@siemens/ix 2.0.0-beta.0 → 2.0.0-beta.1
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/base-button-c158438e.js +50 -0
- package/dist/cjs/base-button-c158438e.js.map +1 -0
- package/dist/cjs/base-icon-button-bbca2582.js +20 -0
- package/dist/cjs/base-icon-button-bbca2582.js.map +1 -0
- package/dist/cjs/breakpoints-e19e827e.js +27 -0
- package/dist/cjs/breakpoints-e19e827e.js.map +1 -0
- package/dist/cjs/context-0fdf2fa1.js +106 -0
- package/dist/cjs/context-0fdf2fa1.js.map +1 -0
- package/dist/cjs/{floating-ui.dom.esm-b79b633f.js → floating-ui.dom.esm-3b936e26.js} +654 -534
- package/dist/cjs/floating-ui.dom.esm-3b936e26.js.map +1 -0
- package/dist/cjs/{icon-eeb2940a.js → icon-9e9f2faf.js} +2 -2
- package/dist/cjs/{icon-eeb2940a.js.map → icon-9e9f2faf.js.map} +1 -1
- package/dist/cjs/index-1061a1c1.js +8 -0
- package/dist/cjs/index-1061a1c1.js.map +1 -0
- package/dist/cjs/{index-e56a1d39.js → index-be499a74.js} +45 -398
- package/dist/cjs/index-be499a74.js.map +1 -0
- package/dist/cjs/index.cjs.js +4 -4
- package/dist/cjs/ix-action-card.cjs.entry.js +3 -3
- package/dist/cjs/ix-action-card.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-application-header.cjs.entry.js +10 -5
- package/dist/cjs/ix-application-header.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-application-sidebar.cjs.entry.js +47 -0
- package/dist/cjs/ix-application-sidebar.cjs.entry.js.map +1 -0
- package/dist/cjs/ix-application.cjs.entry.js +109 -0
- package/dist/cjs/ix-application.cjs.entry.js.map +1 -0
- package/dist/cjs/ix-avatar.cjs.entry.js +1 -1
- package/dist/cjs/ix-basic-navigation.cjs.entry.js +44 -10
- package/dist/cjs/ix-basic-navigation.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-blind.cjs.entry.js +5 -4
- package/dist/cjs/ix-blind.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-breadcrumb_2.cjs.entry.js +100 -92
- package/dist/cjs/ix-breadcrumb_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-burger-menu.cjs.entry.js +3 -3
- package/dist/cjs/ix-burger-menu.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-button.cjs.entry.js +22 -7
- package/dist/cjs/ix-button.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-card-accordion_2.cjs.entry.js +2 -2
- package/dist/cjs/ix-card-accordion_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-card-list.cjs.entry.js +2 -2
- package/dist/cjs/ix-card-list.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-card_2.cjs.entry.js +3 -3
- package/dist/cjs/ix-card_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-category-filter.cjs.entry.js +73 -40
- package/dist/cjs/ix-category-filter.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-chip.cjs.entry.js +2 -2
- package/dist/cjs/ix-chip.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-col.cjs.entry.js +77 -0
- package/dist/cjs/ix-col.cjs.entry.js.map +1 -0
- package/dist/cjs/ix-content-header.cjs.entry.js +1 -1
- package/dist/cjs/ix-content.cjs.entry.js +32 -0
- package/dist/cjs/ix-content.cjs.entry.js.map +1 -0
- package/dist/cjs/ix-css-grid-item.cjs.entry.js +1 -1
- package/dist/cjs/ix-css-grid-item.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-css-grid.cjs.entry.js +1 -1
- package/dist/cjs/ix-css-grid.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-date-picker_2.cjs.entry.js +4 -4
- package/dist/cjs/ix-date-picker_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-date-time-card.cjs.entry.js +2 -2
- package/dist/cjs/ix-date-time-card.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-datetime-picker.cjs.entry.js +2 -2
- package/dist/cjs/ix-datetime-picker.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-divider.cjs.entry.js +1 -1
- package/dist/cjs/ix-drawer.cjs.entry.js +2 -2
- package/dist/cjs/ix-drawer.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-dropdown-button.cjs.entry.js +4 -3
- package/dist/cjs/ix-dropdown-button.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-dropdown-header.cjs.entry.js +2 -2
- package/dist/cjs/ix-dropdown-header.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-dropdown-quick-actions.cjs.entry.js +1 -1
- package/dist/cjs/ix-dropdown_2.cjs.entry.js +6 -8
- package/dist/cjs/ix-dropdown_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-empty-state.cjs.entry.js +2 -2
- package/dist/cjs/ix-empty-state.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-event-list_2.cjs.entry.js +3 -3
- package/dist/cjs/ix-event-list_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-expanding-search.cjs.entry.js +2 -2
- package/dist/cjs/ix-expanding-search.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-filter-chip.cjs.entry.js +4 -3
- package/dist/cjs/ix-filter-chip.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-flip-tile_2.cjs.entry.js +28 -18
- package/dist/cjs/ix-flip-tile_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-form-field.cjs.entry.js +27 -0
- package/dist/cjs/ix-form-field.cjs.entry.js.map +1 -0
- package/dist/cjs/ix-grid.cjs.entry.js +29 -0
- package/dist/cjs/ix-grid.cjs.entry.js.map +1 -0
- package/dist/cjs/ix-group-context-menu.cjs.entry.js +2 -2
- package/dist/cjs/ix-group_2.cjs.entry.js +4 -4
- package/dist/cjs/ix-group_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-icon-button.cjs.entry.js +21 -13
- package/dist/cjs/ix-icon-button.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-icon-toggle-button.cjs.entry.js +88 -0
- package/dist/cjs/ix-icon-toggle-button.cjs.entry.js.map +1 -0
- package/dist/cjs/ix-icon.cjs.entry.js +2 -2
- package/dist/cjs/ix-input-group.cjs.entry.js +85 -18
- package/dist/cjs/ix-input-group.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-key-value-list.cjs.entry.js +1 -1
- package/dist/cjs/ix-key-value.cjs.entry.js +1 -1
- package/dist/cjs/ix-kpi.cjs.entry.js +2 -2
- package/dist/cjs/ix-kpi.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-link-button.cjs.entry.js +2 -2
- package/dist/cjs/ix-link-button.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-map-navigation_2.cjs.entry.js +11 -3
- package/dist/cjs/ix-map-navigation_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-menu-category.cjs.entry.js +6 -5
- package/dist/cjs/ix-menu-category.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-menu_9.cjs.entry.js +101 -75
- package/dist/cjs/ix-menu_9.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-message-bar.cjs.entry.js +2 -2
- package/dist/cjs/ix-message-bar.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-modal-content.cjs.entry.js +2 -2
- package/dist/cjs/ix-modal-content.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-modal-example.cjs.entry.js +1 -1
- package/dist/cjs/ix-modal-footer.cjs.entry.js +2 -2
- package/dist/cjs/ix-modal-footer.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-modal-header.cjs.entry.js +2 -2
- package/dist/cjs/ix-modal-header.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-modal-loading.cjs.entry.js +1 -1
- package/dist/cjs/ix-modal.cjs.entry.js +2 -2
- package/dist/cjs/ix-modal.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-pagination.cjs.entry.js +32 -15
- package/dist/cjs/ix-pagination.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-pill.cjs.entry.js +2 -2
- package/dist/cjs/ix-pill.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-push-card.cjs.entry.js +5 -2
- package/dist/cjs/ix-push-card.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-row.cjs.entry.js +21 -0
- package/dist/cjs/ix-row.cjs.entry.js.map +1 -0
- package/dist/cjs/ix-select_2.cjs.entry.js +68 -49
- package/dist/cjs/ix-select_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-spinner.cjs.entry.js +2 -2
- package/dist/cjs/ix-spinner.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-split-button_2.cjs.entry.js +7 -5
- package/dist/cjs/ix-split-button_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-tab-item.cjs.entry.js +11 -3
- package/dist/cjs/ix-tab-item.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-tabs.cjs.entry.js +22 -7
- package/dist/cjs/ix-tabs.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-tile.cjs.entry.js +2 -2
- package/dist/cjs/ix-tile.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-toast_2.cjs.entry.js +2 -2
- package/dist/cjs/ix-toast_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-toggle-button.cjs.entry.js +77 -0
- package/dist/cjs/ix-toggle-button.cjs.entry.js.map +1 -0
- package/dist/cjs/ix-toggle.cjs.entry.js +2 -2
- package/dist/cjs/ix-toggle.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-tooltip.cjs.entry.js +2 -2
- package/dist/cjs/ix-tree_2.cjs.entry.js +16 -9
- package/dist/cjs/ix-tree_2.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-typography.cjs.entry.js +25 -12
- package/dist/cjs/ix-typography.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-upload.cjs.entry.js +2 -2
- package/dist/cjs/ix-upload.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-validation-tooltip.cjs.entry.js +8 -8
- package/dist/cjs/ix-validation-tooltip.cjs.entry.js.map +1 -1
- package/dist/cjs/ix-workflow-step_2.cjs.entry.js +14 -18
- package/dist/cjs/ix-workflow-step_2.cjs.entry.js.map +1 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/menu-service-f7ef5265.js +159 -0
- package/dist/cjs/menu-service-f7ef5265.js.map +1 -0
- package/dist/cjs/my-component.cjs.entry.js +1 -1
- package/dist/cjs/my-component.cjs.entry.js.map +1 -1
- package/dist/cjs/{shadow-dom-f9b90696.js → shadow-dom-9b10f758.js} +4 -1
- package/dist/cjs/shadow-dom-9b10f758.js.map +1 -0
- package/dist/cjs/siemens-ix.cjs.js +2 -2
- package/dist/cjs/{theme-switcher-bdbd0d30.js → theme-switcher-d0386ac9.js} +36 -4
- package/dist/cjs/theme-switcher-d0386ac9.js.map +1 -0
- package/dist/collection/collection-manifest.json +13 -13
- package/dist/collection/components/action-card/action-card.css +36 -0
- package/dist/collection/components/action-card/action-card.js +1 -1
- package/dist/collection/components/action-card/action-card.js.map +1 -1
- package/dist/collection/components/application/application.css +106 -0
- package/dist/collection/components/application/application.js +220 -0
- package/dist/collection/components/application/application.js.map +1 -0
- package/dist/collection/components/application-header/application-header.css +4 -2
- package/dist/collection/components/application-header/application-header.js +8 -28
- package/dist/collection/components/application-header/application-header.js.map +1 -1
- package/dist/collection/components/application-header/test/application-headet.ct.js +20 -0
- package/dist/collection/components/application-header/test/application-headet.ct.js.map +1 -0
- package/dist/collection/components/application-sidebar/application-sidebar.css +69 -0
- package/dist/collection/components/application-sidebar/application-sidebar.js +70 -0
- package/dist/collection/components/application-sidebar/application-sidebar.js.map +1 -0
- package/dist/collection/components/application-sidebar/events.js +15 -0
- package/dist/collection/components/application-sidebar/events.js.map +1 -0
- package/dist/collection/components/basic-navigation/basic-navigation.css +39 -2
- package/dist/collection/components/basic-navigation/basic-navigation.js +91 -8
- package/dist/collection/components/basic-navigation/basic-navigation.js.map +1 -1
- package/dist/collection/components/blind/blind.css +23 -8
- package/dist/collection/components/blind/blind.js +23 -2
- package/dist/collection/components/blind/blind.js.map +1 -1
- package/dist/collection/components/breadcrumb/breadcrumb.css +49 -153
- package/dist/collection/components/breadcrumb/breadcrumb.js +80 -92
- package/dist/collection/components/breadcrumb/breadcrumb.js.map +1 -1
- package/dist/collection/components/breadcrumb/test/breadcrumb.ct.js +97 -0
- package/dist/collection/components/breadcrumb/test/breadcrumb.ct.js.map +1 -0
- package/dist/collection/components/breadcrumb-item/breadcrumb-item.css +1063 -1
- package/dist/collection/components/breadcrumb-item/breadcrumb-item.js +153 -3
- package/dist/collection/components/breadcrumb-item/breadcrumb-item.js.map +1 -1
- package/dist/collection/components/button/base-button.js +10 -1
- package/dist/collection/components/button/base-button.js.map +1 -1
- package/dist/collection/components/button/button.css +287 -208
- package/dist/collection/components/button/button.js +62 -44
- package/dist/collection/components/button/button.js.map +1 -1
- package/dist/collection/components/card/card.css +36 -0
- package/dist/collection/components/card-accordion/card-accordion.css +37 -0
- package/dist/collection/components/card-content/card-content.css +36 -0
- package/dist/collection/components/card-list/card-list.css +36 -0
- package/dist/collection/components/category-filter/category-filter.css +1303 -4
- package/dist/collection/components/category-filter/category-filter.js +115 -55
- package/dist/collection/components/category-filter/category-filter.js.map +1 -1
- package/dist/collection/components/chip/chip.css +36 -0
- package/dist/collection/components/col/col.css +19 -0
- package/dist/collection/components/col/col.js +189 -0
- package/dist/collection/components/col/col.js.map +1 -0
- package/dist/collection/components/content/content.css +75 -0
- package/dist/collection/components/content/content.js +46 -0
- package/dist/collection/components/content/content.js.map +1 -0
- package/dist/collection/components/css-grid/builder.js.map +1 -0
- package/dist/collection/components/css-grid/css-grid-item.js.map +1 -0
- package/dist/collection/components/{layout/css-grid → css-grid}/css-grid.js +1 -1
- package/dist/collection/components/css-grid/css-grid.js.map +1 -0
- package/dist/collection/components/date-picker/date-picker.css +38 -0
- package/dist/collection/components/date-time-card/date-time-card.css +38 -0
- package/dist/collection/components/datetime-picker/datetime-picker.css +36 -0
- package/dist/collection/components/drawer/drawer.css +36 -0
- package/dist/collection/components/dropdown/dropdown.css +36 -0
- package/dist/collection/components/dropdown/dropdown.js.map +1 -1
- package/dist/collection/components/dropdown-button/dropdown-button.css +46 -4
- package/dist/collection/components/dropdown-button/dropdown-button.js +27 -1
- package/dist/collection/components/dropdown-button/dropdown-button.js.map +1 -1
- package/dist/collection/components/dropdown-header/dropdown-header.css +36 -0
- package/dist/collection/components/dropdown-item/dropdown-item.css +36 -0
- package/dist/collection/components/empty-state/empty-state.css +38 -0
- package/dist/collection/components/event-list/event-list.css +36 -0
- package/dist/collection/components/event-list-item/event-list-item.css +42 -4
- package/dist/collection/components/expanding-search/expanding-search.css +47 -4
- package/dist/collection/components/filter-chip/filter-chip.css +48 -1
- package/dist/collection/components/filter-chip/filter-chip.js +23 -1
- package/dist/collection/components/filter-chip/filter-chip.js.map +1 -1
- package/dist/collection/components/flip-tile/flip-tile.css +208 -0
- package/dist/collection/components/flip-tile/flip-tile.js +25 -36
- package/dist/collection/components/flip-tile/flip-tile.js.map +1 -1
- package/dist/collection/components/flip-tile/test/flip-tile.ct.js +57 -0
- package/dist/collection/components/flip-tile/test/flip-tile.ct.js.map +1 -0
- package/dist/collection/components/flip-tile-content/flip-tile-content.js +29 -1
- package/dist/collection/components/flip-tile-content/flip-tile-content.js.map +1 -1
- package/dist/collection/components/form-field/form-field.css +234 -0
- package/dist/collection/components/form-field/form-field.js +56 -0
- package/dist/collection/components/form-field/form-field.js.map +1 -0
- package/dist/collection/components/grid/grid.css +26 -0
- package/dist/collection/components/grid/grid.js +98 -0
- package/dist/collection/components/grid/grid.js.map +1 -0
- package/dist/collection/components/group/group.css +4 -4
- package/dist/collection/components/group-item/group-item.css +36 -0
- package/dist/collection/components/icon-button/base-icon-button.js +14 -0
- package/dist/collection/components/icon-button/base-icon-button.js.map +1 -0
- package/dist/collection/components/icon-button/icon-button.css +383 -173
- package/dist/collection/components/icon-button/icon-button.js +18 -49
- package/dist/collection/components/icon-button/icon-button.js.map +1 -1
- package/dist/collection/components/icon-toggle-button/icon-toggle-button.css +618 -0
- package/dist/collection/components/icon-toggle-button/icon-toggle-button.js +274 -0
- package/dist/collection/components/icon-toggle-button/icon-toggle-button.js.map +1 -0
- package/dist/collection/components/input-group/input-group.css +54 -1
- package/dist/collection/components/input-group/input-group.js +92 -17
- package/dist/collection/components/input-group/input-group.js.map +1 -1
- package/dist/collection/components/kpi/kpi.css +38 -2
- package/dist/collection/components/link-button/link-button.css +72 -66
- package/dist/collection/components/map-navigation/map-navigation.css +36 -0
- package/dist/collection/components/map-navigation/map-navigation.js +8 -0
- package/dist/collection/components/map-navigation/map-navigation.js.map +1 -1
- package/dist/collection/components/map-navigation-overlay/map-navigation-overlay.css +56 -0
- package/dist/collection/components/map-navigation-overlay/map-navigation-overlay.js +1 -1
- package/dist/collection/components/map-navigation-overlay/map-navigation-overlay.js.map +1 -1
- package/dist/collection/components/menu/burger-menu.css +104 -62
- package/dist/collection/components/menu/menu.css +45 -6
- package/dist/collection/components/menu/menu.js +66 -103
- package/dist/collection/components/menu/menu.js.map +1 -1
- package/dist/collection/components/menu/test/menu.ct.js +8 -10
- package/dist/collection/components/menu/test/menu.ct.js.map +1 -1
- package/dist/collection/components/menu-about/menu-about.css +2 -2
- package/dist/collection/components/menu-about/menu-about.js +3 -3
- package/dist/collection/components/menu-about/menu-about.js.map +1 -1
- package/dist/collection/components/menu-about-news/menu-about-news.css +36 -0
- package/dist/collection/components/menu-avatar/menu-avatar.css +46 -2
- package/dist/collection/components/menu-avatar/menu-avatar.js +2 -2
- package/dist/collection/components/menu-avatar/menu-avatar.js.map +1 -1
- package/dist/collection/components/menu-avatar-item/menu-avatar-item.css +36 -1
- package/dist/collection/components/menu-category/menu-category.css +41 -0
- package/dist/collection/components/menu-category/menu-category.js +3 -3
- package/dist/collection/components/menu-category/menu-category.js.map +1 -1
- package/dist/collection/components/menu-category/test/menu-category.ct.js +27 -10
- package/dist/collection/components/menu-category/test/menu-category.ct.js.map +1 -1
- package/dist/collection/components/menu-item/menu-item.css +11 -6
- package/dist/collection/components/menu-item/menu-item.js +7 -1
- package/dist/collection/components/menu-item/menu-item.js.map +1 -1
- package/dist/collection/components/menu-settings/menu-settings.css +40 -1
- package/dist/collection/components/menu-settings/menu-settings.js +1 -1
- package/dist/collection/components/menu-settings/menu-settings.js.map +1 -1
- package/dist/collection/components/message-bar/message-bar.css +38 -0
- package/dist/collection/components/modal/modal.css +3 -3
- package/dist/collection/components/modal-content/modal-content.css +36 -0
- package/dist/collection/components/modal-footer/modal-footer.css +36 -0
- package/dist/collection/components/modal-header/modal-header.css +36 -0
- package/dist/collection/components/my-component/my-component.js +1 -1
- package/dist/collection/components/my-component/my-component.js.map +1 -1
- package/dist/collection/components/pagination/pagination.css +919 -2
- package/dist/collection/components/pagination/pagination.js +31 -14
- package/dist/collection/components/pagination/pagination.js.map +1 -1
- package/dist/collection/components/pill/pill.css +36 -0
- package/dist/collection/components/push-card/push-card.js +4 -1
- package/dist/collection/components/push-card/push-card.js.map +1 -1
- package/dist/collection/components/{animated-tab/animated-tab.css → row/row.css} +7 -4
- package/dist/collection/components/row/row.js +30 -0
- package/dist/collection/components/row/row.js.map +1 -0
- package/dist/collection/components/select/select.css +71 -6
- package/dist/collection/components/select/select.js +118 -55
- package/dist/collection/components/select/select.js.map +1 -1
- package/dist/collection/components/select/test/select.ct.js +10 -6
- package/dist/collection/components/select/test/select.ct.js.map +1 -1
- package/dist/collection/components/select-item/select-item.js +1 -1
- package/dist/collection/components/select-item/select-item.js.map +1 -1
- package/dist/collection/components/spinner/spinner.css +148 -0
- package/dist/collection/components/split-button/split-button.css +36 -0
- package/dist/collection/components/split-button/split-button.js +1 -2
- package/dist/collection/components/split-button/split-button.js.map +1 -1
- package/dist/collection/components/split-button-item/split-button-item.js +4 -1
- package/dist/collection/components/split-button-item/split-button-item.js.map +1 -1
- package/dist/collection/components/tab-item/tab-item.css +36 -1
- package/dist/collection/components/tab-item/tab-item.js +34 -1
- package/dist/collection/components/tab-item/tab-item.js.map +1 -1
- package/dist/collection/components/tabs/tabs.css +36 -0
- package/dist/collection/components/tabs/tabs.js +46 -5
- package/dist/collection/components/tabs/tabs.js.map +1 -1
- package/dist/collection/components/tabs/test/tabs.ct.js +84 -0
- package/dist/collection/components/tabs/test/tabs.ct.js.map +1 -0
- package/dist/collection/components/tile/tile.css +36 -0
- package/dist/collection/components/time-picker/time-picker.css +274 -13
- package/dist/collection/components/time-picker/time-picker.js +1 -1
- package/dist/collection/components/time-picker/time-picker.js.map +1 -1
- package/dist/collection/components/toast/toast.css +36 -0
- package/dist/collection/components/toggle/toggle.css +36 -0
- package/dist/collection/components/toggle-button/toggle-button.css +447 -0
- package/dist/collection/components/toggle-button/toggle-button.js +246 -0
- package/dist/collection/components/toggle-button/toggle-button.js.map +1 -0
- package/dist/collection/components/tree/test/tree.ct.js +154 -0
- package/dist/collection/components/tree/test/tree.ct.js.map +1 -0
- package/dist/collection/components/tree/tree.js +14 -7
- package/dist/collection/components/tree/tree.js.map +1 -1
- package/dist/collection/components/tree-item/tree-item.css +56 -14
- package/dist/collection/components/tree-item/tree-item.js +1 -1
- package/dist/collection/components/tree-item/tree-item.js.map +1 -1
- package/dist/collection/components/typography/typography.css +391 -0
- package/dist/collection/components/typography/typography.js +95 -14
- package/dist/collection/components/typography/typography.js.map +1 -1
- package/dist/collection/components/upload/upload.css +36 -0
- package/dist/collection/components/utils/application-layout/context.js +19 -0
- package/dist/collection/components/utils/application-layout/context.js.map +1 -0
- package/dist/collection/components/utils/{screen → application-layout}/index.js +1 -1
- package/dist/collection/components/utils/application-layout/index.js.map +1 -0
- package/dist/collection/components/utils/application-layout/service.js +92 -0
- package/dist/collection/components/utils/application-layout/service.js.map +1 -0
- package/dist/collection/components/utils/breakpoints.js +22 -0
- package/dist/collection/components/utils/breakpoints.js.map +1 -0
- package/dist/collection/components/utils/context.js +79 -0
- package/dist/collection/components/utils/context.js.map +1 -0
- package/dist/collection/components/utils/shadow-dom.js +6 -0
- package/dist/collection/components/utils/shadow-dom.js.map +1 -1
- package/dist/collection/components/utils/theme-switcher.js +35 -3
- package/dist/collection/components/utils/theme-switcher.js.map +1 -1
- package/dist/collection/components/validation-tooltip/validation-tooltip.js +6 -6
- package/dist/collection/components/validation-tooltip/validation-tooltip.js.map +1 -1
- package/dist/collection/components/workflow-step/workflow-step.css +40 -2
- package/dist/collection/components/workflow-step/workflow-step.js +6 -13
- package/dist/collection/components/workflow-step/workflow-step.js.map +1 -1
- package/dist/collection/components/workflow-steps/test/workflow-steps.ct.js +74 -0
- package/dist/collection/components/workflow-steps/test/workflow-steps.ct.js.map +1 -0
- package/dist/collection/components/workflow-steps/workflow-steps.css +38 -0
- package/dist/collection/components/workflow-steps/workflow-steps.js +8 -26
- package/dist/collection/components/workflow-steps/workflow-steps.js.map +1 -1
- package/dist/components/application-header.js +9 -5
- package/dist/components/application-header.js.map +1 -1
- package/dist/components/base-button.js +16 -2
- package/dist/components/base-button.js.map +1 -1
- package/dist/components/base-icon-button.js +18 -0
- package/dist/components/base-icon-button.js.map +1 -0
- package/dist/components/breadcrumb-item.js +99 -0
- package/dist/components/breadcrumb-item.js.map +1 -0
- package/dist/components/breakpoints.js +25 -0
- package/dist/components/breakpoints.js.map +1 -0
- package/dist/components/burger-menu.js +1 -1
- package/dist/components/burger-menu.js.map +1 -1
- package/dist/components/button.js +24 -9
- package/dist/components/button.js.map +1 -1
- package/dist/components/card-accordion.js +1 -1
- package/dist/components/card-accordion.js.map +1 -1
- package/dist/components/card-content.js +1 -1
- package/dist/components/card-content.js.map +1 -1
- package/dist/components/card.js +1 -1
- package/dist/components/card.js.map +1 -1
- package/dist/components/context.js +86 -7
- package/dist/components/context.js.map +1 -1
- package/dist/components/date-picker.js +1 -1
- package/dist/components/date-picker.js.map +1 -1
- package/dist/components/date-time-card.js +1 -1
- package/dist/components/date-time-card.js.map +1 -1
- package/dist/components/dropdown-item.js +2 -4
- package/dist/components/dropdown-item.js.map +1 -1
- package/dist/components/dropdown.js +1 -1
- package/dist/components/dropdown.js.map +1 -1
- package/dist/components/filter-chip.js +5 -3
- package/dist/components/filter-chip.js.map +1 -1
- package/dist/components/floating-ui.dom.esm.js +653 -533
- package/dist/components/floating-ui.dom.esm.js.map +1 -1
- package/dist/components/group-context-menu.js +2 -16
- package/dist/components/group-context-menu.js.map +1 -1
- package/dist/components/group-item.js +1 -1
- package/dist/components/group-item.js.map +1 -1
- package/dist/components/icon-button.js +19 -14
- package/dist/components/icon-button.js.map +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/index2.js +6 -0
- package/dist/components/index2.js.map +1 -0
- package/dist/components/ix-action-card.js +2 -2
- package/dist/components/ix-action-card.js.map +1 -1
- package/dist/components/ix-application-sidebar.d.ts +11 -0
- package/dist/components/ix-application-sidebar.js +63 -0
- package/dist/components/ix-application-sidebar.js.map +1 -0
- package/dist/components/{ix-animated-tab.d.ts → ix-application.d.ts} +4 -4
- package/dist/components/ix-application.js +128 -0
- package/dist/components/ix-application.js.map +1 -0
- package/dist/components/ix-basic-navigation.js +45 -10
- package/dist/components/ix-basic-navigation.js.map +1 -1
- package/dist/components/ix-blind.js +13 -5
- package/dist/components/ix-blind.js.map +1 -1
- package/dist/components/ix-breadcrumb-item.js +1 -32
- package/dist/components/ix-breadcrumb-item.js.map +1 -1
- package/dist/components/ix-breadcrumb.js +76 -98
- package/dist/components/ix-breadcrumb.js.map +1 -1
- package/dist/components/ix-card-list.js +1 -1
- package/dist/components/ix-card-list.js.map +1 -1
- package/dist/components/ix-category-filter.js +76 -41
- package/dist/components/ix-category-filter.js.map +1 -1
- package/dist/components/ix-chip.js +1 -1
- package/dist/components/ix-chip.js.map +1 -1
- package/dist/components/{ix-index-button.d.ts → ix-col.d.ts} +4 -4
- package/dist/components/ix-col.js +96 -0
- package/dist/components/ix-col.js.map +1 -0
- package/dist/components/ix-content.d.ts +11 -0
- package/dist/components/ix-content.js +48 -0
- package/dist/components/ix-content.js.map +1 -0
- package/dist/components/ix-css-grid-item.js.map +1 -1
- package/dist/components/ix-css-grid.js.map +1 -1
- package/dist/components/ix-datetime-picker.js +23 -17
- package/dist/components/ix-datetime-picker.js.map +1 -1
- package/dist/components/ix-drawer.js +1 -1
- package/dist/components/ix-drawer.js.map +1 -1
- package/dist/components/ix-dropdown-button.js +4 -2
- package/dist/components/ix-dropdown-button.js.map +1 -1
- package/dist/components/ix-dropdown-header.js +1 -1
- package/dist/components/ix-dropdown-header.js.map +1 -1
- package/dist/components/ix-empty-state.js +1 -1
- package/dist/components/ix-empty-state.js.map +1 -1
- package/dist/components/ix-event-list-item.js +1 -1
- package/dist/components/ix-event-list-item.js.map +1 -1
- package/dist/components/ix-event-list.js +1 -1
- package/dist/components/ix-event-list.js.map +1 -1
- package/dist/components/ix-expanding-search.js +1 -1
- package/dist/components/ix-expanding-search.js.map +1 -1
- package/dist/components/ix-flip-tile-content.js +5 -2
- package/dist/components/ix-flip-tile-content.js.map +1 -1
- package/dist/components/ix-flip-tile.js +27 -18
- package/dist/components/ix-flip-tile.js.map +1 -1
- package/dist/components/ix-form-field.d.ts +11 -0
- package/dist/components/ix-form-field.js +43 -0
- package/dist/components/ix-form-field.js.map +1 -0
- package/dist/components/ix-grid.d.ts +11 -0
- package/dist/components/ix-grid.js +47 -0
- package/dist/components/ix-grid.js.map +1 -0
- package/dist/components/ix-group.js +3 -2
- package/dist/components/ix-group.js.map +1 -1
- package/dist/components/ix-icon-toggle-button.d.ts +11 -0
- package/dist/components/ix-icon-toggle-button.js +122 -0
- package/dist/components/ix-icon-toggle-button.js.map +1 -0
- package/dist/components/ix-input-group.js +89 -18
- package/dist/components/ix-input-group.js.map +1 -1
- package/dist/components/ix-kpi.js +1 -1
- package/dist/components/ix-kpi.js.map +1 -1
- package/dist/components/ix-link-button.js +1 -1
- package/dist/components/ix-link-button.js.map +1 -1
- package/dist/components/ix-map-navigation.js +8 -1
- package/dist/components/ix-map-navigation.js.map +1 -1
- package/dist/components/ix-menu-about-news.js +1 -1
- package/dist/components/ix-menu-about-news.js.map +1 -1
- package/dist/components/ix-menu-about.js +4 -4
- package/dist/components/ix-menu-about.js.map +1 -1
- package/dist/components/ix-menu-avatar.js +3 -3
- package/dist/components/ix-menu-avatar.js.map +1 -1
- package/dist/components/ix-menu-category.js +4 -4
- package/dist/components/ix-menu-category.js.map +1 -1
- package/dist/components/ix-menu-settings.js +2 -2
- package/dist/components/ix-menu-settings.js.map +1 -1
- package/dist/components/ix-menu.js +80 -62
- package/dist/components/ix-menu.js.map +1 -1
- package/dist/components/ix-message-bar.js +1 -1
- package/dist/components/ix-message-bar.js.map +1 -1
- package/dist/components/ix-modal-content.js +1 -1
- package/dist/components/ix-modal-content.js.map +1 -1
- package/dist/components/ix-modal-footer.js +1 -1
- package/dist/components/ix-modal-footer.js.map +1 -1
- package/dist/components/ix-modal-header.js +1 -1
- package/dist/components/ix-modal-header.js.map +1 -1
- package/dist/components/ix-modal.js +1 -1
- package/dist/components/ix-modal.js.map +1 -1
- package/dist/components/ix-pagination.js +42 -24
- package/dist/components/ix-pagination.js.map +1 -1
- package/dist/components/ix-pill.js +1 -1
- package/dist/components/ix-pill.js.map +1 -1
- package/dist/components/ix-push-card.js +4 -1
- package/dist/components/ix-push-card.js.map +1 -1
- package/dist/components/ix-row.d.ts +11 -0
- package/dist/components/ix-row.js +35 -0
- package/dist/components/ix-row.js.map +1 -0
- package/dist/components/ix-split-button-item.js +4 -1
- package/dist/components/ix-split-button-item.js.map +1 -1
- package/dist/components/ix-split-button.js +2 -3
- package/dist/components/ix-split-button.js.map +1 -1
- package/dist/components/ix-tile.js +1 -1
- package/dist/components/ix-tile.js.map +1 -1
- package/dist/components/{ix-animated-tabs.d.ts → ix-toggle-button.d.ts} +4 -4
- package/dist/components/ix-toggle-button.js +111 -0
- package/dist/components/ix-toggle-button.js.map +1 -0
- package/dist/components/ix-toggle.js +1 -1
- package/dist/components/ix-toggle.js.map +1 -1
- package/dist/components/ix-tree.js +16 -8
- package/dist/components/ix-tree.js.map +1 -1
- package/dist/components/ix-upload.js +1 -1
- package/dist/components/ix-upload.js.map +1 -1
- package/dist/components/ix-validation-tooltip.js +8 -7
- package/dist/components/ix-validation-tooltip.js.map +1 -1
- package/dist/components/ix-workflow-step.js +5 -12
- package/dist/components/ix-workflow-step.js.map +1 -1
- package/dist/components/ix-workflow-steps.js +9 -7
- package/dist/components/ix-workflow-steps.js.map +1 -1
- package/dist/components/map-navigation-overlay.js +3 -2
- package/dist/components/map-navigation-overlay.js.map +1 -1
- package/dist/components/menu-avatar-item.js +1 -1
- package/dist/components/menu-avatar-item.js.map +1 -1
- package/dist/components/menu-item.js +8 -2
- package/dist/components/menu-item.js.map +1 -1
- package/dist/components/menu-service.js +79 -1
- package/dist/components/menu-service.js.map +1 -1
- package/dist/components/my-component.js.map +1 -1
- package/dist/components/select-item.js +3 -2
- package/dist/components/select-item.js.map +1 -1
- package/dist/components/select.js +70 -49
- package/dist/components/select.js.map +1 -1
- package/dist/{esm/shadow-dom-6860b1c4.js → components/shadow-dom.js} +4 -1
- package/dist/components/shadow-dom.js.map +1 -0
- package/dist/components/spinner.js +1 -1
- package/dist/components/spinner.js.map +1 -1
- package/dist/components/tab-item.js +11 -3
- package/dist/components/tab-item.js.map +1 -1
- package/dist/components/tabs.js +23 -8
- package/dist/components/tabs.js.map +1 -1
- package/dist/components/theme-switcher.js +35 -3
- package/dist/components/theme-switcher.js.map +1 -1
- package/dist/components/time-picker.js +18 -12
- package/dist/components/time-picker.js.map +1 -1
- package/dist/components/toast.js +1 -1
- package/dist/components/toast.js.map +1 -1
- package/dist/components/tree-item.js +3 -2
- package/dist/components/tree-item.js.map +1 -1
- package/dist/components/typography.js +28 -12
- package/dist/components/typography.js.map +1 -1
- package/dist/esm/base-button-87048318.js +47 -0
- package/dist/esm/base-button-87048318.js.map +1 -0
- package/dist/esm/base-icon-button-afac2d95.js +18 -0
- package/dist/esm/base-icon-button-afac2d95.js.map +1 -0
- package/dist/esm/breakpoints-b8d59fd9.js +25 -0
- package/dist/esm/breakpoints-b8d59fd9.js.map +1 -0
- package/dist/esm/context-6a3bc77f.js +101 -0
- package/dist/esm/context-6a3bc77f.js.map +1 -0
- package/dist/esm/{floating-ui.dom.esm-9b203a02.js → floating-ui.dom.esm-cbe44820.js} +654 -534
- package/dist/esm/floating-ui.dom.esm-cbe44820.js.map +1 -0
- package/dist/esm/{icon-4ac90a6d.js → icon-f54a8bc4.js} +2 -2
- package/dist/esm/{icon-4ac90a6d.js.map → icon-f54a8bc4.js.map} +1 -1
- package/dist/esm/index-7b24b7fa.js +6 -0
- package/dist/esm/index-7b24b7fa.js.map +1 -0
- package/dist/esm/{index-7334ee80.js → index-eb0be730.js} +46 -398
- package/dist/esm/index-eb0be730.js.map +1 -0
- package/dist/esm/index.js +3 -3
- package/dist/esm/ix-action-card.entry.js +3 -3
- package/dist/esm/ix-action-card.entry.js.map +1 -1
- package/dist/esm/ix-application-header.entry.js +10 -5
- package/dist/esm/ix-application-header.entry.js.map +1 -1
- package/dist/esm/ix-application-sidebar.entry.js +43 -0
- package/dist/esm/ix-application-sidebar.entry.js.map +1 -0
- package/dist/esm/ix-application.entry.js +105 -0
- package/dist/esm/ix-application.entry.js.map +1 -0
- package/dist/esm/ix-avatar.entry.js +1 -1
- package/dist/esm/ix-basic-navigation.entry.js +44 -10
- package/dist/esm/ix-basic-navigation.entry.js.map +1 -1
- package/dist/esm/ix-blind.entry.js +5 -4
- package/dist/esm/ix-blind.entry.js.map +1 -1
- package/dist/esm/ix-breadcrumb_2.entry.js +100 -92
- package/dist/esm/ix-breadcrumb_2.entry.js.map +1 -1
- package/dist/esm/ix-burger-menu.entry.js +3 -3
- package/dist/esm/ix-burger-menu.entry.js.map +1 -1
- package/dist/esm/ix-button.entry.js +22 -7
- package/dist/esm/ix-button.entry.js.map +1 -1
- package/dist/esm/ix-card-accordion_2.entry.js +2 -2
- package/dist/esm/ix-card-accordion_2.entry.js.map +1 -1
- package/dist/esm/ix-card-list.entry.js +2 -2
- package/dist/esm/ix-card-list.entry.js.map +1 -1
- package/dist/esm/ix-card_2.entry.js +3 -3
- package/dist/esm/ix-card_2.entry.js.map +1 -1
- package/dist/esm/ix-category-filter.entry.js +73 -40
- package/dist/esm/ix-category-filter.entry.js.map +1 -1
- package/dist/esm/ix-chip.entry.js +2 -2
- package/dist/esm/ix-chip.entry.js.map +1 -1
- package/dist/esm/ix-col.entry.js +73 -0
- package/dist/esm/ix-col.entry.js.map +1 -0
- package/dist/esm/ix-content-header.entry.js +1 -1
- package/dist/esm/ix-content.entry.js +28 -0
- package/dist/esm/ix-content.entry.js.map +1 -0
- package/dist/esm/ix-css-grid-item.entry.js +1 -1
- package/dist/esm/ix-css-grid-item.entry.js.map +1 -1
- package/dist/esm/ix-css-grid.entry.js +1 -1
- package/dist/esm/ix-css-grid.entry.js.map +1 -1
- package/dist/esm/ix-date-picker_2.entry.js +4 -4
- package/dist/esm/ix-date-picker_2.entry.js.map +1 -1
- package/dist/esm/ix-date-time-card.entry.js +2 -2
- package/dist/esm/ix-date-time-card.entry.js.map +1 -1
- package/dist/esm/ix-datetime-picker.entry.js +2 -2
- package/dist/esm/ix-datetime-picker.entry.js.map +1 -1
- package/dist/esm/ix-divider.entry.js +1 -1
- package/dist/esm/ix-drawer.entry.js +2 -2
- package/dist/esm/ix-drawer.entry.js.map +1 -1
- package/dist/esm/ix-dropdown-button.entry.js +4 -3
- package/dist/esm/ix-dropdown-button.entry.js.map +1 -1
- package/dist/esm/ix-dropdown-header.entry.js +2 -2
- package/dist/esm/ix-dropdown-header.entry.js.map +1 -1
- package/dist/esm/ix-dropdown-quick-actions.entry.js +1 -1
- package/dist/esm/ix-dropdown_2.entry.js +5 -7
- package/dist/esm/ix-dropdown_2.entry.js.map +1 -1
- package/dist/esm/ix-empty-state.entry.js +2 -2
- package/dist/esm/ix-empty-state.entry.js.map +1 -1
- package/dist/esm/ix-event-list_2.entry.js +3 -3
- package/dist/esm/ix-event-list_2.entry.js.map +1 -1
- package/dist/esm/ix-expanding-search.entry.js +2 -2
- package/dist/esm/ix-expanding-search.entry.js.map +1 -1
- package/dist/esm/ix-filter-chip.entry.js +4 -3
- package/dist/esm/ix-filter-chip.entry.js.map +1 -1
- package/dist/esm/ix-flip-tile_2.entry.js +28 -18
- package/dist/esm/ix-flip-tile_2.entry.js.map +1 -1
- package/dist/esm/ix-form-field.entry.js +23 -0
- package/dist/esm/ix-form-field.entry.js.map +1 -0
- package/dist/esm/ix-grid.entry.js +25 -0
- package/dist/esm/ix-grid.entry.js.map +1 -0
- package/dist/esm/ix-group-context-menu.entry.js +2 -2
- package/dist/esm/ix-group_2.entry.js +4 -4
- package/dist/esm/ix-group_2.entry.js.map +1 -1
- package/dist/esm/ix-icon-button.entry.js +21 -13
- package/dist/esm/ix-icon-button.entry.js.map +1 -1
- package/dist/esm/ix-icon-toggle-button.entry.js +84 -0
- package/dist/esm/ix-icon-toggle-button.entry.js.map +1 -0
- package/dist/esm/ix-icon.entry.js +2 -2
- package/dist/esm/ix-input-group.entry.js +85 -18
- package/dist/esm/ix-input-group.entry.js.map +1 -1
- package/dist/esm/ix-key-value-list.entry.js +1 -1
- package/dist/esm/ix-key-value.entry.js +1 -1
- package/dist/esm/ix-kpi.entry.js +2 -2
- package/dist/esm/ix-kpi.entry.js.map +1 -1
- package/dist/esm/ix-link-button.entry.js +2 -2
- package/dist/esm/ix-link-button.entry.js.map +1 -1
- package/dist/esm/ix-map-navigation_2.entry.js +11 -3
- package/dist/esm/ix-map-navigation_2.entry.js.map +1 -1
- package/dist/esm/ix-menu-category.entry.js +6 -5
- package/dist/esm/ix-menu-category.entry.js.map +1 -1
- package/dist/esm/ix-menu_9.entry.js +101 -75
- package/dist/esm/ix-menu_9.entry.js.map +1 -1
- package/dist/esm/ix-message-bar.entry.js +2 -2
- package/dist/esm/ix-message-bar.entry.js.map +1 -1
- package/dist/esm/ix-modal-content.entry.js +2 -2
- package/dist/esm/ix-modal-content.entry.js.map +1 -1
- package/dist/esm/ix-modal-example.entry.js +1 -1
- package/dist/esm/ix-modal-footer.entry.js +2 -2
- package/dist/esm/ix-modal-footer.entry.js.map +1 -1
- package/dist/esm/ix-modal-header.entry.js +2 -2
- package/dist/esm/ix-modal-header.entry.js.map +1 -1
- package/dist/esm/ix-modal-loading.entry.js +1 -1
- package/dist/esm/ix-modal.entry.js +2 -2
- package/dist/esm/ix-modal.entry.js.map +1 -1
- package/dist/esm/ix-pagination.entry.js +32 -15
- package/dist/esm/ix-pagination.entry.js.map +1 -1
- package/dist/esm/ix-pill.entry.js +2 -2
- package/dist/esm/ix-pill.entry.js.map +1 -1
- package/dist/esm/ix-push-card.entry.js +5 -2
- package/dist/esm/ix-push-card.entry.js.map +1 -1
- package/dist/esm/ix-row.entry.js +17 -0
- package/dist/esm/ix-row.entry.js.map +1 -0
- package/dist/esm/ix-select_2.entry.js +68 -49
- package/dist/esm/ix-select_2.entry.js.map +1 -1
- package/dist/esm/ix-spinner.entry.js +2 -2
- package/dist/esm/ix-spinner.entry.js.map +1 -1
- package/dist/esm/ix-split-button_2.entry.js +7 -5
- package/dist/esm/ix-split-button_2.entry.js.map +1 -1
- package/dist/esm/ix-tab-item.entry.js +11 -3
- package/dist/esm/ix-tab-item.entry.js.map +1 -1
- package/dist/esm/ix-tabs.entry.js +22 -7
- package/dist/esm/ix-tabs.entry.js.map +1 -1
- package/dist/esm/ix-tile.entry.js +2 -2
- package/dist/esm/ix-tile.entry.js.map +1 -1
- package/dist/esm/ix-toast_2.entry.js +2 -2
- package/dist/esm/ix-toast_2.entry.js.map +1 -1
- package/dist/esm/ix-toggle-button.entry.js +73 -0
- package/dist/esm/ix-toggle-button.entry.js.map +1 -0
- package/dist/esm/ix-toggle.entry.js +2 -2
- package/dist/esm/ix-toggle.entry.js.map +1 -1
- package/dist/esm/ix-tooltip.entry.js +2 -2
- package/dist/esm/ix-tree_2.entry.js +16 -9
- package/dist/esm/ix-tree_2.entry.js.map +1 -1
- package/dist/esm/ix-typography.entry.js +25 -12
- package/dist/esm/ix-typography.entry.js.map +1 -1
- package/dist/esm/ix-upload.entry.js +2 -2
- package/dist/esm/ix-upload.entry.js.map +1 -1
- package/dist/esm/ix-validation-tooltip.entry.js +8 -8
- package/dist/esm/ix-validation-tooltip.entry.js.map +1 -1
- package/dist/esm/ix-workflow-step_2.entry.js +14 -18
- package/dist/esm/ix-workflow-step_2.entry.js.map +1 -1
- package/dist/esm/loader.js +3 -3
- package/dist/esm/menu-service-12a09006.js +156 -0
- package/dist/esm/menu-service-12a09006.js.map +1 -0
- package/dist/esm/my-component.entry.js +1 -1
- package/dist/esm/my-component.entry.js.map +1 -1
- package/dist/esm/shadow-dom-b9df3d9b.js +21 -0
- package/dist/esm/shadow-dom-b9df3d9b.js.map +1 -0
- package/dist/esm/siemens-ix.js +3 -3
- package/dist/esm/{theme-switcher-7498e4f2.js → theme-switcher-9ede3823.js} +36 -4
- package/dist/esm/theme-switcher-9ede3823.js.map +1 -0
- package/dist/siemens-ix/index.esm.js +1 -1
- package/dist/siemens-ix/index.esm.js.map +1 -1
- package/dist/siemens-ix/p-00616f87.entry.js +2 -0
- package/dist/siemens-ix/{p-8c14a4a3.entry.js.map → p-00616f87.entry.js.map} +1 -1
- package/dist/siemens-ix/p-00df4a8c.js +2 -0
- package/dist/siemens-ix/p-00df4a8c.js.map +1 -0
- package/dist/siemens-ix/p-04eeba9e.js +2 -0
- package/dist/siemens-ix/p-04eeba9e.js.map +1 -0
- package/dist/siemens-ix/{p-b89172b4.entry.js → p-0e2045b9.entry.js} +2 -2
- package/dist/siemens-ix/p-0e2045b9.entry.js.map +1 -0
- package/dist/siemens-ix/p-134b6bd5.js +2 -0
- package/dist/siemens-ix/p-134b6bd5.js.map +1 -0
- package/dist/siemens-ix/p-14621fbd.entry.js +2 -0
- package/dist/siemens-ix/p-14621fbd.entry.js.map +1 -0
- package/dist/siemens-ix/p-1b705d7b.js +2 -0
- package/dist/siemens-ix/p-1b705d7b.js.map +1 -0
- package/dist/siemens-ix/p-1b9b19e6.js +2 -0
- package/dist/siemens-ix/p-1b9b19e6.js.map +1 -0
- package/dist/siemens-ix/p-1fc8e513.entry.js +2 -0
- package/dist/siemens-ix/p-1fc8e513.entry.js.map +1 -0
- package/dist/siemens-ix/{p-157f7ec0.entry.js → p-26855b3f.entry.js} +2 -2
- package/dist/siemens-ix/p-281fa225.entry.js +2 -0
- package/dist/siemens-ix/{p-33670e98.entry.js.map → p-281fa225.entry.js.map} +1 -1
- package/dist/siemens-ix/p-2a29e187.entry.js +2 -0
- package/dist/siemens-ix/{p-5fedb19b.entry.js.map → p-2a29e187.entry.js.map} +1 -1
- package/dist/siemens-ix/p-36c48f12.entry.js +2 -0
- package/dist/siemens-ix/p-36c48f12.entry.js.map +1 -0
- package/dist/siemens-ix/p-36f0b470.entry.js +2 -0
- package/dist/siemens-ix/p-36f0b470.entry.js.map +1 -0
- package/dist/siemens-ix/p-37dd62fc.entry.js +2 -0
- package/dist/siemens-ix/p-37dd62fc.entry.js.map +1 -0
- package/dist/siemens-ix/{p-0e86b47b.entry.js → p-3983ee89.entry.js} +2 -2
- package/dist/siemens-ix/p-3dbeeecf.entry.js +2 -0
- package/dist/siemens-ix/p-3dbeeecf.entry.js.map +1 -0
- package/dist/siemens-ix/p-3eabf464.entry.js +2 -0
- package/dist/siemens-ix/p-3eabf464.entry.js.map +1 -0
- package/dist/siemens-ix/p-40ecc8be.entry.js +2 -0
- package/dist/siemens-ix/p-40ecc8be.entry.js.map +1 -0
- package/dist/siemens-ix/{p-918450cd.entry.js → p-43497703.entry.js} +2 -2
- package/dist/siemens-ix/p-43497703.entry.js.map +1 -0
- package/dist/siemens-ix/{p-0fab8cae.entry.js → p-4659c550.entry.js} +2 -2
- package/dist/siemens-ix/p-475d8732.entry.js +2 -0
- package/dist/siemens-ix/p-475d8732.entry.js.map +1 -0
- package/dist/siemens-ix/p-49b9f9f5.entry.js +2 -0
- package/dist/siemens-ix/{p-c0345859.entry.js.map → p-49b9f9f5.entry.js.map} +1 -1
- package/dist/siemens-ix/{p-02f01e39.entry.js → p-4dbae019.entry.js} +2 -2
- package/dist/siemens-ix/p-4f8954a7.entry.js +2 -0
- package/dist/siemens-ix/p-4f8954a7.entry.js.map +1 -0
- package/dist/siemens-ix/p-5017cf39.entry.js +2 -0
- package/dist/siemens-ix/p-5017cf39.entry.js.map +1 -0
- package/dist/siemens-ix/p-5029fd0f.entry.js +2 -0
- package/dist/siemens-ix/p-5029fd0f.entry.js.map +1 -0
- package/dist/siemens-ix/p-553ebcb1.entry.js +2 -0
- package/dist/siemens-ix/{p-b6d52b6f.entry.js.map → p-553ebcb1.entry.js.map} +1 -1
- package/dist/siemens-ix/p-5650383d.entry.js +2 -0
- package/dist/siemens-ix/p-5650383d.entry.js.map +1 -0
- package/dist/siemens-ix/p-567f71a2.entry.js +2 -0
- package/dist/siemens-ix/p-567f71a2.entry.js.map +1 -0
- package/dist/siemens-ix/p-5d132cc5.entry.js +2 -0
- package/dist/siemens-ix/p-5d132cc5.entry.js.map +1 -0
- package/dist/siemens-ix/p-5e3f8c0b.entry.js +2 -0
- package/dist/siemens-ix/p-5e3f8c0b.entry.js.map +1 -0
- package/dist/siemens-ix/p-61ffc6e1.entry.js +2 -0
- package/dist/siemens-ix/p-61ffc6e1.entry.js.map +1 -0
- package/dist/siemens-ix/p-655d177c.entry.js +2 -0
- package/dist/siemens-ix/p-655d177c.entry.js.map +1 -0
- package/dist/siemens-ix/p-737fca1b.entry.js +2 -0
- package/dist/siemens-ix/{p-1b1bc523.entry.js.map → p-737fca1b.entry.js.map} +1 -1
- package/dist/siemens-ix/p-76a509c7.js +3 -0
- package/dist/siemens-ix/p-76a509c7.js.map +1 -0
- package/dist/siemens-ix/{p-4d194d55.entry.js → p-7918fd50.entry.js} +2 -2
- package/dist/siemens-ix/p-7918fd50.entry.js.map +1 -0
- package/dist/siemens-ix/p-7a884056.entry.js +2 -0
- package/dist/siemens-ix/{p-c4ea8815.entry.js.map → p-7a884056.entry.js.map} +1 -1
- package/dist/siemens-ix/p-7b536489.entry.js +2 -0
- package/dist/siemens-ix/p-7b536489.entry.js.map +1 -0
- package/dist/siemens-ix/p-85f39bd4.js +2 -0
- package/dist/siemens-ix/p-85f39bd4.js.map +1 -0
- package/dist/siemens-ix/{p-db74796e.js → p-8c7d1e06.js} +2 -2
- package/dist/siemens-ix/p-8e39298f.js +2 -0
- package/dist/siemens-ix/p-8e39298f.js.map +1 -0
- package/dist/siemens-ix/p-94ecb1af.entry.js +2 -0
- package/dist/siemens-ix/p-94ecb1af.entry.js.map +1 -0
- package/dist/siemens-ix/p-9848e4de.entry.js +2 -0
- package/dist/siemens-ix/p-9848e4de.entry.js.map +1 -0
- package/dist/siemens-ix/p-98b03a9b.entry.js +2 -0
- package/dist/siemens-ix/p-98b03a9b.entry.js.map +1 -0
- package/dist/siemens-ix/p-9a05ac00.js +2 -0
- package/dist/siemens-ix/p-9a05ac00.js.map +1 -0
- package/dist/siemens-ix/p-9b6075de.entry.js +2 -0
- package/dist/siemens-ix/p-9b6075de.entry.js.map +1 -0
- package/dist/siemens-ix/p-a0fdaa04.entry.js +2 -0
- package/dist/siemens-ix/p-a18f1744.entry.js +2 -0
- package/dist/siemens-ix/p-a18f1744.entry.js.map +1 -0
- package/dist/siemens-ix/p-a3d6abfb.entry.js +2 -0
- package/dist/siemens-ix/p-a3d6abfb.entry.js.map +1 -0
- package/dist/siemens-ix/p-a5ae7bfa.entry.js +2 -0
- package/dist/siemens-ix/p-a5ae7bfa.entry.js.map +1 -0
- package/dist/siemens-ix/p-a6345f97.entry.js +2 -0
- package/dist/siemens-ix/p-a6345f97.entry.js.map +1 -0
- package/dist/siemens-ix/p-a8424ce3.entry.js +2 -0
- package/dist/siemens-ix/p-a8424ce3.entry.js.map +1 -0
- package/dist/siemens-ix/p-a85299c6.entry.js +2 -0
- package/dist/siemens-ix/p-a85299c6.entry.js.map +1 -0
- package/dist/siemens-ix/p-ab452b82.js +2 -0
- package/dist/siemens-ix/p-ab452b82.js.map +1 -0
- package/dist/siemens-ix/p-ab4bdb4e.entry.js +2 -0
- package/dist/siemens-ix/p-ab4bdb4e.entry.js.map +1 -0
- package/dist/siemens-ix/p-ac00ae47.entry.js +2 -0
- package/dist/siemens-ix/p-ac00ae47.entry.js.map +1 -0
- package/dist/siemens-ix/p-b007e4b4.entry.js +2 -0
- package/dist/siemens-ix/{p-b21bc31c.entry.js.map → p-b007e4b4.entry.js.map} +1 -1
- package/dist/siemens-ix/p-b0a1930d.entry.js +2 -0
- package/dist/siemens-ix/p-b0a1930d.entry.js.map +1 -0
- package/dist/siemens-ix/{p-34807901.entry.js → p-b25c770f.entry.js} +2 -2
- package/dist/siemens-ix/{p-34807901.entry.js.map → p-b25c770f.entry.js.map} +1 -1
- package/dist/siemens-ix/{p-f38e7420.entry.js → p-b38eff08.entry.js} +2 -2
- package/dist/siemens-ix/p-b45ca515.entry.js +2 -0
- package/dist/siemens-ix/p-b45ca515.entry.js.map +1 -0
- package/dist/siemens-ix/{p-f0219d7a.entry.js → p-b735ee5e.entry.js} +2 -2
- package/dist/siemens-ix/p-c1ac2d01.entry.js +2 -0
- package/dist/siemens-ix/{p-06603826.entry.js.map → p-c1ac2d01.entry.js.map} +1 -1
- package/dist/siemens-ix/p-c1f5a59a.entry.js +2 -0
- package/dist/siemens-ix/p-c1f5a59a.entry.js.map +1 -0
- package/dist/siemens-ix/p-c75264af.entry.js +2 -0
- package/dist/siemens-ix/p-c75264af.entry.js.map +1 -0
- package/dist/siemens-ix/p-cd0e77f1.entry.js +2 -0
- package/dist/siemens-ix/{p-9547706d.entry.js.map → p-cd0e77f1.entry.js.map} +1 -1
- package/dist/siemens-ix/{p-d48d74af.entry.js → p-cd1e0061.entry.js} +2 -2
- package/dist/siemens-ix/p-ce0a7c1a.entry.js +2 -0
- package/dist/siemens-ix/{p-07a0b330.entry.js.map → p-ce0a7c1a.entry.js.map} +1 -1
- package/dist/siemens-ix/p-d214f57a.entry.js +2 -0
- package/dist/siemens-ix/{p-a9619a92.entry.js.map → p-d214f57a.entry.js.map} +1 -1
- package/dist/siemens-ix/p-d29bcf75.entry.js +2 -0
- package/dist/siemens-ix/p-d29bcf75.entry.js.map +1 -0
- package/dist/siemens-ix/{p-0dea55bf.entry.js → p-d87de06f.entry.js} +2 -2
- package/dist/siemens-ix/{p-d7e8417d.entry.js → p-da133606.entry.js} +2 -2
- package/dist/siemens-ix/p-da133606.entry.js.map +1 -0
- package/dist/siemens-ix/p-db174600.entry.js +2 -0
- package/dist/siemens-ix/p-db2f237f.entry.js +2 -0
- package/dist/siemens-ix/p-db2f237f.entry.js.map +1 -0
- package/dist/siemens-ix/p-dc77f962.entry.js +2 -0
- package/dist/siemens-ix/{p-d81d0f62.entry.js.map → p-dc77f962.entry.js.map} +1 -1
- package/dist/siemens-ix/{p-81333042.entry.js → p-de013166.entry.js} +2 -2
- package/dist/siemens-ix/p-de013166.entry.js.map +1 -0
- package/dist/siemens-ix/p-e2c200f3.entry.js +2 -0
- package/dist/siemens-ix/{p-2ea3d53a.entry.js.map → p-e2c200f3.entry.js.map} +1 -1
- package/dist/siemens-ix/p-e610b2b8.entry.js +2 -0
- package/dist/siemens-ix/{p-e8f2e141.entry.js.map → p-e610b2b8.entry.js.map} +1 -1
- package/dist/siemens-ix/p-eb29049a.entry.js +2 -0
- package/dist/siemens-ix/p-eb29049a.entry.js.map +1 -0
- package/dist/siemens-ix/p-eb3f1ef6.entry.js +2 -0
- package/dist/siemens-ix/p-eb3f1ef6.entry.js.map +1 -0
- package/dist/siemens-ix/p-ebeef6fd.entry.js +2 -0
- package/dist/siemens-ix/p-ebeef6fd.entry.js.map +1 -0
- package/dist/siemens-ix/p-f71da594.entry.js +2 -0
- package/dist/siemens-ix/{p-7d2aec76.entry.js.map → p-f71da594.entry.js.map} +1 -1
- package/dist/siemens-ix/{p-20aa7350.entry.js → p-f88b25d7.entry.js} +2 -2
- package/dist/siemens-ix/p-f9b004ba.entry.js +2 -0
- package/dist/siemens-ix/{p-bf019e35.entry.js.map → p-f9b004ba.entry.js.map} +1 -1
- package/dist/siemens-ix/p-f9d4ca13.entry.js +2 -0
- package/dist/siemens-ix/p-f9d4ca13.entry.js.map +1 -0
- package/dist/siemens-ix/p-feb80449.entry.js +2 -0
- package/dist/siemens-ix/{p-a64d88de.entry.js.map → p-feb80449.entry.js.map} +1 -1
- package/dist/siemens-ix/siemens-ix-core.css +1 -12289
- package/dist/siemens-ix/siemens-ix.css +8249 -11730
- package/dist/siemens-ix/siemens-ix.esm.js +1 -1
- package/dist/siemens-ix/siemens-ix.esm.js.map +1 -1
- package/dist/siemens-ix/theme/classic-dark.css +1 -1062
- package/dist/siemens-ix/theme/classic-light.css +1 -1062
- package/dist/siemens-ix/theme/legacy-classic-dark.css +1 -1061
- package/dist/siemens-ix/theme/legacy-classic-light.css +1 -1061
- package/dist/types/components/application/application.d.ts +36 -0
- package/dist/types/components/application-header/application-header.d.ts +2 -5
- package/dist/types/components/application-header/test/application-headet.ct.d.ts +1 -0
- package/dist/types/components/application-sidebar/application-sidebar.d.ts +7 -0
- package/dist/types/components/application-sidebar/events.d.ts +4 -0
- package/dist/types/components/basic-navigation/basic-navigation.d.ts +14 -2
- package/dist/types/components/blind/blind.d.ts +5 -0
- package/dist/types/components/breadcrumb/breadcrumb.d.ts +15 -14
- package/dist/types/components/breadcrumb/test/breadcrumb.ct.d.ts +1 -0
- package/dist/types/components/breadcrumb-item/breadcrumb-item.d.ts +15 -0
- package/dist/types/components/button/base-button.d.ts +25 -0
- package/dist/types/components/button/button.d.ts +4 -10
- package/dist/types/components/category-filter/category-filter.d.ts +12 -5
- package/dist/types/components/col/col.d.ts +31 -0
- package/dist/types/components/content/content.d.ts +7 -0
- package/dist/types/components/dropdown-button/dropdown-button.d.ts +7 -0
- package/dist/types/components/filter-chip/filter-chip.d.ts +5 -0
- package/dist/types/components/flip-tile/flip-tile.d.ts +9 -11
- package/dist/types/components/flip-tile/test/flip-tile.ct.d.ts +1 -0
- package/dist/types/components/flip-tile-content/flip-tile-content.d.ts +6 -0
- package/dist/types/components/form-field/form-field.d.ts +10 -0
- package/dist/types/components/grid/grid.d.ts +18 -0
- package/dist/types/components/icon-button/base-icon-button.d.ts +2 -0
- package/dist/types/components/icon-button/icon-button.d.ts +2 -13
- package/dist/types/components/icon-toggle-button/icon-toggle-button.d.ts +54 -0
- package/dist/types/components/input-group/input-group.d.ts +11 -1
- package/dist/types/components/map-navigation/map-navigation.d.ts +1 -0
- package/dist/types/components/menu/menu.d.ts +9 -14
- package/dist/types/components/menu-item/menu-item.d.ts +2 -0
- package/dist/types/components/pagination/pagination.d.ts +1 -1
- package/dist/types/components/row/row.d.ts +6 -0
- package/dist/types/components/select/select.d.ts +23 -7
- package/dist/types/components/tab-item/tab-item.d.ts +10 -0
- package/dist/types/components/tabs/tabs.d.ts +8 -0
- package/dist/types/components/tabs/test/tabs.ct.d.ts +1 -0
- package/dist/types/components/toggle-button/toggle-button.d.ts +48 -0
- package/dist/types/components/tree/test/tree.ct.d.ts +1 -0
- package/dist/types/components/tree/tree.d.ts +2 -1
- package/dist/types/components/typography/typography.d.ts +24 -1
- package/dist/types/components/utils/application-layout/context.d.ts +6 -0
- package/dist/types/components/utils/application-layout/index.d.ts +1 -0
- package/dist/types/components/utils/application-layout/service.d.ts +16 -0
- package/dist/types/components/utils/breakpoints.d.ts +8 -0
- package/dist/types/components/utils/context.d.ts +57 -0
- package/dist/types/components/utils/shadow-dom.d.ts +1 -1
- package/dist/types/components/utils/theme-switcher.d.ts +10 -3
- package/dist/types/components/validation-tooltip/validation-tooltip.d.ts +1 -1
- package/dist/types/components/workflow-step/workflow-step.d.ts +1 -2
- package/dist/types/components/workflow-steps/test/workflow-steps.ct.d.ts +1 -0
- package/dist/types/components/workflow-steps/workflow-steps.d.ts +0 -5
- package/dist/types/components.d.ts +556 -167
- package/package.json +7 -5
- package/scss/_core.scss +66 -0
- package/scss/components/_checkboxes.scss +9 -3
- package/scss/components/_fonts.scss +131 -0
- package/scss/components/_table.scss +1 -1
- package/scss/components/form/_input.scss +155 -0
- package/scss/ix-core.scss +2 -75
- package/scss/ix.scss +3 -74
- package/scss/{_fonts.scss → legacy/_fonts.scss} +1 -1
- package/scss/{components → legacy/components}/_buttons.scss +14 -12
- package/scss/{components → legacy/components}/_dropdown.scss +1 -1
- package/scss/{components → legacy/components}/_forms.scss +6 -1
- package/scss/{components → legacy/components}/_modal.scss +1 -1
- package/scss/legacy/mixins/_fonts.scss +166 -0
- package/scss/mixins/_break-points.scss +25 -0
- package/scss/mixins/_fonts.scss +149 -105
- package/scss/mixins/_hover.scss +3 -1
- package/scss/mixins/_scrollbar.scss +44 -0
- package/scss/mixins/shadow-dom/_component.scss +4 -0
- package/scss/theme/classic-dark/_boxShadow.scss +5 -5
- package/scss/theme/classic-dark/_fontFamilies.scss +2 -1
- package/scss/theme/classic-dark/_fontSizes.scss +11 -0
- package/scss/theme/classic-dark/_fontWeights.scss +2 -1
- package/scss/theme/classic-dark/_index.scss +7 -0
- package/scss/theme/classic-dark/_letterSpacing.scss +13 -0
- package/scss/theme/classic-dark/_lineHeights.scss +4 -1
- package/scss/theme/classic-dark/_sizing.scss +12 -0
- package/scss/theme/classic-dark/_spacing.scss +12 -0
- package/scss/theme/classic-dark/_typography.scss +39 -16
- package/scss/theme/classic-light/_boxShadow.scss +5 -5
- package/scss/theme/classic-light/_fontFamilies.scss +2 -1
- package/scss/theme/classic-light/_fontSizes.scss +11 -0
- package/scss/theme/classic-light/_fontWeights.scss +2 -1
- package/scss/theme/classic-light/_index.scss +7 -0
- package/scss/theme/classic-light/_letterSpacing.scss +13 -0
- package/scss/theme/classic-light/_lineHeights.scss +4 -1
- package/scss/theme/classic-light/_sizing.scss +12 -0
- package/scss/theme/classic-light/_spacing.scss +12 -0
- package/scss/theme/classic-light/_typography.scss +39 -16
- package/scss/theme/legacy-classic-dark/_fontFamilies.scss +2 -1
- package/scss/theme/legacy-classic-dark/_fontSizes.scss +11 -0
- package/scss/theme/legacy-classic-dark/_fontWeights.scss +2 -1
- package/scss/theme/legacy-classic-dark/_index.scss +7 -0
- package/scss/theme/legacy-classic-dark/_letterSpacing.scss +13 -0
- package/scss/theme/legacy-classic-dark/_lineHeights.scss +4 -1
- package/scss/theme/legacy-classic-dark/_sizing.scss +12 -0
- package/scss/theme/legacy-classic-dark/_spacing.scss +12 -0
- package/scss/theme/legacy-classic-dark/_typography.scss +39 -16
- package/scss/theme/legacy-classic-light/_fontFamilies.scss +2 -1
- package/scss/theme/legacy-classic-light/_fontSizes.scss +11 -0
- package/scss/theme/legacy-classic-light/_fontWeights.scss +2 -1
- package/scss/theme/legacy-classic-light/_index.scss +7 -0
- package/scss/theme/legacy-classic-light/_letterSpacing.scss +13 -0
- package/scss/theme/legacy-classic-light/_lineHeights.scss +4 -1
- package/scss/theme/legacy-classic-light/_sizing.scss +12 -0
- package/scss/theme/legacy-classic-light/_spacing.scss +12 -0
- package/scss/theme/legacy-classic-light/_typography.scss +39 -16
- package/dist/cjs/base-button-497db257.js +0 -35
- package/dist/cjs/base-button-497db257.js.map +0 -1
- package/dist/cjs/context-2ce9a350.js +0 -26
- package/dist/cjs/context-2ce9a350.js.map +0 -1
- package/dist/cjs/floating-ui.dom.esm-b79b633f.js.map +0 -1
- package/dist/cjs/index-e56a1d39.js.map +0 -1
- package/dist/cjs/ix-animated-tab_2.cjs.entry.js +0 -214
- package/dist/cjs/ix-animated-tab_2.cjs.entry.js.map +0 -1
- package/dist/cjs/ix-index-button.cjs.entry.js +0 -28
- package/dist/cjs/ix-index-button.cjs.entry.js.map +0 -1
- package/dist/cjs/menu-service-d1b87142.js +0 -80
- package/dist/cjs/menu-service-d1b87142.js.map +0 -1
- package/dist/cjs/service-0e27b06b.js +0 -145
- package/dist/cjs/service-0e27b06b.js.map +0 -1
- package/dist/cjs/shadow-dom-f9b90696.js.map +0 -1
- package/dist/cjs/theme-switcher-bdbd0d30.js.map +0 -1
- package/dist/collection/components/animated-tab/animated-tab.js +0 -69
- package/dist/collection/components/animated-tab/animated-tab.js.map +0 -1
- package/dist/collection/components/animated-tabs/animated-tabs.css +0 -158
- package/dist/collection/components/animated-tabs/animated-tabs.js +0 -303
- package/dist/collection/components/animated-tabs/animated-tabs.js.map +0 -1
- package/dist/collection/components/index-button/index-button.css +0 -31
- package/dist/collection/components/index-button/index-button.js +0 -83
- package/dist/collection/components/index-button/index-button.js.map +0 -1
- package/dist/collection/components/layout/css-grid/builder.js.map +0 -1
- package/dist/collection/components/layout/css-grid/css-grid-item.js.map +0 -1
- package/dist/collection/components/layout/css-grid/css-grid.js.map +0 -1
- package/dist/collection/components/utils/screen/context.js +0 -34
- package/dist/collection/components/utils/screen/context.js.map +0 -1
- package/dist/collection/components/utils/screen/index.js.map +0 -1
- package/dist/collection/components/utils/screen/mode.js +0 -85
- package/dist/collection/components/utils/screen/mode.js.map +0 -1
- package/dist/collection/components/utils/screen/service.js +0 -68
- package/dist/collection/components/utils/screen/service.js.map +0 -1
- package/dist/components/index-button.js +0 -41
- package/dist/components/index-button.js.map +0 -1
- package/dist/components/ix-animated-tab.js +0 -39
- package/dist/components/ix-animated-tab.js.map +0 -1
- package/dist/components/ix-animated-tabs.js +0 -224
- package/dist/components/ix-animated-tabs.js.map +0 -1
- package/dist/components/ix-index-button.js +0 -8
- package/dist/components/ix-index-button.js.map +0 -1
- package/dist/components/service.js +0 -143
- package/dist/components/service.js.map +0 -1
- package/dist/esm/base-button-5bfeb71c.js +0 -33
- package/dist/esm/base-button-5bfeb71c.js.map +0 -1
- package/dist/esm/context-381170ae.js +0 -22
- package/dist/esm/context-381170ae.js.map +0 -1
- package/dist/esm/floating-ui.dom.esm-9b203a02.js.map +0 -1
- package/dist/esm/index-7334ee80.js.map +0 -1
- package/dist/esm/ix-animated-tab_2.entry.js +0 -209
- package/dist/esm/ix-animated-tab_2.entry.js.map +0 -1
- package/dist/esm/ix-index-button.entry.js +0 -24
- package/dist/esm/ix-index-button.entry.js.map +0 -1
- package/dist/esm/menu-service-b3076949.js +0 -78
- package/dist/esm/menu-service-b3076949.js.map +0 -1
- package/dist/esm/service-586129b5.js +0 -143
- package/dist/esm/service-586129b5.js.map +0 -1
- package/dist/esm/shadow-dom-6860b1c4.js.map +0 -1
- package/dist/esm/theme-switcher-7498e4f2.js.map +0 -1
- package/dist/siemens-ix/p-00f74fc9.entry.js +0 -2
- package/dist/siemens-ix/p-00f74fc9.entry.js.map +0 -1
- package/dist/siemens-ix/p-01c37ebe.entry.js +0 -2
- package/dist/siemens-ix/p-01c37ebe.entry.js.map +0 -1
- package/dist/siemens-ix/p-0574cf88.entry.js +0 -2
- package/dist/siemens-ix/p-0574cf88.entry.js.map +0 -1
- package/dist/siemens-ix/p-06603826.entry.js +0 -2
- package/dist/siemens-ix/p-06fcaee3.entry.js +0 -2
- package/dist/siemens-ix/p-06fcaee3.entry.js.map +0 -1
- package/dist/siemens-ix/p-07a0b330.entry.js +0 -2
- package/dist/siemens-ix/p-09ce5f12.entry.js +0 -2
- package/dist/siemens-ix/p-09ce5f12.entry.js.map +0 -1
- package/dist/siemens-ix/p-0c9ead45.entry.js +0 -2
- package/dist/siemens-ix/p-0c9ead45.entry.js.map +0 -1
- package/dist/siemens-ix/p-15996fa7.entry.js +0 -2
- package/dist/siemens-ix/p-15996fa7.entry.js.map +0 -1
- package/dist/siemens-ix/p-1b1bc523.entry.js +0 -2
- package/dist/siemens-ix/p-2ea3d53a.entry.js +0 -2
- package/dist/siemens-ix/p-303b8c2f.entry.js +0 -2
- package/dist/siemens-ix/p-303b8c2f.entry.js.map +0 -1
- package/dist/siemens-ix/p-323d5529.js +0 -2
- package/dist/siemens-ix/p-323d5529.js.map +0 -1
- package/dist/siemens-ix/p-33670e98.entry.js +0 -2
- package/dist/siemens-ix/p-34633470.entry.js +0 -2
- package/dist/siemens-ix/p-34633470.entry.js.map +0 -1
- package/dist/siemens-ix/p-38e69215.entry.js +0 -2
- package/dist/siemens-ix/p-38e69215.entry.js.map +0 -1
- package/dist/siemens-ix/p-3a99b0c8.entry.js +0 -2
- package/dist/siemens-ix/p-3a99b0c8.entry.js.map +0 -1
- package/dist/siemens-ix/p-45738e84.js +0 -2
- package/dist/siemens-ix/p-45738e84.js.map +0 -1
- package/dist/siemens-ix/p-4d194d55.entry.js.map +0 -1
- package/dist/siemens-ix/p-56a27b34.entry.js +0 -2
- package/dist/siemens-ix/p-56a27b34.entry.js.map +0 -1
- package/dist/siemens-ix/p-5b39e04e.js +0 -2
- package/dist/siemens-ix/p-5b39e04e.js.map +0 -1
- package/dist/siemens-ix/p-5fedb19b.entry.js +0 -2
- package/dist/siemens-ix/p-627148db.entry.js +0 -2
- package/dist/siemens-ix/p-627148db.entry.js.map +0 -1
- package/dist/siemens-ix/p-62f4db99.entry.js +0 -2
- package/dist/siemens-ix/p-62f4db99.entry.js.map +0 -1
- package/dist/siemens-ix/p-63b82e40.entry.js +0 -2
- package/dist/siemens-ix/p-63b82e40.entry.js.map +0 -1
- package/dist/siemens-ix/p-68c44614.entry.js +0 -2
- package/dist/siemens-ix/p-68c44614.entry.js.map +0 -1
- package/dist/siemens-ix/p-7021c2d1.entry.js +0 -2
- package/dist/siemens-ix/p-7021c2d1.entry.js.map +0 -1
- package/dist/siemens-ix/p-709d38fe.entry.js +0 -2
- package/dist/siemens-ix/p-709d38fe.entry.js.map +0 -1
- package/dist/siemens-ix/p-785726e8.entry.js +0 -2
- package/dist/siemens-ix/p-785726e8.entry.js.map +0 -1
- package/dist/siemens-ix/p-7d2aec76.entry.js +0 -2
- package/dist/siemens-ix/p-81333042.entry.js.map +0 -1
- package/dist/siemens-ix/p-8c14a4a3.entry.js +0 -2
- package/dist/siemens-ix/p-8ce73af1.entry.js +0 -2
- package/dist/siemens-ix/p-8ce73af1.entry.js.map +0 -1
- package/dist/siemens-ix/p-904aa275.entry.js +0 -2
- package/dist/siemens-ix/p-904aa275.entry.js.map +0 -1
- package/dist/siemens-ix/p-918450cd.entry.js.map +0 -1
- package/dist/siemens-ix/p-9547706d.entry.js +0 -2
- package/dist/siemens-ix/p-9903e755.entry.js +0 -2
- package/dist/siemens-ix/p-9903e755.entry.js.map +0 -1
- package/dist/siemens-ix/p-9d264ca8.entry.js +0 -2
- package/dist/siemens-ix/p-9d264ca8.entry.js.map +0 -1
- package/dist/siemens-ix/p-a64d88de.entry.js +0 -2
- package/dist/siemens-ix/p-a8e8a942.entry.js +0 -2
- package/dist/siemens-ix/p-a9619a92.entry.js +0 -2
- package/dist/siemens-ix/p-b21bc31c.entry.js +0 -2
- package/dist/siemens-ix/p-b6d52b6f.entry.js +0 -2
- package/dist/siemens-ix/p-b89172b4.entry.js.map +0 -1
- package/dist/siemens-ix/p-b899b25b.js +0 -3
- package/dist/siemens-ix/p-b899b25b.js.map +0 -1
- package/dist/siemens-ix/p-bf019e35.entry.js +0 -2
- package/dist/siemens-ix/p-c0345859.entry.js +0 -2
- package/dist/siemens-ix/p-c4ea8815.entry.js +0 -2
- package/dist/siemens-ix/p-c84a43ef.entry.js +0 -2
- package/dist/siemens-ix/p-c84a43ef.entry.js.map +0 -1
- package/dist/siemens-ix/p-d0a8aa6f.entry.js +0 -2
- package/dist/siemens-ix/p-d43bf856.js +0 -2
- package/dist/siemens-ix/p-d43bf856.js.map +0 -1
- package/dist/siemens-ix/p-d737ad96.js +0 -2
- package/dist/siemens-ix/p-d737ad96.js.map +0 -1
- package/dist/siemens-ix/p-d7e8417d.entry.js.map +0 -1
- package/dist/siemens-ix/p-d81d0f62.entry.js +0 -2
- package/dist/siemens-ix/p-d991a3d6.entry.js +0 -2
- package/dist/siemens-ix/p-d991a3d6.entry.js.map +0 -1
- package/dist/siemens-ix/p-dbca4dd5.entry.js +0 -2
- package/dist/siemens-ix/p-dbca4dd5.entry.js.map +0 -1
- package/dist/siemens-ix/p-e1c92dcb.entry.js +0 -2
- package/dist/siemens-ix/p-e1c92dcb.entry.js.map +0 -1
- package/dist/siemens-ix/p-e275814e.js +0 -2
- package/dist/siemens-ix/p-e275814e.js.map +0 -1
- package/dist/siemens-ix/p-e3db25ef.entry.js +0 -2
- package/dist/siemens-ix/p-e3db25ef.entry.js.map +0 -1
- package/dist/siemens-ix/p-e8f2e141.entry.js +0 -2
- package/dist/siemens-ix/p-eca0b89c.entry.js +0 -2
- package/dist/siemens-ix/p-eca0b89c.entry.js.map +0 -1
- package/dist/siemens-ix/p-ef73f7e3.entry.js +0 -2
- package/dist/siemens-ix/p-ef73f7e3.entry.js.map +0 -1
- package/dist/siemens-ix/p-f22423c2.js +0 -2
- package/dist/siemens-ix/p-f22423c2.js.map +0 -1
- package/dist/siemens-ix/p-f4d634f5.entry.js +0 -2
- package/dist/siemens-ix/p-f4d634f5.entry.js.map +0 -1
- package/dist/siemens-ix/p-fafe1aeb.entry.js +0 -2
- package/dist/siemens-ix/p-fafe1aeb.entry.js.map +0 -1
- package/dist/siemens-ix/p-fe073f2a.entry.js +0 -2
- package/dist/siemens-ix/p-fe073f2a.entry.js.map +0 -1
- package/dist/siemens-ix/p-ff17104c.entry.js +0 -2
- package/dist/siemens-ix/p-ff17104c.entry.js.map +0 -1
- package/dist/types/components/animated-tab/animated-tab.d.ts +0 -11
- package/dist/types/components/animated-tabs/animated-tabs.d.ts +0 -44
- package/dist/types/components/index-button/index-button.d.ts +0 -16
- package/dist/types/components/utils/screen/context.d.ts +0 -5
- package/dist/types/components/utils/screen/index.d.ts +0 -1
- package/dist/types/components/utils/screen/mode.d.ts +0 -13
- package/dist/types/components/utils/screen/service.d.ts +0 -15
- /package/dist/collection/components/{layout/css-grid → css-grid}/builder.js +0 -0
- /package/dist/collection/components/{layout/css-grid → css-grid}/css-grid-item.css +0 -0
- /package/dist/collection/components/{layout/css-grid → css-grid}/css-grid-item.js +0 -0
- /package/dist/collection/components/{layout/css-grid → css-grid}/css-grid.css +0 -0
- /package/dist/siemens-ix/{p-157f7ec0.entry.js.map → p-26855b3f.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-0e86b47b.entry.js.map → p-3983ee89.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-0fab8cae.entry.js.map → p-4659c550.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-02f01e39.entry.js.map → p-4dbae019.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-db74796e.js.map → p-8c7d1e06.js.map} +0 -0
- /package/dist/siemens-ix/{p-a8e8a942.entry.js.map → p-a0fdaa04.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-f38e7420.entry.js.map → p-b38eff08.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-f0219d7a.entry.js.map → p-b735ee5e.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-d48d74af.entry.js.map → p-cd1e0061.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-0dea55bf.entry.js.map → p-d87de06f.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-d0a8aa6f.entry.js.map → p-db174600.entry.js.map} +0 -0
- /package/dist/siemens-ix/{p-20aa7350.entry.js.map → p-f88b25d7.entry.js.map} +0 -0
- /package/dist/types/components/{layout/css-grid → css-grid}/builder.d.ts +0 -0
- /package/dist/types/components/{layout/css-grid → css-grid}/css-grid-item.d.ts +0 -0
- /package/dist/types/components/{layout/css-grid → css-grid}/css-grid.d.ts +0 -0
- /package/scss/{components → legacy/components}/_button-group.scss +0 -0
|
@@ -1,19 +1,123 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
+
const min = Math.min;
|
|
4
|
+
const max = Math.max;
|
|
5
|
+
const round = Math.round;
|
|
6
|
+
const floor = Math.floor;
|
|
7
|
+
const createCoords = v => ({
|
|
8
|
+
x: v,
|
|
9
|
+
y: v
|
|
10
|
+
});
|
|
11
|
+
const oppositeSideMap = {
|
|
12
|
+
left: 'right',
|
|
13
|
+
right: 'left',
|
|
14
|
+
bottom: 'top',
|
|
15
|
+
top: 'bottom'
|
|
16
|
+
};
|
|
17
|
+
const oppositeAlignmentMap = {
|
|
18
|
+
start: 'end',
|
|
19
|
+
end: 'start'
|
|
20
|
+
};
|
|
21
|
+
function clamp(start, value, end) {
|
|
22
|
+
return max(start, min(value, end));
|
|
23
|
+
}
|
|
24
|
+
function evaluate(value, param) {
|
|
25
|
+
return typeof value === 'function' ? value(param) : value;
|
|
26
|
+
}
|
|
27
|
+
function getSide(placement) {
|
|
28
|
+
return placement.split('-')[0];
|
|
29
|
+
}
|
|
3
30
|
function getAlignment(placement) {
|
|
4
31
|
return placement.split('-')[1];
|
|
5
32
|
}
|
|
6
|
-
|
|
7
|
-
|
|
33
|
+
function getOppositeAxis(axis) {
|
|
34
|
+
return axis === 'x' ? 'y' : 'x';
|
|
35
|
+
}
|
|
36
|
+
function getAxisLength(axis) {
|
|
8
37
|
return axis === 'y' ? 'height' : 'width';
|
|
9
38
|
}
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
return placement.split('-')[0];
|
|
39
|
+
function getSideAxis(placement) {
|
|
40
|
+
return ['top', 'bottom'].includes(getSide(placement)) ? 'y' : 'x';
|
|
13
41
|
}
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
42
|
+
function getAlignmentAxis(placement) {
|
|
43
|
+
return getOppositeAxis(getSideAxis(placement));
|
|
44
|
+
}
|
|
45
|
+
function getAlignmentSides(placement, rects, rtl) {
|
|
46
|
+
if (rtl === void 0) {
|
|
47
|
+
rtl = false;
|
|
48
|
+
}
|
|
49
|
+
const alignment = getAlignment(placement);
|
|
50
|
+
const alignmentAxis = getAlignmentAxis(placement);
|
|
51
|
+
const length = getAxisLength(alignmentAxis);
|
|
52
|
+
let mainAlignmentSide = alignmentAxis === 'x' ? alignment === (rtl ? 'end' : 'start') ? 'right' : 'left' : alignment === 'start' ? 'bottom' : 'top';
|
|
53
|
+
if (rects.reference[length] > rects.floating[length]) {
|
|
54
|
+
mainAlignmentSide = getOppositePlacement(mainAlignmentSide);
|
|
55
|
+
}
|
|
56
|
+
return [mainAlignmentSide, getOppositePlacement(mainAlignmentSide)];
|
|
57
|
+
}
|
|
58
|
+
function getExpandedPlacements(placement) {
|
|
59
|
+
const oppositePlacement = getOppositePlacement(placement);
|
|
60
|
+
return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];
|
|
61
|
+
}
|
|
62
|
+
function getOppositeAlignmentPlacement(placement) {
|
|
63
|
+
return placement.replace(/start|end/g, alignment => oppositeAlignmentMap[alignment]);
|
|
64
|
+
}
|
|
65
|
+
function getSideList(side, isStart, rtl) {
|
|
66
|
+
const lr = ['left', 'right'];
|
|
67
|
+
const rl = ['right', 'left'];
|
|
68
|
+
const tb = ['top', 'bottom'];
|
|
69
|
+
const bt = ['bottom', 'top'];
|
|
70
|
+
switch (side) {
|
|
71
|
+
case 'top':
|
|
72
|
+
case 'bottom':
|
|
73
|
+
if (rtl) return isStart ? rl : lr;
|
|
74
|
+
return isStart ? lr : rl;
|
|
75
|
+
case 'left':
|
|
76
|
+
case 'right':
|
|
77
|
+
return isStart ? tb : bt;
|
|
78
|
+
default:
|
|
79
|
+
return [];
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
function getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {
|
|
83
|
+
const alignment = getAlignment(placement);
|
|
84
|
+
let list = getSideList(getSide(placement), direction === 'start', rtl);
|
|
85
|
+
if (alignment) {
|
|
86
|
+
list = list.map(side => side + "-" + alignment);
|
|
87
|
+
if (flipAlignment) {
|
|
88
|
+
list = list.concat(list.map(getOppositeAlignmentPlacement));
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
return list;
|
|
92
|
+
}
|
|
93
|
+
function getOppositePlacement(placement) {
|
|
94
|
+
return placement.replace(/left|right|bottom|top/g, side => oppositeSideMap[side]);
|
|
95
|
+
}
|
|
96
|
+
function expandPaddingObject(padding) {
|
|
97
|
+
return {
|
|
98
|
+
top: 0,
|
|
99
|
+
right: 0,
|
|
100
|
+
bottom: 0,
|
|
101
|
+
left: 0,
|
|
102
|
+
...padding
|
|
103
|
+
};
|
|
104
|
+
}
|
|
105
|
+
function getPaddingObject(padding) {
|
|
106
|
+
return typeof padding !== 'number' ? expandPaddingObject(padding) : {
|
|
107
|
+
top: padding,
|
|
108
|
+
right: padding,
|
|
109
|
+
bottom: padding,
|
|
110
|
+
left: padding
|
|
111
|
+
};
|
|
112
|
+
}
|
|
113
|
+
function rectToClientRect(rect) {
|
|
114
|
+
return {
|
|
115
|
+
...rect,
|
|
116
|
+
top: rect.y,
|
|
117
|
+
left: rect.x,
|
|
118
|
+
right: rect.x + rect.width,
|
|
119
|
+
bottom: rect.y + rect.height
|
|
120
|
+
};
|
|
17
121
|
}
|
|
18
122
|
|
|
19
123
|
function computeCoordsFromPlacement(_ref, placement, rtl) {
|
|
@@ -21,13 +125,14 @@ function computeCoordsFromPlacement(_ref, placement, rtl) {
|
|
|
21
125
|
reference,
|
|
22
126
|
floating
|
|
23
127
|
} = _ref;
|
|
128
|
+
const sideAxis = getSideAxis(placement);
|
|
129
|
+
const alignmentAxis = getAlignmentAxis(placement);
|
|
130
|
+
const alignLength = getAxisLength(alignmentAxis);
|
|
131
|
+
const side = getSide(placement);
|
|
132
|
+
const isVertical = sideAxis === 'y';
|
|
24
133
|
const commonX = reference.x + reference.width / 2 - floating.width / 2;
|
|
25
134
|
const commonY = reference.y + reference.height / 2 - floating.height / 2;
|
|
26
|
-
const
|
|
27
|
-
const length = getLengthFromAxis(mainAxis);
|
|
28
|
-
const commonAlign = reference[length] / 2 - floating[length] / 2;
|
|
29
|
-
const side = getSide(placement);
|
|
30
|
-
const isVertical = mainAxis === 'x';
|
|
135
|
+
const commonAlign = reference[alignLength] / 2 - floating[alignLength] / 2;
|
|
31
136
|
let coords;
|
|
32
137
|
switch (side) {
|
|
33
138
|
case 'top':
|
|
@@ -62,10 +167,10 @@ function computeCoordsFromPlacement(_ref, placement, rtl) {
|
|
|
62
167
|
}
|
|
63
168
|
switch (getAlignment(placement)) {
|
|
64
169
|
case 'start':
|
|
65
|
-
coords[
|
|
170
|
+
coords[alignmentAxis] -= commonAlign * (rtl && isVertical ? -1 : 1);
|
|
66
171
|
break;
|
|
67
172
|
case 'end':
|
|
68
|
-
coords[
|
|
173
|
+
coords[alignmentAxis] += commonAlign * (rtl && isVertical ? -1 : 1);
|
|
69
174
|
break;
|
|
70
175
|
}
|
|
71
176
|
return coords;
|
|
@@ -163,44 +268,15 @@ const computePosition$1 = async (reference, floating, config) => {
|
|
|
163
268
|
};
|
|
164
269
|
};
|
|
165
270
|
|
|
166
|
-
function expandPaddingObject(padding) {
|
|
167
|
-
return {
|
|
168
|
-
top: 0,
|
|
169
|
-
right: 0,
|
|
170
|
-
bottom: 0,
|
|
171
|
-
left: 0,
|
|
172
|
-
...padding
|
|
173
|
-
};
|
|
174
|
-
}
|
|
175
|
-
|
|
176
|
-
function getSideObjectFromPadding(padding) {
|
|
177
|
-
return typeof padding !== 'number' ? expandPaddingObject(padding) : {
|
|
178
|
-
top: padding,
|
|
179
|
-
right: padding,
|
|
180
|
-
bottom: padding,
|
|
181
|
-
left: padding
|
|
182
|
-
};
|
|
183
|
-
}
|
|
184
|
-
|
|
185
|
-
function rectToClientRect(rect) {
|
|
186
|
-
return {
|
|
187
|
-
...rect,
|
|
188
|
-
top: rect.y,
|
|
189
|
-
left: rect.x,
|
|
190
|
-
right: rect.x + rect.width,
|
|
191
|
-
bottom: rect.y + rect.height
|
|
192
|
-
};
|
|
193
|
-
}
|
|
194
|
-
|
|
195
271
|
/**
|
|
196
272
|
* Resolves with an object of overflow side offsets that determine how much the
|
|
197
|
-
* element is overflowing a given clipping boundary.
|
|
273
|
+
* element is overflowing a given clipping boundary on each side.
|
|
198
274
|
* - positive = overflowing the boundary by that number of pixels
|
|
199
275
|
* - negative = how many pixels left before it will overflow
|
|
200
276
|
* - 0 = lies flush with the boundary
|
|
201
277
|
* @see https://floating-ui.com/docs/detectOverflow
|
|
202
278
|
*/
|
|
203
|
-
async function detectOverflow(
|
|
279
|
+
async function detectOverflow(state, options) {
|
|
204
280
|
var _await$platform$isEle;
|
|
205
281
|
if (options === void 0) {
|
|
206
282
|
options = {};
|
|
@@ -212,15 +288,15 @@ async function detectOverflow(middlewareArguments, options) {
|
|
|
212
288
|
rects,
|
|
213
289
|
elements,
|
|
214
290
|
strategy
|
|
215
|
-
} =
|
|
291
|
+
} = state;
|
|
216
292
|
const {
|
|
217
293
|
boundary = 'clippingAncestors',
|
|
218
294
|
rootBoundary = 'viewport',
|
|
219
295
|
elementContext = 'floating',
|
|
220
296
|
altBoundary = false,
|
|
221
297
|
padding = 0
|
|
222
|
-
} = options;
|
|
223
|
-
const paddingObject =
|
|
298
|
+
} = evaluate(options, state);
|
|
299
|
+
const paddingObject = getPaddingObject(padding);
|
|
224
300
|
const altContext = elementContext === 'floating' ? 'reference' : 'floating';
|
|
225
301
|
const element = elements[altBoundary ? altContext : elementContext];
|
|
226
302
|
const clippingClientRect = rectToClientRect(await platform.getClippingRect({
|
|
@@ -255,151 +331,87 @@ async function detectOverflow(middlewareArguments, options) {
|
|
|
255
331
|
};
|
|
256
332
|
}
|
|
257
333
|
|
|
258
|
-
const min$1 = Math.min;
|
|
259
|
-
const max$1 = Math.max;
|
|
260
|
-
|
|
261
|
-
function within(min$1$1, value, max$1$1) {
|
|
262
|
-
return max$1(min$1$1, min$1(value, max$1$1));
|
|
263
|
-
}
|
|
264
|
-
|
|
265
334
|
/**
|
|
266
|
-
*
|
|
267
|
-
* to the reference element.
|
|
335
|
+
* Provides data to position an inner element of the floating element so that it
|
|
336
|
+
* appears centered to the reference element.
|
|
268
337
|
* @see https://floating-ui.com/docs/arrow
|
|
269
338
|
*/
|
|
270
339
|
const arrow = options => ({
|
|
271
340
|
name: 'arrow',
|
|
272
341
|
options,
|
|
273
|
-
async fn(
|
|
274
|
-
// Since `element` is required, we don't Partial<> the type.
|
|
275
|
-
const {
|
|
276
|
-
element,
|
|
277
|
-
padding = 0
|
|
278
|
-
} = options || {};
|
|
342
|
+
async fn(state) {
|
|
279
343
|
const {
|
|
280
344
|
x,
|
|
281
345
|
y,
|
|
282
346
|
placement,
|
|
283
347
|
rects,
|
|
284
|
-
platform
|
|
285
|
-
|
|
348
|
+
platform,
|
|
349
|
+
elements
|
|
350
|
+
} = state;
|
|
351
|
+
// Since `element` is required, we don't Partial<> the type.
|
|
352
|
+
const {
|
|
353
|
+
element,
|
|
354
|
+
padding = 0
|
|
355
|
+
} = evaluate(options, state) || {};
|
|
286
356
|
if (element == null) {
|
|
287
357
|
return {};
|
|
288
358
|
}
|
|
289
|
-
const paddingObject =
|
|
359
|
+
const paddingObject = getPaddingObject(padding);
|
|
290
360
|
const coords = {
|
|
291
361
|
x,
|
|
292
362
|
y
|
|
293
363
|
};
|
|
294
|
-
const axis =
|
|
295
|
-
const length =
|
|
364
|
+
const axis = getAlignmentAxis(placement);
|
|
365
|
+
const length = getAxisLength(axis);
|
|
296
366
|
const arrowDimensions = await platform.getDimensions(element);
|
|
297
|
-
const
|
|
298
|
-
const
|
|
367
|
+
const isYAxis = axis === 'y';
|
|
368
|
+
const minProp = isYAxis ? 'top' : 'left';
|
|
369
|
+
const maxProp = isYAxis ? 'bottom' : 'right';
|
|
370
|
+
const clientProp = isYAxis ? 'clientHeight' : 'clientWidth';
|
|
299
371
|
const endDiff = rects.reference[length] + rects.reference[axis] - coords[axis] - rects.floating[length];
|
|
300
372
|
const startDiff = coords[axis] - rects.reference[axis];
|
|
301
373
|
const arrowOffsetParent = await (platform.getOffsetParent == null ? void 0 : platform.getOffsetParent(element));
|
|
302
|
-
let clientSize = arrowOffsetParent ?
|
|
303
|
-
|
|
304
|
-
|
|
374
|
+
let clientSize = arrowOffsetParent ? arrowOffsetParent[clientProp] : 0;
|
|
375
|
+
|
|
376
|
+
// DOM platform can return `window` as the `offsetParent`.
|
|
377
|
+
if (!clientSize || !(await (platform.isElement == null ? void 0 : platform.isElement(arrowOffsetParent)))) {
|
|
378
|
+
clientSize = elements.floating[clientProp] || rects.floating[length];
|
|
305
379
|
}
|
|
306
380
|
const centerToReference = endDiff / 2 - startDiff / 2;
|
|
307
381
|
|
|
382
|
+
// If the padding is large enough that it causes the arrow to no longer be
|
|
383
|
+
// centered, modify the padding so that it is centered.
|
|
384
|
+
const largestPossiblePadding = clientSize / 2 - arrowDimensions[length] / 2 - 1;
|
|
385
|
+
const minPadding = min(paddingObject[minProp], largestPossiblePadding);
|
|
386
|
+
const maxPadding = min(paddingObject[maxProp], largestPossiblePadding);
|
|
387
|
+
|
|
308
388
|
// Make sure the arrow doesn't overflow the floating element if the center
|
|
309
389
|
// point is outside the floating element's bounds.
|
|
310
|
-
const min =
|
|
311
|
-
const max = clientSize - arrowDimensions[length] -
|
|
390
|
+
const min$1 = minPadding;
|
|
391
|
+
const max = clientSize - arrowDimensions[length] - maxPadding;
|
|
312
392
|
const center = clientSize / 2 - arrowDimensions[length] / 2 + centerToReference;
|
|
313
|
-
const offset =
|
|
393
|
+
const offset = clamp(min$1, center, max);
|
|
314
394
|
|
|
315
395
|
// If the reference is small enough that the arrow's padding causes it to
|
|
316
396
|
// to point to nothing for an aligned placement, adjust the offset of the
|
|
317
397
|
// floating element itself. This stops `shift()` from taking action, but can
|
|
318
398
|
// be worked around by calling it again after the `arrow()` if desired.
|
|
319
|
-
const shouldAddOffset = getAlignment(placement) != null && center != offset && rects.reference[length] / 2 - (center < min ?
|
|
320
|
-
const alignmentOffset = shouldAddOffset ? center < min ? min - center : max - center : 0;
|
|
399
|
+
const shouldAddOffset = getAlignment(placement) != null && center != offset && rects.reference[length] / 2 - (center < min$1 ? minPadding : maxPadding) - arrowDimensions[length] / 2 < 0;
|
|
400
|
+
const alignmentOffset = shouldAddOffset ? center < min$1 ? min$1 - center : max - center : 0;
|
|
321
401
|
return {
|
|
322
402
|
[axis]: coords[axis] - alignmentOffset,
|
|
323
403
|
data: {
|
|
324
404
|
[axis]: offset,
|
|
325
|
-
centerOffset: center - offset
|
|
405
|
+
centerOffset: center - offset + alignmentOffset
|
|
326
406
|
}
|
|
327
407
|
};
|
|
328
408
|
}
|
|
329
409
|
});
|
|
330
410
|
|
|
331
|
-
const oppositeSideMap = {
|
|
332
|
-
left: 'right',
|
|
333
|
-
right: 'left',
|
|
334
|
-
bottom: 'top',
|
|
335
|
-
top: 'bottom'
|
|
336
|
-
};
|
|
337
|
-
function getOppositePlacement(placement) {
|
|
338
|
-
return placement.replace(/left|right|bottom|top/g, side => oppositeSideMap[side]);
|
|
339
|
-
}
|
|
340
|
-
|
|
341
|
-
function getAlignmentSides(placement, rects, rtl) {
|
|
342
|
-
if (rtl === void 0) {
|
|
343
|
-
rtl = false;
|
|
344
|
-
}
|
|
345
|
-
const alignment = getAlignment(placement);
|
|
346
|
-
const mainAxis = getMainAxisFromPlacement(placement);
|
|
347
|
-
const length = getLengthFromAxis(mainAxis);
|
|
348
|
-
let mainAlignmentSide = mainAxis === 'x' ? alignment === (rtl ? 'end' : 'start') ? 'right' : 'left' : alignment === 'start' ? 'bottom' : 'top';
|
|
349
|
-
if (rects.reference[length] > rects.floating[length]) {
|
|
350
|
-
mainAlignmentSide = getOppositePlacement(mainAlignmentSide);
|
|
351
|
-
}
|
|
352
|
-
return {
|
|
353
|
-
main: mainAlignmentSide,
|
|
354
|
-
cross: getOppositePlacement(mainAlignmentSide)
|
|
355
|
-
};
|
|
356
|
-
}
|
|
357
|
-
|
|
358
|
-
const oppositeAlignmentMap = {
|
|
359
|
-
start: 'end',
|
|
360
|
-
end: 'start'
|
|
361
|
-
};
|
|
362
|
-
function getOppositeAlignmentPlacement(placement) {
|
|
363
|
-
return placement.replace(/start|end/g, alignment => oppositeAlignmentMap[alignment]);
|
|
364
|
-
}
|
|
365
|
-
|
|
366
|
-
function getExpandedPlacements(placement) {
|
|
367
|
-
const oppositePlacement = getOppositePlacement(placement);
|
|
368
|
-
return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];
|
|
369
|
-
}
|
|
370
|
-
|
|
371
|
-
function getSideList(side, isStart, rtl) {
|
|
372
|
-
const lr = ['left', 'right'];
|
|
373
|
-
const rl = ['right', 'left'];
|
|
374
|
-
const tb = ['top', 'bottom'];
|
|
375
|
-
const bt = ['bottom', 'top'];
|
|
376
|
-
switch (side) {
|
|
377
|
-
case 'top':
|
|
378
|
-
case 'bottom':
|
|
379
|
-
if (rtl) return isStart ? rl : lr;
|
|
380
|
-
return isStart ? lr : rl;
|
|
381
|
-
case 'left':
|
|
382
|
-
case 'right':
|
|
383
|
-
return isStart ? tb : bt;
|
|
384
|
-
default:
|
|
385
|
-
return [];
|
|
386
|
-
}
|
|
387
|
-
}
|
|
388
|
-
function getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {
|
|
389
|
-
const alignment = getAlignment(placement);
|
|
390
|
-
let list = getSideList(getSide(placement), direction === 'start', rtl);
|
|
391
|
-
if (alignment) {
|
|
392
|
-
list = list.map(side => side + "-" + alignment);
|
|
393
|
-
if (flipAlignment) {
|
|
394
|
-
list = list.concat(list.map(getOppositeAlignmentPlacement));
|
|
395
|
-
}
|
|
396
|
-
}
|
|
397
|
-
return list;
|
|
398
|
-
}
|
|
399
|
-
|
|
400
411
|
/**
|
|
401
|
-
*
|
|
402
|
-
*
|
|
412
|
+
* Optimizes the visibility of the floating element by flipping the `placement`
|
|
413
|
+
* in order to keep it in view when the preferred placement(s) will overflow the
|
|
414
|
+
* clipping boundary. Alternative to `autoPlacement`.
|
|
403
415
|
* @see https://floating-ui.com/docs/flip
|
|
404
416
|
*/
|
|
405
417
|
const flip = function (options) {
|
|
@@ -409,7 +421,7 @@ const flip = function (options) {
|
|
|
409
421
|
return {
|
|
410
422
|
name: 'flip',
|
|
411
423
|
options,
|
|
412
|
-
async fn(
|
|
424
|
+
async fn(state) {
|
|
413
425
|
var _middlewareData$flip;
|
|
414
426
|
const {
|
|
415
427
|
placement,
|
|
@@ -418,7 +430,7 @@ const flip = function (options) {
|
|
|
418
430
|
initialPlacement,
|
|
419
431
|
platform,
|
|
420
432
|
elements
|
|
421
|
-
} =
|
|
433
|
+
} = state;
|
|
422
434
|
const {
|
|
423
435
|
mainAxis: checkMainAxis = true,
|
|
424
436
|
crossAxis: checkCrossAxis = true,
|
|
@@ -427,7 +439,7 @@ const flip = function (options) {
|
|
|
427
439
|
fallbackAxisSideDirection = 'none',
|
|
428
440
|
flipAlignment = true,
|
|
429
441
|
...detectOverflowOptions
|
|
430
|
-
} = options;
|
|
442
|
+
} = evaluate(options, state);
|
|
431
443
|
const side = getSide(placement);
|
|
432
444
|
const isBasePlacement = getSide(initialPlacement) === initialPlacement;
|
|
433
445
|
const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));
|
|
@@ -436,18 +448,15 @@ const flip = function (options) {
|
|
|
436
448
|
fallbackPlacements.push(...getOppositeAxisPlacements(initialPlacement, flipAlignment, fallbackAxisSideDirection, rtl));
|
|
437
449
|
}
|
|
438
450
|
const placements = [initialPlacement, ...fallbackPlacements];
|
|
439
|
-
const overflow = await detectOverflow(
|
|
451
|
+
const overflow = await detectOverflow(state, detectOverflowOptions);
|
|
440
452
|
const overflows = [];
|
|
441
453
|
let overflowsData = ((_middlewareData$flip = middlewareData.flip) == null ? void 0 : _middlewareData$flip.overflows) || [];
|
|
442
454
|
if (checkMainAxis) {
|
|
443
455
|
overflows.push(overflow[side]);
|
|
444
456
|
}
|
|
445
457
|
if (checkCrossAxis) {
|
|
446
|
-
const
|
|
447
|
-
|
|
448
|
-
cross
|
|
449
|
-
} = getAlignmentSides(placement, rects, rtl);
|
|
450
|
-
overflows.push(overflow[main], overflow[cross]);
|
|
458
|
+
const sides = getAlignmentSides(placement, rects, rtl);
|
|
459
|
+
overflows.push(overflow[sides[0]], overflow[sides[1]]);
|
|
451
460
|
}
|
|
452
461
|
overflowsData = [...overflowsData, {
|
|
453
462
|
placement,
|
|
@@ -456,7 +465,7 @@ const flip = function (options) {
|
|
|
456
465
|
|
|
457
466
|
// One or more sides is overflowing.
|
|
458
467
|
if (!overflows.every(side => side <= 0)) {
|
|
459
|
-
var _middlewareData$flip2;
|
|
468
|
+
var _middlewareData$flip2, _overflowsData$filter;
|
|
460
469
|
const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;
|
|
461
470
|
const nextPlacement = placements[nextIndex];
|
|
462
471
|
if (nextPlacement) {
|
|
@@ -471,20 +480,27 @@ const flip = function (options) {
|
|
|
471
480
|
}
|
|
472
481
|
};
|
|
473
482
|
}
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
483
|
+
|
|
484
|
+
// First, find the candidates that fit on the mainAxis side of overflow,
|
|
485
|
+
// then find the placement that fits the best on the main crossAxis side.
|
|
486
|
+
let resetPlacement = (_overflowsData$filter = overflowsData.filter(d => d.overflows[0] <= 0).sort((a, b) => a.overflows[1] - b.overflows[1])[0]) == null ? void 0 : _overflowsData$filter.placement;
|
|
487
|
+
|
|
488
|
+
// Otherwise fallback.
|
|
489
|
+
if (!resetPlacement) {
|
|
490
|
+
switch (fallbackStrategy) {
|
|
491
|
+
case 'bestFit':
|
|
492
|
+
{
|
|
493
|
+
var _overflowsData$map$so;
|
|
494
|
+
const placement = (_overflowsData$map$so = overflowsData.map(d => [d.placement, d.overflows.filter(overflow => overflow > 0).reduce((acc, overflow) => acc + overflow, 0)]).sort((a, b) => a[1] - b[1])[0]) == null ? void 0 : _overflowsData$map$so[0];
|
|
495
|
+
if (placement) {
|
|
496
|
+
resetPlacement = placement;
|
|
497
|
+
}
|
|
498
|
+
break;
|
|
482
499
|
}
|
|
500
|
+
case 'initialPlacement':
|
|
501
|
+
resetPlacement = initialPlacement;
|
|
483
502
|
break;
|
|
484
|
-
|
|
485
|
-
case 'initialPlacement':
|
|
486
|
-
resetPlacement = initialPlacement;
|
|
487
|
-
break;
|
|
503
|
+
}
|
|
488
504
|
}
|
|
489
505
|
if (placement !== resetPlacement) {
|
|
490
506
|
return {
|
|
@@ -499,6 +515,33 @@ const flip = function (options) {
|
|
|
499
515
|
};
|
|
500
516
|
};
|
|
501
517
|
|
|
518
|
+
function getBoundingRect(rects) {
|
|
519
|
+
const minX = min(...rects.map(rect => rect.left));
|
|
520
|
+
const minY = min(...rects.map(rect => rect.top));
|
|
521
|
+
const maxX = max(...rects.map(rect => rect.right));
|
|
522
|
+
const maxY = max(...rects.map(rect => rect.bottom));
|
|
523
|
+
return {
|
|
524
|
+
x: minX,
|
|
525
|
+
y: minY,
|
|
526
|
+
width: maxX - minX,
|
|
527
|
+
height: maxY - minY
|
|
528
|
+
};
|
|
529
|
+
}
|
|
530
|
+
function getRectsByLine(rects) {
|
|
531
|
+
const sortedRects = rects.slice().sort((a, b) => a.y - b.y);
|
|
532
|
+
const groups = [];
|
|
533
|
+
let prevRect = null;
|
|
534
|
+
for (let i = 0; i < sortedRects.length; i++) {
|
|
535
|
+
const rect = sortedRects[i];
|
|
536
|
+
if (!prevRect || rect.y - prevRect.y > prevRect.height / 2) {
|
|
537
|
+
groups.push([rect]);
|
|
538
|
+
} else {
|
|
539
|
+
groups[groups.length - 1].push(rect);
|
|
540
|
+
}
|
|
541
|
+
prevRect = rect;
|
|
542
|
+
}
|
|
543
|
+
return groups.map(rect => rectToClientRect(getBoundingRect(rect)));
|
|
544
|
+
}
|
|
502
545
|
/**
|
|
503
546
|
* Provides improved positioning for inline reference elements that can span
|
|
504
547
|
* over multiple lines, such as hyperlinks or range selections.
|
|
@@ -511,14 +554,14 @@ const inline = function (options) {
|
|
|
511
554
|
return {
|
|
512
555
|
name: 'inline',
|
|
513
556
|
options,
|
|
514
|
-
async fn(
|
|
557
|
+
async fn(state) {
|
|
515
558
|
const {
|
|
516
559
|
placement,
|
|
517
560
|
elements,
|
|
518
561
|
rects,
|
|
519
562
|
platform,
|
|
520
563
|
strategy
|
|
521
|
-
} =
|
|
564
|
+
} = state;
|
|
522
565
|
// A MouseEvent's client{X,Y} coords can be up to 2 pixels off a
|
|
523
566
|
// ClientRect's bounds, despite the event listener being triggered. A
|
|
524
567
|
// padding of 2 seems to handle this issue.
|
|
@@ -526,14 +569,11 @@ const inline = function (options) {
|
|
|
526
569
|
padding = 2,
|
|
527
570
|
x,
|
|
528
571
|
y
|
|
529
|
-
} = options;
|
|
530
|
-
const
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
}) : rects.reference);
|
|
535
|
-
const clientRects = (await (platform.getClientRects == null ? void 0 : platform.getClientRects(elements.reference))) || [];
|
|
536
|
-
const paddingObject = getSideObjectFromPadding(padding);
|
|
572
|
+
} = evaluate(options, state);
|
|
573
|
+
const nativeClientRects = Array.from((await (platform.getClientRects == null ? void 0 : platform.getClientRects(elements.reference))) || []);
|
|
574
|
+
const clientRects = getRectsByLine(nativeClientRects);
|
|
575
|
+
const fallback = rectToClientRect(getBoundingRect(nativeClientRects));
|
|
576
|
+
const paddingObject = getPaddingObject(padding);
|
|
537
577
|
function getBoundingClientRect() {
|
|
538
578
|
// There are two rects and they are disjoined.
|
|
539
579
|
if (clientRects.length === 2 && clientRects[0].left > clientRects[1].right && x != null && y != null) {
|
|
@@ -543,7 +583,7 @@ const inline = function (options) {
|
|
|
543
583
|
|
|
544
584
|
// There are 2 or more connected rects.
|
|
545
585
|
if (clientRects.length >= 2) {
|
|
546
|
-
if (
|
|
586
|
+
if (getSideAxis(placement) === 'y') {
|
|
547
587
|
const firstRect = clientRects[0];
|
|
548
588
|
const lastRect = clientRects[clientRects.length - 1];
|
|
549
589
|
const isTop = getSide(placement) === 'top';
|
|
@@ -565,8 +605,8 @@ const inline = function (options) {
|
|
|
565
605
|
};
|
|
566
606
|
}
|
|
567
607
|
const isLeftSide = getSide(placement) === 'left';
|
|
568
|
-
const maxRight = max
|
|
569
|
-
const minLeft = min
|
|
608
|
+
const maxRight = max(...clientRects.map(rect => rect.right));
|
|
609
|
+
const minLeft = min(...clientRects.map(rect => rect.left));
|
|
570
610
|
const measureRects = clientRects.filter(rect => isLeftSide ? rect.left === minLeft : rect.right === maxRight);
|
|
571
611
|
const top = measureRects[0].top;
|
|
572
612
|
const bottom = measureRects[measureRects.length - 1].bottom;
|
|
@@ -606,19 +646,21 @@ const inline = function (options) {
|
|
|
606
646
|
};
|
|
607
647
|
};
|
|
608
648
|
|
|
609
|
-
|
|
649
|
+
// For type backwards-compatibility, the `OffsetOptions` type was also
|
|
650
|
+
// Derivable.
|
|
651
|
+
async function convertValueToCoords(state, options) {
|
|
610
652
|
const {
|
|
611
653
|
placement,
|
|
612
654
|
platform,
|
|
613
655
|
elements
|
|
614
|
-
} =
|
|
656
|
+
} = state;
|
|
615
657
|
const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));
|
|
616
658
|
const side = getSide(placement);
|
|
617
659
|
const alignment = getAlignment(placement);
|
|
618
|
-
const isVertical =
|
|
660
|
+
const isVertical = getSideAxis(placement) === 'y';
|
|
619
661
|
const mainAxisMulti = ['left', 'top'].includes(side) ? -1 : 1;
|
|
620
662
|
const crossAxisMulti = rtl && isVertical ? -1 : 1;
|
|
621
|
-
const rawValue =
|
|
663
|
+
const rawValue = evaluate(options, state);
|
|
622
664
|
|
|
623
665
|
// eslint-disable-next-line prefer-const
|
|
624
666
|
let {
|
|
@@ -648,22 +690,25 @@ async function convertValueToCoords(middlewareArguments, value) {
|
|
|
648
690
|
}
|
|
649
691
|
|
|
650
692
|
/**
|
|
651
|
-
*
|
|
693
|
+
* Modifies the placement by translating the floating element along the
|
|
694
|
+
* specified axes.
|
|
695
|
+
* A number (shorthand for `mainAxis` or distance), or an axes configuration
|
|
696
|
+
* object may be passed.
|
|
652
697
|
* @see https://floating-ui.com/docs/offset
|
|
653
698
|
*/
|
|
654
|
-
const offset = function (
|
|
655
|
-
if (
|
|
656
|
-
|
|
699
|
+
const offset = function (options) {
|
|
700
|
+
if (options === void 0) {
|
|
701
|
+
options = 0;
|
|
657
702
|
}
|
|
658
703
|
return {
|
|
659
704
|
name: 'offset',
|
|
660
|
-
options
|
|
661
|
-
async fn(
|
|
705
|
+
options,
|
|
706
|
+
async fn(state) {
|
|
662
707
|
const {
|
|
663
708
|
x,
|
|
664
709
|
y
|
|
665
|
-
} =
|
|
666
|
-
const diffCoords = await convertValueToCoords(
|
|
710
|
+
} = state;
|
|
711
|
+
const diffCoords = await convertValueToCoords(state, options);
|
|
667
712
|
return {
|
|
668
713
|
x: x + diffCoords.x,
|
|
669
714
|
y: y + diffCoords.y,
|
|
@@ -673,13 +718,9 @@ const offset = function (value) {
|
|
|
673
718
|
};
|
|
674
719
|
};
|
|
675
720
|
|
|
676
|
-
function getCrossAxis(axis) {
|
|
677
|
-
return axis === 'x' ? 'y' : 'x';
|
|
678
|
-
}
|
|
679
|
-
|
|
680
721
|
/**
|
|
681
|
-
*
|
|
682
|
-
*
|
|
722
|
+
* Optimizes the visibility of the floating element by shifting it in order to
|
|
723
|
+
* keep it in view when it will overflow the clipping boundary.
|
|
683
724
|
* @see https://floating-ui.com/docs/shift
|
|
684
725
|
*/
|
|
685
726
|
const shift = function (options) {
|
|
@@ -689,12 +730,12 @@ const shift = function (options) {
|
|
|
689
730
|
return {
|
|
690
731
|
name: 'shift',
|
|
691
732
|
options,
|
|
692
|
-
async fn(
|
|
733
|
+
async fn(state) {
|
|
693
734
|
const {
|
|
694
735
|
x,
|
|
695
736
|
y,
|
|
696
737
|
placement
|
|
697
|
-
} =
|
|
738
|
+
} = state;
|
|
698
739
|
const {
|
|
699
740
|
mainAxis: checkMainAxis = true,
|
|
700
741
|
crossAxis: checkCrossAxis = false,
|
|
@@ -711,14 +752,14 @@ const shift = function (options) {
|
|
|
711
752
|
}
|
|
712
753
|
},
|
|
713
754
|
...detectOverflowOptions
|
|
714
|
-
} = options;
|
|
755
|
+
} = evaluate(options, state);
|
|
715
756
|
const coords = {
|
|
716
757
|
x,
|
|
717
758
|
y
|
|
718
759
|
};
|
|
719
|
-
const overflow = await detectOverflow(
|
|
720
|
-
const
|
|
721
|
-
const
|
|
760
|
+
const overflow = await detectOverflow(state, detectOverflowOptions);
|
|
761
|
+
const crossAxis = getSideAxis(getSide(placement));
|
|
762
|
+
const mainAxis = getOppositeAxis(crossAxis);
|
|
722
763
|
let mainAxisCoord = coords[mainAxis];
|
|
723
764
|
let crossAxisCoord = coords[crossAxis];
|
|
724
765
|
if (checkMainAxis) {
|
|
@@ -726,17 +767,17 @@ const shift = function (options) {
|
|
|
726
767
|
const maxSide = mainAxis === 'y' ? 'bottom' : 'right';
|
|
727
768
|
const min = mainAxisCoord + overflow[minSide];
|
|
728
769
|
const max = mainAxisCoord - overflow[maxSide];
|
|
729
|
-
mainAxisCoord =
|
|
770
|
+
mainAxisCoord = clamp(min, mainAxisCoord, max);
|
|
730
771
|
}
|
|
731
772
|
if (checkCrossAxis) {
|
|
732
773
|
const minSide = crossAxis === 'y' ? 'top' : 'left';
|
|
733
774
|
const maxSide = crossAxis === 'y' ? 'bottom' : 'right';
|
|
734
775
|
const min = crossAxisCoord + overflow[minSide];
|
|
735
776
|
const max = crossAxisCoord - overflow[maxSide];
|
|
736
|
-
crossAxisCoord =
|
|
777
|
+
crossAxisCoord = clamp(min, crossAxisCoord, max);
|
|
737
778
|
}
|
|
738
779
|
const limitedCoords = limiter.fn({
|
|
739
|
-
...
|
|
780
|
+
...state,
|
|
740
781
|
[mainAxis]: mainAxisCoord,
|
|
741
782
|
[crossAxis]: crossAxisCoord
|
|
742
783
|
});
|
|
@@ -751,48 +792,38 @@ const shift = function (options) {
|
|
|
751
792
|
};
|
|
752
793
|
};
|
|
753
794
|
|
|
795
|
+
function getNodeName(node) {
|
|
796
|
+
if (isNode(node)) {
|
|
797
|
+
return (node.nodeName || '').toLowerCase();
|
|
798
|
+
}
|
|
799
|
+
// Mocked nodes in testing environments may not be instances of Node. By
|
|
800
|
+
// returning `#document` an infinite loop won't occur.
|
|
801
|
+
// https://github.com/floating-ui/floating-ui/issues/2317
|
|
802
|
+
return '#document';
|
|
803
|
+
}
|
|
754
804
|
function getWindow(node) {
|
|
755
805
|
var _node$ownerDocument;
|
|
756
|
-
return ((_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;
|
|
757
|
-
}
|
|
758
|
-
|
|
759
|
-
function getComputedStyle$1(element) {
|
|
760
|
-
return getWindow(element).getComputedStyle(element);
|
|
761
|
-
}
|
|
762
|
-
|
|
763
|
-
function getNodeName(node) {
|
|
764
|
-
return isNode(node) ? (node.nodeName || '').toLowerCase() : '';
|
|
806
|
+
return (node == null ? void 0 : (_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;
|
|
765
807
|
}
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
if (uaString) {
|
|
770
|
-
return uaString;
|
|
771
|
-
}
|
|
772
|
-
const uaData = navigator.userAgentData;
|
|
773
|
-
if (uaData && Array.isArray(uaData.brands)) {
|
|
774
|
-
uaString = uaData.brands.map(item => item.brand + "/" + item.version).join(' ');
|
|
775
|
-
return uaString;
|
|
776
|
-
}
|
|
777
|
-
return navigator.userAgent;
|
|
808
|
+
function getDocumentElement(node) {
|
|
809
|
+
var _ref;
|
|
810
|
+
return (_ref = (isNode(node) ? node.ownerDocument : node.document) || window.document) == null ? void 0 : _ref.documentElement;
|
|
778
811
|
}
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
return value instanceof getWindow(value).HTMLElement;
|
|
812
|
+
function isNode(value) {
|
|
813
|
+
return value instanceof Node || value instanceof getWindow(value).Node;
|
|
782
814
|
}
|
|
783
815
|
function isElement(value) {
|
|
784
|
-
return value instanceof getWindow(value).Element;
|
|
816
|
+
return value instanceof Element || value instanceof getWindow(value).Element;
|
|
785
817
|
}
|
|
786
|
-
function
|
|
787
|
-
return value instanceof getWindow(value).
|
|
818
|
+
function isHTMLElement(value) {
|
|
819
|
+
return value instanceof HTMLElement || value instanceof getWindow(value).HTMLElement;
|
|
788
820
|
}
|
|
789
|
-
function isShadowRoot(
|
|
790
|
-
// Browsers without `ShadowRoot` support
|
|
821
|
+
function isShadowRoot(value) {
|
|
822
|
+
// Browsers without `ShadowRoot` support.
|
|
791
823
|
if (typeof ShadowRoot === 'undefined') {
|
|
792
824
|
return false;
|
|
793
825
|
}
|
|
794
|
-
|
|
795
|
-
return node instanceof OwnElement || node instanceof ShadowRoot;
|
|
826
|
+
return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;
|
|
796
827
|
}
|
|
797
828
|
function isOverflowElement(element) {
|
|
798
829
|
const {
|
|
@@ -800,52 +831,100 @@ function isOverflowElement(element) {
|
|
|
800
831
|
overflowX,
|
|
801
832
|
overflowY,
|
|
802
833
|
display
|
|
803
|
-
} = getComputedStyle
|
|
834
|
+
} = getComputedStyle(element);
|
|
804
835
|
return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && !['inline', 'contents'].includes(display);
|
|
805
836
|
}
|
|
806
837
|
function isTableElement(element) {
|
|
807
838
|
return ['table', 'td', 'th'].includes(getNodeName(element));
|
|
808
839
|
}
|
|
809
840
|
function isContainingBlock(element) {
|
|
810
|
-
|
|
811
|
-
const
|
|
812
|
-
const css = getComputedStyle$1(element);
|
|
813
|
-
const backdropFilter = css.backdropFilter || css.WebkitBackdropFilter;
|
|
841
|
+
const webkit = isWebKit();
|
|
842
|
+
const css = getComputedStyle(element);
|
|
814
843
|
|
|
815
|
-
// This is non-exhaustive but covers the most common CSS properties that
|
|
816
|
-
// create a containing block.
|
|
817
844
|
// https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
|
|
818
|
-
return css.transform !== 'none' || css.perspective !== 'none' || (
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
845
|
+
return css.transform !== 'none' || css.perspective !== 'none' || (css.containerType ? css.containerType !== 'normal' : false) || !webkit && (css.backdropFilter ? css.backdropFilter !== 'none' : false) || !webkit && (css.filter ? css.filter !== 'none' : false) || ['transform', 'perspective', 'filter'].some(value => (css.willChange || '').includes(value)) || ['paint', 'layout', 'strict', 'content'].some(value => (css.contain || '').includes(value));
|
|
846
|
+
}
|
|
847
|
+
function getContainingBlock(element) {
|
|
848
|
+
let currentNode = getParentNode(element);
|
|
849
|
+
while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {
|
|
850
|
+
if (isContainingBlock(currentNode)) {
|
|
851
|
+
return currentNode;
|
|
852
|
+
} else {
|
|
853
|
+
currentNode = getParentNode(currentNode);
|
|
854
|
+
}
|
|
855
|
+
}
|
|
856
|
+
return null;
|
|
824
857
|
}
|
|
825
|
-
function
|
|
826
|
-
|
|
827
|
-
return
|
|
828
|
-
// Feature detection for this fails in various ways
|
|
829
|
-
// • Always-visible scrollbar or not
|
|
830
|
-
// • Width of <html>, etc.
|
|
831
|
-
// const vV = win.visualViewport;
|
|
832
|
-
// return vV ? Math.abs(win.innerWidth / vV.scale - vV.width) < 0.5 : true;
|
|
858
|
+
function isWebKit() {
|
|
859
|
+
if (typeof CSS === 'undefined' || !CSS.supports) return false;
|
|
860
|
+
return CSS.supports('-webkit-backdrop-filter', 'none');
|
|
833
861
|
}
|
|
834
|
-
|
|
835
862
|
function isLastTraversableNode(node) {
|
|
836
863
|
return ['html', 'body', '#document'].includes(getNodeName(node));
|
|
837
864
|
}
|
|
838
|
-
|
|
839
|
-
|
|
840
|
-
|
|
841
|
-
|
|
865
|
+
function getComputedStyle(element) {
|
|
866
|
+
return getWindow(element).getComputedStyle(element);
|
|
867
|
+
}
|
|
868
|
+
function getNodeScroll(element) {
|
|
869
|
+
if (isElement(element)) {
|
|
870
|
+
return {
|
|
871
|
+
scrollLeft: element.scrollLeft,
|
|
872
|
+
scrollTop: element.scrollTop
|
|
873
|
+
};
|
|
874
|
+
}
|
|
875
|
+
return {
|
|
876
|
+
scrollLeft: element.pageXOffset,
|
|
877
|
+
scrollTop: element.pageYOffset
|
|
878
|
+
};
|
|
879
|
+
}
|
|
880
|
+
function getParentNode(node) {
|
|
881
|
+
if (getNodeName(node) === 'html') {
|
|
882
|
+
return node;
|
|
883
|
+
}
|
|
884
|
+
const result =
|
|
885
|
+
// Step into the shadow DOM of the parent of a slotted node.
|
|
886
|
+
node.assignedSlot ||
|
|
887
|
+
// DOM Element detected.
|
|
888
|
+
node.parentNode ||
|
|
889
|
+
// ShadowRoot detected.
|
|
890
|
+
isShadowRoot(node) && node.host ||
|
|
891
|
+
// Fallback.
|
|
892
|
+
getDocumentElement(node);
|
|
893
|
+
return isShadowRoot(result) ? result.host : result;
|
|
894
|
+
}
|
|
895
|
+
function getNearestOverflowAncestor(node) {
|
|
896
|
+
const parentNode = getParentNode(node);
|
|
897
|
+
if (isLastTraversableNode(parentNode)) {
|
|
898
|
+
return node.ownerDocument ? node.ownerDocument.body : node.body;
|
|
899
|
+
}
|
|
900
|
+
if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {
|
|
901
|
+
return parentNode;
|
|
902
|
+
}
|
|
903
|
+
return getNearestOverflowAncestor(parentNode);
|
|
904
|
+
}
|
|
905
|
+
function getOverflowAncestors(node, list) {
|
|
906
|
+
var _node$ownerDocument2;
|
|
907
|
+
if (list === void 0) {
|
|
908
|
+
list = [];
|
|
909
|
+
}
|
|
910
|
+
const scrollableAncestor = getNearestOverflowAncestor(node);
|
|
911
|
+
const isBody = scrollableAncestor === ((_node$ownerDocument2 = node.ownerDocument) == null ? void 0 : _node$ownerDocument2.body);
|
|
912
|
+
const win = getWindow(scrollableAncestor);
|
|
913
|
+
if (isBody) {
|
|
914
|
+
return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : []);
|
|
915
|
+
}
|
|
916
|
+
return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor));
|
|
917
|
+
}
|
|
842
918
|
|
|
843
919
|
function getCssDimensions(element) {
|
|
844
|
-
const css = getComputedStyle
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
920
|
+
const css = getComputedStyle(element);
|
|
921
|
+
// In testing environments, the `width` and `height` properties are empty
|
|
922
|
+
// strings for SVG elements, returning NaN. Fallback to `0` in this case.
|
|
923
|
+
let width = parseFloat(css.width) || 0;
|
|
924
|
+
let height = parseFloat(css.height) || 0;
|
|
925
|
+
const hasOffset = isHTMLElement(element);
|
|
926
|
+
const offsetWidth = hasOffset ? element.offsetWidth : width;
|
|
927
|
+
const offsetHeight = hasOffset ? element.offsetHeight : height;
|
|
849
928
|
const shouldFallback = round(width) !== offsetWidth || round(height) !== offsetHeight;
|
|
850
929
|
if (shouldFallback) {
|
|
851
930
|
width = offsetWidth;
|
|
@@ -854,7 +933,7 @@ function getCssDimensions(element) {
|
|
|
854
933
|
return {
|
|
855
934
|
width,
|
|
856
935
|
height,
|
|
857
|
-
|
|
936
|
+
$: shouldFallback
|
|
858
937
|
};
|
|
859
938
|
}
|
|
860
939
|
|
|
@@ -862,23 +941,19 @@ function unwrapElement(element) {
|
|
|
862
941
|
return !isElement(element) ? element.contextElement : element;
|
|
863
942
|
}
|
|
864
943
|
|
|
865
|
-
const FALLBACK_SCALE = {
|
|
866
|
-
x: 1,
|
|
867
|
-
y: 1
|
|
868
|
-
};
|
|
869
944
|
function getScale(element) {
|
|
870
945
|
const domElement = unwrapElement(element);
|
|
871
946
|
if (!isHTMLElement(domElement)) {
|
|
872
|
-
return
|
|
947
|
+
return createCoords(1);
|
|
873
948
|
}
|
|
874
949
|
const rect = domElement.getBoundingClientRect();
|
|
875
950
|
const {
|
|
876
951
|
width,
|
|
877
952
|
height,
|
|
878
|
-
|
|
953
|
+
$
|
|
879
954
|
} = getCssDimensions(domElement);
|
|
880
|
-
let x = (
|
|
881
|
-
let y = (
|
|
955
|
+
let x = ($ ? round(rect.width) : rect.width) / width;
|
|
956
|
+
let y = ($ ? round(rect.height) : rect.height) / height;
|
|
882
957
|
|
|
883
958
|
// 0, NaN, or Infinity should always fallback to 1.
|
|
884
959
|
|
|
@@ -894,8 +969,28 @@ function getScale(element) {
|
|
|
894
969
|
};
|
|
895
970
|
}
|
|
896
971
|
|
|
972
|
+
const noOffsets = /*#__PURE__*/createCoords(0);
|
|
973
|
+
function getVisualOffsets(element) {
|
|
974
|
+
const win = getWindow(element);
|
|
975
|
+
if (!isWebKit() || !win.visualViewport) {
|
|
976
|
+
return noOffsets;
|
|
977
|
+
}
|
|
978
|
+
return {
|
|
979
|
+
x: win.visualViewport.offsetLeft,
|
|
980
|
+
y: win.visualViewport.offsetTop
|
|
981
|
+
};
|
|
982
|
+
}
|
|
983
|
+
function shouldAddVisualOffsets(element, isFixed, floatingOffsetParent) {
|
|
984
|
+
if (isFixed === void 0) {
|
|
985
|
+
isFixed = false;
|
|
986
|
+
}
|
|
987
|
+
if (!floatingOffsetParent || isFixed && floatingOffsetParent !== getWindow(element)) {
|
|
988
|
+
return false;
|
|
989
|
+
}
|
|
990
|
+
return isFixed;
|
|
991
|
+
}
|
|
992
|
+
|
|
897
993
|
function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetParent) {
|
|
898
|
-
var _win$visualViewport, _win$visualViewport2;
|
|
899
994
|
if (includeScale === void 0) {
|
|
900
995
|
includeScale = false;
|
|
901
996
|
}
|
|
@@ -904,7 +999,7 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
904
999
|
}
|
|
905
1000
|
const clientRect = element.getBoundingClientRect();
|
|
906
1001
|
const domElement = unwrapElement(element);
|
|
907
|
-
let scale =
|
|
1002
|
+
let scale = createCoords(1);
|
|
908
1003
|
if (includeScale) {
|
|
909
1004
|
if (offsetParent) {
|
|
910
1005
|
if (isElement(offsetParent)) {
|
|
@@ -914,10 +1009,9 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
914
1009
|
scale = getScale(element);
|
|
915
1010
|
}
|
|
916
1011
|
}
|
|
917
|
-
const
|
|
918
|
-
|
|
919
|
-
let
|
|
920
|
-
let y = (clientRect.top + (addVisualOffsets ? ((_win$visualViewport2 = win.visualViewport) == null ? void 0 : _win$visualViewport2.offsetTop) || 0 : 0)) / scale.y;
|
|
1012
|
+
const visualOffsets = shouldAddVisualOffsets(domElement, isFixedStrategy, offsetParent) ? getVisualOffsets(domElement) : createCoords(0);
|
|
1013
|
+
let x = (clientRect.left + visualOffsets.x) / scale.x;
|
|
1014
|
+
let y = (clientRect.top + visualOffsets.y) / scale.y;
|
|
921
1015
|
let width = clientRect.width / scale.x;
|
|
922
1016
|
let height = clientRect.height / scale.y;
|
|
923
1017
|
if (domElement) {
|
|
@@ -928,134 +1022,23 @@ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetPar
|
|
|
928
1022
|
const iframeScale = getScale(currentIFrame);
|
|
929
1023
|
const iframeRect = currentIFrame.getBoundingClientRect();
|
|
930
1024
|
const css = getComputedStyle(currentIFrame);
|
|
931
|
-
iframeRect.
|
|
932
|
-
iframeRect.
|
|
1025
|
+
const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css.paddingLeft)) * iframeScale.x;
|
|
1026
|
+
const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(css.paddingTop)) * iframeScale.y;
|
|
933
1027
|
x *= iframeScale.x;
|
|
934
1028
|
y *= iframeScale.y;
|
|
935
1029
|
width *= iframeScale.x;
|
|
936
1030
|
height *= iframeScale.y;
|
|
937
|
-
x +=
|
|
938
|
-
y +=
|
|
1031
|
+
x += left;
|
|
1032
|
+
y += top;
|
|
939
1033
|
currentIFrame = getWindow(currentIFrame).frameElement;
|
|
940
1034
|
}
|
|
941
1035
|
}
|
|
942
|
-
return {
|
|
1036
|
+
return rectToClientRect({
|
|
943
1037
|
width,
|
|
944
1038
|
height,
|
|
945
|
-
top: y,
|
|
946
|
-
right: x + width,
|
|
947
|
-
bottom: y + height,
|
|
948
|
-
left: x,
|
|
949
1039
|
x,
|
|
950
1040
|
y
|
|
951
|
-
};
|
|
952
|
-
}
|
|
953
|
-
|
|
954
|
-
function getDocumentElement(node) {
|
|
955
|
-
return ((isNode(node) ? node.ownerDocument : node.document) || window.document).documentElement;
|
|
956
|
-
}
|
|
957
|
-
|
|
958
|
-
function getNodeScroll(element) {
|
|
959
|
-
if (isElement(element)) {
|
|
960
|
-
return {
|
|
961
|
-
scrollLeft: element.scrollLeft,
|
|
962
|
-
scrollTop: element.scrollTop
|
|
963
|
-
};
|
|
964
|
-
}
|
|
965
|
-
return {
|
|
966
|
-
scrollLeft: element.pageXOffset,
|
|
967
|
-
scrollTop: element.pageYOffset
|
|
968
|
-
};
|
|
969
|
-
}
|
|
970
|
-
|
|
971
|
-
function getWindowScrollBarX(element) {
|
|
972
|
-
// If <html> has a CSS width greater than the viewport, then this will be
|
|
973
|
-
// incorrect for RTL.
|
|
974
|
-
return getBoundingClientRect(getDocumentElement(element)).left + getNodeScroll(element).scrollLeft;
|
|
975
|
-
}
|
|
976
|
-
|
|
977
|
-
function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
|
|
978
|
-
const isOffsetParentAnElement = isHTMLElement(offsetParent);
|
|
979
|
-
const documentElement = getDocumentElement(offsetParent);
|
|
980
|
-
const rect = getBoundingClientRect(element, true, strategy === 'fixed', offsetParent);
|
|
981
|
-
let scroll = {
|
|
982
|
-
scrollLeft: 0,
|
|
983
|
-
scrollTop: 0
|
|
984
|
-
};
|
|
985
|
-
const offsets = {
|
|
986
|
-
x: 0,
|
|
987
|
-
y: 0
|
|
988
|
-
};
|
|
989
|
-
if (isOffsetParentAnElement || !isOffsetParentAnElement && strategy !== 'fixed') {
|
|
990
|
-
if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {
|
|
991
|
-
scroll = getNodeScroll(offsetParent);
|
|
992
|
-
}
|
|
993
|
-
if (isHTMLElement(offsetParent)) {
|
|
994
|
-
const offsetRect = getBoundingClientRect(offsetParent, true);
|
|
995
|
-
offsets.x = offsetRect.x + offsetParent.clientLeft;
|
|
996
|
-
offsets.y = offsetRect.y + offsetParent.clientTop;
|
|
997
|
-
} else if (documentElement) {
|
|
998
|
-
offsets.x = getWindowScrollBarX(documentElement);
|
|
999
|
-
}
|
|
1000
|
-
}
|
|
1001
|
-
return {
|
|
1002
|
-
x: rect.left + scroll.scrollLeft - offsets.x,
|
|
1003
|
-
y: rect.top + scroll.scrollTop - offsets.y,
|
|
1004
|
-
width: rect.width,
|
|
1005
|
-
height: rect.height
|
|
1006
|
-
};
|
|
1007
|
-
}
|
|
1008
|
-
|
|
1009
|
-
function getParentNode(node) {
|
|
1010
|
-
if (getNodeName(node) === 'html') {
|
|
1011
|
-
return node;
|
|
1012
|
-
}
|
|
1013
|
-
const result =
|
|
1014
|
-
// Step into the shadow DOM of the parent of a slotted node
|
|
1015
|
-
node.assignedSlot ||
|
|
1016
|
-
// DOM Element detected
|
|
1017
|
-
node.parentNode || (
|
|
1018
|
-
// ShadowRoot detected
|
|
1019
|
-
isShadowRoot(node) ? node.host : null) ||
|
|
1020
|
-
// Fallback
|
|
1021
|
-
getDocumentElement(node);
|
|
1022
|
-
return isShadowRoot(result) ? result.host : result;
|
|
1023
|
-
}
|
|
1024
|
-
|
|
1025
|
-
function getTrueOffsetParent(element) {
|
|
1026
|
-
if (!isHTMLElement(element) || getComputedStyle$1(element).position === 'fixed') {
|
|
1027
|
-
return null;
|
|
1028
|
-
}
|
|
1029
|
-
return element.offsetParent;
|
|
1030
|
-
}
|
|
1031
|
-
function getContainingBlock(element) {
|
|
1032
|
-
let currentNode = getParentNode(element);
|
|
1033
|
-
while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {
|
|
1034
|
-
if (isContainingBlock(currentNode)) {
|
|
1035
|
-
return currentNode;
|
|
1036
|
-
} else {
|
|
1037
|
-
currentNode = getParentNode(currentNode);
|
|
1038
|
-
}
|
|
1039
|
-
}
|
|
1040
|
-
return null;
|
|
1041
|
-
}
|
|
1042
|
-
|
|
1043
|
-
// Gets the closest ancestor positioned element. Handles some edge cases,
|
|
1044
|
-
// such as table ancestors and cross browser bugs.
|
|
1045
|
-
function getOffsetParent(element) {
|
|
1046
|
-
const window = getWindow(element);
|
|
1047
|
-
let offsetParent = getTrueOffsetParent(element);
|
|
1048
|
-
while (offsetParent && isTableElement(offsetParent) && getComputedStyle$1(offsetParent).position === 'static') {
|
|
1049
|
-
offsetParent = getTrueOffsetParent(offsetParent);
|
|
1050
|
-
}
|
|
1051
|
-
if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle$1(offsetParent).position === 'static' && !isContainingBlock(offsetParent))) {
|
|
1052
|
-
return window;
|
|
1053
|
-
}
|
|
1054
|
-
return offsetParent || getContainingBlock(element) || window;
|
|
1055
|
-
}
|
|
1056
|
-
|
|
1057
|
-
function getDimensions(element) {
|
|
1058
|
-
return getCssDimensions(element);
|
|
1041
|
+
});
|
|
1059
1042
|
}
|
|
1060
1043
|
|
|
1061
1044
|
function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
|
|
@@ -1073,14 +1056,8 @@ function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
|
|
|
1073
1056
|
scrollLeft: 0,
|
|
1074
1057
|
scrollTop: 0
|
|
1075
1058
|
};
|
|
1076
|
-
let scale =
|
|
1077
|
-
|
|
1078
|
-
y: 1
|
|
1079
|
-
};
|
|
1080
|
-
const offsets = {
|
|
1081
|
-
x: 0,
|
|
1082
|
-
y: 0
|
|
1083
|
-
};
|
|
1059
|
+
let scale = createCoords(1);
|
|
1060
|
+
const offsets = createCoords(0);
|
|
1084
1061
|
if (isOffsetParentAnElement || !isOffsetParentAnElement && strategy !== 'fixed') {
|
|
1085
1062
|
if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {
|
|
1086
1063
|
scroll = getNodeScroll(offsetParent);
|
|
@@ -1091,12 +1068,7 @@ function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
|
|
|
1091
1068
|
offsets.x = offsetRect.x + offsetParent.clientLeft;
|
|
1092
1069
|
offsets.y = offsetRect.y + offsetParent.clientTop;
|
|
1093
1070
|
}
|
|
1094
|
-
// This doesn't appear to need to be negated.
|
|
1095
|
-
// else if (documentElement) {
|
|
1096
|
-
// offsets.x = getWindowScrollBarX(documentElement);
|
|
1097
|
-
// }
|
|
1098
1071
|
}
|
|
1099
|
-
|
|
1100
1072
|
return {
|
|
1101
1073
|
width: rect.width * scale.x,
|
|
1102
1074
|
height: rect.height * scale.y,
|
|
@@ -1105,6 +1077,37 @@ function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
|
|
|
1105
1077
|
};
|
|
1106
1078
|
}
|
|
1107
1079
|
|
|
1080
|
+
function getClientRects(element) {
|
|
1081
|
+
return Array.from(element.getClientRects());
|
|
1082
|
+
}
|
|
1083
|
+
|
|
1084
|
+
function getWindowScrollBarX(element) {
|
|
1085
|
+
// If <html> has a CSS width greater than the viewport, then this will be
|
|
1086
|
+
// incorrect for RTL.
|
|
1087
|
+
return getBoundingClientRect(getDocumentElement(element)).left + getNodeScroll(element).scrollLeft;
|
|
1088
|
+
}
|
|
1089
|
+
|
|
1090
|
+
// Gets the entire size of the scrollable document area, even extending outside
|
|
1091
|
+
// of the `<html>` and `<body>` rect bounds if horizontally scrollable.
|
|
1092
|
+
function getDocumentRect(element) {
|
|
1093
|
+
const html = getDocumentElement(element);
|
|
1094
|
+
const scroll = getNodeScroll(element);
|
|
1095
|
+
const body = element.ownerDocument.body;
|
|
1096
|
+
const width = max(html.scrollWidth, html.clientWidth, body.scrollWidth, body.clientWidth);
|
|
1097
|
+
const height = max(html.scrollHeight, html.clientHeight, body.scrollHeight, body.clientHeight);
|
|
1098
|
+
let x = -scroll.scrollLeft + getWindowScrollBarX(element);
|
|
1099
|
+
const y = -scroll.scrollTop;
|
|
1100
|
+
if (getComputedStyle(body).direction === 'rtl') {
|
|
1101
|
+
x += max(html.clientWidth, body.clientWidth) - width;
|
|
1102
|
+
}
|
|
1103
|
+
return {
|
|
1104
|
+
width,
|
|
1105
|
+
height,
|
|
1106
|
+
x,
|
|
1107
|
+
y
|
|
1108
|
+
};
|
|
1109
|
+
}
|
|
1110
|
+
|
|
1108
1111
|
function getViewportRect(element, strategy) {
|
|
1109
1112
|
const win = getWindow(element);
|
|
1110
1113
|
const html = getDocumentElement(element);
|
|
@@ -1116,8 +1119,8 @@ function getViewportRect(element, strategy) {
|
|
|
1116
1119
|
if (visualViewport) {
|
|
1117
1120
|
width = visualViewport.width;
|
|
1118
1121
|
height = visualViewport.height;
|
|
1119
|
-
const
|
|
1120
|
-
if (
|
|
1122
|
+
const visualViewportBased = isWebKit();
|
|
1123
|
+
if (!visualViewportBased || visualViewportBased && strategy === 'fixed') {
|
|
1121
1124
|
x = visualViewport.offsetLeft;
|
|
1122
1125
|
y = visualViewport.offsetTop;
|
|
1123
1126
|
}
|
|
@@ -1130,86 +1133,47 @@ function getViewportRect(element, strategy) {
|
|
|
1130
1133
|
};
|
|
1131
1134
|
}
|
|
1132
1135
|
|
|
1133
|
-
//
|
|
1134
|
-
// of the `<html>` and `<body>` rect bounds if horizontally scrollable
|
|
1135
|
-
function getDocumentRect(element) {
|
|
1136
|
-
var _element$ownerDocumen;
|
|
1137
|
-
const html = getDocumentElement(element);
|
|
1138
|
-
const scroll = getNodeScroll(element);
|
|
1139
|
-
const body = (_element$ownerDocumen = element.ownerDocument) == null ? void 0 : _element$ownerDocumen.body;
|
|
1140
|
-
const width = max(html.scrollWidth, html.clientWidth, body ? body.scrollWidth : 0, body ? body.clientWidth : 0);
|
|
1141
|
-
const height = max(html.scrollHeight, html.clientHeight, body ? body.scrollHeight : 0, body ? body.clientHeight : 0);
|
|
1142
|
-
let x = -scroll.scrollLeft + getWindowScrollBarX(element);
|
|
1143
|
-
const y = -scroll.scrollTop;
|
|
1144
|
-
if (getComputedStyle$1(body || html).direction === 'rtl') {
|
|
1145
|
-
x += max(html.clientWidth, body ? body.clientWidth : 0) - width;
|
|
1146
|
-
}
|
|
1147
|
-
return {
|
|
1148
|
-
width,
|
|
1149
|
-
height,
|
|
1150
|
-
x,
|
|
1151
|
-
y
|
|
1152
|
-
};
|
|
1153
|
-
}
|
|
1154
|
-
|
|
1155
|
-
function getNearestOverflowAncestor(node) {
|
|
1156
|
-
const parentNode = getParentNode(node);
|
|
1157
|
-
if (isLastTraversableNode(parentNode)) {
|
|
1158
|
-
// @ts-ignore assume body is always available
|
|
1159
|
-
return node.ownerDocument.body;
|
|
1160
|
-
}
|
|
1161
|
-
if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {
|
|
1162
|
-
return parentNode;
|
|
1163
|
-
}
|
|
1164
|
-
return getNearestOverflowAncestor(parentNode);
|
|
1165
|
-
}
|
|
1166
|
-
|
|
1167
|
-
function getOverflowAncestors(node, list) {
|
|
1168
|
-
var _node$ownerDocument;
|
|
1169
|
-
if (list === void 0) {
|
|
1170
|
-
list = [];
|
|
1171
|
-
}
|
|
1172
|
-
const scrollableAncestor = getNearestOverflowAncestor(node);
|
|
1173
|
-
const isBody = scrollableAncestor === ((_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.body);
|
|
1174
|
-
const win = getWindow(scrollableAncestor);
|
|
1175
|
-
if (isBody) {
|
|
1176
|
-
return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : []);
|
|
1177
|
-
}
|
|
1178
|
-
return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor));
|
|
1179
|
-
}
|
|
1180
|
-
|
|
1181
|
-
// Returns the inner client rect, subtracting scrollbars if present
|
|
1136
|
+
// Returns the inner client rect, subtracting scrollbars if present.
|
|
1182
1137
|
function getInnerBoundingClientRect(element, strategy) {
|
|
1183
1138
|
const clientRect = getBoundingClientRect(element, true, strategy === 'fixed');
|
|
1184
1139
|
const top = clientRect.top + element.clientTop;
|
|
1185
1140
|
const left = clientRect.left + element.clientLeft;
|
|
1186
|
-
const scale = isHTMLElement(element) ? getScale(element) :
|
|
1187
|
-
x: 1,
|
|
1188
|
-
y: 1
|
|
1189
|
-
};
|
|
1141
|
+
const scale = isHTMLElement(element) ? getScale(element) : createCoords(1);
|
|
1190
1142
|
const width = element.clientWidth * scale.x;
|
|
1191
1143
|
const height = element.clientHeight * scale.y;
|
|
1192
1144
|
const x = left * scale.x;
|
|
1193
1145
|
const y = top * scale.y;
|
|
1194
1146
|
return {
|
|
1195
|
-
top: y,
|
|
1196
|
-
left: x,
|
|
1197
|
-
right: x + width,
|
|
1198
|
-
bottom: y + height,
|
|
1199
|
-
x,
|
|
1200
|
-
y,
|
|
1201
1147
|
width,
|
|
1202
|
-
height
|
|
1148
|
+
height,
|
|
1149
|
+
x,
|
|
1150
|
+
y
|
|
1203
1151
|
};
|
|
1204
1152
|
}
|
|
1205
1153
|
function getClientRectFromClippingAncestor(element, clippingAncestor, strategy) {
|
|
1154
|
+
let rect;
|
|
1206
1155
|
if (clippingAncestor === 'viewport') {
|
|
1207
|
-
|
|
1156
|
+
rect = getViewportRect(element, strategy);
|
|
1157
|
+
} else if (clippingAncestor === 'document') {
|
|
1158
|
+
rect = getDocumentRect(getDocumentElement(element));
|
|
1159
|
+
} else if (isElement(clippingAncestor)) {
|
|
1160
|
+
rect = getInnerBoundingClientRect(clippingAncestor, strategy);
|
|
1161
|
+
} else {
|
|
1162
|
+
const visualOffsets = getVisualOffsets(element);
|
|
1163
|
+
rect = {
|
|
1164
|
+
...clippingAncestor,
|
|
1165
|
+
x: clippingAncestor.x - visualOffsets.x,
|
|
1166
|
+
y: clippingAncestor.y - visualOffsets.y
|
|
1167
|
+
};
|
|
1208
1168
|
}
|
|
1209
|
-
|
|
1210
|
-
|
|
1169
|
+
return rectToClientRect(rect);
|
|
1170
|
+
}
|
|
1171
|
+
function hasFixedPositionAncestor(element, stopNode) {
|
|
1172
|
+
const parentNode = getParentNode(element);
|
|
1173
|
+
if (parentNode === stopNode || !isElement(parentNode) || isLastTraversableNode(parentNode)) {
|
|
1174
|
+
return false;
|
|
1211
1175
|
}
|
|
1212
|
-
return
|
|
1176
|
+
return getComputedStyle(parentNode).position === 'fixed' || hasFixedPositionAncestor(parentNode, stopNode);
|
|
1213
1177
|
}
|
|
1214
1178
|
|
|
1215
1179
|
// A "clipping ancestor" is an `overflow` element with the characteristic of
|
|
@@ -1222,19 +1186,22 @@ function getClippingElementAncestors(element, cache) {
|
|
|
1222
1186
|
}
|
|
1223
1187
|
let result = getOverflowAncestors(element).filter(el => isElement(el) && getNodeName(el) !== 'body');
|
|
1224
1188
|
let currentContainingBlockComputedStyle = null;
|
|
1225
|
-
const elementIsFixed = getComputedStyle
|
|
1189
|
+
const elementIsFixed = getComputedStyle(element).position === 'fixed';
|
|
1226
1190
|
let currentNode = elementIsFixed ? getParentNode(element) : element;
|
|
1227
1191
|
|
|
1228
1192
|
// https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
|
|
1229
1193
|
while (isElement(currentNode) && !isLastTraversableNode(currentNode)) {
|
|
1230
|
-
const computedStyle = getComputedStyle
|
|
1231
|
-
const
|
|
1232
|
-
|
|
1194
|
+
const computedStyle = getComputedStyle(currentNode);
|
|
1195
|
+
const currentNodeIsContaining = isContainingBlock(currentNode);
|
|
1196
|
+
if (!currentNodeIsContaining && computedStyle.position === 'fixed') {
|
|
1197
|
+
currentContainingBlockComputedStyle = null;
|
|
1198
|
+
}
|
|
1199
|
+
const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === 'static' && !!currentContainingBlockComputedStyle && ['absolute', 'fixed'].includes(currentContainingBlockComputedStyle.position) || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);
|
|
1233
1200
|
if (shouldDropCurrentNode) {
|
|
1234
|
-
// Drop non-containing blocks
|
|
1201
|
+
// Drop non-containing blocks.
|
|
1235
1202
|
result = result.filter(ancestor => ancestor !== currentNode);
|
|
1236
1203
|
} else {
|
|
1237
|
-
// Record last containing block for next iteration
|
|
1204
|
+
// Record last containing block for next iteration.
|
|
1238
1205
|
currentContainingBlockComputedStyle = computedStyle;
|
|
1239
1206
|
}
|
|
1240
1207
|
currentNode = getParentNode(currentNode);
|
|
@@ -1244,7 +1211,7 @@ function getClippingElementAncestors(element, cache) {
|
|
|
1244
1211
|
}
|
|
1245
1212
|
|
|
1246
1213
|
// Gets the maximum area that the element is visible in due to any number of
|
|
1247
|
-
// clipping ancestors
|
|
1214
|
+
// clipping ancestors.
|
|
1248
1215
|
function getClippingRect(_ref) {
|
|
1249
1216
|
let {
|
|
1250
1217
|
element,
|
|
@@ -1271,37 +1238,182 @@ function getClippingRect(_ref) {
|
|
|
1271
1238
|
};
|
|
1272
1239
|
}
|
|
1273
1240
|
|
|
1241
|
+
function getDimensions(element) {
|
|
1242
|
+
return getCssDimensions(element);
|
|
1243
|
+
}
|
|
1244
|
+
|
|
1245
|
+
function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
|
|
1246
|
+
const isOffsetParentAnElement = isHTMLElement(offsetParent);
|
|
1247
|
+
const documentElement = getDocumentElement(offsetParent);
|
|
1248
|
+
const isFixed = strategy === 'fixed';
|
|
1249
|
+
const rect = getBoundingClientRect(element, true, isFixed, offsetParent);
|
|
1250
|
+
let scroll = {
|
|
1251
|
+
scrollLeft: 0,
|
|
1252
|
+
scrollTop: 0
|
|
1253
|
+
};
|
|
1254
|
+
const offsets = createCoords(0);
|
|
1255
|
+
if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
|
|
1256
|
+
if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {
|
|
1257
|
+
scroll = getNodeScroll(offsetParent);
|
|
1258
|
+
}
|
|
1259
|
+
if (isOffsetParentAnElement) {
|
|
1260
|
+
const offsetRect = getBoundingClientRect(offsetParent, true, isFixed, offsetParent);
|
|
1261
|
+
offsets.x = offsetRect.x + offsetParent.clientLeft;
|
|
1262
|
+
offsets.y = offsetRect.y + offsetParent.clientTop;
|
|
1263
|
+
} else if (documentElement) {
|
|
1264
|
+
offsets.x = getWindowScrollBarX(documentElement);
|
|
1265
|
+
}
|
|
1266
|
+
}
|
|
1267
|
+
return {
|
|
1268
|
+
x: rect.left + scroll.scrollLeft - offsets.x,
|
|
1269
|
+
y: rect.top + scroll.scrollTop - offsets.y,
|
|
1270
|
+
width: rect.width,
|
|
1271
|
+
height: rect.height
|
|
1272
|
+
};
|
|
1273
|
+
}
|
|
1274
|
+
|
|
1275
|
+
function getTrueOffsetParent(element, polyfill) {
|
|
1276
|
+
if (!isHTMLElement(element) || getComputedStyle(element).position === 'fixed') {
|
|
1277
|
+
return null;
|
|
1278
|
+
}
|
|
1279
|
+
if (polyfill) {
|
|
1280
|
+
return polyfill(element);
|
|
1281
|
+
}
|
|
1282
|
+
return element.offsetParent;
|
|
1283
|
+
}
|
|
1284
|
+
|
|
1285
|
+
// Gets the closest ancestor positioned element. Handles some edge cases,
|
|
1286
|
+
// such as table ancestors and cross browser bugs.
|
|
1287
|
+
function getOffsetParent(element, polyfill) {
|
|
1288
|
+
const window = getWindow(element);
|
|
1289
|
+
if (!isHTMLElement(element)) {
|
|
1290
|
+
return window;
|
|
1291
|
+
}
|
|
1292
|
+
let offsetParent = getTrueOffsetParent(element, polyfill);
|
|
1293
|
+
while (offsetParent && isTableElement(offsetParent) && getComputedStyle(offsetParent).position === 'static') {
|
|
1294
|
+
offsetParent = getTrueOffsetParent(offsetParent, polyfill);
|
|
1295
|
+
}
|
|
1296
|
+
if (offsetParent && (getNodeName(offsetParent) === 'html' || getNodeName(offsetParent) === 'body' && getComputedStyle(offsetParent).position === 'static' && !isContainingBlock(offsetParent))) {
|
|
1297
|
+
return window;
|
|
1298
|
+
}
|
|
1299
|
+
return offsetParent || getContainingBlock(element) || window;
|
|
1300
|
+
}
|
|
1301
|
+
|
|
1302
|
+
const getElementRects = async function (_ref) {
|
|
1303
|
+
let {
|
|
1304
|
+
reference,
|
|
1305
|
+
floating,
|
|
1306
|
+
strategy
|
|
1307
|
+
} = _ref;
|
|
1308
|
+
const getOffsetParentFn = this.getOffsetParent || getOffsetParent;
|
|
1309
|
+
const getDimensionsFn = this.getDimensions;
|
|
1310
|
+
return {
|
|
1311
|
+
reference: getRectRelativeToOffsetParent(reference, await getOffsetParentFn(floating), strategy),
|
|
1312
|
+
floating: {
|
|
1313
|
+
x: 0,
|
|
1314
|
+
y: 0,
|
|
1315
|
+
...(await getDimensionsFn(floating))
|
|
1316
|
+
}
|
|
1317
|
+
};
|
|
1318
|
+
};
|
|
1319
|
+
|
|
1320
|
+
function isRTL(element) {
|
|
1321
|
+
return getComputedStyle(element).direction === 'rtl';
|
|
1322
|
+
}
|
|
1323
|
+
|
|
1274
1324
|
const platform = {
|
|
1275
|
-
getClippingRect,
|
|
1276
1325
|
convertOffsetParentRelativeRectToViewportRelativeRect,
|
|
1277
|
-
isElement,
|
|
1278
|
-
getDimensions,
|
|
1279
|
-
getOffsetParent,
|
|
1280
1326
|
getDocumentElement,
|
|
1327
|
+
getClippingRect,
|
|
1328
|
+
getOffsetParent,
|
|
1329
|
+
getElementRects,
|
|
1330
|
+
getClientRects,
|
|
1331
|
+
getDimensions,
|
|
1281
1332
|
getScale,
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
reference,
|
|
1285
|
-
floating,
|
|
1286
|
-
strategy
|
|
1287
|
-
} = _ref;
|
|
1288
|
-
const getOffsetParentFn = this.getOffsetParent || getOffsetParent;
|
|
1289
|
-
const getDimensionsFn = this.getDimensions;
|
|
1290
|
-
return {
|
|
1291
|
-
reference: getRectRelativeToOffsetParent(reference, await getOffsetParentFn(floating), strategy),
|
|
1292
|
-
floating: {
|
|
1293
|
-
x: 0,
|
|
1294
|
-
y: 0,
|
|
1295
|
-
...(await getDimensionsFn(floating))
|
|
1296
|
-
}
|
|
1297
|
-
};
|
|
1298
|
-
},
|
|
1299
|
-
getClientRects: element => Array.from(element.getClientRects()),
|
|
1300
|
-
isRTL: element => getComputedStyle$1(element).direction === 'rtl'
|
|
1333
|
+
isElement,
|
|
1334
|
+
isRTL
|
|
1301
1335
|
};
|
|
1302
1336
|
|
|
1337
|
+
// https://samthor.au/2021/observing-dom/
|
|
1338
|
+
function observeMove(element, onMove) {
|
|
1339
|
+
let io = null;
|
|
1340
|
+
let timeoutId;
|
|
1341
|
+
const root = getDocumentElement(element);
|
|
1342
|
+
function cleanup() {
|
|
1343
|
+
clearTimeout(timeoutId);
|
|
1344
|
+
io && io.disconnect();
|
|
1345
|
+
io = null;
|
|
1346
|
+
}
|
|
1347
|
+
function refresh(skip, threshold) {
|
|
1348
|
+
if (skip === void 0) {
|
|
1349
|
+
skip = false;
|
|
1350
|
+
}
|
|
1351
|
+
if (threshold === void 0) {
|
|
1352
|
+
threshold = 1;
|
|
1353
|
+
}
|
|
1354
|
+
cleanup();
|
|
1355
|
+
const {
|
|
1356
|
+
left,
|
|
1357
|
+
top,
|
|
1358
|
+
width,
|
|
1359
|
+
height
|
|
1360
|
+
} = element.getBoundingClientRect();
|
|
1361
|
+
if (!skip) {
|
|
1362
|
+
onMove();
|
|
1363
|
+
}
|
|
1364
|
+
if (!width || !height) {
|
|
1365
|
+
return;
|
|
1366
|
+
}
|
|
1367
|
+
const insetTop = floor(top);
|
|
1368
|
+
const insetRight = floor(root.clientWidth - (left + width));
|
|
1369
|
+
const insetBottom = floor(root.clientHeight - (top + height));
|
|
1370
|
+
const insetLeft = floor(left);
|
|
1371
|
+
const rootMargin = -insetTop + "px " + -insetRight + "px " + -insetBottom + "px " + -insetLeft + "px";
|
|
1372
|
+
const options = {
|
|
1373
|
+
rootMargin,
|
|
1374
|
+
threshold: max(0, min(1, threshold)) || 1
|
|
1375
|
+
};
|
|
1376
|
+
let isFirstUpdate = true;
|
|
1377
|
+
function handleObserve(entries) {
|
|
1378
|
+
const ratio = entries[0].intersectionRatio;
|
|
1379
|
+
if (ratio !== threshold) {
|
|
1380
|
+
if (!isFirstUpdate) {
|
|
1381
|
+
return refresh();
|
|
1382
|
+
}
|
|
1383
|
+
if (!ratio) {
|
|
1384
|
+
timeoutId = setTimeout(() => {
|
|
1385
|
+
refresh(false, 1e-7);
|
|
1386
|
+
}, 100);
|
|
1387
|
+
} else {
|
|
1388
|
+
refresh(false, ratio);
|
|
1389
|
+
}
|
|
1390
|
+
}
|
|
1391
|
+
isFirstUpdate = false;
|
|
1392
|
+
}
|
|
1393
|
+
|
|
1394
|
+
// Older browsers don't support a `document` as the root and will throw an
|
|
1395
|
+
// error.
|
|
1396
|
+
try {
|
|
1397
|
+
io = new IntersectionObserver(handleObserve, {
|
|
1398
|
+
...options,
|
|
1399
|
+
// Handle <iframe>s
|
|
1400
|
+
root: root.ownerDocument
|
|
1401
|
+
});
|
|
1402
|
+
} catch (e) {
|
|
1403
|
+
io = new IntersectionObserver(handleObserve, options);
|
|
1404
|
+
}
|
|
1405
|
+
io.observe(element);
|
|
1406
|
+
}
|
|
1407
|
+
refresh(true);
|
|
1408
|
+
return cleanup;
|
|
1409
|
+
}
|
|
1410
|
+
|
|
1303
1411
|
/**
|
|
1304
1412
|
* Automatically updates the position of the floating element when necessary.
|
|
1413
|
+
* Should only be called when the floating element is mounted on the DOM or
|
|
1414
|
+
* visible on the screen.
|
|
1415
|
+
* @returns cleanup function that should be invoked when the floating element is
|
|
1416
|
+
* removed from the DOM or hidden from the screen.
|
|
1305
1417
|
* @see https://floating-ui.com/docs/autoUpdate
|
|
1306
1418
|
*/
|
|
1307
1419
|
function autoUpdate(reference, floating, update, options) {
|
|
@@ -1309,33 +1421,41 @@ function autoUpdate(reference, floating, update, options) {
|
|
|
1309
1421
|
options = {};
|
|
1310
1422
|
}
|
|
1311
1423
|
const {
|
|
1312
|
-
ancestorScroll
|
|
1424
|
+
ancestorScroll = true,
|
|
1313
1425
|
ancestorResize = true,
|
|
1314
|
-
elementResize =
|
|
1426
|
+
elementResize = typeof ResizeObserver === 'function',
|
|
1427
|
+
layoutShift = typeof IntersectionObserver === 'function',
|
|
1315
1428
|
animationFrame = false
|
|
1316
1429
|
} = options;
|
|
1317
|
-
const
|
|
1318
|
-
const ancestors = ancestorScroll || ancestorResize ? [...(
|
|
1430
|
+
const referenceEl = unwrapElement(reference);
|
|
1431
|
+
const ancestors = ancestorScroll || ancestorResize ? [...(referenceEl ? getOverflowAncestors(referenceEl) : []), ...getOverflowAncestors(floating)] : [];
|
|
1319
1432
|
ancestors.forEach(ancestor => {
|
|
1320
1433
|
ancestorScroll && ancestor.addEventListener('scroll', update, {
|
|
1321
1434
|
passive: true
|
|
1322
1435
|
});
|
|
1323
1436
|
ancestorResize && ancestor.addEventListener('resize', update);
|
|
1324
1437
|
});
|
|
1325
|
-
|
|
1438
|
+
const cleanupIo = referenceEl && layoutShift ? observeMove(referenceEl, update) : null;
|
|
1439
|
+
let reobserveFrame = -1;
|
|
1440
|
+
let resizeObserver = null;
|
|
1326
1441
|
if (elementResize) {
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
if (
|
|
1330
|
-
update
|
|
1442
|
+
resizeObserver = new ResizeObserver(_ref => {
|
|
1443
|
+
let [firstEntry] = _ref;
|
|
1444
|
+
if (firstEntry && firstEntry.target === referenceEl && resizeObserver) {
|
|
1445
|
+
// Prevent update loops when using the `size` middleware.
|
|
1446
|
+
// https://github.com/floating-ui/floating-ui/issues/1740
|
|
1447
|
+
resizeObserver.unobserve(floating);
|
|
1448
|
+
cancelAnimationFrame(reobserveFrame);
|
|
1449
|
+
reobserveFrame = requestAnimationFrame(() => {
|
|
1450
|
+
resizeObserver && resizeObserver.observe(floating);
|
|
1451
|
+
});
|
|
1331
1452
|
}
|
|
1332
|
-
|
|
1453
|
+
update();
|
|
1333
1454
|
});
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
observer.observe(reference.contextElement);
|
|
1455
|
+
if (referenceEl && !animationFrame) {
|
|
1456
|
+
resizeObserver.observe(referenceEl);
|
|
1337
1457
|
}
|
|
1338
|
-
|
|
1458
|
+
resizeObserver.observe(floating);
|
|
1339
1459
|
}
|
|
1340
1460
|
let frameId;
|
|
1341
1461
|
let prevRefRect = animationFrame ? getBoundingClientRect(reference) : null;
|
|
@@ -1352,13 +1472,13 @@ function autoUpdate(reference, floating, update, options) {
|
|
|
1352
1472
|
}
|
|
1353
1473
|
update();
|
|
1354
1474
|
return () => {
|
|
1355
|
-
var _observer;
|
|
1356
1475
|
ancestors.forEach(ancestor => {
|
|
1357
1476
|
ancestorScroll && ancestor.removeEventListener('scroll', update);
|
|
1358
1477
|
ancestorResize && ancestor.removeEventListener('resize', update);
|
|
1359
1478
|
});
|
|
1360
|
-
|
|
1361
|
-
|
|
1479
|
+
cleanupIo && cleanupIo();
|
|
1480
|
+
resizeObserver && resizeObserver.disconnect();
|
|
1481
|
+
resizeObserver = null;
|
|
1362
1482
|
if (animationFrame) {
|
|
1363
1483
|
cancelAnimationFrame(frameId);
|
|
1364
1484
|
}
|
|
@@ -1397,4 +1517,4 @@ exports.inline = inline;
|
|
|
1397
1517
|
exports.offset = offset;
|
|
1398
1518
|
exports.shift = shift;
|
|
1399
1519
|
|
|
1400
|
-
//# sourceMappingURL=floating-ui.dom.esm-
|
|
1520
|
+
//# sourceMappingURL=floating-ui.dom.esm-3b936e26.js.map
|