genesys-spark-components 4.0.0-beta.26 → 4.0.0-beta.28
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/genesys-webcomponents.cjs.js +1 -1
- package/dist/cjs/gux-accordion-section.cjs.entry.js +1 -1
- package/dist/cjs/gux-accordion.cjs.entry.js +1 -1
- package/dist/cjs/gux-action-button.cjs.entry.js +1 -1
- package/dist/cjs/gux-action-toast-legacy.cjs.entry.js +2 -2
- package/dist/cjs/gux-advanced-dropdown-legacy.cjs.entry.js +218 -0
- package/dist/cjs/gux-announce-beta.cjs.entry.js +1 -1
- package/dist/cjs/gux-badge.cjs.entry.js +1 -1
- package/dist/cjs/gux-blank-state.cjs.entry.js +1 -1
- package/dist/cjs/gux-breadcrumbs.cjs.entry.js +1 -1
- package/dist/cjs/gux-button-multi.cjs.entry.js +2 -3
- package/dist/cjs/gux-button-slot.cjs.entry.js +2 -2
- package/dist/cjs/gux-button.cjs.entry.js +2 -2
- package/dist/cjs/gux-calendar.cjs.entry.js +1 -1
- package/dist/cjs/gux-card.cjs.entry.js +1 -1
- package/dist/cjs/gux-column-manager-item.cjs.entry.js +1 -1
- package/dist/cjs/gux-column-manager.cjs.entry.js +1 -1
- package/dist/cjs/gux-content-search.cjs.entry.js +1 -1
- package/dist/cjs/gux-context-menu.cjs.entry.js +1 -1
- package/dist/cjs/gux-copy-to-clipboard.cjs.entry.js +1 -1
- package/dist/cjs/gux-date-beta.cjs.entry.js +1 -1
- package/dist/cjs/gux-date-time-beta.cjs.entry.js +1 -1
- package/dist/cjs/gux-datepicker.cjs.entry.js +1 -1
- package/dist/cjs/gux-disclosure-button-legacy.cjs.entry.js +1 -1
- package/dist/cjs/gux-dismiss-button.cjs.entry.js +1 -1
- package/dist/cjs/gux-dropdown-multi-beta.cjs.entry.js +1 -1
- package/dist/cjs/gux-dropdown-option.cjs.entry.js +1 -1
- package/dist/cjs/gux-dropdown_3.cjs.entry.js +1 -1
- package/dist/cjs/gux-flyout-menu-beta.cjs.entry.js +1 -1
- package/dist/cjs/gux-form-field-checkbox.cjs.entry.js +1 -1
- package/dist/cjs/gux-form-field-color.cjs.entry.js +1 -1
- package/dist/cjs/gux-form-field-dropdown.cjs.entry.js +1 -1
- package/dist/cjs/gux-form-field-input-clear-button.cjs.entry.js +1 -1
- package/dist/cjs/gux-form-field-number_3.cjs.entry.js +2 -2
- package/dist/cjs/gux-form-field-phone.cjs.entry.js +1 -1
- package/dist/cjs/gux-form-field-radio.cjs.entry.js +1 -1
- package/dist/cjs/gux-form-field-range.cjs.entry.js +2 -2
- package/dist/cjs/gux-form-field-search.cjs.entry.js +1 -1
- package/dist/cjs/gux-form-field-select.cjs.entry.js +1 -1
- package/dist/cjs/gux-form-field-text-like.cjs.entry.js +2 -2
- package/dist/cjs/gux-form-field-textarea.cjs.entry.js +2 -2
- package/dist/cjs/gux-form-field-time-picker.cjs.entry.js +1 -1
- package/dist/cjs/gux-icon.cjs.entry.js +1 -1
- package/dist/cjs/gux-inline-alert.cjs.entry.js +1 -1
- package/dist/cjs/gux-list-item.cjs.entry.js +1 -1
- package/dist/cjs/gux-list.cjs.entry.js +1 -1
- package/dist/cjs/gux-listbox-multi.cjs.entry.js +1 -1
- package/dist/cjs/gux-loading-message.cjs.entry.js +3 -47
- package/dist/cjs/gux-modal.cjs.entry.js +1 -1
- package/dist/cjs/gux-month-picker-beta.cjs.entry.js +1 -1
- package/dist/cjs/gux-notification-toast-legacy.cjs.entry.js +2 -2
- package/dist/cjs/gux-page-loading-spinner.cjs.entry.js +1 -1
- package/dist/cjs/{gux-pagination-buttons-beta_2.cjs.entry.js → gux-pagination-buttons_3.cjs.entry.js} +49 -11
- package/dist/cjs/gux-pagination-cursor.cjs.entry.js +1 -1
- package/dist/cjs/gux-pagination-legacy.cjs.entry.js +1 -1
- package/dist/cjs/{gux-pagination-beta.cjs.entry.js → gux-pagination.cjs.entry.js} +6 -6
- package/dist/cjs/gux-phone-input-beta.cjs.entry.js +1 -1
- package/dist/cjs/gux-popover-list.cjs.entry.js +2 -2
- package/dist/cjs/gux-popup.cjs.entry.js +1 -1
- package/dist/cjs/gux-radial-loading.cjs.entry.js +1 -1
- package/dist/cjs/gux-radial-progress.cjs.entry.js +1 -1
- package/dist/cjs/gux-rating.cjs.entry.js +1 -1
- package/dist/cjs/gux-region-icon.cjs.entry.js +1 -1
- package/dist/cjs/gux-screen-reader-beta.cjs.entry.js +1 -1
- package/dist/cjs/gux-simple-toast-legacy.cjs.entry.js +1 -1
- package/dist/cjs/gux-skip-navigation-item.cjs.entry.js +1 -1
- package/dist/cjs/gux-skip-navigation-list.cjs.entry.js +1 -1
- package/dist/cjs/gux-sort-control.cjs.entry.js +1 -1
- package/dist/cjs/gux-switch-item.cjs.entry.js +1 -1
- package/dist/cjs/gux-switch.cjs.entry.js +2 -2
- package/dist/cjs/gux-tab-panel.cjs.entry.js +2 -2
- package/dist/cjs/gux-table-select-menu.cjs.entry.js +1 -1
- package/dist/cjs/gux-table-toolbar-action.cjs.entry.js +1 -1
- package/dist/cjs/gux-table-toolbar-custom-action.cjs.entry.js +1 -1
- package/dist/cjs/gux-table-toolbar-menu-button.cjs.entry.js +1 -1
- package/dist/cjs/gux-table-toolbar.cjs.entry.js +1 -1
- package/dist/cjs/gux-table.cjs.entry.js +2 -2
- package/dist/cjs/gux-tabs-advanced.cjs.entry.js +1 -1
- package/dist/cjs/gux-tabs.cjs.entry.js +1 -1
- package/dist/cjs/gux-tag.cjs.entry.js +80 -0
- package/dist/cjs/gux-text-highlight.cjs.entry.js +1 -1
- package/dist/cjs/gux-time-beta.cjs.entry.js +1 -1
- package/dist/cjs/gux-time-picker.cjs.entry.js +1 -1
- package/dist/cjs/gux-time-zone-picker-beta.cjs.entry.js +1 -1
- package/dist/cjs/gux-toast.cjs.entry.js +1 -1
- package/dist/cjs/gux-toggle-slider.cjs.entry.js +1 -1
- package/dist/cjs/gux-toggle.cjs.entry.js +2 -2
- package/dist/cjs/gux-tooltip.cjs.entry.js +1 -1
- package/dist/cjs/index-0d0fdb85.js +8 -16
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/{usage-fcdc9156.js → usage-5e9eafc4.js} +1 -1
- package/dist/collection/collection-manifest.json +11 -12
- package/dist/collection/components/legacy/gux-action-toast-legacy/gux-action-toast.css +44 -30
- package/dist/collection/components/{stable/gux-advanced-dropdown → legacy/gux-advanced-dropdown-legacy}/dropdown-option/gux-dropdown-option.css +3 -4
- package/dist/collection/components/{stable/gux-advanced-dropdown → legacy/gux-advanced-dropdown-legacy}/dropdown-option/gux-dropdown-option.js +1 -1
- package/dist/collection/components/legacy/gux-advanced-dropdown-legacy/gux-advanced-dropdown.css +253 -0
- package/dist/collection/components/{stable/gux-advanced-dropdown → legacy/gux-advanced-dropdown-legacy}/gux-advanced-dropdown.js +4 -4
- package/dist/collection/components/legacy/gux-notification-toast-legacy/gux-notification-toast.css +44 -30
- package/dist/collection/components/stable/gux-accordion/gux-accordion-section/gux-accordion-section.css +65 -45
- package/dist/collection/components/stable/gux-button/gux-button.css +43 -3
- package/dist/collection/components/stable/gux-button-multi/gux-button-multi.js +1 -19
- package/dist/collection/components/stable/gux-button-slot/gux-button-slot.css +43 -3
- package/dist/collection/components/stable/gux-column-manager/gux-column-manager-item/gux-column-manager-item.css +47 -32
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-range/gux-form-field-range.css +44 -30
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-text-like/gux-form-field-text-like.css +65 -45
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-textarea/gux-form-field-textarea.css +65 -45
- package/dist/collection/components/stable/gux-list/gux-list-divider/gux-list-divider.css +1 -1
- package/dist/collection/components/stable/gux-list/gux-list-divider/gux-list-divider.js +1 -1
- package/dist/collection/components/stable/gux-list/gux-list-item/gux-list-item.css +27 -15
- package/dist/collection/components/stable/gux-list/gux-list-item/gux-list-item.js +1 -1
- package/dist/collection/components/stable/gux-list/gux-list.css +1 -1
- package/dist/collection/components/stable/gux-list/gux-list.js +1 -1
- package/dist/collection/components/stable/gux-loading-message/gux-loading-message.css +87 -192
- package/dist/collection/components/stable/gux-loading-message/gux-loading-message.js +2 -49
- package/dist/collection/components/{beta/gux-pagination-beta/gux-pagination-buttons-beta/gux-pagination-buttons-beta.css → stable/gux-pagination/gux-pagination-buttons/gux-pagination-buttons.css} +11 -11
- package/dist/collection/components/{beta/gux-pagination-beta/gux-pagination-buttons-beta/gux-pagination-buttons-beta.js → stable/gux-pagination/gux-pagination-buttons/gux-pagination-buttons.js} +8 -8
- package/dist/collection/components/{beta/gux-pagination-beta/gux-pagination-item-counts-beta/gux-pagination-item-counts-beta.css → stable/gux-pagination/gux-pagination-item-counts/gux-pagination-item-counts.css} +1 -4
- package/dist/collection/components/{beta/gux-pagination-beta/gux-pagination-item-counts-beta/gux-pagination-item-counts-beta.js → stable/gux-pagination/gux-pagination-item-counts/gux-pagination-item-counts.js} +4 -4
- package/dist/collection/components/{beta/gux-pagination-beta/gux-pagination-items-per-page-beta/gux-pagination-items-per-page-beta.css → stable/gux-pagination/gux-pagination-items-per-page/gux-pagination-items-per-page.css} +5 -5
- package/dist/collection/components/{beta/gux-pagination-beta/gux-pagination-items-per-page-beta/gux-pagination-items-per-page-beta.js → stable/gux-pagination/gux-pagination-items-per-page/gux-pagination-items-per-page.js} +5 -5
- package/dist/collection/components/{beta/gux-pagination-beta/gux-pagination-beta.js → stable/gux-pagination/gux-pagination.js} +8 -8
- package/dist/collection/components/stable/gux-popover-list/gux-popover-list.css +8 -34
- package/dist/collection/components/stable/gux-popover-list/gux-popover-list.js +1 -1
- package/dist/collection/components/stable/gux-popup/gux-popup.css +1 -0
- package/dist/collection/components/stable/gux-skip-navigation-list/gux-skip-navigation-item/gux-skip-navigation-item.css +4 -2
- package/dist/collection/components/stable/gux-skip-navigation-list/gux-skip-navigation-item/gux-skip-navigation-item.js +1 -1
- package/dist/collection/components/stable/gux-switch/gux-switch-item/gux-switch-item.css +173 -7
- package/dist/collection/components/stable/gux-switch/gux-switch-item/gux-switch-item.js +1 -1
- package/dist/collection/components/stable/gux-switch/gux-switch.css +2 -2
- package/dist/collection/components/stable/gux-switch/gux-switch.js +1 -1
- package/dist/collection/components/stable/gux-table/gux-table-select-menu/gux-table-select-menu.css +21 -15
- package/dist/collection/components/stable/gux-table/gux-table.css +44 -30
- package/dist/collection/components/stable/gux-tabs/gux-tab-panel/gux-tab-panel.css +56 -6
- package/dist/collection/components/stable/gux-tabs/gux-tab-panel/gux-tab-panel.js +4 -3
- package/dist/collection/components/stable/gux-tag/gux-tag.css +155 -0
- package/dist/collection/components/{beta → stable}/gux-tag/gux-tag.js +27 -32
- package/dist/collection/components/stable/gux-toggle/gux-toggle-slider/gux-toggle-slider.css +45 -5
- package/dist/collection/components/stable/gux-toggle/gux-toggle-slider/gux-toggle-slider.js +1 -1
- package/dist/collection/components/stable/gux-toggle/gux-toggle.css +4 -2
- package/dist/collection/components/stable/gux-toggle/gux-toggle.js +1 -1
- package/dist/component-specs.json +60 -106
- package/dist/deploy-info.json +3 -3
- package/dist/esm/genesys-webcomponents.js +1 -1
- package/dist/esm/gux-accordion-section.entry.js +1 -1
- package/dist/esm/gux-accordion.entry.js +1 -1
- package/dist/esm/gux-action-button.entry.js +1 -1
- package/dist/esm/gux-action-toast-legacy.entry.js +2 -2
- package/dist/esm/gux-advanced-dropdown-legacy.entry.js +214 -0
- package/dist/esm/gux-announce-beta.entry.js +1 -1
- package/dist/esm/gux-badge.entry.js +1 -1
- package/dist/esm/gux-blank-state.entry.js +1 -1
- package/dist/esm/gux-breadcrumbs.entry.js +1 -1
- package/dist/esm/gux-button-multi.entry.js +2 -3
- package/dist/esm/gux-button-slot.entry.js +2 -2
- package/dist/esm/gux-button.entry.js +2 -2
- package/dist/esm/gux-calendar.entry.js +1 -1
- package/dist/esm/gux-card.entry.js +1 -1
- package/dist/esm/gux-column-manager-item.entry.js +1 -1
- package/dist/esm/gux-column-manager.entry.js +1 -1
- package/dist/esm/gux-content-search.entry.js +1 -1
- package/dist/esm/gux-context-menu.entry.js +1 -1
- package/dist/esm/gux-copy-to-clipboard.entry.js +1 -1
- package/dist/esm/gux-date-beta.entry.js +1 -1
- package/dist/esm/gux-date-time-beta.entry.js +1 -1
- package/dist/esm/gux-datepicker.entry.js +1 -1
- package/dist/esm/gux-disclosure-button-legacy.entry.js +1 -1
- package/dist/esm/gux-dismiss-button.entry.js +1 -1
- package/dist/esm/gux-dropdown-multi-beta.entry.js +1 -1
- package/dist/esm/gux-dropdown-option.entry.js +1 -1
- package/dist/esm/gux-dropdown_3.entry.js +1 -1
- package/dist/esm/gux-flyout-menu-beta.entry.js +1 -1
- package/dist/esm/gux-form-field-checkbox.entry.js +1 -1
- package/dist/esm/gux-form-field-color.entry.js +1 -1
- package/dist/esm/gux-form-field-dropdown.entry.js +1 -1
- package/dist/esm/gux-form-field-input-clear-button.entry.js +1 -1
- package/dist/esm/gux-form-field-number_3.entry.js +2 -2
- package/dist/esm/gux-form-field-phone.entry.js +1 -1
- package/dist/esm/gux-form-field-radio.entry.js +1 -1
- package/dist/esm/gux-form-field-range.entry.js +2 -2
- package/dist/esm/gux-form-field-search.entry.js +1 -1
- package/dist/esm/gux-form-field-select.entry.js +1 -1
- package/dist/esm/gux-form-field-text-like.entry.js +2 -2
- package/dist/esm/gux-form-field-textarea.entry.js +2 -2
- package/dist/esm/gux-form-field-time-picker.entry.js +1 -1
- package/dist/esm/gux-icon.entry.js +1 -1
- package/dist/esm/gux-inline-alert.entry.js +1 -1
- package/dist/esm/gux-list-item.entry.js +1 -1
- package/dist/esm/gux-list.entry.js +1 -1
- package/dist/esm/gux-listbox-multi.entry.js +1 -1
- package/dist/esm/gux-loading-message.entry.js +4 -48
- package/dist/esm/gux-modal.entry.js +1 -1
- package/dist/esm/gux-month-picker-beta.entry.js +1 -1
- package/dist/esm/gux-notification-toast-legacy.entry.js +2 -2
- package/dist/esm/gux-page-loading-spinner.entry.js +1 -1
- package/dist/esm/{gux-pagination-buttons-beta_2.entry.js → gux-pagination-buttons_3.entry.js} +47 -10
- package/dist/esm/gux-pagination-cursor.entry.js +1 -1
- package/dist/esm/gux-pagination-legacy.entry.js +1 -1
- package/dist/esm/{gux-pagination-beta.entry.js → gux-pagination.entry.js} +6 -6
- package/dist/esm/gux-phone-input-beta.entry.js +1 -1
- package/dist/esm/gux-popover-list.entry.js +2 -2
- package/dist/esm/gux-popup.entry.js +1 -1
- package/dist/esm/gux-radial-loading.entry.js +1 -1
- package/dist/esm/gux-radial-progress.entry.js +1 -1
- package/dist/esm/gux-rating.entry.js +1 -1
- package/dist/esm/gux-region-icon.entry.js +1 -1
- package/dist/esm/gux-screen-reader-beta.entry.js +1 -1
- package/dist/esm/gux-simple-toast-legacy.entry.js +1 -1
- package/dist/esm/gux-skip-navigation-item.entry.js +1 -1
- package/dist/esm/gux-skip-navigation-list.entry.js +1 -1
- package/dist/esm/gux-sort-control.entry.js +1 -1
- package/dist/esm/gux-switch-item.entry.js +1 -1
- package/dist/esm/gux-switch.entry.js +2 -2
- package/dist/esm/gux-tab-panel.entry.js +3 -3
- package/dist/esm/gux-table-select-menu.entry.js +1 -1
- package/dist/esm/gux-table-toolbar-action.entry.js +1 -1
- package/dist/esm/gux-table-toolbar-custom-action.entry.js +1 -1
- package/dist/esm/gux-table-toolbar-menu-button.entry.js +1 -1
- package/dist/esm/gux-table-toolbar.entry.js +1 -1
- package/dist/esm/gux-table.entry.js +2 -2
- package/dist/esm/gux-tabs-advanced.entry.js +1 -1
- package/dist/esm/gux-tabs.entry.js +1 -1
- package/dist/esm/gux-tag.entry.js +76 -0
- package/dist/esm/gux-text-highlight.entry.js +1 -1
- package/dist/esm/gux-time-beta.entry.js +1 -1
- package/dist/esm/gux-time-picker.entry.js +1 -1
- package/dist/esm/gux-time-zone-picker-beta.entry.js +1 -1
- package/dist/esm/gux-toast.entry.js +1 -1
- package/dist/esm/gux-toggle-slider.entry.js +1 -1
- package/dist/esm/gux-toggle.entry.js +2 -2
- package/dist/esm/gux-tooltip.entry.js +1 -1
- package/dist/esm/index-0b66fe2c.js +8 -16
- package/dist/esm/loader.js +1 -1
- package/dist/esm/{usage-f03a9e96.js → usage-c6e07f31.js} +1 -1
- package/dist/genesys-webcomponents/genesys-webcomponents.css +2 -2
- package/dist/genesys-webcomponents/genesys-webcomponents.esm.js +1 -1
- package/dist/genesys-webcomponents/i18n/genesys-webcomponents.i18n.en.json +1 -1
- package/dist/genesys-webcomponents/{p-bcec2244.entry.js → p-01c8bb6b.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-35784c37.entry.js → p-02134088.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-7ae4a9fe.entry.js → p-09961f4d.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-0f4948bb.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-fab005df.entry.js → p-172655ad.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-b08f2a1f.entry.js → p-188d3d96.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-596ed860.entry.js → p-1b936c21.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-de63108a.entry.js → p-1e850ed3.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-425a79f2.entry.js → p-219a0bad.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-ba247660.entry.js → p-288ab9a2.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-ec46bb6e.entry.js → p-2a4eacec.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-3031a578.entry.js +1 -0
- package/dist/genesys-webcomponents/p-358f295c.entry.js +1 -0
- package/dist/genesys-webcomponents/p-3aa5149b.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-a0b3b9f2.entry.js → p-3b4d5b80.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-39170389.entry.js → p-3bc32648.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-3d6b25da.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-82bab522.entry.js → p-41dffb40.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-24a36458.entry.js → p-46697c27.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-fd52eebf.entry.js → p-47557661.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-516497a8.entry.js → p-47ba479b.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-4c46f081.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-5623eb9b.entry.js → p-4d17728f.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-ea9d71eb.entry.js → p-4f1063c5.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-5676eed0.entry.js +1 -0
- package/dist/genesys-webcomponents/p-581738c6.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-6b48fbde.entry.js → p-58dbdd6e.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-5dea868f.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-d68a0863.entry.js → p-5e05cbf4.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-82aad1f7.entry.js → p-5e1230ac.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-06a92400.entry.js → p-5f22855f.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-dc84cec7.js → p-6517ed89.js} +1 -1
- package/dist/genesys-webcomponents/{p-b5eb0d49.entry.js → p-651e350f.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-d107d384.entry.js → p-65d42429.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-bb29dc80.entry.js → p-6748082f.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-6846d279.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-a3f9f44a.entry.js → p-68868258.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-8056c132.entry.js → p-698f98c2.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-6bff9eb3.entry.js +1 -0
- package/dist/genesys-webcomponents/p-6c5ba842.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-30598362.entry.js → p-6cddf4cc.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-bfa89db2.entry.js → p-6ceceb96.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-b90e7457.entry.js → p-6d16729f.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-a5d5ba91.entry.js → p-6d7e7a71.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-dc6723ca.entry.js → p-74009863.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-8e592f22.entry.js → p-76f4a444.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-e33c43dd.entry.js → p-77e60d29.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-795e7b1a.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-d0abf3d7.entry.js → p-7a8c150f.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-855c7fcc.entry.js → p-7b4ef992.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-c3980b75.entry.js → p-7be9b209.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-7c5d3642.entry.js +1 -0
- package/dist/genesys-webcomponents/p-7dd13d10.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-40744307.entry.js → p-8212cb52.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-8d693163.entry.js → p-8f49f6a8.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-0b01b76e.entry.js → p-91d49ac1.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-c9ada3f6.entry.js → p-95fc6119.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-c4bdc563.entry.js → p-983c952f.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-92095ee1.entry.js → p-9b6831a5.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-f06e2d5d.entry.js → p-9eb61bd3.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-75f9676c.entry.js → p-a4dbc7d1.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-da2efa1d.entry.js → p-a91103ab.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-f2f53d61.entry.js → p-aaaf2fd9.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-b030d487.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-81a01440.entry.js → p-b0d4ece6.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-46980018.entry.js → p-b2d32b54.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-46abdd72.entry.js → p-ba975521.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-1b35958d.entry.js → p-bcbab73b.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-0212b664.entry.js → p-bd630920.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-e01bffb0.entry.js → p-bdb75a90.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-90379a2c.entry.js → p-bfe3a794.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-c2485ed4.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-532ea636.entry.js → p-c313de7b.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-c4ed84fa.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-7b43f40b.entry.js → p-c609ed18.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-c8580fbf.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-1f39a936.entry.js → p-ca143a76.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-ca5e2ee3.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-3ad223ac.entry.js → p-cb2c7de5.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-119bf1e5.entry.js → p-ccfcec33.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-dfc7c240.entry.js → p-d9f31512.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-e7ea294d.entry.js +1 -0
- package/dist/genesys-webcomponents/p-ecac9a08.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-0978a177.entry.js → p-eeb5254d.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-ffe2a7bc.entry.js → p-f03c03d4.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-9f919a75.entry.js → p-f4b602e0.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-806357bf.entry.js → p-f58ff022.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-82b561eb.entry.js → p-fdbd6834.entry.js} +1 -1
- package/dist/stencil-wrapper.js +1 -1
- package/dist/types/components/{stable/gux-advanced-dropdown → legacy/gux-advanced-dropdown-legacy}/gux-advanced-dropdown.d.ts +1 -1
- package/dist/types/components/stable/gux-button-multi/gux-button-multi.d.ts +0 -4
- package/dist/types/components/stable/gux-loading-message/gux-loading-message.d.ts +0 -10
- package/dist/types/components/{beta/gux-pagination-beta/gux-pagination-buttons-beta/gux-pagination-buttons-beta.d.ts → stable/gux-pagination/gux-pagination-buttons/gux-pagination-buttons.d.ts} +3 -3
- package/dist/types/components/{beta/gux-pagination-beta/gux-pagination-item-counts-beta/gux-pagination-item-counts-beta.d.ts → stable/gux-pagination/gux-pagination-item-counts/gux-pagination-item-counts.d.ts} +1 -1
- package/dist/types/components/{beta/gux-pagination-beta/gux-pagination-items-per-page-beta/gux-pagination-items-per-page-beta.d.ts → stable/gux-pagination/gux-pagination-items-per-page/gux-pagination-items-per-page.d.ts} +2 -2
- package/dist/types/components/{beta/gux-pagination-beta/gux-pagination-beta.d.ts → stable/gux-pagination/gux-pagination.d.ts} +4 -4
- package/dist/types/components/stable/gux-pagination/gux-pagination.types.d.ts +2 -0
- package/dist/types/components/{beta → stable}/gux-tag/gux-tag.d.ts +3 -16
- package/dist/types/components/stable/gux-tag/gux-tag.types.d.ts +1 -0
- package/dist/types/components.d.ts +86 -145
- package/dist/types/stencil-wrapper.d.ts +1 -1
- package/package.json +1 -1
- package/dist/cjs/gux-advanced-dropdown.cjs.entry.js +0 -218
- package/dist/cjs/gux-pagination-items-per-page-beta.cjs.entry.js +0 -46
- package/dist/cjs/gux-tab-panel-beta.cjs.entry.js +0 -34
- package/dist/cjs/gux-tag-beta.cjs.entry.js +0 -84
- package/dist/collection/components/beta/gux-tab-panel-beta/gux-tab-panel-beta.css +0 -15
- package/dist/collection/components/beta/gux-tab-panel-beta/gux-tab-panel-beta.js +0 -107
- package/dist/collection/components/beta/gux-tag/gux-tag.css +0 -461
- package/dist/collection/components/stable/gux-advanced-dropdown/gux-advanced-dropdown.css +0 -85
- package/dist/collection/components/stable/gux-loading-message/gux-loading-message-constants.js +0 -5
- package/dist/collection/components/stable/gux-loading-message/gux-loading-message-size.types.js +0 -1
- package/dist/esm/gux-advanced-dropdown.entry.js +0 -214
- package/dist/esm/gux-pagination-items-per-page-beta.entry.js +0 -42
- package/dist/esm/gux-tab-panel-beta.entry.js +0 -30
- package/dist/esm/gux-tag-beta.entry.js +0 -80
- package/dist/genesys-webcomponents/p-0af113c1.entry.js +0 -1
- package/dist/genesys-webcomponents/p-0b14794a.entry.js +0 -1
- package/dist/genesys-webcomponents/p-12e01c6c.entry.js +0 -1
- package/dist/genesys-webcomponents/p-15182c48.entry.js +0 -1
- package/dist/genesys-webcomponents/p-1a7b3efe.entry.js +0 -1
- package/dist/genesys-webcomponents/p-1b9ae90d.entry.js +0 -1
- package/dist/genesys-webcomponents/p-27a62f54.entry.js +0 -1
- package/dist/genesys-webcomponents/p-3881c2c8.entry.js +0 -1
- package/dist/genesys-webcomponents/p-43d22f9f.entry.js +0 -1
- package/dist/genesys-webcomponents/p-5f0d8583.entry.js +0 -1
- package/dist/genesys-webcomponents/p-81c3fa5a.entry.js +0 -1
- package/dist/genesys-webcomponents/p-844dfb88.entry.js +0 -1
- package/dist/genesys-webcomponents/p-948ad846.entry.js +0 -1
- package/dist/genesys-webcomponents/p-99e5fc7e.entry.js +0 -1
- package/dist/genesys-webcomponents/p-a7ad3633.entry.js +0 -1
- package/dist/genesys-webcomponents/p-c6a3a814.entry.js +0 -1
- package/dist/genesys-webcomponents/p-d2db8cfb.entry.js +0 -1
- package/dist/genesys-webcomponents/p-d2ec2410.entry.js +0 -1
- package/dist/genesys-webcomponents/p-d6b3146d.entry.js +0 -1
- package/dist/genesys-webcomponents/p-e73a5b4e.entry.js +0 -1
- package/dist/genesys-webcomponents/p-f2fea056.entry.js +0 -1
- package/dist/genesys-webcomponents/p-f4048683.entry.js +0 -1
- package/dist/genesys-webcomponents/p-f51f3281.entry.js +0 -1
- package/dist/genesys-webcomponents/p-f9768ae7.entry.js +0 -1
- package/dist/types/components/beta/gux-pagination-beta/gux-pagination-beta.types.d.ts +0 -2
- package/dist/types/components/beta/gux-tab-panel-beta/gux-tab-panel-beta.d.ts +0 -18
- package/dist/types/components/beta/gux-tag/gux-tag.types.d.ts +0 -2
- package/dist/types/components/stable/gux-loading-message/gux-loading-message-constants.d.ts +0 -5
- package/dist/types/components/stable/gux-loading-message/gux-loading-message-size.types.d.ts +0 -1
- /package/dist/cjs/{en-b3076cac.js → en-2a12d7c4.js} +0 -0
- /package/dist/collection/components/legacy/gux-pagination-legacy/{gux-pagination-buttons → gux-pagination-buttons-legacy}/gux-pagination-button.service.js +0 -0
- /package/dist/collection/components/legacy/gux-pagination-legacy/{gux-pagination-buttons → gux-pagination-buttons-legacy}/gux-pagination-buttons-legacy.css +0 -0
- /package/dist/collection/components/legacy/gux-pagination-legacy/{gux-pagination-buttons → gux-pagination-buttons-legacy}/gux-pagination-buttons.js +0 -0
- /package/dist/collection/components/legacy/gux-pagination-legacy/{gux-pagination-item-counts → gux-pagination-item-counts-legacy}/gux-pagination-item-counts-legacy.css +0 -0
- /package/dist/collection/components/legacy/gux-pagination-legacy/{gux-pagination-item-counts → gux-pagination-item-counts-legacy}/gux-pagination-item-counts.js +0 -0
- /package/dist/collection/components/legacy/gux-pagination-legacy/{gux-pagination-items-per-page → gux-pagination-items-per-page-legacy}/gux-pagination-items-per-page-legacy.css +0 -0
- /package/dist/collection/components/legacy/gux-pagination-legacy/{gux-pagination-items-per-page → gux-pagination-items-per-page-legacy}/gux-pagination-items-per-page.js +0 -0
- /package/dist/collection/components/{beta/gux-pagination-beta/gux-pagination-buttons-beta/gux-pagination-button-beta.service.js → stable/gux-pagination/gux-pagination-buttons/gux-pagination-button.service.js} +0 -0
- /package/dist/collection/components/{beta/gux-pagination-beta/gux-pagination-buttons-beta → stable/gux-pagination/gux-pagination-buttons}/gux-pagination-ellipsis-button/gux-pagination-ellipsis-button.css +0 -0
- /package/dist/collection/components/{beta/gux-pagination-beta/gux-pagination-buttons-beta → stable/gux-pagination/gux-pagination-buttons}/gux-pagination-ellipsis-button/gux-pagination-ellipsis-button.js +0 -0
- /package/dist/collection/components/{beta/gux-pagination-beta/gux-pagination-beta.css → stable/gux-pagination/gux-pagination.css} +0 -0
- /package/dist/collection/components/{beta/gux-pagination-beta/gux-pagination-beta.types.js → stable/gux-pagination/gux-pagination.types.js} +0 -0
- /package/dist/collection/components/{beta → stable}/gux-tag/gux-tag.types.js +0 -0
- /package/dist/esm/{en-5d726a81.js → en-6c4aef39.js} +0 -0
- /package/dist/genesys-webcomponents/{p-89af02eb.js → p-abb9b5f7.js} +0 -0
- /package/dist/types/components/{stable/gux-advanced-dropdown → legacy/gux-advanced-dropdown-legacy}/dropdown-option/gux-dropdown-option.d.ts +0 -0
- /package/dist/types/components/legacy/gux-pagination-legacy/{gux-pagination-buttons → gux-pagination-buttons-legacy}/gux-pagination-button.service.d.ts +0 -0
- /package/dist/types/components/legacy/gux-pagination-legacy/{gux-pagination-buttons → gux-pagination-buttons-legacy}/gux-pagination-buttons.d.ts +0 -0
- /package/dist/types/components/legacy/gux-pagination-legacy/{gux-pagination-item-counts → gux-pagination-item-counts-legacy}/gux-pagination-item-counts.d.ts +0 -0
- /package/dist/types/components/legacy/gux-pagination-legacy/{gux-pagination-items-per-page → gux-pagination-items-per-page-legacy}/gux-pagination-items-per-page.d.ts +0 -0
- /package/dist/types/components/{beta/gux-pagination-beta/gux-pagination-buttons-beta/gux-pagination-button-beta.service.d.ts → stable/gux-pagination/gux-pagination-buttons/gux-pagination-button.service.d.ts} +0 -0
- /package/dist/types/components/{beta/gux-pagination-beta/gux-pagination-buttons-beta → stable/gux-pagination/gux-pagination-buttons}/gux-pagination-ellipsis-button/gux-pagination-ellipsis-button.d.ts +0 -0
@@ -1 +1 @@
|
|
1
|
-
import{r as t,c as n,h as e,g as i}from"./p-7d26b2e1.js";import{t as o}from"./p-
|
1
|
+
import{r as t,c as n,h as e,g as i}from"./p-7d26b2e1.js";import{t as o}from"./p-6517ed89.js";import{b as s}from"./p-deee079e.js";import{a}from"./p-3701eff0.js";import"./p-8a133b9b.js";const r={eraseBtnAria:"Clear search text",navigateNextBtn:"Highlight next match",navigatePreviousBtn:"Highlight previous match",totalMatches:"{currentMatch, number} of {matchCount, number}",clear:"Clear"},c=class{constructor(e){t(this,e),this.guxcurrentmatchchanged=n(this,"guxcurrentmatchchanged",7),this.matchCount=0,this.currentMatch=0,this.disabled=void 0,this.value=void 0}async clear(){this.disabled||(this.matchCount=0,this.currentMatch=0,this.value="",this.resetInputSlottedElement(),this.emitCurrentMatchChanged(),this.inputSlottedElement.focus())}async componentWillLoad(){o(this.root),this.i18n=await s(this.root,r),this.inputSlottedElement=this.root.querySelector("input"),this.disabled=this.inputSlottedElement.disabled,this.value=this.inputSlottedElement.value,this.disabledObserver=a(this.inputSlottedElement,(t=>{this.disabled=t})),this.inputSlottedElement.addEventListener("input",(t=>this.onInput(t)))}disconnectedCallback(){this.disabledObserver&&this.disabledObserver.disconnect()}render(){return e("div",{class:{"gux-content-search":!0,"gux-disabled":this.disabled}},e("div",{class:"gux-search-icon"},e("gux-icon",{decorative:!0,"icon-name":"search"})),e("slot",null),this.getNavigationPanel())}getNavigationPanel(){if(this.showNavigationPanel()){const t=this.disableNavigationPanel();return e("div",{class:"gux-content-control-panel"},e("div",{class:{"gux-navigation-panel":!0,"gux-navigation-disabled":t}},e("span",{class:{"gux-navigation-result":!0,"gux-navigation-result-disabled":t}},this.matchCountResult()),e("button",{type:"button",class:"gux-previous-button",title:this.i18n("navigatePreviousBtn"),"aria-label":this.i18n("navigatePreviousBtn"),onClick:()=>this.previousClick(),disabled:t},e("gux-icon",{decorative:!0,"icon-name":"arrow-solid-up"})),e("button",{type:"button",class:"gux-next-button",title:this.i18n("navigateNextBtn"),"aria-label":this.i18n("navigateNextBtn"),onClick:()=>this.nextClick(),disabled:t},e("gux-icon",{decorative:!0,"icon-name":"arrow-solid-down"}))),e("button",{class:"gux-clear-button",tabIndex:-1,type:"button",title:this.i18n("clear"),onClick:()=>{this.clear()}},e("gux-icon",{"icon-name":"close",decorative:!0})))}return null}matchCountResult(){return this.i18n("totalMatches",{currentMatch:this.getNormalizedCurrentMatch(),matchCount:this.getNormalizedMatchCount()})}showNavigationPanel(){return""!==this.value}disableNavigationPanel(){return this.disabled||this.getNormalizedMatchCount()<=0}getNormalizedMatchCount(){return this.matchCount&&Number.isInteger(this.matchCount)&&this.matchCount>=0?Number(this.matchCount):0}getNormalizedCurrentMatch(){return this.currentMatch&&Number.isInteger(this.currentMatch)&&this.currentMatch>=0&&this.currentMatch<=this.getNormalizedMatchCount()&&this.getNormalizedMatchCount()>0?Number(this.currentMatch):0}resetInputSlottedElement(){this.inputSlottedElement.value="",this.inputSlottedElement.dispatchEvent(new InputEvent("input",{bubbles:!0,cancelable:!0})),this.inputSlottedElement.dispatchEvent(new InputEvent("change",{bubbles:!0}))}nextClick(){this.disableNavigationPanel()||(this.currentMatch=this.getNormalizedCurrentMatch()===this.getNormalizedMatchCount()?1:this.getNormalizedCurrentMatch()+1,this.emitCurrentMatchChanged())}previousClick(){this.disableNavigationPanel()||(this.currentMatch=1===this.getNormalizedCurrentMatch()||0===this.getNormalizedCurrentMatch()?this.getNormalizedMatchCount():this.getNormalizedCurrentMatch()-1,this.emitCurrentMatchChanged())}onInput(t){this.value=t.target.value}emitCurrentMatchChanged(){this.guxcurrentmatchchanged.emit(this.getNormalizedCurrentMatch())}get root(){return i(this)}};c.style=":host{display:inline-block;width:300px;min-width:300px;color:#596373}::slotted(input){box-sizing:border-box;width:100%;height:32px;padding:4px 12px;font-family:inherit;font-size:12px;line-height:1.6667;background-color:#fdfdfd;background-image:none;border:1px solid #6b7585;border-radius:2px;flex-basis:100%;flex-shrink:1;min-width:0;height:22px;padding:0;color:#2e394c;background-color:#f6f7f9;border:0;border-radius:0;outline:none}::slotted(input)::placeholder{color:#596373}::slotted(input).gux-focused,::slotted(input):focus-visible{border:1px solid #2a60c8;outline:none;box-shadow:0 0 4px rgba(170, 201, 255, 0.5)}::slotted(input).gux-focused,::slotted(input):focus{border:0;outline:none;box-shadow:none}.gux-content-search{box-sizing:border-box;display:flex;flex-direction:row;width:100%;height:32px;padding:4px 0;margin:4px 0;background-color:#f6f7f9;background-image:none;border:1px solid #6b7585;border-radius:4px;box-shadow:inset 0 0 4px rgba(32, 41, 55, 0.16)}.gux-content-search.gux-disabled{pointer-events:none;cursor:default;opacity:0.5}.gux-content-search:focus-visible,.gux-content-search:focus-within{border:1px solid #2a60c8;outline:none;box-shadow:0 0 4px #75a8ff}.gux-content-search .gux-search-icon{display:flex;flex-shrink:0;align-items:center;padding:0 4px 0 8px}.gux-content-search .gux-search-icon:disabled{pointer-events:none;cursor:default;opacity:0.5}.gux-content-search .gux-search-icon gux-icon{width:16px;height:16px}.gux-content-search .gux-content-control-panel{box-sizing:border-box;display:flex;flex-grow:1;flex-shrink:0;align-content:center;align-items:center;justify-content:flex-end;height:22px;padding:0;line-height:1.6667}.gux-content-search .gux-content-control-panel gux-icon{width:16px;height:16px}.gux-content-search .gux-content-control-panel button{display:block;align-items:center;overflow:hidden;color:#596373;cursor:pointer;background:none;border:none;border-radius:4px;outline:none}.gux-content-search .gux-content-control-panel button:disabled{pointer-events:none;cursor:default;opacity:0.5}.gux-content-search .gux-content-control-panel button:not(:disabled):hover,.gux-content-search .gux-content-control-panel button:not(:disabled):focus-visible{color:#2e394c}.gux-content-search .gux-content-control-panel button:not(.gux-clear-button):focus-visible:enabled{outline:3px solid #aac9ff;outline-offset:1px;box-shadow:0 0 0 1px #fdfdfd}.gux-content-search .gux-content-control-panel button.gux-clear-button{flex-shrink:0;align-items:center;padding-right:0;padding-left:0;margin-right:8px;margin-left:8px}.gux-content-search .gux-content-control-panel button.gux-clear-button gux-icon{width:16px;height:16px}.gux-content-search .gux-content-control-panel .gux-navigation-disabled{pointer-events:auto;cursor:default;opacity:0.5}.gux-content-search .gux-content-control-panel .gux-navigation-panel{display:flex;align-content:center;align-items:center;justify-content:flex-end;border-right:1px solid #596373}.gux-content-search .gux-content-control-panel .gux-navigation-panel .gux-navigation-result{align-items:center;padding-left:8px;font-family:inherit;font-size:12px;white-space:nowrap}.gux-content-search .gux-content-control-panel .gux-navigation-panel .gux-previous-button{flex-shrink:0;align-items:center;padding-right:0;padding-left:0;margin-left:4px}.gux-content-search .gux-content-control-panel .gux-navigation-panel .gux-next-button{flex-shrink:0;align-items:center;padding-right:0;padding-left:0;margin-right:4px}";export{c as gux_content_search}
|
@@ -0,0 +1 @@
|
|
1
|
+
import{r as o,c as t,h as e,g as i}from"./p-7d26b2e1.js";import{o as s}from"./p-93904222.js";import{O as r}from"./p-9d18d475.js";import{a as n}from"./p-091f51f6.js";import{t as a}from"./p-6517ed89.js";import{b as l}from"./p-deee079e.js";import"./p-8a133b9b.js";const u={searchAria:"Search"};const c=class{constructor(e){o(this,e),this.input=t(this,"input",7),this.filter=t(this,"filter",7),this.disabled=!1,this.placeholder=void 0,this.noFilter=!1,this.filterDebounceTimeout=500,this.dropdownHeight="320px",this.srLabelledby=void 0,this.opened=void 0,this.currentlySelectedOption=void 0,this.selectionOptions=void 0}watchValue(o){this.opened&&o&&this.closeDropdown(!1)}get value(){var o;return null===(o=this.currentlySelectedOption)||void 0===o?void 0:o.text}getSelectedValues(){return Promise.resolve([this.value])}async setLabeledBy(o){this.srLabelledby=o}onClickOutside(){this.closeDropdown(!1)}async componentWillLoad(){a(this.root),this.i18n=await l(this.root,u),this.handleSelectionChange=this.handleSelectionChange.bind(this),this.updateSelectionState(),this.addOptionListener(),this.slotObserver=s(this.root,(()=>this.updateSelectionState()))}disconnectedCallback(){this.slotObserver&&this.slotObserver.disconnect()}render(){return e("gux-popup",{expanded:this.opened,disabled:this.disabled},e("div",{slot:"target",class:"gux-select-field",onMouseDown:()=>this.inputMouseDown()},e("a",{ref:o=>this.inputBox=o,class:"gux-select-input","aria-labelledby":this.srLabelledby,tabindex:"0",onKeyDown:o=>this.inputKeyDown(o)},this.placeholder&&!this.value&&e("span",{class:"gux-select-placeholder",title:this.placeholder},this.placeholder),this.value&&e("span",{class:"gux-select-value",title:this.value},this.value)),e("div",{class:"gux-icon-wrapper"},e("gux-icon",{decorative:!0,"icon-name":"chevron-small-down"}))),e("div",{slot:"popup",class:"gux-advanced-dropdown-menu"},e("div",{class:"gux-dropdown-menu-container"},e("gux-form-field-search",{"label-position":"screenreader"},e("label",{slot:"label"},this.i18n("searchAria")),e("input",{slot:"input",type:"search",onInput:o=>{this.handleSearchInput(o)},ref:o=>this.searchInput=o})),e("div",{class:"gux-dropdown-options",style:{maxHeight:this.dropdownHeight},onKeyDown:o=>this.optionsKeyDown(o)},e("slot",null)))))}updateSelectionState(){this.selectionOptions=this.getSelectionOptions(),this.currentlySelectedOption=this.selectionOptions.find((o=>o.selected))}addOptionListener(){this.root.addEventListener("selectedChanged",(o=>this.handleSelectionChange(o)))}handleSelectionChange({target:o}){const t=o;this.closeDropdown(!0),this.currentlySelectedOption!==t&&(this.currentlySelectedOption&&(this.currentlySelectedOption.selected=!1),this.currentlySelectedOption=t,this.input.emit(t.value))}getSelectionOptions(){const o=this.root.querySelectorAll("gux-dropdown-option");return Array.from(o)}inputMouseDown(){this.disabled||(this.opened?this.closeDropdown(!0):this.openDropdown(!1))}getFocusIndex(){return this.selectionOptions.findIndex((o=>o.matches(":focus")))}optionsKeyDown(o){switch(o.key){case"ArrowUp":{o.preventDefault();const t=this.getFocusIndex();t>0&&this.selectionOptions[t-1].focus();break}case"ArrowDown":{o.preventDefault();const t=this.getFocusIndex();t<this.selectionOptions.length-1&&this.selectionOptions[t+1].focus();break}case"Home":if(!this.selectionOptions.length)return;this.selectionOptions[0].focus();break;case"End":if(!this.selectionOptions.length)return;this.selectionOptions[this.selectionOptions.length-1].focus()}}inputKeyDown(o){switch(o.key){case"ArrowUp":case"ArrowDown":case" ":this.openDropdown(!0)}}handleSearchInput(o){o.stopPropagation(),clearTimeout(this.filterDebounceTimer),this.filterDebounceTimer=setTimeout((()=>this.searchRequested()),this.filterDebounceTimeout)}searchRequested(){this.filter.emit(this.searchInput.value),this.setFilteredOptions()}setFilteredOptions(){const o=this.searchInput.value;if(!this.noFilter)for(const t of this.selectionOptions)t.shouldFilter(o).then((o=>{t.filtered=o}))}changeFocusToSearch(){n((()=>{this.searchInput.focus()}))}openDropdown(o){this.opened=!0,o&&this.changeFocusToSearch()}closeDropdown(o){this.opened=!1,this.searchInput.value="",this.setFilteredOptions(),o&&this.inputBox.focus()}get root(){return i(this)}static get watchers(){return{disabled:["watchValue"]}}};(function(o,t,e,i){var s,r=arguments.length,n=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(o,t,e,i);else for(var a=o.length-1;a>=0;a--)(s=o[a])&&(n=(r<3?s(n):r>3?s(t,e,n):s(t,e))||n);r>3&&n&&Object.defineProperty(t,e,n)})([r({triggerEvents:"mousedown"})],c.prototype,"onClickOutside",null),c.style='.gux-focus-ring-focused:focus{outline-width:var(--gse-semantic-focusRing-default-border-width);outline-style:var(--gse-semantic-focusRing-default-border-style);outline-color:var(--gse-semantic-focusRing-default-border-color);outline-offset:var(--gse-semantic-focusRing-offset)}.gux-focus-ring-focused-within:focus-within{outline-width:var(--gse-semantic-focusRing-default-border-width);outline-style:var(--gse-semantic-focusRing-default-border-style);outline-color:var(--gse-semantic-focusRing-default-border-color);outline-offset:var(--gse-semantic-focusRing-offset)}.gux-focus-ring-focused-visible:focus-visible{outline-width:var(--gse-semantic-focusRing-default-border-width);outline-style:var(--gse-semantic-focusRing-default-border-style);outline-color:var(--gse-semantic-focusRing-default-border-color);outline-offset:var(--gse-semantic-focusRing-offset)}.gux-focus-ring-small-focused:focus{outline-width:var(--gse-semantic-focusRing-small-border-width);outline-style:var(--gse-semantic-focusRing-small-border-style);outline-color:var(--gse-semantic-focusRing-small-border-color)}.gux-focus-ring-small-focused-within:focus-within{outline-width:var(--gse-semantic-focusRing-small-border-width);outline-style:var(--gse-semantic-focusRing-small-border-style);outline-color:var(--gse-semantic-focusRing-small-border-color)}.gux-focus-ring-small-focused-visible:focus-visible{outline-width:var(--gse-semantic-focusRing-small-border-width);outline-style:var(--gse-semantic-focusRing-small-border-style);outline-color:var(--gse-semantic-focusRing-small-border-color)}@font-face{font-family:Roboto;font-style:normal;font-weight:300;src:url("./fonts/roboto-v20-latin-300.eot");src:local("Roboto Light"), local("Roboto-Light"), url("./fonts/roboto-v20-latin-300.eot?#iefix") format("embedded-opentype"), url("./fonts/roboto-v20-latin-300.woff2") format("woff2"), url("./fonts/roboto-v20-latin-300.woff") format("woff"), url("./fonts/roboto-v20-latin-300.ttf") format("truetype"), url("./fonts/roboto-v20-latin-300.svg#Roboto") format("svg");}@font-face{font-family:Roboto;font-style:normal;font-weight:400;src:url("./fonts/roboto-v20-latin-regular.eot");src:local("Roboto"), local("Roboto-Regular"), url("./fonts/roboto-v20-latin-regular.eot?#iefix") format("embedded-opentype"), url("./fonts/roboto-v20-latin-regular.woff2") format("woff2"), url("./fonts/roboto-v20-latin-regular.woff") format("woff"), url("./fonts/roboto-v20-latin-regular.ttf") format("truetype"), url("./fonts/roboto-v20-latin-regular.svg#Roboto") format("svg");}@font-face{font-family:Roboto;font-style:italic;font-weight:400;src:url("./fonts/roboto-v20-latin-italic.eot");src:local("Roboto Italic"), local("Roboto-Italic"), url("./fonts/roboto-v20-latin-italic.eot?#iefix") format("embedded-opentype"), url("./fonts/roboto-v20-latin-italic.woff2") format("woff2"), url("./fonts/roboto-v20-latin-italic.woff") format("woff"), url("./fonts/roboto-v20-latin-italic.ttf") format("truetype"), url("./fonts/roboto-v20-latin-italic.svg#Roboto") format("svg");}@font-face{font-family:Roboto;font-style:normal;font-weight:700;src:url("./fonts/roboto-v20-latin-700.eot");src:local("Roboto Bold"), local("Roboto-Bold"), url("./fonts/roboto-v20-latin-700.eot?#iefix") format("embedded-opentype"), url("./fonts/roboto-v20-latin-700.woff2") format("woff2"), url("./fonts/roboto-v20-latin-700.woff") format("woff"), url("./fonts/roboto-v20-latin-700.ttf") format("truetype"), url("./fonts/roboto-v20-latin-700.svg#Roboto") format("svg");}body{font-family:Roboto, sans-serif;font-weight:400;font-size:12px;line-height:20px}h1{font-family:Roboto, sans-serif;font-weight:400;font-weight:300;font-size:24px;line-height:32px}h2{font-family:Roboto, sans-serif;font-weight:400;font-weight:300;font-size:18px;line-height:24px}h3{font-family:Roboto, sans-serif;font-weight:400;font-weight:700;font-size:14px;line-height:20px}h4,h5,h6{font-family:Roboto, sans-serif;font-weight:400;font-size:14px;line-height:20px}.gux-icon-anchor gux-icon{padding-right:var(--gse-ui-links-inLine-padding)}a{color:var(--gse-ui-link-default-color);text-decoration:underline;border-radius:var(--gse-ui-links-borderRadius)}a:hover{color:var(--gse-ui-link-hover-color)}a:active{color:var(--gse-ui-link-active-color)}a:visited{color:var(--gse-ui-link-visited-color)}a:focus-visible{outline-width:var(--gse-semantic-focusRing-default-border-width);outline-style:var(--gse-semantic-focusRing-default-border-style);outline-color:var(--gse-semantic-focusRing-default-border-color);outline-offset:var(--gse-semantic-focusRing-offset)}table a{color:var(--gse-ui-link-default-color);text-decoration:underline;border-radius:var(--gse-ui-links-borderRadius);text-decoration:none}table a:hover{color:var(--gse-ui-link-hover-color)}table a:active{color:var(--gse-ui-link-active-color)}table a:visited{color:var(--gse-ui-link-visited-color)}table a:focus-visible{outline-width:var(--gse-semantic-focusRing-default-border-width);outline-style:var(--gse-semantic-focusRing-default-border-style);outline-color:var(--gse-semantic-focusRing-default-border-color);outline-offset:var(--gse-semantic-focusRing-offset)}:host{color:#2e394c}gux-popup{display:block;margin:4px 0}gux-popup .gux-select-field{position:relative;width:100%;height:32px}gux-popup .gux-select-field a.gux-select-input{position:absolute;inset:0;padding:6px 24px 6px 12px;overflow:hidden;color:#2e394c;text-overflow:ellipsis;text-decoration:none;white-space:nowrap;cursor:pointer;background-color:#f6f7f9;background-image:none;border:1px solid #6b7585;border-radius:4px;box-shadow:inset 0 0 4px rgba(32, 41, 55, 0.16)}gux-popup .gux-select-field a.gux-select-input .gux-select-placeholder,gux-popup .gux-select-field a.gux-select-input .gux-select-value{line-height:20px}gux-popup .gux-select-field a.gux-select-input .gux-select-placeholder{color:#596373}gux-popup .gux-select-field a.gux-select-input:focus-visible{outline:none;box-shadow:0 0 0 3px rgba(117, 168, 255, 0.5)}gux-popup .gux-select-field .gux-icon-wrapper{position:absolute;top:1px;right:8px;bottom:0;display:flex;align-items:center;overflow:hidden;cursor:pointer}gux-popup .gux-select-field .gux-icon-wrapper gux-icon{width:16px;height:16px;color:#596373}gux-popup .gux-select-field:hover .gux-icon-wrapper gux-icon{color:#2e394c}gux-popup .gux-advanced-dropdown-menu{width:100%;background:#fdfdfd;border:1px solid #b4bccb;border-radius:4px;box-shadow:0 0 2px 0 rgba(32, 41, 55, 0.24)}gux-popup .gux-advanced-dropdown-menu .gux-dropdown-menu-container gux-form-field-search{margin:8px 16px}gux-popup .gux-advanced-dropdown-menu .gux-dropdown-menu-container gux-form-field-search input::-webkit-search-cancel-button,gux-popup .gux-advanced-dropdown-menu .gux-dropdown-menu-container gux-form-field-search input::-webkit-search-results-button,gux-popup .gux-advanced-dropdown-menu .gux-dropdown-menu-container gux-form-field-search input::-webkit-calendar-picker-indicator{display:none;-webkit-appearance:none}gux-popup .gux-dropdown-options{padding:8px 0;margin:0;overflow-y:auto;color:#2e394c;background:#fdfdfd;border-radius:4px;box-shadow:none}gux-popup::part(gux-popup-container){width:inherit}';export{c as gux_advanced_dropdown_legacy}
|
@@ -1 +1 @@
|
|
1
|
-
import{r as s,h as t,H as e,g as r}from"./p-7d26b2e1.js";import{l as a,n as o,f as i,p as n,b as c,c as l}from"./p-417354e9.js";import{t as u}from"./p-
|
1
|
+
import{r as s,h as t,H as e,g as r}from"./p-7d26b2e1.js";import{l as a,n as o,f as i,p as n,b as c,c as l}from"./p-417354e9.js";import{t as u}from"./p-6517ed89.js";const h=["gux-list-item"],m=class{constructor(t){s(this,t)}componentWillLoad(){u(this.root)}onKeyDown(s){switch(s.key){case"ArrowUp":s.preventDefault(),n(this.root,h);break;case"Home":s.preventDefault(),i(this.root,h);break;case"ArrowDown":s.preventDefault(),o(this.root,h);break;case"End":s.preventDefault(),a(this.root,h)}}async guxFocusFirstItem(){i(this.root,h)}async guxFocusItemById(s){c(this.root,h,s)}async guxFocusItemByClosestId(s){l(this.root,h,s)}async guxFocusLastItem(){a(this.root,h)}renderFocusTarget(){return t("span",{tabindex:"-1"})}render(){return t(e,{role:"list"},this.renderFocusTarget(),t("slot",null))}static get delegatesFocus(){return!0}get root(){return r(this)}};m.style=":host{display:flex;flex-direction:column;flex-wrap:nowrap;align-content:stretch;align-items:flex-start;justify-content:flex-start}";export{m as gux_list}
|
@@ -1 +1 @@
|
|
1
|
-
import{r as t,h as s,g as i}from"./p-7d26b2e1.js";import{t as r}from"./p-
|
1
|
+
import{r as t,h as s,g as i}from"./p-7d26b2e1.js";import{t as r}from"./p-6517ed89.js";const e=/[ +]/g,n=new Map,h=new Map;function a(t){return t.replace(/[\^$*+?.(){}[\]\\]/g,"\\$&")}const o=class{constructor(s){t(this,s),this.text=void 0,this.highlight=void 0,this.strategy="start",this.dimmed=!1}componentWillLoad(){r(this.root)}render(){if(this.highlight&&this.text)switch(this.strategy){case"start":return this.renderStartsWith();case"contains":return this.renderContains();case"fuzzy":return this.renderFuzzy()}return s("span",{class:{"gux-dimmed":this.dimmed}},this.text)}renderStartsWith(){if(this.text.toLowerCase().startsWith(this.highlight.toLowerCase())){const t=this.text.substring(0,this.highlight.length),i=this.text.substring(this.highlight.length);return s("span",{class:{"gux-dimmed":this.dimmed}},s("mark",null,t),i)}return s("span",{class:{"gux-dimmed":this.dimmed}},this.text)}renderContains(){const t={highlighted:"",remaining:this.text};for(;t.remaining.toLowerCase().includes(this.highlight.toLowerCase());){const s=t.remaining.toLowerCase().indexOf(this.highlight.toLowerCase()),i=t.remaining.substring(0,s),r=t.remaining.substring(s,s+this.highlight.length);t.highlighted+=i+`<mark>${r}</mark>`,t.remaining=t.remaining.substring(s+r.length)}return s("span",{class:{"gux-dimmed":this.dimmed},innerHTML:t.highlighted+t.remaining})}renderFuzzy(){if(function(t,s){let i=n.get(t);return i||(i=function(t){const s=t.split(e).map(a);if(1===s.length)return new RegExp(s[0],"i");let i="(";return s.forEach(((t,r)=>{i+=t+").*",r!==s.length-1&&(i+="(")})),new RegExp(i+"$","i")}(t),n.set(t,i)),i.test(s)}(this.highlight,this.text)){const i=(t=this.highlight,t.split(e).map(a).map((t=>{let s=h.get(t);return s||(s=new RegExp(t,"i"),h.set(t,s)),s}))).reduce(((t,s)=>{const{0:i,index:r,input:e}=t.remaining.match(s),n=e.substring(0,r);return{highlighted:`${t.highlighted+n}<mark>${i}</mark>`,remaining:e.substring(r+i.length)}}),{highlighted:"",remaining:this.text});return s("span",{class:{"gux-dimmed":this.dimmed},innerHTML:i.highlighted+i.remaining})}var t;return s("span",{class:{"gux-dimmed":this.dimmed}},this.text)}get root(){return i(this)}};o.style="mark{background-color:var(--gse-ui-search-match-firstLevel-backgroundColor)}.gux-dimmed mark{background-color:var(--gse-ui-search-match-subsequentLevel-backgroundColor)}";export{o as gux_text_highlight}
|
@@ -1 +1 @@
|
|
1
|
-
import{r as t,h as i,H as o}from"./p-7d26b2e1.js";const e=class{constructor(i){t(this,i)}render(){return i(o,{role:"listitem"},i("slot",null))}static get delegatesFocus(){return!0}};e.style=":host{position:absolute;top:auto;left:-10000px;width:1px;height:1px;overflow:hidden}:host(:focus-within){position:inherit;top:inherit;left:inherit;width:inherit;height:inherit;overflow:inherit}::slotted(a){padding:12px;font-size:2rem;background-color:#fdfdfd;box-shadow:0 8px 24px
|
1
|
+
import{r as t,h as i,H as o}from"./p-7d26b2e1.js";const e=class{constructor(i){t(this,i)}render(){return i(o,{role:"listitem"},i("slot",null))}static get delegatesFocus(){return!0}};e.style=":host{position:absolute;top:auto;left:-10000px;width:1px;height:1px;overflow:hidden}:host(:focus-within){position:inherit;top:inherit;left:inherit;width:inherit;height:inherit;overflow:inherit}::slotted(a){padding:12px;font-size:2rem;background-color:#fdfdfd;box-shadow:0 8px 24px fade(#202937, 40%), 0 0 0 1px #fdfdfd, 0 0 0 4px #aac9ff !important}";export{e as gux_skip_navigation_item}
|
@@ -1 +1 @@
|
|
1
|
-
const t="4.0.0-beta.
|
1
|
+
const t="4.0.0-beta.28",e=20,n=3e4,o=[function(t){const[e,n,...o]=t.split(".");return{name:"spark-library",metadata:{fullVersion:`${e}.${n}.${o.join(".")}`,majorVersion:e,minorVersion:`${e}.${n}`}}}(t)];function i(){const t=window.newrelic;if(t){for(let r=0;r<e;r++){if(0==o.length)return void setTimeout(i,n);const e=o.shift();t.addPageAction(e.name,Object.assign(Object.assign({},e.metadata),{queueDepth:o.length}))}setTimeout(i,n)}}let r=!1;function a(e,n){window.newrelic&&(r||(r=!0,i()),document.contains(e)&&o.push({name:"spark-component",metadata:Object.assign(Object.assign({},n),{component:e.tagName.toLowerCase(),version:t})}))}export{a as t}
|
@@ -1 +1 @@
|
|
1
|
-
import{r as t,c as e,h as n,g as a}from"./p-7d26b2e1.js";import{a as s}from"./p-091f51f6.js";import{a as i,c as r,b as o,f as d}from"./p-4f26144b.js";import{t as h}from"./p-dc84cec7.js";import{g as l,a as c}from"./p-deee079e.js";import{c as u}from"./p-251befef.js";import"./p-8a133b9b.js";function g(t,e){x(t,"remove",e)}function x(t=[],e,n){const a=[].concat(t);for(const t of a)t.classList[e](n)}function b(t,e){return u(t.toLocaleDateString(e,{year:"numeric",month:"long"}))}const f=class{constructor(n){t(this,n),this.calendarSelect=e(this,"calendarSelect",7),this.locale="en",this.value="",this.minDate="",this.maxDate="",this.mode="single",this.numberOfMonths=1,this.startDayOfWeek=void 0,this.previewValue=new Date,this.selectingDate=null}emitCalendarSelect(){this.calendarSelect.emit(this.value)}async setValue(t){if("range"===this.mode&&t instanceof Array){const[e,n]=t;this.value=i(e,n),this.previewValue=r(this.value)[0]}else{const e=t;this.value=o(e),this.previewValue=e}}async focusPreviewDate(){const t=this.root.shadowRoot.querySelector(`td[data-date="${this.previewValue.getTime()}"]`);t&&t.focus()}async resetCalendarView(t){this.previewValue=t}incrementPreviewDateByMonth(t){this.previewValue=new Date(this.previewValue.getFullYear(),this.previewValue.getMonth()+t,15,0,0,0),s((()=>{this.focusPreviewDate()}))}async setValueAndEmit(t){await this.setValue(t),this.emitCalendarSelect()}outOfBounds(t){return""!==this.maxDate&&d(this.maxDate)<t||""!==this.minDate&&d(this.minDate)>t}generateDatesFrom(t,e,n){const a=[],s=new Date(e.getFullYear(),e.getMonth(),e.getDate(),0,0,0,0);for(let e=0;e<n;e++){const e=new Date(s.getFullYear(),s.getMonth(),s.getDate(),0,0,0,0),n=[];let i=!1,o=!1;e.getMonth()!==t&&(n.push("gux-not-in-month"),i=!0,"range"===this.mode&&(n.push("gux-hidden"),o=!0)),this.outOfBounds(e)&&(n.push("gux-disabled"),i=!0);let h=!1;if("range"===this.mode){const[t,a]=r(this.value),s=t.getTime(),i=a.getTime();e.getTime()===s?(h=!0,n.push("gux-selected"),n.push("gux-start-date")):e.getTime()===i&&(h=!0,n.push("gux-selected"),n.push("gux-end-date"))}else{const t=d(this.value).getTime();e.getTime()===t&&(h=!0,n.push("gux-selected"))}a.push({class:n.join(" "),date:e,hidden:o,disabled:i,selected:h}),s.setDate(s.getDate()+1)}return a}create2DArray(t,e){const n=[];for(let a=0;a<e-1;a++){const s=t.slice(a*e,a*e+e);this.weekShouldBeDisplayed(s)&&n.push(s)}return n}isFocusableDate(t){return t.selected||this.previewValue.getTime()===t.date.getTime()}weekShouldBeDisplayed(t){const e=t.find((t=>!t.hidden));return t.length&&!!e}getMonthDays(t){const e=new Date(this.previewValue.getTime());e.setDate(1),e.setMonth(e.getMonth()+t);const n=e.getMonth(),a=function(t,e,n){const a=new Date(e,t,1,1,0,0,0),s=-1*(n-a.getDay()-7)%7;return new Date(a.getTime()-864e5*s)}(n,e.getFullYear(),this.startDayOfWeek),s=this.generateDatesFrom(n,a,42);return this.create2DArray(s,7)}addDays(t,e){const n=new Date(t.valueOf());return n.setDate(n.getDate()+e),n}getAllDatesElements(){const t=this.root.shadowRoot.querySelectorAll("td");return Array.from(t)}getAllSelectableDatesElements(){const t=this.root.shadowRoot.querySelectorAll('td[tabindex="0"]');return Array.from(t)}getRangeDatesElements(t,e){const n=[];let a;a=e<t?this.getRangeDates(e,t):this.getRangeDates(t,e);for(const t of a){const e=this.root.shadowRoot.querySelector(`td[data-date="${t.getTime()}"]:not(.gux-hidden)`);e&&n.push(e)}return n}getRangeDates(t,e){const n=[];let a=t;for(;a<=e;)n.push(new Date(a)),a=this.addDays(a,1);return n}async onDateClick(t){if(!this.outOfBounds(t))if("range"!==this.mode)await this.setValueAndEmit(t);else if(null===this.selectingDate)g(this.getAllDatesElements(),"gux-hovered"),this.selectingDate=new Date(t.valueOf()),this.value=i(t,t);else{const e=this.root.shadowRoot.querySelector(`td[data-date="${t.getTime()}"]`);e&&e.classList.add("gux-selected"),this.updateRangeElements(),await this.setValueAndEmit([this.selectingDate,t]),this.previewValue=t,this.selectingDate=null}}onDateMouseEnter(t){"range"===this.mode&&null!==this.selectingDate&&(this.value=i(t,this.selectingDate),this.updateRangeElements())}updateRangeElements(){if("range"===this.mode){g(this.getAllDatesElements(),"gux-hovered");const[t,e]=r(this.value);x(this.getRangeDatesElements(t,e),"add","gux-hovered")}}async onKeyDown(t){switch(t.key){case" ":case"Enter":t.preventDefault(),await this.onDateClick(this.previewValue);break;case"ArrowDown":t.preventDefault(),this.previewValue=new Date(this.previewValue.setDate(this.previewValue.getDate()+7)),this.onDateMouseEnter(this.previewValue),s((()=>{this.focusPreviewDate()}));break;case"ArrowUp":t.preventDefault(),this.previewValue=new Date(this.previewValue.setDate(this.previewValue.getDate()-7)),this.onDateMouseEnter(this.previewValue),s((()=>{this.focusPreviewDate()}));break;case"ArrowLeft":t.preventDefault(),this.previewValue=new Date(this.previewValue.setDate(this.previewValue.getDate()-1)),this.onDateMouseEnter(this.previewValue),s((()=>{this.focusPreviewDate()}));break;case"ArrowRight":t.preventDefault(),this.previewValue=new Date(this.previewValue.setDate(this.previewValue.getDate()+1)),this.onDateMouseEnter(this.previewValue),s((()=>{this.focusPreviewDate()}));break;case"PageUp":this.incrementPreviewDateByMonth(1),this.onDateMouseEnter(this.previewValue);break;case"PageDown":this.incrementPreviewDateByMonth(-1),this.onDateMouseEnter(this.previewValue)}}componentWillLoad(){if(h(this.root,{variant:this.mode}),this.locale=l(this.root),this.startDayOfWeek=this.startDayOfWeek||c(this.locale),!this.value){const t=new Date;t.setHours(0,0,0,0),this.value="range"===this.mode?i(t,t):o(t)}this.previewValue=d(this.value)}componentDidRender(){this.updateRangeElements()}renderMonthHeader(){return n("div",{class:"gux-month-list"},Array.from(Array(this.numberOfMonths).keys()).map((t=>{const e=function(t,e){const n=new Date(t);return n.setDate(1),n.setMonth(n.getMonth()+e),n}(this.previewValue,t);return n("label",null,b(e,this.locale))})))}renderCalendarTable(t){return n("table",null,n("tr",null,function(t,e){const n=[],a=new Date(1970,0,4);for(let e=0;e<7;e++){const e=a.toLocaleString(t,{weekday:"narrow"});n.push(e),a.setDate(a.getDate()+1)}return(s=n).concat(s.splice(0,(i=e)>s.length?i%s.length:i));var s,i}(this.locale,this.startDayOfWeek).map((t=>n("th",null,t)))),this.getMonthDays(t).map((t=>n("tr",null,t.map((t=>n("td",{tabindex:this.isFocusableDate(t)?"0":"-1",class:t.class,"aria-hidden":t.hidden?"true":"false","aria-disabled":t.disabled?"true":"false","data-date":t.date.getTime(),onClick:()=>{this.onDateClick(t.date)},onMouseEnter:()=>this.onDateMouseEnter(t.date),onKeyDown:t=>{this.onKeyDown(t)}},t.date.getDate(),n("span",{class:"gux-sr-only"},b(t.date,this.locale)))))))))}render(){return n("div",{class:"gux-calendar"},n("div",{class:"gux-header"},n("button",{type:"button",class:"gux-left",onClick:()=>this.incrementPreviewDateByMonth(-1),tabindex:"-1","aria-hidden":"true"},n("gux-icon",{decorative:!0,"icon-name":"chevron-small-left"})),this.renderMonthHeader(),n("button",{type:"button",class:"gux-right",onClick:()=>this.incrementPreviewDateByMonth(1),tabindex:"-1","aria-hidden":"true"},n("gux-icon",{decorative:!0,"icon-name":"chevron-small-right"}))),n("div",{class:"gux-content"},Array.from(Array(this.numberOfMonths).keys()).map((t=>this.renderCalendarTable(t)))))}get root(){return a(this)}};f.style=":host{display:inline-block}.gux-calendar{margin-top:2px;border:1px solid #b4bccb;border-radius:4px}.gux-calendar .gux-header{position:relative;display:flex;align-items:center;justify-content:space-between;height:16px;padding:16px;color:#fdfdfd;background-color:#2a60c8;border-top-left-radius:3px;border-top-right-radius:3px}.gux-calendar .gux-header button{position:absolute;padding:5px;color:#fdfdfd;cursor:pointer;background:none;border:none;outline:none}.gux-calendar .gux-header button:focus-visible{outline:#75a8ff auto 5px}.gux-calendar .gux-header button.gux-left{left:18px}.gux-calendar .gux-header button.gux-right{right:18px}.gux-calendar .gux-header button gux-icon{width:16px;height:16px;pointer-events:none}.gux-calendar .gux-header .gux-month-list{display:flex;justify-content:space-between;width:100%}.gux-calendar .gux-header .gux-month-list label{width:100%;text-align:center;font-size:12px;line-height:20px;font-family:Roboto, sans-serif;font-weight:400;font-weight:700}.gux-calendar .gux-content{display:flex;align-items:flex-start;padding:20px 24px;color:#2e394c;background-color:#fdfdfd;border-bottom-right-radius:3px;border-bottom-left-radius:3px}.gux-calendar .gux-content table{width:168px;text-align:left;table-layout:fixed;border-spacing:0;-ms-user-select:none;user-select:none}.gux-calendar .gux-content table:not(:last-child){padding-right:24px}.gux-calendar .gux-content table tr{height:28px}.gux-calendar .gux-content table tr:empty{display:none}.gux-calendar .gux-content table tr th,.gux-calendar .gux-content table tr td{width:28px;height:28px;padding:0;margin:0;text-align:center;font-family:Roboto, sans-serif;font-weight:400;font-size:12px;line-height:20px}.gux-calendar .gux-content table tr th{font-family:Roboto, sans-serif;font-weight:400;font-weight:700}.gux-calendar .gux-content table tr td{cursor:pointer}.gux-calendar .gux-content table tr td.gux-hovered{background-color:#deeaff}.gux-calendar .gux-content table tr td.gux-selected{color:#fdfdfd;background-color:#2a60c8;border-radius:4px}.gux-calendar .gux-content table tr td.gux-selected.gux-start-date{border-radius:4px 0 0 4px}.gux-calendar .gux-content table tr td.gux-selected.gux-end-date{border-radius:0 4px 4px 0}.gux-calendar .gux-content table tr td:hover:not(.gux-calendar .gux-content table tr td.gux-start-date):not(.gux-calendar .gux-content table tr td.gux-end-date){color:#fdfdfd;background-color:#2a60c8;border-radius:4px}.gux-calendar .gux-content table tr td.gux-disabled{color:rgba(46, 57, 76, 0.5);pointer-events:none}.gux-calendar .gux-content table tr td.gux-not-in-month{color:rgba(107, 117, 133, 0.5)}.gux-calendar .gux-content table tr td.gux-not-in-month:hover{color:#2e394c;background-color:#e2e6ee}.gux-calendar .gux-content table tr td.gux-not-in-month.gux-hidden{visibility:hidden}.gux-sr-only{position:absolute;top:auto;left:-10000px;width:1px;height:1px;overflow:hidden}";export{f as gux_calendar}
|
1
|
+
import{r as t,c as e,h as n,g as a}from"./p-7d26b2e1.js";import{a as s}from"./p-091f51f6.js";import{a as i,c as r,b as o,f as d}from"./p-4f26144b.js";import{t as h}from"./p-6517ed89.js";import{g as l,a as c}from"./p-deee079e.js";import{c as u}from"./p-251befef.js";import"./p-8a133b9b.js";function g(t,e){x(t,"remove",e)}function x(t=[],e,n){const a=[].concat(t);for(const t of a)t.classList[e](n)}function b(t,e){return u(t.toLocaleDateString(e,{year:"numeric",month:"long"}))}const f=class{constructor(n){t(this,n),this.calendarSelect=e(this,"calendarSelect",7),this.locale="en",this.value="",this.minDate="",this.maxDate="",this.mode="single",this.numberOfMonths=1,this.startDayOfWeek=void 0,this.previewValue=new Date,this.selectingDate=null}emitCalendarSelect(){this.calendarSelect.emit(this.value)}async setValue(t){if("range"===this.mode&&t instanceof Array){const[e,n]=t;this.value=i(e,n),this.previewValue=r(this.value)[0]}else{const e=t;this.value=o(e),this.previewValue=e}}async focusPreviewDate(){const t=this.root.shadowRoot.querySelector(`td[data-date="${this.previewValue.getTime()}"]`);t&&t.focus()}async resetCalendarView(t){this.previewValue=t}incrementPreviewDateByMonth(t){this.previewValue=new Date(this.previewValue.getFullYear(),this.previewValue.getMonth()+t,15,0,0,0),s((()=>{this.focusPreviewDate()}))}async setValueAndEmit(t){await this.setValue(t),this.emitCalendarSelect()}outOfBounds(t){return""!==this.maxDate&&d(this.maxDate)<t||""!==this.minDate&&d(this.minDate)>t}generateDatesFrom(t,e,n){const a=[],s=new Date(e.getFullYear(),e.getMonth(),e.getDate(),0,0,0,0);for(let e=0;e<n;e++){const e=new Date(s.getFullYear(),s.getMonth(),s.getDate(),0,0,0,0),n=[];let i=!1,o=!1;e.getMonth()!==t&&(n.push("gux-not-in-month"),i=!0,"range"===this.mode&&(n.push("gux-hidden"),o=!0)),this.outOfBounds(e)&&(n.push("gux-disabled"),i=!0);let h=!1;if("range"===this.mode){const[t,a]=r(this.value),s=t.getTime(),i=a.getTime();e.getTime()===s?(h=!0,n.push("gux-selected"),n.push("gux-start-date")):e.getTime()===i&&(h=!0,n.push("gux-selected"),n.push("gux-end-date"))}else{const t=d(this.value).getTime();e.getTime()===t&&(h=!0,n.push("gux-selected"))}a.push({class:n.join(" "),date:e,hidden:o,disabled:i,selected:h}),s.setDate(s.getDate()+1)}return a}create2DArray(t,e){const n=[];for(let a=0;a<e-1;a++){const s=t.slice(a*e,a*e+e);this.weekShouldBeDisplayed(s)&&n.push(s)}return n}isFocusableDate(t){return t.selected||this.previewValue.getTime()===t.date.getTime()}weekShouldBeDisplayed(t){const e=t.find((t=>!t.hidden));return t.length&&!!e}getMonthDays(t){const e=new Date(this.previewValue.getTime());e.setDate(1),e.setMonth(e.getMonth()+t);const n=e.getMonth(),a=function(t,e,n){const a=new Date(e,t,1,1,0,0,0),s=-1*(n-a.getDay()-7)%7;return new Date(a.getTime()-864e5*s)}(n,e.getFullYear(),this.startDayOfWeek),s=this.generateDatesFrom(n,a,42);return this.create2DArray(s,7)}addDays(t,e){const n=new Date(t.valueOf());return n.setDate(n.getDate()+e),n}getAllDatesElements(){const t=this.root.shadowRoot.querySelectorAll("td");return Array.from(t)}getAllSelectableDatesElements(){const t=this.root.shadowRoot.querySelectorAll('td[tabindex="0"]');return Array.from(t)}getRangeDatesElements(t,e){const n=[];let a;a=e<t?this.getRangeDates(e,t):this.getRangeDates(t,e);for(const t of a){const e=this.root.shadowRoot.querySelector(`td[data-date="${t.getTime()}"]:not(.gux-hidden)`);e&&n.push(e)}return n}getRangeDates(t,e){const n=[];let a=t;for(;a<=e;)n.push(new Date(a)),a=this.addDays(a,1);return n}async onDateClick(t){if(!this.outOfBounds(t))if("range"!==this.mode)await this.setValueAndEmit(t);else if(null===this.selectingDate)g(this.getAllDatesElements(),"gux-hovered"),this.selectingDate=new Date(t.valueOf()),this.value=i(t,t);else{const e=this.root.shadowRoot.querySelector(`td[data-date="${t.getTime()}"]`);e&&e.classList.add("gux-selected"),this.updateRangeElements(),await this.setValueAndEmit([this.selectingDate,t]),this.previewValue=t,this.selectingDate=null}}onDateMouseEnter(t){"range"===this.mode&&null!==this.selectingDate&&(this.value=i(t,this.selectingDate),this.updateRangeElements())}updateRangeElements(){if("range"===this.mode){g(this.getAllDatesElements(),"gux-hovered");const[t,e]=r(this.value);x(this.getRangeDatesElements(t,e),"add","gux-hovered")}}async onKeyDown(t){switch(t.key){case" ":case"Enter":t.preventDefault(),await this.onDateClick(this.previewValue);break;case"ArrowDown":t.preventDefault(),this.previewValue=new Date(this.previewValue.setDate(this.previewValue.getDate()+7)),this.onDateMouseEnter(this.previewValue),s((()=>{this.focusPreviewDate()}));break;case"ArrowUp":t.preventDefault(),this.previewValue=new Date(this.previewValue.setDate(this.previewValue.getDate()-7)),this.onDateMouseEnter(this.previewValue),s((()=>{this.focusPreviewDate()}));break;case"ArrowLeft":t.preventDefault(),this.previewValue=new Date(this.previewValue.setDate(this.previewValue.getDate()-1)),this.onDateMouseEnter(this.previewValue),s((()=>{this.focusPreviewDate()}));break;case"ArrowRight":t.preventDefault(),this.previewValue=new Date(this.previewValue.setDate(this.previewValue.getDate()+1)),this.onDateMouseEnter(this.previewValue),s((()=>{this.focusPreviewDate()}));break;case"PageUp":this.incrementPreviewDateByMonth(1),this.onDateMouseEnter(this.previewValue);break;case"PageDown":this.incrementPreviewDateByMonth(-1),this.onDateMouseEnter(this.previewValue)}}componentWillLoad(){if(h(this.root,{variant:this.mode}),this.locale=l(this.root),this.startDayOfWeek=this.startDayOfWeek||c(this.locale),!this.value){const t=new Date;t.setHours(0,0,0,0),this.value="range"===this.mode?i(t,t):o(t)}this.previewValue=d(this.value)}componentDidRender(){this.updateRangeElements()}renderMonthHeader(){return n("div",{class:"gux-month-list"},Array.from(Array(this.numberOfMonths).keys()).map((t=>{const e=function(t,e){const n=new Date(t);return n.setDate(1),n.setMonth(n.getMonth()+e),n}(this.previewValue,t);return n("label",null,b(e,this.locale))})))}renderCalendarTable(t){return n("table",null,n("tr",null,function(t,e){const n=[],a=new Date(1970,0,4);for(let e=0;e<7;e++){const e=a.toLocaleString(t,{weekday:"narrow"});n.push(e),a.setDate(a.getDate()+1)}return(s=n).concat(s.splice(0,(i=e)>s.length?i%s.length:i));var s,i}(this.locale,this.startDayOfWeek).map((t=>n("th",null,t)))),this.getMonthDays(t).map((t=>n("tr",null,t.map((t=>n("td",{tabindex:this.isFocusableDate(t)?"0":"-1",class:t.class,"aria-hidden":t.hidden?"true":"false","aria-disabled":t.disabled?"true":"false","data-date":t.date.getTime(),onClick:()=>{this.onDateClick(t.date)},onMouseEnter:()=>this.onDateMouseEnter(t.date),onKeyDown:t=>{this.onKeyDown(t)}},t.date.getDate(),n("span",{class:"gux-sr-only"},b(t.date,this.locale)))))))))}render(){return n("div",{class:"gux-calendar"},n("div",{class:"gux-header"},n("button",{type:"button",class:"gux-left",onClick:()=>this.incrementPreviewDateByMonth(-1),tabindex:"-1","aria-hidden":"true"},n("gux-icon",{decorative:!0,"icon-name":"chevron-small-left"})),this.renderMonthHeader(),n("button",{type:"button",class:"gux-right",onClick:()=>this.incrementPreviewDateByMonth(1),tabindex:"-1","aria-hidden":"true"},n("gux-icon",{decorative:!0,"icon-name":"chevron-small-right"}))),n("div",{class:"gux-content"},Array.from(Array(this.numberOfMonths).keys()).map((t=>this.renderCalendarTable(t)))))}get root(){return a(this)}};f.style=":host{display:inline-block}.gux-calendar{margin-top:2px;border:1px solid #b4bccb;border-radius:4px}.gux-calendar .gux-header{position:relative;display:flex;align-items:center;justify-content:space-between;height:16px;padding:16px;color:#fdfdfd;background-color:#2a60c8;border-top-left-radius:3px;border-top-right-radius:3px}.gux-calendar .gux-header button{position:absolute;padding:5px;color:#fdfdfd;cursor:pointer;background:none;border:none;outline:none}.gux-calendar .gux-header button:focus-visible{outline:#75a8ff auto 5px}.gux-calendar .gux-header button.gux-left{left:18px}.gux-calendar .gux-header button.gux-right{right:18px}.gux-calendar .gux-header button gux-icon{width:16px;height:16px;pointer-events:none}.gux-calendar .gux-header .gux-month-list{display:flex;justify-content:space-between;width:100%}.gux-calendar .gux-header .gux-month-list label{width:100%;text-align:center;font-size:12px;line-height:20px;font-family:Roboto, sans-serif;font-weight:400;font-weight:700}.gux-calendar .gux-content{display:flex;align-items:flex-start;padding:20px 24px;color:#2e394c;background-color:#fdfdfd;border-bottom-right-radius:3px;border-bottom-left-radius:3px}.gux-calendar .gux-content table{width:168px;text-align:left;table-layout:fixed;border-spacing:0;-ms-user-select:none;user-select:none}.gux-calendar .gux-content table:not(:last-child){padding-right:24px}.gux-calendar .gux-content table tr{height:28px}.gux-calendar .gux-content table tr:empty{display:none}.gux-calendar .gux-content table tr th,.gux-calendar .gux-content table tr td{width:28px;height:28px;padding:0;margin:0;text-align:center;font-family:Roboto, sans-serif;font-weight:400;font-size:12px;line-height:20px}.gux-calendar .gux-content table tr th{font-family:Roboto, sans-serif;font-weight:400;font-weight:700}.gux-calendar .gux-content table tr td{cursor:pointer}.gux-calendar .gux-content table tr td.gux-hovered{background-color:#deeaff}.gux-calendar .gux-content table tr td.gux-selected{color:#fdfdfd;background-color:#2a60c8;border-radius:4px}.gux-calendar .gux-content table tr td.gux-selected.gux-start-date{border-radius:4px 0 0 4px}.gux-calendar .gux-content table tr td.gux-selected.gux-end-date{border-radius:0 4px 4px 0}.gux-calendar .gux-content table tr td:hover:not(.gux-calendar .gux-content table tr td.gux-start-date):not(.gux-calendar .gux-content table tr td.gux-end-date){color:#fdfdfd;background-color:#2a60c8;border-radius:4px}.gux-calendar .gux-content table tr td.gux-disabled{color:rgba(46, 57, 76, 0.5);pointer-events:none}.gux-calendar .gux-content table tr td.gux-not-in-month{color:rgba(107, 117, 133, 0.5)}.gux-calendar .gux-content table tr td.gux-not-in-month:hover{color:#2e394c;background-color:#e2e6ee}.gux-calendar .gux-content table tr td.gux-not-in-month.gux-hidden{visibility:hidden}.gux-sr-only{position:absolute;top:auto;left:-10000px;width:1px;height:1px;overflow:hidden}";export{f as gux_calendar}
|
@@ -1 +1 @@
|
|
1
|
-
import{r,h as d,g as a}from"./p-7d26b2e1.js";import{t as e}from"./p-
|
1
|
+
import{r,h as d,g as a}from"./p-7d26b2e1.js";import{t as e}from"./p-6517ed89.js";const o=class{constructor(d){r(this,d),this.accent="bordered"}componentWillLoad(){e(this.root,{variant:this.accent})}render(){return d("div",{class:{"gux-card":!0,[`gux-${this.accent}`]:!0}},d("slot",null))}get root(){return a(this)}};o.style=":host{display:block;width:fit-content}.gux-card{box-sizing:border-box;padding:var(--gse-ui-card-padding);background-color:var(--gse-ui-card-backgroundColor);border:var(--gse-ui-card-default-border-width) var(--gse-ui-card-default-border-style) var(--gse-ui-card-default-border-color);border-radius:var(--gse-ui-card-borderRadius)}.gux-card.gux-bordered{border:var(--gse-ui-card-default-border-width) var(--gse-ui-card-default-border-style) var(--gse-ui-card-default-border-color)}.gux-card.gux-raised{border:var(--gse-ui-card-raised-border-width) var(--gse-ui-card-raised-border-style) var(--gse-ui-card-raised-border-color);box-shadow:var(--gse-ui-card-raised-boxShadow-x) var(--gse-ui-card-raised-boxShadow-y) var(--gse-ui-card-raised-boxShadow-blur) var(--gse-ui-card-raised-boxShadow-spread) var(--gse-ui-card-raised-boxShadow-color)}.gux-card.gux-borderless{border:var(--gse-ui-card-borderless-border-width) var(--gse-ui-card-borderless-border-style) var(--gse-ui-card-borderless-border-color)}";export{o as gux_card}
|
@@ -1 +1 @@
|
|
1
|
-
import{r as t,h as o,H as s,g as e}from"./p-7d26b2e1.js";import{a as i}from"./p-091f51f6.js";import{t as r}from"./p-
|
1
|
+
import{r as t,h as o,H as s,g as e}from"./p-7d26b2e1.js";import{a as i}from"./p-091f51f6.js";import{t as r}from"./p-6517ed89.js";import{h as n}from"./p-837e3eff.js";import{c as a}from"./p-e459974a.js";const u=class{constructor(o){t(this,o),this.isShown=!1}forceUpdate(t){t&&this.popperInstance&&this.popperInstance.update()}onKeydown(t){if(t.stopPropagation(),this.isShown)switch(t.key){case"Escape":case"ArrowLeft":case"ArrowUp":return void this.root.focus();case"ArrowDown":return t.preventDefault(),void this.focusOnMenu();case"Enter":return void(this.hideDelayTimeout=i((()=>{this.focusOnMenu()})))}}onKeyup(t){t.stopPropagation()," "!==t.key||(this.menuContentElement.contains(document.activeElement)?this.root.focus():this.hideDelayTimeout=i((()=>{this.focusOnMenu()})))}onmouseenter(){this.show()}onMouseleave(){this.hide()}onClick(t){0!==t.detail&&this.hide(),this.root.focus()}onFocusin(){this.show()}onFocusout(){this.hide()}show(){clearTimeout(this.hideDelayTimeout),this.isShown=!0}hide(){this.isShown&&(this.hideDelayTimeout=setTimeout((()=>{this.isShown=!1}),n))}runPopper(){this.popperInstance=a(this.targetElement,document.querySelector("gux-menu"),{modifiers:[{name:"offset",options:{offset:[0,16]}},{name:"arrow",options:{padding:16}}],placement:"bottom-start"})}destroyPopper(){this.popperInstance&&(this.popperInstance.destroy(),this.popperInstance=null)}focusOnMenu(){if(this.menuContentElement.contains(document.activeElement))return;const t=this.root.querySelector("gux-menu");Array.from(t.children)[0].guxFocus()}componentWillLoad(){r(this.root)}componentDidLoad(){this.runPopper()}disconnectedCallback(){this.destroyPopper()}render(){return o(s,{tabIndex:0,"aria-haspopup":"true"},o("span",{ref:t=>this.targetElement=t},o("slot",{name:"target"})),o("div",{class:{"gux-flyout-menu-content":!0,"gux-shown":this.isShown},ref:t=>this.menuContentElement=t},o("slot",{name:"menu"})))}get root(){return e(this)}static get watchers(){return{isShown:["forceUpdate"]}}};u.style=":host{z-index:var(--gux-zindex-popover, 2);color:#2e394c;cursor:default}:host(:focus){outline:none}:host(:focus-visible){outline:3px solid #aac9ff;outline-offset:1px;box-shadow:0 0 0 1px #fdfdfd}.gux-flyout-menu-content{display:none;margin:0}.gux-flyout-menu-content.gux-shown{display:flex}.gux-arrow,.gux-arrow::before{position:absolute;top:-3px;width:10px;height:10px;background:inherit}.gux-arrow::before{visibility:visible;content:'';border-top:1px solid #b4bccb;border-left:1px solid #b4bccb;transform:rotate(45deg)}";export{u as gux_flyout_menu_beta}
|
@@ -0,0 +1 @@
|
|
1
|
+
import{r as t,c as o,h as s,g as i}from"./p-7d26b2e1.js";import{a as e,c as r,o as a,f as p,s as h,b as n}from"./p-4e2b5bcf.js";import{O as d}from"./p-9d18d475.js";import{t as c}from"./p-6517ed89.js";import{f as l}from"./p-82ffe3cc.js";const u=class{constructor(s){t(this,s),this.guxdismiss=o(this,"guxdismiss",7),this.for=void 0,this.position="bottom",this.displayDismissButton=void 0,this.closeOnClickOutside=!1,this.isOpen=!1}checkForClickOutside(t){const o=t.composedPath(),s=l(this.root,this.for),i=o.includes(s);!this.closeOnClickOutside&&this.displayDismissButton||!this.isOpen||i||this.dismiss()}runUpdatePosition(){this.root.isConnected?this.cleanupUpdatePosition=e(l(this.root,this.for),this.popupElement,(()=>this.updatePosition()),{ancestorScroll:!0,elementResize:!0,animationFrame:!0,ancestorResize:!0}):this.disconnectedCallback()}updatePosition(){const t=l(this.root,this.for);this.popupElement&&r(t,this.popupElement,{placement:this.position,middleware:[a(7),p(),h(),n({element:this.arrowElement,padding:16})]}).then((({x:t,y:o,middlewareData:s,placement:i})=>{Object.assign(this.popupElement.style,{left:`${t}px`,top:`${o}px`});const e={top:"bottom",right:"left",bottom:"top",left:"right"}[i.split("-")[0]];if(s.arrow){const{x:t,y:o}=s.arrow;this.popupElement.setAttribute("data-placement",i),Object.assign(this.arrowElement.style,{left:null!=t?`${t}px`:"",top:null!=o?`${o}px`:"",right:"",bottom:"",[e]:"-6.5px",transform:"rotate(45deg)"})}}))}dismiss(){this.guxdismiss.emit().defaultPrevented||(this.isOpen=!1)}connectedCallback(){c(this.root,{variant:this.position})}componentDidLoad(){this.isOpen&&this.runUpdatePosition()}componentDidUpdate(){this.isOpen?this.runUpdatePosition():this.cleanupUpdatePosition&&this.cleanupUpdatePosition()}disconnectedCallback(){this.cleanupUpdatePosition&&this.cleanupUpdatePosition()}render(){return s("div",{ref:t=>this.popupElement=t,class:{"gux-hidden":!this.isOpen,"gux-popover-wrapper":!0},"data-placement":!0},s("div",{ref:t=>this.arrowElement=t,class:"gux-arrow"}),this.displayDismissButton&&s("gux-dismiss-button",{onClick:this.dismiss.bind(this)}),s("div",{class:"gux-popover-content"},s("slot",null)))}get root(){return i(this)}};(function(t,o,s,i){var e,r=arguments.length,a=r<3?o:null===i?i=Object.getOwnPropertyDescriptor(o,s):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(t,o,s,i);else for(var p=t.length-1;p>=0;p--)(e=t[p])&&(a=(r<3?e(a):r>3?e(o,s,a):e(o,s))||a);r>3&&a&&Object.defineProperty(o,s,a)})([d({triggerEvents:"mousedown"})],u.prototype,"checkForClickOutside",null),u.style=".gux-popover-wrapper{position:absolute;top:0;left:0;z-index:var(--gux-zindex-popover, 2);display:inline-block;padding:8px 0px;background-color:var(--gse-ui-popover-backgroundColor);border-radius:var(--gse-ui-popover-borderRadius);box-shadow:var(--gse-ui-popover-boxShadow-x) var(--gse-ui-popover-boxShadow-y) var(--gse-ui-popover-boxShadow-blur) var(--gse-ui-popover-boxShadow-spread) var(--gse-ui-tooltip-boxShadow-color)}.gux-popover-wrapper.gux-hidden{display:none}.gux-popover-wrapper .gux-arrow{position:absolute;width:var(--gse-ui-popover-anchor-width);height:var(--gse-ui-popover-anchor-width);background:var(--gse-ui-popover-backgroundColor)}";export{u as gux_popover_list}
|
@@ -1 +1 @@
|
|
1
|
-
import{r as t,c as e,f as i,h as o,g as s,H as n}from"./p-7d26b2e1.js";import{O as r}from"./p-9d18d475.js";import{b as a}from"./p-deee079e.js";import{s as u}from"./p-d176c2ae.js";import{o as l,c as d}from"./p-3f5341ea.js";import{b as h}from"./p-091f51f6.js";import{t as c}from"./p-dc84cec7.js";import{O as g}from"./p-f34ce7dc.js";import{k as x,g as p,s as f,c as m,a as b,b as v,h as w,d as y,e as S,f as F,i as j,j as k,m as C,o as z}from"./p-55cf6d81.js";import{w as L}from"./p-76ff3e75.js";import{r as E}from"./p-cbcbd1bb.js";import"./p-8a133b9b.js";const R={filterResults:"Type to filter dropdown results",noSelection:"Select...",dropdown:"Dropdown"};var O=function(t,e,i,o){var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,o);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};const T=class{constructor(i){t(this,i),this.guxexpanded=e(this,"guxexpanded",7),this.guxcollapsed=e(this,"guxcollapsed",7),this.guxfilter=e(this,"guxfilter",7),this.value=void 0,this.disabled=!1,this.required=!1,this.loading=!1,this.placeholder=void 0,this.filterable=!1,this.filterType="none",this.hasError=!1,this.expanded=!1,this.filter=""}watchExpanded(t){t||(this.filter="")}watchValue(t){this.validateValue(t,this.listboxElement)}handleFilter(t){this.guxfilter.emit(t)}onKeydown(t){switch(t.key){case"Escape":return this.isFilterable()&&document.activeElement===this.listboxElement?this.filterElement.focus():void this.collapseListbox("focusFieldButton");case"Tab":return this.shiftTabFromFilterListbox(t)?(t.preventDefault(),this.filterElement.focus()):this.shiftTabFromExpandedFilterInput(t)?(t.preventDefault(),this.collapseListbox("focusFieldButton")):void this.collapseListbox("noFocusChange");case"ArrowDown":return void(this.activeElementNotListbox()&&(t.preventDefault(),this.expanded=!0))}}onInternallistboxoptionsupdated(t){t.stopPropagation(),i(this.root)}onBlur(t){this.stopPropagationOfInternalFocusEvents(t)}onFocus(t){this.stopPropagationOfInternalFocusEvents(t)}onFocusout(t){this.stopPropagationOfInternalFocusEvents(t)}onFocusin(t){this.stopPropagationOfInternalFocusEvents(t)}onClickOutside(){this.collapseListbox("noFocusChange")}onMutation(){var t;this.listboxElement||(this.listboxElement=null===(t=this.root)||void 0===t?void 0:t.querySelector("gux-listbox"),this.applyListboxEventListeners())}onInternalExpanded(t){t.stopPropagation(),this.guxexpanded.emit(),this.listboxElement&&h((()=>{this.listboxElement.focus(),this.isFilterable()&&this.filterElement&&this.filterElement.focus()}))}onInternalCollapsed(t){t.stopPropagation(),this.guxcollapsed.emit()}connectedCallback(){var t;this.listboxElement=null===(t=this.root)||void 0===t?void 0:t.querySelector("gux-listbox"),this.listboxElement&&this.validateValue(this.value,this.listboxElement)}async componentWillLoad(){c(this.root),this.i18n=await a(this.root,R),l(this.root,(()=>{i(this.root)}))}componentDidLoad(){this.applyListboxEventListeners()}componentWillRender(){this.listboxElement&&(this.validateValue(this.value,this.listboxElement),this.listboxElement.loading=this.loading,this.listboxElement.filterType=this.filterType,this.listboxElement.filter=this.filter)}showTooltip(){var t;null===(t=this.truncateElement)||void 0===t||t.setShowTooltip()}hideTooltip(){var t;null===(t=this.truncateElement)||void 0===t||t.setHideTooltip()}validateValue(t,e){void 0!==t?this.getOptionElementByValue(t)&&(e.value=t):e&&(e.value=t)}applyListboxEventListeners(){var t,e;null===(t=this.listboxElement)||void 0===t||t.addEventListener("input",(t=>{t.stopPropagation(),this.updateValue(t.target.value)})),null===(e=this.listboxElement)||void 0===e||e.addEventListener("change",(t=>{t.stopPropagation()}))}stopPropagationOfInternalFocusEvents(t){if(this.root.contains(t.relatedTarget))return t.stopImmediatePropagation()}isFilterable(){return this.filterable||"starts-with"===this.filterType||"custom"===this.filterType}get optionElements(){return x(this.listboxElement)}getOptionElementByValue(t){return this.optionElements.find((e=>e.value===t))}fieldButtonClick(){this.expanded=!this.expanded}filterInput(t){t.stopPropagation(),this.filter=this.filterElement.value}shiftTabFromExpandedFilterInput(t){return t.shiftKey&&this.isFilterable()&&this.expanded&&!(document.activeElement===this.listboxElement)}shiftTabFromFilterListbox(t){return t.shiftKey&&this.isFilterable()&&document.activeElement===this.listboxElement}activeElementNotListbox(){return document.activeElement!==this.listboxElement}filterKeydown(t){switch(t.key){case"ArrowDown":return t.stopImmediatePropagation(),void this.listboxElement.focus();case"Enter":return this.listboxElement.guxSelectActive(),void t.preventDefault()}}filterKeyup(t){" "!==t.key||t.preventDefault()}collapseListbox(t){this.expanded&&(this.expanded=!1),"focusFieldButton"===t&&this.fieldButtonElement.focus()}updateValue(t){this.value!==t&&(this.value=t,u(this.root,"input"),u(this.root,"change")),this.collapseListbox("focusFieldButton")}getTypeaheadText(t){const e=t.length;if(e>0&&!this.loading){const i=p(this.listboxElement,t);if(i&&"custom"!==this.filterType)return i.textContent.trim().substring(e)}return""}renderTargetDisplay(){const t=this.getOptionElementByValue(this.value);return t?o("div",{class:"gux-selected-option"},this.renderSelectedItem(t)):o("div",{class:"gux-placeholder"},this.placeholder||this.i18n("noSelection"))}renderSelectedItem(t){const e=t.tagName.toLowerCase();switch(e){case"gux-option":return o("gux-truncate",{ref:t=>this.truncateElement=t},t.textContent);case"gux-option-icon":return this.renderIconOption(t);default:return e}}renderIconOption(t){let e=null;return null!==t.iconColor&&(e={color:t.iconColor}),o("span",{class:"gux-selected-icon"},o("gux-icon",{"icon-name":t.iconName,style:e,decorative:!0}),o("gux-truncate",{ref:t=>this.truncateElement=t},t.textContent))}renderFilterInputField(){if(this.expanded&&this.isFilterable())return o("div",{class:"gux-field gux-input-field"},o("div",{class:"gux-field-content"},o("div",{class:"gux-filter"},o("div",{class:"gux-filter-display"},o("span",{class:"gux-filter-text"},this.filter),o("span",{class:"gux-filter-suggestion"},this.getTypeaheadText(this.filter))),o("div",{class:"input-and-dropdown-button"},o("input",{onClick:this.fieldButtonClick.bind(this),class:"gux-filter-input",type:"text","aria-label":this.i18n("filterResults"),ref:t=>this.filterElement=t,onInput:this.filterInput.bind(this),onKeyDown:this.filterKeydown.bind(this),onKeyUp:this.filterKeyup.bind(this)})))))}renderPopup(){return o("div",{slot:"popup",class:"gux-listbox-container"},o("slot",null))}renderTarget(){return o("div",{class:{"gux-target-container-expanded":this.expanded&&this.isFilterable(),"gux-target-container-collapsed":!(this.expanded&&this.isFilterable()),"gux-error":this.hasError},slot:"target"},this.renderFilterInputField(),o("button",{type:"button",class:"gux-field gux-field-button",disabled:d(this.root),onClick:this.fieldButtonClick.bind(this),onFocusin:this.showTooltip.bind(this),onFocusout:this.hideTooltip.bind(this),ref:t=>this.fieldButtonElement=t,"aria-haspopup":"listbox","aria-expanded":this.expanded.toString()},this.renderTargetContent(),this.renderRadialLoading(),o("gux-icon",{class:{"gux-expand-icon":!0},"screenreader-text":this.i18n("dropdown"),iconName:"chevron-small-down"})))}renderTargetContent(){if(!this.expanded||!this.isFilterable())return o("div",{class:"gux-field-content"},this.renderTargetDisplay())}renderRadialLoading(){if(this.loading&&!this.expanded)return o("gux-radial-loading",{context:"input"})}render(){return o("gux-popup",{expanded:this.expanded&&(!this.loading||this.isFilterable()),disabled:this.disabled},this.renderTarget(),this.renderPopup())}static get delegatesFocus(){return!0}get root(){return s(this)}static get watchers(){return{expanded:["watchExpanded"],value:["watchValue"],filter:["handleFilter"]}}};O([r({triggerEvents:"mousedown"})],T.prototype,"onClickOutside",null),O([g({childList:!0,subtree:!0})],T.prototype,"onMutation",null),T.style=":host{color:#2e394c}.gux-field,.gux-target-container-expanded{all:unset;box-sizing:border-box;display:flex;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:center;justify-content:center;width:100%;height:32px;padding:6px 8px;font-family:inherit;font-size:12px;line-height:1.6667;cursor:pointer;background-color:#f6f7f9}.gux-error.gux-target-container-collapsed .gux-field-button,.gux-error.gux-target-container-expanded{border-color:#ea0b0b}.gux-field.gux-input-field{height:30px}.gux-field .gux-field-content{--gux-zindex-tooltip:3;display:flex;flex:1 1 0;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:flex-start;justify-content:flex-start;min-width:0;height:100%}.gux-field .gux-field-content .gux-filter,.gux-field .gux-field-content .gux-selected-option,.gux-field .gux-field-content .gux-placeholder{flex:1 1 auto;align-self:auto;order:0;padding:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.gux-field .gux-field-content .gux-filter{position:relative;height:100%}.gux-field .gux-field-content .gux-filter .gux-filter-input{all:unset;width:100%;color:transparent;caret-color:#2e394c}.gux-field .gux-field-content .gux-filter .gux-filter-display{white-space:pre}.gux-field .gux-field-content .gux-filter .gux-filter-display .gux-filter-text{color:#2e394c}.gux-field .gux-field-content .gux-filter .gux-filter-display .gux-filter-suggestion{color:#596373}.gux-field .gux-field-content .gux-filter .gux-filter-input,.gux-field .gux-field-content .gux-filter .gux-filter-display{position:absolute}.gux-field .gux-field-content .gux-placeholder{color:#596373}.gux-field .gux-expand-icon{flex:0 0 auto;align-self:auto;order:0;width:16px;height:16px;padding-left:8px;color:#596373}.gux-target-container-expanded{border:1px solid #6b7585;border-radius:4px;box-shadow:inset 0 0 4px rgba(32, 41, 55, 0.16)}.gux-target-container-expanded:focus-visible,.gux-target-container-expanded:focus-within{outline:3px solid #aac9ff;outline-offset:1px;box-shadow:0 0 0 1px #fdfdfd}.gux-target-container-expanded .gux-filter-input{background-color:inherit;border:none}.gux-target-container-expanded .gux-filter-input:focus{border:none;outline:none}.gux-target-container-expanded .gux-field-button{width:auto;height:30px;padding:0 0 0 8px;margin:0;background:inherit;border:none;outline:none;box-shadow:none}.gux-target-container-expanded .gux-field-button:focus{outline:none}.gux-target-container-collapsed .gux-field-button{border:1px solid #6b7585;border-radius:4px;box-shadow:inset 0 0 4px rgba(32, 41, 55, 0.16)}.gux-target-container-collapsed .gux-field-button:focus-visible,.gux-target-container-collapsed .gux-field-button:focus-within{outline:3px solid #aac9ff;outline-offset:1px;box-shadow:0 0 0 1px #fdfdfd}.gux-listbox-container{box-sizing:border-box;margin:0;color:#2e394c}gux-popup::part(gux-popup-container){width:inherit}.gux-selected-icon{display:flex;align-items:center}.gux-selected-icon gux-icon{width:16px;height:16px;padding-right:8px}";const A=["gux-option","gux-option-icon"].join(","),I={noMatchesHeader:"Sorry, this menu is empty right now.",noMatchesMessage:"Please try again later.",loading:"Loading..."},M=class{constructor(i){t(this,i),this.internallistboxoptionsupdated=e(this,"internallistboxoptionsupdated",7),this.value=void 0,this.loading=!1,this.filter="",this.filterType="none",this.emptyMessage=void 0,this.selectedValues=[],this.listboxOptions=[],this.allListboxOptionsFiltered=void 0}onFocus(){f(this.root)}onBlur(){m(this.root)}onKeydown(t){switch(t.key){case"Enter":return t.preventDefault(),void j(this.root,(t=>this.updateValue(t)));case"ArrowDown":return t.preventDefault(),void(S(this.root)?(t.stopPropagation(),F(this.root)):v(this.root));case"ArrowUp":return t.preventDefault(),void(w(this.root)?(t.stopPropagation(),y(this.root)):b(this.root));case"Home":return t.preventDefault(),void v(this.root);case"End":return t.preventDefault(),void b(this.root);case" ":return void t.preventDefault()}1!==t.key.length||k(this.root,t.key)}onKeyup(t){" "!==t.key||j(this.root,(t=>this.updateValue(t)))}onMousemove(){m(this.root)}onClick(t){L(A,t,(t=>{z(t,(t=>this.updateValue(t)))}))}async guxSelectActive(){j(this.root,(t=>this.updateValue(t)))}setListboxOptions(){this.value&&(this.selectedValues=this.value.split(",")),this.listboxOptions=Array.from(this.root.children),this.internallistboxoptionsupdated.emit()}updateValue(t){this.value!==t&&(this.value=t),u(this.root,"input"),u(this.root,"change")}async componentWillLoad(){c(this.root),this.i18n=await a(this.root,I),this.setListboxOptions()}componentWillRender(){this.listboxOptions.forEach((t=>{t.selected=t.value===this.value,"custom"!==this.filterType&&(t.filtered=!C(t,this.filter))})),this.allListboxOptionsFiltered=0===this.listboxOptions.filter((t=>!t.filtered)).length,!this.allListboxOptionsFiltered&&this.filter?v(this.root):m(this.root)}renderHiddenSlot(){return o("div",{hidden:!0},o("slot",{onSlotchange:()=>this.setListboxOptions()}))}renderLoading(){return[o("div",{class:"gux-message-container"},o("gux-radial-loading",{context:"modal"}),o("span",null,this.i18n("loading"))),this.renderHiddenSlot()]}renderAllListboxOptionsFiltered(){return[o("div",{class:"gux-message-container"},o("div",{class:"gux-no-matches"},this.emptyMessage||[o("div",{class:"gux-no-matches-header"},this.i18n("noMatchesHeader")),o("div",null,this.i18n("noMatchesMessage"))])),this.renderHiddenSlot()]}render(){return this.loading?this.renderLoading():this.allListboxOptionsFiltered?this.renderAllListboxOptionsFiltered():o(n,{role:"listbox",tabindex:0},o("slot",{onSlotchange:()=>this.setListboxOptions()}))}get root(){return s(this)}};M.style=":host{box-sizing:border-box;display:block;max-height:20rem;padding:var(--gse-ui-menu-padding);margin:0;overflow-y:auto;background:var(--gse-ui-menu-backgroundColor);border:var(--gse-ui-menu-border-width) var(--gse-ui-menu-border-style) var(--gse-ui-menu-border-color);border-radius:var(--gse-ui-menu-borderRadius);box-shadow:var(--gse-ui-menu-boxShadow-x) var(--gse-ui-menu-boxShadow-y) var(--gse-ui-menu-boxShadow-blur) var(--gse-ui-menu-boxShadow-spread) var(--gse-ui-menu-boxShadow-color);outline:none}:host(:focus){outline:var(--gse-semantic-focusRing-width) solid var(--gse-semantic-color-focus);outline-offset:var(--gse-semantic-focusRing-offset)}.gux-message-container{display:flex;flex-direction:column;flex-wrap:nowrap;align-content:stretch;align-items:center;justify-content:center;text-align:center}.gux-message-container .gux-no-matches{box-sizing:border-box;height:32px;font-family:var(--gse-ui-dropdown-menu-emptyState-subheader-text-fontFamily);font-weight:var(--gse-ui-dropdown-menu-emptyState-subheader-text-fontWeight);line-height:var(--gse-ui-dropdown-menu-emptyState-subheader-text-lineHeight);font-size:var(--gse-ui-dropdown-menu-emptyState-subheader-text-fontSize);color:var(--gse-ui-dropdown-menu-emptyState-subheader-foregroundColor)}.gux-message-container .gux-no-matches .gux-no-matches-header{font-family:var(--gse-ui-dropdown-menu-emptyState-header-text-fontFamily);font-weight:var(--gse-ui-dropdown-menu-emptyState-header-text-fontWeight);line-height:var(--gse-ui-dropdown-menu-emptyState-header-text-lineHeight);font-size:var(--gse-ui-dropdown-menu-emptyState-header-text-fontSize);color:var(--gse-ui-dropdown-menu-emptyState-header-foregroundColor)}";const H=class{constructor(e){t(this,e),this.value=void 0,this.active=!1,this.selected=!1,this.disabled=!1,this.filtered=!1,this.hovered=!1}onmouseenter(){this.hovered=!0}onMouseleave(){this.hovered=!1}handleActive(t){var e,i;t?null===(e=this.truncateElement)||void 0===e||e.setShowTooltip():null===(i=this.truncateElement)||void 0===i||i.setHideTooltip()}componentWillLoad(){this.root.id=this.root.id||E("gux-option")}getAriaSelected(){return!this.disabled&&(this.selected?"true":"false")}render(){return o(n,{role:"option",class:{"gux-active":this.active,"gux-disabled":this.disabled,"gux-filtered":this.filtered,"gux-hovered":this.hovered,"gux-selected":this.selected},"aria-selected":this.getAriaSelected(),"aria-disabled":this.disabled.toString()},o("gux-truncate",{ref:t=>this.truncateElement=t},o("slot",null)))}get root(){return s(this)}static get watchers(){return{active:["handleActive"]}}};H.style=":host{box-sizing:border-box;display:flex;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:center;justify-content:center;height:var(--gse-ui-menu-option-height);padding:var(--gse-ui-menu-option-padding);color:var(--gse-ui-menu-option-label-foregroundColor);word-wrap:break-word;cursor:pointer;font-family:var(--gse-ui-menu-option-label-default-text-fontFamily);font-weight:var(--gse-ui-menu-option-label-default-text-fontWeight);line-height:var(--gse-ui-menu-option-label-default-text-lineHeight);font-size:var(--gse-ui-menu-option-label-default-text-fontSize);gap:var(--gse-ui-menu-option-gap)}:host .gux-slot-container{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host(.gux-disabled){pointer-events:none;cursor:default;opacity:var(--gse-ui-menu-option-disabled-opacity)}:host(.gux-selected){font-family:var(--gse-ui-menu-option-label-active-text-fontFamily);font-weight:var(--gse-ui-menu-option-label-active-text-fontWeight);line-height:var(--gse-ui-menu-option-label-active-text-lineHeight);font-size:var(--gse-ui-menu-option-label-active-text-fontSize);background:var(--gse-ui-menu-option-selected-backgroundColor)}:host(.gux-active){outline:var(--gse-ui-menu-option-focus-border-width) var(--gse-ui-menu-option-focus-border-style) var(--gse-ui-menu-option-focus-border-color);border-radius:var(--gse-semantic-focusRing-cornerRadius)}:host(.gux-hovered:not(:disabled)){background:var(--gse-ui-menu-option-hover-backgroundColor)}:host(.gux-filtered){display:none}";export{T as gux_dropdown,M as gux_listbox,H as gux_option}
|
1
|
+
import{r as t,c as e,f as i,h as o,g as s,H as n}from"./p-7d26b2e1.js";import{O as r}from"./p-9d18d475.js";import{b as a}from"./p-deee079e.js";import{s as u}from"./p-d176c2ae.js";import{o as l,c as d}from"./p-3f5341ea.js";import{b as h}from"./p-091f51f6.js";import{t as g}from"./p-6517ed89.js";import{O as c}from"./p-f34ce7dc.js";import{k as x,g as p,s as f,c as m,a as b,b as v,h as w,d as y,e as S,f as F,i as j,j as k,m as C,o as z}from"./p-55cf6d81.js";import{w as L}from"./p-76ff3e75.js";import{r as E}from"./p-cbcbd1bb.js";import"./p-8a133b9b.js";const R={filterResults:"Type to filter dropdown results",noSelection:"Select...",dropdown:"Dropdown"};var O=function(t,e,i,o){var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,o);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);return n>3&&r&&Object.defineProperty(e,i,r),r};const T=class{constructor(i){t(this,i),this.guxexpanded=e(this,"guxexpanded",7),this.guxcollapsed=e(this,"guxcollapsed",7),this.guxfilter=e(this,"guxfilter",7),this.value=void 0,this.disabled=!1,this.required=!1,this.loading=!1,this.placeholder=void 0,this.filterable=!1,this.filterType="none",this.hasError=!1,this.expanded=!1,this.filter=""}watchExpanded(t){t||(this.filter="")}watchValue(t){this.validateValue(t,this.listboxElement)}handleFilter(t){this.guxfilter.emit(t)}onKeydown(t){switch(t.key){case"Escape":return this.isFilterable()&&document.activeElement===this.listboxElement?this.filterElement.focus():void this.collapseListbox("focusFieldButton");case"Tab":return this.shiftTabFromFilterListbox(t)?(t.preventDefault(),this.filterElement.focus()):this.shiftTabFromExpandedFilterInput(t)?(t.preventDefault(),this.collapseListbox("focusFieldButton")):void this.collapseListbox("noFocusChange");case"ArrowDown":return void(this.activeElementNotListbox()&&(t.preventDefault(),this.expanded=!0))}}onInternallistboxoptionsupdated(t){t.stopPropagation(),i(this.root)}onBlur(t){this.stopPropagationOfInternalFocusEvents(t)}onFocus(t){this.stopPropagationOfInternalFocusEvents(t)}onFocusout(t){this.stopPropagationOfInternalFocusEvents(t)}onFocusin(t){this.stopPropagationOfInternalFocusEvents(t)}onClickOutside(){this.collapseListbox("noFocusChange")}onMutation(){var t;this.listboxElement||(this.listboxElement=null===(t=this.root)||void 0===t?void 0:t.querySelector("gux-listbox"),this.applyListboxEventListeners())}onInternalExpanded(t){t.stopPropagation(),this.guxexpanded.emit(),this.listboxElement&&h((()=>{this.listboxElement.focus(),this.isFilterable()&&this.filterElement&&this.filterElement.focus()}))}onInternalCollapsed(t){t.stopPropagation(),this.guxcollapsed.emit()}connectedCallback(){var t;this.listboxElement=null===(t=this.root)||void 0===t?void 0:t.querySelector("gux-listbox"),this.listboxElement&&this.validateValue(this.value,this.listboxElement)}async componentWillLoad(){g(this.root),this.i18n=await a(this.root,R),l(this.root,(()=>{i(this.root)}))}componentDidLoad(){this.applyListboxEventListeners()}componentWillRender(){this.listboxElement&&(this.validateValue(this.value,this.listboxElement),this.listboxElement.loading=this.loading,this.listboxElement.filterType=this.filterType,this.listboxElement.filter=this.filter)}showTooltip(){var t;null===(t=this.truncateElement)||void 0===t||t.setShowTooltip()}hideTooltip(){var t;null===(t=this.truncateElement)||void 0===t||t.setHideTooltip()}validateValue(t,e){void 0!==t?this.getOptionElementByValue(t)&&(e.value=t):e&&(e.value=t)}applyListboxEventListeners(){var t,e;null===(t=this.listboxElement)||void 0===t||t.addEventListener("input",(t=>{t.stopPropagation(),this.updateValue(t.target.value)})),null===(e=this.listboxElement)||void 0===e||e.addEventListener("change",(t=>{t.stopPropagation()}))}stopPropagationOfInternalFocusEvents(t){if(this.root.contains(t.relatedTarget))return t.stopImmediatePropagation()}isFilterable(){return this.filterable||"starts-with"===this.filterType||"custom"===this.filterType}get optionElements(){return x(this.listboxElement)}getOptionElementByValue(t){return this.optionElements.find((e=>e.value===t))}fieldButtonClick(){this.expanded=!this.expanded}filterInput(t){t.stopPropagation(),this.filter=this.filterElement.value}shiftTabFromExpandedFilterInput(t){return t.shiftKey&&this.isFilterable()&&this.expanded&&!(document.activeElement===this.listboxElement)}shiftTabFromFilterListbox(t){return t.shiftKey&&this.isFilterable()&&document.activeElement===this.listboxElement}activeElementNotListbox(){return document.activeElement!==this.listboxElement}filterKeydown(t){switch(t.key){case"ArrowDown":return t.stopImmediatePropagation(),void this.listboxElement.focus();case"Enter":return this.listboxElement.guxSelectActive(),void t.preventDefault()}}filterKeyup(t){" "!==t.key||t.preventDefault()}collapseListbox(t){this.expanded&&(this.expanded=!1),"focusFieldButton"===t&&this.fieldButtonElement.focus()}updateValue(t){this.value!==t&&(this.value=t,u(this.root,"input"),u(this.root,"change")),this.collapseListbox("focusFieldButton")}getTypeaheadText(t){const e=t.length;if(e>0&&!this.loading){const i=p(this.listboxElement,t);if(i&&"custom"!==this.filterType)return i.textContent.trim().substring(e)}return""}renderTargetDisplay(){const t=this.getOptionElementByValue(this.value);return t?o("div",{class:"gux-selected-option"},this.renderSelectedItem(t)):o("div",{class:"gux-placeholder"},this.placeholder||this.i18n("noSelection"))}renderSelectedItem(t){const e=t.tagName.toLowerCase();switch(e){case"gux-option":return o("gux-truncate",{ref:t=>this.truncateElement=t},t.textContent);case"gux-option-icon":return this.renderIconOption(t);default:return e}}renderIconOption(t){let e=null;return null!==t.iconColor&&(e={color:t.iconColor}),o("span",{class:"gux-selected-icon"},o("gux-icon",{"icon-name":t.iconName,style:e,decorative:!0}),o("gux-truncate",{ref:t=>this.truncateElement=t},t.textContent))}renderFilterInputField(){if(this.expanded&&this.isFilterable())return o("div",{class:"gux-field gux-input-field"},o("div",{class:"gux-field-content"},o("div",{class:"gux-filter"},o("div",{class:"gux-filter-display"},o("span",{class:"gux-filter-text"},this.filter),o("span",{class:"gux-filter-suggestion"},this.getTypeaheadText(this.filter))),o("div",{class:"input-and-dropdown-button"},o("input",{onClick:this.fieldButtonClick.bind(this),class:"gux-filter-input",type:"text","aria-label":this.i18n("filterResults"),ref:t=>this.filterElement=t,onInput:this.filterInput.bind(this),onKeyDown:this.filterKeydown.bind(this),onKeyUp:this.filterKeyup.bind(this)})))))}renderPopup(){return o("div",{slot:"popup",class:"gux-listbox-container"},o("slot",null))}renderTarget(){return o("div",{class:{"gux-target-container-expanded":this.expanded&&this.isFilterable(),"gux-target-container-collapsed":!(this.expanded&&this.isFilterable()),"gux-error":this.hasError},slot:"target"},this.renderFilterInputField(),o("button",{type:"button",class:"gux-field gux-field-button",disabled:d(this.root),onClick:this.fieldButtonClick.bind(this),onFocusin:this.showTooltip.bind(this),onFocusout:this.hideTooltip.bind(this),ref:t=>this.fieldButtonElement=t,"aria-haspopup":"listbox","aria-expanded":this.expanded.toString()},this.renderTargetContent(),this.renderRadialLoading(),o("gux-icon",{class:{"gux-expand-icon":!0},"screenreader-text":this.i18n("dropdown"),iconName:"chevron-small-down"})))}renderTargetContent(){if(!this.expanded||!this.isFilterable())return o("div",{class:"gux-field-content"},this.renderTargetDisplay())}renderRadialLoading(){if(this.loading&&!this.expanded)return o("gux-radial-loading",{context:"input"})}render(){return o("gux-popup",{expanded:this.expanded&&(!this.loading||this.isFilterable()),disabled:this.disabled},this.renderTarget(),this.renderPopup())}static get delegatesFocus(){return!0}get root(){return s(this)}static get watchers(){return{expanded:["watchExpanded"],value:["watchValue"],filter:["handleFilter"]}}};O([r({triggerEvents:"mousedown"})],T.prototype,"onClickOutside",null),O([c({childList:!0,subtree:!0})],T.prototype,"onMutation",null),T.style=":host{color:#2e394c}.gux-field,.gux-target-container-expanded{all:unset;box-sizing:border-box;display:flex;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:center;justify-content:center;width:100%;height:32px;padding:6px 8px;font-family:inherit;font-size:12px;line-height:1.6667;cursor:pointer;background-color:#f6f7f9}.gux-error.gux-target-container-collapsed .gux-field-button,.gux-error.gux-target-container-expanded{border-color:#ea0b0b}.gux-field.gux-input-field{height:30px}.gux-field .gux-field-content{--gux-zindex-tooltip:3;display:flex;flex:1 1 0;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:flex-start;justify-content:flex-start;min-width:0;height:100%}.gux-field .gux-field-content .gux-filter,.gux-field .gux-field-content .gux-selected-option,.gux-field .gux-field-content .gux-placeholder{flex:1 1 auto;align-self:auto;order:0;padding:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.gux-field .gux-field-content .gux-filter{position:relative;height:100%}.gux-field .gux-field-content .gux-filter .gux-filter-input{all:unset;width:100%;color:transparent;caret-color:#2e394c}.gux-field .gux-field-content .gux-filter .gux-filter-display{white-space:pre}.gux-field .gux-field-content .gux-filter .gux-filter-display .gux-filter-text{color:#2e394c}.gux-field .gux-field-content .gux-filter .gux-filter-display .gux-filter-suggestion{color:#596373}.gux-field .gux-field-content .gux-filter .gux-filter-input,.gux-field .gux-field-content .gux-filter .gux-filter-display{position:absolute}.gux-field .gux-field-content .gux-placeholder{color:#596373}.gux-field .gux-expand-icon{flex:0 0 auto;align-self:auto;order:0;width:16px;height:16px;padding-left:8px;color:#596373}.gux-target-container-expanded{border:1px solid #6b7585;border-radius:4px;box-shadow:inset 0 0 4px rgba(32, 41, 55, 0.16)}.gux-target-container-expanded:focus-visible,.gux-target-container-expanded:focus-within{outline:3px solid #aac9ff;outline-offset:1px;box-shadow:0 0 0 1px #fdfdfd}.gux-target-container-expanded .gux-filter-input{background-color:inherit;border:none}.gux-target-container-expanded .gux-filter-input:focus{border:none;outline:none}.gux-target-container-expanded .gux-field-button{width:auto;height:30px;padding:0 0 0 8px;margin:0;background:inherit;border:none;outline:none;box-shadow:none}.gux-target-container-expanded .gux-field-button:focus{outline:none}.gux-target-container-collapsed .gux-field-button{border:1px solid #6b7585;border-radius:4px;box-shadow:inset 0 0 4px rgba(32, 41, 55, 0.16)}.gux-target-container-collapsed .gux-field-button:focus-visible,.gux-target-container-collapsed .gux-field-button:focus-within{outline:3px solid #aac9ff;outline-offset:1px;box-shadow:0 0 0 1px #fdfdfd}.gux-listbox-container{box-sizing:border-box;margin:0;color:#2e394c}gux-popup::part(gux-popup-container){width:inherit}.gux-selected-icon{display:flex;align-items:center}.gux-selected-icon gux-icon{width:16px;height:16px;padding-right:8px}";const A=["gux-option","gux-option-icon"].join(","),I={noMatchesHeader:"Sorry, this menu is empty right now.",noMatchesMessage:"Please try again later.",loading:"Loading..."},M=class{constructor(i){t(this,i),this.internallistboxoptionsupdated=e(this,"internallistboxoptionsupdated",7),this.value=void 0,this.loading=!1,this.filter="",this.filterType="none",this.emptyMessage=void 0,this.selectedValues=[],this.listboxOptions=[],this.allListboxOptionsFiltered=void 0}onFocus(){f(this.root)}onBlur(){m(this.root)}onKeydown(t){switch(t.key){case"Enter":return t.preventDefault(),void j(this.root,(t=>this.updateValue(t)));case"ArrowDown":return t.preventDefault(),void(S(this.root)?(t.stopPropagation(),F(this.root)):v(this.root));case"ArrowUp":return t.preventDefault(),void(w(this.root)?(t.stopPropagation(),y(this.root)):b(this.root));case"Home":return t.preventDefault(),void v(this.root);case"End":return t.preventDefault(),void b(this.root);case" ":return void t.preventDefault()}1!==t.key.length||k(this.root,t.key)}onKeyup(t){" "!==t.key||j(this.root,(t=>this.updateValue(t)))}onMousemove(){m(this.root)}onClick(t){L(A,t,(t=>{z(t,(t=>this.updateValue(t)))}))}async guxSelectActive(){j(this.root,(t=>this.updateValue(t)))}setListboxOptions(){this.value&&(this.selectedValues=this.value.split(",")),this.listboxOptions=Array.from(this.root.children),this.internallistboxoptionsupdated.emit()}updateValue(t){this.value!==t&&(this.value=t),u(this.root,"input"),u(this.root,"change")}async componentWillLoad(){g(this.root),this.i18n=await a(this.root,I),this.setListboxOptions()}componentWillRender(){this.listboxOptions.forEach((t=>{t.selected=t.value===this.value,"custom"!==this.filterType&&(t.filtered=!C(t,this.filter))})),this.allListboxOptionsFiltered=0===this.listboxOptions.filter((t=>!t.filtered)).length,!this.allListboxOptionsFiltered&&this.filter?v(this.root):m(this.root)}renderHiddenSlot(){return o("div",{hidden:!0},o("slot",{onSlotchange:()=>this.setListboxOptions()}))}renderLoading(){return[o("div",{class:"gux-message-container"},o("gux-radial-loading",{context:"modal"}),o("span",null,this.i18n("loading"))),this.renderHiddenSlot()]}renderAllListboxOptionsFiltered(){return[o("div",{class:"gux-message-container"},o("div",{class:"gux-no-matches"},this.emptyMessage||[o("div",{class:"gux-no-matches-header"},this.i18n("noMatchesHeader")),o("div",null,this.i18n("noMatchesMessage"))])),this.renderHiddenSlot()]}render(){return this.loading?this.renderLoading():this.allListboxOptionsFiltered?this.renderAllListboxOptionsFiltered():o(n,{role:"listbox",tabindex:0},o("slot",{onSlotchange:()=>this.setListboxOptions()}))}get root(){return s(this)}};M.style=":host{box-sizing:border-box;display:block;max-height:20rem;padding:var(--gse-ui-menu-padding);margin:0;overflow-y:auto;background:var(--gse-ui-menu-backgroundColor);border:var(--gse-ui-menu-border-width) var(--gse-ui-menu-border-style) var(--gse-ui-menu-border-color);border-radius:var(--gse-ui-menu-borderRadius);box-shadow:var(--gse-ui-menu-boxShadow-x) var(--gse-ui-menu-boxShadow-y) var(--gse-ui-menu-boxShadow-blur) var(--gse-ui-menu-boxShadow-spread) var(--gse-ui-menu-boxShadow-color);outline:none}:host(:focus){outline:var(--gse-semantic-focusRing-width) solid var(--gse-semantic-color-focus);outline-offset:var(--gse-semantic-focusRing-offset)}.gux-message-container{display:flex;flex-direction:column;flex-wrap:nowrap;align-content:stretch;align-items:center;justify-content:center;text-align:center}.gux-message-container .gux-no-matches{box-sizing:border-box;height:32px;font-family:var(--gse-ui-dropdown-menu-emptyState-subheader-text-fontFamily);font-weight:var(--gse-ui-dropdown-menu-emptyState-subheader-text-fontWeight);line-height:var(--gse-ui-dropdown-menu-emptyState-subheader-text-lineHeight);font-size:var(--gse-ui-dropdown-menu-emptyState-subheader-text-fontSize);color:var(--gse-ui-dropdown-menu-emptyState-subheader-foregroundColor)}.gux-message-container .gux-no-matches .gux-no-matches-header{font-family:var(--gse-ui-dropdown-menu-emptyState-header-text-fontFamily);font-weight:var(--gse-ui-dropdown-menu-emptyState-header-text-fontWeight);line-height:var(--gse-ui-dropdown-menu-emptyState-header-text-lineHeight);font-size:var(--gse-ui-dropdown-menu-emptyState-header-text-fontSize);color:var(--gse-ui-dropdown-menu-emptyState-header-foregroundColor)}";const H=class{constructor(e){t(this,e),this.value=void 0,this.active=!1,this.selected=!1,this.disabled=!1,this.filtered=!1,this.hovered=!1}onmouseenter(){this.hovered=!0}onMouseleave(){this.hovered=!1}handleActive(t){var e,i;t?null===(e=this.truncateElement)||void 0===e||e.setShowTooltip():null===(i=this.truncateElement)||void 0===i||i.setHideTooltip()}componentWillLoad(){this.root.id=this.root.id||E("gux-option")}getAriaSelected(){return!this.disabled&&(this.selected?"true":"false")}render(){return o(n,{role:"option",class:{"gux-active":this.active,"gux-disabled":this.disabled,"gux-filtered":this.filtered,"gux-hovered":this.hovered,"gux-selected":this.selected},"aria-selected":this.getAriaSelected(),"aria-disabled":this.disabled.toString()},o("gux-truncate",{ref:t=>this.truncateElement=t},o("slot",null)))}get root(){return s(this)}static get watchers(){return{active:["handleActive"]}}};H.style=":host{box-sizing:border-box;display:flex;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:center;justify-content:center;height:var(--gse-ui-menu-option-height);padding:var(--gse-ui-menu-option-padding);color:var(--gse-ui-menu-option-label-foregroundColor);word-wrap:break-word;cursor:pointer;font-family:var(--gse-ui-menu-option-label-default-text-fontFamily);font-weight:var(--gse-ui-menu-option-label-default-text-fontWeight);line-height:var(--gse-ui-menu-option-label-default-text-lineHeight);font-size:var(--gse-ui-menu-option-label-default-text-fontSize);gap:var(--gse-ui-menu-option-gap)}:host .gux-slot-container{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}:host(.gux-disabled){pointer-events:none;cursor:default;opacity:var(--gse-ui-menu-option-disabled-opacity)}:host(.gux-selected){font-family:var(--gse-ui-menu-option-label-active-text-fontFamily);font-weight:var(--gse-ui-menu-option-label-active-text-fontWeight);line-height:var(--gse-ui-menu-option-label-active-text-lineHeight);font-size:var(--gse-ui-menu-option-label-active-text-fontSize);background:var(--gse-ui-menu-option-selected-backgroundColor)}:host(.gux-active){outline:var(--gse-ui-menu-option-focus-border-width) var(--gse-ui-menu-option-focus-border-style) var(--gse-ui-menu-option-focus-border-color);border-radius:var(--gse-semantic-focusRing-cornerRadius)}:host(.gux-hovered:not(:disabled)){background:var(--gse-ui-menu-option-hover-backgroundColor)}:host(.gux-filtered){display:none}";export{T as gux_dropdown,M as gux_listbox,H as gux_option}
|
@@ -1 +1 @@
|
|
1
|
-
import{r as t,f as e,h as i,g as o,c as s,H as n}from"./p-7d26b2e1.js";import{b as r}from"./p-deee079e.js";import{c as a,o as p}from"./p-3f5341ea.js";import{O as l}from"./p-f34ce7dc.js";import{o as u}from"./p-3701eff0.js";import{p as h}from"./p-c10e41a9.js";import{h as c,d,G as g,a as f,g as x,v as b,b as m,e as v}from"./p-b3c9fd06.js";import{s as w}from"./p-d176c2ae.js";import{h as y}from"./p-08bc2e6b.js";import{G as j,a as k}from"./p-a733f4ca.js";import{t as C}from"./p-dc84cec7.js";import{t as R}from"./p-89af02eb.js";import{O as z}from"./p-9d18d475.js";import{b as O}from"./p-091f51f6.js";import{a as S,c as D,o as E,f as I,s as L,b as P}from"./p-4e2b5bcf.js";import{g as _}from"./p-3e6097e5.js";import{f as F}from"./p-82ffe3cc.js";import"./p-8a133b9b.js";import"./p-cbcbd1bb.js";import"./p-d0805f56.js";const T={increment:"Increment",decrement:"Decrement"};const $=class{constructor(e){t(this,e),this.clearable=void 0,this.labelPosition=void 0,this.computedLabelPosition="above",this.disabled=void 0,this.required=void 0,this.hasContent=!1,this.hasError=!1,this.hasHelp=!1}onMutation(){this.hasError=y(this.root,"error"),this.hasHelp=y(this.root,"help")}async guxForceUpdate(){this.hasContent=c(this.input),this.hasError=y(this.root,"error"),this.hasHelp=y(this.root,"help"),e(this.root)}async componentWillLoad(){this.getI18nValue=await r(this.root,T),this.setInput(),this.setLabel(),this.hasError=y(this.root,"error"),this.hasHelp=y(this.root,"help"),C(this.root,{variant:this.variant})}disconnectedCallback(){this.disabledObserver&&this.disabledObserver.disconnect(),this.requiredObserver&&this.requiredObserver.disconnect()}render(){const t=this.clearable&&this.hasContent&&!this.disabled;return i(k,{labelPosition:this.computedLabelPosition},i(j,{position:this.computedLabelPosition,required:this.required},i("slot",{name:"label",onSlotchange:()=>this.setLabel()})),i("div",{class:"gux-input-and-error-container"},i("div",{class:{"gux-input":!0,"gux-input-error":this.hasError},part:"input-section"},i("div",{class:{"gux-input-container":!0,"gux-disabled":this.disabled,"gux-clear":t}},i("slot",{name:"input",onSlotchange:()=>this.setInput()}),t&&i("gux-form-field-input-clear-button",{onClick:()=>d(this.input)})),this.renderStepButtons(this.input,this.getI18nValue,this.disabled)),i(g,{show:this.hasError},i("slot",{name:"error"})),i(f,{show:!this.hasError&&this.hasHelp},i("slot",{name:"help"}))))}get variant(){const t=this.labelPosition?this.labelPosition.toLowerCase():"none";return`${this.clearable?"clearable":"unclearable"}-${t}`}setInput(){this.input=x(this.root,'input[type="number"][slot="input"]'),this.hasContent=c(this.input),h(this.input),this.input.addEventListener("input",(()=>{this.hasContent=c(this.input)})),this.disabled=a(this.input),this.required=this.input.required,this.disabledObserver=p(this.input,(t=>{this.disabled=t})),this.requiredObserver=u(this.input,(t=>{this.required=t})),b(this.root,this.input)}setLabel(){this.label=this.root.querySelector('label[slot="label"]'),this.computedLabelPosition=m(this.label,this.labelPosition)}renderStepButtons(t,e,o){return i("div",{class:"gux-step-buttons-container"},i("button",{class:"gux-step-button",tabIndex:-1,type:"button",title:e("increment"),disabled:o,onClick:()=>this.stepUp(t)},i("gux-icon",{"icon-name":"chevron-small-up",decorative:!0})),i("button",{class:"gux-step-button",tabIndex:-1,type:"button",title:e("decrement"),disabled:o,onClick:()=>this.stepDown(t)},i("gux-icon",{"icon-name":"chevron-small-down",decorative:!0})))}stepDown(t){""===t.value?v(t,t.min||"0",!1):(t.stepDown(),this.simulateNativeInputAndChangeEvents(t))}stepUp(t){""===t.value?v(t,t.min||"0",!1):(t.stepUp(),this.simulateNativeInputAndChangeEvents(t))}simulateNativeInputAndChangeEvents(t){w(t,"input"),w(t,"change")}static get delegatesFocus(){return!0}get root(){return o(this)}};(function(t,e,i,o){var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,o);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);n>3&&r&&Object.defineProperty(e,i,r)})([l({childList:!0,subtree:!0})],$.prototype,"onMutation",null),$.style=".gux-form-field-container.gux-beside{display:flex;flex-direction:row}.gux-form-field-error{display:none;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:flex-start;justify-content:flex-start;margin:4px 0;font-size:12px;line-height:20px;color:#2e394c}.gux-form-field-error.gux-show{display:flex}.gux-form-field-error gux-icon{flex:0 1 auto;align-self:auto;order:0;min-width:16px;min-height:16px;margin:2px 4px 0 0;color:#ea0b0b}.gux-form-field-error .gux-message{flex:0 1 auto;align-self:auto;order:0}.gux-form-field-label.gux-required::after{font-size:12px;color:#ea0b0b;content:' *'}.gux-form-field-label.gux-beside{position:relative;top:8px;width:fit-content;min-width:45px;margin-right:8px}.gux-form-field-label.gux-above{margin-bottom:8px}.gux-form-field-label.gux-screenreader{position:absolute;top:auto;left:-10000px;width:1px;height:1px;overflow:hidden}.gux-form-field-help{display:none;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:flex-start;justify-content:flex-start;margin:4px 0;font-size:12px;font-weight:400;line-height:20px;color:#6b7585}.gux-form-field-help.gux-show{display:flex}.gux-form-field-help .gux-message{flex:0 1 auto;align-self:none;order:0}:host{display:block;color:#2e394c}::slotted(label){font-family:Roboto, sans-serif;font-weight:400;font-weight:700;font-size:12px;line-height:16px}::slotted(input){flex:1 1 auto;align-self:auto;order:0;width:100%;overflow:hidden;font-size:12px;color:#2e394c;text-align:right;text-overflow:ellipsis;background-color:#f6f7f9;border:none;outline:none}::slotted(input)::placeholder{color:#596373;opacity:1}.gux-input-and-error-container{flex-grow:1}.gux-input-and-error-container .gux-input{display:flex;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:center;width:100%}.gux-input-and-error-container .gux-input .gux-input-container{box-sizing:border-box;display:flex;flex:1 1 auto;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:center;align-self:auto;justify-content:center;order:0;width:100%;height:32px;padding:4px 12px;font-family:inherit;font-size:12px;line-height:1.6667;color:#2e394c;background-color:#f6f7f9;background-image:none;border:1px solid #6b7585;border-radius:4px;box-shadow:inset 0 0 4px rgba(32, 41, 55, 0.16)}.gux-input-and-error-container .gux-input .gux-input-container.gux-disabled{opacity:0.5}.gux-input-and-error-container .gux-input .gux-input-container.gux-clear{padding-right:0}.gux-input-and-error-container .gux-input .gux-input-container:focus-within{border-color:#2a60c8;outline:3px solid #aac9ff;outline-offset:1px;box-shadow:0 0 0 1px #fdfdfd}.gux-input-and-error-container .gux-input.gux-input-error .gux-input-container{border-color:#ea0b0b}.gux-step-buttons-container{flex:0 1 14px;align-self:auto;order:0;margin:0 4px}.gux-step-buttons-container .gux-step-button{display:flex;flex:0 1 auto;align-items:center;align-self:auto;justify-content:center;order:0;padding:0;color:#596373;background:transparent;border:none}.gux-step-buttons-container .gux-step-button:not(:disabled):focus-visible,.gux-step-buttons-container .gux-step-button:not(:disabled):hover{color:#2a60c8;cursor:pointer}.gux-step-buttons-container .gux-step-button gux-icon{flex:0 0 auto;width:14px;height:14px}";const U=class{constructor(e){t(this,e),this.goToPage=s(this,"goToPage",7),this.isOpen=!1,this.totalPages=void 0}handleKeyDown(t){const e=t.composedPath();switch(t.key){case"Escape":this.isOpen=!1,this.ellipsisButton.focus();break;case"Tab":this.isOpen=!1;break;case"ArrowDown":case"Enter":e.includes(this.ellipsisButton)&&(t.preventDefault(),this.isOpen=!0,this.focusInputElement())}}handleKeyup(t){if(" "===t.key)t.composedPath().includes(this.ellipsisButton)&&(this.isOpen=!0,this.focusInputElement())}toggle(){this.isOpen=!this.isOpen,this.isOpen&&this.focusInputElement()}onClickOutside(){this.isOpen=!1}focusInputElement(){O((()=>{this.inputElement.focus()}))}applyInputListener(){var t;null===(t=this.inputElement)||void 0===t||t.addEventListener("keydown",(t=>{"Enter"!=t.key&&" "!=t.key||(t.preventDefault(),this.goToPage.emit(t.target.value),this.isOpen=!1)}))}async componentWillLoad(){this.i18n=await r(this.root,R),C(this.root)}componentDidLoad(){this.applyInputListener()}render(){return i(n,null,i("button",{id:"popover-target",type:"button",ref:t=>this.ellipsisButton=t,onClick:()=>this.toggle(),"aria-haspopup":"true","aria-expanded":this.isOpen.toString()},i("gux-icon",{screenreaderText:this.i18n("goToPage"),"icon-name":"menu-kebab-horizontal"})),i("gux-tooltip",{for:"popover-target"},this.i18n("goToPage")),i("gux-popover",{"is-open":this.isOpen,for:"popover-target"},i("span",{slot:"title"},this.i18n("goToPage")),i("gux-form-field-number",null,i("input",{slot:"input",type:"number",ref:t=>this.inputElement=t,min:"1",max:this.totalPages,value:"1"}),i("label",{slot:"label"}))))}get root(){return o(this)}};(function(t,e,i,o){var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,o);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);n>3&&r&&Object.defineProperty(e,i,r)})([z({triggerEvents:"mousedown"})],U.prototype,"onClickOutside",null),U.style="button{color:var(--gse-ui-button-ghost-default-foregroundColor);cursor:pointer;background:none;border:none}button:hover{color:var(--gse-ui-button-ghost-hover-foregroundColor)}button:focus-visible{outline:var(--gse-semantic-focusRing-width) solid var(--gse-semantic-color-focus);outline-offset:var(--gse-semantic-focusRing-offset);border-radius:calc(var(--gse-semantic-focusRing-cornerRadius) - var(--gse-semantic-focusRing-offset))}button gux-icon{width:var(--gse-ui-icon-size-sm);height:var(--gse-ui-icon-size-sm);padding-top:4px}input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{margin:0;-webkit-appearance:none}input[type=number]{-moz-appearance:textfield}";const B=class{constructor(e){t(this,e),this.guxdismiss=s(this,"guxdismiss",7),this.for=void 0,this.position="bottom",this.displayDismissButton=void 0,this.closeOnClickOutside=!1,this.isOpen=!1}checkForClickOutside(t){const e=t.composedPath(),i=F(this.root,this.for),o=e.includes(i);!this.closeOnClickOutside&&this.displayDismissButton||!this.isOpen||o||this.dismiss()}get titleSlot(){return _(this.root,"title")}runUpdatePosition(){this.root.isConnected?this.cleanupUpdatePosition=S(F(this.root,this.for),this.popupElement,(()=>this.updatePosition()),{ancestorScroll:!0,elementResize:!0,animationFrame:!0,ancestorResize:!0}):this.disconnectedCallback()}updatePosition(){const t=F(this.root,this.for);this.popupElement&&D(t,this.popupElement,{placement:this.position,middleware:[E(7),I(),L(),P({element:this.arrowElement,padding:16})]}).then((({x:t,y:e,middlewareData:i,placement:o})=>{Object.assign(this.popupElement.style,{left:`${t}px`,top:`${e}px`});const s={top:"bottom",right:"left",bottom:"top",left:"right"}[o.split("-")[0]];if(i.arrow){const{x:t,y:e}=i.arrow;this.popupElement.setAttribute("data-placement",o),Object.assign(this.arrowElement.style,{left:null!=t?`${t}px`:"",top:null!=e?`${e}px`:"",right:"",bottom:"",[s]:"-6.5px",transform:"rotate(45deg)"})}}))}dismiss(){this.guxdismiss.emit().defaultPrevented||(this.isOpen=!1)}connectedCallback(){C(this.root,{variant:this.position})}componentDidLoad(){this.isOpen&&this.runUpdatePosition()}componentDidUpdate(){this.isOpen?this.runUpdatePosition():this.cleanupUpdatePosition&&this.cleanupUpdatePosition()}disconnectedCallback(){this.cleanupUpdatePosition&&this.cleanupUpdatePosition()}renderDismissButton(){if(this.displayDismissButton)return i("gux-dismiss-button",{onClick:this.dismiss.bind(this),position:"inherit"})}render(){return i("div",{ref:t=>this.popupElement=t,class:{"gux-hidden":!this.isOpen,"gux-popover-wrapper":!0},"data-placement":!0},i("div",{ref:t=>this.arrowElement=t,class:"gux-arrow"}),i("div",{class:{"gux-popover-header":Boolean(this.titleSlot)}},i("slot",{name:"title"}),this.renderDismissButton()),i("div",{class:"gux-popover-content"},i("slot",null)))}get root(){return o(this)}};(function(t,e,i,o){var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,o);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);n>3&&r&&Object.defineProperty(e,i,r)})([z({triggerEvents:"mousedown"})],B.prototype,"checkForClickOutside",null),B.style=".gux-popover-wrapper{position:absolute;top:0;left:0;min-width:280px;z-index:var(--gux-zindex-popover, 2);display:inline-block;padding:var(--gse-ui-popover-gap);background-color:var(--gse-ui-popover-backgroundColor);border-radius:var(--gse-ui-popover-borderRadius);box-shadow:var(--gse-ui-popover-boxShadow-x) var(--gse-ui-popover-boxShadow-y) var(--gse-ui-popover-boxShadow-blur) var(--gse-ui-popover-boxShadow-spread) var(--gse-ui-tooltip-boxShadow-color)}.gux-popover-wrapper.gux-hidden{display:none}.gux-popover-wrapper .gux-arrow{position:absolute;width:var(--gse-ui-popover-anchor-width);height:var(--gse-ui-popover-anchor-width);background:var(--gse-ui-popover-backgroundColor)}.gux-popover-wrapper .gux-popover-header{font-family:var(--gse-ui-popover-title-text-fontFamily);font-size:var(--gse-ui-popover-title-text-fontSize);font-weight:var(--gse-ui-popover-title-text-fontWeight);line-height:var(--gse-ui-popover-title-text-lineHeight);color:--gse-ui-popover-headerColor;display:flex;flex-direction:row;align-content:center;align-items:center;justify-content:space-between;padding-bottom:var(--gse-ui-popover-gap)}.gux-popover-wrapper gux-dismiss-button{float:right}";export{$ as gux_form_field_number,U as gux_pagination_ellipsis_button,B as gux_popover}
|
1
|
+
import{r as t,f as e,h as i,g as o,c as s,H as n}from"./p-7d26b2e1.js";import{b as r}from"./p-deee079e.js";import{c as a,o as p}from"./p-3f5341ea.js";import{O as l}from"./p-f34ce7dc.js";import{o as u}from"./p-3701eff0.js";import{p as h}from"./p-c10e41a9.js";import{h as c,d,G as g,a as f,g as x,v as b,b as m,e as v}from"./p-b3c9fd06.js";import{s as w}from"./p-d176c2ae.js";import{h as y}from"./p-08bc2e6b.js";import{G as j,a as k}from"./p-a733f4ca.js";import{t as C}from"./p-6517ed89.js";import{t as R}from"./p-abb9b5f7.js";import{O as z}from"./p-9d18d475.js";import{b as O}from"./p-091f51f6.js";import{a as S,c as D,o as E,f as I,s as L,b as P}from"./p-4e2b5bcf.js";import{g as _}from"./p-3e6097e5.js";import{f as F}from"./p-82ffe3cc.js";import"./p-8a133b9b.js";import"./p-cbcbd1bb.js";import"./p-d0805f56.js";const T={increment:"Increment",decrement:"Decrement"};const $=class{constructor(e){t(this,e),this.clearable=void 0,this.labelPosition=void 0,this.computedLabelPosition="above",this.disabled=void 0,this.required=void 0,this.hasContent=!1,this.hasError=!1,this.hasHelp=!1}onMutation(){this.hasError=y(this.root,"error"),this.hasHelp=y(this.root,"help")}async guxForceUpdate(){this.hasContent=c(this.input),this.hasError=y(this.root,"error"),this.hasHelp=y(this.root,"help"),e(this.root)}async componentWillLoad(){this.getI18nValue=await r(this.root,T),this.setInput(),this.setLabel(),this.hasError=y(this.root,"error"),this.hasHelp=y(this.root,"help"),C(this.root,{variant:this.variant})}disconnectedCallback(){this.disabledObserver&&this.disabledObserver.disconnect(),this.requiredObserver&&this.requiredObserver.disconnect()}render(){const t=this.clearable&&this.hasContent&&!this.disabled;return i(k,{labelPosition:this.computedLabelPosition},i(j,{position:this.computedLabelPosition,required:this.required},i("slot",{name:"label",onSlotchange:()=>this.setLabel()})),i("div",{class:"gux-input-and-error-container"},i("div",{class:{"gux-input":!0,"gux-input-error":this.hasError},part:"input-section"},i("div",{class:{"gux-input-container":!0,"gux-disabled":this.disabled,"gux-clear":t}},i("slot",{name:"input",onSlotchange:()=>this.setInput()}),t&&i("gux-form-field-input-clear-button",{onClick:()=>d(this.input)})),this.renderStepButtons(this.input,this.getI18nValue,this.disabled)),i(g,{show:this.hasError},i("slot",{name:"error"})),i(f,{show:!this.hasError&&this.hasHelp},i("slot",{name:"help"}))))}get variant(){const t=this.labelPosition?this.labelPosition.toLowerCase():"none";return`${this.clearable?"clearable":"unclearable"}-${t}`}setInput(){this.input=x(this.root,'input[type="number"][slot="input"]'),this.hasContent=c(this.input),h(this.input),this.input.addEventListener("input",(()=>{this.hasContent=c(this.input)})),this.disabled=a(this.input),this.required=this.input.required,this.disabledObserver=p(this.input,(t=>{this.disabled=t})),this.requiredObserver=u(this.input,(t=>{this.required=t})),b(this.root,this.input)}setLabel(){this.label=this.root.querySelector('label[slot="label"]'),this.computedLabelPosition=m(this.label,this.labelPosition)}renderStepButtons(t,e,o){return i("div",{class:"gux-step-buttons-container"},i("button",{class:"gux-step-button",tabIndex:-1,type:"button",title:e("increment"),disabled:o,onClick:()=>this.stepUp(t)},i("gux-icon",{"icon-name":"chevron-small-up",decorative:!0})),i("button",{class:"gux-step-button",tabIndex:-1,type:"button",title:e("decrement"),disabled:o,onClick:()=>this.stepDown(t)},i("gux-icon",{"icon-name":"chevron-small-down",decorative:!0})))}stepDown(t){""===t.value?v(t,t.min||"0",!1):(t.stepDown(),this.simulateNativeInputAndChangeEvents(t))}stepUp(t){""===t.value?v(t,t.min||"0",!1):(t.stepUp(),this.simulateNativeInputAndChangeEvents(t))}simulateNativeInputAndChangeEvents(t){w(t,"input"),w(t,"change")}static get delegatesFocus(){return!0}get root(){return o(this)}};(function(t,e,i,o){var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,o);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);n>3&&r&&Object.defineProperty(e,i,r)})([l({childList:!0,subtree:!0})],$.prototype,"onMutation",null),$.style=".gux-form-field-container.gux-beside{display:flex;flex-direction:row}.gux-form-field-error{display:none;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:flex-start;justify-content:flex-start;margin:4px 0;font-size:12px;line-height:20px;color:#2e394c}.gux-form-field-error.gux-show{display:flex}.gux-form-field-error gux-icon{flex:0 1 auto;align-self:auto;order:0;min-width:16px;min-height:16px;margin:2px 4px 0 0;color:#ea0b0b}.gux-form-field-error .gux-message{flex:0 1 auto;align-self:auto;order:0}.gux-form-field-label.gux-required::after{font-size:12px;color:#ea0b0b;content:' *'}.gux-form-field-label.gux-beside{position:relative;top:8px;width:fit-content;min-width:45px;margin-right:8px}.gux-form-field-label.gux-above{margin-bottom:8px}.gux-form-field-label.gux-screenreader{position:absolute;top:auto;left:-10000px;width:1px;height:1px;overflow:hidden}.gux-form-field-help{display:none;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:flex-start;justify-content:flex-start;margin:4px 0;font-size:12px;font-weight:400;line-height:20px;color:#6b7585}.gux-form-field-help.gux-show{display:flex}.gux-form-field-help .gux-message{flex:0 1 auto;align-self:none;order:0}:host{display:block;color:#2e394c}::slotted(label){font-family:Roboto, sans-serif;font-weight:400;font-weight:700;font-size:12px;line-height:16px}::slotted(input){flex:1 1 auto;align-self:auto;order:0;width:100%;overflow:hidden;font-size:12px;color:#2e394c;text-align:right;text-overflow:ellipsis;background-color:#f6f7f9;border:none;outline:none}::slotted(input)::placeholder{color:#596373;opacity:1}.gux-input-and-error-container{flex-grow:1}.gux-input-and-error-container .gux-input{display:flex;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:center;width:100%}.gux-input-and-error-container .gux-input .gux-input-container{box-sizing:border-box;display:flex;flex:1 1 auto;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:center;align-self:auto;justify-content:center;order:0;width:100%;height:32px;padding:4px 12px;font-family:inherit;font-size:12px;line-height:1.6667;color:#2e394c;background-color:#f6f7f9;background-image:none;border:1px solid #6b7585;border-radius:4px;box-shadow:inset 0 0 4px rgba(32, 41, 55, 0.16)}.gux-input-and-error-container .gux-input .gux-input-container.gux-disabled{opacity:0.5}.gux-input-and-error-container .gux-input .gux-input-container.gux-clear{padding-right:0}.gux-input-and-error-container .gux-input .gux-input-container:focus-within{border-color:#2a60c8;outline:3px solid #aac9ff;outline-offset:1px;box-shadow:0 0 0 1px #fdfdfd}.gux-input-and-error-container .gux-input.gux-input-error .gux-input-container{border-color:#ea0b0b}.gux-step-buttons-container{flex:0 1 14px;align-self:auto;order:0;margin:0 4px}.gux-step-buttons-container .gux-step-button{display:flex;flex:0 1 auto;align-items:center;align-self:auto;justify-content:center;order:0;padding:0;color:#596373;background:transparent;border:none}.gux-step-buttons-container .gux-step-button:not(:disabled):focus-visible,.gux-step-buttons-container .gux-step-button:not(:disabled):hover{color:#2a60c8;cursor:pointer}.gux-step-buttons-container .gux-step-button gux-icon{flex:0 0 auto;width:14px;height:14px}";const U=class{constructor(e){t(this,e),this.goToPage=s(this,"goToPage",7),this.isOpen=!1,this.totalPages=void 0}handleKeyDown(t){const e=t.composedPath();switch(t.key){case"Escape":this.isOpen=!1,this.ellipsisButton.focus();break;case"Tab":this.isOpen=!1;break;case"ArrowDown":case"Enter":e.includes(this.ellipsisButton)&&(t.preventDefault(),this.isOpen=!0,this.focusInputElement())}}handleKeyup(t){if(" "===t.key)t.composedPath().includes(this.ellipsisButton)&&(this.isOpen=!0,this.focusInputElement())}toggle(){this.isOpen=!this.isOpen,this.isOpen&&this.focusInputElement()}onClickOutside(){this.isOpen=!1}focusInputElement(){O((()=>{this.inputElement.focus()}))}applyInputListener(){var t;null===(t=this.inputElement)||void 0===t||t.addEventListener("keydown",(t=>{"Enter"!=t.key&&" "!=t.key||(t.preventDefault(),this.goToPage.emit(t.target.value),this.isOpen=!1)}))}async componentWillLoad(){this.i18n=await r(this.root,R),C(this.root)}componentDidLoad(){this.applyInputListener()}render(){return i(n,null,i("button",{id:"popover-target",type:"button",ref:t=>this.ellipsisButton=t,onClick:()=>this.toggle(),"aria-haspopup":"true","aria-expanded":this.isOpen.toString()},i("gux-icon",{screenreaderText:this.i18n("goToPage"),"icon-name":"menu-kebab-horizontal"})),i("gux-tooltip",{for:"popover-target"},this.i18n("goToPage")),i("gux-popover",{"is-open":this.isOpen,for:"popover-target"},i("span",{slot:"title"},this.i18n("goToPage")),i("gux-form-field-number",null,i("input",{slot:"input",type:"number",ref:t=>this.inputElement=t,min:"1",max:this.totalPages,value:"1"}),i("label",{slot:"label"}))))}get root(){return o(this)}};(function(t,e,i,o){var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,o);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);n>3&&r&&Object.defineProperty(e,i,r)})([z({triggerEvents:"mousedown"})],U.prototype,"onClickOutside",null),U.style="button{color:var(--gse-ui-button-ghost-default-foregroundColor);cursor:pointer;background:none;border:none}button:hover{color:var(--gse-ui-button-ghost-hover-foregroundColor)}button:focus-visible{outline:var(--gse-semantic-focusRing-width) solid var(--gse-semantic-color-focus);outline-offset:var(--gse-semantic-focusRing-offset);border-radius:calc(var(--gse-semantic-focusRing-cornerRadius) - var(--gse-semantic-focusRing-offset))}button gux-icon{width:var(--gse-ui-icon-size-sm);height:var(--gse-ui-icon-size-sm);padding-top:4px}input::-webkit-outer-spin-button,input::-webkit-inner-spin-button{margin:0;-webkit-appearance:none}input[type=number]{-moz-appearance:textfield}";const B=class{constructor(e){t(this,e),this.guxdismiss=s(this,"guxdismiss",7),this.for=void 0,this.position="bottom",this.displayDismissButton=void 0,this.closeOnClickOutside=!1,this.isOpen=!1}checkForClickOutside(t){const e=t.composedPath(),i=F(this.root,this.for),o=e.includes(i);!this.closeOnClickOutside&&this.displayDismissButton||!this.isOpen||o||this.dismiss()}get titleSlot(){return _(this.root,"title")}runUpdatePosition(){this.root.isConnected?this.cleanupUpdatePosition=S(F(this.root,this.for),this.popupElement,(()=>this.updatePosition()),{ancestorScroll:!0,elementResize:!0,animationFrame:!0,ancestorResize:!0}):this.disconnectedCallback()}updatePosition(){const t=F(this.root,this.for);this.popupElement&&D(t,this.popupElement,{placement:this.position,middleware:[E(7),I(),L(),P({element:this.arrowElement,padding:16})]}).then((({x:t,y:e,middlewareData:i,placement:o})=>{Object.assign(this.popupElement.style,{left:`${t}px`,top:`${e}px`});const s={top:"bottom",right:"left",bottom:"top",left:"right"}[o.split("-")[0]];if(i.arrow){const{x:t,y:e}=i.arrow;this.popupElement.setAttribute("data-placement",o),Object.assign(this.arrowElement.style,{left:null!=t?`${t}px`:"",top:null!=e?`${e}px`:"",right:"",bottom:"",[s]:"-6.5px",transform:"rotate(45deg)"})}}))}dismiss(){this.guxdismiss.emit().defaultPrevented||(this.isOpen=!1)}connectedCallback(){C(this.root,{variant:this.position})}componentDidLoad(){this.isOpen&&this.runUpdatePosition()}componentDidUpdate(){this.isOpen?this.runUpdatePosition():this.cleanupUpdatePosition&&this.cleanupUpdatePosition()}disconnectedCallback(){this.cleanupUpdatePosition&&this.cleanupUpdatePosition()}renderDismissButton(){if(this.displayDismissButton)return i("gux-dismiss-button",{onClick:this.dismiss.bind(this),position:"inherit"})}render(){return i("div",{ref:t=>this.popupElement=t,class:{"gux-hidden":!this.isOpen,"gux-popover-wrapper":!0},"data-placement":!0},i("div",{ref:t=>this.arrowElement=t,class:"gux-arrow"}),i("div",{class:{"gux-popover-header":Boolean(this.titleSlot)}},i("slot",{name:"title"}),this.renderDismissButton()),i("div",{class:"gux-popover-content"},i("slot",null)))}get root(){return o(this)}};(function(t,e,i,o){var s,n=arguments.length,r=n<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,e,i,o);else for(var a=t.length-1;a>=0;a--)(s=t[a])&&(r=(n<3?s(r):n>3?s(e,i,r):s(e,i))||r);n>3&&r&&Object.defineProperty(e,i,r)})([z({triggerEvents:"mousedown"})],B.prototype,"checkForClickOutside",null),B.style=".gux-popover-wrapper{position:absolute;top:0;left:0;min-width:280px;z-index:var(--gux-zindex-popover, 2);display:inline-block;padding:var(--gse-ui-popover-gap);background-color:var(--gse-ui-popover-backgroundColor);border-radius:var(--gse-ui-popover-borderRadius);box-shadow:var(--gse-ui-popover-boxShadow-x) var(--gse-ui-popover-boxShadow-y) var(--gse-ui-popover-boxShadow-blur) var(--gse-ui-popover-boxShadow-spread) var(--gse-ui-tooltip-boxShadow-color)}.gux-popover-wrapper.gux-hidden{display:none}.gux-popover-wrapper .gux-arrow{position:absolute;width:var(--gse-ui-popover-anchor-width);height:var(--gse-ui-popover-anchor-width);background:var(--gse-ui-popover-backgroundColor)}.gux-popover-wrapper .gux-popover-header{font-family:var(--gse-ui-popover-title-text-fontFamily);font-size:var(--gse-ui-popover-title-text-fontSize);font-weight:var(--gse-ui-popover-title-text-fontWeight);line-height:var(--gse-ui-popover-title-text-lineHeight);color:--gse-ui-popover-headerColor;display:flex;flex-direction:row;align-content:center;align-items:center;justify-content:space-between;padding-bottom:var(--gse-ui-popover-gap)}.gux-popover-wrapper gux-dismiss-button{float:right}";export{$ as gux_form_field_number,U as gux_pagination_ellipsis_button,B as gux_popover}
|
@@ -0,0 +1 @@
|
|
1
|
+
import{r as t,c as a,h as i,g as e}from"./p-7d26b2e1.js";import{b as n}from"./p-deee079e.js";import{t as o}from"./p-abb9b5f7.js";import{b as s}from"./p-091f51f6.js";import"./p-8a133b9b.js";class r{static displayAllPageButtons(t,a,i){switch(i){case"advanced":return function(t,a){if(a<=7)return[...Array(a).keys()].map((a=>{const i=a+1;return{pageNumber:i,display:String(i),current:i===t}}));if(t<=3)return[...[...Array(5).keys()].map((a=>{const i=a+1;return{pageNumber:i,display:String(i),current:i===t}})),{pageNumber:6,display:"...",current:!1},{pageNumber:a,display:String(a),current:!1}];if(t>a-3){const i=[...Array(5).keys()].map((i=>{const e=i+a-4;return{pageNumber:e,display:String(e),current:e===t}}));return[{pageNumber:1,display:"1",current:!1},{pageNumber:a-6,display:"...",current:!1},...i]}const i=[...Array(3).keys()].map((a=>{const i=a+t-1;return{pageNumber:i,display:String(i),current:i===t}}));return[{pageNumber:1,display:"1",current:!1},{pageNumber:t-3,display:"...",current:!1},...i,{pageNumber:t+3,display:"...",current:!1},{pageNumber:a,display:String(a),current:!1}]}(t,a);case"simple":return function(t,a){return a<=3?[...Array(a).keys()].map((a=>{const i=a+1;return{pageNumber:i,display:String(i),current:i===t}})):a>=4?[...[...Array(1).keys()].map((i=>{const e=i+t;return{pageNumber:e,display:String(e),current:e!==a}})),{pageNumber:t,display:"...",current:!1},{pageNumber:a,display:String(a),current:a==t}]:void 0}(t,a)}}}const g=class{constructor(i){t(this,i),this.internalcurrentpagechange=a(this,"internalcurrentpagechange",3),this.currentPage=void 0,this.totalPages=void 0,this.layout="advanced"}goToPageHandler(t){this.currentPage=t.detail,this.handlePageChange(this.currentPage),s((()=>{this.currentElement.focus()}))}get onFirstPage(){return this.currentPage<=1}get onLastPage(){return this.currentPage>=this.totalPages}handleClickFirst(){this.internalcurrentpagechange.emit(1)}handleClickPrevious(){this.internalcurrentpagechange.emit(this.currentPage-1)}handleClickNext(){this.internalcurrentpagechange.emit(this.currentPage+1)}handleClickLast(){this.internalcurrentpagechange.emit(this.totalPages)}handlePageChange(t){this.internalcurrentpagechange.emit(t)}getPageListEnteries(t,a,e){return r.displayAllPageButtons(t,a,e).reduce(((t,a)=>t.concat(a.current?i("button",{ref:t=>this.currentElement=t,class:"gux-pagination-buttons-list-current"},a.display):"..."==a.display?i("gux-pagination-ellipsis-button",{totalPages:this.totalPages}):i("button",{class:"gux-pagination-buttons-list-target",onClick:()=>this.handlePageChange(a.pageNumber)},a.display))),[])}getPageNavigation(){return i("div",{class:"gux-pagination-buttons-list-container"},this.getPageListEnteries(this.currentPage,this.totalPages,this.layout))}async componentWillLoad(){this.i18n=await n(this.root,o)}render(){return i("div",{class:`gux-pagination-buttons-container gux-${this.layout}`},i("div",{class:"gux-pagination-buttons-group"},i("gux-button-slot",{accent:"ghost"},i("button",{title:this.i18n("first"),disabled:this.onFirstPage,onClick:this.handleClickFirst.bind(this)},i("gux-icon",{decorative:!0,"icon-name":"chevron-double-left"}))),i("gux-button-slot",{accent:"ghost"},i("button",{title:this.i18n("previous"),disabled:this.onFirstPage,onClick:this.handleClickPrevious.bind(this)},i("gux-icon",{decorative:!0,"icon-name":"chevron-small-left"})))),this.getPageNavigation(),i("div",{class:"gux-pagination-buttons-group"},i("gux-button-slot",{accent:"ghost"},i("button",{title:this.i18n("next"),disabled:this.onLastPage,onClick:this.handleClickNext.bind(this)},i("gux-icon",{decorative:!0,"icon-name":"chevron-small-right"}))),i("gux-button-slot",{accent:"ghost"},i("button",{title:this.i18n("last"),disabled:this.onLastPage,onClick:this.handleClickLast.bind(this)},i("gux-icon",{decorative:!0,"icon-name":"chevron-double-right"})))))}get root(){return e(this)}};g.style="gux-pagination-buttons .gux-pagination-buttons-container{display:flex;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:center;gap:var(--gse-ui-dataTableItems-tablePagination-recordsetControls-gap);justify-content:flex-end;margin-left:var(--gse-ui-dataTableItems-tablePagination-recordsetControls-gap)}gux-pagination-buttons .gux-pagination-buttons-container>div{flex:0 1 auto;align-self:auto;order:0}gux-pagination-buttons .gux-pagination-buttons-container .gux-pagination-buttons-group{display:flex;flex-direction:row;gap:var(--gse-ui-dataTableItems-tablePagination-recordsetControls-gap);white-space:nowrap}gux-pagination-buttons .gux-pagination-buttons-container .gux-pagination-buttons-list-container{display:flex;flex-direction:row;flex-shrink:0;flex-wrap:nowrap;align-content:stretch;gap:var(--gse-ui-dataTableItems-tablePagination-recordsetControls-gap);align-items:center;justify-content:center}gux-pagination-buttons .gux-pagination-buttons-container .gux-pagination-buttons-list-container .gux-pagination-buttons-list-current,gux-pagination-buttons .gux-pagination-buttons-container .gux-pagination-buttons-list-container .gux-pagination-buttons-list-target{min-width:28px;min-height:24px;padding-left:var(--gse-ui-dataTableItems-tablePagination-padding);padding-right:var(--gse-ui-dataTableItems-tablePagination-padding);margin:0;background:inherit;border:none;font-family:var(--gse-ui-dataTableItems-tablePagination-defaultText-fontFamily);color:var(--gse-ui-dataTableItems-tablePagination-foregroundColor);font-size:var(--gse-ui-dataTableItems-tablePagination-defaultText-fontSize);line-height:var(--gse-ui-dataTableItems-tablePagination-defaultText-lineHeight);font-weight:var(--gse-ui-dataTableItems-tablePagination-currentResultText-fontWeight)}gux-pagination-buttons .gux-pagination-buttons-container .gux-pagination-buttons-list-container .gux-pagination-buttons-list-current:focus-visible,gux-pagination-buttons .gux-pagination-buttons-container .gux-pagination-buttons-list-container .gux-pagination-buttons-list-target:focus-visible{outline:var(--gse-semantic-focusRing-width) solid var(--gse-semantic-color-focus);outline-offset:var(--gse-semantic-focusRing-offset);border-radius:calc(var(--gse-semantic-focusRing-cornerRadius) - var(--gse-semantic-focusRing-offset))}gux-pagination-buttons .gux-pagination-buttons-container .gux-pagination-buttons-list-container .gux-pagination-buttons-list-current{background-color:var(--gse-ui-button-ghost-active-backgroundColor);border-radius:var(--gse-ui-button-borderRadius)}gux-pagination-buttons .gux-pagination-buttons-container .gux-pagination-buttons-list-container .gux-pagination-buttons-list-target{color:var(--gse-ui-button-ghost-default-foregroundColor);cursor:pointer}gux-pagination-buttons .gux-pagination-buttons-container .gux-pagination-buttons-list-container .gux-pagination-buttons-list-target:hover{color:var(--gse-ui-button-ghost-hover-foregroundColor);background-color:var(--gse-ui-button-ghost-hover-backgroundColor);border-radius:var(--gse-ui-button-borderRadius)}";const u={itemCountDisplay:"{firstItem, number} - {lastItem, number}",totalItems:" of {totalItems, number}"},l=class{constructor(a){t(this,a),this.totalItems=0,this.currentPage=0,this.itemsPerPage=25}get firstItem(){return this.totalItems<1?0:(this.currentPage-1)*this.itemsPerPage+1}get lastItem(){return this.totalItems<1?0:Math.min(this.currentPage*this.itemsPerPage,this.totalItems)}async componentWillLoad(){this.i18n=await n(this.root,u)}getPaginationItemCountsRange(){if(this.totalItems)return i("span",null,this.i18n("totalItems",{totalItems:this.totalItems}))}render(){return i("div",{class:"gux-pagination-item-counts-container"},i("span",{class:"gux-pagination-item-counts-range"},this.i18n("itemCountDisplay",{firstItem:this.firstItem,lastItem:this.lastItem})),this.getPaginationItemCountsRange())}get root(){return e(this)}};l.style="gux-pagination-item-counts .gux-pagination-item-counts-container{display:flex;flex-direction:row;gap:var(--gse-ui-dataTableItems-tablePagination-countDisplay-gap);white-space:nowrap;font-family:var(--gse-ui-dataTableItems-tablePagination-defaultText-fontFamily);color:var(--gse-ui-dataTableItems-tablePagination-foregroundColor);font-size:var(--gse-ui-dataTableItems-tablePagination-defaultText-fontSize);line-height:var(--gse-ui-dataTableItems-tablePagination-defaultText-lineHeight);font-weight:var(--gse-ui-dataTableItems-tablePagination-currentResultText-fontWeight)}";const p={perPage:"per page",itemsPerPage:"Items per page",rangeSelected:"Items per page dropdown, {range} selected"},c=class{constructor(i){t(this,i),this.internalitemsperpagechange=a(this,"internalitemsperpagechange",3),this.itemsPerPage=25}handleChange(t){t.stopPropagation();const a=parseInt(this.dropdownElement.value,10);this.internalitemsperpagechange.emit(a)}async componentWillLoad(){this.i18n=await n(this.root,p)}getDropdown(){return i("gux-dropdown",{ref:t=>this.dropdownElement=t,value:`${this.itemsPerPage}`,"aria-label":this.i18n("rangeSelected",{range:this.itemsPerPage})},i("gux-listbox",{"aria-label":this.i18n("itemsPerPage")},i("gux-option",{value:"25"},"25"),i("gux-option",{value:"50"},"50"),i("gux-option",{value:"75"},"75"),i("gux-option",{value:"100"},"100")))}render(){return i("div",{class:"gux-pagination-items-per-page-container"},i("div",{class:"gux-pagination-items-per-page-picker"},this.getDropdown()),i("div",{class:"gux-pagination-per-page"},this.i18n("perPage")))}get root(){return e(this)}};c.style="gux-pagination-items-per-page .gux-pagination-items-per-page-container{display:flex;flex-direction:row;flex-wrap:nowrap;align-content:stretch;gap:var(--gse-ui-dataTableItems-tablePagination-recordsetControls-gap);align-items:center;justify-content:center}gux-pagination-items-per-page .gux-pagination-items-per-page-container>div{flex:0 1 auto;align-self:auto;order:0;white-space:nowrap}gux-pagination-items-per-page .gux-pagination-items-per-page-container .gux-pagination-items-per-page-picker gux-dropdown{display:inline-block;width:64px}gux-pagination-items-per-page .gux-pagination-items-per-page-container gux-dropdown div.gux-dropdown .gux-options.gux-opened{bottom:100%;display:flex;flex-direction:column-reverse}gux-pagination-items-per-page .gux-pagination-items-per-page-container .gux-pagination-per-page{font-family:var(--gse-ui-dataTableItems-tablePagination-defaultText-fontFamily);color:var(--gse-ui-dataTableItems-tablePagination-foregroundColor);font-size:var(--gse-ui-dataTableItems-tablePagination-defaultText-fontSize);line-height:var(--gse-ui-dataTableItems-tablePagination-defaultText-lineHeight);font-weight:var(--gse-ui-dataTableItems-tablePagination-currentResultText-fontWeight)}";export{g as gux_pagination_buttons,l as gux_pagination_item_counts,c as gux_pagination_items_per_page}
|
@@ -0,0 +1 @@
|
|
1
|
+
import{r as o,h as t,g as e}from"./p-7d26b2e1.js";import{c as r,o as i}from"./p-3f5341ea.js";import{O as s}from"./p-f34ce7dc.js";import{o as n}from"./p-3701eff0.js";import{p as l}from"./p-c10e41a9.js";import{h as a}from"./p-08bc2e6b.js";import{G as f,a as u,v as g,b as c}from"./p-b3c9fd06.js";import{G as d,a as m}from"./p-a733f4ca.js";import{t as h}from"./p-6517ed89.js";import"./p-cbcbd1bb.js";import"./p-d0805f56.js";import"./p-d176c2ae.js";const v=class{constructor(t){o(this,t),this.resize=void 0,this.labelPosition=void 0,this.computedLabelPosition="above",this.disabled=void 0,this.required=!0,this.hasError=!1,this.hasHelp=!1}onMutation(){this.hasError=a(this.root,"error"),this.hasHelp=a(this.root,"help")}componentWillLoad(){this.setInput(),this.setLabel(),this.hasError=a(this.root,"error"),this.hasHelp=a(this.root,"help"),h(this.root,{variant:this.variant})}componentDidLoad(){this.updateHeight(this.textareaContainerElement,this.input,this.resize)}disconnectedCallback(){this.disabledObserver&&this.disabledObserver.disconnect(),this.requiredObserver&&this.requiredObserver.disconnect()}render(){return t(m,{labelPosition:this.computedLabelPosition},t(d,{position:this.computedLabelPosition,required:this.required},t("slot",{name:"label",onSlotchange:()=>this.setLabel()})),t("div",{class:"gux-input-and-error-container"},t("div",{ref:o=>this.textareaContainerElement=o,class:{"gux-input":!0,[`gux-resize-${this.resize}`]:!0,"gux-disabled":this.disabled,"gux-input-error":this.hasError}},t("slot",{name:"input"})),t(f,{show:this.hasError},t("slot",{name:"error"})),t(u,{show:!this.hasError&&this.hasHelp},t("slot",{name:"help"}))))}get variant(){const o=this.labelPosition?this.labelPosition.toLowerCase():"none";return`${this.resize}-${o}`}setInput(){this.input=this.root.querySelector('textarea[slot="input"]'),l(this.input),this.updateHeight(this.textareaContainerElement,this.input,this.resize),this.input.addEventListener("input",(()=>{this.updateHeight(this.textareaContainerElement,this.input,this.resize)})),this.disabled=r(this.input),this.required=this.input.required,this.disabledObserver=i(this.input,(o=>{this.disabled=o})),this.requiredObserver=n(this.input,(o=>{this.required=o})),g(this.root,this.input)}setLabel(){this.label=this.root.querySelector('label[slot="label"]'),this.computedLabelPosition=c(this.label,this.labelPosition)}updateHeight(o,t,e){"auto"===e&&o&&(o.dataset.replicatedValue=t.value,o.style.maxHeight=t.style.maxHeight)}get root(){return e(this)}};(function(o,t,e,r){var i,s=arguments.length,n=s<3?t:null===r?r=Object.getOwnPropertyDescriptor(t,e):r;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(o,t,e,r);else for(var l=o.length-1;l>=0;l--)(i=o[l])&&(n=(s<3?i(n):s>3?i(t,e,n):i(t,e))||n);s>3&&n&&Object.defineProperty(t,e,n)})([s({childList:!0,subtree:!0})],v.prototype,"onMutation",null),v.style='.gux-focus-ring-focused:focus{outline-width:var(--gse-semantic-focusRing-default-border-width);outline-style:var(--gse-semantic-focusRing-default-border-style);outline-color:var(--gse-semantic-focusRing-default-border-color);outline-offset:var(--gse-semantic-focusRing-offset)}.gux-focus-ring-focused-within:focus-within{outline-width:var(--gse-semantic-focusRing-default-border-width);outline-style:var(--gse-semantic-focusRing-default-border-style);outline-color:var(--gse-semantic-focusRing-default-border-color);outline-offset:var(--gse-semantic-focusRing-offset)}.gux-focus-ring-focused-visible:focus-visible{outline-width:var(--gse-semantic-focusRing-default-border-width);outline-style:var(--gse-semantic-focusRing-default-border-style);outline-color:var(--gse-semantic-focusRing-default-border-color);outline-offset:var(--gse-semantic-focusRing-offset)}.gux-focus-ring-small-focused:focus{outline-width:var(--gse-semantic-focusRing-small-border-width);outline-style:var(--gse-semantic-focusRing-small-border-style);outline-color:var(--gse-semantic-focusRing-small-border-color)}.gux-focus-ring-small-focused-within:focus-within{outline-width:var(--gse-semantic-focusRing-small-border-width);outline-style:var(--gse-semantic-focusRing-small-border-style);outline-color:var(--gse-semantic-focusRing-small-border-color)}.gux-focus-ring-small-focused-visible:focus-visible{outline-width:var(--gse-semantic-focusRing-small-border-width);outline-style:var(--gse-semantic-focusRing-small-border-style);outline-color:var(--gse-semantic-focusRing-small-border-color)}.gux-focus-ring-focused:focus{outline-width:var(--gse-semantic-focusRing-default-border-width);outline-style:var(--gse-semantic-focusRing-default-border-style);outline-color:var(--gse-semantic-focusRing-default-border-color);outline-offset:var(--gse-semantic-focusRing-offset)}.gux-focus-ring-focused-within:focus-within{outline-width:var(--gse-semantic-focusRing-default-border-width);outline-style:var(--gse-semantic-focusRing-default-border-style);outline-color:var(--gse-semantic-focusRing-default-border-color);outline-offset:var(--gse-semantic-focusRing-offset)}.gux-focus-ring-focused-visible:focus-visible{outline-width:var(--gse-semantic-focusRing-default-border-width);outline-style:var(--gse-semantic-focusRing-default-border-style);outline-color:var(--gse-semantic-focusRing-default-border-color);outline-offset:var(--gse-semantic-focusRing-offset)}.gux-focus-ring-small-focused:focus{outline-width:var(--gse-semantic-focusRing-small-border-width);outline-style:var(--gse-semantic-focusRing-small-border-style);outline-color:var(--gse-semantic-focusRing-small-border-color)}.gux-focus-ring-small-focused-within:focus-within{outline-width:var(--gse-semantic-focusRing-small-border-width);outline-style:var(--gse-semantic-focusRing-small-border-style);outline-color:var(--gse-semantic-focusRing-small-border-color)}.gux-focus-ring-small-focused-visible:focus-visible{outline-width:var(--gse-semantic-focusRing-small-border-width);outline-style:var(--gse-semantic-focusRing-small-border-style);outline-color:var(--gse-semantic-focusRing-small-border-color)}@font-face{font-family:Roboto;font-style:normal;font-weight:300;src:url("./fonts/roboto-v20-latin-300.eot");src:local("Roboto Light"), local("Roboto-Light"), url("./fonts/roboto-v20-latin-300.eot?#iefix") format("embedded-opentype"), url("./fonts/roboto-v20-latin-300.woff2") format("woff2"), url("./fonts/roboto-v20-latin-300.woff") format("woff"), url("./fonts/roboto-v20-latin-300.ttf") format("truetype"), url("./fonts/roboto-v20-latin-300.svg#Roboto") format("svg");}@font-face{font-family:Roboto;font-style:normal;font-weight:400;src:url("./fonts/roboto-v20-latin-regular.eot");src:local("Roboto"), local("Roboto-Regular"), url("./fonts/roboto-v20-latin-regular.eot?#iefix") format("embedded-opentype"), url("./fonts/roboto-v20-latin-regular.woff2") format("woff2"), url("./fonts/roboto-v20-latin-regular.woff") format("woff"), url("./fonts/roboto-v20-latin-regular.ttf") format("truetype"), url("./fonts/roboto-v20-latin-regular.svg#Roboto") format("svg");}@font-face{font-family:Roboto;font-style:italic;font-weight:400;src:url("./fonts/roboto-v20-latin-italic.eot");src:local("Roboto Italic"), local("Roboto-Italic"), url("./fonts/roboto-v20-latin-italic.eot?#iefix") format("embedded-opentype"), url("./fonts/roboto-v20-latin-italic.woff2") format("woff2"), url("./fonts/roboto-v20-latin-italic.woff") format("woff"), url("./fonts/roboto-v20-latin-italic.ttf") format("truetype"), url("./fonts/roboto-v20-latin-italic.svg#Roboto") format("svg");}@font-face{font-family:Roboto;font-style:normal;font-weight:700;src:url("./fonts/roboto-v20-latin-700.eot");src:local("Roboto Bold"), local("Roboto-Bold"), url("./fonts/roboto-v20-latin-700.eot?#iefix") format("embedded-opentype"), url("./fonts/roboto-v20-latin-700.woff2") format("woff2"), url("./fonts/roboto-v20-latin-700.woff") format("woff"), url("./fonts/roboto-v20-latin-700.ttf") format("truetype"), url("./fonts/roboto-v20-latin-700.svg#Roboto") format("svg");}body{font-family:Roboto, sans-serif;font-weight:400;font-size:12px;line-height:20px}h1{font-family:Roboto, sans-serif;font-weight:400;font-weight:300;font-size:24px;line-height:32px}h2{font-family:Roboto, sans-serif;font-weight:400;font-weight:300;font-size:18px;line-height:24px}h3{font-family:Roboto, sans-serif;font-weight:400;font-weight:700;font-size:14px;line-height:20px}h4,h5,h6{font-family:Roboto, sans-serif;font-weight:400;font-size:14px;line-height:20px}.gux-icon-anchor gux-icon{padding-right:var(--gse-ui-links-inLine-padding)}a{color:var(--gse-ui-link-default-color);text-decoration:underline;border-radius:var(--gse-ui-links-borderRadius)}a:hover{color:var(--gse-ui-link-hover-color)}a:active{color:var(--gse-ui-link-active-color)}a:visited{color:var(--gse-ui-link-visited-color)}a:focus-visible{outline-width:var(--gse-semantic-focusRing-default-border-width);outline-style:var(--gse-semantic-focusRing-default-border-style);outline-color:var(--gse-semantic-focusRing-default-border-color);outline-offset:var(--gse-semantic-focusRing-offset)}table a{color:var(--gse-ui-link-default-color);text-decoration:underline;border-radius:var(--gse-ui-links-borderRadius);text-decoration:none}table a:hover{color:var(--gse-ui-link-hover-color)}table a:active{color:var(--gse-ui-link-active-color)}table a:visited{color:var(--gse-ui-link-visited-color)}table a:focus-visible{outline-width:var(--gse-semantic-focusRing-default-border-width);outline-style:var(--gse-semantic-focusRing-default-border-style);outline-color:var(--gse-semantic-focusRing-default-border-color);outline-offset:var(--gse-semantic-focusRing-offset)}.gux-form-field-container.gux-beside{display:flex;flex-direction:row}.gux-form-field-error{display:none;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:flex-start;justify-content:flex-start;padding:var(--gse-ui-formControl-helper-errorPadding);font-family:var(--gse-ui-formControl-helper-helperText-fontFamily);font-size:var(--gse-ui-formControl-helper-helperText-fontSize);line-height:var(--gse-ui-formControl-helper-helperText-lineHeight);color:var(--gse-ui-formControl-helper-errorColor)}.gux-form-field-error.gux-show{display:flex}.gux-form-field-error gux-icon{flex:0 1 auto;align-self:auto;order:0;min-width:var(--gse-ui-icon-size-sm);min-height:var(--gse-ui-icon-size-sm);margin-right:var(--gse-ui-formControl-helper-gap);color:var(--gse-ui-formControl-helper-errorColor)}.gux-form-field-error .gux-message{flex:0 1 auto;align-self:auto;order:0}.gux-form-field-label.gux-required::after{color:var(--gse-ui-formControl-label-indicator-requiredColor);content:" *"}.gux-form-field-label.gux-beside{position:relative;top:8px;width:fit-content;min-width:45px;margin-right:var(--gse-ui-formControl-label-gap)}.gux-form-field-label.gux-above{padding:var(--gse-ui-formControl-label-padding)}.gux-form-field-label.gux-screenreader{position:absolute;top:auto;left:-10000px;width:1px;height:1px;overflow:hidden}.gux-form-field-help{display:none;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:flex-start;justify-content:flex-start;padding:var(--gse-ui-formControl-helper-padding);font-family:var(--gse-ui-formControl-helper-helperText-fontFamily);font-size:var(--gse-ui-formControl-helper-helperText-fontSize);line-height:var(--gse-ui-formControl-helper-helperText-lineHeight);color:var(--gse-ui-formControl-helper-defaultColor)}.gux-form-field-help.gux-show{display:flex}.gux-form-field-help .gux-message{flex:0 1 auto;align-self:none;order:0}:host{display:block}::slotted(label){font-family:var(--gse-ui-formControl-label-text-fontFamily);line-height:var(--gse-ui-formControl-label-text-lineHeight);font-size:var(--gse-ui-formControl-label-text-fontSize);color:var(--gse-ui-formControl-label-labelColor);font-weight:var(--gse-ui-formControl-label-text-fontWeight)}::slotted(textarea){flex:1 1 auto;align-self:auto;order:0;color:var(--gse-ui-formControl-input-populatedColor);font-family:inherit;font-family:var(--gse-ui-formControl-input-contentText-fontFamily);line-height:var(--gse-ui-formControl-input-contentText-lineHeight);font-size:var(--gse-ui-formControl-input-contentText-fontSize);font-weight:var(--gse-ui-formControl-input-contentText-fontWeight);resize:vertical;background-color:var(--gse-ui-formControl-input-backgroundColor);background-image:none;border:none;border-radius:var(--gse-ui-formControl-input-borderRadius);outline:none;padding:var(--gse-ui-formControl-textarea-padding);margin:0}::slotted(textarea)::placeholder{color:var(--gse-ui-formControl-input-placeholderColor);opacity:1}::slotted(textarea)[disabled]{opacity:var(--gse-ui-formControl-input-disabled-opacity)}.gux-input-and-error-container{flex-grow:1}.gux-input-and-error-container .gux-input{position:relative;display:flex;border:var(--gse-ui-formControl-input-default-border-width) var(--gse-ui-formControl-input-default-border-style) var(--gse-ui-formControl-input-default-border-color);border-radius:var(--gse-ui-formControl-input-borderRadius);outline:none}.gux-input-and-error-container .gux-input:focus-within{outline:var(--gse-ui-formControl-input-focus-border-width) var(--gse-ui-formControl-input-focus-border-style) var(--gse-ui-formControl-input-focus-border-color);border:var(--gse-ui-formControl-input-active-border-width) var(--gse-ui-formControl-input-active-border-style) var(--gse-ui-formControl-input-active-border-color);border-radius:var(--gse-ui-formControl-focusRing-borderRadius)}.gux-input-and-error-container .gux-input:hover:not(.gux-disabled){border:var(--gse-ui-formControl-input-hover-border-width) var(--gse-ui-formControl-input-hover-border-style) var(--gse-ui-formControl-input-hover-border-color)}.gux-input-and-error-container .gux-input.gux-input-error{border-color:var(--gse-ui-formControl-input-error-border-color)}.gux-input-and-error-container .gux-input.gux-disabled{opacity:var(--gse-ui-formControl-input-disabled-opacity)}.gux-input-and-error-container .gux-input.gux-resize-none ::slotted(textarea){resize:none}.gux-input-and-error-container .gux-input.gux-resize-auto{display:grid;overflow:hidden;word-break:normal;word-break:break-word;overflow-wrap:anywhere}.gux-input-and-error-container .gux-input.gux-resize-auto::after{grid-row-start:1;grid-row-end:2;grid-column-start:1;grid-column-end:2;white-space:pre-wrap;visibility:hidden;content:attr(data-replicated-value) " ";padding:var(--gse-ui-formControl-textarea-padding);margin:0}.gux-input-and-error-container .gux-input.gux-resize-auto ::slotted(textarea){grid-row-start:1;grid-row-end:2;grid-column-start:1;grid-column-end:2;overflow-x:hidden;resize:none}';export{v as gux_form_field_textarea}
|
@@ -1 +1 @@
|
|
1
|
-
import{r,h as e,g as i}from"./p-7d26b2e1.js";import{b as o}from"./p-deee079e.js";import{t as a}from"./p-
|
1
|
+
import{r,h as e,g as i}from"./p-7d26b2e1.js";import{b as o}from"./p-deee079e.js";import{t as a}from"./p-6517ed89.js";import"./p-8a133b9b.js";const t={info:"Information alert with message",success:"Success alert with message",warning:"Warning alert with message",error:"Error alert with message"},s=class{constructor(e){r(this,e),this.accent="info"}getIcon(r){switch(r){case"info":default:return"fa/circle-info-solid";case"success":return"fa/circle-check-solid";case"warning":return"fa/triangle-exclamation-solid";case"error":return"fa/hexagon-exclamation-solid"}}async componentWillLoad(){a(this.root,{variant:this.accent}),this.i18n=await o(this.root,t)}render(){return e("div",{class:{"gux-inline-alert":!0,[`gux-${this.accent}`]:!0}},e("gux-icon",{"icon-name":this.getIcon(this.accent),decorative:!0}),e("div",{class:"gux-message-wrapper"},e("div",{class:"gux-sr-only"},this.i18n(this.accent)),e("slot",null)))}get root(){return i(this)}};s.style=":host{display:block}.gux-inline-alert{display:flex;flex-direction:row;flex-wrap:nowrap;gap:var(--gse-ui-alert-gap);align-items:center;justify-content:flex-start;padding:var(--gse-ui-alert-padding);border:1px solid;border-radius:var(--gse-ui-alert-borderRadius)}.gux-inline-alert gux-icon{flex-shrink:0;align-self:flex-start;width:var(--gse-ui-icon-size-sm);height:var(--gse-ui-icon-size-sm);margin-top:1px}.gux-inline-alert gux-tooltip-title{white-space:nowrap}.gux-inline-alert .gux-message-wrapper{display:flex;justify-content:flex-start;align-items:center;gap:var(--gse-ui-alert-gap);font-family:var(--gse-ui-alert-text-fontFamily);font-size:var(--gse-ui-alert-text-fontSize);font-weight:var(--gse-ui-alert-text-fontWeight);line-height:var(--gse-ui-alert-text-lineHeight)}.gux-inline-alert .gux-sr-only:not(:focus):not(:active){position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);clip-path:inset(50%);white-space:nowrap}.gux-inline-alert.gux-info{color:var(--gse-ui-alert-info-foregroundColor);background-color:var(--gse-ui-alert-info-backgroundColor);border:var(--gse-ui-alert-info-border-width) var(--gse-ui-alert-info-border-style) var(--gse-ui-alert-info-border-color)}.gux-inline-alert.gux-info gux-icon{color:var(--gse-ui-alert-info-iconColor)}.gux-inline-alert.gux-error{color:var(--gse-ui-alert-error-foregroundColor);background-color:var(--gse-ui-alert-error-backgroundColor);border:var(--gse-ui-alert-error-border-width) var(--gse-ui-alert-error-border-style) var(--gse-ui-alert-error-border-color)}.gux-inline-alert.gux-error gux-icon{color:var(--gse-ui-alert-error-iconColor)}.gux-inline-alert.gux-warning{color:var(--gse-ui-alert-warning-foregroundColor);background-color:var(--gse-ui-alert-warning-backgroundColor);border:var(--gse-ui-alert-warning-border-width) var(--gse-ui-alert-warning-border-style) var(--gse-ui-alert-warning-border-color)}.gux-inline-alert.gux-warning gux-icon{color:var(--gse-ui-alert-warning-iconColor)}.gux-inline-alert.gux-success{color:var(--gse-ui-alert-success-foregroundColor);background-color:var(--gse-ui-alert-success-backgroundColor);border:var(--gse-ui-alert-success-border-width) var(--gse-ui-alert-success-border-style) var(--gse-ui-alert-success-border-color)}.gux-inline-alert.gux-success gux-icon{color:var(--gse-ui-alert-success-iconColor)}";export{s as gux_inline_alert}
|
@@ -1 +1 @@
|
|
1
|
-
import{r as t,h as s,H as e,g as i}from"./p-7d26b2e1.js";import{r as o}from"./p-cbcbd1bb.js";import{t as r}from"./p-
|
1
|
+
import{r as t,h as s,H as e,g as i}from"./p-7d26b2e1.js";import{r as o}from"./p-cbcbd1bb.js";import{t as r}from"./p-6517ed89.js";import{b as n}from"./p-deee079e.js";import{O as a}from"./p-9d18d475.js";import{b as c}from"./p-091f51f6.js";import{w as h}from"./p-76ff3e75.js";import"./p-8a133b9b.js";const l={contextMenuScreenreaderText:"Context menu"};const p=class{constructor(s){t(this,s),this.buttonId=o(),this.screenreaderText="",this.isOpen=!1}onClickOutside(){this.isOpen=!1}handleKeyDown(t){const s=t.composedPath().includes(this.listElement),e=t.composedPath().includes(this.button);switch(t.key){case"Escape":s&&(t.preventDefault(),this.isOpen=!1,this.button.focus());break;case"Tab":this.isOpen=!1;break;case"ArrowDown":case"Enter":e&&!this.isOpen&&(t.preventDefault(),this.isOpen=!0,this.focusFirstListItem());break;case"ArrowUp":e&&!this.isOpen&&(t.preventDefault(),this.isOpen=!0,this.focusLastListItem())}}handleKeyup(t){" "===t.key&&t.composedPath().includes(this.button)&&(t.preventDefault(),this.isOpen=!0,this.focusFirstListItem())}focusFirstListItem(){c((()=>{this.listElement.guxFocusFirstItem()}))}focusLastListItem(){c((()=>{this.listElement.guxFocusLastItem()}))}onButtonClick(){this.isOpen=!this.isOpen,this.isOpen&&this.focusFirstListItem()}onListClick(t){h("gux-list-item",t,(()=>{this.isOpen=!1,this.button.focus()}))}async componentWillLoad(){r(this.root),this.i18n=await n(this.root,l)}render(){return s(e,null,s("gux-popup",{expanded:this.isOpen},s("div",{slot:"target",class:"gux-button-container"},s("gux-button-slot",{accent:"ghost"},s("button",{type:"button",onClick:()=>this.onButtonClick(),id:this.buttonId,ref:t=>this.button=t,"aria-haspopup":"true","aria-expanded":this.isOpen.toString()},s("gux-icon",{"icon-name":"menu-kebab-vertical","screenreader-text":this.screenreaderText||this.i18n("contextMenuScreenreaderText")})))),s("div",{slot:"popup",class:"gux-list-container"},s("gux-list",{onClick:t=>this.onListClick(t),ref:t=>this.listElement=t},s("slot",null)))))}static get delegatesFocus(){return!0}get root(){return i(this)}};(function(t,s,e,i){var o,r=arguments.length,n=r<3?s:null===i?i=Object.getOwnPropertyDescriptor(s,e):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,s,e,i);else for(var a=t.length-1;a>=0;a--)(o=t[a])&&(n=(r<3?o(n):r>3?o(s,e,n):o(s,e))||n);r>3&&n&&Object.defineProperty(s,e,n)})([a({triggerEvents:"click"})],p.prototype,"onClickOutside",null),p.style=":host{display:block;max-width:fit-content}gux-icon{width:16px;height:16px;color:#6b7585}.gux-list-container{width:128px;padding:8px 0;margin:0;text-align:left;list-style:none;background-color:#fdfdfd;border:1px solid #b4bccb;border-radius:4px;box-shadow:0 2px 4px fade(#202937, 24%)}";export{p as gux_context_menu}
|
@@ -1 +1 @@
|
|
1
|
-
import{r as t,h as e,g as i}from"./p-7d26b2e1.js";import{b as o}from"./p-deee079e.js";import{c as s,o as r}from"./p-3f5341ea.js";import{O as n}from"./p-f34ce7dc.js";import{o as l}from"./p-3701eff0.js";import{h as a}from"./p-08bc2e6b.js";import{G as h,a as f,s as d,c as p,b as u}from"./p-b3c9fd06.js";import{G as x,a as g}from"./p-211cc1db.js";import{g as c}from"./p-aa2f9991.js";import{t as m}from"./p-
|
1
|
+
import{r as t,h as e,g as i}from"./p-7d26b2e1.js";import{b as o}from"./p-deee079e.js";import{c as s,o as r}from"./p-3f5341ea.js";import{O as n}from"./p-f34ce7dc.js";import{o as l}from"./p-3701eff0.js";import{h as a}from"./p-08bc2e6b.js";import{G as h,a as f,s as d,c as p,b as u}from"./p-b3c9fd06.js";import{G as x,a as g}from"./p-211cc1db.js";import{g as c}from"./p-aa2f9991.js";import{t as m}from"./p-6517ed89.js";import"./p-8a133b9b.js";import"./p-cbcbd1bb.js";import"./p-d0805f56.js";import"./p-d176c2ae.js";const b={required:"Required"};const w=class{constructor(e){t(this,e),this.labelPosition=void 0,this.computedLabelPosition="above",this.disabled=void 0,this.required=void 0,this.hasError=!1,this.hasHelp=!1}watchValue(t){const e=this.root.querySelector("gux-dropdown")||this.root.querySelector("gux-dropdown-multi-beta");e&&(e.hasError=t)}onMutation(){this.hasError=a(this.root,"error"),this.hasHelp=a(this.root,"help")}async componentWillLoad(){this.getI18nValue=await o(this.root,b),this.setInput(),this.setLabel(),this.hasError=a(this.root,"error"),this.hasHelp=a(this.root,"help"),m(this.root,{variant:this.variant})}disconnectedCallback(){this.disabledObserver&&this.disabledObserver.disconnect(),this.requiredObserver&&this.requiredObserver.disconnect()}renderScreenReaderText(t,i=!1){if(i)return e("gux-screen-reader-beta",null,t)}render(){return e(g,{labelPosition:this.computedLabelPosition},e(x,{position:this.computedLabelPosition,required:this.required},e("slot",{name:"label",onSlotchange:()=>this.setLabel()}),this.renderScreenReaderText(this.getI18nValue("required"),this.required),this.renderScreenReaderText(c(this.root,"error"),this.hasError),this.renderScreenReaderText(c(this.root,"help"),this.hasHelp)),e("div",{class:"gux-input-and-error-container"},e("div",{class:{"gux-input":!0,"gux-input-error":this.hasError,"gux-disabled":this.disabled}},e("slot",null)),e(h,{show:this.hasError},e("slot",{name:"error"})),e(f,{show:!this.hasError&&this.hasHelp},e("slot",{name:"help"}))))}get variant(){return`dropdown-${this.labelPosition?this.labelPosition.toLowerCase():"none"}`}setInput(){this.dropdownElement=this.root.querySelector("gux-dropdown")||this.root.querySelector("gux-dropdown-multi-beta"),this.listboxElement=this.root.querySelector("gux-listbox")||this.root.querySelector("gux-listbox-multi"),this.disabled=s(this.dropdownElement),this.required=this.dropdownElement.required,this.disabledObserver=r(this.dropdownElement,(t=>{this.disabled=t})),this.requiredObserver=l(this.dropdownElement,(t=>{this.required=t})),d(this.root,this.listboxElement,"label"),p(this.root,this.listboxElement,"error"),p(this.root,this.listboxElement,"help")}setLabel(){this.label=this.root.querySelector('label[slot="label"]'),this.computedLabelPosition=u(this.label,this.labelPosition)}get root(){return i(this)}static get watchers(){return{hasError:["watchValue"]}}};(function(t,e,i,o){var s,r=arguments.length,n=r<3?e:null===o?o=Object.getOwnPropertyDescriptor(e,i):o;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(t,e,i,o);else for(var l=t.length-1;l>=0;l--)(s=t[l])&&(n=(r<3?s(n):r>3?s(e,i,n):s(e,i))||n);r>3&&n&&Object.defineProperty(e,i,n)})([n({childList:!0,subtree:!0})],w.prototype,"onMutation",null),w.style=".gux-form-field-fieldset-container{display:flex;min-width:0;padding:0;margin:var(--gux-form-field-fieldset-container-margin-top, 16px) 0 var(--gux-form-field-fieldset-container-margin-bottom, 16px) 0;border:none}.gux-form-field-error{display:none;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:flex-start;justify-content:flex-start;margin:4px 0;font-size:12px;line-height:20px;color:#2e394c}.gux-form-field-error.gux-show{display:flex}.gux-form-field-error gux-icon{flex:0 1 auto;align-self:auto;order:0;min-width:16px;min-height:16px;margin:2px 4px 0 0;color:#ea0b0b}.gux-form-field-error .gux-message{flex:0 1 auto;align-self:auto;order:0}.gux-form-field-legend-label{padding:0}.gux-form-field-legend-label.gux-required::after{font-size:12px;color:#ea0b0b;content:' *'}.gux-form-field-legend-label.gux-beside{position:relative;top:8px;float:left;width:fit-content;min-width:45px;margin-right:8px}.gux-form-field-legend-label.gux-above{margin-bottom:8px}.gux-form-field-legend-label.gux-screenreader{position:absolute;top:auto;left:-10000px;width:1px;height:1px;overflow:hidden}.gux-form-field-help{display:none;flex-direction:row;flex-wrap:nowrap;align-content:stretch;align-items:flex-start;justify-content:flex-start;margin:4px 0;font-size:12px;font-weight:400;line-height:20px;color:#6b7585}.gux-form-field-help.gux-show{display:flex}.gux-form-field-help .gux-message{flex:0 1 auto;align-self:none;order:0}:host{display:block;color:#2e394c}::slotted(label){font-family:Roboto, sans-serif;font-weight:400;font-weight:700;font-size:12px;line-height:16px}.gux-input-and-error-container{flex-grow:1}.gux-input-and-error-container .gux-input.gux-disabled{pointer-events:none;opacity:0.5}";export{w as gux_form_field_dropdown}
|
@@ -1 +1 @@
|
|
1
|
-
import{r as t,c as s,h as i,H as h,g as a}from"./p-7d26b2e1.js";import{t as e}from"./p-
|
1
|
+
import{r as t,c as s,h as i,H as h,g as a}from"./p-7d26b2e1.js";import{t as e}from"./p-6517ed89.js";const l=class{constructor(i){t(this,i),this.guxactivetabchange=s(this,"guxactivetabchange",7),this.activeTab=void 0,this.orientation="horizontal",this.alignment="left",this.useFlexbox=!1,this.tabList=void 0,this.tabPanels=[]}watchActiveTab(t){this.activateTab(t,this.tabList,this.tabPanels),this.guxactivetabchange.emit(t)}onInternalActivateTabPanel(t){t.stopPropagation(),this.activateTab(t.detail,this.tabList,this.tabPanels)}async guxActivate(t){this.activateTab(t,this.tabList,this.tabPanels)}onSlotchange(){const[t,s]=Array.from(this.root.shadowRoot.querySelectorAll("slot"));this.tabList=t.assignedElements()[0],this.tabPanels=s.assignedElements(),this.activateTab(this.activeTab,this.tabList,this.tabPanels)}activateTab(t,s,i){this.activeTab=t||i[0].tabId,s.guxSetActive(this.activeTab),i.forEach((t=>{t.guxSetActive(t.tabId===this.activeTab)}))}componentWillLoad(){e(this.root)}render(){return i(h,{class:{"gux-flex":this.useFlexbox}},i("div",{class:`gux-tabs gux-${this.alignment} gux-${this.orientation}`},i("slot",{name:"tab-list"}),i("div",{class:`gux-${this.alignment} gux-${this.orientation} gux-panel-container`},i("slot",{onSlotchange:this.onSlotchange.bind(this)}))))}get root(){return a(this)}static get watchers(){return{activeTab:["watchActiveTab"]}}};l.style=":host(.gux-flex){display:flex;flex-direction:column}:host(.gux-flex) .gux-tabs{display:flex;flex-direction:column;height:100%}:host(.gux-flex) .gux-panel-container{display:flex;flex-direction:column;height:100%}.gux-tabs.gux-vertical{display:flex;height:100%}";export{l as gux_tabs}
|
@@ -1 +1 @@
|
|
1
|
-
import{r as t,h as o,H as s,g as e}from"./p-7d26b2e1.js";import{t as i}from"./p-
|
1
|
+
import{r as t,h as o,H as s,g as e}from"./p-7d26b2e1.js";import{t as i}from"./p-6517ed89.js";import{O as n}from"./p-9d18d475.js";import{b as r}from"./p-deee079e.js";import{b as u}from"./p-091f51f6.js";import"./p-8a133b9b.js";const a={additionalActions:"Additional Actions"};const c=class{constructor(o){t(this,o),this.showMenu=void 0,this.expanded=!1}handleKeyDown(t){const o=t.composedPath();switch(t.key){case"Escape":this.expanded=!1,o.includes(this.listElement)&&(t.preventDefault(),this.dropdownButton.focus());break;case"Tab":this.expanded=!1;break;case"ArrowDown":case"Enter":o.includes(this.dropdownButton)&&(t.preventDefault(),this.expanded=!0,this.focusFirstItemInPopupList())}}handleKeyup(t){if(" "===t.key)t.composedPath().includes(this.dropdownButton)&&(this.expanded=!0,this.focusFirstItemInPopupList())}onFocusin(){this.tooltipTitleElement.setShowTooltip()}onFocusout(){this.tooltipTitleElement.setHideTooltip()}toggle(){this.expanded=!this.expanded,this.expanded&&this.focusPopupList()}onClickOutside(){this.expanded=!1}focusPopupList(){u((()=>{this.listElement.focus()}))}focusFirstItemInPopupList(){u((()=>{this.listElement.guxFocusFirstItem()}))}async componentWillLoad(){this.i18n=await r(this.root,a),i(this.root)}render(){return o(s,{class:{"gux-show-menu":this.showMenu}},o("gux-popup",{expanded:this.expanded},o("div",{slot:"target",class:"gux-toolbar-menu-container"},o("gux-button-slot",{class:"gux-menu-button"},o("button",{type:"button",ref:t=>this.dropdownButton=t,onMouseUp:()=>this.toggle(),"aria-haspopup":"true","aria-expanded":this.expanded.toString()},o("gux-tooltip-title",{ref:t=>this.tooltipTitleElement=t},o("span",null,o("gux-icon",{"screenreader-text":this.i18n("additionalActions"),"icon-name":"menu-kebab-horizontal"})))))),o("div",{class:"gux-list-container",slot:"popup"},o("gux-list",{ref:t=>this.listElement=t},o("slot",null)))))}static get delegatesFocus(){return!0}get root(){return e(this)}};(function(t,o,s,e){var i,n=arguments.length,r=n<3?o:null===e?e=Object.getOwnPropertyDescriptor(o,s):e;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)r=Reflect.decorate(t,o,s,e);else for(var u=t.length-1;u>=0;u--)(i=t[u])&&(r=(n<3?i(r):n>3?i(o,s,r):i(o,s))||r);n>3&&r&&Object.defineProperty(o,s,r)})([n({triggerEvents:"mousedown"})],c.prototype,"onClickOutside",null),c.style=":host{display:none;-webkit-user-select:none;user-select:none}:host(.gux-show-menu){display:block}.gux-menu-button button{color:var(--gse-ui-button-secondary-default-foregroundColor);cursor:grab;background-color:var(--gse-ui-button-secondary-default-backgroundColor);border:none}.gux-menu-button button gux-icon{width:var(--gse-ui-icon-size-sm);height:var(--gse-ui-icon-size-sm)}.gux-list-container{width:min-content;padding:var(--gse-ui-menu-padding);margin:0;list-style:none;background-color:var(--gse-ui-menu-backgroundColor);border:1px var(--gse-ui-menu-border-style) var(--gse-ui-menu-border-color);border-radius:var(--gse-ui-menu-borderRadius);box-shadow:var(--gse-ui-menu-boxShadow-x) var(--gse-ui-menu-boxShadow-y) var(--gse-ui-menu-boxShadow-blur) var(--gse-ui-menu-boxShadow-spread) var(--gse-ui-menu-boxShadow-color)}";export{c as gux_table_toolbar_menu_button}
|
@@ -1 +1 @@
|
|
1
|
-
import{r as e,c as t,f as n,h as s,g as o}from"./p-7d26b2e1.js";import{b as a}from"./p-deee079e.js";import{t as r}from"./p-
|
1
|
+
import{r as e,c as t,f as n,h as s,g as o}from"./p-7d26b2e1.js";import{b as a}from"./p-deee079e.js";import{t as r}from"./p-6517ed89.js";import{g as i,s as c,a as h,b as l,c as u,d,e as p,f as m,h as g}from"./p-4a6ae41e.js";import"./p-8a133b9b.js";import"./p-9dd4b14a.js";import"./p-d176c2ae.js";const x={search:"Search column",searchResults:"search results",selectedColumnCount:"{count}/{total} Columns Selected",selectAllColumnsScreenReader:"{count} of {total} columns selected: check checkbox to select all {total} columns",unselectAllColumnsScreenReader:"{count} of {total} columns selected: uncheck checkbox to unselect all {total} columns",movePositionPrompt:"Press space or enter to move the {columnName} column to position {newPositionNumber} from position {oldPositionNumber}.",reorderingModeActive:"Reordering mode active. Reposition the {columnName} column using the up arrow key, the down arrow key, the home key and the end key. Press Escape to deactivate reordering mode."},b=class{constructor(n){e(this,n),this.guxorderchange=t(this,"guxorderchange",7),this.highlightResults={matchCount:0,currentMatch:0},this.keyboardOrderChange=i()}watchKeyboardOrderChange(){c(this.root,this.keyboardOrderChange)}async componentWillLoad(){r(this.root),this.i18n=await a(this.root,x)}componentDidLoad(){h(this.root,this.mainCheckboxElement)}handleInternalorderchange(e){e.stopPropagation(),this.emitOrderChange(e.detail)}emitOrderChange(e){const{oldIndex:t,newIndex:n}=e;if(t!==n){const t=l(this.root,e);this.guxorderchange.emit(t)}}handleInternalkeyboardorderstart(e){e.stopPropagation();const t=e.detail,n=u(e.target);this.keyboardOrderChange={oldIndex:n,newIndex:n},this.announceElement.guxAnnounce(this.i18n("reorderingModeActive",{columnName:t}))}handleInternalkeyboardreordermove(e){e.stopPropagation();const{delta:t,column:n}=e.detail;this.keyboardOrderChange=d(this.root,this.keyboardOrderChange,t),this.announceElement.guxAnnounce(this.i18n("movePositionPrompt",{columnName:n,newPositionNumber:this.keyboardOrderChange.newIndex+1,oldPositionNumber:this.keyboardOrderChange.oldIndex+1}))}handleInternalkeyboarddoreorder(e){e.stopPropagation(),this.emitOrderChange(this.keyboardOrderChange),e.target.guxFocus()}handleInternalkeyboardorderfinish(e){e.stopPropagation(),this.keyboardOrderChange=i()}onSearchInput(){this.highlightResults=p(this.root,this.searchElement)}onGuxCurrentMatchChanged(e){this.highlightResults=p(this.root,this.searchElement,e.detail)}onMainCheckboxChange(){m(this.root,this.mainCheckboxElement.checked),n(this.root)}onListChange(){h(this.root,this.mainCheckboxElement),n(this.root)}onSlotChange(){this.onListChange()}renderSelectedColumnCount(){const{count:e,total:t}=g(this.root);return s("div",null,s("span",{"aria-hidden":"true"},this.i18n("selectedColumnCount",{count:e,total:t})),s("span",{class:"gux-sr-only"},s("span",null,": ",this.i18n(e===t?"unselectAllColumnsScreenReader":"selectAllColumnsScreenReader",{count:e,total:t}))))}render(){return s("div",{class:"gux-container"},s("div",{class:"gux-sr-only","aria-live":"polite"},`${this.highlightResults.matchCount} ${this.i18n("searchResults")}`),s("div",{class:"gux-search"},s("gux-content-search",{"match-count":this.highlightResults.matchCount,"current-match":this.highlightResults.currentMatch,onGuxcurrentmatchchanged:e=>this.onGuxCurrentMatchChanged(e)},s("input",{type:"search",placeholder:this.i18n("search"),onInput:()=>this.onSearchInput(),ref:e=>this.searchElement=e}))),s("div",{class:"gux-select"},s("gux-form-field-checkbox",null,s("input",{slot:"input",type:"checkbox",ref:e=>this.mainCheckboxElement=e,onChange:()=>this.onMainCheckboxChange()}),s("label",{slot:"label"},this.renderSelectedColumnCount()))),s("div",{class:"gux-list",onChange:()=>this.onListChange()},s("slot",{onSlotchange:()=>this.onSlotChange()})),s("gux-announce-beta",{ref:e=>this.announceElement=e}))}get root(){return o(this)}static get watchers(){return{keyboardOrderChange:["watchKeyboardOrderChange"]}}};b.style=".gux-container{width:320px;min-width:320px}.gux-container .gux-search gux-content-search{width:100%}.gux-container .gux-search gux-content-search input[type=search]::-webkit-search-decoration,.gux-container .gux-search gux-content-search input[type=search]::-webkit-search-cancel-button,.gux-container .gux-search gux-content-search input[type=search]::-webkit-search-results-button,.gux-container .gux-search gux-content-search input[type=search]::-webkit-search-results-decoration{display:none;-webkit-appearance:none}.gux-container .gux-select{padding:8px 0 8px 16px;margin:4px 0;color:#596373;background-color:#f6f7f9;border-radius:4px}.gux-sr-only:not(:focus):not(:active){position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);clip-path:inset(50%);white-space:nowrap}";export{b as gux_column_manager}
|