wcs-core 7.5.0 → 7.6.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/bundle/{p-763371a0.js → p-1329a1af.js} +3 -3
- package/bundle/p-1329a1af.js.map +1 -0
- package/bundle/p-2f7bca1e.js +2 -0
- package/bundle/p-2f7bca1e.js.map +1 -0
- package/bundle/p-475be4d2.js +2 -0
- package/bundle/{p-010cf905.js → p-5ef2bc63.js} +2 -2
- package/bundle/{p-44a3b0b9.js → p-7a06295b.js} +2 -2
- package/bundle/{p-2751ddc1.js → p-8b186fcf.js} +2 -2
- package/bundle/{p-d23d7658.js → p-a0268a31.js} +2 -2
- package/bundle/{p-c8b73e93.js → p-bce8c93f.js} +2 -2
- package/bundle/{p-2e9b9605.js → p-bf326ae8.js} +2 -2
- package/bundle/{p-98bd8a96.js → p-d018450c.js} +2 -2
- package/bundle/p-d05140f5.js +2 -0
- package/bundle/p-d05140f5.js.map +1 -0
- package/bundle/{p-f0dda0b8.js → p-d3fe6951.js} +2 -2
- package/bundle/{p-9c2aa87a.js → p-ee6ff5f8.js} +2 -2
- package/bundle/{p-cdc6f6c2.js → p-ff261e50.js} +2 -2
- package/bundle/wcs-accordion-panel.js +1 -1
- package/bundle/wcs-alert-drawer.js +1 -1
- package/bundle/wcs-alert.js +1 -1
- package/bundle/wcs-breadcrumb.js +1 -1
- package/bundle/wcs-button.js +1 -1
- package/bundle/wcs-card-content.js +1 -1
- package/bundle/wcs-card-content.js.map +1 -1
- package/bundle/wcs-card.js +1 -1
- package/bundle/wcs-card.js.map +1 -1
- package/bundle/wcs-checkbox.js +1 -1
- package/bundle/wcs-com-nav-category.js +1 -1
- package/bundle/wcs-com-nav-submenu.js +1 -1
- package/bundle/wcs-com-nav.js +1 -1
- package/bundle/wcs-counter.js +1 -1
- package/bundle/wcs-dropdown-item.js +1 -1
- package/bundle/wcs-dropdown.js +1 -1
- package/bundle/wcs-dropdown.js.map +1 -1
- package/bundle/wcs-editable-field.js +1 -1
- package/bundle/wcs-editable-field.js.map +1 -1
- package/bundle/wcs-form-field.js +1 -1
- package/bundle/wcs-galactic-menu.js +1 -1
- package/bundle/wcs-grid-column.js +1 -1
- package/bundle/wcs-grid-column.js.map +1 -1
- package/bundle/wcs-grid-custom-cell.js +1 -1
- package/bundle/wcs-grid-custom-cell.js.map +1 -1
- package/bundle/wcs-grid-pagination.js +1 -1
- package/bundle/wcs-grid.js +1 -1
- package/bundle/wcs-grid.js.map +1 -1
- package/bundle/wcs-header.js +1 -1
- package/bundle/wcs-hint.js +1 -1
- package/bundle/wcs-horizontal-stepper.js +1 -1
- package/bundle/wcs-icon.js +1 -1
- package/bundle/wcs-input.js +1 -1
- package/bundle/wcs-input.js.map +1 -1
- package/bundle/wcs-label.js +1 -1
- package/bundle/wcs-list-item-properties.js +1 -1
- package/bundle/wcs-list-item-property.js +1 -1
- package/bundle/wcs-list-item.js +1 -1
- package/bundle/wcs-mat-icon.js +1 -1
- package/bundle/wcs-modal.js +1 -1
- package/bundle/wcs-native-select.js +1 -1
- package/bundle/wcs-nav-item.js +1 -1
- package/bundle/wcs-nav.js +1 -1
- package/bundle/wcs-progress-bar.js +1 -1
- package/bundle/wcs-progress-radial.js +1 -1
- package/bundle/wcs-radio-group.js +1 -1
- package/bundle/wcs-radio-group.js.map +1 -1
- package/bundle/wcs-radio.js +1 -1
- package/bundle/wcs-radio.js.map +1 -1
- package/bundle/wcs-select-option.js +1 -1
- package/bundle/wcs-select.js +1 -1
- package/bundle/wcs-skeleton-circle.js +1 -1
- package/bundle/wcs-skeleton-rectangle.js +1 -1
- package/bundle/wcs-skeleton-text.js +1 -1
- package/bundle/wcs-spinner.js +1 -1
- package/bundle/wcs-switch.js +1 -1
- package/bundle/wcs-tab.js +1 -1
- package/bundle/wcs-tabs.js +1 -1
- package/bundle/wcs-textarea.js +1 -1
- package/bundle/wcs-tooltip.js +2 -2
- package/composite-elements/{p-af24fb0d.js → p-00dd13c3.js} +3 -3
- package/composite-elements/p-00dd13c3.js.map +1 -0
- package/composite-elements/p-6b91c7bd.js +2 -0
- package/composite-elements/p-6b91c7bd.js.map +1 -0
- package/{bundle/p-30d83d3d.js → composite-elements/p-7feba658.js} +2 -2
- package/composite-elements/p-7feba658.js.map +1 -0
- package/composite-elements/{p-b83afff9.js → p-87e97a2e.js} +2 -2
- package/composite-elements/{p-b92e818b.js → p-a70a3379.js} +2 -2
- package/composite-elements/{p-55668982.js → p-c028b8e6.js} +2 -2
- package/composite-elements/{p-2a51c239.js → p-c6adb221.js} +2 -2
- package/composite-elements/{p-04663560.js → p-e4e3ed2c.js} +2 -2
- package/composite-elements/{p-51517fda.js → p-ec3ce4d4.js} +2 -2
- package/composite-elements/wcs-alert-drawer.js +1 -1
- package/composite-elements/wcs-alert.js +1 -1
- package/composite-elements/wcs-breadcrumb.js +1 -1
- package/composite-elements/wcs-button.js +1 -1
- package/composite-elements/wcs-card-content.js +1 -1
- package/composite-elements/wcs-card-content.js.map +1 -1
- package/composite-elements/wcs-card.js +1 -1
- package/composite-elements/wcs-card.js.map +1 -1
- package/composite-elements/wcs-counter.js +1 -1
- package/composite-elements/wcs-dropdown.js +1 -1
- package/composite-elements/wcs-dropdown.js.map +1 -1
- package/composite-elements/wcs-editable-field.js +1 -1
- package/composite-elements/wcs-editable-field.js.map +1 -1
- package/composite-elements/wcs-galactic-menu.js +1 -1
- package/composite-elements/wcs-grid-column.js +1 -1
- package/composite-elements/wcs-grid-column.js.map +1 -1
- package/composite-elements/wcs-grid-custom-cell.js +1 -1
- package/composite-elements/wcs-grid-custom-cell.js.map +1 -1
- package/composite-elements/wcs-grid-pagination.js +1 -1
- package/composite-elements/wcs-grid.js +1 -1
- package/composite-elements/wcs-grid.js.map +1 -1
- package/composite-elements/wcs-header.js +1 -1
- package/composite-elements/wcs-hint.js +1 -1
- package/composite-elements/wcs-horizontal-stepper.js +1 -1
- package/composite-elements/wcs-icon.js +1 -1
- package/composite-elements/wcs-input.js +1 -1
- package/composite-elements/wcs-input.js.map +1 -1
- package/composite-elements/wcs-label.js +1 -1
- package/composite-elements/wcs-list-item-properties.js +1 -1
- package/composite-elements/wcs-list-item-property.js +1 -1
- package/composite-elements/wcs-list-item.js +1 -1
- package/composite-elements/wcs-mat-icon.js +1 -1
- package/composite-elements/wcs-modal.js +1 -1
- package/composite-elements/wcs-native-select.js +1 -1
- package/composite-elements/wcs-nav-item.js +1 -1
- package/composite-elements/wcs-nav.js +1 -1
- package/composite-elements/wcs-progress-bar.js +1 -1
- package/composite-elements/wcs-progress-radial.js +1 -1
- package/composite-elements/wcs-radio-group.js +1 -1
- package/composite-elements/wcs-radio.js +1 -1
- package/composite-elements/wcs-radio.js.map +1 -1
- package/composite-elements/wcs-select-option.js +1 -1
- package/composite-elements/wcs-select.js +1 -1
- package/composite-elements/wcs-skeleton-circle.js +1 -1
- package/composite-elements/wcs-skeleton-rectangle.js +1 -1
- package/composite-elements/wcs-skeleton-text.js +1 -1
- package/composite-elements/wcs-spinner.js +1 -1
- package/composite-elements/wcs-switch.js +1 -1
- package/composite-elements/wcs-tab.js +1 -1
- package/composite-elements/wcs-tabs.js +1 -1
- package/composite-elements/wcs-textarea.js +1 -1
- package/composite-elements/wcs-tooltip.js +1 -1
- package/dist/cjs/{grid-pagination-4505d7b6.js → grid-pagination-ded127cc.js} +2 -2
- package/dist/cjs/grid-pagination-ded127cc.js.map +1 -0
- package/dist/cjs/{isEqual-8a0a6936.js → isEqual-be8e5a57.js} +2 -2
- package/dist/cjs/{isEqual-8a0a6936.js.map → isEqual-be8e5a57.js.map} +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/wcs-button_2.cjs.entry.js +1 -1
- package/dist/cjs/wcs-card-content.cjs.entry.js +1 -1
- package/dist/cjs/wcs-card-content.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-card.cjs.entry.js +1 -1
- package/dist/cjs/wcs-card.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-dropdown.cjs.entry.js +1 -1
- package/dist/cjs/wcs-dropdown.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-editable-field.cjs.entry.js +34 -10
- package/dist/cjs/wcs-editable-field.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-error_3.cjs.entry.js +2 -2
- package/dist/cjs/wcs-error_3.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-grid-column.cjs.entry.js +1 -1
- package/dist/cjs/wcs-grid-custom-cell.cjs.entry.js +1 -1
- package/dist/cjs/wcs-grid-pagination.cjs.entry.js +1 -1
- package/dist/cjs/wcs-grid.cjs.entry.js +6 -6
- package/dist/cjs/wcs-grid.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-header.cjs.entry.js +1 -1
- 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 +1 -1
- package/dist/cjs/wcs-input.cjs.entry.js +1 -6
- 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-mat-icon.cjs.entry.js +1 -1
- package/dist/cjs/wcs-modal.cjs.entry.js +1 -1
- package/dist/cjs/wcs-native-select.cjs.entry.js +1 -1
- package/dist/cjs/wcs-nav-item.cjs.entry.js +1 -1
- package/dist/cjs/wcs-nav.cjs.entry.js +1 -1
- package/dist/cjs/wcs-progress-bar.cjs.entry.js +2 -2
- package/dist/cjs/wcs-progress-radial.cjs.entry.js +2 -2
- package/dist/cjs/wcs-radio-group.cjs.entry.js +1 -1
- package/dist/cjs/wcs-radio.cjs.entry.js +24 -20
- package/dist/cjs/wcs-radio.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-select_2.cjs.entry.js +19 -9
- 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 +1 -1
- package/dist/cjs/wcs-tab.cjs.entry.js +1 -1
- package/dist/cjs/wcs-tabs.cjs.entry.js +1 -1
- package/dist/cjs/wcs-textarea.cjs.entry.js +1 -1
- package/dist/cjs/wcs-tooltip.cjs.entry.js +1 -1
- package/dist/cjs/wcs.cjs.js +1 -1
- package/dist/collection/components/card/card.js +11 -4
- package/dist/collection/components/card/card.js.map +1 -1
- package/dist/collection/components/card-content/card-content.js +8 -3
- package/dist/collection/components/card-content/card-content.js.map +1 -1
- package/dist/collection/components/dropdown/dropdown.css +8 -0
- package/dist/collection/components/dropdown/dropdown.e2e.playwright.js +53 -0
- package/dist/collection/components/dropdown/dropdown.e2e.playwright.js.map +1 -1
- package/dist/collection/components/editable-field/editable-field.e2e.playwright.js +214 -0
- package/dist/collection/components/editable-field/editable-field.e2e.playwright.js.map +1 -1
- package/dist/collection/components/editable-field/editable-field.js +34 -10
- package/dist/collection/components/editable-field/editable-field.js.map +1 -1
- package/dist/collection/components/grid/grid-radio.css +8 -0
- package/dist/collection/components/grid/grid.e2e.playwright.js +55 -0
- package/dist/collection/components/grid/grid.e2e.playwright.js.map +1 -1
- package/dist/collection/components/grid/grid.js +3 -3
- package/dist/collection/components/grid-column/grid-column.js +1 -1
- package/dist/collection/components/grid-custom-cell/grid-custom-cell.js +1 -1
- package/dist/collection/components/grid-pagination/grid-pagination.js +4 -1
- package/dist/collection/components/grid-pagination/grid-pagination.js.map +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.js +2 -7
- package/dist/collection/components/input/input.js.map +1 -1
- package/dist/collection/components/label/label.css +12 -9
- package/dist/collection/components/label/label.e2e.playwright.js +104 -0
- package/dist/collection/components/label/label.e2e.playwright.js.map +1 -0
- package/dist/collection/components/label/label.js +1 -1
- package/dist/collection/components/label/label.js.map +1 -1
- package/dist/collection/components/list-item/list-item.js +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 +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.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.css +48 -37
- package/dist/collection/components/radio/radio.js +24 -20
- package/dist/collection/components/radio/radio.js.map +1 -1
- package/dist/collection/components/radio-group/radio-group.e2e.playwright.js +92 -7
- package/dist/collection/components/radio-group/radio-group.e2e.playwright.js.map +1 -1
- package/dist/collection/components/radio-group/radio-group.js +1 -1
- package/dist/collection/components/select/select-interface.js.map +1 -1
- package/dist/collection/components/select/select.e2e.playwright.js +9 -9
- package/dist/collection/components/select/select.e2e.playwright.js.map +1 -1
- package/dist/collection/components/select/select.js +16 -6
- 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 +1 -1
- package/dist/collection/components/tab/tab.js +1 -1
- package/dist/collection/components/tabs/tabs.js +1 -1
- package/dist/collection/components/textarea/textarea.js +1 -1
- package/dist/collection/components/tooltip/tooltip.js +1 -1
- package/dist/collection/utils/playwright/test.js +6 -0
- package/dist/collection/utils/playwright/test.js.map +1 -1
- package/dist/esm/{com-nav-utils-ee7bf77c.js → com-nav-utils-27c1efdf.js} +2 -2
- package/dist/esm/{com-nav-utils-ee7bf77c.js.map → com-nav-utils-27c1efdf.js.map} +1 -1
- package/dist/esm/{grid-pagination-731726a6.js → grid-pagination-23102986.js} +3 -3
- package/dist/esm/grid-pagination-23102986.js.map +1 -0
- package/dist/esm/{helpers-ece6a2d3.js → helpers-89faa1b1.js} +2 -2
- package/dist/esm/{helpers-ece6a2d3.js.map → helpers-89faa1b1.js.map} +1 -1
- package/dist/esm/{isEqual-f2a07f4c.js → isEqual-89e74e17.js} +2 -2
- package/dist/esm/{isEqual-f2a07f4c.js.map → isEqual-89e74e17.js.map} +1 -1
- package/dist/esm/{keyboard-event-26b65ae5.js → keyboard-event-dd35bb6b.js} +2 -2
- package/dist/esm/{keyboard-event-26b65ae5.js.map → keyboard-event-dd35bb6b.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-alert-drawer.entry.js +1 -1
- package/dist/esm/wcs-breadcrumb.entry.js +1 -1
- package/dist/esm/wcs-button_2.entry.js +2 -2
- package/dist/esm/wcs-card-content.entry.js +1 -1
- package/dist/esm/wcs-card-content.entry.js.map +1 -1
- package/dist/esm/wcs-card.entry.js +1 -1
- package/dist/esm/wcs-card.entry.js.map +1 -1
- package/dist/esm/wcs-checkbox.entry.js +1 -1
- package/dist/esm/wcs-com-nav-category.entry.js +2 -2
- 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 +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 +35 -11
- package/dist/esm/wcs-editable-field.entry.js.map +1 -1
- package/dist/esm/wcs-error_3.entry.js +3 -3
- package/dist/esm/wcs-error_3.entry.js.map +1 -1
- package/dist/esm/wcs-galactic-menu.entry.js +1 -1
- package/dist/esm/wcs-grid-column.entry.js +2 -2
- 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 +8 -8
- package/dist/esm/wcs-grid.entry.js.map +1 -1
- 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 +2 -7
- 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-mat-icon.entry.js +2 -2
- package/dist/esm/wcs-modal.entry.js +2 -2
- package/dist/esm/wcs-native-select.entry.js +1 -1
- package/dist/esm/wcs-nav-item.entry.js +2 -2
- 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 +2 -2
- package/dist/esm/wcs-radio.entry.js +25 -21
- package/dist/esm/wcs-radio.entry.js.map +1 -1
- package/dist/esm/wcs-select_2.entry.js +21 -11
- 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 +2 -2
- package/dist/esm/wcs-tab.entry.js +1 -1
- package/dist/esm/wcs-tabs.entry.js +2 -2
- package/dist/esm/wcs-textarea.entry.js +2 -2
- package/dist/esm/wcs-tooltip.entry.js +2 -2
- package/dist/esm/wcs.js +1 -1
- package/dist/types/components/card/card.d.ts +10 -3
- package/dist/types/components/card-content/card-content.d.ts +7 -2
- package/dist/types/components/editable-field/editable-field.d.ts +3 -0
- package/dist/types/components/grid-pagination/grid-pagination.d.ts +3 -0
- package/dist/types/components/label/label.e2e.playwright.d.ts +1 -0
- package/dist/types/components/radio/radio.d.ts +4 -5
- package/dist/types/components/select/select-interface.d.ts +4 -0
- package/dist/types/components.d.ts +52 -16
- package/dist/wcs/{p-1ba616c2.entry.js → p-03838b42.entry.js} +2 -2
- package/dist/wcs/{p-b0a6eec6.entry.js → p-0cbf08fb.entry.js} +2 -2
- package/dist/wcs/{p-cad10435.entry.js → p-0d233c6a.entry.js} +2 -2
- package/dist/wcs/{p-db7ba599.entry.js → p-14dfa087.entry.js} +3 -3
- package/dist/wcs/p-1c356201.entry.js +2 -0
- package/dist/wcs/p-1c356201.entry.js.map +1 -0
- package/dist/wcs/{p-b28b2fba.entry.js → p-218b5f3d.entry.js} +2 -2
- package/dist/wcs/{p-aadf37e7.entry.js → p-25d7b2f8.entry.js} +2 -2
- package/dist/wcs/{p-850fa9c9.entry.js → p-3e57c746.entry.js} +2 -2
- package/dist/wcs/{p-52d77e1f.js → p-5314a64d.js} +2 -2
- package/dist/wcs/{p-27b438c0.entry.js → p-53bc2cae.entry.js} +2 -2
- package/dist/wcs/p-5443c9af.entry.js +2 -0
- package/dist/wcs/p-5443c9af.entry.js.map +1 -0
- package/dist/wcs/{p-ad286030.entry.js → p-56d9554a.entry.js} +2 -2
- package/dist/wcs/p-59f96b21.entry.js +2 -0
- package/dist/wcs/{p-ff826ebe.js → p-5cea30cb.js} +1 -1
- package/dist/wcs/{p-ff826ebe.js.map → p-5cea30cb.js.map} +1 -1
- package/dist/wcs/{p-2329af04.entry.js → p-63a8e5cc.entry.js} +2 -2
- package/dist/wcs/{p-fbd68522.entry.js → p-6d8f0040.entry.js} +2 -2
- package/dist/wcs/p-6e7db56e.entry.js +2 -0
- package/dist/wcs/p-6e7db56e.entry.js.map +1 -0
- package/dist/wcs/{p-c84ae00d.entry.js → p-6f937b20.entry.js} +2 -2
- package/dist/wcs/p-7af9a2f3.js +2 -0
- package/dist/wcs/p-7b60d4c7.js +2 -0
- package/dist/wcs/p-7b60d4c7.js.map +1 -0
- package/dist/wcs/{p-2221bf0c.entry.js → p-82838611.entry.js} +3 -3
- package/dist/wcs/p-82838611.entry.js.map +1 -0
- package/dist/wcs/{p-bc009574.entry.js → p-8f95bbf3.entry.js} +2 -2
- package/dist/wcs/{p-9fd3366c.entry.js → p-912c2c9b.entry.js} +2 -2
- package/dist/wcs/p-9197e9b5.entry.js +2 -0
- package/dist/wcs/p-9197e9b5.entry.js.map +1 -0
- package/dist/wcs/{p-1e7ea63c.entry.js → p-9388283a.entry.js} +2 -2
- package/dist/wcs/{p-18fa39f4.entry.js → p-9c6db857.entry.js} +2 -2
- package/dist/wcs/{p-637ec45a.entry.js → p-9d4c8f84.entry.js} +2 -2
- package/dist/wcs/p-9d4c8f84.entry.js.map +1 -0
- package/dist/wcs/{p-dfb52a1c.entry.js → p-9e091c53.entry.js} +2 -2
- package/dist/wcs/{p-450942b1.entry.js → p-a60ba874.entry.js} +3 -3
- package/dist/wcs/{p-c6f8c45c.entry.js → p-a6d64e5b.entry.js} +2 -2
- package/dist/wcs/{p-9c73744c.entry.js → p-ae299c3f.entry.js} +2 -2
- package/dist/wcs/{p-a0f6ef30.entry.js → p-b04471f5.entry.js} +2 -2
- package/dist/wcs/p-b04471f5.entry.js.map +1 -0
- package/dist/wcs/{p-4ae08567.entry.js → p-b3b31d43.entry.js} +2 -2
- package/dist/wcs/{p-abd8d5a0.entry.js → p-b42f441f.entry.js} +2 -2
- package/dist/wcs/{p-5202b323.entry.js → p-b9368690.entry.js} +2 -2
- package/dist/wcs/{p-e56b9ce2.entry.js → p-beeec782.entry.js} +2 -2
- package/dist/wcs/{p-c261eaf9.entry.js → p-c169d496.entry.js} +2 -2
- package/dist/wcs/p-c3b733ff.entry.js +2 -0
- package/dist/wcs/{p-9b76b8e6.entry.js → p-c42a6c1c.entry.js} +2 -2
- package/dist/wcs/p-c42a6c1c.entry.js.map +1 -0
- package/dist/wcs/p-c6808cab.entry.js +2 -0
- package/dist/wcs/{p-ed3b0709.entry.js → p-cb9147b8.entry.js} +2 -2
- package/dist/wcs/{p-f2f7595e.entry.js → p-cceee683.entry.js} +2 -2
- package/dist/wcs/{p-f2f7595e.entry.js.map → p-cceee683.entry.js.map} +1 -1
- package/dist/wcs/p-d3afc02f.entry.js +2 -0
- package/dist/wcs/{p-5e8fff73.entry.js → p-d89ad962.entry.js} +2 -2
- package/dist/wcs/{p-4e2d6227.entry.js → p-d8c4dbc3.entry.js} +2 -2
- package/dist/wcs/p-dbf82cb9.js +2 -0
- package/dist/wcs/{p-dff8641e.entry.js → p-e35b138e.entry.js} +2 -2
- package/dist/wcs/{p-fdeae83e.entry.js → p-f2c49d83.entry.js} +2 -2
- package/dist/wcs/{p-cbda74f6.entry.js → p-f411974e.entry.js} +2 -2
- package/dist/wcs/{p-0326f834.entry.js → p-f974210c.entry.js} +2 -2
- package/dist/wcs/{p-352e1f99.entry.js → p-ff48a8b2.entry.js} +2 -2
- package/dist/wcs/wcs.esm.js +1 -1
- package/dist/wcs/wcs.esm.js.map +1 -1
- package/package.json +2 -2
- package/bundle/p-30d83d3d.js.map +0 -1
- package/bundle/p-763371a0.js.map +0 -1
- package/bundle/p-97e70e10.js +0 -2
- package/bundle/p-fc9ba34d.js +0 -2
- package/bundle/p-fc9ba34d.js.map +0 -1
- package/composite-elements/p-0c306f8c.js +0 -2
- package/composite-elements/p-0c306f8c.js.map +0 -1
- package/composite-elements/p-af24fb0d.js.map +0 -1
- package/composite-elements/p-bc4c736d.js +0 -2
- package/composite-elements/p-bc4c736d.js.map +0 -1
- package/dist/cjs/grid-pagination-4505d7b6.js.map +0 -1
- package/dist/esm/grid-pagination-731726a6.js.map +0 -1
- package/dist/wcs/p-0017d766.js +0 -2
- package/dist/wcs/p-0b8157e7.entry.js +0 -2
- package/dist/wcs/p-2221bf0c.entry.js.map +0 -1
- package/dist/wcs/p-3823f54e.entry.js +0 -2
- package/dist/wcs/p-580b3142.entry.js +0 -2
- package/dist/wcs/p-5da0534f.entry.js +0 -2
- package/dist/wcs/p-5da0534f.entry.js.map +0 -1
- package/dist/wcs/p-637ec45a.entry.js.map +0 -1
- package/dist/wcs/p-86ec9ead.entry.js +0 -2
- package/dist/wcs/p-86ec9ead.entry.js.map +0 -1
- package/dist/wcs/p-89b8c724.js +0 -2
- package/dist/wcs/p-98a8b806.entry.js +0 -2
- package/dist/wcs/p-98a8b806.entry.js.map +0 -1
- package/dist/wcs/p-9b76b8e6.entry.js.map +0 -1
- package/dist/wcs/p-a0f6ef30.entry.js.map +0 -1
- package/dist/wcs/p-ad5192cd.entry.js +0 -2
- package/dist/wcs/p-c5bad0b8.js +0 -2
- package/dist/wcs/p-c5bad0b8.js.map +0 -1
- package/dist/wcs/p-fe303f58.entry.js +0 -2
- package/dist/wcs/p-fe303f58.entry.js.map +0 -1
- /package/bundle/{p-97e70e10.js.map → p-475be4d2.js.map} +0 -0
- /package/bundle/{p-010cf905.js.map → p-5ef2bc63.js.map} +0 -0
- /package/bundle/{p-44a3b0b9.js.map → p-7a06295b.js.map} +0 -0
- /package/bundle/{p-2751ddc1.js.map → p-8b186fcf.js.map} +0 -0
- /package/bundle/{p-d23d7658.js.map → p-a0268a31.js.map} +0 -0
- /package/bundle/{p-c8b73e93.js.map → p-bce8c93f.js.map} +0 -0
- /package/bundle/{p-2e9b9605.js.map → p-bf326ae8.js.map} +0 -0
- /package/bundle/{p-98bd8a96.js.map → p-d018450c.js.map} +0 -0
- /package/bundle/{p-f0dda0b8.js.map → p-d3fe6951.js.map} +0 -0
- /package/bundle/{p-9c2aa87a.js.map → p-ee6ff5f8.js.map} +0 -0
- /package/bundle/{p-cdc6f6c2.js.map → p-ff261e50.js.map} +0 -0
- /package/composite-elements/{p-b83afff9.js.map → p-87e97a2e.js.map} +0 -0
- /package/composite-elements/{p-b92e818b.js.map → p-a70a3379.js.map} +0 -0
- /package/composite-elements/{p-55668982.js.map → p-c028b8e6.js.map} +0 -0
- /package/composite-elements/{p-2a51c239.js.map → p-c6adb221.js.map} +0 -0
- /package/composite-elements/{p-04663560.js.map → p-e4e3ed2c.js.map} +0 -0
- /package/composite-elements/{p-51517fda.js.map → p-ec3ce4d4.js.map} +0 -0
- /package/dist/wcs/{p-1ba616c2.entry.js.map → p-03838b42.entry.js.map} +0 -0
- /package/dist/wcs/{p-b0a6eec6.entry.js.map → p-0cbf08fb.entry.js.map} +0 -0
- /package/dist/wcs/{p-cad10435.entry.js.map → p-0d233c6a.entry.js.map} +0 -0
- /package/dist/wcs/{p-db7ba599.entry.js.map → p-14dfa087.entry.js.map} +0 -0
- /package/dist/wcs/{p-b28b2fba.entry.js.map → p-218b5f3d.entry.js.map} +0 -0
- /package/dist/wcs/{p-aadf37e7.entry.js.map → p-25d7b2f8.entry.js.map} +0 -0
- /package/dist/wcs/{p-850fa9c9.entry.js.map → p-3e57c746.entry.js.map} +0 -0
- /package/dist/wcs/{p-52d77e1f.js.map → p-5314a64d.js.map} +0 -0
- /package/dist/wcs/{p-27b438c0.entry.js.map → p-53bc2cae.entry.js.map} +0 -0
- /package/dist/wcs/{p-ad286030.entry.js.map → p-56d9554a.entry.js.map} +0 -0
- /package/dist/wcs/{p-3823f54e.entry.js.map → p-59f96b21.entry.js.map} +0 -0
- /package/dist/wcs/{p-2329af04.entry.js.map → p-63a8e5cc.entry.js.map} +0 -0
- /package/dist/wcs/{p-fbd68522.entry.js.map → p-6d8f0040.entry.js.map} +0 -0
- /package/dist/wcs/{p-c84ae00d.entry.js.map → p-6f937b20.entry.js.map} +0 -0
- /package/dist/wcs/{p-89b8c724.js.map → p-7af9a2f3.js.map} +0 -0
- /package/dist/wcs/{p-bc009574.entry.js.map → p-8f95bbf3.entry.js.map} +0 -0
- /package/dist/wcs/{p-9fd3366c.entry.js.map → p-912c2c9b.entry.js.map} +0 -0
- /package/dist/wcs/{p-1e7ea63c.entry.js.map → p-9388283a.entry.js.map} +0 -0
- /package/dist/wcs/{p-18fa39f4.entry.js.map → p-9c6db857.entry.js.map} +0 -0
- /package/dist/wcs/{p-dfb52a1c.entry.js.map → p-9e091c53.entry.js.map} +0 -0
- /package/dist/wcs/{p-450942b1.entry.js.map → p-a60ba874.entry.js.map} +0 -0
- /package/dist/wcs/{p-c6f8c45c.entry.js.map → p-a6d64e5b.entry.js.map} +0 -0
- /package/dist/wcs/{p-9c73744c.entry.js.map → p-ae299c3f.entry.js.map} +0 -0
- /package/dist/wcs/{p-4ae08567.entry.js.map → p-b3b31d43.entry.js.map} +0 -0
- /package/dist/wcs/{p-abd8d5a0.entry.js.map → p-b42f441f.entry.js.map} +0 -0
- /package/dist/wcs/{p-5202b323.entry.js.map → p-b9368690.entry.js.map} +0 -0
- /package/dist/wcs/{p-e56b9ce2.entry.js.map → p-beeec782.entry.js.map} +0 -0
- /package/dist/wcs/{p-c261eaf9.entry.js.map → p-c169d496.entry.js.map} +0 -0
- /package/dist/wcs/{p-0b8157e7.entry.js.map → p-c3b733ff.entry.js.map} +0 -0
- /package/dist/wcs/{p-580b3142.entry.js.map → p-c6808cab.entry.js.map} +0 -0
- /package/dist/wcs/{p-ed3b0709.entry.js.map → p-cb9147b8.entry.js.map} +0 -0
- /package/dist/wcs/{p-ad5192cd.entry.js.map → p-d3afc02f.entry.js.map} +0 -0
- /package/dist/wcs/{p-5e8fff73.entry.js.map → p-d89ad962.entry.js.map} +0 -0
- /package/dist/wcs/{p-4e2d6227.entry.js.map → p-d8c4dbc3.entry.js.map} +0 -0
- /package/dist/wcs/{p-0017d766.js.map → p-dbf82cb9.js.map} +0 -0
- /package/dist/wcs/{p-dff8641e.entry.js.map → p-e35b138e.entry.js.map} +0 -0
- /package/dist/wcs/{p-fdeae83e.entry.js.map → p-f2c49d83.entry.js.map} +0 -0
- /package/dist/wcs/{p-cbda74f6.entry.js.map → p-f411974e.entry.js.map} +0 -0
- /package/dist/wcs/{p-0326f834.entry.js.map → p-f974210c.entry.js.map} +0 -0
- /package/dist/wcs/{p-352e1f99.entry.js.map → p-ff48a8b2.entry.js.map} +0 -0
|
@@ -26,7 +26,7 @@ const Header = class {
|
|
|
26
26
|
};
|
|
27
27
|
}
|
|
28
28
|
__stencil_render() {
|
|
29
|
-
return (index.h("header", Object.assign({ key: '
|
|
29
|
+
return (index.h("header", Object.assign({ key: 'd8d14874c0caf8bd0774bfbc43ec74b602d5e3eb', role: "banner", ref: (el) => (this.nativeHeader = el) }, this.inheritedAttributes), index.h("slot", { key: '7c7dcc8f6760d45a5c6ad530cee9947025a87771', name: "logo" }), index.h("slot", { key: '5e5ba145dd565729887993e1e934107311c98738', name: "title" }), index.h("slot", { key: 'fe799951e59ad6288fa5e44480c5e49f47da6c3d', name: "center" }), index.h("slot", { key: '3fabde05983e0bbd226d3d4112e567f7565fb1be', name: "actions" })));
|
|
30
30
|
}
|
|
31
31
|
get el() { return index.getElement(this); }
|
|
32
32
|
render() { return index.h(index.Host, this.hostData(), this.__stencil_render()); }
|
|
@@ -13,7 +13,7 @@ const Hint = class {
|
|
|
13
13
|
this.small = false;
|
|
14
14
|
}
|
|
15
15
|
render() {
|
|
16
|
-
return (index.h(index.Host, { key: '
|
|
16
|
+
return (index.h(index.Host, { key: '6fae15a2dd3769e29fd86d510739a2e7b7c47123', slot: "messages" }, index.h("slot", { key: 'aa531d55bfb557aaba527f63af0f275b7e869d63' })));
|
|
17
17
|
}
|
|
18
18
|
};
|
|
19
19
|
Hint.style = WcsHintStyle0;
|
|
@@ -85,7 +85,7 @@ const HorizontalStepper = class {
|
|
|
85
85
|
}
|
|
86
86
|
}
|
|
87
87
|
render() {
|
|
88
|
-
return (index.h(index.Host, { key: '
|
|
88
|
+
return (index.h(index.Host, { key: '5da8afa26c57a0c1022ff0f07f39df0237642f9d' }, index.h("ul", { key: '842228ca2f4e136a3937b02281ca3194d4caef91', role: "list", class: "steps" }, this.steps.map((step, index$1) => (index.h(HorizontalStep, { step: step, passed: index$1 <= this.internalCurrentStepIndex, checkOnComplete: this.checkOnComplete, complete: this.isComplete(step, index$1), active: index$1 === this.internalCurrentStepIndex, first: index$1 === 0, disable: this.isDisable(step, index$1), onClick: step => this.wcsHorizontalStepClick.emit({ step, index: index$1 }) })))), this.renderLabels()));
|
|
89
89
|
}
|
|
90
90
|
isComplete(step, index) {
|
|
91
91
|
return index <= this.internalCurrentStepIndex || step.complete;
|
|
@@ -26,7 +26,7 @@ const Icon = class {
|
|
|
26
26
|
[`icons-size-${this.size}`]: true
|
|
27
27
|
}
|
|
28
28
|
};
|
|
29
|
-
return (index.h("i", Object.assign({ key: '
|
|
29
|
+
return (index.h("i", Object.assign({ key: '21e345e63fdb54bd03dac7b4574cdc6bddedfaa9' }, cssClass, { ref: (el) => (this.nativeIcon = el) }, this.inheritedAttributes)));
|
|
30
30
|
}
|
|
31
31
|
get el() { return index.getElement(this); }
|
|
32
32
|
};
|
|
@@ -124,12 +124,7 @@ const Input = class {
|
|
|
124
124
|
}
|
|
125
125
|
render() {
|
|
126
126
|
const value = this.getValueAsString();
|
|
127
|
-
|
|
128
|
-
const label = helpers.findItemLabel(this.el);
|
|
129
|
-
if (label) {
|
|
130
|
-
label.id = labelId;
|
|
131
|
-
}
|
|
132
|
-
return (index.h(index.Host, { key: '20899914842d410ef72a8f81906e1e2be6e423cf', "aria-disabled": this.disabled ? 'true' : null, "data-has-prefix": !!this.prefixLabel, "data-has-suffix": !!this.suffixLabel }, this.prefixLabel ? (index.h("span", { class: "prefix", part: "prefix" }, this.prefixLabel)) : null, this.icon ? (index.h("wcs-mat-icon", { icon: this.icon, size: "m" })) : null, index.h("input", Object.assign({ key: '059fb987112d535b3f1cf51ea9bbaa01f36667c5', class: "native-input", ref: input => this.nativeInput = input, "aria-labelledby": label ? labelId : null, disabled: this.disabled, accept: this.accept, autoCapitalize: this.autocapitalize, autoComplete: this.autocomplete, autoCorrect: this.autocorrect, autoFocus: this.autofocus, enterKeyHint: this.enterkeyhint, inputMode: this.inputmode, min: this.min, max: this.max, minLength: this.minlength, maxLength: this.maxlength, multiple: this.multiple, name: this.name, pattern: this.pattern, placeholder: this.placeholder || '', readOnly: this.readonly, required: this.required, spellcheck: this.spellcheck, step: this.step, type: this.passwordReveal ? 'text' : this.type, value: value, onInput: this.onInput, onChange: this.onChange, onBlur: this.onBlur, onFocus: this.onFocus }, this.inheritedAttributes)), this.type === "password" ? (index.h("button", { title: this.passwordReveal ? this.hidePasswordButtonAriaLabel : this.showPasswordButtonAriaLabel, class: "toggle_password", onClick: () => this.passwordRevealIconClick() }, index.h("wcs-mat-icon", { icon: this.iconPassword, size: "m" }))) : null, this.suffixLabel ? (index.h("span", { class: "suffix", part: "suffix" }, this.suffixLabel)) : null));
|
|
127
|
+
return (index.h(index.Host, { key: 'd3123d1eb17f9fe38d6081ec94b15e027f706506', "aria-disabled": this.disabled ? 'true' : null, "data-has-prefix": !!this.prefixLabel, "data-has-suffix": !!this.suffixLabel }, this.prefixLabel ? (index.h("span", { class: "prefix", part: "prefix" }, this.prefixLabel)) : null, this.icon ? (index.h("wcs-mat-icon", { icon: this.icon, size: "m" })) : null, index.h("input", Object.assign({ key: 'b799b4443242f73609e337b33fc5794775aa7e1c', class: "native-input", ref: input => this.nativeInput = input, disabled: this.disabled, accept: this.accept, autoCapitalize: this.autocapitalize, autoComplete: this.autocomplete, autoCorrect: this.autocorrect, autoFocus: this.autofocus, enterKeyHint: this.enterkeyhint, inputMode: this.inputmode, min: this.min, max: this.max, minLength: this.minlength, maxLength: this.maxlength, multiple: this.multiple, name: this.name, pattern: this.pattern, placeholder: this.placeholder || '', readOnly: this.readonly, required: this.required, spellcheck: this.spellcheck, step: this.step, type: this.passwordReveal ? 'text' : this.type, value: value, onInput: this.onInput, onChange: this.onChange, onBlur: this.onBlur, onFocus: this.onFocus }, this.inheritedAttributes)), this.type === "password" ? (index.h("button", { title: this.passwordReveal ? this.hidePasswordButtonAriaLabel : this.showPasswordButtonAriaLabel, class: "toggle_password", onClick: () => this.passwordRevealIconClick() }, index.h("wcs-mat-icon", { icon: this.iconPassword, size: "m" }))) : null, this.suffixLabel ? (index.h("span", { class: "suffix", part: "suffix" }, this.suffixLabel)) : null));
|
|
133
128
|
}
|
|
134
129
|
static get delegatesFocus() { return true; }
|
|
135
130
|
get el() { return index.getElement(this); }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"wcs-input.entry.cjs.js","mappings":";;;;;;;AAAA,MAAM,QAAQ,GAAG,g/MAAg/M,CAAC;AAClgN,uBAAe,QAAQ;;ACgCvB,MAAM,qBAAqB,GAAG,CAAC,UAAU,EAAE,OAAO,CAAC,CAAC;MA+DvC,KAAK;;;;;;;QAGN,YAAO,GAAG,aAAa,QAAQ,EAAE,EAAE,CAAC;QACpC,wBAAmB,GAAyB,EAAE,CAAC;QAC/C,iBAAY,GAAG,YAAY,CAAC;QAyP5B,YAAO,GAAG,CAAC,EAAS;YACxB,MAAM,KAAK,GAAG,EAAE,CAAC,MAAiC,CAAC;YACnD,IAAI,KAAK,EAAE;gBACP,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC,KAAK,IAAI,EAAE,CAAC;aAClC;YACD,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAmB,CAAC,CAAC;SAC3C,CAAA;QAEO,aAAQ,GAAG,CAAC,CAAQ;YACxB,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,EAAC,KAAK,EAAE,IAAI,CAAC,WAAW,CAAC,KAAK,EAAC,CAAC,CAAC;SACxD,CAAA;QAEO,WAAM,GAAG,CAAC,EAAc;YAC5B,IAAI,IAAI,CAAC,eAAe,EAAE;gBACtB,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;aACzB;SACJ,CAAA;QAEO,YAAO,GAAG,CAAC,EAAc;YAC7B,IAAI,IAAI,CAAC,eAAe,EAAE;gBACtB,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;aAC1B;SACJ,CAAA;+BArQkC,IAAI;8BAEI,KAAK;;8BAYvB,KAAK;4BAKY,KAAK;2BAKJ,KAAK;yBAKnB,KAAK;wBAMf,CAAC;;;wBAoByB,KAAK;;oBAUN,GAAG;;;;;;;;oBA2CxB,IAAI,CAAC,OAAO;2CAEW,wBAAwB;2CACxB,0BAA0B;;;wBAoB3B,KAAK;wBAKL,KAAK;0BAKpB,KAAK;qBAMW,SAAS;;oBAWxB,MAAM;qBAKmB,EAAE;;IA7HhD,eAAe;QACrB,IAAI,CAAC,QAAQ,GAAGA,qBAAa,CAAC,IAAI,CAAC,QAAQ,EAAE,IAAI,CAAC,QAAQ,CAAC,CAAC;KAC/D;IAiJD,iBAAiB;QACb,IAAI,CAAC,mBAAmB,mCACjBC,6BAAqB,CAAC,IAAI,CAAC,EAAE,CAAC,GAC9BC,yBAAiB,CAAC,IAAI,CAAC,EAAE,EAAE,qBAAqB,CAAC,CACvD,CAAC;KACL;IAED,iBAAiB;QACb,IAAI,CAAC,eAAe,EAAE,CAAC;QACF;YACjB,QAAQ,CAAC,aAAa,CAAC,IAAI,WAAW,CAAC,iBAAiB,EAAE;gBACtD,MAAM,EAAE,IAAI,CAAC,EAAE;aAClB,CAAC,CAAC,CAAC;SACP;KACJ;IAED,oBAAoB;QACK;YACjB,QAAQ,CAAC,aAAa,CAAC,IAAI,WAAW,CAAC,mBAAmB,EAAE;gBACxD,MAAM,EAAE,IAAI,CAAC,EAAE;aAClB,CAAC,CAAC,CAAC;SACP;KACJ;;;;;;IAQD,MAAM,OAAO;QACT,IAAI,IAAI,CAAC,WAAW,EAAE;YAClB,IAAI,CAAC,WAAW,CAAC,IAAI,EAAE,CAAC;SAC3B;KACJ;;;;IAMD,eAAe;QACX,OAAO,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,WAAY,CAAC,CAAC;KAC7C;IAGD,MAAM,gBAAgB,CAAC,IAAuB,EAAE,KAAgC;QAC5EC,4BAAoB,CAAC,IAAI,CAAC,WAAW,EAAE,IAAI,EAAE,KAAK,CAAC,CAAC;KACvD;IAEO,gBAAgB;QACpB,OAAO,OAAO,IAAI,CAAC,KAAK,KAAK,QAAQ,GAAG,IAAI,CAAC,KAAK,CAAC,QAAQ,EAAE;YACzD,CAAC,IAAI,CAAC,KAAK,IAAI,EAAE,EAAE,QAAQ,EAAE,CAAC;KACrC;IA0BO,uBAAuB;QAC3B,IAAI,CAAC,cAAc,GAAG,CAAC,IAAI,CAAC,cAAc,CAAC;KAC9C;IAGD,sBAAsB;QAClB,IAAI,CAAC,YAAY,GAAG,IAAI,CAAC,cAAc,GAAG,gBAAgB,GAAG,YAAY,CAAC;KAC7E;IAED,MAAM;QACF,MAAM,KAAK,GAAG,IAAI,CAAC,gBAAgB,EAAE,CAAC;QACtC,MAAM,OAAO,GAAG,IAAI,CAAC,OAAO,GAAG,MAAM,CAAC;QACtC,MAAM,KAAK,GAAGC,qBAAa,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;QACrC,IAAI,KAAK,EAAE;YACP,KAAK,CAAC,EAAE,GAAG,OAAO,CAAC;SACtB;QAED,QACIC,QAACC,UAAI,sEACc,IAAI,CAAC,QAAQ,GAAG,MAAM,GAAG,IAAI,qBAC3B,CAAC,CAAC,IAAI,CAAC,WAAW,qBAClB,CAAC,CAAC,IAAI,CAAC,WAAW,IAElC,IAAI,CAAC,WAAW,IAAID,kBAAM,KAAK,EAAC,QAAQ,EAAC,IAAI,EAAC,QAAQ,IAAE,IAAI,CAAC,WAAW,CAAQ,IAAI,IAAI,EACxF,IAAI,CAAC,IAAI,IAAIA,0BAAc,IAAI,EAAE,IAAI,CAAC,IAAI,EAAE,IAAI,EAAC,GAAG,GAAgB,IAAI,IAAI,EAC7EA,kFACI,KAAK,EAAC,cAAc,EACpB,GAAG,EAAE,KAAK,IAAI,IAAI,CAAC,WAAW,GAAG,KAAK,qBACrB,KAAK,GAAG,OAAO,GAAG,IAAI,EACvC,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,MAAM,EAAE,IAAI,CAAC,MAAM,EACnB,cAAc,EAAE,IAAI,CAAC,cAAc,EACnC,YAAY,EAAE,IAAI,CAAC,YAAY,EAC/B,WAAW,EAAE,IAAI,CAAC,WAAW,EAC7B,SAAS,EAAE,IAAI,CAAC,SAAS,EACzB,YAAY,EAAE,IAAI,CAAC,YAAY,EAC/B,SAAS,EAAE,IAAI,CAAC,SAAS,EACzB,GAAG,EAAE,IAAI,CAAC,GAAG,EACb,GAAG,EAAE,IAAI,CAAC,GAAG,EACb,SAAS,EAAE,IAAI,CAAC,SAAS,EACzB,SAAS,EAAE,IAAI,CAAC,SAAS,EACzB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,IAAI,EAAE,IAAI,CAAC,IAAI,EACf,OAAO,EAAE,IAAI,CAAC,OAAO,EACrB,WAAW,EAAE,IAAI,CAAC,WAAW,IAAI,EAAE,EACnC,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,UAAU,EAAE,IAAI,CAAC,UAAU,EAC3B,IAAI,EAAE,IAAI,CAAC,IAAI,EACf,IAAI,EAAE,IAAI,CAAC,cAAc,GAAG,MAAM,GAAG,IAAI,CAAC,IAAI,EAC9C,KAAK,EAAE,KAAK,EACZ,OAAO,EAAE,IAAI,CAAC,OAAO,EACrB,QAAQ,EAAE,IAAI,CAAC,QAAQ,EACvB,MAAM,EAAE,IAAI,CAAC,MAAM,EACnB,OAAO,EAAE,IAAI,CAAC,OAAO,IACjB,IAAI,CAAC,mBAAmB,EAC9B,EACD,IAAI,CAAC,IAAI,KAAK,UAAU,IACrBA,oBAAQ,KAAK,EAAE,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,2BAA2B,GAAG,IAAI,CAAC,2BAA2B,EAAE,KAAK,EAAC,iBAAiB,EAAC,OAAO,EAAE,MAAM,IAAI,CAAC,uBAAuB,EAAE,IAC3KA,0BAAc,IAAI,EAAE,IAAI,CAAC,YAAY,EAAE,IAAI,EAAC,GAAG,GAAgB,CAC1D,IACT,IAAI,EACP,IAAI,CAAC,WAAW,IAAIA,kBAAM,KAAK,EAAC,QAAQ,EAAC,IAAI,EAAC,QAAQ,IAAE,IAAI,CAAC,WAAW,CAAQ,IAAI,IAAI,CACtF,EACT;KACL;;;;;;;;AAGL,IAAI,QAAQ,GAAG,CAAC,CAAC;;;;;","names":["debounceEvent","inheritAriaAttributes","inheritAttributes","setOrRemoveAttribute","findItemLabel","h","Host"],"sources":["src/components/input/input.scss?tag=wcs-input&encapsulation=shadow","src/components/input/input.tsx"],"sourcesContent":["@import '../../style/focus-outline.scss';\n@import '../../style/placeholder.scss';\n\n:host {\n --wcs-input-icon-color-default: var(--wcs-semantic-color-foreground-brand);\n --wcs-input-icon-color-focus: var(--wcs-semantic-color-foreground-brand);\n --wcs-input-icon-color-disabled: var(--wcs-semantic-color-foreground-disabled);\n\n --wcs-input-background-color: var(--wcs-semantic-color-background-control-default);\n\n --wcs-input-border-radius-left: var(--wcs-semantic-border-radius-base); // Overridden from prefix suffix group in form-field\n --wcs-input-border-radius-right: var(--wcs-semantic-border-radius-base); // Overridden from prefix suffix group in form-field\n\n --wcs-input-border-width: var(--wcs-semantic-border-width-default);\n --wcs-input-border-width-focus: var(--wcs-semantic-border-width-large);\n\n --wcs-input-height-l: var(--wcs-semantic-size-l);\n --wcs-input-height-m: var(--wcs-semantic-size-m);\n --wcs-input-height-s: var(--wcs-semantic-size-s);\n --wcs-input-font-size-l: var(--wcs-semantic-font-size-l);\n --wcs-input-font-size-m: var(--wcs-semantic-font-size-m);\n --wcs-input-font-size-s: var(--wcs-semantic-font-size-s);\n\n --wcs-input-prefix-suffix-background-color: var(--wcs-semantic-color-background-surface-accent-lighter);\n --wcs-input-prefix-suffix-color: var(--wcs-semantic-color-foreground-on-accent);\n --wcs-input-prefix-suffix-color-disabled: var(--wcs-semantic-color-text-disabled);\n --wcs-input-prefix-suffix-font-weight: var(--wcs-semantic-font-weight-medium);\n\n --wcs-input-border-style-default: solid;\n --wcs-input-border-style-focus: var(--wcs-semantic-border-style-focus-control);\n\n --wcs-input-border-color-default: var(--wcs-semantic-color-border-primary);\n --wcs-input-border-color-disabled: var(--wcs-semantic-color-border-disabled);\n --wcs-input-border-color-focus: var(--wcs-semantic-color-border-control-focus);\n --wcs-input-reveal-password-button-border-color-focus: var(--wcs-semantic-color-border-focus-base);\n --wcs-input-border-color-error: var(--wcs-semantic-color-border-critical);\n\n --wcs-input-value-color: var(--wcs-semantic-color-text-primary);\n --wcs-input-value-font-weight: var(--wcs-semantic-font-weight-medium);\n\n --wcs-input-placeholder-color: var(--wcs-semantic-color-text-tertiary);\n --wcs-input-placeholder-font-weight: var(--wcs-semantic-font-weight-roman);\n --wcs-input-placeholder-font-style: var(--wcs-semantic-font-style-control-placeholder);\n\n --wcs-input-text-color-disabled: var(--wcs-semantic-color-text-disabled);\n\n --wcs-input-min-height: var(--wcs-semantic-size-s);\n --wcs-input-padding-horizontal-s: calc(1.5 * var(--wcs-semantic-spacing-base));\n --wcs-input-padding-horizontal-m: var(--wcs-semantic-spacing-large);\n --wcs-input-padding-horizontal-l: var(--wcs-semantic-spacing-large);\n --wcs-input-gap: var(--wcs-semantic-spacing-base);\n\n // Default\n --wcs-input-host-height: var(--wcs-input-height-m);\n --wcs-input-font-size: var(--wcs-input-font-size-m);\n padding-left: calc(var(--wcs-input-padding-horizontal-m));\n padding-right: calc(var(--wcs-input-padding-horizontal-m));\n\n display: flex;\n width: 100%;\n height: var(--wcs-input-host-height);\n box-sizing: border-box;\n border-radius: var(--wcs-input-border-radius-left) var(--wcs-input-border-radius-right) var(--wcs-input-border-radius-right) var(--wcs-input-border-radius-left);\n background-color: var(--wcs-input-background-color);\n outline: var(--wcs-input-border-style-default) var(--wcs-input-border-width) var(--wcs-input-border-color-default);\n outline-offset: calc(var(--wcs-input-border-width) * -1);\n background-clip: padding-box;\n\n gap: var(--wcs-input-gap);\n\n input {\n overflow: hidden;\n height: var(--wcs-input-host-height);\n width: 100%;\n padding: 0; // Reset padding from user agent stylesheet, it's the container that will handle padding\n background-color: transparent;\n font-family: var(--wcs-font-sans-serif);\n color: var(--wcs-input-value-color);\n font-weight: var(--wcs-input-value-font-weight) !important;\n border: none;\n font-size: var(--wcs-input-font-size, 1rem);\n line-height: 1.5;\n\n &::placeholder {\n @include placeholder(var(--wcs-input-placeholder-color), var(--wcs-input-placeholder-font-weight), var(--wcs-input-placeholder-font-style));\n }\n }\n\n input:focus {\n box-shadow: none;\n outline: 0;\n }\n\n button.toggle_password {\n background: transparent;\n border: none;\n color: inherit;\n\n cursor: pointer;\n\n\n &:focus-visible {\n @include focus-outline(var(--wcs-input-reveal-password-button-border-color-focus), $outline-offset: calc(-2 * var(--wcs-input-border-width-focus)));\n }\n }\n\n .prefix, .suffix {\n color: var(--wcs-input-prefix-suffix-color);\n display: flex;\n white-space: nowrap;\n align-items: center;\n font-size: var(--wcs-input-font-size, 1rem);\n padding: 0 calc(var(--wcs-input-padding-horizontal-m) / 2);\n font-weight: var(--wcs-input-prefix-suffix-font-weight) !important;\n background-color: var(--wcs-input-prefix-suffix-background-color);\n }\n\n .prefix {\n border-radius: var(--wcs-internal-input-border-radius-left) 0 0 var(--wcs-internal-input-border-radius-left);\n }\n\n .suffix {\n border-radius: 0 var(--wcs-internal-input-border-radius-right) var(--wcs-internal-input-border-radius-right) 0;\n }\n\n wcs-mat-icon {\n color: var(--wcs-input-icon-color-default);\n }\n}\n\n:host([size=l]) {\n --wcs-input-host-height: var(--wcs-input-height-l);\n --wcs-input-font-size: var(--wcs-input-font-size-l);\n\n padding-left: calc(var(--wcs-input-padding-horizontal-l));\n padding-right: calc(var(--wcs-input-padding-horizontal-l));\n}\n\n:host([size=m]) { // Default\n --wcs-input-host-height: var(--wcs-input-height-m);\n --wcs-input-font-size: var(--wcs-input-font-size-m);\n\n padding-left: calc(var(--wcs-input-padding-horizontal-m));\n padding-right: calc(var(--wcs-input-padding-horizontal-m));\n}\n\n:host([size=s]) {\n --wcs-input-host-height: var(--wcs-input-height-s);\n --wcs-input-font-size: var(--wcs-input-font-size-s);\n\n padding-left: calc(var(--wcs-input-padding-horizontal-s));\n padding-right: calc(var(--wcs-input-padding-horizontal-s));\n}\n\n:host([state=error]) {\n outline-color: var(--wcs-input-border-color-error) !important;\n}\n\n:host([data-has-prefix]) {\n padding-left: 0;\n}\n\n:host([data-has-suffix]) {\n padding-right: 0;\n}\n\n:host([disabled]) {\n cursor: not-allowed; // padding is handled by the container, so we need to set cursor not allowed on it\n outline: var(--wcs-input-border-style-default) var(--wcs-input-border-width) var(--wcs-input-border-color-disabled);\n --wcs-input-background-color: var(--wcs-semantic-color-background-control-disabled);\n\n input {\n cursor: not-allowed;\n color: var(--wcs-input-text-color-disabled);\n\n &::placeholder {\n color: var(--wcs-input-text-color-disabled);\n }\n }\n\n .prefix, .suffix {\n color: var(--wcs-input-prefix-suffix-color-disabled);\n cursor: text; // reset cursor to text for prefix and suffix, to be able to select text\n }\n\n wcs-mat-icon {\n color: var(--wcs-input-icon-color-disabled);\n cursor: not-allowed;\n }\n}\n\n:host([readonly]) {\n --wcs-input-background-color: var(--wcs-semantic-color-background-control-readonly);\n --wcs-input-border-width: 0;\n}\n\n:host(:focus-within) {\n outline: var(--wcs-input-border-style-focus) var(--wcs-input-border-width-focus) var(--wcs-input-border-color-focus);\n outline-offset: calc(var(--wcs-input-border-width-focus) * -1);\n\n wcs-mat-icon {\n color: var(--wcs-input-icon-color-focus);\n }\n}\n","import {\n Build,\n Component,\n ComponentInterface,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Method,\n Prop,\n State,\n Watch\n} from '@stencil/core';\nimport {\n debounceEvent,\n findItemLabel,\n inheritAriaAttributes,\n inheritAttributes,\n setOrRemoveAttribute\n} from '../../utils/helpers';\nimport {\n AutocompleteTypes,\n InputChangeEventDetail,\n TextFieldTypes,\n WcsInputSize,\n WcsInputAutocorrect,\n WcsInputEnterKeyHint,\n WcsInputInputMode,\n WcsInputState\n} from './input-interface';\nimport { AriaAttributeName, MutableAriaAttribute } from \"../../utils/mutable-aria-attribute\";\n\nconst INPUT_INHERITED_ATTRS = ['tabindex', 'title'];\n\n/**\n * The input component is a form control that accepts a single line of text.\n * Implementation mainly inspired from Ionic Input Component.\n *\n * ## Accessibility guidelines 💡\n * > - If you use wcs-input outside a wcs-form-field, you have to manage the label and the error message yourself.\n * > You can use the `aria-label` attribute to provide a label for screen readers but adds no visual label.\n * \n * @cssprop --wcs-input-icon-color-default - default icon color when the input is not focused\n * @cssprop --wcs-input-icon-color-focus - icon color when the input is focused\n * @cssprop --wcs-input-icon-color-disabled - icon color when the input is disabled\n *\n * @cssprop --wcs-input-background-color - background color of the input\n *\n * @cssprop --wcs-input-border-radius-left - border radius of the left side of the input\n * @cssprop --wcs-input-border-radius-right - border radius of the right side of the input\n * \n * @cssprop --wcs-input-border-width - border width of the input\n * @cssprop --wcs-input-border-width-focus - border width of the input when focused\n *\n * @cssprop --wcs-input-height-l - large height of the input\n * @cssprop --wcs-input-height-m - medium height of the input\n * @cssprop --wcs-input-height-s - small height of the input\n * @cssprop --wcs-input-font-size-l - large font size of the input\n * @cssprop --wcs-input-font-size-m - medium font size of the input\n * @cssprop --wcs-input-font-size-s - small font size of the input\n *\n * @cssprop --wcs-input-border-style-default - default border style of the input\n * @cssprop --wcs-input-border-style-focus - border style of the input when focused\n * \n * @cssprop --wcs-input-prefix-suffix-background-color - background color of the suffix/prefix\n * @cssprop --wcs-input-prefix-suffix-color - color of the suffix/prefix\n * @cssprop --wcs-input-prefix-suffix-color-disabled - color of the suffix/prefix when the input is disabled\n * @cssprop --wcs-input-prefix-suffix-font-weight - font weight of the suffix/prefix\n *\n * @cssprop --wcs-input-border-color-default - default border color of the input when not focused\n * @cssprop --wcs-input-border-color-disabled - border color of the input when disabled\n * @cssprop --wcs-input-border-color-focus - border color of the input when focused\n * @cssprop --wcs-input-reveal-password-button-border-color-focus - border color of the show/hide password button when focused\n * @cssprop --wcs-input-border-color-error - border color of the input when in error state\n *\n * @cssprop --wcs-input-value-color - color of the input value\n * @cssprop --wcs-input-value-font-weight - font weight of the input value\n * \n * @cssprop --wcs-input-placeholder-color - color of the input placeholder\n * @cssprop --wcs-input-placeholder-font-weight - font weight of the input placeholder\n * @cssprop --wcs-input-placeholder-font-style - font style of the input placeholder\n * \n * @cssprop --wcs-input-text-color-disabled - color of the input when disabled\n *\n * @cssprop --wcs-input-padding-horizontal-s - horizontal padding of the input in small size\n * @cssprop --wcs-input-padding-horizontal-m - horizontal padding of the input in medium size\n * @cssprop --wcs-input-padding-horizontal-l - horizontal padding of the input in large size\n * \n * @cssprop --wcs-input-gap - gap between text input and icon\n */\n@Component({\n tag: 'wcs-input',\n styleUrl: 'input.scss',\n shadow: { delegatesFocus: true },\n})\nexport class Input implements ComponentInterface, MutableAriaAttribute {\n @Element() private el!: HTMLElement;\n private nativeInput?: HTMLInputElement;\n private inputId = `wcs-input-${inputIds++}`;\n private inheritedAttributes: { [k: string]: any } = {};\n private iconPassword = \"visibility\";\n\n /**\n * This is required for a WebKit bug which requires us to\n * blur and focus an input to properly focus the input in\n * an item with delegatesFocus. It will no longer be needed\n * with iOS 14.\n *\n * @internal\n */\n @Prop() fireFocusEvents: boolean = true;\n\n @State() private passwordReveal: boolean = false;\n\n /**\n * If the value of the type attribute is `\"file\"`, then this attribute will indicate the types of files that the\n * server accepts, otherwise it will be ignored. The value must be a comma-separated list of unique content type specifiers.\n */\n @Prop() accept?: string;\n\n /**\n * Indicates whether and how the text value should be automatically capitalized as it is entered/edited by the user.\n * Available options: `\"off\"`, `\"none\"`, `\"on\"`, `\"sentences\"`, `\"words\"`, `\"characters\"`.\n */\n @Prop() autocapitalize = 'off';\n\n /**\n * Indicates whether the value of the control can be automatically completed by the browser.\n */\n @Prop() autocomplete: AutocompleteTypes = 'off';\n\n /**\n * Whether auto correction should be enabled when the user is entering/editing the text value.\n */\n @Prop() autocorrect: WcsInputAutocorrect = 'off';\n\n /**\n * This Boolean attribute lets you specify that a form control should have input focus when the page loads.\n */\n @Prop() autofocus: boolean = false;\n\n /**\n * Set the amount of time, in milliseconds, to wait to trigger the `wcsInput` event after each keystroke.\n * This also impacts form bindings such as `ngModel` or `v-model`.\n */\n @Prop() debounce = 0;\n\n @Watch('debounce')\n protected debounceChanged() {\n this.wcsInput = debounceEvent(this.wcsInput, this.debounce);\n }\n\n /**\n * Prefix displayed before the text field contents. This is not included in the value.\n */\n @Prop() prefixLabel: string;\n\n /**\n * Suffix displayed after the text field contents. This is not included in the value.\n */\n @Prop() suffixLabel: string;\n\n /**\n * If `true`, the user cannot interact with the input.\n */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /**\n * A hint to the browser for which enter key to display.\n */\n @Prop() enterkeyhint?: WcsInputEnterKeyHint;\n\n /**\n * Specify the size (height) of the input.\n */\n @Prop({reflect: true}) size: WcsInputSize = 'm';\n\n /**\n * Name of the material icon to add to the input\n */\n @Prop() icon: string;\n\n /**\n * A hint to the browser for which keyboard to display.\n */\n @Prop() inputmode?: WcsInputInputMode;\n\n /**\n * The maximum value, which must not be less than its minimum (min attribute) value.\n */\n @Prop() max?: string;\n\n /**\n * If the value of the type attribute is `text`, `email`, `search`, `password`, `tel`, or `url`, this attribute\n * specifies the maximum number of characters that the user can enter.\n */\n @Prop() maxlength?: number;\n\n /**\n * The minimum value, which must not be greater than its maximum (max attribute) value.\n */\n @Prop() min?: string;\n\n /**\n * If the value of the type attribute is `text`, `email`, `search`, `password`, `tel`, or `url`, this attribute\n * specifies the minimum number of characters that the user can enter.\n */\n @Prop() minlength?: number;\n\n /**\n * If `true`, the user can enter more than one value. This attribute applies when the type attribute is set to\n * `\"email\"` or `\"file\"`, otherwise it is ignored.\n */\n @Prop({ reflect: true }) multiple?: boolean;\n\n /**\n * The name of the control, which is submitted with the form data.\n */\n @Prop() name: string = this.inputId;\n\n @Prop() hidePasswordButtonAriaLabel: string = \"Cacher le mot de passe\";\n @Prop() showPasswordButtonAriaLabel: string = \"Afficher le mot de passe\";\n\n /**\n * A regular expression that the value is checked against. The pattern must match the entire value, not just some\n * subset. Use the title attribute to describe the pattern to help the user. This attribute applies when the value\n * of the type attribute is `\"text\"`, `\"search\"`, `\"tel\"`, `\"url\"`, `\"email\"`, `\"date\"`, or `\"password\"`, otherwise\n * it is ignored. When the type attribute is `\"date\"`, `pattern` will only be used in browsers that do not support\n * the `\"date\"` input type natively. See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/date for\n * more information.\n */\n @Prop() pattern?: string;\n\n /**\n * Instructional text that shows before the input has a value.\n */\n @Prop() placeholder?: string | null;\n\n /**\n * If `true`, the user cannot modify the value.\n */\n @Prop({ reflect: true }) readonly: boolean = false;\n\n /**\n * If `true`, the user must fill in a value before submitting a form.\n */\n @Prop({ reflect: true }) required: boolean = false;\n\n /**\n * If `true`, the element will have its spelling and grammar checked.\n */\n @Prop() spellcheck: boolean = false;\n\n /**\n * Specifies the state of the input. By default the input is in an normal state but you can to set it to 'error'\n * state if the data given by the user is not valid.\n */\n @Prop({reflect: true}) state: WcsInputState = 'initial';\n\n /**\n * Works with the min and max attributes to limit the increments at which a value can be set.\n * Possible values are: `\"any\"` or a positive floating point number.\n */\n @Prop() step?: string;\n\n /**\n * The type of control to display. The default type is text.\n */\n @Prop() type: TextFieldTypes = 'text';\n\n /**\n * The value of the input.\n */\n @Prop({mutable: true}) value?: string | number | null = '';\n\n /**\n * Emitted when a keyboard input occurred. See https://developer.mozilla.org/en-US/docs/Web/Events/input\n */\n @Event() wcsInput!: EventEmitter<KeyboardEvent>;\n\n /**\n * Emitted when the value has changed. See https://developer.mozilla.org/en-US/docs/Web/Events/change\n */\n @Event() wcsChange!: EventEmitter<InputChangeEventDetail>;\n\n /**\n * Emitted when the input loses focus.\n */\n @Event() wcsBlur!: EventEmitter<FocusEvent>;\n\n /**\n * Emitted when the input has focus.\n */\n @Event() wcsFocus!: EventEmitter<FocusEvent>;\n\n componentWillLoad() {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el),\n ...inheritAttributes(this.el, INPUT_INHERITED_ATTRS)\n };\n }\n\n connectedCallback() {\n this.debounceChanged();\n if (Build.isBrowser) {\n document.dispatchEvent(new CustomEvent('wcsInputDidLoad', {\n detail: this.el\n }));\n }\n }\n\n disconnectedCallback() {\n if (Build.isBrowser) {\n document.dispatchEvent(new CustomEvent('wcsInputDidUnload', {\n detail: this.el\n }));\n }\n }\n\n /**\n * Sets blur on the native `input` in `wcs-input`. Use this method instead of the global\n * `input.blur()`.\n * @internal\n */\n @Method()\n async setBlur() {\n if (this.nativeInput) {\n this.nativeInput.blur();\n }\n }\n\n /**\n * Returns the native `<input>` element used under the hood.\n */\n @Method()\n getInputElement(): Promise<HTMLInputElement> {\n return Promise.resolve(this.nativeInput!);\n }\n\n @Method()\n async setAriaAttribute(attr: AriaAttributeName, value: string | null | undefined) {\n setOrRemoveAttribute(this.nativeInput, attr, value);\n }\n \n private getValueAsString(): string {\n return typeof this.value === 'number' ? this.value.toString() :\n (this.value || '').toString();\n }\n\n private onInput = (ev: Event) => {\n const input = ev.target as HTMLInputElement | null;\n if (input) {\n this.value = input.value || '';\n }\n this.wcsInput.emit(ev as KeyboardEvent);\n }\n\n private onChange = (_: Event) => {\n this.wcsChange.emit({value: this.nativeInput.value});\n }\n\n private onBlur = (ev: FocusEvent) => {\n if (this.fireFocusEvents) {\n this.wcsBlur.emit(ev);\n }\n }\n\n private onFocus = (ev: FocusEvent) => {\n if (this.fireFocusEvents) {\n this.wcsFocus.emit(ev);\n }\n }\n\n private passwordRevealIconClick(): void {\n this.passwordReveal = !this.passwordReveal;\n }\n\n @Watch('passwordReveal')\n onPasswordRevealChange(): void {\n this.iconPassword = this.passwordReveal ? 'visibility_off' : 'visibility';\n }\n\n render() {\n const value = this.getValueAsString();\n const labelId = this.inputId + '-lbl';\n const label = findItemLabel(this.el);\n if (label) {\n label.id = labelId;\n }\n\n return (\n <Host\n aria-disabled={this.disabled ? 'true' : null}\n data-has-prefix={!!this.prefixLabel}\n data-has-suffix={!!this.suffixLabel}\n >\n {this.prefixLabel ? (<span class=\"prefix\" part=\"prefix\">{this.prefixLabel}</span>) : null}\n {this.icon ? (<wcs-mat-icon icon={this.icon} size=\"m\"></wcs-mat-icon>) : null}\n <input\n class=\"native-input\"\n ref={input => this.nativeInput = input}\n aria-labelledby={label ? labelId : null}\n disabled={this.disabled}\n accept={this.accept}\n autoCapitalize={this.autocapitalize}\n autoComplete={this.autocomplete}\n autoCorrect={this.autocorrect}\n autoFocus={this.autofocus}\n enterKeyHint={this.enterkeyhint}\n inputMode={this.inputmode}\n min={this.min}\n max={this.max}\n minLength={this.minlength}\n maxLength={this.maxlength}\n multiple={this.multiple}\n name={this.name}\n pattern={this.pattern}\n placeholder={this.placeholder || ''}\n readOnly={this.readonly}\n required={this.required}\n spellcheck={this.spellcheck}\n step={this.step}\n type={this.passwordReveal ? 'text' : this.type}\n value={value}\n onInput={this.onInput}\n onChange={this.onChange}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n {...this.inheritedAttributes}\n />\n {this.type === \"password\" ? (\n <button title={this.passwordReveal ? this.hidePasswordButtonAriaLabel : this.showPasswordButtonAriaLabel} class=\"toggle_password\" onClick={() => this.passwordRevealIconClick()}>\n <wcs-mat-icon icon={this.iconPassword} size=\"m\"></wcs-mat-icon>\n </button>\n ) : null}\n {this.suffixLabel ? (<span class=\"suffix\" part=\"suffix\">{this.suffixLabel}</span>) : null}\n </Host>\n );\n }\n}\n\nlet inputIds = 0;\n"],"version":3}
|
|
1
|
+
{"file":"wcs-input.entry.cjs.js","mappings":"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","names":["debounceEvent","inheritAriaAttributes","inheritAttributes","setOrRemoveAttribute","h","Host"],"sources":["src/components/input/input.scss?tag=wcs-input&encapsulation=shadow","src/components/input/input.tsx"],"sourcesContent":["@import '../../style/focus-outline.scss';\n@import '../../style/placeholder.scss';\n\n:host {\n --wcs-input-icon-color-default: var(--wcs-semantic-color-foreground-brand);\n --wcs-input-icon-color-focus: var(--wcs-semantic-color-foreground-brand);\n --wcs-input-icon-color-disabled: var(--wcs-semantic-color-foreground-disabled);\n\n --wcs-input-background-color: var(--wcs-semantic-color-background-control-default);\n\n --wcs-input-border-radius-left: var(--wcs-semantic-border-radius-base); // Overridden from prefix suffix group in form-field\n --wcs-input-border-radius-right: var(--wcs-semantic-border-radius-base); // Overridden from prefix suffix group in form-field\n\n --wcs-input-border-width: var(--wcs-semantic-border-width-default);\n --wcs-input-border-width-focus: var(--wcs-semantic-border-width-large);\n\n --wcs-input-height-l: var(--wcs-semantic-size-l);\n --wcs-input-height-m: var(--wcs-semantic-size-m);\n --wcs-input-height-s: var(--wcs-semantic-size-s);\n --wcs-input-font-size-l: var(--wcs-semantic-font-size-l);\n --wcs-input-font-size-m: var(--wcs-semantic-font-size-m);\n --wcs-input-font-size-s: var(--wcs-semantic-font-size-s);\n\n --wcs-input-prefix-suffix-background-color: var(--wcs-semantic-color-background-surface-accent-lighter);\n --wcs-input-prefix-suffix-color: var(--wcs-semantic-color-foreground-on-accent);\n --wcs-input-prefix-suffix-color-disabled: var(--wcs-semantic-color-text-disabled);\n --wcs-input-prefix-suffix-font-weight: var(--wcs-semantic-font-weight-medium);\n\n --wcs-input-border-style-default: solid;\n --wcs-input-border-style-focus: var(--wcs-semantic-border-style-focus-control);\n\n --wcs-input-border-color-default: var(--wcs-semantic-color-border-primary);\n --wcs-input-border-color-disabled: var(--wcs-semantic-color-border-disabled);\n --wcs-input-border-color-focus: var(--wcs-semantic-color-border-control-focus);\n --wcs-input-reveal-password-button-border-color-focus: var(--wcs-semantic-color-border-focus-base);\n --wcs-input-border-color-error: var(--wcs-semantic-color-border-critical);\n\n --wcs-input-value-color: var(--wcs-semantic-color-text-primary);\n --wcs-input-value-font-weight: var(--wcs-semantic-font-weight-medium);\n\n --wcs-input-placeholder-color: var(--wcs-semantic-color-text-tertiary);\n --wcs-input-placeholder-font-weight: var(--wcs-semantic-font-weight-roman);\n --wcs-input-placeholder-font-style: var(--wcs-semantic-font-style-control-placeholder);\n\n --wcs-input-text-color-disabled: var(--wcs-semantic-color-text-disabled);\n\n --wcs-input-min-height: var(--wcs-semantic-size-s);\n --wcs-input-padding-horizontal-s: calc(1.5 * var(--wcs-semantic-spacing-base));\n --wcs-input-padding-horizontal-m: var(--wcs-semantic-spacing-large);\n --wcs-input-padding-horizontal-l: var(--wcs-semantic-spacing-large);\n --wcs-input-gap: var(--wcs-semantic-spacing-base);\n\n // Default\n --wcs-input-host-height: var(--wcs-input-height-m);\n --wcs-input-font-size: var(--wcs-input-font-size-m);\n padding-left: calc(var(--wcs-input-padding-horizontal-m));\n padding-right: calc(var(--wcs-input-padding-horizontal-m));\n\n display: flex;\n width: 100%;\n height: var(--wcs-input-host-height);\n box-sizing: border-box;\n border-radius: var(--wcs-input-border-radius-left) var(--wcs-input-border-radius-right) var(--wcs-input-border-radius-right) var(--wcs-input-border-radius-left);\n background-color: var(--wcs-input-background-color);\n outline: var(--wcs-input-border-style-default) var(--wcs-input-border-width) var(--wcs-input-border-color-default);\n outline-offset: calc(var(--wcs-input-border-width) * -1);\n background-clip: padding-box;\n\n gap: var(--wcs-input-gap);\n\n input {\n overflow: hidden;\n height: var(--wcs-input-host-height);\n width: 100%;\n padding: 0; // Reset padding from user agent stylesheet, it's the container that will handle padding\n background-color: transparent;\n font-family: var(--wcs-font-sans-serif);\n color: var(--wcs-input-value-color);\n font-weight: var(--wcs-input-value-font-weight) !important;\n border: none;\n font-size: var(--wcs-input-font-size, 1rem);\n line-height: 1.5;\n\n &::placeholder {\n @include placeholder(var(--wcs-input-placeholder-color), var(--wcs-input-placeholder-font-weight), var(--wcs-input-placeholder-font-style));\n }\n }\n\n input:focus {\n box-shadow: none;\n outline: 0;\n }\n\n button.toggle_password {\n background: transparent;\n border: none;\n color: inherit;\n\n cursor: pointer;\n\n\n &:focus-visible {\n @include focus-outline(var(--wcs-input-reveal-password-button-border-color-focus), $outline-offset: calc(-2 * var(--wcs-input-border-width-focus)));\n }\n }\n\n .prefix, .suffix {\n color: var(--wcs-input-prefix-suffix-color);\n display: flex;\n white-space: nowrap;\n align-items: center;\n font-size: var(--wcs-input-font-size, 1rem);\n padding: 0 calc(var(--wcs-input-padding-horizontal-m) / 2);\n font-weight: var(--wcs-input-prefix-suffix-font-weight) !important;\n background-color: var(--wcs-input-prefix-suffix-background-color);\n }\n\n .prefix {\n border-radius: var(--wcs-internal-input-border-radius-left) 0 0 var(--wcs-internal-input-border-radius-left);\n }\n\n .suffix {\n border-radius: 0 var(--wcs-internal-input-border-radius-right) var(--wcs-internal-input-border-radius-right) 0;\n }\n\n wcs-mat-icon {\n color: var(--wcs-input-icon-color-default);\n }\n}\n\n:host([size=l]) {\n --wcs-input-host-height: var(--wcs-input-height-l);\n --wcs-input-font-size: var(--wcs-input-font-size-l);\n\n padding-left: calc(var(--wcs-input-padding-horizontal-l));\n padding-right: calc(var(--wcs-input-padding-horizontal-l));\n}\n\n:host([size=m]) { // Default\n --wcs-input-host-height: var(--wcs-input-height-m);\n --wcs-input-font-size: var(--wcs-input-font-size-m);\n\n padding-left: calc(var(--wcs-input-padding-horizontal-m));\n padding-right: calc(var(--wcs-input-padding-horizontal-m));\n}\n\n:host([size=s]) {\n --wcs-input-host-height: var(--wcs-input-height-s);\n --wcs-input-font-size: var(--wcs-input-font-size-s);\n\n padding-left: calc(var(--wcs-input-padding-horizontal-s));\n padding-right: calc(var(--wcs-input-padding-horizontal-s));\n}\n\n:host([state=error]) {\n outline-color: var(--wcs-input-border-color-error) !important;\n}\n\n:host([data-has-prefix]) {\n padding-left: 0;\n}\n\n:host([data-has-suffix]) {\n padding-right: 0;\n}\n\n:host([disabled]) {\n cursor: not-allowed; // padding is handled by the container, so we need to set cursor not allowed on it\n outline: var(--wcs-input-border-style-default) var(--wcs-input-border-width) var(--wcs-input-border-color-disabled);\n --wcs-input-background-color: var(--wcs-semantic-color-background-control-disabled);\n\n input {\n cursor: not-allowed;\n color: var(--wcs-input-text-color-disabled);\n\n &::placeholder {\n color: var(--wcs-input-text-color-disabled);\n }\n }\n\n .prefix, .suffix {\n color: var(--wcs-input-prefix-suffix-color-disabled);\n cursor: text; // reset cursor to text for prefix and suffix, to be able to select text\n }\n\n wcs-mat-icon {\n color: var(--wcs-input-icon-color-disabled);\n cursor: not-allowed;\n }\n}\n\n:host([readonly]) {\n --wcs-input-background-color: var(--wcs-semantic-color-background-control-readonly);\n --wcs-input-border-width: 0;\n}\n\n:host(:focus-within) {\n outline: var(--wcs-input-border-style-focus) var(--wcs-input-border-width-focus) var(--wcs-input-border-color-focus);\n outline-offset: calc(var(--wcs-input-border-width-focus) * -1);\n\n wcs-mat-icon {\n color: var(--wcs-input-icon-color-focus);\n }\n}\n","import {\n Build,\n Component,\n ComponentInterface,\n Element,\n Event,\n EventEmitter,\n h,\n Host,\n Method,\n Prop,\n State,\n Watch\n} from '@stencil/core';\nimport {\n debounceEvent,\n inheritAriaAttributes,\n inheritAttributes,\n setOrRemoveAttribute\n} from '../../utils/helpers';\nimport {\n AutocompleteTypes,\n InputChangeEventDetail,\n TextFieldTypes,\n WcsInputSize,\n WcsInputAutocorrect,\n WcsInputEnterKeyHint,\n WcsInputInputMode,\n WcsInputState\n} from './input-interface';\nimport { AriaAttributeName, MutableAriaAttribute } from \"../../utils/mutable-aria-attribute\";\n\nconst INPUT_INHERITED_ATTRS = ['tabindex', 'title'];\n\n/**\n * The input component is a form control that accepts a single line of text.\n * Implementation mainly inspired from Ionic Input Component.\n *\n * ## Accessibility guidelines 💡\n * > - If you use wcs-input outside a wcs-form-field, you have to manage the label and the error message yourself.\n * > You can use the `aria-label` attribute to provide a label for screen readers but adds no visual label.\n * \n * @cssprop --wcs-input-icon-color-default - default icon color when the input is not focused\n * @cssprop --wcs-input-icon-color-focus - icon color when the input is focused\n * @cssprop --wcs-input-icon-color-disabled - icon color when the input is disabled\n *\n * @cssprop --wcs-input-background-color - background color of the input\n *\n * @cssprop --wcs-input-border-radius-left - border radius of the left side of the input\n * @cssprop --wcs-input-border-radius-right - border radius of the right side of the input\n * \n * @cssprop --wcs-input-border-width - border width of the input\n * @cssprop --wcs-input-border-width-focus - border width of the input when focused\n *\n * @cssprop --wcs-input-height-l - large height of the input\n * @cssprop --wcs-input-height-m - medium height of the input\n * @cssprop --wcs-input-height-s - small height of the input\n * @cssprop --wcs-input-font-size-l - large font size of the input\n * @cssprop --wcs-input-font-size-m - medium font size of the input\n * @cssprop --wcs-input-font-size-s - small font size of the input\n *\n * @cssprop --wcs-input-border-style-default - default border style of the input\n * @cssprop --wcs-input-border-style-focus - border style of the input when focused\n * \n * @cssprop --wcs-input-prefix-suffix-background-color - background color of the suffix/prefix\n * @cssprop --wcs-input-prefix-suffix-color - color of the suffix/prefix\n * @cssprop --wcs-input-prefix-suffix-color-disabled - color of the suffix/prefix when the input is disabled\n * @cssprop --wcs-input-prefix-suffix-font-weight - font weight of the suffix/prefix\n *\n * @cssprop --wcs-input-border-color-default - default border color of the input when not focused\n * @cssprop --wcs-input-border-color-disabled - border color of the input when disabled\n * @cssprop --wcs-input-border-color-focus - border color of the input when focused\n * @cssprop --wcs-input-reveal-password-button-border-color-focus - border color of the show/hide password button when focused\n * @cssprop --wcs-input-border-color-error - border color of the input when in error state\n *\n * @cssprop --wcs-input-value-color - color of the input value\n * @cssprop --wcs-input-value-font-weight - font weight of the input value\n * \n * @cssprop --wcs-input-placeholder-color - color of the input placeholder\n * @cssprop --wcs-input-placeholder-font-weight - font weight of the input placeholder\n * @cssprop --wcs-input-placeholder-font-style - font style of the input placeholder\n * \n * @cssprop --wcs-input-text-color-disabled - color of the input when disabled\n *\n * @cssprop --wcs-input-padding-horizontal-s - horizontal padding of the input in small size\n * @cssprop --wcs-input-padding-horizontal-m - horizontal padding of the input in medium size\n * @cssprop --wcs-input-padding-horizontal-l - horizontal padding of the input in large size\n * \n * @cssprop --wcs-input-gap - gap between text input and icon\n */\n@Component({\n tag: 'wcs-input',\n styleUrl: 'input.scss',\n shadow: { delegatesFocus: true },\n})\nexport class Input implements ComponentInterface, MutableAriaAttribute {\n @Element() private el!: HTMLElement;\n private nativeInput?: HTMLInputElement;\n private inputId = `wcs-input-${inputIds++}`;\n private inheritedAttributes: { [k: string]: any } = {};\n private iconPassword = \"visibility\";\n\n /**\n * This is required for a WebKit bug which requires us to\n * blur and focus an input to properly focus the input in\n * an item with delegatesFocus. It will no longer be needed\n * with iOS 14.\n *\n * @internal\n */\n @Prop() fireFocusEvents: boolean = true;\n\n @State() private passwordReveal: boolean = false;\n\n /**\n * If the value of the type attribute is `\"file\"`, then this attribute will indicate the types of files that the\n * server accepts, otherwise it will be ignored. The value must be a comma-separated list of unique content type specifiers.\n */\n @Prop() accept?: string;\n\n /**\n * Indicates whether and how the text value should be automatically capitalized as it is entered/edited by the user.\n * Available options: `\"off\"`, `\"none\"`, `\"on\"`, `\"sentences\"`, `\"words\"`, `\"characters\"`.\n */\n @Prop() autocapitalize = 'off';\n\n /**\n * Indicates whether the value of the control can be automatically completed by the browser.\n */\n @Prop() autocomplete: AutocompleteTypes = 'off';\n\n /**\n * Whether auto correction should be enabled when the user is entering/editing the text value.\n */\n @Prop() autocorrect: WcsInputAutocorrect = 'off';\n\n /**\n * This Boolean attribute lets you specify that a form control should have input focus when the page loads.\n */\n @Prop() autofocus: boolean = false;\n\n /**\n * Set the amount of time, in milliseconds, to wait to trigger the `wcsInput` event after each keystroke.\n * This also impacts form bindings such as `ngModel` or `v-model`.\n */\n @Prop() debounce = 0;\n\n @Watch('debounce')\n protected debounceChanged() {\n this.wcsInput = debounceEvent(this.wcsInput, this.debounce);\n }\n\n /**\n * Prefix displayed before the text field contents. This is not included in the value.\n */\n @Prop() prefixLabel: string;\n\n /**\n * Suffix displayed after the text field contents. This is not included in the value.\n */\n @Prop() suffixLabel: string;\n\n /**\n * If `true`, the user cannot interact with the input.\n */\n @Prop({ reflect: true }) disabled: boolean = false;\n\n /**\n * A hint to the browser for which enter key to display.\n */\n @Prop() enterkeyhint?: WcsInputEnterKeyHint;\n\n /**\n * Specify the size (height) of the input.\n */\n @Prop({reflect: true}) size: WcsInputSize = 'm';\n\n /**\n * Name of the material icon to add to the input\n */\n @Prop() icon: string;\n\n /**\n * A hint to the browser for which keyboard to display.\n */\n @Prop() inputmode?: WcsInputInputMode;\n\n /**\n * The maximum value, which must not be less than its minimum (min attribute) value.\n */\n @Prop() max?: string;\n\n /**\n * If the value of the type attribute is `text`, `email`, `search`, `password`, `tel`, or `url`, this attribute\n * specifies the maximum number of characters that the user can enter.\n */\n @Prop() maxlength?: number;\n\n /**\n * The minimum value, which must not be greater than its maximum (max attribute) value.\n */\n @Prop() min?: string;\n\n /**\n * If the value of the type attribute is `text`, `email`, `search`, `password`, `tel`, or `url`, this attribute\n * specifies the minimum number of characters that the user can enter.\n */\n @Prop() minlength?: number;\n\n /**\n * If `true`, the user can enter more than one value. This attribute applies when the type attribute is set to\n * `\"email\"` or `\"file\"`, otherwise it is ignored.\n */\n @Prop({ reflect: true }) multiple?: boolean;\n\n /**\n * The name of the control, which is submitted with the form data.\n */\n @Prop() name: string = this.inputId;\n\n @Prop() hidePasswordButtonAriaLabel: string = \"Cacher le mot de passe\";\n @Prop() showPasswordButtonAriaLabel: string = \"Afficher le mot de passe\";\n\n /**\n * A regular expression that the value is checked against. The pattern must match the entire value, not just some\n * subset. Use the title attribute to describe the pattern to help the user. This attribute applies when the value\n * of the type attribute is `\"text\"`, `\"search\"`, `\"tel\"`, `\"url\"`, `\"email\"`, `\"date\"`, or `\"password\"`, otherwise\n * it is ignored. When the type attribute is `\"date\"`, `pattern` will only be used in browsers that do not support\n * the `\"date\"` input type natively. See https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/date for\n * more information.\n */\n @Prop() pattern?: string;\n\n /**\n * Instructional text that shows before the input has a value.\n */\n @Prop() placeholder?: string | null;\n\n /**\n * If `true`, the user cannot modify the value.\n */\n @Prop({ reflect: true }) readonly: boolean = false;\n\n /**\n * If `true`, the user must fill in a value before submitting a form.\n */\n @Prop({ reflect: true }) required: boolean = false;\n\n /**\n * If `true`, the element will have its spelling and grammar checked.\n */\n @Prop() spellcheck: boolean = false;\n\n /**\n * Specifies the state of the input. By default the input is in an normal state but you can to set it to 'error'\n * state if the data given by the user is not valid.\n */\n @Prop({reflect: true}) state: WcsInputState = 'initial';\n\n /**\n * Works with the min and max attributes to limit the increments at which a value can be set.\n * Possible values are: `\"any\"` or a positive floating point number.\n */\n @Prop() step?: string;\n\n /**\n * The type of control to display. The default type is text.\n */\n @Prop() type: TextFieldTypes = 'text';\n\n /**\n * The value of the input.\n */\n @Prop({mutable: true}) value?: string | number | null = '';\n\n /**\n * Emitted when a keyboard input occurred. See https://developer.mozilla.org/en-US/docs/Web/Events/input\n */\n @Event() wcsInput!: EventEmitter<KeyboardEvent>;\n\n /**\n * Emitted when the value has changed. See https://developer.mozilla.org/en-US/docs/Web/Events/change\n */\n @Event() wcsChange!: EventEmitter<InputChangeEventDetail>;\n\n /**\n * Emitted when the input loses focus.\n */\n @Event() wcsBlur!: EventEmitter<FocusEvent>;\n\n /**\n * Emitted when the input has focus.\n */\n @Event() wcsFocus!: EventEmitter<FocusEvent>;\n\n componentWillLoad() {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el),\n ...inheritAttributes(this.el, INPUT_INHERITED_ATTRS)\n };\n }\n\n connectedCallback() {\n this.debounceChanged();\n if (Build.isBrowser) {\n document.dispatchEvent(new CustomEvent('wcsInputDidLoad', {\n detail: this.el\n }));\n }\n }\n\n disconnectedCallback() {\n if (Build.isBrowser) {\n document.dispatchEvent(new CustomEvent('wcsInputDidUnload', {\n detail: this.el\n }));\n }\n }\n\n /**\n * Sets blur on the native `input` in `wcs-input`. Use this method instead of the global\n * `input.blur()`.\n * @internal\n */\n @Method()\n async setBlur() {\n if (this.nativeInput) {\n this.nativeInput.blur();\n }\n }\n\n /**\n * Returns the native `<input>` element used under the hood.\n */\n @Method()\n getInputElement(): Promise<HTMLInputElement> {\n return Promise.resolve(this.nativeInput!);\n }\n\n @Method()\n async setAriaAttribute(attr: AriaAttributeName, value: string | null | undefined) {\n setOrRemoveAttribute(this.nativeInput, attr, value);\n }\n \n private getValueAsString(): string {\n return typeof this.value === 'number' ? this.value.toString() :\n (this.value || '').toString();\n }\n\n private onInput = (ev: Event) => {\n const input = ev.target as HTMLInputElement | null;\n if (input) {\n this.value = input.value || '';\n }\n this.wcsInput.emit(ev as KeyboardEvent);\n }\n\n private onChange = (_: Event) => {\n this.wcsChange.emit({value: this.nativeInput.value});\n }\n\n private onBlur = (ev: FocusEvent) => {\n if (this.fireFocusEvents) {\n this.wcsBlur.emit(ev);\n }\n }\n\n private onFocus = (ev: FocusEvent) => {\n if (this.fireFocusEvents) {\n this.wcsFocus.emit(ev);\n }\n }\n\n private passwordRevealIconClick(): void {\n this.passwordReveal = !this.passwordReveal;\n }\n\n @Watch('passwordReveal')\n onPasswordRevealChange(): void {\n this.iconPassword = this.passwordReveal ? 'visibility_off' : 'visibility';\n }\n\n render() {\n const value = this.getValueAsString();\n\n return (\n <Host\n aria-disabled={this.disabled ? 'true' : null}\n data-has-prefix={!!this.prefixLabel}\n data-has-suffix={!!this.suffixLabel}\n >\n {this.prefixLabel ? (<span class=\"prefix\" part=\"prefix\">{this.prefixLabel}</span>) : null}\n {this.icon ? (<wcs-mat-icon icon={this.icon} size=\"m\"></wcs-mat-icon>) : null}\n <input\n class=\"native-input\"\n ref={input => this.nativeInput = input}\n disabled={this.disabled}\n accept={this.accept}\n autoCapitalize={this.autocapitalize}\n autoComplete={this.autocomplete}\n autoCorrect={this.autocorrect}\n autoFocus={this.autofocus}\n enterKeyHint={this.enterkeyhint}\n inputMode={this.inputmode}\n min={this.min}\n max={this.max}\n minLength={this.minlength}\n maxLength={this.maxlength}\n multiple={this.multiple}\n name={this.name}\n pattern={this.pattern}\n placeholder={this.placeholder || ''}\n readOnly={this.readonly}\n required={this.required}\n spellcheck={this.spellcheck}\n step={this.step}\n type={this.passwordReveal ? 'text' : this.type}\n value={value}\n onInput={this.onInput}\n onChange={this.onChange}\n onBlur={this.onBlur}\n onFocus={this.onFocus}\n {...this.inheritedAttributes}\n />\n {this.type === \"password\" ? (\n <button title={this.passwordReveal ? this.hidePasswordButtonAriaLabel : this.showPasswordButtonAriaLabel} class=\"toggle_password\" onClick={() => this.passwordRevealIconClick()}>\n <wcs-mat-icon icon={this.iconPassword} size=\"m\"></wcs-mat-icon>\n </button>\n ) : null}\n {this.suffixLabel ? (<span class=\"suffix\" part=\"suffix\">{this.suffixLabel}</span>) : null}\n </Host>\n );\n }\n}\n\nlet inputIds = 0;\n"],"version":3}
|
|
@@ -12,7 +12,7 @@ const ListItemProperties = class {
|
|
|
12
12
|
index.registerInstance(this, hostRef);
|
|
13
13
|
}
|
|
14
14
|
render() {
|
|
15
|
-
return (index.h(index.Host, { key: '
|
|
15
|
+
return (index.h(index.Host, { key: '168f5a846e64177a50b350cb90bee3b15a7eb871', slot: "properties" }, index.h("slot", { key: 'f5f3a8caa0da9384d409340f51f41c11971a0904', name: "property" })));
|
|
16
16
|
}
|
|
17
17
|
};
|
|
18
18
|
ListItemProperties.style = WcsListItemPropertiesStyle0;
|
|
@@ -12,7 +12,7 @@ const ListItemProperty = class {
|
|
|
12
12
|
index.registerInstance(this, hostRef);
|
|
13
13
|
}
|
|
14
14
|
render() {
|
|
15
|
-
return (index.h(index.Host, { key: '
|
|
15
|
+
return (index.h(index.Host, { key: '036366a768b3e90eb028cbdf18d006a595282420', slot: "property" }, index.h("slot", { key: 'f5ad277671ba35e014635562b97a279813e5bb0c' })));
|
|
16
16
|
}
|
|
17
17
|
};
|
|
18
18
|
ListItemProperty.style = WcsListItemPropertyStyle0;
|
|
@@ -13,7 +13,7 @@ const ListItem = class {
|
|
|
13
13
|
this.activated = false;
|
|
14
14
|
}
|
|
15
15
|
render() {
|
|
16
|
-
return (index.h(index.Host, { key: '
|
|
16
|
+
return (index.h(index.Host, { key: '1137c9770d8b50d24e8bb3187e586aca7a1ee3b9' }, index.h("slot", { key: '0c44655427e84534f1d6932ac3458d828cd31159', name: "icon" }), index.h("div", { key: '369bbe90f5d5c7a332732c3ba819b5959d09a25b', class: "content" }, index.h("div", { key: 'cd9c45f16a2455d1fe227d7d1e7e077d0327617d', class: "header" }, index.h("div", { key: 'c51172bf63657b2dde77836600ba3940ddde092b' }, index.h("slot", { key: '32452ee6fe06aa7d1652c5246c42afa3a2a66fbf', name: "title" }), index.h("slot", { key: '0bc5cf05d0fae6688ebb842bdeff3d88aa8682d8', name: "properties" })), index.h("slot", { key: '57ad3703881078ebd491166d874bd9593f6a405f', name: "actions" })), index.h("slot", { key: '70f35aa3d2034a8fb04c934d2659997a8b4c268b', name: "description" }))));
|
|
17
17
|
}
|
|
18
18
|
};
|
|
19
19
|
ListItem.style = WcsListItemStyle0;
|
|
@@ -31,7 +31,7 @@ const MatIcon = class {
|
|
|
31
31
|
helpers.setOrRemoveAttribute(this.nativeIcon, attr, value);
|
|
32
32
|
}
|
|
33
33
|
render() {
|
|
34
|
-
return (index.h(index.Host, { key: '
|
|
34
|
+
return (index.h(index.Host, { key: 'dec260ca9c57892e17402365e179a17a0e085b18' }, index.h("i", Object.assign({ key: 'f9e8fb980b2a99bff272b08c629347f6c1b28d49', "aria-hidden": "true", class: ICON_FAMILY_CLASS_NAME[this.family] + ' size-' + this.size, ref: (el) => (this.nativeIcon = el) }, this.inheritedAttributes), this.icon)));
|
|
35
35
|
}
|
|
36
36
|
get el() { return index.getElement(this); }
|
|
37
37
|
};
|
|
@@ -139,7 +139,7 @@ const Modal = class {
|
|
|
139
139
|
}
|
|
140
140
|
render() {
|
|
141
141
|
const modalTitleId = `wcs-modal-title-${this.modalId}`;
|
|
142
|
-
return (index.h(index.Host, { key: '
|
|
142
|
+
return (index.h(index.Host, { key: '2d08c87dcf9936d24dae178ee6a9cf84fb181faf' }, index.h("div", Object.assign({ key: '51c1cbdb0bfc0fbba675508fb7e9fafdc6adc8e4', class: "wcs-modal-container", "data-size": this.size, "aria-modal": "true", role: "dialog", "aria-labelledby": modalTitleId, ref: (el) => (this.nativeDivDialog = el) }, this.inheritedAttributes), index.h("div", { key: 'b62c495d23a0040eb160a93ccf858f7f0f60f83f', class: "wcs-modal-header" }, index.h("h1", { key: '8ea9cf9b9623305b79ed8f7cab3c2bf7e8ff242d', id: modalTitleId }, index.h("slot", { key: '972069f3d03047d4c56d8ea3c129f4296de4eb16', name: "header" })), this.showCloseButton && (index.h("wcs-button", { key: '49bf558d8092030497d29b399efb84c78f1c8748', shape: "round", mode: "clear", id: "wcs-modal-close-button", "aria-label": this.closeButtonAriaLabel, onClick: ($event) => this.onCloseButtonClick($event) }, index.h("wcs-mat-icon", { key: '1f2354939c40f22c2661a8a7383dfb9416b9c9da', icon: "close" })))), index.h("div", { key: '8f3fca88fa36f779c3d67f8694bee5a6386346e8', class: "wcs-modal-content" }, index.h("slot", { key: '4a65490518cbb450e825a9149e8516a3102f8ae3', onSlotchange: () => this.handleSlotContentChange() })), index.h("div", { key: 'be4cb11ff95787c58c6ac690a46522fcc04a6249', class: "wcs-modal-actions" }, index.h("slot", { key: '13a989d259e04ecdb1f89fcaafb7ab13898aee71', name: "actions" })))));
|
|
143
143
|
}
|
|
144
144
|
get el() { return index.getElement(this); }
|
|
145
145
|
static get watchers() { return {
|
|
@@ -124,7 +124,7 @@ const NativeSelect = class {
|
|
|
124
124
|
this._updateStyles();
|
|
125
125
|
}
|
|
126
126
|
render() {
|
|
127
|
-
return (index.h(index.Host, { key: '
|
|
127
|
+
return (index.h(index.Host, { key: '12431927c41eb386de134e92e5583fc0ff582b44', class: `${this.expanded ? 'expanded' : ''}`, "data-disabled": this.disabled, "data-size": this.size }, index.h("div", { key: 'b935ff599bc9829b0c771bf5aa13ae3605cddd98', class: "select-wrapper" }, index.h("slot", { key: 'c02ba432172f6b608f808a6365487b4ec7528a68' }), index.h("div", { key: '53841e3831eeb19165511caabe0f49e6b0a693d4', class: "arrow-container" }, index.h(selectArrow.SelectArrow, { key: '6b474db9957a98e8dada3ce4cda752a7299c5bf9', up: this.expanded })))));
|
|
128
128
|
}
|
|
129
129
|
get el() { return index.getElement(this); }
|
|
130
130
|
static get watchers() { return {
|
|
@@ -18,7 +18,7 @@ const NavItem = class {
|
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
20
|
render() {
|
|
21
|
-
return (index.h(index.Host, { key: '
|
|
21
|
+
return (index.h(index.Host, { key: '3d329f63e895cf09a57e1a0d8304cf833b0ba434', role: "listitem" }, index.h("slot", { key: 'bc4dadc9a3b665412880da1671aa518d7ecf290f' })));
|
|
22
22
|
}
|
|
23
23
|
get el() { return index.getElement(this); }
|
|
24
24
|
};
|
|
@@ -21,7 +21,7 @@ const Nav = class {
|
|
|
21
21
|
helpers.setOrRemoveAttribute(this.nativeNav, attr, value);
|
|
22
22
|
}
|
|
23
23
|
render() {
|
|
24
|
-
return (index.h("nav", Object.assign({ key: '
|
|
24
|
+
return (index.h("nav", Object.assign({ key: '73683911e6d8f624fb152a40e723d1b0920a6265', role: "navigation", class: "wcs-nav-container", ref: (el) => (this.nativeNav = el) }, this.inheritedAttributes), index.h("div", { key: 'e381eab2ef05be7bf28c3eff3e02034d7605015d', role: "list" }, index.h("slot", { key: '714a44e78e9d8495e1da0fd3f002e9cf769cdf95' }), index.h("slot", { key: '570a520fd2f16386c14a250e5786bd97ed3ba293', name: "bottom" }))));
|
|
25
25
|
}
|
|
26
26
|
get el() { return index.getElement(this); }
|
|
27
27
|
};
|
|
@@ -27,8 +27,8 @@ const ProgressBar = class {
|
|
|
27
27
|
const style = {
|
|
28
28
|
width: this.value + '%'
|
|
29
29
|
};
|
|
30
|
-
return (index.h("div", Object.assign({ key: '
|
|
31
|
-
index.h("span", { key: '
|
|
30
|
+
return (index.h("div", Object.assign({ key: 'f13a43d675ed082f811784a998e8bcd54e45a782', class: this.rootClasses(), role: "progressbar", "aria-valuemin": "0", "aria-valuemax": "100", "aria-valuenow": this.value, "aria-valuetext": this.value + '%', ref: (el) => (this.nativeProgress = el) }, this.inheritedAttributes), index.h("div", { key: '861383fa1ae516512a730cad52d1b9dc2ee55809', class: "progress-bar", style: style }, this.showLabel &&
|
|
31
|
+
index.h("span", { key: '0f0a9f0ce03562199f6a743f8dc653e276719b37', class: "progress-label" }, this.value, index.h("sup", { key: '8fa2735668eea7f46562e52748122e2e4fad9908' }, "%")))));
|
|
32
32
|
}
|
|
33
33
|
rootClasses() {
|
|
34
34
|
let classes = 'progress';
|
|
@@ -27,8 +27,8 @@ const ProgressRadial = class {
|
|
|
27
27
|
}
|
|
28
28
|
render() {
|
|
29
29
|
const { backgroundImageSize, halfSize } = { backgroundImageSize: this.backgroundImageSize, halfSize: this.backgroundImageSize / 2 };
|
|
30
|
-
return (index.h("div", Object.assign({ key: '
|
|
31
|
-
index.h("div", { key: '
|
|
30
|
+
return (index.h("div", Object.assign({ key: 'cd493dcab22c92a8683a89e394f51abfbabd0781', class: "progress-circle", "data-component": "radial-progress", style: this.getSize(), role: "progressbar", "aria-valuemin": "0", "aria-valuemax": "100", "aria-valuenow": this.value, "aria-valuetext": this.value + '%', ref: (el) => (this.nativeProgress = el) }, this.inheritedAttributes), index.h("svg", { key: 'e2c4ff80a735815ebbaf051f94108ca5e9a246fa', "data-role": "figure", class: "circle-rail", viewBox: `0 0 ${backgroundImageSize} ${backgroundImageSize}` }, index.h("circle", { key: '375db58b06b0f2c75dbd390e547ccc81258fdf43', cx: halfSize, cy: halfSize, r: 54, "stroke-width": 12 })), index.h("svg", { key: '6cf1fe11b1ec49d8f7cc7b1d53819bad47b24e3d', class: "progress-circle-figure", "data-role": "figure", viewBox: `0 0 ${backgroundImageSize} ${backgroundImageSize}`, style: this.getSvgStyle() }, index.h("circle", { key: '657a8ba78283a98c568eb436d9bfafdebf354934', class: "progress-circle-value", cx: halfSize, cy: halfSize, r: "54", "stroke-width": "12" })), this.showLabel &&
|
|
31
|
+
index.h("div", { key: '7ac452d83ad4bf88fc1e3d2bf63506e30185d115', class: "progress-circle-label", "data-role": "label" }, index.h("span", { key: 'e8827e91faeb2b1a36737ba35250ca0e9d64b830' }, index.h("span", { key: 'de2c9502060d10e020acbdc939efdcae4abc74d8', "data-role": "labelvalue" }, this.value), index.h("sup", { key: '9c872051b94e6ca06eae6a967c75173a0d03ee9a' }, "%")))));
|
|
32
32
|
}
|
|
33
33
|
getSvgStyle() {
|
|
34
34
|
return {
|
|
@@ -101,7 +101,7 @@ const RadioGroup = class {
|
|
|
101
101
|
}
|
|
102
102
|
}
|
|
103
103
|
render() {
|
|
104
|
-
return (index.h(index.Host, { key: '
|
|
104
|
+
return (index.h(index.Host, { key: '9e945b3bd3935232dbfd859e6a53f49523d6f49b', role: "radiogroup" }, index.h("slot", { key: '7c6a9ae33e2dbc25c1c696ee2d9957cc882d5eba', name: "option", onSlotchange: this.onSlotChange.bind(this) })));
|
|
105
105
|
}
|
|
106
106
|
get el() { return index.getElement(this); }
|
|
107
107
|
static get watchers() { return {
|
|
@@ -5,18 +5,27 @@ Object.defineProperty(exports, '__esModule', { value: true });
|
|
|
5
5
|
const index = require('./index-6f0140d8.js');
|
|
6
6
|
const helpers = require('./helpers-2f1a8ddc.js');
|
|
7
7
|
|
|
8
|
-
const radioCss = ":host{width:fit-content;--wcs-radio-transition-duration:var(--wcs-semantic-motion-duration-feedback-base);--wcs-radio-text-color-default:var(--wcs-semantic-color-text-secondary);--wcs-radio-text-font-weight-default:var(--wcs-semantic-font-weight-medium);--wcs-radio-text-color-selected:var(--wcs-semantic-color-text-primary);--wcs-radio-text-font-weight-selected:var(--wcs-semantic-font-weight-medium);--wcs-radio-text-color-disabled:var(--wcs-semantic-color-text-disabled);--wcs-radio-text-color-hover:var(--wcs-semantic-color-text-primary);--wcs-radio-checkmark-size:1rem;--wcs-radio-gap:var(--wcs-semantic-spacing-base);--wcs-radio-outline-color-focus:var(--wcs-semantic-color-border-focus-base);--wcs-radio-checkmark-border-width:var(--wcs-semantic-border-width-large);--wcs-radio-checkmark-border-color-default:var(--wcs-semantic-color-border-control-indicator-default);--wcs-radio-checkmark-border-color-selected:var(--wcs-semantic-color-border-control-indicator-selected);--wcs-radio-checkmark-border-color-hover:var(--wcs-semantic-color-border-control-indicator-hover);--wcs-radio-checkmark-border-color-disabled:var(--wcs-semantic-color-border-control-indicator-disabled);--wcs-radio-checkmark-background-color-default:transparent;--wcs-radio-checkmark-background-color-selected:var(--wcs-semantic-color-background-control-indicator-selected);--wcs-radio-checkmark-background-color-selected-disabled:var(--wcs-semantic-color-background-control-indicator-disabled);--wcs-radio-checkmark-background-color-selected-hover:var(--wcs-semantic-color-background-control-indicator-hover);--wcs-radio-checkmark-outline-distance-with-checkmark-circle:var(--wcs-semantic-spacing-small);--wcs-radio-checkmark-outline-width:var(--wcs-semantic-border-width-large);--wcs-radio-checkmark-outline-color:var(--wcs-semantic-color-foreground-control-indicator-selected);--wcs-radio-checkmark-border-radius:var(--wcs-semantic-border-radius-full);--wcs-radio-border-radius:var(--wcs-semantic-border-radius-base);--wcs-radio-option-background-color-default:var(--wcs-semantic-color-background-action-secondary-default);--wcs-radio-option-background-color-hover:var(--wcs-semantic-color-background-action-secondary-default);--wcs-radio-option-background-color-press:var(--wcs-semantic-color-background-action-secondary-default);--wcs-radio-option-background-color-disabled:var(--wcs-semantic-color-background-action-secondary-default);--wcs-radio-option-background-color-selected-default:var(--wcs-semantic-color-background-action-primary-default);--wcs-radio-option-background-color-selected-hover:var(--wcs-semantic-color-background-action-primary-hover);--wcs-radio-option-background-color-selected-press:var(--wcs-semantic-color-background-action-primary-press);--wcs-radio-option-background-color-selected-disabled:var(--wcs-semantic-color-background-action-primary-disabled);--wcs-radio-option-text-color-default:var(--wcs-semantic-color-foreground-action-secondary-default);--wcs-radio-option-text-color-hover:var(--wcs-semantic-color-foreground-action-secondary-default);--wcs-radio-option-text-color-press:var(--wcs-semantic-color-foreground-action-secondary-press);--wcs-radio-option-text-color-selected-default:var(--wcs-semantic-color-foreground-action-primary-default);--wcs-radio-option-text-color-selected-hover:var(--wcs-semantic-color-foreground-action-primary-hover);--wcs-radio-option-text-color-selected-press:var(--wcs-semantic-color-foreground-action-primary-press);--wcs-radio-option-text-color-disabled:var(--wcs-semantic-color-text-disabled);--wcs-radio-option-text-font-weight-default:var(--wcs-semantic-font-weight-roman);--wcs-radio-option-text-font-weight-selected:var(--wcs-semantic-font-weight-roman);--wcs-radio-option-border-radius:var(--wcs-semantic-border-radius-base);--wcs-radio-option-border-width:var(--wcs-semantic-border-width-default);--wcs-radio-option-border-color-hover:var(--wcs-semantic-color-border-action-secondary-hover);--wcs-radio-option-border-color-press:var(--wcs-semantic-color-border-action-secondary-press);--wcs-radio-option-padding-top:var(--wcs-semantic-spacing-base);--wcs-radio-option-padding-right:var(--wcs-semantic-spacing-large);--wcs-radio-option-padding-bottom:var(--wcs-semantic-spacing-base);--wcs-radio-option-padding-left:var(--wcs-semantic-spacing-large)}:host([mode=radio]) input,:host([mode=horizontal]) input{position:absolute;opacity:0;height:1px;width:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}:host([mode=radio]) label,:host([mode=horizontal]) label{margin-bottom:0;color:var(--wcs-radio-text-color-default);font-weight:var(--wcs-radio-text-font-weight-default) !important;display:inline-block}:host([mode=radio]) label:before,:host([mode=horizontal]) label:before{border-radius:var(--wcs-radio-checkmark-border-radius);border:var(--wcs-radio-checkmark-border-width) solid var(--wcs-radio-checkmark-border-color-default);position:relative;width:var(--wcs-radio-checkmark-size);height:var(--wcs-radio-checkmark-size);pointer-events:none;content:\"\";background-color:var(--wcs-radio-checkmark-background-color-default)}:host([mode=radio]) input:focus-visible+label,:host([mode=horizontal]) input:focus-visible+label{transition:none;outline:var(--wcs-semantic-border-width-large) dashed var(--wcs-radio-outline-color-focus);outline-offset:var(--wcs-semantic-spacing-small);border-radius:var(--wcs-radio-border-radius)}:host([disabled]) label{color:var(--wcs-radio-text-color-disabled);cursor:not-allowed}:host([disabled]) label:before{border-color:var(--wcs-radio-checkmark-border-color-disabled)}:host(:not([disabled])) label{cursor:pointer}:host([mode=radio].checked) label,:host([mode=horizontal].checked) label{color:var(--wcs-radio-text-color-selected);font-weight:var(--wcs-radio-text-font-weight-selected) !important}:host([mode=radio].checked) label:before,:host([mode=horizontal].checked) label:before{border-color:var(--wcs-radio-checkmark-border-color-selected);background-color:var(--wcs-radio-checkmark-background-color-selected);outline:solid var(--wcs-radio-checkmark-outline-width) var(--wcs-radio-checkmark-outline-color);outline-offset:calc(-1 * var(--wcs-radio-checkmark-outline-distance-with-checkmark-circle))}:host([mode=radio][disabled].checked) label,:host([mode=horizontal][disabled].checked) label{color:var(--wcs-radio-text-color-disabled)}:host([mode=radio][disabled].checked) label:before,:host([mode=horizontal][disabled].checked) label:before{border-color:var(--wcs-radio-checkmark-border-color-disabled);background-color:var(--wcs-radio-checkmark-background-color-selected-disabled)}:host([mode=radio]:hover:not([disabled])) label,:host([mode=horizontal]:hover:not([disabled])) label{color:var(--wcs-radio-text-color-hover)}:host([mode=radio]:hover:not([disabled])) label:before,:host([mode=horizontal]:hover:not([disabled])) label:before{border-color:var(--wcs-radio-checkmark-border-color-hover);background-color:var(--wcs-radio-checkmark-background-color-selected-hover)}:host([mode=radio]:hover:not([disabled]):not(.checked)) label:before,:host([mode=horizontal]:hover:not([disabled]):not(.checked)) label:before{background-color:var(--wcs-radio-checkmark-background-color-default)}:host([mode=radio]) label{border:none}:host([mode=radio]) label:before{transition:background-color var(--wcs-radio-transition-duration) ease-in-out;margin-right:var(--wcs-radio-gap);display:inline-block;top:3px;box-sizing:border-box}:host([mode=radio]) label:empty::before{margin-right:0}:host([mode=horizontal]){height:fit-content}:host([mode=horizontal]) label:before{transition:background-color var(--wcs-radio-transition-duration) ease-in-out;margin:auto auto var(--wcs-radio-gap);display:block}:host([mode=horizontal]) label:empty::before{margin-bottom:0}:host([mode=option]){font-weight:var(--wcs-radio-option-text-font-weight-default) !important}:host([mode=option]) input{position:absolute;z-index:-1;opacity:0;box-sizing:border-box;padding:0}:host([mode=option]) label{padding:var(--wcs-radio-option-padding-top) var(--wcs-radio-option-padding-right) var(--wcs-radio-option-padding-bottom) var(--wcs-radio-option-padding-left);margin-bottom:0;color:var(--wcs-radio-option-text-color-default);white-space:nowrap;border-radius:var(--wcs-radio-option-border-radius);transition:background-color var(--wcs-radio-transition-duration) ease-in-out;background-color:var(--wcs-radio-option-background-color-default)}:host([mode=option]) input:focus-visible+label{outline:var(--wcs-semantic-border-width-large) dashed var(--wcs-radio-outline-color-focus);outline-offset:0;border-radius:var(--wcs-radio-border-radius)}:host([mode=option][disabled]) label{color:var(--wcs-radio-option-text-color-disabled);background-color:var(--wcs-radio-option-background-color-disabled)}:host([mode=option][disabled].checked) label{color:var(--wcs-radio-option-text-color-disabled);background-color:var(--wcs-radio-option-background-color-selected-disabled)}:host([mode=option].checked) label{font-weight:var(--wcs-radio-option-text-font-weight-selected) !important;color:var(--wcs-radio-option-text-color-selected-default);background-color:var(--wcs-radio-option-background-color-selected-default)}:host([mode=option]:hover.checked:not([disabled])) label{color:var(--wcs-radio-option-text-color-selected-hover);background-color:var(--wcs-radio-option-background-color-selected-hover)}:host([mode=option]:active.checked:not([disabled])) label{color:var(--wcs-radio-option-text-color-selected-press);background-color:var(--wcs-radio-option-background-color-selected-press)}:host([mode=option]:hover:not(.checked):not([disabled])) label{color:var(--wcs-radio-option-text-color-hover);background-color:var(--wcs-radio-option-background-color-hover);outline:var(--wcs-radio-option-border-width) solid var(--wcs-radio-option-border-color-hover)}:host([mode=option]:active:not(.checked):not([disabled])) label{color:var(--wcs-radio-option-text-color-press);background-color:var(--wcs-radio-option-background-color-press);outline:var(--wcs-radio-option-border-width) solid var(--wcs-radio-option-border-color-press)}";
|
|
8
|
+
const radioCss = ":host{width:fit-content;--wcs-radio-transition-duration:var(--wcs-semantic-motion-duration-feedback-base);--wcs-radio-text-color-default:var(--wcs-semantic-color-text-secondary);--wcs-radio-text-font-weight-default:var(--wcs-semantic-font-weight-medium);--wcs-radio-text-color-selected:var(--wcs-semantic-color-text-primary);--wcs-radio-text-font-weight-selected:var(--wcs-semantic-font-weight-medium);--wcs-radio-text-color-disabled:var(--wcs-semantic-color-text-disabled);--wcs-radio-text-color-hover:var(--wcs-semantic-color-text-primary);--wcs-radio-checkmark-size:1rem;--wcs-radio-gap:var(--wcs-semantic-spacing-base);--wcs-radio-outline-color-focus:var(--wcs-semantic-color-border-focus-base);--wcs-radio-checkmark-border-width:var(--wcs-semantic-border-width-large);--wcs-radio-checkmark-border-color-default:var(--wcs-semantic-color-border-control-indicator-default);--wcs-radio-checkmark-border-color-selected:var(--wcs-semantic-color-border-control-indicator-selected);--wcs-radio-checkmark-border-color-hover:var(--wcs-semantic-color-border-control-indicator-hover);--wcs-radio-checkmark-border-color-disabled:var(--wcs-semantic-color-border-control-indicator-disabled);--wcs-radio-checkmark-background-color-default:transparent;--wcs-radio-checkmark-background-color-selected:var(--wcs-semantic-color-background-control-indicator-selected);--wcs-radio-checkmark-background-color-selected-disabled:var(--wcs-semantic-color-background-control-indicator-disabled);--wcs-radio-checkmark-background-color-selected-hover:var(--wcs-semantic-color-background-control-indicator-hover);--wcs-radio-checkmark-outline-distance-with-checkmark-circle:var(--wcs-semantic-spacing-small);--wcs-radio-checkmark-outline-width:var(--wcs-semantic-border-width-large);--wcs-radio-checkmark-outline-color:var(--wcs-semantic-color-foreground-control-indicator-selected);--wcs-radio-checkmark-border-radius:var(--wcs-semantic-border-radius-full);--wcs-radio-border-radius:var(--wcs-semantic-border-radius-base);--wcs-radio-option-background-color-default:var(--wcs-semantic-color-background-action-secondary-default);--wcs-radio-option-background-color-hover:var(--wcs-semantic-color-background-action-secondary-default);--wcs-radio-option-background-color-press:var(--wcs-semantic-color-background-action-secondary-default);--wcs-radio-option-background-color-disabled:var(--wcs-semantic-color-background-action-secondary-default);--wcs-radio-option-background-color-selected-default:var(--wcs-semantic-color-background-action-primary-default);--wcs-radio-option-background-color-selected-hover:var(--wcs-semantic-color-background-action-primary-hover);--wcs-radio-option-background-color-selected-press:var(--wcs-semantic-color-background-action-primary-press);--wcs-radio-option-background-color-selected-disabled:var(--wcs-semantic-color-background-action-primary-disabled);--wcs-radio-option-text-color-default:var(--wcs-semantic-color-foreground-action-secondary-default);--wcs-radio-option-text-color-hover:var(--wcs-semantic-color-foreground-action-secondary-default);--wcs-radio-option-text-color-press:var(--wcs-semantic-color-foreground-action-secondary-press);--wcs-radio-option-text-color-selected-default:var(--wcs-semantic-color-foreground-action-primary-default);--wcs-radio-option-text-color-selected-hover:var(--wcs-semantic-color-foreground-action-primary-hover);--wcs-radio-option-text-color-selected-press:var(--wcs-semantic-color-foreground-action-primary-press);--wcs-radio-option-text-color-disabled:var(--wcs-semantic-color-text-disabled);--wcs-radio-option-text-font-weight-default:var(--wcs-semantic-font-weight-roman);--wcs-radio-option-text-font-weight-selected:var(--wcs-semantic-font-weight-roman);--wcs-radio-option-border-radius:var(--wcs-semantic-border-radius-base);--wcs-radio-option-border-width:var(--wcs-semantic-border-width-default);--wcs-radio-option-border-color-hover:var(--wcs-semantic-color-border-action-secondary-hover);--wcs-radio-option-border-color-press:var(--wcs-semantic-color-border-action-secondary-press);--wcs-radio-option-padding-top:var(--wcs-semantic-spacing-base);--wcs-radio-option-padding-right:var(--wcs-semantic-spacing-large);--wcs-radio-option-padding-bottom:var(--wcs-semantic-spacing-base);--wcs-radio-option-padding-left:var(--wcs-semantic-spacing-large);position:relative}:host([mode=radio]) input,:host([mode=horizontal]) input{position:absolute;opacity:0;height:1px;width:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}:host([mode=radio]) .label,:host([mode=horizontal]) .label{margin-bottom:0;color:var(--wcs-radio-text-color-default);font-weight:var(--wcs-radio-text-font-weight-default) !important;display:inline-block}:host([mode=radio]) .label:before,:host([mode=horizontal]) .label:before{border-radius:var(--wcs-radio-checkmark-border-radius);border:var(--wcs-radio-checkmark-border-width) solid var(--wcs-radio-checkmark-border-color-default);position:relative;width:var(--wcs-radio-checkmark-size);height:var(--wcs-radio-checkmark-size);pointer-events:none;content:\"\";background-color:var(--wcs-radio-checkmark-background-color-default)}:host(:focus-visible){outline:none}:host(:focus-visible) .label{transition:none;outline:var(--wcs-semantic-border-width-large) dashed var(--wcs-radio-outline-color-focus);outline-offset:var(--wcs-semantic-spacing-small);border-radius:var(--wcs-radio-border-radius)}:host([disabled]) .label{color:var(--wcs-radio-text-color-disabled);cursor:not-allowed}:host([disabled]) .label:before{border-color:var(--wcs-radio-checkmark-border-color-disabled)}:host(:not([disabled])) .label{cursor:pointer}:host([mode=radio].checked) .label,:host([mode=horizontal].checked) .label{color:var(--wcs-radio-text-color-selected);font-weight:var(--wcs-radio-text-font-weight-selected) !important}:host([mode=radio].checked) .label:before,:host([mode=horizontal].checked) .label:before{border-color:var(--wcs-radio-checkmark-border-color-selected);background-color:var(--wcs-radio-checkmark-background-color-selected);outline:solid var(--wcs-radio-checkmark-outline-width) var(--wcs-radio-checkmark-outline-color);outline-offset:calc(-1 * var(--wcs-radio-checkmark-outline-distance-with-checkmark-circle))}:host([mode=radio][disabled].checked) .label,:host([mode=horizontal][disabled].checked) .label{color:var(--wcs-radio-text-color-disabled)}:host([mode=radio][disabled].checked) .label:before,:host([mode=horizontal][disabled].checked) .label:before{border-color:var(--wcs-radio-checkmark-border-color-disabled);background-color:var(--wcs-radio-checkmark-background-color-selected-disabled)}:host([mode=radio]:hover:not([disabled])) .label,:host([mode=horizontal]:hover:not([disabled])) .label{color:var(--wcs-radio-text-color-hover)}:host([mode=radio]:hover:not([disabled])) .label:before,:host([mode=horizontal]:hover:not([disabled])) .label:before{border-color:var(--wcs-radio-checkmark-border-color-hover);background-color:var(--wcs-radio-checkmark-background-color-selected-hover)}:host([mode=radio]:hover:not([disabled]):not(.checked)) .label:before,:host([mode=horizontal]:hover:not([disabled]):not(.checked)) .label:before{background-color:var(--wcs-radio-checkmark-background-color-default)}:host([mode=radio]) .label{border:none}:host([mode=radio]) .label:before{transition:background-color var(--wcs-radio-transition-duration) ease-in-out;margin-right:var(--wcs-radio-gap);display:inline-block;top:3px;box-sizing:border-box}:host([mode=radio]) .label:empty::before{margin-right:0}:host([mode=horizontal]){height:fit-content}:host([mode=horizontal]) .label:before{transition:background-color var(--wcs-radio-transition-duration) ease-in-out;margin:auto auto var(--wcs-radio-gap);display:block}:host([mode=horizontal]) .label:empty::before{margin-bottom:0}:host([mode=option]){font-weight:var(--wcs-radio-option-text-font-weight-default) !important}:host([mode=option]) input{position:absolute;z-index:-1;opacity:0;box-sizing:border-box;padding:0}:host([mode=option]) .label{padding:var(--wcs-radio-option-padding-top) var(--wcs-radio-option-padding-right) var(--wcs-radio-option-padding-bottom) var(--wcs-radio-option-padding-left);margin-bottom:0;color:var(--wcs-radio-option-text-color-default);white-space:nowrap;border-radius:var(--wcs-radio-option-border-radius);transition:background-color var(--wcs-radio-transition-duration) ease-in-out;background-color:var(--wcs-radio-option-background-color-default)}:host([mode=option]) input:focus-visible+.label{outline:var(--wcs-semantic-border-width-large) dashed var(--wcs-radio-outline-color-focus);outline-offset:0;border-radius:var(--wcs-radio-border-radius)}:host([mode=option][disabled]) .label{color:var(--wcs-radio-option-text-color-disabled);background-color:var(--wcs-radio-option-background-color-disabled)}:host([mode=option][disabled].checked) .label{color:var(--wcs-radio-option-text-color-disabled);background-color:var(--wcs-radio-option-background-color-selected-disabled)}:host([mode=option].checked) .label{font-weight:var(--wcs-radio-option-text-font-weight-selected) !important;color:var(--wcs-radio-option-text-color-selected-default);background-color:var(--wcs-radio-option-background-color-selected-default)}:host([mode=option]:hover.checked:not([disabled])) .label{color:var(--wcs-radio-option-text-color-selected-hover);background-color:var(--wcs-radio-option-background-color-selected-hover)}:host([mode=option]:active.checked:not([disabled])) .label{color:var(--wcs-radio-option-text-color-selected-press);background-color:var(--wcs-radio-option-background-color-selected-press)}:host([mode=option]:hover:not(.checked):not([disabled])) .label{color:var(--wcs-radio-option-text-color-hover);background-color:var(--wcs-radio-option-background-color-hover);outline:var(--wcs-radio-option-border-width) solid var(--wcs-radio-option-border-color-hover)}:host([mode=option]:active:not(.checked):not([disabled])) .label{color:var(--wcs-radio-option-text-color-press);background-color:var(--wcs-radio-option-background-color-press);outline:var(--wcs-radio-option-border-width) solid var(--wcs-radio-option-border-color-press)}";
|
|
9
9
|
const WcsRadioStyle0 = radioCss;
|
|
10
10
|
|
|
11
|
-
const RADIO_INHERITED_ATTRS = ['title'];
|
|
12
11
|
const Radio = class {
|
|
13
12
|
constructor(hostRef) {
|
|
14
13
|
index.registerInstance(this, hostRef);
|
|
15
14
|
this.wcsRadioClick = index.createEvent(this, "wcsRadioClick", 7);
|
|
16
15
|
this.wcsBlur = index.createEvent(this, "wcsBlur", 7);
|
|
17
16
|
this.wcsFocus = index.createEvent(this, "wcsFocus", 7);
|
|
18
|
-
this.
|
|
19
|
-
|
|
17
|
+
this.handleClick = () => {
|
|
18
|
+
this.selectRadio();
|
|
19
|
+
};
|
|
20
|
+
this.handleKeyDown = (event) => {
|
|
21
|
+
if (this.disabled)
|
|
22
|
+
return;
|
|
23
|
+
if (event.key === ' ' || event.key === 'Enter') {
|
|
24
|
+
event.preventDefault();
|
|
25
|
+
event.stopPropagation();
|
|
26
|
+
this.selectRadio();
|
|
27
|
+
}
|
|
28
|
+
};
|
|
20
29
|
this.checked = false;
|
|
21
30
|
this.radioTabIndex = -1;
|
|
22
31
|
this.value = undefined;
|
|
@@ -40,7 +49,7 @@ const Radio = class {
|
|
|
40
49
|
this.radioTabIndex = value;
|
|
41
50
|
}
|
|
42
51
|
async setAriaAttribute(attr, value) {
|
|
43
|
-
helpers.setOrRemoveAttribute(this.
|
|
52
|
+
helpers.setOrRemoveAttribute(this.el, attr, value);
|
|
44
53
|
}
|
|
45
54
|
onFocus(ev) {
|
|
46
55
|
this.wcsFocus.emit(ev);
|
|
@@ -56,18 +65,6 @@ const Radio = class {
|
|
|
56
65
|
// If no value was given we use the text content instead.
|
|
57
66
|
this.value = this.el.innerText || '';
|
|
58
67
|
}
|
|
59
|
-
this.inheritedAttributes = Object.assign(Object.assign({}, helpers.inheritAriaAttributes(this.el)), helpers.inheritAttributes(this.el, RADIO_INHERITED_ATTRS));
|
|
60
|
-
}
|
|
61
|
-
onChange(_) {
|
|
62
|
-
if (this.disabled)
|
|
63
|
-
return;
|
|
64
|
-
// If the radio is unchecked, then the change represents its transition to the check state.
|
|
65
|
-
// Only emit the change event when going from unchecked to checked, like the native behavior.
|
|
66
|
-
// https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/change_event
|
|
67
|
-
if (!this.checked) {
|
|
68
|
-
this.checked = true;
|
|
69
|
-
this.emitRadioChangeEvent();
|
|
70
|
-
}
|
|
71
68
|
}
|
|
72
69
|
emitRadioChangeEvent() {
|
|
73
70
|
this.wcsRadioClick.emit({
|
|
@@ -76,13 +73,20 @@ const Radio = class {
|
|
|
76
73
|
value: this.value
|
|
77
74
|
});
|
|
78
75
|
}
|
|
76
|
+
selectRadio() {
|
|
77
|
+
if (this.disabled || this.checked) {
|
|
78
|
+
return;
|
|
79
|
+
}
|
|
80
|
+
this.checked = true;
|
|
81
|
+
// Only emit the change event when going from unchecked to checked, like the native behavior.
|
|
82
|
+
// https://developer.mozilla.org/en-US/docs/Web/API/HTMLElement/change_event
|
|
83
|
+
this.emitRadioChangeEvent();
|
|
84
|
+
}
|
|
79
85
|
render() {
|
|
80
|
-
return (index.h(index.Host, { key: '
|
|
86
|
+
return (index.h(index.Host, { key: '0720e7983a66998bef080116aec041f3309d70dd', slot: "option", role: "radio", "aria-checked": this.checked ? 'true' : 'false', "aria-disabled": this.disabled ? 'true' : 'false', tabIndex: this.disabled ? -1 : this.radioTabIndex, class: this.checked ? 'checked' : '', onClick: this.handleClick.bind(this), onFocus: this.onFocus.bind(this), onBlur: this.onBlur.bind(this), onKeyDown: this.handleKeyDown.bind(this) }, index.h("span", { key: 'bb2fb56fa6c5354a54b4debba078b0c129534e74', class: "label" }, this.label)));
|
|
81
87
|
}
|
|
82
|
-
static get delegatesFocus() { return true; }
|
|
83
88
|
get el() { return index.getElement(this); }
|
|
84
89
|
};
|
|
85
|
-
let radioButtonIds = 0;
|
|
86
90
|
Radio.style = WcsRadioStyle0;
|
|
87
91
|
|
|
88
92
|
exports.wcs_radio = Radio;
|