@nldd/design-system 0.26.1 → 0.26.2
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 +4559 -1176
- package/dist/cdn/autoloader.js +141 -141
- package/dist/cdn/chunks/{accordion-DA4IlxS5.js → accordion-CCuKxlsg.js} +6 -6
- package/dist/cdn/chunks/{accordion-item-Ca1o93cq.js → accordion-item-Cn1UDWtD.js} +7 -7
- package/dist/cdn/chunks/{activity-indicator-Cj4H0Mbz.js → activity-indicator-BM_atCTY.js} +13 -13
- package/dist/cdn/chunks/{admonition-CdZSoO8O.js → admonition-CqDce27_.js} +11 -11
- package/dist/cdn/chunks/{avatar-Dhqn-Dmv.js → avatar-Dl2tOfc2.js} +18 -18
- package/dist/cdn/chunks/{avatar-group-B017eF-u.js → avatar-group-Br3qBaow.js} +42 -40
- package/dist/cdn/chunks/{badge-Bep5B0_g.js → badge-DjjAl4mn.js} +15 -15
- package/dist/cdn/chunks/{banner-DGpIXuE2.js → banner-s5xMqoEU.js} +16 -16
- package/dist/cdn/chunks/{bar-split-view-CKwJxd3e.js → bar-split-view-B6Mv_cw-.js} +8 -8
- package/dist/cdn/chunks/{blockquote-ChMgaOuI.js → blockquote-CRFPXI9u.js} +8 -8
- package/dist/cdn/chunks/{box-BRmziG-6.js → box-CSZyj31o.js} +5 -5
- package/dist/cdn/chunks/{breadcrumbs-BeVO8bkQ.js → breadcrumbs-DzjbOB7o.js} +13 -13
- package/dist/cdn/chunks/{button-cHBkq_s7.js → button-B7OGt_dX.js} +53 -54
- package/dist/cdn/chunks/{button-bar-CLxOdalJ.js → button-bar-CvDkir22.js} +8 -8
- package/dist/cdn/chunks/{button-group-BIvKtEIX.js → button-group-Bi3dr9Go.js} +6 -6
- package/dist/cdn/chunks/{card-B5gp9Zly.js → card-DceO3pMp.js} +10 -10
- package/dist/cdn/chunks/{cell-D4Nrd5Z9.js → cell-Bgp9n0yQ.js} +13 -13
- package/dist/cdn/chunks/{checkbox-CeLTJhAc.js → checkbox-C1F0Q3g8.js} +26 -43
- package/dist/cdn/chunks/{checkbox-field-C8cU8fuf.js → checkbox-field-DGKc530M.js} +35 -43
- package/dist/cdn/chunks/checkbox-group-x9Ua2a06.js +91 -0
- package/dist/cdn/chunks/choice-group-AZsqoheP.js +64 -0
- package/dist/cdn/chunks/{class-map-xzscTu4B.js → class-map-CAVKoa31.js} +1 -1
- package/dist/cdn/chunks/{code-editor-BNhlXTSl.js → code-editor-C0U5qVW2.js} +11 -11
- package/dist/cdn/chunks/{code-viewer-D_JwouYO.js → code-viewer-C_DzKPSv.js} +17 -17
- package/dist/cdn/chunks/{codemirror-input-DJ0wgYrc.js → codemirror-input-BmIE22aU.js} +5 -5
- package/dist/cdn/chunks/{collection-BXvz_OtU.js → collection-BZK9NzrQ.js} +19 -19
- package/dist/cdn/chunks/{combo-box-8kbmoStb.js → combo-box-DJrQ-2Wr.js} +69 -87
- package/dist/cdn/chunks/{container-Dq-2uHd5.js → container-BT96Wlz6.js} +48 -48
- package/dist/cdn/chunks/{custom-element-DeaCQ2NP.js → custom-element-D5bstafw.js} +2 -2
- package/dist/cdn/chunks/{date-field-CQg1_73u.js → date-field-B8GcDwkD.js} +33 -40
- package/dist/cdn/chunks/{date-picker-CTMxGOiA.js → date-picker-Byi-fA0A.js} +17 -17
- package/dist/cdn/chunks/{decorate-CCYde2ES.js → decorate-Cjb3GqlZ.js} +1 -1
- package/dist/cdn/chunks/deep-active-element-DgiHjYGG.js +7 -0
- package/dist/cdn/chunks/{described-by-mixin-BYFim7aO.js → described-by-mixin-ZWpyWEyB.js} +2 -2
- package/dist/cdn/chunks/{description-cell-GcVeCz2_.js → description-cell-DRXRiZGw.js} +12 -12
- package/dist/cdn/chunks/{dev-checks-CSlbfDuF.js → dev-checks-BYWMWeug.js} +931 -931
- package/dist/cdn/chunks/{directive-helpers-DgaADFyY.js → directive-helpers-mh9SNf0j.js} +1 -1
- package/dist/cdn/chunks/{dist-5vPsM2aV.js → dist-1yCEk2Pe.js} +1 -1
- package/dist/cdn/chunks/{dist-1OQdP4ho.js → dist-BBtyEGZQ.js} +3 -3
- package/dist/cdn/chunks/{dist-Da_liXcd.js → dist-BIhRNYZs.js} +3 -3
- package/dist/cdn/chunks/{dist-B23jHvJ5.js → dist-BfJ8w6Dz.js} +1 -1
- package/dist/cdn/chunks/{dist-CcpLhc4y.js → dist-BlHWe6Ns.js} +1 -1
- package/dist/cdn/chunks/{dist-VCymi0hs.js → dist-C4o16iKF.js} +1 -1
- package/dist/cdn/chunks/{dist-CyDpBAaD.js → dist-CKGgPGjj.js} +2 -2
- package/dist/cdn/chunks/{dist-CNy2sPTt.js → dist-CT0CdAxb.js} +2 -2
- package/dist/cdn/chunks/{dist-D4SViUJx.js → dist-DCzCfm9V.js} +1 -1
- package/dist/cdn/chunks/{dist-DLtwMUDc.js → dist-iYv1GHSb.js} +2 -2
- package/dist/cdn/chunks/{dist-DBxjWahH.js → dist-jyyZH0d2.js} +1 -1
- package/dist/cdn/chunks/{divider-8XD3xTbl.js → divider-CeAw8gBP.js} +2 -2
- package/dist/cdn/chunks/{document-tab-bar-RBAmckHS.js → document-tab-bar-rIsC6EZp.js} +32 -46
- package/dist/cdn/chunks/{dropdown-DVlxPcjr.js → dropdown-MEzKo0TQ.js} +14 -14
- package/dist/cdn/chunks/{file-field-BrHnFplX.js → file-field--wivtgZv.js} +42 -40
- package/dist/cdn/chunks/{form-DGHeGEIr.js → form-ByjlUZuR.js} +1 -1
- package/dist/cdn/chunks/{form-actions-CHwWKfMM.js → form-actions-YK7n_jse.js} +4 -4
- package/dist/cdn/chunks/form-associated-mixin-BCzChLUO.js +123 -0
- package/dist/cdn/chunks/{form-field-CdTSI-8h.js → form-field-y-h-k8x5.js} +11 -11
- package/dist/cdn/chunks/{form-section-CjECOIiZ.js → form-section-jWj88aQa.js} +1 -1
- package/dist/cdn/chunks/{full-bleed-section-CQgq4iGQ.js → full-bleed-section-h6CrFe8F.js} +5 -5
- package/dist/cdn/chunks/{hero-DhdcYt2N.js → hero-Dy1tW9gU.js} +19 -19
- package/dist/cdn/chunks/{icon-button-DT_Bi4Ac.js → icon-button-B0Lb2ccT.js} +37 -38
- package/dist/cdn/chunks/{icon-cell-C-qrZAlN.js → icon-cell-byBTzcEn.js} +10 -10
- package/dist/cdn/chunks/{icon-qpmEfU9B.js → icon-m8JXbN5F.js} +8 -8
- package/dist/cdn/chunks/{identity-DFmvuPkl.js → identity-BpUMGka9.js} +12 -12
- package/dist/cdn/chunks/{if-defined-BINBE69I.js → if-defined-Duzrh8bb.js} +1 -1
- package/dist/cdn/chunks/{image-B4M3h1xJ.js → image-DfpFBPj1.js} +21 -21
- package/dist/cdn/chunks/{inline-dialog-L-NvjANF.js → inline-dialog-D6CMJnYk.js} +16 -16
- package/dist/cdn/chunks/interest-intent-Bk3i_upv.js +63 -0
- package/dist/cdn/chunks/{interest-controller-Ban-3NrX.js → interest-invoker-BY95Duqo.js} +28 -38
- package/dist/cdn/chunks/{just-in-time-education-CWplH4r9.js → just-in-time-education-_1kTZuGb.js} +13 -13
- package/dist/cdn/chunks/{kanban-B6Wa-2aM.js → kanban-DFGaEwfP.js} +25 -29
- package/dist/cdn/chunks/{kanban-column-D2-Xq79_.js → kanban-column-Cs47JSUO.js} +10 -10
- package/dist/cdn/chunks/{keyboard-shortcut-Ci95olxF.js → keyboard-shortcut-4DPqQovv.js} +13 -13
- package/dist/cdn/chunks/{languages-C9AGuuSS.js → languages-D-97TsxL.js} +12 -12
- package/dist/cdn/chunks/{link-BJB2a_fG.js → link-6T0VtDWt.js} +18 -18
- package/dist/cdn/chunks/{link-group-aNoedLZo.js → link-group-ymcl82Ua.js} +7 -7
- package/dist/cdn/chunks/{list-CZWX62tH.js → list-BXpR0UzC.js} +110 -95
- package/dist/cdn/chunks/{list-item-DHzsbK_S.js → list-item-CyZ6uPGG.js} +50 -29
- package/dist/cdn/chunks/{list-item-segment-CHLlU9Gg.js → list-item-segment-BUtAy96X.js} +23 -20
- package/dist/cdn/chunks/{menu-bar-CJazkmY7.js → menu-bar-Cn1Nb2ir.js} +59 -60
- package/dist/cdn/chunks/{menu-bar-item-CSqXWNKE.js → menu-bar-item-CZR2qAzA.js} +35 -35
- package/dist/cdn/chunks/{menu-divider-Cn1hTpcM.js → menu-divider-dF1NvFJO.js} +3 -3
- package/dist/cdn/chunks/{menu-group-C71K1Vmv.js → menu-group-DW3so0Dn.js} +4 -4
- package/dist/cdn/chunks/{menu-item-TqBlQfI2.js → menu-item-7kb18Ypf.js} +4 -4
- package/dist/cdn/chunks/{menu-NGpB1SKq.js → menu-kSZLzjet.js} +101 -93
- package/dist/cdn/chunks/{menu.template-DthELYky.js → menu.template-cgua9dKM.js} +4 -4
- package/dist/cdn/chunks/{modal-dialog-0V2HsrJC.js → modal-dialog-DfKbcw9T.js} +28 -78
- package/dist/cdn/chunks/modal-overlay-Bx0bYzF3.js +95 -0
- package/dist/cdn/chunks/{multi-line-text-field-BV4uUDoK.js → multi-line-text-field-AV-vID1z.js} +28 -45
- package/dist/cdn/chunks/{navigation-split-view-tPhkxEVD.js → navigation-split-view-UwlSFPDE.js} +10 -10
- package/dist/cdn/chunks/{notification-CZccv6qx.js → notification-e5uGGh0b.js} +12 -12
- package/dist/cdn/chunks/{number-field-4R2blHda.js → number-field-COUmvl_s.js} +26 -32
- package/dist/cdn/chunks/{one-half-one-half-section-h2fLPQfP.js → one-half-one-half-section-C-AgSdm9.js} +6 -6
- package/dist/cdn/chunks/{one-third-two-thirds-section-mqUAH5lK.js → one-third-two-thirds-section-D1kq4IEc.js} +6 -6
- package/dist/cdn/chunks/{one-time-code-field-Bf_qymKd.js → one-time-code-field-BDQctC8H.js} +25 -38
- package/dist/cdn/chunks/overflow-menu-C67lAkP8.js +83 -0
- package/dist/cdn/chunks/overlay-invoker-CQpe-JGA.js +95 -0
- package/dist/cdn/chunks/{page-Kipfvmi6.js → page-DXEaFsfo.js} +11 -11
- package/dist/cdn/chunks/{page-footer-DxE966Oe.js → page-footer-DFaIlgHs.js} +13 -13
- package/dist/cdn/chunks/{page-section-mixin-DpF9JDpd.js → page-section-mixin-3XhS4f5q.js} +21 -21
- package/dist/cdn/chunks/{pagination-DUFFhaU8.js → pagination-BE3ERBNx.js} +13 -13
- package/dist/cdn/chunks/{password-field-DdYAVmF3.js → password-field-DjRp78HI.js} +28 -45
- package/dist/cdn/chunks/{popover-CRHxyhGx.js → popover-C3j0KtFh.js} +55 -64
- package/dist/cdn/chunks/{progress-bar-BuYsjmSo.js → progress-bar-iWFq6KS1.js} +26 -26
- package/dist/cdn/chunks/{progress-circle-Cvu1bfNG.js → progress-circle-BPFzTlhn.js} +24 -24
- package/dist/cdn/chunks/{radio-button-B_4AxWDx.js → radio-button-BMVBbe3-.js} +17 -26
- package/dist/cdn/chunks/{radio-button-field-D7jIg6Oi.js → radio-button-field-BqSd0JMd.js} +29 -37
- package/dist/cdn/chunks/radio-button-group-DZTPflZ3.js +112 -0
- package/dist/cdn/chunks/{render-marked-CIuiSS_8.js → render-marked-1xftlCd8.js} +1 -1
- package/dist/cdn/chunks/{reorder-handle-cell-DNPaZjSC.js → reorder-handle-cell-loSG6GRY.js} +7 -7
- package/dist/cdn/chunks/{reorder-handle-mixin-CgvWq4fF.js → reorder-handle-mixin-cLWXCdFC.js} +2 -2
- package/dist/cdn/chunks/{repeat-DfVuWl6o.js → repeat-CWsNVfra.js} +2 -2
- package/dist/cdn/chunks/{return-focus-D0fF2hjd.js → return-focus-CpwHVxYU.js} +10 -14
- package/dist/cdn/chunks/{rich-text-CVHlMQY6.js → rich-text-DSvI9u6v.js} +3 -3
- package/dist/cdn/chunks/{row-header-mixin-B25JK2B3.js → row-header-mixin-vwABKkTO.js} +2 -2
- package/dist/cdn/chunks/{scroll-fade-Dv57rTww.js → scroll-fade-ZNdnDF4p.js} +4 -4
- package/dist/cdn/chunks/{search-field-hmD_DXbG.js → search-field-CBTir8Wu.js} +33 -58
- package/dist/cdn/chunks/{segmented-control-e8e-jYSw.js → segmented-control-hvWn3L0J.js} +92 -103
- package/dist/cdn/chunks/{shadow-resets-CRdvf-Ei.js → shadow-resets-JiVlctXb.js} +2 -2
- package/dist/cdn/chunks/{sheet-D09y3J45.js → sheet-CnbdONF9.js} +39 -90
- package/dist/cdn/chunks/{shell-CV3gooGg.js → shell-BAH9okPd.js} +5 -5
- package/dist/cdn/chunks/{side-by-side-split-view-Ckz1C9zk.js → side-by-side-split-view-D07iBCFK.js} +8 -8
- package/dist/cdn/chunks/{sidebar-section-CdyD-x4t.js → sidebar-section-DAE2lrdn.js} +14 -14
- package/dist/cdn/chunks/{simple-section-CEf38rBZ.js → simple-section-DQZpG3nQ.js} +7 -7
- package/dist/cdn/chunks/{skip-link-DMRhATWw.js → skip-link-D0yYukhb.js} +7 -7
- package/dist/cdn/chunks/{slider-Db3FPiP6.js → slider-C-a97cAu.js} +30 -37
- package/dist/cdn/chunks/{spacer-BPFIYueo.js → spacer-C19W6HrX.js} +8 -8
- package/dist/cdn/chunks/{spacer-cell-kITa3CDV.js → spacer-cell-lRxkFSnp.js} +6 -6
- package/dist/cdn/chunks/{split-button-CJs9-Nha.js → split-button-38xSIAVk.js} +21 -21
- package/dist/cdn/chunks/{split-view-divider-lHlM1Ss8.js → split-view-divider-CViSo7s7.js} +5 -5
- package/dist/cdn/chunks/{split-view-pane-DlsbZtyo.js → split-view-pane-Bb1RFCNJ.js} +7 -7
- package/dist/cdn/chunks/{stacked-split-view-uRSVhrMd.js → stacked-split-view-Bnw5hQ5A.js} +8 -8
- package/dist/cdn/chunks/{static-html-BahSPV_4.js → static-html-7PckS8pf.js} +1 -1
- package/dist/cdn/chunks/{status-bar-DCJLVpsW.js → status-bar-D57SEB_4.js} +8 -8
- package/dist/cdn/chunks/{step-bar-CRR2jiyo.js → step-bar-Q_wc0vqp.js} +18 -18
- package/dist/cdn/chunks/{step-cell-CbtKxJNJ.js → step-cell-DU6sNjnm.js} +15 -15
- package/dist/cdn/chunks/{stepper-Con1_CnB.js → stepper-BM1dp44g.js} +16 -26
- package/dist/cdn/chunks/{style-map-uOwLerwV.js → style-map-BRs_xiW6.js} +1 -1
- package/dist/cdn/chunks/{swatch-picker-Bqn0eaC9.js → swatch-picker-BcRbPWVv.js} +63 -69
- package/dist/cdn/chunks/{switch-CMQcLEBJ.js → switch-7BZAufN0.js} +25 -42
- package/dist/cdn/chunks/{switch-field-D9kWq4Kw.js → switch-field-gjPTIapp.js} +19 -32
- package/dist/cdn/chunks/{tab-bar-DXzyZI3V.js → tab-bar-BKzbb7TE.js} +34 -29
- package/dist/cdn/chunks/{table-CWACLpHx.js → table-CmkkY3M1.js} +15 -15
- package/dist/cdn/chunks/{tag-Bo4yJbtF.js → tag-B4VfItSH.js} +11 -11
- package/dist/cdn/chunks/{term-CQ379ZbN.js → term-C0aNyYXz.js} +42 -39
- package/dist/cdn/chunks/{text-D-dFoj6N.js → text-CLuHOFQt.js} +29 -29
- package/dist/cdn/chunks/{text-cell-Be1hStxp.js → text-cell-Dvujh580.js} +23 -23
- package/dist/cdn/chunks/{text-editor-BjzQEBWm.js → text-editor-0_ZoELkA.js} +12 -12
- package/dist/cdn/chunks/{text-field-DA8nirp6.js → text-field-CrRBrXx0.js} +28 -45
- package/dist/cdn/chunks/{time-field-Dd_TxJuf.js → time-field-DUt1zvLw.js} +66 -148
- package/dist/cdn/chunks/{time-picker-B0-rv1qp.js → time-picker-CDzillxF.js} +119 -40
- package/dist/cdn/chunks/{title-DOoPdG_i.js → title-DQXyEqFW.js} +12 -12
- package/dist/cdn/chunks/{title-cell-BzCNOMGr.js → title-cell-CoUK6h-F.js} +23 -23
- package/dist/cdn/chunks/{toggle-button-9PbDHviQ.js → toggle-button-BhU5vLF8.js} +41 -54
- package/dist/cdn/chunks/{toggle-button-group-C-H-xp0M.js → toggle-button-group-B-0r4xZZ.js} +40 -54
- package/dist/cdn/chunks/{token-CMKFC3gz.js → token-CELUzY2p.js} +31 -34
- package/dist/cdn/chunks/{token-field-D4-XHfnG.js → token-field-C8ynyISX.js} +67 -57
- package/dist/cdn/chunks/{toolbar-z9OhEE5l.js → toolbar--QBCm9qO.js} +34 -78
- package/dist/cdn/chunks/{toolbar-item-ZYoyKOyy.js → toolbar-item-BoRhKFDR.js} +3 -3
- package/dist/cdn/chunks/{toolbar-title-FKtQ8ZC4.js → toolbar-title-CciXdTJR.js} +4 -4
- package/dist/cdn/chunks/{toolbar.styles-DDjpdCHV.js → toolbar.styles-B6kTrAfC.js} +3 -3
- package/dist/cdn/chunks/{tooltip-BvRNYRo3.js → tooltip-CkLC4ooQ.js} +43 -41
- package/dist/cdn/chunks/{top-navigation-bar-BHPQntER.js → top-navigation-bar-CGu2pn4Z.js} +29 -29
- package/dist/cdn/chunks/{top-title-bar-BVjegLlh.js → top-title-bar-2b-XHftB.js} +15 -15
- package/dist/cdn/chunks/{translations-cJjO6nQV.js → translations-D0cgmONm.js} +1 -1
- package/dist/cdn/chunks/{two-thirds-one-third-section-BdBHQuXc.js → two-thirds-one-third-section-CEfd273Z.js} +6 -6
- package/dist/cdn/chunks/{validation-list-5E3-3_95.js → validation-list-DIFEVSIk.js} +12 -12
- package/dist/cdn/chunks/{visibility-mixin-DvRe3O8t.js → visibility-mixin-OjALtpXa.js} +14 -14
- package/dist/cdn/chunks/{visually-hidden-F85D_HcR.js → visually-hidden-DcpY5lun.js} +2 -2
- package/dist/cdn/chunks/{window-CabW35M1.js → window-BGZCu06O.js} +44 -80
- package/dist/cdn/chunks/{with-translations-BHDG37HJ.js → with-translations-DkNkjQym.js} +3 -3
- package/dist/components/actions/button/button.d.ts +4 -4
- package/dist/components/actions/button/button.d.ts.map +1 -1
- package/dist/components/actions/button/button.js +4 -5
- package/dist/components/actions/button/button.js.map +1 -1
- package/dist/components/actions/button/button.template.js +1 -1
- package/dist/components/actions/button/button.template.js.map +1 -1
- package/dist/components/actions/icon-button/icon-button.d.ts +4 -4
- package/dist/components/actions/icon-button/icon-button.d.ts.map +1 -1
- package/dist/components/actions/icon-button/icon-button.js +4 -5
- package/dist/components/actions/icon-button/icon-button.js.map +1 -1
- package/dist/components/actions/icon-button/icon-button.template.js +1 -1
- package/dist/components/actions/icon-button/icon-button.template.js.map +1 -1
- package/dist/components/actions/menu/menu.d.ts +22 -6
- package/dist/components/actions/menu/menu.d.ts.map +1 -1
- package/dist/components/actions/menu/menu.js +50 -70
- package/dist/components/actions/menu/menu.js.map +1 -1
- package/dist/components/actions/split-button/split-button.js +1 -1
- package/dist/components/actions/split-button/split-button.js.map +1 -1
- package/dist/components/actions/toolbar/toolbar.d.ts +3 -3
- package/dist/components/actions/toolbar/toolbar.d.ts.map +1 -1
- package/dist/components/actions/toolbar/toolbar.js +4 -4
- package/dist/components/actions/toolbar/toolbar.js.map +1 -1
- package/dist/components/actions/toolbar/toolbar.template.d.ts.map +1 -1
- package/dist/components/actions/toolbar/toolbar.template.js +5 -9
- package/dist/components/actions/toolbar/toolbar.template.js.map +1 -1
- package/dist/components/content/avatar-group/avatar-group.d.ts +7 -1
- package/dist/components/content/avatar-group/avatar-group.d.ts.map +1 -1
- package/dist/components/content/avatar-group/avatar-group.js +9 -9
- package/dist/components/content/avatar-group/avatar-group.js.map +1 -1
- package/dist/components/content/avatar-group/avatar-group.template.d.ts.map +1 -1
- package/dist/components/content/avatar-group/avatar-group.template.js +0 -1
- package/dist/components/content/avatar-group/avatar-group.template.js.map +1 -1
- package/dist/components/content/term/term.d.ts +5 -5
- package/dist/components/content/term/term.d.ts.map +1 -1
- package/dist/components/content/term/term.js +22 -23
- package/dist/components/content/term/term.js.map +1 -1
- package/dist/components/content/term/term.template.js +1 -1
- package/dist/components/content/term/term.template.js.map +1 -1
- package/dist/components/content/token/token.d.ts +3 -5
- package/dist/components/content/token/token.d.ts.map +1 -1
- package/dist/components/content/token/token.js +23 -33
- package/dist/components/content/token/token.js.map +1 -1
- package/dist/components/content/tooltip/tooltip.d.ts +3 -5
- package/dist/components/content/tooltip/tooltip.d.ts.map +1 -1
- package/dist/components/content/tooltip/tooltip.js +34 -119
- package/dist/components/content/tooltip/tooltip.js.map +1 -1
- package/dist/components/forms/form-field/form-field.d.ts.map +1 -1
- package/dist/components/forms/form-field/form-field.js +4 -1
- package/dist/components/forms/form-field/form-field.js.map +1 -1
- package/dist/components/inputs/checkbox/checkbox.d.ts +1 -4
- package/dist/components/inputs/checkbox/checkbox.d.ts.map +1 -1
- package/dist/components/inputs/checkbox/checkbox.js +3 -23
- package/dist/components/inputs/checkbox/checkbox.js.map +1 -1
- package/dist/components/inputs/checkbox-field/checkbox-field.d.ts +1 -5
- package/dist/components/inputs/checkbox-field/checkbox-field.d.ts.map +1 -1
- package/dist/components/inputs/checkbox-field/checkbox-field.js +8 -17
- package/dist/components/inputs/checkbox-field/checkbox-field.js.map +1 -1
- package/dist/components/inputs/checkbox-group/checkbox-group.d.ts +1 -9
- package/dist/components/inputs/checkbox-group/checkbox-group.d.ts.map +1 -1
- package/dist/components/inputs/checkbox-group/checkbox-group.js +18 -59
- package/dist/components/inputs/checkbox-group/checkbox-group.js.map +1 -1
- package/dist/components/inputs/combo-box/combo-box.d.ts +6 -7
- package/dist/components/inputs/combo-box/combo-box.d.ts.map +1 -1
- package/dist/components/inputs/combo-box/combo-box.js +25 -58
- package/dist/components/inputs/combo-box/combo-box.js.map +1 -1
- package/dist/components/inputs/date-field/date-field.d.ts +1 -2
- package/dist/components/inputs/date-field/date-field.d.ts.map +1 -1
- package/dist/components/inputs/date-field/date-field.js +4 -14
- package/dist/components/inputs/date-field/date-field.js.map +1 -1
- package/dist/components/inputs/file-field/file-field.d.ts +6 -3
- package/dist/components/inputs/file-field/file-field.d.ts.map +1 -1
- package/dist/components/inputs/file-field/file-field.js +15 -18
- package/dist/components/inputs/file-field/file-field.js.map +1 -1
- package/dist/components/inputs/multi-line-text-field/multi-line-text-field.d.ts +1 -4
- package/dist/components/inputs/multi-line-text-field/multi-line-text-field.d.ts.map +1 -1
- package/dist/components/inputs/multi-line-text-field/multi-line-text-field.js +3 -23
- package/dist/components/inputs/multi-line-text-field/multi-line-text-field.js.map +1 -1
- package/dist/components/inputs/number-field/number-field.d.ts +4 -3
- package/dist/components/inputs/number-field/number-field.d.ts.map +1 -1
- package/dist/components/inputs/number-field/number-field.js +12 -16
- package/dist/components/inputs/number-field/number-field.js.map +1 -1
- package/dist/components/inputs/one-time-code-field/one-time-code-field.d.ts +1 -4
- package/dist/components/inputs/one-time-code-field/one-time-code-field.d.ts.map +1 -1
- package/dist/components/inputs/one-time-code-field/one-time-code-field.js +2 -17
- package/dist/components/inputs/one-time-code-field/one-time-code-field.js.map +1 -1
- package/dist/components/inputs/password-field/password-field.d.ts +1 -4
- package/dist/components/inputs/password-field/password-field.d.ts.map +1 -1
- package/dist/components/inputs/password-field/password-field.js +3 -23
- package/dist/components/inputs/password-field/password-field.js.map +1 -1
- package/dist/components/inputs/radio-button/radio-button.d.ts +1 -4
- package/dist/components/inputs/radio-button/radio-button.d.ts.map +1 -1
- package/dist/components/inputs/radio-button/radio-button.js +1 -10
- package/dist/components/inputs/radio-button/radio-button.js.map +1 -1
- package/dist/components/inputs/radio-button-field/radio-button-field.d.ts +3 -6
- package/dist/components/inputs/radio-button-field/radio-button-field.d.ts.map +1 -1
- package/dist/components/inputs/radio-button-field/radio-button-field.js +6 -14
- package/dist/components/inputs/radio-button-field/radio-button-field.js.map +1 -1
- package/dist/components/inputs/radio-button-group/radio-button-group.d.ts +1 -10
- package/dist/components/inputs/radio-button-group/radio-button-group.d.ts.map +1 -1
- package/dist/components/inputs/radio-button-group/radio-button-group.js +17 -74
- package/dist/components/inputs/radio-button-group/radio-button-group.js.map +1 -1
- package/dist/components/inputs/search-field/search-field.d.ts +1 -4
- package/dist/components/inputs/search-field/search-field.d.ts.map +1 -1
- package/dist/components/inputs/search-field/search-field.js +5 -35
- package/dist/components/inputs/search-field/search-field.js.map +1 -1
- package/dist/components/inputs/segmented-control/segmented-control.d.ts +1 -3
- package/dist/components/inputs/segmented-control/segmented-control.d.ts.map +1 -1
- package/dist/components/inputs/segmented-control/segmented-control.js +6 -41
- package/dist/components/inputs/segmented-control/segmented-control.js.map +1 -1
- package/dist/components/inputs/slider/slider.d.ts +1 -4
- package/dist/components/inputs/slider/slider.d.ts.map +1 -1
- package/dist/components/inputs/slider/slider.js +1 -14
- package/dist/components/inputs/slider/slider.js.map +1 -1
- package/dist/components/inputs/stepper/stepper.d.ts +1 -3
- package/dist/components/inputs/stepper/stepper.d.ts.map +1 -1
- package/dist/components/inputs/stepper/stepper.js +2 -13
- package/dist/components/inputs/stepper/stepper.js.map +1 -1
- package/dist/components/inputs/swatch-picker/swatch-picker.d.ts +1 -3
- package/dist/components/inputs/swatch-picker/swatch-picker.d.ts.map +1 -1
- package/dist/components/inputs/swatch-picker/swatch-picker.js +5 -28
- package/dist/components/inputs/swatch-picker/swatch-picker.js.map +1 -1
- package/dist/components/inputs/switch/switch.d.ts +1 -4
- package/dist/components/inputs/switch/switch.d.ts.map +1 -1
- package/dist/components/inputs/switch/switch.js +3 -22
- package/dist/components/inputs/switch/switch.js.map +1 -1
- package/dist/components/inputs/switch-field/switch-field.d.ts +1 -4
- package/dist/components/inputs/switch-field/switch-field.d.ts.map +1 -1
- package/dist/components/inputs/switch-field/switch-field.js +2 -16
- package/dist/components/inputs/switch-field/switch-field.js.map +1 -1
- package/dist/components/inputs/text-field/text-field.d.ts +1 -4
- package/dist/components/inputs/text-field/text-field.d.ts.map +1 -1
- package/dist/components/inputs/text-field/text-field.js +3 -23
- package/dist/components/inputs/text-field/text-field.js.map +1 -1
- package/dist/components/inputs/time-field/time-field.d.ts +8 -2
- package/dist/components/inputs/time-field/time-field.d.ts.map +1 -1
- package/dist/components/inputs/time-field/time-field.js +23 -14
- package/dist/components/inputs/time-field/time-field.js.map +1 -1
- package/dist/components/inputs/time-picker/time-picker.d.ts +11 -7
- package/dist/components/inputs/time-picker/time-picker.d.ts.map +1 -1
- package/dist/components/inputs/time-picker/time-picker.js +19 -14
- package/dist/components/inputs/time-picker/time-picker.js.map +1 -1
- package/dist/components/inputs/toggle-button/toggle-button.d.ts +3 -6
- package/dist/components/inputs/toggle-button/toggle-button.d.ts.map +1 -1
- package/dist/components/inputs/toggle-button/toggle-button.js +6 -20
- package/dist/components/inputs/toggle-button/toggle-button.js.map +1 -1
- package/dist/components/inputs/toggle-button-group/toggle-button-group.d.ts +2 -11
- package/dist/components/inputs/toggle-button-group/toggle-button-group.d.ts.map +1 -1
- package/dist/components/inputs/toggle-button-group/toggle-button-group.js +23 -78
- package/dist/components/inputs/toggle-button-group/toggle-button-group.js.map +1 -1
- package/dist/components/inputs/token-field/token-field.d.ts +12 -10
- package/dist/components/inputs/token-field/token-field.d.ts.map +1 -1
- package/dist/components/inputs/token-field/token-field.js +33 -35
- package/dist/components/inputs/token-field/token-field.js.map +1 -1
- package/dist/components/layout/kanban/kanban.d.ts +0 -1
- package/dist/components/layout/kanban/kanban.d.ts.map +1 -1
- package/dist/components/layout/kanban/kanban.js +2 -7
- package/dist/components/layout/kanban/kanban.js.map +1 -1
- package/dist/components/layout/popover/popover.d.ts +17 -3
- package/dist/components/layout/popover/popover.d.ts.map +1 -1
- package/dist/components/layout/popover/popover.js +34 -126
- package/dist/components/layout/popover/popover.js.map +1 -1
- package/dist/components/layout/sheet/sheet.d.ts +2 -33
- package/dist/components/layout/sheet/sheet.d.ts.map +1 -1
- package/dist/components/layout/sheet/sheet.js +8 -169
- package/dist/components/layout/sheet/sheet.js.map +1 -1
- package/dist/components/layout/sheet/sheet.template.js +5 -5
- package/dist/components/layout/sheet/sheet.template.js.map +1 -1
- package/dist/components/layout/window/window.d.ts +2 -30
- package/dist/components/layout/window/window.d.ts.map +1 -1
- package/dist/components/layout/window/window.js +12 -139
- package/dist/components/layout/window/window.js.map +1 -1
- package/dist/components/layout/window/window.template.d.ts.map +1 -1
- package/dist/components/layout/window/window.template.js +5 -4
- package/dist/components/layout/window/window.template.js.map +1 -1
- package/dist/components/lists-and-tables/list/list.d.ts +8 -32
- package/dist/components/lists-and-tables/list/list.d.ts.map +1 -1
- package/dist/components/lists-and-tables/list/list.js +37 -136
- package/dist/components/lists-and-tables/list/list.js.map +1 -1
- package/dist/components/lists-and-tables/list/list.roving.d.ts +79 -0
- package/dist/components/lists-and-tables/list/list.roving.d.ts.map +1 -0
- package/dist/components/lists-and-tables/list/list.roving.js +122 -0
- package/dist/components/lists-and-tables/list/list.roving.js.map +1 -0
- package/dist/components/lists-and-tables/list-item/list-item.d.ts +32 -17
- 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 +49 -36
- package/dist/components/lists-and-tables/list-item/list-item.js.map +1 -1
- package/dist/components/lists-and-tables/list-item-segment/list-item-segment.d.ts +3 -2
- package/dist/components/lists-and-tables/list-item-segment/list-item-segment.d.ts.map +1 -1
- package/dist/components/lists-and-tables/list-item-segment/list-item-segment.js +5 -5
- package/dist/components/lists-and-tables/list-item-segment/list-item-segment.js.map +1 -1
- package/dist/components/navigation/document-tab-bar/document-tab-bar.d.ts +4 -5
- package/dist/components/navigation/document-tab-bar/document-tab-bar.d.ts.map +1 -1
- package/dist/components/navigation/document-tab-bar/document-tab-bar.js +12 -63
- package/dist/components/navigation/document-tab-bar/document-tab-bar.js.map +1 -1
- package/dist/components/navigation/document-tab-bar/document-tab-bar.template.d.ts.map +1 -1
- package/dist/components/navigation/document-tab-bar/document-tab-bar.template.js +5 -7
- package/dist/components/navigation/document-tab-bar/document-tab-bar.template.js.map +1 -1
- package/dist/components/navigation/link/link.d.ts +2 -2
- package/dist/components/navigation/link/link.d.ts.map +1 -1
- package/dist/components/navigation/link/link.js +2 -2
- package/dist/components/navigation/link/link.js.map +1 -1
- package/dist/components/navigation/menu-bar/menu-bar.d.ts +11 -17
- package/dist/components/navigation/menu-bar/menu-bar.d.ts.map +1 -1
- package/dist/components/navigation/menu-bar/menu-bar.js +44 -71
- package/dist/components/navigation/menu-bar/menu-bar.js.map +1 -1
- package/dist/components/navigation/menu-bar/menu-bar.template.js +2 -2
- package/dist/components/navigation/menu-bar-item/menu-bar-item.d.ts +2 -3
- package/dist/components/navigation/menu-bar-item/menu-bar-item.d.ts.map +1 -1
- package/dist/components/navigation/menu-bar-item/menu-bar-item.js +14 -30
- package/dist/components/navigation/menu-bar-item/menu-bar-item.js.map +1 -1
- package/dist/components/navigation/tab-bar/tab-bar.d.ts +8 -2
- package/dist/components/navigation/tab-bar/tab-bar.d.ts.map +1 -1
- package/dist/components/navigation/tab-bar/tab-bar.js +18 -4
- 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 +4 -2
- package/dist/components/navigation/tab-bar/tab-bar.template.js.map +1 -1
- package/dist/components/status-and-feedback/modal-dialog/modal-dialog.d.ts +2 -22
- package/dist/components/status-and-feedback/modal-dialog/modal-dialog.d.ts.map +1 -1
- package/dist/components/status-and-feedback/modal-dialog/modal-dialog.js +4 -124
- package/dist/components/status-and-feedback/modal-dialog/modal-dialog.js.map +1 -1
- package/dist/components/status-and-feedback/modal-dialog/modal-dialog.template.d.ts.map +1 -1
- package/dist/components/status-and-feedback/modal-dialog/modal-dialog.template.js +5 -3
- package/dist/components/status-and-feedback/modal-dialog/modal-dialog.template.js.map +1 -1
- package/dist/nldd.min.js +855 -851
- package/dist/types/react.d.ts +96 -6
- package/dist/types/vue.d.ts +182 -9
- package/dist/utilities/choice-group.d.ts +91 -0
- package/dist/utilities/choice-group.d.ts.map +1 -0
- package/dist/utilities/choice-group.js +135 -0
- package/dist/utilities/choice-group.js.map +1 -0
- package/dist/utilities/deep-active-element.d.ts +6 -0
- package/dist/utilities/deep-active-element.d.ts.map +1 -0
- package/dist/utilities/deep-active-element.js +11 -0
- package/dist/utilities/deep-active-element.js.map +1 -0
- package/dist/utilities/dev-rules.generated.js +931 -931
- package/dist/utilities/dev-rules.generated.js.map +1 -1
- package/dist/utilities/form-associated-mixin.d.ts +21 -5
- package/dist/utilities/form-associated-mixin.d.ts.map +1 -1
- package/dist/utilities/form-associated-mixin.js +86 -5
- package/dist/utilities/form-associated-mixin.js.map +1 -1
- package/dist/utilities/interest-intent.d.ts +63 -0
- package/dist/utilities/interest-intent.d.ts.map +1 -0
- package/dist/utilities/interest-intent.js +139 -0
- package/dist/utilities/interest-intent.js.map +1 -0
- package/dist/utilities/{interest-controller.d.ts → interest-invoker.d.ts} +5 -14
- package/dist/utilities/interest-invoker.d.ts.map +1 -0
- package/dist/utilities/{interest-controller.js → interest-invoker.js} +39 -97
- package/dist/utilities/interest-invoker.js.map +1 -0
- package/dist/utilities/modal-overlay.d.ts +73 -0
- package/dist/utilities/modal-overlay.d.ts.map +1 -0
- package/dist/utilities/modal-overlay.js +219 -0
- package/dist/utilities/modal-overlay.js.map +1 -0
- package/dist/utilities/overflow-menu.d.ts +97 -0
- package/dist/utilities/overflow-menu.d.ts.map +1 -0
- package/dist/utilities/overflow-menu.js +209 -0
- package/dist/utilities/overflow-menu.js.map +1 -0
- package/dist/utilities/overlay-invoker.d.ts +185 -0
- package/dist/utilities/overlay-invoker.d.ts.map +1 -0
- package/dist/utilities/overlay-invoker.js +326 -0
- package/dist/utilities/overlay-invoker.js.map +1 -0
- package/dist/utilities/page-section-mixin.d.ts +11 -0
- package/dist/utilities/page-section-mixin.d.ts.map +1 -1
- package/dist/utilities/page-section-mixin.js +11 -0
- package/dist/utilities/page-section-mixin.js.map +1 -1
- package/dist/utilities/return-focus.d.ts +0 -2
- package/dist/utilities/return-focus.d.ts.map +1 -1
- package/dist/utilities/return-focus.js +1 -7
- package/dist/utilities/return-focus.js.map +1 -1
- package/dist/utilities/with-translations.d.ts +3 -0
- package/dist/utilities/with-translations.d.ts.map +1 -1
- package/dist/utilities/with-translations.js +3 -0
- package/dist/utilities/with-translations.js.map +1 -1
- package/lint/data.generated.json +1 -1
- package/lint/engine.js +4 -114
- package/lint/fix.js +53 -136
- package/lint/frontends.js +68 -6
- package/lint/linter.js +1 -0
- package/lint/main.js +21 -123
- package/lint/project.js +31 -0
- package/lint/rule-compiler.js +289 -0
- package/lint/session.js +127 -0
- package/lint/tree.js +46 -0
- package/package.json +3 -1
- package/dist/cdn/chunks/checkbox-group-CC72cq-P.js +0 -103
- package/dist/cdn/chunks/form-associated-mixin-BtStDDYA.js +0 -73
- package/dist/cdn/chunks/open-when-rendered-CW_2_WUZ.js +0 -20
- package/dist/cdn/chunks/popover-target-B25dxnmt.js +0 -10
- package/dist/cdn/chunks/popup-anchor-controller-VZw0bXf2.js +0 -30
- package/dist/cdn/chunks/radio-button-group-D_OezDhB.js +0 -124
- package/dist/components/actions/toolbar/toolbar.overflow-menu.d.ts +0 -52
- package/dist/components/actions/toolbar/toolbar.overflow-menu.d.ts.map +0 -1
- package/dist/components/actions/toolbar/toolbar.overflow-menu.js +0 -105
- package/dist/components/actions/toolbar/toolbar.overflow-menu.js.map +0 -1
- package/dist/utilities/interest-controller.d.ts.map +0 -1
- package/dist/utilities/interest-controller.js.map +0 -1
- package/dist/utilities/open-when-rendered.d.ts +0 -21
- package/dist/utilities/open-when-rendered.d.ts.map +0 -1
- package/dist/utilities/open-when-rendered.js +0 -30
- package/dist/utilities/open-when-rendered.js.map +0 -1
- package/dist/utilities/popover-target.d.ts +0 -25
- package/dist/utilities/popover-target.d.ts.map +0 -1
- package/dist/utilities/popover-target.js +0 -48
- package/dist/utilities/popover-target.js.map +0 -1
- package/dist/utilities/popup-anchor-controller.d.ts +0 -63
- package/dist/utilities/popup-anchor-controller.d.ts.map +0 -1
- package/dist/utilities/popup-anchor-controller.js +0 -72
- package/dist/utilities/popup-anchor-controller.js.map +0 -1
|
@@ -0,0 +1,326 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The one place that knows how a control opens an overlay (`nldd-menu`,
|
|
3
|
+
* `nldd-popover`): which overlay it is, where it stands, and how a press turns
|
|
4
|
+
* into open or close.
|
|
5
|
+
*
|
|
6
|
+
* The delicate part is the pointerdown. The browser light-dismisses an open
|
|
7
|
+
* auto popover on pointerdown, before the click lands, so a click handler that
|
|
8
|
+
* only sees "the overlay is closed" opens again what the same gesture just
|
|
9
|
+
* closed (the "flashes closed then reopens" bug). The invoker takes a snapshot
|
|
10
|
+
* on pointerdown, and the click reads it. A manual popover (the bottom sheet of
|
|
11
|
+
* nldd-popover on a small screen) is not dismissed by the press, so there the
|
|
12
|
+
* click closes it.
|
|
13
|
+
*
|
|
14
|
+
* Every control that opens an overlay goes through here: a button with an
|
|
15
|
+
* overlay in its `popup` slot, a term, a token, a menu bar item, the picker
|
|
16
|
+
* button of a combo box. What differs between them is configuration: where the
|
|
17
|
+
* overlay comes from, what it anchors to, and, for a control that does more
|
|
18
|
+
* than open and close, its own open and close.
|
|
19
|
+
*/
|
|
20
|
+
const OVERLAY_SELECTOR = 'nldd-menu, nldd-popover';
|
|
21
|
+
export function isOverlayOpen(overlay) {
|
|
22
|
+
return overlay.invokerIsOpen ? overlay.invokerIsOpen() : overlay.matches(':popover-open');
|
|
23
|
+
}
|
|
24
|
+
/** A manual popover stays open on a press outside it, its invoker included. */
|
|
25
|
+
function isLightDismissed(overlay) {
|
|
26
|
+
return overlay.getAttribute('popover') !== 'manual';
|
|
27
|
+
}
|
|
28
|
+
export class OverlayInvoker {
|
|
29
|
+
constructor(host, options = {}) {
|
|
30
|
+
this._overlay = null;
|
|
31
|
+
this._wasOpenOnPointerdown = false;
|
|
32
|
+
/** Bind to a slot's `slotchange`: adopts the first `nldd-menu` or
|
|
33
|
+
* `nldd-popover` in it. Flattened, so a component can forward its own slot
|
|
34
|
+
* into this one (nldd-split-button hands its popup to the chevron). */
|
|
35
|
+
this.handleSlotChange = (event) => {
|
|
36
|
+
const slot = event.target;
|
|
37
|
+
const overlay = slot.assignedElements({ flatten: true }).find((el) => el.matches(OVERLAY_SELECTOR));
|
|
38
|
+
this.setOverlay(overlay ?? null);
|
|
39
|
+
};
|
|
40
|
+
/** Bind to the trigger's `pointerdown`. Covers mouse, touch and pen. A press
|
|
41
|
+
* inside the overlay is not a press on the trigger, even where the overlay
|
|
42
|
+
* sits inside it (a menu in a menu bar item). */
|
|
43
|
+
this.handlePointerdown = (event) => {
|
|
44
|
+
const overlay = this._overlay;
|
|
45
|
+
if (!overlay || event?.composedPath().includes(overlay)) {
|
|
46
|
+
this._wasOpenOnPointerdown = false;
|
|
47
|
+
return;
|
|
48
|
+
}
|
|
49
|
+
this._wasOpenOnPointerdown = this._isOpenFor(overlay) && isLightDismissed(overlay) && !overlay.invokerPressReopens?.();
|
|
50
|
+
};
|
|
51
|
+
this._anchorFor = options.anchorFor ?? (() => host);
|
|
52
|
+
this._options = options;
|
|
53
|
+
}
|
|
54
|
+
/** The overlay this control opens, or null. */
|
|
55
|
+
get overlay() {
|
|
56
|
+
return this._overlay;
|
|
57
|
+
}
|
|
58
|
+
/** Whether the overlay is open for this control. */
|
|
59
|
+
get isOpen() {
|
|
60
|
+
return this._overlay ? this._isOpenFor(this._overlay) : false;
|
|
61
|
+
}
|
|
62
|
+
_isOpenFor(overlay) {
|
|
63
|
+
return this._options.isOpen ? this._options.isOpen(overlay) : isOverlayOpen(overlay);
|
|
64
|
+
}
|
|
65
|
+
/** Adopt an overlay (or none). Lets go of the previous one first: left
|
|
66
|
+
* anchored, a removed overlay keeps positioning against this control and
|
|
67
|
+
* writing its state onto it, and the pair can never be collected. */
|
|
68
|
+
setOverlay(overlay) {
|
|
69
|
+
if (overlay === this._overlay)
|
|
70
|
+
return;
|
|
71
|
+
const previous = this._overlay;
|
|
72
|
+
if (previous && previous.anchorElement === this._anchorFor())
|
|
73
|
+
previous.anchorElement = null;
|
|
74
|
+
this._overlay = overlay;
|
|
75
|
+
this._wasOpenOnPointerdown = false;
|
|
76
|
+
this.anchor();
|
|
77
|
+
this._options.onChange?.(overlay, previous);
|
|
78
|
+
}
|
|
79
|
+
/** (Re-)anchor the overlay. Call once the anchor target exists when it
|
|
80
|
+
* resolves later than the overlay. */
|
|
81
|
+
anchor() {
|
|
82
|
+
const target = this._anchorFor();
|
|
83
|
+
if (this._overlay && target && this._overlay.anchorElement !== target)
|
|
84
|
+
this._overlay.anchorElement = target;
|
|
85
|
+
}
|
|
86
|
+
/**
|
|
87
|
+
* Call from the trigger's click handler: opens the overlay, or closes it.
|
|
88
|
+
* Returns true when there is an overlay, so the click is spent: a popup
|
|
89
|
+
* control neither submits a form nor navigates.
|
|
90
|
+
*
|
|
91
|
+
* Only a pointer-driven click (detail > 0) has a pointerdown before it. A
|
|
92
|
+
* keyboard click ignores the snapshot, which could be left over from a
|
|
93
|
+
* gesture that ended without a click (a drag off the control, a scroll).
|
|
94
|
+
*/
|
|
95
|
+
handleClick(event) {
|
|
96
|
+
const overlay = this._overlay;
|
|
97
|
+
const closedByPress = event.detail > 0 && this._wasOpenOnPointerdown;
|
|
98
|
+
this._wasOpenOnPointerdown = false;
|
|
99
|
+
if (!overlay)
|
|
100
|
+
return false;
|
|
101
|
+
overlay.invokerGestureEnd?.();
|
|
102
|
+
if (closedByPress)
|
|
103
|
+
return true;
|
|
104
|
+
if (this._isOpenFor(overlay))
|
|
105
|
+
this.close();
|
|
106
|
+
else
|
|
107
|
+
this.open();
|
|
108
|
+
return true;
|
|
109
|
+
}
|
|
110
|
+
/** Opens the overlay, unless it is open already. */
|
|
111
|
+
open() {
|
|
112
|
+
const overlay = this._overlay;
|
|
113
|
+
if (!overlay || this._isOpenFor(overlay))
|
|
114
|
+
return;
|
|
115
|
+
this.anchor();
|
|
116
|
+
if (this._options.open)
|
|
117
|
+
this._options.open(overlay);
|
|
118
|
+
else if (overlay.invokerOpen)
|
|
119
|
+
overlay.invokerOpen();
|
|
120
|
+
else
|
|
121
|
+
overlay.showPopover();
|
|
122
|
+
}
|
|
123
|
+
/** Closes the overlay, unless it is closed already. */
|
|
124
|
+
close() {
|
|
125
|
+
const overlay = this._overlay;
|
|
126
|
+
if (!overlay || !this._isOpenFor(overlay))
|
|
127
|
+
return;
|
|
128
|
+
if (this._options.close)
|
|
129
|
+
this._options.close(overlay);
|
|
130
|
+
else if (overlay.invokerClose)
|
|
131
|
+
overlay.invokerClose();
|
|
132
|
+
else
|
|
133
|
+
overlay.hidePopover();
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
/**
|
|
137
|
+
* Whether `trigger` opens `overlay` as a native popover invoker
|
|
138
|
+
* (`popovertarget` or `popoverTargetElement`). The browser then toggles it as
|
|
139
|
+
* the click's default action, and no script should toggle it again.
|
|
140
|
+
*/
|
|
141
|
+
export function invokesNatively(trigger, overlay) {
|
|
142
|
+
const named = trigger.getAttribute('popovertarget') ?? trigger.popovertarget;
|
|
143
|
+
if (named && overlay.id && named === overlay.id)
|
|
144
|
+
return true;
|
|
145
|
+
return trigger.popoverTargetElement === overlay;
|
|
146
|
+
}
|
|
147
|
+
/**
|
|
148
|
+
* Makes an element outside any design-system control the invoker of
|
|
149
|
+
* `overlay`: a plain `<button>` that an overlay names with `anchor="id"`.
|
|
150
|
+
* Listens on the document, so the element may come and go, and calls the
|
|
151
|
+
* invoker for presses that land on it and not in the overlay. A trigger that
|
|
152
|
+
* is a native invoker of the overlay is left to the browser.
|
|
153
|
+
*
|
|
154
|
+
* Returns the function that stops listening.
|
|
155
|
+
*/
|
|
156
|
+
export function watchTrigger(invoker, trigger) {
|
|
157
|
+
const landsOnTrigger = (event) => {
|
|
158
|
+
const overlay = invoker.overlay;
|
|
159
|
+
const element = trigger();
|
|
160
|
+
if (!overlay || !element)
|
|
161
|
+
return false;
|
|
162
|
+
const path = event.composedPath();
|
|
163
|
+
return path.includes(element) && !path.includes(overlay) && !invokesNatively(element, overlay);
|
|
164
|
+
};
|
|
165
|
+
// Capture, so the snapshot is taken before the browser's light dismiss.
|
|
166
|
+
const onPointerdown = (event) => {
|
|
167
|
+
if (landsOnTrigger(event))
|
|
168
|
+
invoker.handlePointerdown(event);
|
|
169
|
+
};
|
|
170
|
+
// A click the app called off opens nothing, as with popovertarget.
|
|
171
|
+
const onClick = (event) => {
|
|
172
|
+
if (!event.defaultPrevented && landsOnTrigger(event))
|
|
173
|
+
invoker.handleClick(event);
|
|
174
|
+
};
|
|
175
|
+
document.addEventListener('pointerdown', onPointerdown, true);
|
|
176
|
+
document.addEventListener('click', onClick);
|
|
177
|
+
return () => {
|
|
178
|
+
document.removeEventListener('pointerdown', onPointerdown, true);
|
|
179
|
+
document.removeEventListener('click', onClick);
|
|
180
|
+
};
|
|
181
|
+
}
|
|
182
|
+
/**
|
|
183
|
+
* Writes an overlay's state onto the element it hangs off: expanded, the
|
|
184
|
+
* popup type and the link to the overlay. The overlay says what it is and
|
|
185
|
+
* whether it is open; this decides how a trigger shows that.
|
|
186
|
+
*
|
|
187
|
+
* `aria-haspopup` is set from the first sync, not from the first open: it is
|
|
188
|
+
* a static property of the trigger ("this button opens a menu"), and a screen
|
|
189
|
+
* reader user tabbing a row of identical buttons needs it before anything was
|
|
190
|
+
* opened. A popup type the consumer chose is left alone; one this wrote follows
|
|
191
|
+
* the overlay when it changes.
|
|
192
|
+
*/
|
|
193
|
+
export class TriggerAria {
|
|
194
|
+
constructor(_options) {
|
|
195
|
+
this._options = _options;
|
|
196
|
+
this._trigger = null;
|
|
197
|
+
this._seededPopupType = null;
|
|
198
|
+
/** The `aria-haspopup` this wrote on a plain trigger, so it takes back only its own. */
|
|
199
|
+
this._seededHasPopup = null;
|
|
200
|
+
}
|
|
201
|
+
sync(trigger, state) {
|
|
202
|
+
if (trigger !== this._trigger)
|
|
203
|
+
this._release(state.controls);
|
|
204
|
+
this._trigger = trigger;
|
|
205
|
+
const element = this._trigger;
|
|
206
|
+
if (!element)
|
|
207
|
+
return;
|
|
208
|
+
const { attributes } = this._options;
|
|
209
|
+
// A control renders its own aria-expanded from the property, on the real
|
|
210
|
+
// inner button, and flips its expanded visual with it. An attribute on
|
|
211
|
+
// the host would land on the custom element and be gone after a render.
|
|
212
|
+
if ('expanded' in element)
|
|
213
|
+
element.expanded = state.open;
|
|
214
|
+
else if (attributes)
|
|
215
|
+
element.setAttribute('aria-expanded', state.open ? 'true' : 'false');
|
|
216
|
+
if ('popupType' in element) {
|
|
217
|
+
if (!element.popupType || element.popupType === this._seededPopupType) {
|
|
218
|
+
element.popupType = state.popupType;
|
|
219
|
+
this._seededPopupType = state.popupType || null;
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
else if (attributes && state.popupType && !element.hasAttribute('aria-haspopup')) {
|
|
223
|
+
element.setAttribute('aria-haspopup', state.popupType);
|
|
224
|
+
this._seededHasPopup = state.popupType;
|
|
225
|
+
}
|
|
226
|
+
if (attributes && state.controls && !element.hasAttribute('aria-controls')) {
|
|
227
|
+
element.setAttribute('aria-controls', state.controls);
|
|
228
|
+
}
|
|
229
|
+
if (this._options.popoverTargetAction && 'popoverTargetAction' in element) {
|
|
230
|
+
element.popoverTargetAction = state.open ? 'hide' : 'show';
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
/**
|
|
234
|
+
* Takes everything off the trigger, for an overlay that leaves the page. In
|
|
235
|
+
* a single-page app the overlay can go while its trigger stays, and an
|
|
236
|
+
* `aria-controls` pointing at an element that no longer exists fails WCAG
|
|
237
|
+
* 4.1.2. A control that keeps its expanded state is reset too, or it stays
|
|
238
|
+
* stuck in its expanded look.
|
|
239
|
+
*/
|
|
240
|
+
clear(trigger, controls) {
|
|
241
|
+
const element = (trigger ?? this._trigger);
|
|
242
|
+
this._trigger = null;
|
|
243
|
+
this._seededPopupType = null;
|
|
244
|
+
this._seededHasPopup = null;
|
|
245
|
+
if (!element)
|
|
246
|
+
return;
|
|
247
|
+
if ('expanded' in element)
|
|
248
|
+
element.expanded = false;
|
|
249
|
+
if (!this._options.attributes)
|
|
250
|
+
return;
|
|
251
|
+
element.removeAttribute('aria-expanded');
|
|
252
|
+
element.removeAttribute('aria-haspopup');
|
|
253
|
+
if (controls && element.getAttribute('aria-controls') === controls)
|
|
254
|
+
element.removeAttribute('aria-controls');
|
|
255
|
+
}
|
|
256
|
+
/** Takes the state off a trigger the overlay leaves, so it does not linger
|
|
257
|
+
* as a toggle for a screen reader, nor in its expanded look. */
|
|
258
|
+
_release(controls) {
|
|
259
|
+
const previous = this._trigger;
|
|
260
|
+
const hasPopup = this._seededHasPopup;
|
|
261
|
+
this._trigger = null;
|
|
262
|
+
this._seededPopupType = null;
|
|
263
|
+
this._seededHasPopup = null;
|
|
264
|
+
if (!previous)
|
|
265
|
+
return;
|
|
266
|
+
if ('expanded' in previous) {
|
|
267
|
+
previous.expanded = false;
|
|
268
|
+
return;
|
|
269
|
+
}
|
|
270
|
+
if (!this._options.attributes)
|
|
271
|
+
return;
|
|
272
|
+
previous.removeAttribute('aria-expanded');
|
|
273
|
+
if (hasPopup && previous.getAttribute('aria-haspopup') === hasPopup)
|
|
274
|
+
previous.removeAttribute('aria-haspopup');
|
|
275
|
+
if (controls && previous.getAttribute('aria-controls') === controls)
|
|
276
|
+
previous.removeAttribute('aria-controls');
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
/**
|
|
280
|
+
* The popover a component's inner button invokes, from `popovertarget` or
|
|
281
|
+
* `popoverTargetElement` on the host.
|
|
282
|
+
*
|
|
283
|
+
* An id written on the inner button is looked up in the component's own
|
|
284
|
+
* shadow root, where the popover never is, so the button opened nothing. The
|
|
285
|
+
* id is looked up here in the tree of the host instead, and the inner button
|
|
286
|
+
* gets the element. The element wins when both are set.
|
|
287
|
+
*
|
|
288
|
+
* Look it up again on click: a popover rendered after the button is not there
|
|
289
|
+
* yet on the button's first render.
|
|
290
|
+
*/
|
|
291
|
+
export function popoverTargetOf(host, id, element) {
|
|
292
|
+
if (element)
|
|
293
|
+
return element;
|
|
294
|
+
if (!id)
|
|
295
|
+
return null;
|
|
296
|
+
const root = host.getRootNode();
|
|
297
|
+
return root.getElementById?.(id) ?? null;
|
|
298
|
+
}
|
|
299
|
+
/** The overlay each host anchored, so it can let go again. */
|
|
300
|
+
const anchoredBy = new WeakMap();
|
|
301
|
+
/**
|
|
302
|
+
* Positions an `nldd-menu` or `nldd-popover` that `popovertarget` points at
|
|
303
|
+
* against the control that opens it, so the overlay needs no `anchor` of its
|
|
304
|
+
* own. The browser already opens and closes it; this adds where it stands and
|
|
305
|
+
* the ARIA link back to the control, as a slotted overlay gets.
|
|
306
|
+
*
|
|
307
|
+
* An overlay with an `anchor` id, or anchored to another element, is
|
|
308
|
+
* left alone: someone chose where it goes. Pass `null` to let go, as on
|
|
309
|
+
* disconnect or when `popovertarget` changes.
|
|
310
|
+
*/
|
|
311
|
+
export function anchorPopoverTarget(host, target) {
|
|
312
|
+
const previous = anchoredBy.get(host);
|
|
313
|
+
const next = target?.matches('nldd-menu, nldd-popover') && !target.getAttribute('anchor')
|
|
314
|
+
? target
|
|
315
|
+
: null;
|
|
316
|
+
if (previous && previous !== next && previous.anchorElement === host)
|
|
317
|
+
previous.anchorElement = null;
|
|
318
|
+
if (next && (next.anchorElement === null || next.anchorElement === host)) {
|
|
319
|
+
next.anchorElement = host;
|
|
320
|
+
anchoredBy.set(host, next);
|
|
321
|
+
}
|
|
322
|
+
else {
|
|
323
|
+
anchoredBy.delete(host);
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
//# sourceMappingURL=overlay-invoker.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"overlay-invoker.js","sourceRoot":"","sources":["../../src/utilities/overlay-invoker.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAoBH,MAAM,gBAAgB,GAAG,yBAAyB,CAAC;AAoBnD,MAAM,UAAU,aAAa,CAAC,OAAyB;IACtD,OAAO,OAAO,CAAC,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,aAAa,EAAE,CAAC,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,eAAe,CAAC,CAAC;AAC3F,CAAC;AAED,+EAA+E;AAC/E,SAAS,gBAAgB,CAAC,OAAgB;IACzC,OAAO,OAAO,CAAC,YAAY,CAAC,SAAS,CAAC,KAAK,QAAQ,CAAC;AACrD,CAAC;AAED,MAAM,OAAO,cAAc;IAM1B,YAAY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AI,IAAI,CAAC;AAC1C,CAAC;AAID,8DAA8D;AAC9D,MAAM,UAAU,GAAG,IAAI,OAAO,EAA8B,CAAC;AAE7D;;;;;;;;;GASG;AACH,MAAM,UAAU,mBAAmB,CAAC,IAAa,EAAE,MAAsB;IACxE,MAAM,QAAQ,GAAG,UAAU,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IACtC,MAAM,IAAI,GAAG,MAAM,EAAE,OAAO,CAAC,yBAAyB,CAAC,IAAI,CAAC,MAAM,CAAC,YAAY,CAAC,QAAQ,CAAC;QACxF,CAAC,CAAC,MAA2B;QAC7B,CAAC,CAAC,IAAI,CAAC;IACR,IAAI,QAAQ,IAAI,QAAQ,KAAK,IAAI,IAAI,QAAQ,CAAC,aAAa,KAAK,IAAI;QAAE,QAAQ,CAAC,aAAa,GAAG,IAAI,CAAC;IACpG,IAAI,IAAI,IAAI,CAAC,IAAI,CAAC,aAAa,KAAK,IAAI,IAAI,IAAI,CAAC,aAAa,KAAK,IAAI,CAAC,EAAE,CAAC;QAC1E,IAAI,CAAC,aAAa,GAAG,IAAI,CAAC;QAC1B,UAAU,CAAC,GAAG,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;IAC5B,CAAC;SAAM,CAAC;QACP,UAAU,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;IACzB,CAAC;AACF,CAAC"}
|
|
@@ -37,6 +37,17 @@ export declare const pageSectionBackgroundStyles: import("lit").CSSResult;
|
|
|
37
37
|
* ```ts
|
|
38
38
|
* class NLDDSimpleSection extends PageSectionMixin(LitElement) { … }
|
|
39
39
|
* ```
|
|
40
|
+
*
|
|
41
|
+
* @mixin PageSectionMixin
|
|
42
|
+
* @attr sm-padding-block - Top and bottom padding in the sm range; wins there over the padding attributes without a breakpoint.
|
|
43
|
+
* @attr sm-padding-top - Top padding in the sm range; wins there over `sm-padding-block` and the padding attributes without a breakpoint.
|
|
44
|
+
* @attr sm-padding-bottom - Bottom padding in the sm range; wins there over `sm-padding-block` and the padding attributes without a breakpoint.
|
|
45
|
+
* @attr md-padding-block - Top and bottom padding in the md range; wins there over the padding attributes without a breakpoint.
|
|
46
|
+
* @attr md-padding-top - Top padding in the md range; wins there over `md-padding-block` and the padding attributes without a breakpoint.
|
|
47
|
+
* @attr md-padding-bottom - Bottom padding in the md range; wins there over `md-padding-block` and the padding attributes without a breakpoint.
|
|
48
|
+
* @attr lg-padding-block - Top and bottom padding in the lg range; wins there over the padding attributes without a breakpoint.
|
|
49
|
+
* @attr lg-padding-top - Top padding in the lg range; wins there over `lg-padding-block` and the padding attributes without a breakpoint.
|
|
50
|
+
* @attr lg-padding-bottom - Bottom padding in the lg range; wins there over `lg-padding-block` and the padding attributes without a breakpoint.
|
|
40
51
|
*/
|
|
41
52
|
export declare function PageSectionMixin<TBase extends Constructor<LitElement>>(Base: TBase): TBase & Constructor<LitElement & {
|
|
42
53
|
background: PageSectionBackground;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"page-section-mixin.d.ts","sourceRoot":"","sources":["../../src/utilities/page-section-mixin.ts"],"names":[],"mappings":"AAEA,OAAO,EAAO,UAAU,EAAuB,MAAM,KAAK,CAAC;AAG3D,KAAK,WAAW,CAAC,CAAC,GAAG,UAAU,IAAI,KAAK,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC;AAE7D,MAAM,MAAM,qBAAqB,GAAG,SAAS,GAAG,MAAM,GAAG,QAAQ,CAAC;AAClE,MAAM,MAAM,kBAAkB,GAC3B,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAC9D,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAEhE;;;;GAIG;AACH,eAAO,MAAM,2BAA2B,yBAevC,CAAC;AAoBF
|
|
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B,CAAC;IACpC,YAAY,CAAC,EAAE,kBAAkB,CAAC;IAClC,eAAe,CAAC,EAAE,kBAAkB,CAAC;IACrC,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,OAAO,CAAC;IACd,aAAa,CAAC,CAAC,EAAE,KAAK,GAAG,IAAI,CAAC;CAC9B,CACD,CACF"}
|
|
@@ -76,6 +76,17 @@ const PADDING_KEYS = [
|
|
|
76
76
|
* ```ts
|
|
77
77
|
* class NLDDSimpleSection extends PageSectionMixin(LitElement) { … }
|
|
78
78
|
* ```
|
|
79
|
+
*
|
|
80
|
+
* @mixin PageSectionMixin
|
|
81
|
+
* @attr sm-padding-block - Top and bottom padding in the sm range; wins there over the padding attributes without a breakpoint.
|
|
82
|
+
* @attr sm-padding-top - Top padding in the sm range; wins there over `sm-padding-block` and the padding attributes without a breakpoint.
|
|
83
|
+
* @attr sm-padding-bottom - Bottom padding in the sm range; wins there over `sm-padding-block` and the padding attributes without a breakpoint.
|
|
84
|
+
* @attr md-padding-block - Top and bottom padding in the md range; wins there over the padding attributes without a breakpoint.
|
|
85
|
+
* @attr md-padding-top - Top padding in the md range; wins there over `md-padding-block` and the padding attributes without a breakpoint.
|
|
86
|
+
* @attr md-padding-bottom - Bottom padding in the md range; wins there over `md-padding-block` and the padding attributes without a breakpoint.
|
|
87
|
+
* @attr lg-padding-block - Top and bottom padding in the lg range; wins there over the padding attributes without a breakpoint.
|
|
88
|
+
* @attr lg-padding-top - Top padding in the lg range; wins there over `lg-padding-block` and the padding attributes without a breakpoint.
|
|
89
|
+
* @attr lg-padding-bottom - Bottom padding in the lg range; wins there over `lg-padding-block` and the padding attributes without a breakpoint.
|
|
79
90
|
*/
|
|
80
91
|
export function PageSectionMixin(Base) {
|
|
81
92
|
class WithPageSection extends Base {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"page-section-mixin.js","sourceRoot":"","sources":["../../src/utilities/page-section-mixin.ts"],"names":[],"mappings":";;;;;;A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,IAAI,EAAE,SAAS,EAAE,kBAAkB,EAAE,CAAC;2DACrC;IAEpC;QADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,gBAAgB,EAAE,CAAC;yDACrC;IAElC;QADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,mBAAmB,EAAE,CAAC;4DACrC;IAGrC;QADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,kBAAkB,EAAE,CAAC;2DACrC;IAEpC;QADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,gBAAgB,EAAE,CAAC;yDACrC;IAElC;QADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,mBAAmB,EAAE,CAAC;4DACrC;IAGrC;QADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,kBAAkB,EAAE,CAAC;2DACrC;IAEpC;QADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,gBAAgB,EAAE,CAAC;yDACrC;IAElC;QADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,mBAAmB,EAAE,CAAC;4DACrC;IAiDtC,OAAO,eAoBL,CAAC;AACJ,CAAC"}
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
/** The element that really holds focus, inside any shadow roots. */
|
|
2
|
-
export declare function deepActiveElement(): HTMLElement | null;
|
|
3
1
|
/**
|
|
4
2
|
* Hands focus back to `target` once `overlay` (a popover, menu, sheet or window)
|
|
5
3
|
* has closed. Call it after the close, with the element that had focus when the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"return-focus.d.ts","sourceRoot":"","sources":["../../src/utilities/return-focus.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"return-focus.d.ts","sourceRoot":"","sources":["../../src/utilities/return-focus.ts"],"names":[],"mappings":"AAGA;;;;;;;;;;;;;;GAcG;AACH,wBAAgB,WAAW,CAAC,MAAM,EAAE,WAAW,GAAG,IAAI,GAAG,SAAS,EAAE,OAAO,EAAE,OAAO,GAAG,IAAI,CAQ1F;AAED;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,WAAW,GAAG,IAAI,CAc1D;AAED;;;;;GAKG;AACH,wBAAgB,WAAW,CAAC,SAAS,EAAE,OAAO,GAAG,OAAO,CAGvD;AAkBD;;;;;;;;;;;GAWG;AACH,qBAAa,WAAW;IACvB,OAAO,CAAC,OAAO,CAA4B;IAC3C,OAAO,CAAC,SAAS,CAA4B;IAE7C;;;;;+EAK2E;IAC3E,QAAQ,CAAC,QAAQ,CAAC,EAAE,OAAO,GAAG,IAAI,GAAG,IAAI;IAMzC,kDAAkD;IAClD,OAAO,CAAC,OAAO,EAAE,OAAO,GAAG,IAAI;CAM/B"}
|
|
@@ -1,11 +1,5 @@
|
|
|
1
|
+
import { deepActiveElement } from './deep-active-element.js';
|
|
1
2
|
import { isPointerMode } from './input-modality.js';
|
|
2
|
-
/** The element that really holds focus, inside any shadow roots. */
|
|
3
|
-
export function deepActiveElement() {
|
|
4
|
-
let el = document.activeElement;
|
|
5
|
-
while (el?.shadowRoot?.activeElement)
|
|
6
|
-
el = el.shadowRoot.activeElement;
|
|
7
|
-
return el;
|
|
8
|
-
}
|
|
9
3
|
/**
|
|
10
4
|
* Hands focus back to `target` once `overlay` (a popover, menu, sheet or window)
|
|
11
5
|
* has closed. Call it after the close, with the element that had focus when the
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"return-focus.js","sourceRoot":"","sources":["../../src/utilities/return-focus.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"return-focus.js","sourceRoot":"","sources":["../../src/utilities/return-focus.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAC7D,OAAO,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEpD;;;;;;;;;;;;;;GAcG;AACH,MAAM,UAAU,WAAW,CAAC,MAAsC,EAAE,OAAgB;IACnF,IAAI,CAAC,MAAM,IAAI,MAAM,KAAK,QAAQ,CAAC,IAAI,IAAI,CAAC,MAAM,CAAC,WAAW;QAAE,OAAO;IACvE,2EAA2E;IAC3E,+DAA+D;IAC/D,0EAA0E;IAC1E,iFAAiF;IACjF,IAAI,CAAC,WAAW,CAAC,OAAO,CAAC,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC;QAAE,OAAO;IAC1D,gBAAgB,CAAC,MAAM,CAAC,CAAC;AAC1B,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,gBAAgB,CAAC,MAAmB;IACnD,wDAAwD;IACxD,IAAI,CAAC,aAAa,EAAE,IAAI,WAAW,CAAC,MAAM,CAAC,EAAE,CAAC;QAC7C,MAAM,CAAC,KAAK,EAAE,CAAC;QACf,OAAO;IACR,CAAC;IACD,MAAM,MAAM,GAAG,iBAAiB,EAAE,CAAC;IACnC,IAAI,MAAM,IAAI,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE,CAAC;QACxC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,gBAAgB,CAAC,IAAI,WAAW,CAAC,MAAM,CAAC;YAAE,OAAO;QACrE,MAAM,CAAC,IAAI,EAAE,CAAC;IACf,CAAC;IACD,0EAA0E;IAC1E,MAAM,MAAM,GAAiB,EAAE,YAAY,EAAE,KAAK,EAAE,CAAC;IACrD,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;AACtB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;QACnC,IAAI,CAAC,SAAS,GAAI,QAA2C,IAAI,IAAI,CAAC;QACtE,IAAI,CAAC,OAAO,GAAG,MAAM,IAAI,MAAM,KAAK,QAAQ,CAAC,IAAI,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC;IAC7E,CAAC;IAED,kDAAkD;IAClD,OAAO,CAAC,OAAgB;QACvB,MAAM,MAAM,GAAG,IAAI,CAAC,OAAO,EAAE,WAAW,CAAC,CAAC,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC;QACzE,IAAI,CAAC,OAAO,GAAG,IAAI,CAAC;QACpB,IAAI,CAAC,SAAS,GAAG,IAAI,CAAC;QACtB,WAAW,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IAC9B,CAAC;CACD"}
|
|
@@ -18,6 +18,9 @@ type Constructor<T = object> = abstract new (...args: any[]) => T;
|
|
|
18
18
|
* }
|
|
19
19
|
* }
|
|
20
20
|
* ```
|
|
21
|
+
*
|
|
22
|
+
* @mixin withTranslations
|
|
23
|
+
* @attr {object} translations - Override translation keys; unset keys fall back to Dutch
|
|
21
24
|
*/
|
|
22
25
|
export declare function withTranslations<T extends Record<string, string>>(Base: Constructor<LitElement> & typeof LitElement, defaults: T): Constructor<LitElement & {
|
|
23
26
|
translations: Partial<T>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"with-translations.d.ts","sourceRoot":"","sources":["../../src/utilities/with-translations.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,KAAK,CAAC;AAIjC,KAAK,WAAW,CAAC,CAAC,GAAG,MAAM,IAAI,QAAQ,MAAM,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC;AAElE
|
|
1
|
+
{"version":3,"file":"with-translations.d.ts","sourceRoot":"","sources":["../../src/utilities/with-translations.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,KAAK,CAAC;AAIjC,KAAK,WAAW,CAAC,CAAC,GAAG,MAAM,IAAI,QAAQ,MAAM,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAC;AAElE;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,gBAAgB,CAAC,CAAC,SAAS,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAChE,IAAI,EAAE,WAAW,CAAC,UAAU,CAAC,GAAG,OAAO,UAAU,EACjD,QAAQ,EAAE,CAAC,GAY4B,WAAW,CAAC,UAAU,GAAG;IAC/D,YAAY,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC;IACzB,EAAE,CAAC,GAAG,EAAE,MAAM,CAAC,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC,GAAG,MAAM,CAAC;CACjE,CAAC,GAAG,OAAO,UAAU,CACtB"}
|
|
@@ -24,6 +24,9 @@ import { translate } from './translations.js';
|
|
|
24
24
|
* }
|
|
25
25
|
* }
|
|
26
26
|
* ```
|
|
27
|
+
*
|
|
28
|
+
* @mixin withTranslations
|
|
29
|
+
* @attr {object} translations - Override translation keys; unset keys fall back to Dutch
|
|
27
30
|
*/
|
|
28
31
|
export function withTranslations(Base, defaults) {
|
|
29
32
|
class TranslationsMixin extends Base {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"with-translations.js","sourceRoot":"","sources":["../../src/utilities/with-translations.ts"],"names":[],"mappings":";;;;;;AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAI9C
|
|
1
|
+
{"version":3,"file":"with-translations.js","sourceRoot":"","sources":["../../src/utilities/with-translations.ts"],"names":[],"mappings":";;;;;;AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAC;AAI9C;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAM,UAAU,gBAAgB,CAC/B,IAAiD,EACjD,QAAW;IAEX,MAAM,iBAAkB,SAAQ,IAAI;QAApC;;YAEC,iBAAY,GAAe,EAAE,CAAC;QAM/B,CAAC;QAJA,gBAAgB;QAChB,EAAE,CAAC,GAAY,EAAE,IAAsC;YACtD,OAAO,SAAS,CAAC,IAAI,CAAC,YAAY,EAAE,QAAQ,EAAE,GAAG,EAAE,IAAI,CAAC,CAAC;QAC1D,CAAC;KACD;IANA;QADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;2DACG;IAQ/B,OAAO,iBAGe,CAAC;AACxB,CAAC"}
|