@memoized-dom/compiler 0.0.1

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.
Files changed (135) hide show
  1. package/README.md +28 -0
  2. package/dist/analysis/access-table.d.ts +5 -0
  3. package/dist/analysis/access-table.d.ts.map +1 -0
  4. package/dist/analysis/component-graph.d.ts +10 -0
  5. package/dist/analysis/component-graph.d.ts.map +1 -0
  6. package/dist/analysis/component-reads.d.ts +10 -0
  7. package/dist/analysis/component-reads.d.ts.map +1 -0
  8. package/dist/analysis/computed.d.ts +11 -0
  9. package/dist/analysis/computed.d.ts.map +1 -0
  10. package/dist/analysis/instance-control-flow.d.ts +9 -0
  11. package/dist/analysis/instance-control-flow.d.ts.map +1 -0
  12. package/dist/analysis/instance.d.ts +9 -0
  13. package/dist/analysis/instance.d.ts.map +1 -0
  14. package/dist/analysis/runtime-pattern.d.ts +9 -0
  15. package/dist/analysis/runtime-pattern.d.ts.map +1 -0
  16. package/dist/analysis/slot-paths.d.ts +11 -0
  17. package/dist/analysis/slot-paths.d.ts.map +1 -0
  18. package/dist/analysis/type-candidates.d.ts +14 -0
  19. package/dist/analysis/type-candidates.d.ts.map +1 -0
  20. package/dist/analysis.d.ts +52 -0
  21. package/dist/analysis.d.ts.map +1 -0
  22. package/dist/compile.d.ts +17 -0
  23. package/dist/compile.d.ts.map +1 -0
  24. package/dist/component-linker.d.ts +32 -0
  25. package/dist/component-linker.d.ts.map +1 -0
  26. package/dist/components/callback-props.d.ts +14 -0
  27. package/dist/components/callback-props.d.ts.map +1 -0
  28. package/dist/components/calls.d.ts +17 -0
  29. package/dist/components/calls.d.ts.map +1 -0
  30. package/dist/components/children.d.ts +43 -0
  31. package/dist/components/children.d.ts.map +1 -0
  32. package/dist/components/declarations.d.ts +16 -0
  33. package/dist/components/declarations.d.ts.map +1 -0
  34. package/dist/components/jsx-values.d.ts +7 -0
  35. package/dist/components/jsx-values.d.ts.map +1 -0
  36. package/dist/components/local-derived.d.ts +6 -0
  37. package/dist/components/local-derived.d.ts.map +1 -0
  38. package/dist/components/manifest.d.ts +31 -0
  39. package/dist/components/manifest.d.ts.map +1 -0
  40. package/dist/components/prop-effects.d.ts +11 -0
  41. package/dist/components/prop-effects.d.ts.map +1 -0
  42. package/dist/components/prop-linker.d.ts +8 -0
  43. package/dist/components/prop-linker.d.ts.map +1 -0
  44. package/dist/components/prop-origins.d.ts +17 -0
  45. package/dist/components/prop-origins.d.ts.map +1 -0
  46. package/dist/components/prop-projections.d.ts +5 -0
  47. package/dist/components/prop-projections.d.ts.map +1 -0
  48. package/dist/components/props.d.ts +73 -0
  49. package/dist/components/props.d.ts.map +1 -0
  50. package/dist/components/ref-props.d.ts +11 -0
  51. package/dist/components/ref-props.d.ts.map +1 -0
  52. package/dist/components/render-callbacks.d.ts +19 -0
  53. package/dist/components/render-callbacks.d.ts.map +1 -0
  54. package/dist/components/render-functions.d.ts +4 -0
  55. package/dist/components/render-functions.d.ts.map +1 -0
  56. package/dist/components/render-prelude.d.ts +13 -0
  57. package/dist/components/render-prelude.d.ts.map +1 -0
  58. package/dist/components/return-plan.d.ts +27 -0
  59. package/dist/components/return-plan.d.ts.map +1 -0
  60. package/dist/conds.d.ts +21 -0
  61. package/dist/conds.d.ts.map +1 -0
  62. package/dist/context/ast.d.ts +51 -0
  63. package/dist/context/ast.d.ts.map +1 -0
  64. package/dist/context/model.d.ts +309 -0
  65. package/dist/context/model.d.ts.map +1 -0
  66. package/dist/context.d.ts +9 -0
  67. package/dist/context.d.ts.map +1 -0
  68. package/dist/effects.d.ts +26 -0
  69. package/dist/effects.d.ts.map +1 -0
  70. package/dist/emission/component.d.ts +12 -0
  71. package/dist/emission/component.d.ts.map +1 -0
  72. package/dist/emission/conditional-region.d.ts +13 -0
  73. package/dist/emission/conditional-region.d.ts.map +1 -0
  74. package/dist/emission/dom-template.d.ts +11 -0
  75. package/dist/emission/dom-template.d.ts.map +1 -0
  76. package/dist/emission/list-region.d.ts +10 -0
  77. package/dist/emission/list-region.d.ts.map +1 -0
  78. package/dist/emission/node-emitter.d.ts +8 -0
  79. package/dist/emission/node-emitter.d.ts.map +1 -0
  80. package/dist/emission/render-callback.d.ts +14 -0
  81. package/dist/emission/render-callback.d.ts.map +1 -0
  82. package/dist/emission/scope.d.ts +47 -0
  83. package/dist/emission/scope.d.ts.map +1 -0
  84. package/dist/emit.d.ts +29 -0
  85. package/dist/emit.d.ts.map +1 -0
  86. package/dist/handler-commits.d.ts +30 -0
  87. package/dist/handler-commits.d.ts.map +1 -0
  88. package/dist/handler-origin.d.ts +13 -0
  89. package/dist/handler-origin.d.ts.map +1 -0
  90. package/dist/handlers/analyze.d.ts +4 -0
  91. package/dist/handlers/analyze.d.ts.map +1 -0
  92. package/dist/handlers/local-calls.d.ts +11 -0
  93. package/dist/handlers/local-calls.d.ts.map +1 -0
  94. package/dist/handlers.d.ts +40 -0
  95. package/dist/handlers.d.ts.map +1 -0
  96. package/dist/helper-summaries.d.ts +12 -0
  97. package/dist/helper-summaries.d.ts.map +1 -0
  98. package/dist/identifiers.d.ts +29 -0
  99. package/dist/identifiers.d.ts.map +1 -0
  100. package/dist/index.d.ts +4 -0
  101. package/dist/index.d.ts.map +1 -0
  102. package/dist/index.js +1 -0
  103. package/dist/jsx/attributes.d.ts +24 -0
  104. package/dist/jsx/attributes.d.ts.map +1 -0
  105. package/dist/jsx/children.d.ts +32 -0
  106. package/dist/jsx/children.d.ts.map +1 -0
  107. package/dist/jsx/dom-attributes.d.ts +13 -0
  108. package/dist/jsx/dom-attributes.d.ts.map +1 -0
  109. package/dist/jsx/dynamic-tags.d.ts +20 -0
  110. package/dist/jsx/dynamic-tags.d.ts.map +1 -0
  111. package/dist/jsx/events.d.ts +4 -0
  112. package/dist/jsx/events.d.ts.map +1 -0
  113. package/dist/jsx/refs.d.ts +15 -0
  114. package/dist/jsx/refs.d.ts.map +1 -0
  115. package/dist/jsx/svg.d.ts +11 -0
  116. package/dist/jsx/svg.d.ts.map +1 -0
  117. package/dist/lifecycle.d.ts +31 -0
  118. package/dist/lifecycle.d.ts.map +1 -0
  119. package/dist/linker.d.ts +19 -0
  120. package/dist/linker.d.ts.map +1 -0
  121. package/dist/lists/calculated-sources.d.ts +8 -0
  122. package/dist/lists/calculated-sources.d.ts.map +1 -0
  123. package/dist/lists/map-site.d.ts +50 -0
  124. package/dist/lists/map-site.d.ts.map +1 -0
  125. package/dist/lists/source-shapes.d.ts +6 -0
  126. package/dist/lists/source-shapes.d.ts.map +1 -0
  127. package/dist/lists.d.ts +7 -0
  128. package/dist/lists.d.ts.map +1 -0
  129. package/dist/module-control-flow.d.ts +8 -0
  130. package/dist/module-control-flow.d.ts.map +1 -0
  131. package/dist/mutation-analysis.d.ts +42 -0
  132. package/dist/mutation-analysis.d.ts.map +1 -0
  133. package/dist/plugin.d.ts +27 -0
  134. package/dist/plugin.d.ts.map +1 -0
  135. package/package.json +30 -0
