@rockshin/tao-ui 0.0.59 → 0.1.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/README.md +5 -1
- package/component-manifest.json +1 -1
- package/dist/components/affix/affix.css +1 -1
- package/dist/components/affix/affix.d.ts +1 -0
- package/dist/components/affix/affix.js +18 -17
- package/dist/components/alert/alert.css +123 -119
- package/dist/components/alert/alert.js +78 -188
- package/dist/components/app/app-modals.js +49 -98
- package/dist/components/app/app-notices.d.ts +2 -2
- package/dist/components/app/app-notices.js +294 -243
- package/dist/components/app/app-types.d.ts +6 -3
- package/dist/components/app/app.css +185 -183
- package/dist/components/app/app.js +1 -1
- package/dist/components/auto-complete/auto-complete.css +30 -28
- package/dist/components/auto-complete/auto-complete.d.ts +3 -1
- package/dist/components/auto-complete/auto-complete.js +2 -1
- package/dist/components/badge/badge.js +42 -127
- package/dist/components/border-beam/border-beam.css +1 -1
- package/dist/components/border-beam/border-beam.d.ts +1 -0
- package/dist/components/border-beam/border-beam.js +1 -0
- package/dist/components/breadcrumb/breadcrumb.css +123 -120
- package/dist/components/breadcrumb/breadcrumb.js +160 -265
- package/dist/components/button/button.d.ts +1 -1
- package/dist/components/button/button.js +52 -151
- package/dist/components/calendar/calendar.js +28 -27
- package/dist/components/card/card-tabs.d.ts +56 -5
- package/dist/components/card/card-tabs.js +214 -468
- package/dist/components/card/card.d.ts +1 -2
- package/dist/components/card/card.js +64 -226
- package/dist/components/carousel/carousel.css +1 -1
- package/dist/components/carousel/carousel.d.ts +59 -4
- package/dist/components/carousel/carousel.js +299 -243
- package/dist/components/cascader/cascader.css +186 -184
- package/dist/components/cascader/cascader.d.ts +3 -1
- package/dist/components/cascader/cascader.js +29 -34
- package/dist/components/checkbox/checkbox.css +93 -90
- package/dist/components/checkbox/checkbox.d.ts +1 -1
- package/dist/components/checkbox/checkbox.js +171 -499
- package/dist/components/collapse/collapse-panels.js +145 -400
- package/dist/components/collapse/collapse.css +172 -170
- package/dist/components/collapse/collapse.d.ts +1 -1
- package/dist/components/collapse/collapse.js +62 -181
- package/dist/components/color-picker/color-picker.css +1 -1
- package/dist/components/color-picker/color-picker.js +418 -981
- package/dist/components/context-menu/context-menu.css +4 -4
- package/dist/components/context-menu/context-menu.d.ts +3 -1
- package/dist/components/context-menu/context-menu.js +54 -135
- package/dist/components/date-picker/calendar/calendar-grid.js +41 -41
- package/dist/components/date-picker/calendar/calendar-header.js +171 -337
- package/dist/components/date-picker/calendar/month-grid.js +33 -103
- package/dist/components/date-picker/calendar/time-panel.js +84 -209
- package/dist/components/date-picker/calendar/year-grid.js +36 -105
- package/dist/components/date-picker/date-localization.js +1 -1
- package/dist/components/date-picker/date-picker.css +599 -642
- package/dist/components/date-picker/date-picker.d.ts +2 -1
- package/dist/components/date-picker/date-picker.js +96 -105
- package/dist/components/date-picker/presets.js +12 -37
- package/dist/components/date-picker/range-picker.d.ts +2 -1
- package/dist/components/date-picker/range-picker.js +222 -255
- package/dist/components/date-picker/types.d.ts +2 -1
- package/dist/components/descriptions/descriptions.css +1 -1
- package/dist/components/descriptions/descriptions.js +30 -39
- package/dist/components/drawer/drawer.css +202 -200
- package/dist/components/drawer/drawer.js +28 -34
- package/dist/components/dropdown/dropdown-core.d.ts +32 -0
- package/dist/components/dropdown/dropdown-core.js +156 -0
- package/dist/components/dropdown/dropdown.css +38 -36
- package/dist/components/dropdown/dropdown.d.ts +4 -30
- package/dist/components/dropdown/dropdown.js +91 -271
- package/dist/components/empty/empty.css +30 -28
- package/dist/components/empty/empty.js +81 -236
- package/dist/components/float-button/float-button.css +1 -1
- package/dist/components/float-button/float-button.js +38 -48
- package/dist/components/form/field-control.js +2 -3
- package/dist/components/form/form-item.js +67 -129
- package/dist/components/form/form.css +36 -34
- package/dist/components/form/form.d.ts +1 -1
- package/dist/components/form/form.js +29 -100
- package/dist/components/form/index.d.ts +1 -1
- package/dist/components/form/use-form.js +48 -66
- package/dist/components/form-actions/form-actions.d.ts +1 -0
- package/dist/components/form-actions/form-actions.js +10 -36
- package/dist/components/form-field/form-field-view.d.ts +1 -0
- package/dist/components/form-field/form-field-view.js +81 -288
- package/dist/components/form-field/form-field.js +13 -31
- package/dist/components/form-field/form.css +74 -72
- package/dist/components/form-section/form-section.d.ts +1 -0
- package/dist/components/form-section/form-section.js +38 -91
- package/dist/components/image/image-icons.js +16 -31
- package/dist/components/image/image.css +1 -1
- package/dist/components/image/image.js +298 -911
- package/dist/components/input/base-input.d.ts +3 -1
- package/dist/components/input/base-input.js +8 -7
- package/dist/components/input/input-shared.css +62 -60
- package/dist/components/input/input-shared.d.ts +1 -1
- package/dist/components/input/input-shared.js +56 -100
- package/dist/components/input/input.css +222 -220
- package/dist/components/input/otp.d.ts +2 -1
- package/dist/components/input/otp.js +143 -324
- package/dist/components/input/password.js +12 -67
- package/dist/components/input/search.js +13 -13
- package/dist/components/input-number/input-number.d.ts +4 -2
- package/dist/components/input-number/input-number.js +30 -137
- package/dist/components/list/list-pagination.css +107 -105
- package/dist/components/list/list-pagination.d.ts +56 -5
- package/dist/components/list/list-pagination.js +249 -316
- package/dist/components/list/list.css +179 -177
- package/dist/components/list/list.js +170 -604
- package/dist/components/listy/listy.css +55 -53
- package/dist/components/listy/listy.d.ts +43 -4
- package/dist/components/listy/listy.js +198 -216
- package/dist/components/masonry/masonry.css +1 -1
- package/dist/components/masonry/masonry.d.ts +1 -0
- package/dist/components/masonry/masonry.js +90 -244
- package/dist/components/mentions/mentions.css +153 -151
- package/dist/components/mentions/mentions.d.ts +53 -11
- package/dist/components/mentions/mentions.js +291 -75
- package/dist/components/menu/menu-render.d.ts +7 -0
- package/dist/components/menu/menu-render.js +156 -302
- package/dist/components/menu/menu.css +142 -140
- package/dist/components/modal/confirm-dialog.js +19 -24
- package/dist/components/modal/modal.css +165 -162
- package/dist/components/modal/modal.js +285 -731
- package/dist/components/modal/use-modal.js +25 -25
- package/dist/components/pagination/pagination.css +134 -131
- package/dist/components/pagination/pagination.d.ts +4 -3
- package/dist/components/pagination/pagination.js +138 -281
- package/dist/components/popconfirm/popconfirm.css +38 -36
- package/dist/components/popconfirm/popconfirm.js +105 -288
- package/dist/components/popover/popover.css +89 -87
- package/dist/components/popover/popover.js +189 -469
- package/dist/components/progress/progress.css +153 -151
- package/dist/components/progress/progress.js +34 -43
- package/dist/components/qr-code/qr-code.css +36 -34
- package/dist/components/qr-code/qr-code.js +83 -277
- package/dist/components/radio/radio.css +95 -92
- package/dist/components/radio/radio.d.ts +1 -1
- package/dist/components/radio/radio.js +114 -376
- package/dist/components/rate/rate.css +80 -78
- package/dist/components/rate/rate.d.ts +34 -6
- package/dist/components/rate/rate.js +160 -244
- package/dist/components/result/result.css +59 -57
- package/dist/components/result/result.d.ts +1 -0
- package/dist/components/result/result.js +118 -291
- package/dist/components/scroll-area/scroll-area.css +160 -148
- package/dist/components/scroll-area/scroll-area.js +284 -488
- package/dist/components/segmented/segmented.css +1 -1
- package/dist/components/segmented/segmented.js +59 -58
- package/dist/components/select/mobile-select.css +166 -164
- package/dist/components/select/mobile-select.js +48 -131
- package/dist/components/select/select-icons.js +59 -128
- package/dist/components/select/select-model.js +1 -1
- package/dist/components/select/select-searchable-list.js +19 -19
- package/dist/components/select/select-tags.js +70 -156
- package/dist/components/select/select-types.d.ts +2 -1
- package/dist/components/select/select.css +509 -506
- package/dist/components/select/select.d.ts +1 -0
- package/dist/components/select/select.js +67 -65
- package/dist/components/select/use-select-selection.js +181 -261
- package/dist/components/skeleton/skeleton.css +105 -103
- package/dist/components/skeleton/skeleton.js +140 -399
- package/dist/components/slider/slider.css +160 -158
- package/dist/components/slider/slider.d.ts +45 -6
- package/dist/components/slider/slider.js +359 -74
- package/dist/components/sonner/index.d.ts +1 -1
- package/dist/components/sonner/sonner.css +190 -182
- package/dist/components/sonner/sonner.js +12 -11
- package/dist/components/spinner/spinner.css +80 -76
- package/dist/components/spinner/spinner.d.ts +1 -1
- package/dist/components/spinner/spinner.js +75 -219
- package/dist/components/splitter/splitter.css +157 -154
- package/dist/components/splitter/splitter.js +271 -448
- package/dist/components/statistic/statistic.css +1 -1
- package/dist/components/statistic/statistic.js +121 -406
- package/dist/components/status-icon/status-icon.js +14 -26
- package/dist/components/steps/steps-icons.js +63 -100
- package/dist/components/steps/steps.css +817 -807
- package/dist/components/steps/steps.d.ts +1 -1
- package/dist/components/steps/steps.js +38 -94
- package/dist/components/steps/use-display-steps.js +21 -54
- package/dist/components/switch/switch-touch.css +17 -15
- package/dist/components/switch/switch.css +192 -190
- package/dist/components/switch/switch.js +63 -196
- package/dist/components/table/table-filter.d.ts +3 -1
- package/dist/components/table/table-filter.js +72 -133
- package/dist/components/table/table-icons.js +77 -152
- package/dist/components/table/table-summary.js +30 -77
- package/dist/components/table/table-types.d.ts +2 -1
- package/dist/components/table/table.css +468 -465
- package/dist/components/table/table.js +86 -84
- package/dist/components/table/use-table-data.js +137 -248
- package/dist/components/tabs/tabs.css +123 -120
- package/dist/components/tabs/tabs.d.ts +4 -3
- package/dist/components/tabs/tabs.js +157 -322
- package/dist/components/tag/tag.css +231 -221
- package/dist/components/tag/tag.js +110 -248
- package/dist/components/textarea/textarea.css +2 -1
- package/dist/components/textarea/textarea.d.ts +3 -1
- package/dist/components/textarea/textarea.js +16 -15
- package/dist/components/time-picker/time-picker.d.ts +1 -0
- package/dist/components/time-picker/time-picker.js +91 -221
- package/dist/components/timeline/timeline.css +1 -1
- package/dist/components/timeline/timeline.js +17 -17
- package/dist/components/tooltip/tooltip.css +79 -77
- package/dist/components/tooltip/tooltip.d.ts +1 -1
- package/dist/components/tooltip/tooltip.js +111 -263
- package/dist/components/tour/tour.css +1 -1
- package/dist/components/tour/tour.d.ts +59 -6
- package/dist/components/tour/tour.js +343 -622
- package/dist/components/transfer/transfer-list.js +19 -19
- package/dist/components/transfer/transfer-parts.js +63 -139
- package/dist/components/transfer/transfer.css +192 -190
- package/dist/components/transfer/transfer.js +57 -56
- package/dist/components/tree/tree-check.js +25 -32
- package/dist/components/tree/tree-keyboard.js +1 -1
- package/dist/components/tree/tree.css +204 -200
- package/dist/components/tree/tree.js +139 -277
- package/dist/components/tree-select/select-engine.css +200 -197
- package/dist/components/tree-select/select-engine.js +11 -38
- package/dist/components/tree-select/tree-select.css +21 -19
- package/dist/components/tree-select/tree-select.d.ts +3 -1
- package/dist/components/tree-select/tree-select.js +12 -10
- package/dist/components/upload/upload.js +193 -308
- package/dist/components/watermark/watermark-context.js +8 -14
- package/dist/components/watermark/watermark.css +1 -1
- package/dist/components/watermark/watermark.js +209 -400
- package/dist/docs/components/stack.doc.js +1 -1
- package/dist/docs/components/table.doc.js +1 -1
- package/dist/entries/affix.d.ts +0 -2
- package/dist/entries/affix.js +0 -2
- package/dist/entries/alert.d.ts +0 -2
- package/dist/entries/alert.js +0 -2
- package/dist/entries/app.d.ts +0 -2
- package/dist/entries/app.js +0 -2
- package/dist/entries/auto-complete.d.ts +0 -2
- package/dist/entries/auto-complete.js +0 -2
- package/dist/entries/avatar.d.ts +0 -2
- package/dist/entries/avatar.js +0 -2
- package/dist/entries/badge.d.ts +0 -2
- package/dist/entries/badge.js +0 -2
- package/dist/entries/border-beam.d.ts +0 -2
- package/dist/entries/border-beam.js +0 -2
- package/dist/entries/breadcrumb.d.ts +0 -2
- package/dist/entries/breadcrumb.js +0 -2
- package/dist/entries/button.d.ts +0 -2
- package/dist/entries/button.js +0 -2
- package/dist/entries/calendar.d.ts +0 -2
- package/dist/entries/calendar.js +0 -2
- package/dist/entries/card.d.ts +0 -2
- package/dist/entries/card.js +0 -2
- package/dist/entries/carousel.d.ts +0 -2
- package/dist/entries/carousel.js +0 -2
- package/dist/entries/cascader.d.ts +0 -2
- package/dist/entries/cascader.js +0 -2
- package/dist/entries/checkbox.d.ts +0 -2
- package/dist/entries/checkbox.js +0 -2
- package/dist/entries/collapse.d.ts +0 -2
- package/dist/entries/collapse.js +0 -2
- package/dist/entries/color-picker.d.ts +0 -2
- package/dist/entries/color-picker.js +0 -2
- package/dist/entries/context-menu.d.ts +0 -2
- package/dist/entries/context-menu.js +0 -2
- package/dist/entries/date-picker.d.ts +0 -2
- package/dist/entries/date-picker.js +0 -2
- package/dist/entries/descriptions.d.ts +0 -2
- package/dist/entries/descriptions.js +0 -2
- package/dist/entries/divider.d.ts +0 -2
- package/dist/entries/divider.js +0 -2
- package/dist/entries/drawer.d.ts +0 -2
- package/dist/entries/drawer.js +0 -2
- package/dist/entries/dropdown.d.ts +0 -2
- package/dist/entries/dropdown.js +0 -2
- package/dist/entries/empty.d.ts +0 -2
- package/dist/entries/empty.js +0 -2
- package/dist/entries/float-button.d.ts +0 -2
- package/dist/entries/float-button.js +0 -2
- package/dist/entries/form-actions.d.ts +0 -2
- package/dist/entries/form-actions.js +0 -2
- package/dist/entries/form-field.d.ts +0 -2
- package/dist/entries/form-field.js +0 -2
- package/dist/entries/form-layout.d.ts +0 -2
- package/dist/entries/form-layout.js +0 -2
- package/dist/entries/form-section.d.ts +0 -2
- package/dist/entries/form-section.js +0 -2
- package/dist/entries/form.d.ts +1 -3
- package/dist/entries/form.js +0 -2
- package/dist/entries/image.d.ts +0 -2
- package/dist/entries/image.js +0 -2
- package/dist/entries/input-number.d.ts +0 -2
- package/dist/entries/input-number.js +0 -2
- package/dist/entries/input.d.ts +1 -3
- package/dist/entries/input.js +0 -2
- package/dist/entries/list.d.ts +0 -2
- package/dist/entries/list.js +0 -2
- package/dist/entries/listy.d.ts +0 -2
- package/dist/entries/listy.js +0 -2
- package/dist/entries/masonry.d.ts +0 -2
- package/dist/entries/masonry.js +0 -2
- package/dist/entries/mentions.d.ts +0 -2
- package/dist/entries/mentions.js +0 -2
- package/dist/entries/modal.d.ts +0 -2
- package/dist/entries/modal.js +0 -2
- package/dist/entries/number-input.d.ts +0 -2
- package/dist/entries/number-input.js +0 -2
- package/dist/entries/pagination.d.ts +0 -2
- package/dist/entries/pagination.js +0 -2
- package/dist/entries/popconfirm.d.ts +0 -2
- package/dist/entries/popconfirm.js +0 -2
- package/dist/entries/popover.d.ts +0 -2
- package/dist/entries/popover.js +0 -2
- package/dist/entries/progress.d.ts +0 -2
- package/dist/entries/progress.js +0 -2
- package/dist/entries/provider.d.ts +1 -3
- package/dist/entries/provider.js +1 -3
- package/dist/entries/qr-code.d.ts +0 -2
- package/dist/entries/qr-code.js +0 -2
- package/dist/entries/radio.d.ts +0 -2
- package/dist/entries/radio.js +0 -2
- package/dist/entries/range-picker.d.ts +0 -2
- package/dist/entries/range-picker.js +0 -2
- package/dist/entries/rate.d.ts +0 -2
- package/dist/entries/rate.js +0 -2
- package/dist/entries/result.d.ts +0 -2
- package/dist/entries/result.js +0 -2
- package/dist/entries/scroll-area.d.ts +0 -2
- package/dist/entries/scroll-area.js +0 -2
- package/dist/entries/segmented.d.ts +0 -2
- package/dist/entries/segmented.js +0 -2
- package/dist/entries/select.d.ts +0 -2
- package/dist/entries/select.js +0 -2
- package/dist/entries/skeleton.d.ts +0 -2
- package/dist/entries/skeleton.js +0 -2
- package/dist/entries/slider.d.ts +0 -2
- package/dist/entries/slider.js +0 -2
- package/dist/entries/sonner.d.ts +0 -2
- package/dist/entries/sonner.js +0 -2
- package/dist/entries/spinner.d.ts +0 -2
- package/dist/entries/spinner.js +0 -2
- package/dist/entries/splitter.d.ts +0 -2
- package/dist/entries/splitter.js +0 -2
- package/dist/entries/stack.d.ts +0 -2
- package/dist/entries/stack.js +0 -2
- package/dist/entries/statistic.d.ts +0 -2
- package/dist/entries/statistic.js +0 -2
- package/dist/entries/steps.d.ts +0 -2
- package/dist/entries/steps.js +0 -2
- package/dist/entries/switch.d.ts +0 -2
- package/dist/entries/switch.js +0 -2
- package/dist/entries/table.d.ts +0 -2
- package/dist/entries/table.js +0 -2
- package/dist/entries/tabs.d.ts +0 -2
- package/dist/entries/tabs.js +0 -2
- package/dist/entries/tag.d.ts +0 -2
- package/dist/entries/tag.js +0 -2
- package/dist/entries/textarea.d.ts +0 -2
- package/dist/entries/textarea.js +0 -2
- package/dist/entries/time-picker.d.ts +0 -2
- package/dist/entries/time-picker.js +0 -2
- package/dist/entries/timeline.d.ts +0 -2
- package/dist/entries/timeline.js +0 -2
- package/dist/entries/tooltip.d.ts +0 -2
- package/dist/entries/tooltip.js +0 -2
- package/dist/entries/tour.d.ts +0 -2
- package/dist/entries/tour.js +0 -2
- package/dist/entries/transfer.d.ts +0 -2
- package/dist/entries/transfer.js +0 -2
- package/dist/entries/tree-select.d.ts +0 -2
- package/dist/entries/tree-select.js +0 -2
- package/dist/entries/tree.d.ts +0 -2
- package/dist/entries/tree.js +0 -2
- package/dist/entries/upload.d.ts +0 -2
- package/dist/entries/upload.js +0 -2
- package/dist/entries/watermark.d.ts +0 -2
- package/dist/entries/watermark.js +0 -2
- package/dist/index.d.ts +5 -7
- package/dist/index.js +2 -4
- package/dist/layouts/form-layout/form-layout.d.ts +1 -0
- package/dist/layouts/form-layout/form-layout.js +10 -36
- package/dist/layouts/stack/layout.css +46 -44
- package/dist/layouts/stack/stack.d.ts +1 -0
- package/dist/layouts/stack/stack.js +16 -69
- package/dist/locales/ar-EG.js +25 -2
- package/dist/locales/create-locale.d.ts +1 -2
- package/dist/locales/create-locale.js +0 -28
- package/dist/locales/de-DE.js +25 -2
- package/dist/locales/en-US.js +24 -1
- package/dist/locales/es-ES.js +25 -2
- package/dist/locales/fr-FR.js +25 -2
- package/dist/locales/hi-IN.js +25 -2
- package/dist/locales/id-ID.js +25 -2
- package/dist/locales/index.d.ts +10 -10
- package/dist/locales/index.js +9 -9
- package/dist/locales/it-IT.js +25 -2
- package/dist/locales/ja-JP.js +25 -2
- package/dist/locales/ko-KR.js +25 -2
- package/dist/locales/pt-BR.js +25 -2
- package/dist/locales/ru-RU.js +25 -2
- package/dist/locales/th-TH.js +25 -2
- package/dist/locales/tr-TR.js +25 -2
- package/dist/locales/vi-VN.js +25 -2
- package/dist/locales/zh-CN.js +25 -2
- package/dist/locales/zh-TW.js +25 -2
- package/dist/number-input/number-input.js +24 -81
- package/dist/number-input/use-number-input.d.ts +1 -0
- package/dist/number-input/use-number-input.js +47 -43
- package/dist/provider/locale.d.ts +1 -1
- package/dist/provider/tao-context.d.ts +38 -0
- package/dist/provider/tao-context.js +92 -0
- package/dist/provider/tao-portal-scope.d.ts +14 -0
- package/dist/provider/tao-portal-scope.js +54 -0
- package/dist/provider/tao-provider.d.ts +5 -55
- package/dist/provider/tao-provider.js +94 -364
- package/dist/theme/control.css +106 -122
- package/dist/theme/theme.css +4 -2
- package/dist/utils/dialog-content.js +55 -210
- package/dist/utils/overlay.js +15 -30
- package/dist/utils/rc-compat.d.ts +13 -0
- package/dist/utils/rc-compat.js +48 -0
- package/dist/utils/refs.js +5 -19
- package/package.json +10 -16
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
-
import { TaoPortalScope, useTaoDirection } from "../../provider/tao-provider.js";
|
|
1
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef, useCallback, useEffect, useId, useMemo, useRef } from "react";
|
|
3
|
+
import { useTaoDirection } from "../../provider/tao-context.js";
|
|
4
|
+
import { TaoPortalScope } from "../../provider/tao-provider.js";
|
|
6
5
|
import { asTriggerChild, useControlledOpen } from "../../utils/overlay.js";
|
|
7
6
|
import { useCommittedRef } from "../../utils/refs.js";
|
|
8
7
|
import { cx } from "../../utils/semantic.js";
|
|
9
8
|
import "./popover.css";
|
|
9
|
+
import * as __rspack_external__radix_ui_react_popover_c8444160 from "@radix-ui/react-popover";
|
|
10
10
|
function hasFocusWithin(element) {
|
|
11
11
|
if (!element) return false;
|
|
12
12
|
const root = element.getRootNode();
|
|
@@ -70,50 +70,24 @@ function isRenderable(node) {
|
|
|
70
70
|
return null != node && 'boolean' != typeof node && '' !== node;
|
|
71
71
|
}
|
|
72
72
|
const popover_PopoverSurface = /*#__PURE__*/ forwardRef(function(props, ref) {
|
|
73
|
-
const
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
t1 = /*#__PURE__*/ jsx("div", {
|
|
79
|
-
...props,
|
|
80
|
-
ref: t0
|
|
81
|
-
});
|
|
82
|
-
$[0] = props;
|
|
83
|
-
$[1] = t0;
|
|
84
|
-
$[2] = t1;
|
|
85
|
-
} else t1 = $[2];
|
|
86
|
-
return t1;
|
|
73
|
+
const retainedHidden = props['data-tao-keep-alive'] && 'closed' === props['data-state'];
|
|
74
|
+
return /*#__PURE__*/ jsx("div", {
|
|
75
|
+
...props,
|
|
76
|
+
ref: retainedHidden ? null : ref
|
|
77
|
+
});
|
|
87
78
|
});
|
|
88
|
-
function Popover(
|
|
89
|
-
const
|
|
90
|
-
const { direction: directionProp, title, content, trigger: t1, placement: t2, open, defaultOpen, onOpenChange, mouseEnterDelay: t3, mouseLeaveDelay: t4, arrow: t5, destroyOnHidden, destroyTooltipOnHide, className, style, classNames, styles, children, "aria-label": ariaLabel, "aria-labelledby": ariaLabelledBy, "aria-describedby": ariaDescribedBy } = t0;
|
|
91
|
-
const trigger = void 0 === t1 ? "hover" : t1;
|
|
92
|
-
const placement = void 0 === t2 ? "top" : t2;
|
|
93
|
-
const mouseEnterDelay = void 0 === t3 ? 0.1 : t3;
|
|
94
|
-
const mouseLeaveDelay = void 0 === t4 ? 0.1 : t4;
|
|
95
|
-
const arrow = void 0 === t5 ? true : t5;
|
|
96
|
-
const [direction, directionRef] = useTaoDirection(directionProp, "self");
|
|
79
|
+
function Popover({ direction: directionProp, title, content, trigger = 'hover', placement = 'top', open, defaultOpen, onOpenChange, mouseEnterDelay = 0.1, mouseLeaveDelay = 0.1, arrow = true, destroyOnHidden, destroyTooltipOnHide, className, style, classNames, styles, children, 'aria-label': ariaLabel, 'aria-labelledby': ariaLabelledBy, 'aria-describedby': ariaDescribedBy }) {
|
|
80
|
+
const [direction, directionRef] = useTaoDirection(directionProp, 'self');
|
|
97
81
|
const titleId = useId();
|
|
98
|
-
|
|
99
|
-
if ($[0] !== trigger) {
|
|
100
|
-
t6 = Array.isArray(trigger) ? trigger : [
|
|
82
|
+
const triggers = useMemo(()=>new Set(Array.isArray(trigger) ? trigger : [
|
|
101
83
|
trigger
|
|
102
|
-
]
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
$[2] = t6;
|
|
110
|
-
$[3] = t7;
|
|
111
|
-
} else t7 = $[3];
|
|
112
|
-
const triggers = t7;
|
|
113
|
-
const hoverMode = triggers.has("hover");
|
|
114
|
-
const focusMode = triggers.has("focus");
|
|
115
|
-
const clickMode = triggers.has("click");
|
|
116
|
-
const contextMenuMode = triggers.has("contextMenu");
|
|
84
|
+
]), [
|
|
85
|
+
trigger
|
|
86
|
+
]);
|
|
87
|
+
const hoverMode = triggers.has('hover');
|
|
88
|
+
const focusMode = triggers.has('focus');
|
|
89
|
+
const clickMode = triggers.has('click');
|
|
90
|
+
const contextMenuMode = triggers.has('contextMenu');
|
|
117
91
|
const shouldDestroy = destroyOnHidden ?? destroyTooltipOnHide ?? false;
|
|
118
92
|
const placementProps = placements[placement];
|
|
119
93
|
const TriggerPrimitive = clickMode ? __rspack_external__radix_ui_react_popover_c8444160.Trigger : __rspack_external__radix_ui_react_popover_c8444160.Anchor;
|
|
@@ -126,64 +100,35 @@ function Popover(t0) {
|
|
|
126
100
|
onOpenChange,
|
|
127
101
|
canOpen: hasPopup
|
|
128
102
|
});
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
focusMode
|
|
134
|
-
};
|
|
135
|
-
$[4] = focusMode;
|
|
136
|
-
$[5] = setOpen;
|
|
137
|
-
$[6] = t8;
|
|
138
|
-
} else t8 = $[6];
|
|
139
|
-
const hoverState = useCommittedRef(t8);
|
|
103
|
+
const hoverState = useCommittedRef({
|
|
104
|
+
setOpen,
|
|
105
|
+
focusMode
|
|
106
|
+
});
|
|
140
107
|
const openTimer = useRef(void 0);
|
|
141
108
|
const closeTimer = useRef(void 0);
|
|
142
109
|
const popupRef = useRef(null);
|
|
143
110
|
const triggerRef = useRef(null);
|
|
144
111
|
const restoringFocus = useRef(false);
|
|
145
112
|
const restoreAfterEscape = useRef(false);
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
$[10] = t11;
|
|
166
|
-
} else t11 = $[10];
|
|
167
|
-
const containsFocusTarget = t11;
|
|
168
|
-
let t12;
|
|
169
|
-
if ($[11] === Symbol.for("react.memo_cache_sentinel")) {
|
|
170
|
-
t12 = ()=>{
|
|
171
|
-
clearTimeout(openTimer.current);
|
|
172
|
-
clearTimeout(closeTimer.current);
|
|
173
|
-
};
|
|
174
|
-
$[11] = t12;
|
|
175
|
-
} else t12 = $[11];
|
|
176
|
-
const cancelTimers = t12;
|
|
177
|
-
let t13;
|
|
178
|
-
if ($[12] !== setOpen) {
|
|
179
|
-
t13 = (next)=>{
|
|
180
|
-
cancelTimers();
|
|
181
|
-
setOpen(next);
|
|
182
|
-
};
|
|
183
|
-
$[12] = setOpen;
|
|
184
|
-
$[13] = t13;
|
|
185
|
-
} else t13 = $[13];
|
|
186
|
-
const changeOpen = t13;
|
|
113
|
+
const setTriggerRef = useCallback((node)=>{
|
|
114
|
+
triggerRef.current = node;
|
|
115
|
+
directionRef(node);
|
|
116
|
+
}, [
|
|
117
|
+
directionRef
|
|
118
|
+
]);
|
|
119
|
+
const containsTrigger = (target)=>target instanceof Node && !!triggerRef.current?.contains(target);
|
|
120
|
+
const containsFocusTarget = useCallback((target)=>target instanceof Node && (triggerRef.current?.contains(target) || popupRef.current?.contains(target)), []);
|
|
121
|
+
const cancelTimers = useCallback(()=>{
|
|
122
|
+
clearTimeout(openTimer.current);
|
|
123
|
+
clearTimeout(closeTimer.current);
|
|
124
|
+
}, []);
|
|
125
|
+
const changeOpen = useCallback((next)=>{
|
|
126
|
+
cancelTimers();
|
|
127
|
+
setOpen(next);
|
|
128
|
+
}, [
|
|
129
|
+
cancelTimers,
|
|
130
|
+
setOpen
|
|
131
|
+
]);
|
|
187
132
|
const hoverEnabled = hasPopup && hoverMode;
|
|
188
133
|
useEffect(()=>{
|
|
189
134
|
if (hoverEnabled) return cancelTimers;
|
|
@@ -191,23 +136,11 @@ function Popover(t0) {
|
|
|
191
136
|
cancelTimers,
|
|
192
137
|
hoverEnabled
|
|
193
138
|
]);
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
};
|
|
200
|
-
t15 = [
|
|
201
|
-
realOpen
|
|
202
|
-
];
|
|
203
|
-
$[14] = realOpen;
|
|
204
|
-
$[15] = t14;
|
|
205
|
-
$[16] = t15;
|
|
206
|
-
} else {
|
|
207
|
-
t14 = $[15];
|
|
208
|
-
t15 = $[16];
|
|
209
|
-
}
|
|
210
|
-
useEffect(t14, t15);
|
|
139
|
+
useEffect(()=>{
|
|
140
|
+
realOpen ? clearTimeout(openTimer.current) : clearTimeout(closeTimer.current);
|
|
141
|
+
}, [
|
|
142
|
+
realOpen
|
|
143
|
+
]);
|
|
211
144
|
useEffect(()=>{
|
|
212
145
|
if (!hasPopup && realOpen && null == open) changeOpen(false);
|
|
213
146
|
}, [
|
|
@@ -216,363 +149,150 @@ function Popover(t0) {
|
|
|
216
149
|
open,
|
|
217
150
|
realOpen
|
|
218
151
|
]);
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
cancelTimers();
|
|
238
|
-
if (!realOpen) return;
|
|
239
|
-
const close = ()=>{
|
|
240
|
-
const { focusMode: focusMode_0, setOpen: setOpen_0 } = hoverState.current;
|
|
241
|
-
if (!focusMode_0 || !hasFocusWithin(triggerRef.current) && !hasFocusWithin(popupRef.current)) setOpen_0(false);
|
|
242
|
-
};
|
|
243
|
-
if (mouseLeaveDelay <= 0) return void close();
|
|
244
|
-
closeTimer.current = setTimeout(close, 1000 * mouseLeaveDelay);
|
|
245
|
-
};
|
|
246
|
-
$[22] = hoverState;
|
|
247
|
-
$[23] = mouseLeaveDelay;
|
|
248
|
-
$[24] = realOpen;
|
|
249
|
-
$[25] = t17;
|
|
250
|
-
} else t17 = $[25];
|
|
251
|
-
const scheduleClose = t17;
|
|
252
|
-
let t18;
|
|
253
|
-
if ($[26] !== changeOpen) {
|
|
254
|
-
t18 = (event)=>{
|
|
255
|
-
if (!containsFocusTarget(event.relatedTarget)) {
|
|
256
|
-
restoreAfterEscape.current = false;
|
|
257
|
-
changeOpen(false);
|
|
258
|
-
}
|
|
152
|
+
const scheduleOpen = useCallback(()=>{
|
|
153
|
+
cancelTimers();
|
|
154
|
+
if (realOpen) return;
|
|
155
|
+
if (mouseEnterDelay <= 0) return void setOpen(true);
|
|
156
|
+
openTimer.current = setTimeout(()=>hoverState.current.setOpen(true), 1000 * mouseEnterDelay);
|
|
157
|
+
}, [
|
|
158
|
+
cancelTimers,
|
|
159
|
+
hoverState,
|
|
160
|
+
mouseEnterDelay,
|
|
161
|
+
realOpen,
|
|
162
|
+
setOpen
|
|
163
|
+
]);
|
|
164
|
+
const scheduleClose = useCallback(()=>{
|
|
165
|
+
cancelTimers();
|
|
166
|
+
if (!realOpen) return;
|
|
167
|
+
const close = ()=>{
|
|
168
|
+
const { focusMode, setOpen } = hoverState.current;
|
|
169
|
+
if (!focusMode || !hasFocusWithin(triggerRef.current) && !hasFocusWithin(popupRef.current)) setOpen(false);
|
|
259
170
|
};
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
}
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
}
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
$[33] = t19;
|
|
285
|
-
} else t19 = $[33];
|
|
286
|
-
const hoverProps = t19;
|
|
287
|
-
let t20;
|
|
288
|
-
if ($[34] !== changeOpen || $[35] !== focusMode) {
|
|
289
|
-
t20 = focusMode ? ()=>{
|
|
171
|
+
if (mouseLeaveDelay <= 0) return void close();
|
|
172
|
+
closeTimer.current = setTimeout(close, 1000 * mouseLeaveDelay);
|
|
173
|
+
}, [
|
|
174
|
+
cancelTimers,
|
|
175
|
+
hoverState,
|
|
176
|
+
mouseLeaveDelay,
|
|
177
|
+
realOpen
|
|
178
|
+
]);
|
|
179
|
+
const handleBlur = useCallback((event)=>{
|
|
180
|
+
if (!containsFocusTarget(event.relatedTarget)) {
|
|
181
|
+
restoreAfterEscape.current = false;
|
|
182
|
+
changeOpen(false);
|
|
183
|
+
}
|
|
184
|
+
}, [
|
|
185
|
+
changeOpen,
|
|
186
|
+
containsFocusTarget
|
|
187
|
+
]);
|
|
188
|
+
const hoverProps = hasPopup && hoverMode ? {
|
|
189
|
+
onPointerEnter: scheduleOpen,
|
|
190
|
+
onPointerLeave: scheduleClose
|
|
191
|
+
} : void 0;
|
|
192
|
+
const triggerProps = hasPopup ? {
|
|
193
|
+
...hoverProps,
|
|
194
|
+
onFocus: focusMode ? ()=>{
|
|
290
195
|
if (!restoringFocus.current) changeOpen(true);
|
|
291
|
-
} : void 0
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
const t21 = focusMode ? handleBlur : void 0;
|
|
297
|
-
let t22;
|
|
298
|
-
if ($[37] !== changeOpen || $[38] !== contextMenuMode) {
|
|
299
|
-
t22 = contextMenuMode ? (event_0)=>{
|
|
300
|
-
if (event_0.defaultPrevented) return;
|
|
301
|
-
event_0.preventDefault();
|
|
196
|
+
} : void 0,
|
|
197
|
+
onBlur: focusMode ? handleBlur : void 0,
|
|
198
|
+
onContextMenu: contextMenuMode ? (event)=>{
|
|
199
|
+
if (event.defaultPrevented) return;
|
|
200
|
+
event.preventDefault();
|
|
302
201
|
changeOpen(true);
|
|
303
|
-
} : void 0
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
};
|
|
396
|
-
$[60] = shouldDestroy;
|
|
397
|
-
$[61] = t44;
|
|
398
|
-
} else t44 = $[61];
|
|
399
|
-
const t45 = focusMode ? cancelTimers : void 0;
|
|
400
|
-
const t46 = focusMode ? handleBlur : void 0;
|
|
401
|
-
let t47;
|
|
402
|
-
if ($[62] === Symbol.for("react.memo_cache_sentinel")) {
|
|
403
|
-
t47 = (event_3)=>{
|
|
404
|
-
if (containsTrigger(event_3.target)) event_3.preventDefault();
|
|
405
|
-
};
|
|
406
|
-
$[62] = t47;
|
|
407
|
-
} else t47 = $[62];
|
|
408
|
-
let t48;
|
|
409
|
-
if ($[63] !== focusMode) {
|
|
410
|
-
t48 = (event_4)=>{
|
|
411
|
-
if (focusMode) event_4.preventDefault();
|
|
412
|
-
};
|
|
413
|
-
$[63] = focusMode;
|
|
414
|
-
$[64] = t48;
|
|
415
|
-
} else t48 = $[64];
|
|
416
|
-
const T1 = popover_PopoverSurface;
|
|
417
|
-
const t49 = "";
|
|
418
|
-
const t50 = classNames?.container;
|
|
419
|
-
let t51;
|
|
420
|
-
if ($[65] !== t50) {
|
|
421
|
-
t51 = cx(t50);
|
|
422
|
-
$[65] = t50;
|
|
423
|
-
$[66] = t51;
|
|
424
|
-
} else t51 = $[66];
|
|
425
|
-
const t52 = styles?.container;
|
|
426
|
-
const t53 = isRenderable(titleNode) && /*#__PURE__*/ jsx("div", {
|
|
427
|
-
"data-tao-popover-title": "",
|
|
428
|
-
id: titleId,
|
|
429
|
-
className: cx(classNames?.title),
|
|
430
|
-
style: styles?.title,
|
|
431
|
-
children: titleNode
|
|
432
|
-
});
|
|
433
|
-
const t54 = isRenderable(contentNode) && /*#__PURE__*/ jsx("div", {
|
|
434
|
-
"data-tao-popover-content": "",
|
|
435
|
-
className: cx(classNames?.content),
|
|
436
|
-
style: styles?.content,
|
|
437
|
-
children: contentNode
|
|
438
|
-
});
|
|
439
|
-
let t55;
|
|
440
|
-
if ($[67] !== t51 || $[68] !== t52 || $[69] !== t53 || $[70] !== t54) {
|
|
441
|
-
t55 = /*#__PURE__*/ jsxs("div", {
|
|
442
|
-
"data-tao-popover-container": t49,
|
|
443
|
-
className: t51,
|
|
444
|
-
style: t52,
|
|
445
|
-
children: [
|
|
446
|
-
t53,
|
|
447
|
-
t54
|
|
448
|
-
]
|
|
449
|
-
});
|
|
450
|
-
$[67] = t51;
|
|
451
|
-
$[68] = t52;
|
|
452
|
-
$[69] = t53;
|
|
453
|
-
$[70] = t54;
|
|
454
|
-
$[71] = t55;
|
|
455
|
-
} else t55 = $[71];
|
|
456
|
-
let t56;
|
|
457
|
-
if ($[72] !== arrow || $[73] !== classNames?.arrow || $[74] !== styles?.arrow) {
|
|
458
|
-
t56 = false !== arrow && /*#__PURE__*/ jsx(__rspack_external__radix_ui_react_popover_c8444160.Arrow, {
|
|
459
|
-
asChild: true,
|
|
460
|
-
children: /*#__PURE__*/ jsx("span", {
|
|
461
|
-
"data-tao-popover-arrow": "",
|
|
462
|
-
className: cx(classNames?.arrow),
|
|
463
|
-
style: styles?.arrow
|
|
202
|
+
} : void 0
|
|
203
|
+
} : void 0;
|
|
204
|
+
return /*#__PURE__*/ jsxs(__rspack_external__radix_ui_react_popover_c8444160.Root, {
|
|
205
|
+
open: hasPopup && realOpen,
|
|
206
|
+
onOpenChange: changeOpen,
|
|
207
|
+
children: [
|
|
208
|
+
/*#__PURE__*/ jsx(TriggerPrimitive, {
|
|
209
|
+
asChild: true,
|
|
210
|
+
ref: setTriggerRef,
|
|
211
|
+
...triggerProps,
|
|
212
|
+
children: asTriggerChild(children)
|
|
213
|
+
}),
|
|
214
|
+
hasPopup && /*#__PURE__*/ jsx(__rspack_external__radix_ui_react_popover_c8444160.Portal, {
|
|
215
|
+
forceMount: shouldDestroy ? void 0 : true,
|
|
216
|
+
children: /*#__PURE__*/ jsx(TaoPortalScope, {
|
|
217
|
+
asChild: true,
|
|
218
|
+
direction: direction,
|
|
219
|
+
children: /*#__PURE__*/ jsx(__rspack_external__radix_ui_react_popover_c8444160.Content, {
|
|
220
|
+
asChild: true,
|
|
221
|
+
ref: popupRef,
|
|
222
|
+
"aria-label": ariaLabel,
|
|
223
|
+
"aria-labelledby": ariaLabelledBy ?? (!ariaLabel && isRenderable(titleNode) ? titleId : void 0),
|
|
224
|
+
"aria-describedby": ariaDescribedBy,
|
|
225
|
+
"data-tao-popover": "",
|
|
226
|
+
"data-tao-placement": placement,
|
|
227
|
+
"data-tao-keep-alive": !shouldDestroy || void 0,
|
|
228
|
+
className: cx(classNames?.root, className),
|
|
229
|
+
style: {
|
|
230
|
+
...styles?.root,
|
|
231
|
+
...style
|
|
232
|
+
},
|
|
233
|
+
...placementProps,
|
|
234
|
+
align: 'rtl' === direction && ('top' === placementProps.side || 'bottom' === placementProps.side) && 'center' !== placementProps.align ? 'start' === placementProps.align ? 'end' : 'start' : placementProps.align,
|
|
235
|
+
sideOffset: 4,
|
|
236
|
+
forceMount: shouldDestroy ? void 0 : true,
|
|
237
|
+
onOpenAutoFocus: (event)=>event.preventDefault(),
|
|
238
|
+
onEscapeKeyDown: ()=>{
|
|
239
|
+
restoreAfterEscape.current = focusMode && !!popupRef.current?.contains(document.activeElement);
|
|
240
|
+
},
|
|
241
|
+
onCloseAutoFocus: (event)=>{
|
|
242
|
+
const focusedRetainedContent = !shouldDestroy && event.currentTarget instanceof HTMLElement && event.currentTarget.contains(document.activeElement);
|
|
243
|
+
if (restoreAfterEscape.current || focusedRetainedContent) {
|
|
244
|
+
restoreAfterEscape.current = false;
|
|
245
|
+
event.preventDefault();
|
|
246
|
+
restoringFocus.current = true;
|
|
247
|
+
triggerRef.current?.focus();
|
|
248
|
+
restoringFocus.current = false;
|
|
249
|
+
}
|
|
250
|
+
},
|
|
251
|
+
onFocusCapture: focusMode ? cancelTimers : void 0,
|
|
252
|
+
onBlurCapture: focusMode ? handleBlur : void 0,
|
|
253
|
+
onInteractOutside: (event)=>{
|
|
254
|
+
if (containsTrigger(event.target)) event.preventDefault();
|
|
255
|
+
},
|
|
256
|
+
onFocusOutside: (event)=>{
|
|
257
|
+
if (focusMode) event.preventDefault();
|
|
258
|
+
},
|
|
259
|
+
...hoverProps,
|
|
260
|
+
children: /*#__PURE__*/ jsxs(popover_PopoverSurface, {
|
|
261
|
+
children: [
|
|
262
|
+
/*#__PURE__*/ jsxs("div", {
|
|
263
|
+
"data-tao-popover-container": "",
|
|
264
|
+
className: cx(classNames?.container),
|
|
265
|
+
style: styles?.container,
|
|
266
|
+
children: [
|
|
267
|
+
isRenderable(titleNode) && /*#__PURE__*/ jsx("div", {
|
|
268
|
+
"data-tao-popover-title": "",
|
|
269
|
+
id: titleId,
|
|
270
|
+
className: cx(classNames?.title),
|
|
271
|
+
style: styles?.title,
|
|
272
|
+
children: titleNode
|
|
273
|
+
}),
|
|
274
|
+
isRenderable(contentNode) && /*#__PURE__*/ jsx("div", {
|
|
275
|
+
"data-tao-popover-content": "",
|
|
276
|
+
className: cx(classNames?.content),
|
|
277
|
+
style: styles?.content,
|
|
278
|
+
children: contentNode
|
|
279
|
+
})
|
|
280
|
+
]
|
|
281
|
+
}),
|
|
282
|
+
false !== arrow && /*#__PURE__*/ jsx(__rspack_external__radix_ui_react_popover_c8444160.Arrow, {
|
|
283
|
+
asChild: true,
|
|
284
|
+
children: /*#__PURE__*/ jsx("span", {
|
|
285
|
+
"data-tao-popover-arrow": "",
|
|
286
|
+
className: cx(classNames?.arrow),
|
|
287
|
+
style: styles?.arrow
|
|
288
|
+
})
|
|
289
|
+
})
|
|
290
|
+
]
|
|
291
|
+
})
|
|
292
|
+
})
|
|
293
|
+
})
|
|
464
294
|
})
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
$[73] = classNames?.arrow;
|
|
468
|
-
$[74] = styles?.arrow;
|
|
469
|
-
$[75] = t56;
|
|
470
|
-
} else t56 = $[75];
|
|
471
|
-
let t57;
|
|
472
|
-
if ($[76] !== T1 || $[77] !== t55 || $[78] !== t56) {
|
|
473
|
-
t57 = /*#__PURE__*/ jsxs(T1, {
|
|
474
|
-
children: [
|
|
475
|
-
t55,
|
|
476
|
-
t56
|
|
477
|
-
]
|
|
478
|
-
});
|
|
479
|
-
$[76] = T1;
|
|
480
|
-
$[77] = t55;
|
|
481
|
-
$[78] = t56;
|
|
482
|
-
$[79] = t57;
|
|
483
|
-
} else t57 = $[79];
|
|
484
|
-
let t58;
|
|
485
|
-
if ($[80] !== ariaDescribedBy || $[81] !== ariaLabel || $[82] !== hoverProps || $[83] !== placement || $[84] !== placementProps || $[85] !== t30.Content || $[86] !== t32 || $[87] !== t34 || $[88] !== t36 || $[89] !== t38 || $[90] !== t39 || $[91] !== t41 || $[92] !== t42 || $[93] !== t43 || $[94] !== t44 || $[95] !== t45 || $[96] !== t46 || $[97] !== t47 || $[98] !== t48 || $[99] !== t57) {
|
|
486
|
-
t58 = /*#__PURE__*/ jsx(t30.Content, {
|
|
487
|
-
asChild: t31,
|
|
488
|
-
ref: popupRef,
|
|
489
|
-
"aria-label": ariaLabel,
|
|
490
|
-
"aria-labelledby": t32,
|
|
491
|
-
"aria-describedby": ariaDescribedBy,
|
|
492
|
-
"data-tao-popover": t33,
|
|
493
|
-
"data-tao-placement": placement,
|
|
494
|
-
"data-tao-keep-alive": t34,
|
|
495
|
-
className: t36,
|
|
496
|
-
style: t38,
|
|
497
|
-
...placementProps,
|
|
498
|
-
align: t39,
|
|
499
|
-
sideOffset: t40,
|
|
500
|
-
forceMount: t41,
|
|
501
|
-
onOpenAutoFocus: t42,
|
|
502
|
-
onEscapeKeyDown: t43,
|
|
503
|
-
onCloseAutoFocus: t44,
|
|
504
|
-
onFocusCapture: t45,
|
|
505
|
-
onBlurCapture: t46,
|
|
506
|
-
onInteractOutside: t47,
|
|
507
|
-
onFocusOutside: t48,
|
|
508
|
-
...hoverProps,
|
|
509
|
-
children: t57
|
|
510
|
-
});
|
|
511
|
-
$[80] = ariaDescribedBy;
|
|
512
|
-
$[81] = ariaLabel;
|
|
513
|
-
$[82] = hoverProps;
|
|
514
|
-
$[83] = placement;
|
|
515
|
-
$[84] = placementProps;
|
|
516
|
-
$[85] = t30.Content;
|
|
517
|
-
$[86] = t32;
|
|
518
|
-
$[87] = t34;
|
|
519
|
-
$[88] = t36;
|
|
520
|
-
$[89] = t38;
|
|
521
|
-
$[90] = t39;
|
|
522
|
-
$[91] = t41;
|
|
523
|
-
$[92] = t42;
|
|
524
|
-
$[93] = t43;
|
|
525
|
-
$[94] = t44;
|
|
526
|
-
$[95] = t45;
|
|
527
|
-
$[96] = t46;
|
|
528
|
-
$[97] = t47;
|
|
529
|
-
$[98] = t48;
|
|
530
|
-
$[99] = t57;
|
|
531
|
-
$[100] = t58;
|
|
532
|
-
} else t58 = $[100];
|
|
533
|
-
let t59;
|
|
534
|
-
if ($[101] !== T0 || $[102] !== direction || $[103] !== t58) {
|
|
535
|
-
t59 = /*#__PURE__*/ jsx(T0, {
|
|
536
|
-
asChild: t29,
|
|
537
|
-
direction: direction,
|
|
538
|
-
children: t58
|
|
539
|
-
});
|
|
540
|
-
$[101] = T0;
|
|
541
|
-
$[102] = direction;
|
|
542
|
-
$[103] = t58;
|
|
543
|
-
$[104] = t59;
|
|
544
|
-
} else t59 = $[104];
|
|
545
|
-
let t60;
|
|
546
|
-
if ($[105] !== t27.Portal || $[106] !== t28 || $[107] !== t59) {
|
|
547
|
-
t60 = /*#__PURE__*/ jsx(t27.Portal, {
|
|
548
|
-
forceMount: t28,
|
|
549
|
-
children: t59
|
|
550
|
-
});
|
|
551
|
-
$[105] = t27.Portal;
|
|
552
|
-
$[106] = t28;
|
|
553
|
-
$[107] = t59;
|
|
554
|
-
$[108] = t60;
|
|
555
|
-
} else t60 = $[108];
|
|
556
|
-
let t61;
|
|
557
|
-
if ($[109] !== changeOpen || $[110] !== realOpen || $[111] !== t24.Root || $[112] !== t26 || $[113] !== t60) {
|
|
558
|
-
t61 = /*#__PURE__*/ jsxs(t24.Root, {
|
|
559
|
-
open: realOpen,
|
|
560
|
-
onOpenChange: changeOpen,
|
|
561
|
-
children: [
|
|
562
|
-
t26,
|
|
563
|
-
t60
|
|
564
|
-
]
|
|
565
|
-
});
|
|
566
|
-
$[109] = changeOpen;
|
|
567
|
-
$[110] = realOpen;
|
|
568
|
-
$[111] = t24.Root;
|
|
569
|
-
$[112] = t26;
|
|
570
|
-
$[113] = t60;
|
|
571
|
-
$[114] = t61;
|
|
572
|
-
} else t61 = $[114];
|
|
573
|
-
return t61;
|
|
574
|
-
}
|
|
575
|
-
function _temp(event_1) {
|
|
576
|
-
return event_1.preventDefault();
|
|
295
|
+
]
|
|
296
|
+
});
|
|
577
297
|
}
|
|
578
298
|
export { Popover };
|