genesys-spark-components 4.0.0-beta.34 → 4.0.0-beta.36
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/en-85604f0f.js +24 -0
- package/dist/cjs/genesys-webcomponents.cjs.js +3 -6
- package/dist/cjs/{get-valid-timezone-39ba3e64.js → get-valid-timezone-5a9231d3.js} +1 -1
- package/dist/cjs/gux-accordion-section.cjs.entry.js +4 -4
- package/dist/cjs/gux-accordion.cjs.entry.js +2 -2
- package/dist/cjs/gux-action-button.cjs.entry.js +8 -8
- package/dist/cjs/gux-action-toast-legacy.cjs.entry.js +3 -3
- package/dist/cjs/gux-advanced-dropdown-legacy.cjs.entry.js +8 -8
- package/dist/cjs/gux-all-row-select.cjs.entry.js +5 -5
- package/dist/cjs/gux-announce-beta.cjs.entry.js +3 -3
- package/dist/cjs/gux-badge.cjs.entry.js +5 -5
- package/dist/cjs/gux-blank-state.cjs.entry.js +3 -3
- package/dist/cjs/gux-breadcrumb-item.cjs.entry.js +3 -3
- package/dist/cjs/gux-breadcrumbs.cjs.entry.js +5 -5
- package/dist/cjs/gux-button-multi.cjs.entry.js +6 -6
- package/dist/cjs/gux-button-slot.cjs.entry.js +4 -4
- package/dist/cjs/gux-button.cjs.entry.js +3 -3
- package/dist/cjs/gux-calendar-beta.cjs.entry.js +9 -9
- package/dist/cjs/gux-calendar.cjs.entry.js +8 -8
- package/dist/cjs/gux-card.cjs.entry.js +2 -2
- package/dist/cjs/gux-column-manager-item.cjs.entry.js +7 -7
- package/dist/cjs/gux-column-manager.cjs.entry.js +7 -7
- package/dist/cjs/{gux-column-manager.service-8a71e1f3.js → gux-column-manager.service-7f1cc862.js} +2 -2
- package/dist/cjs/gux-content-search.cjs.entry.js +7 -7
- package/dist/cjs/gux-context-menu.cjs.entry.js +9 -9
- package/dist/cjs/gux-copy-to-clipboard.cjs.entry.js +7 -7
- package/dist/cjs/gux-create-option.cjs.entry.js +5 -5
- package/dist/cjs/gux-date-beta.cjs.entry.js +5 -5
- package/dist/cjs/gux-date-time-beta.cjs.entry.js +5 -5
- package/dist/cjs/gux-datepicker.cjs.entry.js +10 -10
- package/dist/cjs/gux-disclosure-button-legacy.cjs.entry.js +5 -5
- package/dist/cjs/gux-dismiss-button.cjs.entry.js +5 -5
- package/dist/cjs/gux-dropdown-multi-tag.cjs.entry.js +4 -4
- package/dist/cjs/gux-dropdown-multi.cjs.entry.js +11 -11
- package/dist/cjs/gux-dropdown-option.cjs.entry.js +1 -1
- package/dist/cjs/gux-dropdown_3.cjs.entry.js +15 -15
- package/dist/cjs/gux-flyout-menu.cjs.entry.js +5 -5
- package/dist/cjs/gux-form-field-checkbox.cjs.entry.js +10 -10
- package/dist/cjs/gux-form-field-color.cjs.entry.js +13 -13
- package/dist/cjs/{gux-form-field-container-64e8bc38.js → gux-form-field-container-48871f4b.js} +1 -1
- package/dist/cjs/gux-form-field-dropdown.cjs.entry.js +15 -15
- package/dist/cjs/{gux-form-field-fieldset-container-1abe7d3b.js → gux-form-field-fieldset-container-c0d39bed.js} +1 -1
- package/dist/cjs/gux-form-field-input-clear-button.cjs.entry.js +5 -5
- package/dist/cjs/gux-form-field-number_3.cjs.entry.js +23 -23
- package/dist/cjs/gux-form-field-phone.cjs.entry.js +14 -14
- package/dist/cjs/gux-form-field-radio.cjs.entry.js +11 -11
- package/dist/cjs/gux-form-field-range.cjs.entry.js +13 -13
- package/dist/cjs/gux-form-field-search.cjs.entry.js +13 -13
- package/dist/cjs/gux-form-field-select.cjs.entry.js +13 -13
- package/dist/cjs/gux-form-field-text-like.cjs.entry.js +13 -13
- package/dist/cjs/gux-form-field-textarea.cjs.entry.js +13 -13
- package/dist/cjs/gux-form-field-time-picker.cjs.entry.js +14 -14
- package/dist/cjs/{gux-form-field.service-dd469568.js → gux-form-field.service-704c78c2.js} +5 -5
- package/dist/cjs/gux-icon.cjs.entry.js +3 -3
- package/dist/cjs/gux-inline-alert.cjs.entry.js +5 -5
- package/dist/cjs/gux-list-divider.cjs.entry.js +1 -1
- package/dist/cjs/gux-list-item.cjs.entry.js +3 -3
- package/dist/cjs/gux-list.cjs.entry.js +3 -3
- package/dist/cjs/gux-listbox-multi.cjs.entry.js +9 -9
- package/dist/cjs/gux-loading-message.cjs.entry.js +3 -3
- package/dist/cjs/gux-menu-option.cjs.entry.js +2 -2
- package/dist/cjs/gux-menu.cjs.entry.js +1 -1
- package/dist/cjs/gux-modal.cjs.entry.js +4 -4
- package/dist/cjs/gux-month-calendar.cjs.entry.js +7 -7
- package/dist/cjs/gux-month-list_2.cjs.entry.js +4 -4
- package/dist/cjs/gux-month-picker-beta.cjs.entry.js +9 -9
- package/dist/cjs/gux-notification-toast-legacy.cjs.entry.js +3 -3
- package/dist/cjs/gux-option-icon.cjs.entry.js +3 -3
- package/dist/cjs/gux-option-multi.cjs.entry.js +5 -5
- package/dist/cjs/gux-page-loading-spinner.cjs.entry.js +2 -2
- package/dist/cjs/gux-pagination-buttons-legacy_3.cjs.entry.js +6 -6
- package/dist/cjs/gux-pagination-buttons_3.cjs.entry.js +8 -8
- package/dist/cjs/gux-pagination-cursor.cjs.entry.js +5 -5
- package/dist/cjs/gux-pagination-legacy.cjs.entry.js +3 -3
- package/dist/cjs/gux-pagination.cjs.entry.js +4 -4
- package/dist/cjs/gux-phone-input-beta.cjs.entry.js +8 -8
- package/dist/cjs/gux-popover-list.cjs.entry.js +6 -6
- package/dist/cjs/gux-popup.cjs.entry.js +3 -3
- package/dist/cjs/gux-radial-loading.cjs.entry.js +5 -5
- package/dist/cjs/gux-radial-progress.cjs.entry.js +4 -4
- package/dist/cjs/gux-rating.cjs.entry.js +6 -6
- package/dist/cjs/gux-region-icon.cjs.entry.js +2 -2
- package/dist/cjs/gux-row-select.cjs.entry.js +5 -5
- package/dist/cjs/gux-screen-reader-beta.cjs.entry.js +2 -2
- package/dist/cjs/gux-segmented-control-beta.cjs.entry.js +3 -3
- package/dist/cjs/gux-segmented-control-item.cjs.entry.js +5 -5
- package/dist/cjs/gux-simple-toast-legacy.cjs.entry.js +2 -2
- package/dist/cjs/gux-skip-navigation-item.cjs.entry.js +1 -1
- package/dist/cjs/gux-skip-navigation-list.cjs.entry.js +4 -4
- package/dist/cjs/gux-sort-control.cjs.entry.js +7 -7
- package/dist/cjs/gux-submenu.cjs.entry.js +4 -4
- package/dist/cjs/gux-switch-item.cjs.entry.js +2 -2
- package/dist/cjs/gux-switch-legacy.cjs.entry.js +3 -3
- package/dist/cjs/gux-tab-advanced-legacy.cjs.entry.js +157 -0
- package/dist/cjs/gux-tab-advanced-list-legacy.cjs.entry.js +470 -0
- package/dist/cjs/gux-tab-advanced-list.cjs.entry.js +25 -3044
- package/dist/cjs/gux-tab-advanced-panel-legacy.cjs.entry.js +34 -0
- package/dist/cjs/gux-tab-advanced-panel.cjs.entry.js +2 -2
- package/dist/cjs/gux-tab-advanced.cjs.entry.js +7 -7
- package/dist/cjs/gux-tab-list.cjs.entry.js +6 -6
- package/dist/cjs/gux-tab-panel.cjs.entry.js +2 -2
- package/dist/cjs/gux-tab.cjs.entry.js +1 -1
- package/dist/cjs/gux-table-select-menu.cjs.entry.js +8 -8
- package/dist/cjs/gux-table-select-popover.cjs.entry.js +3 -3
- package/dist/cjs/gux-table-toolbar-action.cjs.entry.js +5 -5
- package/dist/cjs/gux-table-toolbar-custom-action.cjs.entry.js +3 -3
- package/dist/cjs/gux-table-toolbar-menu-button.cjs.entry.js +6 -6
- package/dist/cjs/gux-table-toolbar.cjs.entry.js +5 -5
- package/dist/cjs/gux-table.cjs.entry.js +8 -8
- package/dist/cjs/gux-tabs-advanced-legacy.cjs.entry.js +63 -0
- package/dist/cjs/gux-tabs-advanced.cjs.entry.js +2 -2
- package/dist/cjs/gux-tabs.cjs.entry.js +2 -2
- package/dist/cjs/gux-tag.cjs.entry.js +5 -5
- package/dist/cjs/gux-text-highlight.cjs.entry.js +2 -2
- package/dist/cjs/gux-time-beta.cjs.entry.js +5 -5
- package/dist/cjs/gux-time-picker.cjs.entry.js +8 -8
- package/dist/cjs/gux-time-zone-picker-beta.cjs.entry.js +5 -5
- package/dist/cjs/gux-toast.cjs.entry.js +4 -4
- package/dist/cjs/gux-toggle-slider.cjs.entry.js +2 -2
- package/dist/cjs/gux-toggle.cjs.entry.js +5 -5
- package/dist/cjs/gux-tooltip-title.cjs.entry.js +4 -4
- package/dist/cjs/gux-tooltip.cjs.entry.js +7 -7
- package/dist/cjs/gux-truncate.cjs.entry.js +3 -3
- package/dist/cjs/{index-0d0fdb85.js → index-39160f18.js} +175 -43
- package/dist/cjs/{index-9bbde1aa.js → index-ff762de3.js} +2 -2
- package/dist/cjs/loader.cjs.js +3 -12
- package/dist/cjs/{on-click-outside-428f8bbf.js → on-click-outside-a7d87c91.js} +1 -1
- package/dist/cjs/{on-mutation-247f99dd.js → on-mutation-f396cc0e.js} +1 -1
- package/dist/cjs/{on-resize-ee6a4b87.js → on-resize-b4982908.js} +1 -1
- package/dist/cjs/sortable.esm-73cf219b.js +3023 -0
- package/dist/cjs/{usage-b1e23593.js → usage-d4216a6a.js} +5 -5
- package/dist/collection/collection-manifest.json +127 -123
- package/dist/collection/components/beta/gux-announce/gux-announce.js +7 -5
- package/dist/collection/components/beta/gux-announce/tests/gux-announce.e2e.js +18 -0
- package/dist/collection/components/beta/gux-announce/tests/gux-announce.spec.js +19 -0
- package/dist/collection/components/beta/gux-calendar-beta/components/single/gux-calendar.css +14 -15
- package/dist/collection/components/beta/gux-calendar-beta/components/single/gux-calendar.js +9 -9
- package/dist/collection/components/beta/gux-calendar-beta/services/calendar.service.js +1 -1
- package/dist/collection/components/beta/gux-calendar-beta/tests/gux-calendar.e2e.js +202 -0
- package/dist/collection/components/beta/gux-calendar-beta/tests/gux-calendar.spec.js +19 -0
- package/dist/collection/components/beta/gux-date/gux-date.js +9 -7
- package/dist/collection/components/beta/gux-date/tests/gux-date.e2e.js +30 -0
- package/dist/collection/components/beta/gux-date/tests/gux-date.spec.js +30 -0
- package/dist/collection/components/beta/gux-date-time/gux-date-time.js +9 -7
- package/dist/collection/components/beta/gux-date-time/tests/gux-date-time.e2e.js +30 -0
- package/dist/collection/components/beta/gux-date-time/tests/gux-date-time.spec.js +30 -0
- package/dist/collection/components/beta/gux-month-picker/gux-month-calendar/gux-month-calendar.css +7 -7
- package/dist/collection/components/beta/gux-month-picker/gux-month-calendar/gux-month-calendar.js +18 -12
- package/dist/collection/components/beta/gux-month-picker/gux-month-calendar/gux-month-list/gux-month-list-item/gux-month-list-item.css +3 -3
- package/dist/collection/components/beta/gux-month-picker/gux-month-calendar/gux-month-list/gux-month-list-item/gux-month-list-item.js +4 -3
- package/dist/collection/components/beta/gux-month-picker/gux-month-calendar/gux-month-list/gux-month-list.js +4 -3
- package/dist/collection/components/beta/gux-month-picker/gux-month-picker.css +5 -5
- package/dist/collection/components/beta/gux-month-picker/gux-month-picker.js +14 -11
- package/dist/collection/components/beta/gux-month-picker/tests/gux-month-picker.e2e.js +18 -0
- package/dist/collection/components/beta/gux-month-picker/tests/gux-month-picker.spec.js +27 -0
- package/dist/collection/components/beta/gux-phone-input/components/gux-region-icon/gux-region-icon.js +3 -3
- package/dist/collection/components/beta/gux-phone-input/components/gux-region-icon/gux-region-select.service.js +1 -1
- package/dist/collection/components/beta/gux-phone-input/gux-phone-input.css +2 -45
- package/dist/collection/components/beta/gux-phone-input/gux-phone-input.js +12 -11
- package/dist/collection/components/beta/gux-phone-input/services/region-map.service.js +1 -1
- package/dist/collection/components/beta/gux-phone-input/tests/gux-phone-input.e2e.js +88 -0
- package/dist/collection/components/beta/gux-screen-reader/gux-screen-reader.js +2 -2
- package/dist/collection/components/beta/gux-screen-reader/tests/gux-screen-reader.e2e.js +16 -0
- package/dist/collection/components/beta/gux-screen-reader/tests/gux-screen-reader.spec.js +17 -0
- package/dist/collection/components/beta/gux-segmented-control/gux-segmented-control-item/gux-segmented-control-item.css +18 -61
- package/dist/collection/components/beta/gux-segmented-control/gux-segmented-control-item/gux-segmented-control-item.js +4 -4
- package/dist/collection/components/beta/gux-segmented-control/gux-segmented-control.js +3 -3
- package/dist/collection/components/beta/gux-segmented-control/tests/gux-segmented-control.e2e.js +108 -0
- package/dist/collection/components/beta/gux-segmented-control/tests/gux-segmented-control.spec.js +126 -0
- package/dist/collection/components/beta/gux-time/gux-time.js +9 -7
- package/dist/collection/components/beta/gux-time/tests/gux-time.e2e.js +30 -0
- package/dist/collection/components/beta/gux-time/tests/gux-time.spec.js +30 -0
- package/dist/collection/components/beta/gux-time-zone-picker/gux-time-zone-picker.js +7 -7
- package/dist/collection/components/beta/gux-time-zone-picker/tests/gux-time-zone-picker.e2e.js +53 -0
- package/dist/collection/components/beta/gux-time-zone-picker/tests/gux-time-zone-picker.spec.js +15 -0
- package/dist/collection/components/legacy/gux-action-toast-legacy/gux-action-toast.css +1 -44
- package/dist/collection/components/legacy/gux-action-toast-legacy/gux-action-toast.js +2 -2
- package/dist/collection/components/legacy/gux-action-toast-legacy/tests/gux-action-toast.e2e.js +26 -0
- package/dist/collection/components/legacy/gux-action-toast-legacy/tests/gux-action-toast.spec.js +28 -0
- package/dist/collection/components/legacy/gux-advanced-dropdown-legacy/dropdown-option/gux-dropdown-option.js +5 -3
- package/dist/collection/components/legacy/gux-advanced-dropdown-legacy/dropdown-option/tests/gux-dropdown-option.spec.js +47 -0
- package/dist/collection/components/legacy/gux-advanced-dropdown-legacy/gux-advanced-dropdown.css +1 -52
- package/dist/collection/components/legacy/gux-advanced-dropdown-legacy/gux-advanced-dropdown.js +11 -9
- package/dist/collection/components/legacy/gux-advanced-dropdown-legacy/tests/gux-advanced-dropdown.e2e.js +149 -0
- package/dist/collection/components/legacy/gux-advanced-dropdown-legacy/tests/gux-advanced-dropdown.spec.js +17 -0
- package/dist/collection/components/legacy/gux-disclosure-button-legacy/gux-disclosure-button.js +7 -6
- package/dist/collection/components/legacy/gux-disclosure-button-legacy/tests/gux-disclosure-button.e2e.js +80 -0
- package/dist/collection/components/legacy/gux-disclosure-button-legacy/tests/gux-disclosure-button.spec.js +82 -0
- package/dist/collection/components/legacy/gux-notification-toast-legacy/gux-notification-toast.css +1 -44
- package/dist/collection/components/legacy/gux-notification-toast-legacy/gux-notification-toast.js +4 -3
- package/dist/collection/components/legacy/gux-notification-toast-legacy/tests/gux-notification-toast.e2e.js +109 -0
- package/dist/collection/components/legacy/gux-notification-toast-legacy/tests/gux-notification-toast.spec.js +99 -0
- package/dist/collection/components/legacy/gux-pagination-legacy/gux-pagination-buttons-legacy/gux-pagination-buttons-legacy.css +14 -14
- package/dist/collection/components/legacy/gux-pagination-legacy/gux-pagination-buttons-legacy/gux-pagination-buttons.js +6 -5
- package/dist/collection/components/legacy/gux-pagination-legacy/gux-pagination-buttons-legacy/tests/gux-pagination-buttons.service.spec.js +138 -0
- package/dist/collection/components/legacy/gux-pagination-legacy/gux-pagination-buttons-legacy/tests/gux-pagination-buttons.spec.js +39 -0
- package/dist/collection/components/legacy/gux-pagination-legacy/gux-pagination-item-counts-legacy/gux-pagination-item-counts-legacy.css +3 -3
- package/dist/collection/components/legacy/gux-pagination-legacy/gux-pagination-item-counts-legacy/gux-pagination-item-counts.js +3 -3
- package/dist/collection/components/legacy/gux-pagination-legacy/gux-pagination-item-counts-legacy/tests/gux-pagination-item-counts.spec.js +30 -0
- package/dist/collection/components/legacy/gux-pagination-legacy/gux-pagination-items-per-page-legacy/gux-pagination-items-per-page-legacy.css +3 -3
- package/dist/collection/components/legacy/gux-pagination-legacy/gux-pagination-items-per-page-legacy/gux-pagination-items-per-page.js +5 -4
- package/dist/collection/components/legacy/gux-pagination-legacy/gux-pagination-items-per-page-legacy/tests/gux-pagination-items-per-page.spec.js +33 -0
- package/dist/collection/components/legacy/gux-pagination-legacy/gux-pagination-legacy.css +1 -1
- package/dist/collection/components/legacy/gux-pagination-legacy/gux-pagination.js +8 -5
- package/dist/collection/components/legacy/gux-pagination-legacy/tests/gux-pagination.e2e.js +53 -0
- package/dist/collection/components/legacy/gux-pagination-legacy/tests/gux-pagination.spec.js +65 -0
- package/dist/collection/components/legacy/gux-simple-toast-legacy/gux-simple-toast.js +4 -3
- package/dist/collection/components/legacy/gux-simple-toast-legacy/tests/gux-simple-toast.e2e.js +103 -0
- package/dist/collection/components/legacy/gux-simple-toast-legacy/tests/gux-simple-toast.spec.js +93 -0
- package/dist/collection/components/legacy/gux-switch-legacy/gux-switch-item/gux-switch-item.css +0 -43
- package/dist/collection/components/legacy/gux-switch-legacy/gux-switch-item/gux-switch-item.js +1 -1
- package/dist/collection/components/legacy/gux-switch-legacy/gux-switch.js +5 -4
- package/dist/collection/components/legacy/gux-switch-legacy/tests/gux-switch.e2e.js +87 -0
- package/dist/collection/components/legacy/gux-switch-legacy/tests/gux-switch.spec.js +116 -0
- package/dist/collection/components/legacy/gux-tabs-advanced-legacy/gux-tab-advanced/gux-tab-advanced.css +117 -0
- package/dist/collection/components/legacy/gux-tabs-advanced-legacy/gux-tab-advanced/gux-tab-advanced.js +320 -0
- package/dist/collection/components/legacy/gux-tabs-advanced-legacy/gux-tab-advanced-list/gux-tab-advanced-list.css +127 -0
- package/dist/collection/components/legacy/gux-tabs-advanced-legacy/gux-tab-advanced-list/gux-tab-advanced-list.js +624 -0
- package/dist/collection/components/legacy/gux-tabs-advanced-legacy/gux-tab-advanced-panel/gux-tab-advanced-panel.css +7 -0
- package/dist/collection/components/legacy/gux-tabs-advanced-legacy/gux-tab-advanced-panel/gux-tab-advanced-panel.js +107 -0
- package/dist/collection/components/legacy/gux-tabs-advanced-legacy/gux-tabs-advanced.css +3 -0
- package/dist/collection/components/legacy/gux-tabs-advanced-legacy/gux-tabs-advanced.js +148 -0
- package/dist/collection/components/legacy/gux-tabs-advanced-legacy/tests/gux-tabs-advanced.e2e.js +216 -0
- package/dist/collection/components/legacy/gux-tabs-advanced-legacy/tests/gux-tabs-advanced.spec.js +73 -0
- package/dist/collection/components/stable/gux-accordion/gux-accordion-section/gux-accordion-section.css +4 -94
- package/dist/collection/components/stable/gux-accordion/gux-accordion-section/gux-accordion-section.js +7 -5
- package/dist/collection/components/stable/gux-accordion/gux-accordion.js +2 -2
- package/dist/collection/components/stable/gux-accordion/tests/gux-accordion.e2e.js +46 -0
- package/dist/collection/components/stable/gux-accordion/tests/gux-accordion.spec.js +52 -0
- package/dist/collection/components/stable/gux-action-button/gux-action-button.css +1 -1
- package/dist/collection/components/stable/gux-action-button/gux-action-button.js +12 -10
- package/dist/collection/components/stable/gux-action-button/tests/gux-action-button.e2e.js +93 -0
- package/dist/collection/components/stable/gux-action-button/tests/gux-action-button.spec.js +96 -0
- package/dist/collection/components/stable/gux-alert/gux-inline-alert.css +2 -2
- package/dist/collection/components/stable/gux-alert/gux-inline-alert.js +6 -5
- package/dist/collection/components/stable/gux-alert/tests/gux-inline-alert.e2e.js +22 -0
- package/dist/collection/components/stable/gux-alert/tests/gux-inline-alert.spec.js +23 -0
- package/dist/collection/components/stable/gux-badge/gux-badge.css +3 -3
- package/dist/collection/components/stable/gux-badge/gux-badge.js +6 -5
- package/dist/collection/components/stable/gux-badge/tests/gux-badge.e2e.js +38 -0
- package/dist/collection/components/stable/gux-badge/tests/gux-badge.spec.js +39 -0
- package/dist/collection/components/stable/gux-blank-state/gux-blank-state.css +9 -9
- package/dist/collection/components/stable/gux-blank-state/gux-blank-state.js +2 -2
- package/dist/collection/components/stable/gux-blank-state/tests/gux-blank-state.e2e.js +19 -0
- package/dist/collection/components/stable/gux-blank-state/tests/gux-blank-state.spec.js +26 -0
- package/dist/collection/components/stable/gux-breadcrumbs/breadcrumb-item/gux-breadcrumb-item.css +5 -5
- package/dist/collection/components/stable/gux-breadcrumbs/breadcrumb-item/gux-breadcrumb-item.js +2 -2
- package/dist/collection/components/stable/gux-breadcrumbs/gux-breadcrumbs.css +3 -3
- package/dist/collection/components/stable/gux-breadcrumbs/gux-breadcrumbs.js +6 -5
- package/dist/collection/components/stable/gux-breadcrumbs/tests/gux-breadcrumbs.e2e.js +48 -0
- package/dist/collection/components/stable/gux-breadcrumbs/tests/gux-breadcrumbs.spec.js +91 -0
- package/dist/collection/components/stable/gux-button/gux-button.css +9 -50
- package/dist/collection/components/stable/gux-button/gux-button.js +6 -4
- package/dist/collection/components/stable/gux-button/tests/gux-button.e2e.js +131 -0
- package/dist/collection/components/stable/gux-button/tests/gux-button.spec.js +114 -0
- package/dist/collection/components/stable/gux-button-multi/gux-button-multi.css +1 -1
- package/dist/collection/components/stable/gux-button-multi/gux-button-multi.js +8 -7
- package/dist/collection/components/stable/gux-button-multi/tests/gux-button-multi.e2e.js +69 -0
- package/dist/collection/components/stable/gux-button-multi/tests/gux-button-multi.spec.js +16 -0
- package/dist/collection/components/stable/gux-button-slot/gux-button-slot.css +9 -50
- package/dist/collection/components/stable/gux-button-slot/gux-button-slot.js +5 -4
- package/dist/collection/components/stable/gux-button-slot/tests/gux-button-slot.e2e.js +206 -0
- package/dist/collection/components/stable/gux-button-slot/tests/gux-button-slot.spec.js +258 -0
- package/dist/collection/components/stable/gux-calendar/gux-calendar.css +13 -13
- package/dist/collection/components/stable/gux-calendar/gux-calendar.js +23 -15
- package/dist/collection/components/stable/gux-calendar/gux-calendar.service.js +1 -1
- package/dist/collection/components/stable/gux-calendar/tests/gux-calendar.e2e.js +45 -0
- package/dist/collection/components/stable/gux-calendar/tests/gux-calendar.methods.spec.js +233 -0
- package/dist/collection/components/stable/gux-calendar/tests/gux-calendar.service.spec.js +160 -0
- package/dist/collection/components/stable/gux-calendar/tests/gux-calendar.spec.js +31 -0
- package/dist/collection/components/stable/gux-card/gux-card.js +4 -3
- package/dist/collection/components/stable/gux-card/tests/gux-card.e2e.js +16 -0
- package/dist/collection/components/stable/gux-card/tests/gux-card.spec.js +17 -0
- package/dist/collection/components/stable/gux-column-manager/gux-column-manager-item/gux-column-manager-item.css +1 -54
- package/dist/collection/components/stable/gux-column-manager/gux-column-manager-item/gux-column-manager-item.js +13 -9
- package/dist/collection/components/stable/gux-column-manager/gux-column-manager-item/tests/gux-column-manager-item.service.spec.js +35 -0
- package/dist/collection/components/stable/gux-column-manager/gux-column-manager.js +7 -6
- package/dist/collection/components/stable/gux-column-manager/gux-column-manager.service.js +2 -2
- package/dist/collection/components/stable/gux-content-search/gux-content-search.css +46 -91
- package/dist/collection/components/stable/gux-content-search/gux-content-search.js +8 -7
- package/dist/collection/components/stable/gux-content-search/tests/gux-content-search.e2e.js +542 -0
- package/dist/collection/components/stable/gux-content-search/tests/gux-content-search.spec.js +202 -0
- package/dist/collection/components/stable/gux-context-menu/gux-context-menu.css +2 -2
- package/dist/collection/components/stable/gux-context-menu/gux-context-menu.js +8 -8
- package/dist/collection/components/stable/gux-context-menu/tests/gux-context-menu.e2e.js +78 -0
- package/dist/collection/components/stable/gux-context-menu/tests/gux-context-menu.spec.js +44 -0
- package/dist/collection/components/stable/gux-copy-to-clipboard/gux-copy-to-clipboard.css +3 -3
- package/dist/collection/components/stable/gux-copy-to-clipboard/gux-copy-to-clipboard.js +6 -6
- package/dist/collection/components/stable/gux-copy-to-clipboard/tests/gux-copy-to-clipboard.e2e.js +23 -0
- package/dist/collection/components/stable/gux-copy-to-clipboard/tests/gux-copy-to-clipboard.spec.js +46 -0
- package/dist/collection/components/stable/gux-datepicker/gux-datepicker.css +3 -42
- package/dist/collection/components/stable/gux-datepicker/gux-datepicker.js +14 -12
- package/dist/collection/components/stable/gux-datepicker/tests/gux-datepicker.e2e.js +112 -0
- package/dist/collection/components/stable/gux-datepicker/tests/gux-datepicker.service.spec.js +237 -0
- package/dist/collection/components/stable/gux-datepicker/tests/gux-datepicker.spec.js +36 -0
- package/dist/collection/components/stable/gux-dismiss-button/gux-dismiss-button.css +5 -5
- package/dist/collection/components/stable/gux-dismiss-button/gux-dismiss-button.js +6 -5
- package/dist/collection/components/stable/gux-dismiss-button/tests/gux-dismiss-button.e2e.js +20 -0
- package/dist/collection/components/stable/gux-dismiss-button/tests/gux-dismiss-button.spec.js +22 -0
- package/dist/collection/components/stable/gux-dropdown/gux-dropdown.css +3 -3
- package/dist/collection/components/stable/gux-dropdown/gux-dropdown.js +13 -12
- package/dist/collection/components/stable/gux-dropdown/tests/gux-dropdown.e2e.js +190 -0
- package/dist/collection/components/stable/gux-dropdown/tests/gux-dropdown.spec.js +65 -0
- package/dist/collection/components/stable/gux-dropdown-multi/gux-dropdown-multi-tag/gux-dropdown-multi-tag.css +1 -42
- package/dist/collection/components/stable/gux-dropdown-multi/gux-dropdown-multi-tag/gux-dropdown-multi-tag.js +3 -3
- package/dist/collection/components/stable/gux-dropdown-multi/gux-dropdown-multi.css +5 -48
- package/dist/collection/components/stable/gux-dropdown-multi/gux-dropdown-multi.js +14 -12
- package/dist/collection/components/stable/gux-dropdown-multi/tests/gux-dropdown-multi.e2e.js +309 -0
- package/dist/collection/components/stable/gux-dropdown-multi/tests/gux-dropdown-multi.spec.js +24 -0
- package/dist/collection/components/stable/gux-flyout-menu/gux-flyout-menu.css +2 -43
- package/dist/collection/components/stable/gux-flyout-menu/gux-flyout-menu.js +5 -5
- package/dist/collection/components/stable/gux-flyout-menu/gux-menu/gux-menu-option/gux-menu-option.js +4 -3
- package/dist/collection/components/stable/gux-flyout-menu/gux-menu/gux-menu.js +1 -1
- package/dist/collection/components/stable/gux-flyout-menu/gux-menu/gux-submenu/gux-submenu.js +6 -5
- package/dist/collection/components/stable/gux-flyout-menu/tests/gux-flyout-menu.e2e.js +71 -0
- package/dist/collection/components/stable/gux-flyout-menu/tests/gux-flyout-menu.spec.js +52 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-checkbox/gux-form-field-checkbox.css +1 -2
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-checkbox/gux-form-field-checkbox.js +9 -9
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-checkbox/tests/gux-form-field-checkbox.e2e.js +93 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-checkbox/tests/gux-form-field-checkbox.spec.js +64 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-color/gux-form-field-color.css +4 -86
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-color/gux-form-field-color.js +12 -11
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-color/tests/gux-form-field-color.e2e.js +83 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-color/tests/gux-form-field-color.spec.js +65 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-dropdown/gux-form-field-dropdown.css +2 -45
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-dropdown/gux-form-field-dropdown.js +14 -13
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-dropdown/tests/gux-form-field-dropdown.e2e.js +196 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-dropdown/tests/gux-form-field-dropdown.spec.js +188 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-number/gux-form-field-number.css +5 -87
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-number/gux-form-field-number.js +18 -16
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-number/tests/gux-form-field-number.e2e.js +110 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-number/tests/gux-form-field-number.spec.js +85 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-phone/gux-form-field-phone.css +2 -45
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-phone/gux-form-field-phone.js +15 -14
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-radio/gux-form-field-radio.css +27 -16
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-radio/gux-form-field-radio.js +9 -9
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-radio/tests/gux-form-field-radio.e2e.js +101 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-radio/tests/gux-form-field-radio.spec.js +62 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-range/gux-form-field-range.css +16 -60
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-range/gux-form-field-range.js +12 -11
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-search/gux-form-field-search.css +6 -88
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-search/gux-form-field-search.js +14 -12
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-search/tests/gux-form-field-search.e2e.js +83 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-search/tests/gux-form-field-search.spec.js +65 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-select/gux-form-field-select.css +5 -48
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-select/gux-form-field-select.js +12 -11
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-select/tests/gux-form-field-select.e2e.js +95 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-select/tests/gux-form-field-select.spec.js +80 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-text-like/gux-form-field-text-like.css +9 -91
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-text-like/gux-form-field-text-like.js +14 -12
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-text-like/tests/gux-form-field-text-like.e2e.js +171 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-text-like/tests/gux-form-field-text-like.spec.js +125 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-textarea/gux-form-field-textarea.css +5 -87
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-textarea/gux-form-field-textarea.js +14 -12
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-textarea/tests/gux-form-field-textarea.e2e.js +104 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-textarea/tests/gux-form-field-textarea.spec.js +79 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-time-picker/gux-form-field-time-picker.css +2 -45
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-time-picker/gux-form-field-time-picker.js +12 -11
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-time-picker/tests/gux-form-field-time-picker.e2e.js +83 -0
- package/dist/collection/components/stable/gux-form-field/components/gux-form-field-time-picker/tests/gux-form-field-time-picker.spec.js +66 -0
- package/dist/collection/components/stable/gux-form-field/functional-components/functional-components.js +6 -6
- package/dist/collection/components/stable/gux-form-field/functional-components/gux-form-field-container/gux-form-field-container.js +1 -1
- package/dist/collection/components/stable/gux-form-field/functional-components/gux-form-field-error/gux-form-field-error.js +1 -1
- package/dist/collection/components/stable/gux-form-field/functional-components/gux-form-field-fieldset-container/gux-form-field-fieldset-container.js +1 -1
- package/dist/collection/components/stable/gux-form-field/functional-components/gux-form-field-help/gux-form-field-help.js +1 -1
- package/dist/collection/components/stable/gux-form-field/functional-components/gux-form-field-label/gux-form-field-label.js +1 -1
- package/dist/collection/components/stable/gux-form-field/functional-components/gux-form-field-legend-label/gux-form-field-legend-label.js +1 -1
- package/dist/collection/components/stable/gux-form-field/gux-form-field.service.js +4 -4
- package/dist/collection/components/stable/gux-form-field/helper-components/gux-form-field-input-clear-button/gux-form-field-input-clear-button.css +1 -40
- package/dist/collection/components/stable/gux-form-field/helper-components/gux-form-field-input-clear-button/gux-form-field-input-clear-button.js +4 -4
- package/dist/collection/components/stable/gux-form-field/tests/gux-form-field.service.spec.js +19 -0
- package/dist/collection/components/stable/gux-icon/gux-icon.js +7 -6
- package/dist/collection/components/stable/gux-icon/gux-icon.service.js +1 -1
- package/dist/collection/components/stable/gux-icon/icons/custom/face-smile-hearts-regular.svg +1 -0
- package/dist/collection/components/stable/gux-icon/tests/gux-icon.e2e.js +11 -0
- package/dist/collection/components/stable/gux-icon/tests/gux-icon.service.spec.js +22 -0
- package/dist/collection/components/stable/gux-icon/tests/gux-icon.spec.js +6 -0
- 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-divider/tests/gux-list-divider.spec.js +22 -0
- package/dist/collection/components/stable/gux-list/gux-list-item/gux-list-item.css +9 -9
- package/dist/collection/components/stable/gux-list/gux-list-item/gux-list-item.js +2 -2
- package/dist/collection/components/stable/gux-list/gux-list-item/tests/gux-list-item.spec.js +22 -0
- package/dist/collection/components/stable/gux-list/gux-list.js +11 -7
- package/dist/collection/components/stable/gux-list/tests/gux-list.e2e.js +20 -0
- package/dist/collection/components/stable/gux-list/tests/gux-list.spec.js +23 -0
- package/dist/collection/components/stable/gux-listbox/gux-listbox.css +2 -2
- package/dist/collection/components/stable/gux-listbox/gux-listbox.js +12 -10
- package/dist/collection/components/stable/gux-listbox/options/gux-option/gux-option.css +7 -7
- package/dist/collection/components/stable/gux-listbox/options/gux-option/gux-option.js +2 -2
- package/dist/collection/components/stable/gux-listbox/options/gux-option-icon/gux-option-icon.css +7 -7
- package/dist/collection/components/stable/gux-listbox/options/gux-option-icon/gux-option-icon.js +2 -2
- package/dist/collection/components/stable/gux-listbox-multi/gux-create-option/gux-create-option.css +8 -8
- package/dist/collection/components/stable/gux-listbox-multi/gux-create-option/gux-create-option.js +6 -5
- package/dist/collection/components/stable/gux-listbox-multi/gux-listbox-multi.css +1 -1
- package/dist/collection/components/stable/gux-listbox-multi/gux-listbox-multi.js +12 -10
- package/dist/collection/components/stable/gux-listbox-multi/gux-option-multi/gux-option-multi.css +4 -4
- package/dist/collection/components/stable/gux-listbox-multi/gux-option-multi/gux-option-multi.js +4 -4
- package/dist/collection/components/stable/gux-loading-message/gux-loading-message.css +6 -6
- package/dist/collection/components/stable/gux-loading-message/gux-loading-message.js +2 -2
- package/dist/collection/components/stable/gux-loading-message/tests/gux-loading-message.e2e.js +14 -0
- package/dist/collection/components/stable/gux-loading-message/tests/gux-loading-message.spec.js +27 -0
- package/dist/collection/components/stable/gux-modal/gux-modal.css +14 -57
- package/dist/collection/components/stable/gux-modal/gux-modal.js +5 -4
- package/dist/collection/components/stable/gux-modal/tests/gux-modal.e2e.js +300 -0
- package/dist/collection/components/stable/gux-modal/tests/gux-modal.spec.js +200 -0
- package/dist/collection/components/stable/gux-page-loading-spinner/gux-page-loading-spinner.js +2 -2
- package/dist/collection/components/stable/gux-page-loading-spinner/tests/gux-page-loading-spinner.e2e.js +33 -0
- package/dist/collection/components/stable/gux-page-loading-spinner/tests/gux-page-loading-spinner.spec.js +12 -0
- package/dist/collection/components/stable/gux-pagination/gux-pagination-buttons/gux-pagination-buttons.css +8 -8
- package/dist/collection/components/stable/gux-pagination/gux-pagination-buttons/gux-pagination-buttons.js +7 -6
- package/dist/collection/components/stable/gux-pagination/gux-pagination-buttons/gux-pagination-ellipsis-button/gux-pagination-ellipsis-button.css +1 -1
- package/dist/collection/components/stable/gux-pagination/gux-pagination-buttons/gux-pagination-ellipsis-button/gux-pagination-ellipsis-button.js +6 -6
- package/dist/collection/components/stable/gux-pagination/gux-pagination-buttons/tests/gux-pagination-buttons.service.spec.js +129 -0
- package/dist/collection/components/stable/gux-pagination/gux-pagination-buttons/tests/gux-pagination-buttons.spec.js +32 -0
- package/dist/collection/components/stable/gux-pagination/gux-pagination-item-counts/gux-pagination-item-counts.css +3 -3
- package/dist/collection/components/stable/gux-pagination/gux-pagination-item-counts/gux-pagination-item-counts.js +3 -3
- package/dist/collection/components/stable/gux-pagination/gux-pagination-item-counts/tests/gux-pagination-item-counts.spec.js +30 -0
- package/dist/collection/components/stable/gux-pagination/gux-pagination-items-per-page/gux-pagination-items-per-page.css +3 -3
- package/dist/collection/components/stable/gux-pagination/gux-pagination-items-per-page/gux-pagination-items-per-page.js +5 -4
- package/dist/collection/components/stable/gux-pagination/gux-pagination-items-per-page/tests/gux-pagination-items-per-page.spec.js +37 -0
- package/dist/collection/components/stable/gux-pagination/gux-pagination.css +1 -1
- package/dist/collection/components/stable/gux-pagination/gux-pagination.js +9 -6
- package/dist/collection/components/stable/gux-pagination/tests/gux-pagination.e2e.js +97 -0
- package/dist/collection/components/stable/gux-pagination/tests/gux-pagination.spec.js +116 -0
- package/dist/collection/components/stable/gux-pagination-cursor/gux-pagination-cursor.css +6 -6
- package/dist/collection/components/stable/gux-pagination-cursor/gux-pagination-cursor.js +8 -6
- package/dist/collection/components/stable/gux-pagination-cursor/tests/gux-pagination-cursor.e2e.js +66 -0
- package/dist/collection/components/stable/gux-pagination-cursor/tests/gux-pagination-cursor.spec.js +67 -0
- package/dist/collection/components/stable/gux-popover/gux-popover.css +6 -6
- package/dist/collection/components/stable/gux-popover/gux-popover.js +8 -7
- package/dist/collection/components/stable/gux-popover/tests/gux-popover.e2e.js +60 -0
- package/dist/collection/components/stable/gux-popover/tests/gux-popover.spec.js +54 -0
- package/dist/collection/components/stable/gux-popover-list/gux-popover-list.css +1 -1
- package/dist/collection/components/stable/gux-popover-list/gux-popover-list.js +7 -6
- package/dist/collection/components/stable/gux-popover-list/tests/gux-popover-list.e2e.js +59 -0
- package/dist/collection/components/stable/gux-popover-list/tests/gux-popover-list.spec.js +53 -0
- package/dist/collection/components/stable/gux-popup/gux-popup.css +1 -1
- package/dist/collection/components/stable/gux-popup/gux-popup.js +2 -2
- package/dist/collection/components/stable/gux-popup/tests/gux-popup.e2e.js +29 -0
- package/dist/collection/components/stable/gux-popup/tests/gux-popup.spec.js +41 -0
- package/dist/collection/components/stable/gux-radial-loading/gux-radial-loading.css +31 -31
- package/dist/collection/components/stable/gux-radial-loading/gux-radial-loading.functional.js +2 -2
- package/dist/collection/components/stable/gux-radial-loading/gux-radial-loading.js +7 -6
- package/dist/collection/components/stable/gux-radial-loading/tests/gux-radial-loading.e2e.js +33 -0
- package/dist/collection/components/stable/gux-radial-loading/tests/gux-radial-loading.spec.js +33 -0
- package/dist/collection/components/stable/gux-radial-progress/gux-radial-progress.css +3 -3
- package/dist/collection/components/stable/gux-radial-progress/gux-radial-progress.functional.js +2 -2
- package/dist/collection/components/stable/gux-radial-progress/gux-radial-progress.js +5 -5
- package/dist/collection/components/stable/gux-radial-progress/tests/gux-radial-progress.e2e.js +58 -0
- package/dist/collection/components/stable/gux-radial-progress/tests/gux-radial-progress.service.spec.js +36 -0
- package/dist/collection/components/stable/gux-radial-progress/tests/gux-radial-progress.spec.js +61 -0
- package/dist/collection/components/stable/gux-rating/gux-rating.css +2 -2
- package/dist/collection/components/stable/gux-rating/gux-rating.js +5 -5
- package/dist/collection/components/stable/gux-rating/tests/gux-rating.e2e.js +208 -0
- package/dist/collection/components/stable/gux-rating/tests/gux-rating.spec.js +40 -0
- 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-skip-navigation-list/gux-skip-navigation-list.js +4 -4
- package/dist/collection/components/stable/gux-skip-navigation-list/tests/gux-skip-navigation-list.e2e.js +24 -0
- package/dist/collection/components/stable/gux-skip-navigation-list/tests/gux-skip-navigation-list.spec.js +29 -0
- package/dist/collection/components/stable/gux-table/gux-all-row-select/gux-all-row-select.js +6 -5
- package/dist/collection/components/stable/gux-table/gux-all-row-select/tests/gux-all-row-select.spec.js +11 -0
- package/dist/collection/components/stable/gux-table/gux-row-select/gux-row-select.js +4 -4
- package/dist/collection/components/stable/gux-table/gux-row-select/tests/gux-row-select.spec.js +11 -0
- package/dist/collection/components/stable/gux-table/gux-sort-control/gux-sort-control.css +1 -1
- package/dist/collection/components/stable/gux-table/gux-sort-control/gux-sort-control.js +8 -7
- package/dist/collection/components/stable/gux-table/gux-sort-control/tests/gux-sort-control.e2e.js +56 -0
- package/dist/collection/components/stable/gux-table/gux-sort-control/tests/gux-sort-control.spec.js +48 -0
- package/dist/collection/components/stable/gux-table/gux-table-select-menu/gux-table-select-menu.css +3 -42
- package/dist/collection/components/stable/gux-table/gux-table-select-menu/gux-table-select-menu.js +6 -6
- package/dist/collection/components/stable/gux-table/gux-table-select-menu/gux-table-select-popover/gux-table-header-popover.js +4 -4
- package/dist/collection/components/stable/gux-table/gux-table-select-menu/tests/gux-table-select-menu.spec.js +24 -0
- package/dist/collection/components/stable/gux-table/gux-table.css +1 -44
- package/dist/collection/components/stable/gux-table/gux-table.js +14 -10
- package/dist/collection/components/stable/gux-table/tests/gux-table.e2e.js +540 -0
- package/dist/collection/components/stable/gux-table/tests/gux-table.spec.js +32 -0
- package/dist/collection/components/stable/gux-table-toolbar/gux-table-toolbar-action/gux-table-toolbar-action.js +9 -7
- package/dist/collection/components/stable/gux-table-toolbar/gux-table-toolbar-action/tests/gux-table-toolbar-action.e2e.js +53 -0
- package/dist/collection/components/stable/gux-table-toolbar/gux-table-toolbar-action/tests/gux-table-toolbar-action.spec.js +54 -0
- package/dist/collection/components/stable/gux-table-toolbar/gux-table-toolbar-custom-action/gux-table-toolbar-custom-action.js +5 -4
- package/dist/collection/components/stable/gux-table-toolbar/gux-table-toolbar-custom-action/tests/gux-table-toolbar-custom-action.e2e.js +33 -0
- package/dist/collection/components/stable/gux-table-toolbar/gux-table-toolbar-custom-action/tests/gux-table-toolbar-custom-action.spec.js +34 -0
- package/dist/collection/components/stable/gux-table-toolbar/gux-table-toolbar-menu-button/gux-table-toolbar-menu-button.js +6 -6
- package/dist/collection/components/stable/gux-table-toolbar/gux-table-toolbar.js +7 -7
- package/dist/collection/components/stable/gux-table-toolbar/tests/gux-table-toolbar.e2e.js +46 -0
- package/dist/collection/components/stable/gux-table-toolbar/tests/gux-table-toolbar.spec.js +63 -0
- package/dist/collection/components/stable/gux-tabs/gux-tab/gux-tab.js +7 -4
- package/dist/collection/components/stable/gux-tabs/gux-tab/tests/gux-tab.e2e.js +15 -0
- package/dist/collection/components/stable/gux-tabs/gux-tab/tests/gux-tab.spec.js +16 -0
- package/dist/collection/components/stable/gux-tabs/gux-tab-list/gux-tab-list.css +0 -1
- package/dist/collection/components/stable/gux-tabs/gux-tab-list/gux-tab-list.js +7 -6
- package/dist/collection/components/stable/gux-tabs/gux-tab-list/tests/gux-tab-list.e2e.js +15 -0
- package/dist/collection/components/stable/gux-tabs/gux-tab-list/tests/gux-tab-list.spec.js +16 -0
- package/dist/collection/components/stable/gux-tabs/gux-tab-panel/gux-tab-panel.css +1 -42
- package/dist/collection/components/stable/gux-tabs/gux-tab-panel/gux-tab-panel.js +3 -2
- package/dist/collection/components/stable/gux-tabs/gux-tab-panel/tests/gux-tab-panel.e2e.js +15 -0
- package/dist/collection/components/stable/gux-tabs/gux-tab-panel/tests/gux-tab-panel.spec.js +16 -0
- package/dist/collection/components/stable/gux-tabs/gux-tabs.js +8 -5
- package/dist/collection/components/stable/gux-tabs/tests/gux-tabs.e2e.js +141 -0
- package/dist/collection/components/stable/gux-tabs/tests/gux-tabs.spec.js +57 -0
- package/dist/collection/components/stable/gux-tabs-advanced/gux-tab-advanced/gux-tab-advanced.js +12 -9
- package/dist/collection/components/stable/gux-tabs-advanced/gux-tab-advanced-list/gux-tab-advanced-list.css +1 -85
- package/dist/collection/components/stable/gux-tabs-advanced/gux-tab-advanced-list/gux-tab-advanced-list.js +9 -8
- package/dist/collection/components/stable/gux-tabs-advanced/gux-tab-advanced-panel/gux-tab-advanced-panel.css +1 -42
- package/dist/collection/components/stable/gux-tabs-advanced/gux-tab-advanced-panel/gux-tab-advanced-panel.js +3 -2
- package/dist/collection/components/stable/gux-tabs-advanced/gux-tabs-advanced.js +4 -3
- package/dist/collection/components/stable/gux-tabs-advanced/tests/gux-tabs-advanced.e2e.js +217 -0
- package/dist/collection/components/stable/gux-tabs-advanced/tests/gux-tabs-advanced.spec.js +73 -0
- package/dist/collection/components/stable/gux-tag/gux-tag.css +22 -25
- package/dist/collection/components/stable/gux-tag/gux-tag.js +6 -5
- package/dist/collection/components/stable/gux-tag/tests/gux-tag.e2e.js +135 -0
- package/dist/collection/components/stable/gux-tag/tests/gux-tag.spec.js +130 -0
- package/dist/collection/components/stable/gux-text-highlight/gux-text-highlight.js +5 -4
- package/dist/collection/components/stable/gux-text-highlight/tests/gux-text-highlight.e2e.js +147 -0
- package/dist/collection/components/stable/gux-text-highlight/tests/gux-text-hightlight.spec.js +149 -0
- package/dist/collection/components/stable/gux-time-picker/gux-time-picker.css +7 -7
- package/dist/collection/components/stable/gux-time-picker/gux-time-picker.js +16 -12
- package/dist/collection/components/stable/gux-time-picker/gux-time-picker.service.js +1 -1
- package/dist/collection/components/stable/gux-time-picker/tests/gux-time-picker.e2e.js +41 -0
- package/dist/collection/components/stable/gux-time-picker/tests/gux-time-picker.service.spec.js +698 -0
- package/dist/collection/components/stable/gux-time-picker/tests/gux-time-picker.spec.js +14 -0
- package/dist/collection/components/stable/gux-toast/gux-toast.css +5 -5
- package/dist/collection/components/stable/gux-toast/gux-toast.js +5 -4
- package/dist/collection/components/stable/gux-toast/tests/gux-toast.e2e.js +121 -0
- package/dist/collection/components/stable/gux-toast/tests/gux-toast.spec.js +111 -0
- package/dist/collection/components/stable/gux-toggle/gux-toggle-slider/gux-toggle-slider.css +1 -42
- 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.js +7 -6
- package/dist/collection/components/stable/gux-toggle/tests/gux-toggle.e2e.js +147 -0
- package/dist/collection/components/stable/gux-toggle/tests/gux-toggle.spec.js +126 -0
- package/dist/collection/components/stable/gux-tooltip/gux-tooltip.css +12 -12
- package/dist/collection/components/stable/gux-tooltip/gux-tooltip.js +14 -10
- package/dist/collection/components/stable/gux-tooltip/tests/gux-tooltip.e2e.js +33 -0
- package/dist/collection/components/stable/gux-tooltip/tests/gux-tooltip.spec.js +55 -0
- package/dist/collection/components/stable/gux-tooltip-title/gux-tooltip-title.js +8 -6
- package/dist/collection/components/stable/gux-truncate/gux-truncate.js +8 -6
- package/dist/collection/components/stable/gux-truncate/tests/gux-truncate.e2e.js +32 -0
- package/dist/collection/components/stable/gux-truncate/tests/gux-truncate.spec.js +27 -0
- package/dist/collection/i18n/DateTimeFormatter.js +1 -1
- package/dist/collection/i18n/fetchResources.js +1 -1
- package/dist/collection/i18n/index.js +5 -5
- package/dist/collection/test/e2eTestUtils.js +2 -2
- package/dist/collection/test/specTestUtils.js +8 -0
- package/dist/collection/utils/date/from-iso-time-string.spec.js +13 -0
- package/dist/collection/utils/date/get-valid-timezone.js +1 -1
- package/dist/collection/utils/date/get-valid-timezone.spec.js +38 -0
- package/dist/collection/utils/date/iso-dates.spec.js +170 -0
- package/dist/collection/utils/date/year-month-values.spec.js +81 -0
- package/dist/collection/utils/decorator/on-click-outside.js +1 -1
- package/dist/collection/utils/decorator/on-mutation.js +1 -1
- package/dist/collection/utils/decorator/on-resize.js +1 -1
- package/dist/collection/utils/dom/event-is-from.spec.js +29 -0
- package/dist/collection/utils/dom/manipulate-elements-classes.spec.js +104 -0
- package/dist/collection/utils/dom/on-input-disabled-state-change.js +1 -1
- package/dist/collection/utils/dom/random-html-id.spec.js +14 -0
- package/dist/collection/utils/dom/set-input-value.js +1 -1
- package/dist/collection/utils/dom/when-event-is-from.spec.js +37 -0
- package/dist/collection/utils/string/search.spec.js +40 -0
- package/dist/collection/utils/tracking/usage.js +1 -1
- package/dist/collection/utils/tracking/usage.spec.js +121 -0
- package/dist/component-specs.json +10 -0
- package/dist/deploy-info.json +3 -3
- package/dist/esm/en-bf740e9b.js +22 -0
- package/dist/esm/genesys-webcomponents.js +4 -7
- package/dist/esm/{get-valid-timezone-4b39f118.js → get-valid-timezone-3781bfa2.js} +1 -1
- package/dist/esm/gux-accordion-section.entry.js +4 -4
- package/dist/esm/gux-accordion.entry.js +2 -2
- package/dist/esm/gux-action-button.entry.js +8 -8
- package/dist/esm/gux-action-toast-legacy.entry.js +3 -3
- package/dist/esm/gux-advanced-dropdown-legacy.entry.js +8 -8
- package/dist/esm/gux-all-row-select.entry.js +5 -5
- package/dist/esm/gux-announce-beta.entry.js +3 -3
- package/dist/esm/gux-badge.entry.js +5 -5
- package/dist/esm/gux-blank-state.entry.js +3 -3
- package/dist/esm/gux-breadcrumb-item.entry.js +3 -3
- package/dist/esm/gux-breadcrumbs.entry.js +5 -5
- package/dist/esm/gux-button-multi.entry.js +6 -6
- package/dist/esm/gux-button-slot.entry.js +4 -4
- package/dist/esm/gux-button.entry.js +3 -3
- package/dist/esm/gux-calendar-beta.entry.js +9 -9
- package/dist/esm/gux-calendar.entry.js +8 -8
- package/dist/esm/gux-card.entry.js +2 -2
- package/dist/esm/gux-column-manager-item.entry.js +7 -7
- package/dist/esm/gux-column-manager.entry.js +7 -7
- package/dist/esm/{gux-column-manager.service-a9ea5c54.js → gux-column-manager.service-4f5bf4c4.js} +2 -2
- package/dist/esm/gux-content-search.entry.js +7 -7
- package/dist/esm/gux-context-menu.entry.js +9 -9
- package/dist/esm/gux-copy-to-clipboard.entry.js +7 -7
- package/dist/esm/gux-create-option.entry.js +5 -5
- package/dist/esm/gux-date-beta.entry.js +5 -5
- package/dist/esm/gux-date-time-beta.entry.js +5 -5
- package/dist/esm/gux-datepicker.entry.js +10 -10
- package/dist/esm/gux-disclosure-button-legacy.entry.js +5 -5
- package/dist/esm/gux-dismiss-button.entry.js +5 -5
- package/dist/esm/gux-dropdown-multi-tag.entry.js +4 -4
- package/dist/esm/gux-dropdown-multi.entry.js +11 -11
- package/dist/esm/gux-dropdown-option.entry.js +1 -1
- package/dist/esm/gux-dropdown_3.entry.js +15 -15
- package/dist/esm/gux-flyout-menu.entry.js +5 -5
- package/dist/esm/gux-form-field-checkbox.entry.js +10 -10
- package/dist/esm/gux-form-field-color.entry.js +13 -13
- package/dist/esm/{gux-form-field-container-0d93fc18.js → gux-form-field-container-0628b63c.js} +1 -1
- package/dist/esm/gux-form-field-dropdown.entry.js +15 -15
- package/dist/esm/{gux-form-field-fieldset-container-02a0becc.js → gux-form-field-fieldset-container-863690e1.js} +1 -1
- package/dist/esm/gux-form-field-input-clear-button.entry.js +5 -5
- package/dist/esm/gux-form-field-number_3.entry.js +23 -23
- package/dist/esm/gux-form-field-phone.entry.js +14 -14
- package/dist/esm/gux-form-field-radio.entry.js +11 -11
- package/dist/esm/gux-form-field-range.entry.js +13 -13
- package/dist/esm/gux-form-field-search.entry.js +13 -13
- package/dist/esm/gux-form-field-select.entry.js +13 -13
- package/dist/esm/gux-form-field-text-like.entry.js +13 -13
- package/dist/esm/gux-form-field-textarea.entry.js +13 -13
- package/dist/esm/gux-form-field-time-picker.entry.js +14 -14
- package/dist/esm/{gux-form-field.service-5f03e905.js → gux-form-field.service-1b918b11.js} +5 -5
- package/dist/esm/gux-icon.entry.js +3 -3
- package/dist/esm/gux-inline-alert.entry.js +5 -5
- package/dist/esm/gux-list-divider.entry.js +1 -1
- package/dist/esm/gux-list-item.entry.js +3 -3
- package/dist/esm/gux-list.entry.js +3 -3
- package/dist/esm/gux-listbox-multi.entry.js +9 -9
- package/dist/esm/gux-loading-message.entry.js +3 -3
- package/dist/esm/gux-menu-option.entry.js +2 -2
- package/dist/esm/gux-menu.entry.js +1 -1
- package/dist/esm/gux-modal.entry.js +4 -4
- package/dist/esm/gux-month-calendar.entry.js +7 -7
- package/dist/esm/gux-month-list_2.entry.js +4 -4
- package/dist/esm/gux-month-picker-beta.entry.js +9 -9
- package/dist/esm/gux-notification-toast-legacy.entry.js +3 -3
- package/dist/esm/gux-option-icon.entry.js +3 -3
- package/dist/esm/gux-option-multi.entry.js +5 -5
- package/dist/esm/gux-page-loading-spinner.entry.js +2 -2
- package/dist/esm/gux-pagination-buttons-legacy_3.entry.js +6 -6
- package/dist/esm/gux-pagination-buttons_3.entry.js +8 -8
- package/dist/esm/gux-pagination-cursor.entry.js +5 -5
- package/dist/esm/gux-pagination-legacy.entry.js +3 -3
- package/dist/esm/gux-pagination.entry.js +4 -4
- package/dist/esm/gux-phone-input-beta.entry.js +8 -8
- package/dist/esm/gux-popover-list.entry.js +6 -6
- package/dist/esm/gux-popup.entry.js +3 -3
- package/dist/esm/gux-radial-loading.entry.js +5 -5
- package/dist/esm/gux-radial-progress.entry.js +4 -4
- package/dist/esm/gux-rating.entry.js +6 -6
- package/dist/esm/gux-region-icon.entry.js +2 -2
- package/dist/esm/gux-row-select.entry.js +5 -5
- package/dist/esm/gux-screen-reader-beta.entry.js +2 -2
- package/dist/esm/gux-segmented-control-beta.entry.js +3 -3
- package/dist/esm/gux-segmented-control-item.entry.js +5 -5
- package/dist/esm/gux-simple-toast-legacy.entry.js +2 -2
- package/dist/esm/gux-skip-navigation-item.entry.js +1 -1
- package/dist/esm/gux-skip-navigation-list.entry.js +4 -4
- package/dist/esm/gux-sort-control.entry.js +7 -7
- package/dist/esm/gux-submenu.entry.js +4 -4
- package/dist/esm/gux-switch-item.entry.js +2 -2
- package/dist/esm/gux-switch-legacy.entry.js +3 -3
- package/dist/esm/gux-tab-advanced-legacy.entry.js +153 -0
- package/dist/esm/gux-tab-advanced-list-legacy.entry.js +466 -0
- package/dist/esm/gux-tab-advanced-list.entry.js +10 -3029
- package/dist/esm/gux-tab-advanced-panel-legacy.entry.js +30 -0
- package/dist/esm/gux-tab-advanced-panel.entry.js +2 -2
- package/dist/esm/gux-tab-advanced.entry.js +7 -7
- package/dist/esm/gux-tab-list.entry.js +6 -6
- package/dist/esm/gux-tab-panel.entry.js +2 -2
- package/dist/esm/gux-tab.entry.js +1 -1
- package/dist/esm/gux-table-select-menu.entry.js +8 -8
- package/dist/esm/gux-table-select-popover.entry.js +3 -3
- package/dist/esm/gux-table-toolbar-action.entry.js +5 -5
- package/dist/esm/gux-table-toolbar-custom-action.entry.js +3 -3
- package/dist/esm/gux-table-toolbar-menu-button.entry.js +6 -6
- package/dist/esm/gux-table-toolbar.entry.js +5 -5
- package/dist/esm/gux-table.entry.js +8 -8
- package/dist/esm/gux-tabs-advanced-legacy.entry.js +59 -0
- package/dist/esm/gux-tabs-advanced.entry.js +2 -2
- package/dist/esm/gux-tabs.entry.js +2 -2
- package/dist/esm/gux-tag.entry.js +5 -5
- package/dist/esm/gux-text-highlight.entry.js +2 -2
- package/dist/esm/gux-time-beta.entry.js +5 -5
- package/dist/esm/gux-time-picker.entry.js +8 -8
- package/dist/esm/gux-time-zone-picker-beta.entry.js +5 -5
- package/dist/esm/gux-toast.entry.js +4 -4
- package/dist/esm/gux-toggle-slider.entry.js +2 -2
- package/dist/esm/gux-toggle.entry.js +5 -5
- package/dist/esm/gux-tooltip-title.entry.js +4 -4
- package/dist/esm/gux-tooltip.entry.js +7 -7
- package/dist/esm/gux-truncate.entry.js +3 -3
- package/dist/esm/{index-0b66fe2c.js → index-a0eec33a.js} +175 -43
- package/dist/esm/{index-694d55cf.js → index-e5ccc024.js} +2 -2
- package/dist/esm/loader.js +4 -13
- package/dist/esm/{on-click-outside-bc432a79.js → on-click-outside-e696f632.js} +1 -1
- package/dist/esm/{on-mutation-8c8b2331.js → on-mutation-c1be3c74.js} +1 -1
- package/dist/esm/{on-resize-7177429a.js → on-resize-c9e31879.js} +1 -1
- package/dist/esm/sortable.esm-8c3d5856.js +3021 -0
- package/dist/esm/{usage-7c4316f3.js → usage-b9bc2c35.js} +5 -5
- 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/icons/custom/face-smile-hearts-regular.svg +1 -0
- package/dist/genesys-webcomponents/{p-4a0aae21.entry.js → p-001a4f6c.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-94465268.entry.js → p-004bad0d.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-535d0527.entry.js → p-0209a2e8.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-c5cc4499.entry.js → p-04882cf9.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-27b2e8f1.entry.js → p-050b14b0.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-05102bf4.entry.js +1 -0
- package/dist/genesys-webcomponents/p-06186f07.entry.js +1 -0
- package/dist/genesys-webcomponents/p-0a7237d9.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-8e9bfb5c.entry.js → p-0e1a0eef.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-0f57803f.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-793c5d4b.entry.js → p-0fd727e4.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-9b6ed146.entry.js → p-11a4917d.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-121117b7.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-2ac7ec81.entry.js → p-127514f4.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-8ebb78f7.entry.js → p-13bd1ddb.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-1486d7ea.js +7 -0
- package/dist/genesys-webcomponents/{p-c985b725.entry.js → p-15e52200.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-1b04a4a3.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-81577261.entry.js → p-1c00c8b9.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-8b3bf42a.entry.js → p-25d372af.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-29e65ca5.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-afc8f510.entry.js → p-2a3350f2.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-0b31e700.entry.js → p-3006f950.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-32a36f06.entry.js +1 -0
- package/dist/genesys-webcomponents/p-35fff0fe.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-a0926d37.entry.js → p-3669d1d6.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-377f63a0.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-c686d5f6.entry.js → p-38c797a5.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-045a5c8d.entry.js → p-3b48aaaa.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-13dd4c6b.js → p-3d745319.js} +1 -1
- package/dist/genesys-webcomponents/p-3deec8d5.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-c3d5a975.entry.js → p-3fe16f20.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-7c826e42.entry.js → p-4338a137.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-4426b584.entry.js +1 -0
- package/dist/genesys-webcomponents/p-457dce75.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-d588f252.entry.js → p-48d465fe.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-6bff9eb3.entry.js → p-4a579180.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-804cc43e.entry.js → p-4d14a590.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-4dc4930c.entry.js +1 -0
- package/dist/genesys-webcomponents/p-511eb62e.entry.js +1 -0
- package/dist/genesys-webcomponents/p-51df1ede.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-deee079e.js → p-52e27c60.js} +1 -1
- package/dist/genesys-webcomponents/p-541c3c6b.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-1fd76470.entry.js → p-5463e134.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-06a92400.entry.js → p-550c0768.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-a06023b3.entry.js → p-5524298d.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-5844e8c2.js +1 -0
- package/dist/genesys-webcomponents/{p-380d663e.entry.js → p-59206607.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-832842b0.entry.js → p-5a9d8cb2.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-5d15381f.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-632695ad.entry.js → p-5ea0d07e.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-6a08f78f.entry.js → p-644b750b.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-66290fc5.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-8fe30b09.entry.js → p-67036f76.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-69d045af.entry.js +1 -0
- package/dist/genesys-webcomponents/p-6bee8d41.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-16570da1.entry.js → p-6c72ef03.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-6ce1bf55.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-0bc7c69c.entry.js → p-6d7122bc.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-77db656b.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-800521cd.entry.js → p-7943f46d.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-8920a5e5.js → p-7a100b8c.js} +1 -1
- package/dist/genesys-webcomponents/{p-5e1a9a03.entry.js → p-7bff5f15.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-44835bc5.entry.js → p-7e22896f.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-35f055a2.entry.js → p-7e245e45.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-f34ce7dc.js → p-8801741a.js} +1 -1
- package/dist/genesys-webcomponents/{p-4425a015.entry.js → p-8953cea0.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-9d18d475.js → p-8c362857.js} +1 -1
- package/dist/genesys-webcomponents/p-8c3c2fd5.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-dabf28c2.entry.js → p-8d3fb4b0.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-8e22729c.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-bcf1af79.entry.js → p-9026cf7e.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-903a7fff.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-5675738b.entry.js → p-906bffcd.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-920b9a0d.entry.js +1 -0
- package/dist/genesys-webcomponents/p-92536df7.entry.js +1 -0
- package/dist/genesys-webcomponents/p-9279fb28.entry.js +1 -0
- package/dist/genesys-webcomponents/p-932fdd60.entry.js +1 -0
- package/dist/genesys-webcomponents/p-937ec398.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-a733f4ca.js → p-9383fa8e.js} +1 -1
- package/dist/genesys-webcomponents/{p-d01970f7.entry.js → p-93d5c18d.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-c9ad308d.entry.js → p-9595c4f2.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-b9ed5a20.entry.js → p-984fb2ca.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-831456f4.entry.js → p-9894c33e.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-992542c8.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-18099796.entry.js → p-993b63db.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-9cc0c717.entry.js +1 -0
- package/dist/genesys-webcomponents/p-a1151219.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-4a6ae41e.js → p-a285abaf.js} +1 -1
- package/dist/genesys-webcomponents/{p-b3c9fd06.js → p-a3bc3236.js} +1 -1
- package/dist/genesys-webcomponents/p-a934d5b1.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-334e3b2c.entry.js → p-a96bc06c.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-d3a38337.entry.js → p-b09ed8fd.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-3978c9d9.entry.js → p-b0cc1af2.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-a9b8c730.entry.js → p-b3fd4623.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-b56fd34a.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-39e12286.entry.js → p-b80c59ad.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-bc151fdb.entry.js +1 -0
- package/dist/genesys-webcomponents/p-be68b1e8.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-d8824819.entry.js → p-c05cacb2.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-efafcf0b.entry.js → p-c07ab095.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-9be45fa0.entry.js → p-c183e212.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-c4a77eda.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-c609ed18.entry.js → p-c4f9d3c7.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-24b860b0.js → p-c57cd1d8.js} +1 -1
- package/dist/genesys-webcomponents/p-c7a90b16.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-7a24829d.entry.js → p-c9788b0b.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-cf094b0a.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-c564f3cc.entry.js → p-d0aefa7e.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-d25d679d.entry.js +1 -0
- package/dist/genesys-webcomponents/p-d5d7cf8d.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-21ef475f.entry.js → p-d8e0caa9.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-e9be8807.entry.js → p-d96bce57.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-d24bbafd.entry.js → p-ddfc136f.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-5229c638.entry.js → p-e121f417.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-642b29b5.entry.js → p-e2d75be4.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-c94a287d.entry.js → p-e653b8d2.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-559fd965.entry.js → p-ea777be1.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-ed724d66.js +2 -0
- package/dist/genesys-webcomponents/{p-20e7c016.entry.js → p-edf8e30c.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-ee2ab42a.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-5b0d2d81.entry.js → p-ee662eda.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-b74733e2.entry.js → p-f19e1b38.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-83f26f44.entry.js → p-f34da37c.entry.js} +1 -1
- package/dist/genesys-webcomponents/p-f6bcc7b4.entry.js +1 -0
- package/dist/genesys-webcomponents/p-f7c491f0.entry.js +1 -0
- package/dist/genesys-webcomponents/p-f86080b6.entry.js +1 -0
- package/dist/genesys-webcomponents/{p-30e902fc.entry.js → p-fb9b79ce.entry.js} +1 -1
- package/dist/genesys-webcomponents/{p-211cc1db.js → p-fd5e59f5.js} +1 -1
- package/dist/genesys-webcomponents/scss/style-reset-focusable.scss +44 -5
- package/dist/genesys-webcomponents/scss/style-reset-typography.scss +12 -7
- package/dist/loader/index.d.ts +1 -1
- package/dist/stencil-wrapper.js +4 -4
- package/dist/types/components/legacy/gux-tabs-advanced-legacy/gux-tab-advanced/gux-tab-advanced.d.ts +45 -0
- package/dist/types/components/legacy/gux-tabs-advanced-legacy/gux-tab-advanced-list/gux-tab-advanced-list.d.ts +82 -0
- package/dist/types/components/legacy/gux-tabs-advanced-legacy/gux-tab-advanced-panel/gux-tab-advanced-panel.d.ts +12 -0
- package/dist/types/components/legacy/gux-tabs-advanced-legacy/gux-tabs-advanced.d.ts +25 -0
- package/dist/types/components/stable/gux-icon/gux-icon.types.d.ts +1 -1
- package/dist/types/components.d.ts +132 -0
- package/dist/types/stencil-public-runtime.d.ts +19 -5
- package/dist/types/stencil-wrapper.d.ts +2 -2
- package/dist/types/test/specTestUtils.d.ts +2 -0
- package/package.json +5 -5
- package/dist/esm/polyfills/css-shim.js +0 -1
- package/dist/genesys-webcomponents/p-064f6ec0.entry.js +0 -1
- package/dist/genesys-webcomponents/p-0ed974cb.entry.js +0 -1
- package/dist/genesys-webcomponents/p-16109371.entry.js +0 -1
- package/dist/genesys-webcomponents/p-1dca12c5.entry.js +0 -1
- package/dist/genesys-webcomponents/p-1ee5b66e.entry.js +0 -1
- package/dist/genesys-webcomponents/p-1f265935.entry.js +0 -1
- package/dist/genesys-webcomponents/p-3031a578.entry.js +0 -1
- package/dist/genesys-webcomponents/p-3504b52d.entry.js +0 -1
- package/dist/genesys-webcomponents/p-3d6b25da.entry.js +0 -1
- package/dist/genesys-webcomponents/p-44b665e9.entry.js +0 -1
- package/dist/genesys-webcomponents/p-4bfa8d7f.entry.js +0 -1
- package/dist/genesys-webcomponents/p-4d34cf6e.entry.js +0 -7
- package/dist/genesys-webcomponents/p-4e865a79.entry.js +0 -1
- package/dist/genesys-webcomponents/p-50a508f2.entry.js +0 -1
- package/dist/genesys-webcomponents/p-5406e9ed.entry.js +0 -1
- package/dist/genesys-webcomponents/p-5676eed0.entry.js +0 -1
- package/dist/genesys-webcomponents/p-56b47f79.entry.js +0 -1
- package/dist/genesys-webcomponents/p-66cc767b.entry.js +0 -1
- package/dist/genesys-webcomponents/p-6b0dc655.entry.js +0 -1
- package/dist/genesys-webcomponents/p-6b129835.entry.js +0 -1
- package/dist/genesys-webcomponents/p-700df232.entry.js +0 -1
- package/dist/genesys-webcomponents/p-71649ca7.entry.js +0 -1
- package/dist/genesys-webcomponents/p-718f0a96.entry.js +0 -1
- package/dist/genesys-webcomponents/p-7583eb17.entry.js +0 -1
- package/dist/genesys-webcomponents/p-7c5d3642.entry.js +0 -1
- package/dist/genesys-webcomponents/p-7d26b2e1.js +0 -2
- package/dist/genesys-webcomponents/p-8c62cbe0.entry.js +0 -1
- package/dist/genesys-webcomponents/p-92dc4513.entry.js +0 -1
- package/dist/genesys-webcomponents/p-94965977.entry.js +0 -1
- package/dist/genesys-webcomponents/p-a71e6014.entry.js +0 -1
- package/dist/genesys-webcomponents/p-a90cc738.entry.js +0 -1
- package/dist/genesys-webcomponents/p-a95fbd3b.entry.js +0 -1
- package/dist/genesys-webcomponents/p-baffeea7.entry.js +0 -1
- package/dist/genesys-webcomponents/p-bb33884d.entry.js +0 -1
- package/dist/genesys-webcomponents/p-bcce68e5.entry.js +0 -1
- package/dist/genesys-webcomponents/p-be3431b3.entry.js +0 -1
- package/dist/genesys-webcomponents/p-cae7ee62.entry.js +0 -1
- package/dist/genesys-webcomponents/p-d5e23ee9.entry.js +0 -1
- package/dist/genesys-webcomponents/p-d5e44599.entry.js +0 -1
- package/dist/genesys-webcomponents/p-dc82662a.entry.js +0 -1
- package/dist/genesys-webcomponents/p-e0f0cc0a.entry.js +0 -1
- package/dist/genesys-webcomponents/p-ed00fc7c.entry.js +0 -1
- package/dist/genesys-webcomponents/p-ef910e9b.entry.js +0 -1
- package/dist/genesys-webcomponents/p-f4cd6700.entry.js +0 -1
- package/dist/genesys-webcomponents/scss/focus.scss +0 -48
- package/dist/genesys-webcomponents/scss/typography.scss +0 -127
- /package/dist/cjs/{after-next-render-a09f528a.js → after-next-render-a023ef47.js} +0 -0
- /package/dist/cjs/{capitalize-first-letter-8e2f04e5.js → capitalize-first-letter-251c82ed.js} +0 -0
- /package/dist/cjs/{clamp-1bb96117.js → clamp-a9926a57.js} +0 -0
- /package/dist/cjs/{en-eb56dc17.js → en-5507bf0d.js} +0 -0
- /package/dist/cjs/{en-d1b32383.js → en-807a354e.js} +0 -0
- /package/dist/cjs/{en-2a12d7c4.js → en-f88c1935.js} +0 -0
- /package/dist/cjs/{event-is-from-ad1044f2.js → event-is-from-f3f1cfde.js} +0 -0
- /package/dist/cjs/{find-element-by-id-ecf0efa3.js → find-element-by-id-9c3e0b1b.js} +0 -0
- /package/dist/cjs/{floating-ui.dom.esm-2ed3685b.js → floating-ui.dom.esm-793074c6.js} +0 -0
- /package/dist/cjs/{get-closest-element-ab4b2eee.js → get-closest-element-26894e5a.js} +0 -0
- /package/dist/cjs/{get-slot-097ade01.js → get-slot-395a67ef.js} +0 -0
- /package/dist/cjs/{get-slot-text-content-30aa5492.js → get-slot-text-content-c4306c7a.js} +0 -0
- /package/dist/cjs/{gux-list.service-763539a2.js → gux-list.service-4beaa394.js} +0 -0
- /package/dist/cjs/{gux-listbox.service-93102b5b.js → gux-listbox.service-b1068596.js} +0 -0
- /package/dist/cjs/{gux-menu.common-cf9d53f7.js → gux-menu.common-d41b2fac.js} +0 -0
- /package/dist/cjs/{has-slot-2e73d6e7.js → has-slot-429f8b9e.js} +0 -0
- /package/dist/cjs/{iso-dates-f78ffb80.js → iso-dates-d0cd4802.js} +0 -0
- /package/dist/cjs/{log-error-d46c02b7.js → log-error-8a92241e.js} +0 -0
- /package/dist/cjs/{on-attribute-change-37556263.js → on-attribute-change-4db59350.js} +0 -0
- /package/dist/cjs/{on-input-disabled-state-change-d66fb86b.js → on-input-disabled-state-change-005e5b3e.js} +0 -0
- /package/dist/cjs/{on-mutation-8f8a4460.js → on-mutation-ef917473.js} +0 -0
- /package/dist/cjs/{prevent-browser-validation-styling-d21b1a56.js → prevent-browser-validation-styling-15142963.js} +0 -0
- /package/dist/cjs/{random-html-id-b86b61c0.js → random-html-id-32ef8847.js} +0 -0
- /package/dist/cjs/{simulate-native-event-fe3e62da.js → simulate-native-event-8209a457.js} +0 -0
- /package/dist/cjs/{when-event-is-from-69b5ca13.js → when-event-is-from-20e89254.js} +0 -0
- /package/dist/cjs/{year-month-values-f387f8d8.js → year-month-values-6028ce26.js} +0 -0
- /package/dist/collection/components/beta/gux-phone-input/components/gux-region-icon/sprite-utils/{generate-sprites.js → sprites.generated.js} +0 -0
- /package/dist/esm/{after-next-render-ed0f7dcd.js → after-next-render-84ec18ad.js} +0 -0
- /package/dist/esm/{capitalize-first-letter-d2512ec0.js → capitalize-first-letter-45fad3db.js} +0 -0
- /package/dist/esm/{clamp-6bdb0367.js → clamp-51db64df.js} +0 -0
- /package/dist/esm/{en-5ed282a0.js → en-1f9d79e6.js} +0 -0
- /package/dist/esm/{en-6c4aef39.js → en-98371f99.js} +0 -0
- /package/dist/esm/{en-46223eb1.js → en-b0526f2a.js} +0 -0
- /package/dist/esm/{event-is-from-90b69768.js → event-is-from-e25c5a22.js} +0 -0
- /package/dist/esm/{find-element-by-id-7c5f4fbf.js → find-element-by-id-a3c82a2d.js} +0 -0
- /package/dist/esm/{floating-ui.dom.esm-c86d3efa.js → floating-ui.dom.esm-813bb04f.js} +0 -0
- /package/dist/esm/{get-closest-element-1597503c.js → get-closest-element-66f63212.js} +0 -0
- /package/dist/esm/{get-slot-52d073f3.js → get-slot-55aade31.js} +0 -0
- /package/dist/esm/{get-slot-text-content-2e086993.js → get-slot-text-content-189d6edf.js} +0 -0
- /package/dist/esm/{gux-list.service-a878b7e3.js → gux-list.service-693f4ba7.js} +0 -0
- /package/dist/esm/{gux-listbox.service-a8319b51.js → gux-listbox.service-f2b6e01a.js} +0 -0
- /package/dist/esm/{gux-menu.common-a8b63e91.js → gux-menu.common-e59a1b12.js} +0 -0
- /package/dist/esm/{has-slot-062ae63a.js → has-slot-d06c74d9.js} +0 -0
- /package/dist/esm/{iso-dates-a7c704a4.js → iso-dates-5bcd3209.js} +0 -0
- /package/dist/esm/{log-error-e0bbd04a.js → log-error-0b15023e.js} +0 -0
- /package/dist/esm/{on-attribute-change-5fd8da7c.js → on-attribute-change-b91132e6.js} +0 -0
- /package/dist/esm/{on-input-disabled-state-change-3ea76372.js → on-input-disabled-state-change-e6bc912f.js} +0 -0
- /package/dist/esm/{on-mutation-d500715c.js → on-mutation-a2b7cdad.js} +0 -0
- /package/dist/esm/{prevent-browser-validation-styling-d16c3f4c.js → prevent-browser-validation-styling-8c459589.js} +0 -0
- /package/dist/esm/{random-html-id-8e3f658c.js → random-html-id-3354d85c.js} +0 -0
- /package/dist/esm/{simulate-native-event-ac69961f.js → simulate-native-event-bca7a1c9.js} +0 -0
- /package/dist/esm/{when-event-is-from-18667084.js → when-event-is-from-6154bd60.js} +0 -0
- /package/dist/esm/{year-month-values-1b64c204.js → year-month-values-6ffe871f.js} +0 -0
- /package/dist/genesys-webcomponents/{p-955a1e6a.js → p-08874a83.js} +0 -0
- /package/dist/genesys-webcomponents/{p-8a133b9b.js → p-0962dd7a.js} +0 -0
- /package/dist/genesys-webcomponents/{p-3f5341ea.js → p-16f3da0d.js} +0 -0
- /package/dist/genesys-webcomponents/{p-c10e41a9.js → p-28f55159.js} +0 -0
- /package/dist/genesys-webcomponents/{p-93904222.js → p-31cd1b9a.js} +0 -0
- /package/dist/genesys-webcomponents/{p-08bc2e6b.js → p-324b23f3.js} +0 -0
- /package/dist/genesys-webcomponents/{p-2c3d934a.js → p-363466e3.js} +0 -0
- /package/dist/genesys-webcomponents/{p-d176c2ae.js → p-373c5d93.js} +0 -0
- /package/dist/genesys-webcomponents/{p-cbcbd1bb.js → p-3ea0d493.js} +0 -0
- /package/dist/genesys-webcomponents/{p-1aa11396.js → p-408d5857.js} +0 -0
- /package/dist/genesys-webcomponents/{p-3701eff0.js → p-4e030b49.js} +0 -0
- /package/dist/genesys-webcomponents/{p-4f26144b.js → p-533d7842.js} +0 -0
- /package/dist/genesys-webcomponents/{p-82ffe3cc.js → p-5d7d5695.js} +0 -0
- /package/dist/genesys-webcomponents/{p-3e6097e5.js → p-693c1709.js} +0 -0
- /package/dist/genesys-webcomponents/{p-2bc35259.js → p-705311af.js} +0 -0
- /package/dist/genesys-webcomponents/{p-55cf6d81.js → p-71e00140.js} +0 -0
- /package/dist/genesys-webcomponents/{p-9dd4b14a.js → p-7b08c759.js} +0 -0
- /package/dist/genesys-webcomponents/{p-76ff3e75.js → p-8b703092.js} +0 -0
- /package/dist/genesys-webcomponents/{p-251befef.js → p-9125cc36.js} +0 -0
- /package/dist/genesys-webcomponents/{p-d0805f56.js → p-9d734bbd.js} +0 -0
- /package/dist/genesys-webcomponents/{p-4e2b5bcf.js → p-a5937ee9.js} +0 -0
- /package/dist/genesys-webcomponents/{p-417354e9.js → p-aa9ff6ba.js} +0 -0
- /package/dist/genesys-webcomponents/{p-abb9b5f7.js → p-c7328d42.js} +0 -0
- /package/dist/genesys-webcomponents/{p-29e8b184.js → p-dbb0ac25.js} +0 -0
- /package/dist/genesys-webcomponents/{p-aa2f9991.js → p-dd53013c.js} +0 -0
- /package/dist/genesys-webcomponents/{p-091f51f6.js → p-ffaadf62.js} +0 -0
- /package/dist/types/components/beta/gux-phone-input/components/gux-region-icon/sprite-utils/{generate-sprites.d.ts → sprites.generated.d.ts} +0 -0
@@ -2,3035 +2,16 @@
|
|
2
2
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
4
4
|
|
5
|
-
const index
|
6
|
-
const
|
7
|
-
const
|
8
|
-
const
|
9
|
-
const
|
10
|
-
const
|
11
|
-
require('./
|
5
|
+
const index = require('./index-39160f18.js');
|
6
|
+
const sortable_esm = require('./sortable.esm-73cf219b.js');
|
7
|
+
const onMutation = require('./on-mutation-f396cc0e.js');
|
8
|
+
const eventIsFrom = require('./event-is-from-f3f1cfde.js');
|
9
|
+
const afterNextRender = require('./after-next-render-a023ef47.js');
|
10
|
+
const index$1 = require('./index-ff762de3.js');
|
11
|
+
const en = require('./en-85604f0f.js');
|
12
|
+
require('./get-closest-element-26894e5a.js');
|
12
13
|
|
13
|
-
|
14
|
-
* Sortable 1.15.0
|
15
|
-
* @author RubaXa <trash@rubaxa.org>
|
16
|
-
* @author owenm <owen23355@gmail.com>
|
17
|
-
* @license MIT
|
18
|
-
*/
|
19
|
-
function ownKeys(object, enumerableOnly) {
|
20
|
-
var keys = Object.keys(object);
|
21
|
-
|
22
|
-
if (Object.getOwnPropertySymbols) {
|
23
|
-
var symbols = Object.getOwnPropertySymbols(object);
|
24
|
-
|
25
|
-
if (enumerableOnly) {
|
26
|
-
symbols = symbols.filter(function (sym) {
|
27
|
-
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
28
|
-
});
|
29
|
-
}
|
30
|
-
|
31
|
-
keys.push.apply(keys, symbols);
|
32
|
-
}
|
33
|
-
|
34
|
-
return keys;
|
35
|
-
}
|
36
|
-
|
37
|
-
function _objectSpread2(target) {
|
38
|
-
for (var i = 1; i < arguments.length; i++) {
|
39
|
-
var source = arguments[i] != null ? arguments[i] : {};
|
40
|
-
|
41
|
-
if (i % 2) {
|
42
|
-
ownKeys(Object(source), true).forEach(function (key) {
|
43
|
-
_defineProperty(target, key, source[key]);
|
44
|
-
});
|
45
|
-
} else if (Object.getOwnPropertyDescriptors) {
|
46
|
-
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
47
|
-
} else {
|
48
|
-
ownKeys(Object(source)).forEach(function (key) {
|
49
|
-
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
50
|
-
});
|
51
|
-
}
|
52
|
-
}
|
53
|
-
|
54
|
-
return target;
|
55
|
-
}
|
56
|
-
|
57
|
-
function _typeof(obj) {
|
58
|
-
"@babel/helpers - typeof";
|
59
|
-
|
60
|
-
if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") {
|
61
|
-
_typeof = function (obj) {
|
62
|
-
return typeof obj;
|
63
|
-
};
|
64
|
-
} else {
|
65
|
-
_typeof = function (obj) {
|
66
|
-
return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
|
67
|
-
};
|
68
|
-
}
|
69
|
-
|
70
|
-
return _typeof(obj);
|
71
|
-
}
|
72
|
-
|
73
|
-
function _defineProperty(obj, key, value) {
|
74
|
-
if (key in obj) {
|
75
|
-
Object.defineProperty(obj, key, {
|
76
|
-
value: value,
|
77
|
-
enumerable: true,
|
78
|
-
configurable: true,
|
79
|
-
writable: true
|
80
|
-
});
|
81
|
-
} else {
|
82
|
-
obj[key] = value;
|
83
|
-
}
|
84
|
-
|
85
|
-
return obj;
|
86
|
-
}
|
87
|
-
|
88
|
-
function _extends() {
|
89
|
-
_extends = Object.assign || function (target) {
|
90
|
-
for (var i = 1; i < arguments.length; i++) {
|
91
|
-
var source = arguments[i];
|
92
|
-
|
93
|
-
for (var key in source) {
|
94
|
-
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
95
|
-
target[key] = source[key];
|
96
|
-
}
|
97
|
-
}
|
98
|
-
}
|
99
|
-
|
100
|
-
return target;
|
101
|
-
};
|
102
|
-
|
103
|
-
return _extends.apply(this, arguments);
|
104
|
-
}
|
105
|
-
|
106
|
-
function _objectWithoutPropertiesLoose(source, excluded) {
|
107
|
-
if (source == null) return {};
|
108
|
-
var target = {};
|
109
|
-
var sourceKeys = Object.keys(source);
|
110
|
-
var key, i;
|
111
|
-
|
112
|
-
for (i = 0; i < sourceKeys.length; i++) {
|
113
|
-
key = sourceKeys[i];
|
114
|
-
if (excluded.indexOf(key) >= 0) continue;
|
115
|
-
target[key] = source[key];
|
116
|
-
}
|
117
|
-
|
118
|
-
return target;
|
119
|
-
}
|
120
|
-
|
121
|
-
function _objectWithoutProperties(source, excluded) {
|
122
|
-
if (source == null) return {};
|
123
|
-
|
124
|
-
var target = _objectWithoutPropertiesLoose(source, excluded);
|
125
|
-
|
126
|
-
var key, i;
|
127
|
-
|
128
|
-
if (Object.getOwnPropertySymbols) {
|
129
|
-
var sourceSymbolKeys = Object.getOwnPropertySymbols(source);
|
130
|
-
|
131
|
-
for (i = 0; i < sourceSymbolKeys.length; i++) {
|
132
|
-
key = sourceSymbolKeys[i];
|
133
|
-
if (excluded.indexOf(key) >= 0) continue;
|
134
|
-
if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue;
|
135
|
-
target[key] = source[key];
|
136
|
-
}
|
137
|
-
}
|
138
|
-
|
139
|
-
return target;
|
140
|
-
}
|
141
|
-
|
142
|
-
var version = "1.15.0";
|
143
|
-
|
144
|
-
function userAgent(pattern) {
|
145
|
-
if (typeof window !== 'undefined' && window.navigator) {
|
146
|
-
return !! /*@__PURE__*/navigator.userAgent.match(pattern);
|
147
|
-
}
|
148
|
-
}
|
149
|
-
|
150
|
-
var IE11OrLess = userAgent(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i);
|
151
|
-
var Edge = userAgent(/Edge/i);
|
152
|
-
var FireFox = userAgent(/firefox/i);
|
153
|
-
var Safari = userAgent(/safari/i) && !userAgent(/chrome/i) && !userAgent(/android/i);
|
154
|
-
var IOS = userAgent(/iP(ad|od|hone)/i);
|
155
|
-
var ChromeForAndroid = userAgent(/chrome/i) && userAgent(/android/i);
|
156
|
-
|
157
|
-
var captureMode = {
|
158
|
-
capture: false,
|
159
|
-
passive: false
|
160
|
-
};
|
161
|
-
|
162
|
-
function on(el, event, fn) {
|
163
|
-
el.addEventListener(event, fn, !IE11OrLess && captureMode);
|
164
|
-
}
|
165
|
-
|
166
|
-
function off(el, event, fn) {
|
167
|
-
el.removeEventListener(event, fn, !IE11OrLess && captureMode);
|
168
|
-
}
|
169
|
-
|
170
|
-
function matches(
|
171
|
-
/**HTMLElement*/
|
172
|
-
el,
|
173
|
-
/**String*/
|
174
|
-
selector) {
|
175
|
-
if (!selector) return;
|
176
|
-
selector[0] === '>' && (selector = selector.substring(1));
|
177
|
-
|
178
|
-
if (el) {
|
179
|
-
try {
|
180
|
-
if (el.matches) {
|
181
|
-
return el.matches(selector);
|
182
|
-
} else if (el.msMatchesSelector) {
|
183
|
-
return el.msMatchesSelector(selector);
|
184
|
-
} else if (el.webkitMatchesSelector) {
|
185
|
-
return el.webkitMatchesSelector(selector);
|
186
|
-
}
|
187
|
-
} catch (_) {
|
188
|
-
return false;
|
189
|
-
}
|
190
|
-
}
|
191
|
-
|
192
|
-
return false;
|
193
|
-
}
|
194
|
-
|
195
|
-
function getParentOrHost(el) {
|
196
|
-
return el.host && el !== document && el.host.nodeType ? el.host : el.parentNode;
|
197
|
-
}
|
198
|
-
|
199
|
-
function closest(
|
200
|
-
/**HTMLElement*/
|
201
|
-
el,
|
202
|
-
/**String*/
|
203
|
-
selector,
|
204
|
-
/**HTMLElement*/
|
205
|
-
ctx, includeCTX) {
|
206
|
-
if (el) {
|
207
|
-
ctx = ctx || document;
|
208
|
-
|
209
|
-
do {
|
210
|
-
if (selector != null && (selector[0] === '>' ? el.parentNode === ctx && matches(el, selector) : matches(el, selector)) || includeCTX && el === ctx) {
|
211
|
-
return el;
|
212
|
-
}
|
213
|
-
|
214
|
-
if (el === ctx) break;
|
215
|
-
/* jshint boss:true */
|
216
|
-
} while (el = getParentOrHost(el));
|
217
|
-
}
|
218
|
-
|
219
|
-
return null;
|
220
|
-
}
|
221
|
-
|
222
|
-
var R_SPACE = /\s+/g;
|
223
|
-
|
224
|
-
function toggleClass(el, name, state) {
|
225
|
-
if (el && name) {
|
226
|
-
if (el.classList) {
|
227
|
-
el.classList[state ? 'add' : 'remove'](name);
|
228
|
-
} else {
|
229
|
-
var className = (' ' + el.className + ' ').replace(R_SPACE, ' ').replace(' ' + name + ' ', ' ');
|
230
|
-
el.className = (className + (state ? ' ' + name : '')).replace(R_SPACE, ' ');
|
231
|
-
}
|
232
|
-
}
|
233
|
-
}
|
234
|
-
|
235
|
-
function css(el, prop, val) {
|
236
|
-
var style = el && el.style;
|
237
|
-
|
238
|
-
if (style) {
|
239
|
-
if (val === void 0) {
|
240
|
-
if (document.defaultView && document.defaultView.getComputedStyle) {
|
241
|
-
val = document.defaultView.getComputedStyle(el, '');
|
242
|
-
} else if (el.currentStyle) {
|
243
|
-
val = el.currentStyle;
|
244
|
-
}
|
245
|
-
|
246
|
-
return prop === void 0 ? val : val[prop];
|
247
|
-
} else {
|
248
|
-
if (!(prop in style) && prop.indexOf('webkit') === -1) {
|
249
|
-
prop = '-webkit-' + prop;
|
250
|
-
}
|
251
|
-
|
252
|
-
style[prop] = val + (typeof val === 'string' ? '' : 'px');
|
253
|
-
}
|
254
|
-
}
|
255
|
-
}
|
256
|
-
|
257
|
-
function matrix(el, selfOnly) {
|
258
|
-
var appliedTransforms = '';
|
259
|
-
|
260
|
-
if (typeof el === 'string') {
|
261
|
-
appliedTransforms = el;
|
262
|
-
} else {
|
263
|
-
do {
|
264
|
-
var transform = css(el, 'transform');
|
265
|
-
|
266
|
-
if (transform && transform !== 'none') {
|
267
|
-
appliedTransforms = transform + ' ' + appliedTransforms;
|
268
|
-
}
|
269
|
-
/* jshint boss:true */
|
270
|
-
|
271
|
-
} while (!selfOnly && (el = el.parentNode));
|
272
|
-
}
|
273
|
-
|
274
|
-
var matrixFn = window.DOMMatrix || window.WebKitCSSMatrix || window.CSSMatrix || window.MSCSSMatrix;
|
275
|
-
/*jshint -W056 */
|
276
|
-
|
277
|
-
return matrixFn && new matrixFn(appliedTransforms);
|
278
|
-
}
|
279
|
-
|
280
|
-
function find(ctx, tagName, iterator) {
|
281
|
-
if (ctx) {
|
282
|
-
var list = ctx.getElementsByTagName(tagName),
|
283
|
-
i = 0,
|
284
|
-
n = list.length;
|
285
|
-
|
286
|
-
if (iterator) {
|
287
|
-
for (; i < n; i++) {
|
288
|
-
iterator(list[i], i);
|
289
|
-
}
|
290
|
-
}
|
291
|
-
|
292
|
-
return list;
|
293
|
-
}
|
294
|
-
|
295
|
-
return [];
|
296
|
-
}
|
297
|
-
|
298
|
-
function getWindowScrollingElement() {
|
299
|
-
var scrollingElement = document.scrollingElement;
|
300
|
-
|
301
|
-
if (scrollingElement) {
|
302
|
-
return scrollingElement;
|
303
|
-
} else {
|
304
|
-
return document.documentElement;
|
305
|
-
}
|
306
|
-
}
|
307
|
-
/**
|
308
|
-
* Returns the "bounding client rect" of given element
|
309
|
-
* @param {HTMLElement} el The element whose boundingClientRect is wanted
|
310
|
-
* @param {[Boolean]} relativeToContainingBlock Whether the rect should be relative to the containing block of (including) the container
|
311
|
-
* @param {[Boolean]} relativeToNonStaticParent Whether the rect should be relative to the relative parent of (including) the contaienr
|
312
|
-
* @param {[Boolean]} undoScale Whether the container's scale() should be undone
|
313
|
-
* @param {[HTMLElement]} container The parent the element will be placed in
|
314
|
-
* @return {Object} The boundingClientRect of el, with specified adjustments
|
315
|
-
*/
|
316
|
-
|
317
|
-
|
318
|
-
function getRect(el, relativeToContainingBlock, relativeToNonStaticParent, undoScale, container) {
|
319
|
-
if (!el.getBoundingClientRect && el !== window) return;
|
320
|
-
var elRect, top, left, bottom, right, height, width;
|
321
|
-
|
322
|
-
if (el !== window && el.parentNode && el !== getWindowScrollingElement()) {
|
323
|
-
elRect = el.getBoundingClientRect();
|
324
|
-
top = elRect.top;
|
325
|
-
left = elRect.left;
|
326
|
-
bottom = elRect.bottom;
|
327
|
-
right = elRect.right;
|
328
|
-
height = elRect.height;
|
329
|
-
width = elRect.width;
|
330
|
-
} else {
|
331
|
-
top = 0;
|
332
|
-
left = 0;
|
333
|
-
bottom = window.innerHeight;
|
334
|
-
right = window.innerWidth;
|
335
|
-
height = window.innerHeight;
|
336
|
-
width = window.innerWidth;
|
337
|
-
}
|
338
|
-
|
339
|
-
if ((relativeToContainingBlock || relativeToNonStaticParent) && el !== window) {
|
340
|
-
// Adjust for translate()
|
341
|
-
container = container || el.parentNode; // solves #1123 (see: https://stackoverflow.com/a/37953806/6088312)
|
342
|
-
// Not needed on <= IE11
|
343
|
-
|
344
|
-
if (!IE11OrLess) {
|
345
|
-
do {
|
346
|
-
if (container && container.getBoundingClientRect && (css(container, 'transform') !== 'none' || relativeToNonStaticParent && css(container, 'position') !== 'static')) {
|
347
|
-
var containerRect = container.getBoundingClientRect(); // Set relative to edges of padding box of container
|
348
|
-
|
349
|
-
top -= containerRect.top + parseInt(css(container, 'border-top-width'));
|
350
|
-
left -= containerRect.left + parseInt(css(container, 'border-left-width'));
|
351
|
-
bottom = top + elRect.height;
|
352
|
-
right = left + elRect.width;
|
353
|
-
break;
|
354
|
-
}
|
355
|
-
/* jshint boss:true */
|
356
|
-
|
357
|
-
} while (container = container.parentNode);
|
358
|
-
}
|
359
|
-
}
|
360
|
-
|
361
|
-
if (undoScale && el !== window) {
|
362
|
-
// Adjust for scale()
|
363
|
-
var elMatrix = matrix(container || el),
|
364
|
-
scaleX = elMatrix && elMatrix.a,
|
365
|
-
scaleY = elMatrix && elMatrix.d;
|
366
|
-
|
367
|
-
if (elMatrix) {
|
368
|
-
top /= scaleY;
|
369
|
-
left /= scaleX;
|
370
|
-
width /= scaleX;
|
371
|
-
height /= scaleY;
|
372
|
-
bottom = top + height;
|
373
|
-
right = left + width;
|
374
|
-
}
|
375
|
-
}
|
376
|
-
|
377
|
-
return {
|
378
|
-
top: top,
|
379
|
-
left: left,
|
380
|
-
bottom: bottom,
|
381
|
-
right: right,
|
382
|
-
width: width,
|
383
|
-
height: height
|
384
|
-
};
|
385
|
-
}
|
386
|
-
/**
|
387
|
-
* Checks if a side of an element is scrolled past a side of its parents
|
388
|
-
* @param {HTMLElement} el The element who's side being scrolled out of view is in question
|
389
|
-
* @param {String} elSide Side of the element in question ('top', 'left', 'right', 'bottom')
|
390
|
-
* @param {String} parentSide Side of the parent in question ('top', 'left', 'right', 'bottom')
|
391
|
-
* @return {HTMLElement} The parent scroll element that the el's side is scrolled past, or null if there is no such element
|
392
|
-
*/
|
393
|
-
|
394
|
-
|
395
|
-
function isScrolledPast(el, elSide, parentSide) {
|
396
|
-
var parent = getParentAutoScrollElement(el, true),
|
397
|
-
elSideVal = getRect(el)[elSide];
|
398
|
-
/* jshint boss:true */
|
399
|
-
|
400
|
-
while (parent) {
|
401
|
-
var parentSideVal = getRect(parent)[parentSide],
|
402
|
-
visible = void 0;
|
403
|
-
|
404
|
-
if (parentSide === 'top' || parentSide === 'left') {
|
405
|
-
visible = elSideVal >= parentSideVal;
|
406
|
-
} else {
|
407
|
-
visible = elSideVal <= parentSideVal;
|
408
|
-
}
|
409
|
-
|
410
|
-
if (!visible) return parent;
|
411
|
-
if (parent === getWindowScrollingElement()) break;
|
412
|
-
parent = getParentAutoScrollElement(parent, false);
|
413
|
-
}
|
414
|
-
|
415
|
-
return false;
|
416
|
-
}
|
417
|
-
/**
|
418
|
-
* Gets nth child of el, ignoring hidden children, sortable's elements (does not ignore clone if it's visible)
|
419
|
-
* and non-draggable elements
|
420
|
-
* @param {HTMLElement} el The parent element
|
421
|
-
* @param {Number} childNum The index of the child
|
422
|
-
* @param {Object} options Parent Sortable's options
|
423
|
-
* @return {HTMLElement} The child at index childNum, or null if not found
|
424
|
-
*/
|
425
|
-
|
426
|
-
|
427
|
-
function getChild(el, childNum, options, includeDragEl) {
|
428
|
-
var currentChild = 0,
|
429
|
-
i = 0,
|
430
|
-
children = el.children;
|
431
|
-
|
432
|
-
while (i < children.length) {
|
433
|
-
if (children[i].style.display !== 'none' && children[i] !== Sortable.ghost && (includeDragEl || children[i] !== Sortable.dragged) && closest(children[i], options.draggable, el, false)) {
|
434
|
-
if (currentChild === childNum) {
|
435
|
-
return children[i];
|
436
|
-
}
|
437
|
-
|
438
|
-
currentChild++;
|
439
|
-
}
|
440
|
-
|
441
|
-
i++;
|
442
|
-
}
|
443
|
-
|
444
|
-
return null;
|
445
|
-
}
|
446
|
-
/**
|
447
|
-
* Gets the last child in the el, ignoring ghostEl or invisible elements (clones)
|
448
|
-
* @param {HTMLElement} el Parent element
|
449
|
-
* @param {selector} selector Any other elements that should be ignored
|
450
|
-
* @return {HTMLElement} The last child, ignoring ghostEl
|
451
|
-
*/
|
452
|
-
|
453
|
-
|
454
|
-
function lastChild(el, selector) {
|
455
|
-
var last = el.lastElementChild;
|
456
|
-
|
457
|
-
while (last && (last === Sortable.ghost || css(last, 'display') === 'none' || selector && !matches(last, selector))) {
|
458
|
-
last = last.previousElementSibling;
|
459
|
-
}
|
460
|
-
|
461
|
-
return last || null;
|
462
|
-
}
|
463
|
-
/**
|
464
|
-
* Returns the index of an element within its parent for a selected set of
|
465
|
-
* elements
|
466
|
-
* @param {HTMLElement} el
|
467
|
-
* @param {selector} selector
|
468
|
-
* @return {number}
|
469
|
-
*/
|
470
|
-
|
471
|
-
|
472
|
-
function index(el, selector) {
|
473
|
-
var index = 0;
|
474
|
-
|
475
|
-
if (!el || !el.parentNode) {
|
476
|
-
return -1;
|
477
|
-
}
|
478
|
-
/* jshint boss:true */
|
479
|
-
|
480
|
-
|
481
|
-
while (el = el.previousElementSibling) {
|
482
|
-
if (el.nodeName.toUpperCase() !== 'TEMPLATE' && el !== Sortable.clone && (!selector || matches(el, selector))) {
|
483
|
-
index++;
|
484
|
-
}
|
485
|
-
}
|
486
|
-
|
487
|
-
return index;
|
488
|
-
}
|
489
|
-
/**
|
490
|
-
* Returns the scroll offset of the given element, added with all the scroll offsets of parent elements.
|
491
|
-
* The value is returned in real pixels.
|
492
|
-
* @param {HTMLElement} el
|
493
|
-
* @return {Array} Offsets in the format of [left, top]
|
494
|
-
*/
|
495
|
-
|
496
|
-
|
497
|
-
function getRelativeScrollOffset(el) {
|
498
|
-
var offsetLeft = 0,
|
499
|
-
offsetTop = 0,
|
500
|
-
winScroller = getWindowScrollingElement();
|
501
|
-
|
502
|
-
if (el) {
|
503
|
-
do {
|
504
|
-
var elMatrix = matrix(el),
|
505
|
-
scaleX = elMatrix.a,
|
506
|
-
scaleY = elMatrix.d;
|
507
|
-
offsetLeft += el.scrollLeft * scaleX;
|
508
|
-
offsetTop += el.scrollTop * scaleY;
|
509
|
-
} while (el !== winScroller && (el = el.parentNode));
|
510
|
-
}
|
511
|
-
|
512
|
-
return [offsetLeft, offsetTop];
|
513
|
-
}
|
514
|
-
/**
|
515
|
-
* Returns the index of the object within the given array
|
516
|
-
* @param {Array} arr Array that may or may not hold the object
|
517
|
-
* @param {Object} obj An object that has a key-value pair unique to and identical to a key-value pair in the object you want to find
|
518
|
-
* @return {Number} The index of the object in the array, or -1
|
519
|
-
*/
|
520
|
-
|
521
|
-
|
522
|
-
function indexOfObject(arr, obj) {
|
523
|
-
for (var i in arr) {
|
524
|
-
if (!arr.hasOwnProperty(i)) continue;
|
525
|
-
|
526
|
-
for (var key in obj) {
|
527
|
-
if (obj.hasOwnProperty(key) && obj[key] === arr[i][key]) return Number(i);
|
528
|
-
}
|
529
|
-
}
|
530
|
-
|
531
|
-
return -1;
|
532
|
-
}
|
533
|
-
|
534
|
-
function getParentAutoScrollElement(el, includeSelf) {
|
535
|
-
// skip to window
|
536
|
-
if (!el || !el.getBoundingClientRect) return getWindowScrollingElement();
|
537
|
-
var elem = el;
|
538
|
-
var gotSelf = false;
|
539
|
-
|
540
|
-
do {
|
541
|
-
// we don't need to get elem css if it isn't even overflowing in the first place (performance)
|
542
|
-
if (elem.clientWidth < elem.scrollWidth || elem.clientHeight < elem.scrollHeight) {
|
543
|
-
var elemCSS = css(elem);
|
544
|
-
|
545
|
-
if (elem.clientWidth < elem.scrollWidth && (elemCSS.overflowX == 'auto' || elemCSS.overflowX == 'scroll') || elem.clientHeight < elem.scrollHeight && (elemCSS.overflowY == 'auto' || elemCSS.overflowY == 'scroll')) {
|
546
|
-
if (!elem.getBoundingClientRect || elem === document.body) return getWindowScrollingElement();
|
547
|
-
if (gotSelf || includeSelf) return elem;
|
548
|
-
gotSelf = true;
|
549
|
-
}
|
550
|
-
}
|
551
|
-
/* jshint boss:true */
|
552
|
-
|
553
|
-
} while (elem = elem.parentNode);
|
554
|
-
|
555
|
-
return getWindowScrollingElement();
|
556
|
-
}
|
557
|
-
|
558
|
-
function extend(dst, src) {
|
559
|
-
if (dst && src) {
|
560
|
-
for (var key in src) {
|
561
|
-
if (src.hasOwnProperty(key)) {
|
562
|
-
dst[key] = src[key];
|
563
|
-
}
|
564
|
-
}
|
565
|
-
}
|
566
|
-
|
567
|
-
return dst;
|
568
|
-
}
|
569
|
-
|
570
|
-
function isRectEqual(rect1, rect2) {
|
571
|
-
return Math.round(rect1.top) === Math.round(rect2.top) && Math.round(rect1.left) === Math.round(rect2.left) && Math.round(rect1.height) === Math.round(rect2.height) && Math.round(rect1.width) === Math.round(rect2.width);
|
572
|
-
}
|
573
|
-
|
574
|
-
var _throttleTimeout;
|
575
|
-
|
576
|
-
function throttle(callback, ms) {
|
577
|
-
return function () {
|
578
|
-
if (!_throttleTimeout) {
|
579
|
-
var args = arguments,
|
580
|
-
_this = this;
|
581
|
-
|
582
|
-
if (args.length === 1) {
|
583
|
-
callback.call(_this, args[0]);
|
584
|
-
} else {
|
585
|
-
callback.apply(_this, args);
|
586
|
-
}
|
587
|
-
|
588
|
-
_throttleTimeout = setTimeout(function () {
|
589
|
-
_throttleTimeout = void 0;
|
590
|
-
}, ms);
|
591
|
-
}
|
592
|
-
};
|
593
|
-
}
|
594
|
-
|
595
|
-
function cancelThrottle() {
|
596
|
-
clearTimeout(_throttleTimeout);
|
597
|
-
_throttleTimeout = void 0;
|
598
|
-
}
|
599
|
-
|
600
|
-
function scrollBy(el, x, y) {
|
601
|
-
el.scrollLeft += x;
|
602
|
-
el.scrollTop += y;
|
603
|
-
}
|
604
|
-
|
605
|
-
function clone(el) {
|
606
|
-
var Polymer = window.Polymer;
|
607
|
-
var $ = window.jQuery || window.Zepto;
|
608
|
-
|
609
|
-
if (Polymer && Polymer.dom) {
|
610
|
-
return Polymer.dom(el).cloneNode(true);
|
611
|
-
} else if ($) {
|
612
|
-
return $(el).clone(true)[0];
|
613
|
-
} else {
|
614
|
-
return el.cloneNode(true);
|
615
|
-
}
|
616
|
-
}
|
617
|
-
|
618
|
-
var expando = 'Sortable' + new Date().getTime();
|
619
|
-
|
620
|
-
function AnimationStateManager() {
|
621
|
-
var animationStates = [],
|
622
|
-
animationCallbackId;
|
623
|
-
return {
|
624
|
-
captureAnimationState: function captureAnimationState() {
|
625
|
-
animationStates = [];
|
626
|
-
if (!this.options.animation) return;
|
627
|
-
var children = [].slice.call(this.el.children);
|
628
|
-
children.forEach(function (child) {
|
629
|
-
if (css(child, 'display') === 'none' || child === Sortable.ghost) return;
|
630
|
-
animationStates.push({
|
631
|
-
target: child,
|
632
|
-
rect: getRect(child)
|
633
|
-
});
|
634
|
-
|
635
|
-
var fromRect = _objectSpread2({}, animationStates[animationStates.length - 1].rect); // If animating: compensate for current animation
|
636
|
-
|
637
|
-
|
638
|
-
if (child.thisAnimationDuration) {
|
639
|
-
var childMatrix = matrix(child, true);
|
640
|
-
|
641
|
-
if (childMatrix) {
|
642
|
-
fromRect.top -= childMatrix.f;
|
643
|
-
fromRect.left -= childMatrix.e;
|
644
|
-
}
|
645
|
-
}
|
646
|
-
|
647
|
-
child.fromRect = fromRect;
|
648
|
-
});
|
649
|
-
},
|
650
|
-
addAnimationState: function addAnimationState(state) {
|
651
|
-
animationStates.push(state);
|
652
|
-
},
|
653
|
-
removeAnimationState: function removeAnimationState(target) {
|
654
|
-
animationStates.splice(indexOfObject(animationStates, {
|
655
|
-
target: target
|
656
|
-
}), 1);
|
657
|
-
},
|
658
|
-
animateAll: function animateAll(callback) {
|
659
|
-
var _this = this;
|
660
|
-
|
661
|
-
if (!this.options.animation) {
|
662
|
-
clearTimeout(animationCallbackId);
|
663
|
-
if (typeof callback === 'function') callback();
|
664
|
-
return;
|
665
|
-
}
|
666
|
-
|
667
|
-
var animating = false,
|
668
|
-
animationTime = 0;
|
669
|
-
animationStates.forEach(function (state) {
|
670
|
-
var time = 0,
|
671
|
-
target = state.target,
|
672
|
-
fromRect = target.fromRect,
|
673
|
-
toRect = getRect(target),
|
674
|
-
prevFromRect = target.prevFromRect,
|
675
|
-
prevToRect = target.prevToRect,
|
676
|
-
animatingRect = state.rect,
|
677
|
-
targetMatrix = matrix(target, true);
|
678
|
-
|
679
|
-
if (targetMatrix) {
|
680
|
-
// Compensate for current animation
|
681
|
-
toRect.top -= targetMatrix.f;
|
682
|
-
toRect.left -= targetMatrix.e;
|
683
|
-
}
|
684
|
-
|
685
|
-
target.toRect = toRect;
|
686
|
-
|
687
|
-
if (target.thisAnimationDuration) {
|
688
|
-
// Could also check if animatingRect is between fromRect and toRect
|
689
|
-
if (isRectEqual(prevFromRect, toRect) && !isRectEqual(fromRect, toRect) && // Make sure animatingRect is on line between toRect & fromRect
|
690
|
-
(animatingRect.top - toRect.top) / (animatingRect.left - toRect.left) === (fromRect.top - toRect.top) / (fromRect.left - toRect.left)) {
|
691
|
-
// If returning to same place as started from animation and on same axis
|
692
|
-
time = calculateRealTime(animatingRect, prevFromRect, prevToRect, _this.options);
|
693
|
-
}
|
694
|
-
} // if fromRect != toRect: animate
|
695
|
-
|
696
|
-
|
697
|
-
if (!isRectEqual(toRect, fromRect)) {
|
698
|
-
target.prevFromRect = fromRect;
|
699
|
-
target.prevToRect = toRect;
|
700
|
-
|
701
|
-
if (!time) {
|
702
|
-
time = _this.options.animation;
|
703
|
-
}
|
704
|
-
|
705
|
-
_this.animate(target, animatingRect, toRect, time);
|
706
|
-
}
|
707
|
-
|
708
|
-
if (time) {
|
709
|
-
animating = true;
|
710
|
-
animationTime = Math.max(animationTime, time);
|
711
|
-
clearTimeout(target.animationResetTimer);
|
712
|
-
target.animationResetTimer = setTimeout(function () {
|
713
|
-
target.animationTime = 0;
|
714
|
-
target.prevFromRect = null;
|
715
|
-
target.fromRect = null;
|
716
|
-
target.prevToRect = null;
|
717
|
-
target.thisAnimationDuration = null;
|
718
|
-
}, time);
|
719
|
-
target.thisAnimationDuration = time;
|
720
|
-
}
|
721
|
-
});
|
722
|
-
clearTimeout(animationCallbackId);
|
723
|
-
|
724
|
-
if (!animating) {
|
725
|
-
if (typeof callback === 'function') callback();
|
726
|
-
} else {
|
727
|
-
animationCallbackId = setTimeout(function () {
|
728
|
-
if (typeof callback === 'function') callback();
|
729
|
-
}, animationTime);
|
730
|
-
}
|
731
|
-
|
732
|
-
animationStates = [];
|
733
|
-
},
|
734
|
-
animate: function animate(target, currentRect, toRect, duration) {
|
735
|
-
if (duration) {
|
736
|
-
css(target, 'transition', '');
|
737
|
-
css(target, 'transform', '');
|
738
|
-
var elMatrix = matrix(this.el),
|
739
|
-
scaleX = elMatrix && elMatrix.a,
|
740
|
-
scaleY = elMatrix && elMatrix.d,
|
741
|
-
translateX = (currentRect.left - toRect.left) / (scaleX || 1),
|
742
|
-
translateY = (currentRect.top - toRect.top) / (scaleY || 1);
|
743
|
-
target.animatingX = !!translateX;
|
744
|
-
target.animatingY = !!translateY;
|
745
|
-
css(target, 'transform', 'translate3d(' + translateX + 'px,' + translateY + 'px,0)');
|
746
|
-
this.forRepaintDummy = repaint(target); // repaint
|
747
|
-
|
748
|
-
css(target, 'transition', 'transform ' + duration + 'ms' + (this.options.easing ? ' ' + this.options.easing : ''));
|
749
|
-
css(target, 'transform', 'translate3d(0,0,0)');
|
750
|
-
typeof target.animated === 'number' && clearTimeout(target.animated);
|
751
|
-
target.animated = setTimeout(function () {
|
752
|
-
css(target, 'transition', '');
|
753
|
-
css(target, 'transform', '');
|
754
|
-
target.animated = false;
|
755
|
-
target.animatingX = false;
|
756
|
-
target.animatingY = false;
|
757
|
-
}, duration);
|
758
|
-
}
|
759
|
-
}
|
760
|
-
};
|
761
|
-
}
|
762
|
-
|
763
|
-
function repaint(target) {
|
764
|
-
return target.offsetWidth;
|
765
|
-
}
|
766
|
-
|
767
|
-
function calculateRealTime(animatingRect, fromRect, toRect, options) {
|
768
|
-
return Math.sqrt(Math.pow(fromRect.top - animatingRect.top, 2) + Math.pow(fromRect.left - animatingRect.left, 2)) / Math.sqrt(Math.pow(fromRect.top - toRect.top, 2) + Math.pow(fromRect.left - toRect.left, 2)) * options.animation;
|
769
|
-
}
|
770
|
-
|
771
|
-
var plugins = [];
|
772
|
-
var defaults = {
|
773
|
-
initializeByDefault: true
|
774
|
-
};
|
775
|
-
var PluginManager = {
|
776
|
-
mount: function mount(plugin) {
|
777
|
-
// Set default static properties
|
778
|
-
for (var option in defaults) {
|
779
|
-
if (defaults.hasOwnProperty(option) && !(option in plugin)) {
|
780
|
-
plugin[option] = defaults[option];
|
781
|
-
}
|
782
|
-
}
|
783
|
-
|
784
|
-
plugins.forEach(function (p) {
|
785
|
-
if (p.pluginName === plugin.pluginName) {
|
786
|
-
throw "Sortable: Cannot mount plugin ".concat(plugin.pluginName, " more than once");
|
787
|
-
}
|
788
|
-
});
|
789
|
-
plugins.push(plugin);
|
790
|
-
},
|
791
|
-
pluginEvent: function pluginEvent(eventName, sortable, evt) {
|
792
|
-
var _this = this;
|
793
|
-
|
794
|
-
this.eventCanceled = false;
|
795
|
-
|
796
|
-
evt.cancel = function () {
|
797
|
-
_this.eventCanceled = true;
|
798
|
-
};
|
799
|
-
|
800
|
-
var eventNameGlobal = eventName + 'Global';
|
801
|
-
plugins.forEach(function (plugin) {
|
802
|
-
if (!sortable[plugin.pluginName]) return; // Fire global events if it exists in this sortable
|
803
|
-
|
804
|
-
if (sortable[plugin.pluginName][eventNameGlobal]) {
|
805
|
-
sortable[plugin.pluginName][eventNameGlobal](_objectSpread2({
|
806
|
-
sortable: sortable
|
807
|
-
}, evt));
|
808
|
-
} // Only fire plugin event if plugin is enabled in this sortable,
|
809
|
-
// and plugin has event defined
|
810
|
-
|
811
|
-
|
812
|
-
if (sortable.options[plugin.pluginName] && sortable[plugin.pluginName][eventName]) {
|
813
|
-
sortable[plugin.pluginName][eventName](_objectSpread2({
|
814
|
-
sortable: sortable
|
815
|
-
}, evt));
|
816
|
-
}
|
817
|
-
});
|
818
|
-
},
|
819
|
-
initializePlugins: function initializePlugins(sortable, el, defaults, options) {
|
820
|
-
plugins.forEach(function (plugin) {
|
821
|
-
var pluginName = plugin.pluginName;
|
822
|
-
if (!sortable.options[pluginName] && !plugin.initializeByDefault) return;
|
823
|
-
var initialized = new plugin(sortable, el, sortable.options);
|
824
|
-
initialized.sortable = sortable;
|
825
|
-
initialized.options = sortable.options;
|
826
|
-
sortable[pluginName] = initialized; // Add default options from plugin
|
827
|
-
|
828
|
-
_extends(defaults, initialized.defaults);
|
829
|
-
});
|
830
|
-
|
831
|
-
for (var option in sortable.options) {
|
832
|
-
if (!sortable.options.hasOwnProperty(option)) continue;
|
833
|
-
var modified = this.modifyOption(sortable, option, sortable.options[option]);
|
834
|
-
|
835
|
-
if (typeof modified !== 'undefined') {
|
836
|
-
sortable.options[option] = modified;
|
837
|
-
}
|
838
|
-
}
|
839
|
-
},
|
840
|
-
getEventProperties: function getEventProperties(name, sortable) {
|
841
|
-
var eventProperties = {};
|
842
|
-
plugins.forEach(function (plugin) {
|
843
|
-
if (typeof plugin.eventProperties !== 'function') return;
|
844
|
-
|
845
|
-
_extends(eventProperties, plugin.eventProperties.call(sortable[plugin.pluginName], name));
|
846
|
-
});
|
847
|
-
return eventProperties;
|
848
|
-
},
|
849
|
-
modifyOption: function modifyOption(sortable, name, value) {
|
850
|
-
var modifiedValue;
|
851
|
-
plugins.forEach(function (plugin) {
|
852
|
-
// Plugin must exist on the Sortable
|
853
|
-
if (!sortable[plugin.pluginName]) return; // If static option listener exists for this option, call in the context of the Sortable's instance of this plugin
|
854
|
-
|
855
|
-
if (plugin.optionListeners && typeof plugin.optionListeners[name] === 'function') {
|
856
|
-
modifiedValue = plugin.optionListeners[name].call(sortable[plugin.pluginName], value);
|
857
|
-
}
|
858
|
-
});
|
859
|
-
return modifiedValue;
|
860
|
-
}
|
861
|
-
};
|
862
|
-
|
863
|
-
function dispatchEvent(_ref) {
|
864
|
-
var sortable = _ref.sortable,
|
865
|
-
rootEl = _ref.rootEl,
|
866
|
-
name = _ref.name,
|
867
|
-
targetEl = _ref.targetEl,
|
868
|
-
cloneEl = _ref.cloneEl,
|
869
|
-
toEl = _ref.toEl,
|
870
|
-
fromEl = _ref.fromEl,
|
871
|
-
oldIndex = _ref.oldIndex,
|
872
|
-
newIndex = _ref.newIndex,
|
873
|
-
oldDraggableIndex = _ref.oldDraggableIndex,
|
874
|
-
newDraggableIndex = _ref.newDraggableIndex,
|
875
|
-
originalEvent = _ref.originalEvent,
|
876
|
-
putSortable = _ref.putSortable,
|
877
|
-
extraEventProperties = _ref.extraEventProperties;
|
878
|
-
sortable = sortable || rootEl && rootEl[expando];
|
879
|
-
if (!sortable) return;
|
880
|
-
var evt,
|
881
|
-
options = sortable.options,
|
882
|
-
onName = 'on' + name.charAt(0).toUpperCase() + name.substr(1); // Support for new CustomEvent feature
|
883
|
-
|
884
|
-
if (window.CustomEvent && !IE11OrLess && !Edge) {
|
885
|
-
evt = new CustomEvent(name, {
|
886
|
-
bubbles: true,
|
887
|
-
cancelable: true
|
888
|
-
});
|
889
|
-
} else {
|
890
|
-
evt = document.createEvent('Event');
|
891
|
-
evt.initEvent(name, true, true);
|
892
|
-
}
|
893
|
-
|
894
|
-
evt.to = toEl || rootEl;
|
895
|
-
evt.from = fromEl || rootEl;
|
896
|
-
evt.item = targetEl || rootEl;
|
897
|
-
evt.clone = cloneEl;
|
898
|
-
evt.oldIndex = oldIndex;
|
899
|
-
evt.newIndex = newIndex;
|
900
|
-
evt.oldDraggableIndex = oldDraggableIndex;
|
901
|
-
evt.newDraggableIndex = newDraggableIndex;
|
902
|
-
evt.originalEvent = originalEvent;
|
903
|
-
evt.pullMode = putSortable ? putSortable.lastPutMode : undefined;
|
904
|
-
|
905
|
-
var allEventProperties = _objectSpread2(_objectSpread2({}, extraEventProperties), PluginManager.getEventProperties(name, sortable));
|
906
|
-
|
907
|
-
for (var option in allEventProperties) {
|
908
|
-
evt[option] = allEventProperties[option];
|
909
|
-
}
|
910
|
-
|
911
|
-
if (rootEl) {
|
912
|
-
rootEl.dispatchEvent(evt);
|
913
|
-
}
|
914
|
-
|
915
|
-
if (options[onName]) {
|
916
|
-
options[onName].call(sortable, evt);
|
917
|
-
}
|
918
|
-
}
|
919
|
-
|
920
|
-
var _excluded = ["evt"];
|
921
|
-
|
922
|
-
var pluginEvent = function pluginEvent(eventName, sortable) {
|
923
|
-
var _ref = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {},
|
924
|
-
originalEvent = _ref.evt,
|
925
|
-
data = _objectWithoutProperties(_ref, _excluded);
|
926
|
-
|
927
|
-
PluginManager.pluginEvent.bind(Sortable)(eventName, sortable, _objectSpread2({
|
928
|
-
dragEl: dragEl,
|
929
|
-
parentEl: parentEl,
|
930
|
-
ghostEl: ghostEl,
|
931
|
-
rootEl: rootEl,
|
932
|
-
nextEl: nextEl,
|
933
|
-
lastDownEl: lastDownEl,
|
934
|
-
cloneEl: cloneEl,
|
935
|
-
cloneHidden: cloneHidden,
|
936
|
-
dragStarted: moved,
|
937
|
-
putSortable: putSortable,
|
938
|
-
activeSortable: Sortable.active,
|
939
|
-
originalEvent: originalEvent,
|
940
|
-
oldIndex: oldIndex,
|
941
|
-
oldDraggableIndex: oldDraggableIndex,
|
942
|
-
newIndex: newIndex,
|
943
|
-
newDraggableIndex: newDraggableIndex,
|
944
|
-
hideGhostForTarget: _hideGhostForTarget,
|
945
|
-
unhideGhostForTarget: _unhideGhostForTarget,
|
946
|
-
cloneNowHidden: function cloneNowHidden() {
|
947
|
-
cloneHidden = true;
|
948
|
-
},
|
949
|
-
cloneNowShown: function cloneNowShown() {
|
950
|
-
cloneHidden = false;
|
951
|
-
},
|
952
|
-
dispatchSortableEvent: function dispatchSortableEvent(name) {
|
953
|
-
_dispatchEvent({
|
954
|
-
sortable: sortable,
|
955
|
-
name: name,
|
956
|
-
originalEvent: originalEvent
|
957
|
-
});
|
958
|
-
}
|
959
|
-
}, data));
|
960
|
-
};
|
961
|
-
|
962
|
-
function _dispatchEvent(info) {
|
963
|
-
dispatchEvent(_objectSpread2({
|
964
|
-
putSortable: putSortable,
|
965
|
-
cloneEl: cloneEl,
|
966
|
-
targetEl: dragEl,
|
967
|
-
rootEl: rootEl,
|
968
|
-
oldIndex: oldIndex,
|
969
|
-
oldDraggableIndex: oldDraggableIndex,
|
970
|
-
newIndex: newIndex,
|
971
|
-
newDraggableIndex: newDraggableIndex
|
972
|
-
}, info));
|
973
|
-
}
|
974
|
-
|
975
|
-
var dragEl,
|
976
|
-
parentEl,
|
977
|
-
ghostEl,
|
978
|
-
rootEl,
|
979
|
-
nextEl,
|
980
|
-
lastDownEl,
|
981
|
-
cloneEl,
|
982
|
-
cloneHidden,
|
983
|
-
oldIndex,
|
984
|
-
newIndex,
|
985
|
-
oldDraggableIndex,
|
986
|
-
newDraggableIndex,
|
987
|
-
activeGroup,
|
988
|
-
putSortable,
|
989
|
-
awaitingDragStarted = false,
|
990
|
-
ignoreNextClick = false,
|
991
|
-
sortables = [],
|
992
|
-
tapEvt,
|
993
|
-
touchEvt,
|
994
|
-
lastDx,
|
995
|
-
lastDy,
|
996
|
-
tapDistanceLeft,
|
997
|
-
tapDistanceTop,
|
998
|
-
moved,
|
999
|
-
lastTarget,
|
1000
|
-
lastDirection,
|
1001
|
-
pastFirstInvertThresh = false,
|
1002
|
-
isCircumstantialInvert = false,
|
1003
|
-
targetMoveDistance,
|
1004
|
-
// For positioning ghost absolutely
|
1005
|
-
ghostRelativeParent,
|
1006
|
-
ghostRelativeParentInitialScroll = [],
|
1007
|
-
// (left, top)
|
1008
|
-
_silent = false,
|
1009
|
-
savedInputChecked = [];
|
1010
|
-
/** @const */
|
1011
|
-
|
1012
|
-
var documentExists = typeof document !== 'undefined',
|
1013
|
-
PositionGhostAbsolutely = IOS,
|
1014
|
-
CSSFloatProperty = Edge || IE11OrLess ? 'cssFloat' : 'float',
|
1015
|
-
// This will not pass for IE9, because IE9 DnD only works on anchors
|
1016
|
-
supportDraggable = documentExists && !ChromeForAndroid && !IOS && 'draggable' in document.createElement('div'),
|
1017
|
-
supportCssPointerEvents = function () {
|
1018
|
-
if (!documentExists) return; // false when <= IE11
|
1019
|
-
|
1020
|
-
if (IE11OrLess) {
|
1021
|
-
return false;
|
1022
|
-
}
|
1023
|
-
|
1024
|
-
var el = document.createElement('x');
|
1025
|
-
el.style.cssText = 'pointer-events:auto';
|
1026
|
-
return el.style.pointerEvents === 'auto';
|
1027
|
-
}(),
|
1028
|
-
_detectDirection = function _detectDirection(el, options) {
|
1029
|
-
var elCSS = css(el),
|
1030
|
-
elWidth = parseInt(elCSS.width) - parseInt(elCSS.paddingLeft) - parseInt(elCSS.paddingRight) - parseInt(elCSS.borderLeftWidth) - parseInt(elCSS.borderRightWidth),
|
1031
|
-
child1 = getChild(el, 0, options),
|
1032
|
-
child2 = getChild(el, 1, options),
|
1033
|
-
firstChildCSS = child1 && css(child1),
|
1034
|
-
secondChildCSS = child2 && css(child2),
|
1035
|
-
firstChildWidth = firstChildCSS && parseInt(firstChildCSS.marginLeft) + parseInt(firstChildCSS.marginRight) + getRect(child1).width,
|
1036
|
-
secondChildWidth = secondChildCSS && parseInt(secondChildCSS.marginLeft) + parseInt(secondChildCSS.marginRight) + getRect(child2).width;
|
1037
|
-
|
1038
|
-
if (elCSS.display === 'flex') {
|
1039
|
-
return elCSS.flexDirection === 'column' || elCSS.flexDirection === 'column-reverse' ? 'vertical' : 'horizontal';
|
1040
|
-
}
|
1041
|
-
|
1042
|
-
if (elCSS.display === 'grid') {
|
1043
|
-
return elCSS.gridTemplateColumns.split(' ').length <= 1 ? 'vertical' : 'horizontal';
|
1044
|
-
}
|
1045
|
-
|
1046
|
-
if (child1 && firstChildCSS["float"] && firstChildCSS["float"] !== 'none') {
|
1047
|
-
var touchingSideChild2 = firstChildCSS["float"] === 'left' ? 'left' : 'right';
|
1048
|
-
return child2 && (secondChildCSS.clear === 'both' || secondChildCSS.clear === touchingSideChild2) ? 'vertical' : 'horizontal';
|
1049
|
-
}
|
1050
|
-
|
1051
|
-
return child1 && (firstChildCSS.display === 'block' || firstChildCSS.display === 'flex' || firstChildCSS.display === 'table' || firstChildCSS.display === 'grid' || firstChildWidth >= elWidth && elCSS[CSSFloatProperty] === 'none' || child2 && elCSS[CSSFloatProperty] === 'none' && firstChildWidth + secondChildWidth > elWidth) ? 'vertical' : 'horizontal';
|
1052
|
-
},
|
1053
|
-
_dragElInRowColumn = function _dragElInRowColumn(dragRect, targetRect, vertical) {
|
1054
|
-
var dragElS1Opp = vertical ? dragRect.left : dragRect.top,
|
1055
|
-
dragElS2Opp = vertical ? dragRect.right : dragRect.bottom,
|
1056
|
-
dragElOppLength = vertical ? dragRect.width : dragRect.height,
|
1057
|
-
targetS1Opp = vertical ? targetRect.left : targetRect.top,
|
1058
|
-
targetS2Opp = vertical ? targetRect.right : targetRect.bottom,
|
1059
|
-
targetOppLength = vertical ? targetRect.width : targetRect.height;
|
1060
|
-
return dragElS1Opp === targetS1Opp || dragElS2Opp === targetS2Opp || dragElS1Opp + dragElOppLength / 2 === targetS1Opp + targetOppLength / 2;
|
1061
|
-
},
|
1062
|
-
|
1063
|
-
/**
|
1064
|
-
* Detects first nearest empty sortable to X and Y position using emptyInsertThreshold.
|
1065
|
-
* @param {Number} x X position
|
1066
|
-
* @param {Number} y Y position
|
1067
|
-
* @return {HTMLElement} Element of the first found nearest Sortable
|
1068
|
-
*/
|
1069
|
-
_detectNearestEmptySortable = function _detectNearestEmptySortable(x, y) {
|
1070
|
-
var ret;
|
1071
|
-
sortables.some(function (sortable) {
|
1072
|
-
var threshold = sortable[expando].options.emptyInsertThreshold;
|
1073
|
-
if (!threshold || lastChild(sortable)) return;
|
1074
|
-
var rect = getRect(sortable),
|
1075
|
-
insideHorizontally = x >= rect.left - threshold && x <= rect.right + threshold,
|
1076
|
-
insideVertically = y >= rect.top - threshold && y <= rect.bottom + threshold;
|
1077
|
-
|
1078
|
-
if (insideHorizontally && insideVertically) {
|
1079
|
-
return ret = sortable;
|
1080
|
-
}
|
1081
|
-
});
|
1082
|
-
return ret;
|
1083
|
-
},
|
1084
|
-
_prepareGroup = function _prepareGroup(options) {
|
1085
|
-
function toFn(value, pull) {
|
1086
|
-
return function (to, from, dragEl, evt) {
|
1087
|
-
var sameGroup = to.options.group.name && from.options.group.name && to.options.group.name === from.options.group.name;
|
1088
|
-
|
1089
|
-
if (value == null && (pull || sameGroup)) {
|
1090
|
-
// Default pull value
|
1091
|
-
// Default pull and put value if same group
|
1092
|
-
return true;
|
1093
|
-
} else if (value == null || value === false) {
|
1094
|
-
return false;
|
1095
|
-
} else if (pull && value === 'clone') {
|
1096
|
-
return value;
|
1097
|
-
} else if (typeof value === 'function') {
|
1098
|
-
return toFn(value(to, from, dragEl, evt), pull)(to, from, dragEl, evt);
|
1099
|
-
} else {
|
1100
|
-
var otherGroup = (pull ? to : from).options.group.name;
|
1101
|
-
return value === true || typeof value === 'string' && value === otherGroup || value.join && value.indexOf(otherGroup) > -1;
|
1102
|
-
}
|
1103
|
-
};
|
1104
|
-
}
|
1105
|
-
|
1106
|
-
var group = {};
|
1107
|
-
var originalGroup = options.group;
|
1108
|
-
|
1109
|
-
if (!originalGroup || _typeof(originalGroup) != 'object') {
|
1110
|
-
originalGroup = {
|
1111
|
-
name: originalGroup
|
1112
|
-
};
|
1113
|
-
}
|
1114
|
-
|
1115
|
-
group.name = originalGroup.name;
|
1116
|
-
group.checkPull = toFn(originalGroup.pull, true);
|
1117
|
-
group.checkPut = toFn(originalGroup.put);
|
1118
|
-
group.revertClone = originalGroup.revertClone;
|
1119
|
-
options.group = group;
|
1120
|
-
},
|
1121
|
-
_hideGhostForTarget = function _hideGhostForTarget() {
|
1122
|
-
if (!supportCssPointerEvents && ghostEl) {
|
1123
|
-
css(ghostEl, 'display', 'none');
|
1124
|
-
}
|
1125
|
-
},
|
1126
|
-
_unhideGhostForTarget = function _unhideGhostForTarget() {
|
1127
|
-
if (!supportCssPointerEvents && ghostEl) {
|
1128
|
-
css(ghostEl, 'display', '');
|
1129
|
-
}
|
1130
|
-
}; // #1184 fix - Prevent click event on fallback if dragged but item not changed position
|
1131
|
-
|
1132
|
-
|
1133
|
-
if (documentExists && !ChromeForAndroid) {
|
1134
|
-
document.addEventListener('click', function (evt) {
|
1135
|
-
if (ignoreNextClick) {
|
1136
|
-
evt.preventDefault();
|
1137
|
-
evt.stopPropagation && evt.stopPropagation();
|
1138
|
-
evt.stopImmediatePropagation && evt.stopImmediatePropagation();
|
1139
|
-
ignoreNextClick = false;
|
1140
|
-
return false;
|
1141
|
-
}
|
1142
|
-
}, true);
|
1143
|
-
}
|
1144
|
-
|
1145
|
-
var nearestEmptyInsertDetectEvent = function nearestEmptyInsertDetectEvent(evt) {
|
1146
|
-
if (dragEl) {
|
1147
|
-
evt = evt.touches ? evt.touches[0] : evt;
|
1148
|
-
|
1149
|
-
var nearest = _detectNearestEmptySortable(evt.clientX, evt.clientY);
|
1150
|
-
|
1151
|
-
if (nearest) {
|
1152
|
-
// Create imitation event
|
1153
|
-
var event = {};
|
1154
|
-
|
1155
|
-
for (var i in evt) {
|
1156
|
-
if (evt.hasOwnProperty(i)) {
|
1157
|
-
event[i] = evt[i];
|
1158
|
-
}
|
1159
|
-
}
|
1160
|
-
|
1161
|
-
event.target = event.rootEl = nearest;
|
1162
|
-
event.preventDefault = void 0;
|
1163
|
-
event.stopPropagation = void 0;
|
1164
|
-
|
1165
|
-
nearest[expando]._onDragOver(event);
|
1166
|
-
}
|
1167
|
-
}
|
1168
|
-
};
|
1169
|
-
|
1170
|
-
var _checkOutsideTargetEl = function _checkOutsideTargetEl(evt) {
|
1171
|
-
if (dragEl) {
|
1172
|
-
dragEl.parentNode[expando]._isOutsideThisEl(evt.target);
|
1173
|
-
}
|
1174
|
-
};
|
1175
|
-
/**
|
1176
|
-
* @class Sortable
|
1177
|
-
* @param {HTMLElement} el
|
1178
|
-
* @param {Object} [options]
|
1179
|
-
*/
|
1180
|
-
|
1181
|
-
|
1182
|
-
function Sortable(el, options) {
|
1183
|
-
if (!(el && el.nodeType && el.nodeType === 1)) {
|
1184
|
-
throw "Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(el));
|
1185
|
-
}
|
1186
|
-
|
1187
|
-
this.el = el; // root element
|
1188
|
-
|
1189
|
-
this.options = options = _extends({}, options); // Export instance
|
1190
|
-
|
1191
|
-
el[expando] = this;
|
1192
|
-
var defaults = {
|
1193
|
-
group: null,
|
1194
|
-
sort: true,
|
1195
|
-
disabled: false,
|
1196
|
-
store: null,
|
1197
|
-
handle: null,
|
1198
|
-
draggable: /^[uo]l$/i.test(el.nodeName) ? '>li' : '>*',
|
1199
|
-
swapThreshold: 1,
|
1200
|
-
// percentage; 0 <= x <= 1
|
1201
|
-
invertSwap: false,
|
1202
|
-
// invert always
|
1203
|
-
invertedSwapThreshold: null,
|
1204
|
-
// will be set to same as swapThreshold if default
|
1205
|
-
removeCloneOnHide: true,
|
1206
|
-
direction: function direction() {
|
1207
|
-
return _detectDirection(el, this.options);
|
1208
|
-
},
|
1209
|
-
ghostClass: 'sortable-ghost',
|
1210
|
-
chosenClass: 'sortable-chosen',
|
1211
|
-
dragClass: 'sortable-drag',
|
1212
|
-
ignore: 'a, img',
|
1213
|
-
filter: null,
|
1214
|
-
preventOnFilter: true,
|
1215
|
-
animation: 0,
|
1216
|
-
easing: null,
|
1217
|
-
setData: function setData(dataTransfer, dragEl) {
|
1218
|
-
dataTransfer.setData('Text', dragEl.textContent);
|
1219
|
-
},
|
1220
|
-
dropBubble: false,
|
1221
|
-
dragoverBubble: false,
|
1222
|
-
dataIdAttr: 'data-id',
|
1223
|
-
delay: 0,
|
1224
|
-
delayOnTouchOnly: false,
|
1225
|
-
touchStartThreshold: (Number.parseInt ? Number : window).parseInt(window.devicePixelRatio, 10) || 1,
|
1226
|
-
forceFallback: false,
|
1227
|
-
fallbackClass: 'sortable-fallback',
|
1228
|
-
fallbackOnBody: false,
|
1229
|
-
fallbackTolerance: 0,
|
1230
|
-
fallbackOffset: {
|
1231
|
-
x: 0,
|
1232
|
-
y: 0
|
1233
|
-
},
|
1234
|
-
supportPointer: Sortable.supportPointer !== false && 'PointerEvent' in window && !Safari,
|
1235
|
-
emptyInsertThreshold: 5
|
1236
|
-
};
|
1237
|
-
PluginManager.initializePlugins(this, el, defaults); // Set default options
|
1238
|
-
|
1239
|
-
for (var name in defaults) {
|
1240
|
-
!(name in options) && (options[name] = defaults[name]);
|
1241
|
-
}
|
1242
|
-
|
1243
|
-
_prepareGroup(options); // Bind all private methods
|
1244
|
-
|
1245
|
-
|
1246
|
-
for (var fn in this) {
|
1247
|
-
if (fn.charAt(0) === '_' && typeof this[fn] === 'function') {
|
1248
|
-
this[fn] = this[fn].bind(this);
|
1249
|
-
}
|
1250
|
-
} // Setup drag mode
|
1251
|
-
|
1252
|
-
|
1253
|
-
this.nativeDraggable = options.forceFallback ? false : supportDraggable;
|
1254
|
-
|
1255
|
-
if (this.nativeDraggable) {
|
1256
|
-
// Touch start threshold cannot be greater than the native dragstart threshold
|
1257
|
-
this.options.touchStartThreshold = 1;
|
1258
|
-
} // Bind events
|
1259
|
-
|
1260
|
-
|
1261
|
-
if (options.supportPointer) {
|
1262
|
-
on(el, 'pointerdown', this._onTapStart);
|
1263
|
-
} else {
|
1264
|
-
on(el, 'mousedown', this._onTapStart);
|
1265
|
-
on(el, 'touchstart', this._onTapStart);
|
1266
|
-
}
|
1267
|
-
|
1268
|
-
if (this.nativeDraggable) {
|
1269
|
-
on(el, 'dragover', this);
|
1270
|
-
on(el, 'dragenter', this);
|
1271
|
-
}
|
1272
|
-
|
1273
|
-
sortables.push(this.el); // Restore sorting
|
1274
|
-
|
1275
|
-
options.store && options.store.get && this.sort(options.store.get(this) || []); // Add animation state manager
|
1276
|
-
|
1277
|
-
_extends(this, AnimationStateManager());
|
1278
|
-
}
|
1279
|
-
|
1280
|
-
Sortable.prototype =
|
1281
|
-
/** @lends Sortable.prototype */
|
1282
|
-
{
|
1283
|
-
constructor: Sortable,
|
1284
|
-
_isOutsideThisEl: function _isOutsideThisEl(target) {
|
1285
|
-
if (!this.el.contains(target) && target !== this.el) {
|
1286
|
-
lastTarget = null;
|
1287
|
-
}
|
1288
|
-
},
|
1289
|
-
_getDirection: function _getDirection(evt, target) {
|
1290
|
-
return typeof this.options.direction === 'function' ? this.options.direction.call(this, evt, target, dragEl) : this.options.direction;
|
1291
|
-
},
|
1292
|
-
_onTapStart: function _onTapStart(
|
1293
|
-
/** Event|TouchEvent */
|
1294
|
-
evt) {
|
1295
|
-
if (!evt.cancelable) return;
|
1296
|
-
|
1297
|
-
var _this = this,
|
1298
|
-
el = this.el,
|
1299
|
-
options = this.options,
|
1300
|
-
preventOnFilter = options.preventOnFilter,
|
1301
|
-
type = evt.type,
|
1302
|
-
touch = evt.touches && evt.touches[0] || evt.pointerType && evt.pointerType === 'touch' && evt,
|
1303
|
-
target = (touch || evt).target,
|
1304
|
-
originalTarget = evt.target.shadowRoot && (evt.path && evt.path[0] || evt.composedPath && evt.composedPath()[0]) || target,
|
1305
|
-
filter = options.filter;
|
1306
|
-
|
1307
|
-
_saveInputCheckedState(el); // Don't trigger start event when an element is been dragged, otherwise the evt.oldindex always wrong when set option.group.
|
1308
|
-
|
1309
|
-
|
1310
|
-
if (dragEl) {
|
1311
|
-
return;
|
1312
|
-
}
|
1313
|
-
|
1314
|
-
if (/mousedown|pointerdown/.test(type) && evt.button !== 0 || options.disabled) {
|
1315
|
-
return; // only left button and enabled
|
1316
|
-
} // cancel dnd if original target is content editable
|
1317
|
-
|
1318
|
-
|
1319
|
-
if (originalTarget.isContentEditable) {
|
1320
|
-
return;
|
1321
|
-
} // Safari ignores further event handling after mousedown
|
1322
|
-
|
1323
|
-
|
1324
|
-
if (!this.nativeDraggable && Safari && target && target.tagName.toUpperCase() === 'SELECT') {
|
1325
|
-
return;
|
1326
|
-
}
|
1327
|
-
|
1328
|
-
target = closest(target, options.draggable, el, false);
|
1329
|
-
|
1330
|
-
if (target && target.animated) {
|
1331
|
-
return;
|
1332
|
-
}
|
1333
|
-
|
1334
|
-
if (lastDownEl === target) {
|
1335
|
-
// Ignoring duplicate `down`
|
1336
|
-
return;
|
1337
|
-
} // Get the index of the dragged element within its parent
|
1338
|
-
|
1339
|
-
|
1340
|
-
oldIndex = index(target);
|
1341
|
-
oldDraggableIndex = index(target, options.draggable); // Check filter
|
1342
|
-
|
1343
|
-
if (typeof filter === 'function') {
|
1344
|
-
if (filter.call(this, evt, target, this)) {
|
1345
|
-
_dispatchEvent({
|
1346
|
-
sortable: _this,
|
1347
|
-
rootEl: originalTarget,
|
1348
|
-
name: 'filter',
|
1349
|
-
targetEl: target,
|
1350
|
-
toEl: el,
|
1351
|
-
fromEl: el
|
1352
|
-
});
|
1353
|
-
|
1354
|
-
pluginEvent('filter', _this, {
|
1355
|
-
evt: evt
|
1356
|
-
});
|
1357
|
-
preventOnFilter && evt.cancelable && evt.preventDefault();
|
1358
|
-
return; // cancel dnd
|
1359
|
-
}
|
1360
|
-
} else if (filter) {
|
1361
|
-
filter = filter.split(',').some(function (criteria) {
|
1362
|
-
criteria = closest(originalTarget, criteria.trim(), el, false);
|
1363
|
-
|
1364
|
-
if (criteria) {
|
1365
|
-
_dispatchEvent({
|
1366
|
-
sortable: _this,
|
1367
|
-
rootEl: criteria,
|
1368
|
-
name: 'filter',
|
1369
|
-
targetEl: target,
|
1370
|
-
fromEl: el,
|
1371
|
-
toEl: el
|
1372
|
-
});
|
1373
|
-
|
1374
|
-
pluginEvent('filter', _this, {
|
1375
|
-
evt: evt
|
1376
|
-
});
|
1377
|
-
return true;
|
1378
|
-
}
|
1379
|
-
});
|
1380
|
-
|
1381
|
-
if (filter) {
|
1382
|
-
preventOnFilter && evt.cancelable && evt.preventDefault();
|
1383
|
-
return; // cancel dnd
|
1384
|
-
}
|
1385
|
-
}
|
1386
|
-
|
1387
|
-
if (options.handle && !closest(originalTarget, options.handle, el, false)) {
|
1388
|
-
return;
|
1389
|
-
} // Prepare `dragstart`
|
1390
|
-
|
1391
|
-
|
1392
|
-
this._prepareDragStart(evt, touch, target);
|
1393
|
-
},
|
1394
|
-
_prepareDragStart: function _prepareDragStart(
|
1395
|
-
/** Event */
|
1396
|
-
evt,
|
1397
|
-
/** Touch */
|
1398
|
-
touch,
|
1399
|
-
/** HTMLElement */
|
1400
|
-
target) {
|
1401
|
-
var _this = this,
|
1402
|
-
el = _this.el,
|
1403
|
-
options = _this.options,
|
1404
|
-
ownerDocument = el.ownerDocument,
|
1405
|
-
dragStartFn;
|
1406
|
-
|
1407
|
-
if (target && !dragEl && target.parentNode === el) {
|
1408
|
-
var dragRect = getRect(target);
|
1409
|
-
rootEl = el;
|
1410
|
-
dragEl = target;
|
1411
|
-
parentEl = dragEl.parentNode;
|
1412
|
-
nextEl = dragEl.nextSibling;
|
1413
|
-
lastDownEl = target;
|
1414
|
-
activeGroup = options.group;
|
1415
|
-
Sortable.dragged = dragEl;
|
1416
|
-
tapEvt = {
|
1417
|
-
target: dragEl,
|
1418
|
-
clientX: (touch || evt).clientX,
|
1419
|
-
clientY: (touch || evt).clientY
|
1420
|
-
};
|
1421
|
-
tapDistanceLeft = tapEvt.clientX - dragRect.left;
|
1422
|
-
tapDistanceTop = tapEvt.clientY - dragRect.top;
|
1423
|
-
this._lastX = (touch || evt).clientX;
|
1424
|
-
this._lastY = (touch || evt).clientY;
|
1425
|
-
dragEl.style['will-change'] = 'all';
|
1426
|
-
|
1427
|
-
dragStartFn = function dragStartFn() {
|
1428
|
-
pluginEvent('delayEnded', _this, {
|
1429
|
-
evt: evt
|
1430
|
-
});
|
1431
|
-
|
1432
|
-
if (Sortable.eventCanceled) {
|
1433
|
-
_this._onDrop();
|
1434
|
-
|
1435
|
-
return;
|
1436
|
-
} // Delayed drag has been triggered
|
1437
|
-
// we can re-enable the events: touchmove/mousemove
|
1438
|
-
|
1439
|
-
|
1440
|
-
_this._disableDelayedDragEvents();
|
1441
|
-
|
1442
|
-
if (!FireFox && _this.nativeDraggable) {
|
1443
|
-
dragEl.draggable = true;
|
1444
|
-
} // Bind the events: dragstart/dragend
|
1445
|
-
|
1446
|
-
|
1447
|
-
_this._triggerDragStart(evt, touch); // Drag start event
|
1448
|
-
|
1449
|
-
|
1450
|
-
_dispatchEvent({
|
1451
|
-
sortable: _this,
|
1452
|
-
name: 'choose',
|
1453
|
-
originalEvent: evt
|
1454
|
-
}); // Chosen item
|
1455
|
-
|
1456
|
-
|
1457
|
-
toggleClass(dragEl, options.chosenClass, true);
|
1458
|
-
}; // Disable "draggable"
|
1459
|
-
|
1460
|
-
|
1461
|
-
options.ignore.split(',').forEach(function (criteria) {
|
1462
|
-
find(dragEl, criteria.trim(), _disableDraggable);
|
1463
|
-
});
|
1464
|
-
on(ownerDocument, 'dragover', nearestEmptyInsertDetectEvent);
|
1465
|
-
on(ownerDocument, 'mousemove', nearestEmptyInsertDetectEvent);
|
1466
|
-
on(ownerDocument, 'touchmove', nearestEmptyInsertDetectEvent);
|
1467
|
-
on(ownerDocument, 'mouseup', _this._onDrop);
|
1468
|
-
on(ownerDocument, 'touchend', _this._onDrop);
|
1469
|
-
on(ownerDocument, 'touchcancel', _this._onDrop); // Make dragEl draggable (must be before delay for FireFox)
|
1470
|
-
|
1471
|
-
if (FireFox && this.nativeDraggable) {
|
1472
|
-
this.options.touchStartThreshold = 4;
|
1473
|
-
dragEl.draggable = true;
|
1474
|
-
}
|
1475
|
-
|
1476
|
-
pluginEvent('delayStart', this, {
|
1477
|
-
evt: evt
|
1478
|
-
}); // Delay is impossible for native DnD in Edge or IE
|
1479
|
-
|
1480
|
-
if (options.delay && (!options.delayOnTouchOnly || touch) && (!this.nativeDraggable || !(Edge || IE11OrLess))) {
|
1481
|
-
if (Sortable.eventCanceled) {
|
1482
|
-
this._onDrop();
|
1483
|
-
|
1484
|
-
return;
|
1485
|
-
} // If the user moves the pointer or let go the click or touch
|
1486
|
-
// before the delay has been reached:
|
1487
|
-
// disable the delayed drag
|
1488
|
-
|
1489
|
-
|
1490
|
-
on(ownerDocument, 'mouseup', _this._disableDelayedDrag);
|
1491
|
-
on(ownerDocument, 'touchend', _this._disableDelayedDrag);
|
1492
|
-
on(ownerDocument, 'touchcancel', _this._disableDelayedDrag);
|
1493
|
-
on(ownerDocument, 'mousemove', _this._delayedDragTouchMoveHandler);
|
1494
|
-
on(ownerDocument, 'touchmove', _this._delayedDragTouchMoveHandler);
|
1495
|
-
options.supportPointer && on(ownerDocument, 'pointermove', _this._delayedDragTouchMoveHandler);
|
1496
|
-
_this._dragStartTimer = setTimeout(dragStartFn, options.delay);
|
1497
|
-
} else {
|
1498
|
-
dragStartFn();
|
1499
|
-
}
|
1500
|
-
}
|
1501
|
-
},
|
1502
|
-
_delayedDragTouchMoveHandler: function _delayedDragTouchMoveHandler(
|
1503
|
-
/** TouchEvent|PointerEvent **/
|
1504
|
-
e) {
|
1505
|
-
var touch = e.touches ? e.touches[0] : e;
|
1506
|
-
|
1507
|
-
if (Math.max(Math.abs(touch.clientX - this._lastX), Math.abs(touch.clientY - this._lastY)) >= Math.floor(this.options.touchStartThreshold / (this.nativeDraggable && window.devicePixelRatio || 1))) {
|
1508
|
-
this._disableDelayedDrag();
|
1509
|
-
}
|
1510
|
-
},
|
1511
|
-
_disableDelayedDrag: function _disableDelayedDrag() {
|
1512
|
-
dragEl && _disableDraggable(dragEl);
|
1513
|
-
clearTimeout(this._dragStartTimer);
|
1514
|
-
|
1515
|
-
this._disableDelayedDragEvents();
|
1516
|
-
},
|
1517
|
-
_disableDelayedDragEvents: function _disableDelayedDragEvents() {
|
1518
|
-
var ownerDocument = this.el.ownerDocument;
|
1519
|
-
off(ownerDocument, 'mouseup', this._disableDelayedDrag);
|
1520
|
-
off(ownerDocument, 'touchend', this._disableDelayedDrag);
|
1521
|
-
off(ownerDocument, 'touchcancel', this._disableDelayedDrag);
|
1522
|
-
off(ownerDocument, 'mousemove', this._delayedDragTouchMoveHandler);
|
1523
|
-
off(ownerDocument, 'touchmove', this._delayedDragTouchMoveHandler);
|
1524
|
-
off(ownerDocument, 'pointermove', this._delayedDragTouchMoveHandler);
|
1525
|
-
},
|
1526
|
-
_triggerDragStart: function _triggerDragStart(
|
1527
|
-
/** Event */
|
1528
|
-
evt,
|
1529
|
-
/** Touch */
|
1530
|
-
touch) {
|
1531
|
-
touch = touch || evt.pointerType == 'touch' && evt;
|
1532
|
-
|
1533
|
-
if (!this.nativeDraggable || touch) {
|
1534
|
-
if (this.options.supportPointer) {
|
1535
|
-
on(document, 'pointermove', this._onTouchMove);
|
1536
|
-
} else if (touch) {
|
1537
|
-
on(document, 'touchmove', this._onTouchMove);
|
1538
|
-
} else {
|
1539
|
-
on(document, 'mousemove', this._onTouchMove);
|
1540
|
-
}
|
1541
|
-
} else {
|
1542
|
-
on(dragEl, 'dragend', this);
|
1543
|
-
on(rootEl, 'dragstart', this._onDragStart);
|
1544
|
-
}
|
1545
|
-
|
1546
|
-
try {
|
1547
|
-
if (document.selection) {
|
1548
|
-
// Timeout neccessary for IE9
|
1549
|
-
_nextTick(function () {
|
1550
|
-
document.selection.empty();
|
1551
|
-
});
|
1552
|
-
} else {
|
1553
|
-
window.getSelection().removeAllRanges();
|
1554
|
-
}
|
1555
|
-
} catch (err) {}
|
1556
|
-
},
|
1557
|
-
_dragStarted: function _dragStarted(fallback, evt) {
|
1558
|
-
|
1559
|
-
awaitingDragStarted = false;
|
1560
|
-
|
1561
|
-
if (rootEl && dragEl) {
|
1562
|
-
pluginEvent('dragStarted', this, {
|
1563
|
-
evt: evt
|
1564
|
-
});
|
1565
|
-
|
1566
|
-
if (this.nativeDraggable) {
|
1567
|
-
on(document, 'dragover', _checkOutsideTargetEl);
|
1568
|
-
}
|
1569
|
-
|
1570
|
-
var options = this.options; // Apply effect
|
1571
|
-
|
1572
|
-
!fallback && toggleClass(dragEl, options.dragClass, false);
|
1573
|
-
toggleClass(dragEl, options.ghostClass, true);
|
1574
|
-
Sortable.active = this;
|
1575
|
-
fallback && this._appendGhost(); // Drag start event
|
1576
|
-
|
1577
|
-
_dispatchEvent({
|
1578
|
-
sortable: this,
|
1579
|
-
name: 'start',
|
1580
|
-
originalEvent: evt
|
1581
|
-
});
|
1582
|
-
} else {
|
1583
|
-
this._nulling();
|
1584
|
-
}
|
1585
|
-
},
|
1586
|
-
_emulateDragOver: function _emulateDragOver() {
|
1587
|
-
if (touchEvt) {
|
1588
|
-
this._lastX = touchEvt.clientX;
|
1589
|
-
this._lastY = touchEvt.clientY;
|
1590
|
-
|
1591
|
-
_hideGhostForTarget();
|
1592
|
-
|
1593
|
-
var target = document.elementFromPoint(touchEvt.clientX, touchEvt.clientY);
|
1594
|
-
var parent = target;
|
1595
|
-
|
1596
|
-
while (target && target.shadowRoot) {
|
1597
|
-
target = target.shadowRoot.elementFromPoint(touchEvt.clientX, touchEvt.clientY);
|
1598
|
-
if (target === parent) break;
|
1599
|
-
parent = target;
|
1600
|
-
}
|
1601
|
-
|
1602
|
-
dragEl.parentNode[expando]._isOutsideThisEl(target);
|
1603
|
-
|
1604
|
-
if (parent) {
|
1605
|
-
do {
|
1606
|
-
if (parent[expando]) {
|
1607
|
-
var inserted = void 0;
|
1608
|
-
inserted = parent[expando]._onDragOver({
|
1609
|
-
clientX: touchEvt.clientX,
|
1610
|
-
clientY: touchEvt.clientY,
|
1611
|
-
target: target,
|
1612
|
-
rootEl: parent
|
1613
|
-
});
|
1614
|
-
|
1615
|
-
if (inserted && !this.options.dragoverBubble) {
|
1616
|
-
break;
|
1617
|
-
}
|
1618
|
-
}
|
1619
|
-
|
1620
|
-
target = parent; // store last element
|
1621
|
-
}
|
1622
|
-
/* jshint boss:true */
|
1623
|
-
while (parent = parent.parentNode);
|
1624
|
-
}
|
1625
|
-
|
1626
|
-
_unhideGhostForTarget();
|
1627
|
-
}
|
1628
|
-
},
|
1629
|
-
_onTouchMove: function _onTouchMove(
|
1630
|
-
/**TouchEvent*/
|
1631
|
-
evt) {
|
1632
|
-
if (tapEvt) {
|
1633
|
-
var options = this.options,
|
1634
|
-
fallbackTolerance = options.fallbackTolerance,
|
1635
|
-
fallbackOffset = options.fallbackOffset,
|
1636
|
-
touch = evt.touches ? evt.touches[0] : evt,
|
1637
|
-
ghostMatrix = ghostEl && matrix(ghostEl, true),
|
1638
|
-
scaleX = ghostEl && ghostMatrix && ghostMatrix.a,
|
1639
|
-
scaleY = ghostEl && ghostMatrix && ghostMatrix.d,
|
1640
|
-
relativeScrollOffset = PositionGhostAbsolutely && ghostRelativeParent && getRelativeScrollOffset(ghostRelativeParent),
|
1641
|
-
dx = (touch.clientX - tapEvt.clientX + fallbackOffset.x) / (scaleX || 1) + (relativeScrollOffset ? relativeScrollOffset[0] - ghostRelativeParentInitialScroll[0] : 0) / (scaleX || 1),
|
1642
|
-
dy = (touch.clientY - tapEvt.clientY + fallbackOffset.y) / (scaleY || 1) + (relativeScrollOffset ? relativeScrollOffset[1] - ghostRelativeParentInitialScroll[1] : 0) / (scaleY || 1); // only set the status to dragging, when we are actually dragging
|
1643
|
-
|
1644
|
-
if (!Sortable.active && !awaitingDragStarted) {
|
1645
|
-
if (fallbackTolerance && Math.max(Math.abs(touch.clientX - this._lastX), Math.abs(touch.clientY - this._lastY)) < fallbackTolerance) {
|
1646
|
-
return;
|
1647
|
-
}
|
1648
|
-
|
1649
|
-
this._onDragStart(evt, true);
|
1650
|
-
}
|
1651
|
-
|
1652
|
-
if (ghostEl) {
|
1653
|
-
if (ghostMatrix) {
|
1654
|
-
ghostMatrix.e += dx - (lastDx || 0);
|
1655
|
-
ghostMatrix.f += dy - (lastDy || 0);
|
1656
|
-
} else {
|
1657
|
-
ghostMatrix = {
|
1658
|
-
a: 1,
|
1659
|
-
b: 0,
|
1660
|
-
c: 0,
|
1661
|
-
d: 1,
|
1662
|
-
e: dx,
|
1663
|
-
f: dy
|
1664
|
-
};
|
1665
|
-
}
|
1666
|
-
|
1667
|
-
var cssMatrix = "matrix(".concat(ghostMatrix.a, ",").concat(ghostMatrix.b, ",").concat(ghostMatrix.c, ",").concat(ghostMatrix.d, ",").concat(ghostMatrix.e, ",").concat(ghostMatrix.f, ")");
|
1668
|
-
css(ghostEl, 'webkitTransform', cssMatrix);
|
1669
|
-
css(ghostEl, 'mozTransform', cssMatrix);
|
1670
|
-
css(ghostEl, 'msTransform', cssMatrix);
|
1671
|
-
css(ghostEl, 'transform', cssMatrix);
|
1672
|
-
lastDx = dx;
|
1673
|
-
lastDy = dy;
|
1674
|
-
touchEvt = touch;
|
1675
|
-
}
|
1676
|
-
|
1677
|
-
evt.cancelable && evt.preventDefault();
|
1678
|
-
}
|
1679
|
-
},
|
1680
|
-
_appendGhost: function _appendGhost() {
|
1681
|
-
// Bug if using scale(): https://stackoverflow.com/questions/2637058
|
1682
|
-
// Not being adjusted for
|
1683
|
-
if (!ghostEl) {
|
1684
|
-
var container = this.options.fallbackOnBody ? document.body : rootEl,
|
1685
|
-
rect = getRect(dragEl, true, PositionGhostAbsolutely, true, container),
|
1686
|
-
options = this.options; // Position absolutely
|
1687
|
-
|
1688
|
-
if (PositionGhostAbsolutely) {
|
1689
|
-
// Get relatively positioned parent
|
1690
|
-
ghostRelativeParent = container;
|
1691
|
-
|
1692
|
-
while (css(ghostRelativeParent, 'position') === 'static' && css(ghostRelativeParent, 'transform') === 'none' && ghostRelativeParent !== document) {
|
1693
|
-
ghostRelativeParent = ghostRelativeParent.parentNode;
|
1694
|
-
}
|
1695
|
-
|
1696
|
-
if (ghostRelativeParent !== document.body && ghostRelativeParent !== document.documentElement) {
|
1697
|
-
if (ghostRelativeParent === document) ghostRelativeParent = getWindowScrollingElement();
|
1698
|
-
rect.top += ghostRelativeParent.scrollTop;
|
1699
|
-
rect.left += ghostRelativeParent.scrollLeft;
|
1700
|
-
} else {
|
1701
|
-
ghostRelativeParent = getWindowScrollingElement();
|
1702
|
-
}
|
1703
|
-
|
1704
|
-
ghostRelativeParentInitialScroll = getRelativeScrollOffset(ghostRelativeParent);
|
1705
|
-
}
|
1706
|
-
|
1707
|
-
ghostEl = dragEl.cloneNode(true);
|
1708
|
-
toggleClass(ghostEl, options.ghostClass, false);
|
1709
|
-
toggleClass(ghostEl, options.fallbackClass, true);
|
1710
|
-
toggleClass(ghostEl, options.dragClass, true);
|
1711
|
-
css(ghostEl, 'transition', '');
|
1712
|
-
css(ghostEl, 'transform', '');
|
1713
|
-
css(ghostEl, 'box-sizing', 'border-box');
|
1714
|
-
css(ghostEl, 'margin', 0);
|
1715
|
-
css(ghostEl, 'top', rect.top);
|
1716
|
-
css(ghostEl, 'left', rect.left);
|
1717
|
-
css(ghostEl, 'width', rect.width);
|
1718
|
-
css(ghostEl, 'height', rect.height);
|
1719
|
-
css(ghostEl, 'opacity', '0.8');
|
1720
|
-
css(ghostEl, 'position', PositionGhostAbsolutely ? 'absolute' : 'fixed');
|
1721
|
-
css(ghostEl, 'zIndex', '100000');
|
1722
|
-
css(ghostEl, 'pointerEvents', 'none');
|
1723
|
-
Sortable.ghost = ghostEl;
|
1724
|
-
container.appendChild(ghostEl); // Set transform-origin
|
1725
|
-
|
1726
|
-
css(ghostEl, 'transform-origin', tapDistanceLeft / parseInt(ghostEl.style.width) * 100 + '% ' + tapDistanceTop / parseInt(ghostEl.style.height) * 100 + '%');
|
1727
|
-
}
|
1728
|
-
},
|
1729
|
-
_onDragStart: function _onDragStart(
|
1730
|
-
/**Event*/
|
1731
|
-
evt,
|
1732
|
-
/**boolean*/
|
1733
|
-
fallback) {
|
1734
|
-
var _this = this;
|
1735
|
-
|
1736
|
-
var dataTransfer = evt.dataTransfer;
|
1737
|
-
var options = _this.options;
|
1738
|
-
pluginEvent('dragStart', this, {
|
1739
|
-
evt: evt
|
1740
|
-
});
|
1741
|
-
|
1742
|
-
if (Sortable.eventCanceled) {
|
1743
|
-
this._onDrop();
|
1744
|
-
|
1745
|
-
return;
|
1746
|
-
}
|
1747
|
-
|
1748
|
-
pluginEvent('setupClone', this);
|
1749
|
-
|
1750
|
-
if (!Sortable.eventCanceled) {
|
1751
|
-
cloneEl = clone(dragEl);
|
1752
|
-
cloneEl.removeAttribute("id");
|
1753
|
-
cloneEl.draggable = false;
|
1754
|
-
cloneEl.style['will-change'] = '';
|
1755
|
-
|
1756
|
-
this._hideClone();
|
1757
|
-
|
1758
|
-
toggleClass(cloneEl, this.options.chosenClass, false);
|
1759
|
-
Sortable.clone = cloneEl;
|
1760
|
-
} // #1143: IFrame support workaround
|
1761
|
-
|
1762
|
-
|
1763
|
-
_this.cloneId = _nextTick(function () {
|
1764
|
-
pluginEvent('clone', _this);
|
1765
|
-
if (Sortable.eventCanceled) return;
|
1766
|
-
|
1767
|
-
if (!_this.options.removeCloneOnHide) {
|
1768
|
-
rootEl.insertBefore(cloneEl, dragEl);
|
1769
|
-
}
|
1770
|
-
|
1771
|
-
_this._hideClone();
|
1772
|
-
|
1773
|
-
_dispatchEvent({
|
1774
|
-
sortable: _this,
|
1775
|
-
name: 'clone'
|
1776
|
-
});
|
1777
|
-
});
|
1778
|
-
!fallback && toggleClass(dragEl, options.dragClass, true); // Set proper drop events
|
1779
|
-
|
1780
|
-
if (fallback) {
|
1781
|
-
ignoreNextClick = true;
|
1782
|
-
_this._loopId = setInterval(_this._emulateDragOver, 50);
|
1783
|
-
} else {
|
1784
|
-
// Undo what was set in _prepareDragStart before drag started
|
1785
|
-
off(document, 'mouseup', _this._onDrop);
|
1786
|
-
off(document, 'touchend', _this._onDrop);
|
1787
|
-
off(document, 'touchcancel', _this._onDrop);
|
1788
|
-
|
1789
|
-
if (dataTransfer) {
|
1790
|
-
dataTransfer.effectAllowed = 'move';
|
1791
|
-
options.setData && options.setData.call(_this, dataTransfer, dragEl);
|
1792
|
-
}
|
1793
|
-
|
1794
|
-
on(document, 'drop', _this); // #1276 fix:
|
1795
|
-
|
1796
|
-
css(dragEl, 'transform', 'translateZ(0)');
|
1797
|
-
}
|
1798
|
-
|
1799
|
-
awaitingDragStarted = true;
|
1800
|
-
_this._dragStartId = _nextTick(_this._dragStarted.bind(_this, fallback, evt));
|
1801
|
-
on(document, 'selectstart', _this);
|
1802
|
-
moved = true;
|
1803
|
-
|
1804
|
-
if (Safari) {
|
1805
|
-
css(document.body, 'user-select', 'none');
|
1806
|
-
}
|
1807
|
-
},
|
1808
|
-
// Returns true - if no further action is needed (either inserted or another condition)
|
1809
|
-
_onDragOver: function _onDragOver(
|
1810
|
-
/**Event*/
|
1811
|
-
evt) {
|
1812
|
-
var el = this.el,
|
1813
|
-
target = evt.target,
|
1814
|
-
dragRect,
|
1815
|
-
targetRect,
|
1816
|
-
revert,
|
1817
|
-
options = this.options,
|
1818
|
-
group = options.group,
|
1819
|
-
activeSortable = Sortable.active,
|
1820
|
-
isOwner = activeGroup === group,
|
1821
|
-
canSort = options.sort,
|
1822
|
-
fromSortable = putSortable || activeSortable,
|
1823
|
-
vertical,
|
1824
|
-
_this = this,
|
1825
|
-
completedFired = false;
|
1826
|
-
|
1827
|
-
if (_silent) return;
|
1828
|
-
|
1829
|
-
function dragOverEvent(name, extra) {
|
1830
|
-
pluginEvent(name, _this, _objectSpread2({
|
1831
|
-
evt: evt,
|
1832
|
-
isOwner: isOwner,
|
1833
|
-
axis: vertical ? 'vertical' : 'horizontal',
|
1834
|
-
revert: revert,
|
1835
|
-
dragRect: dragRect,
|
1836
|
-
targetRect: targetRect,
|
1837
|
-
canSort: canSort,
|
1838
|
-
fromSortable: fromSortable,
|
1839
|
-
target: target,
|
1840
|
-
completed: completed,
|
1841
|
-
onMove: function onMove(target, after) {
|
1842
|
-
return _onMove(rootEl, el, dragEl, dragRect, target, getRect(target), evt, after);
|
1843
|
-
},
|
1844
|
-
changed: changed
|
1845
|
-
}, extra));
|
1846
|
-
} // Capture animation state
|
1847
|
-
|
1848
|
-
|
1849
|
-
function capture() {
|
1850
|
-
dragOverEvent('dragOverAnimationCapture');
|
1851
|
-
|
1852
|
-
_this.captureAnimationState();
|
1853
|
-
|
1854
|
-
if (_this !== fromSortable) {
|
1855
|
-
fromSortable.captureAnimationState();
|
1856
|
-
}
|
1857
|
-
} // Return invocation when dragEl is inserted (or completed)
|
1858
|
-
|
1859
|
-
|
1860
|
-
function completed(insertion) {
|
1861
|
-
dragOverEvent('dragOverCompleted', {
|
1862
|
-
insertion: insertion
|
1863
|
-
});
|
1864
|
-
|
1865
|
-
if (insertion) {
|
1866
|
-
// Clones must be hidden before folding animation to capture dragRectAbsolute properly
|
1867
|
-
if (isOwner) {
|
1868
|
-
activeSortable._hideClone();
|
1869
|
-
} else {
|
1870
|
-
activeSortable._showClone(_this);
|
1871
|
-
}
|
1872
|
-
|
1873
|
-
if (_this !== fromSortable) {
|
1874
|
-
// Set ghost class to new sortable's ghost class
|
1875
|
-
toggleClass(dragEl, putSortable ? putSortable.options.ghostClass : activeSortable.options.ghostClass, false);
|
1876
|
-
toggleClass(dragEl, options.ghostClass, true);
|
1877
|
-
}
|
1878
|
-
|
1879
|
-
if (putSortable !== _this && _this !== Sortable.active) {
|
1880
|
-
putSortable = _this;
|
1881
|
-
} else if (_this === Sortable.active && putSortable) {
|
1882
|
-
putSortable = null;
|
1883
|
-
} // Animation
|
1884
|
-
|
1885
|
-
|
1886
|
-
if (fromSortable === _this) {
|
1887
|
-
_this._ignoreWhileAnimating = target;
|
1888
|
-
}
|
1889
|
-
|
1890
|
-
_this.animateAll(function () {
|
1891
|
-
dragOverEvent('dragOverAnimationComplete');
|
1892
|
-
_this._ignoreWhileAnimating = null;
|
1893
|
-
});
|
1894
|
-
|
1895
|
-
if (_this !== fromSortable) {
|
1896
|
-
fromSortable.animateAll();
|
1897
|
-
fromSortable._ignoreWhileAnimating = null;
|
1898
|
-
}
|
1899
|
-
} // Null lastTarget if it is not inside a previously swapped element
|
1900
|
-
|
1901
|
-
|
1902
|
-
if (target === dragEl && !dragEl.animated || target === el && !target.animated) {
|
1903
|
-
lastTarget = null;
|
1904
|
-
} // no bubbling and not fallback
|
1905
|
-
|
1906
|
-
|
1907
|
-
if (!options.dragoverBubble && !evt.rootEl && target !== document) {
|
1908
|
-
dragEl.parentNode[expando]._isOutsideThisEl(evt.target); // Do not detect for empty insert if already inserted
|
1909
|
-
|
1910
|
-
|
1911
|
-
!insertion && nearestEmptyInsertDetectEvent(evt);
|
1912
|
-
}
|
1913
|
-
|
1914
|
-
!options.dragoverBubble && evt.stopPropagation && evt.stopPropagation();
|
1915
|
-
return completedFired = true;
|
1916
|
-
} // Call when dragEl has been inserted
|
1917
|
-
|
1918
|
-
|
1919
|
-
function changed() {
|
1920
|
-
newIndex = index(dragEl);
|
1921
|
-
newDraggableIndex = index(dragEl, options.draggable);
|
1922
|
-
|
1923
|
-
_dispatchEvent({
|
1924
|
-
sortable: _this,
|
1925
|
-
name: 'change',
|
1926
|
-
toEl: el,
|
1927
|
-
newIndex: newIndex,
|
1928
|
-
newDraggableIndex: newDraggableIndex,
|
1929
|
-
originalEvent: evt
|
1930
|
-
});
|
1931
|
-
}
|
1932
|
-
|
1933
|
-
if (evt.preventDefault !== void 0) {
|
1934
|
-
evt.cancelable && evt.preventDefault();
|
1935
|
-
}
|
1936
|
-
|
1937
|
-
target = closest(target, options.draggable, el, true);
|
1938
|
-
dragOverEvent('dragOver');
|
1939
|
-
if (Sortable.eventCanceled) return completedFired;
|
1940
|
-
|
1941
|
-
if (dragEl.contains(evt.target) || target.animated && target.animatingX && target.animatingY || _this._ignoreWhileAnimating === target) {
|
1942
|
-
return completed(false);
|
1943
|
-
}
|
1944
|
-
|
1945
|
-
ignoreNextClick = false;
|
1946
|
-
|
1947
|
-
if (activeSortable && !options.disabled && (isOwner ? canSort || (revert = parentEl !== rootEl) // Reverting item into the original list
|
1948
|
-
: putSortable === this || (this.lastPutMode = activeGroup.checkPull(this, activeSortable, dragEl, evt)) && group.checkPut(this, activeSortable, dragEl, evt))) {
|
1949
|
-
vertical = this._getDirection(evt, target) === 'vertical';
|
1950
|
-
dragRect = getRect(dragEl);
|
1951
|
-
dragOverEvent('dragOverValid');
|
1952
|
-
if (Sortable.eventCanceled) return completedFired;
|
1953
|
-
|
1954
|
-
if (revert) {
|
1955
|
-
parentEl = rootEl; // actualization
|
1956
|
-
|
1957
|
-
capture();
|
1958
|
-
|
1959
|
-
this._hideClone();
|
1960
|
-
|
1961
|
-
dragOverEvent('revert');
|
1962
|
-
|
1963
|
-
if (!Sortable.eventCanceled) {
|
1964
|
-
if (nextEl) {
|
1965
|
-
rootEl.insertBefore(dragEl, nextEl);
|
1966
|
-
} else {
|
1967
|
-
rootEl.appendChild(dragEl);
|
1968
|
-
}
|
1969
|
-
}
|
1970
|
-
|
1971
|
-
return completed(true);
|
1972
|
-
}
|
1973
|
-
|
1974
|
-
var elLastChild = lastChild(el, options.draggable);
|
1975
|
-
|
1976
|
-
if (!elLastChild || _ghostIsLast(evt, vertical, this) && !elLastChild.animated) {
|
1977
|
-
// Insert to end of list
|
1978
|
-
// If already at end of list: Do not insert
|
1979
|
-
if (elLastChild === dragEl) {
|
1980
|
-
return completed(false);
|
1981
|
-
} // if there is a last element, it is the target
|
1982
|
-
|
1983
|
-
|
1984
|
-
if (elLastChild && el === evt.target) {
|
1985
|
-
target = elLastChild;
|
1986
|
-
}
|
1987
|
-
|
1988
|
-
if (target) {
|
1989
|
-
targetRect = getRect(target);
|
1990
|
-
}
|
1991
|
-
|
1992
|
-
if (_onMove(rootEl, el, dragEl, dragRect, target, targetRect, evt, !!target) !== false) {
|
1993
|
-
capture();
|
1994
|
-
|
1995
|
-
if (elLastChild && elLastChild.nextSibling) {
|
1996
|
-
// the last draggable element is not the last node
|
1997
|
-
el.insertBefore(dragEl, elLastChild.nextSibling);
|
1998
|
-
} else {
|
1999
|
-
el.appendChild(dragEl);
|
2000
|
-
}
|
2001
|
-
|
2002
|
-
parentEl = el; // actualization
|
2003
|
-
|
2004
|
-
changed();
|
2005
|
-
return completed(true);
|
2006
|
-
}
|
2007
|
-
} else if (elLastChild && _ghostIsFirst(evt, vertical, this)) {
|
2008
|
-
// Insert to start of list
|
2009
|
-
var firstChild = getChild(el, 0, options, true);
|
2010
|
-
|
2011
|
-
if (firstChild === dragEl) {
|
2012
|
-
return completed(false);
|
2013
|
-
}
|
2014
|
-
|
2015
|
-
target = firstChild;
|
2016
|
-
targetRect = getRect(target);
|
2017
|
-
|
2018
|
-
if (_onMove(rootEl, el, dragEl, dragRect, target, targetRect, evt, false) !== false) {
|
2019
|
-
capture();
|
2020
|
-
el.insertBefore(dragEl, firstChild);
|
2021
|
-
parentEl = el; // actualization
|
2022
|
-
|
2023
|
-
changed();
|
2024
|
-
return completed(true);
|
2025
|
-
}
|
2026
|
-
} else if (target.parentNode === el) {
|
2027
|
-
targetRect = getRect(target);
|
2028
|
-
var direction = 0,
|
2029
|
-
targetBeforeFirstSwap,
|
2030
|
-
differentLevel = dragEl.parentNode !== el,
|
2031
|
-
differentRowCol = !_dragElInRowColumn(dragEl.animated && dragEl.toRect || dragRect, target.animated && target.toRect || targetRect, vertical),
|
2032
|
-
side1 = vertical ? 'top' : 'left',
|
2033
|
-
scrolledPastTop = isScrolledPast(target, 'top', 'top') || isScrolledPast(dragEl, 'top', 'top'),
|
2034
|
-
scrollBefore = scrolledPastTop ? scrolledPastTop.scrollTop : void 0;
|
2035
|
-
|
2036
|
-
if (lastTarget !== target) {
|
2037
|
-
targetBeforeFirstSwap = targetRect[side1];
|
2038
|
-
pastFirstInvertThresh = false;
|
2039
|
-
isCircumstantialInvert = !differentRowCol && options.invertSwap || differentLevel;
|
2040
|
-
}
|
2041
|
-
|
2042
|
-
direction = _getSwapDirection(evt, target, targetRect, vertical, differentRowCol ? 1 : options.swapThreshold, options.invertedSwapThreshold == null ? options.swapThreshold : options.invertedSwapThreshold, isCircumstantialInvert, lastTarget === target);
|
2043
|
-
var sibling;
|
2044
|
-
|
2045
|
-
if (direction !== 0) {
|
2046
|
-
// Check if target is beside dragEl in respective direction (ignoring hidden elements)
|
2047
|
-
var dragIndex = index(dragEl);
|
2048
|
-
|
2049
|
-
do {
|
2050
|
-
dragIndex -= direction;
|
2051
|
-
sibling = parentEl.children[dragIndex];
|
2052
|
-
} while (sibling && (css(sibling, 'display') === 'none' || sibling === ghostEl));
|
2053
|
-
} // If dragEl is already beside target: Do not insert
|
2054
|
-
|
2055
|
-
|
2056
|
-
if (direction === 0 || sibling === target) {
|
2057
|
-
return completed(false);
|
2058
|
-
}
|
2059
|
-
|
2060
|
-
lastTarget = target;
|
2061
|
-
lastDirection = direction;
|
2062
|
-
var nextSibling = target.nextElementSibling,
|
2063
|
-
after = false;
|
2064
|
-
after = direction === 1;
|
2065
|
-
|
2066
|
-
var moveVector = _onMove(rootEl, el, dragEl, dragRect, target, targetRect, evt, after);
|
2067
|
-
|
2068
|
-
if (moveVector !== false) {
|
2069
|
-
if (moveVector === 1 || moveVector === -1) {
|
2070
|
-
after = moveVector === 1;
|
2071
|
-
}
|
2072
|
-
|
2073
|
-
_silent = true;
|
2074
|
-
setTimeout(_unsilent, 30);
|
2075
|
-
capture();
|
2076
|
-
|
2077
|
-
if (after && !nextSibling) {
|
2078
|
-
el.appendChild(dragEl);
|
2079
|
-
} else {
|
2080
|
-
target.parentNode.insertBefore(dragEl, after ? nextSibling : target);
|
2081
|
-
} // Undo chrome's scroll adjustment (has no effect on other browsers)
|
2082
|
-
|
2083
|
-
|
2084
|
-
if (scrolledPastTop) {
|
2085
|
-
scrollBy(scrolledPastTop, 0, scrollBefore - scrolledPastTop.scrollTop);
|
2086
|
-
}
|
2087
|
-
|
2088
|
-
parentEl = dragEl.parentNode; // actualization
|
2089
|
-
// must be done before animation
|
2090
|
-
|
2091
|
-
if (targetBeforeFirstSwap !== undefined && !isCircumstantialInvert) {
|
2092
|
-
targetMoveDistance = Math.abs(targetBeforeFirstSwap - getRect(target)[side1]);
|
2093
|
-
}
|
2094
|
-
|
2095
|
-
changed();
|
2096
|
-
return completed(true);
|
2097
|
-
}
|
2098
|
-
}
|
2099
|
-
|
2100
|
-
if (el.contains(dragEl)) {
|
2101
|
-
return completed(false);
|
2102
|
-
}
|
2103
|
-
}
|
2104
|
-
|
2105
|
-
return false;
|
2106
|
-
},
|
2107
|
-
_ignoreWhileAnimating: null,
|
2108
|
-
_offMoveEvents: function _offMoveEvents() {
|
2109
|
-
off(document, 'mousemove', this._onTouchMove);
|
2110
|
-
off(document, 'touchmove', this._onTouchMove);
|
2111
|
-
off(document, 'pointermove', this._onTouchMove);
|
2112
|
-
off(document, 'dragover', nearestEmptyInsertDetectEvent);
|
2113
|
-
off(document, 'mousemove', nearestEmptyInsertDetectEvent);
|
2114
|
-
off(document, 'touchmove', nearestEmptyInsertDetectEvent);
|
2115
|
-
},
|
2116
|
-
_offUpEvents: function _offUpEvents() {
|
2117
|
-
var ownerDocument = this.el.ownerDocument;
|
2118
|
-
off(ownerDocument, 'mouseup', this._onDrop);
|
2119
|
-
off(ownerDocument, 'touchend', this._onDrop);
|
2120
|
-
off(ownerDocument, 'pointerup', this._onDrop);
|
2121
|
-
off(ownerDocument, 'touchcancel', this._onDrop);
|
2122
|
-
off(document, 'selectstart', this);
|
2123
|
-
},
|
2124
|
-
_onDrop: function _onDrop(
|
2125
|
-
/**Event*/
|
2126
|
-
evt) {
|
2127
|
-
var el = this.el,
|
2128
|
-
options = this.options; // Get the index of the dragged element within its parent
|
2129
|
-
|
2130
|
-
newIndex = index(dragEl);
|
2131
|
-
newDraggableIndex = index(dragEl, options.draggable);
|
2132
|
-
pluginEvent('drop', this, {
|
2133
|
-
evt: evt
|
2134
|
-
});
|
2135
|
-
parentEl = dragEl && dragEl.parentNode; // Get again after plugin event
|
2136
|
-
|
2137
|
-
newIndex = index(dragEl);
|
2138
|
-
newDraggableIndex = index(dragEl, options.draggable);
|
2139
|
-
|
2140
|
-
if (Sortable.eventCanceled) {
|
2141
|
-
this._nulling();
|
2142
|
-
|
2143
|
-
return;
|
2144
|
-
}
|
2145
|
-
|
2146
|
-
awaitingDragStarted = false;
|
2147
|
-
isCircumstantialInvert = false;
|
2148
|
-
pastFirstInvertThresh = false;
|
2149
|
-
clearInterval(this._loopId);
|
2150
|
-
clearTimeout(this._dragStartTimer);
|
2151
|
-
|
2152
|
-
_cancelNextTick(this.cloneId);
|
2153
|
-
|
2154
|
-
_cancelNextTick(this._dragStartId); // Unbind events
|
2155
|
-
|
2156
|
-
|
2157
|
-
if (this.nativeDraggable) {
|
2158
|
-
off(document, 'drop', this);
|
2159
|
-
off(el, 'dragstart', this._onDragStart);
|
2160
|
-
}
|
2161
|
-
|
2162
|
-
this._offMoveEvents();
|
2163
|
-
|
2164
|
-
this._offUpEvents();
|
2165
|
-
|
2166
|
-
if (Safari) {
|
2167
|
-
css(document.body, 'user-select', '');
|
2168
|
-
}
|
2169
|
-
|
2170
|
-
css(dragEl, 'transform', '');
|
2171
|
-
|
2172
|
-
if (evt) {
|
2173
|
-
if (moved) {
|
2174
|
-
evt.cancelable && evt.preventDefault();
|
2175
|
-
!options.dropBubble && evt.stopPropagation();
|
2176
|
-
}
|
2177
|
-
|
2178
|
-
ghostEl && ghostEl.parentNode && ghostEl.parentNode.removeChild(ghostEl);
|
2179
|
-
|
2180
|
-
if (rootEl === parentEl || putSortable && putSortable.lastPutMode !== 'clone') {
|
2181
|
-
// Remove clone(s)
|
2182
|
-
cloneEl && cloneEl.parentNode && cloneEl.parentNode.removeChild(cloneEl);
|
2183
|
-
}
|
2184
|
-
|
2185
|
-
if (dragEl) {
|
2186
|
-
if (this.nativeDraggable) {
|
2187
|
-
off(dragEl, 'dragend', this);
|
2188
|
-
}
|
2189
|
-
|
2190
|
-
_disableDraggable(dragEl);
|
2191
|
-
|
2192
|
-
dragEl.style['will-change'] = ''; // Remove classes
|
2193
|
-
// ghostClass is added in dragStarted
|
2194
|
-
|
2195
|
-
if (moved && !awaitingDragStarted) {
|
2196
|
-
toggleClass(dragEl, putSortable ? putSortable.options.ghostClass : this.options.ghostClass, false);
|
2197
|
-
}
|
2198
|
-
|
2199
|
-
toggleClass(dragEl, this.options.chosenClass, false); // Drag stop event
|
2200
|
-
|
2201
|
-
_dispatchEvent({
|
2202
|
-
sortable: this,
|
2203
|
-
name: 'unchoose',
|
2204
|
-
toEl: parentEl,
|
2205
|
-
newIndex: null,
|
2206
|
-
newDraggableIndex: null,
|
2207
|
-
originalEvent: evt
|
2208
|
-
});
|
2209
|
-
|
2210
|
-
if (rootEl !== parentEl) {
|
2211
|
-
if (newIndex >= 0) {
|
2212
|
-
// Add event
|
2213
|
-
_dispatchEvent({
|
2214
|
-
rootEl: parentEl,
|
2215
|
-
name: 'add',
|
2216
|
-
toEl: parentEl,
|
2217
|
-
fromEl: rootEl,
|
2218
|
-
originalEvent: evt
|
2219
|
-
}); // Remove event
|
2220
|
-
|
2221
|
-
|
2222
|
-
_dispatchEvent({
|
2223
|
-
sortable: this,
|
2224
|
-
name: 'remove',
|
2225
|
-
toEl: parentEl,
|
2226
|
-
originalEvent: evt
|
2227
|
-
}); // drag from one list and drop into another
|
2228
|
-
|
2229
|
-
|
2230
|
-
_dispatchEvent({
|
2231
|
-
rootEl: parentEl,
|
2232
|
-
name: 'sort',
|
2233
|
-
toEl: parentEl,
|
2234
|
-
fromEl: rootEl,
|
2235
|
-
originalEvent: evt
|
2236
|
-
});
|
2237
|
-
|
2238
|
-
_dispatchEvent({
|
2239
|
-
sortable: this,
|
2240
|
-
name: 'sort',
|
2241
|
-
toEl: parentEl,
|
2242
|
-
originalEvent: evt
|
2243
|
-
});
|
2244
|
-
}
|
2245
|
-
|
2246
|
-
putSortable && putSortable.save();
|
2247
|
-
} else {
|
2248
|
-
if (newIndex !== oldIndex) {
|
2249
|
-
if (newIndex >= 0) {
|
2250
|
-
// drag & drop within the same list
|
2251
|
-
_dispatchEvent({
|
2252
|
-
sortable: this,
|
2253
|
-
name: 'update',
|
2254
|
-
toEl: parentEl,
|
2255
|
-
originalEvent: evt
|
2256
|
-
});
|
2257
|
-
|
2258
|
-
_dispatchEvent({
|
2259
|
-
sortable: this,
|
2260
|
-
name: 'sort',
|
2261
|
-
toEl: parentEl,
|
2262
|
-
originalEvent: evt
|
2263
|
-
});
|
2264
|
-
}
|
2265
|
-
}
|
2266
|
-
}
|
2267
|
-
|
2268
|
-
if (Sortable.active) {
|
2269
|
-
/* jshint eqnull:true */
|
2270
|
-
if (newIndex == null || newIndex === -1) {
|
2271
|
-
newIndex = oldIndex;
|
2272
|
-
newDraggableIndex = oldDraggableIndex;
|
2273
|
-
}
|
2274
|
-
|
2275
|
-
_dispatchEvent({
|
2276
|
-
sortable: this,
|
2277
|
-
name: 'end',
|
2278
|
-
toEl: parentEl,
|
2279
|
-
originalEvent: evt
|
2280
|
-
}); // Save sorting
|
2281
|
-
|
2282
|
-
|
2283
|
-
this.save();
|
2284
|
-
}
|
2285
|
-
}
|
2286
|
-
}
|
2287
|
-
|
2288
|
-
this._nulling();
|
2289
|
-
},
|
2290
|
-
_nulling: function _nulling() {
|
2291
|
-
pluginEvent('nulling', this);
|
2292
|
-
rootEl = dragEl = parentEl = ghostEl = nextEl = cloneEl = lastDownEl = cloneHidden = tapEvt = touchEvt = moved = newIndex = newDraggableIndex = oldIndex = oldDraggableIndex = lastTarget = lastDirection = putSortable = activeGroup = Sortable.dragged = Sortable.ghost = Sortable.clone = Sortable.active = null;
|
2293
|
-
savedInputChecked.forEach(function (el) {
|
2294
|
-
el.checked = true;
|
2295
|
-
});
|
2296
|
-
savedInputChecked.length = lastDx = lastDy = 0;
|
2297
|
-
},
|
2298
|
-
handleEvent: function handleEvent(
|
2299
|
-
/**Event*/
|
2300
|
-
evt) {
|
2301
|
-
switch (evt.type) {
|
2302
|
-
case 'drop':
|
2303
|
-
case 'dragend':
|
2304
|
-
this._onDrop(evt);
|
2305
|
-
|
2306
|
-
break;
|
2307
|
-
|
2308
|
-
case 'dragenter':
|
2309
|
-
case 'dragover':
|
2310
|
-
if (dragEl) {
|
2311
|
-
this._onDragOver(evt);
|
2312
|
-
|
2313
|
-
_globalDragOver(evt);
|
2314
|
-
}
|
2315
|
-
|
2316
|
-
break;
|
2317
|
-
|
2318
|
-
case 'selectstart':
|
2319
|
-
evt.preventDefault();
|
2320
|
-
break;
|
2321
|
-
}
|
2322
|
-
},
|
2323
|
-
|
2324
|
-
/**
|
2325
|
-
* Serializes the item into an array of string.
|
2326
|
-
* @returns {String[]}
|
2327
|
-
*/
|
2328
|
-
toArray: function toArray() {
|
2329
|
-
var order = [],
|
2330
|
-
el,
|
2331
|
-
children = this.el.children,
|
2332
|
-
i = 0,
|
2333
|
-
n = children.length,
|
2334
|
-
options = this.options;
|
2335
|
-
|
2336
|
-
for (; i < n; i++) {
|
2337
|
-
el = children[i];
|
2338
|
-
|
2339
|
-
if (closest(el, options.draggable, this.el, false)) {
|
2340
|
-
order.push(el.getAttribute(options.dataIdAttr) || _generateId(el));
|
2341
|
-
}
|
2342
|
-
}
|
2343
|
-
|
2344
|
-
return order;
|
2345
|
-
},
|
2346
|
-
|
2347
|
-
/**
|
2348
|
-
* Sorts the elements according to the array.
|
2349
|
-
* @param {String[]} order order of the items
|
2350
|
-
*/
|
2351
|
-
sort: function sort(order, useAnimation) {
|
2352
|
-
var items = {},
|
2353
|
-
rootEl = this.el;
|
2354
|
-
this.toArray().forEach(function (id, i) {
|
2355
|
-
var el = rootEl.children[i];
|
2356
|
-
|
2357
|
-
if (closest(el, this.options.draggable, rootEl, false)) {
|
2358
|
-
items[id] = el;
|
2359
|
-
}
|
2360
|
-
}, this);
|
2361
|
-
useAnimation && this.captureAnimationState();
|
2362
|
-
order.forEach(function (id) {
|
2363
|
-
if (items[id]) {
|
2364
|
-
rootEl.removeChild(items[id]);
|
2365
|
-
rootEl.appendChild(items[id]);
|
2366
|
-
}
|
2367
|
-
});
|
2368
|
-
useAnimation && this.animateAll();
|
2369
|
-
},
|
2370
|
-
|
2371
|
-
/**
|
2372
|
-
* Save the current sorting
|
2373
|
-
*/
|
2374
|
-
save: function save() {
|
2375
|
-
var store = this.options.store;
|
2376
|
-
store && store.set && store.set(this);
|
2377
|
-
},
|
2378
|
-
|
2379
|
-
/**
|
2380
|
-
* For each element in the set, get the first element that matches the selector by testing the element itself and traversing up through its ancestors in the DOM tree.
|
2381
|
-
* @param {HTMLElement} el
|
2382
|
-
* @param {String} [selector] default: `options.draggable`
|
2383
|
-
* @returns {HTMLElement|null}
|
2384
|
-
*/
|
2385
|
-
closest: function closest$1(el, selector) {
|
2386
|
-
return closest(el, selector || this.options.draggable, this.el, false);
|
2387
|
-
},
|
2388
|
-
|
2389
|
-
/**
|
2390
|
-
* Set/get option
|
2391
|
-
* @param {string} name
|
2392
|
-
* @param {*} [value]
|
2393
|
-
* @returns {*}
|
2394
|
-
*/
|
2395
|
-
option: function option(name, value) {
|
2396
|
-
var options = this.options;
|
2397
|
-
|
2398
|
-
if (value === void 0) {
|
2399
|
-
return options[name];
|
2400
|
-
} else {
|
2401
|
-
var modifiedValue = PluginManager.modifyOption(this, name, value);
|
2402
|
-
|
2403
|
-
if (typeof modifiedValue !== 'undefined') {
|
2404
|
-
options[name] = modifiedValue;
|
2405
|
-
} else {
|
2406
|
-
options[name] = value;
|
2407
|
-
}
|
2408
|
-
|
2409
|
-
if (name === 'group') {
|
2410
|
-
_prepareGroup(options);
|
2411
|
-
}
|
2412
|
-
}
|
2413
|
-
},
|
2414
|
-
|
2415
|
-
/**
|
2416
|
-
* Destroy
|
2417
|
-
*/
|
2418
|
-
destroy: function destroy() {
|
2419
|
-
pluginEvent('destroy', this);
|
2420
|
-
var el = this.el;
|
2421
|
-
el[expando] = null;
|
2422
|
-
off(el, 'mousedown', this._onTapStart);
|
2423
|
-
off(el, 'touchstart', this._onTapStart);
|
2424
|
-
off(el, 'pointerdown', this._onTapStart);
|
2425
|
-
|
2426
|
-
if (this.nativeDraggable) {
|
2427
|
-
off(el, 'dragover', this);
|
2428
|
-
off(el, 'dragenter', this);
|
2429
|
-
} // Remove draggable attributes
|
2430
|
-
|
2431
|
-
|
2432
|
-
Array.prototype.forEach.call(el.querySelectorAll('[draggable]'), function (el) {
|
2433
|
-
el.removeAttribute('draggable');
|
2434
|
-
});
|
2435
|
-
|
2436
|
-
this._onDrop();
|
2437
|
-
|
2438
|
-
this._disableDelayedDragEvents();
|
2439
|
-
|
2440
|
-
sortables.splice(sortables.indexOf(this.el), 1);
|
2441
|
-
this.el = el = null;
|
2442
|
-
},
|
2443
|
-
_hideClone: function _hideClone() {
|
2444
|
-
if (!cloneHidden) {
|
2445
|
-
pluginEvent('hideClone', this);
|
2446
|
-
if (Sortable.eventCanceled) return;
|
2447
|
-
css(cloneEl, 'display', 'none');
|
2448
|
-
|
2449
|
-
if (this.options.removeCloneOnHide && cloneEl.parentNode) {
|
2450
|
-
cloneEl.parentNode.removeChild(cloneEl);
|
2451
|
-
}
|
2452
|
-
|
2453
|
-
cloneHidden = true;
|
2454
|
-
}
|
2455
|
-
},
|
2456
|
-
_showClone: function _showClone(putSortable) {
|
2457
|
-
if (putSortable.lastPutMode !== 'clone') {
|
2458
|
-
this._hideClone();
|
2459
|
-
|
2460
|
-
return;
|
2461
|
-
}
|
2462
|
-
|
2463
|
-
if (cloneHidden) {
|
2464
|
-
pluginEvent('showClone', this);
|
2465
|
-
if (Sortable.eventCanceled) return; // show clone at dragEl or original position
|
2466
|
-
|
2467
|
-
if (dragEl.parentNode == rootEl && !this.options.group.revertClone) {
|
2468
|
-
rootEl.insertBefore(cloneEl, dragEl);
|
2469
|
-
} else if (nextEl) {
|
2470
|
-
rootEl.insertBefore(cloneEl, nextEl);
|
2471
|
-
} else {
|
2472
|
-
rootEl.appendChild(cloneEl);
|
2473
|
-
}
|
2474
|
-
|
2475
|
-
if (this.options.group.revertClone) {
|
2476
|
-
this.animate(dragEl, cloneEl);
|
2477
|
-
}
|
2478
|
-
|
2479
|
-
css(cloneEl, 'display', '');
|
2480
|
-
cloneHidden = false;
|
2481
|
-
}
|
2482
|
-
}
|
2483
|
-
};
|
2484
|
-
|
2485
|
-
function _globalDragOver(
|
2486
|
-
/**Event*/
|
2487
|
-
evt) {
|
2488
|
-
if (evt.dataTransfer) {
|
2489
|
-
evt.dataTransfer.dropEffect = 'move';
|
2490
|
-
}
|
2491
|
-
|
2492
|
-
evt.cancelable && evt.preventDefault();
|
2493
|
-
}
|
2494
|
-
|
2495
|
-
function _onMove(fromEl, toEl, dragEl, dragRect, targetEl, targetRect, originalEvent, willInsertAfter) {
|
2496
|
-
var evt,
|
2497
|
-
sortable = fromEl[expando],
|
2498
|
-
onMoveFn = sortable.options.onMove,
|
2499
|
-
retVal; // Support for new CustomEvent feature
|
2500
|
-
|
2501
|
-
if (window.CustomEvent && !IE11OrLess && !Edge) {
|
2502
|
-
evt = new CustomEvent('move', {
|
2503
|
-
bubbles: true,
|
2504
|
-
cancelable: true
|
2505
|
-
});
|
2506
|
-
} else {
|
2507
|
-
evt = document.createEvent('Event');
|
2508
|
-
evt.initEvent('move', true, true);
|
2509
|
-
}
|
2510
|
-
|
2511
|
-
evt.to = toEl;
|
2512
|
-
evt.from = fromEl;
|
2513
|
-
evt.dragged = dragEl;
|
2514
|
-
evt.draggedRect = dragRect;
|
2515
|
-
evt.related = targetEl || toEl;
|
2516
|
-
evt.relatedRect = targetRect || getRect(toEl);
|
2517
|
-
evt.willInsertAfter = willInsertAfter;
|
2518
|
-
evt.originalEvent = originalEvent;
|
2519
|
-
fromEl.dispatchEvent(evt);
|
2520
|
-
|
2521
|
-
if (onMoveFn) {
|
2522
|
-
retVal = onMoveFn.call(sortable, evt, originalEvent);
|
2523
|
-
}
|
2524
|
-
|
2525
|
-
return retVal;
|
2526
|
-
}
|
2527
|
-
|
2528
|
-
function _disableDraggable(el) {
|
2529
|
-
el.draggable = false;
|
2530
|
-
}
|
2531
|
-
|
2532
|
-
function _unsilent() {
|
2533
|
-
_silent = false;
|
2534
|
-
}
|
2535
|
-
|
2536
|
-
function _ghostIsFirst(evt, vertical, sortable) {
|
2537
|
-
var rect = getRect(getChild(sortable.el, 0, sortable.options, true));
|
2538
|
-
var spacer = 10;
|
2539
|
-
return vertical ? evt.clientX < rect.left - spacer || evt.clientY < rect.top && evt.clientX < rect.right : evt.clientY < rect.top - spacer || evt.clientY < rect.bottom && evt.clientX < rect.left;
|
2540
|
-
}
|
2541
|
-
|
2542
|
-
function _ghostIsLast(evt, vertical, sortable) {
|
2543
|
-
var rect = getRect(lastChild(sortable.el, sortable.options.draggable));
|
2544
|
-
var spacer = 10;
|
2545
|
-
return vertical ? evt.clientX > rect.right + spacer || evt.clientX <= rect.right && evt.clientY > rect.bottom && evt.clientX >= rect.left : evt.clientX > rect.right && evt.clientY > rect.top || evt.clientX <= rect.right && evt.clientY > rect.bottom + spacer;
|
2546
|
-
}
|
2547
|
-
|
2548
|
-
function _getSwapDirection(evt, target, targetRect, vertical, swapThreshold, invertedSwapThreshold, invertSwap, isLastTarget) {
|
2549
|
-
var mouseOnAxis = vertical ? evt.clientY : evt.clientX,
|
2550
|
-
targetLength = vertical ? targetRect.height : targetRect.width,
|
2551
|
-
targetS1 = vertical ? targetRect.top : targetRect.left,
|
2552
|
-
targetS2 = vertical ? targetRect.bottom : targetRect.right,
|
2553
|
-
invert = false;
|
2554
|
-
|
2555
|
-
if (!invertSwap) {
|
2556
|
-
// Never invert or create dragEl shadow when target movemenet causes mouse to move past the end of regular swapThreshold
|
2557
|
-
if (isLastTarget && targetMoveDistance < targetLength * swapThreshold) {
|
2558
|
-
// multiplied only by swapThreshold because mouse will already be inside target by (1 - threshold) * targetLength / 2
|
2559
|
-
// check if past first invert threshold on side opposite of lastDirection
|
2560
|
-
if (!pastFirstInvertThresh && (lastDirection === 1 ? mouseOnAxis > targetS1 + targetLength * invertedSwapThreshold / 2 : mouseOnAxis < targetS2 - targetLength * invertedSwapThreshold / 2)) {
|
2561
|
-
// past first invert threshold, do not restrict inverted threshold to dragEl shadow
|
2562
|
-
pastFirstInvertThresh = true;
|
2563
|
-
}
|
2564
|
-
|
2565
|
-
if (!pastFirstInvertThresh) {
|
2566
|
-
// dragEl shadow (target move distance shadow)
|
2567
|
-
if (lastDirection === 1 ? mouseOnAxis < targetS1 + targetMoveDistance // over dragEl shadow
|
2568
|
-
: mouseOnAxis > targetS2 - targetMoveDistance) {
|
2569
|
-
return -lastDirection;
|
2570
|
-
}
|
2571
|
-
} else {
|
2572
|
-
invert = true;
|
2573
|
-
}
|
2574
|
-
} else {
|
2575
|
-
// Regular
|
2576
|
-
if (mouseOnAxis > targetS1 + targetLength * (1 - swapThreshold) / 2 && mouseOnAxis < targetS2 - targetLength * (1 - swapThreshold) / 2) {
|
2577
|
-
return _getInsertDirection(target);
|
2578
|
-
}
|
2579
|
-
}
|
2580
|
-
}
|
2581
|
-
|
2582
|
-
invert = invert || invertSwap;
|
2583
|
-
|
2584
|
-
if (invert) {
|
2585
|
-
// Invert of regular
|
2586
|
-
if (mouseOnAxis < targetS1 + targetLength * invertedSwapThreshold / 2 || mouseOnAxis > targetS2 - targetLength * invertedSwapThreshold / 2) {
|
2587
|
-
return mouseOnAxis > targetS1 + targetLength / 2 ? 1 : -1;
|
2588
|
-
}
|
2589
|
-
}
|
2590
|
-
|
2591
|
-
return 0;
|
2592
|
-
}
|
2593
|
-
/**
|
2594
|
-
* Gets the direction dragEl must be swapped relative to target in order to make it
|
2595
|
-
* seem that dragEl has been "inserted" into that element's position
|
2596
|
-
* @param {HTMLElement} target The target whose position dragEl is being inserted at
|
2597
|
-
* @return {Number} Direction dragEl must be swapped
|
2598
|
-
*/
|
2599
|
-
|
2600
|
-
|
2601
|
-
function _getInsertDirection(target) {
|
2602
|
-
if (index(dragEl) < index(target)) {
|
2603
|
-
return 1;
|
2604
|
-
} else {
|
2605
|
-
return -1;
|
2606
|
-
}
|
2607
|
-
}
|
2608
|
-
/**
|
2609
|
-
* Generate id
|
2610
|
-
* @param {HTMLElement} el
|
2611
|
-
* @returns {String}
|
2612
|
-
* @private
|
2613
|
-
*/
|
2614
|
-
|
2615
|
-
|
2616
|
-
function _generateId(el) {
|
2617
|
-
var str = el.tagName + el.className + el.src + el.href + el.textContent,
|
2618
|
-
i = str.length,
|
2619
|
-
sum = 0;
|
2620
|
-
|
2621
|
-
while (i--) {
|
2622
|
-
sum += str.charCodeAt(i);
|
2623
|
-
}
|
2624
|
-
|
2625
|
-
return sum.toString(36);
|
2626
|
-
}
|
2627
|
-
|
2628
|
-
function _saveInputCheckedState(root) {
|
2629
|
-
savedInputChecked.length = 0;
|
2630
|
-
var inputs = root.getElementsByTagName('input');
|
2631
|
-
var idx = inputs.length;
|
2632
|
-
|
2633
|
-
while (idx--) {
|
2634
|
-
var el = inputs[idx];
|
2635
|
-
el.checked && savedInputChecked.push(el);
|
2636
|
-
}
|
2637
|
-
}
|
2638
|
-
|
2639
|
-
function _nextTick(fn) {
|
2640
|
-
return setTimeout(fn, 0);
|
2641
|
-
}
|
2642
|
-
|
2643
|
-
function _cancelNextTick(id) {
|
2644
|
-
return clearTimeout(id);
|
2645
|
-
} // Fixed #973:
|
2646
|
-
|
2647
|
-
|
2648
|
-
if (documentExists) {
|
2649
|
-
on(document, 'touchmove', function (evt) {
|
2650
|
-
if ((Sortable.active || awaitingDragStarted) && evt.cancelable) {
|
2651
|
-
evt.preventDefault();
|
2652
|
-
}
|
2653
|
-
});
|
2654
|
-
} // Export utils
|
2655
|
-
|
2656
|
-
|
2657
|
-
Sortable.utils = {
|
2658
|
-
on: on,
|
2659
|
-
off: off,
|
2660
|
-
css: css,
|
2661
|
-
find: find,
|
2662
|
-
is: function is(el, selector) {
|
2663
|
-
return !!closest(el, selector, el, false);
|
2664
|
-
},
|
2665
|
-
extend: extend,
|
2666
|
-
throttle: throttle,
|
2667
|
-
closest: closest,
|
2668
|
-
toggleClass: toggleClass,
|
2669
|
-
clone: clone,
|
2670
|
-
index: index,
|
2671
|
-
nextTick: _nextTick,
|
2672
|
-
cancelNextTick: _cancelNextTick,
|
2673
|
-
detectDirection: _detectDirection,
|
2674
|
-
getChild: getChild
|
2675
|
-
};
|
2676
|
-
/**
|
2677
|
-
* Get the Sortable instance of an element
|
2678
|
-
* @param {HTMLElement} element The element
|
2679
|
-
* @return {Sortable|undefined} The instance of Sortable
|
2680
|
-
*/
|
2681
|
-
|
2682
|
-
Sortable.get = function (element) {
|
2683
|
-
return element[expando];
|
2684
|
-
};
|
2685
|
-
/**
|
2686
|
-
* Mount a plugin to Sortable
|
2687
|
-
* @param {...SortablePlugin|SortablePlugin[]} plugins Plugins being mounted
|
2688
|
-
*/
|
2689
|
-
|
2690
|
-
|
2691
|
-
Sortable.mount = function () {
|
2692
|
-
for (var _len = arguments.length, plugins = new Array(_len), _key = 0; _key < _len; _key++) {
|
2693
|
-
plugins[_key] = arguments[_key];
|
2694
|
-
}
|
2695
|
-
|
2696
|
-
if (plugins[0].constructor === Array) plugins = plugins[0];
|
2697
|
-
plugins.forEach(function (plugin) {
|
2698
|
-
if (!plugin.prototype || !plugin.prototype.constructor) {
|
2699
|
-
throw "Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(plugin));
|
2700
|
-
}
|
2701
|
-
|
2702
|
-
if (plugin.utils) Sortable.utils = _objectSpread2(_objectSpread2({}, Sortable.utils), plugin.utils);
|
2703
|
-
PluginManager.mount(plugin);
|
2704
|
-
});
|
2705
|
-
};
|
2706
|
-
/**
|
2707
|
-
* Create sortable instance
|
2708
|
-
* @param {HTMLElement} el
|
2709
|
-
* @param {Object} [options]
|
2710
|
-
*/
|
2711
|
-
|
2712
|
-
|
2713
|
-
Sortable.create = function (el, options) {
|
2714
|
-
return new Sortable(el, options);
|
2715
|
-
}; // Export
|
2716
|
-
|
2717
|
-
|
2718
|
-
Sortable.version = version;
|
2719
|
-
|
2720
|
-
var autoScrolls = [],
|
2721
|
-
scrollEl,
|
2722
|
-
scrollRootEl,
|
2723
|
-
scrolling = false,
|
2724
|
-
lastAutoScrollX,
|
2725
|
-
lastAutoScrollY,
|
2726
|
-
touchEvt$1,
|
2727
|
-
pointerElemChangedInterval;
|
2728
|
-
|
2729
|
-
function AutoScrollPlugin() {
|
2730
|
-
function AutoScroll() {
|
2731
|
-
this.defaults = {
|
2732
|
-
scroll: true,
|
2733
|
-
forceAutoScrollFallback: false,
|
2734
|
-
scrollSensitivity: 30,
|
2735
|
-
scrollSpeed: 10,
|
2736
|
-
bubbleScroll: true
|
2737
|
-
}; // Bind all private methods
|
2738
|
-
|
2739
|
-
for (var fn in this) {
|
2740
|
-
if (fn.charAt(0) === '_' && typeof this[fn] === 'function') {
|
2741
|
-
this[fn] = this[fn].bind(this);
|
2742
|
-
}
|
2743
|
-
}
|
2744
|
-
}
|
2745
|
-
|
2746
|
-
AutoScroll.prototype = {
|
2747
|
-
dragStarted: function dragStarted(_ref) {
|
2748
|
-
var originalEvent = _ref.originalEvent;
|
2749
|
-
|
2750
|
-
if (this.sortable.nativeDraggable) {
|
2751
|
-
on(document, 'dragover', this._handleAutoScroll);
|
2752
|
-
} else {
|
2753
|
-
if (this.options.supportPointer) {
|
2754
|
-
on(document, 'pointermove', this._handleFallbackAutoScroll);
|
2755
|
-
} else if (originalEvent.touches) {
|
2756
|
-
on(document, 'touchmove', this._handleFallbackAutoScroll);
|
2757
|
-
} else {
|
2758
|
-
on(document, 'mousemove', this._handleFallbackAutoScroll);
|
2759
|
-
}
|
2760
|
-
}
|
2761
|
-
},
|
2762
|
-
dragOverCompleted: function dragOverCompleted(_ref2) {
|
2763
|
-
var originalEvent = _ref2.originalEvent;
|
2764
|
-
|
2765
|
-
// For when bubbling is canceled and using fallback (fallback 'touchmove' always reached)
|
2766
|
-
if (!this.options.dragOverBubble && !originalEvent.rootEl) {
|
2767
|
-
this._handleAutoScroll(originalEvent);
|
2768
|
-
}
|
2769
|
-
},
|
2770
|
-
drop: function drop() {
|
2771
|
-
if (this.sortable.nativeDraggable) {
|
2772
|
-
off(document, 'dragover', this._handleAutoScroll);
|
2773
|
-
} else {
|
2774
|
-
off(document, 'pointermove', this._handleFallbackAutoScroll);
|
2775
|
-
off(document, 'touchmove', this._handleFallbackAutoScroll);
|
2776
|
-
off(document, 'mousemove', this._handleFallbackAutoScroll);
|
2777
|
-
}
|
2778
|
-
|
2779
|
-
clearPointerElemChangedInterval();
|
2780
|
-
clearAutoScrolls();
|
2781
|
-
cancelThrottle();
|
2782
|
-
},
|
2783
|
-
nulling: function nulling() {
|
2784
|
-
touchEvt$1 = scrollRootEl = scrollEl = scrolling = pointerElemChangedInterval = lastAutoScrollX = lastAutoScrollY = null;
|
2785
|
-
autoScrolls.length = 0;
|
2786
|
-
},
|
2787
|
-
_handleFallbackAutoScroll: function _handleFallbackAutoScroll(evt) {
|
2788
|
-
this._handleAutoScroll(evt, true);
|
2789
|
-
},
|
2790
|
-
_handleAutoScroll: function _handleAutoScroll(evt, fallback) {
|
2791
|
-
var _this = this;
|
2792
|
-
|
2793
|
-
var x = (evt.touches ? evt.touches[0] : evt).clientX,
|
2794
|
-
y = (evt.touches ? evt.touches[0] : evt).clientY,
|
2795
|
-
elem = document.elementFromPoint(x, y);
|
2796
|
-
touchEvt$1 = evt; // IE does not seem to have native autoscroll,
|
2797
|
-
// Edge's autoscroll seems too conditional,
|
2798
|
-
// MACOS Safari does not have autoscroll,
|
2799
|
-
// Firefox and Chrome are good
|
2800
|
-
|
2801
|
-
if (fallback || this.options.forceAutoScrollFallback || Edge || IE11OrLess || Safari) {
|
2802
|
-
autoScroll(evt, this.options, elem, fallback); // Listener for pointer element change
|
2803
|
-
|
2804
|
-
var ogElemScroller = getParentAutoScrollElement(elem, true);
|
2805
|
-
|
2806
|
-
if (scrolling && (!pointerElemChangedInterval || x !== lastAutoScrollX || y !== lastAutoScrollY)) {
|
2807
|
-
pointerElemChangedInterval && clearPointerElemChangedInterval(); // Detect for pointer elem change, emulating native DnD behaviour
|
2808
|
-
|
2809
|
-
pointerElemChangedInterval = setInterval(function () {
|
2810
|
-
var newElem = getParentAutoScrollElement(document.elementFromPoint(x, y), true);
|
2811
|
-
|
2812
|
-
if (newElem !== ogElemScroller) {
|
2813
|
-
ogElemScroller = newElem;
|
2814
|
-
clearAutoScrolls();
|
2815
|
-
}
|
2816
|
-
|
2817
|
-
autoScroll(evt, _this.options, newElem, fallback);
|
2818
|
-
}, 10);
|
2819
|
-
lastAutoScrollX = x;
|
2820
|
-
lastAutoScrollY = y;
|
2821
|
-
}
|
2822
|
-
} else {
|
2823
|
-
// if DnD is enabled (and browser has good autoscrolling), first autoscroll will already scroll, so get parent autoscroll of first autoscroll
|
2824
|
-
if (!this.options.bubbleScroll || getParentAutoScrollElement(elem, true) === getWindowScrollingElement()) {
|
2825
|
-
clearAutoScrolls();
|
2826
|
-
return;
|
2827
|
-
}
|
2828
|
-
|
2829
|
-
autoScroll(evt, this.options, getParentAutoScrollElement(elem, false), false);
|
2830
|
-
}
|
2831
|
-
}
|
2832
|
-
};
|
2833
|
-
return _extends(AutoScroll, {
|
2834
|
-
pluginName: 'scroll',
|
2835
|
-
initializeByDefault: true
|
2836
|
-
});
|
2837
|
-
}
|
2838
|
-
|
2839
|
-
function clearAutoScrolls() {
|
2840
|
-
autoScrolls.forEach(function (autoScroll) {
|
2841
|
-
clearInterval(autoScroll.pid);
|
2842
|
-
});
|
2843
|
-
autoScrolls = [];
|
2844
|
-
}
|
2845
|
-
|
2846
|
-
function clearPointerElemChangedInterval() {
|
2847
|
-
clearInterval(pointerElemChangedInterval);
|
2848
|
-
}
|
2849
|
-
|
2850
|
-
var autoScroll = throttle(function (evt, options, rootEl, isFallback) {
|
2851
|
-
// Bug: https://bugzilla.mozilla.org/show_bug.cgi?id=505521
|
2852
|
-
if (!options.scroll) return;
|
2853
|
-
var x = (evt.touches ? evt.touches[0] : evt).clientX,
|
2854
|
-
y = (evt.touches ? evt.touches[0] : evt).clientY,
|
2855
|
-
sens = options.scrollSensitivity,
|
2856
|
-
speed = options.scrollSpeed,
|
2857
|
-
winScroller = getWindowScrollingElement();
|
2858
|
-
var scrollThisInstance = false,
|
2859
|
-
scrollCustomFn; // New scroll root, set scrollEl
|
2860
|
-
|
2861
|
-
if (scrollRootEl !== rootEl) {
|
2862
|
-
scrollRootEl = rootEl;
|
2863
|
-
clearAutoScrolls();
|
2864
|
-
scrollEl = options.scroll;
|
2865
|
-
scrollCustomFn = options.scrollFn;
|
2866
|
-
|
2867
|
-
if (scrollEl === true) {
|
2868
|
-
scrollEl = getParentAutoScrollElement(rootEl, true);
|
2869
|
-
}
|
2870
|
-
}
|
2871
|
-
|
2872
|
-
var layersOut = 0;
|
2873
|
-
var currentParent = scrollEl;
|
2874
|
-
|
2875
|
-
do {
|
2876
|
-
var el = currentParent,
|
2877
|
-
rect = getRect(el),
|
2878
|
-
top = rect.top,
|
2879
|
-
bottom = rect.bottom,
|
2880
|
-
left = rect.left,
|
2881
|
-
right = rect.right,
|
2882
|
-
width = rect.width,
|
2883
|
-
height = rect.height,
|
2884
|
-
canScrollX = void 0,
|
2885
|
-
canScrollY = void 0,
|
2886
|
-
scrollWidth = el.scrollWidth,
|
2887
|
-
scrollHeight = el.scrollHeight,
|
2888
|
-
elCSS = css(el),
|
2889
|
-
scrollPosX = el.scrollLeft,
|
2890
|
-
scrollPosY = el.scrollTop;
|
2891
|
-
|
2892
|
-
if (el === winScroller) {
|
2893
|
-
canScrollX = width < scrollWidth && (elCSS.overflowX === 'auto' || elCSS.overflowX === 'scroll' || elCSS.overflowX === 'visible');
|
2894
|
-
canScrollY = height < scrollHeight && (elCSS.overflowY === 'auto' || elCSS.overflowY === 'scroll' || elCSS.overflowY === 'visible');
|
2895
|
-
} else {
|
2896
|
-
canScrollX = width < scrollWidth && (elCSS.overflowX === 'auto' || elCSS.overflowX === 'scroll');
|
2897
|
-
canScrollY = height < scrollHeight && (elCSS.overflowY === 'auto' || elCSS.overflowY === 'scroll');
|
2898
|
-
}
|
2899
|
-
|
2900
|
-
var vx = canScrollX && (Math.abs(right - x) <= sens && scrollPosX + width < scrollWidth) - (Math.abs(left - x) <= sens && !!scrollPosX);
|
2901
|
-
var vy = canScrollY && (Math.abs(bottom - y) <= sens && scrollPosY + height < scrollHeight) - (Math.abs(top - y) <= sens && !!scrollPosY);
|
2902
|
-
|
2903
|
-
if (!autoScrolls[layersOut]) {
|
2904
|
-
for (var i = 0; i <= layersOut; i++) {
|
2905
|
-
if (!autoScrolls[i]) {
|
2906
|
-
autoScrolls[i] = {};
|
2907
|
-
}
|
2908
|
-
}
|
2909
|
-
}
|
2910
|
-
|
2911
|
-
if (autoScrolls[layersOut].vx != vx || autoScrolls[layersOut].vy != vy || autoScrolls[layersOut].el !== el) {
|
2912
|
-
autoScrolls[layersOut].el = el;
|
2913
|
-
autoScrolls[layersOut].vx = vx;
|
2914
|
-
autoScrolls[layersOut].vy = vy;
|
2915
|
-
clearInterval(autoScrolls[layersOut].pid);
|
2916
|
-
|
2917
|
-
if (vx != 0 || vy != 0) {
|
2918
|
-
scrollThisInstance = true;
|
2919
|
-
/* jshint loopfunc:true */
|
2920
|
-
|
2921
|
-
autoScrolls[layersOut].pid = setInterval(function () {
|
2922
|
-
// emulate drag over during autoscroll (fallback), emulating native DnD behaviour
|
2923
|
-
if (isFallback && this.layer === 0) {
|
2924
|
-
Sortable.active._onTouchMove(touchEvt$1); // To move ghost if it is positioned absolutely
|
2925
|
-
|
2926
|
-
}
|
2927
|
-
|
2928
|
-
var scrollOffsetY = autoScrolls[this.layer].vy ? autoScrolls[this.layer].vy * speed : 0;
|
2929
|
-
var scrollOffsetX = autoScrolls[this.layer].vx ? autoScrolls[this.layer].vx * speed : 0;
|
2930
|
-
|
2931
|
-
if (typeof scrollCustomFn === 'function') {
|
2932
|
-
if (scrollCustomFn.call(Sortable.dragged.parentNode[expando], scrollOffsetX, scrollOffsetY, evt, touchEvt$1, autoScrolls[this.layer].el) !== 'continue') {
|
2933
|
-
return;
|
2934
|
-
}
|
2935
|
-
}
|
2936
|
-
|
2937
|
-
scrollBy(autoScrolls[this.layer].el, scrollOffsetX, scrollOffsetY);
|
2938
|
-
}.bind({
|
2939
|
-
layer: layersOut
|
2940
|
-
}), 24);
|
2941
|
-
}
|
2942
|
-
}
|
2943
|
-
|
2944
|
-
layersOut++;
|
2945
|
-
} while (options.bubbleScroll && currentParent !== winScroller && (currentParent = getParentAutoScrollElement(currentParent, false)));
|
2946
|
-
|
2947
|
-
scrolling = scrollThisInstance; // in case another function catches scrolling as false in between when it is not
|
2948
|
-
}, 30);
|
2949
|
-
|
2950
|
-
var drop = function drop(_ref) {
|
2951
|
-
var originalEvent = _ref.originalEvent,
|
2952
|
-
putSortable = _ref.putSortable,
|
2953
|
-
dragEl = _ref.dragEl,
|
2954
|
-
activeSortable = _ref.activeSortable,
|
2955
|
-
dispatchSortableEvent = _ref.dispatchSortableEvent,
|
2956
|
-
hideGhostForTarget = _ref.hideGhostForTarget,
|
2957
|
-
unhideGhostForTarget = _ref.unhideGhostForTarget;
|
2958
|
-
if (!originalEvent) return;
|
2959
|
-
var toSortable = putSortable || activeSortable;
|
2960
|
-
hideGhostForTarget();
|
2961
|
-
var touch = originalEvent.changedTouches && originalEvent.changedTouches.length ? originalEvent.changedTouches[0] : originalEvent;
|
2962
|
-
var target = document.elementFromPoint(touch.clientX, touch.clientY);
|
2963
|
-
unhideGhostForTarget();
|
2964
|
-
|
2965
|
-
if (toSortable && !toSortable.el.contains(target)) {
|
2966
|
-
dispatchSortableEvent('spill');
|
2967
|
-
this.onSpill({
|
2968
|
-
dragEl: dragEl,
|
2969
|
-
putSortable: putSortable
|
2970
|
-
});
|
2971
|
-
}
|
2972
|
-
};
|
2973
|
-
|
2974
|
-
function Revert() {}
|
2975
|
-
|
2976
|
-
Revert.prototype = {
|
2977
|
-
startIndex: null,
|
2978
|
-
dragStart: function dragStart(_ref2) {
|
2979
|
-
var oldDraggableIndex = _ref2.oldDraggableIndex;
|
2980
|
-
this.startIndex = oldDraggableIndex;
|
2981
|
-
},
|
2982
|
-
onSpill: function onSpill(_ref3) {
|
2983
|
-
var dragEl = _ref3.dragEl,
|
2984
|
-
putSortable = _ref3.putSortable;
|
2985
|
-
this.sortable.captureAnimationState();
|
2986
|
-
|
2987
|
-
if (putSortable) {
|
2988
|
-
putSortable.captureAnimationState();
|
2989
|
-
}
|
2990
|
-
|
2991
|
-
var nextSibling = getChild(this.sortable.el, this.startIndex, this.options);
|
2992
|
-
|
2993
|
-
if (nextSibling) {
|
2994
|
-
this.sortable.el.insertBefore(dragEl, nextSibling);
|
2995
|
-
} else {
|
2996
|
-
this.sortable.el.appendChild(dragEl);
|
2997
|
-
}
|
2998
|
-
|
2999
|
-
this.sortable.animateAll();
|
3000
|
-
|
3001
|
-
if (putSortable) {
|
3002
|
-
putSortable.animateAll();
|
3003
|
-
}
|
3004
|
-
},
|
3005
|
-
drop: drop
|
3006
|
-
};
|
3007
|
-
|
3008
|
-
_extends(Revert, {
|
3009
|
-
pluginName: 'revertOnSpill'
|
3010
|
-
});
|
3011
|
-
|
3012
|
-
function Remove() {}
|
3013
|
-
|
3014
|
-
Remove.prototype = {
|
3015
|
-
onSpill: function onSpill(_ref4) {
|
3016
|
-
var dragEl = _ref4.dragEl,
|
3017
|
-
putSortable = _ref4.putSortable;
|
3018
|
-
var parentSortable = putSortable || this.sortable;
|
3019
|
-
parentSortable.captureAnimationState();
|
3020
|
-
dragEl.parentNode && dragEl.parentNode.removeChild(dragEl);
|
3021
|
-
parentSortable.animateAll();
|
3022
|
-
},
|
3023
|
-
drop: drop
|
3024
|
-
};
|
3025
|
-
|
3026
|
-
_extends(Remove, {
|
3027
|
-
pluginName: 'removeOnSpill'
|
3028
|
-
});
|
3029
|
-
|
3030
|
-
Sortable.mount(new AutoScrollPlugin());
|
3031
|
-
Sortable.mount(Remove, Revert);
|
3032
|
-
|
3033
|
-
const guxTabAdvancedListCss = ".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)}.gux-icon-anchor gux-icon{padding-right:var(--gse-ui-links-inLine-padding)}gux-tab-advanced-list .gux-tab-container{display:flex;align-items:flex-end;width:100%;height:50px;margin-bottom:16px;overflow-x:auto;overflow-y:hidden;background-color:#f6f7f9;border-bottom:1px solid #d7dce5;border-radius:4px 4px 0 0}gux-tab-advanced-list .gux-tab-container .action-button-container{display:flex;border-radius:4px}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button{min-width:35px;height:50px;padding:0;margin-left:2px;color:#2e394c;background-color:#e2e6ee;border:none;border-radius:4px;transition:color 0.25s}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button [slot=add-tab]{display:inline-flex;align-items:center;padding:0 12px;white-space:nowrap;font-family:var(--gse-core-fontFamily-body), sans-serif;font-weight:var(--gse-core-fontWeight-bold)}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button [slot=add-tab] gux-icon{padding-right:8px}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button:disabled{opacity:0.5}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button:hover{background-color:#d7dce5}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button:active{background-color:#c8cfda}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button:focus-visible{outline:none;box-shadow:inset 0 0 0 3px #aac9ff}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button:focus-visible{border-radius:5px;outline:none;box-shadow:inset 0 0 0 3px #aac9ff}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button gux-icon{width:16px;height:16px}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container{display:flex;border-radius:4px}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button{display:flex;align-items:center;justify-content:center;width:28px;height:50px;padding:0;color:#2e394c;background-color:#e2e6ee;border:none;border-radius:4px;transition:color 0.25s}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button:focus-visible{border:3px solid #aac9ff;border-radius:5px;outline:none}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button gux-icon{width:16px;height:16px}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button:focus-visible{border:3px solid #aac9ff;outline:none}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button:hover{background-color:#d7dce5}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button:active{background-color:#c8cfda}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button: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-tab-advanced-list .gux-tab-container .gux-scrollable-section{display:flex;align-items:flex-end;height:50px;overflow-x:auto;scroll-behavior:smooth;scrollbar-width:none}gux-tab-advanced-list .gux-tab-container .gux-scrollable-section::-webkit-scrollbar{height:0}gux-tab-advanced-list .gux-sr-only{position:absolute;top:auto;left:-10000px;width:1px;height:1px;overflow:hidden}";
|
14
|
+
const guxTabAdvancedListCss = "gux-tab-advanced-list .gux-tab-container{display:flex;align-items:flex-end;width:100%;height:50px;margin-bottom:16px;overflow-x:auto;overflow-y:hidden;background-color:#f6f7f9;border-bottom:1px solid #d7dce5;border-radius:4px 4px 0 0}gux-tab-advanced-list .gux-tab-container .action-button-container{display:flex;border-radius:4px}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button{min-width:35px;height:50px;padding:0;margin-left:2px;color:#2e394c;background-color:#e2e6ee;border:none;border-radius:4px;transition:color 0.25s}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button [slot=add-tab]{display:inline-flex;align-items:center;padding:0 12px;white-space:nowrap;font-family:var(--gse-core-fontFamily-body), sans-serif;font-weight:var(--gse-core-fontWeight-bold)}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button [slot=add-tab] gux-icon{padding-right:8px}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button:disabled{opacity:0.5}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button:hover{background-color:#d7dce5}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button:active{background-color:#c8cfda}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button:focus-visible{outline:none;box-shadow:inset 0 0 0 3px #aac9ff}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button:focus-visible{border-radius:5px;outline:none;box-shadow:inset 0 0 0 3px #aac9ff}gux-tab-advanced-list .gux-tab-container .action-button-container .add-tab-button gux-icon{width:16px;height:16px}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container{display:flex;border-radius:4px}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button{display:flex;align-items:center;justify-content:center;width:28px;height:50px;padding:0;color:#2e394c;background-color:#e2e6ee;border:none;border-radius:4px;transition:color 0.25s}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button:focus-visible{border:3px solid #aac9ff;border-radius:5px;outline:none}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button gux-icon{width:16px;height:16px}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button:focus-visible{border:3px solid #aac9ff;outline:none}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button:hover{background-color:#d7dce5}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button:active{background-color:#c8cfda}gux-tab-advanced-list .gux-tab-container .action-button-container .gux-scroll-button-container .gux-scroll-button:focus-visible{outline:var(--gse-semantic-focusRing-default-border-color) var(--gse-semantic-focusRing-default-border-style) var(--gse-semantic-focusRing-default-border-width);outline-offset:var(--gse-semantic-focusRing-offset)}gux-tab-advanced-list .gux-tab-container .gux-scrollable-section{display:flex;align-items:flex-end;height:50px;overflow-x:auto;scroll-behavior:smooth;scrollbar-width:none}gux-tab-advanced-list .gux-tab-container .gux-scrollable-section::-webkit-scrollbar{height:0}gux-tab-advanced-list .gux-sr-only{position:absolute;top:auto;left:-10000px;width:1px;height:1px;overflow:hidden}";
|
3034
15
|
|
3035
16
|
var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
|
3036
17
|
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
@@ -3044,9 +25,9 @@ var __decorate = (undefined && undefined.__decorate) || function (decorators, ta
|
|
3044
25
|
};
|
3045
26
|
const GuxTabAdvancedList = class {
|
3046
27
|
constructor(hostRef) {
|
3047
|
-
index
|
3048
|
-
this.newTab = index
|
3049
|
-
this.sortChanged = index
|
28
|
+
index.registerInstance(this, hostRef);
|
29
|
+
this.newTab = index.createEvent(this, "newTab", 7);
|
30
|
+
this.sortChanged = index.createEvent(this, "sortChanged", 7);
|
3050
31
|
this.showNewTabButton = true;
|
3051
32
|
this.tabLimit = Infinity;
|
3052
33
|
this.allowSort = true;
|
@@ -3307,7 +288,7 @@ const GuxTabAdvancedList = class {
|
|
3307
288
|
}
|
3308
289
|
}
|
3309
290
|
createSortable() {
|
3310
|
-
this.sortableInstance = new Sortable(this.root.querySelector('.gux-scrollable-section'), {
|
291
|
+
this.sortableInstance = new sortable_esm.Sortable(this.root.querySelector('.gux-scrollable-section'), {
|
3311
292
|
animation: 250,
|
3312
293
|
draggable: 'gux-tab-advanced',
|
3313
294
|
filter: '.ignore-sort',
|
@@ -3330,7 +311,7 @@ const GuxTabAdvancedList = class {
|
|
3330
311
|
this.sortChanged.emit(tabIds);
|
3331
312
|
}
|
3332
313
|
checkForScrollbarHideOrShow() {
|
3333
|
-
index
|
314
|
+
index.readTask(() => {
|
3334
315
|
const el = this.root.querySelector('.gux-scrollable-section');
|
3335
316
|
const hasScrollbar = el.clientWidth < el.scrollWidth;
|
3336
317
|
if (hasScrollbar !== this.hasScrollbar) {
|
@@ -3381,7 +362,7 @@ const GuxTabAdvancedList = class {
|
|
3381
362
|
}
|
3382
363
|
async componentWillLoad() {
|
3383
364
|
this.setTabTriggers();
|
3384
|
-
this.i18n = await index$
|
365
|
+
this.i18n = await index$1.buildI18nForComponent(this.root, en.tabsResources, 'gux-tabs-advanced');
|
3385
366
|
}
|
3386
367
|
validateSortableInstance() {
|
3387
368
|
if (this.allowSort && !this.sortableInstance) {
|
@@ -3411,7 +392,7 @@ const GuxTabAdvancedList = class {
|
|
3411
392
|
}, 500);
|
3412
393
|
}
|
3413
394
|
scrollLeft() {
|
3414
|
-
index
|
395
|
+
index.writeTask(() => {
|
3415
396
|
var _a;
|
3416
397
|
this.root
|
3417
398
|
.querySelector('.gux-scrollable-section')
|
@@ -3419,7 +400,7 @@ const GuxTabAdvancedList = class {
|
|
3419
400
|
});
|
3420
401
|
}
|
3421
402
|
scrollRight() {
|
3422
|
-
index
|
403
|
+
index.writeTask(() => {
|
3423
404
|
var _a;
|
3424
405
|
this.root
|
3425
406
|
.querySelector('.gux-scrollable-section')
|
@@ -3428,13 +409,13 @@ const GuxTabAdvancedList = class {
|
|
3428
409
|
}
|
3429
410
|
scrollToStart() {
|
3430
411
|
const scrollableSection = this.root.querySelector('.gux-scrollable-section');
|
3431
|
-
index
|
412
|
+
index.writeTask(() => {
|
3432
413
|
scrollableSection === null || scrollableSection === void 0 ? void 0 : scrollableSection.scrollBy(-(scrollableSection === null || scrollableSection === void 0 ? void 0 : scrollableSection.scrollWidth), 0);
|
3433
414
|
});
|
3434
415
|
}
|
3435
416
|
scrollToEnd() {
|
3436
417
|
const scrollableSection = this.root.querySelector('.gux-scrollable-section');
|
3437
|
-
index
|
418
|
+
index.writeTask(() => {
|
3438
419
|
scrollableSection.scrollBy(scrollableSection === null || scrollableSection === void 0 ? void 0 : scrollableSection.scrollWidth, 0);
|
3439
420
|
});
|
3440
421
|
}
|
@@ -3444,19 +425,19 @@ const GuxTabAdvancedList = class {
|
|
3444
425
|
}
|
3445
426
|
render() {
|
3446
427
|
const AddNewTabButton = (props) => {
|
3447
|
-
return (index
|
428
|
+
return (index.h("button", { title: this.disableAddTabButton
|
3448
429
|
? this.i18n('disableNewTab')
|
3449
430
|
: this.root.querySelector('[slot="add-tab"]')
|
3450
431
|
? this.root.querySelector('[slot="add-tab"]').textContent.trim()
|
3451
|
-
: this.i18n('createNewTab'), class: "add-tab-button", onClick: () => props.onClick(), disabled: this.disableAddTabButton }, index
|
432
|
+
: this.i18n('createNewTab'), class: "add-tab-button", onClick: () => props.onClick(), disabled: this.disableAddTabButton }, index.h("slot", { name: "add-tab" }, index.h("gux-icon", { "icon-name": "add", decorative: true }))));
|
3452
433
|
};
|
3453
434
|
return [
|
3454
|
-
index
|
3455
|
-
index
|
435
|
+
index.h("span", { class: "gux-sr-only gux-aria-live-region", "aria-live": "polite" }, this.ariaLiveAlert ? this.i18n(this.ariaLiveAlert) : ''),
|
436
|
+
index.h("div", { class: "gux-tab-container" }, index.h("div", { class: "action-button-container" }, this.renderScrollButton('scrollLeft')), index.h("div", { role: "tablist", class: `gux-scrollable-section ${this.keyboardSort ? 'gux-tab-sorting' : ''}`, "aria-owns": this.triggerIds }, index.h("slot", null)), index.h("div", { class: "action-button-container" }, this.renderScrollButton('scrollRight'), this.showNewTabButton ? (index.h(AddNewTabButton, { onClick: () => this.newTab.emit() })) : null))
|
3456
437
|
];
|
3457
438
|
}
|
3458
439
|
renderScrollButton(direction) {
|
3459
|
-
return (index
|
440
|
+
return (index.h("div", { class: "gux-scroll-button-container" }, this.hasScrollbar ? (index.h("button", { tabindex: "-1", title: this.i18n(direction), "aria-label": this.i18n(direction), class: "gux-scroll-button", onDragOver: () => this.getScrollDirection(direction), onClick: () => this.getScrollDirection(direction) }, index.h("gux-icon", { "icon-name": this.getChevronIconName(direction), decorative: true }))) : null));
|
3460
441
|
}
|
3461
442
|
getScrollDirection(direction) {
|
3462
443
|
switch (direction) {
|
@@ -3476,7 +457,7 @@ const GuxTabAdvancedList = class {
|
|
3476
457
|
return 'chevron-right';
|
3477
458
|
}
|
3478
459
|
}
|
3479
|
-
get root() { return index
|
460
|
+
get root() { return index.getElement(this); }
|
3480
461
|
static get watchers() { return {
|
3481
462
|
"allowSort": ["watchAllowSort"]
|
3482
463
|
}; }
|