@@ -0,0 +1,11 @@
1
+ /**
2
+ * components/ref-props.ts - discover ref adapters crossing component APIs.
3
+ *
4
+ * A prop becomes a ref prop only when the receiving component authors it in
5
+ * `ref={...}`. Callers can then turn assignable JSX sinks into callbacks
6
+ * before the ordinary props ABI reads their values.
7
+ */
8
+ import type { Ctx } from '../context';
9
+ /** Mark every declared prop that a component forwards into a JSX ref slot. */
10
+ export declare function scanRefProps(ctx: Ctx): void;
11
+ //# sourceMappingURL=ref-props.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ref-props.d.ts","sourceRoot":"","sources":["../../src/components/ref-props.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAGH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AAItC,8EAA8E;AAC9E,wBAAgB,YAAY,CAAC,GAAG,EAAE,GAAG,GAAG,IAAI,CAmB3C"}
@@ -0,0 +1,19 @@
1
+ import type { NodePath } from '@babel/traverse';
2
+ import * as t from '@babel/types';
3
+ import type { Ctx } from '../context';
4
+ export interface RenderCallbackInvocation {
5
+ propName: string;
6
+ target: t.Expression;
7
+ arguments: t.Expression[];
8
+ }
9
+ /** Is this JSX element the returned root of a declared callback prop value? */
10
+ export declare function isRenderCallbackJsxRoot(ctx: Ctx, element: NodePath<t.JSXElement>): boolean;
11
+ /** Match `items.map((item, index) => renderItem(item, index))`. */
12
+ export declare function matchRenderCallbackMap(ctx: Ctx, componentName: string, call: t.CallExpression): RenderCallbackInvocation | null;
13
+ /**
14
+ * Discover structural callback props before map-site analysis. No callback
15
+ * method names or runtime JSX values are involved: the callee declares the
16
+ * contract by directly returning a prop invocation from a structural map.
17
+ */
18
+ export declare function scanRenderCallbacks(ctx: Ctx): void;
19
+ //# sourceMappingURL=render-callbacks.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"render-callbacks.d.ts","sourceRoot":"","sources":["../../src/components/render-callbacks.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,KAAK,CAAC,MAAM,cAAc,CAAC;AAClC,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AAOtC,MAAM,WAAW,wBAAwB;IACvC,QAAQ,EAAE,MAAM,CAAC;IACjB,MAAM,EAAE,CAAC,CAAC,UAAU,CAAC;IACrB,SAAS,EAAE,CAAC,CAAC,UAAU,EAAE,CAAC;CAC3B;AAED,+EAA+E;AAC/E,wBAAgB,uBAAuB,CACrC,GAAG,EAAE,GAAG,EACR,OAAO,EAAE,QAAQ,CAAC,CAAC,CAAC,UAAU,CAAC,GAC9B,OAAO,CA2CT;AAoDD,mEAAmE;AACnE,wBAAgB,sBAAsB,CACpC,GAAG,EAAE,GAAG,EACR,aAAa,EAAE,MAAM,EACrB,IAAI,EAAE,CAAC,CAAC,cAAc,GACrB,wBAAwB,GAAG,IAAI,CA4BjC;AAED;;;;GAIG;AACH,wBAAgB,mBAAmB,CAAC,GAAG,EAAE,GAAG,GAAG,IAAI,CAmBlD"}
@@ -0,0 +1,4 @@
1
+ import { type Ctx } from '../context';
2
+ /** Expand every locally resolvable JSX-returning call inside components. */
3
+ export declare function normalizeRenderFunctions(ctx: Ctx): void;
4
+ //# sourceMappingURL=render-functions.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"render-functions.d.ts","sourceRoot":"","sources":["../../src/components/render-functions.ts"],"names":[],"mappings":"AASA,OAAO,EAAc,KAAK,GAAG,EAAE,MAAM,YAAY,CAAC;AAgclD,4EAA4E;AAC5E,wBAAgB,wBAAwB,CAAC,GAAG,EAAE,GAAG,GAAG,IAAI,CAgEvD"}
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Ordered replay for pure component-body calculations.
3
+ *
4
+ * Const derivations and pure if/switch assignments share one source order.
5
+ * Partial controls restore their initializer-backed fallbacks before replay.
6
+ * Dirty reasons guard adjacent calculations with equal dependencies; a
7
+ * reason-less update conservatively runs every calculation.
8
+ */
9
+ import * as t from '@babel/types';
10
+ import type { Ctx } from '../context';
11
+ import { type ControlFlowDerivation, type LocalDerivation } from './props';
12
+ export declare function buildRenderPreludeReplay(ctx: Ctx, component: string, reasonVar: string | null, body: t.Statement[], locals: LocalDerivation[], controls: ControlFlowDerivation[]): t.BlockStatement;
13
+ //# sourceMappingURL=render-prelude.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"render-prelude.d.ts","sourceRoot":"","sources":["../../src/components/render-prelude.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,OAAO,KAAK,CAAC,MAAM,cAAc,CAAC;AAClC,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAEL,KAAK,qBAAqB,EAC1B,KAAK,eAAe,EACrB,MAAM,SAAS,CAAC;AAejB,wBAAgB,wBAAwB,CACtC,GAAG,EAAE,GAAG,EACR,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,MAAM,GAAG,IAAI,EACxB,IAAI,EAAE,CAAC,CAAC,SAAS,EAAE,EACnB,MAAM,EAAE,eAAe,EAAE,EACzB,QAAQ,EAAE,qBAAqB,EAAE,GAChC,CAAC,CAAC,cAAc,CAqElB"}
@@ -0,0 +1,27 @@
1
+ /**
2
+ * Normalize supported JSX return control flow into one stable branch picker.
3
+ */
4
+ import type { NodePath } from '@babel/traverse';
5
+ import * as t from '@babel/types';
6
+ import type { JsxNode } from '../jsx/children';
7
+ export interface ComponentReturnPlan {
8
+ /** Branch picker passed directly to createCondRegion(). */
9
+ pick: t.ArrowFunctionExpression;
10
+ branches: JsxNode[];
11
+ /** Top-level source statements replaced by the structural region. */
12
+ statements: Set<t.Statement>;
13
+ }
14
+ export interface DirectComponentReturn {
15
+ jsx: JsxNode;
16
+ statement: t.ReturnStatement;
17
+ }
18
+ export type ComponentReturns = DirectComponentReturn | ComponentReturnPlan;
19
+ /**
20
+ * Supported structural forms:
21
+ * - one direct JSX return
22
+ * - a contiguous tail chain of `if (test) return <JSX>` plus final return
23
+ * - a terminal if/else whose two arms return JSX
24
+ * - a terminal exhaustive switch whose cases return JSX
25
+ */
26
+ export declare function analyzeComponentReturns(path: NodePath<t.FunctionDeclaration>, name: string): ComponentReturns;
27
+ //# sourceMappingURL=return-plan.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"return-plan.d.ts","sourceRoot":"","sources":["../../src/components/return-plan.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,KAAK,CAAC,MAAM,cAAc,CAAC;AAClC,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAE/C,MAAM,WAAW,mBAAmB;IAClC,2DAA2D;IAC3D,IAAI,EAAE,CAAC,CAAC,uBAAuB,CAAC;IAChC,QAAQ,EAAE,OAAO,EAAE,CAAC;IACpB,qEAAqE;IACrE,UAAU,EAAE,GAAG,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC;CAC9B;AAED,MAAM,WAAW,qBAAqB;IACpC,GAAG,EAAE,OAAO,CAAC;IACb,SAAS,EAAE,CAAC,CAAC,eAAe,CAAC;CAC9B;AAED,MAAM,MAAM,gBAAgB,GAAG,qBAAqB,GAAG,mBAAmB,CAAC;AAqH3E;;;;;;GAMG;AACH,wBAAgB,uBAAuB,CACrC,IAAI,EAAE,QAAQ,CAAC,CAAC,CAAC,mBAAmB,CAAC,EACrC,IAAI,EAAE,MAAM,GACX,gBAAgB,CA2FlB"}
@@ -0,0 +1,21 @@
1
+ /**
2
+ * conds.ts - conditional-site analysis.
3
+ *
4
+ * Direct JSX-child ternaries and logical conditions become anchored regions.
5
+ * Right-associated ternary chains flatten into one multi-branch region.
6
+ */
7
+ import type { NodePath } from '@babel/traverse';
8
+ import * as t from '@babel/types';
9
+ import type { JsxNode } from './jsx/children';
10
+ export interface CondSite {
11
+ /** Expression selecting an index in branches. */
12
+ pickExpr: t.Expression;
13
+ branches: (JsxNode | null)[];
14
+ /** `when0`, `when1`, ... per owner, source order. */
15
+ suffix: string;
16
+ }
17
+ export declare function matchCond(expr: t.Node): t.ConditionalExpression | t.LogicalExpression | null;
18
+ export declare function analyzeCondSite(expr: t.ConditionalExpression | t.LogicalExpression, errorAt: Pick<NodePath, 'buildCodeFrameError'>, usedConds: {
19
+ count: number;
20
+ }): CondSite;
21
+ //# sourceMappingURL=conds.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"conds.d.ts","sourceRoot":"","sources":["../src/conds.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,KAAK,CAAC,MAAM,cAAc,CAAC;AAGlC,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAE9C,MAAM,WAAW,QAAQ;IACvB,iDAAiD;IACjD,QAAQ,EAAE,CAAC,CAAC,UAAU,CAAC;IACvB,QAAQ,EAAE,CAAC,OAAO,GAAG,IAAI,CAAC,EAAE,CAAC;IAC7B,qDAAqD;IACrD,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,wBAAgB,SAAS,CACvB,IAAI,EAAE,CAAC,CAAC,IAAI,GACX,CAAC,CAAC,qBAAqB,GAAG,CAAC,CAAC,iBAAiB,GAAG,IAAI,CAStD;AAsCD,wBAAgB,eAAe,CAC7B,IAAI,EAAE,CAAC,CAAC,qBAAqB,GAAG,CAAC,CAAC,iBAAiB,EACnD,OAAO,EAAE,IAAI,CAAC,QAAQ,EAAE,qBAAqB,CAAC,EAC9C,SAAS,EAAE;IAAE,KAAK,EAAE,MAAM,CAAA;CAAE,GAC3B,QAAQ,CAiEV"}
@@ -0,0 +1,51 @@
1
+ import * as t from '@babel/types';
2
+ import type { Ctx, StateKind } from './model';
3
+ /** Register a state binding while preserving a linker-provided import entry. */
4
+ export declare function registerState(ctx: Ctx, name: string, kind: StateKind): void;
5
+ /** Convert a binding-relative analysis key to its defining module identity. */
6
+ export declare function canonicalStateKey(ctx: Ctx, key: string): string;
7
+ /** Hoist and dedupe a canonical write-set constant. */
8
+ export declare function freshWriteConst(ctx: Ctx, writes: readonly string[]): t.Identifier;
9
+ /** Hoist and dedupe a sorted array used to batch local dirty reasons. */
10
+ export declare function freshReasonConst(ctx: Ctx, reasons: readonly number[]): t.Identifier;
11
+ /** Static property-path key for `a.b.c`, or null for a dynamic path. */
12
+ export declare function memberKey(node: t.MemberExpression): string | null;
13
+ /** Reactive list-row context used during event-handler analysis. */
14
+ export interface RowCtx {
15
+ itemParam: string;
16
+ itemPath: string[];
17
+ rowIdVar: string;
18
+ refreshVar?: string;
19
+ keyPath: string[] | null;
20
+ sourceKey: string;
21
+ sourceLocal?: boolean;
22
+ ownerIdVar?: string;
23
+ }
24
+ /** Extract a row key path relative to its item parameter. */
25
+ export declare function keyPathOf(keyExpr: t.Expression | null, itemParam: string): string[] | null;
26
+ /** Whether an item-relative write can alter the authored row key. */
27
+ export declare function writeTouchesKey(writtenSegments: string[], keyPath: string[] | null): boolean;
28
+ export interface ComputedAnalysis {
29
+ reads: Set<string>;
30
+ impure: boolean;
31
+ reason?: string;
32
+ }
33
+ /** Root identifier of a member chain, including dynamic member segments. */
34
+ export declare function memberRootName(node: t.MemberExpression): string | null;
35
+ /** Whether an initializer is a statically-shaped plain object store. */
36
+ export declare function isStoreObject(init: t.Expression | null | undefined): boolean;
37
+ /** Whether a const initializer creates a mutable object root. */
38
+ export declare function isConstObjectState(init: t.Expression | null | undefined): boolean;
39
+ /** Unwrap a string or expression-container JSX attribute value. */
40
+ export declare function attrExpr(value: t.JSXAttribute['value']): t.Expression | null;
41
+ /** Whether an expression references any reactive binding in its scope model. */
42
+ export declare function exprReadsState(ctx: Ctx, expression: t.Node, componentName?: string): boolean;
43
+ /** Whether an expression references state owned by one component instance. */
44
+ export declare function exprReadsInstanceState(ctx: Ctx, expression: t.Node, componentName: string): boolean;
45
+ /** Walk raw AST nodes; returning false skips a node's children. */
46
+ export declare function walkNodes(root: t.Node, visit: (node: t.Node, parent: t.Node | null) => void | boolean): void;
47
+ /** Whether a raw AST subtree contains JSX. */
48
+ export declare function nodeHasJsx(root: t.Node): boolean;
49
+ /** Root state identifiers referenced by a raw AST subtree. */
50
+ export declare function collectStateIds(ctx: Ctx, root: t.Node): Set<string>;
51
+ //# sourceMappingURL=ast.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ast.d.ts","sourceRoot":"","sources":["../../src/context/ast.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAC,MAAM,cAAc,CAAC;AAElC,OAAO,KAAK,EAAE,GAAG,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAE9C,gFAAgF;AAChF,wBAAgB,aAAa,CAAC,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,SAAS,GAAG,IAAI,CAK3E;AAED,+EAA+E;AAC/E,wBAAgB,iBAAiB,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,M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E;AAED,wEAAwE;AACxE,wBAAgB,aAAa,CAC3B,IAAI,EAAE,CAAC,CAAC,UAAU,GAAG,IAAI,GAAG,SAAS,GACpC,OAAO,CAQT;AAED,iEAAiE;AACjE,wBAAgB,kBAAkB,CAChC,IAAI,EAAE,CAAC,CAAC,UAAU,GAAG,IAAI,GAAG,SAAS,GACpC,OAAO,CAGT;AAED,mEAAmE;AACnE,wBAAgB,QAAQ,CACtB,KAAK,EAAE,CAAC,CAAC,YAAY,CAAC,OAAO,CAAC,GAC7B,CAAC,CAAC,UAAU,GAAG,IAAI,CASrB;AAED,gFAAgF;AAChF,wBAAgB,cAAc,CAC5B,GAAG,EAAE,GAAG,EACR,UAAU,EAAE,CAAC,CAAC,IAAI,EAClB,aAAa,CAAC,EAAE,MAAM,GACrB,OAAO,CAyCT;AAED,8EAA8E;AAC9E,wBAAgB,sBAAsB,CACpC,GAAG,EAAE,GAAG,EACR,UAAU,EAAE,CAAC,CAAC,IAAI,EAClB,aAAa,EAAE,MAAM,GACpB,OAAO,CAiBT;AAED,mEAAmE;AACnE,wBAAgB,SAAS,CACvB,IAAI,EAAE,CAAC,CAAC,IAAI,EACZ,KAAK,EAAE,CAAC,IAAI,EAAE,CAAC,CAAC,IAAI,EAAE,MAAM,EAAE,CAAC,CAAC,IAAI,GAAG,IAAI,KAAK,IAAI,GAAG,OAAO,GAC7D,IAAI,CAiBN;AAED,8CAA8C;AAC9C,wBAAgB,UAAU,CAAC,IAAI,EAAE,CAAC,CAAC,IAAI,GAAG,OAAO,CAMhD;AAED,8DAA8D;AAC9D,wBAAgB,eAAe,CAAC,GAAG,EAAE,GAAG,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI,GAAG,GAAG,CAAC,MAAM,CAAC,CAcnE"}
@@ -0,0 +1,309 @@
1
+ /**
2
+ * context.ts — shared compiler state and pure AST helpers.
3
+ *
4
+ * Every module (analysis / handlers / lists / emit) takes the same Ctx, so
5
+ * the plugin shell in plugin.ts stays a thin visitor wiring layer. One Ctx
6
+ * is created per compiled module.
7
+ */
8
+ import type { NodePath } from '@babel/traverse';
9
+ import * as t from '@babel/types';
10
+ import type { ComponentPropsPlan, ControlFlowDerivation, LocalDerivation } from '../components/props';
11
+ import type { GeneratedIdentifiers } from '../identifiers';
12
+ export interface MemoDomOptions {
13
+ /** Module specifier compiled output imports the runtime from. */
14
+ runtimePath?: string;
15
+ /** Entity id of the root component. */
16
+ rootId?: string;
17
+ /**
18
+ * Stable identity for this source module. Defaults to `./component.tsx`.
19
+ * Module-state keys are always `<moduleId>#<binding>[.<path>]`.
20
+ */
21
+ moduleId?: string;
22
+ /**
23
+ * Resolved import metadata supplied by compileModules(). This is public for
24
+ * bundler integrations that perform their own graph/link pass.
25
+ */
26
+ linkedImports?: Record<string, LinkedImport>;
27
+ /** Caller-derived runtime placements for components declared in this file. */
28
+ linkedComponentPaths?: Record<string, string[]>;
29
+ /** Cross-file keyed-row uses for components declared in this file. */
30
+ linkedComponentRows?: Record<string, LinkedComponentRowUse[]>;
31
+ /** Caller-resolved state boundaries for each declaration's named props. */
32
+ linkedComponentPropSources?: Record<string, Record<string, LinkedComponentPropSource>>;
33
+ /** Linker-resolved render-slot props for declarations in this module. */
34
+ linkedComponentRenderProps?: Record<string, string[]>;
35
+ }
36
+ export interface LinkedStateImport {
37
+ type: 'state';
38
+ kind: StateKind;
39
+ /** Canonical root key of the defining export (`./state.ts#store`). */
40
+ key: string;
41
+ /** Finite intrinsic-tag identities declared by a string-literal union. */
42
+ tagCandidates?: string[];
43
+ /** Finite component identities reachable through this state/registry. */
44
+ componentCandidates?: LinkedDynamicComponentCandidate[];
45
+ }
46
+ export interface LinkedFunctionImport {
47
+ type: 'function';
48
+ /** Finite intrinsic-tag identities declared by the helper return type. */
49
+ tagCandidates?: string[];
50
+ /** Finite component identities declared by helper returns. */
51
+ componentCandidates?: LinkedDynamicComponentCandidate[];
52
+ reads: string[];
53
+ /** Directly proven state writes. */
54
+ writes: string[];
55
+ /** Conservative effects bounded to serialized state roots. */
56
+ boundedWrites: string[];
57
+ /** Effects on arguments, expressed as paths relative to each argument. */
58
+ parameterWrites: ParameterWrite[];
59
+ /** Effects may extend beyond every known root and argument. */
60
+ unbounded: boolean;
61
+ }
62
+ export interface LinkedComponentImport {
63
+ type: 'component';
64
+ /** Canonical declaration identity (`./Row.tsx#Row`). */
65
+ key: string;
66
+ /** Declared positional names or closed object-pattern property names. */
67
+ props: string[];
68
+ objectProps: boolean;
69
+ /** Generic object bindings and object rest accept additional properties. */
70
+ acceptsUnknownProps: boolean;
71
+ hasWholeDefault: boolean;
72
+ /** Whether keyed-row compilation can use the allocation-free row ABI. */
73
+ listLightweight: boolean;
74
+ /** Host event attributes can use a caller-owned delegated list root. */
75
+ delegatedEvents?: boolean;
76
+ /** Props consumed as compiler-owned mount slots. */
77
+ renderProps?: string[];
78
+ /** Props consumed as caller-owned structural row factories. */
79
+ renderCallbacks?: string[];
80
+ /** Props consumed as DOM ref adapters. */
81
+ refProps?: string[];
82
+ /** Canonical module dependencies read by this component and descendants. */
83
+ subtreeReads?: string[];
84
+ }
85
+ export interface LinkedDynamicComponentCandidate extends Omit<LinkedComponentImport, 'type'> {
86
+ /** Module specifier synthesized into the consuming module. */
87
+ source: string;
88
+ /** Named export imported from `source`. */
89
+ imported: string;
90
+ }
91
+ export interface LinkedComponentRowUse {
92
+ /** Key path relative to the row callback parameter, or null. */
93
+ keyPath: string[] | null;
94
+ /** Canonical module key or binding-relative instance key of the source. */
95
+ sourceKey: string;
96
+ /** The reactive collection source belongs to one caller component instance. */
97
+ sourceLocal: boolean;
98
+ }
99
+ export interface LinkedComponentPropSource {
100
+ /** Canonical state boundaries that may supply this prop. */
101
+ keys: string[];
102
+ /** At least one call site cannot be bounded to canonical module state. */
103
+ rootFallback: boolean;
104
+ }
105
+ export type LinkedImport = LinkedStateImport | LinkedFunctionImport | LinkedComponentImport;
106
+ export interface ParameterWrite {
107
+ index: number;
108
+ path: string[];
109
+ }
110
+ /**
111
+ * Reactive-state classification (the two — three — legal ways JS state changes):
112
+ * 'let' — rebindable binding; writes are assignments/updates/mutations
113
+ * 'store' — const plain-object literal; writes are property mutations (path-keyed)
114
+ * 'const' - constructor-created object or array; mutations are allowed,
115
+ * rebinding is a compile error (JS would TypeError at runtime)
116
+ */
117
+ export type StateKind = 'let' | 'store' | 'const' | 'computed';
118
+ export interface CompInfo {
119
+ /**
120
+ * Names of ALL parent components (a shared child has several). Empty for
121
+ * the root. M5.3: was a single `parent` — multi-parent components misrouted.
122
+ */
123
+ parents: Set<string>;
124
+ /** Number of host JSX elements (diagnostic / future suffix paths). */
125
+ jsxCount: number;
126
+ }
127
+ /** A list site owned by a component: region id-prefix is '<path(owner)>/<suffix>'. */
128
+ export interface SiteRef {
129
+ owner: string;
130
+ suffix: string;
131
+ /** R11: row-analysis data for item-write routing in listed components. */
132
+ itemParam?: string;
133
+ keyExpr?: t.Expression | null;
134
+ sourceKey?: string;
135
+ /** Instance sources invalidate their owner directly, never through a table. */
136
+ sourceLocal?: boolean;
137
+ }
138
+ /** Module-level helper function summary (M5.3 interprocedural analysis). */
139
+ export interface FnSummary {
140
+ reads: Set<string>;
141
+ /** Directly proven state writes. */
142
+ writes: Set<string>;
143
+ /** Conservative effects bounded to module-state roots. */
144
+ boundedWrites: Set<string>;
145
+ /** Effects on arguments, expressed as paths relative to each argument. */
146
+ parameterWrites: ParameterWrite[];
147
+ /** True when effects cannot be bounded to known roots or arguments. */
148
+ unbounded: boolean;
149
+ }
150
+ /** One compiler-owned reactive side effect declared in a component body. */
151
+ export interface EffectSite {
152
+ /** Stable source-order suffix within the owning component. */
153
+ index: number;
154
+ /** Source statement removed from ordinary factory initialization. */
155
+ statement: t.Statement;
156
+ /** Callback registered with the runtime after DOM creation. */
157
+ callback: t.Expression;
158
+ /** Canonical or binding-relative module state read by the callback. */
159
+ moduleReads: Set<string>;
160
+ /** Instance state/prop roots that can change callback observations. */
161
+ localReads: Set<string>;
162
+ /** Instance local derivations read by the callback. */
163
+ localDerivationReads: Set<string>;
164
+ /** Reactive activation gate for a conditional effect. */
165
+ condition: t.Expression | null;
166
+ conditionModuleReads: Set<string>;
167
+ conditionLocalReads: Set<string>;
168
+ conditionLocalDerivationReads: Set<string>;
169
+ }
170
+ /** One singleton reactive effect declared directly at module scope. */
171
+ export interface ModuleEffectSite {
172
+ index: number;
173
+ statement: t.Statement;
174
+ callback: t.Expression;
175
+ moduleReads: Set<string>;
176
+ condition: t.Expression | null;
177
+ conditionModuleReads: Set<string>;
178
+ entityId: string;
179
+ }
180
+ export interface ModuleControlFlowDerivation {
181
+ statement: t.IfStatement | t.SwitchStatement;
182
+ bindings: string[];
183
+ sources: string[];
184
+ entityId: string;
185
+ }
186
+ export type HelperPath = NodePath<t.FunctionDeclaration | t.ArrowFunctionExpression | t.FunctionExpression>;
187
+ export interface Ctx {
188
+ runtimePath: string;
189
+ rootId: string;
190
+ moduleId: string;
191
+ state: Map<string, StateKind>;
192
+ /** Local binding name -> canonical state root. */
193
+ stateKeys: Map<string, string>;
194
+ /** Finite intrinsic-tag identities proven by state type annotations. */
195
+ stateTagCandidates: Map<string, string[]>;
196
+ functionTagCandidates: Map<string, string[]>;
197
+ stateComponentCandidates: Map<string, string[]>;
198
+ functionComponentCandidates: Map<string, string[]>;
199
+ linkedDynamicComponentCandidates: Map<string, LinkedDynamicComponentCandidate[]>;
200
+ /** Imported ES bindings cannot be rebound, even when their export is a `let`. */
201
+ importedState: Set<string>;
202
+ /** Linked summaries for imported functions and conservative external calls. */
203
+ importedFunctions: Map<string, FnSummary>;
204
+ importedComponents: Map<string, LinkedComponentImport>;
205
+ /** Graph-linked placements for declarations in this module. */
206
+ linkedComponentPaths: Map<string, string[]>;
207
+ /** Graph-linked keyed-row modes for declarations in this module. */
208
+ linkedComponentRows: Map<string, LinkedComponentRowUse[]>;
209
+ linkedComponentPropSources: Map<string, Map<string, LinkedComponentPropSource>>;
210
+ linkedComponentRenderProps: Map<string, string[]>;
211
+ comps: Map<string, CompInfo>;
212
+ compPaths: Map<string, NodePath<t.FunctionDeclaration>>;
213
+ /** Top-level functions WITHOUT JSX — helpers, summarized for interprocedural effects. */
214
+ helpers: Map<string, HelperPath>;
215
+ /** JSX-returning functions expanded at local render call sites. */
216
+ jsxHelpers: Map<string, HelperPath>;
217
+ helperSummaries: Map<string, FnSummary>;
218
+ compReads: Map<string, Set<string>>;
219
+ /** parent comp → child comp → number of static JSX references. */
220
+ childRefCounts: Map<string, Map<string, number>>;
221
+ /**
222
+ * Lexical component owners that author one or more deferred render slots.
223
+ * Runtime mounts after the first receive a `$slot[n]` identity segment;
224
+ * access-table paths expand only for these owners.
225
+ */
226
+ renderSlotOwners: Set<string>;
227
+ /**
228
+ * Components used as list rows: child comp name → the sites ('<path(owner)>/<suffix>')
229
+ * at whose 'Row[k]' its instances live. A listed component is multi-instance:
230
+ * never locality-eligible.
231
+ */
232
+ listedSites: Map<string, SiteRef[]>;
233
+ /** Local declarations containing one or more host JSX event attributes. */
234
+ componentsWithHostEvents: Set<string>;
235
+ /** Components mounted lexically inside conditional branch factories. */
236
+ conditionalComponentSites: Map<string, SiteRef[]>;
237
+ /** Components mounted beneath keyed inline host-row factories. */
238
+ rowComponentSites: Map<string, SiteRef[]>;
239
+ /** Local and imported JSX call contracts, captured before params are rewritten. */
240
+ componentProps: Map<string, ComponentPropsPlan>;
241
+ /** Memoized isLightweightListedComponent results (the eligibility check traverses the AST). */
242
+ lightweightCache: Map<string, boolean>;
243
+ /** Inline-row reads: '<owner>/<suffix>' → site + state vars read in the row JSX. */
244
+ rowReads: Map<string, {
245
+ owner: string;
246
+ suffix: string;
247
+ vars: Set<string>;
248
+ }>;
249
+ /** Conditional-region reads (R8): '<owner>/when<n>' → site + vars read in condition+branches. */
250
+ condReads: Map<string, {
251
+ owner: string;
252
+ suffix: string;
253
+ vars: Set<string>;
254
+ }>;
255
+ /**
256
+ * R12: instance state — component name → top-level let/var names of its
257
+ * body. Instance state lives in the factory closure of ONE instance: it
258
+ * is readable only by that instance (it reaches children exclusively via
259
+ * props, which R10 re-pushes on every parent render; nested rows are
260
+ * resynced by the M5.5 reconcile machinery). Writes therefore need NO
261
+ * access-table routing — they are unconditionally `markDirty(id)`.
262
+ * Instance names SHADOW same-named module state inside their component.
263
+ */
264
+ instanceState: Map<string, Set<string>>;
265
+ /** Ordered local binding/pattern derivations replayed in the owner update. */
266
+ instanceDerivations: Map<string, LocalDerivation[]>;
267
+ /** Pure top-level if/switch calculations replayed in source order. */
268
+ instanceControlFlow: Map<string, ControlFlowDerivation[]>;
269
+ /** All bindings introduced by local derivations, for locality and writes. */
270
+ instanceDerivedBindings: Map<string, Set<string>>;
271
+ /** Numeric dirty reasons for exact local write roots. */
272
+ instanceReasonIds: Map<string, Map<string, number>>;
273
+ /** Components whose local dependency graph has skippable work. */
274
+ selectiveDerivationComponents: Set<string>;
275
+ /** Compiler-owned reactive effects, in source order per component. */
276
+ effects: Map<string, EffectSite[]>;
277
+ /** Module-owned singleton effects, in source order. */
278
+ moduleEffects: ModuleEffectSite[];
279
+ /**
280
+ * R13: auto-detected computeds — module-level `const x = <state
281
+ * derivation>` (detection by REFERENCE: any expression mentioning state).
282
+ * reads = the source state keys the derivation reads
283
+ * (root names for lets/computeds, dotted keys for stores). The compiler
284
+ * rewrites the declaration to a let + registers a depth-(-1) entity whose
285
+ * render recomputes and commits 'x' downstream ONLY when the value
286
+ * actually changed (computedChanged).
287
+ */
288
+ computeds: Map<string, {
289
+ reads: Set<string>;
290
+ }>;
291
+ /** Pure exhaustive module-level if/switch calculations. */
292
+ moduleControlFlow: ModuleControlFlowDerivation[];
293
+ header: t.Statement[];
294
+ readers: Map<string, Set<string>>;
295
+ writeConstCounter: number;
296
+ /** Dedupe table for hoisted write-set consts: joined writes → const name. */
297
+ writeConsts: Map<string, string>;
298
+ reasonConstCounter: number;
299
+ /** Dedupe table for hoisted multi-reason arrays. */
300
+ reasonConsts: Map<string, string>;
301
+ /** Function nodes whose handler analysis already ran (shared declarations). */
302
+ analyzedFunctions: WeakSet<t.Node>;
303
+ /** Whether a shared handler already emits a commit in its event scope. */
304
+ handlerHasRootCommit: WeakMap<t.Node, boolean>;
305
+ /** Compiler-wide allocator initialized from the original Program scope. */
306
+ identifiers: GeneratedIdentifiers | null;
307
+ }
308
+ export declare function createCtx(opts?: MemoDomOptions): Ctx;
309
+ //# sourceMappingURL=model.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"model.d.ts","sourceRoot":"","sources":["../../src/context/model.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,KAAK,CAAC,MAAM,cAAc,CAAC;AAClC,OAAO,KAAK,EACV,kBAAkB,EAClB,qBAAqB,EACrB,eAAe,EAChB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AAE3D,MAAM,WAAW,cAAc;IAC7B,iEAAiE;IACjE,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,uCAAuC;IACvC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;;OAGG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,YAAY,CAAC,CAAC;IAC7C,8EAA8E;IAC9E,oBAAoB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;IAChD,sEAAsE;IACtE,mBAAmB,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,qBAAqB,EAAE,CAAC,CAAC;IAC9D,2EAA2E;IAC3E,0BAA0B,CAAC,EAAE,MAAM,CACjC,MAAM,EACN,MAAM,CAAC,MAAM,EAAE,yBAAyB,CAAC,CAC1C,CAAC;IACF,yEAAyE;IACzE,0BAA0B,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;CACvD;AAED,MA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EAAE;QAAE,KAAK,EAAE,GAAG,CAAC,MAAM,CAAC,CAAA;KAAE,CAAC,CAAC;IAC/C,2DAA2D;IAC3D,iBAAiB,EAAE,2BAA2B,EAAE,CAAC;IAGjD,MAAM,EAAE,CAAC,CAAC,SAAS,EAAE,CAAC;IACtB,OAAO,EAAE,GAAG,CAAC,MAAM,EAAE,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC;IAClC,iBAAiB,EAAE,MAAM,CAAC;IAC1B,6EAA6E;IAC7E,WAAW,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjC,kBAAkB,EAAE,MAAM,CAAC;IAC3B,oDAAoD;IACpD,YAAY,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAClC,+EAA+E;IAC/E,iBAAiB,EAAE,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC;IACnC,0EAA0E;IAC1E,oBAAoB,EAAE,OAAO,CAAC,CAAC,CAAC,IAAI,EAAE,OAAO,CAAC,CAAC;IAC/C,2EAA2E;IAC3E,WAAW,EAAE,oBAAoB,GAAG,IAAI,CAAC;CAC1C;AAED,wBAAgB,SAAS,CAAC,IAAI,GAAE,cAAmB,GAAG,GAAG,CA8JxD"}
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Stable facade for shared compiler context types and AST utilities.
3
+ *
4
+ * Keeping this module preserves existing imports while implementation details
5
+ * are grouped under context/.
6
+ */
7
+ export * from './context/model';
8
+ export * from './context/ast';
9
+ //# sourceMappingURL=context.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../src/context.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,cAAc,iBAAiB,CAAC;AAChC,cAAc,eAAe,CAAC"}
@@ -0,0 +1,26 @@
1
+ /**
2
+ * Compiler intrinsic `effect(() => ...)`.
3
+ *
4
+ * Effects are component-owned, statically subscribed callbacks. Their runtime
5
+ * entities execute only after render entities have drained, and own the latest
6
+ * teardown returned by the callback.
7
+ */
8
+ import type { NodePath } from '@babel/traverse';
9
+ import * as t from '@babel/types';
10
+ import { type Ctx, type EffectSite } from './context';
11
+ import type { EmitScope } from './emission/scope';
12
+ /**
13
+ * Discover and validate direct component-body effect statements.
14
+ */
15
+ export declare function scanEffects(ctx: Ctx, programPath: NodePath<t.Program>): void;
16
+ /**
17
+ * Dirty local/prop-dependent effect entities after the owner's DOM update.
18
+ */
19
+ export declare function buildLocalEffectInvalidations(ctx: Ctx, component: string, factoryId: string, reasonVar: string | null, sites: EffectSite[], scope?: EmitScope): t.Statement;
20
+ /** Runtime registrations emitted after the owner's DOM creation statements. */
21
+ export declare function buildEffectRegistrations(ctx: Ctx, factoryId: string, sites: EffectSite[]): t.Statement[];
22
+ /** Lower direct module effects to stable singleton registrations. */
23
+ export declare function rewriteModuleEffects(ctx: Ctx, programPath: NodePath<t.Program>): void;
24
+ /** Reject effect syntax that was not consumed by component emission. */
25
+ export declare function rejectUnownedEffects(programPath: NodePath<t.Program>): void;
26
+ //# sourceMappingURL=effects.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"effects.d.ts","sourceRoot":"","sources":["../src/effects.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,KAAK,CAAC,MAAM,cAAc,CAAC;AAClC,OAAO,EAIL,KAAK,GAAG,EACR,KAAK,UAAU,EAEhB,MAAM,WAAW,CAAC;AAInB,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AA6flD;;GAEG;AACH,wBAAgB,WAAW,CACzB,GAAG,EAAE,GAAG,EACR,WAAW,EAAE,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAC,GAC/B,IAAI,CAuFN;AAoDD;;GAEG;AACH,wBAAgB,6BAA6B,CAC3C,GAAG,EAAE,GAAG,EACR,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,MAAM,GAAG,IAAI,EACxB,KAAK,EAAE,UAAU,EAAE,EACnB,KAAK,CAAC,EAAE,SAAS,GAChB,CAAC,CAAC,SAAS,CAkGb;AAED,+EAA+E;AAC/E,wBAAgB,wBAAwB,CACtC,GAAG,EAAE,GAAG,EACR,SAAS,EAAE,MAAM,EACjB,KAAK,EAAE,UAAU,EAAE,GAClB,CAAC,CAAC,SAAS,EAAE,CA0Bf;AASD,qEAAqE;AACrE,wBAAgB,oBAAoB,CAClC,GAAG,EAAE,GAAG,EACR,WAAW,EAAE,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAC,GAC/B,IAAI,CA+DN;AAED,wEAAwE;AACxE,wBAAgB,oBAAoB,CAClC,WAAW,EAAE,QAAQ,CAAC,CAAC,CAAC,OAAO,CAAC,GAC/B,IAAI,CAUN"}
@@ -0,0 +1,12 @@
1
+ /**
2
+ * emission/component.ts - component source functions to runtime factories.
3
+ *
4
+ * This emitter owns the component factory ABI, prop and local-derivation
5
+ * replay order, lifecycle registration, and listed-row identity. DOM and
6
+ * structural-region creation remain in emit.ts.
7
+ */
8
+ import type { NodePath } from '@babel/traverse';
9
+ import * as t from '@babel/types';
10
+ import { type Ctx } from '../context';
11
+ export declare function transformComponent(ctx: Ctx, path: NodePath<t.FunctionDeclaration>, name: string): void;
12
+ //# sourceMappingURL=component.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"component.d.ts","sourceRoot":"","sources":["../../src/emission/component.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,KAAK,CAAC,MAAM,cAAc,CAAC;AAElC,OAAO,EAEL,KAAK,GAAG,EAET,MAAM,YAAY,CAAC;AAgCpB,wBAAgB,kBAAkB,CAChC,GAAG,EAAE,GAAG,EACR,IAAI,EAAE,QAAQ,CAAC,CAAC,CAAC,mBAAmB,CAAC,EACrC,IAAI,EAAE,MAAM,GACX,IAAI,CA2RN"}
@@ -0,0 +1,13 @@
1
+ import type { NodePath } from '@babel/traverse';
2
+ import * as t from '@babel/types';
3
+ import { type Ctx } from '../context';
4
+ import type { JsxNode } from '../jsx/children';
5
+ import { type EmitScope } from './scope';
6
+ import type { NodeEmitter } from './node-emitter';
7
+ /** Emit an anchored conditional region owned by a component or row. */
8
+ export declare function emitConditionalRegion(ctx: Ctx, scope: EmitScope, expression: t.ConditionalExpression | t.LogicalExpression, parentElementVariable: string, componentName: string, componentPath: NodePath<t.FunctionDeclaration>, emitNode: NodeEmitter, inSvg?: boolean, ownerId?: t.Expression, forwardFromOwner?: boolean): void;
9
+ /** Build a non-entity branch factory with isolated slots and cleanup. */
10
+ export declare function buildConditionalBranchCreate(ctx: Ctx, jsx: JsxNode, componentName: string, componentPath: NodePath<t.FunctionDeclaration>, regionId: t.Expression, emitNode: NodeEmitter, inSvg?: boolean, ownerId?: t.Expression, allowConditions?: boolean, usedConditions?: {
11
+ count: number;
12
+ }): t.ArrowFunctionExpression;
13
+ //# sourceMappingURL=conditional-region.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"conditional-region.d.ts","sourceRoot":"","sources":["../../src/emission/conditional-region.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,KAAK,CAAC,MAAM,cAAc,CAAC;AAClC,OAAO,EAEL,KAAK,GAAG,EACT,MAAM,YAAY,CAAC;AAGpB,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAKL,KAAK,SAAS,EACf,MAAM,SAAS,CAAC;AACjB,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAElD,uEAAuE;AACvE,wBAAgB,qBAAqB,CACnC,GAAG,EAAE,GAAG,EACR,KAAK,EAAE,SAAS,EAChB,UAAU,EAAE,CAAC,CAAC,qBAAqB,GAAG,CAAC,CAAC,iBAAiB,EACzD,qBAAqB,EAAE,MAAM,EAC7B,aAAa,EAAE,MAAM,EACrB,aAAa,EAAE,QAAQ,CAAC,CAAC,CAAC,mBAAmB,CAAC,EAC9C,QAAQ,EAAE,WAAW,EACrB,KAAK,UAAQ,EACb,OAAO,GAAE,CAAC,CAAC,UAA4C,EACvD,gBAAgB,UAAQ,GACvB,IAAI,CA+EN;AAED,yEAAyE;AACzE,wBAAgB,4BAA4B,CAC1C,GAAG,EAAE,GAAG,EACR,GAAG,EAAE,OAAO,EACZ,aAAa,EAAE,MAAM,EACrB,aAAa,EAAE,QAAQ,CAAC,CAAC,CAAC,mBAAmB,CAAC,EAC9C,QAAQ,EAAE,CAAC,CAAC,UAAU,EACtB,QAAQ,EAAE,WAAW,EACrB,KAAK,UAAQ,EACb,OAAO,GAAE,CAAC,CAAC,UAAqB,EAChC,eAAe,UAAQ,EACvB,cAAc,CAAC,EAAE;IAAE,KAAK,EAAE,MAAM,CAAA;CAAE,GACjC,CAAC,CAAC,uBAAuB,CAwF3B"}
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Lazy static DOM templates for allocation-free listed components.
3
+ *
4
+ * Listed rows are mounted many times. Their static host structure is built
5
+ * once, retained as a detached pristine node, and deep-cloned per row. Dynamic
6
+ * setters and event/ref/lifecycle work remain in the row factory.
7
+ */
8
+ import type { Ctx } from '../context';
9
+ import type { EmitScope } from './scope';
10
+ export declare function applyRepeatedDomTemplate(ctx: Ctx, scope: EmitScope, rootVar: string): boolean;
11
+ //# sourceMappingURL=dom-template.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dom-template.d.ts","sourceRoot":"","sources":["../../src/emission/dom-template.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAGH,OAAO,KAAK,EAAE,GAAG,EAAE,MAAM,YAAY,CAAC;AAEtC,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAkBzC,wBAAgB,wBAAwB,CACtC,GAAG,EAAE,GAAG,EACR,KAAK,EAAE,SAAS,EAChB,OAAO,EAAE,MAAM,GACd,OAAO,CA2GT"}
@@ -0,0 +1,10 @@
1
+ import type { NodePath } from '@babel/traverse';
2
+ import * as t from '@babel/types';
3
+ import { type Ctx, type RowCtx } from '../context';
4
+ import { type JsxChild } from '../components/children';
5
+ import { type EmitScope } from './scope';
6
+ import type { NodeEmitter } from './node-emitter';
7
+ export type AuthoredChildrenSlotBuilder = (ctx: Ctx, ownerScope: EmitScope, children: readonly JsxChild[], componentName: string, componentPath: NodePath<t.FunctionDeclaration>, nestedIn: 'row' | 'cond' | null, rowContext: RowCtx | undefined, eventOriginId: t.Expression | undefined, inSvg: boolean, ownerId: t.Expression) => t.Identifier;
8
+ /** Emit a keyed list region and its row factory. */
9
+ export declare function emitListRegion(ctx: Ctx, scope: EmitScope, call: t.CallExpression, parentElementVariable: string, componentName: string, componentPath: NodePath<t.FunctionDeclaration>, emitNode: NodeEmitter, buildAuthoredChildrenSlot: AuthoredChildrenSlotBuilder, inSvg?: boolean, ownerId?: t.Expression, parentRow?: RowCtx): void;
10
+ //# sourceMappingURL=list-region.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"list-region.d.ts","sourceRoot":"","sources":["../../src/emission/list-region.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAChD,OAAO,KAAK,CAAC,MAAM,cAAc,CAAC;AAClC,OAAO,EAIL,KAAK,GAAG,EACR,KAAK,MAAM,EACZ,MAAM,YAAY,CAAC;AAQpB,OAAO,EAGL,KAAK,QAAQ,EACd,MAAM,wBAAwB,CAAC;AAahC,OAAO,EAKL,KAAK,SAAS,EACf,MAAM,SAAS,CAAC;AACjB,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAKlD,MAAM,MAAM,2BAA2B,GAAG,CACxC,GAAG,EAAE,GAAG,EACR,UAAU,EAAE,SAAS,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