@wireweave/core 4.0.0-beta.13 → 4.0.0-beta.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/app.cjs CHANGED
@@ -1,50 +1,51 @@
1
1
  'use strict';
2
2
 
3
- var chunk4UZBGIGJ_cjs = require('./chunk-4UZBGIGJ.cjs');
3
+ var chunkXODYFTKU_cjs = require('./chunk-XODYFTKU.cjs');
4
+ var chunkVCHXMPZL_cjs = require('./chunk-VCHXMPZL.cjs');
4
5
 
5
6
 
6
7
 
7
8
  Object.defineProperty(exports, "advanceClock", {
8
9
  enumerable: true,
9
- get: function () { return chunk4UZBGIGJ_cjs.advanceClock; }
10
+ get: function () { return chunkXODYFTKU_cjs.advanceClock; }
10
11
  });
11
12
  Object.defineProperty(exports, "compileApp", {
12
13
  enumerable: true,
13
- get: function () { return chunk4UZBGIGJ_cjs.compileApp; }
14
- });
15
- Object.defineProperty(exports, "createAppBundle", {
16
- enumerable: true,
17
- get: function () { return chunk4UZBGIGJ_cjs.createAppBundle; }
14
+ get: function () { return chunkXODYFTKU_cjs.compileApp; }
18
15
  });
19
16
  Object.defineProperty(exports, "createAppComponentInstanceId", {
20
17
  enumerable: true,
21
- get: function () { return chunk4UZBGIGJ_cjs.createAppComponentInstanceId; }
18
+ get: function () { return chunkXODYFTKU_cjs.createAppComponentInstanceId; }
22
19
  });
23
20
  Object.defineProperty(exports, "createAppNodeId", {
24
21
  enumerable: true,
25
- get: function () { return chunk4UZBGIGJ_cjs.createAppNodeId; }
22
+ get: function () { return chunkXODYFTKU_cjs.createAppNodeId; }
26
23
  });
27
24
  Object.defineProperty(exports, "createRuntime", {
28
25
  enumerable: true,
29
- get: function () { return chunk4UZBGIGJ_cjs.createRuntime; }
26
+ get: function () { return chunkXODYFTKU_cjs.createRuntime; }
30
27
  });
31
28
  Object.defineProperty(exports, "linkAndCompileApp", {
32
29
  enumerable: true,
33
- get: function () { return chunk4UZBGIGJ_cjs.linkAndCompileApp; }
30
+ get: function () { return chunkXODYFTKU_cjs.linkAndCompileApp; }
34
31
  });
35
32
  Object.defineProperty(exports, "linkApp", {
36
33
  enumerable: true,
37
- get: function () { return chunk4UZBGIGJ_cjs.linkApp; }
34
+ get: function () { return chunkXODYFTKU_cjs.linkApp; }
38
35
  });
39
36
  Object.defineProperty(exports, "reduceEvent", {
40
37
  enumerable: true,
41
- get: function () { return chunk4UZBGIGJ_cjs.reduceEvent; }
38
+ get: function () { return chunkXODYFTKU_cjs.reduceEvent; }
42
39
  });
43
40
  Object.defineProperty(exports, "renderSite", {
44
41
  enumerable: true,
45
- get: function () { return chunk4UZBGIGJ_cjs.renderSite; }
42
+ get: function () { return chunkXODYFTKU_cjs.renderSite; }
46
43
  });
47
44
  Object.defineProperty(exports, "resetRuntime", {
48
45
  enumerable: true,
49
- get: function () { return chunk4UZBGIGJ_cjs.resetRuntime; }
46
+ get: function () { return chunkXODYFTKU_cjs.resetRuntime; }
47
+ });
48
+ Object.defineProperty(exports, "createAppBundle", {
49
+ enumerable: true,
50
+ get: function () { return chunkVCHXMPZL_cjs.createAppBundle; }
50
51
  });
package/dist/app.d.cts CHANGED
@@ -1,6 +1,7 @@
1
1
  import { S as SourceLocation, L as LayoutDefinitionNode, i as ComponentDefinitionNode, P as PageNode } from './types-CGRi1k2N.cjs';
