@nldd/design-system 0.19.0 → 0.20.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/custom-elements.json +317 -49
- package/dist/components/actions/button/button.d.ts +5 -5
- package/dist/components/actions/button/button.d.ts.map +1 -1
- package/dist/components/actions/button/button.js +6 -6
- package/dist/components/actions/button/button.js.map +1 -1
- package/dist/components/actions/button/button.template.d.ts.map +1 -1
- package/dist/components/actions/button/button.template.js +6 -8
- package/dist/components/actions/button/button.template.js.map +1 -1
- package/dist/components/actions/button-bar/button-bar.d.ts.map +1 -1
- package/dist/components/actions/button-bar/button-bar.js +15 -4
- package/dist/components/actions/button-bar/button-bar.js.map +1 -1
- package/dist/components/actions/button-group/button-group.d.ts.map +1 -1
- package/dist/components/actions/button-group/button-group.js +7 -1
- package/dist/components/actions/button-group/button-group.js.map +1 -1
- package/dist/components/actions/button-group/button-group.styles.js +2 -2
- package/dist/components/actions/icon-button/icon-button.d.ts +3 -3
- package/dist/components/actions/icon-button/icon-button.d.ts.map +1 -1
- package/dist/components/actions/icon-button/icon-button.js +4 -4
- package/dist/components/actions/icon-button/icon-button.js.map +1 -1
- package/dist/components/actions/icon-button/icon-button.template.d.ts.map +1 -1
- package/dist/components/actions/icon-button/icon-button.template.js +2 -4
- package/dist/components/actions/icon-button/icon-button.template.js.map +1 -1
- package/dist/components/actions/menu/menu-item.d.ts +6 -1
- package/dist/components/actions/menu/menu-item.d.ts.map +1 -1
- package/dist/components/actions/menu/menu-item.js +15 -5
- package/dist/components/actions/menu/menu-item.js.map +1 -1
- package/dist/components/actions/menu/menu.d.ts +31 -8
- package/dist/components/actions/menu/menu.d.ts.map +1 -1
- package/dist/components/actions/menu/menu.js +107 -31
- package/dist/components/actions/menu/menu.js.map +1 -1
- package/dist/components/actions/menu/menu.pointer.d.ts +7 -0
- package/dist/components/actions/menu/menu.pointer.d.ts.map +1 -1
- package/dist/components/actions/menu/menu.pointer.js +17 -0
- package/dist/components/actions/menu/menu.pointer.js.map +1 -1
- package/dist/components/actions/menu/menu.safe-triangle.d.ts +6 -5
- package/dist/components/actions/menu/menu.safe-triangle.d.ts.map +1 -1
- package/dist/components/actions/menu/menu.safe-triangle.js +3 -3
- package/dist/components/actions/menu/menu.safe-triangle.js.map +1 -1
- package/dist/components/actions/menu/menu.styles.d.ts.map +1 -1
- package/dist/components/actions/menu/menu.styles.js +6 -0
- package/dist/components/actions/menu/menu.styles.js.map +1 -1
- package/dist/components/actions/menu/menu.template.d.ts.map +1 -1
- package/dist/components/actions/menu/menu.template.js +15 -8
- package/dist/components/actions/menu/menu.template.js.map +1 -1
- package/dist/components/actions/toolbar/toolbar-title.js +2 -2
- package/dist/components/actions/toolbar/toolbar-title.js.map +1 -1
- package/dist/components/components.js +645 -297
- package/dist/components/content/avatar/avatar.js +1 -1
- package/dist/components/content/avatar/avatar.js.map +1 -1
- package/dist/components/content/avatar-group/avatar-group.d.ts.map +1 -1
- package/dist/components/content/avatar-group/avatar-group.js +2 -1
- package/dist/components/content/avatar-group/avatar-group.js.map +1 -1
- package/dist/components/content/image/image.js +1 -1
- package/dist/components/content/image/image.js.map +1 -1
- package/dist/components/content/tag/tag.d.ts +3 -3
- package/dist/components/content/tag/tag.js +3 -3
- package/dist/components/content/tag/tag.template.js +3 -3
- package/dist/components/content/tag/tag.template.js.map +1 -1
- package/dist/components/content/title/title.js +1 -1
- package/dist/components/content/title/title.js.map +1 -1
- package/dist/components/content/token/token.d.ts +6 -4
- package/dist/components/content/token/token.d.ts.map +1 -1
- package/dist/components/content/token/token.js +6 -4
- package/dist/components/content/token/token.js.map +1 -1
- package/dist/components/content/token/token.template.js +1 -1
- package/dist/components/content/token/token.template.js.map +1 -1
- package/dist/components/{reflect-non-default-B9wQcnne.js → decorate-DD7uUxHb.js} +16 -1
- package/dist/components/{defer-focus-BQ3c4mzj.js → defer-focus-dzorHsCQ.js} +2 -2
- package/dist/components/{dev-checks-lQ-gHUjV.js → dev-checks-CLB9G43h.js} +5 -0
- package/dist/components/{icon-CrBk3W-t.js → icon-_Eox7ZfO.js} +1 -2
- package/dist/components/{icon-button-CfpnGzYQ.js → icon-button-8gvQCwCW.js} +8 -11
- package/dist/components/{input-modality-CiPLYYMN.js → input-modality-D_CY185R.js} +8 -2
- package/dist/components/inputs/file-field/file-field.js +1 -1
- package/dist/components/inputs/file-field/file-field.js.map +1 -1
- package/dist/components/inputs/one-time-code-field/one-time-code-field.styles.d.ts.map +1 -1
- package/dist/components/inputs/one-time-code-field/one-time-code-field.styles.js +4 -2
- package/dist/components/inputs/one-time-code-field/one-time-code-field.styles.js.map +1 -1
- package/dist/components/inputs/one-time-code-field/one-time-code-field.template.js +2 -2
- package/dist/components/inputs/one-time-code-field/one-time-code-field.template.js.map +1 -1
- package/dist/components/inputs/segmented-control/segmented-control.d.ts +2 -2
- package/dist/components/inputs/segmented-control/segmented-control.js +4 -4
- package/dist/components/inputs/segmented-control/segmented-control.js.map +1 -1
- package/dist/components/inputs/segmented-control/segmented-control.template.js +2 -2
- package/dist/components/inputs/segmented-control/segmented-control.template.js.map +1 -1
- package/dist/components/inputs/swatch-picker/swatch-picker.js +1 -1
- package/dist/components/inputs/swatch-picker/swatch-picker.js.map +1 -1
- package/dist/components/inputs/time-picker/time-picker.js +1 -1
- package/dist/components/inputs/time-picker/time-picker.js.map +1 -1
- package/dist/components/inputs/toggle-button/toggle-button.d.ts +2 -2
- package/dist/components/inputs/toggle-button/toggle-button.js +3 -3
- package/dist/components/inputs/toggle-button/toggle-button.js.map +1 -1
- package/dist/components/inputs/toggle-button/toggle-button.template.d.ts.map +1 -1
- package/dist/components/inputs/toggle-button/toggle-button.template.js +7 -10
- package/dist/components/inputs/toggle-button/toggle-button.template.js.map +1 -1
- package/dist/components/inputs/toggle-button-group/toggle-button-group.js +1 -1
- package/dist/components/inputs/toggle-button-group/toggle-button-group.js.map +1 -1
- package/dist/components/inputs/toggle-button-group/toggle-button-group.styles.js +3 -3
- package/dist/components/layout/card/card.js +1 -1
- package/dist/components/layout/card/card.js.map +1 -1
- package/dist/components/layout/card/card.styles.d.ts.map +1 -1
- package/dist/components/layout/card/card.styles.js +3 -1
- package/dist/components/layout/card/card.styles.js.map +1 -1
- package/dist/components/layout/kanban/kanban.d.ts.map +1 -1
- package/dist/components/layout/kanban/kanban.js +2 -1
- package/dist/components/layout/kanban/kanban.js.map +1 -1
- package/dist/components/layout/page/page.d.ts.map +1 -1
- package/dist/components/layout/page/page.js +3 -2
- package/dist/components/layout/page/page.js.map +1 -1
- package/dist/components/layout/page/page.styles.d.ts.map +1 -1
- package/dist/components/layout/page/page.styles.js +3 -2
- package/dist/components/layout/page/page.styles.js.map +1 -1
- package/dist/components/layout/page-footer/page-footer.d.ts +5 -2
- package/dist/components/layout/page-footer/page-footer.d.ts.map +1 -1
- package/dist/components/layout/page-footer/page-footer.js +5 -2
- package/dist/components/layout/page-footer/page-footer.js.map +1 -1
- package/dist/components/layout/page-footer/page-footer.template.d.ts.map +1 -1
- package/dist/components/layout/page-footer/page-footer.template.js +2 -4
- package/dist/components/layout/page-footer/page-footer.template.js.map +1 -1
- package/dist/components/layout/page-sections/full-bleed-section/full-bleed-section.d.ts +1 -1
- package/dist/components/layout/page-sections/full-bleed-section/full-bleed-section.d.ts.map +1 -1
- package/dist/components/layout/page-sections/full-bleed-section/full-bleed-section.js +2 -2
- package/dist/components/layout/page-sections/full-bleed-section/full-bleed-section.js.map +1 -1
- package/dist/components/layout/page-sections/hero/hero.d.ts.map +1 -1
- package/dist/components/layout/page-sections/hero/hero.js +2 -2
- package/dist/components/layout/page-sections/hero/hero.js.map +1 -1
- package/dist/components/layout/page-sections/one-half-one-half-section/one-half-one-half-section.d.ts +1 -1
- package/dist/components/layout/page-sections/one-half-one-half-section/one-half-one-half-section.d.ts.map +1 -1
- package/dist/components/layout/page-sections/one-half-one-half-section/one-half-one-half-section.js +2 -2
- package/dist/components/layout/page-sections/one-half-one-half-section/one-half-one-half-section.js.map +1 -1
- package/dist/components/layout/page-sections/one-third-two-thirds-section/one-third-two-thirds-section.d.ts +1 -1
- package/dist/components/layout/page-sections/one-third-two-thirds-section/one-third-two-thirds-section.d.ts.map +1 -1
- package/dist/components/layout/page-sections/one-third-two-thirds-section/one-third-two-thirds-section.js +2 -2
- package/dist/components/layout/page-sections/one-third-two-thirds-section/one-third-two-thirds-section.js.map +1 -1
- package/dist/components/layout/page-sections/sidebar-section/sidebar-section.d.ts +1 -1
- package/dist/components/layout/page-sections/sidebar-section/sidebar-section.d.ts.map +1 -1
- package/dist/components/layout/page-sections/sidebar-section/sidebar-section.js +4 -4
- package/dist/components/layout/page-sections/sidebar-section/sidebar-section.js.map +1 -1
- package/dist/components/layout/page-sections/simple-section/simple-section.d.ts +1 -1
- package/dist/components/layout/page-sections/simple-section/simple-section.d.ts.map +1 -1
- package/dist/components/layout/page-sections/simple-section/simple-section.js +2 -2
- package/dist/components/layout/page-sections/simple-section/simple-section.js.map +1 -1
- package/dist/components/layout/page-sections/two-thirds-one-third-section/two-thirds-one-third-section.d.ts +1 -1
- package/dist/components/layout/page-sections/two-thirds-one-third-section/two-thirds-one-third-section.d.ts.map +1 -1
- package/dist/components/layout/page-sections/two-thirds-one-third-section/two-thirds-one-third-section.js +2 -2
- package/dist/components/layout/page-sections/two-thirds-one-third-section/two-thirds-one-third-section.js.map +1 -1
- package/dist/components/layout/popover/popover.d.ts +1 -2
- package/dist/components/layout/popover/popover.d.ts.map +1 -1
- package/dist/components/layout/popover/popover.js +10 -12
- package/dist/components/layout/popover/popover.js.map +1 -1
- package/dist/components/layout/sheet/sheet.d.ts +1 -0
- package/dist/components/layout/sheet/sheet.d.ts.map +1 -1
- package/dist/components/layout/sheet/sheet.js +6 -1
- package/dist/components/layout/sheet/sheet.js.map +1 -1
- package/dist/components/layout/spacer/spacer.js +1 -1
- package/dist/components/layout/spacer/spacer.js.map +1 -1
- package/dist/components/layout/split-views/bar-split-view/bar-split-view.d.ts.map +1 -1
- package/dist/components/layout/split-views/bar-split-view/bar-split-view.js +2 -1
- package/dist/components/layout/split-views/bar-split-view/bar-split-view.js.map +1 -1
- package/dist/components/layout/split-views/side-by-side-split-view/side-by-side-split-view.d.ts.map +1 -1
- package/dist/components/layout/split-views/side-by-side-split-view/side-by-side-split-view.js +3 -2
- package/dist/components/layout/split-views/side-by-side-split-view/side-by-side-split-view.js.map +1 -1
- package/dist/components/layout/split-views/split-view-pane/split-view-pane.d.ts.map +1 -1
- package/dist/components/layout/split-views/split-view-pane/split-view-pane.js +2 -1
- package/dist/components/layout/split-views/split-view-pane/split-view-pane.js.map +1 -1
- package/dist/components/layout/split-views/stacked-split-view/stacked-split-view.d.ts.map +1 -1
- package/dist/components/layout/split-views/stacked-split-view/stacked-split-view.js +3 -2
- package/dist/components/layout/split-views/stacked-split-view/stacked-split-view.js.map +1 -1
- package/dist/components/layout/window/window.d.ts +1 -0
- package/dist/components/layout/window/window.d.ts.map +1 -1
- package/dist/components/layout/window/window.js +7 -1
- package/dist/components/layout/window/window.js.map +1 -1
- package/dist/components/lists-and-tables/cells/icon-cell/icon-cell.d.ts +5 -2
- package/dist/components/lists-and-tables/cells/icon-cell/icon-cell.d.ts.map +1 -1
- package/dist/components/lists-and-tables/cells/icon-cell/icon-cell.js +7 -4
- package/dist/components/lists-and-tables/cells/icon-cell/icon-cell.js.map +1 -1
- package/dist/components/lists-and-tables/cells/icon-cell/icon-cell.template.js +3 -3
- package/dist/components/lists-and-tables/cells/icon-cell/icon-cell.template.js.map +1 -1
- package/dist/components/lists-and-tables/cells/spacer-cell/spacer-cell.d.ts.map +1 -1
- package/dist/components/lists-and-tables/cells/spacer-cell/spacer-cell.js +2 -1
- package/dist/components/lists-and-tables/cells/spacer-cell/spacer-cell.js.map +1 -1
- package/dist/components/lists-and-tables/cells/text-cell/text-cell.d.ts +2 -2
- package/dist/components/lists-and-tables/cells/text-cell/text-cell.js +2 -2
- package/dist/components/lists-and-tables/cells/title-cell/title-cell.d.ts +2 -2
- package/dist/components/lists-and-tables/cells/title-cell/title-cell.js +2 -2
- package/dist/components/lists-and-tables/list/list.d.ts.map +1 -1
- package/dist/components/lists-and-tables/list/list.js +4 -1
- package/dist/components/lists-and-tables/list/list.js.map +1 -1
- package/dist/components/lists-and-tables/list-item/list-item.d.ts +12 -9
- package/dist/components/lists-and-tables/list-item/list-item.d.ts.map +1 -1
- package/dist/components/lists-and-tables/list-item/list-item.js +17 -11
- package/dist/components/lists-and-tables/list-item/list-item.js.map +1 -1
- package/dist/components/lists-and-tables/list-item/list-item.styles.d.ts.map +1 -1
- package/dist/components/lists-and-tables/list-item/list-item.styles.js +20 -0
- package/dist/components/lists-and-tables/list-item/list-item.styles.js.map +1 -1
- package/dist/components/lists-and-tables/list-item-segment/list-item-segment.styles.d.ts.map +1 -1
- package/dist/components/lists-and-tables/list-item-segment/list-item-segment.styles.js +6 -0
- package/dist/components/lists-and-tables/list-item-segment/list-item-segment.styles.js.map +1 -1
- package/dist/components/lists-and-tables/table/table.js +5 -5
- package/dist/components/lists-and-tables/table/table.js.map +1 -1
- package/dist/components/navigation/breadcrumbs/breadcrumbs.d.ts +5 -2
- package/dist/components/navigation/breadcrumbs/breadcrumbs.d.ts.map +1 -1
- package/dist/components/navigation/breadcrumbs/breadcrumbs.js +5 -2
- package/dist/components/navigation/breadcrumbs/breadcrumbs.js.map +1 -1
- package/dist/components/navigation/breadcrumbs/breadcrumbs.template.d.ts.map +1 -1
- package/dist/components/navigation/breadcrumbs/breadcrumbs.template.js +2 -4
- package/dist/components/navigation/breadcrumbs/breadcrumbs.template.js.map +1 -1
- package/dist/components/navigation/link/link.d.ts +7 -4
- package/dist/components/navigation/link/link.d.ts.map +1 -1
- package/dist/components/navigation/link/link.js +7 -4
- package/dist/components/navigation/link/link.js.map +1 -1
- package/dist/components/navigation/link/link.template.js +5 -5
- package/dist/components/navigation/link/link.template.js.map +1 -1
- package/dist/components/navigation/menu-bar-item/menu-bar-item.js +1 -1
- package/dist/components/navigation/menu-bar-item/menu-bar-item.js.map +1 -1
- package/dist/components/navigation/pagination/pagination.d.ts.map +1 -1
- package/dist/components/navigation/pagination/pagination.js +3 -2
- package/dist/components/navigation/pagination/pagination.js.map +1 -1
- package/dist/components/navigation/tab-bar/tab-bar.d.ts +18 -2
- package/dist/components/navigation/tab-bar/tab-bar.d.ts.map +1 -1
- package/dist/components/navigation/tab-bar/tab-bar.js +51 -3
- package/dist/components/navigation/tab-bar/tab-bar.js.map +1 -1
- package/dist/components/navigation/tab-bar/tab-bar.template.d.ts.map +1 -1
- package/dist/components/navigation/tab-bar/tab-bar.template.js +5 -3
- package/dist/components/navigation/tab-bar/tab-bar.template.js.map +1 -1
- package/dist/components/navigation/top-navigation-bar/top-navigation-bar.js +2 -2
- package/dist/components/navigation/top-navigation-bar/top-navigation-bar.js.map +1 -1
- package/dist/components/navigation/top-navigation-bar/top-navigation-bar.menu-sheet.d.ts +4 -0
- package/dist/components/navigation/top-navigation-bar/top-navigation-bar.menu-sheet.d.ts.map +1 -1
- package/dist/components/navigation/top-navigation-bar/top-navigation-bar.menu-sheet.js +26 -2
- package/dist/components/navigation/top-navigation-bar/top-navigation-bar.menu-sheet.js.map +1 -1
- package/dist/components/status-and-feedback/banner/banner.js +1 -1
- package/dist/components/status-and-feedback/banner/banner.js.map +1 -1
- package/dist/components/status-and-feedback/inline-dialog/inline-dialog.js +2 -2
- package/dist/components/status-and-feedback/inline-dialog/inline-dialog.js.map +1 -1
- package/dist/components/status-and-feedback/just-in-time-education/just-in-time-education.js +1 -1
- package/dist/components/status-and-feedback/just-in-time-education/just-in-time-education.js.map +1 -1
- package/dist/components/status-and-feedback/modal-dialog/modal-dialog.js +1 -1
- package/dist/components/status-and-feedback/modal-dialog/modal-dialog.js.map +1 -1
- package/dist/components/status-and-feedback/notification/notification.js +2 -2
- package/dist/components/status-and-feedback/notification/notification.js.map +1 -1
- package/dist/components/status-and-feedback/progress-bar/progress-bar.js +4 -4
- package/dist/components/status-and-feedback/progress-bar/progress-bar.js.map +1 -1
- package/dist/components/status-and-feedback/progress-circle/progress-circle.js +4 -4
- package/dist/components/status-and-feedback/progress-circle/progress-circle.js.map +1 -1
- package/dist/components/status-and-feedback/step-bar/step-bar.d.ts +5 -2
- package/dist/components/status-and-feedback/step-bar/step-bar.d.ts.map +1 -1
- package/dist/components/status-and-feedback/step-bar/step-bar.js +6 -3
- package/dist/components/status-and-feedback/step-bar/step-bar.js.map +1 -1
- package/dist/components/status-and-feedback/step-bar/step-bar.template.js +1 -1
- package/dist/components/status-and-feedback/step-bar/step-bar.template.js.map +1 -1
- package/dist/components/{visibility-mixin-BMtETgjk.js → visibility-mixin-Dzn48SL8.js} +1 -1
- package/dist/css/variables.css +6 -0
- package/dist/nldd.min.js +823 -767
- package/dist/types/vue.d.ts +15 -11
- package/dist/utilities/dev-rules.generated.d.ts.map +1 -1
- package/dist/utilities/dev-rules.generated.js +5 -0
- package/dist/utilities/dev-rules.generated.js.map +1 -1
- package/dist/utilities/input-modality.d.ts.map +1 -1
- package/dist/utilities/input-modality.js +4 -2
- package/dist/utilities/input-modality.js.map +1 -1
- package/dist/utilities/page-section-mixin.d.ts +10 -4
- package/dist/utilities/page-section-mixin.d.ts.map +1 -1
- package/dist/utilities/page-section-mixin.js +29 -23
- package/dist/utilities/page-section-mixin.js.map +1 -1
- package/dist/utilities/return-focus.d.ts +44 -0
- package/dist/utilities/return-focus.d.ts.map +1 -0
- package/dist/utilities/return-focus.js +99 -0
- package/dist/utilities/return-focus.js.map +1 -0
- package/dist/utilities/slot-content.d.ts +30 -0
- package/dist/utilities/slot-content.d.ts.map +1 -0
- package/dist/utilities/slot-content.js +38 -0
- package/dist/utilities/slot-content.js.map +1 -0
- package/lint/data.generated.json +1 -1
- package/package.json +1 -1
- package/dist/components/decorate-C7khEuc7.js +0 -16
|
@@ -1,16 +1,15 @@
|
|
|
1
1
|
import { t as __exportAll } from "./rolldown-runtime-D8jQpDG7.js";
|
|
2
|
-
import { n as customElement, t as __decorate } from "./decorate-
|
|
2
|
+
import { n as reflectNonDefault, r as customElement, t as __decorate } from "./decorate-DD7uUxHb.js";
|
|
3
3
|
import { n as slottedReset, t as inheritedTextReset } from "./shadow-resets-BwOyyZFH.js";
|
|
4
|
-
import { a as downloadLinkHintKey, c as linkRel, i as translate, n as withTranslations, o as linkHintKey, r as setTranslations, s as markDownloadTarget, t as deferFocus } from "./defer-focus-
|
|
4
|
+
import { a as downloadLinkHintKey, c as linkRel, i as translate, n as withTranslations, o as linkHintKey, r as setTranslations, s as markDownloadTarget, t as deferFocus } from "./defer-focus-dzorHsCQ.js";
|
|
5
5
|
import { n as internalsOf, r as setState$1 } from "./element-state-BnarBv0M.js";
|
|
6
|
-
import { a as releaseContext, c as anchorPopoverTarget, d as ShortcutAvailabilityController, f as hasShortcut, i as langOf, l as popoverTargetOf, m as shortcutsAvailable, n as NLDDTooltip, o as NLDDActivityIndicator, p as shortcutLabel, r as carryContext, s as PopupAnchorController, t as NLDDIconButton, u as NLDDKeyboardShortcut } from "./icon-button-
|
|
7
|
-
import { t as reflectNonDefault } from "./reflect-non-default-B9wQcnne.js";
|
|
6
|
+
import { a as releaseContext, c as anchorPopoverTarget, d as ShortcutAvailabilityController, f as hasShortcut, i as langOf, l as popoverTargetOf, m as shortcutsAvailable, n as NLDDTooltip, o as NLDDActivityIndicator, p as shortcutLabel, r as carryContext, s as PopupAnchorController, t as NLDDIconButton, u as NLDDKeyboardShortcut } from "./icon-button-8gvQCwCW.js";
|
|
8
7
|
import { t as nlddButtonTranslations } from "./button.i18n-DiDGynnq.js";
|
|
9
|
-
import { t as NLDDIcon } from "./icon-
|
|
10
|
-
import { n as isPointerMode, r as isTouchMode, t as isKeyboardMode } from "./input-modality-
|
|
8
|
+
import { t as NLDDIcon } from "./icon-_Eox7ZfO.js";
|
|
9
|
+
import { n as isPointerMode, r as isTouchMode, t as isKeyboardMode } from "./input-modality-D_CY185R.js";
|
|
11
10
|
import { A as nlddStepperTranslations, B as nlddComboBoxTranslations, C as nlddCardTranslations, D as nlddTimeFieldTranslations, E as nlddTokenFieldTranslations, F as nlddFileFieldTranslations, G as nlddCodeViewerTranslations, H as nlddTokenTranslations, I as nlddDateFieldTranslations, J as nlddAvatarTranslations, K as nlddAvatarGroupTranslations, L as MONTH_KEYS, M as nlddSearchFieldTranslations, N as nlddPasswordFieldTranslations, O as nlddTimePickerTranslations, P as nlddNumberFieldTranslations, R as WEEKDAY_KEYS, S as nlddCollectionTranslations, T as nlddSliderTranslations, U as nlddRichTextTranslations, V as nlddValidationListTranslations, W as nlddImageTranslations, X as nlddMenuTranslations, Y as nlddToolbarTranslations, Z as nlddSplitButtonTranslations, _ as nlddTableTranslations, a as nlddBadgeTranslations, b as nlddPageFooterTranslations, c as nlddPaginationTranslations, d as nlddTopNavigationBarTranslations, f as nlddSkipLinkTranslations, g as nlddDragHandleCellTranslations, h as nlddBreadcrumbsTranslations, i as nlddProgressBarTranslations, j as nlddSwatchPickerItemTranslations, k as nlddTextEditorTranslations, l as nlddDocumentTabBarTranslations, m as nlddMenuBarTranslations, n as nlddStepBarTranslations, o as nlddNotificationTranslations, p as nlddLinkTranslations, q as nlddPopoverTranslations, r as nlddProgressCircleTranslations, s as nlddBannerTranslations, t as nlddJustInTimeEducationTranslations, u as nlddTabBarTranslations, v as nlddListItemSegmentTranslations, w as nlddSidebarSectionTranslations, x as nlddWindowTranslations, y as nlddKanbanTranslations, z as nlddDatePickerTranslations } from "./just-in-time-education.i18n-BqU1ImP4.js";
|
|
12
11
|
import { i as splitSectionBreakpoints, n as queryBreakpoints, r as rootFontSize, t as breakpointPx } from "./breakpoints-DtL62nLI.js";
|
|
13
|
-
import { t as VisibilityMixin } from "./visibility-mixin-
|
|
12
|
+
import { t as VisibilityMixin } from "./visibility-mixin-Dzn48SL8.js";
|
|
14
13
|
import { t as nlddListTranslations } from "./list.i18n-CKqbhFQ_.js";
|
|
15
14
|
import { t as nlddListItemTranslations } from "./list-item.i18n-89uqlBMK.js";
|
|
16
15
|
import { $ as ChangeSet, A as syntaxTree, B as getDrawSelectionConfig, C as indentNodeProp, D as matchBrackets, E as languageDataProp, F as RectangleMarker, G as layer, H as gutter, I as ViewPlugin, J as placeholder, K as lineNumbers, L as WidgetType, M as Direction, N as EditorView, P as GutterMarker, Q as ChangeDesc, R as drawSelection, S as getIndentation, T as indentUnit, U as gutterLineClass, W as keymap, X as tooltips, Y as showTooltip, Z as Annotation, _t as findClusterBreak, a as HighlightStyle, at as Prec, b as foldService, c as Language, d as ParseContext, dt as Text, et as Compartment, f as StreamLanguage, ft as Transaction, gt as countColumn, h as defineLanguageFacet, ht as combineConfig, j as Decoration, k as syntaxHighlighting, l as LanguageDescription, lt as StateEffect, nt as EditorState, o as IndentContext, ot as RangeSet, rt as Facet, st as RangeSetBuilder, tt as EditorSelection, u as LanguageSupport, ut as StateField, w as indentString, x as getIndentUnit, y as foldNodeProp, z as dropCursor } from "./dist-BFZM0YsR.js";
|
|
@@ -651,13 +650,13 @@ var buttonStyles = css`
|
|
|
651
650
|
function renderContent(component) {
|
|
652
651
|
return html`
|
|
653
652
|
<span class="button__content">
|
|
654
|
-
|
|
653
|
+
<slot name="start-icon">${component.startIcon ? html`
|
|
655
654
|
<span class="button__start-icon">
|
|
656
655
|
<nldd-icon icon=${component.startIcon}></nldd-icon>
|
|
657
656
|
</span>
|
|
658
|
-
` :
|
|
657
|
+
` : nothing}</slot>
|
|
659
658
|
<span class="button__text-area">
|
|
660
|
-
<span class="button__text"
|
|
659
|
+
<span class="button__text"><slot name="text">${component.text}</slot></span>
|
|
661
660
|
${component.supportingText ? html`<span class="button__supporting-text">${component.supportingText}</span>` : nothing}
|
|
662
661
|
</span>
|
|
663
662
|
${hasShortcut(component) ? html`
|
|
@@ -673,11 +672,11 @@ function renderContent(component) {
|
|
|
673
672
|
></nldd-keyboard-shortcut>
|
|
674
673
|
</span>
|
|
675
674
|
` : nothing}
|
|
676
|
-
|
|
675
|
+
<slot name="end-icon">${component.endIcon ? html`
|
|
677
676
|
<span class="button__end-icon">
|
|
678
677
|
<nldd-icon icon=${component.endIcon}></nldd-icon>
|
|
679
678
|
</span>
|
|
680
|
-
` :
|
|
679
|
+
` : nothing}</slot>
|
|
681
680
|
</span>
|
|
682
681
|
${component.expandable ? html`
|
|
683
682
|
<nldd-icon class="button__disclosure-icon"
|
|
@@ -904,9 +903,9 @@ function ownerForm(host, internals) {
|
|
|
904
903
|
* @attr {string} rel - Link rel attribute, used with href; with target '_blank', 'noopener noreferrer' is added to whatever you set
|
|
905
904
|
* @attr {object} translations - Override translation keys (e.g. the "opens in new tab" announcement); unset keys fall back to Dutch.
|
|
906
905
|
*
|
|
907
|
-
* @slot text - Slot for custom button content (e.g. text with inline markup).
|
|
908
|
-
* @slot start-icon - Slot for a custom start icon (e.g. custom SVG).
|
|
909
|
-
* @slot end-icon - Slot for a custom end icon (e.g. custom SVG).
|
|
906
|
+
* @slot text - Slot for custom button content (e.g. text with inline markup). Wins over `text`. Provide accessible-label when the slotted content isn't plain text.
|
|
907
|
+
* @slot start-icon - Slot for a custom start icon (e.g. custom SVG). Wins over `start-icon`.
|
|
908
|
+
* @slot end-icon - Slot for a custom end icon (e.g. custom SVG). Wins over `end-icon`.
|
|
910
909
|
* @slot popup - A single `nldd-menu` or `nldd-popover` this button invokes. Slotting it auto-anchors the overlay to the button and toggles it on click (no id/anchor wiring). The overlay syncs `expanded` and `aria-haspopup` back onto the button. Add `expandable` for the disclosure chevron. Mirrors nldd-split-button; the manual `anchor`/`popovertarget` wiring keeps working when you don't slot an overlay.
|
|
911
910
|
*
|
|
912
911
|
* @fires click - When button is clicked (not fired when disabled)
|
|
@@ -1048,8 +1047,8 @@ __decorate([property({
|
|
|
1048
1047
|
attribute: "popup-type"
|
|
1049
1048
|
})], NLDDButton.prototype, "popupType", void 0);
|
|
1050
1049
|
__decorate([property({
|
|
1051
|
-
|
|
1052
|
-
|
|
1050
|
+
reflect: true,
|
|
1051
|
+
converter: reflectNonDefault("button")
|
|
1053
1052
|
})], NLDDButton.prototype, "type", void 0);
|
|
1054
1053
|
__decorate([property({ type: String })], NLDDButton.prototype, "popovertarget", void 0);
|
|
1055
1054
|
__decorate([property({ attribute: false })], NLDDButton.prototype, "popoverTargetElement", void 0);
|
|
@@ -1574,6 +1573,12 @@ var menuItemStyles = css`
|
|
|
1574
1573
|
}
|
|
1575
1574
|
}
|
|
1576
1575
|
|
|
1576
|
+
/* The icon cell gives what it holds display: block; the slot that passes the
|
|
1577
|
+
icon on must stay out of the layout. */
|
|
1578
|
+
.menu__item-icon {
|
|
1579
|
+
display: contents;
|
|
1580
|
+
}
|
|
1581
|
+
|
|
1577
1582
|
/* A link item (href) renders as <a>; strip the UA link color/underline so
|
|
1578
1583
|
it is visually identical to the button variant. The text color is owned
|
|
1579
1584
|
by the inner nldd-text-cell. The control cursor token (default, like the
|
|
@@ -1837,22 +1842,27 @@ function menuItemTemplate(variant = null) {
|
|
|
1837
1842
|
const hasSubmenu = this._hasSubmenu;
|
|
1838
1843
|
const safeHref = sanitizeUrl(this.href) ?? "";
|
|
1839
1844
|
const asLink = !!safeHref && this.type === "button" && !hasSubmenu && !this.disabled;
|
|
1845
|
+
const hasIcon = Boolean(this.icon) || this._hasIconSlot;
|
|
1840
1846
|
const content = html`
|
|
1841
1847
|
${hasCheckColumn ? html`
|
|
1842
1848
|
<nldd-icon-cell
|
|
1843
|
-
size="24"
|
|
1844
1849
|
horizontal-alignment="center"
|
|
1845
1850
|
icon=${hasCheckState && this.selected ? "check-mark" : nothing}
|
|
1846
1851
|
></nldd-icon-cell>
|
|
1847
1852
|
<nldd-spacer-cell size="4"></nldd-spacer-cell>
|
|
1848
1853
|
` : nothing}
|
|
1849
|
-
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
-
|
|
1855
|
-
|
|
1854
|
+
<nldd-icon-cell
|
|
1855
|
+
size="20"
|
|
1856
|
+
?hidden=${!hasIcon}
|
|
1857
|
+
><slot
|
|
1858
|
+
name="icon"
|
|
1859
|
+
class="menu__item-icon"
|
|
1860
|
+
@slotchange=${this._onIconSlotChange}
|
|
1861
|
+
>${this.icon ? html`<nldd-icon icon=${this.icon}></nldd-icon>` : nothing}</slot></nldd-icon-cell>
|
|
1862
|
+
<nldd-spacer-cell
|
|
1863
|
+
size="8"
|
|
1864
|
+
?hidden=${!hasIcon}
|
|
1865
|
+
></nldd-spacer-cell>
|
|
1856
1866
|
<nldd-text-cell
|
|
1857
1867
|
text=${this.text}
|
|
1858
1868
|
query=${this.query}
|
|
@@ -2080,10 +2090,46 @@ function template$22() {
|
|
|
2080
2090
|
part="icon"
|
|
2081
2091
|
class="icon-cell__glyph"
|
|
2082
2092
|
>
|
|
2083
|
-
${this.icon ? html`<nldd-icon icon=${this.icon}></nldd-icon>` :
|
|
2093
|
+
${this.icon && !this._slot.has ? html`<nldd-icon icon=${this.icon}></nldd-icon>` : nothing}<slot @slotchange=${this._slot.onChange}></slot>
|
|
2084
2094
|
</span>
|
|
2085
2095
|
`;
|
|
2086
2096
|
}
|
|
2097
|
+
// src/utilities/slot-content.ts
|
|
2098
|
+
/**
|
|
2099
|
+
* Whether a slot holds something to show: an element, or text that is more
|
|
2100
|
+
* than whitespace.
|
|
2101
|
+
*
|
|
2102
|
+
* A default slot also gets the whitespace and line breaks between the tags of
|
|
2103
|
+
* the markup around it, and that whitespace switches off the slot's fallback
|
|
2104
|
+
* content. A component that lets its slot win over an attribute therefore
|
|
2105
|
+
* renders the attribute beside the slot, and hides it when this says so.
|
|
2106
|
+
*/
|
|
2107
|
+
function hasSlotContent(slot) {
|
|
2108
|
+
return slot.assignedNodes().some((node) => node.nodeType === Node.ELEMENT_NODE || node.nodeType === Node.TEXT_NODE && (node.textContent ?? "").trim().length > 0);
|
|
2109
|
+
}
|
|
2110
|
+
/**
|
|
2111
|
+
* Tracks whether a slot holds something, for a component whose slot wins over
|
|
2112
|
+
* an attribute. Pass `onChange` to the slot's `@slotchange` and render the
|
|
2113
|
+
* attribute only while `has` is false:
|
|
2114
|
+
*
|
|
2115
|
+
* ```ts
|
|
2116
|
+
* private _textSlot = new SlotContent(this);
|
|
2117
|
+
* // in the template
|
|
2118
|
+
* html`${this._textSlot.has ? nothing : this.text}<slot @slotchange=${this._textSlot.onChange}></slot>`
|
|
2119
|
+
* ```
|
|
2120
|
+
*/
|
|
2121
|
+
var SlotContent = class {
|
|
2122
|
+
constructor(_host) {
|
|
2123
|
+
this._host = _host;
|
|
2124
|
+
this.has = false;
|
|
2125
|
+
this.onChange = (e) => {
|
|
2126
|
+
const has = hasSlotContent(e.target);
|
|
2127
|
+
if (has === this.has) return;
|
|
2128
|
+
this.has = has;
|
|
2129
|
+
this._host.requestUpdate();
|
|
2130
|
+
};
|
|
2131
|
+
}
|
|
2132
|
+
};
|
|
2087
2133
|
// src/components/lists-and-tables/cells/icon-cell/icon-cell.ts
|
|
2088
2134
|
/**
|
|
2089
2135
|
* Nederlandse Digitale Dienst Icon Cell Component (Lit + TypeScript)
|
|
@@ -2096,10 +2142,10 @@ function template$22() {
|
|
|
2096
2142
|
* @attr {string} size - Size: '16' | '20' | '24' | '32' (default: '24')
|
|
2097
2143
|
* @attr {'content' | 'secondary' | 'accent' | 'success' | 'warning' | 'critical'} color - Color variant of the icon (default: 'content')
|
|
2098
2144
|
* @attr {string} vertical-alignment - Vertical alignment: 'top' | 'center' | 'bottom' (default: 'center')
|
|
2099
|
-
* @attr {string} icon - Icon name (renders `<nldd-icon>`).
|
|
2145
|
+
* @attr {string} icon - Icon name (renders `<nldd-icon>`). Content in the default slot wins.
|
|
2100
2146
|
* @attr {boolean} disclosure - Marks this icon as the chevron of a row or segment that opens and closes: the row turns it with `expanded`.
|
|
2101
2147
|
*
|
|
2102
|
-
* @slot -
|
|
2148
|
+
* @slot - Custom icon content, for iconography outside the icon set. Wins over `icon`.
|
|
2103
2149
|
*
|
|
2104
2150
|
* @csspart icon - The glyph itself, whether it comes from `icon` or from the slot. Transform this rather than the cell: a transform on the host changes the box `getBoundingClientRect()` reports, and a row measures its cells to place the divider.
|
|
2105
2151
|
*/
|
|
@@ -2111,6 +2157,7 @@ var _NLDDIconCell = class NLDDIconCell extends VisibilityMixin(LitElement, "cell
|
|
|
2111
2157
|
this.color = "content";
|
|
2112
2158
|
this.verticalAlignment = "center";
|
|
2113
2159
|
this.icon = "";
|
|
2160
|
+
this._slot = new SlotContent(this);
|
|
2114
2161
|
}
|
|
2115
2162
|
render() {
|
|
2116
2163
|
return template$22.call(this);
|
|
@@ -2118,8 +2165,8 @@ var _NLDDIconCell = class NLDDIconCell extends VisibilityMixin(LitElement, "cell
|
|
|
2118
2165
|
};
|
|
2119
2166
|
var NLDDIconCell = (_NLDDIconCell.styles = iconCellStyles, _NLDDIconCell);
|
|
2120
2167
|
__decorate([property({
|
|
2121
|
-
|
|
2122
|
-
|
|
2168
|
+
reflect: true,
|
|
2169
|
+
converter: reflectNonDefault("24")
|
|
2123
2170
|
})], NLDDIconCell.prototype, "size", void 0);
|
|
2124
2171
|
__decorate([property({
|
|
2125
2172
|
reflect: true,
|
|
@@ -2131,8 +2178,8 @@ __decorate([property({
|
|
|
2131
2178
|
converter: reflectNonDefault("center")
|
|
2132
2179
|
})], NLDDIconCell.prototype, "verticalAlignment", void 0);
|
|
2133
2180
|
__decorate([property({
|
|
2134
|
-
|
|
2135
|
-
|
|
2181
|
+
reflect: true,
|
|
2182
|
+
converter: reflectNonDefault("")
|
|
2136
2183
|
})], NLDDIconCell.prototype, "icon", void 0);
|
|
2137
2184
|
NLDDIconCell = __decorate([customElement("nldd-icon-cell")], NLDDIconCell);
|
|
2138
2185
|
// src/components/lists-and-tables/cells/spacer-cell/spacer-cell.styles.ts
|
|
@@ -2205,8 +2252,8 @@ var _NLDDSpacerCell = class NLDDSpacerCell extends VisibilityMixin(LitElement, "
|
|
|
2205
2252
|
};
|
|
2206
2253
|
var NLDDSpacerCell = (_NLDDSpacerCell.styles = spacerCellStyles, _NLDDSpacerCell);
|
|
2207
2254
|
__decorate([property({
|
|
2208
|
-
|
|
2209
|
-
|
|
2255
|
+
reflect: true,
|
|
2256
|
+
converter: reflectNonDefault("16")
|
|
2210
2257
|
})], NLDDSpacerCell.prototype, "size", void 0);
|
|
2211
2258
|
NLDDSpacerCell = __decorate([customElement("nldd-spacer-cell")], NLDDSpacerCell);
|
|
2212
2259
|
// src/components/lists-and-tables/cells/text-cell/text-cell.styles.ts
|
|
@@ -2559,12 +2606,12 @@ function RowHeaderMixin(Base) {
|
|
|
2559
2606
|
* @attr {string} horizontal-alignment - Horizontal alignment: 'left' | 'center' | 'right' (default: 'left')
|
|
2560
2607
|
* @attr {string} vertical-alignment - Vertical alignment: 'top' | 'center' | 'bottom' (default: 'center')
|
|
2561
2608
|
*
|
|
2562
|
-
* @attr {string} text - Main text content. Supports **bold** syntax for inline bold segments.
|
|
2609
|
+
* @attr {string} text - Main text content. Supports **bold** syntax for inline bold segments. Content in the default slot wins.
|
|
2563
2610
|
* @attr {string} supporting-text - Optional supporting text displayed below the main content. Supports **bold**. Falls back to `supporting-text` slot.
|
|
2564
2611
|
* @attr {string} overline - Optional overline text displayed above the main content. Supports **bold**. Falls back to `overline` slot.
|
|
2565
2612
|
*
|
|
2566
2613
|
* @slot overline - Rich content for the overline region. Overrides the `overline` attribute when content is assigned.
|
|
2567
|
-
* @slot - (default) Rich content for the main text region.
|
|
2614
|
+
* @slot - (default) Rich content for the main text region. Wins over `text`.
|
|
2568
2615
|
* @slot supporting-text - Rich content for the supporting text region. Overrides the `supporting-text` attribute when content is assigned.
|
|
2569
2616
|
*
|
|
2570
2617
|
* ### Query mark
|
|
@@ -2907,7 +2954,7 @@ var buttonGroupStyles = css`
|
|
|
2907
2954
|
:host {
|
|
2908
2955
|
--_button-group-flex-direction: column;
|
|
2909
2956
|
--_button-group-flex-wrap: nowrap;
|
|
2910
|
-
--_button-group-gap: var(--
|
|
2957
|
+
--_button-group-gap: var(--semantics-button-groups-md-gap);
|
|
2911
2958
|
|
|
2912
2959
|
box-sizing: border-box;
|
|
2913
2960
|
display: flex;
|
|
@@ -2923,7 +2970,7 @@ var buttonGroupStyles = css`
|
|
|
2923
2970
|
}
|
|
2924
2971
|
|
|
2925
2972
|
:host([size="sm"]) {
|
|
2926
|
-
--_button-group-gap: var(--
|
|
2973
|
+
--_button-group-gap: var(--semantics-button-groups-sm-gap);
|
|
2927
2974
|
}
|
|
2928
2975
|
|
|
2929
2976
|
:host([hidden]) {
|
|
@@ -3109,7 +3156,8 @@ var NLDDButtonGroup = (_NLDDButtonGroup = class NLDDButtonGroup extends LitEleme
|
|
|
3109
3156
|
for (const el of assigned) {
|
|
3110
3157
|
const own = el.getAttribute("size");
|
|
3111
3158
|
if (own !== null && own !== this.size && !this._sized.has(el)) setState$1(this, "own-size-overwritten", true);
|
|
3112
|
-
|
|
3159
|
+
if ("size" in el) el.size = this.size;
|
|
3160
|
+
else el.setAttribute("size", this.size);
|
|
3113
3161
|
this._sized.add(el);
|
|
3114
3162
|
}
|
|
3115
3163
|
}
|
|
@@ -3285,13 +3333,13 @@ __decorate([property({
|
|
|
3285
3333
|
converter: reflectNonDefault("md")
|
|
3286
3334
|
})], NLDDInlineDialog.prototype, "size", void 0);
|
|
3287
3335
|
__decorate([property({
|
|
3288
|
-
|
|
3289
|
-
|
|
3336
|
+
reflect: true,
|
|
3337
|
+
converter: reflectNonDefault("")
|
|
3290
3338
|
})], NLDDInlineDialog.prototype, "icon", void 0);
|
|
3291
3339
|
__decorate([property({
|
|
3292
|
-
type: String,
|
|
3293
3340
|
reflect: true,
|
|
3294
|
-
attribute: "icon-color"
|
|
3341
|
+
attribute: "icon-color",
|
|
3342
|
+
converter: reflectNonDefault("")
|
|
3295
3343
|
})], NLDDInlineDialog.prototype, "iconColor", void 0);
|
|
3296
3344
|
__decorate([property({
|
|
3297
3345
|
reflect: true,
|
|
@@ -3315,6 +3363,98 @@ __decorate([property({
|
|
|
3315
3363
|
__decorate([state()], NLDDInlineDialog.prototype, "_hasContent", void 0);
|
|
3316
3364
|
__decorate([state()], NLDDInlineDialog.prototype, "_hasActions", void 0);
|
|
3317
3365
|
NLDDInlineDialog = __decorate([customElement("nldd-inline-dialog")], NLDDInlineDialog);
|
|
3366
|
+
// src/utilities/return-focus.ts
|
|
3367
|
+
/** The element that really holds focus, inside any shadow roots. */
|
|
3368
|
+
function deepActiveElement() {
|
|
3369
|
+
let el = document.activeElement;
|
|
3370
|
+
while (el?.shadowRoot?.activeElement) el = el.shadowRoot.activeElement;
|
|
3371
|
+
return el;
|
|
3372
|
+
}
|
|
3373
|
+
/**
|
|
3374
|
+
* Hands focus back to `target` once `overlay` (a popover, menu, sheet or window)
|
|
3375
|
+
* has closed. Call it after the close, with the element that had focus when the
|
|
3376
|
+
* overlay opened.
|
|
3377
|
+
*
|
|
3378
|
+
* - Focus the user moved elsewhere, by a click into a field or Tab out of the
|
|
3379
|
+
* overlay, stays there. Only focus still in the overlay, on nothing, or on
|
|
3380
|
+
* `target` itself is handed back.
|
|
3381
|
+
* - After the keyboard, `target` gets a plain `focus()` and its ring.
|
|
3382
|
+
* - After a mouse or a finger, it gets no ring. The browser's own close step
|
|
3383
|
+
* has often moved focus back already, and WebKit draws a ring for that
|
|
3384
|
+
* script focus. A second `focus()` would be a no-op, so it blurs first and
|
|
3385
|
+
* focuses with `focusVisible: false`. Chromium leaves the ring off itself.
|
|
3386
|
+
* A text field keeps its ring, as it does on any click.
|
|
3387
|
+
*/
|
|
3388
|
+
function returnFocus(target, overlay) {
|
|
3389
|
+
if (!target || target === document.body || !target.isConnected) return;
|
|
3390
|
+
const active = deepActiveElement();
|
|
3391
|
+
const onTarget = !!active && isWithin(active, target);
|
|
3392
|
+
if (!(!active || active === document.body || onTarget || isWithin(active, overlay))) return;
|
|
3393
|
+
if (!isPointerMode()) {
|
|
3394
|
+
target.focus();
|
|
3395
|
+
return;
|
|
3396
|
+
}
|
|
3397
|
+
if (active && onTarget) {
|
|
3398
|
+
if (!active.matches(":focus-visible") || isTextEntry(active)) return;
|
|
3399
|
+
active.blur();
|
|
3400
|
+
}
|
|
3401
|
+
target.focus({ focusVisible: false });
|
|
3402
|
+
}
|
|
3403
|
+
/** Whether `node` is `container` or inside it, across shadow roots. */
|
|
3404
|
+
function isWithin(node, container) {
|
|
3405
|
+
for (let n = node; n; n = n.parentNode ?? (n instanceof ShadowRoot ? n.host : null)) if (n === container) return true;
|
|
3406
|
+
return false;
|
|
3407
|
+
}
|
|
3408
|
+
function isTextEntry(el) {
|
|
3409
|
+
if (el.isContentEditable || el instanceof HTMLTextAreaElement) return true;
|
|
3410
|
+
return el instanceof HTMLInputElement && ![
|
|
3411
|
+
"button",
|
|
3412
|
+
"checkbox",
|
|
3413
|
+
"color",
|
|
3414
|
+
"file",
|
|
3415
|
+
"image",
|
|
3416
|
+
"radio",
|
|
3417
|
+
"range",
|
|
3418
|
+
"reset",
|
|
3419
|
+
"submit"
|
|
3420
|
+
].includes(el.type);
|
|
3421
|
+
}
|
|
3422
|
+
/**
|
|
3423
|
+
* Remembers where focus was when an overlay opened, and hands it back when it
|
|
3424
|
+
* closes, through `returnFocus`. One per overlay:
|
|
3425
|
+
*
|
|
3426
|
+
* ```ts
|
|
3427
|
+
* private _focusReturn = new FocusReturn();
|
|
3428
|
+
* // on open, before the overlay takes focus
|
|
3429
|
+
* this._focusReturn.remember(anchor);
|
|
3430
|
+
* // once it has closed
|
|
3431
|
+
* this._focusReturn.restore(this);
|
|
3432
|
+
* ```
|
|
3433
|
+
*/
|
|
3434
|
+
var FocusReturn = class {
|
|
3435
|
+
constructor() {
|
|
3436
|
+
this._target = null;
|
|
3437
|
+
this._fallback = null;
|
|
3438
|
+
}
|
|
3439
|
+
/** Remembers what has focus now, inside any shadow roots, so focus goes
|
|
3440
|
+
* back to that element and not to the host it sits in. With nothing
|
|
3441
|
+
* focused, as after a click on a button in Safari, it remembers
|
|
3442
|
+
* `fallback`: an overlay's anchor, so Tab goes on from there. The
|
|
3443
|
+
* fallback also stands in for a remembered element that has left the page
|
|
3444
|
+
* by the time the overlay closes, as when a framework renders it anew. */
|
|
3445
|
+
remember(fallback) {
|
|
3446
|
+
const active = deepActiveElement();
|
|
3447
|
+
this._fallback = fallback ?? null;
|
|
3448
|
+
this._target = active && active !== document.body ? active : this._fallback;
|
|
3449
|
+
}
|
|
3450
|
+
/** Hands focus back once `overlay` has closed. */
|
|
3451
|
+
restore(overlay) {
|
|
3452
|
+
const target = this._target?.isConnected ? this._target : this._fallback;
|
|
3453
|
+
this._target = null;
|
|
3454
|
+
this._fallback = null;
|
|
3455
|
+
returnFocus(target, overlay);
|
|
3456
|
+
}
|
|
3457
|
+
};
|
|
3318
3458
|
/**
|
|
3319
3459
|
* The menu-item under a point, piercing shadow boundaries.
|
|
3320
3460
|
* `document.elementFromPoint` stops at the outermost shadow host, so a menu
|
|
@@ -3336,6 +3476,22 @@ function menuItemFromPoint(x, y) {
|
|
|
3336
3476
|
return null;
|
|
3337
3477
|
}
|
|
3338
3478
|
/**
|
|
3479
|
+
* The element under a point, in the tree of the menu it lies in. Like
|
|
3480
|
+
* `menuItemFromPoint` it descends shadow roots, but only until it reaches a
|
|
3481
|
+
* menu, so an item still resolves to the item and not to the inside of it.
|
|
3482
|
+
* Null where the point is on nothing.
|
|
3483
|
+
*/
|
|
3484
|
+
function menuElementFromPoint(x, y) {
|
|
3485
|
+
let root = document;
|
|
3486
|
+
const MAX_PIERCE_DEPTH = 20;
|
|
3487
|
+
for (let depth = 0; depth < MAX_PIERCE_DEPTH; depth++) {
|
|
3488
|
+
const el = root.elementFromPoint(x, y);
|
|
3489
|
+
if (!el || el.closest("nldd-menu") || !el.shadowRoot) return el;
|
|
3490
|
+
root = el.shadowRoot;
|
|
3491
|
+
}
|
|
3492
|
+
return null;
|
|
3493
|
+
}
|
|
3494
|
+
/**
|
|
3339
3495
|
* The pointer gestures of a menu, each with its own coordinates and listeners:
|
|
3340
3496
|
*
|
|
3341
3497
|
* 1. **Press, drag and release.** A native `<select>` lets you press on one
|
|
@@ -3673,7 +3829,7 @@ var SafeTriangleController = class {
|
|
|
3673
3829
|
this.movingToward = false;
|
|
3674
3830
|
this._lastPos = p;
|
|
3675
3831
|
this._removeOverlay();
|
|
3676
|
-
if (wasMoving) this._host.
|
|
3832
|
+
if (wasMoving) this._host.releaseAt(p);
|
|
3677
3833
|
}
|
|
3678
3834
|
} else {
|
|
3679
3835
|
const shape = wedge(this._apex, p, r);
|
|
@@ -3683,7 +3839,7 @@ var SafeTriangleController = class {
|
|
|
3683
3839
|
this._lastPos = p;
|
|
3684
3840
|
const opener = this._host.safeTriangleOpener;
|
|
3685
3841
|
if (opener && this.movingToward && !opener.hasAttribute("highlighted")) this._host.highlightOpener();
|
|
3686
|
-
if (wasMoving && !this.movingToward) this._host.
|
|
3842
|
+
if (wasMoving && !this.movingToward) this._host.releaseAt(p);
|
|
3687
3843
|
this._scheduleStall();
|
|
3688
3844
|
}
|
|
3689
3845
|
_clearStall() {
|
|
@@ -3698,7 +3854,7 @@ var SafeTriangleController = class {
|
|
|
3698
3854
|
this._stallTimer = null;
|
|
3699
3855
|
this.movingToward = false;
|
|
3700
3856
|
this._apex = null;
|
|
3701
|
-
if (this._lastPos) this._host.
|
|
3857
|
+
if (this._lastPos) this._host.releaseAt(this._lastPos);
|
|
3702
3858
|
}, 500);
|
|
3703
3859
|
}
|
|
3704
3860
|
_drawOverlay(vertices) {
|
|
@@ -3793,7 +3949,7 @@ function syncListItemRole(host, variant) {
|
|
|
3793
3949
|
* @attr {boolean} destructive - Marks the item as destructive (red text; red highlight bg). Use for irreversible actions like "Delete". Color is the only built-in signal, so per WCAG 1.4.1 the item's own label must convey the destructive nature (e.g. "Verwijder") — don't rely on the red alone. Confirming the action (e.g. a follow-up dialog) is the consumer's responsibility.
|
|
3794
3950
|
* @attr {string} text - Display text. Supports **bold** markdown syntax.
|
|
3795
3951
|
* @attr {string} details - Secondary label shown on the right side.
|
|
3796
|
-
* @attr {string} icon - Icon name rendered before the text.
|
|
3952
|
+
* @attr {string} icon - Icon name rendered before the text. An icon in the `icon` slot takes its place.
|
|
3797
3953
|
* @attr {string} shortcut - Keyboard shortcut hint shown on the right, e.g. 'Cmd+E'. Display only (rendered via nldd-keyboard-shortcut) — it does not bind the key; wire up the handling in your app. Hidden on touch-only devices, where it isn't invokable.
|
|
3798
3954
|
* @attr {string} shortcut-mac / shortcut-windows / shortcut-linux - Per-OS overrides for `shortcut`, picked by detected OS (falls back to `shortcut`).
|
|
3799
3955
|
* @attr {string} href - Optional link target. A plain button item with an href renders as an `<a>` so it is a real link (middle-click, open in new tab, copy link). Ignored for submenu openers, checkbox/radio items, and while disabled.
|
|
@@ -3805,6 +3961,8 @@ function syncListItemRole(host, variant) {
|
|
|
3805
3961
|
* @attr {string} query - Query substring to bold-highlight in text. Set by menu's filter(); also settable by consumers.
|
|
3806
3962
|
* @attr {string} query-mark-mode - 'match' | 'predictive' (default: 'predictive'). See text-cell for details.
|
|
3807
3963
|
*
|
|
3964
|
+
* @slot icon - An icon of your own before the text, such as an `<img>`: one that is not in the icon set. Wins over `icon`.
|
|
3965
|
+
*
|
|
3808
3966
|
* @fires select - Fired when the item is clicked and not disabled.
|
|
3809
3967
|
*/
|
|
3810
3968
|
var NLDDMenuItem = class NLDDMenuItem extends LitElement {
|
|
@@ -3829,6 +3987,10 @@ var NLDDMenuItem = class NLDDMenuItem extends LitElement {
|
|
|
3829
3987
|
this.menuVariant = null;
|
|
3830
3988
|
this.checkColumn = false;
|
|
3831
3989
|
this._submenuOpen = false;
|
|
3990
|
+
this._hasIconSlot = false;
|
|
3991
|
+
this._onIconSlotChange = (e) => {
|
|
3992
|
+
this._hasIconSlot = e.target.assignedElements().length > 0;
|
|
3993
|
+
};
|
|
3832
3994
|
this._cachedSubmenuEl = null;
|
|
3833
3995
|
this._submenuMutationObserver = null;
|
|
3834
3996
|
}
|
|
@@ -3925,8 +4087,8 @@ __decorate([property({
|
|
|
3925
4087
|
converter: reflectNonDefault("")
|
|
3926
4088
|
})], NLDDMenuItem.prototype, "details", void 0);
|
|
3927
4089
|
__decorate([property({
|
|
3928
|
-
|
|
3929
|
-
|
|
4090
|
+
reflect: true,
|
|
4091
|
+
converter: reflectNonDefault("")
|
|
3930
4092
|
})], NLDDMenuItem.prototype, "icon", void 0);
|
|
3931
4093
|
__decorate([property({
|
|
3932
4094
|
reflect: true,
|
|
@@ -3948,12 +4110,12 @@ __decorate([property({
|
|
|
3948
4110
|
converter: reflectNonDefault("")
|
|
3949
4111
|
})], NLDDMenuItem.prototype, "shortcutLinux", void 0);
|
|
3950
4112
|
__decorate([property({
|
|
3951
|
-
|
|
3952
|
-
|
|
4113
|
+
reflect: true,
|
|
4114
|
+
converter: reflectNonDefault("")
|
|
3953
4115
|
})], NLDDMenuItem.prototype, "href", void 0);
|
|
3954
4116
|
__decorate([property({
|
|
3955
|
-
|
|
3956
|
-
|
|
4117
|
+
reflect: true,
|
|
4118
|
+
converter: reflectNonDefault("button")
|
|
3957
4119
|
})], NLDDMenuItem.prototype, "type", void 0);
|
|
3958
4120
|
__decorate([property({
|
|
3959
4121
|
type: Boolean,
|
|
@@ -3964,8 +4126,8 @@ __decorate([property({
|
|
|
3964
4126
|
reflect: true
|
|
3965
4127
|
})], NLDDMenuItem.prototype, "disabled", void 0);
|
|
3966
4128
|
__decorate([property({
|
|
3967
|
-
|
|
3968
|
-
|
|
4129
|
+
reflect: true,
|
|
4130
|
+
converter: reflectNonDefault("")
|
|
3969
4131
|
})], NLDDMenuItem.prototype, "value", void 0);
|
|
3970
4132
|
__decorate([property({
|
|
3971
4133
|
reflect: true,
|
|
@@ -3983,6 +4145,7 @@ __decorate([property({
|
|
|
3983
4145
|
__decorate([state()], NLDDMenuItem.prototype, "menuVariant", void 0);
|
|
3984
4146
|
__decorate([state()], NLDDMenuItem.prototype, "checkColumn", void 0);
|
|
3985
4147
|
__decorate([state()], NLDDMenuItem.prototype, "_submenuOpen", void 0);
|
|
4148
|
+
__decorate([state()], NLDDMenuItem.prototype, "_hasIconSlot", void 0);
|
|
3986
4149
|
if (!customElements.get("nldd-menu-item")) customElements.define("nldd-menu-item", NLDDMenuItem);
|
|
3987
4150
|
// src/components/actions/menu/menu-group.ts
|
|
3988
4151
|
var _NLDDMenuGroup;
|
|
@@ -4072,6 +4235,12 @@ function nameOfAnchor(anchor) {
|
|
|
4072
4235
|
}
|
|
4073
4236
|
/** How long the options have to stay the same before their number is said. */
|
|
4074
4237
|
var ANNOUNCE_RESULTS_DELAY_MS = 500;
|
|
4238
|
+
/** A submenu opens when the pointer has not moved over its item for this long. */
|
|
4239
|
+
var HOVER_REST_MS = 40;
|
|
4240
|
+
/** Or when it moves slower than this, about 100 pixels a second. */
|
|
4241
|
+
var HOVER_SLOW_PX_PER_MS = .1;
|
|
4242
|
+
/** Or, at the latest, when it has stayed on the item this long. */
|
|
4243
|
+
var HOVER_OPEN_MAX_MS = 150;
|
|
4075
4244
|
/**
|
|
4076
4245
|
* A floating menu component using the Popover API.
|
|
4077
4246
|
* Positioned relative to an anchor element using Floating UI.
|
|
@@ -4128,6 +4297,7 @@ var NLDDMenu = class NLDDMenu extends LitElement {
|
|
|
4128
4297
|
this._parentMenu = null;
|
|
4129
4298
|
this._parentItem = null;
|
|
4130
4299
|
this._isOpen = false;
|
|
4300
|
+
this._focusReturn = new FocusReturn();
|
|
4131
4301
|
this._previousAnchorForResync = null;
|
|
4132
4302
|
this._collapsedByPointerGesture = false;
|
|
4133
4303
|
this._cleanupAutoUpdate = null;
|
|
@@ -4156,7 +4326,10 @@ var NLDDMenu = class NLDDMenu extends LitElement {
|
|
|
4156
4326
|
if (this._isOpen) this.hidePopover();
|
|
4157
4327
|
else this.showPopover();
|
|
4158
4328
|
};
|
|
4329
|
+
this._hoverOpenItem = null;
|
|
4159
4330
|
this._hoverOpenTimer = null;
|
|
4331
|
+
this._hoverOpenDeadline = 0;
|
|
4332
|
+
this._lastHoverMove = null;
|
|
4160
4333
|
this._safeTriangle = new SafeTriangleController(this);
|
|
4161
4334
|
this._handleMenuItemMouseenter = (event) => {
|
|
4162
4335
|
if (isTouchMode()) return;
|
|
@@ -4166,14 +4339,33 @@ var NLDDMenu = class NLDDMenu extends LitElement {
|
|
|
4166
4339
|
};
|
|
4167
4340
|
this._handleMouseover = (event) => {
|
|
4168
4341
|
if (isTouchMode() || this.variant === "listbox") return;
|
|
4169
|
-
if (this._activeSubmenu || this._safeTriangle.movingToward) return;
|
|
4170
4342
|
if (event.composedPath().some((node) => node instanceof Element && node.localName === "nldd-menu-item")) return;
|
|
4171
|
-
this.
|
|
4343
|
+
if (this._safeTriangle.movingToward) return;
|
|
4344
|
+
this._leaveItems();
|
|
4172
4345
|
};
|
|
4173
4346
|
this._handleMouseleave = () => {
|
|
4174
4347
|
if (this.variant !== "listbox") this._clearHighlight();
|
|
4175
4348
|
this._cancelHoverOpen();
|
|
4176
4349
|
};
|
|
4350
|
+
this._handleHoverMove = (event) => {
|
|
4351
|
+
const item = this._hoverOpenItem;
|
|
4352
|
+
if (!item || !event.composedPath().includes(item)) return;
|
|
4353
|
+
const last = this._lastHoverMove;
|
|
4354
|
+
this._lastHoverMove = {
|
|
4355
|
+
x: event.clientX,
|
|
4356
|
+
y: event.clientY,
|
|
4357
|
+
t: event.timeStamp
|
|
4358
|
+
};
|
|
4359
|
+
if (last) {
|
|
4360
|
+
const elapsed = event.timeStamp - last.t;
|
|
4361
|
+
const distance = Math.hypot(event.clientX - last.x, event.clientY - last.y);
|
|
4362
|
+
if (elapsed > 0 && distance > 0 && distance / elapsed < HOVER_SLOW_PX_PER_MS) {
|
|
4363
|
+
this._openHoverItem();
|
|
4364
|
+
return;
|
|
4365
|
+
}
|
|
4366
|
+
}
|
|
4367
|
+
this._waitForRest();
|
|
4368
|
+
};
|
|
4177
4369
|
this._handleMenuItemFocused = (event) => {
|
|
4178
4370
|
const item = event.target.closest("nldd-menu-item");
|
|
4179
4371
|
if (!item || item.disabled || item.hasAttribute("hidden")) return;
|
|
@@ -4327,7 +4519,9 @@ var NLDDMenu = class NLDDMenu extends LitElement {
|
|
|
4327
4519
|
});
|
|
4328
4520
|
};
|
|
4329
4521
|
this._handleBeforeToggle = (event) => {
|
|
4330
|
-
if (event.newState
|
|
4522
|
+
if (event.newState !== "open") return;
|
|
4523
|
+
this.removeAttribute("positioned");
|
|
4524
|
+
if (this.variant !== "listbox" && !this._isSubmenu) this._focusReturn.remember(this._getAnchorEl());
|
|
4331
4525
|
};
|
|
4332
4526
|
this._handleToggle = async (event) => {
|
|
4333
4527
|
const toggleEvent = event;
|
|
@@ -4341,6 +4535,7 @@ var NLDDMenu = class NLDDMenu extends LitElement {
|
|
|
4341
4535
|
document.removeEventListener("pointerdown", this._handleDocumentPointerdown, true);
|
|
4342
4536
|
this._pointer.stopOutsideTap();
|
|
4343
4537
|
this._clearHighlight();
|
|
4538
|
+
this._focusReturn.restore(this);
|
|
4344
4539
|
return;
|
|
4345
4540
|
}
|
|
4346
4541
|
this._updateDividerVisibility();
|
|
@@ -4526,7 +4721,7 @@ var NLDDMenu = class NLDDMenu extends LitElement {
|
|
|
4526
4721
|
}
|
|
4527
4722
|
/**
|
|
4528
4723
|
* Item-activation logic shared between the native `mouseenter` capture
|
|
4529
|
-
* handler and the safe
|
|
4724
|
+
* handler and the safe triangle's `releaseAt` (sideways exit, direction
|
|
4530
4725
|
* reversal, stall dismissal). Those paths know which item is under the
|
|
4531
4726
|
* cursor — they don't need to synthesize a MouseEvent just to re-enter
|
|
4532
4727
|
* the handler. Factoring out the body keeps the entry contracts honest:
|
|
@@ -4541,24 +4736,57 @@ var NLDDMenu = class NLDDMenu extends LitElement {
|
|
|
4541
4736
|
if (this._drillInMode) return;
|
|
4542
4737
|
if (this._activeSubmenu && item !== this._activeSubmenuOpener) this._activeSubmenu.hidePopover?.();
|
|
4543
4738
|
this._cancelHoverOpen();
|
|
4544
|
-
if (item._hasSubmenu && this._activeSubmenuOpener !== item) this.
|
|
4545
|
-
|
|
4546
|
-
|
|
4547
|
-
|
|
4548
|
-
|
|
4549
|
-
|
|
4550
|
-
*
|
|
4551
|
-
*
|
|
4552
|
-
|
|
4553
|
-
|
|
4554
|
-
const
|
|
4739
|
+
if (item._hasSubmenu && this._activeSubmenuOpener !== item) this._scheduleHoverOpen(item);
|
|
4740
|
+
}
|
|
4741
|
+
/** @internal For the safe triangle: the cursor has turned away from the
|
|
4742
|
+
* submenu, or stalled, at `p`. An item of this menu there takes over, as its
|
|
4743
|
+
* mouseenter would have while the cursor was protected. Anything else in or
|
|
4744
|
+
* out of this menu (a divider, the padding, the page) leaves the items. A
|
|
4745
|
+
* point in another menu is that menu's to handle: a menu is an auto
|
|
4746
|
+
* popover, so the only other one open is a submenu in this chain. */
|
|
4747
|
+
releaseAt(p) {
|
|
4748
|
+
const el = menuElementFromPoint(p.x, p.y);
|
|
4749
|
+
const menu = el?.closest("nldd-menu");
|
|
4750
|
+
if (menu && menu !== this) return;
|
|
4751
|
+
const item = el?.closest("nldd-menu-item");
|
|
4555
4752
|
if (item) this._activateItem(item);
|
|
4753
|
+
else this._leaveItems();
|
|
4754
|
+
}
|
|
4755
|
+
/** The pointer is over none of this menu's items: nothing stays open or
|
|
4756
|
+
* highlighted for an item it has left. */
|
|
4757
|
+
_leaveItems() {
|
|
4758
|
+
this._cancelHoverOpen();
|
|
4759
|
+
this._activeSubmenu?.hidePopover?.();
|
|
4760
|
+
if (this.variant !== "listbox") this._clearHighlight();
|
|
4761
|
+
}
|
|
4762
|
+
/**
|
|
4763
|
+
* Opens the item's submenu once the pointer comes to rest on it: it stops
|
|
4764
|
+
* ({@link HOVER_REST_MS} without a move), slows below
|
|
4765
|
+
* {@link HOVER_SLOW_PX_PER_MS}, or has stayed on the item for
|
|
4766
|
+
* {@link HOVER_OPEN_MAX_MS}. A pointer passing over the menu on its way
|
|
4767
|
+
* somewhere does none of that, so it opens nothing.
|
|
4768
|
+
*/
|
|
4769
|
+
_scheduleHoverOpen(item) {
|
|
4770
|
+
this._hoverOpenItem = item;
|
|
4771
|
+
this._hoverOpenDeadline = performance.now() + HOVER_OPEN_MAX_MS;
|
|
4772
|
+
this._waitForRest();
|
|
4773
|
+
}
|
|
4774
|
+
/** (Re)starts the wait for the pointer to rest, never past the deadline. */
|
|
4775
|
+
_waitForRest() {
|
|
4776
|
+
if (this._hoverOpenTimer !== null) clearTimeout(this._hoverOpenTimer);
|
|
4777
|
+
const wait = Math.min(HOVER_REST_MS, this._hoverOpenDeadline - performance.now());
|
|
4778
|
+
this._hoverOpenTimer = window.setTimeout(() => this._openHoverItem(), Math.max(0, wait));
|
|
4779
|
+
}
|
|
4780
|
+
_openHoverItem() {
|
|
4781
|
+
const item = this._hoverOpenItem;
|
|
4782
|
+
this._cancelHoverOpen();
|
|
4783
|
+
item?._handleClick();
|
|
4556
4784
|
}
|
|
4557
4785
|
_cancelHoverOpen() {
|
|
4558
|
-
if (this._hoverOpenTimer !== null)
|
|
4559
|
-
|
|
4560
|
-
|
|
4561
|
-
|
|
4786
|
+
if (this._hoverOpenTimer !== null) clearTimeout(this._hoverOpenTimer);
|
|
4787
|
+
this._hoverOpenTimer = null;
|
|
4788
|
+
this._hoverOpenItem = null;
|
|
4789
|
+
this._lastHoverMove = null;
|
|
4562
4790
|
}
|
|
4563
4791
|
static _getDrillInModeQuery() {
|
|
4564
4792
|
if (NLDDMenu._drillInModeQuery === null) NLDDMenu._drillInModeQuery = matchMedia(`(pointer: coarse), (max-width: ${queryBreakpoints.smMax})`);
|
|
@@ -4593,6 +4821,7 @@ var NLDDMenu = class NLDDMenu extends LitElement {
|
|
|
4593
4821
|
this.addEventListener("focusout", this._handleFocusOut);
|
|
4594
4822
|
this.addEventListener("mouseenter", this._handleMenuItemMouseenter, true);
|
|
4595
4823
|
this.addEventListener("mouseover", this._handleMouseover);
|
|
4824
|
+
this.addEventListener("mousemove", this._handleHoverMove);
|
|
4596
4825
|
this.addEventListener("mouseleave", this._handleMouseleave);
|
|
4597
4826
|
this.addEventListener("menu-item-focused", this._handleMenuItemFocused);
|
|
4598
4827
|
this.addEventListener("submenu-open", this._handleSubmenuOpen);
|
|
@@ -4625,6 +4854,7 @@ var NLDDMenu = class NLDDMenu extends LitElement {
|
|
|
4625
4854
|
this._tabbing = false;
|
|
4626
4855
|
this.removeEventListener("mouseenter", this._handleMenuItemMouseenter, true);
|
|
4627
4856
|
this.removeEventListener("mouseover", this._handleMouseover);
|
|
4857
|
+
this.removeEventListener("mousemove", this._handleHoverMove);
|
|
4628
4858
|
this.removeEventListener("mouseleave", this._handleMouseleave);
|
|
4629
4859
|
this.removeEventListener("menu-item-focused", this._handleMenuItemFocused);
|
|
4630
4860
|
this.removeEventListener("submenu-open", this._handleSubmenuOpen);
|
|
@@ -4914,13 +5144,10 @@ __decorate([property({
|
|
|
4914
5144
|
reflect: true,
|
|
4915
5145
|
converter: reflectNonDefault("menu")
|
|
4916
5146
|
})], NLDDMenu.prototype, "variant", void 0);
|
|
5147
|
+
__decorate([property({ type: String })], NLDDMenu.prototype, "width", void 0);
|
|
4917
5148
|
__decorate([property({
|
|
4918
|
-
|
|
4919
|
-
|
|
4920
|
-
})], NLDDMenu.prototype, "width", void 0);
|
|
4921
|
-
__decorate([property({
|
|
4922
|
-
type: String,
|
|
4923
|
-
reflect: true
|
|
5149
|
+
reflect: true,
|
|
5150
|
+
converter: reflectNonDefault("")
|
|
4924
5151
|
})], NLDDMenu.prototype, "anchor", void 0);
|
|
4925
5152
|
__decorate([property({ attribute: false })], NLDDMenu.prototype, "anchorElement", void 0);
|
|
4926
5153
|
__decorate([property({ attribute: "accessible-label" })], NLDDMenu.prototype, "accessibleLabel", void 0);
|
|
@@ -5316,6 +5543,15 @@ var _NLDDButtonBar;
|
|
|
5316
5543
|
*/
|
|
5317
5544
|
if (!customElements.get("nldd-button-bar-divider")) customElements.define("nldd-button-bar-divider", class extends HTMLElement {});
|
|
5318
5545
|
var BUTTON_TAGS = ["nldd-button", "nldd-icon-button"];
|
|
5546
|
+
/**
|
|
5547
|
+
* Hands a value the bar decides to a button. The property, not the attribute:
|
|
5548
|
+
* a framework such as Vue sets these as properties, only the property
|
|
5549
|
+
* overrides that, and the button's converter leaves no attribute at its default.
|
|
5550
|
+
*/
|
|
5551
|
+
function assign(el, name, value) {
|
|
5552
|
+
if (name in el) el[name] = value;
|
|
5553
|
+
else el.setAttribute(name, value);
|
|
5554
|
+
}
|
|
5319
5555
|
var NLDDButtonBar = (_NLDDButtonBar = class NLDDButtonBar extends LitElement {
|
|
5320
5556
|
constructor(..._args) {
|
|
5321
5557
|
super(..._args);
|
|
@@ -5358,10 +5594,10 @@ var NLDDButtonBar = (_NLDDButtonBar = class NLDDButtonBar extends LitElement {
|
|
|
5358
5594
|
if (BUTTON_TAGS.includes(target.tagName.toLowerCase())) target.removeAttribute("data-focused");
|
|
5359
5595
|
}
|
|
5360
5596
|
_propagateSize() {
|
|
5361
|
-
Array.from(this.children).filter((el) => BUTTON_TAGS.includes(el.tagName.toLowerCase())).forEach((el) => el
|
|
5597
|
+
Array.from(this.children).filter((el) => BUTTON_TAGS.includes(el.tagName.toLowerCase())).forEach((el) => assign(el, "size", this.size));
|
|
5362
5598
|
}
|
|
5363
5599
|
_propagateAppearance() {
|
|
5364
|
-
Array.from(this.children).filter((el) => BUTTON_TAGS.includes(el.tagName.toLowerCase())).forEach((el) => el
|
|
5600
|
+
Array.from(this.children).filter((el) => BUTTON_TAGS.includes(el.tagName.toLowerCase())).forEach((el) => assign(el, "appearance", this.appearance));
|
|
5365
5601
|
}
|
|
5366
5602
|
_propagateDisabled() {
|
|
5367
5603
|
const buttons = Array.from(this.children).filter((el) => BUTTON_TAGS.includes(el.tagName.toLowerCase()));
|
|
@@ -5388,8 +5624,8 @@ var NLDDButtonBar = (_NLDDButtonBar = class NLDDButtonBar extends LitElement {
|
|
|
5388
5624
|
id: this._idCounter++
|
|
5389
5625
|
};
|
|
5390
5626
|
if (BUTTON_TAGS.includes(tag)) {
|
|
5391
|
-
el
|
|
5392
|
-
el
|
|
5627
|
+
assign(el, "size", this.size);
|
|
5628
|
+
assign(el, "appearance", this.appearance);
|
|
5393
5629
|
el.setAttribute("no-highlight-border", "");
|
|
5394
5630
|
}
|
|
5395
5631
|
const id = this._idCounter++;
|
|
@@ -6167,12 +6403,12 @@ __decorate([property({
|
|
|
6167
6403
|
converter: reflectNonDefault("")
|
|
6168
6404
|
})], NLDDToolbarTitle.prototype, "supportingText", void 0);
|
|
6169
6405
|
__decorate([property({
|
|
6170
|
-
|
|
6171
|
-
|
|
6406
|
+
reflect: true,
|
|
6407
|
+
converter: reflectNonDefault("")
|
|
6172
6408
|
})], NLDDToolbarTitle.prototype, "href", void 0);
|
|
6173
6409
|
__decorate([property({
|
|
6174
|
-
|
|
6175
|
-
|
|
6410
|
+
reflect: true,
|
|
6411
|
+
converter: reflectNonDefault("")
|
|
6176
6412
|
})], NLDDToolbarTitle.prototype, "target", void 0);
|
|
6177
6413
|
__decorate([property({ type: Object })], NLDDToolbarTitle.prototype, "translations", void 0);
|
|
6178
6414
|
__decorate([property({
|
|
@@ -7103,8 +7339,8 @@ __decorate([property({
|
|
|
7103
7339
|
converter: reflectNonDefault("delay")
|
|
7104
7340
|
})], NLDDAvatar.prototype, "tooltipTiming", void 0);
|
|
7105
7341
|
__decorate([property({
|
|
7106
|
-
|
|
7107
|
-
|
|
7342
|
+
reflect: true,
|
|
7343
|
+
converter: reflectNonDefault("")
|
|
7108
7344
|
})], NLDDAvatar.prototype, "href", void 0);
|
|
7109
7345
|
__decorate([property({
|
|
7110
7346
|
type: Boolean,
|
|
@@ -7909,7 +8145,7 @@ var NLDDPopover = (_NLDDPopover2 = class NLDDPopover extends LitElement {
|
|
|
7909
8145
|
this.translations = {};
|
|
7910
8146
|
this.open = false;
|
|
7911
8147
|
this._isOpen = false;
|
|
7912
|
-
this.
|
|
8148
|
+
this._focusReturn = new FocusReturn();
|
|
7913
8149
|
this._pointerdownOnAnchorWhileOpen = false;
|
|
7914
8150
|
this._cleanupAutoUpdate = null;
|
|
7915
8151
|
this._smQuery = null;
|
|
@@ -7966,7 +8202,9 @@ var NLDDPopover = (_NLDDPopover2 = class NLDDPopover extends LitElement {
|
|
|
7966
8202
|
else this.showPopover();
|
|
7967
8203
|
};
|
|
7968
8204
|
this._handleBeforeToggle = (event) => {
|
|
7969
|
-
if (event.newState
|
|
8205
|
+
if (event.newState !== "open") return;
|
|
8206
|
+
this.removeAttribute("positioned");
|
|
8207
|
+
this._focusReturn.remember(this._getAnchorEl());
|
|
7970
8208
|
};
|
|
7971
8209
|
this._handleToggle = async (event) => {
|
|
7972
8210
|
const toggleEvent = event;
|
|
@@ -7976,14 +8214,13 @@ var NLDDPopover = (_NLDDPopover2 = class NLDDPopover extends LitElement {
|
|
|
7976
8214
|
if (toggleEvent.newState !== "open") {
|
|
7977
8215
|
this._cleanupAutoUpdate?.();
|
|
7978
8216
|
this._cleanupAutoUpdate = null;
|
|
7979
|
-
this.
|
|
8217
|
+
this._focusReturn.restore(this);
|
|
7980
8218
|
this.dispatchEvent(new CustomEvent("close", {
|
|
7981
8219
|
bubbles: false,
|
|
7982
8220
|
composed: true
|
|
7983
8221
|
}));
|
|
7984
8222
|
return;
|
|
7985
8223
|
}
|
|
7986
|
-
this._previousFocus = document.activeElement ?? this._getAnchorEl();
|
|
7987
8224
|
await this.reposition();
|
|
7988
8225
|
this.setAttribute("positioned", "");
|
|
7989
8226
|
const anchorEl = this._getAnchorEl();
|
|
@@ -8001,7 +8238,6 @@ var NLDDPopover = (_NLDDPopover2 = class NLDDPopover extends LitElement {
|
|
|
8001
8238
|
event.preventDefault();
|
|
8002
8239
|
event.stopPropagation();
|
|
8003
8240
|
this.hide();
|
|
8004
|
-
this._getAnchorEl()?.focus();
|
|
8005
8241
|
return;
|
|
8006
8242
|
}
|
|
8007
8243
|
if (event.key !== "Tab") return;
|
|
@@ -8217,11 +8453,6 @@ var NLDDPopover = (_NLDDPopover2 = class NLDDPopover extends LitElement {
|
|
|
8217
8453
|
}
|
|
8218
8454
|
this.focus();
|
|
8219
8455
|
}
|
|
8220
|
-
_returnFocus() {
|
|
8221
|
-
const target = this._previousFocus ?? this._getAnchorEl();
|
|
8222
|
-
this._previousFocus = null;
|
|
8223
|
-
target?.focus();
|
|
8224
|
-
}
|
|
8225
8456
|
_getFocusables() {
|
|
8226
8457
|
const selector = [
|
|
8227
8458
|
"a[href]",
|
|
@@ -8266,8 +8497,8 @@ __decorate([property({
|
|
|
8266
8497
|
attribute: "sm-full-height"
|
|
8267
8498
|
})], NLDDPopover.prototype, "smFullHeight", void 0);
|
|
8268
8499
|
__decorate([property({
|
|
8269
|
-
|
|
8270
|
-
|
|
8500
|
+
reflect: true,
|
|
8501
|
+
converter: reflectNonDefault("")
|
|
8271
8502
|
})], NLDDPopover.prototype, "anchor", void 0);
|
|
8272
8503
|
__decorate([property({ attribute: false })], NLDDPopover.prototype, "anchorElement", void 0);
|
|
8273
8504
|
__decorate([property({
|
|
@@ -9558,9 +9789,10 @@ var pageStyles = css`
|
|
|
9558
9789
|
opacity: 0;
|
|
9559
9790
|
}
|
|
9560
9791
|
|
|
9561
|
-
/* Root-scroll mode: footer
|
|
9792
|
+
/* Root-scroll mode: the footer sits inside .page__scroll, where the inset
|
|
9793
|
+
already holds its own height. */
|
|
9562
9794
|
:host([data-scroll="root"][sticky-footer]) .page__footer {
|
|
9563
|
-
bottom: var(--
|
|
9795
|
+
bottom: var(--_page-outer-inset-bottom);
|
|
9564
9796
|
}
|
|
9565
9797
|
`;
|
|
9566
9798
|
// src/components/layout/page/page.template.ts
|
|
@@ -9951,8 +10183,8 @@ var NLDDPage = (_NLDDPage = class NLDDPage extends LitElement {
|
|
|
9951
10183
|
}
|
|
9952
10184
|
}, _NLDDPage.styles = pageStyles, _NLDDPage);
|
|
9953
10185
|
__decorate([property({
|
|
9954
|
-
|
|
9955
|
-
|
|
10186
|
+
reflect: true,
|
|
10187
|
+
converter: reflectNonDefault("inherit")
|
|
9956
10188
|
})], NLDDPage.prototype, "background", void 0);
|
|
9957
10189
|
__decorate([property({
|
|
9958
10190
|
type: String,
|
|
@@ -9969,8 +10201,8 @@ __decorate([property({
|
|
|
9969
10201
|
attribute: "sticky-footer"
|
|
9970
10202
|
})], NLDDPage.prototype, "stickyFooter", void 0);
|
|
9971
10203
|
__decorate([property({
|
|
9972
|
-
|
|
9973
|
-
|
|
10204
|
+
reflect: true,
|
|
10205
|
+
converter: reflectNonDefault("auto")
|
|
9974
10206
|
})], NLDDPage.prototype, "landmarks", void 0);
|
|
9975
10207
|
__decorate([state()], NLDDPage.prototype, "_scrolled", void 0);
|
|
9976
10208
|
__decorate([state()], NLDDPage.prototype, "_atEnd", void 0);
|
|
@@ -11151,6 +11383,7 @@ var NLDDList = (_NLDDList2 = class NLDDList extends LitElement {
|
|
|
11151
11383
|
this._syncUnmanagedControls();
|
|
11152
11384
|
}
|
|
11153
11385
|
if (changed.has("appearance")) this._updateItemContext();
|
|
11386
|
+
if (changed.has("dividers") && changed.get("dividers") !== void 0) this._getItems().forEach((item) => item._measureDividerMarkers());
|
|
11154
11387
|
if (changed.has("type")) {
|
|
11155
11388
|
this._applyHostType();
|
|
11156
11389
|
if (changed.get("type") === "listbox" && this.type !== "listbox") {
|
|
@@ -11738,8 +11971,8 @@ __decorate([property({
|
|
|
11738
11971
|
converter: reflectNonDefault("always")
|
|
11739
11972
|
})], NLDDList.prototype, "dividers", void 0);
|
|
11740
11973
|
__decorate([property({
|
|
11741
|
-
|
|
11742
|
-
|
|
11974
|
+
reflect: true,
|
|
11975
|
+
converter: reflectNonDefault("")
|
|
11743
11976
|
})], NLDDList.prototype, "height", void 0);
|
|
11744
11977
|
__decorate([property({
|
|
11745
11978
|
type: String,
|
|
@@ -11953,11 +12186,17 @@ var listItemStyles = css`
|
|
|
11953
12186
|
--context-content-secondary-color: var(--semantics-list-items-is-selected-content-color);
|
|
11954
12187
|
}
|
|
11955
12188
|
|
|
12189
|
+
/* On the row, not the host, so a ring inside matches the fill without
|
|
12190
|
+
reaching the child rows. :where keeps it as light as the fill it mirrors. */
|
|
12191
|
+
:host(:where([selected], [checkbox][checked], [current], [data-current])) .list-item {
|
|
12192
|
+
--context-parent-background-color: var(--semantics-list-items-is-selected-background-color);
|
|
12193
|
+
}
|
|
11956
12194
|
|
|
11957
12195
|
/* A checked checkbox action selects the whole row, so the fill runs across
|
|
11958
12196
|
the disclosure action too instead of stopping at its boundary. */
|
|
11959
12197
|
.list-item.is-action-checked {
|
|
11960
12198
|
--_list-item-background-color: var(--semantics-list-items-is-selected-background-color);
|
|
12199
|
+
--context-parent-background-color: var(--semantics-list-items-is-selected-background-color);
|
|
11961
12200
|
--context-content-color: var(--semantics-list-items-is-selected-content-color);
|
|
11962
12201
|
--context-content-secondary-color: var(--semantics-list-items-is-selected-content-color);
|
|
11963
12202
|
}
|
|
@@ -11972,6 +12211,7 @@ var listItemStyles = css`
|
|
|
11972
12211
|
@media (hover: hover) {
|
|
11973
12212
|
:host(:not([disabled])) .list-item__action:hover {
|
|
11974
12213
|
--_list-item-background-color: var(--semantics-list-items-is-hovered-background-color);
|
|
12214
|
+
--context-parent-background-color: var(--semantics-list-items-is-hovered-background-color);
|
|
11975
12215
|
--context-content-color: var(--semantics-list-items-is-hovered-content-color);
|
|
11976
12216
|
--context-content-secondary-color: var(--semantics-list-items-is-hovered-content-color);
|
|
11977
12217
|
}
|
|
@@ -11979,6 +12219,7 @@ var listItemStyles = css`
|
|
|
11979
12219
|
:host(:is([selected], [checkbox][checked]):not([disabled])) .list-item__action:hover,
|
|
11980
12220
|
:host(:is([current], [data-current]):not([disabled])) .list-item__action:hover {
|
|
11981
12221
|
--_list-item-background-color: var(--semantics-list-items-is-selected-is-hovered-background-color);
|
|
12222
|
+
--context-parent-background-color: var(--semantics-list-items-is-selected-is-hovered-background-color);
|
|
11982
12223
|
--context-content-color: var(--semantics-list-items-is-selected-content-color);
|
|
11983
12224
|
--context-content-secondary-color: var(--semantics-list-items-is-selected-content-color);
|
|
11984
12225
|
}
|
|
@@ -12009,6 +12250,7 @@ var listItemStyles = css`
|
|
|
12009
12250
|
hovering it as well, and the state it just gave focus to has to win. */
|
|
12010
12251
|
:host(:is([current], [data-current]):focus-within) .list-item,
|
|
12011
12252
|
:host(:is([current], [data-current]):focus-within) .list-item__action {
|
|
12253
|
+
--context-parent-background-color: var(--semantics-list-items-is-highlighted-background-color);
|
|
12012
12254
|
--context-content-color: var(--semantics-list-items-is-highlighted-content-color);
|
|
12013
12255
|
--context-content-secondary-color: var(--semantics-list-items-is-highlighted-content-color);
|
|
12014
12256
|
}
|
|
@@ -12045,6 +12287,7 @@ var listItemStyles = css`
|
|
|
12045
12287
|
/* The content color has to travel with the fill: the neutral press rule
|
|
12046
12288
|
above sets it too, and black on a deep accent is unreadable. */
|
|
12047
12289
|
:host(:is([current], [data-current]):focus-within:not([disabled])) .list-item__action:hover {
|
|
12290
|
+
--context-parent-background-color: var(--semantics-list-items-is-highlighted-is-hovered-background-color);
|
|
12048
12291
|
--context-content-color: var(--semantics-list-items-is-highlighted-content-color);
|
|
12049
12292
|
--context-content-secondary-color: var(--semantics-list-items-is-highlighted-content-color);
|
|
12050
12293
|
}
|
|
@@ -12053,6 +12296,7 @@ var listItemStyles = css`
|
|
|
12053
12296
|
the press (pointercancel) instead of flashing it. */
|
|
12054
12297
|
:host(:not([disabled])) .list-item__action.is-pressed {
|
|
12055
12298
|
--_list-item-background-color: var(--semantics-list-items-is-active-background-color);
|
|
12299
|
+
--context-parent-background-color: var(--semantics-list-items-is-active-background-color);
|
|
12056
12300
|
--context-content-color: var(--semantics-list-items-is-active-content-color);
|
|
12057
12301
|
--context-content-secondary-color: var(--semantics-list-items-is-active-content-color);
|
|
12058
12302
|
}
|
|
@@ -12060,12 +12304,14 @@ var listItemStyles = css`
|
|
|
12060
12304
|
:host(:is([selected], [checkbox][checked]):not([disabled])) .list-item__action.is-pressed,
|
|
12061
12305
|
:host(:is([current], [data-current]):not([disabled])) .list-item__action.is-pressed {
|
|
12062
12306
|
--_list-item-background-color: var(--semantics-list-items-is-selected-is-active-background-color);
|
|
12307
|
+
--context-parent-background-color: var(--semantics-list-items-is-selected-is-active-background-color);
|
|
12063
12308
|
--context-content-color: var(--semantics-list-items-is-selected-content-color);
|
|
12064
12309
|
--context-content-secondary-color: var(--semantics-list-items-is-selected-content-color);
|
|
12065
12310
|
}
|
|
12066
12311
|
|
|
12067
12312
|
:host(:is([selected], [checkbox][checked])) .list-item__action {
|
|
12068
12313
|
--_list-item-background-color: var(--semantics-list-items-is-selected-background-color);
|
|
12314
|
+
--context-parent-background-color: var(--semantics-list-items-is-selected-background-color);
|
|
12069
12315
|
--context-content-color: var(--semantics-list-items-is-selected-content-color);
|
|
12070
12316
|
--context-content-secondary-color: var(--semantics-list-items-is-selected-content-color);
|
|
12071
12317
|
}
|
|
@@ -12078,9 +12324,16 @@ var listItemStyles = css`
|
|
|
12078
12324
|
--context-content-secondary-color: var(--semantics-list-items-is-highlighted-content-color);
|
|
12079
12325
|
}
|
|
12080
12326
|
|
|
12327
|
+
/* The same two selectors as the fill above, so the hover rule cannot win. */
|
|
12328
|
+
:host(:is([current], [data-current]):not([disabled])) .list-item__action.is-pressed,
|
|
12329
|
+
:host(:is([current], [data-current]):focus-within:not([disabled])) .list-item__action.is-pressed {
|
|
12330
|
+
--context-parent-background-color: var(--semantics-list-items-is-highlighted-is-active-background-color);
|
|
12331
|
+
}
|
|
12332
|
+
|
|
12081
12333
|
.list-item.is-highlighted,
|
|
12082
12334
|
:host(:is([selected], [checkbox][checked])) .list-item.is-highlighted .list-item__action {
|
|
12083
12335
|
--_list-item-background-color: var(--semantics-list-items-is-highlighted-background-color);
|
|
12336
|
+
--context-parent-background-color: var(--semantics-list-items-is-highlighted-background-color);
|
|
12084
12337
|
--context-content-color: var(--semantics-list-items-is-highlighted-content-color);
|
|
12085
12338
|
--context-content-secondary-color: var(--semantics-list-items-is-highlighted-content-color);
|
|
12086
12339
|
}
|
|
@@ -12714,14 +12967,6 @@ var NLDDListItem = (_NLDDListItem2 = class NLDDListItem extends withTranslations
|
|
|
12714
12967
|
else action?.removeAttribute("aria-current");
|
|
12715
12968
|
}
|
|
12716
12969
|
/**
|
|
12717
|
-
* Measures the divider markers and writes the result as `--_list-item-divider-inset-
|
|
12718
|
-
* start/-end` on the host. No markers → the vars are cleared and CSS falls
|
|
12719
|
-
* back to the content width. Union semantics: the divider runs from the
|
|
12720
|
-
* FIRST `divider-start` to the LAST `divider-end`; a side without markers
|
|
12721
|
-
* keeps its default. Insets are measured against the row block (the widened
|
|
12722
|
-
* box on interactive rows), so the values compose with the edge geometry.
|
|
12723
|
-
*/
|
|
12724
|
-
/**
|
|
12725
12970
|
* The cell the divider starts at when nobody said otherwise: the row's first
|
|
12726
12971
|
* text or title cell. The line lands on the words rather than on whatever
|
|
12727
12972
|
* leads up to them — an icon, an avatar, a checkbox, or the spacers a tree
|
|
@@ -12732,11 +12977,23 @@ var NLDDListItem = (_NLDDListItem2 = class NLDDListItem extends withTranslations
|
|
|
12732
12977
|
_implicitDividerStart() {
|
|
12733
12978
|
return this._ownDescendants("nldd-text-cell, nldd-title-cell");
|
|
12734
12979
|
}
|
|
12980
|
+
/**
|
|
12981
|
+
* Measures the divider markers and writes the result as `--_list-item-divider-inset-
|
|
12982
|
+
* start/-end` on the host. No markers → the vars are cleared and CSS falls
|
|
12983
|
+
* back to the content width. Union semantics: the divider runs from the
|
|
12984
|
+
* FIRST `divider-start` to the LAST `divider-end`; a side without markers
|
|
12985
|
+
* keeps its default. Insets are measured against the row block (the widened
|
|
12986
|
+
* box on interactive rows), so the values compose with the edge geometry.
|
|
12987
|
+
* A list with `dividers="never"` draws no line, so its rows measure nothing.
|
|
12988
|
+
*
|
|
12989
|
+
* @internal Also called by the list when its `dividers` changes.
|
|
12990
|
+
*/
|
|
12735
12991
|
_measureDividerMarkers() {
|
|
12736
12992
|
if (this.hasAttribute("data-nldd-clone")) return;
|
|
12737
|
-
const
|
|
12738
|
-
const
|
|
12739
|
-
const
|
|
12993
|
+
const drawsDivider = this._parentList?.getAttribute("dividers") !== "never";
|
|
12994
|
+
const explicitStarts = drawsDivider ? this._ownDescendants("[divider-start]") : [];
|
|
12995
|
+
const starts = !drawsDivider ? [] : explicitStarts.length ? explicitStarts : this._implicitDividerStart();
|
|
12996
|
+
const ends = drawsDivider ? this._ownDescendants("[divider-end]") : [];
|
|
12740
12997
|
const targets = starts.length || ends.length ? [
|
|
12741
12998
|
this,
|
|
12742
12999
|
...starts,
|
|
@@ -13351,8 +13608,8 @@ var NLDDAvatarGroup = (_NLDDAvatarGroup = class NLDDAvatarGroup extends withTran
|
|
|
13351
13608
|
}
|
|
13352
13609
|
}, _NLDDAvatarGroup.styles = avatarGroupStyles, _NLDDAvatarGroup);
|
|
13353
13610
|
__decorate([property({
|
|
13354
|
-
|
|
13355
|
-
|
|
13611
|
+
reflect: true,
|
|
13612
|
+
converter: reflectNonDefault("40")
|
|
13356
13613
|
})], NLDDAvatarGroup.prototype, "size", void 0);
|
|
13357
13614
|
__decorate([property({
|
|
13358
13615
|
type: Number,
|
|
@@ -15770,9 +16027,9 @@ __decorate([property({
|
|
|
15770
16027
|
attribute: "fetchpriority"
|
|
15771
16028
|
})], NLDDImage.prototype, "fetchPriority", void 0);
|
|
15772
16029
|
__decorate([property({
|
|
15773
|
-
|
|
16030
|
+
reflect: true,
|
|
15774
16031
|
attribute: "aspect-ratio",
|
|
15775
|
-
|
|
16032
|
+
converter: reflectNonDefault("")
|
|
15776
16033
|
})], NLDDImage.prototype, "aspectRatio", void 0);
|
|
15777
16034
|
__decorate([property({
|
|
15778
16035
|
reflect: true,
|
|
@@ -16189,12 +16446,12 @@ function template$13(component) {
|
|
|
16189
16446
|
>
|
|
16190
16447
|
${showIcon ? html`
|
|
16191
16448
|
<span class="tag__icon">
|
|
16192
|
-
|
|
16449
|
+
<slot name="icon">${component.icon ? html`<nldd-icon icon=${component.icon}></nldd-icon>` : variant === "icon" ? html`<nldd-icon icon="icon-placeholder"></nldd-icon>` : nothing}</slot>
|
|
16193
16450
|
</span>
|
|
16194
16451
|
` : nothing}
|
|
16195
16452
|
${showText ? html`
|
|
16196
16453
|
<span class="tag__text">
|
|
16197
|
-
${component.
|
|
16454
|
+
${component._hasSlotText ? nothing : component.text}<slot></slot>
|
|
16198
16455
|
</span>
|
|
16199
16456
|
` : nothing}
|
|
16200
16457
|
</span>
|
|
@@ -16216,12 +16473,12 @@ function template$13(component) {
|
|
|
16216
16473
|
* @attr {string} variant - What is visible: 'text' | 'icon' | 'icon-and-text'. Unset → detected from which of text/icon is present.
|
|
16217
16474
|
* @attr {string} color - Color variant. Semantic: 'neutral' | 'accent' | 'success' | 'warning' | 'critical'. Rijkshuisstijl colors: 'lintblauw' | 'donkerblauw' | 'hemelblauw' | 'lichtblauw' | 'paars' | 'violet' | 'robijnrood' | 'roze' | 'rood' | 'oranje' | 'donkergeel' | 'geel' | 'donkerbruin' | 'bruin' | 'donkergroen' | 'groen' | 'mosgroen' | 'mintgroen'. (default: 'neutral')
|
|
16218
16475
|
* @attr {string} size - Tag size: 'sm' | 'md' (default: 'md')
|
|
16219
|
-
* @attr {string} text - Tag text
|
|
16476
|
+
* @attr {string} text - Tag text. Content in the default slot wins.
|
|
16220
16477
|
* @attr {string} icon - Icon before the text
|
|
16221
16478
|
* @attr {string} accessible-label - Accessible label for screen readers. Use this on icon-only tags without visible text.
|
|
16222
16479
|
*
|
|
16223
|
-
* @slot - Tag text
|
|
16224
|
-
* @slot icon - Custom icon before the text
|
|
16480
|
+
* @slot - Tag text. Wins over `text`.
|
|
16481
|
+
* @slot icon - Custom icon before the text. Wins over `icon`.
|
|
16225
16482
|
*/
|
|
16226
16483
|
var _NLDDTag = class NLDDTag extends LitElement {
|
|
16227
16484
|
constructor(..._args) {
|
|
@@ -17212,6 +17469,7 @@ function titleTemplate(component) {
|
|
|
17212
17469
|
* @slot supporting-text - Supporting text that is more than text. Takes the place of the supporting-text attribute.
|
|
17213
17470
|
* @slot end - Whatever belongs at the end of the title line: a button, a menu, a status badge, a version. Named for the position, not for a kind of content, because anything can sit there.
|
|
17214
17471
|
*/
|
|
17472
|
+
var title_exports = /* @__PURE__ */ __exportAll({ NLDDTitle: () => NLDDTitle });
|
|
17215
17473
|
var _NLDDTitle = class NLDDTitle extends LitElement {
|
|
17216
17474
|
constructor(..._args) {
|
|
17217
17475
|
super(..._args);
|
|
@@ -17256,8 +17514,8 @@ var _NLDDTitle = class NLDDTitle extends LitElement {
|
|
|
17256
17514
|
};
|
|
17257
17515
|
var NLDDTitle = (_NLDDTitle.styles = titleStyles, _NLDDTitle);
|
|
17258
17516
|
__decorate([property({
|
|
17259
|
-
|
|
17260
|
-
|
|
17517
|
+
reflect: true,
|
|
17518
|
+
converter: reflectNonDefault(3)
|
|
17261
17519
|
})], NLDDTitle.prototype, "size", void 0);
|
|
17262
17520
|
__decorate([property({
|
|
17263
17521
|
reflect: true,
|
|
@@ -17428,7 +17686,7 @@ var tokenStyles = css`
|
|
|
17428
17686
|
function tokenTemplate(component) {
|
|
17429
17687
|
return html`
|
|
17430
17688
|
<div class="token">
|
|
17431
|
-
<span class="token__text">${component.
|
|
17689
|
+
<span class="token__text">${component._textSlot.has ? nothing : component.text}<slot @slotchange=${component._textSlot.onChange}></slot></span>
|
|
17432
17690
|
${component.control === "dismiss" ? html`
|
|
17433
17691
|
<div class="token__dismiss-action">
|
|
17434
17692
|
<nldd-icon-button
|
|
@@ -17479,7 +17737,7 @@ function tokenTemplate(component) {
|
|
|
17479
17737
|
*
|
|
17480
17738
|
* @element nldd-token
|
|
17481
17739
|
*
|
|
17482
|
-
* @attr {string} text - Token text
|
|
17740
|
+
* @attr {string} text - Token text. Content in the default slot wins.
|
|
17483
17741
|
* @attr {'none' | 'dismiss' | 'menu'} control - Control type (default: 'none')
|
|
17484
17742
|
* @attr {string} dismiss-text - Accessible label for the dismiss button. Unset, it names the token: `Verwijder "{text}"`, so a row of tokens does not read as a row of identical buttons.
|
|
17485
17743
|
* @attr {string} menu-text - Accessible label for the menu button. Unset, it is `Toon opties voor "{text}"`.
|
|
@@ -17488,7 +17746,7 @@ function tokenTemplate(component) {
|
|
|
17488
17746
|
* @attr {boolean} expanded - Reflects whether the token's menu is open (control="menu"); managed by the token.
|
|
17489
17747
|
* @attr {boolean} disabled - Disabled state. Avoid it where you can; the design guidelines say why.
|
|
17490
17748
|
*
|
|
17491
|
-
* @slot - Token text
|
|
17749
|
+
* @slot - Token text. Wins over `text`.
|
|
17492
17750
|
* @slot menu - An nldd-menu that the token opens from its menu button (control="menu").
|
|
17493
17751
|
*
|
|
17494
17752
|
* @fires dismiss - When the dismiss button is clicked
|
|
@@ -17496,6 +17754,7 @@ function tokenTemplate(component) {
|
|
|
17496
17754
|
var _NLDDToken = class NLDDToken extends LitElement {
|
|
17497
17755
|
constructor(..._args) {
|
|
17498
17756
|
super(..._args);
|
|
17757
|
+
this._textSlot = new SlotContent(this);
|
|
17499
17758
|
this.text = "";
|
|
17500
17759
|
this.control = "none";
|
|
17501
17760
|
this.dismissText = "";
|
|
@@ -27699,8 +27958,8 @@ __decorate([property({
|
|
|
27699
27958
|
converter: reflectNonDefault("md")
|
|
27700
27959
|
})], NLDDFileField.prototype, "size", void 0);
|
|
27701
27960
|
__decorate([property({
|
|
27702
|
-
|
|
27703
|
-
|
|
27961
|
+
reflect: true,
|
|
27962
|
+
converter: reflectNonDefault("")
|
|
27704
27963
|
})], NLDDFileField.prototype, "accept", void 0);
|
|
27705
27964
|
__decorate([property({
|
|
27706
27965
|
type: Boolean,
|
|
@@ -28556,6 +28815,7 @@ var oneTimeCodeFieldStyles = css`
|
|
|
28556
28815
|
display: block;
|
|
28557
28816
|
max-width: 100%;
|
|
28558
28817
|
-webkit-tap-highlight-color: transparent;
|
|
28818
|
+
pointer-events: none;
|
|
28559
28819
|
}
|
|
28560
28820
|
|
|
28561
28821
|
:host([hidden]) {
|
|
@@ -28603,6 +28863,7 @@ var oneTimeCodeFieldStyles = css`
|
|
|
28603
28863
|
position: relative;
|
|
28604
28864
|
width: fit-content;
|
|
28605
28865
|
max-width: 100%;
|
|
28866
|
+
pointer-events: auto;
|
|
28606
28867
|
}
|
|
28607
28868
|
|
|
28608
28869
|
:host([centered]) .one-time-code-field {
|
|
@@ -28691,12 +28952,12 @@ var oneTimeCodeFieldStyles = css`
|
|
|
28691
28952
|
white-space: pre;
|
|
28692
28953
|
}
|
|
28693
28954
|
|
|
28694
|
-
.one-time-code-field__separator
|
|
28955
|
+
.one-time-code-field__separator--space {
|
|
28695
28956
|
width: var(--_one-time-code-field-space-width);
|
|
28696
28957
|
flex-shrink: 0;
|
|
28697
28958
|
}
|
|
28698
28959
|
|
|
28699
|
-
.one-time-code-field__separator
|
|
28960
|
+
.one-time-code-field__separator--dash {
|
|
28700
28961
|
border-radius: calc(var(--_one-time-code-field-dash-height) / 2);
|
|
28701
28962
|
background-color: currentColor;
|
|
28702
28963
|
width: var(--_one-time-code-field-dash-width);
|
|
@@ -28870,8 +29131,8 @@ function renderBoxes(component) {
|
|
|
28870
29131
|
* with the boxes; any other character stays text. */
|
|
28871
29132
|
function renderSeparator(part) {
|
|
28872
29133
|
const mark = part.trim();
|
|
28873
|
-
if (mark === "") return html`<span class="one-time-code-field__separator
|
|
28874
|
-
if (mark === "-" || mark === "–") return html`<span class="one-time-code-field__separator
|
|
29134
|
+
if (mark === "") return html`<span class="one-time-code-field__separator one-time-code-field__separator--space"></span>`;
|
|
29135
|
+
if (mark === "-" || mark === "–") return html`<span class="one-time-code-field__separator one-time-code-field__separator--dash"></span>`;
|
|
28875
29136
|
return html`<span class="one-time-code-field__separator">${part}</span>`;
|
|
28876
29137
|
}
|
|
28877
29138
|
function oneTimeCodeFieldTemplate(component) {
|
|
@@ -31665,7 +31926,7 @@ function segmentedControlItemTemplate(component) {
|
|
|
31665
31926
|
<span class="segmented-control__item-icon"
|
|
31666
31927
|
aria-hidden=${isIcon ? nothing : "true"}
|
|
31667
31928
|
>
|
|
31668
|
-
|
|
31929
|
+
<slot name="icon">${component.icon ? html`<nldd-icon icon=${component.icon}></nldd-icon>` : showPlaceholder ? html`<nldd-icon icon="icon-placeholder"></nldd-icon>` : nothing}</slot>
|
|
31669
31930
|
</span>
|
|
31670
31931
|
<span class="segmented-control__item-text"
|
|
31671
31932
|
aria-hidden=${isIcon ? "true" : nothing}
|
|
@@ -31744,7 +32005,7 @@ function segmentedControlItemTemplate(component) {
|
|
|
31744
32005
|
* @attr {string} group-name - Name of the group for form submission, put on the native checkbox. Set by nldd-segmented-control.
|
|
31745
32006
|
* @attr {boolean} required - Required state of the native checkbox. In radio mode the group carries the constraint.
|
|
31746
32007
|
*
|
|
31747
|
-
* @slot icon - Slot for a custom icon (e.g. custom SVG).
|
|
32008
|
+
* @slot icon - Slot for a custom icon (e.g. custom SVG). Wins over `icon`.
|
|
31748
32009
|
*
|
|
31749
32010
|
* @fires item-change - When item is activated; detail: { value: string, checked: boolean }
|
|
31750
32011
|
*/
|
|
@@ -32166,8 +32427,8 @@ __decorate([property({
|
|
|
32166
32427
|
reflect: true
|
|
32167
32428
|
})], NLDDSegmentedControl.prototype, "invalid", void 0);
|
|
32168
32429
|
__decorate([property({
|
|
32169
|
-
|
|
32170
|
-
|
|
32430
|
+
reflect: true,
|
|
32431
|
+
converter: reflectNonDefault("")
|
|
32171
32432
|
})], NLDDSegmentedControl.prototype, "value", void 0);
|
|
32172
32433
|
__decorate([property({
|
|
32173
32434
|
type: Array,
|
|
@@ -32182,8 +32443,8 @@ __decorate([property({
|
|
|
32182
32443
|
converter: reflectNonDefault("md")
|
|
32183
32444
|
})], NLDDSegmentedControl.prototype, "size", void 0);
|
|
32184
32445
|
__decorate([property({
|
|
32185
|
-
|
|
32186
|
-
|
|
32446
|
+
reflect: true,
|
|
32447
|
+
converter: reflectNonDefault("radio")
|
|
32187
32448
|
})], NLDDSegmentedControl.prototype, "type", void 0);
|
|
32188
32449
|
__decorate([property({
|
|
32189
32450
|
reflect: true,
|
|
@@ -32820,8 +33081,8 @@ __decorate([property({
|
|
|
32820
33081
|
converter: reflectNonDefault("")
|
|
32821
33082
|
})], NLDDSwatchPicker.prototype, "name", void 0);
|
|
32822
33083
|
__decorate([property({
|
|
32823
|
-
|
|
32824
|
-
|
|
33084
|
+
reflect: true,
|
|
33085
|
+
converter: reflectNonDefault("")
|
|
32825
33086
|
})], NLDDSwatchPicker.prototype, "value", void 0);
|
|
32826
33087
|
__decorate([property({
|
|
32827
33088
|
type: Boolean,
|
|
@@ -42081,8 +42342,8 @@ var _NLDDSpacer = class NLDDSpacer extends LitElement {
|
|
|
42081
42342
|
};
|
|
42082
42343
|
var NLDDSpacer = (_NLDDSpacer.styles = spacerStyles, _NLDDSpacer);
|
|
42083
42344
|
__decorate([property({
|
|
42084
|
-
|
|
42085
|
-
|
|
42345
|
+
reflect: true,
|
|
42346
|
+
converter: reflectNonDefault("16")
|
|
42086
42347
|
})], NLDDSpacer.prototype, "size", void 0);
|
|
42087
42348
|
__decorate([property({
|
|
42088
42349
|
type: String,
|
|
@@ -42757,8 +43018,8 @@ __decorate([property({ type: String })], NLDDTimePicker.prototype, "min", void 0
|
|
|
42757
43018
|
__decorate([property({ type: String })], NLDDTimePicker.prototype, "max", void 0);
|
|
42758
43019
|
__decorate([property({ type: Number })], NLDDTimePicker.prototype, "step", void 0);
|
|
42759
43020
|
__decorate([property({
|
|
42760
|
-
|
|
42761
|
-
|
|
43021
|
+
reflect: true,
|
|
43022
|
+
converter: reflectNonDefault(7)
|
|
42762
43023
|
})], NLDDTimePicker.prototype, "rows", void 0);
|
|
42763
43024
|
__decorate([property({
|
|
42764
43025
|
reflect: true,
|
|
@@ -43751,15 +44012,13 @@ function toggleButtonTemplate(component) {
|
|
|
43751
44012
|
const name = component.accessibleLabel || ((component.variant === "icon" || shortcutWords) && component.text ? component.text : "");
|
|
43752
44013
|
const ariaLabel = name ? [name, shortcutWords].filter(Boolean).join(" ") : nothing;
|
|
43753
44014
|
const tooltipText = (showIcon || component.variant === "icon") && !showText ? component.accessibleLabel || component.text || "" : "";
|
|
43754
|
-
const
|
|
43755
|
-
const icon =
|
|
43756
|
-
|
|
43757
|
-
|
|
43758
|
-
|
|
43759
|
-
|
|
43760
|
-
|
|
43761
|
-
icon="icon-placeholder"
|
|
43762
|
-
></nldd-icon>` : nothing}</slot>`;
|
|
44015
|
+
const fallbackIcon = (component.selected && component.selectedIcon ? component.selectedIcon : component.icon) || (showPlaceholder ? "icon-placeholder" : "");
|
|
44016
|
+
const icon = html`<slot
|
|
44017
|
+
name="icon"
|
|
44018
|
+
@slotchange=${component.requestUpdate}
|
|
44019
|
+
>${fallbackIcon ? html`<nldd-icon class="toggle-button__icon"
|
|
44020
|
+
icon=${fallbackIcon}
|
|
44021
|
+
></nldd-icon>` : nothing}</slot>`;
|
|
43763
44022
|
const textContent = showText ? html`<span class="toggle-button__text">${component.text}</span>` : nothing;
|
|
43764
44023
|
let result;
|
|
43765
44024
|
if (component.type === "radio") result = html`
|
|
@@ -43857,7 +44116,7 @@ function toggleButtonTemplate(component) {
|
|
|
43857
44116
|
* @attr {boolean} required - Required state. Set by nldd-toggle-button-group.
|
|
43858
44117
|
* @attr {boolean} invalid - Marks the control as invalid. Announced with aria-invalid; nothing is drawn for it.
|
|
43859
44118
|
*
|
|
43860
|
-
* @slot icon - Slot for a custom icon (e.g. custom SVG).
|
|
44119
|
+
* @slot icon - Slot for a custom icon (e.g. custom SVG). Wins over `icon` and `selected-icon`.
|
|
43861
44120
|
*
|
|
43862
44121
|
* @fires change - When selection changes; detail: { selected: boolean, value: string }
|
|
43863
44122
|
*/
|
|
@@ -44055,8 +44314,8 @@ __decorate([property({
|
|
|
44055
44314
|
reflect: true
|
|
44056
44315
|
})], NLDDToggleButton.prototype, "required", void 0);
|
|
44057
44316
|
__decorate([property({
|
|
44058
|
-
|
|
44059
|
-
|
|
44317
|
+
reflect: true,
|
|
44318
|
+
converter: reflectNonDefault("button")
|
|
44060
44319
|
})], NLDDToggleButton.prototype, "type", void 0);
|
|
44061
44320
|
__decorate([property({
|
|
44062
44321
|
reflect: true,
|
|
@@ -44138,9 +44397,9 @@ var toggleButtonGroupStyles = css`
|
|
|
44138
44397
|
/* # Host */
|
|
44139
44398
|
|
|
44140
44399
|
:host {
|
|
44141
|
-
--_toggle-button-group-md-gap: var(--
|
|
44142
|
-
--_toggle-button-group-sm-gap: var(--
|
|
44143
|
-
--_toggle-button-group-xs-gap: var(--
|
|
44400
|
+
--_toggle-button-group-md-gap: var(--semantics-button-groups-md-gap);
|
|
44401
|
+
--_toggle-button-group-sm-gap: var(--semantics-button-groups-sm-gap);
|
|
44402
|
+
--_toggle-button-group-xs-gap: var(--semantics-button-groups-xs-gap);
|
|
44144
44403
|
|
|
44145
44404
|
display: block;
|
|
44146
44405
|
isolation: isolate;
|
|
@@ -44350,8 +44609,8 @@ __decorate([property({
|
|
|
44350
44609
|
reflect: true
|
|
44351
44610
|
})], NLDDToggleButtonGroup.prototype, "required", void 0);
|
|
44352
44611
|
__decorate([property({
|
|
44353
|
-
|
|
44354
|
-
|
|
44612
|
+
reflect: true,
|
|
44613
|
+
converter: reflectNonDefault("checkbox")
|
|
44355
44614
|
})], NLDDToggleButtonGroup.prototype, "type", void 0);
|
|
44356
44615
|
__decorate([property({ type: String })], NLDDToggleButtonGroup.prototype, "name", void 0);
|
|
44357
44616
|
__decorate([property({
|
|
@@ -47098,8 +47357,8 @@ var _NLDDBarSplitView = class NLDDBarSplitView extends LitElement {
|
|
|
47098
47357
|
};
|
|
47099
47358
|
var NLDDBarSplitView = (_NLDDBarSplitView.styles = barSplitViewStyles, _NLDDBarSplitView);
|
|
47100
47359
|
__decorate([property({
|
|
47101
|
-
|
|
47102
|
-
|
|
47360
|
+
reflect: true,
|
|
47361
|
+
converter: reflectNonDefault("inherit")
|
|
47103
47362
|
})], NLDDBarSplitView.prototype, "background", void 0);
|
|
47104
47363
|
__decorate([state()], NLDDBarSplitView.prototype, "_currentBreakpoint", void 0);
|
|
47105
47364
|
NLDDBarSplitView = __decorate([customElement("nldd-bar-split-view")], NLDDBarSplitView);
|
|
@@ -48110,12 +48369,12 @@ var _NLDDSideBySideSplitView = class NLDDSideBySideSplitView extends LitElement
|
|
|
48110
48369
|
};
|
|
48111
48370
|
var NLDDSideBySideSplitView = (_NLDDSideBySideSplitView.styles = sideBySideSplitViewStyles, _NLDDSideBySideSplitView);
|
|
48112
48371
|
__decorate([property({
|
|
48113
|
-
|
|
48114
|
-
|
|
48372
|
+
reflect: true,
|
|
48373
|
+
converter: reflectNonDefault("inherit")
|
|
48115
48374
|
})], NLDDSideBySideSplitView.prototype, "background", void 0);
|
|
48116
48375
|
__decorate([property({
|
|
48117
|
-
|
|
48118
|
-
|
|
48376
|
+
reflect: true,
|
|
48377
|
+
converter: reflectNonDefault(2)
|
|
48119
48378
|
})], NLDDSideBySideSplitView.prototype, "panes", void 0);
|
|
48120
48379
|
__decorate([state()], NLDDSideBySideSplitView.prototype, "_visiblePanes", void 0);
|
|
48121
48380
|
NLDDSideBySideSplitView = __decorate([customElement("nldd-side-by-side-split-view")], NLDDSideBySideSplitView);
|
|
@@ -48293,12 +48552,12 @@ var _NLDDStackedSplitView = class NLDDStackedSplitView extends LitElement {
|
|
|
48293
48552
|
};
|
|
48294
48553
|
var NLDDStackedSplitView = (_NLDDStackedSplitView.styles = stackedSplitViewStyles, _NLDDStackedSplitView);
|
|
48295
48554
|
__decorate([property({
|
|
48296
|
-
|
|
48297
|
-
|
|
48555
|
+
reflect: true,
|
|
48556
|
+
converter: reflectNonDefault("inherit")
|
|
48298
48557
|
})], NLDDStackedSplitView.prototype, "background", void 0);
|
|
48299
48558
|
__decorate([property({
|
|
48300
|
-
|
|
48301
|
-
|
|
48559
|
+
reflect: true,
|
|
48560
|
+
converter: reflectNonDefault(2)
|
|
48302
48561
|
})], NLDDStackedSplitView.prototype, "panes", void 0);
|
|
48303
48562
|
__decorate([state()], NLDDStackedSplitView.prototype, "_visiblePanes", void 0);
|
|
48304
48563
|
NLDDStackedSplitView = __decorate([customElement("nldd-stacked-split-view")], NLDDStackedSplitView);
|
|
@@ -48453,8 +48712,8 @@ var _NLDDSplitViewPane = class NLDDSplitViewPane extends LitElement {
|
|
|
48453
48712
|
};
|
|
48454
48713
|
var NLDDSplitViewPane = (_NLDDSplitViewPane.styles = splitViewPaneStyles, _NLDDSplitViewPane);
|
|
48455
48714
|
__decorate([property({
|
|
48456
|
-
|
|
48457
|
-
|
|
48715
|
+
reflect: true,
|
|
48716
|
+
converter: reflectNonDefault("inherit")
|
|
48458
48717
|
})], NLDDSplitViewPane.prototype, "background", void 0);
|
|
48459
48718
|
__decorate([property({
|
|
48460
48719
|
type: Boolean,
|
|
@@ -48468,11 +48727,30 @@ __decorate([property({
|
|
|
48468
48727
|
})], NLDDSplitViewPane.prototype, "hasContent", void 0);
|
|
48469
48728
|
NLDDSplitViewPane = __decorate([customElement("nldd-split-view-pane")], NLDDSplitViewPane);
|
|
48470
48729
|
// src/utilities/page-section-mixin.ts
|
|
48471
|
-
|
|
48472
|
-
|
|
48473
|
-
|
|
48474
|
-
|
|
48475
|
-
|
|
48730
|
+
/**
|
|
48731
|
+
* The surface a `background` paints, and passes on through
|
|
48732
|
+
* `--context-parent-background-color` so cards and nested sections read the
|
|
48733
|
+
* same surface. Every section puts this first in its `styles`.
|
|
48734
|
+
*/
|
|
48735
|
+
var pageSectionBackgroundStyles = css`
|
|
48736
|
+
:host([background="base"]) {
|
|
48737
|
+
--context-parent-background-color: var(--semantics-surfaces-base-background-color);
|
|
48738
|
+
}
|
|
48739
|
+
|
|
48740
|
+
:host([background="tinted"]) {
|
|
48741
|
+
--context-parent-background-color: var(--semantics-surfaces-tinted-background-color);
|
|
48742
|
+
}
|
|
48743
|
+
|
|
48744
|
+
:host([background="accent-tinted"]) {
|
|
48745
|
+
--context-parent-background-color: var(--semantics-surfaces-accent-tinted-background-color);
|
|
48746
|
+
}
|
|
48747
|
+
|
|
48748
|
+
:host([background="base"]),
|
|
48749
|
+
:host([background="tinted"]),
|
|
48750
|
+
:host([background="accent-tinted"]) {
|
|
48751
|
+
background-color: var(--context-parent-background-color);
|
|
48752
|
+
}
|
|
48753
|
+
`;
|
|
48476
48754
|
function paddingToValue(size) {
|
|
48477
48755
|
if (size === void 0 || size === "") return null;
|
|
48478
48756
|
if (size === "0") return "0";
|
|
@@ -48500,10 +48778,10 @@ var PADDING_KEYS = [
|
|
|
48500
48778
|
];
|
|
48501
48779
|
/**
|
|
48502
48780
|
* Shared surface controls for the page-section components. Adds three
|
|
48503
|
-
* orthogonal capabilities
|
|
48504
|
-
* properties
|
|
48505
|
-
*
|
|
48506
|
-
*
|
|
48781
|
+
* orthogonal capabilities. Padding and height are written as custom
|
|
48782
|
+
* properties on the host, which inherit through the shadow boundary into the
|
|
48783
|
+
* section's block element and slotted content; the background comes from
|
|
48784
|
+
* `pageSectionBackgroundStyles`:
|
|
48507
48785
|
*
|
|
48508
48786
|
* - **background**: `inherit` (the default — transparent, shows the ancestor's
|
|
48509
48787
|
* surface) | `base` (the base surface color) | `tinted` | `accent-tinted`
|
|
@@ -48538,7 +48816,6 @@ function PageSectionMixin(Base) {
|
|
|
48538
48816
|
}
|
|
48539
48817
|
updated(changed) {
|
|
48540
48818
|
super.updated(changed);
|
|
48541
|
-
if (changed.has("background")) this._applyBackground();
|
|
48542
48819
|
if (PADDING_KEYS.some((k) => changed.has(k))) this._applyPadding();
|
|
48543
48820
|
if (changed.has("height")) this._applyHeight();
|
|
48544
48821
|
}
|
|
@@ -48548,16 +48825,6 @@ function PageSectionMixin(Base) {
|
|
|
48548
48825
|
if (!wrapper) return;
|
|
48549
48826
|
wrapper.hidden = slot.assignedElements().length === 0;
|
|
48550
48827
|
}
|
|
48551
|
-
_applyBackground() {
|
|
48552
|
-
const token = this.background === "inherit" ? void 0 : BACKGROUND_TOKEN[this.background];
|
|
48553
|
-
if (token) {
|
|
48554
|
-
this.style.backgroundColor = token;
|
|
48555
|
-
this.style.setProperty("--context-parent-background-color", token);
|
|
48556
|
-
} else {
|
|
48557
|
-
this.style.backgroundColor = "";
|
|
48558
|
-
this.style.removeProperty("--context-parent-background-color");
|
|
48559
|
-
}
|
|
48560
|
-
}
|
|
48561
48828
|
_applyPadding() {
|
|
48562
48829
|
const self = this;
|
|
48563
48830
|
for (const scope of PADDING_SCOPES) {
|
|
@@ -48869,7 +49136,7 @@ var _NLDDSimpleSection = class NLDDSimpleSection extends PageSectionMixin(LitEle
|
|
|
48869
49136
|
return simpleSectionTemplate(this);
|
|
48870
49137
|
}
|
|
48871
49138
|
};
|
|
48872
|
-
var NLDDSimpleSection = (_NLDDSimpleSection.styles = simpleSectionStyles, _NLDDSimpleSection);
|
|
49139
|
+
var NLDDSimpleSection = (_NLDDSimpleSection.styles = [pageSectionBackgroundStyles, simpleSectionStyles], _NLDDSimpleSection);
|
|
48873
49140
|
__decorate([property({
|
|
48874
49141
|
reflect: true,
|
|
48875
49142
|
converter: reflectNonDefault("")
|
|
@@ -49763,7 +50030,11 @@ var NLDDHero = (_NLDDHero = class NLDDHero extends PageSectionMixin(LitElement)
|
|
|
49763
50030
|
render() {
|
|
49764
50031
|
return heroTemplate(this);
|
|
49765
50032
|
}
|
|
49766
|
-
}, _NLDDHero.styles = [
|
|
50033
|
+
}, _NLDDHero.styles = [
|
|
50034
|
+
pageSectionBackgroundStyles,
|
|
50035
|
+
heroStyles,
|
|
50036
|
+
heroCornerStyles
|
|
50037
|
+
], _NLDDHero);
|
|
49767
50038
|
__decorate([property({
|
|
49768
50039
|
reflect: true,
|
|
49769
50040
|
converter: reflectNonDefault("")
|
|
@@ -50003,7 +50274,7 @@ var _NLDDFullBleedSection = class NLDDFullBleedSection extends PageSectionMixin(
|
|
|
50003
50274
|
return fullBleedSectionTemplate(this);
|
|
50004
50275
|
}
|
|
50005
50276
|
};
|
|
50006
|
-
var NLDDFullBleedSection = (_NLDDFullBleedSection.styles = fullBleedSectionStyles, _NLDDFullBleedSection);
|
|
50277
|
+
var NLDDFullBleedSection = (_NLDDFullBleedSection.styles = [pageSectionBackgroundStyles, fullBleedSectionStyles], _NLDDFullBleedSection);
|
|
50007
50278
|
__decorate([property({
|
|
50008
50279
|
reflect: true,
|
|
50009
50280
|
converter: reflectNonDefault("")
|
|
@@ -50241,7 +50512,7 @@ var _NLDDOneThirdTwoThirdsSection = class NLDDOneThirdTwoThirdsSection extends P
|
|
|
50241
50512
|
return oneThirdTwoThirdsSectionTemplate(this);
|
|
50242
50513
|
}
|
|
50243
50514
|
};
|
|
50244
|
-
var NLDDOneThirdTwoThirdsSection = (_NLDDOneThirdTwoThirdsSection.styles = oneThirdTwoThirdsSectionStyles, _NLDDOneThirdTwoThirdsSection);
|
|
50515
|
+
var NLDDOneThirdTwoThirdsSection = (_NLDDOneThirdTwoThirdsSection.styles = [pageSectionBackgroundStyles, oneThirdTwoThirdsSectionStyles], _NLDDOneThirdTwoThirdsSection);
|
|
50245
50516
|
__decorate([property({
|
|
50246
50517
|
reflect: true,
|
|
50247
50518
|
converter: reflectNonDefault("")
|
|
@@ -50484,7 +50755,7 @@ var _NLDDTwoThirdsOneThirdSection = class NLDDTwoThirdsOneThirdSection extends P
|
|
|
50484
50755
|
return twoThirdsOneThirdSectionTemplate(this);
|
|
50485
50756
|
}
|
|
50486
50757
|
};
|
|
50487
|
-
var NLDDTwoThirdsOneThirdSection = (_NLDDTwoThirdsOneThirdSection.styles = twoThirdsOneThirdSectionStyles, _NLDDTwoThirdsOneThirdSection);
|
|
50758
|
+
var NLDDTwoThirdsOneThirdSection = (_NLDDTwoThirdsOneThirdSection.styles = [pageSectionBackgroundStyles, twoThirdsOneThirdSectionStyles], _NLDDTwoThirdsOneThirdSection);
|
|
50488
50759
|
__decorate([property({
|
|
50489
50760
|
reflect: true,
|
|
50490
50761
|
converter: reflectNonDefault("")
|
|
@@ -50727,7 +50998,7 @@ var _NLDDOneHalfOneHalfSection = class NLDDOneHalfOneHalfSection extends PageSec
|
|
|
50727
50998
|
return oneHalfOneHalfSectionTemplate(this);
|
|
50728
50999
|
}
|
|
50729
51000
|
};
|
|
50730
|
-
var NLDDOneHalfOneHalfSection = (_NLDDOneHalfOneHalfSection.styles = oneHalfOneHalfSectionStyles, _NLDDOneHalfOneHalfSection);
|
|
51001
|
+
var NLDDOneHalfOneHalfSection = (_NLDDOneHalfOneHalfSection.styles = [pageSectionBackgroundStyles, oneHalfOneHalfSectionStyles], _NLDDOneHalfOneHalfSection);
|
|
50731
51002
|
__decorate([property({
|
|
50732
51003
|
reflect: true,
|
|
50733
51004
|
converter: reflectNonDefault("")
|
|
@@ -51382,6 +51653,7 @@ var NLDDSheet = (_NLDDSheet = class NLDDSheet extends LitElement {
|
|
|
51382
51653
|
this._pointerDownOnBackdrop = false;
|
|
51383
51654
|
this._pointerUpOnBackdrop = false;
|
|
51384
51655
|
this._closeEmitted = false;
|
|
51656
|
+
this._focusReturn = new FocusReturn();
|
|
51385
51657
|
this._handleDismiss = (e) => {
|
|
51386
51658
|
if (isDismissFromTitleBar(e)) {
|
|
51387
51659
|
e.stopPropagation();
|
|
@@ -51439,7 +51711,10 @@ var NLDDSheet = (_NLDDSheet = class NLDDSheet extends LitElement {
|
|
|
51439
51711
|
window.clearTimeout(this._closeFallback);
|
|
51440
51712
|
this._closing = false;
|
|
51441
51713
|
dialog.classList.remove("is-closing");
|
|
51442
|
-
} else
|
|
51714
|
+
} else {
|
|
51715
|
+
this._focusReturn.remember();
|
|
51716
|
+
dialog.showModal();
|
|
51717
|
+
}
|
|
51443
51718
|
this.open = true;
|
|
51444
51719
|
this._manageFocus();
|
|
51445
51720
|
this.dispatchEvent(new CustomEvent("open", {
|
|
@@ -51496,6 +51771,7 @@ var NLDDSheet = (_NLDDSheet = class NLDDSheet extends LitElement {
|
|
|
51496
51771
|
bubbles: false,
|
|
51497
51772
|
composed: true
|
|
51498
51773
|
}));
|
|
51774
|
+
this._focusReturn.restore(this);
|
|
51499
51775
|
}
|
|
51500
51776
|
_handleDialogClose(e) {
|
|
51501
51777
|
if (e.target !== this._dialog) return;
|
|
@@ -51516,8 +51792,8 @@ __decorate([property({
|
|
|
51516
51792
|
converter: reflectNonDefault("")
|
|
51517
51793
|
})], NLDDSheet.prototype, "width", void 0);
|
|
51518
51794
|
__decorate([property({
|
|
51519
|
-
|
|
51520
|
-
|
|
51795
|
+
reflect: true,
|
|
51796
|
+
converter: reflectNonDefault("")
|
|
51521
51797
|
})], NLDDSheet.prototype, "height", void 0);
|
|
51522
51798
|
__decorate([property({
|
|
51523
51799
|
reflect: true,
|
|
@@ -51788,7 +52064,7 @@ var _NLDDSidebarSection = class NLDDSidebarSection extends PageSectionMixin(LitE
|
|
|
51788
52064
|
return sidebarSectionTemplate(this);
|
|
51789
52065
|
}
|
|
51790
52066
|
};
|
|
51791
|
-
var NLDDSidebarSection = (_NLDDSidebarSection.styles = sidebarSectionStyles, _NLDDSidebarSection);
|
|
52067
|
+
var NLDDSidebarSection = (_NLDDSidebarSection.styles = [pageSectionBackgroundStyles, sidebarSectionStyles], _NLDDSidebarSection);
|
|
51792
52068
|
__decorate([property({
|
|
51793
52069
|
reflect: true,
|
|
51794
52070
|
converter: reflectNonDefault("")
|
|
@@ -51804,14 +52080,14 @@ __decorate([property({
|
|
|
51804
52080
|
attribute: "no-collapse"
|
|
51805
52081
|
})], NLDDSidebarSection.prototype, "noCollapse", void 0);
|
|
51806
52082
|
__decorate([property({
|
|
51807
|
-
type: String,
|
|
51808
52083
|
reflect: true,
|
|
51809
|
-
attribute: "sticky-top"
|
|
52084
|
+
attribute: "sticky-top",
|
|
52085
|
+
converter: reflectNonDefault("")
|
|
51810
52086
|
})], NLDDSidebarSection.prototype, "stickyTop", void 0);
|
|
51811
52087
|
__decorate([property({
|
|
51812
|
-
type: String,
|
|
51813
52088
|
reflect: true,
|
|
51814
|
-
attribute: "sticky-bottom"
|
|
52089
|
+
attribute: "sticky-bottom",
|
|
52090
|
+
converter: reflectNonDefault("")
|
|
51815
52091
|
})], NLDDSidebarSection.prototype, "stickyBottom", void 0);
|
|
51816
52092
|
__decorate([property({
|
|
51817
52093
|
type: Boolean,
|
|
@@ -52019,10 +52295,12 @@ var cardStyles = css`
|
|
|
52019
52295
|
|
|
52020
52296
|
/* # Link / button overlay */
|
|
52021
52297
|
|
|
52298
|
+
/* z-index 1, not 0: content that is only position: relative, such as an
|
|
52299
|
+
nldd-image, would otherwise paint over the overlay and take its clicks. */
|
|
52022
52300
|
.card__action {
|
|
52023
52301
|
position: absolute;
|
|
52024
52302
|
inset: 0;
|
|
52025
|
-
z-index:
|
|
52303
|
+
z-index: 1;
|
|
52026
52304
|
border-radius: inherit;
|
|
52027
52305
|
}
|
|
52028
52306
|
|
|
@@ -52241,8 +52519,8 @@ __decorate([property({
|
|
|
52241
52519
|
attribute: "accessible-label"
|
|
52242
52520
|
})], NLDDCard.prototype, "accessibleLabel", void 0);
|
|
52243
52521
|
__decorate([property({
|
|
52244
|
-
|
|
52245
|
-
|
|
52522
|
+
reflect: true,
|
|
52523
|
+
converter: reflectNonDefault("")
|
|
52246
52524
|
})], NLDDCard.prototype, "href", void 0);
|
|
52247
52525
|
__decorate([property({ type: String })], NLDDCard.prototype, "target", void 0);
|
|
52248
52526
|
__decorate([property({ type: String })], NLDDCard.prototype, "download", void 0);
|
|
@@ -53011,6 +53289,7 @@ var _NLDDWindow = class NLDDWindow extends LitElement {
|
|
|
53011
53289
|
this._titleBar = new TitleBarLabelController(this);
|
|
53012
53290
|
this._cancelPendingOpen = null;
|
|
53013
53291
|
this._closeEmitted = false;
|
|
53292
|
+
this._focusReturn = new FocusReturn();
|
|
53014
53293
|
this._handleDialogClose = (e) => {
|
|
53015
53294
|
if (e.target !== this._dialog) return;
|
|
53016
53295
|
this._closing = false;
|
|
@@ -53087,6 +53366,7 @@ var _NLDDWindow = class NLDDWindow extends LitElement {
|
|
|
53087
53366
|
this._cancelPendingOpen = null;
|
|
53088
53367
|
this._closeEmitted = false;
|
|
53089
53368
|
setState$1(this, "unnamed", !this.accessibleLabel && !this._titleBar.text);
|
|
53369
|
+
this._focusReturn.remember();
|
|
53090
53370
|
dialog.showModal();
|
|
53091
53371
|
this.open = true;
|
|
53092
53372
|
this._applyPositionStyles();
|
|
@@ -53115,6 +53395,7 @@ var _NLDDWindow = class NLDDWindow extends LitElement {
|
|
|
53115
53395
|
bubbles: false,
|
|
53116
53396
|
composed: true
|
|
53117
53397
|
}));
|
|
53398
|
+
this._focusReturn.restore(this);
|
|
53118
53399
|
}
|
|
53119
53400
|
_manageFocus() {
|
|
53120
53401
|
if (focusAutofocusTarget(this)) return;
|
|
@@ -53156,8 +53437,8 @@ var _NLDDWindow = class NLDDWindow extends LitElement {
|
|
|
53156
53437
|
};
|
|
53157
53438
|
var NLDDWindow = (_NLDDWindow.styles = windowStyles, _NLDDWindow);
|
|
53158
53439
|
__decorate([property({
|
|
53159
|
-
|
|
53160
|
-
|
|
53440
|
+
reflect: true,
|
|
53441
|
+
converter: reflectNonDefault("inherit")
|
|
53161
53442
|
})], NLDDWindow.prototype, "scheme", void 0);
|
|
53162
53443
|
__decorate([property({
|
|
53163
53444
|
type: String,
|
|
@@ -53516,7 +53797,7 @@ function pageFooterLegalBarTemplate(component) {
|
|
|
53516
53797
|
`;
|
|
53517
53798
|
}
|
|
53518
53799
|
function pageFooterLegalBarItemTemplate(component) {
|
|
53519
|
-
const label = component.
|
|
53800
|
+
const label = html`${component._textSlot.has ? nothing : component.text}<slot @slotchange=${component._textSlot.onChange}></slot>`;
|
|
53520
53801
|
if (component.href) return html`
|
|
53521
53802
|
<span class="page-footer__legal-bar-item">
|
|
53522
53803
|
<a class="page-footer__legal-bar-item-link"
|
|
@@ -53561,14 +53842,15 @@ var _NLDDPageFooter;
|
|
|
53561
53842
|
*
|
|
53562
53843
|
* @element nldd-page-footer-legal-bar-item
|
|
53563
53844
|
*
|
|
53564
|
-
* @attr {string} text - Item label.
|
|
53845
|
+
* @attr {string} text - Item label. Content in the default slot wins.
|
|
53565
53846
|
* @attr {string} href - Link target. When omitted, the item renders as plain text.
|
|
53566
53847
|
*
|
|
53567
|
-
* @slot - Item label
|
|
53848
|
+
* @slot - Item label. Wins over `text`.
|
|
53568
53849
|
*/
|
|
53569
53850
|
var NLDDPageFooterLegalBarItem = class extends LitElement {
|
|
53570
53851
|
constructor(..._args) {
|
|
53571
53852
|
super(..._args);
|
|
53853
|
+
this._textSlot = new SlotContent(this);
|
|
53572
53854
|
this.text = "";
|
|
53573
53855
|
}
|
|
53574
53856
|
render() {
|
|
@@ -54830,8 +55112,8 @@ __decorate([property({
|
|
|
54830
55112
|
attribute: "accessible-label"
|
|
54831
55113
|
})], NLDDKanban.prototype, "accessibleLabel", void 0);
|
|
54832
55114
|
__decorate([property({
|
|
54833
|
-
|
|
54834
|
-
|
|
55115
|
+
reflect: true,
|
|
55116
|
+
converter: reflectNonDefault("")
|
|
54835
55117
|
})], NLDDKanban.prototype, "height", void 0);
|
|
54836
55118
|
__decorate([property({
|
|
54837
55119
|
type: Boolean,
|
|
@@ -54950,6 +55232,7 @@ var listItemSegmentStyles = css`
|
|
|
54950
55232
|
:host(:not([disabled])) a.list-item-segment:hover,
|
|
54951
55233
|
button.list-item-segment:not(:disabled):hover {
|
|
54952
55234
|
--_list-item-segment-background-color: var(--context-list-item-hovered-background-color, var(--semantics-list-items-is-hovered-background-color));
|
|
55235
|
+
--context-parent-background-color: var(--_list-item-segment-background-color);
|
|
54953
55236
|
--context-content-color: var(--context-list-item-hovered-content-color, var(--semantics-list-items-is-hovered-content-color));
|
|
54954
55237
|
--context-content-secondary-color: var(--context-list-item-hovered-content-color, var(--semantics-list-items-is-hovered-content-color));
|
|
54955
55238
|
}
|
|
@@ -54963,6 +55246,7 @@ var listItemSegmentStyles = css`
|
|
|
54963
55246
|
button.list-item-segment:not(:disabled).is-pressed,
|
|
54964
55247
|
:host(:not([disabled])) .list-item-segment.is-pressed {
|
|
54965
55248
|
--_list-item-segment-background-color: var(--context-list-item-active-background-color, var(--semantics-list-items-is-active-background-color));
|
|
55249
|
+
--context-parent-background-color: var(--_list-item-segment-background-color);
|
|
54966
55250
|
--context-content-color: var(--context-list-item-active-content-color, var(--context-list-item-hovered-content-color, var(--semantics-list-items-is-active-content-color)));
|
|
54967
55251
|
--context-content-secondary-color: var(--context-list-item-active-content-color, var(--context-list-item-hovered-content-color, var(--semantics-list-items-is-active-content-color)));
|
|
54968
55252
|
}
|
|
@@ -54971,6 +55255,7 @@ var listItemSegmentStyles = css`
|
|
|
54971
55255
|
dim it while what it opened is still on screen. */
|
|
54972
55256
|
:host([expanded]) .list-item-segment {
|
|
54973
55257
|
--_list-item-segment-background-color: var(--semantics-list-items-is-expanded-background-color);
|
|
55258
|
+
--context-parent-background-color: var(--_list-item-segment-background-color);
|
|
54974
55259
|
--context-content-color: var(--semantics-list-items-is-expanded-content-color);
|
|
54975
55260
|
--context-content-secondary-color: var(--semantics-list-items-is-expanded-content-color);
|
|
54976
55261
|
}
|
|
@@ -54979,6 +55264,7 @@ var listItemSegmentStyles = css`
|
|
|
54979
55264
|
:host([expanded]:not([disabled])) a.list-item-segment:hover,
|
|
54980
55265
|
:host([expanded]) button.list-item-segment:not(:disabled):hover {
|
|
54981
55266
|
--_list-item-segment-background-color: var(--semantics-list-items-is-expanded-is-hovered-background-color);
|
|
55267
|
+
--context-parent-background-color: var(--_list-item-segment-background-color);
|
|
54982
55268
|
--context-content-color: var(--semantics-list-items-is-expanded-content-color);
|
|
54983
55269
|
--context-content-secondary-color: var(--semantics-list-items-is-expanded-content-color);
|
|
54984
55270
|
}
|
|
@@ -54988,12 +55274,14 @@ var listItemSegmentStyles = css`
|
|
|
54988
55274
|
:host([expanded]) button.list-item-segment:not(:disabled).is-pressed,
|
|
54989
55275
|
:host([expanded]:not([disabled])) .list-item-segment.is-pressed {
|
|
54990
55276
|
--_list-item-segment-background-color: var(--semantics-list-items-is-expanded-is-active-background-color);
|
|
55277
|
+
--context-parent-background-color: var(--_list-item-segment-background-color);
|
|
54991
55278
|
--context-content-color: var(--semantics-list-items-is-expanded-content-color);
|
|
54992
55279
|
--context-content-secondary-color: var(--semantics-list-items-is-expanded-content-color);
|
|
54993
55280
|
}
|
|
54994
55281
|
|
|
54995
55282
|
:host([checked]) .list-item-segment {
|
|
54996
55283
|
--_list-item-segment-background-color: var(--semantics-list-items-is-selected-background-color);
|
|
55284
|
+
--context-parent-background-color: var(--_list-item-segment-background-color);
|
|
54997
55285
|
--context-content-color: var(--semantics-list-items-is-selected-content-color);
|
|
54998
55286
|
--context-content-secondary-color: var(--semantics-list-items-is-selected-content-color);
|
|
54999
55287
|
}
|
|
@@ -55584,28 +55872,28 @@ __decorate([property({
|
|
|
55584
55872
|
converter: reflectNonDefault("base")
|
|
55585
55873
|
})], NLDDTable.prototype, "background", void 0);
|
|
55586
55874
|
__decorate([property({
|
|
55587
|
-
|
|
55588
|
-
|
|
55875
|
+
reflect: true,
|
|
55876
|
+
converter: reflectNonDefault("")
|
|
55589
55877
|
})], NLDDTable.prototype, "columns", void 0);
|
|
55590
55878
|
__decorate([property({
|
|
55591
|
-
type: String,
|
|
55592
55879
|
reflect: true,
|
|
55593
|
-
attribute: "sm-columns"
|
|
55880
|
+
attribute: "sm-columns",
|
|
55881
|
+
converter: reflectNonDefault("")
|
|
55594
55882
|
})], NLDDTable.prototype, "smColumns", void 0);
|
|
55595
55883
|
__decorate([property({
|
|
55596
|
-
type: String,
|
|
55597
55884
|
reflect: true,
|
|
55598
|
-
attribute: "md-columns"
|
|
55885
|
+
attribute: "md-columns",
|
|
55886
|
+
converter: reflectNonDefault("")
|
|
55599
55887
|
})], NLDDTable.prototype, "mdColumns", void 0);
|
|
55600
55888
|
__decorate([property({
|
|
55601
|
-
type: String,
|
|
55602
55889
|
reflect: true,
|
|
55603
|
-
attribute: "lg-columns"
|
|
55890
|
+
attribute: "lg-columns",
|
|
55891
|
+
converter: reflectNonDefault("")
|
|
55604
55892
|
})], NLDDTable.prototype, "lgColumns", void 0);
|
|
55605
55893
|
__decorate([property({
|
|
55606
|
-
type: String,
|
|
55607
55894
|
reflect: true,
|
|
55608
|
-
attribute: "accessible-label"
|
|
55895
|
+
attribute: "accessible-label",
|
|
55896
|
+
converter: reflectNonDefault("")
|
|
55609
55897
|
})], NLDDTable.prototype, "accessibleLabel", void 0);
|
|
55610
55898
|
__decorate([property({ type: Object })], NLDDTable.prototype, "translations", void 0);
|
|
55611
55899
|
__decorate([property({
|
|
@@ -55961,13 +56249,13 @@ var template$9 = function() {
|
|
|
55961
56249
|
* @attr {'left' | 'center' | 'right'} horizontal-alignment - Horizontal alignment (default: 'left')
|
|
55962
56250
|
* @attr {'top' | 'center' | 'bottom'} vertical-alignment - Vertical alignment (default: 'center')
|
|
55963
56251
|
*
|
|
55964
|
-
* @attr {string} text - Title text content. Supports **bold** syntax for inline bold segments.
|
|
56252
|
+
* @attr {string} text - Title text content. Supports **bold** syntax for inline bold segments. Content in the default slot wins.
|
|
55965
56253
|
* @attr {string} supporting-text - Optional supporting text displayed below the title. Supports **bold**. Falls back to `supporting-text` slot.
|
|
55966
56254
|
* @attr {string} overline - Optional overline text displayed above the title. Supports **bold**. Falls back to `overline` slot.
|
|
55967
56255
|
* @attr {number} heading-level - Heading level for the title element: 1–6 (default: none, renders a <p>)
|
|
55968
56256
|
*
|
|
55969
56257
|
* @slot overline - Rich content for the overline region. Overrides the `overline` attribute when content is assigned.
|
|
55970
|
-
* @slot - (default) Rich content for the title.
|
|
56258
|
+
* @slot - (default) Rich content for the title. Wins over `text`.
|
|
55971
56259
|
* @slot supporting-text - Rich content for the supporting text region. Overrides the `supporting-text` attribute when content is assigned.
|
|
55972
56260
|
*
|
|
55973
56261
|
* ### Query mark
|
|
@@ -56987,7 +57275,7 @@ function breadcrumbsTemplate(component) {
|
|
|
56987
57275
|
`;
|
|
56988
57276
|
}
|
|
56989
57277
|
function breadcrumbsItemTemplate(component) {
|
|
56990
|
-
const label = component.
|
|
57278
|
+
const label = html`${component._textSlot.has ? nothing : component.text}<slot @slotchange=${component._textSlot.onChange}></slot>`;
|
|
56991
57279
|
const separator = html`<span class="breadcrumbs__separator"
|
|
56992
57280
|
aria-hidden="true"
|
|
56993
57281
|
><nldd-icon icon="chevron-right-small"></nldd-icon></span>`;
|
|
@@ -57032,13 +57320,14 @@ var _NLDDBreadcrumbs;
|
|
|
57032
57320
|
*
|
|
57033
57321
|
* @attr {string} href - Link target. Ignored when `current` is set.
|
|
57034
57322
|
* @attr {boolean} current - Marks this item as the current page (renders as plain text + `aria-current="page"`). Typical use is on the last item.
|
|
57035
|
-
* @attr {string} text - Item label.
|
|
57323
|
+
* @attr {string} text - Item label. Content in the default slot wins.
|
|
57036
57324
|
*
|
|
57037
|
-
* @slot - Item label
|
|
57325
|
+
* @slot - Item label. Wins over `text`.
|
|
57038
57326
|
*/
|
|
57039
57327
|
var NLDDBreadcrumbsItem = class extends LitElement {
|
|
57040
57328
|
constructor(..._args) {
|
|
57041
57329
|
super(..._args);
|
|
57330
|
+
this._textSlot = new SlotContent(this);
|
|
57042
57331
|
this.current = false;
|
|
57043
57332
|
this.text = "";
|
|
57044
57333
|
}
|
|
@@ -57629,8 +57918,8 @@ __decorate([property({
|
|
|
57629
57918
|
})], NLDDMenuBarItem.prototype, "currentType", void 0);
|
|
57630
57919
|
__decorate([property({ type: String })], NLDDMenuBarItem.prototype, "href", void 0);
|
|
57631
57920
|
__decorate([property({
|
|
57632
|
-
|
|
57633
|
-
|
|
57921
|
+
reflect: true,
|
|
57922
|
+
converter: reflectNonDefault("")
|
|
57634
57923
|
})], NLDDMenuBarItem.prototype, "icon", void 0);
|
|
57635
57924
|
__decorate([property({
|
|
57636
57925
|
type: Boolean,
|
|
@@ -58100,9 +58389,9 @@ function template$4(helpers) {
|
|
|
58100
58389
|
const renderLinkHint = !!linkHint && !this.accessibleLabel;
|
|
58101
58390
|
const hasStartIcon = !!this.startIcon || this._hasStartSlot;
|
|
58102
58391
|
const hasEndIcon = !!this.endIcon || this._hasEndSlot;
|
|
58103
|
-
const startIcon = this.startIcon ? html`<span class="link__start-icon"><nldd-icon icon=${this.startIcon}></nldd-icon></span>` :
|
|
58104
|
-
const endIcon = this.endIcon ? html`<span class="link__end-icon"><nldd-icon icon=${this.endIcon}></nldd-icon></span>` :
|
|
58105
|
-
const label = html`<span class="link__label">${this.
|
|
58392
|
+
const startIcon = html`<slot name="start-icon" @slotchange=${helpers.handleSlotChange}>${this.startIcon ? html`<span class="link__start-icon"><nldd-icon icon=${this.startIcon}></nldd-icon></span>` : nothing}</slot>`;
|
|
58393
|
+
const endIcon = html`<slot name="end-icon" @slotchange=${helpers.handleSlotChange}>${this.endIcon ? html`<span class="link__end-icon"><nldd-icon icon=${this.endIcon}></nldd-icon></span>` : nothing}</slot>`;
|
|
58394
|
+
const label = html`<span class="link__label">${this._textSlot.has ? nothing : this.text}<slot @slotchange=${this._textSlot.onChange}></slot></span>`;
|
|
58106
58395
|
return html`<a class="link"
|
|
58107
58396
|
href=${this.disabled ? nothing : this.href || nothing}
|
|
58108
58397
|
role=${this.disabled ? "link" : nothing}
|
|
@@ -58140,7 +58429,7 @@ function template$4(helpers) {
|
|
|
58140
58429
|
* @attr {string} download - Saves the file the link points at instead of opening it; only used with href. Without a value the browser takes the name from the URL, with one that is the file name. A browser ignores it for a URL on another origin and opens the file there. Adds a visually hidden "downloadt bestand" for screen readers. Leave `target` off: a download opens no tab.
|
|
58141
58430
|
* @attr {string} rel - Link rel attribute; with target '_blank', 'noopener noreferrer' is added to whatever you set
|
|
58142
58431
|
* @attr {string} size - Text size: 'inherit' (the default) follows the surrounding text and lays the link out inline, so it wraps in running prose. 'xs' | 'sm' | 'md' | 'lg' pin a size and switch to inline-flex, which baseline-aligns a start or end icon with an explicit gap.
|
|
58143
|
-
* @attr {string} text - Link text
|
|
58432
|
+
* @attr {string} text - Link text. Content in the default slot wins.
|
|
58144
58433
|
* @attr {string} start-icon - Icon before the text
|
|
58145
58434
|
* @attr {string} end-icon - Icon after the text
|
|
58146
58435
|
* @attr {string} accessible-label - Accessible label for screen readers
|
|
@@ -58148,13 +58437,14 @@ function template$4(helpers) {
|
|
|
58148
58437
|
* @attr {boolean} no-tab - Takes the control out of the tab order (tabindex="-1"), for a control owned by a roving container (a row of an nldd-list, where the arrow keys move between rows) that manages focus itself. Still mouse- and script-focusable.
|
|
58149
58438
|
* @attr {object} translations - Override translation keys (e.g. the "opent in nieuw tabblad" announcement); unset keys fall back to Dutch.
|
|
58150
58439
|
*
|
|
58151
|
-
* @slot - Link text
|
|
58152
|
-
* @slot start-icon - Custom icon before the text
|
|
58153
|
-
* @slot end-icon - Custom icon after the text
|
|
58440
|
+
* @slot - Link text. Wins over `text`.
|
|
58441
|
+
* @slot start-icon - Custom icon before the text. Wins over `start-icon`.
|
|
58442
|
+
* @slot end-icon - Custom icon after the text. Wins over `end-icon`.
|
|
58154
58443
|
*/
|
|
58155
58444
|
var _NLDDLink = class NLDDLink extends withTranslations(LitElement, nlddLinkTranslations) {
|
|
58156
58445
|
constructor(..._args) {
|
|
58157
58446
|
super(..._args);
|
|
58447
|
+
this._textSlot = new SlotContent(this);
|
|
58158
58448
|
this.href = void 0;
|
|
58159
58449
|
this.target = void 0;
|
|
58160
58450
|
this.download = void 0;
|
|
@@ -59222,7 +59512,9 @@ var TopNavigationMenuSheet = class {
|
|
|
59222
59512
|
this._host = _host;
|
|
59223
59513
|
this.list = null;
|
|
59224
59514
|
this.titleBar = null;
|
|
59515
|
+
this.title = null;
|
|
59225
59516
|
this._sheet = null;
|
|
59517
|
+
this._page = null;
|
|
59226
59518
|
this._stack = [];
|
|
59227
59519
|
this._back = () => {
|
|
59228
59520
|
if (this._stack.length <= 1) return;
|
|
@@ -59276,6 +59568,8 @@ var TopNavigationMenuSheet = class {
|
|
|
59276
59568
|
this._sheet = null;
|
|
59277
59569
|
this.list = null;
|
|
59278
59570
|
this.titleBar = null;
|
|
59571
|
+
this.title = null;
|
|
59572
|
+
this._page = null;
|
|
59279
59573
|
this._stack = [];
|
|
59280
59574
|
}
|
|
59281
59575
|
_create() {
|
|
@@ -59290,7 +59584,14 @@ var TopNavigationMenuSheet = class {
|
|
|
59290
59584
|
titleBar.addEventListener("back", this._back);
|
|
59291
59585
|
this.titleBar = titleBar;
|
|
59292
59586
|
page.appendChild(titleBar);
|
|
59587
|
+
const title = document.createElement("nldd-title");
|
|
59588
|
+
title.id = `nldd-menu-sheet-title-${++sheetCount}`;
|
|
59589
|
+
title.setAttribute("slot", "header");
|
|
59590
|
+
title.setAttribute("size", "2");
|
|
59591
|
+
titleBar.setAttribute("collapse-anchor", title.id);
|
|
59592
|
+
this.title = title;
|
|
59293
59593
|
const section = document.createElement("nldd-simple-section");
|
|
59594
|
+
section.appendChild(title);
|
|
59294
59595
|
const list = document.createElement("nldd-list");
|
|
59295
59596
|
list.setAttribute("type", "navigation");
|
|
59296
59597
|
list.setAttribute("appearance", "simple");
|
|
@@ -59298,6 +59599,7 @@ var TopNavigationMenuSheet = class {
|
|
|
59298
59599
|
this.list = list;
|
|
59299
59600
|
section.appendChild(list);
|
|
59300
59601
|
page.appendChild(section);
|
|
59602
|
+
this._page = page;
|
|
59301
59603
|
sheet.appendChild(page);
|
|
59302
59604
|
document.body.appendChild(sheet);
|
|
59303
59605
|
return sheet;
|
|
@@ -59306,12 +59608,15 @@ var TopNavigationMenuSheet = class {
|
|
|
59306
59608
|
* rows. With `moveFocus` after a step down or back, focus lands on the row
|
|
59307
59609
|
* that opened the level going back, else on the first row. */
|
|
59308
59610
|
_render(moveFocus = false, focusOpenerText) {
|
|
59309
|
-
const { list, titleBar } = this;
|
|
59310
|
-
if (!list || !titleBar || this._stack.length === 0) return;
|
|
59611
|
+
const { list, titleBar, title } = this;
|
|
59612
|
+
if (!list || !titleBar || !title || this._stack.length === 0) return;
|
|
59311
59613
|
const depth = this._stack.length;
|
|
59312
59614
|
const level = this._stack[depth - 1];
|
|
59313
59615
|
list.setAttribute("aria-label", this._host._globalMenuBar?.getAttribute("accessible-label") || this._host._t("components.top-navigation-bar.global-menu-bar-label"));
|
|
59314
59616
|
titleBar.setAttribute("text", level.title);
|
|
59617
|
+
title.setAttribute("text", level.title);
|
|
59618
|
+
const scroller = this._page?.scrollTarget;
|
|
59619
|
+
if (scroller && scroller !== document.scrollingElement) scroller.scrollTop = 0;
|
|
59315
59620
|
if (depth > 1) titleBar.setAttribute("back-text", this._stack[depth - 2].title);
|
|
59316
59621
|
else titleBar.removeAttribute("back-text");
|
|
59317
59622
|
list.replaceChildren();
|
|
@@ -59355,17 +59660,20 @@ var TopNavigationMenuSheet = class {
|
|
|
59355
59660
|
});
|
|
59356
59661
|
}
|
|
59357
59662
|
};
|
|
59663
|
+
/** Numbers the title of each bar's sheet, so two bars never share an id. */
|
|
59664
|
+
var sheetCount = 0;
|
|
59358
59665
|
async function loadDependencies() {
|
|
59359
59666
|
await Promise.all([
|
|
59360
59667
|
Promise.resolve().then(() => sheet_exports),
|
|
59361
59668
|
Promise.resolve().then(() => page_exports),
|
|
59362
59669
|
Promise.resolve().then(() => simple_section_exports),
|
|
59363
59670
|
Promise.resolve().then(() => top_title_bar_exports),
|
|
59671
|
+
Promise.resolve().then(() => title_exports),
|
|
59364
59672
|
Promise.resolve().then(() => list_exports),
|
|
59365
59673
|
Promise.resolve().then(() => list_item_exports),
|
|
59366
59674
|
Promise.resolve().then(() => text_cell_exports),
|
|
59367
59675
|
Promise.resolve().then(() => icon_cell_exports),
|
|
59368
|
-
import("./icon-
|
|
59676
|
+
import("./icon-_Eox7ZfO.js").then((n) => n.n)
|
|
59369
59677
|
]);
|
|
59370
59678
|
}
|
|
59371
59679
|
/** The rows of a level, read from its container: the global menu bar's items
|
|
@@ -59479,7 +59787,7 @@ var NLDDTopNavigationBar = (_NLDDTopNavigationBar = class NLDDTopNavigationBar e
|
|
|
59479
59787
|
if (!selectEvent.defaultPrevented) {
|
|
59480
59788
|
detail.item.current = true;
|
|
59481
59789
|
globalItems.forEach((item) => {
|
|
59482
|
-
if (item !== detail.item) item.
|
|
59790
|
+
if (item !== detail.item) item.current = false;
|
|
59483
59791
|
});
|
|
59484
59792
|
}
|
|
59485
59793
|
};
|
|
@@ -59658,8 +59966,8 @@ __decorate([property({
|
|
|
59658
59966
|
reflect: true
|
|
59659
59967
|
})], NLDDTopNavigationBar.prototype, "noLogo", void 0);
|
|
59660
59968
|
__decorate([property({
|
|
59661
|
-
|
|
59662
|
-
|
|
59969
|
+
reflect: true,
|
|
59970
|
+
converter: reflectNonDefault("")
|
|
59663
59971
|
})], NLDDTopNavigationBar.prototype, "width", void 0);
|
|
59664
59972
|
__decorate([property({
|
|
59665
59973
|
reflect: true,
|
|
@@ -60075,6 +60383,9 @@ function tabBarTemplate(component) {
|
|
|
60075
60383
|
<nldd-menu
|
|
60076
60384
|
slot="popup"
|
|
60077
60385
|
placement="bottom-end"
|
|
60386
|
+
@beforetoggle=${(event) => {
|
|
60387
|
+
if (event.newState === "open") component.requestUpdate();
|
|
60388
|
+
}}
|
|
60078
60389
|
>
|
|
60079
60390
|
${component._overflowItems.map((item) => html`
|
|
60080
60391
|
<nldd-menu-item
|
|
@@ -60082,7 +60393,7 @@ function tabBarTemplate(component) {
|
|
|
60082
60393
|
icon=${item.icon || nothing}
|
|
60083
60394
|
href=${sanitizeUrl(item.href) || nothing}
|
|
60084
60395
|
@select=${(event) => component._selectFromOverflow(event, item)}
|
|
60085
|
-
|
|
60396
|
+
>${item._slottedIcon?.cloneNode(true) ?? nothing}</nldd-menu-item>
|
|
60086
60397
|
`)}
|
|
60087
60398
|
</nldd-menu>
|
|
60088
60399
|
</nldd-icon-button>
|
|
@@ -60115,7 +60426,7 @@ function tabBarItemTemplate(component) {
|
|
|
60115
60426
|
<span class="tab-bar__item-icon"
|
|
60116
60427
|
aria-hidden="true"
|
|
60117
60428
|
>
|
|
60118
|
-
|
|
60429
|
+
<slot name="icon" @slotchange=${component._onIconSlotChange}>${component.icon ? html`<nldd-icon icon=${component.icon}></nldd-icon>` : showPlaceholder ? html`<nldd-icon icon="icon-placeholder"></nldd-icon>` : nothing}</slot>
|
|
60119
60430
|
</span>
|
|
60120
60431
|
<span class="tab-bar__item-text">
|
|
60121
60432
|
${component.text}
|
|
@@ -60188,10 +60499,12 @@ function tabBarItemTemplate(component) {
|
|
|
60188
60499
|
* @attr {string} text - Tab text; also used as accessible name for icon-only items
|
|
60189
60500
|
* @attr {string} href - Optional link URL; renders an anchor instead of a button
|
|
60190
60501
|
* @attr {'icon-and-text'|'text'|'icon'} variant - Forces this presentation on this item, over the one from nldd-tab-bar
|
|
60191
|
-
* @attr {string} icon - Icon name for nldd-icon; an
|
|
60502
|
+
* @attr {string} icon - Icon name for nldd-icon; an icon in the icon slot wins. The icon and icon-and-text variants fall back to a placeholder icon when neither is provided.
|
|
60192
60503
|
* @attr {'md'|'lg'} size - Size: 'md' (default) | 'lg'. Set by nldd-tab-bar from its own size; 'lg' enlarges the touch target while keeping the variant layout.
|
|
60504
|
+
* @attr {string} controls - Id of the element this tab shows, looked up in the tab's own tree. The tab announces it as the content it controls (`aria-controls`). Give that element `role="tabpanel"` and an `aria-labelledby` with the id of this item, which names it after the tab. No effect in a `navigation` bar.
|
|
60505
|
+
* @prop {Element | null} controlsElement - The element this tab shows, for where an id does not reach: content in another shadow root, or content a framework renders after the tab (`controls` is looked up when the page loads and on every update of the tab, such as when it becomes current). Wins over `controls`. Browsers without element references (`ariaControlsElements`) get no relation.
|
|
60193
60506
|
*
|
|
60194
|
-
* @slot icon - Icon content
|
|
60507
|
+
* @slot icon - Icon content, such as an `<img>`. Wins over `icon`. The overflow menu shows a copy, made again each time the menu opens, so a new `src` shows there too.
|
|
60195
60508
|
*
|
|
60196
60509
|
* @fires select - When the item is activated; detail: { item: NLDDTabBarItem }
|
|
60197
60510
|
*/
|
|
@@ -60204,11 +60517,14 @@ var _NLDDTabBarItem = class NLDDTabBarItem extends LitElement {
|
|
|
60204
60517
|
this._authorVariant = "";
|
|
60205
60518
|
this.text = "";
|
|
60206
60519
|
this.icon = "";
|
|
60520
|
+
this.controls = "";
|
|
60521
|
+
this.controlsElement = null;
|
|
60207
60522
|
this.size = "md";
|
|
60208
60523
|
this._hasIconSlot = false;
|
|
60209
60524
|
this._navigation = false;
|
|
60210
60525
|
this._isFallbackFocusable = false;
|
|
60211
60526
|
this._groupDisabled = false;
|
|
60527
|
+
this._awaitingLoad = false;
|
|
60212
60528
|
}
|
|
60213
60529
|
get _effectiveVariant() {
|
|
60214
60530
|
if (this._authorVariant) return this._authorVariant;
|
|
@@ -60226,6 +60542,27 @@ var _NLDDTabBarItem = class NLDDTabBarItem extends LitElement {
|
|
|
60226
60542
|
}
|
|
60227
60543
|
updated() {
|
|
60228
60544
|
this.setAttribute("variant", this._effectiveVariant);
|
|
60545
|
+
this._applyControls();
|
|
60546
|
+
}
|
|
60547
|
+
/** Points the tab at the element it shows. By reference, not by id: the tab
|
|
60548
|
+
* sits in this item's shadow root, where an id from the page does not
|
|
60549
|
+
* resolve. Content that follows the tab bar may not be parsed yet on the
|
|
60550
|
+
* first update, so a missing id is looked up again once the page is in. */
|
|
60551
|
+
_applyControls() {
|
|
60552
|
+
const tab = this.renderRoot.querySelector("[role=\"tab\"]");
|
|
60553
|
+
const target = this.controlsElement ?? this._findControls();
|
|
60554
|
+
if (tab && "ariaControlsElements" in tab && (tab.ariaControlsElements?.[0] ?? null) !== target) tab.ariaControlsElements = target ? [target] : null;
|
|
60555
|
+
if (!target && this.controls && !this.controlsElement && document.readyState === "loading" && !this._awaitingLoad) {
|
|
60556
|
+
this._awaitingLoad = true;
|
|
60557
|
+
document.addEventListener("DOMContentLoaded", () => {
|
|
60558
|
+
this._awaitingLoad = false;
|
|
60559
|
+
if (this.isConnected) this._applyControls();
|
|
60560
|
+
}, { once: true });
|
|
60561
|
+
}
|
|
60562
|
+
}
|
|
60563
|
+
_findControls() {
|
|
60564
|
+
if (!this.controls) return null;
|
|
60565
|
+
return this.getRootNode().getElementById?.(this.controls) ?? null;
|
|
60229
60566
|
}
|
|
60230
60567
|
focus(options) {
|
|
60231
60568
|
if (deferFocus(this, options)) return;
|
|
@@ -60234,6 +60571,11 @@ var _NLDDTabBarItem = class NLDDTabBarItem extends LitElement {
|
|
|
60234
60571
|
_onIconSlotChange(e) {
|
|
60235
60572
|
const slot = e.target;
|
|
60236
60573
|
this._hasIconSlot = slot.assignedElements({ flatten: true }).length > 0;
|
|
60574
|
+
this.closest("nldd-tab-bar")?.requestUpdate();
|
|
60575
|
+
}
|
|
60576
|
+
/** The icon in the slot, which the overflow menu copies. */
|
|
60577
|
+
get _slottedIcon() {
|
|
60578
|
+
return this.querySelector(":scope > [slot=\"icon\"]");
|
|
60237
60579
|
}
|
|
60238
60580
|
_handleClick(event) {
|
|
60239
60581
|
if (this._groupDisabled) {
|
|
@@ -60264,9 +60606,14 @@ __decorate([property({
|
|
|
60264
60606
|
converter: reflectNonDefault("")
|
|
60265
60607
|
})], NLDDTabBarItem.prototype, "text", void 0);
|
|
60266
60608
|
__decorate([property({
|
|
60267
|
-
|
|
60268
|
-
|
|
60609
|
+
reflect: true,
|
|
60610
|
+
converter: reflectNonDefault("")
|
|
60269
60611
|
})], NLDDTabBarItem.prototype, "icon", void 0);
|
|
60612
|
+
__decorate([property({
|
|
60613
|
+
reflect: true,
|
|
60614
|
+
converter: reflectNonDefault("")
|
|
60615
|
+
})], NLDDTabBarItem.prototype, "controls", void 0);
|
|
60616
|
+
__decorate([property({ attribute: false })], NLDDTabBarItem.prototype, "controlsElement", void 0);
|
|
60270
60617
|
__decorate([property({
|
|
60271
60618
|
reflect: true,
|
|
60272
60619
|
converter: reflectNonDefault("md")
|
|
@@ -62407,12 +62754,12 @@ var _NLDDPagination = class NLDDPagination extends LitElement {
|
|
|
62407
62754
|
};
|
|
62408
62755
|
var NLDDPagination = (_NLDDPagination.styles = paginationStyles, _NLDDPagination);
|
|
62409
62756
|
__decorate([property({
|
|
62410
|
-
|
|
62411
|
-
|
|
62757
|
+
reflect: true,
|
|
62758
|
+
converter: reflectNonDefault(1)
|
|
62412
62759
|
})], NLDDPagination.prototype, "current", void 0);
|
|
62413
62760
|
__decorate([property({
|
|
62414
|
-
|
|
62415
|
-
|
|
62761
|
+
reflect: true,
|
|
62762
|
+
converter: reflectNonDefault(1)
|
|
62416
62763
|
})], NLDDPagination.prototype, "total", void 0);
|
|
62417
62764
|
__decorate([property({
|
|
62418
62765
|
type: Boolean,
|
|
@@ -62739,8 +63086,8 @@ __decorate([property({
|
|
|
62739
63086
|
converter: reflectNonDefault("")
|
|
62740
63087
|
})], NLDDModalDialog.prototype, "supportingText", void 0);
|
|
62741
63088
|
__decorate([property({
|
|
62742
|
-
|
|
62743
|
-
|
|
63089
|
+
reflect: true,
|
|
63090
|
+
converter: reflectNonDefault("")
|
|
62744
63091
|
})], NLDDModalDialog.prototype, "icon", void 0);
|
|
62745
63092
|
__decorate([property({
|
|
62746
63093
|
type: String,
|
|
@@ -63134,8 +63481,8 @@ __decorate([property({
|
|
|
63134
63481
|
converter: reflectNonDefault("md")
|
|
63135
63482
|
})], NLDDBanner.prototype, "size", void 0);
|
|
63136
63483
|
__decorate([property({
|
|
63137
|
-
|
|
63138
|
-
|
|
63484
|
+
reflect: true,
|
|
63485
|
+
converter: reflectNonDefault("")
|
|
63139
63486
|
})], NLDDBanner.prototype, "icon", void 0);
|
|
63140
63487
|
__decorate([property({
|
|
63141
63488
|
reflect: true,
|
|
@@ -64034,13 +64381,13 @@ __decorate([property({
|
|
|
64034
64381
|
converter: reflectNonDefault("")
|
|
64035
64382
|
})], NLDDNotification.prototype, "icon", void 0);
|
|
64036
64383
|
__decorate([property({
|
|
64037
|
-
|
|
64038
|
-
|
|
64384
|
+
reflect: true,
|
|
64385
|
+
converter: reflectNonDefault("")
|
|
64039
64386
|
})], NLDDNotification.prototype, "text", void 0);
|
|
64040
64387
|
__decorate([property({
|
|
64041
|
-
type: String,
|
|
64042
64388
|
reflect: true,
|
|
64043
|
-
attribute: "supporting-text"
|
|
64389
|
+
attribute: "supporting-text",
|
|
64390
|
+
converter: reflectNonDefault("")
|
|
64044
64391
|
})], NLDDNotification.prototype, "supportingText", void 0);
|
|
64045
64392
|
__decorate([property({
|
|
64046
64393
|
reflect: true,
|
|
@@ -64978,8 +65325,8 @@ __decorate([property({
|
|
|
64978
65325
|
converter: reflectNonDefault("accent")
|
|
64979
65326
|
})], NLDDProgressBarSegmentIndicator.prototype, "color", void 0);
|
|
64980
65327
|
__decorate([property({
|
|
64981
|
-
|
|
64982
|
-
|
|
65328
|
+
reflect: true,
|
|
65329
|
+
converter: reflectNonDefault("")
|
|
64983
65330
|
})], NLDDProgressBarSegmentIndicator.prototype, "name", void 0);
|
|
64984
65331
|
__decorate([property({
|
|
64985
65332
|
reflect: true,
|
|
@@ -65179,8 +65526,8 @@ __decorate([property({
|
|
|
65179
65526
|
converter: reflectNonDefault("progress")
|
|
65180
65527
|
})], NLDDProgressBar.prototype, "variant", void 0);
|
|
65181
65528
|
__decorate([property({
|
|
65182
|
-
|
|
65183
|
-
|
|
65529
|
+
reflect: true,
|
|
65530
|
+
converter: reflectNonDefault(100)
|
|
65184
65531
|
})], NLDDProgressBar.prototype, "max", void 0);
|
|
65185
65532
|
__decorate([property({
|
|
65186
65533
|
type: Number,
|
|
@@ -65204,9 +65551,9 @@ __decorate([property({
|
|
|
65204
65551
|
converter: reflectNonDefault("percentage")
|
|
65205
65552
|
})], NLDDProgressBar.prototype, "valueFormat", void 0);
|
|
65206
65553
|
__decorate([property({
|
|
65207
|
-
type: String,
|
|
65208
65554
|
reflect: true,
|
|
65209
|
-
attribute: "value-text"
|
|
65555
|
+
attribute: "value-text",
|
|
65556
|
+
converter: reflectNonDefault("")
|
|
65210
65557
|
})], NLDDProgressBar.prototype, "valueText", void 0);
|
|
65211
65558
|
__decorate([property({
|
|
65212
65559
|
reflect: true,
|
|
@@ -65214,9 +65561,9 @@ __decorate([property({
|
|
|
65214
65561
|
converter: reflectNonDefault("inline")
|
|
65215
65562
|
})], NLDDProgressBar.prototype, "valueDisplay", void 0);
|
|
65216
65563
|
__decorate([property({
|
|
65217
|
-
type: String,
|
|
65218
65564
|
reflect: true,
|
|
65219
|
-
attribute: "accessible-label"
|
|
65565
|
+
attribute: "accessible-label",
|
|
65566
|
+
converter: reflectNonDefault("")
|
|
65220
65567
|
})], NLDDProgressBar.prototype, "accessibleLabel", void 0);
|
|
65221
65568
|
__decorate([property({
|
|
65222
65569
|
type: Boolean,
|
|
@@ -65793,8 +66140,8 @@ __decorate([property({
|
|
|
65793
66140
|
converter: reflectNonDefault("accent")
|
|
65794
66141
|
})], NLDDProgressCircleSegmentIndicator.prototype, "color", void 0);
|
|
65795
66142
|
__decorate([property({
|
|
65796
|
-
|
|
65797
|
-
|
|
66143
|
+
reflect: true,
|
|
66144
|
+
converter: reflectNonDefault("")
|
|
65798
66145
|
})], NLDDProgressCircleSegmentIndicator.prototype, "name", void 0);
|
|
65799
66146
|
NLDDProgressCircleSegmentIndicator = __decorate([customElement("nldd-progress-circle-segment-indicator")], NLDDProgressCircleSegmentIndicator);
|
|
65800
66147
|
var NLDDProgressCircle = (_NLDDProgressCircle2 = class NLDDProgressCircle extends LitElement {
|
|
@@ -66031,8 +66378,8 @@ __decorate([property({
|
|
|
66031
66378
|
converter: reflectNonDefault("progress")
|
|
66032
66379
|
})], NLDDProgressCircle.prototype, "variant", void 0);
|
|
66033
66380
|
__decorate([property({
|
|
66034
|
-
|
|
66035
|
-
|
|
66381
|
+
reflect: true,
|
|
66382
|
+
converter: reflectNonDefault(100)
|
|
66036
66383
|
})], NLDDProgressCircle.prototype, "max", void 0);
|
|
66037
66384
|
__decorate([property({
|
|
66038
66385
|
type: Number,
|
|
@@ -66056,9 +66403,9 @@ __decorate([property({
|
|
|
66056
66403
|
converter: reflectNonDefault("percentage")
|
|
66057
66404
|
})], NLDDProgressCircle.prototype, "valueFormat", void 0);
|
|
66058
66405
|
__decorate([property({
|
|
66059
|
-
type: String,
|
|
66060
66406
|
reflect: true,
|
|
66061
|
-
attribute: "value-text"
|
|
66407
|
+
attribute: "value-text",
|
|
66408
|
+
converter: reflectNonDefault("")
|
|
66062
66409
|
})], NLDDProgressCircle.prototype, "valueText", void 0);
|
|
66063
66410
|
__decorate([property({
|
|
66064
66411
|
reflect: true,
|
|
@@ -66066,9 +66413,9 @@ __decorate([property({
|
|
|
66066
66413
|
converter: reflectNonDefault("tooltip")
|
|
66067
66414
|
})], NLDDProgressCircle.prototype, "valueDisplay", void 0);
|
|
66068
66415
|
__decorate([property({
|
|
66069
|
-
type: String,
|
|
66070
66416
|
reflect: true,
|
|
66071
|
-
attribute: "accessible-label"
|
|
66417
|
+
attribute: "accessible-label",
|
|
66418
|
+
converter: reflectNonDefault("")
|
|
66072
66419
|
})], NLDDProgressCircle.prototype, "accessibleLabel", void 0);
|
|
66073
66420
|
__decorate([property({
|
|
66074
66421
|
type: Boolean,
|
|
@@ -66451,7 +66798,7 @@ function stepBarItemTemplate(component) {
|
|
|
66451
66798
|
aria-hidden="true"
|
|
66452
66799
|
>${marker}</span>
|
|
66453
66800
|
<span class="step-bar__item-title">
|
|
66454
|
-
${component.
|
|
66801
|
+
${component._textSlot.has ? nothing : component.text}<slot @slotchange=${component._textSlot.onChange}></slot>
|
|
66455
66802
|
<span class="step-bar__item-status">, ${component._statusText}</span>
|
|
66456
66803
|
</span>
|
|
66457
66804
|
`;
|
|
@@ -66536,16 +66883,17 @@ var _NLDDStepBar;
|
|
|
66536
66883
|
* @element nldd-step-bar-item
|
|
66537
66884
|
*
|
|
66538
66885
|
* @attr {'past' | 'current' | 'future'} status - How far along this step is. `current` marks the step you are on (`aria-current="step"`) and the parent derives the others from it: with none marked step 1 is current, with more than one the last wins. `past` and `future` override what is derived for this step only
|
|
66539
|
-
* @attr {string} text - Label under the disc
|
|
66886
|
+
* @attr {string} text - Label under the disc. Content in the default slot wins.
|
|
66540
66887
|
* @attr {string} icon - Icon in the disc instead of the number or the check mark
|
|
66541
66888
|
* @attr {string} href - Makes the step a link (back to a completed step, for instance)
|
|
66542
66889
|
* @attr {boolean} button - Makes the step a button, for flows without a URL per step; ignored when `href` is set
|
|
66543
66890
|
*
|
|
66544
|
-
* @slot - Label
|
|
66891
|
+
* @slot - Label. Wins over `text`.
|
|
66545
66892
|
*/
|
|
66546
66893
|
var NLDDStepBarItem = class extends LitElement {
|
|
66547
66894
|
constructor(..._args) {
|
|
66548
66895
|
super(..._args);
|
|
66896
|
+
this._textSlot = new SlotContent(this);
|
|
66549
66897
|
this.text = "";
|
|
66550
66898
|
this.icon = "";
|
|
66551
66899
|
this.href = "";
|
|
@@ -66588,8 +66936,8 @@ __decorate([property({
|
|
|
66588
66936
|
})], NLDDStepBarItem.prototype, "text", void 0);
|
|
66589
66937
|
__decorate([property({ type: String })], NLDDStepBarItem.prototype, "icon", void 0);
|
|
66590
66938
|
__decorate([property({
|
|
66591
|
-
|
|
66592
|
-
|
|
66939
|
+
reflect: true,
|
|
66940
|
+
converter: reflectNonDefault("")
|
|
66593
66941
|
})], NLDDStepBarItem.prototype, "href", void 0);
|
|
66594
66942
|
__decorate([property({
|
|
66595
66943
|
type: Boolean,
|
|
@@ -67882,9 +68230,9 @@ __decorate([property({
|
|
|
67882
68230
|
reflect: true
|
|
67883
68231
|
})], NLDDJustInTimeEducation.prototype, "dismissable", void 0);
|
|
67884
68232
|
__decorate([property({
|
|
67885
|
-
type: String,
|
|
67886
68233
|
reflect: true,
|
|
67887
|
-
attribute: "arrow-length"
|
|
68234
|
+
attribute: "arrow-length",
|
|
68235
|
+
converter: reflectNonDefault("")
|
|
67888
68236
|
})], NLDDJustInTimeEducation.prototype, "arrowLength", void 0);
|
|
67889
68237
|
__decorate([property({
|
|
67890
68238
|
type: Boolean,
|