@vectoriox/iox-ui 5.168.0 → 5.170.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/commerce-core/index.d.ts +32 -3
- package/design-core/index.d.ts +91 -5
- package/fesm2022/vectoriox-iox-ui-commerce-core.mjs +52 -1
- package/fesm2022/vectoriox-iox-ui-commerce-core.mjs.map +1 -1
- package/fesm2022/vectoriox-iox-ui-design-core.mjs +147 -15
- package/fesm2022/vectoriox-iox-ui-design-core.mjs.map +1 -1
- package/fesm2022/vectoriox-iox-ui-generation-core.mjs +76 -11
- package/fesm2022/vectoriox-iox-ui-generation-core.mjs.map +1 -1
- package/fesm2022/vectoriox-iox-ui.mjs +30 -5
- package/fesm2022/vectoriox-iox-ui.mjs.map +1 -1
- package/generation-core/index.d.ts +34 -4
- package/index.d.ts +4 -0
- package/package.json +1 -1
- package/src/commerce-core/shop-display.ts +35 -1
- package/src/commerce-core/variants.ts +25 -0
- package/src/design-core/flavor-spec.generated.ts +24 -0
- package/src/design-core/font-metrics.ts +28 -8
- package/src/design-core/footer-classes.ts +14 -3
- package/src/design-core/header-behaviour.ts +87 -5
- package/src/generation-core/compose-site.ts +3 -0
- package/src/generation-core/contact-facts.ts +61 -0
- package/src/generation-core/footer-mix.ts +16 -8
- package/src/generation-core/layout-language.ts +6 -2
- package/src/generation-core/public-api.ts +1 -0
- package/src/generation-core/site-build-run.ts +12 -0
- package/styles/iox-design.css +53 -8
|
@@ -6,7 +6,7 @@ import { Subject, fromEvent } from 'rxjs';
|
|
|
6
6
|
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
|
|
7
7
|
import * as i1 from '@angular/common';
|
|
8
8
|
import { CommonModule, isPlatformBrowser } from '@angular/common';
|
|
9
|
-
import { SPEC_AXES, resolveDesignMotion, FILTER_FUNCTIONS, BACKDROP_FUNCTIONS, decomposeCssFunctions, FieldClass, HeaderAttribute, HeaderBehaviour, HeaderInk, OPENING_ATTRIBUTE, schemeOfClasses, schemeUnderBar, BRAND_NAME_ATTRIBUTE, MENU_ATTRIBUTES, menuDialogAttributes, menuButtonAttributes, headerAttributes, HeaderTrait, BRAND_ROLE, brandNameAttributes, REDUCED_ENTRANCE_MAX_MS, roleClass, preloaderWords, PreloaderKind, preloaderGraphemes, PRELOADER_EXIT_EASE, PRELOADER_CAP_MS, isFirstVisit, PRELOADER_ENTER_EASE, PreloaderExit, PRELOADER_MIN_SHOW_MS, preloaderLeaveAt, preloaderExitMotion, preloaderPercent, inkOnGround, writeFieldError } from '@vectoriox/iox-ui/design-core';
|
|
9
|
+
import { SPEC_AXES, resolveDesignMotion, FILTER_FUNCTIONS, BACKDROP_FUNCTIONS, decomposeCssFunctions, FieldClass, HeaderAttribute, HeaderBehaviour, HeaderInk, OPENING_ATTRIBUTE, schemeOfClasses, schemeUnderBar, BRAND_NAME_ATTRIBUTE, BAR_ATTRIBUTE, BAR_NAME_ATTRIBUTE, MENU_ATTRIBUTES, menuDialogAttributes, menuButtonAttributes, headerAttributes, HeaderTrait, BRAND_ROLE, brandNameAttributes, NAV_ROLE, navBarAttributes, REDUCED_ENTRANCE_MAX_MS, roleClass, preloaderWords, PreloaderKind, preloaderGraphemes, PRELOADER_EXIT_EASE, PRELOADER_CAP_MS, isFirstVisit, PRELOADER_ENTER_EASE, PreloaderExit, PRELOADER_MIN_SHOW_MS, preloaderLeaveAt, preloaderExitMotion, preloaderPercent, inkOnGround, writeFieldError } from '@vectoriox/iox-ui/design-core';
|
|
10
10
|
export * from '@vectoriox/iox-ui/design-core';
|
|
11
11
|
import { setPageScroller, pageScroller, SceneAttribute, SCENE_WAKE_EVENT, SCENE_REVEAL_DEFAULT, SceneRevealFrom, revealClipPath, playTextReveal, textRevealByOf, textRevealLookOf, textRevealStaggerOf, ScrollActionKind, lightMotionWanted, scrubTextReveal, ScrollPlay, gentleFrames, SCENE_PHONE_MAX_WIDTH, normalizeParallaxDepth, normalizeParallaxPhone, parallaxShift, parallaxRest, parallaxFrames, PROGRESS_BAR_FRAMES, ParallaxPhone, outermostNodeOf, normalizeScrollRange, scrollPlayFor, ScrollRange } from '@vectoriox/iox-ui/scene-core';
|
|
12
12
|
import Lenis from 'lenis';
|
|
@@ -17,7 +17,7 @@ import { runExitMotion, isExiting, popoverOpenersSelector, OpenerAttribute, canc
|
|
|
17
17
|
export { SCROLL_PROGRESS_TRIGGER } from '@vectoriox/iox-ui/actions-core';
|
|
18
18
|
import { VideoKind, planVideo, videoRootAttributes, videoInnerHtml, videoWords, VideoAttribute, attachVideoAt, VideoClass } from '@vectoriox/iox-ui/media-core';
|
|
19
19
|
import * as i1$1 from '@angular/platform-browser';
|
|
20
|
-
import { formatMoneyValue, CURRENCY_CODES, SHOP_SLOTS } from '@vectoriox/iox-ui/commerce-core';
|
|
20
|
+
import { listPriceField, formatMoneyValue, CURRENCY_CODES, SHOP_SLOTS } from '@vectoriox/iox-ui/commerce-core';
|
|
21
21
|
import { CUSTOMER_SLOT } from '@vectoriox/iox-ui/identity-core';
|
|
22
22
|
|
|
23
23
|
class ViewPositionDirective {
|
|
@@ -9158,7 +9158,7 @@ var A11yAttribute;
|
|
|
9158
9158
|
const MANAGED_A11Y_ATTRIBUTES = [
|
|
9159
9159
|
A11yAttribute.Label, A11yAttribute.Hidden, A11yAttribute.Current, A11yAttribute.Id,
|
|
9160
9160
|
'aria-haspopup', 'aria-expanded', 'aria-controls', DIALOG_CLOSE_ABOVE_ATTRIBUTE,
|
|
9161
|
-
HeaderAttribute.Behaviour, HeaderAttribute.Edge, BRAND_NAME_ATTRIBUTE, SLIDE_CAPTION_ATTRIBUTE,
|
|
9161
|
+
HeaderAttribute.Behaviour, HeaderAttribute.Edge, BRAND_NAME_ATTRIBUTE, BAR_ATTRIBUTE, BAR_NAME_ATTRIBUTE, SLIDE_CAPTION_ATTRIBUTE,
|
|
9162
9162
|
TOOLTIP_ATTRIBUTE, TOOLTIP_PLACEMENT_ATTRIBUTE, ...MARQUEE_NODE_ATTRIBUTES, ...MENU_ATTRIBUTES, ...POPUP_ATTRIBUTES,
|
|
9163
9163
|
];
|
|
9164
9164
|
/** The type of a menu button and of the menu's Close (header-ingredients HI2a: its kind — lines · word · dots). */
|
|
@@ -9233,8 +9233,27 @@ function nodeA11yAttributes(node, ctx = {}) {
|
|
|
9233
9233
|
// vectoriox/iox-ui#98: a header's long name steps down the look's type scale on a phone (the shared CSS reads it).
|
|
9234
9234
|
if (node.role === BRAND_ROLE)
|
|
9235
9235
|
Object.assign(out, brandNameAttributes(brandWords(node)));
|
|
9236
|
+
// vectoriox/iox-ui#143: a phone bar crowded by the menu, the bag and the account packs its controls and steps the name
|
|
9237
|
+
// by the room it is left (the name's own step cannot see its neighbours).
|
|
9238
|
+
if (node.role === NAV_ROLE) {
|
|
9239
|
+
const brand = findBrand(node);
|
|
9240
|
+
Object.assign(out, navBarAttributes(node, brand ? brandWords(brand) : ''));
|
|
9241
|
+
}
|
|
9236
9242
|
return out;
|
|
9237
9243
|
}
|
|
9244
|
+
/** The navigation's brand (its first part carrying `nav.brand`), outside the drawer. */
|
|
9245
|
+
function findBrand(node) {
|
|
9246
|
+
for (const child of (node.children ?? [])) {
|
|
9247
|
+
if (!child || child.type === DIALOG_NODE_TYPE)
|
|
9248
|
+
continue;
|
|
9249
|
+
if (child.role === BRAND_ROLE)
|
|
9250
|
+
return child;
|
|
9251
|
+
const deeper = findBrand(child);
|
|
9252
|
+
if (deeper)
|
|
9253
|
+
return deeper;
|
|
9254
|
+
}
|
|
9255
|
+
return null;
|
|
9256
|
+
}
|
|
9238
9257
|
/** A brand's name: the words of its first Heading or Text (a logo-only brand has none). */
|
|
9239
9258
|
function brandWords(node) {
|
|
9240
9259
|
for (const child of (node.children ?? [])) {
|
|
@@ -11019,7 +11038,10 @@ const PIPE_REGISTRY = {
|
|
|
11019
11038
|
},
|
|
11020
11039
|
// Commerce E1c (shop-aware A-D2, C-D7): a price in the page's language — a Money as it is, a bare number as MAJOR
|
|
11021
11040
|
// units of the binding's currency, else the studio's. commerce-core `formatMoneyValue` is the one formatter.
|
|
11022
|
-
|
|
11041
|
+
// vectoriox/iox-ui#142: a list row's product with options reads its variants' lowest price ("From ₪89.00") — its own
|
|
11042
|
+
// `pricing.price` is empty — through commerce-core `listPriceField`; anything else formats as it always did.
|
|
11043
|
+
money: (v, args, ctx) => listPriceField(ctx.source, ctx.path, ctx.locale, args[0] || ctx.currency)
|
|
11044
|
+
?? formatMoneyValue(v, args[0] || ctx.currency, ctx.locale),
|
|
11023
11045
|
// AW11-D10 (award lists): a colour block's ground and the ink on it, item by item when the page is drawn — design-core
|
|
11024
11046
|
// `inkOnGround` (AA; the ground moved in lightness only when no ink reads). Not a filter an author picks (no
|
|
11025
11047
|
// descriptor): the list composer writes them on `style:` bindings. A value that is no hex colour passes through.
|
|
@@ -11146,7 +11168,10 @@ function resolvePath(obj, path) {
|
|
|
11146
11168
|
*/
|
|
11147
11169
|
function resolveBoundValue(sourceData, binding, ctx = {}) {
|
|
11148
11170
|
const raw = binding.path ? resolvePath(sourceData, binding.path) : sourceData;
|
|
11149
|
-
|
|
11171
|
+
if (!binding.pipes?.length)
|
|
11172
|
+
return raw;
|
|
11173
|
+
// The pipes see what the value was read from (a list row's product — vectoriox/iox-ui#142's `money`).
|
|
11174
|
+
return applyBindingPipes(raw, binding.pipes, { ...ctx, source: sourceData, path: binding.path });
|
|
11150
11175
|
}
|
|
11151
11176
|
|
|
11152
11177
|
/**
|