2
- import { J as JsonObject, V as V4SourceSpan, P as ParsedDocument, c as CanonicalModule, k as JsonValue } from './v4-types-2ORUg6To.cjs';
3
- import { e as SiteOptions } from './index-DyXaMSgd.cjs';
2
+ import { o as AppBundle, A as AppResult, b as LinkedApp, i as SiteOptions, L as LinkedIdentity, a as ScreenReference, n as AppArtifact } from './index-DdQv4Bu5.cjs';
3
+ export { p as CreateAppBundleOptions, D as Diagnostic, I as InstanceStep, S as SourceMapEntry, q as createAppBundle } from './index-DdQv4Bu5.cjs';
4
+ import { k as JsonValue, J as JsonObject } from './v4-types-2ORUg6To.cjs';
4
5
 
5
6
  /** A source file and exact span within it. */
6
7
  interface AppSourceSpan {
@@ -138,147 +139,6 @@ type AppLinkResult = {
138
139
  diagnostics: readonly AppLinkDiagnostic[];
139
140
  };
140
141
 
141
- interface Diagnostic {
142
- severity: 'error';
143
- code: string;
144
- phase: 'schema' | 'import' | 'link' | 'compile';
145
- sourceId: string;
146
- start: number;
147
- end: number;
148
- path: string;
149
- messageKey: string;
150
- details: JsonObject;
151
- related: {
152
- sourceId: string;
153
- start: number;
154
- end: number;
155
- }[];
156
- }
157
- type AppResult<T> = {
158
- ok: true;
159
- value: T;
160
- diagnostics: readonly [];
161
- } | {
162
- ok: false;
163
- value: null;
164
- html: null;
165
- diagnostics: readonly Diagnostic[];
166
- };
167
- interface ScreenReference {
168
- namespace: string;
169
- id: string;
170
- variant?: string;
171
- }
172
- interface CreateAppBundleOptions {
173
- id: string;
174
- entry: ScreenReference;
175
- profile: JsonObject;
176
- states: JsonObject[];
177
- registry: ParsedDocument['registry'];
178
- fixtures: JsonObject[];
179
- /** Exact original module bytes. Source maps address these bytes as moduleId.wf. */
180
- moduleSources: Readonly<Record<string, string>>;
181
- }
182
- declare const bundleBrand: unique symbol;
183
- declare const linkedBrand: unique symbol;
184
- interface AppBundle {
185
- readonly [bundleBrand]: true;
186
- readonly schemaVersion: '1.0.0';
187
- readonly languageVersion: '4.0.0';
188
- readonly id: string;
189
- readonly entry: Readonly<ScreenReference>;
190
- readonly profile: Readonly<JsonObject>;
191
- readonly states: readonly JsonObject[];
192
- readonly registry: Readonly<ParsedDocument['registry']>;
193
- readonly fixtures: readonly JsonObject[];
194
- readonly modules: readonly CanonicalModule[];
195
- }
196
- type InstanceStep = {
197
- kind: 'use';
198
- id: string;
199
- } | {
200
- kind: 'repeat';
201
- id: string;
202
- index: number;
203
- };
204
- interface LinkedIdentity {
205
- namespace: string;
206
- definitionKind: 'page' | 'layout' | 'component';
207
- definitionId: string;
208
- instanceRoot: {
209
- kind: 'screen';
210
- namespace: string;
211
- id: string;
212
- } | {
213
- kind: 'shell';
214
- namespace: string;
215
- id: string;
216
- profileDigest: string;
217
- };
218
- instancePath: InstanceStep[];
219
- localId: string;
220
- }
221
- interface SourceMapEntry {
222
- renderedId: string;
223
- identity: LinkedIdentity;
224
- moduleId: string;
225
- source: Readonly<V4SourceSpan>;
226
- invocationSources: readonly Readonly<V4SourceSpan>[];
227
- requirementRefs: readonly string[];
228
- obligationRefs: readonly string[];
229
- operationIds: readonly string[];
230
- }
231
- interface LinkedApp {
232
- readonly [linkedBrand]: true;
233
- readonly kind: 'LinkedApp';
234
- readonly languageVersion: '4.0.0';
235
- readonly id: string;
236
- readonly digest: string;
237
- readonly sourceMap: readonly SourceMapEntry[];
238
- }
239
- interface AppArtifact {
240
- readonly kind: 'AppArtifact';
241
- readonly schemaVersion: '1.0.0';
242
- readonly languageVersion: '4.0.0';
243
- readonly html: string;
244
- readonly mediaType: 'text/html';
245
- readonly byteLength: number;
246
- readonly digest: string;
247
- readonly modelDigest: string;
248
- readonly profileDigest: string;
249
- readonly runtimeDigest: string;
250
- readonly registryDigest: string;
251
- readonly entry: Readonly<ScreenReference>;
252
- readonly screenIndex: readonly {
253
- route: ScreenReference;
254
- renderedId: string;
255
- }[];
256
- readonly operationIndex: readonly {
257
- renderedId: string;
258
- handlerId: string;
259
- operationId: string;
260
- executionClass: string;
261
- operation: JsonObject;
262
- }[];
263
- readonly diagnostics: readonly [];
264
- readonly sourceMap: readonly SourceMapEntry[];
265
- readonly manifest: {
266
- readonly appId: string;
267
- readonly modelDigest: string;
268
- readonly profileDigest: string;
269
- readonly registryDigest: string;
270
- readonly htmlDigest: string;
271
- readonly runtimeDigest: string;
272
- readonly executionScope: 'standard-1';
273
- readonly unsupportedOperations: readonly {
274
- renderedId: string;
275
- handlerId: string;
276
- operationId: string;
277
- }[];
278
- };
279
- }
280
- declare function createAppBundle(documents: readonly ParsedDocument[], options: CreateAppBundleOptions): AppResult<AppBundle>;
281
-
282
142
  /**
283
143
  * Create the stable identity used by linked documents and source maps.
284
144
  * Each segment is encoded so punctuation in authored identifiers cannot collide.
@@ -485,4 +345,4 @@ declare function advanceClock(snapshot: RuntimeSnapshot, deltaMs: number): Runti
485
345
  declare function resetRuntime(snapshot: RuntimeSnapshot): RuntimeSnapshot;
486
346
  declare function renderSite(bundle: AppBundle): AppResult<AppArtifact>;
487
347
 
488
- export { type AppArtifact, type AppBundle, type AppCompileResult, type AppComponentInput, type AppComponentInstanceId, type AppDefinitionKind, type AppDocument, type AppLayoutInput, type AppLinkDiagnostic, type AppLinkDiagnosticCode, type AppLinkResult, type AppManifest, type AppManifestModule, type AppModuleInput, type AppNodeId, type AppNodeKind, type AppReferenceInput, type AppResult, type AppScreenInput, type AppSourceMapEntry, type AppSourceSpan, type CompileAppOptions, type CreateAppBundleOptions, type Diagnostic, type InstanceStep, type LinkedApp, type LinkedIdentity, type ResolvedAppComponent, type ResolvedAppLayout, type ResolvedAppModule, type ResolvedAppReference, type ResolvedAppScreen, type RuntimeBrowserEffect, type RuntimeInput, type RuntimeSnapshot, type RuntimeTrace, type ScreenReference, type SourceMapEntry, advanceClock, compileApp, createAppBundle, createAppComponentInstanceId, createAppNodeId, createRuntime, linkAndCompileApp, linkApp, reduceEvent, renderSite, resetRuntime };
348
+ export { AppArtifact, AppBundle, type AppCompileResult, type AppComponentInput, type AppComponentInstanceId, type AppDefinitionKind, type AppDocument, type AppLayoutInput, type AppLinkDiagnostic, type AppLinkDiagnosticCode, type AppLinkResult, type AppManifest, type AppManifestModule, type AppModuleInput, type AppNodeId, type AppNodeKind, type AppReferenceInput, AppResult, type AppScreenInput, type AppSourceMapEntry, type AppSourceSpan, type CompileAppOptions, LinkedApp, LinkedIdentity, type ResolvedAppComponent, type ResolvedAppLayout, type ResolvedAppModule, type ResolvedAppReference, type ResolvedAppScreen, type RuntimeBrowserEffect, type RuntimeInput, type RuntimeSnapshot, type RuntimeTrace, ScreenReference, advanceClock, compileApp, createAppComponentInstanceId, createAppNodeId, createRuntime, linkAndCompileApp, linkApp, reduceEvent, renderSite, resetRuntime };
package/dist/app.d.ts CHANGED
@@ -1,6 +1,7 @@
1
1
  import { S as SourceLocation, L as LayoutDefinitionNode, i as ComponentDefinitionNode, P as PageNode } from './types-CGRi1k2N.js';
2
- import { J as JsonObject, V as V4SourceSpan, P as ParsedDocument, c as CanonicalModule, k as JsonValue } from './v4-types-2ORUg6To.js';
3
- import { e as SiteOptions } from './index-BGU_4N4W.js';
2
+ import { o as AppBundle, A as AppResult, b as LinkedApp, i as SiteOptions, L as LinkedIdentity, a as ScreenReference, n as AppArtifact } from './index-c4FTW7XA.js';
3
+ export { p as CreateAppBundleOptions, D as Diagnostic, I as InstanceStep, S as SourceMapEntry, q as createAppBundle } from './index-c4FTW7XA.js';
4
+ import { k as JsonValue, J as JsonObject } from './v4-types-2ORUg6To.js';
4
5
 
5
6
  /** A source file and exact span within it. */
6
7
  interface AppSourceSpan {
@@ -138,147 +139,6 @@ type AppLinkResult = {
138
139
  diagnostics: readonly AppLinkDiagnostic[];
139
140
  };
140
141
 
141
- interface Diagnostic {
142
- severity: 'error';
143
- code: string;
144
- phase: 'schema' | 'import' | 'link' | 'compile';
145
- sourceId: string;
146
- start: number;
147
- end: number;
148
- path: string;
149
- messageKey: string;
150
- details: JsonObject;
151
- related: {
152
- sourceId: string;
153
- start: number;
154
- end: number;
155
- }[];
156
- }
157
- type AppResult<T> = {
158
- ok: true;
159
- value: T;
160
- diagnostics: readonly [];
161
- } | {
162
- ok: false;
163
- value: null;
164
- html: null;
165
- diagnostics: readonly Diagnostic[];
166
- };
167
- interface ScreenReference {
168
- namespace: string;
169
- id: string;
170
- variant?: string;
171
- }
172
- interface CreateAppBundleOptions {
173
- id: string;
174
- entry: ScreenReference;
175
- profile: JsonObject;
176
- states: JsonObject[];
177
- registry: ParsedDocument['registry'];
178
- fixtures: JsonObject[];
179
- /** Exact original module bytes. Source maps address these bytes as moduleId.wf. */
180
- moduleSources: Readonly<Record<string, string>>;
181
- }
182
- declare const bundleBrand: unique symbol;
183
- declare const linkedBrand: unique symbol;
184
- interface AppBundle {
185
- readonly [bundleBrand]: true;
186
- readonly schemaVersion: '1.0.0';
187
- readonly languageVersion: '4.0.0';
188
- readonly id: string;
189
- readonly entry: Readonly<ScreenReference>;
190
- readonly profile: Readonly<JsonObject>;
191
- readonly states: readonly JsonObject[];
192
- readonly registry: Readonly<ParsedDocument['registry']>;
193
- readonly fixtures: readonly JsonObject[];
194
- readonly modules: readonly CanonicalModule[];
195
- }
196
- type InstanceStep = {
197
- kind: 'use';
198
- id: string;
199
- } | {
200
- kind: 'repeat';
201
- id: string;
202
- index: number;
203
- };
204
- interface LinkedIdentity {
205
- namespace: string;
206
- definitionKind: 'page' | 'layout' | 'component';
207
- definitionId: string;
208
- instanceRoot: {
209
- kind: 'screen';
210
- namespace: string;
211
- id: string;
212
- } | {
213
- kind: 'shell';
214
- namespace: string;
215
- id: string;
216
- profileDigest: string;
217
- };
218
- instancePath: InstanceStep[];
219
- localId: string;
220
- }
221
- interface SourceMapEntry {
222
- renderedId: string;
223
- identity: LinkedIdentity;
224
- moduleId: string;
225
- source: Readonly<V4SourceSpan>;
226
- invocationSources: readonly Readonly<V4SourceSpan>[];
227
- requirementRefs: readonly string[];
228
- obligationRefs: readonly string[];
229
- operationIds: readonly string[];
230
- }
231
- interface LinkedApp {
232
- readonly [linkedBrand]: true;
233
- readonly kind: 'LinkedApp';
234
- readonly languageVersion: '4.0.0';
235
- readonly id: string;
236
- readonly digest: string;
237
- readonly sourceMap: readonly SourceMapEntry[];
238
- }
239
- interface AppArtifact {
240
- readonly kind: 'AppArtifact';
241
- readonly schemaVersion: '1.0.0';
242
- readonly languageVersion: '4.0.0';
243
- readonly html: string;
244
- readonly mediaType: 'text/html';
245
- readonly byteLength: number;
246
- readonly digest: string;
247
- readonly modelDigest: string;
248
- readonly profileDigest: string;
249
- readonly runtimeDigest: string;
250
- readonly registryDigest: string;
251
- readonly entry: Readonly<ScreenReference>;
252
- readonly screenIndex: readonly {
253
- route: ScreenReference;
254
- renderedId: string;
255
- }[];
256
- readonly operationIndex: readonly {
257
- renderedId: string;
258
- handlerId: string;
259
- operationId: string;
260
- executionClass: string;
261
- operation: JsonObject;
262
- }[];
263
- readonly diagnostics: readonly [];
264
- readonly sourceMap: readonly SourceMapEntry[];
265
- readonly manifest: {
266
- readonly appId: string;
267
- readonly modelDigest: string;
268
- readonly profileDigest: string;
269
- readonly registryDigest: string;
270
- readonly htmlDigest: string;
271
- readonly runtimeDigest: string;
272
- readonly executionScope: 'standard-1';
273
- readonly unsupportedOperations: readonly {
274
- renderedId: string;
275
- handlerId: string;
276
- operationId: string;
277
- }[];
278
- };
279
- }
280
- declare function createAppBundle(documents: readonly ParsedDocument[], options: CreateAppBundleOptions): AppResult<AppBundle>;
281
-
282
142
  /**
283
143
  * Create the stable identity used by linked documents and source maps.
284
144
  * Each segment is encoded so punctuation in authored identifiers cannot collide.
@@ -485,4 +345,4 @@ declare function advanceClock(snapshot: RuntimeSnapshot, deltaMs: number): Runti
485
345
  declare function resetRuntime(snapshot: RuntimeSnapshot): RuntimeSnapshot;
486
346
  declare function renderSite(bundle: AppBundle): AppResult<AppArtifact>;
487
347
 
488
- export { type AppArtifact, type AppBundle, type AppCompileResult, type AppComponentInput, type AppComponentInstanceId, type AppDefinitionKind, type AppDocument, type AppLayoutInput, type AppLinkDiagnostic, type AppLinkDiagnosticCode, type AppLinkResult, type AppManifest, type AppManifestModule, type AppModuleInput, type AppNodeId, type AppNodeKind, type AppReferenceInput, type AppResult, type AppScreenInput, type AppSourceMapEntry, type AppSourceSpan, type CompileAppOptions, type CreateAppBundleOptions, type Diagnostic, type InstanceStep, type LinkedApp, type LinkedIdentity, type ResolvedAppComponent, type ResolvedAppLayout, type ResolvedAppModule, type ResolvedAppReference, type ResolvedAppScreen, type RuntimeBrowserEffect, type RuntimeInput, type RuntimeSnapshot, type RuntimeTrace, type ScreenReference, type SourceMapEntry, advanceClock, compileApp, createAppBundle, createAppComponentInstanceId, createAppNodeId, createRuntime, linkAndCompileApp, linkApp, reduceEvent, renderSite, resetRuntime };
348
+ export { AppArtifact, AppBundle, type AppCompileResult, type AppComponentInput, type AppComponentInstanceId, type AppDefinitionKind, type AppDocument, type AppLayoutInput, type AppLinkDiagnostic, type AppLinkDiagnosticCode, type AppLinkResult, type AppManifest, type AppManifestModule, type AppModuleInput, type AppNodeId, type AppNodeKind, type AppReferenceInput, AppResult, type AppScreenInput, type AppSourceMapEntry, type AppSourceSpan, type CompileAppOptions, LinkedApp, LinkedIdentity, type ResolvedAppComponent, type ResolvedAppLayout, type ResolvedAppModule, type ResolvedAppReference, type ResolvedAppScreen, type RuntimeBrowserEffect, type RuntimeInput, type RuntimeSnapshot, type RuntimeTrace, ScreenReference, advanceClock, compileApp, createAppComponentInstanceId, createAppNodeId, createRuntime, linkAndCompileApp, linkApp, reduceEvent, renderSite, resetRuntime };
package/dist/app.js CHANGED
@@ -1 +1,2 @@
1
- export { advanceClock, compileApp, createAppBundle, createAppComponentInstanceId, createAppNodeId, createRuntime, linkAndCompileApp, linkApp, reduceEvent, renderSite, resetRuntime } from './chunk-FS6A6EJ4.js';
1
+ export { advanceClock, compileApp, createAppComponentInstanceId, createAppNodeId, createRuntime, linkAndCompileApp, linkApp, reduceEvent, renderSite, resetRuntime } from './chunk-NZGEUVB4.js';
2
+ export { createAppBundle } from './chunk-24W2GEKO.js';