@ukic/canary-web-components 3.0.0-canary.3 → 3.0.0-canary.4
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/core.cjs.js +1 -1
- package/dist/cjs/helpers-a67ad3a4.js.map +1 -1
- package/dist/cjs/ic-accordion-group.cjs.entry.js +9 -9
- package/dist/cjs/ic-accordion-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-accordion.cjs.entry.js +4 -4
- package/dist/cjs/ic-accordion.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-alert.cjs.entry.js +6 -4
- package/dist/cjs/ic-alert.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-card-horizontal.cjs.entry.js +20 -25
- package/dist/cjs/ic-card-horizontal.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-card-vertical.cjs.entry.js +21 -23
- package/dist/cjs/ic-card-vertical.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-checkbox-group.cjs.entry.js +15 -4
- package/dist/cjs/ic-checkbox-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-checkbox.cjs.entry.js +4 -2
- package/dist/cjs/ic-checkbox.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-classification-banner.cjs.entry.js +1 -1
- package/dist/cjs/ic-classification-banner.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-data-table.cjs.entry.js +65 -10
- package/dist/cjs/ic-data-table.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-date-input.cjs.entry.js +3 -2
- package/dist/cjs/ic-date-input.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-date-picker.cjs.entry.js +1 -1
- package/dist/cjs/ic-date-picker.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-dialog.cjs.entry.js +3 -1
- package/dist/cjs/ic-dialog.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-divider.cjs.entry.js +70 -6
- package/dist/cjs/ic-divider.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-empty-state_2.cjs.entry.js +22 -8
- package/dist/cjs/ic-empty-state_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-footer-link-group.cjs.entry.js +1 -1
- package/dist/cjs/ic-footer-link-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-footer-link.cjs.entry.js +1 -1
- package/dist/cjs/ic-footer-link.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-footer.cjs.entry.js +1 -1
- package/dist/cjs/ic-footer.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-hero.cjs.entry.js +1 -1
- package/dist/cjs/ic-hero.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-horizontal-scroll.cjs.entry.js +3 -2
- package/dist/cjs/ic-horizontal-scroll.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-input-component-container_3.cjs.entry.js +5 -4
- package/dist/cjs/ic-input-component-container_3.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-input-label_2.cjs.entry.js +2 -2
- package/dist/cjs/ic-input-label_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-menu-group.cjs.entry.js +1 -1
- package/dist/cjs/ic-menu-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-menu-item.cjs.entry.js +9 -9
- package/dist/cjs/ic-menu-item.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-navigation-group.cjs.entry.js +3 -2
- package/dist/cjs/ic-navigation-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-navigation-item.cjs.entry.js +28 -1
- package/dist/cjs/ic-navigation-item.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-pagination_4.cjs.entry.js +44 -25
- package/dist/cjs/ic-pagination_4.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-popover-menu.cjs.entry.js +3 -3
- package/dist/cjs/ic-popover-menu.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-radio-group.cjs.entry.js +13 -4
- package/dist/cjs/ic-radio-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-radio-option.cjs.entry.js +7 -3
- package/dist/cjs/ic-radio-option.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-search-bar.cjs.entry.js +11 -8
- package/dist/cjs/ic-search-bar.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-side-navigation.cjs.entry.js +3 -2
- package/dist/cjs/ic-side-navigation.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-tab-context.cjs.entry.js +2 -1
- package/dist/cjs/ic-tab-context.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-toast.cjs.entry.js +2 -2
- package/dist/cjs/ic-toast.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-toggle-button-group.cjs.entry.js +1 -1
- package/dist/cjs/ic-toggle-button-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-tree-item.cjs.entry.js +7 -5
- package/dist/cjs/ic-tree-item.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-tree-view.cjs.entry.js +12 -12
- package/dist/cjs/ic-tree-view.cjs.entry.js.map +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/ic-card-horizontal/ic-card-horizontal.css +18 -21
- package/dist/collection/components/ic-card-horizontal/ic-card-horizontal.js +44 -25
- package/dist/collection/components/ic-card-horizontal/ic-card-horizontal.js.map +1 -1
- package/dist/collection/components/ic-data-table/ic-data-table.css +20 -0
- package/dist/collection/components/ic-data-table/ic-data-table.js +86 -11
- package/dist/collection/components/ic-data-table/ic-data-table.js.map +1 -1
- package/dist/collection/components/ic-data-table/story-data.js +7 -0
- package/dist/collection/components/ic-data-table/story-data.js.map +1 -1
- package/dist/collection/components/ic-data-table/test/basic/ic-data-table.spec.js +17 -0
- package/dist/collection/components/ic-data-table/test/basic/ic-data-table.spec.js.map +1 -1
- package/dist/collection/components/ic-date-input/ic-date-input.css +8 -0
- package/dist/collection/components/ic-date-input/ic-date-input.js +2 -1
- package/dist/collection/components/ic-date-input/ic-date-input.js.map +1 -1
- package/dist/collection/components/ic-date-picker/ic-date-picker.css +1 -0
- package/dist/collection/components/ic-pagination-bar/ic-pagination-bar.css +8 -7
- package/dist/collection/components/ic-pagination-bar/ic-pagination-bar.js +64 -32
- package/dist/collection/components/ic-pagination-bar/ic-pagination-bar.js.map +1 -1
- package/dist/collection/components/ic-tree-item/ic-tree-item.css +14 -21
- package/dist/collection/components/ic-tree-item/ic-tree-item.js +30 -31
- package/dist/collection/components/ic-tree-item/ic-tree-item.js.map +1 -1
- package/dist/collection/components/ic-tree-view/ic-tree-view.css +8 -9
- package/dist/collection/components/ic-tree-view/ic-tree-view.js +36 -36
- package/dist/collection/components/ic-tree-view/ic-tree-view.js.map +1 -1
- package/dist/collection/utils/types.js.map +1 -1
- package/dist/components/helpers2.js +1 -1
- package/dist/components/helpers2.js.map +1 -1
- package/dist/components/ic-accordion-group.js +11 -11
- package/dist/components/ic-accordion-group.js.map +1 -1
- package/dist/components/ic-accordion.js +5 -5
- package/dist/components/ic-accordion.js.map +1 -1
- package/dist/components/ic-alert.js +8 -5
- package/dist/components/ic-alert.js.map +1 -1
- package/dist/components/ic-card-horizontal.js +22 -26
- package/dist/components/ic-card-horizontal.js.map +1 -1
- package/dist/components/ic-card-vertical.js +23 -24
- package/dist/components/ic-card-vertical.js.map +1 -1
- package/dist/components/ic-checkbox-group.js +18 -5
- package/dist/components/ic-checkbox-group.js.map +1 -1
- package/dist/components/ic-checkbox.js +5 -2
- package/dist/components/ic-checkbox.js.map +1 -1
- package/dist/components/ic-classification-banner.js +1 -1
- package/dist/components/ic-classification-banner.js.map +1 -1
- package/dist/components/ic-data-table.js +68 -11
- package/dist/components/ic-data-table.js.map +1 -1
- package/dist/components/ic-date-input2.js +3 -2
- package/dist/components/ic-date-input2.js.map +1 -1
- package/dist/components/ic-date-picker.js +1 -1
- package/dist/components/ic-date-picker.js.map +1 -1
- package/dist/components/ic-dialog.js +4 -1
- package/dist/components/ic-dialog.js.map +1 -1
- package/dist/components/ic-divider2.js +86 -9
- package/dist/components/ic-divider2.js.map +1 -1
- package/dist/components/ic-footer-link-group.js +1 -1
- package/dist/components/ic-footer-link-group.js.map +1 -1
- package/dist/components/ic-footer-link.js +1 -1
- package/dist/components/ic-footer-link.js.map +1 -1
- package/dist/components/ic-footer.js +1 -1
- package/dist/components/ic-footer.js.map +1 -1
- package/dist/components/ic-hero.js +1 -1
- package/dist/components/ic-hero.js.map +1 -1
- package/dist/components/ic-horizontal-scroll2.js +3 -2
- package/dist/components/ic-horizontal-scroll2.js.map +1 -1
- package/dist/components/ic-input-component-container2.js +1 -1
- package/dist/components/ic-input-component-container2.js.map +1 -1
- package/dist/components/ic-input-label2.js +1 -1
- package/dist/components/ic-input-label2.js.map +1 -1
- package/dist/components/ic-input-validation2.js +1 -1
- package/dist/components/ic-input-validation2.js.map +1 -1
- package/dist/components/ic-menu-group.js +1 -1
- package/dist/components/ic-menu-group.js.map +1 -1
- package/dist/components/ic-menu-item2.js +10 -10
- package/dist/components/ic-menu-item2.js.map +1 -1
- package/dist/components/ic-menu2.js +4 -3
- package/dist/components/ic-menu2.js.map +1 -1
- package/dist/components/ic-navigation-group.js +3 -2
- package/dist/components/ic-navigation-group.js.map +1 -1
- package/dist/components/ic-navigation-item.js +30 -2
- package/dist/components/ic-navigation-item.js.map +1 -1
- package/dist/components/ic-pagination-bar2.js +26 -11
- package/dist/components/ic-pagination-bar2.js.map +1 -1
- package/dist/components/ic-pagination-item2.js +9 -11
- package/dist/components/ic-pagination-item2.js.map +1 -1
- package/dist/components/ic-pagination2.js +38 -15
- package/dist/components/ic-pagination2.js.map +1 -1
- package/dist/components/ic-popover-menu.js +3 -3
- package/dist/components/ic-popover-menu.js.map +1 -1
- package/dist/components/ic-radio-group.js +16 -5
- package/dist/components/ic-radio-group.js.map +1 -1
- package/dist/components/ic-radio-option.js +8 -3
- package/dist/components/ic-radio-option.js.map +1 -1
- package/dist/components/ic-search-bar.js +12 -8
- package/dist/components/ic-search-bar.js.map +1 -1
- package/dist/components/ic-select2.js.map +1 -1
- package/dist/components/ic-side-navigation.js +3 -2
- package/dist/components/ic-side-navigation.js.map +1 -1
- package/dist/components/ic-tab-context.js +2 -1
- package/dist/components/ic-tab-context.js.map +1 -1
- package/dist/components/ic-text-field2.js +1 -1
- package/dist/components/ic-text-field2.js.map +1 -1
- package/dist/components/ic-toast.js +3 -3
- package/dist/components/ic-toast.js.map +1 -1
- package/dist/components/ic-toggle-button-group.js +1 -1
- package/dist/components/ic-toggle-button-group.js.map +1 -1
- package/dist/components/ic-tree-item.js +8 -6
- package/dist/components/ic-tree-item.js.map +1 -1
- package/dist/components/ic-tree-view.js +15 -15
- package/dist/components/ic-tree-view.js.map +1 -1
- package/dist/core/core.css +125 -13
- package/dist/core/core.esm.js +1 -1
- package/dist/core/core.esm.js.map +1 -1
- package/dist/core/{p-13e01a1e.entry.js → p-00ff3a06.entry.js} +2 -2
- package/dist/core/p-00ff3a06.entry.js.map +1 -0
- package/dist/core/{p-7e1603cc.entry.js → p-01ab3a15.entry.js} +2 -2
- package/dist/core/p-01ab3a15.entry.js.map +1 -0
- package/dist/core/p-1d24a02a.entry.js +2 -0
- package/dist/core/{p-dcccd9c1.entry.js.map → p-1d24a02a.entry.js.map} +1 -1
- package/dist/core/p-235b461f.entry.js +2 -0
- package/dist/core/p-235b461f.entry.js.map +1 -0
- package/dist/core/p-2873f871.entry.js +2 -0
- package/dist/core/p-2873f871.entry.js.map +1 -0
- package/dist/core/p-2f4bec06.entry.js +2 -0
- package/dist/core/p-2f4bec06.entry.js.map +1 -0
- package/dist/core/p-350074d4.entry.js +2 -0
- package/dist/core/p-350074d4.entry.js.map +1 -0
- package/dist/core/{p-5cfb5821.entry.js → p-39101ffc.entry.js} +2 -2
- package/dist/core/{p-5cfb5821.entry.js.map → p-39101ffc.entry.js.map} +1 -1
- package/dist/core/p-3b0fae40.entry.js +2 -0
- package/dist/core/p-3b0fae40.entry.js.map +1 -0
- package/dist/core/p-42f1b9cc.entry.js +2 -0
- package/dist/core/p-42f1b9cc.entry.js.map +1 -0
- package/dist/core/p-53228014.entry.js +2 -0
- package/dist/core/p-53228014.entry.js.map +1 -0
- package/dist/core/p-574355c9.entry.js +2 -0
- package/dist/core/p-574355c9.entry.js.map +1 -0
- package/dist/core/p-5af1273f.entry.js +2 -0
- package/dist/core/p-5af1273f.entry.js.map +1 -0
- package/dist/core/p-5eecd3fc.entry.js +2 -0
- package/dist/core/p-5eecd3fc.entry.js.map +1 -0
- package/dist/core/{p-51ea45cb.entry.js → p-606ad46f.entry.js} +2 -2
- package/dist/core/p-606ad46f.entry.js.map +1 -0
- package/dist/core/{p-a4439688.entry.js → p-620b758c.entry.js} +2 -2
- package/dist/core/p-637035c3.entry.js +2 -0
- package/dist/core/p-637035c3.entry.js.map +1 -0
- package/dist/core/p-72210cd4.entry.js +2 -0
- package/dist/core/p-72210cd4.entry.js.map +1 -0
- package/dist/core/p-7c3c080a.entry.js +2 -0
- package/dist/core/p-7c3c080a.entry.js.map +1 -0
- package/dist/core/p-7c663d4a.entry.js +2 -0
- package/dist/core/p-7c663d4a.entry.js.map +1 -0
- package/dist/core/p-7c6710f8.entry.js +2 -0
- package/dist/core/p-7c6710f8.entry.js.map +1 -0
- package/dist/core/{p-c6a62d1b.entry.js → p-80dee118.entry.js} +2 -2
- package/dist/core/p-80dee118.entry.js.map +1 -0
- package/dist/core/p-85d51975.entry.js +2 -0
- package/dist/core/p-85d51975.entry.js.map +1 -0
- package/dist/core/{p-044689ef.entry.js → p-8ffdd236.entry.js} +2 -2
- package/dist/core/p-8ffdd236.entry.js.map +1 -0
- package/dist/core/p-97953d8b.entry.js +2 -0
- package/dist/core/p-97953d8b.entry.js.map +1 -0
- package/dist/core/p-9a62c3b8.entry.js +2 -0
- package/dist/core/p-9a62c3b8.entry.js.map +1 -0
- package/dist/core/p-a22d335b.entry.js +2 -0
- package/dist/core/p-a22d335b.entry.js.map +1 -0
- package/dist/core/p-a22e5356.entry.js +2 -0
- package/dist/core/p-a22e5356.entry.js.map +1 -0
- package/dist/core/p-b03218df.entry.js +2 -0
- package/dist/core/p-b03218df.entry.js.map +1 -0
- package/dist/core/p-c1feb2b2.entry.js +2 -0
- package/dist/core/p-c1feb2b2.entry.js.map +1 -0
- package/dist/core/p-c883b5c1.entry.js +2 -0
- package/dist/core/p-c883b5c1.entry.js.map +1 -0
- package/dist/core/p-dcbfc485.entry.js +2 -0
- package/dist/core/p-dcbfc485.entry.js.map +1 -0
- package/dist/core/{p-44ee5375.entry.js → p-e3e0cf46.entry.js} +2 -2
- package/dist/core/p-e3e0cf46.entry.js.map +1 -0
- package/dist/core/{p-89be0a21.js → p-e6a330e4.js} +2 -2
- package/dist/core/p-e6a330e4.js.map +1 -0
- package/dist/core/{p-94416b6b.entry.js → p-e7b6d9c5.entry.js} +2 -2
- package/dist/core/{p-94416b6b.entry.js.map → p-e7b6d9c5.entry.js.map} +1 -1
- package/dist/core/p-ea3e2419.entry.js +2 -0
- package/dist/core/p-ea3e2419.entry.js.map +1 -0
- package/dist/core/{p-94141606.entry.js → p-f32ab3de.entry.js} +2 -2
- package/dist/core/p-f32ab3de.entry.js.map +1 -0
- package/dist/core/p-f3f9acbb.entry.js +2 -0
- package/dist/core/p-f3f9acbb.entry.js.map +1 -0
- package/dist/esm/core.js +1 -1
- package/dist/esm/{helpers-a7b13f5a.js → helpers-1e2516ae.js} +2 -2
- package/dist/esm/helpers-1e2516ae.js.map +1 -0
- package/dist/esm/ic-accordion-group.entry.js +9 -9
- package/dist/esm/ic-accordion-group.entry.js.map +1 -1
- package/dist/esm/ic-accordion.entry.js +4 -4
- package/dist/esm/ic-accordion.entry.js.map +1 -1
- package/dist/esm/ic-alert.entry.js +6 -4
- package/dist/esm/ic-alert.entry.js.map +1 -1
- package/dist/esm/ic-card-horizontal.entry.js +22 -27
- package/dist/esm/ic-card-horizontal.entry.js.map +1 -1
- package/dist/esm/ic-card-vertical.entry.js +22 -24
- package/dist/esm/ic-card-vertical.entry.js.map +1 -1
- package/dist/esm/ic-checkbox-group.entry.js +15 -4
- package/dist/esm/ic-checkbox-group.entry.js.map +1 -1
- package/dist/esm/ic-checkbox.entry.js +4 -2
- package/dist/esm/ic-checkbox.entry.js.map +1 -1
- package/dist/esm/ic-classification-banner.entry.js +1 -1
- package/dist/esm/ic-classification-banner.entry.js.map +1 -1
- package/dist/esm/ic-data-table-title-bar.entry.js +1 -1
- package/dist/esm/ic-data-table.entry.js +66 -11
- package/dist/esm/ic-data-table.entry.js.map +1 -1
- package/dist/esm/ic-date-input.entry.js +4 -3
- package/dist/esm/ic-date-input.entry.js.map +1 -1
- package/dist/esm/ic-date-picker.entry.js +2 -2
- package/dist/esm/ic-date-picker.entry.js.map +1 -1
- package/dist/esm/ic-dialog.entry.js +3 -1
- package/dist/esm/ic-dialog.entry.js.map +1 -1
- package/dist/esm/ic-divider.entry.js +72 -8
- package/dist/esm/ic-divider.entry.js.map +1 -1
- package/dist/esm/ic-empty-state_2.entry.js +23 -9
- package/dist/esm/ic-empty-state_2.entry.js.map +1 -1
- package/dist/esm/ic-footer-link-group.entry.js +1 -1
- package/dist/esm/ic-footer-link-group.entry.js.map +1 -1
- package/dist/esm/ic-footer-link.entry.js +1 -1
- package/dist/esm/ic-footer-link.entry.js.map +1 -1
- package/dist/esm/ic-footer.entry.js +1 -1
- package/dist/esm/ic-footer.entry.js.map +1 -1
- package/dist/esm/ic-hero.entry.js +1 -1
- package/dist/esm/ic-hero.entry.js.map +1 -1
- package/dist/esm/ic-horizontal-scroll.entry.js +3 -2
- package/dist/esm/ic-horizontal-scroll.entry.js.map +1 -1
- package/dist/esm/ic-input-component-container_3.entry.js +5 -4
- package/dist/esm/ic-input-component-container_3.entry.js.map +1 -1
- package/dist/esm/ic-input-label_2.entry.js +2 -2
- package/dist/esm/ic-input-label_2.entry.js.map +1 -1
- package/dist/esm/ic-menu-group.entry.js +1 -1
- package/dist/esm/ic-menu-group.entry.js.map +1 -1
- package/dist/esm/ic-menu-item.entry.js +9 -9
- package/dist/esm/ic-menu-item.entry.js.map +1 -1
- package/dist/esm/ic-navigation-group.entry.js +3 -2
- package/dist/esm/ic-navigation-group.entry.js.map +1 -1
- package/dist/esm/ic-navigation-item.entry.js +29 -2
- package/dist/esm/ic-navigation-item.entry.js.map +1 -1
- package/dist/esm/ic-pagination_4.entry.js +44 -25
- package/dist/esm/ic-pagination_4.entry.js.map +1 -1
- package/dist/esm/ic-popover-menu.entry.js +3 -3
- package/dist/esm/ic-popover-menu.entry.js.map +1 -1
- package/dist/esm/ic-radio-group.entry.js +13 -4
- package/dist/esm/ic-radio-group.entry.js.map +1 -1
- package/dist/esm/ic-radio-option.entry.js +7 -3
- package/dist/esm/ic-radio-option.entry.js.map +1 -1
- package/dist/esm/ic-search-bar.entry.js +11 -8
- package/dist/esm/ic-search-bar.entry.js.map +1 -1
- package/dist/esm/ic-side-navigation.entry.js +3 -2
- package/dist/esm/ic-side-navigation.entry.js.map +1 -1
- package/dist/esm/ic-tab-context.entry.js +2 -1
- package/dist/esm/ic-tab-context.entry.js.map +1 -1
- package/dist/esm/ic-toast.entry.js +3 -3
- package/dist/esm/ic-toast.entry.js.map +1 -1
- package/dist/esm/ic-toggle-button-group.entry.js +1 -1
- package/dist/esm/ic-toggle-button-group.entry.js.map +1 -1
- package/dist/esm/ic-tree-item.entry.js +8 -6
- package/dist/esm/ic-tree-item.entry.js.map +1 -1
- package/dist/esm/ic-tree-view.entry.js +13 -13
- package/dist/esm/ic-tree-view.entry.js.map +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/ic-card-horizontal/ic-card-horizontal.d.ts +6 -2
- package/dist/types/components/ic-data-table/ic-data-table.d.ts +11 -0
- package/dist/types/components/ic-data-table/story-data.d.ts +1 -0
- package/dist/types/components/ic-pagination-bar/ic-pagination-bar.d.ts +10 -5
- package/dist/types/components/ic-tree-item/ic-tree-item.d.ts +6 -5
- package/dist/types/components/ic-tree-view/ic-tree-view.d.ts +7 -6
- package/dist/types/components.d.ts +54 -21
- package/dist/types/utils/types.d.ts +3 -1
- package/hydrate/index.js +430 -201
- package/package.json +3 -3
- package/dist/core/p-044689ef.entry.js.map +0 -1
- package/dist/core/p-095da817.entry.js +0 -2
- package/dist/core/p-095da817.entry.js.map +0 -1
- package/dist/core/p-13e01a1e.entry.js.map +0 -1
- package/dist/core/p-1ae71507.entry.js +0 -2
- package/dist/core/p-1ae71507.entry.js.map +0 -1
- package/dist/core/p-2200ca85.entry.js +0 -2
- package/dist/core/p-2200ca85.entry.js.map +0 -1
- package/dist/core/p-2257f5e8.entry.js +0 -2
- package/dist/core/p-2257f5e8.entry.js.map +0 -1
- package/dist/core/p-266098ee.entry.js +0 -2
- package/dist/core/p-266098ee.entry.js.map +0 -1
- package/dist/core/p-283a2274.entry.js +0 -2
- package/dist/core/p-283a2274.entry.js.map +0 -1
- package/dist/core/p-42f88966.entry.js +0 -2
- package/dist/core/p-42f88966.entry.js.map +0 -1
- package/dist/core/p-44ee5375.entry.js.map +0 -1
- package/dist/core/p-48a78218.entry.js +0 -2
- package/dist/core/p-48a78218.entry.js.map +0 -1
- package/dist/core/p-4e316ae5.entry.js +0 -2
- package/dist/core/p-4e316ae5.entry.js.map +0 -1
- package/dist/core/p-51ea45cb.entry.js.map +0 -1
- package/dist/core/p-5458d818.entry.js +0 -2
- package/dist/core/p-5458d818.entry.js.map +0 -1
- package/dist/core/p-5ad1a7fb.entry.js +0 -2
- package/dist/core/p-5ad1a7fb.entry.js.map +0 -1
- package/dist/core/p-5b061abc.entry.js +0 -2
- package/dist/core/p-5b061abc.entry.js.map +0 -1
- package/dist/core/p-6fd89ed5.entry.js +0 -2
- package/dist/core/p-6fd89ed5.entry.js.map +0 -1
- package/dist/core/p-7e1603cc.entry.js.map +0 -1
- package/dist/core/p-7e5b0fff.entry.js +0 -2
- package/dist/core/p-7e5b0fff.entry.js.map +0 -1
- package/dist/core/p-86b608b5.entry.js +0 -2
- package/dist/core/p-86b608b5.entry.js.map +0 -1
- package/dist/core/p-89be0a21.js.map +0 -1
- package/dist/core/p-94141606.entry.js.map +0 -1
- package/dist/core/p-a8106c56.entry.js +0 -2
- package/dist/core/p-a8106c56.entry.js.map +0 -1
- package/dist/core/p-affd7f55.entry.js +0 -2
- package/dist/core/p-affd7f55.entry.js.map +0 -1
- package/dist/core/p-bac2beeb.entry.js +0 -2
- package/dist/core/p-bac2beeb.entry.js.map +0 -1
- package/dist/core/p-c29b2b48.entry.js +0 -2
- package/dist/core/p-c29b2b48.entry.js.map +0 -1
- package/dist/core/p-c6a62d1b.entry.js.map +0 -1
- package/dist/core/p-cfd81370.entry.js +0 -2
- package/dist/core/p-cfd81370.entry.js.map +0 -1
- package/dist/core/p-d53fb899.entry.js +0 -2
- package/dist/core/p-d53fb899.entry.js.map +0 -1
- package/dist/core/p-d5e9cf81.entry.js +0 -2
- package/dist/core/p-d5e9cf81.entry.js.map +0 -1
- package/dist/core/p-dcccd9c1.entry.js +0 -2
- package/dist/core/p-edfd0946.entry.js +0 -2
- package/dist/core/p-edfd0946.entry.js.map +0 -1
- package/dist/core/p-f1842a68.entry.js +0 -2
- package/dist/core/p-f1842a68.entry.js.map +0 -1
- package/dist/core/p-f8c1d7e8.entry.js +0 -2
- package/dist/core/p-f8c1d7e8.entry.js.map +0 -1
- package/dist/core/p-fc2f336d.entry.js +0 -2
- package/dist/core/p-fc2f336d.entry.js.map +0 -1
- package/dist/esm/helpers-a7b13f5a.js.map +0 -1
- /package/dist/core/{p-a4439688.entry.js.map → p-620b758c.entry.js.map} +0 -0
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["icDataTableCss","DataTable","this","DENSITY_HEIGHT_MULTIPLIER","dense","default","spacious","DENSITY_PADDING_HEIGHT_DIFF","SORT_ICONS","unsorted","unsortedIcon","ascending","ascendingIcon","descending","descendingIcon","hasLoadedForOneSecond","resizeObserver","SHOW_HIDE_STRING","SHOW_HIDE_CSS_CLASS","TOOLTIP_STRING","TOOLTIP","TEXT_WRAP_STRING","TEXT_WRAP_CLASS","dataUpdated","rowHeightSet","initialLoad","icPageChangeEvent","itemsPerPageChange","DATA_ROW_HEIGHT_STRING","ROW_HEIGHT_CSS_VARIABLE","DEFAULT_LINE_HEIGHT","densityUpdate","truncationPatternUpdated","isNewDebounceDelaySet","headerResizeObserver","IC_TOOLTIP_STRING","SHOW_TRUNC_TOOLTIP_STRING","runHeaderResizeObserver","ResizeObserver","headerResizeCallback","observe","el","hideColumnHeaders","columnHeaderTruncation","tableContainerWidth","shadowRoot","querySelector","clientWidth","prevTableContainerWidth","headers","querySelectorAll","forEach","header","tooltip","typographyEls","length","classList","remove","add","updateSetRowHeight","typographyEl","fontSize","parseInt","getComputedStyle","document","documentElement","cellContainer","getCellContainer","rowHeight","parseFloat","getAttribute","scrollHeight","style","removeProperty","getTypographyElements","debounceDataTruncation","contains","dynamicDebounce","dataTruncation","setNewDebounceDelay","debounceDelay","delay","getLines","height","Math","floor","truncate","clientHeight","closest","truncationPattern","addTooltipTruncation","addShowHideTruncation","setAttribute","appendChild","isEmptyString","resetShowHideTruncation","getTooltip","showHideBtn","truncWrapper","getTruncWrapper","removeTooltip","removeTextWrap","tableCell","deleteTextWrapDataKey","array","Array","isArray","val","textWrap","startLoadingTimer","timerStarted","Date","now","setTimeout","minimumLoadingDisplayDuration","isObject","value","notDefaultDensity","density","getCellContent","cell","dataType","undefined","toLocaleDateString","getCellAlignment","alignment","Object","keys","includes","getObjectValue","getCellOptions","key","createUpdatingIndicator","appearance","description","max","min","progress","monochrome","updatingOptions","h","colSpan","columns","class","theme","fullWidth","type","size","setRowHeight","pxToRem","setTruncationClass","getColumnWidth","columnWidth","columnWidthStyling","assign","minWidth","maxWidth","getRowHeight","currentRowHeight","columnProps","rowTextWrap","createCells","row","rowIndex","rowValues","values","rowKeys","rowOptions","getRowOptions","rowAlignment","rowEmphasis","headerIndex","indexOf","variableRowHeightVal","_a","variableRowHeight","call","index","globalRowHeight","map","cellSlotName","hasIcon","cellValue","scope","stickyRowHeaders","innerHTML","isSlotUsed","columnAlignment","vertical","_b","_c","_d","_e","horizontal","_f","_g","_h","_j","icon","name","Fragment","_k","onAllCells","_l","_m","variant","emphasis","href","createColumnHeaders","cellAlignment","colspan","title","updating","loading","hideOnHeader","label","target","id","sortable","getSortButtonLabel","onClick","sortRows","sortedColumn","sortedColumnOrder","onRowClick","selectedRow","createRows","data","showPagination","slice","fromRow","toRow","organisedData","slottedColumns","filter","col","addDataToPosition","sort","getSortFunction","getNextSortOption","option","sortOrders","sortOptions","sortOption","getComparison","targetRow","comparisonRow","targetRowValue","comparisonRowValue","find","valueOf","String","localeCompare","numeric","sensitivity","a","b","column","sortButton","previousSortedButton","nextSortOrderIndex","tableSorted","icSortChange","emit","columnName","sorted","from","updateTruncationTooltip","removeTooltipOnly","regenerateTooltip","updateScrollOffset","scrollOffset","scrollTop","setTableDimensions","tableHostDimensions","width","fixCellTooltips","elements","element","slotElements","getSlotElements","slottedEl","tooltipEl","tagName","setExternalPopperProps","strategy","itemsPerPageOptions","rangeLabelType","showItemsPerPageControl","showGoToPageControl","itemLabel","pageLabel","hideRangeLabel","hideAllFromItemsPerPage","defaultColumn","headerTruncationChangeHandler","disconnectedCallback","disconnect","componentWillLoad","rowsPerPage","Number","paginationBarOptions","previousRowsPerPage","loadingOptions","showBackground","previousItemsPerPage","componentDidLoad","tableElement","tableContainer","checkResizeObserver","scrollable","showLoadingIndicator","componentDidUpdate","truncateUpdatedData","componentDidRender","createShowHideTruncation","resetTruncation","then","removeAttribute","hasAutoRowHeight","setProperty","allRows","newRows","checkMaxLines","setShowHideExpanded","addLineClampCSS","createTruncationTooltip","handleTypographyTruncationExpandToggle","detail","expanded","getPropertyValue","handlePageChange","parentElement","tableRowsContainer","previousPaginationPage","handleItemsPerPageChange","handleDensityChange","ev","clickListener","loadingHandler","newValue","truncationPatternHandler","dataHandler","newData","densityHandler","rowHeightChangeHandler","oldValue","icRowHeightChange","resetRowHeights","loadingIndicator","rowOptionsIndex","textContent","cssText","createElement","render","caption","stickyColumnHeaders","Host","tabIndex","onScroll","tableLayout","aligned","heading","labelDuration","ref","totalItems"],"sources":["src/components/ic-data-table/ic-data-table.css?tag=ic-data-table&encapsulation=shadow","src/components/ic-data-table/ic-data-table.tsx"],"sourcesContent":[":host {\n position: relative;\n display: inline-flex;\n max-height: 100%;\n width: var(--table-width, 100%);\n height: 100%;\n min-width: var(--table-min-width);\n max-width: var(--table-max-width);\n}\n\ntbody {\n vertical-align: top;\n}\n\n.table-container {\n position: relative;\n height: calc(100% - var(--ic-space-xxxs));\n display: flex;\n flex-direction: column;\n width: 100%;\n}\n\n.cell-container {\n display: flex;\n min-height: 1.5rem;\n overflow-y: hidden;\n height: var(--row-height);\n}\n\n.truncation-show-hide {\n overflow: visible;\n display: block;\n}\n\n.cell-icon.truncation-show-hide {\n display: flex;\n}\n\n.cell-container:not(.data-type-element, .truncation-show-hide) {\n overflow-x: hidden;\n}\n\nic-loading-indicator {\n position: sticky;\n top: 20px;\n}\n\nic-loading-indicator.ic-theme-dark {\n --inner-color: var(--ic-action-default-dark);\n --outer-color: var(--ic-action-neutral-light);\n --label-color: var(--ic-color-text-primary-dark);\n}\n\nic-loading-indicator.ic-theme-dark.ic-loading-indicator-monochrome {\n --inner-color: var(--ic-action-light);\n --outer-color: var(--ic-action-neutral-dark);\n --label-color: var(--ic-color-text-inverse-dark);\n}\n\n.table-row-container {\n position: relative;\n height: 100%;\n overflow: auto;\n transition: var(--ic-easing-transition-fast);\n overflow-anchor: none;\n}\n\n:host([show-pagination=\"true\"]) .table-row-container {\n height: calc(100% - 3.5625rem);\n}\n\ntable {\n table-layout: var(--table-layout, \"fixed\");\n border-spacing: 0;\n width: 100%;\n height: var(--table-height, auto);\n}\n\n.table-row-container:focus {\n outline: none;\n box-shadow: var(--ic-border-focus);\n border-radius: var(--ic-border-radius);\n transition: var(--ic-easing-transition-fast);\n z-index: 1;\n}\n\n:host([embedded=\"true\"]) .table-row-container {\n border: var(--ic-border-light);\n}\n\n.column-header-inner-container {\n padding: var(--ic-space-xs);\n box-sizing: border-box;\n}\n\n.column-header-inner-container ic-tooltip {\n pointer-events: none;\n}\n\n.column-header-inner-container ic-tooltip.show-trunc-tooltip {\n pointer-events: auto;\n}\n\n.column-header-inner-container ic-tooltip .column-header-text {\n --ic-line-clamp: 1;\n}\n\n.column-header-sticky {\n position: sticky;\n top: 0;\n z-index: 1;\n}\n\n.column-header-overlay {\n position: sticky;\n top: 0;\n z-index: 1;\n box-shadow: 0 0.375rem var(--ic-space-xs) calc(var(--ic-space-xxs * -1))\n rgb(0 0 0 / 20%);\n}\n\n.row-header-sticky {\n position: sticky;\n left: 0;\n}\n\n.column-header,\n.table-row {\n box-sizing: border-box;\n}\n\n.table-row-selected {\n background-color: var(--ic-table-row-selected) !important;\n}\n\n.sort-button {\n margin-left: auto;\n}\n\n.sort-button:hover {\n background-color: var(--ic-action-dark-bg-hover);\n}\n\n.sort-button:active {\n background-color: var(--ic-action-dark-bg-pressed);\n}\n\n.sort-button svg {\n color: var(--ic-architectural-black);\n}\n\n.sort-button-unsorted svg {\n color: var(--ic-color-text-tertiary);\n}\n\n.table-density-dense .column-header-inner-container,\ntd.table-density-dense {\n padding: var(--ic-space-xxs) var(--ic-space-xs) !important;\n}\n\n.text-dense {\n font-size: var(--ic-font-size-label);\n}\n\n.table-density-spacious .column-header-inner-container,\ntd.table-density-spacious {\n padding: 0.625rem var(--ic-space-xs) !important;\n}\n\n.text-spacious {\n font-size: 1.125rem;\n}\n\n.column-header-text {\n font-weight: var(--ic-font-weight-bold);\n}\n\n.dummy-column-header-text {\n white-space: nowrap;\n overflow: hidden;\n height: 0;\n width: fit-content;\n}\n\n.row-header,\n.column-header {\n text-align: left;\n padding: var(--ic-space-xs);\n background-color: var(--ic-architectural-40);\n border-right: var(--ic-border-light);\n border-bottom: var(--ic-border-light);\n}\n\n.column-header {\n padding: 0;\n width: var(--column-width);\n min-width: var(--column-min-width, 4rem);\n max-width: var(--column-max-width);\n}\n\n.column-header:last-child {\n border-right: none;\n}\n\n.scrollable .column-header:last-child {\n border-right: var(--ic-border-light) !important;\n}\n\n:host([embedded=\"true\"]) tr:last-child .table-cell,\n:host([embedded=\"true\"]) tr:last-child .row-header {\n border-bottom: none;\n}\n\n.column-header-alignment-left,\n.row-header-alignment-left,\n.cell-alignment-left {\n text-align: left !important;\n justify-content: start !important;\n}\n\n.column-header-alignment-right,\n.row-header-alignment-right,\n.cell-alignment-right {\n text-align: right !important;\n justify-content: end !important;\n}\n\n.cell-alignment-right.truncation-tooltip ic-tooltip ic-typography {\n padding-right: calc(var(--ic-space-xxs) + var(--ic-space-xs));\n}\n\n.cell-alignment-right.truncation-show-hide ic-typography {\n --ellipsis-padding-right: calc(var(--ic-space-xxs) + var(--ic-space-xs));\n}\n\n.column-header-alignment-center,\n.row-header-alignment-center,\n.cell-alignment-center {\n text-align: center !important;\n justify-content: center !important;\n}\n\n.table-row:nth-child(even) {\n background-color: var(--ic-architectural-20);\n}\n\n.table-cell {\n padding: var(--ic-space-xs);\n border-bottom: solid var(--ic-architectural-100) var(--ic-space-1px);\n overflow: hidden;\n box-sizing: border-box;\n max-width: var(--column-max-width);\n min-width: var(--column-min-width);\n}\n\n.table-cell.with-overflow {\n overflow: visible;\n}\n\n.data-type-string,\n.data-type-address {\n text-align: left;\n vertical-align: top;\n}\n\n.data-type-number,\n.data-type-date {\n text-align: right;\n justify-content: end;\n vertical-align: top;\n}\n\n.cell-alignment-top {\n vertical-align: top;\n align-items: flex-start;\n}\n\n.cell-alignment-middle {\n vertical-align: middle;\n align-items: center;\n}\n\n.cell-alignment-bottom {\n vertical-align: bottom;\n align-items: flex-end;\n}\n\n.cell-emphasis-low {\n --ic-typography-color: var(--ic-color-text-secondary);\n}\n\n.cell-emphasis-high {\n font-weight: var(--ic-font-weight-bold);\n}\n\n.pagination-container {\n background-color: var(--ic-architectural-40);\n border-top: var(--ic-border-light);\n}\n\n.screen-reader-sort-text,\n.table-caption {\n position: absolute;\n left: -100rem;\n}\n\n.table-cell,\n.column-header,\n.row-header {\n word-wrap: break-word;\n white-space: pre-wrap;\n}\n\n.loading-empty {\n padding: var(--ic-space-xl) var(--ic-space-xxl);\n margin-top: var(--ic-space-xl);\n}\n\n.updating-state {\n padding: 0;\n border-bottom: var(--ic-border-light);\n}\n\n.updating-state-headers {\n border-bottom: none;\n}\n\n.loading {\n position: absolute;\n left: calc(50% - 5.9741rem);\n opacity: 0;\n transition: opacity var(--ic-transition-duration-slow);\n}\n\n.loading.show-background {\n background-color: var(--ic-architectural-white);\n border: var(--ic-border-light);\n}\n\n.loading.show {\n opacity: 1;\n}\n\n.icon,\n::slotted(svg) {\n height: var(--ic-space-lg);\n width: var(--ic-space-lg);\n margin-right: var(--ic-space-xxs);\n}\n\n.column-header-alignment-right > .icon,\n.row-header-alignment-right > .icon,\n.cell-alignment-right > .icon,\n.column-header-alignment-right > ::slotted(svg),\n.row-header-alignment-right > ::slotted(svg),\n.cell-alignment-right > ::slotted(svg) {\n margin-right: auto;\n}\n\n.column-header-alignment-center > ic-typography,\n.row-header-alignment-right > ic-typography,\n.cell-alignment-center > ic-typography {\n flex: 1;\n}\n\n.icon > svg {\n height: var(--ic-space-lg);\n width: var(--ic-space-lg);\n display: inline-block;\n}\n\n.truncation-tooltip ic-typography {\n display: -webkit-box;\n -webkit-line-clamp: var(--ic-line-clamp, 0);\n -webkit-box-orient: vertical;\n overflow: hidden;\n}\n\n.truncation-tooltip ic-typography,\n.truncation-show-hide ic-typography {\n white-space: normal;\n}\n\n.ic-tooltip-overflow {\n overflow: hidden;\n width: 100%;\n}\n\n@media screen and (min-width: 577px) {\n .column-header-inner-container {\n display: flex;\n align-items: center;\n }\n}\n","/* eslint-disable @typescript-eslint/no-explicit-any */\nimport {\n Component,\n Element,\n h,\n Prop,\n State,\n Listen,\n Watch,\n Fragment,\n Method,\n Event,\n EventEmitter,\n Host,\n} from \"@stencil/core\";\nimport unsortedIcon from \"./assets/unsorted-icon.svg\";\nimport ascendingIcon from \"./assets/ascending-icon.svg\";\nimport descendingIcon from \"./assets/descending-icon.svg\";\nimport {\n IcDataTableDataType,\n IcDataTableColumnDataTypes,\n IcDataTableColumnObject,\n IcDataTableColumnWidthTypes,\n IcDataTableDensityOptions,\n IcDataTableRowHeights,\n IcDataTableSortOrderOptions,\n IcDataTableTruncationTypes,\n IcDensityUpdateEventDetail,\n IcSortEventDetail,\n} from \"./ic-data-table.types\";\nimport { IcThemeForegroundNoDefault } from \"@ukic/web-components/dist/types/utils/types\";\nimport { IcPaginationBarOptions } from \"../../utils/types\";\n// Unable to import helper functions via @ukic/web-components\nimport {\n isEmptyString,\n isSlotUsed,\n pxToRem,\n addDataToPosition,\n dynamicDebounce,\n getSlotElements,\n checkResizeObserver,\n} from \"../../utils/helpers\";\n\n/**\n * @slot empty-state - Content is slotted below the table header when there is no data and the table is not loading.\n * @slot {COLUMN_KEY}-{ROW_INDEX}[-icon] - Each cell should have its own slot, named using the column tag and the row index, allowing for custom elements to be displayed. Include `-icon` at the end for that cell's icon slot.\n * @slot {COLUMN_KEY}-column-icon - The icon slot for a column header.\n * @slot title-bar - A custom ic-data-table-title-bar can be slotted above the column headers to display additional information about the table.\n * @slot pagination-bar - A custom ic-pagination-bar can be slotted below the data to provide enhanced control over how the data is interacted with when being fetched externally.\n */\n@Component({\n tag: \"ic-data-table\",\n styleUrl: \"ic-data-table.css\",\n shadow: true,\n})\nexport class DataTable {\n private DENSITY_HEIGHT_MULTIPLIER = {\n dense: 0.8,\n default: 1,\n spacious: 1.2,\n };\n\n private DENSITY_PADDING_HEIGHT_DIFF = {\n dense: 8,\n default: 16,\n spacious: 20,\n };\n\n private SORT_ICONS = {\n unsorted: unsortedIcon,\n ascending: ascendingIcon,\n descending: descendingIcon,\n };\n\n private hasLoadedForOneSecond = true;\n private loadingIndicator: HTMLIcLoadingIndicatorElement;\n private timerStarted: number;\n private resizeObserver: ResizeObserver = null;\n private SHOW_HIDE_STRING = \"show-hide\";\n private SHOW_HIDE_CSS_CLASS = `${this.SHOW_HIDE_STRING}-wrap`;\n private TOOLTIP_STRING = \"tooltip\";\n private TOOLTIP = `ic-${this.TOOLTIP_STRING}`;\n private TEXT_WRAP_STRING = \"text-wrap\";\n private TEXT_WRAP_CLASS = `.${this.TEXT_WRAP_STRING}`;\n private dataUpdated = false;\n private tableSorted: boolean;\n private rowHeightSet = false;\n private initialLoad = false;\n private icPageChangeEvent = false;\n private itemsPerPageChange = false;\n private DATA_ROW_HEIGHT_STRING = \"data-row-height\";\n private ROW_HEIGHT_CSS_VARIABLE = \"--row-height\";\n private previousItemsPerPage: number;\n private DEFAULT_LINE_HEIGHT = 24;\n private densityUpdate = false;\n private previousPaginationPage: number;\n private truncationPatternUpdated: boolean = false;\n private isNewDebounceDelaySet = false;\n private headerResizeObserver: ResizeObserver = null;\n private prevTableContainerWidth: number;\n private IC_TOOLTIP_STRING = \"ic-tooltip\";\n private SHOW_TRUNC_TOOLTIP_STRING = \"show-trunc-tooltip\";\n\n @Element() el: HTMLIcDataTableElement;\n\n @State() fromRow: number = 0;\n\n @State() previousRowsPerPage: number;\n\n @State() rowsPerPage: number;\n\n @State() scrollable: boolean = false;\n\n @State() scrollOffset: number = 0;\n\n @State() selectedRow: object;\n\n @State() sortedColumn: string;\n\n @State() sortedColumnOrder: IcDataTableSortOrderOptions;\n\n @State() toRow: number;\n\n @State() currentRowHeight: number;\n\n @State() debounceDelay = 0;\n\n /**\n * The title for the table only visible to screen readers.\n */\n @Prop() caption!: string;\n\n /**\n * Determines whether the column header should be truncated and display a tooltip. Default is `false`.\n */\n @Prop() columnHeaderTruncation: boolean = false;\n\n @Watch(\"columnHeaderTruncation\")\n headerTruncationChangeHandler(): void {\n if (this.columnHeaderTruncation) {\n this.prevTableContainerWidth = 0;\n } else {\n const headers = this.el.shadowRoot.querySelectorAll(\"th.column-header\");\n headers.forEach((header) => {\n const tooltip = header.querySelector(this.IC_TOOLTIP_STRING);\n if (tooltip) {\n tooltip.classList.remove(this.SHOW_TRUNC_TOOLTIP_STRING);\n }\n });\n }\n }\n\n /**\n * The column headers for the table.\n */\n @Prop() columns!: IcDataTableColumnObject[];\n\n /**\n * The row content for the table.\n */\n @Prop() data: IcDataTableDataType[];\n\n /**\n * Set the density of the table including font and padding.\n */\n @Prop({ mutable: true }) density?: IcDataTableDensityOptions = \"default\";\n\n /**\n * Applies a border to the table container.\n */\n @Prop() embedded?: boolean = false;\n\n /**\n * Sets the row height on all rows in the table that aren't set using the `variableRowHeight` method.\n */\n @Prop({ mutable: true }) globalRowHeight?: IcDataTableRowHeights = \"auto\";\n\n /**\n * Sets the table height. Can be set to `auto` or a specific value in `px`, `rem`, or `%`.\n */\n @Prop() height?: string;\n\n /**\n * If `true`, column headers will not be visible.\n */\n @Prop() hideColumnHeaders?: boolean = false;\n\n /**\n * When set to `true`, the full table will show a loading state, featuring a radial indicator.\n */\n @Prop({ mutable: true }) loading?: boolean = false;\n\n /**\n * Sets the props for the circular loading indicator used in the loading state.\n */\n @Prop() loadingOptions?: {\n appearance?: IcThemeForegroundNoDefault;\n description?: string;\n label?: string;\n labelDuration?: number;\n max?: number;\n min?: number;\n progress?: number;\n showBackground?: boolean;\n monochrome?: boolean;\n };\n\n /**\n * Sets the maximum width of the data table. Can be set in `px`, `rem`, or `%`.\n */\n @Prop() maxWidth?: string;\n\n /**\n * Sets the minimum width of the data table. Can be set in `px`, `rem`, or `%`.\n */\n @Prop() minWidth?: string;\n\n /**\n * The minimum amount of time the `loading` state displays for before showing the data. Used to prevent flashing in the component.\n */\n @Prop() minimumLoadingDisplayDuration?: number = 1000;\n\n /**\n * Sets the props for the built-in pagination bar. If the `pagination-bar` slot is used then this prop is ignored.\n */\n @Prop() paginationBarOptions?: IcPaginationBarOptions = {\n itemsPerPageOptions: [\n { label: \"10\", value: \"10\" },\n { label: \"25\", value: \"25\" },\n { label: \"50\", value: \"50\" },\n ],\n rangeLabelType: \"page\",\n type: \"simple\",\n showItemsPerPageControl: true,\n showGoToPageControl: true,\n alignment: \"right\",\n itemLabel: \"Item\",\n pageLabel: \"Page\",\n hideRangeLabel: false,\n hideAllFromItemsPerPage: false,\n theme: \"inherit\",\n monochrome: false,\n };\n\n /**\n * If `true`, adds a pagination bar to the bottom of the table.\n */\n @Prop() showPagination?: boolean = false;\n\n /**\n * If `true`, allows table columns to be sorted using applied sort buttons.\n */\n @Prop() sortable?: boolean = false;\n\n /**\n * Sets the order columns will be sorted in and allows for 'default' sorts to be added.\n */\n @Prop() sortOptions?: {\n sortOrders: IcDataTableSortOrderOptions[];\n defaultColumn?: string;\n } = {\n sortOrders: [\"unsorted\", \"ascending\", \"descending\"],\n defaultColumn: \"\",\n };\n\n /**\n * If `true`, column headers will remain at the top of the table when scrolling vertically.\n */\n @Prop() stickyColumnHeaders?: boolean = false;\n\n /**\n * If `true`, row headers will remain to the left when scrolling horizontally.\n */\n @Prop() stickyRowHeaders?: boolean = false;\n /**\n * Sets the layout of the table\n */\n @Prop() tableLayout?: \"fixed\" | \"auto\" = \"fixed\";\n\n /**\n * Sets the method used to truncate long text in cells where textWrap is `false`. The `tooltip` truncation pattern allows the overflowing text to be seen in a tooltip. The `show-hide` truncation pattern allows the overflowing text to be shown and hidden using the ic-typography \"See more\"/\"See less\" buttons.\n */\n @Prop() truncationPattern?: IcDataTableTruncationTypes;\n\n /**\n * If `true`, the table displays a linear loading indicator below the header row to indicate an updating state.\n */\n @Prop() updating?: boolean = false;\n\n /**\n * Sets the props for the linear loading indicator used in the updating state.\n */\n @Prop() updatingOptions?: {\n appearance?: IcThemeForegroundNoDefault;\n description?: string;\n max?: number;\n min?: number;\n progress?: number;\n monochrome?: boolean;\n };\n\n /**\n * Allows for custom setting of row heights on individual rows based on an individual value from the `data` prop and the row index.\n * If the function returns `null`, that row's height will be set to the `globalRowHeight` property.\n */\n @Prop({ mutable: true }) variableRowHeight?: (params: {\n [key: string]: any;\n index: number;\n }) => IcDataTableRowHeights | null;\n\n /**\n * Sets the table width. Can be set to `auto` or a specific value in `px`, `rem`, or `%`.\n */\n @Prop() width?: string;\n\n /**\n * Emitted when the `globalRowHeight` or `variableRowHeight` properties change in the data table.\n */\n @Event() icRowHeightChange: EventEmitter<void>;\n\n /**\n * Emitted when a column sort button is clicked.\n */\n @Event() icSortChange: EventEmitter<IcSortEventDetail>;\n\n disconnectedCallback(): void {\n this.resizeObserver?.disconnect();\n this.headerResizeObserver?.disconnect();\n }\n\n componentWillLoad(): void {\n this.rowsPerPage = Number(\n this.paginationBarOptions.itemsPerPageOptions[0].value\n );\n this.previousRowsPerPage = this.rowsPerPage;\n this.toRow = this.rowsPerPage;\n this.sortedColumn = this.sortOptions.defaultColumn;\n this.sortedColumnOrder = this.sortOptions.sortOrders[0];\n this.loadingOptions = {\n ...this.loadingOptions,\n showBackground: this.data?.length > 0,\n };\n this.initialLoad = true;\n this.previousItemsPerPage = this.rowsPerPage;\n }\n\n componentDidLoad(): void {\n const tableElement = this.el.shadowRoot.querySelector(\"table\");\n const tableContainer = this.el.shadowRoot.querySelector(\".table-container\");\n\n checkResizeObserver(this.runHeaderResizeObserver);\n\n if (this.dataUpdated) {\n this.dataUpdated = false;\n }\n\n if (\n tableElement?.clientHeight > tableContainer?.clientHeight ||\n tableElement?.clientWidth > tableContainer?.clientWidth\n ) {\n this.scrollable = true;\n }\n if (this.loading) {\n this.startLoadingTimer();\n this.showLoadingIndicator();\n }\n\n if (this.truncationPattern) {\n this.getTypographyElements().forEach(\n (typographyEl: HTMLIcTypographyElement) => {\n const cellContainer = this.getCellContainer(typographyEl);\n if (!cellContainer.classList.contains(this.TEXT_WRAP_STRING)) {\n this.dataTruncation(typographyEl);\n }\n }\n );\n\n this.debounceDataTruncation();\n }\n\n if (this.globalRowHeight !== \"auto\") {\n this.updateSetRowHeight();\n }\n }\n\n componentDidUpdate(): void {\n // truncation updates invoked here once new/updated data has\n // rendered to take into account updated .cell-container/ic-typography box model updates.\n if (\n this.truncationPattern === this.SHOW_HIDE_STRING ||\n this.truncationPattern === this.TOOLTIP_STRING\n ) {\n this.truncateUpdatedData();\n }\n }\n\n componentDidRender(): void {\n this.fixCellTooltips();\n }\n\n private runHeaderResizeObserver = () => {\n this.headerResizeObserver = new ResizeObserver(() => {\n this.headerResizeCallback();\n });\n this.headerResizeObserver.observe(this.el);\n };\n\n private headerResizeCallback = () => {\n if (!this.hideColumnHeaders && this.columnHeaderTruncation) {\n const tableContainerWidth =\n this.el.shadowRoot.querySelector(\".table-container\").clientWidth;\n if (tableContainerWidth !== this.prevTableContainerWidth) {\n const headers = this.el.shadowRoot.querySelectorAll(\"th.column-header\");\n headers.forEach((header) => {\n const tooltip = header.querySelector(this.IC_TOOLTIP_STRING);\n const typographyEls = header.querySelectorAll(\"ic-typography\");\n if (tooltip && typographyEls && typographyEls.length === 2) {\n tooltip.classList.remove(this.SHOW_TRUNC_TOOLTIP_STRING);\n if (typographyEls[1].clientWidth > typographyEls[0].clientWidth) {\n tooltip.classList.add(this.SHOW_TRUNC_TOOLTIP_STRING);\n }\n }\n });\n this.prevTableContainerWidth = tableContainerWidth;\n }\n }\n };\n\n private truncateUpdatedData() {\n if (this.dataUpdated) {\n if (this.truncationPattern === this.SHOW_HIDE_STRING) {\n this.getTypographyElements().forEach(\n (typographyEl: HTMLIcTypographyElement) => {\n const truncWrapper = this.getTruncWrapper(typographyEl);\n const cellContainer = this.getCellContainer(typographyEl);\n\n if (\n cellContainer?.clientHeight - this.DEFAULT_LINE_HEIGHT >=\n truncWrapper?.scrollHeight\n ) {\n this.resetShowHideTruncation(typographyEl);\n return;\n }\n\n setTimeout(() => {\n // slight delay due to data rendering\n if (typographyEl?.scrollHeight > cellContainer?.clientHeight) {\n this.addShowHideTruncation(cellContainer, typographyEl);\n }\n }, 150);\n }\n );\n }\n\n if (this.truncationPattern === this.TOOLTIP_STRING) {\n this.updateTruncationTooltip();\n }\n\n this.dataUpdated = false;\n }\n\n if (this.tableSorted) {\n if (this.truncationPattern === this.TOOLTIP_STRING) {\n this.updateTruncationTooltip();\n }\n\n if (this.truncationPattern === this.SHOW_HIDE_STRING) {\n this.getTypographyElements().forEach(\n (typographyEl: HTMLIcTypographyElement) => {\n const cellContainer = this.getCellContainer(typographyEl);\n\n if (!cellContainer.classList.contains(this.TEXT_WRAP_STRING)) {\n this.createShowHideTruncation(typographyEl, cellContainer);\n } else {\n typographyEl.resetTruncation().then(() => {\n cellContainer.removeAttribute(\"style\");\n });\n }\n }\n );\n }\n\n this.tableSorted = false;\n }\n\n // This function recalculates the tooltip truncation when the rowHeight has been set.\n // This is in componentDidUpdate so a setTimeout is not used to wait for the render to be complete\n if (this.rowHeightSet) {\n const fontSize = parseInt(\n getComputedStyle(document.documentElement).fontSize\n );\n const hasAutoRowHeight = this.globalRowHeight === \"auto\";\n\n this.getTypographyElements().forEach(\n (typographyEl: HTMLIcTypographyElement) => {\n const cellContainer = this.getCellContainer(typographyEl);\n const tooltipEl = this.getTooltip(typographyEl);\n\n if (hasAutoRowHeight) {\n cellContainer.style.height = null;\n\n if (this.truncationPattern === this.TOOLTIP_STRING) {\n this.removeTooltip(cellContainer, typographyEl, tooltipEl);\n typographyEl.setAttribute(\"style\", `--ic-line-clamp: 0`);\n } else if (this.truncationPattern === this.SHOW_HIDE_STRING) {\n this.resetShowHideTruncation(typographyEl);\n }\n\n return;\n }\n\n const rowHeight =\n fontSize *\n parseFloat(cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING));\n\n // If the set row height is bigger than the cell container even\n // with textWrap, set the row height\n if (\n !cellContainer?.style?.height &&\n rowHeight > cellContainer.clientHeight &&\n !cellContainer.classList.contains(this.TEXT_WRAP_STRING)\n ) {\n cellContainer.style.setProperty(\n this.ROW_HEIGHT_CSS_VARIABLE,\n cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING)\n );\n }\n\n if (this.truncationPattern) {\n // If the set row height is bigger than the typography truncation wrapper\n // scroll height, remove see more / see less button\n if (this.truncationPattern === this.SHOW_HIDE_STRING) {\n const truncWrapper = this.getTruncWrapper(typographyEl);\n const showHideBtn =\n typographyEl.shadowRoot.querySelector(\"button\");\n\n if (\n showHideBtn &&\n truncWrapper?.scrollHeight <= cellContainer.clientHeight\n ) {\n this.resetShowHideTruncation(typographyEl);\n return;\n }\n }\n\n this.truncate(typographyEl, cellContainer, tooltipEl);\n } else {\n this.updateSetRowHeight(typographyEl);\n }\n }\n );\n\n this.rowHeightSet = false;\n }\n\n // Only run truncation on the new rows\n // when the number of items per page has increased\n if (this.itemsPerPageChange) {\n const allRows = this.el.shadowRoot.querySelectorAll(\".table-row\");\n\n if (this.rowsPerPage > this.previousItemsPerPage) {\n const newRows = Array.from(allRows).slice(this.previousItemsPerPage);\n\n newRows.forEach((row) => {\n row\n .querySelectorAll(\"ic-typography\")\n .forEach((typographyEl: HTMLIcTypographyElement) => {\n const cellContainer = this.getCellContainer(typographyEl);\n const tooltipEl = this.getTooltip(typographyEl);\n\n this.truncate(typographyEl, cellContainer, tooltipEl);\n });\n });\n }\n\n this.previousItemsPerPage = this.rowsPerPage;\n this.itemsPerPageChange = false;\n }\n\n if (!this.initialLoad && this.icPageChangeEvent) {\n if (this.truncationPattern === this.TOOLTIP_STRING) {\n this.updateTruncationTooltip();\n }\n\n // set truncation to see more if opened and next/previous page is pressed\n if (this.truncationPattern === this.SHOW_HIDE_STRING) {\n this.getTypographyElements().forEach((typographyEl) => {\n const cellContainer = this.getCellContainer(typographyEl);\n const showHideBtn = typographyEl.shadowRoot.querySelector(\"button\");\n\n if (\n typographyEl?.scrollHeight > cellContainer.clientHeight &&\n !showHideBtn\n ) {\n this.addShowHideTruncation(cellContainer, typographyEl);\n }\n });\n }\n\n this.icPageChangeEvent = false;\n }\n\n if (this.densityUpdate) {\n this.getTypographyElements().forEach((typographyEl) => {\n const cellContainer = this.getCellContainer(typographyEl);\n const tooltipEl = this.getTooltip(typographyEl);\n\n this.truncate(typographyEl, cellContainer, tooltipEl);\n });\n\n this.densityUpdate = false;\n }\n\n if (this.truncationPatternUpdated) {\n if (this.truncationPattern === this.TOOLTIP_STRING) {\n this.getTypographyElements().forEach((typographyEl) => {\n const cellContainer = this.getCellContainer(typographyEl);\n const tooltipEl = this.getTooltip(typographyEl);\n\n if (typographyEl.scrollHeight > cellContainer.clientHeight) {\n this.addTooltipTruncation(typographyEl, cellContainer, tooltipEl);\n }\n });\n } else if (this.truncationPattern === this.SHOW_HIDE_STRING) {\n this.getTypographyElements().forEach(\n (typographyEl: HTMLIcTypographyElement) => {\n const truncWrapper = this.getTruncWrapper(typographyEl);\n const cellContainer = this.getCellContainer(typographyEl);\n\n if (\n cellContainer?.clientHeight - this.DEFAULT_LINE_HEIGHT >\n truncWrapper?.scrollHeight\n ) {\n this.resetShowHideTruncation(typographyEl);\n return;\n }\n\n if (typographyEl?.scrollHeight > cellContainer?.clientHeight) {\n this.addShowHideTruncation(cellContainer, typographyEl);\n }\n }\n );\n }\n }\n }\n\n private updateSetRowHeight = (typographyEl?: HTMLIcTypographyElement) => {\n const fontSize = parseInt(\n getComputedStyle(document.documentElement).fontSize\n );\n\n if (typographyEl) {\n const cellContainer = this.getCellContainer(typographyEl);\n\n const rowHeight =\n fontSize *\n parseFloat(cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING));\n\n if (typographyEl.scrollHeight > rowHeight) {\n cellContainer.style.removeProperty(this.ROW_HEIGHT_CSS_VARIABLE);\n }\n } else {\n this.getTypographyElements().forEach(\n (typographyEl: HTMLIcTypographyElement) => {\n const cellContainer = this.getCellContainer(typographyEl);\n\n const rowHeight =\n fontSize *\n parseFloat(cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING));\n\n if (typographyEl.scrollHeight > rowHeight) {\n cellContainer.style.removeProperty(this.ROW_HEIGHT_CSS_VARIABLE);\n }\n }\n );\n }\n };\n\n private createShowHideTruncation(\n typographyEl: HTMLIcTypographyElement,\n cellContainer: HTMLElement\n ) {\n typographyEl.checkMaxLines(typographyEl.scrollHeight);\n typographyEl.setAttribute(\n \"max-lines\",\n `${Math.floor(cellContainer?.clientHeight / this.DEFAULT_LINE_HEIGHT)}`\n );\n typographyEl.setShowHideExpanded(false);\n\n cellContainer.style.setProperty(this.ROW_HEIGHT_CSS_VARIABLE, null);\n }\n\n private debounceDataTruncation = () => {\n this.getTypographyElements().forEach(\n (typographyEl: HTMLIcTypographyElement) => {\n const cellContainer = this.getCellContainer(typographyEl);\n if (!cellContainer.classList.contains(this.TEXT_WRAP_STRING)) {\n this.resizeObserver = new ResizeObserver(\n // This gets triggered twice due to updated data and see more/see less button\n dynamicDebounce(\n () => {\n this.dataTruncation(typographyEl);\n\n if (!this.isNewDebounceDelaySet) {\n this.setNewDebounceDelay(200);\n }\n },\n () => this.debounceDelay\n ) as ResizeObserverCallback\n );\n\n this.resizeObserver.observe(typographyEl);\n }\n }\n );\n };\n\n private setNewDebounceDelay = (delay: number) => {\n this.debounceDelay = delay;\n\n this.isNewDebounceDelaySet = true;\n };\n\n private getLines = (height: number): number =>\n Math.floor(height / this.DEFAULT_LINE_HEIGHT);\n\n private truncate = (\n typographyEl: HTMLIcTypographyElement,\n cellContainer: HTMLElement,\n tooltip: HTMLIcTooltipElement\n ) => {\n if (typographyEl?.scrollHeight > cellContainer?.clientHeight) {\n //24 is the height of a single line\n if (!typographyEl.closest(this.TEXT_WRAP_CLASS)) {\n if (this.truncationPattern === this.TOOLTIP_STRING) {\n this.addTooltipTruncation(typographyEl, cellContainer, tooltip);\n }\n if (this.truncationPattern === this.SHOW_HIDE_STRING) {\n this.addShowHideTruncation(cellContainer, typographyEl);\n }\n }\n } else {\n if (this.truncationPattern === this.TOOLTIP_STRING && tooltip) {\n typographyEl.setAttribute(\"style\", `--ic-line-clamp: 0`);\n\n cellContainer.appendChild(typographyEl);\n tooltip.remove();\n }\n\n if (\n this.truncationPattern === this.SHOW_HIDE_STRING &&\n !isEmptyString(typographyEl.getAttribute(\"max-lines\"))\n ) {\n this.resetShowHideTruncation(typographyEl);\n }\n }\n };\n\n private addTooltipTruncation(\n typographyEl: HTMLIcTypographyElement,\n cellContainer: HTMLElement,\n tooltip: HTMLIcTooltipElement\n ) {\n this.addLineClampCSS(typographyEl, cellContainer);\n\n if (!tooltip) {\n this.createTruncationTooltip(typographyEl, cellContainer);\n }\n }\n\n private addShowHideTruncation(\n cellContainer: HTMLElement,\n typographyEl: HTMLIcTypographyElement\n ) {\n cellContainer.classList.add(this.SHOW_HIDE_CSS_CLASS);\n this.createShowHideTruncation(typographyEl, cellContainer);\n }\n\n private dataTruncation = (typographyEl: HTMLIcTypographyElement) => {\n // Tooltip truncation mentioned in AC. Will need revisiting\n const tooltip: HTMLIcTooltipElement = this.getTooltip(typographyEl);\n const cellContainer = this.getCellContainer(typographyEl);\n if (\n cellContainer?.classList.contains(\"data-type-element\") ||\n this.dataUpdated\n ) {\n return;\n }\n\n if (\n this.truncationPattern === this.SHOW_HIDE_STRING &&\n typographyEl.shadowRoot.querySelector(\"button\")\n ) {\n const showHideBtn = typographyEl.shadowRoot.querySelector(\"button\");\n // If the see more/see less is present and the max lines is equal to the cell container\n // remove the see more/see less button\n if (showHideBtn) {\n const truncWrapper = this.getTruncWrapper(typographyEl);\n\n if (\n this.getLines(truncWrapper.scrollHeight) ===\n +typographyEl.getAttribute(\"max-lines\")\n ) {\n this.resetShowHideTruncation(typographyEl);\n }\n }\n }\n\n // Deals with setting and resetting row height and re-truncating data\n if (this.rowHeightSet && this.truncationPattern === this.SHOW_HIDE_STRING) {\n const truncWrapper = this.getTruncWrapper(typographyEl);\n // cellContainer.clientHeight - 24 removes the extra line by see more/see less\n if (\n truncWrapper &&\n cellContainer.clientHeight - this.DEFAULT_LINE_HEIGHT >\n truncWrapper.scrollHeight\n ) {\n this.resetShowHideTruncation(typographyEl);\n return;\n }\n\n if (typographyEl.scrollHeight > cellContainer.clientHeight) {\n this.addShowHideTruncation(cellContainer, typographyEl);\n return;\n }\n }\n\n if (\n typographyEl?.scrollHeight > 0 &&\n cellContainer?.clientHeight > 0 &&\n typographyEl?.scrollHeight === cellContainer?.clientHeight\n ) {\n if (tooltip) {\n this.removeTooltip(cellContainer, typographyEl, tooltip);\n }\n return;\n }\n\n this.truncate(typographyEl, cellContainer, tooltip);\n };\n\n private getTruncWrapper(typographyEl: HTMLIcTypographyElement) {\n return typographyEl.shadowRoot.querySelector(\".trunc-wrapper\");\n }\n\n // Set the height to initial if row height is set and the show / hide truncation\n // is clicked\n @Listen(\"typographyTruncationExpandToggle\")\n handleTypographyTruncationExpandToggle({\n detail,\n }: CustomEvent<{\n expanded: boolean;\n typographyEl: HTMLIcTypographyElement;\n }>): void {\n const { expanded, typographyEl } = detail;\n const cellContainer = this.getCellContainer(typographyEl);\n\n if (\n cellContainer.style.getPropertyValue(this.ROW_HEIGHT_CSS_VARIABLE) &&\n expanded\n ) {\n cellContainer.style.setProperty(this.ROW_HEIGHT_CSS_VARIABLE, \"inherit\");\n }\n }\n\n @Listen(\"icPageChange\")\n handlePageChange({ detail, target }: CustomEvent<{ value: number }>): void {\n if ((target as HTMLIcPaginationBarElement).parentElement !== this.el) {\n this.fromRow = (detail.value - 1) * this.rowsPerPage;\n this.toRow = this.fromRow + this.rowsPerPage;\n const tableRowsContainer = this.el.shadowRoot.querySelector(\n \".table-row-container\"\n );\n if (this.previousRowsPerPage === this.rowsPerPage) {\n tableRowsContainer.scrollTop = 0;\n } else if (this.previousRowsPerPage < this.rowsPerPage) {\n tableRowsContainer.scrollTop = this.scrollOffset;\n this.previousRowsPerPage = this.rowsPerPage;\n } else {\n this.previousRowsPerPage = this.rowsPerPage;\n }\n }\n\n if (!this.initialLoad && this.previousPaginationPage !== detail.value) {\n // This is to prevent icPageChange from triggering truncation on first load\n this.icPageChangeEvent = true;\n }\n\n this.previousPaginationPage = detail.value;\n this.initialLoad = false;\n }\n\n @Listen(\"icItemsPerPageChange\")\n handleItemsPerPageChange({\n detail,\n target,\n }: CustomEvent<{ value: number }>): void {\n if ((target as HTMLIcPaginationBarElement).parentElement !== this.el) {\n this.previousRowsPerPage = this.rowsPerPage;\n this.rowsPerPage = detail.value;\n }\n\n this.itemsPerPageChange = true;\n }\n\n @Listen(\"icTableDensityUpdate\")\n handleDensityChange(ev: CustomEvent<IcDensityUpdateEventDetail>): void {\n this.density = ev.detail.value;\n }\n\n @Listen(\"click\", { target: \"window\" })\n clickListener(ev: MouseEvent): void {\n if (ev.target !== this.el) this.selectedRow = undefined;\n }\n\n @Watch(\"loading\")\n loadingHandler(newValue: boolean): void {\n if (newValue) this.startLoadingTimer();\n\n if (this.loading) {\n setTimeout(() => {\n this.showLoadingIndicator();\n }, 500);\n }\n }\n\n @Watch(\"truncationPattern\")\n truncationPatternHandler(newValue: IcDataTableTruncationTypes): void {\n if (newValue === this.TOOLTIP_STRING) {\n this.resetShowHideTruncation();\n this.updateTruncationTooltip(true);\n\n // Not using debounceDataTruncation here due to resizeObserver not being triggered\n this.getTypographyElements().forEach(\n (typographyEl: HTMLIcTypographyElement) => {\n const cellContainer = this.getCellContainer(typographyEl);\n const tooltip: HTMLIcTooltipElement = this.getTooltip(typographyEl);\n\n this.truncate(typographyEl, cellContainer, tooltip);\n }\n );\n }\n\n if (newValue === this.SHOW_HIDE_STRING) {\n // ResizeObserver is trigger here due to the see more/see less links being removed.\n // The resizeObserver will also apply the tooltip where relevant\n this.updateTruncationTooltip(true);\n this.getTypographyElements().forEach(\n (typographyEl: HTMLIcTypographyElement) => {\n const truncWrapper = this.getTruncWrapper(typographyEl);\n const cellContainer = this.getCellContainer(typographyEl);\n\n if (\n cellContainer?.clientHeight - this.DEFAULT_LINE_HEIGHT >\n truncWrapper?.scrollHeight\n ) {\n this.resetShowHideTruncation(typographyEl);\n return;\n }\n\n setTimeout(() => {\n // slight delay due to data rendering\n if (typographyEl?.scrollHeight > cellContainer?.clientHeight) {\n this.addShowHideTruncation(cellContainer, typographyEl);\n }\n }, 150);\n }\n );\n }\n\n this.truncationPatternUpdated = true;\n }\n\n @Watch(\"data\")\n async dataHandler(newData: IcDataTableDataType[]): Promise<void> {\n this.loadingOptions = {\n ...this.loadingOptions,\n showBackground: newData?.length > 0,\n };\n if (this.loading) {\n !this.hasLoadedForOneSecond\n ? setTimeout(\n () => (this.loading = false),\n this.minimumLoadingDisplayDuration -\n (Date.now() - this.timerStarted)\n )\n : (this.loading = false);\n }\n if (this.updating) this.updating = false;\n\n this.dataUpdated = true;\n }\n\n @Watch(\"density\")\n async densityHandler(): Promise<void> {\n this.densityUpdate = true;\n }\n\n private removeTextWrap = (): void => {\n this.getTypographyElements().forEach(\n (typographyEl: HTMLIcTypographyElement) => {\n const tableCell = typographyEl.closest(\"td\");\n if (tableCell.classList.contains(this.TEXT_WRAP_STRING)) {\n tableCell.classList.remove(this.TEXT_WRAP_STRING);\n }\n }\n );\n };\n\n private getCellContainer = (\n typographyEl: HTMLIcTypographyElement\n ): HTMLElement => {\n return typographyEl.closest(\".cell-container\");\n };\n\n private deleteTextWrapDataKey = (\n array: IcDataTableColumnObject[] | object[]\n ) =>\n Array.isArray(array) &&\n array.forEach((val) => val.textWrap && delete val.textWrap);\n\n private resetShowHideTruncation(typographyEl?: HTMLIcTypographyElement) {\n if (typographyEl) {\n const truncWrapper = this.getTruncWrapper(typographyEl);\n const cellContainer = this.getCellContainer(typographyEl);\n\n if (\n truncWrapper?.scrollHeight > cellContainer?.clientHeight &&\n !isEmptyString(typographyEl.getAttribute(\"max-lines\")) &&\n Math.floor(cellContainer?.clientHeight / this.DEFAULT_LINE_HEIGHT) !==\n +typographyEl.getAttribute(\"max-lines\")\n ) {\n typographyEl.checkMaxLines(truncWrapper.scrollHeight);\n typographyEl.setAttribute(\n \"max-lines\",\n `${Math.floor(\n cellContainer?.clientHeight / this.DEFAULT_LINE_HEIGHT\n )}`\n );\n typographyEl.setShowHideExpanded(false);\n\n cellContainer.style.setProperty(this.ROW_HEIGHT_CSS_VARIABLE, null);\n } else {\n typographyEl.resetTruncation().then(() => {\n if (!typographyEl.closest(this.TEXT_WRAP_CLASS)) {\n cellContainer.style.setProperty(\n this.ROW_HEIGHT_CSS_VARIABLE,\n cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING)\n );\n }\n });\n }\n } else {\n this.getTypographyElements().forEach((typographyEl) => {\n const cellContainer = this.getCellContainer(typographyEl);\n\n typographyEl.resetTruncation().then(() => {\n if (!typographyEl.closest(this.TEXT_WRAP_CLASS)) {\n cellContainer.style.setProperty(\n this.ROW_HEIGHT_CSS_VARIABLE,\n cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING)\n );\n }\n });\n });\n }\n }\n\n @Watch(\"globalRowHeight\")\n @Watch(\"variableRowHeight\")\n rowHeightChangeHandler(newValue: number, oldValue: number): void {\n if (+newValue !== +oldValue) {\n this.deleteTextWrapDataKey(this.data);\n this.deleteTextWrapDataKey(this.columns);\n this.removeTextWrap();\n\n this.icRowHeightChange.emit();\n\n this.rowHeightSet = true;\n }\n }\n\n /**\n * Resets the `globalRowHeight` prop to number or auto and sets the `variableRowHeight` prop to `null`.\n */\n @Method()\n async resetRowHeights(rowHeight?: number | \"auto\"): Promise<void> {\n this.globalRowHeight = rowHeight || \"auto\";\n this.variableRowHeight = null;\n }\n\n private showLoadingIndicator() {\n this.loadingIndicator.classList.add(\"show\");\n }\n\n private startLoadingTimer = (): void => {\n this.hasLoadedForOneSecond = false;\n this.timerStarted = Date.now();\n setTimeout(() => {\n this.hasLoadedForOneSecond = true;\n this.timerStarted = null;\n }, this.minimumLoadingDisplayDuration);\n };\n\n private isObject = (value: any) => typeof value === \"object\";\n\n private notDefaultDensity = () => this.density !== \"default\";\n\n private getCellContent = (\n cell: any,\n dataType: IcDataTableColumnDataTypes\n ): any => {\n switch (dataType) {\n case \"element\":\n return undefined;\n case \"date\":\n return (\n cell instanceof Date ? cell : new Date(cell)\n ).toLocaleDateString();\n default:\n return cell;\n }\n };\n\n private getCellAlignment = (\n cell: any,\n alignment: \"horizontal\" | \"vertical\"\n ) => {\n if (this.isObject(cell) && Object.keys(cell).includes(\"cellAlignment\")) {\n return this.getObjectValue(\n this.getObjectValue(cell, \"cellAlignment\"),\n alignment\n );\n }\n };\n\n private getCellOptions = (cell: any, key: string) => {\n if (!(this.isObject(cell) && Object.keys(cell).includes(key))) return;\n\n return this.getObjectValue(cell, key);\n };\n\n private createUpdatingIndicator = () => {\n const { appearance, description, max, min, progress, monochrome } =\n this.updatingOptions || {};\n return (\n <th colSpan={this.columns.length} class=\"updating-state\">\n <ic-loading-indicator\n theme={appearance}\n monochrome={monochrome}\n description={description || \"Updating table data\"}\n fullWidth={true}\n max={max}\n min={min}\n progress={progress}\n type=\"linear\"\n size=\"small\"\n ></ic-loading-indicator>\n </th>\n );\n };\n\n private setRowHeight = (height: number) => {\n return pxToRem(\n `${\n height * this.DENSITY_HEIGHT_MULTIPLIER[this.density] -\n this.DENSITY_PADDING_HEIGHT_DIFF[this.density]\n }px`\n );\n };\n\n private setTruncationClass = () => {\n if (this.truncationPattern) {\n return { [`truncation-${this.truncationPattern}`]: true };\n }\n\n return {};\n };\n\n private getColumnWidth = (\n columnWidth?: string | IcDataTableColumnWidthTypes\n ) => {\n // TODO: Setting max width on columns\n let columnWidthStyling = {};\n\n if (columnWidth) {\n if (typeof columnWidth === \"string\") {\n columnWidthStyling = {\n ...columnWidthStyling,\n [\"--column-width\"]: columnWidth,\n };\n }\n\n if (typeof columnWidth === \"object\" && !!Object.keys(columnWidth)) {\n if (columnWidth?.minWidth) {\n columnWidthStyling = {\n ...columnWidthStyling,\n [\"--column-min-width\"]: columnWidth?.minWidth,\n };\n }\n\n if (columnWidth?.maxWidth) {\n columnWidthStyling = {\n ...columnWidthStyling,\n [\"--column-max-width\"]: columnWidth?.maxWidth,\n };\n }\n }\n }\n\n return columnWidthStyling;\n };\n\n private getRowHeight = (\n currentRowHeight: number,\n columnProps: IcDataTableColumnObject,\n rowTextWrap: boolean,\n cell: any\n ) => {\n if (\n (this.truncationPattern || currentRowHeight) &&\n !columnProps?.textWrap &&\n !rowTextWrap &&\n !this.getCellOptions(cell, \"textWrap\") &&\n columnProps?.dataType !== \"element\"\n ) {\n return {\n [this.ROW_HEIGHT_CSS_VARIABLE]: this.setRowHeight(currentRowHeight),\n };\n }\n\n return {};\n };\n\n private createCells = (row: IcDataTableDataType, rowIndex: number) => {\n const rowValues = Object.values(row);\n const rowKeys = Object.keys(row);\n\n const rowOptions = this.getRowOptions(rowKeys, rowValues);\n let rowAlignment: string;\n let rowEmphasis: string;\n\n const headerIndex = rowKeys.indexOf(\"header\");\n if (headerIndex > -1) {\n rowAlignment = this.getObjectValue(\n rowValues[headerIndex],\n \"rowAlignment\"\n );\n rowEmphasis = this.getObjectValue(rowValues[headerIndex], \"emphasis\");\n }\n\n const variableRowHeightVal = this.variableRowHeight?.({\n ...row,\n index: rowIndex,\n });\n const currentRowHeight = variableRowHeightVal\n ? variableRowHeightVal !== \"auto\" && variableRowHeightVal\n : this.globalRowHeight !== \"auto\" && this.globalRowHeight;\n\n return rowValues.map((cell, index) => {\n const columnProps = this.columns[index];\n const cellSlotName = `${columnProps?.key}-${rowIndex}`;\n const hasIcon = this.isObject(cell) && Object.keys(cell).includes(\"icon\");\n const cellValue = (key: string) => this.getObjectValue(cell, key);\n\n if (rowKeys[index] === \"header\") {\n return (\n <th\n scope=\"row\"\n colSpan={cellValue(\"colspan\")}\n class={{\n [\"row-header\"]: true,\n [`row-header-alignment-${cellValue(\"cellAlignment\")}`]:\n !!cellValue(\"cellAlignment\"),\n [\"row-header-sticky\"]: this.stickyRowHeaders,\n }}\n >\n {cellValue(\"title\")}\n </th>\n );\n }\n\n if (rowKeys[index] !== \"rowOptions\") {\n return (\n <td\n class={{\n [\"table-cell\"]: true,\n [`table-density-${this.density}`]: this.notDefaultDensity(),\n [\"with-overflow\"]: columnProps?.dataType === \"element\",\n }}\n style={{ ...this.getColumnWidth(columnProps.columnWidth) }}\n >\n <div\n innerHTML={\n columnProps?.dataType === \"element\" &&\n !isSlotUsed(this.el, cellSlotName)\n ? (cell as string)\n : null\n }\n class={{\n \"cell-container\": columnProps?.dataType !== \"element\",\n [`cell-alignment-${\n columnProps?.columnAlignment?.vertical ||\n rowOptions?.rowAlignment?.vertical ||\n rowAlignment ||\n this.getCellAlignment(cell, \"vertical\")\n }`]:\n !!columnProps?.columnAlignment?.vertical ||\n !!rowOptions?.rowAlignment?.vertical ||\n !!rowAlignment ||\n !!this.getCellAlignment(cell, \"vertical\"),\n [`cell-alignment-${\n columnProps?.columnAlignment?.horizontal ||\n rowOptions?.rowAlignment?.horizontal ||\n this.getCellAlignment(cell, \"horizontal\")\n }`]:\n !!columnProps?.columnAlignment?.horizontal ||\n !!rowOptions?.rowAlignment?.horizontal ||\n !!this.getCellAlignment(cell, \"horizontal\"),\n [`data-type-${columnProps?.dataType}`]: true,\n [this.TEXT_WRAP_STRING]:\n columnProps?.textWrap ||\n rowOptions?.textWrap ||\n !!this.getCellOptions(cell, \"textWrap\"),\n [\"cell-icon\"]: hasIcon || !!columnProps?.icon?.icon,\n ...this.setTruncationClass(),\n }}\n style={{\n ...this.getRowHeight(\n currentRowHeight,\n columnProps,\n rowOptions?.textWrap,\n cell\n ),\n ...this.getColumnWidth(columnProps?.columnWidth),\n }}\n data-row-height={\n this.truncationPattern || currentRowHeight\n ? this.setRowHeight(currentRowHeight)\n : null\n }\n >\n {isSlotUsed(this.el, cellSlotName) ? (\n <slot name={cellSlotName} />\n ) : (\n <Fragment>\n {isSlotUsed(this.el, `${cellSlotName}-icon`) ? (\n <slot name={`${cellSlotName}-icon`} />\n ) : (\n (hasIcon || columnProps?.icon?.onAllCells) &&\n (cellValue(\"icon\") || columnProps?.icon?.icon) && (\n <span\n class=\"icon\"\n innerHTML={cellValue(\"icon\") || columnProps?.icon?.icon}\n ></span>\n )\n )}\n {columnProps?.dataType !== \"element\" &&\n !isSlotUsed(this.el, cellSlotName) && (\n <ic-typography\n variant=\"body\"\n class={{\n [`cell-emphasis-${\n (this.isObject(cell) && cellValue(\"emphasis\")) ||\n columnProps?.emphasis ||\n rowEmphasis\n }`]:\n (this.isObject(cell) && !!cellValue(\"emphasis\")) ||\n !!columnProps?.emphasis ||\n !!rowEmphasis,\n [`text-${this.density}`]: this.notDefaultDensity(),\n }}\n >\n {this.isObject(cell) &&\n columnProps?.dataType !== \"date\" ? (\n Object.keys(cell).includes(\"href\") ? (\n <ic-link href={cellValue(\"href\")}>\n {cellValue(\"data\")}\n </ic-link>\n ) : (\n cellValue(\"data\")\n )\n ) : (\n this.getCellContent(cell, columnProps?.dataType)\n )}\n </ic-typography>\n )}\n </Fragment>\n )}\n </div>\n </td>\n );\n }\n });\n };\n\n private createColumnHeaders = () => {\n return this.columns.map(\n ({ cellAlignment, colspan, icon, key, title, columnWidth }, index) => (\n <th\n scope=\"col\"\n class={{\n [\"column-header\"]: true,\n [`table-density-${this.density}`]: this.notDefaultDensity(),\n [\"updating-state-headers\"]: this.updating && !this.loading,\n }}\n style={{ ...this.getColumnWidth(columnWidth) }}\n colSpan={colspan}\n >\n <div\n class={{\n \"column-header-inner-container\": true,\n \"truncation-tooltip\": this.columnHeaderTruncation,\n [`column-header-alignment-${cellAlignment}`]: !!cellAlignment,\n }}\n >\n {isSlotUsed(this.el, `${key}-column-icon`) ? (\n <slot name={`${key}-column-icon`} />\n ) : (\n icon &&\n !icon.hideOnHeader && (\n <span class=\"icon\" innerHTML={icon.icon}></span>\n )\n )}\n {this.columnHeaderTruncation ? (\n <ic-tooltip label={title} target={`column-header-${index}`}>\n <ic-typography\n id={`column-header-${index}`}\n variant=\"body\"\n class={{\n [\"column-header-text\"]: true,\n [`text-${this.density}`]: this.notDefaultDensity(),\n }}\n >\n {title}\n </ic-typography>\n </ic-tooltip>\n ) : (\n <ic-typography\n variant=\"body\"\n class={{\n [\"column-header-text\"]: true,\n [`text-${this.density}`]: this.notDefaultDensity(),\n }}\n >\n {title}\n </ic-typography>\n )}\n {this.sortable && (\n <ic-button\n variant=\"icon\"\n id={`sort-button-${key}`}\n aria-label={this.getSortButtonLabel(key)}\n // eslint-disable-next-line react/jsx-no-bind\n onClick={() => this.sortRows(key)}\n innerHTML={\n this.SORT_ICONS[\n this.sortedColumn === key\n ? this.sortedColumnOrder\n : \"unsorted\"\n ]\n }\n class={{\n [\"sort-button\"]: true,\n [\"sort-button-unsorted\"]:\n this.sortedColumn !== key ||\n this.sortedColumnOrder === \"unsorted\",\n }}\n ></ic-button>\n )}\n </div>\n {this.columnHeaderTruncation && (\n <ic-typography\n variant=\"body\"\n aria-hidden=\"true\"\n class={{\n [\"column-header-text\"]: true,\n [\"dummy-column-header-text\"]: this.columnHeaderTruncation,\n [`text-${this.density}`]: this.notDefaultDensity(),\n }}\n >\n {title}\n </ic-typography>\n )}\n </th>\n )\n );\n };\n\n private onRowClick = (row: object) => {\n this.selectedRow =\n this.selectedRow !== row && !this.loading && !this.updating && row;\n };\n\n private createRows = () => {\n const data = this.showPagination\n ? this.data.slice(this.fromRow, this.toRow)\n : this.data.slice();\n\n /**\n * Ensures that createCells has a value in data to map over to actually render the slot.\n * Removes the need for the user to add it multiple times.\n * `addDataToPosition` used to add the element in the correct column order.\n * Adding empty string value in to give `createCells` something to loop over.\n */\n const organisedData = data.map((row, rowIndex) => {\n const slottedColumns = this.columns\n .map(\n ({ key }, index) =>\n isSlotUsed(this.el, `${key}-${rowIndex}`) && { key, index }\n )\n .filter((col) => !!col);\n return slottedColumns.length > 0\n ? addDataToPosition(row, slottedColumns, \"\")\n : row;\n });\n\n return organisedData\n .sort(!this.sortable ? undefined : this.getSortFunction())\n .map((row, index) => {\n return (\n <tr\n // eslint-disable-next-line react/jsx-no-bind\n onClick={() => this.onRowClick(row)}\n class={{\n [\"table-row\"]: true,\n [\"table-row-selected\"]: this.selectedRow === row,\n }}\n >\n {this.createCells(row, index)}\n </tr>\n );\n });\n };\n\n private getObjectValue = (cell: object, key: string) => {\n return Object.values(cell)[Object.keys(cell).indexOf(key)];\n };\n\n private getSortButtonLabel = (key: string) => {\n let label = \"\";\n const getNextSortOption = (option: IcDataTableSortOrderOptions) => {\n const sortOrders = this.sortOptions.sortOrders;\n return sortOrders[(sortOrders.indexOf(option) + 1) % sortOrders.length];\n };\n\n if (this.sortedColumn === key) {\n const sortOption = getNextSortOption(this.sortedColumnOrder);\n label = sortOption !== \"unsorted\" ? `Sort ${sortOption}` : \"Remove sort\";\n } else {\n label = `Sort ${getNextSortOption(\"unsorted\")}`;\n }\n\n return label;\n };\n\n private getComparison = (targetRow: any, comparisonRow: any): number => {\n const targetRowValue = targetRow[this.sortedColumn];\n const comparisonRowValue = comparisonRow[this.sortedColumn];\n return this.columns.find((col) => col.key === this.sortedColumn)\n .dataType === \"date\"\n ? new Date(targetRowValue).valueOf() -\n new Date(comparisonRowValue).valueOf()\n : String(\n this.isObject(targetRowValue)\n ? Object.values(targetRowValue)[0]\n : targetRowValue\n ).localeCompare(\n String(\n this.isObject(comparisonRowValue)\n ? Object.values(comparisonRowValue)[0]\n : comparisonRowValue\n ),\n undefined,\n { numeric: true, sensitivity: \"base\" }\n );\n };\n\n private getSortFunction = () => {\n switch (this.sortedColumnOrder) {\n case \"ascending\":\n return (a: any, b: any) => this.getComparison(a, b);\n case \"descending\":\n return (a: any, b: any) => this.getComparison(b, a);\n default:\n return undefined;\n }\n };\n\n private sortRows = (column: string) => {\n const sortButton = this.el.shadowRoot.querySelector(\n `#sort-button-${column}`\n ) as HTMLIcButtonElement;\n\n const sortOrders = this.sortOptions.sortOrders;\n\n if (column !== this.sortedColumn) {\n if (this.sortedColumn) {\n const previousSortedButton = this.el.shadowRoot.querySelector(\n `#sort-button-${this.sortedColumn}`\n ) as HTMLIcButtonElement;\n previousSortedButton.setAttribute(\n \"aria-label\",\n this.getSortButtonLabel(column)\n ); // Passing through unsorted column returns correct label for newly unsorted column\n }\n this.sortedColumn = column;\n this.sortedColumnOrder = \"unsorted\";\n }\n\n let nextSortOrderIndex = sortOrders.indexOf(this.sortedColumnOrder) + 1;\n\n if (nextSortOrderIndex > sortOrders.length - 1) {\n nextSortOrderIndex = 0;\n }\n\n this.sortedColumnOrder = sortOrders[nextSortOrderIndex];\n\n sortButton.setAttribute(\"aria-label\", this.getSortButtonLabel(column));\n\n this.tableSorted = true;\n\n this.icSortChange.emit({\n columnName: column,\n sorted: this.sortedColumnOrder,\n });\n };\n\n private getTypographyElements = (): HTMLIcTypographyElement[] => {\n return Array.from(\n this.el.shadowRoot.querySelectorAll(\n \"ic-typography:not(.column-header-text)\"\n )\n );\n };\n\n private getTooltip = (\n typographyEl: HTMLIcTypographyElement\n ): HTMLIcTooltipElement => {\n return typographyEl.closest(this.TOOLTIP);\n };\n\n private updateTruncationTooltip = (removeTooltipOnly = false) => {\n this.getTypographyElements().forEach(\n (typographyEl: HTMLIcTypographyElement) => {\n const tooltip = this.getTooltip(typographyEl);\n const cellContainer = this.getCellContainer(typographyEl);\n\n if (typographyEl.closest(this.TEXT_WRAP_CLASS)) {\n this.removeTooltip(cellContainer, typographyEl, tooltip);\n typographyEl.setAttribute(\"style\", `--ic-line-clamp: 0`);\n return;\n }\n\n this.regenerateTooltip(\n cellContainer,\n typographyEl,\n tooltip,\n removeTooltipOnly\n );\n }\n );\n };\n\n private updateScrollOffset = () => {\n this.scrollOffset = this.el.shadowRoot.querySelector(\n \".table-row-container\"\n ).scrollTop;\n };\n\n private getRowOptions(rowKeys: string[], rowValues: any[]) {\n const rowOptionsIndex = rowKeys.indexOf(\"rowOptions\");\n return rowOptionsIndex > -1 && rowValues[rowOptionsIndex];\n }\n\n private regenerateTooltip(\n cellContainer: HTMLElement,\n typographyEl: HTMLIcTypographyElement,\n tooltip: HTMLIcTooltipElement,\n removeTooltipOnly?: boolean\n ) {\n // When sorting the table, instead of regenerating the tooltip,\n // the tooltip details are updated\n\n if (tooltip) {\n if (this.tableSorted) {\n tooltip.setAttribute(\"target\", typographyEl.id);\n tooltip.setAttribute(\"label\", typographyEl.textContent);\n } else {\n this.removeTooltip(cellContainer, typographyEl, tooltip);\n }\n if (removeTooltipOnly) {\n return;\n }\n }\n\n // This add line clamp to data only when\n // the data object has been updated\n if (!typographyEl.getAttribute(\"style\") && this.dataUpdated) {\n this.addLineClampCSS(typographyEl, cellContainer);\n }\n\n if (\n typographyEl?.scrollHeight > cellContainer?.clientHeight &&\n this.truncationPattern === this.TOOLTIP_STRING\n ) {\n if (\n !typographyEl.getAttribute(\"style\") ||\n typographyEl.style.cssText.includes(\"--ic-line-clamp: 0;\")\n ) {\n this.addLineClampCSS(typographyEl, cellContainer);\n }\n this.createTruncationTooltip(typographyEl, cellContainer);\n }\n }\n private setTableDimensions = () => {\n let tableHostDimensions = {};\n\n if (this.width) {\n tableHostDimensions = {\n ...tableHostDimensions,\n [\"--table-width\"]: this.width,\n };\n }\n\n if (this.height) {\n tableHostDimensions = {\n ...tableHostDimensions,\n [\"--table-height\"]: this.height,\n };\n }\n\n if (this.maxWidth) {\n tableHostDimensions = {\n ...tableHostDimensions,\n [\"--table-max-width\"]: this.maxWidth,\n };\n }\n\n if (this.minWidth) {\n tableHostDimensions = {\n ...tableHostDimensions,\n [\"--table-min-width\"]: this.minWidth,\n };\n }\n\n return tableHostDimensions;\n };\n\n private removeTooltip(\n cellContainer: HTMLElement,\n typographyEl: HTMLIcTypographyElement,\n tooltip: HTMLIcTooltipElement\n ) {\n cellContainer.appendChild(typographyEl);\n if (tooltip) {\n tooltip.remove();\n }\n }\n\n private addLineClampCSS(\n typographyEl: HTMLIcTypographyElement,\n cellContainer: HTMLElement\n ) {\n typographyEl.setAttribute(\n \"style\",\n `--ic-line-clamp: ${this.getLines(cellContainer?.clientHeight)}`\n );\n }\n\n private createTruncationTooltip(\n typographyEl: HTMLIcTypographyElement,\n cellContainer: HTMLElement\n ) {\n const tooltipEl = document.createElement(\n this.IC_TOOLTIP_STRING\n ) as HTMLIcTooltipElement;\n tooltipEl.setAttribute(\"target\", typographyEl.id);\n tooltipEl.setAttribute(\"label\", typographyEl.textContent);\n tooltipEl.classList.add(\"ic-tooltip-overflow\");\n tooltipEl.setExternalPopperProps({\n // This might need reverting back to absolute if the tooltip doesn't dynamically position itself correctly\n strategy: \"fixed\",\n });\n cellContainer.appendChild(tooltipEl);\n tooltipEl.appendChild(typographyEl);\n }\n\n private fixCellTooltips = () => {\n const elements = this.el.shadowRoot.querySelectorAll(\".data-type-element\");\n elements.forEach((element) => {\n const slotElements = getSlotElements(element);\n slotElements.forEach((slottedEl: HTMLElement) => {\n const tooltipEl = (\n slottedEl.tagName === \"IC-TOOLTIP\"\n ? slottedEl\n : slottedEl.shadowRoot?.querySelector(this.IC_TOOLTIP_STRING)\n ) as HTMLIcTooltipElement;\n if (tooltipEl) {\n tooltipEl.setExternalPopperProps({\n strategy: \"fixed\",\n });\n }\n });\n });\n };\n\n render() {\n const {\n caption,\n createColumnHeaders,\n createRows,\n createUpdatingIndicator,\n data,\n hideColumnHeaders,\n loading,\n loadingOptions,\n paginationBarOptions,\n scrollable,\n scrollOffset,\n showPagination,\n sortable,\n sortedColumnOrder,\n sortedColumn,\n stickyColumnHeaders,\n updateScrollOffset,\n updating,\n } = this;\n\n return (\n <Host style={{ ...this.setTableDimensions() }}>\n <div class=\"table-container\">\n {isSlotUsed(this.el, \"title-bar\") && <slot name=\"title-bar\" />}\n <div\n class={{\n [\"table-row-container\"]: true,\n scrollable,\n }}\n tabIndex={scrollable ? 0 : null}\n onScroll={updateScrollOffset}\n >\n {isSlotUsed(this.el, \"title-bar\") && <slot name=\"title-bar\" />}\n <table\n style={{\n [\"--table-layout\"]: this.tableLayout,\n }}\n >\n <caption class=\"table-caption\">{caption}</caption>\n {!hideColumnHeaders && (\n <thead\n class={{\n [\"column-header-sticky\"]: stickyColumnHeaders,\n [\"column-header-overlay\"]:\n stickyColumnHeaders && scrollOffset !== 0,\n }}\n >\n <tr>{createColumnHeaders()}</tr>\n </thead>\n )}\n {updating &&\n !loading &&\n (hideColumnHeaders ? (\n <thead>{createUpdatingIndicator()}</thead>\n ) : (\n createUpdatingIndicator()\n ))}\n {data?.length > 0 && !loading && <tbody>{createRows()}</tbody>}\n </table>\n {!data?.length &&\n !loading &&\n (isSlotUsed(this.el, \"empty-state\") ? (\n <slot name=\"empty-state\" />\n ) : (\n <ic-empty-state\n aligned=\"center\"\n heading=\"No Data\"\n class=\"loading-empty\"\n ></ic-empty-state>\n ))}\n </div>\n {loading && (\n <ic-loading-indicator\n theme={loadingOptions?.appearance}\n monochrome={loadingOptions?.monochrome}\n class={{\n \"loading-empty\": loading,\n loading: true,\n \"show-background\": loadingOptions.showBackground,\n }}\n description={loadingOptions.description || \"Loading table data\"}\n label={loadingOptions.label || \"Loading...\"}\n labelDuration={loadingOptions?.labelDuration}\n max={loadingOptions?.max}\n min={loadingOptions?.min}\n progress={loadingOptions?.progress}\n ref={(el: HTMLIcLoadingIndicatorElement) =>\n (this.loadingIndicator = el)\n }\n ></ic-loading-indicator>\n )}\n {(showPagination || isSlotUsed(this.el, \"pagination-bar\")) && (\n <div class=\"pagination-container\">\n {isSlotUsed(this.el, \"pagination-bar\") ? (\n <slot name=\"pagination-bar\" />\n ) : (\n <ic-pagination-bar\n totalItems={data.length}\n type={paginationBarOptions.type}\n rangeLabelType={paginationBarOptions.rangeLabelType}\n showItemsPerPageControl={\n paginationBarOptions.showItemsPerPageControl\n }\n showGoToPageControl={paginationBarOptions.showGoToPageControl}\n itemsPerPageOptions={paginationBarOptions.itemsPerPageOptions}\n alignment={paginationBarOptions.alignment}\n theme={paginationBarOptions.theme}\n monochrome={paginationBarOptions.monochrome}\n itemLabel={paginationBarOptions.itemLabel}\n pageLabel={paginationBarOptions.pageLabel}\n hideRangeLabel={paginationBarOptions.hideRangeLabel}\n hideAllFromItemsPerPage={\n paginationBarOptions.hideAllFromItemsPerPage\n }\n ></ic-pagination-bar>\n )}\n </div>\n )}\n {sortable && (\n <div class=\"screen-reader-sort-text\" aria-live=\"polite\">\n {sortedColumnOrder !== \"unsorted\" && sortedColumn\n ? `${sortedColumn} sorted ${sortedColumnOrder}`\n : \"table unsorted\"}\n </div>\n )}\n </div>\n </Host>\n );\n }\n}\n"],"mappings":"iqBAAA,MAAMA,EAAiB,mkN,MCuDVC,EAAS,M,yHACZC,KAAAC,0BAA4B,CAClCC,MAAO,GACPC,QAAS,EACTC,SAAU,KAGJJ,KAAAK,4BAA8B,CACpCH,MAAO,EACPC,QAAS,GACTC,SAAU,IAGJJ,KAAAM,WAAa,CACnBC,SAAUC,EACVC,UAAWC,EACXC,WAAYC,GAGNZ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,SAAdA,EAAgBrK,WAC5BK,MAAO,CACL,gBAAiBsE,EACjBA,QAAS,KACT,kBAAmB0F,EAAeC,gBAEpC1K,YAAayK,EAAezK,aAAe,qBAC3CiF,MAAOwF,EAAexF,OAAS,aAC/BoJ,cAAe5D,IAAc,MAAdA,SAAc,SAAdA,EAAgB4D,cAC/BpO,IAAKwK,IAAc,MAAdA,SAAc,SAAdA,EAAgBxK,IACrBC,IAAKuK,IAAc,MAAdA,SAAc,SAAdA,EAAgBvK,IACrBC,SAAUsK,IAAc,MAAdA,SAAc,SAAdA,EAAgBtK,SAC1BmO,IAAMnU,GACHvC,KAAK2V,iBAAmBpT,KAI7B2L,GAAkB1C,EAAWxL,KAAKuC,GAAI,oBACtCmG,EAAA,OAAKG,MAAM,wBACR2C,EAAWxL,KAAKuC,GAAI,kBACnBmG,EAAA,QAAM2D,KAAK,mBAEX3D,EAAA,qBACEiO,WAAY1I,EAAK5K,OACjB2F,KAAM2J,EAAqB3J,KAC3B6I,eAAgBc,EAAqBd,eACrCC,wBACEa,EAAqBb,wBAEvBC,oBAAqBY,EAAqBZ,oBAC1CH,oBAAqBe,EAAqBf,oBAC1CjK,UAAWgL,EAAqBhL,UAChCmB,MAAO6J,EAAqB7J,MAC5BN,WAAYmK,EAAqBnK,WACjCwJ,UAAWW,EAAqBX,UAChCC,UAAWU,EAAqBV,UAChCC,eAAgBS,EAAqBT,eACrCC,wBACEQ,EAAqBR,2BAM9B3E,GACC9E,EAAA,OAAKG,MAAM,0BAAyB,YAAW,UAC5CgF,IAAsB,YAAcD,EACjC,GAAGA,YAAuBC,IAC1B,mB"}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
import{r as i,h as t,H as e,g as o}from"./p-8455d1bb.js";import{D as s,g as n,e as a,x as r}from"./p-043cf5de.js";import{C as h}from"./p-170ddfc2.js";const d='/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0;}[type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}[type="search"]{-webkit-appearance:textfield;outline-offset:-2px;}[type="search"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}:host{display:block;--ic-typography-color:currentcolor}:host(.in-side-menu){border-bottom:var(--ic-border-width) solid var(--ic-architectural-200);padding:var(--ic-space-md) 0}:host .navigation-group{height:100%;width:-moz-fit-content;width:fit-content;color:var(--ic-theme-text);display:flex;align-items:center;justify-content:center;padding:0 var(--ic-space-md) var(--ic-space-xxs);transition:var(--ic-easing-transition-slow);position:relative;background:none;border:none;white-space:nowrap}:host(.in-side-menu) .navigation-group{height:2.5rem;width:100%;text-align:left}:host(.in-side-menu) .navigation-group .ic-typography-label{width:11.875rem}:host(.in-side-menu) .navigation-group-side-menu{color:var(--ic-action-default);justify-content:flex-start;padding:0 var(--ic-space-md) 0 var(--ic-space-md)}:host(.in-side-menu) .navigation-group-side-menu-collapsed,:host(.in-side-menu) .navigation-group-side-menu-expanded{color:var(--ic-action-default);justify-content:flex-start;padding-left:var(--ic-space-md)}:host(.in-side-menu) .navigation-group-side-menu-expanded{margin-bottom:var(--ic-space-xs)}:host(.in-side-menu) .navigation-group-side-menu-collapsed::after,:host(.in-side-menu) .navigation-group-side-menu-expanded::after{border-style:solid;border-width:0.125em 0.125em 0 0;content:"";display:inline-block;height:0.45em;left:0.75em;position:relative;top:-0.1em;transform:rotate(135deg);vertical-align:top;width:0.45em}:host(.in-side-menu) .navigation-group-side-menu-expanded::after{top:0.15em;transform:rotate(-45deg)}:host .navigation-group:hover,:host .navigation-group:active,:host .selected{background-color:var(--ic-architectural-20);color:var(--ic-color-text-primary-light);outline:none;cursor:pointer}:host(:not(.in-side-menu)) .navigation-group:focus{box-shadow:var(--ic-border-focus);border-radius:var(--ic-border-radius);outline:var(--ic-hc-focus-outline);z-index:var(--ic-z-index-navigation-item);transition:box-shadow var(--ic-easing-transition-fast)}:host(.in-side-menu) .navigation-group-side-menu:hover,:host(.in-side-menu) .navigation-group-side-menu:active,:host(.in-side-menu) .navigation-group-side-menu:focus{background-color:var(--ic-architectural-20);color:var(--ic-action-default);cursor:auto;box-shadow:none;outline:none}:host(.in-side-menu) .navigation-group-side-menu:focus{outline:var(--ic-hc-focus-outline)}:host(.in-side-menu) .navigation-group-side-menu-expanded:hover:not(:focus),:host(.in-side-menu) .navigation-group-side-menu-collapsed:hover:not(:focus){background-color:var(--ic-action-dark-bg-hover);color:var(--ic-action-default);cursor:pointer}:host(.in-side-menu) .navigation-group-side-menu-expanded:active:not(:focus),:host(.in-side-menu) .navigation-group-side-menu-collapsed:active:not(:focus){background-color:var(--ic-action-dark-bg-pressed);color:var(--ic-action-default)}:host(.in-side-menu) .navigation-group-side-menu-expanded:focus,:host(.in-side-menu) .navigation-group-side-menu-collapsed:focus{color:var(--ic-action-default);box-shadow:var(--ic-border-focus-inset);border-radius:var(--ic-border-radius-inset);outline:var(--ic-hc-focus-outline)}:host .navigation-group-dropdown{background-color:var(--ic-architectural-20);border-bottom:var(--ic-border-default);position:absolute;left:0;right:0;padding:var(--ic-space-xs) var(--ic-space-md);box-shadow:0 0.375rem 0.5rem -0.375rem rgba(0 0 0 / 20%);z-index:calc(var(--ic-z-index-navigation-item) - 1)}:host .navigation-group-dropdown-items-list{list-style:none;display:flex;flex-flow:column wrap;align-content:flex-start;padding-left:var(--ic-space-md);max-height:16.5rem}:host .chevron-toggle-icon-wrapper{display:flex;align-items:center}:host .chevron-toggle-icon-wrapper svg{transform:rotate(90deg);height:var(--ic-space-lg);width:var(--ic-space-lg)}:host .chevron-toggle-icon-closed svg{transform:rotate(-90deg)}:host(.ic-navigation-group-expanded) .grouped-links-wrapper{height:var(--navigation-child-items-height, auto) !important;transition:var(--ic-easing-transition-slow);overflow:hidden}:host(.ic-navigation-group-side-nav) .link,:host(.ic-navigation-group-side-nav) ::slotted(a){height:var(--navigation-child-items-height, auto)}:host(.ic-navigation-group-collapsed) .grouped-links-wrapper{height:0;transition:var(--ic-easing-transition-slow);overflow:hidden}:host(.ic-navigation-group-side-nav) .navigation-group{height:var(--navigation-group-height);width:var(--navigation-group-width);justify-content:var(--navigation-group-justify-content);padding-right:var(--navigation-group-expand-toggle-padding)}:host(.ic-navigation-group-side-nav) .navigation-group:hover,:host(.ic-navigation-group-side-nav) .navigation-group:active,:host(.ic-navigation-group-side-nav) .selected{background-color:var(--navigation-group-hover);color:var(--navigation-group-text-hover)}:host(.ic-navigation-group-side-nav) .navigation-group:focus{box-shadow:var(--ic-border-focus-inset);border-radius:var(--ic-border-radius-inset);background:none}:host(.ic-navigation-group-side-nav) .ic-typography-caption{position:var(--navigation-group-title-position);left:var(--navigation-group-title-position-left);white-space:nowrap}';const c=class{constructor(e){i(this,e);this.allGroupedNavigationItems=[];this.DYNAMIC_GROUPED_LINKS_HEIGHT_MS=100;this.IC_NAVIGATION_ITEM="ic-navigation-item";this.mouseGate=false;this.nodeName="IC-NAVIGATION-GROUP";this.GROUPED_LINKS_WRAPPER_CLASS=".grouped-links-wrapper";this.sideNavExpandHandler=i=>{this.isSideNavExpanded=i.detail.sideNavExpanded;const t=this.el.shadowRoot.querySelector(this.GROUPED_LINKS_WRAPPER_CLASS);if(!t)return;if(this.isSideNavExpanded){if(this.expanded&&this.expandedNavItemsHeight){this.setGroupedLinksElementHeight(t,this.expandedNavItemsHeight)}else if(this.expanded){setTimeout((()=>{this.expandedNavItemsHeight=this.getNavigationChildItemsHeight();this.setGroupedLinksElementHeight(t,this.expandedNavItemsHeight)}),this.DYNAMIC_GROUPED_LINKS_HEIGHT_MS)}}else{if(this.expanded&&this.collapsedNavItemsHeight){this.setGroupedLinksElementHeight(t,this.collapsedNavItemsHeight)}else if(this.expanded){setTimeout((()=>{this.collapsedNavItemsHeight=this.getNavigationChildItemsHeight();this.setGroupedLinksElementHeight(t,this.collapsedNavItemsHeight)}),this.DYNAMIC_GROUPED_LINKS_HEIGHT_MS)}}};this.topNavResizedHandler=({detail:i})=>{var t;const{size:e}=i;if(e!==this.deviceSize){this.deviceSize=e;this.inTopNavSideMenu=e<=(((t=this.parentEl)===null||t===void 0?void 0:t.customMobileBreakpoint)||s.L)}};this.setGroupedNavItemTabIndex=i=>{this.el.querySelectorAll(this.IC_NAVIGATION_ITEM).forEach((t=>{const e=t.shadowRoot.querySelector("a")||t.querySelector("a");if(e){e.setAttribute("tabindex",i)}}))};this.toggleGroupedLinkWrapperHeight=(i,t)=>{if(!i)return;if(t){if(this.isSideNavExpanded){this.setGroupedLinksElementHeight(i,this.expandedNavItemsHeight)}else{this.setGroupedLinksElementHeight(i,this.collapsedNavItemsHeight)}this.setGroupedNavItemTabIndex("0")}else{i.style.setProperty("--navigation-child-items-height","0");this.setGroupedNavItemTabIndex("-1")}};this.toggleExpanded=()=>{this.expanded=!this.expanded;const i=this.el.shadowRoot.querySelector(this.GROUPED_LINKS_WRAPPER_CLASS);this.toggleGroupedLinkWrapperHeight(i,this.expanded)};this.handleClick=i=>{if(this.navigationType==="top"&&i.detail){this.toggleDropdown()}else{this.toggleExpanded()}};this.handleBlur=i=>{const t=i.relatedTarget;if(!this.el.contains(t)){this.hideDropdown()}};this.handleTopNavKeydown=i=>{if(i.key===" "||i.key==="Enter"){this.toggleDropdown()}else if(!this.inTopNavSideMenu&&i.key==="Escape"){this.hideDropdown()}};this.handleKeydown=i=>{if(i.key==="Enter"||i.key===" "||i.key==="Escape"){switch(this.navigationType){case"top":this.handleTopNavKeydown(i);break;case"side":this.toggleExpanded();i.preventDefault();break;default:this.toggleExpanded();break}}};this.handleMouseLeave=i=>{const t=i.relatedTarget;this.mouseGate=false;if(!this.el.contains(t)&&t!==this.dropdown&&document.activeElement!==this.el&&!this.el.contains(document.activeElement)&&(t===null||t===void 0?void 0:t.nodeName)===this.nodeName&&this.dropdownOpen===true){this.mouseGate=true;this.hideDropdown()}else if(!this.el.contains(t)&&t!==this.dropdown&&!this.el.contains(document.activeElement)){this.mouseGate=false;setTimeout((()=>{this.dropdownOpen?this.hideDropdown():null}),500)}};this.handleMouseEnter=i=>{const t=i.relatedTarget;document.addEventListener("keydown",this.handleKeydown);if((t===null||t===void 0?void 0:t.nodeName)===this.nodeName&&this.mouseGate===true){this.showDropdown()}else if(this.dropdownOpen===false&&t!==null&&this.mouseGate===false){this.mouseGate=true;setTimeout((()=>{this.mouseGate&&this.showDropdown()}),500)}};this.renderDropdownGroupedLinks=()=>t("div",{class:{["navigation-group-dropdown"]:!this.inTopNavSideMenu,["navigation-group-dropdown-side-menu"]:this.inTopNavSideMenu,["selected"]:this.dropdownOpen&&!this.inTopNavSideMenu},onMouseLeave:!this.inTopNavSideMenu?this.handleMouseLeave:null,ref:i=>this.dropdown=i},t("nav",{class:{["navigation-group-dropdown-items"]:!this.inTopNavSideMenu}},t("ul",null,t("slot",null))));this.renderGroupedLinks=()=>t("ul",{class:"grouped-links-wrapper"},t("slot",null));this.getNavigationChildItemsHeight=()=>{let i=0;this.allGroupedNavigationItems.forEach((t=>{i+=t.offsetHeight}));return`${i}px`};this.setInitialGroupedLinksWrapperHeight=()=>{const i=this.el.shadowRoot.querySelector(this.GROUPED_LINKS_WRAPPER_CLASS);if(!i)return;if(!this.isSideNavExpanded&&!this.collapsedNavItemsHeight&&this.expanded){this.collapsedNavItemsHeight=this.getNavigationChildItemsHeight();this.setGroupedLinksElementHeight(i,this.collapsedNavItemsHeight)}if(this.isSideNavExpanded&&this.expanded){this.expandedNavItemsHeight=this.getNavigationChildItemsHeight();this.setGroupedLinksElementHeight(i,this.expandedNavItemsHeight)}};this.renderNavigationItems=()=>{if(this.dropdownOpen||this.inTopNavSideMenu&&!this.expandable){return this.renderDropdownGroupedLinks()}if(this.navigationType!=="top"){return this.renderGroupedLinks()}return null};this.deviceSize=s.XL;this.dropdownOpen=false;this.expanded=true;this.focusStyle=n();this.inTopNavSideMenu=false;this.navigationType=undefined;this.parentEl=undefined;this.expandable=false;this.label=undefined}disconnectedCallback(){if(this.navigationType==="side"){this.parentEl.removeEventListener("icSideNavExpanded",this.sideNavExpandHandler)}else if(this.navigationType==="top"){this.parentEl.removeEventListener("icTopNavResized",this.topNavResizedHandler)}}componentWillLoad(){this.deviceSize=a();const{navType:i,parent:t}=r(this.el);this.navigationType=i;this.parentEl=t;if(this.navigationType==="side"){this.parentEl.addEventListener("icSideNavExpanded",this.sideNavExpandHandler)}else if(this.navigationType==="top"){this.parentEl.addEventListener("icTopNavResized",this.topNavResizedHandler);if(this.deviceSize<=this.parentEl.customMobileBreakpoint)this.inTopNavSideMenu=true}}componentDidLoad(){this.allGroupedNavigationItems=Array.from(this.el.querySelectorAll(this.IC_NAVIGATION_ITEM));setTimeout((()=>this.setInitialGroupedLinksWrapperHeight()),this.DYNAMIC_GROUPED_LINKS_HEIGHT_MS)}childBlurHandler(){this.hideDropdown()}navItemClickHandler(){this.hideDropdown()}themeChangeHandler(i){const t=i.detail;this.focusStyle=t.mode}async setFocus(){if(this.groupEl){this.groupEl.focus()}}toggleDropdown(){this.dropdownOpen=!this.dropdownOpen}showDropdown(){if(!this.dropdownOpen){this.toggleDropdown()}}hideDropdown(){document.removeEventListener("keydown",this.handleKeydown);if(this.dropdownOpen){this.toggleDropdown()}}setGroupedLinksElementHeight(i,t){i.style.setProperty("--navigation-child-items-height",t)}render(){const{label:i,dropdownOpen:o,inTopNavSideMenu:s,expandable:n}=this;return t(e,{class:{["in-side-menu"]:s,"ic-navigation-group-expanded":this.expanded,"ic-navigation-group-collapsed":!this.expanded,["ic-navigation-group-side-nav"]:this.navigationType==="side"},role:"listitem"},t("button",{onMouseEnter:!s&&this.navigationType==="top"&&this.handleMouseEnter,onMouseLeave:this.navigationType==="top"&&this.handleMouseLeave,tabindex:s&&!n?"-1":"0",onBlur:this.handleBlur,onClick:n?this.handleClick:null,onKeyDown:this.handleKeydown,class:{["navigation-group"]:true,[this.focusStyle]:!s,["navigation-group-side-menu"]:s&&!n,["navigation-group-side-menu-collapsed"]:s&&n&&!o,["navigation-group-side-menu-expanded"]:s&&n&&o,["selected"]:o&&!s},ref:i=>this.groupEl=i,"aria-expanded":`${o||this.expanded}`,"aria-haspopup":`${!s&&this.navigationType==="top"}`},t("ic-typography",{variant:this.navigationType==="side"?"caption":"label"},i),this.navigationType==="side"&&n&&t("div",{class:{"chevron-toggle-icon-wrapper":true,"chevron-toggle-icon-closed":this.expanded},innerHTML:h})),this.renderNavigationItems())}static get delegatesFocus(){return true}get el(){return o(this)}};c.style=d;export{c as ic_navigation_group};
|
2
|
-
//# sourceMappingURL=p-
|
1
|
+
import{r as i,h as t,H as e,g as o}from"./p-8455d1bb.js";import{D as s,g as n,e as a,x as r}from"./p-043cf5de.js";import{C as h}from"./p-170ddfc2.js";const d='/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0;}[type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}[type="search"]{-webkit-appearance:textfield;outline-offset:-2px;}[type="search"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}:host{display:block;--ic-typography-color:currentcolor}:host(.in-side-menu){border-bottom:var(--ic-border-width) solid var(--ic-architectural-200);padding:var(--ic-space-md) 0}:host .navigation-group{height:100%;width:-moz-fit-content;width:fit-content;color:var(--ic-theme-text);display:flex;align-items:center;justify-content:center;padding:0 var(--ic-space-md) var(--ic-space-xxs);transition:var(--ic-easing-transition-slow);position:relative;background:none;border:none;white-space:nowrap}:host(.in-side-menu) .navigation-group{height:2.5rem;width:100%;text-align:left}:host(.in-side-menu) .navigation-group .ic-typography-label{width:11.875rem}:host(.in-side-menu) .navigation-group-side-menu{color:var(--ic-action-default);justify-content:flex-start;padding:0 var(--ic-space-md) 0 var(--ic-space-md)}:host(.in-side-menu) .navigation-group-side-menu-collapsed,:host(.in-side-menu) .navigation-group-side-menu-expanded{color:var(--ic-action-default);justify-content:flex-start;padding-left:var(--ic-space-md)}:host(.in-side-menu) .navigation-group-side-menu-expanded{margin-bottom:var(--ic-space-xs)}:host(.in-side-menu) .navigation-group-side-menu-collapsed::after,:host(.in-side-menu) .navigation-group-side-menu-expanded::after{border-style:solid;border-width:0.125em 0.125em 0 0;content:"";display:inline-block;height:0.45em;left:0.75em;position:relative;top:-0.1em;transform:rotate(135deg);vertical-align:top;width:0.45em}:host(.in-side-menu) .navigation-group-side-menu-expanded::after{top:0.15em;transform:rotate(-45deg)}:host .navigation-group:hover,:host .navigation-group:active,:host .selected{background-color:var(--ic-architectural-20);color:var(--ic-color-text-primary-light);outline:none;cursor:pointer}:host(:not(.in-side-menu)) .navigation-group:focus{box-shadow:var(--ic-border-focus);border-radius:var(--ic-border-radius);outline:var(--ic-hc-focus-outline);z-index:var(--ic-z-index-navigation-item);transition:box-shadow var(--ic-easing-transition-fast)}:host(.in-side-menu) .navigation-group-side-menu:hover,:host(.in-side-menu) .navigation-group-side-menu:active,:host(.in-side-menu) .navigation-group-side-menu:focus{background-color:var(--ic-architectural-20);color:var(--ic-action-default);cursor:auto;box-shadow:none;outline:none}:host(.in-side-menu) .navigation-group-side-menu:focus{outline:var(--ic-hc-focus-outline)}:host(.in-side-menu) .navigation-group-side-menu-expanded:hover:not(:focus),:host(.in-side-menu) .navigation-group-side-menu-collapsed:hover:not(:focus){background-color:var(--ic-action-dark-bg-hover);color:var(--ic-action-default);cursor:pointer}:host(.in-side-menu) .navigation-group-side-menu-expanded:active:not(:focus),:host(.in-side-menu) .navigation-group-side-menu-collapsed:active:not(:focus){background-color:var(--ic-action-dark-bg-pressed);color:var(--ic-action-default)}:host(.in-side-menu) .navigation-group-side-menu-expanded:focus,:host(.in-side-menu) .navigation-group-side-menu-collapsed:focus{color:var(--ic-action-default);box-shadow:var(--ic-border-focus-inset);border-radius:var(--ic-border-radius-inset);outline:var(--ic-hc-focus-outline)}:host .navigation-group-dropdown{background-color:var(--ic-architectural-20);border-bottom:var(--ic-border-default);position:absolute;left:0;right:0;padding:var(--ic-space-xs) var(--ic-space-md);box-shadow:0 0.375rem 0.5rem -0.375rem rgba(0 0 0 / 20%);z-index:calc(var(--ic-z-index-navigation-item) - 1)}:host .navigation-group-dropdown-items-list{list-style:none;display:flex;flex-flow:column wrap;align-content:flex-start;padding-left:var(--ic-space-md);max-height:16.5rem}:host .chevron-toggle-icon-wrapper{display:flex;align-items:center}:host .chevron-toggle-icon-wrapper svg{transform:rotate(90deg);height:var(--ic-space-lg);width:var(--ic-space-lg)}:host .chevron-toggle-icon-closed svg{transform:rotate(-90deg)}:host(.ic-navigation-group-expanded) .grouped-links-wrapper{height:var(--navigation-child-items-height, auto) !important;transition:var(--ic-easing-transition-slow);overflow:hidden}:host(.ic-navigation-group-side-nav) .link,:host(.ic-navigation-group-side-nav) ::slotted(a){height:var(--navigation-child-items-height, auto)}:host(.ic-navigation-group-collapsed) .grouped-links-wrapper{height:0;transition:var(--ic-easing-transition-slow);overflow:hidden}:host(.ic-navigation-group-side-nav) .navigation-group{height:var(--navigation-group-height);width:var(--navigation-group-width);justify-content:var(--navigation-group-justify-content);padding-right:var(--navigation-group-expand-toggle-padding)}:host(.ic-navigation-group-side-nav) .navigation-group:hover,:host(.ic-navigation-group-side-nav) .navigation-group:active,:host(.ic-navigation-group-side-nav) .selected{background-color:var(--navigation-group-hover);color:var(--navigation-group-text-hover)}:host(.ic-navigation-group-side-nav) .navigation-group:focus{box-shadow:var(--ic-border-focus-inset);border-radius:var(--ic-border-radius-inset);background:none}:host(.ic-navigation-group-side-nav) .ic-typography-caption{position:var(--navigation-group-title-position);left:var(--navigation-group-title-position-left);white-space:nowrap}';const c=class{constructor(e){i(this,e);this.allGroupedNavigationItems=[];this.DYNAMIC_GROUPED_LINKS_HEIGHT_MS=100;this.IC_NAVIGATION_ITEM="ic-navigation-item";this.mouseGate=false;this.nodeName="IC-NAVIGATION-GROUP";this.GROUPED_LINKS_WRAPPER_CLASS=".grouped-links-wrapper";this.sideNavExpandHandler=i=>{this.isSideNavExpanded=i.detail.sideNavExpanded;const t=this.el.shadowRoot.querySelector(this.GROUPED_LINKS_WRAPPER_CLASS);if(!t)return;if(this.isSideNavExpanded){if(this.expanded&&this.expandedNavItemsHeight){this.setGroupedLinksElementHeight(t,this.expandedNavItemsHeight)}else if(this.expanded){setTimeout((()=>{this.expandedNavItemsHeight=this.getNavigationChildItemsHeight();this.setGroupedLinksElementHeight(t,this.expandedNavItemsHeight)}),this.DYNAMIC_GROUPED_LINKS_HEIGHT_MS)}}else{if(this.expanded&&this.collapsedNavItemsHeight){this.setGroupedLinksElementHeight(t,this.collapsedNavItemsHeight)}else if(this.expanded){setTimeout((()=>{this.collapsedNavItemsHeight=this.getNavigationChildItemsHeight();this.setGroupedLinksElementHeight(t,this.collapsedNavItemsHeight)}),this.DYNAMIC_GROUPED_LINKS_HEIGHT_MS)}}};this.topNavResizedHandler=({detail:i})=>{var t;const{size:e}=i;if(e!==this.deviceSize){this.deviceSize=e;this.inTopNavSideMenu=e<=(((t=this.parentEl)===null||t===void 0?void 0:t.customMobileBreakpoint)||s.L)}};this.setGroupedNavItemTabIndex=i=>{this.el.querySelectorAll(this.IC_NAVIGATION_ITEM).forEach((t=>{const e=t.shadowRoot.querySelector("a")||t.querySelector("a");if(e){e.setAttribute("tabindex",i)}}))};this.toggleGroupedLinkWrapperHeight=(i,t)=>{if(!i)return;if(t){if(this.isSideNavExpanded){this.setGroupedLinksElementHeight(i,this.expandedNavItemsHeight)}else{this.setGroupedLinksElementHeight(i,this.collapsedNavItemsHeight)}this.setGroupedNavItemTabIndex("0")}else{i.style.setProperty("--navigation-child-items-height","0");this.setGroupedNavItemTabIndex("-1")}};this.toggleExpanded=()=>{this.expanded=!this.expanded;const i=this.el.shadowRoot.querySelector(this.GROUPED_LINKS_WRAPPER_CLASS);this.toggleGroupedLinkWrapperHeight(i,this.expanded)};this.handleClick=i=>{if(this.navigationType==="top"&&i.detail){this.toggleDropdown()}else{this.toggleExpanded()}};this.handleBlur=i=>{const t=i.relatedTarget;if(!this.el.contains(t)){this.hideDropdown()}};this.handleTopNavKeydown=i=>{if(i.key===" "||i.key==="Enter"){this.toggleDropdown()}else if(!this.inTopNavSideMenu&&i.key==="Escape"){this.hideDropdown()}};this.handleKeydown=i=>{if(i.key==="Enter"||i.key===" "||i.key==="Escape"){switch(this.navigationType){case"top":this.handleTopNavKeydown(i);break;case"side":this.toggleExpanded();i.preventDefault();break;default:this.toggleExpanded();break}}};this.handleMouseLeave=i=>{const t=i.relatedTarget;this.mouseGate=false;if(!this.el.contains(t)&&t!==this.dropdown&&document.activeElement!==this.el&&!this.el.contains(document.activeElement)&&(t===null||t===void 0?void 0:t.nodeName)===this.nodeName&&this.dropdownOpen===true){this.mouseGate=true;this.hideDropdown()}else if(!this.el.contains(t)&&t!==this.dropdown&&!this.el.contains(document.activeElement)){this.mouseGate=false;setTimeout((()=>{this.dropdownOpen?this.hideDropdown():null}),500)}};this.handleMouseEnter=i=>{const t=i.relatedTarget;document.addEventListener("keydown",this.handleKeydown);if((t===null||t===void 0?void 0:t.nodeName)===this.nodeName&&this.mouseGate===true){this.showDropdown()}else if(this.dropdownOpen===false&&t!==null&&this.mouseGate===false){this.mouseGate=true;setTimeout((()=>{this.mouseGate&&this.showDropdown()}),500)}};this.renderDropdownGroupedLinks=()=>t("div",{class:{["navigation-group-dropdown"]:!this.inTopNavSideMenu,["navigation-group-dropdown-side-menu"]:this.inTopNavSideMenu,["selected"]:this.dropdownOpen&&!this.inTopNavSideMenu},onMouseLeave:!this.inTopNavSideMenu?this.handleMouseLeave:null,ref:i=>this.dropdown=i},t("nav",{class:{["navigation-group-dropdown-items"]:!this.inTopNavSideMenu}},t("ul",null,t("slot",null))));this.renderGroupedLinks=()=>t("ul",{class:"grouped-links-wrapper"},t("slot",null));this.getNavigationChildItemsHeight=()=>{let i=0;this.allGroupedNavigationItems.forEach((t=>{i+=t.offsetHeight}));return`${i}px`};this.setInitialGroupedLinksWrapperHeight=()=>{const i=this.el.shadowRoot.querySelector(this.GROUPED_LINKS_WRAPPER_CLASS);if(!i)return;if(!this.isSideNavExpanded&&!this.collapsedNavItemsHeight&&this.expanded){this.collapsedNavItemsHeight=this.getNavigationChildItemsHeight();this.setGroupedLinksElementHeight(i,this.collapsedNavItemsHeight)}if(this.isSideNavExpanded&&this.expanded){this.expandedNavItemsHeight=this.getNavigationChildItemsHeight();this.setGroupedLinksElementHeight(i,this.expandedNavItemsHeight)}};this.renderNavigationItems=()=>{if(this.dropdownOpen||this.inTopNavSideMenu&&!this.expandable){return this.renderDropdownGroupedLinks()}if(this.navigationType!=="top"){return this.renderGroupedLinks()}return null};this.deviceSize=s.XL;this.dropdownOpen=false;this.expanded=true;this.focusStyle=n();this.inTopNavSideMenu=false;this.navigationType=undefined;this.parentEl=undefined;this.expandable=false;this.label=undefined}disconnectedCallback(){var i,t;if(this.navigationType==="side"){(i=this.parentEl)===null||i===void 0?void 0:i.removeEventListener("icSideNavExpanded",this.sideNavExpandHandler)}else if(this.navigationType==="top"){(t=this.parentEl)===null||t===void 0?void 0:t.removeEventListener("icTopNavResized",this.topNavResizedHandler)}}componentWillLoad(){this.deviceSize=a();const{navType:i,parent:t}=r(this.el);this.navigationType=i;this.parentEl=t;if(this.navigationType==="side"){this.parentEl.addEventListener("icSideNavExpanded",this.sideNavExpandHandler)}else if(this.navigationType==="top"){this.parentEl.addEventListener("icTopNavResized",this.topNavResizedHandler);if(this.deviceSize<=this.parentEl.customMobileBreakpoint)this.inTopNavSideMenu=true}}componentDidLoad(){this.allGroupedNavigationItems=Array.from(this.el.querySelectorAll(this.IC_NAVIGATION_ITEM));setTimeout((()=>this.setInitialGroupedLinksWrapperHeight()),this.DYNAMIC_GROUPED_LINKS_HEIGHT_MS)}childBlurHandler(){this.hideDropdown()}navItemClickHandler(){this.hideDropdown()}themeChangeHandler(i){const t=i.detail;this.focusStyle=t.mode}async setFocus(){if(this.groupEl){this.groupEl.focus()}}toggleDropdown(){this.dropdownOpen=!this.dropdownOpen}showDropdown(){if(!this.dropdownOpen){this.toggleDropdown()}}hideDropdown(){document.removeEventListener("keydown",this.handleKeydown);if(this.dropdownOpen){this.toggleDropdown()}}setGroupedLinksElementHeight(i,t){i.style.setProperty("--navigation-child-items-height",t)}render(){const{label:i,dropdownOpen:o,inTopNavSideMenu:s,expandable:n}=this;return t(e,{class:{["in-side-menu"]:s,"ic-navigation-group-expanded":this.expanded,"ic-navigation-group-collapsed":!this.expanded,["ic-navigation-group-side-nav"]:this.navigationType==="side"},role:"listitem"},t("button",{onMouseEnter:!s&&this.navigationType==="top"&&this.handleMouseEnter,onMouseLeave:this.navigationType==="top"&&this.handleMouseLeave,tabindex:s&&!n?"-1":"0",onBlur:this.handleBlur,onClick:n?this.handleClick:null,onKeyDown:this.handleKeydown,class:{["navigation-group"]:true,[this.focusStyle]:!s,["navigation-group-side-menu"]:s&&!n,["navigation-group-side-menu-collapsed"]:s&&n&&!o,["navigation-group-side-menu-expanded"]:s&&n&&o,["selected"]:o&&!s},ref:i=>this.groupEl=i,"aria-expanded":`${o||this.expanded}`,"aria-haspopup":`${!s&&this.navigationType==="top"}`},t("ic-typography",{variant:this.navigationType==="side"?"caption":"label"},i),this.navigationType==="side"&&n&&t("div",{class:{"chevron-toggle-icon-wrapper":true,"chevron-toggle-icon-closed":this.expanded},innerHTML:h})),this.renderNavigationItems())}static get delegatesFocus(){return true}get el(){return o(this)}};c.style=d;export{c as ic_navigation_group};
|
2
|
+
//# sourceMappingURL=p-f32ab3de.entry.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["icNavigationGroupCss","NavigationGroup","constructor","hostRef","this","allGroupedNavigationItems","DYNAMIC_GROUPED_LINKS_HEIGHT_MS","IC_NAVIGATION_ITEM","mouseGate","nodeName","GROUPED_LINKS_WRAPPER_CLASS","sideNavExpandHandler","event","isSideNavExpanded","detail","sideNavExpanded","linkWrapper","el","shadowRoot","querySelector","expanded","expandedNavItemsHeight","setGroupedLinksElementHeight","setTimeout","getNavigationChildItemsHeight","collapsedNavItemsHeight","topNavResizedHandler","_a","size","deviceSize","inTopNavSideMenu","parentEl","customMobileBreakpoint","DEVICE_SIZES","L","setGroupedNavItemTabIndex","tabIndexValue","querySelectorAll","forEach","navigationItem","navItem","setAttribute","toggleGroupedLinkWrapperHeight","wrapper","style","setProperty","toggleExpanded","handleClick","ev","navigationType","toggleDropdown","handleBlur","target","relatedTarget","contains","hideDropdown","handleTopNavKeydown","key","handleKeydown","preventDefault","handleMouseLeave","relTarget","dropdown","document","activeElement","dropdownOpen","handleMouseEnter","addEventListener","showDropdown","renderDropdownGroupedLinks","h","class","onMouseLeave","ref","renderGroupedLinks","navigationChildItemsHeight","offsetHeight","setInitialGroupedLinksWrapperHeight","renderNavigationItems","expandable","XL","focusStyle","getThemeForegroundColor","undefined","label","disconnectedCallback","_b","removeEventListener","componentWillLoad","getCurrentDeviceSize","navType","parent","getNavItemParentDetails","componentDidLoad","Array","from","childBlurHandler","navItemClickHandler","themeChangeHandler","theme","mode","setFocus","groupEl","focus","groupedNavItemWrapper","height","render","Host","role","onMouseEnter","tabindex","onBlur","onClick","onKeyDown","variant","innerHTML","chevronIcon","delegatesFocus"],"sources":["../web-components/dist/collection/components/ic-navigation-group/ic-navigation-group.css?tag=ic-navigation-group&encapsulation=shadow","../web-components/dist/collection/components/ic-navigation-group/ic-navigation-group.js"],"sourcesContent":["/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */\n\n/* Document\n ========================================================================== */\n\n/**\n * 1. Correct the line height in all browsers.\n * 2. Prevent adjustments of font size after orientation changes in iOS.\n */\n\nhtml {\n line-height: 1.15; /* 1 */\n -webkit-text-size-adjust: 100%; /* 2 */\n}\n\n/* Sections\n ========================================================================== */\n\n/**\n * Remove the margin in all browsers.\n */\n\nbody {\n margin: 0;\n}\n\n/**\n * Render the `main` element consistently in IE.\n */\n\nmain {\n display: block;\n}\n\n/**\n * Correct the font size and margin on `h1` elements within `section` and\n * `article` contexts in Chrome, Firefox, and Safari.\n */\n\nh1 {\n font-size: 2em;\n margin: 0.67em 0;\n}\n\n/* Grouping content\n ========================================================================== */\n\n/**\n * 1. Add the correct box sizing in Firefox.\n * 2. Show the overflow in Edge and IE.\n */\n\nhr {\n box-sizing: content-box; /* 1 */\n height: 0; /* 1 */\n overflow: visible; /* 2 */\n}\n\n/**\n * 1. Correct the inheritance and scaling of font size in all browsers.\n * 2. Correct the odd `em` font sizing in all browsers.\n */\n\npre {\n font-family: monospace, monospace; /* 1 */\n font-size: 1em; /* 2 */\n}\n\n/* Text-level semantics\n ========================================================================== */\n\n/**\n * Remove the gray background on active links in IE 10.\n */\n\na {\n background-color: transparent;\n}\n\n/**\n * 1. Remove the bottom border in Chrome 57-\n * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.\n */\n\nabbr[title] {\n border-bottom: none; /* 1 */\n text-decoration: underline; /* 2 */\n -webkit-text-decoration: underline dotted;\n text-decoration: underline dotted; /* 2 */\n}\n\n/**\n * Add the correct font weight in Chrome, Edge, and Safari.\n */\n\nb,\nstrong {\n font-weight: bolder;\n}\n\n/**\n * 1. Correct the inheritance and scaling of font size in all browsers.\n * 2. Correct the odd `em` font sizing in all browsers.\n */\n\ncode,\nkbd,\nsamp {\n font-family: monospace, monospace; /* 1 */\n font-size: 1em; /* 2 */\n}\n\n/**\n * Add the correct font size in all browsers.\n */\n\nsmall {\n font-size: 80%;\n}\n\n/**\n * Prevent `sub` and `sup` elements from affecting the line height in\n * all browsers.\n */\n\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\n/* Embedded content\n ========================================================================== */\n\n/**\n * Remove the border on images inside links in IE 10.\n */\n\nimg {\n border-style: none;\n}\n\n/* Forms\n ========================================================================== */\n\n/**\n * 1. Change the font styles in all browsers.\n * 2. Remove the margin in Firefox and Safari.\n */\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: inherit; /* 1 */\n font-size: 100%; /* 1 */\n line-height: 1.15; /* 1 */\n margin: 0; /* 2 */\n}\n\n/**\n * Show the overflow in IE.\n * 1. Show the overflow in Edge.\n */\n\nbutton,\ninput {\n /* 1 */\n overflow: visible;\n}\n\n/**\n * Remove the inheritance of text transform in Edge, Firefox, and IE.\n * 1. Remove the inheritance of text transform in Firefox.\n */\n\nbutton,\nselect {\n /* 1 */\n text-transform: none;\n}\n\n/**\n * Correct the inability to style clickable types in iOS and Safari.\n */\n\nbutton,\n[type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"] {\n -webkit-appearance: button;\n}\n\n/**\n * Remove the inner border and padding in Firefox.\n */\n\nbutton::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner {\n border-style: none;\n padding: 0;\n}\n\n/**\n * Restore the focus styles unset by the previous rule.\n */\n\nbutton:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring {\n outline: 1px dotted ButtonText;\n}\n\n/**\n * Correct the padding in Firefox.\n */\n\nfieldset {\n padding: 0.35em 0.75em 0.625em;\n}\n\n/**\n * 1. Correct the text wrapping in Edge and IE.\n * 2. Correct the color inheritance from `fieldset` elements in IE.\n * 3. Remove the padding so developers are not caught out when they zero out\n * `fieldset` elements in all browsers.\n */\n\nlegend {\n box-sizing: border-box; /* 1 */\n color: inherit; /* 2 */\n display: table; /* 1 */\n max-width: 100%; /* 1 */\n padding: 0; /* 3 */\n white-space: normal; /* 1 */\n}\n\n/**\n * Add the correct vertical alignment in Chrome, Firefox, and Opera.\n */\n\nprogress {\n vertical-align: baseline;\n}\n\n/**\n * Remove the default vertical scrollbar in IE 10+.\n */\n\ntextarea {\n overflow: auto;\n}\n\n/**\n * 1. Add the correct box sizing in IE 10.\n * 2. Remove the padding in IE 10.\n */\n\n[type=\"checkbox\"],\n[type=\"radio\"] {\n box-sizing: border-box; /* 1 */\n padding: 0; /* 2 */\n}\n\n/**\n * Correct the cursor style of increment and decrement buttons in Chrome.\n */\n\n[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button {\n height: auto;\n}\n\n/**\n * 1. Correct the odd appearance in Chrome and Safari.\n * 2. Correct the outline style in Safari.\n */\n\n[type=\"search\"] {\n -webkit-appearance: textfield; /* 1 */\n outline-offset: -2px; /* 2 */\n}\n\n/**\n * Remove the inner padding in Chrome and Safari on macOS.\n */\n\n[type=\"search\"]::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n/**\n * 1. Correct the inability to style clickable types in iOS and Safari.\n * 2. Change font properties to `inherit` in Safari.\n */\n\n::-webkit-file-upload-button {\n -webkit-appearance: button; /* 1 */\n font: inherit; /* 2 */\n}\n\n/* Interactive\n ========================================================================== */\n\n/*\n * Add the correct display in Edge, IE 10+, and Firefox.\n */\n\ndetails {\n display: block;\n}\n\n/*\n * Add the correct display in all browsers.\n */\n\nsummary {\n display: list-item;\n}\n\n/* Misc\n ========================================================================== */\n\n/**\n * Add the correct display in IE 10+.\n */\n\ntemplate {\n display: none;\n}\n\n/**\n * Add the correct display in IE 10.\n */\n\n[hidden] {\n display: none;\n}\n\nhtml,\nbody,\ndiv,\nspan,\napplet,\nobject,\niframe,\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\np,\nblockquote,\npre,\na,\nabbr,\nacronym,\naddress,\nbig,\ncite,\ncode,\ndel,\ndfn,\nem,\nimg,\nins,\nkbd,\nq,\ns,\nsamp,\nsmall,\nstrike,\nstrong,\nsub,\nsup,\ntt,\nvar,\nb,\nu,\ni,\ncenter,\ndl,\ndt,\ndd,\nol,\nul,\nli,\nfieldset,\nform,\nlabel,\nlegend,\ntable,\ncaption,\ntbody,\ntfoot,\nthead,\ntr,\nth,\ntd,\narticle,\naside,\ncanvas,\ndetails,\nembed,\nfigure,\nfigcaption,\nfooter,\nheader,\nhgroup,\nmenu,\nnav,\noutput,\nruby,\nsection,\nsummary,\ntime,\nmark,\naudio,\nvideo {\n margin: 0;\n padding: 0;\n border: 0;\n font-size: 100%;\n font-style: inherit;\n vertical-align: baseline;\n}\n\n\n/**\n * @prop --ic-z-index-navigation-item: z-index of navigation group item\n */\n\n:host {\n display: block;\n\n --ic-typography-color: currentcolor;\n}\n\n:host(.in-side-menu) {\n border-bottom: var(--ic-border-width) solid var(--ic-architectural-200);\n padding: var(--ic-space-md) 0;\n}\n\n:host .navigation-group {\n height: 100%;\n width: -moz-fit-content;\n width: fit-content;\n color: var(--ic-theme-text);\n display: flex;\n align-items: center;\n justify-content: center;\n padding: 0 var(--ic-space-md) var(--ic-space-xxs);\n transition: var(--ic-easing-transition-slow);\n position: relative;\n background: none;\n border: none;\n white-space: nowrap;\n}\n\n:host(.in-side-menu) .navigation-group {\n height: 2.5rem;\n width: 100%;\n text-align: left;\n}\n\n:host(.in-side-menu) .navigation-group .ic-typography-label {\n width: 11.875rem;\n}\n\n:host(.in-side-menu) .navigation-group-side-menu {\n color: var(--ic-action-default);\n justify-content: flex-start;\n padding: 0 var(--ic-space-md) 0 var(--ic-space-md);\n}\n\n:host(.in-side-menu) .navigation-group-side-menu-collapsed,\n:host(.in-side-menu) .navigation-group-side-menu-expanded {\n color: var(--ic-action-default);\n justify-content: flex-start;\n padding-left: var(--ic-space-md);\n}\n\n:host(.in-side-menu) .navigation-group-side-menu-expanded {\n margin-bottom: var(--ic-space-xs);\n}\n\n:host(.in-side-menu) .navigation-group-side-menu-collapsed::after,\n:host(.in-side-menu) .navigation-group-side-menu-expanded::after {\n border-style: solid;\n border-width: 0.125em 0.125em 0 0;\n content: \"\";\n display: inline-block;\n height: 0.45em;\n left: 0.75em;\n position: relative;\n top: -0.1em;\n transform: rotate(135deg);\n vertical-align: top;\n width: 0.45em;\n}\n\n:host(.in-side-menu) .navigation-group-side-menu-expanded::after {\n top: 0.15em;\n transform: rotate(-45deg);\n}\n\n:host .navigation-group:hover,\n:host .navigation-group:active,\n:host .selected {\n background-color: var(--ic-architectural-20);\n color: var(--ic-color-text-primary-light);\n outline: none;\n cursor: pointer;\n}\n\n:host(:not(.in-side-menu)) .navigation-group:focus {\n box-shadow: var(--ic-border-focus);\n border-radius: var(--ic-border-radius);\n outline: var(--ic-hc-focus-outline);\n z-index: var(--ic-z-index-navigation-item);\n transition: box-shadow var(--ic-easing-transition-fast);\n}\n\n:host(.in-side-menu) .navigation-group-side-menu:hover,\n:host(.in-side-menu) .navigation-group-side-menu:active,\n:host(.in-side-menu) .navigation-group-side-menu:focus {\n background-color: var(--ic-architectural-20);\n color: var(--ic-action-default);\n cursor: auto;\n box-shadow: none;\n outline: none;\n}\n\n:host(.in-side-menu) .navigation-group-side-menu:focus {\n outline: var(--ic-hc-focus-outline);\n}\n\n:host(.in-side-menu) .navigation-group-side-menu-expanded:hover:not(:focus),\n:host(.in-side-menu) .navigation-group-side-menu-collapsed:hover:not(:focus) {\n background-color: var(--ic-action-dark-bg-hover);\n color: var(--ic-action-default);\n cursor: pointer;\n}\n\n:host(.in-side-menu) .navigation-group-side-menu-expanded:active:not(:focus),\n:host(.in-side-menu) .navigation-group-side-menu-collapsed:active:not(:focus) {\n background-color: var(--ic-action-dark-bg-pressed);\n color: var(--ic-action-default);\n}\n\n:host(.in-side-menu) .navigation-group-side-menu-expanded:focus,\n:host(.in-side-menu) .navigation-group-side-menu-collapsed:focus {\n color: var(--ic-action-default);\n box-shadow: var(--ic-border-focus-inset);\n border-radius: var(--ic-border-radius-inset);\n outline: var(--ic-hc-focus-outline);\n}\n\n:host .navigation-group-dropdown {\n background-color: var(--ic-architectural-20);\n border-bottom: var(--ic-border-default);\n position: absolute;\n left: 0;\n right: 0;\n padding: var(--ic-space-xs) var(--ic-space-md);\n box-shadow: 0 0.375rem 0.5rem -0.375rem rgba(0 0 0 / 20%);\n z-index: calc(var(--ic-z-index-navigation-item) - 1);\n}\n\n:host .navigation-group-dropdown-items-list {\n list-style: none;\n display: flex;\n flex-flow: column wrap;\n align-content: flex-start;\n padding-left: var(--ic-space-md);\n max-height: 16.5rem;\n}\n\n:host .chevron-toggle-icon-wrapper {\n display: flex;\n align-items: center;\n}\n\n:host .chevron-toggle-icon-wrapper svg {\n transform: rotate(90deg);\n height: var(--ic-space-lg);\n width: var(--ic-space-lg);\n}\n\n:host .chevron-toggle-icon-closed svg {\n transform: rotate(-90deg);\n}\n\n:host(.ic-navigation-group-expanded) .grouped-links-wrapper {\n height: var(--navigation-child-items-height, auto) !important;\n transition: var(--ic-easing-transition-slow);\n overflow: hidden;\n}\n\n:host(.ic-navigation-group-side-nav) .link,\n:host(.ic-navigation-group-side-nav) ::slotted(a) {\n height: var(--navigation-child-items-height, auto);\n}\n\n:host(.ic-navigation-group-collapsed) .grouped-links-wrapper {\n height: 0;\n transition: var(--ic-easing-transition-slow);\n overflow: hidden;\n}\n\n:host(.ic-navigation-group-side-nav) .navigation-group {\n height: var(--navigation-group-height);\n width: var(--navigation-group-width);\n justify-content: var(--navigation-group-justify-content);\n padding-right: var(--navigation-group-expand-toggle-padding);\n}\n\n:host(.ic-navigation-group-side-nav) .navigation-group:hover,\n:host(.ic-navigation-group-side-nav) .navigation-group:active,\n:host(.ic-navigation-group-side-nav) .selected {\n background-color: var(--navigation-group-hover);\n color: var(--navigation-group-text-hover);\n}\n\n:host(.ic-navigation-group-side-nav) .navigation-group:focus {\n box-shadow: var(--ic-border-focus-inset);\n border-radius: var(--ic-border-radius-inset);\n background: none;\n}\n\n:host(.ic-navigation-group-side-nav) .ic-typography-caption {\n position: var(--navigation-group-title-position);\n left: var(--navigation-group-title-position-left);\n white-space: nowrap;\n}\n","import { Host, h, } from \"@stencil/core\";\nimport { DEVICE_SIZES, getCurrentDeviceSize, getThemeForegroundColor, getNavItemParentDetails, } from \"../../utils/helpers\";\nimport chevronIcon from \"../../assets/chevron-icon.svg\";\nexport class NavigationGroup {\n constructor() {\n this.allGroupedNavigationItems = [];\n this.DYNAMIC_GROUPED_LINKS_HEIGHT_MS = 100;\n this.IC_NAVIGATION_ITEM = \"ic-navigation-item\";\n this.mouseGate = false;\n this.nodeName = \"IC-NAVIGATION-GROUP\";\n this.GROUPED_LINKS_WRAPPER_CLASS = \".grouped-links-wrapper\";\n this.sideNavExpandHandler = (event) => {\n this.isSideNavExpanded = event.detail.sideNavExpanded;\n const linkWrapper = this.el.shadowRoot.querySelector(this.GROUPED_LINKS_WRAPPER_CLASS);\n if (!linkWrapper)\n return;\n if (this.isSideNavExpanded) {\n if (this.expanded && this.expandedNavItemsHeight) {\n this.setGroupedLinksElementHeight(linkWrapper, this.expandedNavItemsHeight);\n }\n else if (this.expanded) {\n setTimeout(() => {\n this.expandedNavItemsHeight = this.getNavigationChildItemsHeight();\n this.setGroupedLinksElementHeight(linkWrapper, this.expandedNavItemsHeight);\n }, this.DYNAMIC_GROUPED_LINKS_HEIGHT_MS);\n }\n }\n else {\n if (this.expanded && this.collapsedNavItemsHeight) {\n this.setGroupedLinksElementHeight(linkWrapper, this.collapsedNavItemsHeight);\n }\n else if (this.expanded) {\n setTimeout(() => {\n this.collapsedNavItemsHeight = this.getNavigationChildItemsHeight();\n this.setGroupedLinksElementHeight(linkWrapper, this.collapsedNavItemsHeight);\n }, this.DYNAMIC_GROUPED_LINKS_HEIGHT_MS);\n }\n }\n };\n this.topNavResizedHandler = ({ detail, }) => {\n var _a;\n const { size } = detail;\n if (size !== this.deviceSize) {\n this.deviceSize = size;\n this.inTopNavSideMenu =\n size <=\n (((_a = this.parentEl) === null || _a === void 0 ? void 0 : _a.customMobileBreakpoint) || DEVICE_SIZES.L);\n }\n };\n this.setGroupedNavItemTabIndex = (tabIndexValue) => {\n this.el\n .querySelectorAll(this.IC_NAVIGATION_ITEM)\n .forEach((navigationItem) => {\n const navItem = navigationItem.shadowRoot.querySelector(\"a\") ||\n navigationItem.querySelector(\"a\");\n if (navItem) {\n navItem.setAttribute(\"tabindex\", tabIndexValue);\n }\n });\n };\n this.toggleGroupedLinkWrapperHeight = (wrapper, expanded) => {\n if (!wrapper)\n return;\n if (expanded) {\n if (this.isSideNavExpanded) {\n this.setGroupedLinksElementHeight(wrapper, this.expandedNavItemsHeight);\n }\n else {\n this.setGroupedLinksElementHeight(wrapper, this.collapsedNavItemsHeight);\n }\n this.setGroupedNavItemTabIndex(\"0\");\n }\n else {\n wrapper.style.setProperty(\"--navigation-child-items-height\", \"0\");\n this.setGroupedNavItemTabIndex(\"-1\");\n }\n };\n this.toggleExpanded = () => {\n this.expanded = !this.expanded;\n const linkWrapper = this.el.shadowRoot.querySelector(this.GROUPED_LINKS_WRAPPER_CLASS);\n this.toggleGroupedLinkWrapperHeight(linkWrapper, this.expanded);\n };\n this.handleClick = (ev) => {\n if (this.navigationType === \"top\" && ev.detail) {\n this.toggleDropdown();\n }\n else {\n this.toggleExpanded();\n }\n };\n this.handleBlur = (ev) => {\n const target = ev.relatedTarget;\n if (!this.el.contains(target)) {\n this.hideDropdown();\n }\n };\n this.handleTopNavKeydown = (ev) => {\n if (ev.key === \" \" || ev.key === \"Enter\") {\n this.toggleDropdown();\n }\n else if (!this.inTopNavSideMenu && ev.key === \"Escape\") {\n this.hideDropdown();\n }\n };\n this.handleKeydown = (ev) => {\n if (ev.key === \"Enter\" || ev.key === \" \" || ev.key === \"Escape\") {\n switch (this.navigationType) {\n case \"top\":\n this.handleTopNavKeydown(ev);\n break;\n case \"side\":\n this.toggleExpanded();\n ev.preventDefault();\n break;\n default:\n this.toggleExpanded();\n break;\n }\n }\n };\n this.handleMouseLeave = (ev) => {\n const relTarget = ev.relatedTarget;\n this.mouseGate = false;\n if (!this.el.contains(relTarget) &&\n relTarget !== this.dropdown &&\n document.activeElement !== this.el &&\n !this.el.contains(document.activeElement) &&\n (relTarget === null || relTarget === void 0 ? void 0 : relTarget.nodeName) === this.nodeName &&\n this.dropdownOpen === true) {\n this.mouseGate = true;\n this.hideDropdown();\n }\n else if (!this.el.contains(relTarget) &&\n relTarget !== this.dropdown &&\n !this.el.contains(document.activeElement)) {\n this.mouseGate = false;\n setTimeout(() => {\n this.dropdownOpen ? this.hideDropdown() : null;\n }, 500);\n }\n };\n this.handleMouseEnter = (ev) => {\n const relTarget = ev.relatedTarget;\n document.addEventListener(\"keydown\", this.handleKeydown);\n if ((relTarget === null || relTarget === void 0 ? void 0 : relTarget.nodeName) === this.nodeName && this.mouseGate === true) {\n this.showDropdown();\n }\n else if (this.dropdownOpen === false &&\n relTarget !== null &&\n this.mouseGate === false) {\n this.mouseGate = true;\n setTimeout(() => {\n this.mouseGate && this.showDropdown();\n }, 500);\n }\n };\n this.renderDropdownGroupedLinks = () => (h(\"div\", { class: {\n [\"navigation-group-dropdown\"]: !this.inTopNavSideMenu,\n [\"navigation-group-dropdown-side-menu\"]: this.inTopNavSideMenu,\n [\"selected\"]: this.dropdownOpen && !this.inTopNavSideMenu,\n }, onMouseLeave: !this.inTopNavSideMenu ? this.handleMouseLeave : null, ref: (el) => (this.dropdown = el) }, h(\"nav\", { class: {\n [\"navigation-group-dropdown-items\"]: !this.inTopNavSideMenu,\n } }, h(\"ul\", null, h(\"slot\", null)))));\n this.renderGroupedLinks = () => (h(\"ul\", { class: \"grouped-links-wrapper\" }, h(\"slot\", null)));\n /**\n * Gets the total height of navigation links to improve\n * smoothness of expand/collapse animations\n */\n this.getNavigationChildItemsHeight = () => {\n let navigationChildItemsHeight = 0;\n this.allGroupedNavigationItems.forEach((navItem) => {\n navigationChildItemsHeight += navItem.offsetHeight;\n });\n return `${navigationChildItemsHeight}px`;\n };\n this.setInitialGroupedLinksWrapperHeight = () => {\n const linkWrapper = this.el.shadowRoot.querySelector(this.GROUPED_LINKS_WRAPPER_CLASS);\n if (!linkWrapper)\n return;\n if (!this.isSideNavExpanded &&\n !this.collapsedNavItemsHeight &&\n this.expanded) {\n this.collapsedNavItemsHeight = this.getNavigationChildItemsHeight();\n this.setGroupedLinksElementHeight(linkWrapper, this.collapsedNavItemsHeight);\n }\n if (this.isSideNavExpanded && this.expanded) {\n this.expandedNavItemsHeight = this.getNavigationChildItemsHeight();\n this.setGroupedLinksElementHeight(linkWrapper, this.expandedNavItemsHeight);\n }\n };\n this.renderNavigationItems = () => {\n if (this.dropdownOpen || (this.inTopNavSideMenu && !this.expandable)) {\n return this.renderDropdownGroupedLinks();\n }\n if (this.navigationType !== \"top\") {\n return this.renderGroupedLinks();\n }\n return null;\n };\n this.deviceSize = DEVICE_SIZES.XL;\n this.dropdownOpen = false;\n this.expanded = true;\n this.focusStyle = getThemeForegroundColor();\n this.inTopNavSideMenu = false;\n this.navigationType = undefined;\n this.parentEl = undefined;\n this.expandable = false;\n this.label = undefined;\n }\n disconnectedCallback() {\n var _a, _b;\n if (this.navigationType === \"side\") {\n (_a = this.parentEl) === null || _a === void 0 ? void 0 : _a.removeEventListener(\"icSideNavExpanded\", this.sideNavExpandHandler);\n }\n else if (this.navigationType === \"top\") {\n (_b = this.parentEl) === null || _b === void 0 ? void 0 : _b.removeEventListener(\"icTopNavResized\", this.topNavResizedHandler);\n }\n }\n componentWillLoad() {\n this.deviceSize = getCurrentDeviceSize();\n const { navType, parent } = getNavItemParentDetails(this.el);\n this.navigationType = navType;\n this.parentEl = parent;\n if (this.navigationType === \"side\") {\n this.parentEl.addEventListener(\"icSideNavExpanded\", this.sideNavExpandHandler);\n }\n else if (this.navigationType === \"top\") {\n this.parentEl.addEventListener(\"icTopNavResized\", this.topNavResizedHandler);\n if (this.deviceSize <=\n this.parentEl.customMobileBreakpoint)\n this.inTopNavSideMenu = true;\n }\n }\n componentDidLoad() {\n this.allGroupedNavigationItems = Array.from(this.el.querySelectorAll(this.IC_NAVIGATION_ITEM));\n /**\n * debounce is required as the incorrect height was retrieved instantly after\n * componentDidLoad is invoked.\n */\n setTimeout(() => this.setInitialGroupedLinksWrapperHeight(), this.DYNAMIC_GROUPED_LINKS_HEIGHT_MS);\n }\n childBlurHandler() {\n this.hideDropdown();\n }\n navItemClickHandler() {\n this.hideDropdown();\n }\n themeChangeHandler(ev) {\n const theme = ev.detail;\n this.focusStyle = theme.mode;\n }\n /**\n * Sets focus on the nav item.\n */\n async setFocus() {\n if (this.groupEl) {\n this.groupEl.focus();\n }\n }\n toggleDropdown() {\n this.dropdownOpen = !this.dropdownOpen;\n }\n showDropdown() {\n if (!this.dropdownOpen) {\n this.toggleDropdown();\n }\n }\n hideDropdown() {\n document.removeEventListener(\"keydown\", this.handleKeydown);\n if (this.dropdownOpen) {\n this.toggleDropdown();\n }\n }\n setGroupedLinksElementHeight(groupedNavItemWrapper, height) {\n groupedNavItemWrapper.style.setProperty(\"--navigation-child-items-height\", height);\n }\n render() {\n const { label, dropdownOpen, inTopNavSideMenu, expandable } = this;\n return (h(Host, { class: {\n [\"in-side-menu\"]: inTopNavSideMenu,\n \"ic-navigation-group-expanded\": this.expanded,\n \"ic-navigation-group-collapsed\": !this.expanded,\n [\"ic-navigation-group-side-nav\"]: this.navigationType === \"side\",\n }, role: \"listitem\" }, h(\"button\", { onMouseEnter: !inTopNavSideMenu &&\n this.navigationType === \"top\" &&\n this.handleMouseEnter, onMouseLeave: this.navigationType === \"top\" && this.handleMouseLeave, tabindex: inTopNavSideMenu && !expandable ? \"-1\" : \"0\", onBlur: this.handleBlur, onClick: expandable ? this.handleClick : null, onKeyDown: this.handleKeydown, class: {\n [\"navigation-group\"]: true,\n [this.focusStyle]: !inTopNavSideMenu,\n [\"navigation-group-side-menu\"]: inTopNavSideMenu && !expandable,\n [\"navigation-group-side-menu-collapsed\"]: inTopNavSideMenu && expandable && !dropdownOpen,\n [\"navigation-group-side-menu-expanded\"]: inTopNavSideMenu && expandable && dropdownOpen,\n [\"selected\"]: dropdownOpen && !inTopNavSideMenu,\n }, ref: (el) => (this.groupEl = el), \"aria-expanded\": `${dropdownOpen || this.expanded}`, \"aria-haspopup\": `${!inTopNavSideMenu && this.navigationType === \"top\"}` }, h(\"ic-typography\", { variant: this.navigationType === \"side\" ? \"caption\" : \"label\" }, label), this.navigationType === \"side\" && expandable && (h(\"div\", { class: {\n \"chevron-toggle-icon-wrapper\": true,\n \"chevron-toggle-icon-closed\": this.expanded,\n }, innerHTML: chevronIcon }))), this.renderNavigationItems()));\n }\n static get is() { return \"ic-navigation-group\"; }\n static get encapsulation() { return \"shadow\"; }\n static get delegatesFocus() { return true; }\n static get originalStyleUrls() {\n return {\n \"$\": [\"ic-navigation-group.css\"]\n };\n }\n static get styleUrls() {\n return {\n \"$\": [\"ic-navigation-group.css\"]\n };\n }\n static get properties() {\n return {\n \"expandable\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": false,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, the group will be expandable in the side menu.\"\n },\n \"attribute\": \"expandable\",\n \"reflect\": false,\n \"defaultValue\": \"false\"\n },\n \"label\": {\n \"type\": \"string\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"string\",\n \"resolved\": \"string\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": false,\n \"docs\": {\n \"tags\": [],\n \"text\": \"The label to display on the group.\"\n },\n \"attribute\": \"label\",\n \"reflect\": false\n }\n };\n }\n static get states() {\n return {\n \"deviceSize\": {},\n \"dropdownOpen\": {},\n \"expanded\": {},\n \"focusStyle\": {},\n \"inTopNavSideMenu\": {},\n \"navigationType\": {},\n \"parentEl\": {}\n };\n }\n static get methods() {\n return {\n \"setFocus\": {\n \"complexType\": {\n \"signature\": \"() => Promise<void>\",\n \"parameters\": [],\n \"references\": {\n \"Promise\": {\n \"location\": \"global\",\n \"id\": \"global::Promise\"\n }\n },\n \"return\": \"Promise<void>\"\n },\n \"docs\": {\n \"text\": \"Sets focus on the nav item.\",\n \"tags\": []\n }\n }\n };\n }\n static get elementRef() { return \"el\"; }\n static get listeners() {\n return [{\n \"name\": \"childBlur\",\n \"method\": \"childBlurHandler\",\n \"target\": undefined,\n \"capture\": false,\n \"passive\": false\n }, {\n \"name\": \"navItemClicked\",\n \"method\": \"navItemClickHandler\",\n \"target\": undefined,\n \"capture\": false,\n \"passive\": false\n }, {\n \"name\": \"themeChange\",\n \"method\": \"themeChangeHandler\",\n \"target\": \"document\",\n \"capture\": false,\n \"passive\": false\n }];\n }\n}\n//# sourceMappingURL=ic-navigation-group.js.map\n"],"mappings":"sJAAA,MAAMA,EAAuB,w2O,MCGhBC,EAAe,MACxB,WAAAC,CAAAC,G,UACIC,KAAKC,0BAA4B,GACjCD,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AAM,CAAEpC,MAAO,CACjB,CAAC,gBAAiBzC,EAClB,+BAAgC1B,KAAKgB,SACrC,iCAAkChB,KAAKgB,SACvC,CAAC,gCAAiChB,KAAK6C,iBAAmB,QAC3D2D,KAAM,YAActC,EAAE,SAAU,CAAEuC,cAAe/E,GAChD1B,KAAK6C,iBAAmB,OACxB7C,KAAK8D,iBAAkBM,aAAcpE,KAAK6C,iBAAmB,OAAS7C,KAAKwD,iBAAkBkD,SAAUhF,IAAqBiD,EAAa,KAAO,IAAKgC,OAAQ3G,KAAK+C,WAAY6D,QAASjC,EAAa3E,KAAK2C,YAAc,KAAMkE,UAAW7G,KAAKsD,cAAea,MAAO,CACnQ,CAAC,oBAAqB,KACtB,CAACnE,KAAK6E,aAAcnD,EACpB,CAAC,8BAA+BA,IAAqBiD,EACrD,CAAC,wCAAyCjD,GAAoBiD,IAAed,EAC7E,CAAC,uCAAwCnC,GAAoBiD,GAAcd,EAC3E,CAAC,YAAaA,IAAiBnC,GAChC2C,IAAMxD,GAAQb,KAAKkG,QAAUrF,EAAK,gBAAiB,GAAGgD,GAAgB7D,KAAKgB,WAAY,gBAAiB,IAAIU,GAAoB1B,KAAK6C,iBAAmB,SAAWqB,EAAE,gBAAiB,CAAE4C,QAAS9G,KAAK6C,iBAAmB,OAAS,UAAY,SAAWmC,GAAQhF,KAAK6C,iBAAmB,QAAU8B,GAAeT,EAAE,MAAO,CAAEC,MAAO,CACnU,8BAA+B,KAC/B,6BAA8BnE,KAAKgB,UACpC+F,UAAWC,KAAkBhH,KAAK0E,wB,CAI7C,yBAAWuC,GAAmB,OAAO,IAAK,C"}
|
@@ -0,0 +1,2 @@
|
|
1
|
+
import{r as e,c as t,f as i,h as a,H as r,g as n}from"./p-8455d1bb.js";import{c as o}from"./p-e081702e.js";import{c as s,i as l,V as c,I as d}from"./p-043cf5de.js";const u='/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0;}[type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}[type="search"]{-webkit-appearance:textfield;outline-offset:-2px;}[type="search"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}:host{display:block}:host ::slotted(ic-typography){--ic-typography-color:var(--ic-alert-description)}.container{min-height:3.5rem;border-radius:var(--ic-border-radius);position:relative;display:flex;align-items:center}.container-neutral{background-color:var(--ic-alert-background-neutral)}.container-info{background-color:var(--ic-alert-background-info)}.container-warning{background-color:var(--ic-alert-background-warning)}.container-error{background-color:var(--ic-alert-background-error)}.container-success{background-color:var(--ic-alert-background-success)}.alert-icon-container{height:100%;display:flex;align-items:center}.divider{height:100%;width:var(--ic-space-xs);border-radius:var(--ic-space-xxxs) 0 0 var(--ic-space-xxxs);position:absolute}.divider-neutral{background-color:var(--ic-alert-status-type-neutral)}.divider-info{background-color:var(--ic-alert-status-type-info)}.divider-warning{background-color:var(--ic-alert-status-type-warning)}.divider-error{background-color:var(--ic-alert-status-type-error)}.divider-success{background-color:var(--ic-alert-status-type-success)}.alert-icon{height:var(--ic-space-lg);width:1.375rem;margin-left:1.125rem}.icon-placeholder{margin-left:var(--ic-space-xs)}.alert-icon>svg{height:var(--ic-space-lg);width:var(--ic-space-lg);display:inline-block}:host([showdefaulticon="false"]) .icon-neutral{visibility:hidden;width:0;margin-left:0.625rem}.icon-neutral>svg,::slotted(svg){height:var(--ic-space-lg);width:var(--ic-space-lg);display:inline-block;fill:var(--ic-alert-icon-neutral)}:host([variant="info"]) .alert-icon svg{fill:var(--ic-alert-icon-info)}:host([variant="warning"]) .alert-icon svg{fill:var(--ic-alert-icon-warning)}:host([variant="error"]) .alert-icon svg{fill:var(--ic-alert-icon-error)}:host([variant="success"]) .alert-icon svg{fill:var(--ic-alert-icon-success)}.alert-content{display:flex;align-items:center;margin-left:0.625rem;width:100%}.alert-message{display:flex;align-items:center;padding:var(--ic-space-xs) var(--ic-space-xs) var(--ic-space-xs) 0;flex:1;--ic-typography-color:var(--ic-alert-description)}.alert-message-title-above{display:inline}.alert-title{margin-right:var(--ic-space-xs);--ic-typography-color:var(--ic-alert-title)}.alert-title-above{white-space:normal}.alert-action-container{margin-right:var(--ic-space-xs);display:flex;align-items:center}.dismiss-icon{margin-right:var(--ic-space-xxxs);margin-left:-0.375rem;padding:0.375rem;border:none;border-radius:50%;background-color:inherit;display:flex;align-items:center;justify-content:center}.dismiss-icon>svg{color:var(--ic-alert-icon-dismissible)}.dismiss-icon:hover{cursor:pointer}@media (max-width: 628px){.alert-content{display:flex;flex-direction:column;align-items:flex-start}.alert-message{display:flex;flex-direction:column;align-items:flex-start}.alert-title{white-space:normal}.alert-action-container{margin-bottom:var(--ic-space-xs)}}@media (forced-colors: active){.container{border:var(--ic-border-hc)}}';const p=class{constructor(a){e(this,a);this.icDismiss=t(this,"icDismiss",7);this.hostMutationObserver=null;this.dismissAction=()=>{this.icDismiss.emit()};this.hostMutationCallback=e=>{if(e.some((({type:e,addedNodes:t,removedNodes:i})=>e==="childList"?s(t,i,"action"):false))){i(this)}};this.alertTitleWrap=false;this.visible=true;this.announced=true;this.dismissible=false;this.heading="";this.message=undefined;this.showDefaultIcon=true;this.theme="inherit";this.titleAbove=false;this.variant="neutral"}disconnectedCallback(){var e;(e=this.hostMutationObserver)===null||e===void 0?void 0:e.disconnect()}componentDidLoad(){this.alertTitleShouldWrap();this.hostMutationObserver=new MutationObserver(this.hostMutationCallback);this.hostMutationObserver.observe(this.el,{childList:true})}handleClick(){this.visible=!this.visible}alertTitleShouldWrap(){var e;const t=(e=this.el.shadowRoot.querySelector(".alert-title"))===null||e===void 0?void 0:e.clientHeight;if(t>24)this.alertTitleWrap=true}render(){const{variant:e,heading:t,message:i,titleAbove:n,dismissible:s,announced:u,visible:p,showDefaultIcon:h,theme:m}=this;return p&&a(r,{role:u?"alert":null,class:{[d.Dark]:true,[`ic-theme-${m}`]:m!=="inherit"}},a("div",{class:{["container"]:true,[`container-${e}`]:true}},a("div",{class:"alert-icon-container"},a("div",{class:{["divider"]:true,[`divider-${e}`]:true}}),e==="neutral"?l(this.el,"neutral-icon")?a("div",{class:"alert-icon svg-container icon-neutral"},a("slot",{name:"neutral-icon"})):h?a("span",{class:{["alert-icon"]:true,["svg-container"]:true,[`icon-${e}`]:true},innerHTML:c[e].icon}):a("div",{class:"icon-placeholder"}):a("span",{class:{["alert-icon"]:true,["svg-container"]:true,[`icon-${e}`]:true},innerHTML:c[e].icon})),a("div",{class:"alert-content"},a("div",{class:{["alert-message"]:true,["alert-message-title-above"]:n||this.alertTitleWrap}},t&&a("ic-typography",{class:{["alert-title"]:true,["alert-title-above"]:n||this.alertTitleWrap},variant:"subtitle-large"},a("p",null,t)),a("slot",{name:"message"},a("ic-typography",{variant:"body"},i))),l(this.el,"action")&&a("div",{class:"alert-action-container"},a("slot",{name:"action"}))),a("div",{class:"dismiss-icon-container"},s&&a("ic-button",{class:{["svg-container"]:true,["dismiss-icon"]:true},innerHTML:o,onClick:this.dismissAction,variant:"icon",title:"dismiss"}))))}get el(){return n(this)}};p.style=u;export{p as ic_alert};
|
2
|
+
//# sourceMappingURL=p-f3f9acbb.entry.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"names":["icAlertCss","Alert","constructor","hostRef","this","hostMutationObserver","dismissAction","icDismiss","emit","hostMutationCallback","mutationList","some","type","addedNodes","removedNodes","checkSlotInChildMutations","forceUpdate","alertTitleWrap","visible","announced","dismissible","heading","message","undefined","showDefaultIcon","theme","titleAbove","variant","disconnectedCallback","_a","disconnect","componentDidLoad","alertTitleShouldWrap","MutationObserver","observe","el","childList","handleClick","titleHeight","shadowRoot","querySelector","clientHeight","render","h","Host","role","class","IcThemeForegroundEnum","Dark","isSlotUsed","name","innerHTML","VARIANT_ICONS","icon","closeIcon","onClick","title"],"sources":["../web-components/dist/collection/components/ic-alert/ic-alert.css?tag=ic-alert&encapsulation=shadow","../web-components/dist/collection/components/ic-alert/ic-alert.js"],"sourcesContent":["/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */\n\n/* Document\n ========================================================================== */\n\n/**\n * 1. Correct the line height in all browsers.\n * 2. Prevent adjustments of font size after orientation changes in iOS.\n */\n\nhtml {\n line-height: 1.15; /* 1 */\n -webkit-text-size-adjust: 100%; /* 2 */\n}\n\n/* Sections\n ========================================================================== */\n\n/**\n * Remove the margin in all browsers.\n */\n\nbody {\n margin: 0;\n}\n\n/**\n * Render the `main` element consistently in IE.\n */\n\nmain {\n display: block;\n}\n\n/**\n * Correct the font size and margin on `h1` elements within `section` and\n * `article` contexts in Chrome, Firefox, and Safari.\n */\n\nh1 {\n font-size: 2em;\n margin: 0.67em 0;\n}\n\n/* Grouping content\n ========================================================================== */\n\n/**\n * 1. Add the correct box sizing in Firefox.\n * 2. Show the overflow in Edge and IE.\n */\n\nhr {\n box-sizing: content-box; /* 1 */\n height: 0; /* 1 */\n overflow: visible; /* 2 */\n}\n\n/**\n * 1. Correct the inheritance and scaling of font size in all browsers.\n * 2. Correct the odd `em` font sizing in all browsers.\n */\n\npre {\n font-family: monospace, monospace; /* 1 */\n font-size: 1em; /* 2 */\n}\n\n/* Text-level semantics\n ========================================================================== */\n\n/**\n * Remove the gray background on active links in IE 10.\n */\n\na {\n background-color: transparent;\n}\n\n/**\n * 1. Remove the bottom border in Chrome 57-\n * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.\n */\n\nabbr[title] {\n border-bottom: none; /* 1 */\n text-decoration: underline; /* 2 */\n -webkit-text-decoration: underline dotted;\n text-decoration: underline dotted; /* 2 */\n}\n\n/**\n * Add the correct font weight in Chrome, Edge, and Safari.\n */\n\nb,\nstrong {\n font-weight: bolder;\n}\n\n/**\n * 1. Correct the inheritance and scaling of font size in all browsers.\n * 2. Correct the odd `em` font sizing in all browsers.\n */\n\ncode,\nkbd,\nsamp {\n font-family: monospace, monospace; /* 1 */\n font-size: 1em; /* 2 */\n}\n\n/**\n * Add the correct font size in all browsers.\n */\n\nsmall {\n font-size: 80%;\n}\n\n/**\n * Prevent `sub` and `sup` elements from affecting the line height in\n * all browsers.\n */\n\nsub,\nsup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\nsub {\n bottom: -0.25em;\n}\n\nsup {\n top: -0.5em;\n}\n\n/* Embedded content\n ========================================================================== */\n\n/**\n * Remove the border on images inside links in IE 10.\n */\n\nimg {\n border-style: none;\n}\n\n/* Forms\n ========================================================================== */\n\n/**\n * 1. Change the font styles in all browsers.\n * 2. Remove the margin in Firefox and Safari.\n */\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n font-family: inherit; /* 1 */\n font-size: 100%; /* 1 */\n line-height: 1.15; /* 1 */\n margin: 0; /* 2 */\n}\n\n/**\n * Show the overflow in IE.\n * 1. Show the overflow in Edge.\n */\n\nbutton,\ninput {\n /* 1 */\n overflow: visible;\n}\n\n/**\n * Remove the inheritance of text transform in Edge, Firefox, and IE.\n * 1. Remove the inheritance of text transform in Firefox.\n */\n\nbutton,\nselect {\n /* 1 */\n text-transform: none;\n}\n\n/**\n * Correct the inability to style clickable types in iOS and Safari.\n */\n\nbutton,\n[type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"] {\n -webkit-appearance: button;\n}\n\n/**\n * Remove the inner border and padding in Firefox.\n */\n\nbutton::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner {\n border-style: none;\n padding: 0;\n}\n\n/**\n * Restore the focus styles unset by the previous rule.\n */\n\nbutton:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring {\n outline: 1px dotted ButtonText;\n}\n\n/**\n * Correct the padding in Firefox.\n */\n\nfieldset {\n padding: 0.35em 0.75em 0.625em;\n}\n\n/**\n * 1. Correct the text wrapping in Edge and IE.\n * 2. Correct the color inheritance from `fieldset` elements in IE.\n * 3. Remove the padding so developers are not caught out when they zero out\n * `fieldset` elements in all browsers.\n */\n\nlegend {\n box-sizing: border-box; /* 1 */\n color: inherit; /* 2 */\n display: table; /* 1 */\n max-width: 100%; /* 1 */\n padding: 0; /* 3 */\n white-space: normal; /* 1 */\n}\n\n/**\n * Add the correct vertical alignment in Chrome, Firefox, and Opera.\n */\n\nprogress {\n vertical-align: baseline;\n}\n\n/**\n * Remove the default vertical scrollbar in IE 10+.\n */\n\ntextarea {\n overflow: auto;\n}\n\n/**\n * 1. Add the correct box sizing in IE 10.\n * 2. Remove the padding in IE 10.\n */\n\n[type=\"checkbox\"],\n[type=\"radio\"] {\n box-sizing: border-box; /* 1 */\n padding: 0; /* 2 */\n}\n\n/**\n * Correct the cursor style of increment and decrement buttons in Chrome.\n */\n\n[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button {\n height: auto;\n}\n\n/**\n * 1. Correct the odd appearance in Chrome and Safari.\n * 2. Correct the outline style in Safari.\n */\n\n[type=\"search\"] {\n -webkit-appearance: textfield; /* 1 */\n outline-offset: -2px; /* 2 */\n}\n\n/**\n * Remove the inner padding in Chrome and Safari on macOS.\n */\n\n[type=\"search\"]::-webkit-search-decoration {\n -webkit-appearance: none;\n}\n\n/**\n * 1. Correct the inability to style clickable types in iOS and Safari.\n * 2. Change font properties to `inherit` in Safari.\n */\n\n::-webkit-file-upload-button {\n -webkit-appearance: button; /* 1 */\n font: inherit; /* 2 */\n}\n\n/* Interactive\n ========================================================================== */\n\n/*\n * Add the correct display in Edge, IE 10+, and Firefox.\n */\n\ndetails {\n display: block;\n}\n\n/*\n * Add the correct display in all browsers.\n */\n\nsummary {\n display: list-item;\n}\n\n/* Misc\n ========================================================================== */\n\n/**\n * Add the correct display in IE 10+.\n */\n\ntemplate {\n display: none;\n}\n\n/**\n * Add the correct display in IE 10.\n */\n\n[hidden] {\n display: none;\n}\n\nhtml,\nbody,\ndiv,\nspan,\napplet,\nobject,\niframe,\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\np,\nblockquote,\npre,\na,\nabbr,\nacronym,\naddress,\nbig,\ncite,\ncode,\ndel,\ndfn,\nem,\nimg,\nins,\nkbd,\nq,\ns,\nsamp,\nsmall,\nstrike,\nstrong,\nsub,\nsup,\ntt,\nvar,\nb,\nu,\ni,\ncenter,\ndl,\ndt,\ndd,\nol,\nul,\nli,\nfieldset,\nform,\nlabel,\nlegend,\ntable,\ncaption,\ntbody,\ntfoot,\nthead,\ntr,\nth,\ntd,\narticle,\naside,\ncanvas,\ndetails,\nembed,\nfigure,\nfigcaption,\nfooter,\nheader,\nhgroup,\nmenu,\nnav,\noutput,\nruby,\nsection,\nsummary,\ntime,\nmark,\naudio,\nvideo {\n margin: 0;\n padding: 0;\n border: 0;\n font-size: 100%;\n font-style: inherit;\n vertical-align: baseline;\n}\n\n\n:host {\n display: block;\n}\n\n:host ::slotted(ic-typography) {\n --ic-typography-color: var(--ic-alert-description);\n}\n\n.container {\n min-height: 3.5rem;\n border-radius: var(--ic-border-radius);\n position: relative;\n display: flex;\n align-items: center;\n}\n\n.container-neutral {\n background-color: var(--ic-alert-background-neutral);\n}\n\n.container-info {\n background-color: var(--ic-alert-background-info);\n}\n\n.container-warning {\n background-color: var(--ic-alert-background-warning);\n}\n\n.container-error {\n background-color: var(--ic-alert-background-error);\n}\n\n.container-success {\n background-color: var(--ic-alert-background-success);\n}\n\n.alert-icon-container {\n height: 100%;\n display: flex;\n align-items: center;\n}\n\n.divider {\n height: 100%;\n width: var(--ic-space-xs);\n border-radius: var(--ic-space-xxxs) 0 0 var(--ic-space-xxxs);\n position: absolute;\n}\n\n.divider-neutral {\n background-color: var(--ic-alert-status-type-neutral);\n}\n\n.divider-info {\n background-color: var(--ic-alert-status-type-info);\n}\n\n.divider-warning {\n background-color: var(--ic-alert-status-type-warning);\n}\n\n.divider-error {\n background-color: var(--ic-alert-status-type-error);\n}\n\n.divider-success {\n background-color: var(--ic-alert-status-type-success);\n}\n\n.alert-icon {\n height: var(--ic-space-lg);\n width: 1.375rem;\n margin-left: 1.125rem;\n}\n\n.icon-placeholder {\n margin-left: var(--ic-space-xs);\n}\n\n.alert-icon > svg {\n height: var(--ic-space-lg);\n width: var(--ic-space-lg);\n display: inline-block;\n}\n\n/* required for Gatsby as prop does not seem to work when set to false */\n:host([showdefaulticon=\"false\"]) .icon-neutral {\n visibility: hidden;\n width: 0;\n margin-left: 0.625rem;\n}\n\n.icon-neutral > svg,\n::slotted(svg) {\n height: var(--ic-space-lg);\n width: var(--ic-space-lg);\n display: inline-block;\n fill: var(--ic-alert-icon-neutral);\n}\n\n:host([variant=\"info\"]) .alert-icon svg {\n fill: var(--ic-alert-icon-info);\n}\n\n:host([variant=\"warning\"]) .alert-icon svg {\n fill: var(--ic-alert-icon-warning);\n}\n\n:host([variant=\"error\"]) .alert-icon svg {\n fill: var(--ic-alert-icon-error);\n}\n\n:host([variant=\"success\"]) .alert-icon svg {\n fill: var(--ic-alert-icon-success);\n}\n\n.alert-content {\n display: flex;\n align-items: center;\n margin-left: 0.625rem;\n width: 100%;\n}\n\n.alert-message {\n display: flex;\n align-items: center;\n padding: var(--ic-space-xs) var(--ic-space-xs) var(--ic-space-xs) 0;\n flex: 1;\n --ic-typography-color: var(--ic-alert-description);\n}\n\n.alert-message-title-above {\n display: inline;\n}\n\n.alert-title {\n margin-right: var(--ic-space-xs);\n --ic-typography-color: var(--ic-alert-title);\n}\n\n.alert-title-above {\n white-space: normal;\n}\n\n.alert-action-container {\n margin-right: var(--ic-space-xs);\n display: flex;\n align-items: center;\n}\n\n.dismiss-icon {\n margin-right: var(--ic-space-xxxs);\n margin-left: -0.375rem;\n padding: 0.375rem;\n border: none;\n border-radius: 50%;\n background-color: inherit;\n display: flex;\n align-items: center;\n justify-content: center;\n}\n\n.dismiss-icon > svg {\n color: var(--ic-alert-icon-dismissible);\n}\n\n.dismiss-icon:hover {\n cursor: pointer;\n}\n\n@media (max-width: 628px) {\n .alert-content {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n }\n\n .alert-message {\n display: flex;\n flex-direction: column;\n align-items: flex-start;\n }\n\n .alert-title {\n white-space: normal;\n }\n\n .alert-action-container {\n margin-bottom: var(--ic-space-xs);\n }\n}\n\n@media (forced-colors: active) {\n .container {\n border: var(--ic-border-hc);\n }\n}\n","import { Host, h, forceUpdate, } from \"@stencil/core\";\nimport closeIcon from \"../../assets/close-icon.svg\";\nimport { isSlotUsed, checkSlotInChildMutations } from \"../../utils/helpers\";\nimport { IcThemeForegroundEnum, } from \"../../utils/types\";\nimport { VARIANT_ICONS } from \"../../utils/constants\";\n/**\n * @slot message - Content is placed to the right of the title.\n * @slot action - Content is placed to the right of the message.\n * @slot neutral-icon - A custom neutral icon is placed to the left of the title. This will override the default icon if used.\n */\nexport class Alert {\n constructor() {\n this.hostMutationObserver = null;\n this.dismissAction = () => {\n this.icDismiss.emit();\n };\n this.hostMutationCallback = (mutationList) => {\n if (mutationList.some(({ type, addedNodes, removedNodes }) => type === \"childList\"\n ? checkSlotInChildMutations(addedNodes, removedNodes, \"action\")\n : false)) {\n forceUpdate(this);\n }\n };\n this.alertTitleWrap = false;\n this.visible = true;\n this.announced = true;\n this.dismissible = false;\n this.heading = \"\";\n this.message = undefined;\n this.showDefaultIcon = true;\n this.theme = \"inherit\";\n this.titleAbove = false;\n this.variant = \"neutral\";\n }\n disconnectedCallback() {\n var _a;\n (_a = this.hostMutationObserver) === null || _a === void 0 ? void 0 : _a.disconnect();\n }\n componentDidLoad() {\n this.alertTitleShouldWrap();\n this.hostMutationObserver = new MutationObserver(this.hostMutationCallback);\n this.hostMutationObserver.observe(this.el, {\n childList: true,\n });\n }\n handleClick() {\n this.visible = !this.visible;\n }\n alertTitleShouldWrap() {\n var _a;\n const titleHeight = (_a = this.el.shadowRoot.querySelector(\".alert-title\")) === null || _a === void 0 ? void 0 : _a.clientHeight;\n if (titleHeight > 24)\n this.alertTitleWrap = true;\n }\n render() {\n const { variant, heading, message, titleAbove, dismissible, announced, visible, showDefaultIcon, theme, } = this;\n return (visible && (h(Host, { role: announced ? \"alert\" : null, class: {\n [IcThemeForegroundEnum.Dark]: true,\n [`ic-theme-${theme}`]: theme !== \"inherit\",\n } }, h(\"div\", { class: {\n [\"container\"]: true,\n [`container-${variant}`]: true,\n } }, h(\"div\", { class: \"alert-icon-container\" }, h(\"div\", { class: {\n [\"divider\"]: true,\n [`divider-${variant}`]: true,\n } }), variant === \"neutral\" ? (isSlotUsed(this.el, \"neutral-icon\") ? (h(\"div\", { class: \"alert-icon svg-container icon-neutral\" }, h(\"slot\", { name: \"neutral-icon\" }))) : showDefaultIcon ? (h(\"span\", { class: {\n [\"alert-icon\"]: true,\n [\"svg-container\"]: true,\n [`icon-${variant}`]: true,\n }, innerHTML: VARIANT_ICONS[variant].icon })) : (h(\"div\", { class: \"icon-placeholder\" }))) : (h(\"span\", { class: {\n [\"alert-icon\"]: true,\n [\"svg-container\"]: true,\n [`icon-${variant}`]: true,\n }, innerHTML: VARIANT_ICONS[variant].icon }))), h(\"div\", { class: \"alert-content\" }, h(\"div\", { class: {\n [\"alert-message\"]: true,\n [\"alert-message-title-above\"]: titleAbove || this.alertTitleWrap,\n } }, heading && (h(\"ic-typography\", { class: {\n [\"alert-title\"]: true,\n [\"alert-title-above\"]: titleAbove || this.alertTitleWrap,\n }, variant: \"subtitle-large\" }, h(\"p\", null, heading))), h(\"slot\", { name: \"message\" }, h(\"ic-typography\", { variant: \"body\" }, message))), isSlotUsed(this.el, \"action\") && (h(\"div\", { class: \"alert-action-container\" }, h(\"slot\", { name: \"action\" })))), h(\"div\", { class: \"dismiss-icon-container\" }, dismissible && (h(\"ic-button\", { class: {\n [\"svg-container\"]: true,\n [\"dismiss-icon\"]: true,\n }, innerHTML: closeIcon, onClick: this.dismissAction, variant: \"icon\", title: \"dismiss\" })))))));\n }\n static get is() { return \"ic-alert\"; }\n static get encapsulation() { return \"shadow\"; }\n static get originalStyleUrls() {\n return {\n \"$\": [\"ic-alert.css\"]\n };\n }\n static get styleUrls() {\n return {\n \"$\": [\"ic-alert.css\"]\n };\n }\n static get properties() {\n return {\n \"announced\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, the alert will have the 'alert' ARIA role and will be announced to screen readers.\"\n },\n \"attribute\": \"announced\",\n \"reflect\": false,\n \"defaultValue\": \"true\"\n },\n \"dismissible\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, the alert will have a close icon at the end to dismiss it.\"\n },\n \"attribute\": \"dismissible\",\n \"reflect\": false,\n \"defaultValue\": \"false\"\n },\n \"heading\": {\n \"type\": \"string\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"string\",\n \"resolved\": \"string\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"The optional title to display at the start of the alert.\"\n },\n \"attribute\": \"heading\",\n \"reflect\": false,\n \"defaultValue\": \"\\\"\\\"\"\n },\n \"message\": {\n \"type\": \"string\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"string\",\n \"resolved\": \"string\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"The main body message of the alert.\"\n },\n \"attribute\": \"message\",\n \"reflect\": false\n },\n \"showDefaultIcon\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": false,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, the default icon for the neutral variant will appear on the left of the alert.\"\n },\n \"attribute\": \"show-default-icon\",\n \"reflect\": false,\n \"defaultValue\": \"true\"\n },\n \"theme\": {\n \"type\": \"string\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"IcThemeMode\",\n \"resolved\": \"\\\"dark\\\" | \\\"inherit\\\" | \\\"light\\\"\",\n \"references\": {\n \"IcThemeMode\": {\n \"location\": \"import\",\n \"path\": \"../../utils/types\",\n \"id\": \"src/utils/types.ts::IcThemeMode\"\n }\n }\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"Sets the theme color to the dark or light theme color. \\\"inherit\\\" will set the color based on the system settings or ic-theme component.\"\n },\n \"attribute\": \"theme\",\n \"reflect\": false,\n \"defaultValue\": \"\\\"inherit\\\"\"\n },\n \"titleAbove\": {\n \"type\": \"boolean\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"boolean\",\n \"resolved\": \"boolean\",\n \"references\": {}\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"If `true`, the title and message will appear above and below instead of inline.\"\n },\n \"attribute\": \"title-above\",\n \"reflect\": false,\n \"defaultValue\": \"false\"\n },\n \"variant\": {\n \"type\": \"string\",\n \"mutable\": false,\n \"complexType\": {\n \"original\": \"IcStatusVariants\",\n \"resolved\": \"\\\"error\\\" | \\\"info\\\" | \\\"neutral\\\" | \\\"success\\\" | \\\"warning\\\"\",\n \"references\": {\n \"IcStatusVariants\": {\n \"location\": \"import\",\n \"path\": \"../../utils/types\",\n \"id\": \"src/utils/types.ts::IcStatusVariants\"\n }\n }\n },\n \"required\": false,\n \"optional\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"The variant of the alert which will be rendered.\"\n },\n \"attribute\": \"variant\",\n \"reflect\": false,\n \"defaultValue\": \"\\\"neutral\\\"\"\n }\n };\n }\n static get states() {\n return {\n \"alertTitleWrap\": {},\n \"visible\": {}\n };\n }\n static get events() {\n return [{\n \"method\": \"icDismiss\",\n \"name\": \"icDismiss\",\n \"bubbles\": true,\n \"cancelable\": true,\n \"composed\": true,\n \"docs\": {\n \"tags\": [],\n \"text\": \"Is emitted when the user dismisses the alert.\"\n },\n \"complexType\": {\n \"original\": \"void\",\n \"resolved\": \"void\",\n \"references\": {}\n }\n }];\n }\n static get elementRef() { return \"el\"; }\n static get listeners() {\n return [{\n \"name\": \"icDismiss\",\n \"method\": \"handleClick\",\n \"target\": undefined,\n \"capture\": true,\n \"passive\": false\n }];\n }\n}\n//# sourceMappingURL=ic-alert.js.map\n"],"mappings":"oKAAA,MAAMA,EAAa,uvK,MCUNC,EAAK,MACd,WAAAC,CAAAC,G,+CACIC,KAAKC,qBAAuB,KAC5BD,KAAKE,cAAgB,KACjBF,KAAKG,UAAUC,MAAM,EAEzBJ,KAAKK,qBAAwBC,IACzB,GAAIA,EAAaC,MAAK,EAAGC,OAAMC,aAAYC,kBAAmBF,IAAS,YACjEG,EAA0BF,EAAYC,EAAc,UACpD,QAAQ,CACVE,EAAYZ,K,GAGpBA,KAAKa,eAAiB,MACtBb,KAAKc,QAAU,KACfd,KAAKe,UAAY,KACjBf,KAAKgB,YAAc,MACnBhB,KAAKiB,QAAU,GACfjB,KAAKkB,QAAUC,UACfnB,KAAKoB,gBAAkB,KACvBpB,KAAKqB,MAAQ,UACbrB,KAAKsB,WAAa,MAClBtB,KAAKuB,QAAU,S,CAEnB,oBAAAC,GACI,IAAIC,GACHA,EAAKzB,KAAKC,wBAA0B,MAAQwB,SAAY,OAAS,EAAIA,EAAGC,Y,CAE7E,gBAAAC,GACI3B,KAAK4B,uBACL5B,KAAKC,qBAAuB,IAAI4B,iBAAiB7B,KAAKK,sBACtDL,KAAKC,qBAAqB6B,QAAQ9B,KAAK+B,GAAI,CACvCC,UAAW,M,CAGnB,WAAAC,GACIjC,KAAKc,SAAWd,KAAKc,O,CAEzB,oBAAAc,GACI,IAAIH,EACJ,MAAMS,GAAeT,EAAKzB,KAAK+B,GAAGI,WAAWC,cAAc,mBAAqB,MAAQX,SAAY,OAAS,EAAIA,EAAGY,aACpH,GAAIH,EAAc,GACdlC,KAAKa,eAAiB,I,CAE9B,MAAAyB,GACI,MAAMf,QAAEA,EAAON,Q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