@vectoriox/iox-ui 5.125.0 → 5.127.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.
@@ -307,5 +307,77 @@ interface FocusableSheet {
307
307
  */
308
308
  declare function focusDialogSheet(dialog: FocusableSheet | null | undefined): boolean;
309
309
 
310
- export { ACCOUNT_ACTION_TYPES, BEHAVIOUR_ACTION_TYPES, CONSENT_ACTION_TYPES, COUNT_UP_TRIGGERS, DIALOG_ACTION_TYPE_SET, DIALOG_CLOSING_ATTRIBUTE, DIALOG_EXIT_TIMEOUT_MS, DIALOG_OPENER_ACTION_TYPES, DIALOG_OPENER_TRIGGER, DIALOG_SELECTOR, ELEMENT_ACTION_DESCRIPTORS, ELEMENT_ACTION_GROUP_ORDER, FORM_SUBMIT_ACTION_DESCRIPTORS, ITEM_ACTION_TYPES, OpenerAttribute, POPOVER_ACTION_TYPE_SET, POPOVER_NODE_TYPE, POPOVER_OPENER_ACTION_TYPES, SCROLL_PROGRESS_TRIGGER, SERVER_ELEMENT_ACTION_TYPES, SHOP_ACTION_TYPES, SHOP_ENTITLEMENT, TOAST_ACTION_TYPES, actionOfferedUnder, addableActions, cancelExit, closeDialogAnimated, dialogDomId, dialogOpenerAttributes, dialogOpenersSelector, dialogTogglesClosed, focusDialogSheet, groupedElementActions, isExiting, itemActionOf, nodeIdOfDialogDomId, nodeIdOfPopoverDomId, openedDialogId, openedPopoverId, openedTargetId, opensAtClickedItem, popoverDomId, popoverOpenerAttributes, popoverOpenersSelector, resolveActionAvailability, runExitMotion };
311
- export type { ActionAvailability, ActionAvailabilityContext, ActionAvailabilityState, ActionDescriptor, ActionGroup, ActionKind, ActionParamSpec, ActionTargetSpec, BuilderBehaviour, DialogElementLike, ExitAnimationLike, ExitMotionElement, ExitMotionOptions, FocusableSheet, OpenerActionLike, OpenerInteractionLike, OpenerNodeLike };
310
+ /**
311
+ * Where a menu's REVEAL grows from (header-ingredients HI2a; header-builder board 2: "origin = the opener's centre"). A
312
+ * zoom scales about it, a circle and the torn edge open from it — so the menu reads as coming OUT of the button that opened
313
+ * it. The reveals themselves are CSS transitions in the shared `iox-design.css` (Emil: a menu toggles, so it must reverse
314
+ * from its live value — a transition, never keyframes); the one beat of script is this: put the opener's centre, in the
315
+ * menu's own box, into two custom properties when the menu opens. ONE function for the live page and the builder canvas
316
+ * (each passes its own box measure). Framework-free.
317
+ */
318
+ declare enum RevealOriginProperty {
319
+ X = "--reveal-x",
320
+ Y = "--reveal-y",
321
+ /** How far the reveal must grow to cover the menu: the distance to its farthest corner (a circle of this radius,
322
+ * centred on the origin, covers the whole box — so the reveal spends its time ON the menu, not past it). */
323
+ R = "--reveal-r"
324
+ }
325
+ interface RevealOriginPoint {
326
+ x: number;
327
+ y: number;
328
+ r: number;
329
+ }
330
+ interface RevealRect {
331
+ left: number;
332
+ top: number;
333
+ width: number;
334
+ height: number;
335
+ }
336
+ interface RevealOriginOptions {
337
+ /** Opener space → the menu's CSS px (the builder canvas is zoomed: its rects are scaled). Default 1. */
338
+ scale?: number;
339
+ /** With no opener, the menu's top-LEFT corner (a start-side menu in LTR, an end-side one in RTL); else top-right. */
340
+ atLeft?: boolean;
341
+ }
342
+ /**
343
+ * The reveal origin in the menu's own box (CSS px, from its top-left border edge): the opener's centre, or — opened by
344
+ * anything else (a link, an action on another element) — the menu's top corner on its side. `box` is the menu's
345
+ * UNTRANSFORMED box, in the same space as the opener's rect. Pure.
346
+ */
347
+ declare function revealOrigin(opener: RevealRect | null | undefined, box: RevealRect, options?: RevealOriginOptions): RevealOriginPoint;
348
+ /** The custom properties for an origin. */
349
+ declare function revealOriginStyle(origin: RevealOriginPoint): Record<RevealOriginProperty, string>;
350
+ /** What `revealFrom` needs of a live `<dialog>` (structural, so the spec drives it without a DOM). */
351
+ interface RevealDialogLike {
352
+ id: string;
353
+ offsetWidth: number;
354
+ offsetHeight: number;
355
+ style: {
356
+ setProperty(name: string, value: string): void;
357
+ };
358
+ getAttribute(name: string): string | null;
359
+ ownerDocument: {
360
+ defaultView: {
361
+ getComputedStyle(el: unknown): {
362
+ marginLeft: string;
363
+ marginTop: string;
364
+ direction: string;
365
+ };
366
+ } | null;
367
+ querySelectorAll(selector: string): ArrayLike<RevealOpenerLike>;
368
+ } | null;
369
+ }
370
+ interface RevealOpenerLike {
371
+ getBoundingClientRect(): RevealRect;
372
+ getClientRects?(): ArrayLike<unknown>;
373
+ }
374
+ /**
375
+ * Set a just-opened live `<dialog>`'s reveal origin from the element that opened it (`opener`), else from the first of its
376
+ * openers that is on screen (`aria-controls` — the menu button at its width), else its top corner. Call it right after
377
+ * `showModal()`. A top-layer dialog is fixed at `inset: 0`, so its untransformed box starts at its USED margins — a
378
+ * reveal's starting scale or translate never moves a margin, whereas `getBoundingClientRect` would read it.
379
+ */
380
+ declare function revealFrom(dialog: RevealDialogLike | null | undefined, opener?: RevealOpenerLike | null): void;
381
+
382
+ export { ACCOUNT_ACTION_TYPES, BEHAVIOUR_ACTION_TYPES, CONSENT_ACTION_TYPES, COUNT_UP_TRIGGERS, DIALOG_ACTION_TYPE_SET, DIALOG_CLOSING_ATTRIBUTE, DIALOG_EXIT_TIMEOUT_MS, DIALOG_OPENER_ACTION_TYPES, DIALOG_OPENER_TRIGGER, DIALOG_SELECTOR, ELEMENT_ACTION_DESCRIPTORS, ELEMENT_ACTION_GROUP_ORDER, FORM_SUBMIT_ACTION_DESCRIPTORS, ITEM_ACTION_TYPES, OpenerAttribute, POPOVER_ACTION_TYPE_SET, POPOVER_NODE_TYPE, POPOVER_OPENER_ACTION_TYPES, RevealOriginProperty, SCROLL_PROGRESS_TRIGGER, SERVER_ELEMENT_ACTION_TYPES, SHOP_ACTION_TYPES, SHOP_ENTITLEMENT, TOAST_ACTION_TYPES, actionOfferedUnder, addableActions, cancelExit, closeDialogAnimated, dialogDomId, dialogOpenerAttributes, dialogOpenersSelector, dialogTogglesClosed, focusDialogSheet, groupedElementActions, isExiting, itemActionOf, nodeIdOfDialogDomId, nodeIdOfPopoverDomId, openedDialogId, openedPopoverId, openedTargetId, opensAtClickedItem, popoverDomId, popoverOpenerAttributes, popoverOpenersSelector, resolveActionAvailability, revealFrom, revealOrigin, revealOriginStyle, runExitMotion };
383
+ export type { ActionAvailability, ActionAvailabilityContext, ActionAvailabilityState, ActionDescriptor, ActionGroup, ActionKind, ActionParamSpec, ActionTargetSpec, BuilderBehaviour, DialogElementLike, ExitAnimationLike, ExitMotionElement, ExitMotionOptions, FocusableSheet, OpenerActionLike, OpenerInteractionLike, OpenerNodeLike, RevealDialogLike, RevealOpenerLike, RevealOriginOptions, RevealOriginPoint, RevealRect };
@@ -873,6 +873,10 @@ declare const SPEC_TIERS: {
873
873
  readonly name: "dialog-edge";
874
874
  readonly type: "color";
875
875
  readonly default: "var(--iox-line)";
876
+ }, {
877
+ readonly name: "menu-edge";
878
+ readonly type: "color";
879
+ readonly default: "var(--iox-accent)";
876
880
  }, {
877
881
  readonly name: "image-radius";
878
882
  readonly type: "radius";
@@ -5991,6 +5995,12 @@ declare const SPEC_FLAVOR_PACKS: readonly [{
5991
5995
  readonly type: "color";
5992
5996
  readonly group: "components";
5993
5997
  readonly value: "var(--iox-line)";
5998
+ }, {
5999
+ readonly name: "menu-edge";
6000
+ readonly tier: "component";
6001
+ readonly type: "color";
6002
+ readonly group: "components";
6003
+ readonly value: "var(--iox-accent)";
5994
6004
  }, {
5995
6005
  readonly name: "image-radius";
5996
6006
  readonly tier: "component";
@@ -8000,6 +8010,12 @@ declare const SPEC_FLAVOR_PACKS: readonly [{
8000
8010
  readonly type: "color";
8001
8011
  readonly group: "components";
8002
8012
  readonly value: "var(--iox-line)";
8013
+ }, {
8014
+ readonly name: "menu-edge";
8015
+ readonly tier: "component";
8016
+ readonly type: "color";
8017
+ readonly group: "components";
8018
+ readonly value: "var(--iox-accent)";
8003
8019
  }, {
8004
8020
  readonly name: "image-radius";
8005
8021
  readonly tier: "component";
@@ -10011,6 +10027,12 @@ declare const SPEC_FLAVOR_PACKS: readonly [{
10011
10027
  readonly type: "color";
10012
10028
  readonly group: "components";
10013
10029
  readonly value: "var(--iox-line)";
10030
+ }, {
10031
+ readonly name: "menu-edge";
10032
+ readonly tier: "component";
10033
+ readonly type: "color";
10034
+ readonly group: "components";
10035
+ readonly value: "var(--iox-accent)";
10014
10036
  }, {
10015
10037
  readonly name: "image-radius";
10016
10038
  readonly tier: "component";
@@ -12047,6 +12069,12 @@ declare const SPEC_FLAVOR_PACKS: readonly [{
12047
12069
  readonly type: "color";
12048
12070
  readonly group: "components";
12049
12071
  readonly value: "var(--iox-line)";
12072
+ }, {
12073
+ readonly name: "menu-edge";
12074
+ readonly tier: "component";
12075
+ readonly type: "color";
12076
+ readonly group: "components";
12077
+ readonly value: "var(--iox-accent)";
12050
12078
  }, {
12051
12079
  readonly name: "image-radius";
12052
12080
  readonly tier: "component";
@@ -14066,6 +14094,12 @@ declare const SPEC_FLAVOR_PACKS: readonly [{
14066
14094
  readonly type: "color";
14067
14095
  readonly group: "components";
14068
14096
  readonly value: "var(--iox-line)";
14097
+ }, {
14098
+ readonly name: "menu-edge";
14099
+ readonly tier: "component";
14100
+ readonly type: "color";
14101
+ readonly group: "components";
14102
+ readonly value: "var(--iox-accent)";
14069
14103
  }, {
14070
14104
  readonly name: "image-radius";
14071
14105
  readonly tier: "component";
@@ -16085,6 +16119,12 @@ declare const SPEC_FLAVOR_PACKS: readonly [{
16085
16119
  readonly type: "color";
16086
16120
  readonly group: "components";
16087
16121
  readonly value: "var(--iox-line)";
16122
+ }, {
16123
+ readonly name: "menu-edge";
16124
+ readonly tier: "component";
16125
+ readonly type: "color";
16126
+ readonly group: "components";
16127
+ readonly value: "var(--iox-accent)";
16088
16128
  }, {
16089
16129
  readonly name: "image-radius";
16090
16130
  readonly tier: "component";
@@ -17386,6 +17426,112 @@ declare function headerStaysAtTop(behaviour: unknown): boolean;
17386
17426
  /** The attributes a header renders, from its two trait values — `{}` for a header that keeps today's behaviour. */
17387
17427
  declare function headerAttributes(behaviour: unknown, edge: unknown): Record<string, string>;
17388
17428
 
17429
+ /**
17430
+ * How a site's MENU looks and moves (header-ingredients-plan.md HI2a; HB-D1/HB-D2, header-builder board v2). The header
17431
+ * table's menu words — its form (drawer · full · top panel · card · mega), how it opens (slide · fade · zoom · circle ·
17432
+ * torn), the button that opens it (lines · word · dots) and what the mouse does in it (line · dim · row · none) — become
17433
+ * TRAITS on the menu's own nodes (the Dialog, the menu button and its Close) and ONE answer every renderer applies: the
17434
+ * attributes below, which the shared CSS (`iox-design.css`) reads. A menu with none of them renders exactly as the drawer
17435
+ * always did (R-H4): today's look is every default, and a default writes nothing.
17436
+ *
17437
+ * Framework-free: the composer (generation-core), the builder and both engine paths read it.
17438
+ */
17439
+ declare enum MenuForm {
17440
+ /** A sheet from the menu button's edge — the menu every site had before HI2. */
17441
+ Drawer = "drawer",
17442
+ /** The whole screen: an index of the page names. */
17443
+ Full = "full",
17444
+ /** A panel that drops from the top, as tall as its content (past 80dvh it scrolls inside itself — T7). */
17445
+ Panel = "panel",
17446
+ /** A card that opens from the menu button's corner. */
17447
+ Card = "card",
17448
+ /** A wide panel under the bar, its pages in columns. */
17449
+ Mega = "mega"
17450
+ }
17451
+ declare enum MenuReveal {
17452
+ /** A drawer from its edge; any other menu a short drop (today's motion). */
17453
+ Slide = "slide",
17454
+ Fade = "fade",
17455
+ /** Grows from the menu button's centre (transform-origin = the opener). */
17456
+ Zoom = "zoom",
17457
+ /** `clip-path: circle()` grown from the menu button. */
17458
+ Circle = "circle",
17459
+ /** Our own ragged edge (HB-D7) grown from the menu button, rimmed in the look's `menu-edge`. */
17460
+ Torn = "torn"
17461
+ }
17462
+ declare enum MenuButtonKind {
17463
+ /** Three lines that become a cross (the list icon, the drawer's Close an X — today's). */
17464
+ Lines = "lines",
17465
+ /** The word Menu, which becomes Close. */
17466
+ Word = "word",
17467
+ /** Nine dots that spread under the mouse and become a cross. */
17468
+ Dots = "dots"
17469
+ }
17470
+ declare enum MenuHover {
17471
+ /** A line draws under the page name (today's: the drawn underline of a navigation's links). */
17472
+ Line = "line",
17473
+ /** The other page names dim. */
17474
+ Dim = "dim",
17475
+ /** The row under the mouse lights up. */
17476
+ Row = "row",
17477
+ None = "none"
17478
+ }
17479
+ /** What a card, top panel or mega menu becomes on a phone: the drawer, or the full-screen index (the phone ingredient). */
17480
+ declare enum MenuPhoneForm {
17481
+ Drawer = "drawer",
17482
+ Full = "full"
17483
+ }
17484
+ /** The traits, stored in the node's props (no default: a node saved before HI2 saves none). */
17485
+ declare enum MenuTrait {
17486
+ /** On the menu (the Dialog). */
17487
+ Form = "menuForm",
17488
+ Reveal = "menuReveal",
17489
+ Hover = "menuHover",
17490
+ Phone = "menuPhone",
17491
+ /** On the menu button AND the menu's Close (the same button, open). */
17492
+ Button = "menuButton"
17493
+ }
17494
+ declare enum MenuAttribute {
17495
+ Form = "data-iox-menu",
17496
+ Reveal = "data-iox-reveal",
17497
+ Hover = "data-iox-menu-hover",
17498
+ Phone = "data-iox-menu-phone",
17499
+ Button = "data-iox-menu-button"
17500
+ }
17501
+ /** Every attribute a menu part may carry (what a renderer's attribute sync owns). */
17502
+ declare const MENU_ATTRIBUTES: ReadonlyArray<string>;
17503
+ /** A menu's whole look. */
17504
+ interface MenuLook {
17505
+ form: MenuForm;
17506
+ reveal: MenuReveal;
17507
+ button: MenuButtonKind;
17508
+ hover: MenuHover;
17509
+ phone: MenuPhoneForm;
17510
+ }
17511
+ /** Today's menu, every default (R-H4: it writes nothing). */
17512
+ declare const DEFAULT_MENU_LOOK: Readonly<MenuLook>;
17513
+ declare const menuFormOf: (v: unknown) => MenuForm;
17514
+ declare const menuRevealOf: (v: unknown) => MenuReveal;
17515
+ declare const menuButtonOf: (v: unknown) => MenuButtonKind;
17516
+ declare const menuHoverOf: (v: unknown) => MenuHover;
17517
+ declare const menuPhoneOf: (v: unknown) => MenuPhoneForm;
17518
+ /** Reads a trait (`props` on a serialized node). */
17519
+ type MenuTraitReader = (name: MenuTrait) => unknown;
17520
+ /** The attributes a MENU (the Dialog) renders from its traits — `{}` for today's drawer. */
17521
+ declare function menuDialogAttributes(read: MenuTraitReader): Record<string, string>;
17522
+ /** The attribute a menu BUTTON (or the menu's Close) renders — `{}` for today's list icon. */
17523
+ declare function menuButtonAttributes(read: MenuTraitReader): Record<string, string>;
17524
+ /** The traits a menu's Dialog is stamped with for a look: only what differs from today's (R-H4). */
17525
+ declare function menuDialogProps(look: Partial<MenuLook>): Record<string, string>;
17526
+ /** The trait a menu button (and the Close) is stamped with for a kind: none for today's. */
17527
+ declare function menuButtonProps(kind: MenuButtonKind | undefined): Record<string, string>;
17528
+ /** True when the form shows its own place only above the phone width (a card, a top panel, a mega panel — R-H10: on a
17529
+ * phone each becomes the phone menu). A drawer and the full screen are the same at every width. */
17530
+ declare function menuFormSwitchesOnPhone(form: MenuForm): boolean;
17531
+ /** The width (CSS px) at and below which a card, panel or mega menu becomes its phone form — the shared CSS's
17532
+ * `@media (max-width: 767px)` and the canvas's container query (Mobile landscape, the phone menu's default). */
17533
+ declare const MENU_PHONE_MAX_WIDTH = 767;
17534
+
17389
17535
  /**
17390
17536
  * Flavors v1 (flavors-and-theming-plan.md, F1–F2): a pack is its TOKENS plus the accent hue
17391
17537
  * opinion the brand derivation reads. The per-type `defaults` map and its resolvers are gone
@@ -18895,5 +19041,5 @@ declare function presetChoices(id: string, mode?: DesignMode): DesignChoices | n
18895
19041
  */
18896
19042
  declare function stylePresetOfChoices(choices: DesignChoices | null | undefined): StylePreset | undefined;
18897
19043
 
18898
- export { ACCENT_TOKEN_NAMES, ANIMATE_IDS, AdoptOutcome, AdoptSkipReason, BAR_RESERVE_BREAKPOINTS, BAR_RESERVE_CLASS, BETWEEN_IDS, BOTTOM_BAR_STYLE, BUTTON_VARIANT_TO_STYLE, CANVAS_LINK_ATTRIBUTE, CARD_LINK_CLASS, COLOR_SCHEMES, COLOR_SCHEME_TRAIT, COLOR_SCHEME_TYPES, COMPOSED_HEADER, CONTRAST_AUDIT_MEMORY, ColorScheme, ColourCheckId, DEFAULT_FLAVOR_ID, DESIGN_TOKEN_GROUPS, DESIGN_TOKEN_TIERS, DESIGN_TOKEN_TYPES, DesignConfigKey, ELEMENT_STYLES, ELEMENT_STYLE_MARKER_CLASS, ELEMENT_STYLE_STATES, EMPTY_IMAGE_ATTRIBUTE, EMPTY_IMAGE_SRC, ElementStyleState, EntranceParam, FIELD_INVALID_CLASS, FLAVOR_SPEC_VERSION, FONT_CATALOG, FONT_FAMILY_TOKENS, FONT_FILE_ACCEPT, FONT_FILE_EXTENSIONS, FONT_FILE_FORMATS, FONT_STYLES, FONT_WEIGHTS, FieldClass, FontUploadError, GOOGLE_FONTS_CSS_ORIGIN, GOOGLE_FONTS_FILE_ORIGIN, HEADER_THEME_COLOR_TOKEN, HELD_CONTRAST, HeaderAttribute, HeaderBehaviour, HeaderEdge, HeaderTrait, INHERITED_TEXT, LinkType, MARK_STYLES, MAX_FONT_FILE_BYTES, MOOD_IDS, MOOD_LABELS, NEW_NODE_STYLE_DEFAULTS, OPENING_ATTRIBUTE, OPENING_FOLLOWER_ROLE, OPENING_SETTING, OwnedTraitLink, PALETTE_PRESETS, PRE_DS2_FLAVOR_DEFAULTS, PRE_MOTION, PRE_TINT_DEFAULT, REDUCED_DESIGN_MOTION, REDUCED_MOTION_OVERRIDES, REDUCED_TRANSPARENCY_OVERRIDES, REVERT_WINDOW_MS, ROW_INDEX_ATTRIBUTE, SCHEME_INK, SCROLL_IDS, SPEC_A11Y, SPEC_AXES, SPEC_BUTTON_VARIANT_TO_STYLE, SPEC_CONTRAST, SPEC_CONTRAST_AUDIT, SPEC_DEFAULT_ELEMENT_STYLE, SPEC_ELEMENT_STYLES, SPEC_FIELD_CLASS_BASELINE, SPEC_FLAVORS, SPEC_FLAVOR_PACKS, SPEC_FLOATING_BASELINE, SPEC_FONTS, SPEC_FONT_METRICS, SPEC_FONT_ROLES, SPEC_INK_SCOPES, SPEC_LEGACY_ALIASES, SPEC_MOODS, SPEC_PALETTE_PRESETS, SPEC_SCHEMES, SPEC_SCHEME_INK, SPEC_SCRIPTS, SPEC_SPRINGS, SPEC_STYLE_PRESETS, SPEC_TIERS, SPEC_TIER_IDS, SPEC_TOKEN_TYPES, STAGGER_MAX_ITEMS, STAGGER_SHRINK, STYLE_PRESETS, SUPERSEDED_STYLE_VALUES, SWISS_FLAVOR, THEME_COLOR_TOKEN, TINT_FULL_CHROMA, TINT_IDS, TINT_LEVELS, TINT_OWN_HUE_CHROMA, TINT_TURN_CHROMA, USER_TOKEN_SOURCE, WCAG_AA_TEXT, WCAG_AA_UI, adoptElementStyles, adoptionStyleFor, apcaLc, applyElementStyle, applyHeadingLevelRule, atLightness, atLightnessMaxChroma, auditDesignContrast, barReserveClass, buildFlavorTokens, buildFontFaceCss, buttonBlockHref, catalogFontId, checkFontWeight, choicesForPack, colorSchemeClass, colorSchemeOf, colourTabChecks, compareFontWeights, compileSchemeCss, compileTokenCss, compileTokenCssBlocks, compositeOver, cssString, defaultDesignChoices, defaultElementStyleFor, deriveAccentTokens, deriveBrandTokens, designApplySnapshot, designBaseline, designConfigEntries, designModeOf, designMotionOf, designRevertConfig, designTokenRepairs, designTokenRows, drawsScript, elementStyleById, elementStyleClass, elementStyleFace, elementStylesFor, emptyImageLabelSrc, emptyImagePlaceholder, emptyImageSrc, ensureAlpha, ensureContrast, entranceDelay, flavorColours, flavorPackById, flavorSeedWrites, flavorSourceStamp, fontFamilyKey, fontFileName, fontFileStem, fontFormatOf, fontPreloads, fontRoleReferences, fontStackWithout, fontWeightCovers, fontWeightRange, fontWeightValue, fontsForTokens, formatFontFamilies, formatFontFamily, formatFontWeight, googleFontHref, groupFontFamilies, hasElementStyleMarker, headerAttributes, headerBehaviourOf, headerEdgeOf, headerStaysAtTop, headingHref, inSrgbGamut, isDesignTokenGroup, isDesignTokenTier, isDesignTokenType, isFontWeightRange, isRetiredFlavorId, legacyDesignTokenRows, legacyFlavorTokens, legacyRuleTokenReferences, matchFontWeight, missingDesignRows, missingFontRoles, nodeDesignClasses, normalizeFontStyle, normalizeFontWeight, normalizeFontWeightValue, oklabToRgb, openingFollowerSelector, ownedTraitStatus, ownedTraitsOf, packDesignChoices, pageOpeningScheme, paintColours, parseCssColour, parseFontFamilies, parseFontWeight, parseHexColor, planDesignApply, planDesignRevert, planFlavorRevert, planFlavorSeed, planFontFamilyRemoval, planSwissMigration, preTintAccentGrounds, presetChoices, presetModes, previewElementStyleAdoption, previewFontWeight, quantizeRgb, readDesignConfig, readOwnedTrait, relativeLuminance, releaseElementStyle, repeatedRowIndex, resolveDesignChoices, resolveDesignMotion, resolveSchemeTokenValues, resolveTokenReferences, resolveTokenValues, revertAvailable, rgbToOklab, ringColour, roleClass, sameDesignChoices, scriptsForLocale, setColorScheme, specTokenNames, splitTopLevel, springToLinear, stackNamesFamily, staggerDelay, styleKeyToKebab, stylePresetById, stylePresetOfChoices, switchElementStyle, syncNodeDesignClasses, textWidthEm, themeColors, toHexColor, tokenReferences, tokensToDarkVarMap, tokensToVarMap, unknownTokenReferences, untouchedSeedRow, userFontStack, validateFlavorPack, wcagContrastRatio, withSchemeInk, withoutScriptPartners, writeFieldError, writeOwnedTrait };
18899
- export type { AccentBackgrounds, AccentGround, AccentTokenName, AdoptContext, AdoptReport, AdoptableNode, AdoptedNode, AnimateId, ApplyElementStyleResult, BetweenId, ButtonBlockLinkProps, ColourCheck, ColourFlavor, ContrastFinding, DensityId, DesignApplyOptions, DesignChoices, DesignClassSource, DesignConfigEntry, DesignMode, DesignMotion, DesignRevertSnapshot, DesignTokenGroup, DesignTokenLike, DesignTokenRow, DesignTokenTier, DesignTokenType, ElementStyle, ElementStyleTarget, ElementStyleTraitLike, FlavorColours, FlavorPack, FlavorPackV2, FlavorPalette, FlavorRevertPlan, FlavorRevertSnapshot, FlavorRevertWrite, FlavorSeedOptions, FlavorSeedPlan, FlavorSpecToken, FlavorTintConfig, FlavorTokenDef, FontDescriptor, FontFamilyGroup, FontFamilyRemoval, FontFamilyToken, FontFormat, FontPair, FontRoleToken, FontStyle, FontWeight, FontWeightRange, FontsForTokensOptions, KeptEdit, LinearSpring, MissingFontRole, MoodId, MotionId, NodeLinkProps, OkLab, OwnedTrait, OwnedTraitStatus, PalettePreset, PresetMode, ResolvedMode, Rgb, Rgba, SchemeId, ScriptId, ScrollId, SeedBaseline, SeedExpectation, ShapeId, SkippedNode, StaggerSpec, StoredDesign, StoredDesignTokenRow, StylePreset, SupersededStyleValue, SwissMigration, SwitchElementStyleResult, ThemeColorOptions, ThemeColors, TimedAction, TintId, TintLevel, TokenCssBlocks, TokenCssOptions, TypeFace };
19044
+ export { ACCENT_TOKEN_NAMES, ANIMATE_IDS, AdoptOutcome, AdoptSkipReason, BAR_RESERVE_BREAKPOINTS, BAR_RESERVE_CLASS, BETWEEN_IDS, BOTTOM_BAR_STYLE, BUTTON_VARIANT_TO_STYLE, CANVAS_LINK_ATTRIBUTE, CARD_LINK_CLASS, COLOR_SCHEMES, COLOR_SCHEME_TRAIT, COLOR_SCHEME_TYPES, COMPOSED_HEADER, CONTRAST_AUDIT_MEMORY, ColorScheme, ColourCheckId, DEFAULT_FLAVOR_ID, DEFAULT_MENU_LOOK, DESIGN_TOKEN_GROUPS, DESIGN_TOKEN_TIERS, DESIGN_TOKEN_TYPES, DesignConfigKey, ELEMENT_STYLES, ELEMENT_STYLE_MARKER_CLASS, ELEMENT_STYLE_STATES, EMPTY_IMAGE_ATTRIBUTE, EMPTY_IMAGE_SRC, ElementStyleState, EntranceParam, FIELD_INVALID_CLASS, FLAVOR_SPEC_VERSION, FONT_CATALOG, FONT_FAMILY_TOKENS, FONT_FILE_ACCEPT, FONT_FILE_EXTENSIONS, FONT_FILE_FORMATS, FONT_STYLES, FONT_WEIGHTS, FieldClass, FontUploadError, GOOGLE_FONTS_CSS_ORIGIN, GOOGLE_FONTS_FILE_ORIGIN, HEADER_THEME_COLOR_TOKEN, HELD_CONTRAST, HeaderAttribute, HeaderBehaviour, HeaderEdge, HeaderTrait, INHERITED_TEXT, LinkType, MARK_STYLES, MAX_FONT_FILE_BYTES, MENU_ATTRIBUTES, MENU_PHONE_MAX_WIDTH, MOOD_IDS, MOOD_LABELS, MenuAttribute, MenuButtonKind, MenuForm, MenuHover, MenuPhoneForm, MenuReveal, MenuTrait, NEW_NODE_STYLE_DEFAULTS, OPENING_ATTRIBUTE, OPENING_FOLLOWER_ROLE, OPENING_SETTING, OwnedTraitLink, PALETTE_PRESETS, PRE_DS2_FLAVOR_DEFAULTS, PRE_MOTION, PRE_TINT_DEFAULT, REDUCED_DESIGN_MOTION, REDUCED_MOTION_OVERRIDES, REDUCED_TRANSPARENCY_OVERRIDES, REVERT_WINDOW_MS, ROW_INDEX_ATTRIBUTE, SCHEME_INK, SCROLL_IDS, SPEC_A11Y, SPEC_AXES, SPEC_BUTTON_VARIANT_TO_STYLE, SPEC_CONTRAST, SPEC_CONTRAST_AUDIT, SPEC_DEFAULT_ELEMENT_STYLE, SPEC_ELEMENT_STYLES, SPEC_FIELD_CLASS_BASELINE, SPEC_FLAVORS, SPEC_FLAVOR_PACKS, SPEC_FLOATING_BASELINE, SPEC_FONTS, SPEC_FONT_METRICS, SPEC_FONT_ROLES, SPEC_INK_SCOPES, SPEC_LEGACY_ALIASES, SPEC_MOODS, SPEC_PALETTE_PRESETS, SPEC_SCHEMES, SPEC_SCHEME_INK, SPEC_SCRIPTS, SPEC_SPRINGS, SPEC_STYLE_PRESETS, SPEC_TIERS, SPEC_TIER_IDS, SPEC_TOKEN_TYPES, STAGGER_MAX_ITEMS, STAGGER_SHRINK, STYLE_PRESETS, SUPERSEDED_STYLE_VALUES, SWISS_FLAVOR, THEME_COLOR_TOKEN, TINT_FULL_CHROMA, TINT_IDS, TINT_LEVELS, TINT_OWN_HUE_CHROMA, TINT_TURN_CHROMA, USER_TOKEN_SOURCE, WCAG_AA_TEXT, WCAG_AA_UI, adoptElementStyles, adoptionStyleFor, apcaLc, applyElementStyle, applyHeadingLevelRule, atLightness, atLightnessMaxChroma, auditDesignContrast, barReserveClass, buildFlavorTokens, buildFontFaceCss, buttonBlockHref, catalogFontId, checkFontWeight, choicesForPack, colorSchemeClass, colorSchemeOf, colourTabChecks, compareFontWeights, compileSchemeCss, compileTokenCss, compileTokenCssBlocks, compositeOver, cssString, defaultDesignChoices, defaultElementStyleFor, deriveAccentTokens, deriveBrandTokens, designApplySnapshot, designBaseline, designConfigEntries, designModeOf, designMotionOf, designRevertConfig, designTokenRepairs, designTokenRows, drawsScript, elementStyleById, elementStyleClass, elementStyleFace, elementStylesFor, emptyImageLabelSrc, emptyImagePlaceholder, emptyImageSrc, ensureAlpha, ensureContrast, entranceDelay, flavorColours, flavorPackById, flavorSeedWrites, flavorSourceStamp, fontFamilyKey, fontFileName, fontFileStem, fontFormatOf, fontPreloads, fontRoleReferences, fontStackWithout, fontWeightCovers, fontWeightRange, fontWeightValue, fontsForTokens, formatFontFamilies, formatFontFamily, formatFontWeight, googleFontHref, groupFontFamilies, hasElementStyleMarker, headerAttributes, headerBehaviourOf, headerEdgeOf, headerStaysAtTop, headingHref, inSrgbGamut, isDesignTokenGroup, isDesignTokenTier, isDesignTokenType, isFontWeightRange, isRetiredFlavorId, legacyDesignTokenRows, legacyFlavorTokens, legacyRuleTokenReferences, matchFontWeight, menuButtonAttributes, menuButtonOf, menuButtonProps, menuDialogAttributes, menuDialogProps, menuFormOf, menuFormSwitchesOnPhone, menuHoverOf, menuPhoneOf, menuRevealOf, missingDesignRows, missingFontRoles, nodeDesignClasses, normalizeFontStyle, normalizeFontWeight, normalizeFontWeightValue, oklabToRgb, openingFollowerSelector, ownedTraitStatus, ownedTraitsOf, packDesignChoices, pageOpeningScheme, paintColours, parseCssColour, parseFontFamilies, parseFontWeight, parseHexColor, planDesignApply, planDesignRevert, planFlavorRevert, planFlavorSeed, planFontFamilyRemoval, planSwissMigration, preTintAccentGrounds, presetChoices, presetModes, previewElementStyleAdoption, previewFontWeight, quantizeRgb, readDesignConfig, readOwnedTrait, relativeLuminance, releaseElementStyle, repeatedRowIndex, resolveDesignChoices, resolveDesignMotion, resolveSchemeTokenValues, resolveTokenReferences, resolveTokenValues, revertAvailable, rgbToOklab, ringColour, roleClass, sameDesignChoices, scriptsForLocale, setColorScheme, specTokenNames, splitTopLevel, springToLinear, stackNamesFamily, staggerDelay, styleKeyToKebab, stylePresetById, stylePresetOfChoices, switchElementStyle, syncNodeDesignClasses, textWidthEm, themeColors, toHexColor, tokenReferences, tokensToDarkVarMap, tokensToVarMap, unknownTokenReferences, untouchedSeedRow, userFontStack, validateFlavorPack, wcagContrastRatio, withSchemeInk, withoutScriptPartners, writeFieldError, writeOwnedTrait };
19045
+ export type { AccentBackgrounds, AccentGround, AccentTokenName, AdoptContext, AdoptReport, AdoptableNode, AdoptedNode, AnimateId, ApplyElementStyleResult, BetweenId, ButtonBlockLinkProps, ColourCheck, ColourFlavor, ContrastFinding, DensityId, DesignApplyOptions, DesignChoices, DesignClassSource, DesignConfigEntry, DesignMode, DesignMotion, DesignRevertSnapshot, DesignTokenGroup, DesignTokenLike, DesignTokenRow, DesignTokenTier, DesignTokenType, ElementStyle, ElementStyleTarget, ElementStyleTraitLike, FlavorColours, FlavorPack, FlavorPackV2, FlavorPalette, FlavorRevertPlan, FlavorRevertSnapshot, FlavorRevertWrite, FlavorSeedOptions, FlavorSeedPlan, FlavorSpecToken, FlavorTintConfig, FlavorTokenDef, FontDescriptor, FontFamilyGroup, FontFamilyRemoval, FontFamilyToken, FontFormat, FontPair, FontRoleToken, FontStyle, FontWeight, FontWeightRange, FontsForTokensOptions, KeptEdit, LinearSpring, MenuLook, MenuTraitReader, MissingFontRole, MoodId, MotionId, NodeLinkProps, OkLab, OwnedTrait, OwnedTraitStatus, PalettePreset, PresetMode, ResolvedMode, Rgb, Rgba, SchemeId, ScriptId, ScrollId, SeedBaseline, SeedExpectation, ShapeId, SkippedNode, StaggerSpec, StoredDesign, StoredDesignTokenRow, StylePreset, SupersededStyleValue, SwissMigration, SwitchElementStyleResult, ThemeColorOptions, ThemeColors, TimedAction, TintId, TintLevel, TokenCssBlocks, TokenCssOptions, TypeFace };
@@ -473,6 +473,69 @@ function focusDialogSheet(dialog) {
473
473
  return true;
474
474
  }
475
475
 
476
+ /**
477
+ * Where a menu's REVEAL grows from (header-ingredients HI2a; header-builder board 2: "origin = the opener's centre"). A
478
+ * zoom scales about it, a circle and the torn edge open from it — so the menu reads as coming OUT of the button that opened
479
+ * it. The reveals themselves are CSS transitions in the shared `iox-design.css` (Emil: a menu toggles, so it must reverse
480
+ * from its live value — a transition, never keyframes); the one beat of script is this: put the opener's centre, in the
481
+ * menu's own box, into two custom properties when the menu opens. ONE function for the live page and the builder canvas
482
+ * (each passes its own box measure). Framework-free.
483
+ */
484
+ var RevealOriginProperty;
485
+ (function (RevealOriginProperty) {
486
+ RevealOriginProperty["X"] = "--reveal-x";
487
+ RevealOriginProperty["Y"] = "--reveal-y";
488
+ /** How far the reveal must grow to cover the menu: the distance to its farthest corner (a circle of this radius,
489
+ * centred on the origin, covers the whole box — so the reveal spends its time ON the menu, not past it). */
490
+ RevealOriginProperty["R"] = "--reveal-r";
491
+ })(RevealOriginProperty || (RevealOriginProperty = {}));
492
+ /**
493
+ * The reveal origin in the menu's own box (CSS px, from its top-left border edge): the opener's centre, or — opened by
494
+ * anything else (a link, an action on another element) — the menu's top corner on its side. `box` is the menu's
495
+ * UNTRANSFORMED box, in the same space as the opener's rect. Pure.
496
+ */
497
+ function revealOrigin(opener, box, options = {}) {
498
+ const scale = options.scale && options.scale > 0 ? options.scale : 1;
499
+ const width = box.width / scale;
500
+ const height = box.height / scale;
501
+ const at = !opener || !(opener.width > 0 || opener.height > 0)
502
+ ? { x: Math.round(options.atLeft ? 0 : width), y: 0 }
503
+ : { x: Math.round(((opener.left + opener.width / 2) - box.left) / scale), y: Math.round(((opener.top + opener.height / 2) - box.top) / scale) };
504
+ const r = Math.ceil(Math.max(...[[0, 0], [width, 0], [0, height], [width, height]].map(([cx, cy]) => Math.hypot(cx - at.x, cy - at.y))));
505
+ return { ...at, r };
506
+ }
507
+ /** The custom properties for an origin. */
508
+ function revealOriginStyle(origin) {
509
+ return { [RevealOriginProperty.X]: `${origin.x}px`, [RevealOriginProperty.Y]: `${origin.y}px`, [RevealOriginProperty.R]: `${origin.r}px` };
510
+ }
511
+ const rendered = (el) => {
512
+ if (!el)
513
+ return false;
514
+ if (el.getClientRects && !el.getClientRects().length)
515
+ return false;
516
+ const r = el.getBoundingClientRect();
517
+ return r.width > 0 || r.height > 0;
518
+ };
519
+ /**
520
+ * Set a just-opened live `<dialog>`'s reveal origin from the element that opened it (`opener`), else from the first of its
521
+ * openers that is on screen (`aria-controls` — the menu button at its width), else its top corner. Call it right after
522
+ * `showModal()`. A top-layer dialog is fixed at `inset: 0`, so its untransformed box starts at its USED margins — a
523
+ * reveal's starting scale or translate never moves a margin, whereas `getBoundingClientRect` would read it.
524
+ */
525
+ function revealFrom(dialog, opener) {
526
+ const view = dialog?.ownerDocument?.defaultView;
527
+ if (!dialog || !view)
528
+ return;
529
+ const cs = view.getComputedStyle(dialog);
530
+ const box = { left: parseFloat(cs.marginLeft) || 0, top: parseFloat(cs.marginTop) || 0, width: dialog.offsetWidth, height: dialog.offsetHeight };
531
+ const from = rendered(opener) ? opener
532
+ : dialog.id ? Array.from(dialog.ownerDocument.querySelectorAll(dialogOpenersSelector(dialog.id))).find(rendered) ?? null : null;
533
+ const atLeft = (dialog.getAttribute('data-iox-dialog-placement') === 'start') !== (cs.direction === 'rtl');
534
+ const origin = revealOrigin(from ? from.getBoundingClientRect() : null, box, { atLeft });
535
+ for (const [name, value] of Object.entries(revealOriginStyle(origin)))
536
+ dialog.style.setProperty(name, value);
537
+ }
538
+
476
539
  /**
477
540
  * @vectoriox/iox-ui/actions-core — the shared, FRAMEWORK-FREE action vocabulary.
478
541
  *
@@ -488,5 +551,5 @@ function focusDialogSheet(dialog) {
488
551
  * Generated bundle index. Do not edit.
489
552
  */
490
553
 
491
- export { ACCOUNT_ACTION_TYPES, BEHAVIOUR_ACTION_TYPES, CONSENT_ACTION_TYPES, COUNT_UP_TRIGGERS, DIALOG_ACTION_TYPE_SET, DIALOG_CLOSING_ATTRIBUTE, DIALOG_EXIT_TIMEOUT_MS, DIALOG_OPENER_ACTION_TYPES, DIALOG_OPENER_TRIGGER, DIALOG_SELECTOR, ELEMENT_ACTION_DESCRIPTORS, ELEMENT_ACTION_GROUP_ORDER, FORM_SUBMIT_ACTION_DESCRIPTORS, ITEM_ACTION_TYPES, OpenerAttribute, POPOVER_ACTION_TYPE_SET, POPOVER_NODE_TYPE, POPOVER_OPENER_ACTION_TYPES, SCROLL_PROGRESS_TRIGGER, SERVER_ELEMENT_ACTION_TYPES, SHOP_ACTION_TYPES, SHOP_ENTITLEMENT, TOAST_ACTION_TYPES, actionOfferedUnder, addableActions, cancelExit, closeDialogAnimated, dialogDomId, dialogOpenerAttributes, dialogOpenersSelector, dialogTogglesClosed, focusDialogSheet, groupedElementActions, isExiting, itemActionOf, nodeIdOfDialogDomId, nodeIdOfPopoverDomId, openedDialogId, openedPopoverId, openedTargetId, opensAtClickedItem, popoverDomId, popoverOpenerAttributes, popoverOpenersSelector, resolveActionAvailability, runExitMotion };
554
+ export { ACCOUNT_ACTION_TYPES, BEHAVIOUR_ACTION_TYPES, CONSENT_ACTION_TYPES, COUNT_UP_TRIGGERS, DIALOG_ACTION_TYPE_SET, DIALOG_CLOSING_ATTRIBUTE, DIALOG_EXIT_TIMEOUT_MS, DIALOG_OPENER_ACTION_TYPES, DIALOG_OPENER_TRIGGER, DIALOG_SELECTOR, ELEMENT_ACTION_DESCRIPTORS, ELEMENT_ACTION_GROUP_ORDER, FORM_SUBMIT_ACTION_DESCRIPTORS, ITEM_ACTION_TYPES, OpenerAttribute, POPOVER_ACTION_TYPE_SET, POPOVER_NODE_TYPE, POPOVER_OPENER_ACTION_TYPES, RevealOriginProperty, SCROLL_PROGRESS_TRIGGER, SERVER_ELEMENT_ACTION_TYPES, SHOP_ACTION_TYPES, SHOP_ENTITLEMENT, TOAST_ACTION_TYPES, actionOfferedUnder, addableActions, cancelExit, closeDialogAnimated, dialogDomId, dialogOpenerAttributes, dialogOpenersSelector, dialogTogglesClosed, focusDialogSheet, groupedElementActions, isExiting, itemActionOf, nodeIdOfDialogDomId, nodeIdOfPopoverDomId, openedDialogId, openedPopoverId, openedTargetId, opensAtClickedItem, popoverDomId, popoverOpenerAttributes, popoverOpenersSelector, resolveActionAvailability, revealFrom, revealOrigin, revealOriginStyle, runExitMotion };
492
555
  //# sourceMappingURL=vectoriox-iox-ui-actions-core.mjs.map