hys-ui 0.1.1 → 0.3.0
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/CHANGELOG.md +149 -0
- package/README.md +17 -1
- package/dist/components/HysAccordion/HysAccordion.vue.js +1 -1
- package/dist/components/HysAccordion/HysAccordion2.vue.js +181 -47
- package/dist/components/HysAlert/HysAlert.vue.js +5 -54
- package/dist/components/HysAlert/HysAlert2.vue.js +159 -2
- package/dist/components/HysAutocomplete/HysAutocomplete.vue.js +7 -0
- package/dist/components/HysAutocomplete/HysAutocomplete2.vue.js +639 -0
- package/dist/components/HysAvatar/HysAvatar.vue.js +5 -35
- package/dist/components/HysAvatar/HysAvatar2.vue.js +221 -2
- package/dist/components/HysAvatarGroup/HysAvatarGroup.vue.js +7 -0
- package/dist/components/HysAvatarGroup/HysAvatarGroup2.vue.js +256 -0
- package/dist/components/HysBadge/HysBadge.vue.js +2 -2
- package/dist/components/HysBadge/HysBadge2.vue.js +154 -27
- package/dist/components/HysBreadcrumb/HysBreadcrumb.vue.js +5 -38
- package/dist/components/HysBreadcrumb/HysBreadcrumb2.vue.js +288 -2
- package/dist/components/HysButton/HysButton.vue.js +2 -2
- package/dist/components/HysButton/HysButton2.vue.js +29 -28
- package/dist/components/HysCalendar/HysCalendar.vue.js +5 -92
- package/dist/components/HysCalendar/HysCalendar2.vue.js +815 -2
- package/dist/components/HysCard/HysCard.vue.js +2 -2
- package/dist/components/HysCard/HysCard2.vue.js +175 -42
- package/dist/components/HysCascader/HysCascader.vue.js +5 -194
- package/dist/components/HysCascader/HysCascader2.vue.js +773 -2
- package/dist/components/HysCascader/HysCascaderColumn.vue.js +7 -0
- package/dist/components/HysCascader/HysCascaderColumn2.vue.js +232 -0
- package/dist/components/HysCheckbox/HysCheckbox.vue.js +3 -3
- package/dist/components/HysCheckbox/HysCheckbox2.vue.js +180 -65
- package/dist/components/HysCheckboxGroup/HysCheckboxGroup.vue.js +7 -0
- package/dist/components/HysCheckboxGroup/HysCheckboxGroup2.vue.js +237 -0
- package/dist/components/HysColorPicker/HysColorPanel.vue.js +7 -0
- package/dist/components/HysColorPicker/HysColorPanel2.vue.js +238 -0
- package/dist/components/HysColorPicker/HysColorPicker.vue.js +1 -1
- package/dist/components/HysColorPicker/HysColorPicker2.vue.js +239 -216
- package/dist/components/HysCommandPalette/HysCommandPalette.vue.js +90 -76
- package/dist/components/HysContextMenu/HysContextMenu.vue.js +5 -89
- package/dist/components/HysContextMenu/HysContextMenu2.vue.js +247 -2
- package/dist/components/HysContextMenu/HysMenuPanel.vue.js +7 -0
- package/dist/components/HysContextMenu/HysMenuPanel2.vue.js +208 -0
- package/dist/components/HysContextMenu/HysMenuSlot.js +10 -0
- package/dist/components/HysDataGrid/HysDataGrid.vue.js +1 -1
- package/dist/components/HysDataGrid/HysDataGrid2.vue.js +1019 -563
- package/dist/components/HysDatePicker/HysDatePicker.vue.js +270 -139
- package/dist/components/HysDatePicker/HysDatePickerControl.vue.js +7 -0
- package/dist/components/HysDatePicker/HysDatePickerControl2.vue.js +820 -0
- package/dist/components/HysDatePicker/HysDatePickerPanel.vue.js +7 -0
- package/dist/components/HysDatePicker/HysDatePickerPanel2.vue.js +357 -0
- package/dist/components/HysDateRangePicker/HysDateRangePicker.vue.js +270 -158
- package/dist/components/HysDivider/HysDivider.vue.js +2 -2
- package/dist/components/HysDivider/HysDivider2.vue.js +33 -13
- package/dist/components/HysDrawer/HysDrawer.vue.js +1 -1
- package/dist/components/HysDrawer/HysDrawer2.vue.js +434 -84
- package/dist/components/HysEmpty/HysEmpty.vue.js +5 -41
- package/dist/components/HysEmpty/HysEmpty2.vue.js +181 -2
- package/dist/components/HysFileManager/HysFileManager.vue.js +3 -3
- package/dist/components/HysFileManager/HysFileManager2.vue.js +43 -42
- package/dist/components/HysForm/HysForm.vue.js +3 -3
- package/dist/components/HysForm/HysForm2.vue.js +578 -92
- package/dist/components/HysFormItem/HysFormItem.vue.js +5 -85
- package/dist/components/HysFormItem/HysFormItem2.vue.js +528 -2
- package/dist/components/HysGantt/HysGantt.vue.js +1 -1
- package/dist/components/HysGantt/HysGantt2.vue.js +1380 -268
- package/dist/components/HysInput/HysInput.vue.js +2 -2
- package/dist/components/HysInput/HysInput2.vue.js +467 -120
- package/dist/components/HysMention/HysMention.vue.js +2 -2
- package/dist/components/HysMention/HysMention2.vue.js +122 -109
- package/dist/components/HysModal/HysModal.vue.js +2 -2
- package/dist/components/HysModal/HysModal2.vue.js +490 -85
- package/dist/components/HysNumberInput/HysNumberInput.vue.js +2 -2
- package/dist/components/HysNumberInput/HysNumberInput2.vue.js +561 -79
- package/dist/components/HysOrgTree/HysOrgTree.vue.js +29 -26
- package/dist/components/HysPagination/HysPagination.vue.js +1 -1
- package/dist/components/HysPagination/HysPagination2.vue.js +2 -0
- package/dist/components/HysPermissionMatrix/HysPermissionMatrix.vue.js +2 -2
- package/dist/components/HysPermissionMatrix/HysPermissionMatrix2.vue.js +52 -51
- package/dist/components/HysPopover/HysPopover.vue.js +5 -91
- package/dist/components/HysPopover/HysPopover2.vue.js +120 -2
- package/dist/components/HysProgress/HysProgress.vue.js +2 -2
- package/dist/components/HysProgress/HysProgress2.vue.js +319 -52
- package/dist/components/HysRadio/HysRadio.vue.js +7 -0
- package/dist/components/HysRadio/HysRadio2.vue.js +180 -0
- package/dist/components/HysRadioGroup/HysRadioGroup.vue.js +2 -2
- package/dist/components/HysRadioGroup/HysRadioGroup2.vue.js +190 -65
- package/dist/components/HysRating/HysRating.vue.js +1 -1
- package/dist/components/HysRating/HysRating2.vue.js +288 -68
- package/dist/components/HysRichTextEditor/HysRichTextEditor.vue.js +1 -1
- package/dist/components/HysRichTextEditor/HysRichTextEditor2.vue.js +70 -69
- package/dist/components/HysSearch/HysSearch.vue.js +37 -36
- package/dist/components/HysSegmented/HysSegmented.vue.js +5 -63
- package/dist/components/HysSegmented/HysSegmented2.vue.js +273 -2
- package/dist/components/HysSelect/HysSelect.vue.js +3 -2
- package/dist/components/HysSelect/HysSelect2.vue.js +999 -189
- package/dist/components/HysSkeleton/HysSkeleton.vue.js +2 -2
- package/dist/components/HysSkeleton/HysSkeleton2.vue.js +126 -29
- package/dist/components/HysSlider/HysSlider.vue.js +1 -1
- package/dist/components/HysSlider/HysSlider2.vue.js +536 -59
- package/dist/components/HysSlider/SliderTooltip.vue.js +7 -0
- package/dist/components/HysSlider/SliderTooltip2.vue.js +170 -0
- package/dist/components/HysSteps/HysSteps.vue.js +1 -1
- package/dist/components/HysSteps/HysSteps2.vue.js +110 -36
- package/dist/components/HysSwitch/HysSwitch.vue.js +2 -2
- package/dist/components/HysSwitch/HysSwitch2.vue.js +232 -50
- package/dist/components/HysTable/HysTable.vue.js +1 -1
- package/dist/components/HysTable/HysTable2.vue.js +1494 -88
- package/dist/components/HysTable/HysTableFilterOptions.vue.js +7 -0
- package/dist/components/HysTable/HysTableFilterOptions2.vue.js +133 -0
- package/dist/components/HysTabs/HysTabs.vue.js +2 -2
- package/dist/components/HysTabs/HysTabs2.vue.js +262 -68
- package/dist/components/HysTagInput/HysTagInput.vue.js +5 -81
- package/dist/components/HysTagInput/HysTagInput2.vue.js +396 -2
- package/dist/components/HysTextarea/HysTextarea.vue.js +138 -77
- package/dist/components/HysTimeline/HysTimeline.vue.js +2 -2
- package/dist/components/HysTimeline/HysTimeline2.vue.js +243 -24
- package/dist/components/HysTooltip/HysTooltip.vue.js +5 -64
- package/dist/components/HysTooltip/HysTooltip2.vue.js +110 -2
- package/dist/components/HysTour/HysTour.vue.js +46 -42
- package/dist/components/HysTransfer/HysTransfer.vue.js +5 -223
- package/dist/components/HysTransfer/HysTransfer2.vue.js +446 -2
- package/dist/components/HysTransfer/HysTransferPanel.vue.js +7 -0
- package/dist/components/HysTransfer/HysTransferPanel2.vue.js +503 -0
- package/dist/components/HysTree/HysTree.vue.js +2 -3
- package/dist/components/HysTree/HysTree2.vue.js +651 -301
- package/dist/components/HysTreeSelect/HysTreeSelect.vue.js +5 -136
- package/dist/components/HysTreeSelect/HysTreeSelect2.vue.js +570 -2
- package/dist/components/HysTreeSelect/HysTreeSelectPanel.vue.js +7 -0
- package/dist/components/HysTreeSelect/HysTreeSelectPanel2.vue.js +323 -0
- package/dist/components/HysUpload/HysUpload.vue.js +2 -2
- package/dist/components/HysUpload/HysUpload2.vue.js +459 -124
- package/dist/components/HysVirtualTable/HysVirtualTable.vue.js +5 -94
- package/dist/components/HysVirtualTable/HysVirtualTable2.vue.js +656 -2
- package/dist/composables/autocomplete.js +50 -0
- package/dist/composables/avatar.js +57 -0
- package/dist/composables/calendar.js +96 -0
- package/dist/composables/cascader.js +79 -0
- package/dist/composables/choice.js +38 -0
- package/dist/composables/choiceModel.js +67 -0
- package/dist/composables/color.js +97 -0
- package/dist/composables/dataGrid.js +68 -0
- package/dist/composables/datePicker.js +227 -0
- package/dist/composables/drawer.js +17 -0
- package/dist/composables/feedback.js +14 -0
- package/dist/composables/formContext.js +92 -7
- package/dist/composables/formLayout.js +57 -0
- package/dist/composables/formValidation.js +240 -0
- package/dist/composables/ganttConflicts.js +143 -0
- package/dist/composables/menu.js +96 -0
- package/dist/composables/modal.js +14 -0
- package/dist/composables/numberInput.js +91 -0
- package/dist/composables/overlayManager.js +48 -18
- package/dist/composables/progress.js +94 -0
- package/dist/composables/rating.js +16 -0
- package/dist/composables/selectOptions.js +54 -0
- package/dist/composables/table.js +150 -0
- package/dist/composables/tagInput.js +16 -0
- package/dist/composables/textInput.js +34 -0
- package/dist/composables/timeline.js +19 -0
- package/dist/composables/transfer.js +65 -0
- package/dist/composables/tree.js +118 -0
- package/dist/composables/treeSelect.js +71 -0
- package/dist/composables/upload.js +55 -0
- package/dist/composables/uploadRequest.js +58 -0
- package/dist/composables/useAlert.js +124 -0
- package/dist/composables/useCascader.js +438 -0
- package/dist/composables/useColorPicker.js +402 -0
- package/dist/composables/useContextMenu.js +514 -0
- package/dist/composables/useDataGridRemote.js +67 -0
- package/dist/composables/useDatePicker.js +425 -0
- package/dist/composables/useDialog.js +86 -43
- package/dist/composables/useDrawerPush.js +33 -0
- package/dist/composables/useDrawerResize.js +221 -0
- package/dist/composables/useFloating.js +136 -56
- package/dist/composables/useGanttDependencies.js +306 -0
- package/dist/composables/useGanttHistory.js +157 -0
- package/dist/composables/useGanttLabelResize.js +100 -0
- package/dist/composables/useHysModal.js +185 -0
- package/dist/composables/useModal.js +295 -0
- package/dist/composables/useModalInteraction.js +394 -0
- package/dist/composables/usePopupSurface.js +458 -0
- package/dist/composables/useTable.js +474 -0
- package/dist/composables/useTagInput.js +313 -0
- package/dist/composables/useTextareaSize.js +72 -0
- package/dist/composables/useTransfer.js +257 -0
- package/dist/composables/useTransferMotion.js +185 -0
- package/dist/composables/useTree.js +439 -0
- package/dist/composables/useTreeSelect.js +361 -0
- package/dist/composables/useUpload.js +472 -0
- package/dist/composables/useUploadModel.js +65 -0
- package/dist/composables/useUploadRequests.js +266 -0
- package/dist/composables/useVirtualTableLayout.js +277 -0
- package/dist/composables/virtualTable.js +43 -0
- package/dist/index.js +152 -139
- package/dist/internal/PopupReference.js +39 -0
- package/dist/internal/PopupSurfacePanel.vue.js +7 -0
- package/dist/internal/PopupSurfacePanel2.vue.js +92 -0
- package/dist/motion/PopupMotion.js +105 -0
- package/dist/motion/popup.js +10 -0
- package/dist/style.css +1 -1
- package/dist/types/components/HysAccordion/HysAccordion.vue.d.ts +61 -22
- package/dist/types/components/HysAlert/HysAlert.vue.d.ts +32 -22
- package/dist/types/components/HysAutocomplete/HysAutocomplete.vue.d.ts +201 -0
- package/dist/types/components/HysAvatar/HysAvatar.vue.d.ts +28 -15
- package/dist/types/components/HysAvatarGroup/HysAvatarGroup.vue.d.ts +104 -0
- package/dist/types/components/HysBadge/HysBadge.vue.d.ts +41 -4
- package/dist/types/components/HysBreadcrumb/HysBreadcrumb.vue.d.ts +71 -20
- package/dist/types/components/HysButton/HysButton.vue.d.ts +0 -1
- package/dist/types/components/HysCalendar/HysCalendar.vue.d.ts +120 -31
- package/dist/types/components/HysCard/HysCard.vue.d.ts +55 -7
- package/dist/types/components/HysCascader/HysCascader.vue.d.ts +129 -41
- package/dist/types/components/HysCascader/HysCascaderColumn.vue.d.ts +55 -0
- package/dist/types/components/HysCheckbox/HysCheckbox.vue.d.ts +50 -39
- package/dist/types/components/HysCheckboxGroup/HysCheckboxGroup.vue.d.ts +73 -0
- package/dist/types/components/HysColorPicker/HysColorPanel.vue.d.ts +58 -0
- package/dist/types/components/HysColorPicker/HysColorPicker.vue.d.ts +63 -10
- package/dist/types/components/HysCommandPalette/HysCommandPalette.vue.d.ts +2 -1
- package/dist/types/components/HysContextMenu/HysContextMenu.vue.d.ts +50 -34
- package/dist/types/components/HysContextMenu/HysMenuPanel.vue.d.ts +79 -0
- package/dist/types/components/HysContextMenu/HysMenuSlot.d.ts +8 -0
- package/dist/types/components/HysDataGrid/HysDataGrid.vue.d.ts +65 -118
- package/dist/types/components/HysDatePicker/HysDatePicker.vue.d.ts +66 -14
- package/dist/types/components/HysDatePicker/HysDatePickerControl.vue.d.ts +90 -0
- package/dist/types/components/HysDatePicker/HysDatePickerPanel.vue.d.ts +93 -0
- package/dist/types/components/HysDateRangePicker/HysDateRangePicker.vue.d.ts +66 -14
- package/dist/types/components/HysDivider/HysDivider.vue.d.ts +8 -3
- package/dist/types/components/HysDrawer/HysDrawer.vue.d.ts +92 -35
- package/dist/types/components/HysEmpty/HysEmpty.vue.d.ts +24 -20
- package/dist/types/components/HysForm/HysForm.vue.d.ts +110 -18
- package/dist/types/components/HysFormItem/HysFormItem.vue.d.ts +108 -2
- package/dist/types/components/HysGantt/HysGantt.vue.d.ts +84 -5
- package/dist/types/components/HysInput/HysInput.vue.d.ts +52 -29
- package/dist/types/components/HysMention/HysMention.vue.d.ts +4 -3
- package/dist/types/components/HysModal/HysModal.vue.d.ts +111 -34
- package/dist/types/components/HysNumberInput/HysNumberInput.vue.d.ts +93 -35
- package/dist/types/components/HysOrgTree/HysOrgTree.vue.d.ts +1 -0
- package/dist/types/components/HysPagination/HysPagination.vue.d.ts +1 -1
- package/dist/types/components/HysPermissionMatrix/HysPermissionMatrix.vue.d.ts +2 -2
- package/dist/types/components/HysPopover/HysPopover.vue.d.ts +41 -29
- package/dist/types/components/HysProgress/HysProgress.vue.d.ts +18 -24
- package/dist/types/components/HysRadio/HysRadio.vue.d.ts +56 -0
- package/dist/types/components/HysRadioGroup/HysRadioGroup.vue.d.ts +34 -12
- package/dist/types/components/HysRating/HysRating.vue.d.ts +85 -5
- package/dist/types/components/HysResizablePanel/HysResizablePanel.vue.d.ts +2 -2
- package/dist/types/components/HysRichTextEditor/HysRichTextEditor.vue.d.ts +4 -4
- package/dist/types/components/HysSearch/HysSearch.vue.d.ts +2 -2
- package/dist/types/components/HysSegmented/HysSegmented.vue.d.ts +64 -32
- package/dist/types/components/HysSelect/HysSelect.vue.d.ts +131 -22
- package/dist/types/components/HysSkeleton/HysSkeleton.vue.d.ts +30 -2
- package/dist/types/components/HysSlider/HysSlider.vue.d.ts +69 -11
- package/dist/types/components/HysSlider/SliderTooltip.vue.d.ts +24 -0
- package/dist/types/components/HysSplitPane/HysSplitPane.vue.d.ts +3 -3
- package/dist/types/components/HysSteps/HysSteps.vue.d.ts +64 -9
- package/dist/types/components/HysSwitch/HysSwitch.vue.d.ts +76 -17
- package/dist/types/components/HysTable/HysTable.vue.d.ts +206 -32
- package/dist/types/components/HysTable/HysTableFilterOptions.vue.d.ts +18 -0
- package/dist/types/components/HysTabs/HysTabs.vue.d.ts +76 -23
- package/dist/types/components/HysTagInput/HysTagInput.vue.d.ts +50 -28
- package/dist/types/components/HysTextarea/HysTextarea.vue.d.ts +44 -27
- package/dist/types/components/HysTimeline/HysTimeline.vue.d.ts +19 -32
- package/dist/types/components/HysToast/HysToast.vue.d.ts +3 -3
- package/dist/types/components/HysTooltip/HysTooltip.vue.d.ts +39 -19
- package/dist/types/components/HysTour/HysTour.vue.d.ts +4 -3
- package/dist/types/components/HysTransfer/HysTransfer.vue.d.ts +55 -40
- package/dist/types/components/HysTransfer/HysTransferPanel.vue.d.ts +107 -0
- package/dist/types/components/HysTree/HysTree.vue.d.ts +140 -73
- package/dist/types/components/HysTreeSelect/HysTreeSelect.vue.d.ts +102 -23
- package/dist/types/components/HysTreeSelect/HysTreeSelectPanel.vue.d.ts +56 -0
- package/dist/types/components/HysUpload/HysUpload.vue.d.ts +55 -67
- package/dist/types/components/HysVirtualTable/HysVirtualTable.vue.d.ts +71 -40
- package/dist/types/composables/autocomplete.d.ts +109 -0
- package/dist/types/composables/avatar.d.ts +73 -0
- package/dist/types/composables/calendar.d.ts +66 -0
- package/dist/types/composables/cascader.d.ts +195 -0
- package/dist/types/composables/choice.d.ts +110 -0
- package/dist/types/composables/choiceModel.d.ts +11 -0
- package/dist/types/composables/color.d.ts +97 -0
- package/dist/types/composables/dataGrid.d.ts +100 -0
- package/dist/types/composables/datePicker.d.ts +250 -0
- package/dist/types/composables/drawer.d.ts +102 -0
- package/dist/types/composables/feedback.d.ts +98 -0
- package/dist/types/composables/formContext.d.ts +135 -8
- package/dist/types/composables/formLayout.d.ts +11 -0
- package/dist/types/composables/formValidation.d.ts +13 -0
- package/dist/types/composables/gantt.d.ts +68 -0
- package/dist/types/composables/ganttConflicts.d.ts +30 -0
- package/dist/types/composables/menu.d.ts +183 -0
- package/dist/types/composables/modal.d.ts +183 -0
- package/dist/types/composables/numberInput.d.ts +45 -0
- package/dist/types/composables/overlayManager.d.ts +7 -3
- package/dist/types/composables/popupSurface.d.ts +83 -0
- package/dist/types/composables/progress.d.ts +92 -0
- package/dist/types/composables/rating.d.ts +18 -0
- package/dist/types/composables/segmented.d.ts +15 -0
- package/dist/types/composables/selectOptions.d.ts +46 -0
- package/dist/types/composables/slider.d.ts +21 -0
- package/dist/types/composables/table.d.ts +312 -0
- package/dist/types/composables/tagInput.d.ts +96 -0
- package/dist/types/composables/textInput.d.ts +76 -0
- package/dist/types/composables/timeline.d.ts +82 -0
- package/dist/types/composables/transfer.d.ts +187 -0
- package/dist/types/composables/tree.d.ts +240 -0
- package/dist/types/composables/treeSelect.d.ts +170 -0
- package/dist/types/composables/upload.d.ts +202 -0
- package/dist/types/composables/uploadRequest.d.ts +3 -0
- package/dist/types/composables/useAlert.d.ts +21 -0
- package/dist/types/composables/useCascader.d.ts +162 -0
- package/dist/types/composables/useColorPicker.d.ts +101 -0
- package/dist/types/composables/useContextMenu.d.ts +81 -0
- package/dist/types/composables/useDataGridRemote.d.ts +15 -0
- package/dist/types/composables/useDatePicker.d.ts +79 -0
- package/dist/types/composables/useDialog.d.ts +16 -3
- package/dist/types/composables/useDrawerPush.d.ts +6 -0
- package/dist/types/composables/useDrawerResize.d.ts +27 -0
- package/dist/types/composables/useFloating.d.ts +28 -6
- package/dist/types/composables/useGanttDependencies.d.ts +83 -0
- package/dist/types/composables/useGanttHistory.d.ts +42 -0
- package/dist/types/composables/useGanttLabelResize.d.ts +23 -0
- package/dist/types/composables/useHysModal.d.ts +44 -0
- package/dist/types/composables/useModal.d.ts +62 -0
- package/dist/types/composables/useModalInteraction.d.ts +27 -0
- package/dist/types/composables/usePopupSurface.d.ts +3341 -0
- package/dist/types/composables/useTable.d.ts +60 -0
- package/dist/types/composables/useTagInput.d.ts +66 -0
- package/dist/types/composables/useTextareaSize.d.ts +3 -0
- package/dist/types/composables/useTransfer.d.ts +58 -0
- package/dist/types/composables/useTransferMotion.d.ts +36 -0
- package/dist/types/composables/useTree.d.ts +77 -0
- package/dist/types/composables/useTreeSelect.d.ts +117 -0
- package/dist/types/composables/useUpload.d.ts +94 -0
- package/dist/types/composables/useUploadModel.d.ts +14 -0
- package/dist/types/composables/useUploadRequests.d.ts +38 -0
- package/dist/types/composables/useVirtualTableLayout.d.ts +51 -0
- package/dist/types/composables/virtualTable.d.ts +126 -0
- package/dist/types/index.d.ts +50 -9
- package/dist/types/internal/PopupReference.d.ts +18 -0
- package/dist/types/internal/PopupSurfacePanel.vue.d.ts +37 -0
- package/dist/types/motion/PopupMotion.d.ts +59 -0
- package/dist/types/motion/popup.d.ts +12 -0
- package/package.json +2 -1
package/dist/index.js
CHANGED
|
@@ -1,146 +1,159 @@
|
|
|
1
1
|
/* empty css */
|
|
2
|
-
import { default as
|
|
2
|
+
import { default as o } from "./components/HysAccordion/HysAccordion.vue.js";
|
|
3
3
|
import { default as s } from "./components/HysAlert/HysAlert.vue.js";
|
|
4
4
|
import { default as l } from "./components/HysAnimatedNumber/HysAnimatedNumber.vue.js";
|
|
5
|
-
import { default as m } from "./components/
|
|
6
|
-
import { default as u } from "./components/
|
|
7
|
-
import { default as y } from "./components/
|
|
8
|
-
import { default as i } from "./components/
|
|
9
|
-
import { default as
|
|
10
|
-
import { default as C } from "./components/
|
|
11
|
-
import { default as
|
|
12
|
-
import { default as P } from "./components/
|
|
13
|
-
import { default as k } from "./components/
|
|
14
|
-
import { default as
|
|
15
|
-
import { default as
|
|
16
|
-
import { default as
|
|
17
|
-
import { default as
|
|
18
|
-
import { default as
|
|
19
|
-
import { default as
|
|
20
|
-
import { default as z } from "./components/
|
|
21
|
-
import { default as K } from "./components/
|
|
22
|
-
import { default as O } from "./components/
|
|
23
|
-
import { default as j } from "./components/
|
|
24
|
-
import { default as Q } from "./components/
|
|
25
|
-
import { default as X } from "./components/
|
|
26
|
-
import { default as Z } from "./components/
|
|
27
|
-
import { default as $ } from "./components/
|
|
28
|
-
import { default as re } from "./components/
|
|
29
|
-
import { default as
|
|
30
|
-
import { default as se } from "./components/
|
|
31
|
-
import { default as le } from "./components/
|
|
32
|
-
import { default as me } from "./components/
|
|
33
|
-
import { default as ue } from "./components/
|
|
34
|
-
import { default as ye } from "./components/
|
|
35
|
-
import { default as ie } from "./components/
|
|
36
|
-
import { default as
|
|
37
|
-
import { default as Ce } from "./components/
|
|
38
|
-
import { default as
|
|
39
|
-
import { default as Pe } from "./components/
|
|
40
|
-
import { default as ke } from "./components/
|
|
41
|
-
import { default as
|
|
42
|
-
import { default as
|
|
43
|
-
import { default as
|
|
44
|
-
import { default as
|
|
45
|
-
import { default as
|
|
46
|
-
import { default as
|
|
47
|
-
import { default as ze } from "./components/
|
|
48
|
-
import { default as Ke } from "./components/
|
|
49
|
-
import { default as Oe } from "./components/
|
|
50
|
-
import { default as je } from "./components/
|
|
51
|
-
import { default as Qe } from "./components/
|
|
52
|
-
import { default as Xe } from "./components/
|
|
53
|
-
import { default as Ze } from "./components/
|
|
54
|
-
import { default as $e } from "./components/
|
|
55
|
-
import { default as rr } from "./components/
|
|
56
|
-
import { default as
|
|
57
|
-
import { default as sr } from "./components/
|
|
58
|
-
import { default as lr } from "./components/
|
|
59
|
-
import { default as mr } from "./components/
|
|
60
|
-
import { default as ur } from "./components/
|
|
61
|
-
import { default as yr } from "./components/
|
|
62
|
-
import { default as ir } from "./components/
|
|
63
|
-
import { default as
|
|
64
|
-
import { default as Cr } from "./components/
|
|
65
|
-
import { default as
|
|
66
|
-
import { default as Pr } from "./components/
|
|
67
|
-
import { default as kr } from "./components/
|
|
68
|
-
import { default as
|
|
69
|
-
import { default as
|
|
70
|
-
import { default as
|
|
71
|
-
import {
|
|
72
|
-
import {
|
|
5
|
+
import { default as m } from "./components/HysAutocomplete/HysAutocomplete.vue.js";
|
|
6
|
+
import { default as u } from "./components/HysAvatar/HysAvatar.vue.js";
|
|
7
|
+
import { default as y } from "./components/HysAvatarGroup/HysAvatarGroup.vue.js";
|
|
8
|
+
import { default as i } from "./components/HysBadge/HysBadge.vue.js";
|
|
9
|
+
import { default as c } from "./components/HysBreadcrumb/HysBreadcrumb.vue.js";
|
|
10
|
+
import { default as C } from "./components/HysButton/HysButton.vue.js";
|
|
11
|
+
import { default as g } from "./components/HysCalendar/HysCalendar.vue.js";
|
|
12
|
+
import { default as P } from "./components/HysCalendarNavigation/HysCalendarNavigation.vue.js";
|
|
13
|
+
import { default as k } from "./components/HysCard/HysCard.vue.js";
|
|
14
|
+
import { default as v } from "./components/HysCascader/HysCascader.vue.js";
|
|
15
|
+
import { default as D } from "./components/HysChart/HysChart.vue.js";
|
|
16
|
+
import { default as R } from "./components/HysCheckbox/HysCheckbox.vue.js";
|
|
17
|
+
import { default as I } from "./components/HysCheckboxGroup/HysCheckboxGroup.vue.js";
|
|
18
|
+
import { default as N } from "./components/HysColorPicker/HysColorPicker.vue.js";
|
|
19
|
+
import { default as B } from "./components/HysColorTokenEditor/HysColorTokenEditor.vue.js";
|
|
20
|
+
import { default as z } from "./components/HysCommandPalette/HysCommandPalette.vue.js";
|
|
21
|
+
import { default as K } from "./components/HysCommentEditor/HysCommentEditor.vue.js";
|
|
22
|
+
import { default as O } from "./components/HysContextMenu/HysContextMenu.vue.js";
|
|
23
|
+
import { default as j } from "./components/HysCronEditor/HysCronEditor.vue.js";
|
|
24
|
+
import { default as Q } from "./components/HysDataGrid/HysDataGrid.vue.js";
|
|
25
|
+
import { default as X } from "./components/HysDatePicker/HysDatePicker.vue.js";
|
|
26
|
+
import { default as Z } from "./components/HysDateRangePicker/HysDateRangePicker.vue.js";
|
|
27
|
+
import { default as $ } from "./components/HysDiffViewer/HysDiffViewer.vue.js";
|
|
28
|
+
import { default as re } from "./components/HysDivider/HysDivider.vue.js";
|
|
29
|
+
import { default as oe } from "./components/HysDrawer/HysDrawer.vue.js";
|
|
30
|
+
import { default as se } from "./components/HysEmpty/HysEmpty.vue.js";
|
|
31
|
+
import { default as le } from "./components/HysFileManager/HysFileManager.vue.js";
|
|
32
|
+
import { default as me } from "./components/HysForm/HysForm.vue.js";
|
|
33
|
+
import { default as ue } from "./components/HysFormItem/HysFormItem.vue.js";
|
|
34
|
+
import { default as ye } from "./components/HysGantt/HysGantt.vue.js";
|
|
35
|
+
import { default as ie } from "./components/HysInput/HysInput.vue.js";
|
|
36
|
+
import { default as ce } from "./components/HysJsonEditor/HysJsonEditor.vue.js";
|
|
37
|
+
import { default as Ce } from "./components/HysKanban/HysKanban.vue.js";
|
|
38
|
+
import { default as ge } from "./components/HysMention/HysMention.vue.js";
|
|
39
|
+
import { default as Pe } from "./components/HysModal/HysModal.vue.js";
|
|
40
|
+
import { default as ke } from "./components/HysNotificationCenter/HysNotificationCenter.vue.js";
|
|
41
|
+
import { default as ve } from "./components/HysNumberInput/HysNumberInput.vue.js";
|
|
42
|
+
import { default as De } from "./components/HysOrgTree/HysOrgTree.vue.js";
|
|
43
|
+
import { default as Re } from "./components/HysPagination/HysPagination.vue.js";
|
|
44
|
+
import { default as Ie } from "./components/HysPermissionMatrix/HysPermissionMatrix.vue.js";
|
|
45
|
+
import { default as Ne } from "./components/HysPopover/HysPopover.vue.js";
|
|
46
|
+
import { default as Be } from "./components/HysProgress/HysProgress.vue.js";
|
|
47
|
+
import { default as ze } from "./components/HysRadio/HysRadio.vue.js";
|
|
48
|
+
import { default as Ke } from "./components/HysRadioGroup/HysRadioGroup.vue.js";
|
|
49
|
+
import { default as Oe } from "./components/HysRating/HysRating.vue.js";
|
|
50
|
+
import { default as je } from "./components/HysResizablePanel/HysResizablePanel.vue.js";
|
|
51
|
+
import { default as Qe } from "./components/HysRichTextEditor/HysRichTextEditor.vue.js";
|
|
52
|
+
import { default as Xe } from "./components/HysSearch/HysSearch.vue.js";
|
|
53
|
+
import { default as Ze } from "./components/HysSegmented/HysSegmented.vue.js";
|
|
54
|
+
import { default as $e } from "./components/HysSelect/HysSelect.vue.js";
|
|
55
|
+
import { default as rr } from "./components/HysShortcutHelp/HysShortcutHelp.vue.js";
|
|
56
|
+
import { default as or } from "./components/HysSkeleton/HysSkeleton.vue.js";
|
|
57
|
+
import { default as sr } from "./components/HysSlider/HysSlider.vue.js";
|
|
58
|
+
import { default as lr } from "./components/HysSortableList/HysSortableList.vue.js";
|
|
59
|
+
import { default as mr } from "./components/HysSplitPane/HysSplitPane.vue.js";
|
|
60
|
+
import { default as ur } from "./components/HysSteps/HysSteps.vue.js";
|
|
61
|
+
import { default as yr } from "./components/HysSwitch/HysSwitch.vue.js";
|
|
62
|
+
import { default as ir } from "./components/HysTable/HysTable.vue.js";
|
|
63
|
+
import { default as cr } from "./components/HysTabs/HysTabs.vue.js";
|
|
64
|
+
import { default as Cr } from "./components/HysTagInput/HysTagInput.vue.js";
|
|
65
|
+
import { default as gr } from "./components/HysTextarea/HysTextarea.vue.js";
|
|
66
|
+
import { default as Pr } from "./components/HysTimeline/HysTimeline.vue.js";
|
|
67
|
+
import { default as kr } from "./components/HysToast/HysToast.vue.js";
|
|
68
|
+
import { default as vr } from "./components/HysTooltip/HysTooltip.vue.js";
|
|
69
|
+
import { default as Dr } from "./components/HysTour/HysTour.vue.js";
|
|
70
|
+
import { default as Rr } from "./components/HysTransfer/HysTransfer.vue.js";
|
|
71
|
+
import { default as Ir } from "./components/HysTree/HysTree.vue.js";
|
|
72
|
+
import { default as Nr } from "./components/HysTreeSelect/HysTreeSelect.vue.js";
|
|
73
|
+
import { default as Br } from "./components/HysUpload/HysUpload.vue.js";
|
|
74
|
+
import { default as zr } from "./components/HysVirtualTable/HysVirtualTable.vue.js";
|
|
75
|
+
import { provideHysConfig as Kr } from "./config.js";
|
|
76
|
+
import { useHysFormItemContext as Or } from "./composables/formContext.js";
|
|
77
|
+
import { createHysToast as jr, useHysToast as qr } from "./composables/useHysToast.js";
|
|
78
|
+
import { createHysModal as Wr, useHysModal as Xr } from "./composables/useHysModal.js";
|
|
73
79
|
export {
|
|
74
|
-
|
|
80
|
+
o as HysAccordion,
|
|
75
81
|
s as HysAlert,
|
|
76
82
|
l as HysAnimatedNumber,
|
|
77
|
-
m as
|
|
78
|
-
u as
|
|
79
|
-
y as
|
|
80
|
-
i as
|
|
81
|
-
|
|
82
|
-
C as
|
|
83
|
-
|
|
84
|
-
P as
|
|
85
|
-
k as
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
z as
|
|
93
|
-
K as
|
|
94
|
-
O as
|
|
95
|
-
j as
|
|
96
|
-
Q as
|
|
97
|
-
X as
|
|
98
|
-
Z as
|
|
99
|
-
$ as
|
|
100
|
-
re as
|
|
101
|
-
|
|
102
|
-
se as
|
|
103
|
-
le as
|
|
104
|
-
me as
|
|
105
|
-
ue as
|
|
106
|
-
ye as
|
|
107
|
-
ie as
|
|
108
|
-
|
|
109
|
-
Ce as
|
|
110
|
-
|
|
111
|
-
Pe as
|
|
112
|
-
ke as
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
ze as
|
|
120
|
-
Ke as
|
|
121
|
-
Oe as
|
|
122
|
-
je as
|
|
123
|
-
Qe as
|
|
124
|
-
Xe as
|
|
125
|
-
Ze as
|
|
126
|
-
$e as
|
|
127
|
-
rr as
|
|
128
|
-
|
|
129
|
-
sr as
|
|
130
|
-
lr as
|
|
131
|
-
mr as
|
|
132
|
-
ur as
|
|
133
|
-
yr as
|
|
134
|
-
ir as
|
|
135
|
-
|
|
136
|
-
Cr as
|
|
137
|
-
|
|
138
|
-
Pr as
|
|
139
|
-
kr as
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
Nr as
|
|
145
|
-
|
|
83
|
+
m as HysAutocomplete,
|
|
84
|
+
u as HysAvatar,
|
|
85
|
+
y as HysAvatarGroup,
|
|
86
|
+
i as HysBadge,
|
|
87
|
+
c as HysBreadcrumb,
|
|
88
|
+
C as HysButton,
|
|
89
|
+
g as HysCalendar,
|
|
90
|
+
P as HysCalendarNavigation,
|
|
91
|
+
k as HysCard,
|
|
92
|
+
v as HysCascader,
|
|
93
|
+
D as HysChart,
|
|
94
|
+
R as HysCheckbox,
|
|
95
|
+
I as HysCheckboxGroup,
|
|
96
|
+
N as HysColorPicker,
|
|
97
|
+
B as HysColorTokenEditor,
|
|
98
|
+
z as HysCommandPalette,
|
|
99
|
+
K as HysCommentEditor,
|
|
100
|
+
O as HysContextMenu,
|
|
101
|
+
j as HysCronEditor,
|
|
102
|
+
Q as HysDataGrid,
|
|
103
|
+
X as HysDatePicker,
|
|
104
|
+
Z as HysDateRangePicker,
|
|
105
|
+
$ as HysDiffViewer,
|
|
106
|
+
re as HysDivider,
|
|
107
|
+
oe as HysDrawer,
|
|
108
|
+
se as HysEmpty,
|
|
109
|
+
le as HysFileManager,
|
|
110
|
+
me as HysForm,
|
|
111
|
+
ue as HysFormItem,
|
|
112
|
+
ye as HysGantt,
|
|
113
|
+
ie as HysInput,
|
|
114
|
+
ce as HysJsonEditor,
|
|
115
|
+
Ce as HysKanban,
|
|
116
|
+
ge as HysMention,
|
|
117
|
+
Pe as HysModal,
|
|
118
|
+
ke as HysNotificationCenter,
|
|
119
|
+
ve as HysNumberInput,
|
|
120
|
+
De as HysOrgTree,
|
|
121
|
+
Re as HysPagination,
|
|
122
|
+
Ie as HysPermissionMatrix,
|
|
123
|
+
Ne as HysPopover,
|
|
124
|
+
Be as HysProgress,
|
|
125
|
+
ze as HysRadio,
|
|
126
|
+
Ke as HysRadioGroup,
|
|
127
|
+
Oe as HysRating,
|
|
128
|
+
je as HysResizablePanel,
|
|
129
|
+
Qe as HysRichTextEditor,
|
|
130
|
+
Xe as HysSearch,
|
|
131
|
+
Ze as HysSegmented,
|
|
132
|
+
$e as HysSelect,
|
|
133
|
+
rr as HysShortcutHelp,
|
|
134
|
+
or as HysSkeleton,
|
|
135
|
+
sr as HysSlider,
|
|
136
|
+
lr as HysSortableList,
|
|
137
|
+
mr as HysSplitPane,
|
|
138
|
+
ur as HysSteps,
|
|
139
|
+
yr as HysSwitch,
|
|
140
|
+
ir as HysTable,
|
|
141
|
+
cr as HysTabs,
|
|
142
|
+
Cr as HysTagInput,
|
|
143
|
+
gr as HysTextarea,
|
|
144
|
+
Pr as HysTimeline,
|
|
145
|
+
kr as HysToast,
|
|
146
|
+
vr as HysTooltip,
|
|
147
|
+
Dr as HysTour,
|
|
148
|
+
Rr as HysTransfer,
|
|
149
|
+
Ir as HysTree,
|
|
150
|
+
Nr as HysTreeSelect,
|
|
151
|
+
Br as HysUpload,
|
|
152
|
+
zr as HysVirtualTable,
|
|
153
|
+
Wr as createHysModal,
|
|
154
|
+
jr as createHysToast,
|
|
155
|
+
Kr as provideHysConfig,
|
|
156
|
+
Or as useHysFormItemContext,
|
|
157
|
+
Xr as useHysModal,
|
|
158
|
+
qr as useHysToast
|
|
146
159
|
};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { defineComponent as u, isVNode as g, Text as l, Comment as s, h as b, Fragment as f, cloneVNode as x } from "vue";
|
|
2
|
+
const m = (n) => n.flatMap(
|
|
3
|
+
(e) => e.type === f ? m(e.children) : e.type === s || e.type === l && !String(e.children).trim() ? [] : [e]
|
|
4
|
+
), k = u({
|
|
5
|
+
name: "HysPopupReference",
|
|
6
|
+
inheritAttrs: !1,
|
|
7
|
+
props: { id: String, open: Boolean, kind: String },
|
|
8
|
+
emits: ["element"],
|
|
9
|
+
setup(n, { slots: e, emit: h }) {
|
|
10
|
+
const y = (t) => {
|
|
11
|
+
const r = (t == null ? void 0 : t.$el) ?? t;
|
|
12
|
+
h("element", r instanceof HTMLElement ? r : void 0);
|
|
13
|
+
};
|
|
14
|
+
return () => {
|
|
15
|
+
var a, p, d, c;
|
|
16
|
+
const t = ((a = e.default) == null ? void 0 : a.call(e)) ?? [], r = m(t), i = r[0];
|
|
17
|
+
if (r.length !== 1 || !g(i) || i.type === l || i.type === s)
|
|
18
|
+
return b(f, null, t);
|
|
19
|
+
const o = (p = i.props) == null ? void 0 : p["aria-describedby"];
|
|
20
|
+
return x(
|
|
21
|
+
i,
|
|
22
|
+
{
|
|
23
|
+
ref: y,
|
|
24
|
+
...n.kind === "tooltip" ? {
|
|
25
|
+
"aria-describedby": n.open ? [o, n.id].filter(Boolean).join(" ") : o
|
|
26
|
+
} : {
|
|
27
|
+
"aria-controls": n.open ? n.id : (d = i.props) == null ? void 0 : d["aria-controls"],
|
|
28
|
+
"aria-expanded": n.open,
|
|
29
|
+
"aria-haspopup": ((c = i.props) == null ? void 0 : c["aria-haspopup"]) ?? "dialog"
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
!0
|
|
33
|
+
);
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
});
|
|
37
|
+
export {
|
|
38
|
+
k as default
|
|
39
|
+
};
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { defineComponent as m, provide as y, computed as p, openBlock as i, createBlock as b, Teleport as k, createVNode as h, unref as r, withCtx as w, withDirectives as P, createElementBlock as o, mergeProps as g, normalizeStyle as s, createCommentVNode as l, createElementVNode as E, normalizeClass as L, renderSlot as c, normalizeProps as d, guardReactiveProps as f, createTextVNode as S, toDisplayString as C, vShow as F } from "vue";
|
|
2
|
+
import I from "../motion/PopupMotion.js";
|
|
3
|
+
import { useHysRootAttrs as T } from "../config.js";
|
|
4
|
+
import { overlayOwnerKey as N } from "../composables/overlayManager.js";
|
|
5
|
+
const V = ["id", "role", "aria-label", "aria-labelledby", "data-side", "data-placement"], $ = ["id"], A = /* @__PURE__ */ m({
|
|
6
|
+
__name: "PopupSurfacePanel",
|
|
7
|
+
props: {
|
|
8
|
+
surface: {},
|
|
9
|
+
options: {},
|
|
10
|
+
kind: {},
|
|
11
|
+
title: {}
|
|
12
|
+
},
|
|
13
|
+
setup(e) {
|
|
14
|
+
const u = e;
|
|
15
|
+
y(
|
|
16
|
+
N,
|
|
17
|
+
p(() => u.surface.active.value && u.surface.open.value)
|
|
18
|
+
);
|
|
19
|
+
const v = T();
|
|
20
|
+
return (n, a) => e.surface.active.value ? (i(), b(k, {
|
|
21
|
+
key: 0,
|
|
22
|
+
to: e.surface.teleportTo.value,
|
|
23
|
+
disabled: e.options.appendTo === !1
|
|
24
|
+
}, [
|
|
25
|
+
h(r(I), {
|
|
26
|
+
"popup-transition": e.options.popupTransition,
|
|
27
|
+
"popup-transition-duration": e.options.popupTransitionDuration,
|
|
28
|
+
placement: e.surface.placement.value,
|
|
29
|
+
"ignore-owner": "",
|
|
30
|
+
onEntered: e.surface.afterEnter,
|
|
31
|
+
onLeft: e.surface.afterLeave,
|
|
32
|
+
onInactive: e.surface.inactive
|
|
33
|
+
}, {
|
|
34
|
+
default: w(() => [
|
|
35
|
+
e.surface.mounted.value ? P((i(), o("div", g({
|
|
36
|
+
key: 0,
|
|
37
|
+
id: e.surface.id,
|
|
38
|
+
ref: (t) => e.surface.panel.value = t
|
|
39
|
+
}, r(v), {
|
|
40
|
+
class: ["hys-ui-popup-surface-panel", [
|
|
41
|
+
e.kind === "tooltip" ? "hys-ui-tooltip-bubble hys-ui-floating-tooltip" : "hys-ui-popover-panel hys-ui-floating-surface",
|
|
42
|
+
e.options.overlayClass,
|
|
43
|
+
{ "hys-ui-popup-enterable": e.options.enterable !== !1 }
|
|
44
|
+
]],
|
|
45
|
+
style: e.surface.style.value,
|
|
46
|
+
role: e.kind === "tooltip" ? "tooltip" : "dialog",
|
|
47
|
+
"aria-label": e.options.ariaLabel || (e.kind === "popover" ? e.title || "浮层" : void 0),
|
|
48
|
+
"aria-labelledby": e.kind === "popover" && !e.options.ariaLabel && (e.title || n.$slots.title) ? e.surface.titleId : void 0,
|
|
49
|
+
"data-side": e.surface.placement.value.split("-")[0],
|
|
50
|
+
"data-placement": e.surface.placement.value,
|
|
51
|
+
onPointerenter: a[0] || (a[0] = //@ts-ignore
|
|
52
|
+
(...t) => e.surface.panelEnter && e.surface.panelEnter(...t)),
|
|
53
|
+
onPointerleave: a[1] || (a[1] = //@ts-ignore
|
|
54
|
+
(...t) => e.surface.panelLeave && e.surface.panelLeave(...t)),
|
|
55
|
+
onFocusin: a[2] || (a[2] = //@ts-ignore
|
|
56
|
+
(...t) => e.surface.panelFocusIn && e.surface.panelFocusIn(...t)),
|
|
57
|
+
onFocusout: a[3] || (a[3] = //@ts-ignore
|
|
58
|
+
(...t) => e.surface.panelFocusOut && e.surface.panelFocusOut(...t))
|
|
59
|
+
}), [
|
|
60
|
+
e.options.showArrow ? (i(), o("span", {
|
|
61
|
+
key: 0,
|
|
62
|
+
class: "hys-ui-popup-arrow",
|
|
63
|
+
style: s(e.surface.arrowStyle.value),
|
|
64
|
+
"aria-hidden": "true"
|
|
65
|
+
}, null, 4)) : l("", !0),
|
|
66
|
+
E("div", {
|
|
67
|
+
class: L(["hys-ui-popup-surface-content", e.options.contentClass]),
|
|
68
|
+
style: s(e.surface.contentStyle.value)
|
|
69
|
+
}, [
|
|
70
|
+
e.kind === "popover" && (e.title || n.$slots.title) ? (i(), o("div", {
|
|
71
|
+
key: 0,
|
|
72
|
+
id: e.surface.titleId,
|
|
73
|
+
class: "hys-ui-popup-surface-title"
|
|
74
|
+
}, [
|
|
75
|
+
c(n.$slots, "title", d(f(e.surface.scope.value)), () => [
|
|
76
|
+
S(C(e.title), 1)
|
|
77
|
+
], !0)
|
|
78
|
+
], 8, $)) : l("", !0),
|
|
79
|
+
c(n.$slots, "default", d(f(e.surface.scope.value)), void 0, !0)
|
|
80
|
+
], 6)
|
|
81
|
+
], 16, V)), [
|
|
82
|
+
[F, e.surface.open.value]
|
|
83
|
+
]) : l("", !0)
|
|
84
|
+
]),
|
|
85
|
+
_: 3
|
|
86
|
+
}, 8, ["popup-transition", "popup-transition-duration", "placement", "onEntered", "onLeft", "onInactive"])
|
|
87
|
+
], 8, ["to", "disabled"])) : l("", !0);
|
|
88
|
+
}
|
|
89
|
+
});
|
|
90
|
+
export {
|
|
91
|
+
A as default
|
|
92
|
+
};
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import { defineComponent as T, ref as x, inject as B, computed as p, watch as W, onMounted as C, onActivated as D, onDeactivated as O, onBeforeUnmount as k, h as H, Transition as N } from "vue";
|
|
2
|
+
import { useHysRootAttrs as S } from "../config.js";
|
|
3
|
+
import { overlayOwnerKey as j } from "../composables/overlayManager.js";
|
|
4
|
+
const U = T({
|
|
5
|
+
name: "HysPopupMotion",
|
|
6
|
+
props: {
|
|
7
|
+
popupTransition: {
|
|
8
|
+
type: String,
|
|
9
|
+
default: void 0
|
|
10
|
+
},
|
|
11
|
+
popupTransitionDuration: { type: Number, default: void 0 },
|
|
12
|
+
placement: { type: String, default: "bottom-start" },
|
|
13
|
+
disabled: { type: Boolean, default: !1 },
|
|
14
|
+
ignoreOwner: { type: Boolean, default: !1 }
|
|
15
|
+
},
|
|
16
|
+
emits: ["inactive", "entered", "left"],
|
|
17
|
+
setup(i, { slots: A, emit: s }) {
|
|
18
|
+
var w;
|
|
19
|
+
const E = S(), l = x(!0), h = x(
|
|
20
|
+
typeof window < "u" && !!((w = window.matchMedia) != null && w.call(window, "(prefers-reduced-motion: reduce)").matches)
|
|
21
|
+
), a = B(j, void 0);
|
|
22
|
+
let n, c = !1;
|
|
23
|
+
const v = p(() => i.popupTransition ?? "scale"), y = p(
|
|
24
|
+
() => Number.isFinite(i.popupTransitionDuration) ? Math.max(0, Math.min(2e3, i.popupTransitionDuration)) : 160
|
|
25
|
+
), M = p(
|
|
26
|
+
() => l.value && (i.ignoreOwner || (a == null ? void 0 : a.value) !== !1)
|
|
27
|
+
), L = p(
|
|
28
|
+
() => !i.disabled && v.value !== "none" && y.value > 0 && E.value["data-hys-motion"] !== "off" && !h.value
|
|
29
|
+
);
|
|
30
|
+
let o;
|
|
31
|
+
const d = /* @__PURE__ */ new WeakMap();
|
|
32
|
+
function f() {
|
|
33
|
+
h.value = !!(n != null && n.matches);
|
|
34
|
+
}
|
|
35
|
+
function m() {
|
|
36
|
+
var t;
|
|
37
|
+
c || (c = !0, n = (t = window.matchMedia) == null ? void 0 : t.call(window, "(prefers-reduced-motion: reduce)"), f(), n == null || n.addEventListener("change", f));
|
|
38
|
+
}
|
|
39
|
+
function g() {
|
|
40
|
+
c = !1, n == null || n.removeEventListener("change", f);
|
|
41
|
+
}
|
|
42
|
+
function u(t) {
|
|
43
|
+
const e = t, r = d.get(t);
|
|
44
|
+
r && (e.inert = r.inert, r.aria === null ? e.removeAttribute("aria-hidden") : e.setAttribute("aria-hidden", r.aria), e.style.pointerEvents = r.pointer, d.delete(t)), e.classList.add("hys-ui-popup-motion"), e.style.setProperty(
|
|
45
|
+
"--hys-ui-popup-duration",
|
|
46
|
+
y.value + "ms"
|
|
47
|
+
), o = e, b(e);
|
|
48
|
+
}
|
|
49
|
+
function b(t) {
|
|
50
|
+
const e = i.placement;
|
|
51
|
+
t.style.setProperty(
|
|
52
|
+
"--hys-ui-popup-origin",
|
|
53
|
+
e.startsWith("top") ? "bottom center" : e.startsWith("left") ? "right center" : e.startsWith("right") ? "left center" : "top center"
|
|
54
|
+
), t.style.setProperty(
|
|
55
|
+
"--hys-ui-popup-x",
|
|
56
|
+
e.startsWith("left") ? "6px" : e.startsWith("right") ? "-6px" : "0px"
|
|
57
|
+
), t.style.setProperty(
|
|
58
|
+
"--hys-ui-popup-y",
|
|
59
|
+
e.startsWith("left") || e.startsWith("right") ? "0px" : e.startsWith("top") ? "6px" : "-6px"
|
|
60
|
+
);
|
|
61
|
+
}
|
|
62
|
+
function P(t) {
|
|
63
|
+
const e = t;
|
|
64
|
+
u(t), d.set(t, {
|
|
65
|
+
inert: e.inert,
|
|
66
|
+
aria: e.getAttribute("aria-hidden"),
|
|
67
|
+
pointer: e.style.pointerEvents
|
|
68
|
+
}), e.inert = !0, e.setAttribute("aria-hidden", "true"), e.style.pointerEvents = "none";
|
|
69
|
+
}
|
|
70
|
+
return W(
|
|
71
|
+
() => i.placement,
|
|
72
|
+
() => {
|
|
73
|
+
o != null && o.isConnected && b(o);
|
|
74
|
+
},
|
|
75
|
+
{ flush: "post" }
|
|
76
|
+
), C(m), D(() => {
|
|
77
|
+
l.value = !0, m();
|
|
78
|
+
}), O(() => {
|
|
79
|
+
l.value = !1, g(), s("inactive");
|
|
80
|
+
}), k(g), W(
|
|
81
|
+
() => a == null ? void 0 : a.value,
|
|
82
|
+
(t) => {
|
|
83
|
+
t === !1 && !i.ignoreOwner && s("inactive");
|
|
84
|
+
},
|
|
85
|
+
{ flush: "sync" }
|
|
86
|
+
), () => M.value ? H(
|
|
87
|
+
N,
|
|
88
|
+
{
|
|
89
|
+
name: "hys-ui-popup-" + v.value,
|
|
90
|
+
appear: !0,
|
|
91
|
+
css: L.value,
|
|
92
|
+
onAfterEnter: () => s("entered"),
|
|
93
|
+
onAfterLeave: () => s("left"),
|
|
94
|
+
onBeforeEnter: u,
|
|
95
|
+
onEnterCancelled: u,
|
|
96
|
+
onBeforeLeave: P,
|
|
97
|
+
onLeaveCancelled: u
|
|
98
|
+
},
|
|
99
|
+
A.default
|
|
100
|
+
) : null;
|
|
101
|
+
}
|
|
102
|
+
});
|
|
103
|
+
export {
|
|
104
|
+
U as default
|
|
105
|
+
};
|