@exactjs/core 0.6.2 → 0.6.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.
Files changed (179) hide show
  1. package/AGENTS.md +12 -14
  2. package/README.md +6 -8
  3. package/dist/client/component/resumption.js +5 -1
  4. package/dist/client/component/resumption.js.map +1 -1
  5. package/dist/client/component-contract/continuation-validation.d.ts +5 -0
  6. package/dist/client/component-contract/continuation-validation.d.ts.map +1 -1
  7. package/dist/client/component-contract/continuation-validation.js +7 -0
  8. package/dist/client/component-contract/continuation-validation.js.map +1 -1
  9. package/dist/client/component-contract/contract-validation.d.ts.map +1 -1
  10. package/dist/client/component-contract/contract-validation.js +4 -1
  11. package/dist/client/component-contract/contract-validation.js.map +1 -1
  12. package/dist/client/component-contracts.d.ts +5 -0
  13. package/dist/client/component-contracts.d.ts.map +1 -1
  14. package/dist/client/component-contracts.js.map +1 -1
  15. package/dist/client/framework/component-contract-validation.d.ts +1 -1
  16. package/dist/client/framework/component-contract-validation.d.ts.map +1 -1
  17. package/dist/client/framework/component-contract-validation.js +1 -1
  18. package/dist/client/framework/component-contract-validation.js.map +1 -1
  19. package/dist/client/framework/fragment-target-projection-plan.d.ts +9 -0
  20. package/dist/client/framework/fragment-target-projection-plan.d.ts.map +1 -0
  21. package/dist/client/framework/fragment-target-projection-plan.js +99 -0
  22. package/dist/client/framework/fragment-target-projection-plan.js.map +1 -0
  23. package/dist/client/framework/fragment-target-projection.d.ts +1 -5
  24. package/dist/client/framework/fragment-target-projection.d.ts.map +1 -1
  25. package/dist/client/framework/fragment-target-projection.js +5 -95
  26. package/dist/client/framework/fragment-target-projection.js.map +1 -1
  27. package/dist/client/framework/operation-protocol.d.ts +9 -0
  28. package/dist/client/framework/operation-protocol.d.ts.map +1 -1
  29. package/dist/client/framework/operation-protocol.js.map +1 -1
  30. package/dist/client/framework/server-fragment-target-projection.d.ts +4 -0
  31. package/dist/client/framework/server-fragment-target-projection.d.ts.map +1 -0
  32. package/dist/client/framework/server-fragment-target-projection.js +7 -0
  33. package/dist/client/framework/server-fragment-target-projection.js.map +1 -0
  34. package/dist/client/framework/server-render-structure.d.ts +1 -0
  35. package/dist/client/framework/server-render-structure.d.ts.map +1 -1
  36. package/dist/client/framework/server-render-structure.js +1 -0
  37. package/dist/client/framework/server-render-structure.js.map +1 -1
  38. package/dist/client/framework/server-task-helpers.d.ts +1 -0
  39. package/dist/client/framework/server-task-helpers.d.ts.map +1 -1
  40. package/dist/client/framework/server-task-helpers.js +1 -0
  41. package/dist/client/framework/server-task-helpers.js.map +1 -1
  42. package/dist/client/framework/task-frames.d.ts +2 -1
  43. package/dist/client/framework/task-frames.d.ts.map +1 -1
  44. package/dist/client/framework/task-frames.js +1 -0
  45. package/dist/client/framework/task-frames.js.map +1 -1
  46. package/dist/client/runtime/tasks.d.ts +1 -0
  47. package/dist/client/runtime/tasks.d.ts.map +1 -1
  48. package/dist/client/runtime/tasks.js +1 -0
  49. package/dist/client/runtime/tasks.js.map +1 -1
  50. package/dist/client/tasks/contracts.d.ts +2 -0
  51. package/dist/client/tasks/contracts.d.ts.map +1 -1
  52. package/dist/client/tasks/contracts.js.map +1 -1
  53. package/dist/client/tasks/progress-bindings.d.ts +20 -0
  54. package/dist/client/tasks/progress-bindings.d.ts.map +1 -0
  55. package/dist/client/tasks/progress-bindings.js +51 -0
  56. package/dist/client/tasks/progress-bindings.js.map +1 -0
  57. package/dist/client/tasks/progress-receiver.d.ts +24 -0
  58. package/dist/client/tasks/progress-receiver.d.ts.map +1 -0
  59. package/dist/client/tasks/progress-receiver.js +71 -0
  60. package/dist/client/tasks/progress-receiver.js.map +1 -0
  61. package/dist/component/resumption.js +5 -1
  62. package/dist/component/resumption.js.map +1 -1
  63. package/dist/component-contract/continuation-validation.d.ts +5 -0
  64. package/dist/component-contract/continuation-validation.d.ts.map +1 -1
  65. package/dist/component-contract/continuation-validation.js +7 -0
  66. package/dist/component-contract/continuation-validation.js.map +1 -1
  67. package/dist/component-contract/contract-validation.d.ts.map +1 -1
  68. package/dist/component-contract/contract-validation.js +4 -1
  69. package/dist/component-contract/contract-validation.js.map +1 -1
  70. package/dist/component-contracts.d.ts +5 -0
  71. package/dist/component-contracts.d.ts.map +1 -1
  72. package/dist/component-contracts.js.map +1 -1
  73. package/dist/framework/component-contract-validation.d.ts +1 -1
  74. package/dist/framework/component-contract-validation.d.ts.map +1 -1
  75. package/dist/framework/component-contract-validation.js +1 -1
  76. package/dist/framework/component-contract-validation.js.map +1 -1
  77. package/dist/framework/fragment-target-projection-plan.d.ts +9 -0
  78. package/dist/framework/fragment-target-projection-plan.d.ts.map +1 -0
  79. package/dist/framework/fragment-target-projection-plan.js +99 -0
  80. package/dist/framework/fragment-target-projection-plan.js.map +1 -0
  81. package/dist/framework/fragment-target-projection.d.ts +1 -5
  82. package/dist/framework/fragment-target-projection.d.ts.map +1 -1
  83. package/dist/framework/fragment-target-projection.js +5 -95
  84. package/dist/framework/fragment-target-projection.js.map +1 -1
  85. package/dist/framework/operation-protocol.d.ts +9 -0
  86. package/dist/framework/operation-protocol.d.ts.map +1 -1
  87. package/dist/framework/operation-protocol.js.map +1 -1
  88. package/dist/framework/server-fragment-target-projection.d.ts +4 -0
  89. package/dist/framework/server-fragment-target-projection.d.ts.map +1 -0
  90. package/dist/framework/server-fragment-target-projection.js +7 -0
  91. package/dist/framework/server-fragment-target-projection.js.map +1 -0
  92. package/dist/framework/server-render-structure.d.ts +1 -0
  93. package/dist/framework/server-render-structure.d.ts.map +1 -1
  94. package/dist/framework/server-render-structure.js +1 -0
  95. package/dist/framework/server-render-structure.js.map +1 -1
  96. package/dist/framework/server-task-helpers.d.ts +1 -0
  97. package/dist/framework/server-task-helpers.d.ts.map +1 -1
  98. package/dist/framework/server-task-helpers.js +1 -0
  99. package/dist/framework/server-task-helpers.js.map +1 -1
  100. package/dist/framework/task-frames.d.ts +2 -1
  101. package/dist/framework/task-frames.d.ts.map +1 -1
  102. package/dist/framework/task-frames.js +1 -0
  103. package/dist/framework/task-frames.js.map +1 -1
  104. package/dist/runtime/tasks.d.ts +1 -0
  105. package/dist/runtime/tasks.d.ts.map +1 -1
  106. package/dist/runtime/tasks.js +1 -0
  107. package/dist/runtime/tasks.js.map +1 -1
  108. package/dist/server/component/resumption.js +5 -1
  109. package/dist/server/component/resumption.js.map +1 -1
  110. package/dist/server/component-contract/continuation-validation.d.ts +5 -0
  111. package/dist/server/component-contract/continuation-validation.d.ts.map +1 -1
  112. package/dist/server/component-contract/continuation-validation.js +7 -0
  113. package/dist/server/component-contract/continuation-validation.js.map +1 -1
  114. package/dist/server/component-contract/contract-validation.d.ts.map +1 -1
  115. package/dist/server/component-contract/contract-validation.js +4 -1
  116. package/dist/server/component-contract/contract-validation.js.map +1 -1
  117. package/dist/server/component-contracts.d.ts +5 -0
  118. package/dist/server/component-contracts.d.ts.map +1 -1
  119. package/dist/server/component-contracts.js.map +1 -1
  120. package/dist/server/framework/component-contract-validation.d.ts +1 -1
  121. package/dist/server/framework/component-contract-validation.d.ts.map +1 -1
  122. package/dist/server/framework/component-contract-validation.js +1 -1
  123. package/dist/server/framework/component-contract-validation.js.map +1 -1
  124. package/dist/server/framework/fragment-target-projection-plan.d.ts +9 -0
  125. package/dist/server/framework/fragment-target-projection-plan.d.ts.map +1 -0
  126. package/dist/server/framework/fragment-target-projection-plan.js +99 -0
  127. package/dist/server/framework/fragment-target-projection-plan.js.map +1 -0
  128. package/dist/server/framework/fragment-target-projection.d.ts +1 -5
  129. package/dist/server/framework/fragment-target-projection.d.ts.map +1 -1
  130. package/dist/server/framework/fragment-target-projection.js +5 -95
  131. package/dist/server/framework/fragment-target-projection.js.map +1 -1
  132. package/dist/server/framework/operation-protocol.d.ts +9 -0
  133. package/dist/server/framework/operation-protocol.d.ts.map +1 -1
  134. package/dist/server/framework/operation-protocol.js.map +1 -1
  135. package/dist/server/framework/server-fragment-target-projection.d.ts +4 -0
  136. package/dist/server/framework/server-fragment-target-projection.d.ts.map +1 -0
  137. package/dist/server/framework/server-fragment-target-projection.js +7 -0
  138. package/dist/server/framework/server-fragment-target-projection.js.map +1 -0
  139. package/dist/server/framework/server-render-structure.d.ts +1 -0
  140. package/dist/server/framework/server-render-structure.d.ts.map +1 -1
  141. package/dist/server/framework/server-render-structure.js +1 -0
  142. package/dist/server/framework/server-render-structure.js.map +1 -1
  143. package/dist/server/framework/server-task-helpers.d.ts +1 -0
  144. package/dist/server/framework/server-task-helpers.d.ts.map +1 -1
  145. package/dist/server/framework/server-task-helpers.js +1 -0
  146. package/dist/server/framework/server-task-helpers.js.map +1 -1
  147. package/dist/server/framework/task-frames.d.ts +2 -1
  148. package/dist/server/framework/task-frames.d.ts.map +1 -1
  149. package/dist/server/framework/task-frames.js +1 -0
  150. package/dist/server/framework/task-frames.js.map +1 -1
  151. package/dist/server/runtime/tasks.d.ts +1 -0
  152. package/dist/server/runtime/tasks.d.ts.map +1 -1
  153. package/dist/server/runtime/tasks.js +1 -0
  154. package/dist/server/runtime/tasks.js.map +1 -1
  155. package/dist/server/tasks/contracts.d.ts +2 -0
  156. package/dist/server/tasks/contracts.d.ts.map +1 -1
  157. package/dist/server/tasks/contracts.js.map +1 -1
  158. package/dist/server/tasks/progress-bindings.d.ts +20 -0
  159. package/dist/server/tasks/progress-bindings.d.ts.map +1 -0
  160. package/dist/server/tasks/progress-bindings.js +51 -0
  161. package/dist/server/tasks/progress-bindings.js.map +1 -0
  162. package/dist/server/tasks/progress-receiver.d.ts +24 -0
  163. package/dist/server/tasks/progress-receiver.d.ts.map +1 -0
  164. package/dist/server/tasks/progress-receiver.js +71 -0
  165. package/dist/server/tasks/progress-receiver.js.map +1 -0
  166. package/dist/tasks/contracts.d.ts +2 -0
  167. package/dist/tasks/contracts.d.ts.map +1 -1
  168. package/dist/tasks/contracts.js.map +1 -1
  169. package/dist/tasks/progress-bindings.d.ts +20 -0
  170. package/dist/tasks/progress-bindings.d.ts.map +1 -0
  171. package/dist/tasks/progress-bindings.js +51 -0
  172. package/dist/tasks/progress-bindings.js.map +1 -0
  173. package/dist/tasks/progress-receiver.d.ts +24 -0
  174. package/dist/tasks/progress-receiver.d.ts.map +1 -0
  175. package/dist/tasks/progress-receiver.js +71 -0
  176. package/dist/tasks/progress-receiver.js.map +1 -0
  177. package/package.json +1 -1
  178. package/dist/client/component/error-boundary.js.map +0 -1
  179. package/dist/server/component/error-boundary.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"component-contracts.js","sourceRoot":"","sources":["../../src/component-contracts.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wBAAwB,EAAE,MAAM,kCAAkC,CAAC;AAG5E,OAAO,EAAE,0BAA0B,EAAE,MAAM,wCAAwC,CAAC;AACpF,OAAO,EACN,iBAAiB,EACjB,uBAAuB,EACvB,aAAa,EACb,MAAM,6CAA6C,CAAC;AAgBrD,OAAO,EACN,0BAA0B,EAE1B,MAAM,wCAAwC,CAAC;AAEhD,wFAAwF;AACxF,MAAM,CAAC,MAAM,sBAAsB,GAAG,MAAM,CAAC,GAAG,CAAC,6BAA6B,CAAC,CAAC;AAEhF,gGAAgG;AAChG,MAAM,CAAC,MAAM,kBAAkB,GAAG,MAAM,CAAC,GAAG,CAAC,oBAAoB,CAAC,CAAC;AA6MnE,kFAAkF;AAClF,MAAM,UAAU,gBAAgB,CAAC,SAAkB;IAClD,IAAI,OAAO,SAAS,KAAK,UAAU;QAAE,OAAO,KAAK,CAAC;IAClD,MAAM,QAAQ,GAAI,SAA+B,CAAC,kBAAkB,CAAC,CAAC;IACtE,OAAO,OAAO,QAAQ,KAAK,QAAQ,IAAI,QAAQ,CAAC,MAAM,GAAG,CAAC,CAAC;AAC5D,CAAC;AAED,6FAA6F;AAC7F,MAAM,UAAU,0BAA0B,CACzC,SAAoC;IAEpC,MAAM,QAAQ,GAAI,SAA+B,CAAC,sBAAsB,CAAC,CAAC;IAC1E,IAAI,CAAC,QAAQ;QAAE,OAAO,SAAS,CAAC;IAChC,MAAM,WAAW,GAAG,sBAAsB,CAA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Ac,CAC7B,CAAC;YACF,uBAAuB,CAAC,eAAe,EAAE,cAAc,CAAC,IAAI,EAAE,cAAc,CAAC,cAAc,CAAC,CAAC;QAC9F,CAAC;QACD,KAAK,MAAM,YAAY,IAAI,QAAQ,CAAC,aAAa,IAAI,EAAE;YACtD,aAAa,CAAC,aAAa,EAAE,YAAY,CAAC,EAAE,EAAE,YAAY,EAAE,cAAc,CAAC,CAAC;QAC7E,KAAK,MAAM,QAAQ,IAAI,QAAQ,CAAC,SAAS,IAAI,EAAE;YAAE,iBAAiB,CAAC,SAAS,EAAE,QAAQ,CAAC,CAAC;QACxF,KAAK,MAAM,QAAQ,IAAI,QAAQ,CAAC,UAAU,IAAI,EAAE;YAC/C,aAAa,CAAC,UAAU,EAAE,QAAQ,CAAC,EAAE,EAAE,QAAQ,EAAE,UAAU,CAAC,CAAC;QAC9D,IAAI,QAAQ,CAAC,UAAU;YACtB,aAAa,CACZ,WAAW,EACX,QAAQ,CAAC,UAAU,CAAC,WAAW,EAC/B,QAAQ,CAAC,UAAU,EACnB,YAAY,CACZ,CAAC;QACH,IAAI,QAAQ,CAAC,SAAS;YACrB,aAAa,CAAC,UAAU,EAAE,WAAW,EAAE,QAAQ,CAAC,SAAS,EAAE,gBAAgB,CAAC,CAAC;QAC9E,SAAS,CAAC,WAAW,CAAC,GAAG,QAAQ,CAAC,QAAQ,CAAC;IAC5C,CAAC;IAED,OAAO,MAAM,CAAC,MAAM,CAAC;QACpB,eAAe;QACf,mBAAmB;QACnB,aAAa;QACb,SAAS;QACT,UAAU;QACV,WAAW;QACX,UAAU;QACV,SAAS;KACT,CAAC,CAAC;AACJ,CAAC","sourcesContent":["import { componentContractVersion } from './component/contract-versions.js';\nimport type { ContextToken } from './component/contracts.js';\nimport type { TaskContext } from './tasks/contracts.js';\nimport { validatedComponentContract } from './component-contract/contract-cache.js';\nimport {\n\taddUniqueExecutor,\n\taddUniqueImplementation,\n\taddUniqueJson\n} from './component-contract/composition-support.js';\nimport type { ExactComponentExecutableArtifact } from './component-abi/artifact.js';\nimport type { ExactClientComponentArtifact } from './component-abi/client.js';\nimport type { ExactServerComponentArtifact } from './component-abi/server.js';\nimport type {\n\tAnyExactComponentCallable,\n\tExactComponentReactiveAllocation\n} from './component-abi/executable-fields.js';\n\nexport type { ExactComponentExecutableArtifact } from './component-abi/artifact.js';\nexport type { ExactClientComponentArtifact } from './component-abi/client.js';\nexport type {\n\tExactServerComponentArtifact,\n\tExactServerComponentExecution\n} from './component-abi/server.js';\nexport type { AnyExactComponentCallable } from './component-abi/executable-fields.js';\nexport {\n\tdecodeExactValueWithSchema,\n\ttype ExactValueSerializationSchema\n} from './component-abi/value-serialization.js';\n\n/** Global property under which compiled artifacts carry their target-local contract. */\nexport const exactComponentContract = Symbol.for('@exactjs/component-contract');\n\n/** Global marker distinguishing a native eXact component from compatibility-owned functions. */\nexport const exactComponentType = Symbol.for('@exactjs/component');\n\n/** One executable implementation owned by a compiled component artifact. */\nexport type ExactComponentImplementationContract = Readonly<{\n\tid: string;\n\tname: string;\n\trole: 'root' | 'client-island' | 'server-part';\n\timplementation: AnyExactComponentCallable;\n}>;\n\n/** Runtime-neutral state path used by a generated continuation contract. */\nexport type ExactContinuationStatePathContract = Readonly<{\n\tpath: string;\n\tkind: 'read' | 'write';\n\tconfidence: 'exact' | 'broad' | 'unknown';\n\toperation?: 'value' | 'map' | 'set';\n}>;\n\n/** One ordered Map or Set mutation returned by a server continuation. */\nexport type ExactCollectionMutation =\n\t| Readonly<{ path: string; operation: 'map-set'; key: unknown; value: unknown }>\n\t| Readonly<{ path: string; operation: 'map-delete'; key: unknown }>\n\t| Readonly<{ path: string; operation: 'map-clear' }>\n\t| Readonly<{ path: string; operation: 'set-add'; value: unknown }>\n\t| Readonly<{ path: string; operation: 'set-delete'; value: unknown }>\n\t| Readonly<{ path: string; operation: 'set-clear' }>;\n\n/** Private operation contract attached to the component artifact that owns it. */\nexport type ExactComponentContinuationContract = Readonly<{\n\tid: string;\n\tkind: 'task';\n\tcomponentId: string;\n\treadiness: 'blocking' | 'nonblocking';\n\tconcurrency?: 'parallel' | 'latest' | 'queue';\n\tdependencies: readonly Readonly<{\n\t\tindex?: number;\n\t\tsource: 'state' | 'props' | 'derived' | 'argument';\n\t\tpath?: string;\n\t}>[];\n\tinvocation?: Readonly<{\n\t\targuments: readonly Readonly<{ index?: number; source: 'argument'; path?: string }>[];\n\t\tconcurrency: 'parallel' | 'latest' | 'queue';\n\t}>;\n\tstateReads: readonly ExactContinuationStatePathContract[];\n\tstateWrites: readonly ExactContinuationStatePathContract[];\n\tpublicContexts: readonly string[];\n\tserverContexts: readonly string[];\n\tcontextWrites: readonly string[];\n\t/** Server-owned context mutations which never enter the client response. */\n\tserverContextWrites?: readonly string[];\n\tboundaries: readonly string[];\n}>;\n\n/** Serializable activation record accepted by one generated server continuation. */\nexport type ExactComponentContinuationActivation = Readonly<{\n\tstate: Record<string, unknown>;\n\tdependencies: readonly unknown[];\n\tpublicContext: Readonly<Record<string, unknown>>;\n\tgeneration?: number;\n}>;\n\n/** Trusted invocation resources available only while a server continuation executes. */\nexport type ExactComponentContinuationExecution = Readonly<{\n\ttask: TaskContext;\n\tsignal: AbortSignal;\n\tgetContext<T>(token: ContextToken<T>, authoredName?: string): T;\n\tsetContext<T>(token: ContextToken<T>, value: T, authoredName?: string): void;\n}>;\n\n/** State accumulated by a generated continuation before write-contract projection. */\nexport type ExactComponentContinuationExecutionResult = Readonly<{\n\tstate: Record<string, unknown>;\n\tcontexts?: Readonly<Record<string, unknown>>;\n\tvalue?: unknown;\n}>;\n\n/** Executable server half paired with one inert continuation descriptor. */\nexport type ExactComponentContinuationExecutorContract = Readonly<{\n\tid: string;\n\tcomponentId: string;\n\texecute(\n\t\tactivation: ExactComponentContinuationActivation,\n\t\texecution: ExactComponentContinuationExecution\n\t): ExactComponentContinuationExecutionResult | Promise<ExactComponentContinuationExecutionResult>;\n}>;\n\n/** One compiler-owned DOM boundary and its component ownership. */\nexport type ExactComponentBoundaryContract = Readonly<{\n\tid: string;\n\tcomponentId: string;\n\townerComponentId: string;\n\tkind: string;\n\tplanVersion?: number;\n\tbuildKey?: string;\n\tplanEdgeId?: string;\n\tparentPlanId?: string;\n\tfallbackPlanId?: string;\n\tpatchTargets?: readonly string[];\n\tdiscriminatorKind?: 'single' | 'branch' | 'keyed';\n\tdiscriminatorValues?: readonly string[];\n\tgeneration?: number;\n}>;\n\n/** Minimum browser-visible values required to resume one SSR component. */\nexport type ExactComponentResumptionContract = Readonly<{\n\tcomponentId: string;\n\tstatePaths: readonly string[];\n\t/** State path and root-prop path pairs that client setup can reconstruct. */\n\tstateInputs: readonly (readonly [statePath: string, propPath: string])[];\n\t/** Compact completion allowlist when a hydration artifact omits its execution catalog. */\n\tcontinuations?: readonly string[];\n\t/** Server-only primitive setup values that sparse capture may omit. */\n\tstateDefaults?: readonly (readonly [\n\t\tstatePath: string,\n\t\tvalue: string | number | boolean | null\n\t])[];\n\tvalueCaptures: readonly string[];\n\tcontexts: readonly string[];\n\tboundaries: readonly string[];\n}>;\n\n/** Compact target-local execution wiring emitted for one semantic component. */\nexport type ExactComponentExecutionContract = Readonly<{\n\tversion: 1;\n\t/** Port tuple: kind, authored path, direction. Its array position is its index. */\n\tports: readonly (readonly [\n\t\tkind: 'state' | 'props' | 'context' | 'derived' | 'argument',\n\t\tpath: string,\n\t\tdirection: 'input' | 'output' | 'inout'\n\t])[];\n\t/** Transition tuple: identity, task, activation, placement, readiness, concurrency, inputs, outputs. */\n\ttransitions: readonly (readonly [\n\t\tid: string,\n\t\ttaskId: string,\n\t\tactivation: 'setup' | 'interaction',\n\t\tplacement: 'client' | 'server' | 'isomorphic',\n\t\treadiness: 'blocking' | 'nonblocking',\n\t\tconcurrency: 'parallel' | 'latest' | 'queue',\n\t\tinputs: readonly number[],\n\t\toutputs: readonly number[]\n\t])[];\n\t/** Build-inspection inventory omitted from render-mode-projected runtime bundles. */\n\treactive?: readonly ExactComponentReactiveAllocation[];\n}>;\n\n/** One component-owned direct DOM update program shared by every instance of its definition. */\nexport type {\n\tExactCompiledComponentCapability,\n\tExactCompiledComponentInputUpdateContract,\n\tExactCompiledComponentUpdateContract,\n\tExactNarrowComponentUpdateContract,\n\tExactWideComponentUpdateContract\n} from './component-definition-contracts.js';\n\n/** Target-local executable contract attached to a public component root. */\nexport type ExactComponentContract = Readonly<{\n\t/** Target-discriminated component contract for this compiler/runtime generation. */\n\tversion: typeof componentContractVersion;\n\tplacement: 'client' | 'server' | 'isomorphic' | 'unknown';\n\trole: 'client' | 'render' | 'executor';\n\timplementations: readonly ExactComponentImplementationContract[];\n\tcontinuations: readonly ExactComponentContinuationContract[];\n\texecutors: readonly ExactComponentContinuationExecutorContract[];\n\tboundaries: readonly ExactComponentBoundaryContract[];\n\tresumption?: ExactComponentResumptionContract;\n\texecution?: ExactComponentExecutionContract;\n\tartifact: ExactComponentExecutableArtifact;\n}>;\n\n/** Build-projected runtime attachment after adapter-owned composition facts are erased. */\nexport type ExactPreparedComponentContract = Readonly<\n\tPick<ExactComponentContract, 'artifact'> & Partial<Omit<ExactComponentContract, 'artifact'>>\n>;\n\n/** Runtime attachment whose single executable artifact is guaranteed by the current target ABI. */\nexport type ExactExecutableComponentContract = ExactPreparedComponentContract;\n\n/** Prepared attachment whose target-local artifact is always executable. */\nexport type ExactPreparedExecutableComponentContract = ExactExecutableComponentContract;\n\n/** Current executable contract proven to carry the client target ABI. */\nexport type ExactClientExecutableComponentContract = ExactExecutableComponentContract &\n\tReadonly<{ artifact: ExactClientComponentArtifact }>;\n\n/** Current executable contract proven to carry the server target ABI. */\nexport type ExactServerExecutableComponentContract = ExactComponentContract &\n\tReadonly<{ artifact: ExactServerComponentArtifact }>;\n\n/** Composed target-local contracts indexed for runtime use. */\nexport type ExactComposedComponentContracts = Readonly<{\n\timplementations: Record<string, AnyExactComponentCallable>;\n\timplementationsById: Record<string, AnyExactComponentCallable>;\n\tcontinuations: Record<string, ExactComponentContinuationContract>;\n\texecutors: Record<string, ExactComponentContinuationExecutorContract>;\n\tboundaries: Record<string, ExactComponentBoundaryContract>;\n\tresumptions: Record<string, ExactComponentResumptionContract>;\n\texecutions: Record<string, ExactComponentExecutionContract>;\n\tartifacts: Record<string, ExactComponentExecutableArtifact>;\n}>;\n\ntype ContractComponent = AnyExactComponentCallable & {\n\t[exactComponentContract]?: ExactComponentContract;\n\t[exactComponentType]?: string;\n};\n\n/** Returns whether a callable carries a valid native eXact component identity. */\nexport function isExactComponent(component: unknown): component is AnyExactComponentCallable {\n\tif (typeof component !== 'function') return false;\n\tconst identity = (component as ContractComponent)[exactComponentType];\n\treturn typeof identity === 'string' && identity.length > 0;\n}\n\n/** Reads and validates compiler-attached metadata from one target-local component export. */\nexport function readExactComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactComponentContract | undefined {\n\tconst contract = (component as ContractComponent)[exactComponentContract];\n\tif (!contract) return undefined;\n\tconst componentId = exactComponentIdentity(component);\n\treturn validatedComponentContract(component, contract, componentId);\n}\n\n/** Reads one current executable target artifact and rejects obsolete or identity-only values. */\nexport function readExactExecutableComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactExecutableComponentContract {\n\tconst contract = readExactComponentContract(component);\n\tif (!contract?.artifact)\n\t\tthrow new TypeError('Native eXact component execution requires a compiled component artifact');\n\treturn contract;\n}\n\n/** Reads and validates one client-target executable component contract. */\nexport function readExactClientExecutableComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactClientExecutableComponentContract {\n\tconst contract = readExactExecutableComponentContract(component);\n\tif (contract.artifact.target !== 'client')\n\t\tthrow new TypeError('Client execution requires a current client component artifact');\n\treturn contract as ExactClientExecutableComponentContract;\n}\n\n/** Reads and validates one server-target executable component contract. */\nexport function readExactServerExecutableComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactServerExecutableComponentContract {\n\tconst contract = readExactExecutableComponentContract(component);\n\tif (contract.artifact.target !== 'server')\n\t\tthrow new TypeError('Server execution requires a current server component artifact');\n\treturn contract as ExactServerExecutableComponentContract;\n}\n\n/** Reads build-validated compiler metadata without repeating recursive runtime validation. */\nexport function readPreparedExactComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactPreparedComponentContract | undefined {\n\tconst contract = (component as ContractComponent)[exactComponentContract];\n\tif (contract && contract.artifact?.version !== componentContractVersion)\n\t\tthrow new TypeError(\n\t\t\t`Unsupported eXact component artifact version ${contract.artifact?.version}; expected ${componentContractVersion}. Recompile with the matching eXact compiler.`\n\t\t);\n\treturn contract;\n}\n\n/** Reads a build-validated current executable target artifact. */\nexport function readPreparedExactExecutableComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactPreparedExecutableComponentContract {\n\tconst contract = readPreparedExactComponentContract(component);\n\tif (!contract?.artifact)\n\t\tthrow new TypeError(\n\t\t\t`Native eXact component execution requires a compiled component artifact: ${component.name || '<anonymous>'}`\n\t\t);\n\treturn contract;\n}\n\n/** Reads one build-validated client-target executable component contract. */\nexport function readPreparedExactClientExecutableComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactPreparedComponentContract & Readonly<{ artifact: ExactClientComponentArtifact }> {\n\tconst contract = readPreparedExactExecutableComponentContract(component);\n\tif (contract.artifact.target !== 'client')\n\t\tthrow new TypeError('Client execution requires a current client component artifact');\n\treturn contract as ExactPreparedComponentContract &\n\t\tReadonly<{ artifact: ExactClientComponentArtifact }>;\n}\n\n/** Reads one build-validated server-target executable component contract. */\nexport function readPreparedExactServerExecutableComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactServerExecutableComponentContract {\n\tconst contract = readPreparedExactExecutableComponentContract(component);\n\tif (contract.artifact.target !== 'server')\n\t\tthrow new TypeError('Server execution requires a current server component artifact');\n\treturn contract as ExactServerExecutableComponentContract;\n}\n\n/** Returns the stable compiler identity used to pair SSR and client component boundaries. */\nexport function exactComponentIdentity(component: AnyExactComponentCallable): string {\n\tconst identity = (component as ContractComponent)[exactComponentType];\n\tif (typeof identity === 'string' && identity) return identity;\n\tthrow new Error('Native eXact components require compiler-owned identity');\n}\n\n/** Composes reachable imported component contracts into duplicate-checked runtime indexes. */\nexport function composeExactComponentContracts(\n\tcomponents: readonly AnyExactComponentCallable[],\n\trole: ExactComponentContract['role']\n): ExactComposedComponentContracts {\n\treturn composeComponentContracts(components, role, readExactComponentContract);\n}\n\n/** Composes build-validated compiler metadata without repeating recursive validation. */\nexport function composePreparedExactComponentContracts(\n\tcomponents: readonly AnyExactComponentCallable[],\n\trole: ExactComponentContract['role']\n): ExactComposedComponentContracts {\n\treturn composeComponentContracts(components, role, readPreparedExactComponentContract);\n}\n\nfunction composeComponentContracts(\n\tcomponents: readonly AnyExactComponentCallable[],\n\trole: ExactComponentContract['role'],\n\treadContract: (component: AnyExactComponentCallable) => ExactPreparedComponentContract | undefined\n): ExactComposedComponentContracts {\n\tconst implementations: Record<string, AnyExactComponentCallable> = {};\n\tconst implementationsById: Record<string, AnyExactComponentCallable> = {};\n\tconst continuations: Record<string, ExactComponentContinuationContract> = {};\n\tconst executors: Record<string, ExactComponentContinuationExecutorContract> = {};\n\tconst boundaries: Record<string, ExactComponentBoundaryContract> = {};\n\tconst resumptions: Record<string, ExactComponentResumptionContract> = {};\n\tconst executions: Record<string, ExactComponentExecutionContract> = {};\n\tconst artifacts: Record<string, ExactComponentExecutableArtifact> = {};\n\n\tfor (const component of components) {\n\t\tconst contract = readContract(component);\n\t\tif (!contract) continue;\n\t\tconst componentId = exactComponentIdentity(component);\n\t\tconst projectedRole =\n\t\t\tcontract.role ?? (contract.artifact.target === 'client' ? 'client' : 'render');\n\t\tif (projectedRole !== role)\n\t\t\tthrow new Error(\n\t\t\t\t`Expected eXact ${role} component contract for ${componentId}, received ${projectedRole}`\n\t\t\t);\n\t\tconst projectedImplementations = contract.implementations ?? [\n\t\t\t{\n\t\t\t\tid: componentId,\n\t\t\t\tname: component.name,\n\t\t\t\trole: 'root' as const,\n\t\t\t\timplementation: component\n\t\t\t}\n\t\t];\n\t\tfor (const implementation of projectedImplementations) {\n\t\t\taddUniqueImplementation(\n\t\t\t\timplementationsById,\n\t\t\t\timplementation.id,\n\t\t\t\timplementation.implementation\n\t\t\t);\n\t\t\taddUniqueImplementation(implementations, implementation.name, implementation.implementation);\n\t\t}\n\t\tfor (const continuation of contract.continuations ?? [])\n\t\t\taddUniqueJson(continuations, continuation.id, continuation, 'continuation');\n\t\tfor (const executor of contract.executors ?? []) addUniqueExecutor(executors, executor);\n\t\tfor (const boundary of contract.boundaries ?? [])\n\t\t\taddUniqueJson(boundaries, boundary.id, boundary, 'boundary');\n\t\tif (contract.resumption)\n\t\t\taddUniqueJson(\n\t\t\t\tresumptions,\n\t\t\t\tcontract.resumption.componentId,\n\t\t\t\tcontract.resumption,\n\t\t\t\t'resumption'\n\t\t\t);\n\t\tif (contract.execution)\n\t\t\taddUniqueJson(executions, componentId, contract.execution, 'execution plan');\n\t\tartifacts[componentId] = contract.artifact;\n\t}\n\n\treturn Object.freeze({\n\t\timplementations,\n\t\timplementationsById,\n\t\tcontinuations,\n\t\texecutors,\n\t\tboundaries,\n\t\tresumptions,\n\t\texecutions,\n\t\tartifacts\n\t});\n}\n"]}
