@nldd/design-system 0.20.0 → 0.21.1
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 +361 -10
- package/dist/cdn/autoloader.js +181 -0
- package/dist/cdn/chunks/activity-indicator-JglZJ8dh.js +356 -0
- package/dist/cdn/chunks/activity-indicator.i18n-D7mCy6d2.js +3 -0
- package/dist/cdn/chunks/avatar-ASqePVhU.js +308 -0
- package/dist/cdn/chunks/avatar-group-GinEMPm9.js +338 -0
- package/dist/cdn/chunks/avatar-group.i18n-BYw_9wt_.js +7 -0
- package/dist/cdn/chunks/avatar.i18n-CMwQjBkS.js +7 -0
- package/dist/cdn/chunks/badge-Cc2Nufoc.js +323 -0
- package/dist/cdn/chunks/badge.i18n-DqW7hLQj.js +3 -0
- package/dist/cdn/chunks/banner-BLVKM07M.js +325 -0
- package/dist/cdn/chunks/banner.i18n-BOCM9rGN.js +3 -0
- package/dist/cdn/chunks/bar-split-view-Clbg-p9H.js +259 -0
- package/dist/cdn/chunks/base-CfuoYRhN.js +3 -0
- package/dist/cdn/chunks/blockquote-BoOqbGdm.js +189 -0
- package/dist/cdn/chunks/box-WkhyjQVy.js +88 -0
- package/dist/cdn/chunks/breadcrumbs-D9YxZzRj.js +162 -0
- package/dist/cdn/chunks/breadcrumbs.i18n-zmO8jaTO.js +3 -0
- package/dist/cdn/chunks/breakpoints-Cwor8TRP.js +15 -0
- package/dist/cdn/chunks/button-DO90Lo6q.js +863 -0
- package/dist/cdn/chunks/button-bar-Bxgdbyh3.js +225 -0
- package/dist/cdn/chunks/button-group-BYGPPLmZ.js +205 -0
- package/dist/{components/button.i18n-DiDGynnq.js → cdn/chunks/button.i18n-BGFt7Z9u.js} +2 -2
- package/dist/cdn/chunks/card-BP0jfOkS.js +262 -0
- package/dist/cdn/chunks/card.i18n-CpafLm3i.js +8 -0
- package/dist/cdn/chunks/carried-context-DlMSujiJ.js +37 -0
- package/dist/cdn/chunks/cell-BRD2ilQh.js +144 -0
- package/dist/cdn/chunks/checkbox-Cazx8CQn.js +296 -0
- package/dist/cdn/chunks/checkbox-field-DDZ-B6vH.js +157 -0
- package/dist/cdn/chunks/class-map-CXSdNjt8.js +26 -0
- package/dist/cdn/chunks/code-editor-D6Q55oaY.js +286 -0
- package/dist/cdn/chunks/code-viewer-DspLH2T1.js +766 -0
- package/dist/cdn/chunks/code-viewer.i18n-BHfSDRbK.js +13 -0
- package/dist/cdn/chunks/codemirror-input-Db65x22n.js +1232 -0
- package/dist/cdn/chunks/collection-NVtkvDls.js +396 -0
- package/dist/cdn/chunks/collection.i18n-DqWPGnZO.js +8 -0
- package/dist/cdn/chunks/combo-box-OywRKaWj.js +512 -0
- package/dist/cdn/chunks/combo-box.i18n-BorzYnJ2.js +6 -0
- package/dist/cdn/chunks/container-rrbwk0z4.js +602 -0
- package/dist/cdn/chunks/custom-element-BW8Ua4c7.js +7 -0
- package/dist/cdn/chunks/custom-element-q6NzoL5b.js +301 -0
- package/dist/cdn/chunks/custom-font-size-D7KNr84p.js +57 -0
- package/dist/cdn/chunks/date-field-vmZLo80s.js +662 -0
- package/dist/cdn/chunks/date-field.i18n-BTzc0E9a.js +15 -0
- package/dist/cdn/chunks/date-picker-CXDzSBoL.js +993 -0
- package/dist/cdn/chunks/date-picker.i18n-Dsc_M5QK.js +82 -0
- package/dist/cdn/chunks/decorate-TduJMFD_.js +280 -0
- package/dist/cdn/chunks/defer-focus-F73ud2D9.js +9 -0
- package/dist/cdn/chunks/described-by-mixin-daRE7orX.js +32 -0
- package/dist/cdn/chunks/description-cell-CQwOj_rN.js +166 -0
- package/dist/cdn/chunks/dev-checks-zW_W-hnh.js +2695 -0
- package/dist/cdn/chunks/directive-CwRgozUW.js +27 -0
- package/dist/cdn/chunks/dismiss-from-title-bar-C6mP7sWP.js +5 -0
- package/dist/cdn/chunks/dist-3C80SZN9.js +849 -0
- package/dist/cdn/chunks/dist-A7_1pHX0.js +379 -0
- package/dist/cdn/chunks/dist-BEfLdOvy.js +1346 -0
- package/dist/cdn/chunks/dist-BTUxFM2V.js +268 -0
- package/dist/cdn/chunks/dist-CP3G1pSK.js +1037 -0
- package/dist/cdn/chunks/dist-C_dGY6zR.js +468 -0
- package/dist/{components/dist-B9YBOGFW.js → cdn/chunks/dist-ChmCRv39.js} +109 -153
- package/dist/{components/dist-CJm4tkNC.js → cdn/chunks/dist-D2qap2OY.js} +23 -31
- package/dist/cdn/chunks/dist-DPUBF0MZ.js +1593 -0
- package/dist/{components/dist-4g23YHP0.js → cdn/chunks/dist-DrTzvgE7.js} +291 -404
- package/dist/cdn/chunks/dist-EM4MWLQq.js +385 -0
- package/dist/cdn/chunks/dist-EgIBI-FG.js +293 -0
- package/dist/{components/dist-Bf823YyL.js → cdn/chunks/dist-Rm6FvrSR.js} +272 -551
- package/dist/cdn/chunks/divider-CCNbnplA.js +53 -0
- package/dist/cdn/chunks/document-tab-bar-A2DFWrP9.js +973 -0
- package/dist/cdn/chunks/document-tab-bar.i18n-DKrA9TnB.js +9 -0
- package/dist/cdn/chunks/drag-handle-cell-CbzDYebG.js +206 -0
- package/dist/cdn/chunks/drag-handle-cell.i18n-CKUrbm2q.js +3 -0
- package/dist/cdn/chunks/dropdown-DZTZtkm5.js +350 -0
- package/dist/cdn/chunks/element-state-B-44fVqq.js +20 -0
- package/dist/cdn/chunks/file-field-DQ52qq5L.js +1484 -0
- package/dist/cdn/chunks/file-field.i18n-pDM7Utud.js +40 -0
- package/dist/cdn/chunks/floating-ui.dom-B8J1rV2c.js +753 -0
- package/dist/cdn/chunks/focus-target-DSLGcCWq.js +24 -0
- package/dist/cdn/chunks/form-actions-C_7hINq-.js +90 -0
- package/dist/cdn/chunks/form-associated-mixin--GIbl98p.js +62 -0
- package/dist/cdn/chunks/form-field--4nWJ_DK.js +364 -0
- package/dist/cdn/chunks/form-hXLgy_tY.js +84 -0
- package/dist/cdn/chunks/form-section-By-D4un0.js +64 -0
- package/dist/cdn/chunks/full-bleed-section-Dg4sIJG1.js +161 -0
- package/dist/cdn/chunks/gherkin-eseYvsxh.js +29 -0
- package/dist/cdn/chunks/hero-CQQMNCT_.js +761 -0
- package/dist/{components/icon-_Eox7ZfO.js → cdn/chunks/icon-BORlalt0.js} +298 -308
- package/dist/cdn/chunks/icon-button-rKiIHs7A.js +632 -0
- package/dist/{components/icon-button.i18n-1_N-wN6x.js → cdn/chunks/icon-button.i18n-DpZOfIS4.js} +2 -4
- package/dist/cdn/chunks/icon-cell-rk4NQid2.js +156 -0
- package/dist/cdn/chunks/identity-BLXecYsZ.js +187 -0
- package/dist/cdn/chunks/if-defined-CaKKERku.js +4 -0
- package/dist/cdn/chunks/image-DZMW6JgL.js +659 -0
- package/dist/cdn/chunks/image.i18n-ONcm1h7o.js +3 -0
- package/dist/cdn/chunks/implicit-submission-Csbcor_E.js +27 -0
- package/dist/cdn/chunks/inline-dialog-WlqtPBPJ.js +259 -0
- package/dist/cdn/chunks/input-modality-XE0B7yCn.js +42 -0
- package/dist/cdn/chunks/just-in-time-education-DRcb5g7x.js +611 -0
- package/dist/cdn/chunks/just-in-time-education.i18n-CW_dsaxf.js +6 -0
- package/dist/cdn/chunks/kanban-Ca_mfqsA.js +400 -0
- package/dist/cdn/chunks/kanban-column-fgIMc7pw.js +375 -0
- package/dist/cdn/chunks/kanban.i18n-CWqc3e0B.js +11 -0
- package/dist/cdn/chunks/keyboard-shortcut-EknnW7Ub.js +267 -0
- package/dist/cdn/chunks/languages-yKikVFv_.js +8893 -0
- package/dist/cdn/chunks/link-FBSAJ3UC.js +229 -0
- package/dist/cdn/chunks/link-group-90qVfKa0.js +111 -0
- package/dist/cdn/chunks/link-hint-KFhgr5Ng.js +24 -0
- package/dist/cdn/chunks/link-rel-DvrTEfVT.js +8 -0
- package/dist/cdn/chunks/link.i18n-DJPobGmu.js +8 -0
- package/dist/cdn/chunks/list-CaWl3q0Z.js +880 -0
- package/dist/cdn/chunks/list-item-Cagnf6eG.js +802 -0
- package/dist/cdn/chunks/list-item-segment-BRzBF1y_.js +315 -0
- package/dist/cdn/chunks/list-item-segment.i18n-DHnrQL4V.js +8 -0
- package/dist/{components/list-item.i18n-89uqlBMK.js → cdn/chunks/list-item.i18n-Br6J5Ev9.js} +2 -2
- package/dist/cdn/chunks/list-items-Du0RCWsY.js +6 -0
- package/dist/{components/list.i18n-CKqbhFQ_.js → cdn/chunks/list.i18n-C40ltgdI.js} +2 -2
- package/dist/cdn/chunks/loading-tags-DtUr-DR7.js +3 -0
- package/dist/cdn/chunks/menu-BtxzRedh.js +719 -0
- package/dist/cdn/chunks/menu-bar-BU3Hjk1b.js +253 -0
- package/dist/cdn/chunks/menu-bar-item-C7LQ0NI_.js +365 -0
- package/dist/cdn/chunks/menu-bar.i18n-BoMu4Eoz.js +3 -0
- package/dist/cdn/chunks/menu-divider-CLLRgMll.js +15 -0
- package/dist/cdn/chunks/menu-group-BL24ChpR.js +23 -0
- package/dist/cdn/chunks/menu-item-CooKfrFa.js +140 -0
- package/dist/cdn/chunks/menu.i18n-C6uYJsG3.js +10 -0
- package/dist/cdn/chunks/menu.template-C6rbfI-u.js +642 -0
- package/dist/cdn/chunks/modal-dialog-BrUMP4Jm.js +240 -0
- package/dist/cdn/chunks/multi-line-text-field-D7hXhyOn.js +318 -0
- package/dist/cdn/chunks/navigation-split-view-B2ZQhxEb.js +621 -0
- package/dist/cdn/chunks/nl.generated-D6T41jG3.js +112 -0
- package/dist/cdn/chunks/notification-DSGP14d1.js +492 -0
- package/dist/cdn/chunks/notification.i18n-BKUSLN5c.js +6 -0
- package/dist/cdn/chunks/number-field-B8op14Y_.js +301 -0
- package/dist/cdn/chunks/number-field.i18n-BS0bINWY.js +7 -0
- package/dist/cdn/chunks/one-half-one-half-section-ZYmHYf4Q.js +213 -0
- package/dist/cdn/chunks/one-third-two-thirds-section-Ds10K6AS.js +213 -0
- package/dist/cdn/chunks/one-time-code-field-Cgy_tTS4.js +693 -0
- package/dist/cdn/chunks/open-when-rendered-CW_2_WUZ.js +20 -0
- package/dist/cdn/chunks/owned-attribute-x9OCTy_4.js +6 -0
- package/dist/cdn/chunks/owner-form-Cq8tT7ac.js +7 -0
- package/dist/cdn/chunks/page-CBf_Decp.js +431 -0
- package/dist/cdn/chunks/page-footer-CSv1dU7M.js +396 -0
- package/dist/cdn/chunks/page-footer.i18n-pbdr4lN3.js +3 -0
- package/dist/cdn/chunks/page-section-mixin-Dp6X8GKd.js +132 -0
- package/dist/cdn/chunks/pagination-CMUcFB53.js +485 -0
- package/dist/cdn/chunks/pagination.i18n-QQMx14CQ.js +9 -0
- package/dist/cdn/chunks/password-field-C76Vm3rm.js +368 -0
- package/dist/cdn/chunks/password-field.i18n-CzdBn-1b.js +8 -0
- package/dist/cdn/chunks/popover-CGbeEv_-.js +334 -0
- package/dist/cdn/chunks/popover-target-B25dxnmt.js +10 -0
- package/dist/cdn/chunks/popover.i18n-DmFBHUvB.js +3 -0
- package/dist/cdn/chunks/popup-anchor-controller-VZw0bXf2.js +30 -0
- package/dist/cdn/chunks/progress-bar-BLiHaRUS.js +674 -0
- package/dist/cdn/chunks/progress-bar.i18n-Cr5miGTx.js +8 -0
- package/dist/cdn/chunks/progress-circle-CjkovRbL.js +667 -0
- package/dist/cdn/chunks/progress-circle.i18n-CRrXuY4V.js +8 -0
- package/dist/cdn/chunks/query-ChDzi9FQ.js +28 -0
- package/dist/cdn/chunks/radio-button-GHyO-GQB.js +338 -0
- package/dist/cdn/chunks/radio-button-field-C-Z6Lnd4.js +192 -0
- package/dist/cdn/chunks/radio-button-group-ChTqBCnQ.js +118 -0
- package/dist/cdn/chunks/radio-position-CXWYAjaz.js +10 -0
- package/dist/cdn/chunks/reflect-non-default-Bu3rpCvg.js +9 -0
- package/dist/cdn/chunks/render-marked-DX_5ISZE.js +37 -0
- package/dist/cdn/chunks/repeat-Ch_5OsXE.js +76 -0
- package/dist/cdn/chunks/return-focus-BzZWhXhc.js +57 -0
- package/dist/cdn/chunks/rich-text-CQ2uwMSp.js +47 -0
- package/dist/cdn/chunks/rich-text.i18n-BlJ68YuU.js +3 -0
- package/dist/cdn/chunks/row-header-mixin-CgqvREoV.js +16 -0
- package/dist/cdn/chunks/sanitize-url-CBuGmY0W.js +7 -0
- package/dist/cdn/chunks/scroll-mode-controller-COUD1-3P.js +42 -0
- package/dist/cdn/chunks/search-field-BGNfERhn.js +396 -0
- package/dist/cdn/chunks/search-field.i18n-B_Oc7hc-.js +6 -0
- package/dist/cdn/chunks/segmented-control-BYAG4VRp.js +671 -0
- package/dist/cdn/chunks/shadow-resets-6SToDsPu.js +12 -0
- package/dist/cdn/chunks/sheet-CqN7ViYV.js +340 -0
- package/dist/cdn/chunks/shell-C9rds_D9.js +146 -0
- package/dist/cdn/chunks/shell-DmJOYhyF.js +108 -0
- package/dist/cdn/chunks/side-by-side-split-view-C5oX4c6Z.js +166 -0
- package/dist/cdn/chunks/sidebar-section-CFPBdETU.js +353 -0
- package/dist/cdn/chunks/sidebar-section.i18n-BuGfRMpD.js +6 -0
- package/dist/cdn/chunks/simple-section-qrCqXeBa.js +192 -0
- package/dist/cdn/chunks/skip-link-DWh4W6-J.js +161 -0
- package/dist/cdn/chunks/skip-link.i18n--PbEdAmJ.js +3 -0
- package/dist/cdn/chunks/slider--hODfOwh.js +772 -0
- package/dist/cdn/chunks/slider.i18n-DVw0c8AG.js +6 -0
- package/dist/cdn/chunks/slot-content-BLuPqVXw.js +13 -0
- package/dist/cdn/chunks/spacer-CFzq_JCh.js +237 -0
- package/dist/cdn/chunks/spacer-cell-DuVOgIj8.js +68 -0
- package/dist/cdn/chunks/spacing-scale-SufIjHeN.js +28 -0
- package/dist/cdn/chunks/split-button-DH19p8So.js +268 -0
- package/dist/cdn/chunks/split-button.i18n-DtClSMga.js +3 -0
- package/dist/cdn/chunks/split-view-divider-jzcPmnMh.js +100 -0
- package/dist/cdn/chunks/split-view-pane-BLsZz263.js +128 -0
- package/dist/cdn/chunks/stacked-split-view-CcOR8LrJ.js +157 -0
- package/dist/cdn/chunks/static-html-Cf4ccUIg.js +26 -0
- package/dist/cdn/chunks/status-bar-CINbOihq.js +284 -0
- package/dist/cdn/chunks/status-bar-change-CR9l0Gyk.js +3 -0
- package/dist/cdn/chunks/step-bar-6FvZL1Ti.js +474 -0
- package/dist/cdn/chunks/step-bar.i18n-DocExlD7.js +9 -0
- package/dist/cdn/chunks/step-cell-CejRisgS.js +287 -0
- package/dist/cdn/chunks/stepper-CY2rJWOJ.js +223 -0
- package/dist/cdn/chunks/stepper.i18n-COOAkaBl.js +7 -0
- package/dist/cdn/chunks/style-map-DsIw6lkq.js +29 -0
- package/dist/cdn/chunks/style-mod-DGMhzWuk.js +1583 -0
- package/dist/cdn/chunks/swatch-picker-BY3DBIl6.js +430 -0
- package/dist/cdn/chunks/swatch-picker.i18n-_G0nmnGe.js +22 -0
- package/dist/cdn/chunks/switch-DDSsZFwK.js +275 -0
- package/dist/cdn/chunks/switch-field-CMoM9I38.js +137 -0
- package/dist/cdn/chunks/tab-bar-CA8K1XjU.js +697 -0
- package/dist/cdn/chunks/tab-bar.i18n-Crsc7ShA.js +3 -0
- package/dist/cdn/chunks/table-DwXjCSD5.js +308 -0
- package/dist/cdn/chunks/table.i18n-Bmb_uw_w.js +3 -0
- package/dist/cdn/chunks/tag-DM3APy3B.js +306 -0
- package/dist/cdn/chunks/text-B1CatNR1.js +421 -0
- package/dist/cdn/chunks/text-cell-BkEsGI3g.js +299 -0
- package/dist/cdn/chunks/text-editor-BvTiMeNV.js +3743 -0
- package/dist/cdn/chunks/text-editor.i18n-sJKiRQ4i.js +17 -0
- package/dist/cdn/chunks/text-field-CUyh1-V8.js +398 -0
- package/dist/cdn/chunks/time-field--5K0YTcr.js +607 -0
- package/dist/cdn/chunks/time-field.i18n-CLH5vmS7.js +11 -0
- package/dist/cdn/chunks/time-picker-W0xYXLy8.js +508 -0
- package/dist/cdn/chunks/time-picker.i18n-BilOCXlS.js +7 -0
- package/dist/cdn/chunks/title-BuT7tWqN.js +437 -0
- package/dist/cdn/chunks/title-bar-label-controller-DSxdKZOg.js +24 -0
- package/dist/cdn/chunks/title-cell-8d8psUBX.js +327 -0
- package/dist/cdn/chunks/toggle-button-DNXWXZpE.js +528 -0
- package/dist/cdn/chunks/toggle-button-group-ByowJYgs.js +156 -0
- package/dist/cdn/chunks/token-CnkEB3hB.js +266 -0
- package/dist/cdn/chunks/token-field-BpyxOGmU.js +664 -0
- package/dist/cdn/chunks/token-field.i18n-BclzoR8F.js +9 -0
- package/dist/cdn/chunks/token.i18n-RGD5zAtl.js +7 -0
- package/dist/cdn/chunks/toml-w97zZfFO.js +27 -0
- package/dist/cdn/chunks/toolbar-C24LqAzK.js +408 -0
- package/dist/cdn/chunks/toolbar-item-DpPfPxCi.js +50 -0
- package/dist/cdn/chunks/toolbar-title-KBMpfL9d.js +84 -0
- package/dist/cdn/chunks/toolbar.i18n-QwS37CBC.js +8 -0
- package/dist/cdn/chunks/toolbar.styles-BQkG4gVc.js +383 -0
- package/dist/cdn/chunks/tooltip-BsAHJjci.js +325 -0
- package/dist/cdn/chunks/top-navigation-bar-C_kLPVKD.js +925 -0
- package/dist/cdn/chunks/top-navigation-bar.i18n-C-lcH1nB.js +10 -0
- package/dist/cdn/chunks/top-title-bar-iNFB2zQL.js +344 -0
- package/dist/cdn/chunks/translations-wxBSz213.js +8 -0
- package/dist/cdn/chunks/two-thirds-one-third-section-D-UANbHC.js +213 -0
- package/dist/cdn/chunks/validation-list-C5BhHZIG.js +202 -0
- package/dist/cdn/chunks/validation-list.i18n-CM6In8zD.js +12 -0
- package/dist/cdn/chunks/visibility-mixin-COAZ9pON.js +74 -0
- package/dist/cdn/chunks/visually-hidden-BPgATaH0.js +43 -0
- package/dist/cdn/chunks/window-CxV6ELE9.js +227 -0
- package/dist/cdn/chunks/window.i18n-CsEnUPAk.js +3 -0
- package/dist/cdn/chunks/with-translations-XX14GKFh.js +16 -0
- package/dist/components/actions/menu/menu-item.d.ts +6 -2
- package/dist/components/actions/menu/menu-item.d.ts.map +1 -1
- package/dist/components/actions/menu/menu-item.js +12 -1
- package/dist/components/actions/menu/menu-item.js.map +1 -1
- package/dist/components/actions/menu/menu.js +1 -1
- package/dist/components/actions/menu/menu.js.map +1 -1
- package/dist/components/actions/menu/menu.template.d.ts.map +1 -1
- package/dist/components/actions/menu/menu.template.js +2 -1
- package/dist/components/actions/menu/menu.template.js.map +1 -1
- package/dist/components/content/blockquote/blockquote.d.ts +1 -0
- package/dist/components/content/blockquote/blockquote.d.ts.map +1 -1
- package/dist/components/content/blockquote/blockquote.js +1 -0
- package/dist/components/content/blockquote/blockquote.js.map +1 -1
- package/dist/components/content/identity/identity.d.ts +1 -0
- package/dist/components/content/identity/identity.d.ts.map +1 -1
- package/dist/components/content/identity/identity.js +1 -0
- package/dist/components/content/identity/identity.js.map +1 -1
- package/dist/components/content/image/image.d.ts +1 -0
- package/dist/components/content/image/image.d.ts.map +1 -1
- package/dist/components/content/image/image.js +1 -0
- package/dist/components/content/image/image.js.map +1 -1
- package/dist/components/content/rich-text/rich-text.d.ts +1 -0
- package/dist/components/content/rich-text/rich-text.d.ts.map +1 -1
- package/dist/components/content/rich-text/rich-text.js +1 -0
- package/dist/components/content/rich-text/rich-text.js.map +1 -1
- package/dist/components/content/text/text.d.ts +1 -0
- package/dist/components/content/text/text.d.ts.map +1 -1
- package/dist/components/content/text/text.js +1 -0
- package/dist/components/content/text/text.js.map +1 -1
- package/dist/components/content/title/title.d.ts +1 -0
- package/dist/components/content/title/title.d.ts.map +1 -1
- package/dist/components/content/title/title.js +1 -0
- package/dist/components/content/title/title.js.map +1 -1
- package/dist/components/forms/form/form.d.ts.map +1 -1
- package/dist/components/forms/form/form.js +1 -0
- package/dist/components/forms/form/form.js.map +1 -1
- package/dist/components/forms/form-field/form-field.d.ts +1 -0
- package/dist/components/forms/form-field/form-field.d.ts.map +1 -1
- package/dist/components/forms/form-field/form-field.js +1 -0
- package/dist/components/forms/form-field/form-field.js.map +1 -1
- package/dist/components/inputs/date-field/date-field.d.ts +9 -4
- package/dist/components/inputs/date-field/date-field.d.ts.map +1 -1
- package/dist/components/inputs/date-field/date-field.js +20 -7
- package/dist/components/inputs/date-field/date-field.js.map +1 -1
- package/dist/components/inputs/date-field/date-field.template.d.ts.map +1 -1
- package/dist/components/inputs/date-field/date-field.template.js +1 -0
- package/dist/components/inputs/date-field/date-field.template.js.map +1 -1
- package/dist/components/inputs/dropdown/dropdown.d.ts +23 -2
- package/dist/components/inputs/dropdown/dropdown.d.ts.map +1 -1
- package/dist/components/inputs/dropdown/dropdown.js +68 -11
- package/dist/components/inputs/dropdown/dropdown.js.map +1 -1
- package/dist/components/inputs/time-field/time-field.d.ts +4 -0
- package/dist/components/inputs/time-field/time-field.d.ts.map +1 -1
- package/dist/components/inputs/time-field/time-field.js +17 -2
- package/dist/components/inputs/time-field/time-field.js.map +1 -1
- package/dist/components/inputs/time-field/time-field.template.d.ts.map +1 -1
- package/dist/components/inputs/time-field/time-field.template.js +1 -0
- package/dist/components/inputs/time-field/time-field.template.js.map +1 -1
- package/dist/components/layout/container/container.d.ts +15 -2
- package/dist/components/layout/container/container.d.ts.map +1 -1
- package/dist/components/layout/container/container.js +38 -3
- package/dist/components/layout/container/container.js.map +1 -1
- package/dist/components/layout/container/container.styles.js +1 -1
- package/dist/components/layout/container/container.template.js +1 -1
- package/dist/components/layout/container/container.template.js.map +1 -1
- package/dist/components/layout/page-sections/hero/hero.d.ts +1 -0
- package/dist/components/layout/page-sections/hero/hero.d.ts.map +1 -1
- package/dist/components/layout/page-sections/hero/hero.js +1 -0
- package/dist/components/layout/page-sections/hero/hero.js.map +1 -1
- package/dist/components/layout/popover/popover.d.ts.map +1 -1
- package/dist/components/layout/popover/popover.js +4 -2
- package/dist/components/layout/popover/popover.js.map +1 -1
- package/dist/components/lists-and-tables/list-item/list-item.d.ts +7 -0
- 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 +13 -3
- 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 +11 -1
- 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 +19 -3
- package/dist/components/lists-and-tables/list-item-segment/list-item-segment.js.map +1 -1
- package/dist/nldd.min.js +729 -727
- package/dist/types/react.d.ts +3323 -0
- package/dist/types/vue.d.ts +11 -3
- package/dist/utilities/autoloader.d.ts +33 -0
- package/dist/utilities/autoloader.d.ts.map +1 -0
- package/dist/utilities/autoloader.generated.d.ts +3 -0
- package/dist/utilities/autoloader.generated.d.ts.map +1 -0
- package/dist/utilities/autoloader.generated.js +141 -0
- package/dist/utilities/autoloader.generated.js.map +1 -0
- package/dist/utilities/autoloader.js +94 -0
- package/dist/utilities/autoloader.js.map +1 -0
- package/dist/utilities/dev-checks.d.ts +9 -0
- package/dist/utilities/dev-checks.d.ts.map +1 -1
- package/dist/utilities/dev-checks.js +45 -3
- package/dist/utilities/dev-checks.js.map +1 -1
- package/dist/utilities/dev-rules.generated.d.ts.map +1 -1
- package/dist/utilities/dev-rules.generated.js +12 -2
- package/dist/utilities/dev-rules.generated.js.map +1 -1
- package/dist/utilities/loading-tags.d.ts +7 -0
- package/dist/utilities/loading-tags.d.ts.map +1 -0
- package/dist/utilities/loading-tags.js +7 -0
- package/dist/utilities/loading-tags.js.map +1 -0
- package/dist/utilities/owner-form.d.ts +3 -3
- package/dist/utilities/owner-form.d.ts.map +1 -1
- package/dist/utilities/owner-form.js +6 -3
- package/dist/utilities/owner-form.js.map +1 -1
- package/dist/utilities/return-focus.d.ts +14 -0
- package/dist/utilities/return-focus.d.ts.map +1 -1
- package/dist/utilities/return-focus.js +26 -8
- package/dist/utilities/return-focus.js.map +1 -1
- package/lint/data.generated.json +1 -1
- package/lint/engine.js +53 -1
- package/lint/format.js +6 -5
- package/lint/frontends.js +224 -16
- package/lint/linter.js +5 -3
- package/lint/main.js +36 -9
- package/lint/project.js +73 -4
- package/lint/rule-data.js +17 -2
- package/lint/tree.js +3 -0
- package/package.json +50 -11
- package/dist/components/breakpoints-DtL62nLI.js +0 -45
- package/dist/components/components.js +0 -68243
- package/dist/components/decorate-DD7uUxHb.js +0 -51
- package/dist/components/defer-focus-dzorHsCQ.js +0 -176
- package/dist/components/dev-checks-CLB9G43h.js +0 -2711
- package/dist/components/dist-245LaK9m.js +0 -1479
- package/dist/components/dist-BFZM0YsR.js +0 -15772
- package/dist/components/dist-BNkeFjc3.js +0 -1180
- package/dist/components/dist-CSC1dG3L.js +0 -365
- package/dist/components/dist-CeMOOqgP.js +0 -1509
- package/dist/components/dist-DFjwTlJV.js +0 -624
- package/dist/components/dist-DHhnz3Gv.js +0 -381
- package/dist/components/dist-PeUX4vPq.js +0 -2857
- package/dist/components/dist-m70B83qb.js +0 -463
- package/dist/components/element-state-BnarBv0M.js +0 -42
- package/dist/components/gherkin-DzYbEwDO.js +0 -107
- package/dist/components/icon-button-8gvQCwCW.js +0 -2305
- package/dist/components/input-modality-D_CY185R.js +0 -48
- package/dist/components/just-in-time-education.i18n-BqU1ImP4.js +0 -423
- package/dist/components/nl.generated-DzZkOgnP.js +0 -64
- package/dist/components/rolldown-runtime-D8jQpDG7.js +0 -12
- package/dist/components/shadow-resets-BwOyyZFH.js +0 -60
- package/dist/components/shell-Dh5IwHd-.js +0 -222
- package/dist/components/toml-D0Pix_8Q.js +0 -58
- package/dist/components/visibility-mixin-Dzn48SL8.js +0 -153
|
@@ -0,0 +1,863 @@
|
|
|
1
|
+
import { r as e } from "./icon-BORlalt0.js";
|
|
2
|
+
import { i as t, n } from "./custom-element-q6NzoL5b.js";
|
|
3
|
+
import { n as r, o as i, r as a, t as o } from "./decorate-TduJMFD_.js";
|
|
4
|
+
import { t as s } from "./custom-element-BW8Ua4c7.js";
|
|
5
|
+
import { t as c } from "./reflect-non-default-Bu3rpCvg.js";
|
|
6
|
+
import { n as l } from "./element-state-B-44fVqq.js";
|
|
7
|
+
import { t as u } from "./shadow-resets-6SToDsPu.js";
|
|
8
|
+
import { t as d } from "./link-rel-DvrTEfVT.js";
|
|
9
|
+
import { r as f, t as p } from "./link-hint-KFhgr5Ng.js";
|
|
10
|
+
import { i as m, n as h, r as g } from "./keyboard-shortcut-EknnW7Ub.js";
|
|
11
|
+
import { n as _, t as v } from "./popover-target-B25dxnmt.js";
|
|
12
|
+
import { t as y } from "./with-translations-XX14GKFh.js";
|
|
13
|
+
import { t as b } from "./button.i18n-BGFt7Z9u.js";
|
|
14
|
+
import { t as x } from "./popup-anchor-controller-VZw0bXf2.js";
|
|
15
|
+
import "./activity-indicator-JglZJ8dh.js";
|
|
16
|
+
import { t as S } from "./described-by-mixin-daRE7orX.js";
|
|
17
|
+
import { t as C } from "./defer-focus-F73ud2D9.js";
|
|
18
|
+
import { t as w } from "./owner-form-Cq8tT7ac.js";
|
|
19
|
+
// src/components/actions/button/button.styles.ts
|
|
20
|
+
var T = t`
|
|
21
|
+
:host {
|
|
22
|
+
box-sizing: border-box;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
/* # Host */
|
|
27
|
+
|
|
28
|
+
:host {
|
|
29
|
+
--_button-corner-radius: var(--semantics-controls-md-corner-radius);
|
|
30
|
+
/* A parent that stacks its buttons says so through the context variable;
|
|
31
|
+
the button's own width attribute overrides it with an inline style. */
|
|
32
|
+
--_button-width: var(--context-button-width, auto);
|
|
33
|
+
--_button-min-size: var(--semantics-controls-md-min-size);
|
|
34
|
+
--_button-block-padding: var(--semantics-controls-md-block-padding);
|
|
35
|
+
--_button-inline-padding: var(--semantics-buttons-md-inline-padding);
|
|
36
|
+
--_button-gap: var(--semantics-buttons-md-gap);
|
|
37
|
+
--_button-font: var(--semantics-buttons-md-primary-text-font);
|
|
38
|
+
--_button-icon-size: var(--semantics-buttons-md-icon-size);
|
|
39
|
+
--_button-disclosure-icon-size: var(--primitives-space-20);
|
|
40
|
+
--_button-supporting-font: var(--semantics-buttons-md-supporting-text-font);
|
|
41
|
+
--_button-background-color: var(--semantics-buttons-neutral-tinted-background-color);
|
|
42
|
+
--_button-primary-content-color: var(--semantics-buttons-neutral-tinted-content-color);
|
|
43
|
+
--_button-secondary-content-color: var(--semantics-buttons-neutral-tinted-content-secondary-color);
|
|
44
|
+
--_button-highlight-border-color: var(--semantics-buttons-neutral-tinted-highlight-border-color);
|
|
45
|
+
--_button-is-hovered-background-color: var(--semantics-buttons-neutral-tinted-is-hovered-background-color);
|
|
46
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-neutral-tinted-is-hovered-content-color);
|
|
47
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-neutral-tinted-is-hovered-content-secondary-color);
|
|
48
|
+
--_button-is-hovered-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-hovered-highlight-border-color);
|
|
49
|
+
--_button-is-active-background-color: var(--semantics-buttons-neutral-tinted-is-active-background-color);
|
|
50
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-neutral-tinted-is-active-content-color);
|
|
51
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-neutral-tinted-is-active-content-secondary-color);
|
|
52
|
+
--_button-is-active-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-active-highlight-border-color);
|
|
53
|
+
|
|
54
|
+
${u}
|
|
55
|
+
/* inline-flex, not inline-block: a block container puts the control on a
|
|
56
|
+
line, and the strut's descender then grows the host with the inherited
|
|
57
|
+
line-height, so the same button is taller in body text than in a form. */
|
|
58
|
+
display: inline-flex;
|
|
59
|
+
position: relative;
|
|
60
|
+
/* A definite width, so a flex or grid parent doesn't stretch the host: an
|
|
61
|
+
inline-block shrink-wraps in normal flow, but as a flex item it would be
|
|
62
|
+
stretched to the full line while the button inside stays content-sized —
|
|
63
|
+
leaving an invisible box around the button that swallows clicks that
|
|
64
|
+
look like they land beside it. align-self would only cover flex. */
|
|
65
|
+
width: fit-content;
|
|
66
|
+
max-width: 100%;
|
|
67
|
+
-webkit-user-select: none;
|
|
68
|
+
user-select: none;
|
|
69
|
+
-webkit-tap-highlight-color: transparent;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
:host([size="xs"]) {
|
|
73
|
+
--_button-corner-radius: var(--semantics-controls-xs-corner-radius);
|
|
74
|
+
--_button-min-size: var(--semantics-controls-xs-min-size);
|
|
75
|
+
--_button-block-padding: var(--semantics-controls-xs-block-padding);
|
|
76
|
+
--_button-inline-padding: var(--semantics-buttons-xs-inline-padding);
|
|
77
|
+
--_button-gap: var(--semantics-buttons-xs-gap);
|
|
78
|
+
--_button-font: var(--semantics-buttons-xs-primary-text-font);
|
|
79
|
+
--_button-icon-size: var(--semantics-buttons-xs-icon-size);
|
|
80
|
+
--_button-disclosure-icon-size: var(--primitives-space-16);
|
|
81
|
+
--_button-supporting-font: var(--semantics-buttons-xs-supporting-text-font);
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
:host([size="sm"]) {
|
|
85
|
+
--_button-corner-radius: var(--semantics-controls-sm-corner-radius);
|
|
86
|
+
--_button-min-size: var(--semantics-controls-sm-min-size);
|
|
87
|
+
--_button-block-padding: var(--semantics-controls-sm-block-padding);
|
|
88
|
+
--_button-inline-padding: var(--semantics-buttons-sm-inline-padding);
|
|
89
|
+
--_button-gap: var(--semantics-buttons-sm-gap);
|
|
90
|
+
--_button-font: var(--semantics-buttons-sm-primary-text-font);
|
|
91
|
+
--_button-icon-size: var(--semantics-buttons-sm-icon-size);
|
|
92
|
+
--_button-disclosure-icon-size: var(--primitives-space-18);
|
|
93
|
+
--_button-supporting-font: var(--semantics-buttons-sm-supporting-text-font);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
:host([size="lg"]) {
|
|
97
|
+
--_button-corner-radius: var(--semantics-controls-lg-corner-radius);
|
|
98
|
+
--_button-min-size: var(--semantics-controls-lg-min-size);
|
|
99
|
+
--_button-block-padding: var(--semantics-controls-lg-block-padding);
|
|
100
|
+
--_button-inline-padding: var(--semantics-buttons-lg-inline-padding);
|
|
101
|
+
--_button-gap: var(--semantics-buttons-lg-gap);
|
|
102
|
+
--_button-font: var(--semantics-buttons-lg-primary-text-font);
|
|
103
|
+
--_button-icon-size: var(--semantics-buttons-lg-icon-size);
|
|
104
|
+
--_button-disclosure-icon-size: var(--primitives-space-24);
|
|
105
|
+
--_button-supporting-font: var(--semantics-buttons-lg-supporting-text-font);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
:host([appearance="neutral-base"]) {
|
|
109
|
+
--_button-background-color: var(--semantics-buttons-neutral-base-background-color);
|
|
110
|
+
--_button-primary-content-color: var(--semantics-buttons-neutral-base-content-color);
|
|
111
|
+
--_button-secondary-content-color: var(--semantics-buttons-neutral-base-content-secondary-color);
|
|
112
|
+
--_button-highlight-border-color: var(--semantics-buttons-neutral-base-highlight-border-color);
|
|
113
|
+
--_button-is-hovered-background-color: var(--semantics-buttons-neutral-base-is-hovered-background-color);
|
|
114
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-neutral-base-is-hovered-content-color);
|
|
115
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-neutral-base-is-hovered-content-secondary-color);
|
|
116
|
+
--_button-is-hovered-highlight-border-color: var(--semantics-buttons-neutral-base-is-hovered-highlight-border-color);
|
|
117
|
+
--_button-is-active-background-color: var(--semantics-buttons-neutral-base-is-active-background-color);
|
|
118
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-neutral-base-is-active-content-color);
|
|
119
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-neutral-base-is-active-content-secondary-color);
|
|
120
|
+
--_button-is-active-highlight-border-color: var(--semantics-buttons-neutral-base-is-active-highlight-border-color);
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
:host([appearance="neutral-transparent"]) {
|
|
124
|
+
--_button-background-color: transparent;
|
|
125
|
+
--_button-primary-content-color: var(--semantics-buttons-neutral-transparent-content-color);
|
|
126
|
+
--_button-secondary-content-color: var(--semantics-buttons-neutral-transparent-content-secondary-color);
|
|
127
|
+
--_button-highlight-border-color: transparent;
|
|
128
|
+
--_button-is-hovered-background-color: transparent;
|
|
129
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-neutral-transparent-is-hovered-content-color);
|
|
130
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-neutral-transparent-is-hovered-content-secondary-color);
|
|
131
|
+
--_button-is-hovered-highlight-border-color: transparent;
|
|
132
|
+
--_button-is-active-background-color: transparent;
|
|
133
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-neutral-transparent-is-active-content-color);
|
|
134
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-neutral-transparent-is-active-content-secondary-color);
|
|
135
|
+
--_button-is-active-highlight-border-color: transparent;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
:host([appearance="accent-filled"]),
|
|
139
|
+
:host([appearance="primary"]) {
|
|
140
|
+
--_button-background-color: var(--semantics-buttons-accent-filled-background-color);
|
|
141
|
+
--_button-primary-content-color: var(--semantics-buttons-accent-filled-content-color);
|
|
142
|
+
--_button-secondary-content-color: var(--semantics-buttons-accent-filled-content-secondary-color);
|
|
143
|
+
--_button-highlight-border-color: var(--semantics-buttons-accent-filled-highlight-border-color);
|
|
144
|
+
--_button-is-hovered-background-color: var(--semantics-buttons-accent-filled-is-hovered-background-color);
|
|
145
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-accent-filled-is-hovered-content-color);
|
|
146
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-accent-filled-is-hovered-content-secondary-color);
|
|
147
|
+
--_button-is-hovered-highlight-border-color: var(--semantics-buttons-accent-filled-is-hovered-highlight-border-color);
|
|
148
|
+
--_button-is-active-background-color: var(--semantics-buttons-accent-filled-is-active-background-color);
|
|
149
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-accent-filled-is-active-content-color);
|
|
150
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-accent-filled-is-active-content-secondary-color);
|
|
151
|
+
--_button-is-active-highlight-border-color: var(--semantics-buttons-accent-filled-is-active-highlight-border-color);
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
:host([appearance="accent-transparent"]) {
|
|
155
|
+
--_button-background-color: transparent;
|
|
156
|
+
--_button-primary-content-color: var(--semantics-buttons-accent-transparent-content-color);
|
|
157
|
+
--_button-secondary-content-color: var(--semantics-buttons-accent-transparent-content-secondary-color);
|
|
158
|
+
--_button-highlight-border-color: transparent;
|
|
159
|
+
--_button-is-hovered-background-color: transparent;
|
|
160
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-accent-transparent-is-hovered-content-color);
|
|
161
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-accent-transparent-is-hovered-content-secondary-color);
|
|
162
|
+
--_button-is-hovered-highlight-border-color: transparent;
|
|
163
|
+
--_button-is-active-background-color: transparent;
|
|
164
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-accent-transparent-is-active-content-color);
|
|
165
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-accent-transparent-is-active-content-secondary-color);
|
|
166
|
+
--_button-is-active-highlight-border-color: transparent;
|
|
167
|
+
}
|
|
168
|
+
|
|
169
|
+
:host([appearance="critical-tinted"]),
|
|
170
|
+
:host([appearance="destructive"]) {
|
|
171
|
+
--_button-background-color: var(--semantics-buttons-critical-tinted-background-color);
|
|
172
|
+
--_button-primary-content-color: var(--semantics-buttons-critical-tinted-content-color);
|
|
173
|
+
--_button-secondary-content-color: var(--semantics-buttons-critical-tinted-content-secondary-color);
|
|
174
|
+
--_button-highlight-border-color: var(--semantics-buttons-critical-tinted-highlight-border-color);
|
|
175
|
+
--_button-is-hovered-background-color: var(--semantics-buttons-critical-tinted-is-hovered-background-color);
|
|
176
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-critical-tinted-is-hovered-content-color);
|
|
177
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-critical-tinted-is-hovered-content-secondary-color);
|
|
178
|
+
--_button-is-hovered-highlight-border-color: var(--semantics-buttons-critical-tinted-is-hovered-highlight-border-color);
|
|
179
|
+
--_button-is-active-background-color: var(--semantics-buttons-critical-tinted-is-active-background-color);
|
|
180
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-critical-tinted-is-active-content-color);
|
|
181
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-critical-tinted-is-active-content-secondary-color);
|
|
182
|
+
--_button-is-active-highlight-border-color: var(--semantics-buttons-critical-tinted-is-active-highlight-border-color);
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
:host([appearance="critical-transparent"]) {
|
|
186
|
+
--_button-background-color: transparent;
|
|
187
|
+
--_button-primary-content-color: var(--semantics-buttons-critical-transparent-content-color);
|
|
188
|
+
--_button-secondary-content-color: var(--semantics-buttons-critical-transparent-content-secondary-color);
|
|
189
|
+
--_button-highlight-border-color: transparent;
|
|
190
|
+
--_button-is-hovered-background-color: transparent;
|
|
191
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-critical-transparent-is-hovered-content-color);
|
|
192
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-critical-transparent-is-hovered-content-secondary-color);
|
|
193
|
+
--_button-is-hovered-highlight-border-color: transparent;
|
|
194
|
+
--_button-is-active-background-color: transparent;
|
|
195
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-critical-transparent-is-active-content-color);
|
|
196
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-critical-transparent-is-active-content-secondary-color);
|
|
197
|
+
--_button-is-active-highlight-border-color: transparent;
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
/* The on-color variants derive from currentColor (which stays
|
|
201
|
+
unresolved inside the tokens). The filled label prefers the surface
|
|
202
|
+
color from --context-parent-background-color; that var() must resolve
|
|
203
|
+
here on the host — inside a :root token it would freeze — with the
|
|
204
|
+
tokens' white/black contrast flip as fallback. */
|
|
205
|
+
|
|
206
|
+
:host([appearance="inherit-tinted"]),
|
|
207
|
+
:host([expanded][appearance="inherit-tinted"]) {
|
|
208
|
+
--_button-background-color: var(--context-button-background-color, var(--semantics-buttons-inherit-tinted-background-color));
|
|
209
|
+
--_button-primary-content-color: var(--semantics-buttons-inherit-tinted-content-color);
|
|
210
|
+
--_button-secondary-content-color: var(--semantics-buttons-inherit-tinted-content-secondary-color);
|
|
211
|
+
--_button-highlight-border-color: var(--semantics-buttons-inherit-tinted-highlight-border-color);
|
|
212
|
+
--_button-is-hovered-background-color: var(--_button-background-color);
|
|
213
|
+
--_button-is-hovered-primary-content-color: var(--_button-primary-content-color);
|
|
214
|
+
--_button-is-hovered-secondary-content-color: var(--_button-secondary-content-color);
|
|
215
|
+
--_button-is-hovered-highlight-border-color: var(--_button-highlight-border-color);
|
|
216
|
+
--_button-is-active-background-color: var(--_button-background-color);
|
|
217
|
+
--_button-is-active-primary-content-color: var(--_button-primary-content-color);
|
|
218
|
+
--_button-is-active-secondary-content-color: var(--_button-secondary-content-color);
|
|
219
|
+
--_button-is-active-highlight-border-color: var(--_button-highlight-border-color);
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
:host([appearance="inherit-filled"]),
|
|
223
|
+
:host([expanded][appearance="inherit-filled"]) {
|
|
224
|
+
--_button-background-color: var(--semantics-buttons-inherit-filled-background-color);
|
|
225
|
+
--_button-primary-content-color: var(--context-parent-background-color, var(--semantics-buttons-inherit-filled-content-color));
|
|
226
|
+
--_button-secondary-content-color: var(--semantics-buttons-inherit-filled-content-secondary-color);
|
|
227
|
+
--_button-highlight-border-color: var(--semantics-buttons-inherit-filled-highlight-border-color);
|
|
228
|
+
--_button-is-hovered-background-color: var(--_button-background-color);
|
|
229
|
+
--_button-is-hovered-primary-content-color: var(--_button-primary-content-color);
|
|
230
|
+
--_button-is-hovered-secondary-content-color: var(--_button-secondary-content-color);
|
|
231
|
+
--_button-is-hovered-highlight-border-color: var(--_button-highlight-border-color);
|
|
232
|
+
--_button-is-active-background-color: var(--_button-background-color);
|
|
233
|
+
--_button-is-active-primary-content-color: var(--_button-primary-content-color);
|
|
234
|
+
--_button-is-active-secondary-content-color: var(--_button-secondary-content-color);
|
|
235
|
+
--_button-is-active-highlight-border-color: var(--_button-highlight-border-color);
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
/* For inherit-filled the inner button keeps the inherited on-color:
|
|
239
|
+
its currentColor background and the label's contrast flip resolve
|
|
240
|
+
against it, and would otherwise self-reference the label. The label
|
|
241
|
+
color moves to the content layer instead. The higher specificity of
|
|
242
|
+
these rules deliberately pins the color through hover/active/expanded. */
|
|
243
|
+
:host([appearance="inherit-filled"]) .button {
|
|
244
|
+
color: inherit;
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
:host([appearance="inherit-filled"]) .button > * {
|
|
248
|
+
color: var(--_button-primary-content-color);
|
|
249
|
+
}
|
|
250
|
+
|
|
251
|
+
/* ## Expanded — default (incl. unknown variant) */
|
|
252
|
+
|
|
253
|
+
:host([expanded]) {
|
|
254
|
+
--_button-background-color: var(--semantics-buttons-neutral-tinted-is-expanded-background-color);
|
|
255
|
+
--_button-primary-content-color: var(--semantics-buttons-neutral-tinted-is-expanded-content-color);
|
|
256
|
+
--_button-secondary-content-color: var(--semantics-buttons-neutral-tinted-is-expanded-content-secondary-color);
|
|
257
|
+
--_button-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-expanded-highlight-border-color);
|
|
258
|
+
--_button-is-hovered-background-color: var(--semantics-buttons-neutral-tinted-is-expanded-is-hovered-background-color);
|
|
259
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-neutral-tinted-is-expanded-is-hovered-content-color);
|
|
260
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-neutral-tinted-is-expanded-is-hovered-content-secondary-color);
|
|
261
|
+
--_button-is-hovered-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-expanded-is-hovered-highlight-border-color);
|
|
262
|
+
--_button-is-active-background-color: var(--semantics-buttons-neutral-tinted-is-expanded-is-active-background-color);
|
|
263
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-neutral-tinted-is-expanded-is-active-content-color);
|
|
264
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-neutral-tinted-is-expanded-is-active-content-secondary-color);
|
|
265
|
+
--_button-is-active-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-expanded-is-active-highlight-border-color);
|
|
266
|
+
}
|
|
267
|
+
|
|
268
|
+
:host([expanded][appearance="neutral-base"]) {
|
|
269
|
+
--_button-background-color: var(--semantics-buttons-neutral-base-is-expanded-background-color);
|
|
270
|
+
--_button-primary-content-color: var(--semantics-buttons-neutral-base-is-expanded-content-color);
|
|
271
|
+
--_button-secondary-content-color: var(--semantics-buttons-neutral-base-is-expanded-content-secondary-color);
|
|
272
|
+
--_button-highlight-border-color: var(--semantics-buttons-neutral-base-is-expanded-highlight-border-color);
|
|
273
|
+
--_button-is-hovered-background-color: var(--semantics-buttons-neutral-base-is-expanded-is-hovered-background-color);
|
|
274
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-neutral-base-is-expanded-is-hovered-content-color);
|
|
275
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-neutral-base-is-expanded-is-hovered-content-secondary-color);
|
|
276
|
+
--_button-is-hovered-highlight-border-color: var(--semantics-buttons-neutral-base-is-expanded-is-hovered-highlight-border-color);
|
|
277
|
+
--_button-is-active-background-color: var(--semantics-buttons-neutral-base-is-expanded-is-active-background-color);
|
|
278
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-neutral-base-is-expanded-is-active-content-color);
|
|
279
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-neutral-base-is-expanded-is-active-content-secondary-color);
|
|
280
|
+
--_button-is-active-highlight-border-color: var(--semantics-buttons-neutral-base-is-expanded-is-active-highlight-border-color);
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
:host([expanded][appearance="neutral-transparent"]) {
|
|
284
|
+
--_button-background-color: transparent;
|
|
285
|
+
--_button-primary-content-color: var(--semantics-buttons-neutral-transparent-content-color);
|
|
286
|
+
--_button-secondary-content-color: var(--semantics-buttons-neutral-transparent-content-secondary-color);
|
|
287
|
+
--_button-highlight-border-color: transparent;
|
|
288
|
+
--_button-is-hovered-background-color: transparent;
|
|
289
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-neutral-transparent-is-hovered-content-color);
|
|
290
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-neutral-transparent-is-hovered-content-secondary-color);
|
|
291
|
+
--_button-is-hovered-highlight-border-color: transparent;
|
|
292
|
+
--_button-is-active-background-color: transparent;
|
|
293
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-neutral-transparent-is-active-content-color);
|
|
294
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-neutral-transparent-is-active-content-secondary-color);
|
|
295
|
+
--_button-is-active-highlight-border-color: transparent;
|
|
296
|
+
}
|
|
297
|
+
|
|
298
|
+
:host([expanded][appearance="accent-filled"]),
|
|
299
|
+
:host([expanded][appearance="primary"]) {
|
|
300
|
+
--_button-background-color: var(--semantics-buttons-accent-filled-is-expanded-background-color);
|
|
301
|
+
--_button-primary-content-color: var(--semantics-buttons-accent-filled-is-expanded-content-color);
|
|
302
|
+
--_button-secondary-content-color: var(--semantics-buttons-accent-filled-is-expanded-content-secondary-color);
|
|
303
|
+
--_button-highlight-border-color: var(--semantics-buttons-accent-filled-is-expanded-highlight-border-color);
|
|
304
|
+
--_button-is-hovered-background-color: var(--semantics-buttons-accent-filled-is-expanded-is-hovered-background-color);
|
|
305
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-accent-filled-is-expanded-is-hovered-content-color);
|
|
306
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-accent-filled-is-expanded-is-hovered-content-secondary-color);
|
|
307
|
+
--_button-is-hovered-highlight-border-color: var(--semantics-buttons-accent-filled-is-expanded-is-hovered-highlight-border-color);
|
|
308
|
+
--_button-is-active-background-color: var(--semantics-buttons-accent-filled-is-expanded-is-active-background-color);
|
|
309
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-accent-filled-is-expanded-is-active-content-color);
|
|
310
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-accent-filled-is-expanded-is-active-content-secondary-color);
|
|
311
|
+
--_button-is-active-highlight-border-color: var(--semantics-buttons-accent-filled-is-expanded-is-active-highlight-border-color);
|
|
312
|
+
}
|
|
313
|
+
|
|
314
|
+
:host([expanded][appearance="accent-transparent"]) {
|
|
315
|
+
--_button-background-color: transparent;
|
|
316
|
+
--_button-primary-content-color: var(--semantics-buttons-accent-transparent-content-color);
|
|
317
|
+
--_button-secondary-content-color: var(--semantics-buttons-accent-transparent-content-secondary-color);
|
|
318
|
+
--_button-highlight-border-color: transparent;
|
|
319
|
+
--_button-is-hovered-background-color: transparent;
|
|
320
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-accent-transparent-is-hovered-content-color);
|
|
321
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-accent-transparent-is-hovered-content-secondary-color);
|
|
322
|
+
--_button-is-hovered-highlight-border-color: transparent;
|
|
323
|
+
--_button-is-active-background-color: transparent;
|
|
324
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-accent-transparent-is-active-content-color);
|
|
325
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-accent-transparent-is-active-content-secondary-color);
|
|
326
|
+
--_button-is-active-highlight-border-color: transparent;
|
|
327
|
+
}
|
|
328
|
+
|
|
329
|
+
:host([expanded][appearance="critical-tinted"]),
|
|
330
|
+
:host([expanded][appearance="destructive"]) {
|
|
331
|
+
--_button-background-color: var(--semantics-buttons-critical-tinted-is-expanded-background-color);
|
|
332
|
+
--_button-primary-content-color: var(--semantics-buttons-critical-tinted-is-expanded-content-color);
|
|
333
|
+
--_button-secondary-content-color: var(--semantics-buttons-critical-tinted-is-expanded-content-secondary-color);
|
|
334
|
+
--_button-highlight-border-color: var(--semantics-buttons-critical-tinted-is-expanded-highlight-border-color);
|
|
335
|
+
--_button-is-hovered-background-color: var(--semantics-buttons-critical-tinted-is-expanded-is-hovered-background-color);
|
|
336
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-critical-tinted-is-expanded-is-hovered-content-color);
|
|
337
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-critical-tinted-is-expanded-is-hovered-content-secondary-color);
|
|
338
|
+
--_button-is-hovered-highlight-border-color: var(--semantics-buttons-critical-tinted-is-expanded-is-hovered-highlight-border-color);
|
|
339
|
+
--_button-is-active-background-color: var(--semantics-buttons-critical-tinted-is-expanded-is-active-background-color);
|
|
340
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-critical-tinted-is-expanded-is-active-content-color);
|
|
341
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-critical-tinted-is-expanded-is-active-content-secondary-color);
|
|
342
|
+
--_button-is-active-highlight-border-color: var(--semantics-buttons-critical-tinted-is-expanded-is-active-highlight-border-color);
|
|
343
|
+
}
|
|
344
|
+
|
|
345
|
+
:host([expanded][appearance="critical-transparent"]) {
|
|
346
|
+
--_button-background-color: transparent;
|
|
347
|
+
--_button-primary-content-color: var(--semantics-buttons-critical-transparent-content-color);
|
|
348
|
+
--_button-secondary-content-color: var(--semantics-buttons-critical-transparent-content-secondary-color);
|
|
349
|
+
--_button-highlight-border-color: transparent;
|
|
350
|
+
--_button-is-hovered-background-color: transparent;
|
|
351
|
+
--_button-is-hovered-primary-content-color: var(--semantics-buttons-critical-transparent-is-hovered-content-color);
|
|
352
|
+
--_button-is-hovered-secondary-content-color: var(--semantics-buttons-critical-transparent-is-hovered-content-secondary-color);
|
|
353
|
+
--_button-is-hovered-highlight-border-color: transparent;
|
|
354
|
+
--_button-is-active-background-color: transparent;
|
|
355
|
+
--_button-is-active-primary-content-color: var(--semantics-buttons-critical-transparent-is-active-content-color);
|
|
356
|
+
--_button-is-active-secondary-content-color: var(--semantics-buttons-critical-transparent-is-active-content-secondary-color);
|
|
357
|
+
--_button-is-active-highlight-border-color: transparent;
|
|
358
|
+
}
|
|
359
|
+
|
|
360
|
+
:host([width="full"]) {
|
|
361
|
+
display: block;
|
|
362
|
+
width: 100%;
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
:host([horizontal-alignment="left"]) .button {
|
|
366
|
+
justify-content: flex-start;
|
|
367
|
+
text-align: left;
|
|
368
|
+
}
|
|
369
|
+
|
|
370
|
+
:host([horizontal-alignment="right"]) .button {
|
|
371
|
+
justify-content: flex-end;
|
|
372
|
+
text-align: right;
|
|
373
|
+
}
|
|
374
|
+
|
|
375
|
+
:host([hidden]) {
|
|
376
|
+
display: none;
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
:host([disabled]) {
|
|
380
|
+
opacity: var(--primitives-opacity-disabled);
|
|
381
|
+
pointer-events: none;
|
|
382
|
+
}
|
|
383
|
+
|
|
384
|
+
:host([no-highlight-border]),
|
|
385
|
+
:host([no-highlight-border][expanded]) {
|
|
386
|
+
--_button-highlight-border-color: transparent;
|
|
387
|
+
--_button-is-hovered-highlight-border-color: transparent;
|
|
388
|
+
--_button-is-active-highlight-border-color: transparent;
|
|
389
|
+
}
|
|
390
|
+
|
|
391
|
+
|
|
392
|
+
/* # Block */
|
|
393
|
+
|
|
394
|
+
.button {
|
|
395
|
+
box-sizing: border-box;
|
|
396
|
+
display: inline-flex;
|
|
397
|
+
position: relative;
|
|
398
|
+
margin: 0;
|
|
399
|
+
border: none;
|
|
400
|
+
border-radius: var(--_button-corner-radius);
|
|
401
|
+
background: none;
|
|
402
|
+
background-color: var(--_button-background-color);
|
|
403
|
+
box-shadow: inset 0 0 0 var(--primitives-border-width-thin) var(--_button-highlight-border-color);
|
|
404
|
+
width: var(--_button-width);
|
|
405
|
+
min-width: var(--_button-min-size);
|
|
406
|
+
max-width: 100%;
|
|
407
|
+
min-height: var(--_button-min-size);
|
|
408
|
+
padding: var(--_button-block-padding) var(--_button-inline-padding);
|
|
409
|
+
gap: var(--_button-gap);
|
|
410
|
+
align-items: center;
|
|
411
|
+
justify-content: center;
|
|
412
|
+
color: var(--_button-primary-content-color);
|
|
413
|
+
font: var(--_button-font);
|
|
414
|
+
text-align: center;
|
|
415
|
+
text-decoration: none;
|
|
416
|
+
text-wrap: pretty;
|
|
417
|
+
transition:
|
|
418
|
+
background-color var(--primitives-transition-duration-fast) var(--primitives-transition-easing-default),
|
|
419
|
+
color var(--primitives-transition-duration-fast) var(--primitives-transition-easing-default)
|
|
420
|
+
;
|
|
421
|
+
appearance: none;
|
|
422
|
+
}
|
|
423
|
+
|
|
424
|
+
a.button {
|
|
425
|
+
cursor: var(--semantics-controls-link-cursor);
|
|
426
|
+
}
|
|
427
|
+
|
|
428
|
+
.button:hover {
|
|
429
|
+
@media (hover: hover) {
|
|
430
|
+
background-color: var(--_button-is-hovered-background-color);
|
|
431
|
+
color: var(--_button-is-hovered-primary-content-color);
|
|
432
|
+
--_button-highlight-border-color: var(--_button-is-hovered-highlight-border-color);
|
|
433
|
+
}
|
|
434
|
+
}
|
|
435
|
+
|
|
436
|
+
.button:active {
|
|
437
|
+
background-color: var(--_button-is-active-background-color);
|
|
438
|
+
color: var(--_button-is-active-primary-content-color);
|
|
439
|
+
--_button-highlight-border-color: var(--_button-is-active-highlight-border-color);
|
|
440
|
+
}
|
|
441
|
+
|
|
442
|
+
/* Loading keeps the control focusable (not disabled); activation is blocked in JS. */
|
|
443
|
+
:host([loading]) .button {
|
|
444
|
+
cursor: default;
|
|
445
|
+
}
|
|
446
|
+
|
|
447
|
+
.button:focus-visible {
|
|
448
|
+
outline: var(--semantics-focus-ring-outline);
|
|
449
|
+
outline-offset: var(--semantics-focus-ring-outline-offset);
|
|
450
|
+
box-shadow: var(--semantics-focus-ring-box-shadow), inset 0 0 0 var(--primitives-border-width-thin) var(--_button-highlight-border-color);
|
|
451
|
+
}
|
|
452
|
+
|
|
453
|
+
.button:focus:not(:focus-visible) {
|
|
454
|
+
outline: none;
|
|
455
|
+
}
|
|
456
|
+
|
|
457
|
+
@media (prefers-reduced-motion: reduce) {
|
|
458
|
+
.button,
|
|
459
|
+
.button__content {
|
|
460
|
+
transition: none;
|
|
461
|
+
}
|
|
462
|
+
}
|
|
463
|
+
|
|
464
|
+
|
|
465
|
+
/* # Elements */
|
|
466
|
+
|
|
467
|
+
.button__content {
|
|
468
|
+
display: inline-flex;
|
|
469
|
+
max-width: 100%;
|
|
470
|
+
min-width: 0;
|
|
471
|
+
align-items: center;
|
|
472
|
+
/* Space between the icons and the text-area. Was padding-inline on the
|
|
473
|
+
text-area; a flex gap keeps it off the text and out of the no-icon edges. */
|
|
474
|
+
gap: var(--_button-gap);
|
|
475
|
+
transition: opacity var(--primitives-transition-duration-slow) var(--primitives-transition-easing-default);
|
|
476
|
+
}
|
|
477
|
+
|
|
478
|
+
/* Loading crossfades the content out (opacity, not visibility, so the button
|
|
479
|
+
keeps its accessible name) while the indicator fades in. The content stays
|
|
480
|
+
laid out, so the button keeps its width. */
|
|
481
|
+
:host([loading]) .button__content {
|
|
482
|
+
opacity: 0;
|
|
483
|
+
}
|
|
484
|
+
|
|
485
|
+
:host([loading]) .button__disclosure-icon {
|
|
486
|
+
opacity: 0;
|
|
487
|
+
}
|
|
488
|
+
|
|
489
|
+
/* Wrapper overlaid on the control, positioned against the host (which is
|
|
490
|
+
position:relative). It lives outside the <button>/<a> so the indicator's
|
|
491
|
+
role="status" live region announces loading without joining the button's
|
|
492
|
+
accessible name. The activity-indicator inside fills it and centers its
|
|
493
|
+
circle, which inherits the content color via currentColor. */
|
|
494
|
+
.button__activity-indicator {
|
|
495
|
+
position: absolute;
|
|
496
|
+
inset: 0;
|
|
497
|
+
color: var(--_button-primary-content-color);
|
|
498
|
+
}
|
|
499
|
+
|
|
500
|
+
::slotted(nldd-icon) {
|
|
501
|
+
display: none;
|
|
502
|
+
}
|
|
503
|
+
|
|
504
|
+
.button__text {
|
|
505
|
+
min-width: 0;
|
|
506
|
+
}
|
|
507
|
+
|
|
508
|
+
/* A capped button truncates by itself: max-width is there to keep the button
|
|
509
|
+
within a bound, and a label that wrapped to three lines would defeat that. */
|
|
510
|
+
:host([single-line]) .button__text,
|
|
511
|
+
:host([max-width]) .button__text {
|
|
512
|
+
overflow: hidden;
|
|
513
|
+
text-overflow: ellipsis;
|
|
514
|
+
white-space: nowrap;
|
|
515
|
+
}
|
|
516
|
+
|
|
517
|
+
.button__text-area {
|
|
518
|
+
display: flex;
|
|
519
|
+
flex-direction: column;
|
|
520
|
+
min-width: 0;
|
|
521
|
+
}
|
|
522
|
+
|
|
523
|
+
:host([size="xs"]) .button__text-area,
|
|
524
|
+
:host([size="sm"]) .button__text-area {
|
|
525
|
+
flex-direction: row;
|
|
526
|
+
align-items: baseline;
|
|
527
|
+
gap: var(--_button-gap);
|
|
528
|
+
}
|
|
529
|
+
|
|
530
|
+
.button__supporting-text {
|
|
531
|
+
min-width: 0;
|
|
532
|
+
color: var(--_button-secondary-content-color);
|
|
533
|
+
font: var(--_button-supporting-font);
|
|
534
|
+
text-wrap: pretty;
|
|
535
|
+
}
|
|
536
|
+
|
|
537
|
+
.button:hover .button__supporting-text {
|
|
538
|
+
@media (hover: hover) {
|
|
539
|
+
color: var(--_button-is-hovered-secondary-content-color);
|
|
540
|
+
}
|
|
541
|
+
}
|
|
542
|
+
|
|
543
|
+
.button:active .button__supporting-text {
|
|
544
|
+
color: var(--_button-is-active-secondary-content-color);
|
|
545
|
+
}
|
|
546
|
+
|
|
547
|
+
/* Visually-hidden link hint (another website, a new tab);
|
|
548
|
+
part of the link's accessible name but never shown. Standard recipe. */
|
|
549
|
+
.button__link-hint {
|
|
550
|
+
position: absolute;
|
|
551
|
+
margin: -1px;
|
|
552
|
+
border: 0;
|
|
553
|
+
width: 1px;
|
|
554
|
+
height: 1px;
|
|
555
|
+
overflow: hidden;
|
|
556
|
+
padding: 0;
|
|
557
|
+
white-space: nowrap;
|
|
558
|
+
clip-path: inset(50%);
|
|
559
|
+
}
|
|
560
|
+
|
|
561
|
+
:host([single-line]) .button__supporting-text,
|
|
562
|
+
:host([max-width]) .button__supporting-text {
|
|
563
|
+
overflow: hidden;
|
|
564
|
+
text-overflow: ellipsis;
|
|
565
|
+
white-space: nowrap;
|
|
566
|
+
}
|
|
567
|
+
|
|
568
|
+
:host(:not([size])) .button.has-supporting-text,
|
|
569
|
+
:host([size="md"]) .button.has-supporting-text {
|
|
570
|
+
--_button-font: var(--semantics-buttons-sm-primary-text-font);
|
|
571
|
+
--_button-icon-size: var(--semantics-buttons-md-has-supporting-text-icon-size);
|
|
572
|
+
--_button-inline-padding: var(--semantics-buttons-md-has-supporting-text-inline-padding);
|
|
573
|
+
--_button-block-padding: var(--primitives-space-4);
|
|
574
|
+
}
|
|
575
|
+
|
|
576
|
+
:host([size="lg"]) .button.has-supporting-text {
|
|
577
|
+
--_button-font: var(--semantics-buttons-md-primary-text-font);
|
|
578
|
+
--_button-icon-size: var(--semantics-buttons-lg-has-supporting-text-icon-size);
|
|
579
|
+
--_button-inline-padding: var(--semantics-buttons-lg-has-supporting-text-inline-padding);
|
|
580
|
+
--_button-block-padding: var(--primitives-space-4);
|
|
581
|
+
}
|
|
582
|
+
|
|
583
|
+
.button__shortcut {
|
|
584
|
+
display: flex;
|
|
585
|
+
flex-shrink: 0;
|
|
586
|
+
color: var(--_button-secondary-content-color);
|
|
587
|
+
}
|
|
588
|
+
|
|
589
|
+
.button:hover .button__shortcut {
|
|
590
|
+
@media (hover: hover) {
|
|
591
|
+
color: var(--_button-is-hovered-secondary-content-color);
|
|
592
|
+
}
|
|
593
|
+
}
|
|
594
|
+
|
|
595
|
+
.button:active .button__shortcut {
|
|
596
|
+
color: var(--_button-is-active-secondary-content-color);
|
|
597
|
+
}
|
|
598
|
+
|
|
599
|
+
@media (any-hover: none) {
|
|
600
|
+
.button__shortcut {
|
|
601
|
+
display: none;
|
|
602
|
+
}
|
|
603
|
+
}
|
|
604
|
+
|
|
605
|
+
.button__start-icon,
|
|
606
|
+
.button__end-icon {
|
|
607
|
+
display: flex;
|
|
608
|
+
width: var(--_button-icon-size);
|
|
609
|
+
height: var(--_button-icon-size);
|
|
610
|
+
flex-shrink: 0;
|
|
611
|
+
align-items: center;
|
|
612
|
+
justify-content: center;
|
|
613
|
+
}
|
|
614
|
+
|
|
615
|
+
/* Those spans are only rendered for the attribute; slotted content lands in a
|
|
616
|
+
bare slot. Sizing it here rather than wrapping the slot in the same span,
|
|
617
|
+
because that span has a width and would reserve icon space on every button
|
|
618
|
+
that has no icon at all. */
|
|
619
|
+
::slotted([slot="start-icon"]),
|
|
620
|
+
::slotted([slot="end-icon"]) {
|
|
621
|
+
flex-shrink: 0;
|
|
622
|
+
width: var(--_button-icon-size);
|
|
623
|
+
height: var(--_button-icon-size);
|
|
624
|
+
}
|
|
625
|
+
|
|
626
|
+
:host([expandable]) .button {
|
|
627
|
+
padding-inline-end: calc(var(--_button-inline-padding) + var(--_button-gap) + var(--_button-disclosure-icon-size));
|
|
628
|
+
}
|
|
629
|
+
|
|
630
|
+
.button__disclosure-icon {
|
|
631
|
+
display: block;
|
|
632
|
+
position: absolute;
|
|
633
|
+
top: 50%;
|
|
634
|
+
inset-inline-end: var(--_button-inline-padding);
|
|
635
|
+
width: var(--_button-disclosure-icon-size);
|
|
636
|
+
height: var(--_button-disclosure-icon-size);
|
|
637
|
+
transform: translateY(-50%);
|
|
638
|
+
}
|
|
639
|
+
`;
|
|
640
|
+
// src/components/actions/button/button.template.ts
|
|
641
|
+
function E(e) {
|
|
642
|
+
return i`
|
|
643
|
+
<span class="button__content">
|
|
644
|
+
<slot name="start-icon">${e.startIcon ? i`
|
|
645
|
+
<span class="button__start-icon">
|
|
646
|
+
<nldd-icon icon=${e.startIcon}></nldd-icon>
|
|
647
|
+
</span>
|
|
648
|
+
` : a}</slot>
|
|
649
|
+
<span class="button__text-area">
|
|
650
|
+
<span class="button__text"><slot name="text">${e.text}</slot></span>
|
|
651
|
+
${e.supportingText ? i`<span class="button__supporting-text">${e.supportingText}</span>` : a}
|
|
652
|
+
</span>
|
|
653
|
+
${g(e) ? i`
|
|
654
|
+
<span class="button__shortcut">
|
|
655
|
+
<nldd-keyboard-shortcut
|
|
656
|
+
size="inherit"
|
|
657
|
+
appearance="simple"
|
|
658
|
+
color="inherit"
|
|
659
|
+
keys=${e.shortcut || a}
|
|
660
|
+
mac-keys=${e.shortcutMac || a}
|
|
661
|
+
windows-keys=${e.shortcutWindows || a}
|
|
662
|
+
linux-keys=${e.shortcutLinux || a}
|
|
663
|
+
></nldd-keyboard-shortcut>
|
|
664
|
+
</span>
|
|
665
|
+
` : a}
|
|
666
|
+
<slot name="end-icon">${e.endIcon ? i`
|
|
667
|
+
<span class="button__end-icon">
|
|
668
|
+
<nldd-icon icon=${e.endIcon}></nldd-icon>
|
|
669
|
+
</span>
|
|
670
|
+
` : a}</slot>
|
|
671
|
+
</span>
|
|
672
|
+
${e.expandable ? i`
|
|
673
|
+
<nldd-icon class="button__disclosure-icon"
|
|
674
|
+
icon="chevron-down-small"
|
|
675
|
+
></nldd-icon>
|
|
676
|
+
` : a}
|
|
677
|
+
`;
|
|
678
|
+
}
|
|
679
|
+
function D(e) {
|
|
680
|
+
let t = E(this), n = ["button", this.supportingText ? "has-supporting-text" : ""].filter(Boolean).join(" "), r = this.expandable || this.popupType ? String(this.expanded) : this.expanded ? "true" : a, o = p(this.href, this.target, this.download);
|
|
681
|
+
this.href && f(this, this.download, this.target);
|
|
682
|
+
let s = o ? this._t(`components.button.${o}`) : "", c = this.accessibleLabel || (this.supportingText ? [this.text, this.supportingText].filter(Boolean).join(", ") : ""), l = c ? [c, m(this)].filter(Boolean).join(" ") : "", u = l ? [l, s].filter(Boolean).join(", ") : a, h = !!s && !c, g = this.loading ? "true" : a, v = this.loading ? i`
|
|
683
|
+
<div class="button__activity-indicator">
|
|
684
|
+
<nldd-activity-indicator
|
|
685
|
+
timing="instant"
|
|
686
|
+
size=${this.size === "xs" ? "16" : this.size === "sm" ? "20" : this.size === "lg" ? "28" : "24"}
|
|
687
|
+
text=${this.loadingText || a}
|
|
688
|
+
></nldd-activity-indicator>
|
|
689
|
+
</div>
|
|
690
|
+
` : a, y = i`<slot name="popup" @slotchange=${this._popup.handleSlotChange}></slot>`;
|
|
691
|
+
if (this.href) {
|
|
692
|
+
let o = d(this.rel, this.target);
|
|
693
|
+
return i`
|
|
694
|
+
<a class=${n}
|
|
695
|
+
href=${this.href}
|
|
696
|
+
target=${this.target || a}
|
|
697
|
+
rel=${o || a}
|
|
698
|
+
download=${this.download ?? a}
|
|
699
|
+
aria-disabled=${this.disabled ? "true" : a}
|
|
700
|
+
aria-label=${u}
|
|
701
|
+
aria-haspopup=${this.popupType || a}
|
|
702
|
+
aria-expanded=${r}
|
|
703
|
+
aria-busy=${g}
|
|
704
|
+
tabindex=${this.noTab ? "-1" : a}
|
|
705
|
+
@pointerdown=${this._popup.handlePointerdown}
|
|
706
|
+
@click=${e.handleClick}
|
|
707
|
+
>
|
|
708
|
+
${t}${h ? i`<span class="button__link-hint">, ${s}</span>` : a}
|
|
709
|
+
</a>
|
|
710
|
+
${v}
|
|
711
|
+
${y}
|
|
712
|
+
`;
|
|
713
|
+
}
|
|
714
|
+
return i`
|
|
715
|
+
<button class=${n}
|
|
716
|
+
type=${this.type}
|
|
717
|
+
?disabled=${this.disabled}
|
|
718
|
+
aria-disabled=${this.disabled ? "true" : a}
|
|
719
|
+
aria-label=${u}
|
|
720
|
+
aria-haspopup=${this.popupType || a}
|
|
721
|
+
aria-expanded=${r}
|
|
722
|
+
aria-busy=${g}
|
|
723
|
+
tabindex=${this.noTab ? "-1" : a}
|
|
724
|
+
.popoverTargetElement=${_(this, this.popovertarget, this.popoverTargetElement)}
|
|
725
|
+
.popoverTargetAction=${this.popoverTargetAction}
|
|
726
|
+
@pointerdown=${this._popup.handlePointerdown}
|
|
727
|
+
@click=${e.handleClick}
|
|
728
|
+
>
|
|
729
|
+
${t}
|
|
730
|
+
</button>
|
|
731
|
+
${v}
|
|
732
|
+
${y}
|
|
733
|
+
`;
|
|
734
|
+
}
|
|
735
|
+
// src/components/actions/button/button.ts
|
|
736
|
+
var O = /* @__PURE__ */ e({ NLDDButton: () => A }), k = class extends S(y(r, b)) {
|
|
737
|
+
constructor(...e) {
|
|
738
|
+
super(...e), this._internals = l(this), this.appearance = "neutral-tinted", this.size = "md", this.horizontalAlignment = "", this.width = "", this.maxWidth = "", this.noTab = !1, this.expandable = !1, this.expanded = !1, this.type = "button", this.popovertarget = void 0, this.popoverTargetElement = null, this.popoverTargetAction = "toggle", this.loading = !1, this.loadingText = "", this.disabled = !1, this.text = "", this.supportingText = "", this.singleLine = !1, this.noHighlightBorder = !1, this.startIcon = "", this.endIcon = "", this.accessibleLabel = "", this.shortcut = "", this.shortcutMac = "", this.shortcutWindows = "", this.shortcutLinux = "", this.href = void 0, this.target = void 0, this.download = void 0, this.rel = void 0, this._popup = new x(this), this._shortcutAvailability = new h(this);
|
|
739
|
+
}
|
|
740
|
+
disconnectedCallback() {
|
|
741
|
+
super.disconnectedCallback(), v(this, null);
|
|
742
|
+
}
|
|
743
|
+
updated(e) {
|
|
744
|
+
if (v(this, _(this, this.popovertarget, this.popoverTargetElement)), e.has("maxWidth")) {
|
|
745
|
+
let e = !!this.maxWidth && CSS.supports("max-width", this.maxWidth);
|
|
746
|
+
this.style.maxWidth = e ? this.maxWidth : "";
|
|
747
|
+
}
|
|
748
|
+
if (e.has("width")) {
|
|
749
|
+
let e = this.width, t = e === "full", n = !!e && !t && CSS.supports("width", e);
|
|
750
|
+
this.style.width = n ? e : "", t || n ? this.style.setProperty("--_button-width", "100%") : this.style.removeProperty("--_button-width");
|
|
751
|
+
}
|
|
752
|
+
}
|
|
753
|
+
_handleClick(e) {
|
|
754
|
+
if (this.disabled || this.loading) {
|
|
755
|
+
e.preventDefault(), e.stopPropagation();
|
|
756
|
+
return;
|
|
757
|
+
}
|
|
758
|
+
if (e.currentTarget instanceof HTMLButtonElement && (e.currentTarget.popoverTargetElement = _(this, this.popovertarget, this.popoverTargetElement), v(this, e.currentTarget.popoverTargetElement)), this._popup.handleClick(e)) {
|
|
759
|
+
e.preventDefault();
|
|
760
|
+
return;
|
|
761
|
+
}
|
|
762
|
+
if (this.href) return;
|
|
763
|
+
let t = this._ownerForm();
|
|
764
|
+
this.type === "submit" ? t?.requestSubmit() : this.type === "reset" && t?.reset();
|
|
765
|
+
}
|
|
766
|
+
_ownerForm() {
|
|
767
|
+
return w(this, this._internals);
|
|
768
|
+
}
|
|
769
|
+
focus(e) {
|
|
770
|
+
C(this, e) || this.shadowRoot?.querySelector(".button")?.focus(e);
|
|
771
|
+
}
|
|
772
|
+
describedTarget() {
|
|
773
|
+
return this.shadowRoot?.querySelector("button, a") ?? null;
|
|
774
|
+
}
|
|
775
|
+
render() {
|
|
776
|
+
return D.call(this, { handleClick: this._handleClick.bind(this) });
|
|
777
|
+
}
|
|
778
|
+
}, A = (k.styles = T, k.formAssociated = !0, k);
|
|
779
|
+
o([n({
|
|
780
|
+
reflect: !0,
|
|
781
|
+
converter: c("neutral-tinted")
|
|
782
|
+
})], A.prototype, "appearance", void 0), o([n({
|
|
783
|
+
reflect: !0,
|
|
784
|
+
converter: c("md")
|
|
785
|
+
})], A.prototype, "size", void 0), o([n({
|
|
786
|
+
reflect: !0,
|
|
787
|
+
attribute: "horizontal-alignment",
|
|
788
|
+
converter: c("")
|
|
789
|
+
})], A.prototype, "horizontalAlignment", void 0), o([n({
|
|
790
|
+
reflect: !0,
|
|
791
|
+
converter: c("")
|
|
792
|
+
})], A.prototype, "width", void 0), o([n({
|
|
793
|
+
reflect: !0,
|
|
794
|
+
attribute: "max-width",
|
|
795
|
+
converter: c("")
|
|
796
|
+
})], A.prototype, "maxWidth", void 0), o([n({
|
|
797
|
+
type: Boolean,
|
|
798
|
+
reflect: !0,
|
|
799
|
+
attribute: "no-tab"
|
|
800
|
+
})], A.prototype, "noTab", void 0), o([n({
|
|
801
|
+
type: Boolean,
|
|
802
|
+
reflect: !0,
|
|
803
|
+
attribute: "expandable"
|
|
804
|
+
})], A.prototype, "expandable", void 0), o([n({
|
|
805
|
+
type: Boolean,
|
|
806
|
+
reflect: !0
|
|
807
|
+
})], A.prototype, "expanded", void 0), o([n({
|
|
808
|
+
type: String,
|
|
809
|
+
reflect: !0,
|
|
810
|
+
attribute: "popup-type"
|
|
811
|
+
})], A.prototype, "popupType", void 0), o([n({
|
|
812
|
+
reflect: !0,
|
|
813
|
+
converter: c("button")
|
|
814
|
+
})], A.prototype, "type", void 0), o([n({ type: String })], A.prototype, "popovertarget", void 0), o([n({ attribute: !1 })], A.prototype, "popoverTargetElement", void 0), o([n({ attribute: !1 })], A.prototype, "popoverTargetAction", void 0), o([n({
|
|
815
|
+
type: Boolean,
|
|
816
|
+
reflect: !0
|
|
817
|
+
})], A.prototype, "loading", void 0), o([n({ attribute: "loading-text" })], A.prototype, "loadingText", void 0), o([n({
|
|
818
|
+
type: Boolean,
|
|
819
|
+
reflect: !0
|
|
820
|
+
})], A.prototype, "disabled", void 0), o([n({
|
|
821
|
+
reflect: !0,
|
|
822
|
+
converter: c("")
|
|
823
|
+
})], A.prototype, "text", void 0), o([n({
|
|
824
|
+
reflect: !0,
|
|
825
|
+
attribute: "supporting-text",
|
|
826
|
+
converter: c("")
|
|
827
|
+
})], A.prototype, "supportingText", void 0), o([n({
|
|
828
|
+
type: Boolean,
|
|
829
|
+
reflect: !0,
|
|
830
|
+
attribute: "single-line"
|
|
831
|
+
})], A.prototype, "singleLine", void 0), o([n({
|
|
832
|
+
type: Boolean,
|
|
833
|
+
reflect: !0,
|
|
834
|
+
attribute: "no-highlight-border"
|
|
835
|
+
})], A.prototype, "noHighlightBorder", void 0), o([n({
|
|
836
|
+
type: String,
|
|
837
|
+
attribute: "start-icon"
|
|
838
|
+
})], A.prototype, "startIcon", void 0), o([n({
|
|
839
|
+
type: String,
|
|
840
|
+
attribute: "end-icon"
|
|
841
|
+
})], A.prototype, "endIcon", void 0), o([n({
|
|
842
|
+
type: String,
|
|
843
|
+
attribute: "accessible-label"
|
|
844
|
+
})], A.prototype, "accessibleLabel", void 0), o([n({
|
|
845
|
+
reflect: !0,
|
|
846
|
+
converter: c("")
|
|
847
|
+
})], A.prototype, "shortcut", void 0), o([n({
|
|
848
|
+
reflect: !0,
|
|
849
|
+
attribute: "shortcut-mac",
|
|
850
|
+
converter: c("")
|
|
851
|
+
})], A.prototype, "shortcutMac", void 0), o([n({
|
|
852
|
+
reflect: !0,
|
|
853
|
+
attribute: "shortcut-windows",
|
|
854
|
+
converter: c("")
|
|
855
|
+
})], A.prototype, "shortcutWindows", void 0), o([n({
|
|
856
|
+
reflect: !0,
|
|
857
|
+
attribute: "shortcut-linux",
|
|
858
|
+
converter: c("")
|
|
859
|
+
})], A.prototype, "shortcutLinux", void 0), o([n({
|
|
860
|
+
type: String,
|
|
861
|
+
reflect: !0
|
|
862
|
+
})], A.prototype, "href", void 0), o([n({ type: String })], A.prototype, "target", void 0), o([n({ type: String })], A.prototype, "download", void 0), o([n({ type: String })], A.prototype, "rel", void 0), A = o([s("nldd-button")], A);
|
|
863
|
+
export { O as t };
|