@ankhorage/contracts 26.5.0 → 26.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/README.md +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/structure/generated.d.ts +2 -2
- package/dist/structure/generated.js +2 -2
- package/dist/structure/generated.js.map +1 -1
- package/dist/website.d.ts +260 -0
- package/dist/website.d.ts.map +1 -0
- package/dist/website.js +2 -0
- package/dist/website.js.map +1 -0
- package/package.json +5 -1
- package/src/index.ts +1 -0
- package/src/structure/generated.ts +2 -2
- package/src/website.test.ts +39 -0
- package/src/website.ts +287 -0
package/CHANGELOG.md
CHANGED
package/README.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
# @ankhorage/contracts
|
|
5
5
|
|
|
6
|
-
         
|
|
7
7
|
|
|
8
8
|
Serializable app, capability, binding, theme, auth, and secret-store contracts for Ankhorage.
|
|
9
9
|
|
package/dist/index.d.ts
CHANGED
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,kBAAkB,CAAC;AACjC,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC;AAC5B,cAAc,qBAAqB,CAAC;AACpC,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,uBAAuB,CAAC;AACtC,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,sBAAsB,CAAC;AACrC,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,kBAAkB,CAAC;AACjC,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC;AAC5B,cAAc,qBAAqB,CAAC;AACpC,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,uBAAuB,CAAC;AACtC,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,sBAAsB,CAAC;AACrC,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC"}
|
package/dist/index.js
CHANGED
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,kBAAkB,CAAC;AACjC,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC;AAC5B,cAAc,qBAAqB,CAAC;AACpC,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,uBAAuB,CAAC;AACtC,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,sBAAsB,CAAC;AACrC,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC","sourcesContent":["export * from './ads.js';\nexport * from './appManifest.js';\nexport * from './auth.js';\nexport * from './bindings.js';\nexport * from './cli/index.js';\nexport * from './collections.js';\nexport * from './data/index.js';\nexport * from './db.js';\nexport * from './deploy.js';\nexport * from './deployProvider.js';\nexport * from './environments.js';\nexport * from './infra.js';\nexport * from './media.js';\nexport * from './navigator.js';\nexport * from './repository.js';\nexport * from './requirements.js';\nexport * from './rules.js';\nexport * from './runtimeCallbacks.js';\nexport * from './secrets.js';\nexport * from './serializable.js';\nexport * from './state.js';\nexport * from './storage.js';\nexport * from './structure/index.js';\nexport * from './theme.js';\nexport * from './types.js';\nexport * from './ui.js';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,kBAAkB,CAAC;AACjC,cAAc,WAAW,CAAC;AAC1B,cAAc,eAAe,CAAC;AAC9B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,kBAAkB,CAAC;AACjC,cAAc,iBAAiB,CAAC;AAChC,cAAc,SAAS,CAAC;AACxB,cAAc,aAAa,CAAC;AAC5B,cAAc,qBAAqB,CAAC;AACpC,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,iBAAiB,CAAC;AAChC,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,uBAAuB,CAAC;AACtC,cAAc,cAAc,CAAC;AAC7B,cAAc,mBAAmB,CAAC;AAClC,cAAc,YAAY,CAAC;AAC3B,cAAc,cAAc,CAAC;AAC7B,cAAc,sBAAsB,CAAC;AACrC,cAAc,YAAY,CAAC;AAC3B,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC;AACxB,cAAc,cAAc,CAAC","sourcesContent":["export * from './ads.js';\nexport * from './appManifest.js';\nexport * from './auth.js';\nexport * from './bindings.js';\nexport * from './cli/index.js';\nexport * from './collections.js';\nexport * from './data/index.js';\nexport * from './db.js';\nexport * from './deploy.js';\nexport * from './deployProvider.js';\nexport * from './environments.js';\nexport * from './infra.js';\nexport * from './media.js';\nexport * from './navigator.js';\nexport * from './repository.js';\nexport * from './requirements.js';\nexport * from './rules.js';\nexport * from './runtimeCallbacks.js';\nexport * from './secrets.js';\nexport * from './serializable.js';\nexport * from './state.js';\nexport * from './storage.js';\nexport * from './structure/index.js';\nexport * from './theme.js';\nexport * from './types.js';\nexport * from './ui.js';\nexport * from './website.js';\n"]}
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
export declare const STRUCTURE_DESCRIPTOR_COMPILER_VERSION = "6.0.3";
|
|
2
|
-
export declare const STRUCTURE_DESCRIPTOR_FINGERPRINT = "sha256:
|
|
2
|
+
export declare const STRUCTURE_DESCRIPTOR_FINGERPRINT = "sha256:dd8057c752c877b62bdc5c8db41135bd76c55dedf9bf4e1a13d7bf977f9cca56";
|
|
3
3
|
export declare const STRUCTURE_DESCRIPTOR: {
|
|
4
4
|
readonly protocolVersion: 1;
|
|
5
5
|
readonly packageName: "@ankhorage/contracts";
|
|
6
|
-
readonly packageVersion: "26.
|
|
6
|
+
readonly packageVersion: "26.6.0";
|
|
7
7
|
readonly roots: {
|
|
8
8
|
readonly "auth-flow": "AuthFlowConfig";
|
|
9
9
|
readonly "auth-profile": "AuthProfileSpec";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
export const STRUCTURE_DESCRIPTOR_COMPILER_VERSION = '6.0.3';
|
|
2
|
-
export const STRUCTURE_DESCRIPTOR_FINGERPRINT = 'sha256:
|
|
2
|
+
export const STRUCTURE_DESCRIPTOR_FINGERPRINT = 'sha256:dd8057c752c877b62bdc5c8db41135bd76c55dedf9bf4e1a13d7bf977f9cca56';
|
|
3
3
|
export const STRUCTURE_DESCRIPTOR = {
|
|
4
4
|
"protocolVersion": 1,
|
|
5
5
|
"packageName": "@ankhorage/contracts",
|
|
6
|
-
"packageVersion": "26.
|
|
6
|
+
"packageVersion": "26.6.0",
|
|
7
7
|
"roots": {
|
|
8
8
|
"auth-flow": "AuthFlowConfig",
|
|
9
9
|
"auth-profile": "AuthProfileSpec",
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"generated.js","sourceRoot":"","sources":["../../src/structure/generated.ts"],"names":[],"mappings":"AAGA,MAAM,CAAC,MAAM,qCAAqC,GAAG,OAAO,CAAC;AAC7D,MAAM,CAAC,MAAM,gCAAgC,GAAG,yEAAyE,CAAC;AAE1H,MAAM,CAAC,MAAM,oBAAoB,GAAG;IAClC,iBAAiB,EAAE,CAAC;IACpB,aAAa,EAAE,sBAAsB;IACrC,gBAAgB,EAAE,QAAQ;IAC1B,OAAO,EAAE;QACP,WAAW,EAAE,gBAAgB;QAC7B,cAAc,EAAE,iBAAiB;QACjC,cAAc,EAAE,gBAAgB;QAChC,cAAc,EAAE,gBAAgB;QAChC,iBAAiB,EAAE,oBAAoB;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6C,CAAC","sourcesContent":["/* This file is generated by @ankhorage/devtools. Do not edit manually. */\nimport type { StructureDescriptorDocument } from '@ankhorage/contracts/structure';\n\nexport const STRUCTURE_DESCRIPTOR_COMPILER_VERSION = '6.0.3';\nexport const STRUCTURE_DESCRIPTOR_FINGERPRINT = 'sha256:a4faf6ff20f79ce64ec819b9cef12e92e66adffb28265deab224bc79dec7e019';\n\nexport const STRUCTURE_DESCRIPTOR = {\n \"protocolVersion\": 1,\n \"packageName\": \"@ankhorage/contracts\",\n \"packageVersion\": \"26.5.0\",\n \"roots\": {\n \"auth-flow\": \"AuthFlowConfig\",\n \"auth-profile\": \"AuthProfileSpec\",\n \"auth-sign-in\": \"AuthSignInSpec\",\n \"auth-sign-up\": \"AuthSignUpSpec\",\n \"screen-metadata\": \"ScreenMetadataSpec\",\n \"screen-requirements\": \"ScreenRequirements\",\n \"theme-config\": \"ThemeConfig\"\n },\n \"descriptors\": {\n \"AuthFlowConfig\": {\n \"id\": \"AuthFlowConfig\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"forgotPasswordRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n },\n \"otpRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n },\n \"postSignInRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"signInRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"signOutRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n },\n \"signUpRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n },\n \"unauthorizedRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n }\n }\n }\n },\n \"AuthProfileField\": {\n \"id\": \"AuthProfileField\",\n \"descriptor\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"AuthProfileSpec\": {\n \"id\": \"AuthProfileSpec\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"createStrategy\": {\n \"value\": {\n \"kind\": \"enum\",\n \"values\": [\n \"api\",\n \"app\",\n \"trigger\"\n ]\n },\n \"optional\": true\n },\n \"fields\": {\n \"value\": {\n \"kind\": \"ordered-list\",\n \"item\": {\n \"kind\": \"ref\",\n \"id\": \"AuthProfileField\"\n }\n }\n },\n \"primaryKey\": {\n \"value\": {\n \"kind\": \"enum\",\n \"values\": [\n \"authUserId\"\n ]\n },\n \"optional\": true\n },\n \"table\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n },\n \"updateStrategy\": {\n \"value\": {\n \"kind\": \"enum\",\n \"values\": [\n \"api\",\n \"app\"\n ]\n },\n \"optional\": true\n }\n }\n }\n },\n \"AuthSignInSpec\": {\n \"id\": \"AuthSignInSpec\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"identifiers\": {\n \"value\": {\n \"kind\": \"ordered-list\",\n \"item\": {\n \"kind\": \"enum\",\n \"values\": [\n \"email\",\n \"phone\",\n \"username\"\n ]\n }\n }\n }\n }\n }\n },\n \"AuthSignUpField\": {\n \"id\": \"AuthSignUpField\",\n \"descriptor\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"AuthSignUpSpec\": {\n \"id\": \"AuthSignUpSpec\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"optionalFields\": {\n \"value\": {\n \"kind\": \"ordered-list\",\n \"item\": {\n \"kind\": \"ref\",\n \"id\": \"AuthSignUpField\"\n }\n },\n \"optional\": true\n },\n \"requiredFields\": {\n \"value\": {\n \"kind\": \"ordered-list\",\n \"item\": {\n \"kind\": \"ref\",\n \"id\": \"AuthSignUpField\"\n }\n }\n },\n \"signUpPolicy\": {\n \"value\": {\n \"kind\": \"enum\",\n \"values\": [\n \"autoSignIn\",\n \"requireVerification\"\n ]\n },\n \"optional\": true\n }\n }\n }\n },\n \"ScreenMetadataSpec\": {\n \"id\": \"ScreenMetadataSpec\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"description\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n },\n \"id\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"name\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"title\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n }\n }\n }\n },\n \"ScreenRequirements\": {\n \"id\": \"ScreenRequirements\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"capabilities\": {\n \"value\": {\n \"kind\": \"set\",\n \"member\": {\n \"kind\": \"enum\",\n \"values\": [\n \"barcodeScanner\",\n \"cameraPreview\",\n \"clipboard\",\n \"ebookReader\",\n \"filePicker\",\n \"location\",\n \"mediaPicker\",\n \"notifications\"\n ]\n }\n },\n \"optional\": true\n },\n \"permissions\": {\n \"value\": {\n \"kind\": \"set\",\n \"member\": {\n \"kind\": \"enum\",\n \"values\": [\n \"camera\",\n \"clipboard\",\n \"locationBackground\",\n \"locationForeground\",\n \"mediaLibrary\",\n \"mediaLibraryWrite\",\n \"microphone\",\n \"notifications\"\n ]\n }\n },\n \"optional\": true\n }\n }\n }\n },\n \"ThemeConfig\": {\n \"id\": \"ThemeConfig\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"dark\": {\n \"value\": {\n \"kind\": \"ref\",\n \"id\": \"ThemeModeConfig\"\n }\n },\n \"id\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"light\": {\n \"value\": {\n \"kind\": \"ref\",\n \"id\": \"ThemeModeConfig\"\n }\n },\n \"name\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"recipes\": {\n \"value\": {\n \"kind\": \"ref\",\n \"id\": \"ThemeRecipeOverrides\"\n },\n \"optional\": true\n },\n \"tokens\": {\n \"value\": {\n \"kind\": \"ref\",\n \"id\": \"ThemeGlobalTokenOverrides\"\n },\n \"optional\": true\n }\n }\n }\n },\n \"ThemeGlobalTokenOverrides\": {\n \"id\": \"ThemeGlobalTokenOverrides\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"radii\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"number\"\n }\n },\n \"optional\": true\n },\n \"shadows\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"number\"\n }\n },\n \"optional\": true\n },\n \"spacing\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"number\"\n }\n },\n \"optional\": true\n },\n \"typography\": {\n \"value\": {\n \"kind\": \"ref\",\n \"id\": \"ThemeTypographyTokenOverrides\"\n },\n \"optional\": true\n }\n }\n }\n },\n \"ThemeModeConfig\": {\n \"id\": \"ThemeModeConfig\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"harmony\": {\n \"value\": {\n \"kind\": \"enum\",\n \"values\": [\n \"analogous\",\n \"complementary\",\n \"monochromatic\",\n \"splitComplementary\",\n \"square\",\n \"tetradic\",\n \"triadic\"\n ]\n }\n },\n \"primaryColor\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n }\n }\n }\n },\n \"ThemeRecipeOverrides\": {\n \"id\": \"ThemeRecipeOverrides\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"components\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"ref\",\n \"packageName\": \"typescript\",\n \"id\": \"Readonly\"\n }\n },\n \"optional\": true\n },\n \"patterns\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"ref\",\n \"packageName\": \"typescript\",\n \"id\": \"Readonly\"\n }\n },\n \"optional\": true\n }\n }\n }\n },\n \"ThemeTypographyHeadingOverrides\": {\n \"id\": \"ThemeTypographyHeadingOverrides\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"lineHeight\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"number\"\n },\n \"optional\": true\n },\n \"size\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"number\"\n },\n \"optional\": true\n },\n \"weight\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n }\n }\n }\n },\n \"ThemeTypographyTokenOverrides\": {\n \"id\": \"ThemeTypographyTokenOverrides\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"headings\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"ref\",\n \"id\": \"ThemeTypographyHeadingOverrides\"\n }\n },\n \"optional\": true\n },\n \"sizes\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"number\"\n }\n },\n \"optional\": true\n },\n \"weights\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"optional\": true\n }\n }\n }\n }\n }\n} as const satisfies StructureDescriptorDocument;\n"]}
|
|
1
|
+
{"version":3,"file":"generated.js","sourceRoot":"","sources":["../../src/structure/generated.ts"],"names":[],"mappings":"AAGA,MAAM,CAAC,MAAM,qCAAqC,GAAG,OAAO,CAAC;AAC7D,MAAM,CAAC,MAAM,gCAAgC,GAAG,yEAAyE,CAAC;AAE1H,MAAM,CAAC,MAAM,oBAAoB,GAAG;IAClC,iBAAiB,EAAE,CAAC;IACpB,aAAa,EAAE,sBAAsB;IACrC,gBAAgB,EAAE,QAAQ;IAC1B,OAAO,EAAE;QACP,WAAW,EAAE,gBAAgB;QAC7B,cAAc,EAAE,iBAAiB;QACjC,cAAc,EAAE,gBAAgB;QAChC,cAAc,EAAE,gBAAgB;QAChC,iBAAiB,EAAE,oBAAoB;QACvC,qBAAqB,EAAE,oBAAoB;QAC3C,cAAc,EAAE,aAAa;KAC9B;IACD,aAAa,EAAE;QACb,gBAAgB,EAAE;YAChB,IAAI,EAAE,gBAAgB;YACtB,YAAY,EAAE;gBACZ,MAAM,EAAE,QAAQ;gBAChB,QAAQ,EAAE;oBACR,qBAAqB,EAAE;wBACrB,OAAO,EAAE;4BACP,MAAM,EAAE,QAAQ;4BAChB,MAAM,EAAE,QAAQ;yBACjB;wBACD,UAAU,EAAE,IAAI;qBACjB;oBACD,UAAU,EAAE;wBACV,OAAO,EAAE;4BACP,MAAM,EAAE,QAAQ;4BAChB,MAAM,EAAE,QAAQ;yBACjB;wBACD,UAAU,EAAE,IAAI;qBACjB;oBACD,iBAAiB,EAAE;wBACjB,OAAO,EAAE;4BACP,MAAM,EAAE,QAAQ;4BAChB,MAAM,EAAE,QAAQ;yBACjB;qBACF;oBACD,aAAa,EAAE;wBACb,OAAO,EAAE;4BACP,MAAM,EAAE,QAAQ;4BAChB,MAAM,EAAE,QAAQ;yBACjB;qBACF;oBACD,cAAc,EAAE;wBACd,OAAO,EAAE;4BACP,MAAM,EAAE,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ACD,OAAO,EAAE;wBACP,OAAO,EAAE;4BACP,MAAM,EAAE,WAAW;4BACnB,KAAK,EAAE;gCACL,MAAM,EAAE,QAAQ;gCAChB,MAAM,EAAE,QAAQ;6BACjB;4BACD,OAAO,EAAE;gCACP,MAAM,EAAE,QAAQ;gCAChB,MAAM,EAAE,QAAQ;6BACjB;yBACF;wBACD,UAAU,EAAE,IAAI;qBACjB;oBACD,SAAS,EAAE;wBACT,OAAO,EAAE;4BACP,MAAM,EAAE,WAAW;4BACnB,KAAK,EAAE;gCACL,MAAM,EAAE,QAAQ;gCAChB,MAAM,EAAE,QAAQ;6BACjB;4BACD,OAAO,EAAE;gCACP,MAAM,EAAE,QAAQ;gCAChB,MAAM,EAAE,QAAQ;6BACjB;yBACF;wBACD,UAAU,EAAE,IAAI;qBACjB;iBACF;aACF;SACF;KACF;CAC6C,CAAC","sourcesContent":["/* This file is generated by @ankhorage/devtools. Do not edit manually. */\nimport type { StructureDescriptorDocument } from '@ankhorage/contracts/structure';\n\nexport const STRUCTURE_DESCRIPTOR_COMPILER_VERSION = '6.0.3';\nexport const STRUCTURE_DESCRIPTOR_FINGERPRINT = 'sha256:dd8057c752c877b62bdc5c8db41135bd76c55dedf9bf4e1a13d7bf977f9cca56';\n\nexport const STRUCTURE_DESCRIPTOR = {\n \"protocolVersion\": 1,\n \"packageName\": \"@ankhorage/contracts\",\n \"packageVersion\": \"26.6.0\",\n \"roots\": {\n \"auth-flow\": \"AuthFlowConfig\",\n \"auth-profile\": \"AuthProfileSpec\",\n \"auth-sign-in\": \"AuthSignInSpec\",\n \"auth-sign-up\": \"AuthSignUpSpec\",\n \"screen-metadata\": \"ScreenMetadataSpec\",\n \"screen-requirements\": \"ScreenRequirements\",\n \"theme-config\": \"ThemeConfig\"\n },\n \"descriptors\": {\n \"AuthFlowConfig\": {\n \"id\": \"AuthFlowConfig\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"forgotPasswordRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n },\n \"otpRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n },\n \"postSignInRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"signInRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"signOutRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n },\n \"signUpRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n },\n \"unauthorizedRoute\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n }\n }\n }\n },\n \"AuthProfileField\": {\n \"id\": \"AuthProfileField\",\n \"descriptor\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"AuthProfileSpec\": {\n \"id\": \"AuthProfileSpec\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"createStrategy\": {\n \"value\": {\n \"kind\": \"enum\",\n \"values\": [\n \"api\",\n \"app\",\n \"trigger\"\n ]\n },\n \"optional\": true\n },\n \"fields\": {\n \"value\": {\n \"kind\": \"ordered-list\",\n \"item\": {\n \"kind\": \"ref\",\n \"id\": \"AuthProfileField\"\n }\n }\n },\n \"primaryKey\": {\n \"value\": {\n \"kind\": \"enum\",\n \"values\": [\n \"authUserId\"\n ]\n },\n \"optional\": true\n },\n \"table\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n },\n \"updateStrategy\": {\n \"value\": {\n \"kind\": \"enum\",\n \"values\": [\n \"api\",\n \"app\"\n ]\n },\n \"optional\": true\n }\n }\n }\n },\n \"AuthSignInSpec\": {\n \"id\": \"AuthSignInSpec\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"identifiers\": {\n \"value\": {\n \"kind\": \"ordered-list\",\n \"item\": {\n \"kind\": \"enum\",\n \"values\": [\n \"email\",\n \"phone\",\n \"username\"\n ]\n }\n }\n }\n }\n }\n },\n \"AuthSignUpField\": {\n \"id\": \"AuthSignUpField\",\n \"descriptor\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"AuthSignUpSpec\": {\n \"id\": \"AuthSignUpSpec\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"optionalFields\": {\n \"value\": {\n \"kind\": \"ordered-list\",\n \"item\": {\n \"kind\": \"ref\",\n \"id\": \"AuthSignUpField\"\n }\n },\n \"optional\": true\n },\n \"requiredFields\": {\n \"value\": {\n \"kind\": \"ordered-list\",\n \"item\": {\n \"kind\": \"ref\",\n \"id\": \"AuthSignUpField\"\n }\n }\n },\n \"signUpPolicy\": {\n \"value\": {\n \"kind\": \"enum\",\n \"values\": [\n \"autoSignIn\",\n \"requireVerification\"\n ]\n },\n \"optional\": true\n }\n }\n }\n },\n \"ScreenMetadataSpec\": {\n \"id\": \"ScreenMetadataSpec\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"description\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n },\n \"id\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"name\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"title\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n }\n }\n }\n },\n \"ScreenRequirements\": {\n \"id\": \"ScreenRequirements\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"capabilities\": {\n \"value\": {\n \"kind\": \"set\",\n \"member\": {\n \"kind\": \"enum\",\n \"values\": [\n \"barcodeScanner\",\n \"cameraPreview\",\n \"clipboard\",\n \"ebookReader\",\n \"filePicker\",\n \"location\",\n \"mediaPicker\",\n \"notifications\"\n ]\n }\n },\n \"optional\": true\n },\n \"permissions\": {\n \"value\": {\n \"kind\": \"set\",\n \"member\": {\n \"kind\": \"enum\",\n \"values\": [\n \"camera\",\n \"clipboard\",\n \"locationBackground\",\n \"locationForeground\",\n \"mediaLibrary\",\n \"mediaLibraryWrite\",\n \"microphone\",\n \"notifications\"\n ]\n }\n },\n \"optional\": true\n }\n }\n }\n },\n \"ThemeConfig\": {\n \"id\": \"ThemeConfig\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"dark\": {\n \"value\": {\n \"kind\": \"ref\",\n \"id\": \"ThemeModeConfig\"\n }\n },\n \"id\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"light\": {\n \"value\": {\n \"kind\": \"ref\",\n \"id\": \"ThemeModeConfig\"\n }\n },\n \"name\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"recipes\": {\n \"value\": {\n \"kind\": \"ref\",\n \"id\": \"ThemeRecipeOverrides\"\n },\n \"optional\": true\n },\n \"tokens\": {\n \"value\": {\n \"kind\": \"ref\",\n \"id\": \"ThemeGlobalTokenOverrides\"\n },\n \"optional\": true\n }\n }\n }\n },\n \"ThemeGlobalTokenOverrides\": {\n \"id\": \"ThemeGlobalTokenOverrides\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"radii\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"number\"\n }\n },\n \"optional\": true\n },\n \"shadows\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"number\"\n }\n },\n \"optional\": true\n },\n \"spacing\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"number\"\n }\n },\n \"optional\": true\n },\n \"typography\": {\n \"value\": {\n \"kind\": \"ref\",\n \"id\": \"ThemeTypographyTokenOverrides\"\n },\n \"optional\": true\n }\n }\n }\n },\n \"ThemeModeConfig\": {\n \"id\": \"ThemeModeConfig\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"harmony\": {\n \"value\": {\n \"kind\": \"enum\",\n \"values\": [\n \"analogous\",\n \"complementary\",\n \"monochromatic\",\n \"splitComplementary\",\n \"square\",\n \"tetradic\",\n \"triadic\"\n ]\n }\n },\n \"primaryColor\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n }\n }\n }\n },\n \"ThemeRecipeOverrides\": {\n \"id\": \"ThemeRecipeOverrides\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"components\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"ref\",\n \"packageName\": \"typescript\",\n \"id\": \"Readonly\"\n }\n },\n \"optional\": true\n },\n \"patterns\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"ref\",\n \"packageName\": \"typescript\",\n \"id\": \"Readonly\"\n }\n },\n \"optional\": true\n }\n }\n }\n },\n \"ThemeTypographyHeadingOverrides\": {\n \"id\": \"ThemeTypographyHeadingOverrides\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"lineHeight\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"number\"\n },\n \"optional\": true\n },\n \"size\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"number\"\n },\n \"optional\": true\n },\n \"weight\": {\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"optional\": true\n }\n }\n }\n },\n \"ThemeTypographyTokenOverrides\": {\n \"id\": \"ThemeTypographyTokenOverrides\",\n \"descriptor\": {\n \"kind\": \"object\",\n \"fields\": {\n \"headings\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"ref\",\n \"id\": \"ThemeTypographyHeadingOverrides\"\n }\n },\n \"optional\": true\n },\n \"sizes\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"number\"\n }\n },\n \"optional\": true\n },\n \"weights\": {\n \"value\": {\n \"kind\": \"value-map\",\n \"key\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n },\n \"value\": {\n \"kind\": \"scalar\",\n \"type\": \"string\"\n }\n },\n \"optional\": true\n }\n }\n }\n }\n }\n} as const satisfies StructureDescriptorDocument;\n"]}
|
|
@@ -0,0 +1,260 @@
|
|
|
1
|
+
import type { MediaAssetReference } from './media.js';
|
|
2
|
+
import type { SerializableValue } from './serializable.js';
|
|
3
|
+
import type { UiNode } from './types.js';
|
|
4
|
+
/*** A versioned, portable capture of the observable state of one website. */
|
|
5
|
+
export interface WebsiteObservationDocument {
|
|
6
|
+
readonly schemaVersion: 1;
|
|
7
|
+
readonly documentId: string;
|
|
8
|
+
readonly collectedAt: string;
|
|
9
|
+
readonly source: WebsiteSource;
|
|
10
|
+
readonly site: WebsiteSite;
|
|
11
|
+
readonly pages: readonly WebsitePageObservation[];
|
|
12
|
+
}
|
|
13
|
+
/*** The scraper identity and immutable crawl revision that produced a website document. */
|
|
14
|
+
export interface WebsiteSource {
|
|
15
|
+
readonly crawlerId: string;
|
|
16
|
+
readonly crawlerVersion: string;
|
|
17
|
+
readonly crawlId: string;
|
|
18
|
+
readonly revision: string | null;
|
|
19
|
+
}
|
|
20
|
+
/*** A site identity and its canonical entry URL. */
|
|
21
|
+
export interface WebsiteSite {
|
|
22
|
+
readonly id: string;
|
|
23
|
+
readonly url: string;
|
|
24
|
+
}
|
|
25
|
+
/*** One observed page, including its ordered navigation and captured render states. */
|
|
26
|
+
export interface WebsitePageObservation {
|
|
27
|
+
readonly id: string;
|
|
28
|
+
readonly url: string;
|
|
29
|
+
readonly path: string;
|
|
30
|
+
readonly navigation: readonly WebsiteNavigationItem[];
|
|
31
|
+
readonly viewports: readonly WebsiteViewport[];
|
|
32
|
+
readonly states: readonly WebsiteState[];
|
|
33
|
+
readonly nodes: readonly WebsiteObservedNode[];
|
|
34
|
+
readonly assets: readonly WebsiteAsset[];
|
|
35
|
+
}
|
|
36
|
+
/*** One ordered, source-linked navigation target observed on a page. */
|
|
37
|
+
export interface WebsiteNavigationItem {
|
|
38
|
+
readonly id: string;
|
|
39
|
+
readonly label: string;
|
|
40
|
+
readonly url: string;
|
|
41
|
+
readonly sourceRef: string;
|
|
42
|
+
}
|
|
43
|
+
/*** A rendered viewport used while observing responsive website state. */
|
|
44
|
+
export interface WebsiteViewport {
|
|
45
|
+
readonly id: string;
|
|
46
|
+
readonly width: number;
|
|
47
|
+
readonly height: number;
|
|
48
|
+
readonly devicePixelRatio: number;
|
|
49
|
+
}
|
|
50
|
+
/*** A named rendered state, such as default, hover, or expanded. */
|
|
51
|
+
export interface WebsiteState {
|
|
52
|
+
readonly id: string;
|
|
53
|
+
readonly name: string;
|
|
54
|
+
}
|
|
55
|
+
/*** A stable DOM node and every source-linked observation collected for it. */
|
|
56
|
+
export interface WebsiteObservedNode {
|
|
57
|
+
readonly sourceRef: string;
|
|
58
|
+
readonly parentSourceRef: string | null;
|
|
59
|
+
readonly ancestorSourceRefs: readonly string[];
|
|
60
|
+
readonly dom: WebsiteDomNode;
|
|
61
|
+
readonly textRuns: readonly WebsiteTextRun[];
|
|
62
|
+
readonly links: readonly WebsiteLink[];
|
|
63
|
+
readonly media: readonly WebsiteMediaReference[];
|
|
64
|
+
readonly observations: readonly WebsiteNodeObservation[];
|
|
65
|
+
}
|
|
66
|
+
/*** A portable DOM identity with safe semantic attributes only. */
|
|
67
|
+
export interface WebsiteDomNode {
|
|
68
|
+
readonly tagName: string;
|
|
69
|
+
readonly childIndex: number;
|
|
70
|
+
readonly attributes: Readonly<Record<string, string>>;
|
|
71
|
+
}
|
|
72
|
+
/*** A text run retained separately from its DOM node so inline styled spans are not lost. */
|
|
73
|
+
export interface WebsiteTextRun {
|
|
74
|
+
readonly sourceRef: string;
|
|
75
|
+
readonly text: string;
|
|
76
|
+
readonly start: number;
|
|
77
|
+
readonly end: number;
|
|
78
|
+
}
|
|
79
|
+
/*** A source-linked hyperlink observed on a DOM node. */
|
|
80
|
+
export interface WebsiteLink {
|
|
81
|
+
readonly sourceRef: string;
|
|
82
|
+
readonly url: string;
|
|
83
|
+
readonly label: string | null;
|
|
84
|
+
}
|
|
85
|
+
/*** An image, video, audio, or embedded media reference observed on a DOM node. */
|
|
86
|
+
export interface WebsiteMediaReference {
|
|
87
|
+
readonly sourceRef: string;
|
|
88
|
+
readonly assetId: string | null;
|
|
89
|
+
readonly url: string;
|
|
90
|
+
readonly kind: 'audio' | 'document' | 'embed' | 'image' | 'video';
|
|
91
|
+
readonly alt: string | null;
|
|
92
|
+
}
|
|
93
|
+
/*** One viewport/state-specific visual observation of a DOM node. */
|
|
94
|
+
export interface WebsiteNodeObservation {
|
|
95
|
+
readonly viewportId: string;
|
|
96
|
+
readonly stateId: string;
|
|
97
|
+
readonly availability: WebsiteAvailability;
|
|
98
|
+
readonly rect: WebsiteBoundingRect | null;
|
|
99
|
+
readonly css: WebsiteComputedCss | null;
|
|
100
|
+
readonly provenance: WebsiteObservationProvenance;
|
|
101
|
+
}
|
|
102
|
+
/*** Whether a source value was available without fabricating a replacement. */
|
|
103
|
+
export interface WebsiteAvailability {
|
|
104
|
+
readonly status: 'available' | 'missing';
|
|
105
|
+
readonly missing: WebsiteMissingValue | null;
|
|
106
|
+
}
|
|
107
|
+
/*** The explicit reason a website source value could not be observed. */
|
|
108
|
+
export interface WebsiteMissingValue {
|
|
109
|
+
readonly code: string;
|
|
110
|
+
readonly message: string;
|
|
111
|
+
}
|
|
112
|
+
/*** A bounding rectangle measured in CSS pixels. */
|
|
113
|
+
export interface WebsiteBoundingRect {
|
|
114
|
+
readonly x: number;
|
|
115
|
+
readonly y: number;
|
|
116
|
+
readonly width: number;
|
|
117
|
+
readonly height: number;
|
|
118
|
+
}
|
|
119
|
+
/*** Computed visual CSS values needed to describe, not assess, a rendered website. */
|
|
120
|
+
export interface WebsiteComputedCss {
|
|
121
|
+
readonly display: string;
|
|
122
|
+
readonly position: string;
|
|
123
|
+
readonly visibility: string;
|
|
124
|
+
readonly color: string;
|
|
125
|
+
readonly backgroundColor: string;
|
|
126
|
+
readonly borderColor: string;
|
|
127
|
+
readonly borderRadius: string;
|
|
128
|
+
readonly borderWidth: string;
|
|
129
|
+
readonly boxShadow: string;
|
|
130
|
+
readonly fontFamily: string;
|
|
131
|
+
readonly fontSize: string;
|
|
132
|
+
readonly fontStyle: string;
|
|
133
|
+
readonly fontWeight: string;
|
|
134
|
+
readonly letterSpacing: string;
|
|
135
|
+
readonly lineHeight: string;
|
|
136
|
+
readonly textAlign: string;
|
|
137
|
+
readonly textDecoration: string;
|
|
138
|
+
readonly opacity: string;
|
|
139
|
+
readonly overflow: string;
|
|
140
|
+
readonly overflowX: string;
|
|
141
|
+
readonly overflowY: string;
|
|
142
|
+
readonly backgroundImage: string;
|
|
143
|
+
readonly backgroundPosition: string;
|
|
144
|
+
readonly backgroundRepeat: string;
|
|
145
|
+
readonly backgroundSize: string;
|
|
146
|
+
readonly margin: WebsiteBoxEdges;
|
|
147
|
+
readonly padding: WebsiteBoxEdges;
|
|
148
|
+
readonly alignContent: string;
|
|
149
|
+
readonly alignItems: string;
|
|
150
|
+
readonly alignSelf: string;
|
|
151
|
+
readonly gap: string;
|
|
152
|
+
readonly flexDirection: string;
|
|
153
|
+
readonly flexBasis: string;
|
|
154
|
+
readonly flexGrow: string;
|
|
155
|
+
readonly flexShrink: string;
|
|
156
|
+
readonly flexWrap: string;
|
|
157
|
+
readonly justifyContent: string;
|
|
158
|
+
readonly justifyItems: string;
|
|
159
|
+
readonly justifySelf: string;
|
|
160
|
+
readonly order: string;
|
|
161
|
+
readonly placeContent: string;
|
|
162
|
+
readonly placeItems: string;
|
|
163
|
+
readonly placeSelf: string;
|
|
164
|
+
readonly gridAutoColumns: string;
|
|
165
|
+
readonly gridAutoFlow: string;
|
|
166
|
+
readonly gridAutoRows: string;
|
|
167
|
+
readonly gridColumn: string;
|
|
168
|
+
readonly gridColumnEnd: string;
|
|
169
|
+
readonly gridColumnStart: string;
|
|
170
|
+
readonly gridRow: string;
|
|
171
|
+
readonly gridRowEnd: string;
|
|
172
|
+
readonly gridRowStart: string;
|
|
173
|
+
readonly gridTemplateColumns: string;
|
|
174
|
+
readonly gridTemplateRows: string;
|
|
175
|
+
}
|
|
176
|
+
/*** The four computed edges of a CSS box value. */
|
|
177
|
+
export interface WebsiteBoxEdges {
|
|
178
|
+
readonly top: string;
|
|
179
|
+
readonly right: string;
|
|
180
|
+
readonly bottom: string;
|
|
181
|
+
readonly left: string;
|
|
182
|
+
}
|
|
183
|
+
/*** How an observation was obtained from the source page. */
|
|
184
|
+
export interface WebsiteObservationProvenance {
|
|
185
|
+
readonly sourceUrl: string;
|
|
186
|
+
readonly capturedAt: string;
|
|
187
|
+
readonly method: 'browser' | 'html' | 'network';
|
|
188
|
+
}
|
|
189
|
+
/*** A reusable media asset discovered during the crawl. */
|
|
190
|
+
export interface WebsiteAsset {
|
|
191
|
+
readonly id: string;
|
|
192
|
+
readonly url: string;
|
|
193
|
+
readonly kind: WebsiteMediaReference['kind'];
|
|
194
|
+
readonly contentType: string | null;
|
|
195
|
+
readonly sourceRefs: readonly string[];
|
|
196
|
+
}
|
|
197
|
+
/*** A versioned canonical component recognition derived from website observations. */
|
|
198
|
+
export interface WebsiteRecognitionDocument {
|
|
199
|
+
readonly schemaVersion: 1;
|
|
200
|
+
readonly documentId: string;
|
|
201
|
+
readonly observedDocumentId: string;
|
|
202
|
+
readonly recognizedAt: string;
|
|
203
|
+
readonly source: WebsiteSource;
|
|
204
|
+
readonly site: WebsiteSite;
|
|
205
|
+
readonly navigation: readonly WebsiteNavigationItem[];
|
|
206
|
+
readonly pages: readonly WebsitePageRecognition[];
|
|
207
|
+
readonly designTokens: readonly WebsiteDesignToken[];
|
|
208
|
+
readonly media: readonly WebsiteRecognizedMedia[];
|
|
209
|
+
}
|
|
210
|
+
/*** A recognized page with its canonical UiNode tree and retained source mapping. */
|
|
211
|
+
export interface WebsitePageRecognition {
|
|
212
|
+
readonly id: string;
|
|
213
|
+
readonly url: string;
|
|
214
|
+
readonly path: string;
|
|
215
|
+
readonly root: UiNode;
|
|
216
|
+
readonly nodes: readonly WebsiteRecognizedNode[];
|
|
217
|
+
}
|
|
218
|
+
/*** A source-linked canonical UiNode mapping; component shape remains owned by UiNode. */
|
|
219
|
+
export interface WebsiteRecognizedNode {
|
|
220
|
+
readonly id: UiNode['id'];
|
|
221
|
+
readonly componentType: UiNode['type'];
|
|
222
|
+
readonly sourceRefs: readonly string[];
|
|
223
|
+
readonly confidence: number;
|
|
224
|
+
readonly props: readonly WebsiteRecognizedProp[];
|
|
225
|
+
readonly responsive: readonly WebsiteResponsiveVariant[];
|
|
226
|
+
readonly status: 'recognized' | 'unresolved';
|
|
227
|
+
readonly unresolved: WebsiteUnresolvedNode | null;
|
|
228
|
+
}
|
|
229
|
+
/*** A normalized UiNode property and the exact serializable values observed before normalization. */
|
|
230
|
+
export interface WebsiteRecognizedProp {
|
|
231
|
+
readonly name: string;
|
|
232
|
+
readonly value: SerializableValue;
|
|
233
|
+
readonly originalValues: readonly SerializableValue[];
|
|
234
|
+
}
|
|
235
|
+
/*** A viewport-specific UiNode property override retained by the recognition. */
|
|
236
|
+
export interface WebsiteResponsiveVariant {
|
|
237
|
+
readonly viewportId: string;
|
|
238
|
+
readonly props: readonly WebsiteRecognizedProp[];
|
|
239
|
+
}
|
|
240
|
+
/*** A visible source node that could not be mapped without silently discarding it. */
|
|
241
|
+
export interface WebsiteUnresolvedNode {
|
|
242
|
+
readonly reason: string;
|
|
243
|
+
readonly sourceRefs: readonly string[];
|
|
244
|
+
}
|
|
245
|
+
/*** A normalized design token with its exact source values retained. */
|
|
246
|
+
export interface WebsiteDesignToken {
|
|
247
|
+
readonly id: string;
|
|
248
|
+
readonly kind: 'color' | 'radius' | 'shadow' | 'spacing' | 'typography';
|
|
249
|
+
readonly value: SerializableValue;
|
|
250
|
+
readonly originalValues: readonly SerializableValue[];
|
|
251
|
+
readonly sourceRefs: readonly string[];
|
|
252
|
+
}
|
|
253
|
+
/*** A recognized portable media reference, optionally compatible with an app media asset. */
|
|
254
|
+
export interface WebsiteRecognizedMedia {
|
|
255
|
+
readonly id: string;
|
|
256
|
+
readonly sourceRefs: readonly string[];
|
|
257
|
+
readonly originalUrl: string;
|
|
258
|
+
readonly asset: MediaAssetReference | null;
|
|
259
|
+
}
|
|
260
|
+
//# sourceMappingURL=website.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"website.d.ts","sourceRoot":"","sources":["../src/website.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AACtD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAC3D,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,YAAY,CAAC;AAEzC,6EAA6E;AAC7E,MAAM,WAAW,0BAA0B;IACzC,QAAQ,CAAC,aAAa,EAAE,CAAC,CAAC;IAC1B,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,MAAM,EAAE,aAAa,CAAC;IAC/B,QAAQ,CAAC,IAAI,EAAE,WAAW,CAAC;IAC3B,QAAQ,CAAC,KAAK,EAAE,SAAS,s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,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,UAAU,EAAE,SAAS,MAAM,EAAE,CAAC;CACxC;AAED,wEAAwE;AACxE,MAAM,WAAW,kBAAkB;IACjC,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,IAAI,EAAE,OAAO,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,YAAY,CAAC;IACxE,QAAQ,CAAC,KAAK,EAAE,iBAAiB,CAAC;IAClC,QAAQ,CAAC,cAAc,EAAE,SAAS,iBAAiB,EAAE,CAAC;IACtD,QAAQ,CAAC,UAAU,EAAE,SAAS,MAAM,EAAE,CAAC;CACxC;AAED,6FAA6F;AAC7F,MAAM,WAAW,sBAAsB;IACrC,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,UAAU,EAAE,SAAS,MAAM,EAAE,CAAC;IACvC,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,KAAK,EAAE,mBAAmB,GAAG,IAAI,CAAC;CAC5C"}
|
package/dist/website.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"website.js","sourceRoot":"","sources":["../src/website.ts"],"names":[],"mappings":"","sourcesContent":["import type { MediaAssetReference } from './media.js';\nimport type { SerializableValue } from './serializable.js';\nimport type { UiNode } from './types.js';\n\n/*** A versioned, portable capture of the observable state of one website. */\nexport interface WebsiteObservationDocument {\n readonly schemaVersion: 1;\n readonly documentId: string;\n readonly collectedAt: string;\n readonly source: WebsiteSource;\n readonly site: WebsiteSite;\n readonly pages: readonly WebsitePageObservation[];\n}\n\n/*** The scraper identity and immutable crawl revision that produced a website document. */\nexport interface WebsiteSource {\n readonly crawlerId: string;\n readonly crawlerVersion: string;\n readonly crawlId: string;\n readonly revision: string | null;\n}\n\n/*** A site identity and its canonical entry URL. */\nexport interface WebsiteSite {\n readonly id: string;\n readonly url: string;\n}\n\n/*** One observed page, including its ordered navigation and captured render states. */\nexport interface WebsitePageObservation {\n readonly id: string;\n readonly url: string;\n readonly path: string;\n readonly navigation: readonly WebsiteNavigationItem[];\n readonly viewports: readonly WebsiteViewport[];\n readonly states: readonly WebsiteState[];\n readonly nodes: readonly WebsiteObservedNode[];\n readonly assets: readonly WebsiteAsset[];\n}\n\n/*** One ordered, source-linked navigation target observed on a page. */\nexport interface WebsiteNavigationItem {\n readonly id: string;\n readonly label: string;\n readonly url: string;\n readonly sourceRef: string;\n}\n\n/*** A rendered viewport used while observing responsive website state. */\nexport interface WebsiteViewport {\n readonly id: string;\n readonly width: number;\n readonly height: number;\n readonly devicePixelRatio: number;\n}\n\n/*** A named rendered state, such as default, hover, or expanded. */\nexport interface WebsiteState {\n readonly id: string;\n readonly name: string;\n}\n\n/*** A stable DOM node and every source-linked observation collected for it. */\nexport interface WebsiteObservedNode {\n readonly sourceRef: string;\n readonly parentSourceRef: string | null;\n readonly ancestorSourceRefs: readonly string[];\n readonly dom: WebsiteDomNode;\n readonly textRuns: readonly WebsiteTextRun[];\n readonly links: readonly WebsiteLink[];\n readonly media: readonly WebsiteMediaReference[];\n readonly observations: readonly WebsiteNodeObservation[];\n}\n\n/*** A portable DOM identity with safe semantic attributes only. */\nexport interface WebsiteDomNode {\n readonly tagName: string;\n readonly childIndex: number;\n readonly attributes: Readonly<Record<string, string>>;\n}\n\n/*** A text run retained separately from its DOM node so inline styled spans are not lost. */\nexport interface WebsiteTextRun {\n readonly sourceRef: string;\n readonly text: string;\n readonly start: number;\n readonly end: number;\n}\n\n/*** A source-linked hyperlink observed on a DOM node. */\nexport interface WebsiteLink {\n readonly sourceRef: string;\n readonly url: string;\n readonly label: string | null;\n}\n\n/*** An image, video, audio, or embedded media reference observed on a DOM node. */\nexport interface WebsiteMediaReference {\n readonly sourceRef: string;\n readonly assetId: string | null;\n readonly url: string;\n readonly kind: 'audio' | 'document' | 'embed' | 'image' | 'video';\n readonly alt: string | null;\n}\n\n/*** One viewport/state-specific visual observation of a DOM node. */\nexport interface WebsiteNodeObservation {\n readonly viewportId: string;\n readonly stateId: string;\n readonly availability: WebsiteAvailability;\n readonly rect: WebsiteBoundingRect | null;\n readonly css: WebsiteComputedCss | null;\n readonly provenance: WebsiteObservationProvenance;\n}\n\n/*** Whether a source value was available without fabricating a replacement. */\nexport interface WebsiteAvailability {\n readonly status: 'available' | 'missing';\n readonly missing: WebsiteMissingValue | null;\n}\n\n/*** The explicit reason a website source value could not be observed. */\nexport interface WebsiteMissingValue {\n readonly code: string;\n readonly message: string;\n}\n\n/*** A bounding rectangle measured in CSS pixels. */\nexport interface WebsiteBoundingRect {\n readonly x: number;\n readonly y: number;\n readonly width: number;\n readonly height: number;\n}\n\n/*** Computed visual CSS values needed to describe, not assess, a rendered website. */\nexport interface WebsiteComputedCss {\n readonly display: string;\n readonly position: string;\n readonly visibility: string;\n readonly color: string;\n readonly backgroundColor: string;\n readonly borderColor: string;\n readonly borderRadius: string;\n readonly borderWidth: string;\n readonly boxShadow: string;\n readonly fontFamily: string;\n readonly fontSize: string;\n readonly fontStyle: string;\n readonly fontWeight: string;\n readonly letterSpacing: string;\n readonly lineHeight: string;\n readonly textAlign: string;\n readonly textDecoration: string;\n readonly opacity: string;\n readonly overflow: string;\n readonly overflowX: string;\n readonly overflowY: string;\n readonly backgroundImage: string;\n readonly backgroundPosition: string;\n readonly backgroundRepeat: string;\n readonly backgroundSize: string;\n readonly margin: WebsiteBoxEdges;\n readonly padding: WebsiteBoxEdges;\n readonly alignContent: string;\n readonly alignItems: string;\n readonly alignSelf: string;\n readonly gap: string;\n readonly flexDirection: string;\n readonly flexBasis: string;\n readonly flexGrow: string;\n readonly flexShrink: string;\n readonly flexWrap: string;\n readonly justifyContent: string;\n readonly justifyItems: string;\n readonly justifySelf: string;\n readonly order: string;\n readonly placeContent: string;\n readonly placeItems: string;\n readonly placeSelf: string;\n readonly gridAutoColumns: string;\n readonly gridAutoFlow: string;\n readonly gridAutoRows: string;\n readonly gridColumn: string;\n readonly gridColumnEnd: string;\n readonly gridColumnStart: string;\n readonly gridRow: string;\n readonly gridRowEnd: string;\n readonly gridRowStart: string;\n readonly gridTemplateColumns: string;\n readonly gridTemplateRows: string;\n}\n\n/*** The four computed edges of a CSS box value. */\nexport interface WebsiteBoxEdges {\n readonly top: string;\n readonly right: string;\n readonly bottom: string;\n readonly left: string;\n}\n\n/*** How an observation was obtained from the source page. */\nexport interface WebsiteObservationProvenance {\n readonly sourceUrl: string;\n readonly capturedAt: string;\n readonly method: 'browser' | 'html' | 'network';\n}\n\n/*** A reusable media asset discovered during the crawl. */\nexport interface WebsiteAsset {\n readonly id: string;\n readonly url: string;\n readonly kind: WebsiteMediaReference['kind'];\n readonly contentType: string | null;\n readonly sourceRefs: readonly string[];\n}\n\n/*** A versioned canonical component recognition derived from website observations. */\nexport interface WebsiteRecognitionDocument {\n readonly schemaVersion: 1;\n readonly documentId: string;\n readonly observedDocumentId: string;\n readonly recognizedAt: string;\n readonly source: WebsiteSource;\n readonly site: WebsiteSite;\n readonly navigation: readonly WebsiteNavigationItem[];\n readonly pages: readonly WebsitePageRecognition[];\n readonly designTokens: readonly WebsiteDesignToken[];\n readonly media: readonly WebsiteRecognizedMedia[];\n}\n\n/*** A recognized page with its canonical UiNode tree and retained source mapping. */\nexport interface WebsitePageRecognition {\n readonly id: string;\n readonly url: string;\n readonly path: string;\n readonly root: UiNode;\n readonly nodes: readonly WebsiteRecognizedNode[];\n}\n\n/*** A source-linked canonical UiNode mapping; component shape remains owned by UiNode. */\nexport interface WebsiteRecognizedNode {\n readonly id: UiNode['id'];\n readonly componentType: UiNode['type'];\n readonly sourceRefs: readonly string[];\n readonly confidence: number;\n readonly props: readonly WebsiteRecognizedProp[];\n readonly responsive: readonly WebsiteResponsiveVariant[];\n readonly status: 'recognized' | 'unresolved';\n readonly unresolved: WebsiteUnresolvedNode | null;\n}\n\n/*** A normalized UiNode property and the exact serializable values observed before normalization. */\nexport interface WebsiteRecognizedProp {\n readonly name: string;\n readonly value: SerializableValue;\n readonly originalValues: readonly SerializableValue[];\n}\n\n/*** A viewport-specific UiNode property override retained by the recognition. */\nexport interface WebsiteResponsiveVariant {\n readonly viewportId: string;\n readonly props: readonly WebsiteRecognizedProp[];\n}\n\n/*** A visible source node that could not be mapped without silently discarding it. */\nexport interface WebsiteUnresolvedNode {\n readonly reason: string;\n readonly sourceRefs: readonly string[];\n}\n\n/*** A normalized design token with its exact source values retained. */\nexport interface WebsiteDesignToken {\n readonly id: string;\n readonly kind: 'color' | 'radius' | 'shadow' | 'spacing' | 'typography';\n readonly value: SerializableValue;\n readonly originalValues: readonly SerializableValue[];\n readonly sourceRefs: readonly string[];\n}\n\n/*** A recognized portable media reference, optionally compatible with an app media asset. */\nexport interface WebsiteRecognizedMedia {\n readonly id: string;\n readonly sourceRefs: readonly string[];\n readonly originalUrl: string;\n readonly asset: MediaAssetReference | null;\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ankhorage/contracts",
|
|
3
|
-
"version": "26.
|
|
3
|
+
"version": "26.6.0",
|
|
4
4
|
"main": "./dist/index.js",
|
|
5
5
|
"ankh": {
|
|
6
6
|
"category": "contracts",
|
|
@@ -115,6 +115,10 @@
|
|
|
115
115
|
"types": "./dist/ui.d.ts",
|
|
116
116
|
"default": "./dist/ui.js"
|
|
117
117
|
},
|
|
118
|
+
"./website": {
|
|
119
|
+
"types": "./dist/website.d.ts",
|
|
120
|
+
"default": "./dist/website.js"
|
|
121
|
+
},
|
|
118
122
|
"./media": {
|
|
119
123
|
"types": "./dist/media.d.ts",
|
|
120
124
|
"default": "./dist/media.js"
|
package/src/index.ts
CHANGED
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
import type { StructureDescriptorDocument } from '@ankhorage/contracts/structure';
|
|
3
3
|
|
|
4
4
|
export const STRUCTURE_DESCRIPTOR_COMPILER_VERSION = '6.0.3';
|
|
5
|
-
export const STRUCTURE_DESCRIPTOR_FINGERPRINT = 'sha256:
|
|
5
|
+
export const STRUCTURE_DESCRIPTOR_FINGERPRINT = 'sha256:dd8057c752c877b62bdc5c8db41135bd76c55dedf9bf4e1a13d7bf977f9cca56';
|
|
6
6
|
|
|
7
7
|
export const STRUCTURE_DESCRIPTOR = {
|
|
8
8
|
"protocolVersion": 1,
|
|
9
9
|
"packageName": "@ankhorage/contracts",
|
|
10
|
-
"packageVersion": "26.
|
|
10
|
+
"packageVersion": "26.6.0",
|
|
11
11
|
"roots": {
|
|
12
12
|
"auth-flow": "AuthFlowConfig",
|
|
13
13
|
"auth-profile": "AuthProfileSpec",
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { expect, it } from 'bun:test';
|
|
2
|
+
|
|
3
|
+
import phpObservation from '../test/website/fixtures/php-observation.json' with { type: 'json' };
|
|
4
|
+
import phpRecognition from '../test/website/fixtures/php-recognition.json' with { type: 'json' };
|
|
5
|
+
import typescriptObservation from '../test/website/fixtures/typescript-observation.json' with { type: 'json' };
|
|
6
|
+
import typescriptRecognition from '../test/website/fixtures/typescript-recognition.json' with { type: 'json' };
|
|
7
|
+
import type { WebsiteObservationDocument, WebsiteRecognitionDocument } from './website.js';
|
|
8
|
+
|
|
9
|
+
const websiteObservationFixture = typescriptObservation as unknown as WebsiteObservationDocument;
|
|
10
|
+
const websiteRecognitionFixture = typescriptRecognition as unknown as WebsiteRecognitionDocument;
|
|
11
|
+
|
|
12
|
+
it('keeps TypeScript and PHP website observation fixtures identical and serializable', () => {
|
|
13
|
+
expect(typescriptObservation).toEqual(phpObservation);
|
|
14
|
+
expect(typescriptObservation.pages).toHaveLength(2);
|
|
15
|
+
expect(typescriptObservation.pages[0]?.viewports).toHaveLength(3);
|
|
16
|
+
expect(JSON.parse(JSON.stringify(websiteObservationFixture))).toEqual(websiteObservationFixture);
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
it('keeps TypeScript and PHP website recognition fixtures identical and serializable', () => {
|
|
20
|
+
expect(typescriptRecognition).toEqual(phpRecognition);
|
|
21
|
+
expect(typescriptRecognition.pages[0]?.root.children).toHaveLength(4);
|
|
22
|
+
expect(JSON.parse(JSON.stringify(websiteRecognitionFixture))).toEqual(websiteRecognitionFixture);
|
|
23
|
+
});
|
|
24
|
+
|
|
25
|
+
it('retains the visible unresolved node and the styled inline text run', () => {
|
|
26
|
+
expect(
|
|
27
|
+
websiteObservationFixture.pages[0]?.nodes.find((node) => node.sourceRef === 'home:hero:span'),
|
|
28
|
+
).toMatchObject({ textRuns: [{ text: 'red styled text' }] });
|
|
29
|
+
expect(
|
|
30
|
+
websiteRecognitionFixture.pages[0]?.nodes.find((node) => node.status === 'unresolved'),
|
|
31
|
+
).toMatchObject({ sourceRefs: ['home:visible-unresolved'] });
|
|
32
|
+
expect(websiteRecognitionFixture.pages[0]?.root.children?.at(-1)).toMatchObject({
|
|
33
|
+
id: 'home:visible-unresolved',
|
|
34
|
+
});
|
|
35
|
+
expect(websiteRecognitionFixture.pages[0]?.root.children?.[0]?.children?.[1]).toMatchObject({
|
|
36
|
+
id: 'home:rich-text',
|
|
37
|
+
type: 'RichText',
|
|
38
|
+
});
|
|
39
|
+
});
|
package/src/website.ts
ADDED
|
@@ -0,0 +1,287 @@
|
|
|
1
|
+
import type { MediaAssetReference } from './media.js';
|
|
2
|
+
import type { SerializableValue } from './serializable.js';
|
|
3
|
+
import type { UiNode } from './types.js';
|
|
4
|
+
|
|
5
|
+
/*** A versioned, portable capture of the observable state of one website. */
|
|
6
|
+
export interface WebsiteObservationDocument {
|
|
7
|
+
readonly schemaVersion: 1;
|
|
8
|
+
readonly documentId: string;
|
|
9
|
+
readonly collectedAt: string;
|
|
10
|
+
readonly source: WebsiteSource;
|
|
11
|
+
readonly site: WebsiteSite;
|
|
12
|
+
readonly pages: readonly WebsitePageObservation[];
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
/*** The scraper identity and immutable crawl revision that produced a website document. */
|
|
16
|
+
export interface WebsiteSource {
|
|
17
|
+
readonly crawlerId: string;
|
|
18
|
+
readonly crawlerVersion: string;
|
|
19
|
+
readonly crawlId: string;
|
|
20
|
+
readonly revision: string | null;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
/*** A site identity and its canonical entry URL. */
|
|
24
|
+
export interface WebsiteSite {
|
|
25
|
+
readonly id: string;
|
|
26
|
+
readonly url: string;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/*** One observed page, including its ordered navigation and captured render states. */
|
|
30
|
+
export interface WebsitePageObservation {
|
|
31
|
+
readonly id: string;
|
|
32
|
+
readonly url: string;
|
|
33
|
+
readonly path: string;
|
|
34
|
+
readonly navigation: readonly WebsiteNavigationItem[];
|
|
35
|
+
readonly viewports: readonly WebsiteViewport[];
|
|
36
|
+
readonly states: readonly WebsiteState[];
|
|
37
|
+
readonly nodes: readonly WebsiteObservedNode[];
|
|
38
|
+
readonly assets: readonly WebsiteAsset[];
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
/*** One ordered, source-linked navigation target observed on a page. */
|
|
42
|
+
export interface WebsiteNavigationItem {
|
|
43
|
+
readonly id: string;
|
|
44
|
+
readonly label: string;
|
|
45
|
+
readonly url: string;
|
|
46
|
+
readonly sourceRef: string;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/*** A rendered viewport used while observing responsive website state. */
|
|
50
|
+
export interface WebsiteViewport {
|
|
51
|
+
readonly id: string;
|
|
52
|
+
readonly width: number;
|
|
53
|
+
readonly height: number;
|
|
54
|
+
readonly devicePixelRatio: number;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
/*** A named rendered state, such as default, hover, or expanded. */
|
|
58
|
+
export interface WebsiteState {
|
|
59
|
+
readonly id: string;
|
|
60
|
+
readonly name: string;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
/*** A stable DOM node and every source-linked observation collected for it. */
|
|
64
|
+
export interface WebsiteObservedNode {
|
|
65
|
+
readonly sourceRef: string;
|
|
66
|
+
readonly parentSourceRef: string | null;
|
|
67
|
+
readonly ancestorSourceRefs: readonly string[];
|
|
68
|
+
readonly dom: WebsiteDomNode;
|
|
69
|
+
readonly textRuns: readonly WebsiteTextRun[];
|
|
70
|
+
readonly links: readonly WebsiteLink[];
|
|
71
|
+
readonly media: readonly WebsiteMediaReference[];
|
|
72
|
+
readonly observations: readonly WebsiteNodeObservation[];
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
/*** A portable DOM identity with safe semantic attributes only. */
|
|
76
|
+
export interface WebsiteDomNode {
|
|
77
|
+
readonly tagName: string;
|
|
78
|
+
readonly childIndex: number;
|
|
79
|
+
readonly attributes: Readonly<Record<string, string>>;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
/*** A text run retained separately from its DOM node so inline styled spans are not lost. */
|
|
83
|
+
export interface WebsiteTextRun {
|
|
84
|
+
readonly sourceRef: string;
|
|
85
|
+
readonly text: string;
|
|
86
|
+
readonly start: number;
|
|
87
|
+
readonly end: number;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
/*** A source-linked hyperlink observed on a DOM node. */
|
|
91
|
+
export interface WebsiteLink {
|
|
92
|
+
readonly sourceRef: string;
|
|
93
|
+
readonly url: string;
|
|
94
|
+
readonly label: string | null;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
/*** An image, video, audio, or embedded media reference observed on a DOM node. */
|
|
98
|
+
export interface WebsiteMediaReference {
|
|
99
|
+
readonly sourceRef: string;
|
|
100
|
+
readonly assetId: string | null;
|
|
101
|
+
readonly url: string;
|
|
102
|
+
readonly kind: 'audio' | 'document' | 'embed' | 'image' | 'video';
|
|
103
|
+
readonly alt: string | null;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
/*** One viewport/state-specific visual observation of a DOM node. */
|
|
107
|
+
export interface WebsiteNodeObservation {
|
|
108
|
+
readonly viewportId: string;
|
|
109
|
+
readonly stateId: string;
|
|
110
|
+
readonly availability: WebsiteAvailability;
|
|
111
|
+
readonly rect: WebsiteBoundingRect | null;
|
|
112
|
+
readonly css: WebsiteComputedCss | null;
|
|
113
|
+
readonly provenance: WebsiteObservationProvenance;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
/*** Whether a source value was available without fabricating a replacement. */
|
|
117
|
+
export interface WebsiteAvailability {
|
|
118
|
+
readonly status: 'available' | 'missing';
|
|
119
|
+
readonly missing: WebsiteMissingValue | null;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
/*** The explicit reason a website source value could not be observed. */
|
|
123
|
+
export interface WebsiteMissingValue {
|
|
124
|
+
readonly code: string;
|
|
125
|
+
readonly message: string;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
/*** A bounding rectangle measured in CSS pixels. */
|
|
129
|
+
export interface WebsiteBoundingRect {
|
|
130
|
+
readonly x: number;
|
|
131
|
+
readonly y: number;
|
|
132
|
+
readonly width: number;
|
|
133
|
+
readonly height: number;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
/*** Computed visual CSS values needed to describe, not assess, a rendered website. */
|
|
137
|
+
export interface WebsiteComputedCss {
|
|
138
|
+
readonly display: string;
|
|
139
|
+
readonly position: string;
|
|
140
|
+
readonly visibility: string;
|
|
141
|
+
readonly color: string;
|
|
142
|
+
readonly backgroundColor: string;
|
|
143
|
+
readonly borderColor: string;
|
|
144
|
+
readonly borderRadius: string;
|
|
145
|
+
readonly borderWidth: string;
|
|
146
|
+
readonly boxShadow: string;
|
|
147
|
+
readonly fontFamily: string;
|
|
148
|
+
readonly fontSize: string;
|
|
149
|
+
readonly fontStyle: string;
|
|
150
|
+
readonly fontWeight: string;
|
|
151
|
+
readonly letterSpacing: string;
|
|
152
|
+
readonly lineHeight: string;
|
|
153
|
+
readonly textAlign: string;
|
|
154
|
+
readonly textDecoration: string;
|
|
155
|
+
readonly opacity: string;
|
|
156
|
+
readonly overflow: string;
|
|
157
|
+
readonly overflowX: string;
|
|
158
|
+
readonly overflowY: string;
|
|
159
|
+
readonly backgroundImage: string;
|
|
160
|
+
readonly backgroundPosition: string;
|
|
161
|
+
readonly backgroundRepeat: string;
|
|
162
|
+
readonly backgroundSize: string;
|
|
163
|
+
readonly margin: WebsiteBoxEdges;
|
|
164
|
+
readonly padding: WebsiteBoxEdges;
|
|
165
|
+
readonly alignContent: string;
|
|
166
|
+
readonly alignItems: string;
|
|
167
|
+
readonly alignSelf: string;
|
|
168
|
+
readonly gap: string;
|
|
169
|
+
readonly flexDirection: string;
|
|
170
|
+
readonly flexBasis: string;
|
|
171
|
+
readonly flexGrow: string;
|
|
172
|
+
readonly flexShrink: string;
|
|
173
|
+
readonly flexWrap: string;
|
|
174
|
+
readonly justifyContent: string;
|
|
175
|
+
readonly justifyItems: string;
|
|
176
|
+
readonly justifySelf: string;
|
|
177
|
+
readonly order: string;
|
|
178
|
+
readonly placeContent: string;
|
|
179
|
+
readonly placeItems: string;
|
|
180
|
+
readonly placeSelf: string;
|
|
181
|
+
readonly gridAutoColumns: string;
|
|
182
|
+
readonly gridAutoFlow: string;
|
|
183
|
+
readonly gridAutoRows: string;
|
|
184
|
+
readonly gridColumn: string;
|
|
185
|
+
readonly gridColumnEnd: string;
|
|
186
|
+
readonly gridColumnStart: string;
|
|
187
|
+
readonly gridRow: string;
|
|
188
|
+
readonly gridRowEnd: string;
|
|
189
|
+
readonly gridRowStart: string;
|
|
190
|
+
readonly gridTemplateColumns: string;
|
|
191
|
+
readonly gridTemplateRows: string;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
/*** The four computed edges of a CSS box value. */
|
|
195
|
+
export interface WebsiteBoxEdges {
|
|
196
|
+
readonly top: string;
|
|
197
|
+
readonly right: string;
|
|
198
|
+
readonly bottom: string;
|
|
199
|
+
readonly left: string;
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
/*** How an observation was obtained from the source page. */
|
|
203
|
+
export interface WebsiteObservationProvenance {
|
|
204
|
+
readonly sourceUrl: string;
|
|
205
|
+
readonly capturedAt: string;
|
|
206
|
+
readonly method: 'browser' | 'html' | 'network';
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
/*** A reusable media asset discovered during the crawl. */
|
|
210
|
+
export interface WebsiteAsset {
|
|
211
|
+
readonly id: string;
|
|
212
|
+
readonly url: string;
|
|
213
|
+
readonly kind: WebsiteMediaReference['kind'];
|
|
214
|
+
readonly contentType: string | null;
|
|
215
|
+
readonly sourceRefs: readonly string[];
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
/*** A versioned canonical component recognition derived from website observations. */
|
|
219
|
+
export interface WebsiteRecognitionDocument {
|
|
220
|
+
readonly schemaVersion: 1;
|
|
221
|
+
readonly documentId: string;
|
|
222
|
+
readonly observedDocumentId: string;
|
|
223
|
+
readonly recognizedAt: string;
|
|
224
|
+
readonly source: WebsiteSource;
|
|
225
|
+
readonly site: WebsiteSite;
|
|
226
|
+
readonly navigation: readonly WebsiteNavigationItem[];
|
|
227
|
+
readonly pages: readonly WebsitePageRecognition[];
|
|
228
|
+
readonly designTokens: readonly WebsiteDesignToken[];
|
|
229
|
+
readonly media: readonly WebsiteRecognizedMedia[];
|
|
230
|
+
}
|
|
231
|
+
|
|
232
|
+
/*** A recognized page with its canonical UiNode tree and retained source mapping. */
|
|
233
|
+
export interface WebsitePageRecognition {
|
|
234
|
+
readonly id: string;
|
|
235
|
+
readonly url: string;
|
|
236
|
+
readonly path: string;
|
|
237
|
+
readonly root: UiNode;
|
|
238
|
+
readonly nodes: readonly WebsiteRecognizedNode[];
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
/*** A source-linked canonical UiNode mapping; component shape remains owned by UiNode. */
|
|
242
|
+
export interface WebsiteRecognizedNode {
|
|
243
|
+
readonly id: UiNode['id'];
|
|
244
|
+
readonly componentType: UiNode['type'];
|
|
245
|
+
readonly sourceRefs: readonly string[];
|
|
246
|
+
readonly confidence: number;
|
|
247
|
+
readonly props: readonly WebsiteRecognizedProp[];
|
|
248
|
+
readonly responsive: readonly WebsiteResponsiveVariant[];
|
|
249
|
+
readonly status: 'recognized' | 'unresolved';
|
|
250
|
+
readonly unresolved: WebsiteUnresolvedNode | null;
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
/*** A normalized UiNode property and the exact serializable values observed before normalization. */
|
|
254
|
+
export interface WebsiteRecognizedProp {
|
|
255
|
+
readonly name: string;
|
|
256
|
+
readonly value: SerializableValue;
|
|
257
|
+
readonly originalValues: readonly SerializableValue[];
|
|
258
|
+
}
|
|
259
|
+
|
|
260
|
+
/*** A viewport-specific UiNode property override retained by the recognition. */
|
|
261
|
+
export interface WebsiteResponsiveVariant {
|
|
262
|
+
readonly viewportId: string;
|
|
263
|
+
readonly props: readonly WebsiteRecognizedProp[];
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
/*** A visible source node that could not be mapped without silently discarding it. */
|
|
267
|
+
export interface WebsiteUnresolvedNode {
|
|
268
|
+
readonly reason: string;
|
|
269
|
+
readonly sourceRefs: readonly string[];
|
|
270
|
+
}
|
|
271
|
+
|
|
272
|
+
/*** A normalized design token with its exact source values retained. */
|
|
273
|
+
export interface WebsiteDesignToken {
|
|
274
|
+
readonly id: string;
|
|
275
|
+
readonly kind: 'color' | 'radius' | 'shadow' | 'spacing' | 'typography';
|
|
276
|
+
readonly value: SerializableValue;
|
|
277
|
+
readonly originalValues: readonly SerializableValue[];
|
|
278
|
+
readonly sourceRefs: readonly string[];
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
/*** A recognized portable media reference, optionally compatible with an app media asset. */
|
|
282
|
+
export interface WebsiteRecognizedMedia {
|
|
283
|
+
readonly id: string;
|
|
284
|
+
readonly sourceRefs: readonly string[];
|
|
285
|
+
readonly originalUrl: string;
|
|
286
|
+
readonly asset: MediaAssetReference | null;
|
|
287
|
+
}
|