@daikin-oss/design-system-web-components 0.7.0 → 1.0.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/CHANGELOG.md +109 -12
- package/README.md +2 -2
- package/dist/cjs/base/dds-element.cjs +8 -0
- package/dist/cjs/base/dds-element.d.cts +4 -0
- package/dist/cjs/base/decorators.cjs +13 -0
- package/dist/cjs/base/decorators.d.cts +2 -0
- package/dist/cjs/base/define.cjs +18 -0
- package/dist/cjs/base/define.d.cts +1 -0
- package/dist/cjs/base/index.cjs +8 -0
- package/dist/cjs/base/index.d.cts +3 -0
- package/dist/cjs/components/accordion/daikin-accordion.cjs +39 -6
- package/dist/cjs/components/accordion/daikin-accordion.d.cts +15 -2
- package/dist/cjs/components/accordion-item/daikin-accordion-item.cjs +37 -77
- package/dist/cjs/components/accordion-item/daikin-accordion-item.d.cts +10 -16
- package/dist/cjs/components/breadcrumb/daikin-breadcrumb.cjs +8 -5
- package/dist/cjs/components/breadcrumb/daikin-breadcrumb.d.cts +2 -2
- package/dist/cjs/components/breadcrumb-item/daikin-breadcrumb-item.cjs +8 -5
- package/dist/cjs/components/breadcrumb-item/daikin-breadcrumb-item.d.cts +2 -2
- package/dist/cjs/components/button/daikin-button.cjs +20 -8
- package/dist/cjs/components/button/daikin-button.d.cts +6 -3
- package/dist/cjs/components/card/daikin-card.cjs +11 -7
- package/dist/cjs/components/card/daikin-card.d.cts +8 -2
- package/dist/cjs/components/card-footer/daikin-card-footer.cjs +9 -9
- package/dist/cjs/components/card-footer/daikin-card-footer.d.cts +6 -2
- package/dist/cjs/components/card-header/daikin-card-header.cjs +10 -10
- package/dist/cjs/components/card-header/daikin-card-header.d.cts +6 -2
- package/dist/cjs/components/carousel/daikin-carousel.cjs +217 -0
- package/dist/cjs/components/carousel/daikin-carousel.d.cts +56 -0
- package/dist/cjs/components/carousel/index.cjs +7 -0
- package/dist/cjs/components/carousel/index.d.cts +1 -0
- package/dist/cjs/components/carousel-item/daikin-carousel-item.cjs +80 -0
- package/dist/cjs/components/carousel-item/daikin-carousel-item.d.cts +50 -0
- package/dist/cjs/components/carousel-item/index.cjs +7 -0
- package/dist/cjs/components/carousel-item/index.d.cts +1 -0
- package/dist/cjs/components/checkbox/daikin-checkbox.cjs +34 -16
- package/dist/cjs/components/checkbox/daikin-checkbox.d.cts +4 -2
- package/dist/cjs/components/dropdown/daikin-dropdown.cjs +16 -5
- package/dist/cjs/components/dropdown/daikin-dropdown.d.cts +16 -2
- package/dist/cjs/components/dropdown-item/daikin-dropdown-item.cjs +12 -5
- package/dist/cjs/components/dropdown-item/daikin-dropdown-item.d.cts +10 -2
- package/dist/cjs/components/icon/daikin-icon.cjs +8 -5
- package/dist/cjs/components/icon/daikin-icon.d.cts +2 -2
- package/dist/cjs/components/icon/icons.json.cjs +1 -70
- package/dist/cjs/components/icon/icons.json.d.cts +0 -8
- package/dist/cjs/components/icon-button/daikin-icon-button.cjs +8 -5
- package/dist/cjs/components/icon-button/daikin-icon-button.d.cts +2 -2
- package/dist/cjs/components/index.cjs +25 -5
- package/dist/cjs/components/index.d.cts +5 -1
- package/dist/cjs/components/inline-notification/daikin-inline-notification.cjs +92 -0
- package/dist/cjs/components/inline-notification/daikin-inline-notification.d.cts +55 -0
- package/dist/cjs/components/inline-notification/index.cjs +7 -0
- package/dist/cjs/components/inline-notification/index.d.cts +1 -0
- package/dist/cjs/components/input-group/daikin-input-group.cjs +12 -9
- package/dist/cjs/components/input-group/daikin-input-group.d.cts +15 -7
- package/dist/cjs/components/link/daikin-link.cjs +9 -6
- package/dist/cjs/components/link/daikin-link.d.cts +2 -2
- package/dist/cjs/components/list/daikin-list.cjs +9 -9
- package/dist/cjs/components/list/daikin-list.d.cts +7 -2
- package/dist/cjs/components/list-item/daikin-list-item.cjs +8 -5
- package/dist/cjs/components/list-item/daikin-list-item.d.cts +6 -2
- package/dist/cjs/components/pagination/daikin-pagination.cjs +22 -13
- package/dist/cjs/components/pagination/daikin-pagination.d.cts +6 -2
- package/dist/cjs/components/progress-bar/daikin-progress-bar.cjs +13 -8
- package/dist/cjs/components/progress-bar/daikin-progress-bar.d.cts +3 -2
- package/dist/cjs/components/progress-indicator/daikin-progress-indicator.cjs +16 -20
- package/dist/cjs/components/progress-indicator/daikin-progress-indicator.d.cts +12 -5
- package/dist/cjs/components/progress-indicator-item/daikin-progress-indicator-item.cjs +24 -25
- package/dist/cjs/components/progress-indicator-item/daikin-progress-indicator-item.d.cts +8 -4
- package/dist/cjs/components/radio/daikin-radio.cjs +45 -23
- package/dist/cjs/components/radio/daikin-radio.d.cts +18 -8
- package/dist/cjs/components/radio-group/daikin-radio-group.cjs +31 -11
- package/dist/cjs/components/radio-group/daikin-radio-group.d.cts +20 -14
- package/dist/cjs/components/select/daikin-select.cjs +15 -6
- package/dist/cjs/components/select/daikin-select.d.cts +11 -2
- package/dist/cjs/components/tab/daikin-tab.cjs +25 -10
- package/dist/cjs/components/tab/daikin-tab.d.cts +7 -2
- package/dist/cjs/components/tab-panels/daikin-tab-panels.cjs +9 -7
- package/dist/cjs/components/tab-panels/daikin-tab-panels.d.cts +2 -2
- package/dist/cjs/components/table/daikin-table.cjs +9 -6
- package/dist/cjs/components/table/daikin-table.d.cts +9 -2
- package/dist/cjs/components/table-cell/daikin-table-cell.cjs +8 -5
- package/dist/cjs/components/table-cell/daikin-table-cell.d.cts +6 -2
- package/dist/cjs/components/table-header-cell/daikin-table-header-cell.cjs +8 -5
- package/dist/cjs/components/table-header-cell/daikin-table-header-cell.d.cts +6 -2
- package/dist/cjs/components/tabs/daikin-tabs.cjs +25 -10
- package/dist/cjs/components/tabs/daikin-tabs.d.cts +8 -2
- package/dist/cjs/components/text-area/daikin-text-area.cjs +16 -7
- package/dist/cjs/components/text-area/daikin-text-area.d.cts +7 -2
- package/dist/cjs/components/text-field/daikin-text-field.cjs +16 -7
- package/dist/cjs/components/text-field/daikin-text-field.d.cts +7 -2
- package/dist/cjs/components/toast-notification/daikin-toast-notification.cjs +94 -0
- package/dist/cjs/components/toast-notification/daikin-toast-notification.d.cts +69 -0
- package/dist/cjs/components/toast-notification/index.cjs +7 -0
- package/dist/cjs/components/toast-notification/index.d.cts +1 -0
- package/dist/cjs/components/toast-notification-manager/daikin-toast-notification-manager.cjs +192 -0
- package/dist/cjs/components/toast-notification-manager/daikin-toast-notification-manager.d.cts +67 -0
- package/dist/cjs/components/toast-notification-manager/index.cjs +7 -0
- package/dist/cjs/components/toast-notification-manager/index.d.cts +1 -0
- package/dist/cjs/components/toggle/daikin-toggle.cjs +8 -5
- package/dist/cjs/components/toggle/daikin-toggle.d.cts +3 -2
- package/dist/cjs/components/tooltip/daikin-tooltip.cjs +42 -30
- package/dist/cjs/components/tooltip/daikin-tooltip.d.cts +16 -6
- package/dist/cjs/components/tree/daikin-tree.cjs +36 -37
- package/dist/cjs/components/tree/daikin-tree.d.cts +13 -14
- package/dist/cjs/components/tree-item/daikin-tree-item.cjs +22 -18
- package/dist/cjs/components/tree-item/daikin-tree-item.d.cts +9 -9
- package/dist/cjs/components/tree-section/daikin-tree-section.cjs +26 -41
- package/dist/cjs/components/tree-section/daikin-tree-section.d.cts +10 -20
- package/dist/cjs/controllers/click-outside.d.cts +1 -1
- package/dist/cjs/index.cjs +25 -5
- package/dist/cjs/tailwind.css.cjs +1 -1
- package/dist/cjs/utils/notification-common.cjs +121 -0
- package/dist/cjs/utils/notification-common.d.cts +19 -0
- package/dist/cjs-dev/base/dds-element.cjs +8 -0
- package/dist/cjs-dev/base/dds-element.d.cts +4 -0
- package/dist/cjs-dev/base/decorators.cjs +13 -0
- package/dist/cjs-dev/base/decorators.d.cts +2 -0
- package/dist/cjs-dev/base/define.cjs +18 -0
- package/dist/cjs-dev/base/define.d.cts +1 -0
- package/dist/cjs-dev/base/index.cjs +8 -0
- package/dist/cjs-dev/base/index.d.cts +3 -0
- package/dist/cjs-dev/components/accordion/daikin-accordion.cjs +46 -6
- package/dist/cjs-dev/components/accordion/daikin-accordion.d.cts +15 -2
- package/dist/cjs-dev/components/accordion-item/daikin-accordion-item.cjs +37 -77
- package/dist/cjs-dev/components/accordion-item/daikin-accordion-item.d.cts +10 -16
- package/dist/cjs-dev/components/breadcrumb/daikin-breadcrumb.cjs +8 -5
- package/dist/cjs-dev/components/breadcrumb/daikin-breadcrumb.d.cts +2 -2
- package/dist/cjs-dev/components/breadcrumb-item/daikin-breadcrumb-item.cjs +8 -5
- package/dist/cjs-dev/components/breadcrumb-item/daikin-breadcrumb-item.d.cts +2 -2
- package/dist/cjs-dev/components/button/daikin-button.cjs +20 -8
- package/dist/cjs-dev/components/button/daikin-button.d.cts +6 -3
- package/dist/cjs-dev/components/card/daikin-card.cjs +11 -7
- package/dist/cjs-dev/components/card/daikin-card.d.cts +8 -2
- package/dist/cjs-dev/components/card-footer/daikin-card-footer.cjs +9 -9
- package/dist/cjs-dev/components/card-footer/daikin-card-footer.d.cts +6 -2
- package/dist/cjs-dev/components/card-header/daikin-card-header.cjs +10 -10
- package/dist/cjs-dev/components/card-header/daikin-card-header.d.cts +6 -2
- package/dist/cjs-dev/components/carousel/daikin-carousel.cjs +227 -0
- package/dist/cjs-dev/components/carousel/daikin-carousel.d.cts +56 -0
- package/dist/cjs-dev/components/carousel/index.cjs +7 -0
- package/dist/cjs-dev/components/carousel/index.d.cts +1 -0
- package/dist/cjs-dev/components/carousel-item/daikin-carousel-item.cjs +80 -0
- package/dist/cjs-dev/components/carousel-item/daikin-carousel-item.d.cts +50 -0
- package/dist/cjs-dev/components/carousel-item/index.cjs +7 -0
- package/dist/cjs-dev/components/carousel-item/index.d.cts +1 -0
- package/dist/cjs-dev/components/checkbox/daikin-checkbox.cjs +34 -16
- package/dist/cjs-dev/components/checkbox/daikin-checkbox.d.cts +4 -2
- package/dist/cjs-dev/components/dropdown/daikin-dropdown.cjs +16 -5
- package/dist/cjs-dev/components/dropdown/daikin-dropdown.d.cts +16 -2
- package/dist/cjs-dev/components/dropdown-item/daikin-dropdown-item.cjs +12 -5
- package/dist/cjs-dev/components/dropdown-item/daikin-dropdown-item.d.cts +10 -2
- package/dist/cjs-dev/components/icon/daikin-icon.cjs +8 -5
- package/dist/cjs-dev/components/icon/daikin-icon.d.cts +2 -2
- package/dist/cjs-dev/components/icon/icons.json.cjs +1 -70
- package/dist/cjs-dev/components/icon/icons.json.d.cts +0 -8
- package/dist/cjs-dev/components/icon-button/daikin-icon-button.cjs +8 -5
- package/dist/cjs-dev/components/icon-button/daikin-icon-button.d.cts +2 -2
- package/dist/cjs-dev/components/index.cjs +25 -5
- package/dist/cjs-dev/components/index.d.cts +5 -1
- package/dist/cjs-dev/components/inline-notification/daikin-inline-notification.cjs +92 -0
- package/dist/cjs-dev/components/inline-notification/daikin-inline-notification.d.cts +55 -0
- package/dist/cjs-dev/components/inline-notification/index.cjs +7 -0
- package/dist/cjs-dev/components/inline-notification/index.d.cts +1 -0
- package/dist/cjs-dev/components/input-group/daikin-input-group.cjs +12 -9
- package/dist/cjs-dev/components/input-group/daikin-input-group.d.cts +15 -7
- package/dist/cjs-dev/components/link/daikin-link.cjs +9 -6
- package/dist/cjs-dev/components/link/daikin-link.d.cts +2 -2
- package/dist/cjs-dev/components/list/daikin-list.cjs +9 -9
- package/dist/cjs-dev/components/list/daikin-list.d.cts +7 -2
- package/dist/cjs-dev/components/list-item/daikin-list-item.cjs +8 -5
- package/dist/cjs-dev/components/list-item/daikin-list-item.d.cts +6 -2
- package/dist/cjs-dev/components/pagination/daikin-pagination.cjs +22 -13
- package/dist/cjs-dev/components/pagination/daikin-pagination.d.cts +6 -2
- package/dist/cjs-dev/components/progress-bar/daikin-progress-bar.cjs +13 -8
- package/dist/cjs-dev/components/progress-bar/daikin-progress-bar.d.cts +3 -2
- package/dist/cjs-dev/components/progress-indicator/daikin-progress-indicator.cjs +16 -30
- package/dist/cjs-dev/components/progress-indicator/daikin-progress-indicator.d.cts +12 -5
- package/dist/cjs-dev/components/progress-indicator-item/daikin-progress-indicator-item.cjs +24 -25
- package/dist/cjs-dev/components/progress-indicator-item/daikin-progress-indicator-item.d.cts +8 -4
- package/dist/cjs-dev/components/radio/daikin-radio.cjs +45 -23
- package/dist/cjs-dev/components/radio/daikin-radio.d.cts +18 -8
- package/dist/cjs-dev/components/radio-group/daikin-radio-group.cjs +31 -11
- package/dist/cjs-dev/components/radio-group/daikin-radio-group.d.cts +20 -14
- package/dist/cjs-dev/components/select/daikin-select.cjs +15 -6
- package/dist/cjs-dev/components/select/daikin-select.d.cts +11 -2
- package/dist/cjs-dev/components/tab/daikin-tab.cjs +25 -10
- package/dist/cjs-dev/components/tab/daikin-tab.d.cts +7 -2
- package/dist/cjs-dev/components/tab-panels/daikin-tab-panels.cjs +9 -7
- package/dist/cjs-dev/components/tab-panels/daikin-tab-panels.d.cts +2 -2
- package/dist/cjs-dev/components/table/daikin-table.cjs +9 -6
- package/dist/cjs-dev/components/table/daikin-table.d.cts +9 -2
- package/dist/cjs-dev/components/table-cell/daikin-table-cell.cjs +8 -5
- package/dist/cjs-dev/components/table-cell/daikin-table-cell.d.cts +6 -2
- package/dist/cjs-dev/components/table-header-cell/daikin-table-header-cell.cjs +8 -5
- package/dist/cjs-dev/components/table-header-cell/daikin-table-header-cell.d.cts +6 -2
- package/dist/cjs-dev/components/tabs/daikin-tabs.cjs +25 -10
- package/dist/cjs-dev/components/tabs/daikin-tabs.d.cts +8 -2
- package/dist/cjs-dev/components/text-area/daikin-text-area.cjs +16 -7
- package/dist/cjs-dev/components/text-area/daikin-text-area.d.cts +7 -2
- package/dist/cjs-dev/components/text-field/daikin-text-field.cjs +16 -7
- package/dist/cjs-dev/components/text-field/daikin-text-field.d.cts +7 -2
- package/dist/cjs-dev/components/toast-notification/daikin-toast-notification.cjs +94 -0
- package/dist/cjs-dev/components/toast-notification/daikin-toast-notification.d.cts +69 -0
- package/dist/cjs-dev/components/toast-notification/index.cjs +7 -0
- package/dist/cjs-dev/components/toast-notification/index.d.cts +1 -0
- package/dist/cjs-dev/components/toast-notification-manager/daikin-toast-notification-manager.cjs +192 -0
- package/dist/cjs-dev/components/toast-notification-manager/daikin-toast-notification-manager.d.cts +67 -0
- package/dist/cjs-dev/components/toast-notification-manager/index.cjs +7 -0
- package/dist/cjs-dev/components/toast-notification-manager/index.d.cts +1 -0
- package/dist/cjs-dev/components/toggle/daikin-toggle.cjs +8 -5
- package/dist/cjs-dev/components/toggle/daikin-toggle.d.cts +3 -2
- package/dist/cjs-dev/components/tooltip/daikin-tooltip.cjs +42 -30
- package/dist/cjs-dev/components/tooltip/daikin-tooltip.d.cts +16 -6
- package/dist/cjs-dev/components/tree/daikin-tree.cjs +36 -37
- package/dist/cjs-dev/components/tree/daikin-tree.d.cts +13 -14
- package/dist/cjs-dev/components/tree-item/daikin-tree-item.cjs +22 -18
- package/dist/cjs-dev/components/tree-item/daikin-tree-item.d.cts +9 -9
- package/dist/cjs-dev/components/tree-section/daikin-tree-section.cjs +26 -41
- package/dist/cjs-dev/components/tree-section/daikin-tree-section.d.cts +10 -20
- package/dist/cjs-dev/controllers/click-outside.d.cts +1 -1
- package/dist/cjs-dev/index.cjs +25 -5
- package/dist/cjs-dev/tailwind.css.cjs +1 -1
- package/dist/cjs-dev/utils/notification-common.cjs +124 -0
- package/dist/cjs-dev/utils/notification-common.d.cts +19 -0
- package/dist/es/base/dds-element.d.ts +4 -0
- package/dist/es/base/dds-element.js +8 -0
- package/dist/es/base/decorators.d.ts +2 -0
- package/dist/es/base/decorators.js +13 -0
- package/dist/es/base/define.d.ts +1 -0
- package/dist/es/base/define.js +18 -0
- package/dist/es/base/index.d.ts +3 -0
- package/dist/es/base/index.js +8 -0
- package/dist/es/components/accordion/daikin-accordion.d.ts +15 -2
- package/dist/es/components/accordion/daikin-accordion.js +38 -5
- package/dist/es/components/accordion-item/daikin-accordion-item.d.ts +10 -16
- package/dist/es/components/accordion-item/daikin-accordion-item.js +36 -76
- package/dist/es/components/breadcrumb/daikin-breadcrumb.d.ts +2 -2
- package/dist/es/components/breadcrumb/daikin-breadcrumb.js +7 -4
- package/dist/es/components/breadcrumb-item/daikin-breadcrumb-item.d.ts +2 -2
- package/dist/es/components/breadcrumb-item/daikin-breadcrumb-item.js +7 -4
- package/dist/es/components/button/daikin-button.d.ts +6 -3
- package/dist/es/components/button/daikin-button.js +19 -7
- package/dist/es/components/card/daikin-card.d.ts +8 -2
- package/dist/es/components/card/daikin-card.js +10 -6
- package/dist/es/components/card-footer/daikin-card-footer.d.ts +6 -2
- package/dist/es/components/card-footer/daikin-card-footer.js +7 -7
- package/dist/es/components/card-header/daikin-card-header.d.ts +6 -2
- package/dist/es/components/card-header/daikin-card-header.js +8 -8
- package/dist/es/components/carousel/daikin-carousel.d.ts +56 -0
- package/dist/es/components/carousel/daikin-carousel.js +218 -0
- package/dist/es/components/carousel/index.d.ts +1 -0
- package/dist/es/components/carousel/index.js +4 -0
- package/dist/es/components/carousel-item/daikin-carousel-item.d.ts +50 -0
- package/dist/es/components/carousel-item/daikin-carousel-item.js +81 -0
- package/dist/es/components/carousel-item/index.d.ts +1 -0
- package/dist/es/components/carousel-item/index.js +4 -0
- package/dist/es/components/checkbox/daikin-checkbox.d.ts +4 -2
- package/dist/es/components/checkbox/daikin-checkbox.js +33 -15
- package/dist/es/components/dropdown/daikin-dropdown.d.ts +16 -2
- package/dist/es/components/dropdown/daikin-dropdown.js +15 -4
- package/dist/es/components/dropdown-item/daikin-dropdown-item.d.ts +10 -2
- package/dist/es/components/dropdown-item/daikin-dropdown-item.js +11 -4
- package/dist/es/components/icon/daikin-icon.d.ts +2 -2
- package/dist/es/components/icon/daikin-icon.js +7 -4
- package/dist/es/components/icon/icons.json.d.ts +0 -8
- package/dist/es/components/icon/icons.json.js +1 -70
- package/dist/es/components/icon-button/daikin-icon-button.d.ts +2 -2
- package/dist/es/components/icon-button/daikin-icon-button.js +7 -4
- package/dist/es/components/index.d.ts +5 -1
- package/dist/es/components/index.js +10 -2
- package/dist/es/components/inline-notification/daikin-inline-notification.d.ts +55 -0
- package/dist/es/components/inline-notification/daikin-inline-notification.js +93 -0
- package/dist/es/components/inline-notification/index.d.ts +1 -0
- package/dist/es/components/inline-notification/index.js +4 -0
- package/dist/es/components/input-group/daikin-input-group.d.ts +15 -7
- package/dist/es/components/input-group/daikin-input-group.js +11 -8
- package/dist/es/components/link/daikin-link.d.ts +2 -2
- package/dist/es/components/link/daikin-link.js +8 -5
- package/dist/es/components/list/daikin-list.d.ts +7 -2
- package/dist/es/components/list/daikin-list.js +7 -7
- package/dist/es/components/list-item/daikin-list-item.d.ts +6 -2
- package/dist/es/components/list-item/daikin-list-item.js +7 -4
- package/dist/es/components/pagination/daikin-pagination.d.ts +6 -2
- package/dist/es/components/pagination/daikin-pagination.js +21 -12
- package/dist/es/components/progress-bar/daikin-progress-bar.d.ts +3 -2
- package/dist/es/components/progress-bar/daikin-progress-bar.js +12 -7
- package/dist/es/components/progress-indicator/daikin-progress-indicator.d.ts +12 -5
- package/dist/es/components/progress-indicator/daikin-progress-indicator.js +15 -19
- package/dist/es/components/progress-indicator-item/daikin-progress-indicator-item.d.ts +8 -4
- package/dist/es/components/progress-indicator-item/daikin-progress-indicator-item.js +23 -24
- package/dist/es/components/radio/daikin-radio.d.ts +18 -8
- package/dist/es/components/radio/daikin-radio.js +44 -22
- package/dist/es/components/radio-group/daikin-radio-group.d.ts +20 -14
- package/dist/es/components/radio-group/daikin-radio-group.js +30 -10
- package/dist/es/components/select/daikin-select.d.ts +11 -2
- package/dist/es/components/select/daikin-select.js +14 -5
- package/dist/es/components/tab/daikin-tab.d.ts +7 -2
- package/dist/es/components/tab/daikin-tab.js +24 -9
- package/dist/es/components/tab-panels/daikin-tab-panels.d.ts +2 -2
- package/dist/es/components/tab-panels/daikin-tab-panels.js +8 -6
- package/dist/es/components/table/daikin-table.d.ts +9 -2
- package/dist/es/components/table/daikin-table.js +8 -5
- package/dist/es/components/table-cell/daikin-table-cell.d.ts +6 -2
- package/dist/es/components/table-cell/daikin-table-cell.js +7 -4
- package/dist/es/components/table-header-cell/daikin-table-header-cell.d.ts +6 -2
- package/dist/es/components/table-header-cell/daikin-table-header-cell.js +7 -4
- package/dist/es/components/tabs/daikin-tabs.d.ts +8 -2
- package/dist/es/components/tabs/daikin-tabs.js +24 -9
- package/dist/es/components/text-area/daikin-text-area.d.ts +7 -2
- package/dist/es/components/text-area/daikin-text-area.js +15 -6
- package/dist/es/components/text-field/daikin-text-field.d.ts +7 -2
- package/dist/es/components/text-field/daikin-text-field.js +15 -6
- package/dist/es/components/toast-notification/daikin-toast-notification.d.ts +69 -0
- package/dist/es/components/toast-notification/daikin-toast-notification.js +95 -0
- package/dist/es/components/toast-notification/index.d.ts +1 -0
- package/dist/es/components/toast-notification/index.js +4 -0
- package/dist/es/components/toast-notification-manager/daikin-toast-notification-manager.d.ts +67 -0
- package/dist/es/components/toast-notification-manager/daikin-toast-notification-manager.js +193 -0
- package/dist/es/components/toast-notification-manager/index.d.ts +1 -0
- package/dist/es/components/toast-notification-manager/index.js +4 -0
- package/dist/es/components/toggle/daikin-toggle.d.ts +3 -2
- package/dist/es/components/toggle/daikin-toggle.js +7 -4
- package/dist/es/components/tooltip/daikin-tooltip.d.ts +16 -6
- package/dist/es/components/tooltip/daikin-tooltip.js +41 -29
- package/dist/es/components/tree/daikin-tree.d.ts +13 -14
- package/dist/es/components/tree/daikin-tree.js +35 -36
- package/dist/es/components/tree-item/daikin-tree-item.d.ts +9 -9
- package/dist/es/components/tree-item/daikin-tree-item.js +21 -17
- package/dist/es/components/tree-section/daikin-tree-section.d.ts +10 -20
- package/dist/es/components/tree-section/daikin-tree-section.js +25 -40
- package/dist/es/controllers/click-outside.d.ts +1 -1
- package/dist/es/index.js +10 -2
- package/dist/es/tailwind.css.js +1 -1
- package/dist/es/utils/notification-common.d.ts +19 -0
- package/dist/es/utils/notification-common.js +121 -0
- package/dist/es-dev/base/dds-element.d.ts +4 -0
- package/dist/es-dev/base/dds-element.js +8 -0
- package/dist/es-dev/base/decorators.d.ts +2 -0
- package/dist/es-dev/base/decorators.js +13 -0
- package/dist/es-dev/base/define.d.ts +1 -0
- package/dist/es-dev/base/define.js +18 -0
- package/dist/es-dev/base/index.d.ts +3 -0
- package/dist/es-dev/base/index.js +8 -0
- package/dist/es-dev/components/accordion/daikin-accordion.d.ts +15 -2
- package/dist/es-dev/components/accordion/daikin-accordion.js +45 -5
- package/dist/es-dev/components/accordion-item/daikin-accordion-item.d.ts +10 -16
- package/dist/es-dev/components/accordion-item/daikin-accordion-item.js +36 -76
- package/dist/es-dev/components/breadcrumb/daikin-breadcrumb.d.ts +2 -2
- package/dist/es-dev/components/breadcrumb/daikin-breadcrumb.js +7 -4
- package/dist/es-dev/components/breadcrumb-item/daikin-breadcrumb-item.d.ts +2 -2
- package/dist/es-dev/components/breadcrumb-item/daikin-breadcrumb-item.js +7 -4
- package/dist/es-dev/components/button/daikin-button.d.ts +6 -3
- package/dist/es-dev/components/button/daikin-button.js +19 -7
- package/dist/es-dev/components/card/daikin-card.d.ts +8 -2
- package/dist/es-dev/components/card/daikin-card.js +10 -6
- package/dist/es-dev/components/card-footer/daikin-card-footer.d.ts +6 -2
- package/dist/es-dev/components/card-footer/daikin-card-footer.js +7 -7
- package/dist/es-dev/components/card-header/daikin-card-header.d.ts +6 -2
- package/dist/es-dev/components/card-header/daikin-card-header.js +8 -8
- package/dist/es-dev/components/carousel/daikin-carousel.d.ts +56 -0
- package/dist/es-dev/components/carousel/daikin-carousel.js +228 -0
- package/dist/es-dev/components/carousel/index.d.ts +1 -0
- package/dist/es-dev/components/carousel/index.js +4 -0
- package/dist/es-dev/components/carousel-item/daikin-carousel-item.d.ts +50 -0
- package/dist/es-dev/components/carousel-item/daikin-carousel-item.js +81 -0
- package/dist/es-dev/components/carousel-item/index.d.ts +1 -0
- package/dist/es-dev/components/carousel-item/index.js +4 -0
- package/dist/es-dev/components/checkbox/daikin-checkbox.d.ts +4 -2
- package/dist/es-dev/components/checkbox/daikin-checkbox.js +33 -15
- package/dist/es-dev/components/dropdown/daikin-dropdown.d.ts +16 -2
- package/dist/es-dev/components/dropdown/daikin-dropdown.js +15 -4
- package/dist/es-dev/components/dropdown-item/daikin-dropdown-item.d.ts +10 -2
- package/dist/es-dev/components/dropdown-item/daikin-dropdown-item.js +11 -4
- package/dist/es-dev/components/icon/daikin-icon.d.ts +2 -2
- package/dist/es-dev/components/icon/daikin-icon.js +7 -4
- package/dist/es-dev/components/icon/icons.json.d.ts +0 -8
- package/dist/es-dev/components/icon/icons.json.js +1 -70
- package/dist/es-dev/components/icon-button/daikin-icon-button.d.ts +2 -2
- package/dist/es-dev/components/icon-button/daikin-icon-button.js +7 -4
- package/dist/es-dev/components/index.d.ts +5 -1
- package/dist/es-dev/components/index.js +10 -2
- package/dist/es-dev/components/inline-notification/daikin-inline-notification.d.ts +55 -0
- package/dist/es-dev/components/inline-notification/daikin-inline-notification.js +93 -0
- package/dist/es-dev/components/inline-notification/index.d.ts +1 -0
- package/dist/es-dev/components/inline-notification/index.js +4 -0
- package/dist/es-dev/components/input-group/daikin-input-group.d.ts +15 -7
- package/dist/es-dev/components/input-group/daikin-input-group.js +11 -8
- package/dist/es-dev/components/link/daikin-link.d.ts +2 -2
- package/dist/es-dev/components/link/daikin-link.js +8 -5
- package/dist/es-dev/components/list/daikin-list.d.ts +7 -2
- package/dist/es-dev/components/list/daikin-list.js +7 -7
- package/dist/es-dev/components/list-item/daikin-list-item.d.ts +6 -2
- package/dist/es-dev/components/list-item/daikin-list-item.js +7 -4
- package/dist/es-dev/components/pagination/daikin-pagination.d.ts +6 -2
- package/dist/es-dev/components/pagination/daikin-pagination.js +21 -12
- package/dist/es-dev/components/progress-bar/daikin-progress-bar.d.ts +3 -2
- package/dist/es-dev/components/progress-bar/daikin-progress-bar.js +12 -7
- package/dist/es-dev/components/progress-indicator/daikin-progress-indicator.d.ts +12 -5
- package/dist/es-dev/components/progress-indicator/daikin-progress-indicator.js +15 -29
- package/dist/es-dev/components/progress-indicator-item/daikin-progress-indicator-item.d.ts +8 -4
- package/dist/es-dev/components/progress-indicator-item/daikin-progress-indicator-item.js +23 -24
- package/dist/es-dev/components/radio/daikin-radio.d.ts +18 -8
- package/dist/es-dev/components/radio/daikin-radio.js +44 -22
- package/dist/es-dev/components/radio-group/daikin-radio-group.d.ts +20 -14
- package/dist/es-dev/components/radio-group/daikin-radio-group.js +30 -10
- package/dist/es-dev/components/select/daikin-select.d.ts +11 -2
- package/dist/es-dev/components/select/daikin-select.js +14 -5
- package/dist/es-dev/components/tab/daikin-tab.d.ts +7 -2
- package/dist/es-dev/components/tab/daikin-tab.js +24 -9
- package/dist/es-dev/components/tab-panels/daikin-tab-panels.d.ts +2 -2
- package/dist/es-dev/components/tab-panels/daikin-tab-panels.js +8 -6
- package/dist/es-dev/components/table/daikin-table.d.ts +9 -2
- package/dist/es-dev/components/table/daikin-table.js +8 -5
- package/dist/es-dev/components/table-cell/daikin-table-cell.d.ts +6 -2
- package/dist/es-dev/components/table-cell/daikin-table-cell.js +7 -4
- package/dist/es-dev/components/table-header-cell/daikin-table-header-cell.d.ts +6 -2
- package/dist/es-dev/components/table-header-cell/daikin-table-header-cell.js +7 -4
- package/dist/es-dev/components/tabs/daikin-tabs.d.ts +8 -2
- package/dist/es-dev/components/tabs/daikin-tabs.js +24 -9
- package/dist/es-dev/components/text-area/daikin-text-area.d.ts +7 -2
- package/dist/es-dev/components/text-area/daikin-text-area.js +15 -6
- package/dist/es-dev/components/text-field/daikin-text-field.d.ts +7 -2
- package/dist/es-dev/components/text-field/daikin-text-field.js +15 -6
- package/dist/es-dev/components/toast-notification/daikin-toast-notification.d.ts +69 -0
- package/dist/es-dev/components/toast-notification/daikin-toast-notification.js +95 -0
- package/dist/es-dev/components/toast-notification/index.d.ts +1 -0
- package/dist/es-dev/components/toast-notification/index.js +4 -0
- package/dist/es-dev/components/toast-notification-manager/daikin-toast-notification-manager.d.ts +67 -0
- package/dist/es-dev/components/toast-notification-manager/daikin-toast-notification-manager.js +193 -0
- package/dist/es-dev/components/toast-notification-manager/index.d.ts +1 -0
- package/dist/es-dev/components/toast-notification-manager/index.js +4 -0
- package/dist/es-dev/components/toggle/daikin-toggle.d.ts +3 -2
- package/dist/es-dev/components/toggle/daikin-toggle.js +7 -4
- package/dist/es-dev/components/tooltip/daikin-tooltip.d.ts +16 -6
- package/dist/es-dev/components/tooltip/daikin-tooltip.js +41 -29
- package/dist/es-dev/components/tree/daikin-tree.d.ts +13 -14
- package/dist/es-dev/components/tree/daikin-tree.js +35 -36
- package/dist/es-dev/components/tree-item/daikin-tree-item.d.ts +9 -9
- package/dist/es-dev/components/tree-item/daikin-tree-item.js +21 -17
- package/dist/es-dev/components/tree-section/daikin-tree-section.d.ts +10 -20
- package/dist/es-dev/components/tree-section/daikin-tree-section.js +25 -40
- package/dist/es-dev/controllers/click-outside.d.ts +1 -1
- package/dist/es-dev/index.js +10 -2
- package/dist/es-dev/tailwind.css.js +1 -1
- package/dist/es-dev/utils/notification-common.d.ts +19 -0
- package/dist/es-dev/utils/notification-common.js +124 -0
- package/icons/checkbox-checked.svg +2 -3
- package/icons/status-negative.svg +4 -2
- package/icons/status-warning.svg +2 -4
- package/package.json +54 -50
- package/dist/cjs/components/notification/daikin-notification.cjs +0 -196
- package/dist/cjs/components/notification/daikin-notification.d.cts +0 -77
- package/dist/cjs/components/notification/index.cjs +0 -7
- package/dist/cjs/components/notification/index.d.cts +0 -1
- package/dist/cjs/constants/events.cjs +0 -4
- package/dist/cjs-dev/components/notification/daikin-notification.cjs +0 -196
- package/dist/cjs-dev/components/notification/daikin-notification.d.cts +0 -77
- package/dist/cjs-dev/components/notification/index.cjs +0 -7
- package/dist/cjs-dev/components/notification/index.d.cts +0 -1
- package/dist/cjs-dev/constants/events.cjs +0 -4
- package/dist/es/components/notification/daikin-notification.d.ts +0 -77
- package/dist/es/components/notification/daikin-notification.js +0 -197
- package/dist/es/components/notification/index.d.ts +0 -1
- package/dist/es/components/notification/index.js +0 -4
- package/dist/es/constants/events.js +0 -4
- package/dist/es-dev/components/notification/daikin-notification.d.ts +0 -77
- package/dist/es-dev/components/notification/daikin-notification.js +0 -197
- package/dist/es-dev/components/notification/index.d.ts +0 -1
- package/dist/es-dev/components/notification/index.js +0 -4
- package/dist/es-dev/constants/events.js +0 -4
- package/icons/arrow-up.svg +0 -3
- package/icons/status-success.svg +0 -6
|
@@ -1,5 +1,8 @@
|
|
|
1
|
-
import { css, unsafeCSS,
|
|
2
|
-
import { property, queryAssignedElements
|
|
1
|
+
import { css, unsafeCSS, html } from "lit";
|
|
2
|
+
import { property, queryAssignedElements } from "lit/decorators.js";
|
|
3
|
+
import { DDSElement } from "../../base/dds-element.js";
|
|
4
|
+
import { ddsElement } from "../../base/decorators.js";
|
|
5
|
+
import "../../base/define.js";
|
|
3
6
|
import tailwindStyles from "../../tailwind.css.js";
|
|
4
7
|
import { handleTreeMoveFocusRoot } from "./common.js";
|
|
5
8
|
var __defProp = Object.defineProperty;
|
|
@@ -12,41 +15,41 @@ var __decorateClass = (decorators, target, key, kind) => {
|
|
|
12
15
|
if (kind && result) __defProp(target, key, result);
|
|
13
16
|
return result;
|
|
14
17
|
};
|
|
15
|
-
let DaikinTree = class extends
|
|
18
|
+
let DaikinTree = class extends DDSElement {
|
|
16
19
|
constructor() {
|
|
17
20
|
super(...arguments);
|
|
18
21
|
this.selectable = false;
|
|
19
|
-
this.
|
|
22
|
+
this.selectedItems = [];
|
|
20
23
|
}
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
this._sections.forEach((section) => {
|
|
26
|
-
section.selectable = this.selectable;
|
|
27
|
-
});
|
|
24
|
+
_handleMouseDown(event) {
|
|
25
|
+
if (event.detail >= 2) {
|
|
26
|
+
event.preventDefault();
|
|
27
|
+
}
|
|
28
28
|
}
|
|
29
29
|
_handleSlotChange() {
|
|
30
|
-
this.
|
|
31
|
-
this.
|
|
30
|
+
this._children.forEach((child) => child.level = 0);
|
|
31
|
+
this.selectItems(this.selectedItems);
|
|
32
32
|
}
|
|
33
33
|
_handleTreeMoveFocus(event) {
|
|
34
34
|
handleTreeMoveFocusRoot(event, this._children);
|
|
35
35
|
}
|
|
36
36
|
_handleTreeSelect(event) {
|
|
37
|
-
event.stopPropagation();
|
|
38
37
|
if (!this.selectable) {
|
|
39
38
|
return;
|
|
40
39
|
}
|
|
40
|
+
event.stopPropagation();
|
|
41
41
|
const target = event.target;
|
|
42
|
-
this.
|
|
42
|
+
this.selectedItems = [target.value];
|
|
43
43
|
}
|
|
44
44
|
_handleTreeUnselect(event) {
|
|
45
|
+
if (!this.selectable) {
|
|
46
|
+
return;
|
|
47
|
+
}
|
|
45
48
|
event.stopPropagation();
|
|
46
|
-
this.
|
|
49
|
+
this.selectedItems = this.getSelectedItems();
|
|
47
50
|
}
|
|
48
51
|
render() {
|
|
49
|
-
return html`<div role="tree">
|
|
52
|
+
return html`<div role="tree" @mousedown=${this._handleMouseDown}>
|
|
50
53
|
<slot
|
|
51
54
|
@slotchange=${this._handleSlotChange}
|
|
52
55
|
@tree-move-focus=${this._handleTreeMoveFocus}
|
|
@@ -56,31 +59,30 @@ let DaikinTree = class extends LitElement {
|
|
|
56
59
|
</div>`;
|
|
57
60
|
}
|
|
58
61
|
updated(changedProperties) {
|
|
59
|
-
if (changedProperties.has("
|
|
60
|
-
this.
|
|
61
|
-
}
|
|
62
|
-
if (changedProperties.has("selected") && this.selectable) {
|
|
63
|
-
this.selectItem(this.selected);
|
|
62
|
+
if (changedProperties.has("selectedItems")) {
|
|
63
|
+
this.selectItems(this.selectedItems);
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
66
|
/**
|
|
67
|
-
* Calls `
|
|
67
|
+
* Calls `selectItems` for the tree sections and tree items of the child elements in the slot.
|
|
68
68
|
*
|
|
69
69
|
* @param value Tree item value.
|
|
70
70
|
* @private
|
|
71
71
|
*/
|
|
72
|
-
|
|
73
|
-
this._children.forEach((child) => child.
|
|
72
|
+
selectItems(values) {
|
|
73
|
+
this._children.forEach((child) => child.selectItems(values));
|
|
74
74
|
}
|
|
75
75
|
/**
|
|
76
|
-
* Returns the `value` of the currently selected
|
|
77
|
-
* If nothing is selected, returns `
|
|
76
|
+
* Returns an array of the `value` of the currently selected sections and items.
|
|
77
|
+
* If nothing is selected, returns `[]`.
|
|
78
78
|
*
|
|
79
|
-
* @returns
|
|
79
|
+
* @returns An array of the `value` of the selected sections and items (if any). `[]` if there is none.
|
|
80
80
|
* @private
|
|
81
81
|
*/
|
|
82
|
-
|
|
83
|
-
return
|
|
82
|
+
getSelectedItems() {
|
|
83
|
+
return Array.from(
|
|
84
|
+
new Set(this._children.flatMap((child) => child.getSelectedItems()))
|
|
85
|
+
);
|
|
84
86
|
}
|
|
85
87
|
};
|
|
86
88
|
DaikinTree.styles = css`
|
|
@@ -94,16 +96,13 @@ __decorateClass([
|
|
|
94
96
|
property({ type: Boolean, reflect: true })
|
|
95
97
|
], DaikinTree.prototype, "selectable", 2);
|
|
96
98
|
__decorateClass([
|
|
97
|
-
property({ type:
|
|
98
|
-
], DaikinTree.prototype, "
|
|
99
|
+
property({ type: Array, attribute: false })
|
|
100
|
+
], DaikinTree.prototype, "selectedItems", 2);
|
|
99
101
|
__decorateClass([
|
|
100
102
|
queryAssignedElements({ selector: "daikin-tree-section,daikin-tree-item" })
|
|
101
103
|
], DaikinTree.prototype, "_children", 2);
|
|
102
|
-
__decorateClass([
|
|
103
|
-
queryAssignedElements({ selector: "daikin-tree-section" })
|
|
104
|
-
], DaikinTree.prototype, "_sections", 2);
|
|
105
104
|
DaikinTree = __decorateClass([
|
|
106
|
-
|
|
105
|
+
ddsElement("daikin-tree")
|
|
107
106
|
], DaikinTree);
|
|
108
107
|
export {
|
|
109
108
|
DaikinTree
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { PropertyValues } from 'lit';
|
|
2
|
+
import { DDSElement } from "../../base/index.js";
|
|
2
3
|
export declare const cvaTreeChildren: (props?: ({
|
|
3
4
|
disabled?: boolean | null | undefined;
|
|
4
5
|
selected?: boolean | null | undefined;
|
|
@@ -29,7 +30,7 @@ export declare const cvaTreeChildren: (props?: ({
|
|
|
29
30
|
* <daikin-tree-item>Tree item</daikin-tree-item>
|
|
30
31
|
* ```
|
|
31
32
|
*/
|
|
32
|
-
export declare class DaikinTreeItem extends
|
|
33
|
+
export declare class DaikinTreeItem extends DDSElement {
|
|
33
34
|
static readonly styles: import('lit').CSSResult;
|
|
34
35
|
/**
|
|
35
36
|
* Value of the tree item.
|
|
@@ -41,9 +42,7 @@ export declare class DaikinTreeItem extends LitElement {
|
|
|
41
42
|
disabled: boolean;
|
|
42
43
|
/**
|
|
43
44
|
* Whether the tree item is selected.
|
|
44
|
-
*
|
|
45
|
-
* Controlled by `daikin-tree` if its `selectable` is true.
|
|
46
|
-
* If the tree's `selected` is false, you can manually set this property to control the display of the selected state.
|
|
45
|
+
* Controlled by `daikin-tree`.
|
|
47
46
|
*/
|
|
48
47
|
selected: boolean;
|
|
49
48
|
/**
|
|
@@ -55,6 +54,7 @@ export declare class DaikinTreeItem extends LitElement {
|
|
|
55
54
|
*/
|
|
56
55
|
level: number;
|
|
57
56
|
private readonly _focusableRef;
|
|
57
|
+
private get _selected();
|
|
58
58
|
private _handleKeyDown;
|
|
59
59
|
constructor();
|
|
60
60
|
render(): import('lit-html').TemplateResult<1>;
|
|
@@ -79,14 +79,14 @@ export declare class DaikinTreeItem extends LitElement {
|
|
|
79
79
|
* @param value Tree item value.
|
|
80
80
|
* @private
|
|
81
81
|
*/
|
|
82
|
-
|
|
82
|
+
selectItems(values: readonly string[]): void;
|
|
83
83
|
/**
|
|
84
|
-
* Returns `this.value` if selected, or `
|
|
84
|
+
* Returns `[this.value]` if selected, or `[]` if not selected.
|
|
85
85
|
*
|
|
86
|
-
* @returns `this.value` if selected. `
|
|
86
|
+
* @returns `[this.value]` if selected. `[]` if not selected.
|
|
87
87
|
* @private
|
|
88
88
|
*/
|
|
89
|
-
|
|
89
|
+
getSelectedItems(): string[];
|
|
90
90
|
}
|
|
91
91
|
declare global {
|
|
92
92
|
interface HTMLElementTagNameMap {
|
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
import { cva } from "class-variance-authority";
|
|
2
|
-
import { css, unsafeCSS,
|
|
3
|
-
import { property
|
|
2
|
+
import { css, unsafeCSS, html } from "lit";
|
|
3
|
+
import { property } from "lit/decorators.js";
|
|
4
4
|
import { ifDefined } from "lit/directives/if-defined.js";
|
|
5
5
|
import { createRef, ref } from "lit/directives/ref.js";
|
|
6
|
+
import { DDSElement } from "../../base/dds-element.js";
|
|
7
|
+
import { ddsElement } from "../../base/decorators.js";
|
|
8
|
+
import "../../base/define.js";
|
|
6
9
|
import tailwindStyles from "../../tailwind.css.js";
|
|
7
10
|
import { isSimpleKeyEvent } from "../../utils/is-simple-key.js";
|
|
8
11
|
import { emitTreeSelect, getDirectionFromKey, emitTreeMoveFocus, emitTreeUnselect } from "../tree/common.js";
|
|
@@ -25,6 +28,7 @@ const cvaTreeChildren = cva(
|
|
|
25
28
|
"py-3",
|
|
26
29
|
"pr-4",
|
|
27
30
|
"pl-[calc((var(--level)+1)*1rem)]",
|
|
31
|
+
"leading-[130%]",
|
|
28
32
|
"focus-visible:outline",
|
|
29
33
|
"focus-visible:outline-2",
|
|
30
34
|
"focus-visible:-outline-offset-2",
|
|
@@ -58,7 +62,8 @@ const cvaTreeChildren = cva(
|
|
|
58
62
|
"before:i-daikin-chevron-right",
|
|
59
63
|
"before:size-5",
|
|
60
64
|
"before:m-0.5",
|
|
61
|
-
"before:transition-all"
|
|
65
|
+
"before:transition-all",
|
|
66
|
+
"before:flex-none"
|
|
62
67
|
]
|
|
63
68
|
},
|
|
64
69
|
open: {
|
|
@@ -68,7 +73,7 @@ const cvaTreeChildren = cva(
|
|
|
68
73
|
}
|
|
69
74
|
}
|
|
70
75
|
);
|
|
71
|
-
let DaikinTreeItem = class extends
|
|
76
|
+
let DaikinTreeItem = class extends DDSElement {
|
|
72
77
|
constructor() {
|
|
73
78
|
super();
|
|
74
79
|
this.value = "";
|
|
@@ -82,6 +87,9 @@ let DaikinTreeItem = class extends LitElement {
|
|
|
82
87
|
}
|
|
83
88
|
});
|
|
84
89
|
}
|
|
90
|
+
get _selected() {
|
|
91
|
+
return this.selected && !this.disabled;
|
|
92
|
+
}
|
|
85
93
|
_handleKeyDown(event) {
|
|
86
94
|
if (!isSimpleKeyEvent(event)) {
|
|
87
95
|
return;
|
|
@@ -105,13 +113,13 @@ let DaikinTreeItem = class extends LitElement {
|
|
|
105
113
|
${ref(this._focusableRef)}
|
|
106
114
|
class=${cvaTreeChildren({
|
|
107
115
|
disabled: this.disabled,
|
|
108
|
-
selected: this.
|
|
116
|
+
selected: this._selected,
|
|
109
117
|
icon: false,
|
|
110
118
|
open: false
|
|
111
119
|
})}
|
|
112
120
|
role="treeitem"
|
|
113
121
|
aria-disabled=${this.disabled}
|
|
114
|
-
aria-selected=${this.
|
|
122
|
+
aria-selected=${this._selected}
|
|
115
123
|
tabindex=${ifDefined(!this.disabled ? 0 : void 0)}
|
|
116
124
|
style=${`--level:${this.level}`}
|
|
117
125
|
@click=${() => emitTreeSelect(this)}
|
|
@@ -123,7 +131,6 @@ let DaikinTreeItem = class extends LitElement {
|
|
|
123
131
|
updated(changedProperties) {
|
|
124
132
|
if (changedProperties.has("disabled")) {
|
|
125
133
|
if (this.disabled) {
|
|
126
|
-
this.selectItem(null);
|
|
127
134
|
emitTreeUnselect(this);
|
|
128
135
|
}
|
|
129
136
|
}
|
|
@@ -154,20 +161,17 @@ let DaikinTreeItem = class extends LitElement {
|
|
|
154
161
|
* @param value Tree item value.
|
|
155
162
|
* @private
|
|
156
163
|
*/
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
return;
|
|
160
|
-
}
|
|
161
|
-
this.selected = this.value === value;
|
|
164
|
+
selectItems(values) {
|
|
165
|
+
this.selected = !this.disabled && values.includes(this.value);
|
|
162
166
|
}
|
|
163
167
|
/**
|
|
164
|
-
* Returns `this.value` if selected, or `
|
|
168
|
+
* Returns `[this.value]` if selected, or `[]` if not selected.
|
|
165
169
|
*
|
|
166
|
-
* @returns `this.value` if selected. `
|
|
170
|
+
* @returns `[this.value]` if selected. `[]` if not selected.
|
|
167
171
|
* @private
|
|
168
172
|
*/
|
|
169
|
-
|
|
170
|
-
return !this.disabled && this.selected ? this.value :
|
|
173
|
+
getSelectedItems() {
|
|
174
|
+
return !this.disabled && this.selected ? [this.value] : [];
|
|
171
175
|
}
|
|
172
176
|
};
|
|
173
177
|
DaikinTreeItem.styles = css`
|
|
@@ -190,7 +194,7 @@ __decorateClass([
|
|
|
190
194
|
property({ type: Number, attribute: false })
|
|
191
195
|
], DaikinTreeItem.prototype, "level", 2);
|
|
192
196
|
DaikinTreeItem = __decorateClass([
|
|
193
|
-
|
|
197
|
+
ddsElement("daikin-tree-item")
|
|
194
198
|
], DaikinTreeItem);
|
|
195
199
|
export {
|
|
196
200
|
DaikinTreeItem,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { PropertyValues } from 'lit';
|
|
2
|
+
import { DDSElement } from "../../base/index.js";
|
|
2
3
|
/**
|
|
3
4
|
* The tree section component that can be used within `daikin-tree` component.
|
|
4
5
|
*
|
|
@@ -30,7 +31,7 @@ import { LitElement, PropertyValues } from 'lit';
|
|
|
30
31
|
* </daikin-tree-section>
|
|
31
32
|
* ```
|
|
32
33
|
*/
|
|
33
|
-
export declare class DaikinTreeSection extends
|
|
34
|
+
export declare class DaikinTreeSection extends DDSElement {
|
|
34
35
|
static readonly styles: import('lit').CSSResult;
|
|
35
36
|
/**
|
|
36
37
|
* Value of the tree section.
|
|
@@ -40,18 +41,9 @@ export declare class DaikinTreeSection extends LitElement {
|
|
|
40
41
|
* Whether the tree section is disabled.
|
|
41
42
|
*/
|
|
42
43
|
disabled: boolean;
|
|
43
|
-
/**
|
|
44
|
-
* Whether or not to enable tree selection.
|
|
45
|
-
* Controlled by `daikin-tree`.
|
|
46
|
-
*
|
|
47
|
-
* @private
|
|
48
|
-
*/
|
|
49
|
-
selectable: boolean;
|
|
50
44
|
/**
|
|
51
45
|
* Whether the tree item is selected.
|
|
52
|
-
*
|
|
53
|
-
* Controlled by `daikin-tree` if its `selectable` is true.
|
|
54
|
-
* If the tree's `selected` is false, you can manually set this property to control the display of the selected state.
|
|
46
|
+
* Controlled by `daikin-tree`.
|
|
55
47
|
*/
|
|
56
48
|
selected: boolean;
|
|
57
49
|
/**
|
|
@@ -68,12 +60,10 @@ export declare class DaikinTreeSection extends LitElement {
|
|
|
68
60
|
*/
|
|
69
61
|
level: number;
|
|
70
62
|
private readonly _children;
|
|
71
|
-
private readonly _sections;
|
|
72
63
|
private readonly _focusableRef;
|
|
73
64
|
private get _open();
|
|
74
65
|
private get _selected();
|
|
75
66
|
private _updateChildrenLevel;
|
|
76
|
-
private _updateSections;
|
|
77
67
|
private _handleClick;
|
|
78
68
|
private _handleSlotChange;
|
|
79
69
|
private _handleTreeMoveFocus;
|
|
@@ -97,20 +87,20 @@ export declare class DaikinTreeSection extends LitElement {
|
|
|
97
87
|
focusLastItem(options?: FocusOptions): void;
|
|
98
88
|
/**
|
|
99
89
|
* Updates the selection state (`this.selected`) to true if the argument `value` matches `this.value`. Otherwise, sets it to false.
|
|
100
|
-
* In addition, calls `
|
|
90
|
+
* In addition, calls `selectItems` for the tree sections and tree items of the child elements in the slot in the same way.
|
|
101
91
|
*
|
|
102
92
|
* @param value Tree item value.
|
|
103
93
|
* @private
|
|
104
94
|
*/
|
|
105
|
-
|
|
95
|
+
selectItems(values: readonly string[]): void;
|
|
106
96
|
/**
|
|
107
|
-
* Returns the `value` of the currently selected
|
|
108
|
-
* If nothing is selected, returns `
|
|
97
|
+
* Returns an array of the `value` of the currently selected sections and items.
|
|
98
|
+
* If nothing is selected, returns `[]`.
|
|
109
99
|
*
|
|
110
|
-
* @returns
|
|
100
|
+
* @returns An array of the `value` of the currently selected sections and items (if any). `[]` if there is none.
|
|
111
101
|
* @private
|
|
112
102
|
*/
|
|
113
|
-
|
|
103
|
+
getSelectedItems(): string[];
|
|
114
104
|
}
|
|
115
105
|
declare global {
|
|
116
106
|
interface HTMLElementTagNameMap {
|
|
@@ -1,7 +1,10 @@
|
|
|
1
|
-
import { css, unsafeCSS,
|
|
2
|
-
import { property, queryAssignedElements
|
|
1
|
+
import { css, unsafeCSS, html } from "lit";
|
|
2
|
+
import { property, queryAssignedElements } from "lit/decorators.js";
|
|
3
3
|
import { ifDefined } from "lit/directives/if-defined.js";
|
|
4
4
|
import { createRef, ref } from "lit/directives/ref.js";
|
|
5
|
+
import { DDSElement } from "../../base/dds-element.js";
|
|
6
|
+
import { ddsElement } from "../../base/decorators.js";
|
|
7
|
+
import "../../base/define.js";
|
|
5
8
|
import tailwindStyles from "../../tailwind.css.js";
|
|
6
9
|
import { isSimpleKeyEvent } from "../../utils/is-simple-key.js";
|
|
7
10
|
import { cvaTreeChildren } from "../tree-item/daikin-tree-item.js";
|
|
@@ -16,12 +19,11 @@ var __decorateClass = (decorators, target, key, kind) => {
|
|
|
16
19
|
if (kind && result) __defProp(target, key, result);
|
|
17
20
|
return result;
|
|
18
21
|
};
|
|
19
|
-
let DaikinTreeSection = class extends
|
|
22
|
+
let DaikinTreeSection = class extends DDSElement {
|
|
20
23
|
constructor() {
|
|
21
24
|
super(...arguments);
|
|
22
25
|
this.value = "";
|
|
23
26
|
this.disabled = false;
|
|
24
|
-
this.selectable = false;
|
|
25
27
|
this.selected = false;
|
|
26
28
|
this.open = false;
|
|
27
29
|
this.level = 0;
|
|
@@ -38,11 +40,6 @@ let DaikinTreeSection = class extends LitElement {
|
|
|
38
40
|
item.level = this.level + 1;
|
|
39
41
|
}
|
|
40
42
|
}
|
|
41
|
-
_updateSections() {
|
|
42
|
-
this._sections.forEach((section) => {
|
|
43
|
-
section.selectable = this.selectable;
|
|
44
|
-
});
|
|
45
|
-
}
|
|
46
43
|
_handleClick() {
|
|
47
44
|
if (!this.disabled && this.dispatchEvent(
|
|
48
45
|
new Event("toggle", {
|
|
@@ -55,7 +52,6 @@ let DaikinTreeSection = class extends LitElement {
|
|
|
55
52
|
}
|
|
56
53
|
_handleSlotChange() {
|
|
57
54
|
this._updateChildrenLevel();
|
|
58
|
-
this._updateSections();
|
|
59
55
|
}
|
|
60
56
|
_handleTreeMoveFocus(event) {
|
|
61
57
|
handleTreeMoveFocusSection(this, event, this._children);
|
|
@@ -68,9 +64,7 @@ let DaikinTreeSection = class extends LitElement {
|
|
|
68
64
|
if (!this.disabled && ["Enter", " "].includes(event.key)) {
|
|
69
65
|
event.preventDefault();
|
|
70
66
|
this._handleClick();
|
|
71
|
-
|
|
72
|
-
emitTreeSelect(this);
|
|
73
|
-
}
|
|
67
|
+
emitTreeSelect(this);
|
|
74
68
|
return;
|
|
75
69
|
}
|
|
76
70
|
const direction = getDirectionFromKey(event.key);
|
|
@@ -143,13 +137,9 @@ let DaikinTreeSection = class extends LitElement {
|
|
|
143
137
|
}
|
|
144
138
|
if (changedProperties.has("disabled")) {
|
|
145
139
|
if (this.disabled) {
|
|
146
|
-
this.selectItem(null);
|
|
147
140
|
emitTreeUnselect(this);
|
|
148
141
|
}
|
|
149
142
|
}
|
|
150
|
-
if (changedProperties.has("selectable")) {
|
|
151
|
-
this._updateSections();
|
|
152
|
-
}
|
|
153
143
|
}
|
|
154
144
|
/**
|
|
155
145
|
* Focuses on the inner button.
|
|
@@ -178,33 +168,34 @@ let DaikinTreeSection = class extends LitElement {
|
|
|
178
168
|
}
|
|
179
169
|
/**
|
|
180
170
|
* Updates the selection state (`this.selected`) to true if the argument `value` matches `this.value`. Otherwise, sets it to false.
|
|
181
|
-
* In addition, calls `
|
|
171
|
+
* In addition, calls `selectItems` for the tree sections and tree items of the child elements in the slot in the same way.
|
|
182
172
|
*
|
|
183
173
|
* @param value Tree item value.
|
|
184
174
|
* @private
|
|
185
175
|
*/
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
this._children.forEach((child) => child.selectItem(value));
|
|
176
|
+
selectItems(values) {
|
|
177
|
+
this.selected = !this.disabled && values.includes(this.value);
|
|
178
|
+
this._children.forEach(
|
|
179
|
+
(child) => child.selectItems(this.disabled ? [] : values)
|
|
180
|
+
);
|
|
192
181
|
}
|
|
193
182
|
/**
|
|
194
|
-
* Returns the `value` of the currently selected
|
|
195
|
-
* If nothing is selected, returns `
|
|
183
|
+
* Returns an array of the `value` of the currently selected sections and items.
|
|
184
|
+
* If nothing is selected, returns `[]`.
|
|
196
185
|
*
|
|
197
|
-
* @returns
|
|
186
|
+
* @returns An array of the `value` of the currently selected sections and items (if any). `[]` if there is none.
|
|
198
187
|
* @private
|
|
199
188
|
*/
|
|
200
|
-
|
|
189
|
+
getSelectedItems() {
|
|
201
190
|
if (this.disabled) {
|
|
202
|
-
return
|
|
203
|
-
}
|
|
204
|
-
if (this.selected) {
|
|
205
|
-
return this.value;
|
|
191
|
+
return [];
|
|
206
192
|
}
|
|
207
|
-
return
|
|
193
|
+
return Array.from(
|
|
194
|
+
/* @__PURE__ */ new Set([
|
|
195
|
+
...this.selected ? [this.value] : [],
|
|
196
|
+
...this._children.flatMap((child) => child.getSelectedItems())
|
|
197
|
+
])
|
|
198
|
+
);
|
|
208
199
|
}
|
|
209
200
|
};
|
|
210
201
|
DaikinTreeSection.styles = css`
|
|
@@ -220,9 +211,6 @@ __decorateClass([
|
|
|
220
211
|
__decorateClass([
|
|
221
212
|
property({ type: Boolean, reflect: true })
|
|
222
213
|
], DaikinTreeSection.prototype, "disabled", 2);
|
|
223
|
-
__decorateClass([
|
|
224
|
-
property({ type: Boolean, attribute: false })
|
|
225
|
-
], DaikinTreeSection.prototype, "selectable", 2);
|
|
226
214
|
__decorateClass([
|
|
227
215
|
property({ type: Boolean, reflect: true })
|
|
228
216
|
], DaikinTreeSection.prototype, "selected", 2);
|
|
@@ -235,11 +223,8 @@ __decorateClass([
|
|
|
235
223
|
__decorateClass([
|
|
236
224
|
queryAssignedElements({ selector: "daikin-tree-section,daikin-tree-item" })
|
|
237
225
|
], DaikinTreeSection.prototype, "_children", 2);
|
|
238
|
-
__decorateClass([
|
|
239
|
-
queryAssignedElements({ selector: "daikin-tree-section" })
|
|
240
|
-
], DaikinTreeSection.prototype, "_sections", 2);
|
|
241
226
|
DaikinTreeSection = __decorateClass([
|
|
242
|
-
|
|
227
|
+
ddsElement("daikin-tree-section")
|
|
243
228
|
], DaikinTreeSection);
|
|
244
229
|
export {
|
|
245
230
|
DaikinTreeSection
|
package/dist/es/index.js
CHANGED
|
@@ -6,16 +6,18 @@ import { DaikinButton } from "./components/button/daikin-button.js";
|
|
|
6
6
|
import { DaikinCard } from "./components/card/daikin-card.js";
|
|
7
7
|
import { DaikinCardFooter } from "./components/card-footer/daikin-card-footer.js";
|
|
8
8
|
import { DaikinCardHeader } from "./components/card-header/daikin-card-header.js";
|
|
9
|
+
import { DaikinCarousel } from "./components/carousel/daikin-carousel.js";
|
|
10
|
+
import { DaikinCarouselItem } from "./components/carousel-item/daikin-carousel-item.js";
|
|
9
11
|
import { DaikinCheckbox } from "./components/checkbox/daikin-checkbox.js";
|
|
10
12
|
import { DaikinDropdown } from "./components/dropdown/daikin-dropdown.js";
|
|
11
13
|
import { DaikinDropdownItem } from "./components/dropdown-item/daikin-dropdown-item.js";
|
|
12
14
|
import { DaikinIcon, iconList } from "./components/icon/daikin-icon.js";
|
|
13
15
|
import { DaikinIconButton } from "./components/icon-button/daikin-icon-button.js";
|
|
16
|
+
import { DaikinInlineNotification } from "./components/inline-notification/daikin-inline-notification.js";
|
|
14
17
|
import { DaikinInputGroup } from "./components/input-group/daikin-input-group.js";
|
|
15
18
|
import { DaikinLink } from "./components/link/daikin-link.js";
|
|
16
19
|
import { DaikinList } from "./components/list/daikin-list.js";
|
|
17
20
|
import { DaikinListItem } from "./components/list-item/daikin-list-item.js";
|
|
18
|
-
import { DaikinNotification } from "./components/notification/daikin-notification.js";
|
|
19
21
|
import { DaikinPagination } from "./components/pagination/daikin-pagination.js";
|
|
20
22
|
import { DaikinProgressBar } from "./components/progress-bar/daikin-progress-bar.js";
|
|
21
23
|
import { DaikinProgressIndicator } from "./components/progress-indicator/daikin-progress-indicator.js";
|
|
@@ -30,6 +32,8 @@ import { DaikinTableHeaderCell } from "./components/table-header-cell/daikin-tab
|
|
|
30
32
|
import { DaikinTabs } from "./components/tabs/daikin-tabs.js";
|
|
31
33
|
import { DaikinTextArea } from "./components/text-area/daikin-text-area.js";
|
|
32
34
|
import { DaikinTextField } from "./components/text-field/daikin-text-field.js";
|
|
35
|
+
import { DaikinToastNotification } from "./components/toast-notification/daikin-toast-notification.js";
|
|
36
|
+
import { DaikinToastNotificationManager } from "./components/toast-notification-manager/daikin-toast-notification-manager.js";
|
|
33
37
|
import { DaikinToggle } from "./components/toggle/daikin-toggle.js";
|
|
34
38
|
import { DaikinTooltip } from "./components/tooltip/daikin-tooltip.js";
|
|
35
39
|
import { DaikinTree } from "./components/tree/daikin-tree.js";
|
|
@@ -44,16 +48,18 @@ export {
|
|
|
44
48
|
DaikinCard,
|
|
45
49
|
DaikinCardFooter,
|
|
46
50
|
DaikinCardHeader,
|
|
51
|
+
DaikinCarousel,
|
|
52
|
+
DaikinCarouselItem,
|
|
47
53
|
DaikinCheckbox,
|
|
48
54
|
DaikinDropdown,
|
|
49
55
|
DaikinDropdownItem,
|
|
50
56
|
DaikinIcon,
|
|
51
57
|
DaikinIconButton,
|
|
58
|
+
DaikinInlineNotification,
|
|
52
59
|
DaikinInputGroup,
|
|
53
60
|
DaikinLink,
|
|
54
61
|
DaikinList,
|
|
55
62
|
DaikinListItem,
|
|
56
|
-
DaikinNotification,
|
|
57
63
|
DaikinPagination,
|
|
58
64
|
DaikinProgressBar,
|
|
59
65
|
DaikinProgressIndicator,
|
|
@@ -68,6 +74,8 @@ export {
|
|
|
68
74
|
DaikinTabs,
|
|
69
75
|
DaikinTextArea,
|
|
70
76
|
DaikinTextField,
|
|
77
|
+
DaikinToastNotification,
|
|
78
|
+
DaikinToastNotificationManager,
|
|
71
79
|
DaikinToggle,
|
|
72
80
|
DaikinTooltip,
|
|
73
81
|
DaikinTree,
|