@ukic/web-components 3.0.0-alpha.1 → 3.0.0-alpha.3
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/core.cjs.js +1 -1
- package/dist/cjs/{helpers-f1cf5156.js → helpers-69219f14.js} +24 -1
- package/dist/cjs/helpers-69219f14.js.map +1 -0
- package/dist/cjs/ic-accordion-group.cjs.entry.js +1 -1
- package/dist/cjs/ic-accordion.cjs.entry.js +2 -2
- package/dist/cjs/ic-accordion.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-alert.cjs.entry.js +2 -2
- package/dist/cjs/ic-alert.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-back-to-top.cjs.entry.js +1 -1
- package/dist/cjs/ic-badge.cjs.entry.js +2 -2
- package/dist/cjs/ic-badge.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-breadcrumb-group.cjs.entry.js +1 -1
- package/dist/cjs/ic-breadcrumb.cjs.entry.js +2 -2
- package/dist/cjs/ic-breadcrumb.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-button_3.cjs.entry.js +17 -16
- package/dist/cjs/ic-button_3.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-card-vertical.cjs.entry.js +2 -2
- package/dist/cjs/ic-card-vertical.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-checkbox-group.cjs.entry.js +3 -3
- package/dist/cjs/ic-checkbox-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-checkbox.cjs.entry.js +3 -3
- package/dist/cjs/ic-checkbox.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-chip.cjs.entry.js +21 -14
- package/dist/cjs/ic-chip.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-classification-banner.cjs.entry.js +1 -1
- package/dist/cjs/ic-classification-banner.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-data-row.cjs.entry.js +1 -1
- package/dist/cjs/ic-dialog.cjs.entry.js +1 -1
- package/dist/cjs/ic-divider.cjs.entry.js +2 -2
- package/dist/cjs/ic-divider.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-empty-state.cjs.entry.js +1 -1
- package/dist/cjs/ic-footer-link-group.cjs.entry.js +2 -2
- package/dist/cjs/ic-footer-link-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-footer-link.cjs.entry.js +2 -2
- package/dist/cjs/ic-footer-link.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-footer.cjs.entry.js +2 -2
- package/dist/cjs/ic-footer.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-hero.cjs.entry.js +1 -1
- package/dist/cjs/ic-horizontal-scroll.cjs.entry.js +2 -2
- package/dist/cjs/ic-horizontal-scroll.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-input-component-container_3.cjs.entry.js +447 -165
- package/dist/cjs/ic-input-component-container_3.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-input-label_2.cjs.entry.js +9 -7
- package/dist/cjs/ic-input-label_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-link.cjs.entry.js +2 -2
- package/dist/cjs/ic-link.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-menu-group.cjs.entry.js +2 -2
- package/dist/cjs/ic-menu-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-menu-item.cjs.entry.js +2 -2
- package/dist/cjs/ic-menu-item.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-navigation-button.cjs.entry.js +1 -1
- package/dist/cjs/ic-navigation-group.cjs.entry.js +2 -2
- package/dist/cjs/ic-navigation-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-navigation-item.cjs.entry.js +2 -2
- package/dist/cjs/ic-navigation-item.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-navigation-menu.cjs.entry.js +2 -2
- package/dist/cjs/ic-navigation-menu.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-page-header.cjs.entry.js +5 -5
- package/dist/cjs/ic-page-header.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-pagination-item.cjs.entry.js +2 -2
- package/dist/cjs/ic-pagination-item.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-pagination.cjs.entry.js +1 -1
- package/dist/cjs/ic-popover-menu.cjs.entry.js +27 -21
- package/dist/cjs/ic-popover-menu.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-radio-group.cjs.entry.js +20 -10
- package/dist/cjs/ic-radio-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-radio-option.cjs.entry.js +27 -22
- package/dist/cjs/ic-radio-option.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-search-bar.cjs.entry.js +12 -25
- package/dist/cjs/ic-search-bar.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-select.cjs.entry.js +148 -38
- package/dist/cjs/ic-select.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-side-navigation.cjs.entry.js +2 -2
- package/dist/cjs/ic-side-navigation.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-skeleton.cjs.entry.js +4 -4
- package/dist/cjs/ic-skeleton.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-status-tag.cjs.entry.js +2 -2
- package/dist/cjs/ic-status-tag.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-step.cjs.entry.js +4 -5
- package/dist/cjs/ic-step.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-stepper.cjs.entry.js +12 -2
- package/dist/cjs/ic-stepper.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-switch.cjs.entry.js +7 -4
- package/dist/cjs/ic-switch.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-tab-context.cjs.entry.js +58 -122
- package/dist/cjs/ic-tab-context.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-tab-group.cjs.entry.js +1 -1
- package/dist/cjs/ic-tab-panel.cjs.entry.js +2 -2
- package/dist/cjs/ic-tab-panel.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-tab.cjs.entry.js +6 -7
- package/dist/cjs/ic-tab.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-text-field.cjs.entry.js +3 -3
- package/dist/cjs/ic-text-field.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-theme.cjs.entry.js +1 -1
- package/dist/cjs/ic-toast.cjs.entry.js +3 -3
- package/dist/cjs/ic-toast.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-toggle-button.cjs.entry.js +2 -2
- package/dist/cjs/ic-toggle-button.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-top-navigation.cjs.entry.js +2 -2
- package/dist/cjs/ic-top-navigation.cjs.entry.js.map +1 -1
- package/dist/cjs/ic-typography.cjs.entry.js +5 -3
- package/dist/cjs/ic-typography.cjs.entry.js.map +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/ic-accordion/ic-accordion.css +3 -3
- package/dist/collection/components/ic-alert/ic-alert.css +19 -12
- package/dist/collection/components/ic-alert/ic-alert.js +1 -1
- package/dist/collection/components/ic-alert/ic-alert.js.map +1 -1
- package/dist/collection/components/ic-badge/ic-badge.css +2 -2
- package/dist/collection/components/ic-breadcrumb/ic-breadcrumb.css +1 -1
- package/dist/collection/components/ic-button/ic-button.css +30 -33
- package/dist/collection/components/ic-button/ic-button.js +5 -6
- package/dist/collection/components/ic-button/ic-button.js.map +1 -1
- package/dist/collection/components/ic-card-vertical/ic-card-vertical.css +9 -9
- package/dist/collection/components/ic-checkbox/ic-checkbox.css +9 -4
- package/dist/collection/components/ic-checkbox/ic-checkbox.js +1 -1
- package/dist/collection/components/ic-checkbox/ic-checkbox.js.map +1 -1
- package/dist/collection/components/ic-checkbox-group/ic-checkbox-group.css +2 -2
- package/dist/collection/components/ic-checkbox-group/ic-checkbox-group.js +1 -1
- package/dist/collection/components/ic-checkbox-group/ic-checkbox-group.js.map +1 -1
- package/dist/collection/components/ic-chip/ic-chip.css +64 -49
- package/dist/collection/components/ic-chip/ic-chip.js +41 -15
- package/dist/collection/components/ic-chip/ic-chip.js.map +1 -1
- package/dist/collection/components/ic-chip/test/basic/ic-chip.spec.js +16 -0
- package/dist/collection/components/ic-chip/test/basic/ic-chip.spec.js.map +1 -1
- package/dist/collection/components/ic-classification-banner/ic-classification-banner.css +25 -9
- package/dist/collection/components/ic-divider/ic-divider.css +2 -2
- package/dist/collection/components/ic-footer/ic-footer.css +3 -3
- package/dist/collection/components/ic-footer-link/ic-footer-link.css +4 -4
- package/dist/collection/components/ic-footer-link-group/ic-footer-link-group.css +4 -4
- package/dist/collection/components/ic-horizontal-scroll/ic-horizontal-scroll.css +3 -3
- package/dist/collection/components/ic-input-component-container/ic-input-component-container.css +9 -9
- package/dist/collection/components/ic-input-label/ic-input-label.css +6 -5
- package/dist/collection/components/ic-input-label/ic-input-label.js +45 -4
- package/dist/collection/components/ic-input-label/ic-input-label.js.map +1 -1
- package/dist/collection/components/ic-input-label/test/basic/ic-input-label.spec.js +35 -49
- package/dist/collection/components/ic-input-label/test/basic/ic-input-label.spec.js.map +1 -1
- package/dist/collection/components/ic-input-validation/ic-input-validation.css +3 -3
- package/dist/collection/components/ic-link/ic-link.css +1 -1
- package/dist/collection/components/ic-loading-indicator/ic-loading-indicator.css +15 -10
- package/dist/collection/components/ic-loading-indicator/ic-loading-indicator.js +50 -31
- package/dist/collection/components/ic-loading-indicator/ic-loading-indicator.js.map +1 -1
- package/dist/collection/components/ic-menu/ic-menu.css +79 -19
- package/dist/collection/components/ic-menu/ic-menu.js +485 -192
- package/dist/collection/components/ic-menu/ic-menu.js.map +1 -1
- package/dist/collection/components/ic-menu/test/basic/ic-menu.spec.js +381 -33
- package/dist/collection/components/ic-menu/test/basic/ic-menu.spec.js.map +1 -1
- package/dist/collection/components/ic-menu-group/ic-menu-group.css +2 -2
- package/dist/collection/components/ic-menu-item/ic-menu-item.css +32 -28
- package/dist/collection/components/ic-navigation-group/ic-navigation-group.css +3 -3
- package/dist/collection/components/ic-navigation-item/ic-navigation-item.css +8 -8
- package/dist/collection/components/ic-navigation-menu/ic-navigation-menu.css +2 -2
- package/dist/collection/components/ic-page-header/ic-page-header.css +5 -2
- package/dist/collection/components/ic-page-header/ic-page-header.js +3 -3
- package/dist/collection/components/ic-page-header/ic-page-header.js.map +1 -1
- package/dist/collection/components/ic-pagination-item/ic-pagination-item.css +5 -5
- package/dist/collection/components/ic-popover-menu/ic-popover-menu.css +5 -5
- package/dist/collection/components/ic-popover-menu/ic-popover-menu.js +76 -19
- package/dist/collection/components/ic-popover-menu/ic-popover-menu.js.map +1 -1
- package/dist/collection/components/ic-radio-group/ic-radio-group.css +1 -1
- package/dist/collection/components/ic-radio-group/ic-radio-group.js +18 -8
- package/dist/collection/components/ic-radio-group/ic-radio-group.js.map +1 -1
- package/dist/collection/components/ic-radio-group/test/basic/ic-radio-group.spec.js +2 -2
- package/dist/collection/components/ic-radio-group/test/basic/ic-radio-group.spec.js.map +1 -1
- package/dist/collection/components/ic-radio-option/ic-radio-option.css +4 -3
- package/dist/collection/components/ic-radio-option/ic-radio-option.js +26 -21
- package/dist/collection/components/ic-radio-option/ic-radio-option.js.map +1 -1
- package/dist/collection/components/ic-search-bar/ic-search-bar.css +6 -5
- package/dist/collection/components/ic-search-bar/ic-search-bar.js +10 -23
- package/dist/collection/components/ic-search-bar/ic-search-bar.js.map +1 -1
- package/dist/collection/components/ic-select/ic-select.css +45 -25
- package/dist/collection/components/ic-select/ic-select.js +192 -44
- package/dist/collection/components/ic-select/ic-select.js.map +1 -1
- package/dist/collection/components/ic-select/test/basic/ic-select.spec.js +160 -1
- package/dist/collection/components/ic-select/test/basic/ic-select.spec.js.map +1 -1
- package/dist/collection/components/ic-side-navigation/ic-side-navigation.css +8 -8
- package/dist/collection/components/ic-skeleton/ic-skeleton.css +4 -27
- package/dist/collection/components/ic-skeleton/ic-skeleton.js +16 -10
- package/dist/collection/components/ic-skeleton/ic-skeleton.js.map +1 -1
- package/dist/collection/components/ic-status-tag/ic-status-tag.css +1 -1
- package/dist/collection/components/ic-step/ic-step.css +65 -98
- package/dist/collection/components/ic-step/ic-step.js +29 -3
- package/dist/collection/components/ic-step/ic-step.js.map +1 -1
- package/dist/collection/components/ic-stepper/ic-stepper.js +37 -19
- package/dist/collection/components/ic-stepper/ic-stepper.js.map +1 -1
- package/dist/collection/components/ic-stepper/test/basic/ic-stepper.spec.js +4 -4
- package/dist/collection/components/ic-stepper/test/basic/ic-stepper.spec.js.map +1 -1
- package/dist/collection/components/ic-switch/ic-switch.css +28 -31
- package/dist/collection/components/ic-switch/ic-switch.js +29 -2
- package/dist/collection/components/ic-switch/ic-switch.js.map +1 -1
- package/dist/collection/components/ic-tab/ic-tab.js +5 -6
- package/dist/collection/components/ic-tab/ic-tab.js.map +1 -1
- package/dist/collection/components/ic-tab-context/ic-tab-context.js +58 -122
- package/dist/collection/components/ic-tab-context/ic-tab-context.js.map +1 -1
- package/dist/collection/components/ic-tab-context/test/basic/ic-tab-context.spec.js +2 -2
- package/dist/collection/components/ic-tab-context/test/basic/ic-tab-context.spec.js.map +1 -1
- package/dist/collection/components/ic-tab-panel/ic-tab-panel.css +1 -1
- package/dist/collection/components/ic-text-field/ic-text-field.css +7 -6
- package/dist/collection/components/ic-text-field/ic-text-field.js +1 -1
- package/dist/collection/components/ic-text-field/ic-text-field.js.map +1 -1
- package/dist/collection/components/ic-toast/ic-toast.css +9 -4
- package/dist/collection/components/ic-toast/ic-toast.js +1 -1
- package/dist/collection/components/ic-toast/ic-toast.js.map +1 -1
- package/dist/collection/components/ic-toast/test/basic/ic-toast.spec.js +1 -1
- package/dist/collection/components/ic-toast/test/basic/ic-toast.spec.js.map +1 -1
- package/dist/collection/components/ic-toggle-button/ic-toggle-button.css +8 -8
- package/dist/collection/components/ic-tooltip/ic-tooltip.css +7 -1
- package/dist/collection/components/ic-top-navigation/ic-top-navigation.css +6 -6
- package/dist/collection/components/ic-top-navigation/ic-top-navigation.js.map +1 -1
- package/dist/collection/components/ic-typography/ic-typography.css +3 -3
- package/dist/collection/components/ic-typography/ic-typography.js +3 -1
- package/dist/collection/components/ic-typography/ic-typography.js.map +1 -1
- package/dist/collection/utils/helpers.js +20 -0
- package/dist/collection/utils/helpers.js.map +1 -1
- package/dist/collection/utils/types.js.map +1 -1
- package/dist/components/helpers.js +22 -1
- package/dist/components/helpers.js.map +1 -1
- package/dist/components/ic-accordion.js +1 -1
- package/dist/components/ic-accordion.js.map +1 -1
- package/dist/components/ic-alert.js +1 -1
- package/dist/components/ic-alert.js.map +1 -1
- package/dist/components/ic-badge.js +1 -1
- package/dist/components/ic-badge.js.map +1 -1
- package/dist/components/ic-breadcrumb2.js +1 -1
- package/dist/components/ic-breadcrumb2.js.map +1 -1
- package/dist/components/ic-button2.js +6 -7
- package/dist/components/ic-button2.js.map +1 -1
- package/dist/components/ic-card-vertical.js +1 -1
- package/dist/components/ic-card-vertical.js.map +1 -1
- package/dist/components/ic-checkbox-group.js +2 -2
- package/dist/components/ic-checkbox-group.js.map +1 -1
- package/dist/components/ic-checkbox.js +2 -2
- package/dist/components/ic-checkbox.js.map +1 -1
- package/dist/components/ic-chip.js +23 -14
- package/dist/components/ic-chip.js.map +1 -1
- package/dist/components/ic-classification-banner.js +1 -1
- package/dist/components/ic-classification-banner.js.map +1 -1
- package/dist/components/ic-divider2.js +1 -1
- package/dist/components/ic-divider2.js.map +1 -1
- package/dist/components/ic-footer-link-group.js +1 -1
- package/dist/components/ic-footer-link-group.js.map +1 -1
- package/dist/components/ic-footer-link.js +1 -1
- package/dist/components/ic-footer-link.js.map +1 -1
- package/dist/components/ic-footer.js +1 -1
- package/dist/components/ic-footer.js.map +1 -1
- package/dist/components/ic-horizontal-scroll2.js +1 -1
- package/dist/components/ic-horizontal-scroll2.js.map +1 -1
- package/dist/components/ic-input-component-container2.js +1 -1
- package/dist/components/ic-input-component-container2.js.map +1 -1
- package/dist/components/ic-input-label2.js +10 -6
- package/dist/components/ic-input-label2.js.map +1 -1
- package/dist/components/ic-input-validation2.js +1 -1
- package/dist/components/ic-input-validation2.js.map +1 -1
- package/dist/components/ic-link2.js +1 -1
- package/dist/components/ic-link2.js.map +1 -1
- package/dist/components/ic-loading-indicator2.js +11 -9
- package/dist/components/ic-loading-indicator2.js.map +1 -1
- package/dist/components/ic-menu-group.js +1 -1
- package/dist/components/ic-menu-group.js.map +1 -1
- package/dist/components/ic-menu-item2.js +1 -1
- package/dist/components/ic-menu-item2.js.map +1 -1
- package/dist/components/ic-menu2.js +450 -167
- package/dist/components/ic-menu2.js.map +1 -1
- package/dist/components/ic-navigation-group.js +2 -2
- package/dist/components/ic-navigation-group.js.map +1 -1
- package/dist/components/ic-navigation-item.js +2 -2
- package/dist/components/ic-navigation-item.js.map +1 -1
- package/dist/components/ic-navigation-menu2.js +2 -2
- package/dist/components/ic-navigation-menu2.js.map +1 -1
- package/dist/components/ic-page-header.js +4 -4
- package/dist/components/ic-page-header.js.map +1 -1
- package/dist/components/ic-pagination-item2.js +2 -2
- package/dist/components/ic-pagination-item2.js.map +1 -1
- package/dist/components/ic-popover-menu.js +29 -21
- package/dist/components/ic-popover-menu.js.map +1 -1
- package/dist/components/ic-radio-group.js +19 -9
- package/dist/components/ic-radio-group.js.map +1 -1
- package/dist/components/ic-radio-option.js +27 -22
- package/dist/components/ic-radio-option.js.map +1 -1
- package/dist/components/ic-search-bar.js +12 -25
- package/dist/components/ic-search-bar.js.map +1 -1
- package/dist/components/ic-select.js +149 -38
- package/dist/components/ic-select.js.map +1 -1
- package/dist/components/ic-side-navigation.js +2 -2
- package/dist/components/ic-side-navigation.js.map +1 -1
- package/dist/components/ic-skeleton.js +5 -5
- package/dist/components/ic-skeleton.js.map +1 -1
- package/dist/components/ic-status-tag.js +1 -1
- package/dist/components/ic-status-tag.js.map +1 -1
- package/dist/components/ic-step.js +4 -4
- package/dist/components/ic-step.js.map +1 -1
- package/dist/components/ic-stepper.js +14 -3
- package/dist/components/ic-stepper.js.map +1 -1
- package/dist/components/ic-switch.js +7 -3
- package/dist/components/ic-switch.js.map +1 -1
- package/dist/components/ic-tab-context.js +58 -122
- package/dist/components/ic-tab-context.js.map +1 -1
- package/dist/components/ic-tab-panel.js +1 -1
- package/dist/components/ic-tab-panel.js.map +1 -1
- package/dist/components/ic-tab.js +5 -6
- package/dist/components/ic-tab.js.map +1 -1
- package/dist/components/ic-text-field2.js +3 -3
- package/dist/components/ic-text-field2.js.map +1 -1
- package/dist/components/ic-theme.js +1 -1
- package/dist/components/ic-toast.js +3 -3
- package/dist/components/ic-toast.js.map +1 -1
- package/dist/components/ic-toggle-button.js +1 -1
- package/dist/components/ic-toggle-button.js.map +1 -1
- package/dist/components/ic-tooltip2.js +1 -1
- package/dist/components/ic-tooltip2.js.map +1 -1
- package/dist/components/ic-top-navigation.js +2 -2
- package/dist/components/ic-top-navigation.js.map +1 -1
- package/dist/components/ic-typography2.js +4 -2
- package/dist/components/ic-typography2.js.map +1 -1
- package/dist/core/core.css +661 -37
- package/dist/core/core.esm.js +1 -1
- package/dist/core/core.esm.js.map +1 -1
- package/dist/core/{p-d2f89cb5.entry.js → p-0395442c.entry.js} +2 -2
- package/dist/core/p-0d233b0c.entry.js +2 -0
- package/dist/core/p-0d233b0c.entry.js.map +1 -0
- package/dist/core/p-134def81.entry.js +2 -0
- package/dist/core/p-134def81.entry.js.map +1 -0
- package/dist/core/p-14dfd8db.entry.js +2 -0
- package/dist/core/p-14dfd8db.entry.js.map +1 -0
- package/dist/core/p-1b116dd1.entry.js +2 -0
- package/dist/core/p-1b116dd1.entry.js.map +1 -0
- package/dist/core/p-21cc87c0.entry.js +2 -0
- package/dist/core/p-21cc87c0.entry.js.map +1 -0
- package/dist/core/{p-54238d16.entry.js → p-27274ca8.entry.js} +2 -2
- package/dist/core/p-27274ca8.entry.js.map +1 -0
- package/dist/core/p-2eae9b27.entry.js +2 -0
- package/dist/core/p-2eae9b27.entry.js.map +1 -0
- package/dist/core/p-3618ac34.entry.js +2 -0
- package/dist/core/p-3618ac34.entry.js.map +1 -0
- package/dist/core/{p-355acffa.entry.js → p-37dea10d.entry.js} +2 -2
- package/dist/core/p-384d454d.entry.js +2 -0
- package/dist/core/p-384d454d.entry.js.map +1 -0
- package/dist/core/p-3d417eff.entry.js +2 -0
- package/dist/core/p-3d417eff.entry.js.map +1 -0
- package/dist/core/p-3d9726a3.entry.js +2 -0
- package/dist/core/p-3d9726a3.entry.js.map +1 -0
- package/dist/core/p-43256b7c.entry.js +2 -0
- package/dist/core/p-43256b7c.entry.js.map +1 -0
- package/dist/core/{p-46ee459b.entry.js → p-4a3b1f06.entry.js} +2 -2
- package/dist/core/{p-46ee459b.entry.js.map → p-4a3b1f06.entry.js.map} +1 -1
- package/dist/core/p-50ead56c.entry.js +2 -0
- package/dist/core/p-50ead56c.entry.js.map +1 -0
- package/dist/core/{p-5a2630fb.entry.js → p-5cd016e1.entry.js} +2 -2
- package/dist/core/{p-5a2630fb.entry.js.map → p-5cd016e1.entry.js.map} +1 -1
- package/dist/core/{p-78ce4920.entry.js → p-5ef8e106.entry.js} +2 -2
- package/dist/core/{p-78ce4920.entry.js.map → p-5ef8e106.entry.js.map} +1 -1
- package/dist/core/{p-c81109da.entry.js → p-690c5e80.entry.js} +2 -2
- package/dist/core/p-690c5e80.entry.js.map +1 -0
- package/dist/core/{p-43f9a711.entry.js → p-6d3e4bb1.entry.js} +2 -2
- package/dist/core/{p-1e802eeb.entry.js → p-726673ee.entry.js} +2 -2
- package/dist/core/p-726673ee.entry.js.map +1 -0
- package/dist/core/p-72d30c8a.entry.js +2 -0
- package/dist/core/p-72d30c8a.entry.js.map +1 -0
- package/dist/core/{p-f30f3a3e.entry.js → p-76263187.entry.js} +2 -2
- package/dist/core/p-7827b5cb.entry.js +2 -0
- package/dist/core/p-7827b5cb.entry.js.map +1 -0
- package/dist/core/p-79d0be03.entry.js +2 -0
- package/dist/core/p-79d0be03.entry.js.map +1 -0
- package/dist/core/{p-bf4c61cb.entry.js → p-7b35de65.entry.js} +2 -2
- package/dist/core/{p-bf4c61cb.entry.js.map → p-7b35de65.entry.js.map} +1 -1
- package/dist/core/p-7fbf2d3e.entry.js +2 -0
- package/dist/core/p-7fbf2d3e.entry.js.map +1 -0
- package/dist/core/p-91cf9b2b.entry.js +2 -0
- package/dist/core/p-91cf9b2b.entry.js.map +1 -0
- package/dist/core/p-922984cb.entry.js +2 -0
- package/dist/core/p-922984cb.entry.js.map +1 -0
- package/dist/core/{p-e861a2b3.entry.js → p-95f603dd.entry.js} +2 -2
- package/dist/core/p-95f603dd.entry.js.map +1 -0
- package/dist/core/{p-e4b276b5.entry.js → p-97fb2bdf.entry.js} +2 -2
- package/dist/core/p-ac4b7329.entry.js +2 -0
- package/dist/core/p-ac4b7329.entry.js.map +1 -0
- package/dist/core/p-acbd15ab.entry.js +2 -0
- package/dist/core/p-acbd15ab.entry.js.map +1 -0
- package/dist/core/{p-e597da0e.entry.js → p-b01ffa55.entry.js} +2 -2
- package/dist/core/p-b01ffa55.entry.js.map +1 -0
- package/dist/core/p-b17c94b7.entry.js +2 -0
- package/dist/core/p-b17c94b7.entry.js.map +1 -0
- package/dist/core/p-b78f8b8c.entry.js +2 -0
- package/dist/core/p-b78f8b8c.entry.js.map +1 -0
- package/dist/core/{p-312cacae.js → p-b7eb8ef9.js} +2 -2
- package/dist/core/p-b7eb8ef9.js.map +1 -0
- package/dist/core/{p-363d6e88.entry.js → p-b95a72a3.entry.js} +2 -2
- package/dist/core/{p-21e5dd29.entry.js → p-b997064c.entry.js} +2 -2
- package/dist/core/{p-56d1828c.entry.js → p-ba6ecc15.entry.js} +2 -2
- package/dist/core/{p-56d1828c.entry.js.map → p-ba6ecc15.entry.js.map} +1 -1
- package/dist/core/p-c0fc3d02.entry.js +2 -0
- package/dist/core/p-c0fc3d02.entry.js.map +1 -0
- package/dist/core/p-c396bd4d.entry.js +2 -0
- package/dist/core/p-c396bd4d.entry.js.map +1 -0
- package/dist/core/{p-a3b6a02d.entry.js → p-c9cf932c.entry.js} +2 -2
- package/dist/core/{p-a3b6a02d.entry.js.map → p-c9cf932c.entry.js.map} +1 -1
- package/dist/core/p-cf7db84a.entry.js +2 -0
- package/dist/core/p-cf7db84a.entry.js.map +1 -0
- package/dist/core/{p-a765ad17.entry.js → p-dd36bf1b.entry.js} +2 -2
- package/dist/core/p-dd36bf1b.entry.js.map +1 -0
- package/dist/core/p-e488de54.entry.js +2 -0
- package/dist/core/p-e488de54.entry.js.map +1 -0
- package/dist/core/p-e4d1839e.entry.js +2 -0
- package/dist/core/p-e4d1839e.entry.js.map +1 -0
- package/dist/core/p-eb3b4935.entry.js +2 -0
- package/dist/core/p-eb3b4935.entry.js.map +1 -0
- package/dist/core/{p-60efd7fa.entry.js → p-ebafab37.entry.js} +2 -2
- package/dist/core/{p-82375dca.entry.js → p-ee6dd94c.entry.js} +2 -2
- package/dist/core/p-f0fc1bf0.entry.js +2 -0
- package/dist/core/p-f0fc1bf0.entry.js.map +1 -0
- package/dist/core/p-f24984c5.entry.js +2 -0
- package/dist/core/p-f24984c5.entry.js.map +1 -0
- package/dist/core/{p-d8870804.entry.js → p-f5b2b26d.entry.js} +2 -2
- package/dist/core/p-f60dbd0e.entry.js +2 -0
- package/dist/core/p-f60dbd0e.entry.js.map +1 -0
- package/dist/core/{p-40e9e76a.entry.js → p-f71c00ce.entry.js} +2 -2
- package/dist/core/{p-69f3ce5a.entry.js → p-ff4298b1.entry.js} +2 -2
- package/dist/core/p-ff4298b1.entry.js.map +1 -0
- package/dist/esm/core.js +1 -1
- package/dist/esm/{helpers-1c9151ef.js → helpers-e8797e8d.js} +23 -2
- package/dist/esm/helpers-e8797e8d.js.map +1 -0
- package/dist/esm/ic-accordion-group.entry.js +1 -1
- package/dist/esm/ic-accordion.entry.js +2 -2
- package/dist/esm/ic-accordion.entry.js.map +1 -1
- package/dist/esm/ic-alert.entry.js +2 -2
- package/dist/esm/ic-alert.entry.js.map +1 -1
- package/dist/esm/ic-back-to-top.entry.js +1 -1
- package/dist/esm/ic-badge.entry.js +2 -2
- package/dist/esm/ic-badge.entry.js.map +1 -1
- package/dist/esm/ic-breadcrumb-group.entry.js +1 -1
- package/dist/esm/ic-breadcrumb.entry.js +2 -2
- package/dist/esm/ic-breadcrumb.entry.js.map +1 -1
- package/dist/esm/ic-button_3.entry.js +17 -16
- package/dist/esm/ic-button_3.entry.js.map +1 -1
- package/dist/esm/ic-card-vertical.entry.js +2 -2
- package/dist/esm/ic-card-vertical.entry.js.map +1 -1
- package/dist/esm/ic-checkbox-group.entry.js +3 -3
- package/dist/esm/ic-checkbox-group.entry.js.map +1 -1
- package/dist/esm/ic-checkbox.entry.js +3 -3
- package/dist/esm/ic-checkbox.entry.js.map +1 -1
- package/dist/esm/ic-chip.entry.js +22 -15
- package/dist/esm/ic-chip.entry.js.map +1 -1
- package/dist/esm/ic-classification-banner.entry.js +1 -1
- package/dist/esm/ic-classification-banner.entry.js.map +1 -1
- package/dist/esm/ic-data-row.entry.js +1 -1
- package/dist/esm/ic-dialog.entry.js +1 -1
- package/dist/esm/ic-divider.entry.js +2 -2
- package/dist/esm/ic-divider.entry.js.map +1 -1
- package/dist/esm/ic-empty-state.entry.js +1 -1
- package/dist/esm/ic-footer-link-group.entry.js +2 -2
- package/dist/esm/ic-footer-link-group.entry.js.map +1 -1
- package/dist/esm/ic-footer-link.entry.js +2 -2
- package/dist/esm/ic-footer-link.entry.js.map +1 -1
- package/dist/esm/ic-footer.entry.js +2 -2
- package/dist/esm/ic-footer.entry.js.map +1 -1
- package/dist/esm/ic-hero.entry.js +1 -1
- package/dist/esm/ic-horizontal-scroll.entry.js +2 -2
- package/dist/esm/ic-horizontal-scroll.entry.js.map +1 -1
- package/dist/esm/ic-input-component-container_3.entry.js +447 -165
- package/dist/esm/ic-input-component-container_3.entry.js.map +1 -1
- package/dist/esm/ic-input-label_2.entry.js +9 -7
- package/dist/esm/ic-input-label_2.entry.js.map +1 -1
- package/dist/esm/ic-link.entry.js +2 -2
- package/dist/esm/ic-link.entry.js.map +1 -1
- package/dist/esm/ic-menu-group.entry.js +2 -2
- package/dist/esm/ic-menu-group.entry.js.map +1 -1
- package/dist/esm/ic-menu-item.entry.js +2 -2
- package/dist/esm/ic-menu-item.entry.js.map +1 -1
- package/dist/esm/ic-navigation-button.entry.js +1 -1
- package/dist/esm/ic-navigation-group.entry.js +2 -2
- package/dist/esm/ic-navigation-group.entry.js.map +1 -1
- package/dist/esm/ic-navigation-item.entry.js +2 -2
- package/dist/esm/ic-navigation-item.entry.js.map +1 -1
- package/dist/esm/ic-navigation-menu.entry.js +2 -2
- package/dist/esm/ic-navigation-menu.entry.js.map +1 -1
- package/dist/esm/ic-page-header.entry.js +5 -5
- package/dist/esm/ic-page-header.entry.js.map +1 -1
- package/dist/esm/ic-pagination-item.entry.js +2 -2
- package/dist/esm/ic-pagination-item.entry.js.map +1 -1
- package/dist/esm/ic-pagination.entry.js +1 -1
- package/dist/esm/ic-popover-menu.entry.js +27 -21
- package/dist/esm/ic-popover-menu.entry.js.map +1 -1
- package/dist/esm/ic-radio-group.entry.js +20 -10
- package/dist/esm/ic-radio-group.entry.js.map +1 -1
- package/dist/esm/ic-radio-option.entry.js +27 -22
- package/dist/esm/ic-radio-option.entry.js.map +1 -1
- package/dist/esm/ic-search-bar.entry.js +12 -25
- package/dist/esm/ic-search-bar.entry.js.map +1 -1
- package/dist/esm/ic-select.entry.js +148 -38
- package/dist/esm/ic-select.entry.js.map +1 -1
- package/dist/esm/ic-side-navigation.entry.js +2 -2
- package/dist/esm/ic-side-navigation.entry.js.map +1 -1
- package/dist/esm/ic-skeleton.entry.js +4 -4
- package/dist/esm/ic-skeleton.entry.js.map +1 -1
- package/dist/esm/ic-status-tag.entry.js +2 -2
- package/dist/esm/ic-status-tag.entry.js.map +1 -1
- package/dist/esm/ic-step.entry.js +4 -5
- package/dist/esm/ic-step.entry.js.map +1 -1
- package/dist/esm/ic-stepper.entry.js +12 -2
- package/dist/esm/ic-stepper.entry.js.map +1 -1
- package/dist/esm/ic-switch.entry.js +7 -4
- package/dist/esm/ic-switch.entry.js.map +1 -1
- package/dist/esm/ic-tab-context.entry.js +58 -122
- package/dist/esm/ic-tab-context.entry.js.map +1 -1
- package/dist/esm/ic-tab-group.entry.js +1 -1
- package/dist/esm/ic-tab-panel.entry.js +2 -2
- package/dist/esm/ic-tab-panel.entry.js.map +1 -1
- package/dist/esm/ic-tab.entry.js +6 -7
- package/dist/esm/ic-tab.entry.js.map +1 -1
- package/dist/esm/ic-text-field.entry.js +3 -3
- package/dist/esm/ic-text-field.entry.js.map +1 -1
- package/dist/esm/ic-theme.entry.js +1 -1
- package/dist/esm/ic-toast.entry.js +3 -3
- package/dist/esm/ic-toast.entry.js.map +1 -1
- package/dist/esm/ic-toggle-button.entry.js +2 -2
- package/dist/esm/ic-toggle-button.entry.js.map +1 -1
- package/dist/esm/ic-top-navigation.entry.js +2 -2
- package/dist/esm/ic-top-navigation.entry.js.map +1 -1
- package/dist/esm/ic-typography.entry.js +5 -3
- package/dist/esm/ic-typography.entry.js.map +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/ic-alert/ic-alert.d.ts +1 -1
- package/dist/types/components/ic-chip/ic-chip.d.ts +8 -2
- package/dist/types/components/ic-input-label/ic-input-label.d.ts +8 -0
- package/dist/types/components/ic-loading-indicator/ic-loading-indicator.d.ts +9 -5
- package/dist/types/components/ic-menu/ic-menu.d.ts +43 -15
- package/dist/types/components/ic-popover-menu/ic-popover-menu.d.ts +7 -2
- package/dist/types/components/ic-radio-option/ic-radio-option.d.ts +3 -2
- package/dist/types/components/ic-select/ic-select.d.ts +24 -10
- package/dist/types/components/ic-skeleton/ic-skeleton.d.ts +3 -2
- package/dist/types/components/ic-step/ic-step.d.ts +5 -0
- package/dist/types/components/ic-stepper/ic-stepper.d.ts +6 -4
- package/dist/types/components/ic-switch/ic-switch.d.ts +5 -1
- package/dist/types/components/ic-tab-context/ic-tab-context.d.ts +8 -6
- package/dist/types/components.d.ts +113 -46
- package/dist/types/utils/helpers.d.ts +7 -0
- package/dist/types/utils/types.d.ts +1 -1
- package/hydrate/index.js +886 -494
- package/package.json +2 -2
- package/vscode-data.json +105 -35
- package/dist/cjs/helpers-f1cf5156.js.map +0 -1
- package/dist/collection/components/ic-radio-group/test/basic/ic-radio-group.e2e.js +0 -339
- package/dist/collection/components/ic-radio-group/test/basic/ic-radio-group.e2e.js.map +0 -1
- package/dist/collection/components/ic-search-bar/test/basic/ic-search-bar.e2e.js +0 -1106
- package/dist/collection/components/ic-search-bar/test/basic/ic-search-bar.e2e.js.map +0 -1
- package/dist/collection/components/ic-stepper/test/basic/ic-stepper.e2e.js +0 -49
- package/dist/collection/components/ic-stepper/test/basic/ic-stepper.e2e.js.map +0 -1
- package/dist/collection/components/ic-tooltip/test/basic/ic-tooltip.e2e.js +0 -109
- package/dist/collection/components/ic-tooltip/test/basic/ic-tooltip.e2e.js.map +0 -1
- package/dist/collection/components/ic-typography/test/basic/ic-typography.e2e.js +0 -39
- package/dist/collection/components/ic-typography/test/basic/ic-typography.e2e.js.map +0 -1
- package/dist/core/p-09104e40.entry.js +0 -2
- package/dist/core/p-09104e40.entry.js.map +0 -1
- package/dist/core/p-0c0b1c74.entry.js +0 -2
- package/dist/core/p-0c0b1c74.entry.js.map +0 -1
- package/dist/core/p-0c3a0d85.entry.js +0 -2
- package/dist/core/p-0c3a0d85.entry.js.map +0 -1
- package/dist/core/p-1083a708.entry.js +0 -2
- package/dist/core/p-1083a708.entry.js.map +0 -1
- package/dist/core/p-130dd440.entry.js +0 -2
- package/dist/core/p-130dd440.entry.js.map +0 -1
- package/dist/core/p-1e802eeb.entry.js.map +0 -1
- package/dist/core/p-21312898.entry.js +0 -2
- package/dist/core/p-21312898.entry.js.map +0 -1
- package/dist/core/p-2ab86057.entry.js +0 -2
- package/dist/core/p-2ab86057.entry.js.map +0 -1
- package/dist/core/p-312cacae.js.map +0 -1
- package/dist/core/p-35b8b480.entry.js +0 -2
- package/dist/core/p-35b8b480.entry.js.map +0 -1
- package/dist/core/p-54238d16.entry.js.map +0 -1
- package/dist/core/p-550d7356.entry.js +0 -2
- package/dist/core/p-550d7356.entry.js.map +0 -1
- package/dist/core/p-5a52614c.entry.js +0 -2
- package/dist/core/p-5a52614c.entry.js.map +0 -1
- package/dist/core/p-69f3ce5a.entry.js.map +0 -1
- package/dist/core/p-79d2a33b.entry.js +0 -2
- package/dist/core/p-79d2a33b.entry.js.map +0 -1
- package/dist/core/p-80237a20.entry.js +0 -2
- package/dist/core/p-80237a20.entry.js.map +0 -1
- package/dist/core/p-804513ad.entry.js +0 -2
- package/dist/core/p-804513ad.entry.js.map +0 -1
- package/dist/core/p-8e1e25a7.entry.js +0 -2
- package/dist/core/p-8e1e25a7.entry.js.map +0 -1
- package/dist/core/p-a1a1000d.entry.js +0 -2
- package/dist/core/p-a1a1000d.entry.js.map +0 -1
- package/dist/core/p-a1b1a0ab.entry.js +0 -2
- package/dist/core/p-a1b1a0ab.entry.js.map +0 -1
- package/dist/core/p-a37bcdbe.entry.js +0 -2
- package/dist/core/p-a37bcdbe.entry.js.map +0 -1
- package/dist/core/p-a765ad17.entry.js.map +0 -1
- package/dist/core/p-aa2be24c.entry.js +0 -2
- package/dist/core/p-aa2be24c.entry.js.map +0 -1
- package/dist/core/p-b12a5283.entry.js +0 -2
- package/dist/core/p-b12a5283.entry.js.map +0 -1
- package/dist/core/p-b1b05979.entry.js +0 -2
- package/dist/core/p-b1b05979.entry.js.map +0 -1
- package/dist/core/p-c6795377.entry.js +0 -2
- package/dist/core/p-c6795377.entry.js.map +0 -1
- package/dist/core/p-c81109da.entry.js.map +0 -1
- package/dist/core/p-cb4d104e.entry.js +0 -2
- package/dist/core/p-cb4d104e.entry.js.map +0 -1
- package/dist/core/p-d43d1ec0.entry.js +0 -2
- package/dist/core/p-d43d1ec0.entry.js.map +0 -1
- package/dist/core/p-d5829a35.entry.js +0 -2
- package/dist/core/p-d5829a35.entry.js.map +0 -1
- package/dist/core/p-ddb8d280.entry.js +0 -2
- package/dist/core/p-ddb8d280.entry.js.map +0 -1
- package/dist/core/p-e0e34fa7.entry.js +0 -2
- package/dist/core/p-e0e34fa7.entry.js.map +0 -1
- package/dist/core/p-e597da0e.entry.js.map +0 -1
- package/dist/core/p-e861a2b3.entry.js.map +0 -1
- package/dist/core/p-ea277b05.entry.js +0 -2
- package/dist/core/p-ea277b05.entry.js.map +0 -1
- package/dist/core/p-ef871b8f.entry.js +0 -2
- package/dist/core/p-ef871b8f.entry.js.map +0 -1
- package/dist/core/p-f229d19e.entry.js +0 -2
- package/dist/core/p-f229d19e.entry.js.map +0 -1
- package/dist/core/p-fa587e6d.entry.js +0 -2
- package/dist/core/p-fa587e6d.entry.js.map +0 -1
- package/dist/core/p-fb6ac08d.entry.js +0 -2
- package/dist/core/p-fb6ac08d.entry.js.map +0 -1
- package/dist/esm/helpers-1c9151ef.js.map +0 -1
- /package/dist/core/{p-d2f89cb5.entry.js.map → p-0395442c.entry.js.map} +0 -0
- /package/dist/core/{p-355acffa.entry.js.map → p-37dea10d.entry.js.map} +0 -0
- /package/dist/core/{p-43f9a711.entry.js.map → p-6d3e4bb1.entry.js.map} +0 -0
- /package/dist/core/{p-f30f3a3e.entry.js.map → p-76263187.entry.js.map} +0 -0
- /package/dist/core/{p-e4b276b5.entry.js.map → p-97fb2bdf.entry.js.map} +0 -0
- /package/dist/core/{p-363d6e88.entry.js.map → p-b95a72a3.entry.js.map} +0 -0
- /package/dist/core/{p-21e5dd29.entry.js.map → p-b997064c.entry.js.map} +0 -0
- /package/dist/core/{p-60efd7fa.entry.js.map → p-ebafab37.entry.js.map} +0 -0
- /package/dist/core/{p-82375dca.entry.js.map → p-ee6dd94c.entry.js.map} +0 -0
- /package/dist/core/{p-d8870804.entry.js.map → p-f5b2b26d.entry.js.map} +0 -0
- /package/dist/core/{p-40e9e76a.entry.js.map → p-f71c00ce.entry.js.map} +0 -0
@@ -60,7 +60,7 @@ export class CheckboxGroup {
|
|
60
60
|
[`ic-checkbox-group-${size}`]: true,
|
61
61
|
} }, (validationStatus === "error" || required || hideLabel) && (h("span", { id: "screenReaderOnlyText", class: "screen-reader-only-text", "aria-hidden": "true" }, label, " ", validationStatus === "error" ? "invalid data " : null, " ", required ? "required" : null)), h("fieldset", { id: name, "aria-labelledby": `${validationStatus === "error" || required || hideLabel
|
62
62
|
? "screenReaderOnlyText"
|
63
|
-
: ""} ${describedBy}`.trim(), disabled: disabled }, !hideLabel && (h("legend", null, h("ic-input-label", { class: { [`${validationStatus}`]: true }, label: label, helperText: helperText, required: required, disabled: disabled,
|
63
|
+
: ""} ${describedBy}`.trim(), disabled: disabled }, !hideLabel && (h("legend", null, h("ic-input-label", { class: { [`${validationStatus}`]: true }, label: label, helperText: helperText, required: required, disabled: disabled, useLabelTag: false }))), h("div", { class: "checkboxes-container" }, h("slot", null))), hasValidationStatus(validationStatus, disabled) && (h("ic-input-validation", { for: name, ariaLiveMode: "polite", status: validationStatus, message: validationText }))));
|
64
64
|
}
|
65
65
|
static get is() { return "ic-checkbox-group"; }
|
66
66
|
static get encapsulation() { return "shadow"; }
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ic-checkbox-group.js","sourceRoot":"","sources":["../../../src/components/ic-checkbox-group/ic-checkbox-group.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,IAAI,EACJ,CAAC,EACD,IAAI,EACJ,MAAM,EACN,OAAO,EACP,KAAK,EAEL,KAAK,GACN,MAAM,eAAe,CAAC;AACvB,OAAO,EACL,uBAAuB,EACvB,mBAAmB,EACnB,gCAAgC,EAChC,mBAAmB,GACpB,MAAM,qBAAqB,CAAC;AAS7B,6DAA6D;AAC7D,MAAM,OAAO,aAAa;;wBAMI,KAAK;0BAKJ,EAAE;yBAKF,KAAK;;;wBA+BN,KAAK;oBAKR,QAAQ;gCAKsB,EAAE;8BAKxB,EAAE;;IAhCnC,gBAAgB,CACd,QAAgB,EAChB,QAAgB,EAChB,QAA0B;QAE1B,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,gBAAgB,CAAC,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,QAAQ,EAAE,EAAE;YACvE,IAAI,QAAQ,KAAK,OAAO;gBAAE,QAAQ,CAAC,UAAU,GAA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;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import {\n Component,\n Host,\n h,\n Prop,\n Listen,\n Element,\n Event,\n EventEmitter,\n Watch,\n} from \"@stencil/core\";\nimport {\n getInputDescribedByText,\n hasValidationStatus,\n onComponentRequiredPropUndefined,\n removeDisabledFalse,\n} from \"../../utils/helpers\";\nimport { IcInformationStatusOrEmpty, IcSizes } from \"../../utils/types\";\nimport { IcChangeEventDetail } from \"./ic-checkbox-group.types\";\n\n@Component({\n tag: \"ic-checkbox-group\",\n styleUrl: \"ic-checkbox-group.css\",\n shadow: true,\n})\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport class CheckboxGroup {\n @Element() el: HTMLIcCheckboxGroupElement;\n\n /**\n * If `true`, the checkbox group will be set to the disabled state.\n */\n @Prop() disabled: boolean = false;\n\n /**\n * The helper text that will be displayed for additional field guidance.\n */\n @Prop() helperText: string = \"\";\n\n /**\n * If `true`, the label will be hidden and the required label value will be applied as an aria-label.\n */\n @Prop() hideLabel: boolean = false;\n\n /**\n * The label for the checkbox group to be displayed.\n */\n @Prop() label!: string;\n\n /**\n * The name for the checkbox group to differentiate from other groups.\n */\n @Prop() name!: string;\n\n @Watch(\"label\")\n @Watch(\"name\")\n labelNameHandler(\n newValue: string,\n oldValue: string,\n propName: \"label\" | \"name\"\n ): void {\n Array.from(this.el.querySelectorAll(\"ic-checkbox\")).forEach((checkbox) => {\n if (propName === \"label\") checkbox.groupLabel = newValue;\n else if (checkbox.name === oldValue) {\n // If the checkbox name has been set by the parent, then override it\n checkbox.name = newValue;\n }\n });\n }\n\n /**\n * If `true`, the checkbox group will require a value.\n */\n @Prop() required: boolean = false;\n\n /**\n * The size of the checkboxes to be displayed. This does not affect the font size of the label.\n */\n @Prop() size?: IcSizes = \"medium\";\n\n /**\n * The validation status - e.g. 'error' | 'warning' | 'success'.\n */\n @Prop() validationStatus: IcInformationStatusOrEmpty = \"\";\n\n /**\n * The validation text - e.g. 'error' | 'warning' | 'success'.\n */\n @Prop() validationText: string = \"\";\n\n /**\n * Emitted when a checkbox is checked.\n */\n @Event() icChange: EventEmitter<IcChangeEventDetail>;\n\n @Listen(\"icChange\")\n handleChange(ev: CustomEvent): void {\n //don't pass on the event if it has come from slotted text field\n //otherwise any icChange handler bound to the checkbox group will also run\n if ((ev.target as HTMLElement).tagName === \"IC-TEXT-FIELD\") {\n ev.stopImmediatePropagation();\n }\n }\n\n componentWillLoad(): void {\n removeDisabledFalse(this.disabled, this.el);\n }\n\n componentDidLoad(): void {\n onComponentRequiredPropUndefined(\n [\n { prop: this.label, propName: \"label\" },\n { prop: this.name, propName: \"name\" },\n ],\n \"Checkbox Group\"\n );\n }\n\n @Listen(\"icCheck\")\n selectHandler({ target }: CustomEvent): void {\n const checkedOptions = Array.from(\n this.el.querySelectorAll(\"ic-checkbox\")\n ).filter(({ checked, disabled }) => checked && !disabled);\n this.icChange.emit({\n value: checkedOptions.map(({ value }) => value),\n checkedOptions: checkedOptions.map((opt) => ({\n checkbox: opt,\n textFieldValue: opt.querySelector(\"ic-text-field\")?.value,\n })),\n selectedOption: target as HTMLIcCheckboxElement,\n });\n }\n\n render() {\n const {\n disabled,\n helperText,\n hideLabel,\n label,\n name,\n required,\n size,\n validationStatus,\n validationText,\n } = this;\n\n const describedBy = getInputDescribedByText(\n name,\n helperText !== \"\",\n validationStatus !== \"\"\n );\n\n return (\n <Host\n class={{\n [`ic-checkbox-group-${size}`]: true,\n }}\n >\n {(validationStatus === \"error\" || required || hideLabel) && (\n <span\n id=\"screenReaderOnlyText\"\n class=\"screen-reader-only-text\"\n aria-hidden=\"true\"\n >\n {label} {validationStatus === \"error\" ? \"invalid data \" : null}{\" \"}\n {required ? \"required\" : null}\n </span>\n )}\n <fieldset\n id={name}\n aria-labelledby={`${\n validationStatus === \"error\" || required || hideLabel\n ? \"screenReaderOnlyText\"\n : \"\"\n } ${describedBy}`.trim()}\n disabled={disabled}\n >\n {!hideLabel && (\n <legend>\n <ic-input-label\n class={{ [`${validationStatus}`]: true }}\n label={label}\n helperText={helperText}\n required={required}\n disabled={disabled}\n useLabelTag={false}\n ></ic-input-label>\n </legend>\n )}\n <div class=\"checkboxes-container\">\n <slot></slot>\n </div>\n </fieldset>\n {hasValidationStatus(validationStatus, disabled) && (\n <ic-input-validation\n for={name}\n ariaLiveMode=\"polite\"\n status={validationStatus}\n message={validationText}\n ></ic-input-validation>\n )}\n </Host>\n );\n }\n}\n"]}
|
@@ -444,17 +444,30 @@ video {
|
|
444
444
|
:host {
|
445
445
|
display: inline-block;
|
446
446
|
max-width: 100%;
|
447
|
+
vertical-align: middle;
|
447
448
|
}
|
448
449
|
|
449
450
|
.chip {
|
451
|
+
--chip-bg-color: transparent;
|
452
|
+
--chip-hover-bg: var(--ic-chip-action-hover);
|
453
|
+
--chip-pressed-bg: var(--ic-chip-action-pressed);
|
454
|
+
|
450
455
|
display: flex;
|
451
456
|
padding: var(--ic-space-xxs);
|
452
457
|
font-size: 0.875rem;
|
453
458
|
border-radius: var(--ic-space-md);
|
454
459
|
text-align: left;
|
455
460
|
text-decoration: none;
|
456
|
-
transition: var(--ic-easing-transition-fast);
|
457
461
|
position: relative;
|
462
|
+
background-color: var(--chip-bg-color);
|
463
|
+
border: var(--ic-border-width) solid transparent;
|
464
|
+
justify-content: space-between;
|
465
|
+
}
|
466
|
+
|
467
|
+
@media (prefers-reduced-motion: no-preference) {
|
468
|
+
.chip {
|
469
|
+
transition: var(--ic-easing-transition-fast);
|
470
|
+
}
|
458
471
|
}
|
459
472
|
|
460
473
|
.chip.small {
|
@@ -471,69 +484,79 @@ video {
|
|
471
484
|
padding: 0 var(--ic-space-xs);
|
472
485
|
}
|
473
486
|
|
474
|
-
.chip.hovered:not(:focus-within) {
|
475
|
-
background-color: var(--ic-architectural-300);
|
476
|
-
}
|
477
|
-
|
478
487
|
.chip:focus-within {
|
479
488
|
box-shadow: var(--ic-border-focus);
|
480
489
|
outline: var(--ic-hc-focus-outline);
|
481
490
|
z-index: 1;
|
482
491
|
}
|
483
492
|
|
484
|
-
.chip.outlined.hovered:not(:focus-within) {
|
485
|
-
background-color: var(--ic-action-dark-bg-hover);
|
486
|
-
}
|
487
|
-
|
488
493
|
ic-tooltip:focus-within {
|
489
494
|
z-index: 1;
|
490
495
|
}
|
491
496
|
|
492
497
|
.filled {
|
493
|
-
|
494
|
-
|
498
|
+
--chip-bg-color: var(
|
499
|
+
--chip-custom-color,
|
500
|
+
var(--ic-chip-background-filled-default)
|
501
|
+
);
|
502
|
+
--ic-typography-color: var(
|
503
|
+
--chip-custom-foreground-color,
|
504
|
+
var(--ic-chip-label)
|
505
|
+
);
|
495
506
|
|
496
|
-
|
497
|
-
|
498
|
-
border: none;
|
507
|
+
color: var(--chip-custom-foreground-color, var(--ic-chip-label));
|
499
508
|
}
|
500
509
|
|
501
510
|
.filled.disabled {
|
502
|
-
|
511
|
+
--chip-bg-color: var(--ic-chip-background-filled-inactive);
|
503
512
|
}
|
504
513
|
|
505
|
-
.
|
506
|
-
color: var(--ic-architectural-
|
507
|
-
|
508
|
-
|
509
|
-
|
514
|
+
:host(.ic-chip-dark-text) {
|
515
|
+
--chip-custom-foreground-color: var(--ic-architectural-black);
|
516
|
+
}
|
517
|
+
|
518
|
+
:host(.ic-chip-light-text) {
|
519
|
+
--chip-custom-foreground-color: var(--ic-architectural-white);
|
520
|
+
}
|
521
|
+
|
522
|
+
:host(.ic-chip-dark-text) .chip.filled.hovered:not(:focus-within) {
|
523
|
+
--chip-hover-bg: var(--ic-action-dark-bg-hover);
|
510
524
|
}
|
511
525
|
|
512
|
-
.
|
513
|
-
|
526
|
+
:host(.ic-chip-dark-text) .chip.filled:focus-within {
|
527
|
+
--chip-pressed-bg: var(--ic-action-dark-bg-pressed);
|
514
528
|
}
|
515
529
|
|
516
|
-
.
|
517
|
-
|
530
|
+
:host(.ic-chip-light-text) .chip.filled.hovered:not(:focus-within) {
|
531
|
+
--chip-hover-bg: var(--ic-action-light-bg-hover);
|
532
|
+
}
|
533
|
+
|
534
|
+
:host(.ic-chip-light-text) .chip.filled:focus-within {
|
535
|
+
--chip-pressed-bg: var(--ic-action-light-bg-pressed);
|
536
|
+
}
|
537
|
+
|
538
|
+
.outlined {
|
539
|
+
color: var(--ic-chip-label);
|
540
|
+
border-color: var(--chip-custom-color, var(--ic-chip-outline));
|
541
|
+
padding: calc(var(--ic-space-xxs));
|
542
|
+
|
543
|
+
--ic-typography-color: var(--ic-chip-label);
|
518
544
|
}
|
519
545
|
|
520
546
|
.outlined.disabled {
|
521
547
|
border: var(--ic-border-disabled);
|
522
|
-
|
548
|
+
border-color: var(--ic-chip-outline-inactive);
|
523
549
|
}
|
524
550
|
|
525
551
|
.chip.disabled ic-typography {
|
526
|
-
--ic-typography-color: var(--ic-
|
527
|
-
}
|
528
|
-
|
529
|
-
.filled.disabled ic-typography {
|
530
|
-
--ic-typography-color: var(--ic-architectural-600);
|
552
|
+
--ic-typography-color: var(--ic-chip-label-inactive);
|
531
553
|
}
|
532
554
|
|
533
555
|
.dismiss-icon {
|
534
556
|
border: none;
|
535
557
|
border-radius: 50%;
|
536
558
|
padding: 0;
|
559
|
+
color: currentcolor;
|
537
560
|
background: none;
|
538
561
|
cursor: pointer;
|
539
562
|
margin: var(--ic-space-xxxs);
|
@@ -547,7 +570,7 @@ ic-tooltip:focus-within {
|
|
547
570
|
|
548
571
|
.dismiss-icon[disabled] {
|
549
572
|
pointer-events: none;
|
550
|
-
color: var(--ic-
|
573
|
+
color: var(--ic-chip-icon-inactive);
|
551
574
|
}
|
552
575
|
|
553
576
|
.icon {
|
@@ -563,32 +586,24 @@ ic-tooltip {
|
|
563
586
|
|
564
587
|
.chip.disabled path,
|
565
588
|
.chip.disabled ::slotted(svg) {
|
566
|
-
fill: var(--ic-
|
589
|
+
fill: var(--ic-chip-icon-inactive);
|
567
590
|
}
|
568
591
|
|
569
|
-
.
|
570
|
-
background-color: var(--ic-
|
592
|
+
.outlined.non-transparent {
|
593
|
+
background-color: var(--ic-chip-outline-background);
|
571
594
|
}
|
572
595
|
|
573
|
-
.chip.
|
574
|
-
background-
|
596
|
+
:host .chip.hovered:not(:focus-within) {
|
597
|
+
background-image: linear-gradient(var(--chip-hover-bg) 0 0);
|
598
|
+
}
|
599
|
+
|
600
|
+
:host .chip:focus-within {
|
601
|
+
background-image: linear-gradient(var(--chip-pressed-bg) 0 0);
|
575
602
|
}
|
576
603
|
|
577
604
|
@media (forced-colors: active) {
|
578
605
|
.chip {
|
579
|
-
border: var(--ic-hc
|
580
|
-
}
|
581
|
-
|
582
|
-
.filled.small {
|
583
|
-
padding: calc(var(--ic-space-xxxs) - var(--ic-space-1px));
|
584
|
-
}
|
585
|
-
|
586
|
-
.filled {
|
587
|
-
padding: calc(var(--ic-space-xxxs) + var(--ic-space-1px));
|
588
|
-
}
|
589
|
-
|
590
|
-
.filled.large {
|
591
|
-
padding: calc(var(--ic-space-xs) - var(--ic-space-1px));
|
606
|
+
border: var(--ic-border-hc);
|
592
607
|
}
|
593
608
|
|
594
609
|
.chip.disabled {
|
@@ -1,4 +1,4 @@
|
|
1
|
-
import { h, } from "@stencil/core";
|
1
|
+
import { h, Host, } from "@stencil/core";
|
2
2
|
import { onComponentRequiredPropUndefined, isSlotUsed, removeDisabledFalse, convertToRGBA, isElInAGGrid, } from "../../utils/helpers";
|
3
3
|
import dismissIcon from "../../assets/dismiss-icon.svg";
|
4
4
|
/**
|
@@ -21,10 +21,17 @@ export class Chip {
|
|
21
21
|
const colorRGBA = convertToRGBA(this.customColor);
|
22
22
|
if (colorRGBA) {
|
23
23
|
const { r, g, b, a } = colorRGBA;
|
24
|
-
|
25
|
-
|
24
|
+
this.customColorClass =
|
25
|
+
(r * 299 + g * 587 + b * 114) / 1000 > 133.3505
|
26
|
+
? "ic-chip-dark-text"
|
27
|
+
: "ic-chip-light-text";
|
28
|
+
this.el.setAttribute("style", `--chip-custom-color: rgba(${r}, ${g}, ${b}, ${a});`);
|
29
|
+
}
|
30
|
+
else {
|
31
|
+
this.customColorClass = "";
|
26
32
|
}
|
27
33
|
};
|
34
|
+
this.customColorClass = "";
|
28
35
|
this.hovered = false;
|
29
36
|
this.visible = true;
|
30
37
|
this.customColor = null;
|
@@ -32,19 +39,16 @@ export class Chip {
|
|
32
39
|
this.dismissible = false;
|
33
40
|
this.label = undefined;
|
34
41
|
this.size = "medium";
|
42
|
+
this.theme = "inherit";
|
35
43
|
this.transparentBackground = true;
|
36
44
|
this.variant = "filled";
|
37
45
|
}
|
38
46
|
customColorHandler() {
|
39
|
-
|
40
|
-
this.setChipColour();
|
41
|
-
}
|
47
|
+
this.setChipColour();
|
42
48
|
}
|
43
49
|
componentWillLoad() {
|
44
50
|
removeDisabledFalse(this.disabled, this.el);
|
45
|
-
|
46
|
-
this.setChipColour();
|
47
|
-
}
|
51
|
+
this.customColorHandler();
|
48
52
|
}
|
49
53
|
componentWillRender() {
|
50
54
|
if (isElInAGGrid(this.el)) {
|
@@ -65,16 +69,19 @@ export class Chip {
|
|
65
69
|
(_a = this.el.shadowRoot.querySelector("button")) === null || _a === void 0 ? void 0 : _a.focus();
|
66
70
|
}
|
67
71
|
render() {
|
68
|
-
const { label, variant, size, dismissible, visible, disabled, hovered } = this;
|
69
|
-
return (
|
72
|
+
const { label, variant, size, dismissible, visible, disabled, hovered, theme, customColorClass, } = this;
|
73
|
+
return (h(Host, { class: {
|
74
|
+
[`ic-theme-${theme}`]: theme !== "inherit",
|
75
|
+
[`${customColorClass}`]: variant === "filled" && customColorClass !== "",
|
76
|
+
} }, visible && (h("div", { class: {
|
70
77
|
chip: true,
|
71
78
|
[`${variant}`]: true,
|
72
79
|
[`${size}`]: true,
|
73
80
|
disabled,
|
74
81
|
dismissible,
|
75
82
|
hovered,
|
76
|
-
"
|
77
|
-
} }, isSlotUsed(this.el, "icon") && (h("div", { class: "icon" }, h("slot", { name: "icon" }))), h("ic-typography", { variant: "label", "apply-vertical-margins": false, class: { label: true, "in-ag-grid": this.inAGGrid } }, h("span", null, label)), dismissible && (h("ic-tooltip", { label: "Dismiss", target: "dismiss-icon", class: { "tooltip-disabled": disabled } }, h("button", { id: "dismiss-icon", class: "dismiss-icon", "aria-label": `Dismiss ${label} chip`, disabled: disabled, tabindex: disabled ? -1 : 0, onClick: this.dismissAction, onMouseEnter: this.mouseEnterHandler, onMouseLeave: this.mouseLeaveHandler, innerHTML: dismissIcon }))), isSlotUsed(this.el, "badge") && h("slot", { name: "badge" }))));
|
83
|
+
"non-transparent": this.variant === "outlined" && !this.transparentBackground,
|
84
|
+
} }, isSlotUsed(this.el, "icon") && (h("div", { class: "icon" }, h("slot", { name: "icon" }))), h("ic-typography", { variant: "label", "apply-vertical-margins": false, class: { label: true, "in-ag-grid": this.inAGGrid } }, h("span", null, label)), dismissible && (h("ic-tooltip", { label: "Dismiss", target: "dismiss-icon", class: { "tooltip-disabled": disabled } }, h("button", { id: "dismiss-icon", class: "dismiss-icon", "aria-label": `Dismiss ${label} chip`, disabled: disabled, tabindex: disabled ? -1 : 0, onClick: this.dismissAction, onMouseEnter: this.mouseEnterHandler, onMouseLeave: this.mouseLeaveHandler, innerHTML: dismissIcon }))), isSlotUsed(this.el, "badge") && h("slot", { name: "badge" })))));
|
78
85
|
}
|
79
86
|
static get is() { return "ic-chip"; }
|
80
87
|
static get encapsulation() { return "shadow"; }
|
@@ -109,7 +116,7 @@ export class Chip {
|
|
109
116
|
"optional": true,
|
110
117
|
"docs": {
|
111
118
|
"tags": [],
|
112
|
-
"text": "The custom chip colour. This
|
119
|
+
"text": "The custom chip colour. This will override the theme colour.\nCan be a hex value e.g. \"#ff0000\", RGB e.g. \"rgb(255, 0, 0)\", or RGBA e.g. \"rgba(255, 0, 0, 1)\"."
|
113
120
|
},
|
114
121
|
"attribute": "custom-color",
|
115
122
|
"reflect": false,
|
@@ -192,6 +199,24 @@ export class Chip {
|
|
192
199
|
"reflect": false,
|
193
200
|
"defaultValue": "\"medium\""
|
194
201
|
},
|
202
|
+
"theme": {
|
203
|
+
"type": "string",
|
204
|
+
"mutable": false,
|
205
|
+
"complexType": {
|
206
|
+
"original": "\"dark\" | \"light\" | \"inherit\"",
|
207
|
+
"resolved": "\"dark\" | \"inherit\" | \"light\"",
|
208
|
+
"references": {}
|
209
|
+
},
|
210
|
+
"required": false,
|
211
|
+
"optional": true,
|
212
|
+
"docs": {
|
213
|
+
"tags": [],
|
214
|
+
"text": "Sets the chip to the dark or light theme colors. \"inherit\" will set the color based on the system settings or ic-theme component.\nSetting the \"customColor\" prop will override this."
|
215
|
+
},
|
216
|
+
"attribute": "theme",
|
217
|
+
"reflect": false,
|
218
|
+
"defaultValue": "\"inherit\""
|
219
|
+
},
|
195
220
|
"transparentBackground": {
|
196
221
|
"type": "boolean",
|
197
222
|
"mutable": false,
|
@@ -204,7 +229,7 @@ export class Chip {
|
|
204
229
|
"optional": true,
|
205
230
|
"docs": {
|
206
231
|
"tags": [],
|
207
|
-
"text": "If `true`, the outlined variant of chip will have a transparent background rather than
|
232
|
+
"text": "If `true`, the outlined variant of chip will have a transparent background rather than the theme defined color."
|
208
233
|
},
|
209
234
|
"attribute": "transparent-background",
|
210
235
|
"reflect": false,
|
@@ -238,6 +263,7 @@ export class Chip {
|
|
238
263
|
}
|
239
264
|
static get states() {
|
240
265
|
return {
|
266
|
+
"customColorClass": {},
|
241
267
|
"hovered": {},
|
242
268
|
"visible": {}
|
243
269
|
};
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ic-chip.js","sourceRoot":"","sources":["../../../src/components/ic-chip/ic-chip.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,CAAC,EACD,IAAI,EACJ,KAAK,EACL,MAAM,EACN,KAAK,EAEL,OAAO,EACP,MAAM,EACN,KAAK,
|
1
|
+
{"version":3,"file":"ic-chip.js","sourceRoot":"","sources":["../../../src/components/ic-chip/ic-chip.tsx"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,CAAC,EACD,IAAI,EACJ,KAAK,EACL,MAAM,EACN,KAAK,EAEL,OAAO,EACP,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import {\n Component,\n h,\n Prop,\n State,\n Listen,\n Event,\n EventEmitter,\n Element,\n Method,\n Watch,\n Host,\n} from \"@stencil/core\";\nimport {\n onComponentRequiredPropUndefined,\n isSlotUsed,\n removeDisabledFalse,\n convertToRGBA,\n isElInAGGrid,\n} from \"../../utils/helpers\";\nimport { IcColor, IcEmphasisType, IcSizes } from \"../../utils/types\";\nimport dismissIcon from \"../../assets/dismiss-icon.svg\";\n\n/**\n * @slot icon - Content will be rendered at the start of the chip.\n * @slot badge - Badge component overlaying the top right of the chip.\n */\n@Component({\n tag: \"ic-chip\",\n styleUrl: \"ic-chip.css\",\n shadow: {\n delegatesFocus: true,\n },\n})\nexport class Chip {\n private inAGGrid: boolean = false;\n\n @Element() el: HTMLIcChipElement;\n\n @State() customColorClass: string = \"\";\n @State() hovered: boolean = false;\n @State() visible: boolean = true;\n\n /**\n * The custom chip colour. This will override the theme colour.\n * Can be a hex value e.g. \"#ff0000\", RGB e.g. \"rgb(255, 0, 0)\", or RGBA e.g. \"rgba(255, 0, 0, 1)\".\n */\n @Prop() customColor?: IcColor = null;\n\n @Watch(\"customColor\")\n customColorHandler(): void {\n this.setChipColour();\n }\n\n /**\n * If `true`, the chip will appear disabled.\n */\n @Prop() disabled?: boolean = false;\n\n /**\n * If `true`, the chip will have a close button at the end to dismiss it.\n */\n @Prop() dismissible?: boolean = false;\n\n /**\n * The text rendered within the chip.\n */\n @Prop() label!: string;\n\n /**\n * The size of the chip.\n */\n @Prop() size?: IcSizes = \"medium\";\n /**\n * Sets the chip to the dark or light theme colors. \"inherit\" will set the color based on the system settings or ic-theme component.\n * Setting the \"customColor\" prop will override this.\n */\n @Prop() theme?: \"dark\" | \"light\" | \"inherit\" = \"inherit\";\n\n /**\n * If `true`, the outlined variant of chip will have a transparent background rather than the theme defined color.\n */\n @Prop() transparentBackground?: boolean = true;\n\n /**\n * The emphasis of the chip.\n */\n @Prop() variant?: IcEmphasisType = \"filled\";\n\n /**\n * Is emitted when the user dismisses the chip.\n */\n @Event() icDismiss: EventEmitter<void>;\n\n componentWillLoad(): void {\n removeDisabledFalse(this.disabled, this.el);\n this.customColorHandler();\n }\n\n componentWillRender(): void {\n if (isElInAGGrid(this.el)) {\n this.inAGGrid = true;\n }\n }\n\n componentDidLoad(): void {\n onComponentRequiredPropUndefined(\n [{ prop: this.label, propName: \"label\" }],\n \"Chip\"\n );\n }\n\n @Listen(\"icDismiss\", { capture: true })\n handleClick(): void {\n this.visible = !this.visible;\n }\n\n /**\n * Sets focus on the chip.\n */\n @Method()\n async setFocus(): Promise<void> {\n this.el.shadowRoot.querySelector(\"button\")?.focus();\n }\n\n private dismissAction = (): void => {\n this.icDismiss.emit();\n };\n\n private mouseEnterHandler = (): void => {\n this.hovered = true;\n };\n\n private mouseLeaveHandler = (): void => {\n this.hovered = false;\n };\n\n private setChipColour = () => {\n const colorRGBA = convertToRGBA(this.customColor);\n if (colorRGBA) {\n const { r, g, b, a } = colorRGBA;\n this.customColorClass =\n (r * 299 + g * 587 + b * 114) / 1000 > 133.3505\n ? \"ic-chip-dark-text\"\n : \"ic-chip-light-text\";\n this.el.setAttribute(\n \"style\",\n `--chip-custom-color: rgba(${r}, ${g}, ${b}, ${a});`\n );\n } else {\n this.customColorClass = \"\";\n }\n };\n\n render() {\n const {\n label,\n variant,\n size,\n dismissible,\n visible,\n disabled,\n hovered,\n theme,\n customColorClass,\n } = this;\n\n return (\n <Host\n class={{\n [`ic-theme-${theme}`]: theme !== \"inherit\",\n [`${customColorClass}`]:\n variant === \"filled\" && customColorClass !== \"\",\n }}\n >\n {visible && (\n <div\n class={{\n chip: true,\n [`${variant}`]: true,\n [`${size}`]: true,\n disabled,\n dismissible,\n hovered,\n \"non-transparent\":\n this.variant === \"outlined\" && !this.transparentBackground,\n }}\n >\n {isSlotUsed(this.el, \"icon\") && (\n <div class=\"icon\">\n <slot name=\"icon\" />\n </div>\n )}\n <ic-typography\n variant=\"label\"\n apply-vertical-margins={false}\n class={{ label: true, \"in-ag-grid\": this.inAGGrid }}\n >\n <span>{label}</span>\n </ic-typography>\n {dismissible && (\n <ic-tooltip\n label=\"Dismiss\"\n target=\"dismiss-icon\"\n class={{ \"tooltip-disabled\": disabled }}\n >\n <button\n id=\"dismiss-icon\"\n class=\"dismiss-icon\"\n aria-label={`Dismiss ${label} chip`}\n disabled={disabled}\n tabindex={disabled ? -1 : 0}\n onClick={this.dismissAction}\n onMouseEnter={this.mouseEnterHandler}\n onMouseLeave={this.mouseLeaveHandler}\n innerHTML={dismissIcon}\n ></button>\n </ic-tooltip>\n )}\n {isSlotUsed(this.el, \"badge\") && <slot name=\"badge\"></slot>}\n </div>\n )}\n </Host>\n );\n }\n}\n"]}
|
@@ -79,6 +79,22 @@ describe("ic-chip component renders label", () => {
|
|
79
79
|
});
|
80
80
|
expect(page.root).toMatchSnapshot();
|
81
81
|
});
|
82
|
+
it("should render outlined variant", async () => {
|
83
|
+
const page = await newSpecPage({
|
84
|
+
components: [Chip],
|
85
|
+
html: `<ic-chip label="Label" variant="outlined">
|
86
|
+
</ic-chip>`,
|
87
|
+
});
|
88
|
+
expect(page.root).toMatchSnapshot();
|
89
|
+
});
|
90
|
+
it("should render outlined variant with solid-background", async () => {
|
91
|
+
const page = await newSpecPage({
|
92
|
+
components: [Chip],
|
93
|
+
html: `<ic-chip label="Label" variant="outlined" transparent-background="false">
|
94
|
+
</ic-chip>`,
|
95
|
+
});
|
96
|
+
expect(page.root).toMatchSnapshot();
|
97
|
+
});
|
82
98
|
it("should apply 'hovered' style when cursor is on dismiss button", async () => {
|
83
99
|
const page = await newSpecPage({
|
84
100
|
components: [Chip],
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"ic-chip.spec.js","sourceRoot":"","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CAAC,IAAI,CAAC,CAAC;IACf,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC","sourcesContent":["import { newSpecPage } from \"@stencil/core/testing\";\nimport { Chip } from \"../../ic-chip\";\nimport * as helpers from \"../../../../utils/helpers\";\n\ndescribe(\"ic-chip component renders label\", () => {\n it(\"should render static\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n</svg>\n </ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render dismissible\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" dismissible=\"true\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n</svg>\n </ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render disabled\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" dismissible=\"true\" disabled=\"true\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n</svg>\n </ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render small\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" dismissible=\"true\" size=\"small\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n </svg>\n </ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render with custom colour\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" custom-color=\"#F8C8DC\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n</svg>\n</ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render with custom rgb colour\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" custom-color=\"rgb(248,200,220)\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n</svg>\n</ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render with custom colour that sets white foreground text\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" custom-color=\"#00008B\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n</svg>\n</ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should apply 'hovered' style when cursor is on dismiss button\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip id=\"test-id\" label=\"Label\" dismissible=\"true\"></ic-chip>`,\n });\n\n expect(page.root).not.toBeNull;\n\n const chip = await document.getElementById(\"test-id\");\n\n const dismissButton = page.root.shadowRoot.querySelector(\"button\");\n\n await expect(chip.classList.contains(\"hovered\")).toBeFalsy;\n\n const event = new Event(\"mouseenter\", {\n bubbles: true,\n cancelable: true,\n });\n\n dismissButton.dispatchEvent(event);\n await page.waitForChanges();\n\n await expect(chip.classList.contains(\"hovered\")).toBeTruthy;\n });\n\n it(\"should lose 'hovered' style when cursor moves off dismiss button\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip id=\"test-id\" label=\"Label\" dismissible=\"true\"></ic-chip>`,\n });\n\n expect(page.root).not.toBeNull;\n\n const chip = await document.getElementById(\"test-id\");\n\n const dismissButton = page.root.shadowRoot.querySelector(\"button\");\n\n const enterEvent = new Event(\"mouseenter\", {\n bubbles: true,\n cancelable: true,\n });\n\n dismissButton.dispatchEvent(enterEvent);\n await page.waitForChanges();\n\n await expect(chip.classList.contains(\"hovered\")).toBeTruthy;\n\n const leaveEvent = new Event(\"mouseleave\", {\n bubbles: true,\n cancelable: true,\n });\n\n dismissButton.dispatchEvent(leaveEvent);\n\n await expect(chip.classList.contains(\"hovered\")).toBeFalsy;\n });\n\n it(\"should close on dismiss icon click\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"This is dismissible\" dismissible=\"true\"></ic-chip>`,\n });\n\n let chip = await page.root.shadowRoot.querySelector(\"div\");\n const dismissButton = await page.root.shadowRoot.querySelector(\"button\");\n\n expect(chip).not.toBeNull();\n expect(dismissButton).not.toBeNull();\n\n await dismissButton.click();\n\n await page.waitForChanges();\n chip = await page.root.shadowRoot.querySelector(\"div\");\n\n expect(chip).toBeNull();\n });\n\n it(\"should call 'setFocus' when chip is focused\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"This is dismissible\" dismissible=\"true\"></ic-chip>`,\n });\n\n //Can't expect anything in this test - this is to increase code coverage only\n await page.rootInstance.setFocus().toHaveBeenCalled;\n });\n\n it(\"should switch custom colour after initial render\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Default\" custom-color=\"#F8C8DC\"></ic-chip>`,\n });\n\n const chip = document.querySelector(\"ic-chip\");\n\n expect(page.rootInstance.customColor).toBe(\"#F8C8DC\");\n\n chip.customColor = \"#00008B\";\n await page.waitForChanges();\n\n expect(page.rootInstance.customColor).toBe(\"#00008B\");\n });\n\n it(\"should apply the correct class when in an AG Grid\", async () => {\n Object.defineProperty(helpers, \"isElInAGGrid\", {\n value: jest.fn().mockReturnValue(true),\n });\n\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Default\"></ic-chip>`,\n });\n\n await page.waitForChanges();\n\n expect(page.rootInstance.inAGGrid).toBe(true);\n expect(\n page.root.shadowRoot\n .querySelector(\"ic-typography\")\n .classList.contains(\"in-ag-grid\")\n ).toBe(true);\n });\n});\n"]}
|
1
|
+
{"version":3,"file":"ic-chip.spec.js","sourceRoot":"","sources":["../../../../../src/components/ic-chip/test/basic/ic-chip.spec.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AACrC,OAAO,KAAK,OAAO,MA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CAAC,IAAI,CAAC;YAClB,IAAI,EAAE,qCAAqC;SAC5C,CAAC,CAAC;QAEH,MAAM,IAAI,CAAC,cAAc,EAAE,CAAC;QAE5B,MAAM,CAAC,IAAI,CAAC,YAAY,CAAC,QAAQ,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;QAC9C,MAAM,CACJ,IAAI,CAAC,IAAI,CAAC,UAAU;aACjB,aAAa,CAAC,eAAe,CAAC;aAC9B,SAAS,CAAC,QAAQ,CAAC,YAAY,CAAC,CACpC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IACf,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC","sourcesContent":["import { newSpecPage } from \"@stencil/core/testing\";\nimport { Chip } from \"../../ic-chip\";\nimport * as helpers from \"../../../../utils/helpers\";\n\ndescribe(\"ic-chip component renders label\", () => {\n it(\"should render static\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n</svg>\n </ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render dismissible\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" dismissible=\"true\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n</svg>\n </ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render disabled\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" dismissible=\"true\" disabled=\"true\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n</svg>\n </ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render small\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" dismissible=\"true\" size=\"small\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n </svg>\n </ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render with custom colour\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" custom-color=\"#F8C8DC\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n</svg>\n</ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render with custom rgb colour\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" custom-color=\"rgb(248,200,220)\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n</svg>\n</ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render with custom colour that sets white foreground text\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" custom-color=\"#00008B\">\n <svg slot=\"icon\" width=\"20\" height=\"20\" viewBox=\"0 0 20 20\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M10 0C4.48 0 0 4.48 0 10C0 15.52 4.48 20 10 20C15.52 20 20 15.52 20 10C20 4.48 15.52 0 10 0ZM10 3C11.66 3 13 4.34 13 6C13 7.66 11.66 9 10 9C8.34 9 7 7.66 7 6C7 4.34 8.34 3 10 3ZM10 17.2C7.5 17.2 5.29 15.92 4 13.98C4.03 11.99 8 10.9 10 10.9C11.99 10.9 15.97 11.99 16 13.98C14.71 15.92 12.5 17.2 10 17.2Z\" fill=\"currentColor\"/>\n</svg>\n</ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render outlined variant\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" variant=\"outlined\">\n </ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should render outlined variant with solid-background\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Label\" variant=\"outlined\" transparent-background=\"false\">\n </ic-chip>`,\n });\n\n expect(page.root).toMatchSnapshot();\n });\n\n it(\"should apply 'hovered' style when cursor is on dismiss button\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip id=\"test-id\" label=\"Label\" dismissible=\"true\"></ic-chip>`,\n });\n\n expect(page.root).not.toBeNull;\n\n const chip = await document.getElementById(\"test-id\");\n\n const dismissButton = page.root.shadowRoot.querySelector(\"button\");\n\n await expect(chip.classList.contains(\"hovered\")).toBeFalsy;\n\n const event = new Event(\"mouseenter\", {\n bubbles: true,\n cancelable: true,\n });\n\n dismissButton.dispatchEvent(event);\n await page.waitForChanges();\n\n await expect(chip.classList.contains(\"hovered\")).toBeTruthy;\n });\n\n it(\"should lose 'hovered' style when cursor moves off dismiss button\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip id=\"test-id\" label=\"Label\" dismissible=\"true\"></ic-chip>`,\n });\n\n expect(page.root).not.toBeNull;\n\n const chip = await document.getElementById(\"test-id\");\n\n const dismissButton = page.root.shadowRoot.querySelector(\"button\");\n\n const enterEvent = new Event(\"mouseenter\", {\n bubbles: true,\n cancelable: true,\n });\n\n dismissButton.dispatchEvent(enterEvent);\n await page.waitForChanges();\n\n await expect(chip.classList.contains(\"hovered\")).toBeTruthy;\n\n const leaveEvent = new Event(\"mouseleave\", {\n bubbles: true,\n cancelable: true,\n });\n\n dismissButton.dispatchEvent(leaveEvent);\n\n await expect(chip.classList.contains(\"hovered\")).toBeFalsy;\n });\n\n it(\"should close on dismiss icon click\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"This is dismissible\" dismissible=\"true\"></ic-chip>`,\n });\n\n let chip = await page.root.shadowRoot.querySelector(\"div\");\n const dismissButton = await page.root.shadowRoot.querySelector(\"button\");\n\n expect(chip).not.toBeNull();\n expect(dismissButton).not.toBeNull();\n\n await dismissButton.click();\n\n await page.waitForChanges();\n chip = await page.root.shadowRoot.querySelector(\"div\");\n\n expect(chip).toBeNull();\n });\n\n it(\"should call 'setFocus' when chip is focused\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"This is dismissible\" dismissible=\"true\"></ic-chip>`,\n });\n\n //Can't expect anything in this test - this is to increase code coverage only\n await page.rootInstance.setFocus().toHaveBeenCalled;\n });\n\n it(\"should switch custom colour after initial render\", async () => {\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Default\" custom-color=\"#F8C8DC\"></ic-chip>`,\n });\n\n const chip = document.querySelector(\"ic-chip\");\n\n expect(page.rootInstance.customColor).toBe(\"#F8C8DC\");\n\n chip.customColor = \"#00008B\";\n await page.waitForChanges();\n\n expect(page.rootInstance.customColor).toBe(\"#00008B\");\n });\n\n it(\"should apply the correct class when in an AG Grid\", async () => {\n Object.defineProperty(helpers, \"isElInAGGrid\", {\n value: jest.fn().mockReturnValue(true),\n });\n\n const page = await newSpecPage({\n components: [Chip],\n html: `<ic-chip label=\"Default\"></ic-chip>`,\n });\n\n await page.waitForChanges();\n\n expect(page.rootInstance.inAGGrid).toBe(true);\n expect(\n page.root.shadowRoot\n .querySelector(\"ic-typography\")\n .classList.contains(\"in-ag-grid\")\n ).toBe(true);\n });\n});\n"]}
|
@@ -454,6 +454,22 @@ video {
|
|
454
454
|
z-index: var(--ic-z-index-classification-banner);
|
455
455
|
|
456
456
|
--ic-typography-color: currentcolor;
|
457
|
+
|
458
|
+
/* classification official */
|
459
|
+
--ic-color-classification-official: var(--ic-color-classification-blue);
|
460
|
+
--ic-color-classification-official-foreground: #fff;
|
461
|
+
|
462
|
+
/* classification secret */
|
463
|
+
--ic-color-classification-secret: var(--ic-color-classification-yellow);
|
464
|
+
--ic-color-classification-secret-foreground: #000;
|
465
|
+
|
466
|
+
/* classification top secret */
|
467
|
+
--ic-color-classification-top-secret: var(--ic-color-classification-red);
|
468
|
+
--ic-color-classification-top-secret-foreground: #fff;
|
469
|
+
|
470
|
+
/* classification not set */
|
471
|
+
--ic-color-classification-not-set: var(--ic-color-classification-grey);
|
472
|
+
--ic-color-classification-not-set-foreground: #fff;
|
457
473
|
}
|
458
474
|
|
459
475
|
:host(.ic-classification-banner-inline) {
|
@@ -471,24 +487,24 @@ video {
|
|
471
487
|
}
|
472
488
|
|
473
489
|
.default {
|
474
|
-
background-color: var(--ic-classification-not-set);
|
475
|
-
color: var(--ic-classification-not-set-foreground);
|
490
|
+
background-color: var(--ic-color-classification-not-set);
|
491
|
+
color: var(--ic-color-classification-not-set-foreground);
|
476
492
|
}
|
477
493
|
|
478
494
|
.official,
|
479
495
|
.official-sensitive {
|
480
|
-
background-color: var(--ic-classification-official);
|
481
|
-
color: var(--ic-classification-official-foreground);
|
496
|
+
background-color: var(--ic-color-classification-official);
|
497
|
+
color: var(--ic-color-classification-official-foreground);
|
482
498
|
}
|
483
499
|
|
484
500
|
.secret {
|
485
|
-
background-color: var(--ic-classification-secret);
|
486
|
-
color: var(--ic-classification-secret-foreground);
|
501
|
+
background-color: var(--ic-color-classification-secret);
|
502
|
+
color: var(--ic-color-classification-secret-foreground);
|
487
503
|
}
|
488
504
|
|
489
505
|
.top-secret {
|
490
|
-
background-color: var(--ic-classification-top-secret);
|
491
|
-
color: var(--ic-classification-top-secret-foreground);
|
506
|
+
background-color: var(--ic-color-classification-top-secret);
|
507
|
+
color: var(--ic-color-classification-top-secret-foreground);
|
492
508
|
}
|
493
509
|
|
494
510
|
.offscreen {
|
@@ -501,6 +517,6 @@ video {
|
|
501
517
|
|
502
518
|
@media (forced-colors: active) {
|
503
519
|
.classification-banner {
|
504
|
-
border: var(--ic-hc
|
520
|
+
border: var(--ic-border-hc);
|
505
521
|
}
|
506
522
|
}
|
@@ -3,9 +3,9 @@ hr {
|
|
3
3
|
margin: 0;
|
4
4
|
border: none;
|
5
5
|
height: var(--ic-space-1px);
|
6
|
-
background-color: var(--ic-keyline-darken
|
6
|
+
background-color: var(--ic-color-keyline-darken);
|
7
7
|
}
|
8
8
|
|
9
9
|
hr.light {
|
10
|
-
background-color: var(--ic-keyline-lighten
|
10
|
+
background-color: var(--ic-color-keyline-lighten);
|
11
11
|
}
|
@@ -462,13 +462,13 @@ video {
|
|
462
462
|
:host(.ic-footer-foreground-light) {
|
463
463
|
--footer-theme-secondary: var(--ic-theme-secondary);
|
464
464
|
--footer-theme-tertiary: var(--ic-theme-tertiary);
|
465
|
-
--footer-keyline: var(--ic-keyline-lighten);
|
465
|
+
--footer-keyline: var(--ic-border-keyline-lighten);
|
466
466
|
}
|
467
467
|
|
468
468
|
:host(.ic-footer-foreground-dark) {
|
469
469
|
--footer-theme-secondary: var(--ic-theme-secondary-light);
|
470
470
|
--footer-theme-tertiary: var(--ic-theme-tertiary-light);
|
471
|
-
--footer-keyline: var(--ic-keyline-darken);
|
471
|
+
--footer-keyline: var(--ic-border-keyline-darken);
|
472
472
|
}
|
473
473
|
|
474
474
|
:host(.ic-footer-small.ic-footer-ungrouped) {
|
@@ -545,6 +545,6 @@ footer {
|
|
545
545
|
|
546
546
|
@media (forced-colors: active) {
|
547
547
|
footer {
|
548
|
-
border-top: var(--ic-hc
|
548
|
+
border-top: var(--ic-border-hc);
|
549
549
|
}
|
550
550
|
}
|