wcs-core 7.0.0 → 7.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/design-tokens/dist/sncf-holding-root-scoped.css +589 -0
- package/design-tokens/dist/sncf-holding.css +13 -0
- package/design-tokens/dist/sncf-holding.json +54 -0
- package/design-tokens/dist/sncf-reseau-root-scoped.css +652 -0
- package/design-tokens/dist/sncf-reseau.css +10 -0
- package/design-tokens/dist/sncf-reseau.json +54 -0
- package/design-tokens/dist/sncf-voyageurs-root-scoped.css +550 -0
- package/design-tokens/dist/sncf-voyageurs.css +13 -0
- package/design-tokens/dist/sncf-voyageurs.json +54 -0
- package/dist/cjs/{com-nav-utils-9f6c99b8.js → com-nav-utils-ff4f0bef.js} +2 -2
- package/dist/cjs/{com-nav-utils-9f6c99b8.js.map → com-nav-utils-ff4f0bef.js.map} +1 -1
- package/dist/cjs/control-component-interface-d9b68f28.js +43 -0
- package/dist/cjs/control-component-interface-d9b68f28.js.map +1 -0
- package/dist/cjs/{grid-pagination-2c752b22.js → grid-pagination-e4f29c78.js} +3 -3
- package/dist/cjs/{grid-pagination-2c752b22.js.map → grid-pagination-e4f29c78.js.map} +1 -1
- package/dist/cjs/{helpers-871f5a3d.js → helpers-2f1a8ddc.js} +44 -1
- package/dist/cjs/helpers-2f1a8ddc.js.map +1 -0
- package/dist/cjs/{keyboard-event-d2c81ce0.js → keyboard-event-40ecdc27.js} +2 -2
- package/dist/cjs/{keyboard-event-d2c81ce0.js.map → keyboard-event-40ecdc27.js.map} +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/wcs-accordion-panel.cjs.entry.js +1 -1
- package/dist/cjs/wcs-action-bar.cjs.entry.js +1 -1
- package/dist/cjs/wcs-action-bar.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-badge.cjs.entry.js +1 -1
- package/dist/cjs/wcs-badge.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-breadcrumb.cjs.entry.js +1 -1
- package/dist/cjs/wcs-button_2.cjs.entry.js +3 -3
- package/dist/cjs/wcs-button_2.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-checkbox.cjs.entry.js +6 -2
- package/dist/cjs/wcs-checkbox.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-com-nav-category.cjs.entry.js +2 -2
- package/dist/cjs/wcs-com-nav-item.cjs.entry.js +1 -1
- package/dist/cjs/wcs-com-nav-item.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-com-nav-submenu.cjs.entry.js +2 -2
- package/dist/cjs/wcs-com-nav.cjs.entry.js +2 -2
- package/dist/cjs/wcs-counter.cjs.entry.js +13 -5
- package/dist/cjs/wcs-counter.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-dropdown-item.cjs.entry.js +1 -1
- package/dist/cjs/wcs-dropdown.cjs.entry.js +3 -3
- package/dist/cjs/wcs-dropdown.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-editable-field.cjs.entry.js +81 -55
- package/dist/cjs/wcs-editable-field.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-error_3.cjs.entry.js +209 -0
- package/dist/cjs/wcs-error_3.cjs.entry.js.map +1 -0
- package/dist/cjs/wcs-field-content.cjs.entry.js +1 -1
- package/dist/cjs/wcs-field-label.cjs.entry.js +1 -1
- package/dist/cjs/wcs-field.cjs.entry.js +1 -1
- package/dist/cjs/wcs-footer.cjs.entry.js +1 -1
- package/dist/cjs/wcs-footer.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-galactic-menu.cjs.entry.js +4 -4
- package/dist/cjs/wcs-galactic-menu.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-galactic.cjs.entry.js +1 -1
- package/dist/cjs/wcs-grid-column.cjs.entry.js +2 -2
- package/dist/cjs/wcs-grid-column.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-grid-custom-cell.cjs.entry.js +1 -1
- package/dist/cjs/wcs-grid-pagination.cjs.entry.js +2 -2
- package/dist/cjs/wcs-grid.cjs.entry.js +6 -6
- package/dist/cjs/wcs-header.cjs.entry.js +2 -2
- package/dist/cjs/wcs-hint.cjs.entry.js +1 -1
- package/dist/cjs/wcs-horizontal-stepper.cjs.entry.js +1 -1
- package/dist/cjs/wcs-icon.cjs.entry.js +2 -2
- package/dist/cjs/wcs-input.cjs.entry.js +5 -3
- package/dist/cjs/wcs-input.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-list-item-properties.cjs.entry.js +1 -1
- package/dist/cjs/wcs-list-item-property.cjs.entry.js +1 -1
- package/dist/cjs/wcs-list-item.cjs.entry.js +1 -1
- package/dist/cjs/wcs-list-item.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-mat-icon.cjs.entry.js +2 -2
- package/dist/cjs/wcs-modal.cjs.entry.js +17 -3
- package/dist/cjs/wcs-modal.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-native-select.cjs.entry.js +1 -1
- package/dist/cjs/wcs-nav-item.cjs.entry.js +3 -3
- package/dist/cjs/wcs-nav-item.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-nav.cjs.entry.js +2 -2
- package/dist/cjs/wcs-progress-bar.cjs.entry.js +3 -3
- package/dist/cjs/wcs-progress-radial.cjs.entry.js +3 -3
- package/dist/cjs/wcs-radio-group.cjs.entry.js +5 -2
- package/dist/cjs/wcs-radio-group.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-radio.cjs.entry.js +2 -2
- package/dist/cjs/wcs-radio.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-select_2.cjs.entry.js +8 -7
- package/dist/cjs/wcs-select_2.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-skeleton-circle.cjs.entry.js +1 -1
- package/dist/cjs/wcs-skeleton-rectangle.cjs.entry.js +1 -1
- package/dist/cjs/wcs-skeleton-text.cjs.entry.js +1 -1
- package/dist/cjs/wcs-switch.cjs.entry.js +6 -2
- package/dist/cjs/wcs-switch.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-tab.cjs.entry.js +1 -1
- package/dist/cjs/wcs-tabs.cjs.entry.js +2 -2
- package/dist/cjs/wcs-tabs.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-textarea.cjs.entry.js +2 -2
- package/dist/cjs/wcs-textarea.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-tooltip.cjs.entry.js +8 -4
- package/dist/cjs/wcs-tooltip.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs.cjs.js +1 -1
- package/dist/collection/components/action-bar/action-bar.js +2 -2
- package/dist/collection/components/action-bar/action-bar.js.map +1 -1
- package/dist/collection/components/badge/badge.css +1 -0
- package/dist/collection/components/button/button.js +2 -2
- package/dist/collection/components/button/button.js.map +1 -1
- package/dist/collection/components/checkbox/checkbox.js +22 -1
- package/dist/collection/components/checkbox/checkbox.js.map +1 -1
- package/dist/collection/components/com-nav-item/com-nav-item.css +2 -1
- package/dist/collection/components/counter/counter.css +3 -0
- package/dist/collection/components/counter/counter.js +13 -5
- package/dist/collection/components/counter/counter.js.map +1 -1
- package/dist/collection/components/dropdown/dropdown.js +2 -2
- package/dist/collection/components/dropdown/dropdown.js.map +1 -1
- package/dist/collection/components/editable-field/editable-field.css +31 -10
- package/dist/collection/components/editable-field/editable-field.e2e.js +176 -0
- package/dist/collection/components/editable-field/editable-field.e2e.js.map +1 -0
- package/dist/collection/components/editable-field/editable-field.js +83 -57
- package/dist/collection/components/editable-field/editable-field.js.map +1 -1
- package/dist/collection/components/error/error.js +1 -1
- package/dist/collection/components/field/field.js +1 -1
- package/dist/collection/components/field-content/field-content.js +1 -1
- package/dist/collection/components/field-label/field-label.js +1 -1
- package/dist/collection/components/footer/footer.js +1 -1
- package/dist/collection/components/footer/footer.js.map +1 -1
- package/dist/collection/components/form-field/form-field.css +39 -12
- package/dist/collection/components/form-field/form-field.e2e.js +122 -0
- package/dist/collection/components/form-field/form-field.e2e.js.map +1 -0
- package/dist/collection/components/form-field/form-field.js +29 -12
- package/dist/collection/components/form-field/form-field.js.map +1 -1
- package/dist/collection/components/galactic/galactic.js +1 -1
- package/dist/collection/components/galactic-menu/galactic-menu.css +1 -0
- package/dist/collection/components/galactic-menu/galactic-menu.js +2 -2
- package/dist/collection/components/grid/grid.js +3 -3
- package/dist/collection/components/grid-column/grid-column.js +2 -2
- package/dist/collection/components/grid-column/grid-column.js.map +1 -1
- package/dist/collection/components/grid-custom-cell/grid-custom-cell.js +1 -1
- package/dist/collection/components/grid-pagination/grid-pagination.js +1 -1
- package/dist/collection/components/header/header.js +1 -1
- package/dist/collection/components/hint/hint.js +1 -1
- package/dist/collection/components/horizontal-stepper/horizontal-stepper.js +1 -1
- package/dist/collection/components/icon/icon.js +1 -1
- package/dist/collection/components/input/input.css +10 -1
- package/dist/collection/components/input/input.js +42 -3
- package/dist/collection/components/input/input.js.map +1 -1
- package/dist/collection/components/label/label.js +1 -1
- package/dist/collection/components/list-item/list-item.js +7 -2
- package/dist/collection/components/list-item/list-item.js.map +1 -1
- package/dist/collection/components/list-item-properties/list-item-properties.js +1 -1
- package/dist/collection/components/list-item-property/list-item-property.js +1 -1
- package/dist/collection/components/mat-icon/mat-icon.js +1 -1
- package/dist/collection/components/modal/modal.js +58 -2
- package/dist/collection/components/modal/modal.js.map +1 -1
- package/dist/collection/components/native-select/native-select.js +1 -1
- package/dist/collection/components/nav/nav.js +1 -1
- package/dist/collection/components/nav-item/nav-item.css +24 -6
- package/dist/collection/components/nav-item/nav-item.js +1 -1
- package/dist/collection/components/progress-bar/progress-bar.js +2 -2
- package/dist/collection/components/progress-radial/progress-radial.js +2 -2
- package/dist/collection/components/radio/radio.js +2 -2
- package/dist/collection/components/radio/radio.js.map +1 -1
- package/dist/collection/components/radio-group/radio-group.js +39 -2
- package/dist/collection/components/radio-group/radio-group.js.map +1 -1
- package/dist/collection/components/select/select.js +22 -3
- package/dist/collection/components/select/select.js.map +1 -1
- package/dist/collection/components/select-option/select-option.js +2 -2
- package/dist/collection/components/skeleton-circle/skeleton-circle.js +1 -1
- package/dist/collection/components/skeleton-rectangle/skeleton-rectangle.js +1 -1
- package/dist/collection/components/skeleton-text/skeleton-text.js +1 -1
- package/dist/collection/components/spinner/spinner.js +1 -1
- package/dist/collection/components/switch/switch.js +23 -2
- package/dist/collection/components/switch/switch.js.map +1 -1
- package/dist/collection/components/tab/tab.js +1 -1
- package/dist/collection/components/tabs/tabs.js +2 -2
- package/dist/collection/components/tabs/tabs.js.map +1 -1
- package/dist/collection/components/textarea/textarea.js +3 -3
- package/dist/collection/components/textarea/textarea.js.map +1 -1
- package/dist/collection/components/tooltip/tooltip.js +10 -8
- package/dist/collection/components/tooltip/tooltip.js.map +1 -1
- package/dist/collection/utils/control-component-interface.js +37 -0
- package/dist/collection/utils/control-component-interface.js.map +1 -0
- package/dist/collection/utils/helpers.js +40 -0
- package/dist/collection/utils/helpers.js.map +1 -1
- package/dist/esm/{com-nav-utils-1366c701.js → com-nav-utils-ee7bf77c.js} +2 -2
- package/dist/esm/{com-nav-utils-1366c701.js.map → com-nav-utils-ee7bf77c.js.map} +1 -1
- package/dist/esm/control-component-interface-9f09e520.js +40 -0
- package/dist/esm/control-component-interface-9f09e520.js.map +1 -0
- package/dist/esm/{grid-pagination-421689be.js → grid-pagination-976a86e9.js} +3 -3
- package/dist/esm/{grid-pagination-421689be.js.map → grid-pagination-976a86e9.js.map} +1 -1
- package/dist/esm/{helpers-f137ec8d.js → helpers-ece6a2d3.js} +42 -2
- package/dist/esm/helpers-ece6a2d3.js.map +1 -0
- package/dist/esm/{keyboard-event-bdea408a.js → keyboard-event-26b65ae5.js} +2 -2
- package/dist/esm/{keyboard-event-bdea408a.js.map → keyboard-event-26b65ae5.js.map} +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/wcs-accordion-panel.entry.js +1 -1
- package/dist/esm/wcs-action-bar.entry.js +1 -1
- package/dist/esm/wcs-action-bar.entry.js.map +1 -1
- package/dist/esm/wcs-badge.entry.js +1 -1
- package/dist/esm/wcs-badge.entry.js.map +1 -1
- package/dist/esm/wcs-breadcrumb.entry.js +1 -1
- package/dist/esm/wcs-button_2.entry.js +3 -3
- package/dist/esm/wcs-button_2.entry.js.map +1 -1
- package/dist/esm/wcs-checkbox.entry.js +6 -2
- package/dist/esm/wcs-checkbox.entry.js.map +1 -1
- package/dist/esm/wcs-com-nav-category.entry.js +2 -2
- package/dist/esm/wcs-com-nav-item.entry.js +1 -1
- package/dist/esm/wcs-com-nav-item.entry.js.map +1 -1
- package/dist/esm/wcs-com-nav-submenu.entry.js +2 -2
- package/dist/esm/wcs-com-nav.entry.js +2 -2
- package/dist/esm/wcs-counter.entry.js +13 -5
- package/dist/esm/wcs-counter.entry.js.map +1 -1
- package/dist/esm/wcs-dropdown-item.entry.js +1 -1
- package/dist/esm/wcs-dropdown.entry.js +3 -3
- package/dist/esm/wcs-dropdown.entry.js.map +1 -1
- package/dist/esm/wcs-editable-field.entry.js +81 -55
- package/dist/esm/wcs-editable-field.entry.js.map +1 -1
- package/dist/esm/wcs-error_3.entry.js +203 -0
- package/dist/esm/wcs-error_3.entry.js.map +1 -0
- package/dist/esm/wcs-field-content.entry.js +1 -1
- package/dist/esm/wcs-field-label.entry.js +1 -1
- package/dist/esm/wcs-field.entry.js +1 -1
- package/dist/esm/wcs-footer.entry.js +1 -1
- package/dist/esm/wcs-footer.entry.js.map +1 -1
- package/dist/esm/wcs-galactic-menu.entry.js +4 -4
- package/dist/esm/wcs-galactic-menu.entry.js.map +1 -1
- package/dist/esm/wcs-galactic.entry.js +1 -1
- package/dist/esm/wcs-grid-column.entry.js +2 -2
- package/dist/esm/wcs-grid-column.entry.js.map +1 -1
- package/dist/esm/wcs-grid-custom-cell.entry.js +1 -1
- package/dist/esm/wcs-grid-pagination.entry.js +2 -2
- package/dist/esm/wcs-grid.entry.js +6 -6
- package/dist/esm/wcs-header.entry.js +2 -2
- package/dist/esm/wcs-hint.entry.js +1 -1
- package/dist/esm/wcs-horizontal-stepper.entry.js +1 -1
- package/dist/esm/wcs-icon.entry.js +2 -2
- package/dist/esm/wcs-input.entry.js +5 -3
- package/dist/esm/wcs-input.entry.js.map +1 -1
- package/dist/esm/wcs-list-item-properties.entry.js +1 -1
- package/dist/esm/wcs-list-item-property.entry.js +1 -1
- package/dist/esm/wcs-list-item.entry.js +1 -1
- package/dist/esm/wcs-list-item.entry.js.map +1 -1
- package/dist/esm/wcs-mat-icon.entry.js +2 -2
- package/dist/esm/wcs-modal.entry.js +17 -3
- package/dist/esm/wcs-modal.entry.js.map +1 -1
- package/dist/esm/wcs-native-select.entry.js +1 -1
- package/dist/esm/wcs-nav-item.entry.js +3 -3
- package/dist/esm/wcs-nav-item.entry.js.map +1 -1
- package/dist/esm/wcs-nav.entry.js +2 -2
- package/dist/esm/wcs-progress-bar.entry.js +3 -3
- package/dist/esm/wcs-progress-radial.entry.js +3 -3
- package/dist/esm/wcs-radio-group.entry.js +5 -2
- package/dist/esm/wcs-radio-group.entry.js.map +1 -1
- package/dist/esm/wcs-radio.entry.js +2 -2
- package/dist/esm/wcs-radio.entry.js.map +1 -1
- package/dist/esm/wcs-select_2.entry.js +8 -7
- package/dist/esm/wcs-select_2.entry.js.map +1 -1
- package/dist/esm/wcs-skeleton-circle.entry.js +1 -1
- package/dist/esm/wcs-skeleton-rectangle.entry.js +1 -1
- package/dist/esm/wcs-skeleton-text.entry.js +1 -1
- package/dist/esm/wcs-switch.entry.js +6 -2
- package/dist/esm/wcs-switch.entry.js.map +1 -1
- package/dist/esm/wcs-tab.entry.js +1 -1
- package/dist/esm/wcs-tabs.entry.js +2 -2
- package/dist/esm/wcs-tabs.entry.js.map +1 -1
- package/dist/esm/wcs-textarea.entry.js +2 -2
- package/dist/esm/wcs-textarea.entry.js.map +1 -1
- package/dist/esm/wcs-tooltip.entry.js +8 -4
- package/dist/esm/wcs-tooltip.entry.js.map +1 -1
- package/dist/esm/wcs.js +1 -1
- package/dist/types/components/checkbox/checkbox.d.ts +3 -1
- package/dist/types/components/counter/counter.d.ts +6 -0
- package/dist/types/components/editable-field/editable-field.d.ts +23 -9
- package/dist/types/components/input/input.d.ts +3 -0
- package/dist/types/components/list-item/list-item.d.ts +5 -0
- package/dist/types/components/modal/modal.d.ts +23 -0
- package/dist/types/components/radio-group/radio-group.d.ts +3 -1
- package/dist/types/components/select/select.d.ts +4 -0
- package/dist/types/components/switch/switch.d.ts +3 -1
- package/dist/types/components/tooltip/tooltip.d.ts +3 -5
- package/dist/types/components.d.ts +87 -16
- package/dist/types/utils/control-component-interface.d.ts +22 -0
- package/dist/types/utils/helpers.d.ts +21 -0
- package/dist/wcs/p-0017d766.js +2 -0
- package/dist/wcs/{p-45a6934d.entry.js → p-0ffdfc10.entry.js} +2 -2
- package/dist/wcs/{p-9f23c49e.entry.js → p-13090618.entry.js} +2 -2
- package/dist/wcs/{p-8f0e093f.entry.js → p-13e50077.entry.js} +2 -2
- package/dist/wcs/p-1438530e.entry.js +2 -0
- package/dist/wcs/p-1438530e.entry.js.map +1 -0
- package/dist/wcs/{p-2305f257.entry.js → p-16dd21cf.entry.js} +2 -2
- package/dist/wcs/{p-85a5bbb7.entry.js → p-206c01d5.entry.js} +2 -2
- package/dist/wcs/{p-85a5bbb7.entry.js.map → p-206c01d5.entry.js.map} +1 -1
- package/dist/wcs/{p-09d0a296.entry.js → p-21b964cd.entry.js} +3 -3
- package/dist/wcs/p-21b964cd.entry.js.map +1 -0
- package/dist/wcs/p-21d2f06f.entry.js +2 -0
- package/dist/wcs/p-21d2f06f.entry.js.map +1 -0
- package/dist/wcs/{p-2add4d4d.entry.js → p-258855a1.entry.js} +2 -2
- package/dist/wcs/{p-2c9e20c1.entry.js → p-294732f7.entry.js} +2 -2
- package/dist/wcs/{p-15ff9f93.entry.js → p-29f5b974.entry.js} +2 -2
- package/dist/wcs/{p-1ab0d13b.entry.js → p-2adf00be.entry.js} +2 -2
- package/dist/wcs/p-2adf00be.entry.js.map +1 -0
- package/dist/wcs/p-37800935.entry.js +2 -0
- package/dist/wcs/{p-76f07dbd.entry.js → p-388e6d75.entry.js} +2 -2
- package/dist/wcs/{p-8bd1b9ce.entry.js → p-43d70995.entry.js} +2 -2
- package/dist/wcs/{p-9553d60e.entry.js → p-4661290b.entry.js} +2 -2
- package/dist/wcs/{p-9553d60e.entry.js.map → p-4661290b.entry.js.map} +1 -1
- package/dist/wcs/{p-d2a4f609.entry.js → p-4dc52a25.entry.js} +2 -2
- package/dist/wcs/{p-25b96cde.entry.js → p-50523b53.entry.js} +2 -2
- package/dist/wcs/p-50523b53.entry.js.map +1 -0
- package/dist/wcs/p-52d77e1f.js +2 -0
- package/dist/wcs/p-52d77e1f.js.map +1 -0
- package/dist/wcs/p-5974be61.entry.js +2 -0
- package/dist/wcs/p-5974be61.entry.js.map +1 -0
- package/dist/wcs/{p-0fa370d7.entry.js → p-5bf73e05.entry.js} +3 -3
- package/dist/wcs/{p-0fa370d7.entry.js.map → p-5bf73e05.entry.js.map} +1 -1
- package/dist/wcs/{p-e19308cf.entry.js → p-5d5f50ed.entry.js} +2 -2
- package/dist/wcs/{p-94ff8939.entry.js → p-5de993d7.entry.js} +2 -2
- package/dist/wcs/p-5de993d7.entry.js.map +1 -0
- package/dist/wcs/{p-a788b5bd.entry.js → p-619e1110.entry.js} +2 -2
- package/dist/wcs/{p-9e03b379.entry.js → p-694724a2.entry.js} +2 -2
- package/dist/wcs/{p-f8d2be83.entry.js → p-6b06d2e7.entry.js} +2 -2
- package/dist/wcs/p-6f5d570a.entry.js +2 -0
- package/dist/wcs/p-6f5d570a.entry.js.map +1 -0
- package/dist/wcs/p-71db0ed5.entry.js +2 -0
- package/dist/wcs/{p-209145de.entry.js → p-76c92e22.entry.js} +2 -2
- package/dist/wcs/{p-f06aa79d.entry.js → p-796e690d.entry.js} +2 -2
- package/dist/wcs/{p-f06aa79d.entry.js.map → p-796e690d.entry.js.map} +1 -1
- package/dist/wcs/{p-97cbbcfc.entry.js → p-7d665a7e.entry.js} +2 -2
- package/dist/wcs/p-89b8c724.js +2 -0
- package/dist/wcs/{p-412b0021.js → p-8fcceaf1.js} +2 -2
- package/dist/wcs/p-9243a323.entry.js +2 -0
- package/dist/wcs/p-9243a323.entry.js.map +1 -0
- package/dist/wcs/p-94aa269f.entry.js +2 -0
- package/dist/wcs/p-94aa269f.entry.js.map +1 -0
- package/dist/wcs/{p-87b69cac.entry.js → p-9554196c.entry.js} +2 -2
- package/dist/wcs/{p-80a23f9c.entry.js → p-96bff8fe.entry.js} +2 -2
- package/dist/wcs/{p-80a23f9c.entry.js.map → p-96bff8fe.entry.js.map} +1 -1
- package/dist/wcs/{p-fa507e06.entry.js → p-9ad23e83.entry.js} +2 -2
- package/dist/wcs/{p-5ea2aba5.entry.js → p-9c012aae.entry.js} +2 -2
- package/dist/wcs/p-9dc3f9a5.entry.js +2 -0
- package/dist/wcs/p-9dc3f9a5.entry.js.map +1 -0
- package/dist/wcs/p-9eb66fa9.entry.js +2 -0
- package/dist/wcs/p-a7468a3a.js +2 -0
- package/dist/wcs/p-a7468a3a.js.map +1 -0
- package/dist/wcs/{p-4982f96c.entry.js → p-a7891233.entry.js} +2 -2
- package/dist/wcs/p-b2080509.entry.js +2 -0
- package/dist/wcs/{p-806315e6.entry.js.map → p-b2080509.entry.js.map} +1 -1
- package/dist/wcs/p-b96f4921.entry.js +2 -0
- package/dist/wcs/p-b96f4921.entry.js.map +1 -0
- package/dist/wcs/{p-276b8125.entry.js → p-c2d35aa6.entry.js} +3 -3
- package/dist/wcs/{p-276b8125.entry.js.map → p-c2d35aa6.entry.js.map} +1 -1
- package/dist/wcs/p-c752b85a.entry.js +2 -0
- package/dist/wcs/{p-b0f8190f.entry.js → p-d895ffb4.entry.js} +2 -2
- package/dist/wcs/{p-1e5aa960.entry.js → p-d9525519.entry.js} +2 -2
- package/dist/wcs/p-d9525519.entry.js.map +1 -0
- package/dist/wcs/{p-db81b74f.entry.js → p-da4636fa.entry.js} +2 -2
- package/dist/wcs/p-da4636fa.entry.js.map +1 -0
- package/dist/wcs/p-dd60a6db.entry.js +2 -0
- package/dist/wcs/p-dd60a6db.entry.js.map +1 -0
- package/dist/wcs/p-dddcd685.entry.js +2 -0
- package/dist/wcs/p-dddcd685.entry.js.map +1 -0
- package/dist/wcs/p-e36b2ad1.entry.js +2 -0
- package/dist/wcs/p-f87636f6.entry.js +2 -0
- package/dist/wcs/p-f87636f6.entry.js.map +1 -0
- package/dist/wcs/p-fc115de4.entry.js +2 -0
- package/dist/wcs/wcs.esm.js +1 -1
- package/dist/wcs/wcs.esm.js.map +1 -1
- package/package.json +1 -1
- package/dist/cjs/helpers-871f5a3d.js.map +0 -1
- package/dist/cjs/wcs-error_2.cjs.entry.js +0 -168
- package/dist/cjs/wcs-error_2.cjs.entry.js.map +0 -1
- package/dist/cjs/wcs-label.cjs.entry.js +0 -33
- package/dist/cjs/wcs-label.cjs.entry.js.map +0 -1
- package/dist/esm/helpers-f137ec8d.js.map +0 -1
- package/dist/esm/wcs-error_2.entry.js +0 -163
- package/dist/esm/wcs-error_2.entry.js.map +0 -1
- package/dist/esm/wcs-label.entry.js +0 -29
- package/dist/esm/wcs-label.entry.js.map +0 -1
- package/dist/wcs/p-08e86d69.entry.js +0 -2
- package/dist/wcs/p-08e86d69.entry.js.map +0 -1
- package/dist/wcs/p-09d0a296.entry.js.map +0 -1
- package/dist/wcs/p-0fdaec9e.entry.js +0 -2
- package/dist/wcs/p-0fdaec9e.entry.js.map +0 -1
- package/dist/wcs/p-19c77b5c.entry.js +0 -2
- package/dist/wcs/p-1ab0d13b.entry.js.map +0 -1
- package/dist/wcs/p-1e5aa960.entry.js.map +0 -1
- package/dist/wcs/p-25b96cde.entry.js.map +0 -1
- package/dist/wcs/p-400a71d7.entry.js +0 -2
- package/dist/wcs/p-4ca7c59f.entry.js +0 -2
- package/dist/wcs/p-4ca7c59f.entry.js.map +0 -1
- package/dist/wcs/p-4d6d1d14.js +0 -2
- package/dist/wcs/p-52cd0abb.entry.js +0 -2
- package/dist/wcs/p-52cd0abb.entry.js.map +0 -1
- package/dist/wcs/p-5f517eb5.entry.js +0 -2
- package/dist/wcs/p-806315e6.entry.js +0 -2
- package/dist/wcs/p-8780a429.entry.js +0 -2
- package/dist/wcs/p-8780a429.entry.js.map +0 -1
- package/dist/wcs/p-94ff8939.entry.js.map +0 -1
- package/dist/wcs/p-985c4cf2.entry.js +0 -2
- package/dist/wcs/p-985c4cf2.entry.js.map +0 -1
- package/dist/wcs/p-a3aece7a.js +0 -2
- package/dist/wcs/p-a3aece7a.js.map +0 -1
- package/dist/wcs/p-a66a4289.entry.js +0 -2
- package/dist/wcs/p-bf31245c.entry.js +0 -2
- package/dist/wcs/p-bf31245c.entry.js.map +0 -1
- package/dist/wcs/p-cd592a00.entry.js +0 -2
- package/dist/wcs/p-cd592a00.entry.js.map +0 -1
- package/dist/wcs/p-d42831b2.entry.js +0 -2
- package/dist/wcs/p-d42831b2.entry.js.map +0 -1
- package/dist/wcs/p-d7acbf01.js +0 -2
- package/dist/wcs/p-db81b74f.entry.js.map +0 -1
- package/dist/wcs/p-dbbf0980.entry.js +0 -2
- package/dist/wcs/p-dbbf0980.entry.js.map +0 -1
- package/dist/wcs/p-e64d7437.entry.js +0 -2
- package/dist/wcs/p-e86575d3.entry.js +0 -2
- package/dist/wcs/p-e86575d3.entry.js.map +0 -1
- package/dist/wcs/p-f264d46f.entry.js +0 -2
- package/dist/wcs/p-fd9e731d.entry.js +0 -2
- package/dist/wcs/p-fd9e731d.entry.js.map +0 -1
- /package/dist/wcs/{p-d7acbf01.js.map → p-0017d766.js.map} +0 -0
- /package/dist/wcs/{p-45a6934d.entry.js.map → p-0ffdfc10.entry.js.map} +0 -0
- /package/dist/wcs/{p-9f23c49e.entry.js.map → p-13090618.entry.js.map} +0 -0
- /package/dist/wcs/{p-8f0e093f.entry.js.map → p-13e50077.entry.js.map} +0 -0
- /package/dist/wcs/{p-2305f257.entry.js.map → p-16dd21cf.entry.js.map} +0 -0
- /package/dist/wcs/{p-2add4d4d.entry.js.map → p-258855a1.entry.js.map} +0 -0
- /package/dist/wcs/{p-2c9e20c1.entry.js.map → p-294732f7.entry.js.map} +0 -0
- /package/dist/wcs/{p-15ff9f93.entry.js.map → p-29f5b974.entry.js.map} +0 -0
- /package/dist/wcs/{p-e64d7437.entry.js.map → p-37800935.entry.js.map} +0 -0
- /package/dist/wcs/{p-76f07dbd.entry.js.map → p-388e6d75.entry.js.map} +0 -0
- /package/dist/wcs/{p-8bd1b9ce.entry.js.map → p-43d70995.entry.js.map} +0 -0
- /package/dist/wcs/{p-d2a4f609.entry.js.map → p-4dc52a25.entry.js.map} +0 -0
- /package/dist/wcs/{p-e19308cf.entry.js.map → p-5d5f50ed.entry.js.map} +0 -0
- /package/dist/wcs/{p-a788b5bd.entry.js.map → p-619e1110.entry.js.map} +0 -0
- /package/dist/wcs/{p-9e03b379.entry.js.map → p-694724a2.entry.js.map} +0 -0
- /package/dist/wcs/{p-f8d2be83.entry.js.map → p-6b06d2e7.entry.js.map} +0 -0
- /package/dist/wcs/{p-5f517eb5.entry.js.map → p-71db0ed5.entry.js.map} +0 -0
- /package/dist/wcs/{p-209145de.entry.js.map → p-76c92e22.entry.js.map} +0 -0
- /package/dist/wcs/{p-97cbbcfc.entry.js.map → p-7d665a7e.entry.js.map} +0 -0
- /package/dist/wcs/{p-4d6d1d14.js.map → p-89b8c724.js.map} +0 -0
- /package/dist/wcs/{p-412b0021.js.map → p-8fcceaf1.js.map} +0 -0
- /package/dist/wcs/{p-87b69cac.entry.js.map → p-9554196c.entry.js.map} +0 -0
- /package/dist/wcs/{p-fa507e06.entry.js.map → p-9ad23e83.entry.js.map} +0 -0
- /package/dist/wcs/{p-5ea2aba5.entry.js.map → p-9c012aae.entry.js.map} +0 -0
- /package/dist/wcs/{p-19c77b5c.entry.js.map → p-9eb66fa9.entry.js.map} +0 -0
- /package/dist/wcs/{p-4982f96c.entry.js.map → p-a7891233.entry.js.map} +0 -0
- /package/dist/wcs/{p-400a71d7.entry.js.map → p-c752b85a.entry.js.map} +0 -0
- /package/dist/wcs/{p-b0f8190f.entry.js.map → p-d895ffb4.entry.js.map} +0 -0
- /package/dist/wcs/{p-f264d46f.entry.js.map → p-e36b2ad1.entry.js.map} +0 -0
- /package/dist/wcs/{p-a66a4289.entry.js.map → p-fc115de4.entry.js.map} +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{r as t,h as e,H as i}from"./p-32e583ea.js";const
|
|
2
|
-
//# sourceMappingURL=p-
|
|
1
|
+
import{r as t,h as e,H as i}from"./p-32e583ea.js";const a=":host{--wcs-list-item-padding:var(--wcs-semantic-spacing-large);--wcs-list-item-border-width:var(--wcs-semantic-border-width-default);--wcs-list-item-border-color:var(--wcs-semantic-color-border-secondary);--wcs-list-item-background-color-default:var(--wcs-semantic-color-background-action-secondary-default);--wcs-list-item-background-color-hover:var(--wcs-semantic-color-background-action-secondary-hover);--wcs-list-item-background-color-active:var(--wcs-semantic-color-background-action-secondary-selected-default);--wcs-list-item-transition-duration:var(--wcs-semantic-motion-duration-feedback-base);--wcs-list-item-title-color:var(--wcs-semantic-color-text-primary);--wcs-list-item-title-font-weight:var(--wcs-semantic-font-weight-heavy);--wcs-list-item-title-line-height:var(--wcs-semantic-font-line-height-medium);--wcs-list-item-title-margin-bottom:var(--wcs-semantic-spacing-base);--wcs-list-item-icon-color:var(--wcs-semantic-color-text-secondary);--wcs-list-item-icon-margin-right:var(--wcs-semantic-spacing-large);--wcs-list-item-actions-margin-left:var(--wcs-semantic-spacing-base);display:flex;padding:var(--wcs-list-item-padding);border:solid var(--wcs-list-item-border-width) var(--wcs-list-item-border-color);margin-bottom:calc(-1 * var(--wcs-list-item-border-width));background-color:var(--wcs-list-item-background-color-default)}:host(:hover){background-color:var(--wcs-list-item-background-color-hover);transition:var(--wcs-list-item-transition-duration)}:host([activated]){background-color:var(--wcs-list-item-background-color-active)}::slotted([slot=title]){color:var(--wcs-list-item-title-color);margin-bottom:var(--wcs-list-item-title-margin-bottom);line-height:var(--wcs-list-item-title-line-height);font-weight:var(--wcs-list-item-title-font-weight);font-family:inherit}::slotted([slot=icon]){color:var(--wcs-list-item-icon-color);margin-right:var(--wcs-list-item-icon-margin-right)}::slotted([slot=actions]){margin-left:var(--wcs-list-item-actions-margin-left)}.content{display:flex;flex-direction:column;flex-grow:1}.header{display:flex;justify-content:space-between}";const c=a;const s=class{constructor(e){t(this,e);this.activated=false}render(){return e(i,{key:"fc01923b2eb3b33d6258718a81455ab790e2dcf4"},e("slot",{key:"6748668e355f3aec9245110299def03ac8783f1e",name:"icon"}),e("div",{key:"46a944966bd87168ad909d7ff9046362a4adf2e2",class:"content"},e("div",{key:"d9d9e1d7bdcc5c1eb947e088b86a7308fd21f9af",class:"header"},e("div",{key:"5dfb072ab048e89a4afe42e2e94b5299f455d889"},e("slot",{key:"ed261613330757d84b1f5f252b32ddf58270b4e8",name:"title"}),e("slot",{key:"ed9f95eaddf982a4aaa07e7b41ae3b9e091c4c85",name:"properties"})),e("slot",{key:"c0aae152b37a42ffb57fcd7fb70f44f83ddf8d3e",name:"actions"})),e("slot",{key:"c7a6b166b7c6e0c160a758640e38feeb5dfcd55d",name:"description"})))}};s.style=c;export{s as wcs_list_item};
|
|
2
|
+
//# sourceMappingURL=p-d9525519.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["listItemCss","WcsListItemStyle0","ListItem","render","h","Host","key","name","class"],"sources":["src/components/list-item/list-item.scss?tag=wcs-list-item&encapsulation=shadow","src/components/list-item/list-item.tsx"],"sourcesContent":[":host {\n --wcs-list-item-padding: var(--wcs-semantic-spacing-large);\n --wcs-list-item-border-width: var(--wcs-semantic-border-width-default);\n --wcs-list-item-border-color: var(--wcs-semantic-color-border-secondary);\n\n --wcs-list-item-background-color-default: var(--wcs-semantic-color-background-action-secondary-default);\n --wcs-list-item-background-color-hover: var(--wcs-semantic-color-background-action-secondary-hover);\n --wcs-list-item-background-color-active: var(--wcs-semantic-color-background-action-secondary-selected-default);\n --wcs-list-item-transition-duration: var(--wcs-semantic-motion-duration-feedback-base);\n\n --wcs-list-item-title-color: var(--wcs-semantic-color-text-primary);\n --wcs-list-item-title-font-weight: var(--wcs-semantic-font-weight-heavy);\n --wcs-list-item-title-line-height: var(--wcs-semantic-font-line-height-medium);\n --wcs-list-item-title-margin-bottom: var(--wcs-semantic-spacing-base);\n\n --wcs-list-item-icon-color: var(--wcs-semantic-color-text-secondary);\n --wcs-list-item-icon-margin-right: var(--wcs-semantic-spacing-large);\n\n --wcs-list-item-actions-margin-left: var(--wcs-semantic-spacing-base);\n\n\n display: flex;\n padding: var(--wcs-list-item-padding);\n border: solid var(--wcs-list-item-border-width) var(--wcs-list-item-border-color);\n margin-bottom: calc(-1 * var(--wcs-list-item-border-width));\n background-color: var(--wcs-list-item-background-color-default);\n}\n\n:host(:hover) {\n background-color: var(--wcs-list-item-background-color-hover);\n transition: var(--wcs-list-item-transition-duration);\n}\n\n:host([activated]) {\n background-color: var(--wcs-list-item-background-color-active);\n}\n\n::slotted([slot=title]) {\n color: var(--wcs-list-item-title-color);\n margin-bottom: var(--wcs-list-item-title-margin-bottom);\n line-height: var(--wcs-list-item-title-line-height);\n font-weight: var(--wcs-list-item-title-font-weight);\n font-family: inherit;\n}\n\n::slotted([slot=icon]) {\n color: var(--wcs-list-item-icon-color);\n margin-right: var(--wcs-list-item-icon-margin-right);\n}\n\n::slotted([slot=actions]) {\n margin-left: var(--wcs-list-item-actions-margin-left);\n}\n\n.content {\n display: flex;\n flex-direction: column;\n flex-grow: 1;\n}\n\n.header {\n display: flex;\n justify-content: space-between;\n}\n","import { Component, ComponentInterface, h, Host, Prop } from '@stencil/core';\n\n/**\n * Lists are used for grouping a collection of related items.\n * \n * Standard lists can be used either with or without icons. Depending on the context, the list can have one or more\n * actions (favourite, download, delete, etc.). Use standard lists with a unique action when each line has an action. \n * \n * ## Accessibility guidelines 💡\n * > - You should wrap your list-items inside a container with a `role` attribute set to `list`. On each `wcs-list-item`, \n * you should set a `role` attribute to `listitem`. See the code below.\n * actions (favourite, download, delete, etc.). Use standard lists with a unique action when each line has an action.\n *\n * @slot title - Slot containing the title of the list item\n * @slot properties - Slot containing the `<wcs-list-item-properties>` element\n * @slot actions - Slot containing the actions of the list item, prefer using some `<wcs-button>` inside\n * @slot description - Slot containing the description of the list item\n * \n * @cssprop --wcs-list-item-padding - Padding of the list item\n * @cssprop --wcs-list-item-border-width - Border width of the list item\n * @cssprop --wcs-list-item-border-color - Border color of the list item\n * @cssprop --wcs-list-item-background-color-default - Background color of the list item\n * @cssprop --wcs-list-item-background-color-hover - Background color of the list item when hovered\n * @cssprop --wcs-list-item-background-color-active - Background color of the list item when active\n * @cssprop --wcs-list-item-transition-duration - Transition duration of the list item\n * @cssprop --wcs-list-item-title-color - Color of the title of the list item\n * @cssprop --wcs-list-item-title-font-weight - Font weight of the title of the list item\n * @cssprop --wcs-list-item-title-line-height - Line height of the title of the list item\n * @cssprop --wcs-list-item-title-margin-bottom - Margin bottom of the title of the list item\n * @cssprop --wcs-list-item-icon-color - Color of the icon of the list item\n * @cssprop --wcs-list-item-icon-margin-right - Margin right of the icon of the list item\n * @cssprop --wcs-list-item-actions-margin-left - Margin left of the actions of the list item\n */\n@Component({\n tag: 'wcs-list-item',\n styleUrl: 'list-item.scss',\n shadow: true\n})\nexport class ListItem implements ComponentInterface {\n /**\n * True if the item is active. Adds a background color that highlights it.\n */\n @Prop({ reflect: true, mutable: true }) activated: boolean = false;\n\n render() {\n return (\n <Host>\n <slot name=\"icon\"/>\n <div class=\"content\">\n <div class=\"header\">\n <div>\n <slot name=\"title\"/>\n <slot name=\"properties\"/>\n </div>\n <slot name=\"actions\"/>\n </div>\n <slot name=\"description\"/>\n </div>\n </Host>\n );\n }\n}\n"],"mappings":"kDAAA,MAAMA,EAAc,mjEACpB,MAAAC,EAAeD,E,MCqCFE,EAAQ,M,wCAI4C,K,CAE7D,MAAAC,GACI,OACIC,EAACC,EAAI,CAAAC,IAAA,4CACDF,EAAA,QAAAE,IAAA,2CAAMC,KAAK,SACXH,EAAA,OAAAE,IAAA,2CAAKE,MAAM,WACPJ,EAAA,OAAAE,IAAA,2CAAKE,MAAM,UACPJ,EAAA,OAAAE,IAAA,4CACIF,EAAA,QAAAE,IAAA,2CAAMC,KAAK,UACXH,EAAA,QAAAE,IAAA,2CAAMC,KAAK,gBAEfH,EAAA,QAAAE,IAAA,2CAAMC,KAAK,aAEfH,EAAA,QAAAE,IAAA,2CAAMC,KAAK,iB"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{r as e,c as o,h as i,H as
|
|
2
|
-
//# sourceMappingURL=p-
|
|
1
|
+
import{r as e,c as o,h as i,H as n}from"./p-32e583ea.js";const t=":host{--wcs-com-nav-item-gap:var(--wcs-semantic-spacing-base);--wcs-com-nav-item-font-size:var(--wcs-semantic-font-size-label-1);--wcs-com-nav-item-arrow-icon-color:var(--wcs-semantic-color-foreground-action-neutral-default);--wcs-com-nav-item-arrow-icon-font-size:0.6rem;--wcs-com-nav-item-arrow-icon-font-family:icons;--wcs-com-nav-item-arrow-icon-line-height:1;--wcs-com-nav-item-focus-outline-color:var(--wcs-semantic-color-border-focus-base);position:relative;display:inline-flex;align-items:center;gap:var(--wcs-com-nav-item-gap);height:fit-content;padding:0 8px;font:inherit;}:host ::slotted(a){user-select:none;cursor:pointer;text-decoration:none;font-size:var(--wcs-com-nav-item-font-size);color:inherit;font-weight:inherit;display:flex;align-items:center}:host .arrow-icon{display:inline-block;font-family:icons;color:var(--wcs-com-nav-item-arrow-icon-color);font-size:var(--wcs-com-nav-item-arrow-icon-font-size);line-height:var(--wcs-com-nav-item-arrow-icon-line-height);box-sizing:border-box}:host .arrow-container{display:unset}:host ::slotted(a:focus-visible){outline:none}:host(:focus-within){outline:var(--wcs-semantic-border-width-large) dashed var(--wcs-com-nav-item-focus-outline-color);outline-offset:0.5rem;border-radius:2px}@media screen and (min-width: 576px){:host ::slotted(a){display:flex;align-items:center;height:100%;padding-top:unset;padding-bottom:unset;padding-left:unset}}";const a=t;const s=class{constructor(i){e(this,i);this.wcsClickOnFinalAction=o(this,"wcsClickOnFinalAction",7)}onClick(){this.wcsClickOnFinalAction.emit()}render(){return i(n,{key:"ebafe8ee7fa4dfb839095a00119b1fb60ec9f61f",role:"listitem"},i("slot",{key:"4dd33801a76cd03665c107afb6a1640f2843d3cd"}),i("span",{key:"a9fe68e0e7b0e4221ba6b1a6b3e6802876082ce4",class:"arrow-container"},i("span",{key:"b0d3aa7fbfb967e7910ea6f446e1dd0489d39265","aria-hidden":"true",class:"arrow-icon"},"")))}};s.style=a;export{s as wcs_com_nav_item};
|
|
2
|
+
//# sourceMappingURL=p-da4636fa.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["comNavItemCss","WcsComNavItemStyle0","ComNavItem","onClick","this","wcsClickOnFinalAction","emit","render","h","Host","key","role","class"],"sources":["src/components/com-nav-item/com-nav-item.scss?tag=wcs-com-nav-item&encapsulation=shadow","src/components/com-nav-item/com-nav-item.tsx"],"sourcesContent":["@import '../../style/focus-outline.scss';\n@import '../com-nav/com-nav-focus.scss';\n\n/* Default style and mobile behaviour */\n:host {\n --wcs-com-nav-item-gap: var(--wcs-semantic-spacing-base);\n --wcs-com-nav-item-font-size: var(--wcs-semantic-font-size-label-1);\n --wcs-com-nav-item-arrow-icon-color: var(--wcs-semantic-color-foreground-action-neutral-default);\n --wcs-com-nav-item-arrow-icon-font-size: 0.6rem;\n --wcs-com-nav-item-arrow-icon-font-family: icons;\n --wcs-com-nav-item-arrow-icon-line-height: 1;\n\n --wcs-com-nav-item-focus-outline-color: var(--wcs-semantic-color-border-focus-base);\n\n position: relative;\n display: inline-flex;\n align-items: center;\n gap: var(--wcs-com-nav-item-gap);\n height: fit-content;\n padding: 0 8px;\n\n font: inherit;\n\n ::slotted(a) {\n /* Default */\n user-select: none;\n cursor: pointer;\n text-decoration: none;\n font-size: var(--wcs-com-nav-item-font-size);\n color: inherit;\n font-weight: inherit;\n\n display: flex;\n align-items: center;\n }\n\n /* Common behaviour between Large Screen and Small Screens */\n .arrow-icon {\n display: inline-block;\n font-family: icons;\n color: var(--wcs-com-nav-item-arrow-icon-color);\n font-size: var(--wcs-com-nav-item-arrow-icon-font-size);\n line-height: var(--wcs-com-nav-item-arrow-icon-line-height);\n box-sizing: border-box;\n }\n\n .arrow-container {\n display: unset;\n }\n\n /**For mobile*/\n ::slotted(a:focus-visible) {\n outline: none;\n }\n}\n\n:host(:focus-within) {\n @include com-nav-item-mobile-focus-outline(var(--wcs-com-nav-item-focus-outline-color));\n}\n\n/* Large screen, specific behaviour */\n@media screen and (min-width: 576px) {\n :host {\n ::slotted(a) {\n display: flex;\n align-items: center;\n height: 100%;\n\n /* Reset for pc */\n padding-top: unset;\n padding-bottom: unset;\n padding-left: unset;\n }\n\n // Focus outline style is handling by com-nav, com-nav-submenu and com-nav-category in desktop mode\n }\n}\n","import { Component, Host, h, Event, EventEmitter, Listen } from '@stencil/core';\n\n/**\n * The com-nav-item is a subcomponent of `wcs-com-nav`. It represents a list-item wrapper around a link.\n * \n * @cssprop --wcs-com-nav-item-gap - Gap between text and arrow\n * @cssprop --wcs-com-nav-item-font-weight - Font-weight of item\n * @cssprop --wcs-com-nav-item-arrow-icon-font-size - Arrow size\n * @cssprop --wcs-com-nav-item-focus-outline-color - Focus outline color\n */\n@Component({\n tag: 'wcs-com-nav-item',\n styleUrl: './com-nav-item.scss',\n shadow: true\n})\nexport class ComNavItem {\n /**\n * Emitted when a user click on a final navigation action.\n *\n * Used by the com-nav component to close the mobile menu overlay when a user click on a final action.\n */\n @Event() private wcsClickOnFinalAction: EventEmitter<void>;\n \n @Listen('click')\n onClick() {\n this.wcsClickOnFinalAction.emit();\n }\n \n render() {\n return (\n <Host role=\"listitem\">\n <slot></slot>\n <span class=\"arrow-container\">\n <span aria-hidden=\"true\" class=\"arrow-icon\"></span>\n </span>\n </Host>\n );\n }\n\n}\n"],"mappings":"yDAAA,MAAMA,EAAgB,i4CACtB,MAAAC,EAAeD,E,MCcFE,EAAU,M,sFASnB,OAAAC,GACIC,KAAKC,sBAAsBC,M,CAG/B,MAAAC,GACI,OACIC,EAACC,EAAI,CAAAC,IAAA,2CAACC,KAAK,YACPH,EAAA,QAAAE,IAAA,6CACAF,EAAA,QAAAE,IAAA,2CAAME,MAAM,mBACJJ,EAAA,QAAAE,IAAA,yDAAkB,OAAOE,MAAM,cAAY,M"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as c,c as s,h as t,H as e,g as i}from"./p-32e583ea.js";import{i as o,a,s as r}from"./p-52d77e1f.js";import{g as n}from"./p-a7468a3a.js";const d=':host{--wcs-switch-background-color-initial:var(--wcs-semantic-color-background-control-indicator-default);--wcs-switch-background-color-final:var(--wcs-semantic-color-background-control-indicator-selected);--wcs-switch-background-color-disabled:var(--wcs-semantic-color-background-control-indicator-disabled);--wcs-switch-background-color-disabled-selected:var(--wcs-semantic-color-background-control-indicator-disabled);--wcs-switch-background-color-hover-selected:var(--wcs-semantic-color-background-control-indicator-hover);--wcs-switch-padding-horizontal:var(--wcs-semantic-spacing-small);--wcs-switch-padding-vertical:calc((var(--wcs-switch-height) - var(--wcs-switch-dot-size)) / 2);--wcs-switch-dot-color-default:var(--wcs-semantic-color-foreground-brand);--wcs-switch-dot-color-selected:var(--wcs-semantic-color-foreground-control-indicator-selected);--wcs-switch-dot-color-disabled:var(--wcs-semantic-color-foreground-control-indicator-disabled);--wcs-switch-text-color-default:var(--wcs-semantic-color-text-secondary);--wcs-switch-text-color-selected:var(--wcs-semantic-color-text-primary);--wcs-switch-text-color-disabled:var(--wcs-semantic-color-text-disabled);--wcs-switch-text-font-weight-default:var(--wcs-semantic-font-weight-medium);--wcs-switch-text-font-weight-selected:var(--wcs-semantic-font-weight-medium);--wcs-switch-outline-color-focus:var(--wcs-semantic-color-border-focus-base);--wcs-switch-dot-translate-x:calc(var(--wcs-switch-width) - var(--wcs-switch-dot-size) - (2 * var(--wcs-switch-padding-horizontal)));--wcs-switch-transition-duration:var(--wcs-semantic-motion-duration-feedback-base);--wcs-switch-dot-size:0.875rem;--wcs-switch-height:var(--wcs-semantic-size-xs);--wcs-switch-width:var(--wcs-semantic-size-l);--wcs-switch-border-radius:var(--wcs-semantic-border-radius-full);--wcs-switch-gap:var(--wcs-semantic-spacing-base);display:inline-flex}:host([disabled]) .text{color:var(--wcs-switch-text-color-disabled)}:host([disabled]) .wcs-container{cursor:not-allowed}.wcs-container{position:relative;display:flex;user-select:none;margin-bottom:0;gap:var(--wcs-switch-gap)}.wcs-container:has(input:focus-visible){outline:var(--wcs-semantic-border-width-large) dashed var(--wcs-switch-outline-color-focus);outline-offset:var(--wcs-semantic-spacing-small);border-radius:var(--wcs-switch-border-radius)}@supports not selector(.wcs-container:has(input:focus-visible)){.wcs-container:focus-within{outline:var(--wcs-semantic-border-width-large) dashed var(--wcs-switch-outline-color-focus);outline-offset:var(--wcs-semantic-spacing-small);border-radius:var(--wcs-switch-border-radius)}}:host([label-alignment=top]) .wcs-container{align-items:start}:host([label-alignment=center]) .wcs-container{align-items:center}:host([label-alignment=bottom]) .wcs-container{align-items:flex-end}.wcs-container input{position:absolute;opacity:0;height:0;width:0}.text{color:var(--wcs-switch-text-color-default);font-weight:var(--wcs-switch-text-font-weight-default);line-height:1.375}.wcs-container:not([aria-disabled]) input:checked~.text{font-weight:var(--wcs-switch-text-font-weight-selected);color:var(--wcs-switch-text-color-selected)}.wcs-checkmark::before{position:absolute;transition:all var(--wcs-switch-transition-duration) ease-out}.wcs-checkmark::before{bottom:var(--wcs-switch-padding-vertical);left:var(--wcs-switch-padding-horizontal);width:var(--wcs-switch-dot-size);height:var(--wcs-switch-dot-size);content:"";border-radius:50%;background-color:var(--wcs-switch-dot-color-default)}:host([disabled]:not([checked])) .wcs-checkmark::before{background-color:var(--wcs-switch-dot-color-disabled)}:host([disabled]:not([checked])) .wcs-checkmark{background-color:var(--wcs-switch-background-color-disabled)}:host([disabled][checked]) .wcs-checkmark{background-color:var(--wcs-switch-background-color-disabled-selected)}:host([disabled]) .text{color:var(--wcs-switch-text-color-disabled)}.wcs-checkmark{top:0;right:0;bottom:0;left:0;width:var(--wcs-switch-width);height:var(--wcs-switch-height);border-radius:var(--wcs-switch-border-radius);background-color:var(--wcs-switch-background-color-initial);min-width:3rem;position:relative}.wcs-container:not([aria-disabled]){cursor:pointer}input:not([disabled]):checked+.wcs-checkmark::before,.wcs-container:focus input:not([disabled])+.wcs-checkmark::before{background-color:var(--wcs-switch-dot-color-selected)}input:checked+.wcs-checkmark::before{transform:translateX(var(--wcs-switch-dot-translate-x))}input:not([disabled]):checked+.wcs-checkmark{background-color:var(--wcs-switch-background-color-final)}.wcs-container:hover input:not([disabled]):checked+.wcs-checkmark{background-color:var(--wcs-switch-background-color-hover-selected)}';const l=d;const h=["tabindex"];const w=class{constructor(t){c(this,t);this.wcsChange=s(this,"wcsChange",7);this.wcsFocus=s(this,"wcsFocus",7);this.wcsBlur=s(this,"wcsBlur",7);this.switchId=`wcs-switch-${b++}`;this.inheritedAttributes={};this.name=this.switchId;this.checked=false;this.labelAlignment="center";this.disabled=false}handleChange(c){c.stopImmediatePropagation();c.preventDefault();this.toggleSwitchState()}async handleHostClick(c){c.preventDefault();c.stopPropagation();this.toggleSwitchState()}handleInputClick(c){if(c.detail){c.stopImmediatePropagation();c.preventDefault()}}toggleSwitchState(){if(this.disabled)return;this.checked=!this.checked;this.wcsChange.emit({checked:this.checked})}handleFocus(c){this.wcsFocus.emit(c)}handleBlur(c){this.wcsBlur.emit(c)}componentWillLoad(){this.inheritedAttributes=Object.assign(Object.assign({},o(this.el)),a(this.el,h))}async setAriaAttribute(c,s){r(this.nativeInput,c,s)}async getLabel(){return n(this.el)}render(){return t(e,{key:"7583a10f5f7f2dbad7b31fcab1864d950b7a773c"},t("label",{key:"93dcf06138949976d600935058f82dc7c0fd44cb",htmlFor:this.name,class:"wcs-container","aria-disabled":this.disabled},t("input",Object.assign({key:"274e8126f833188a2e60f8ed62f1fbc63efa7970",onBlur:this.handleBlur.bind(this),onChange:this.handleChange.bind(this),onClick:this.handleInputClick.bind(this),onFocus:this.handleFocus.bind(this),checked:this.checked,id:this.name,class:"wcs-switch",type:"checkbox",name:this.name,disabled:this.disabled,ref:c=>{this.nativeInput=c}},this.inheritedAttributes)),t("span",{key:"57e6bcc1b48d4765ec081736e7bc13000dbaa665",class:"wcs-checkmark"}),t("span",{key:"f03e632e387bb25030ab0cd0f4e5aa451c17d042",class:"text"},t("slot",{key:"ab9340d1fa032ab2da0318387c5332def8b757dd"}))))}static get delegatesFocus(){return true}get el(){return i(this)}};let b=0;w.style=l;export{w as wcs_switch};
|
|
2
|
+
//# sourceMappingURL=p-dd60a6db.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["switchCss","WcsSwitchStyle0","SWITCH_INHERITED_ATTRS","Switch","this","switchId","switchIds","inheritedAttributes","handleChange","ev","stopImmediatePropagation","preventDefault","toggleSwitchState","handleHostClick","e","stopPropagation","handleInputClick","detail","disabled","checked","wcsChange","emit","handleFocus","event","wcsFocus","handleBlur","wcsBlur","componentWillLoad","Object","assign","inheritAriaAttributes","el","inheritAttributes","setAriaAttribute","attr","value","setOrRemoveAttribute","nativeInput","getLabel","getSlottedContentText","render","h","Host","key","htmlFor","name","class","onBlur","bind","onChange","onClick","onFocus","id","type","ref"],"sources":["src/components/switch/switch.scss?tag=wcs-switch&encapsulation=shadow","src/components/switch/switch.tsx"],"sourcesContent":["@import '../../style/focus-outline.scss';\n\n:host {\n --wcs-switch-background-color-initial: var(--wcs-semantic-color-background-control-indicator-default);\n --wcs-switch-background-color-final: var(--wcs-semantic-color-background-control-indicator-selected);\n --wcs-switch-background-color-disabled: var(--wcs-semantic-color-background-control-indicator-disabled);\n --wcs-switch-background-color-disabled-selected: var(--wcs-semantic-color-background-control-indicator-disabled);\n --wcs-switch-background-color-hover-selected: var(--wcs-semantic-color-background-control-indicator-hover);\n\n --wcs-switch-padding-horizontal: var(--wcs-semantic-spacing-small);\n --wcs-switch-padding-vertical: calc((var(--wcs-switch-height) - var(--wcs-switch-dot-size)) / 2); // to center the dot vertically, at the middle of the dot\n\n // TODO : Les variables figma sont bindées sur les primitives\n --wcs-switch-dot-color-default: var(--wcs-semantic-color-foreground-brand); // the dot color when the switch is not checked\n --wcs-switch-dot-color-selected: var(--wcs-semantic-color-foreground-control-indicator-selected); // the dot color when the switch is checked\n --wcs-switch-dot-color-disabled: var(--wcs-semantic-color-foreground-control-indicator-disabled);\n\n --wcs-switch-text-color-default: var(--wcs-semantic-color-text-secondary);\n --wcs-switch-text-color-selected: var(--wcs-semantic-color-text-primary);\n --wcs-switch-text-color-disabled: var(--wcs-semantic-color-text-disabled);\n\n --wcs-switch-text-font-weight-default: var(--wcs-semantic-font-weight-medium);\n --wcs-switch-text-font-weight-selected: var(--wcs-semantic-font-weight-medium);\n\n --wcs-switch-outline-color-focus: var(--wcs-semantic-color-border-focus-base);\n\n --wcs-switch-dot-translate-x: calc(var(--wcs-switch-width) - var(--wcs-switch-dot-size) - (2 * var(--wcs-switch-padding-horizontal)));\n --wcs-switch-transition-duration: var(--wcs-semantic-motion-duration-feedback-base);\n\n --wcs-switch-dot-size: 0.875rem; /* 14px */\n\n --wcs-switch-height: var(--wcs-semantic-size-xs);\n --wcs-switch-width: var(--wcs-semantic-size-l);\n\n --wcs-switch-border-radius: var(--wcs-semantic-border-radius-full);\n\n --wcs-switch-gap: var(--wcs-semantic-spacing-base);\n\n display: inline-flex;\n}\n\n:host([disabled]) {\n .text {\n color: var(--wcs-switch-text-color-disabled);\n }\n\n .wcs-container {\n cursor: not-allowed;\n }\n}\n\n/* Customize the label (the wcs-container) */\n.wcs-container {\n position: relative;\n display: flex;\n user-select: none;\n margin-bottom: 0;\n\n gap: var(--wcs-switch-gap);\n}\n\n.wcs-container:has(input:focus-visible) {\n @include focus-outline($outline-color: var(--wcs-switch-outline-color-focus), $border-radius: var(--wcs-switch-border-radius));\n}\n\n/* If the selector focus-visible is not supported by the browser, use focus-within instead */\n@supports not selector(.wcs-container:has(input:focus-visible)){\n .wcs-container:focus-within {\n @include focus-outline($outline-color: var(--wcs-switch-outline-color-focus), $border-radius: var(--wcs-switch-border-radius));\n }\n}\n\n/* Let the user choose the alignment of the checkbox with the label text */\n:host([label-alignment=\"top\"]) {\n .wcs-container {\n align-items: start;\n }\n}\n\n:host([label-alignment=\"center\"]) {\n .wcs-container {\n align-items: center;\n }\n}\n\n:host([label-alignment=\"bottom\"]) {\n .wcs-container {\n align-items: flex-end;\n }\n}\n\n/* Hide the browser's default switch */\n.wcs-container input {\n position: absolute;\n opacity: 0;\n height: 0;\n width: 0;\n}\n\n.text {\n color: var(--wcs-switch-text-color-default);\n\n font-weight: var(--wcs-switch-text-font-weight-default);\n line-height: 1.375;\n}\n\n.wcs-container:not([aria-disabled]) input:checked ~ .text {\n font-weight: var(--wcs-switch-text-font-weight-selected);\n color: var(--wcs-switch-text-color-selected);\n}\n\n.wcs-checkmark::before {\n position: absolute;\n transition: all var(--wcs-switch-transition-duration) ease-out;\n}\n\n.wcs-checkmark::before {\n bottom: var(--wcs-switch-padding-vertical);\n left: var(--wcs-switch-padding-horizontal);\n width: var(--wcs-switch-dot-size);\n height: var(--wcs-switch-dot-size);\n content: \"\";\n border-radius: 50%;\n background-color: var(--wcs-switch-dot-color-default);\n}\n\n:host([disabled]:not([checked])) {\n .wcs-checkmark::before {\n background-color: var(--wcs-switch-dot-color-disabled);\n }\n\n .wcs-checkmark {\n background-color: var(--wcs-switch-background-color-disabled);\n }\n}\n\n:host([disabled][checked]) {\n .wcs-checkmark {\n background-color: var(--wcs-switch-background-color-disabled-selected);\n }\n}\n\n:host([disabled]) {\n .text {\n color: var(--wcs-switch-text-color-disabled);\n }\n}\n\n.wcs-checkmark {\n top: 0;\n right: 0;\n bottom: 0;\n left: 0;\n width: var(--wcs-switch-width);\n height: var(--wcs-switch-height);\n border-radius: var(--wcs-switch-border-radius);\n background-color: var(--wcs-switch-background-color-initial);\n\n min-width: 3rem;\n position: relative;\n}\n\n.wcs-container:not([aria-disabled]) {\n cursor: pointer;\n}\n\n/* When the switch is checked, change the dot to white */\ninput:not([disabled]):checked + .wcs-checkmark::before,\n.wcs-container:focus input:not([disabled]) + .wcs-checkmark::before {\n background-color: var(--wcs-switch-dot-color-selected);\n}\n\n/* Switch transition */\ninput:checked + .wcs-checkmark::before {\n transform: translateX(var(--wcs-switch-dot-translate-x));\n}\n\n/* When the switch is checked, change background */\ninput:not([disabled]):checked + .wcs-checkmark {\n background-color: var(--wcs-switch-background-color-final);\n}\n\n/* When the switch is checked and hover, change background */\n.wcs-container:hover input:not([disabled]):checked + .wcs-checkmark {\n background-color: var(--wcs-switch-background-color-hover-selected);\n}\n","import {\n Component,\n ComponentInterface,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Listen,\n Method,\n Prop\n} from '@stencil/core';\nimport { SwitchChangeEventDetail, SwitchLabelAlignment } from './switch-interface';\nimport { AriaAttributeName, MutableAriaAttribute } from \"../../utils/mutable-aria-attribute\";\nimport { inheritAriaAttributes, inheritAttributes, setOrRemoveAttribute } from \"../../utils/helpers\";\nimport { ControlComponentWithLabel, getSlottedContentText } from \"../../utils/control-component-interface\";\n\nconst SWITCH_INHERITED_ATTRS = ['tabindex'];\n\n/**\n * The switch component is a control used to switch between on and off state.\n * \n * @cssprop --wcs-switch-outline-color-focus - Color of the focus outline\n * \n * @cssprop --wcs-switch-text-color-default - Color of the text when the switch is not selected\n * @cssprop --wcs-switch-text-color-selected - Color of the text when the switch is selected\n * @cssprop --wcs-switch-text-color-disabled - Color of the text when the switch is disabled\n\n * \n * @cssprop --wcs-switch-background-color-initial - Background color of the switch when not selected\n * @cssprop --wcs-switch-background-color-final - Background color of the switch when selected\n * @cssprop --wcs-switch-background-color-disabled - Background color of the switch when disabled\n * @cssprop --wcs-switch-background-color-disabled-selected - Background color of the switch when disabled and selected\n * @cssprop --wcs-switch-background-color-hover-selected - Background color of the switch when hovered and selected\n * \n * @cssprop --wcs-switch-height - Height of the switch\n * @cssprop --wcs-switch-width - Width of the switch\n * @cssprop --wcs-switch-border-radius - Border radius of the switch\n * @cssprop --wcs-switch-padding-horizontal - Horizontal padding of the switch\n * @cssprop --wcs-switch-padding-vertical - Vertical padding of the switch\n * \n * @cssprop --wcs-switch-dot-color-default - Color of the dot when not selected\n * @cssprop --wcs-switch-dot-color-selected - Color of the dot when selected\n * @cssprop --wcs-switch-dot-color-disabled - Color of the dot when disabled\n * \n * @cssprop --wcs-switch-dot-translate-x - Horizontal translation of the dot (from left to right = right to left)\n * @cssprop --wcs-switch-dot-size - Size of the dot\n * \n * @cssprop --wcs-switch-gap - Gap between the switch and the text\n */\n@Component({\n tag: 'wcs-switch',\n styleUrl: 'switch.scss',\n shadow: {\n delegatesFocus: true,\n }\n})\nexport class Switch implements ComponentInterface, MutableAriaAttribute, ControlComponentWithLabel {\n @Element() private el!: HTMLElement;\n private switchId = `wcs-switch-${switchIds++}`;\n private nativeInput!: HTMLInputElement;\n private inheritedAttributes: { [k: string]: any } = {};\n\n @Prop() name = this.switchId;\n\n /**\n * If `true`, the switch is selected.\n */\n @Prop({reflect: true}) checked = false;\n\n /**\n * Specifie the alignment of the switch with the label content\n */\n @Prop({reflect: true}) labelAlignment: SwitchLabelAlignment = 'center';\n\n /**\n * Specify whether the switch is disabled or not.\n */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /**\n * Emitted when the checked property has changed.\n */\n @Event() wcsChange!: EventEmitter<SwitchChangeEventDetail>;\n\n /**\n * Emitted when the switch has focus.\n */\n @Event() wcsFocus!: EventEmitter<FocusEvent>;\n \n /**\n * Emitted when the switch loses focus.\n */\n @Event() wcsBlur!: EventEmitter<FocusEvent>;\n\n \n handleChange(ev: Event) {\n ev.stopImmediatePropagation();\n ev.preventDefault();\n this.toggleSwitchState();\n }\n\n @Listen('click')\n async handleHostClick(e: Event){\n e.preventDefault();\n e.stopPropagation();\n\n this.toggleSwitchState();\n }\n\n handleInputClick(ev: PointerEvent) {\n // If the click event is coming from the mouse we ignore it.\n // We only want to handle the keyboard interactions as it is the only purpose of this native input\n if (ev.detail) {\n ev.stopImmediatePropagation()\n ev.preventDefault();\n }\n }\n\n toggleSwitchState() {\n if (this.disabled) return;\n \n this.checked = !this.checked;\n this.wcsChange.emit({\n checked: this.checked,\n });\n }\n\n handleFocus(event: FocusEvent) {\n this.wcsFocus.emit(event);\n }\n\n handleBlur(event: FocusEvent) {\n this.wcsBlur.emit(event);\n }\n\n componentWillLoad(): Promise<void> | void {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el),\n ...inheritAttributes(this.el, SWITCH_INHERITED_ATTRS),\n };\n }\n \n @Method()\n async setAriaAttribute(attr: AriaAttributeName, value: string | null | undefined) {\n setOrRemoveAttribute(this.nativeInput, attr, value);\n }\n\n @Method()\n async getLabel(): Promise<string> {\n return getSlottedContentText(this.el);\n }\n \n render() {\n return (\n <Host>\n <label htmlFor={this.name} class=\"wcs-container\" aria-disabled={this.disabled}>\n <input onBlur={this.handleBlur.bind(this)}\n onChange={this.handleChange.bind(this)}\n onClick={this.handleInputClick.bind(this)}\n onFocus={this.handleFocus.bind(this)}\n checked={this.checked}\n id={this.name}\n class=\"wcs-switch\"\n type=\"checkbox\"\n name={this.name}\n disabled={this.disabled}\n ref={el => {this.nativeInput = el}}\n {...this.inheritedAttributes}>\n </input>\n <span class=\"wcs-checkmark\"></span>\n <span class=\"text\">\n <slot/>\n </span>\n </label>\n </Host>\n );\n }\n}\n\nlet switchIds = 0;\n"],"mappings":"iJAAA,MAAMA,EAAY,2mJAClB,MAAAC,EAAeD,ECgBf,MAAME,EAAyB,CAAC,Y,MAwCnBC,EAAM,M,kIAEPC,KAAAC,SAAW,cAAcC,MAEzBF,KAAAG,oBAA4C,G,UAErCH,KAAKC,S,aAKa,M,oBAK6B,S,cAKjB,K,CAkB7C,YAAAG,CAAaC,GACTA,EAAGC,2BACHD,EAAGE,iBACHP,KAAKQ,mB,CAIT,qBAAMC,CAAgBC,GAClBA,EAAEH,iB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AAE,IAAA,+C,mEAQxB,IAAIrC,EAAY,E"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,h as a,H as t,g as o}from"./p-32e583ea.js";import{i as c,a as i,s as r,q as s,b as n}from"./p-52d77e1f.js";import{c as l}from"./p-0f864e86.js";const d=':host{--wcs-galactic-menu-background-color:var(--wcs-semantic-color-background-surface-brand);--wcs-galactic-menu-padding-horizontal:var(--wcs-semantic-spacing-large);--wcs-galactic-menu-gap:var(--wcs-semantic-spacing-large);--wcs-galactic-menu-height:var(--wcs-semantic-size-s);--wcs-galactic-menu-icon-focus-outline-color:var(--wcs-galactic-text-color, white);--wcs-galactic-menu-overlay-color:var(--wcs-semantic-color-text-inverse);--wcs-galactic-menu-overlay-background-color:var(--wcs-semantic-color-background-surface-inverse);--wcs-galactic-menu-overlay-padding:var(--wcs-semantic-spacing-large);display:flex;align-items:center;box-sizing:border-box;height:var(--wcs-galactic-menu-height);gap:var(--wcs-galactic-menu-gap);padding:0 var(--wcs-galactic-menu-padding-horizontal);background-color:var(--wcs-galactic-menu-background-color)}#menu{display:none;background-color:var(--wcs-galactic-menu-overlay-background-color);color:var(--wcs-galactic-menu-overlay-color);padding:var(--wcs-galactic-menu-overlay-padding);--wcs-semantic-color-border-focus-base:var(--wcs-semantic-color-text-inverse, white)}#menu[data-show]{display:block;z-index:9999}#menu[data-popper-placement^=top]>#arrow{bottom:-4px}#menu[data-popper-placement^=bottom]>#arrow{top:-4px}#menu[data-popper-placement^=left]>#arrow{right:-4px}#menu[data-popper-placement^=right]>#arrow{left:-4px}#arrow,#arrow::before{position:absolute;width:8px;height:8px;background:inherit}#arrow{visibility:hidden}#arrow::before{visibility:visible;content:"";transform:rotate(45deg)}button{background:transparent;border:none;color:inherit;cursor:pointer;user-select:none}button:focus-visible{outline:var(--wcs-semantic-border-width-large) dashed var(--wcs-galactic-menu-icon-focus-outline-color);outline-offset:0;border-radius:0.1rem}';const u=d;const m=["tabindex","title"];const p=class{constructor(a){e(this,a);this.inheritedAttributes={};this.showPopoverMenu=false;this.text=undefined}componentDidLoad(){this.menu=this.el.shadowRoot.getElementById("toggle-menu-icon");this.tooltip=this.el.shadowRoot.getElementById("menu");this.popper=l(this.menu,this.tooltip,{placement:"bottom-end",modifiers:[{name:"offset",options:{offset:[0,8]}}]})}componentWillLoad(){this.inheritedAttributes=Object.assign(Object.assign({},c(this.el)),i(this.el,m))}async setAriaAttribute(e,a){r(this.menuButton,e,a)}onWindowClickEvent(e){if(s(e,this.tooltip)||s(e,this.menu)){return}else{if(this.showPopoverMenu){this.toggleMenu()}}}onKeyDown(e){var a;if(n(e)){e.preventDefault();this.showPopoverMenu=false;(a=this.menuButton)===null||a===void 0?void 0:a.focus()}}toggleMenu(){this.showPopoverMenu=!this.showPopoverMenu}componentDidRender(){if(this.popper){this.popper.update()}}render(){return a(t,{key:"57fa555ec72e13761295e18aa779d5ac5be81111"},a("span",{key:"91b4fe9a2f6ee303c3ba00c2ba1a1ded0ac7a761"},this.text),a("button",Object.assign({key:"324d0c458e500ba5d47187bdd59297f67e067374","aria-haspopup":"true","aria-controls":"menu",ref:e=>{this.menuButton=e},"aria-expanded":this.showPopoverMenu?"true":"false"},this.inheritedAttributes,{onClick:e=>this.toggleMenu()}),a("wcs-mat-icon",{key:"accf07fb4f5d737f30f16c5cd96b96a5b66ba1d0",id:"toggle-menu-icon",icon:"more_horiz",size:"m"})),a("span",{key:"f9ae129e58d7911a7a88d8b2449a8b2e19be516f",id:"menu",role:"menu","data-show":this.showPopoverMenu},a("div",{key:"f4b78cf4631a7fa1b6ca1e68a7eb633d52c7b994",id:"arrow","data-popper-arrow":true}),a("slot",{key:"c9eb687e1b82f075a5ef1b84d09b69bdbf9c292f"})))}get el(){return o(this)}};p.style=u;export{p as wcs_galactic_menu};
|
|
2
|
+
//# sourceMappingURL=p-dddcd685.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["galacticMenuCss","WcsGalacticMenuStyle0","GALACTIC_MENU_INHERITED_ATTRS","Galactic","this","inheritedAttributes","componentDidLoad","menu","el","shadowRoot","getElementById","tooltip","popper","createPopper","placement","modifiers","name","options","offset","componentWillLoad","Object","assign","inheritAriaAttributes","inheritAttributes","setAriaAttribute","attr","value","setOrRemoveAttribute","menuButton","onWindowClickEvent","event","clickInsideElement","showPopoverMenu","toggleMenu","onKeyDown","_event","isEscapeKey","preventDefault","_a","focus","componentDidRender","update","render","h","Host","key","text","ref","onClick","_","id","icon","size","role"],"sources":["src/components/galactic-menu/galactic-menu.scss?tag=wcs-galactic-menu&encapsulation=shadow","src/components/galactic-menu/galactic-menu.tsx"],"sourcesContent":["@import '../../style/focus-outline.scss';\n\n:host {\n --wcs-galactic-menu-background-color: var(--wcs-semantic-color-background-surface-brand);\n --wcs-galactic-menu-padding-horizontal: var(--wcs-semantic-spacing-large);\n --wcs-galactic-menu-gap: var(--wcs-semantic-spacing-large);\n --wcs-galactic-menu-height: var(--wcs-semantic-size-s);\n\n --wcs-galactic-menu-icon-focus-outline-color: var(--wcs-galactic-text-color, white); /* Inherit from galactic */\n --wcs-galactic-menu-overlay-color: var(--wcs-semantic-color-text-inverse);\n --wcs-galactic-menu-overlay-background-color: var(--wcs-semantic-color-background-surface-inverse);\n --wcs-galactic-menu-overlay-padding: var(--wcs-semantic-spacing-large);\n\n display: flex;\n align-items: center;\n box-sizing: border-box;\n height: var(--wcs-galactic-menu-height);\n gap: var(--wcs-galactic-menu-gap);\n padding: 0 var(--wcs-galactic-menu-padding-horizontal);\n background-color: var(--wcs-galactic-menu-background-color);\n\n}\n#menu {\n display: none;\n background-color: var(--wcs-galactic-menu-overlay-background-color);\n color: var(--wcs-galactic-menu-overlay-color);\n padding: var(--wcs-galactic-menu-overlay-padding);\n --wcs-semantic-color-border-focus-base: var(--wcs-semantic-color-text-inverse, white); // resolve bad contrast issue with focus outline of wcs-button\n}\n#menu[data-show] {\n display: block;\n z-index: 9999;\n}\n#menu[data-popper-placement^='top'] > #arrow {\n bottom: -4px;\n}\n\n#menu[data-popper-placement^='bottom'] > #arrow {\n top: -4px;\n}\n\n#menu[data-popper-placement^='left'] > #arrow {\n right: -4px;\n}\n\n#menu[data-popper-placement^='right'] > #arrow {\n left: -4px;\n}\n\n#arrow,\n#arrow::before {\n position: absolute;\n width: 8px;\n height: 8px;\n background: inherit;\n}\n\n#arrow {\n visibility: hidden;\n}\n\n#arrow::before {\n visibility: visible;\n content: '';\n transform: rotate(45deg);\n}\n\nbutton {\n background: transparent;\n border: none;\n color: inherit;\n\n cursor: pointer;\n user-select: none;\n\n &:focus-visible {\n @include focus-outline(var(--wcs-galactic-menu-icon-focus-outline-color), $outline-offset: 0);\n }\n}\n","import { Component, ComponentInterface, Element, h, Host, Listen, Method, Prop, State } from '@stencil/core';\nimport { Instance, createPopper } from '@popperjs/core';\nimport {\n clickInsideElement,\n inheritAriaAttributes,\n inheritAttributes,\n isEscapeKey,\n setOrRemoveAttribute\n} from '../../utils/helpers';\nimport { AriaAttributeName } from \"../../utils/mutable-aria-attribute\";\n\n\nconst GALACTIC_MENU_INHERITED_ATTRS = ['tabindex', 'title'];\n\n/**\n * *Part of communication design system*\n * You can put a wcs-galactic-menu inside a wcs-galactic component to add an extra menu\n * \n * @slot <no-name> - Main container slot\n * \n * @cssprop --wcs-galactic-menu-background-color - Background color of the menu\n * @cssprop --wcs-galactic-menu-padding-horizontal - Horizontal padding of the menu\n * @cssprop --wcs-galactic-menu-gap - Gap between items in the menu\n * @cssprop --wcs-galactic-menu-height - Height of the menu\n * @cssprop --wcs-galactic-menu-icon-focus-outline-color - Color of the focus outline on the icon\n * @cssprop --wcs-galactic-menu-overlay-background-color - Background color of the overlay\n * @cssprop --wcs-galactic-menu-overlay-padding - Padding of the overlay\n * @cssprop --wcs-galactic-menu-overlay-color - Color of the overlay\n */\n@Component({\n tag: 'wcs-galactic-menu',\n styleUrl: 'galactic-menu.scss',\n shadow: true\n})\nexport class Galactic implements ComponentInterface {\n @Element() private el: HTMLWcsGalacticMenuElement;\n private menuButton!: HTMLButtonElement;\n private inheritedAttributes: { [k: string]: any } = {};\n \n @State() private showPopoverMenu: boolean = false;\n private popper: Instance;\n /**\n * Text to be displayed in the galactic bar\n */\n @Prop() text: string;\n private menu;\n private tooltip;\n\n componentDidLoad() {\n this.menu = this.el.shadowRoot.getElementById('toggle-menu-icon');\n this.tooltip = this.el.shadowRoot.getElementById('menu');\n this.popper = createPopper(this.menu, this.tooltip, {\n placement: 'bottom-end',\n modifiers: [\n {\n name: 'offset',\n options: {\n offset: [0, 8]\n }\n }\n ]\n });\n }\n\n componentWillLoad(): Promise<void> | void {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el),\n ...inheritAttributes(this.el, GALACTIC_MENU_INHERITED_ATTRS),\n };\n }\n\n @Method()\n async setAriaAttribute(attr: AriaAttributeName, value: string | null | undefined) {\n setOrRemoveAttribute(this.menuButton, attr, value);\n }\n\n\n @Listen('click', {target: 'window'})\n onWindowClickEvent(event: MouseEvent) {\n if (clickInsideElement(event, this.tooltip) || clickInsideElement(event, this.menu)) {\n return;\n } else {\n if (this.showPopoverMenu) {\n this.toggleMenu();\n }\n }\n }\n\n @Listen('keydown')\n onKeyDown(_event: KeyboardEvent) {\n if (isEscapeKey(_event)) {\n _event.preventDefault();\n this.showPopoverMenu = false;\n this.menuButton?.focus();\n }\n }\n \n private toggleMenu() {\n this.showPopoverMenu = !this.showPopoverMenu;\n }\n\n componentDidRender() {\n if (this.popper) {\n this.popper.update();\n }\n }\n\n render(): any {\n return (\n <Host>\n <span>{this.text}</span>\n <button aria-haspopup=\"true\"\n aria-controls=\"menu\"\n ref={el => {\n this.menuButton = el\n }}\n aria-expanded={this.showPopoverMenu ? \"true\" : \"false\"}\n {...this.inheritedAttributes}\n onClick={_ => this.toggleMenu()}>\n <wcs-mat-icon id=\"toggle-menu-icon\" icon=\"more_horiz\" size=\"m\"></wcs-mat-icon>\n </button>\n <span id=\"menu\" role=\"menu\" data-show={this.showPopoverMenu}>\n <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AA,2DAAsB,OAAM,gBACN,OACdE,IAAKvC,IACDJ,KAAKwB,WAAapB,CAAE,EACvB,gBACcJ,KAAK4B,gBAAkB,OAAS,SAC3C5B,KAAKC,oBAAmB,CAC5B2C,QAASC,GAAK7C,KAAK6B,eACvBU,EAAA,gBAAAE,IAAA,2CAAcK,GAAG,mBAAmBC,KAAK,aAAaC,KAAK,OAE/DT,EAAA,QAAAE,IAAA,2CAAMK,GAAG,OAAOG,KAAK,OAAM,YAAYjD,KAAK4B,iBACxCW,EAAA,OAAAE,IAAA,2CAAKK,GAAG,QAAO,2BACfP,EAAA,QAAAE,IAAA,8C"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as a,c as t,h as s,H as o,g as e}from"./p-32e583ea.js";import{i,a as c}from"./p-fb2751c2.js";import{i as d,a as l,s as r,n}from"./p-52d77e1f.js";const h="wcs-modal{--wcs-modal-backdrop-color:var(--wcs-semantic-color-background-backdrop);--wcs-modal-max-height:80%;--wcs-modal-background-color:var(--wcs-semantic-color-background-surface-primary);--wcs-modal-border-radius:var(--wcs-semantic-border-radius-base);--wcs-modal-padding:calc(3 * var(--wcs-semantic-spacing-base));--wcs-modal-border-width:var(--wcs-semantic-border-width-default);--wcs-modal-border-color:var(--wcs-semantic-color-border-secondary);--wcs-modal-title-margin-bottom:var(--wcs-semantic-spacing-large);--wcs-modal-title-font-size:var(--wcs-semantic-font-size-heading-4);--wcs-modal-title-font-weight:var(--wcs-semantic-font-weight-heavy);--wcs-modal-title-line-height:var(--wcs-semantic-font-line-height-medium);--wcs-modal-actions-margin-top:var(--wcs-semantic-spacing-large);--wcs-modal-width-s:288px;--wcs-modal-width-m:480px;--wcs-modal-width-l:864px;--wcs-modal-width-xl:1200px;z-index:999;position:fixed;top:0;bottom:0;left:0;right:0;display:none;background:var(--wcs-modal-backdrop-color)}wcs-modal[show]{display:flex;height:100vh;width:100vw;align-items:center;justify-content:center}wcs-modal[without-backdrop]{background-color:unset}wcs-modal[without-backdrop] .wcs-modal-container{border:solid var(--wcs-modal-border-width) var(--wcs-modal-border-color)}.wcs-modal-container{max-height:var(--wcs-modal-max-height, 80%);background-color:var(--wcs-modal-background-color);display:grid;grid-template-columns:100%;grid-template-rows:auto 1fr auto;box-sizing:border-box;pointer-events:auto;background-clip:padding-box;border-radius:var(--wcs-modal-border-radius);z-index:20000;padding:var(--wcs-modal-padding)}.wcs-modal-container[data-size=s]{width:var(--wcs-modal-width-s)}.wcs-modal-container[data-size=m]{width:var(--wcs-modal-width-m)}.wcs-modal-container[data-size=l]{width:var(--wcs-modal-width-l)}.wcs-modal-container[data-size=xl]{width:var(--wcs-modal-width-xl)}.wcs-modal-header{margin-bottom:var(--wcs-modal-title-margin-bottom);display:flex;align-items:center;justify-content:space-between}.wcs-modal-header h1{font-size:var(--wcs-modal-title-font-size);font-weight:var(--wcs-modal-title-font-weight);line-height:var(--wcs-modal-title-line-height);margin:0}.wcs-modal-content{overflow-y:var(--wcs-modal-overflow-y, auto)}.wcs-modal-actions{margin-top:var(--wcs-modal-actions-margin-top);display:flex;justify-content:flex-end}";const m=h;const w=[];const f=class{constructor(s){a(this,s);this.wcsDialogClosed=t(this,"wcsDialogClosed",7);this.inheritedAttributes={};this.modalId=b++;this.showAttributeChangedMarker=false;this.hasBeenClosedBefore=false;this.withoutBackdrop=false;this.show=false;this.showCloseButton=false;this.closeButtonAriaLabel="Fermer";this.size="m";this.hideActions=false;this.modalTriggerControlsId=undefined;this.initialFocusElementId=undefined;this.disableAutoFocus=false}componentWillLoad(){if(!this.modalTriggerControlsId){console.warn("wcs-modal: You must provide the modal-trigger-controls-id attribute to the modal to make it to work properly")}this.inheritedAttributes=Object.assign(Object.assign({},d(this.el)),l(this.el,w))}componentDidLoad(){this.updateFocusableElements()}componentDidRender(){var a;this.updateFocusableElements();if(this.showAttributeChangedMarker){this.showAttributeChangedMarker=false;if(this.disableAutoFocus){return}if(!this.initialFocusElementId){(a=this.firstFocusableElement)===null||a===void 0?void 0:a.focus()}else{const a=document.getElementById(this.initialFocusElementId);if(!a){console.warn(`wcs-modal: Unable to focus element - ID '${this.initialFocusElementId}' not found in DOM`)}a===null||a===void 0?void 0:a.focus()}}}async setAriaAttribute(a,t){r(this.nativeDivDialog,a,t)}onShowChange(){if(this.show){this.hasBeenClosedBefore=false;this.showAttributeChangedMarker=true}else{if(this.hasBeenClosedBefore){return}this.hasBeenClosedBefore=true;if(this.modalTriggerControlsId){const a=document.getElementById(this.modalTriggerControlsId);if(!a){console.warn(`wcs-modal: Element with id '${this.modalTriggerControlsId}' could not be found`)}a===null||a===void 0?void 0:a.focus()}}}updateFocusableElements(){const a=Array.from(this.el.querySelectorAll("*")).filter((a=>i(a)));this.firstFocusableElement=a.length>0&&a[0];this.lastFocusableElement=a.length>0&&a[a.length-1]}close(){if(this.show){this.show=false;this.wcsDialogClosed.emit()}}onKeyDown(a){if(this.show&&this.showCloseButton&&a.key==="Escape"){this.close()}if(this.show){if(n(a)){this.updateFocusableElements();const t=this.firstFocusableElement;const s=this.lastFocusableElement;if(a.shiftKey&&c(t)){a.preventDefault();s.focus()}else if(!a.shiftKey&&c(s)){a.preventDefault();t.focus()}}}}onCloseButtonClick(a){this.close()}handleSlotContentChange(){this.updateFocusableElements()}render(){const a=`wcs-modal-title-${this.modalId}`;return s(o,{key:"1b9a4d86bf1e97ef7ef988b7355b75eb5f344ca8"},s("div",Object.assign({key:"ab5e3938796e950e9e3aa81cd35a723d6429a8e6",class:"wcs-modal-container","data-size":this.size,"aria-modal":true,role:"dialog","aria-labelledby":a,ref:a=>this.nativeDivDialog=a},this.inheritedAttributes),s("div",{key:"80fe453c1ffd3453832c799f131d50c97d37954f",class:"wcs-modal-header"},s("h1",{key:"632853fdbc254e92167fafd022b7f0d392b861bc",id:a},s("slot",{key:"b84db0d064adae8e50a013315fd3c593a39a6f99",name:"header"})),this.showCloseButton&&s("wcs-button",{key:"27bf915ff1ccebab3de363d8dae6914de112aa7b",shape:"round",mode:"clear",id:"wcs-modal-close-button","aria-label":this.closeButtonAriaLabel,onClick:a=>this.onCloseButtonClick(a)},s("wcs-mat-icon",{key:"adacfb9e0b2c435d97f35e8423dd21f4bb534212",icon:"close"}))),s("div",{key:"33757197132d566f2ade4ea1c1cf36bc914702b2",class:"wcs-modal-content"},s("slot",{key:"c742e77c50cccc69435c40cf845fa6280a1a7063",onSlotchange:()=>this.handleSlotContentChange()})),!this.hideActions&&s("div",{key:"e98977493e4fc5461fbab1b67d609a1a956b7fbf",class:"wcs-modal-actions"},s("slot",{key:"56168022f0de471106a15b03f7b16c3c6d3cbc1b",name:"actions"}))))}get el(){return e(this)}static get watchers(){return{show:["onShowChange"]}}};let b=0;f.style=m;export{f as wcs_modal};
|
|
2
|
+
//# sourceMappingURL=p-f87636f6.entry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["modalCss","WcsModalStyle0","MODAL_INHERITED_ATTRS","Modal","this","inheritedAttributes","modalId","modalIds","showAttributeChangedMarker","hasBeenClosedBefore","undefined","componentWillLoad","modalTriggerControlsId","console","warn","Object","assign","inheritAriaAttributes","el","inheritAttributes","componentDidLoad","updateFocusableElements","componentDidRender","disableAutoFocus","initialFocusElementId","_a","firstFocusableElement","focus","modalElementToFocusOnOpening","document","getElementById","setAriaAttribute","attr","value","setOrRemoveAttribute","nativeDivDialog","onShowChange","show","modalTriggerControlsHtmlElement","focusableElements","Array","from","querySelectorAll","filter","element","isFocusable","length","lastFocusableElement","close","wcsDialogClosed","emit","onKeyDown","event","showCloseButton","key","isTabKey","firstElement","lastElement","shiftKey","isElementFocused","preventDefault","onCloseButtonClick","_","handleSlotContentChange","render","modalTitleId","h","Host","class","size","role","ref","id","name","shape","mode","closeButtonAriaLabel","onClick","$event","icon","onSlotchange","hideActions"],"sources":["src/components/modal/modal.scss?tag=wcs-modal","src/components/modal/modal.tsx"],"sourcesContent":["wcs-modal {\n --wcs-modal-backdrop-color: var(--wcs-semantic-color-background-backdrop);\n --wcs-modal-max-height: 80%;\n --wcs-modal-background-color: var(--wcs-semantic-color-background-surface-primary);\n --wcs-modal-border-radius: var(--wcs-semantic-border-radius-base);\n --wcs-modal-padding: calc(3 * var(--wcs-semantic-spacing-base));\n --wcs-modal-border-width: var(--wcs-semantic-border-width-default);\n --wcs-modal-border-color: var(--wcs-semantic-color-border-secondary);\n --wcs-modal-title-margin-bottom: var(--wcs-semantic-spacing-large);\n --wcs-modal-title-font-size: var(--wcs-semantic-font-size-heading-4);\n --wcs-modal-title-font-weight: var(--wcs-semantic-font-weight-heavy);\n --wcs-modal-title-line-height: var(--wcs-semantic-font-line-height-medium);\n --wcs-modal-actions-margin-top: var(--wcs-semantic-spacing-large);\n\n // Specific component level tokens\n --wcs-modal-width-s: 288px;\n --wcs-modal-width-m: 480px;\n --wcs-modal-width-l: 864px;\n --wcs-modal-width-xl: 1200px;\n\n z-index: 999;\n position: fixed;\n top: 0;\n bottom: 0;\n left: 0;\n right: 0;\n display: none;\n background: var(--wcs-modal-backdrop-color);\n}\n\nwcs-modal[show] {\n display: flex;\n height: 100vh;\n width: 100vw;\n align-items: center;\n justify-content: center;\n}\n\n/**\nBackdrop\n */\nwcs-modal[without-backdrop] {\n background-color: unset;\n\n .wcs-modal-container {\n border: solid var(--wcs-modal-border-width) var(--wcs-modal-border-color);\n }\n}\n\n/**\nModal window\n */\n.wcs-modal-container {\n max-height: var(--wcs-modal-max-height, 80%);\n background-color: var(--wcs-modal-background-color);\n display: grid;\n grid-template-columns: 100%;\n grid-template-rows: auto 1fr auto;\n box-sizing: border-box;\n pointer-events: auto;\n background-clip: padding-box;\n border-radius: var(--wcs-modal-border-radius);\n z-index: 20000;\n padding: var(--wcs-modal-padding);\n}\n\n.wcs-modal-container[data-size=s] {\n width: var(--wcs-modal-width-s);\n}\n\n.wcs-modal-container[data-size=m] {\n width: var(--wcs-modal-width-m);\n}\n\n.wcs-modal-container[data-size=l] {\n width: var(--wcs-modal-width-l);\n}\n\n.wcs-modal-container[data-size=xl] {\n width: var(--wcs-modal-width-xl);\n}\n\n.wcs-modal-header {\n /* h1 for semantic but h3 for style */\n h1 {\n font-size: var(--wcs-modal-title-font-size);\n font-weight: var(--wcs-modal-title-font-weight);\n line-height: var(--wcs-modal-title-line-height);\n margin: 0;\n }\n\n margin-bottom: var(--wcs-modal-title-margin-bottom);\n display: flex;\n align-items: center;\n justify-content: space-between;\n}\n\n.wcs-modal-content {\n overflow-y: var(--wcs-modal-overflow-y, auto);\n}\n\n.wcs-modal-actions {\n margin-top: var(--wcs-modal-actions-margin-top);\n display: flex;\n justify-content: flex-end;\n}\n","import {\n Element,\n Component,\n Event,\n EventEmitter,\n h,\n Host,\n Listen,\n Prop,\n ComponentInterface,\n Watch, Method\n} from '@stencil/core';\nimport { ModalSize } from './modal-interface';\nimport { isElementFocused, isFocusable } from \"../../utils/accessibility\";\nimport { inheritAriaAttributes, inheritAttributes, isTabKey, setOrRemoveAttribute } from \"../../utils/helpers\";\nimport { AriaAttributeName, MutableAriaAttribute } from \"../../utils/mutable-aria-attribute\";\n\nconst MODAL_INHERITED_ATTRS = [];\n\n/**\n * The modal component (also named dialog or popup) is an interface element that appears on top of the page content.\n * Use it to show a message, a confirmation dialog, or any other content like forms.\n *\n * ## Accessibility guidelines 💡\n * > - Modal element has `role=\"dialog\"` and `aria-modal=\"true\"`\n * > - Keyboard navigation is trapped inside the modal\n * > - It is mandatory to set the `modal-trigger-controls-id` to the id of the element that opens the dialog, in order\n * > to focus it upon dialog dismissal.\n * > - On modal opening, the default behaviour is to focus the first focusable element. If you want to change the initial \n * > behaviour, you have to use `modal-element-id-to-focus-on-opening` attribute to set the id of the inner modal element you \n * > want to focus. You will see a story as example below\n * > - The modal can be closed at any time by pressing the Escape key.\n * >\n * > - More info : https://www.w3.org/WAI/ARIA/apg/patterns/dialog-modal/\n *\n * @cssprop --wcs-modal-max-height - Max height of the main container\n * @cssprop --wcs-modal-overflow-y - Overflow-y of the content\n *\n * @cssprop --wcs-modal-backdrop-color - Backdrop color of the modal\n * @cssprop --wcs-modal-max-height - Max height of the main container\n * @cssprop --wcs-modal-background-color - Background color of the modal\n * @cssprop --wcs-modal-border-radius - Border radius of the modal\n * @cssprop --wcs-modal-padding - Padding inside the modal\n * @cssprop --wcs-modal-border-width - Border width of the modal\n * @cssprop --wcs-modal-border-color - Border color of the modal\n * @cssprop --wcs-modal-title-margin-bottom - Margin bottom of the modal title\n * @cssprop --wcs-modal-title-font-size - Font size of the modal title\n * @cssprop --wcs-modal-title-font-weight - Font weight of the modal title\n * @cssprop --wcs-modal-title-line-height - Line height of the modal title\n * @cssprop --wcs-modal-actions-margin-top - Margin top of the modal actions\n * @cssprop --wcs-modal-width-s - Width of the modal for size small\n * @cssprop --wcs-modal-width-m - Width of the modal for size medium\n * @cssprop --wcs-modal-width-l - Width of the modal for size large\n * @cssprop --wcs-modal-width-xl - Width of the modal for size extra large\n * \n * @slot <no-name> Main container slot\n * @slot header Header container slot (for title)\n * @slot actions Actions container slot (for buttons)\n */\n@Component({\n tag: 'wcs-modal',\n styleUrl: 'modal.scss',\n shadow: false,\n})\nexport class Modal implements ComponentInterface, MutableAriaAttribute {\n @Element() private el: HTMLElement;\n private nativeDivDialog!: HTMLDivElement;\n private inheritedAttributes: { [k: string]: any } = {};\n\n /**\n * Specifies whether the component should display a backdrop on the entire page\n */\n @Prop({reflect: true}) withoutBackdrop: boolean = false;\n\n /**\n * Displays the modal\n */\n @Prop({reflect: true, mutable: true}) show: boolean = false;\n\n /**\n * Triggered when the user leaves the dialog with the closing button.\n */\n @Event() wcsDialogClosed: EventEmitter<void>;\n\n /**\n * Specifies whether the component should display a close button.\n * if false, it won't close the modal when the escape key is pressed.\n */\n @Prop({reflect: true}) showCloseButton: boolean = false;\n\n /**\n * Specifies the aria-label present on the close button when the modal is opened. \n * Only use when `showCloseButton` is `true`.\n */\n @Prop() closeButtonAriaLabel: string = 'Fermer';\n\n /**\n * There are multiple sizes for modals. The default size is medium (m), however other sizes are available. Select the\n * size best suited for the content and screen size displaying the modal. Remember to test responsiveness.\n */\n @Prop() size: ModalSize = 'm';\n\n /**\n * Specifies whether the component should hide the actions slot or not\n */\n @Prop({reflect: true}) hideActions: boolean = false;\n\n /**\n * Specifies which element id controls the modal\n * @private\n */\n @Prop() modalTriggerControlsId: string;\n /**\n * The ID of the element to automatically focus when the modal opens.\n * \n * If this property is not set and `disableAutoFocus` is false, the modal will\n * automatically focus the first focusable element within its content.\n * This follows accessibility best practices by ensuring keyboard navigation\n * starts from a logical point when the modal opens.\n * \n * @example\n * <wcs-modal initial-focus-element=\"cancel-button\"></wcs-modal>\n */\n @Prop() initialFocusElementId?: string = undefined;\n\n /**\n * Disables automatic focus behavior when the modal opens.\n * \n * When set to true, the modal will not automatically focus any element upon opening.\n * Use this property with caution, as managing focus is important for accessibility.\n * Consider providing an alternative focus management strategy if disabling the default behavior.\n */\n @Prop() disableAutoFocus: boolean = false;\n\n /**\n * Give an unique id\n * @private\n */\n private modalId: number = modalIds++;\n\n private firstFocusableElement: HTMLElement;\n private lastFocusableElement: HTMLElement;\n /**\n * This attribute is used to determine whether the show attribute has changed since the last rendering. \n * This allows us to call the focus method on the first element of the modal when the show attribute changes to true. \n * This call is made in the componentDidRender method\n * @private\n */\n private showAttributeChangedMarker: boolean = false;\n /**\n * This attribute is used to determine if the modal has been closed for the first time since its last activation.\n * It is set to 'true' when the modal is first closed, and will be reset to 'false' when the modal is shown again.\n * This state is important for accessibility reasons in order to focus the modal trigger element (like the button \n * which controls the modal)\n *\n * @private\n */\n private hasBeenClosedBefore: boolean = false;\n\n componentWillLoad(): Promise<void> | void {\n if (!this.modalTriggerControlsId) {\n console.warn('wcs-modal: You must provide the modal-trigger-controls-id attribute to the modal to make it to work properly');\n }\n\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el),\n ...inheritAttributes(this.el, MODAL_INHERITED_ATTRS),\n };\n }\n\n componentDidLoad() {\n this.updateFocusableElements();\n }\n\n componentDidRender() {\n this.updateFocusableElements();\n if (this.showAttributeChangedMarker) {\n this.showAttributeChangedMarker = false;\n \n if(this.disableAutoFocus) {\n return;\n }\n \n if(!this.initialFocusElementId) {\n this.firstFocusableElement?.focus();\n } else {\n const modalElementToFocusOnOpening = document.getElementById(this.initialFocusElementId);\n if(!modalElementToFocusOnOpening) {\n console.warn(`wcs-modal: Unable to focus element - ID '${this.initialFocusElementId}' not found in DOM`);\n }\n \n modalElementToFocusOnOpening?.focus();\n }\n }\n }\n\n @Method()\n async setAriaAttribute(attr: AriaAttributeName, value: string | null | undefined) {\n setOrRemoveAttribute(this.nativeDivDialog, attr, value);\n }\n \n @Watch(\"show\")\n onShowChange() {\n if(this.show) {\n this.hasBeenClosedBefore = false;\n this.showAttributeChangedMarker = true;\n } else {\n // if we already made actions when the modal was firstly closed, we do nothing\n if(this.hasBeenClosedBefore) {\n return;\n }\n \n this.hasBeenClosedBefore = true;\n\n if(this.modalTriggerControlsId) {\n const modalTriggerControlsHtmlElement = document.getElementById(this.modalTriggerControlsId);\n if(!modalTriggerControlsHtmlElement) {\n console.warn(`wcs-modal: Element with id '${this.modalTriggerControlsId}' could not be found`);\n }\n modalTriggerControlsHtmlElement?.focus();\n }\n }\n }\n\n private updateFocusableElements() {\n const focusableElements = Array.from(this.el.querySelectorAll('*'))\n .filter(element => isFocusable(element));\n\n this.firstFocusableElement = focusableElements.length > 0 && focusableElements[0] as HTMLElement;\n this.lastFocusableElement = focusableElements.length > 0 && focusableElements[focusableElements.length - 1] as HTMLElement;\n }\n \n private close() {\n // If the modal isn't shown, we don't do anything\n if (this.show) {\n this.show = false;\n this.wcsDialogClosed.emit();\n }\n }\n\n @Listen('keydown', {target: 'document'})\n onKeyDown(event: KeyboardEvent) {\n if (this.show && this.showCloseButton && event.key === 'Escape') {\n this.close();\n }\n\n if (this.show) {\n if (isTabKey(event)) {\n this.updateFocusableElements(); // XXX: maybe a performance issue\n const firstElement = this.firstFocusableElement;\n const lastElement = this.lastFocusableElement;\n\n if (event.shiftKey && isElementFocused(firstElement)) {\n event.preventDefault();\n lastElement.focus();\n } else if (!event.shiftKey && isElementFocused(lastElement)) {\n event.preventDefault();\n firstElement.focus();\n }\n }\n }\n }\n\n private onCloseButtonClick(_: MouseEvent) {\n this.close();\n }\n\n private handleSlotContentChange() {\n this.updateFocusableElements();\n }\n\n render() {\n const modalTitleId = `wcs-modal-title-${this.modalId}`;\n return (\n <Host>\n <div class=\"wcs-modal-container\"\n data-size={this.size}\n aria-modal={true}\n role={\"dialog\"}\n aria-labelledby={modalTitleId}\n ref={(el) => (this.nativeDivDialog = el)}\n {...this.inheritedAttributes}\n >\n <div class=\"wcs-modal-header\">\n <h1 id={modalTitleId}>\n <slot name=\"header\"></slot>\n </h1>\n {this.showCloseButton && (\n <wcs-button shape=\"round\" \n mode=\"clear\" \n id=\"wcs-modal-close-button\"\n aria-label={this.closeButtonAriaLabel}\n onClick={($event) => this.onCloseButtonClick($event)}>\n <wcs-mat-icon icon=\"close\"></wcs-mat-icon>\n </wcs-button>)\n }\n\n </div>\n <div class=\"wcs-modal-content\">\n <slot onSlotchange={() => this.handleSlotContentChange()}></slot>\n </div>\n {!this.hideActions && (\n <div class=\"wcs-modal-actions\">\n <slot name=\"actions\"></slot>\n </div>)\n }\n </div>\n </Host>\n );\n }\n}\n\nlet modalIds = 0;\n"],"mappings":"0JAAA,MAAMA,EAAW,6zEACjB,MAAAC,EAAeD,ECgBf,MAAME,EAAwB,G,MA+CjBC,EAAK,M,0EAGNC,KAAAC,oBAA4C,GAuE5CD,KAAAE,QAAkBC,IAUlBH,KAAAI,2BAAsC,MAStCJ,KAAAK,oBAA+B,M,qBArFW,M,UAKI,M,qBAWJ,M,0BAMX,S,UAMb,I,iBAKoB,M,iEAkBLC,U,sBASL,K,CA2BpC,iBAAAC,GACI,IAAKP,KAAKQ,uBAAwB,CAC9BC,QAAQC,KAAK,+G,CAGjBV,KAAKC,oBAAmBU,OAAAC,OAAAD,OAAAC,OAAA,GACjBC,EAAsBb,KAAKc,KAC3BC,EAAkBf,KAAKc,GAAIhB,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CAAMmB,KAAK,c,+EASvC,IAAIlE,EAAW,E"}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{r as e,c as s,h as t,H as d}from"./p-32e583ea.js";const o=":host{display:block}:host([hidden]){display:none}";const a=o;const c=class{constructor(t){e(this,t);this.tabLoaded=s(this,"tabLoaded",7);this.header=undefined;this.itemKey=undefined}componentDidLoad(){this.tabLoaded.emit()}render(){return t(d,{key:"805ddbb0eafcce267e7f102f8d7c19712d5b04be",slot:"wcs-tab",role:"tabpanel"},t("slot",{key:"ec2afee10cefdf575df100582e769e3bf93d2412"}))}};c.style=a;export{c as wcs_tab};
|
|
2
|
+
//# sourceMappingURL=p-fc115de4.entry.js.map
|
package/dist/wcs/wcs.esm.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{p as e,b as t}from"./p-32e583ea.js";export{s as setNonce}from"./p-32e583ea.js";import{g as a}from"./p-e1255160.js";var n=()=>{const t=import.meta.url;const a={};if(t!==""){a.resourcesUrl=new URL(".",t).href}return e(a)};n().then((async e=>{await a();return t(JSON.parse('[["p-f264d46f",[[1,"wcs-grid-pagination",{"availablePageSizes":[16],"currentPage":[1026,"current-page"],"pageSize":[2,"page-size"],"itemsCount":[2,"items-count"],"pageCount":[2,"page-count"],"setAriaAttribute":[64]}]]],["p-dbbf0980",[[1,"wcs-editable-field",{"type":[1],"label":[1],"readonly":[4],"value":[1032],"validateFn":[16],"formatFn":[16],"errorMsg":[1,"error-msg"],"size":[513],"currentState":[32],"isError":[32]},[[8,"click","onWindowClickEvent"]],{"value":["onValueChange"]}]]],["p-d2a4f609",[[1,"wcs-horizontal-stepper",{"currentStep":[1026,"current-step"],"steps":[16],"mode":[1],"checkOnComplete":[4,"check-on-complete"],"internalCurrentStepIndex":[32],"previous":[64],"next":[64]},null,{"currentStep":["onCurrentStepChange"]}]]],["p-2305f257",[[1,"wcs-breadcrumb",{"maxItems":[2,"max-items"],"itemsBeforeCollapse":[2,"items-before-collapse"],"itemsAfterCollapse":[2,"items-after-collapse"],"ariaLabelExpandButton":[1,"aria-label-expand-button"],"showHiddenItems":[32],"setAriaAttribute":[64]},null,{"maxItems":["handleCollapsePropsChange"],"itemsBeforeCollapse":["handleCollapsePropsChange"],"itemsAfterCollapse":["handleCollapsePropsChange"],"ariaLabelExpandButton":["handleAriaLabelExpandBtnChange"]}]]],["p-985c4cf2",[[17,"wcs-counter",{"size":[513],"label":[1],"disabled":[4],"min":[1026],"max":[1026],"step":[1026],"value":[1026],"displayedValue":[32],"setAriaAttribute":[64]},null,{"value":["valueChange"]}]]],["p-97cbbcfc",[[1,"wcs-grid",{"serverMode":[4,"server-mode"],"data":[16],"loading":[4],"selectionConfig":[1,"selection-config"],"selectedItems":[8,"selected-items"],"wcsGridPaginationId":[1,"wcs-grid-pagination-id"],"rowIdPath":[1,"row-id-path"],"rowCssPartsFn":[16],"columns":[32],"paginationEl":[32],"rows":[32],"cursorPosition":[32],"setAriaAttribute":[64]},[[0,"focus","onFocus"],[0,"blur","onBlur"],[0,"wcsHiddenChange","onHiddenColumnChange"],[0,"keydown","onKeyDown"],[1,"mousedown","onClick"],[0,"wcsSortChange","sortChangeEventHandler"],[0,"wcsGridPaginationChange","paginationChangeEventHandler"],[8,"wcsGridPaginationChange","paginationChangeEventHandlerOutside"]],{"cursorPosition":["onCursorPositionChange"],"data":["onDataChange"],"selectedItems":["onSelectedItemsPropertyChange"]}]]],["p-08e86d69",[[4,"wcs-modal",{"withoutBackdrop":[516,"without-backdrop"],"show":[1540],"showCloseButton":[516,"show-close-button"],"closeButtonAriaLabel":[1,"close-button-aria-label"],"size":[1],"hideActions":[516,"hide-actions"],"modalTriggerControlsId":[1,"modal-trigger-controls-id"],"setAriaAttribute":[64]},[[4,"keydown","onKeyDown"]],{"show":["onShowChange"]}]]],["p-94ff8939",[[17,"wcs-dropdown",{"noArrow":[4,"no-arrow"],"mode":[1],"shape":[1],"size":[1],"disabled":[4],"placement":[1],"expanded":[32],"setAriaAttribute":[64]},[[0,"blur","onBlur"],[8,"click","onWindowClickEvent"],[0,"wcsDropdownItemClick","dropdownItemClick"],[0,"keydown","onKeyDown"]],{"placement":["placementChange"]}]]],["p-8780a429",[[1,"wcs-galactic-menu",{"text":[1],"showPopoverMenu":[32],"setAriaAttribute":[64]},[[8,"click","onWindowClickEvent"],[0,"keydown","onKeyDown"]]]]],["p-52cd0abb",[[17,"wcs-input",{"fireFocusEvents":[4,"fire-focus-events"],"accept":[1],"autocapitalize":[1],"autocomplete":[1],"autocorrect":[1],"autofocus":[4],"debounce":[2],"prefixLabel":[1,"prefix-label"],"suffixLabel":[1,"suffix-label"],"disabled":[4],"enterkeyhint":[1],"size":[513],"icon":[1],"inputmode":[1],"max":[1],"maxlength":[2],"min":[1],"minlength":[2],"multiple":[4],"name":[1],"pattern":[1],"placeholder":[1],"readonly":[4],"required":[4],"spellcheck":[4],"state":[513],"step":[1],"type":[1],"value":[1032],"passwordReveal":[32],"setBlur":[64],"getInputElement":[64],"setAriaAttribute":[64]},null,{"debounce":["debounceChanged"],"passwordReveal":["onPasswordRevealChange"]}]]],["p-85a5bbb7",[[17,"wcs-textarea",{"fireFocusEvents":[4,"fire-focus-events"],"autocapitalize":[1],"autofocus":[4],"debounce":[2],"disabled":[4],"icon":[1],"inputmode":[1],"enterkeyhint":[1],"maxlength":[2],"minlength":[2],"name":[1],"placeholder":[1],"readonly":[4],"required":[4],"spellcheck":[4],"state":[513],"cols":[2],"rows":[2],"wrap":[1],"autoGrow":[4,"auto-grow"],"value":[1025],"resize":[513],"setAriaAttribute":[64],"fitContent":[64],"setBlur":[64],"getInputElement":[64]},null,{"debounce":["debounceChanged"],"value":["valueChanged"]}]]],["p-02f31010",[[1,"wcs-accordion",{"hideActionText":[516,"hide-action-text"],"highlight":[516],"groupContentWithHeader":[516,"group-content-with-header"]},[[0,"wcsOpenChange","wcsOpenChangeHandler"]],{"hideActionText":["updateHideActiontextOnPanel"],"highlight":["updateHighlightOnPanel"],"groupContentWithHeader":["updateGroupContentWithHeader"]}]]],["p-61592f91",[[1,"wcs-accordion-content"]]],["p-439804b0",[[1,"wcs-accordion-header"]]],["p-209145de",[[1,"wcs-accordion-panel",{"open":[1540],"hideActionText":[516,"hide-action-text"],"highlight":[516],"groupContentWithHeader":[516,"group-content-with-header"],"setAriaAttribute":[64],"close":[64]},null,{"open":["openChange"]}]]],["p-9553d60e",[[1,"wcs-action-bar",{"gutter":[4],"hasTabs":[32]}]]],["p-e5c057c4",[[1,"wcs-app"]]],["p-e86575d3",[[1,"wcs-badge",{"shape":[1],"color":[1],"size":[513]}]]],["p-ca8f3677",[[1,"wcs-breadcrumb-item",{"last":[4]}]]],["p-96195d9a",[[1,"wcs-card",{"mode":[1537]}]]],["p-ab49926d",[[1,"wcs-card-body"]]],["p-87b69cac",[[1,"wcs-com-nav",{"appName":[1,"app-name"],"mobileMenuOpen":[32],"currentActiveSizing":[32],"setAriaAttribute":[64]},[[0,"wcsClickOnFinalAction","onClickOnFinalAction"],[8,"keydown","exitMobileMenuOnKeyDown"]]]]],["p-f8d2be83",[[1,"wcs-com-nav-category",{"label":[1],"categoryOpen":[32],"currentActiveSizing":[32],"setAriaAttribute":[64],"close":[64],"open":[64]},[[8,"click","onWindowClickEvent"],[8,"wcsCategoryOpened","onSubmenuOpened"]]]]],["p-db81b74f",[[1,"wcs-com-nav-item",null,[[0,"click","onClick"]]]]],["p-2c9e20c1",[[1,"wcs-com-nav-submenu",{"label":[1],"panelTitle":[1,"panel-title"],"panelDescription":[1,"panel-description"],"menuOpen":[32],"currentActiveSizing":[32],"setAriaAttribute":[64],"close":[64],"open":[64]},[[8,"click","onWindowClickEvent"],[8,"wcsSubmenuOpened","onSubmenuOpened"],[8,"keydown","onEscapeKeyDown"],[0,"wcsClickOnFinalAction","wcsCategoryItemClickedHandler"]]]]],["p-d443d419",[[1,"wcs-divider"]]],["p-550012c2",[[1,"wcs-dropdown-divider"]]],["p-3cfa1c4b",[[1,"wcs-dropdown-header"]]],["p-8f0e093f",[[4,"wcs-dropdown-item",null,[[1,"mouseup","onMouseUp"],[0,"keydown","onKeyDown"]]]]],["p-4982f96c",[[1,"wcs-field"]]],["p-5f517eb5",[[1,"wcs-field-content"]]],["p-19c77b5c",[[1,"wcs-field-label"]]],["p-25b96cde",[[1,"wcs-footer"]]],["p-5ea2aba5",[[1,"wcs-galactic",{"text":[1],"show":[32]}]]],["p-80a23f9c",[[1,"wcs-grid-column",{"path":[1],"name":[1],"sort":[4],"sortFn":[16],"formatter":[16],"sortOrder":[1025,"sort-order"],"width":[1],"customCells":[4,"custom-cells"],"hidden":[4],"cursorPosition":[16],"columnPosition":[2,"column-position"],"setAriaAttribute":[64]},null,{"hidden":["parseMyObjectProp"],"sortOrder":["sortOrderChange"]}]]],["p-400a71d7",[[1,"wcs-grid-custom-cell",{"columnId":[1,"column-id"],"rowId":[8,"row-id"]}]]],["p-76f07dbd",[[1,"wcs-header",{"setAriaAttribute":[64]}]]],["p-a788b5bd",[[1,"wcs-hint",{"small":[1540]}]]],["p-806315e6",[[0,"wcs-icon",{"icon":[1],"size":[1],"setAriaAttribute":[64]}]]],["p-d42831b2",[[1,"wcs-label",{"required":[516],"setAriaAttribute":[64]}]]],["p-1e5aa960",[[1,"wcs-list-item",{"activated":[1028]}]]],["p-e19308cf",[[1,"wcs-list-item-properties"]]],["p-e64d7437",[[1,"wcs-list-item-property"]]],["p-8bd1b9ce",[[1,"wcs-native-select",{"size":[513],"required":[4],"expanded":[32],"disabled":[32],"setAriaAttribute":[64],"updateStyles":[64]},null,{"required":["requiredChanged"]}]]],["p-2add4d4d",[[1,"wcs-nav",{"setAriaAttribute":[64]}]]],["p-4ca7c59f",[[4,"wcs-nav-item",null,[[0,"keydown","onKeyDown"]]]]],["p-15ff9f93",[[1,"wcs-progress-radial",{"size":[2],"showLabel":[4,"show-label"],"value":[2],"setAriaAttribute":[64]}]]],["p-f06aa79d",[[17,"wcs-radio",{"value":[1544],"label":[1537],"disabled":[1028],"name":[1025],"mode":[513],"checked":[32],"radioTabIndex":[32],"updateState":[64],"setTabIndex":[64],"setAriaAttribute":[64]}]]],["p-0fdaec9e",[[1,"wcs-radio-group",{"value":[1032],"name":[520],"mode":[513]},[[0,"wcsRadioClick","handleRadioClick"],[0,"keydown","handleKeyDown"]],{"value":["onValueChangeHandler"],"name":["updateAllRadioModeAndName"],"mode":["updateAllRadioModeAndName"]}]]],["p-45a6934d",[[1,"wcs-skeleton-circle",{"animation":[513],"radius":[514]}]]],["p-9e03b379",[[1,"wcs-skeleton-rectangle",{"animation":[513],"rounded":[516],"height":[513],"width":[513]}]]],["p-b0f8190f",[[1,"wcs-skeleton-text",{"animation":[513],"height":[1]}]]],["p-fd9e731d",[[17,"wcs-switch",{"name":[1],"checked":[516],"labelAlignment":[513,"label-alignment"],"disabled":[4],"setAriaAttribute":[64]},[[0,"click","handleHostClick"]]]]],["p-a66a4289",[[1,"wcs-tab",{"header":[513],"itemKey":[8,"item-key"]}]]],["p-1ab0d13b",[[1,"wcs-tabs",{"align":[513],"selectedIndex":[2,"selected-index"],"selectedKey":[8,"selected-key"],"headersOnly":[4,"headers-only"],"gutter":[4],"description":[1],"headers":[32],"currentActiveTabIndex":[32],"setAriaAttribute":[64]},[[0,"tabLoaded","onTabLoaded"]],{"selectedIndex":["selectedIndexChanged"],"selectedKey":["selectedTabkeyChanged"]}]]],["p-0fa370d7",[[1,"wcs-tooltip",{"for":[1],"position":[513],"interactive":[4],"maxWidth":[8,"max-width"],"delay":[2],"duration":[2],"trigger":[1],"theme":[1],"content":[1],"appendTo":[1,"append-to"],"hide":[64],"show":[64],"disable":[64],"enable":[64]},[[8,"keydown","handleKeyDown"]],{"interactive":["updateProps"],"position":["updateProps"],"maxWidth":["updateProps"],"theme":["updateProps"],"delay":["updateProps"],"duration":["updateProps"],"trigger":["updateProps"],"content":["updateTippyContent"]}]]],["p-9f23c49e",[[1,"wcs-progress-bar",{"size":[1],"showLabel":[4,"show-label"],"value":[2],"setAriaAttribute":[64]}]]],["p-09d0a296",[[4,"wcs-select-option",{"disabled":[1540],"selected":[1540],"highlighted":[1540],"value":[8],"chipColor":[1,"chip-color"],"chipBackgroundColor":[1,"chip-background-color"],"multiple":[1540]},[[1,"mouseup","onMouseUp"],[0,"keydown","handleKeydown"]]],[1,"wcs-select",{"size":[513],"value":[1032],"placeholder":[1537],"disabled":[1028],"multiple":[516],"autocomplete":[516],"serverMode":[516,"server-mode"],"filterFn":[16],"chips":[516],"name":[1],"compareWith":[16],"expanded":[32],"displayText":[32],"focused":[32],"showNoResultFoundLabel":[32],"autocompleteValue":[32],"overlayDirection":[32],"open":[64],"close":[64],"setAriaAttribute":[64]},[[1,"mouseup","onMouseUp"],[8,"click","onWindowClickEvent"],[0,"keydown","onKeyDown"],[0,"wcsSelectOptionClick","selectedOptionChanged"],[0,"focus","onFocus"],[2,"blur","onBlur"]],{"value":["onValueChangeHandler"]}]]],["p-bf31245c",[[1,"wcs-error"],[1,"wcs-form-field",{"isError":[1540,"is-error"],"hasPrefix":[32],"hasSuffix":[32],"spiedElement":[32]},null,{"isError":["isErrorChange"]}]]],["p-cd592a00",[[17,"wcs-checkbox",{"name":[1],"indeterminate":[1540],"checked":[1540],"labelAlignment":[1537,"label-alignment"],"disabled":[516],"setAriaAttribute":[64]},[[0,"click","handleHostClick"]]]]],["p-fa507e06",[[1,"wcs-mat-icon",{"icon":[1],"size":[1],"family":[1],"setAriaAttribute":[64]}]]],["p-276b8125",[[17,"wcs-button",{"type":[1025],"href":[1],"target":[1],"disabled":[516],"ripple":[4],"size":[513],"shape":[513],"mode":[513],"loading":[1028],"setAriaAttribute":[64]},[[0,"click","onClick"]],{"ripple":["onRippleChange"]}],[1,"wcs-spinner",{"mode":[513]}]]]]'),e)}));
|
|
1
|
+
import{p as e,b as t}from"./p-32e583ea.js";export{s as setNonce}from"./p-32e583ea.js";import{g as a}from"./p-e1255160.js";var n=()=>{const t=import.meta.url;const a={};if(t!==""){a.resourcesUrl=new URL(".",t).href}return e(a)};n().then((async e=>{await a();return t(JSON.parse('[["p-94aa269f",[[1,"wcs-editable-field",{"type":[1],"label":[1],"readonly":[516],"value":[1032],"validateFn":[16],"formatFn":[16],"errorMsg":[1,"error-msg"],"size":[513],"currentState":[32],"isError":[32]},[[8,"click","onWindowClickEvent"]],{"value":["onValueChange"]}]]],["p-e36b2ad1",[[1,"wcs-grid-pagination",{"availablePageSizes":[16],"currentPage":[1026,"current-page"],"pageSize":[2,"page-size"],"itemsCount":[2,"items-count"],"pageCount":[2,"page-count"],"setAriaAttribute":[64]}]]],["p-4dc52a25",[[1,"wcs-horizontal-stepper",{"currentStep":[1026,"current-step"],"steps":[16],"mode":[1],"checkOnComplete":[4,"check-on-complete"],"internalCurrentStepIndex":[32],"previous":[64],"next":[64]},null,{"currentStep":["onCurrentStepChange"]}]]],["p-16dd21cf",[[1,"wcs-breadcrumb",{"maxItems":[2,"max-items"],"itemsBeforeCollapse":[2,"items-before-collapse"],"itemsAfterCollapse":[2,"items-after-collapse"],"ariaLabelExpandButton":[1,"aria-label-expand-button"],"showHiddenItems":[32],"setAriaAttribute":[64]},null,{"maxItems":["handleCollapsePropsChange"],"itemsBeforeCollapse":["handleCollapsePropsChange"],"itemsAfterCollapse":["handleCollapsePropsChange"],"ariaLabelExpandButton":["handleAriaLabelExpandBtnChange"]}]]],["p-9dc3f9a5",[[17,"wcs-counter",{"size":[513],"label":[1],"disabled":[516],"min":[1026],"max":[1026],"step":[1026],"value":[1026],"displayedValue":[32],"setAriaAttribute":[64]},null,{"value":["valueChange"]}]]],["p-7d665a7e",[[1,"wcs-grid",{"serverMode":[4,"server-mode"],"data":[16],"loading":[4],"selectionConfig":[1,"selection-config"],"selectedItems":[8,"selected-items"],"wcsGridPaginationId":[1,"wcs-grid-pagination-id"],"rowIdPath":[1,"row-id-path"],"rowCssPartsFn":[16],"columns":[32],"paginationEl":[32],"rows":[32],"cursorPosition":[32],"setAriaAttribute":[64]},[[0,"focus","onFocus"],[0,"blur","onBlur"],[0,"wcsHiddenChange","onHiddenColumnChange"],[0,"keydown","onKeyDown"],[1,"mousedown","onClick"],[0,"wcsSortChange","sortChangeEventHandler"],[0,"wcsGridPaginationChange","paginationChangeEventHandler"],[8,"wcsGridPaginationChange","paginationChangeEventHandlerOutside"]],{"cursorPosition":["onCursorPositionChange"],"data":["onDataChange"],"selectedItems":["onSelectedItemsPropertyChange"]}]]],["p-f87636f6",[[4,"wcs-modal",{"withoutBackdrop":[516,"without-backdrop"],"show":[1540],"showCloseButton":[516,"show-close-button"],"closeButtonAriaLabel":[1,"close-button-aria-label"],"size":[1],"hideActions":[516,"hide-actions"],"modalTriggerControlsId":[1,"modal-trigger-controls-id"],"initialFocusElementId":[1,"initial-focus-element-id"],"disableAutoFocus":[4,"disable-auto-focus"],"setAriaAttribute":[64]},[[4,"keydown","onKeyDown"]],{"show":["onShowChange"]}]]],["p-5de993d7",[[17,"wcs-dropdown",{"noArrow":[4,"no-arrow"],"mode":[1],"shape":[1],"size":[1],"disabled":[516],"placement":[1],"expanded":[32],"setAriaAttribute":[64]},[[0,"blur","onBlur"],[8,"click","onWindowClickEvent"],[0,"wcsDropdownItemClick","dropdownItemClick"],[0,"keydown","onKeyDown"]],{"placement":["placementChange"]}]]],["p-dddcd685",[[1,"wcs-galactic-menu",{"text":[1],"showPopoverMenu":[32],"setAriaAttribute":[64]},[[8,"click","onWindowClickEvent"],[0,"keydown","onKeyDown"]]]]],["p-5974be61",[[17,"wcs-input",{"fireFocusEvents":[4,"fire-focus-events"],"accept":[1],"autocapitalize":[1],"autocomplete":[1],"autocorrect":[1],"autofocus":[4],"debounce":[2],"prefixLabel":[1,"prefix-label"],"suffixLabel":[1,"suffix-label"],"disabled":[516],"enterkeyhint":[1],"size":[513],"icon":[1],"inputmode":[1],"max":[1],"maxlength":[2],"min":[1],"minlength":[2],"multiple":[4],"name":[1],"hidePasswordButtonAriaLabel":[1,"hide-password-button-aria-label"],"showPasswordButtonAriaLabel":[1,"show-password-button-aria-label"],"pattern":[1],"placeholder":[1],"readonly":[516],"required":[4],"spellcheck":[4],"state":[513],"step":[1],"type":[1],"value":[1032],"passwordReveal":[32],"setBlur":[64],"getInputElement":[64],"setAriaAttribute":[64]},null,{"debounce":["debounceChanged"],"passwordReveal":["onPasswordRevealChange"]}]]],["p-206c01d5",[[17,"wcs-textarea",{"fireFocusEvents":[4,"fire-focus-events"],"autocapitalize":[1],"autofocus":[4],"debounce":[2],"disabled":[516],"icon":[1],"inputmode":[1],"enterkeyhint":[1],"maxlength":[2],"minlength":[2],"name":[1],"placeholder":[1],"readonly":[516],"required":[4],"spellcheck":[4],"state":[513],"cols":[2],"rows":[2],"wrap":[1],"autoGrow":[4,"auto-grow"],"value":[1025],"resize":[513],"setAriaAttribute":[64],"fitContent":[64],"setBlur":[64],"getInputElement":[64]},null,{"debounce":["debounceChanged"],"value":["valueChanged"]}]]],["p-02f31010",[[1,"wcs-accordion",{"hideActionText":[516,"hide-action-text"],"highlight":[516],"groupContentWithHeader":[516,"group-content-with-header"]},[[0,"wcsOpenChange","wcsOpenChangeHandler"]],{"hideActionText":["updateHideActiontextOnPanel"],"highlight":["updateHighlightOnPanel"],"groupContentWithHeader":["updateGroupContentWithHeader"]}]]],["p-61592f91",[[1,"wcs-accordion-content"]]],["p-439804b0",[[1,"wcs-accordion-header"]]],["p-76c92e22",[[1,"wcs-accordion-panel",{"open":[1540],"hideActionText":[516,"hide-action-text"],"highlight":[516],"groupContentWithHeader":[516,"group-content-with-header"],"setAriaAttribute":[64],"close":[64]},null,{"open":["openChange"]}]]],["p-4661290b",[[1,"wcs-action-bar",{"gutter":[516],"hasTabs":[32]}]]],["p-e5c057c4",[[1,"wcs-app"]]],["p-1438530e",[[1,"wcs-badge",{"shape":[1],"color":[1],"size":[513]}]]],["p-ca8f3677",[[1,"wcs-breadcrumb-item",{"last":[4]}]]],["p-96195d9a",[[1,"wcs-card",{"mode":[1537]}]]],["p-ab49926d",[[1,"wcs-card-body"]]],["p-9554196c",[[1,"wcs-com-nav",{"appName":[1,"app-name"],"mobileMenuOpen":[32],"currentActiveSizing":[32],"setAriaAttribute":[64]},[[0,"wcsClickOnFinalAction","onClickOnFinalAction"],[8,"keydown","exitMobileMenuOnKeyDown"]]]]],["p-6b06d2e7",[[1,"wcs-com-nav-category",{"label":[1],"categoryOpen":[32],"currentActiveSizing":[32],"setAriaAttribute":[64],"close":[64],"open":[64]},[[8,"click","onWindowClickEvent"],[8,"wcsCategoryOpened","onSubmenuOpened"]]]]],["p-da4636fa",[[1,"wcs-com-nav-item",null,[[0,"click","onClick"]]]]],["p-294732f7",[[1,"wcs-com-nav-submenu",{"label":[1],"panelTitle":[1,"panel-title"],"panelDescription":[1,"panel-description"],"menuOpen":[32],"currentActiveSizing":[32],"setAriaAttribute":[64],"close":[64],"open":[64]},[[8,"click","onWindowClickEvent"],[8,"wcsSubmenuOpened","onSubmenuOpened"],[8,"keydown","onEscapeKeyDown"],[0,"wcsClickOnFinalAction","wcsCategoryItemClickedHandler"]]]]],["p-d443d419",[[1,"wcs-divider"]]],["p-550012c2",[[1,"wcs-dropdown-divider"]]],["p-3cfa1c4b",[[1,"wcs-dropdown-header"]]],["p-13e50077",[[4,"wcs-dropdown-item",null,[[1,"mouseup","onMouseUp"],[0,"keydown","onKeyDown"]]]]],["p-a7891233",[[1,"wcs-field"]]],["p-71db0ed5",[[1,"wcs-field-content"]]],["p-9eb66fa9",[[1,"wcs-field-label"]]],["p-50523b53",[[1,"wcs-footer"]]],["p-9c012aae",[[1,"wcs-galactic",{"text":[1],"show":[32]}]]],["p-96bff8fe",[[1,"wcs-grid-column",{"path":[1],"name":[1],"sort":[4],"sortFn":[16],"formatter":[16],"sortOrder":[1025,"sort-order"],"width":[1],"customCells":[4,"custom-cells"],"hidden":[516],"cursorPosition":[16],"columnPosition":[2,"column-position"],"setAriaAttribute":[64]},null,{"hidden":["parseMyObjectProp"],"sortOrder":["sortOrderChange"]}]]],["p-c752b85a",[[1,"wcs-grid-custom-cell",{"columnId":[1,"column-id"],"rowId":[8,"row-id"]}]]],["p-388e6d75",[[1,"wcs-header",{"setAriaAttribute":[64]}]]],["p-619e1110",[[1,"wcs-hint",{"small":[1540]}]]],["p-b2080509",[[0,"wcs-icon",{"icon":[1],"size":[1],"setAriaAttribute":[64]}]]],["p-d9525519",[[1,"wcs-list-item",{"activated":[1540]}]]],["p-5d5f50ed",[[1,"wcs-list-item-properties"]]],["p-37800935",[[1,"wcs-list-item-property"]]],["p-43d70995",[[1,"wcs-native-select",{"size":[513],"required":[4],"expanded":[32],"disabled":[32],"setAriaAttribute":[64],"updateStyles":[64]},null,{"required":["requiredChanged"]}]]],["p-258855a1",[[1,"wcs-nav",{"setAriaAttribute":[64]}]]],["p-6f5d570a",[[4,"wcs-nav-item",null,[[0,"keydown","onKeyDown"]]]]],["p-29f5b974",[[1,"wcs-progress-radial",{"size":[2],"showLabel":[4,"show-label"],"value":[2],"setAriaAttribute":[64]}]]],["p-796e690d",[[17,"wcs-radio",{"value":[1544],"label":[1537],"disabled":[1540],"name":[1025],"mode":[513],"checked":[32],"radioTabIndex":[32],"updateState":[64],"setTabIndex":[64],"setAriaAttribute":[64]}]]],["p-b96f4921",[[1,"wcs-radio-group",{"value":[1032],"name":[520],"mode":[513],"setAriaAttribute":[64]},[[0,"wcsRadioClick","handleRadioClick"],[0,"keydown","handleKeyDown"]],{"value":["onValueChangeHandler"],"name":["updateAllRadioModeAndName"],"mode":["updateAllRadioModeAndName"]}]]],["p-0ffdfc10",[[1,"wcs-skeleton-circle",{"animation":[513],"radius":[514]}]]],["p-694724a2",[[1,"wcs-skeleton-rectangle",{"animation":[513],"rounded":[516],"height":[513],"width":[513]}]]],["p-d895ffb4",[[1,"wcs-skeleton-text",{"animation":[513],"height":[1]}]]],["p-dd60a6db",[[17,"wcs-switch",{"name":[1],"checked":[516],"labelAlignment":[513,"label-alignment"],"disabled":[516],"setAriaAttribute":[64],"getLabel":[64]},[[0,"click","handleHostClick"]]]]],["p-fc115de4",[[1,"wcs-tab",{"header":[513],"itemKey":[8,"item-key"]}]]],["p-2adf00be",[[1,"wcs-tabs",{"align":[513],"selectedIndex":[2,"selected-index"],"selectedKey":[8,"selected-key"],"headersOnly":[4,"headers-only"],"gutter":[516],"description":[1],"headers":[32],"currentActiveTabIndex":[32],"setAriaAttribute":[64]},[[0,"tabLoaded","onTabLoaded"]],{"selectedIndex":["selectedIndexChanged"],"selectedKey":["selectedTabkeyChanged"]}]]],["p-5bf73e05",[[1,"wcs-tooltip",{"for":[1],"position":[513],"interactive":[4],"maxWidth":[8,"max-width"],"delay":[2],"duration":[2],"trigger":[1],"theme":[1],"content":[1],"appendTo":[1,"append-to"],"hide":[64],"show":[64],"disable":[64],"enable":[64]},[[8,"keydown","handleKeyDown"]],{"interactive":["updateProps"],"position":["updateProps"],"maxWidth":["updateProps"],"theme":["updateProps"],"delay":["updateProps"],"duration":["updateProps"],"trigger":["updateProps"],"content":["updateTippyContent"]}]]],["p-13090618",[[1,"wcs-progress-bar",{"size":[1],"showLabel":[4,"show-label"],"value":[2],"setAriaAttribute":[64]}]]],["p-21b964cd",[[4,"wcs-select-option",{"disabled":[1540],"selected":[1540],"highlighted":[1540],"value":[8],"chipColor":[1,"chip-color"],"chipBackgroundColor":[1,"chip-background-color"],"multiple":[1540]},[[1,"mouseup","onMouseUp"],[0,"keydown","handleKeydown"]]],[1,"wcs-select",{"size":[513],"value":[1032],"placeholder":[1537],"disabled":[1540],"required":[4],"multiple":[516],"autocomplete":[516],"serverMode":[516,"server-mode"],"filterFn":[16],"chips":[516],"name":[1],"compareWith":[16],"expanded":[32],"displayText":[32],"focused":[32],"showNoResultFoundLabel":[32],"autocompleteValue":[32],"overlayDirection":[32],"open":[64],"close":[64],"setAriaAttribute":[64]},[[1,"mouseup","onMouseUp"],[8,"click","onWindowClickEvent"],[0,"keydown","onKeyDown"],[0,"wcsSelectOptionClick","selectedOptionChanged"],[0,"focus","onFocus"],[2,"blur","onBlur"]],{"value":["onValueChangeHandler"]}]]],["p-21d2f06f",[[1,"wcs-error"],[1,"wcs-form-field",{"isError":[1540,"is-error"],"hasPrefix":[32],"hasSuffix":[32],"spiedElement":[32]},null,{"isError":["isErrorChange"]}],[1,"wcs-label",{"required":[516],"setAriaAttribute":[64]}]]],["p-9243a323",[[17,"wcs-checkbox",{"name":[1],"indeterminate":[1540],"checked":[1540],"labelAlignment":[1537,"label-alignment"],"disabled":[516],"setAriaAttribute":[64],"getLabel":[64]},[[0,"click","handleHostClick"]]]]],["p-9ad23e83",[[1,"wcs-mat-icon",{"icon":[1],"size":[1],"family":[1],"setAriaAttribute":[64]}]]],["p-c2d35aa6",[[17,"wcs-button",{"type":[1025],"href":[1],"target":[1],"disabled":[516],"ripple":[4],"size":[513],"shape":[513],"mode":[513],"loading":[1540],"setAriaAttribute":[64]},[[0,"click","onClick"]],{"ripple":["onRippleChange"]}],[1,"wcs-spinner",{"mode":[513]}]]]]'),e)}));
|
|
2
2
|
//# sourceMappingURL=wcs.esm.js.map
|
package/dist/wcs/wcs.esm.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["patchBrowser","importMeta","url","opts","resourcesUrl","URL","href","promiseResolve","then","async","options","globalScripts","bootstrapLazy","JSON","parse"],"sources":["node_modules/@stencil/core/internal/client/patch-browser.js","@lazy-browser-entrypoint?app-data=conditional"],"sourcesContent":["/*\n Stencil Client Patch Browser v4.17.2 | MIT Licensed | https://stenciljs.com\n */\n\n// src/client/client-patch-browser.ts\nimport { BUILD, NAMESPACE } from \"@stencil/core/internal/app-data\";\nimport { consoleDevInfo, doc, H, promiseResolve } from \"@stencil/core\";\nvar patchBrowser = () => {\n if (BUILD.isDev && !BUILD.isTesting) {\n consoleDevInfo(\"Running in development mode.\");\n }\n if (BUILD.cloneNodeFix) {\n patchCloneNodeFix(H.prototype);\n }\n const scriptElm = BUILD.scriptDataOpts ? Array.from(doc.querySelectorAll(\"script\")).find(\n (s) => new RegExp(`/${NAMESPACE}(\\\\.esm)?\\\\.js($|\\\\?|#)`).test(s.src) || s.getAttribute(\"data-stencil-namespace\") === NAMESPACE\n ) : null;\n const importMeta = import.meta.url;\n const opts = BUILD.scriptDataOpts ? (scriptElm || {})[\"data-opts\"] || {} : {};\n if (importMeta !== \"\") {\n opts.resourcesUrl = new URL(\".\", importMeta).href;\n }\n return promiseResolve(opts);\n};\nvar patchCloneNodeFix = (HTMLElementPrototype) => {\n const nativeCloneNodeFn = HTMLElementPrototype.cloneNode;\n HTMLElementPrototype.cloneNode = function(deep) {\n if (this.nodeName === \"TEMPLATE\") {\n return nativeCloneNodeFn.call(this, deep);\n }\n const clonedNode = nativeCloneNodeFn.call(this, false);\n const srcChildNodes = this.childNodes;\n if (deep) {\n for (let i = 0; i < srcChildNodes.length; i++) {\n if (srcChildNodes[i].nodeType !== 2) {\n clonedNode.appendChild(srcChildNodes[i].cloneNode(true));\n }\n }\n }\n return clonedNode;\n };\n};\nexport {\n patchBrowser\n};\n","export { setNonce } from '@stencil/core';\nimport { bootstrapLazy } from '@stencil/core';\nimport { patchBrowser } from '@stencil/core/internal/client/patch-browser';\nimport { globalScripts } from '@stencil/core/internal/app-globals';\npatchBrowser().then(async (options) => {\n await globalScripts();\n return bootstrapLazy([/*!__STENCIL_LAZY_DATA__*/], options);\n});\n"],"mappings":"0HAOA,IAAIA,EAAe,KAUjB,MAAMC,cAAyBC,IAC/B,MAAMC,EAAqE,GAC3E,GAAIF,IAAe,GAAI,CACrBE,EAAKC,aAAe,IAAIC,IAAI,IAAKJ,GAAYK,IACjD,CACE,OAAOC,EAAeJ,EAAK,EClB7BH,IAAeQ,MAAKC,MAAOC,UACnBC,IACN,OAAOC,EAAcC,KAAAC,MAAA,
|
|
1
|
+
{"version":3,"names":["patchBrowser","importMeta","url","opts","resourcesUrl","URL","href","promiseResolve","then","async","options","globalScripts","bootstrapLazy","JSON","parse"],"sources":["node_modules/@stencil/core/internal/client/patch-browser.js","@lazy-browser-entrypoint?app-data=conditional"],"sourcesContent":["/*\n Stencil Client Patch Browser v4.17.2 | MIT Licensed | https://stenciljs.com\n */\n\n// src/client/client-patch-browser.ts\nimport { BUILD, NAMESPACE } from \"@stencil/core/internal/app-data\";\nimport { consoleDevInfo, doc, H, promiseResolve } from \"@stencil/core\";\nvar patchBrowser = () => {\n if (BUILD.isDev && !BUILD.isTesting) {\n consoleDevInfo(\"Running in development mode.\");\n }\n if (BUILD.cloneNodeFix) {\n patchCloneNodeFix(H.prototype);\n }\n const scriptElm = BUILD.scriptDataOpts ? Array.from(doc.querySelectorAll(\"script\")).find(\n (s) => new RegExp(`/${NAMESPACE}(\\\\.esm)?\\\\.js($|\\\\?|#)`).test(s.src) || s.getAttribute(\"data-stencil-namespace\") === NAMESPACE\n ) : null;\n const importMeta = import.meta.url;\n const opts = BUILD.scriptDataOpts ? (scriptElm || {})[\"data-opts\"] || {} : {};\n if (importMeta !== \"\") {\n opts.resourcesUrl = new URL(\".\", importMeta).href;\n }\n return promiseResolve(opts);\n};\nvar patchCloneNodeFix = (HTMLElementPrototype) => {\n const nativeCloneNodeFn = HTMLElementPrototype.cloneNode;\n HTMLElementPrototype.cloneNode = function(deep) {\n if (this.nodeName === \"TEMPLATE\") {\n return nativeCloneNodeFn.call(this, deep);\n }\n const clonedNode = nativeCloneNodeFn.call(this, false);\n const srcChildNodes = this.childNodes;\n if (deep) {\n for (let i = 0; i < srcChildNodes.length; i++) {\n if (srcChildNodes[i].nodeType !== 2) {\n clonedNode.appendChild(srcChildNodes[i].cloneNode(true));\n }\n }\n }\n return clonedNode;\n };\n};\nexport {\n patchBrowser\n};\n","export { setNonce } from '@stencil/core';\nimport { bootstrapLazy } from '@stencil/core';\nimport { patchBrowser } from '@stencil/core/internal/client/patch-browser';\nimport { globalScripts } from '@stencil/core/internal/app-globals';\npatchBrowser().then(async (options) => {\n await globalScripts();\n return bootstrapLazy([/*!__STENCIL_LAZY_DATA__*/], options);\n});\n"],"mappings":"0HAOA,IAAIA,EAAe,KAUjB,MAAMC,cAAyBC,IAC/B,MAAMC,EAAqE,GAC3E,GAA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AAC;SAEe,UAAU,CAAC,GAAkB;IACzC,OAAO,GAAG,CAAC,IAAI,KAAK,OAAO,CAAC;AAChC,CAAC;SAEe,UAAU,CAAC,GAAkB;IACzC,OAAO,GAAG,CAAC,GAAG,KAAK,OAAO,CAAC;AAC/B,CAAC;SAEe,SAAS,CAAC,GAAkB;IACxC,OAAO,GAAG,CAAC,IAAI,KAAK,MAAM,CAAC;AAC/B,CAAC;SAEe,QAAQ,CAAC,GAAkB;IACvC,OAAO,GAAG,CAAC,IAAI,KAAK,KAAK,CAAC;AAC9B,CAAC;SAEe,YAAY,CAAC,GAAkB;IAC3C,OAAO,GAAG,CAAC,GAAG,KAAK,SAAS,CAAC;AACjC,CAAC;SAEe,cAAc,CAAC,GAAkB;IAC7C,OAAO,GAAG,CAAC,GAAG,KAAK,WAAW,CAAC;AACnC,CAAC;SAEe,cAAc,CAAC,GAAkB;IAC7C,OAAO,GAAG,CAAC,GAAG,KAAK,WAAW,CAAC;AACnC,CAAC;SAEe,eAAe,CAAC,GAAkB;IAC9C,OAAO,GAAG,CAAC,GAAG,KAAK,YAAY,CAAC;AACpC,CAAC;SAEe,aAAa,CAAC,GAAkB;IAC5C,OAAO,GAAG,CAAC,GAAG,KAAK,UAAU,CAAC;AAClC,CAAC;SAEe,WAAW,CAAC,GAAkB;IAC1C,OAAO,GAAG,CAAC,GAAG,KAAK,QAAQ,CAAC;AAChC,CAAC;SAEe,QAAQ,CAAC,GAAkB;IACvC,OAAO,GAAG,CAAC,GAAG,KAAK,KAAK,CAAC;AAC7B,CAAC;SAMe,uBAAuB,CAAC,IAAY;IAChD,OAAO,MAAM,CAAC,gBAAgB,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,gBAAgB,CAAC,IAAI,CAAC,IAAI,IAAI,CAAC;AACjF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/utils/helpers.ts"],"sourcesContent":["import { EventEmitter } from '@stencil/core';\n\nexport function isElement(element: any): element is Element {\n return 'clientWidth' in element\n && 'clientHeight' in element;\n}\n\nexport function hasShadowDom(el: HTMLElement) {\n return !!el.shadowRoot && !!(el as any).attachShadow;\n}\n\nexport const debounceEvent = (event: EventEmitter, wait: number): EventEmitter => {\n const original = (event as any)._original || event;\n return {\n _original: event,\n emit: debounce(original.emit.bind(original), wait)\n } as EventEmitter;\n};\n\nexport const debounce = (func: (...args: any[]) => void, wait = 0) => {\n let timer: any;\n return (...args: any[]): any => {\n clearTimeout(timer);\n timer = setTimeout(func, wait, ...args);\n };\n};\n\n/**\n * Elements inside of web components sometimes need to inherit global attributes\n * set on the host. For example, the inner input in `wcs-input` should inherit\n * the `title` attribute that developers set directly on `wcs-input`. This\n * helper function should be called in componentWillLoad and assigned to a variable\n * that is later used in the render function.\n *\n * This does not need to be reactive as changing attributes on the host element\n * does not trigger a re-render.\n */\nexport const inheritAttributes = (el: HTMLElement, attributes: string[] = []) => {\n const attributeObject: { [k: string]: any } = {};\n\n attributes.forEach(attr => {\n if (el.hasAttribute(attr)) {\n const value = el.getAttribute(attr);\n if (value !== null) {\n attributeObject[attr] = el.getAttribute(attr);\n }\n el.removeAttribute(attr);\n }\n });\n\n return attributeObject;\n}\n\n/**\n * List of available ARIA attributes + `role`.\n * Removed deprecated attributes.\n * https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes\n */\nconst ariaAttributes = [\n 'role',\n 'aria-activedescendant',\n 'aria-atomic',\n 'aria-autocomplete',\n 'aria-braillelabel',\n 'aria-brailleroledescription',\n 'aria-busy',\n 'aria-checked',\n 'aria-colcount',\n 'aria-colindex',\n 'aria-colindextext',\n 'aria-colspan',\n 'aria-controls',\n 'aria-current',\n 'aria-describedby',\n 'aria-description',\n 'aria-details',\n 'aria-disabled',\n 'aria-errormessage',\n 'aria-expanded',\n 'aria-flowto',\n 'aria-haspopup',\n 'aria-hidden',\n 'aria-invalid',\n 'aria-keyshortcuts',\n 'aria-label',\n 'aria-labelledby',\n 'aria-level',\n 'aria-live',\n 'aria-multiline',\n 'aria-multiselectable',\n 'aria-orientation',\n 'aria-owns',\n 'aria-placeholder',\n 'aria-posinset',\n 'aria-pressed',\n 'aria-readonly',\n 'aria-relevant',\n 'aria-required',\n 'aria-roledescription',\n 'aria-rowcount',\n 'aria-rowindex',\n 'aria-rowindextext',\n 'aria-rowspan',\n 'aria-selected',\n 'aria-setsize',\n 'aria-sort',\n 'aria-valuemax',\n 'aria-valuemin',\n 'aria-valuenow',\n 'aria-valuetext',\n];\n\n/**\n * Returns an array of aria attributes that should be copied from\n * the shadow host element to a target within the light DOM.\n * @param el The element that the attributes should be copied from.\n * @param ignoreList The list of aria-attributes to ignore reflecting and removing from the host.\n * Use this in instances where we manually specify aria attributes on the `<Host>` element.\n */\nexport const inheritAriaAttributes = (el: HTMLElement, ignoreList?: string[]) => {\n let attributesToInherit = ariaAttributes;\n if (ignoreList && ignoreList.length > 0) {\n attributesToInherit = attributesToInherit.filter((attr) => !ignoreList.includes(attr));\n }\n return inheritAttributes(el, attributesToInherit);\n};\n\n/**\n * Dynamically add or remove an attribute on the element.\n * If the value of the attribute is null or undefined, the attribute is removed.\n *\n * @param el - The HTMLElement\n * @param attr - The attribute to be added or removed\n * @param value - The value of the attribute\n */\nexport function setOrRemoveAttribute(el: HTMLElement, attr: string, value: string | null | undefined) {\n if (el) {\n if (value === undefined || value === null) {\n el.removeAttribute(attr);\n } else {\n el.setAttribute(attr, value);\n }\n }\n}\n\nexport const findItemLabel = (componentEl: HTMLElement): HTMLWcsLabelElement | null => {\n const itemEl = componentEl.closest('wcs-form-field');\n if (itemEl) {\n return itemEl.querySelector('wcs-label');\n }\n return null;\n};\n\n/**\n * Given two lists of items, this function will return the items that were removed, kept, and added compared to the source list.\n * @param sourceList - The source list of items\n * @param newList - The target list of items\n * @param compareFn - The function to compare the items\n */\nexport const compareLists: <T>(sourceList: T[], newList: T[], compareFn: (v1: T, v2: T) => boolean) => {\n removed: T[];\n kept: T[];\n added: T[]\n} = <T>(sourceList: T[], newList: T[], compareFn: (v1: T, v2: T) => boolean) => {\n const removed = sourceList.filter(val => !newList.some(newVal => compareFn(val, newVal)));\n const kept = sourceList.filter(val => newList.some(newVal => compareFn(val, newVal)));\n const added = newList.filter(val => !sourceList.some(sourceVal => compareFn(val, sourceVal)));\n\n return { removed, kept, added };\n};\n\n\ndeclare const __zone_symbol__requestAnimationFrame: any;\n\n/**\n * Patched version of requestAnimationFrame that avoids ngzone\n * Use only when you know ngzone should not run\n */\nexport const raf = (h: any) => {\n if (typeof __zone_symbol__requestAnimationFrame === 'function') {\n return __zone_symbol__requestAnimationFrame(h);\n }\n if (typeof requestAnimationFrame === 'function') {\n return requestAnimationFrame(h);\n }\n return setTimeout(h);\n};\n\n/**\n * Return true if the mouseEvent click is inside the given HTML element\n */\nexport const clickInsideElement = (event: MouseEvent, element: HTMLElement): boolean => {\n return event.x >= element.getBoundingClientRect().x && event.x <= element.getBoundingClientRect().x + element.getBoundingClientRect().width\n && event.y >= element.getBoundingClientRect().y && event.y <= element.getBoundingClientRect().y + element.getBoundingClientRect().height;\n}\n\n\nexport const clickTargetIsElementOrChildren = (mouseEvent: MouseEvent, element: HTMLElement) => {\n return mouseEvent.target instanceof Node\n && element.contains(mouseEvent.target);\n}\n\nexport function generateUniqueId(componentName: string): string {\n return componentName + \"-\" + Math.random().toString(36);\n}\n\nexport function isKeyup(evt: KeyboardEvent) {\n return evt.code === 'ArrowUp';\n}\n\nexport function isKeydown(evt: KeyboardEvent) {\n return evt.code === 'ArrowDown';\n}\n\nexport function isEscapeKey(evt: KeyboardEvent) {\n return evt.code === 'Escape';\n}\n\nexport function isSpaceKey(evt: KeyboardEvent) {\n return evt.code === 'Space';\n}\n\nexport function isEnterKey(evt: KeyboardEvent) {\n return evt.key === 'Enter';\n}\n\nexport function isHomeKey(evt: KeyboardEvent) {\n return evt.code === 'Home';\n}\n\nexport function isEndKey(evt: KeyboardEvent) {\n return evt.code === 'End';\n}\n\nexport function isUpArrowKey(evt: KeyboardEvent) {\n return evt.key === 'ArrowUp';\n}\n\nexport function isDownArrowKey(evt: KeyboardEvent) {\n return evt.key === 'ArrowDown';\n}\n\nexport function isLeftArrowKey(evt: KeyboardEvent) {\n return evt.key === 'ArrowLeft';\n}\n\nexport function isRightArrowKey(evt: KeyboardEvent) {\n return evt.key === 'ArrowRight';\n}\n\nexport function isPageDownKey(evt: KeyboardEvent) {\n return evt.key === 'PageDown';\n}\n\nexport function isPageUpKey(evt: KeyboardEvent) {\n return evt.key === 'PageUp';\n}\n\nexport function isTabKey(evt: KeyboardEvent) {\n return evt.key === 'Tab';\n}\n\nexport function isCtrlA(evt: KeyboardEvent) {\n return evt.key === 'a' && evt.ctrlKey;\n}\n\nexport function getCssRootPropertyValue(name: string): string | null {\n return window.getComputedStyle(document.body).getPropertyValue(name) || null;\n}\n"],"version":3}
|
|
@@ -1,168 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
-
|
|
5
|
-
const index = require('./index-6f0140d8.js');
|
|
6
|
-
const mutableAriaAttribute = require('./mutable-aria-attribute-342a2304.js');
|
|
7
|
-
|
|
8
|
-
const errorCss = ":host{--wcs-error-color:var(--wcs-semantic-color-text-critical);--wcs-error-font-size:var(--wcs-semantic-font-size-caption-2);--wcs-error-font-weight:var(--wcs-semantic-font-weight-book);color:var(--wcs-error-color);font-size:var(--wcs-error-font-size);font-weight:var(--wcs-error-font-weight)}";
|
|
9
|
-
const WcsErrorStyle0 = errorCss;
|
|
10
|
-
|
|
11
|
-
const Label = class {
|
|
12
|
-
constructor(hostRef) {
|
|
13
|
-
index.registerInstance(this, hostRef);
|
|
14
|
-
}
|
|
15
|
-
render() {
|
|
16
|
-
return (index.h(index.Host, { key: '2257210c2e97d6c4dc04a87fa05121e203b79619', "aria-live": "polite", "aria-atomic": "true", slot: "error" }, index.h("slot", { key: 'fc76b174cb85991bb4cd899b72605b171f8165e6' })));
|
|
17
|
-
}
|
|
18
|
-
};
|
|
19
|
-
Label.style = WcsErrorStyle0;
|
|
20
|
-
|
|
21
|
-
const formFieldCss = ":host{--wcs-form-field-gap:var(--wcs-semantic-spacing-small);--wcs-form-field-prefix-suffix-border-radius:var(--wcs-semantic-border-radius-base);--wcs-form-field-prefix-icon-color:var(--wcs-semantic-color-foreground-primary);--wcs-form-field-prefix-value-color:var(--wcs-semantic-color-text-inverse);--wcs-form-field-prefix-placeholder-color:var(--wcs-semantic-color-text-inverse);display:flex;flex-direction:column;gap:var(--wcs-form-field-gap)}:host ::slotted([slot=prefix]){--wcs-select-value-color:var(--wcs-semantic-color-text-inverse);--wcs-select-placeholder-color:var(--wcs-semantic-color-text-inverse);--wcs-select-control-background-color:var(--wcs-semantic-color-background-action-primary-default);--wcs-select-control-arrow-color:var(--wcs-form-field-prefix-icon-color);--wcs-select-control-border-radius:var(--wcs-form-field-prefix-suffix-border-radius) 0 0 var(--wcs-form-field-prefix-suffix-border-radius);--wcs-select-control-border-width-default:0;--wcs-select-control-border-style-focus:dashed;--wcs-select-control-border-color-focus:var(--wcs-semantic-color-border-focus-base);--wcs-native-select-value-color:var(--wcs-semantic-color-text-inverse);--wcs-native-select-placeholder-color:var(--wcs-semantic-color-text-inverse);--wcs-native-select-arrow-color:var(--wcs-form-field-prefix-icon-color);--wcs-native-select-background-color:var(--wcs-semantic-color-background-action-primary-default);--wcs-native-select-border-width:0;--wcs-native-select-border-color-focus:var(--wcs-semantic-color-border-focus-base);--wcs-native-select-border-style-focus:dashed;--wcs-native-select-border-radius:var(--wcs-form-field-prefix-suffix-border-radius) 0 0 var(--wcs-form-field-prefix-suffix-border-radius);--wcs-native-select-option-color:var(--wcs-semantic-color-text-inverse)}:host ::slotted([slot=prefix][disabled]),:host ::slotted([slot=prefix]:disabled),:host ::slotted([slot=prefix][aria-disabled=true]),:host ::slotted([slot=prefix][data-disabled]){--wcs-semantic-color-background-control-disabled:var(--wcs-semantic-color-background-action-primary-disabled);--wcs-semantic-color-text-disabled:var(--wcs-semantic-color-foreground-disabled);--wcs-select-control-background-color:var(--wcs-semantic-color-background-action-primary-disabled);--wcs-select-value-color:var(--wcs-semantic-color-text-disabled);--wcs-select-placeholder-color:var(--wcs-semantic-color-text-disabled);--wcs-native-select-background-color:var(--wcs-semantic-color-background-action-primary-disabled);--wcs-native-select-placeholder-color:var(--wcs-semantic-color-text-disabled);--wcs-native-select-value-color:var(--wcs-semantic-color-text-disabled)}:host ::slotted([slot=prefix]:hover:not([disabled]):not([data-disabled])){--wcs-select-control-background-color:var(--wcs-semantic-color-background-action-primary-hover);--wcs-native-select-background-color:var(--wcs-semantic-color-background-action-primary-hover)}:host ::slotted([slot=prefix]:active:not([disabled]):not([data-disabled])){--wcs-select-control-background-color:var(--wcs-semantic-color-background-action-primary-press);--wcs-native-select-background-color:var(--wcs-semantic-color-background-action-primary-press)}.input-container{display:flex}::slotted(wcs-select:not([slot=prefix])){width:100%}::slotted(wcs-native-select:not([slot=prefix])){width:100%}:host(.has-prefix) ::slotted(wcs-input){--wcs-input-border-radius-left:0}:host(.has-suffix) ::slotted(wcs-input){--wcs-input-border-radius-right:0}::slotted([slot=suffix]){--wcs-button-border-radius:0 var(--wcs-form-field-prefix-suffix-border-radius) var(--wcs-form-field-prefix-suffix-border-radius) 0;--wcs-select-control-border-radius:0 var(--wcs-form-field-prefix-suffix-border-radius) var(--wcs-form-field-prefix-suffix-border-radius) 0;--wcs-native-select-border-radius:0 var(--wcs-form-field-prefix-suffix-border-radius) var(--wcs-form-field-prefix-suffix-border-radius) 0}";
|
|
22
|
-
const WcsFormFieldStyle0 = formFieldCss;
|
|
23
|
-
|
|
24
|
-
const FormField = class {
|
|
25
|
-
constructor(hostRef) {
|
|
26
|
-
index.registerInstance(this, hostRef);
|
|
27
|
-
this.isError = false;
|
|
28
|
-
this.hasPrefix = false;
|
|
29
|
-
this.hasSuffix = false;
|
|
30
|
-
this.spiedElement = undefined;
|
|
31
|
-
}
|
|
32
|
-
componentWillLoad() {
|
|
33
|
-
this.hasSuffix = this.el.querySelector('wcs-button') !== null;
|
|
34
|
-
this.hasPrefix = this.el.querySelector('wcs-select') !== null;
|
|
35
|
-
}
|
|
36
|
-
componentDidLoad() {
|
|
37
|
-
this.initSpiedElement();
|
|
38
|
-
this.addRequiredMarkerToLabel();
|
|
39
|
-
this.updateErrorStateOnInput(this.isError);
|
|
40
|
-
}
|
|
41
|
-
isErrorChange(newValue) {
|
|
42
|
-
this.updateErrorStateOnInput(newValue);
|
|
43
|
-
this.updateAriaAttributes();
|
|
44
|
-
}
|
|
45
|
-
updateErrorStateOnInput(newValue) {
|
|
46
|
-
if (this.spiedElementIsOfType('wcs-input', 'wcs-textarea')) {
|
|
47
|
-
if (newValue) {
|
|
48
|
-
this.spiedElement.setAttribute('state', 'error');
|
|
49
|
-
}
|
|
50
|
-
else {
|
|
51
|
-
this.spiedElement.setAttribute('state', 'initial');
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
/**
|
|
56
|
-
* This function return true if the form field contains an element with tagName matches a value of the types param
|
|
57
|
-
* @param types
|
|
58
|
-
* @private
|
|
59
|
-
*/
|
|
60
|
-
spiedElementIsOfType(...types) {
|
|
61
|
-
var _a;
|
|
62
|
-
for (const type of types) {
|
|
63
|
-
if (((_a = this.spiedElement) === null || _a === void 0 ? void 0 : _a.tagName) === type.toUpperCase())
|
|
64
|
-
return true;
|
|
65
|
-
}
|
|
66
|
-
return false;
|
|
67
|
-
}
|
|
68
|
-
addRequiredMarkerToLabel() {
|
|
69
|
-
var _a;
|
|
70
|
-
// TODO: deprecate this in favor of the 'required' component attribute
|
|
71
|
-
const label = this.el.querySelector('wcs-label');
|
|
72
|
-
this.observer = new MutationObserver(mutations => {
|
|
73
|
-
var _a;
|
|
74
|
-
const requiredAttMutation = mutations.filter(m => m.attributeName === 'required')[0];
|
|
75
|
-
if (requiredAttMutation) {
|
|
76
|
-
this.updateLabelRequiredFlag((_a = this.spiedElement) === null || _a === void 0 ? void 0 : _a.hasAttribute('required'), label);
|
|
77
|
-
}
|
|
78
|
-
});
|
|
79
|
-
if (this.spiedElement) {
|
|
80
|
-
this.observer.observe(this.spiedElement, { attributes: true });
|
|
81
|
-
}
|
|
82
|
-
const isRequired = (_a = this.spiedElement) === null || _a === void 0 ? void 0 : _a.hasAttribute('required');
|
|
83
|
-
this.updateLabelRequiredFlag(isRequired, label);
|
|
84
|
-
}
|
|
85
|
-
initSpiedElement() {
|
|
86
|
-
var _a, _b;
|
|
87
|
-
const SUPPORTED_COMPONENTS = ['wcs-input', 'wcs-select', 'wcs-native-select', 'wcs-textarea', 'wcs-radio-group', 'wcs-switch', 'wcs-checkbox', 'wcs-native-select', 'wcs-counter'];
|
|
88
|
-
this.spiedElement = (_a = this.el.shadowRoot.querySelector('slot:not([name])')) === null || _a === void 0 ? void 0 : _a.assignedElements().filter(n => [...SUPPORTED_COMPONENTS, 'SLOT'].map(x => x.toUpperCase()).indexOf(n.nodeName) !== -1)[0];
|
|
89
|
-
// If the component is used in another web component
|
|
90
|
-
if (((_b = this.spiedElement) === null || _b === void 0 ? void 0 : _b.tagName) === 'SLOT') {
|
|
91
|
-
this.spiedElement = (this.spiedElement
|
|
92
|
-
.assignedElements()
|
|
93
|
-
.filter(n => SUPPORTED_COMPONENTS.map(x => x.toUpperCase()).indexOf(n.nodeName) !== -1)[0]);
|
|
94
|
-
}
|
|
95
|
-
if (!this.spiedElement) {
|
|
96
|
-
// tslint:disable-next-line:no-console
|
|
97
|
-
console.warn('Form-field component support only ' + SUPPORTED_COMPONENTS.toString() + '. Some features may not work with the provided component.');
|
|
98
|
-
return;
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
updateAriaAttributes() {
|
|
102
|
-
if (mutableAriaAttribute.isMutableAriaAttribute(this.spiedElement)) {
|
|
103
|
-
this.spiedElement.setAriaAttribute('aria-label', this.label);
|
|
104
|
-
// Sur les autres DS, généralement seul l'erreur est affichée et pas avec la description
|
|
105
|
-
if (this.isError) {
|
|
106
|
-
if (this.error)
|
|
107
|
-
this.spiedElement.setAriaAttribute('aria-description', this.error);
|
|
108
|
-
this.spiedElement.setAriaAttribute('aria-invalid', 'true');
|
|
109
|
-
}
|
|
110
|
-
else {
|
|
111
|
-
if (this.description)
|
|
112
|
-
this.spiedElement.setAriaAttribute('aria-description', this.description);
|
|
113
|
-
this.spiedElement.setAriaAttribute('aria-invalid', 'false');
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
|
-
}
|
|
117
|
-
get label() {
|
|
118
|
-
var _a;
|
|
119
|
-
return (_a = this.el.querySelector('wcs-label')) === null || _a === void 0 ? void 0 : _a.textContent;
|
|
120
|
-
}
|
|
121
|
-
get description() {
|
|
122
|
-
var _a;
|
|
123
|
-
return (_a = this.el.querySelector('wcs-hint')) === null || _a === void 0 ? void 0 : _a.textContent;
|
|
124
|
-
}
|
|
125
|
-
get error() {
|
|
126
|
-
var _a;
|
|
127
|
-
return (_a = this.el.querySelector('wcs-error')) === null || _a === void 0 ? void 0 : _a.textContent;
|
|
128
|
-
}
|
|
129
|
-
updateLabelRequiredFlag(isRequired, label) {
|
|
130
|
-
if (isRequired && label) {
|
|
131
|
-
label.setAttribute('required', 'true');
|
|
132
|
-
}
|
|
133
|
-
else if (!isRequired && label) {
|
|
134
|
-
label.removeAttribute('required');
|
|
135
|
-
}
|
|
136
|
-
}
|
|
137
|
-
disconnectedCallback() {
|
|
138
|
-
var _a;
|
|
139
|
-
(_a = this.observer) === null || _a === void 0 ? void 0 : _a.disconnect();
|
|
140
|
-
}
|
|
141
|
-
render() {
|
|
142
|
-
let classes = '';
|
|
143
|
-
const isError = this.isError;
|
|
144
|
-
if (this.hasSuffix) {
|
|
145
|
-
classes += ' has-suffix';
|
|
146
|
-
}
|
|
147
|
-
if (this.hasPrefix) {
|
|
148
|
-
classes += ' has-prefix';
|
|
149
|
-
}
|
|
150
|
-
return (index.h(index.Host, { key: 'c9f7040c27e964d32f5d39befad34fd2500ad89b', class: classes }, index.h("slot", { key: '580960c53f66356e3e8a67436603f3d5d0828409', name: "label" }), index.h("div", { key: '9f942bf24140c7c3718d4e56b5c356e4471c246b', class: "input-container" }, index.h("slot", { key: '03ac6862d220be32e3c62d6fa6b49d745f77f1f8', name: "prefix" }), index.h("slot", { key: '476c0419a0269dde5d3b89b025f475c54fa7a1f4', onSlotchange: () => this.onFormInputSlotChange() }), index.h("slot", { key: '63e76f50c004442ad27dbdf87c59fdb574a24352', name: "suffix" })), isError ? (index.h("slot", { name: "error" })) : '', index.h("slot", { key: 'd6dd0c622edbaf25c38844f62e46efefb462d616', name: "messages" })));
|
|
151
|
-
}
|
|
152
|
-
onFormInputSlotChange() {
|
|
153
|
-
this.initSpiedElement();
|
|
154
|
-
this.updateAriaAttributes();
|
|
155
|
-
this.addRequiredMarkerToLabel();
|
|
156
|
-
this.updateErrorStateOnInput(this.isError);
|
|
157
|
-
}
|
|
158
|
-
get el() { return index.getElement(this); }
|
|
159
|
-
static get watchers() { return {
|
|
160
|
-
"isError": ["isErrorChange"]
|
|
161
|
-
}; }
|
|
162
|
-
};
|
|
163
|
-
FormField.style = WcsFormFieldStyle0;
|
|
164
|
-
|
|
165
|
-
exports.wcs_error = Label;
|
|
166
|
-
exports.wcs_form_field = FormField;
|
|
167
|
-
|
|
168
|
-
//# sourceMappingURL=wcs-error_2.cjs.entry.js.map
|