@helixui/library 3.3.1 → 3.4.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 +340 -71
- package/dist/components/hx-accordion/hx-accordion-item.d.ts +35 -0
- package/dist/components/hx-accordion/hx-accordion-item.d.ts.map +1 -1
- package/dist/components/hx-alert/hx-alert.d.ts +11 -0
- package/dist/components/hx-alert/hx-alert.d.ts.map +1 -1
- package/dist/components/hx-alert/hx-alert.styles.d.ts.map +1 -1
- package/dist/components/hx-alert/index.js +1 -1
- package/dist/components/hx-badge/hx-badge.styles.d.ts.map +1 -1
- package/dist/components/hx-badge/index.js +1 -1
- package/dist/components/hx-banner/hx-banner.d.ts +9 -1
- package/dist/components/hx-banner/hx-banner.d.ts.map +1 -1
- package/dist/components/hx-banner/index.js +1 -1
- package/dist/components/hx-button/hx-button.d.ts +11 -1
- package/dist/components/hx-button/hx-button.d.ts.map +1 -1
- package/dist/components/hx-button/index.js +1 -1
- package/dist/components/hx-button-group/hx-button-group.d.ts +13 -0
- package/dist/components/hx-button-group/hx-button-group.d.ts.map +1 -1
- package/dist/components/hx-button-group/index.js +1 -1
- package/dist/components/hx-checkbox/hx-checkbox.d.ts +153 -1
- package/dist/components/hx-checkbox/hx-checkbox.d.ts.map +1 -1
- package/dist/components/hx-checkbox/hx-checkbox.styles.d.ts.map +1 -1
- package/dist/components/hx-checkbox/index.js +1 -1
- package/dist/components/hx-checkbox-group/hx-checkbox-group.d.ts +151 -2
- package/dist/components/hx-checkbox-group/hx-checkbox-group.d.ts.map +1 -1
- package/dist/components/hx-checkbox-group/index.js +1 -1
- package/dist/components/hx-color-picker/hx-color-picker.d.ts +163 -1
- package/dist/components/hx-color-picker/hx-color-picker.d.ts.map +1 -1
- package/dist/components/hx-color-picker/hx-color-picker.styles.d.ts.map +1 -1
- package/dist/components/hx-color-picker/index.js +1 -1
- package/dist/components/hx-combobox/hx-combobox.d.ts +311 -2
- package/dist/components/hx-combobox/hx-combobox.d.ts.map +1 -1
- package/dist/components/hx-combobox/index.js +1 -1
- package/dist/components/hx-data-table/hx-data-table.d.ts.map +1 -1
- package/dist/components/hx-data-table/index.js +1 -1
- package/dist/components/hx-date-picker/hx-date-picker.d.ts +182 -56
- package/dist/components/hx-date-picker/hx-date-picker.d.ts.map +1 -1
- package/dist/components/hx-date-picker/hx-date-picker.styles.d.ts.map +1 -1
- package/dist/components/hx-date-picker/index.js +1 -1
- package/dist/components/hx-dialog/hx-dialog.d.ts +240 -0
- package/dist/components/hx-dialog/hx-dialog.d.ts.map +1 -1
- package/dist/components/hx-dialog/index.js +1 -1
- package/dist/components/hx-drawer/hx-drawer.d.ts +201 -0
- package/dist/components/hx-drawer/hx-drawer.d.ts.map +1 -1
- package/dist/components/hx-drawer/hx-drawer.styles.d.ts.map +1 -1
- package/dist/components/hx-drawer/index.js +1 -1
- package/dist/components/hx-dropdown/hx-dropdown.d.ts +168 -0
- package/dist/components/hx-dropdown/hx-dropdown.d.ts.map +1 -1
- package/dist/components/hx-dropdown/index.js +1 -1
- package/dist/components/hx-field/hx-field.d.ts +109 -0
- package/dist/components/hx-field/hx-field.d.ts.map +1 -1
- package/dist/components/hx-field/index.js +1 -1
- package/dist/components/hx-icon-button/hx-icon-button.d.ts +16 -3
- package/dist/components/hx-icon-button/hx-icon-button.d.ts.map +1 -1
- package/dist/components/hx-icon-button/hx-icon-button.styles.d.ts.map +1 -1
- package/dist/components/hx-icon-button/index.js +1 -1
- package/dist/components/hx-link/hx-link.d.ts +10 -1
- package/dist/components/hx-link/hx-link.d.ts.map +1 -1
- package/dist/components/hx-link/index.js +1 -1
- package/dist/components/hx-list/hx-list-item.d.ts +27 -1
- package/dist/components/hx-list/hx-list-item.d.ts.map +1 -1
- package/dist/components/hx-list/hx-list.d.ts +28 -0
- package/dist/components/hx-list/hx-list.d.ts.map +1 -1
- package/dist/components/hx-list/index.js +1 -1
- package/dist/components/hx-menu/hx-menu-divider.d.ts +10 -0
- package/dist/components/hx-menu/hx-menu-divider.d.ts.map +1 -1
- package/dist/components/hx-menu/hx-menu-item.d.ts +99 -2
- package/dist/components/hx-menu/hx-menu-item.d.ts.map +1 -1
- package/dist/components/hx-menu/hx-menu-item.styles.d.ts.map +1 -1
- package/dist/components/hx-menu/hx-menu.d.ts +117 -2
- package/dist/components/hx-menu/hx-menu.d.ts.map +1 -1
- package/dist/components/hx-menu/index.js +1 -1
- package/dist/components/hx-meter/hx-meter.d.ts +39 -0
- package/dist/components/hx-meter/hx-meter.d.ts.map +1 -1
- package/dist/components/hx-meter/hx-meter.styles.d.ts.map +1 -1
- package/dist/components/hx-meter/index.js +1 -1
- package/dist/components/hx-overflow-menu/hx-overflow-menu.d.ts +132 -1
- package/dist/components/hx-overflow-menu/hx-overflow-menu.d.ts.map +1 -1
- package/dist/components/hx-overflow-menu/index.js +1 -1
- package/dist/components/hx-phi-field/hx-phi-field.d.ts +0 -1
- package/dist/components/hx-phi-field/hx-phi-field.d.ts.map +1 -1
- package/dist/components/hx-popover/hx-popover.d.ts +91 -0
- package/dist/components/hx-popover/hx-popover.d.ts.map +1 -1
- package/dist/components/hx-popover/index.js +1 -1
- package/dist/components/hx-progress-bar/hx-progress-bar.d.ts +33 -0
- package/dist/components/hx-progress-bar/hx-progress-bar.d.ts.map +1 -1
- package/dist/components/hx-progress-bar/index.js +1 -1
- package/dist/components/hx-radio-group/hx-radio-group.d.ts +152 -1
- package/dist/components/hx-radio-group/hx-radio-group.d.ts.map +1 -1
- package/dist/components/hx-radio-group/hx-radio.d.ts +14 -0
- package/dist/components/hx-radio-group/hx-radio.d.ts.map +1 -1
- package/dist/components/hx-radio-group/index.js +1 -1
- package/dist/components/hx-select/hx-select.d.ts +304 -2
- package/dist/components/hx-select/hx-select.d.ts.map +1 -1
- package/dist/components/hx-select/hx-select.styles.d.ts.map +1 -1
- package/dist/components/hx-select/index.js +1 -1
- package/dist/components/hx-side-nav/hx-nav-item.styles.d.ts.map +1 -1
- package/dist/components/hx-side-nav/index.js +1 -1
- package/dist/components/hx-spinner/hx-spinner.d.ts +14 -0
- package/dist/components/hx-spinner/hx-spinner.d.ts.map +1 -1
- package/dist/components/hx-spinner/index.js +1 -1
- package/dist/components/hx-split-button/hx-split-button.d.ts +94 -7
- package/dist/components/hx-split-button/hx-split-button.d.ts.map +1 -1
- package/dist/components/hx-split-button/index.js +1 -1
- package/dist/components/hx-stat/hx-stat.d.ts +28 -0
- package/dist/components/hx-stat/hx-stat.d.ts.map +1 -1
- package/dist/components/hx-stat/index.js +1 -1
- package/dist/components/hx-switch/hx-switch.d.ts +78 -1
- package/dist/components/hx-switch/hx-switch.d.ts.map +1 -1
- package/dist/components/hx-switch/hx-switch.styles.d.ts.map +1 -1
- package/dist/components/hx-switch/index.js +1 -1
- package/dist/components/hx-table/hx-td.d.ts +30 -3
- package/dist/components/hx-table/hx-td.d.ts.map +1 -1
- package/dist/components/hx-table/hx-th.d.ts +39 -3
- package/dist/components/hx-table/hx-th.d.ts.map +1 -1
- package/dist/components/hx-table/hx-tr.d.ts +26 -0
- package/dist/components/hx-table/hx-tr.d.ts.map +1 -1
- package/dist/components/hx-table/index.js +1 -1
- package/dist/components/hx-tabs/hx-tab-panel.d.ts +34 -0
- package/dist/components/hx-tabs/hx-tab-panel.d.ts.map +1 -1
- package/dist/components/hx-tabs/hx-tab.d.ts +45 -2
- package/dist/components/hx-tabs/hx-tab.d.ts.map +1 -1
- package/dist/components/hx-tabs/hx-tab.styles.d.ts.map +1 -1
- package/dist/components/hx-tabs/hx-tabs.d.ts +32 -2
- package/dist/components/hx-tabs/hx-tabs.d.ts.map +1 -1
- package/dist/components/hx-tabs/index.js +1 -1
- package/dist/components/hx-tag/hx-tag.styles.d.ts.map +1 -1
- package/dist/components/hx-tag/index.js +1 -1
- package/dist/components/hx-theme/hx-theme.d.ts +10 -5
- package/dist/components/hx-theme/hx-theme.d.ts.map +1 -1
- package/dist/components/hx-time-picker/hx-time-picker.d.ts +210 -2
- package/dist/components/hx-time-picker/hx-time-picker.d.ts.map +1 -1
- package/dist/components/hx-time-picker/hx-time-picker.styles.d.ts.map +1 -1
- package/dist/components/hx-time-picker/index.js +1 -1
- package/dist/components/hx-toast/hx-toast-stack.d.ts +14 -0
- package/dist/components/hx-toast/hx-toast-stack.d.ts.map +1 -1
- package/dist/components/hx-toast/hx-toast.d.ts +22 -3
- package/dist/components/hx-toast/hx-toast.d.ts.map +1 -1
- package/dist/components/hx-toast/index.js +1 -1
- package/dist/components/hx-toast/toast-factory.d.ts.map +1 -1
- package/dist/components/hx-toggle-button/hx-toggle-button.d.ts +110 -0
- package/dist/components/hx-toggle-button/hx-toggle-button.d.ts.map +1 -1
- package/dist/components/hx-toggle-button/hx-toggle-button.styles.d.ts.map +1 -1
- package/dist/components/hx-toggle-button/index.js +1 -1
- package/dist/components/hx-tooltip/hx-tooltip.d.ts +52 -0
- package/dist/components/hx-tooltip/hx-tooltip.d.ts.map +1 -1
- package/dist/components/hx-tooltip/index.js +1 -1
- package/dist/components/hx-tree-view/hx-tree-item.d.ts +117 -12
- package/dist/components/hx-tree-view/hx-tree-item.d.ts.map +1 -1
- package/dist/components/hx-tree-view/hx-tree-view.d.ts +87 -7
- package/dist/components/hx-tree-view/hx-tree-view.d.ts.map +1 -1
- package/dist/components/hx-tree-view/index.js +1 -1
- package/dist/css/helix-all.css +221 -1
- package/dist/css/helix-core.css +81 -0
- package/dist/css/helix-feedback.css +14 -0
- package/dist/css/helix-forms.css +109 -1
- package/dist/css/helix-overlay.css +17 -0
- package/dist/css/hx-alert.css +9 -0
- package/dist/css/hx-badge.css +28 -0
- package/dist/css/hx-checkbox.css +18 -0
- package/dist/css/hx-color-picker.css +25 -0
- package/dist/css/hx-date-picker.css +2 -1
- package/dist/css/hx-drawer.css +17 -0
- package/dist/css/hx-icon-button.css +30 -0
- package/dist/css/hx-meter.css +5 -0
- package/dist/css/hx-select.css +19 -0
- package/dist/css/hx-switch.css +17 -0
- package/dist/css/hx-tag.css +23 -0
- package/dist/css/hx-time-picker.css +11 -0
- package/dist/css/hx-toggle-button.css +17 -0
- package/dist/css/index.css +1 -1
- package/dist/css/manifest.json +4 -1
- package/dist/index.js +38 -38
- package/dist/shared/aria-flatten-DY6v2vah.js +22 -0
- package/dist/shared/aria-flatten-DY6v2vah.js.map +1 -0
- package/dist/shared/aria-idref-CxvyzfQS.js +126 -0
- package/dist/shared/aria-idref-CxvyzfQS.js.map +1 -0
- package/dist/shared/hx-accordion-ZVzgDzTG.js.map +1 -1
- package/dist/shared/{hx-alert-CLn7CstP.js → hx-alert-Bto8-TIi.js} +55 -37
- package/dist/shared/hx-alert-Bto8-TIi.js.map +1 -0
- package/dist/shared/{hx-badge-CQXgOXJM.js → hx-badge-JlFtAdxS.js} +37 -9
- package/dist/shared/hx-badge-JlFtAdxS.js.map +1 -0
- package/dist/shared/{hx-banner-D3DzpfcP.js → hx-banner-fpRnciIO.js} +13 -5
- package/dist/shared/hx-banner-fpRnciIO.js.map +1 -0
- package/dist/shared/{hx-button-DPY6SPVT.js → hx-button-BOwAEcF1.js} +108 -85
- package/dist/shared/{hx-button-DPY6SPVT.js.map → hx-button-BOwAEcF1.js.map} +1 -1
- package/dist/shared/{hx-button-group-BI-QBqmO.js → hx-button-group-DcHP5MBv.js} +15 -16
- package/dist/shared/{hx-button-group-BI-QBqmO.js.map → hx-button-group-DcHP5MBv.js.map} +1 -1
- package/dist/shared/hx-checkbox-C48KYKFq.js +696 -0
- package/dist/shared/hx-checkbox-C48KYKFq.js.map +1 -0
- package/dist/shared/hx-checkbox-group-BJIAX3zU.js +496 -0
- package/dist/shared/hx-checkbox-group-BJIAX3zU.js.map +1 -0
- package/dist/shared/hx-color-picker-Dk4cBwYQ.js +1221 -0
- package/dist/shared/hx-color-picker-Dk4cBwYQ.js.map +1 -0
- package/dist/shared/hx-combobox-BTLO9qiK.js +1359 -0
- package/dist/shared/hx-combobox-BTLO9qiK.js.map +1 -0
- package/dist/shared/{hx-data-table-CLqVqdxr.js → hx-data-table-Ct3gQ6ya.js} +3 -2
- package/dist/shared/{hx-data-table-CLqVqdxr.js.map → hx-data-table-Ct3gQ6ya.js.map} +1 -1
- package/dist/shared/{hx-date-picker-2iRG1p74.js → hx-date-picker-CiR7FVnR.js} +542 -206
- package/dist/shared/hx-date-picker-CiR7FVnR.js.map +1 -0
- package/dist/shared/hx-dialog-AOZpHSuF.js +717 -0
- package/dist/shared/hx-dialog-AOZpHSuF.js.map +1 -0
- package/dist/shared/{hx-drawer-Y1Ui2IWJ.js → hx-drawer-DH6CdAN1.js} +300 -98
- package/dist/shared/hx-drawer-DH6CdAN1.js.map +1 -0
- package/dist/shared/hx-dropdown-DiLd40Lm.js +401 -0
- package/dist/shared/hx-dropdown-DiLd40Lm.js.map +1 -0
- package/dist/shared/{hx-field-B3Qo8OLS.js → hx-field-zw0U1KVi.js} +99 -38
- package/dist/shared/hx-field-zw0U1KVi.js.map +1 -0
- package/dist/shared/{hx-icon-button-CGNdQSFM.js → hx-icon-button-a6OpeQz5.js} +149 -68
- package/dist/shared/hx-icon-button-a6OpeQz5.js.map +1 -0
- package/dist/shared/{hx-link-C-O6vq0Q.js → hx-link-CMnZRUtQ.js} +55 -43
- package/dist/shared/hx-link-CMnZRUtQ.js.map +1 -0
- package/dist/shared/{hx-list-MyEhh8c7.js → hx-list-De66EtAP.js} +163 -107
- package/dist/shared/hx-list-De66EtAP.js.map +1 -0
- package/dist/shared/hx-menu-divider-BjiRIWKq.js +797 -0
- package/dist/shared/hx-menu-divider-BjiRIWKq.js.map +1 -0
- package/dist/shared/{hx-meter-BPscsw5t.js → hx-meter-BJdh6nrF.js} +105 -64
- package/dist/shared/hx-meter-BJdh6nrF.js.map +1 -0
- package/dist/shared/{hx-nav-item-xqRPOCWX.js → hx-nav-item-CODtUlew.js} +13 -9
- package/dist/shared/{hx-nav-item-xqRPOCWX.js.map → hx-nav-item-CODtUlew.js.map} +1 -1
- package/dist/shared/hx-overflow-menu-BQ4fiMYu.js +492 -0
- package/dist/shared/hx-overflow-menu-BQ4fiMYu.js.map +1 -0
- package/dist/shared/hx-phi-field-C19oxlrr.js.map +1 -1
- package/dist/shared/{hx-popover-B-FP3-wW.js → hx-popover-B9W8-tC0.js} +123 -66
- package/dist/shared/hx-popover-B9W8-tC0.js.map +1 -0
- package/dist/shared/hx-progress-bar-C8nDMdYa.js +290 -0
- package/dist/shared/hx-progress-bar-C8nDMdYa.js.map +1 -0
- package/dist/shared/hx-radio-Z1lV1zTO.js +822 -0
- package/dist/shared/hx-radio-Z1lV1zTO.js.map +1 -0
- package/dist/shared/hx-select-D18CnJ0e.js +1089 -0
- package/dist/shared/hx-select-D18CnJ0e.js.map +1 -0
- package/dist/shared/{hx-spinner-DL5AYr16.js → hx-spinner-BB0h2hKZ.js} +62 -34
- package/dist/shared/hx-spinner-BB0h2hKZ.js.map +1 -0
- package/dist/shared/{hx-split-button-Djnc5Aeg.js → hx-split-button-BoABoEm5.js} +153 -82
- package/dist/shared/hx-split-button-BoABoEm5.js.map +1 -0
- package/dist/shared/{hx-stat-WOcNV1Ry.js → hx-stat-Dtf9lz-O.js} +77 -47
- package/dist/shared/hx-stat-Dtf9lz-O.js.map +1 -0
- package/dist/shared/hx-switch-B6kr-EwE.js +540 -0
- package/dist/shared/hx-switch-B6kr-EwE.js.map +1 -0
- package/dist/shared/{hx-tab-panel-DspCrKqo.js → hx-tab-panel-BQtBXKLD.js} +255 -131
- package/dist/shared/hx-tab-panel-BQtBXKLD.js.map +1 -0
- package/dist/shared/{hx-tag-CNSmdyaK.js → hx-tag-C5aCUpVi.js} +63 -40
- package/dist/shared/hx-tag-C5aCUpVi.js.map +1 -0
- package/dist/shared/{hx-td-DnnEMIuA.js → hx-td-BGkFOJEK.js} +267 -123
- package/dist/shared/hx-td-BGkFOJEK.js.map +1 -0
- package/dist/shared/hx-theme-BsefFWTO.js.map +1 -1
- package/dist/shared/hx-time-picker-iwCD7rzW.js +1038 -0
- package/dist/shared/hx-time-picker-iwCD7rzW.js.map +1 -0
- package/dist/shared/{hx-toggle-button-iLiYrMbD.js → hx-toggle-button-BQ81EDkl.js} +226 -65
- package/dist/shared/hx-toggle-button-BQ81EDkl.js.map +1 -0
- package/dist/shared/{hx-tooltip-nYOv9OLu.js → hx-tooltip-DVqtKPCD.js} +68 -46
- package/dist/shared/hx-tooltip-DVqtKPCD.js.map +1 -0
- package/dist/shared/hx-tree-item-CHrUhuZL.js +925 -0
- package/dist/shared/hx-tree-item-CHrUhuZL.js.map +1 -0
- package/dist/shared/menu-roving-DmMnzJhn.js +14 -0
- package/dist/shared/menu-roving-DmMnzJhn.js.map +1 -0
- package/dist/shared/menu-tree-BNM0SYYq.js +42 -0
- package/dist/shared/menu-tree-BNM0SYYq.js.map +1 -0
- package/dist/shared/{toast-factory-YSznocIV.js → toast-factory-CL2BzdSB.js} +128 -77
- package/dist/shared/toast-factory-CL2BzdSB.js.map +1 -0
- package/dist/utils/aria-flatten.d.ts +56 -0
- package/dist/utils/aria-flatten.d.ts.map +1 -0
- package/dist/utils/aria-idref.d.ts +127 -0
- package/dist/utils/aria-idref.d.ts.map +1 -0
- package/dist/utils/menu-label.d.ts +18 -0
- package/dist/utils/menu-label.d.ts.map +1 -0
- package/dist/utils/menu-roving.d.ts +28 -0
- package/dist/utils/menu-roving.d.ts.map +1 -0
- package/dist/utils/menu-tree.d.ts +41 -0
- package/dist/utils/menu-tree.d.ts.map +1 -0
- package/dist/utils/tree-walk.d.ts +53 -0
- package/dist/utils/tree-walk.d.ts.map +1 -0
- package/figma-inventory.json +132 -20
- package/package.json +1 -1
- package/dist/shared/hx-alert-CLn7CstP.js.map +0 -1
- package/dist/shared/hx-badge-CQXgOXJM.js.map +0 -1
- package/dist/shared/hx-banner-D3DzpfcP.js.map +0 -1
- package/dist/shared/hx-checkbox-D7xma9YH.js +0 -524
- package/dist/shared/hx-checkbox-D7xma9YH.js.map +0 -1
- package/dist/shared/hx-checkbox-group-C9n315Ju.js +0 -323
- package/dist/shared/hx-checkbox-group-C9n315Ju.js.map +0 -1
- package/dist/shared/hx-color-picker-uRc865FJ.js +0 -882
- package/dist/shared/hx-color-picker-uRc865FJ.js.map +0 -1
- package/dist/shared/hx-combobox-DDzqNKEW.js +0 -924
- package/dist/shared/hx-combobox-DDzqNKEW.js.map +0 -1
- package/dist/shared/hx-date-picker-2iRG1p74.js.map +0 -1
- package/dist/shared/hx-dialog-DRN_1-Y-.js +0 -514
- package/dist/shared/hx-dialog-DRN_1-Y-.js.map +0 -1
- package/dist/shared/hx-drawer-Y1Ui2IWJ.js.map +0 -1
- package/dist/shared/hx-dropdown-LyaRc8Rf.js +0 -263
- package/dist/shared/hx-dropdown-LyaRc8Rf.js.map +0 -1
- package/dist/shared/hx-field-B3Qo8OLS.js.map +0 -1
- package/dist/shared/hx-icon-button-CGNdQSFM.js.map +0 -1
- package/dist/shared/hx-link-C-O6vq0Q.js.map +0 -1
- package/dist/shared/hx-list-MyEhh8c7.js.map +0 -1
- package/dist/shared/hx-menu-divider-C2omnPtj.js +0 -558
- package/dist/shared/hx-menu-divider-C2omnPtj.js.map +0 -1
- package/dist/shared/hx-meter-BPscsw5t.js.map +0 -1
- package/dist/shared/hx-overflow-menu-DCLsdIBy.js +0 -374
- package/dist/shared/hx-overflow-menu-DCLsdIBy.js.map +0 -1
- package/dist/shared/hx-popover-B-FP3-wW.js.map +0 -1
- package/dist/shared/hx-progress-bar-Bn3JEPUf.js +0 -258
- package/dist/shared/hx-progress-bar-Bn3JEPUf.js.map +0 -1
- package/dist/shared/hx-radio-CJvNU2yP.js +0 -621
- package/dist/shared/hx-radio-CJvNU2yP.js.map +0 -1
- package/dist/shared/hx-select-C8fEHQhC.js +0 -807
- package/dist/shared/hx-select-C8fEHQhC.js.map +0 -1
- package/dist/shared/hx-spinner-DL5AYr16.js.map +0 -1
- package/dist/shared/hx-split-button-Djnc5Aeg.js.map +0 -1
- package/dist/shared/hx-stat-WOcNV1Ry.js.map +0 -1
- package/dist/shared/hx-switch-BrZFaRue.js +0 -420
- package/dist/shared/hx-switch-BrZFaRue.js.map +0 -1
- package/dist/shared/hx-tab-panel-DspCrKqo.js.map +0 -1
- package/dist/shared/hx-tag-CNSmdyaK.js.map +0 -1
- package/dist/shared/hx-td-DnnEMIuA.js.map +0 -1
- package/dist/shared/hx-time-picker-BoEIZwzv.js +0 -688
- package/dist/shared/hx-time-picker-BoEIZwzv.js.map +0 -1
- package/dist/shared/hx-toggle-button-iLiYrMbD.js.map +0 -1
- package/dist/shared/hx-tooltip-nYOv9OLu.js.map +0 -1
- package/dist/shared/hx-tree-item-C2CiWuDE.js +0 -703
- package/dist/shared/hx-tree-item-C2CiWuDE.js.map +0 -1
- package/dist/shared/toast-factory-YSznocIV.js.map +0 -1
|
@@ -1,12 +1,14 @@
|
|
|
1
|
-
import { css as
|
|
2
|
-
import { property as
|
|
3
|
-
import { F as
|
|
4
|
-
import { classMap as
|
|
5
|
-
import { ifDefined as
|
|
6
|
-
import { b as
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
|
|
1
|
+
import { css as z, html as y, nothing as D } from "lit";
|
|
2
|
+
import { property as h, state as _, query as N, customElement as W } from "lit/decorators.js";
|
|
3
|
+
import { F as G } from "./FormMixin-B8PXk5RQ.js";
|
|
4
|
+
import { classMap as B } from "lit/directives/class-map.js";
|
|
5
|
+
import { ifDefined as U } from "lit/directives/if-defined.js";
|
|
6
|
+
import { b as V } from "./forced-colors-CTEDFRGa.js";
|
|
7
|
+
import { s as j, i as P, r as q } from "./aria-idref-CxvyzfQS.js";
|
|
8
|
+
import { f as k } from "./aria-flatten-DY6v2vah.js";
|
|
9
|
+
import { H as K } from "./helix-element-BNEYeiys.js";
|
|
10
|
+
import { c as X } from "./id-counter-DuX8vsui.js";
|
|
11
|
+
const J = z`
|
|
10
12
|
/* ============================================================
|
|
11
13
|
Host
|
|
12
14
|
============================================================ */
|
|
@@ -343,7 +345,8 @@ const I = D`
|
|
|
343
345
|
Live region (screen reader announcements)
|
|
344
346
|
============================================================ */
|
|
345
347
|
|
|
346
|
-
.calendar__live-region
|
|
348
|
+
.calendar__live-region,
|
|
349
|
+
.field__sr-only {
|
|
347
350
|
position: absolute;
|
|
348
351
|
width: 1px;
|
|
349
352
|
height: 1px;
|
|
@@ -429,15 +432,15 @@ const I = D`
|
|
|
429
432
|
}
|
|
430
433
|
}
|
|
431
434
|
`;
|
|
432
|
-
var
|
|
433
|
-
for (var i = a > 1 ? void 0 : a ?
|
|
434
|
-
(
|
|
435
|
-
return a && i &&
|
|
435
|
+
var Q = Object.defineProperty, Z = Object.getOwnPropertyDescriptor, n = (t, e, r, a) => {
|
|
436
|
+
for (var i = a > 1 ? void 0 : a ? Z(e, r) : e, s = t.length - 1, o; s >= 0; s--)
|
|
437
|
+
(o = t[s]) && (i = (a ? o(e, r, i) : o(i)) || i);
|
|
438
|
+
return a && i && Q(e, r, i), i;
|
|
436
439
|
};
|
|
437
|
-
const
|
|
438
|
-
let
|
|
440
|
+
const ee = X("hx-date-picker");
|
|
441
|
+
let l = class extends G(K) {
|
|
439
442
|
constructor() {
|
|
440
|
-
super(...arguments), this.name = "", this.value = "", this.min = "", this.max = "", this.label = "", this.required = !1, this.disabled = !1, this.error = "", this.helpText = "", this.format = "MM/DD/YYYY", this.locale = "en-US", this.requiredMessage = "This field is required.", this.chooseDateLabel = "Choose a date", this.openCalendarLabel = "Open calendar", this.closeCalendarLabel = "Close calendar", this.previousMonthLabel = "Previous month", this.nextMonthLabel = "Next month", this._isOpen = !1, this._viewYear = (/* @__PURE__ */ new Date()).getFullYear(), this._viewMonth = (/* @__PURE__ */ new Date()).getMonth(), this._focusedDay = null, this._liveMessage = "", this._dayGrid = [], this._dayAriaLabels = /* @__PURE__ */ new Map(), this._weekdayFormatter = null, this._monthFormatter = null, this._formatterLocale = "", this._cachedWeekdayNames = null, this._id =
|
|
443
|
+
super(...arguments), this.name = "", this.value = "", this.min = "", this.max = "", this.label = "", this.required = !1, this.disabled = !1, this.error = "", this.helpText = "", this.format = "MM/DD/YYYY", this.locale = "en-US", this.requiredMessage = "This field is required.", this.chooseDateLabel = "Choose a date", this.openCalendarLabel = "Open calendar", this.closeCalendarLabel = "Close calendar", this.previousMonthLabel = "Previous month", this.nextMonthLabel = "Next month", this.accessibleLabel = null, this._isOpen = !1, this._viewYear = (/* @__PURE__ */ new Date()).getFullYear(), this._viewMonth = (/* @__PURE__ */ new Date()).getMonth(), this._focusedDay = null, this._liveMessage = "", this._dayGrid = [], this._dayAriaLabels = /* @__PURE__ */ new Map(), this._weekdayFormatter = null, this._monthFormatter = null, this._formatterLocale = "", this._cachedWeekdayNames = null, this._id = ee(), this._inputId = `${this._id}-input`, this._helpTextId = `${this._id}-help`, this._errorId = `${this._id}-error`, this._calendarId = `${this._id}-calendar`, this._liveRegionId = `${this._id}-live`, this._labelId = `${this._id}-label`, this._consumerDescId = `${this._id}-consumer-desc`, this._hasLabelSlot = !1, this._hasErrorSlot = !1, this._hasHelpSlot = !1, this._labelSource = "none", this._labelSlotText = "", this._supportsIdrefRefs = !0, this._invalid = !1, this._announcedError = "", this._ariaMirror = null, this._helpSlotTextObserver = null, this._errorSlotTextObserver = null, this._hostDescribedByObserver = null, this._consumerLabelledBy = null, this._consumerDescribedBy = null, this._slottedLabelEls = [], this._labelSlotTextObserver = null, this._externalRefsObserver = null, this._handleDocumentClick = (t) => {
|
|
441
444
|
if (!this._isOpen) return;
|
|
442
445
|
t.composedPath().includes(this) || this._closeCalendar();
|
|
443
446
|
}, this._handleGridClick = (t) => {
|
|
@@ -449,25 +452,32 @@ let s = class extends M(S) {
|
|
|
449
452
|
a && this._selectDay(a);
|
|
450
453
|
};
|
|
451
454
|
}
|
|
452
|
-
/** @internal */
|
|
453
|
-
_handleLabelSlotChange(t) {
|
|
454
|
-
const e = t.target;
|
|
455
|
-
if (this._hasLabelSlot = e.assignedElements().length > 0, this._hasLabelSlot) {
|
|
456
|
-
const r = e.assignedElements()[0];
|
|
457
|
-
r && !r.id && (r.id = `${this._inputId}-slotted-label`);
|
|
458
|
-
}
|
|
459
|
-
}
|
|
460
|
-
/** @internal */
|
|
461
|
-
_handleErrorSlotChange(t) {
|
|
462
|
-
const e = t.target;
|
|
463
|
-
this._hasErrorSlot = e.assignedElements().length > 0;
|
|
464
|
-
}
|
|
465
455
|
// ─── Lifecycle ───
|
|
456
|
+
connectedCallback() {
|
|
457
|
+
super.connectedCallback();
|
|
458
|
+
const t = this.constructor;
|
|
459
|
+
this._supportsIdrefRefs = t.__testSupportsIdrefRefsOverride !== null ? t.__testSupportsIdrefRefsOverride : j(this._internals), this._hostDescribedByObserver = new MutationObserver((e) => {
|
|
460
|
+
let r = !1;
|
|
461
|
+
for (const a of e) {
|
|
462
|
+
if (a.attributeName !== "aria-describedby") continue;
|
|
463
|
+
const i = a.oldValue, s = this.getAttribute("aria-describedby");
|
|
464
|
+
i !== null && s === null && (this._consumerDescribedBy = null, r = !0);
|
|
465
|
+
}
|
|
466
|
+
r && this._syncHostAriaSemantics();
|
|
467
|
+
}), this._hostDescribedByObserver.observe(this, {
|
|
468
|
+
attributes: !0,
|
|
469
|
+
attributeFilter: ["aria-describedby"],
|
|
470
|
+
attributeOldValue: !0
|
|
471
|
+
}), this._syncHostAriaSemantics(), this._ariaMirror = P(this, () => {
|
|
472
|
+
this._syncHostAriaSemantics();
|
|
473
|
+
});
|
|
474
|
+
}
|
|
466
475
|
disconnectedCallback() {
|
|
467
|
-
|
|
476
|
+
var t, e, r, a, i, s;
|
|
477
|
+
super.disconnectedCallback(), document.removeEventListener("click", this._handleDocumentClick, !0), (t = this._ariaMirror) == null || t.disconnect(), this._ariaMirror = null, (e = this._helpSlotTextObserver) == null || e.disconnect(), this._helpSlotTextObserver = null, (r = this._errorSlotTextObserver) == null || r.disconnect(), this._errorSlotTextObserver = null, (a = this._labelSlotTextObserver) == null || a.disconnect(), this._labelSlotTextObserver = null, (i = this._hostDescribedByObserver) == null || i.disconnect(), this._hostDescribedByObserver = null, (s = this._externalRefsObserver) == null || s.disconnect(), this._externalRefsObserver = null;
|
|
468
478
|
}
|
|
469
479
|
willUpdate(t) {
|
|
470
|
-
super.willUpdate(t), t.has("value") && this._internals.setFormValue(this.value), (t.has("_viewMonth") || t.has("_viewYear") || t.has("locale") || this._dayGrid.length === 0) && (this._dayGrid = this._getDaysInGrid(), this._dayAriaLabels = new Map(
|
|
480
|
+
super.willUpdate(t), t.has("value") && this._internals.setFormValue(this.value), (t.has("error") || !this.hasUpdated) && (this._announcedError = this.error ?? ""), t.has("label") && this._refreshLabelSource(), (t.has("_viewMonth") || t.has("_viewYear") || t.has("locale") || this._dayGrid.length === 0) && (this._dayGrid = this._getDaysInGrid(), this._dayAriaLabels = new Map(
|
|
471
481
|
this._dayGrid.filter((r) => r !== null).map((r) => [
|
|
472
482
|
this._toISO(r),
|
|
473
483
|
r.toLocaleDateString(this.locale, {
|
|
@@ -480,34 +490,326 @@ let s = class extends M(S) {
|
|
|
480
490
|
));
|
|
481
491
|
}
|
|
482
492
|
updated(t) {
|
|
483
|
-
var e
|
|
484
|
-
if (super.updated(t), t.has("error") && this.error) {
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
const i = this.error;
|
|
488
|
-
requestAnimationFrame(() => {
|
|
489
|
-
a.textContent = "", requestAnimationFrame(() => {
|
|
490
|
-
a.textContent = i;
|
|
491
|
-
});
|
|
492
|
-
});
|
|
493
|
-
}
|
|
494
|
-
}
|
|
495
|
-
if (t.has("_isOpen"))
|
|
493
|
+
var e;
|
|
494
|
+
if (super.updated(t), this._syncHostAriaSemantics(), t.has("error") && (t.get("error") && this.error ? (this._announcedError = "", requestAnimationFrame(() => {
|
|
495
|
+
this._announcedError = this.error;
|
|
496
|
+
})) : this._announcedError = this.error), t.has("_isOpen"))
|
|
496
497
|
if (this._isOpen) {
|
|
497
|
-
const
|
|
498
|
-
|
|
499
|
-
var
|
|
500
|
-
(
|
|
498
|
+
const r = this._parseISODate(this.value);
|
|
499
|
+
r && (this._viewYear = r.getFullYear(), this._viewMonth = r.getMonth()), this.updateComplete.then(() => {
|
|
500
|
+
var a;
|
|
501
|
+
(a = this._calendar) == null || a.show(), this._focusActiveDay(), document.addEventListener("click", this._handleDocumentClick, !0);
|
|
501
502
|
});
|
|
502
503
|
} else
|
|
503
|
-
(
|
|
504
|
+
(e = this._calendar) == null || e.close(), this._focusedDay = null, document.removeEventListener("click", this._handleDocumentClick, !0);
|
|
504
505
|
if ((t.has("_viewMonth") || t.has("_viewYear")) && this._isOpen) {
|
|
505
|
-
const
|
|
506
|
-
this._liveMessage = `${
|
|
506
|
+
const r = this._getMonthName(this._viewMonth);
|
|
507
|
+
this._liveMessage = `${r} ${this._viewYear}`, this.updateComplete.then(() => {
|
|
507
508
|
this._focusActiveDay();
|
|
508
509
|
});
|
|
509
510
|
}
|
|
510
511
|
}
|
|
512
|
+
firstUpdated(t) {
|
|
513
|
+
super.firstUpdated(t), this._seedSlotStateSync(), this._syncHostAriaSemantics(), !this.label && !this.accessibleLabel && !this._hasLabelSlot && !this.getAttribute("aria-label") && this.getAttribute("aria-labelledby");
|
|
514
|
+
}
|
|
515
|
+
/**
|
|
516
|
+
* Synchronous slot-state seed. Mirrors the side effects of the three
|
|
517
|
+
* `_handle*SlotChange` handlers (label / help-text / error) but is driven by
|
|
518
|
+
* direct `slot.assignedNodes()` reads so we can populate state BEFORE the
|
|
519
|
+
* microtask `slotchange` events fire after the first render.
|
|
520
|
+
* @internal
|
|
521
|
+
*/
|
|
522
|
+
_seedSlotStateSync() {
|
|
523
|
+
const t = this.shadowRoot;
|
|
524
|
+
if (!t) return;
|
|
525
|
+
const e = t.querySelector('slot[name="label"]');
|
|
526
|
+
if (e) {
|
|
527
|
+
const i = this._readLabelSlotState(e);
|
|
528
|
+
this._hasLabelSlot = i.hasUsefulName, this._slottedLabelEls = i.elements, this._labelSlotText = i.text, this._installLabelSlotTextObserver(i.elements), this._refreshLabelSource();
|
|
529
|
+
}
|
|
530
|
+
const r = t.querySelector('slot[name="help-text"]');
|
|
531
|
+
r && (this._hasHelpSlot = this._readHelpSlotStateSync(r), this._installHelpSlotTextObserver(r));
|
|
532
|
+
const a = t.querySelector('slot[name="error"]');
|
|
533
|
+
a && (this._hasErrorSlot = this._readErrorSlotStateSync(a), this._installErrorSlotTextObserver(a));
|
|
534
|
+
}
|
|
535
|
+
/**
|
|
536
|
+
* Reads the label slot's assigned nodes and computes the discriminated
|
|
537
|
+
* naming state. An empty whitespace-only slot does NOT count as a useful
|
|
538
|
+
* name. Per AccName 1.2 §4.3.10, `aria-hidden="true"` and `[hidden]`
|
|
539
|
+
* elements contribute zero to the accessible name.
|
|
540
|
+
* @internal
|
|
541
|
+
*/
|
|
542
|
+
_readLabelSlotState(t) {
|
|
543
|
+
const e = t.assignedNodes(), r = [], a = [];
|
|
544
|
+
for (const s of e)
|
|
545
|
+
if (s.nodeType === Node.ELEMENT_NODE) {
|
|
546
|
+
const o = s;
|
|
547
|
+
if (r.push(o), o.getAttribute("aria-hidden") === "true") continue;
|
|
548
|
+
const d = k(o);
|
|
549
|
+
d && a.push(d);
|
|
550
|
+
} else if (s.nodeType === Node.TEXT_NODE) {
|
|
551
|
+
const o = (s.textContent ?? "").trim();
|
|
552
|
+
o && a.push(o);
|
|
553
|
+
}
|
|
554
|
+
const i = a.join(" ").replace(/\s+/g, " ").trim();
|
|
555
|
+
return {
|
|
556
|
+
hasUsefulName: i.length > 0,
|
|
557
|
+
elements: r,
|
|
558
|
+
text: i
|
|
559
|
+
};
|
|
560
|
+
}
|
|
561
|
+
/**
|
|
562
|
+
* Re-evaluate the help-text slot's "has meaningful content" state from its
|
|
563
|
+
* current effective text. AccName-aware so descendants carrying
|
|
564
|
+
* `aria-hidden="true"` or `hidden` do NOT count.
|
|
565
|
+
* @internal
|
|
566
|
+
*/
|
|
567
|
+
_readHelpSlotStateSync(t) {
|
|
568
|
+
const e = t.assignedNodes({ flatten: !0 });
|
|
569
|
+
for (const r of e)
|
|
570
|
+
if (r.nodeType === Node.TEXT_NODE) {
|
|
571
|
+
if ((r.textContent ?? "").trim().length > 0) return !0;
|
|
572
|
+
} else if (r.nodeType === Node.ELEMENT_NODE && k(r).length > 0)
|
|
573
|
+
return !0;
|
|
574
|
+
return !1;
|
|
575
|
+
}
|
|
576
|
+
/**
|
|
577
|
+
* Re-evaluate the error slot's "has meaningful content" state from its
|
|
578
|
+
* current effective text.
|
|
579
|
+
* @internal
|
|
580
|
+
*/
|
|
581
|
+
_readErrorSlotStateSync(t) {
|
|
582
|
+
const e = t.assignedNodes({ flatten: !0 });
|
|
583
|
+
for (const r of e)
|
|
584
|
+
if (r.nodeType === Node.TEXT_NODE) {
|
|
585
|
+
if ((r.textContent ?? "").trim().length > 0) return !0;
|
|
586
|
+
} else if (r.nodeType === Node.ELEMENT_NODE && k(r).length > 0)
|
|
587
|
+
return !0;
|
|
588
|
+
return !1;
|
|
589
|
+
}
|
|
590
|
+
/**
|
|
591
|
+
* Recomputes the discriminated label source. Slot takes precedence over
|
|
592
|
+
* the `label` property because the render path suppresses the internal
|
|
593
|
+
* `<label>` when slotted content is present.
|
|
594
|
+
* @internal
|
|
595
|
+
*/
|
|
596
|
+
_refreshLabelSource() {
|
|
597
|
+
this._hasLabelSlot ? this._labelSource = "slot" : this.label ? this._labelSource = "string" : this._labelSource = "none";
|
|
598
|
+
}
|
|
599
|
+
/**
|
|
600
|
+
* (Re-)installs a `MutationObserver` against the deduped union of
|
|
601
|
+
* consumer-resolved label/description elements.
|
|
602
|
+
* @internal
|
|
603
|
+
*/
|
|
604
|
+
_installExternalRefsObserver(t) {
|
|
605
|
+
if (this._externalRefsObserver && (this._externalRefsObserver.disconnect(), this._externalRefsObserver = null), t.length === 0) return;
|
|
606
|
+
const e = new Set(t), r = new MutationObserver(() => {
|
|
607
|
+
this._syncHostAriaSemantics();
|
|
608
|
+
});
|
|
609
|
+
for (const a of e)
|
|
610
|
+
r.observe(a, {
|
|
611
|
+
characterData: !0,
|
|
612
|
+
subtree: !0,
|
|
613
|
+
childList: !0,
|
|
614
|
+
attributes: !0,
|
|
615
|
+
attributeFilter: ["aria-hidden", "hidden"]
|
|
616
|
+
});
|
|
617
|
+
this._externalRefsObserver = r;
|
|
618
|
+
}
|
|
619
|
+
/**
|
|
620
|
+
* Resolves consumer-supplied label/description IDREFs on the host and
|
|
621
|
+
* writes the canonical ARIA onto the **inner readonly `<input>`** for the
|
|
622
|
+
* W3C APG date-picker dialog pattern.
|
|
623
|
+
*
|
|
624
|
+
* The inner input is INTENTIONALLY NOT a `role="combobox"` — it is a
|
|
625
|
+
* readonly text input with `aria-haspopup="dialog"` per W3C APG date picker
|
|
626
|
+
* dialog. A separate trigger button owns `aria-expanded` /
|
|
627
|
+
* `aria-controls=${calendarId}` for the dialog. (Cross-shadow `aria-controls`
|
|
628
|
+
* referencing an in-shadow id is a documented limitation, mirrored from
|
|
629
|
+
* hx-popover and hx-dropdown.)
|
|
630
|
+
*
|
|
631
|
+
* Cross-shadow naming uses a belt-and-suspenders strategy:
|
|
632
|
+
*
|
|
633
|
+
* 1. **Modern path** (`_supportsIdrefRefs === true`): consumer-resolved
|
|
634
|
+
* label/description elements are written onto
|
|
635
|
+
* `internals.ariaLabelledByElements` / `ariaDescribedByElements` on
|
|
636
|
+
* the host. Host-level `aria-labelledby` / `aria-describedby`
|
|
637
|
+
* attributes are LEFT IN PLACE so AT walking up the DOM also sees them.
|
|
638
|
+
* Resolved-element text is also flattened onto the inner input as
|
|
639
|
+
* `aria-label` so AT that does NOT walk up still announces the right
|
|
640
|
+
* name.
|
|
641
|
+
*
|
|
642
|
+
* 2. **Legacy fallback** (`_supportsIdrefRefs === false`): the resolved-
|
|
643
|
+
* element text is flattened onto the inner input as `aria-label` and
|
|
644
|
+
* mirrored into a synthesized in-shadow span pointed at by the inner
|
|
645
|
+
* input's `aria-describedby`.
|
|
646
|
+
*
|
|
647
|
+
* Writing `aria-labelledby="<light-DOM id>"` directly on the shadow-DOM
|
|
648
|
+
* inner input is INTENTIONALLY avoided: light-DOM ids do not resolve from
|
|
649
|
+
* inside a shadow root.
|
|
650
|
+
* @internal
|
|
651
|
+
*/
|
|
652
|
+
_syncHostAriaSemantics() {
|
|
653
|
+
var H, F, Y, R;
|
|
654
|
+
const t = this._internals, e = this._input;
|
|
655
|
+
if (!e) {
|
|
656
|
+
const u = !t.validity.valid || !!(this.error || this._hasErrorSlot);
|
|
657
|
+
this._invalid !== u && (this._invalid = u);
|
|
658
|
+
return;
|
|
659
|
+
}
|
|
660
|
+
const r = this.getAttribute("aria-label"), a = r !== null && r.trim() || "", i = ((H = this.shadowRoot) == null ? void 0 : H.getElementById(this._labelId)) ?? null, s = this._slottedLabelEls, o = ((F = this.shadowRoot) == null ? void 0 : F.getElementById(this._helpTextId)) ?? null, d = ((Y = this.shadowRoot) == null ? void 0 : Y.getElementById(this._errorId)) ?? null, c = this.getAttribute("aria-labelledby");
|
|
661
|
+
this._consumerLabelledBy = c;
|
|
662
|
+
const p = this.getAttribute("aria-describedby");
|
|
663
|
+
this._consumerDescribedBy = p;
|
|
664
|
+
const f = q(this, this._consumerLabelledBy), w = f.length > 0, m = q(this, this._consumerDescribedBy);
|
|
665
|
+
this._installExternalRefsObserver([...f, ...m]);
|
|
666
|
+
const v = !!(this.error || this._hasErrorSlot), L = !t.validity.valid || v;
|
|
667
|
+
this._invalid !== L && (this._invalid = L);
|
|
668
|
+
const x = typeof this.accessibleLabel == "string" && this.accessibleLabel.trim().length > 0 ? this.accessibleLabel : null, O = (u) => u.getAttribute("aria-hidden") !== "true" && !u.hasAttribute("hidden"), S = [];
|
|
669
|
+
x || (S.push(...f.filter(O)), !w && !a && (this._labelSource === "slot" && s.length > 0 ? S.push(...s.filter(O)) : this._labelSource === "string" && i && S.push(i)));
|
|
670
|
+
const M = [...m.filter(O)];
|
|
671
|
+
if (o && !v && this._hasHelpSlot && M.push(o), d && v && M.push(d), this._supportsIdrefRefs) {
|
|
672
|
+
const u = t;
|
|
673
|
+
u.ariaLabelledByElements = S.length > 0 ? S : null, u.ariaDescribedByElements = M.length > 0 ? M : null, x ? t.ariaLabel = x : t.ariaLabel = null;
|
|
674
|
+
}
|
|
675
|
+
const I = (u) => u.filter(O).map((A) => k(A)).filter((A) => A.length > 0).join(" ");
|
|
676
|
+
let b = null, T = null, $ = "";
|
|
677
|
+
if (!x && w && ($ = I(f)), x)
|
|
678
|
+
b = x;
|
|
679
|
+
else if ($)
|
|
680
|
+
b = $;
|
|
681
|
+
else if (a)
|
|
682
|
+
b = a;
|
|
683
|
+
else if (this._labelSource === "slot") {
|
|
684
|
+
if (this._labelSlotText)
|
|
685
|
+
b = this._labelSlotText;
|
|
686
|
+
else if (s.length > 0) {
|
|
687
|
+
const u = I(s);
|
|
688
|
+
u && (b = u);
|
|
689
|
+
}
|
|
690
|
+
} else this._labelSource === "string" && (i != null && i.id ? T = i.id : this.label && (b = this.label));
|
|
691
|
+
T ? (e.getAttribute("aria-labelledby") !== T && e.setAttribute("aria-labelledby", T), e.hasAttribute("aria-label") && e.removeAttribute("aria-label")) : b ? (e.getAttribute("aria-label") !== b && e.setAttribute("aria-label", b), e.hasAttribute("aria-labelledby") && e.removeAttribute("aria-labelledby")) : (e.hasAttribute("aria-label") && e.removeAttribute("aria-label"), e.hasAttribute("aria-labelledby") && e.removeAttribute("aria-labelledby"));
|
|
692
|
+
const E = ((R = this.shadowRoot) == null ? void 0 : R.getElementById(this._consumerDescId)) ?? null, C = I(m);
|
|
693
|
+
E && E.textContent !== C && (E.textContent = C);
|
|
694
|
+
const g = [];
|
|
695
|
+
if (C && E && g.push(this._consumerDescId), o && !v && this._hasHelpSlot && g.push(this._helpTextId), d && v && g.push(this._errorId), !this._hasHelpSlot && this.helpText && !v && o && !g.includes(this._helpTextId) && g.push(this._helpTextId), g.length > 0) {
|
|
696
|
+
const u = g.join(" ");
|
|
697
|
+
e.getAttribute("aria-describedby") !== u && e.setAttribute("aria-describedby", u);
|
|
698
|
+
} else e.hasAttribute("aria-describedby") && e.removeAttribute("aria-describedby");
|
|
699
|
+
e.hasAttribute("aria-description") && e.removeAttribute("aria-description");
|
|
700
|
+
}
|
|
701
|
+
/**
|
|
702
|
+
* (Re-)installs the help-text slot text/visibility observer.
|
|
703
|
+
* @internal
|
|
704
|
+
*/
|
|
705
|
+
_installHelpSlotTextObserver(t) {
|
|
706
|
+
var r;
|
|
707
|
+
if ((r = this._helpSlotTextObserver) == null || r.disconnect(), !t) {
|
|
708
|
+
this._helpSlotTextObserver = null;
|
|
709
|
+
return;
|
|
710
|
+
}
|
|
711
|
+
const e = new MutationObserver(() => {
|
|
712
|
+
this._hasHelpSlot = this._readHelpSlotStateSync(t), this._syncHostAriaSemantics();
|
|
713
|
+
});
|
|
714
|
+
t.assignedNodes().forEach((a) => {
|
|
715
|
+
if (a.nodeType !== Node.ELEMENT_NODE) {
|
|
716
|
+
e.observe(a, {
|
|
717
|
+
characterData: !0,
|
|
718
|
+
childList: !0,
|
|
719
|
+
subtree: !0
|
|
720
|
+
});
|
|
721
|
+
return;
|
|
722
|
+
}
|
|
723
|
+
e.observe(a, {
|
|
724
|
+
characterData: !0,
|
|
725
|
+
childList: !0,
|
|
726
|
+
subtree: !0,
|
|
727
|
+
attributes: !0,
|
|
728
|
+
attributeFilter: ["aria-hidden", "hidden"]
|
|
729
|
+
});
|
|
730
|
+
}), this._helpSlotTextObserver = e;
|
|
731
|
+
}
|
|
732
|
+
/**
|
|
733
|
+
* (Re-)installs the error slot text/visibility observer.
|
|
734
|
+
* @internal
|
|
735
|
+
*/
|
|
736
|
+
_installErrorSlotTextObserver(t) {
|
|
737
|
+
var r;
|
|
738
|
+
if ((r = this._errorSlotTextObserver) == null || r.disconnect(), !t) {
|
|
739
|
+
this._errorSlotTextObserver = null;
|
|
740
|
+
return;
|
|
741
|
+
}
|
|
742
|
+
const e = new MutationObserver(() => {
|
|
743
|
+
this._hasErrorSlot = this._readErrorSlotStateSync(t), this._syncHostAriaSemantics();
|
|
744
|
+
});
|
|
745
|
+
t.assignedNodes().forEach((a) => {
|
|
746
|
+
if (a.nodeType !== Node.ELEMENT_NODE) {
|
|
747
|
+
e.observe(a, {
|
|
748
|
+
characterData: !0,
|
|
749
|
+
childList: !0,
|
|
750
|
+
subtree: !0
|
|
751
|
+
});
|
|
752
|
+
return;
|
|
753
|
+
}
|
|
754
|
+
e.observe(a, {
|
|
755
|
+
characterData: !0,
|
|
756
|
+
childList: !0,
|
|
757
|
+
subtree: !0,
|
|
758
|
+
attributes: !0,
|
|
759
|
+
attributeFilter: ["aria-hidden", "hidden"]
|
|
760
|
+
});
|
|
761
|
+
}), this._errorSlotTextObserver = e;
|
|
762
|
+
}
|
|
763
|
+
/**
|
|
764
|
+
* (Re-)installs the label slot text/visibility observer over the current
|
|
765
|
+
* set of slotted label elements.
|
|
766
|
+
* @internal
|
|
767
|
+
*/
|
|
768
|
+
_installLabelSlotTextObserver(t) {
|
|
769
|
+
var r;
|
|
770
|
+
if ((r = this._labelSlotTextObserver) == null || r.disconnect(), t.length === 0) {
|
|
771
|
+
this._labelSlotTextObserver = null;
|
|
772
|
+
return;
|
|
773
|
+
}
|
|
774
|
+
const e = new MutationObserver(() => {
|
|
775
|
+
const a = [];
|
|
776
|
+
for (const s of t) {
|
|
777
|
+
if (s.getAttribute("aria-hidden") === "true") continue;
|
|
778
|
+
const o = k(s);
|
|
779
|
+
o && a.push(o);
|
|
780
|
+
}
|
|
781
|
+
const i = a.join(" ").replace(/\s+/g, " ").trim();
|
|
782
|
+
this._labelSlotText = i, this._hasLabelSlot = i.length > 0, this._refreshLabelSource(), this._syncHostAriaSemantics();
|
|
783
|
+
});
|
|
784
|
+
for (const a of t)
|
|
785
|
+
e.observe(a, {
|
|
786
|
+
characterData: !0,
|
|
787
|
+
childList: !0,
|
|
788
|
+
subtree: !0,
|
|
789
|
+
attributes: !0,
|
|
790
|
+
attributeFilter: ["aria-hidden", "hidden"]
|
|
791
|
+
});
|
|
792
|
+
this._labelSlotTextObserver = e;
|
|
793
|
+
}
|
|
794
|
+
// ─── Slot Change Handlers ───
|
|
795
|
+
/** @internal */
|
|
796
|
+
_handleLabelSlotChange(t) {
|
|
797
|
+
if (!(t.target instanceof HTMLSlotElement)) return;
|
|
798
|
+
const e = this._readLabelSlotState(t.target);
|
|
799
|
+
if (this._hasLabelSlot = e.hasUsefulName, this._slottedLabelEls = e.elements, this._labelSlotText = e.text, e.elements.length > 0) {
|
|
800
|
+
const r = e.elements[0];
|
|
801
|
+
r && !r.id && (r.id = `${this._inputId}-slotted-label`);
|
|
802
|
+
}
|
|
803
|
+
this._installLabelSlotTextObserver(e.elements), this._refreshLabelSource(), this._syncHostAriaSemantics();
|
|
804
|
+
}
|
|
805
|
+
/** @internal */
|
|
806
|
+
_handleErrorSlotChange(t) {
|
|
807
|
+
t.target instanceof HTMLSlotElement && (this._hasErrorSlot = this._readErrorSlotStateSync(t.target), this._installErrorSlotTextObserver(t.target), this._syncHostAriaSemantics());
|
|
808
|
+
}
|
|
809
|
+
/** @internal */
|
|
810
|
+
_handleHelpSlotChange(t) {
|
|
811
|
+
t.target instanceof HTMLSlotElement && (this._hasHelpSlot = this._readHelpSlotStateSync(t.target), this._installHelpSlotTextObserver(t.target), this._syncHostAriaSemantics());
|
|
812
|
+
}
|
|
511
813
|
// ─── Form Integration ───
|
|
512
814
|
/** @internal */
|
|
513
815
|
_updateValidity() {
|
|
@@ -515,7 +817,7 @@ let s = class extends M(S) {
|
|
|
515
817
|
{ valueMissing: !0 },
|
|
516
818
|
this.error || this.requiredMessage,
|
|
517
819
|
this._input
|
|
518
|
-
) : this._internals.setValidity({});
|
|
820
|
+
) : this._internals.setValidity({}), this._syncHostAriaSemantics();
|
|
519
821
|
}
|
|
520
822
|
/** @internal */
|
|
521
823
|
_onFormReset() {
|
|
@@ -568,11 +870,7 @@ let s = class extends M(S) {
|
|
|
568
870
|
_isToday(t) {
|
|
569
871
|
return this._isSameDay(t, /* @__PURE__ */ new Date());
|
|
570
872
|
}
|
|
571
|
-
/**
|
|
572
|
-
* Ensure memoized Intl.DateTimeFormat instances exist and match the current locale.
|
|
573
|
-
* Rebuilds only when locale changes; also clears the cached weekday names.
|
|
574
|
-
* @internal
|
|
575
|
-
*/
|
|
873
|
+
/** @internal */
|
|
576
874
|
_ensureFormatters() {
|
|
577
875
|
this._formatterLocale === this.locale && this._weekdayFormatter && this._monthFormatter || (this._weekdayFormatter = new Intl.DateTimeFormat(this.locale, { weekday: "short" }), this._monthFormatter = new Intl.DateTimeFormat(this.locale, { month: "long" }), this._formatterLocale = this.locale, this._cachedWeekdayNames = null);
|
|
578
876
|
}
|
|
@@ -584,29 +882,21 @@ let s = class extends M(S) {
|
|
|
584
882
|
_getDayName(t) {
|
|
585
883
|
return this._ensureFormatters(), (this._weekdayFormatter ?? new Intl.DateTimeFormat(this.locale, { weekday: "short" })).format(new Date(2e3, 0, 2 + t));
|
|
586
884
|
}
|
|
587
|
-
/**
|
|
588
|
-
* Returns the 7 cached weekday header strings for the current locale.
|
|
589
|
-
* Computed once per locale and reused across all renders.
|
|
590
|
-
* @internal
|
|
591
|
-
*/
|
|
885
|
+
/** @internal */
|
|
592
886
|
_getWeekdayNames() {
|
|
593
887
|
return this._ensureFormatters(), this._cachedWeekdayNames || (this._cachedWeekdayNames = Array.from({ length: 7 }, (t, e) => this._getDayName(e))), this._cachedWeekdayNames;
|
|
594
888
|
}
|
|
595
889
|
// ─── Calendar Grid ───
|
|
596
|
-
/**
|
|
597
|
-
* Returns an array of Date objects (or null for padding cells) representing
|
|
598
|
-
* the 6-week grid for the current view month.
|
|
599
|
-
*/
|
|
600
890
|
/** @internal */
|
|
601
891
|
_getDaysInGrid() {
|
|
602
892
|
const e = new Date(this._viewYear, this._viewMonth, 1).getDay(), r = new Date(this._viewYear, this._viewMonth + 1, 0).getDate(), a = [];
|
|
603
|
-
for (let
|
|
893
|
+
for (let s = 0; s < e; s++)
|
|
604
894
|
a.push(null);
|
|
605
|
-
for (let
|
|
606
|
-
a.push(new Date(this._viewYear, this._viewMonth,
|
|
895
|
+
for (let s = 1; s <= r; s++)
|
|
896
|
+
a.push(new Date(this._viewYear, this._viewMonth, s));
|
|
607
897
|
const i = a.length % 7;
|
|
608
898
|
if (i !== 0)
|
|
609
|
-
for (let
|
|
899
|
+
for (let s = 0; s < 7 - i; s++)
|
|
610
900
|
a.push(null);
|
|
611
901
|
return a;
|
|
612
902
|
}
|
|
@@ -644,8 +934,8 @@ let s = class extends M(S) {
|
|
|
644
934
|
if (r === null) {
|
|
645
935
|
const a = new Date(this._viewYear, this._viewMonth + 1, 0).getDate();
|
|
646
936
|
for (let i = 1; i <= a; i++) {
|
|
647
|
-
const
|
|
648
|
-
if (!this._isDateDisabled(
|
|
937
|
+
const s = new Date(this._viewYear, this._viewMonth, i);
|
|
938
|
+
if (!this._isDateDisabled(s)) {
|
|
649
939
|
r = i;
|
|
650
940
|
break;
|
|
651
941
|
}
|
|
@@ -696,8 +986,8 @@ let s = class extends M(S) {
|
|
|
696
986
|
t.preventDefault();
|
|
697
987
|
const r = this._focusedDay ?? 1, a = new Date(this._viewYear, this._viewMonth + 1, 0).getDate();
|
|
698
988
|
if (e === "Enter" || e === " ") {
|
|
699
|
-
const
|
|
700
|
-
this._isDateDisabled(
|
|
989
|
+
const s = new Date(this._viewYear, this._viewMonth, r);
|
|
990
|
+
this._isDateDisabled(s) || this._selectDay(s);
|
|
701
991
|
return;
|
|
702
992
|
}
|
|
703
993
|
if (e === "PageUp") {
|
|
@@ -709,44 +999,44 @@ let s = class extends M(S) {
|
|
|
709
999
|
return;
|
|
710
1000
|
}
|
|
711
1001
|
if (e === "Home") {
|
|
712
|
-
const
|
|
713
|
-
|
|
714
|
-
var
|
|
715
|
-
(p = (
|
|
1002
|
+
const o = new Date(this._viewYear, this._viewMonth, r).getDay(), d = r - o;
|
|
1003
|
+
d >= 1 && (this._focusedDay = d, this.updateComplete.then(() => {
|
|
1004
|
+
var c, p;
|
|
1005
|
+
(p = (c = this._calendar) == null ? void 0 : c.querySelector(`[data-day="${d}"]`)) == null || p.focus();
|
|
716
1006
|
}));
|
|
717
1007
|
return;
|
|
718
1008
|
}
|
|
719
1009
|
if (e === "End") {
|
|
720
|
-
const
|
|
721
|
-
|
|
722
|
-
var p,
|
|
723
|
-
(
|
|
1010
|
+
const d = 6 - new Date(this._viewYear, this._viewMonth, r).getDay(), c = r + d;
|
|
1011
|
+
c <= a && (this._focusedDay = c, this.updateComplete.then(() => {
|
|
1012
|
+
var p, f;
|
|
1013
|
+
(f = (p = this._calendar) == null ? void 0 : p.querySelector(`[data-day="${c}"]`)) == null || f.focus();
|
|
724
1014
|
}));
|
|
725
1015
|
return;
|
|
726
1016
|
}
|
|
727
1017
|
let i = r;
|
|
728
1018
|
if (e === "ArrowLeft" && (i = r - 1), e === "ArrowRight" && (i = r + 1), e === "ArrowUp" && (i = r - 7), e === "ArrowDown" && (i = r + 7), i < 1) {
|
|
729
1019
|
this._prevMonth();
|
|
730
|
-
const
|
|
731
|
-
this._focusedDay =
|
|
732
|
-
var
|
|
733
|
-
const
|
|
734
|
-
(
|
|
1020
|
+
const s = new Date(this._viewYear, this._viewMonth + 1, 0).getDate();
|
|
1021
|
+
this._focusedDay = s + i, this.updateComplete.then(() => {
|
|
1022
|
+
var d, c;
|
|
1023
|
+
const o = this._focusedDay;
|
|
1024
|
+
(c = (d = this._calendar) == null ? void 0 : d.querySelector(`[data-day="${o}"]`)) == null || c.focus();
|
|
735
1025
|
});
|
|
736
1026
|
return;
|
|
737
1027
|
}
|
|
738
1028
|
if (i > a) {
|
|
739
|
-
const
|
|
740
|
-
this._nextMonth(), this._focusedDay =
|
|
741
|
-
var
|
|
742
|
-
const
|
|
743
|
-
(
|
|
1029
|
+
const s = i - a;
|
|
1030
|
+
this._nextMonth(), this._focusedDay = s, this.updateComplete.then(() => {
|
|
1031
|
+
var d, c;
|
|
1032
|
+
const o = this._focusedDay;
|
|
1033
|
+
(c = (d = this._calendar) == null ? void 0 : d.querySelector(`[data-day="${o}"]`)) == null || c.focus();
|
|
744
1034
|
});
|
|
745
1035
|
return;
|
|
746
1036
|
}
|
|
747
1037
|
this._focusedDay = i, this.updateComplete.then(() => {
|
|
748
|
-
var
|
|
749
|
-
(
|
|
1038
|
+
var s, o;
|
|
1039
|
+
(o = (s = this._calendar) == null ? void 0 : s.querySelector(`[data-day="${i}"]`)) == null || o.focus();
|
|
750
1040
|
});
|
|
751
1041
|
}
|
|
752
1042
|
// ─── Navigation Boundary Checks ───
|
|
@@ -765,60 +1055,60 @@ let s = class extends M(S) {
|
|
|
765
1055
|
// ─── Focus Trap ───
|
|
766
1056
|
/** @internal */
|
|
767
1057
|
_handleCalendarTab(t) {
|
|
768
|
-
var
|
|
1058
|
+
var s, o;
|
|
769
1059
|
if (t.key !== "Tab" || !this._isOpen) return;
|
|
770
|
-
const e = (
|
|
1060
|
+
const e = (s = this._calendar) == null ? void 0 : s.querySelectorAll(
|
|
771
1061
|
'button:not([disabled]), [tabindex="0"]'
|
|
772
1062
|
);
|
|
773
1063
|
if (!e || e.length === 0) return;
|
|
774
|
-
const r = e[0], a = e[e.length - 1], i = (
|
|
1064
|
+
const r = e[0], a = e[e.length - 1], i = (o = this.shadowRoot) == null ? void 0 : o.activeElement;
|
|
775
1065
|
t.shiftKey ? i === r && (t.preventDefault(), a == null || a.focus()) : i === a && (t.preventDefault(), r == null || r.focus());
|
|
776
1066
|
}
|
|
777
1067
|
// ─── Render Helpers ───
|
|
778
1068
|
/** @internal */
|
|
779
1069
|
_renderWeekdayHeaders() {
|
|
780
1070
|
const e = this._getWeekdayNames().map(
|
|
781
|
-
(r) =>
|
|
1071
|
+
(r) => y`<div class="calendar__weekday" role="columnheader" aria-label=${r}>
|
|
782
1072
|
${r.slice(0, 2)}
|
|
783
1073
|
</div>`
|
|
784
1074
|
);
|
|
785
|
-
return
|
|
1075
|
+
return y`<div class="calendar__row" role="row">${e}</div>`;
|
|
786
1076
|
}
|
|
787
1077
|
/** @internal */
|
|
788
1078
|
_renderDayGrid() {
|
|
789
1079
|
const t = this._dayGrid, e = this._parseISODate(this.value), r = /* @__PURE__ */ new Date(), a = [];
|
|
790
1080
|
for (let i = 0; i < t.length; i += 7) {
|
|
791
|
-
const
|
|
792
|
-
if (
|
|
793
|
-
return
|
|
794
|
-
const
|
|
795
|
-
return
|
|
1081
|
+
const s = t.slice(i, i + 7).map((o) => {
|
|
1082
|
+
if (o === null)
|
|
1083
|
+
return y`<div class="calendar__day-cell" role="gridcell" aria-hidden="true"></div>`;
|
|
1084
|
+
const d = e ? this._isSameDay(o, e) : !1, c = this._isSameDay(o, r), p = this._isDateDisabled(o), f = this._focusedDay === o.getDate(), w = o.getDate(), m = this._toISO(o), v = this._dayAriaLabels.get(m) ?? m;
|
|
1085
|
+
return y`<div
|
|
796
1086
|
class="calendar__day-cell"
|
|
797
1087
|
role="gridcell"
|
|
798
|
-
aria-selected=${
|
|
799
|
-
aria-disabled=${p ? "true" :
|
|
800
|
-
aria-current=${
|
|
1088
|
+
aria-selected=${d ? "true" : "false"}
|
|
1089
|
+
aria-disabled=${p ? "true" : D}
|
|
1090
|
+
aria-current=${c ? "date" : D}
|
|
801
1091
|
>
|
|
802
1092
|
<button
|
|
803
1093
|
part="day"
|
|
804
|
-
class=${
|
|
1094
|
+
class=${B({
|
|
805
1095
|
calendar__day: !0,
|
|
806
|
-
"calendar__day--selected":
|
|
807
|
-
"calendar__day--today":
|
|
1096
|
+
"calendar__day--selected": d,
|
|
1097
|
+
"calendar__day--today": c,
|
|
808
1098
|
"calendar__day--disabled": p
|
|
809
1099
|
})}
|
|
810
1100
|
type="button"
|
|
811
|
-
data-day=${
|
|
812
|
-
data-date=${
|
|
813
|
-
aria-label=${
|
|
814
|
-
tabindex=${
|
|
1101
|
+
data-day=${w}
|
|
1102
|
+
data-date=${m}
|
|
1103
|
+
aria-label=${v}
|
|
1104
|
+
tabindex=${f ? "0" : "-1"}
|
|
815
1105
|
?disabled=${p}
|
|
816
1106
|
>
|
|
817
|
-
${
|
|
1107
|
+
${w}
|
|
818
1108
|
</button>
|
|
819
1109
|
</div>`;
|
|
820
1110
|
});
|
|
821
|
-
a.push(
|
|
1111
|
+
a.push(y`<div class="calendar__row" role="row">${s}</div>`);
|
|
822
1112
|
}
|
|
823
1113
|
return a;
|
|
824
1114
|
}
|
|
@@ -829,22 +1119,31 @@ let s = class extends M(S) {
|
|
|
829
1119
|
"field--error": t,
|
|
830
1120
|
"field--disabled": this.disabled,
|
|
831
1121
|
"field--required": this.required
|
|
832
|
-
}
|
|
833
|
-
return
|
|
834
|
-
<div part="field" class=${
|
|
1122
|
+
};
|
|
1123
|
+
return y`
|
|
1124
|
+
<div part="field" class=${B(a)}>
|
|
835
1125
|
<!-- Label -->
|
|
836
1126
|
<div class="field__label-wrapper">
|
|
837
1127
|
<slot name="label" @slotchange=${this._handleLabelSlotChange}>
|
|
838
|
-
${this.label ?
|
|
839
|
-
<label part="label" class="field__label" for=${this._inputId}>
|
|
1128
|
+
${this.label ? y`
|
|
1129
|
+
<label part="label" id=${this._labelId} class="field__label" for=${this._inputId}>
|
|
840
1130
|
${this.label}
|
|
841
|
-
${this.required ?
|
|
1131
|
+
${this.required ? y`<span class="field__required-marker" aria-hidden="true">*</span>` : D}
|
|
842
1132
|
</label>
|
|
843
|
-
` :
|
|
1133
|
+
` : D}
|
|
844
1134
|
</slot>
|
|
845
1135
|
</div>
|
|
846
1136
|
|
|
847
1137
|
<!-- Input + Trigger -->
|
|
1138
|
+
<!--
|
|
1139
|
+
W3C APG date picker dialog pattern: the inner input is a readonly
|
|
1140
|
+
text input, NOT a combobox. Users do not type — they open the dialog
|
|
1141
|
+
via the trigger button (or by clicking the input). The trigger button
|
|
1142
|
+
owns aria-expanded and aria-controls (pointed at the in-shadow
|
|
1143
|
+
calendar id) for the dialog. Cross-shadow aria-controls referencing
|
|
1144
|
+
an in-shadow id is a documented limitation and matches the precedent
|
|
1145
|
+
set by hx-popover and hx-dropdown.
|
|
1146
|
+
-->
|
|
848
1147
|
<div part="input-wrapper" class="field__input-wrapper">
|
|
849
1148
|
<input
|
|
850
1149
|
part="input"
|
|
@@ -853,14 +1152,11 @@ let s = class extends M(S) {
|
|
|
853
1152
|
type="text"
|
|
854
1153
|
readonly
|
|
855
1154
|
.value=${e}
|
|
856
|
-
placeholder=${
|
|
1155
|
+
placeholder=${U(this.format || void 0)}
|
|
857
1156
|
?disabled=${this.disabled}
|
|
858
|
-
aria-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
aria-invalid=${t ? "true" : u}
|
|
862
|
-
aria-describedby=${m(i)}
|
|
863
|
-
aria-required=${this.required ? "true" : u}
|
|
1157
|
+
aria-invalid=${this._invalid ? "true" : "false"}
|
|
1158
|
+
aria-required=${this.required ? "true" : "false"}
|
|
1159
|
+
aria-disabled=${this.disabled ? "true" : D}
|
|
864
1160
|
aria-haspopup="dialog"
|
|
865
1161
|
@click=${this._openCalendar}
|
|
866
1162
|
/>
|
|
@@ -940,7 +1236,6 @@ let s = class extends M(S) {
|
|
|
940
1236
|
</div>
|
|
941
1237
|
|
|
942
1238
|
<!-- Day Grid -->
|
|
943
|
-
<!-- Single delegated click handler on the grid replaces per-cell closures. -->
|
|
944
1239
|
<div
|
|
945
1240
|
class="calendar__grid"
|
|
946
1241
|
role="grid"
|
|
@@ -951,112 +1246,153 @@ let s = class extends M(S) {
|
|
|
951
1246
|
</div>
|
|
952
1247
|
</dialog>
|
|
953
1248
|
|
|
954
|
-
<!--
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
1249
|
+
<!--
|
|
1250
|
+
Persistent error live region. role="alert" is set from first paint
|
|
1251
|
+
so the WAI-ARIA contract for live updates is honoured.
|
|
1252
|
+
-->
|
|
1253
|
+
<div
|
|
1254
|
+
part="error"
|
|
1255
|
+
class="field__error"
|
|
1256
|
+
id=${this._errorId}
|
|
1257
|
+
role="alert"
|
|
1258
|
+
?hidden=${!t}
|
|
1259
|
+
>
|
|
1260
|
+
<slot name="error" @slotchange=${this._handleErrorSlotChange}
|
|
1261
|
+
>${this._announcedError}</slot
|
|
1262
|
+
>
|
|
1263
|
+
</div>
|
|
962
1264
|
|
|
963
1265
|
<!-- Help Text -->
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
1266
|
+
<div
|
|
1267
|
+
part="help-text"
|
|
1268
|
+
class="field__help-text"
|
|
1269
|
+
id=${this._helpTextId}
|
|
1270
|
+
?hidden=${!this.helpText && !this._hasHelpSlot || t}
|
|
1271
|
+
>
|
|
1272
|
+
<slot name="help-text" @slotchange=${this._handleHelpSlotChange}>${this.helpText}</slot>
|
|
1273
|
+
</div>
|
|
1274
|
+
|
|
1275
|
+
<!--
|
|
1276
|
+
Synthesized in-shadow mirror of the consumer-resolved description
|
|
1277
|
+
text. Its id is appended to the inner input's aria-describedby chain
|
|
1278
|
+
so AT picks the consumer description up through the standard
|
|
1279
|
+
described-by channel without needing aria-description (which W3C
|
|
1280
|
+
AccName drops whenever aria-describedby is also present).
|
|
1281
|
+
-->
|
|
1282
|
+
<span id=${this._consumerDescId} class="field__sr-only" aria-hidden="false"></span>
|
|
969
1283
|
</div>
|
|
970
1284
|
`;
|
|
971
1285
|
}
|
|
972
1286
|
};
|
|
973
|
-
|
|
974
|
-
|
|
1287
|
+
l.styles = [J, V];
|
|
1288
|
+
l.formAssociated = !0;
|
|
1289
|
+
l.__testSupportsIdrefRefsOverride = null;
|
|
1290
|
+
n([
|
|
1291
|
+
h({ type: String, reflect: !0 })
|
|
1292
|
+
], l.prototype, "name", 2);
|
|
1293
|
+
n([
|
|
1294
|
+
h({ type: String })
|
|
1295
|
+
], l.prototype, "value", 2);
|
|
1296
|
+
n([
|
|
1297
|
+
h({ type: String })
|
|
1298
|
+
], l.prototype, "min", 2);
|
|
1299
|
+
n([
|
|
1300
|
+
h({ type: String })
|
|
1301
|
+
], l.prototype, "max", 2);
|
|
1302
|
+
n([
|
|
1303
|
+
h({ type: String })
|
|
1304
|
+
], l.prototype, "label", 2);
|
|
1305
|
+
n([
|
|
1306
|
+
h({ type: Boolean, reflect: !0 })
|
|
1307
|
+
], l.prototype, "required", 2);
|
|
1308
|
+
n([
|
|
1309
|
+
h({ type: Boolean, reflect: !0 })
|
|
1310
|
+
], l.prototype, "disabled", 2);
|
|
975
1311
|
n([
|
|
976
|
-
|
|
977
|
-
],
|
|
1312
|
+
h({ type: String })
|
|
1313
|
+
], l.prototype, "error", 2);
|
|
978
1314
|
n([
|
|
979
|
-
|
|
980
|
-
],
|
|
1315
|
+
h({ type: String, attribute: "help-text" })
|
|
1316
|
+
], l.prototype, "helpText", 2);
|
|
981
1317
|
n([
|
|
982
|
-
|
|
983
|
-
],
|
|
1318
|
+
h({ type: String })
|
|
1319
|
+
], l.prototype, "format", 2);
|
|
984
1320
|
n([
|
|
985
|
-
|
|
986
|
-
],
|
|
1321
|
+
h({ type: String })
|
|
1322
|
+
], l.prototype, "locale", 2);
|
|
987
1323
|
n([
|
|
988
|
-
|
|
989
|
-
],
|
|
1324
|
+
h({ type: String, attribute: "required-message" })
|
|
1325
|
+
], l.prototype, "requiredMessage", 2);
|
|
990
1326
|
n([
|
|
991
|
-
|
|
992
|
-
],
|
|
1327
|
+
h({ type: String, attribute: "choose-date-label" })
|
|
1328
|
+
], l.prototype, "chooseDateLabel", 2);
|
|
993
1329
|
n([
|
|
994
|
-
|
|
995
|
-
],
|
|
1330
|
+
h({ type: String, attribute: "open-calendar-label" })
|
|
1331
|
+
], l.prototype, "openCalendarLabel", 2);
|
|
996
1332
|
n([
|
|
997
|
-
|
|
998
|
-
],
|
|
1333
|
+
h({ type: String, attribute: "close-calendar-label" })
|
|
1334
|
+
], l.prototype, "closeCalendarLabel", 2);
|
|
999
1335
|
n([
|
|
1000
|
-
|
|
1001
|
-
],
|
|
1336
|
+
h({ type: String, attribute: "previous-month-label" })
|
|
1337
|
+
], l.prototype, "previousMonthLabel", 2);
|
|
1002
1338
|
n([
|
|
1003
|
-
|
|
1004
|
-
],
|
|
1339
|
+
h({ type: String, attribute: "next-month-label" })
|
|
1340
|
+
], l.prototype, "nextMonthLabel", 2);
|
|
1005
1341
|
n([
|
|
1006
|
-
|
|
1007
|
-
],
|
|
1342
|
+
h({ type: String, attribute: "accessible-label" })
|
|
1343
|
+
], l.prototype, "accessibleLabel", 2);
|
|
1008
1344
|
n([
|
|
1009
|
-
|
|
1010
|
-
],
|
|
1345
|
+
_()
|
|
1346
|
+
], l.prototype, "_isOpen", 2);
|
|
1011
1347
|
n([
|
|
1012
|
-
|
|
1013
|
-
],
|
|
1348
|
+
_()
|
|
1349
|
+
], l.prototype, "_viewYear", 2);
|
|
1014
1350
|
n([
|
|
1015
|
-
|
|
1016
|
-
],
|
|
1351
|
+
_()
|
|
1352
|
+
], l.prototype, "_viewMonth", 2);
|
|
1017
1353
|
n([
|
|
1018
|
-
|
|
1019
|
-
],
|
|
1354
|
+
_()
|
|
1355
|
+
], l.prototype, "_focusedDay", 2);
|
|
1020
1356
|
n([
|
|
1021
|
-
|
|
1022
|
-
],
|
|
1357
|
+
_()
|
|
1358
|
+
], l.prototype, "_liveMessage", 2);
|
|
1023
1359
|
n([
|
|
1024
|
-
|
|
1025
|
-
],
|
|
1360
|
+
N(".field__input")
|
|
1361
|
+
], l.prototype, "_input", 2);
|
|
1026
1362
|
n([
|
|
1027
|
-
|
|
1028
|
-
],
|
|
1363
|
+
N(".field__trigger")
|
|
1364
|
+
], l.prototype, "_trigger", 2);
|
|
1029
1365
|
n([
|
|
1030
|
-
|
|
1031
|
-
],
|
|
1366
|
+
N(".calendar")
|
|
1367
|
+
], l.prototype, "_calendar", 2);
|
|
1032
1368
|
n([
|
|
1033
|
-
|
|
1034
|
-
],
|
|
1369
|
+
_()
|
|
1370
|
+
], l.prototype, "_hasLabelSlot", 2);
|
|
1035
1371
|
n([
|
|
1036
|
-
|
|
1037
|
-
],
|
|
1372
|
+
_()
|
|
1373
|
+
], l.prototype, "_hasErrorSlot", 2);
|
|
1038
1374
|
n([
|
|
1039
|
-
|
|
1040
|
-
],
|
|
1375
|
+
_()
|
|
1376
|
+
], l.prototype, "_hasHelpSlot", 2);
|
|
1041
1377
|
n([
|
|
1042
|
-
|
|
1043
|
-
],
|
|
1378
|
+
_()
|
|
1379
|
+
], l.prototype, "_labelSource", 2);
|
|
1044
1380
|
n([
|
|
1045
|
-
|
|
1046
|
-
],
|
|
1381
|
+
_()
|
|
1382
|
+
], l.prototype, "_labelSlotText", 2);
|
|
1047
1383
|
n([
|
|
1048
|
-
|
|
1049
|
-
],
|
|
1384
|
+
_()
|
|
1385
|
+
], l.prototype, "_supportsIdrefRefs", 2);
|
|
1050
1386
|
n([
|
|
1051
|
-
|
|
1052
|
-
],
|
|
1387
|
+
_()
|
|
1388
|
+
], l.prototype, "_invalid", 2);
|
|
1053
1389
|
n([
|
|
1054
|
-
|
|
1055
|
-
],
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
],
|
|
1390
|
+
_()
|
|
1391
|
+
], l.prototype, "_announcedError", 2);
|
|
1392
|
+
l = n([
|
|
1393
|
+
W("hx-date-picker")
|
|
1394
|
+
], l);
|
|
1059
1395
|
export {
|
|
1060
|
-
|
|
1396
|
+
l as H
|
|
1061
1397
|
};
|
|
1062
|
-
//# sourceMappingURL=hx-date-picker-
|
|
1398
|
+
//# sourceMappingURL=hx-date-picker-CiR7FVnR.js.map
|