mirror of
https://github.com/rxliuli/apps.apple.com.git
synced 2025-11-09 23:00:32 +00:00
init commit
This commit is contained in:
3
node_modules/@jet/environment/models/actions/alert-action.js
generated
vendored
Normal file
3
node_modules/@jet/environment/models/actions/alert-action.js
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
//# sourceMappingURL=alert-action.js.map
|
||||
22
node_modules/@jet/environment/models/actions/compound-action.js
generated
vendored
Normal file
22
node_modules/@jet/environment/models/actions/compound-action.js
generated
vendored
Normal file
@@ -0,0 +1,22 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.makeCompoundAction = exports.isCompoundAction = void 0;
|
||||
/**
|
||||
* Custom type guard to determine if an action is a CompoundAction.
|
||||
*/
|
||||
function isCompoundAction(action) {
|
||||
return (action === null || action === void 0 ? void 0 : action.$kind) === "compoundAction";
|
||||
}
|
||||
exports.isCompoundAction = isCompoundAction;
|
||||
/**
|
||||
* Helper that returns a CompoundAction, given an ActionMetrics and ActionModel[] of subactions.
|
||||
*/
|
||||
function makeCompoundAction(actionMetrics, subactions) {
|
||||
return {
|
||||
$kind: "compoundAction",
|
||||
subactions,
|
||||
actionMetrics,
|
||||
};
|
||||
}
|
||||
exports.makeCompoundAction = makeCompoundAction;
|
||||
//# sourceMappingURL=compound-action.js.map
|
||||
21
node_modules/@jet/environment/models/actions/empty-action.js
generated
vendored
Normal file
21
node_modules/@jet/environment/models/actions/empty-action.js
generated
vendored
Normal file
@@ -0,0 +1,21 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.makeEmptyAction = exports.isEmptyAction = void 0;
|
||||
/**
|
||||
* Custom type guard to determine if an action is an EmptyAction.
|
||||
*/
|
||||
function isEmptyAction(action) {
|
||||
return (action === null || action === void 0 ? void 0 : action.$kind) === "emptyAction";
|
||||
}
|
||||
exports.isEmptyAction = isEmptyAction;
|
||||
/**
|
||||
* Helper that returns an EmptyAction, given an ActionMetrics.
|
||||
*/
|
||||
function makeEmptyAction(actionMetrics) {
|
||||
return {
|
||||
$kind: "emptyAction",
|
||||
actionMetrics,
|
||||
};
|
||||
}
|
||||
exports.makeEmptyAction = makeEmptyAction;
|
||||
//# sourceMappingURL=empty-action.js.map
|
||||
3
node_modules/@jet/environment/models/actions/external-url-action.js
generated
vendored
Normal file
3
node_modules/@jet/environment/models/actions/external-url-action.js
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
//# sourceMappingURL=external-url-action.js.map
|
||||
3
node_modules/@jet/environment/models/actions/flow-action.js
generated
vendored
Normal file
3
node_modules/@jet/environment/models/actions/flow-action.js
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
//# sourceMappingURL=flow-action.js.map
|
||||
3
node_modules/@jet/environment/models/actions/flow-back-action.js
generated
vendored
Normal file
3
node_modules/@jet/environment/models/actions/flow-back-action.js
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
//# sourceMappingURL=flow-back-action.js.map
|
||||
3
node_modules/@jet/environment/models/actions/http-action.js
generated
vendored
Normal file
3
node_modules/@jet/environment/models/actions/http-action.js
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
//# sourceMappingURL=http-action.js.map
|
||||
3
node_modules/@jet/environment/models/actions/http-template-action.js
generated
vendored
Normal file
3
node_modules/@jet/environment/models/actions/http-template-action.js
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
//# sourceMappingURL=http-template-action.js.map
|
||||
26
node_modules/@jet/environment/models/actions/index.js
generated
vendored
Normal file
26
node_modules/@jet/environment/models/actions/index.js
generated
vendored
Normal file
@@ -0,0 +1,26 @@
|
||||
"use strict";
|
||||
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
||||
if (k2 === undefined) k2 = k;
|
||||
var desc = Object.getOwnPropertyDescriptor(m, k);
|
||||
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
||||
desc = { enumerable: true, get: function() { return m[k]; } };
|
||||
}
|
||||
Object.defineProperty(o, k2, desc);
|
||||
}) : (function(o, m, k, k2) {
|
||||
if (k2 === undefined) k2 = k;
|
||||
o[k2] = m[k];
|
||||
}));
|
||||
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
||||
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
||||
};
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
__exportStar(require("./alert-action"), exports);
|
||||
__exportStar(require("./compound-action"), exports);
|
||||
__exportStar(require("./empty-action"), exports);
|
||||
__exportStar(require("./external-url-action"), exports);
|
||||
__exportStar(require("./flow-action"), exports);
|
||||
__exportStar(require("./flow-back-action"), exports);
|
||||
__exportStar(require("./http-action"), exports);
|
||||
__exportStar(require("./http-template-action"), exports);
|
||||
__exportStar(require("./toast-action"), exports);
|
||||
//# sourceMappingURL=index.js.map
|
||||
3
node_modules/@jet/environment/models/actions/toast-action.js
generated
vendored
Normal file
3
node_modules/@jet/environment/models/actions/toast-action.js
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
//# sourceMappingURL=toast-action.js.map
|
||||
39
node_modules/@jet/environment/models/artwork.js
generated
vendored
Normal file
39
node_modules/@jet/environment/models/artwork.js
generated
vendored
Normal file
@@ -0,0 +1,39 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.makeArtworkURLTemplate = void 0;
|
||||
const validation = require("../json/validation");
|
||||
const optional_1 = require("../types/optional");
|
||||
const urls_1 = require("../util/urls");
|
||||
/**
|
||||
* Regex to parse artwork URL template string.
|
||||
*/
|
||||
const URL_TEMPLATE_PARSER = new RegExp("^({w}|[0-9]+(?:.[0-9]*)?)x({h}|[0-9]+(?:.[0-9]*)?)({c}|[a-z]{2}).({f}|[a-z]+)$");
|
||||
/**
|
||||
* Create an instance of artwork URL template from string.
|
||||
* @param fromString - String to create artwork URL template from.
|
||||
* @returns A new artwork URL template or `null` if string
|
||||
* does not represent a valid artwork URL template.
|
||||
*/
|
||||
function makeArtworkURLTemplate(fromString) {
|
||||
// A valid URL that ends with '{w}x{h}{c}.{f}'
|
||||
// with any of placeholders possibly resolved to an actual value.
|
||||
const url = new urls_1.URL(fromString);
|
||||
if (url.pathname === undefined) {
|
||||
validation.context("makeArtworkURLTemplate", () => {
|
||||
validation.unexpectedType("ignoredValue", "A valid URL string", fromString);
|
||||
});
|
||||
return null;
|
||||
}
|
||||
// Expecting 5 matches: whole string + width, height, crop code and format.
|
||||
const lastPathComponent = fromString.substring(fromString.lastIndexOf("/") + 1);
|
||||
const matches = URL_TEMPLATE_PARSER.exec(lastPathComponent);
|
||||
if ((0, optional_1.isNothing)(matches) || matches.length !== 5) {
|
||||
validation.context("makeArtworkURLTemplate", () => {
|
||||
validation.unexpectedType("ignoredValue", "A valid artwork URL template ending with {w}x{h}{c}.{f} format", lastPathComponent);
|
||||
});
|
||||
return null;
|
||||
}
|
||||
return fromString;
|
||||
}
|
||||
exports.makeArtworkURLTemplate = makeArtworkURLTemplate;
|
||||
//# sourceMappingURL=artwork.js.map
|
||||
3
node_modules/@jet/environment/models/button.js
generated
vendored
Normal file
3
node_modules/@jet/environment/models/button.js
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
//# sourceMappingURL=button.js.map
|
||||
196
node_modules/@jet/environment/models/color.js
generated
vendored
Normal file
196
node_modules/@jet/environment/models/color.js
generated
vendored
Normal file
@@ -0,0 +1,196 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.areEqual = exports.luminanceFrom = exports.dynamicWith = exports.named = exports.rgbWith = exports.htmlWith = exports.Color = void 0;
|
||||
const optional_1 = require("../types/optional");
|
||||
// endregion
|
||||
// region Constructors
|
||||
// eslint-disable-next-line no-redeclare, @typescript-eslint/no-redeclare
|
||||
exports.Color = {
|
||||
/**
|
||||
* Create new `HTMLColor` from hexadecimal string representation.
|
||||
*
|
||||
* @param hexString - Hexadecimal string representation.
|
||||
*/
|
||||
fromHex(string) {
|
||||
if ((0, optional_1.isNothing)(string)) {
|
||||
return null;
|
||||
}
|
||||
return {
|
||||
$kind: "html",
|
||||
value: string,
|
||||
};
|
||||
},
|
||||
/**
|
||||
* Create new `RBGColor` with RGB components and opacity value.
|
||||
*
|
||||
* @param red - Red color value.
|
||||
* @param green - Green color value.
|
||||
* @param blue - Blue color value.
|
||||
* @param alpha - Opacity value.
|
||||
*/
|
||||
fromRGB(red, green, blue, alpha = 1.0) {
|
||||
const newColor = {
|
||||
$kind: "rgb",
|
||||
red: red,
|
||||
green: green,
|
||||
blue: blue,
|
||||
alpha: alpha,
|
||||
};
|
||||
return newColor;
|
||||
},
|
||||
/**
|
||||
* Create new named color using the color name.
|
||||
*
|
||||
* @param name - The name of the color.
|
||||
*/
|
||||
named(name) {
|
||||
const newColor = {
|
||||
$kind: "named",
|
||||
name: name,
|
||||
};
|
||||
return newColor;
|
||||
},
|
||||
/**
|
||||
* Create new dynamic color with light and dark color variants.
|
||||
*
|
||||
* @param lightColor - The light color variant.
|
||||
* @param lightHighContrastColor - The light hight-contrast color variant.
|
||||
* @param darkColor - The dark color variant.
|
||||
* @param darkHighContrastColor - The dark hight-contrast color variant.
|
||||
*/
|
||||
dynamicWith(lightColor, lightHighContrastColor, darkColor, darkHighContrastColor) {
|
||||
const newColor = {
|
||||
$kind: "dynamic",
|
||||
lightColor: lightColor,
|
||||
lightHighContrastColor: lightHighContrastColor,
|
||||
darkColor: darkColor,
|
||||
darkHighContrastColor: darkHighContrastColor,
|
||||
};
|
||||
return newColor;
|
||||
},
|
||||
// endregion
|
||||
// region Properties
|
||||
/**
|
||||
* Get the luminance of the color.
|
||||
*
|
||||
* @param rgbColor - The RGB color to get luminance for.
|
||||
*/
|
||||
luminanceFrom(rgbColor) {
|
||||
// Note: This is lifted from UIColor_Private
|
||||
// Using RGB color components, calculates and returns (0.2126 * r) + (0.7152 * g) + (0.0722 * b).
|
||||
return rgbColor.red * 0.2126 + rgbColor.green * 0.7152 + rgbColor.blue * 0.0722;
|
||||
},
|
||||
// endregion
|
||||
// region Identity
|
||||
/**
|
||||
* Compare two colors for equality.
|
||||
*
|
||||
* @param color1 - Left hand side color to compare.
|
||||
* @param color2 - Right hand side color to compare.
|
||||
* @returns A Boolean indicating whether the colors are equal.
|
||||
*/
|
||||
areEqual(color1, color2) {
|
||||
if ((0, optional_1.isNothing)(color1)) {
|
||||
return (0, optional_1.isNothing)(color2);
|
||||
}
|
||||
else if ((0, optional_1.isNothing)(color2)) {
|
||||
return (0, optional_1.isNothing)(color1);
|
||||
}
|
||||
const kind1 = color1.$kind;
|
||||
const kind2 = color2.$kind;
|
||||
if (kind1 === "named" && kind2 === "named") {
|
||||
const namedColor1 = color1;
|
||||
const namedColor2 = color2;
|
||||
return namedColor1.name === namedColor2.name;
|
||||
}
|
||||
else if (kind1 === "rgb" && kind2 === "rgb") {
|
||||
const rgbColor1 = color1;
|
||||
const rgbColor2 = color2;
|
||||
return (rgbColor1.red === rgbColor2.red &&
|
||||
rgbColor1.green === rgbColor2.green &&
|
||||
rgbColor1.blue === rgbColor2.blue &&
|
||||
rgbColor1.alpha === rgbColor2.alpha);
|
||||
}
|
||||
else if (kind1 === "dynamic" && kind2 === "dynamic") {
|
||||
const dynamicColor1 = color1;
|
||||
const dynamicColor2 = color2;
|
||||
return (exports.Color.areEqual(dynamicColor1.lightColor, dynamicColor2.lightColor) &&
|
||||
exports.Color.areEqual(dynamicColor1.lightHighContrastColor, dynamicColor2.lightHighContrastColor) &&
|
||||
exports.Color.areEqual(dynamicColor1.darkColor, dynamicColor2.darkColor) &&
|
||||
exports.Color.areEqual(dynamicColor1.darkHighContrastColor, dynamicColor2.darkHighContrastColor));
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
}
|
||||
},
|
||||
};
|
||||
/**
|
||||
* Create new `HTMLColor` from hexadecimal string representation.
|
||||
*
|
||||
* @param hexString - Hexadecimal string representation.
|
||||
*
|
||||
* @deprecated This symbol has been moved to `Color.fromHex` and will be removed
|
||||
* in the future.
|
||||
*/
|
||||
const htmlWith = exports.Color.fromHex;
|
||||
exports.htmlWith = htmlWith;
|
||||
/**
|
||||
* Create new `RBGColor` with RGB components and opacity value.
|
||||
*
|
||||
* @param red - Red color value.
|
||||
* @param green - Green color value.
|
||||
* @param blue - Blue color value.
|
||||
* @param alpha - Opacity value.
|
||||
*
|
||||
* @deprecated This symbol has been moved to `Color.fromRGB` and will be removed
|
||||
* in the future.
|
||||
*/
|
||||
const rgbWith = exports.Color.fromRGB;
|
||||
exports.rgbWith = rgbWith;
|
||||
/**
|
||||
* Create new named color using the color name.
|
||||
*
|
||||
* @param name - The name of the color.
|
||||
*
|
||||
* @deprecated This symbol has been moved to `Color.named` and will be removed
|
||||
* in the future.
|
||||
*/
|
||||
const named = exports.Color.named;
|
||||
exports.named = named;
|
||||
/**
|
||||
* Create new dynamic color with light and dark color variants.
|
||||
*
|
||||
* @param lightColor - The light color variant.
|
||||
* @param lightHighContrastColor - The light hight-contrast color variant.
|
||||
* @param darkColor - The dark color variant.
|
||||
* @param darkHighContrastColor - The dark hight-contrast color variant.
|
||||
*
|
||||
* @deprecated This symbol has been moved to `Color.dynamicWith` and will be removed
|
||||
* in the future.
|
||||
*/
|
||||
const dynamicWith = exports.Color.dynamicWith;
|
||||
exports.dynamicWith = dynamicWith;
|
||||
/**
|
||||
* Get the luminance of the color.
|
||||
*
|
||||
* @param rgbColor - The RGB color to get luminance for.
|
||||
*
|
||||
* @deprecated This symbol has been moved to `Color.luminanceFrom` and will be removed
|
||||
* in the future.
|
||||
*/
|
||||
const luminanceFrom = exports.Color.luminanceFrom;
|
||||
exports.luminanceFrom = luminanceFrom;
|
||||
/**
|
||||
* Compare two colors for equality.
|
||||
*
|
||||
* @param color1 - Left hand side color to compare.
|
||||
* @param color2 - Right hand side color to compare.
|
||||
* @returns A Boolean indicating whether the colors are equal.
|
||||
*
|
||||
* @deprecated This symbol has been moved to `Color.areEqual` and will be removed
|
||||
* in the future.
|
||||
*/
|
||||
const areEqual = exports.Color.areEqual;
|
||||
exports.areEqual = areEqual;
|
||||
// endregion
|
||||
//# sourceMappingURL=color.js.map
|
||||
25
node_modules/@jet/environment/models/index.js
generated
vendored
Normal file
25
node_modules/@jet/environment/models/index.js
generated
vendored
Normal file
@@ -0,0 +1,25 @@
|
||||
"use strict";
|
||||
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
||||
if (k2 === undefined) k2 = k;
|
||||
var desc = Object.getOwnPropertyDescriptor(m, k);
|
||||
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
||||
desc = { enumerable: true, get: function() { return m[k]; } };
|
||||
}
|
||||
Object.defineProperty(o, k2, desc);
|
||||
}) : (function(o, m, k, k2) {
|
||||
if (k2 === undefined) k2 = k;
|
||||
o[k2] = m[k];
|
||||
}));
|
||||
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
||||
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
||||
};
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
__exportStar(require("./actions"), exports);
|
||||
__exportStar(require("./artwork"), exports);
|
||||
__exportStar(require("./button"), exports);
|
||||
__exportStar(require("./color"), exports);
|
||||
__exportStar(require("./menu"), exports);
|
||||
__exportStar(require("./paragraph"), exports);
|
||||
__exportStar(require("./programmed-text"), exports);
|
||||
__exportStar(require("./video"), exports);
|
||||
//# sourceMappingURL=index.js.map
|
||||
8
node_modules/@jet/environment/models/menu.js
generated
vendored
Normal file
8
node_modules/@jet/environment/models/menu.js
generated
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
exports.menuSeparatorID = void 0;
|
||||
/**
|
||||
* A standard identifier for including a separator in a menu.
|
||||
*/
|
||||
exports.menuSeparatorID = "com.apple.JetEngine.separator";
|
||||
//# sourceMappingURL=menu.js.map
|
||||
4
node_modules/@jet/environment/models/paragraph.js
generated
vendored
Normal file
4
node_modules/@jet/environment/models/paragraph.js
generated
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
// endregion
|
||||
//# sourceMappingURL=paragraph.js.map
|
||||
5
node_modules/@jet/environment/models/programmed-text.js
generated
vendored
Normal file
5
node_modules/@jet/environment/models/programmed-text.js
generated
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
"use strict";
|
||||
// region ProgrammedText
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
// endregion
|
||||
//# sourceMappingURL=programmed-text.js.map
|
||||
3
node_modules/@jet/environment/models/video.js
generated
vendored
Normal file
3
node_modules/@jet/environment/models/video.js
generated
vendored
Normal file
@@ -0,0 +1,3 @@
|
||||
"use strict";
|
||||
Object.defineProperty(exports, "__esModule", { value: true });
|
||||
//# sourceMappingURL=video.js.map
|
||||
Reference in New Issue
Block a user