@yahoo/uds-create-config 5.32.3 → 5.32.4

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.
@@ -30,8 +30,8 @@ type WebActivation = (typeof WEB_ACTIVATIONS)[number];
30
30
  */
31
31
  declare const modifierGroupFields: z.ZodObject<{
32
32
  type: z.ZodOptional<z.ZodEnum<{
33
- mode: "mode";
34
33
  state: "state";
34
+ mode: "mode";
35
35
  }>>;
36
36
  default: z.ZodOptional<z.ZodObject<{
37
37
  __ref: z.ZodString;
@@ -53,8 +53,8 @@ declare const ModifierDefinition: EntityClass<z.ZodObject<{
53
53
  declarations: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
54
54
  }, z.core.$strip>, z.ZodObject<{
55
55
  type: z.ZodOptional<z.ZodEnum<{
56
- mode: "mode";
57
56
  state: "state";
57
+ mode: "mode";
58
58
  }>>;
59
59
  default: z.ZodOptional<z.ZodObject<{
60
60
  __ref: z.ZodString;
@@ -11,9 +11,9 @@ import { z } from "zod";
11
11
  */
12
12
  declare const inlineJsMotion: z.ZodObject<{
13
13
  transition: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
14
+ initial: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodString, z.ZodArray<z.ZodString>, z.ZodLiteral<false>]>>;
14
15
  exit: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodString, z.ZodArray<z.ZodString>]>>;
15
16
  layout: z.ZodOptional<z.ZodUnion<readonly [z.ZodBoolean, z.ZodLiteral<"position">, z.ZodLiteral<"size">, z.ZodLiteral<"preserve-aspect">]>>;
16
- initial: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodString, z.ZodArray<z.ZodString>, z.ZodLiteral<false>]>>;
17
17
  variants: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
18
18
  animate: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodString, z.ZodArray<z.ZodString>]>>;
19
19
  whileHover: z.ZodOptional<z.ZodUnion<readonly [z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodString, z.ZodArray<z.ZodString>]>>;
@@ -2,8 +2,8 @@ import { splitRef } from "../../framework/utils/refs.js";
2
2
  import { defineEntity } from "../../framework/defineEntity.js";
3
3
  import { defineSubEntity } from "../../framework/defineSubEntity.js";
4
4
  import { createSliceMemo } from "../../framework/memo.js";
5
- import { buildFields } from "../../configs/build-options.js";
6
5
  import { parseRootFontSize } from "../../css/root-font-size.js";
6
+ import { buildFields } from "../../configs/build-options.js";
7
7
  import { resolveInputDir } from "../../framework/registry-dir.js";
8
8
  import { safelistSchema } from "./safelist.js";
9
9
  import { z } from "zod";
@@ -3,9 +3,9 @@ import { composedValueSchemas } from "./composed-values.js";
3
3
  import { defineEntity } from "../../framework/defineEntity.js";
4
4
  import { defineSubEntity, orList } from "../../framework/defineSubEntity.js";
5
5
  import { Font } from "./Font.js";
6
- import { Modifier } from "./Modifier.js";
7
- import { spellTokenRead } from "./token-values.js";
8
6
  import { WEB_CONFIG_NAME } from "../../configs/platform.js";
7
+ import { spellTokenRead } from "./token-values.js";
8
+ import { Modifier } from "./Modifier.js";
9
9
  import { authoringPhantom } from "../../framework/utils/authoring-phantom.js";
10
10
  import { prepareLinkedTokenBody } from "./linked-token-values.js";
11
11
  import { z } from "zod";
@@ -119,12 +119,13 @@ function defineOverride(value) {
119
119
  const Override = defineOverride(tokenValue);
120
120
  const TokenEntity = defineEntity({
121
121
  kind: "token",
122
- prepareLinkedBody: ({ path, body, source, config }) => prepareLinkedTokenBody({
122
+ prepareLinkedBody: ({ path, body, source, config, extend }) => prepareLinkedTokenBody({
123
123
  path,
124
124
  body,
125
125
  source,
126
126
  config,
127
- destinationPlatform: WEB_CONFIG_NAME
127
+ destinationPlatform: WEB_CONFIG_NAME,
128
+ extend
128
129
  }),
129
130
  fields: z.object({
130
131
  value: tokenValue.describe("The base value: a literal, a ref to another token, or a composed value such as a gradient."),
@@ -1,8 +1,8 @@
1
1
  import { isRef, kindOf, pathOf, ref, routedSource, sourceHops, splitRef } from "../../framework/utils/refs.js";
2
2
  import { createSliceMemo } from "../../framework/memo.js";
3
+ import { isNativeConfig } from "../../configs/platform.js";
3
4
  import { Settings, classPrefixOf, prefixed, varPrefixOf } from "./Settings.js";
4
5
  import { File } from "./File.js";
5
- import { isNativeConfig } from "../../configs/platform.js";
6
6
  import { Component } from "./Component.js";
7
7
  import { contentKey } from "../../framework/utils/content-key.js";
8
8
  //#region src/entities/system/component-module.ts
@@ -0,0 +1,19 @@
1
+ import { z } from "zod";
2
+
3
+ //#region src/entities/system/linked-flex-values.d.ts
4
+ /** Native has no flex shorthand string. Its equivalent is these three style declarations. */
5
+ declare const nativeFlexValue: z.ZodObject<{
6
+ flexGrow: z.ZodNumber;
7
+ flexShrink: z.ZodNumber;
8
+ flexBasis: z.ZodUnion<readonly [z.ZodNumber, z.ZodLiteral<"auto">, z.ZodString]>;
9
+ }, z.core.$strict>;
10
+ type NativeFlexValue = z.infer<typeof nativeFlexValue>;
11
+ declare function isNativeFlexValue(value: unknown): value is NativeFlexValue;
12
+ /** The supported CSS flex grammar, resolved to RN longhands without losing its basis or shrink. */
13
+ declare function webFlexToNative(value: string | number, remBase?: number): NativeFlexValue;
14
+ /** RN numeric flex is not CSS numeric flex: Yoga's native defaults use shrink=0, and positive
15
+ * numbers use a 0pt basis. Negative flex supplies shrink while retaining auto basis.
16
+ * See Yoga Node::resolveFlexGrow/resolveFlexShrink/processFlexBasis with useWebDefaults=false. */
17
+ declare function nativeFlexToWeb(value: NativeFlexValue | number): string;
18
+ //#endregion
19
+ export { NativeFlexValue, isNativeFlexValue, nativeFlexToWeb, webFlexToNative };
@@ -0,0 +1,77 @@
1
+ import { z } from "zod";
2
+ //#region src/entities/system/linked-flex-values.ts
3
+ /** Native has no flex shorthand string. Its equivalent is these three style declarations. */
4
+ const nativeFlexValue = z.strictObject({
5
+ flexGrow: z.number().nonnegative(),
6
+ flexShrink: z.number().nonnegative(),
7
+ flexBasis: z.union([
8
+ z.number().nonnegative(),
9
+ z.literal("auto"),
10
+ z.string().regex(/^(?:\d+(?:\.\d+)?|\.\d+)%$/)
11
+ ])
12
+ });
13
+ function isNativeFlexValue(value) {
14
+ return typeof value === "object" && value !== null && "flexGrow" in value && nativeFlexValue.safeParse(value).success;
15
+ }
16
+ const NUMBER = /^(?:\d+(?:\.\d+)?|\.\d+)$/;
17
+ /** The supported CSS flex grammar, resolved to RN longhands without losing its basis or shrink. */
18
+ function webFlexToNative(value, remBase) {
19
+ const text = String(value).trim();
20
+ if (text === "none") return {
21
+ flexGrow: 0,
22
+ flexShrink: 0,
23
+ flexBasis: "auto"
24
+ };
25
+ if (text === "auto") return {
26
+ flexGrow: 1,
27
+ flexShrink: 1,
28
+ flexBasis: "auto"
29
+ };
30
+ if (text === "initial") return {
31
+ flexGrow: 0,
32
+ flexShrink: 1,
33
+ flexBasis: "auto"
34
+ };
35
+ const parts = text.split(/\s+/);
36
+ let grow = 1;
37
+ let shrink = 1;
38
+ let basis = "0%";
39
+ if (parts.length <= 3 && NUMBER.test(parts[0] ?? "")) {
40
+ grow = Number(parts.shift());
41
+ if (parts.length && NUMBER.test(parts[0] ?? "")) shrink = Number(parts.shift());
42
+ if (parts.length === 1) basis = parts.shift() ?? "";
43
+ } else if (parts.length === 1) basis = parts.shift() ?? "";
44
+ if (parts.length === 0) {
45
+ if (basis === "auto" || /^(?:\d+(?:\.\d+)?|\.\d+)%$/.test(basis)) return {
46
+ flexGrow: grow,
47
+ flexShrink: shrink,
48
+ flexBasis: basis
49
+ };
50
+ const length = /^(\d+(?:\.\d+)?|\.\d+)(px|rem)?$/.exec(basis);
51
+ if (length && (length[2] || Number(length[1]) === 0)) {
52
+ if (length[2] !== "rem" || remBase !== void 0) return {
53
+ flexGrow: grow,
54
+ flexShrink: shrink,
55
+ flexBasis: Number(length[1]) * (length[2] === "rem" ? remBase : 1)
56
+ };
57
+ }
58
+ }
59
+ throw new Error(`[uds] Cannot translate Web flex ${JSON.stringify(value)} to native. Use none, auto, initial, or numeric grow/shrink with an auto, percentage, px, or fixed-rem basis.`);
60
+ }
61
+ /** RN numeric flex is not CSS numeric flex: Yoga's native defaults use shrink=0, and positive
62
+ * numbers use a 0pt basis. Negative flex supplies shrink while retaining auto basis.
63
+ * See Yoga Node::resolveFlexGrow/resolveFlexShrink/processFlexBasis with useWebDefaults=false. */
64
+ function nativeFlexToWeb(value) {
65
+ const { flexGrow, flexShrink, flexBasis } = typeof value !== "number" ? value : value > 0 ? {
66
+ flexGrow: value,
67
+ flexShrink: 0,
68
+ flexBasis: 0
69
+ } : {
70
+ flexGrow: 0,
71
+ flexShrink: -value,
72
+ flexBasis: "auto"
73
+ };
74
+ return `${flexGrow} ${flexShrink} ${typeof flexBasis === "number" ? `${flexBasis}px` : flexBasis}`;
75
+ }
76
+ //#endregion
77
+ export { isNativeFlexValue, nativeFlexToWeb, nativeFlexValue, webFlexToNative };
@@ -0,0 +1,11 @@
1
+ import type { Config } from '../../framework/Config';
2
+ import type { BagSites } from './style-bag';
3
+ /** Translate inherited literals before merging the destination's own style overrides. Refs keep
4
+ * their identity: the linked-token adapter handles their values and mode overrides. */
5
+ export declare function translateLinkedStyleBags({ body, source, config, bags, owner, }: {
6
+ body: Record<string, unknown>;
7
+ source?: Config;
8
+ config: Config;
9
+ bags: BagSites;
10
+ owner?: string;
11
+ }): Record<string, unknown>;
@@ -0,0 +1,47 @@
1
+ import { isRef, pathOf } from "../../framework/utils/refs.js";
2
+ import { NATIVE_CONFIG_NAME } from "../../configs/platform.js";
3
+ import { isNativeFlexValue, nativeFlexToWeb, webFlexToNative } from "./linked-flex-values.js";
4
+ import { rootFontSize } from "./token-values.js";
5
+ import { stylePropEntries, stylePropertyPathFor } from "../../framework/projections.js";
6
+ //#region src/entities/system/linked-style-values.ts
7
+ /** Translate inherited literals before merging the destination's own style overrides. Refs keep
8
+ * their identity: the linked-token adapter handles their values and mode overrides. */
9
+ function translateLinkedStyleBags({ body, source, config, bags, owner }) {
10
+ if (!source || source.name === config.name) return body;
11
+ if (!["system-config", "react-native-system"].includes(source.name)) return body;
12
+ if (!["system-config", "react-native-system"].includes(config.name)) return body;
13
+ const native = config.name === NATIVE_CONFIG_NAME;
14
+ const translate = (bag, element) => Object.fromEntries(Object.entries(bag).map(([key, raw]) => {
15
+ if (key.startsWith("_")) return [key, raw];
16
+ const propPath = stylePropertyPathFor({
17
+ config: source,
18
+ key,
19
+ through: [isRef(element) ? pathOf(element) : typeof element === "string" ? element : owner]
20
+ });
21
+ const properties = propPath ? source.resolve("style-property", propPath)?.toJSON().properties : void 0;
22
+ if (!propPath || !Array.isArray(properties) || properties.length !== 1 || isRef(raw)) return [key, raw];
23
+ const property = String(properties[0]).replace(/-([a-z])/g, (_, c) => c.toUpperCase());
24
+ if (![
25
+ "flex",
26
+ "flexGrow",
27
+ "flexShrink"
28
+ ].includes(property)) return [key, raw];
29
+ const alias = stylePropEntries(source, propPath).find((entry) => entry.leaf === String(raw));
30
+ if (alias?.declarations) return [key, raw];
31
+ const resolved = alias ? alias.numeric && /^(?:\d+(?:\.\d+)?|\.\d+)$/.test(alias.value) ? Number(alias.value) : alias.value : raw;
32
+ const value = typeof resolved === "string" && resolved.startsWith("[") && resolved.endsWith("]") ? resolved.slice(1, -1) : resolved;
33
+ if (property === "flex") {
34
+ if (native && (typeof value === "string" || typeof value === "number")) return [key, webFlexToNative(value, rootFontSize(source).px)];
35
+ if (!native && (typeof value === "number" || isNativeFlexValue(value))) return [key, `[${nativeFlexToWeb(value)}]`];
36
+ } else if (typeof value === "string" || typeof value === "number") {
37
+ if (!/^(?:\d+(?:\.\d+)?|\.\d+)$/.test(String(value)) || !Number.isFinite(Number(value))) throw new Error(`[uds] Cannot translate ${property} ${JSON.stringify(value)}: expected a non-negative unitless number.`);
38
+ return [key, native ? Number(value) : `[${value}]`];
39
+ }
40
+ return [key, raw];
41
+ }));
42
+ const translated = structuredClone(body);
43
+ for (const site of [...bags(translated)].reverse()) site.write(translate(site.bag, site.element));
44
+ return translated;
45
+ }
46
+ //#endregion
47
+ export { translateLinkedStyleBags };
@@ -1,5 +1,6 @@
1
1
  import { Config } from "../../framework/Config.js";
2
2
  import { NATIVE_CONFIG_NAME, WEB_CONFIG_NAME } from "../../configs/platform.js";
3
+ import { NativeFlexValue } from "./linked-flex-values.js";
3
4
 
4
5
  //#region src/entities/system/linked-token-values.d.ts
5
6
  type Platform = typeof WEB_CONFIG_NAME | typeof NATIVE_CONFIG_NAME;
@@ -11,24 +12,26 @@ declare function convertLinkedTokenValue({
11
12
  remBase
12
13
  }: {
13
14
  path: string;
14
- value: string | number | boolean;
15
+ value: string | number | boolean | NativeFlexValue;
15
16
  sourcePlatform: string;
16
17
  destinationPlatform: Platform; /** The pinned web source's fixed root size, only needed for web rem → native points. */
17
18
  remBase?: number;
18
- }): string | number | boolean;
19
+ }): string | number | boolean | NativeFlexValue;
19
20
  /** The one adapter for base and mode values before a linked body is parsed by its destination. */
20
21
  declare function prepareLinkedTokenBody({
21
22
  path,
22
23
  body,
23
24
  source,
24
25
  config,
25
- destinationPlatform
26
+ destinationPlatform,
27
+ extend
26
28
  }: {
27
29
  path: string;
28
30
  body: Record<string, unknown>;
29
31
  source: Config; /** The config whose refs the body spells; a source's own body spells them in the source. */
30
32
  config: Config;
31
33
  destinationPlatform: Platform;
34
+ extend?: Record<string, unknown>;
32
35
  }): Record<string, unknown>;
33
36
  //#endregion
34
37
  export { convertLinkedTokenValue, prepareLinkedTokenBody };
@@ -1,9 +1,10 @@
1
1
  import { hasRefMarker } from "../../framework/utils/refs.js";
2
2
  import { isCalc } from "./calc.js";
3
3
  import { isOklchColor } from "./color.js";
4
- import { literalValueOf } from "../../framework/projections.js";
5
- import { rootFontSize } from "./token-values.js";
6
4
  import "../../configs/platform.js";
5
+ import { isNativeFlexValue, nativeFlexToWeb, webFlexToNative } from "./linked-flex-values.js";
6
+ import { rootFontSize } from "./token-values.js";
7
+ import { literalValueOf } from "../../framework/projections.js";
7
8
  //#region src/entities/system/linked-token-values.ts
8
9
  /**
9
10
  * Adapt a linked token for the system reading it. The source keeps its authored value; only the
@@ -12,10 +13,12 @@ import "../../configs/platform.js";
12
13
  */
13
14
  const LENGTH_GROUPS = new Set([
14
15
  "spacing",
16
+ "size",
15
17
  "radius",
16
18
  "borderRadius",
17
19
  "iconSize",
18
20
  "borderWidth",
21
+ "outlineOffset",
19
22
  "fontSize",
20
23
  "fontLineHeight",
21
24
  "fontLetterSpacing"
@@ -23,7 +26,9 @@ const LENGTH_GROUPS = new Set([
23
26
  const NUMBER_GROUPS = new Set([
24
27
  "opacity",
25
28
  "zIndex",
26
- "fontWeight"
29
+ "fontWeight",
30
+ "flexGrow",
31
+ "flexShrink"
27
32
  ]);
28
33
  const LENGTH = /^(-?(?:\d+(?:\.\d+)?|\.\d+))(px|rem)$/;
29
34
  const NUMBER = /^-?(?:\d+(?:\.\d+)?|\.\d+)$/;
@@ -33,9 +38,16 @@ const OKLCH = /^oklch\(\s*(-?[\d.]+)(%?)\s+(-?[\d.]+)(%?)\s+(-?[\d.]+|none)(?:de
33
38
  function convertLinkedTokenValue({ path, value, sourcePlatform, destinationPlatform, remBase }) {
34
39
  if (sourcePlatform === destinationPlatform) return value;
35
40
  const group = path.split("/")[0];
41
+ if (group === "flex") {
42
+ if (destinationPlatform === "react-native-system") {
43
+ if (isNativeFlexValue(value)) return value;
44
+ if (typeof value === "string" || typeof value === "number") return webFlexToNative(value, remBase);
45
+ } else if (sourcePlatform === "react-native-system" && (typeof value === "number" || isNativeFlexValue(value))) return nativeFlexToWeb(value);
46
+ }
36
47
  if (destinationPlatform === "react-native-system") {
37
48
  if (LENGTH_GROUPS.has(group)) {
38
49
  if (typeof value === "number") return value;
50
+ if (group === "size" && typeof value === "string" && /^-?(?:\d+(?:\.\d+)?|\.\d+)%$/.test(value)) return value;
39
51
  const match = typeof value === "string" ? LENGTH.exec(value) : null;
40
52
  if (!match) throw unsupported("native", path, value, "a px or rem length");
41
53
  if (match[2] === "rem" && remBase === void 0) throw new Error(`[uds] Linked native token "${path}" has value ${JSON.stringify(value)}, but its source has no fixed root font size for rem conversion.`);
@@ -60,7 +72,7 @@ function convertLinkedTokenValue({ path, value, sourcePlatform, destinationPlatf
60
72
  return value;
61
73
  }
62
74
  /** The one adapter for base and mode values before a linked body is parsed by its destination. */
63
- function prepareLinkedTokenBody({ path, body, source, config, destinationPlatform }) {
75
+ function prepareLinkedTokenBody({ path, body, source, config, destinationPlatform, extend }) {
64
76
  if (source.name === destinationPlatform) return body;
65
77
  const remBase = source.name === "system-config" ? rootFontSize(source).px : void 0;
66
78
  const convert = (value) => {
@@ -69,7 +81,7 @@ function prepareLinkedTokenBody({ path, body, source, config, destinationPlatfor
69
81
  value,
70
82
  remBase
71
83
  }) : value;
72
- return typeof literal === "string" || typeof literal === "number" || typeof literal === "boolean" ? convertLinkedTokenValue({
84
+ return typeof literal === "string" || typeof literal === "number" || typeof literal === "boolean" || isNativeFlexValue(literal) ? convertLinkedTokenValue({
73
85
  path,
74
86
  value: literal,
75
87
  sourcePlatform: source.name,
@@ -80,10 +92,10 @@ function prepareLinkedTokenBody({ path, body, source, config, destinationPlatfor
80
92
  const overrides = body.overrides;
81
93
  return {
82
94
  ...body,
83
- value: convert(body.value),
95
+ value: extend && Object.hasOwn(extend, "value") ? body.value : convert(body.value),
84
96
  ...overrides && typeof overrides === "object" && !Array.isArray(overrides) ? { overrides: Object.fromEntries(Object.entries(overrides).map(([key, raw]) => [key, raw && typeof raw === "object" && !Array.isArray(raw) ? {
85
97
  ...raw,
86
- value: convert(raw.value)
98
+ value: Object.hasOwn((extend?.overrides)?.[key] ?? {}, "value") ? raw.value : convert(raw.value)
87
99
  } : raw])) } : {}
88
100
  };
89
101
  }
@@ -1,11 +1,11 @@
1
1
  import { collectRefs, isRef, kindOf, pathOf } from "../../framework/utils/refs.js";
2
2
  import { composedValueFormOf } from "./composed-values.js";
3
3
  import { createSliceMemo } from "../../framework/memo.js";
4
+ import { tokenValueRow } from "./token-values.js";
4
5
  import { MOTION_EASING_NAMES, bezierPoints, motionOfCssKeyword } from "./easings.js";
5
6
  import { inlineMotions } from "./motion-variants.js";
6
7
  import { isReducedMotion } from "./reduced-motion.js";
7
8
  import { jsMotionPropFields } from "./Motion.js";
8
- import { tokenValueRow } from "./token-values.js";
9
9
  import { renderValue } from "./value-render.js";
10
10
  //#region src/entities/system/motion-presets.ts
11
11
  /** A time spelled in CSS, which `motion/react` reads in seconds. */
@@ -1415,12 +1415,14 @@ declare class Config {
1415
1415
  kind,
1416
1416
  path,
1417
1417
  body,
1418
- extend
1418
+ extend,
1419
+ source
1419
1420
  }: {
1420
1421
  kind: string;
1421
1422
  path: string;
1422
1423
  body: Record<string, unknown>;
1423
1424
  extend: Record<string, unknown>;
1425
+ source?: Config;
1424
1426
  }): Record<string, unknown>;
1425
1427
  /** The body of the entity a re-pointed path names, or `undefined` when there is none to read. */
1426
1428
  private redirectedBody;
@@ -2074,7 +2074,8 @@ var Config = class Config {
2074
2074
  kind: patch.kind,
2075
2075
  path: pathOf(extension),
2076
2076
  body: current.source,
2077
- extend: current.overlay
2077
+ extend: current.overlay,
2078
+ source: this.configFor(extension)
2078
2079
  }) : resolved.toJSON();
2079
2080
  const materialized = snapshot.withChanges([itemChange(entry, patch.kind, patch.path, inherited)]);
2080
2081
  const changed = this.applySub(materialized, patch, materialized.get(patch.kind, patch.path) ?? resolved, mode);
@@ -2164,7 +2165,8 @@ var Config = class Config {
2164
2165
  kind: patch.kind,
2165
2166
  path: pathOf(extension),
2166
2167
  body: current.source,
2167
- extend: current.overlay
2168
+ extend: current.overlay,
2169
+ source: this.configFor(extension)
2168
2170
  }) : resolved.toJSON(), delta, isField);
2169
2171
  const local = { ...current ? current.overlay : extension.extend };
2170
2172
  for (const field of touched) if (Object.hasOwn(delta, field) && delta[field] === null) delete local[field];
@@ -2176,7 +2178,8 @@ var Config = class Config {
2176
2178
  kind: patch.kind,
2177
2179
  path: pathOf(extension),
2178
2180
  body: sourceBody,
2179
- extend: local
2181
+ extend: local,
2182
+ source: this.configFor(extension)
2180
2183
  });
2181
2184
  const createSchema = wholeBodySchema(entry, { config: this });
2182
2185
  let merged = candidate;
@@ -2926,13 +2929,15 @@ var Config = class Config {
2926
2929
  kind,
2927
2930
  path: pathOf(extension),
2928
2931
  body: inherited,
2929
- extend: extension.extend ?? {}
2932
+ extend: extension.extend ?? {},
2933
+ source
2930
2934
  });
2931
2935
  return this.entityOf(kind)?.prepareLinkedBody?.({
2932
2936
  path: pathOf(extension),
2933
2937
  body: merged,
2934
2938
  source,
2935
- config: this
2939
+ config: this,
2940
+ extend: extension.extend ?? {}
2936
2941
  }) ?? merged;
2937
2942
  }
2938
2943
  /**
@@ -2947,7 +2952,7 @@ var Config = class Config {
2947
2952
  * nothing. The pin's invariants refuse the last two when they're written, and the build reports a
2948
2953
  * missing target (`brokenLinkRedirects`).
2949
2954
  */
2950
- laidLinkedBody({ kind, path, body, extend }) {
2955
+ laidLinkedBody({ kind, path, body, extend, source }) {
2951
2956
  const { target, rest } = redirectOf(extend);
2952
2957
  const base = target === void 0 ? body : this.redirectedBody({
2953
2958
  kind,
@@ -2958,7 +2963,9 @@ var Config = class Config {
2958
2963
  entry: this.entityOf(kind),
2959
2964
  path,
2960
2965
  body: base,
2961
- extend: rest
2966
+ extend: rest,
2967
+ config: this,
2968
+ source: target === void 0 ? source : this.configFor({ __ref: target })
2962
2969
  }), rest);
2963
2970
  }
2964
2971
  /** The body of the entity a re-pointed path names, or `undefined` when there is none to read. */
@@ -3892,7 +3899,8 @@ var Config = class Config {
3892
3899
  kind,
3893
3900
  path,
3894
3901
  body: theirs,
3895
- extend: laid
3902
+ extend: laid,
3903
+ source: this.sourceFor(slug)
3896
3904
  });
3897
3905
  return laid ? {
3898
3906
  ...theirs,
@@ -5111,7 +5119,8 @@ var Config = class Config {
5111
5119
  source: slug,
5112
5120
  owns: (name) => source.ownedKinds().includes(name)
5113
5121
  }),
5114
- extend: extension.extend
5122
+ extend: extension.extend,
5123
+ source
5115
5124
  });
5116
5125
  visitEntity(kind, body, false, linked);
5117
5126
  visitBags(kind, body, linked);
@@ -6035,11 +6044,13 @@ function redirectOf(extend) {
6035
6044
  }
6036
6045
  /** A source's body as an extension reads it before its `extend` merges in: the kind's
6037
6046
  * {@link EntityKind.rebaseLinkedBody}, where it declares one. */
6038
- function rebasedLinkedBody({ entry, path, body, extend }) {
6047
+ function rebasedLinkedBody({ entry, path, body, extend, source, config }) {
6039
6048
  return entry?.rebaseLinkedBody?.({
6040
6049
  path,
6041
6050
  body,
6042
- extend
6051
+ extend,
6052
+ source,
6053
+ config
6043
6054
  }) ?? body;
6044
6055
  }
6045
6056
  function overlayBody({ overlay, theirs }) {
@@ -6,9 +6,9 @@ import { modifierCategory } from "../entities/system/modifier-axis.js";
6
6
  import { forwardedPropName, forwardsOf, rootLayerOf } from "../entities/system/element.js";
7
7
  import { createSliceMemo } from "./memo.js";
8
8
  import { fontFamilyStack } from "../entities/system/Font.js";
9
+ import { classPrefixOf, prefixed, varPrefixOf } from "../entities/system/Settings.js";
9
10
  import { listedIn } from "./utils/enumerated.js";
10
11
  import "../entities/system/Modifier.js";
11
- import { classPrefixOf, prefixed, varPrefixOf } from "../entities/system/Settings.js";
12
12
  import { StyleProperty, leavesOfStylePropValue, numberUnitRefusal } from "../entities/system/StyleProperty.js";
13
13
  import { componentStates } from "./component-states.js";
14
14
  import { isConditionalPreview, storedPreview, unconditionalPreviewProps } from "./preview-store.js";
@@ -82,7 +82,9 @@ interface EntityKind {
82
82
  readonly rebaseLinkedBody?: (args: {
83
83
  readonly path: string;
84
84
  readonly body: Record<string, unknown>;
85
- readonly extend: Record<string, unknown>;
85
+ readonly extend: Record<string, unknown>; /** Source context for platform translation before destination overrides are merged. */
86
+ readonly source?: Config;
87
+ readonly config: Config;
86
88
  }) => Record<string, unknown>;
87
89
  /** The keys a style rule's layer bag takes that this kind owns, by key. See {@link LayerKey}. */
88
90
  readonly layerKeys?: Readonly<Record<string, LayerKey>>;
@@ -91,7 +93,8 @@ interface EntityKind {
91
93
  readonly path: string;
92
94
  readonly body: Record<string, unknown>;
93
95
  readonly source: Config; /** The config borrowing the body, which resolves the body's source-qualified refs. */
94
- readonly config: Config;
96
+ readonly config: Config; /** Authored destination values must not be interpreted in the source platform's units. */
97
+ readonly extend: Record<string, unknown>;
95
98
  }) => Record<string, unknown>;
96
99
  /** The entity class's name (`style-property` → `StyleProperty`) — what a consumer writes to reach
97
100
  * it (`StyleProperty.ref(...)`, `Token.group(...)`).
package/dist/index.d.ts CHANGED
@@ -70,6 +70,7 @@ import { Documentation, DocumentationClass } from "./entities/documentation/Docu
70
70
  import { NATIVE_ACTIVATIONS, NativeActivation, NativeModifier, NativeModifierClass } from "./entities/native/NativeModifier.js";
71
71
  import { CanvasSection, CanvasSectionClass, NativeSettings } from "./entities/native/NativeSettings.js";
72
72
  import { NativeStyleProperty, rnStyleKey } from "./entities/native/NativeStyleProperty.js";
73
+ import { NativeFlexValue, isNativeFlexValue, nativeFlexToWeb, webFlexToNative } from "./entities/system/linked-flex-values.js";
73
74
  import { NativeToken, nativeTokenValue } from "./entities/native/NativeToken.js";
74
75
  import { CANVAS_ROLES, CanvasRole, CanvasRoleClass, CanvasRoleName } from "./entities/system/CanvasRole.js";
75
76
  import { COMPONENT_ENTRY_STATIC, CREATED_COMPONENT_DIRECTORY, ComponentModuleSource, ComponentRegistryImport, ComponentRegistryImportBinding, componentModuleFilePaths, componentModuleKey, componentModuleSource, componentRegistryImports, createdComponentFilePath, createdComponentPathOf, createdModuleKey, isCreatedComponent, linkedComponentModule, linkedModuleView } from "./entities/system/component-module.js";
@@ -120,4 +121,4 @@ import { SpecNode, validateSpec } from "./framework/validate-spec.js";
120
121
  import { valueLeavesOf, valueSchemaOf } from "./framework/value-domain.js";
121
122
  import { views } from "./framework/views-facade.js";
122
123
  import { RN_STYLE_KEYS } from "./react-native/style-keys.generated.js";
123
- export { AI_LANES, ANATOMY_MARKER, type Add, AiChat, type AiChatClass, AiFlow, type AiFlowClass, type AiFlowOrigin, AiGeneration, type AiGenerationClass, type AiLane, AiMessage, type AiMessageClass, type AiMultiAgentMode, type AnatomyIssue, type AnatomyIssueKind, type AnatomyReport, Annotation, type AnnotationClass, AnnotationFields, type AnnotationSegment, type AnySystemConfig, type AppliedOp, type AsInput, type AttachedSources, type Authored, type AuthoredComponent, type AuthoredProp, type AuthoredPropBody, type AuthoredStyleBag, type AuthoredStyleField, type AuthoringSignatureOptions, BUILD_DEFAULTS, type BatchReceipt, type BindingKind, type BreakOutcome, type BreakPlan, type BreakPlanInput, type BreakPlanRow, type BreakReach, BuildSection, type BuildSectionClass, CANVAS_ROLES, COMPONENT_ENTRY_STATIC, CONFIG_OPERATION_KIND, CREATED_COMPONENT_DIRECTORY, CSS_DEFAULTS, CSS_PROPERTY_NAMES, CSS_WIDE_KEYWORDS, CURRENT_SCHEMA_VERSION, type Calc, type CalcOperand, Canvas, type CanvasClass, CanvasConfig, type CanvasConfigClass, CanvasRole, type CanvasRoleClass, type CanvasRoleName, CanvasSection, type CanvasSectionClass, type CaptureToSpecOptions, type CaptureToSpecResult, type CapturedChild, type CapturedElement, CapturedNode, type CapturedNodeJson, type Spec as CapturedSpec, type SpecElement as CapturedSpecElement, type CapturedText, type Cell, type CellSlot, type Change, type ChangeHook, type ChangeTarget, type CheckedTokenRefPath, type ChildrenPolicy, type ClassGrammar, type CodeSlot, type Collection, type ColorValue, Component, type ComponentBody, type ComponentBuilder, type ComponentClass, type ComponentContractOf, type ComponentCreateInput, type ComponentElementBody, type ComponentInteraction, type ComponentItemInput, type ComponentModuleSource, type ComponentPropBody, type ComponentPropsOf, type ComponentReference, type ComponentRegistryImport, type ComponentRegistryImportBinding, type ComponentRuleClass, type ComponentSpec, type ComponentSpecs, type ComponentState, type ComponentStyleBody, type ComposedValue, type ComposedValueAuthoring, type ComposedValueForm, Composite, type CompositeClass, type ComputedFields, type ComputedFunctions, type ComputedInput, type ComputedMap, type ComputedValue, Config, type ConfigClass, type ConfigEdit, ConfigFormatError, type ConfigInstance, type ConfigIssue, type ConfigIssueCode, type ConfigKind, type ConfigOp, ConfigRejection, ConfigSession, type ConfigSessionOptions, type ConfigSink, type ConfigSource, type CopyPlan, type CopyPlanInput, type CopyPlanRow, type CreateInput, type CssGrammar, type CssPrefix, type CssPropertyEntry, CssSection, type CssSectionClass, DERIVED_COLOR_DEFAULT_SPACE, DERIVED_COLOR_SPACE, DERIVED_MUTATIONS, type DanglingDirective, type DanglingLocalRef, type DanglingRef, type DeclaredRuntimeModule, type DeletePlan, type DeriveMembers, type DerivedColor, type DerivedEntityClass, type DerivedOp, Device, type DeviceClass, type DiffOptions, type Divide, Documentation, type DocumentationClass, DocumentationLibrary, type DocumentationLibraryClass, type DomLikeElement, type DraftSource, ENTITY_PATH_MESSAGE, EXPORT_MEMBER, type Edition, type ElementVisibility, type ElementVisibilityInput, type ElementVisibilitySchema, Entity, type EntityAddress, type EntityChange, type EntityClass, type EntityKind, type EntityMap, type EntryGroup, type ExpandOptions, type ExpansionResult, type ExtendedComponentRef, type ExtendedRef, type FieldsSchema, File, type FileClass, Font, type FontClass, FontFile, type FontFileClass, type ForwardBlockedReason, type ForwardClaims, type ForwardOption, type ForwardOptions, type ForwardRequest, GROUP, GUIDANCE_LANES, GlobalStyle, type GlobalStyleClass, type GlyphComponent, type GlyphExportRule, type GlyphSource, type GlyphValue, type GoverningCondition, type Gradient, type GroupBody, type GroupComputedInput, Guidance, type GuidanceClass, type GuidanceLane, type GuidanceScope, type GuidanceSegment, GuidanceStyle, type GuidanceStyleBody, type GuidanceStyleClass, type HasSnapshot, type HydrationOptions, ICON_METADATA_FORMATS, Icon, type IconAnswer, type IconClass, type IconGlyph, type IconHook, type IconLibrary, type IconMemberMetadata, type IconMetadataAdapter, type IconMetadataDeclaration, type IconMetadataFile, type IconMetadataFormat, type IconTool, type IconVariantAs, type IdentifiedOp, type InferredRename, type InlineMotion, type Instance, type InstanceSlot, type InstanceSpec, type InteractionCondition, type ItemOf, type KindRef, type KindSignature, type KindSlice, LINK_SLUG, LINK_SLUG_MESSAGE, type LayerElement, type LayerMap, type LayerPropDriver, type LayerStyleOptions, type LeafAddress, type LinkArrival, type LinkDeclaration, type LinkPaths, type LinkPlan, type LinkPlanInput, type LinkedElsewhere, LinkedSystem, type LinkedSystemClass, type LinkedSystemCreateInput, type LinkedSystemItemInput, type LinkedSystemResolver, type LinkedSystemState, type ListOptions, type LiveConfig, type LocalOverlay, MINTED, MODIFIER_CATEGORIES, MOTION_FACTORY, MOTION_VARIANT_STATES, type MarkerKind, type MisdeclaredOverlay, Modifier, type ModifierCategory, type ModifierClass, type ModifierGroupMeta, Motion, type MotionClass, type MotionPresetToken, type Multiply, NATIVE_ACTIVATIONS, type NativeActivation, NativeModifier, type NativeModifierClass, NativeSettings, NativeStyleProperty, NativeToken, Node, type NodeClass, type OklchColor, type OnLinked, type OpHandler, type OpInput, Operation, type OperationClass, type OrphanedMotionVariant, type OverlayVerb, type OverrideCondition, type OwnedRecords, PLACED_NODE_KEY, PLAYGROUND_DEFAULTS, Package, type PackageClass, Page, type PageClass, type Patch, type PathOf, type PickedComposite, type PinDirective, type PinOptions, type PinOptionsField, type PinOptionsInput, type PlacedMotion, type Plan, type PlanImpact, type PlanOp, PlaygroundSection, type PlaygroundSectionClass, Presence, type PresenceProps, type PreviewElement, type PreviewMatrix, type ProjectedVisibility, type PropCondition, type PropDecl, type PropDeclaration, type PropMap, type PropRoute, type PropShapeSchema, RN_STYLE_KEYS, ReactNativeSystem, type ReactNativeSystemClass, type ReactNativeSystemConfig, type RebaseConflict, type RebaseOrigin, type RebaseResult, type RecordedSource, type RedundantQualifier, type Ref, type RefGraph, type RefGraphEntry, type RefIndex, type RefIndexChange, type RefMember, type RefTarget, type RegisteredComponentContracts, type RegisteredComponentHandles, type RegisteredEntities, type RegisteredGroupPaths, type RegisteredMembers, type RegisteredModifiers, type RegisteredMotionRuntimes, type RegisteredPaths, type RegisteredStyleBag, type RegisteredStyleProps, type RegisteredTokenValues, type RenamePlan, type RenderArgs, type RenderElement, type RenderSpec, type RenderedNode, type RenderedTarget, type RepeatRow, type RepeatSpec, type RequiredContent, type RequiredPropUnforwarded, type ResolveContext, type ResolveValueTypeInput, type ResolvedBinding, type ResolvedSource, type RootFontSize, SCRIPT_EXTENSIONS, SERIALIZED_CONFIG_VERSION, SIZE_TOLERANCE_PX, SLOT_CODE_FORMS, STYLE_PROPERTIES, STYLE_PROP_NUMBER_UNITS, STYLE_PROP_VALUE_FORMS, STYLE_PROP_VALUE_LEAVES, type SafelistEntry, type SchemaEntry, type SchemaMigration, SchemaVersionTooNew, type SerializedConfig, type SerializedSourceAnswer, Settings, type SettingsClass, type Shadow, type ShadowColor, type ShadowLayer, type ShadowParts, type SignatureOptions, type SkippedOp, type Slot, type SlotCell, type SlotCodeForm, type SlotDecl, type SlotHost, type SlotTarget, Snapshot, type Source, type SourceAnswer, type SourceChange, type SourceMap, type SourceResolution, type SourceResolutionSchemas, type SourceResolver, type SourceRowState, type SourceState, type SourceUnavailable, type SourcesBySlug, type SourcesOf, type SpecNode, type SplitStyleProps, type StampedPatch, type StoredConfig, type StoredPreviewCondition, type StyleClass, type StyleDeclarationGroup, type StylePropEntry, type StylePropLeaf, type StylePropNumberUnit, type StylePropValue, type StylePropValueCtx, type StylePropValueKind, StyleProperty, type StylePropertyClass, type StylePropertyItem, type StyleRuleInput, type StyleValue, type SubEntityClass, type SubPatch, type Subtract, type SurfaceCompositeProp, type SurfaceProp, type SurfacePropCondition, type SurfacePropKind, type SurfaceScalarProp, type SurfaceSlotProp, type SurfaceStylePropertyProp, type SurfaceVariantProp, System, type SystemClass, type SystemConfig, SystemSection, type SystemSectionClass, SystemSource, type SystemSourceClass, TOKEN_READERS, type TimingValue, Token, type TokenBinding, type TokenBody, type TokenClass, type TokenGroupReader, type TokenGroupVariableReader, type TokenMatch, type TokenReader, type TokenReaders, type TokenRefPath, type TokenReference, type TokenValueEntry, type TokenValueRow, type TokenValueState, type TokenVariableAsText, type TokenVariableReaders, Tool, type ToolClass, type Transition, type TransitionSegment, type TraverseOptions, type TreeNode, UDS_FORCE_STATES, UNCONDITIONAL_PREVIEW_KEY, UNREACHABLE, type UnadoptedDirective, type UnknownStyleLeaf, type UnlinkPlan, type UnlinkPlanInput, type UnreadableBorrow, type UnstatableCondition, type UnstatableOverride, type UpgradedDraft, type UserSchemas, VOID_ELEMENTS, type ValueOf, type ValueRefs, type ValueType, type VarNaming, type VariantValueBody, type VariantValues, type VisibilityOperator, type VisibilityTerm, WEB_ACTIVATIONS, type WalkOptions, type WebActivation, add, addressOf, adoptLinkedModule, alpha, anatomyElementComponent, anatomyIssueKey, anatomyTextProp, applyPathDelta, arbitraryClassName, arbitraryNeedsClass, authoredBag, authoredValue, authoringSignatures, baseOf, bindStateRef, bindingPath, blankComponentBody, bodyNumberLeaves, bodyNumberUnit, borrowedGroup, borrowedItem, boundElementType, brandGroup, buildRefGraph, buildRefIndex, calcOperands, calcOperator, canonicalWhen, capturedFromDom, changeOf, changeValueAt, changesOf, childrenPolicy, classGrammar, classLeaf, className, classPrefixOf, classSelector, classifyOverlay, classifyStylePropValue, codeSlotsOf, collectRefs, componentClassBase, componentCompositeClasses, componentInteractions, componentLayerClass, componentModuleFilePaths, componentModuleKey, componentModuleSource, componentMotionClasses, componentPropClasses, componentPropComposites, componentRegistryImports, componentRuleClasses, componentSpec, componentStateAttribute, componentStateAttributes, componentStateDefaults, componentStates, composedValueAuthoring, composedValueFormOf, composedValueForms, composedValueSchemas, condArms, condValue, containsMarker, convertLinkedTokenValue, createCanvasConfig, createSliceMemo, createdComponentFilePath, createdComponentPathOf, createdModuleKey, cssPrefixes, cssPropValue, cssProperty, cssPropertyNames, cssString, cssValueIssue, cssVar, cssVarRef, danglingDirectives, danglingLocalRefs, danglingSourcedRefs, darken, declarationKeyName, declarationText, declaredField, declaredPropDefaults, declaredPropRouting, declaredRuntimeModules, declaredVariants, declaresCssVariable, defineComponent, defineConfig, defineDerivedEntity, defineEntity, defineOverride, defineSubEntity, deriveCreateSchema, deriveSpec, deriveUpdateSchema, describeBody, describePatch, detectedWireVersion, diffRendered, divide, editOp, elementFromCaptured, entityPathProblem, entityRefOf, entryKeyOf, evaluateCalc, excludedCondition, expandComponent, expandSpec, fieldKeys, fontFamilyStack, fontFileDescriptors, forceModeAttribute, forceModeAttributeOf, forceModeProp, forceModePropGroup, forceModePropValue, forceModeProps, forceStateAttribute, forceStateSelector, forwardClaims, forwardRoutes, forwardedLayers, forwardedNames, forwardsOf, globalStyleName, glyphComponentOf, glyphExportNames, glyphExportRule, glyphLibrariesOf, glyphPropsOf, glyphSourcesOf, glyphType, glyphVariantProp, graftPreviewElements, guidanceReaches, guidanceScopeOf, guidanceTextOf, hasInteraction, hasJsMotion, heldLinked, iconCategories, iconLibraries, iconLibrary, iconMemberMetadata, iconMetadata, iconMetadataDeclaration, iconMetadataFile, iconMetadataFileJsonSchema, iconMetadataFormat, iconMetadataSourceFile, iconResolver, iconToolAxisOptions, iconToolFor, iconToolLibraries, iconToolOf, iconToolsOf, iconVariantAs, inferredRenames, inlineJsMotion, inlineMotionId, inlineMotionProps, inlineMotions, inlineRuleComposites, inputOf, instanceHolding, instanceSpec, interactionKey, interactionModifiers, intoName, isAdd, isAuthored, isBinaryAsset, isCalc, isComposedValue, isConfigFormatError, isConfigRejection, isCreatedComponent, isCssProperty, isCustomPropertyKey, isDeclaredElementProp, isDerivedColor, isDivide, isEntityPath, isExtendedRef, isFontFaceStyle, isFontFaceWeight, isForceModeProp, isGradient, isGroupBody, isIdentifier, isInlineMotion, isInteractionModifier, isLinkSlug, isMintedRow, isMultiply, isNativeConfig, isOklchColor, isPlainObject, isPreviewElement, isRef, isReservedWord, isShadow, isSubtract, isSystemConfig, isTokenReader, isTransition, isValueSlot, jsMotionBody, jsMotionPresets, jsMotionPropFields, kebabComponent, keyedPreviewConditions, kindOf, kindsOf, layerJsMotionPresets, layerPropDrivers, layerPropRoutes, layerRef, layerRoutedProps, layerStyles, layerTextProp, leafAddresses, leafVerb, leavesOfStylePropValue, librariesBoundBy, libraryHolding, lighten, linearGradient, linkedComponentModule, linkedModuleView, linkedVarNaming, literalValueOf, liveStateProps, markerKind, matchEntities, matchTokens, memberFromLeaf, memberLeaves, memberOf, memberRef, memberVariantOptions, memoryConfigSource, misdeclaredOverlays, mix, modeAxes, modifierAxes, modifierAxis, modifierCategory, modifierGroupFields, modifierInvariants, modifierLeaf, modifierUtilitiesUsed, motionClassName, motionPresetTokens, motionVariantGroups, multiply, nameIconsInTree, nameStyleNumbers, namedFields, nativeTokenValue, negatedCssValue, normalizeName, normalizeStyleValue, oklch, opOf, opVerb, opacityPercentage, opsForKind, orList, orRef, orphanedMotionVariants, overlayVerb, overrideCondition, overrideKey, overrideKeyModifiers, overrideModifiers, ownTextProp, ownValues, ownerOf, ownsItsValues, packageKey, packageName, parseRootFontSize, parseTokenValue, partsOf, pathDelta, pathOf, pathSegments, pinStyleNumbers, placedGlyphElement, placedMotions, planBreak, planCopy, planLink, planUnlink, prefixed, prepareLinkedTokenBody, previewConditionalProps, previewConditions, previewDefaults, previewMatrix, previewSpec, propApplies, propInto, propOwner, propRegistryRef, propValueDomain, propValueFromAxis, propsIntoLayer, readStatePointer, readsState, redundantQualifiers, ref, refGraphOf, refKey, refLeaf, refListOf, refOfKey, refSchema, refTo, registerSchemaMigrations, renderBindingsOf, renderComposedValue, renderDerivedColor, renderGradient, renderInterpolated, renderOklch, renderShadow, renderSignature, renderStyleValue, renderTransition, renderValue, renderedElement, renderedSignatureOf, renderedTarget, replaceRefMarkers, requiredContentCondition, requiredContentLayers, requiredPropsUnforwarded, resolutionSchema, resolveBinding, resolveComponentProps, resolveFieldValue, resolveIconLibraries, resolveInputDir, resolveOutDir, resolveOutputAlias, resolveRegistryDir, resolveSourceAlias, resolveTokenValue, resolveTokenValueUnder, resolveValue, resolveValueType, resolveVisibility, resolvedSource, rewriteRefNamespace, rewriteRefSource, rewriteRefs, rewriteStyleNumbers, rnStyleKey, rootFontSize, rootLayerOf, routeOf, routedBag, routedProp, routedPropIn, routedSource, routesContent, routesOf, ruleApplies, ruleCondition, runChangeHooks, safelistEntrySchema, schemaVersionOf, searchEntities, searchTokens, setAtPath, shadow, signatureOf, slotCodeForms, slotTargetsOf, snapshotHtml, sniffValueType, sourceEntries, sourceHops, sourceOf, sourceOfGroup, sourceOfItem, sourceRowStates, sourceSlugFor, sourceUnavailable, sourceUnreachable, sourceVarPrefix, specFromCapture, specToNodePatches, specWithResolvedVisibility, spellTokenRead, splitRef, splitRefMarkers, splitStyleProps, splitVariants, stamp, standsInForCode, statePointerProp, stateRef, stateTest, stateVariantNames, storedPreview, styleAliasesOf, styleDeclarationGroups, styleDeclarations, styleNumberAsPainted, styleNumberReadingChanges, stylePropClassBase, stylePropClassName, stylePropClasses, stylePropEntries, stylePropLeafForToken, stylePropNegates, stylePropNumberCss, stylePropNumberLeaf, stylePropNumberLeaves, stylePropNumberName, stylePropNumberNamedLeaves, stylePropNumberUnit, stylePropNumberUnitRefusal, stylePropOffScaleLiteral, stylePropOwnClasses, stylePropTokenGroup, stylePropTokenPath, stylePropTokenValues, stylePropValueFormOf, stylePropValueFromLeaf, stylePropValueLeaves, stylePropValueSchema, stylePropValues, stylePropertiesWriting, stylePropertyAccepts, stylePropertyFor, stylePropertyPathFor, styleRuleMotionClasses, subtract, suggestLinkSlug, summarizeChanges, surfaceProp, surfaceProps, tablerExportName, tablerStyledExportName, toCssPropertyName, tokenBinding, tokenExists, tokenReference, tokenValueRow, tokenValueRows, tokenVariablesAsText, touchedFields, transition, unadoptedDirectives, unconditionalPreviewProps, unknownStyleLeaves, unreadableBorrows, unstatableConditions, unstatableOverrides, updateRefIndex, upgradeDraftEntries, upgradePatch, upgradeSerializedConfig, validateComponentProps, validateSpec, valueAt, valueForwardsOf, valueLeavesOf, valueRef, valueSchemaOf, valueTypeOf, varPrefixOf, views, visibilityStateProps, visibilityTerms, whenParts, withRequiredContentHidden, withoutTruthyTerm, wrappedElementKey };
124
+ export { AI_LANES, ANATOMY_MARKER, type Add, AiChat, type AiChatClass, AiFlow, type AiFlowClass, type AiFlowOrigin, AiGeneration, type AiGenerationClass, type AiLane, AiMessage, type AiMessageClass, type AiMultiAgentMode, type AnatomyIssue, type AnatomyIssueKind, type AnatomyReport, Annotation, type AnnotationClass, AnnotationFields, type AnnotationSegment, type AnySystemConfig, type AppliedOp, type AsInput, type AttachedSources, type Authored, type AuthoredComponent, type AuthoredProp, type AuthoredPropBody, type AuthoredStyleBag, type AuthoredStyleField, type AuthoringSignatureOptions, BUILD_DEFAULTS, type BatchReceipt, type BindingKind, type BreakOutcome, type BreakPlan, type BreakPlanInput, type BreakPlanRow, type BreakReach, BuildSection, type BuildSectionClass, CANVAS_ROLES, COMPONENT_ENTRY_STATIC, CONFIG_OPERATION_KIND, CREATED_COMPONENT_DIRECTORY, CSS_DEFAULTS, CSS_PROPERTY_NAMES, CSS_WIDE_KEYWORDS, CURRENT_SCHEMA_VERSION, type Calc, type CalcOperand, Canvas, type CanvasClass, CanvasConfig, type CanvasConfigClass, CanvasRole, type CanvasRoleClass, type CanvasRoleName, CanvasSection, type CanvasSectionClass, type CaptureToSpecOptions, type CaptureToSpecResult, type CapturedChild, type CapturedElement, CapturedNode, type CapturedNodeJson, type Spec as CapturedSpec, type SpecElement as CapturedSpecElement, type CapturedText, type Cell, type CellSlot, type Change, type ChangeHook, type ChangeTarget, type CheckedTokenRefPath, type ChildrenPolicy, type ClassGrammar, type CodeSlot, type Collection, type ColorValue, Component, type ComponentBody, type ComponentBuilder, type ComponentClass, type ComponentContractOf, type ComponentCreateInput, type ComponentElementBody, type ComponentInteraction, type ComponentItemInput, type ComponentModuleSource, type ComponentPropBody, type ComponentPropsOf, type ComponentReference, type ComponentRegistryImport, type ComponentRegistryImportBinding, type ComponentRuleClass, type ComponentSpec, type ComponentSpecs, type ComponentState, type ComponentStyleBody, type ComposedValue, type ComposedValueAuthoring, type ComposedValueForm, Composite, type CompositeClass, type ComputedFields, type ComputedFunctions, type ComputedInput, type ComputedMap, type ComputedValue, Config, type ConfigClass, type ConfigEdit, ConfigFormatError, type ConfigInstance, type ConfigIssue, type ConfigIssueCode, type ConfigKind, type ConfigOp, ConfigRejection, ConfigSession, type ConfigSessionOptions, type ConfigSink, type ConfigSource, type CopyPlan, type CopyPlanInput, type CopyPlanRow, type CreateInput, type CssGrammar, type CssPrefix, type CssPropertyEntry, CssSection, type CssSectionClass, DERIVED_COLOR_DEFAULT_SPACE, DERIVED_COLOR_SPACE, DERIVED_MUTATIONS, type DanglingDirective, type DanglingLocalRef, type DanglingRef, type DeclaredRuntimeModule, type DeletePlan, type DeriveMembers, type DerivedColor, type DerivedEntityClass, type DerivedOp, Device, type DeviceClass, type DiffOptions, type Divide, Documentation, type DocumentationClass, DocumentationLibrary, type DocumentationLibraryClass, type DomLikeElement, type DraftSource, ENTITY_PATH_MESSAGE, EXPORT_MEMBER, type Edition, type ElementVisibility, type ElementVisibilityInput, type ElementVisibilitySchema, Entity, type EntityAddress, type EntityChange, type EntityClass, type EntityKind, type EntityMap, type EntryGroup, type ExpandOptions, type ExpansionResult, type ExtendedComponentRef, type ExtendedRef, type FieldsSchema, File, type FileClass, Font, type FontClass, FontFile, type FontFileClass, type ForwardBlockedReason, type ForwardClaims, type ForwardOption, type ForwardOptions, type ForwardRequest, GROUP, GUIDANCE_LANES, GlobalStyle, type GlobalStyleClass, type GlyphComponent, type GlyphExportRule, type GlyphSource, type GlyphValue, type GoverningCondition, type Gradient, type GroupBody, type GroupComputedInput, Guidance, type GuidanceClass, type GuidanceLane, type GuidanceScope, type GuidanceSegment, GuidanceStyle, type GuidanceStyleBody, type GuidanceStyleClass, type HasSnapshot, type HydrationOptions, ICON_METADATA_FORMATS, Icon, type IconAnswer, type IconClass, type IconGlyph, type IconHook, type IconLibrary, type IconMemberMetadata, type IconMetadataAdapter, type IconMetadataDeclaration, type IconMetadataFile, type IconMetadataFormat, type IconTool, type IconVariantAs, type IdentifiedOp, type InferredRename, type InlineMotion, type Instance, type InstanceSlot, type InstanceSpec, type InteractionCondition, type ItemOf, type KindRef, type KindSignature, type KindSlice, LINK_SLUG, LINK_SLUG_MESSAGE, type LayerElement, type LayerMap, type LayerPropDriver, type LayerStyleOptions, type LeafAddress, type LinkArrival, type LinkDeclaration, type LinkPaths, type LinkPlan, type LinkPlanInput, type LinkedElsewhere, LinkedSystem, type LinkedSystemClass, type LinkedSystemCreateInput, type LinkedSystemItemInput, type LinkedSystemResolver, type LinkedSystemState, type ListOptions, type LiveConfig, type LocalOverlay, MINTED, MODIFIER_CATEGORIES, MOTION_FACTORY, MOTION_VARIANT_STATES, type MarkerKind, type MisdeclaredOverlay, Modifier, type ModifierCategory, type ModifierClass, type ModifierGroupMeta, Motion, type MotionClass, type MotionPresetToken, type Multiply, NATIVE_ACTIVATIONS, type NativeActivation, type NativeFlexValue, NativeModifier, type NativeModifierClass, NativeSettings, NativeStyleProperty, NativeToken, Node, type NodeClass, type OklchColor, type OnLinked, type OpHandler, type OpInput, Operation, type OperationClass, type OrphanedMotionVariant, type OverlayVerb, type OverrideCondition, type OwnedRecords, PLACED_NODE_KEY, PLAYGROUND_DEFAULTS, Package, type PackageClass, Page, type PageClass, type Patch, type PathOf, type PickedComposite, type PinDirective, type PinOptions, type PinOptionsField, type PinOptionsInput, type PlacedMotion, type Plan, type PlanImpact, type PlanOp, PlaygroundSection, type PlaygroundSectionClass, Presence, type PresenceProps, type PreviewElement, type PreviewMatrix, type ProjectedVisibility, type PropCondition, type PropDecl, type PropDeclaration, type PropMap, type PropRoute, type PropShapeSchema, RN_STYLE_KEYS, ReactNativeSystem, type ReactNativeSystemClass, type ReactNativeSystemConfig, type RebaseConflict, type RebaseOrigin, type RebaseResult, type RecordedSource, type RedundantQualifier, type Ref, type RefGraph, type RefGraphEntry, type RefIndex, type RefIndexChange, type RefMember, type RefTarget, type RegisteredComponentContracts, type RegisteredComponentHandles, type RegisteredEntities, type RegisteredGroupPaths, type RegisteredMembers, type RegisteredModifiers, type RegisteredMotionRuntimes, type RegisteredPaths, type RegisteredStyleBag, type RegisteredStyleProps, type RegisteredTokenValues, type RenamePlan, type RenderArgs, type RenderElement, type RenderSpec, type RenderedNode, type RenderedTarget, type RepeatRow, type RepeatSpec, type RequiredContent, type RequiredPropUnforwarded, type ResolveContext, type ResolveValueTypeInput, type ResolvedBinding, type ResolvedSource, type RootFontSize, SCRIPT_EXTENSIONS, SERIALIZED_CONFIG_VERSION, SIZE_TOLERANCE_PX, SLOT_CODE_FORMS, STYLE_PROPERTIES, STYLE_PROP_NUMBER_UNITS, STYLE_PROP_VALUE_FORMS, STYLE_PROP_VALUE_LEAVES, type SafelistEntry, type SchemaEntry, type SchemaMigration, SchemaVersionTooNew, type SerializedConfig, type SerializedSourceAnswer, Settings, type SettingsClass, type Shadow, type ShadowColor, type ShadowLayer, type ShadowParts, type SignatureOptions, type SkippedOp, type Slot, type SlotCell, type SlotCodeForm, type SlotDecl, type SlotHost, type SlotTarget, Snapshot, type Source, type SourceAnswer, type SourceChange, type SourceMap, type SourceResolution, type SourceResolutionSchemas, type SourceResolver, type SourceRowState, type SourceState, type SourceUnavailable, type SourcesBySlug, type SourcesOf, type SpecNode, type SplitStyleProps, type StampedPatch, type StoredConfig, type StoredPreviewCondition, type StyleClass, type StyleDeclarationGroup, type StylePropEntry, type StylePropLeaf, type StylePropNumberUnit, type StylePropValue, type StylePropValueCtx, type StylePropValueKind, StyleProperty, type StylePropertyClass, type StylePropertyItem, type StyleRuleInput, type StyleValue, type SubEntityClass, type SubPatch, type Subtract, type SurfaceCompositeProp, type SurfaceProp, type SurfacePropCondition, type SurfacePropKind, type SurfaceScalarProp, type SurfaceSlotProp, type SurfaceStylePropertyProp, type SurfaceVariantProp, System, type SystemClass, type SystemConfig, SystemSection, type SystemSectionClass, SystemSource, type SystemSourceClass, TOKEN_READERS, type TimingValue, Token, type TokenBinding, type TokenBody, type TokenClass, type TokenGroupReader, type TokenGroupVariableReader, type TokenMatch, type TokenReader, type TokenReaders, type TokenRefPath, type TokenReference, type TokenValueEntry, type TokenValueRow, type TokenValueState, type TokenVariableAsText, type TokenVariableReaders, Tool, type ToolClass, type Transition, type TransitionSegment, type TraverseOptions, type TreeNode, UDS_FORCE_STATES, UNCONDITIONAL_PREVIEW_KEY, UNREACHABLE, type UnadoptedDirective, type UnknownStyleLeaf, type UnlinkPlan, type UnlinkPlanInput, type UnreadableBorrow, type UnstatableCondition, type UnstatableOverride, type UpgradedDraft, type UserSchemas, VOID_ELEMENTS, type ValueOf, type ValueRefs, type ValueType, type VarNaming, type VariantValueBody, type VariantValues, type VisibilityOperator, type VisibilityTerm, WEB_ACTIVATIONS, type WalkOptions, type WebActivation, add, addressOf, adoptLinkedModule, alpha, anatomyElementComponent, anatomyIssueKey, anatomyTextProp, applyPathDelta, arbitraryClassName, arbitraryNeedsClass, authoredBag, authoredValue, authoringSignatures, baseOf, bindStateRef, bindingPath, blankComponentBody, bodyNumberLeaves, bodyNumberUnit, borrowedGroup, borrowedItem, boundElementType, brandGroup, buildRefGraph, buildRefIndex, calcOperands, calcOperator, canonicalWhen, capturedFromDom, changeOf, changeValueAt, changesOf, childrenPolicy, classGrammar, classLeaf, className, classPrefixOf, classSelector, classifyOverlay, classifyStylePropValue, codeSlotsOf, collectRefs, componentClassBase, componentCompositeClasses, componentInteractions, componentLayerClass, componentModuleFilePaths, componentModuleKey, componentModuleSource, componentMotionClasses, componentPropClasses, componentPropComposites, componentRegistryImports, componentRuleClasses, componentSpec, componentStateAttribute, componentStateAttributes, componentStateDefaults, componentStates, composedValueAuthoring, composedValueFormOf, composedValueForms, composedValueSchemas, condArms, condValue, containsMarker, convertLinkedTokenValue, createCanvasConfig, createSliceMemo, createdComponentFilePath, createdComponentPathOf, createdModuleKey, cssPrefixes, cssPropValue, cssProperty, cssPropertyNames, cssString, cssValueIssue, cssVar, cssVarRef, danglingDirectives, danglingLocalRefs, danglingSourcedRefs, darken, declarationKeyName, declarationText, declaredField, declaredPropDefaults, declaredPropRouting, declaredRuntimeModules, declaredVariants, declaresCssVariable, defineComponent, defineConfig, defineDerivedEntity, defineEntity, defineOverride, defineSubEntity, deriveCreateSchema, deriveSpec, deriveUpdateSchema, describeBody, describePatch, detectedWireVersion, diffRendered, divide, editOp, elementFromCaptured, entityPathProblem, entityRefOf, entryKeyOf, evaluateCalc, excludedCondition, expandComponent, expandSpec, fieldKeys, fontFamilyStack, fontFileDescriptors, forceModeAttribute, forceModeAttributeOf, forceModeProp, forceModePropGroup, forceModePropValue, forceModeProps, forceStateAttribute, forceStateSelector, forwardClaims, forwardRoutes, forwardedLayers, forwardedNames, forwardsOf, globalStyleName, glyphComponentOf, glyphExportNames, glyphExportRule, glyphLibrariesOf, glyphPropsOf, glyphSourcesOf, glyphType, glyphVariantProp, graftPreviewElements, guidanceReaches, guidanceScopeOf, guidanceTextOf, hasInteraction, hasJsMotion, heldLinked, iconCategories, iconLibraries, iconLibrary, iconMemberMetadata, iconMetadata, iconMetadataDeclaration, iconMetadataFile, iconMetadataFileJsonSchema, iconMetadataFormat, iconMetadataSourceFile, iconResolver, iconToolAxisOptions, iconToolFor, iconToolLibraries, iconToolOf, iconToolsOf, iconVariantAs, inferredRenames, inlineJsMotion, inlineMotionId, inlineMotionProps, inlineMotions, inlineRuleComposites, inputOf, instanceHolding, instanceSpec, interactionKey, interactionModifiers, intoName, isAdd, isAuthored, isBinaryAsset, isCalc, isComposedValue, isConfigFormatError, isConfigRejection, isCreatedComponent, isCssProperty, isCustomPropertyKey, isDeclaredElementProp, isDerivedColor, isDivide, isEntityPath, isExtendedRef, isFontFaceStyle, isFontFaceWeight, isForceModeProp, isGradient, isGroupBody, isIdentifier, isInlineMotion, isInteractionModifier, isLinkSlug, isMintedRow, isMultiply, isNativeConfig, isNativeFlexValue, isOklchColor, isPlainObject, isPreviewElement, isRef, isReservedWord, isShadow, isSubtract, isSystemConfig, isTokenReader, isTransition, isValueSlot, jsMotionBody, jsMotionPresets, jsMotionPropFields, kebabComponent, keyedPreviewConditions, kindOf, kindsOf, layerJsMotionPresets, layerPropDrivers, layerPropRoutes, layerRef, layerRoutedProps, layerStyles, layerTextProp, leafAddresses, leafVerb, leavesOfStylePropValue, librariesBoundBy, libraryHolding, lighten, linearGradient, linkedComponentModule, linkedModuleView, linkedVarNaming, literalValueOf, liveStateProps, markerKind, matchEntities, matchTokens, memberFromLeaf, memberLeaves, memberOf, memberRef, memberVariantOptions, memoryConfigSource, misdeclaredOverlays, mix, modeAxes, modifierAxes, modifierAxis, modifierCategory, modifierGroupFields, modifierInvariants, modifierLeaf, modifierUtilitiesUsed, motionClassName, motionPresetTokens, motionVariantGroups, multiply, nameIconsInTree, nameStyleNumbers, namedFields, nativeFlexToWeb, nativeTokenValue, negatedCssValue, normalizeName, normalizeStyleValue, oklch, opOf, opVerb, opacityPercentage, opsForKind, orList, orRef, orphanedMotionVariants, overlayVerb, overrideCondition, overrideKey, overrideKeyModifiers, overrideModifiers, ownTextProp, ownValues, ownerOf, ownsItsValues, packageKey, packageName, parseRootFontSize, parseTokenValue, partsOf, pathDelta, pathOf, pathSegments, pinStyleNumbers, placedGlyphElement, placedMotions, planBreak, planCopy, planLink, planUnlink, prefixed, prepareLinkedTokenBody, previewConditionalProps, previewConditions, previewDefaults, previewMatrix, previewSpec, propApplies, propInto, propOwner, propRegistryRef, propValueDomain, propValueFromAxis, propsIntoLayer, readStatePointer, readsState, redundantQualifiers, ref, refGraphOf, refKey, refLeaf, refListOf, refOfKey, refSchema, refTo, registerSchemaMigrations, renderBindingsOf, renderComposedValue, renderDerivedColor, renderGradient, renderInterpolated, renderOklch, renderShadow, renderSignature, renderStyleValue, renderTransition, renderValue, renderedElement, renderedSignatureOf, renderedTarget, replaceRefMarkers, requiredContentCondition, requiredContentLayers, requiredPropsUnforwarded, resolutionSchema, resolveBinding, resolveComponentProps, resolveFieldValue, resolveIconLibraries, resolveInputDir, resolveOutDir, resolveOutputAlias, resolveRegistryDir, resolveSourceAlias, resolveTokenValue, resolveTokenValueUnder, resolveValue, resolveValueType, resolveVisibility, resolvedSource, rewriteRefNamespace, rewriteRefSource, rewriteRefs, rewriteStyleNumbers, rnStyleKey, rootFontSize, rootLayerOf, routeOf, routedBag, routedProp, routedPropIn, routedSource, routesContent, routesOf, ruleApplies, ruleCondition, runChangeHooks, safelistEntrySchema, schemaVersionOf, searchEntities, searchTokens, setAtPath, shadow, signatureOf, slotCodeForms, slotTargetsOf, snapshotHtml, sniffValueType, sourceEntries, sourceHops, sourceOf, sourceOfGroup, sourceOfItem, sourceRowStates, sourceSlugFor, sourceUnavailable, sourceUnreachable, sourceVarPrefix, specFromCapture, specToNodePatches, specWithResolvedVisibility, spellTokenRead, splitRef, splitRefMarkers, splitStyleProps, splitVariants, stamp, standsInForCode, statePointerProp, stateRef, stateTest, stateVariantNames, storedPreview, styleAliasesOf, styleDeclarationGroups, styleDeclarations, styleNumberAsPainted, styleNumberReadingChanges, stylePropClassBase, stylePropClassName, stylePropClasses, stylePropEntries, stylePropLeafForToken, stylePropNegates, stylePropNumberCss, stylePropNumberLeaf, stylePropNumberLeaves, stylePropNumberName, stylePropNumberNamedLeaves, stylePropNumberUnit, stylePropNumberUnitRefusal, stylePropOffScaleLiteral, stylePropOwnClasses, stylePropTokenGroup, stylePropTokenPath, stylePropTokenValues, stylePropValueFormOf, stylePropValueFromLeaf, stylePropValueLeaves, stylePropValueSchema, stylePropValues, stylePropertiesWriting, stylePropertyAccepts, stylePropertyFor, stylePropertyPathFor, styleRuleMotionClasses, subtract, suggestLinkSlug, summarizeChanges, surfaceProp, surfaceProps, tablerExportName, tablerStyledExportName, toCssPropertyName, tokenBinding, tokenExists, tokenReference, tokenValueRow, tokenValueRows, tokenVariablesAsText, touchedFields, transition, unadoptedDirectives, unconditionalPreviewProps, unknownStyleLeaves, unreadableBorrows, unstatableConditions, unstatableOverrides, updateRefIndex, upgradeDraftEntries, upgradePatch, upgradeSerializedConfig, validateComponentProps, validateSpec, valueAt, valueForwardsOf, valueLeavesOf, valueRef, valueSchemaOf, valueTypeOf, varPrefixOf, views, visibilityStateProps, visibilityTerms, webFlexToNative, whenParts, withRequiredContentHidden, withoutTruthyTerm, wrappedElementKey };