@vectoriox/iox-ui 5.90.1 → 5.91.0
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/design-core/index.d.ts +50 -3
- package/fesm2022/vectoriox-iox-ui-design-core.mjs +69 -4
- package/fesm2022/vectoriox-iox-ui-design-core.mjs.map +1 -1
- package/fesm2022/vectoriox-iox-ui-generation-core.mjs +575 -77
- package/fesm2022/vectoriox-iox-ui-generation-core.mjs.map +1 -1
- package/fesm2022/vectoriox-iox-ui.mjs +40 -23
- package/fesm2022/vectoriox-iox-ui.mjs.map +1 -1
- package/generation-core/index.d.ts +161 -20
- package/index.d.ts +18 -1
- package/package.json +1 -1
- package/src/design-core/flavor-spec.generated.ts +28 -0
- package/src/design-core/node-classes.ts +28 -1
- package/src/design-core/token-css.ts +18 -3
- package/src/generation-core/check-layout.ts +84 -25
- package/src/generation-core/compose-layout.ts +92 -7
- package/src/generation-core/compose-site.ts +18 -7
- package/src/generation-core/layout-language.ts +19 -1
- package/src/generation-core/layout-section-fallback.ts +18 -4
- package/src/generation-core/layout-space.ts +260 -0
- package/src/generation-core/patterns.ts +2 -0
- package/src/generation-core/pictures.ts +3 -3
- package/src/generation-core/public-api.ts +1 -0
- package/src/generation-core/site-spec.generated.ts +30 -14
- package/src/generation-core/stock-photos.ts +77 -13
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { NEW_NODE_STYLE_DEFAULTS, defaultElementStyleFor, elementStyleById, ownedTraitsOf, applyElementStyle, parseHexColor, rgbToOklab, flavorPackById, SPEC_AXES, EntranceParam, staggerDelay, LinkType, presetChoices, resolveDesignChoices, textWidthEm, elementStyleFace, setColorScheme, ColorScheme, stylePresetOfChoices, presetModes, STYLE_PRESETS, COLOR_SCHEMES, ANIMATE_IDS, auditDesignContrast, parseCssColour, compositeOver, wcagContrastRatio, relativeLuminance, toHexColor, resolveTokenValues, designTokenRows } from '@vectoriox/iox-ui/design-core';
|
|
1
|
+
import { NEW_NODE_STYLE_DEFAULTS, defaultElementStyleFor, elementStyleById, ownedTraitsOf, applyElementStyle, parseHexColor, rgbToOklab, flavorPackById, SPEC_AXES, EntranceParam, staggerDelay, LinkType, presetChoices, resolveDesignChoices, textWidthEm, elementStyleFace, setColorScheme, ColorScheme, stylePresetOfChoices, presetModes, STYLE_PRESETS, COLOR_SCHEMES, colorSchemeClass, COLOR_SCHEME_TRAIT, ANIMATE_IDS, auditDesignContrast, parseCssColour, compositeOver, wcagContrastRatio, relativeLuminance, toHexColor, resolveTokenValues, designTokenRows } from '@vectoriox/iox-ui/design-core';
|
|
2
2
|
import { formPresetById, FormPresetId, FormAfterSend, FORM_AFTER_SEND_TRAIT, FORM_ACTIONS_ROLE, channelOpensNewTab, FORM_CHANNEL_ROLE, planFormPresetIds, ControlType, FORM_NODE_TYPE, collectFormSpec, FIELD_NODE_TYPE, isChannelFilled } from '@vectoriox/iox-ui/forms-core';
|
|
3
3
|
import { normalizeFrameSequence, filmScreensFor, FILM_PREPARED_PICTURES, FrameExtension } from '@vectoriox/iox-ui/media-core';
|
|
4
4
|
import { SEO_DESCRIPTION_MAX, SEO_TITLE_MAX } from '@vectoriox/iox-ui/seo-core';
|
|
@@ -599,7 +599,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
599
599
|
]
|
|
600
600
|
]
|
|
601
601
|
}
|
|
602
|
-
]
|
|
602
|
+
],
|
|
603
|
+
"textHe": "צרו קשר"
|
|
603
604
|
}
|
|
604
605
|
]
|
|
605
606
|
}
|
|
@@ -750,7 +751,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
750
751
|
]
|
|
751
752
|
]
|
|
752
753
|
}
|
|
753
|
-
]
|
|
754
|
+
],
|
|
755
|
+
"textHe": "צרו קשר"
|
|
754
756
|
}
|
|
755
757
|
]
|
|
756
758
|
}
|
|
@@ -1222,7 +1224,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
1222
1224
|
"slot": "cta",
|
|
1223
1225
|
"max": 24,
|
|
1224
1226
|
"text": "Get in touch",
|
|
1225
|
-
"role": "nav.cta"
|
|
1227
|
+
"role": "nav.cta",
|
|
1228
|
+
"textHe": "צרו קשר"
|
|
1226
1229
|
}
|
|
1227
1230
|
]
|
|
1228
1231
|
}
|
|
@@ -1301,7 +1304,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
1301
1304
|
"slot": "cta",
|
|
1302
1305
|
"max": 24,
|
|
1303
1306
|
"text": "Get in touch",
|
|
1304
|
-
"role": "nav.cta"
|
|
1307
|
+
"role": "nav.cta",
|
|
1308
|
+
"textHe": "צרו קשר"
|
|
1305
1309
|
}
|
|
1306
1310
|
]
|
|
1307
1311
|
}
|
|
@@ -1374,7 +1378,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
1374
1378
|
"level": "h4",
|
|
1375
1379
|
"slot": "pagesLabel",
|
|
1376
1380
|
"max": 40,
|
|
1377
|
-
"text": "Pages"
|
|
1381
|
+
"text": "Pages",
|
|
1382
|
+
"textHe": "עמודים"
|
|
1378
1383
|
},
|
|
1379
1384
|
{
|
|
1380
1385
|
"t": "Link",
|
|
@@ -1400,7 +1405,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
1400
1405
|
"level": "h4",
|
|
1401
1406
|
"slot": "contactLabel",
|
|
1402
1407
|
"max": 40,
|
|
1403
|
-
"text": "Contact"
|
|
1408
|
+
"text": "Contact",
|
|
1409
|
+
"textHe": "יצירת קשר"
|
|
1404
1410
|
},
|
|
1405
1411
|
{
|
|
1406
1412
|
"t": "Text",
|
|
@@ -1509,7 +1515,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
1509
1515
|
"level": "h4",
|
|
1510
1516
|
"slot": "pagesLabel",
|
|
1511
1517
|
"max": 40,
|
|
1512
|
-
"text": "Pages"
|
|
1518
|
+
"text": "Pages",
|
|
1519
|
+
"textHe": "עמודים"
|
|
1513
1520
|
},
|
|
1514
1521
|
{
|
|
1515
1522
|
"t": "Link",
|
|
@@ -1535,7 +1542,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
1535
1542
|
"level": "h4",
|
|
1536
1543
|
"slot": "visitLabel",
|
|
1537
1544
|
"max": 40,
|
|
1538
|
-
"text": "Visit"
|
|
1545
|
+
"text": "Visit",
|
|
1546
|
+
"textHe": "ביקור"
|
|
1539
1547
|
},
|
|
1540
1548
|
{
|
|
1541
1549
|
"t": "Text",
|
|
@@ -1564,7 +1572,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
1564
1572
|
"level": "h4",
|
|
1565
1573
|
"slot": "contactLabel",
|
|
1566
1574
|
"max": 40,
|
|
1567
|
-
"text": "Contact"
|
|
1575
|
+
"text": "Contact",
|
|
1576
|
+
"textHe": "יצירת קשר"
|
|
1568
1577
|
},
|
|
1569
1578
|
{
|
|
1570
1579
|
"t": "Text",
|
|
@@ -1745,7 +1754,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
1745
1754
|
"href": "/contact",
|
|
1746
1755
|
"slot": "secondary",
|
|
1747
1756
|
"max": 24,
|
|
1748
|
-
"text": "Get in touch"
|
|
1757
|
+
"text": "Get in touch",
|
|
1758
|
+
"textHe": "צרו קשר"
|
|
1749
1759
|
}
|
|
1750
1760
|
]
|
|
1751
1761
|
}
|
|
@@ -1835,7 +1845,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
1835
1845
|
"href": "/contact",
|
|
1836
1846
|
"slot": "primary",
|
|
1837
1847
|
"max": 24,
|
|
1838
|
-
"text": "Get in touch"
|
|
1848
|
+
"text": "Get in touch",
|
|
1849
|
+
"textHe": "צרו קשר"
|
|
1839
1850
|
},
|
|
1840
1851
|
{
|
|
1841
1852
|
"t": "ButtonBlock",
|
|
@@ -2769,7 +2780,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
2769
2780
|
"href": "/contact",
|
|
2770
2781
|
"slot": "action",
|
|
2771
2782
|
"max": 24,
|
|
2772
|
-
"text": "Get in touch"
|
|
2783
|
+
"text": "Get in touch",
|
|
2784
|
+
"textHe": "צרו קשר"
|
|
2773
2785
|
}
|
|
2774
2786
|
]
|
|
2775
2787
|
}
|
|
@@ -3515,7 +3527,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
3515
3527
|
"slot": "title",
|
|
3516
3528
|
"max": 44,
|
|
3517
3529
|
"text": "Get in touch",
|
|
3518
|
-
"enter": "heading"
|
|
3530
|
+
"enter": "heading",
|
|
3531
|
+
"textHe": "צרו קשר"
|
|
3519
3532
|
},
|
|
3520
3533
|
{
|
|
3521
3534
|
"t": "Text",
|
|
@@ -4536,7 +4549,8 @@ const SPEC_SITE_PATTERNS = {
|
|
|
4536
4549
|
"href": "/contact",
|
|
4537
4550
|
"slot": "cta",
|
|
4538
4551
|
"max": 24,
|
|
4539
|
-
"text": "Get in touch"
|
|
4552
|
+
"text": "Get in touch",
|
|
4553
|
+
"textHe": "צרו קשר"
|
|
4540
4554
|
}
|
|
4541
4555
|
]
|
|
4542
4556
|
}
|
|
@@ -6183,6 +6197,8 @@ const SPEC_SITE_LAYOUT = {
|
|
|
6183
6197
|
"distinct": {
|
|
6184
6198
|
"holdsMax": 1
|
|
6185
6199
|
},
|
|
6200
|
+
"voidScreen": 0.6,
|
|
6201
|
+
"bandColumns": 10,
|
|
6186
6202
|
"composedPages": 2,
|
|
6187
6203
|
"repairs": 1
|
|
6188
6204
|
},
|
|
@@ -13935,7 +13951,7 @@ function navShapeBreakpoint(globals) {
|
|
|
13935
13951
|
}
|
|
13936
13952
|
const prop = (n, name) => n.props?.[name];
|
|
13937
13953
|
const isPageLink = (n) => prop(n, 'linkType') === LinkType.Page && typeof prop(n, 'pageRoute') === 'string';
|
|
13938
|
-
function textOf$
|
|
13954
|
+
function textOf$3(n) {
|
|
13939
13955
|
if (n.type === LINK)
|
|
13940
13956
|
return String(prop(n, 'label') ?? '');
|
|
13941
13957
|
let words = '';
|
|
@@ -13947,7 +13963,7 @@ function textOf$2(n) {
|
|
|
13947
13963
|
function navPages(root) {
|
|
13948
13964
|
const links = findAll([root], NavRole.Link);
|
|
13949
13965
|
const source = links.length ? links : collectHeaderLinks(root);
|
|
13950
|
-
return source.filter(isPageLink).map(n => ({ label: textOf$
|
|
13966
|
+
return source.filter(isPageLink).map(n => ({ label: textOf$3(n), route: String(prop(n, 'pageRoute')) }));
|
|
13951
13967
|
}
|
|
13952
13968
|
/** Where a phone menu's pages come from: the header's own page Links, else the studio's pages. */
|
|
13953
13969
|
var NavPagesSource;
|
|
@@ -14083,7 +14099,7 @@ function drawer(kit, root, pages, at) {
|
|
|
14083
14099
|
const dr = part(kit, 'drawer', DIALOG$1, {
|
|
14084
14100
|
placement: 'end', closeOnBackdrop: true, showCloseButton: false, ariaLabel: NAV_SHAPE_COPY.menu, closeAbove: at,
|
|
14085
14101
|
}, 'dialog', NavRole.Drawer, { width: '86vw', maxWidth: '360px', display: 'flex', flexDirection: 'column', gap: '20px' });
|
|
14086
|
-
const brandWords = textOf$
|
|
14102
|
+
const brandWords = textOf$3(find([root], NavRole.Brand) ?? root) || NAV_PART_LABELS[NavRole.Root];
|
|
14087
14103
|
const head = part(kit, 'drawer-head', CONTAINER, {}, 'box', NavRole.DrawerHead, { display: 'flex', justifyContent: 'space-between', alignItems: 'center', gap: '12px' });
|
|
14088
14104
|
const close = part(kit, 'drawer-close', BUTTON, { tag: 'button', ariaLabel: NAV_SHAPE_COPY.closeMenu }, 'button-ghost', NavRole.DrawerClose, { ...MENU_BUTTON_LAY });
|
|
14089
14105
|
close.children = [iconNode(kit, 'drawer-close-icon', CLOSE_ICON)];
|
|
@@ -14334,7 +14350,7 @@ function nameParts(root) {
|
|
|
14334
14350
|
}
|
|
14335
14351
|
const cta = find([root], NavRole.Cta);
|
|
14336
14352
|
if (cta && !cta.label) {
|
|
14337
|
-
const words = textOf$
|
|
14353
|
+
const words = textOf$3(cta);
|
|
14338
14354
|
if (words)
|
|
14339
14355
|
cta.label = words;
|
|
14340
14356
|
}
|
|
@@ -14621,6 +14637,20 @@ var LayoutMendKind;
|
|
|
14621
14637
|
* the section's words name, else the first in plan order. None, or the section's words name the list it named
|
|
14622
14638
|
* (iox-ui#66): left to the model. */
|
|
14623
14639
|
LayoutMendKind["Source"] = "source";
|
|
14640
|
+
/** A held section where nothing moves by the scroll (the page stops on a still screen, M8 demo): its line — a word,
|
|
14641
|
+
* heading or text of at most the kinetic words — is lit word by word as the hold plays. */
|
|
14642
|
+
LayoutMendKind["Words"] = "words";
|
|
14643
|
+
/** A held section where nothing moves and no line can be lit: it flows, one screen tall — when the page can spare the hold. */
|
|
14644
|
+
LayoutMendKind["Unpin"] = "unpin";
|
|
14645
|
+
/** …and when it cannot (a daring page needs its holds): its largest photo drifts — a slow scale as the hold plays. */
|
|
14646
|
+
LayoutMendKind["Drift"] = "drift";
|
|
14647
|
+
/** A shape with no purpose — not a rule, a band, a frame, a backdrop to words, and it does not move: it is dropped. */
|
|
14648
|
+
LayoutMendKind["Drop"] = "drop";
|
|
14649
|
+
/** A section that leaves a stretch of the laptop's screen with nothing on it: its height comes down (its rows keep
|
|
14650
|
+
* their share, the words still fit) until the stretch is gone. */
|
|
14651
|
+
LayoutMendKind["Screens"] = "screens";
|
|
14652
|
+
/** A daring or Expressive page whose opening has no display: the opening's lead line is set as one (a word). */
|
|
14653
|
+
LayoutMendKind["Display"] = "display";
|
|
14624
14654
|
})(LayoutMendKind || (LayoutMendKind = {}));
|
|
14625
14655
|
/** Which rule chose a mended gallery's list. */
|
|
14626
14656
|
var LayoutSourceChoice;
|
|
@@ -14831,6 +14861,255 @@ function driftOverlap(a, b, view, clip) {
|
|
|
14831
14861
|
return best;
|
|
14832
14862
|
}
|
|
14833
14863
|
|
|
14864
|
+
/**
|
|
14865
|
+
* Space on a composed page (the M8 demo, the bar's live page 2026-11-10): what the static check can read off the grid
|
|
14866
|
+
* about stillness and emptiness — a held section where nothing moves, a shape that is there for nothing, a stretch of the
|
|
14867
|
+
* laptop's screen with nothing on it, an opening with no display. Estimates on the check's laptop (1440 × 900), the
|
|
14868
|
+
* render check measures the real page. Pure.
|
|
14869
|
+
*/
|
|
14870
|
+
const L$1 = SPEC_SITE_LAYOUT;
|
|
14871
|
+
const LIM$1 = L$1.limits;
|
|
14872
|
+
/**
|
|
14873
|
+
* The laptop the estimates are made on (the render check's 1440 × 900). A grid column is taken as 1440 / 12 px and a row
|
|
14874
|
+
* as its section's screens × 900 / rows (a held section's grid is its one-screen stage): the gutter and the column gaps
|
|
14875
|
+
* are left out, so a box reads about a fifth wider than it renders — the render check measures the real one.
|
|
14876
|
+
*/
|
|
14877
|
+
const LAYOUT_CHECK_VIEWPORT = { width: 1440, height: 900 };
|
|
14878
|
+
const GRID$1 = 12;
|
|
14879
|
+
const COLUMN_PX$1 = LAYOUT_CHECK_VIEWPORT.width / GRID$1;
|
|
14880
|
+
/** A line of words stands its size × this tall. */
|
|
14881
|
+
const LAYOUT_LINE_HEIGHT = 1.2;
|
|
14882
|
+
const HEBREW$1 = /[-]/;
|
|
14883
|
+
/** A button's ink, as tall as its padding and one line. */
|
|
14884
|
+
const BUTTON_PX = 56;
|
|
14885
|
+
/** How far the screens mend lowers a section at a time, and how often it tries. */
|
|
14886
|
+
const SCREENS_STEP = 0.25;
|
|
14887
|
+
const SCREENS_TRIES = 40;
|
|
14888
|
+
/** The kinds the composer stretches over their whole cell (`place`); every other kind sits in its cell's middle. */
|
|
14889
|
+
const FULL_CELL = new Set([LayoutLayerKind.Photo, LayoutLayerKind.Shape, LayoutLayerKind.Gallery, LayoutLayerKind.Form, LayoutLayerKind.Marquee]);
|
|
14890
|
+
/** The kinds a held section's line may be lit by the scroll (`kinetic`). */
|
|
14891
|
+
const LAYOUT_KINETIC_KINDS = new Set([LayoutLayerKind.Word, LayoutLayerKind.Heading, LayoutLayerKind.Text]);
|
|
14892
|
+
const span$1 = (r) => (r ? r[1] - r[0] : 0);
|
|
14893
|
+
const isText$1 = (l) => LAYOUT_TEXT_KINDS.has(l.kind);
|
|
14894
|
+
const isPictured$1 = (l) => l.kind === LayoutLayerKind.Photo || l.kind === LayoutLayerKind.Gallery;
|
|
14895
|
+
const wordsOf$2 = (t) => String(t ?? '').trim().split(/\s+/).filter(Boolean).length;
|
|
14896
|
+
const meets = (a, b) => {
|
|
14897
|
+
const ov = (p, q) => p[0] < q[1] && q[0] < p[1];
|
|
14898
|
+
return ov(a.col ?? [0, 0], b.col ?? [0, 0]) && ov(a.row ?? [0, 0], b.row ?? [0, 0]);
|
|
14899
|
+
};
|
|
14900
|
+
const textOf$2 = (l) => String(l.text ?? (l.items ?? []).join(' '));
|
|
14901
|
+
const advanceOf = (text) => (HEBREW$1.test(text) ? LIM$1.advance.hebrew : LIM$1.advance.latin);
|
|
14902
|
+
/** A grid box's size in px on the laptop. */
|
|
14903
|
+
function layoutBoxPx(col, row, s) {
|
|
14904
|
+
const height = (s.pin ? 1 : s.screens) * LAYOUT_CHECK_VIEWPORT.height;
|
|
14905
|
+
return { w: span$1(col) * COLUMN_PX$1, h: (span$1(row) * height) / Math.max(1, s.rows) };
|
|
14906
|
+
}
|
|
14907
|
+
/** Whether a sized text layer's words fit its box at its size (the check's estimate; a `screen` word is sized to fit). */
|
|
14908
|
+
function layoutTextFits(l, s, size = l.size) {
|
|
14909
|
+
const text = textOf$2(l);
|
|
14910
|
+
if (!isText$1(l) || !size || size === LayoutSize.Screen || !text)
|
|
14911
|
+
return true;
|
|
14912
|
+
const px = L$1.sizePx[size];
|
|
14913
|
+
const box = layoutBoxPx(l.col, l.row, s);
|
|
14914
|
+
const lines = Math.floor(box.h / (px * LAYOUT_LINE_HEIGHT));
|
|
14915
|
+
const items = l.kind === LayoutLayerKind.List ? Math.max(1, l.items?.length ?? 1) : 1;
|
|
14916
|
+
return lines >= items && (text.length * px * advanceOf(text)) / Math.max(1, lines) <= box.w * LIM$1.textFitSlack;
|
|
14917
|
+
}
|
|
14918
|
+
/** Words or a button drawn over a layer (above it, meeting it). */
|
|
14919
|
+
function wordsOver(s, li) {
|
|
14920
|
+
const l = s.layers[li];
|
|
14921
|
+
return s.layers.some((o, oi) => oi !== li && (isText$1(o) || o.kind === LayoutLayerKind.Button) && (o.z ?? 0) > (l.z ?? 0) && meets(o, l));
|
|
14922
|
+
}
|
|
14923
|
+
/**
|
|
14924
|
+
* A rule: a shape one row high with no words on it — the looks' hairline ("a shape one row high"). The composer draws it
|
|
14925
|
+
* as a line, never as the row's full height (the bar's grey boxes: a 150–180 px block where a hairline was meant).
|
|
14926
|
+
*/
|
|
14927
|
+
function isLayoutRule(s, li) {
|
|
14928
|
+
const l = s.layers?.[li];
|
|
14929
|
+
return !!l && l.kind === LayoutLayerKind.Shape && span$1(l.row) === 1 && !wordsOver(s, li);
|
|
14930
|
+
}
|
|
14931
|
+
/** Where a rule's line sits in its row: against the words it belongs to (above it → its top, below it → its bottom). */
|
|
14932
|
+
function layoutRuleEdge(s, li) {
|
|
14933
|
+
const l = s.layers[li];
|
|
14934
|
+
const beside = (o) => isText$1(o) && (o.col?.[0] ?? 0) < (l.col?.[1] ?? 0) && (l.col?.[0] ?? 0) < (o.col?.[1] ?? 0);
|
|
14935
|
+
if (s.layers.some((o, oi) => oi !== li && beside(o) && o.row?.[1] === l.row[0]))
|
|
14936
|
+
return 'start';
|
|
14937
|
+
if (s.layers.some((o, oi) => oi !== li && beside(o) && o.row?.[0] === l.row[1]))
|
|
14938
|
+
return 'end';
|
|
14939
|
+
return 'center';
|
|
14940
|
+
}
|
|
14941
|
+
/**
|
|
14942
|
+
* A shape is there for something: a rule, a band of colour (wide, or off an edge), a backdrop to words, a frame meeting
|
|
14943
|
+
* a picture, or it moves (tracks, a depth). Anything else is an empty box on the page.
|
|
14944
|
+
*/
|
|
14945
|
+
function layoutShapeHasPurpose(s, li) {
|
|
14946
|
+
const l = s.layers?.[li];
|
|
14947
|
+
if (!l || l.kind !== LayoutLayerKind.Shape)
|
|
14948
|
+
return true;
|
|
14949
|
+
if (isLayoutRule(s, li) || wordsOver(s, li))
|
|
14950
|
+
return true;
|
|
14951
|
+
if (span$1(l.col) >= LIM$1.bandColumns || (l.bleed && l.bleed !== 'none'))
|
|
14952
|
+
return true;
|
|
14953
|
+
if (s.layers.some((o, oi) => oi !== li && isPictured$1(o) && meets(o, l)))
|
|
14954
|
+
return true;
|
|
14955
|
+
return !!l.motion?.length || (!!l.depth && l.depth !== LayoutDepth.Mid);
|
|
14956
|
+
}
|
|
14957
|
+
/** A held section where nothing moves by the scroll: no track, no kinetic line, no gallery the scroll turns. */
|
|
14958
|
+
function layoutHeldStill(s) {
|
|
14959
|
+
if (!s.pin || (s.track ?? 1) > 1 || s.readyMade)
|
|
14960
|
+
return false;
|
|
14961
|
+
return !(s.layers ?? []).some(l => !!l.motion?.length || !!l.kinetic || (l.kind === LayoutLayerKind.Gallery && !!l.gallery?.scroll));
|
|
14962
|
+
}
|
|
14963
|
+
/**
|
|
14964
|
+
* The line a still hold can light word by word: a word, heading or text of 2 to the kinetic words, never over a picture —
|
|
14965
|
+
* the lead first, then by size. -1: none.
|
|
14966
|
+
*/
|
|
14967
|
+
function layoutStillLine(s) {
|
|
14968
|
+
const sizes = Object.keys(L$1.sizePx);
|
|
14969
|
+
const found = (s.layers ?? [])
|
|
14970
|
+
.map((l, li) => ({ l, li }))
|
|
14971
|
+
.filter(({ l }) => LAYOUT_KINETIC_KINDS.has(l.kind) && wordsOf$2(l.text) >= 2 && wordsOf$2(l.text) <= LIM$1.kineticWords)
|
|
14972
|
+
.filter(({ l }) => !(s.layers ?? []).some(o => o !== l && isPictured$1(o) && meets(o, l)))
|
|
14973
|
+
.sort((a, b) => Number(b.l.role === LayoutRole.Lead) - Number(a.l.role === LayoutRole.Lead) || sizes.indexOf(b.l.size ?? 'm') - sizes.indexOf(a.l.size ?? 'm') || a.li - b.li);
|
|
14974
|
+
return found[0]?.li ?? -1;
|
|
14975
|
+
}
|
|
14976
|
+
/** A held section's largest photo that may move (not decoration — decoration only fades), for a still hold that cannot
|
|
14977
|
+
* let go of the page: -1, none. */
|
|
14978
|
+
function layoutDriftPhoto(s) {
|
|
14979
|
+
const area = (l) => span$1(l.col) * span$1(l.row);
|
|
14980
|
+
const found = (s.layers ?? []).map((l, li) => ({ l, li }))
|
|
14981
|
+
.filter(({ l }) => l.kind === LayoutLayerKind.Photo && l.role !== LayoutRole.Decoration && Array.isArray(l.col) && Array.isArray(l.row))
|
|
14982
|
+
.sort((a, b) => area(b.l) - area(a.l) || a.li - b.li);
|
|
14983
|
+
return found[0]?.li ?? -1;
|
|
14984
|
+
}
|
|
14985
|
+
/** The drift a still hold's photo takes: a slow scale over the whole hold — transform only, inside the track's bounds. */
|
|
14986
|
+
const LAYOUT_DRIFT = { prop: LayoutTrackProp.Scale, from: 1, to: 1.08, at: [0, 1] };
|
|
14987
|
+
/** A section whose screen is spoken for: what is on it never leaves it (held, sideways, a photo ground, ready-made), or
|
|
14988
|
+
* its space is the point (an inhale — the page's one breath, a word in the quiet). */
|
|
14989
|
+
const filled = (s) => !!s.pin || (s.track ?? 1) > 1 || !!s.readyMade || String(s.ground ?? '').startsWith('photo:')
|
|
14990
|
+
|| s.kind === LayoutSectionKind.Inhale;
|
|
14991
|
+
/** Where a layer's ink is in its section (px from the section's top): its cell for what stretches, its words' lines in the
|
|
14992
|
+
* cell's middle for the rest, the line of a rule. */
|
|
14993
|
+
function inkOf(s, li, rowPx) {
|
|
14994
|
+
const l = s.layers[li];
|
|
14995
|
+
const t = (l.row[0] - 1) * rowPx;
|
|
14996
|
+
const b = (l.row[1] - 1) * rowPx;
|
|
14997
|
+
const mid = (t + b) / 2;
|
|
14998
|
+
if (l.kind === LayoutLayerKind.Shape && isLayoutRule(s, li)) {
|
|
14999
|
+
const edge = layoutRuleEdge(s, li);
|
|
15000
|
+
const at = edge === 'start' ? t : edge === 'end' ? b : mid;
|
|
15001
|
+
return [at, at];
|
|
15002
|
+
}
|
|
15003
|
+
if (FULL_CELL.has(l.kind) || l.size === LayoutSize.Screen)
|
|
15004
|
+
return [t, b];
|
|
15005
|
+
let h = BUTTON_PX;
|
|
15006
|
+
if (isText$1(l)) {
|
|
15007
|
+
const text = textOf$2(l);
|
|
15008
|
+
const px = L$1.sizePx[(l.size ?? LayoutSize.M)] ?? L$1.sizePx.m;
|
|
15009
|
+
const w = Math.max(1, span$1(l.col) * COLUMN_PX$1);
|
|
15010
|
+
const items = l.kind === LayoutLayerKind.List ? Math.max(1, l.items?.length ?? 1) : 1;
|
|
15011
|
+
const lines = Math.max(items, Math.ceil((text.length * px * advanceOf(text)) / (w * LIM$1.textFitSlack)));
|
|
15012
|
+
h = lines * px * LAYOUT_LINE_HEIGHT;
|
|
15013
|
+
}
|
|
15014
|
+
h = Math.min(b - t, h);
|
|
15015
|
+
return [mid - h / 2, mid + h / 2];
|
|
15016
|
+
}
|
|
15017
|
+
/**
|
|
15018
|
+
* Every stretch more than `voidScreen` of a screen tall with nothing on it, top to bottom. A section that holds (or is a
|
|
15019
|
+
* photo, or ready-made) fills its height; one that flows has its layers' ink (`inkOf`). Judged across the sections, as a
|
|
15020
|
+
* visitor scrolls them; the end of the page counts (the footer is not the page's).
|
|
15021
|
+
*/
|
|
15022
|
+
function layoutVoids(sections) {
|
|
15023
|
+
const ink = [];
|
|
15024
|
+
const bounds = [];
|
|
15025
|
+
let top = 0;
|
|
15026
|
+
for (const s of sections) {
|
|
15027
|
+
const height = Math.max(1, Number(s.screens) || 1) * LAYOUT_CHECK_VIEWPORT.height;
|
|
15028
|
+
bounds.push([top, top + height]);
|
|
15029
|
+
if (filled(s))
|
|
15030
|
+
ink.push([top, top + height]);
|
|
15031
|
+
else {
|
|
15032
|
+
const rowPx = height / Math.max(1, s.rows);
|
|
15033
|
+
(s.layers ?? []).forEach((l, li) => {
|
|
15034
|
+
if (!Array.isArray(l.row) || !Array.isArray(l.col))
|
|
15035
|
+
return;
|
|
15036
|
+
const [a, b] = inkOf(s, li, rowPx);
|
|
15037
|
+
ink.push([top + a, top + b]);
|
|
15038
|
+
});
|
|
15039
|
+
}
|
|
15040
|
+
top += height;
|
|
15041
|
+
}
|
|
15042
|
+
ink.sort((a, b) => a[0] - b[0]);
|
|
15043
|
+
const voids = [];
|
|
15044
|
+
const least = LIM$1.voidScreen * LAYOUT_CHECK_VIEWPORT.height;
|
|
15045
|
+
let end = 0;
|
|
15046
|
+
const push = (from, to) => {
|
|
15047
|
+
if (to - from <= least)
|
|
15048
|
+
return;
|
|
15049
|
+
const within = bounds.map((b, i) => (b[0] < to && from < b[1] ? i : -1)).filter(i => i >= 0);
|
|
15050
|
+
voids.push({ from: Math.round(from), to: Math.round(to), sections: within });
|
|
15051
|
+
};
|
|
15052
|
+
for (const [a, b] of ink) {
|
|
15053
|
+
push(end, a);
|
|
15054
|
+
end = Math.max(end, b);
|
|
15055
|
+
}
|
|
15056
|
+
push(end, top);
|
|
15057
|
+
return voids;
|
|
15058
|
+
}
|
|
15059
|
+
/**
|
|
15060
|
+
* The heights that close every void: the sections a void lies in that flow come down a quarter screen at a time (never
|
|
15061
|
+
* under one screen; their rows keep their share, and each of their words still fits) until no void is left. Null when
|
|
15062
|
+
* that cannot close them — then the model is asked.
|
|
15063
|
+
*/
|
|
15064
|
+
function layoutVoidScreens(sections) {
|
|
15065
|
+
const next = sections.map(s => ({ ...s }));
|
|
15066
|
+
const stuck = new Set();
|
|
15067
|
+
for (let tries = 0; tries < SCREENS_TRIES; tries++) {
|
|
15068
|
+
const voids = layoutVoids(next);
|
|
15069
|
+
if (!voids.length) {
|
|
15070
|
+
return next.map((s, i) => ({ section: i, screens: s.screens })).filter(({ section, screens }) => screens !== sections[section].screens);
|
|
15071
|
+
}
|
|
15072
|
+
const free = [...new Set(voids.flatMap(v => v.sections))]
|
|
15073
|
+
.filter(i => !filled(next[i]) && !stuck.has(i) && next[i].screens > 1)
|
|
15074
|
+
.sort((a, b) => next[b].screens - next[a].screens || a - b);
|
|
15075
|
+
if (!free.length)
|
|
15076
|
+
return null;
|
|
15077
|
+
const i = free[0];
|
|
15078
|
+
const lower = { ...next[i], screens: Math.max(1, Math.round((next[i].screens - SCREENS_STEP) * 100) / 100) };
|
|
15079
|
+
if ((lower.layers ?? []).every(l => layoutTextFits(l, lower)))
|
|
15080
|
+
next[i] = lower;
|
|
15081
|
+
else
|
|
15082
|
+
stuck.add(i);
|
|
15083
|
+
}
|
|
15084
|
+
return null;
|
|
15085
|
+
}
|
|
15086
|
+
/** The layers that make an opening's display: a word (set in the display face), or words at xxl or screen size. */
|
|
15087
|
+
function layoutOpeningDisplays(page) {
|
|
15088
|
+
const first = page.sections?.[0];
|
|
15089
|
+
if (!first || first.readyMade)
|
|
15090
|
+
return [];
|
|
15091
|
+
return (first.layers ?? []).map((l, li) => ({ l, li }))
|
|
15092
|
+
.filter(({ l }) => isText$1(l) && (l.kind === LayoutLayerKind.Word || l.size === LayoutSize.Screen || l.size === LayoutSize.Xxl))
|
|
15093
|
+
.map(({ li }) => li);
|
|
15094
|
+
}
|
|
15095
|
+
/**
|
|
15096
|
+
* The opening's lead set as its display (a word) where it can be: a heading of at most `xl`'s characters. Its size goes
|
|
15097
|
+
* up to xl where it still fits there. Null: no such lead.
|
|
15098
|
+
*/
|
|
15099
|
+
function layoutOpeningDisplayMend(page) {
|
|
15100
|
+
const first = page.sections?.[0];
|
|
15101
|
+
if (!first || first.readyMade)
|
|
15102
|
+
return null;
|
|
15103
|
+
const li = (first.layers ?? []).findIndex(l => l.role === LayoutRole.Lead && l.kind === LayoutLayerKind.Heading);
|
|
15104
|
+
if (li < 0)
|
|
15105
|
+
return null;
|
|
15106
|
+
const lead = first.layers[li];
|
|
15107
|
+
if (textOf$2(lead).length > L$1.maxChars.xl)
|
|
15108
|
+
return null;
|
|
15109
|
+
const small = lead.size !== LayoutSize.Xl && lead.size !== LayoutSize.Xxl;
|
|
15110
|
+
return small && layoutTextFits(lead, first, LayoutSize.Xl) ? { layer: li, size: LayoutSize.Xl } : { layer: li };
|
|
15111
|
+
}
|
|
15112
|
+
|
|
14834
15113
|
/** The design a page wears when only its look's preset is known: the preset in `mode` (else its own), else the default. */
|
|
14835
15114
|
function layoutDesignOf(presetId, mode) {
|
|
14836
15115
|
const id = String(presetId ?? '');
|
|
@@ -14950,6 +15229,8 @@ const GALLERY_SPEED = 900;
|
|
|
14950
15229
|
const GALLERY_STACKED_ASPECT = '4 / 5';
|
|
14951
15230
|
const FULL = '100%';
|
|
14952
15231
|
const ZERO$1 = '0px';
|
|
15232
|
+
/** A rule's line: the looks' hairline. */
|
|
15233
|
+
const RULE_PX = '1px';
|
|
14953
15234
|
const PHONE_GROUND_BRIGHTNESS = '0.75';
|
|
14954
15235
|
const GALLERY_BAR_TOP = '12px';
|
|
14955
15236
|
const STRETCH_KINDS = new Set([LayoutLayerKind.Photo, LayoutLayerKind.Shape, LayoutLayerKind.Gallery, LayoutLayerKind.Form]);
|
|
@@ -15377,10 +15658,20 @@ function buttonLayer(id, l, ctx) {
|
|
|
15377
15658
|
* scheme re-declares those tokens for that band; on the page's own ground (or the soft one) they wear none. */
|
|
15378
15659
|
const BAND_SCHEME_ON = {
|
|
15379
15660
|
[LayoutColour.Ink]: ColorScheme.Inverse,
|
|
15380
|
-
[LayoutColour.Muted]: ColorScheme.
|
|
15661
|
+
[LayoutColour.Muted]: ColorScheme.Muted,
|
|
15381
15662
|
[LayoutColour.Accent]: ColorScheme.Accent,
|
|
15382
15663
|
};
|
|
15383
|
-
/**
|
|
15664
|
+
/** A wrapper that adds no box (`display: contents` — its children keep their place in the grid) and re-declares the band's
|
|
15665
|
+
* tokens for them: a ready-made section's content, a button on a band. */
|
|
15666
|
+
function bandColours(id, scheme, children) {
|
|
15667
|
+
const band = create$1(id, T.Container, {}, NO_ELEMENT_STYLE);
|
|
15668
|
+
band.label = 'band colours';
|
|
15669
|
+
setStyleProps(band, { display: 'contents' });
|
|
15670
|
+
setColorScheme(band, scheme);
|
|
15671
|
+
band.children = children;
|
|
15672
|
+
return band;
|
|
15673
|
+
}
|
|
15674
|
+
/** The scheme a form, a gallery, a button or a ready-made section's content on this section ground wears, or null on the page's own ground. */
|
|
15384
15675
|
function layoutBandScheme(ground) {
|
|
15385
15676
|
return BAND_SCHEME_ON[(ground ?? LayoutColour.Ground)] ?? null;
|
|
15386
15677
|
}
|
|
@@ -15475,6 +15766,10 @@ function composeLayer(l, lc, ctx) {
|
|
|
15475
15766
|
}
|
|
15476
15767
|
outer.label = `${lc.section.id} · ${l.kind}${l.role ? ` (${l.role})` : ''}`;
|
|
15477
15768
|
place(outer, l, lc, ctx);
|
|
15769
|
+
// A rule is a line against the words it belongs to, never its row's full height (the bar's grey boxes, M8 demo).
|
|
15770
|
+
if (l.kind === LayoutLayerKind.Shape && isLayoutRule(lc.section, lc.li)) {
|
|
15771
|
+
setStyleProps(outer, { height: RULE_PX, alignSelf: layoutRuleEdge(lc.section, lc.li), borderRadius: ZERO$1 });
|
|
15772
|
+
}
|
|
15478
15773
|
// Held: the layer moves by tracks; a kinetic heading lights word by word as the section is read.
|
|
15479
15774
|
const tracks = [];
|
|
15480
15775
|
if (lc.held) {
|
|
@@ -15509,7 +15804,10 @@ function composeLayer(l, lc, ctx) {
|
|
|
15509
15804
|
}
|
|
15510
15805
|
if (interactions.length)
|
|
15511
15806
|
outer.interactions = [...outer.interactions, ...interactions];
|
|
15512
|
-
|
|
15807
|
+
// A button draws its ink from the page's button tokens: on a band they must be the band's, or a text button on the ink
|
|
15808
|
+
// (or the muted) band is the ground's own colour — the bar's "See the whole menu" (M8 gate 2, iox-ui#70).
|
|
15809
|
+
const scheme = l.kind === LayoutLayerKind.Button ? layoutBandScheme(lc.section.ground) : null;
|
|
15810
|
+
return scheme ? bandColours(`${outer.id}-band`, scheme, [outer]) : outer;
|
|
15513
15811
|
}
|
|
15514
15812
|
// ── Sections ────────────────────────────────────────────────────────────────────────────────────────────
|
|
15515
15813
|
function transitionOf(s, prev, ctx, si) {
|
|
@@ -15635,7 +15933,7 @@ function composeHeader(ctx) {
|
|
|
15635
15933
|
gap(ctx, LayoutGapCode.SectionLink, 'nav', 'section links scroll by an action, with no #address');
|
|
15636
15934
|
const pages = [{ name: ctx.site.name, route: NAV_ROUTE, isHome: true }, ...links.map(link => ({ name: link.label, route: `/${link.to}` }))];
|
|
15637
15935
|
let n = 0;
|
|
15638
|
-
const { header } = composeNavHeader({ business: { name: ctx.site.name }, pages }, { id: `${ctx.p}-nav`, newId: suffix => `${ctx.p}-nav-${++n}-${suffix}` });
|
|
15936
|
+
const { header } = composeNavHeader({ business: { name: ctx.site.name }, pages, locale: ctx.site.locale }, { id: `${ctx.p}-nav`, newId: suffix => `${ctx.p}-nav-${++n}-${suffix}` });
|
|
15639
15937
|
if (ctx.rtl)
|
|
15640
15938
|
setStyleProps(header, { textDirection: 'rtl' });
|
|
15641
15939
|
let drawer;
|
|
@@ -15668,6 +15966,67 @@ function wireLinks(ctx) {
|
|
|
15668
15966
|
node.interactions = [...node.interactions, { id: `${node.id}-to`, trigger: 'click', actions }];
|
|
15669
15967
|
}
|
|
15670
15968
|
}
|
|
15969
|
+
// ── A ready-made section among composed ones (vectoriox/iox-ui#69) ───────────────────────────────────────
|
|
15970
|
+
/** The pattern's own section padding: its ground's rhythm above and below, the pattern's gutter at the sides. */
|
|
15971
|
+
const PATTERN_SECTION_PAD = 'var(--iox-section-pad)';
|
|
15972
|
+
const PATTERN_SECTION_SPACE = 'var(--iox-space-section)';
|
|
15973
|
+
/** The furthest in a ready-made section's words start: the column grid keeps at least eight columns for them. */
|
|
15974
|
+
const READY_MADE_MAX_COLUMN = 3;
|
|
15975
|
+
/** The ground a section paints, by name (a photo ground reads as the ink: its words are light). */
|
|
15976
|
+
function groundOf(s) {
|
|
15977
|
+
const ground = String(s.ground ?? LayoutColour.Ground);
|
|
15978
|
+
return ground.startsWith('photo:') ? LayoutColour.Ink : ground;
|
|
15979
|
+
}
|
|
15980
|
+
/** The composed section a ready-made place stands beside: the one it follows, or for an opening the one after it; null
|
|
15981
|
+
* when the page has no composed section. */
|
|
15982
|
+
function readyMadeNeighbour(sections, si) {
|
|
15983
|
+
for (let i = si - 1; i >= 0; i--)
|
|
15984
|
+
if (!sections[i].readyMade)
|
|
15985
|
+
return sections[i];
|
|
15986
|
+
for (let i = si + 1; i < sections.length; i++)
|
|
15987
|
+
if (!sections[i].readyMade)
|
|
15988
|
+
return sections[i];
|
|
15989
|
+
return null;
|
|
15990
|
+
}
|
|
15991
|
+
/** The column a ready-made section's words start on: where its neighbour's words start (their first column), so the two
|
|
15992
|
+
* share an edge; at most READY_MADE_MAX_COLUMN; 1 (the gutter) when the neighbour has no words. */
|
|
15993
|
+
function readyMadeColumn(neighbour) {
|
|
15994
|
+
const starts = (neighbour?.layers ?? []).filter(l => LAYOUT_TEXT_KINDS.has(l.kind) && Array.isArray(l.col)).map(l => l.col[0]);
|
|
15995
|
+
return Math.min(READY_MADE_MAX_COLUMN, Math.max(1, starts.length ? Math.min(...starts) : 1));
|
|
15996
|
+
}
|
|
15997
|
+
/** Where column `n` starts from the page's edge, on the composed sections' own grid (`gridLayout`): the gutter, then
|
|
15998
|
+
* n - 1 columns and their gaps. */
|
|
15999
|
+
function columnInset(n) {
|
|
16000
|
+
if (n <= 1)
|
|
16001
|
+
return LAYOUT_GUTTER;
|
|
16002
|
+
const column = `((100% - 2 * ${LAYOUT_GUTTER} - ${GRID_COLUMNS - 1} * ${LAYOUT_COLUMN_GAP}) / ${GRID_COLUMNS} + ${LAYOUT_COLUMN_GAP})`;
|
|
16003
|
+
return `calc(${LAYOUT_GUTTER} + ${n - 1} * ${column})`;
|
|
16004
|
+
}
|
|
16005
|
+
/** A pattern that paints its own ground — a Scene, or a picture behind its words — keeps its colours. */
|
|
16006
|
+
function paintsItsOwnGround(root) {
|
|
16007
|
+
return root.role === SceneRole.Scene || (root.children ?? []).some(c => c.styleProps?.['position'] === 'absolute');
|
|
16008
|
+
}
|
|
16009
|
+
/**
|
|
16010
|
+
* iox-ui#69: a ready-made section reads as the same hand as the composed sections around it. It paints the ground it
|
|
16011
|
+
* follows with the composed sections' own paint (the page's tokens on the section), its content wears that band's
|
|
16012
|
+
* colour scheme in a wrapper that adds no box (`display: contents` — the pattern's layout is untouched, its tokens
|
|
16013
|
+
* re-resolve), and its words start on the layout's column instead of the pattern's gutter; on a phone, the composed
|
|
16014
|
+
* sections' gutter. A pattern that paints its own ground keeps its colours.
|
|
16015
|
+
*/
|
|
16016
|
+
function dressReadyMade(root, ground, column) {
|
|
16017
|
+
if (root.styleProps?.['padding'] === PATTERN_SECTION_PAD) {
|
|
16018
|
+
setStyleProps(root, { padding: `${PATTERN_SECTION_SPACE} ${columnInset(column)}` });
|
|
16019
|
+
phone(root, { padding: `${PATTERN_SECTION_SPACE} ${LAYOUT_GUTTER}` });
|
|
16020
|
+
}
|
|
16021
|
+
if (ground === null || paintsItsOwnGround(root))
|
|
16022
|
+
return;
|
|
16023
|
+
setColorScheme(root, ColorScheme.Default);
|
|
16024
|
+
setStyleProps(root, { backgroundColor: groundPaint(ground) });
|
|
16025
|
+
const scheme = layoutBandScheme(ground);
|
|
16026
|
+
if (!scheme || !root.children?.length)
|
|
16027
|
+
return;
|
|
16028
|
+
root.children = [bandColours(`${root.id}-band`, scheme, root.children)];
|
|
16029
|
+
}
|
|
15671
16030
|
/**
|
|
15672
16031
|
* A layout-language page → its layout and header. Deterministic: the same layout composes to byte-identical nodes.
|
|
15673
16032
|
* Refuses (ComposeError) a link to a section the layout does not have; everything the product cannot say comes back in
|
|
@@ -15700,13 +16059,15 @@ function composeLayout(site, options) {
|
|
|
15700
16059
|
if (!options.readyMade)
|
|
15701
16060
|
throw new ComposeError(`sections[${si}]: a ready-made place needs its plan section stamped (options.readyMade)`);
|
|
15702
16061
|
const node = options.readyMade(s, `${ctx.p}-s${si}`);
|
|
16062
|
+
const neighbour = readyMadeNeighbour(site.sections, si);
|
|
16063
|
+
const ground = neighbour ? groundOf(neighbour) : null;
|
|
16064
|
+
dressReadyMade(node, ground, readyMadeColumn(neighbour));
|
|
15703
16065
|
ctx.sections[s.id] = node.id;
|
|
15704
|
-
prev = LayoutColour.Ground;
|
|
16066
|
+
prev = paintsItsOwnGround(node) || ground === null ? LayoutColour.Ground : ground;
|
|
15705
16067
|
return node;
|
|
15706
16068
|
}
|
|
15707
16069
|
const node = composeSection$1(s, si, prev, ctx);
|
|
15708
|
-
|
|
15709
|
-
prev = ground.startsWith('photo:') ? LayoutColour.Ink : ground;
|
|
16070
|
+
prev = groundOf(s);
|
|
15710
16071
|
return node;
|
|
15711
16072
|
});
|
|
15712
16073
|
const header = composeHeader(ctx);
|
|
@@ -15915,6 +16276,10 @@ function nonEmpty$2(v) {
|
|
|
15915
16276
|
function fillVariables(text, ctx) {
|
|
15916
16277
|
return text.replace(TEXT_VARIABLE, (_m, name) => (name === 'year' ? String(ctx.year) : ctx.plan.business.name));
|
|
15917
16278
|
}
|
|
16279
|
+
/** A pattern node's own words in the site's language: its Hebrew on a Hebrew site when the contract gives one. */
|
|
16280
|
+
function ownWords(pn, locale) {
|
|
16281
|
+
return locale === SiteLocale.He && pn.textHe ? pn.textHe : pn.text;
|
|
16282
|
+
}
|
|
15918
16283
|
/** Where a node's words come from: the plan's slot → the business → the customer's fact → the pattern's
|
|
15919
16284
|
* own text. A missing fact shows its label and is a placeholder; nothing is ever made up. */
|
|
15920
16285
|
function chooseText(pn, ctx) {
|
|
@@ -15931,7 +16296,7 @@ function chooseText(pn, ctx) {
|
|
|
15931
16296
|
const given = ctx.plan.business.facts?.[fact];
|
|
15932
16297
|
return nonEmpty$2(given) ? { value: given } : { value: SITE_FACT_LABELS[fact], placeholder: { kind: PlaceholderKind.Fact, fact } };
|
|
15933
16298
|
}
|
|
15934
|
-
const own = pn.text === undefined ? undefined : fillVariables(pn.
|
|
16299
|
+
const own = pn.text === undefined ? undefined : fillVariables(ownWords(pn, ctx.plan.locale), ctx);
|
|
15935
16300
|
if (pn.ph === PatternPlaceholder.Copy)
|
|
15936
16301
|
return { value: own, placeholder: { kind: PlaceholderKind.Copy } };
|
|
15937
16302
|
if (pn.ph === PatternPlaceholder.Price)
|
|
@@ -16931,9 +17296,10 @@ function composeSite(plan, context) {
|
|
|
16931
17296
|
const pages = plan.pages.map(page => {
|
|
16932
17297
|
const nextAlias = page.routeSource ? nextSourceOf(relatives, page.routeSource) : null;
|
|
16933
17298
|
if (page.layout) {
|
|
17299
|
+
const opening = layoutBandScheme(page.layout.sections[0]?.ground);
|
|
16934
17300
|
return {
|
|
16935
17301
|
key: page.key, name: page.name, route: { path: page.route }, isHome: page.isHome === true, status: STATUS_DRAFT, locale,
|
|
16936
|
-
pageSettings: { designSystem: true, layoutSource: { pageKey: page.key } }, seo: composePageSeo(page, plan),
|
|
17302
|
+
pageSettings: { designSystem: true, layoutSource: { pageKey: page.key }, ...(opening ? { opening } : {}) }, seo: composePageSeo(page, plan),
|
|
16937
17303
|
layout: composeLayoutPage(page, page.layout, plan, context, design, placeholders, (section, id) => composePattern(patternById(section.pattern), id, { ...base, owner: page.key, page, section, nextAlias }, { level: section.enter ?? design.animate ?? null, rtl })),
|
|
16938
17304
|
};
|
|
16939
17305
|
}
|
|
@@ -16942,6 +17308,7 @@ function composeSite(plan, context) {
|
|
|
16942
17308
|
const motion = { level: section.enter ?? design.animate ?? null, rtl };
|
|
16943
17309
|
return composePattern(pattern, `${page.key}-${i}`, { ...base, owner: page.key, page, section, nextAlias }, motion);
|
|
16944
17310
|
});
|
|
17311
|
+
const opening = colorSchemeClass(layout[0]?.props?.[COLOR_SCHEME_TRAIT]) ? layout[0].props[COLOR_SCHEME_TRAIT] : null;
|
|
16945
17312
|
return {
|
|
16946
17313
|
key: page.key,
|
|
16947
17314
|
name: page.name,
|
|
@@ -16949,7 +17316,7 @@ function composeSite(plan, context) {
|
|
|
16949
17316
|
isHome: page.isHome === true,
|
|
16950
17317
|
status: STATUS_DRAFT,
|
|
16951
17318
|
locale,
|
|
16952
|
-
pageSettings: { designSystem: true },
|
|
17319
|
+
pageSettings: { designSystem: true, ...(opening ? { opening } : {}) },
|
|
16953
17320
|
seo: composePageSeo(page, plan),
|
|
16954
17321
|
layout,
|
|
16955
17322
|
};
|
|
@@ -17023,7 +17390,7 @@ function composeNavHeader(input, options) {
|
|
|
17023
17390
|
const all = navPagePlans(input.pages);
|
|
17024
17391
|
const navRoutes = new Set(siteNavPages(input.pages).map(p => p.route));
|
|
17025
17392
|
const pages = all.map(p => ({ ...p, inNav: navRoutes.has(p.route) }));
|
|
17026
|
-
const plan = { business: input.business, pages, dataSources: [], contentTypes: [] };
|
|
17393
|
+
const plan = { business: input.business, pages, dataSources: [], contentTypes: [], locale: input.locale };
|
|
17027
17394
|
const email = nonEmpty$2(input.business.facts?.email) ? input.business.facts.email.trim() : null;
|
|
17028
17395
|
const issues = [];
|
|
17029
17396
|
const ctx = {
|
|
@@ -18923,7 +19290,7 @@ function writtenTexts(plan) {
|
|
|
18923
19290
|
});
|
|
18924
19291
|
return out;
|
|
18925
19292
|
}
|
|
18926
|
-
const HEBREW
|
|
19293
|
+
const HEBREW = /[-]/;
|
|
18927
19294
|
/** Hebrew joins up to two one-letter words (and, the, in, to, from, that, as) to the next: "והטוב" holds "טוב". The
|
|
18928
19295
|
* ONE rule — the intake's keyword match (harness-core) uses it too. */
|
|
18929
19296
|
const HEBREW_PREFIXES = '[והבלמשכ]{0,2}';
|
|
@@ -18932,7 +19299,7 @@ const normalise = (s) => s.normalize('NFKC').toLowerCase();
|
|
|
18932
19299
|
/** A word (or phrase) as a whole-word pattern; Hebrew allows its one-letter prefixes. */
|
|
18933
19300
|
function wordPattern(word) {
|
|
18934
19301
|
const w = escape(normalise(word.trim())).replace(/\s+/g, '\\s+');
|
|
18935
|
-
const prefix = HEBREW
|
|
19302
|
+
const prefix = HEBREW.test(word) ? HEBREW_PREFIXES : '';
|
|
18936
19303
|
return new RegExp(`(?<![\\p{L}\\p{N}])${prefix}${w}(?![\\p{L}\\p{N}])`, 'u');
|
|
18937
19304
|
}
|
|
18938
19305
|
/** What a fact looks like when a model writes one — each judged against the owner's facts. */
|
|
@@ -19622,45 +19989,97 @@ var StockSlotKind;
|
|
|
19622
19989
|
/** The image field of a marked sample item. */
|
|
19623
19990
|
StockSlotKind["Item"] = "item";
|
|
19624
19991
|
})(StockSlotKind || (StockSlotKind = {}));
|
|
19625
|
-
|
|
19626
|
-
|
|
19627
|
-
|
|
19992
|
+
const ownPhotoOf = (photo) => (typeof photo === 'string' ? { url: photo } : photo);
|
|
19993
|
+
/** A title word counts this much more than any other word the item and the photo share. */
|
|
19994
|
+
const OWN_NAMED_POINTS = 10;
|
|
19995
|
+
/** Without its name, this many of the item's words must be in the photo's. */
|
|
19996
|
+
const OWN_SHARED_MIN = 2;
|
|
19997
|
+
/**
|
|
19998
|
+
* How well an owner's photo stands under a sample item (M8 demo: the bar's room photos stood under "Martini" and
|
|
19999
|
+
* "Negroni"): its words name the item, or share at least two of the item's words. 0 — it does not; a photo with no words
|
|
20000
|
+
* never does.
|
|
20001
|
+
*/
|
|
20002
|
+
function ownPhotoFit(photo, subject, words) {
|
|
20003
|
+
const has = new Set(stockWords(photo.words));
|
|
20004
|
+
if (!has.size)
|
|
20005
|
+
return 0;
|
|
20006
|
+
const named = subject.filter(w => has.has(w)).length;
|
|
20007
|
+
const shared = words.filter(w => has.has(w)).length;
|
|
20008
|
+
return named ? OWN_NAMED_POINTS * named + shared : shared >= OWN_SHARED_MIN ? shared : 0;
|
|
20009
|
+
}
|
|
20010
|
+
/** The owner's photos that fit an item, best first (their order breaks a tie). */
|
|
20011
|
+
function ownPhotosFor(photos, subject, words) {
|
|
20012
|
+
return photos.map((photo, i) => ({ photo, i, fit: ownPhotoFit(photo, subject, words) }))
|
|
20013
|
+
.filter(f => f.fit > 0)
|
|
20014
|
+
.sort((a, b) => b.fit - a.fit || a.i - b.i)
|
|
20015
|
+
.map(f => f.photo);
|
|
20016
|
+
}
|
|
20017
|
+
/**
|
|
20018
|
+
* The owner's photos come before any stock or sample picture. A composed section's empty picture takes them in order and
|
|
20019
|
+
* never repeats one. A sample item takes only one that shows it (`ownPhotoFit`), never twice in one type's samples; an
|
|
20020
|
+
* item none fits keeps its sample picture or goes on to the library (`rest`) — never an unrelated photo under its name.
|
|
20021
|
+
*/
|
|
20022
|
+
function planOwnPhotos(slots, photos) {
|
|
20023
|
+
const own = photos.map(ownPhotoOf).filter(p => !!p.url);
|
|
20024
|
+
if (!own.length)
|
|
19628
20025
|
return { placements: [], rest: [...slots] };
|
|
19629
20026
|
const placements = [];
|
|
19630
20027
|
const rest = [];
|
|
20028
|
+
const shown = new Map();
|
|
19631
20029
|
let next = 0;
|
|
19632
20030
|
for (const slot of slots) {
|
|
19633
20031
|
if (slot.kind === StockSlotKind.Section) {
|
|
19634
|
-
if (next <
|
|
19635
|
-
placements.push({ nodeId: slot.nodeId, owner: slot.owner, url:
|
|
20032
|
+
if (next < own.length)
|
|
20033
|
+
placements.push({ nodeId: slot.nodeId, owner: slot.owner, url: own[next++].url });
|
|
19636
20034
|
else
|
|
19637
20035
|
rest.push(slot);
|
|
20036
|
+
continue;
|
|
19638
20037
|
}
|
|
19639
|
-
|
|
19640
|
-
|
|
20038
|
+
const group = shown.get(slot.contentType) ?? new Set();
|
|
20039
|
+
const best = ownPhotosFor(own.filter(p => !group.has(p.url)), slot.subject ?? [], slot.words)[0];
|
|
20040
|
+
if (!best) {
|
|
20041
|
+
rest.push(slot);
|
|
20042
|
+
continue;
|
|
19641
20043
|
}
|
|
20044
|
+
group.add(best.url);
|
|
20045
|
+
shown.set(slot.contentType, group);
|
|
20046
|
+
placements.push({ item: { contentType: slot.contentType, index: slot.index, field: slot.field }, url: best.url });
|
|
19642
20047
|
}
|
|
19643
20048
|
return { placements, rest };
|
|
19644
20049
|
}
|
|
19645
|
-
/**
|
|
19646
|
-
|
|
19647
|
-
|
|
20050
|
+
/**
|
|
20051
|
+
* Each marked sample's gallery shows the owner's photos that fit the item (`ownPhotoFit`) instead of bundled samples; an
|
|
20052
|
+
* item none fits keeps its samples.
|
|
20053
|
+
*/
|
|
20054
|
+
function applyOwnPhotoGalleries(plan, items, photos) {
|
|
20055
|
+
const own = photos.map(ownPhotoOf).filter(p => !!p.url);
|
|
20056
|
+
if (!own.length)
|
|
19648
20057
|
return 0;
|
|
19649
20058
|
let changed = 0;
|
|
19650
20059
|
for (const type of plan.contentTypes) {
|
|
19651
20060
|
const field = roleField(type, ContentRole.Gallery);
|
|
19652
20061
|
if (!field)
|
|
19653
20062
|
continue;
|
|
19654
|
-
(items[type.name] ?? []).forEach(
|
|
20063
|
+
(items[type.name] ?? []).forEach(item => {
|
|
19655
20064
|
const list = item[field];
|
|
19656
20065
|
if (!item['isSample'] || !Array.isArray(list))
|
|
19657
20066
|
return;
|
|
19658
|
-
|
|
20067
|
+
const { subject, words } = itemWords(type, item);
|
|
20068
|
+
const fitting = ownPhotosFor(own, subject, words);
|
|
20069
|
+
if (!fitting.length)
|
|
20070
|
+
return;
|
|
20071
|
+
let next = 0;
|
|
20072
|
+
item[field] = list.map(value => (parseSampleImageRef(value) === null ? value : fitting[next++ % fitting.length].url));
|
|
19659
20073
|
changed++;
|
|
19660
20074
|
});
|
|
19661
20075
|
}
|
|
19662
20076
|
return changed;
|
|
19663
20077
|
}
|
|
20078
|
+
/** A sample item's words: its name (`title`) and everything that says what it is (the type's label and name, its summary). */
|
|
20079
|
+
function itemWords(type, item) {
|
|
20080
|
+
const title = item[roleField(type, ContentRole.Title) ?? ''];
|
|
20081
|
+
return { subject: stockWords(title), words: stockWords(type.label, type.name, title, item[roleField(type, ContentRole.Summary) ?? '']) };
|
|
20082
|
+
}
|
|
19664
20083
|
/** Where a photo may not appear twice: one page; one content type's samples (a list shows them together). */
|
|
19665
20084
|
function stockGroupOf(target) {
|
|
19666
20085
|
return target.kind === StockSlotKind.Section ? `page:${target.owner}` : `items:${target.contentType}`;
|
|
@@ -19720,11 +20139,11 @@ function stockItemSlots(plan, composed) {
|
|
|
19720
20139
|
const field = roleField(type, ContentRole.Image);
|
|
19721
20140
|
if (!field)
|
|
19722
20141
|
continue;
|
|
19723
|
-
const words = (item) => [type.label, type.name, ...[ContentRole.Title, ContentRole.Summary].map(r => item[roleField(type, r) ?? ''])];
|
|
19724
20142
|
(composed.items[type.name] ?? []).forEach((item, index) => {
|
|
19725
20143
|
if (!item.isSample || parseSampleImageRef(item[field]) === null)
|
|
19726
20144
|
return;
|
|
19727
|
-
|
|
20145
|
+
const { subject, words } = itemWords(type, item);
|
|
20146
|
+
out.push({ kind: StockSlotKind.Item, contentType: type.name, index, field, intent: StockIntent.Product, aspect: STOCK_ITEM_ASPECT, words, subject });
|
|
19728
20147
|
});
|
|
19729
20148
|
}
|
|
19730
20149
|
return out;
|
|
@@ -20799,14 +21218,29 @@ const phraseOf = (text) => {
|
|
|
20799
21218
|
};
|
|
20800
21219
|
/** The fewest words a text needs to count as said twice — a two-word label ("The room") may well appear twice. */
|
|
20801
21220
|
const REPEAT_MIN_WORDS = 3;
|
|
21221
|
+
/** The share of the shorter text's words the longer one holds for the two to be the same sentence said twice: one word
|
|
21222
|
+
* changed is still a repeat (the café's quote, "…וחברים צריכים שולחן" and "…וחברים טובים צריכים שולחן"). */
|
|
21223
|
+
const REPEAT_SHARED = 0.8;
|
|
21224
|
+
/** Whether two texts say the same thing: one inside the other, or the shorter's words (function words aside) nearly all
|
|
21225
|
+
* in the longer. */
|
|
21226
|
+
function sameSaying(a, b) {
|
|
21227
|
+
if (a.phrase.includes(b.phrase) || b.phrase.includes(a.phrase))
|
|
21228
|
+
return true;
|
|
21229
|
+
const [short, long] = [new Set(wordsOf$1(a.text)), new Set(wordsOf$1(b.text))].sort((x, y) => x.size - y.size);
|
|
21230
|
+
if (short.size < REPEAT_MIN_WORDS)
|
|
21231
|
+
return false;
|
|
21232
|
+
return [...short].filter(w => long.has(w)).length / short.size >= REPEAT_SHARED;
|
|
21233
|
+
}
|
|
20802
21234
|
/**
|
|
20803
21235
|
* Whether the plan section would say again what the sections the model kept already say (iox-ui#68): a title or a text of
|
|
20804
|
-
* its slots found inside a kept layer's words, or a kept layer's words found inside it
|
|
21236
|
+
* its slots found inside a kept layer's words, or a kept layer's words found inside it, or the two the same sentence
|
|
21237
|
+
* with a word changed — each of three words or more.
|
|
20805
21238
|
*/
|
|
20806
21239
|
function repeatsKept(plan, kept) {
|
|
20807
|
-
const
|
|
20808
|
-
|
|
20809
|
-
|
|
21240
|
+
const long = (text) => ({ ...phraseOf(text), text });
|
|
21241
|
+
const said = kept.flatMap(s => (s.layers ?? []).flatMap(layerTexts)).map(long).filter(p => p.words >= REPEAT_MIN_WORDS);
|
|
21242
|
+
return Object.values(plan.slots ?? {}).map(long).filter(p => p.words >= REPEAT_MIN_WORDS)
|
|
21243
|
+
.some(slot => said.some(k => sameSaying(slot, k)));
|
|
20810
21244
|
}
|
|
20811
21245
|
/** How well a ready-made section stands for a model's section: the same list, the form, the words they share. */
|
|
20812
21246
|
function fitScore(section, plan) {
|
|
@@ -21141,22 +21575,16 @@ function layoutPresetColours(presetId, mode) {
|
|
|
21141
21575
|
return presetPaint(presetId, mode)?.colours ?? null;
|
|
21142
21576
|
}
|
|
21143
21577
|
// ── Geometry ────────────────────────────────────────────────────────────────────────────────────────────
|
|
21144
|
-
/**
|
|
21145
|
-
* The laptop the estimates are made on (the render check's 1440 × 900). A grid column is taken as 1440 / 12 px and a row
|
|
21146
|
-
* as its section's screens × 900 / rows (a held section's grid is its one-screen stage): the gutter and the column gaps
|
|
21147
|
-
* are left out, so a box reads about a fifth wider than it renders — the render check measures the real one.
|
|
21148
|
-
*/
|
|
21149
|
-
const LAYOUT_CHECK_VIEWPORT = { width: 1440, height: 900 };
|
|
21150
21578
|
const GRID = 12;
|
|
21151
21579
|
const COLUMN_PX = LAYOUT_CHECK_VIEWPORT.width / GRID;
|
|
21152
|
-
/** A line of words stands its size × this tall. */
|
|
21153
|
-
const LINE_HEIGHT = 1.2;
|
|
21154
21580
|
/** WCAG's large text (≥ 24 px): 3:1 is enough. */
|
|
21155
21581
|
const LARGE_TEXT_PX = 24;
|
|
21156
21582
|
const CONTRAST_LARGE = 3;
|
|
21157
21583
|
const CONTRAST_BODY = 4.5;
|
|
21158
21584
|
/** The prototype's numbers the contract does not carry yet. */
|
|
21159
21585
|
const TRACK_SCALE_MAX = 1.3;
|
|
21586
|
+
/** A section that holds the page: held two screens or more, or sideways. */
|
|
21587
|
+
const isHold = (s) => !!s.pin && (s.screens >= 2 || (s.track ?? 1) > 1);
|
|
21160
21588
|
const INNER_MAX = 3;
|
|
21161
21589
|
const BEAT_MAX = 5;
|
|
21162
21590
|
const POP_WORDS = 3;
|
|
@@ -21168,7 +21596,6 @@ const START_CLIP_MIN = 40;
|
|
|
21168
21596
|
const HIDDEN_CLIP = 30;
|
|
21169
21597
|
/** A button or section that reads as a way to reach the business (the prototype's words, English and Hebrew). */
|
|
21170
21598
|
const CONTACT_WORDS = /contact|book|reserve|visit|table|sign.?up|enquir|צור|הזמ|קשר|שולחן|ביקור|הרשמ/i;
|
|
21171
|
-
const HEBREW = /[-]/;
|
|
21172
21599
|
const LATIN_SENTENCE = /[A-Za-z]{3,}(\s+[A-Za-z]{3,}){2,}/;
|
|
21173
21600
|
const NUMBER_GIVEN = /\d[\d:.,]{2,}|[$₪€£]\s?\d+/g;
|
|
21174
21601
|
const CHIP_NUMBER = /\d{2,}|[$₪€£]/;
|
|
@@ -21191,11 +21618,7 @@ const groundPhotoOf = (s) => (String(s.ground ?? '').startsWith(PHOTO_GROUND) ?
|
|
|
21191
21618
|
const isText = (l) => LAYOUT_TEXT_KINDS.has(l.kind);
|
|
21192
21619
|
const isPictured = (l) => l.kind === LayoutLayerKind.Photo || l.kind === LayoutLayerKind.Gallery;
|
|
21193
21620
|
const contrastOf = (a, b) => (Math.max(a, b) + 0.05) / (Math.min(a, b) + 0.05);
|
|
21194
|
-
|
|
21195
|
-
function boxPx(col, row, s) {
|
|
21196
|
-
const height = (s.pin ? 1 : s.screens) * LAYOUT_CHECK_VIEWPORT.height;
|
|
21197
|
-
return { w: span(col) * COLUMN_PX, h: (span(row) * height) / Math.max(1, s.rows) };
|
|
21198
|
-
}
|
|
21621
|
+
const boxPx = layoutBoxPx;
|
|
21199
21622
|
/** A section of one photo on one side and words on the other: 'start' | 'end' | null (the prototype's `splitSide`). */
|
|
21200
21623
|
function splitSide(s) {
|
|
21201
21624
|
const photos = (s.layers ?? []).filter(isPictured);
|
|
@@ -21365,6 +21788,7 @@ function examineLayout(page, ctx, carried, given) {
|
|
|
21365
21788
|
let screenWords = 0;
|
|
21366
21789
|
let wordsOnPhoto = 0;
|
|
21367
21790
|
let holds = 0;
|
|
21791
|
+
const allHolds = sections.filter(isHold).length;
|
|
21368
21792
|
let pinned = 0;
|
|
21369
21793
|
let marquees = 0;
|
|
21370
21794
|
let boxes = 0;
|
|
@@ -21417,7 +21841,7 @@ function examineLayout(page, ctx, carried, given) {
|
|
|
21417
21841
|
add(LayoutIssueCode.Structure, `${at}.layers`, 'at least one layer');
|
|
21418
21842
|
if (s.pin)
|
|
21419
21843
|
pinned++;
|
|
21420
|
-
if (
|
|
21844
|
+
if (isHold(s))
|
|
21421
21845
|
holds++;
|
|
21422
21846
|
if (i === 0 && daring && splitSide(s))
|
|
21423
21847
|
add(LayoutIssueCode.Daring, at, 'a daring page never opens on a split (photo one side, words the other) — break it');
|
|
@@ -21500,15 +21924,9 @@ function examineLayout(page, ctx, carried, given) {
|
|
|
21500
21924
|
if ((l.size === 'm' || l.size === 's') && text.length > LIM.longTextChars && span(l.col) > LIM.longTextColumns) {
|
|
21501
21925
|
add(LayoutIssueCode.Reading, `${lp}.col`, `long text is never wider than ${LIM.longTextColumns} columns`);
|
|
21502
21926
|
}
|
|
21503
|
-
if (placed && isText(l) && l.size && l.size !== 'screen' && text) {
|
|
21504
|
-
const
|
|
21505
|
-
|
|
21506
|
-
const lines = Math.floor(box.h / (px * LINE_HEIGHT));
|
|
21507
|
-
const advance = HEBREW.test(text) ? LIM.advance.hebrew : LIM.advance.latin;
|
|
21508
|
-
const items = l.kind === LayoutLayerKind.List ? Math.max(1, l.items?.length ?? 1) : 1;
|
|
21509
|
-
const fits = lines >= items && (text.length * px * advance) / Math.max(1, lines) <= box.w * LIM.textFitSlack;
|
|
21510
|
-
if (!fits)
|
|
21511
|
-
add(LayoutIssueCode.Reading, `${lp}.row`, `${text.length} characters at ${l.size} do not fit a box of ${span(l.col)} columns × ${span(l.row)} rows (about ${Math.max(0, lines)} line${lines === 1 ? '' : 's'}) — give it more rows or columns, or fewer words`);
|
|
21927
|
+
if (placed && isText(l) && l.size && l.size !== 'screen' && text && !layoutTextFits(l, s)) {
|
|
21928
|
+
const lines = Math.floor(boxPx(l.col, l.row, s).h / (L.sizePx[l.size] * LAYOUT_LINE_HEIGHT));
|
|
21929
|
+
add(LayoutIssueCode.Reading, `${lp}.row`, `${text.length} characters at ${l.size} do not fit a box of ${span(l.col)} columns × ${span(l.row)} rows (about ${Math.max(0, lines)} line${lines === 1 ? '' : 's'}) — give it more rows or columns, or fewer words`);
|
|
21512
21930
|
}
|
|
21513
21931
|
if (l.size === 'screen' || l.size === 'xxl')
|
|
21514
21932
|
huge++;
|
|
@@ -21554,6 +21972,9 @@ function examineLayout(page, ctx, carried, given) {
|
|
|
21554
21972
|
if (l.depth === 'front')
|
|
21555
21973
|
add(LayoutIssueCode.Motion, `${lp}.depth`, 'decoration never runs ahead — back or mid');
|
|
21556
21974
|
}
|
|
21975
|
+
if (l.kind === LayoutLayerKind.Shape && !layoutShapeHasPurpose(s, j)) {
|
|
21976
|
+
add(LayoutIssueCode.Look, lp, 'a shape that is there for nothing — not a rule (one row high), a band, a frame for a picture or a ground for words, and it does not move: an empty box on the page', { kind: LayoutMendKind.Drop, layer: lp });
|
|
21977
|
+
}
|
|
21557
21978
|
if (l.role === LayoutRole.Static && ((l.enter && l.enter !== LayoutEnter.None) || l.motion?.length || deep))
|
|
21558
21979
|
add(LayoutIssueCode.Motion, `${lp}.role`, 'a static layer has no enter, motion or depth');
|
|
21559
21980
|
if (l.rotate) {
|
|
@@ -21597,8 +22018,8 @@ function examineLayout(page, ctx, carried, given) {
|
|
|
21597
22018
|
if (shows.length && hides.length && Math.max(...hides) > Math.max(...shows))
|
|
21598
22019
|
add(LayoutIssueCode.Motion, `${lp}.motion`, 'it leaves more slowly than it arrived — an exit is shorter than the entrance');
|
|
21599
22020
|
if (l.kinetic) {
|
|
21600
|
-
if (
|
|
21601
|
-
add(LayoutIssueCode.Value, `${lp}.kinetic`, 'only a word or
|
|
22021
|
+
if (!LAYOUT_KINETIC_KINDS.has(l.kind))
|
|
22022
|
+
add(LayoutIssueCode.Value, `${lp}.kinetic`, 'only a word, a heading or a line of text');
|
|
21602
22023
|
if (wordsOf(l.text) > LIM.kineticWords)
|
|
21603
22024
|
add(LayoutIssueCode.Look, `${lp}.kinetic`, `${wordsOf(l.text)} words — kinetic words hold at most ${LIM.kineticWords}`);
|
|
21604
22025
|
if (!s.pin)
|
|
@@ -21773,6 +22194,15 @@ function examineLayout(page, ctx, carried, given) {
|
|
|
21773
22194
|
add(LayoutIssueCode.Content, `${lp}.text`, 'the site is Hebrew — write it in Hebrew');
|
|
21774
22195
|
}
|
|
21775
22196
|
});
|
|
22197
|
+
if (layoutHeldStill(s)) {
|
|
22198
|
+
const line = layoutStillLine(s);
|
|
22199
|
+
const photo = layoutDriftPhoto(s);
|
|
22200
|
+
// A daring page needs its holds: letting this one flow would trade the still screen for a page that holds too little.
|
|
22201
|
+
const spare = !daring || allHolds - Number(isHold(s)) >= LIM.daring.holds - carried.holds;
|
|
22202
|
+
add(LayoutIssueCode.Motion, at, 'it holds the page and nothing in it moves by the scroll — a held section plays: light its line word by word (kinetic), give a layer a track, or let it flow', line >= 0 ? { kind: LayoutMendKind.Words, layer: `${at}.layers[${line}]` }
|
|
22203
|
+
: spare ? { kind: LayoutMendKind.Unpin, section: i }
|
|
22204
|
+
: photo >= 0 ? { kind: LayoutMendKind.Drift, layer: `${at}.layers[${photo}]` } : undefined);
|
|
22205
|
+
}
|
|
21776
22206
|
if (limits.rotatedPerSectionMax !== undefined && rotated > limits.rotatedPerSectionMax)
|
|
21777
22207
|
add(LayoutIssueCode.Look, at, `${rotated} rotated layers — at most ${limits.rotatedPerSectionMax}`);
|
|
21778
22208
|
if (i === 0 && limits.firstButtonsMax !== undefined && layers.filter(l => l.kind === LayoutLayerKind.Button).length > limits.firstButtonsMax) {
|
|
@@ -21789,6 +22219,21 @@ function examineLayout(page, ctx, carried, given) {
|
|
|
21789
22219
|
}
|
|
21790
22220
|
}
|
|
21791
22221
|
});
|
|
22222
|
+
const voids = layoutVoids(sections);
|
|
22223
|
+
const voidScreens = voids.length ? layoutVoidScreens(sections) : null;
|
|
22224
|
+
for (const v of voids) {
|
|
22225
|
+
add(LayoutIssueCode.Look, `sections[${v.sections[0]}]`, `${Math.round(v.to - v.from)}px of the laptop's screen with nothing on it (${v.sections.map(i => sections[i].id).join(' → ')}) — a section that flows fills its screens: fewer screens, or layers where the eye would land`, voidScreens ? { kind: LayoutMendKind.Screens, sections: voidScreens } : undefined);
|
|
22226
|
+
}
|
|
22227
|
+
const opening = layoutOpeningDisplays(page);
|
|
22228
|
+
if ((daring || ctx.design?.animate === SCENE_LEVEL) && sections[0] && !sections[0].readyMade) {
|
|
22229
|
+
if (!opening.length) {
|
|
22230
|
+
const display = layoutOpeningDisplayMend(page);
|
|
22231
|
+
add(LayoutIssueCode.Daring, 'sections[0]', 'the opening has no display — a daring page opens on one thing set large: a word, or a heading at xxl or screen size', display ? { kind: LayoutMendKind.Display, layer: `sections[0].layers[${display.layer}]`, ...(display.size ? { size: display.size } : {}) } : undefined);
|
|
22232
|
+
}
|
|
22233
|
+
else if (opening.length > 1) {
|
|
22234
|
+
add(LayoutIssueCode.Look, 'sections[0]', `${opening.length} displays in the opening — one moment: one word or one large heading`);
|
|
22235
|
+
}
|
|
22236
|
+
}
|
|
21792
22237
|
if (ctx.first && !reachable)
|
|
21793
22238
|
add(LayoutIssueCode.Content, 'sections', 'nothing lets people reach the business — a form, or a button to one');
|
|
21794
22239
|
if (galleries < LIM.galleriesMin - carried.galleries)
|
|
@@ -22066,6 +22511,7 @@ const MEND_ROLE_ORDER = [LayoutRole.Decoration, LayoutRole.Static, undefined, La
|
|
|
22066
22511
|
*/
|
|
22067
22512
|
function mendLayout(page, issues) {
|
|
22068
22513
|
const mended = [];
|
|
22514
|
+
const drops = [];
|
|
22069
22515
|
if (!issues.some(i => i.mend))
|
|
22070
22516
|
return { page, mended };
|
|
22071
22517
|
const next = structuredClone(page);
|
|
@@ -22116,6 +22562,58 @@ function mendLayout(page, issues) {
|
|
|
22116
22562
|
layer.gallery.source = mend.source;
|
|
22117
22563
|
mended.push(issue);
|
|
22118
22564
|
}
|
|
22565
|
+
else if (mend?.kind === LayoutMendKind.Words) {
|
|
22566
|
+
const layer = layerAt(mend.layer);
|
|
22567
|
+
if (!layer)
|
|
22568
|
+
continue;
|
|
22569
|
+
layer.kinetic = true;
|
|
22570
|
+
mended.push(issue);
|
|
22571
|
+
}
|
|
22572
|
+
else if (mend?.kind === LayoutMendKind.Display) {
|
|
22573
|
+
const layer = layerAt(mend.layer);
|
|
22574
|
+
if (!layer)
|
|
22575
|
+
continue;
|
|
22576
|
+
layer.kind = LayoutLayerKind.Word;
|
|
22577
|
+
if (mend.size)
|
|
22578
|
+
layer.size = mend.size;
|
|
22579
|
+
mended.push(issue);
|
|
22580
|
+
}
|
|
22581
|
+
else if (mend?.kind === LayoutMendKind.Drift) {
|
|
22582
|
+
const layer = layerAt(mend.layer);
|
|
22583
|
+
if (!layer)
|
|
22584
|
+
continue;
|
|
22585
|
+
layer.motion = [...(layer.motion ?? []), { ...LAYOUT_DRIFT, at: [...LAYOUT_DRIFT.at] }];
|
|
22586
|
+
mended.push(issue);
|
|
22587
|
+
}
|
|
22588
|
+
else if (mend?.kind === LayoutMendKind.Unpin) {
|
|
22589
|
+
const section = next.sections?.[mend.section];
|
|
22590
|
+
if (!section)
|
|
22591
|
+
continue;
|
|
22592
|
+
section.pin = false;
|
|
22593
|
+
delete section.track;
|
|
22594
|
+
section.screens = 1;
|
|
22595
|
+
mended.push(issue);
|
|
22596
|
+
}
|
|
22597
|
+
else if (mend?.kind === LayoutMendKind.Screens) {
|
|
22598
|
+
if (mend.sections.some(m => !next.sections?.[m.section]))
|
|
22599
|
+
continue;
|
|
22600
|
+
for (const m of mend.sections)
|
|
22601
|
+
next.sections[m.section].screens = m.screens;
|
|
22602
|
+
mended.push(issue);
|
|
22603
|
+
}
|
|
22604
|
+
else if (mend?.kind === LayoutMendKind.Drop && layerAt(mend.layer)) {
|
|
22605
|
+
drops.push(issue);
|
|
22606
|
+
}
|
|
22607
|
+
}
|
|
22608
|
+
// Last, so every path above still names the layer it was found at: the empty shapes leave, the latest first.
|
|
22609
|
+
const dropAt = (i) => /^sections\[(\d+)\]\.layers\[(\d+)\]$/.exec(i.mend.layer).slice(1).map(Number);
|
|
22610
|
+
for (const issue of [...drops].sort((a, b) => dropAt(b)[0] - dropAt(a)[0] || dropAt(b)[1] - dropAt(a)[1])) {
|
|
22611
|
+
const [si, li] = dropAt(issue);
|
|
22612
|
+
const section = next.sections[si];
|
|
22613
|
+
section.layers.splice(li, 1);
|
|
22614
|
+
if (Array.isArray(section.phone))
|
|
22615
|
+
section.phone = section.phone.filter(n => n !== li).map(n => (n > li ? n - 1 : n));
|
|
22616
|
+
mended.push(issue);
|
|
22119
22617
|
}
|
|
22120
22618
|
return { page: mended.length ? next : page, mended };
|
|
22121
22619
|
}
|
|
@@ -22459,5 +22957,5 @@ function layoutRepairJsonSchema() {
|
|
|
22459
22957
|
* Generated bundle index. Do not edit.
|
|
22460
22958
|
*/
|
|
22461
22959
|
|
|
22462
|
-
export { ACTION_START_SCALE, ACTIVE_BUILD_STATUSES, AI_REFUSAL_NEXT, AI_REFUSAL_STATUS, AI_STEPS, AI_STEP_LABELS, AI_STEP_NEEDS, AI_STEP_PART_TOKENS, AI_STEP_TYPICAL_TOKENS, ART_DIRECTION_PARTS, AiCallStatus, AiCapability, AiFeature, AiGenerationStage, AiKeyMode, AiLimit, AiNextKind, AiProviderId, AiRefusalCode, AiStep, BAR_ITEMS_MAX, BAR_ITEMS_MIN, BASELINE_ROLES, BUILD_STEPS, BaselineRole, BindScope, BuildNoticeCode, BuildStep, CONTENT_ROLE_MEANINGS, CREDITS_PER_USD, CardBindTarget, CheckSeverity, ComposeError, ComposeIssueCode, ContentFieldControl, ContentFieldType, ContentRole, ContentTypeAction, CreatedKind, DANGLING_LINK_CODES, DEFAULT_PHONE_MENU_BREAKPOINT, DEFAULT_SITE_LOCALE, ENTRANCE_EASING, ENTRANCE_ORIGIN_LOOK, ENTRANCE_TRIGGER, EntrancePart, EntranceSide, FACT_KEYS, FIELD_TYPE_OF_CONTROL, FILL_ASPECT, FILM_PATTERN, FINAL_GENERATION_STAGES, FINDING_SEVERITY, FilmUnplaced, GRAMMAR_TOO_LARGE_MESSAGE, GlobalSlot, HEBREW_PREFIXES, JSON_SCHEMA_BANNED_KEYWORDS, JsonSchemaShapeError, KeptReason, LAYOUT_ACCENT_TEXT, LAYOUT_BEAT_DELAY, LAYOUT_CHECK_VIEWPORT, LAYOUT_COLOUR_TOKEN, LAYOUT_COLUMN_GAP, LAYOUT_DEPTH_ON_PHONE, LAYOUT_EASING, LAYOUT_ENTRANCE_MAX_MS, LAYOUT_FONT_SIZE, LAYOUT_GUTTER, LAYOUT_HIDDEN_OPACITY, LAYOUT_OPERATED, LAYOUT_PACE, LAYOUT_PHONE_BREAKPOINT, LAYOUT_PHONE_PADDING, LAYOUT_PHOTO_ASPECT, LAYOUT_READY_MADE_TOKEN, LAYOUT_RISE, LAYOUT_SCREEN_PX, LAYOUT_TEXT_KINDS, LAYOUT_TOOLTIP_TRAIT, LAYOUT_VIEWPORTS, LAYOUT_WIRE_AUTOPLAY_MS, LayoutAlign, LayoutBleed, LayoutButtonVariant, LayoutColour, LayoutColourMode, LayoutDepth, LayoutDial, LayoutEase, LayoutEditOp, LayoutEnter, LayoutGalleryEffect, LayoutGapCode, LayoutIssueCode, LayoutLayerKind, LayoutMendKind, LayoutNavKind, LayoutPace, LayoutPhotoShape, LayoutPhotoSource, LayoutRole, LayoutSectionKind, LayoutSequenceToken, LayoutSide, LayoutSignatureId, LayoutSize, LayoutSourceChoice, LayoutTrackProp, LayoutTransition, LayoutViewport, MAX_SITE_PICTURES, NAV_PART_LABELS, NAV_SHAPE_COPY, NEUTRAL_STYLE_PROPS, NODE_BASELINES, NO_TOKENS, NavPagesSource, NavRole, NavShape, NavShapeError, PAGE_ARCHETYPES, PHOTO_ANALYSIS_WIDTH, PHOTO_CALM_DETAIL, PHOTO_GRID, PHOTO_LIGHT_LUMINANCE, PICTURE_ASPECTS, PICTURE_NEVER, PICTURE_REAL_PLACE_FAMILIES, PICTURE_REROLL_EVERY, PICTURE_REVIEW_FORMAT, PICTURE_REVIEW_SHAPE, PICTURE_TEXT_CONTRAST, PICTURE_WORLDS, PICTURE_WORLD_IDS, PLAN_EDITS_ANSWER_SHAPES, PLAN_EDITS_PART_SCHEMA_NAMES, PLAN_EDIT_OP_PART, PLAN_EDIT_SHAPE, PLAN_EDIT_WIRE_KEYS, PLAN_PARTS, PLAN_PART_KEYS, PLAN_WIRE_DERIVED, PLAN_WIRE_PART_SCHEMA_NAMES, PLAN_WIRE_SHAPE, PRICING_PATTERN, PROOF_FINGERPRINTS, PUBLISH_BLOCKING_PLACEHOLDERS, PageDataKind, PathIssueCollector, PatternDirective, PatternGlobalPosition, PatternOpens, PatternPlaceholder, PatternRecipe, PhoneMenuBreakpoint, PhotoTone, PictureRefusal, PictureWorld, PlaceholderKind, PlanChangeAction, PlanChangeKind, PlanDataSourceMode, PlanDataSourceType, PlanEditIssueCode, PlanEditOp, PlanEditsOutcome, PlanPart, PlanWireEntry, PlanWireShapeError, PlanWordIssueCode, PreflightRefusalCode, PublishRefusalCode, RENDER_CHECK, REQUIRED_CONTENT_ROLES, RelativeOp, SAMPLE_IMAGE_REF, SCENE_LEVEL, SCENE_OTHER_PAGES, SCRIM_BACKGROUND, SCRIM_COVER, SCRIM_LEVELS, SHOWCASE_FILM, SITE_CHECKS, SITE_FACT_LABELS, SITE_HEADER_PATTERN, SITE_LIBRARY, SITE_LOCALES, SITE_NEED_IDS, SITE_PATTERNS, SITE_PLAN_VERSION, SITE_TEMPLATES, SPEC_SITE_ARCHETYPES, SPEC_SITE_COPY_LENGTHS, SPEC_SITE_DENSITY_COPY, SPEC_SITE_FACTS, SPEC_SITE_LAYOUT, SPEC_SITE_LIBRARY, SPEC_SITE_LOCALES, SPEC_SITE_NEED_IDS, SPEC_SITE_PATTERNS, SPEC_SITE_PICTURE_NEVER, SPEC_SITE_PICTURE_WORLDS, SPEC_SITE_PLAN_SHAPE, SPEC_SITE_REQUIRED_ROLES, SPEC_SITE_ROLES, SPEC_SITE_TEMPLATES, STOCK_FAMILIES, STOCK_FAMILY_INTENTS, STOCK_INTENT_ORDER, STOCK_INTENT_SUBJECTS, STOCK_ITEM_ASPECT, STOCK_MIN_KEPT, STOCK_PROVIDER_TERMS, STOCK_SEED_MARGIN, STOCK_SUBJECT_WORDS, STRICT_SCHEMA_BUDGET, STRICT_SCHEMA_LIMITS, STUDIO_TEMPLATE, ScrimLevel, SectionFallbackLastResort, SectionSwapAction, SectionSwapRule, SiteBuildKind, SiteBuildStatus, SiteCheckId, SiteFindingCode, SiteLocale, SitePlanError, SitePlanIssueCode, SitePlanSourceKind, SiteTemplateError, SiteTemplateId, StepState, StockIntent, StockOrientation, StockProviderId, StockReviewFlag, StockReviewVerdict, StockSlotKind, StockSubject, WORDS_AREA_DEFAULT_SHARE, WordsEdge, addBarItem, addStockCredits, aiStepParts, applyLayoutEdits, applyOwnPhotoGalleries, applyPictureScrims, applyPlanEdits, applyStockItemPhotos, applyStockPhotos, archetypeIssues, areaLuminance, artDirectionFor, artDirectionIssues, artDirectionPreamble, aspectRatioOf, assertStyleSlots, assertValidSitePlan, auditLayoutMotion, auditSite, barIconForRoute, blocksPublish, brandHueWord, buildKeys, buildStepFacts, builtHomePageId, calmParts, calmUnder, checkLayout, chooseScrim, composeContextOf, composeLayout, composeNavHeader, composePresetForm, composeSection, composeSite, contentTypeOfSource, contentTypePreviewFields, contentTypeToWire, copyLengthOf, costUsd, coverCrop, createSerializedNode, creditsOfUsd, dataSourceToWire, derivedBeats, derivedDataSources, describeInventoryForPrompt, describePlanData, describeShapeKey, driftAt, driftOverlap, emptyAreaPhrase, entranceAction, entranceInteraction, estimatePictures, estimateStepCredits, expandLayoutWire, expandPlanWire, expandWireContentType, expandWireDataSource, expandWireEdit, expandWireField, expandWirePage, expandWireSection, failedBuildStep, fallBackBySection, fieldToWire, filmOfPlan, filmPlacement, findNavRoot, fingerprintOf, frameWords, isActiveBuild, isNonEmptyString, isPictureWorld, isPlainObject, isRtlLocale, jsonAnyOf, jsonBoolean, jsonClosedObject, jsonInteger, jsonListOf, jsonOneOf, jsonSchemaKeywords, jsonSchemaObjects, jsonShapedObject, jsonText, judgeLayoutRender, layerShownSpans, layoutBandScheme, layoutColumnsVw, layoutDesignOf, layoutDialOf, layoutElementStyle, layoutGalleryLists, layoutGallerySources, layoutGlideDepth, layoutLookChanges, layoutLookOf, layoutMotionOf, layoutNodeClass, layoutPathSteps, layoutPhotoIds, layoutPresetColours, layoutPresetOf, layoutRepairJsonSchema, layoutRoomPx, layoutTextWidthEm, layoutToWire, layoutWireJsonSchema, luminanceOf, measureLayout, mendLayout, modelCanDo, moveBarItem, navPages, navShapeBreakpoint, navShapeOf, nextSourceOf, nodeBindPaths, orientationOfRatio, pageToWire, parseLayoutPhotoId, parsePatternPath, parseSampleImageRef, pathAt, patternById, patternHasForm, patternLinkSlots, patternListGap, patternManifest, patternNeedsBinding, patternNodes, patternOptionalParts, patternRoleNeeds, patternScopes, patternSlotBudgets, patternSlots, patternTakesBinding, phoneGapBefore, phoneMenuPages, phoneWordsColour, photoInventory, photoShapeOf, pictureAspect, picturePrompt, pictureRefusalOf, pictureRerolls, pictureReviewIssues, pictureReviewJsonSchema, pictureReviewPasses, pictureSlotKey, pictureTargets, pictureTryFits, pixelsUnder, placeFilm, planEditOps, planEditToWire, planEditWireGaps, planEditWireKeys, planEditWireOps, planEditWireShape, planEditsFromWire, planEditsJsonSchema, planEditsToWire, planEntrances, planFromTemplate, planLayoutPhotos, planNavShape, planOwnPhotos, planPartOfPath, planPartToWire, planPictures, planStockPhotos, planToWire, planWireGaps, planWirePartJsonSchema, planWirePartShape, planWordIssues, publishRefusal, publishVerdict, recipeListBinds, recomposeAsks, releasedLayoutDefaults, removeBarItem, requiredAcknowledgements, requiredShapeKeys, roleField, routeMatches, routeParams, samenessIssues, sampleImageRef, scoreStockPhoto, screenFontSize, screenWordColumns, screenWordMisfit, screenWordOverflowPx, sectionEntrances, sectionPatternIds, sectionToWire, sectionsNamed, sequenceShare, sequenceTokenOf, setStyleProps, shapeKeys, showcaseGlobals, showcasePages, showcasePlans, showcaseScenes, shownTogether, signatureOf, siteNavPages, slotBudget, splitSide, stockCopyKey, stockCreditLine, stockCreditLines, stockCreditNode, stockCreditNodeId, stockFits, stockGroupOf, stockItemSlots, stockKept, stockPhotoRatio, stockPhotoSubject, stockPhotoUsable, stockPhotoWords, stockSlots, stockWord, stockWords, strictSchemaComplexity, strictSchemaRefusal, toneOf, typicalStepTokens, validatePlanEdits, validateSitePlan, walkSerialized, wireContentTypeJsonSchema, wireDataSourceJsonSchema, wireFieldJsonSchema, wirePageJsonSchema, wireSectionJsonSchema, withDerivedSources, wordPattern, wordsOverPhotos, wordsOverPicture, writtenTexts };
|
|
22960
|
+
export { ACTION_START_SCALE, ACTIVE_BUILD_STATUSES, AI_REFUSAL_NEXT, AI_REFUSAL_STATUS, AI_STEPS, AI_STEP_LABELS, AI_STEP_NEEDS, AI_STEP_PART_TOKENS, AI_STEP_TYPICAL_TOKENS, ART_DIRECTION_PARTS, AiCallStatus, AiCapability, AiFeature, AiGenerationStage, AiKeyMode, AiLimit, AiNextKind, AiProviderId, AiRefusalCode, AiStep, BAR_ITEMS_MAX, BAR_ITEMS_MIN, BASELINE_ROLES, BUILD_STEPS, BaselineRole, BindScope, BuildNoticeCode, BuildStep, CONTENT_ROLE_MEANINGS, CREDITS_PER_USD, CardBindTarget, CheckSeverity, ComposeError, ComposeIssueCode, ContentFieldControl, ContentFieldType, ContentRole, ContentTypeAction, CreatedKind, DANGLING_LINK_CODES, DEFAULT_PHONE_MENU_BREAKPOINT, DEFAULT_SITE_LOCALE, ENTRANCE_EASING, ENTRANCE_ORIGIN_LOOK, ENTRANCE_TRIGGER, EntrancePart, EntranceSide, FACT_KEYS, FIELD_TYPE_OF_CONTROL, FILL_ASPECT, FILM_PATTERN, FINAL_GENERATION_STAGES, FINDING_SEVERITY, FilmUnplaced, GRAMMAR_TOO_LARGE_MESSAGE, GlobalSlot, HEBREW_PREFIXES, JSON_SCHEMA_BANNED_KEYWORDS, JsonSchemaShapeError, KeptReason, LAYOUT_ACCENT_TEXT, LAYOUT_BEAT_DELAY, LAYOUT_CHECK_VIEWPORT, LAYOUT_COLOUR_TOKEN, LAYOUT_COLUMN_GAP, LAYOUT_DEPTH_ON_PHONE, LAYOUT_DRIFT, LAYOUT_EASING, LAYOUT_ENTRANCE_MAX_MS, LAYOUT_FONT_SIZE, LAYOUT_GUTTER, LAYOUT_HIDDEN_OPACITY, LAYOUT_KINETIC_KINDS, LAYOUT_LINE_HEIGHT, LAYOUT_OPERATED, LAYOUT_PACE, LAYOUT_PHONE_BREAKPOINT, LAYOUT_PHONE_PADDING, LAYOUT_PHOTO_ASPECT, LAYOUT_READY_MADE_TOKEN, LAYOUT_RISE, LAYOUT_SCREEN_PX, LAYOUT_TEXT_KINDS, LAYOUT_TOOLTIP_TRAIT, LAYOUT_VIEWPORTS, LAYOUT_WIRE_AUTOPLAY_MS, LayoutAlign, LayoutBleed, LayoutButtonVariant, LayoutColour, LayoutColourMode, LayoutDepth, LayoutDial, LayoutEase, LayoutEditOp, LayoutEnter, LayoutGalleryEffect, LayoutGapCode, LayoutIssueCode, LayoutLayerKind, LayoutMendKind, LayoutNavKind, LayoutPace, LayoutPhotoShape, LayoutPhotoSource, LayoutRole, LayoutSectionKind, LayoutSequenceToken, LayoutSide, LayoutSignatureId, LayoutSize, LayoutSourceChoice, LayoutTrackProp, LayoutTransition, LayoutViewport, MAX_SITE_PICTURES, NAV_PART_LABELS, NAV_SHAPE_COPY, NEUTRAL_STYLE_PROPS, NODE_BASELINES, NO_TOKENS, NavPagesSource, NavRole, NavShape, NavShapeError, PAGE_ARCHETYPES, PHOTO_ANALYSIS_WIDTH, PHOTO_CALM_DETAIL, PHOTO_GRID, PHOTO_LIGHT_LUMINANCE, PICTURE_ASPECTS, PICTURE_NEVER, PICTURE_REAL_PLACE_FAMILIES, PICTURE_REROLL_EVERY, PICTURE_REVIEW_FORMAT, PICTURE_REVIEW_SHAPE, PICTURE_TEXT_CONTRAST, PICTURE_WORLDS, PICTURE_WORLD_IDS, PLAN_EDITS_ANSWER_SHAPES, PLAN_EDITS_PART_SCHEMA_NAMES, PLAN_EDIT_OP_PART, PLAN_EDIT_SHAPE, PLAN_EDIT_WIRE_KEYS, PLAN_PARTS, PLAN_PART_KEYS, PLAN_WIRE_DERIVED, PLAN_WIRE_PART_SCHEMA_NAMES, PLAN_WIRE_SHAPE, PRICING_PATTERN, PROOF_FINGERPRINTS, PUBLISH_BLOCKING_PLACEHOLDERS, PageDataKind, PathIssueCollector, PatternDirective, PatternGlobalPosition, PatternOpens, PatternPlaceholder, PatternRecipe, PhoneMenuBreakpoint, PhotoTone, PictureRefusal, PictureWorld, PlaceholderKind, PlanChangeAction, PlanChangeKind, PlanDataSourceMode, PlanDataSourceType, PlanEditIssueCode, PlanEditOp, PlanEditsOutcome, PlanPart, PlanWireEntry, PlanWireShapeError, PlanWordIssueCode, PreflightRefusalCode, PublishRefusalCode, RENDER_CHECK, REQUIRED_CONTENT_ROLES, RelativeOp, SAMPLE_IMAGE_REF, SCENE_LEVEL, SCENE_OTHER_PAGES, SCRIM_BACKGROUND, SCRIM_COVER, SCRIM_LEVELS, SHOWCASE_FILM, SITE_CHECKS, SITE_FACT_LABELS, SITE_HEADER_PATTERN, SITE_LIBRARY, SITE_LOCALES, SITE_NEED_IDS, SITE_PATTERNS, SITE_PLAN_VERSION, SITE_TEMPLATES, SPEC_SITE_ARCHETYPES, SPEC_SITE_COPY_LENGTHS, SPEC_SITE_DENSITY_COPY, SPEC_SITE_FACTS, SPEC_SITE_LAYOUT, SPEC_SITE_LIBRARY, SPEC_SITE_LOCALES, SPEC_SITE_NEED_IDS, SPEC_SITE_PATTERNS, SPEC_SITE_PICTURE_NEVER, SPEC_SITE_PICTURE_WORLDS, SPEC_SITE_PLAN_SHAPE, SPEC_SITE_REQUIRED_ROLES, SPEC_SITE_ROLES, SPEC_SITE_TEMPLATES, STOCK_FAMILIES, STOCK_FAMILY_INTENTS, STOCK_INTENT_ORDER, STOCK_INTENT_SUBJECTS, STOCK_ITEM_ASPECT, STOCK_MIN_KEPT, STOCK_PROVIDER_TERMS, STOCK_SEED_MARGIN, STOCK_SUBJECT_WORDS, STRICT_SCHEMA_BUDGET, STRICT_SCHEMA_LIMITS, STUDIO_TEMPLATE, ScrimLevel, SectionFallbackLastResort, SectionSwapAction, SectionSwapRule, SiteBuildKind, SiteBuildStatus, SiteCheckId, SiteFindingCode, SiteLocale, SitePlanError, SitePlanIssueCode, SitePlanSourceKind, SiteTemplateError, SiteTemplateId, StepState, StockIntent, StockOrientation, StockProviderId, StockReviewFlag, StockReviewVerdict, StockSlotKind, StockSubject, WORDS_AREA_DEFAULT_SHARE, WordsEdge, addBarItem, addStockCredits, aiStepParts, applyLayoutEdits, applyOwnPhotoGalleries, applyPictureScrims, applyPlanEdits, applyStockItemPhotos, applyStockPhotos, archetypeIssues, areaLuminance, artDirectionFor, artDirectionIssues, artDirectionPreamble, aspectRatioOf, assertStyleSlots, assertValidSitePlan, auditLayoutMotion, auditSite, barIconForRoute, blocksPublish, brandHueWord, buildKeys, buildStepFacts, builtHomePageId, calmParts, calmUnder, checkLayout, chooseScrim, composeContextOf, composeLayout, composeNavHeader, composePresetForm, composeSection, composeSite, contentTypeOfSource, contentTypePreviewFields, contentTypeToWire, copyLengthOf, costUsd, coverCrop, createSerializedNode, creditsOfUsd, dataSourceToWire, derivedBeats, derivedDataSources, describeInventoryForPrompt, describePlanData, describeShapeKey, driftAt, driftOverlap, emptyAreaPhrase, entranceAction, entranceInteraction, estimatePictures, estimateStepCredits, expandLayoutWire, expandPlanWire, expandWireContentType, expandWireDataSource, expandWireEdit, expandWireField, expandWirePage, expandWireSection, failedBuildStep, fallBackBySection, fieldToWire, filmOfPlan, filmPlacement, findNavRoot, fingerprintOf, frameWords, isActiveBuild, isLayoutRule, isNonEmptyString, isPictureWorld, isPlainObject, isRtlLocale, jsonAnyOf, jsonBoolean, jsonClosedObject, jsonInteger, jsonListOf, jsonOneOf, jsonSchemaKeywords, jsonSchemaObjects, jsonShapedObject, jsonText, judgeLayoutRender, layerShownSpans, layoutBandScheme, layoutBoxPx, layoutColumnsVw, layoutDesignOf, layoutDialOf, layoutDriftPhoto, layoutElementStyle, layoutGalleryLists, layoutGallerySources, layoutGlideDepth, layoutHeldStill, layoutLookChanges, layoutLookOf, layoutMotionOf, layoutNodeClass, layoutOpeningDisplayMend, layoutOpeningDisplays, layoutPathSteps, layoutPhotoIds, layoutPresetColours, layoutPresetOf, layoutRepairJsonSchema, layoutRoomPx, layoutRuleEdge, layoutShapeHasPurpose, layoutStillLine, layoutTextFits, layoutTextWidthEm, layoutToWire, layoutVoidScreens, layoutVoids, layoutWireJsonSchema, luminanceOf, measureLayout, mendLayout, modelCanDo, moveBarItem, navPages, navShapeBreakpoint, navShapeOf, nextSourceOf, nodeBindPaths, orientationOfRatio, ownPhotoFit, pageToWire, parseLayoutPhotoId, parsePatternPath, parseSampleImageRef, pathAt, patternById, patternHasForm, patternLinkSlots, patternListGap, patternManifest, patternNeedsBinding, patternNodes, patternOptionalParts, patternRoleNeeds, patternScopes, patternSlotBudgets, patternSlots, patternTakesBinding, phoneGapBefore, phoneMenuPages, phoneWordsColour, photoInventory, photoShapeOf, pictureAspect, picturePrompt, pictureRefusalOf, pictureRerolls, pictureReviewIssues, pictureReviewJsonSchema, pictureReviewPasses, pictureSlotKey, pictureTargets, pictureTryFits, pixelsUnder, placeFilm, planEditOps, planEditToWire, planEditWireGaps, planEditWireKeys, planEditWireOps, planEditWireShape, planEditsFromWire, planEditsJsonSchema, planEditsToWire, planEntrances, planFromTemplate, planLayoutPhotos, planNavShape, planOwnPhotos, planPartOfPath, planPartToWire, planPictures, planStockPhotos, planToWire, planWireGaps, planWirePartJsonSchema, planWirePartShape, planWordIssues, publishRefusal, publishVerdict, readyMadeColumn, recipeListBinds, recomposeAsks, releasedLayoutDefaults, removeBarItem, requiredAcknowledgements, requiredShapeKeys, roleField, routeMatches, routeParams, samenessIssues, sampleImageRef, scoreStockPhoto, screenFontSize, screenWordColumns, screenWordMisfit, screenWordOverflowPx, sectionEntrances, sectionPatternIds, sectionToWire, sectionsNamed, sequenceShare, sequenceTokenOf, setStyleProps, shapeKeys, showcaseGlobals, showcasePages, showcasePlans, showcaseScenes, shownTogether, signatureOf, siteNavPages, slotBudget, splitSide, stockCopyKey, stockCreditLine, stockCreditLines, stockCreditNode, stockCreditNodeId, stockFits, stockGroupOf, stockItemSlots, stockKept, stockPhotoRatio, stockPhotoSubject, stockPhotoUsable, stockPhotoWords, stockSlots, stockWord, stockWords, strictSchemaComplexity, strictSchemaRefusal, toneOf, typicalStepTokens, validatePlanEdits, validateSitePlan, walkSerialized, wireContentTypeJsonSchema, wireDataSourceJsonSchema, wireFieldJsonSchema, wirePageJsonSchema, wireSectionJsonSchema, withDerivedSources, wordPattern, wordsOverPhotos, wordsOverPicture, writtenTexts };
|
|
22463
22961
|
//# sourceMappingURL=vectoriox-iox-ui-generation-core.mjs.map
|