@vectoriox/iox-ui 5.196.0 → 5.198.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/composite-core/index.d.ts +19 -2
- package/data-core/index.d.ts +101 -2
- package/design-core/index.d.ts +183 -30
- package/fesm2022/vectoriox-iox-ui-composite-core.mjs +49 -10
- package/fesm2022/vectoriox-iox-ui-composite-core.mjs.map +1 -1
- package/fesm2022/vectoriox-iox-ui-data-core.mjs +192 -2
- package/fesm2022/vectoriox-iox-ui-data-core.mjs.map +1 -1
- package/fesm2022/vectoriox-iox-ui-design-core.mjs +299 -74
- package/fesm2022/vectoriox-iox-ui-design-core.mjs.map +1 -1
- package/fesm2022/vectoriox-iox-ui-generation-core.mjs +2287 -528
- package/fesm2022/vectoriox-iox-ui-generation-core.mjs.map +1 -1
- package/fesm2022/vectoriox-iox-ui-harness-core.mjs +3 -1
- package/fesm2022/vectoriox-iox-ui-harness-core.mjs.map +1 -1
- package/fesm2022/vectoriox-iox-ui.mjs +32 -2
- package/fesm2022/vectoriox-iox-ui.mjs.map +1 -1
- package/generation-core/index.d.ts +1454 -200
- package/harness-core/index.d.ts +1 -1
- package/package.json +1 -1
- package/src/composite-core/header.ts +34 -1
- package/src/composite-core/slider-runtime.ts +16 -8
- package/src/data-core/placeholder-rows.ts +220 -0
- package/src/data-core/public-api.ts +2 -1
- package/src/design-core/brand.ts +58 -5
- package/src/design-core/contrast-audit.ts +49 -22
- package/src/design-core/design-apply.ts +34 -3
- package/src/design-core/flavor-fixtures.generated.ts +123 -123
- package/src/design-core/flavor-spec.generated.ts +44 -4
- package/src/design-core/flavor-tokens.ts +1 -1
- package/src/design-core/header-behaviour.ts +82 -15
- package/src/design-core/motion-language.ts +5 -14
- package/src/design-core/node-links.ts +34 -0
- package/src/design-core/preloader.ts +4 -5
- package/src/generation-core/audit-site.ts +10 -1
- package/src/generation-core/audit-words.ts +5 -0
- package/src/generation-core/body-mix.ts +40 -102
- package/src/generation-core/check-free.ts +26 -5
- package/src/generation-core/check-layout.ts +10 -4
- package/src/generation-core/check-list.ts +3 -25
- package/src/generation-core/colour-mix.ts +296 -0
- package/src/generation-core/compose-free.ts +40 -18
- package/src/generation-core/compose-site.ts +124 -22
- package/src/generation-core/footer-mix.ts +102 -54
- package/src/generation-core/free-fallback.ts +6 -4
- package/src/generation-core/free-opening.ts +57 -0
- package/src/generation-core/free-parts.ts +87 -0
- package/src/generation-core/free-slot-words.ts +30 -0
- package/src/generation-core/generation-tier.ts +6 -17
- package/src/generation-core/header-mix.ts +125 -4
- package/src/generation-core/item-fill.ts +42 -0
- package/src/generation-core/layout-drawers.ts +3 -2
- package/src/generation-core/layout-wire.ts +10 -16
- package/src/generation-core/list-panel.ts +3 -3
- package/src/generation-core/list-table.ts +5 -14
- package/src/generation-core/list-words.ts +2 -1
- package/src/generation-core/nav-shape.ts +45 -16
- package/src/generation-core/node-baselines.generated.ts +1 -0
- package/src/generation-core/opening-mix.ts +16 -33
- package/src/generation-core/part-tier.ts +14 -0
- package/src/generation-core/plan-wire.ts +31 -43
- package/src/generation-core/public-api.ts +4 -0
- package/src/generation-core/site-build-run.ts +4 -0
- package/src/generation-core/site-spec.generated.ts +1127 -93
- package/src/generation-core/stock-search.ts +106 -18
- package/src/generation-core/type-led.ts +19 -4
- package/src/generation-core/validate-site-plan.ts +4 -5
- package/src/harness-core/run-compose-context.ts +3 -1
- package/styles/iox-design.css +139 -4
|
@@ -1138,6 +1138,36 @@ function headingHref(props, pageHref = route => route) {
|
|
|
1138
1138
|
return String(props.url ?? '').trim() || null;
|
|
1139
1139
|
return null;
|
|
1140
1140
|
}
|
|
1141
|
+
/** The prop a node's route params are stored under — `routeParam:<name>`, a static value or a binding (both land there). */
|
|
1142
|
+
const ROUTE_PARAM_PREFIX = 'routeParam:';
|
|
1143
|
+
/** A node's route params by name, from its `routeParam:<name>` props (`{ 'routeParam:slug': 'soap' }` → `{ slug: 'soap' }`). */
|
|
1144
|
+
function routeParamValues(props) {
|
|
1145
|
+
const out = {};
|
|
1146
|
+
for (const [key, value] of Object.entries(props ?? {})) {
|
|
1147
|
+
if (key.startsWith(ROUTE_PARAM_PREFIX))
|
|
1148
|
+
out[key.slice(ROUTE_PARAM_PREFIX.length)] = value;
|
|
1149
|
+
}
|
|
1150
|
+
return out;
|
|
1151
|
+
}
|
|
1152
|
+
const ROUTE_PARAM = /:([a-zA-Z_][a-zA-Z0-9_]*)/g;
|
|
1153
|
+
/**
|
|
1154
|
+
* A page route with its `:params` filled: each from `values` (URL-encoded), an unfilled one leaving no gap
|
|
1155
|
+
* (`/shop/:slug/reviews` with no slug → `/shop/reviews`). The engine's `resolvePageHref` substitution, shared so the builder's
|
|
1156
|
+
* Preview links where the live site does — a product card read `/shop/:slug` there (vectoriox/iox-ui#176). The route's
|
|
1157
|
+
* leading slash is kept; the engine makes it base-relative itself.
|
|
1158
|
+
*/
|
|
1159
|
+
function fillRouteParams(route, values) {
|
|
1160
|
+
return String(route ?? '')
|
|
1161
|
+
.replace(ROUTE_PARAM, (_m, name) => {
|
|
1162
|
+
const value = values[name];
|
|
1163
|
+
return value === undefined || value === null || value === '' ? '' : encodeURIComponent(String(value));
|
|
1164
|
+
})
|
|
1165
|
+
.replace(/\/{2,}/g, '/');
|
|
1166
|
+
}
|
|
1167
|
+
/** Does the route still name a `:param` (one nothing filled)? */
|
|
1168
|
+
function routeHasParams(route) {
|
|
1169
|
+
return new RegExp(ROUTE_PARAM.source).test(String(route ?? ''));
|
|
1170
|
+
}
|
|
1141
1171
|
|
|
1142
1172
|
/**
|
|
1143
1173
|
* Directive-host Heading: the real `<h1>`…`<h6>` IS the host — no `app-builder-heading`
|
|
@@ -9502,8 +9532,8 @@ function nodeA11yAttributes(node, ctx = {}) {
|
|
|
9502
9532
|
if (node.type === MENU_BUTTON_TYPE)
|
|
9503
9533
|
Object.assign(out, menuButtonAttributes((name) => nodeTraitValue(node, name)));
|
|
9504
9534
|
// T2 (M4): how a header behaves as the page scrolls — the shared CSS and the header runtime read these. HI3 slice 1:
|
|
9505
|
-
// what it stands on (over · over-glass · glass).
|
|
9506
|
-
Object.assign(out, headerAttributes(nodeTraitValue(node, HeaderTrait.Behaviour), nodeTraitValue(node, HeaderTrait.Edge), nodeTraitValue(node, HeaderTrait.Ink), nodeTraitValue(node, HeaderTrait.Ground)));
|
|
9535
|
+
// what it stands on (over · over-glass · glass). Slice 2: its outline (pill · islands) and its name (hangs · later).
|
|
9536
|
+
Object.assign(out, headerAttributes(nodeTraitValue(node, HeaderTrait.Behaviour), nodeTraitValue(node, HeaderTrait.Edge), nodeTraitValue(node, HeaderTrait.Ink), nodeTraitValue(node, HeaderTrait.Ground), nodeTraitValue(node, HeaderTrait.Shape), nodeTraitValue(node, HeaderTrait.Brand)));
|
|
9507
9537
|
if (node.type === SLIDE_TYPE) {
|
|
9508
9538
|
const caption = trimmed$1(nodeTraitValue(node, SLIDE_CAPTION_TRAIT));
|
|
9509
9539
|
if (caption)
|