1
+ {"version":3,"file":"component-contracts.js","sourceRoot":"","sources":["../../src/component-contracts.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wBAAwB,EAAE,MAAM,kCAAkC,CAAC;AAG5E,OAAO,EAAE,0BAA0B,EAAE,MAAM,wCAAwC,CAAC;AACpF,OAAO,EACN,iBAAiB,EACjB,uBAAuB,EACvB,aAAa,EACb,MAAM,6CAA6C,CAAC;AAgBrD,OAAO,EACN,0BAA0B,EAE1B,MAAM,wCAAwC,CAAC;AAEhD,wFAAwF;AACxF,MAAM,CAAC,MAAM,sBAAsB,GAAG,MAAM,CAAC,GAAG,CAAC,6BAA6B,CAAC,CAAC;AAEhF,gGAAgG;AAChG,MAAM,CAAC,MAAM,kBAAkB,GAAG,MAAM,CAAC,GAAG,CAAC,oBAAoB,CAAC,CAAC;AA+MnE,kFAAkF;AAClF,MAAM,UAAU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SAAS,CAAC,WAAW,CAAC,GAAG,QAAQ,CAAC,QAAQ,CAAC;IAC5C,CAAC;IAED,OAAO,MAAM,CAAC,MAAM,CAAC;QACpB,eAAe;QACf,mBAAmB;QACnB,aAAa;QACb,SAAS;QACT,UAAU;QACV,WAAW;QACX,UAAU;QACV,SAAS;KACT,CAAC,CAAC;AACJ,CAAC","sourcesContent":["import { componentContractVersion } from './component/contract-versions.js';\nimport type { ContextToken } from './component/contracts.js';\nimport type { TaskContext } from './tasks/contracts.js';\nimport { validatedComponentContract } from './component-contract/contract-cache.js';\nimport {\n\taddUniqueExecutor,\n\taddUniqueImplementation,\n\taddUniqueJson\n} from './component-contract/composition-support.js';\nimport type { ExactComponentExecutableArtifact } from './component-abi/artifact.js';\nimport type { ExactClientComponentArtifact } from './component-abi/client.js';\nimport type { ExactServerComponentArtifact } from './component-abi/server.js';\nimport type {\n\tAnyExactComponentCallable,\n\tExactComponentReactiveAllocation\n} from './component-abi/executable-fields.js';\n\nexport type { ExactComponentExecutableArtifact } from './component-abi/artifact.js';\nexport type { ExactClientComponentArtifact } from './component-abi/client.js';\nexport type {\n\tExactServerComponentArtifact,\n\tExactServerComponentExecution\n} from './component-abi/server.js';\nexport type { AnyExactComponentCallable } from './component-abi/executable-fields.js';\nexport {\n\tdecodeExactValueWithSchema,\n\ttype ExactValueSerializationSchema\n} from './component-abi/value-serialization.js';\n\n/** Global property under which compiled artifacts carry their target-local contract. */\nexport const exactComponentContract = Symbol.for('@exactjs/component-contract');\n\n/** Global marker distinguishing a native eXact component from compatibility-owned functions. */\nexport const exactComponentType = Symbol.for('@exactjs/component');\n\n/** One executable implementation owned by a compiled component artifact. */\nexport type ExactComponentImplementationContract = Readonly<{\n\tid: string;\n\tname: string;\n\trole: 'root' | 'client-island' | 'server-part';\n\timplementation: AnyExactComponentCallable;\n}>;\n\n/** Runtime-neutral state path used by a generated continuation contract. */\nexport type ExactContinuationStatePathContract = Readonly<{\n\tpath: string;\n\tkind: 'read' | 'write';\n\tconfidence: 'exact' | 'broad' | 'unknown';\n\toperation?: 'value' | 'map' | 'set';\n}>;\n\n/** One ordered Map or Set mutation returned by a server continuation. */\nexport type ExactCollectionMutation =\n\t| Readonly<{ path: string; operation: 'map-set'; key: unknown; value: unknown }>\n\t| Readonly<{ path: string; operation: 'map-delete'; key: unknown }>\n\t| Readonly<{ path: string; operation: 'map-clear' }>\n\t| Readonly<{ path: string; operation: 'set-add'; value: unknown }>\n\t| Readonly<{ path: string; operation: 'set-delete'; value: unknown }>\n\t| Readonly<{ path: string; operation: 'set-clear' }>;\n\n/** Private operation contract attached to the component artifact that owns it. */\nexport type ExactComponentContinuationContract = Readonly<{\n\tid: string;\n\tkind: 'task';\n\tcomponentId: string;\n\treadiness: 'blocking' | 'nonblocking';\n\tconcurrency?: 'parallel' | 'latest' | 'queue';\n\t/** Compiler-owned progress receivers allowed for this operation. */\n\tprogress?: readonly Readonly<{ id: string; label: string }>[];\n\tdependencies: readonly Readonly<{\n\t\tindex?: number;\n\t\tsource: 'state' | 'props' | 'derived' | 'argument';\n\t\tpath?: string;\n\t}>[];\n\tinvocation?: Readonly<{\n\t\targuments: readonly Readonly<{ index?: number; source: 'argument'; path?: string }>[];\n\t\tconcurrency: 'parallel' | 'latest' | 'queue';\n\t}>;\n\tstateReads: readonly ExactContinuationStatePathContract[];\n\tstateWrites: readonly ExactContinuationStatePathContract[];\n\tpublicContexts: readonly string[];\n\tserverContexts: readonly string[];\n\tcontextWrites: readonly string[];\n\t/** Server-owned context mutations which never enter the client response. */\n\tserverContextWrites?: readonly string[];\n\tboundaries: readonly string[];\n}>;\n\n/** Serializable activation record accepted by one generated server continuation. */\nexport type ExactComponentContinuationActivation = Readonly<{\n\tstate: Record<string, unknown>;\n\tdependencies: readonly unknown[];\n\tpublicContext: Readonly<Record<string, unknown>>;\n\tgeneration?: number;\n}>;\n\n/** Trusted invocation resources available only while a server continuation executes. */\nexport type ExactComponentContinuationExecution = Readonly<{\n\ttask: TaskContext;\n\tsignal: AbortSignal;\n\tgetContext<T>(token: ContextToken<T>, authoredName?: string): T;\n\tsetContext<T>(token: ContextToken<T>, value: T, authoredName?: string): void;\n}>;\n\n/** State accumulated by a generated continuation before write-contract projection. */\nexport type ExactComponentContinuationExecutionResult = Readonly<{\n\tstate: Record<string, unknown>;\n\tcontexts?: Readonly<Record<string, unknown>>;\n\tvalue?: unknown;\n}>;\n\n/** Executable server half paired with one inert continuation descriptor. */\nexport type ExactComponentContinuationExecutorContract = Readonly<{\n\tid: string;\n\tcomponentId: string;\n\texecute(\n\t\tactivation: ExactComponentContinuationActivation,\n\t\texecution: ExactComponentContinuationExecution\n\t): ExactComponentContinuationExecutionResult | Promise<ExactComponentContinuationExecutionResult>;\n}>;\n\n/** One compiler-owned DOM boundary and its component ownership. */\nexport type ExactComponentBoundaryContract = Readonly<{\n\tid: string;\n\tcomponentId: string;\n\townerComponentId: string;\n\tkind: string;\n\tplanVersion?: number;\n\tbuildKey?: string;\n\tplanEdgeId?: string;\n\tparentPlanId?: string;\n\tfallbackPlanId?: string;\n\tpatchTargets?: readonly string[];\n\tdiscriminatorKind?: 'single' | 'branch' | 'keyed';\n\tdiscriminatorValues?: readonly string[];\n\tgeneration?: number;\n}>;\n\n/** Minimum browser-visible values required to resume one SSR component. */\nexport type ExactComponentResumptionContract = Readonly<{\n\tcomponentId: string;\n\tstatePaths: readonly string[];\n\t/** State path and root-prop path pairs that client setup can reconstruct. */\n\tstateInputs: readonly (readonly [statePath: string, propPath: string])[];\n\t/** Compact completion allowlist when a hydration artifact omits its execution catalog. */\n\tcontinuations?: readonly string[];\n\t/** Server-only primitive setup values that sparse capture may omit. */\n\tstateDefaults?: readonly (readonly [\n\t\tstatePath: string,\n\t\tvalue: string | number | boolean | null\n\t])[];\n\tvalueCaptures: readonly string[];\n\tcontexts: readonly string[];\n\tboundaries: readonly string[];\n}>;\n\n/** Compact target-local execution wiring emitted for one semantic component. */\nexport type ExactComponentExecutionContract = Readonly<{\n\tversion: 1;\n\t/** Port tuple: kind, authored path, direction. Its array position is its index. */\n\tports: readonly (readonly [\n\t\tkind: 'state' | 'props' | 'context' | 'derived' | 'argument',\n\t\tpath: string,\n\t\tdirection: 'input' | 'output' | 'inout'\n\t])[];\n\t/** Transition tuple: identity, task, activation, placement, readiness, concurrency, inputs, outputs. */\n\ttransitions: readonly (readonly [\n\t\tid: string,\n\t\ttaskId: string,\n\t\tactivation: 'setup' | 'interaction',\n\t\tplacement: 'client' | 'server' | 'isomorphic',\n\t\treadiness: 'blocking' | 'nonblocking',\n\t\tconcurrency: 'parallel' | 'latest' | 'queue',\n\t\tinputs: readonly number[],\n\t\toutputs: readonly number[]\n\t])[];\n\t/** Build-inspection inventory omitted from render-mode-projected runtime bundles. */\n\treactive?: readonly ExactComponentReactiveAllocation[];\n}>;\n\n/** One component-owned direct DOM update program shared by every instance of its definition. */\nexport type {\n\tExactCompiledComponentCapability,\n\tExactCompiledComponentInputUpdateContract,\n\tExactCompiledComponentUpdateContract,\n\tExactNarrowComponentUpdateContract,\n\tExactWideComponentUpdateContract\n} from './component-definition-contracts.js';\n\n/** Target-local executable contract attached to a public component root. */\nexport type ExactComponentContract = Readonly<{\n\t/** Target-discriminated component contract for this compiler/runtime generation. */\n\tversion: typeof componentContractVersion;\n\tplacement: 'client' | 'server' | 'isomorphic' | 'unknown';\n\trole: 'client' | 'render' | 'executor';\n\timplementations: readonly ExactComponentImplementationContract[];\n\tcontinuations: readonly ExactComponentContinuationContract[];\n\texecutors: readonly ExactComponentContinuationExecutorContract[];\n\tboundaries: readonly ExactComponentBoundaryContract[];\n\tresumption?: ExactComponentResumptionContract;\n\texecution?: ExactComponentExecutionContract;\n\tartifact: ExactComponentExecutableArtifact;\n}>;\n\n/** Build-projected runtime attachment after adapter-owned composition facts are erased. */\nexport type ExactPreparedComponentContract = Readonly<\n\tPick<ExactComponentContract, 'artifact'> & Partial<Omit<ExactComponentContract, 'artifact'>>\n>;\n\n/** Runtime attachment whose single executable artifact is guaranteed by the current target ABI. */\nexport type ExactExecutableComponentContract = ExactPreparedComponentContract;\n\n/** Prepared attachment whose target-local artifact is always executable. */\nexport type ExactPreparedExecutableComponentContract = ExactExecutableComponentContract;\n\n/** Current executable contract proven to carry the client target ABI. */\nexport type ExactClientExecutableComponentContract = ExactExecutableComponentContract &\n\tReadonly<{ artifact: ExactClientComponentArtifact }>;\n\n/** Current executable contract proven to carry the server target ABI. */\nexport type ExactServerExecutableComponentContract = ExactComponentContract &\n\tReadonly<{ artifact: ExactServerComponentArtifact }>;\n\n/** Composed target-local contracts indexed for runtime use. */\nexport type ExactComposedComponentContracts = Readonly<{\n\timplementations: Record<string, AnyExactComponentCallable>;\n\timplementationsById: Record<string, AnyExactComponentCallable>;\n\tcontinuations: Record<string, ExactComponentContinuationContract>;\n\texecutors: Record<string, ExactComponentContinuationExecutorContract>;\n\tboundaries: Record<string, ExactComponentBoundaryContract>;\n\tresumptions: Record<string, ExactComponentResumptionContract>;\n\texecutions: Record<string, ExactComponentExecutionContract>;\n\tartifacts: Record<string, ExactComponentExecutableArtifact>;\n}>;\n\ntype ContractComponent = AnyExactComponentCallable & {\n\t[exactComponentContract]?: ExactComponentContract;\n\t[exactComponentType]?: string;\n};\n\n/** Returns whether a callable carries a valid native eXact component identity. */\nexport function isExactComponent(component: unknown): component is AnyExactComponentCallable {\n\tif (typeof component !== 'function') return false;\n\tconst identity = (component as ContractComponent)[exactComponentType];\n\treturn typeof identity === 'string' && identity.length > 0;\n}\n\n/** Reads and validates compiler-attached metadata from one target-local component export. */\nexport function readExactComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactComponentContract | undefined {\n\tconst contract = (component as ContractComponent)[exactComponentContract];\n\tif (!contract) return undefined;\n\tconst componentId = exactComponentIdentity(component);\n\treturn validatedComponentContract(component, contract, componentId);\n}\n\n/** Reads one current executable target artifact and rejects obsolete or identity-only values. */\nexport function readExactExecutableComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactExecutableComponentContract {\n\tconst contract = readExactComponentContract(component);\n\tif (!contract?.artifact)\n\t\tthrow new TypeError('Native eXact component execution requires a compiled component artifact');\n\treturn contract;\n}\n\n/** Reads and validates one client-target executable component contract. */\nexport function readExactClientExecutableComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactClientExecutableComponentContract {\n\tconst contract = readExactExecutableComponentContract(component);\n\tif (contract.artifact.target !== 'client')\n\t\tthrow new TypeError('Client execution requires a current client component artifact');\n\treturn contract as ExactClientExecutableComponentContract;\n}\n\n/** Reads and validates one server-target executable component contract. */\nexport function readExactServerExecutableComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactServerExecutableComponentContract {\n\tconst contract = readExactExecutableComponentContract(component);\n\tif (contract.artifact.target !== 'server')\n\t\tthrow new TypeError('Server execution requires a current server component artifact');\n\treturn contract as ExactServerExecutableComponentContract;\n}\n\n/** Reads build-validated compiler metadata without repeating recursive runtime validation. */\nexport function readPreparedExactComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactPreparedComponentContract | undefined {\n\tconst contract = (component as ContractComponent)[exactComponentContract];\n\tif (contract && contract.artifact?.version !== componentContractVersion)\n\t\tthrow new TypeError(\n\t\t\t`Unsupported eXact component artifact version ${contract.artifact?.version}; expected ${componentContractVersion}. Recompile with the matching eXact compiler.`\n\t\t);\n\treturn contract;\n}\n\n/** Reads a build-validated current executable target artifact. */\nexport function readPreparedExactExecutableComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactPreparedExecutableComponentContract {\n\tconst contract = readPreparedExactComponentContract(component);\n\tif (!contract?.artifact)\n\t\tthrow new TypeError(\n\t\t\t`Native eXact component execution requires a compiled component artifact: ${component.name || '<anonymous>'}`\n\t\t);\n\treturn contract;\n}\n\n/** Reads one build-validated client-target executable component contract. */\nexport function readPreparedExactClientExecutableComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactPreparedComponentContract & Readonly<{ artifact: ExactClientComponentArtifact }> {\n\tconst contract = readPreparedExactExecutableComponentContract(component);\n\tif (contract.artifact.target !== 'client')\n\t\tthrow new TypeError('Client execution requires a current client component artifact');\n\treturn contract as ExactPreparedComponentContract &\n\t\tReadonly<{ artifact: ExactClientComponentArtifact }>;\n}\n\n/** Reads one build-validated server-target executable component contract. */\nexport function readPreparedExactServerExecutableComponentContract(\n\tcomponent: AnyExactComponentCallable\n): ExactServerExecutableComponentContract {\n\tconst contract = readPreparedExactExecutableComponentContract(component);\n\tif (contract.artifact.target !== 'server')\n\t\tthrow new TypeError('Server execution requires a current server component artifact');\n\treturn contract as ExactServerExecutableComponentContract;\n}\n\n/** Returns the stable compiler identity used to pair SSR and client component boundaries. */\nexport function exactComponentIdentity(component: AnyExactComponentCallable): string {\n\tconst identity = (component as ContractComponent)[exactComponentType];\n\tif (typeof identity === 'string' && identity) return identity;\n\tthrow new Error('Native eXact components require compiler-owned identity');\n}\n\n/** Composes reachable imported component contracts into duplicate-checked runtime indexes. */\nexport function composeExactComponentContracts(\n\tcomponents: readonly AnyExactComponentCallable[],\n\trole: ExactComponentContract['role']\n): ExactComposedComponentContracts {\n\treturn composeComponentContracts(components, role, readExactComponentContract);\n}\n\n/** Composes build-validated compiler metadata without repeating recursive validation. */\nexport function composePreparedExactComponentContracts(\n\tcomponents: readonly AnyExactComponentCallable[],\n\trole: ExactComponentContract['role']\n): ExactComposedComponentContracts {\n\treturn composeComponentContracts(components, role, readPreparedExactComponentContract);\n}\n\nfunction composeComponentContracts(\n\tcomponents: readonly AnyExactComponentCallable[],\n\trole: ExactComponentContract['role'],\n\treadContract: (component: AnyExactComponentCallable) => ExactPreparedComponentContract | undefined\n): ExactComposedComponentContracts {\n\tconst implementations: Record<string, AnyExactComponentCallable> = {};\n\tconst implementationsById: Record<string, AnyExactComponentCallable> = {};\n\tconst continuations: Record<string, ExactComponentContinuationContract> = {};\n\tconst executors: Record<string, ExactComponentContinuationExecutorContract> = {};\n\tconst boundaries: Record<string, ExactComponentBoundaryContract> = {};\n\tconst resumptions: Record<string, ExactComponentResumptionContract> = {};\n\tconst executions: Record<string, ExactComponentExecutionContract> = {};\n\tconst artifacts: Record<string, ExactComponentExecutableArtifact> = {};\n\n\tfor (const component of components) {\n\t\tconst contract = readContract(component);\n\t\tif (!contract) continue;\n\t\tconst componentId = exactComponentIdentity(component);\n\t\tconst projectedRole =\n\t\t\tcontract.role ?? (contract.artifact.target === 'client' ? 'client' : 'render');\n\t\tif (projectedRole !== role)\n\t\t\tthrow new Error(\n\t\t\t\t`Expected eXact ${role} component contract for ${componentId}, received ${projectedRole}`\n\t\t\t);\n\t\tconst projectedImplementations = contract.implementations ?? [\n\t\t\t{\n\t\t\t\tid: componentId,\n\t\t\t\tname: component.name,\n\t\t\t\trole: 'root' as const,\n\t\t\t\timplementation: component\n\t\t\t}\n\t\t];\n\t\tfor (const implementation of projectedImplementations) {\n\t\t\taddUniqueImplementation(\n\t\t\t\timplementationsById,\n\t\t\t\timplementation.id,\n\t\t\t\timplementation.implementation\n\t\t\t);\n\t\t\taddUniqueImplementation(implementations, implementation.name, implementation.implementation);\n\t\t}\n\t\tfor (const continuation of contract.continuations ?? [])\n\t\t\taddUniqueJson(continuations, continuation.id, continuation, 'continuation');\n\t\tfor (const executor of contract.executors ?? []) addUniqueExecutor(executors, executor);\n\t\tfor (const boundary of contract.boundaries ?? [])\n\t\t\taddUniqueJson(boundaries, boundary.id, boundary, 'boundary');\n\t\tif (contract.resumption)\n\t\t\taddUniqueJson(\n\t\t\t\tresumptions,\n\t\t\t\tcontract.resumption.componentId,\n\t\t\t\tcontract.resumption,\n\t\t\t\t'resumption'\n\t\t\t);\n\t\tif (contract.execution)\n\t\t\taddUniqueJson(executions, componentId, contract.execution, 'execution plan');\n\t\tartifacts[componentId] = contract.artifact;\n\t}\n\n\treturn Object.freeze({\n\t\timplementations,\n\t\timplementationsById,\n\t\tcontinuations,\n\t\texecutors,\n\t\tboundaries,\n\t\tresumptions,\n\t\texecutions,\n\t\tartifacts\n\t});\n}\n"]}
@@ -1,2 +1,2 @@
1
- export { isExactContinuationDependency, isExactContinuationInvocation, isExactContinuationStatePath } from '../component-contract/continuation-validation.js';
1
+ export { isExactProgressReceiver, isExactContinuationDependency, isExactContinuationInvocation, isExactContinuationStatePath } from '../component-contract/continuation-validation.js';
2
2
  //# sourceMappingURL=component-contract-validation.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"component-contract-validation.d.ts","sourceRoot":"","sources":["../../../src/framework/component-contract-validation.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,6BAA6B,EAC7B,6BAA6B,EAC7B,4BAA4B,EAC5B,MAAM,kDAAkD,CAAC"}
1
+ {"version":3,"file":"component-contract-validation.d.ts","sourceRoot":"","sources":["../../../src/framework/component-contract-validation.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,uBAAuB,EACvB,6BAA6B,EAC7B,6BAA6B,EAC7B,4BAA4B,EAC5B,MAAM,kDAAkD,CAAC"}
@@ -1,2 +1,2 @@
1
- export { isExactContinuationDependency, isExactContinuationInvocation, isExactContinuationStatePath } from '../component-contract/continuation-validation.js';
1
+ export { isExactProgressReceiver, isExactContinuationDependency, isExactContinuationInvocation, isExactContinuationStatePath } from '../component-contract/continuation-validation.js';
2
2
  //# sourceMappingURL=component-contract-validation.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"component-contract-validation.js","sourceRoot":"","sources":["../../../src/framework/component-contract-validation.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,6BAA6B,EAC7B,6BAA6B,EAC7B,4BAA4B,EAC5B,MAAM,kDAAkD,CAAC","sourcesContent":["export {\n\tisExactContinuationDependency,\n\tisExactContinuationInvocation,\n\tisExactContinuationStatePath\n} from '../component-contract/continuation-validation.js';\n"]}
1
+ {"version":3,"file":"component-contract-validation.js","sourceRoot":"","sources":["../../../src/framework/component-contract-validation.ts"],"names":[],"mappings":"AAAA,OAAO,EACN,uBAAuB,EACvB,6BAA6B,EAC7B,6BAA6B,EAC7B,4BAA4B,EAC5B,MAAM,kDAAkD,CAAC","sourcesContent":["export {\n\tisExactProgressReceiver,\n\tisExactContinuationDependency,\n\tisExactContinuationInvocation,\n\tisExactContinuationStatePath\n} from '../component-contract/continuation-validation.js';\n"]}
@@ -0,0 +1,9 @@
1
+ import type { AnyComponentInstance, Child } from '../component/contracts.js';
2
+ /**
3
+ * Projects only one enhancement owner's supplied placement, preserving its authored structure.
4
+ * Nested component implementations stay opaque. Each owner is a host-coalescing barrier; transparent
5
+ * consecutive owners are grouped before this path. The caller supplies range evaluation: clients
6
+ * retain invalidation, while servers resolve the current render attempt without subscriptions.
7
+ */
8
+ export declare function createFragmentTargetProjectionWithRanges(supplied: Child | (() => Child), tag: string, owner: AnyComponentInstance | undefined, projectRange: (read: () => Child, markerId?: string, mayReplaceSubtree?: boolean) => Child): (children: readonly Child[]) => Child[];
9
+ //# sourceMappingURL=fragment-target-projection-plan.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fragment-target-projection-plan.d.ts","sourceRoot":"","sources":["../../../src/framework/fragment-target-projection-plan.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;AA6B7E;;;;;GAKG;AACH,wBAAgB,wCAAwC,CACvD,QAAQ,EAAE,KAAK,GAAG,CAAC,MAAM,KAAK,CAAC,EAC/B,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,oBAAoB,GAAG,SAAS,EACvC,YAAY,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,EAAE,QAAQ,CAAC,EAAE,MAAM,EAAE,iBAAiB,CAAC,EAAE,OAAO,KAAK,KAAK,GACxF,CAAC,QAAQ,EAAE,SAAS,KAAK,EAAE,KAAK,KAAK,EAAE,CAmGzC"}
@@ -0,0 +1,99 @@
1
+ import { unwrap } from '@exactjs/reactive/framework/values';
2
+ import { readCompiledTargetReceipt, createCompiledTargetReceipt } from '../component-abi/target-receipt.js';
3
+ import { readCompiledIntrinsicReceipt, withIntrinsicReceiptChildren } from '../component-abi/intrinsic-receipt.js';
4
+ import { readCompiledFragmentReceipt, createCompiledFragmentReceipt, createCompiledFragmentPresentation } from '../component-abi/fragment-receipt.js';
5
+ import { readChildRangeReceipt } from '../component-abi/child-range-receipt.js';
6
+ import { readPreparedServerChildRange, createPreparedServerChildRange } from '../component-abi/server-child-range.js';
7
+ import { readPreparedServerRenderProgram } from '../server-render-program.js';
8
+ import { readRenderProgramReceipt, createPreparedRenderProgram, readRenderProgramSlot } from '../render-program.js';
9
+ import { readPreparedTargetOutput } from './prepared-target-output.js';
10
+ import { FragmentPresentationHosts } from './fragment-hosts.js';
11
+ /**
12
+ * Projects only one enhancement owner's supplied placement, preserving its authored structure.
13
+ * Nested component implementations stay opaque. Each owner is a host-coalescing barrier; transparent
14
+ * consecutive owners are grouped before this path. The caller supplies range evaluation: clients
15
+ * retain invalidation, while servers resolve the current render attempt without subscriptions.
16
+ */
17
+ export function createFragmentTargetProjectionWithRanges(supplied, tag, owner, projectRange) {
18
+ const identity = Symbol('fragment contribution');
19
+ const hosts = new FragmentPresentationHosts();
20
+ const cache = new WeakMap();
21
+ const map = (raw) => {
22
+ const selected = typeof supplied === 'function' ? supplied() : supplied;
23
+ if (raw === selected)
24
+ return raw;
25
+ const value = unwrap(raw);
26
+ if (value === selected)
27
+ return value;
28
+ if (Array.isArray(value))
29
+ return value.map(map);
30
+ if (typeof value !== 'object' || value === null)
31
+ return value;
32
+ const retained = cache.get(value);
33
+ if (retained !== undefined)
34
+ return retained;
35
+ const target = readCompiledTargetReceipt(value);
36
+ let result = value;
37
+ if (target) {
38
+ const contribution = readPreparedTargetOutput([value], selected);
39
+ const presentation = createCompiledFragmentPresentation(selected, hosts
40
+ .reconcile([
41
+ {
42
+ owner: identity,
43
+ tag,
44
+ props: contribution.props,
45
+ declaredHostProps: contribution.declaredHostProps
46
+ }
47
+ ])
48
+ .map((host) => ({
49
+ identity: host.identity,
50
+ tag: host.tag,
51
+ contributions: [{ identity, props: contribution.props, owner }]
52
+ })));
53
+ result = createCompiledTargetReceipt(null, presentation);
54
+ }
55
+ else {
56
+ const intrinsic = readCompiledIntrinsicReceipt(value);
57
+ const fragment = readCompiledFragmentReceipt(value);
58
+ const range = readChildRangeReceipt(value);
59
+ const serverRange = readPreparedServerChildRange(value);
60
+ const program = readRenderProgramReceipt(value);
61
+ const serverProgram = readPreparedServerRenderProgram(value);
62
+ if (intrinsic)
63
+ result = withIntrinsicReceiptChildren(value, intrinsic.children.map((child) => map(child)));
64
+ else if (fragment)
65
+ result = createCompiledFragmentReceipt({ ...fragment.props, key: fragment.key, __exactEnhancements: fragment.enhancement }, ...fragment.children.map(map));
66
+ else if (range && !range.dynamicComponent)
67
+ result = projectRange(() => map(range.value), range.markerId, range.mayReplaceSubtree);
68
+ else if (serverRange)
69
+ result = createPreparedServerChildRange(map(serverRange.value), serverRange.markerId, serverRange.mayReplaceSubtree);
70
+ else if (program) {
71
+ const invocation = program.invocation;
72
+ const slots = new Set(invocation.program.targetSlots ?? []);
73
+ result = createPreparedRenderProgram(invocation.program, (index) => slots.has(index)
74
+ ? map(readRenderProgramSlot(invocation, index))
75
+ : readRenderProgramSlot(invocation, index), invocation.owner, invocation.propertyWriter, program.enhancement);
76
+ }
77
+ else if (serverProgram) {
78
+ const slots = new Set(serverProgram.program.targetSlots ?? []);
79
+ const values = (input) => input.map((entry, index) => (slots.has(index) ? map(entry) : entry));
80
+ result = {
81
+ ...serverProgram,
82
+ eagerValues: values(serverProgram.eagerValues),
83
+ ...(serverProgram.deferredValues
84
+ ? {
85
+ deferredValues: {
86
+ ...serverProgram.deferredValues,
87
+ read: () => values(serverProgram.deferredValues.read())
88
+ }
89
+ }
90
+ : {})
91
+ };
92
+ }
93
+ }
94
+ cache.set(value, result);
95
+ return result;
96
+ };
97
+ return (children) => children.map((child) => map(child));
98
+ }
99
+ //# sourceMappingURL=fragment-target-projection-plan.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fragment-target-projection-plan.js","sourceRoot":"","sources":["../../../src/framework/fragment-target-projection-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K,CAAU,CAAC,CAAC;AACnE,CAAC","sourcesContent":["import type { AnyComponentInstance, Child } from '../component/contracts.js';\nimport { unwrap } from '@exactjs/reactive/framework/values';\nimport {\n\treadCompiledTargetReceipt,\n\tcreateCompiledTargetReceipt\n} from '../component-abi/target-receipt.js';\nimport {\n\treadCompiledIntrinsicReceipt,\n\twithIntrinsicReceiptChildren\n} from '../component-abi/intrinsic-receipt.js';\nimport {\n\treadCompiledFragmentReceipt,\n\tcreateCompiledFragmentReceipt,\n\tcreateCompiledFragmentPresentation\n} from '../component-abi/fragment-receipt.js';\nimport { readChildRangeReceipt } from '../component-abi/child-range-receipt.js';\nimport {\n\treadPreparedServerChildRange,\n\tcreatePreparedServerChildRange\n} from '../component-abi/server-child-range.js';\nimport { readPreparedServerRenderProgram } from '../server-render-program.js';\nimport {\n\treadRenderProgramReceipt,\n\tcreatePreparedRenderProgram,\n\treadRenderProgramSlot\n} from '../render-program.js';\nimport { readPreparedTargetOutput } from './prepared-target-output.js';\nimport { FragmentPresentationHosts } from './fragment-hosts.js';\n\n/**\n * Projects only one enhancement owner's supplied placement, preserving its authored structure.\n * Nested component implementations stay opaque. Each owner is a host-coalescing barrier; transparent\n * consecutive owners are grouped before this path. The caller supplies range evaluation: clients\n * retain invalidation, while servers resolve the current render attempt without subscriptions.\n */\nexport function createFragmentTargetProjectionWithRanges(\n\tsupplied: Child | (() => Child),\n\ttag: string,\n\towner: AnyComponentInstance | undefined,\n\tprojectRange: (read: () => Child, markerId?: string, mayReplaceSubtree?: boolean) => Child\n): (children: readonly Child[]) => Child[] {\n\tconst identity = Symbol('fragment contribution');\n\tconst hosts = new FragmentPresentationHosts();\n\tconst cache = new WeakMap<object, Child>();\n\tconst map = (raw: unknown): unknown => {\n\t\tconst selected = typeof supplied === 'function' ? supplied() : supplied;\n\t\tif (raw === selected) return raw;\n\t\tconst value = unwrap(raw);\n\t\tif (value === selected) return value;\n\t\tif (Array.isArray(value)) return value.map(map);\n\t\tif (typeof value !== 'object' || value === null) return value;\n\t\tconst retained = cache.get(value);\n\t\tif (retained !== undefined) return retained;\n\t\tconst target = readCompiledTargetReceipt(value);\n\t\tlet result: unknown = value;\n\t\tif (target) {\n\t\t\tconst contribution = readPreparedTargetOutput([value as Child], selected)!;\n\t\t\tconst presentation = createCompiledFragmentPresentation(\n\t\t\t\tselected,\n\t\t\t\thosts\n\t\t\t\t\t.reconcile([\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\towner: identity,\n\t\t\t\t\t\t\ttag,\n\t\t\t\t\t\t\tprops: contribution.props,\n\t\t\t\t\t\t\tdeclaredHostProps: contribution.declaredHostProps\n\t\t\t\t\t\t}\n\t\t\t\t\t])\n\t\t\t\t\t.map((host) => ({\n\t\t\t\t\t\tidentity: host.identity,\n\t\t\t\t\t\ttag: host.tag,\n\t\t\t\t\t\tcontributions: [{ identity, props: contribution.props, owner }]\n\t\t\t\t\t}))\n\t\t\t);\n\t\t\tresult = createCompiledTargetReceipt(null, presentation);\n\t\t} else {\n\t\t\tconst intrinsic = readCompiledIntrinsicReceipt(value);\n\t\t\tconst fragment = readCompiledFragmentReceipt(value);\n\t\t\tconst range = readChildRangeReceipt(value);\n\t\t\tconst serverRange = readPreparedServerChildRange(value);\n\t\t\tconst program = readRenderProgramReceipt(value);\n\t\t\tconst serverProgram = readPreparedServerRenderProgram(value);\n\t\t\tif (intrinsic)\n\t\t\t\tresult = withIntrinsicReceiptChildren(\n\t\t\t\t\tvalue,\n\t\t\t\t\tintrinsic.children.map((child) => map(child) as Child)\n\t\t\t\t);\n\t\t\telse if (fragment)\n\t\t\t\tresult = createCompiledFragmentReceipt(\n\t\t\t\t\t{ ...fragment.props, key: fragment.key, __exactEnhancements: fragment.enhancement },\n\t\t\t\t\t...fragment.children.map(map)\n\t\t\t\t);\n\t\t\telse if (range && !range.dynamicComponent)\n\t\t\t\tresult = projectRange(\n\t\t\t\t\t() => map(range.value) as Child,\n\t\t\t\t\trange.markerId,\n\t\t\t\t\trange.mayReplaceSubtree\n\t\t\t\t);\n\t\t\telse if (serverRange)\n\t\t\t\tresult = createPreparedServerChildRange(\n\t\t\t\t\tmap(serverRange.value) as Child,\n\t\t\t\t\tserverRange.markerId,\n\t\t\t\t\tserverRange.mayReplaceSubtree\n\t\t\t\t);\n\t\t\telse if (program) {\n\t\t\t\tconst invocation = program.invocation;\n\t\t\t\tconst slots = new Set(invocation.program.targetSlots ?? []);\n\t\t\t\tresult = createPreparedRenderProgram(\n\t\t\t\t\tinvocation.program,\n\t\t\t\t\t(index) =>\n\t\t\t\t\t\tslots.has(index)\n\t\t\t\t\t\t\t? map(readRenderProgramSlot(invocation, index))\n\t\t\t\t\t\t\t: readRenderProgramSlot(invocation, index),\n\t\t\t\t\tinvocation.owner,\n\t\t\t\t\tinvocation.propertyWriter,\n\t\t\t\t\tprogram.enhancement\n\t\t\t\t);\n\t\t\t} else if (serverProgram) {\n\t\t\t\tconst slots = new Set(serverProgram.program.targetSlots ?? []);\n\t\t\t\tconst values = (input: readonly unknown[]) =>\n\t\t\t\t\tinput.map((entry, index) => (slots.has(index) ? map(entry) : entry));\n\t\t\t\tresult = {\n\t\t\t\t\t...serverProgram,\n\t\t\t\t\teagerValues: values(serverProgram.eagerValues),\n\t\t\t\t\t...(serverProgram.deferredValues\n\t\t\t\t\t\t? {\n\t\t\t\t\t\t\t\tdeferredValues: {\n\t\t\t\t\t\t\t\t\t...serverProgram.deferredValues,\n\t\t\t\t\t\t\t\t\tread: () => values(serverProgram.deferredValues!.read())\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t: {})\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\t\tcache.set(value, result as Child);\n\t\treturn result;\n\t};\n\treturn (children) => children.map((child) => map(child) as Child);\n}\n"]}
@@ -1,8 +1,4 @@
1
1
  import type { AnyComponentInstance, Child } from '../component/contracts.js';
2
- /**
3
- * Projects only one enhancement owner's supplied placement, preserving its authored structure.
4
- * Nested component implementations stay opaque. Each owner is a host-coalescing barrier; transparent
5
- * consecutive owners are grouped before this path. Reactive ranges retain their existing invalidation.
6
- */
2
+ /** Projects fragment targets while retaining client range subscriptions and ownership. */
7
3
  export declare function createFragmentTargetProjection(supplied: Child | (() => Child), tag: string, owner?: AnyComponentInstance): (children: readonly Child[]) => Child[];
8
4
  //# sourceMappingURL=fragment-target-projection.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"fragment-target-projection.d.ts","sourceRoot":"","sources":["../../../src/framework/fragment-target-projection.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;AAgC7E;;;;GAIG;AACH,wBAAgB,8BAA8B,CAC7C,QAAQ,EAAE,KAAK,GAAG,CAAC,MAAM,KAAK,CAAC,EAC/B,GAAG,EAAE,MAAM,EACX,KAAK,CAAC,EAAE,oBAAoB,GAC1B,CAAC,QAAQ,EAAE,SAAS,KAAK,EAAE,KAAK,KAAK,EAAE,CAmGzC"}
1
+ {"version":3,"file":"fragment-target-projection.d.ts","sourceRoot":"","sources":["../../../src/framework/fragment-target-projection.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;AAK7E,0FAA0F;AAC1F,wBAAgB,8BAA8B,CAC7C,QAAQ,EAAE,KAAK,GAAG,CAAC,MAAM,KAAK,CAAC,EAC/B,GAAG,EAAE,MAAM,EACX,KAAK,CAAC,EAAE,oBAAoB,GAC1B,CAAC,QAAQ,EAAE,SAAS,KAAK,EAAE,KAAK,KAAK,EAAE,CAQzC"}
@@ -1,98 +1,8 @@
1
- import { computed, unwrap } from '@exactjs/reactive/framework/runtime';
2
- import { readCompiledTargetReceipt, createCompiledTargetReceipt } from '../component-abi/target-receipt.js';
3
- import { readCompiledIntrinsicReceipt, withIntrinsicReceiptChildren } from '../component-abi/intrinsic-receipt.js';
4
- import { readCompiledFragmentReceipt, createCompiledFragmentReceipt, createCompiledFragmentPresentation } from '../component-abi/fragment-receipt.js';
5
- import { readChildRangeReceipt, createChildRangeReceipt } from '../component-abi/child-range-receipt.js';
6
- import { readPreparedServerChildRange, createPreparedServerChildRange } from '../component-abi/server-child-range.js';
7
- import { readPreparedServerRenderProgram } from '../server-render-program.js';
8
- import { readRenderProgramReceipt, createPreparedRenderProgram, readRenderProgramSlot } from '../render-program.js';
9
- import { readPreparedTargetOutput } from './prepared-target-output.js';
10
- import { FragmentPresentationHosts } from './fragment-hosts.js';
11
- /**
12
- * Projects only one enhancement owner's supplied placement, preserving its authored structure.
13
- * Nested component implementations stay opaque. Each owner is a host-coalescing barrier; transparent
14
- * consecutive owners are grouped before this path. Reactive ranges retain their existing invalidation.
15
- */
1
+ import { computed } from '@exactjs/reactive/framework/runtime';
2
+ import { createChildRangeReceipt } from '../component-abi/child-range-receipt.js';
3
+ import { createFragmentTargetProjectionWithRanges } from './fragment-target-projection-plan.js';
4
+ /** Projects fragment targets while retaining client range subscriptions and ownership. */
16
5
  export function createFragmentTargetProjection(supplied, tag, owner) {
17
- const identity = Symbol('fragment contribution');
18
- const hosts = new FragmentPresentationHosts();
19
- const cache = new WeakMap();
20
- const map = (raw) => {
21
- const selected = typeof supplied === 'function' ? supplied() : supplied;
22
- if (raw === selected)
23
- return raw;
24
- const value = unwrap(raw);
25
- if (value === selected)
26
- return value;
27
- if (Array.isArray(value))
28
- return value.map(map);
29
- if (typeof value !== 'object' || value === null)
30
- return value;
31
- const retained = cache.get(value);
32
- if (retained !== undefined)
33
- return retained;
34
- const target = readCompiledTargetReceipt(value);
35
- let result = value;
36
- if (target) {
37
- const contribution = readPreparedTargetOutput([value], selected);
38
- const presentation = createCompiledFragmentPresentation(selected, hosts
39
- .reconcile([
40
- {
41
- owner: identity,
42
- tag,
43
- props: contribution.props,
44
- declaredHostProps: contribution.declaredHostProps
45
- }
46
- ])
47
- .map((host) => ({
48
- identity: host.identity,
49
- tag: host.tag,
50
- contributions: [{ identity, props: contribution.props, owner }]
51
- })));
52
- result = createCompiledTargetReceipt(null, presentation);
53
- }
54
- else {
55
- const intrinsic = readCompiledIntrinsicReceipt(value);
56
- const fragment = readCompiledFragmentReceipt(value);
57
- const range = readChildRangeReceipt(value);
58
- const serverRange = readPreparedServerChildRange(value);
59
- const program = readRenderProgramReceipt(value);
60
- const serverProgram = readPreparedServerRenderProgram(value);
61
- if (intrinsic)
62
- result = withIntrinsicReceiptChildren(value, intrinsic.children.map((child) => map(child)));
63
- else if (fragment)
64
- result = createCompiledFragmentReceipt({ ...fragment.props, key: fragment.key, __exactEnhancements: fragment.enhancement }, ...fragment.children.map(map));
65
- else if (range && !range.dynamicComponent)
66
- result = createChildRangeReceipt(computed(() => map(range.value)), range.markerId, range.mayReplaceSubtree);
67
- else if (serverRange)
68
- result = createPreparedServerChildRange(map(serverRange.value), serverRange.markerId, serverRange.mayReplaceSubtree);
69
- else if (program) {
70
- const invocation = program.invocation;
71
- const slots = new Set(invocation.program.targetSlots ?? []);
72
- result = createPreparedRenderProgram(invocation.program, (index) => slots.has(index)
73
- ? map(readRenderProgramSlot(invocation, index))
74
- : readRenderProgramSlot(invocation, index), invocation.owner, invocation.propertyWriter, program.enhancement);
75
- }
76
- else if (serverProgram) {
77
- const slots = new Set(serverProgram.program.targetSlots ?? []);
78
- const values = (input) => input.map((entry, index) => (slots.has(index) ? map(entry) : entry));
79
- result = {
80
- ...serverProgram,
81
- eagerValues: values(serverProgram.eagerValues),
82
- ...(serverProgram.deferredValues
83
- ? {
84
- deferredValues: {
85
- ...serverProgram.deferredValues,
86
- read: () => values(serverProgram.deferredValues.read())
87
- }
88
- }
89
- : {})
90
- };
91
- }
92
- }
93
- cache.set(value, result);
94
- return result;
95
- };
96
- return (children) => children.map((child) => map(child));
6
+ return createFragmentTargetProjectionWithRanges(supplied, tag, owner, (read, markerId, mayReplaceSubtree) => createChildRangeReceipt(computed(read), markerId, mayReplaceSubtree));
97
7
  }
98
8
  //# sourceMappingURL=fragment-target-projection.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"fragment-target-projection.js","sourceRoot":"","sources":["../../../src/framework/fragment-target-projection.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,qCAAqC,CAAC;AACvE,OAAO,EACN,yBAAyB,EACzB,2BAA2B,EAC3B,MAAM,oCAAoC,CAAC;AAC5C,OAAO,EACN,4BAA4B,EAC5B,4BAA4B,EAC5B,MAAM,uCAAuC,CAAC;AAC/C,OAAO,EACN,2BAA2B,EAC3B,6BAA6B,EAC7B,kCAAkC,EAClC,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EACN,qBAAqB,EACrB,uBAAuB,EACvB,MAAM,yCAAyC,CAAC;AACjD,OAAO,EACN,4BAA4B,EAC5B,8BAA8B,EAC9B,MAAM,wCAAwC,CAAC;AAChD,OAAO,EAAE,+BAA+B,EAAE,MAAM,6BAA6B,CAAC;AAC9E,OAAO,EACN,wBAAwB,EACxB,2BAA2B,EAC3B,qBAAqB,EACrB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EAAE,wBAAwB,EAAE,MAAM,6BAA6B,CAAC;AACvE,OAAO,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAEhE;;;;GAIG;AACH,MAAM,UAAU,8BAA8B,CAC7C,QAA+B,EAC/B,GAAW,EACX,KAA4B;IAE5B,MAAM,QAAQ,GAAG,MAAM,CAAC,uBAAuB,CAAC,CAAC;IACjD,MAAM,KAAK,GAAG,IAAI,yBAAyB,EAAE,CAAC;IAC9C,MAAM,KAAK,GAAG,IAAI,OAAO,EAAiB,CAAC;IAC3C,MAAM,GAAG,GAAG,CAAC,GAAY,EAAW,EAAE;QACrC,MAAM,QAAQ,GAAG,OAAO,QAAQ,KAAK,UAAU,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAC;QACxE,IAAI,GAAG,KAAK,QAAQ;YAAE,OAAO,GAAG,CAAC;QACjC,M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;IACF,OAAO,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,GAAG,CAAC,KAAK,CAAU,CAAC,CAAC;AACnE,CAAC","sourcesContent":["import type { AnyComponentInstance, Child } from '../component/contracts.js';\nimport { computed, unwrap } from '@exactjs/reactive/framework/runtime';\nimport {\n\treadCompiledTargetReceipt,\n\tcreateCompiledTargetReceipt\n} from '../component-abi/target-receipt.js';\nimport {\n\treadCompiledIntrinsicReceipt,\n\twithIntrinsicReceiptChildren\n} from '../component-abi/intrinsic-receipt.js';\nimport {\n\treadCompiledFragmentReceipt,\n\tcreateCompiledFragmentReceipt,\n\tcreateCompiledFragmentPresentation\n} from '../component-abi/fragment-receipt.js';\nimport {\n\treadChildRangeReceipt,\n\tcreateChildRangeReceipt\n} from '../component-abi/child-range-receipt.js';\nimport {\n\treadPreparedServerChildRange,\n\tcreatePreparedServerChildRange\n} from '../component-abi/server-child-range.js';\nimport { readPreparedServerRenderProgram } from '../server-render-program.js';\nimport {\n\treadRenderProgramReceipt,\n\tcreatePreparedRenderProgram,\n\treadRenderProgramSlot\n} from '../render-program.js';\nimport { readPreparedTargetOutput } from './prepared-target-output.js';\nimport { FragmentPresentationHosts } from './fragment-hosts.js';\n\n/**\n * Projects only one enhancement owner's supplied placement, preserving its authored structure.\n * Nested component implementations stay opaque. Each owner is a host-coalescing barrier; transparent\n * consecutive owners are grouped before this path. Reactive ranges retain their existing invalidation.\n */\nexport function createFragmentTargetProjection(\n\tsupplied: Child | (() => Child),\n\ttag: string,\n\towner?: AnyComponentInstance\n): (children: readonly Child[]) => Child[] {\n\tconst identity = Symbol('fragment contribution');\n\tconst hosts = new FragmentPresentationHosts();\n\tconst cache = new WeakMap<object, Child>();\n\tconst map = (raw: unknown): unknown => {\n\t\tconst selected = typeof supplied === 'function' ? supplied() : supplied;\n\t\tif (raw === selected) return raw;\n\t\tconst value = unwrap(raw);\n\t\tif (value === selected) return value;\n\t\tif (Array.isArray(value)) return value.map(map);\n\t\tif (typeof value !== 'object' || value === null) return value;\n\t\tconst retained = cache.get(value);\n\t\tif (retained !== undefined) return retained;\n\t\tconst target = readCompiledTargetReceipt(value);\n\t\tlet result: unknown = value;\n\t\tif (target) {\n\t\t\tconst contribution = readPreparedTargetOutput([value as Child], selected)!;\n\t\t\tconst presentation = createCompiledFragmentPresentation(\n\t\t\t\tselected,\n\t\t\t\thosts\n\t\t\t\t\t.reconcile([\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\towner: identity,\n\t\t\t\t\t\t\ttag,\n\t\t\t\t\t\t\tprops: contribution.props,\n\t\t\t\t\t\t\tdeclaredHostProps: contribution.declaredHostProps\n\t\t\t\t\t\t}\n\t\t\t\t\t])\n\t\t\t\t\t.map((host) => ({\n\t\t\t\t\t\tidentity: host.identity,\n\t\t\t\t\t\ttag: host.tag,\n\t\t\t\t\t\tcontributions: [{ identity, props: contribution.props, owner }]\n\t\t\t\t\t}))\n\t\t\t);\n\t\t\tresult = createCompiledTargetReceipt(null, presentation);\n\t\t} else {\n\t\t\tconst intrinsic = readCompiledIntrinsicReceipt(value);\n\t\t\tconst fragment = readCompiledFragmentReceipt(value);\n\t\t\tconst range = readChildRangeReceipt(value);\n\t\t\tconst serverRange = readPreparedServerChildRange(value);\n\t\t\tconst program = readRenderProgramReceipt(value);\n\t\t\tconst serverProgram = readPreparedServerRenderProgram(value);\n\t\t\tif (intrinsic)\n\t\t\t\tresult = withIntrinsicReceiptChildren(\n\t\t\t\t\tvalue,\n\t\t\t\t\tintrinsic.children.map((child) => map(child) as Child)\n\t\t\t\t);\n\t\t\telse if (fragment)\n\t\t\t\tresult = createCompiledFragmentReceipt(\n\t\t\t\t\t{ ...fragment.props, key: fragment.key, __exactEnhancements: fragment.enhancement },\n\t\t\t\t\t...fragment.children.map(map)\n\t\t\t\t);\n\t\t\telse if (range && !range.dynamicComponent)\n\t\t\t\tresult = createChildRangeReceipt(\n\t\t\t\t\tcomputed(() => map(range.value)),\n\t\t\t\t\trange.markerId,\n\t\t\t\t\trange.mayReplaceSubtree\n\t\t\t\t);\n\t\t\telse if (serverRange)\n\t\t\t\tresult = createPreparedServerChildRange(\n\t\t\t\t\tmap(serverRange.value) as Child,\n\t\t\t\t\tserverRange.markerId,\n\t\t\t\t\tserverRange.mayReplaceSubtree\n\t\t\t\t);\n\t\t\telse if (program) {\n\t\t\t\tconst invocation = program.invocation;\n\t\t\t\tconst slots = new Set(invocation.program.targetSlots ?? []);\n\t\t\t\tresult = createPreparedRenderProgram(\n\t\t\t\t\tinvocation.program,\n\t\t\t\t\t(index) =>\n\t\t\t\t\t\tslots.has(index)\n\t\t\t\t\t\t\t? map(readRenderProgramSlot(invocation, index))\n\t\t\t\t\t\t\t: readRenderProgramSlot(invocation, index),\n\t\t\t\t\tinvocation.owner,\n\t\t\t\t\tinvocation.propertyWriter,\n\t\t\t\t\tprogram.enhancement\n\t\t\t\t);\n\t\t\t} else if (serverProgram) {\n\t\t\t\tconst slots = new Set(serverProgram.program.targetSlots ?? []);\n\t\t\t\tconst values = (input: readonly unknown[]) =>\n\t\t\t\t\tinput.map((entry, index) => (slots.has(index) ? map(entry) : entry));\n\t\t\t\tresult = {\n\t\t\t\t\t...serverProgram,\n\t\t\t\t\teagerValues: values(serverProgram.eagerValues),\n\t\t\t\t\t...(serverProgram.deferredValues\n\t\t\t\t\t\t? {\n\t\t\t\t\t\t\t\tdeferredValues: {\n\t\t\t\t\t\t\t\t\t...serverProgram.deferredValues,\n\t\t\t\t\t\t\t\t\tread: () => values(serverProgram.deferredValues!.read())\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t: {})\n\t\t\t\t};\n\t\t\t}\n\t\t}\n\t\tcache.set(value, result as Child);\n\t\treturn result;\n\t};\n\treturn (children) => children.map((child) => map(child) as Child);\n}\n"]}
1
+ {"version":3,"file":"fragment-target-projection.js","sourceRoot":"","sources":["../../../src/framework/fragment-target-projection.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,qCAAqC,CAAC;AAC/D,OAAO,EAAE,uBAAuB,EAAE,MAAM,yCAAyC,CAAC;AAClF,OAAO,EAAE,wCAAwC,EAAE,MAAM,sCAAsC,CAAC;AAEhG,0FAA0F;AAC1F,MAAM,UAAU,8BAA8B,CAC7C,QAA+B,EAC/B,GAAW,EACX,KAA4B;IAE5B,OAAO,wCAAwC,CAC9C,QAAQ,EACR,GAAG,EACH,KAAK,EACL,CAAC,IAAI,EAAE,QAAQ,EAAE,iBAAiB,EAAE,EAAE,CACrC,uBAAuB,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,QAAQ,EAAE,iBAAiB,CAAC,CACrE,CAAC;AACH,CAAC","sourcesContent":["import type { AnyComponentInstance, Child } from '../component/contracts.js';\nimport { computed } from '@exactjs/reactive/framework/runtime';\nimport { createChildRangeReceipt } from '../component-abi/child-range-receipt.js';\nimport { createFragmentTargetProjectionWithRanges } from './fragment-target-projection-plan.js';\n\n/** Projects fragment targets while retaining client range subscriptions and ownership. */\nexport function createFragmentTargetProjection(\n\tsupplied: Child | (() => Child),\n\ttag: string,\n\towner?: AnyComponentInstance\n): (children: readonly Child[]) => Child[] {\n\treturn createFragmentTargetProjectionWithRanges(\n\t\tsupplied,\n\t\ttag,\n\t\towner,\n\t\t(read, markerId, mayReplaceSubtree) =>\n\t\t\tcreateChildRangeReceipt(computed(read), markerId, mayReplaceSubtree)\n\t);\n}\n"]}
@@ -83,6 +83,15 @@ export type ExactBatchResult = {
83
83
  };
84
84
  /** Reports one event in an incremental operation response. */
85
85
  export type ExactStreamEvent = {
86
+ event: 'progress';
87
+ version: 1;
88
+ index: number;
89
+ type: ExactInvocationKind;
90
+ id: string;
91
+ opId?: string;
92
+ receiver: string;
93
+ snapshot: unknown;
94
+ } | {
86
95
  event: 'start';
87
96
  version: 1;
88
97
  operations: number;
@@ -1 +1 @@
1
- {"version":3,"file":"operation-protocol.d.ts","source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,MAAM,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE,GAC1D;IAAE,IAAI,EAAE,OAAO,CAAC;IAAC,EAAE,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,GAAG,IAAI,CAAA;CAAE,GACjE;IACA,IAAI,EAAE,MAAM,CAAC;IACb,EAAE,EAAE,MAAM,CAAC;IACX,EAAE,EAAE,QAAQ,GAAG,MAAM,GAAG,QAAQ,CAAC;IACjC,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,CAAC,EAAE,MAAM,CAAC;CACb,GACD;IAAE,IAAI,EAAE,OAAO,CAAC;IAAC,EAAE,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,OAAO,CAAA;CAAE,GAC7C;IAAE,IAAI,EAAE,SAAS,CAAC;IAAC,EAAE,EAAE,MAAM,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CAAC;AAejD;;;;GAIG;AACH,wBAAgB,sBAAsB,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAK5D;AAED,YAAY,EAAE,uBAAuB,EAAE,MAAM,2BAA2B,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"operation-protocol.js","sourceRoot":"","sources":["../../../src/framework/operation-protocol.ts"],"names":[],"mappings":"AAoJA,MAAM,2BAA2B,GAAG,IAAI,GAAG,CAAC;IAC3C,WAAW;IACX,aAAa;IACb,yBAAyB;IACzB,WAAW;IACX,WAAW;IACX,WAAW;IACX,WAAW;IACX,WAAW;IACX,QAAQ;IACR,aAAa;CACb,CAAC,CAAC;AAEH;;;;GAIG;AACH,MAAM,UAAU,sBAAsB,CAAC,IAAY;IAClD,MAAM,UAAU,GAAG,IAAI,CAAC,WAAW,EAAE,CAAC;IACtC,OAAO,CACN,CAAC,CAAC,UAAU,IAAI,CAAC,UAAU,CAAC,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,2BAA2B,CAAC,GAAG,CAAC,UAAU,CAAC,CAC5F,CAAC;AACH,CAAC","sourcesContent":["import type { ExactCollectionMutation } from '../component-contracts.js';\nimport type { ExactRuntimeInspectionEvent } from '@exactjs/devtools-protocol';\n\n/** Identifies the operation represented by a framework protocol request. */\nexport type ExactInvocationKind = 'invoke' | 'refresh';\n\n/** Selects one concrete compiler-planned partition instance. */\nexport type ExactPartitionDiscriminator =\n\t| Readonly<{ kind: 'single' }>\n\t| Readonly<{ kind: 'branch'; branch: string }>\n\t| Readonly<{ kind: 'keyed'; list: string; keyToken: string }>;\n\n/** Carries generation-fenced authority for a compiler-planned partition. */\nexport type ExactPartitionAuthority = Readonly<{\n\tversion: 1;\n\tbuildKey: string;\n\texecutionRoot: string;\n\tplanEdgeId: string;\n\townerComponentId: string;\n\tdiscriminator: ExactPartitionDiscriminator;\n\tgeneration: number;\n}>;\n\n/** Maps compiler-owned operation identities to configured endpoint routes. */\nexport type ExactEndpointRoutes = {\n\tinvocations?: Record<string, string>;\n\tboundaries?: Record<string, string>;\n};\n\n/** Describes one invocation or refresh request on the framework wire protocol. */\nexport type ExactInvocationRequest = {\n\ttype: ExactInvocationKind;\n\troot?: string;\n\tid: string;\n\tpartition?: ExactPartitionAuthority;\n\topId?: string;\n\tdependsOn?: string[];\n\tpayload?: unknown;\n\tstate?: unknown;\n\tpublicContext?: Record<string, unknown>;\n\tboundaryHtml?: string;\n\tboundaryHtmls?: Record<string, string>;\n};\n\n/** Groups invocation requests for bounded concurrent execution. */\nexport type ExactBatchRequest = {\n\ttype: 'batch';\n\tversion?: 1;\n\toperations: ExactInvocationRequest[];\n};\n\n/** Describes the transport-safe result of one invocation. */\nexport type ExactInvocationResult = {\n\tpatches?: ExactPatch[];\n\tstate?: unknown;\n\tmutations?: ExactCollectionMutation[];\n\tcontexts?: Record<string, unknown>;\n\tvalue?: unknown;\n\thtml?: string;\n};\n\n/** Describes a successful operation response. */\nexport type ExactOperationSuccess = {\n\tok: true;\n\ttype: ExactInvocationKind;\n\tid: string;\n\topId?: string;\n} & ExactInvocationResult;\n\n/** Describes a rejected or failed operation response. */\nexport type ExactOperationError = {\n\tok: false;\n\ttype: ExactInvocationKind;\n\tid: string;\n\topId?: string;\n\tstatus: number;\n\terror: 'bad_request' | 'not_found' | 'forbidden' | 'internal_error' | 'dependency_failed';\n};\n\n/** Describes the result of one operation. */\nexport type ExactOperationResult = ExactOperationSuccess | ExactOperationError;\n\n/** Describes a completed batch response. */\nexport type ExactBatchResult = {\n\tok: true;\n\tversion: 1;\n\tresults: ExactOperationResult[];\n};\n\n/** Reports one event in an incremental operation response. */\nexport type ExactStreamEvent =\n\t| { event: 'start'; version: 1; operations: number }\n\t| {\n\t\t\tevent: 'patch';\n\t\t\tversion: 1;\n\t\t\tindex: number;\n\t\t\ttype: ExactInvocationKind;\n\t\t\tid: string;\n\t\t\topId?: string;\n\t\t\tpatch: ExactPatch;\n\t }\n\t| {\n\t\t\tevent: 'state';\n\t\t\tversion: 1;\n\t\t\tindex: number;\n\t\t\ttype: ExactInvocationKind;\n\t\t\tid: string;\n\t\t\topId?: string;\n\t\t\tvalue: unknown;\n\t }\n\t| {\n\t\t\tevent: 'mutations';\n\t\t\tversion: 1;\n\t\t\tindex: number;\n\t\t\ttype: ExactInvocationKind;\n\t\t\tid: string;\n\t\t\topId?: string;\n\t\t\tmutations: ExactCollectionMutation[];\n\t }\n\t| {\n\t\t\tevent: 'html';\n\t\t\tversion: 1;\n\t\t\tindex: number;\n\t\t\ttype: ExactInvocationKind;\n\t\t\tid: string;\n\t\t\topId?: string;\n\t\t\thtml: string;\n\t }\n\t| { event: 'result'; version: 1; index: number; result: ExactOperationResult }\n\t| { event: 'observations'; version: 1; observations: readonly ExactRuntimeInspectionEvent[] }\n\t| { event: 'complete'; version: 1 };\n\n/** Describes one client-applied operation patch. */\nexport type ExactPatch =\n\t| { type: 'text'; id: string; value: string }\n\t| { type: 'prop'; id: string; name: string; value: unknown }\n\t| { type: 'style'; id: string; name: string; value: string | null }\n\t| {\n\t\t\ttype: 'list';\n\t\t\tid: string;\n\t\t\top: 'insert' | 'move' | 'remove';\n\t\t\tkey: string;\n\t\t\tbefore?: string;\n\t\t\thtml?: string;\n\t }\n\t| { type: 'state'; id: string; value: unknown }\n\t| { type: 'replace'; id: string; html: string };\n\nconst forbiddenDomPatchProperties = new Set([\n\t'__proto__',\n\t'constructor',\n\t'dangerouslysetinnerhtml',\n\t'innerhtml',\n\t'innertext',\n\t'outerhtml',\n\t'outertext',\n\t'prototype',\n\t'srcdoc',\n\t'textcontent'\n]);\n\n/**\n * Reports whether a server property patch may cross the operation boundary.\n * Structural HTML/text setters, inline event handlers, iframe documents, and\n * JavaScript prototype controls require dedicated framework-owned operations.\n */\nexport function isSafeDomPatchProperty(name: string): boolean {\n\tconst normalized = name.toLowerCase();\n\treturn (\n\t\t!!normalized && !normalized.startsWith('on') && !forbiddenDomPatchProperties.has(normalized)\n\t);\n}\n\nexport type { ExactCollectionMutation } from '../component-contracts.js';\n"]}
1
+ {"version":3,"file":"operation-protocol.js","sourceRoot":"","sources":["../../../src/framework/operation-protocol.ts"],"names":[],"mappings":"AA8JA,MAAM,2BAA2B,GAAG,IAAI,GAAG,CAAC;IAC3C,WAAW;IACX,aAAa;IACb,yBAAyB;IACzB,WAAW;IACX,WAAW;IACX,WAAW;IACX,WAAW;IACX,WAAW;IACX,QAAQ;IACR,aAAa;CACb,CAAC,CAAC;AAEH;;;;GAIG;AACH,MAAM,UAAU,sBAAsB,CAAC,IAAY;IAClD,MAAM,UAAU,GAAG,IAAI,CAAC,WAAW,EAAE,CAAC;IACtC,OAAO,CACN,CAAC,CAAC,UAAU,IAAI,CAAC,UAAU,CAAC,UAAU,CAAC,IAAI,CAAC,IAAI,CAAC,2BAA2B,CAAC,GAAG,CAAC,UAAU,CAAC,CAC5F,CAAC;AACH,CAAC","sourcesContent":["import type { ExactCollectionMutation } from '../component-contracts.js';\nimport type { ExactRuntimeInspectionEvent } from '@exactjs/devtools-protocol';\n\n/** Identifies the operation represented by a framework protocol request. */\nexport type ExactInvocationKind = 'invoke' | 'refresh';\n\n/** Selects one concrete compiler-planned partition instance. */\nexport type ExactPartitionDiscriminator =\n\t| Readonly<{ kind: 'single' }>\n\t| Readonly<{ kind: 'branch'; branch: string }>\n\t| Readonly<{ kind: 'keyed'; list: string; keyToken: string }>;\n\n/** Carries generation-fenced authority for a compiler-planned partition. */\nexport type ExactPartitionAuthority = Readonly<{\n\tversion: 1;\n\tbuildKey: string;\n\texecutionRoot: string;\n\tplanEdgeId: string;\n\townerComponentId: string;\n\tdiscriminator: ExactPartitionDiscriminator;\n\tgeneration: number;\n}>;\n\n/** Maps compiler-owned operation identities to configured endpoint routes. */\nexport type ExactEndpointRoutes = {\n\tinvocations?: Record<string, string>;\n\tboundaries?: Record<string, string>;\n};\n\n/** Describes one invocation or refresh request on the framework wire protocol. */\nexport type ExactInvocationRequest = {\n\ttype: ExactInvocationKind;\n\troot?: string;\n\tid: string;\n\tpartition?: ExactPartitionAuthority;\n\topId?: string;\n\tdependsOn?: string[];\n\tpayload?: unknown;\n\tstate?: unknown;\n\tpublicContext?: Record<string, unknown>;\n\tboundaryHtml?: string;\n\tboundaryHtmls?: Record<string, string>;\n};\n\n/** Groups invocation requests for bounded concurrent execution. */\nexport type ExactBatchRequest = {\n\ttype: 'batch';\n\tversion?: 1;\n\toperations: ExactInvocationRequest[];\n};\n\n/** Describes the transport-safe result of one invocation. */\nexport type ExactInvocationResult = {\n\tpatches?: ExactPatch[];\n\tstate?: unknown;\n\tmutations?: ExactCollectionMutation[];\n\tcontexts?: Record<string, unknown>;\n\tvalue?: unknown;\n\thtml?: string;\n};\n\n/** Describes a successful operation response. */\nexport type ExactOperationSuccess = {\n\tok: true;\n\ttype: ExactInvocationKind;\n\tid: string;\n\topId?: string;\n} & ExactInvocationResult;\n\n/** Describes a rejected or failed operation response. */\nexport type ExactOperationError = {\n\tok: false;\n\ttype: ExactInvocationKind;\n\tid: string;\n\topId?: string;\n\tstatus: number;\n\terror: 'bad_request' | 'not_found' | 'forbidden' | 'internal_error' | 'dependency_failed';\n};\n\n/** Describes the result of one operation. */\nexport type ExactOperationResult = ExactOperationSuccess | ExactOperationError;\n\n/** Describes a completed batch response. */\nexport type ExactBatchResult = {\n\tok: true;\n\tversion: 1;\n\tresults: ExactOperationResult[];\n};\n\n/** Reports one event in an incremental operation response. */\nexport type ExactStreamEvent =\n\t| {\n\t\t\tevent: 'progress';\n\t\t\tversion: 1;\n\t\t\tindex: number;\n\t\t\ttype: ExactInvocationKind;\n\t\t\tid: string;\n\t\t\topId?: string;\n\t\t\treceiver: string;\n\t\t\tsnapshot: unknown;\n\t }\n\t| { event: 'start'; version: 1; operations: number }\n\t| {\n\t\t\tevent: 'patch';\n\t\t\tversion: 1;\n\t\t\tindex: number;\n\t\t\ttype: ExactInvocationKind;\n\t\t\tid: string;\n\t\t\topId?: string;\n\t\t\tpatch: ExactPatch;\n\t }\n\t| {\n\t\t\tevent: 'state';\n\t\t\tversion: 1;\n\t\t\tindex: number;\n\t\t\ttype: ExactInvocationKind;\n\t\t\tid: string;\n\t\t\topId?: string;\n\t\t\tvalue: unknown;\n\t }\n\t| {\n\t\t\tevent: 'mutations';\n\t\t\tversion: 1;\n\t\t\tindex: number;\n\t\t\ttype: ExactInvocationKind;\n\t\t\tid: string;\n\t\t\topId?: string;\n\t\t\tmutations: ExactCollectionMutation[];\n\t }\n\t| {\n\t\t\tevent: 'html';\n\t\t\tversion: 1;\n\t\t\tindex: number;\n\t\t\ttype: ExactInvocationKind;\n\t\t\tid: string;\n\t\t\topId?: string;\n\t\t\thtml: string;\n\t }\n\t| { event: 'result'; version: 1; index: number; result: ExactOperationResult }\n\t| { event: 'observations'; version: 1; observations: readonly ExactRuntimeInspectionEvent[] }\n\t| { event: 'complete'; version: 1 };\n\n/** Describes one client-applied operation patch. */\nexport type ExactPatch =\n\t| { type: 'text'; id: string; value: string }\n\t| { type: 'prop'; id: string; name: string; value: unknown }\n\t| { type: 'style'; id: string; name: string; value: string | null }\n\t| {\n\t\t\ttype: 'list';\n\t\t\tid: string;\n\t\t\top: 'insert' | 'move' | 'remove';\n\t\t\tkey: string;\n\t\t\tbefore?: string;\n\t\t\thtml?: string;\n\t }\n\t| { type: 'state'; id: string; value: unknown }\n\t| { type: 'replace'; id: string; html: string };\n\nconst forbiddenDomPatchProperties = new Set([\n\t'__proto__',\n\t'constructor',\n\t'dangerouslysetinnerhtml',\n\t'innerhtml',\n\t'innertext',\n\t'outerhtml',\n\t'outertext',\n\t'prototype',\n\t'srcdoc',\n\t'textcontent'\n]);\n\n/**\n * Reports whether a server property patch may cross the operation boundary.\n * Structural HTML/text setters, inline event handlers, iframe documents, and\n * JavaScript prototype controls require dedicated framework-owned operations.\n */\nexport function isSafeDomPatchProperty(name: string): boolean {\n\tconst normalized = name.toLowerCase();\n\treturn (\n\t\t!!normalized && !normalized.startsWith('on') && !forbiddenDomPatchProperties.has(normalized)\n\t);\n}\n\nexport type { ExactCollectionMutation } from '../component-contracts.js';\n"]}
@@ -0,0 +1,4 @@
1
+ import type { AnyComponentInstance, Child } from '../component/contracts.js';
2
+ /** Projects one server render attempt without creating client subscriptions or effect scopes. */
3
+ export declare function createServerFragmentTargetProjection(supplied: Child | (() => Child), tag: string, owner?: AnyComponentInstance): (children: readonly Child[]) => Child[];
4
+ //# sourceMappingURL=server-fragment-target-projection.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"server-fragment-target-projection.d.ts","sourceRoot":"","sources":["../../../src/framework/server-fragment-target-projection.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,KAAK,EAAE,MAAM,2BAA2B,CAAC;AAI7E,iGAAiG;AACjG,wBAAgB,oCAAoC,CACnD,QAAQ,EAAE,KAAK,GAAG,CAAC,MAAM,KAAK,CAAC,EAC/B,GAAG,EAAE,MAAM,EACX,KAAK,CAAC,EAAE,oBAAoB,GAC1B,CAAC,QAAQ,EAAE,SAAS,KAAK,EAAE,KAAK,KAAK,EAAE,CAQzC"}
@@ -0,0 +1,7 @@
1
+ import { createPreparedServerChildRange } from '../component-abi/server-child-range.js';
2
+ import { createFragmentTargetProjectionWithRanges } from './fragment-target-projection-plan.js';
3
+ /** Projects one server render attempt without creating client subscriptions or effect scopes. */
4
+ export function createServerFragmentTargetProjection(supplied, tag, owner) {
5
+ return createFragmentTargetProjectionWithRanges(supplied, tag, owner, (read, markerId, mayReplaceSubtree) => createPreparedServerChildRange(read(), markerId, mayReplaceSubtree));
6
+ }
7
+ //# sourceMappingURL=server-fragment-target-projection.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"server-fragment-target-projection.js","sourceRoot":"","sources":["../../../src/framework/server-fragment-target-projection.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,8BAA8B,EAAE,MAAM,wCAAwC,CAAC;AACxF,OAAO,EAAE,wCAAwC,EAAE,MAAM,sCAAsC,CAAC;AAEhG,iGAAiG;AACjG,MAAM,UAAU,oCAAoC,CACnD,QAA+B,EAC/B,GAAW,EACX,KAA4B;IAE5B,OAAO,wCAAwC,CAC9C,QAAQ,EACR,GAAG,EACH,KAAK,EACL,CAAC,IAAI,EAAE,QAAQ,EAAE,iBAAiB,EAAE,EAAE,CACrC,8BAA8B,CAAC,IAAI,EAAE,EAAE,QAAQ,EAAE,iBAAiB,CAAC,CACpE,CAAC;AACH,CAAC","sourcesContent":["import type { AnyComponentInstance, Child } from '../component/contracts.js';\nimport { createPreparedServerChildRange } from '../component-abi/server-child-range.js';\nimport { createFragmentTargetProjectionWithRanges } from './fragment-target-projection-plan.js';\n\n/** Projects one server render attempt without creating client subscriptions or effect scopes. */\nexport function createServerFragmentTargetProjection(\n\tsupplied: Child | (() => Child),\n\ttag: string,\n\towner?: AnyComponentInstance\n): (children: readonly Child[]) => Child[] {\n\treturn createFragmentTargetProjectionWithRanges(\n\t\tsupplied,\n\t\ttag,\n\t\towner,\n\t\t(read, markerId, mayReplaceSubtree) =>\n\t\t\tcreatePreparedServerChildRange(read(), markerId, mayReplaceSubtree)\n\t);\n}\n"]}
@@ -16,4 +16,5 @@ export declare function createForwardedExpression<T>(compute: () => T): T;
16
16
  export declare function createDynamicChild(compute: () => RenderResult, markerId?: string, mayReplaceSubtree?: boolean): ExactPreparedServerChildRange;
17
17
  /** Creates the eager server operation for one compiler-owned dynamic child range. */
18
18
  export declare function createCompiledChildRangeReceipt(compute: () => RenderResult, markerId?: string, mayReplaceSubtree?: boolean): ExactPreparedServerChildRange;
19
+ export { createServerFragmentTargetProjection } from './server-fragment-target-projection.js';
19
20
  //# sourceMappingURL=server-render-structure.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"server-render-structure.d.ts","sourceRoot":"","sources":["../../../src/framework/server-render-structure.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAC9D,OAAO,EAEN,KAAK,6BAA6B,EAClC,MAAM,wCAAwC,CAAC;AAEhD,OAAO,EAAE,sBAAsB,EAAE,wBAAwB,EAAE,MAAM,0BAA0B,CAAC;AAC5F,OAAO,EAAE,2BAA2B,EAAE,4BAA4B,EAAE,MAAM,wBAAwB,CAAC;AACnG,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC1E,OAAO,EACN,2BAA2B,EAC3B,iCAAiC,EACjC,4BAA4B,EAC5B,+BAA+B,EAC/B,iBAAiB,EACjB,wBAAwB,EACxB,qBAAqB,EACrB,KAAK,kBAAkB,EACvB,KAAK,wBAAwB,EAC7B,KAAK,qBAAqB,EAC1B,KAAK,yBAAyB,EAC9B,KAAK,wBAAwB,EAC7B,KAAK,+BAA+B,EACpC,KAAK,4BAA4B,EACjC,KAAK,yBAAyB,EAC9B,KAAK,6BAA6B,EAClC,KAAK,gCAAgC,EACrC,KAAK,sBAAsB,EAC3B,KAAK,sBAAsB,EAC3B,KAAK,+BAA+B,EACpC,KAAK,2BAA2B,EAChC,KAAK,+BAA+B,EACpC,KAAK,2BAA2B,EAChC,KAAK,qBAAqB,EAC1B,KAAK,uBAAuB,EAC5B,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACN,sCAAsC,EACtC,oDAAoD,EACpD,oCAAoC,EACpC,KAAK,qCAAqC,EAC1C,MAAM,6BAA6B,CAAC;AACrC,OAAO,EACN,4BAA4B,EAC5B,KAAK,6BAA6B,EAClC,MAAM,wCAAwC,CAAC;AAChD,OAAO,EACN,8BAA8B,EAC9B,4BAA4B,EAC5B,KAAK,6BAA6B,EAClC,MAAM,wCAAwC,CAAC;AAChD,OAAO,EACN,qBAAqB,EACrB,oBAAoB,EACpB,gBAAgB,EAChB,MAAM,+CAA+C,CAAC;AAEvD,4FAA4F;AAC5F,wBAAgB,gBAAgB,CAAC,CAAC,EAAE,OAAO,EAAE,MAAM,CAAC,GAAG,CAAC,CAEvD;AAED,2FAA2F;AAC3F,wBAAgB,yBAAyB,CAAC,CAAC,EAAE,OAAO,EAAE,MAAM,CAAC,GAAG,CAAC,CAEhE;AAED,6FAA6F;AAC7F,wBAAgB,kBAAkB,CACjC,OAAO,EAAE,MAAM,YAAY,EAC3B,QAAQ,CAAC,EAAE,MAAM,EACjB,iBAAiB,UAAO,GACtB,6BAA6B,CAE/B;AAED,qFAAqF;AACrF,wBAAgB,+BAA+B,CAC9C,OAAO,EAAE,MAAM,YAAY,EAC3B,QAAQ,CAAC,EAAE,MAAM,EACjB,iBAAiB,UAAO,GACtB,6BAA6B,CAE/B"}
1
+ {"version":3,"file":"server-render-structure.d.ts","sourceRoot":"","sources":["../../../src/framework/server-render-structure.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,2BAA2B,CAAC;AAC9D,OAAO,EAEN,KAAK,6BAA6B,EAClC,MAAM,wCAAwC,CAAC;AAEhD,OAAO,EAAE,sBAAsB,EAAE,wBAAwB,EAAE,MAAM,0BAA0B,CAAC;AAC5F,OAAO,EAAE,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,OAAO,EAAE,MAAM,YAAY,EAC3B,QAAQ,CAAC,EAAE,MAAM,EACjB,iBAAiB,UAAO,GACtB,6BAA6B,CAE/B;AAED,qFAAqF;AACrF,wBAAgB,+BAA+B,CAC9C,OAAO,EAAE,MAAM,YAAY,EAC3B,QAAQ,CAAC,EAAE,MAAM,EACjB,iBAAiB,UAAO,GACtB,6BAA6B,CAE/B;AAED,OAAO,EAAE,oCAAoC,EAAE,MAAM,wCAAwC,CAAC"}
@@ -23,4 +23,5 @@ export function createDynamicChild(compute, markerId, mayReplaceSubtree = true)
23
23
  export function createCompiledChildRangeReceipt(compute, markerId, mayReplaceSubtree = true) {
24
24
  return createPreparedServerChildRange(compute(), markerId, mayReplaceSubtree);
25
25
  }
26
+ export { createServerFragmentTargetProjection } from './server-fragment-target-projection.js';
26
27
  //# sourceMappingURL=server-render-structure.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"server-render-structure.js","sourceRoot":"","sources":["../../../src/framework/server-render-structure.ts"],"names":[],"mappings":"AACA,OAAO,EACN,8BAA8B,EAE9B,MAAM,wCAAwC,CAAC;AAEhD,OAAO,EAAE,sBAAsB,EAAE,wBAAwB,EAAE,MAAM,0BAA0B,CAAC;AAC5F,OAAO,EAAE,2BAA2B,EAAE,4BAA4B,EAAE,MAAM,wBAAwB,CAAC;AACnG,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC1E,OAAO,EACN,2BAA2B,EAC3B,iCAAiC,EACjC,4BAA4B,EAC5B,+BAA+B,EAC/B,iBAAiB,EACjB,wBAAwB,EACxB,qBAAqB,EAmBrB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACN,sCAAsC,EACtC,oDAAoD,EACpD,oCAAoC,EAEpC,MAAM,6BAA6B,CAAC;AACrC,OAAO,EACN,4BAA4B,EAE5B,MAAM,wCAAwC,CAAC;AAChD,OAAO,EACN,8BAA8B,EAC9B,4BAA4B,EAE5B,MAAM,wCAAwC,CAAC;AAChD,OAAO,EACN,qBAAqB,EACrB,oBAAoB,EACpB,gBAAgB,EAChB,MAAM,+CAA+C,CAAC;AAEvD,4FAA4F;AAC5F,MAAM,UAAU,gBAAgB,CAAI,OAAgB;IACnD,OAAO,OAAO,EAAE,CAAC;AAClB,CAAC;AAED,2FAA2F;AAC3F,MAAM,UAAU,yBAAyB,CAAI,OAAgB;IAC5D,OAAO,OAAO,EAAE,CAAC;AAClB,CAAC;AAED,6FAA6F;AAC7F,MAAM,UAAU,kBAAkB,CACjC,OAA2B,EAC3B,QAAiB,EACjB,iBAAiB,GAAG,IAAI;IAExB,OAAO,8BAA8B,CAAC,OAAO,EAAE,EAAE,QAAQ,EAAE,iBAAiB,CAAC,CAAC;AAC/E,CAAC;AAED,qFAAqF;AACrF,MAAM,UAAU,+BAA+B,CAC9C,OAA2B,EAC3B,QAAiB,EACjB,iBAAiB,GAAG,IAAI;IAExB,OAAO,8BAA8B,CAAC,OAAO,EAAE,EAAE,QAAQ,EAAE,iBAAiB,CAAC,CAAC;AAC/E,CAAC","sourcesContent":["import type { RenderResult } from '../component/contracts.js';\nimport {\n\tcreatePreparedServerChildRange,\n\ttype ExactPreparedServerChildRange\n} from '../component-abi/server-child-range.js';\n\nexport { isFiniteClientBoundary, markFiniteClientBoundary } from '../hydration-boundary.js';\nexport { hasIndependentAsyncSiblings, markIndependentAsyncSiblings } from '../ssr-independence.js';\nexport { RenderProgram, ServerBoundary, ServerSlot } from '../symbols.js';\nexport {\n\tcreatePreparedRenderProgram,\n\tcreatePreparedServerRenderProgram,\n\tprepareCompiledRenderProgram,\n\treadPreparedServerRenderProgram,\n\treadRenderProgram,\n\treadRenderProgramReceipt,\n\treadRenderProgramSlot,\n\ttype ExactRenderProgram,\n\ttype ExactDirectRenderProgram,\n\ttype ExactDomRenderProgram,\n\ttype ExactRenderProgramBinding,\n\ttype ExactRenderProgramBinder,\n\ttype ExactRenderProgramBindingTarget,\n\ttype ExactRenderProgramInvocation,\n\ttype ExactRenderProgramReceipt,\n\ttype ExactRenderProgramReceiptData,\n\ttype ExactPreparedServerRenderProgram,\n\ttype ExactRenderProgramNode,\n\ttype ExactRenderProgramSlot,\n\ttype ExactRenderProgramSsrOperations,\n\ttype ExactRenderProgramSsrOutput,\n\ttype ExactRenderProgramSsrInvocation,\n\ttype ExactRenderProgramSsrWriter,\n\ttype ExactSsrRenderProgram,\n\ttype ExactTableRenderProgram\n} from '../render-program.js';\nexport {\n\tcreatePreparedServerComponentReference,\n\tcreatePreparedServerComponentReferenceFromPlainProps,\n\treadPreparedServerComponentReference,\n\ttype ExactPreparedServerComponentReference\n} from '../component-abi/receipt.js';\nexport {\n\treadPreparedServerChildRange,\n\ttype ExactPreparedServerChildRange\n} from '../component-abi/server-child-range.js';\nexport {\n\tcreatePreparedServerKeyedChild,\n\treadPreparedServerKeyedChild,\n\ttype ExactPreparedServerKeyedChild\n} from '../component-abi/server-keyed-child.js';\nexport {\n\tcreateKeyedServerSlot,\n\tcreateServerBoundary,\n\tcreateServerSlot\n} from '../component-abi/server-structure-receipts.js';\n\n/** Evaluates a compiler-known expression directly in a compiler-closed server component. */\nexport function createExpression<T>(compute: () => T): T {\n\treturn compute();\n}\n\n/** Evaluates a compiler-forwarded input directly in a compiler-closed server component. */\nexport function createForwardedExpression<T>(compute: () => T): T {\n\treturn compute();\n}\n\n/** Creates an eager focused child range for a direct server render or its local fallback. */\nexport function createDynamicChild(\n\tcompute: () => RenderResult,\n\tmarkerId?: string,\n\tmayReplaceSubtree = true\n): ExactPreparedServerChildRange {\n\treturn createPreparedServerChildRange(compute(), markerId, mayReplaceSubtree);\n}\n\n/** Creates the eager server operation for one compiler-owned dynamic child range. */\nexport function createCompiledChildRangeReceipt(\n\tcompute: () => RenderResult,\n\tmarkerId?: string,\n\tmayReplaceSubtree = true\n): ExactPreparedServerChildRange {\n\treturn createPreparedServerChildRange(compute(), markerId, mayReplaceSubtree);\n}\n"]}
1
+ {"version":3,"file":"server-render-structure.js","sourceRoot":"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CAAC,OAAO,EAAE,EAAE,QAAQ,EAAE,iBAAiB,CAAC,CAAC;AAC/E,CAAC;AAED,OAAO,EAAE,oCAAoC,EAAE,MAAM,wCAAwC,CAAC","sourcesContent":["import type { RenderResult } from '../component/contracts.js';\nimport {\n\tcreatePreparedServerChildRange,\n\ttype ExactPreparedServerChildRange\n} from '../component-abi/server-child-range.js';\n\nexport { isFiniteClientBoundary, markFiniteClientBoundary } from '../hydration-boundary.js';\nexport { hasIndependentAsyncSiblings, markIndependentAsyncSiblings } from '../ssr-independence.js';\nexport { RenderProgram, ServerBoundary, ServerSlot } from '../symbols.js';\nexport {\n\tcreatePreparedRenderProgram,\n\tcreatePreparedServerRenderProgram,\n\tprepareCompiledRenderProgram,\n\treadPreparedServerRenderProgram,\n\treadRenderProgram,\n\treadRenderProgramReceipt,\n\treadRenderProgramSlot,\n\ttype ExactRenderProgram,\n\ttype ExactDirectRenderProgram,\n\ttype ExactDomRenderProgram,\n\ttype ExactRenderProgramBinding,\n\ttype ExactRenderProgramBinder,\n\ttype ExactRenderProgramBindingTarget,\n\ttype ExactRenderProgramInvocation,\n\ttype ExactRenderProgramReceipt,\n\ttype ExactRenderProgramReceiptData,\n\ttype ExactPreparedServerRenderProgram,\n\ttype ExactRenderProgramNode,\n\ttype ExactRenderProgramSlot,\n\ttype ExactRenderProgramSsrOperations,\n\ttype ExactRenderProgramSsrOutput,\n\ttype ExactRenderProgramSsrInvocation,\n\ttype ExactRenderProgramSsrWriter,\n\ttype ExactSsrRenderProgram,\n\ttype ExactTableRenderProgram\n} from '../render-program.js';\nexport {\n\tcreatePreparedServerComponentReference,\n\tcreatePreparedServerComponentReferenceFromPlainProps,\n\treadPreparedServerComponentReference,\n\ttype ExactPreparedServerComponentReference\n} from '../component-abi/receipt.js';\nexport {\n\treadPreparedServerChildRange,\n\ttype ExactPreparedServerChildRange\n} from '../component-abi/server-child-range.js';\nexport {\n\tcreatePreparedServerKeyedChild,\n\treadPreparedServerKeyedChild,\n\ttype ExactPreparedServerKeyedChild\n} from '../component-abi/server-keyed-child.js';\nexport {\n\tcreateKeyedServerSlot,\n\tcreateServerBoundary,\n\tcreateServerSlot\n} from '../component-abi/server-structure-receipts.js';\n\n/** Evaluates a compiler-known expression directly in a compiler-closed server component. */\nexport function createExpression<T>(compute: () => T): T {\n\treturn compute();\n}\n\n/** Evaluates a compiler-forwarded input directly in a compiler-closed server component. */\nexport function createForwardedExpression<T>(compute: () => T): T {\n\treturn compute();\n}\n\n/** Creates an eager focused child range for a direct server render or its local fallback. */\nexport function createDynamicChild(\n\tcompute: () => RenderResult,\n\tmarkerId?: string,\n\tmayReplaceSubtree = true\n): ExactPreparedServerChildRange {\n\treturn createPreparedServerChildRange(compute(), markerId, mayReplaceSubtree);\n}\n\n/** Creates the eager server operation for one compiler-owned dynamic child range. */\nexport function createCompiledChildRangeReceipt(\n\tcompute: () => RenderResult,\n\tmarkerId?: string,\n\tmayReplaceSubtree = true\n): ExactPreparedServerChildRange {\n\treturn createPreparedServerChildRange(compute(), markerId, mayReplaceSubtree);\n}\n\nexport { createServerFragmentTargetProjection } from './server-fragment-target-projection.js';\n"]}
@@ -10,4 +10,5 @@ export { bindTaskForHost, defineTask, invokeTask } from '../tasks/runtime.js';
10
10
  export { activateServerComponentTaskTreeForHost } from '../tasks/server-component-task-tree.js';
11
11
  export { mutateTaskCollection, ownTaskResource, stageTaskMutation, taskAnimationFrame, taskAwait, taskFetch, taskIdleCallback, taskInterval, taskObserver, taskTimeout } from '../tasks/resources.js';
12
12
  export { combineTaskSignal, withAbortSignal, withTaskSignal } from '../tasks/signals.js';
13
+ export { createTaskProgressReporter, registerTaskProgressReceiver } from '../tasks/progress-bindings.js';
13
14
  //# sourceMappingURL=server-task-helpers.d.ts.map