@gov-design-system-ce/components 0.0.6 → 0.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/Fragment-52846f79.js +7 -0
- package/dist/cjs/Fragment-52846f79.js.map +1 -0
- package/dist/cjs/{constants-5f6bbc50.js → constants-245999e7.js} +3 -2
- package/dist/cjs/constants-245999e7.js.map +1 -0
- package/dist/cjs/{constants-dc2ba6bd.js → constants-61f8be34.js} +3 -3
- package/dist/cjs/constants-61f8be34.js.map +1 -0
- package/dist/cjs/core.cjs.js +1 -1
- package/dist/cjs/gov-accordion-item.cjs.entry.js +2 -2
- package/dist/cjs/gov-accordion-item.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-accordion.cjs.entry.js +2 -1
- package/dist/cjs/gov-accordion.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-alert.cjs.entry.js +1 -1
- package/dist/cjs/gov-alert.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-app.cjs.entry.js +673 -165
- package/dist/cjs/gov-app.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-attachments_3.cjs.entry.js +1 -1
- package/dist/cjs/gov-attachments_3.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-backdrop.cjs.entry.js +4 -3
- package/dist/cjs/gov-backdrop.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-badge.cjs.entry.js +17 -17
- package/dist/cjs/gov-badge.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-breadcrumbs.cjs.entry.js +1 -1
- package/dist/cjs/gov-breadcrumbs.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-button.cjs.entry.js +14 -3
- package/dist/cjs/gov-button.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-card.cjs.entry.js +1 -1
- package/dist/cjs/gov-card.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-form-autocomplete.cjs.entry.js +4 -0
- package/dist/cjs/gov-form-autocomplete.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-form-checkbox.cjs.entry.js +23 -7
- package/dist/cjs/gov-form-checkbox.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-form-file.cjs.entry.js +7 -1
- package/dist/cjs/gov-form-file.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-form-input.cjs.entry.js +8 -2
- package/dist/cjs/gov-form-input.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-form-multi-select.cjs.entry.js +11 -3
- package/dist/cjs/gov-form-multi-select.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-form-password-power.cjs.entry.js +28 -0
- package/dist/cjs/gov-form-password-power.cjs.entry.js.map +1 -0
- package/dist/cjs/gov-form-radio.cjs.entry.js +17 -1
- package/dist/cjs/gov-form-radio.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-form-search.cjs.entry.js +1 -1
- package/dist/cjs/gov-form-search.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-form-select.cjs.entry.js +3 -3
- package/dist/cjs/gov-form-select.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-form-switch.cjs.entry.js +23 -7
- package/dist/cjs/gov-form-switch.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-icon.cjs.entry.js +1 -1
- package/dist/cjs/gov-modal.cjs.entry.js +19 -13
- package/dist/cjs/gov-modal.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-pagination.cjs.entry.js +50 -16
- package/dist/cjs/gov-pagination.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-prompt.cjs.entry.js +12 -6
- package/dist/cjs/gov-prompt.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-side-nav-item.cjs.entry.js +1 -1
- package/dist/cjs/gov-side-nav-item.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-spacer.cjs.entry.js +1 -1
- package/dist/cjs/gov-spacer.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-statsbar-item.cjs.entry.js +1 -1
- package/dist/cjs/gov-statsbar.cjs.entry.js +2 -2
- package/dist/cjs/gov-statsbar.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-tabs.cjs.entry.js +1 -1
- package/dist/cjs/gov-tabs.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-tile.cjs.entry.js +3 -2
- package/dist/cjs/gov-tile.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-tiles.cjs.entry.js +2 -1
- package/dist/cjs/gov-tiles.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-toast.cjs.entry.js +1 -1
- package/dist/cjs/gov-toast.cjs.entry.js.map +1 -1
- package/dist/cjs/gov-wizzard-item.cjs.entry.js +1 -1
- package/dist/cjs/gov-wizzard-item.cjs.entry.js.map +1 -1
- package/dist/cjs/index-356717ae.js +4 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/gov-accordion/gov-accordion-item.css +37 -5
- package/dist/collection/components/gov-accordion/gov-accordion-item.js +1 -1
- package/dist/collection/components/gov-accordion/gov-accordion-item.js.map +1 -1
- package/dist/collection/components/gov-accordion/gov-accordion.css +6 -0
- package/dist/collection/components/gov-accordion/gov-accordion.js +19 -0
- package/dist/collection/components/gov-accordion/gov-accordion.js.map +1 -1
- package/dist/collection/components/gov-alert/gov-alert.css +3 -0
- package/dist/collection/components/gov-alert/gov-alert.js +1 -1
- package/dist/collection/components/gov-alert/gov-alert.js.map +1 -1
- package/dist/collection/components/gov-app/gov-app.css +3 -0
- package/dist/collection/components/gov-attachments/gov-attachments-item.css +3 -0
- package/dist/collection/components/gov-attachments/gov-attachments-item.js +1 -1
- package/dist/collection/components/gov-attachments/gov-attachments-item.js.map +1 -1
- package/dist/collection/components/gov-attachments/gov-attachments.css +3 -0
- package/dist/collection/components/gov-backdrop/gov-backdrop.css +3 -0
- package/dist/collection/components/gov-backdrop/gov-backdrop.js +5 -4
- package/dist/collection/components/gov-backdrop/gov-backdrop.js.map +1 -1
- package/dist/collection/components/gov-badge/constants.js +4 -1
- package/dist/collection/components/gov-badge/constants.js.map +1 -1
- package/dist/collection/components/gov-badge/gov-badge.css +204 -96
- package/dist/collection/components/gov-badge/gov-badge.js +26 -47
- package/dist/collection/components/gov-badge/gov-badge.js.map +1 -1
- package/dist/collection/components/gov-breadcrumbs/gov-breadcrumbs.css +3 -0
- package/dist/collection/components/gov-breadcrumbs/gov-breadcrumbs.js +1 -1
- package/dist/collection/components/gov-breadcrumbs/gov-breadcrumbs.js.map +1 -1
- package/dist/collection/components/gov-button/constants.js +2 -1
- package/dist/collection/components/gov-button/constants.js.map +1 -1
- package/dist/collection/components/gov-button/gov-button.css +210 -131
- package/dist/collection/components/gov-button/gov-button.js +18 -7
- package/dist/collection/components/gov-button/gov-button.js.map +1 -1
- package/dist/collection/components/gov-card/gov-card.css +3 -0
- package/dist/collection/components/gov-card/gov-card.js +1 -1
- package/dist/collection/components/gov-card/gov-card.js.map +1 -1
- package/dist/collection/components/gov-container/gov-container.css +3 -0
- package/dist/collection/components/gov-cookiebar/gov-cookiebar.css +3 -0
- package/dist/collection/components/gov-empty/gov-empty.css +3 -0
- package/dist/collection/components/gov-error-code/gov-error-code.css +3 -0
- package/dist/collection/components/gov-form/autocomplete/gov-form-autocomplete.css +3 -0
- package/dist/collection/components/gov-form/autocomplete/gov-form-autocomplete.js +4 -0
- package/dist/collection/components/gov-form/autocomplete/gov-form-autocomplete.js.map +1 -1
- package/dist/collection/components/gov-form/checkbox/gov-form-checkbox.css +3 -0
- package/dist/collection/components/gov-form/checkbox/gov-form-checkbox.js +53 -19
- package/dist/collection/components/gov-form/checkbox/gov-form-checkbox.js.map +1 -1
- package/dist/collection/components/gov-form/control/gov-form-control.css +3 -0
- package/dist/collection/components/gov-form/file/gov-form-file.css +3 -0
- package/dist/collection/components/gov-form/file/gov-form-file.js +7 -1
- package/dist/collection/components/gov-form/file/gov-form-file.js.map +1 -1
- package/dist/collection/components/gov-form/group/gov-form-group.css +3 -0
- package/dist/collection/components/gov-form/input/gov-form-input.css +6 -3
- package/dist/collection/components/gov-form/input/gov-form-input.js +7 -1
- package/dist/collection/components/gov-form/input/gov-form-input.js.map +1 -1
- package/dist/collection/components/gov-form/label/gov-form-label.css +3 -0
- package/dist/collection/components/gov-form/message/gov-form-message.css +3 -0
- package/dist/collection/components/gov-form/multiselect/gov-form-multi-select.css +3 -3
- package/dist/collection/components/gov-form/multiselect/gov-form-multi-select.js +10 -2
- package/dist/collection/components/gov-form/multiselect/gov-form-multi-select.js.map +1 -1
- package/dist/collection/components/gov-form/password-power/constants.js +6 -0
- package/dist/collection/components/gov-form/password-power/constants.js.map +1 -0
- package/dist/collection/components/gov-form/password-power/gov-form-password-power.css +246 -0
- package/dist/collection/components/gov-form/password-power/gov-form-password-power.js +43 -0
- package/dist/collection/components/gov-form/password-power/gov-form-password-power.js.map +1 -0
- package/dist/collection/components/gov-form/radio/gov-form-radio.css +3 -0
- package/dist/collection/components/gov-form/radio/gov-form-radio.js +35 -1
- package/dist/collection/components/gov-form/radio/gov-form-radio.js.map +1 -1
- package/dist/collection/components/gov-form/search/gov-form-search.css +7 -0
- package/dist/collection/components/gov-form/select/gov-form-select.css +3 -3
- package/dist/collection/components/gov-form/select/gov-form-select.js +2 -2
- package/dist/collection/components/gov-form/select/gov-form-select.js.map +1 -1
- package/dist/collection/components/gov-form/switch/gov-form-switch.css +3 -0
- package/dist/collection/components/gov-form/switch/gov-form-switch.js +52 -18
- package/dist/collection/components/gov-form/switch/gov-form-switch.js.map +1 -1
- package/dist/collection/components/gov-grid/gov-grid-item.css +3 -0
- package/dist/collection/components/gov-grid/gov-grid.css +3 -0
- package/dist/collection/components/gov-icon/gov-icon.css +3 -0
- package/dist/collection/components/gov-icon/list.js +148 -5
- package/dist/collection/components/gov-icon/list.js.map +1 -1
- package/dist/collection/components/gov-layout/gov-layout-column.css +3 -0
- package/dist/collection/components/gov-layout/gov-layout.css +3 -0
- package/dist/collection/components/gov-loading/gov-loading.css +3 -0
- package/dist/collection/components/gov-message/gov-message.css +3 -0
- package/dist/collection/components/gov-modal/gov-modal.css +6 -3
- package/dist/collection/components/gov-modal/gov-modal.js +35 -22
- package/dist/collection/components/gov-modal/gov-modal.js.map +1 -1
- package/dist/collection/components/gov-nav/gov-nav-item.css +3 -0
- package/dist/collection/components/gov-nav/gov-nav.css +3 -0
- package/dist/collection/components/gov-pagination/gov-pagination.css +88 -39
- package/dist/collection/components/gov-pagination/gov-pagination.js +63 -29
- package/dist/collection/components/gov-pagination/gov-pagination.js.map +1 -1
- package/dist/collection/components/gov-promp/gov-prompt.css +6 -3
- package/dist/collection/components/gov-promp/gov-prompt.js +18 -5
- package/dist/collection/components/gov-promp/gov-prompt.js.map +1 -1
- package/dist/collection/components/gov-side-nav/gov-side-nav-item.css +3 -0
- package/dist/collection/components/gov-side-nav/gov-side-nav-item.js +1 -1
- package/dist/collection/components/gov-side-nav/gov-side-nav-item.js.map +1 -1
- package/dist/collection/components/gov-side-nav/gov-side-nav.css +3 -0
- package/dist/collection/components/gov-spacer/gov-spacer.css +3 -0
- package/dist/collection/components/gov-spacer/gov-spacer.js +3 -2
- package/dist/collection/components/gov-spacer/gov-spacer.js.map +1 -1
- package/dist/collection/components/gov-statsbar/constants.js +1 -1
- package/dist/collection/components/gov-statsbar/constants.js.map +1 -1
- package/dist/collection/components/gov-statsbar/gov-statsbar-item.css +3 -0
- package/dist/collection/components/gov-statsbar/gov-statsbar.css +3 -0
- package/dist/collection/components/gov-statsbar/gov-statsbar.js +2 -2
- package/dist/collection/components/gov-statsbar/gov-statsbar.js.map +1 -1
- package/dist/collection/components/gov-stepper/gov-stepper-item.css +3 -0
- package/dist/collection/components/gov-stepper/gov-stepper.css +3 -0
- package/dist/collection/components/gov-tabs/gov-tabs-item.css +3 -0
- package/dist/collection/components/gov-tabs/gov-tabs.css +3 -0
- package/dist/collection/components/gov-tabs/gov-tabs.js +1 -1
- package/dist/collection/components/gov-tabs/gov-tabs.js.map +1 -1
- package/dist/collection/components/gov-tile/constants.js +1 -0
- package/dist/collection/components/gov-tile/constants.js.map +1 -1
- package/dist/collection/components/gov-tile/gov-tile.css +11 -4
- package/dist/collection/components/gov-tile/gov-tile.js +3 -6
- package/dist/collection/components/gov-tile/gov-tile.js.map +1 -1
- package/dist/collection/components/gov-tiles/gov-tiles.css +6 -0
- package/dist/collection/components/gov-tiles/gov-tiles.js +19 -0
- package/dist/collection/components/gov-tiles/gov-tiles.js.map +1 -1
- package/dist/collection/components/gov-toast/gov-toast.css +3 -0
- package/dist/collection/components/gov-toast/gov-toast.js +1 -1
- package/dist/collection/components/gov-toast/gov-toast.js.map +1 -1
- package/dist/collection/components/gov-tooltip/gov-tooltip-content.css +3 -0
- package/dist/collection/components/gov-tooltip/gov-tooltip.css +3 -0
- package/dist/collection/components/gov-wizzard/gov-wizzard-item.css +3 -0
- package/dist/collection/components/gov-wizzard/gov-wizzard-item.js +1 -1
- package/dist/collection/components/gov-wizzard/gov-wizzard-item.js.map +1 -1
- package/dist/collection/components/gov-wizzard/gov-wizzard.css +3 -0
- package/dist/collection/pages/Accordion.js +97 -2
- package/dist/collection/pages/Accordion.js.map +1 -1
- package/dist/collection/pages/Badge.js +27 -0
- package/dist/collection/pages/Badge.js.map +1 -1
- package/dist/collection/pages/Button.js +440 -120
- package/dist/collection/pages/Button.js.map +1 -1
- package/dist/collection/pages/Error.js +1 -1
- package/dist/collection/pages/Error.js.map +1 -1
- package/dist/collection/pages/Forms.js +46 -29
- package/dist/collection/pages/Forms.js.map +1 -1
- package/dist/collection/pages/Pagination.js +12 -2
- package/dist/collection/pages/Pagination.js.map +1 -1
- package/dist/collection/pages/Stepper.js +6 -6
- package/dist/collection/pages/Stepper.js.map +1 -1
- package/dist/collection/pages/Tiles.js +39 -0
- package/dist/collection/pages/Tiles.js.map +1 -1
- package/dist/collection/pages/ToastMessage.js +1 -1
- package/dist/collection/pages/ToastMessage.js.map +1 -1
- package/dist/collection/pages/ToastMessageCountdown.js +1 -1
- package/dist/collection/pages/ToastMessageCountdown.js.map +1 -1
- package/dist/collection/pages/Wizzard.js +3 -3
- package/dist/collection/pages/Wizzard.js.map +1 -1
- package/dist/collection/utils/array.utils.js +2 -0
- package/dist/collection/utils/array.utils.js.map +1 -0
- package/dist/components/Fragment.js +5 -0
- package/dist/components/Fragment.js.map +1 -0
- package/dist/components/constants11.js +2 -2
- package/dist/components/constants11.js.map +1 -1
- package/dist/components/constants3.js +2 -1
- package/dist/components/constants3.js.map +1 -1
- package/dist/components/gov-accordion-item.js +2 -3
- package/dist/components/gov-accordion-item.js.map +1 -1
- package/dist/components/gov-accordion.js +3 -2
- package/dist/components/gov-accordion.js.map +1 -1
- package/dist/components/gov-alert.js +1 -2
- package/dist/components/gov-alert.js.map +1 -1
- package/dist/components/gov-app.js +673 -166
- package/dist/components/gov-app.js.map +1 -1
- package/dist/components/gov-attachments-item2.js +1 -2
- package/dist/components/gov-attachments-item2.js.map +1 -1
- package/dist/components/gov-attachments2.js +0 -1
- package/dist/components/gov-attachments2.js.map +1 -1
- package/dist/components/gov-backdrop2.js +5 -5
- package/dist/components/gov-backdrop2.js.map +1 -1
- package/dist/components/gov-badge2.js +16 -18
- package/dist/components/gov-badge2.js.map +1 -1
- package/dist/components/gov-breadcrumbs.js +1 -2
- package/dist/components/gov-breadcrumbs.js.map +1 -1
- package/dist/components/gov-button2.js +17 -7
- package/dist/components/gov-button2.js.map +1 -1
- package/dist/components/gov-card.js +1 -2
- package/dist/components/gov-card.js.map +1 -1
- package/dist/components/gov-container.js +0 -1
- package/dist/components/gov-container.js.map +1 -1
- package/dist/components/gov-cookiebar.js +0 -1
- package/dist/components/gov-cookiebar.js.map +1 -1
- package/dist/components/gov-empty.js +0 -1
- package/dist/components/gov-empty.js.map +1 -1
- package/dist/components/gov-error-code.js +0 -1
- package/dist/components/gov-error-code.js.map +1 -1
- package/dist/components/gov-form-autocomplete2.js +4 -1
- package/dist/components/gov-form-autocomplete2.js.map +1 -1
- package/dist/components/gov-form-checkbox.js +24 -8
- package/dist/components/gov-form-checkbox.js.map +1 -1
- package/dist/components/gov-form-control.js +0 -1
- package/dist/components/gov-form-control.js.map +1 -1
- package/dist/components/gov-form-file.js +7 -2
- package/dist/components/gov-form-file.js.map +1 -1
- package/dist/components/gov-form-group.js +0 -1
- package/dist/components/gov-form-group.js.map +1 -1
- package/dist/components/gov-form-input2.js +8 -3
- package/dist/components/gov-form-input2.js.map +1 -1
- package/dist/components/gov-form-label.js +0 -1
- package/dist/components/gov-form-label.js.map +1 -1
- package/dist/components/gov-form-message2.js +0 -1
- package/dist/components/gov-form-message2.js.map +1 -1
- package/dist/components/gov-form-multi-select.js +11 -4
- package/dist/components/gov-form-multi-select.js.map +1 -1
- package/dist/components/gov-form-password-power.d.ts +11 -0
- package/dist/components/gov-form-password-power.js +43 -0
- package/dist/components/gov-form-password-power.js.map +1 -0
- package/dist/components/gov-form-radio.js +18 -2
- package/dist/components/gov-form-radio.js.map +1 -1
- package/dist/components/gov-form-search.js +1 -2
- package/dist/components/gov-form-search.js.map +1 -1
- package/dist/components/gov-form-select2.js +3 -4
- package/dist/components/gov-form-select2.js.map +1 -1
- package/dist/components/gov-form-switch.js +24 -8
- package/dist/components/gov-form-switch.js.map +1 -1
- package/dist/components/gov-grid-item.js +0 -1
- package/dist/components/gov-grid-item.js.map +1 -1
- package/dist/components/gov-grid.js +0 -1
- package/dist/components/gov-grid.js.map +1 -1
- package/dist/components/gov-icon2.js +1 -2
- package/dist/components/gov-icon2.js.map +1 -1
- package/dist/components/gov-layout-column.js +0 -1
- package/dist/components/gov-layout-column.js.map +1 -1
- package/dist/components/gov-layout.js +0 -1
- package/dist/components/gov-layout.js.map +1 -1
- package/dist/components/gov-loading.js +0 -1
- package/dist/components/gov-loading.js.map +1 -1
- package/dist/components/gov-message.js +0 -1
- package/dist/components/gov-message.js.map +1 -1
- package/dist/components/gov-modal.js +20 -14
- package/dist/components/gov-modal.js.map +1 -1
- package/dist/components/gov-nav-item.js +0 -1
- package/dist/components/gov-nav-item.js.map +1 -1
- package/dist/components/gov-nav.js +0 -1
- package/dist/components/gov-nav.js.map +1 -1
- package/dist/components/gov-pagination.js +50 -17
- package/dist/components/gov-pagination.js.map +1 -1
- package/dist/components/gov-prompt.js +13 -7
- package/dist/components/gov-prompt.js.map +1 -1
- package/dist/components/gov-side-nav-item.js +1 -2
- package/dist/components/gov-side-nav-item.js.map +1 -1
- package/dist/components/gov-side-nav.js +0 -1
- package/dist/components/gov-side-nav.js.map +1 -1
- package/dist/components/gov-spacer.js +1 -2
- package/dist/components/gov-spacer.js.map +1 -1
- package/dist/components/gov-statsbar-item.js +0 -1
- package/dist/components/gov-statsbar-item.js.map +1 -1
- package/dist/components/gov-statsbar.js +2 -3
- package/dist/components/gov-statsbar.js.map +1 -1
- package/dist/components/gov-stepper-item.js +0 -1
- package/dist/components/gov-stepper-item.js.map +1 -1
- package/dist/components/gov-stepper.js +0 -1
- package/dist/components/gov-stepper.js.map +1 -1
- package/dist/components/gov-tabs-item.js +0 -1
- package/dist/components/gov-tabs-item.js.map +1 -1
- package/dist/components/gov-tabs.js +1 -2
- package/dist/components/gov-tabs.js.map +1 -1
- package/dist/components/gov-tile.js +3 -3
- package/dist/components/gov-tile.js.map +1 -1
- package/dist/components/gov-tiles.js +4 -3
- package/dist/components/gov-tiles.js.map +1 -1
- package/dist/components/gov-toast.js +1 -2
- package/dist/components/gov-toast.js.map +1 -1
- package/dist/components/gov-tooltip-content.js +0 -1
- package/dist/components/gov-tooltip-content.js.map +1 -1
- package/dist/components/gov-tooltip.js +0 -1
- package/dist/components/gov-tooltip.js.map +1 -1
- package/dist/components/gov-wizzard-item.js +1 -2
- package/dist/components/gov-wizzard-item.js.map +1 -1
- package/dist/components/gov-wizzard.js +0 -1
- package/dist/components/gov-wizzard.js.map +1 -1
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +1 -0
- package/dist/components/index.js.map +1 -1
- package/dist/core/core.css +1 -1
- package/dist/core/core.esm.js +1 -1
- package/dist/core/core.esm.js.map +1 -1
- package/dist/core/{p-e7dd2002.entry.js → p-00e1e600.entry.js} +2 -2
- package/dist/core/p-00e1e600.entry.js.map +1 -0
- package/dist/core/{p-ae3e2d60.entry.js → p-04fc18ab.entry.js} +2 -2
- package/dist/core/p-04fc18ab.entry.js.map +1 -0
- package/dist/core/p-0950ba85.entry.js +2 -0
- package/dist/core/p-0950ba85.entry.js.map +1 -0
- package/dist/core/{p-5fa41af9.js → p-1020a160.js} +1 -1
- package/dist/core/p-1020a160.js.map +1 -0
- package/dist/core/{p-9e6a41cc.entry.js → p-16608a87.entry.js} +2 -2
- package/dist/core/p-16608a87.entry.js.map +1 -0
- package/dist/core/{p-f5ee7634.entry.js → p-1bb5184f.entry.js} +2 -2
- package/dist/core/{p-f5ee7634.entry.js.map → p-1bb5184f.entry.js.map} +1 -1
- package/dist/core/p-1c06fb0b.entry.js +2 -0
- package/dist/core/p-1c06fb0b.entry.js.map +1 -0
- package/dist/core/p-1c1d0bbe.js +2 -0
- package/dist/core/p-1c1d0bbe.js.map +1 -0
- package/dist/core/{p-b48a3112.entry.js → p-4b375a4d.entry.js} +2 -2
- package/dist/core/{p-b48a3112.entry.js.map → p-4b375a4d.entry.js.map} +1 -1
- package/dist/core/p-5b4e3bdf.entry.js +2 -0
- package/dist/core/p-5b4e3bdf.entry.js.map +1 -0
- package/dist/core/p-613d8ed8.entry.js +2 -0
- package/dist/core/p-613d8ed8.entry.js.map +1 -0
- package/dist/core/{p-6d40721b.entry.js → p-63d2e8ec.entry.js} +2 -2
- package/dist/core/{p-6d40721b.entry.js.map → p-63d2e8ec.entry.js.map} +1 -1
- package/dist/core/{p-f5ffcb3d.entry.js → p-72b9e63a.entry.js} +2 -2
- package/dist/core/{p-5cecdaaf.entry.js → p-72f16a95.entry.js} +2 -2
- package/dist/core/p-7ac5f119.entry.js +2 -0
- package/dist/core/{p-63079b80.entry.js.map → p-7ac5f119.entry.js.map} +1 -1
- package/dist/core/{p-03d40bf4.entry.js → p-833ab414.entry.js} +2 -2
- package/dist/core/{p-03d40bf4.entry.js.map → p-833ab414.entry.js.map} +1 -1
- package/dist/core/{p-34360f92.entry.js → p-84fda9dd.entry.js} +2 -2
- package/dist/core/{p-34360f92.entry.js.map → p-84fda9dd.entry.js.map} +1 -1
- package/dist/core/p-851939ff.entry.js +2 -0
- package/dist/core/p-851939ff.entry.js.map +1 -0
- package/dist/core/p-8dacc8dc.entry.js +2 -0
- package/dist/core/p-8dacc8dc.entry.js.map +1 -0
- package/dist/core/p-8dbad4a2.entry.js +2 -0
- package/dist/core/p-8dbad4a2.entry.js.map +1 -0
- package/dist/core/p-902002e9.entry.js +2 -0
- package/dist/core/p-902002e9.entry.js.map +1 -0
- package/dist/core/p-95f21fbf.entry.js +2 -0
- package/dist/core/p-95f21fbf.entry.js.map +1 -0
- package/dist/core/p-99155ec0.entry.js +2 -0
- package/dist/core/p-99155ec0.entry.js.map +1 -0
- package/dist/core/{p-7591ecd4.entry.js → p-9ca0a11c.entry.js} +2 -2
- package/dist/core/{p-7591ecd4.entry.js.map → p-9ca0a11c.entry.js.map} +1 -1
- package/dist/core/p-9ceeba49.entry.js +2 -0
- package/dist/core/p-9ceeba49.entry.js.map +1 -0
- package/dist/core/{p-ec617f18.entry.js → p-9d30e79e.entry.js} +2 -2
- package/dist/core/{p-ec617f18.entry.js.map → p-9d30e79e.entry.js.map} +1 -1
- package/dist/core/{p-38fb2d42.entry.js → p-a36234bb.entry.js} +2 -2
- package/dist/core/p-a36234bb.entry.js.map +1 -0
- package/dist/core/p-ac33c5ef.entry.js +2 -0
- package/dist/core/p-ac33c5ef.entry.js.map +1 -0
- package/dist/core/p-b966062a.entry.js +2 -0
- package/dist/core/p-b966062a.entry.js.map +1 -0
- package/dist/core/{p-fc1581f9.entry.js → p-bd560ffc.entry.js} +2 -2
- package/dist/core/{p-fc1581f9.entry.js.map → p-bd560ffc.entry.js.map} +1 -1
- package/dist/core/{p-93facb4a.entry.js → p-c0430e75.entry.js} +2 -2
- package/dist/core/p-c0430e75.entry.js.map +1 -0
- package/dist/core/p-c9948e57.entry.js +2 -0
- package/dist/core/p-c9948e57.entry.js.map +1 -0
- package/dist/core/p-cd869237.js +2 -0
- package/dist/core/p-cd869237.js.map +1 -0
- package/dist/core/{p-9cc6ed83.entry.js → p-e57d250f.entry.js} +2 -2
- package/dist/core/p-e57d250f.entry.js.map +1 -0
- package/dist/core/p-ecdfb046.entry.js +2 -0
- package/dist/core/p-ecdfb046.entry.js.map +1 -0
- package/dist/core/p-fac1c202.entry.js +2 -0
- package/dist/core/p-fac1c202.entry.js.map +1 -0
- package/dist/custom-elements/index.d.ts +6 -0
- package/dist/custom-elements/index.js +1 -1
- package/dist/custom-elements/index.js.map +1 -1
- package/dist/esm/Fragment-8d8d54fb.js +5 -0
- package/dist/esm/Fragment-8d8d54fb.js.map +1 -0
- package/dist/esm/{constants-d550c816.js → constants-037c35bc.js} +3 -3
- package/dist/esm/constants-037c35bc.js.map +1 -0
- package/dist/esm/{constants-1a2146b2.js → constants-45f6db4c.js} +3 -2
- package/dist/esm/constants-45f6db4c.js.map +1 -0
- package/dist/esm/core.js +1 -1
- package/dist/esm/gov-accordion-item.entry.js +2 -2
- package/dist/esm/gov-accordion-item.entry.js.map +1 -1
- package/dist/esm/gov-accordion.entry.js +2 -1
- package/dist/esm/gov-accordion.entry.js.map +1 -1
- package/dist/esm/gov-alert.entry.js +1 -1
- package/dist/esm/gov-alert.entry.js.map +1 -1
- package/dist/esm/gov-app.entry.js +673 -165
- package/dist/esm/gov-app.entry.js.map +1 -1
- package/dist/esm/gov-attachments_3.entry.js +1 -1
- package/dist/esm/gov-attachments_3.entry.js.map +1 -1
- package/dist/esm/gov-backdrop.entry.js +5 -4
- package/dist/esm/gov-backdrop.entry.js.map +1 -1
- package/dist/esm/gov-badge.entry.js +17 -17
- package/dist/esm/gov-badge.entry.js.map +1 -1
- package/dist/esm/gov-breadcrumbs.entry.js +1 -1
- package/dist/esm/gov-breadcrumbs.entry.js.map +1 -1
- package/dist/esm/gov-button.entry.js +14 -3
- package/dist/esm/gov-button.entry.js.map +1 -1
- package/dist/esm/gov-card.entry.js +1 -1
- package/dist/esm/gov-card.entry.js.map +1 -1
- package/dist/esm/gov-form-autocomplete.entry.js +4 -0
- package/dist/esm/gov-form-autocomplete.entry.js.map +1 -1
- package/dist/esm/gov-form-checkbox.entry.js +23 -7
- package/dist/esm/gov-form-checkbox.entry.js.map +1 -1
- package/dist/esm/gov-form-file.entry.js +7 -1
- package/dist/esm/gov-form-file.entry.js.map +1 -1
- package/dist/esm/gov-form-input.entry.js +8 -2
- package/dist/esm/gov-form-input.entry.js.map +1 -1
- package/dist/esm/gov-form-multi-select.entry.js +11 -3
- package/dist/esm/gov-form-multi-select.entry.js.map +1 -1
- package/dist/esm/gov-form-password-power.entry.js +24 -0
- package/dist/esm/gov-form-password-power.entry.js.map +1 -0
- package/dist/esm/gov-form-radio.entry.js +17 -1
- package/dist/esm/gov-form-radio.entry.js.map +1 -1
- package/dist/esm/gov-form-search.entry.js +1 -1
- package/dist/esm/gov-form-search.entry.js.map +1 -1
- package/dist/esm/gov-form-select.entry.js +3 -3
- package/dist/esm/gov-form-select.entry.js.map +1 -1
- package/dist/esm/gov-form-switch.entry.js +23 -7
- package/dist/esm/gov-form-switch.entry.js.map +1 -1
- package/dist/esm/gov-icon.entry.js +1 -1
- package/dist/esm/gov-modal.entry.js +19 -13
- package/dist/esm/gov-modal.entry.js.map +1 -1
- package/dist/esm/gov-pagination.entry.js +50 -16
- package/dist/esm/gov-pagination.entry.js.map +1 -1
- package/dist/esm/gov-prompt.entry.js +12 -6
- package/dist/esm/gov-prompt.entry.js.map +1 -1
- package/dist/esm/gov-side-nav-item.entry.js +1 -1
- package/dist/esm/gov-side-nav-item.entry.js.map +1 -1
- package/dist/esm/gov-spacer.entry.js +1 -1
- package/dist/esm/gov-spacer.entry.js.map +1 -1
- package/dist/esm/gov-statsbar-item.entry.js +1 -1
- package/dist/esm/gov-statsbar.entry.js +2 -2
- package/dist/esm/gov-statsbar.entry.js.map +1 -1
- package/dist/esm/gov-tabs.entry.js +1 -1
- package/dist/esm/gov-tabs.entry.js.map +1 -1
- package/dist/esm/gov-tile.entry.js +3 -2
- package/dist/esm/gov-tile.entry.js.map +1 -1
- package/dist/esm/gov-tiles.entry.js +2 -1
- package/dist/esm/gov-tiles.entry.js.map +1 -1
- package/dist/esm/gov-toast.entry.js +1 -1
- package/dist/esm/gov-toast.entry.js.map +1 -1
- package/dist/esm/gov-wizzard-item.entry.js +1 -1
- package/dist/esm/gov-wizzard-item.entry.js.map +1 -1
- package/dist/esm/index-00e9a0d5.js +4 -0
- package/dist/esm/loader.js +1 -1
- package/dist/hydrate/index.js +946 -271
- package/dist/types/components/gov-accordion/gov-accordion.d.ts +4 -0
- package/dist/types/components/gov-badge/constants.d.ts +4 -2
- package/dist/types/components/gov-badge/gov-badge.d.ts +4 -9
- package/dist/types/components/gov-button/constants.d.ts +3 -2
- package/dist/types/components/gov-button/gov-button.d.ts +2 -0
- package/dist/types/components/gov-form/checkbox/gov-form-checkbox.d.ts +8 -3
- package/dist/types/components/gov-form/file/gov-form-file.d.ts +1 -0
- package/dist/types/components/gov-form/password-power/constants.d.ts +5 -0
- package/dist/types/components/gov-form/password-power/gov-form-password-power.d.ts +7 -0
- package/dist/types/components/gov-form/radio/gov-form-radio.d.ts +5 -0
- package/dist/types/components/gov-form/switch/gov-form-switch.d.ts +8 -3
- package/dist/types/components/gov-modal/gov-modal.d.ts +3 -1
- package/dist/types/components/gov-pagination/gov-pagination.d.ts +7 -3
- package/dist/types/components/gov-promp/gov-prompt.d.ts +3 -1
- package/dist/types/components/gov-statsbar/constants.d.ts +2 -2
- package/dist/types/components/gov-tile/constants.d.ts +1 -0
- package/dist/types/components/gov-tile/gov-tile.d.ts +1 -2
- package/dist/types/components/gov-tiles/gov-tiles.d.ts +4 -0
- package/dist/types/components.d.ts +65 -14
- package/dist/types/utils/array.utils.d.ts +1 -0
- package/package.json +1 -1
- package/dist/cjs/constants-5f6bbc50.js.map +0 -1
- package/dist/cjs/constants-dc2ba6bd.js.map +0 -1
- package/dist/core/p-00182e76.entry.js +0 -2
- package/dist/core/p-00182e76.entry.js.map +0 -1
- package/dist/core/p-0278fcb3.entry.js +0 -2
- package/dist/core/p-0278fcb3.entry.js.map +0 -1
- package/dist/core/p-08f14c8b.entry.js +0 -2
- package/dist/core/p-08f14c8b.entry.js.map +0 -1
- package/dist/core/p-0a152bb7.entry.js +0 -2
- package/dist/core/p-0a152bb7.entry.js.map +0 -1
- package/dist/core/p-14f8f2fb.js +0 -2
- package/dist/core/p-14f8f2fb.js.map +0 -1
- package/dist/core/p-2128abe1.entry.js +0 -2
- package/dist/core/p-2128abe1.entry.js.map +0 -1
- package/dist/core/p-22722ff3.entry.js +0 -2
- package/dist/core/p-22722ff3.entry.js.map +0 -1
- package/dist/core/p-2419f4cd.entry.js +0 -2
- package/dist/core/p-2419f4cd.entry.js.map +0 -1
- package/dist/core/p-38fb2d42.entry.js.map +0 -1
- package/dist/core/p-4681cb3a.entry.js +0 -2
- package/dist/core/p-4681cb3a.entry.js.map +0 -1
- package/dist/core/p-469273be.entry.js +0 -2
- package/dist/core/p-469273be.entry.js.map +0 -1
- package/dist/core/p-5547dbb0.entry.js +0 -2
- package/dist/core/p-5547dbb0.entry.js.map +0 -1
- package/dist/core/p-5fa41af9.js.map +0 -1
- package/dist/core/p-63079b80.entry.js +0 -2
- package/dist/core/p-8965f84a.entry.js +0 -2
- package/dist/core/p-8965f84a.entry.js.map +0 -1
- package/dist/core/p-93facb4a.entry.js.map +0 -1
- package/dist/core/p-9cc6ed83.entry.js.map +0 -1
- package/dist/core/p-9e6a41cc.entry.js.map +0 -1
- package/dist/core/p-ad0cc981.entry.js +0 -2
- package/dist/core/p-ad0cc981.entry.js.map +0 -1
- package/dist/core/p-ae3e2d60.entry.js.map +0 -1
- package/dist/core/p-e52a042f.entry.js +0 -2
- package/dist/core/p-e52a042f.entry.js.map +0 -1
- package/dist/core/p-e7dd2002.entry.js.map +0 -1
- package/dist/core/p-f2dc8ce3.entry.js +0 -2
- package/dist/core/p-f2dc8ce3.entry.js.map +0 -1
- package/dist/core/p-fc91591d.entry.js +0 -2
- package/dist/core/p-fc91591d.entry.js.map +0 -1
- package/dist/esm/constants-1a2146b2.js.map +0 -1
- package/dist/esm/constants-d550c816.js.map +0 -1
- /package/dist/core/{p-f5ffcb3d.entry.js.map → p-72b9e63a.entry.js.map} +0 -0
- /package/dist/core/{p-5cecdaaf.entry.js.map → p-72f16a95.entry.js.map} +0 -0
|
@@ -13,6 +13,10 @@ export declare class GovAccordion {
|
|
|
13
13
|
* Style variation of the button.
|
|
14
14
|
*/
|
|
15
15
|
readonly variant?: AccordionVariantType;
|
|
16
|
+
/**
|
|
17
|
+
* Accordion item underline
|
|
18
|
+
*/
|
|
19
|
+
readonly noBorder: boolean;
|
|
16
20
|
/**
|
|
17
21
|
* Adds accessible label for the accordion that is only shown for screen readers.
|
|
18
22
|
*/
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { ValueOf } from '../../types/interfaces';
|
|
2
|
-
declare enum NativeType {
|
|
2
|
+
export declare enum NativeType {
|
|
3
|
+
A = "a",
|
|
3
4
|
SPAN = "span",
|
|
4
5
|
BUTTON = "button"
|
|
5
6
|
}
|
|
@@ -7,5 +8,6 @@ export declare type NativeTypesType = `${ValueOf<typeof NativeType>}`;
|
|
|
7
8
|
export declare const BadgeClass: {
|
|
8
9
|
root: string;
|
|
9
10
|
inner: string;
|
|
11
|
+
hasRight: string;
|
|
12
|
+
hasLeft: string;
|
|
10
13
|
};
|
|
11
|
-
export {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { EventEmitter } from
|
|
2
|
-
import { NativeTypesType } from
|
|
3
|
-
import { ButtonSizesType, TypesType, ButtonVariantType } from
|
|
1
|
+
import { EventEmitter } from "../../stencil-public-runtime";
|
|
2
|
+
import { NativeTypesType } from "./constants";
|
|
3
|
+
import { ButtonSizesType, TypesType, ButtonVariantType } from "../gov-button/constants";
|
|
4
4
|
export declare class GovBadge {
|
|
5
5
|
private h;
|
|
6
6
|
constructor();
|
|
@@ -35,12 +35,7 @@ export declare class GovBadge {
|
|
|
35
35
|
/**
|
|
36
36
|
* Used to change the HMTL tag in the badge
|
|
37
37
|
*/
|
|
38
|
-
readonly tag:
|
|
39
|
-
/**
|
|
40
|
-
* Same as original parameter
|
|
41
|
-
* https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button#attr-type
|
|
42
|
-
*/
|
|
43
|
-
readonly nativeType: NativeTypesType;
|
|
38
|
+
readonly tag: NativeTypesType;
|
|
44
39
|
/**
|
|
45
40
|
* Style variation of the badge.
|
|
46
41
|
*/
|
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import { Sizes } from '../../core/constants/sizes';
|
|
2
2
|
import { Variants } from '../../core/constants/variants';
|
|
3
3
|
import { ValueOf } from '../../types/interfaces';
|
|
4
|
-
export declare const ButtonSizes: Pick<typeof Sizes, "_S" | "_M" | "_L" | "_XL">;
|
|
4
|
+
export declare const ButtonSizes: Pick<typeof Sizes, "_S" | "_M" | "_L" | "_XS" | "_XL">;
|
|
5
5
|
export declare type ButtonSizesType = `${ValueOf<typeof ButtonSizes>}`;
|
|
6
6
|
export declare const ButtonVariants: Pick<typeof Variants, "PRIMARY" | "SECONDARY" | "SUCCESS" | "ERROR" | "WARNING">;
|
|
7
7
|
export declare type ButtonVariantType = `${ValueOf<typeof ButtonVariants>}`;
|
|
8
8
|
export declare enum Type {
|
|
9
9
|
SOLID = "solid",
|
|
10
10
|
OUTLINED = "outlined",
|
|
11
|
-
BASE = "base"
|
|
11
|
+
BASE = "base",
|
|
12
|
+
LINK = "link"
|
|
12
13
|
}
|
|
13
14
|
export declare type TypesType = `${ValueOf<typeof Type>}`;
|
|
14
15
|
export declare enum NativeType {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { EventEmitter } from
|
|
2
|
-
import { FormCheckboxSizesType } from
|
|
3
|
-
import { GovFormCheckboxChangeEvent } from
|
|
1
|
+
import { EventEmitter } from "../../../stencil-public-runtime";
|
|
2
|
+
import { FormCheckboxSizesType } from "./constants";
|
|
3
|
+
import { GovFormCheckboxChangeEvent } from "./interfaces";
|
|
4
4
|
export declare class GovFormCheckbox {
|
|
5
5
|
private h;
|
|
6
6
|
private f;
|
|
@@ -37,6 +37,10 @@ export declare class GovFormCheckbox {
|
|
|
37
37
|
* Custom checkbox identifier.
|
|
38
38
|
*/
|
|
39
39
|
readonly identifier: string;
|
|
40
|
+
/**
|
|
41
|
+
* When you can't use the form label.
|
|
42
|
+
*/
|
|
43
|
+
readonly noLabel: boolean;
|
|
40
44
|
/**
|
|
41
45
|
* Indicates the entered value does not conform to the format expected by the application.
|
|
42
46
|
*/
|
|
@@ -69,6 +73,7 @@ export declare class GovFormCheckbox {
|
|
|
69
73
|
render(): any;
|
|
70
74
|
private onFocusHandler;
|
|
71
75
|
private onBlurHandler;
|
|
76
|
+
private onClickHandler;
|
|
72
77
|
private onChangeHandler;
|
|
73
78
|
/**
|
|
74
79
|
* Validate the WCAG attributes of the component
|
|
@@ -11,6 +11,10 @@ export declare class GovFormRadio {
|
|
|
11
11
|
* Value of radio
|
|
12
12
|
*/
|
|
13
13
|
readonly value: string;
|
|
14
|
+
/**
|
|
15
|
+
* When you can't use the form label.
|
|
16
|
+
*/
|
|
17
|
+
readonly noLabel: boolean;
|
|
14
18
|
/**
|
|
15
19
|
* Radio default state
|
|
16
20
|
*/
|
|
@@ -67,6 +71,7 @@ export declare class GovFormRadio {
|
|
|
67
71
|
componentWillLoad(): void;
|
|
68
72
|
componentDidRender(): Promise<void>;
|
|
69
73
|
render(): any;
|
|
74
|
+
private onClickHandler;
|
|
70
75
|
private onFocusHandler;
|
|
71
76
|
private onBlurHandler;
|
|
72
77
|
private onChangeHandler;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { EventEmitter } from
|
|
2
|
-
import { FormSwitchSizesType } from
|
|
3
|
-
import { GovFormSwitchChangeEvent } from
|
|
1
|
+
import { EventEmitter } from "../../../stencil-public-runtime";
|
|
2
|
+
import { FormSwitchSizesType } from "./constants";
|
|
3
|
+
import { GovFormSwitchChangeEvent } from "./interfaces";
|
|
4
4
|
export declare class GovFormSwitch {
|
|
5
5
|
private h;
|
|
6
6
|
private f;
|
|
@@ -11,6 +11,10 @@ export declare class GovFormSwitch {
|
|
|
11
11
|
* Value of switch
|
|
12
12
|
*/
|
|
13
13
|
readonly value: string;
|
|
14
|
+
/**
|
|
15
|
+
* When you can't use the form label.
|
|
16
|
+
*/
|
|
17
|
+
readonly noLabel: boolean;
|
|
14
18
|
/**
|
|
15
19
|
* Switch default state
|
|
16
20
|
*/
|
|
@@ -67,6 +71,7 @@ export declare class GovFormSwitch {
|
|
|
67
71
|
componentWillLoad(): void;
|
|
68
72
|
componentDidRender(): Promise<void>;
|
|
69
73
|
render(): any;
|
|
74
|
+
private onClickHandler;
|
|
70
75
|
private onFocusHandler;
|
|
71
76
|
private onBlurHandler;
|
|
72
77
|
private onChangeHandler;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EventEmitter } from
|
|
1
|
+
import { EventEmitter } from "../../stencil-public-runtime";
|
|
2
2
|
export declare class GovModal {
|
|
3
3
|
private h;
|
|
4
4
|
private readonly labelId;
|
|
@@ -41,7 +41,9 @@ export declare class GovModal {
|
|
|
41
41
|
* Emitted when modal window closes.
|
|
42
42
|
*/
|
|
43
43
|
govClose: EventEmitter<PointerEvent>;
|
|
44
|
+
modalVisible: boolean;
|
|
44
45
|
validateLabelTag(newValue: string): void;
|
|
46
|
+
watchOpen(newValue: boolean): void;
|
|
45
47
|
private showModal;
|
|
46
48
|
private hideModal;
|
|
47
49
|
componentWillRender(): Promise<void>;
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
import { EventEmitter } from
|
|
2
|
-
import { PaginationSizeType, PaginationVariantType, PaginationType } from
|
|
3
|
-
import { Pagination } from
|
|
1
|
+
import { EventEmitter } from "../../stencil-public-runtime";
|
|
2
|
+
import { PaginationSizeType, PaginationVariantType, PaginationType } from "./constants";
|
|
3
|
+
import { Pagination } from "./pagination";
|
|
4
4
|
export declare class GovPagination {
|
|
5
5
|
private h;
|
|
6
6
|
private readonly pageSelectId;
|
|
7
|
+
private spreadSelectRef?;
|
|
7
8
|
constructor();
|
|
8
9
|
readonly host: HTMLGovPaginationElement;
|
|
9
10
|
/**
|
|
@@ -72,8 +73,11 @@ export declare class GovPagination {
|
|
|
72
73
|
componentDidRender(): Promise<void>;
|
|
73
74
|
private recalculatePagination;
|
|
74
75
|
private isActivePageClass;
|
|
76
|
+
private prepareLinkUrl;
|
|
77
|
+
private resetSelectValue;
|
|
75
78
|
render(): any;
|
|
76
79
|
private onClickHandler;
|
|
80
|
+
private onSelectHandler;
|
|
77
81
|
/**
|
|
78
82
|
* Validate the WCAG attributes of the component
|
|
79
83
|
*/
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EventEmitter } from
|
|
1
|
+
import { EventEmitter } from "../../stencil-public-runtime";
|
|
2
2
|
export declare class GovPrompt {
|
|
3
3
|
private h;
|
|
4
4
|
private readonly labelId;
|
|
@@ -41,7 +41,9 @@ export declare class GovPrompt {
|
|
|
41
41
|
* Emitted when modal window closes.
|
|
42
42
|
*/
|
|
43
43
|
govClose: EventEmitter<PointerEvent>;
|
|
44
|
+
modalVisible: boolean;
|
|
44
45
|
validateLabelTag(newValue: string): void;
|
|
46
|
+
watchOpen(newValue: boolean): void;
|
|
45
47
|
private showModal;
|
|
46
48
|
private hideModal;
|
|
47
49
|
componentWillRender(): Promise<void>;
|
|
@@ -4,8 +4,8 @@ export declare enum StatsBarIconPosition {
|
|
|
4
4
|
LEFT = "left"
|
|
5
5
|
}
|
|
6
6
|
export declare type StatsBarIconPositionType = `${ValueOf<typeof StatsBarIconPosition>}`;
|
|
7
|
-
export declare const
|
|
8
|
-
export declare type StatsBarVariantType = `${ValueOf<typeof
|
|
7
|
+
export declare const StatsBarVariants: Pick<typeof Variants, "PRIMARY" | "SECONDARY">;
|
|
8
|
+
export declare type StatsBarVariantType = `${ValueOf<typeof StatsBarVariants>}`;
|
|
9
9
|
export declare const StatsBarClass: {
|
|
10
10
|
root: string;
|
|
11
11
|
section: string;
|
|
@@ -45,6 +45,10 @@ import { WizardSizesType, WizardVariantsType } from "./components/gov-wizzard/co
|
|
|
45
45
|
import { GovWizzardItemChangeEvent } from "./components/gov-wizzard/gov-wizzard-item.d";
|
|
46
46
|
export namespace Components {
|
|
47
47
|
interface GovAccordion {
|
|
48
|
+
/**
|
|
49
|
+
* Accordion item underline
|
|
50
|
+
*/
|
|
51
|
+
"noBorder": boolean;
|
|
48
52
|
/**
|
|
49
53
|
* Accordion’s size.
|
|
50
54
|
*/
|
|
@@ -200,10 +204,6 @@ export namespace Components {
|
|
|
200
204
|
* Determide if component should have inversed colors to be used on dark background
|
|
201
205
|
*/
|
|
202
206
|
"inverse": boolean;
|
|
203
|
-
/**
|
|
204
|
-
* Same as original parameter https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button#attr-type
|
|
205
|
-
*/
|
|
206
|
-
"nativeType": NativeTypesType;
|
|
207
207
|
/**
|
|
208
208
|
* Badge’s size.
|
|
209
209
|
*/
|
|
@@ -211,7 +211,7 @@ export namespace Components {
|
|
|
211
211
|
/**
|
|
212
212
|
* Used to change the HMTL tag in the badge
|
|
213
213
|
*/
|
|
214
|
-
"tag":
|
|
214
|
+
"tag": NativeTypesType;
|
|
215
215
|
/**
|
|
216
216
|
* Same as original parameter
|
|
217
217
|
* @link https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#attr-target
|
|
@@ -560,6 +560,10 @@ export namespace Components {
|
|
|
560
560
|
* Name of the checkbox.
|
|
561
561
|
*/
|
|
562
562
|
"name": string;
|
|
563
|
+
/**
|
|
564
|
+
* When you can't use the form label.
|
|
565
|
+
*/
|
|
566
|
+
"noLabel": boolean;
|
|
563
567
|
/**
|
|
564
568
|
* Set whether the input is required or not. Please note that this is necessary for accessible inputs when the user is required to fill them. When using this property you need to also set “novalidate” attribute to your form element to prevent browser from displaying its own validation errors.
|
|
565
569
|
*/
|
|
@@ -898,6 +902,12 @@ export namespace Components {
|
|
|
898
902
|
*/
|
|
899
903
|
"wcagOwns": string;
|
|
900
904
|
}
|
|
905
|
+
interface GovFormPasswordPower {
|
|
906
|
+
/**
|
|
907
|
+
* Password power: 0 - none, 1 - weak, 2 - medium, 3 - strong
|
|
908
|
+
*/
|
|
909
|
+
"power": number;
|
|
910
|
+
}
|
|
901
911
|
interface GovFormRadio {
|
|
902
912
|
/**
|
|
903
913
|
* Radio default state
|
|
@@ -919,6 +929,10 @@ export namespace Components {
|
|
|
919
929
|
* Name of the radio.
|
|
920
930
|
*/
|
|
921
931
|
"name": string;
|
|
932
|
+
/**
|
|
933
|
+
* When you can't use the form label.
|
|
934
|
+
*/
|
|
935
|
+
"noLabel": boolean;
|
|
922
936
|
/**
|
|
923
937
|
* Set whether the input is required or not. Please note that this is necessary for accessible inputs when the user is required to fill them. When using this property you need to also set “novalidate” attribute to your form element to prevent browser from displaying its own validation errors.
|
|
924
938
|
*/
|
|
@@ -1037,6 +1051,10 @@ export namespace Components {
|
|
|
1037
1051
|
* Name of the switch.
|
|
1038
1052
|
*/
|
|
1039
1053
|
"name": string;
|
|
1054
|
+
/**
|
|
1055
|
+
* When you can't use the form label.
|
|
1056
|
+
*/
|
|
1057
|
+
"noLabel": boolean;
|
|
1040
1058
|
/**
|
|
1041
1059
|
* Set whether the input is required or not. Please note that this is necessary for accessible inputs when the user is required to fill them. When using this property you need to also set “novalidate” attribute to your form element to prevent browser from displaying its own validation errors.
|
|
1042
1060
|
*/
|
|
@@ -1512,8 +1530,7 @@ export namespace Components {
|
|
|
1512
1530
|
}
|
|
1513
1531
|
interface GovTile {
|
|
1514
1532
|
/**
|
|
1515
|
-
*
|
|
1516
|
-
* @link https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#attr-href
|
|
1533
|
+
* Link on whole tile
|
|
1517
1534
|
*/
|
|
1518
1535
|
"href": string;
|
|
1519
1536
|
/**
|
|
@@ -1530,6 +1547,10 @@ export namespace Components {
|
|
|
1530
1547
|
* Number of columns between 1-4
|
|
1531
1548
|
*/
|
|
1532
1549
|
"columns": number;
|
|
1550
|
+
/**
|
|
1551
|
+
* Tiles border
|
|
1552
|
+
*/
|
|
1553
|
+
"noBorder": boolean;
|
|
1533
1554
|
}
|
|
1534
1555
|
interface GovToast {
|
|
1535
1556
|
/**
|
|
@@ -1939,6 +1960,12 @@ declare global {
|
|
|
1939
1960
|
prototype: HTMLGovFormMultiSelectElement;
|
|
1940
1961
|
new (): HTMLGovFormMultiSelectElement;
|
|
1941
1962
|
};
|
|
1963
|
+
interface HTMLGovFormPasswordPowerElement extends Components.GovFormPasswordPower, HTMLStencilElement {
|
|
1964
|
+
}
|
|
1965
|
+
var HTMLGovFormPasswordPowerElement: {
|
|
1966
|
+
prototype: HTMLGovFormPasswordPowerElement;
|
|
1967
|
+
new (): HTMLGovFormPasswordPowerElement;
|
|
1968
|
+
};
|
|
1942
1969
|
interface HTMLGovFormRadioElement extends Components.GovFormRadio, HTMLStencilElement {
|
|
1943
1970
|
}
|
|
1944
1971
|
var HTMLGovFormRadioElement: {
|
|
@@ -2156,6 +2183,7 @@ declare global {
|
|
|
2156
2183
|
"gov-form-label": HTMLGovFormLabelElement;
|
|
2157
2184
|
"gov-form-message": HTMLGovFormMessageElement;
|
|
2158
2185
|
"gov-form-multi-select": HTMLGovFormMultiSelectElement;
|
|
2186
|
+
"gov-form-password-power": HTMLGovFormPasswordPowerElement;
|
|
2159
2187
|
"gov-form-radio": HTMLGovFormRadioElement;
|
|
2160
2188
|
"gov-form-search": HTMLGovFormSearchElement;
|
|
2161
2189
|
"gov-form-select": HTMLGovFormSelectElement;
|
|
@@ -2192,6 +2220,10 @@ declare global {
|
|
|
2192
2220
|
}
|
|
2193
2221
|
declare namespace LocalJSX {
|
|
2194
2222
|
interface GovAccordion {
|
|
2223
|
+
/**
|
|
2224
|
+
* Accordion item underline
|
|
2225
|
+
*/
|
|
2226
|
+
"noBorder"?: boolean;
|
|
2195
2227
|
/**
|
|
2196
2228
|
* Called when the accordion state changes
|
|
2197
2229
|
*/
|
|
@@ -2335,10 +2367,6 @@ declare namespace LocalJSX {
|
|
|
2335
2367
|
* Determide if component should have inversed colors to be used on dark background
|
|
2336
2368
|
*/
|
|
2337
2369
|
"inverse"?: boolean;
|
|
2338
|
-
/**
|
|
2339
|
-
* Same as original parameter https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button#attr-type
|
|
2340
|
-
*/
|
|
2341
|
-
"nativeType"?: NativeTypesType;
|
|
2342
2370
|
/**
|
|
2343
2371
|
* Emitted when the button click.
|
|
2344
2372
|
*/
|
|
@@ -2350,7 +2378,7 @@ declare namespace LocalJSX {
|
|
|
2350
2378
|
/**
|
|
2351
2379
|
* Used to change the HMTL tag in the badge
|
|
2352
2380
|
*/
|
|
2353
|
-
"tag"?:
|
|
2381
|
+
"tag"?: NativeTypesType;
|
|
2354
2382
|
/**
|
|
2355
2383
|
* Same as original parameter
|
|
2356
2384
|
* @link https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#attr-target
|
|
@@ -2677,6 +2705,10 @@ declare namespace LocalJSX {
|
|
|
2677
2705
|
* Name of the checkbox.
|
|
2678
2706
|
*/
|
|
2679
2707
|
"name"?: string;
|
|
2708
|
+
/**
|
|
2709
|
+
* When you can't use the form label.
|
|
2710
|
+
*/
|
|
2711
|
+
"noLabel"?: boolean;
|
|
2680
2712
|
/**
|
|
2681
2713
|
* Emitted when the checkbox loses focus.
|
|
2682
2714
|
*/
|
|
@@ -3031,6 +3063,12 @@ declare namespace LocalJSX {
|
|
|
3031
3063
|
*/
|
|
3032
3064
|
"wcagOwns"?: string;
|
|
3033
3065
|
}
|
|
3066
|
+
interface GovFormPasswordPower {
|
|
3067
|
+
/**
|
|
3068
|
+
* Password power: 0 - none, 1 - weak, 2 - medium, 3 - strong
|
|
3069
|
+
*/
|
|
3070
|
+
"power"?: number;
|
|
3071
|
+
}
|
|
3034
3072
|
interface GovFormRadio {
|
|
3035
3073
|
/**
|
|
3036
3074
|
* Radio default state
|
|
@@ -3052,6 +3090,10 @@ declare namespace LocalJSX {
|
|
|
3052
3090
|
* Name of the radio.
|
|
3053
3091
|
*/
|
|
3054
3092
|
"name"?: string;
|
|
3093
|
+
/**
|
|
3094
|
+
* When you can't use the form label.
|
|
3095
|
+
*/
|
|
3096
|
+
"noLabel"?: boolean;
|
|
3055
3097
|
/**
|
|
3056
3098
|
* Emitted when the radio loses focus.
|
|
3057
3099
|
*/
|
|
@@ -3174,6 +3216,10 @@ declare namespace LocalJSX {
|
|
|
3174
3216
|
* Name of the switch.
|
|
3175
3217
|
*/
|
|
3176
3218
|
"name"?: string;
|
|
3219
|
+
/**
|
|
3220
|
+
* When you can't use the form label.
|
|
3221
|
+
*/
|
|
3222
|
+
"noLabel"?: boolean;
|
|
3177
3223
|
/**
|
|
3178
3224
|
* Emitted when the switch loses focus.
|
|
3179
3225
|
*/
|
|
@@ -3605,8 +3651,7 @@ declare namespace LocalJSX {
|
|
|
3605
3651
|
}
|
|
3606
3652
|
interface GovTile {
|
|
3607
3653
|
/**
|
|
3608
|
-
*
|
|
3609
|
-
* @link https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#attr-href
|
|
3654
|
+
* Link on whole tile
|
|
3610
3655
|
*/
|
|
3611
3656
|
"href"?: string;
|
|
3612
3657
|
/**
|
|
@@ -3623,6 +3668,10 @@ declare namespace LocalJSX {
|
|
|
3623
3668
|
* Number of columns between 1-4
|
|
3624
3669
|
*/
|
|
3625
3670
|
"columns"?: number;
|
|
3671
|
+
/**
|
|
3672
|
+
* Tiles border
|
|
3673
|
+
*/
|
|
3674
|
+
"noBorder"?: boolean;
|
|
3626
3675
|
}
|
|
3627
3676
|
interface GovToast {
|
|
3628
3677
|
/**
|
|
@@ -3775,6 +3824,7 @@ declare namespace LocalJSX {
|
|
|
3775
3824
|
"gov-form-label": GovFormLabel;
|
|
3776
3825
|
"gov-form-message": GovFormMessage;
|
|
3777
3826
|
"gov-form-multi-select": GovFormMultiSelect;
|
|
3827
|
+
"gov-form-password-power": GovFormPasswordPower;
|
|
3778
3828
|
"gov-form-radio": GovFormRadio;
|
|
3779
3829
|
"gov-form-search": GovFormSearch;
|
|
3780
3830
|
"gov-form-select": GovFormSelect;
|
|
@@ -3837,6 +3887,7 @@ declare module "@stencil/core" {
|
|
|
3837
3887
|
"gov-form-label": LocalJSX.GovFormLabel & JSXBase.HTMLAttributes<HTMLGovFormLabelElement>;
|
|
3838
3888
|
"gov-form-message": LocalJSX.GovFormMessage & JSXBase.HTMLAttributes<HTMLGovFormMessageElement>;
|
|
3839
3889
|
"gov-form-multi-select": LocalJSX.GovFormMultiSelect & JSXBase.HTMLAttributes<HTMLGovFormMultiSelectElement>;
|
|
3890
|
+
"gov-form-password-power": LocalJSX.GovFormPasswordPower & JSXBase.HTMLAttributes<HTMLGovFormPasswordPowerElement>;
|
|
3840
3891
|
"gov-form-radio": LocalJSX.GovFormRadio & JSXBase.HTMLAttributes<HTMLGovFormRadioElement>;
|
|
3841
3892
|
"gov-form-search": LocalJSX.GovFormSearch & JSXBase.HTMLAttributes<HTMLGovFormSearchElement>;
|
|
3842
3893
|
"gov-form-select": LocalJSX.GovFormSelect & JSXBase.HTMLAttributes<HTMLGovFormSelectElement>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const createArrayRange: (from: number, to: number) => number[];
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name" : "@gov-design-system-ce/components",
|
|
3
3
|
"description" : "This package includes Gov Design System Web Components and related utilities.",
|
|
4
4
|
"author": "Zdeněk Vítek",
|
|
5
|
-
"version" : "0.0.
|
|
5
|
+
"version" : "0.0.8",
|
|
6
6
|
"license" : "EUPL v1.2 Licensed",
|
|
7
7
|
"main" : "./dist/index.cjs.js",
|
|
8
8
|
"module" : "./dist/index.js",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"file":"constants-5f6bbc50.js","mappings":";;;;;;MAKa,WAAW,GAAGA,UAAI,CAACC,WAAK,EAAE,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,CAAC,EAAC;MAGpD,cAAc,GAAGD,UAAI,CAACE,iBAAQ,EAAE,CAAC,SAAS,EAAE,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,SAAS,CAAC,EAAC;AAGzFC;AAAZ,WAAY,IAAI;EACf,uBAAe,CAAA;EACf,6BAAqB,CAAA;EACrB,qBAAa,CAAA;AACd,CAAC,EAJWA,YAAI,KAAJA,YAAI,QAIf;AAIWC;AAAZ,WAAY,UAAU;EACrB,+BAAiB,CAAA;EACjB,+BAAiB,CAAA;EACjB,6BAAe,CAAA;AAChB,CAAC,EAJWA,kBAAU,KAAVA,kBAAU,QAIrB;AAID,IAAY,YAIX;AAJD,WAAY,YAAY;EACvB,gCAAgB,CAAA;EAChB,8BAAc,CAAA;EACd,4BAAY,CAAA;AACb,CAAC,EAJW,YAAY,KAAZ,YAAY,QAIvB;MAGY,WAAW,GAAG;EAC1B,IAAI,EAAE,YAAY;EAClB,YAAY,EAAE,oBAAoB;;;;;;;","names":["pick","Sizes","Variants","Type","NativeType"],"sources":["../../../packages/core/src/components/gov-button/constants.ts"],"sourcesContent":["import { Sizes } from '../../core/constants/sizes'\nimport { Variants } from '../../core/constants/variants'\nimport { ValueOf } from '../../types/interfaces'\nimport { pick } from '../../utils/utils'\n\nexport const ButtonSizes = pick(Sizes, ['_S', '_M', '_L', '_XL'])\nexport type ButtonSizesType = `${ValueOf<typeof ButtonSizes>}`\n\nexport const ButtonVariants = pick(Variants, ['PRIMARY', 'SECONDARY', 'SUCCESS', 'ERROR', 'WARNING'])\nexport type ButtonVariantType = `${ValueOf<typeof ButtonVariants>}`\n\nexport enum Type {\n\tSOLID = 'solid',\n\tOUTLINED = 'outlined',\n\tBASE = 'base',\n}\n\nexport type TypesType = `${ValueOf<typeof Type>}`\n\nexport enum NativeType {\n\tSUBMIT = 'submit',\n\tBUTTON = 'button',\n\tRESET = 'reset',\n}\n\nexport type NativeTypesType = `${ValueOf<typeof NativeType>}`\n\nexport enum ButtonTarget {\n\tBLANK = '_blank',\n\tSELF = '_self',\n\tNEW = '_new',\n}\nexport type ButtonTargetType = `${ValueOf<typeof ButtonTarget>}`\n\nexport const ButtonClass = {\n\troot: 'gov-button',\n\trootWithIcon: 'gov-button--w-icon',\n}\n"],"version":3}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"file":"constants-dc2ba6bd.js","mappings":";;;;;AAIYA;AAAZ,WAAY,oBAAoB;EAC/B,qCAAa,CAAA;AACd,CAAC,EAFWA,4BAAoB,KAApBA,4BAAoB,QAE/B;MAGY,eAAe,GAAGC,UAAI,CAACC,iBAAQ,EAAE,CAAC,SAAS,EAAE,WAAW,CAAC,EAAC;MAG1D,aAAa,GAAG;EAC5B,IAAI,EAAE,cAAc;EACpB,OAAO,EAAE,uBAAuB;EAChC;MAEY,iBAAiB,GAAG;EAChC,IAAI,EAAE,mBAAmB;EACzB,IAAI,EAAE,yBAAyB;EAC/B,MAAM,EAAE,2BAA2B;EACnC,IAAI,EAAE,yBAAyB;;;;;;;","names":["StatsBarIconPosition","pick","Variants"],"sources":["../../../packages/core/src/components/gov-statsbar/constants.tsx"],"sourcesContent":["import { ValueOf } from '../../types/interfaces'\nimport { pick } from '../../utils/utils'\nimport { Variants } from '../../core/constants/variants'\n\nexport enum StatsBarIconPosition {\n\tLEFT = 'left',\n}\nexport type StatsBarIconPositionType = `${ValueOf<typeof StatsBarIconPosition>}`\n\nexport const StatsBarVariant = pick(Variants, ['PRIMARY', 'SECONDARY'])\nexport type StatsBarVariantType = `${ValueOf<typeof StatsBarVariant>}`\n\nexport const StatsBarClass = {\n\troot: 'gov-statsbar',\n\tsection: 'gov-statsbar__section',\n}\n\nexport const StatsBarItemClass = {\n\troot: 'gov-statsbar-item',\n\ticon: 'gov-statsbar-item__icon',\n\tnumber: 'gov-statsbar-item__number',\n\ttext: 'gov-statsbar-item__text',\n}\n"],"version":3}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{r as o,c as a,h as e,H as t,g as i}from"./p-682c7cc6.js";import{c as r}from"./p-24636c53.js";import{a as s}from"./p-364b4792.js";import{M as d}from"./p-45485d1c.js";import{c as l}from"./p-c20102ff.js";import{d as n}from"./p-03990da5.js";import{g as m,a as g}from"./p-3f37ddb6.js";import{a as c}from"./p-561fa17b.js";const h='.gov-spin-animation,.gov-pseudo-spin-animation::before{animation:spin 4s linear infinite}@keyframes spin{100%{transform:rotate(360deg)}}@keyframes countdown{to{transform:scaleX(0)}}.gov-modal{display:none}.gov-modal__dialog{z-index:101;position:fixed;top:50%;left:50%;display:flex;justify-content:center;align-items:center;width:100%;max-width:var(--gov-modal-max-width, 52.5rem);height:100%;padding:0.5rem;border:none;background:transparent;transform:translate(-50%, -50%);pointer-events:none}.gov-modal__inner{position:relative;display:flex;flex-direction:column;width:100%;max-height:100%;border-radius:var(--gov-border-radius, 0.1875rem);background:var(--gov-modal-bg, var(--gov-color-neutral-white));overflow:hidden;pointer-events:auto;box-shadow:0 0 1.5rem rgba(var(--gov-color-secondary-800-rgb), 0.24)}.gov-modal__header{display:flex;gap:1rem;align-items:flex-start;padding:1.5rem 0.25rem 1.5rem 1rem;border-bottom:var(--gov-modal-border-color, 0.0625rem solid var(--gov-color-secondary-500))}.gov-modal__icon{flex:0 0 auto;padding-top:calc((var(--gov-text-3xl-font-size) * 1.5 - 1.5rem) / 2)}.gov-modal__icon>*{width:1.5rem;height:1.5rem}.gov-modal__title{font-weight:var(--gov-text-3xl-font-weight);font-size:var(--gov-text-3xl-font-size);line-height:var(--gov-text-3xl-line-height);letter-spacing:var(--gov-text-3xl-letter-spacing);margin:0}.gov-modal__close{flex:0 0 auto;margin-left:auto;padding-top:calc((var(--gov-text-3xl-font-size) * 1.5 - 2rem) / 2)}.gov-modal__content{height:100%;padding:1.5rem 1rem;color:var(--gov-modal-text-color, var(--gov-color-secondary-700));overflow:auto}.gov-modal__content>*:last-child{margin-bottom:0}.gov-modal__actions{display:flex;gap:0.5rem 1rem;flex-wrap:wrap;justify-content:flex-end;padding:1.5rem 1rem;border-top:var(--gov-modal-border-color, 0.0625rem solid var(--gov-color-secondary-500))}.gov-modal__dialog:focus .gov-modal__inner{outline:var(--gov-outline-width, 0.125rem) solid var(--gov-color-focus-base)}.gov-modal[open=""],.gov-modal[open=true i],.gov-modal[open="1"]{display:block}@media (min-width: 30em){.gov-modal__dialog{max-width:calc(var(--gov-modal-max-width, 52.5rem) + 3rem);padding:1.5rem}.gov-modal__dialog:focus{outline-offset:-1.5rem}.gov-modal__inner{box-shadow:0 0 2rem rgba(var(--gov-color-secondary-800-rgb), 0.32)}.gov-modal--prompt .gov-modal__dialog{max-width:calc(var(--gov-modal-prompt-max-width, 33.125rem) + 3rem)}}@media (min-width: 48em){.gov-modal__header{gap:1.25rem;padding:2rem 2.25rem 2rem 3rem}.gov-modal__close{padding-top:calc((var(--gov-text-3xl-font-size) * 1.5 - 2.5rem) / 2)}.gov-modal__content{padding:1.5rem 3rem 2rem}.gov-modal--prompt .gov-modal__header,.gov-modal--prompt .gov-modal__content,.gov-modal--prompt .gov-modal__actions{padding:1.5rem}}';const v=class{constructor(e){o(this,e);this.govClose=a(this,"gov-close",7);this.open=false;this.label=undefined;this.role="dialog";this.labelTag="h2";this.wcaglabelledBy=undefined;this.wcagDescribedBy=undefined;this.wcagCloseLabel=undefined;this.wcagCloseLabelledBy=undefined;this.h=m(this.host);this.labelId=r("GovModalLabel");this.contentId=r("GovModalContent")}validateLabelTag(o){const a=["h1","h2","h3","h4","h5","h6"];if(o){if(!a.includes(o)){c(`[${d.root}]: Tag ${o} is not allowed.`)}}}showModal(){this.open=true;document.body.classList.add(d.bodyFix)}hideModal(){this.open=false;document.body.classList.remove(d.bodyFix)}async componentWillRender(){if(this.open){this.showModal()}else{this.hideModal()}}async componentDidRender(){if(l()){await n(500);await this.validateWcag()}}render(){const o=this.labelTag;return e(t,{class:this.h.classes(d.root),open:this.open},e("dialog",{class:d.dialog,hidden:!this.open,tabindex:"-1",open:this.open,"aria-modal":"true","aria-hidden":g(!this.open),"aria-labelledby":this.wcaglabelledBy||this.labelId,"aria-describedby":this.wcagDescribedBy||this.contentId,role:this.role},e("div",{class:d.inner},e("div",{class:d.header},this.h.hasSlot("icon")&&e("div",{class:d.icon},e("slot",{name:"icon"})),this.label&&e(o,{class:d.title,id:this.labelId},this.label),e("gov-button",{class:d.close,variant:"primary",wcagLabel:this.wcagCloseLabel,wcagLabelledBy:this.wcagCloseLabelledBy,type:"base","on-gov-click":this.onCloseHandler.bind(this)},e("gov-icon",{name:"cross"}))),e("div",{class:d.content,id:this.contentId},e("slot",null)))),e("gov-backdrop",{visible:this.open,"wcag-label":this.wcagCloseLabel,"wcag-labelled-by":this.wcagCloseLabelledBy,"on-gov-click":this.onCloseHandler.bind(this)}))}onCloseHandler(o){o.stopPropagation();this.hideModal();this.govClose.emit(o)}async show(){this.showModal()}async hide(){this.hideModal()}async validateWcag(){s(this.wcaglabelledBy,"aria-labelledby",d.root);s(this.wcagDescribedBy,"aria-describedby",d.root)}get host(){return i(this)}static get watchers(){return{labelTag:["validateLabelTag"]}}};v.style=h;export{v as gov_modal};
|
|
2
|
-
//# sourceMappingURL=p-00182e76.entry.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../packages/core/src/components/gov-modal/gov-modal.scss?tag=gov-modal","../../../packages/core/src/components/gov-modal/gov-modal.tsx"],"names":["govModalCss","GovModal","[object Object]","hostRef","this","h","govHost","host","labelId","createID","contentId","newValue","validTags","includes","govErrorLog","ModalClass","root","open","document","body","classList","add","bodyFix","remove","showModal","hideModal","canValidateWcagOnRender","delay","validateWcag","LabelTag","labelTag","Host","class","classes","dialog","hidden","tabindex","aria-modal","aria-hidden","toBoolAttr","aria-labelledby","wcaglabelledBy","aria-describedby","wcagDescribedBy","role","inner","header","hasSlot","icon","name","label","title","id","close","variant","wcagLabel","wcagCloseLabel","wcagLabelledBy","wcagCloseLabelledBy","type","on-gov-click","onCloseHandler","bind","content","visible","wcag-label","wcag-labelled-by","e","stopPropagation","govClose","emit","validateWcagRef"],"mappings":"mUAAA,MAAMA,EAAc,4sFCePC,EAAQ,MAKpBC,YAAAC,2DAWe,qCAQqB,uBAI0B,mIAtB7DC,KAAKC,EAAIC,EAAQF,KAAKG,MACtBH,KAAKI,QAAUC,EAAS,iBACxBL,KAAKM,UAAYD,EAAS,mBA2C3BP,iBAAiBS,GAChB,MAAMC,EAAY,CAAC,KAAM,KAAM,KAAM,KAAM,KAAM,MACjD,GAAID,EAAU,CACb,IAAKC,EAAUC,SAASF,GAAW,CAClCG,EAAY,IAAIC,EAAWC,cAAcL,uBAKpCT,YACPE,KAAKa,KAAO,KACZC,SAASC,KAAKC,UAAUC,IAAIN,EAAWO,SAGhCpB,YACPE,KAAKa,KAAO,MACZC,SAASC,KAAKC,UAAUG,OAAOR,EAAWO,SAG3CpB,4BACC,GAAIE,KAAKa,KAAM,CACdb,KAAKoB,gBACC,CACNpB,KAAKqB,aAIPvB,2BACC,GAAIwB,IAA2B,OACxBC,EAAM,WACNvB,KAAKwB,gBAIb1B,SACC,MAAM2B,EAAWzB,KAAK0B,SACtB,OACCzB,EAAC0B,EAAI,CAACC,MAAO5B,KAAKC,EAAE4B,QAAQlB,EAAWC,MAAOC,KAAMb,KAAKa,MACxDZ,EAAA,SAAA,CACC2B,MAAOjB,EAAWmB,OAClBC,QAAS/B,KAAKa,KACdmB,SAAS,KACTnB,KAAMb,KAAKa,KAAIoB,aACJ,OAAMC,cACJC,GAAYnC,KAAKa,MAAKuB,kBAClBpC,KAAKqC,gBAAkBrC,KAAKI,QAAOkC,mBAClCtC,KAAKuC,iBAAmBvC,KAAKM,UAC/CkC,KAAMxC,KAAKwC,MAEXvC,EAAA,MAAA,CAAK2B,MAAOjB,EAAW8B,OACtBxC,EAAA,MAAA,CAAK2B,MAAOjB,EAAW+B,QACrB1C,KAAKC,EAAE0C,QAAQ,SACf1C,EAAA,MAAA,CAAK2B,MAAOjB,EAAWiC,MACtB3C,EAAA,OAAA,CAAM4C,KAAK,UAGZ7C,KAAK8C,OACL7C,EAACwB,EAAQ,CAACG,MAAOjB,EAAWoC,MAAOC,GAAIhD,KAAKI,SAC1CJ,KAAK8C,OAGR7C,EAAA,aAAA,CACC2B,MAAOjB,EAAWsC,MAClBC,QAAQ,UACRC,UAAWnD,KAAKoD,eAChBC,eAAgBrD,KAAKsD,oBACrBC,KAAK,OAAMC,eACGxD,KAAKyD,eAAeC,KAAK1D,OAEvCC,EAAA,WAAA,CAAU4C,KAAK,YAGjB5C,EAAA,MAAA,CAAK2B,MAAOjB,EAAWgD,QAASX,GAAIhD,KAAKM,WACxCL,EAAA,OAAA,SAKHA,EAAA,eAAA,CACC2D,QAAS5D,KAAKa,KAAIgD,aACN7D,KAAKoD,eAAcU,mBACb9D,KAAKsD,oBAAmBE,eAC5BxD,KAAKyD,eAAeC,KAAK1D,SAMnCF,eAAeiE,GACtBA,EAAEC,kBACFhE,KAAKqB,YACLrB,KAAKiE,SAASC,KAAKH,GAOpBjE,aACCE,KAAKoB,YAONtB,aACCE,KAAKqB,YAONvB,qBACCqE,EAAgBnE,KAAKqC,eAAgB,kBAAmB1B,EAAWC,MACnEuD,EAAgBnE,KAAKuC,gBAAiB,mBAAoB5B,EAAWC","sourcesContent":["/*\n * Modal\n */\n\n$class: \".gov-modal\";\n\n#{$class} {\n\tdisplay: none;\n\t&__dialog {\n\t\t@include z-index(\"modal\", 1);\n\t\tposition: fixed;\n\t\ttop: 50%;\n\t\tleft: 50%;\n\t\tdisplay: flex;\n\t\tjustify-content: center;\n\t\talign-items: center;\n\t\twidth: 100%;\n\t\tmax-width: $modal-max-width;\n\t\theight: 100%;\n\t\tpadding: rem-calc(8);\n\t\tborder: none;\n\t\tbackground: transparent;\n\t\ttransform: translate(-50%, -50%);\n\t\tpointer-events: none;\n\t}\n\t&__inner {\n\t\tposition: relative;\n\t\tdisplay: flex;\n\t\tflex-direction: column;\n\t\twidth: 100%;\n\t\tmax-height: 100%;\n\t\tborder-radius: $border-radius;\n\t\tbackground: $modal-bg;\n\t\toverflow: hidden;\n\t\tpointer-events: auto;\n\t\tbox-shadow: get($shadow-l, $shadows);\n\t}\n\t&__header {\n\t\tdisplay: flex;\n\t\tgap: rem-calc(16);\n\t\talign-items: flex-start;\n\t\tpadding: rem-calc(24 4 24 16);\n\t\tborder-bottom: $modal-border;\n\t}\n\t&__icon {\n\t\tflex: 0 0 auto;\n\t\tpadding-top: calc(((var(--gov-text-#{$font-size-3xl}-font-size) * 1.5) - rem-calc(24)) / 2);\n\t\t& > * {\n\t\t\twidth: rem-calc(24);\n\t\t\theight: rem-calc(24);\n\t\t}\n\t}\n\t&__title {\n\t\t@include typography($font-size-3xl);\n\t\tmargin: 0;\n\t}\n\t&__close {\n\t\tflex: 0 0 auto;\n\t\tmargin-left: auto;\n\t\tpadding-top: calc(((var(--gov-text-#{$font-size-3xl}-font-size) * 1.5) - rem-calc(32)) / 2);\n\t}\n\t&__content {\n\t\t@include reset-last-margin();\n\t\theight: 100%;\n\t\tpadding: rem-calc(24 16);\n\t\tcolor: $modal-text-color;\n\t\toverflow: auto;\n\t}\n\t&__actions {\n\t\tdisplay: flex;\n\t\tgap: rem-calc(8 16);\n\t\tflex-wrap: wrap;\n\t\tjustify-content: flex-end;\n\t\tpadding: rem-calc(24 16);\n\t\tborder-top: $modal-border;\n\t}\n\n\t// STATES\n\t&__dialog:focus &__inner {\n\t\toutline: $outline;\n\t}\n\t@include parameter(\"open\") {\n\t\tdisplay: block;\n\t}\n\n\t// MQ\n\t@include mq($from: sm) {\n\t\t&__dialog {\n\t\t\tmax-width: calc($modal-max-width + 2 * rem-calc(24));\n\t\t\tpadding: rem-calc(24);\n\t\t\t&:focus {\n\t\t\t\toutline-offset: rem-calc(-24);\n\t\t\t}\n\t\t}\n\t\t&__inner {\n\t\t\tbox-shadow: get($shadow-xl, $shadows);\n\t\t}\n\n\t\t// VARIANTS\n\t\t&--prompt &__dialog {\n\t\t\tmax-width: calc($modal-prompt-max-width + 2 * rem-calc(24));\n\t\t}\n\t}\n\t@include mq($from: md) {\n\t\t&__header {\n\t\t\tgap: rem-calc(20);\n\t\t\tpadding: rem-calc(32 36 32 48);\n\t\t}\n\t\t&__close {\n\t\t\tpadding-top: calc(((var(--gov-text-#{$font-size-3xl}-font-size) * 1.5) - rem-calc(40)) / 2);\n\t\t}\n\t\t&__content {\n\t\t\tpadding: rem-calc(24 48 32);\n\t\t}\n\n\t\t// VARIANTS\n\t\t&--prompt {\n\t\t\t#{$class} {\n\t\t\t\t&__header,\n\t\t\t\t&__content,\n\t\t\t\t&__actions {\n\t\t\t\t\tpadding: rem-calc(24);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n}\n","import { Component, Event, Element, EventEmitter, h, Host, Method, Prop, Watch } from '@stencil/core'\nimport { createID } from '../../utils/string.utils'\nimport { validateWcagRef } from '../../helpers/Validate/wcag'\nimport { ModalClass } from './constants'\nimport { canValidateWcagOnRender } from '../../helpers/Dom/win'\nimport { delay } from '../../utils/utils'\nimport { toBoolAttr } from '../../helpers/Dom/template'\nimport { govHost } from '../../helpers/Dom/template'\nimport { GovHost } from '../../helpers/Dom/template.types'\nimport { govErrorLog } from '../../helpers/Log/gov.log'\n\n@Component({\n\ttag: 'gov-modal',\n\tstyleUrl: 'gov-modal.scss',\n})\nexport class GovModal {\n\tprivate h: GovHost\n\tprivate readonly labelId: string\n\tprivate readonly contentId: string\n\n\tconstructor() {\n\t\tthis.h = govHost(this.host)\n\t\tthis.labelId = createID('GovModalLabel')\n\t\tthis.contentId = createID('GovModalContent')\n\t}\n\n\t@Element() host: HTMLGovModalElement\n\n\t/**\n\t * Attribute for modal window display\n\t */\n\t@Prop() open = false\n\t/**\n\t * Title of modal window\n\t */\n\t@Prop() label: string\n\t/**\n\t * Role of modal\n\t */\n\t@Prop({ attribute: 'role' }) role = 'dialog'\n\t/**\n\t * Used to change the HMTL tag in the modal label for correct semantic structure\n\t */\n\t@Prop({ attribute: 'label-tag' }) readonly labelTag: string = 'h2'\n\t/**\n\t * String of id's that indicate alternative labels elements\n\t */\n\t@Prop({ attribute: 'wcag-labelled-by' }) wcaglabelledBy: string\n\t/**\n\t * Indicates the id of a component that describes the modal.\n\t */\n\t@Prop({ attribute: 'wcag-described-by' }) wcagDescribedBy: string\n\t/**\n\t * Adds accessible label for the modal close button that is only shown for screen readers.\n\t */\n\t@Prop({ attribute: 'wcag-close-label' }) wcagCloseLabel: string\n\t/**\n\t * A string of identifiers that indicate alternative label elements for closing the modal window\n\t */\n\t@Prop({ attribute: 'wcag-close-labelled-by' }) wcagCloseLabelledBy: string\n\t/**\n\t * Emitted when modal window closes.\n\t */\n\t@Event({ eventName: 'gov-close' }) govClose: EventEmitter<PointerEvent>\n\n\t@Watch('labelTag')\n\tvalidateLabelTag(newValue: string): void {\n\t\tconst validTags = ['h1', 'h2', 'h3', 'h4', 'h5', 'h6']\n\t\tif (newValue) {\n\t\t\tif (!validTags.includes(newValue)) {\n\t\t\t\tgovErrorLog(`[${ModalClass.root}]: Tag ${newValue} is not allowed.`)\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate showModal() {\n\t\tthis.open = true\n\t\tdocument.body.classList.add(ModalClass.bodyFix)\n\t}\n\n\tprivate hideModal() {\n\t\tthis.open = false\n\t\tdocument.body.classList.remove(ModalClass.bodyFix)\n\t}\n\n\tasync componentWillRender() {\n\t\tif (this.open) {\n\t\t\tthis.showModal()\n\t\t} else {\n\t\t\tthis.hideModal()\n\t\t}\n\t}\n\n\tasync componentDidRender() {\n\t\tif (canValidateWcagOnRender()) {\n\t\t\tawait delay(500)\n\t\t\tawait this.validateWcag()\n\t\t}\n\t}\n\n\trender() {\n\t\tconst LabelTag = this.labelTag\n\t\treturn (\n\t\t\t<Host class={this.h.classes(ModalClass.root)} open={this.open}>\n\t\t\t\t<dialog\n\t\t\t\t\tclass={ModalClass.dialog}\n\t\t\t\t\thidden={!this.open}\n\t\t\t\t\ttabindex=\"-1\"\n\t\t\t\t\topen={this.open}\n\t\t\t\t\taria-modal=\"true\"\n\t\t\t\t\taria-hidden={toBoolAttr(!this.open)}\n\t\t\t\t\taria-labelledby={this.wcaglabelledBy || this.labelId}\n\t\t\t\t\taria-describedby={this.wcagDescribedBy || this.contentId}\n\t\t\t\t\trole={this.role}\n\t\t\t\t>\n\t\t\t\t\t<div class={ModalClass.inner}>\n\t\t\t\t\t\t<div class={ModalClass.header}>\n\t\t\t\t\t\t\t{this.h.hasSlot('icon') && (\n\t\t\t\t\t\t\t\t<div class={ModalClass.icon}>\n\t\t\t\t\t\t\t\t\t<slot name=\"icon\" />\n\t\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t{this.label && (\n\t\t\t\t\t\t\t\t<LabelTag class={ModalClass.title} id={this.labelId}>\n\t\t\t\t\t\t\t\t\t{this.label}\n\t\t\t\t\t\t\t\t</LabelTag>\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t<gov-button\n\t\t\t\t\t\t\t\tclass={ModalClass.close}\n\t\t\t\t\t\t\t\tvariant=\"primary\"\n\t\t\t\t\t\t\t\twcagLabel={this.wcagCloseLabel}\n\t\t\t\t\t\t\t\twcagLabelledBy={this.wcagCloseLabelledBy}\n\t\t\t\t\t\t\t\ttype=\"base\"\n\t\t\t\t\t\t\t\ton-gov-click={this.onCloseHandler.bind(this)}\n\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t<gov-icon name=\"cross\" />\n\t\t\t\t\t\t\t</gov-button>\n\t\t\t\t\t\t</div>\n\t\t\t\t\t\t<div class={ModalClass.content} id={this.contentId}>\n\t\t\t\t\t\t\t<slot />\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</div>\n\t\t\t\t</dialog>\n\n\t\t\t\t<gov-backdrop\n\t\t\t\t\tvisible={this.open}\n\t\t\t\t\twcag-label={this.wcagCloseLabel}\n\t\t\t\t\twcag-labelled-by={this.wcagCloseLabelledBy}\n\t\t\t\t\ton-gov-click={this.onCloseHandler.bind(this)}\n\t\t\t\t/>\n\t\t\t</Host>\n\t\t)\n\t}\n\n\tprivate onCloseHandler(e: PointerEvent) {\n\t\te.stopPropagation()\n\t\tthis.hideModal()\n\t\tthis.govClose.emit(e)\n\t}\n\n\t/**\n\t * Showing the modal\n\t */\n\t@Method()\n\tasync show(): Promise<void> {\n\t\tthis.showModal()\n\t}\n\n\t/**\n\t * Hidding the modal\n\t */\n\t@Method()\n\tasync hide(): Promise<void> {\n\t\tthis.hideModal()\n\t}\n\n\t/**\n\t * Validate the WCAG attributes of the component\n\t */\n\t@Method()\n\tasync validateWcag(): Promise<void> {\n\t\tvalidateWcagRef(this.wcaglabelledBy, 'aria-labelledby', ModalClass.root)\n\t\tvalidateWcagRef(this.wcagDescribedBy, 'aria-describedby', ModalClass.root)\n\t}\n}\n"]}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{r as i,c as t,h as a,H as n,g as e}from"./p-682c7cc6.js";import{v as o}from"./p-26acf964.js";import{S as s}from"./p-55500e5a.js";import{V as r}from"./p-ff7365ae.js";import{p as g,d as l}from"./p-03990da5.js";import{g as c,p,t as v}from"./p-3f37ddb6.js";import{c as h,v as m}from"./p-364b4792.js";import{c as d}from"./p-c20102ff.js";import{c as f}from"./p-24636c53.js";import"./p-561fa17b.js";const _=(i,t)=>[...t];const u=g(s,["_S","_M"]);const b=g(r,["PRIMARY","SECONDARY"]);var w;(function(i){i["BUTTON"]="button";i["SELECT"]="select"})(w||(w={}));const y={root:"gov-pagination",list:"gov-pagination__list",item:"gov-pagination__item",itemArrow:"gov-pagination__item--arrow",itemMore:"gov-pagination__item--more",itemSelect:"gov-pagination__item--select",inner:"gov-pagination__inner",arrow:"gov-pagination__arrow"};function x(i,t=1,a=10,n=10){const e=Math.ceil(i/a);if(t<1){t=1}else if(t>e){t=e}let o,s;if(e<=n){o=1;s=e}else{const i=Math.floor(n/2);const a=Math.ceil(n/2)-1;if(t<=i){o=1;s=n}else if(t+a>=e){o=e-n+1;s=e}else{o=t-i;s=t+a}}const r=(t-1)*a;const g=Math.min(r+a-1,i-1);const l=Array.from(Array(s+1-o).keys()).map((i=>o+i));return{totalItems:i,currentPage:t,pageSize:a,totalPages:e,startPage:o,endPage:s,startIndex:r,endIndex:g,pages:l}}const z=".gov-pagination__list{margin:0;padding:0}.gov-pagination__list .gov-pagination__item{margin:0;padding:0;background:none}.gov-pagination__list .gov-pagination__item::before{display:none}.gov-spin-animation,.gov-pseudo-spin-animation::before{animation:spin 4s linear infinite}@keyframes spin{100%{transform:rotate(360deg)}}@keyframes countdown{to{transform:scaleX(0)}}.gov-pagination{position:relative;display:block;width:100%}.gov-pagination__list{display:flex;align-items:center;font-weight:bold;text-align:center}.gov-pagination__list .gov-pagination__item{display:flex;justify-content:center;align-items:center;margin:0;border-radius:var(--gov-border-radius, 0.1875rem);overflow:hidden}.gov-pagination__list .gov-pagination__item--arrow{display:flex}.gov-pagination__list .gov-pagination__item--select{z-index:1;display:flex;overflow:visible;padding:0rem 1rem}.gov-pagination__item .gov-button .element{width:var(--gov-pagination-button-size, 2rem)}.gov-pagination__arrow{margin:0}.gov-pagination__item--more .gov-form-select select{border:none;padding-right:0.75rem !important}.gov-pagination__item--more .gov-form-select .gov-icon{display:none}.gov-pagination__inner{display:flex;justify-content:center;align-items:center;align-self:stretch;width:100%;color:var(--gov-pagination-color, var(--gov-color-primary));text-decoration:none}.gov-pagination button.gov-pagination__inner,.gov-pagination a.gov-pagination__inner{display:inline-flex;vertical-align:middle;justify-content:center;align-items:center;border:0;background-color:transparent;text-align:center;text-decoration:none;cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none;transition:background-color 150ms, color 150ms}.gov-pagination button.gov-pagination__inner:focus,.gov-pagination a.gov-pagination__inner:focus{outline:none}@media not all and (pointer: coarse){.gov-pagination button.gov-pagination__inner:hover,.gov-pagination a.gov-pagination__inner:hover{background-color:var(--gov-pagination-bg-active, var(--gov-color-primary-100));color:var(--gov-pagination-color-active, var(--gov-color-secondary))}}.gov-pagination[size=s] .gov-pagination__inner{font-weight:var(--gov-text-s-font-weight);font-size:var(--gov-text-s-font-size);line-height:var(--gov-text-s-line-height);letter-spacing:var(--gov-text-s-letter-spacing);font-weight:inherit}@media (min-width: 48em){.gov-pagination[size=s] .gov-pagination__item .gov-button .element{width:var(--gov-pagination-s-button-size, 2rem)}}.gov-pagination[size=m] .gov-pagination__inner{font-weight:var(--gov-text-m-font-weight);font-size:var(--gov-text-m-font-size);line-height:var(--gov-text-m-line-height);letter-spacing:var(--gov-text-m-letter-spacing);font-weight:inherit}@media (min-width: 48em){.gov-pagination[size=m] .gov-pagination__item .gov-button .element{width:var(--gov-pagination-m-button-size, 2.5rem)}}";const j=class{constructor(a){i(this,a);this.govPage=t(this,"gov-page",7);this.type="button";this.current=1;this.total=undefined;this.inverse=undefined;this.size="m";this.variant="primary";this.pageSize=10;this.maxPages=5;this.link=undefined;this.wcagLabel=undefined;this.wcagLabelledBy=undefined;this.wcagSelectLabel="Vybrat stranu";this.wcagPageLabel="Strana";this.pagination=undefined;this.h=c(this.host);this.pageSelectId=f("GovPageSelect")}validateType(i){o(w,i,y.root)}validateSize(i){o(u,i,y.root)}validateVariant(i){o(b,i,y.root)}componentWillLoad(){this.recalculatePagination(this.current);this.validateSize(this.size);this.validateVariant(this.variant)}async componentDidRender(){if(d()){await l(500);await this.validateWcag()}}recalculatePagination(i){this.pagination=x(this.total,i,this.pageSize,this.maxPages)}isActivePageClass(i,t){if(this.pagination.currentPage===t){return i+" is-active"}else{return i}}render(){const i=(i,t)=>{const n=i===-1;const e=v(this.pagination.currentPage===i?true:undefined);const o=this.pagination.currentPage===i?"solid":"base";return a("gov-button",{variant:this.variant,size:this.size,type:o,inverse:this.pagination.currentPage===i?true:false,disabled:n,"gov-click":()=>this.onClickHandler(i),"wcag-label":this.wcagPageLabel+" "+i,"wcag-current":e,class:y.inner},t)};return a(n,{class:this.h.classes(y.root),type:this.type,variant:this.variant,size:this.size},a("nav",{"aria-label":this.wcagLabel,"aria-labelledby":this.wcagLabelledBy},a("ul",{class:y.list},a("li",{class:p([y.item,y.itemArrow])},i(this.pagination.startPage<this.pagination.currentPage?this.pagination.currentPage-1:-1,a("gov-icon",{class:y.arrow,name:"double-arrow-left"}))),a("li",{class:p([y.item,y.itemArrow])},i(this.pagination.startPage<this.pagination.currentPage?this.pagination.currentPage-1:-1,a("gov-icon",{class:y.arrow,name:"arrow-left"}))),this.type=="select"?a("li",{class:p([y.item,y.itemSelect])},a("span",{class:y.inner},a("span",{id:this.pageSelectId,hidden:true},this.wcagSelectLabel),a("gov-form-select",{size:"m","wcag-labelled-by":this.pageSelectId},this.pagination.pages.map((i=>a("option",{value:i,selected:this.pagination.currentPage===i},i)))))):a(_,null,this.pagination.pages.map((t=>a("li",{class:this.isActivePageClass(y.item,t)},i(t,t)))),a("li",{class:p([y.item,y.itemMore])},a("span",{class:y.inner},a("span",{id:this.pageSelectId,hidden:true},this.wcagSelectLabel),a("gov-form-select",{size:"m","wcag-labelled-by":this.pageSelectId},a("option",{value:"..."},"..."),this.pagination.pages.map((i=>a("option",{value:i,selected:this.pagination.currentPage===i},i))))))),a("li",{class:p([y.item,y.itemArrow])},i(this.pagination.totalPages>this.pagination.currentPage?this.pagination.currentPage+1:-1,a("gov-icon",{class:y.arrow,name:"arrow-right"}))),a("li",{class:p([y.item,y.itemArrow])},i(this.pagination.totalPages>this.pagination.currentPage?this.pagination.totalPages:-1,a("gov-icon",{class:y.arrow,name:"double-arrow-right"}))))))}onClickHandler(i){this.recalculatePagination(i);this.govPage.emit(Object.assign({},this.pagination))}async validateWcag(){h(this.wcagPageLabel,"wcag-page-label",y.root);h(this.wcagSelectLabel,"wcag-select-label",y.root);m(this.wcagLabel,this.wcagLabelledBy,y.root)}get host(){return e(this)}static get watchers(){return{type:["validateType"],size:["validateSize"],variant:["validateVariant"]}}};j.style=z;export{j as gov_pagination};
|
|
2
|
-
//# sourceMappingURL=p-0278fcb3.entry.js.map
|