@nldd/design-system 0.25.1 → 0.26.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 +2845 -79
- package/dist/cdn/autoloader.js +141 -140
- package/dist/cdn/chunks/{accordion-B7KdKJno.js → accordion-DA4IlxS5.js} +4 -4
- package/dist/cdn/chunks/{accordion-item-CVy8Apta.js → accordion-item-Ca1o93cq.js} +9 -7
- package/dist/cdn/chunks/{activity-indicator-CpJVlX6K.js → activity-indicator-Cj4H0Mbz.js} +5 -5
- package/dist/cdn/chunks/{admonition-C89WHJ9a.js → admonition-CdZSoO8O.js} +9 -7
- package/dist/cdn/chunks/{avatar-Bf0OfAtQ.js → avatar-Dhqn-Dmv.js} +6 -6
- package/dist/cdn/chunks/{avatar-group-BeBAv2wB.js → avatar-group-B017eF-u.js} +15 -15
- package/dist/cdn/chunks/{badge-C43FvgkK.js → badge-Bep5B0_g.js} +5 -5
- package/dist/cdn/chunks/{banner-OWK0gwFb.js → banner-DGpIXuE2.js} +7 -7
- package/dist/cdn/chunks/{bar-split-view-Dj1WycIW.js → bar-split-view-CKwJxd3e.js} +5 -5
- package/dist/cdn/chunks/{blockquote-D_5MxcSi.js → blockquote-ChMgaOuI.js} +3 -3
- package/dist/cdn/chunks/{box-BUoxiA7b.js → box-BRmziG-6.js} +3 -3
- package/dist/cdn/chunks/{breadcrumbs-DXxJTACL.js → breadcrumbs-BeVO8bkQ.js} +5 -5
- package/dist/cdn/chunks/{button-bar-BSt-QQRG.js → button-bar-CLxOdalJ.js} +3 -3
- package/dist/cdn/chunks/{button-DpKyquzm.js → button-cHBkq_s7.js} +9 -9
- package/dist/cdn/chunks/{button-group-D5QJWJzh.js → button-group-BIvKtEIX.js} +2 -2
- package/dist/cdn/chunks/{card-Cz4f-dCf.js → card-B5gp9Zly.js} +8 -6
- package/dist/cdn/chunks/{cell-zFw2V9wD.js → cell-D4Nrd5Z9.js} +6 -6
- package/dist/cdn/chunks/{checkbox-BDp3O8Nc.js → checkbox-CeLTJhAc.js} +4 -4
- package/dist/cdn/chunks/checkbox-field-C8cU8fuf.js +244 -0
- package/dist/cdn/chunks/checkbox-group-CC72cq-P.js +103 -0
- package/dist/cdn/chunks/{class-map-C7ao595e.js → class-map-xzscTu4B.js} +1 -1
- package/dist/cdn/chunks/{code-editor-Chm9EG_v.js → code-editor-BNhlXTSl.js} +10 -10
- package/dist/cdn/chunks/{code-viewer-DX322d7w.js → code-viewer-D_JwouYO.js} +35 -35
- package/dist/cdn/chunks/{codemirror-input-BLMJQbHq.js → codemirror-input-DJ0wgYrc.js} +368 -368
- package/dist/cdn/chunks/{collection-Bf8HoSki.js → collection-BXvz_OtU.js} +8 -8
- package/dist/cdn/chunks/{combo-box-VuU_F54v.js → combo-box-8kbmoStb.js} +10 -9
- package/dist/cdn/chunks/{container-qVTgmbpz.js → container-Dq-2uHd5.js} +2 -2
- package/dist/cdn/chunks/{custom-element-C5yyaCZS.js → custom-element-DeaCQ2NP.js} +1 -1
- package/dist/cdn/chunks/{date-field-By9Q8151.js → date-field-CQg1_73u.js} +13 -13
- package/dist/cdn/chunks/{date-picker-DtA4PXCh.js → date-picker-CTMxGOiA.js} +10 -10
- package/dist/cdn/chunks/{decorate-CkbtFnic.js → decorate-CCYde2ES.js} +1 -1
- package/dist/cdn/chunks/described-by-mixin-BYFim7aO.js +62 -0
- package/dist/cdn/chunks/{description-cell-D2INE8A3.js → description-cell-GcVeCz2_.js} +6 -6
- package/dist/cdn/chunks/{dev-checks-UHHli7gE.js → dev-checks-CSlbfDuF.js} +43 -5
- package/dist/cdn/chunks/directive-helpers-DgaADFyY.js +24 -0
- package/dist/cdn/chunks/{dist-BG0xnVUi.js → dist-1OQdP4ho.js} +10 -10
- package/dist/cdn/chunks/{dist-C-T4uKP1.js → dist-5vPsM2aV.js} +8 -8
- package/dist/cdn/chunks/{dist-VXOtAJ-m.js → dist-B23jHvJ5.js} +15 -15
- package/dist/cdn/chunks/{dist-Cm51DQO4.js → dist-CNy2sPTt.js} +6 -6
- package/dist/cdn/chunks/{dist-B1pwN_VD.js → dist-CcpLhc4y.js} +7 -7
- package/dist/cdn/chunks/{dist-Ce38ZA7b.js → dist-CyDpBAaD.js} +7 -7
- package/dist/cdn/chunks/{dist-pCih3zzc.js → dist-D4SViUJx.js} +21 -21
- package/dist/cdn/chunks/{dist-qo8avphr.js → dist-DBxjWahH.js} +4 -4
- package/dist/cdn/chunks/{dist-BzfFo9Yu.js → dist-DLtwMUDc.js} +18 -18
- package/dist/cdn/chunks/{dist-Dg3ySzj7.js → dist-Da_liXcd.js} +124 -124
- package/dist/cdn/chunks/{dist-zxb4QZZG.js → dist-VCymi0hs.js} +250 -250
- package/dist/cdn/chunks/{divider-Cv_vyHvw.js → divider-8XD3xTbl.js} +2 -2
- package/dist/cdn/chunks/{document-tab-bar-CdOxr8KC.js → document-tab-bar-RBAmckHS.js} +9 -9
- package/dist/cdn/chunks/{dropdown-DC9J6k0P.js → dropdown-DVlxPcjr.js} +5 -5
- package/dist/cdn/chunks/field-button-controller-yvICuXoE.js +26 -0
- package/dist/cdn/chunks/{file-field-CsrTk4uk.js → file-field-BrHnFplX.js} +12 -12
- package/dist/cdn/chunks/{form-ClOD1OKh.js → form-DGHeGEIr.js} +1 -1
- package/dist/cdn/chunks/{form-actions-CwaXGj43.js → form-actions-CHwWKfMM.js} +2 -2
- package/dist/cdn/chunks/{form-field-LoX9v2Pa.js → form-field-CdTSI-8h.js} +21 -16
- package/dist/cdn/chunks/{form-section-i6piyKuy.js → form-section-CjECOIiZ.js} +1 -1
- package/dist/cdn/chunks/{full-bleed-section-6aAfCnez.js → full-bleed-section-CQgq4iGQ.js} +3 -3
- package/dist/cdn/chunks/{hero-CTQAayXT.js → hero-DhdcYt2N.js} +4 -4
- package/dist/cdn/chunks/{icon-button-DuEiOOoc.js → icon-button-DT_Bi4Ac.js} +17 -13
- package/dist/cdn/chunks/{icon-cell-uZkR3hZx.js → icon-cell-C-qrZAlN.js} +5 -5
- package/dist/cdn/chunks/{icon-B5kHyCz2.js → icon-qpmEfU9B.js} +2 -2
- package/dist/cdn/chunks/{identity-DR6DMjke.js → identity-DFmvuPkl.js} +6 -6
- package/dist/cdn/chunks/{if-defined-B7fJBsUt.js → if-defined-BINBE69I.js} +1 -1
- package/dist/cdn/chunks/{image-CuBUo_MQ.js → image-B4M3h1xJ.js} +8 -8
- package/dist/cdn/chunks/{inline-dialog-CZNkWJIA.js → inline-dialog-L-NvjANF.js} +6 -6
- package/dist/cdn/chunks/{just-in-time-education-qwg9hTDX.js → just-in-time-education-CWplH4r9.js} +5 -5
- package/dist/cdn/chunks/{kanban-Bkg-nZmX.js → kanban-B6Wa-2aM.js} +5 -5
- package/dist/cdn/chunks/{kanban-column-C8iRyRNY.js → kanban-column-D2-Xq79_.js} +4 -4
- package/dist/cdn/chunks/{keyboard-shortcut-Rq5IHU-e.js → keyboard-shortcut-Ci95olxF.js} +118 -47
- package/dist/cdn/chunks/{languages-DLHsACpp.js → languages-C9AGuuSS.js} +43 -32
- package/dist/cdn/chunks/{link-CgjFwaHP.js → link-BJB2a_fG.js} +36 -28
- package/dist/cdn/chunks/{link-group-5W0GAmTq.js → link-group-aNoedLZo.js} +2 -2
- package/dist/cdn/chunks/{list-BASqIKtP.js → list-CZWX62tH.js} +8 -8
- package/dist/cdn/chunks/{list-item-DTcPysIP.js → list-item-DHzsbK_S.js} +5 -5
- package/dist/cdn/chunks/{list-item-segment-CRw0y4kg.js → list-item-segment-CHLlU9Gg.js} +3 -3
- package/dist/cdn/chunks/{menu-CYILGTpB.js → menu-NGpB1SKq.js} +42 -22
- package/dist/cdn/chunks/{menu-bar-CL566HmJ.js → menu-bar-CJazkmY7.js} +6 -6
- package/dist/cdn/chunks/{menu-bar-item-C6OrUu_4.js → menu-bar-item-CSqXWNKE.js} +6 -6
- package/dist/cdn/chunks/{menu-divider-BtU9eBSb.js → menu-divider-Cn1hTpcM.js} +3 -3
- package/dist/cdn/chunks/{menu-group-r2TvdqJB.js → menu-group-C71K1Vmv.js} +4 -4
- package/dist/cdn/chunks/{menu-item-CS45jTLu.js → menu-item-TqBlQfI2.js} +4 -4
- package/dist/cdn/chunks/{menu.template-CF8Iau1s.js → menu.template-DthELYky.js} +21 -16
- package/dist/cdn/chunks/{modal-dialog-C9NBq8TO.js → modal-dialog-0V2HsrJC.js} +4 -4
- package/dist/cdn/chunks/{multi-line-text-field-BkxV0vqA.js → multi-line-text-field-BV4uUDoK.js} +60 -34
- package/dist/cdn/chunks/{navigation-split-view-DNrQYkg7.js → navigation-split-view-tPhkxEVD.js} +4 -4
- package/dist/cdn/chunks/{notification-Dzpy9hCc.js → notification-CZccv6qx.js} +6 -6
- package/dist/cdn/chunks/{number-field-BJCUe-bI.js → number-field-4R2blHda.js} +8 -8
- package/dist/cdn/chunks/{one-half-one-half-section-Ctw8ri5v.js → one-half-one-half-section-h2fLPQfP.js} +3 -3
- package/dist/cdn/chunks/{one-third-two-thirds-section-DxUUH8lS.js → one-third-two-thirds-section-mqUAH5lK.js} +3 -3
- package/dist/cdn/chunks/{one-time-code-field-DGDyqIMd.js → one-time-code-field-Bf_qymKd.js} +8 -7
- package/dist/cdn/chunks/{page-BpavFPML.js → page-Kipfvmi6.js} +4 -4
- package/dist/cdn/chunks/{page-footer-CVqmyulx.js → page-footer-DxE966Oe.js} +4 -4
- package/dist/cdn/chunks/{page-section-mixin-BHg-Wre9.js → page-section-mixin-DpF9JDpd.js} +3 -3
- package/dist/cdn/chunks/{pagination-BGZYq-eO.js → pagination-DUFFhaU8.js} +6 -6
- package/dist/cdn/chunks/{password-field-BIFfLAls.js → password-field-DdYAVmF3.js} +9 -9
- package/dist/cdn/chunks/{popover-TCW20ibN.js → popover-CRHxyhGx.js} +6 -6
- package/dist/cdn/chunks/{progress-bar-C4bLuJBa.js → progress-bar-BuYsjmSo.js} +7 -7
- package/dist/cdn/chunks/{progress-circle-BePtt89f.js → progress-circle-Cvu1bfNG.js} +7 -7
- package/dist/cdn/chunks/{radio-button-CLiuwjA1.js → radio-button-B_4AxWDx.js} +3 -3
- package/dist/cdn/chunks/{radio-button-field-BPva1mUv.js → radio-button-field-D7jIg6Oi.js} +6 -6
- package/dist/cdn/chunks/{radio-button-group-Z5s4obz6.js → radio-button-group-D_OezDhB.js} +12 -6
- package/dist/cdn/chunks/{render-marked-C3ypoEZM.js → render-marked-CIuiSS_8.js} +1 -1
- package/dist/cdn/chunks/{reorder-handle-cell-BB9b4T_d.js → reorder-handle-cell-DNPaZjSC.js} +4 -4
- package/dist/cdn/chunks/{reorder-handle-mixin-DBjNe6Rl.js → reorder-handle-mixin-CgvWq4fF.js} +2 -2
- package/dist/cdn/chunks/repeat-DfVuWl6o.js +57 -0
- package/dist/cdn/chunks/{return-focus-BzZWhXhc.js → return-focus-D0fF2hjd.js} +1 -1
- package/dist/cdn/chunks/{rich-text-DTxHo8E_.js → rich-text-CVHlMQY6.js} +3 -3
- package/dist/cdn/chunks/{row-header-mixin-BcwoEgu7.js → row-header-mixin-B25JK2B3.js} +2 -2
- package/dist/cdn/chunks/{scroll-fade-Dul0IfE1.js → scroll-fade-Dv57rTww.js} +2 -2
- package/dist/cdn/chunks/{search-field-BeZN7S8J.js → search-field-hmD_DXbG.js} +11 -11
- package/dist/cdn/chunks/{segmented-control-Dzu8xoqB.js → segmented-control-e8e-jYSw.js} +6 -6
- package/dist/cdn/chunks/{shadow-resets-Dlq8Oecv.js → shadow-resets-CRdvf-Ei.js} +2 -2
- package/dist/cdn/chunks/{sheet-DaQpfAep.js → sheet-D09y3J45.js} +4 -4
- package/dist/cdn/chunks/{shell-DSNgonKU.js → shell-CV3gooGg.js} +3 -3
- package/dist/cdn/chunks/{side-by-side-split-view-DhGbcDrs.js → side-by-side-split-view-Ckz1C9zk.js} +4 -4
- package/dist/cdn/chunks/{sidebar-section-BlJmPb9C.js → sidebar-section-CdyD-x4t.js} +7 -7
- package/dist/cdn/chunks/{simple-section-CYiTEFqN.js → simple-section-CEf38rBZ.js} +3 -3
- package/dist/cdn/chunks/{skip-link-CReOb-Ci.js → skip-link-DMRhATWw.js} +4 -4
- package/dist/cdn/chunks/{slider-DUEGol_V.js → slider-Db3FPiP6.js} +8 -8
- package/dist/cdn/chunks/{spacer-CPmyJDQq.js → spacer-BPFIYueo.js} +2 -2
- package/dist/cdn/chunks/{spacer-cell-DJEv0v6s.js → spacer-cell-kITa3CDV.js} +4 -4
- package/dist/cdn/chunks/{split-button-B3vfYAdy.js → split-button-CJs9-Nha.js} +7 -7
- package/dist/cdn/chunks/{split-view-divider-pSUpnEPX.js → split-view-divider-lHlM1Ss8.js} +2 -2
- package/dist/cdn/chunks/{split-view-pane-J1RVr_w1.js → split-view-pane-DlsbZtyo.js} +3 -3
- package/dist/cdn/chunks/{stacked-split-view-B67fT-Ch.js → stacked-split-view-uRSVhrMd.js} +4 -4
- package/dist/cdn/chunks/{static-html-BT4LOKbV.js → static-html-BahSPV_4.js} +1 -1
- package/dist/cdn/chunks/{status-bar-CGXqgNOf.js → status-bar-DCJLVpsW.js} +4 -4
- package/dist/cdn/chunks/{step-bar-DdsA2Egs.js → step-bar-CRR2jiyo.js} +6 -6
- package/dist/cdn/chunks/{step-cell-DsTAgMCx.js → step-cell-CbtKxJNJ.js} +5 -5
- package/dist/cdn/chunks/{stepper-DPqXiLQr.js → stepper-Con1_CnB.js} +6 -6
- package/dist/cdn/chunks/{style-map-B7yv7Y8k.js → style-map-uOwLerwV.js} +1 -1
- package/dist/cdn/chunks/{swatch-picker-D9QZmbNN.js → swatch-picker-Bqn0eaC9.js} +5 -5
- package/dist/cdn/chunks/{switch-CE2glvZQ.js → switch-CMQcLEBJ.js} +4 -4
- package/dist/cdn/chunks/{switch-field-Dr2LovXc.js → switch-field-D9kWq4Kw.js} +5 -5
- package/dist/cdn/chunks/{tab-bar-DYZbToZB.js → tab-bar-DXzyZI3V.js} +8 -8
- package/dist/cdn/chunks/{table-DoQMJbSg.js → table-CWACLpHx.js} +5 -5
- package/dist/cdn/chunks/{tag-DOX5nY-Z.js → tag-Bo4yJbtF.js} +4 -4
- package/dist/cdn/chunks/{term-CxGzPnhq.js → term-CQ379ZbN.js} +12 -12
- package/dist/cdn/chunks/{text-Dqe0uTK7.js → text-D-dFoj6N.js} +3 -3
- package/dist/cdn/chunks/{text-cell-ByGrujhK.js → text-cell-Be1hStxp.js} +8 -8
- package/dist/cdn/chunks/{text-editor-DT9oWQCT.js → text-editor-BjzQEBWm.js} +1372 -904
- package/dist/cdn/chunks/{text-field-DKz5IRAU.js → text-field-DA8nirp6.js} +47 -65
- package/dist/cdn/chunks/{time-field-Dh7nTwNc.js → time-field-Dd_TxJuf.js} +15 -15
- package/dist/cdn/chunks/{time-picker-Bp-l4JfF.js → time-picker-B0-rv1qp.js} +5 -5
- package/dist/cdn/chunks/{title-CdIWXNtc.js → title-DOoPdG_i.js} +4 -4
- package/dist/cdn/chunks/{title-cell-DNbP8l_x.js → title-cell-BzCNOMGr.js} +8 -8
- package/dist/cdn/chunks/{toggle-button-CPMxB3gN.js → toggle-button-9PbDHviQ.js} +60 -42
- package/dist/cdn/chunks/{toggle-button-group-ERWVyRX5.js → toggle-button-group-C-H-xp0M.js} +11 -5
- package/dist/cdn/chunks/{token-CG8dR3EH.js → token-CMKFC3gz.js} +5 -5
- package/dist/cdn/chunks/{token-field-B8wqHKan.js → token-field-D4-XHfnG.js} +11 -11
- package/dist/cdn/chunks/{toolbar-item-xJEewchW.js → toolbar-item-ZYoyKOyy.js} +3 -3
- package/dist/cdn/chunks/{toolbar-title-C08aG67Y.js → toolbar-title-FKtQ8ZC4.js} +4 -4
- package/dist/cdn/chunks/{toolbar-CiZoecHm.js → toolbar-z9OhEE5l.js} +8 -8
- package/dist/cdn/chunks/{toolbar.styles-DmAHodW4.js → toolbar.styles-DDjpdCHV.js} +3 -3
- package/dist/cdn/chunks/{tooltip-660R32cn.js → tooltip-BvRNYRo3.js} +5 -5
- package/dist/cdn/chunks/{top-navigation-bar-B1HFShH8.js → top-navigation-bar-BHPQntER.js} +17 -17
- package/dist/cdn/chunks/{top-title-bar-BLZZd0Iu.js → top-title-bar-BVjegLlh.js} +6 -6
- package/dist/cdn/chunks/{translations-CF08wvn-.js → translations-cJjO6nQV.js} +1 -1
- package/dist/cdn/chunks/{two-thirds-one-third-section-Dqz7UoSH.js → two-thirds-one-third-section-BdBHQuXc.js} +3 -3
- package/dist/cdn/chunks/{validation-list-D-bzOl5H.js → validation-list-5E3-3_95.js} +3 -3
- package/dist/cdn/chunks/{visibility-mixin-X9d6wHvR.js → visibility-mixin-DvRe3O8t.js} +2 -2
- package/dist/cdn/chunks/{visually-hidden-Cew5_ldu.js → visually-hidden-F85D_HcR.js} +2 -2
- package/dist/cdn/chunks/{window-DSgA26_c.js → window-CabW35M1.js} +5 -5
- package/dist/cdn/chunks/{with-translations-Boc5Daaj.js → with-translations-BHDG37HJ.js} +3 -3
- package/dist/components/actions/button/button.d.ts +1 -1
- package/dist/components/actions/button/button.js +1 -1
- package/dist/components/actions/button/button.template.js +1 -1
- package/dist/components/actions/icon-button/icon-button.d.ts +5 -1
- package/dist/components/actions/icon-button/icon-button.d.ts.map +1 -1
- package/dist/components/actions/icon-button/icon-button.js +10 -5
- package/dist/components/actions/icon-button/icon-button.js.map +1 -1
- package/dist/components/actions/menu/menu-item.d.ts +1 -1
- package/dist/components/actions/menu/menu-item.js +1 -1
- package/dist/components/actions/menu/menu.d.ts +13 -1
- package/dist/components/actions/menu/menu.d.ts.map +1 -1
- package/dist/components/actions/menu/menu.js +53 -2
- package/dist/components/actions/menu/menu.js.map +1 -1
- package/dist/components/actions/menu/menu.pointer.d.ts +6 -2
- package/dist/components/actions/menu/menu.pointer.d.ts.map +1 -1
- package/dist/components/actions/menu/menu.pointer.js +15 -5
- package/dist/components/actions/menu/menu.pointer.js.map +1 -1
- package/dist/components/actions/menu/menu.styles.d.ts.map +1 -1
- package/dist/components/actions/menu/menu.styles.js +16 -11
- package/dist/components/actions/menu/menu.styles.js.map +1 -1
- package/dist/components/actions/menu/menu.template.js +1 -1
- package/dist/components/content/accordion/accordion-item.styles.d.ts.map +1 -1
- package/dist/components/content/accordion/accordion-item.styles.js +5 -3
- package/dist/components/content/accordion/accordion-item.styles.js.map +1 -1
- package/dist/components/content/admonition/admonition.styles.d.ts.map +1 -1
- package/dist/components/content/admonition/admonition.styles.js +5 -3
- package/dist/components/content/admonition/admonition.styles.js.map +1 -1
- package/dist/components/content/icon/icon.d.ts +1 -1
- package/dist/components/content/icon/icon.js +1 -1
- package/dist/components/content/keyboard-shortcut/keyboard-shortcut.d.ts +16 -9
- package/dist/components/content/keyboard-shortcut/keyboard-shortcut.d.ts.map +1 -1
- package/dist/components/content/keyboard-shortcut/keyboard-shortcut.js +18 -12
- package/dist/components/content/keyboard-shortcut/keyboard-shortcut.js.map +1 -1
- package/dist/components/content/keyboard-shortcut/keyboard-shortcut.styles.d.ts.map +1 -1
- package/dist/components/content/keyboard-shortcut/keyboard-shortcut.styles.js +26 -12
- package/dist/components/content/keyboard-shortcut/keyboard-shortcut.styles.js.map +1 -1
- package/dist/components/content/keyboard-shortcut/keyboard-shortcut.template.d.ts.map +1 -1
- package/dist/components/content/keyboard-shortcut/keyboard-shortcut.template.js +12 -3
- package/dist/components/content/keyboard-shortcut/keyboard-shortcut.template.js.map +1 -1
- package/dist/components/content/tooltip/tooltip.template.js +1 -1
- package/dist/components/forms/form-field/form-field.d.ts +3 -1
- package/dist/components/forms/form-field/form-field.d.ts.map +1 -1
- package/dist/components/forms/form-field/form-field.js +14 -3
- package/dist/components/forms/form-field/form-field.js.map +1 -1
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.d.ts.map +1 -1
- package/dist/components/index.js +1 -0
- package/dist/components/index.js.map +1 -1
- package/dist/components/inputs/checkbox-field/checkbox-field.d.ts +44 -2
- package/dist/components/inputs/checkbox-field/checkbox-field.d.ts.map +1 -1
- package/dist/components/inputs/checkbox-field/checkbox-field.js +129 -9
- package/dist/components/inputs/checkbox-field/checkbox-field.js.map +1 -1
- package/dist/components/inputs/checkbox-field/checkbox-field.styles.d.ts.map +1 -1
- package/dist/components/inputs/checkbox-field/checkbox-field.styles.js +6 -0
- package/dist/components/inputs/checkbox-field/checkbox-field.styles.js.map +1 -1
- package/dist/components/inputs/checkbox-field/checkbox-field.template.d.ts.map +1 -1
- package/dist/components/inputs/checkbox-field/checkbox-field.template.js +18 -4
- package/dist/components/inputs/checkbox-field/checkbox-field.template.js.map +1 -1
- package/dist/components/inputs/checkbox-group/checkbox-group.d.ts +77 -0
- package/dist/components/inputs/checkbox-group/checkbox-group.d.ts.map +1 -0
- package/dist/components/inputs/checkbox-group/checkbox-group.js +188 -0
- package/dist/components/inputs/checkbox-group/checkbox-group.js.map +1 -0
- package/dist/components/inputs/checkbox-group/checkbox-group.styles.d.ts +2 -0
- package/dist/components/inputs/checkbox-group/checkbox-group.styles.d.ts.map +1 -0
- package/dist/components/inputs/checkbox-group/checkbox-group.styles.js +28 -0
- package/dist/components/inputs/checkbox-group/checkbox-group.styles.js.map +1 -0
- package/dist/components/inputs/checkbox-group/checkbox-group.template.d.ts +4 -0
- package/dist/components/inputs/checkbox-group/checkbox-group.template.d.ts.map +1 -0
- package/dist/components/inputs/checkbox-group/checkbox-group.template.js +9 -0
- package/dist/components/inputs/checkbox-group/checkbox-group.template.js.map +1 -0
- package/dist/components/inputs/combo-box/combo-box.d.ts +3 -0
- package/dist/components/inputs/combo-box/combo-box.d.ts.map +1 -1
- package/dist/components/inputs/combo-box/combo-box.js +3 -0
- package/dist/components/inputs/combo-box/combo-box.js.map +1 -1
- package/dist/components/inputs/combo-box/combo-box.styles.d.ts.map +1 -1
- package/dist/components/inputs/combo-box/combo-box.styles.js +1 -0
- package/dist/components/inputs/combo-box/combo-box.styles.js.map +1 -1
- package/dist/components/inputs/date-field/date-field.d.ts +3 -0
- package/dist/components/inputs/date-field/date-field.d.ts.map +1 -1
- package/dist/components/inputs/date-field/date-field.js +3 -0
- package/dist/components/inputs/date-field/date-field.js.map +1 -1
- package/dist/components/inputs/dropdown/dropdown.d.ts +4 -0
- package/dist/components/inputs/dropdown/dropdown.d.ts.map +1 -1
- package/dist/components/inputs/dropdown/dropdown.js +4 -0
- package/dist/components/inputs/dropdown/dropdown.js.map +1 -1
- package/dist/components/inputs/multi-line-text-field/multi-line-text-field.d.ts +8 -0
- 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 +8 -0
- package/dist/components/inputs/multi-line-text-field/multi-line-text-field.js.map +1 -1
- package/dist/components/inputs/multi-line-text-field/multi-line-text-field.styles.d.ts.map +1 -1
- package/dist/components/inputs/multi-line-text-field/multi-line-text-field.styles.js +24 -2
- package/dist/components/inputs/multi-line-text-field/multi-line-text-field.styles.js.map +1 -1
- package/dist/components/inputs/multi-line-text-field/multi-line-text-field.template.d.ts.map +1 -1
- package/dist/components/inputs/multi-line-text-field/multi-line-text-field.template.js +3 -0
- package/dist/components/inputs/multi-line-text-field/multi-line-text-field.template.js.map +1 -1
- package/dist/components/inputs/number-field/number-field.d.ts +3 -0
- package/dist/components/inputs/number-field/number-field.d.ts.map +1 -1
- package/dist/components/inputs/number-field/number-field.js +3 -0
- 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 +3 -0
- 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 +3 -0
- package/dist/components/inputs/one-time-code-field/one-time-code-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 +1 -0
- package/dist/components/inputs/one-time-code-field/one-time-code-field.styles.js.map +1 -1
- package/dist/components/inputs/password-field/password-field.d.ts +3 -0
- package/dist/components/inputs/password-field/password-field.d.ts.map +1 -1
- package/dist/components/inputs/password-field/password-field.js +3 -0
- package/dist/components/inputs/password-field/password-field.js.map +1 -1
- package/dist/components/inputs/password-field/password-field.styles.js +1 -1
- 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 +5 -0
- 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 +5 -0
- 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 +19 -9
- package/dist/components/inputs/radio-button-group/radio-button-group.js.map +1 -1
- package/dist/components/inputs/search-field/search-field.d.ts +3 -0
- package/dist/components/inputs/search-field/search-field.d.ts.map +1 -1
- package/dist/components/inputs/search-field/search-field.js +3 -0
- package/dist/components/inputs/search-field/search-field.js.map +1 -1
- package/dist/components/inputs/search-field/search-field.styles.js +1 -1
- package/dist/components/inputs/text-editor/text-editor.clipboard.d.ts +5 -2
- package/dist/components/inputs/text-editor/text-editor.clipboard.d.ts.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.clipboard.js +23 -4
- package/dist/components/inputs/text-editor/text-editor.clipboard.js.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.code-copy.d.ts.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.code-copy.js +38 -18
- package/dist/components/inputs/text-editor/text-editor.code-copy.js.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.commands.d.ts +8 -6
- package/dist/components/inputs/text-editor/text-editor.commands.d.ts.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.commands.js +23 -9
- package/dist/components/inputs/text-editor/text-editor.commands.js.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.d.ts +26 -0
- package/dist/components/inputs/text-editor/text-editor.d.ts.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.js +165 -15
- package/dist/components/inputs/text-editor/text-editor.js.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.list-input.d.ts +17 -0
- package/dist/components/inputs/text-editor/text-editor.list-input.d.ts.map +1 -0
- package/dist/components/inputs/text-editor/text-editor.list-input.js +133 -0
- package/dist/components/inputs/text-editor/text-editor.list-input.js.map +1 -0
- package/dist/components/inputs/text-editor/text-editor.markdown.d.ts.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.markdown.js +28 -1
- package/dist/components/inputs/text-editor/text-editor.markdown.js.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.mentions.d.ts +4 -2
- package/dist/components/inputs/text-editor/text-editor.mentions.d.ts.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.mentions.js +9 -5
- package/dist/components/inputs/text-editor/text-editor.mentions.js.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.ordered-list.d.ts.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.ordered-list.js +89 -18
- package/dist/components/inputs/text-editor/text-editor.ordered-list.js.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.paste.d.ts +10 -0
- package/dist/components/inputs/text-editor/text-editor.paste.d.ts.map +1 -0
- package/dist/components/inputs/text-editor/text-editor.paste.js +116 -0
- package/dist/components/inputs/text-editor/text-editor.paste.js.map +1 -0
- package/dist/components/inputs/text-editor/text-editor.styles.d.ts.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.styles.js +49 -2
- package/dist/components/inputs/text-editor/text-editor.styles.js.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.template.d.ts +1 -1
- package/dist/components/inputs/text-editor/text-editor.template.d.ts.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.template.js +4 -3
- package/dist/components/inputs/text-editor/text-editor.template.js.map +1 -1
- package/dist/components/inputs/text-editor/text-editor.toolbar.d.ts +53 -0
- package/dist/components/inputs/text-editor/text-editor.toolbar.d.ts.map +1 -0
- package/dist/components/inputs/text-editor/text-editor.toolbar.js +302 -0
- package/dist/components/inputs/text-editor/text-editor.toolbar.js.map +1 -0
- package/dist/components/inputs/text-field/text-field.d.ts +7 -13
- package/dist/components/inputs/text-field/text-field.d.ts.map +1 -1
- package/dist/components/inputs/text-field/text-field.js +8 -50
- package/dist/components/inputs/text-field/text-field.js.map +1 -1
- package/dist/components/inputs/text-field/text-field.styles.d.ts.map +1 -1
- package/dist/components/inputs/text-field/text-field.styles.js +1 -2
- package/dist/components/inputs/text-field/text-field.styles.js.map +1 -1
- package/dist/components/inputs/text-field/text-field.template.js +2 -2
- package/dist/components/inputs/text-field/text-field.template.js.map +1 -1
- package/dist/components/inputs/time-field/time-field.d.ts +3 -0
- package/dist/components/inputs/time-field/time-field.d.ts.map +1 -1
- package/dist/components/inputs/time-field/time-field.js +3 -0
- package/dist/components/inputs/time-field/time-field.js.map +1 -1
- package/dist/components/inputs/toggle-button/toggle-button.d.ts +22 -2
- package/dist/components/inputs/toggle-button/toggle-button.d.ts.map +1 -1
- package/dist/components/inputs/toggle-button/toggle-button.js +53 -7
- package/dist/components/inputs/toggle-button/toggle-button.js.map +1 -1
- package/dist/components/inputs/toggle-button/toggle-button.styles.d.ts.map +1 -1
- package/dist/components/inputs/toggle-button/toggle-button.styles.js +3 -1
- package/dist/components/inputs/toggle-button/toggle-button.styles.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 +6 -2
- package/dist/components/inputs/toggle-button/toggle-button.template.js.map +1 -1
- package/dist/components/inputs/toggle-button-group/toggle-button-group.d.ts +6 -1
- 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 +20 -10
- package/dist/components/inputs/toggle-button-group/toggle-button-group.js.map +1 -1
- package/dist/components/inputs/token-field/token-field.d.ts +3 -0
- package/dist/components/inputs/token-field/token-field.d.ts.map +1 -1
- package/dist/components/inputs/token-field/token-field.js +3 -0
- package/dist/components/inputs/token-field/token-field.js.map +1 -1
- package/dist/components/layout/card/card.d.ts +2 -0
- package/dist/components/layout/card/card.d.ts.map +1 -1
- package/dist/components/layout/card/card.js +5 -2
- package/dist/components/layout/card/card.js.map +1 -1
- package/dist/components/navigation/link/link.d.ts +13 -3
- package/dist/components/navigation/link/link.d.ts.map +1 -1
- package/dist/components/navigation/link/link.js +25 -9
- package/dist/components/navigation/link/link.js.map +1 -1
- package/dist/components/status-and-feedback/step-bar/step-bar.styles.js +1 -1
- package/dist/css/dropdown.css +17 -0
- package/dist/css/global-open-font.css +1 -0
- package/dist/css/global.css +1 -0
- package/dist/css/rich-text.css +8 -2
- package/dist/css/variables.css +2 -1
- package/dist/nldd.min.js +941 -789
- package/dist/types/react.d.ts +151 -15
- package/dist/types/vue.d.ts +305 -45
- package/dist/utilities/autoloader.generated.d.ts.map +1 -1
- package/dist/utilities/autoloader.generated.js +1 -0
- package/dist/utilities/autoloader.generated.js.map +1 -1
- package/dist/utilities/codemirror/codemirror-element.d.ts +12 -1
- package/dist/utilities/codemirror/codemirror-element.d.ts.map +1 -1
- package/dist/utilities/codemirror/codemirror-element.js +23 -4
- package/dist/utilities/codemirror/codemirror-element.js.map +1 -1
- package/dist/utilities/codemirror/codemirror-input.d.ts +3 -0
- package/dist/utilities/codemirror/codemirror-input.d.ts.map +1 -1
- package/dist/utilities/codemirror/codemirror-input.js +14 -3
- package/dist/utilities/codemirror/codemirror-input.js.map +1 -1
- package/dist/utilities/described-by-mixin.d.ts +6 -0
- package/dist/utilities/described-by-mixin.d.ts.map +1 -1
- package/dist/utilities/described-by-mixin.js +81 -2
- package/dist/utilities/described-by-mixin.js.map +1 -1
- package/dist/utilities/dev-rules.generated.d.ts.map +1 -1
- package/dist/utilities/dev-rules.generated.js +46 -5
- package/dist/utilities/dev-rules.generated.js.map +1 -1
- package/dist/utilities/field-button-controller.d.ts +28 -0
- package/dist/utilities/field-button-controller.d.ts.map +1 -0
- package/dist/utilities/field-button-controller.js +56 -0
- package/dist/utilities/field-button-controller.js.map +1 -0
- package/dist/utilities/return-focus.d.ts.map +1 -1
- package/dist/utilities/return-focus.js +3 -0
- package/dist/utilities/return-focus.js.map +1 -1
- package/dist/utilities/shortcut.d.ts +14 -0
- package/dist/utilities/shortcut.d.ts.map +1 -1
- package/dist/utilities/shortcut.js +37 -1
- package/dist/utilities/shortcut.js.map +1 -1
- package/lint/data.generated.json +1 -1
- package/lint/linter.js +4 -1
- package/package.json +6 -2
- package/dist/cdn/chunks/checkbox-field-CSXV0prA.js +0 -162
- package/dist/cdn/chunks/described-by-mixin-DXC6jkCd.js +0 -35
- package/dist/cdn/chunks/repeat-s95Ixbpx.js +0 -76
|
@@ -9,6 +9,18 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
9
9
|
*
|
|
10
10
|
* A checkbox with an inline label for use in forms.
|
|
11
11
|
*
|
|
12
|
+
* Options that belong under this one are nldd-checkbox-fields of their own,
|
|
13
|
+
* each with `slot="children"`, as rows nest in nldd-list-item. They indent to
|
|
14
|
+
* line up with the label, and are a group named after this option. This
|
|
15
|
+
* checkbox then follows them: checked when all of them are, indeterminate
|
|
16
|
+
* when some are, and unchecked when none are. Checking or unchecking it does
|
|
17
|
+
* the same to every option under it that is not disabled, nor under a
|
|
18
|
+
* disabled one; those fire no `change` of their own then, so listen on this
|
|
19
|
+
* one or higher up. When a disabled option keeps it indeterminate and the
|
|
20
|
+
* rest are already checked, a click unchecks them instead. Its own `change`
|
|
21
|
+
* fires when they change its state, so a box further up follows too. In an
|
|
22
|
+
* nldd-checkbox-group, the options under it belong to the group as well.
|
|
23
|
+
*
|
|
12
24
|
* Form-associated: participates in native form submission under `name` with
|
|
13
25
|
* `value` when checked (the inner nldd-checkbox sits in the shadow root and
|
|
14
26
|
* never joins the consumer's form; the field submits on its behalf).
|
|
@@ -21,13 +33,15 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
21
33
|
* @attr {string} value - Value for form submission
|
|
22
34
|
* @attr {string} name - Name for form submission
|
|
23
35
|
* @attr {string} label - Label text for the checkbox
|
|
24
|
-
* @attr {boolean} required - Required state
|
|
36
|
+
* @attr {boolean} required - Required state. In an nldd-checkbox-group, set by the group, it asks for at least one checked box in the group, not for this one.
|
|
25
37
|
* @attr {boolean} invalid - Marks the control as invalid. Announced with aria-invalid; nothing is drawn for it.
|
|
26
38
|
*
|
|
39
|
+
* @slot children - nldd-checkbox-field elements with the options under this one.
|
|
40
|
+
*
|
|
27
41
|
* @fires change - When checked state changes; detail: { checked: boolean, value: string }
|
|
28
42
|
*/
|
|
29
43
|
import { LitElement } from 'lit';
|
|
30
|
-
import { property } from 'lit/decorators.js';
|
|
44
|
+
import { property, state } from 'lit/decorators.js';
|
|
31
45
|
import { customElement } from '../../../utilities/custom-element.js';
|
|
32
46
|
import { FormAssociated, uncheckedValidity } from '../../../utilities/form-associated-mixin.js';
|
|
33
47
|
import { checkboxFieldStyles } from './checkbox-field.styles.js';
|
|
@@ -50,6 +64,9 @@ let NLDDCheckboxField = class NLDDCheckboxField extends DescribedBy(FormAssociat
|
|
|
50
64
|
this.color = '';
|
|
51
65
|
this.label = '';
|
|
52
66
|
this.required = false;
|
|
67
|
+
/** Set by nldd-checkbox-group: whether any box in the group is checked,
|
|
68
|
+
* which is what `required` asks there. */
|
|
69
|
+
this._groupHasSelection = false;
|
|
53
70
|
/**
|
|
54
71
|
* Marks the control as invalid.
|
|
55
72
|
*
|
|
@@ -60,21 +77,115 @@ let NLDDCheckboxField = class NLDDCheckboxField extends DescribedBy(FormAssociat
|
|
|
60
77
|
* choosing not to show something is not a reason to keep quiet about it.
|
|
61
78
|
*/
|
|
62
79
|
this.invalid = false;
|
|
80
|
+
/** The options right under this one, not those further down. */
|
|
81
|
+
this._childFields = [];
|
|
82
|
+
/** A change of an option right under this one; one further down reaches
|
|
83
|
+
* this through the option it belongs to. */
|
|
84
|
+
this._handleChildChange = (e) => {
|
|
85
|
+
const target = e.target;
|
|
86
|
+
if (target === this || target.localName !== 'nldd-checkbox-field')
|
|
87
|
+
return;
|
|
88
|
+
if (!this._childFields.includes(target))
|
|
89
|
+
return;
|
|
90
|
+
this._followChildren(true);
|
|
91
|
+
};
|
|
92
|
+
}
|
|
93
|
+
/** In an nldd-checkbox-group, where `required` is about the group and no
|
|
94
|
+
* single box is announced as required. */
|
|
95
|
+
get _inGroup() {
|
|
96
|
+
return this._group !== null;
|
|
63
97
|
}
|
|
64
98
|
firstUpdated() {
|
|
65
99
|
this._initialChecked = this.checked;
|
|
66
100
|
}
|
|
101
|
+
connectedCallback() {
|
|
102
|
+
super.connectedCallback();
|
|
103
|
+
this.addEventListener('change', this._handleChildChange);
|
|
104
|
+
}
|
|
105
|
+
disconnectedCallback() {
|
|
106
|
+
super.disconnectedCallback();
|
|
107
|
+
this.removeEventListener('change', this._handleChildChange);
|
|
108
|
+
}
|
|
109
|
+
_handleChildrenSlotChange(e) {
|
|
110
|
+
const slot = e.target;
|
|
111
|
+
this._childFields = slot.assignedElements()
|
|
112
|
+
.filter((el) => el.localName === 'nldd-checkbox-field');
|
|
113
|
+
this._followChildren(false);
|
|
114
|
+
// The group sees only its own children arrive, not the options under them.
|
|
115
|
+
this._group?._onSlotChange();
|
|
116
|
+
}
|
|
117
|
+
/** The nldd-checkbox-group around this field, if any. */
|
|
118
|
+
get _group() {
|
|
119
|
+
return this.closest('nldd-checkbox-group');
|
|
120
|
+
}
|
|
121
|
+
/** Also when the app sets `checked` or a form resets it: the group answers
|
|
122
|
+
* `required` again, which it cannot see by itself. */
|
|
123
|
+
willUpdate(changed) {
|
|
124
|
+
super.willUpdate(changed);
|
|
125
|
+
if (this.hasUpdated && changed.has('checked'))
|
|
126
|
+
this._group?._optionChanged();
|
|
127
|
+
}
|
|
128
|
+
/** Checked when all options under this one are, indeterminate when some
|
|
129
|
+
* are, unchecked when none are. */
|
|
130
|
+
_followChildren(announce) {
|
|
131
|
+
const fields = this._childFields;
|
|
132
|
+
if (fields.length === 0)
|
|
133
|
+
return;
|
|
134
|
+
const all = fields.every((field) => field.checked);
|
|
135
|
+
const some = fields.some((field) => field.checked || field.indeterminate);
|
|
136
|
+
const indeterminate = !all && some;
|
|
137
|
+
if (all === this.checked && indeterminate === this.indeterminate)
|
|
138
|
+
return;
|
|
139
|
+
this.checked = all;
|
|
140
|
+
this.indeterminate = indeterminate;
|
|
141
|
+
this.commitFormValue();
|
|
142
|
+
if (announce)
|
|
143
|
+
this._dispatchChange();
|
|
144
|
+
}
|
|
145
|
+
/** Whether setting the options under this one would change any of them. */
|
|
146
|
+
_wouldChange(checked) {
|
|
147
|
+
return this._childFields.some((field) => !field.disabled && (field._childFields.length > 0
|
|
148
|
+
? field._wouldChange(checked)
|
|
149
|
+
: field.checked !== checked));
|
|
150
|
+
}
|
|
151
|
+
/** Gives every option under this one, at any depth, this state, except
|
|
152
|
+
* those that are disabled and everything under them. */
|
|
153
|
+
_setChildren(checked) {
|
|
154
|
+
if (this._childFields.length === 0)
|
|
155
|
+
return;
|
|
156
|
+
this._childFields.forEach((field) => {
|
|
157
|
+
// A disabled option keeps its state, and so does everything under it.
|
|
158
|
+
if (field.disabled)
|
|
159
|
+
return;
|
|
160
|
+
field.checked = checked;
|
|
161
|
+
field.indeterminate = false;
|
|
162
|
+
// Depth first, so each box follows options that are settled.
|
|
163
|
+
field._setChildren(checked);
|
|
164
|
+
field.commitFormValue();
|
|
165
|
+
});
|
|
166
|
+
this._followChildren(false);
|
|
167
|
+
}
|
|
168
|
+
_dispatchChange() {
|
|
169
|
+
this.dispatchEvent(new CustomEvent('change', {
|
|
170
|
+
detail: { checked: this.checked, value: this.value },
|
|
171
|
+
bubbles: true,
|
|
172
|
+
composed: true,
|
|
173
|
+
}));
|
|
174
|
+
}
|
|
67
175
|
formValue() {
|
|
68
176
|
return this.checked ? this.value : null;
|
|
69
177
|
}
|
|
70
178
|
/** The checkbox that carries `required` sits in a shadow root of its own,
|
|
71
179
|
* where the form cannot see it. */
|
|
72
180
|
ownValidity() {
|
|
73
|
-
return uncheckedValidity(this);
|
|
181
|
+
return uncheckedValidity({ required: this.required, checked: this.checked || this._groupHasSelection, disabled: this.disabled });
|
|
74
182
|
}
|
|
75
183
|
formResetCallback() {
|
|
76
184
|
this.checked = this._initialChecked;
|
|
77
185
|
this.indeterminate = false;
|
|
186
|
+
// The options under this one reset too, in their own callbacks.
|
|
187
|
+
if (this._childFields.length > 0)
|
|
188
|
+
queueMicrotask(() => this._followChildren(false));
|
|
78
189
|
}
|
|
79
190
|
formStateRestoreCallback(state) {
|
|
80
191
|
this.checked = state !== null;
|
|
@@ -88,15 +199,18 @@ let NLDDCheckboxField = class NLDDCheckboxField extends DescribedBy(FormAssociat
|
|
|
88
199
|
checkbox?.toggle();
|
|
89
200
|
}
|
|
90
201
|
_handleChange(e) {
|
|
91
|
-
|
|
202
|
+
let { checked } = e.detail;
|
|
203
|
+
// Partial because of an option it cannot change: checking would do
|
|
204
|
+
// nothing, so the click clears what it can.
|
|
205
|
+
if (checked && this._childFields.length > 0 && !this._wouldChange(true))
|
|
206
|
+
checked = false;
|
|
92
207
|
this.checked = checked;
|
|
93
208
|
this.indeterminate = false;
|
|
209
|
+
this._setChildren(checked);
|
|
210
|
+
// The box toggled itself; render even when this field ends where it was.
|
|
211
|
+
this.requestUpdate();
|
|
94
212
|
this.commitFormValue();
|
|
95
|
-
this.
|
|
96
|
-
detail: { checked: this.checked, value: this.value },
|
|
97
|
-
bubbles: true,
|
|
98
|
-
composed: true,
|
|
99
|
-
}));
|
|
213
|
+
this._dispatchChange();
|
|
100
214
|
}
|
|
101
215
|
/**
|
|
102
216
|
* Delegates focus to the inner `<nldd-checkbox>`, which in turn focuses its
|
|
@@ -144,9 +258,15 @@ __decorate([
|
|
|
144
258
|
__decorate([
|
|
145
259
|
property({ type: Boolean, reflect: true })
|
|
146
260
|
], NLDDCheckboxField.prototype, "required", void 0);
|
|
261
|
+
__decorate([
|
|
262
|
+
state()
|
|
263
|
+
], NLDDCheckboxField.prototype, "_groupHasSelection", void 0);
|
|
147
264
|
__decorate([
|
|
148
265
|
property({ type: Boolean, reflect: true })
|
|
149
266
|
], NLDDCheckboxField.prototype, "invalid", void 0);
|
|
267
|
+
__decorate([
|
|
268
|
+
state()
|
|
269
|
+
], NLDDCheckboxField.prototype, "_childFields", void 0);
|
|
150
270
|
NLDDCheckboxField = __decorate([
|
|
151
271
|
customElement('nldd-checkbox-field')
|
|
152
272
|
], NLDDCheckboxField);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"checkbox-field.js","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-field/checkbox-field.ts"],"names":[],"mappings":";;;;;;AAAA
|
|
1
|
+
{"version":3,"file":"checkbox-field.js","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-field/checkbox-field.ts"],"names":[],"mappings":";;;;;;AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmCG;AACH,OAAO,EAAE,UAAU,EAAuB,MAAM,KAAK,CAAC;AACtD,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,aAAa,EAAE,MAAM,sCAAsC,CAAC;AACrE,OAAO,EAAE,cAAc,EAAE,iBAAiB,EAAoC,MAAM,6CAA6C,CAAC;AAClI,OAAO,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AACjE,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AAGrE,OAAO,EAAE,WAAW,EAAE,MAAM,0CAA0C,CAAC;AACvE,OAAO,EAAE,iBAAiB,EAAE,MAAM,2CAA2C,CAAC;AAC9E,OAAO,EAAE,UAAU,EAAE,MAAM,mCAAmC,CAAC;AAGxD,IAAM,iBAAiB,GAAvB,MAAM,iBAAkB,SAAQ,WAAW,CAAC,cAAc,CAAC,UAAU,CAAC,CAAC;IAAvE;;QASE,oBAAe,GAAG,KAAK,CAAC;QAGhC,YAAO,GAAG,KAAK,CAAC;QAGhB,kBAAa,GAAG,KAAK,CAAC;QAGtB,aAAQ,GAAG,KAAK,CAAC;QAGjB,UAAK,GAAG,IAAI,CAAC;QAEb;8EACsE;QAEtE,SAAI,GAAG,EAAE,CA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3B;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;gDAChB;AAIX;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;mDAC1B;AAWjB;IADC,KAAK,EAAE;6DACmB;AAa3B;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;kDAC3B;AAkBhB;IADC,KAAK,EAAE;uDAC+B;AA/E3B,iBAAiB;IAD7B,aAAa,CAAC,qBAAqB,CAAC;GACxB,iBAAiB,CA2N7B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"checkbox-field.styles.d.ts","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-field/checkbox-field.styles.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,mBAAmB,
|
|
1
|
+
{"version":3,"file":"checkbox-field.styles.d.ts","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-field/checkbox-field.styles.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,mBAAmB,yBAkE/B,CAAC"}
|
|
@@ -9,6 +9,8 @@ export const checkboxFieldStyles = css `
|
|
|
9
9
|
/* # Host */
|
|
10
10
|
|
|
11
11
|
:host {
|
|
12
|
+
--_checkbox-field-children-padding-inline-start: calc(var(--semantics-controls-xs-min-size) + var(--primitives-space-8));
|
|
13
|
+
|
|
12
14
|
${inheritedTextReset}
|
|
13
15
|
display: block;
|
|
14
16
|
}
|
|
@@ -60,5 +62,9 @@ export const checkboxFieldStyles = css `
|
|
|
60
62
|
:host([disabled]) .checkbox-field__label {
|
|
61
63
|
opacity: var(--primitives-opacity-disabled);
|
|
62
64
|
}
|
|
65
|
+
|
|
66
|
+
.checkbox-field__children {
|
|
67
|
+
padding-inline-start: var(--_checkbox-field-children-padding-inline-start);
|
|
68
|
+
}
|
|
63
69
|
`;
|
|
64
70
|
//# sourceMappingURL=checkbox-field.styles.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"checkbox-field.styles.js","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-field/checkbox-field.styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAC1B,OAAO,EAAE,kBAAkB,EAAE,MAAM,yCAAyC,CAAC;AAE7E,MAAM,CAAC,MAAM,mBAAmB,GAAG,GAAG,CAAA
|
|
1
|
+
{"version":3,"file":"checkbox-field.styles.js","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-field/checkbox-field.styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAC1B,OAAO,EAAE,kBAAkB,EAAE,MAAM,yCAAyC,CAAC;AAE7E,MAAM,CAAC,MAAM,mBAAmB,GAAG,GAAG,CAAA;;;;;;;;;;;IAWlC,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAuDrB,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"checkbox-field.template.d.ts","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-field/checkbox-field.template.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,cAAc,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"checkbox-field.template.d.ts","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-field/checkbox-field.template.ts"],"names":[],"mappings":"AAAA,OAAO,EAAiB,cAAc,EAAE,MAAM,KAAK,CAAC;AAEpD,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAC7D,OAAO,yBAAyB,CAAC;AAGjC,wBAAgB,qBAAqB,CAAC,SAAS,EAAE,iBAAiB,GAAG,cAAc,CAmClF"}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { html, nothing } from 'lit';
|
|
2
|
+
import { live } from 'lit/directives/live.js';
|
|
2
3
|
import '../checkbox/checkbox.js';
|
|
3
4
|
/* eslint-disable lit-a11y/click-events-have-key-events -- label wrapper delegates to inner checkbox */
|
|
4
5
|
export function checkboxFieldTemplate(component) {
|
|
@@ -10,9 +11,9 @@ export function checkboxFieldTemplate(component) {
|
|
|
10
11
|
<nldd-checkbox
|
|
11
12
|
color=${component.color || nothing}
|
|
12
13
|
?invalid=${component.invalid}
|
|
13
|
-
?required=${component.required}
|
|
14
|
-
?checked=${component.checked}
|
|
15
|
-
?indeterminate=${component.indeterminate}
|
|
14
|
+
?required=${component.required && !component._inGroup}
|
|
15
|
+
?checked=${live(component.checked)}
|
|
16
|
+
?indeterminate=${live(component.indeterminate)}
|
|
16
17
|
?disabled=${component.disabled}
|
|
17
18
|
name=${component.name || nothing}
|
|
18
19
|
value=${component.value}
|
|
@@ -20,7 +21,20 @@ export function checkboxFieldTemplate(component) {
|
|
|
20
21
|
@change=${component._handleChange}
|
|
21
22
|
></nldd-checkbox>
|
|
22
23
|
</div>
|
|
23
|
-
<span class="checkbox-field__label"
|
|
24
|
+
<span class="checkbox-field__label"
|
|
25
|
+
id="label"
|
|
26
|
+
>
|
|
27
|
+
${component.label}
|
|
28
|
+
</span>
|
|
29
|
+
</div>
|
|
30
|
+
<div class="checkbox-field__children"
|
|
31
|
+
role=${component._childFields.length > 0 ? 'group' : nothing}
|
|
32
|
+
aria-labelledby=${component._childFields.length > 0 ? 'label' : nothing}
|
|
33
|
+
>
|
|
34
|
+
<slot
|
|
35
|
+
name="children"
|
|
36
|
+
@slotchange=${component._handleChildrenSlotChange}
|
|
37
|
+
></slot>
|
|
24
38
|
</div>
|
|
25
39
|
`;
|
|
26
40
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"checkbox-field.template.js","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-field/checkbox-field.template.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,OAAO,EAAkB,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"checkbox-field.template.js","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-field/checkbox-field.template.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,OAAO,EAAkB,MAAM,KAAK,CAAC;AACpD,OAAO,EAAE,IAAI,EAAE,MAAM,wBAAwB,CAAC;AAE9C,OAAO,yBAAyB,CAAC;AAEjC,uGAAuG;AACvG,MAAM,UAAU,qBAAqB,CAAC,SAA4B;IACjE,OAAO,IAAI,CAAA;;YAEA,SAAS,CAAC,iBAAiB;;;;aAI1B,SAAS,CAAC,KAAK,IAAI,OAAO;gBACvB,SAAS,CAAC,OAAO;iBAChB,SAAS,CAAC,QAAQ,IAAI,CAAC,SAAS,CAAC,QAAQ;gBAC1C,IAAI,CAAC,SAAS,CAAC,OAAO,CAAC;sBACjB,IAAI,CAAC,SAAS,CAAC,aAAa,CAAC;iBAClC,SAAS,CAAC,QAAQ;YACvB,SAAS,CAAC,IAAI,IAAI,OAAO;aACxB,SAAS,CAAC,KAAK;wBACJ,SAAS,CAAC,KAAK,IAAI,OAAO;eACnC,SAAS,CAAC,aAAa;;;;;;MAMhC,SAAS,CAAC,KAAK;;;;UAIX,SAAS,CAAC,YAAY,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,OAAO;qBAC1C,SAAS,CAAC,YAAY,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,OAAO;;;;kBAIxD,SAAS,CAAC,yBAAyB;;;EAGnD,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Nederlandse Digitale Dienst Checkbox Group Component (Lit + TypeScript)
|
|
3
|
+
*
|
|
4
|
+
* Groups nldd-checkbox-field elements as nldd-radio-button-group groups radio
|
|
5
|
+
* buttons: the same layout, one name for all of them, and a group that a
|
|
6
|
+
* screen reader announces with its label. Each checkbox is a stop of its own
|
|
7
|
+
* for Tab, as checkboxes are; the arrow keys belong to a radio group.
|
|
8
|
+
* Use inside nldd-form-field, which provides the group label.
|
|
9
|
+
*
|
|
10
|
+
* `required` asks for at least one checked box, not for every box: while none
|
|
11
|
+
* is checked, each field reports a missing value, and as soon as one is
|
|
12
|
+
* checked, none does. Nothing announces it per box, since no single box is
|
|
13
|
+
* required, and ARIA has no `aria-required` for a group: say it in the label
|
|
14
|
+
* or the help text, or mark the other questions optional.
|
|
15
|
+
*
|
|
16
|
+
* @element nldd-checkbox-group
|
|
17
|
+
* @attr {string} name - Forwarded to all nldd-checkbox-field elements in the group; clearing it leaves them the name they had
|
|
18
|
+
* @attr {boolean} disabled - Disables all fields in the group
|
|
19
|
+
* @attr {boolean} required - At least one box in the group has to be checked. Set on every field in the group, nested ones included, whether it is on or off: in a group, the group decides.
|
|
20
|
+
* @attr {string} accessible-label - Accessible name for the group, set as aria-label on the group
|
|
21
|
+
* @attr {string} accessible-labeled-by - Id of an external label element, set as aria-labelledby on the group
|
|
22
|
+
* @attr {boolean} invalid - Marks the control as invalid. Announced with aria-invalid; nothing is drawn for it.
|
|
23
|
+
*
|
|
24
|
+
* @slot - Slot for nldd-checkbox-field elements. Options nested in the `children` slot of a field belong to the group too; see nldd-checkbox-field.
|
|
25
|
+
*
|
|
26
|
+
* @fires change - Bubbles up from the field that changed; detail: { checked: boolean, value: string }
|
|
27
|
+
*/
|
|
28
|
+
import { LitElement } from 'lit';
|
|
29
|
+
export declare class NLDDCheckboxGroup extends LitElement {
|
|
30
|
+
static styles: import("lit").CSSResult;
|
|
31
|
+
/** Says this is the control an nldd-form-field is about, so the field can
|
|
32
|
+
* find it, name it and move focus into it. See nldd-form-field. */
|
|
33
|
+
static isFormInput: boolean;
|
|
34
|
+
name: string;
|
|
35
|
+
disabled: boolean;
|
|
36
|
+
required: boolean;
|
|
37
|
+
/** Accessible name forwarded as aria-label to the group host. */
|
|
38
|
+
accessibleLabel: string;
|
|
39
|
+
accessibleLabeledBy: string;
|
|
40
|
+
/** The name this group wrote onto its host, so it only takes back its own. */
|
|
41
|
+
private _appliedLabel;
|
|
42
|
+
private _answerQueued;
|
|
43
|
+
/**
|
|
44
|
+
* Marks the control as invalid.
|
|
45
|
+
*
|
|
46
|
+
* Announced and not drawn. What is wrong belongs in an
|
|
47
|
+
* nldd-validation-list, in words: a red ring around a single
|
|
48
|
+
* checkbox would say the option is wrong, while it is the question
|
|
49
|
+
* that is unanswered. `aria-invalid` still goes on the control, because
|
|
50
|
+
* choosing not to show something is not a reason to keep quiet about it.
|
|
51
|
+
*/
|
|
52
|
+
invalid: boolean;
|
|
53
|
+
connectedCallback(): void;
|
|
54
|
+
disconnectedCallback(): void;
|
|
55
|
+
updated(changed: Map<PropertyKey, unknown>): void;
|
|
56
|
+
/** Every field in the group, those nested under another one included. */
|
|
57
|
+
private _getFields;
|
|
58
|
+
private _syncFields;
|
|
59
|
+
/** Whether any box is checked: what `required` asks of the group. A field
|
|
60
|
+
* only sees itself, so the group tells each of them. */
|
|
61
|
+
private _syncAnswered;
|
|
62
|
+
private _handleChange;
|
|
63
|
+
/** Called by a field whose `checked` changed, whoever changed it: the
|
|
64
|
+
* user, the app or a form reset. */
|
|
65
|
+
_optionChanged(): void;
|
|
66
|
+
_onSlotChange: () => void;
|
|
67
|
+
/** Delegates focus to the first checked box, or else to the first one that
|
|
68
|
+
* is enabled, so a label pointing at the group lands on a box. */
|
|
69
|
+
focus(options?: FocusOptions): void;
|
|
70
|
+
render(): import("lit-html").TemplateResult;
|
|
71
|
+
}
|
|
72
|
+
declare global {
|
|
73
|
+
interface HTMLElementTagNameMap {
|
|
74
|
+
'nldd-checkbox-group': NLDDCheckboxGroup;
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
//# sourceMappingURL=checkbox-group.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"checkbox-group.d.ts","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-group/checkbox-group.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,OAAO,EAAE,UAAU,EAAE,MAAM,KAAK,CAAC;AASjC,qBACa,iBAAkB,SAAQ,UAAU;IAChD,OAAgB,MAAM,0BAAuB;IAE7C;wEACoE;IACpE,MAAM,CAAC,WAAW,UAAQ;IAG1B,IAAI,SAAM;IAGV,QAAQ,UAAS;IAGjB,QAAQ,UAAS;IAEjB,iEAAiE;IAEjE,eAAe,SAAM;IAGrB,mBAAmB,SAAM;IAEzB,8EAA8E;IAC9E,OAAO,CAAC,aAAa,CAAuB;IAC5C,OAAO,CAAC,aAAa,CAAS;IAE9B;;;;;;;;OAQG;IAEH,OAAO,UAAS;IAEP,iBAAiB,IAAI,IAAI;IAMzB,oBAAoB,IAAI,IAAI;IAK5B,OAAO,CAAC,OAAO,EAAE,GAAG,CAAC,WAAW,EAAE,OAAO,CAAC,GAAG,IAAI;IAsB1D,yEAAyE;IACzE,OAAO,CAAC,UAAU;IAIlB,OAAO,CAAC,WAAW;IAiBnB;6DACyD;IACzD,OAAO,CAAC,aAAa;IAWrB,OAAO,CAAC,aAAa,CAEnB;IAEF;yCACqC;IACrC,cAAc,IAAI,IAAI;IAWtB,aAAa,QAAO,IAAI,CAEtB;IAEF;uEACmE;IAC1D,KAAK,CAAC,OAAO,CAAC,EAAE,YAAY,GAAG,IAAI;IAMnC,MAAM;CAGf;AAED,OAAO,CAAC,MAAM,CAAC;IACd,UAAU,qBAAqB;QAC9B,qBAAqB,EAAE,iBAAiB,CAAC;KACzC;CACD"}
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
/**
|
|
8
|
+
* Nederlandse Digitale Dienst Checkbox Group Component (Lit + TypeScript)
|
|
9
|
+
*
|
|
10
|
+
* Groups nldd-checkbox-field elements as nldd-radio-button-group groups radio
|
|
11
|
+
* buttons: the same layout, one name for all of them, and a group that a
|
|
12
|
+
* screen reader announces with its label. Each checkbox is a stop of its own
|
|
13
|
+
* for Tab, as checkboxes are; the arrow keys belong to a radio group.
|
|
14
|
+
* Use inside nldd-form-field, which provides the group label.
|
|
15
|
+
*
|
|
16
|
+
* `required` asks for at least one checked box, not for every box: while none
|
|
17
|
+
* is checked, each field reports a missing value, and as soon as one is
|
|
18
|
+
* checked, none does. Nothing announces it per box, since no single box is
|
|
19
|
+
* required, and ARIA has no `aria-required` for a group: say it in the label
|
|
20
|
+
* or the help text, or mark the other questions optional.
|
|
21
|
+
*
|
|
22
|
+
* @element nldd-checkbox-group
|
|
23
|
+
* @attr {string} name - Forwarded to all nldd-checkbox-field elements in the group; clearing it leaves them the name they had
|
|
24
|
+
* @attr {boolean} disabled - Disables all fields in the group
|
|
25
|
+
* @attr {boolean} required - At least one box in the group has to be checked. Set on every field in the group, nested ones included, whether it is on or off: in a group, the group decides.
|
|
26
|
+
* @attr {string} accessible-label - Accessible name for the group, set as aria-label on the group
|
|
27
|
+
* @attr {string} accessible-labeled-by - Id of an external label element, set as aria-labelledby on the group
|
|
28
|
+
* @attr {boolean} invalid - Marks the control as invalid. Announced with aria-invalid; nothing is drawn for it.
|
|
29
|
+
*
|
|
30
|
+
* @slot - Slot for nldd-checkbox-field elements. Options nested in the `children` slot of a field belong to the group too; see nldd-checkbox-field.
|
|
31
|
+
*
|
|
32
|
+
* @fires change - Bubbles up from the field that changed; detail: { checked: boolean, value: string }
|
|
33
|
+
*/
|
|
34
|
+
import { LitElement } from 'lit';
|
|
35
|
+
import { property } from 'lit/decorators.js';
|
|
36
|
+
import { customElement } from '../../../utilities/custom-element.js';
|
|
37
|
+
import { checkboxGroupStyles } from './checkbox-group.styles.js';
|
|
38
|
+
import { checkboxGroupTemplate } from './checkbox-group.template.js';
|
|
39
|
+
import { setOwnedAttribute } from '../../../utilities/owned-attribute.js';
|
|
40
|
+
import { deferFocus } from '../../../utilities/defer-focus.js';
|
|
41
|
+
let NLDDCheckboxGroup = class NLDDCheckboxGroup extends LitElement {
|
|
42
|
+
constructor() {
|
|
43
|
+
super(...arguments);
|
|
44
|
+
this.name = '';
|
|
45
|
+
this.disabled = false;
|
|
46
|
+
this.required = false;
|
|
47
|
+
/** Accessible name forwarded as aria-label to the group host. */
|
|
48
|
+
this.accessibleLabel = '';
|
|
49
|
+
this.accessibleLabeledBy = '';
|
|
50
|
+
/** The name this group wrote onto its host, so it only takes back its own. */
|
|
51
|
+
this._appliedLabel = null;
|
|
52
|
+
this._answerQueued = false;
|
|
53
|
+
/**
|
|
54
|
+
* Marks the control as invalid.
|
|
55
|
+
*
|
|
56
|
+
* Announced and not drawn. What is wrong belongs in an
|
|
57
|
+
* nldd-validation-list, in words: a red ring around a single
|
|
58
|
+
* checkbox would say the option is wrong, while it is the question
|
|
59
|
+
* that is unanswered. `aria-invalid` still goes on the control, because
|
|
60
|
+
* choosing not to show something is not a reason to keep quiet about it.
|
|
61
|
+
*/
|
|
62
|
+
this.invalid = false;
|
|
63
|
+
this._handleChange = () => {
|
|
64
|
+
this._syncAnswered();
|
|
65
|
+
};
|
|
66
|
+
this._onSlotChange = () => {
|
|
67
|
+
this._syncFields();
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
connectedCallback() {
|
|
71
|
+
super.connectedCallback();
|
|
72
|
+
this.setAttribute('role', 'group');
|
|
73
|
+
this.addEventListener('change', this._handleChange);
|
|
74
|
+
}
|
|
75
|
+
disconnectedCallback() {
|
|
76
|
+
super.disconnectedCallback();
|
|
77
|
+
this.removeEventListener('change', this._handleChange);
|
|
78
|
+
}
|
|
79
|
+
updated(changed) {
|
|
80
|
+
if (changed.has('name') || changed.has('disabled') || changed.has('required')) {
|
|
81
|
+
this._syncFields();
|
|
82
|
+
}
|
|
83
|
+
if (changed.has('invalid')) {
|
|
84
|
+
if (this.invalid)
|
|
85
|
+
this.setAttribute('aria-invalid', 'true');
|
|
86
|
+
else
|
|
87
|
+
this.removeAttribute('aria-invalid');
|
|
88
|
+
}
|
|
89
|
+
// Only ever take back a name this group wrote itself, so an aria-label the
|
|
90
|
+
// consumer put on the host stays.
|
|
91
|
+
if (changed.has('accessibleLabel')) {
|
|
92
|
+
this._appliedLabel = setOwnedAttribute(this, 'aria-label', this.accessibleLabel, this._appliedLabel);
|
|
93
|
+
}
|
|
94
|
+
if (changed.has('accessibleLabeledBy')) {
|
|
95
|
+
if (this.accessibleLabeledBy) {
|
|
96
|
+
this.setAttribute('aria-labelledby', this.accessibleLabeledBy);
|
|
97
|
+
}
|
|
98
|
+
else {
|
|
99
|
+
this.removeAttribute('aria-labelledby');
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
/** Every field in the group, those nested under another one included. */
|
|
104
|
+
_getFields() {
|
|
105
|
+
return Array.from(this.querySelectorAll('nldd-checkbox-field'));
|
|
106
|
+
}
|
|
107
|
+
_syncFields() {
|
|
108
|
+
this._getFields().forEach(field => {
|
|
109
|
+
if (this.name)
|
|
110
|
+
field.name = this.name;
|
|
111
|
+
field.required = this.required;
|
|
112
|
+
if (this.disabled) {
|
|
113
|
+
if (!field.hasAttribute('disabled')) {
|
|
114
|
+
field.setAttribute('group-disabled', '');
|
|
115
|
+
field.disabled = true;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
else if (field.hasAttribute('group-disabled')) {
|
|
119
|
+
field.removeAttribute('group-disabled');
|
|
120
|
+
field.disabled = false;
|
|
121
|
+
}
|
|
122
|
+
});
|
|
123
|
+
this._syncAnswered();
|
|
124
|
+
}
|
|
125
|
+
/** Whether any box is checked: what `required` asks of the group. A field
|
|
126
|
+
* only sees itself, so the group tells each of them. */
|
|
127
|
+
_syncAnswered() {
|
|
128
|
+
const fields = this._getFields();
|
|
129
|
+
const answered = fields.some((field) => field.checked);
|
|
130
|
+
fields.forEach((field) => {
|
|
131
|
+
field._groupHasSelection = answered;
|
|
132
|
+
// Synchronously: a consumer reading validity in its change listener
|
|
133
|
+
// should see the answer the group just changed.
|
|
134
|
+
field.commitFormValue?.();
|
|
135
|
+
});
|
|
136
|
+
}
|
|
137
|
+
/** Called by a field whose `checked` changed, whoever changed it: the
|
|
138
|
+
* user, the app or a form reset. */
|
|
139
|
+
_optionChanged() {
|
|
140
|
+
// Once for all of them: checking an option with others under it changes
|
|
141
|
+
// every one of those, each of which reports here.
|
|
142
|
+
if (this._answerQueued)
|
|
143
|
+
return;
|
|
144
|
+
this._answerQueued = true;
|
|
145
|
+
queueMicrotask(() => {
|
|
146
|
+
this._answerQueued = false;
|
|
147
|
+
this._syncAnswered();
|
|
148
|
+
});
|
|
149
|
+
}
|
|
150
|
+
/** Delegates focus to the first checked box, or else to the first one that
|
|
151
|
+
* is enabled, so a label pointing at the group lands on a box. */
|
|
152
|
+
focus(options) {
|
|
153
|
+
if (deferFocus(this, options))
|
|
154
|
+
return;
|
|
155
|
+
const fields = this._getFields().filter((field) => !field.disabled);
|
|
156
|
+
(fields.find((field) => field.checked) ?? fields[0])?.focus(options);
|
|
157
|
+
}
|
|
158
|
+
render() {
|
|
159
|
+
return checkboxGroupTemplate(this);
|
|
160
|
+
}
|
|
161
|
+
};
|
|
162
|
+
NLDDCheckboxGroup.styles = checkboxGroupStyles;
|
|
163
|
+
/** Says this is the control an nldd-form-field is about, so the field can
|
|
164
|
+
* find it, name it and move focus into it. See nldd-form-field. */
|
|
165
|
+
NLDDCheckboxGroup.isFormInput = true;
|
|
166
|
+
__decorate([
|
|
167
|
+
property({ type: String })
|
|
168
|
+
], NLDDCheckboxGroup.prototype, "name", void 0);
|
|
169
|
+
__decorate([
|
|
170
|
+
property({ type: Boolean, reflect: true })
|
|
171
|
+
], NLDDCheckboxGroup.prototype, "disabled", void 0);
|
|
172
|
+
__decorate([
|
|
173
|
+
property({ type: Boolean, reflect: true })
|
|
174
|
+
], NLDDCheckboxGroup.prototype, "required", void 0);
|
|
175
|
+
__decorate([
|
|
176
|
+
property({ type: String, attribute: 'accessible-label' })
|
|
177
|
+
], NLDDCheckboxGroup.prototype, "accessibleLabel", void 0);
|
|
178
|
+
__decorate([
|
|
179
|
+
property({ type: String, attribute: 'accessible-labeled-by' })
|
|
180
|
+
], NLDDCheckboxGroup.prototype, "accessibleLabeledBy", void 0);
|
|
181
|
+
__decorate([
|
|
182
|
+
property({ type: Boolean, reflect: true })
|
|
183
|
+
], NLDDCheckboxGroup.prototype, "invalid", void 0);
|
|
184
|
+
NLDDCheckboxGroup = __decorate([
|
|
185
|
+
customElement('nldd-checkbox-group')
|
|
186
|
+
], NLDDCheckboxGroup);
|
|
187
|
+
export { NLDDCheckboxGroup };
|
|
188
|
+
//# sourceMappingURL=checkbox-group.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"checkbox-group.js","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-group/checkbox-group.ts"],"names":[],"mappings":";;;;;;AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;GA0BG;AACH,OAAO,EAAE,UAAU,EAAE,MAAM,KAAK,CAAC;AACjC,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EAAE,aAAa,EAAE,MAAM,sCAAsC,CAAC;AACrE,OAAO,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAC;AACjE,OAAO,EAAE,qBAAqB,EAAE,MAAM,8BAA8B,CAAC;AAErE,OAAO,EAAE,iBAAiB,EAAE,MAAM,uCAAuC,CAAC;AAC1E,OAAO,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E,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,CAAC,EAAE,KAAK,CAAC,OAAO,CAAC,CAAC;IACtE,CAAC;IAEQ,MAAM;QACd,OAAO,qBAAqB,CAAC,IAAI,CAAC,CAAC;IACpC,CAAC;;AAzIe,wBAAM,GAAG,mBAAmB,AAAtB,CAAuB;AAE7C;oEACoE;AAC7D,6BAAW,GAAG,IAAI,AAAP,CAAQ;AAG1B;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;+CACjB;AAGV;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;mDAC1B;AAGjB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;mDAC1B;AAIjB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,kBAAkB,EAAE,CAAC;0DACrC;AAGrB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,uBAAuB,EAAE,CAAC;8DACtC;AAgBzB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;kDAC3B;AArCJ,iBAAiB;IAD7B,aAAa,CAAC,qBAAqB,CAAC;GACxB,iBAAiB,CA2I7B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"checkbox-group.styles.d.ts","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-group/checkbox-group.styles.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,mBAAmB,yBAwB/B,CAAC"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { css } from 'lit';
|
|
2
|
+
import { inheritedTextReset } from '../../../assets/styles/shadow-resets.js';
|
|
3
|
+
export const checkboxGroupStyles = css `
|
|
4
|
+
:host {
|
|
5
|
+
box-sizing: border-box;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
/* # Host */
|
|
10
|
+
|
|
11
|
+
:host {
|
|
12
|
+
${inheritedTextReset}
|
|
13
|
+
display: block;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
:host([hidden]) {
|
|
17
|
+
display: none;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
/* # Block */
|
|
22
|
+
|
|
23
|
+
.checkbox-group {
|
|
24
|
+
display: flex;
|
|
25
|
+
flex-direction: column;
|
|
26
|
+
}
|
|
27
|
+
`;
|
|
28
|
+
//# sourceMappingURL=checkbox-group.styles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"checkbox-group.styles.js","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-group/checkbox-group.styles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAC1B,OAAO,EAAE,kBAAkB,EAAE,MAAM,yCAAyC,CAAC;AAE7E,MAAM,CAAC,MAAM,mBAAmB,GAAG,GAAG,CAAA;;;;;;;;;IASlC,kBAAkB;;;;;;;;;;;;;;;CAerB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"checkbox-group.template.d.ts","sourceRoot":"","sources":["../../../../src/components/inputs/checkbox-group/checkbox-group.template.ts"],"names":[],"mappings":"AAAA,OAAO,EAAQ,cAAc,EAAE,MAAM,KAAK,CAAC;AAC3C,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,qBAAqB,CAAC;AAE7D,wBAAgB,qBAAqB,CAAC,SAAS,EAAE,iBAAiB,GAAG,cAAc,CAMlF"}
|