@daikin-oss/design-system-web-components 1.6.0 → 2.0.0-next.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +96 -0
- package/custom-elements.json +1380 -69
- package/dist/cjs/base/dds-element.cjs +1 -1
- package/dist/cjs/components/accordion-item/daikin-accordion-item.cjs +25 -8
- package/dist/cjs/components/accordion-item/daikin-accordion-item.d.cts +1 -0
- package/dist/cjs/components/breadcrumb/daikin-breadcrumb.d.cts +1 -1
- package/dist/cjs/components/breadcrumb-item/daikin-breadcrumb-item.cjs +9 -6
- package/dist/cjs/components/breadcrumb-item/daikin-breadcrumb-item.d.cts +1 -0
- package/dist/cjs/components/calendar/daikin-calendar.cjs +73 -26
- package/dist/cjs/components/calendar/daikin-calendar.d.cts +13 -0
- package/dist/cjs/components/checkbox/daikin-checkbox.cjs +190 -52
- package/dist/cjs/components/checkbox/daikin-checkbox.d.cts +18 -0
- package/dist/cjs/components/checkbox-group/daikin-checkbox-group.cjs +7 -1
- package/dist/cjs/components/checkbox-group/daikin-checkbox-group.d.cts +5 -0
- package/dist/cjs/components/chip/daikin-chip.cjs +195 -93
- package/dist/cjs/components/chip/daikin-chip.d.cts +20 -0
- package/dist/cjs/components/combobox/daikin-combobox.cjs +111 -33
- package/dist/cjs/components/combobox/daikin-combobox.d.cts +10 -0
- package/dist/cjs/components/date-picker/daikin-date-picker.cjs +243 -65
- package/dist/cjs/components/date-picker/daikin-date-picker.d.cts +37 -2
- package/dist/cjs/components/drawer/daikin-drawer.cjs +1 -1
- package/dist/cjs/components/dropdown/daikin-dropdown.cjs +164 -32
- package/dist/cjs/components/dropdown/daikin-dropdown.d.cts +13 -0
- package/dist/cjs/components/dropdown-item/daikin-dropdown-item.cjs +13 -6
- package/dist/cjs/components/icon-button/daikin-icon-button.cjs +2 -0
- package/dist/cjs/components/icon-button/daikin-icon-button.d.cts +2 -0
- package/dist/cjs/components/index.cjs +2 -2
- package/dist/cjs/components/input-group/daikin-input-group.cjs +88 -30
- package/dist/cjs/components/input-group/daikin-input-group.d.cts +10 -0
- package/dist/cjs/components/list-item/daikin-list-item.cjs +21 -10
- package/dist/cjs/components/list-item/daikin-list-item.d.cts +9 -0
- package/dist/cjs/components/logo/daikin-logo.cjs +1 -1
- package/dist/cjs/components/logo/daikin-logo.d.cts +2 -2
- package/dist/cjs/components/menu/daikin-menu.cjs +2 -2
- package/dist/cjs/components/modal-header/daikin-modal-header.cjs +10 -4
- package/dist/cjs/components/modal-header/daikin-modal-header.d.cts +1 -0
- package/dist/cjs/components/navigation/daikin-navigation.cjs +21 -0
- package/dist/cjs/components/navigation/daikin-navigation.d.cts +9 -0
- package/dist/cjs/components/navigation-item/daikin-navigation-item.cjs +18 -14
- package/dist/cjs/components/pagination/daikin-pagination.cjs +60 -19
- package/dist/cjs/components/pagination/daikin-pagination.d.cts +11 -0
- package/dist/cjs/components/progress-bar/daikin-progress-bar.cjs +27 -19
- package/dist/cjs/components/progress-bar/daikin-progress-bar.d.cts +1 -0
- package/dist/cjs/components/radio/daikin-radio.cjs +160 -35
- package/dist/cjs/components/radio/daikin-radio.d.cts +26 -0
- package/dist/cjs/components/radio-group/daikin-radio-group.cjs +10 -1
- package/dist/cjs/components/radio-group/daikin-radio-group.d.cts +4 -0
- package/dist/cjs/components/select/daikin-select.cjs +128 -21
- package/dist/cjs/components/select/daikin-select.d.cts +11 -0
- package/dist/cjs/components/slider/daikin-slider.cjs +61 -16
- package/dist/cjs/components/slider/daikin-slider.d.cts +4 -0
- package/dist/cjs/components/status-message/daikin-status-message.cjs +1 -0
- package/dist/cjs/components/status-message/daikin-status-message.d.cts +2 -0
- package/dist/cjs/components/table/daikin-table.cjs +108 -16
- package/dist/cjs/components/table/daikin-table.d.cts +58 -1
- package/dist/cjs/components/table-cell/daikin-table-cell.cjs +3 -4
- package/dist/cjs/components/table-header-cell/daikin-table-header-cell.cjs +21 -15
- package/dist/cjs/components/tag/daikin-tag.cjs +99 -20
- package/dist/cjs/components/tag/daikin-tag.d.cts +14 -0
- package/dist/cjs/components/text-area/daikin-text-area.cjs +22 -2
- package/dist/cjs/components/text-field/daikin-text-field.cjs +96 -50
- package/dist/cjs/components/text-field/daikin-text-field.d.cts +9 -0
- package/dist/cjs/components/text-field/number-utils.cjs +51 -19
- package/dist/cjs/components/text-field/number-utils.d.cts +7 -0
- package/dist/cjs/components/text-masked-field/daikin-text-masked-field.cjs +31 -7
- package/dist/cjs/components/time-picker/daikin-time-picker.cjs +325 -108
- package/dist/cjs/components/time-picker/daikin-time-picker.d.cts +57 -14
- package/dist/cjs/components/time-picker/index.cjs +2 -2
- package/dist/cjs/components/toast-notification-manager/daikin-toast-notification-manager.cjs +1 -1
- package/dist/cjs/components/toggle/daikin-toggle.cjs +110 -35
- package/dist/cjs/components/toggle/daikin-toggle.d.cts +5 -0
- package/dist/cjs/components/tooltip/daikin-tooltip.cjs +1 -1
- package/dist/cjs/components/tree-item/daikin-tree-item.cjs +24 -8
- package/dist/cjs/components/tree-item/daikin-tree-item.d.cts +1 -0
- package/dist/cjs/components/tree-section/daikin-tree-section.cjs +7 -1
- package/dist/cjs/components/tree-section/daikin-tree-section.d.cts +1 -0
- package/dist/cjs/components/vertical-navigation/daikin-vertical-navigation.cjs +1 -1
- package/dist/cjs/components/vertical-navigation-item/daikin-vertical-navigation-item.cjs +248 -38
- package/dist/cjs/components/vertical-navigation-item/daikin-vertical-navigation-item.d.cts +17 -7
- package/dist/cjs/components/vertical-navigation-menu-item/daikin-vertical-navigation-menu-item.cjs +103 -33
- package/dist/cjs/components/vertical-navigation-menu-item/daikin-vertical-navigation-menu-item.d.cts +6 -1
- package/dist/cjs/controllers/custom-readonly.cjs +59 -0
- package/dist/cjs/controllers/custom-readonly.d.cts +28 -0
- package/dist/cjs/index.cjs +2 -2
- package/dist/cjs/tailwind.css.cjs +1 -1
- package/dist/cjs/utils/calendar-common.cjs +6 -2
- package/dist/cjs/utils/calendar-common.d.cts +1 -1
- package/dist/cjs/utils/extract-half-width-digits.cjs +11 -0
- package/dist/cjs/utils/extract-half-width-digits.d.cts +15 -0
- package/dist/cjs-dev/base/dds-element.cjs +1 -1
- package/dist/cjs-dev/components/accordion-item/daikin-accordion-item.cjs +25 -8
- package/dist/cjs-dev/components/accordion-item/daikin-accordion-item.d.cts +1 -0
- package/dist/cjs-dev/components/breadcrumb/daikin-breadcrumb.d.cts +1 -1
- package/dist/cjs-dev/components/breadcrumb-item/daikin-breadcrumb-item.cjs +9 -6
- package/dist/cjs-dev/components/breadcrumb-item/daikin-breadcrumb-item.d.cts +1 -0
- package/dist/cjs-dev/components/calendar/daikin-calendar.cjs +73 -26
- package/dist/cjs-dev/components/calendar/daikin-calendar.d.cts +13 -0
- package/dist/cjs-dev/components/checkbox/daikin-checkbox.cjs +190 -52
- package/dist/cjs-dev/components/checkbox/daikin-checkbox.d.cts +18 -0
- package/dist/cjs-dev/components/checkbox-group/daikin-checkbox-group.cjs +7 -1
- package/dist/cjs-dev/components/checkbox-group/daikin-checkbox-group.d.cts +5 -0
- package/dist/cjs-dev/components/chip/daikin-chip.cjs +195 -93
- package/dist/cjs-dev/components/chip/daikin-chip.d.cts +20 -0
- package/dist/cjs-dev/components/combobox/daikin-combobox.cjs +111 -33
- package/dist/cjs-dev/components/combobox/daikin-combobox.d.cts +10 -0
- package/dist/cjs-dev/components/date-picker/daikin-date-picker.cjs +243 -65
- package/dist/cjs-dev/components/date-picker/daikin-date-picker.d.cts +37 -2
- package/dist/cjs-dev/components/drawer/daikin-drawer.cjs +1 -1
- package/dist/cjs-dev/components/dropdown/daikin-dropdown.cjs +164 -32
- package/dist/cjs-dev/components/dropdown/daikin-dropdown.d.cts +13 -0
- package/dist/cjs-dev/components/dropdown-item/daikin-dropdown-item.cjs +13 -6
- package/dist/cjs-dev/components/icon-button/daikin-icon-button.cjs +2 -0
- package/dist/cjs-dev/components/icon-button/daikin-icon-button.d.cts +2 -0
- package/dist/cjs-dev/components/index.cjs +2 -2
- package/dist/cjs-dev/components/input-group/daikin-input-group.cjs +88 -30
- package/dist/cjs-dev/components/input-group/daikin-input-group.d.cts +10 -0
- package/dist/cjs-dev/components/list-item/daikin-list-item.cjs +21 -10
- package/dist/cjs-dev/components/list-item/daikin-list-item.d.cts +9 -0
- package/dist/cjs-dev/components/logo/daikin-logo.cjs +1 -1
- package/dist/cjs-dev/components/logo/daikin-logo.d.cts +2 -2
- package/dist/cjs-dev/components/menu/daikin-menu.cjs +2 -2
- package/dist/cjs-dev/components/modal-header/daikin-modal-header.cjs +10 -4
- package/dist/cjs-dev/components/modal-header/daikin-modal-header.d.cts +1 -0
- package/dist/cjs-dev/components/navigation/daikin-navigation.cjs +21 -0
- package/dist/cjs-dev/components/navigation/daikin-navigation.d.cts +9 -0
- package/dist/cjs-dev/components/navigation-item/daikin-navigation-item.cjs +18 -14
- package/dist/cjs-dev/components/pagination/daikin-pagination.cjs +60 -19
- package/dist/cjs-dev/components/pagination/daikin-pagination.d.cts +11 -0
- package/dist/cjs-dev/components/progress-bar/daikin-progress-bar.cjs +27 -19
- package/dist/cjs-dev/components/progress-bar/daikin-progress-bar.d.cts +1 -0
- package/dist/cjs-dev/components/radio/daikin-radio.cjs +160 -35
- package/dist/cjs-dev/components/radio/daikin-radio.d.cts +26 -0
- package/dist/cjs-dev/components/radio-group/daikin-radio-group.cjs +10 -1
- package/dist/cjs-dev/components/radio-group/daikin-radio-group.d.cts +4 -0
- package/dist/cjs-dev/components/select/daikin-select.cjs +128 -21
- package/dist/cjs-dev/components/select/daikin-select.d.cts +11 -0
- package/dist/cjs-dev/components/slider/daikin-slider.cjs +61 -16
- package/dist/cjs-dev/components/slider/daikin-slider.d.cts +4 -0
- package/dist/cjs-dev/components/status-message/daikin-status-message.cjs +1 -0
- package/dist/cjs-dev/components/status-message/daikin-status-message.d.cts +2 -0
- package/dist/cjs-dev/components/table/daikin-table.cjs +108 -16
- package/dist/cjs-dev/components/table/daikin-table.d.cts +58 -1
- package/dist/cjs-dev/components/table-cell/daikin-table-cell.cjs +3 -4
- package/dist/cjs-dev/components/table-header-cell/daikin-table-header-cell.cjs +21 -15
- package/dist/cjs-dev/components/tag/daikin-tag.cjs +99 -20
- package/dist/cjs-dev/components/tag/daikin-tag.d.cts +14 -0
- package/dist/cjs-dev/components/text-area/daikin-text-area.cjs +22 -2
- package/dist/cjs-dev/components/text-field/daikin-text-field.cjs +96 -50
- package/dist/cjs-dev/components/text-field/daikin-text-field.d.cts +9 -0
- package/dist/cjs-dev/components/text-field/number-utils.cjs +51 -19
- package/dist/cjs-dev/components/text-field/number-utils.d.cts +7 -0
- package/dist/cjs-dev/components/text-masked-field/daikin-text-masked-field.cjs +31 -7
- package/dist/cjs-dev/components/time-picker/daikin-time-picker.cjs +325 -108
- package/dist/cjs-dev/components/time-picker/daikin-time-picker.d.cts +57 -14
- package/dist/cjs-dev/components/time-picker/index.cjs +2 -2
- package/dist/cjs-dev/components/toast-notification-manager/daikin-toast-notification-manager.cjs +1 -1
- package/dist/cjs-dev/components/toggle/daikin-toggle.cjs +110 -35
- package/dist/cjs-dev/components/toggle/daikin-toggle.d.cts +5 -0
- package/dist/cjs-dev/components/tooltip/daikin-tooltip.cjs +1 -1
- package/dist/cjs-dev/components/tree-item/daikin-tree-item.cjs +24 -8
- package/dist/cjs-dev/components/tree-item/daikin-tree-item.d.cts +1 -0
- package/dist/cjs-dev/components/tree-section/daikin-tree-section.cjs +7 -1
- package/dist/cjs-dev/components/tree-section/daikin-tree-section.d.cts +1 -0
- package/dist/cjs-dev/components/vertical-navigation/daikin-vertical-navigation.cjs +1 -1
- package/dist/cjs-dev/components/vertical-navigation-item/daikin-vertical-navigation-item.cjs +248 -38
- package/dist/cjs-dev/components/vertical-navigation-item/daikin-vertical-navigation-item.d.cts +17 -7
- package/dist/cjs-dev/components/vertical-navigation-menu-item/daikin-vertical-navigation-menu-item.cjs +103 -33
- package/dist/cjs-dev/components/vertical-navigation-menu-item/daikin-vertical-navigation-menu-item.d.cts +6 -1
- package/dist/cjs-dev/controllers/custom-readonly.cjs +59 -0
- package/dist/cjs-dev/controllers/custom-readonly.d.cts +28 -0
- package/dist/cjs-dev/index.cjs +2 -2
- package/dist/cjs-dev/tailwind.css.cjs +1 -1
- package/dist/cjs-dev/utils/calendar-common.cjs +6 -2
- package/dist/cjs-dev/utils/calendar-common.d.cts +1 -1
- package/dist/cjs-dev/utils/extract-half-width-digits.cjs +11 -0
- package/dist/cjs-dev/utils/extract-half-width-digits.d.cts +15 -0
- package/dist/es/base/dds-element.js +1 -1
- package/dist/es/components/accordion-item/daikin-accordion-item.d.ts +1 -0
- package/dist/es/components/accordion-item/daikin-accordion-item.js +25 -8
- package/dist/es/components/breadcrumb/daikin-breadcrumb.d.ts +1 -1
- package/dist/es/components/breadcrumb-item/daikin-breadcrumb-item.d.ts +1 -0
- package/dist/es/components/breadcrumb-item/daikin-breadcrumb-item.js +9 -6
- package/dist/es/components/calendar/daikin-calendar.d.ts +13 -0
- package/dist/es/components/calendar/daikin-calendar.js +73 -26
- package/dist/es/components/checkbox/daikin-checkbox.d.ts +18 -0
- package/dist/es/components/checkbox/daikin-checkbox.js +190 -52
- package/dist/es/components/checkbox-group/daikin-checkbox-group.d.ts +5 -0
- package/dist/es/components/checkbox-group/daikin-checkbox-group.js +7 -1
- package/dist/es/components/chip/daikin-chip.d.ts +20 -0
- package/dist/es/components/chip/daikin-chip.js +195 -93
- package/dist/es/components/combobox/daikin-combobox.d.ts +10 -0
- package/dist/es/components/combobox/daikin-combobox.js +111 -33
- package/dist/es/components/date-picker/daikin-date-picker.d.ts +37 -2
- package/dist/es/components/date-picker/daikin-date-picker.js +243 -65
- package/dist/es/components/drawer/daikin-drawer.js +1 -1
- package/dist/es/components/dropdown/daikin-dropdown.d.ts +13 -0
- package/dist/es/components/dropdown/daikin-dropdown.js +164 -32
- package/dist/es/components/dropdown-item/daikin-dropdown-item.js +13 -6
- package/dist/es/components/icon-button/daikin-icon-button.d.ts +2 -0
- package/dist/es/components/icon-button/daikin-icon-button.js +2 -0
- package/dist/es/components/index.js +4 -4
- package/dist/es/components/input-group/daikin-input-group.d.ts +10 -0
- package/dist/es/components/input-group/daikin-input-group.js +89 -31
- package/dist/es/components/list-item/daikin-list-item.d.ts +9 -0
- package/dist/es/components/list-item/daikin-list-item.js +21 -10
- package/dist/es/components/logo/daikin-logo.d.ts +2 -2
- package/dist/es/components/logo/daikin-logo.js +1 -1
- package/dist/es/components/menu/daikin-menu.js +2 -2
- package/dist/es/components/modal-header/daikin-modal-header.d.ts +1 -0
- package/dist/es/components/modal-header/daikin-modal-header.js +10 -4
- package/dist/es/components/navigation/daikin-navigation.d.ts +9 -0
- package/dist/es/components/navigation/daikin-navigation.js +22 -1
- package/dist/es/components/navigation-item/daikin-navigation-item.js +18 -14
- package/dist/es/components/pagination/daikin-pagination.d.ts +11 -0
- package/dist/es/components/pagination/daikin-pagination.js +61 -20
- package/dist/es/components/progress-bar/daikin-progress-bar.d.ts +1 -0
- package/dist/es/components/progress-bar/daikin-progress-bar.js +27 -19
- package/dist/es/components/radio/daikin-radio.d.ts +26 -0
- package/dist/es/components/radio/daikin-radio.js +160 -35
- package/dist/es/components/radio-group/daikin-radio-group.d.ts +4 -0
- package/dist/es/components/radio-group/daikin-radio-group.js +10 -1
- package/dist/es/components/select/daikin-select.d.ts +11 -0
- package/dist/es/components/select/daikin-select.js +128 -21
- package/dist/es/components/slider/daikin-slider.d.ts +4 -0
- package/dist/es/components/slider/daikin-slider.js +61 -16
- package/dist/es/components/status-message/daikin-status-message.d.ts +2 -0
- package/dist/es/components/status-message/daikin-status-message.js +1 -0
- package/dist/es/components/table/daikin-table.d.ts +58 -1
- package/dist/es/components/table/daikin-table.js +109 -17
- package/dist/es/components/table-cell/daikin-table-cell.js +3 -4
- package/dist/es/components/table-header-cell/daikin-table-header-cell.js +21 -15
- package/dist/es/components/tag/daikin-tag.d.ts +14 -0
- package/dist/es/components/tag/daikin-tag.js +100 -21
- package/dist/es/components/text-area/daikin-text-area.js +22 -2
- package/dist/es/components/text-field/daikin-text-field.d.ts +9 -0
- package/dist/es/components/text-field/daikin-text-field.js +97 -51
- package/dist/es/components/text-field/number-utils.d.ts +7 -0
- package/dist/es/components/text-field/number-utils.js +51 -19
- package/dist/es/components/text-masked-field/daikin-text-masked-field.js +31 -7
- package/dist/es/components/time-picker/daikin-time-picker.d.ts +57 -14
- package/dist/es/components/time-picker/daikin-time-picker.js +327 -110
- package/dist/es/components/time-picker/index.js +4 -4
- package/dist/es/components/toast-notification-manager/daikin-toast-notification-manager.js +1 -1
- package/dist/es/components/toggle/daikin-toggle.d.ts +5 -0
- package/dist/es/components/toggle/daikin-toggle.js +110 -35
- package/dist/es/components/tooltip/daikin-tooltip.js +1 -1
- package/dist/es/components/tree-item/daikin-tree-item.d.ts +1 -0
- package/dist/es/components/tree-item/daikin-tree-item.js +24 -8
- package/dist/es/components/tree-section/daikin-tree-section.d.ts +1 -0
- package/dist/es/components/tree-section/daikin-tree-section.js +7 -1
- package/dist/es/components/vertical-navigation/daikin-vertical-navigation.js +1 -1
- package/dist/es/components/vertical-navigation-item/daikin-vertical-navigation-item.d.ts +17 -7
- package/dist/es/components/vertical-navigation-item/daikin-vertical-navigation-item.js +248 -38
- package/dist/es/components/vertical-navigation-menu-item/daikin-vertical-navigation-menu-item.d.ts +6 -1
- package/dist/es/components/vertical-navigation-menu-item/daikin-vertical-navigation-menu-item.js +104 -34
- package/dist/es/controllers/custom-readonly.d.ts +28 -0
- package/dist/es/controllers/custom-readonly.js +59 -0
- package/dist/es/index.js +4 -4
- package/dist/es/tailwind.css.js +1 -1
- package/dist/es/utils/calendar-common.d.ts +1 -1
- package/dist/es/utils/calendar-common.js +6 -2
- package/dist/es/utils/extract-half-width-digits.d.ts +15 -0
- package/dist/es/utils/extract-half-width-digits.js +11 -0
- package/dist/es-dev/base/dds-element.js +1 -1
- package/dist/es-dev/components/accordion-item/daikin-accordion-item.d.ts +1 -0
- package/dist/es-dev/components/accordion-item/daikin-accordion-item.js +25 -8
- package/dist/es-dev/components/breadcrumb/daikin-breadcrumb.d.ts +1 -1
- package/dist/es-dev/components/breadcrumb-item/daikin-breadcrumb-item.d.ts +1 -0
- package/dist/es-dev/components/breadcrumb-item/daikin-breadcrumb-item.js +9 -6
- package/dist/es-dev/components/calendar/daikin-calendar.d.ts +13 -0
- package/dist/es-dev/components/calendar/daikin-calendar.js +73 -26
- package/dist/es-dev/components/checkbox/daikin-checkbox.d.ts +18 -0
- package/dist/es-dev/components/checkbox/daikin-checkbox.js +190 -52
- package/dist/es-dev/components/checkbox-group/daikin-checkbox-group.d.ts +5 -0
- package/dist/es-dev/components/checkbox-group/daikin-checkbox-group.js +7 -1
- package/dist/es-dev/components/chip/daikin-chip.d.ts +20 -0
- package/dist/es-dev/components/chip/daikin-chip.js +195 -93
- package/dist/es-dev/components/combobox/daikin-combobox.d.ts +10 -0
- package/dist/es-dev/components/combobox/daikin-combobox.js +111 -33
- package/dist/es-dev/components/date-picker/daikin-date-picker.d.ts +37 -2
- package/dist/es-dev/components/date-picker/daikin-date-picker.js +243 -65
- package/dist/es-dev/components/drawer/daikin-drawer.js +1 -1
- package/dist/es-dev/components/dropdown/daikin-dropdown.d.ts +13 -0
- package/dist/es-dev/components/dropdown/daikin-dropdown.js +164 -32
- package/dist/es-dev/components/dropdown-item/daikin-dropdown-item.js +13 -6
- package/dist/es-dev/components/icon-button/daikin-icon-button.d.ts +2 -0
- package/dist/es-dev/components/icon-button/daikin-icon-button.js +2 -0
- package/dist/es-dev/components/index.js +4 -4
- package/dist/es-dev/components/input-group/daikin-input-group.d.ts +10 -0
- package/dist/es-dev/components/input-group/daikin-input-group.js +89 -31
- package/dist/es-dev/components/list-item/daikin-list-item.d.ts +9 -0
- package/dist/es-dev/components/list-item/daikin-list-item.js +21 -10
- package/dist/es-dev/components/logo/daikin-logo.d.ts +2 -2
- package/dist/es-dev/components/logo/daikin-logo.js +1 -1
- package/dist/es-dev/components/menu/daikin-menu.js +2 -2
- package/dist/es-dev/components/modal-header/daikin-modal-header.d.ts +1 -0
- package/dist/es-dev/components/modal-header/daikin-modal-header.js +10 -4
- package/dist/es-dev/components/navigation/daikin-navigation.d.ts +9 -0
- package/dist/es-dev/components/navigation/daikin-navigation.js +22 -1
- package/dist/es-dev/components/navigation-item/daikin-navigation-item.js +18 -14
- package/dist/es-dev/components/pagination/daikin-pagination.d.ts +11 -0
- package/dist/es-dev/components/pagination/daikin-pagination.js +61 -20
- package/dist/es-dev/components/progress-bar/daikin-progress-bar.d.ts +1 -0
- package/dist/es-dev/components/progress-bar/daikin-progress-bar.js +27 -19
- package/dist/es-dev/components/radio/daikin-radio.d.ts +26 -0
- package/dist/es-dev/components/radio/daikin-radio.js +160 -35
- package/dist/es-dev/components/radio-group/daikin-radio-group.d.ts +4 -0
- package/dist/es-dev/components/radio-group/daikin-radio-group.js +10 -1
- package/dist/es-dev/components/select/daikin-select.d.ts +11 -0
- package/dist/es-dev/components/select/daikin-select.js +128 -21
- package/dist/es-dev/components/slider/daikin-slider.d.ts +4 -0
- package/dist/es-dev/components/slider/daikin-slider.js +61 -16
- package/dist/es-dev/components/status-message/daikin-status-message.d.ts +2 -0
- package/dist/es-dev/components/status-message/daikin-status-message.js +1 -0
- package/dist/es-dev/components/table/daikin-table.d.ts +58 -1
- package/dist/es-dev/components/table/daikin-table.js +109 -17
- package/dist/es-dev/components/table-cell/daikin-table-cell.js +3 -4
- package/dist/es-dev/components/table-header-cell/daikin-table-header-cell.js +21 -15
- package/dist/es-dev/components/tag/daikin-tag.d.ts +14 -0
- package/dist/es-dev/components/tag/daikin-tag.js +100 -21
- package/dist/es-dev/components/text-area/daikin-text-area.js +22 -2
- package/dist/es-dev/components/text-field/daikin-text-field.d.ts +9 -0
- package/dist/es-dev/components/text-field/daikin-text-field.js +97 -51
- package/dist/es-dev/components/text-field/number-utils.d.ts +7 -0
- package/dist/es-dev/components/text-field/number-utils.js +51 -19
- package/dist/es-dev/components/text-masked-field/daikin-text-masked-field.js +31 -7
- package/dist/es-dev/components/time-picker/daikin-time-picker.d.ts +57 -14
- package/dist/es-dev/components/time-picker/daikin-time-picker.js +327 -110
- package/dist/es-dev/components/time-picker/index.js +4 -4
- package/dist/es-dev/components/toast-notification-manager/daikin-toast-notification-manager.js +1 -1
- package/dist/es-dev/components/toggle/daikin-toggle.d.ts +5 -0
- package/dist/es-dev/components/toggle/daikin-toggle.js +110 -35
- package/dist/es-dev/components/tooltip/daikin-tooltip.js +1 -1
- package/dist/es-dev/components/tree-item/daikin-tree-item.d.ts +1 -0
- package/dist/es-dev/components/tree-item/daikin-tree-item.js +24 -8
- package/dist/es-dev/components/tree-section/daikin-tree-section.d.ts +1 -0
- package/dist/es-dev/components/tree-section/daikin-tree-section.js +7 -1
- package/dist/es-dev/components/vertical-navigation/daikin-vertical-navigation.js +1 -1
- package/dist/es-dev/components/vertical-navigation-item/daikin-vertical-navigation-item.d.ts +17 -7
- package/dist/es-dev/components/vertical-navigation-item/daikin-vertical-navigation-item.js +248 -38
- package/dist/es-dev/components/vertical-navigation-menu-item/daikin-vertical-navigation-menu-item.d.ts +6 -1
- package/dist/es-dev/components/vertical-navigation-menu-item/daikin-vertical-navigation-menu-item.js +104 -34
- package/dist/es-dev/controllers/custom-readonly.d.ts +28 -0
- package/dist/es-dev/controllers/custom-readonly.js +59 -0
- package/dist/es-dev/index.js +4 -4
- package/dist/es-dev/tailwind.css.js +1 -1
- package/dist/es-dev/utils/calendar-common.d.ts +1 -1
- package/dist/es-dev/utils/calendar-common.js +6 -2
- package/dist/es-dev/utils/extract-half-width-digits.d.ts +15 -0
- package/dist/es-dev/utils/extract-half-width-digits.js +11 -0
- package/icons/logo-negative.svg +16 -9
- package/icons/logo-positive.svg +16 -9
- package/package.json +6 -5
|
@@ -10,6 +10,8 @@ const ddsFormElement = require("../../base/dds-form-element.cjs");
|
|
|
10
10
|
const ddsProperty = require("../../base/dds-property.cjs");
|
|
11
11
|
const decorators = require("../../base/decorators.cjs");
|
|
12
12
|
require("../../base/define.cjs");
|
|
13
|
+
const clickOutside = require("../../controllers/click-outside.cjs");
|
|
14
|
+
const customReadonly = require("../../controllers/custom-readonly.cjs");
|
|
13
15
|
const floatingUiAutoUpdate = require("../../controllers/floating-ui-auto-update.cjs");
|
|
14
16
|
const tailwind = require("../../tailwind.css.cjs");
|
|
15
17
|
const isSimpleKey = require("../../utils/is-simple-key.cjs");
|
|
@@ -27,16 +29,12 @@ var __decorateClass = (decorators2, target, key, kind) => {
|
|
|
27
29
|
const cvaButton = classVarianceAuthority.cva(
|
|
28
30
|
[
|
|
29
31
|
"flex",
|
|
30
|
-
"justify-between",
|
|
31
32
|
"items-center",
|
|
32
|
-
"gap-
|
|
33
|
+
"gap-(--dds-gap-10)",
|
|
33
34
|
"w-full",
|
|
34
|
-
"h-
|
|
35
|
-
"min-h-12",
|
|
35
|
+
"h-(--dds-input-height)",
|
|
36
36
|
"bg-ddt-color-common-background-default",
|
|
37
|
-
"
|
|
38
|
-
"pl-4",
|
|
39
|
-
"pr-3",
|
|
37
|
+
"px-(--dds-padding-30)",
|
|
40
38
|
"rounded-sm",
|
|
41
39
|
"overflow-hidden",
|
|
42
40
|
"text-left",
|
|
@@ -49,13 +47,7 @@ const cvaButton = classVarianceAuthority.cva(
|
|
|
49
47
|
"focus-visible:-outline-offset-2",
|
|
50
48
|
"enabled:outline-(--color-base)",
|
|
51
49
|
"disabled:text-ddt-color-common-disabled",
|
|
52
|
-
"disabled:outline-ddt-color-common-disabled"
|
|
53
|
-
"after:icon-[daikin--chevron-down]",
|
|
54
|
-
"after:size-6",
|
|
55
|
-
"after:flex-none",
|
|
56
|
-
"after:ml-auto",
|
|
57
|
-
"enabled:after:text-ddt-color-common-text-primary",
|
|
58
|
-
"disabled:after:text-ddt-color-common-disabled"
|
|
50
|
+
"disabled:outline-ddt-color-common-disabled"
|
|
59
51
|
],
|
|
60
52
|
{
|
|
61
53
|
variants: {
|
|
@@ -81,8 +73,41 @@ const cvaButton = classVarianceAuthority.cva(
|
|
|
81
73
|
placeholder: {
|
|
82
74
|
false: ["text-ddt-color-common-text-primary"],
|
|
83
75
|
true: ["text-ddt-color-common-text-secondary"]
|
|
76
|
+
},
|
|
77
|
+
readonly: {
|
|
78
|
+
false: [],
|
|
79
|
+
true: ["cursor-default"]
|
|
80
|
+
},
|
|
81
|
+
disabled: {
|
|
82
|
+
false: [],
|
|
83
|
+
true: []
|
|
84
84
|
}
|
|
85
|
-
}
|
|
85
|
+
},
|
|
86
|
+
compoundVariants: [
|
|
87
|
+
{
|
|
88
|
+
readonly: false,
|
|
89
|
+
class: [
|
|
90
|
+
"after:icon-[daikin--chevron-down]",
|
|
91
|
+
"after:size-(--dds-icon)",
|
|
92
|
+
"after:flex-none",
|
|
93
|
+
"after:ml-auto",
|
|
94
|
+
"enabled:after:text-ddt-color-common-text-primary",
|
|
95
|
+
"disabled:after:text-ddt-color-common-disabled"
|
|
96
|
+
]
|
|
97
|
+
},
|
|
98
|
+
{
|
|
99
|
+
readonly: true,
|
|
100
|
+
disabled: true,
|
|
101
|
+
class: [
|
|
102
|
+
"after:icon-[daikin--chevron-down]",
|
|
103
|
+
"after:size-(--dds-icon)",
|
|
104
|
+
"after:flex-none",
|
|
105
|
+
"after:ml-auto",
|
|
106
|
+
"enabled:after:text-ddt-color-common-text-primary",
|
|
107
|
+
"disabled:after:text-ddt-color-common-disabled"
|
|
108
|
+
]
|
|
109
|
+
}
|
|
110
|
+
]
|
|
86
111
|
}
|
|
87
112
|
);
|
|
88
113
|
const floatingPositionOptions = {
|
|
@@ -104,6 +129,7 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
104
129
|
constructor() {
|
|
105
130
|
super(...arguments);
|
|
106
131
|
this.disabled = false;
|
|
132
|
+
this.readonly = false;
|
|
107
133
|
this.required = false;
|
|
108
134
|
this.error = false;
|
|
109
135
|
this.open = false;
|
|
@@ -113,6 +139,26 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
113
139
|
this._label = null;
|
|
114
140
|
this._initialUpdateCompleted = false;
|
|
115
141
|
this._autoUpdateController = new floatingUiAutoUpdate.FloatingUIAutoUpdateController(this);
|
|
142
|
+
this._readonlyController = new customReadonly.CustomReadonlyController(this, {
|
|
143
|
+
isReadonly: () => this.readonly,
|
|
144
|
+
isDisabled: () => this.disabled,
|
|
145
|
+
blockedKeys: [
|
|
146
|
+
"ArrowUp",
|
|
147
|
+
"ArrowDown",
|
|
148
|
+
"ArrowLeft",
|
|
149
|
+
"ArrowRight",
|
|
150
|
+
"Home",
|
|
151
|
+
"End",
|
|
152
|
+
"PageUp",
|
|
153
|
+
"PageDown",
|
|
154
|
+
"Enter",
|
|
155
|
+
" "
|
|
156
|
+
]
|
|
157
|
+
});
|
|
158
|
+
this._clickOutsideController = new clickOutside.ClickOutsideController(
|
|
159
|
+
this,
|
|
160
|
+
this._onClickOutside
|
|
161
|
+
);
|
|
116
162
|
this._willBeFocusedByPress = false;
|
|
117
163
|
this._lastFocusedItem = null;
|
|
118
164
|
this._dropdownRef = ref_js.createRef();
|
|
@@ -126,6 +172,23 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
126
172
|
}
|
|
127
173
|
);
|
|
128
174
|
}
|
|
175
|
+
get _isMenuOpen() {
|
|
176
|
+
return this.open && !this.disabled && !this.readonly;
|
|
177
|
+
}
|
|
178
|
+
_syncSingleOpenState() {
|
|
179
|
+
const root = this.getRootNode();
|
|
180
|
+
const activeDropdown = exports.DaikinDropdown._activeOpenByRoot.get(root);
|
|
181
|
+
if (this._isMenuOpen) {
|
|
182
|
+
if (activeDropdown && activeDropdown !== this && activeDropdown.open) {
|
|
183
|
+
activeDropdown.open = false;
|
|
184
|
+
}
|
|
185
|
+
exports.DaikinDropdown._activeOpenByRoot.set(root, this);
|
|
186
|
+
return;
|
|
187
|
+
}
|
|
188
|
+
if (activeDropdown === this) {
|
|
189
|
+
exports.DaikinDropdown._activeOpenByRoot.delete(root);
|
|
190
|
+
}
|
|
191
|
+
}
|
|
129
192
|
_searchItem(prefix) {
|
|
130
193
|
const items = this._items.filter(
|
|
131
194
|
(item) => {
|
|
@@ -184,17 +247,29 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
184
247
|
* @param value The value of selected option.
|
|
185
248
|
*/
|
|
186
249
|
_handleSelectOption(value) {
|
|
250
|
+
if (this.disabled || this.readonly) {
|
|
251
|
+
return;
|
|
252
|
+
}
|
|
187
253
|
this.value = value;
|
|
188
254
|
this.selectedOptions = this.multiple ? this.selectedOptions.includes(value) ? this.selectedOptions.filter((option) => option != value) : [...this.selectedOptions, value] : [value];
|
|
189
255
|
this.dispatchEvent(new Event("change"));
|
|
190
256
|
}
|
|
191
257
|
_handleFocusOut(event) {
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
258
|
+
const relatedTarget = event.relatedTarget;
|
|
259
|
+
const movedFocusWithinSelf = !!relatedTarget && (this.contains(relatedTarget) || this.renderRoot.contains(relatedTarget));
|
|
260
|
+
if (movedFocusWithinSelf || this._willBeFocusedByPress) {
|
|
261
|
+
return;
|
|
262
|
+
}
|
|
263
|
+
this._closeDropdownByBlur();
|
|
264
|
+
}
|
|
265
|
+
_closeDropdownByBlur() {
|
|
266
|
+
this.open = false;
|
|
267
|
+
}
|
|
268
|
+
_onClickOutside() {
|
|
269
|
+
if (!this.open || this.disabled || this._willBeFocusedByPress) {
|
|
270
|
+
return;
|
|
197
271
|
}
|
|
272
|
+
this._closeDropdownByBlur();
|
|
198
273
|
}
|
|
199
274
|
/**
|
|
200
275
|
* Removes the last selected option.
|
|
@@ -212,6 +287,15 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
212
287
|
}
|
|
213
288
|
}
|
|
214
289
|
_handleKeyDown(event) {
|
|
290
|
+
if (this.disabled || this.readonly) {
|
|
291
|
+
return;
|
|
292
|
+
}
|
|
293
|
+
if (event.key === "Tab" && event.shiftKey && this.open) {
|
|
294
|
+
event.preventDefault();
|
|
295
|
+
this._closeDropdownByBlur();
|
|
296
|
+
this.focus();
|
|
297
|
+
return;
|
|
298
|
+
}
|
|
215
299
|
if (event.altKey && !event.ctrlKey && !event.metaKey && !event.shiftKey) {
|
|
216
300
|
if (event.key === "ArrowDown") {
|
|
217
301
|
event.preventDefault();
|
|
@@ -278,7 +362,7 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
278
362
|
}
|
|
279
363
|
}
|
|
280
364
|
_handlePointerUp() {
|
|
281
|
-
if (this.disabled) {
|
|
365
|
+
if (this.disabled || this.readonly) {
|
|
282
366
|
return;
|
|
283
367
|
}
|
|
284
368
|
this._willBeFocusedByPress = false;
|
|
@@ -288,7 +372,7 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
288
372
|
if (event.key === "Enter" || event.key === " ") {
|
|
289
373
|
event.preventDefault();
|
|
290
374
|
event.stopPropagation();
|
|
291
|
-
if (this.disabled) {
|
|
375
|
+
if (this.disabled || this.readonly) {
|
|
292
376
|
return;
|
|
293
377
|
}
|
|
294
378
|
this.open = !this.open;
|
|
@@ -319,22 +403,24 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
319
403
|
this._updateItemsSelectable();
|
|
320
404
|
}
|
|
321
405
|
render() {
|
|
322
|
-
const fallbackLabel = this.
|
|
406
|
+
const fallbackLabel = this._isMenuOpen ? "Close dropdown" : this.selectedOptions.length ? `Selected: ${this._selectionLabels.join(", ")}` : this.value ? `Selected: ${this.value}` : "Open dropdown";
|
|
323
407
|
return lit.html`<div class="w-full" @keydown=${this._handleKeyDown}>
|
|
324
408
|
<button
|
|
325
409
|
${ref_js.ref(this._dropdownRef)}
|
|
326
410
|
id="dropdown-button"
|
|
327
411
|
type="button"
|
|
328
412
|
class=${cvaButton({
|
|
329
|
-
open: this.
|
|
413
|
+
open: this._isMenuOpen,
|
|
330
414
|
error: this.error,
|
|
415
|
+
disabled: this.disabled,
|
|
416
|
+
readonly: this.readonly,
|
|
331
417
|
placeholder: !this.selectedOptions.length
|
|
332
418
|
})}
|
|
333
419
|
?disabled=${this.disabled}
|
|
334
420
|
aria-label=${`${this._label ?? ""} ${fallbackLabel}`}
|
|
335
|
-
aria-expanded=${this.
|
|
421
|
+
aria-expanded=${this._isMenuOpen}
|
|
336
422
|
aria-disabled=${this.disabled}
|
|
337
|
-
aria-controls=${this.
|
|
423
|
+
aria-controls=${this._isMenuOpen ? "dropdown-items" : lit.nothing}
|
|
338
424
|
aria-required=${this.required}
|
|
339
425
|
aria-haspopup="listbox"
|
|
340
426
|
@pointerup=${this._handlePointerUp}
|
|
@@ -342,15 +428,20 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
342
428
|
@keydown=${this._handleButtonKeyDown}
|
|
343
429
|
${this._autoUpdateController.refReference()}
|
|
344
430
|
>
|
|
345
|
-
<
|
|
431
|
+
<slot
|
|
432
|
+
name="left-icon"
|
|
433
|
+
class="slotted:shrink-0 size-(--dds-icon) slotted:size-(--dds-icon)"
|
|
434
|
+
></slot>
|
|
435
|
+
<span class="truncate pl-(--dds-space-100)">
|
|
346
436
|
${this.selectedOptions.length ? this.multiple && this.selectedOptions.length > (this.maxLabels ?? 0) ? this.selectedOptions.length === 1 ? `one item selected` : `${this.selectedOptions.length} items selected` : this._selectionLabels.join(", ") : this.placeholder}
|
|
347
437
|
</span>
|
|
348
438
|
</button>
|
|
349
439
|
<div
|
|
350
440
|
id="dropdown-items"
|
|
351
441
|
role="listbox"
|
|
352
|
-
popover
|
|
442
|
+
.popover=${"manual"}
|
|
353
443
|
class="flex flex-col overflow-hidden floating-unready:hidden absolute left-(--floating-x,0) top-(--floating-y,0) min-w-(--floating-width) max-h-50 border border-ddt-color-divider rounded-sm max-w-min"
|
|
444
|
+
tabindex="-1"
|
|
354
445
|
aria-labelledby="dropdown-button"
|
|
355
446
|
@floating-ready=${this._handleFloatingReady}
|
|
356
447
|
${this._autoUpdateController.refFloating()}
|
|
@@ -368,8 +459,10 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
368
459
|
// TODO(DDS-1226): refactor here with CSS Anchor Positioning instead of using floating-ui
|
|
369
460
|
this._autoUpdateController.directive(
|
|
370
461
|
floatingPositionOptions,
|
|
371
|
-
this.
|
|
462
|
+
this._isMenuOpen
|
|
372
463
|
)}
|
|
464
|
+
${// Ensure open dropdown is closed even when focusout/relatedTarget is unreliable across browsers.
|
|
465
|
+
this._clickOutsideController.directive(this._isMenuOpen)}
|
|
373
466
|
</div>`;
|
|
374
467
|
}
|
|
375
468
|
/**
|
|
@@ -390,6 +483,9 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
390
483
|
this._initialUpdateCompleted = true;
|
|
391
484
|
return;
|
|
392
485
|
}
|
|
486
|
+
if ((changedProperties.has("open") || changedProperties.has("readonly")) && this.readonly && this.open) {
|
|
487
|
+
this.open = false;
|
|
488
|
+
}
|
|
393
489
|
const hasChangedValue = changedProperties.has("value");
|
|
394
490
|
const hasChangedSelectedOptions = changedProperties.has("selectedOptions");
|
|
395
491
|
if (hasChangedValue && !hasChangedSelectedOptions) {
|
|
@@ -401,12 +497,18 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
401
497
|
}
|
|
402
498
|
updated(changedProperties) {
|
|
403
499
|
var _a;
|
|
500
|
+
this._readonlyController.setTarget(
|
|
501
|
+
this._button
|
|
502
|
+
);
|
|
503
|
+
if (changedProperties.has("open") || changedProperties.has("disabled") || changedProperties.has("readonly")) {
|
|
504
|
+
this._syncSingleOpenState();
|
|
505
|
+
}
|
|
404
506
|
if (changedProperties.has("value")) {
|
|
405
507
|
this._updateFormValue();
|
|
406
508
|
}
|
|
407
|
-
if (changedProperties.has("open") || changedProperties.has("disabled")) {
|
|
509
|
+
if (changedProperties.has("open") || changedProperties.has("disabled") || changedProperties.has("readonly")) {
|
|
408
510
|
(_a = this._autoUpdateController.floatingElement) == null ? void 0 : _a.togglePopover(
|
|
409
|
-
this.
|
|
511
|
+
this._isMenuOpen
|
|
410
512
|
);
|
|
411
513
|
if (changedProperties.get("open") && !this.open && !this.disabled) {
|
|
412
514
|
this.focus();
|
|
@@ -414,7 +516,7 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
414
516
|
}
|
|
415
517
|
if (changedProperties.has("open")) {
|
|
416
518
|
const wasOpen = changedProperties.get("open");
|
|
417
|
-
if (wasOpen !== void 0) {
|
|
519
|
+
if (wasOpen !== void 0 && wasOpen !== this.open) {
|
|
418
520
|
this.dispatchEvent(
|
|
419
521
|
new ToggleEvent("toggle", {
|
|
420
522
|
oldState: wasOpen ? "open" : "closed",
|
|
@@ -433,6 +535,10 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
433
535
|
this._updateItemsSelectable();
|
|
434
536
|
}
|
|
435
537
|
}
|
|
538
|
+
disconnectedCallback() {
|
|
539
|
+
this._syncSingleOpenState();
|
|
540
|
+
super.disconnectedCallback();
|
|
541
|
+
}
|
|
436
542
|
/**
|
|
437
543
|
* This method is used by `daikin-input-group` to reflect it's attributes to this component.
|
|
438
544
|
* @private
|
|
@@ -440,11 +546,13 @@ exports.DaikinDropdown = class DaikinDropdown extends ddsFormElement.DDSFormElem
|
|
|
440
546
|
reflectInputGroup(inputGroup) {
|
|
441
547
|
const isError = !inputGroup.disabled && !!inputGroup.error;
|
|
442
548
|
this.disabled = !!inputGroup.disabled;
|
|
549
|
+
this.readonly = !!inputGroup.readonly;
|
|
443
550
|
this.required = !!inputGroup.required;
|
|
444
551
|
this.error = isError;
|
|
445
552
|
this._label = inputGroup.label;
|
|
446
553
|
}
|
|
447
554
|
};
|
|
555
|
+
exports.DaikinDropdown._activeOpenByRoot = /* @__PURE__ */ new WeakMap();
|
|
448
556
|
exports.DaikinDropdown.styles = lit.css`
|
|
449
557
|
${lit.unsafeCSS(tailwind.default)}
|
|
450
558
|
|
|
@@ -453,6 +561,27 @@ exports.DaikinDropdown.styles = lit.css`
|
|
|
453
561
|
width: 100%;
|
|
454
562
|
}
|
|
455
563
|
|
|
564
|
+
:host([readonly]:not([disabled])) button {
|
|
565
|
+
--color-base: var(--dds-color-common-surface-secondary);
|
|
566
|
+
background-color: var(--dds-color-common-surface-secondary);
|
|
567
|
+
}
|
|
568
|
+
|
|
569
|
+
:host([readonly]:not([disabled])) button:hover,
|
|
570
|
+
:host([readonly]:not([disabled])) button:active {
|
|
571
|
+
--color-base: var(--dds-color-common-surface-secondary);
|
|
572
|
+
background-color: var(--dds-color-common-surface-secondary);
|
|
573
|
+
}
|
|
574
|
+
|
|
575
|
+
:host([readonly]:not([disabled])) button:focus-visible {
|
|
576
|
+
--color-base: var(--dds-color-common-border-focus);
|
|
577
|
+
}
|
|
578
|
+
|
|
579
|
+
:host([readonly][error]:not([disabled])) button,
|
|
580
|
+
:host([readonly][error]:not([disabled])) button:hover,
|
|
581
|
+
:host([readonly][error]:not([disabled])) button:active {
|
|
582
|
+
--color-base: var(--dds-color-common-danger-default);
|
|
583
|
+
}
|
|
584
|
+
|
|
456
585
|
::slotted {
|
|
457
586
|
width: 100%;
|
|
458
587
|
}
|
|
@@ -463,6 +592,9 @@ __decorateClass([
|
|
|
463
592
|
__decorateClass([
|
|
464
593
|
ddsProperty.property({ type: Boolean, reflect: true })
|
|
465
594
|
], exports.DaikinDropdown.prototype, "disabled", 2);
|
|
595
|
+
__decorateClass([
|
|
596
|
+
ddsProperty.property({ type: Boolean, reflect: true })
|
|
597
|
+
], exports.DaikinDropdown.prototype, "readonly", 2);
|
|
466
598
|
__decorateClass([
|
|
467
599
|
ddsProperty.property({ type: Boolean, reflect: true })
|
|
468
600
|
], exports.DaikinDropdown.prototype, "required", 2);
|
|
@@ -19,6 +19,7 @@ import { DaikinInputGroup } from "../input-group/index.cjs";
|
|
|
19
19
|
* @fires toggle - A custom event emitted when the dropdown menu opens or closes.
|
|
20
20
|
*
|
|
21
21
|
* @slot - Dropdown item list slot. Place `daikin-dropdown-item` elements here.
|
|
22
|
+
* @slot left-icon - A slot for an icon to be placed to the left of the text. Place `daikin-icon` or something similar.
|
|
22
23
|
*
|
|
23
24
|
* @example
|
|
24
25
|
*
|
|
@@ -36,6 +37,7 @@ import { DaikinInputGroup } from "../input-group/index.cjs";
|
|
|
36
37
|
* ```
|
|
37
38
|
*/
|
|
38
39
|
export declare class DaikinDropdown extends DDSFormElement {
|
|
40
|
+
private static _activeOpenByRoot;
|
|
39
41
|
static readonly styles: import('lit').CSSResult;
|
|
40
42
|
/**
|
|
41
43
|
* Placeholder text of the dropdown.
|
|
@@ -45,6 +47,10 @@ export declare class DaikinDropdown extends DDSFormElement {
|
|
|
45
47
|
* Whether the dropdown is disabled.
|
|
46
48
|
*/
|
|
47
49
|
disabled: boolean;
|
|
50
|
+
/**
|
|
51
|
+
* Whether the dropdown is readonly.
|
|
52
|
+
*/
|
|
53
|
+
readonly: boolean;
|
|
48
54
|
/**
|
|
49
55
|
* Whether the dropdown is required.
|
|
50
56
|
*/
|
|
@@ -84,6 +90,8 @@ export declare class DaikinDropdown extends DDSFormElement {
|
|
|
84
90
|
private get _selectionLabels();
|
|
85
91
|
private _initialUpdateCompleted;
|
|
86
92
|
private _autoUpdateController;
|
|
93
|
+
private readonly _readonlyController;
|
|
94
|
+
private _clickOutsideController;
|
|
87
95
|
private _willBeFocusedByPress;
|
|
88
96
|
/**
|
|
89
97
|
* Last focused dropdown item.
|
|
@@ -91,6 +99,8 @@ export declare class DaikinDropdown extends DDSFormElement {
|
|
|
91
99
|
*/
|
|
92
100
|
private _lastFocusedItem;
|
|
93
101
|
private _dropdownRef;
|
|
102
|
+
private get _isMenuOpen();
|
|
103
|
+
private _syncSingleOpenState;
|
|
94
104
|
private _searchItem;
|
|
95
105
|
private _moveFocus;
|
|
96
106
|
private _updateFormValue;
|
|
@@ -106,6 +116,8 @@ export declare class DaikinDropdown extends DDSFormElement {
|
|
|
106
116
|
*/
|
|
107
117
|
private _handleSelectOption;
|
|
108
118
|
private _handleFocusOut;
|
|
119
|
+
private _closeDropdownByBlur;
|
|
120
|
+
private _onClickOutside;
|
|
109
121
|
/**
|
|
110
122
|
* Removes the last selected option.
|
|
111
123
|
*
|
|
@@ -141,6 +153,7 @@ export declare class DaikinDropdown extends DDSFormElement {
|
|
|
141
153
|
focus(options?: FocusOptions): void;
|
|
142
154
|
protected willUpdate(changedProperties: PropertyValues): void;
|
|
143
155
|
protected updated(changedProperties: PropertyValues<this>): void;
|
|
156
|
+
disconnectedCallback(): void;
|
|
144
157
|
/**
|
|
145
158
|
* This method is used by `daikin-input-group` to reflect it's attributes to this component.
|
|
146
159
|
* @private
|
|
@@ -27,8 +27,8 @@ const cvaOption = classVarianceAuthority.cva(
|
|
|
27
27
|
"items-center",
|
|
28
28
|
"gap-1",
|
|
29
29
|
"size-full",
|
|
30
|
-
"min-h-12",
|
|
31
30
|
"text-left",
|
|
31
|
+
"text-(length:--dds-font-size-label-text)",
|
|
32
32
|
"relative",
|
|
33
33
|
"focus-visible:outline-solid",
|
|
34
34
|
"focus-visible:outline-2",
|
|
@@ -48,7 +48,7 @@ const cvaOption = classVarianceAuthority.cva(
|
|
|
48
48
|
"hover:[--color-primary:var(--dds-color-common-surface-selected-hover)]",
|
|
49
49
|
"active:[--color-primary:var(--dds-color-common-surface-selected-press)]",
|
|
50
50
|
"after:icon-[daikin--dropdown-check]",
|
|
51
|
-
"after:size-
|
|
51
|
+
"after:size-(--dds-icon)",
|
|
52
52
|
"after:flex-none"
|
|
53
53
|
]
|
|
54
54
|
},
|
|
@@ -64,8 +64,13 @@ const cvaOption = classVarianceAuthority.cva(
|
|
|
64
64
|
]
|
|
65
65
|
},
|
|
66
66
|
multiple: {
|
|
67
|
-
false: ["justify-between", "p-
|
|
68
|
-
true: [
|
|
67
|
+
false: ["justify-between", "p-(--dds-padding-30)"],
|
|
68
|
+
true: [
|
|
69
|
+
"after:hidden",
|
|
70
|
+
"py-(--dds-padding-20)",
|
|
71
|
+
"pl-(--dds-padding-20)",
|
|
72
|
+
"pr-(--dds-padding-30)"
|
|
73
|
+
]
|
|
69
74
|
}
|
|
70
75
|
}
|
|
71
76
|
}
|
|
@@ -122,7 +127,7 @@ exports.DaikinDropdownItem = class DaikinDropdownItem extends ddsElement.DDSElem
|
|
|
122
127
|
@mousedown=${this._handleMousedown}
|
|
123
128
|
>
|
|
124
129
|
<daikin-checkbox
|
|
125
|
-
class="size-full part-label:
|
|
130
|
+
class="size-full part-label:cursor-pointer"
|
|
126
131
|
check-state=${this.selected ? "checked" : "unchecked"}
|
|
127
132
|
tabindex="-1"
|
|
128
133
|
?disabled=${this.disabled}
|
|
@@ -140,7 +145,9 @@ exports.DaikinDropdownItem = class DaikinDropdownItem extends ddsElement.DDSElem
|
|
|
140
145
|
?disabled=${this.disabled}
|
|
141
146
|
@click=${this._handleClick}
|
|
142
147
|
>
|
|
143
|
-
<
|
|
148
|
+
<span class="mt-[0.09375rem] mb-[0.09375rem]">
|
|
149
|
+
<slot></slot>
|
|
150
|
+
</span>
|
|
144
151
|
</button>`;
|
|
145
152
|
}
|
|
146
153
|
/**
|
|
@@ -160,6 +160,7 @@ exports.DaikinIconButton = class DaikinIconButton extends ddsFormElement.DDSForm
|
|
|
160
160
|
if (this.type === "link") {
|
|
161
161
|
const linkDisabled = this.disabled || this.href == null;
|
|
162
162
|
return lit.html`<a
|
|
163
|
+
part="icon-button"
|
|
163
164
|
class=${iconButtonCN}
|
|
164
165
|
href=${ifDefined_js.ifDefined(!linkDisabled ? this.href ?? void 0 : void 0)}
|
|
165
166
|
tabindex=${ifDefined_js.ifDefined(this.getBackingProperty("buttonTabIndex"))}
|
|
@@ -174,6 +175,7 @@ exports.DaikinIconButton = class DaikinIconButton extends ddsFormElement.DDSForm
|
|
|
174
175
|
}
|
|
175
176
|
return lit.html`
|
|
176
177
|
<button
|
|
178
|
+
part="icon-button"
|
|
177
179
|
class=${iconButtonCN}
|
|
178
180
|
type=${this.type}
|
|
179
181
|
tabindex=${ifDefined_js.ifDefined(this.getBackingProperty("buttonTabIndex"))}
|
|
@@ -22,6 +22,8 @@ type IconButtonVariantProps = MergeVariantProps<typeof cvaIconButton>;
|
|
|
22
22
|
*
|
|
23
23
|
* @slot - A slot for an icon. Place a daikin-icon element or something similar.
|
|
24
24
|
*
|
|
25
|
+
* @csspart icon-button - CSS styles applied to the `icon-button` part target the internal `<button>` element.
|
|
26
|
+
*
|
|
25
27
|
* @example
|
|
26
28
|
*
|
|
27
29
|
* ```js
|
|
@@ -315,13 +315,13 @@ Object.defineProperty(exports, "DaikinTimePicker", {
|
|
|
315
315
|
exports.calcDigitInput = daikinTimePicker.calcDigitInput;
|
|
316
316
|
exports.formatPartsForUI = daikinTimePicker.formatPartsForUI;
|
|
317
317
|
exports.formatTimeForUI = daikinTimePicker.formatTimeForUI;
|
|
318
|
-
exports.from24HourFormat = daikinTimePicker.from24HourFormat;
|
|
319
318
|
exports.getTimeItemInSelection = daikinTimePicker.getTimeItemInSelection;
|
|
320
319
|
exports.isTimeOutOfRange = daikinTimePicker.isTimeOutOfRange;
|
|
321
320
|
exports.isValidValueTime = daikinTimePicker.isValidValueTime;
|
|
322
321
|
exports.parsePartsFromUIValue = daikinTimePicker.parsePartsFromUIValue;
|
|
323
|
-
exports.
|
|
322
|
+
exports.timeValueToUI = daikinTimePicker.timeValueToUI;
|
|
324
323
|
exports.tryParseTimeFromUIValue = daikinTimePicker.tryParseTimeFromUIValue;
|
|
324
|
+
exports.uiToTimeValue = daikinTimePicker.uiToTimeValue;
|
|
325
325
|
Object.defineProperty(exports, "DaikinToastNotification", {
|
|
326
326
|
enumerable: true,
|
|
327
327
|
get: () => daikinToastNotification.DaikinToastNotification
|