@ukic/canary-web-components 3.0.0-canary.33 → 3.0.0-canary.35
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/{OpenInNew-7bac24f7.js → OpenInNew-add95b7b.js} +1 -1
- package/dist/cjs/OpenInNew-add95b7b.js.map +1 -0
- package/dist/{esm/purify-6eaa9893.js → cjs/common-helpers-577fc5b0.js} +22 -2
- package/dist/cjs/common-helpers-577fc5b0.js.map +1 -0
- package/dist/cjs/core.cjs.js +1 -1
- package/dist/cjs/{helpers-2cc5f6db.js → helpers-cb472df9.js} +1 -128
- package/dist/cjs/helpers-cb472df9.js.map +1 -0
- package/dist/cjs/helpers-f81fed28.js.map +1 -1
- package/dist/cjs/ic-badge-27f26087.js +184 -0
- package/dist/cjs/ic-badge-27f26087.js.map +1 -0
- package/dist/cjs/ic-badge.cjs.entry.js +4 -177
- package/dist/cjs/ic-badge.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-button-4c329a7d.js +435 -0
- package/dist/cjs/ic-button-4c329a7d.js.map +1 -0
- package/dist/cjs/ic-button_3.cjs.entry.js +9 -875
- package/dist/cjs/ic-button_3.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-calendar_2.cjs.entry.js +22 -13
- package/dist/cjs/ic-calendar_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-card-horizontal.cjs.entry.js +10 -5
- package/dist/cjs/ic-card-horizontal.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-checkbox-ac44e0a2.js +204 -0
- package/dist/cjs/ic-checkbox-ac44e0a2.js.map +1 -0
- package/dist/cjs/ic-checkbox_3.cjs.entry.js +22 -208
- package/dist/cjs/ic-checkbox_3.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-chip-1ff0950a.js +133 -0
- package/dist/cjs/ic-chip-1ff0950a.js.map +1 -0
- package/dist/cjs/ic-chip.cjs.entry.js +4 -119
- package/dist/cjs/ic-chip.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-data-table-title-bar.cjs.entry.js +19 -4
- package/dist/cjs/ic-data-table-title-bar.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-data-table.cjs.entry.js +18 -10
- package/dist/cjs/ic-data-table.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-date-picker.cjs.entry.js +2 -2
- package/dist/cjs/ic-input-component-container_4.cjs.entry.js +7 -229
- package/dist/cjs/ic-input-component-container_4.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-input-validation-bf7afa43.js +259 -0
- package/dist/cjs/ic-input-validation-bf7afa43.js.map +1 -0
- package/dist/cjs/ic-link-c77848ab.js +111 -0
- package/dist/cjs/ic-link-c77848ab.js.map +1 -0
- package/dist/cjs/ic-link.cjs.entry.js +5 -104
- package/dist/cjs/ic-link.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-loading-indicator-bbd1572c.js +233 -0
- package/dist/cjs/ic-loading-indicator-bbd1572c.js.map +1 -0
- package/dist/cjs/ic-menu-e9a1a0d3.js +987 -0
- package/dist/cjs/ic-menu-e9a1a0d3.js.map +1 -0
- package/dist/cjs/ic-menu.cjs.entry.js +6 -991
- package/dist/cjs/ic-menu.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-navigation-item-59bd8957.js +243 -0
- package/dist/cjs/ic-navigation-item-59bd8957.js.map +1 -0
- package/dist/cjs/ic-navigation-item.cjs.entry.js +5 -232
- package/dist/cjs/ic-navigation-item.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-page-header-3d8b3a59.js +131 -0
- package/dist/cjs/ic-page-header-3d8b3a59.js.map +1 -0
- package/dist/cjs/ic-page-header.cjs.entry.js +4 -124
- package/dist/cjs/ic-page-header.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-pagination_3.cjs.entry.js +16 -0
- package/dist/cjs/ic-pagination_3.cjs.entry.js.map +1 -0
- package/dist/cjs/ic-section-container-128e2db0.js +34 -0
- package/dist/cjs/ic-section-container-128e2db0.js.map +1 -0
- package/dist/cjs/ic-section-container.cjs.entry.js +3 -27
- package/dist/cjs/ic-section-container.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-select-bc8ca251.js +876 -0
- package/dist/cjs/ic-select-bc8ca251.js.map +1 -0
- package/dist/cjs/ic-skip-link-43203eea.js +60 -0
- package/dist/cjs/ic-skip-link-43203eea.js.map +1 -0
- package/dist/cjs/ic-skip-link.cjs.entry.js +3 -53
- package/dist/cjs/ic-skip-link.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-status-tag-a4377a6b.js +55 -0
- package/dist/cjs/ic-status-tag-a4377a6b.js.map +1 -0
- package/dist/cjs/ic-status-tag.cjs.entry.js +4 -48
- package/dist/cjs/ic-status-tag.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-table-of-contents.cjs.entry.js +14 -3
- package/dist/cjs/ic-table-of-contents.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-text-field-5d7ae957.js +732 -0
- package/dist/cjs/ic-text-field-5d7ae957.js.map +1 -0
- package/dist/cjs/ic-theme.cjs.entry.js +2 -2
- package/dist/cjs/ic-theme.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-time-input.cjs.entry.js +17 -7
- package/dist/cjs/ic-time-input.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-time-selector.cjs.entry.js +53 -170
- package/dist/cjs/ic-time-selector.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-toggle-button-ce67a1ec.js +452 -0
- package/dist/cjs/ic-toggle-button-ce67a1ec.js.map +1 -0
- package/dist/cjs/ic-toggle-button_2.cjs.entry.js +5 -445
- package/dist/cjs/ic-toggle-button_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-tooltip-3cc80832.js +239 -0
- package/dist/cjs/ic-tooltip-3cc80832.js.map +1 -0
- package/dist/cjs/ic-top-navigation-a6c4be7b.js +237 -0
- package/dist/cjs/ic-top-navigation-a6c4be7b.js.map +1 -0
- package/dist/cjs/ic-top-navigation.cjs.entry.js +4 -227
- package/dist/cjs/ic-top-navigation.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-tree-item.cjs.entry.js +5 -4
- package/dist/cjs/ic-tree-item.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-tree-view.cjs.entry.js +7 -5
- package/dist/cjs/ic-tree-view.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-typography-a199c128.js +198 -0
- package/dist/cjs/ic-typography-a199c128.js.map +1 -0
- package/dist/cjs/ic-typography.cjs.entry.js +4 -191
- package/dist/cjs/ic-typography.cjs.entry.js.map +1 -1
- package/dist/cjs/index-d337cd8a.js +6 -170
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +28 -76
- package/dist/collection/components/ic-calendar/ic-calendar.js +12 -10
- package/dist/collection/components/ic-calendar/ic-calendar.js.map +1 -1
- package/dist/collection/components/ic-calendar/ic-day-button.js +1 -0
- package/dist/collection/components/ic-calendar/ic-day-button.js.map +1 -1
- package/dist/collection/components/ic-calendar/ic-month-picker.js +1 -0
- package/dist/collection/components/ic-calendar/ic-month-picker.js.map +1 -1
- package/dist/collection/components/ic-calendar/ic-year-picker.js +1 -0
- package/dist/collection/components/ic-calendar/ic-year-picker.js.map +1 -1
- package/dist/collection/components/ic-calendar/test/a11y/ic-calendar.test.a11y.js +1 -1
- package/dist/collection/components/ic-calendar/test/a11y/ic-calendar.test.a11y.js.map +1 -1
- package/dist/collection/components/ic-card-horizontal/ic-card-horizontal.js +9 -5
- package/dist/collection/components/ic-card-horizontal/ic-card-horizontal.js.map +1 -1
- package/dist/collection/components/ic-data-table/ic-data-table.js +15 -8
- package/dist/collection/components/ic-data-table/ic-data-table.js.map +1 -1
- package/dist/collection/components/ic-data-table-title-bar/ic-data-table-title-bar.js +18 -4
- package/dist/collection/components/ic-data-table-title-bar/ic-data-table-title-bar.js.map +1 -1
- package/dist/collection/components/ic-date-input/ic-date-input.js +13 -3
- package/dist/collection/components/ic-date-input/ic-date-input.js.map +1 -1
- package/dist/collection/components/ic-date-input/test/helpers/ic-date-input.js +1 -1
- package/dist/collection/components/ic-date-input/test/helpers/ic-date-input.js.map +1 -1
- package/dist/collection/components/ic-date-picker/ic-date-picker.js +2 -2
- package/dist/collection/components/ic-pagination-bar/ic-pagination-bar.js +19 -12
- package/dist/collection/components/ic-pagination-bar/ic-pagination-bar.js.map +1 -1
- package/dist/collection/components/ic-table-of-contents/ic-table-of-contents-item.js +1 -0
- package/dist/collection/components/ic-table-of-contents/ic-table-of-contents-item.js.map +1 -1
- package/dist/collection/components/ic-table-of-contents/ic-table-of-contents.js +12 -3
- package/dist/collection/components/ic-table-of-contents/ic-table-of-contents.js.map +1 -1
- package/dist/collection/components/ic-time-input/ic-time-input.js +20 -8
- package/dist/collection/components/ic-time-input/ic-time-input.js.map +1 -1
- package/dist/collection/components/ic-time-input/ic-time-input.stories.js +4 -4
- package/dist/collection/components/ic-time-input/ic-time-input.stories.js.map +1 -1
- package/dist/collection/components/ic-time-input/test/helpers/ic-time-input.js +1 -1
- package/dist/collection/components/ic-time-input/test/helpers/ic-time-input.js.map +1 -1
- package/dist/collection/components/ic-time-selector/ic-time-selector.js +55 -200
- package/dist/collection/components/ic-time-selector/ic-time-selector.js.map +1 -1
- package/dist/collection/components/ic-time-selector/ic-time-selector.stories.js +50 -24
- package/dist/collection/components/ic-time-selector/ic-time-selector.stories.js.map +1 -1
- package/dist/collection/components/ic-tree-item/ic-tree-item.js +4 -4
- package/dist/collection/components/ic-tree-item/ic-tree-item.js.map +1 -1
- package/dist/collection/components/ic-tree-view/ic-tree-view.js +5 -3
- package/dist/collection/components/ic-tree-view/ic-tree-view.js.map +1 -1
- package/dist/collection/components/ic-tree-view/ic-tree-view.stories.js +32 -2
- package/dist/collection/components/ic-tree-view/ic-tree-view.stories.js.map +1 -1
- package/dist/collection/utils/types.js.map +1 -1
- package/dist/components/common-helpers.js +1364 -3
- package/dist/components/common-helpers.js.map +1 -1
- package/dist/components/helpers.js +1 -116
- package/dist/components/helpers.js.map +1 -1
- package/dist/components/helpers2.js.map +1 -1
- package/dist/components/ic-badge.d.ts +11 -0
- package/dist/components/ic-badge.js +3 -3
- package/dist/components/ic-badge.js.map +1 -1
- package/dist/components/ic-button.d.ts +11 -0
- package/dist/components/ic-button2.js +5 -5
- package/dist/components/ic-button2.js.map +1 -1
- package/dist/components/ic-calendar2.js +12 -11
- package/dist/components/ic-calendar2.js.map +1 -1
- package/dist/components/ic-card-horizontal.js +6 -5
- package/dist/components/ic-card-horizontal.js.map +1 -1
- package/dist/components/ic-checkbox.d.ts +11 -0
- package/dist/components/ic-checkbox2.js +5 -5
- package/dist/components/ic-checkbox2.js.map +1 -1
- package/dist/components/ic-chip.d.ts +11 -0
- package/dist/components/ic-chip.js +14 -6
- package/dist/components/ic-chip.js.map +1 -1
- package/dist/components/ic-data-table-title-bar.js +18 -7
- package/dist/components/ic-data-table-title-bar.js.map +1 -1
- package/dist/components/ic-data-table.js +34 -40
- package/dist/components/ic-data-table.js.map +1 -1
- package/dist/components/ic-date-input2.js +10 -6
- package/dist/components/ic-date-input2.js.map +1 -1
- package/dist/components/ic-date-picker.js +2 -2
- package/dist/components/ic-empty-state.d.ts +11 -0
- package/dist/components/ic-empty-state2.js +3 -3
- package/dist/components/ic-empty-state2.js.map +1 -1
- package/dist/components/ic-input-component-container.d.ts +11 -0
- package/dist/components/ic-input-component-container2.js +5 -4
- package/dist/components/ic-input-component-container2.js.map +1 -1
- package/dist/components/ic-input-container.d.ts +11 -0
- package/dist/components/ic-input-container2.js +2 -2
- package/dist/components/ic-input-container2.js.map +1 -1
- package/dist/components/ic-input-label.d.ts +11 -0
- package/dist/components/ic-input-label2.js +3 -3
- package/dist/components/ic-input-label2.js.map +1 -1
- package/dist/components/ic-input-validation.d.ts +11 -0
- package/dist/components/ic-input-validation2.js +21 -5
- package/dist/components/ic-input-validation2.js.map +1 -1
- package/dist/components/ic-link.d.ts +11 -0
- package/dist/components/ic-link2.js +2 -2
- package/dist/components/ic-link2.js.map +1 -1
- package/dist/components/ic-loading-indicator.d.ts +11 -0
- package/dist/components/ic-loading-indicator2.js +27 -13
- package/dist/components/ic-loading-indicator2.js.map +1 -1
- package/dist/components/ic-menu.d.ts +11 -0
- package/dist/components/ic-menu2.js +11 -22
- package/dist/components/ic-menu2.js.map +1 -1
- package/dist/components/ic-navigation-item.d.ts +11 -0
- package/dist/components/ic-navigation-item.js +8 -4
- package/dist/components/ic-navigation-item.js.map +1 -1
- package/dist/components/ic-page-header.d.ts +11 -0
- package/dist/components/ic-page-header.js +9 -33
- package/dist/components/ic-page-header.js.map +1 -1
- package/dist/components/ic-pagination-bar2.js +23 -29
- package/dist/components/ic-pagination-bar2.js.map +1 -1
- package/dist/components/ic-pagination.d.ts +11 -0
- package/dist/components/ic-pagination2.js +34 -15
- package/dist/components/ic-pagination2.js.map +1 -1
- package/dist/components/ic-section-container.d.ts +11 -0
- package/dist/components/ic-section-container2.js +2 -2
- package/dist/components/ic-section-container2.js.map +1 -1
- package/dist/components/ic-select.d.ts +11 -0
- package/dist/components/ic-select2.js +7 -7
- package/dist/components/ic-select2.js.map +1 -1
- package/dist/components/ic-skip-link.d.ts +11 -0
- package/dist/components/ic-skip-link.js +2 -2
- package/dist/components/ic-skip-link.js.map +1 -1
- package/dist/components/ic-status-tag.d.ts +11 -0
- package/dist/components/ic-status-tag.js +2 -2
- package/dist/components/ic-status-tag.js.map +1 -1
- package/dist/components/ic-table-of-contents.js +5 -4
- package/dist/components/ic-table-of-contents.js.map +1 -1
- package/dist/components/ic-text-field.d.ts +11 -0
- package/dist/components/ic-text-field2.js +6 -6
- package/dist/components/ic-text-field2.js.map +1 -1
- package/dist/components/ic-theme.d.ts +11 -0
- package/dist/components/ic-theme.js +2 -2
- package/dist/components/ic-theme.js.map +1 -1
- package/dist/components/ic-time-input.js +16 -12
- package/dist/components/ic-time-input.js.map +1 -1
- package/dist/components/ic-time-selector.js +51 -173
- package/dist/components/ic-time-selector.js.map +1 -1
- package/dist/components/ic-toggle-button-group.d.ts +11 -0
- package/dist/components/ic-toggle-button-group2.js +2 -2
- package/dist/components/ic-toggle-button-group2.js.map +1 -1
- package/dist/components/ic-toggle-button.d.ts +11 -0
- package/dist/components/ic-toggle-button2.js +3 -3
- package/dist/components/ic-toggle-button2.js.map +1 -1
- package/dist/components/ic-tooltip.d.ts +11 -0
- package/dist/components/ic-tooltip2.js +3 -3
- package/dist/components/ic-tooltip2.js.map +1 -1
- package/dist/components/ic-top-navigation.d.ts +11 -0
- package/dist/components/ic-top-navigation.js +12 -21
- package/dist/components/ic-top-navigation.js.map +1 -1
- package/dist/components/ic-tree-item.js +4 -5
- package/dist/components/ic-tree-item.js.map +1 -1
- package/dist/components/ic-tree-view.js +5 -4
- package/dist/components/ic-tree-view.js.map +1 -1
- package/dist/components/ic-typography.d.ts +11 -0
- package/dist/components/ic-typography2.js +3 -3
- package/dist/components/ic-typography2.js.map +1 -1
- package/dist/components/success-icon.js +11 -0
- package/dist/components/success-icon.js.map +1 -0
- package/dist/core/core.css +1 -1
- package/dist/core/core.esm.js +1 -1
- package/dist/core/core.esm.js.map +1 -1
- package/dist/core/p-01b04775.js +2 -0
- package/dist/core/p-01b04775.js.map +1 -0
- package/dist/core/p-02d0a238.entry.js +2 -0
- package/dist/core/{p-c4b2774d.entry.js → p-0592277b.js} +2 -2
- package/dist/core/p-0592277b.js.map +1 -0
- package/dist/core/p-0664935b.js +2 -0
- package/dist/core/p-0664935b.js.map +1 -0
- package/dist/core/p-0aa06309.entry.js +2 -0
- package/dist/core/p-0aa06309.entry.js.map +1 -0
- package/dist/core/p-0c02b16c.entry.js +2 -0
- package/dist/core/p-1836fef6.entry.js +2 -0
- package/dist/core/p-1836fef6.entry.js.map +1 -0
- package/dist/core/{p-79ead0e7.entry.js → p-18d5e467.js} +2 -2
- package/dist/core/p-18d5e467.js.map +1 -0
- package/dist/core/p-1ddc08d0.js +2 -0
- package/dist/core/p-1ddc08d0.js.map +1 -0
- package/dist/core/{p-201b41c7.entry.js → p-22267c01.entry.js} +2 -2
- package/dist/core/p-27962d4d.entry.js +2 -0
- package/dist/core/p-384a7f60.entry.js +2 -0
- package/dist/core/p-3ed17bfc.entry.js +2 -0
- package/dist/core/p-3ed17bfc.entry.js.map +1 -0
- package/dist/core/p-42bacb0d.entry.js +2 -0
- package/dist/core/p-42bacb0d.entry.js.map +1 -0
- package/dist/core/p-4385552a.entry.js +2 -0
- package/dist/core/p-4385552a.entry.js.map +1 -0
- package/dist/core/{p-551a0fc1.entry.js → p-510f8257.entry.js} +2 -2
- package/dist/core/p-510f8257.entry.js.map +1 -0
- package/dist/core/{p-939025af.entry.js → p-5585895d.js} +2 -2
- package/dist/core/p-5585895d.js.map +1 -0
- package/dist/core/p-56ef5c79.js +2 -0
- package/dist/core/p-56ef5c79.js.map +1 -0
- package/dist/core/{p-7efdbab8.entry.js → p-5d5b1aa8.js} +2 -2
- package/dist/core/p-5d5b1aa8.js.map +1 -0
- package/dist/core/p-5e14ec1e.entry.js +2 -0
- package/dist/core/p-5e14ec1e.entry.js.map +1 -0
- package/dist/core/p-67a25154.entry.js +2 -0
- package/dist/core/p-67a25154.entry.js.map +1 -0
- package/dist/core/{p-ea1ea1b9.js → p-67a4f674.js} +1 -1
- package/dist/core/p-67a4f674.js.map +1 -0
- package/dist/core/p-6f45df7a.entry.js +2 -0
- package/dist/core/p-6f45df7a.entry.js.map +1 -0
- package/dist/core/{p-33509a89.entry.js → p-7843f9be.js} +2 -2
- package/dist/core/p-7843f9be.js.map +1 -0
- package/dist/core/p-7bbd1881.js +2 -0
- package/dist/core/p-7bbd1881.js.map +1 -0
- package/dist/core/{p-349d91dc.js → p-7d378ee6.js} +3 -3
- package/dist/core/p-7d378ee6.js.map +1 -0
- package/dist/core/p-7e4404fc.entry.js +2 -0
- package/dist/core/p-7e4404fc.entry.js.map +1 -0
- package/dist/core/p-829b34f9.js.map +1 -1
- package/dist/core/p-84129c7e.entry.js +2 -0
- package/dist/core/p-84129c7e.entry.js.map +1 -0
- package/dist/core/p-857362bd.entry.js +2 -0
- package/dist/core/p-857362bd.entry.js.map +1 -0
- package/dist/core/p-883e677d.entry.js +2 -0
- package/dist/core/p-883e677d.entry.js.map +1 -0
- package/dist/core/p-9148bd35.js +2 -0
- package/dist/core/p-9148bd35.js.map +1 -0
- package/dist/core/p-92e447e1.entry.js +2 -0
- package/dist/core/p-92e447e1.entry.js.map +1 -0
- package/dist/core/p-964d0e32.js +2 -0
- package/dist/core/p-964d0e32.js.map +1 -0
- package/dist/core/{p-9ca147f3.entry.js → p-9b218099.js} +2 -2
- package/dist/core/p-9b218099.js.map +1 -0
- package/dist/core/p-a4cb3520.js +2 -0
- package/dist/core/p-a4cb3520.js.map +1 -0
- package/dist/core/p-a50e4bdf.entry.js +2 -0
- package/dist/core/p-a50e4bdf.entry.js.map +1 -0
- package/dist/core/p-b8325ec4.js +2 -0
- package/dist/core/p-b8325ec4.js.map +1 -0
- package/dist/core/p-c1337dbc.entry.js +2 -0
- package/dist/core/p-c1337dbc.entry.js.map +1 -0
- package/dist/core/p-c2669ec9.js +2 -0
- package/dist/core/p-c2669ec9.js.map +1 -0
- package/dist/core/p-c5ac4fcc.entry.js +2 -0
- package/dist/core/p-c5ac4fcc.entry.js.map +1 -0
- package/dist/core/{p-879c180d.entry.js → p-c5d680be.js} +2 -2
- package/dist/core/p-c5d680be.js.map +1 -0
- package/dist/core/p-cd454ff0.entry.js +2 -0
- package/dist/core/p-cd454ff0.entry.js.map +1 -0
- package/dist/core/{p-319e3d5b.entry.js → p-d107dfa8.js} +2 -2
- package/dist/core/p-d107dfa8.js.map +1 -0
- package/dist/core/p-da2a9ddc.js +2 -0
- package/dist/core/p-da2a9ddc.js.map +1 -0
- package/dist/core/p-dc3a13d5.entry.js +2 -0
- package/dist/core/p-dc3a13d5.entry.js.map +1 -0
- package/dist/core/p-f3267773.entry.js +2 -0
- package/dist/core/p-f3267773.entry.js.map +1 -0
- package/dist/core/p-f65f0065.js +2 -0
- package/dist/core/p-f65f0065.js.map +1 -0
- package/dist/core/p-fc239961.entry.js +2 -0
- package/dist/core/p-fc239961.entry.js.map +1 -0
- package/dist/core/p-fd4fd86a.entry.js +2 -0
- package/dist/core/p-fd4fd86a.entry.js.map +1 -0
- package/dist/esm/{OpenInNew-52210a9d.js → OpenInNew-6f820c13.js} +1 -1
- package/dist/esm/OpenInNew-6f820c13.js.map +1 -0
- package/dist/{cjs/purify-039f565a.js → esm/common-helpers-f2174548.js} +18 -3
- package/dist/esm/common-helpers-f2174548.js.map +1 -0
- package/dist/esm/core.js +1 -1
- package/dist/esm/{helpers-063369f4.js → helpers-15fb9b13.js} +2 -117
- package/dist/esm/helpers-15fb9b13.js.map +1 -0
- package/dist/esm/helpers-a08b3f32.js.map +1 -1
- package/dist/esm/ic-badge-5c2b4bc7.js +182 -0
- package/dist/esm/ic-badge-5c2b4bc7.js.map +1 -0
- package/dist/esm/ic-badge.entry.js +3 -180
- package/dist/esm/ic-badge.entry.js.map +1 -1
- package/dist/esm/ic-button-2f9b4e8a.js +433 -0
- package/dist/esm/ic-button-2f9b4e8a.js.map +1 -0
- package/dist/esm/ic-button_3.entry.js +6 -876
- package/dist/esm/ic-button_3.entry.js.map +1 -1
- package/dist/esm/ic-calendar_2.entry.js +22 -13
- package/dist/esm/ic-calendar_2.entry.js.map +1 -1
- package/dist/esm/ic-card-horizontal.entry.js +10 -5
- package/dist/esm/ic-card-horizontal.entry.js.map +1 -1
- package/dist/esm/ic-checkbox-f21a3f00.js +201 -0
- package/dist/esm/ic-checkbox-f21a3f00.js.map +1 -0
- package/dist/esm/ic-checkbox_3.entry.js +17 -203
- package/dist/esm/ic-checkbox_3.entry.js.map +1 -1
- package/dist/esm/ic-chip-b44cea5b.js +131 -0
- package/dist/esm/ic-chip-b44cea5b.js.map +1 -0
- package/dist/esm/ic-chip.entry.js +3 -122
- package/dist/esm/ic-chip.entry.js.map +1 -1
- package/dist/esm/ic-data-table-title-bar.entry.js +19 -4
- package/dist/esm/ic-data-table-title-bar.entry.js.map +1 -1
- package/dist/esm/ic-data-table.entry.js +18 -10
- package/dist/esm/ic-data-table.entry.js.map +1 -1
- package/dist/esm/ic-date-picker.entry.js +2 -2
- package/dist/esm/ic-input-component-container_4.entry.js +3 -229
- package/dist/esm/ic-input-component-container_4.entry.js.map +1 -1
- package/dist/esm/ic-input-validation-cce3bb05.js +254 -0
- package/dist/esm/ic-input-validation-cce3bb05.js.map +1 -0
- package/dist/esm/ic-link-0f6ba1b0.js +109 -0
- package/dist/esm/ic-link-0f6ba1b0.js.map +1 -0
- package/dist/esm/ic-link.entry.js +4 -107
- package/dist/esm/ic-link.entry.js.map +1 -1
- package/dist/esm/ic-loading-indicator-7ec7c6c9.js +231 -0
- package/dist/esm/ic-loading-indicator-7ec7c6c9.js.map +1 -0
- package/dist/esm/ic-menu-c29dda8d.js +985 -0
- package/dist/esm/ic-menu-c29dda8d.js.map +1 -0
- package/dist/esm/ic-menu.entry.js +5 -994
- package/dist/esm/ic-menu.entry.js.map +1 -1
- package/dist/esm/ic-navigation-item-e775ce8c.js +241 -0
- package/dist/esm/ic-navigation-item-e775ce8c.js.map +1 -0
- package/dist/esm/ic-navigation-item.entry.js +4 -235
- package/dist/esm/ic-navigation-item.entry.js.map +1 -1
- package/dist/esm/ic-page-header-a4a552fe.js +129 -0
- package/dist/esm/ic-page-header-a4a552fe.js.map +1 -0
- package/dist/esm/ic-page-header.entry.js +3 -127
- package/dist/esm/ic-page-header.entry.js.map +1 -1
- package/dist/esm/ic-pagination_3.entry.js +6 -0
- package/dist/esm/ic-pagination_3.entry.js.map +1 -0
- package/dist/esm/ic-section-container-3b887eb7.js +32 -0
- package/dist/esm/ic-section-container-3b887eb7.js.map +1 -0
- package/dist/esm/ic-section-container.entry.js +2 -30
- package/dist/esm/ic-section-container.entry.js.map +1 -1
- package/dist/esm/ic-select-cb04ab16.js +874 -0
- package/dist/esm/ic-select-cb04ab16.js.map +1 -0
- package/dist/esm/ic-skip-link-7c9b8269.js +58 -0
- package/dist/esm/ic-skip-link-7c9b8269.js.map +1 -0
- package/dist/esm/ic-skip-link.entry.js +2 -56
- package/dist/esm/ic-skip-link.entry.js.map +1 -1
- package/dist/esm/ic-status-tag-7395532c.js +53 -0
- package/dist/esm/ic-status-tag-7395532c.js.map +1 -0
- package/dist/esm/ic-status-tag.entry.js +3 -51
- package/dist/esm/ic-status-tag.entry.js.map +1 -1
- package/dist/esm/ic-table-of-contents.entry.js +14 -3
- package/dist/esm/ic-table-of-contents.entry.js.map +1 -1
- package/dist/esm/ic-text-field-73754fc7.js +729 -0
- package/dist/esm/ic-text-field-73754fc7.js.map +1 -0
- package/dist/esm/ic-theme.entry.js +2 -2
- package/dist/esm/ic-theme.entry.js.map +1 -1
- package/dist/esm/ic-time-input.entry.js +17 -7
- package/dist/esm/ic-time-input.entry.js.map +1 -1
- package/dist/esm/ic-time-selector.entry.js +53 -170
- package/dist/esm/ic-time-selector.entry.js.map +1 -1
- package/dist/esm/ic-toggle-button-c58aaaec.js +449 -0
- package/dist/esm/ic-toggle-button-c58aaaec.js.map +1 -0
- package/dist/esm/ic-toggle-button_2.entry.js +3 -447
- package/dist/esm/ic-toggle-button_2.entry.js.map +1 -1
- package/dist/esm/ic-tooltip-3c856fa7.js +237 -0
- package/dist/esm/ic-tooltip-3c856fa7.js.map +1 -0
- package/dist/esm/ic-top-navigation-ba78648a.js +235 -0
- package/dist/esm/ic-top-navigation-ba78648a.js.map +1 -0
- package/dist/esm/ic-top-navigation.entry.js +3 -230
- package/dist/esm/ic-top-navigation.entry.js.map +1 -1
- package/dist/esm/ic-tree-item.entry.js +5 -4
- package/dist/esm/ic-tree-item.entry.js.map +1 -1
- package/dist/esm/ic-tree-view.entry.js +7 -5
- package/dist/esm/ic-tree-view.entry.js.map +1 -1
- package/dist/esm/ic-typography-9e3efc99.js +196 -0
- package/dist/esm/ic-typography-9e3efc99.js.map +1 -0
- package/dist/esm/ic-typography.entry.js +3 -194
- package/dist/esm/ic-typography.entry.js.map +1 -1
- package/dist/esm/index-a7a720e7.js +6 -170
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/ic-calendar/ic-calendar.d.ts +2 -0
- package/dist/types/components/ic-calendar/ic-day-button.d.ts +1 -0
- package/dist/types/components/ic-calendar/ic-month-picker.d.ts +1 -0
- package/dist/types/components/ic-calendar/ic-year-picker.d.ts +1 -0
- package/dist/types/components/ic-card-horizontal/ic-card-horizontal.d.ts +4 -0
- package/dist/types/components/ic-data-table/ic-data-table.d.ts +7 -0
- package/dist/types/components/ic-data-table-title-bar/ic-data-table-title-bar.d.ts +4 -0
- package/dist/types/components/ic-date-input/ic-date-input.d.ts +7 -0
- package/dist/types/components/ic-pagination-bar/ic-pagination-bar.d.ts +8 -1
- package/dist/types/components/ic-table-of-contents/ic-table-of-contents-item.d.ts +1 -0
- package/dist/types/components/ic-table-of-contents/ic-table-of-contents.d.ts +9 -0
- package/dist/types/components/ic-time-input/ic-time-input.d.ts +10 -1
- package/dist/types/components/ic-time-selector/ic-time-selector.d.ts +4 -10
- package/dist/types/components/ic-time-selector/ic-time-selector.stories.d.ts +48 -13
- package/dist/types/components/ic-tree-item/ic-tree-item.d.ts +1 -0
- package/dist/types/components/ic-tree-view/ic-tree-view.d.ts +2 -0
- package/dist/types/components/ic-tree-view/ic-tree-view.stories.d.ts +27 -21
- package/dist/types/components.d.ts +3918 -786
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-badge/ic-badge.d.ts +74 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-badge/ic-badge.types.d.ts +4 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-button/ic-button.d.ts +210 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-button/ic-button.types.d.ts +2 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-checkbox/ic-checkbox.d.ts +90 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-chip/ic-chip.d.ts +75 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-empty-state/ic-empty-state.d.ts +44 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-empty-state/ic-empty-state.types.d.ts +1 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-input-component-container/ic-input-component-container.d.ts +40 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-input-container/ic-input-container.d.ts +11 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-input-label/ic-input-label.d.ts +42 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-input-validation/ic-input-validation.d.ts +32 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-link/ic-link.d.ts +55 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-loading-indicator/ic-loading-indicator.d.ts +83 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-loading-indicator/ic-loading-indicator.types.d.ts +9 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-menu/ic-menu.d.ts +235 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-menu/ic-menu.types.d.ts +12 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-navigation-item/ic-navigation-item.d.ts +102 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-page-header/ic-page-header.d.ts +61 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-pagination/ic-pagination.d.ts +102 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-pagination/ic-pagination.types.d.ts +6 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-search-bar/ic-search-bar.types.d.ts +5 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-section-container/ic-section-container.d.ts +12 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-select/ic-select.d.ts +282 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-side-navigation/ic-side-navigation.types.d.ts +13 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-skip-link/ic-skip-link.d.ts +38 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-status-tag/ic-status-tag.d.ts +35 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-status-tag/ic-status-tag.types.d.ts +1 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-text-field/ic-text-field.d.ts +262 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-text-field/ic-text-field.types.d.ts +8 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-theme/ic-theme.d.ts +28 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-toggle-button/ic-toggle-button.d.ts +75 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-toggle-button-group/ic-toggle-button-group.d.ts +92 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-toggle-button-group/ic-toggle-button-group.types.d.ts +7 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-tooltip/ic-tooltip.d.ts +82 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-tooltip/ic-tooltip.types.d.ts +1 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-top-navigation/ic-top-navigation.d.ts +102 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/components/ic-typography/ic-typography.d.ts +83 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/utils/helpers.d.ts +167 -0
- package/dist/types/home/runner/work/ic-ui-kit/ic-ui-kit/packages/canary-web-components/.stencil/web-components/src/utils/types.d.ts +98 -0
- package/dist/types/utils/types.d.ts +1 -2
- package/hydrate/index.js +12979 -20485
- package/hydrate/index.mjs +12979 -20485
- package/package.json +14 -20
- package/dist/cjs/OpenInNew-7bac24f7.js.map +0 -1
- package/dist/cjs/check-icon-dd563898.js +0 -10
- package/dist/cjs/check-icon-dd563898.js.map +0 -1
- package/dist/cjs/chevron-icon-3dedd973.js +0 -10
- package/dist/cjs/chevron-icon-3dedd973.js.map +0 -1
- package/dist/cjs/close-icon-d62b369d.js +0 -12
- package/dist/cjs/close-icon-d62b369d.js.map +0 -1
- package/dist/cjs/common-helpers-944cb54d.js +0 -21
- package/dist/cjs/common-helpers-944cb54d.js.map +0 -1
- package/dist/cjs/helpers-2cc5f6db.js.map +0 -1
- package/dist/cjs/ic-accordion-group.cjs.entry.js +0 -137
- package/dist/cjs/ic-accordion-group.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-accordion.cjs.entry.js +0 -150
- package/dist/cjs/ic-accordion.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-action-chip.cjs.entry.js +0 -116
- package/dist/cjs/ic-action-chip.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-alert.cjs.entry.js +0 -136
- package/dist/cjs/ic-alert.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-back-to-top.cjs.entry.js +0 -168
- package/dist/cjs/ic-back-to-top.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-breadcrumb-group.cjs.entry.js +0 -241
- package/dist/cjs/ic-breadcrumb-group.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-breadcrumb.cjs.entry.js +0 -118
- package/dist/cjs/ic-breadcrumb.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-card-vertical.cjs.entry.js +0 -171
- package/dist/cjs/ic-card-vertical.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-checkbox-group.cjs.entry.js +0 -127
- package/dist/cjs/ic-checkbox-group.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-classification-banner.cjs.entry.js +0 -67
- package/dist/cjs/ic-classification-banner.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-data-list.cjs.entry.js +0 -38
- package/dist/cjs/ic-data-list.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-data-row.cjs.entry.js +0 -88
- package/dist/cjs/ic-data-row.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-dialog.cjs.entry.js +0 -388
- package/dist/cjs/ic-dialog.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-divider.cjs.entry.js +0 -114
- package/dist/cjs/ic-divider.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-footer-link-group.cjs.entry.js +0 -69
- package/dist/cjs/ic-footer-link-group.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-footer-link.cjs.entry.js +0 -65
- package/dist/cjs/ic-footer-link.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-footer.cjs.entry.js +0 -119
- package/dist/cjs/ic-footer.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-hero.cjs.entry.js +0 -104
- package/dist/cjs/ic-hero.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-horizontal-scroll.cjs.entry.js +0 -196
- package/dist/cjs/ic-horizontal-scroll.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-layout-grid-item.cjs.entry.js +0 -70
- package/dist/cjs/ic-layout-grid-item.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-layout-grid.cjs.entry.js +0 -156
- package/dist/cjs/ic-layout-grid.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-menu-group.cjs.entry.js +0 -25
- package/dist/cjs/ic-menu-group.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-menu-item.cjs.entry.js +0 -121
- package/dist/cjs/ic-menu-item.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-navigation-button.cjs.entry.js +0 -124
- package/dist/cjs/ic-navigation-button.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-navigation-group.cjs.entry.js +0 -293
- package/dist/cjs/ic-navigation-group.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-navigation-menu.cjs.entry.js +0 -149
- package/dist/cjs/ic-navigation-menu.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-pagination_4.cjs.entry.js +0 -1647
- package/dist/cjs/ic-pagination_4.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-popover-menu.cjs.entry.js +0 -308
- package/dist/cjs/ic-popover-menu.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-radio-group.cjs.entry.js +0 -264
- package/dist/cjs/ic-radio-group.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-radio-option.cjs.entry.js +0 -173
- package/dist/cjs/ic-radio-option.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-search-bar.cjs.entry.js +0 -606
- package/dist/cjs/ic-search-bar.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-side-navigation.cjs.entry.js +0 -488
- package/dist/cjs/ic-side-navigation.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-skeleton.cjs.entry.js +0 -47
- package/dist/cjs/ic-skeleton.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-step.cjs.entry.js +0 -155
- package/dist/cjs/ic-step.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-stepper.cjs.entry.js +0 -288
- package/dist/cjs/ic-stepper.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-switch.cjs.entry.js +0 -124
- package/dist/cjs/ic-switch.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-tab-context.cjs.entry.js +0 -250
- package/dist/cjs/ic-tab-context.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-tab-group.cjs.entry.js +0 -40
- package/dist/cjs/ic-tab-group.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-tab-panel.cjs.entry.js +0 -42
- package/dist/cjs/ic-tab-panel.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-tab.cjs.entry.js +0 -112
- package/dist/cjs/ic-tab.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-toast-region.cjs.entry.js +0 -59
- package/dist/cjs/ic-toast-region.cjs.entry.js.map +0 -1
- package/dist/cjs/ic-toast.cjs.entry.js +0 -239
- package/dist/cjs/ic-toast.cjs.entry.js.map +0 -1
- package/dist/cjs/purify-039f565a.js.map +0 -1
- package/dist/components/check-icon.js +0 -8
- package/dist/components/check-icon.js.map +0 -1
- package/dist/components/chevron-icon.js +0 -8
- package/dist/components/chevron-icon.js.map +0 -1
- package/dist/components/close-icon.js +0 -10
- package/dist/components/close-icon.js.map +0 -1
- package/dist/components/ic-accordion-group.js +0 -188
- package/dist/components/ic-accordion-group.js.map +0 -1
- package/dist/components/ic-accordion.js +0 -181
- package/dist/components/ic-accordion.js.map +0 -1
- package/dist/components/ic-action-chip.js +0 -160
- package/dist/components/ic-action-chip.js.map +0 -1
- package/dist/components/ic-alert.js +0 -187
- package/dist/components/ic-alert.js.map +0 -1
- package/dist/components/ic-back-to-top.js +0 -216
- package/dist/components/ic-back-to-top.js.map +0 -1
- package/dist/components/ic-breadcrumb-group.js +0 -278
- package/dist/components/ic-breadcrumb-group.js.map +0 -1
- package/dist/components/ic-breadcrumb.js +0 -8
- package/dist/components/ic-breadcrumb.js.map +0 -1
- package/dist/components/ic-breadcrumb2.js +0 -145
- package/dist/components/ic-breadcrumb2.js.map +0 -1
- package/dist/components/ic-card-vertical.js +0 -219
- package/dist/components/ic-card-vertical.js.map +0 -1
- package/dist/components/ic-checkbox-group.js +0 -176
- package/dist/components/ic-checkbox-group.js.map +0 -1
- package/dist/components/ic-classification-banner.js +0 -93
- package/dist/components/ic-classification-banner.js.map +0 -1
- package/dist/components/ic-data-list.js +0 -62
- package/dist/components/ic-data-list.js.map +0 -1
- package/dist/components/ic-data-row.js +0 -115
- package/dist/components/ic-data-row.js.map +0 -1
- package/dist/components/ic-dialog.js +0 -445
- package/dist/components/ic-dialog.js.map +0 -1
- package/dist/components/ic-divider.js +0 -8
- package/dist/components/ic-divider.js.map +0 -1
- package/dist/components/ic-divider2.js +0 -139
- package/dist/components/ic-divider2.js.map +0 -1
- package/dist/components/ic-footer-link-group.js +0 -101
- package/dist/components/ic-footer-link-group.js.map +0 -1
- package/dist/components/ic-footer-link.js +0 -95
- package/dist/components/ic-footer-link.js.map +0 -1
- package/dist/components/ic-footer.js +0 -155
- package/dist/components/ic-footer.js.map +0 -1
- package/dist/components/ic-hero.js +0 -145
- package/dist/components/ic-hero.js.map +0 -1
- package/dist/components/ic-horizontal-scroll.js +0 -8
- package/dist/components/ic-horizontal-scroll.js.map +0 -1
- package/dist/components/ic-horizontal-scroll2.js +0 -240
- package/dist/components/ic-horizontal-scroll2.js.map +0 -1
- package/dist/components/ic-layout-grid-item.js +0 -95
- package/dist/components/ic-layout-grid-item.js.map +0 -1
- package/dist/components/ic-layout-grid.js +0 -188
- package/dist/components/ic-layout-grid.js.map +0 -1
- package/dist/components/ic-menu-group.js +0 -47
- package/dist/components/ic-menu-group.js.map +0 -1
- package/dist/components/ic-menu-item.js +0 -8
- package/dist/components/ic-menu-item.js.map +0 -1
- package/dist/components/ic-menu-item2.js +0 -171
- package/dist/components/ic-menu-item2.js.map +0 -1
- package/dist/components/ic-navigation-button.js +0 -174
- package/dist/components/ic-navigation-button.js.map +0 -1
- package/dist/components/ic-navigation-group.js +0 -326
- package/dist/components/ic-navigation-group.js.map +0 -1
- package/dist/components/ic-navigation-menu.js +0 -8
- package/dist/components/ic-navigation-menu.js.map +0 -1
- package/dist/components/ic-navigation-menu2.js +0 -188
- package/dist/components/ic-navigation-menu2.js.map +0 -1
- package/dist/components/ic-pagination-item.js +0 -8
- package/dist/components/ic-pagination-item.js.map +0 -1
- package/dist/components/ic-pagination-item2.js +0 -107
- package/dist/components/ic-pagination-item2.js.map +0 -1
- package/dist/components/ic-popover-menu.js +0 -369
- package/dist/components/ic-popover-menu.js.map +0 -1
- package/dist/components/ic-radio-group.js +0 -317
- package/dist/components/ic-radio-group.js.map +0 -1
- package/dist/components/ic-radio-option.js +0 -209
- package/dist/components/ic-radio-option.js.map +0 -1
- package/dist/components/ic-search-bar.js +0 -719
- package/dist/components/ic-search-bar.js.map +0 -1
- package/dist/components/ic-side-navigation.js +0 -553
- package/dist/components/ic-side-navigation.js.map +0 -1
- package/dist/components/ic-skeleton.js +0 -64
- package/dist/components/ic-skeleton.js.map +0 -1
- package/dist/components/ic-step.js +0 -198
- package/dist/components/ic-step.js.map +0 -1
- package/dist/components/ic-stepper.js +0 -320
- package/dist/components/ic-stepper.js.map +0 -1
- package/dist/components/ic-switch.js +0 -166
- package/dist/components/ic-switch.js.map +0 -1
- package/dist/components/ic-tab-context.js +0 -276
- package/dist/components/ic-tab-context.js.map +0 -1
- package/dist/components/ic-tab-group.js +0 -89
- package/dist/components/ic-tab-group.js.map +0 -1
- package/dist/components/ic-tab-panel.js +0 -63
- package/dist/components/ic-tab-panel.js.map +0 -1
- package/dist/components/ic-tab.js +0 -143
- package/dist/components/ic-tab.js.map +0 -1
- package/dist/components/ic-toast-region.js +0 -76
- package/dist/components/ic-toast-region.js.map +0 -1
- package/dist/components/ic-toast.js +0 -293
- package/dist/components/ic-toast.js.map +0 -1
- package/dist/components/purify.js +0 -1363
- package/dist/components/purify.js.map +0 -1
- package/dist/core/p-04cb17d7.entry.js +0 -2
- package/dist/core/p-04cb17d7.entry.js.map +0 -1
- package/dist/core/p-08f24329.entry.js +0 -2
- package/dist/core/p-08f24329.entry.js.map +0 -1
- package/dist/core/p-0aa9ce8b.js +0 -2
- package/dist/core/p-14b8bf37.entry.js +0 -2
- package/dist/core/p-14b8bf37.entry.js.map +0 -1
- package/dist/core/p-169ad948.entry.js +0 -2
- package/dist/core/p-169ad948.entry.js.map +0 -1
- package/dist/core/p-170ddfc2.js +0 -2
- package/dist/core/p-1cc402b8.entry.js +0 -2
- package/dist/core/p-1cc402b8.entry.js.map +0 -1
- package/dist/core/p-1d166343.entry.js +0 -2
- package/dist/core/p-1d166343.entry.js.map +0 -1
- package/dist/core/p-319e3d5b.entry.js.map +0 -1
- package/dist/core/p-33509a89.entry.js.map +0 -1
- package/dist/core/p-3389625c.entry.js +0 -2
- package/dist/core/p-3389625c.entry.js.map +0 -1
- package/dist/core/p-344752cb.entry.js +0 -2
- package/dist/core/p-344752cb.entry.js.map +0 -1
- package/dist/core/p-348d7080.entry.js +0 -2
- package/dist/core/p-348d7080.entry.js.map +0 -1
- package/dist/core/p-349d91dc.js.map +0 -1
- package/dist/core/p-39cdf5db.entry.js +0 -2
- package/dist/core/p-39cdf5db.entry.js.map +0 -1
- package/dist/core/p-496b314f.entry.js +0 -2
- package/dist/core/p-496b314f.entry.js.map +0 -1
- package/dist/core/p-508b6da3.entry.js +0 -2
- package/dist/core/p-508b6da3.entry.js.map +0 -1
- package/dist/core/p-5254a078.entry.js +0 -2
- package/dist/core/p-5254a078.entry.js.map +0 -1
- package/dist/core/p-53740194.entry.js +0 -2
- package/dist/core/p-53740194.entry.js.map +0 -1
- package/dist/core/p-551a0fc1.entry.js.map +0 -1
- package/dist/core/p-5e6687a8.entry.js +0 -2
- package/dist/core/p-5e6687a8.entry.js.map +0 -1
- package/dist/core/p-60f4fe3a.entry.js +0 -2
- package/dist/core/p-60f4fe3a.entry.js.map +0 -1
- package/dist/core/p-61c92598.entry.js +0 -2
- package/dist/core/p-61c92598.entry.js.map +0 -1
- package/dist/core/p-6323da7a.entry.js +0 -2
- package/dist/core/p-6323da7a.entry.js.map +0 -1
- package/dist/core/p-67c3985d.entry.js +0 -2
- package/dist/core/p-67c3985d.entry.js.map +0 -1
- package/dist/core/p-691dd972.entry.js +0 -2
- package/dist/core/p-691dd972.entry.js.map +0 -1
- package/dist/core/p-6dfe0922.entry.js +0 -2
- package/dist/core/p-6dfe0922.entry.js.map +0 -1
- package/dist/core/p-71cc5909.entry.js +0 -2
- package/dist/core/p-71cc5909.entry.js.map +0 -1
- package/dist/core/p-770e92cd.entry.js +0 -2
- package/dist/core/p-770e92cd.entry.js.map +0 -1
- package/dist/core/p-79ead0e7.entry.js.map +0 -1
- package/dist/core/p-7b4b45cf.entry.js +0 -2
- package/dist/core/p-7b4b45cf.entry.js.map +0 -1
- package/dist/core/p-7efdbab8.entry.js.map +0 -1
- package/dist/core/p-802a4bd3.entry.js +0 -2
- package/dist/core/p-802a4bd3.entry.js.map +0 -1
- package/dist/core/p-879c180d.entry.js.map +0 -1
- package/dist/core/p-8830011c.entry.js +0 -2
- package/dist/core/p-8830011c.entry.js.map +0 -1
- package/dist/core/p-8ab37b4d.entry.js +0 -2
- package/dist/core/p-8ab37b4d.entry.js.map +0 -1
- package/dist/core/p-939025af.entry.js.map +0 -1
- package/dist/core/p-939b168a.entry.js +0 -2
- package/dist/core/p-939b168a.entry.js.map +0 -1
- package/dist/core/p-9674b63f.entry.js +0 -2
- package/dist/core/p-9674b63f.entry.js.map +0 -1
- package/dist/core/p-9ca147f3.entry.js.map +0 -1
- package/dist/core/p-9dea5764.entry.js +0 -2
- package/dist/core/p-9dea5764.entry.js.map +0 -1
- package/dist/core/p-a422b778.js +0 -2
- package/dist/core/p-a422b778.js.map +0 -1
- package/dist/core/p-a88e61b2.entry.js +0 -2
- package/dist/core/p-a88e61b2.entry.js.map +0 -1
- package/dist/core/p-a8a92e54.entry.js +0 -2
- package/dist/core/p-a8a92e54.entry.js.map +0 -1
- package/dist/core/p-a94a7b71.entry.js +0 -2
- package/dist/core/p-a94a7b71.entry.js.map +0 -1
- package/dist/core/p-ad551a0c.entry.js +0 -2
- package/dist/core/p-ad551a0c.entry.js.map +0 -1
- package/dist/core/p-adde6c66.entry.js +0 -2
- package/dist/core/p-adde6c66.entry.js.map +0 -1
- package/dist/core/p-b434bd7c.entry.js +0 -2
- package/dist/core/p-b434bd7c.entry.js.map +0 -1
- package/dist/core/p-b4a2f6fa.entry.js +0 -2
- package/dist/core/p-b4a2f6fa.entry.js.map +0 -1
- package/dist/core/p-c0a7eed7.entry.js +0 -2
- package/dist/core/p-c0a7eed7.entry.js.map +0 -1
- package/dist/core/p-c0b227d2.entry.js +0 -2
- package/dist/core/p-c0b227d2.entry.js.map +0 -1
- package/dist/core/p-c32f043e.entry.js +0 -2
- package/dist/core/p-c32f043e.entry.js.map +0 -1
- package/dist/core/p-c4b2774d.entry.js.map +0 -1
- package/dist/core/p-c9525aac.entry.js +0 -2
- package/dist/core/p-c9525aac.entry.js.map +0 -1
- package/dist/core/p-ca05573a.entry.js +0 -2
- package/dist/core/p-ca05573a.entry.js.map +0 -1
- package/dist/core/p-d0607a70.entry.js +0 -2
- package/dist/core/p-d0607a70.entry.js.map +0 -1
- package/dist/core/p-d528d856.entry.js +0 -2
- package/dist/core/p-d528d856.entry.js.map +0 -1
- package/dist/core/p-da1c2883.entry.js +0 -2
- package/dist/core/p-da1c2883.entry.js.map +0 -1
- package/dist/core/p-e081702e.js +0 -2
- package/dist/core/p-e2e556ec.entry.js +0 -2
- package/dist/core/p-e2e556ec.entry.js.map +0 -1
- package/dist/core/p-e519f607.js +0 -2
- package/dist/core/p-e519f607.js.map +0 -1
- package/dist/core/p-e5c6d01a.entry.js +0 -2
- package/dist/core/p-e5c6d01a.entry.js.map +0 -1
- package/dist/core/p-e8db8772.entry.js +0 -2
- package/dist/core/p-e8db8772.entry.js.map +0 -1
- package/dist/core/p-ea04103e.entry.js +0 -2
- package/dist/core/p-ea04103e.entry.js.map +0 -1
- package/dist/core/p-eaeb473e.entry.js +0 -2
- package/dist/core/p-eaeb473e.entry.js.map +0 -1
- package/dist/core/p-ecc7fd71.entry.js +0 -2
- package/dist/core/p-ecc7fd71.entry.js.map +0 -1
- package/dist/core/p-efe260f0.entry.js +0 -2
- package/dist/core/p-efe260f0.entry.js.map +0 -1
- package/dist/core/p-f1b57f91.entry.js +0 -2
- package/dist/core/p-f1b57f91.entry.js.map +0 -1
- package/dist/core/p-f5dc04f7.entry.js +0 -2
- package/dist/core/p-f5dc04f7.entry.js.map +0 -1
- package/dist/core/p-fb07921b.entry.js +0 -2
- package/dist/core/p-fb07921b.entry.js.map +0 -1
- package/dist/core/p-fd08156a.entry.js +0 -2
- package/dist/core/p-fd08156a.entry.js.map +0 -1
- package/dist/core/p-fe5b51bb.entry.js +0 -2
- package/dist/core/p-fe5b51bb.entry.js.map +0 -1
- package/dist/core/p-ff618439.entry.js +0 -2
- package/dist/core/p-ff618439.entry.js.map +0 -1
- package/dist/esm/OpenInNew-52210a9d.js.map +0 -1
- package/dist/esm/check-icon-f2346e76.js +0 -8
- package/dist/esm/check-icon-f2346e76.js.map +0 -1
- package/dist/esm/chevron-icon-875b7af2.js +0 -8
- package/dist/esm/chevron-icon-875b7af2.js.map +0 -1
- package/dist/esm/close-icon-c9e09475.js +0 -10
- package/dist/esm/close-icon-c9e09475.js.map +0 -1
- package/dist/esm/common-helpers-86c07ff1.js +0 -19
- package/dist/esm/common-helpers-86c07ff1.js.map +0 -1
- package/dist/esm/helpers-063369f4.js.map +0 -1
- package/dist/esm/ic-accordion-group.entry.js +0 -133
- package/dist/esm/ic-accordion-group.entry.js.map +0 -1
- package/dist/esm/ic-accordion.entry.js +0 -146
- package/dist/esm/ic-accordion.entry.js.map +0 -1
- package/dist/esm/ic-action-chip.entry.js +0 -112
- package/dist/esm/ic-action-chip.entry.js.map +0 -1
- package/dist/esm/ic-alert.entry.js +0 -132
- package/dist/esm/ic-alert.entry.js.map +0 -1
- package/dist/esm/ic-back-to-top.entry.js +0 -164
- package/dist/esm/ic-back-to-top.entry.js.map +0 -1
- package/dist/esm/ic-breadcrumb-group.entry.js +0 -237
- package/dist/esm/ic-breadcrumb-group.entry.js.map +0 -1
- package/dist/esm/ic-breadcrumb.entry.js +0 -114
- package/dist/esm/ic-breadcrumb.entry.js.map +0 -1
- package/dist/esm/ic-card-vertical.entry.js +0 -167
- package/dist/esm/ic-card-vertical.entry.js.map +0 -1
- package/dist/esm/ic-checkbox-group.entry.js +0 -123
- package/dist/esm/ic-checkbox-group.entry.js.map +0 -1
- package/dist/esm/ic-classification-banner.entry.js +0 -63
- package/dist/esm/ic-classification-banner.entry.js.map +0 -1
- package/dist/esm/ic-data-list.entry.js +0 -34
- package/dist/esm/ic-data-list.entry.js.map +0 -1
- package/dist/esm/ic-data-row.entry.js +0 -84
- package/dist/esm/ic-data-row.entry.js.map +0 -1
- package/dist/esm/ic-dialog.entry.js +0 -384
- package/dist/esm/ic-dialog.entry.js.map +0 -1
- package/dist/esm/ic-divider.entry.js +0 -110
- package/dist/esm/ic-divider.entry.js.map +0 -1
- package/dist/esm/ic-footer-link-group.entry.js +0 -65
- package/dist/esm/ic-footer-link-group.entry.js.map +0 -1
- package/dist/esm/ic-footer-link.entry.js +0 -61
- package/dist/esm/ic-footer-link.entry.js.map +0 -1
- package/dist/esm/ic-footer.entry.js +0 -115
- package/dist/esm/ic-footer.entry.js.map +0 -1
- package/dist/esm/ic-hero.entry.js +0 -100
- package/dist/esm/ic-hero.entry.js.map +0 -1
- package/dist/esm/ic-horizontal-scroll.entry.js +0 -192
- package/dist/esm/ic-horizontal-scroll.entry.js.map +0 -1
- package/dist/esm/ic-layout-grid-item.entry.js +0 -66
- package/dist/esm/ic-layout-grid-item.entry.js.map +0 -1
- package/dist/esm/ic-layout-grid.entry.js +0 -152
- package/dist/esm/ic-layout-grid.entry.js.map +0 -1
- package/dist/esm/ic-menu-group.entry.js +0 -21
- package/dist/esm/ic-menu-group.entry.js.map +0 -1
- package/dist/esm/ic-menu-item.entry.js +0 -117
- package/dist/esm/ic-menu-item.entry.js.map +0 -1
- package/dist/esm/ic-navigation-button.entry.js +0 -120
- package/dist/esm/ic-navigation-button.entry.js.map +0 -1
- package/dist/esm/ic-navigation-group.entry.js +0 -289
- package/dist/esm/ic-navigation-group.entry.js.map +0 -1
- package/dist/esm/ic-navigation-menu.entry.js +0 -145
- package/dist/esm/ic-navigation-menu.entry.js.map +0 -1
- package/dist/esm/ic-pagination_4.entry.js +0 -1640
- package/dist/esm/ic-pagination_4.entry.js.map +0 -1
- package/dist/esm/ic-popover-menu.entry.js +0 -304
- package/dist/esm/ic-popover-menu.entry.js.map +0 -1
- package/dist/esm/ic-radio-group.entry.js +0 -260
- package/dist/esm/ic-radio-group.entry.js.map +0 -1
- package/dist/esm/ic-radio-option.entry.js +0 -169
- package/dist/esm/ic-radio-option.entry.js.map +0 -1
- package/dist/esm/ic-search-bar.entry.js +0 -602
- package/dist/esm/ic-search-bar.entry.js.map +0 -1
- package/dist/esm/ic-side-navigation.entry.js +0 -484
- package/dist/esm/ic-side-navigation.entry.js.map +0 -1
- package/dist/esm/ic-skeleton.entry.js +0 -43
- package/dist/esm/ic-skeleton.entry.js.map +0 -1
- package/dist/esm/ic-step.entry.js +0 -151
- package/dist/esm/ic-step.entry.js.map +0 -1
- package/dist/esm/ic-stepper.entry.js +0 -284
- package/dist/esm/ic-stepper.entry.js.map +0 -1
- package/dist/esm/ic-switch.entry.js +0 -120
- package/dist/esm/ic-switch.entry.js.map +0 -1
- package/dist/esm/ic-tab-context.entry.js +0 -246
- package/dist/esm/ic-tab-context.entry.js.map +0 -1
- package/dist/esm/ic-tab-group.entry.js +0 -36
- package/dist/esm/ic-tab-group.entry.js.map +0 -1
- package/dist/esm/ic-tab-panel.entry.js +0 -38
- package/dist/esm/ic-tab-panel.entry.js.map +0 -1
- package/dist/esm/ic-tab.entry.js +0 -108
- package/dist/esm/ic-tab.entry.js.map +0 -1
- package/dist/esm/ic-toast-region.entry.js +0 -55
- package/dist/esm/ic-toast-region.entry.js.map +0 -1
- package/dist/esm/ic-toast.entry.js +0 -235
- package/dist/esm/ic-toast.entry.js.map +0 -1
- package/dist/esm/purify-6eaa9893.js.map +0 -1
- /package/dist/core/{p-0aa9ce8b.js.map → p-02d0a238.entry.js.map} +0 -0
- /package/dist/core/{p-170ddfc2.js.map → p-0c02b16c.entry.js.map} +0 -0
- /package/dist/core/{p-201b41c7.entry.js.map → p-22267c01.entry.js.map} +0 -0
- /package/dist/core/{p-e081702e.js.map → p-27962d4d.entry.js.map} +0 -0
- /package/dist/core/{p-ea1ea1b9.js.map → p-384a7f60.entry.js.map} +0 -0
|
@@ -1,1640 +0,0 @@
|
|
|
1
|
-
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement, f as forceUpdate } from './index-a7a720e7.js';
|
|
2
|
-
import { r as removeDisabledFalse, o as onComponentRequiredPropUndefined, O as capitalize, P as checkSlotInChildMutations, B as getLabelFromValue, A as getFilteredMenuOptions, Q as isMacDevice, R as getOptionsWithoutGroupTitlesCount, y as removeFormResetListener, t as inheritAttributes, z as addFormResetListener, F as renderHiddenInput, k as getInputDescribedByText, i as isSlotUsed, S as isMobileOrTablet, v as IC_INHERITED_ARIA, T as IcInformationStatus, l as hasValidationStatus, G as isEmptyString, E as debounceEvent, U as IGNORED_KEYBOARD_CHARACTERS, L as removeHiddenInput } from './helpers-063369f4.js';
|
|
3
|
-
|
|
4
|
-
const paginationNextPrevious = `<svg width="8" height="10" viewBox="0 0 8 10" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
5
|
-
<path d="M2.08748 0L0.912476 1.175L4.72914 5L0.912476 8.825L2.08748 10L7.08748 5L2.08748 0Z" fill="currentColor"/>
|
|
6
|
-
</svg>
|
|
7
|
-
`;
|
|
8
|
-
|
|
9
|
-
const paginationFirstLast = `<svg width="12" height="10" viewBox="0 0 12 10" fill="none" xmlns="http://www.w3.org/2000/svg">
|
|
10
|
-
<path d="M11.1709 8.825L7.34589 5L11.1709 1.175L9.99589 0L4.99589 5L9.99589 10L11.1709 8.825ZM0.829224 0H2.49589V10H0.829224V0Z" fill="currentColour"/>
|
|
11
|
-
</svg>`;
|
|
12
|
-
|
|
13
|
-
const icPaginationCss = "/*! 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{box-sizing:border-box;width:100%;display:flex;justify-content:center}nav{width:100%;display:flex;flex-flow:row wrap;justify-content:flex-start;align-items:center}ic-button{cursor:pointer}ic-button.next-previous{--icon-width:var(--ic-space-xs);--icon-height:calc(var(--ic-space-xs) + var(--ic-space-xxxs));padding:0 var(--ic-space-xxs) 0 var(--ic-space-xxxs)}ic-button.first-last{--icon-width:calc(var(--ic-space-sm) + var(--ic-space-xxxs));--icon-height:calc(var(--ic-space-xs) + var(--ic-space-xxxs))}ic-button.first-last::part(button),ic-button.next-previous::part(button){color:var(--ic-pagination-chevron)}:host(.ic-pagination-monochrome) ic-button.first-last::part(button),:host(.ic-pagination-monochrome) ic-button.next-previous::part(button){color:var(--ic-pagination-chevron-monochrome)}ic-button.ic-button-disabled.first-last::part(button),ic-button.ic-button-disabled.next-previous::part(button),:host(.ic-pagination-monochrome) ic-button.ic-button-disabled.first-last::part(button),:host(.ic-pagination-monochrome) ic-button.ic-button-disabled.next-previous::part(button){color:var(--ic-pagination-chevron-disabled)}.disabled{color:var(--ic-color-text-disabled-mid);pointer-events:none;cursor:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}.hide-current-page{display:none}.sr-only{position:absolute;left:-9999px}.sr-only:dir(rtl){right:-9999px}";
|
|
14
|
-
const IcPaginationStyle0 = icPaginationCss;
|
|
15
|
-
|
|
16
|
-
const Pagination = class {
|
|
17
|
-
constructor(hostRef) {
|
|
18
|
-
registerInstance(this, hostRef);
|
|
19
|
-
this.icPageChange = createEvent(this, "icPageChange", 7);
|
|
20
|
-
this.endEllipsis = false;
|
|
21
|
-
this.endItems = [];
|
|
22
|
-
this.midItems = [];
|
|
23
|
-
this.startEllipsis = false;
|
|
24
|
-
this.startItems = [];
|
|
25
|
-
/**
|
|
26
|
-
* The accessible label of the pagination component to provide context for screen reader users.
|
|
27
|
-
*/
|
|
28
|
-
this.accessibleLabel = "Pagination Navigation";
|
|
29
|
-
/**
|
|
30
|
-
* The number of pages displayed adjacent to the current page when using 'complex' type pagination. Accepted values are 0, 1 & 2.
|
|
31
|
-
*/
|
|
32
|
-
this.adjacentPageCount = 1;
|
|
33
|
-
/**
|
|
34
|
-
* The number of pages displayed as boundary items to the current page when using 'complex' type pagination. Accepted values are 0, 1 & 2.
|
|
35
|
-
*/
|
|
36
|
-
this.boundaryPageCount = 1;
|
|
37
|
-
/**
|
|
38
|
-
* The default page to display.
|
|
39
|
-
*/
|
|
40
|
-
this.defaultPage = 1;
|
|
41
|
-
/**
|
|
42
|
-
* If `true`, the pagination will not allow interaction.
|
|
43
|
-
*/
|
|
44
|
-
this.disabled = false;
|
|
45
|
-
/**
|
|
46
|
-
* If `true`, the current page of the simple pagination will not be displayed.
|
|
47
|
-
*/
|
|
48
|
-
this.hideCurrentPage = false;
|
|
49
|
-
/**
|
|
50
|
-
* If `true`, the first and last page buttons will not be displayed.
|
|
51
|
-
*/
|
|
52
|
-
this.hideFirstAndLastPageButton = false;
|
|
53
|
-
/**
|
|
54
|
-
* The label for the pagination item (applicable when simple pagination is being used).
|
|
55
|
-
*/
|
|
56
|
-
this.label = "Page";
|
|
57
|
-
/**
|
|
58
|
-
* If `true`, the pagination will display as black in the light theme, and white in dark theme.
|
|
59
|
-
*/
|
|
60
|
-
this.monochrome = false;
|
|
61
|
-
/**
|
|
62
|
-
* 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.
|
|
63
|
-
*/
|
|
64
|
-
this.theme = "inherit";
|
|
65
|
-
/**
|
|
66
|
-
* The type of pagination to be used.
|
|
67
|
-
*/
|
|
68
|
-
this.type = "simple";
|
|
69
|
-
/**
|
|
70
|
-
* The current page displayed by the pagination.
|
|
71
|
-
*/
|
|
72
|
-
this.currentPage = this.defaultPage;
|
|
73
|
-
this.handleClickFirst = () => {
|
|
74
|
-
this.currentPage = 1;
|
|
75
|
-
this.icPageChange.emit({ value: this.currentPage });
|
|
76
|
-
};
|
|
77
|
-
this.handleClickPrevious = () => {
|
|
78
|
-
this.currentPage--;
|
|
79
|
-
this.icPageChange.emit({ value: this.currentPage });
|
|
80
|
-
};
|
|
81
|
-
this.handleClickNext = () => {
|
|
82
|
-
this.currentPage++;
|
|
83
|
-
this.icPageChange.emit({ value: this.currentPage });
|
|
84
|
-
};
|
|
85
|
-
this.handleClickLast = () => {
|
|
86
|
-
this.currentPage = this.pages;
|
|
87
|
-
this.icPageChange.emit({ value: this.currentPage });
|
|
88
|
-
};
|
|
89
|
-
// button rendering abstracted from component render methods for clarity
|
|
90
|
-
this.firstButton = () => {
|
|
91
|
-
return (h("ic-button", { id: "first-page-button", "aria-label": "Go to first page", theme: this.theme, onClick: this.handleClickFirst, class: "page-button first-last", disabled: this.currentPage === 1 || this.disabled, variant: "icon-tertiary", monochrome: this.theme == "light" || this.theme == "dark", innerHTML: paginationFirstLast }));
|
|
92
|
-
};
|
|
93
|
-
this.previousButton = () => {
|
|
94
|
-
return (h("ic-button", { id: "previous-page-button", "aria-label": "Go to previous page", theme: this.theme, onClick: this.handleClickPrevious, class: "page-button next-previous flip", disabled: this.currentPage === 1 || this.disabled, variant: "icon-tertiary", monochrome: this.theme == "light" || this.theme == "dark", innerHTML: paginationNextPrevious }));
|
|
95
|
-
};
|
|
96
|
-
this.nextButton = () => {
|
|
97
|
-
return (h("ic-button", { id: "next-page-button", "aria-label": "Go to next page", theme: this.theme, onClick: this.handleClickNext, class: "page-button next-previous", disabled: this.currentPage === this.pages || this.disabled, variant: "icon-tertiary", monochrome: this.theme == "light" || this.theme == "dark", innerHTML: paginationNextPrevious }));
|
|
98
|
-
};
|
|
99
|
-
this.lastButton = () => {
|
|
100
|
-
return (h("ic-button", { id: "last-page-button", "aria-label": "Go to last page", theme: this.theme, onClick: this.handleClickLast, class: "page-button first-last flip", disabled: this.currentPage === this.pages || this.disabled, variant: "icon-tertiary", monochrome: this.theme == "light" || this.theme == "dark", innerHTML: paginationFirstLast }));
|
|
101
|
-
};
|
|
102
|
-
this.renderStartEllipsis = () => {
|
|
103
|
-
return (h("ic-pagination-item", { theme: this.theme, monochrome: this.monochrome, type: "ellipsis", id: "start-ellipsis", disabled: this.disabled }));
|
|
104
|
-
};
|
|
105
|
-
this.renderEndEllipsis = () => {
|
|
106
|
-
return (h("ic-pagination-item", { theme: this.theme, monochrome: this.monochrome, type: "ellipsis", id: "end-ellipsis", disabled: this.disabled }));
|
|
107
|
-
};
|
|
108
|
-
this.renderStartItems = () => {
|
|
109
|
-
return this.startItems.map((page) => {
|
|
110
|
-
return (h("ic-pagination-item", { theme: this.theme, monochrome: this.monochrome, selected: page === this.currentPage, id: `pagination-item-${page}`, type: "page", page: page, disabled: this.disabled }));
|
|
111
|
-
});
|
|
112
|
-
};
|
|
113
|
-
this.renderEndItems = () => {
|
|
114
|
-
return this.endItems.map((page) => {
|
|
115
|
-
return (h("ic-pagination-item", { theme: this.theme, monochrome: this.monochrome, selected: page === this.currentPage, id: `pagination-item-${page}`, type: "page", page: page, disabled: this.disabled }));
|
|
116
|
-
});
|
|
117
|
-
};
|
|
118
|
-
this.renderMiddleItems = () => {
|
|
119
|
-
return this.midItems.map((page) => {
|
|
120
|
-
return (h("ic-pagination-item", { theme: this.theme, monochrome: this.monochrome, selected: page === this.currentPage, id: `pagination-item-${page}`, type: "page", page: page, disabled: this.disabled }));
|
|
121
|
-
});
|
|
122
|
-
};
|
|
123
|
-
}
|
|
124
|
-
watchAdjacentPageCountHandler() {
|
|
125
|
-
if (this.adjacentPageCount > 2) {
|
|
126
|
-
this.adjacentPageCount = 2;
|
|
127
|
-
}
|
|
128
|
-
}
|
|
129
|
-
watchBoundaryPageCountHandler() {
|
|
130
|
-
if (this.boundaryPageCount > 2) {
|
|
131
|
-
this.boundaryPageCount = 2;
|
|
132
|
-
}
|
|
133
|
-
}
|
|
134
|
-
watchDisabledHandler() {
|
|
135
|
-
removeDisabledFalse(this.disabled, this.el);
|
|
136
|
-
}
|
|
137
|
-
watchNumberPagesHandler() {
|
|
138
|
-
this.watchPageChangeHandler();
|
|
139
|
-
}
|
|
140
|
-
watchTypeHandler() {
|
|
141
|
-
this.watchPageChangeHandler();
|
|
142
|
-
}
|
|
143
|
-
watchPageChangeHandler() {
|
|
144
|
-
if (this.type === "simple") {
|
|
145
|
-
return;
|
|
146
|
-
}
|
|
147
|
-
this.startEllipsis = false;
|
|
148
|
-
this.endEllipsis = false;
|
|
149
|
-
this.startItems = [];
|
|
150
|
-
this.endItems = [];
|
|
151
|
-
this.midItems = [];
|
|
152
|
-
const startItems = [];
|
|
153
|
-
let startItemCount = 0;
|
|
154
|
-
const endItems = [];
|
|
155
|
-
let endStart = this.pages;
|
|
156
|
-
const midItems = [];
|
|
157
|
-
let midStart;
|
|
158
|
-
let midEnd;
|
|
159
|
-
let startEllipsis = false;
|
|
160
|
-
let endEllipsis = false;
|
|
161
|
-
if (this.pages <=
|
|
162
|
-
this.boundaryPageCount * 2 + this.adjacentPageCount * 2 + 3) {
|
|
163
|
-
this.startEllipsis = false;
|
|
164
|
-
this.endEllipsis = false;
|
|
165
|
-
for (let i = 1; i <= this.pages; i++) {
|
|
166
|
-
startItems.push(i);
|
|
167
|
-
}
|
|
168
|
-
this.startItems = startItems;
|
|
169
|
-
return;
|
|
170
|
-
}
|
|
171
|
-
startItemCount = this.boundaryPageCount === 0 ? 1 : this.boundaryPageCount;
|
|
172
|
-
endStart =
|
|
173
|
-
this.boundaryPageCount === 0
|
|
174
|
-
? this.pages
|
|
175
|
-
: this.pages - this.boundaryPageCount + 1;
|
|
176
|
-
if (this.currentPage <=
|
|
177
|
-
this.adjacentPageCount + this.boundaryPageCount + 2) {
|
|
178
|
-
startEllipsis = false;
|
|
179
|
-
endEllipsis = true;
|
|
180
|
-
let numItems = 2 * this.adjacentPageCount + 1;
|
|
181
|
-
if (this.boundaryPageCount === 0) {
|
|
182
|
-
numItems--;
|
|
183
|
-
}
|
|
184
|
-
midStart = startItemCount + 1;
|
|
185
|
-
midEnd = midStart + numItems;
|
|
186
|
-
}
|
|
187
|
-
else {
|
|
188
|
-
startEllipsis = true;
|
|
189
|
-
if (this.currentPage >
|
|
190
|
-
this.pages - (this.adjacentPageCount + this.boundaryPageCount + 2)) {
|
|
191
|
-
let numItems = 2 * this.adjacentPageCount + 1;
|
|
192
|
-
if (this.boundaryPageCount === 0) {
|
|
193
|
-
numItems--;
|
|
194
|
-
}
|
|
195
|
-
midEnd =
|
|
196
|
-
this.boundaryPageCount === 0
|
|
197
|
-
? this.pages - 1
|
|
198
|
-
: this.pages - this.boundaryPageCount;
|
|
199
|
-
midStart = midEnd - numItems;
|
|
200
|
-
}
|
|
201
|
-
else {
|
|
202
|
-
endEllipsis = true;
|
|
203
|
-
midStart = this.currentPage - this.adjacentPageCount;
|
|
204
|
-
midEnd = this.currentPage + this.adjacentPageCount;
|
|
205
|
-
}
|
|
206
|
-
}
|
|
207
|
-
//create array of start items
|
|
208
|
-
if (this.boundaryPageCount > 0 ||
|
|
209
|
-
(this.boundaryPageCount === 0 && startEllipsis === false)) {
|
|
210
|
-
for (let i = 1; i <= startItemCount; i++) {
|
|
211
|
-
startItems.push(i);
|
|
212
|
-
}
|
|
213
|
-
}
|
|
214
|
-
//create array of end items
|
|
215
|
-
if (this.boundaryPageCount > 0 ||
|
|
216
|
-
(this.boundaryPageCount === 0 && endEllipsis === false)) {
|
|
217
|
-
for (let i = endStart; i <= this.pages; i++) {
|
|
218
|
-
endItems.push(i);
|
|
219
|
-
}
|
|
220
|
-
}
|
|
221
|
-
//create array of mid items
|
|
222
|
-
for (let i = midStart; i <= midEnd; i++) {
|
|
223
|
-
midItems.push(i);
|
|
224
|
-
}
|
|
225
|
-
this.startEllipsis = startEllipsis;
|
|
226
|
-
this.endEllipsis = endEllipsis;
|
|
227
|
-
this.startItems = startItems;
|
|
228
|
-
this.endItems = endItems;
|
|
229
|
-
this.midItems = midItems;
|
|
230
|
-
}
|
|
231
|
-
componentWillLoad() {
|
|
232
|
-
this.watchPageChangeHandler();
|
|
233
|
-
this.watchBoundaryPageCountHandler();
|
|
234
|
-
this.watchAdjacentPageCountHandler();
|
|
235
|
-
removeDisabledFalse(this.disabled, this.el);
|
|
236
|
-
}
|
|
237
|
-
componentDidLoad() {
|
|
238
|
-
onComponentRequiredPropUndefined([{ prop: this.pages, propName: "pages" }], "Pagination");
|
|
239
|
-
}
|
|
240
|
-
paginationItemClickHandler(ev) {
|
|
241
|
-
const page = ev.detail.page;
|
|
242
|
-
this.currentPage = page;
|
|
243
|
-
this.icPageChange.emit({ value: this.currentPage });
|
|
244
|
-
}
|
|
245
|
-
/**
|
|
246
|
-
* Sets the currently displayed page.
|
|
247
|
-
* @param {number} page The page number to set as the current page
|
|
248
|
-
*/
|
|
249
|
-
async setCurrentPage(page) {
|
|
250
|
-
if (typeof page === "number" && page > 0 && page <= this.pages) {
|
|
251
|
-
this.currentPage = page;
|
|
252
|
-
}
|
|
253
|
-
else {
|
|
254
|
-
console.error("Current page must be a number greater than zero but less than or equal to the total number of pages");
|
|
255
|
-
}
|
|
256
|
-
}
|
|
257
|
-
render() {
|
|
258
|
-
const { type, currentPage, hideCurrentPage, disabled, hideFirstAndLastPageButton, label, theme, monochrome, } = this;
|
|
259
|
-
return (h(Host, { key: '206014fa2aa2c61bb9535e4de4fa5bf756bd318c', class: {
|
|
260
|
-
[`ic-theme-${theme}`]: theme !== "inherit",
|
|
261
|
-
["ic-pagination-monochrome"]: !!monochrome,
|
|
262
|
-
} }, type === "simple" && (h("nav", { key: '8544b88d593c806867e0bd49cb0624a684dec271', class: {
|
|
263
|
-
["disabled"]: !!disabled,
|
|
264
|
-
}, role: "navigation", "aria-label": this.accessibleLabel }, hideFirstAndLastPageButton ? null : this.firstButton(), this.previousButton(), h("ic-pagination-item", { key: '5331aca30709281171cf19f17c2f05a0d0cdf168', theme: this.theme, monochrome: this.monochrome, type: "simple-current", page: currentPage, label: label, class: { ["hide-current-page"]: !!hideCurrentPage }, disabled: disabled }), this.nextButton(), hideFirstAndLastPageButton ? null : this.lastButton())), type === "complex" && (h("nav", { key: '6b7acef9da08b590b941a7ce142ce448dbf79ff2', class: {
|
|
265
|
-
["disabled"]: !!disabled,
|
|
266
|
-
}, role: "navigation", "aria-label": this.accessibleLabel }, hideFirstAndLastPageButton ? null : this.firstButton(), this.previousButton(), this.renderStartItems(), this.startEllipsis && this.renderStartEllipsis(), this.renderMiddleItems(), this.endEllipsis && this.renderEndEllipsis(), this.renderEndItems(), this.nextButton(), hideFirstAndLastPageButton ? null : this.lastButton())), type === "complex" && (h("span", { key: 'e60f3fb36b78e7970f14836295efbd3a1f481885', class: "sr-only", "aria-live": "polite" }, "Page ", this.currentPage))));
|
|
267
|
-
}
|
|
268
|
-
get el() { return getElement(this); }
|
|
269
|
-
static get watchers() { return {
|
|
270
|
-
"adjacentPageCount": ["watchAdjacentPageCountHandler"],
|
|
271
|
-
"boundaryPageCount": ["watchBoundaryPageCountHandler"],
|
|
272
|
-
"disabled": ["watchDisabledHandler"],
|
|
273
|
-
"pages": ["watchNumberPagesHandler"],
|
|
274
|
-
"type": ["watchTypeHandler"],
|
|
275
|
-
"currentPage": ["watchPageChangeHandler"]
|
|
276
|
-
}; }
|
|
277
|
-
};
|
|
278
|
-
Pagination.style = IcPaginationStyle0;
|
|
279
|
-
|
|
280
|
-
const icPaginationItemCss = "/*! 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}a{text-align:center}.item-container{display:flex;justify-content:center;align-items:center;width:calc(var(--ic-space-xl) + var(--ic-space-sm));height:var(--ic-space-xl);margin:var(--ic-space-xxs) var(--ic-space-xxxs);cursor:pointer;text-decoration:none}button{background:none;border:none;outline:inherit;position:relative}.ellipsis{pointer-events:none;--ic-typography-color:var(--ic-pagination-ellipsis)}.monochrome .ellipsis{--ic-typography-color:var(--ic-pagination-ellipsis-monochrome)}.item-container:focus{box-shadow:var(--ic-border-focus);outline:var(--ic-hc-focus-outline);border-radius:var(--ic-border-radius);transition:var(--ic-easing-transition-fast)}.page{--ic-typography-color:var(--ic-pagination-page-number)}.monochrome .page{--ic-typography-color:var(--ic-pagination-page-number-monochrome)}.simple-current{min-width:calc(var(--ic-space-xxl) + var(--ic-space-md));height:var(--ic-space-lg);cursor:default}.item-container.page:hover:not(.selected):not(:focus){border-radius:var(--ic-border-radius);background-color:var(--ic-pagination-hover)}.item-container.page:active:not(.selected):not(:focus){background-color:var(--ic-pagination-pressed)}.monochrome .item-container.page:hover:not(.selected):not(:focus){background-color:var(--ic-pagination-hover-monochrome)}.monochrome .item-container.page:active:not(.selected):not(:focus){background-color:var(--ic-pagination-pressed-monochrome)}.selected{pointer-events:none;outline:none}.selected::after{content:\"\";height:var(--ic-space-xxs);width:100%;position:absolute;bottom:0;background-color:var(--ic-pagination-selected-banner)}.monochrome .selected::after{background-color:var(--ic-pagination-selected-banner-monochrome)}.page-selected{--ic-typography-color:var(--ic-pagination-text)}.item-container.page.light:hover:not(.selected):not(:focus){background-color:var(--ic-action-light-bg-hover)}.item-container.page.light:active:not(.selected):not(:focus){background-color:var(--ic-action-light-bg-pressed)}ic-typography.light,ic-typography.page-selected.light{--ic-typography-color:var(--ic-architectural-white)}.selected.light::after{content:\"\";height:var(--ic-space-xxs);width:100%;position:absolute;bottom:0;background-color:var(--ic-action-monochrome)}.item-container.page.dark:hover:not(.selected):not(:focus){background-color:var(--ic-action-dark-bg-hover)}.item-container.page.dark:active:not(.selected):not(:focus){background-color:var(--ic-action-dark-bg-pressed)}ic-typography.dark{--ic-typography-color:var(--ic-color-text-primary)}.selected.dark::after{content:\"\";height:var(--ic-space-xxs);width:100%;position:absolute;bottom:0;background-color:var(--ic-action-monochrome-dark)}.disabled{--ic-typography-color:var(--ic-pagination-text-disabled);pointer-events:none;cursor:none;-webkit-user-select:none;-moz-user-select:none;user-select:none}.disabled.page ic-typography{--ic-typography-color:var(--ic-pagination-page-number-disabled)}.disabled.ellipsis{--ic-typography-color:var(--ic-pagination-ellipsis-disabled)}.monochrome .disabled.page{--ic-typography-color:var(--ic-pagination-page-number-monochrome-disabled)}.monochrome .disabled.ellipsis{--ic-typography-color:var(--ic-pagination-ellipsis-monochrome-disabled)}@media (forced-colors: active){.selected::after{background-color:Highlight}.selected.light::after{background-color:Highlight}.selected.dark::after{background-color:Highlight}.disabled{--ic-typography-color:GrayText}}";
|
|
281
|
-
const IcPaginationItemStyle0 = icPaginationItemCss;
|
|
282
|
-
|
|
283
|
-
const PaginationItem = class {
|
|
284
|
-
constructor(hostRef) {
|
|
285
|
-
registerInstance(this, hostRef);
|
|
286
|
-
this.paginationItemClick = createEvent(this, "paginationItemClick", 7);
|
|
287
|
-
/**
|
|
288
|
-
* If `true`, the pagination item will be disabled.
|
|
289
|
-
*/
|
|
290
|
-
this.disabled = false;
|
|
291
|
-
/**
|
|
292
|
-
* The label for the pagination item (applicable when simple pagination is being used).
|
|
293
|
-
*/
|
|
294
|
-
this.label = "Page";
|
|
295
|
-
/**
|
|
296
|
-
* If `true`, the pagination item will display as black in the light theme, and white in dark theme.
|
|
297
|
-
*/
|
|
298
|
-
this.monochrome = false;
|
|
299
|
-
/**
|
|
300
|
-
* If `true`, the pagination item will be selected.
|
|
301
|
-
*/
|
|
302
|
-
this.selected = false;
|
|
303
|
-
/**
|
|
304
|
-
* 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.
|
|
305
|
-
*/
|
|
306
|
-
this.theme = "inherit";
|
|
307
|
-
this.handleClick = () => {
|
|
308
|
-
this.paginationItemClick.emit({ page: this.page || null });
|
|
309
|
-
};
|
|
310
|
-
}
|
|
311
|
-
watchDisabledHandler() {
|
|
312
|
-
removeDisabledFalse(this.disabled, this.el);
|
|
313
|
-
}
|
|
314
|
-
watchLabelHandler() {
|
|
315
|
-
this.capitalizedLabel = capitalize(this.label);
|
|
316
|
-
}
|
|
317
|
-
componentWillLoad() {
|
|
318
|
-
this.watchLabelHandler();
|
|
319
|
-
removeDisabledFalse(this.disabled, this.el);
|
|
320
|
-
}
|
|
321
|
-
render() {
|
|
322
|
-
const { page, selected, type, disabled, label, capitalizedLabel, monochrome, } = this;
|
|
323
|
-
return (h("a", { key: 'c067a0e35e2a92dff8d7f24d135a06a686d74a7d', class: { ["monochrome"]: !!monochrome } }, type === "ellipsis" ? (h("div", { class: {
|
|
324
|
-
["item-container"]: true,
|
|
325
|
-
["ellipsis"]: true,
|
|
326
|
-
["disabled"]: !!disabled,
|
|
327
|
-
} }, h("ic-typography", { variant: "label" }, "..."))) : type === "page" ? (h("button", { disabled: disabled, onClick: this.handleClick, tabindex: selected ? "-1" : "0", role: "button", "aria-current": selected && "page", "aria-label": selected ? `${label}: ${page}` : `Go to ${label} ${page}`, class: {
|
|
328
|
-
["selected"]: !disabled && selected,
|
|
329
|
-
["disabled"]: !!disabled,
|
|
330
|
-
["item-container"]: true,
|
|
331
|
-
["page"]: type === "page",
|
|
332
|
-
} }, h("ic-typography", { variant: "label", class: {
|
|
333
|
-
["page-selected"]: selected,
|
|
334
|
-
["disabled"]: !!disabled,
|
|
335
|
-
} }, page))) : (h("ic-typography", { "aria-live": "polite", class: {
|
|
336
|
-
[`simple-current`]: true,
|
|
337
|
-
["disabled"]: !!disabled,
|
|
338
|
-
}, variant: "label" }, capitalizedLabel, " ", page))));
|
|
339
|
-
}
|
|
340
|
-
get el() { return getElement(this); }
|
|
341
|
-
static get watchers() { return {
|
|
342
|
-
"disabled": ["watchDisabledHandler"],
|
|
343
|
-
"label": ["watchLabelHandler"]
|
|
344
|
-
}; }
|
|
345
|
-
};
|
|
346
|
-
PaginationItem.style = IcPaginationItemStyle0;
|
|
347
|
-
|
|
348
|
-
const Expand = `<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
|
|
349
|
-
<path d="M7 9.5L12 14.5L17 9.5H7Z" fill="currentColor" />
|
|
350
|
-
</svg>
|
|
351
|
-
`;
|
|
352
|
-
|
|
353
|
-
const Clear = `<svg width="16" height="16" viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg">
|
|
354
|
-
<path d="M12.6666 4.27334L11.7266 3.33334L7.99998 7.06001L4.27331 3.33334L3.33331 4.27334L7.05998 8.00001L3.33331 11.7267L4.27331 12.6667L7.99998 8.94001L11.7266 12.6667L12.6666 11.7267L8.93998 8.00001L12.6666 4.27334Z" fill="currentColor" />
|
|
355
|
-
</svg>
|
|
356
|
-
`;
|
|
357
|
-
|
|
358
|
-
const icSelectCss = "/*! 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;position:relative;--ic-input-label-helpertext-padding:var(--ic-space-xs);--menu-max-height:100px;--border-color:var(--ic-select-field-border);--border-color-hover:var(--ic-select-field-border-hover);--border-color-pressed:var(--ic-select-field-border-pressed);--border-color-disabled:var(--ic-select-field-border-disabled);--border-color-error:var(--ic-select-field-border-error);--border-color-error-hover:var(--ic-select-field-border-error-hover);--border-color-error-pressed:var(--ic-select-field-border-error-pressed);--border-color-success:var(--ic-select-field-border-success);--border-color-success-hover:var(--ic-select-field-border-success-hover);--border-color-success-pressed:var(--ic-select-field-border-success-pressed);--border-color-warning:var(--ic-select-field-border-warning);--border-color-warning-hover:var(--ic-select-field-border-warning-hover);--border-color-warning-pressed:var(--ic-select-field-border-warning-pressed);--ic-input-label-text-color:var(--ic-select-field-label);--ic-input-label-helper-text-color:var(\n --ic-select-input-field-label-subtitle\n );--ic-input-validation-status-text-color:var(--ic-select-state-text);--ic-input-validation-error:var(--ic-select-state-icon-error);--ic-input-validation-warning-icon-color:var(--ic-select-state-icon-warning);--ic-input-validation-success-icon-color:var(--ic-select-state-icon-success);--menu-item-text-color:var(--ic-select-list-option-text);--menu-bg-color:var(--ic-select-list-option-background);--menu-border-color:var(--ic-select-dropdown-list-border)}:host(.ic-select-disabled){--ic-input-label-text-color:var(--ic-select-field-label-disabled);--ic-input-label-helper-text-color:var(\n --ic-select-input-field-label-subtitle-disabled\n )}:host(.ic-select-full-width){width:100%}ic-input-component-container.menu-open{--border-color:var(--ic-select-field-border-pressed)}ic-input-validation .status-icon,ic-input-validation .statustext{visibility:visible}ic-input-validation.menu-open .status-icon,ic-input-validation.menu-open .statustext{visibility:hidden;transition:visibility 0s}ic-input-label{margin-bottom:var(--ic-space-xs)}select{border:0;border-radius:var(--ic-border-radius);background-color:var(--ic-select-field-background);color:var(--ic-select-content-text);line-height:1.5rem;letter-spacing:0.005rem;width:100%;height:100%;padding-left:0.375rem;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-repeat:no-repeat;background-position:right 0.375rem center;background-image:var(--ic-select-mobile-dropdown-icon);caret-color:var(--ic-select-input-field-text-cursor)}select option,.select-option-selected{color:var(--ic-select-list-option-text)}select:disabled{color:var(--ic-select-content-text-disabled);background-image:var(--ic-select-mobile-dropdown-icon-disabled)}select:focus{border:0;outline:0}select:not([disabled]){cursor:pointer}.select-container{width:100%;display:flex;align-items:center;position:relative}.select-input{width:100%;height:100%;padding:0 0.375rem;display:flex;cursor:pointer;align-items:center;justify-content:space-between;background:none;border:none;background-color:var(--ic-select-field-background);color:var(--ic-select-content-text)}.select-input:focus{outline:none}.select-input[disabled]{pointer-events:none}:host(.ic-select-searchable) .select-input{cursor:auto}.select-input.with-clear-button{padding-right:0}.value-text{max-width:calc(100% - (var(--ic-space-lg) + var(--ic-space-xxs)));box-sizing:border-box;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;margin-bottom:0 !important}.value-text.with-clear-button{padding-right:calc(var(--ic-space-xl) + var(--ic-space-xs))}.searchable-select-container{align-items:center;display:flex;width:100%;position:relative}.expand-icon{height:var(--ic-space-lg);padding-left:var(--ic-space-xxs);color:var(--ic-select-expand-icon-color)}.expand-icon>svg{display:inline-block;width:var(--ic-space-lg);height:var(--ic-space-lg)}:host(.ic-select-disabled) .expand-icon,:host(.ic-select-disabled) .expand-icon>svg>path{color:var(--ic-select-disabled-expand-icon-color)}:host(.ic-select-searchable) .expand-icon{padding-left:0;height:2.25rem}:host(.ic-select-searchable) .expand-icon>svg{height:2.25rem;padding:0 calc(var(--ic-space-xxxs) + var(--ic-space-xxs)) 0\n var(--ic-space-xxs)}:host(.ic-select-searchable:not(.ic-select-disabled)) .expand-icon>svg{cursor:pointer}.expand-icon-open{color:var(--ic-select-expand-icon-color)}.expand-icon-open,:host(.ic-select-searchable) .expand-icon-open{transform:rotateX(180deg)}.placeholder{color:var(--ic-select-content-placeholder-text)}:host(.ic-select-disabled.ic-select-searchable) .select-input::-moz-placeholder{color:var(--ic-select-content-text-disabled)}:host(.ic-select-disabled) .value-text,:host(.ic-select-disabled) .select-input,:host(.ic-select-disabled) .placeholder,:host(.ic-select-disabled.ic-select-searchable) .select-input::placeholder{color:var(--ic-select-content-text-disabled)}.select-input-end{display:flex;align-items:center}.clear-button-container{display:flex;align-items:center}.divider{width:var(--ic-space-1px);background-color:var(--ic-select-content-divider);margin:var(--ic-space-xxs) 0;border-radius:var(--ic-space-1px);height:var(--ic-space-lg)}:host(.ic-select-small) .divider{height:var(--ic-space-md)}:host(.ic-select-large) .divider{height:var(--ic-space-xl)}.clear-button{color:var(--ic-select-clear-button);position:absolute;right:calc(var(--ic-space-xl) + var(--ic-space-xxs) - var(--ic-space-1px));border-radius:var(--ic-border-radius);transition:box-shadow var(--ic-easing-transition),\n border-radius var(--ic-easing-transition)}.clear-button:focus,.clear-button:active{background-color:var(--ic-color-focus-inner);box-shadow:inset 0 0 0 0.125rem var(--ic-color-focus-outer);border-radius:0.25rem}.clear-button:focus,.clear-button:active *{fill:var(--ic-atoms-input-clear-button-focus)}.clear-button.searchable{position:static}.searchable-select-results-status,.multi-select-selected-count{border:0;clip:rect(0, 0, 0, 0, 0);height:var(--ic-space-1px);overflow:hidden;padding:0;position:absolute;white-space:nowrap;width:var(--ic-space-1px)}::slotted([slot=\"icon\"]){fill:var(--ic-select-content-placeholder-text)}.has-value ::slotted([slot=\"icon\"]){fill:var(--ic-select-content-text)}.readonly ::slotted([slot=\"icon\"]){padding:0.375rem;margin-bottom:0.75rem}@media (forced-colors: active){.has-value ::slotted([slot=\"icon\"]){fill:currentcolor}}";
|
|
359
|
-
const IcSelectStyle0 = icSelectCss;
|
|
360
|
-
|
|
361
|
-
let inputIds$1 = 0;
|
|
362
|
-
const MUTABLE_ATTRIBUTES$1 = [...IC_INHERITED_ARIA, "tabindex", "title"];
|
|
363
|
-
const Select = class {
|
|
364
|
-
constructor(hostRef) {
|
|
365
|
-
registerInstance(this, hostRef);
|
|
366
|
-
this.icBlur = createEvent(this, "icBlur", 7);
|
|
367
|
-
this.icChange = createEvent(this, "icChange", 7);
|
|
368
|
-
this.icClear = createEvent(this, "icClear", 7);
|
|
369
|
-
this.icClose = createEvent(this, "icClose", 7);
|
|
370
|
-
this.icFocus = createEvent(this, "icFocus", 7);
|
|
371
|
-
this.icInput = createEvent(this, "icInput", 7);
|
|
372
|
-
this.icOpen = createEvent(this, "icOpen", 7);
|
|
373
|
-
this.icOptionSelect = createEvent(this, "icOptionSelect", 7);
|
|
374
|
-
this.icOptionDeselect = createEvent(this, "icOptionDeselect", 7);
|
|
375
|
-
this.icRetryLoad = createEvent(this, "icRetryLoad", 7);
|
|
376
|
-
this.blurredBecauseButtonPressed = false;
|
|
377
|
-
this.hasSetDefaultValue = false;
|
|
378
|
-
this.hasTimedOut = false;
|
|
379
|
-
this.inheritedAttributes = {};
|
|
380
|
-
this.initialOptionsEmpty = false;
|
|
381
|
-
this.inputId = `ic-select-input-${inputIds$1++}`;
|
|
382
|
-
this.menuId = `${this.inputId}-menu`;
|
|
383
|
-
this.retryButtonClick = false;
|
|
384
|
-
this.searchableMenuItemSelected = false;
|
|
385
|
-
this.ungroupedOptions = [];
|
|
386
|
-
this.hostMutationObserver = null;
|
|
387
|
-
this.clearButtonFocused = false;
|
|
388
|
-
this.noOptions = null;
|
|
389
|
-
this.open = false;
|
|
390
|
-
this.pressedCharacters = "";
|
|
391
|
-
this.searchableSelectInputValue = null;
|
|
392
|
-
/**
|
|
393
|
-
* If `true`, the disabled state will be set.
|
|
394
|
-
*/
|
|
395
|
-
this.disabled = false;
|
|
396
|
-
/**
|
|
397
|
-
* If `true`, the built in filtering will be disabled for a searchable variant. For example, if options will already be filtered from external source.
|
|
398
|
-
*/
|
|
399
|
-
this.disableAutoFiltering = false;
|
|
400
|
-
/**
|
|
401
|
-
* The text displayed when there are no options in the option list.
|
|
402
|
-
*/
|
|
403
|
-
this.emptyOptionListText = "No results found";
|
|
404
|
-
/**
|
|
405
|
-
* If `true`, the select will fill the width of the container.
|
|
406
|
-
*/
|
|
407
|
-
this.fullWidth = false;
|
|
408
|
-
/**
|
|
409
|
-
* The helper text that will be displayed for additional field guidance.
|
|
410
|
-
*/
|
|
411
|
-
this.helperText = "";
|
|
412
|
-
/**
|
|
413
|
-
* If `true`, the label will be hidden and the required label value will be applied as an aria-label.
|
|
414
|
-
*/
|
|
415
|
-
this.hideLabel = false;
|
|
416
|
-
/**
|
|
417
|
-
* If `true`, descriptions of options will be included when filtering options in a searchable select. Only applies to built in filtering.
|
|
418
|
-
*/
|
|
419
|
-
this.includeDescriptionsInSearch = false;
|
|
420
|
-
/**
|
|
421
|
-
* If `true`, group titles of grouped options will be included when filtering options in a searchable select. Only applies to built in filtering.
|
|
422
|
-
*/
|
|
423
|
-
this.includeGroupTitlesInSearch = false;
|
|
424
|
-
/**
|
|
425
|
-
* The message displayed when external loading times out.
|
|
426
|
-
*/
|
|
427
|
-
this.loadingErrorLabel = "Loading Error";
|
|
428
|
-
/**
|
|
429
|
-
* The message displayed whilst the options are being loaded externally.
|
|
430
|
-
*/
|
|
431
|
-
this.loadingLabel = "Loading...";
|
|
432
|
-
/**
|
|
433
|
-
* If `true`, multiple options can be selected.
|
|
434
|
-
*/
|
|
435
|
-
this.multiple = false;
|
|
436
|
-
/**
|
|
437
|
-
* The name of the control, which is submitted with the form data.
|
|
438
|
-
*/
|
|
439
|
-
this.name = this.inputId;
|
|
440
|
-
/**
|
|
441
|
-
* The placeholder value to be displayed.
|
|
442
|
-
*/
|
|
443
|
-
this.placeholder = "Select an option";
|
|
444
|
-
/**
|
|
445
|
-
* If `true`, the readonly state will be set.
|
|
446
|
-
*/
|
|
447
|
-
this.readonly = false;
|
|
448
|
-
/**
|
|
449
|
-
* If `true`, the select will require a value.
|
|
450
|
-
*/
|
|
451
|
-
this.required = false;
|
|
452
|
-
/**
|
|
453
|
-
* If `true`, a searchable variant of the select will be displayed which can be typed in to filter options. This functionality is only available on the single-select variant of the select component.
|
|
454
|
-
*/
|
|
455
|
-
this.searchable = false;
|
|
456
|
-
/**
|
|
457
|
-
* Whether the search string of the searchable select should match the start of or anywhere in the options. Only applies to built in filtering.
|
|
458
|
-
*/
|
|
459
|
-
this.searchMatchPosition = "anywhere";
|
|
460
|
-
/**
|
|
461
|
-
* If `true`, the icOptionSelect event will be fired on enter instead of ArrowUp and ArrowDown on the single select.
|
|
462
|
-
*/
|
|
463
|
-
this.selectOnEnter = false;
|
|
464
|
-
/**
|
|
465
|
-
* If `true`, a button which clears the select input when clicked will be displayed. The button will always appear on the searchable select.
|
|
466
|
-
*/
|
|
467
|
-
this.showClearButton = false;
|
|
468
|
-
/**
|
|
469
|
-
* The size of the select.
|
|
470
|
-
*/
|
|
471
|
-
this.size = "medium";
|
|
472
|
-
/**
|
|
473
|
-
* 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.
|
|
474
|
-
*/
|
|
475
|
-
this.theme = "inherit";
|
|
476
|
-
/**
|
|
477
|
-
* The value of the `aria-live` attribute on the validation message.
|
|
478
|
-
*/
|
|
479
|
-
this.validationAriaLive = "polite";
|
|
480
|
-
/**
|
|
481
|
-
* The validation status - e.g. 'error' | 'warning' | 'success'.
|
|
482
|
-
*/
|
|
483
|
-
this.validationStatus = "";
|
|
484
|
-
/**
|
|
485
|
-
* The text to display as the validation message.
|
|
486
|
-
*/
|
|
487
|
-
this.validationText = "";
|
|
488
|
-
/**
|
|
489
|
-
* If `true`, the loading state will be triggered when fetching options asynchronously.
|
|
490
|
-
*/
|
|
491
|
-
this.loading = false;
|
|
492
|
-
/**
|
|
493
|
-
* The possible selection options.
|
|
494
|
-
*/
|
|
495
|
-
this.options = [];
|
|
496
|
-
this.filteredOptions = this.options;
|
|
497
|
-
this.uniqueOptions = this.options;
|
|
498
|
-
/**
|
|
499
|
-
* The amount of time, in milliseconds, to wait to trigger the `icInput` event after each keystroke.
|
|
500
|
-
*/
|
|
501
|
-
this.debounce = 0;
|
|
502
|
-
this.currDebounce = this.debounce;
|
|
503
|
-
/**
|
|
504
|
-
* The value of the select, reflected by the value of the currently selected option.
|
|
505
|
-
* For the searchable variant, the value is also reflected by the user input.
|
|
506
|
-
* For the multi-select variant, the value must be an array of option values.
|
|
507
|
-
*/
|
|
508
|
-
this.value = null;
|
|
509
|
-
this.initialValue = this.value;
|
|
510
|
-
this.inputValueToFilter = this.value;
|
|
511
|
-
// triggered when attributes of host element change
|
|
512
|
-
this.hostMutationCallback = (mutationList) => {
|
|
513
|
-
let forceComponentUpdate = false;
|
|
514
|
-
mutationList.forEach(({ attributeName, type, addedNodes, removedNodes }) => {
|
|
515
|
-
if (attributeName) {
|
|
516
|
-
const attribute = this.el.getAttribute(attributeName);
|
|
517
|
-
if (attribute && MUTABLE_ATTRIBUTES$1.includes(attributeName)) {
|
|
518
|
-
this.inheritedAttributes[attributeName] = attribute;
|
|
519
|
-
forceComponentUpdate = true;
|
|
520
|
-
}
|
|
521
|
-
}
|
|
522
|
-
else if (type === "childList") {
|
|
523
|
-
forceComponentUpdate = checkSlotInChildMutations(addedNodes, removedNodes, "icon");
|
|
524
|
-
}
|
|
525
|
-
});
|
|
526
|
-
if (forceComponentUpdate) {
|
|
527
|
-
forceUpdate(this);
|
|
528
|
-
}
|
|
529
|
-
};
|
|
530
|
-
this.handleRetry = (ev) => {
|
|
531
|
-
var _a;
|
|
532
|
-
if (ev.detail.keyPressed)
|
|
533
|
-
(_a = this.searchableSelectElement) === null || _a === void 0 ? void 0 : _a.focus();
|
|
534
|
-
this.blurredBecauseButtonPressed = true;
|
|
535
|
-
this.retryButtonClick = true;
|
|
536
|
-
this.hasSetDefaultValue = true;
|
|
537
|
-
this.icRetryLoad.emit({
|
|
538
|
-
value: this.searchable
|
|
539
|
-
? this.searchableSelectInputValue
|
|
540
|
-
: this.hiddenInputValue,
|
|
541
|
-
});
|
|
542
|
-
};
|
|
543
|
-
this.emitIcChange = (value) => {
|
|
544
|
-
// If "Select all" button clicked, replace value with new value (array of all option values)
|
|
545
|
-
if (this.multiple && !Array.isArray(value) && value !== null) {
|
|
546
|
-
// Update selected options - adds / removes them, in order of option list
|
|
547
|
-
// Create new array if value prop is undefined
|
|
548
|
-
if (this.value) {
|
|
549
|
-
let valueArray = this.value.slice();
|
|
550
|
-
if (this.value.includes(value)) {
|
|
551
|
-
valueArray.splice(valueArray.indexOf(value), 1);
|
|
552
|
-
}
|
|
553
|
-
else {
|
|
554
|
-
valueArray.push(value);
|
|
555
|
-
valueArray = this.getValueSortedByOptions(valueArray);
|
|
556
|
-
}
|
|
557
|
-
this.value = valueArray.length === 0 ? null : valueArray;
|
|
558
|
-
}
|
|
559
|
-
else {
|
|
560
|
-
this.value = [value];
|
|
561
|
-
}
|
|
562
|
-
}
|
|
563
|
-
else {
|
|
564
|
-
this.value = value;
|
|
565
|
-
}
|
|
566
|
-
this.icChange.emit({ value: this.multiple ? this.value : value });
|
|
567
|
-
};
|
|
568
|
-
this.emitIcInput = (value) => {
|
|
569
|
-
clearTimeout(this.debounceIcInput);
|
|
570
|
-
this.debounceIcInput = window.setTimeout(() => this.icInput.emit({ value }), this.currDebounce);
|
|
571
|
-
};
|
|
572
|
-
this.setOptions = () => {
|
|
573
|
-
if (!this.hasTimedOut && this.options !== this.noOptions) {
|
|
574
|
-
this.loading = false;
|
|
575
|
-
clearTimeout(this.timeoutTimer);
|
|
576
|
-
if (this.options.length > 0) {
|
|
577
|
-
this.setOptionsValuesFromLabels();
|
|
578
|
-
this.uniqueOptions = this.deduplicateOptions(this.options);
|
|
579
|
-
}
|
|
580
|
-
else {
|
|
581
|
-
this.noOptions = [{ label: this.emptyOptionListText, value: "" }];
|
|
582
|
-
this.uniqueOptions = this.noOptions;
|
|
583
|
-
}
|
|
584
|
-
this.filteredOptions = this.uniqueOptions;
|
|
585
|
-
if (this.isExternalFiltering()) {
|
|
586
|
-
// When searchable select
|
|
587
|
-
this.noOptions = null;
|
|
588
|
-
this.updateSearchableSelectResultAriaLive();
|
|
589
|
-
this.setDefaultValue();
|
|
590
|
-
}
|
|
591
|
-
else if (this.initialOptionsEmpty) {
|
|
592
|
-
this.setDefaultValue();
|
|
593
|
-
this.initialOptionsEmpty = false;
|
|
594
|
-
}
|
|
595
|
-
}
|
|
596
|
-
else if (!this.searchable) {
|
|
597
|
-
this.options = this.noOptions || [];
|
|
598
|
-
}
|
|
599
|
-
};
|
|
600
|
-
/**
|
|
601
|
-
* Processes the provided array of IcMenuOptions, removing duplicates and reporting them with a console.warn
|
|
602
|
-
* @param options array of IcMenuOptions
|
|
603
|
-
* @returns a new options object, with all entries possessing a duplicate 'value' field removed
|
|
604
|
-
*/
|
|
605
|
-
this.deduplicateOptions = (options) => {
|
|
606
|
-
const uniqueValues = [];
|
|
607
|
-
const dedupedOptions = [];
|
|
608
|
-
options.forEach((option) => {
|
|
609
|
-
if (option.children) {
|
|
610
|
-
//If an option has children, we will loop through them
|
|
611
|
-
const dedupedChildren = [];
|
|
612
|
-
option.children.forEach((child) => {
|
|
613
|
-
if (uniqueValues.includes(child.value)) {
|
|
614
|
-
console.warn(`ic-select with label ${this.label} was populated with duplicate option (value: ${child.value}) which has been removed.`);
|
|
615
|
-
}
|
|
616
|
-
else {
|
|
617
|
-
uniqueValues.push(child.value);
|
|
618
|
-
dedupedChildren.push(child);
|
|
619
|
-
}
|
|
620
|
-
});
|
|
621
|
-
// construct a modified option, inserting the deduplicated children alongside the original information
|
|
622
|
-
dedupedOptions.push(Object.assign(Object.assign({}, option), { children: dedupedChildren }));
|
|
623
|
-
}
|
|
624
|
-
else {
|
|
625
|
-
// If an option does not have children, assess to see if it's value has been included already
|
|
626
|
-
if (uniqueValues.includes(option.value)) {
|
|
627
|
-
console.warn(`ic-select with label ${this.label} was populated with duplicate option (value: ${option.value}) which has been removed.`);
|
|
628
|
-
}
|
|
629
|
-
else {
|
|
630
|
-
uniqueValues.push(option.value);
|
|
631
|
-
dedupedOptions.push(option);
|
|
632
|
-
}
|
|
633
|
-
}
|
|
634
|
-
});
|
|
635
|
-
return dedupedOptions;
|
|
636
|
-
};
|
|
637
|
-
/**
|
|
638
|
-
* Loop through options array and for all options with no value, infer it from the label
|
|
639
|
-
*/
|
|
640
|
-
this.setOptionsValuesFromLabels = () => {
|
|
641
|
-
if (this.options.length > 0) {
|
|
642
|
-
this.options.map((option) => {
|
|
643
|
-
if (!option.value) {
|
|
644
|
-
option.value = option.label;
|
|
645
|
-
}
|
|
646
|
-
});
|
|
647
|
-
}
|
|
648
|
-
};
|
|
649
|
-
this.setUngroupedOptions = (event) => {
|
|
650
|
-
this.ungroupedOptions = event.detail.options;
|
|
651
|
-
};
|
|
652
|
-
this.setTextColor = () => {
|
|
653
|
-
if (this.nativeSelectElement) {
|
|
654
|
-
this.nativeSelectElement.className =
|
|
655
|
-
this.nativeSelectElement.selectedIndex === 0
|
|
656
|
-
? "placeholder"
|
|
657
|
-
: "select-option-selected";
|
|
658
|
-
}
|
|
659
|
-
};
|
|
660
|
-
this.setMenuChange = (open) => {
|
|
661
|
-
if (this.open !== open) {
|
|
662
|
-
this.open = open;
|
|
663
|
-
}
|
|
664
|
-
};
|
|
665
|
-
this.getLabelFromValue = (value) => getLabelFromValue(value, this.uniqueOptions);
|
|
666
|
-
this.getMultipleOptionsString = (selectedValues) => selectedValues === null || selectedValues === void 0 ? void 0 : selectedValues.map((value) => this.getLabelFromValue(value)).filter((label) => !!label).join(", ");
|
|
667
|
-
this.getFilteredChildMenuOptions = (option) => (Object.assign(Object.assign({}, option), { children: option.children &&
|
|
668
|
-
getFilteredMenuOptions(option.children, this.searchable && !!this.includeDescriptionsInSearch, this.searchable
|
|
669
|
-
? this.searchableSelectInputValue || ""
|
|
670
|
-
: this.pressedCharacters, this.searchable ? this.searchMatchPosition : "start") }));
|
|
671
|
-
// (For multi-select) get value array, i.e. selected option values, in order they appear in option list
|
|
672
|
-
this.getValueSortedByOptions = (value) => {
|
|
673
|
-
const valueArray = value;
|
|
674
|
-
const valuesFromAllOptions = this.ungroupedOptions.map((option) => option.value);
|
|
675
|
-
valueArray.sort((a, b) => valuesFromAllOptions.indexOf(a) - valuesFromAllOptions.indexOf(b));
|
|
676
|
-
return valueArray;
|
|
677
|
-
};
|
|
678
|
-
this.handleNativeSelectChange = () => {
|
|
679
|
-
if (this.nativeSelectElement) {
|
|
680
|
-
this.icOptionSelect.emit({ value: this.nativeSelectElement.value });
|
|
681
|
-
this.emitIcChange(this.nativeSelectElement.value);
|
|
682
|
-
}
|
|
683
|
-
this.setTextColor();
|
|
684
|
-
};
|
|
685
|
-
// Handle option select for when a custom input box and menu is rendered
|
|
686
|
-
// (rather than native <select> - rendered when viewed on a mobile / tablet screen)
|
|
687
|
-
this.handleCustomSelectChange = (event) => {
|
|
688
|
-
var _a, _b;
|
|
689
|
-
const { value, label, optionId } = event.detail;
|
|
690
|
-
if (label === this.emptyOptionListText) {
|
|
691
|
-
(_a = this.searchableSelectElement) === null || _a === void 0 ? void 0 : _a.focus();
|
|
692
|
-
return;
|
|
693
|
-
}
|
|
694
|
-
if (this.searchable) {
|
|
695
|
-
this.value = value || null;
|
|
696
|
-
this.searchableMenuItemSelected = true;
|
|
697
|
-
// After editing the input, if selecting the same option as before, set the input value to label again
|
|
698
|
-
if (this.value === this.currValue) {
|
|
699
|
-
this.searchableSelectInputValue =
|
|
700
|
-
this.getLabelFromValue(this.value) || null;
|
|
701
|
-
}
|
|
702
|
-
this.inputValueToFilter = null;
|
|
703
|
-
this.hiddenInputValue =
|
|
704
|
-
this.getValueFromLabel(this.searchableSelectInputValue) || null;
|
|
705
|
-
}
|
|
706
|
-
if (value) {
|
|
707
|
-
if (this.multiple && ((_b = this.value) === null || _b === void 0 ? void 0 : _b.includes(value))) {
|
|
708
|
-
this.icOptionDeselect.emit({ value });
|
|
709
|
-
}
|
|
710
|
-
else {
|
|
711
|
-
this.icOptionSelect.emit({ value });
|
|
712
|
-
}
|
|
713
|
-
}
|
|
714
|
-
this.ariaActiveDescendant = optionId;
|
|
715
|
-
this.emitIcChange(value || null);
|
|
716
|
-
};
|
|
717
|
-
this.handleSelectAllChange = ({ detail, }) => {
|
|
718
|
-
const allValues = this.ungroupedOptions
|
|
719
|
-
.filter((option) => !option.disabled)
|
|
720
|
-
.map((option) => option.value);
|
|
721
|
-
if (detail.select) {
|
|
722
|
-
// Only emit icOptionSelect for all values that are newly selected
|
|
723
|
-
const unselectedValues = this.value
|
|
724
|
-
? allValues.filter((value) => this.value && !this.value.includes(value))
|
|
725
|
-
: allValues;
|
|
726
|
-
unselectedValues.forEach((value) => this.icOptionSelect.emit({ value }));
|
|
727
|
-
}
|
|
728
|
-
else {
|
|
729
|
-
// Only emit icOptionDeselect for values that were selected
|
|
730
|
-
this.value.forEach((value) => this.icOptionDeselect.emit({ value }));
|
|
731
|
-
}
|
|
732
|
-
this.emitIcChange(detail.select ? allValues : null);
|
|
733
|
-
};
|
|
734
|
-
this.handleMenuChange = (event) => {
|
|
735
|
-
this.open = event.detail.open;
|
|
736
|
-
this.pressedCharacters = "";
|
|
737
|
-
if (this.searchable)
|
|
738
|
-
this.handleFocusIndicatorDisplay();
|
|
739
|
-
};
|
|
740
|
-
// clears the debounce delay when navigating the menu with arrow keys etc
|
|
741
|
-
// to prevent delay in change event, which should only occur when typing in input
|
|
742
|
-
this.handleMenuKeyPress = (ev) => {
|
|
743
|
-
ev.cancelBubble = true;
|
|
744
|
-
if (!this.multiple) {
|
|
745
|
-
this.handleCharacterKeyDown(ev.detail.key);
|
|
746
|
-
}
|
|
747
|
-
};
|
|
748
|
-
this.handleFocusIndicatorDisplay = () => {
|
|
749
|
-
var _a;
|
|
750
|
-
const focusIndicator = (_a = this.el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector(".focus-indicator");
|
|
751
|
-
if (focusIndicator) {
|
|
752
|
-
if (this.open) {
|
|
753
|
-
focusIndicator.classList.add("focus-indicator-enabled");
|
|
754
|
-
}
|
|
755
|
-
else {
|
|
756
|
-
focusIndicator.classList.remove("focus-indicator-enabled");
|
|
757
|
-
}
|
|
758
|
-
}
|
|
759
|
-
};
|
|
760
|
-
this.handleMouseDown = (event) => {
|
|
761
|
-
if (!this.open) {
|
|
762
|
-
event.preventDefault();
|
|
763
|
-
}
|
|
764
|
-
};
|
|
765
|
-
this.isExternalFiltering = () => this.searchable && !!this.disableAutoFiltering;
|
|
766
|
-
this.handleClick = (event) => {
|
|
767
|
-
var _a, _b;
|
|
768
|
-
if (!this.open && this.menu) {
|
|
769
|
-
if (this.isExternalFiltering()) {
|
|
770
|
-
this.menu.options = this.filteredOptions;
|
|
771
|
-
}
|
|
772
|
-
else if (!this.hasTimedOut &&
|
|
773
|
-
!this.loading &&
|
|
774
|
-
!((_a = this.noOptions) === null || _a === void 0 ? void 0 : _a.length) &&
|
|
775
|
-
(!this.searchable || this.searchableMenuItemSelected)) {
|
|
776
|
-
this.noOptions = null;
|
|
777
|
-
this.menu.options = this.uniqueOptions;
|
|
778
|
-
}
|
|
779
|
-
}
|
|
780
|
-
if (event.detail !== 0) {
|
|
781
|
-
(_b = this.menu) === null || _b === void 0 ? void 0 : _b.handleClickOpen();
|
|
782
|
-
}
|
|
783
|
-
};
|
|
784
|
-
this.handleExpandIconMouseDown = (event) => {
|
|
785
|
-
var _a;
|
|
786
|
-
if (!this.disabled) {
|
|
787
|
-
event.preventDefault();
|
|
788
|
-
(_a = this.searchableSelectElement) === null || _a === void 0 ? void 0 : _a.focus();
|
|
789
|
-
this.handleClick(event);
|
|
790
|
-
}
|
|
791
|
-
};
|
|
792
|
-
this.handleClear = (event) => {
|
|
793
|
-
var _a, _b;
|
|
794
|
-
event.stopPropagation();
|
|
795
|
-
this.hasTimedOut = false;
|
|
796
|
-
clearTimeout(this.timeoutTimer);
|
|
797
|
-
this.clearInput();
|
|
798
|
-
this.emitIcChange(null);
|
|
799
|
-
this.icClear.emit();
|
|
800
|
-
if (this.searchable) {
|
|
801
|
-
this.hiddenInputValue = null;
|
|
802
|
-
(_a = this.searchableSelectElement) === null || _a === void 0 ? void 0 : _a.focus();
|
|
803
|
-
}
|
|
804
|
-
else {
|
|
805
|
-
(_b = this.customSelectElement) === null || _b === void 0 ? void 0 : _b.focus();
|
|
806
|
-
}
|
|
807
|
-
};
|
|
808
|
-
this.handleCharacterKeyDown = (key) => {
|
|
809
|
-
// Only close menu when space is pressed if not being used alongside character keys to quickly select options
|
|
810
|
-
if (this.open && key === " " && this.pressedCharacters.length === 0) {
|
|
811
|
-
this.setMenuChange(false);
|
|
812
|
-
}
|
|
813
|
-
if (key.length !== 1 || this.searchable) {
|
|
814
|
-
this.pressedCharacters = "";
|
|
815
|
-
return;
|
|
816
|
-
}
|
|
817
|
-
window.clearTimeout(this.characterKeyPressTimer);
|
|
818
|
-
this.characterKeyPressTimer = window.setTimeout(() => (this.pressedCharacters = ""), 1000);
|
|
819
|
-
if (key !== " " || !!this.pressedCharacters) {
|
|
820
|
-
this.pressedCharacters += key;
|
|
821
|
-
this.handleFilter();
|
|
822
|
-
if (!this.noOptions) {
|
|
823
|
-
this.emitIcChange(this.filteredOptions[0].value);
|
|
824
|
-
}
|
|
825
|
-
}
|
|
826
|
-
};
|
|
827
|
-
this.handleNativeSelectKeyDown = (event) => {
|
|
828
|
-
if ((event.key !== "Escape" && event.key !== "Tab") || this.open) {
|
|
829
|
-
event.cancelBubble = true;
|
|
830
|
-
}
|
|
831
|
-
this.handleCharacterKeyDown(event.key);
|
|
832
|
-
};
|
|
833
|
-
this.handleKeyDown = (event) => {
|
|
834
|
-
var _a;
|
|
835
|
-
if ((event.key !== "Escape" && event.key !== "Tab") || this.open) {
|
|
836
|
-
event.cancelBubble = true;
|
|
837
|
-
}
|
|
838
|
-
const isArrowKey = event.key === "ArrowDown" || event.key === "ArrowUp";
|
|
839
|
-
if (this.menu && !this.open) {
|
|
840
|
-
if (this.isExternalFiltering() && (event.key === "Enter" || isArrowKey)) {
|
|
841
|
-
this.menu.options = this.filteredOptions;
|
|
842
|
-
}
|
|
843
|
-
else if (!this.hasTimedOut) {
|
|
844
|
-
this.noOptions = null;
|
|
845
|
-
this.menu.options = this.uniqueOptions;
|
|
846
|
-
}
|
|
847
|
-
}
|
|
848
|
-
if (this.open && event.key === "Enter") {
|
|
849
|
-
this.setMenuChange(false);
|
|
850
|
-
}
|
|
851
|
-
else {
|
|
852
|
-
if (!isArrowKey || this.noOptions === null) {
|
|
853
|
-
if (event.key !== " " || this.pressedCharacters.length <= 0) {
|
|
854
|
-
// Keyboard events get passed onto ic-menu except in the case of ctrl-a on a searchable select
|
|
855
|
-
const isCtrlA = event.key === "a" &&
|
|
856
|
-
((isMacDevice() && event.metaKey) ||
|
|
857
|
-
(!isMacDevice() && event.ctrlKey));
|
|
858
|
-
if (!(this.searchable && isCtrlA)) {
|
|
859
|
-
(_a = this.menu) === null || _a === void 0 ? void 0 : _a.handleKeyboardOpen(event);
|
|
860
|
-
}
|
|
861
|
-
}
|
|
862
|
-
if (!this.multiple) {
|
|
863
|
-
this.handleCharacterKeyDown(event.key);
|
|
864
|
-
}
|
|
865
|
-
}
|
|
866
|
-
}
|
|
867
|
-
};
|
|
868
|
-
this.handleClearButtonFocus = () => {
|
|
869
|
-
this.clearButtonFocused = true;
|
|
870
|
-
};
|
|
871
|
-
this.handleClearButtonBlur = (ev) => {
|
|
872
|
-
var _a;
|
|
873
|
-
const retryButton = (_a = this.menu) === null || _a === void 0 ? void 0 : _a.querySelector("#retry-button");
|
|
874
|
-
if ((!this.searchableSelectElement ||
|
|
875
|
-
ev.relatedTarget !== this.searchableSelectElement) &&
|
|
876
|
-
(!retryButton || ev.relatedTarget !== retryButton)) {
|
|
877
|
-
this.setMenuChange(false);
|
|
878
|
-
this.handleFocusIndicatorDisplay();
|
|
879
|
-
}
|
|
880
|
-
this.clearButtonFocused = false;
|
|
881
|
-
};
|
|
882
|
-
this.handleFilter = () => {
|
|
883
|
-
var _a;
|
|
884
|
-
const options = this.deduplicateOptions(this.searchable ? [...this.uniqueOptions] : this.ungroupedOptions);
|
|
885
|
-
const isGrouped = options.some((option) => !!option.children);
|
|
886
|
-
let newFilteredOptions = [];
|
|
887
|
-
let menuOptionsFiltered;
|
|
888
|
-
if (this.searchable) {
|
|
889
|
-
menuOptionsFiltered = getFilteredMenuOptions(options, !!this.includeDescriptionsInSearch, this.inputValueToFilter || "", this.searchMatchPosition);
|
|
890
|
-
this.searchableMenuItemSelected = false;
|
|
891
|
-
}
|
|
892
|
-
else {
|
|
893
|
-
menuOptionsFiltered = getFilteredMenuOptions(options, false, this.pressedCharacters, "start");
|
|
894
|
-
}
|
|
895
|
-
if (!isGrouped &&
|
|
896
|
-
((_a = menuOptionsFiltered[0]) === null || _a === void 0 ? void 0 : _a.label) !== this.emptyOptionListText) {
|
|
897
|
-
newFilteredOptions = menuOptionsFiltered;
|
|
898
|
-
}
|
|
899
|
-
else if (isGrouped) {
|
|
900
|
-
newFilteredOptions = options.map((option) => this.includeGroupTitlesInSearch &&
|
|
901
|
-
menuOptionsFiltered.indexOf(option) !== -1
|
|
902
|
-
? option
|
|
903
|
-
: this.getFilteredChildMenuOptions(option));
|
|
904
|
-
}
|
|
905
|
-
if (newFilteredOptions.length > 0 &&
|
|
906
|
-
(!isGrouped ||
|
|
907
|
-
newFilteredOptions.some(({ children }) => children && children.length > 0))) {
|
|
908
|
-
this.noOptions = null;
|
|
909
|
-
this.filteredOptions = newFilteredOptions;
|
|
910
|
-
}
|
|
911
|
-
else {
|
|
912
|
-
this.noOptions = [{ label: this.emptyOptionListText, value: "" }];
|
|
913
|
-
this.filteredOptions = this.noOptions;
|
|
914
|
-
}
|
|
915
|
-
};
|
|
916
|
-
/**
|
|
917
|
-
* Put the select component into loading state.
|
|
918
|
-
* Replace options with the loading message. If timeout is enabled, set the timeout and once passed, replace options with the loading error message
|
|
919
|
-
*/
|
|
920
|
-
this.triggerLoading = () => {
|
|
921
|
-
this.hasTimedOut = false;
|
|
922
|
-
this.noOptions = [{ label: this.loadingLabel, value: "", loading: true }];
|
|
923
|
-
if (this.filteredOptions !== this.noOptions && this.searchable) {
|
|
924
|
-
this.filteredOptions = this.noOptions;
|
|
925
|
-
}
|
|
926
|
-
else if (this.uniqueOptions !== this.noOptions && !this.searchable) {
|
|
927
|
-
this.uniqueOptions = this.noOptions;
|
|
928
|
-
}
|
|
929
|
-
if (this.timeout) {
|
|
930
|
-
this.timeoutTimer = window.setTimeout(() => {
|
|
931
|
-
this.loading = false;
|
|
932
|
-
this.hasTimedOut = true;
|
|
933
|
-
this.noOptions = [
|
|
934
|
-
{ label: this.loadingErrorLabel, value: "", timedOut: true },
|
|
935
|
-
];
|
|
936
|
-
this.filteredOptions = this.noOptions;
|
|
937
|
-
if (!this.searchable)
|
|
938
|
-
this.uniqueOptions = this.noOptions;
|
|
939
|
-
}, this.timeout);
|
|
940
|
-
}
|
|
941
|
-
};
|
|
942
|
-
this.getValueFromLabel = (label) => { var _a; return label && ((_a = this.uniqueOptions.find((option) => option.label === label)) === null || _a === void 0 ? void 0 : _a.value); };
|
|
943
|
-
this.handleSearchableSelectInput = (event) => {
|
|
944
|
-
this.searchableSelectInputValue = event.target.value;
|
|
945
|
-
this.emitIcInput(this.searchableSelectInputValue);
|
|
946
|
-
// De-select previous selection when input is edited
|
|
947
|
-
// Only emit icChange once when editing input
|
|
948
|
-
if (this.value != null) {
|
|
949
|
-
this.emitIcChange(null);
|
|
950
|
-
}
|
|
951
|
-
this.hiddenInputValue = null;
|
|
952
|
-
this.inputValueToFilter = this.searchableSelectInputValue;
|
|
953
|
-
this.setMenuChange(true);
|
|
954
|
-
if (!this.disableAutoFiltering) {
|
|
955
|
-
this.handleFilter();
|
|
956
|
-
clearTimeout(this.debounceAria);
|
|
957
|
-
window.setTimeout(() => {
|
|
958
|
-
this.updateSearchableSelectResultAriaLive();
|
|
959
|
-
}, 800);
|
|
960
|
-
}
|
|
961
|
-
};
|
|
962
|
-
this.updateSearchableSelectResultAriaLive = () => {
|
|
963
|
-
var _a;
|
|
964
|
-
const searchableSelectResultsStatusEl = (_a = this.el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector(".searchable-select-results-status");
|
|
965
|
-
if (searchableSelectResultsStatusEl) {
|
|
966
|
-
searchableSelectResultsStatusEl.innerText =
|
|
967
|
-
this.noOptions !== null ? this.emptyOptionListText : "";
|
|
968
|
-
}
|
|
969
|
-
};
|
|
970
|
-
this.updateMultiSelectedCountAriaLive = () => {
|
|
971
|
-
var _a, _b;
|
|
972
|
-
const multiSelectSelectedCountEl = (_a = this.el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector(".multi-select-selected-count");
|
|
973
|
-
const selectedCount = `${(_b = this.currValue) === null || _b === void 0 ? void 0 : _b.length} of ${getOptionsWithoutGroupTitlesCount(this.options)} selected`;
|
|
974
|
-
if (multiSelectSelectedCountEl &&
|
|
975
|
-
multiSelectSelectedCountEl.innerText !== selectedCount) {
|
|
976
|
-
multiSelectSelectedCountEl.innerText = selectedCount;
|
|
977
|
-
}
|
|
978
|
-
};
|
|
979
|
-
this.getDefaultValue = (value) => this.getLabelFromValue(value) || null;
|
|
980
|
-
this.setDefaultValue = () => {
|
|
981
|
-
if (!this.hasSetDefaultValue && this.currValue) {
|
|
982
|
-
this.searchableSelectInputValue = this.searchable
|
|
983
|
-
? this.getDefaultValue(this.currValue)
|
|
984
|
-
: null;
|
|
985
|
-
this.initialValue = this.currValue;
|
|
986
|
-
this.hasSetDefaultValue = true;
|
|
987
|
-
}
|
|
988
|
-
};
|
|
989
|
-
this.onFocus = () => {
|
|
990
|
-
this.icFocus.emit();
|
|
991
|
-
};
|
|
992
|
-
this.onBlur = ({ relatedTarget }) => {
|
|
993
|
-
var _a;
|
|
994
|
-
const target = relatedTarget;
|
|
995
|
-
if (target !== null &&
|
|
996
|
-
((target.tagName === "UL" && target.className.includes("menu")) ||
|
|
997
|
-
(target.tagName === "LI" && target.className.includes("option")))) {
|
|
998
|
-
return;
|
|
999
|
-
}
|
|
1000
|
-
const retryButton = (_a = this.menu) === null || _a === void 0 ? void 0 : _a.querySelector("#retry-button");
|
|
1001
|
-
if (this.searchable &&
|
|
1002
|
-
!!this.menu &&
|
|
1003
|
-
target !== this.menu &&
|
|
1004
|
-
!Array.from(this.menu.querySelectorAll("[role='option']")).includes(target) &&
|
|
1005
|
-
(!this.clearButton || target !== this.clearButton) &&
|
|
1006
|
-
(!retryButton || target !== retryButton)) {
|
|
1007
|
-
if (!this.retryButtonClick) {
|
|
1008
|
-
this.setMenuChange(false);
|
|
1009
|
-
// Clear input field on blur when searchable if no option is selected
|
|
1010
|
-
if (!this.value) {
|
|
1011
|
-
this.clearInput();
|
|
1012
|
-
}
|
|
1013
|
-
}
|
|
1014
|
-
this.handleFocusIndicatorDisplay();
|
|
1015
|
-
}
|
|
1016
|
-
this.retryButtonClick = false;
|
|
1017
|
-
this.icBlur.emit();
|
|
1018
|
-
};
|
|
1019
|
-
this.onTimeoutBlur = (ev) => {
|
|
1020
|
-
if (ev.detail.ev.relatedTarget !==
|
|
1021
|
-
this.searchableSelectElement &&
|
|
1022
|
-
!this.blurredBecauseButtonPressed) {
|
|
1023
|
-
this.setMenuChange(false);
|
|
1024
|
-
this.handleFocusIndicatorDisplay();
|
|
1025
|
-
this.icBlur.emit();
|
|
1026
|
-
}
|
|
1027
|
-
this.blurredBecauseButtonPressed = false;
|
|
1028
|
-
};
|
|
1029
|
-
this.handleFormReset = () => {
|
|
1030
|
-
this.value = this.initialValue;
|
|
1031
|
-
if (this.searchable) {
|
|
1032
|
-
this.searchableSelectInputValue = this.getDefaultValue(this.value);
|
|
1033
|
-
this.hiddenInputValue = this.value;
|
|
1034
|
-
}
|
|
1035
|
-
};
|
|
1036
|
-
this.clearInput = () => {
|
|
1037
|
-
var _a;
|
|
1038
|
-
this.noOptions = null;
|
|
1039
|
-
if (this.searchable) {
|
|
1040
|
-
(_a = this.searchableSelectElement) === null || _a === void 0 ? void 0 : _a.setAttribute("value", "");
|
|
1041
|
-
this.searchableSelectInputValue = null;
|
|
1042
|
-
this.filteredOptions = this.uniqueOptions;
|
|
1043
|
-
}
|
|
1044
|
-
};
|
|
1045
|
-
this.renderNativeOption = (option) => (h("option", { value: option.value, disabled: option.disabled, selected: option.value === this.currValue }, option.label));
|
|
1046
|
-
}
|
|
1047
|
-
watchDisabledHandler() {
|
|
1048
|
-
removeDisabledFalse(this.disabled, this.el);
|
|
1049
|
-
}
|
|
1050
|
-
loadingHandler(newValue) {
|
|
1051
|
-
newValue ? this.triggerLoading() : this.setOptions();
|
|
1052
|
-
}
|
|
1053
|
-
watchOptionsHandler() {
|
|
1054
|
-
this.setOptions();
|
|
1055
|
-
}
|
|
1056
|
-
debounceChangedHandler(newValue) {
|
|
1057
|
-
if (this.currDebounce !== newValue) {
|
|
1058
|
-
this.currDebounce = newValue;
|
|
1059
|
-
}
|
|
1060
|
-
}
|
|
1061
|
-
valueChangedHandler() {
|
|
1062
|
-
if (this.value !== this.currValue) {
|
|
1063
|
-
if (this.value && this.multiple) {
|
|
1064
|
-
this.currValue = this.getMultipleOptionsString(this.value)
|
|
1065
|
-
? this.getValueSortedByOptions(this.value)
|
|
1066
|
-
: null;
|
|
1067
|
-
this.updateMultiSelectedCountAriaLive();
|
|
1068
|
-
}
|
|
1069
|
-
else {
|
|
1070
|
-
this.currValue = this.getLabelFromValue(this.value)
|
|
1071
|
-
? this.value
|
|
1072
|
-
: null;
|
|
1073
|
-
}
|
|
1074
|
-
}
|
|
1075
|
-
if (this.searchable && this.value) {
|
|
1076
|
-
// Only set if value not null - prevents whole input value being cleared when edited
|
|
1077
|
-
this.searchableSelectInputValue =
|
|
1078
|
-
this.getLabelFromValue(String(this.currValue)) || null;
|
|
1079
|
-
}
|
|
1080
|
-
}
|
|
1081
|
-
openChangedHandler() {
|
|
1082
|
-
this.open ? this.icOpen.emit() : this.icClose.emit();
|
|
1083
|
-
}
|
|
1084
|
-
disconnectedCallback() {
|
|
1085
|
-
var _a;
|
|
1086
|
-
removeFormResetListener(this.el, this.handleFormReset);
|
|
1087
|
-
(_a = this.hostMutationObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
|
|
1088
|
-
}
|
|
1089
|
-
componentWillLoad() {
|
|
1090
|
-
const valueInOptions = this.multiple
|
|
1091
|
-
? this.getMultipleOptionsString(this.value)
|
|
1092
|
-
: this.getLabelFromValue(this.value);
|
|
1093
|
-
this.currValue = valueInOptions ? this.value : null;
|
|
1094
|
-
this.inheritedAttributes = inheritAttributes(this.el, MUTABLE_ATTRIBUTES$1);
|
|
1095
|
-
removeDisabledFalse(this.disabled, this.el);
|
|
1096
|
-
this.setOptionsValuesFromLabels();
|
|
1097
|
-
addFormResetListener(this.el, this.handleFormReset);
|
|
1098
|
-
if (!this.options.length) {
|
|
1099
|
-
this.initialOptionsEmpty = true;
|
|
1100
|
-
this.noOptions = [{ label: this.emptyOptionListText, value: "" }];
|
|
1101
|
-
this.uniqueOptions = this.noOptions;
|
|
1102
|
-
this.filteredOptions = this.noOptions;
|
|
1103
|
-
}
|
|
1104
|
-
else {
|
|
1105
|
-
this.setDefaultValue();
|
|
1106
|
-
this.uniqueOptions = this.deduplicateOptions(this.options);
|
|
1107
|
-
}
|
|
1108
|
-
}
|
|
1109
|
-
componentDidLoad() {
|
|
1110
|
-
onComponentRequiredPropUndefined([{ prop: this.label, propName: "label" }], "Select");
|
|
1111
|
-
if (this.loading) {
|
|
1112
|
-
this.triggerLoading();
|
|
1113
|
-
}
|
|
1114
|
-
if (this.searchable) {
|
|
1115
|
-
this.hiddenInputValue = this.currValue;
|
|
1116
|
-
}
|
|
1117
|
-
this.hostMutationObserver = new MutationObserver(this.hostMutationCallback);
|
|
1118
|
-
this.hostMutationObserver.observe(this.el, {
|
|
1119
|
-
attributes: true,
|
|
1120
|
-
childList: true,
|
|
1121
|
-
});
|
|
1122
|
-
}
|
|
1123
|
-
componentDidRender() {
|
|
1124
|
-
if (this.nativeSelectElement && !this.disabled) {
|
|
1125
|
-
this.setTextColor();
|
|
1126
|
-
}
|
|
1127
|
-
}
|
|
1128
|
-
/**
|
|
1129
|
-
* Sets focus on the input box.
|
|
1130
|
-
*/
|
|
1131
|
-
async setFocus() {
|
|
1132
|
-
if (this.nativeSelectElement) {
|
|
1133
|
-
this.nativeSelectElement.focus();
|
|
1134
|
-
}
|
|
1135
|
-
else if (this.customSelectElement) {
|
|
1136
|
-
this.customSelectElement.focus();
|
|
1137
|
-
}
|
|
1138
|
-
else if (this.searchableSelectElement) {
|
|
1139
|
-
this.searchableSelectElement.focus();
|
|
1140
|
-
}
|
|
1141
|
-
}
|
|
1142
|
-
render() {
|
|
1143
|
-
var _a, _b, _c, _d;
|
|
1144
|
-
const { size, disabled, fullWidth, helperText, hideLabel, label, menuId, multiple, name, options, placeholder, readonly, required, searchable, showClearButton, validationAriaLive, validationStatus, validationText, currValue, theme, hiddenInputValue, open, inputId, searchableSelectInputValue, loading, value, emptyOptionListText, uniqueOptions, selectOnEnter, form, inheritedAttributes, ariaActiveDescendant, hasTimedOut, filteredOptions, clearButtonFocused, } = this;
|
|
1145
|
-
// HTML inputs only accept 'string' for their value
|
|
1146
|
-
// Does not cause errors when it is a multi-select - sets value correctly, to a comma-separated string
|
|
1147
|
-
renderHiddenInput(this.el, searchable ? hiddenInputValue : currValue, name || inputId, disabled);
|
|
1148
|
-
const invalid = `${validationStatus === IcInformationStatus.Error}`;
|
|
1149
|
-
const showValidation = hasValidationStatus(validationStatus, !!disabled);
|
|
1150
|
-
const describedBy = getInputDescribedByText(this.el, inputId, helperText !== "", showValidation).trim();
|
|
1151
|
-
const valueLabelString = multiple
|
|
1152
|
-
? this.getMultipleOptionsString(currValue)
|
|
1153
|
-
: this.getLabelFromValue(currValue);
|
|
1154
|
-
const isClearable = !disabled &&
|
|
1155
|
-
(searchable
|
|
1156
|
-
? !!searchableSelectInputValue
|
|
1157
|
-
: !!currValue && !loading && showClearButton);
|
|
1158
|
-
return (h(Host, { key: 'beb04e2fdc2db5765b24622f4d31bfdf36c61ba6', class: {
|
|
1159
|
-
"ic-select-disabled": disabled,
|
|
1160
|
-
"ic-select-searchable": searchable,
|
|
1161
|
-
[`ic-select-${size}`]: size !== "medium",
|
|
1162
|
-
"ic-select-full-width": fullWidth,
|
|
1163
|
-
[`ic-theme-${theme}`]: theme !== "inherit",
|
|
1164
|
-
}, onBlur: this.onBlur }, h("ic-input-container", { key: 'e85323a8778251dca9d78ccc76906c7523a8f02a', readonly: readonly }, !hideLabel && (h("ic-input-label", { key: '9bd3a6662c29157c323beee7355ec0983a0a83e9', for: inputId, label: label, helperText: helperText, required: required, disabled: disabled, readonly: readonly }, h("slot", { key: 'ba0fc93028a2ff25112730a950381a25bee23b54', name: "helper-text", slot: "helper-text" }))), h("ic-input-component-container", { key: 'c7d54f4d61bcb41cfbb3c4af1600a783e696121f', ref: (el) => (this.anchorEl = el), class: { "menu-open": open }, size: size, fullWidth: fullWidth, disabled: disabled, readonly: readonly, validationStatus: validationStatus }, isSlotUsed(this.el, "icon") &&
|
|
1165
|
-
!disabled &&
|
|
1166
|
-
(!readonly || !!value) && (h("span", { key: '891b11b3008d52ac3db2197c372b21a12a9f431e', slot: "left-icon", class: {
|
|
1167
|
-
readonly,
|
|
1168
|
-
"has-value": !!value,
|
|
1169
|
-
} }, h("slot", { key: '9fc291a9f0b756bf31331260ea3c313cdecf8fa2', name: "icon" }))), readonly ? (h("ic-typography", null, h("p", null, valueLabelString))) : isMobileOrTablet() && !multiple ? (h("select", Object.assign({ ref: (el) => (this.nativeSelectElement = el), disabled: disabled, onChange: this.handleNativeSelectChange, required: required, id: inputId, "aria-label": label, "aria-describedby": describedBy, "aria-invalid": invalid, onBlur: this.onBlur, onFocus: this.onFocus, onKeyDown: this.handleNativeSelectKeyDown, form: form }, inheritedAttributes), h("option", { value: "", selected: true, disabled: !showClearButton }, placeholder), options.map((option) => option.children ? (h("optgroup", { label: option.label }, option.children.map((child) => this.renderNativeOption(child)))) : (this.renderNativeOption(option))))) : searchable ? (h("div", { class: "searchable-select-container" }, h("input", { class: {
|
|
1170
|
-
"value-text": true,
|
|
1171
|
-
"select-input": true,
|
|
1172
|
-
"with-clear-button": !!searchableSelectInputValue,
|
|
1173
|
-
}, role: "combobox", autocomplete: "off", "aria-label": label, "aria-describedby": describedBy, "aria-activedescendant": ariaActiveDescendant, "aria-autocomplete": "list", "aria-expanded": `${open}`, "aria-invalid": invalid, "aria-required": `${required}`, "aria-controls": menuId, ref: (el) => (this.searchableSelectElement = el), id: inputId, value: searchableSelectInputValue || undefined, placeholder: placeholder, disabled: disabled, onInput: this.handleSearchableSelectInput, onClick: this.handleClick, onKeyDown: this.handleKeyDown, onFocus: this.onFocus, onBlur: this.onBlur, form: form }), isClearable && (h("div", { class: "clear-button-container" }, h("ic-button", { id: "clear-button", ref: (el) => (this.clearButton = el), "aria-label": searchableSelectInputValue &&
|
|
1174
|
-
(currValue === null || loading)
|
|
1175
|
-
? "Clear input"
|
|
1176
|
-
: "Clear selection", class: "clear-button", innerHTML: Clear, onClick: this.handleClear, onFocus: this.handleClearButtonFocus, onBlur: this.handleClearButtonBlur, size: size, variant: "icon-tertiary", theme: clearButtonFocused ? "light" : "dark" }), h("div", { class: "divider" }))), h("span", { onMouseDown: this.handleExpandIconMouseDown, class: {
|
|
1177
|
-
"expand-icon": true,
|
|
1178
|
-
"expand-icon-open": open,
|
|
1179
|
-
}, innerHTML: Expand, "aria-hidden": "true" }), h("div", { "aria-live": "polite", role: "status", class: "searchable-select-results-status" }))) : (h("div", { class: "select-container" }, h("button", { role: "combobox", class: "select-input", ref: (el) => (this.customSelectElement = el), id: inputId, "aria-label": `${label}, ${(multiple && currValue
|
|
1180
|
-
? `${currValue.length} of ${getOptionsWithoutGroupTitlesCount(options)} selected, ${valueLabelString}`
|
|
1181
|
-
: valueLabelString) || placeholder}`, "aria-describedby": describedBy, "aria-invalid": invalid, "aria-haspopup": "listbox", "aria-expanded": `${open}`, "aria-owns": menuId, "aria-controls": menuId, "aria-required": `${required}`, disabled: disabled, onBlur: this.onBlur, onFocus: this.onFocus, onClick: this.handleClick, onMouseDown: this.handleMouseDown, onKeyDown: this.handleKeyDown }, h("ic-typography", { variant: "body", class: {
|
|
1182
|
-
"value-text": true,
|
|
1183
|
-
"with-clear-button": isClearable,
|
|
1184
|
-
placeholder: !loading && multiple
|
|
1185
|
-
? !value || value.length < 1
|
|
1186
|
-
: !this.getLabelFromValue(currValue),
|
|
1187
|
-
} }, valueLabelString || placeholder), h("div", { class: "select-input-end" }, isClearable && h("div", { class: "divider" }), h("span", { class: {
|
|
1188
|
-
"expand-icon": true,
|
|
1189
|
-
"expand-icon-open": open,
|
|
1190
|
-
}, innerHTML: Expand, "aria-hidden": "true" }))), isClearable && (h("ic-button", { id: "clear-button", "aria-label": "Clear selection", class: "clear-button", innerHTML: Clear, onClick: this.handleClear, onFocus: this.handleClearButtonFocus, onBlur: this.handleClearButtonBlur, size: size, variant: "icon-tertiary", theme: clearButtonFocused ? "light" : "dark" }))))), (!isMobileOrTablet() || multiple) && (h("ic-menu", { key: 'b56cf5adc26838ad0f873aa16df8da7fd7b83d22', class: {
|
|
1191
|
-
"no-results": loading ||
|
|
1192
|
-
hasTimedOut ||
|
|
1193
|
-
(searchable &&
|
|
1194
|
-
((_b = (_a = this.filteredOptions) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.label) === emptyOptionListText) ||
|
|
1195
|
-
(!searchable &&
|
|
1196
|
-
((_d = (_c = this.uniqueOptions) === null || _c === void 0 ? void 0 : _c[0]) === null || _d === void 0 ? void 0 : _d.label) === emptyOptionListText),
|
|
1197
|
-
}, ref: (el) => (this.menu = el), inputEl: searchable
|
|
1198
|
-
? this.searchableSelectElement
|
|
1199
|
-
: this.customSelectElement, inputLabel: label, anchorEl: this.anchorEl, size: size, menuId: menuId, open: open, options: searchable ? filteredOptions : uniqueOptions, value: multiple ? currValue : currValue, fullWidth: fullWidth, selectOnEnter: selectOnEnter, onMenuStateChange: this.handleMenuChange, onMenuOptionSelect: this.handleCustomSelectChange, onMenuOptionSelectAll: this.handleSelectAllChange, onMenuKeyPress: this.handleMenuKeyPress, onUngroupedOptionsSet: this.setUngroupedOptions, onRetryButtonClicked: this.handleRetry, parentEl: this.el, onTimeoutBlur: this.onTimeoutBlur, activationType: searchable || multiple || selectOnEnter ? "manual" : "automatic", closeOnSelect: !multiple, multiSelect: multiple ? true : false, searchableSelect: searchable ? true : false })), multiple && (h("div", { key: 'c4e7606e119c8658e590716ff02dcaf45f30ae89', "aria-live": "polite", role: "status", class: "multi-select-selected-count" })), h("ic-input-validation", { key: 'b74ff136f8b758c400d9c0262a227f2286b301d5', class: {
|
|
1200
|
-
"menu-open": open,
|
|
1201
|
-
}, ariaLiveMode: validationAriaLive, status: showValidation ? validationStatus : "", message: showValidation ? validationText : "", for: inputId }))));
|
|
1202
|
-
}
|
|
1203
|
-
static get delegatesFocus() { return true; }
|
|
1204
|
-
get el() { return getElement(this); }
|
|
1205
|
-
static get watchers() { return {
|
|
1206
|
-
"disabled": ["watchDisabledHandler"],
|
|
1207
|
-
"loading": ["loadingHandler"],
|
|
1208
|
-
"options": ["watchOptionsHandler"],
|
|
1209
|
-
"debounce": ["debounceChangedHandler"],
|
|
1210
|
-
"value": ["valueChangedHandler"],
|
|
1211
|
-
"open": ["openChangedHandler"]
|
|
1212
|
-
}; }
|
|
1213
|
-
};
|
|
1214
|
-
Select.style = IcSelectStyle0;
|
|
1215
|
-
|
|
1216
|
-
const icTextFieldCss = "/*! 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-input-label-helpertext-padding:var(--ic-space-xs);--border-color:var(--ic-text-field-border-neutral);--border-color-hover:var(--ic-text-field-border-neutral-hover);--border-color-pressed:var(--ic-text-field-border-neutral-pressed);--border-color-disabled:var(--ic-text-field-border-disabled);--border-color-error:var(--ic-text-field-border-error);--border-color-error-hover:var(--ic-text-field-border-error-hover);--border-color-error-pressed:var(--ic-text-field-border-error-pressed);--border-color-success:var(--ic-text-field-border-success);--border-color-success-hover:var(--ic-text-field-border-success-hover);--border-color-success-pressed:var(--ic-text-field-border-success-pressed);--border-color-warning:var(--ic-text-field-border-warning);--border-color-warning-hover:var(--ic-text-field-border-warning-hover);--border-color-warning-pressed:var(--ic-text-field-border-warning-pressed);--ic-input-label-text-color:var(--ic-text-field-label);--ic-input-label-helper-text-color:var(--ic-text-field-subtitle);--ic-input-validation-status-text-color:var(--ic-text-field-state-text);--ic-input-validation-error:var(--ic-text-field-state-icon-error);--ic-input-validation-warning-icon-color:var(\n --ic-text-field-state-icon-warning\n );--ic-input-validation-success-icon-color:var(\n --ic-text-field-state-icon-success\n );--ic-input-component-container-success-icon-inline-color:var(\n --ic-text-field-state-icon-success\n )}:host(.ic-text-field-disabled){--ic-input-label-text-color:var(--ic-text-field-label-disabled);--ic-input-label-helper-text-color:var(--ic-text-field-subtitle-disabled);--text-field-placeholder-color:var(\n --ic-text-field-text-area-placeholder-text-disabled\n )}:host(.ic-text-field-full-width){width:100%}::-moz-placeholder{color:var(\n --text-field-placeholder-color,\n var(--ic-text-field-placeholder-text)\n );opacity:1}::placeholder{color:var(\n --text-field-placeholder-color,\n var(--ic-text-field-placeholder-text)\n );opacity:1}input,textarea{border:0;border-radius:var(--ic-border-radius);color:var(--text-field-text-color, var(--ic-text-field-text));background-color:var(--input-bg-color, var(--ic-text-field-background));line-height:1.5rem;letter-spacing:0.005rem;width:100%;padding-right:var(--ic-space-xs);padding-left:var(--ic-space-xs);caret-color:var(\n --text-field-typing-cursor,\n var(--ic-text-field-typing-cursor)\n )}textarea{min-height:var(--ic-space-lg);resize:vertical;padding-top:0.375rem}input:focus,textarea:focus{border:0;outline:0}input:disabled,textarea:disabled{color:var(\n --text-field-disabled-text-color,\n var(--ic-text-field-text-disabled)\n )}input.readonly,textarea.readonly{color:var(--ic-text-field-read-only-input-text-internal);background:transparent}input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}input[type=\"number\"]{-moz-appearance:textfield}textarea.no-resize{resize:none}.char-count-text{--ic-typography-color:var(--ic-text-field-character-limit);padding-right:var(--ic-space-xxxs)}:host(.ic-text-field-disabled) .char-count-text{--ic-typography-color:var(--ic-text-field-character-limit-disabled)}.no-left-pad{padding-left:0}::slotted([slot=\"icon\"]){fill:var(--ic-text-field-text-disabled)}.has-value ::slotted([slot=\"icon\"]){fill:var(--ic-text-field-input-internal-icon)}.char-count{margin-right:calc(-1 * var(--ic-space-xxxs))}.remaining-char-count-desc{position:absolute;left:-9999px}.show-validation{margin-top:var(--ic-space-xs)}input[type=\"search\"]::-webkit-search-cancel-button,input[type=\"search\"]::-webkit-search-decoration,input[type=\"search\"]::-webkit-search-results-button,input[type=\"search\"]::-webkit-search-results-decoration{display:none}input[type=\"search\"].truncate-value{width:100%;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}@media (forced-colors: active){input.readonly,textarea.readonly{color:canvastext}.has-value ::slotted([slot=\"icon\"]){fill:currentcolor}}";
|
|
1217
|
-
const IcTextFieldStyle0 = icTextFieldCss;
|
|
1218
|
-
|
|
1219
|
-
let inputIds = 0;
|
|
1220
|
-
const MUTABLE_ATTRIBUTES = [...IC_INHERITED_ARIA, "title"];
|
|
1221
|
-
const TextField = class {
|
|
1222
|
-
constructor(hostRef) {
|
|
1223
|
-
registerInstance(this, hostRef);
|
|
1224
|
-
this.getValidationText = createEvent(this, "getValidationText", 7);
|
|
1225
|
-
this.icBlur = createEvent(this, "icBlur", 7);
|
|
1226
|
-
this.icChange = createEvent(this, "icChange", 7);
|
|
1227
|
-
this.icFocus = createEvent(this, "icFocus", 7);
|
|
1228
|
-
this.icInput = createEvent(this, "icInput", 7);
|
|
1229
|
-
this.icKeydown = createEvent(this, "icKeydown", 7);
|
|
1230
|
-
this.icScroll = createEvent(this, "icScroll", 7);
|
|
1231
|
-
this.inheritedAttributes = {};
|
|
1232
|
-
this.hostMutationObserver = null;
|
|
1233
|
-
this.numChars = 0;
|
|
1234
|
-
this.maxCharactersReached = false;
|
|
1235
|
-
this.maxCharactersWarning = false;
|
|
1236
|
-
this.minCharactersUnattained = false;
|
|
1237
|
-
this.maxValueExceeded = false;
|
|
1238
|
-
this.minValueUnattained = false;
|
|
1239
|
-
this.isFocussed = false;
|
|
1240
|
-
/**
|
|
1241
|
-
* The automatic capitalisation of the text value as it is entered/edited by the user.
|
|
1242
|
-
* Available options: "off", "none", "on", "sentences", "words", "characters".
|
|
1243
|
-
*/
|
|
1244
|
-
this.autocapitalize = "off";
|
|
1245
|
-
/**
|
|
1246
|
-
* The state of autocompletion the browser can apply on the text value.
|
|
1247
|
-
*/
|
|
1248
|
-
this.autocomplete = "off";
|
|
1249
|
-
/**
|
|
1250
|
-
* The state of autocorrection the browser can apply when the user is entering/editing the text value.
|
|
1251
|
-
*/
|
|
1252
|
-
this.autocorrect = "off";
|
|
1253
|
-
/**
|
|
1254
|
-
* If `true`, the form control will have input focus when the page loads.
|
|
1255
|
-
*/
|
|
1256
|
-
this.autofocus = false;
|
|
1257
|
-
/**
|
|
1258
|
-
* If `true`, the disabled state will be set.
|
|
1259
|
-
*/
|
|
1260
|
-
this.disabled = false;
|
|
1261
|
-
/**
|
|
1262
|
-
* Specify whether the text field fills the full width of the container.
|
|
1263
|
-
* If `true`, this overrides the --input-width CSS variable.
|
|
1264
|
-
*/
|
|
1265
|
-
this.fullWidth = false;
|
|
1266
|
-
/**
|
|
1267
|
-
* The helper text that will be displayed for additional field guidance.
|
|
1268
|
-
*/
|
|
1269
|
-
this.helperText = "";
|
|
1270
|
-
/**
|
|
1271
|
-
* If `true`, the character count which is displayed when `maxCharacters` is set will be visually hidden.
|
|
1272
|
-
*/
|
|
1273
|
-
this.hideCharCount = false;
|
|
1274
|
-
/**
|
|
1275
|
-
* If `true`, the label will be hidden and the required label value will be applied as an aria-label.
|
|
1276
|
-
*/
|
|
1277
|
-
this.hideLabel = false;
|
|
1278
|
-
/**
|
|
1279
|
-
* @internal If `true`, the hidden form input will stop rendering for form submission.
|
|
1280
|
-
*/
|
|
1281
|
-
this.hiddenInput = true;
|
|
1282
|
-
/**
|
|
1283
|
-
* The ID for the input.
|
|
1284
|
-
*/
|
|
1285
|
-
this.inputId = `ic-text-field-input-${inputIds++}`;
|
|
1286
|
-
/**
|
|
1287
|
-
* A hint to the browser for which keyboard to display.
|
|
1288
|
-
* Possible values: `"none"`, `"text"`, `"tel"`, `"url"`,
|
|
1289
|
-
* `"email"`, `"numeric"`, `"decimal"`, and `"search"`.
|
|
1290
|
-
*/
|
|
1291
|
-
this.inputmode = "text";
|
|
1292
|
-
/**
|
|
1293
|
-
* The count of characters in the field. Will display a warning if the bound is reached. (NOTE: If the value of the text field has been set using the `value` prop, it will be truncated to this number of characters)
|
|
1294
|
-
*/
|
|
1295
|
-
this.maxCharacters = 0;
|
|
1296
|
-
/**
|
|
1297
|
-
* The text to display as the warning message when the maximum number of characters (the `maxCharacters` prop value) is reached.
|
|
1298
|
-
*/
|
|
1299
|
-
// prettier-ignore
|
|
1300
|
-
this.maxCharactersMessage = `Maximum input is ${this.maxCharacters} characters`;
|
|
1301
|
-
/**
|
|
1302
|
-
* The text to display as the error message when the maximum value (the `max` prop value) has been exceeded.
|
|
1303
|
-
*/
|
|
1304
|
-
this.maxMessage = `Maximum value of ${this.max} exceeded`;
|
|
1305
|
-
/**
|
|
1306
|
-
* The minimum number of characters that can be entered in the field.
|
|
1307
|
-
*/
|
|
1308
|
-
this.minCharacters = 0;
|
|
1309
|
-
/**
|
|
1310
|
-
* The text to display as the error message when the minimum number of characters (the `minCharacters` prop value) has not been met.
|
|
1311
|
-
*/
|
|
1312
|
-
// prettier-ignore
|
|
1313
|
-
this.minCharactersMessage = `Minimum input is ${this.minCharacters} characters`;
|
|
1314
|
-
/**
|
|
1315
|
-
* The text to display as the error message when the minimum value (the `min` prop value) has not been met.
|
|
1316
|
-
*/
|
|
1317
|
-
this.minMessage = `Minimum value of ${this.min} not met`;
|
|
1318
|
-
/**
|
|
1319
|
-
* The name of the control, which is submitted with the form data.
|
|
1320
|
-
*/
|
|
1321
|
-
this.name = this.inputId;
|
|
1322
|
-
/**
|
|
1323
|
-
* The placeholder value to be displayed.
|
|
1324
|
-
*/
|
|
1325
|
-
this.placeholder = "";
|
|
1326
|
-
/**
|
|
1327
|
-
* If `true`, the read only state will be set.
|
|
1328
|
-
*/
|
|
1329
|
-
this.readonly = false;
|
|
1330
|
-
/**
|
|
1331
|
-
* If `true`, the input will require a value.
|
|
1332
|
-
*/
|
|
1333
|
-
this.required = false;
|
|
1334
|
-
/**
|
|
1335
|
-
* If `true`, the multiline text area will be resizeable.
|
|
1336
|
-
*/
|
|
1337
|
-
this.resize = false;
|
|
1338
|
-
/**
|
|
1339
|
-
* The number of rows to transform the text field into a text area with a specific height.
|
|
1340
|
-
*/
|
|
1341
|
-
this.rows = 1;
|
|
1342
|
-
/**
|
|
1343
|
-
* The size of the text field component.
|
|
1344
|
-
*/
|
|
1345
|
-
this.size = "medium";
|
|
1346
|
-
/**
|
|
1347
|
-
* If `true`, the value of the text field will have its spelling and grammar checked.
|
|
1348
|
-
*/
|
|
1349
|
-
this.spellcheck = false;
|
|
1350
|
-
/**
|
|
1351
|
-
* 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.
|
|
1352
|
-
*/
|
|
1353
|
-
this.theme = "inherit";
|
|
1354
|
-
/**
|
|
1355
|
-
* @internal If `true`, an ellipsis will be displayed at the end of the value if the value is longer than the container.
|
|
1356
|
-
*/
|
|
1357
|
-
this.truncateValue = false;
|
|
1358
|
-
/**
|
|
1359
|
-
* The type of control to display. The default type is text.
|
|
1360
|
-
*/
|
|
1361
|
-
this.type = "text";
|
|
1362
|
-
/**
|
|
1363
|
-
* The value of the `aria-live` attribute on the validation message. When set to "default", the `aria-live` value will be handled automatically, e.g. "assertive" for `validation-status="error"`.
|
|
1364
|
-
*/
|
|
1365
|
-
this.validationAriaLive = "default";
|
|
1366
|
-
/**
|
|
1367
|
-
* If `true`, the icon in input control will be displayed - only applies when validationStatus ='success'.
|
|
1368
|
-
*/
|
|
1369
|
-
this.validationInline = false;
|
|
1370
|
-
/**
|
|
1371
|
-
* @internal If `true`, the validation will display inline.
|
|
1372
|
-
*/
|
|
1373
|
-
this.validationInlineInternal = false;
|
|
1374
|
-
/**
|
|
1375
|
-
* The validation state - e.g. 'error' | 'warning' | 'success'.
|
|
1376
|
-
*/
|
|
1377
|
-
this.validationStatus = "";
|
|
1378
|
-
/**
|
|
1379
|
-
* The text to display as the validation message.
|
|
1380
|
-
*/
|
|
1381
|
-
this.validationText = "";
|
|
1382
|
-
/**
|
|
1383
|
-
* The amount of time, in milliseconds, to wait to trigger the `icChange` event after each keystroke.
|
|
1384
|
-
*/
|
|
1385
|
-
this.debounce = 0;
|
|
1386
|
-
/**
|
|
1387
|
-
* The value of the text field.
|
|
1388
|
-
*/
|
|
1389
|
-
this.value = "";
|
|
1390
|
-
this.initialValue = this.value;
|
|
1391
|
-
this.checkChildHydration = () => {
|
|
1392
|
-
var _a, _b;
|
|
1393
|
-
if (this.hideLabel ||
|
|
1394
|
-
((_b = (_a = this.el.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector("ic-typography")) === null || _b === void 0 ? void 0 : _b.classList.contains("hydrated"))) {
|
|
1395
|
-
this.setFocus();
|
|
1396
|
-
clearInterval(this.interval);
|
|
1397
|
-
}
|
|
1398
|
-
};
|
|
1399
|
-
this.getNumberOfCharacters = (value) => value !== null && value !== undefined ? value.length : 0;
|
|
1400
|
-
this.getMaxValueExceeded = (value) => {
|
|
1401
|
-
this.numChars = this.getNumberOfCharacters(value);
|
|
1402
|
-
if (this.type === "number") {
|
|
1403
|
-
this.minValueUnattained = !!value && Number(value) < Number(this.min);
|
|
1404
|
-
this.maxValueExceeded = Number(value) > Number(this.max);
|
|
1405
|
-
}
|
|
1406
|
-
};
|
|
1407
|
-
this.getMaxCharactersReached = (value) => {
|
|
1408
|
-
this.numChars = this.getNumberOfCharacters(value);
|
|
1409
|
-
this.maxCharactersReached =
|
|
1410
|
-
this.maxCharacters > 0 && this.numChars >= this.maxCharacters;
|
|
1411
|
-
if (this.maxCharactersWarning && !this.maxCharactersReached) {
|
|
1412
|
-
this.maxCharactersWarning = false;
|
|
1413
|
-
}
|
|
1414
|
-
};
|
|
1415
|
-
this.onInput = (ev) => {
|
|
1416
|
-
this.value = ev.target.value;
|
|
1417
|
-
this.icInput.emit({ value: this.value });
|
|
1418
|
-
};
|
|
1419
|
-
this.onBlur = (ev) => {
|
|
1420
|
-
const target = ev.target;
|
|
1421
|
-
target.removeEventListener("wheel", this.onWheel);
|
|
1422
|
-
const { value } = target;
|
|
1423
|
-
this.numChars = value.length;
|
|
1424
|
-
this.minCharactersUnattained =
|
|
1425
|
-
this.minCharacters > 0 && this.numChars < this.minCharacters;
|
|
1426
|
-
this.icBlur.emit({ value });
|
|
1427
|
-
this.isFocussed = false;
|
|
1428
|
-
};
|
|
1429
|
-
this.onFocus = (ev) => {
|
|
1430
|
-
const target = ev.target;
|
|
1431
|
-
target.addEventListener("wheel", this.onWheel);
|
|
1432
|
-
this.icFocus.emit({ value: target.value });
|
|
1433
|
-
this.isFocussed = true;
|
|
1434
|
-
};
|
|
1435
|
-
this.onTextAreaScroll = () => {
|
|
1436
|
-
this.icScroll.emit();
|
|
1437
|
-
};
|
|
1438
|
-
this.onWheel = (ev) => {
|
|
1439
|
-
const target = ev.target;
|
|
1440
|
-
if (target.type === "number") {
|
|
1441
|
-
target.blur();
|
|
1442
|
-
setTimeout(() => {
|
|
1443
|
-
target.focus();
|
|
1444
|
-
}, 0);
|
|
1445
|
-
}
|
|
1446
|
-
};
|
|
1447
|
-
this.hasStatus = (status) => status !== "" && !this.disabled;
|
|
1448
|
-
this.handleFormReset = () => {
|
|
1449
|
-
this.value = this.initialValue;
|
|
1450
|
-
};
|
|
1451
|
-
this.showValidationMargin = () => {
|
|
1452
|
-
const maxNumChars = this.readonly ? 0 : this.maxCharacters;
|
|
1453
|
-
const emptyString = isEmptyString(this.validationStatus) ||
|
|
1454
|
-
isEmptyString(this.validationText);
|
|
1455
|
-
const valueOutsideRange = this.minValueUnattained || this.maxValueExceeded;
|
|
1456
|
-
const charsOutsideRange = maxNumChars > 0 || this.minCharactersUnattained;
|
|
1457
|
-
return ((!emptyString || valueOutsideRange || charsOutsideRange) &&
|
|
1458
|
-
!this.validationInlineInternal);
|
|
1459
|
-
};
|
|
1460
|
-
// triggered when attributes of host element change
|
|
1461
|
-
this.hostMutationCallback = (mutationList) => {
|
|
1462
|
-
let forceComponentUpdate = false;
|
|
1463
|
-
mutationList.forEach(({ attributeName, type, addedNodes, removedNodes }) => {
|
|
1464
|
-
if (attributeName && MUTABLE_ATTRIBUTES.includes(attributeName)) {
|
|
1465
|
-
const attribute = this.el.getAttribute(attributeName);
|
|
1466
|
-
if (attribute) {
|
|
1467
|
-
this.inheritedAttributes[attributeName] = attribute;
|
|
1468
|
-
}
|
|
1469
|
-
forceComponentUpdate = true;
|
|
1470
|
-
}
|
|
1471
|
-
else if (type === "childList") {
|
|
1472
|
-
forceComponentUpdate = checkSlotInChildMutations(addedNodes, removedNodes, "icon");
|
|
1473
|
-
}
|
|
1474
|
-
});
|
|
1475
|
-
if (forceComponentUpdate) {
|
|
1476
|
-
forceUpdate(this);
|
|
1477
|
-
}
|
|
1478
|
-
};
|
|
1479
|
-
}
|
|
1480
|
-
watchDisabledHandler() {
|
|
1481
|
-
removeDisabledFalse(this.disabled, this.el);
|
|
1482
|
-
}
|
|
1483
|
-
debounceChanged() {
|
|
1484
|
-
this.icChange = debounceEvent(this.icChange, this.debounce);
|
|
1485
|
-
}
|
|
1486
|
-
watchValueHandler(newValue) {
|
|
1487
|
-
let value;
|
|
1488
|
-
if (this.maxCharacters > 0) {
|
|
1489
|
-
value = newValue.substring(0, this.maxCharacters);
|
|
1490
|
-
if (value.length < newValue.length) {
|
|
1491
|
-
this.maxCharactersWarning = true;
|
|
1492
|
-
}
|
|
1493
|
-
this.value = value;
|
|
1494
|
-
}
|
|
1495
|
-
else {
|
|
1496
|
-
value = newValue;
|
|
1497
|
-
}
|
|
1498
|
-
if (this.inputEl && this.inputEl.value !== value) {
|
|
1499
|
-
this.inputEl.value = value;
|
|
1500
|
-
}
|
|
1501
|
-
this.getMaxValueExceeded(value);
|
|
1502
|
-
this.getMaxCharactersReached(value);
|
|
1503
|
-
this.icChange.emit({ value });
|
|
1504
|
-
}
|
|
1505
|
-
connectedCallback() {
|
|
1506
|
-
this.debounceChanged();
|
|
1507
|
-
}
|
|
1508
|
-
disconnectedCallback() {
|
|
1509
|
-
var _a;
|
|
1510
|
-
removeFormResetListener(this.el, this.handleFormReset);
|
|
1511
|
-
(_a = this.hostMutationObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
|
|
1512
|
-
}
|
|
1513
|
-
componentWillLoad() {
|
|
1514
|
-
if (this.value !== this.initialValue) {
|
|
1515
|
-
this.watchValueHandler(this.value);
|
|
1516
|
-
}
|
|
1517
|
-
else if (this.maxCharacters > 0) {
|
|
1518
|
-
this.value = this.value.substring(0, this.maxCharacters);
|
|
1519
|
-
}
|
|
1520
|
-
this.getMaxValueExceeded(this.value);
|
|
1521
|
-
this.getMaxCharactersReached(this.value);
|
|
1522
|
-
this.inheritedAttributes = inheritAttributes(this.el, MUTABLE_ATTRIBUTES);
|
|
1523
|
-
if (this.readonly) {
|
|
1524
|
-
this.maxValueExceeded = false;
|
|
1525
|
-
this.minValueUnattained = false;
|
|
1526
|
-
}
|
|
1527
|
-
addFormResetListener(this.el, this.handleFormReset);
|
|
1528
|
-
removeDisabledFalse(this.disabled, this.el);
|
|
1529
|
-
}
|
|
1530
|
-
componentDidLoad() {
|
|
1531
|
-
onComponentRequiredPropUndefined([{ prop: this.label, propName: "label" }], "Text Field");
|
|
1532
|
-
if (this.validationInlineInternal) {
|
|
1533
|
-
this.getValidationText.emit({ value: this.validationText });
|
|
1534
|
-
}
|
|
1535
|
-
this.hostMutationObserver = new MutationObserver(this.hostMutationCallback);
|
|
1536
|
-
this.hostMutationObserver.observe(this.el, {
|
|
1537
|
-
attributes: true,
|
|
1538
|
-
childList: true,
|
|
1539
|
-
});
|
|
1540
|
-
if (this.autofocus && !this.disabled && !this.readonly) {
|
|
1541
|
-
this.interval = setInterval(this.checkChildHydration, 50);
|
|
1542
|
-
}
|
|
1543
|
-
}
|
|
1544
|
-
handleKeyDown(ev) {
|
|
1545
|
-
var _a, _b;
|
|
1546
|
-
this.icKeydown.emit({
|
|
1547
|
-
event: ev,
|
|
1548
|
-
cursorPosition: (_a = this.inputEl.selectionStart) !== null && _a !== void 0 ? _a : 0,
|
|
1549
|
-
selectionEnd: (_b = this.inputEl.selectionEnd) !== null && _b !== void 0 ? _b : 0,
|
|
1550
|
-
});
|
|
1551
|
-
if (!ev.ctrlKey && !IGNORED_KEYBOARD_CHARACTERS.includes(ev.key)) {
|
|
1552
|
-
this.maxCharactersWarning = this.maxCharactersReached;
|
|
1553
|
-
}
|
|
1554
|
-
}
|
|
1555
|
-
/**
|
|
1556
|
-
* Sets focus on the native `input`.
|
|
1557
|
-
*/
|
|
1558
|
-
async setFocus() {
|
|
1559
|
-
var _a;
|
|
1560
|
-
(_a = this.inputEl) === null || _a === void 0 ? void 0 : _a.focus();
|
|
1561
|
-
}
|
|
1562
|
-
render() {
|
|
1563
|
-
const { inputId, name, label, required, size, placeholder, helperText, hideCharCount, rows, resize, disabled, value, min, max, numChars, readonly, maxCharacters, maxCharactersMessage, maxCharactersWarning, maxCharactersReached, maxMessage, minCharacters, minCharactersMessage, minCharactersUnattained, minMessage, minValueUnattained, maxValueExceeded, validationAriaLive, validationStatus, validationText, validationInline, validationInlineInternal, spellcheck, inputmode, fullWidth, truncateValue, hiddenInput, theme, hideLabel, type, autocapitalize, ariaActiveDescendant, inheritedAttributes, ariaExpanded, ariaOwns, autocomplete, role, isFocussed, } = this;
|
|
1564
|
-
const el = this.el;
|
|
1565
|
-
const disabledMode = readonly || disabled;
|
|
1566
|
-
const currentStatus = maxValueExceeded ||
|
|
1567
|
-
minValueUnattained ||
|
|
1568
|
-
minCharactersUnattained ||
|
|
1569
|
-
maxCharactersWarning
|
|
1570
|
-
? maxCharactersWarning
|
|
1571
|
-
? IcInformationStatus.Warning
|
|
1572
|
-
: IcInformationStatus.Error
|
|
1573
|
-
: validationStatus;
|
|
1574
|
-
const currentValidationText = maxCharactersWarning
|
|
1575
|
-
? maxCharactersMessage
|
|
1576
|
-
: maxValueExceeded
|
|
1577
|
-
? maxMessage
|
|
1578
|
-
: minValueUnattained
|
|
1579
|
-
? minMessage
|
|
1580
|
-
: minCharactersUnattained
|
|
1581
|
-
? minCharactersMessage
|
|
1582
|
-
: validationText;
|
|
1583
|
-
const maxNumChars = readonly ? 0 : maxCharacters;
|
|
1584
|
-
const messageAriaLive = validationAriaLive === "default"
|
|
1585
|
-
? maxCharactersWarning ||
|
|
1586
|
-
maxValueExceeded ||
|
|
1587
|
-
minValueUnattained ||
|
|
1588
|
-
currentStatus === IcInformationStatus.Error
|
|
1589
|
-
? "assertive"
|
|
1590
|
-
: "polite"
|
|
1591
|
-
: validationAriaLive;
|
|
1592
|
-
const showStatusText = this.hasStatus(currentStatus) &&
|
|
1593
|
-
!(currentStatus == IcInformationStatus.Success && validationInline) &&
|
|
1594
|
-
!validationInlineInternal;
|
|
1595
|
-
const multiline = rows > 1;
|
|
1596
|
-
const hiddenCharCountDescId = maxCharacters > 0 ? `${inputId}-char-count-desc` : "";
|
|
1597
|
-
const charsRemaining = maxNumChars - numChars;
|
|
1598
|
-
const remainingCharCountDescId = maxCharacters > 0 ? `${inputId}-remaining-char-count-desc` : "";
|
|
1599
|
-
const remainingCharCountDesc = `${charsRemaining} character${charsRemaining === 1 ? "" : "s"} remaining.`;
|
|
1600
|
-
const describedBy = `${getInputDescribedByText(this.el, inputId, helperText !== "", showStatusText)} ${hiddenCharCountDescId} ${numChars > 0 ? remainingCharCountDescId : ""}`.trim();
|
|
1601
|
-
const disabledText = disabledMode && !readonly;
|
|
1602
|
-
const showLeftIcon = !!this.el.querySelector(`[slot="icon"]`) && !disabledText;
|
|
1603
|
-
const invalid = `${currentStatus === IcInformationStatus.Error}`;
|
|
1604
|
-
hiddenInput
|
|
1605
|
-
? renderHiddenInput(this.el, value, name, disabledMode)
|
|
1606
|
-
: removeHiddenInput(this.el);
|
|
1607
|
-
return (h(Host, { key: '4a38a5d8bd42f37b2ab1e9f3af485695b6185a8a', class: {
|
|
1608
|
-
"ic-text-field-full-width": fullWidth,
|
|
1609
|
-
"ic-text-field-disabled": disabledMode,
|
|
1610
|
-
[`ic-theme-${theme}`]: theme !== "inherit",
|
|
1611
|
-
} }, h("ic-input-container", { key: 'a7da6f94bac334322b00b223cfb3462d026fbba1', readonly: readonly, disabled: disabledMode }, !hideLabel && (h("ic-input-label", { key: '97a5cc41a79cfc56c3e8e309154cbcc015bbadad', for: inputId, label: label, helperText: helperText, required: required, disabled: disabledText, readonly: readonly }, h("slot", { key: 'd9994cb1bb7218712bbed976057a3ca8d9ad3c2b', name: "helper-text", slot: "helper-text" }))), h("ic-input-component-container", { key: '0d3a988b563b2f9f2033b52a75f4fd5e27056ba8', size: size, validationStatus: currentStatus, multiLine: multiline, disabled: disabledMode, readonly: readonly, validationInline: validationInline, fullWidth: fullWidth }, showLeftIcon && (h("span", { key: '319fa22903ab0b2c2315377abb9f9e7bad15f221', class: {
|
|
1612
|
-
readonly,
|
|
1613
|
-
"has-value": this.getNumberOfCharacters(value) > 0,
|
|
1614
|
-
}, slot: "left-icon" }, h("slot", { key: '1224a807133d300df0a6070c998260ece29e8c80', name: "icon" }))), !multiline ? (h("input", Object.assign({ id: inputId, name: name, ref: (el) => (this.inputEl = el), type: type, min: min, max: max, value: value, class: {
|
|
1615
|
-
"no-left-pad": !showLeftIcon && readonly,
|
|
1616
|
-
readonly,
|
|
1617
|
-
"truncate-value": truncateValue,
|
|
1618
|
-
}, placeholder: placeholder ? placeholder : "", required: required, disabled: disabledMode, readonly: readonly, onInput: this.onInput, onBlur: this.onBlur, onFocus: this.onFocus, "aria-label": label, "aria-describedby": describedBy, "aria-invalid": invalid, "aria-activedescendant": ariaActiveDescendant, "aria-expanded": ariaExpanded, "aria-owns": ariaOwns, autocomplete: autocomplete, autocapitalize: autocapitalize, spellcheck: spellcheck, inputmode: inputmode, role: role || undefined, maxlength: maxCharactersReached ? maxCharacters : undefined, minlength: minCharactersUnattained ? minCharacters : undefined }, inheritedAttributes))) : (h("textarea", Object.assign({ id: inputId, class: {
|
|
1619
|
-
"no-resize": resize === false || !!readonly,
|
|
1620
|
-
"no-left-pad": !showLeftIcon && !!readonly,
|
|
1621
|
-
readonly: !!readonly,
|
|
1622
|
-
}, name: name, ref: (el) => (this.inputEl = el), value: value, rows: rows, required: required, disabled: disabledMode, placeholder: placeholder, readonly: readonly, onInput: this.onInput, onBlur: this.onBlur, onFocus: this.onFocus, onScroll: this.onTextAreaScroll, "aria-label": label, "aria-describedby": describedBy, "aria-invalid": invalid, autocomplete: autocomplete, autocapitalize: autocapitalize, spellcheck: spellcheck, inputmode: inputmode, maxlength: maxCharactersReached ? maxCharacters : undefined, minlength: minCharactersUnattained ? minCharacters : undefined }, inheritedAttributes))), isSlotUsed(el, "clear-button") && (h("slot", { key: 'e50c8194546e08898e7ef0ed4dd940a881ffd5c4', name: "clear-button" })), isSlotUsed(el, "search-submit-button") && (h("slot", { key: 'e2ba7a0f555593f767ff1c93c4c58b71967da1a7', name: "search-submit-button" }))), isSlotUsed(el, "menu") && h("slot", { key: '7b22fe423951f0f38c5419ff3c35e9f32a72735d', name: "menu" }), h("ic-input-validation", { key: '85aec8ebd4633fa36585e3253e1cc8107c374495', class: { "show-validation": this.showValidationMargin() }, status: this.hasStatus(currentStatus) === false ||
|
|
1623
|
-
(currentStatus === IcInformationStatus.Success &&
|
|
1624
|
-
validationInline) ||
|
|
1625
|
-
validationInlineInternal
|
|
1626
|
-
? ""
|
|
1627
|
-
: currentStatus, message: showStatusText ? currentValidationText : "", ariaLiveMode: messageAriaLive, for: inputId, fullWidth: fullWidth }, !readonly && maxNumChars > 0 && (h("div", { key: 'f857927758c96f735592e7af679dba91c333fbf1', slot: "validation-message-adornment" }, !hideCharCount && (h("ic-typography", { key: 'eed01e87433155c8311c5ef958145d484c65264a', variant: "caption", class: "char-count-text" }, h("span", { key: '1752a0a453ed7dd28b909029f847330ffbff406c', class: "char-count" }, numChars, "/", maxNumChars))), h("span", { key: 'cd708a611a6133a7cf3b892d8f83cbf592791907', class: "remaining-char-count-desc", "aria-live": "polite", hidden: !isFocussed, id: remainingCharCountDescId }, remainingCharCountDesc), h("span", { key: 'ebe5600dece8662d9966667308e79872793b098c', hidden: true, id: hiddenCharCountDescId }, "Field can contain a maximum of ", maxNumChars, " characters.")))))));
|
|
1628
|
-
}
|
|
1629
|
-
get el() { return getElement(this); }
|
|
1630
|
-
static get watchers() { return {
|
|
1631
|
-
"disabled": ["watchDisabledHandler"],
|
|
1632
|
-
"debounce": ["debounceChanged"],
|
|
1633
|
-
"value": ["watchValueHandler"]
|
|
1634
|
-
}; }
|
|
1635
|
-
};
|
|
1636
|
-
TextField.style = IcTextFieldStyle0;
|
|
1637
|
-
|
|
1638
|
-
export { Pagination as ic_pagination, PaginationItem as ic_pagination_item, Select as ic_select, TextField as ic_text_field };
|
|
1639
|
-
|
|
1640
|
-
//# sourceMappingURL=ic-pagination_4.entry.js.map
|