@wireweave/core 4.0.0-beta.14 → 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 +13 -13
- package/dist/app.d.cts +2 -2
- package/dist/app.d.ts +2 -2
- package/dist/app.js +2 -2
- package/dist/{chunk-TQSOLTMZ.js → chunk-24W2GEKO.js} +250 -40
- package/dist/{chunk-IMUVIIJR.cjs → chunk-H2SWIUMU.cjs} +9 -3
- package/dist/{chunk-LA5LKIEL.cjs → chunk-KMZXXIM2.cjs} +16 -16
- package/dist/{chunk-4DDV6Z2X.js → chunk-NPDSIAWT.js} +2 -2
- package/dist/{chunk-2Y3GKARZ.js → chunk-NZGEUVB4.js} +74 -20
- package/dist/{chunk-3RWGG5EC.js → chunk-UGMDBW46.js} +9 -4
- package/dist/{chunk-NV6UV5ID.cjs → chunk-VCHXMPZL.cjs} +263 -52
- package/dist/{chunk-SAN6CJEE.cjs → chunk-XODYFTKU.cjs} +136 -82
- package/dist/{index-BD_4rXH-.d.cts → index-CIfur9e3.d.cts} +1 -1
- package/dist/{index-YSIzfhOd.d.cts → index-DdQv4Bu5.d.cts} +7 -1
- package/dist/{index-g9yV20xb.d.ts → index-DwGsnD0n.d.ts} +1 -1
- package/dist/{index-BEnsO2kE.d.ts → index-c4FTW7XA.d.ts} +7 -1
- package/dist/index.cjs +46 -46
- package/dist/index.d.cts +4 -4
- package/dist/index.d.ts +4 -4
- package/dist/index.js +7 -7
- package/dist/parser.cjs +9 -9
- package/dist/parser.js +1 -1
- package/dist/renderer.cjs +8 -8
- package/dist/renderer.d.cts +2 -2
- package/dist/renderer.d.ts +2 -2
- package/dist/renderer.js +2 -2
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
3
|
+
var chunkVCHXMPZL_cjs = require('./chunk-VCHXMPZL.cjs');
|
|
4
|
+
var chunkH2SWIUMU_cjs = require('./chunk-H2SWIUMU.cjs');
|
|
5
5
|
var chunkETV4XYOV_cjs = require('./chunk-ETV4XYOV.cjs');
|
|
6
6
|
|
|
7
7
|
// src/ast/component-parameters.ts
|
|
@@ -405,7 +405,7 @@ function expandNode(node, path, context) {
|
|
|
405
405
|
return clone;
|
|
406
406
|
}
|
|
407
407
|
function linkApp(input, modules) {
|
|
408
|
-
if (modules === void 0) return
|
|
408
|
+
if (modules === void 0) return chunkVCHXMPZL_cjs.linkAppV4(input);
|
|
409
409
|
return linkLegacyApp(input, modules);
|
|
410
410
|
}
|
|
411
411
|
function linkLegacyApp(manifest, modules) {
|
|
@@ -617,7 +617,7 @@ function compileApp(document2, options = {}) {
|
|
|
617
617
|
type: "Document",
|
|
618
618
|
children: [...document2.layouts.map(projectLayout), ...document2.screens.map(projectScreen)]
|
|
619
619
|
};
|
|
620
|
-
return
|
|
620
|
+
return chunkVCHXMPZL_cjs.renderSite(projected, { ...options, annotationStyle: "neutral" });
|
|
621
621
|
}
|
|
622
622
|
function linkAndCompileApp(input, modules, options = {}) {
|
|
623
623
|
if (modules === void 0) {
|
|
@@ -629,20 +629,20 @@ function linkAndCompileApp(input, modules, options = {}) {
|
|
|
629
629
|
return { ...linked, html: compileApp(linked.document, options) };
|
|
630
630
|
}
|
|
631
631
|
function escape(value) {
|
|
632
|
-
return
|
|
632
|
+
return chunkVCHXMPZL_cjs.textValue(value).replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'");
|
|
633
633
|
}
|
|
634
634
|
function attribute(name, value) {
|
|
635
635
|
return value === void 0 || value === false ? "" : ` ${name}="${escape(value === true ? "" : value)}"`;
|
|
636
636
|
}
|
|
637
637
|
function jsonBlock(value) {
|
|
638
|
-
return
|
|
638
|
+
return chunkVCHXMPZL_cjs.jcs(value).replace(/</g, "\\u003c");
|
|
639
639
|
}
|
|
640
640
|
function address(route) {
|
|
641
641
|
return `#wf/${encodeURIComponent(route.namespace)}/${encodeURIComponent(route.id)}${route.variant === void 0 ? "" : `?variant=${encodeURIComponent(route.variant)}`}`;
|
|
642
642
|
}
|
|
643
643
|
function hashBase64(value) {
|
|
644
644
|
var _a, _b;
|
|
645
|
-
const hex =
|
|
645
|
+
const hex = chunkH2SWIUMU_cjs.digestV4(value).slice(7), alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";
|
|
646
646
|
const bytes = Array.from(
|
|
647
647
|
{ length: 32 },
|
|
648
648
|
(_, index) => Number.parseInt(hex.slice(index * 2, index * 2 + 2), 16)
|
|
@@ -660,45 +660,47 @@ var HtmlArtifact = class {
|
|
|
660
660
|
chunkETV4XYOV_cjs.__publicField(this, "program", program);
|
|
661
661
|
chunkETV4XYOV_cjs.__publicField(this, "unsupported", []);
|
|
662
662
|
chunkETV4XYOV_cjs.__publicField(this, "rules", []);
|
|
663
|
+
chunkETV4XYOV_cjs.__publicField(this, "assets");
|
|
664
|
+
this.assets = chunkVCHXMPZL_cjs.validateAppAssets(data.bundle.profile).assets;
|
|
663
665
|
}
|
|
664
666
|
node(entry) {
|
|
665
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m;
|
|
667
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p;
|
|
666
668
|
const { node, renderedId } = entry;
|
|
667
669
|
const attrs = node.attributes;
|
|
668
|
-
const label = (_b = node.label) != null ? _b :
|
|
670
|
+
const label = (_b = node.label) != null ? _b : chunkVCHXMPZL_cjs.textValue((_a = attrs.label) != null ? _a : "");
|
|
669
671
|
const children = () => entry.children.map((child) => this.node(child)).join("");
|
|
670
|
-
let common = attribute("id", renderedId) + attribute("class", `wf-node wf-${node.kind} ${renderedId}`) + attribute("data-wf-kind", node.kind) + attribute("data-wf-source", entry.owner.module.id) + attribute("data-wf-identity",
|
|
672
|
+
let common = attribute("id", renderedId) + attribute("class", `wf-node wf-${node.kind} ${renderedId}`) + attribute("data-wf-kind", node.kind) + attribute("data-wf-source", entry.owner.module.id) + attribute("data-wf-identity", chunkVCHXMPZL_cjs.jcs(entry.identity)) + attribute(
|
|
671
673
|
"data-wf-requirements",
|
|
672
|
-
attrs.requirementRefs === void 0 ? void 0 :
|
|
674
|
+
attrs.requirementRefs === void 0 ? void 0 : chunkVCHXMPZL_cjs.jcs(attrs.requirementRefs)
|
|
673
675
|
) + attribute(
|
|
674
676
|
"data-wf-obligations",
|
|
675
|
-
attrs.obligationRefs === void 0 ? void 0 :
|
|
676
|
-
) + attribute("data-wf-on", attrs.on === void 0 ? void 0 :
|
|
677
|
+
attrs.obligationRefs === void 0 ? void 0 : chunkVCHXMPZL_cjs.jcs(attrs.obligationRefs)
|
|
678
|
+
) + attribute("data-wf-on", attrs.on === void 0 ? void 0 : chunkVCHXMPZL_cjs.jcs(attrs.on)) + attribute("data-wf-bind", attrs.bind === void 0 ? void 0 : chunkVCHXMPZL_cjs.jcs(attrs.bind)) + attribute("data-wf-data", attrs.data === void 0 ? void 0 : chunkVCHXMPZL_cjs.jcs(attrs.data)) + attribute("data-wf-columns", attrs.columns === void 0 ? void 0 : chunkVCHXMPZL_cjs.jcs(attrs.columns)) + attribute(
|
|
677
679
|
"data-wf-targets",
|
|
678
|
-
entry.effectTargets === void 0 ? void 0 :
|
|
680
|
+
entry.effectTargets === void 0 ? void 0 : chunkVCHXMPZL_cjs.jcs(entry.effectTargets)
|
|
679
681
|
) + attribute(
|
|
680
682
|
"data-wf-visible-when",
|
|
681
|
-
attrs.visibleWhen === void 0 ? void 0 :
|
|
683
|
+
attrs.visibleWhen === void 0 ? void 0 : chunkVCHXMPZL_cjs.jcs(attrs.visibleWhen)
|
|
682
684
|
) + attribute(
|
|
683
685
|
"data-wf-enabled-when",
|
|
684
|
-
attrs.enabledWhen === void 0 ? void 0 :
|
|
685
|
-
) + attribute("data-wf-when", attrs.when === void 0 ? void 0 :
|
|
686
|
+
attrs.enabledWhen === void 0 ? void 0 : chunkVCHXMPZL_cjs.jcs(attrs.enabledWhen)
|
|
687
|
+
) + attribute("data-wf-when", attrs.when === void 0 ? void 0 : chunkVCHXMPZL_cjs.jcs(attrs.when)) + attribute("data-wf-state-bindings", chunkVCHXMPZL_cjs.jcs(entry.stateBindings)) + attribute("data-wf-navigate", entry.route === void 0 ? void 0 : address(entry.route)) + attribute("aria-label", (_c = attrs["aria-label"]) != null ? _c : attrs.aria) + attribute("aria-busy", attrs.loading === true ? "true" : void 0) + attribute(
|
|
686
688
|
"data-wf-disabled",
|
|
687
689
|
attrs.disabled === true || attrs.loading === true ? true : void 0
|
|
688
690
|
) + attribute("data-wf-action", attrs.action);
|
|
689
|
-
for (const handler of
|
|
690
|
-
for (const operation of
|
|
691
|
+
for (const handler of chunkVCHXMPZL_cjs.asObjects(attrs.on))
|
|
692
|
+
for (const operation of chunkVCHXMPZL_cjs.asObjects(handler.operations)) {
|
|
691
693
|
if (operation.executionClass === "specified") {
|
|
692
694
|
this.unsupported.push({
|
|
693
695
|
renderedId,
|
|
694
|
-
handlerId:
|
|
695
|
-
operationId:
|
|
696
|
+
handlerId: chunkVCHXMPZL_cjs.textValue(handler.id),
|
|
697
|
+
operationId: chunkVCHXMPZL_cjs.textValue(operation.id)
|
|
696
698
|
});
|
|
697
699
|
}
|
|
698
700
|
}
|
|
699
701
|
if (entry.slot) return `<div${common} data-wf-slot="${escape(entry.owner.key)}"></div>`;
|
|
700
702
|
this.layout(entry);
|
|
701
|
-
const bound =
|
|
703
|
+
const bound = chunkVCHXMPZL_cjs.object(attrs.bind) ? entry.stateBindings[chunkVCHXMPZL_cjs.textValue(attrs.bind.state)] : void 0;
|
|
702
704
|
const value = (_d = bound == null ? void 0 : bound.initial) != null ? _d : attrs.value;
|
|
703
705
|
const disabled = attrs.disabled === true || attrs.loading === true;
|
|
704
706
|
const labelled = (control) => `<div class="wf-field" data-wf-field="${renderedId}">${label ? `<label for="${renderedId}">${escape(label)}</label>` : ""}${control}<span id="${renderedId}-error" role="alert" hidden></span></div>`;
|
|
@@ -715,7 +717,7 @@ var HtmlArtifact = class {
|
|
|
715
717
|
);
|
|
716
718
|
if (node.kind === "select")
|
|
717
719
|
return labelled(
|
|
718
|
-
`<select${common}${scalarAttrs}>${
|
|
720
|
+
`<select${common}${scalarAttrs}>${chunkVCHXMPZL_cjs.asObjects(attrs.options).map(
|
|
719
721
|
(option) => `<option${attribute("value", option.value)}${attribute("selected", value === option.value)}${attribute("disabled", option.disabled)}>${escape(option.label)}</option>`
|
|
720
722
|
).join("")}</select>`
|
|
721
723
|
);
|
|
@@ -736,12 +738,19 @@ var HtmlArtifact = class {
|
|
|
736
738
|
return `<h${rank}${common}>${escape(label)}</h${rank}>`;
|
|
737
739
|
}
|
|
738
740
|
if (node.kind === "divider") return `<hr${common}>`;
|
|
739
|
-
if (node.kind === "image")
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
741
|
+
if (node.kind === "image") {
|
|
742
|
+
const asset = typeof attrs.src === "string" ? this.assets.get(attrs.src) : void 0;
|
|
743
|
+
return asset === void 0 ? `<div${common} role="img"${attribute("aria-label", (_g = attrs.alt) != null ? _g : "Image placeholder")}></div>` : `<img${common}${attribute("src", `data:${asset.mediaType};base64,${asset.base64}`)}${attribute("alt", (_h = attrs.alt) != null ? _h : "")}>`;
|
|
744
|
+
}
|
|
745
|
+
if (node.kind === "avatar") {
|
|
746
|
+
const accessibleLabel = ((_j = (_i = attrs["aria-label"]) != null ? _i : attrs.aria) != null ? _j : label) || attrs.name || "Avatar";
|
|
747
|
+
const asset = typeof attrs.src === "string" ? this.assets.get(attrs.src) : void 0;
|
|
748
|
+
return asset === void 0 ? `<span${common}${attribute("role", "img")}${attrs["aria-label"] === void 0 && attrs.aria === void 0 ? attribute("aria-label", accessibleLabel) : ""}>${escape((_k = node.number) != null ? _k : label || attrs.name || "")}</span>` : `<span${common}${attribute("role", "img")}${attrs["aria-label"] === void 0 && attrs.aria === void 0 ? attribute("aria-label", accessibleLabel) : ""}><img${attribute("src", `data:${asset.mediaType};base64,${asset.base64}`)}${attribute("alt", accessibleLabel)}></span>`;
|
|
749
|
+
}
|
|
750
|
+
if (node.kind === "icon" || node.kind === "badge" || node.kind === "marker")
|
|
751
|
+
return `<span${common}>${escape((_l = node.number) != null ? _l : label || attrs.name || "")}</span>`;
|
|
743
752
|
if (node.kind === "progress")
|
|
744
|
-
return `<progress${common}${attribute("value", attrs.indeterminate === true ? void 0 : value != null ? value : 0)}${attribute("max", (
|
|
753
|
+
return `<progress${common}${attribute("value", attrs.indeterminate === true ? void 0 : value != null ? value : 0)}${attribute("max", (_m = attrs.max) != null ? _m : 100)}>${escape(label)}</progress>`;
|
|
745
754
|
if (node.kind === "alert" || node.kind === "toast" || node.kind === "spinner")
|
|
746
755
|
return `<p${common}${attribute("role", node.kind === "alert" ? "alert" : "status")}>${escape(label)}${attrs.dismissible === true ? `<button type="button" data-wf-event-owner="${renderedId}" aria-label="Dismiss ${escape(label)}">Dismiss</button>` : ""}</p>`;
|
|
747
756
|
if (node.kind === "accordion")
|
|
@@ -754,12 +763,12 @@ var HtmlArtifact = class {
|
|
|
754
763
|
return `<div${common}>${children()}<span id="${renderedId}-tooltip" role="tooltip" hidden>${escape(label)}</span></div>`;
|
|
755
764
|
if (node.kind === "table") {
|
|
756
765
|
const columns = Array.isArray(attrs.columns) ? attrs.columns : [];
|
|
757
|
-
let rows = (
|
|
758
|
-
if (
|
|
759
|
-
const initial = (
|
|
766
|
+
let rows = (_n = node.items) != null ? _n : [];
|
|
767
|
+
if (chunkVCHXMPZL_cjs.object(attrs.data)) {
|
|
768
|
+
const initial = (_o = entry.stateBindings[chunkVCHXMPZL_cjs.textValue(attrs.data.state)]) == null ? void 0 : _o.initial;
|
|
760
769
|
if (Array.isArray(initial))
|
|
761
770
|
rows = initial.map(
|
|
762
|
-
(record) => columns.map((column) =>
|
|
771
|
+
(record) => columns.map((column) => chunkVCHXMPZL_cjs.object(record) ? record[chunkVCHXMPZL_cjs.textValue(column)] : null)
|
|
763
772
|
);
|
|
764
773
|
}
|
|
765
774
|
return `<table${common}><thead><tr>${columns.map((column) => `<th scope="col">${escape(column)}</th>`).join("")}</tr></thead><tbody>${rows.map((row) => `<tr>${(Array.isArray(row) ? row : []).map((cell) => `<td>${escape(cell != null ? cell : "")}</td>`).join("")}</tr>`).join("")}</tbody></table>`;
|
|
@@ -777,7 +786,7 @@ var HtmlArtifact = class {
|
|
|
777
786
|
}
|
|
778
787
|
if (node.kind === "tab")
|
|
779
788
|
return `<section${common} role="tabpanel" aria-labelledby="${renderedId}-tab" tabindex="0">${children()}</section>`;
|
|
780
|
-
const tag = (
|
|
789
|
+
const tag = (_p = {
|
|
781
790
|
header: "header",
|
|
782
791
|
main: "main",
|
|
783
792
|
footer: "footer",
|
|
@@ -787,7 +796,7 @@ var HtmlArtifact = class {
|
|
|
787
796
|
section: "section",
|
|
788
797
|
page: "section",
|
|
789
798
|
"annotation-item": "section"
|
|
790
|
-
}[node.kind]) != null ?
|
|
799
|
+
}[node.kind]) != null ? _p : "div";
|
|
791
800
|
if (node.kind === "page") common += ' tabindex="-1"';
|
|
792
801
|
return `<${tag}${common}>${label ? `<span class="wf-label">${escape(label)}</span>` : ""}${children()}</${tag}>`;
|
|
793
802
|
}
|
|
@@ -797,9 +806,9 @@ var HtmlArtifact = class {
|
|
|
797
806
|
const length = (value, axis, spacing = false) => {
|
|
798
807
|
if (typeof value === "number")
|
|
799
808
|
return `${spacing && [0, 1, 2, 3, 4, 5, 6, 8, 10, 12, 16, 20].includes(value) ? value * 4 : value}px`;
|
|
800
|
-
if (
|
|
809
|
+
if (chunkVCHXMPZL_cjs.object(value)) {
|
|
801
810
|
const amount = Number(value.value);
|
|
802
|
-
return value.unit === "vh" ? `${amount * Number(profile.height) / 100}px` : value.unit === "vw" ? `${amount * Number(profile.width) / 100}px` : value.unit === "rem" ? `${amount * 16}px` : `${amount}${
|
|
811
|
+
return value.unit === "vh" ? `${amount * Number(profile.height) / 100}px` : value.unit === "vw" ? `${amount * Number(profile.width) / 100}px` : value.unit === "rem" ? `${amount * 16}px` : `${amount}${chunkVCHXMPZL_cjs.textValue(value.unit)}`;
|
|
803
812
|
}
|
|
804
813
|
return value === "full" ? "100%" : value === "screen" ? `${Number(profile[axis])}px` : value === "fit" ? "fit-content" : "auto";
|
|
805
814
|
};
|
|
@@ -836,10 +845,10 @@ var HtmlArtifact = class {
|
|
|
836
845
|
if (["row", "col", "stack"].includes(kind)) {
|
|
837
846
|
styles.push(
|
|
838
847
|
"display:flex",
|
|
839
|
-
`flex-direction:${
|
|
848
|
+
`flex-direction:${chunkVCHXMPZL_cjs.textValue((_a = a.direction) != null ? _a : kind === "row" ? "row" : "column")}`,
|
|
840
849
|
`flex-wrap:${a.wrap === true ? "wrap" : "nowrap"}`,
|
|
841
|
-
`justify-content:${(_c = { start: "flex-start", end: "flex-end", between: "space-between", around: "space-around", evenly: "space-evenly" }[
|
|
842
|
-
`align-items:${(_e = { start: "flex-start", end: "flex-end" }[
|
|
850
|
+
`justify-content:${(_c = { start: "flex-start", end: "flex-end", between: "space-between", around: "space-around", evenly: "space-evenly" }[chunkVCHXMPZL_cjs.textValue(a.justify)]) != null ? _c : chunkVCHXMPZL_cjs.textValue((_b = a.justify) != null ? _b : "flex-start")}`,
|
|
851
|
+
`align-items:${(_e = { start: "flex-start", end: "flex-end" }[chunkVCHXMPZL_cjs.textValue(a.align)]) != null ? _e : chunkVCHXMPZL_cjs.textValue((_d = a.align) != null ? _d : "stretch")}`
|
|
843
852
|
);
|
|
844
853
|
}
|
|
845
854
|
if (a.flex !== void 0)
|
|
@@ -857,7 +866,7 @@ var HtmlArtifact = class {
|
|
|
857
866
|
if (a.order !== void 0) styles.push(`order:${Number(a.order)}`);
|
|
858
867
|
if (a.scroll === true) styles.push("overflow:auto");
|
|
859
868
|
if (kind !== "page" && (a.x !== void 0 || a.y !== void 0 || a.anchor !== void 0)) {
|
|
860
|
-
const anchor =
|
|
869
|
+
const anchor = chunkVCHXMPZL_cjs.textValue((_i = a.anchor) != null ? _i : "top-left"), vertical = anchor === "center" ? "center" : anchor.split("-")[0], horizontal = anchor === "center" ? "center" : anchor.split("-")[1];
|
|
861
870
|
styles.push(
|
|
862
871
|
"position:absolute",
|
|
863
872
|
`left:calc(${horizontal === "center" ? "50%" : horizontal === "right" ? "100%" : "0%"} + ${Number((_j = a.x) != null ? _j : 0)}px)`,
|
|
@@ -875,11 +884,11 @@ var HtmlArtifact = class {
|
|
|
875
884
|
styles.push("background:#f4f4f5");
|
|
876
885
|
if (a.shadow !== void 0 && a.shadow !== "none")
|
|
877
886
|
styles.push(
|
|
878
|
-
`box-shadow:0 ${{ sm: 1, md: 2, lg: 4, xl: 8 }[
|
|
887
|
+
`box-shadow:0 ${{ sm: 1, md: 2, lg: 4, xl: 8 }[chunkVCHXMPZL_cjs.textValue(a.shadow)]}px ${{ sm: 1, md: 2, lg: 4, xl: 8 }[chunkVCHXMPZL_cjs.textValue(a.shadow)]}px #71717a`
|
|
879
888
|
);
|
|
880
889
|
if (a.bold === true || a.weight !== void 0)
|
|
881
890
|
styles.push(
|
|
882
|
-
`font-weight:${a.bold === true ? 700 : { normal: 400, medium: 500, semibold: 600, bold: 700 }[
|
|
891
|
+
`font-weight:${a.bold === true ? 700 : { normal: 400, medium: 500, semibold: 600, bold: 700 }[chunkVCHXMPZL_cjs.textValue(a.weight)]}`
|
|
883
892
|
);
|
|
884
893
|
if (typeof a.size === "string") {
|
|
885
894
|
const font = { xs: 12, sm: 14, base: 16, md: 16, lg: 18, xl: 20, "2xl": 24, "3xl": 30 }[a.size];
|
|
@@ -892,7 +901,7 @@ var HtmlArtifact = class {
|
|
|
892
901
|
);
|
|
893
902
|
} else if (typeof a.size === "number") styles.push(`width:${a.size}px`, `height:${a.size}px`);
|
|
894
903
|
if (["text", "title", "link"].includes(kind) && a.align !== void 0)
|
|
895
|
-
styles.push(`text-align:${
|
|
904
|
+
styles.push(`text-align:${chunkVCHXMPZL_cjs.textValue(a.align)}`);
|
|
896
905
|
if (styles.length) this.rules.push(`#wireweave-app .${entry.renderedId}{${styles.join(";")}}`);
|
|
897
906
|
}
|
|
898
907
|
html() {
|
|
@@ -909,7 +918,10 @@ var HtmlArtifact = class {
|
|
|
909
918
|
return `<section data-wf-requirement="${escape(entry.id)}"><h3>${escape(entry.title)}</h3><p>${escape((_b = (_a = entry.behavior) != null ? _a : entry.trigger) != null ? _b : "")}</p></section>`;
|
|
910
919
|
}
|
|
911
920
|
).join("");
|
|
912
|
-
const
|
|
921
|
+
const font = typeof bundle.profile.fontAssetId === "string" ? this.assets.get(bundle.profile.fontAssetId) : void 0;
|
|
922
|
+
const fontFace = font === void 0 ? "" : `@font-face{font-family:WireweaveProfile;src:url(data:${font.mediaType};base64,${font.base64}) format("woff2");font-display:swap}`;
|
|
923
|
+
const fontFamily = font === void 0 ? "system-ui,sans-serif" : "WireweaveProfile,system-ui,sans-serif";
|
|
924
|
+
const css = `${fontFace}#wireweave-app{font:16px/1.5 ${fontFamily};color:#18181b;background:white}#wireweave-app [hidden]{display:none!important}#wireweave-app *{box-sizing:border-box}#wireweave-app :focus-visible{outline:2px solid #18181b;outline-offset:2px}#wireweave-app button,#wireweave-app input,#wireweave-app select{min-height:24px;font:inherit}#wireweave-app .wf-row{display:flex;gap:0}#wireweave-app .wf-col{flex:1}#wireweave-app .wf-stack,#wireweave-app .wf-field{display:flex;flex-direction:column;gap:8px}#wireweave-app .wf-page,#wireweave-app [data-wf-shell]{width:${chunkVCHXMPZL_cjs.textValue(bundle.profile.width)}px;height:${chunkVCHXMPZL_cjs.textValue(bundle.profile.height)}px;overflow:auto}#wireweave-app .wf-card,#wireweave-app th,#wireweave-app td{border:1px solid #71717a;padding:8px}#wireweave-app .wf-relative{position:relative}#wireweave-app [data-wf-slot]{display:contents}${this.rules.join("")}#wireweave-app[data-wf-view=accessible] .wf-node,#wireweave-app[data-wf-view=accessible] [data-wf-shell]{position:static!important;transform:none!important;width:auto!important;height:auto!important;min-width:0!important;max-width:100%!important;min-height:0!important;overflow-wrap:anywhere;order:0!important}#wireweave-app[data-wf-view=accessible] .wf-row{flex-direction:column!important;flex-wrap:wrap!important}#wireweave-app[data-wf-view=accessible] .wf-col{flex-basis:auto!important}#wireweave-app .wf-field{min-width:0}#wireweave-app .wf-field input,#wireweave-app .wf-field textarea,#wireweave-app .wf-field select{max-width:100%}#wireweave-app [data-wf-field][hidden]{display:none!important}#wireweave-app [role=tablist]{display:flex;flex-wrap:wrap}#wireweave-app [role=tooltip]{background:#f4f4f5;border:1px solid #71717a}#wireweave-app dialog{color:#18181b;background:white;max-width:100%;max-height:100%;overflow:auto}`;
|
|
913
925
|
const runtimeData = this.program;
|
|
914
926
|
const csp = `default-src 'none'; script-src 'sha256-${hashBase64(NATIVE_RUNTIME)}'; style-src 'sha256-${hashBase64(css)}'; img-src data:; font-src data:; connect-src 'none'; object-src 'none'; base-uri 'none'; form-action 'none'; frame-src 'none'`;
|
|
915
927
|
return `<!DOCTYPE html>
|
|
@@ -2293,6 +2305,7 @@ function runtimeEngine(program) {
|
|
|
2293
2305
|
append(state, null, null, null, { type: input.kind }, "busy", "history-compensation");
|
|
2294
2306
|
return state;
|
|
2295
2307
|
}
|
|
2308
|
+
state.diagnostic = null;
|
|
2296
2309
|
if (input.kind === "reset") {
|
|
2297
2310
|
reset(state);
|
|
2298
2311
|
drain(state);
|
|
@@ -2376,6 +2389,12 @@ function runtimeEngine(program) {
|
|
|
2376
2389
|
if (!node) throw Error("unknown-source");
|
|
2377
2390
|
if (!["click", "input", "change", "submit", "keydown", "focus", "blur"].includes(input.event))
|
|
2378
2391
|
throw Error("event-type");
|
|
2392
|
+
if ("value" in input) {
|
|
2393
|
+
if (input.value === void 0) throw Error("event-payload");
|
|
2394
|
+
bounded(input.value);
|
|
2395
|
+
}
|
|
2396
|
+
if ("checked" in input && typeof input.checked !== "boolean") throw Error("event-payload");
|
|
2397
|
+
if ("key" in input && typeof input.key !== "string") throw Error("event-payload");
|
|
2379
2398
|
if (input.event === "keydown" && (typeof input.key !== "string" || "value" in input || "checked" in input))
|
|
2380
2399
|
throw Error("event-payload");
|
|
2381
2400
|
if (!["input", "change", "keydown"].includes(input.event) && ("value" in input || "checked" in input || "key" in input))
|
|
@@ -2384,10 +2403,15 @@ function runtimeEngine(program) {
|
|
|
2384
2403
|
node.kind
|
|
2385
2404
|
))
|
|
2386
2405
|
throw Error("event-owner");
|
|
2406
|
+
if (["input", "change"].includes(input.event)) {
|
|
2407
|
+
const booleanControl = ["checkbox", "radio", "switch"].includes(node.kind);
|
|
2408
|
+
if ("key" in input) throw Error("event-payload");
|
|
2409
|
+
if (booleanControl && "value" in input) throw Error("event-payload");
|
|
2410
|
+
if (!booleanControl && "checked" in input) throw Error("event-payload");
|
|
2411
|
+
}
|
|
2387
2412
|
if (input.event === "submit" && node.kind !== "form") throw Error("event-owner");
|
|
2388
2413
|
const event = { type: input.event };
|
|
2389
2414
|
if (input.value !== void 0) {
|
|
2390
|
-
bounded(input.value);
|
|
2391
2415
|
event.value = input.value;
|
|
2392
2416
|
}
|
|
2393
2417
|
if (input.checked !== void 0) event.checked = input.checked;
|
|
@@ -2452,15 +2476,15 @@ var snapshotPrograms = /* @__PURE__ */ new WeakMap();
|
|
|
2452
2476
|
function runtimeProgram(linked) {
|
|
2453
2477
|
const cached = programCache.get(linked);
|
|
2454
2478
|
if (cached) return cached;
|
|
2455
|
-
const data =
|
|
2479
|
+
const data = chunkVCHXMPZL_cjs.getLinkedAppData(linked);
|
|
2456
2480
|
if (!data) throw new TypeError("Untrusted LinkedApp");
|
|
2457
2481
|
const states = {};
|
|
2458
2482
|
for (const state of data.bundle.states) {
|
|
2459
|
-
const key = `app:${
|
|
2483
|
+
const key = `app:${chunkVCHXMPZL_cjs.textValue(state.id)}`;
|
|
2460
2484
|
states[key] = {
|
|
2461
2485
|
key,
|
|
2462
2486
|
initial: state.initial,
|
|
2463
|
-
type:
|
|
2487
|
+
type: chunkVCHXMPZL_cjs.textValue(state.type),
|
|
2464
2488
|
lifetime: "session",
|
|
2465
2489
|
sensitive: state.sensitive === true,
|
|
2466
2490
|
root: "app"
|
|
@@ -2472,14 +2496,14 @@ function runtimeProgram(linked) {
|
|
|
2472
2496
|
let form = entry.parent;
|
|
2473
2497
|
while (form && form.node.kind !== "form") form = form.parent;
|
|
2474
2498
|
const root = entry.identity.instanceRoot;
|
|
2475
|
-
const handlers =
|
|
2476
|
-
id:
|
|
2477
|
-
event:
|
|
2478
|
-
...handler.key === void 0 ? {} : { key:
|
|
2499
|
+
const handlers = chunkVCHXMPZL_cjs.asObjects(entry.node.attributes.on).map((handler) => ({
|
|
2500
|
+
id: chunkVCHXMPZL_cjs.textValue(handler.id),
|
|
2501
|
+
event: chunkVCHXMPZL_cjs.textValue(handler.event),
|
|
2502
|
+
...handler.key === void 0 ? {} : { key: chunkVCHXMPZL_cjs.textValue(handler.key) },
|
|
2479
2503
|
...handler.guard === void 0 ? {} : { guard: handler.guard },
|
|
2480
2504
|
concurrency: handler.concurrency === "queue" ? "queue" : "drop",
|
|
2481
|
-
operations:
|
|
2482
|
-
id:
|
|
2505
|
+
operations: chunkVCHXMPZL_cjs.asObjects(handler.operations).map((operation) => ({
|
|
2506
|
+
id: chunkVCHXMPZL_cjs.textValue(operation.id),
|
|
2483
2507
|
executionClass: operation.executionClass,
|
|
2484
2508
|
effect: operation.effect,
|
|
2485
2509
|
after: operation.after,
|
|
@@ -2514,11 +2538,16 @@ function runtimeProgram(linked) {
|
|
|
2514
2538
|
form: (_e = (_d = entry.formTarget) != null ? _d : form == null ? void 0 : form.renderedId) != null ? _e : null
|
|
2515
2539
|
};
|
|
2516
2540
|
});
|
|
2517
|
-
const
|
|
2541
|
+
const runtimeProfile = Object.fromEntries(
|
|
2542
|
+
Object.entries(data.bundle.profile).filter(
|
|
2543
|
+
([key]) => key !== "assets" && key !== "fontAssetId"
|
|
2544
|
+
)
|
|
2545
|
+
);
|
|
2546
|
+
const program = chunkVCHXMPZL_cjs.freeze({
|
|
2518
2547
|
appId: data.bundle.id,
|
|
2519
2548
|
modelDigest: linked.digest,
|
|
2520
|
-
profileDigest:
|
|
2521
|
-
profile:
|
|
2549
|
+
profileDigest: chunkH2SWIUMU_cjs.digestV4(chunkVCHXMPZL_cjs.jcs(data.bundle.profile)),
|
|
2550
|
+
profile: runtimeProfile,
|
|
2522
2551
|
entry: data.bundle.entry,
|
|
2523
2552
|
nodes: runtimeNodes,
|
|
2524
2553
|
states,
|
|
@@ -2537,11 +2566,11 @@ function runtimeProgram(linked) {
|
|
|
2537
2566
|
slot: shell.slotId
|
|
2538
2567
|
})),
|
|
2539
2568
|
fixtures: data.bundle.fixtures.map((fixture) => ({
|
|
2540
|
-
id:
|
|
2541
|
-
exhaustion:
|
|
2542
|
-
steps:
|
|
2569
|
+
id: chunkVCHXMPZL_cjs.textValue(fixture.id),
|
|
2570
|
+
exhaustion: chunkVCHXMPZL_cjs.textValue(fixture.exhaustion),
|
|
2571
|
+
steps: chunkVCHXMPZL_cjs.asObjects(fixture.steps).map((step) => ({
|
|
2543
2572
|
delayMs: Number(step.delayMs),
|
|
2544
|
-
outcome:
|
|
2573
|
+
outcome: chunkVCHXMPZL_cjs.textValue(step.outcome),
|
|
2545
2574
|
value: step.value
|
|
2546
2575
|
}))
|
|
2547
2576
|
})),
|
|
@@ -2551,7 +2580,7 @@ function runtimeProgram(linked) {
|
|
|
2551
2580
|
return program;
|
|
2552
2581
|
}
|
|
2553
2582
|
function ownSnapshot(snapshot, program) {
|
|
2554
|
-
|
|
2583
|
+
chunkVCHXMPZL_cjs.freeze(snapshot);
|
|
2555
2584
|
snapshotPrograms.set(snapshot, program);
|
|
2556
2585
|
return snapshot;
|
|
2557
2586
|
}
|
|
@@ -2588,6 +2617,16 @@ function browserAdapter(engine, program) {
|
|
|
2588
2617
|
if ((node == null ? void 0 : node.kind) === "dropdown") return document.getElementById(id + "-trigger");
|
|
2589
2618
|
return element(id);
|
|
2590
2619
|
}
|
|
2620
|
+
function pendingFor(id) {
|
|
2621
|
+
for (const request of Object.values(state.requests)) {
|
|
2622
|
+
let owner2 = nodes.get(request.owner);
|
|
2623
|
+
while (owner2) {
|
|
2624
|
+
if (owner2.id === id) return true;
|
|
2625
|
+
owner2 = owner2.parent ? nodes.get(owner2.parent) : void 0;
|
|
2626
|
+
}
|
|
2627
|
+
}
|
|
2628
|
+
return false;
|
|
2629
|
+
}
|
|
2591
2630
|
function metadata(sequence) {
|
|
2592
2631
|
return { wireweave: { modelDigest: program.modelDigest, sequence } };
|
|
2593
2632
|
}
|
|
@@ -2649,11 +2688,23 @@ function browserAdapter(engine, program) {
|
|
|
2649
2688
|
root.querySelector("[data-wf-invalid-address]").textContent = state.address;
|
|
2650
2689
|
root.setAttribute("data-wf-route", state.route ? state.address : "error");
|
|
2651
2690
|
root.setAttribute("data-wf-view", state.viewMode);
|
|
2652
|
-
root.setAttribute(
|
|
2691
|
+
root.setAttribute(
|
|
2692
|
+
"aria-busy",
|
|
2693
|
+
String(state.suspended || Object.keys(state.requests).length > 0)
|
|
2694
|
+
);
|
|
2653
2695
|
for (const node of program.nodes) {
|
|
2654
2696
|
const el = element(node.id);
|
|
2655
2697
|
if (!el) continue;
|
|
2656
2698
|
el.hidden = view.visible[node.id] !== true;
|
|
2699
|
+
const pending = pendingFor(node.id);
|
|
2700
|
+
if (pending || node.attributes.loading === true) {
|
|
2701
|
+
el.setAttribute("aria-busy", "true");
|
|
2702
|
+
if (pending) el.setAttribute("data-wf-pending", "true");
|
|
2703
|
+
else el.removeAttribute("data-wf-pending");
|
|
2704
|
+
} else {
|
|
2705
|
+
el.removeAttribute("aria-busy");
|
|
2706
|
+
el.removeAttribute("data-wf-pending");
|
|
2707
|
+
}
|
|
2657
2708
|
const field = el.closest("[data-wf-field]");
|
|
2658
2709
|
if (field) field.hidden = el.hidden;
|
|
2659
2710
|
if (node.kind === "tab") {
|
|
@@ -2698,10 +2749,7 @@ function browserAdapter(engine, program) {
|
|
|
2698
2749
|
error.textContent = state.invalid[node.id] ? "Check the required input values." : "";
|
|
2699
2750
|
error.hidden = !state.invalid[node.id];
|
|
2700
2751
|
}
|
|
2701
|
-
el.setAttribute(
|
|
2702
|
-
"aria-busy",
|
|
2703
|
-
String(Object.values(state.requests).some((request) => request.owner === node.id))
|
|
2704
|
-
);
|
|
2752
|
+
el.setAttribute("aria-busy", String(pending || node.attributes.loading === true));
|
|
2705
2753
|
}
|
|
2706
2754
|
if (node.kind === "accordion")
|
|
2707
2755
|
el.open = state.expanded[node.id] === true;
|
|
@@ -2978,15 +3026,15 @@ function browserAdapter(engine, program) {
|
|
|
2978
3026
|
}
|
|
2979
3027
|
var NATIVE_RUNTIME = `(()=>{const program=JSON.parse(document.getElementById("wf-runtime-data").textContent);(${browserAdapter.toString()})((${runtimeEngine.toString()})(program),program);})();`;
|
|
2980
3028
|
function compileAppV4(linked) {
|
|
2981
|
-
const data =
|
|
3029
|
+
const data = chunkVCHXMPZL_cjs.getLinkedAppData(linked);
|
|
2982
3030
|
if (data === void 0)
|
|
2983
|
-
return
|
|
3031
|
+
return chunkVCHXMPZL_cjs.failed([chunkVCHXMPZL_cjs.diagnostic("WW_SCHEMA", "app.untrusted-linked-model", void 0, {}, "compile")]);
|
|
2984
3032
|
if (data.artifact !== void 0) return { ok: true, value: data.artifact, diagnostics: [] };
|
|
2985
3033
|
const renderer = new HtmlArtifact(data, runtimeProgram(linked));
|
|
2986
3034
|
const html = renderer.html();
|
|
2987
3035
|
if (new TextEncoder().encode(html).byteLength > 64 * 1024 * 1024)
|
|
2988
|
-
return
|
|
2989
|
-
const artifact =
|
|
3036
|
+
return chunkVCHXMPZL_cjs.failed([chunkVCHXMPZL_cjs.diagnostic("WW_LIMIT", "app.html-byte-limit", void 0, {}, "compile")]);
|
|
3037
|
+
const artifact = chunkVCHXMPZL_cjs.freeze({
|
|
2990
3038
|
kind: "AppArtifact",
|
|
2991
3039
|
schemaVersion: "1.0.0",
|
|
2992
3040
|
languageVersion: "4.0.0",
|
|
@@ -2994,10 +3042,10 @@ function compileAppV4(linked) {
|
|
|
2994
3042
|
sourceMap: data.sourceMap,
|
|
2995
3043
|
mediaType: "text/html",
|
|
2996
3044
|
byteLength: new TextEncoder().encode(html).byteLength,
|
|
2997
|
-
digest:
|
|
3045
|
+
digest: chunkH2SWIUMU_cjs.digestV4(html),
|
|
2998
3046
|
modelDigest: linked.digest,
|
|
2999
|
-
profileDigest:
|
|
3000
|
-
runtimeDigest:
|
|
3047
|
+
profileDigest: chunkH2SWIUMU_cjs.digestV4(chunkVCHXMPZL_cjs.jcs(data.bundle.profile)),
|
|
3048
|
+
runtimeDigest: chunkH2SWIUMU_cjs.digestV4(NATIVE_RUNTIME),
|
|
3001
3049
|
registryDigest: data.bundle.registry.digest,
|
|
3002
3050
|
entry: data.bundle.entry,
|
|
3003
3051
|
screenIndex: data.screens.map((screen) => ({
|
|
@@ -3005,12 +3053,12 @@ function compileAppV4(linked) {
|
|
|
3005
3053
|
renderedId: screen.children[0].renderedId
|
|
3006
3054
|
})),
|
|
3007
3055
|
operationIndex: data.nodes.flatMap(
|
|
3008
|
-
(node) =>
|
|
3009
|
-
(handler) =>
|
|
3056
|
+
(node) => chunkVCHXMPZL_cjs.asObjects(node.node.attributes.on).flatMap(
|
|
3057
|
+
(handler) => chunkVCHXMPZL_cjs.asObjects(handler.operations).map((operation) => ({
|
|
3010
3058
|
renderedId: node.renderedId,
|
|
3011
|
-
handlerId:
|
|
3012
|
-
operationId:
|
|
3013
|
-
executionClass:
|
|
3059
|
+
handlerId: chunkVCHXMPZL_cjs.textValue(handler.id),
|
|
3060
|
+
operationId: chunkVCHXMPZL_cjs.textValue(operation.id),
|
|
3061
|
+
executionClass: chunkVCHXMPZL_cjs.textValue(operation.executionClass),
|
|
3014
3062
|
operation
|
|
3015
3063
|
}))
|
|
3016
3064
|
)
|
|
@@ -3019,11 +3067,17 @@ function compileAppV4(linked) {
|
|
|
3019
3067
|
manifest: {
|
|
3020
3068
|
appId: data.bundle.id,
|
|
3021
3069
|
modelDigest: linked.digest,
|
|
3022
|
-
profileDigest:
|
|
3070
|
+
profileDigest: chunkH2SWIUMU_cjs.digestV4(chunkVCHXMPZL_cjs.jcs(data.bundle.profile)),
|
|
3023
3071
|
registryDigest: data.bundle.registry.digest,
|
|
3024
|
-
htmlDigest:
|
|
3025
|
-
runtimeDigest:
|
|
3072
|
+
htmlDigest: chunkH2SWIUMU_cjs.digestV4(html),
|
|
3073
|
+
runtimeDigest: chunkH2SWIUMU_cjs.digestV4(NATIVE_RUNTIME),
|
|
3026
3074
|
executionScope: "standard-1",
|
|
3075
|
+
assets: [...renderer.assets.values()].map(({ id, mediaType, digest, byteLength }) => ({
|
|
3076
|
+
id,
|
|
3077
|
+
mediaType,
|
|
3078
|
+
digest,
|
|
3079
|
+
byteLength
|
|
3080
|
+
})),
|
|
3027
3081
|
unsupportedOperations: renderer.unsupported
|
|
3028
3082
|
}
|
|
3029
3083
|
});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { P as PageNode, L as LayoutDefinitionNode, W as WireframeDocument, A as AnyNode, C as ComponentUseNode, I as InteractiveProps, G as GuardedOutcomeProps } from './types-CGRi1k2N.cjs';
|
|
2
|
-
import { D as Diagnostic, S as SourceMapEntry, L as LinkedIdentity, a as ScreenReference, A as AppResult, b as LinkedApp, R as RenderContext, c as RenderOptions, T as ThemeConfig, d as RenderResult, e as AnnotationStyle, P as PageRenderResult, C as CanvasOptions, f as CanvasRenderResult, g as SvgRenderOptions, h as SvgRenderResult } from './index-
|
|
2
|
+
import { D as Diagnostic, S as SourceMapEntry, L as LinkedIdentity, a as ScreenReference, A as AppResult, b as LinkedApp, R as RenderContext, c as RenderOptions, T as ThemeConfig, d as RenderResult, e as AnnotationStyle, P as PageRenderResult, C as CanvasOptions, f as CanvasRenderResult, g as SvgRenderOptions, h as SvgRenderResult } from './index-DdQv4Bu5.cjs';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* The screen model behind `renderSite` — which pages become screens, which
|
|
@@ -4,7 +4,7 @@ import { W as WireframeDocument } from './types-CGRi1k2N.cjs';
|
|
|
4
4
|
interface Diagnostic {
|
|
5
5
|
severity: 'error';
|
|
6
6
|
code: string;
|
|
7
|
-
phase: '
|
|
7
|
+
phase: 'parse' | 'schema' | 'link' | 'semantic' | 'compile' | 'runtime';
|
|
8
8
|
sourceId: string;
|
|
9
9
|
start: number;
|
|
10
10
|
end: number;
|
|
@@ -133,6 +133,12 @@ interface AppArtifact {
|
|
|
133
133
|
readonly htmlDigest: string;
|
|
134
134
|
readonly runtimeDigest: string;
|
|
135
135
|
readonly executionScope: 'standard-1';
|
|
136
|
+
readonly assets: readonly {
|
|
137
|
+
readonly id: string;
|
|
138
|
+
readonly mediaType: string;
|
|
139
|
+
readonly digest: string;
|
|
140
|
+
readonly byteLength: number;
|
|
141
|
+
}[];
|
|
136
142
|
readonly unsupportedOperations: readonly {
|
|
137
143
|
renderedId: string;
|
|
138
144
|
handlerId: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { P as PageNode, L as LayoutDefinitionNode, W as WireframeDocument, A as AnyNode, C as ComponentUseNode, I as InteractiveProps, G as GuardedOutcomeProps } from './types-CGRi1k2N.js';
|
|
2
|
-
import { D as Diagnostic, S as SourceMapEntry, L as LinkedIdentity, a as ScreenReference, A as AppResult, b as LinkedApp, R as RenderContext, c as RenderOptions, T as ThemeConfig, d as RenderResult, e as AnnotationStyle, P as PageRenderResult, C as CanvasOptions, f as CanvasRenderResult, g as SvgRenderOptions, h as SvgRenderResult } from './index-
|
|
2
|
+
import { D as Diagnostic, S as SourceMapEntry, L as LinkedIdentity, a as ScreenReference, A as AppResult, b as LinkedApp, R as RenderContext, c as RenderOptions, T as ThemeConfig, d as RenderResult, e as AnnotationStyle, P as PageRenderResult, C as CanvasOptions, f as CanvasRenderResult, g as SvgRenderOptions, h as SvgRenderResult } from './index-c4FTW7XA.js';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* The screen model behind `renderSite` — which pages become screens, which
|
|
@@ -4,7 +4,7 @@ import { W as WireframeDocument } from './types-CGRi1k2N.js';
|
|
|
4
4
|
interface Diagnostic {
|
|
5
5
|
severity: 'error';
|
|
6
6
|
code: string;
|
|
7
|
-
phase: '
|
|
7
|
+
phase: 'parse' | 'schema' | 'link' | 'semantic' | 'compile' | 'runtime';
|
|
8
8
|
sourceId: string;
|
|
9
9
|
start: number;
|
|
10
10
|
end: number;
|
|
@@ -133,6 +133,12 @@ interface AppArtifact {
|
|
|
133
133
|
readonly htmlDigest: string;
|
|
134
134
|
readonly runtimeDigest: string;
|
|
135
135
|
readonly executionScope: 'standard-1';
|
|
136
|
+
readonly assets: readonly {
|
|
137
|
+
readonly id: string;
|
|
138
|
+
readonly mediaType: string;
|
|
139
|
+
readonly digest: string;
|
|
140
|
+
readonly byteLength: number;
|
|
141
|
+
}[];
|
|
136
142
|
readonly unsupportedOperations: readonly {
|
|
137
143
|
renderedId: string;
|
|
138
144
|
handlerId: string;
|