@onereach/ui-components 6.1.3 → 6.1.4
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/bundled/v2/components/OrDatePickerV3/OrDatePicker.js +1 -1
- package/dist/bundled/v2/components/OrDateTimePickerV3/OrDateTimePicker.js +1 -1
- package/dist/bundled/v2/components/OrFloating/OrFloating.js +1 -1
- package/dist/bundled/v2/components/OrPopoverV3/OrPopover.js +47 -48
- package/dist/bundled/v2/components/OrPopoverV3/OrPopover.vue.d.ts +18 -4
- package/dist/bundled/v2/components/OrPopoverV3/hooks/types.d.ts +77 -0
- package/dist/bundled/v2/components/OrPopoverV3/hooks/types.js +1 -0
- package/dist/bundled/v2/components/OrPopoverV3/hooks/useFloating.d.ts +4 -0
- package/dist/bundled/v2/components/OrPopoverV3/hooks/useFloating.js +137 -0
- package/dist/bundled/v2/components/OrSortingV3/OrSorting.js +5 -1
- package/dist/bundled/v2/floating-ui.dom-d9ef0d1f.js +1443 -0
- package/dist/bundled/v3/{OrAvatar.vue_vue_type_script_lang-058f42b8.js → OrAvatar.vue_vue_type_script_lang-95fe92f9.js} +1 -1
- package/dist/bundled/v3/{OrButton.vue_vue_type_script_lang-04789919.js → OrButton.vue_vue_type_script_lang-9d4ac135.js} +1 -1
- package/dist/bundled/v3/{OrCardCollection.vue_vue_type_script_lang-084e3a6c.js → OrCardCollection.vue_vue_type_script_lang-ac7e801f.js} +3 -3
- package/dist/bundled/v3/{OrCardCollection.vue_vue_type_script_lang-b49e1183.js → OrCardCollection.vue_vue_type_script_lang-d7695115.js} +3 -3
- package/dist/bundled/v3/{OrCheckbox.vue_vue_type_script_lang-ab56a97e.js → OrCheckbox.vue_vue_type_script_lang-576b5f5d.js} +1 -1
- package/dist/bundled/v3/{OrChip.vue_vue_type_script_lang-1f55d1a7.js → OrChip.vue_vue_type_script_lang-8ccf3d2d.js} +1 -1
- package/dist/bundled/v3/{OrChips.vue_vue_type_script_lang-be1e7c30.js → OrChips.vue_vue_type_script_lang-70be98b5.js} +1 -1
- package/dist/bundled/v3/{OrCode.vue_vue_type_script_lang-28b94dd1.js → OrCode.vue_vue_type_script_lang-26864777.js} +2 -2
- package/dist/bundled/v3/{OrCode.vue_vue_type_script_lang-dce07d9f.js → OrCode.vue_vue_type_script_lang-939f278f.js} +2 -2
- package/dist/bundled/v3/{OrColorPicker.vue_vue_type_script_lang-250f679e.js → OrColorPicker.vue_vue_type_script_lang-7b6d1e64.js} +1 -1
- package/dist/bundled/v3/{OrConfirm.vue_vue_type_script_lang-5218eed6.js → OrConfirm.vue_vue_type_script_lang-01c26f78.js} +1 -1
- package/dist/bundled/v3/{OrConfirm.vue_vue_type_script_lang-05c54fee.js → OrConfirm.vue_vue_type_script_lang-1c8833a9.js} +2 -2
- package/dist/bundled/v3/{OrContextMenu.vue_vue_type_script_lang-f9c94c76.js → OrContextMenu.vue_vue_type_script_lang-a7e28c30.js} +1 -1
- package/dist/bundled/v3/{OrDatePicker.vue_vue_type_script_lang-f0c601e9.js → OrDatePicker.vue_vue_type_script_lang-54a5fcf9.js} +3 -3
- package/dist/bundled/v3/{OrDateTimePicker.vue_vue_type_script_lang-3329d4d8.js → OrDateTimePicker.vue_vue_type_script_lang-2a292787.js} +2 -2
- package/dist/bundled/v3/{OrDateTimePicker.vue_vue_type_script_lang-65c11848.js → OrDateTimePicker.vue_vue_type_script_lang-4b7f7aab.js} +3 -3
- package/dist/bundled/v3/{OrDateTimePickerMonthSelect-3d1478af.js → OrDateTimePickerMonthSelect-457c8634.js} +2 -2
- package/dist/bundled/v3/{OrFloating.vue_vue_type_script_lang-6be13add.js → OrFloating.vue_vue_type_script_lang-d579c010.js} +1 -1
- package/dist/bundled/v3/{OrIcon.vue_vue_type_script_lang-ac8f9d3e.js → OrIcon.vue_vue_type_script_lang-23dad121.js} +1 -1
- package/dist/bundled/v3/{OrIconButton.vue_vue_type_script_lang-7c9e5033.js → OrIconButton.vue_vue_type_script_lang-85c7ef74.js} +2 -2
- package/dist/bundled/v3/{OrIconButton.vue_vue_type_script_lang-e6c61cfd.js → OrIconButton.vue_vue_type_script_lang-adbc7714.js} +1 -1
- package/dist/bundled/v3/{OrInlineInput.vue_vue_type_script_lang-47e464e3.js → OrInlineInput.vue_vue_type_script_lang-31b6e953.js} +1 -1
- package/dist/bundled/v3/{OrInlineTextEdit.vue_vue_type_script_lang-c9474fbe.js → OrInlineTextEdit.vue_vue_type_script_lang-e5151109.js} +1 -1
- package/dist/bundled/v3/{OrInlineTextarea.vue_vue_type_script_lang-2785a182.js → OrInlineTextarea.vue_vue_type_script_lang-f08444c3.js} +1 -1
- package/dist/bundled/v3/{OrInput.vue_vue_type_script_lang-caf9e3f3.js → OrInput.vue_vue_type_script_lang-3c8594b8.js} +1 -1
- package/dist/bundled/v3/{OrList.vue_vue_type_script_lang-8622ae68.js → OrList.vue_vue_type_script_lang-cb637c9e.js} +3 -3
- package/dist/bundled/v3/{OrListOfInputs.vue_vue_type_script_lang-43cf4a6e.js → OrListOfInputs.vue_vue_type_script_lang-31f604eb.js} +3 -3
- package/dist/bundled/v3/{OrMenu.vue_vue_type_script_lang-fa75c5f9.js → OrMenu.vue_vue_type_script_lang-916a42b7.js} +1 -1
- package/dist/bundled/v3/{OrModal.vue_vue_type_script_lang-46c6e9a0.js → OrModal.vue_vue_type_script_lang-34597fe7.js} +1 -1
- package/dist/bundled/v3/{OrModal.vue_vue_type_script_lang-089dd5fd.js → OrModal.vue_vue_type_script_lang-7f46b47e.js} +1 -1
- package/dist/bundled/v3/{OrNotification.vue_vue_type_script_lang-d5cd06d6.js → OrNotification.vue_vue_type_script_lang-17ae96e3.js} +2 -2
- package/dist/bundled/v3/{OrNotification.vue_vue_type_script_lang-e8d9e29d.js → OrNotification.vue_vue_type_script_lang-3ce9dc8a.js} +1 -1
- package/dist/bundled/v3/{OrOverflowMenu.vue_vue_type_script_lang-8976c7cb.js → OrOverflowMenu.vue_vue_type_script_lang-f8e4a5b8.js} +3 -3
- package/dist/bundled/v3/{OrPagination.vue_vue_type_script_lang-f203e797.js → OrPagination.vue_vue_type_script_lang-f147d104.js} +1 -1
- package/dist/bundled/v3/{OrPassword.vue_vue_type_script_lang-801df81f.js → OrPassword.vue_vue_type_script_lang-e85c91c4.js} +1 -1
- package/dist/bundled/v3/{OrPopover.vue_vue_type_script_lang-1b2cb592.js → OrPopover.vue_vue_type_script_lang-e83a4a30.js} +45 -47
- package/dist/bundled/v3/{OrSearch.vue_vue_type_script_lang-db238842.js → OrSearch.vue_vue_type_script_lang-29a39215.js} +1 -1
- package/dist/bundled/v3/{OrSearch.vue_vue_type_script_lang-a1d47bfb.js → OrSearch.vue_vue_type_script_lang-57162ecf.js} +1 -1
- package/dist/bundled/v3/{OrSelect.vue_vue_type_script_lang-54bff43c.js → OrSelect.vue_vue_type_script_lang-8d6431f0.js} +4 -4
- package/dist/bundled/v3/{OrSelect.vue_vue_type_script_lang-0e16c49d.js → OrSelect.vue_vue_type_script_lang-e2818b8e.js} +4 -4
- package/dist/bundled/v3/{OrSidebar.vue_vue_type_script_lang-5e39e11c.js → OrSidebar.vue_vue_type_script_lang-ac0187fe.js} +1 -1
- package/dist/bundled/v3/{OrSlider.vue_vue_type_script_lang-ddeb981a.js → OrSlider.vue_vue_type_script_lang-1632008b.js} +1 -1
- package/dist/bundled/v3/{OrSorting.vue_vue_type_script_lang-a47a6c7c.js → OrSorting.vue_vue_type_script_lang-7aafb94c.js} +1 -1
- package/dist/bundled/v3/{OrStepper.vue_vue_type_script_lang-35b3f789.js → OrStepper.vue_vue_type_script_lang-c7f9582b.js} +1 -1
- package/dist/bundled/v3/{OrTabs.vue_vue_type_script_lang-d53cdbc8.js → OrTabs.vue_vue_type_script_lang-977cfc93.js} +1 -1
- package/dist/bundled/v3/{OrTag.vue_vue_type_script_lang-e3c6c3ea.js → OrTag.vue_vue_type_script_lang-0a36cba8.js} +1 -1
- package/dist/bundled/v3/{OrTag.vue_vue_type_script_lang-db85a592.js → OrTag.vue_vue_type_script_lang-7654a348.js} +1 -1
- package/dist/bundled/v3/{OrTagInput.vue_vue_type_script_lang-739bea76.js → OrTagInput.vue_vue_type_script_lang-21e3e87a.js} +2 -2
- package/dist/bundled/v3/{OrTags.vue_vue_type_script_lang-664206e2.js → OrTags.vue_vue_type_script_lang-f411a7f7.js} +2 -2
- package/dist/bundled/v3/{OrTextbox.vue_vue_type_script_lang-12a5099f.js → OrTextbox.vue_vue_type_script_lang-5c706917.js} +1 -1
- package/dist/bundled/v3/{OrTimePicker.vue_vue_type_script_lang-ffafa6f3.js → OrTimePicker.vue_vue_type_script_lang-16751c5f.js} +2 -2
- package/dist/bundled/v3/{OrTooltip.vue_vue_type_script_lang-e18e400d.js → OrTooltip.vue_vue_type_script_lang-0d0b435f.js} +1 -1
- package/dist/bundled/v3/{OrTooltip.vue_vue_type_script_lang-d59653b0.js → OrTooltip.vue_vue_type_script_lang-b201e580.js} +1 -1
- package/dist/bundled/v3/components/OrAvatar/OrAvatar.js +2 -2
- package/dist/bundled/v3/components/OrAvatar/index.js +1 -1
- package/dist/bundled/v3/components/OrButtonV2/OrButton.js +2 -2
- package/dist/bundled/v3/components/OrButtonV2/index.js +2 -2
- package/dist/bundled/v3/components/OrCardCollection/OrCardCollection.js +2 -2
- package/dist/bundled/v3/components/OrCardCollection/index.js +1 -1
- package/dist/bundled/v3/components/OrCardCollectionV3/OrCardCollection.js +2 -2
- package/dist/bundled/v3/components/OrCardCollectionV3/index.js +1 -1
- package/dist/bundled/v3/components/OrCheckbox/OrCheckbox.js +2 -2
- package/dist/bundled/v3/components/OrCheckbox/index.js +1 -1
- package/dist/bundled/v3/components/OrChip/OrChip.js +2 -2
- package/dist/bundled/v3/components/OrChip/index.js +1 -1
- package/dist/bundled/v3/components/OrChips/OrChips.js +2 -2
- package/dist/bundled/v3/components/OrChips/index.js +2 -2
- package/dist/bundled/v3/components/OrCode/OrCode.js +2 -2
- package/dist/bundled/v3/components/OrCode/index.js +1 -1
- package/dist/bundled/v3/components/OrCodeV3/OrCode.js +2 -2
- package/dist/bundled/v3/components/OrCodeV3/index.js +1 -1
- package/dist/bundled/v3/components/OrColorPicker/OrColorPicker.js +2 -2
- package/dist/bundled/v3/components/OrColorPicker/index.js +1 -1
- package/dist/bundled/v3/components/OrConfirm/OrConfirm.js +2 -2
- package/dist/bundled/v3/components/OrConfirm/index.js +1 -1
- package/dist/bundled/v3/components/OrConfirmV3/OrConfirm.js +2 -2
- package/dist/bundled/v3/components/OrConfirmV3/index.js +1 -1
- package/dist/bundled/v3/components/OrContextMenuV3/OrContextMenu.js +2 -2
- package/dist/bundled/v3/components/OrContextMenuV3/index.js +1 -1
- package/dist/bundled/v3/components/OrDatePickerV3/OrDatePicker.js +2 -2
- package/dist/bundled/v3/components/OrDatePickerV3/index.js +1 -1
- package/dist/bundled/v3/components/OrDateTimePicker/OrDateTimePicker.js +2 -2
- package/dist/bundled/v3/components/OrDateTimePicker/index.js +1 -1
- package/dist/bundled/v3/components/OrDateTimePickerV3/OrDateTimePicker.js +2 -2
- package/dist/bundled/v3/components/OrDateTimePickerV3/index.js +1 -1
- package/dist/bundled/v3/components/OrFloating/OrFloating.js +2 -2
- package/dist/bundled/v3/components/OrFloating/index.js +1 -1
- package/dist/bundled/v3/components/OrIcon/OrIcon.js +2 -2
- package/dist/bundled/v3/components/OrIcon/index.js +1 -1
- package/dist/bundled/v3/components/OrIconButtonV2/OrIconButton.js +2 -2
- package/dist/bundled/v3/components/OrIconButtonV2/index.js +1 -1
- package/dist/bundled/v3/components/OrIconButtonV3/OrIconButton.js +2 -2
- package/dist/bundled/v3/components/OrIconButtonV3/index.js +1 -1
- package/dist/bundled/v3/components/OrInlineInputV3/OrInlineInput.js +2 -2
- package/dist/bundled/v3/components/OrInlineInputV3/index.js +1 -1
- package/dist/bundled/v3/components/OrInlineTextEdit/OrInlineTextEdit.js +2 -2
- package/dist/bundled/v3/components/OrInlineTextEdit/index.js +1 -1
- package/dist/bundled/v3/components/OrInlineTextareaV3/OrInlineTextarea.js +2 -2
- package/dist/bundled/v3/components/OrInlineTextareaV3/index.js +1 -1
- package/dist/bundled/v3/components/OrInputV3/OrInput.js +2 -2
- package/dist/bundled/v3/components/OrInputV3/index.js +1 -1
- package/dist/bundled/v3/components/OrList/OrList.js +2 -2
- package/dist/bundled/v3/components/OrList/index.js +1 -1
- package/dist/bundled/v3/components/OrListOfInputs/OrListOfInputs.js +2 -2
- package/dist/bundled/v3/components/OrListOfInputs/index.js +1 -1
- package/dist/bundled/v3/components/OrMenuV3/OrMenu.js +2 -2
- package/dist/bundled/v3/components/OrMenuV3/index.js +1 -1
- package/dist/bundled/v3/components/OrModal/OrModal.js +2 -2
- package/dist/bundled/v3/components/OrModal/index.js +1 -1
- package/dist/bundled/v3/components/OrModalV3/OrModal.js +2 -2
- package/dist/bundled/v3/components/OrModalV3/index.js +1 -1
- package/dist/bundled/v3/components/OrNotification/OrNotification.js +2 -2
- package/dist/bundled/v3/components/OrNotification/index.js +1 -1
- package/dist/bundled/v3/components/OrNotificationV3/OrNotification.js +2 -2
- package/dist/bundled/v3/components/OrNotificationV3/index.js +1 -1
- package/dist/bundled/v3/components/OrOverflowMenu/OrOverflowMenu.js +2 -2
- package/dist/bundled/v3/components/OrOverflowMenu/index.js +1 -1
- package/dist/bundled/v3/components/OrPaginationV3/OrPagination.js +2 -2
- package/dist/bundled/v3/components/OrPaginationV3/index.js +1 -1
- package/dist/bundled/v3/components/OrPassword/OrPassword.js +2 -2
- package/dist/bundled/v3/components/OrPassword/index.js +1 -1
- package/dist/bundled/v3/components/OrPopoverV3/OrPopover.js +3 -2
- package/dist/bundled/v3/components/OrPopoverV3/OrPopover.vue.d.ts +9 -2
- package/dist/bundled/v3/components/OrPopoverV3/hooks/types.d.ts +77 -0
- package/dist/bundled/v3/components/OrPopoverV3/hooks/types.js +1 -0
- package/dist/bundled/v3/components/OrPopoverV3/hooks/useFloating.d.ts +4 -0
- package/dist/bundled/v3/components/OrPopoverV3/hooks/useFloating.js +137 -0
- package/dist/bundled/v3/components/OrPopoverV3/index.js +1 -1
- package/dist/bundled/v3/components/OrSearch/OrSearch.js +2 -2
- package/dist/bundled/v3/components/OrSearch/index.js +1 -1
- package/dist/bundled/v3/components/OrSearchV3/OrSearch.js +2 -2
- package/dist/bundled/v3/components/OrSearchV3/index.js +1 -1
- package/dist/bundled/v3/components/OrSelect/OrSelect.js +2 -2
- package/dist/bundled/v3/components/OrSelect/index.js +1 -1
- package/dist/bundled/v3/components/OrSelectV3/OrSelect.js +2 -2
- package/dist/bundled/v3/components/OrSelectV3/index.js +1 -1
- package/dist/bundled/v3/components/OrSidebarV3/OrSidebar.js +2 -2
- package/dist/bundled/v3/components/OrSidebarV3/index.js +1 -1
- package/dist/bundled/v3/components/OrSlider/OrSlider.js +2 -2
- package/dist/bundled/v3/components/OrSlider/index.js +1 -1
- package/dist/bundled/v3/components/OrSortingV3/OrSorting.js +7 -3
- package/dist/bundled/v3/components/OrSortingV3/index.js +1 -1
- package/dist/bundled/v3/components/OrStepper/OrStepper.js +2 -2
- package/dist/bundled/v3/components/OrStepper/index.js +1 -1
- package/dist/bundled/v3/components/OrTabsV3/OrTabs.js +2 -2
- package/dist/bundled/v3/components/OrTabsV3/index.js +1 -1
- package/dist/bundled/v3/components/OrTag/OrTag.js +2 -2
- package/dist/bundled/v3/components/OrTag/index.js +1 -1
- package/dist/bundled/v3/components/OrTagInputV3/OrTagInput.js +2 -2
- package/dist/bundled/v3/components/OrTagInputV3/index.js +1 -1
- package/dist/bundled/v3/components/OrTagV3/OrTag.js +2 -2
- package/dist/bundled/v3/components/OrTagV3/index.js +1 -1
- package/dist/bundled/v3/components/OrTagsV3/OrTags.js +2 -2
- package/dist/bundled/v3/components/OrTagsV3/index.js +1 -1
- package/dist/bundled/v3/components/OrTextbox/OrTextbox.js +2 -2
- package/dist/bundled/v3/components/OrTextbox/index.js +1 -1
- package/dist/bundled/v3/components/OrTimePickerV3/OrTimePicker.js +2 -2
- package/dist/bundled/v3/components/OrTimePickerV3/index.js +1 -1
- package/dist/bundled/v3/components/OrToast/OrToast.js +1 -1
- package/dist/bundled/v3/components/OrToast/index.js +1 -1
- package/dist/bundled/v3/components/OrToastContainer/OrToastContainer.js +2 -2
- package/dist/bundled/v3/components/OrToastContainer/index.js +1 -1
- package/dist/bundled/v3/components/OrToastContainerV3/OrToastContainer.js +2 -2
- package/dist/bundled/v3/components/OrToastContainerV3/index.js +1 -1
- package/dist/bundled/v3/components/OrToastV3/OrToast.js +1 -1
- package/dist/bundled/v3/components/OrToastV3/index.js +1 -1
- package/dist/bundled/v3/components/OrTooltip/OrTooltip.js +2 -2
- package/dist/bundled/v3/components/OrTooltip/index.js +1 -1
- package/dist/bundled/v3/components/OrTooltipV3/OrTooltip.js +2 -2
- package/dist/bundled/v3/components/OrTooltipV3/index.js +1 -1
- package/dist/bundled/v3/components/index.js +54 -54
- package/dist/bundled/v3/floating-ui.dom-d9ef0d1f.js +1443 -0
- package/dist/bundled/v3/index.js +54 -54
- package/dist/esm/v2/{OrCardCollection-57a8050a.js → OrCardCollection-c27ae76f.js} +3 -3
- package/dist/esm/v2/{OrCode-8ed38ba0.js → OrCode-4501e2df.js} +2 -2
- package/dist/esm/v2/{OrConfirm-1ed37e0e.js → OrConfirm-4841e1eb.js} +1 -1
- package/dist/esm/v2/{OrContextMenu-eafd1a99.js → OrContextMenu-01efdb43.js} +2 -2
- package/dist/esm/v2/{OrDatePicker-5a7e8810.js → OrDatePicker-528b55ec.js} +3 -3
- package/dist/esm/v2/{OrDateTimePicker-8494f545.js → OrDateTimePicker-80bd401a.js} +1 -1
- package/dist/esm/v2/{OrDateTimePicker.vue_rollup-plugin-vue_script-c14cf224.js → OrDateTimePicker.vue_rollup-plugin-vue_script-8e987b8d.js} +3 -3
- package/dist/esm/v2/{OrDateTimePickerPopoverHeader-7f9e4d2b.js → OrDateTimePickerPopoverHeader-835e4e49.js} +3 -3
- package/dist/esm/v2/{OrIconButton-27b956d4.js → OrIconButton-6eda233c.js} +2 -2
- package/dist/esm/v2/{OrInlineInput-85857493.js → OrInlineInput-9f88fff9.js} +1 -1
- package/dist/esm/v2/{OrInlineTextarea-8eb5496f.js → OrInlineTextarea-03e8b8a6.js} +1 -1
- package/dist/esm/v2/{OrInput-8dd34dd1.js → OrInput-54abe165.js} +1 -1
- package/dist/esm/v2/{OrMenu-d4faf682.js → OrMenu-c2c6473f.js} +1 -1
- package/dist/esm/v2/{OrModal-8e67d338.js → OrModal-8ea08182.js} +1 -1
- package/dist/esm/v2/{OrNotification-f3398729.js → OrNotification-9875c55d.js} +1 -1
- package/dist/esm/v2/{OrPagination-ebb41c8e.js → OrPagination-c5058980.js} +2 -2
- package/dist/esm/v2/{OrPopover-33cfbe85.js → OrPopover-f6114169.js} +180 -48
- package/dist/esm/v2/{OrSearch-621875e2.js → OrSearch-8a834099.js} +1 -1
- package/dist/esm/v2/{OrSelect-ffad4f01.js → OrSelect-cd37db8d.js} +4 -4
- package/dist/esm/v2/{OrSidebar-a15270fd.js → OrSidebar-a5608742.js} +1 -1
- package/dist/esm/v2/{OrSidebarCollapseButton-b62ed09d.js → OrSidebarCollapseButton-c999d09a.js} +1 -1
- package/dist/esm/v2/{OrSorting-90322f1e.js → OrSorting-82557def.js} +7 -3
- package/dist/esm/v2/{OrTabs-ba0c1ebe.js → OrTabs-92ccb30f.js} +2 -2
- package/dist/esm/v2/{OrTag-a37918e7.js → OrTag-15cd89e8.js} +1 -1
- package/dist/esm/v2/{OrTagInput-5e4fb76f.js → OrTagInput-f443f295.js} +2 -2
- package/dist/esm/v2/{OrTags-7e7c728a.js → OrTags-b34c628e.js} +2 -2
- package/dist/esm/v2/{OrTimePicker-4cea1dda.js → OrTimePicker-e711a256.js} +4 -4
- package/dist/esm/v2/{OrTooltip-0dc5202d.js → OrTooltip-a4e679bb.js} +1 -1
- package/dist/esm/v2/components/index.js +29 -29
- package/dist/esm/v2/components/or-card-collection-v3/index.js +8 -8
- package/dist/esm/v2/components/or-code-v3/index.js +5 -5
- package/dist/esm/v2/components/or-confirm-v3/index.js +5 -5
- package/dist/esm/v2/components/or-context-menu-v3/index.js +3 -3
- package/dist/esm/v2/components/or-date-picker-v3/index.js +6 -6
- package/dist/esm/v2/components/or-date-time-picker-v3/index.js +7 -7
- package/dist/esm/v2/components/or-icon-button-v3/index.js +3 -3
- package/dist/esm/v2/components/or-inline-input-v3/index.js +4 -4
- package/dist/esm/v2/components/or-inline-textarea-v3/index.js +4 -4
- package/dist/esm/v2/components/or-input-v3/index.js +4 -4
- package/dist/esm/v2/components/or-menu-v3/index.js +2 -2
- package/dist/esm/v2/components/or-modal-v3/index.js +4 -4
- package/dist/esm/v2/components/or-notification-v3/index.js +4 -4
- package/dist/esm/v2/components/or-pagination-v3/index.js +3 -3
- package/dist/esm/v2/components/or-popover-v3/OrPopover.vue.d.ts +18 -4
- package/dist/esm/v2/components/or-popover-v3/hooks/types.d.ts +77 -0
- package/dist/esm/v2/components/or-popover-v3/hooks/useFloating.d.ts +4 -0
- package/dist/esm/v2/components/or-popover-v3/index.js +1 -1
- package/dist/esm/v2/components/or-search-v3/index.js +5 -5
- package/dist/esm/v2/components/or-select-v3/index.js +6 -6
- package/dist/esm/v2/components/or-sidebar-v3/index.js +5 -5
- package/dist/esm/v2/components/or-sidebar-v3/partials/index.js +4 -4
- package/dist/esm/v2/components/or-sorting-v3/index.js +3 -3
- package/dist/esm/v2/components/or-tabs-v3/index.js +3 -3
- package/dist/esm/v2/components/or-tag-input-v3/index.js +6 -6
- package/dist/esm/v2/components/or-tag-v3/index.js +4 -4
- package/dist/esm/v2/components/or-tags-v3/index.js +5 -5
- package/dist/esm/v2/components/or-time-picker-v3/index.js +7 -7
- package/dist/esm/v2/components/or-toast-v3/index.js +4 -4
- package/dist/esm/v2/components/or-toast-v3/or-toast-container-v3/index.js +4 -4
- package/dist/esm/v2/components/or-tooltip-v3/index.js +2 -2
- package/dist/esm/v2/index.js +29 -29
- package/dist/esm/v2/{types-c2ae54c4.js → types-635157b1.js} +1 -1
- package/dist/esm/v3/{OrCardCollection-9791a2b5.js → OrCardCollection-bddf72ef.js} +3 -3
- package/dist/esm/v3/{OrCode-abc9471e.js → OrCode-a63c3a7b.js} +2 -2
- package/dist/esm/v3/{OrConfirm-19e7c8e8.js → OrConfirm-d304e9a4.js} +1 -1
- package/dist/esm/v3/{OrContextMenu-716dc892.js → OrContextMenu-bf1e07ae.js} +2 -2
- package/dist/esm/v3/{OrDatePicker-ebeb9f68.js → OrDatePicker-87aef206.js} +3 -3
- package/dist/esm/v3/{OrDateTimePicker-24be33b0.js → OrDateTimePicker-738f9cd3.js} +3 -3
- package/dist/esm/v3/{OrDateTimePickerPopoverHeader-f2890500.js → OrDateTimePickerPopoverHeader-03ae7d09.js} +3 -3
- package/dist/esm/v3/{OrIconButton-5c4371dd.js → OrIconButton-a69c7775.js} +2 -2
- package/dist/esm/v3/{OrInlineInput-bea03180.js → OrInlineInput-246d88ca.js} +1 -1
- package/dist/esm/v3/{OrInlineTextarea-df7b8b6a.js → OrInlineTextarea-c9febb84.js} +1 -1
- package/dist/esm/v3/{OrInput-1eb88296.js → OrInput-e12b0489.js} +1 -1
- package/dist/esm/v3/{OrMenu-ff970bcb.js → OrMenu-9a82f18f.js} +1 -1
- package/dist/esm/v3/{OrModal-1b83e7d3.js → OrModal-fc3bb76e.js} +1 -1
- package/dist/esm/v3/{OrNotification-873d8c57.js → OrNotification-c8cd9f3d.js} +1 -1
- package/dist/esm/v3/{OrPagination-3f37f40e.js → OrPagination-cc0b041a.js} +2 -2
- package/dist/esm/v3/{OrPopover-972d594f.js → OrPopover-7b2af064.js} +179 -47
- package/dist/esm/v3/{OrSearch-e68d4be3.js → OrSearch-bc259374.js} +1 -1
- package/dist/esm/v3/{OrSelect-bb5ca541.js → OrSelect-a7d3c84d.js} +4 -4
- package/dist/esm/v3/{OrSidebar-4db54e71.js → OrSidebar-8837a93e.js} +1 -1
- package/dist/esm/v3/{OrSidebarCollapseButton-493b4fb0.js → OrSidebarCollapseButton-f44951ac.js} +1 -1
- package/dist/esm/v3/{OrSorting-852633b5.js → OrSorting-6baec1ab.js} +7 -3
- package/dist/esm/v3/{OrTabs-60e18180.js → OrTabs-2ab1aefa.js} +2 -2
- package/dist/esm/v3/{OrTag-91a545db.js → OrTag-2a3d7293.js} +1 -1
- package/dist/esm/v3/{OrTagInput-6decbf5e.js → OrTagInput-ccb72239.js} +2 -2
- package/dist/esm/v3/{OrTags-641804a0.js → OrTags-69e90412.js} +2 -2
- package/dist/esm/v3/{OrTimePicker-839da564.js → OrTimePicker-a3870a62.js} +4 -4
- package/dist/esm/v3/{OrTooltip-af24ca57.js → OrTooltip-5bf6890a.js} +1 -1
- package/dist/esm/v3/components/index.js +28 -28
- package/dist/esm/v3/components/or-card-collection-v3/index.js +8 -8
- package/dist/esm/v3/components/or-code-v3/index.js +5 -5
- package/dist/esm/v3/components/or-confirm-v3/index.js +5 -5
- package/dist/esm/v3/components/or-context-menu-v3/index.js +3 -3
- package/dist/esm/v3/components/or-date-picker-v3/index.js +6 -6
- package/dist/esm/v3/components/or-date-time-picker-v3/index.js +6 -6
- package/dist/esm/v3/components/or-icon-button-v3/index.js +3 -3
- package/dist/esm/v3/components/or-inline-input-v3/index.js +4 -4
- package/dist/esm/v3/components/or-inline-textarea-v3/index.js +4 -4
- package/dist/esm/v3/components/or-input-v3/index.js +4 -4
- package/dist/esm/v3/components/or-menu-v3/index.js +2 -2
- package/dist/esm/v3/components/or-modal-v3/index.js +4 -4
- package/dist/esm/v3/components/or-notification-v3/index.js +4 -4
- package/dist/esm/v3/components/or-pagination-v3/index.js +3 -3
- package/dist/esm/v3/components/or-popover-v3/OrPopover.vue.d.ts +9 -2
- package/dist/esm/v3/components/or-popover-v3/hooks/types.d.ts +77 -0
- package/dist/esm/v3/components/or-popover-v3/hooks/useFloating.d.ts +4 -0
- package/dist/esm/v3/components/or-popover-v3/index.js +1 -1
- package/dist/esm/v3/components/or-search-v3/index.js +5 -5
- package/dist/esm/v3/components/or-select-v3/index.js +6 -6
- package/dist/esm/v3/components/or-sidebar-v3/index.js +5 -5
- package/dist/esm/v3/components/or-sidebar-v3/partials/index.js +4 -4
- package/dist/esm/v3/components/or-sorting-v3/index.js +3 -3
- package/dist/esm/v3/components/or-tabs-v3/index.js +3 -3
- package/dist/esm/v3/components/or-tag-input-v3/index.js +6 -6
- package/dist/esm/v3/components/or-tag-v3/index.js +4 -4
- package/dist/esm/v3/components/or-tags-v3/index.js +5 -5
- package/dist/esm/v3/components/or-time-picker-v3/index.js +7 -7
- package/dist/esm/v3/components/or-toast-v3/index.js +4 -4
- package/dist/esm/v3/components/or-toast-v3/or-toast-container-v3/index.js +4 -4
- package/dist/esm/v3/components/or-tooltip-v3/index.js +2 -2
- package/dist/esm/v3/index.js +28 -28
- package/dist/esm/v3/{types-c59b23d8.js → types-c4c1e2cc.js} +1 -1
- package/package.json +3 -3
- package/src/components/or-popover-v3/OrPopover.vue +32 -48
- package/src/components/or-popover-v3/hooks/types.ts +97 -0
- package/src/components/or-popover-v3/hooks/useFloating.ts +159 -0
- package/src/components/or-sorting-v3/OrSorting.vue +4 -0
- package/dist/bundled/v2/floating-ui.dom.esm-83eba816.js +0 -1082
- package/dist/bundled/v3/floating-ui.dom.esm-83eba816.js +0 -1082
- /package/dist/bundled/v2/{OrDateTimePickerMonthSelect-31a5687d.js → OrDateTimePickerMonthSelect-ac5c91e5.js} +0 -0
- /package/dist/bundled/v3/{OrToastContainer.vue_vue_type_script_lang-619af0a2.js → OrToastContainer.vue_vue_type_script_lang-1693c39d.js} +0 -0
- /package/dist/bundled/v3/{OrToastContainer.vue_vue_type_script_lang-4b586b65.js → OrToastContainer.vue_vue_type_script_lang-71a39d2d.js} +0 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { s as OrTimePickerV3 } from '../../OrTimePicker-
|
|
2
|
-
export { D as TimePickerFormat } from '../../OrDateTimePicker-
|
|
1
|
+
export { s as OrTimePickerV3 } from '../../OrTimePicker-a3870a62.js';
|
|
2
|
+
export { D as TimePickerFormat } from '../../OrDateTimePicker-738f9cd3.js';
|
|
3
3
|
export { I as TimePickerSize } from '../../OrInputBox-912a6254.js';
|
|
4
4
|
import 'vue-demi';
|
|
5
5
|
import '../../dropdown-open-06d651cf.js';
|
|
@@ -10,16 +10,16 @@ import 'lodash/get';
|
|
|
10
10
|
import '../../useProxyModelValue-940010d2.js';
|
|
11
11
|
import '@onereach/styles/tailwind/plugins/core';
|
|
12
12
|
import '@onereach/styles/tailwind.config.json';
|
|
13
|
-
import '../../OrDateTimePickerPopoverHeader-
|
|
13
|
+
import '../../OrDateTimePickerPopoverHeader-03ae7d09.js';
|
|
14
14
|
import 'vue';
|
|
15
15
|
import '../../OrButton-4a3c3e7b.js';
|
|
16
16
|
import '../../OrLoader-b79022da.js';
|
|
17
17
|
import '../../OrLabel-d4c46bb6.js';
|
|
18
|
-
import '../../OrIconButton-
|
|
18
|
+
import '../../OrIconButton-a69c7775.js';
|
|
19
19
|
import '../../OrIcon-62793572.js';
|
|
20
|
-
import '../../OrTooltip-
|
|
20
|
+
import '../../OrTooltip-5bf6890a.js';
|
|
21
21
|
import '../../usePopoverState-b92c698b.js';
|
|
22
|
-
import '../../OrPopover-
|
|
22
|
+
import '../../OrPopover-7b2af064.js';
|
|
23
23
|
import '@floating-ui/dom';
|
|
24
24
|
import '../../useElevation-a50ec347.js';
|
|
25
25
|
import '../../useResponsive-5c8291da.js';
|
|
@@ -28,6 +28,6 @@ import '../../OrOverlay-6269c33a.js';
|
|
|
28
28
|
import '../../OrTeleport.vue3-8099178c.js';
|
|
29
29
|
import '../../useTheme-0ef25778.js';
|
|
30
30
|
import '../../OrMenuItem-54062d59.js';
|
|
31
|
-
import '../../OrMenu-
|
|
31
|
+
import '../../OrMenu-9a82f18f.js';
|
|
32
32
|
import '../../OrError-c01d0c29.js';
|
|
33
33
|
import '../../OrHint-06ab89d7.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { a as OrToastContainerV3, s as OrToastV3, t as TypesV3 } from '../../types-
|
|
1
|
+
export { a as OrToastContainerV3, s as OrToastV3, t as TypesV3 } from '../../types-c4c1e2cc.js';
|
|
2
2
|
export { p as PropsV3, a as useQueueV3, u as useToastV3 } from '../../useToast-5aa9dc05.js';
|
|
3
3
|
import '@vueuse/core';
|
|
4
4
|
import 'vue-demi';
|
|
@@ -10,11 +10,11 @@ import '@onereach/styles/tailwind/plugins/core';
|
|
|
10
10
|
import '@onereach/styles/tailwind.config.json';
|
|
11
11
|
import '../../OrTeleport.vue3-8099178c.js';
|
|
12
12
|
import 'vue';
|
|
13
|
-
import '../../OrIconButton-
|
|
13
|
+
import '../../OrIconButton-a69c7775.js';
|
|
14
14
|
import '../../OrIcon-62793572.js';
|
|
15
|
-
import '../../OrTooltip-
|
|
15
|
+
import '../../OrTooltip-5bf6890a.js';
|
|
16
16
|
import '../../usePopoverState-b92c698b.js';
|
|
17
|
-
import '../../OrPopover-
|
|
17
|
+
import '../../OrPopover-7b2af064.js';
|
|
18
18
|
import '@floating-ui/dom';
|
|
19
19
|
import '../../useResponsive-5c8291da.js';
|
|
20
20
|
import '../../OrBottomSheet-efcae28c.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { a as OrToastContainerV3, t as TypesV3 } from '../../../types-
|
|
1
|
+
export { a as OrToastContainerV3, t as TypesV3 } from '../../../types-c4c1e2cc.js';
|
|
2
2
|
export { p as PropsV3, a as useQueueV3, u as useToastV3 } from '../../../useToast-5aa9dc05.js';
|
|
3
3
|
import '@vueuse/core';
|
|
4
4
|
import 'vue-demi';
|
|
@@ -10,11 +10,11 @@ import '@onereach/styles/tailwind/plugins/core';
|
|
|
10
10
|
import '@onereach/styles/tailwind.config.json';
|
|
11
11
|
import '../../../OrTeleport.vue3-8099178c.js';
|
|
12
12
|
import 'vue';
|
|
13
|
-
import '../../../OrIconButton-
|
|
13
|
+
import '../../../OrIconButton-a69c7775.js';
|
|
14
14
|
import '../../../OrIcon-62793572.js';
|
|
15
|
-
import '../../../OrTooltip-
|
|
15
|
+
import '../../../OrTooltip-5bf6890a.js';
|
|
16
16
|
import '../../../usePopoverState-b92c698b.js';
|
|
17
|
-
import '../../../OrPopover-
|
|
17
|
+
import '../../../OrPopover-7b2af064.js';
|
|
18
18
|
import '@floating-ui/dom';
|
|
19
19
|
import '../../../useResponsive-5c8291da.js';
|
|
20
20
|
import '../../../OrBottomSheet-efcae28c.js';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { s as OrTooltipV3 } from '../../OrTooltip-
|
|
2
|
-
export { P as TooltipPlacement } from '../../OrPopover-
|
|
1
|
+
export { s as OrTooltipV3 } from '../../OrTooltip-5bf6890a.js';
|
|
2
|
+
export { P as TooltipPlacement } from '../../OrPopover-7b2af064.js';
|
|
3
3
|
import 'vue-demi';
|
|
4
4
|
import '@vueuse/core';
|
|
5
5
|
import '../../dom-aecadd9a.js';
|
package/dist/esm/v3/index.js
CHANGED
|
@@ -7,7 +7,7 @@ export { a as BUTTON_COLOR, c as BUTTON_LOADER_TYPE, b as BUTTON_SIZE, B as BUTT
|
|
|
7
7
|
export { a as ButtonColor, b as ButtonType, B as ButtonVariant, s as OrButtonV3 } from './OrButton-4a3c3e7b.js';
|
|
8
8
|
export { s as OrCard } from './OrCard-e3a5aea4.js';
|
|
9
9
|
export { C as CARD_COLLECTION_LAYOUT, s as OrCardCollection } from './OrCardCollection-8c81a2d5.js';
|
|
10
|
-
export { C as CardCollectionView, s as OrCardCollectionV3, d as defaultViewModes, g as gridView, l as listView } from './OrCardCollection-
|
|
10
|
+
export { C as CardCollectionView, s as OrCardCollectionV3, d as defaultViewModes, g as gridView, l as listView } from './OrCardCollection-bddf72ef.js';
|
|
11
11
|
export { s as OrCardV3 } from './OrCard-cc82902c.js';
|
|
12
12
|
export { s as OrCheckbox } from './OrCheckbox-5666c954.js';
|
|
13
13
|
export { s as OrCheckboxGroupV3 } from './OrCheckboxGroup-f80d8bc0.js';
|
|
@@ -21,19 +21,19 @@ export { lintGutter, linter } from '@codemirror/lint';
|
|
|
21
21
|
export { javascript } from '@codemirror/lang-javascript';
|
|
22
22
|
export { json, jsonParseLinter } from '@codemirror/lang-json';
|
|
23
23
|
export { html } from '@codemirror/lang-html';
|
|
24
|
-
export { C as CodeLanguage, s as OrCodeV3 } from './OrCode-
|
|
24
|
+
export { C as CodeLanguage, s as OrCodeV3 } from './OrCode-a63c3a7b.js';
|
|
25
25
|
export { s as OrCollapse } from './OrCollapse-d7c0afae.js';
|
|
26
26
|
export { s as OrColorPicker, h as amber, n as black, b as blue, m as blueGrey, k as brown, c as cyan, j as deepOrange, d as deepPurple, g as green, i as indigo, l as lightBlue, e as lightGreen, f as lime, o as orange, p as pink, a as purple, r as red, t as teal, w as white, y as yellow } from './OrColorPicker-252f482b.js';
|
|
27
27
|
export { s as OrCombinedInputV3 } from './OrCombinedInput-b8a868cb.js';
|
|
28
28
|
export { I as CombinedInputSize, I as DatePickerSize, I as DateTimePickerSize, I as InputBoxSize, a as InputBoxVariant, I as InputSize, s as OrInputBoxV3, I as SearchSize, I as SelectSize, I as TagInputSize, I as TextareaSize, I as TimePickerSize } from './OrInputBox-912a6254.js';
|
|
29
29
|
export { s as OrConfirm } from './OrConfirm-97ab80b9.js';
|
|
30
|
-
export { C as ConfirmType, s as OrConfirmV3 } from './OrConfirm-
|
|
31
|
-
export { s as OrContextMenuV3 } from './OrContextMenu-
|
|
32
|
-
export { s as OrMenuV3 } from './OrMenu-
|
|
33
|
-
export { P as ContextMenuPlacement, P as MenuPlacement, s as OrPopoverV3, P as PopoverPlacement, a as PopoverVariant, P as TooltipPlacement } from './OrPopover-
|
|
34
|
-
export { s as OrDatePickerV3 } from './OrDatePicker-
|
|
30
|
+
export { C as ConfirmType, s as OrConfirmV3 } from './OrConfirm-d304e9a4.js';
|
|
31
|
+
export { s as OrContextMenuV3 } from './OrContextMenu-bf1e07ae.js';
|
|
32
|
+
export { s as OrMenuV3 } from './OrMenu-9a82f18f.js';
|
|
33
|
+
export { P as ContextMenuPlacement, P as MenuPlacement, s as OrPopoverV3, P as PopoverPlacement, a as PopoverVariant, P as TooltipPlacement } from './OrPopover-7b2af064.js';
|
|
34
|
+
export { s as OrDatePickerV3 } from './OrDatePicker-87aef206.js';
|
|
35
35
|
export { D as DEFAULT_TEXT, s as OrDateTimePicker, a as OrDateTimePickerItemTypes, O as OrDateTimePickerTypes } from './OrDateTimePicker-4bfefbcd.js';
|
|
36
|
-
export { D as DateTimePickerTimeFormat, s as OrDateTimePickerV3, D as TimePickerFormat } from './OrDateTimePicker-
|
|
36
|
+
export { D as DateTimePickerTimeFormat, s as OrDateTimePickerV3, D as TimePickerFormat } from './OrDateTimePicker-738f9cd3.js';
|
|
37
37
|
export { E as EmptyStateSize, s as OrEmptyStateV3 } from './OrEmptyState-5349a1f9.js';
|
|
38
38
|
export { s as OrError } from './OrError-f90296db.js';
|
|
39
39
|
export { s as OrErrorTagV3 } from './OrErrorTag-ade9192b.js';
|
|
@@ -45,14 +45,14 @@ export { F as FormGroupDirection, s as OrFormGroupV3 } from './OrFormGroup-37f2b
|
|
|
45
45
|
export { s as OrHint } from './OrHint-8822005b.js';
|
|
46
46
|
export { s as OrHintV3 } from './OrHint-06ab89d7.js';
|
|
47
47
|
export { s as OrIcon, O as OrIconColors, a as OrIconType } from './OrIcon-f7130a5c.js';
|
|
48
|
-
export { I as IconButtonColor, s as OrIconButtonV3 } from './OrIconButton-
|
|
48
|
+
export { I as IconButtonColor, s as OrIconButtonV3 } from './OrIconButton-a69c7775.js';
|
|
49
49
|
export { I as IconButtonSize, I as IconSize, a as IconVariant, s as OrIconV3 } from './OrIcon-62793572.js';
|
|
50
50
|
export { I as InlineInputBoxSize, I as InlineInputSize, s as OrInlineInputBoxV3 } from './OrInlineInputBox-01fb2cb2.js';
|
|
51
|
-
export { I as InlineInputType, s as OrInlineInputV3 } from './OrInlineInput-
|
|
51
|
+
export { I as InlineInputType, s as OrInlineInputV3 } from './OrInlineInput-246d88ca.js';
|
|
52
52
|
export { a as InlineTextEditTrimmingTypes, I as InlineTextEditTypes, s as OrInlineTextEdit } from './OrInlineTextEdit-a3c4c7dc.js';
|
|
53
|
-
export { s as OrInlineTextareaV3 } from './OrInlineTextarea-
|
|
53
|
+
export { s as OrInlineTextareaV3 } from './OrInlineTextarea-c9febb84.js';
|
|
54
54
|
export { s as OrInput } from './OrInput-2c3111c2.js';
|
|
55
|
-
export { I as InputType, s as OrInputV3 } from './OrInput-
|
|
55
|
+
export { I as InputType, s as OrInputV3 } from './OrInput-e12b0489.js';
|
|
56
56
|
export { s as OrLabel } from './OrLabel-a7d99df4.js';
|
|
57
57
|
export { L as LabelVariant, s as OrLabelV3 } from './OrLabel-d4c46bb6.js';
|
|
58
58
|
export { L as LinkColor, s as OrLinkV3 } from './OrLink-dcae31fb.js';
|
|
@@ -62,14 +62,14 @@ export { L as LoaderViews, s as OrLoader } from './OrLoader-d28a8ebf.js';
|
|
|
62
62
|
export { a as LoaderColor, b as LoaderSize, L as LoaderVariant, s as OrLoaderV3 } from './OrLoader-b79022da.js';
|
|
63
63
|
export { s as OrMenuItemV3 } from './OrMenuItem-54062d59.js';
|
|
64
64
|
export { s as OrModal, O as OrModalSizes } from './OrModal-b2060770.js';
|
|
65
|
-
export { M as ModalSize, s as OrModalV3 } from './OrModal-
|
|
65
|
+
export { M as ModalSize, s as OrModalV3 } from './OrModal-fc3bb76e.js';
|
|
66
66
|
export { a as OR_NOTIFICATION_SIZE, O as OR_NOTIFICATION_TYPE, s as OrNotification } from './OrNotification-1b28dd4a.js';
|
|
67
|
-
export { N as NotificationVariant, s as OrNotificationV3 } from './OrNotification-
|
|
67
|
+
export { N as NotificationVariant, s as OrNotificationV3 } from './OrNotification-c8cd9f3d.js';
|
|
68
68
|
export { s as OrNumberInput } from './OrNumberInput-e9dcdcbd.js';
|
|
69
69
|
export { s as OrOverflowMenu } from './OrOverflowMenu-440ddf3e.js';
|
|
70
70
|
export { s as OrOverlay } from './OrOverlay-451dce49.js';
|
|
71
71
|
export { s as OrOverlayV3 } from './OrOverlay-6269c33a.js';
|
|
72
|
-
export { s as OrPaginationV3 } from './OrPagination-
|
|
72
|
+
export { s as OrPaginationV3 } from './OrPagination-cc0b041a.js';
|
|
73
73
|
export { s as OrPassword } from './OrPassword-4494ac89.js';
|
|
74
74
|
export { s as OrProgress, O as OrProgressColors, a as OrProgressTypes } from './OrProgress-aa2ea84b.js';
|
|
75
75
|
export { s as OrProgressV3, P as ProgressColor, a as ProgressType } from './OrProgress-73b41ba4.js';
|
|
@@ -78,13 +78,13 @@ export { s as OrRadioGroup } from './OrRadioGroup-00785e41.js';
|
|
|
78
78
|
export { s as OrRadioGroupV3 } from './OrRadioGroup-cae1897c.js';
|
|
79
79
|
export { s as OrRadioV3 } from './OrRadio-02e0d111.js';
|
|
80
80
|
export { s as OrSearch } from './OrSearch-2800e9bf.js';
|
|
81
|
-
export { s as OrSearchV3 } from './OrSearch-
|
|
81
|
+
export { s as OrSearchV3 } from './OrSearch-bc259374.js';
|
|
82
82
|
export { s as OrSegmentedControlV3, S as SegmentedControlSize } from './OrSegmentedControl-4c4fff7b.js';
|
|
83
83
|
export { s as OrSelect } from './OrSelect-9520d6e6.js';
|
|
84
|
-
export { s as OrSelectV3 } from './OrSelect-
|
|
84
|
+
export { s as OrSelectV3 } from './OrSelect-a7d3c84d.js';
|
|
85
85
|
export { s as OrSidebar, O as OrSidebarSide } from './OrSidebar-aaf73310.js';
|
|
86
|
-
export { s as OrSidebarV3 } from './OrSidebar-
|
|
87
|
-
export { O as OrSidebarPlacement } from './OrSidebarCollapseButton-
|
|
86
|
+
export { s as OrSidebarV3 } from './OrSidebar-8837a93e.js';
|
|
87
|
+
export { O as OrSidebarPlacement } from './OrSidebarCollapseButton-f44951ac.js';
|
|
88
88
|
export { s as OrSkeletonCircle } from './OrSkeletonCircle-66e175a0.js';
|
|
89
89
|
export { s as OrSkeletonRect } from './OrSkeletonRect-c694574e.js';
|
|
90
90
|
export { s as OrSkeletonText } from './OrSkeletonText-9a800de4.js';
|
|
@@ -93,7 +93,7 @@ export { s as OrSkeletonCircleV3 } from './OrSkeletonCircle-1eae069b.js';
|
|
|
93
93
|
export { s as OrSkeletonRectV3 } from './OrSkeletonRect-ba5df861.js';
|
|
94
94
|
export { s as OrSkeletonTextV3 } from './OrSkeletonText-3c3207d0.js';
|
|
95
95
|
export { s as OrSlider } from './OrSlider-b7bd588e.js';
|
|
96
|
-
export { s as OrSortingV3 } from './OrSorting-
|
|
96
|
+
export { s as OrSortingV3 } from './OrSorting-6baec1ab.js';
|
|
97
97
|
export { s as OrStepper } from './OrStepper-4943002c.js';
|
|
98
98
|
export { s as OrSwitch } from './OrSwitch-fb864132.js';
|
|
99
99
|
export { s as OrSwitchV3 } from './OrSwitch-1ac1bfcd.js';
|
|
@@ -101,25 +101,25 @@ export { s as OrTab } from './OrTab-d8d4e871.js';
|
|
|
101
101
|
export { s as OrTabHeaderItem } from './OrTabHeaderItem-c2af7ca3.js';
|
|
102
102
|
export { s as OrTabV3 } from './OrTab-2d567d8e.js';
|
|
103
103
|
export { s as OrTabs } from './OrTabs-3da3ea89.js';
|
|
104
|
-
export { s as OrTabsV3, T as TabsVariant } from './OrTabs-
|
|
104
|
+
export { s as OrTabsV3, T as TabsVariant } from './OrTabs-2ab1aefa.js';
|
|
105
105
|
export { s as OrTag } from './OrTag-1b3b1296.js';
|
|
106
|
-
export { s as OrTagInputV3 } from './OrTagInput-
|
|
107
|
-
export { s as OrTagV3, a as TagColor, T as TagVariant } from './OrTag-
|
|
108
|
-
export { s as OrTagsV3, T as TagsOverflow } from './OrTags-
|
|
106
|
+
export { s as OrTagInputV3 } from './OrTagInput-ccb72239.js';
|
|
107
|
+
export { s as OrTagV3, a as TagColor, T as TagVariant } from './OrTag-2a3d7293.js';
|
|
108
|
+
export { s as OrTagsV3, T as TagsOverflow } from './OrTags-69e90412.js';
|
|
109
109
|
export { s as OrTeleport } from './OrTeleport.vue3-9bce0c02.js';
|
|
110
110
|
export { s as OrTeleportV3 } from './OrTeleport.vue3-8099178c.js';
|
|
111
111
|
export { s as OrTextV3 } from './OrText-d54c951d.js';
|
|
112
112
|
export { s as OrTextarea } from './OrTextarea-7a753c1a.js';
|
|
113
113
|
export { s as OrTextareaV3 } from './OrTextarea-aa1cf564.js';
|
|
114
114
|
export { s as OrTextbox, T as TextboxTypes } from './OrTextbox-cb6762c8.js';
|
|
115
|
-
export { s as OrTimePickerV3 } from './OrTimePicker-
|
|
115
|
+
export { s as OrTimePickerV3 } from './OrTimePicker-a3870a62.js';
|
|
116
116
|
export { s as OrToast, a as OrToastContainer } from './OrToastContainer-d6f117e2.js';
|
|
117
117
|
export { P as PositionsX, b as PositionsY, c as ToastType, T as TransitionType, a as useQueue, u as useToast } from './useToast-05a9c81b.js';
|
|
118
|
-
export { a as OrToastContainerV3, s as OrToastV3, t as TypesV3 } from './types-
|
|
118
|
+
export { a as OrToastContainerV3, s as OrToastV3, t as TypesV3 } from './types-c4c1e2cc.js';
|
|
119
119
|
export { p as PropsV3, a as useQueueV3, u as useToastV3 } from './useToast-5aa9dc05.js';
|
|
120
120
|
export { s as OrTooltip } from './OrTooltip-7ac03028.js';
|
|
121
121
|
export { s as OrTooltipContent } from './OrTooltipContent-c0042844.js';
|
|
122
|
-
export { s as OrTooltipV3 } from './OrTooltip-
|
|
122
|
+
export { s as OrTooltipV3 } from './OrTooltip-5bf6890a.js';
|
|
123
123
|
export { s as OrTreeV3, T as TreeNodeDropPosition } from './OrTree-a0e57f4e.js';
|
|
124
124
|
export { D as DropdownClose, a as DropdownOpen } from './dropdown-open-06d651cf.js';
|
|
125
125
|
export { u as useControlAttributes, a as useIdAttribute } from './useIdAttribute-859439f0.js';
|
|
@@ -152,7 +152,7 @@ import '@codemirror/language';
|
|
|
152
152
|
import '@lezer/highlight';
|
|
153
153
|
import '@vueuse/math';
|
|
154
154
|
import '@floating-ui/dom';
|
|
155
|
-
import './OrDateTimePickerPopoverHeader-
|
|
155
|
+
import './OrDateTimePickerPopoverHeader-03ae7d09.js';
|
|
156
156
|
import 'lodash/padStart';
|
|
157
157
|
import 'lodash/cloneDeep';
|
|
158
158
|
import 'lodash/isEqual';
|
|
@@ -6,7 +6,7 @@ import '@onereach/styles/tailwind/plugins/core';
|
|
|
6
6
|
import '@onereach/styles/tailwind.config.json';
|
|
7
7
|
import { s as script$4 } from './OrTeleport.vue3-8099178c.js';
|
|
8
8
|
import { T as ToastType, P as PositionsX, b as PositionsY, c as TransitionType, d as useToastEventBus, a as useQueue } from './useToast-5aa9dc05.js';
|
|
9
|
-
import { s as script$2 } from './OrIconButton-
|
|
9
|
+
import { s as script$2 } from './OrIconButton-a69c7775.js';
|
|
10
10
|
import { s as script$3 } from './OrLoader-b79022da.js';
|
|
11
11
|
import { resolveComponent, openBlock, createElementBlock, normalizeClass, renderSlot, createCommentVNode, createVNode, createElementVNode, toDisplayString, createBlock, withModifiers, withCtx, TransitionGroup, Fragment, renderList, mergeProps } from 'vue';
|
|
12
12
|
import { s as styleInject } from './style-inject.es-4c6f2515.js';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@onereach/ui-components",
|
|
3
|
-
"version": "6.1.
|
|
3
|
+
"version": "6.1.4",
|
|
4
4
|
"npmUnpacked": "4.15.2",
|
|
5
5
|
"description": "Vue components library for v2/3",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"@codemirror/lang-javascript": "6.1.8",
|
|
39
39
|
"@codemirror/lang-json": "6.0.1",
|
|
40
40
|
"@codemirror/lang-markdown": "6.1.1",
|
|
41
|
-
"@floating-ui/dom": "
|
|
41
|
+
"@floating-ui/dom": "1.4.2",
|
|
42
42
|
"@onereach/styles": "^4.0.0",
|
|
43
43
|
"@types/lodash": "4.14.173",
|
|
44
44
|
"@types/sortablejs": "1.10.7",
|
|
@@ -157,5 +157,5 @@
|
|
|
157
157
|
},
|
|
158
158
|
"./package.json": "./package.json"
|
|
159
159
|
},
|
|
160
|
-
"gitHead": "
|
|
160
|
+
"gitHead": "01a78f3689604f2071254d6207404ea28d89c1d6"
|
|
161
161
|
}
|
|
@@ -9,6 +9,7 @@
|
|
|
9
9
|
<div
|
|
10
10
|
ref="root"
|
|
11
11
|
v-bind="$attrs"
|
|
12
|
+
:style="floatingStyles"
|
|
12
13
|
:class="rootStyles"
|
|
13
14
|
>
|
|
14
15
|
<template v-if="disableDefaultStyles">
|
|
@@ -38,15 +39,15 @@
|
|
|
38
39
|
</template>
|
|
39
40
|
|
|
40
41
|
<script lang="ts">
|
|
41
|
-
import { ReferenceElement, autoUpdate,
|
|
42
|
+
import { ReferenceElement, autoUpdate, size, flip, hide, offset as offsetMiddleware, shift } from '@floating-ui/dom';
|
|
42
43
|
import { MaybeElementRef, onClickOutside } from '@vueuse/core';
|
|
43
|
-
import { PropType, computed, defineComponent, ref, toRef,
|
|
44
|
+
import { PropType, computed, defineComponent, ref, toRef, toRefs } from 'vue-demi';
|
|
44
45
|
import { useElevation, usePopoverState, useResponsive } from '../../hooks';
|
|
45
|
-
import { requestAF } from '../../utils/functions/dom';
|
|
46
46
|
import { OrBottomSheetV3 as OrBottomSheet } from '../or-bottom-sheet-v3';
|
|
47
47
|
import { OrTeleportV3 as OrTeleport } from '../or-teleport-v3';
|
|
48
48
|
import { PopoverOffset, PopoverPlacement, PopoverVariant } from './props';
|
|
49
49
|
import { Popover, PopoverBody, PopoverBodyPlacements } from './styles';
|
|
50
|
+
import { useFloating } from './hooks/useFloating';
|
|
50
51
|
|
|
51
52
|
export default defineComponent({
|
|
52
53
|
components: {
|
|
@@ -131,6 +132,8 @@ export default defineComponent({
|
|
|
131
132
|
const bottomSheet = ref<InstanceType<typeof OrBottomSheet>>();
|
|
132
133
|
const bottomSheetRoot = computed(() => bottomSheet.value?.root);
|
|
133
134
|
|
|
135
|
+
const { trigger, placement, offset, fullWidth } = toRefs(props);
|
|
136
|
+
|
|
134
137
|
// Styles
|
|
135
138
|
const rootStyles = computed(() => [
|
|
136
139
|
'or-popover-v3',
|
|
@@ -140,64 +143,44 @@ export default defineComponent({
|
|
|
140
143
|
|
|
141
144
|
const bodyStyles = computed(() => [
|
|
142
145
|
...PopoverBody,
|
|
143
|
-
...PopoverBodyPlacements[
|
|
146
|
+
...PopoverBodyPlacements[placement.value],
|
|
144
147
|
]);
|
|
145
148
|
|
|
146
149
|
// State
|
|
147
150
|
const { state, open, close, toggle } = usePopoverState(toRef(props, 'isOpen'), context.emit);
|
|
148
151
|
|
|
149
|
-
const
|
|
150
|
-
|
|
152
|
+
const { floatingStyles, middlewareData } = useFloating(trigger, root, {
|
|
153
|
+
placement,
|
|
154
|
+
middleware: [
|
|
155
|
+
offsetMiddleware(offset.value),
|
|
156
|
+
shift(),
|
|
157
|
+
flip(),
|
|
158
|
+
hide(),
|
|
159
|
+
size({
|
|
160
|
+
apply({ rects }) {
|
|
161
|
+
if (fullWidth.value && root.value)
|
|
162
|
+
Object.assign(root.value.style, {
|
|
163
|
+
width: `${rects.reference.width}px`,
|
|
164
|
+
});
|
|
165
|
+
},
|
|
166
|
+
}),
|
|
167
|
+
],
|
|
168
|
+
whileElementsMounted(...args) {
|
|
169
|
+
return autoUpdate(...args, { animationFrame: true });
|
|
170
|
+
},
|
|
171
|
+
});
|
|
172
|
+
|
|
173
|
+
const isFlipped = computed(() => Boolean(middlewareData.value.flip?.index));
|
|
174
|
+
const isHidden = computed(() => Boolean(middlewareData.value.hide?.referenceHidden));
|
|
151
175
|
|
|
152
176
|
// Helpers
|
|
153
177
|
const { isDesktop, isMobile } = useResponsive(containerRoot);
|
|
154
178
|
|
|
155
|
-
// Effects
|
|
156
|
-
watchPostEffect(() => {
|
|
157
|
-
const rootElement = unref(root);
|
|
158
|
-
|
|
159
|
-
if (rootElement) {
|
|
160
|
-
const { trigger, placement } = props;
|
|
161
|
-
|
|
162
|
-
if (trigger) {
|
|
163
|
-
autoUpdate(trigger, rootElement, async () => {
|
|
164
|
-
const { x, y, middlewareData } = await computePosition(trigger, rootElement, {
|
|
165
|
-
placement,
|
|
166
|
-
|
|
167
|
-
middleware: [
|
|
168
|
-
offset(props.offset),
|
|
169
|
-
shift(),
|
|
170
|
-
flip(),
|
|
171
|
-
hide(),
|
|
172
|
-
],
|
|
173
|
-
});
|
|
174
|
-
|
|
175
|
-
const { width: triggerWidth } = trigger.getBoundingClientRect();
|
|
176
|
-
|
|
177
|
-
// this hack fixes the issue when popover triggers 'ResizeObserver loop limit exceeded' runtime error
|
|
178
|
-
// https://github.com/floating-ui/floating-ui/issues/1740#issuecomment-1563544849
|
|
179
|
-
requestAF(() => {
|
|
180
|
-
Object.assign(rootElement.style, {
|
|
181
|
-
left: `${x}px`,
|
|
182
|
-
top: `${y}px`,
|
|
183
|
-
visibility: middlewareData.hide!.referenceHidden ? 'hidden' : 'visible',
|
|
184
|
-
width: props.fullWidth ? `${triggerWidth}px` : '',
|
|
185
|
-
});
|
|
186
|
-
});
|
|
187
|
-
isFlipped.value = Boolean(middlewareData.flip?.index);
|
|
188
|
-
isHidden.value = Boolean(middlewareData.hide?.referenceHidden);
|
|
189
|
-
});
|
|
190
|
-
}
|
|
191
|
-
}
|
|
192
|
-
});
|
|
193
|
-
|
|
194
179
|
// #region Elevation
|
|
195
180
|
useElevation(root, state);
|
|
196
181
|
// #endregion
|
|
197
182
|
|
|
198
183
|
// #region Click Outside
|
|
199
|
-
const trigger = toRef(props, 'trigger') as MaybeElementRef;
|
|
200
|
-
|
|
201
184
|
onClickOutside(root, (event) => {
|
|
202
185
|
const path = event.composedPath() as Element[];
|
|
203
186
|
|
|
@@ -205,7 +188,7 @@ export default defineComponent({
|
|
|
205
188
|
close();
|
|
206
189
|
}
|
|
207
190
|
}, {
|
|
208
|
-
ignore: [trigger],
|
|
191
|
+
ignore: [(trigger as MaybeElementRef)],
|
|
209
192
|
});
|
|
210
193
|
// #endregion
|
|
211
194
|
|
|
@@ -216,6 +199,7 @@ export default defineComponent({
|
|
|
216
199
|
bottomSheetRoot,
|
|
217
200
|
rootStyles,
|
|
218
201
|
bodyStyles,
|
|
202
|
+
floatingStyles,
|
|
219
203
|
state,
|
|
220
204
|
isFlipped,
|
|
221
205
|
isHidden,
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
import type {
|
|
2
|
+
FloatingElement,
|
|
3
|
+
Middleware,
|
|
4
|
+
MiddlewareData,
|
|
5
|
+
Placement,
|
|
6
|
+
ReferenceElement,
|
|
7
|
+
Strategy,
|
|
8
|
+
} from '@floating-ui/dom';
|
|
9
|
+
import type { ComponentPublicInstance, Ref } from 'vue-demi';
|
|
10
|
+
|
|
11
|
+
export type MaybeReadonlyRef<T> = T | Readonly<Ref<T>>;
|
|
12
|
+
|
|
13
|
+
export type MaybeElement<T> = T | ComponentPublicInstance | null | undefined;
|
|
14
|
+
|
|
15
|
+
export type UseFloatingOptions<T extends ReferenceElement = ReferenceElement> =
|
|
16
|
+
{
|
|
17
|
+
/**
|
|
18
|
+
* Represents the open/close state of the floating element.
|
|
19
|
+
* @default true
|
|
20
|
+
*/
|
|
21
|
+
open?: MaybeReadonlyRef<boolean | undefined>;
|
|
22
|
+
/**
|
|
23
|
+
* Where to place the floating element relative to its reference element.
|
|
24
|
+
* @default 'bottom'
|
|
25
|
+
*/
|
|
26
|
+
placement?: MaybeReadonlyRef<Placement | undefined>;
|
|
27
|
+
/**
|
|
28
|
+
* The type of CSS position property to use.
|
|
29
|
+
* @default 'absolute'
|
|
30
|
+
*/
|
|
31
|
+
strategy?: MaybeReadonlyRef<Strategy | undefined>;
|
|
32
|
+
/**
|
|
33
|
+
* These are plain objects that modify the positioning coordinates in some fashion, or provide useful data for the consumer to use.
|
|
34
|
+
* @default undefined
|
|
35
|
+
*/
|
|
36
|
+
middleware?: MaybeReadonlyRef<Middleware[] | undefined>;
|
|
37
|
+
/**
|
|
38
|
+
* Whether to use `transform` instead of `top` and `left` styles to
|
|
39
|
+
* position the floating element (`floatingStyles`).
|
|
40
|
+
* @default true
|
|
41
|
+
*/
|
|
42
|
+
transform?: MaybeReadonlyRef<boolean | undefined>;
|
|
43
|
+
/**
|
|
44
|
+
* Callback to handle mounting/unmounting of the elements.
|
|
45
|
+
* @default undefined
|
|
46
|
+
*/
|
|
47
|
+
whileElementsMounted?: (
|
|
48
|
+
reference: T,
|
|
49
|
+
floating: FloatingElement,
|
|
50
|
+
update: () => void
|
|
51
|
+
) => () => void;
|
|
52
|
+
};
|
|
53
|
+
|
|
54
|
+
export type UseFloatingReturn = {
|
|
55
|
+
/**
|
|
56
|
+
* The x-coord of the floating element.
|
|
57
|
+
*/
|
|
58
|
+
x: Readonly<Ref<number>>;
|
|
59
|
+
/**
|
|
60
|
+
* The y-coord of the floating element.
|
|
61
|
+
*/
|
|
62
|
+
y: Readonly<Ref<number>>;
|
|
63
|
+
/**
|
|
64
|
+
* The stateful placement, which can be different from the initial `placement` passed as options.
|
|
65
|
+
*/
|
|
66
|
+
placement: Readonly<Ref<Placement>>;
|
|
67
|
+
/**
|
|
68
|
+
* The type of CSS position property to use.
|
|
69
|
+
*/
|
|
70
|
+
strategy: Readonly<Ref<Strategy>>;
|
|
71
|
+
/**
|
|
72
|
+
* Additional data from middleware.
|
|
73
|
+
*/
|
|
74
|
+
middlewareData: Readonly<Ref<MiddlewareData>>;
|
|
75
|
+
/**
|
|
76
|
+
* The boolean that let you know if the floating element has been positioned.
|
|
77
|
+
*/
|
|
78
|
+
isPositioned: Readonly<Ref<boolean>>;
|
|
79
|
+
/**
|
|
80
|
+
* CSS styles to apply to the floating element to position it.
|
|
81
|
+
*/
|
|
82
|
+
floatingStyles: Readonly<
|
|
83
|
+
Ref<{
|
|
84
|
+
position: Strategy;
|
|
85
|
+
top: string;
|
|
86
|
+
left: string;
|
|
87
|
+
transform?: string;
|
|
88
|
+
willChange?: string;
|
|
89
|
+
}>
|
|
90
|
+
>;
|
|
91
|
+
/**
|
|
92
|
+
* The function to update floating position manually.
|
|
93
|
+
*/
|
|
94
|
+
update: () => void;
|
|
95
|
+
};
|
|
96
|
+
|
|
97
|
+
|
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
import type { FloatingElement, MiddlewareData, ReferenceElement } from '@floating-ui/dom';
|
|
2
|
+
import { computePosition } from '@floating-ui/dom';
|
|
3
|
+
import { Ref, computed, getCurrentScope, onScopeDispose, ref, shallowReadonly, shallowRef, unref, watch } from 'vue-demi';
|
|
4
|
+
|
|
5
|
+
import type {
|
|
6
|
+
UseFloatingOptions,
|
|
7
|
+
UseFloatingReturn,
|
|
8
|
+
MaybeElement,
|
|
9
|
+
} from './types';
|
|
10
|
+
|
|
11
|
+
// https://github.com/floating-ui/floating-ui/blob/master/packages/vue/src/useFloating.ts
|
|
12
|
+
/**
|
|
13
|
+
* Computes the `x` and `y` coordinates that will place the floating element next to a reference element when it is given a certain CSS positioning strategy.
|
|
14
|
+
* @param reference The reference template ref.
|
|
15
|
+
* @param floating The floating template ref.
|
|
16
|
+
* @param options The floating options.
|
|
17
|
+
* @see https://floating-ui.com/docs/vue
|
|
18
|
+
*/
|
|
19
|
+
|
|
20
|
+
import type { ComponentPublicInstance } from 'vue-demi';
|
|
21
|
+
|
|
22
|
+
function roundByDPR(element: Element, value: number) {
|
|
23
|
+
const dpr = getDPR(element);
|
|
24
|
+
return Math.round(value * dpr) / dpr;
|
|
25
|
+
}
|
|
26
|
+
function getDPR(element: Element): number {
|
|
27
|
+
if (typeof window === 'undefined') {
|
|
28
|
+
return 1;
|
|
29
|
+
}
|
|
30
|
+
const win = element.ownerDocument.defaultView || window;
|
|
31
|
+
return win.devicePixelRatio || 1;
|
|
32
|
+
}
|
|
33
|
+
function unwrapElement<T>(element: MaybeElement<T>) {
|
|
34
|
+
return ((element as Exclude<MaybeElement<T>, T>)?.$el ?? element) as Exclude<
|
|
35
|
+
MaybeElement<T>,
|
|
36
|
+
ComponentPublicInstance
|
|
37
|
+
>;
|
|
38
|
+
}
|
|
39
|
+
export function useFloating<T extends ReferenceElement = ReferenceElement>(
|
|
40
|
+
reference: Readonly<Ref<MaybeElement<T>>>,
|
|
41
|
+
floating: Readonly<Ref<MaybeElement<FloatingElement>>>,
|
|
42
|
+
options: UseFloatingOptions<T> = {}
|
|
43
|
+
): UseFloatingReturn {
|
|
44
|
+
const whileElementsMountedOption = options.whileElementsMounted;
|
|
45
|
+
const openOption = computed(() => unref(options.open) ?? true);
|
|
46
|
+
const middlewareOption = computed(() => unref(options.middleware));
|
|
47
|
+
const placementOption = computed(() => unref(options.placement) ?? 'bottom');
|
|
48
|
+
const strategyOption = computed(() => unref(options.strategy) ?? 'absolute');
|
|
49
|
+
const transformOption = computed(() => unref(options.transform) ?? true);
|
|
50
|
+
const referenceElement = computed(() => unwrapElement(reference.value));
|
|
51
|
+
const floatingElement = computed(() => unwrapElement(floating.value));
|
|
52
|
+
const x = ref(0);
|
|
53
|
+
const y = ref(0);
|
|
54
|
+
const strategy = ref(strategyOption.value);
|
|
55
|
+
const placement = ref(placementOption.value);
|
|
56
|
+
const middlewareData = shallowRef<MiddlewareData>({});
|
|
57
|
+
const isPositioned = ref(false);
|
|
58
|
+
const floatingStyles = computed(() => {
|
|
59
|
+
const initialStyles = {
|
|
60
|
+
position: strategy.value,
|
|
61
|
+
left: '0',
|
|
62
|
+
top: '0',
|
|
63
|
+
};
|
|
64
|
+
|
|
65
|
+
if (!floatingElement.value) {
|
|
66
|
+
return initialStyles;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
const xVal = roundByDPR(floatingElement.value, x.value);
|
|
70
|
+
const yVal = roundByDPR(floatingElement.value, y.value);
|
|
71
|
+
|
|
72
|
+
if (transformOption.value) {
|
|
73
|
+
return {
|
|
74
|
+
...initialStyles,
|
|
75
|
+
transform: `translate(${xVal}px, ${yVal}px)`,
|
|
76
|
+
...(getDPR(floatingElement.value) >= 1.5 && { willChange: 'transform' }),
|
|
77
|
+
};
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
return {
|
|
81
|
+
position: strategy.value,
|
|
82
|
+
left: `${xVal}px`,
|
|
83
|
+
top: `${yVal}px`,
|
|
84
|
+
};
|
|
85
|
+
});
|
|
86
|
+
|
|
87
|
+
let whileElementsMountedCleanup: (() => void) | undefined;
|
|
88
|
+
|
|
89
|
+
function update() {
|
|
90
|
+
if (referenceElement.value == null || floatingElement.value == null) {
|
|
91
|
+
return;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
computePosition(referenceElement.value, floatingElement.value, {
|
|
95
|
+
middleware: middlewareOption.value,
|
|
96
|
+
placement: placementOption.value,
|
|
97
|
+
strategy: strategyOption.value,
|
|
98
|
+
}).then((position) => {
|
|
99
|
+
x.value = position.x;
|
|
100
|
+
y.value = position.y;
|
|
101
|
+
strategy.value = position.strategy;
|
|
102
|
+
placement.value = position.placement;
|
|
103
|
+
middlewareData.value = position.middlewareData;
|
|
104
|
+
isPositioned.value = true;
|
|
105
|
+
});
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
function cleanup() {
|
|
109
|
+
if (typeof whileElementsMountedCleanup === 'function') {
|
|
110
|
+
whileElementsMountedCleanup();
|
|
111
|
+
whileElementsMountedCleanup = undefined;
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
|
|
115
|
+
function attach() {
|
|
116
|
+
cleanup();
|
|
117
|
+
|
|
118
|
+
if (whileElementsMountedOption === undefined) {
|
|
119
|
+
update();
|
|
120
|
+
return;
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
if (referenceElement.value != null && floatingElement.value != null) {
|
|
124
|
+
whileElementsMountedCleanup = whileElementsMountedOption(
|
|
125
|
+
referenceElement.value,
|
|
126
|
+
floatingElement.value,
|
|
127
|
+
update
|
|
128
|
+
);
|
|
129
|
+
return;
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
function reset() {
|
|
134
|
+
if (!openOption.value) {
|
|
135
|
+
isPositioned.value = false;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
watch([middlewareOption, placementOption, strategyOption], update, {
|
|
140
|
+
flush: 'sync',
|
|
141
|
+
});
|
|
142
|
+
watch([referenceElement, floatingElement], attach, { flush: 'sync' });
|
|
143
|
+
watch(openOption, reset, { flush: 'sync' });
|
|
144
|
+
|
|
145
|
+
if (getCurrentScope()) {
|
|
146
|
+
onScopeDispose(cleanup);
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
return {
|
|
150
|
+
x: shallowReadonly(x),
|
|
151
|
+
y: shallowReadonly(y),
|
|
152
|
+
strategy: shallowReadonly(strategy),
|
|
153
|
+
placement: shallowReadonly(placement),
|
|
154
|
+
middlewareData: shallowReadonly(middlewareData),
|
|
155
|
+
isPositioned: shallowReadonly(isPositioned),
|
|
156
|
+
floatingStyles,
|
|
157
|
+
update,
|
|
158
|
+
};
|
|
159
|
+
}
|