wcs-core 7.5.1 → 7.7.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/index.js +1 -1
- package/bundle/p-035ad27f.js +2 -0
- package/bundle/{p-010cf905.js → p-16c7ed2e.js} +2 -2
- package/bundle/p-34ecd856.js +2 -0
- package/bundle/p-34ecd856.js.map +1 -0
- package/bundle/p-53550684.js +2 -0
- package/bundle/p-53550684.js.map +1 -0
- package/bundle/{p-97e70e10.js → p-5a997d17.js} +2 -2
- package/bundle/p-68ab4391.js +16 -0
- package/bundle/p-68ab4391.js.map +1 -0
- package/bundle/{p-60193ef5.js → p-791fce94.js} +2 -2
- package/bundle/{p-44a3b0b9.js → p-87b9556d.js} +2 -2
- package/bundle/{p-d23d7658.js → p-886109ed.js} +2 -2
- package/bundle/p-9138985e.js +2 -0
- package/bundle/p-9138985e.js.map +1 -0
- package/bundle/p-95eb2e54.js +2 -0
- package/bundle/p-95eb2e54.js.map +1 -0
- package/bundle/{p-2751ddc1.js → p-a9a83300.js} +2 -2
- package/bundle/{p-cdc6f6c2.js → p-c13e9bb6.js} +8 -8
- package/bundle/p-c13e9bb6.js.map +1 -0
- package/bundle/p-c70a403e.js +2 -0
- package/bundle/p-c70a403e.js.map +1 -0
- package/bundle/{p-c8b73e93.js → p-d7d1ea63.js} +2 -2
- package/bundle/p-f6d5c242.js +2 -0
- package/bundle/p-f6d5c242.js.map +1 -0
- package/bundle/wcs-accordion-panel.js +1 -1
- package/bundle/wcs-alert-drawer.js +1 -1
- package/bundle/wcs-alert-drawer.js.map +1 -1
- package/bundle/wcs-alert.js +1 -1
- package/bundle/wcs-app.js +1 -1
- package/bundle/wcs-badge.js +1 -1
- package/bundle/wcs-breadcrumb-item.js +1 -1
- package/bundle/wcs-breadcrumb.js +1 -1
- package/bundle/wcs-button.js +1 -1
- package/bundle/wcs-card-body.js +1 -1
- package/bundle/wcs-card-body.js.map +1 -1
- package/bundle/wcs-card-content.js +1 -1
- package/bundle/wcs-card-content.js.map +1 -1
- package/bundle/wcs-card-footer.js +1 -1
- package/bundle/wcs-card-header.js +1 -1
- package/bundle/wcs-card-media.js +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-chip.js +1 -1
- package/bundle/wcs-chip.js.map +1 -1
- package/bundle/wcs-com-nav-category.js +1 -1
- package/bundle/wcs-com-nav-item.js +1 -1
- package/bundle/wcs-com-nav-submenu.js +1 -1
- package/bundle/wcs-com-nav.js +1 -1
- package/bundle/wcs-com-nav.js.map +1 -1
- package/bundle/wcs-counter.js +1 -1
- package/bundle/wcs-divider.js +1 -1
- package/bundle/wcs-dropdown-divider.js +1 -1
- package/bundle/wcs-dropdown-header.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-error.js +1 -1
- package/bundle/wcs-field-content.js +1 -1
- package/bundle/wcs-field-content.js.map +1 -1
- package/bundle/wcs-field-label.js +1 -1
- package/bundle/wcs-field.js +1 -1
- package/bundle/wcs-field.js.map +1 -1
- package/bundle/wcs-footer.js +1 -1
- package/bundle/wcs-form-field.js +1 -1
- package/bundle/wcs-galactic-menu.js +1 -1
- package/bundle/wcs-galactic.js +1 -1
- package/bundle/wcs-grid-column.js +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-message.d.ts +11 -0
- package/bundle/wcs-message.js +2 -0
- package/bundle/wcs-message.js.map +1 -0
- 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-tab.js.map +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-a90bb01e.js → p-061ccda5.js} +2 -2
- package/composite-elements/{p-ef26b4d8.js → p-2181568b.js} +2 -2
- package/composite-elements/{p-b83afff9.js → p-61886571.js} +2 -2
- package/composite-elements/p-846e40e9.js +16 -0
- package/composite-elements/p-846e40e9.js.map +1 -0
- package/composite-elements/p-8a2107d4.js +2 -0
- package/composite-elements/p-8a2107d4.js.map +1 -0
- package/composite-elements/p-8cafb0b4.js +2 -0
- package/composite-elements/p-8cafb0b4.js.map +1 -0
- package/composite-elements/p-8f51f4cb.js +2 -0
- package/composite-elements/p-8f51f4cb.js.map +1 -0
- package/composite-elements/p-b53ae1a8.js +2 -0
- package/composite-elements/p-b53ae1a8.js.map +1 -0
- package/composite-elements/p-b6d0a6b4.js +2 -0
- package/composite-elements/p-cb9faa9b.js +2 -0
- package/composite-elements/{p-5a3d7fec.js → p-cd6cca64.js} +2 -2
- package/composite-elements/{p-04663560.js → p-d2d79425.js} +2 -2
- package/composite-elements/{p-b92e818b.js → p-f0b064a2.js} +2 -2
- package/composite-elements/{p-51517fda.js → p-f161f50b.js} +8 -8
- package/composite-elements/p-f161f50b.js.map +1 -0
- package/composite-elements/p-f6d5c242.js +2 -0
- package/composite-elements/p-f6d5c242.js.map +1 -0
- package/composite-elements/p-f85cc676.js +2 -0
- package/composite-elements/p-f85cc676.js.map +1 -0
- package/composite-elements/wcs-accordion-panel.js +1 -1
- package/composite-elements/wcs-alert-drawer.js +1 -1
- package/composite-elements/wcs-alert-drawer.js.map +1 -1
- package/composite-elements/wcs-alert.js +1 -1
- package/composite-elements/wcs-app.js +1 -1
- package/composite-elements/wcs-badge.js +1 -1
- package/composite-elements/wcs-breadcrumb-item.js +1 -1
- package/composite-elements/wcs-breadcrumb.js +1 -1
- package/composite-elements/wcs-button.js +1 -1
- package/composite-elements/wcs-card-body.js +1 -1
- package/composite-elements/wcs-card-body.js.map +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-footer.js +1 -1
- package/composite-elements/wcs-card-header.js +1 -1
- package/composite-elements/wcs-card-media.js +1 -1
- package/composite-elements/wcs-card.js +1 -1
- package/composite-elements/wcs-card.js.map +1 -1
- package/composite-elements/wcs-checkbox.js +1 -1
- package/composite-elements/wcs-chip.js +1 -1
- package/composite-elements/wcs-chip.js.map +1 -1
- package/composite-elements/wcs-com-nav-category.js +1 -1
- package/composite-elements/wcs-com-nav-item.js +1 -1
- package/composite-elements/wcs-com-nav-submenu.js +1 -1
- package/composite-elements/wcs-com-nav.js +1 -1
- package/composite-elements/wcs-com-nav.js.map +1 -1
- package/composite-elements/wcs-counter.js +1 -1
- package/composite-elements/wcs-divider.js +1 -1
- package/composite-elements/wcs-dropdown-divider.js +1 -1
- package/composite-elements/wcs-dropdown-header.js +1 -1
- package/composite-elements/wcs-dropdown-item.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-error.js +1 -1
- package/composite-elements/wcs-field-content.js +1 -1
- package/composite-elements/wcs-field-content.js.map +1 -1
- package/composite-elements/wcs-field-label.js +1 -1
- package/composite-elements/wcs-field.js +1 -1
- package/composite-elements/wcs-field.js.map +1 -1
- package/composite-elements/wcs-footer.js +1 -1
- package/composite-elements/wcs-form-field.js +1 -1
- package/composite-elements/wcs-galactic-menu.js +1 -1
- package/composite-elements/wcs-galactic.js +1 -1
- package/composite-elements/wcs-grid-column.js +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-message.d.ts +11 -0
- package/composite-elements/wcs-message.js +2 -0
- package/composite-elements/wcs-message.js.map +1 -0
- 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-tab.js.map +1 -1
- package/composite-elements/wcs-tabs.js +1 -1
- package/composite-elements/wcs-textarea.js +1 -1
- package/composite-elements/wcs-tooltip.js +2 -2
- package/dist/cjs/alert-close-button-4435ed57.js +10 -0
- package/dist/cjs/alert-close-button-4435ed57.js.map +1 -0
- package/dist/cjs/{com-nav-utils-ff4f0bef.js → com-nav-utils-e081e998.js} +2 -2
- package/dist/cjs/{com-nav-utils-ff4f0bef.js.map → com-nav-utils-e081e998.js.map} +1 -1
- package/dist/cjs/{grid-pagination-4505d7b6.js → grid-pagination-e92dca78.js} +4 -4
- package/dist/cjs/grid-pagination-e92dca78.js.map +1 -0
- package/dist/cjs/{helpers-2f1a8ddc.js → helpers-eaafd588.js} +1 -9
- package/dist/cjs/helpers-eaafd588.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/{keyboard-event-40ecdc27.js → keyboard-event-4890c60e.js} +2 -2
- package/dist/cjs/{keyboard-event-40ecdc27.js.map → keyboard-event-4890c60e.js.map} +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/wcs-accordion-panel.cjs.entry.js +1 -1
- package/dist/cjs/wcs-alert-drawer.cjs.entry.js +14 -2
- package/dist/cjs/wcs-alert-drawer.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-alert.cjs.entry.js +3 -2
- package/dist/cjs/wcs-alert.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-app.cjs.entry.js +3 -3
- package/dist/cjs/wcs-badge.cjs.entry.js +1 -1
- package/dist/cjs/wcs-breadcrumb-item.cjs.entry.js +1 -1
- package/dist/cjs/wcs-breadcrumb.cjs.entry.js +2 -2
- package/dist/cjs/{wcs-button_2.cjs.entry.js → wcs-button_3.cjs.entry.js} +40 -5
- package/dist/cjs/wcs-button_3.cjs.entry.js.map +1 -0
- package/dist/cjs/wcs-card-body.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-footer.cjs.entry.js +1 -1
- package/dist/cjs/wcs-card-header.cjs.entry.js +1 -1
- package/dist/cjs/wcs-card-media.cjs.entry.js +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-checkbox.cjs.entry.js +2 -2
- package/dist/cjs/wcs-chip.cjs.entry.js +18 -6
- package/dist/cjs/wcs-chip.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-com-nav-category.cjs.entry.js +4 -4
- package/dist/cjs/wcs-com-nav-item.cjs.entry.js +1 -1
- package/dist/cjs/wcs-com-nav-submenu.cjs.entry.js +4 -4
- package/dist/cjs/wcs-com-nav.cjs.entry.js +4 -4
- package/dist/cjs/wcs-counter.cjs.entry.js +2 -2
- package/dist/cjs/wcs-divider.cjs.entry.js +1 -1
- package/dist/cjs/wcs-dropdown-divider.cjs.entry.js +1 -1
- package/dist/cjs/wcs-dropdown-header.cjs.entry.js +1 -1
- package/dist/cjs/wcs-dropdown-item.cjs.entry.js +2 -2
- package/dist/cjs/wcs-dropdown.cjs.entry.js +4 -4
- package/dist/cjs/wcs-dropdown.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-editable-field.cjs.entry.js +35 -11
- package/dist/cjs/wcs-editable-field.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-error_3.cjs.entry.js +5 -5
- package/dist/cjs/wcs-error_3.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-field-content.cjs.entry.js +1 -1
- package/dist/cjs/wcs-field-label.cjs.entry.js +1 -1
- package/dist/cjs/wcs-field.cjs.entry.js +1 -1
- package/dist/cjs/wcs-footer.cjs.entry.js +1 -1
- package/dist/cjs/wcs-galactic-menu.cjs.entry.js +3 -3
- package/dist/cjs/wcs-galactic.cjs.entry.js +1 -1
- package/dist/cjs/wcs-grid-column.cjs.entry.js +2 -2
- package/dist/cjs/wcs-grid-custom-cell.cjs.entry.js +1 -1
- package/dist/cjs/wcs-grid-pagination.cjs.entry.js +2 -2
- package/dist/cjs/wcs-grid.cjs.entry.js +15 -8
- package/dist/cjs/wcs-grid.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-header.cjs.entry.js +2 -2
- package/dist/cjs/wcs-hint.cjs.entry.js +1 -1
- package/dist/cjs/wcs-horizontal-stepper.cjs.entry.js +1 -1
- package/dist/cjs/wcs-icon.cjs.entry.js +2 -2
- package/dist/cjs/wcs-input.cjs.entry.js +2 -7
- 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-message.cjs.entry.js +56 -0
- package/dist/cjs/wcs-message.cjs.entry.js.map +1 -0
- package/dist/cjs/wcs-modal.cjs.entry.js +2 -2
- package/dist/cjs/wcs-native-select.cjs.entry.js +1 -1
- package/dist/cjs/wcs-nav-item.cjs.entry.js +2 -2
- package/dist/cjs/wcs-nav.cjs.entry.js +2 -2
- package/dist/cjs/wcs-progress-bar.cjs.entry.js +3 -3
- package/dist/cjs/wcs-progress-radial.cjs.entry.js +3 -3
- package/dist/cjs/wcs-radio-group.cjs.entry.js +2 -2
- package/dist/cjs/wcs-radio.cjs.entry.js +25 -21
- package/dist/cjs/wcs-radio.cjs.entry.js.map +1 -1
- package/dist/cjs/wcs-select_2.cjs.entry.js +25 -23
- 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 +2 -2
- package/dist/cjs/wcs-tab.cjs.entry.js +1 -1
- package/dist/cjs/wcs-tabs.cjs.entry.js +2 -2
- package/dist/cjs/wcs-textarea.cjs.entry.js +2 -2
- package/dist/cjs/wcs-tooltip.cjs.entry.js +2 -2
- package/dist/cjs/wcs.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/alert/alert-close-button.js +3 -0
- package/dist/collection/components/alert/alert-close-button.js.map +1 -0
- package/dist/collection/components/alert/alert.css +12 -11
- package/dist/collection/components/alert/alert.js +2 -1
- package/dist/collection/components/alert/alert.js.map +1 -1
- package/dist/collection/components/alert-drawer/alert-drawer.js +34 -2
- package/dist/collection/components/alert-drawer/alert-drawer.js.map +1 -1
- package/dist/collection/components/app/app.js +3 -3
- package/dist/collection/components/badge/badge.js +1 -1
- package/dist/collection/components/breadcrumb/breadcrumb.js +1 -1
- package/dist/collection/components/breadcrumb-item/breadcrumb-item.js +1 -1
- package/dist/collection/components/button/button.css +26 -0
- package/dist/collection/components/button/button.js +47 -1
- package/dist/collection/components/button/button.js.map +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-body/card-body.js +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/card-footer/card-footer.js +1 -1
- package/dist/collection/components/card-header/card-header.js +1 -1
- package/dist/collection/components/card-media/card-media.js +1 -1
- package/dist/collection/components/checkbox/checkbox.js +1 -1
- package/dist/collection/components/chip/chip.e2e.playwright.js +33 -0
- package/dist/collection/components/chip/chip.e2e.playwright.js.map +1 -1
- package/dist/collection/components/chip/chip.js +19 -6
- package/dist/collection/components/chip/chip.js.map +1 -1
- package/dist/collection/components/com-nav/com-nav.js +2 -2
- package/dist/collection/components/com-nav-category/com-nav-category.js +2 -2
- package/dist/collection/components/com-nav-item/com-nav-item.js +1 -1
- package/dist/collection/components/com-nav-submenu/com-nav-submenu.js +2 -2
- package/dist/collection/components/counter/counter.js +1 -1
- package/dist/collection/components/divider/divider.js +1 -1
- package/dist/collection/components/dropdown/dropdown.css +9 -0
- package/dist/collection/components/dropdown/dropdown.e2e.playwright.js +76 -0
- package/dist/collection/components/dropdown/dropdown.e2e.playwright.js.map +1 -1
- package/dist/collection/components/dropdown/dropdown.js +1 -1
- package/dist/collection/components/dropdown-divider/dropdown-divider.js +1 -1
- package/dist/collection/components/dropdown-header/dropdown-header.js +1 -1
- package/dist/collection/components/dropdown-item/dropdown-item.js +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/error/error.js +1 -1
- package/dist/collection/components/field/field.js +1 -1
- package/dist/collection/components/field-content/field-content.js +1 -1
- package/dist/collection/components/field-label/field-label.js +1 -1
- package/dist/collection/components/footer/footer.js +1 -1
- package/dist/collection/components/form-field/form-field.js +1 -1
- package/dist/collection/components/galactic/galactic.js +1 -1
- package/dist/collection/components/galactic-menu/galactic-menu.js +2 -2
- package/dist/collection/components/grid/grid-radio.css +8 -0
- package/dist/collection/components/grid/grid.e2e.playwright.js +130 -0
- package/dist/collection/components/grid/grid.e2e.playwright.js.map +1 -1
- package/dist/collection/components/grid/grid.js +10 -3
- package/dist/collection/components/grid/grid.js.map +1 -1
- 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.css +4 -0
- 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 -8
- package/dist/collection/components/label/label.e2e.playwright.js +62 -0
- package/dist/collection/components/label/label.e2e.playwright.js.map +1 -1
- 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.css +8 -4
- package/dist/collection/components/mat-icon/mat-icon.js +6 -1
- package/dist/collection/components/mat-icon/mat-icon.js.map +1 -1
- package/dist/collection/components/message/message-interface.js +2 -0
- package/dist/collection/components/message/message-interface.js.map +1 -0
- package/dist/collection/components/message/message.css +101 -0
- package/dist/collection/components/message/message.js +206 -0
- package/dist/collection/components/message/message.js.map +1 -0
- 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 +167 -16
- package/dist/collection/components/select/select.e2e.playwright.js.map +1 -1
- package/dist/collection/components/select/select.js +21 -19
- 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/esm/alert-close-button-2ce5ac95.js +8 -0
- package/dist/esm/alert-close-button-2ce5ac95.js.map +1 -0
- package/dist/esm/{com-nav-utils-ee7bf77c.js → com-nav-utils-a5af32af.js} +2 -2
- package/dist/esm/{com-nav-utils-ee7bf77c.js.map → com-nav-utils-a5af32af.js.map} +1 -1
- package/dist/esm/{grid-pagination-731726a6.js → grid-pagination-c29173f6.js} +4 -4
- package/dist/esm/grid-pagination-c29173f6.js.map +1 -0
- package/dist/esm/{helpers-ece6a2d3.js → helpers-2d73ee7c.js} +2 -9
- package/dist/esm/helpers-2d73ee7c.js.map +1 -0
- 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-3a0579d5.js} +2 -2
- package/dist/esm/{keyboard-event-26b65ae5.js.map → keyboard-event-3a0579d5.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 +14 -2
- package/dist/esm/wcs-alert-drawer.entry.js.map +1 -1
- package/dist/esm/wcs-alert.entry.js +3 -2
- package/dist/esm/wcs-alert.entry.js.map +1 -1
- package/dist/esm/wcs-app.entry.js +3 -3
- package/dist/esm/wcs-badge.entry.js +1 -1
- package/dist/esm/wcs-breadcrumb-item.entry.js +1 -1
- package/dist/esm/wcs-breadcrumb.entry.js +2 -2
- package/dist/esm/{wcs-button_2.entry.js → wcs-button_3.entry.js} +41 -7
- package/dist/esm/{wcs-button_2.entry.js.map → wcs-button_3.entry.js.map} +1 -1
- package/dist/esm/wcs-card-body.entry.js +1 -1
- 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-footer.entry.js +1 -1
- package/dist/esm/wcs-card-header.entry.js +1 -1
- package/dist/esm/wcs-card-media.entry.js +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 +2 -2
- package/dist/esm/wcs-chip.entry.js +18 -6
- package/dist/esm/wcs-chip.entry.js.map +1 -1
- package/dist/esm/wcs-com-nav-category.entry.js +4 -4
- package/dist/esm/wcs-com-nav-item.entry.js +1 -1
- package/dist/esm/wcs-com-nav-submenu.entry.js +4 -4
- package/dist/esm/wcs-com-nav.entry.js +4 -4
- package/dist/esm/wcs-counter.entry.js +2 -2
- package/dist/esm/wcs-divider.entry.js +1 -1
- package/dist/esm/wcs-dropdown-divider.entry.js +1 -1
- package/dist/esm/wcs-dropdown-header.entry.js +1 -1
- package/dist/esm/wcs-dropdown-item.entry.js +2 -2
- package/dist/esm/wcs-dropdown.entry.js +4 -4
- 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 +5 -5
- package/dist/esm/wcs-error_3.entry.js.map +1 -1
- package/dist/esm/wcs-field-content.entry.js +1 -1
- package/dist/esm/wcs-field-label.entry.js +1 -1
- package/dist/esm/wcs-field.entry.js +1 -1
- package/dist/esm/wcs-footer.entry.js +1 -1
- package/dist/esm/wcs-galactic-menu.entry.js +3 -3
- package/dist/esm/wcs-galactic.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 +15 -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-message.entry.js +52 -0
- package/dist/esm/wcs-message.entry.js.map +1 -0
- 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 +25 -23
- 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/alert/alert-close-button.d.ts +4 -0
- package/dist/types/components/alert-drawer/alert-drawer.d.ts +10 -0
- package/dist/types/components/button/button.d.ts +18 -0
- 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/chip/chip.d.ts +1 -1
- 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/mat-icon/mat-icon.d.ts +5 -0
- package/dist/types/components/message/message-interface.d.ts +1 -0
- package/dist/types/components/message/message.d.ts +77 -0
- package/dist/types/components/radio/radio.d.ts +4 -5
- package/dist/types/components/select/select-interface.d.ts +5 -0
- package/dist/types/components/select/select.d.ts +0 -2
- package/dist/types/components.d.ts +316 -21
- package/dist/wcs/{p-41b946b2.entry.js → p-03ae13ec.entry.js} +2 -2
- package/dist/wcs/p-07c961b4.entry.js +2 -0
- package/dist/wcs/p-07c961b4.entry.js.map +1 -0
- package/dist/wcs/{p-dfb52a1c.entry.js → p-0a0bc006.entry.js} +2 -2
- package/dist/wcs/p-0a0bc006.entry.js.map +1 -0
- package/dist/wcs/{p-abd8d5a0.entry.js → p-167108aa.entry.js} +2 -2
- package/dist/wcs/{p-5e8fff73.entry.js → p-17c8f012.entry.js} +2 -2
- package/dist/wcs/{p-db7ba599.entry.js → p-190a8883.entry.js} +3 -3
- package/dist/wcs/{p-0758d22e.entry.js → p-276070f3.entry.js} +2 -2
- package/dist/wcs/{p-f929b66f.entry.js → p-28941abc.entry.js} +2 -2
- package/dist/wcs/p-28b3e55a.entry.js +2 -0
- package/dist/wcs/p-28b3e55a.entry.js.map +1 -0
- package/dist/wcs/{p-c261eaf9.entry.js → p-28d52607.entry.js} +2 -2
- package/dist/wcs/p-2d4fd96a.entry.js +2 -0
- package/dist/wcs/{p-18fa39f4.entry.js → p-2d5becbf.entry.js} +2 -2
- package/dist/wcs/p-2da579f2.entry.js +2 -0
- package/dist/wcs/{p-53a395a9.entry.js → p-2e0238b6.entry.js} +2 -2
- package/dist/wcs/{p-1e7ea63c.entry.js → p-358a505f.entry.js} +2 -2
- package/dist/wcs/{p-dff8641e.entry.js → p-38d37878.entry.js} +2 -2
- package/dist/wcs/{p-4ae08567.entry.js → p-3bc23ef1.entry.js} +2 -2
- package/dist/wcs/p-3da303d7.entry.js +16 -0
- package/dist/wcs/p-3da303d7.entry.js.map +1 -0
- package/dist/wcs/{p-9fd3366c.entry.js → p-407d9700.entry.js} +2 -2
- package/dist/wcs/{p-c84ae00d.entry.js → p-41383e84.entry.js} +2 -2
- package/dist/wcs/{p-27b438c0.entry.js → p-4506e5e4.entry.js} +2 -2
- package/dist/wcs/{p-5202b323.entry.js → p-48541bf7.entry.js} +2 -2
- package/dist/wcs/{p-8332a7e3.entry.js → p-4a28d7a3.entry.js} +2 -2
- package/dist/wcs/p-4c43d8fc.entry.js +2 -0
- package/dist/wcs/p-4c43d8fc.entry.js.map +1 -0
- package/dist/wcs/{p-0424e545.entry.js → p-4d7bc716.entry.js} +2 -2
- package/dist/wcs/{p-f2f7595e.entry.js → p-4ef24e07.entry.js} +2 -2
- package/dist/wcs/{p-f2f7595e.entry.js.map → p-4ef24e07.entry.js.map} +1 -1
- package/dist/wcs/{p-367946fe.entry.js → p-4f20cdba.entry.js} +2 -2
- package/dist/wcs/{p-1ba616c2.entry.js → p-4fad6675.entry.js} +2 -2
- package/dist/wcs/p-51c93d07.entry.js +2 -0
- package/dist/wcs/p-51c93d07.entry.js.map +1 -0
- package/dist/wcs/{p-cbda74f6.entry.js → p-575881cd.entry.js} +2 -2
- package/dist/wcs/p-5823cd22.entry.js +2 -0
- package/dist/wcs/p-5a276237.entry.js +2 -0
- package/dist/wcs/{p-fdeae83e.entry.js → p-5b61a775.entry.js} +2 -2
- package/dist/wcs/p-5bc7a732.js +2 -0
- package/dist/wcs/p-5bc7a732.js.map +1 -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-6033c91b.entry.js +2 -0
- package/dist/wcs/p-609115fc.js +2 -0
- package/dist/wcs/p-609115fc.js.map +1 -0
- package/dist/wcs/{p-aadf37e7.entry.js → p-6b5db6be.entry.js} +2 -2
- package/dist/wcs/{p-a0f6ef30.entry.js → p-6b86d4fa.entry.js} +2 -2
- package/dist/wcs/p-6b86d4fa.entry.js.map +1 -0
- package/dist/wcs/p-6c6841ac.entry.js +2 -0
- package/dist/wcs/p-6c78d16e.js +2 -0
- package/dist/wcs/p-714c3cd7.entry.js +2 -0
- package/dist/wcs/p-714c3cd7.entry.js.map +1 -0
- package/dist/wcs/p-71af107c.js +2 -0
- package/dist/wcs/p-71af107c.js.map +1 -0
- package/dist/wcs/{p-ad286030.entry.js → p-7b67cec9.entry.js} +2 -2
- package/dist/wcs/{p-781a956e.entry.js → p-7cd88886.entry.js} +2 -2
- package/dist/wcs/{p-850fa9c9.entry.js → p-7f5eea6a.entry.js} +2 -2
- package/dist/wcs/{p-e56b9ce2.entry.js → p-882886ae.entry.js} +2 -2
- package/dist/wcs/p-8fd515a3.entry.js +2 -0
- package/dist/wcs/{p-352e1f99.entry.js → p-95f35254.entry.js} +2 -2
- package/dist/wcs/{p-b0a6eec6.entry.js → p-9d47a628.entry.js} +2 -2
- package/dist/wcs/p-9d683786.entry.js +2 -0
- package/dist/wcs/{p-22620c69.entry.js → p-a45a1f25.entry.js} +2 -2
- package/dist/wcs/p-a45a1f25.entry.js.map +1 -0
- package/dist/wcs/{p-0326f834.entry.js → p-a9fa5726.entry.js} +2 -2
- package/dist/wcs/p-ae305b09.entry.js +2 -0
- package/dist/wcs/p-ae305b09.entry.js.map +1 -0
- package/dist/wcs/p-afd3e923.entry.js +2 -0
- package/dist/wcs/{p-990698a7.entry.js → p-b1b0e2cb.entry.js} +2 -2
- package/dist/wcs/p-b1b0e2cb.entry.js.map +1 -0
- package/dist/wcs/{p-3a18535f.entry.js → p-b9744cf7.entry.js} +2 -2
- package/dist/wcs/p-b99daad4.entry.js +156 -0
- package/dist/wcs/p-b99daad4.entry.js.map +1 -0
- package/dist/wcs/{p-cbbca016.entry.js → p-cefd8219.entry.js} +2 -2
- package/dist/wcs/{p-9c73744c.entry.js → p-d18051b2.entry.js} +2 -2
- package/dist/wcs/{p-637ec45a.entry.js → p-d42f5883.entry.js} +2 -2
- package/dist/wcs/p-d42f5883.entry.js.map +1 -0
- package/dist/wcs/p-d6d273d2.js +2 -0
- package/dist/wcs/{p-2329af04.entry.js → p-e08febb4.entry.js} +2 -2
- package/dist/wcs/{p-bc009574.entry.js → p-e91d33e0.entry.js} +2 -2
- package/dist/wcs/p-f37d7b07.entry.js +2 -0
- package/dist/wcs/{p-fbd68522.entry.js → p-f7897fd4.entry.js} +2 -2
- package/dist/wcs/{p-c6f8c45c.entry.js → p-fcc43c82.entry.js} +2 -2
- package/dist/wcs/{p-ed3b0709.entry.js → p-fd18dce6.entry.js} +2 -2
- package/dist/wcs/p-fed6a8cd.entry.js +2 -0
- package/dist/wcs/{p-cad10435.entry.js.map → p-fed6a8cd.entry.js.map} +1 -1
- package/dist/wcs/{p-4e2d6227.entry.js → p-ff20d08b.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-2e9b9605.js +0 -2
- package/bundle/p-2e9b9605.js.map +0 -1
- package/bundle/p-30d83d3d.js +0 -2
- package/bundle/p-30d83d3d.js.map +0 -1
- package/bundle/p-581fc0fc.js +0 -2
- package/bundle/p-581fc0fc.js.map +0 -1
- package/bundle/p-763371a0.js +0 -16
- package/bundle/p-763371a0.js.map +0 -1
- package/bundle/p-98bd8a96.js +0 -2
- package/bundle/p-98bd8a96.js.map +0 -1
- package/bundle/p-9c2aa87a.js +0 -2
- package/bundle/p-9c2aa87a.js.map +0 -1
- package/bundle/p-cdc6f6c2.js.map +0 -1
- package/bundle/p-f0dda0b8.js +0 -2
- package/composite-elements/p-2454bcae.js +0 -2
- package/composite-elements/p-2a51c239.js +0 -2
- package/composite-elements/p-2a51c239.js.map +0 -1
- package/composite-elements/p-46f752d5.js +0 -2
- package/composite-elements/p-51517fda.js.map +0 -1
- package/composite-elements/p-55668982.js +0 -2
- package/composite-elements/p-55668982.js.map +0 -1
- package/composite-elements/p-79ad61e4.js +0 -2
- package/composite-elements/p-79ad61e4.js.map +0 -1
- package/composite-elements/p-af24fb0d.js +0 -16
- 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/composite-elements/p-e803bb26.js +0 -2
- package/composite-elements/p-e803bb26.js.map +0 -1
- package/dist/cjs/grid-pagination-4505d7b6.js.map +0 -1
- package/dist/cjs/helpers-2f1a8ddc.js.map +0 -1
- package/dist/cjs/wcs-button_2.cjs.entry.js.map +0 -1
- package/dist/cjs/wcs-mat-icon.cjs.entry.js +0 -42
- package/dist/cjs/wcs-mat-icon.cjs.entry.js.map +0 -1
- package/dist/esm/grid-pagination-731726a6.js.map +0 -1
- package/dist/esm/helpers-ece6a2d3.js.map +0 -1
- package/dist/esm/wcs-mat-icon.entry.js +0 -38
- package/dist/esm/wcs-mat-icon.entry.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 +0 -16
- package/dist/wcs/p-2221bf0c.entry.js.map +0 -1
- package/dist/wcs/p-22620c69.entry.js.map +0 -1
- package/dist/wcs/p-3823f54e.entry.js +0 -2
- package/dist/wcs/p-450942b1.entry.js +0 -156
- package/dist/wcs/p-450942b1.entry.js.map +0 -1
- package/dist/wcs/p-52d77e1f.js +0 -2
- package/dist/wcs/p-52d77e1f.js.map +0 -1
- package/dist/wcs/p-5607246c.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-6aededc6.entry.js +0 -2
- package/dist/wcs/p-7de847e0.entry.js +0 -2
- package/dist/wcs/p-8152d360.entry.js +0 -2
- package/dist/wcs/p-8152d360.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-990698a7.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-b28b2fba.entry.js +0 -2
- package/dist/wcs/p-b28b2fba.entry.js.map +0 -1
- package/dist/wcs/p-c211a5d1.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-c7812760.entry.js +0 -2
- package/dist/wcs/p-cad10435.entry.js +0 -2
- package/dist/wcs/p-dfb52a1c.entry.js.map +0 -1
- package/dist/wcs/p-e26c19e5.entry.js +0 -2
- package/dist/wcs/p-fe303f58.entry.js +0 -2
- package/dist/wcs/p-fe303f58.entry.js.map +0 -1
- /package/bundle/{p-f0dda0b8.js.map → p-035ad27f.js.map} +0 -0
- /package/bundle/{p-010cf905.js.map → p-16c7ed2e.js.map} +0 -0
- /package/bundle/{p-97e70e10.js.map → p-5a997d17.js.map} +0 -0
- /package/bundle/{p-60193ef5.js.map → p-791fce94.js.map} +0 -0
- /package/bundle/{p-44a3b0b9.js.map → p-87b9556d.js.map} +0 -0
- /package/bundle/{p-d23d7658.js.map → p-886109ed.js.map} +0 -0
- /package/bundle/{p-2751ddc1.js.map → p-a9a83300.js.map} +0 -0
- /package/bundle/{p-c8b73e93.js.map → p-d7d1ea63.js.map} +0 -0
- /package/composite-elements/{p-a90bb01e.js.map → p-061ccda5.js.map} +0 -0
- /package/composite-elements/{p-ef26b4d8.js.map → p-2181568b.js.map} +0 -0
- /package/composite-elements/{p-b83afff9.js.map → p-61886571.js.map} +0 -0
- /package/composite-elements/{p-2454bcae.js.map → p-b6d0a6b4.js.map} +0 -0
- /package/composite-elements/{p-46f752d5.js.map → p-cb9faa9b.js.map} +0 -0
- /package/composite-elements/{p-5a3d7fec.js.map → p-cd6cca64.js.map} +0 -0
- /package/composite-elements/{p-04663560.js.map → p-d2d79425.js.map} +0 -0
- /package/composite-elements/{p-b92e818b.js.map → p-f0b064a2.js.map} +0 -0
- /package/dist/wcs/{p-41b946b2.entry.js.map → p-03ae13ec.entry.js.map} +0 -0
- /package/dist/wcs/{p-abd8d5a0.entry.js.map → p-167108aa.entry.js.map} +0 -0
- /package/dist/wcs/{p-5e8fff73.entry.js.map → p-17c8f012.entry.js.map} +0 -0
- /package/dist/wcs/{p-db7ba599.entry.js.map → p-190a8883.entry.js.map} +0 -0
- /package/dist/wcs/{p-0758d22e.entry.js.map → p-276070f3.entry.js.map} +0 -0
- /package/dist/wcs/{p-f929b66f.entry.js.map → p-28941abc.entry.js.map} +0 -0
- /package/dist/wcs/{p-c261eaf9.entry.js.map → p-28d52607.entry.js.map} +0 -0
- /package/dist/wcs/{p-c211a5d1.entry.js.map → p-2d4fd96a.entry.js.map} +0 -0
- /package/dist/wcs/{p-18fa39f4.entry.js.map → p-2d5becbf.entry.js.map} +0 -0
- /package/dist/wcs/{p-7de847e0.entry.js.map → p-2da579f2.entry.js.map} +0 -0
- /package/dist/wcs/{p-53a395a9.entry.js.map → p-2e0238b6.entry.js.map} +0 -0
- /package/dist/wcs/{p-1e7ea63c.entry.js.map → p-358a505f.entry.js.map} +0 -0
- /package/dist/wcs/{p-dff8641e.entry.js.map → p-38d37878.entry.js.map} +0 -0
- /package/dist/wcs/{p-4ae08567.entry.js.map → p-3bc23ef1.entry.js.map} +0 -0
- /package/dist/wcs/{p-9fd3366c.entry.js.map → p-407d9700.entry.js.map} +0 -0
- /package/dist/wcs/{p-c84ae00d.entry.js.map → p-41383e84.entry.js.map} +0 -0
- /package/dist/wcs/{p-27b438c0.entry.js.map → p-4506e5e4.entry.js.map} +0 -0
- /package/dist/wcs/{p-5202b323.entry.js.map → p-48541bf7.entry.js.map} +0 -0
- /package/dist/wcs/{p-8332a7e3.entry.js.map → p-4a28d7a3.entry.js.map} +0 -0
- /package/dist/wcs/{p-0424e545.entry.js.map → p-4d7bc716.entry.js.map} +0 -0
- /package/dist/wcs/{p-367946fe.entry.js.map → p-4f20cdba.entry.js.map} +0 -0
- /package/dist/wcs/{p-1ba616c2.entry.js.map → p-4fad6675.entry.js.map} +0 -0
- /package/dist/wcs/{p-cbda74f6.entry.js.map → p-575881cd.entry.js.map} +0 -0
- /package/dist/wcs/{p-0b8157e7.entry.js.map → p-5823cd22.entry.js.map} +0 -0
- /package/dist/wcs/{p-580b3142.entry.js.map → p-5a276237.entry.js.map} +0 -0
- /package/dist/wcs/{p-fdeae83e.entry.js.map → p-5b61a775.entry.js.map} +0 -0
- /package/dist/wcs/{p-e26c19e5.entry.js.map → p-6033c91b.entry.js.map} +0 -0
- /package/dist/wcs/{p-aadf37e7.entry.js.map → p-6b5db6be.entry.js.map} +0 -0
- /package/dist/wcs/{p-6aededc6.entry.js.map → p-6c6841ac.entry.js.map} +0 -0
- /package/dist/wcs/{p-0017d766.js.map → p-6c78d16e.js.map} +0 -0
- /package/dist/wcs/{p-ad286030.entry.js.map → p-7b67cec9.entry.js.map} +0 -0
- /package/dist/wcs/{p-781a956e.entry.js.map → p-7cd88886.entry.js.map} +0 -0
- /package/dist/wcs/{p-850fa9c9.entry.js.map → p-7f5eea6a.entry.js.map} +0 -0
- /package/dist/wcs/{p-e56b9ce2.entry.js.map → p-882886ae.entry.js.map} +0 -0
- /package/dist/wcs/{p-5607246c.entry.js.map → p-8fd515a3.entry.js.map} +0 -0
- /package/dist/wcs/{p-352e1f99.entry.js.map → p-95f35254.entry.js.map} +0 -0
- /package/dist/wcs/{p-b0a6eec6.entry.js.map → p-9d47a628.entry.js.map} +0 -0
- /package/dist/wcs/{p-3823f54e.entry.js.map → p-9d683786.entry.js.map} +0 -0
- /package/dist/wcs/{p-0326f834.entry.js.map → p-a9fa5726.entry.js.map} +0 -0
- /package/dist/wcs/{p-ad5192cd.entry.js.map → p-afd3e923.entry.js.map} +0 -0
- /package/dist/wcs/{p-3a18535f.entry.js.map → p-b9744cf7.entry.js.map} +0 -0
- /package/dist/wcs/{p-cbbca016.entry.js.map → p-cefd8219.entry.js.map} +0 -0
- /package/dist/wcs/{p-9c73744c.entry.js.map → p-d18051b2.entry.js.map} +0 -0
- /package/dist/wcs/{p-89b8c724.js.map → p-d6d273d2.js.map} +0 -0
- /package/dist/wcs/{p-2329af04.entry.js.map → p-e08febb4.entry.js.map} +0 -0
- /package/dist/wcs/{p-bc009574.entry.js.map → p-e91d33e0.entry.js.map} +0 -0
- /package/dist/wcs/{p-c7812760.entry.js.map → p-f37d7b07.entry.js.map} +0 -0
- /package/dist/wcs/{p-fbd68522.entry.js.map → p-f7897fd4.entry.js.map} +0 -0
- /package/dist/wcs/{p-c6f8c45c.entry.js.map → p-fcc43c82.entry.js.map} +0 -0
- /package/dist/wcs/{p-ed3b0709.entry.js.map → p-fd18dce6.entry.js.map} +0 -0
- /package/dist/wcs/{p-4e2d6227.entry.js.map → p-ff20d08b.entry.js.map} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"grid.js","sourceRoot":"","sources":["../../../src/components/grid/grid.tsx"],"names":[],"mappings":"AAAA,OAAO,EACH,SAAS,EAGT,OAAO,EACP,KAAK,EAEL,WAAW,EACX,CAAC,EACD,IAAI,EACJ,MAAM,EAAE,MAAM,EACd,IAAI,EACJ,KAAK,EAEL,KAAK,EACR,MAAM,eAAe,CAAC;AACvB,OAAO,EACH,mBAAmB,GAUtB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAE,EAAE,IAAI,IAAI,EAAE,MAAM,MAAM,CAAC;AAClC,OAAO,EAAE,SAAS,EAAE,GAAG,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpD,OAAO,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AACpE,OAAO,EAAE,yBAAyB,EAAiC,MAAM,uBAAuB,CAAC;AACjG,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEzC,OAAO,EAAE,qBAAqB,EAAE,iBAAiB,EAAE,oBAAoB,EAAE,MAAM,qBAAqB,CAAC;AAQrG,MAAM,oBAAoB,GAAG,CAAC,OAAO,CAAC,CAAC;AAEvC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AAMH,MAAM,OAAO,IAAI;;QAGL,wBAAmB,GAAyB,EAAE,CAAC;0BAKR,KAAK;;;+BAeF,MAAM;6BAInB,EAAE;;;6BAcA,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI;;;oBAMZ,EAAE;8BA0BsB,EAAC,GAAG,EAAE,CAAC,EAAE,GAAG,EAAE,CAAC,EAAC;;IAG9E,sBAAsB,CAAC,QAAoC;QACvD,8DAA8D;QAC9D,IAAI,CAAC,0BAA0B,EAAE,CAAC,OAAO,CAAC,CAAC,CAA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,sBAAsB,EAAE,CAAC,CAAC,CAAC,oBAAoB,CAAC,CAAC,CAAC,IAAI,EAC1E,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC,IAAI,GAAG,SAAS,IAAG,IAAI,CAAC,cAAc,CAAC,GAAG,EAAE,IAAI,CAAC,CAAM,CAAC,CAAA;YACzF,CAAC,CACJ,CACA,CAAC;IACV,CAAC;IAEO,2BAA2B,CAAC,GAAe;QAC/C,MAAM,KAAK,GAAG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC;QACtC,OAAO,CAAA,KAAK,aAAL,KAAK,uBAAL,KAAK,CAAE,MAAM,MAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,KAAK,CAAC;IAC9C,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACJ;AAED;;;;GAIG","sourcesContent":["import {\n Component,\n ComponentDidLoad,\n ComponentInterface,\n Element,\n Event,\n EventEmitter,\n forceUpdate,\n h,\n Host,\n Listen, Method,\n Prop,\n State,\n VNode,\n Watch\n} from '@stencil/core';\nimport {\n getSortOrderInteger,\n HyperFunc, RowCssPartsFn,\n WcsGridAllRowSelectedEventDetails,\n WcsGridCell,\n WcsGridColumnSortChangeEventDetails,\n WcsGridPaginationChangeEventDetails,\n WcsGridRow,\n WcsGridRowData,\n WcsGridSelectionConfig,\n WcsGridSelectionEventDetails,\n} from './grid-interface';\nimport { v4 as uuid } from 'uuid';\nimport { cloneDeep, get, isEqual } from 'lodash-es';\nimport { GridPagination } from '../grid-pagination/grid-pagination';\nimport { getActionForKeyboardEvent, KeyboardEventAssociatedAction } from \"./grid-keyboard-event\";\nimport { GridRadio } from \"./grid-radio\";\nimport { AriaAttributeName, MutableAriaAttribute } from \"../../utils/mutable-aria-attribute\";\nimport { inheritAriaAttributes, inheritAttributes, setOrRemoveAttribute } from \"../../utils/helpers\";\n\ninterface GridElementWithCoordinates {\n el: HTMLTableCellElement,\n row: number,\n col: number,\n}\n\nconst GRID_INHERITED_ATTRS = ['title'];\n\n/**\n * The grid component is a complex component used as an HTML table to display collections of data.\n *\n * @cssprop --wcs-grid-gap - Gap between grid cells (horizontal, vertical using `border-spacing` property)\n * @cssprop --wcs-grid-vertical-align - Vertical alignment of grid cells\n * @cssprop --wcs-grid-outline-color - Outline color for grid cells\n *\n * @cssprop --wcs-grid-cell-text-color - Text color of all grid cells\n * @cssprop --wcs-grid-cell-padding-horizontal - Horizontal padding of grid cells\n * @cssprop --wcs-grid-cell-padding-vertical - Vertical padding of grid cells\n * @cssprop --wcs-grid-cell-border-bottom - Bottom border of grid cells\n * @cssprop --wcs-grid-cell-separator-border - Separator border between grid cells\n * @cssprop --wcs-grid-first-cell-border-radius - Border radius of the first cell in a row\n * @cssprop --wcs-grid-last-cell-border-radius - Border radius of the last cell in a row\n *\n * @cssprop --wcs-grid-highlight-color - Background color for selected rows\n * @cssprop --wcs-grid-row-background-color - Background color of all rows\n * @cssprop --wcs-grid-row-odd-background-color - Background color of odd rows\n * @cssprop --wcs-grid-row-even-background-color - Background color of even rows\n *\n * @cssprop --wcs-grid-header-background-color-default - Default background color of the header\n * @cssprop --wcs-grid-header-background-color-hover - Background color of the header on hover\n * @cssprop --wcs-grid-header-background-color-press - Background color of the header on press\n * @cssprop --wcs-grid-header-text-color - Text color of the header\n * @cssprop --wcs-grid-header-font-weight - Font weight of the header\n * @cssprop --wcs-grid-header-font-size - Font size of the header\n * @cssprop --wcs-grid-header-line-height - Line height of the header\n * @cssprop --wcs-grid-header-padding-vertical - Vertical padding of the header\n * @cssprop --wcs-grid-header-padding-horizontal - Horizontal padding of the header\n * @cssprop --wcs-grid-header-border-left - Left border between header cells (default is none\n * @cssprop --wcs-grid-header-border-radius - Border radius of the header\n * @cssprop --wcs-grid-header-border-bottom - Bottom border of the header\n * @cssprop --wcs-grid-header-transition-duration - Transition duration of the header\n * @cssprop --wcs-grid-first-header-background-color - Background color of the first header cell\n * @cssprop --wcs-grid-first-header-border-radius - Border radius of the first header cell\n * @cssprop --wcs-grid-last-header-border-radius - Border radius of the last header cell\n * @cssprop --wcs-grid-column-selection-width - Width of the selection column (when selectionConfig is defined)\n * @cssprop --wcs-grid-header-sort-arrow-color-default - Color of the sort arrow in the header\n * @cssprop --wcs-grid-header-sort-arrow-color-hover - Color of the sort arrow in the header when hovered\n * \n * @csspart all-rows-checkbox - CSS part for the checkbox in the selection column that selects all rows\n * @csspart row-checkbox - CSS part for the checkbox of each row in the selection column\n * \n * @slot grid-column - The slot containing the column of the grid in the `<thead>`\n * @slot grid-pagination - The slot containing the pagination of the grid below the `<table>`\n *\n */\n@Component({\n tag: 'wcs-grid',\n styleUrls: ['grid.scss', 'grid-radio.scss'],\n shadow: true\n})\nexport class Grid implements ComponentInterface, ComponentDidLoad, MutableAriaAttribute {\n @Element() private el!: HTMLWcsGridElement;\n private nativeTable!: HTMLTableElement;\n private inheritedAttributes: { [k: string]: any } = {};\n \n /**\n * Manage sort and pagination with a backend server when set to `true`\n */\n @Prop({ reflect: true }) serverMode: boolean = false;\n /**\n * Contains the data to display in the table from a js object\n */\n @Prop() data: any[];\n /**\n * Flag to display a spinner during data loading\n */\n @Prop({ reflect: true }) loading: boolean;\n /**\n * Used to manage grid's row selection. \n * \"none\": no row can be selected. \n * \"multiple\": several rows can be selected. \n * \"single\": one row only can be selected. \n */\n @Prop() selectionConfig: WcsGridSelectionConfig = 'none';\n /**\n * Set the selected items (rows)\n */\n @Prop() selectedItems: any | any[] = [];\n /**\n * Automatically set by the component to reference the wcs-grid-pagination HTML element by its id.\n */\n @Prop() wcsGridPaginationId: string;\n /**\n * Name of the object's key that will be used to display the cells whose `keyValue` attribute matches to the\n * object's value for this key. Useful for custom cells.\n */\n @Prop() rowIdPath: string;\n /**\n * Function to add css parts to the grid rows, this allows you to customize the rows with css parts directly\n * in you're application stylesheet.\n */\n @Prop() rowCssPartsFn: RowCssPartsFn = (_) => null;\n @State() private columns: HTMLWcsGridColumnElement[];\n @State() private paginationEl: HTMLWcsGridPaginationElement;\n /**\n * Rows to display, contains user data and meta data\n */\n @State() private rows: WcsGridRow[] = [];\n /**\n * Event emitted when a row is selected or unselected\n */\n @Event() wcsGridSelectionChange!: EventEmitter<WcsGridSelectionEventDetails>;\n /**\n * Event emitted when all rows are selected or unselected\n */\n @Event() wcsGridAllSelectionChange!: EventEmitter<WcsGridAllRowSelectedEventDetails>;\n /**\n * Event emitted when the grid has focus.\n */\n @Event() wcsFocus!: EventEmitter<FocusEvent>;\n /**\n * Event emitted when the grid loses focus.\n */\n @Event() wcsBlur!: EventEmitter<FocusEvent>;\n \n /**\n * Used to track the focus position in the grid for keyboard navigation. \n * Header row : index 0 \n * First column :\n * - index 1 if selection mode multiple or single\n * - index 0 if no selection mode\n * Default position : col 0, row 1\n */\n @State() private cursorPosition: {col: number, row: number} = {col: 0, row: 1};\n \n @Watch('cursorPosition')\n onCursorPositionChange(newValue: {col: number, row: number}): void {\n // Notify all grid columns that the cursorPosition has changed\n this.getGridColumnsFromTemplate().forEach(g => g.cursorPosition = newValue);\n }\n \n @Watch('data')\n onDataChange(newValue: any[]): void {\n this.updateGridRows(newValue);\n this.refreshSort(false);\n this.updatePageIndex();\n }\n\n @Watch('selectedItems')\n onSelectedItemsPropertyChange(newValue: any | any[]) {\n this.updateSelectionWithValues(newValue);\n }\n \n @Listen('focus')\n onFocus(event: FocusEvent) {\n this.getElementToFocusAtCursorPosition()?.focus();\n this.wcsFocus.emit(event);\n }\n\n @Listen('blur')\n onBlur(event: FocusEvent) {\n this.wcsBlur.emit(event);\n }\n\n /**\n * Set focus on the first cell of the grid\n */\n @Method()\n async focusFirstCell() {\n this.cursorPosition = { col: this.selectionConfig === 'none' ? 0 : 1, row: 1 };\n this.getElementToFocusAtCursorPosition()?.focus();\n }\n\n /**\n * If selectionConfig is different from `none`, that means that an extra column for radio or checkbox is rendered\n * in the table.\n */\n hasSelectionColumn() {\n return this.selectionConfig !== 'none';\n }\n \n /**\n * Returns the element to focus at the current cursor position : it can be a cell (td, th) to focus or a nested\n * checkbox / radio element if the selection mode is single or multiple\n */\n getElementToFocusAtCursorPosition(): HTMLTableCellElement | HTMLWcsCheckboxElement | HTMLInputElement {\n const el = this.gridElementsWithCoordinates.find(cell =>\n cell.col === this.cursorPosition?.col && cell.row === this.cursorPosition?.row)?.el;\n return this.hasSelectionColumn()\n ? el.querySelector('wcs-checkbox,input[type=\"radio\"]') ?? el\n : el;\n }\n \n moveCursorPosition(directionX: number | 'first' | 'last', directionY: number | 'first' | 'last') {\n this.cursorPosition = {\n col: directionX === 'first' ? 0 :\n directionX === 'last' ? this.totalDisplayedColumnCount() - 1 :\n Math.min(Math.max(this.cursorPosition.col + directionX, 0), this.totalDisplayedColumnCount() - 1),\n row: directionY === 'first' ? 0 :\n directionY === 'last' ? this.getRowsForCurrentPage().length :\n Math.min(Math.max(this.cursorPosition.row + directionY, 0), this.getRowsForCurrentPage().length)\n };\n \n this.handleCursorPositionOnEmptyTh();\n \n this.getElementToFocusAtCursorPosition()?.focus();\n }\n\n /**\n * When the grid has selectionConfig single, an empty th appears at col=0, row=0.\n * It should not be focusable so the cursor navigates to col=1, row=0 instead.\n */\n handleCursorPositionOnEmptyTh() {\n if (this.selectionConfig === 'single' && this.cursorPosition.col === 0 && this.cursorPosition.row === 0) {\n this.cursorPosition = {\n col: 1,\n row: 0\n }\n }\n }\n\n @Listen('wcsHiddenChange')\n onHiddenColumnChange(): void {\n // We use forceUpdate because the fact of hiding a column or not does not modify the internal structure of the grid (WcsGridRow).\n // Hide a column only impacts the way it is rendered but the grid-column remains in the dom and in our internal model.\n forceUpdate(this);\n this.cursorPosition = { col: 0 , row: 1 }\n }\n\n @Listen('keydown')\n onKeyDown(_event: KeyboardEvent) {\n if (document.activeElement?.tagName === 'WCS-GRID-PAGINATION') {\n return;\n }\n \n let type: 'grid_no_selection' | 'grid_selection_single' | 'grid_selection_multiple';\n \n switch (this.selectionConfig) {\n case \"multiple\":\n type = 'grid_selection_multiple';\n break;\n case \"single\":\n type = 'grid_selection_single';\n break;\n case \"none\":\n type = 'grid_no_selection';\n break;\n }\n\n const actionsFromKeyboardEvents: KeyboardEventAssociatedAction[] = getActionForKeyboardEvent(_event, type);\n\n // If we have at least one associated actions, we prevent the default behavior of the event. \n // Except if the action is a focus move (we have to handle the preventDefault behavior ourselves in the action implementation)\n if (actionsFromKeyboardEvents.length != 0) {\n _event.preventDefault();\n }\n\n for (const actionFromKeyboardEvent of actionsFromKeyboardEvents) {\n this.doActionFromKeyboardEventAssociatedAction(actionFromKeyboardEvent, _event);\n }\n }\n\n doActionFromKeyboardEventAssociatedAction(actionFromKeyboardEvent: KeyboardEventAssociatedAction, event: KeyboardEvent) {\n switch (actionFromKeyboardEvent.kind) {\n case \"FocusCell\":\n switch (actionFromKeyboardEvent.target) {\n case \"up\":\n this.moveCursorPosition(0, -1);\n break;\n case \"down\":\n this.moveCursorPosition(0, 1);\n break;\n case \"left\":\n this.moveCursorPosition(-1, 0);\n break;\n case \"right\":\n this.moveCursorPosition(1, 0);\n break;\n case \"first_of_row\":\n this.moveCursorPosition('first', 0);\n break;\n case \"last_of_row\":\n this.moveCursorPosition('last', 0);\n break;\n case \"first_of_grid\":\n this.moveCursorPosition('first', 'first');\n break;\n case \"last_of_grid\":\n this.moveCursorPosition('last', 'last');\n break;\n default:\n break;\n }\n case \"SelectRow\":\n switch (actionFromKeyboardEvent.target) {\n case \"one\":\n event.preventDefault();\n if (this.cursorPosition.row > 0) {\n this.onRowSelection(this.rows[this.cursorPosition.row - 1]);\n }\n break;\n case \"all\":\n this.selectAllRows();\n break;\n default:\n break;\n }\n break;\n default:\n throw new Error(\"Internal error\");\n }\n }\n \n \n @Listen('mousedown')\n onClick(_event: MouseEvent) {\n const clickedGridElement: HTMLTableCellElement = _event.composedPath()\n .filter(x => ['TD', 'TH']\n .includes((x as HTMLElement).nodeName))[0] as HTMLTableCellElement;\n \n if(!clickedGridElement) return; // it can be the grid pagination node, we don't want to handle it\n \n const clickedGridElementWithCoordinates = this.gridElementsWithCoordinates.find(e => e.el === clickedGridElement);\n \n this.cursorPosition = {\n col: clickedGridElementWithCoordinates.col,\n row: clickedGridElementWithCoordinates.row,\n }\n }\n\n private updateSelectionWithValues(values: any | any[]) {\n if (this.selectionConfig === 'single') {\n this.rows.map(r => r.selected = false);\n for (const row of this.rows) {\n if (isEqual(row.data, values)) {\n row.selected = true;\n break; // only one line can be selected\n }\n }\n } else if (this.selectionConfig === 'multiple') {\n this.rows.map(r => r.selected = false);\n for (const row of this.rows) {\n if (values.find(x => isEqual(x, row.data))) {\n row.selected = true;\n }\n }\n }\n this.rows = cloneDeep(this.rows);\n }\n\n private wcsGridRowToWcsGridRowData(row: WcsGridRow): WcsGridRowData {\n return {selected: row.selected, page: row.page, data: row.data};\n }\n\n private updateGridRows(data: any[]): void {\n const rows: WcsGridRow[] = [];\n if (data && this.columns) {\n // eslint-disable-next-line @typescript-eslint/prefer-for-of\n for (let i = 0; i < data.length; i++) {\n const row: WcsGridRow = {\n uuid: uuid(),\n data: data[i],\n selected: false,\n cells: []\n };\n let index = 0;\n for (const column of this.columns) {\n column.columnPosition = index + (this.hasSelectionColumn() ? 1 : 0);\n index++;\n row.cells.push({\n content: get(data[i], column.path),\n column,\n formatter: column.formatter\n })\n }\n rows.push(row);\n }\n this.rows = rows;\n }\n }\n\n componentDidLoad(): void {\n this.columns = this.getGridColumnsFromTemplate();\n this.paginationEl = this.wcsGridPaginationId\n ? document.getElementById(this.wcsGridPaginationId) as HTMLWcsGridPaginationElement\n : this.getGridPaginationsFromTemplate()[0];\n this.updateGridRows(this.data);\n if (this.selectedItems) {\n this.updateSelectionWithValues(this.selectedItems);\n }\n this.refreshSort(true);\n this.updatePageIndex();\n }\n\n componentWillLoad(): Promise<void> | void {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el),\n ...inheritAttributes(this.el, GRID_INHERITED_ATTRS),\n };\n }\n\n @Method()\n async setAriaAttribute(attr: AriaAttributeName, value: string | null | undefined) {\n setOrRemoveAttribute(this.nativeTable, attr, value);\n }\n\n /**\n * Handle existing column's filters (defined before the grid is instantiated)\n * @private\n */\n private refreshSort(refreshOthersColumnsSortOrderState: boolean) {\n //fixme: why the column property can be null or undefined?\n // Explanation: https://stenciljs.com/docs/component-lifecycle\n // The @watch can be called before the componentDidLoad() which sets the columns\n if (this.columns) {\n const [first, ...other] = this.columns.filter(c => c.sortOrder !== 'none');\n if (first && !this.serverMode) {\n this.sortBy(first);\n }\n refreshOthersColumnsSortOrderState && this.disableSortOrderForColumns(other);\n }\n }\n\n private disableSortOrderForColumns(columns: HTMLWcsGridColumnElement[] | null | undefined): void {\n columns?.forEach(c => c.sortOrder = 'none');\n }\n\n private getGridColumnsFromTemplate(): HTMLWcsGridColumnElement[] {\n const slotted = this.el.shadowRoot.querySelector('slot[name=\"grid-column\"]') as HTMLSlotElement;\n return slotted.assignedElements() as any as HTMLWcsGridColumnElement[];\n }\n\n private getGridPaginationsFromTemplate(): HTMLWcsGridPaginationElement[] {\n const slotted = this.el.shadowRoot.querySelector('slot[name=\"grid-pagination\"]') as HTMLSlotElement;\n return slotted.assignedElements() as any as HTMLWcsGridPaginationElement[];\n }\n \n private get gridElementsWithCoordinates(): GridElementWithCoordinates[] {\n const gridElements: GridElementWithCoordinates[] = [];\n // If selection multiple, the first cell should be added to the list\n if (this.selectionConfig === 'multiple') {\n gridElements.push({\n el: this.el.shadowRoot.querySelector('th'),\n row: 0,\n col: 0\n });\n }\n this.getGridColumnsFromTemplate()\n .filter(col => !col.hidden)\n .forEach((col, index) => {\n gridElements.push({\n el: col.shadowRoot.querySelector('th'),\n row: 0,\n col: index + (this.hasSelectionColumn() ? 1 : 0),\n });\n });\n this.el.shadowRoot.querySelectorAll('td').forEach((cell, index) => {\n gridElements.push({\n el: cell,\n row: 1 + Math.floor(index / this.totalDisplayedColumnCount()),\n col: index % this.totalDisplayedColumnCount(),\n });\n });\n \n return gridElements;\n }\n\n @Listen('wcsSortChange')\n sortChangeEventHandler(event: CustomEvent<WcsGridColumnSortChangeEventDetails>): void {\n // fixme: why the column property can be null or undefined?\n // Explanation: https://stenciljs.com/docs/component-lifecycle\n // The @Listen can be called before the componentDidLoad() which sets the columns\n if (event.detail.order === 'none' || !this.columns) return;\n // We keep only one active sort column\n this.disableSortOrderForColumns(this.columns.filter(c => c !== event.detail.column));\n if (this.serverMode) return;\n this.sortBy(event.detail.column);\n this.updatePageIndex();\n }\n\n /**\n * Sorts the grid rows according to the given column's configuration\n * @param column Column from which to extract the sorting configuration\n * @private\n */\n private sortBy(column: HTMLWcsGridColumnElement) {\n if (column.sortFn) {\n this.rows = cloneDeep(this.rows)\n .sort((a: any, b: any) => column.sortFn(a.data, b.data, column) * getSortOrderInteger(column.sortOrder));\n } else {\n this.rows = cloneDeep(this.rows)\n .sort((a: any, b: any) => {\n const path = column.path;\n return ((get(a.data, path) < get(b.data, path)) ? -1 : (get(a.data, path) > get(b.data, path)) ? 1 : 0) * getSortOrderInteger(column.sortOrder);\n });\n }\n }\n\n /**\n * Update the page's number of all rows\n */\n private updatePageIndex(): void {\n if (!this.serverMode && this.paginationEl) {\n this.paginationEl.itemsCount = this.data.length;\n this.paginationEl.pageCount = Math.ceil(this.data.length / this.paginationEl.pageSize);\n\n if (this.paginationEl.pageCount <= 1) {\n this.paginationEl.currentPage = GridPagination.INDEX_FIRST_PAGE;\n } else if (this.paginationEl.pageCount > 0 && this.paginationEl.currentPage + 1 > this.paginationEl.pageCount) {\n this.paginationEl.currentPage = this.paginationEl.pageCount - 1;\n }\n\n const rows = cloneDeep(this.rows);\n rows.forEach((row: WcsGridRow, index: number) =>\n row.page = Math.floor(index / this.paginationEl.pageSize)\n );\n this.rows = [...rows];\n }\n }\n\n @Listen('wcsGridPaginationChange')\n paginationChangeEventHandler(): void {\n this.onPaginationChange();\n }\n\n @Listen('wcsGridPaginationChange', {target: 'window'})\n paginationChangeEventHandlerOutside(event: CustomEvent<WcsGridPaginationChangeEventDetails>): void {\n if (this.wcsGridPaginationId && this.wcsGridPaginationId === (event.target as HTMLElement).id) {\n this.onPaginationChange();\n }\n }\n\n private onPaginationChange(): void {\n if (this.serverMode) return;\n this.updatePageIndex();\n }\n\n private onRowSelection(row: WcsGridRow): void {\n if (this.selectionConfig === 'single') {\n this.rows.filter(r => r.uuid !== row.uuid).map(r => r.selected = false);\n }\n row.selected = !row.selected;\n if (this.selectionConfig !== 'single' || row.selected) {\n this.wcsGridSelectionChange.emit({\n selectedRows: this.selectedRows.map(row => this.wcsGridRowToWcsGridRowData(row)),\n changedRow: this.wcsGridRowToWcsGridRowData(row)\n });\n }\n this.rows = cloneDeep(this.rows);\n }\n\n private get selectedRows(): WcsGridRow[] {\n return this.rows.filter(r => r.selected);\n }\n\n private selectAllRows(): void {\n const rows = this.getRowsForCurrentPage();\n const selected = !this.allRowsAreSelected();\n rows.map(r => r.selected = selected);\n this.wcsGridAllSelectionChange.emit({rows: selected ? rows.map(row => this.wcsGridRowToWcsGridRowData(row)) : []});\n this.wcsGridSelectionChange.emit({ \n selectedRows: this.selectedRows.map(row => this.wcsGridRowToWcsGridRowData(row)),\n changedRow: 'allCheckbox'\n });\n this.rows = cloneDeep(this.rows);\n }\n\n private allRowsAreSelected(): boolean {\n const rows = this.getRowsForCurrentPage();\n return rows.length > 0 && rows.filter(row => row.selected).length === rows.length;\n }\n\n private getRowsForCurrentPage(): WcsGridRow[] {\n // When in server mode, the state exists outside the internal grid model, so we must rely on the DOM state\n if (!this.serverMode && this.paginationEl) {\n return this.rows.filter(row => row.page === this.paginationEl.currentPage);\n }\n return this.rows;\n }\n\n renderSelectionColumn(row: WcsGridRow, rowIndex: number): any {\n switch (this.selectionConfig) {\n case 'none':\n return;\n case 'single': \n return <td aria-colindex={this.atLeastOneColumnHidden() ? 1 : null}\n tabIndex={this.cursorPosition?.col === 0 && rowIndex + 1 === this.cursorPosition?.row ? 0 : -1}>\n <GridRadio checked={row.selected}\n row={row}\n rowIndex={rowIndex + 1}\n totalRows={this.rows.length}\n onClick={ (row) => {\n if (!row.selected) {\n this.onRowSelection(row)\n }\n }}/>\n </td>;\n case 'multiple': \n return <td aria-colindex={this.atLeastOneColumnHidden() ? 1 : null}\n tabIndex={this.cursorPosition?.col === 0 && rowIndex + 1 === this.cursorPosition?.row ? 0 : -1}>\n <wcs-checkbox tabIndex={-1}\n part=\"row-checkbox\"\n checked={row.selected} onWcsChange={this.onRowSelection.bind(this, row)}/>\n </td>;\n }\n }\n\n private getCellContent(row: WcsGridRow, cell: WcsGridCell): HTMLElement | HTMLElement[] | string | void {\n if (cell.formatter) {\n return cell.formatter(\n (h as unknown) as HyperFunc<VNode>,\n cell.column,\n this.wcsGridRowToWcsGridRowData(row)\n );\n }\n return cell.content;\n }\n\n /**\n * Returns the total number of columns\n * @private\n */\n private totalColumnCount() {\n if (!this.columns) {\n return 0;\n }\n return this.columns.length + (this.hasSelectionColumn() ? 1 : 0);\n }\n\n /**\n * Returns the total number of columns that are not hidden\n * @private\n */\n private totalDisplayedColumnCount() {\n return this.totalColumnCount() - this.columns?.filter(col => col.hidden).length ?? 0;\n }\n\n /**\n * Returns true if at least one column is hidden from the table\n * @private\n */\n private atLeastOneColumnHidden() {\n return this.totalDisplayedColumnCount() !== this.totalColumnCount();\n }\n \n render(): any {\n return (\n <Host>\n {\n <table role=\"grid\"\n ref={(el) => (this.nativeTable = el)}\n aria-rowcount={!this.loading && this.rows?.length}\n aria-colcount={!this.loading && this.totalDisplayedColumnCount()}\n {...this.inheritedAttributes}>\n <thead>\n <tr aria-rowindex=\"1\">\n {\n this.selectionConfig === 'none' ? ''\n : <th class=\"wcs-grid-selection-column\">\n {\n this.selectionConfig === 'single' ? '' :\n <wcs-checkbox tabIndex={this.cursorPosition?.col === 0\n && this.cursorPosition?.row === 0 ? 0 : -1}\n part=\"all-rows-checkbox\"\n checked={this.allRowsAreSelected()}\n onWcsChange={this.selectAllRows.bind(this)}/>\n }\n </th>\n }\n <slot name=\"grid-column\"></slot>\n </tr>\n </thead>\n <tbody>\n {\n this.loading\n ? <tr aria-busy=\"true\">\n <td colSpan={this.totalColumnCount()} class=\"loading\">\n <wcs-spinner></wcs-spinner>\n </td>\n </tr>\n : this.rows\n ?.filter(row => this.serverMode || !this.paginationEl || row.page === this.paginationEl.currentPage)\n .map((row, index) =>\n this.renderRow(row, index)\n )\n }\n </tbody>\n </table>\n }\n <slot name=\"grid-pagination\"></slot>\n </Host>\n );\n }\n\n /**\n * Returns the row with all mapped cells inside. \n * The aria-rowindex here starts at 2 because the header row starts at index 1. \n * @private\n */ \n private renderRow(row: WcsGridRow, rowIndex: number) {\n let hiddenColumnCount = 0;\n return <tr class={row.selected ? 'selected' : ''}\n part={this.rowCssPartsWithoutEmptyList(row)?.join(' ')}\n aria-selected={row.selected ? 'true' : null}\n aria-rowindex={rowIndex + 2}>\n {this.renderSelectionColumn(row, rowIndex)}\n {row.cells?.map((cell, cellIndex) => {\n if (cell.column.hidden) {\n hiddenColumnCount++;\n return;\n }\n const nonHiddenColumnIndex = cellIndex - hiddenColumnCount + 1 + (this.hasSelectionColumn() ? 1 : 0);\n const cursorIsOnCell = nonHiddenColumnIndex - 1 === this.cursorPosition?.col \n && rowIndex + 1 === this.cursorPosition?.row;\n return cell.column.customCells\n ? (<td tabIndex={cursorIsOnCell ? 0 : -1}\n aria-colindex={this.atLeastOneColumnHidden() ? nonHiddenColumnIndex : null}>\n <slot name={cell.column.id + '-' + get(row.data, this.rowIdPath)}/>\n </td>)\n : (<td tabIndex={cursorIsOnCell ? 0 : -1}\n aria-colindex={this.atLeastOneColumnHidden() ? nonHiddenColumnIndex : null}\n part={cell.column.path + '-column'}>{this.getCellContent(row, cell)}</td>)\n }\n )}\n </tr>;\n }\n \n private rowCssPartsWithoutEmptyList(row: WcsGridRow): string[] | null | undefined {\n const parts = this.rowCssPartsFn(row);\n return parts?.length === 0 ? null : parts;\n }\n}\n\n/**\n * Pour resize le tableau\n * https://www.brainbell.com/javascript/making-resizable-table-js.htmls\n *\n */\n"]}
|
|
1
|
+
{"version":3,"file":"grid.js","sourceRoot":"","sources":["../../../src/components/grid/grid.tsx"],"names":[],"mappings":"AAAA,OAAO,EACH,SAAS,EAGT,OAAO,EACP,KAAK,EAEL,WAAW,EACX,CAAC,EACD,IAAI,EACJ,MAAM,EAAE,MAAM,EACd,IAAI,EACJ,KAAK,EAEL,KAAK,EACR,MAAM,eAAe,CAAC;AACvB,OAAO,EACH,mBAAmB,GAUtB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAAE,EAAE,IAAI,IAAI,EAAE,MAAM,MAAM,CAAC;AAClC,OAAO,EAAE,SAAS,EAAE,GAAG,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AACpD,OAAO,EAAE,cAAc,EAAE,MAAM,oCAAoC,CAAC;AACpE,OAAO,EAAE,yBAAyB,EAAiC,MAAM,uBAAuB,CAAC;AACjG,OAAO,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEzC,OAAO,EAAE,qBAAqB,EAAE,iBAAiB,EAAE,oBAAoB,EAAE,MAAM,qBAAqB,CAAC;AAQrG,MAAM,oBAAoB,GAAG,CAAC,OAAO,CAAC,CAAC;AAEvC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8CG;AAMH,MAAM,OAAO,IAAI;;QAGL,wBAAmB,GAAyB,EAAE,CAAC;0BAKR,KAAK;;;+BAeF,MAAM;6B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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACJ;AAED;;;;GAIG","sourcesContent":["import {\n Component,\n ComponentDidLoad,\n ComponentInterface,\n Element,\n Event,\n EventEmitter,\n forceUpdate,\n h,\n Host,\n Listen, Method,\n Prop,\n State,\n VNode,\n Watch\n} from '@stencil/core';\nimport {\n getSortOrderInteger,\n HyperFunc, RowCssPartsFn,\n WcsGridAllRowSelectedEventDetails,\n WcsGridCell,\n WcsGridColumnSortChangeEventDetails,\n WcsGridPaginationChangeEventDetails,\n WcsGridRow,\n WcsGridRowData,\n WcsGridSelectionConfig,\n WcsGridSelectionEventDetails,\n} from './grid-interface';\nimport { v4 as uuid } from 'uuid';\nimport { cloneDeep, get, isEqual } from 'lodash-es';\nimport { GridPagination } from '../grid-pagination/grid-pagination';\nimport { getActionForKeyboardEvent, KeyboardEventAssociatedAction } from \"./grid-keyboard-event\";\nimport { GridRadio } from \"./grid-radio\";\nimport { AriaAttributeName, MutableAriaAttribute } from \"../../utils/mutable-aria-attribute\";\nimport { inheritAriaAttributes, inheritAttributes, setOrRemoveAttribute } from \"../../utils/helpers\";\n\ninterface GridElementWithCoordinates {\n el: HTMLTableCellElement,\n row: number,\n col: number,\n}\n\nconst GRID_INHERITED_ATTRS = ['title'];\n\n/**\n * The grid component is a complex component used as an HTML table to display collections of data.\n *\n * @cssprop --wcs-grid-gap - Gap between grid cells (horizontal, vertical using `border-spacing` property)\n * @cssprop --wcs-grid-vertical-align - Vertical alignment of grid cells\n * @cssprop --wcs-grid-outline-color - Outline color for grid cells\n *\n * @cssprop --wcs-grid-cell-text-color - Text color of all grid cells\n * @cssprop --wcs-grid-cell-padding-horizontal - Horizontal padding of grid cells\n * @cssprop --wcs-grid-cell-padding-vertical - Vertical padding of grid cells\n * @cssprop --wcs-grid-cell-border-bottom - Bottom border of grid cells\n * @cssprop --wcs-grid-cell-separator-border - Separator border between grid cells\n * @cssprop --wcs-grid-first-cell-border-radius - Border radius of the first cell in a row\n * @cssprop --wcs-grid-last-cell-border-radius - Border radius of the last cell in a row\n *\n * @cssprop --wcs-grid-highlight-color - Background color for selected rows\n * @cssprop --wcs-grid-row-background-color - Background color of all rows\n * @cssprop --wcs-grid-row-odd-background-color - Background color of odd rows\n * @cssprop --wcs-grid-row-even-background-color - Background color of even rows\n *\n * @cssprop --wcs-grid-header-background-color-default - Default background color of the header\n * @cssprop --wcs-grid-header-background-color-hover - Background color of the header on hover\n * @cssprop --wcs-grid-header-background-color-press - Background color of the header on press\n * @cssprop --wcs-grid-header-text-color - Text color of the header\n * @cssprop --wcs-grid-header-font-weight - Font weight of the header\n * @cssprop --wcs-grid-header-font-size - Font size of the header\n * @cssprop --wcs-grid-header-line-height - Line height of the header\n * @cssprop --wcs-grid-header-padding-vertical - Vertical padding of the header\n * @cssprop --wcs-grid-header-padding-horizontal - Horizontal padding of the header\n * @cssprop --wcs-grid-header-border-left - Left border between header cells (default is none\n * @cssprop --wcs-grid-header-border-radius - Border radius of the header\n * @cssprop --wcs-grid-header-border-bottom - Bottom border of the header\n * @cssprop --wcs-grid-header-transition-duration - Transition duration of the header\n * @cssprop --wcs-grid-first-header-background-color - Background color of the first header cell\n * @cssprop --wcs-grid-first-header-border-radius - Border radius of the first header cell\n * @cssprop --wcs-grid-last-header-border-radius - Border radius of the last header cell\n * @cssprop --wcs-grid-column-selection-width - Width of the selection column (when selectionConfig is defined)\n * @cssprop --wcs-grid-header-sort-arrow-color-default - Color of the sort arrow in the header\n * @cssprop --wcs-grid-header-sort-arrow-color-hover - Color of the sort arrow in the header when hovered\n * \n * @csspart all-rows-checkbox - CSS part for the checkbox in the selection column that selects all rows\n * @csspart row-checkbox - CSS part for the checkbox of each row in the selection column\n * \n * @slot grid-column - The slot containing the column of the grid in the `<thead>`\n * @slot grid-pagination - The slot containing the pagination of the grid below the `<table>`\n *\n */\n@Component({\n tag: 'wcs-grid',\n styleUrls: ['grid.scss', 'grid-radio.scss'],\n shadow: true\n})\nexport class Grid implements ComponentInterface, ComponentDidLoad, MutableAriaAttribute {\n @Element() private el!: HTMLWcsGridElement;\n private nativeTable!: HTMLTableElement;\n private inheritedAttributes: { [k: string]: any } = {};\n \n /**\n * Manage sort and pagination with a backend server when set to `true`\n */\n @Prop({ reflect: true }) serverMode: boolean = false;\n /**\n * Contains the data to display in the table from a js object\n */\n @Prop() data: any[];\n /**\n * Flag to display a spinner during data loading\n */\n @Prop({ reflect: true }) loading: boolean;\n /**\n * Used to manage grid's row selection. \n * \"none\": no row can be selected. \n * \"multiple\": several rows can be selected. \n * \"single\": one row only can be selected. \n */\n @Prop() selectionConfig: WcsGridSelectionConfig = 'none';\n /**\n * Set the selected items (rows)\n */\n @Prop() selectedItems: any | any[] = [];\n /**\n * Automatically set by the component to reference the wcs-grid-pagination HTML element by its id.\n */\n @Prop() wcsGridPaginationId: string;\n /**\n * Name of the object's key that will be used to display the cells whose `keyValue` attribute matches to the\n * object's value for this key. Useful for custom cells.\n */\n @Prop() rowIdPath: string;\n /**\n * Function to add css parts to the grid rows, this allows you to customize the rows with css parts directly\n * in you're application stylesheet.\n */\n @Prop() rowCssPartsFn: RowCssPartsFn = (_) => null;\n @State() private columns: HTMLWcsGridColumnElement[];\n @State() private paginationEl: HTMLWcsGridPaginationElement;\n /**\n * Rows to display, contains user data and meta data\n */\n @State() private rows: WcsGridRow[] = [];\n /**\n * Event emitted when a row is selected or unselected\n */\n @Event() wcsGridSelectionChange!: EventEmitter<WcsGridSelectionEventDetails>;\n /**\n * Event emitted when all rows are selected or unselected\n */\n @Event() wcsGridAllSelectionChange!: EventEmitter<WcsGridAllRowSelectedEventDetails>;\n /**\n * Event emitted when the grid has focus.\n */\n @Event() wcsFocus!: EventEmitter<FocusEvent>;\n /**\n * Event emitted when the grid loses focus.\n */\n @Event() wcsBlur!: EventEmitter<FocusEvent>;\n \n /**\n * Used to track the focus position in the grid for keyboard navigation. \n * Header row : index 0 \n * First column :\n * - index 1 if selection mode multiple or single\n * - index 0 if no selection mode\n * Default position : col 0, row 1\n */\n @State() private cursorPosition: {col: number, row: number} = {col: 0, row: 1};\n \n @Watch('cursorPosition')\n onCursorPositionChange(newValue: {col: number, row: number}): void {\n // Notify all grid columns that the cursorPosition has changed\n this.getGridColumnsFromTemplate().forEach(g => g.cursorPosition = newValue);\n }\n \n @Watch('data')\n onDataChange(newValue: any[]): void {\n this.updateGridRows(newValue);\n this.refreshSort(false);\n this.updatePageIndex();\n }\n\n @Watch('selectedItems')\n onSelectedItemsPropertyChange(newValue: any | any[]) {\n this.updateSelectionWithValues(newValue);\n }\n \n @Listen('focus')\n onFocus(event: FocusEvent) {\n this.getElementToFocusAtCursorPosition()?.focus();\n this.wcsFocus.emit(event);\n }\n\n @Listen('blur')\n onBlur(event: FocusEvent) {\n this.wcsBlur.emit(event);\n }\n\n /**\n * Set focus on the first cell of the grid\n */\n @Method()\n async focusFirstCell() {\n this.cursorPosition = { col: this.selectionConfig === 'none' ? 0 : 1, row: 1 };\n this.getElementToFocusAtCursorPosition()?.focus();\n }\n\n /**\n * If selectionConfig is different from `none`, that means that an extra column for radio or checkbox is rendered\n * in the table.\n */\n hasSelectionColumn() {\n return this.selectionConfig !== 'none';\n }\n \n /**\n * Returns the element to focus at the current cursor position : it can be a cell (td, th) to focus or a nested\n * checkbox / radio element if the selection mode is single or multiple\n */\n getElementToFocusAtCursorPosition(): HTMLTableCellElement | HTMLWcsCheckboxElement | HTMLInputElement {\n const el = this.gridElementsWithCoordinates.find(cell =>\n cell.col === this.cursorPosition?.col && cell.row === this.cursorPosition?.row)?.el;\n return this.hasSelectionColumn()\n ? el.querySelector('wcs-checkbox,input[type=\"radio\"]') ?? el\n : el;\n }\n \n moveCursorPosition(directionX: number | 'first' | 'last', directionY: number | 'first' | 'last') {\n this.cursorPosition = {\n col: directionX === 'first' ? 0 :\n directionX === 'last' ? this.totalDisplayedColumnCount() - 1 :\n Math.min(Math.max(this.cursorPosition.col + directionX, 0), this.totalDisplayedColumnCount() - 1),\n row: directionY === 'first' ? 0 :\n directionY === 'last' ? this.getRowsForCurrentPage().length :\n Math.min(Math.max(this.cursorPosition.row + directionY, 0), this.getRowsForCurrentPage().length)\n };\n \n this.handleCursorPositionOnEmptyTh();\n \n this.getElementToFocusAtCursorPosition()?.focus();\n }\n\n /**\n * When the grid has selectionConfig single, an empty th appears at col=0, row=0.\n * It should not be focusable so the cursor navigates to col=1, row=0 instead.\n */\n handleCursorPositionOnEmptyTh() {\n if (this.selectionConfig === 'single' && this.cursorPosition.col === 0 && this.cursorPosition.row === 0) {\n this.cursorPosition = {\n col: 1,\n row: 0\n }\n }\n }\n\n @Listen('wcsHiddenChange')\n onHiddenColumnChange(): void {\n // We use forceUpdate because the fact of hiding a column or not does not modify the internal structure of the grid (WcsGridRow).\n // Hide a column only impacts the way it is rendered but the grid-column remains in the dom and in our internal model.\n forceUpdate(this);\n this.cursorPosition = { col: 0 , row: 1 }\n }\n\n @Listen('keydown')\n onKeyDown(_event: KeyboardEvent) {\n if (document.activeElement?.tagName === 'WCS-GRID-PAGINATION') {\n return;\n }\n \n let type: 'grid_no_selection' | 'grid_selection_single' | 'grid_selection_multiple';\n \n switch (this.selectionConfig) {\n case \"multiple\":\n type = 'grid_selection_multiple';\n break;\n case \"single\":\n type = 'grid_selection_single';\n break;\n case \"none\":\n type = 'grid_no_selection';\n break;\n }\n\n const actionsFromKeyboardEvents: KeyboardEventAssociatedAction[] = getActionForKeyboardEvent(_event, type);\n\n // If we have at least one associated actions, we prevent the default behavior of the event. \n // Except if the action is a focus move (we have to handle the preventDefault behavior ourselves in the action implementation)\n if (actionsFromKeyboardEvents.length != 0) {\n _event.preventDefault();\n }\n\n for (const actionFromKeyboardEvent of actionsFromKeyboardEvents) {\n this.doActionFromKeyboardEventAssociatedAction(actionFromKeyboardEvent, _event);\n }\n }\n\n doActionFromKeyboardEventAssociatedAction(actionFromKeyboardEvent: KeyboardEventAssociatedAction, event: KeyboardEvent) {\n switch (actionFromKeyboardEvent.kind) {\n case \"FocusCell\":\n switch (actionFromKeyboardEvent.target) {\n case \"up\":\n this.moveCursorPosition(0, -1);\n break;\n case \"down\":\n this.moveCursorPosition(0, 1);\n break;\n case \"left\":\n this.moveCursorPosition(-1, 0);\n break;\n case \"right\":\n this.moveCursorPosition(1, 0);\n break;\n case \"first_of_row\":\n this.moveCursorPosition('first', 0);\n break;\n case \"last_of_row\":\n this.moveCursorPosition('last', 0);\n break;\n case \"first_of_grid\":\n this.moveCursorPosition('first', 'first');\n break;\n case \"last_of_grid\":\n this.moveCursorPosition('last', 'last');\n break;\n default:\n break;\n }\n case \"SelectRow\":\n switch (actionFromKeyboardEvent.target) {\n case \"one\":\n event.preventDefault();\n if (this.cursorPosition.row > 0) {\n this.onRowSelection(this.rows[this.cursorPosition.row - 1]);\n }\n break;\n case \"all\":\n this.selectAllRows();\n break;\n default:\n break;\n }\n break;\n default:\n throw new Error(\"Internal error\");\n }\n }\n \n \n @Listen('mousedown')\n onClick(_event: MouseEvent) {\n const clickedGridElement: HTMLTableCellElement = _event.composedPath()\n .filter(x => ['TD', 'TH']\n .includes((x as HTMLElement).nodeName))[0] as HTMLTableCellElement;\n \n if(!clickedGridElement) return; // it can be the grid pagination node, we don't want to handle it\n \n const clickedGridElementWithCoordinates = this.gridElementsWithCoordinates.find(e => e.el === clickedGridElement);\n \n this.cursorPosition = {\n col: clickedGridElementWithCoordinates.col,\n row: clickedGridElementWithCoordinates.row,\n }\n }\n\n private updateSelectionWithValues(values: any | any[]) {\n if (this.selectionConfig === 'single') {\n this.rows.map(r => r.selected = false);\n for (const row of this.rows) {\n if (isEqual(row.data, values)) {\n row.selected = true;\n break; // only one line can be selected\n }\n }\n } else if (this.selectionConfig === 'multiple') {\n this.rows.map(r => r.selected = false);\n for (const row of this.rows) {\n if (values.find(x => isEqual(x, row.data))) {\n row.selected = true;\n }\n }\n }\n this.rows = cloneDeep(this.rows);\n }\n\n private wcsGridRowToWcsGridRowData(row: WcsGridRow): WcsGridRowData {\n return {selected: row.selected, page: row.page, data: row.data};\n }\n\n private updateGridRows(data: any[]): void {\n const rows: WcsGridRow[] = [];\n if (data && this.columns) {\n // eslint-disable-next-line @typescript-eslint/prefer-for-of\n for (let i = 0; i < data.length; i++) {\n const row: WcsGridRow = {\n uuid: uuid(),\n data: data[i],\n selected: false,\n cells: []\n };\n let index = 0;\n for (const column of this.columns) {\n column.columnPosition = index + (this.hasSelectionColumn() ? 1 : 0);\n index++;\n row.cells.push({\n content: get(data[i], column.path),\n column,\n formatter: column.formatter\n })\n }\n rows.push(row);\n }\n this.rows = rows;\n }\n }\n\n componentDidLoad(): void {\n this.columns = this.getGridColumnsFromTemplate();\n this.paginationEl = this.wcsGridPaginationId\n ? document.getElementById(this.wcsGridPaginationId) as HTMLWcsGridPaginationElement\n : this.getGridPaginationsFromTemplate()[0];\n this.updateGridRows(this.data);\n if (this.selectedItems) {\n this.updateSelectionWithValues(this.selectedItems);\n }\n this.refreshSort(true);\n this.updatePageIndex();\n }\n\n componentWillLoad(): Promise<void> | void {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el),\n ...inheritAttributes(this.el, GRID_INHERITED_ATTRS),\n };\n }\n\n @Method()\n async setAriaAttribute(attr: AriaAttributeName, value: string | null | undefined) {\n setOrRemoveAttribute(this.nativeTable, attr, value);\n }\n\n /**\n * Handle existing column's filters (defined before the grid is instantiated)\n * @private\n */\n private refreshSort(refreshOthersColumnsSortOrderState: boolean) {\n //fixme: why the column property can be null or undefined?\n // Explanation: https://stenciljs.com/docs/component-lifecycle\n // The @watch can be called before the componentDidLoad() which sets the columns\n if (this.columns) {\n const [first, ...other] = this.columns.filter(c => c.sortOrder !== 'none');\n if (first && !this.serverMode) {\n this.sortBy(first);\n }\n refreshOthersColumnsSortOrderState && this.disableSortOrderForColumns(other);\n }\n }\n\n private disableSortOrderForColumns(columns: HTMLWcsGridColumnElement[] | null | undefined): void {\n columns?.forEach(c => c.sortOrder = 'none');\n }\n\n private getGridColumnsFromTemplate(): HTMLWcsGridColumnElement[] {\n const slotted = this.el.shadowRoot.querySelector('slot[name=\"grid-column\"]') as HTMLSlotElement;\n return slotted.assignedElements() as any as HTMLWcsGridColumnElement[];\n }\n\n private getGridPaginationsFromTemplate(): HTMLWcsGridPaginationElement[] {\n const slotted = this.el.shadowRoot.querySelector('slot[name=\"grid-pagination\"]') as HTMLSlotElement;\n return slotted.assignedElements() as any as HTMLWcsGridPaginationElement[];\n }\n \n private get gridElementsWithCoordinates(): GridElementWithCoordinates[] {\n const gridElements: GridElementWithCoordinates[] = [];\n // If selection multiple, the first cell should be added to the list\n if (this.selectionConfig === 'multiple') {\n gridElements.push({\n el: this.el.shadowRoot.querySelector('th'),\n row: 0,\n col: 0\n });\n }\n this.getGridColumnsFromTemplate()\n .filter(col => !col.hidden)\n .forEach((col, index) => {\n gridElements.push({\n el: col.shadowRoot.querySelector('th'),\n row: 0,\n col: index + (this.hasSelectionColumn() ? 1 : 0),\n });\n });\n this.el.shadowRoot.querySelectorAll('td').forEach((cell, index) => {\n gridElements.push({\n el: cell,\n row: 1 + Math.floor(index / this.totalDisplayedColumnCount()),\n col: index % this.totalDisplayedColumnCount(),\n });\n });\n \n return gridElements;\n }\n\n @Listen('wcsSortChange')\n sortChangeEventHandler(event: CustomEvent<WcsGridColumnSortChangeEventDetails>): void {\n // fixme: why the column property can be null or undefined?\n // Explanation: https://stenciljs.com/docs/component-lifecycle\n // The @Listen can be called before the componentDidLoad() which sets the columns\n if (event.detail.order === 'none' || !this.columns) return;\n // We keep only one active sort column\n this.disableSortOrderForColumns(this.columns.filter(c => c !== event.detail.column));\n if (this.serverMode) return;\n this.sortBy(event.detail.column);\n this.updatePageIndex();\n }\n\n /**\n * Sorts the grid rows according to the given column's configuration\n * @param column Column from which to extract the sorting configuration\n * @private\n */\n private sortBy(column: HTMLWcsGridColumnElement) {\n if (column.sortFn) {\n this.rows = cloneDeep(this.rows)\n .sort((a: any, b: any) => column.sortFn(a.data, b.data, column) * getSortOrderInteger(column.sortOrder));\n } else {\n this.rows = cloneDeep(this.rows)\n .sort((a: any, b: any) => {\n const path = column.path;\n return ((get(a.data, path) < get(b.data, path)) ? -1 : (get(a.data, path) > get(b.data, path)) ? 1 : 0) * getSortOrderInteger(column.sortOrder);\n });\n }\n }\n\n /**\n * Update the page's number of all rows\n */\n private updatePageIndex(): void {\n if (!this.serverMode && this.paginationEl) {\n if(!this.data || this.data?.length === 0) {\n this.paginationEl.itemsCount = 0;\n this.paginationEl.pageCount = 0;\n this.paginationEl.currentPage = -1;\n return;\n }\n\n this.paginationEl.itemsCount = this.data.length;\n this.paginationEl.pageCount = Math.ceil(this.data.length / this.paginationEl.pageSize);\n\n if (this.paginationEl.pageCount <= 1) {\n this.paginationEl.currentPage = GridPagination.INDEX_FIRST_PAGE;\n } else if (this.paginationEl.pageCount > 0 && this.paginationEl.currentPage + 1 > this.paginationEl.pageCount) {\n this.paginationEl.currentPage = this.paginationEl.pageCount - 1;\n }\n\n const rows = cloneDeep(this.rows);\n rows.forEach((row: WcsGridRow, index: number) =>\n row.page = Math.floor(index / this.paginationEl.pageSize)\n );\n this.rows = [...rows];\n }\n }\n\n @Listen('wcsGridPaginationChange')\n paginationChangeEventHandler(): void {\n this.onPaginationChange();\n }\n\n @Listen('wcsGridPaginationChange', {target: 'window'})\n paginationChangeEventHandlerOutside(event: CustomEvent<WcsGridPaginationChangeEventDetails>): void {\n if (this.wcsGridPaginationId && this.wcsGridPaginationId === (event.target as HTMLElement).id) {\n this.onPaginationChange();\n }\n }\n\n private onPaginationChange(): void {\n if (this.serverMode) return;\n this.updatePageIndex();\n }\n\n private onRowSelection(row: WcsGridRow): void {\n if (this.selectionConfig === 'single') {\n this.rows.filter(r => r.uuid !== row.uuid).map(r => r.selected = false);\n }\n row.selected = !row.selected;\n if (this.selectionConfig !== 'single' || row.selected) {\n this.wcsGridSelectionChange.emit({\n selectedRows: this.selectedRows.map(row => this.wcsGridRowToWcsGridRowData(row)),\n changedRow: this.wcsGridRowToWcsGridRowData(row)\n });\n }\n this.rows = cloneDeep(this.rows);\n }\n\n private get selectedRows(): WcsGridRow[] {\n return this.rows.filter(r => r.selected);\n }\n\n private selectAllRows(): void {\n const rows = this.getRowsForCurrentPage();\n const selected = !this.allRowsAreSelected();\n rows.map(r => r.selected = selected);\n this.wcsGridAllSelectionChange.emit({rows: selected ? rows.map(row => this.wcsGridRowToWcsGridRowData(row)) : []});\n this.wcsGridSelectionChange.emit({ \n selectedRows: this.selectedRows.map(row => this.wcsGridRowToWcsGridRowData(row)),\n changedRow: 'allCheckbox'\n });\n this.rows = cloneDeep(this.rows);\n }\n\n private allRowsAreSelected(): boolean {\n const rows = this.getRowsForCurrentPage();\n return rows.length > 0 && rows.filter(row => row.selected).length === rows.length;\n }\n\n private getRowsForCurrentPage(): WcsGridRow[] {\n // When in server mode, the state exists outside the internal grid model, so we must rely on the DOM state\n if (!this.serverMode && this.paginationEl) {\n return this.rows.filter(row => row.page === this.paginationEl.currentPage);\n }\n return this.rows;\n }\n\n renderSelectionColumn(row: WcsGridRow, rowIndex: number): any {\n switch (this.selectionConfig) {\n case 'none':\n return;\n case 'single': \n return <td aria-colindex={this.atLeastOneColumnHidden() ? 1 : null}\n tabIndex={this.cursorPosition?.col === 0 && rowIndex + 1 === this.cursorPosition?.row ? 0 : -1}>\n <GridRadio checked={row.selected}\n row={row}\n rowIndex={rowIndex + 1}\n totalRows={this.rows.length}\n onClick={ (row) => {\n if (!row.selected) {\n this.onRowSelection(row)\n }\n }}/>\n </td>;\n case 'multiple': \n return <td aria-colindex={this.atLeastOneColumnHidden() ? 1 : null}\n tabIndex={this.cursorPosition?.col === 0 && rowIndex + 1 === this.cursorPosition?.row ? 0 : -1}>\n <wcs-checkbox tabIndex={-1}\n part=\"row-checkbox\"\n checked={row.selected} onWcsChange={this.onRowSelection.bind(this, row)}/>\n </td>;\n }\n }\n\n private getCellContent(row: WcsGridRow, cell: WcsGridCell): HTMLElement | HTMLElement[] | string | void {\n if (cell.formatter) {\n return cell.formatter(\n (h as unknown) as HyperFunc<VNode>,\n cell.column,\n this.wcsGridRowToWcsGridRowData(row)\n );\n }\n return cell.content;\n }\n\n /**\n * Returns the total number of columns\n * @private\n */\n private totalColumnCount() {\n if (!this.columns) {\n return 0;\n }\n return this.columns.length + (this.hasSelectionColumn() ? 1 : 0);\n }\n\n /**\n * Returns the total number of columns that are not hidden\n * @private\n */\n private totalDisplayedColumnCount() {\n return this.totalColumnCount() - this.columns?.filter(col => col.hidden).length ?? 0;\n }\n\n /**\n * Returns true if at least one column is hidden from the table\n * @private\n */\n private atLeastOneColumnHidden() {\n return this.totalDisplayedColumnCount() !== this.totalColumnCount();\n }\n \n render(): any {\n return (\n <Host>\n {\n <table role=\"grid\"\n ref={(el) => (this.nativeTable = el)}\n aria-rowcount={!this.loading && this.rows?.length}\n aria-colcount={!this.loading && this.totalDisplayedColumnCount()}\n {...this.inheritedAttributes}>\n <thead>\n <tr aria-rowindex=\"1\">\n {\n this.selectionConfig === 'none' ? ''\n : <th class=\"wcs-grid-selection-column\">\n {\n this.selectionConfig === 'single' ? '' :\n <wcs-checkbox tabIndex={this.cursorPosition?.col === 0\n && this.cursorPosition?.row === 0 ? 0 : -1}\n part=\"all-rows-checkbox\"\n checked={this.allRowsAreSelected()}\n onWcsChange={this.selectAllRows.bind(this)}/>\n }\n </th>\n }\n <slot name=\"grid-column\"></slot>\n </tr>\n </thead>\n <tbody>\n {\n this.loading\n ? <tr aria-busy=\"true\">\n <td colSpan={this.totalColumnCount()} class=\"loading\">\n <wcs-spinner></wcs-spinner>\n </td>\n </tr>\n : this.rows\n ?.filter(row => this.serverMode || !this.paginationEl || row.page === this.paginationEl.currentPage)\n .map((row, index) =>\n this.renderRow(row, index)\n )\n }\n </tbody>\n </table>\n }\n <slot name=\"grid-pagination\"></slot>\n </Host>\n );\n }\n\n /**\n * Returns the row with all mapped cells inside. \n * The aria-rowindex here starts at 2 because the header row starts at index 1. \n * @private\n */ \n private renderRow(row: WcsGridRow, rowIndex: number) {\n let hiddenColumnCount = 0;\n return <tr class={row.selected ? 'selected' : ''}\n part={this.rowCssPartsWithoutEmptyList(row)?.join(' ')}\n aria-selected={row.selected ? 'true' : null}\n aria-rowindex={rowIndex + 2}>\n {this.renderSelectionColumn(row, rowIndex)}\n {row.cells?.map((cell, cellIndex) => {\n if (cell.column.hidden) {\n hiddenColumnCount++;\n return;\n }\n const nonHiddenColumnIndex = cellIndex - hiddenColumnCount + 1 + (this.hasSelectionColumn() ? 1 : 0);\n const cursorIsOnCell = nonHiddenColumnIndex - 1 === this.cursorPosition?.col \n && rowIndex + 1 === this.cursorPosition?.row;\n return cell.column.customCells\n ? (<td tabIndex={cursorIsOnCell ? 0 : -1}\n aria-colindex={this.atLeastOneColumnHidden() ? nonHiddenColumnIndex : null}>\n <slot name={cell.column.id + '-' + get(row.data, this.rowIdPath)}/>\n </td>)\n : (<td tabIndex={cursorIsOnCell ? 0 : -1}\n aria-colindex={this.atLeastOneColumnHidden() ? nonHiddenColumnIndex : null}\n part={cell.column.path + '-column'}>{this.getCellContent(row, cell)}</td>)\n }\n )}\n </tr>;\n }\n \n private rowCssPartsWithoutEmptyList(row: WcsGridRow): string[] | null | undefined {\n const parts = this.rowCssPartsFn(row);\n return parts?.length === 0 ? null : parts;\n }\n}\n\n/**\n * Pour resize le tableau\n * https://www.brainbell.com/javascript/making-resizable-table-js.htmls\n *\n */\n"]}
|
|
@@ -69,7 +69,7 @@ export class GridColumn {
|
|
|
69
69
|
}
|
|
70
70
|
render() {
|
|
71
71
|
const ButtonOrDiv = this.getTagName();
|
|
72
|
-
return (h(Host, { key: '
|
|
72
|
+
return (h(Host, { key: '118b343bd6403270ae60ec7859ba56bea98c6aa1', slot: "grid-column" }, h("th", Object.assign({ key: '61815f030b8b3b5ceff187bf264a86d03fa8a3bd', style: { width: this.width }, class: this.sort ? 'pointer' : '', tabIndex: this.sort ? -1 : this.getTabIndex(), scope: "col", onClick: this.onSortClick.bind(this), onKeyDown: this.handleSortKeyDown.bind(this), onFocus: this.delegateFocusToButton.bind(this), "aria-sort": this.sort ? this.getSortOrderForAriaSort(this.sortOrder) : null, ref: (el) => (this.nativeTh = el) }, this.inheritedAttributes), h(ButtonOrDiv, { key: '5894a5ca7af78e40b6307a290707090f974ef652', class: "grid-column-th-content", ref: (el) => this.buttonOrDiv = el, tabIndex: this.sort ? this.getTabIndex() : -1 }, h("span", { key: '4bd49d08cea2f0892ae0e28f20cf2fc982345f9e' }, this.name), this.sort ? h("div", { class: "sort-arrow-container" }, h(GridSortArrow, { state: this.sortOrder })) : ''))));
|
|
73
73
|
}
|
|
74
74
|
onSortClick() {
|
|
75
75
|
if (!this.sort)
|
|
@@ -8,7 +8,7 @@ export class GridCustomCell {
|
|
|
8
8
|
this.rowId = undefined;
|
|
9
9
|
}
|
|
10
10
|
render() {
|
|
11
|
-
return (h(Host, { key: '
|
|
11
|
+
return (h(Host, { key: 'aac258f291f690ca8e124414d265f5fec7fc6a56', slot: this.columnId + '-' + this.rowId }, h("slot", { key: '7371fc04b30f46ada2ae94c8b4c64d6e0aa07789' })));
|
|
12
12
|
}
|
|
13
13
|
static get is() { return "wcs-grid-custom-cell"; }
|
|
14
14
|
static get encapsulation() { return "shadow"; }
|
|
@@ -14,6 +14,9 @@ const GRID_PAGINATION_INHERITED_ATTRS = ['tabindex', 'title'];
|
|
|
14
14
|
* @cssprop --wcs-grid-pagination-margin-top - Margin between the grid and the pagination
|
|
15
15
|
* @cssprop --wcs-grid-pagination-arrow-color-inactive - Color of the inactive arrow
|
|
16
16
|
* @cssprop --wcs-grid-pagination-arrow-color-active - Color of the active arrow
|
|
17
|
+
*
|
|
18
|
+
* @slot elements-per-page-text - Text following the page size select. Default text is " éléments par page". You may want to add a non-breaking space before the text to separate it from the number.
|
|
19
|
+
* @slot items-count-text - Text following the number of elements. Default text is " éléments". You may want to add a non-breaking space before the text to separate it from the number.
|
|
17
20
|
*/
|
|
18
21
|
export class GridPagination {
|
|
19
22
|
constructor() {
|
|
@@ -94,7 +97,7 @@ export class GridPagination {
|
|
|
94
97
|
});
|
|
95
98
|
}
|
|
96
99
|
render() {
|
|
97
|
-
return (h(Host, { key: '
|
|
100
|
+
return (h(Host, { key: '2b66040862ae88efc9c2fdf69f4b6398a1467765', slot: "grid-pagination" }, h("div", { key: '26ad3a0408a18669e6edef534de9056f6b7b438a', class: "container" }, h("div", { key: '7160d82226cbc902028d1ff3456e110ba1930907', class: "page-size" }, h("wcs-select", { key: '8eabadf8c1d750f47998ef8bc58764ec94ca8efc', placeholder: "El\u00E9ments par page", class: "available-page-sizes", "aria-labelledby": "elements-per-page-number elements-per-page-text", value: this.pageSize, onWcsChange: this.onChangePageSize.bind(this) }, this.availablePageSizes.map((pageSize) => h("wcs-select-option", { value: pageSize }, pageSize))), h("span", { key: 'a02dbcb0b3150112ce68697fa7e6e596613fdbbf', id: "elements-per-page-number", hidden: true }, this.pageSize), h("span", { key: '9e4676f3042fb8199a4ecb7ae9d49a492b22e6c6', id: "elements-per-page-text" }, h("slot", { key: '95635bcbe8251327916722cbac7da2d02192d00d', name: "elements-per-page-text" }, h("span", { key: '7e2ec062a42d983c0def5cbaf3799e37d51387b1' }, " \u00E9l\u00E9ments par page")))), h("div", { key: '06310a17ab65d3904715263b755d8293f60963bc', class: "items-count" }, h("p", { key: '8692ce9d64ef8af6eadea566367212d2f627e4a2' }, this.itemsCount, h("slot", { key: 'a449b2752bf712f34f2f4692331db98cac24e425', name: "items-count-text" }, h("span", { key: 'eb8f58c0b822fc56113f5674ec5f84d9ec9783fe' }, " \u00E9l\u00E9ments")))), h("nav", Object.assign({ key: '5cde096a375644a4a5282060006cddcf87cbee06', "aria-label": "pagination", ref: (el) => (this.nativeNav = el) }, this.inheritedAttributes), h("ul", { key: '1adac702212d51f51790fea4cc7fc237a90d2a1c', class: "page-management" }, h("li", { key: '9b11e07954ea7ee9a11f35acfcb634ce803c3ec3', class: "pagination-arrow", onClick: this.firstPage.bind(this) }, h(GridPaginationArrow, { key: '3ad79b51e5a21c91767d60c5d79016de378054c1', active: this.canGoToPreviousPage(), order: "previous", double: true })), h("li", { key: 'd8d56d81054b3487acc4aeabe7dca35e07004e8d', class: "pagination-arrow", onClick: this.previousPage.bind(this) }, h(GridPaginationArrow, { key: '47489f5211613cb9ff49a5f91cccd5baa2cd1b81', active: this.canGoToPreviousPage(), order: "previous" })), h("li", { key: '8bef90ad2eb8fca1161fdfead7193d64db263754', class: "pagination-counter" }, h("span", { key: '360f57f5ac09f4a86f2bb452651b2157f32fcaea', "aria-label": `Page ${this.currentPage + 1} sur ${this.pageCount}`, "aria-current": "page" }, this.currentPage + 1, " / ", this.pageCount)), h("li", { key: '31b214923f3e8c91b20948bd324e3ab9246df335', class: "pagination-arrow", onClick: this.nextPage.bind(this) }, h(GridPaginationArrow, { key: '03a73099f418ca3518bce9a19244d0ebf31c4b2c', active: this.canGoToNextPage(), order: "next" })), h("li", { key: '92f0c159253ec4a1d7337e87329d95cd15b280e4', class: "pagination-arrow", onClick: this.lastPage.bind(this) }, h(GridPaginationArrow, { key: '6c390af9e0b7a15e6f6fafaa6a6d62adda28b5b9', active: this.canGoToNextPage(), order: "next", double: true })))))));
|
|
98
101
|
}
|
|
99
102
|
static get is() { return "wcs-grid-pagination"; }
|
|
100
103
|
static get encapsulation() { return "shadow"; }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"grid-pagination.js","sourceRoot":"","sources":["../../../src/components/grid-pagination/grid-pagination.tsx"],"names":[],"mappings":"AAAA,OAAO,EACH,SAAS,EACW,OAAO,EAC3B,KAAK,EACL,CAAC,EACD,IAAI,EAAE,MAAM,EACZ,IAAI,EACP,MAAM,eAAe,CAAC;AAKvB,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAE9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C,OAAO,EAAE,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,IAAI,CAAC;4BAC9D,EAAC,mBAAmB,qDAAC,MAAM,EAAE,IAAI,CAAC,mBAAmB,EAAE,EAAE,KAAK,EAAC,UAAU,GAAuB,CAC/F;wBAEL,2DAAI,KAAK,EAAC,oBAAoB;4BAC1B,2EAAkB,QAAQ,IAAI,CAAC,WAAW,GAAG,CAAC,QAAQ,IAAI,CAAC,SAAS,EAAE,kBAAe,MAAM;gCACtF,IAAI,CAAC,WAAW,GAAG,CAAC;;gCAAK,IAAI,CAAC,SAAS,CACrC,CACN;wBAEL,2DAAI,KAAK,EAAC,kBAAkB,EAAC,OAAO,EAAE,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC;4BAC1D,EAAC,mBAAmB,qDAAC,MAAM,EAAE,IAAI,CAAC,eAAe,EAAE,EAAE,KAAK,EAAC,MAAM,GAAuB,CACvF;wBACL,2DAAI,KAAK,EAAC,kBAAkB,EAAC,OAAO,EAAE,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC;4BAC1D,EAAC,mBAAmB,qDAAC,MAAM,EAAE,IAAI,CAAC,eAAe,EAAE,EAAE,KAAK,EAAC,MAAM,EAAC,MAAM,SAAuB,CAC9F,CACJ,CACH,CACJ,CACH,CAAC,CAAA;IACZ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AApKe,+BAAgB,GAAW,CAAC,AAAZ,CAAa","sourcesContent":["import {\n Component,\n ComponentInterface, Element,\n Event, EventEmitter,\n h,\n Host, Method,\n Prop\n} from '@stencil/core';\nimport {\n WcsGridPaginationChangeEventDetails\n} from '../grid/grid-interface';\nimport { SelectChangeEventDetail } from '../select/select-interface';\nimport { GridPaginationArrow } from './grid-pagination-arrow';\nimport { AriaAttributeName, MutableAriaAttribute } from \"../../utils/mutable-aria-attribute\";\nimport { inheritAriaAttributes, inheritAttributes, setOrRemoveAttribute } from \"../../utils/helpers\";\n\nconst GRID_PAGINATION_INHERITED_ATTRS = ['tabindex', 'title'];\n\n/**\n * The grid pagination is a subcomponent of `wcs-grid`, slotted in `grid-pagination` under the `<table>` element.\n * \n * @cssprop --wcs-grid-pagination-color - Text color of the grid pagination\n * @cssprop --wcs-grid-pagination-font-size - Font-size of the grid pagination\n * @cssprop --wcs-grid-pagination-font-weight - Font-weight of the grid pagination\n * @cssprop --wcs-grid-pagination-gap - Gap between the page size, number of elements and page management\n * @cssprop --wcs-grid-pagination-page-size-gap - Gap between the select and the text within the page size container\n * @cssprop --wcs-grid-pagination-counter-gap - Gap within the page management counter\n * @cssprop --wcs-grid-pagination-margin-top - Margin between the grid and the pagination\n * @cssprop --wcs-grid-pagination-arrow-color-inactive - Color of the inactive arrow\n * @cssprop --wcs-grid-pagination-arrow-color-active - Color of the active arrow\n */\n@Component({\n tag: 'wcs-grid-pagination',\n styleUrl: 'grid-pagination.scss',\n shadow: true\n})\nexport class GridPagination implements ComponentInterface, MutableAriaAttribute {\n @Element() private el!: HTMLElement;\n private nativeNav!: HTMLElement;\n private inheritedAttributes: { [k: string]: any } = {};\n \n static readonly INDEX_FIRST_PAGE: number = 0;\n /**\n * Set the available page sizes in the pagination dropdown on the left.\n */\n @Prop() availablePageSizes: number[] = [10, 20, 50];\n /**\n * The current page of the pagination. First page starts at index 0.\n */\n @Prop({mutable: true}) currentPage: number = GridPagination.INDEX_FIRST_PAGE;\n /**\n * Maximum number of elements shown per page. \n * Default is the first value of `availablePageSizes`.\n */\n @Prop() pageSize: number = this.availablePageSizes[0];\n /**\n * Total elements in the grid. \n * - **Grid in `Server mode`** : You have to set `itemsCount` = your total data length. \n * - **Grid not in Server mode** : Do not set it manually : itemsCount is set and updated every pagination refresh.\n */\n @Prop() itemsCount: number = 0;\n /**\n * Max number of pages. \n * - **Grid in `Server mode`** : You have to set `pageCount` = `itemsCount` divided by `pageSize`. \n * - **Grid not in Server mode** : Do not set it manually : pageCount is set and updated every pagination refresh.\n */\n @Prop() pageCount: number = 1;\n /**\n * Event emitted when the pagination changes.\n */\n @Event() wcsGridPaginationChange!: EventEmitter<WcsGridPaginationChangeEventDetails>;\n\n componentWillLoad(): Promise<void> | void {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el),\n ...inheritAttributes(this.el, GRID_PAGINATION_INHERITED_ATTRS),\n };\n }\n\n @Method()\n async setAriaAttribute(attr: AriaAttributeName, value: string | null | undefined) {\n setOrRemoveAttribute(this.nativeNav, attr, value);\n }\n \n private getWcsGrid(): HTMLWcsGridElement | undefined {\n return this.el.parentElement.tagName === 'WCS-GRID' ? this.el.parentElement as HTMLWcsGridElement : undefined;\n }\n\n private lastPage(): void {\n this.currentPage = this.pageCount - 1;\n this.emitPaginationChange();\n this.focusFirstGridCell();\n }\n\n private nextPage(): void {\n if (this.canGoToNextPage()) {\n this.currentPage++;\n this.emitPaginationChange();\n this.focusFirstGridCell();\n }\n }\n\n private canGoToNextPage(): boolean {\n return this.currentPage + 1 < this.pageCount;\n }\n\n private previousPage(): void {\n if (this.canGoToPreviousPage()) {\n this.currentPage--;\n this.emitPaginationChange();\n this.focusFirstGridCell();\n }\n }\n\n private canGoToPreviousPage(): boolean {\n return this.currentPage > 0;\n }\n\n private firstPage(): void {\n this.currentPage = 0;\n this.emitPaginationChange();\n this.focusFirstGridCell();\n }\n\n private onChangePageSize(event: CustomEvent<SelectChangeEventDetail>): void {\n this.pageSize = event.detail.value;\n if (this.currentPage + 1 > this.pageSize) {\n this.currentPage = 0;\n }\n this.emitPaginationChange();\n this.focusFirstGridCell();\n }\n\n /**\n * Move focus to the first grid cell after a pagination change\n */\n private focusFirstGridCell() {\n const grid = this.getWcsGrid();\n if (grid) {\n requestAnimationFrame(() => {\n this.el.blur();\n grid.focusFirstCell();\n })\n }\n }\n\n private emitPaginationChange(): void {\n this.wcsGridPaginationChange.emit({\n pagination: {\n currentPage: this.currentPage,\n pageSize: this.pageSize,\n itemsCount: this.itemsCount,\n pageCount: this.pageCount\n }\n });\n }\n\n render(): any {\n return (<Host slot=\"grid-pagination\">\n <div class=\"container\">\n <div class=\"page-size\">\n <wcs-select placeholder=\"Eléments par page\"\n class=\"available-page-sizes\"\n aria-labelledby=\"elements-per-page-number elements-per-page-text\"\n value={this.pageSize}\n onWcsChange={this.onChangePageSize.bind(this)}>\n {\n this.availablePageSizes.map((pageSize) =>\n <wcs-select-option value={pageSize}>{pageSize}</wcs-select-option>\n )\n }\n </wcs-select>\n <span id=\"elements-per-page-number\" hidden>{this.pageSize}</span>\n <span id=\"elements-per-page-text\">éléments par page</span>\n </div>\n\n <div class=\"items-count\">\n <span>{this.itemsCount} éléments</span>\n </div>\n\n <nav aria-label=\"pagination\" ref={(el) => (this.nativeNav = el)} {...this.inheritedAttributes}>\n <ul class=\"page-management\">\n <li class=\"pagination-arrow\" onClick={this.firstPage.bind(this)}>\n <GridPaginationArrow active={this.canGoToPreviousPage()} order=\"previous\" double></GridPaginationArrow>\n </li>\n <li class=\"pagination-arrow\" onClick={this.previousPage.bind(this)}>\n <GridPaginationArrow active={this.canGoToPreviousPage()} order=\"previous\"></GridPaginationArrow>\n </li>\n \n <li class=\"pagination-counter\">\n <span aria-label={`Page ${this.currentPage + 1} sur ${this.pageCount}`} aria-current=\"page\">\n {this.currentPage + 1} / {this.pageCount}\n </span>\n </li>\n \n <li class=\"pagination-arrow\" onClick={this.nextPage.bind(this)}>\n <GridPaginationArrow active={this.canGoToNextPage()} order=\"next\"></GridPaginationArrow>\n </li>\n <li class=\"pagination-arrow\" onClick={this.lastPage.bind(this)}>\n <GridPaginationArrow active={this.canGoToNextPage()} order=\"next\" double></GridPaginationArrow>\n </li>\n </ul>\n </nav>\n </div>\n </Host>)\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"gr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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA5Ke,+BAAgB,GAAW,CAAC,AAAZ,CAAa","sourcesContent":["import {\n Component,\n ComponentInterface, Element,\n Event, EventEmitter,\n h,\n Host, Method,\n Prop\n} from '@stencil/core';\nimport {\n WcsGridPaginationChangeEventDetails\n} from '../grid/grid-interface';\nimport { SelectChangeEventDetail } from '../select/select-interface';\nimport { GridPaginationArrow } from './grid-pagination-arrow';\nimport { AriaAttributeName, MutableAriaAttribute } from \"../../utils/mutable-aria-attribute\";\nimport { inheritAriaAttributes, inheritAttributes, setOrRemoveAttribute } from \"../../utils/helpers\";\n\nconst GRID_PAGINATION_INHERITED_ATTRS = ['tabindex', 'title'];\n\n/**\n * The grid pagination is a subcomponent of `wcs-grid`, slotted in `grid-pagination` under the `<table>` element.\n * \n * @cssprop --wcs-grid-pagination-color - Text color of the grid pagination\n * @cssprop --wcs-grid-pagination-font-size - Font-size of the grid pagination\n * @cssprop --wcs-grid-pagination-font-weight - Font-weight of the grid pagination\n * @cssprop --wcs-grid-pagination-gap - Gap between the page size, number of elements and page management\n * @cssprop --wcs-grid-pagination-page-size-gap - Gap between the select and the text within the page size container\n * @cssprop --wcs-grid-pagination-counter-gap - Gap within the page management counter\n * @cssprop --wcs-grid-pagination-margin-top - Margin between the grid and the pagination\n * @cssprop --wcs-grid-pagination-arrow-color-inactive - Color of the inactive arrow\n * @cssprop --wcs-grid-pagination-arrow-color-active - Color of the active arrow\n * \n * @slot elements-per-page-text - Text following the page size select. Default text is \" éléments par page\". You may want to add a non-breaking space before the text to separate it from the number.\n * @slot items-count-text - Text following the number of elements. Default text is \" éléments\". You may want to add a non-breaking space before the text to separate it from the number.\n */\n@Component({\n tag: 'wcs-grid-pagination',\n styleUrl: 'grid-pagination.scss',\n shadow: true\n})\nexport class GridPagination implements ComponentInterface, MutableAriaAttribute {\n @Element() private el!: HTMLElement;\n private nativeNav!: HTMLElement;\n private inheritedAttributes: { [k: string]: any } = {};\n \n static readonly INDEX_FIRST_PAGE: number = 0;\n /**\n * Set the available page sizes in the pagination dropdown on the left.\n */\n @Prop() availablePageSizes: number[] = [10, 20, 50];\n /**\n * The current page of the pagination. First page starts at index 0.\n */\n @Prop({mutable: true}) currentPage: number = GridPagination.INDEX_FIRST_PAGE;\n /**\n * Maximum number of elements shown per page. \n * Default is the first value of `availablePageSizes`.\n */\n @Prop() pageSize: number = this.availablePageSizes[0];\n /**\n * Total elements in the grid. \n * - **Grid in `Server mode`** : You have to set `itemsCount` = your total data length. \n * - **Grid not in Server mode** : Do not set it manually : itemsCount is set and updated every pagination refresh.\n */\n @Prop() itemsCount: number = 0;\n /**\n * Max number of pages. \n * - **Grid in `Server mode`** : You have to set `pageCount` = `itemsCount` divided by `pageSize`. \n * - **Grid not in Server mode** : Do not set it manually : pageCount is set and updated every pagination refresh.\n */\n @Prop() pageCount: number = 1;\n /**\n * Event emitted when the pagination changes.\n */\n @Event() wcsGridPaginationChange!: EventEmitter<WcsGridPaginationChangeEventDetails>;\n\n componentWillLoad(): Promise<void> | void {\n this.inheritedAttributes = {\n ...inheritAriaAttributes(this.el),\n ...inheritAttributes(this.el, GRID_PAGINATION_INHERITED_ATTRS),\n };\n }\n\n @Method()\n async setAriaAttribute(attr: AriaAttributeName, value: string | null | undefined) {\n setOrRemoveAttribute(this.nativeNav, attr, value);\n }\n \n private getWcsGrid(): HTMLWcsGridElement | undefined {\n return this.el.parentElement.tagName === 'WCS-GRID' ? this.el.parentElement as HTMLWcsGridElement : undefined;\n }\n\n private lastPage(): void {\n this.currentPage = this.pageCount - 1;\n this.emitPaginationChange();\n this.focusFirstGridCell();\n }\n\n private nextPage(): void {\n if (this.canGoToNextPage()) {\n this.currentPage++;\n this.emitPaginationChange();\n this.focusFirstGridCell();\n }\n }\n\n private canGoToNextPage(): boolean {\n return this.currentPage + 1 < this.pageCount;\n }\n\n private previousPage(): void {\n if (this.canGoToPreviousPage()) {\n this.currentPage--;\n this.emitPaginationChange();\n this.focusFirstGridCell();\n }\n }\n\n private canGoToPreviousPage(): boolean {\n return this.currentPage > 0;\n }\n\n private firstPage(): void {\n this.currentPage = 0;\n this.emitPaginationChange();\n this.focusFirstGridCell();\n }\n\n private onChangePageSize(event: CustomEvent<SelectChangeEventDetail>): void {\n this.pageSize = event.detail.value;\n if (this.currentPage + 1 > this.pageSize) {\n this.currentPage = 0;\n }\n this.emitPaginationChange();\n this.focusFirstGridCell();\n }\n\n /**\n * Move focus to the first grid cell after a pagination change\n */\n private focusFirstGridCell() {\n const grid = this.getWcsGrid();\n if (grid) {\n requestAnimationFrame(() => {\n this.el.blur();\n grid.focusFirstCell();\n })\n }\n }\n\n private emitPaginationChange(): void {\n this.wcsGridPaginationChange.emit({\n pagination: {\n currentPage: this.currentPage,\n pageSize: this.pageSize,\n itemsCount: this.itemsCount,\n pageCount: this.pageCount\n }\n });\n }\n\n render(): any {\n return (<Host slot=\"grid-pagination\">\n <div class=\"container\">\n <div class=\"page-size\">\n <wcs-select placeholder=\"Eléments par page\"\n class=\"available-page-sizes\"\n aria-labelledby=\"elements-per-page-number elements-per-page-text\"\n value={this.pageSize}\n onWcsChange={this.onChangePageSize.bind(this)}>\n {\n this.availablePageSizes.map((pageSize) =>\n <wcs-select-option value={pageSize}>{pageSize}</wcs-select-option>\n )\n }\n </wcs-select>\n <span id=\"elements-per-page-number\" hidden>{this.pageSize}</span>\n <span id=\"elements-per-page-text\"> \n <slot name=\"elements-per-page-text\">\n <span> éléments par page</span>\n </slot>\n </span>\n </div>\n\n <div class=\"items-count\">\n <p>{this.itemsCount}\n <slot name=\"items-count-text\">\n <span> éléments</span>\n </slot>\n </p>\n </div>\n\n <nav aria-label=\"pagination\" ref={(el) => (this.nativeNav = el)} {...this.inheritedAttributes}>\n <ul class=\"page-management\">\n <li class=\"pagination-arrow\" onClick={this.firstPage.bind(this)}>\n <GridPaginationArrow active={this.canGoToPreviousPage()} order=\"previous\" double></GridPaginationArrow>\n </li>\n <li class=\"pagination-arrow\" onClick={this.previousPage.bind(this)}>\n <GridPaginationArrow active={this.canGoToPreviousPage()} order=\"previous\"></GridPaginationArrow>\n </li>\n \n <li class=\"pagination-counter\">\n <span aria-label={`Page ${this.currentPage + 1} sur ${this.pageCount}`} aria-current=\"page\">\n {this.currentPage + 1} / {this.pageCount}\n </span>\n </li>\n \n <li class=\"pagination-arrow\" onClick={this.nextPage.bind(this)}>\n <GridPaginationArrow active={this.canGoToNextPage()} order=\"next\"></GridPaginationArrow>\n </li>\n <li class=\"pagination-arrow\" onClick={this.lastPage.bind(this)}>\n <GridPaginationArrow active={this.canGoToNextPage()} order=\"next\" double></GridPaginationArrow>\n </li>\n </ul>\n </nav>\n </div>\n </Host>)\n }\n}\n"]}
|
|
@@ -37,7 +37,7 @@ export class Header {
|
|
|
37
37
|
};
|
|
38
38
|
}
|
|
39
39
|
render() {
|
|
40
|
-
return (h("header", Object.assign({ key: '
|
|
40
|
+
return (h("header", Object.assign({ key: '7d05333cbba02a8fa94f6bcd3a6e129c612a5eab', role: "banner", ref: (el) => (this.nativeHeader = el) }, this.inheritedAttributes), h("slot", { key: '7f2796e1a5667d54d30c7da60f3a8d03d3a463b7', name: "logo" }), h("slot", { key: 'fa547bcffaa627441a062c8bde97023c81704357', name: "title" }), h("slot", { key: 'fcff0c217083dbc971dafe72065416bfb5ac5332', name: "center" }), h("slot", { key: '459692329e5c4eb786d9ee232821927867686b19', name: "actions" })));
|
|
41
41
|
}
|
|
42
42
|
static get is() { return "wcs-header"; }
|
|
43
43
|
static get encapsulation() { return "shadow"; }
|
|
@@ -17,7 +17,7 @@ export class Hint {
|
|
|
17
17
|
this.small = false;
|
|
18
18
|
}
|
|
19
19
|
render() {
|
|
20
|
-
return (h(Host, { key: '
|
|
20
|
+
return (h(Host, { key: '543a98e5e95618f1916dbe681e12d8fca7e2d8c9', slot: "messages" }, h("slot", { key: '5d460b4dd0e7c6a22d42fa96de491cd0e2a4cc5f' })));
|
|
21
21
|
}
|
|
22
22
|
static get is() { return "wcs-hint"; }
|
|
23
23
|
static get encapsulation() { return "shadow"; }
|
|
@@ -60,7 +60,7 @@ export class HorizontalStepper {
|
|
|
60
60
|
}
|
|
61
61
|
}
|
|
62
62
|
render() {
|
|
63
|
-
return (h(Host, { key: '
|
|
63
|
+
return (h(Host, { key: 'b395a8e5c504ac8732384c0b05d49ad0dc5876aa' }, h("ul", { key: '158b7501687c4063e8a0f57d28b26fbd9ad5fa2f', role: "list", class: "steps" }, this.steps.map((step, index) => (h(HorizontalStep, { step: step, passed: index <= this.internalCurrentStepIndex, checkOnComplete: this.checkOnComplete, complete: this.isComplete(step, index), active: index === this.internalCurrentStepIndex, first: index === 0, disable: this.isDisable(step, index), onClick: step => this.wcsHorizontalStepClick.emit({ step, index }) })))), this.renderLabels()));
|
|
64
64
|
}
|
|
65
65
|
isComplete(step, index) {
|
|
66
66
|
return index <= this.internalCurrentStepIndex || step.complete;
|
|
@@ -23,7 +23,7 @@ export class Icon {
|
|
|
23
23
|
[`icons-size-${this.size}`]: true
|
|
24
24
|
}
|
|
25
25
|
};
|
|
26
|
-
return (h("i", Object.assign({ key: '
|
|
26
|
+
return (h("i", Object.assign({ key: 'd12fcb5beb00093de33123442fb94c33dbab957a' }, cssClass, { ref: (el) => (this.nativeIcon = el) }, this.inheritedAttributes)));
|
|
27
27
|
}
|
|
28
28
|
static get is() { return "wcs-icon"; }
|
|
29
29
|
static get properties() {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Build, h, Host } from "@stencil/core";
|
|
2
|
-
import { debounceEvent,
|
|
2
|
+
import { debounceEvent, inheritAriaAttributes, inheritAttributes, setOrRemoveAttribute } from "../../utils/helpers";
|
|
3
3
|
const INPUT_INHERITED_ATTRS = ['tabindex', 'title'];
|
|
4
4
|
/**
|
|
5
5
|
* The input component is a form control that accepts a single line of text.
|
|
@@ -167,12 +167,7 @@ export class Input {
|
|
|
167
167
|
}
|
|
168
168
|
render() {
|
|
169
169
|
const value = this.getValueAsString();
|
|
170
|
-
|
|
171
|
-
const label = findItemLabel(this.el);
|
|
172
|
-
if (label) {
|
|
173
|
-
label.id = labelId;
|
|
174
|
-
}
|
|
175
|
-
return (h(Host, { key: '20899914842d410ef72a8f81906e1e2be6e423cf', "aria-disabled": this.disabled ? 'true' : null, "data-has-prefix": !!this.prefixLabel, "data-has-suffix": !!this.suffixLabel }, this.prefixLabel ? (h("span", { class: "prefix", part: "prefix" }, this.prefixLabel)) : null, this.icon ? (h("wcs-mat-icon", { icon: this.icon, size: "m" })) : null, 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" ? (h("button", { title: this.passwordReveal ? this.hidePasswordButtonAriaLabel : this.showPasswordButtonAriaLabel, class: "toggle_password", onClick: () => this.passwordRevealIconClick() }, h("wcs-mat-icon", { icon: this.iconPassword, size: "m" }))) : null, this.suffixLabel ? (h("span", { class: "suffix", part: "suffix" }, this.suffixLabel)) : null));
|
|
170
|
+
return (h(Host, { key: '27fd1df5da31b16cd286e8d3ec53f67408c99a6b', "aria-disabled": this.disabled ? 'true' : null, "data-has-prefix": !!this.prefixLabel, "data-has-suffix": !!this.suffixLabel }, this.prefixLabel ? (h("span", { class: "prefix", part: "prefix" }, this.prefixLabel)) : null, this.icon ? (h("wcs-mat-icon", { icon: this.icon, size: "m" })) : null, h("input", Object.assign({ key: '9731bd23ee6bdfe5f61f449a2f050d6bf3332b83', 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" ? (h("button", { title: this.passwordReveal ? this.hidePasswordButtonAriaLabel : this.showPasswordButtonAriaLabel, class: "toggle_password", onClick: () => this.passwordRevealIconClick() }, h("wcs-mat-icon", { icon: this.iconPassword, size: "m" }))) : null, this.suffixLabel ? (h("span", { class: "suffix", part: "suffix" }, this.suffixLabel)) : null));
|
|
176
171
|
}
|
|
177
172
|
static get is() { return "wcs-input"; }
|
|
178
173
|
static get encapsulation() { return "shadow"; }
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"input.js","sourceRoot":"","sources":["../../../src/components/input/input.tsx"],"names":[],"mappings":"AAAA,OAAO,EACH,KAAK,EACL,SAAS,EAET,OAAO,EACP,KAAK,EAEL,CAAC,EACD,IAAI,EACJ,MAAM,EACN,IAAI,EACJ,KAAK,EACL,KAAK,EACR,MAAM,eAAe,CAAC;AACvB,OAAO,EACH,aAAa,EACb,aAAa,EACb,qBAAqB,EACrB,iBAAiB,EACjB,oBAAoB,EACvB,MAAM,qBAAqB,CAAC;AAa7B,MAAM,qBAAqB,GAAG,CAAC,UAAU,EAAE,OAAO,CAAC,C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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACJ;AAED,IAAI,QAAQ,GAAG,CAAC,CAAC","sourcesContent":["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"]}
|
|
1
|
+
{"version":3,"file":"input.js","sourceRoot":"","sources":["../../../src/components/input/input.tsx"],"names":[],"mappings":"AAAA,OAAO,EACH,KAAK,EACL,SAAS,EAET,OAAO,EACP,KAAK,EAEL,CAAC,EACD,IAAI,EACJ,MAAM,EACN,IAAI,EACJ,KAAK,EACL,KAAK,EACR,MAAM,eAAe,CAAC;AACvB,OAAO,EACH,aAAa,EACb,qBAAqB,EACrB,iBAAiB,EACjB,oBAAoB,EACvB,MAAM,qBAAqB,CAAC;AAa7B,MAAM,qBAAqB,GAAG,CAAC,UAAU,EAAE,OAAO,CAAC,CAAC;AAEpD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuDG;AAMH,MAAM,OAAO,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,EAAE,EAAE;YAC5B,MAAM,KAAK,GAAG,EAAE,CAAC,MAAiC,CAAC;YACnD,IAAI,KAAK,EAAE,CAAC;gBACR,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC,KAAK,IAAI,EAAE,CAAC;YACnC,CAAC;YACD,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,EAAmB,CAAC,CAAC;QAC5C,CAAC,CAAA;QAEO,aAAQ,GAAG,CAAC,CAAQ,EAAE,EAAE;YAC5B,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,EAAC,KAAK,EAAE,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACJ;AAED,IAAI,QAAQ,GAAG,CAAC,CAAC","sourcesContent":["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"]}
|