@42-central/ui-react 0.20.0 → 0.20.2
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/{chunk-P276SCCV.js → chunk-2BNIHOMT.js} +6 -6
- package/dist/{chunk-P276SCCV.js.map → chunk-2BNIHOMT.js.map} +1 -1
- package/dist/{chunk-PAFS7TED.js → chunk-2HIX6DKN.js} +3 -3
- package/dist/{chunk-PAFS7TED.js.map → chunk-2HIX6DKN.js.map} +1 -1
- package/dist/{chunk-Z5WYYDG2.js → chunk-2MXWEIMD.js} +7 -4
- package/dist/chunk-2MXWEIMD.js.map +1 -0
- package/dist/{chunk-VVM7JMZS.js → chunk-37VQGKD6.js} +8 -8
- package/dist/{chunk-VVM7JMZS.js.map → chunk-37VQGKD6.js.map} +1 -1
- package/dist/{chunk-7R4CDHBK.js → chunk-45QRQKRC.js} +4 -4
- package/dist/{chunk-7R4CDHBK.js.map → chunk-45QRQKRC.js.map} +1 -1
- package/dist/{chunk-FZNPJAGJ.js → chunk-45TG7H5Q.js} +5 -5
- package/dist/{chunk-FZNPJAGJ.js.map → chunk-45TG7H5Q.js.map} +1 -1
- package/dist/{chunk-MKJKCBRE.js → chunk-47LEAR6G.js} +6 -6
- package/dist/{chunk-MKJKCBRE.js.map → chunk-47LEAR6G.js.map} +1 -1
- package/dist/chunk-4ASNIDV7.js +17 -0
- package/dist/chunk-4ASNIDV7.js.map +1 -0
- package/dist/{chunk-WFHY6NRQ.js → chunk-5CNVVA7I.js} +11 -11
- package/dist/{chunk-WFHY6NRQ.js.map → chunk-5CNVVA7I.js.map} +1 -1
- package/dist/{chunk-2TM7UVM2.js → chunk-6M6YZ3PQ.js} +4 -4
- package/dist/{chunk-2TM7UVM2.js.map → chunk-6M6YZ3PQ.js.map} +1 -1
- package/dist/{chunk-4BGU2UQB.js → chunk-6VYGK3Q3.js} +6 -6
- package/dist/{chunk-4BGU2UQB.js.map → chunk-6VYGK3Q3.js.map} +1 -1
- package/dist/{chunk-ZFUTGBJC.js → chunk-6YNLRQ25.js} +3 -3
- package/dist/{chunk-ZFUTGBJC.js.map → chunk-6YNLRQ25.js.map} +1 -1
- package/dist/{chunk-6OV6EJQ2.js → chunk-7AQ4MN4M.js} +6 -6
- package/dist/{chunk-6OV6EJQ2.js.map → chunk-7AQ4MN4M.js.map} +1 -1
- package/dist/{chunk-5337N3FE.js → chunk-7BOSX65U.js} +3 -3
- package/dist/{chunk-5337N3FE.js.map → chunk-7BOSX65U.js.map} +1 -1
- package/dist/{chunk-THLMW5IU.js → chunk-7CNDZZZ6.js} +4 -4
- package/dist/{chunk-THLMW5IU.js.map → chunk-7CNDZZZ6.js.map} +1 -1
- package/dist/{chunk-LJ3GHC4V.js → chunk-BE2LWUHY.js} +5 -5
- package/dist/{chunk-LJ3GHC4V.js.map → chunk-BE2LWUHY.js.map} +1 -1
- package/dist/{chunk-2KN3MI7I.js → chunk-C4NFRSOR.js} +4 -4
- package/dist/{chunk-2KN3MI7I.js.map → chunk-C4NFRSOR.js.map} +1 -1
- package/dist/{chunk-3REFDGOM.js → chunk-C6NVU4F7.js} +3 -3
- package/dist/{chunk-3REFDGOM.js.map → chunk-C6NVU4F7.js.map} +1 -1
- package/dist/{chunk-LSIX2PVU.js → chunk-C74TV64U.js} +7 -7
- package/dist/{chunk-LSIX2PVU.js.map → chunk-C74TV64U.js.map} +1 -1
- package/dist/{chunk-HVOEVB4E.js → chunk-D2QIPQ74.js} +3 -3
- package/dist/{chunk-HVOEVB4E.js.map → chunk-D2QIPQ74.js.map} +1 -1
- package/dist/{chunk-4EU6FGGB.js → chunk-DA4QII2N.js} +4 -4
- package/dist/{chunk-4EU6FGGB.js.map → chunk-DA4QII2N.js.map} +1 -1
- package/dist/{chunk-LZWA7V62.js → chunk-DJLNGWMM.js} +5 -5
- package/dist/{chunk-LZWA7V62.js.map → chunk-DJLNGWMM.js.map} +1 -1
- package/dist/{chunk-HEQ2H6VO.js → chunk-DT6LKNZF.js} +4 -4
- package/dist/{chunk-HEQ2H6VO.js.map → chunk-DT6LKNZF.js.map} +1 -1
- package/dist/{chunk-BUFALAEK.js → chunk-E5H3YWZV.js} +4 -4
- package/dist/{chunk-BUFALAEK.js.map → chunk-E5H3YWZV.js.map} +1 -1
- package/dist/{chunk-H7INUXZD.js → chunk-F342ZT7O.js} +4 -4
- package/dist/{chunk-H7INUXZD.js.map → chunk-F342ZT7O.js.map} +1 -1
- package/dist/{chunk-KOT4PWGE.js → chunk-FDCPMUJK.js} +6 -6
- package/dist/{chunk-KOT4PWGE.js.map → chunk-FDCPMUJK.js.map} +1 -1
- package/dist/{chunk-VALQ2XVA.js → chunk-H3PYSAWN.js} +3 -3
- package/dist/{chunk-VALQ2XVA.js.map → chunk-H3PYSAWN.js.map} +1 -1
- package/dist/{chunk-WR444JRU.js → chunk-HQPU73WV.js} +7 -7
- package/dist/{chunk-WR444JRU.js.map → chunk-HQPU73WV.js.map} +1 -1
- package/dist/{chunk-Q5ZO2O25.js → chunk-HRNWWL3Y.js} +6 -6
- package/dist/{chunk-Q5ZO2O25.js.map → chunk-HRNWWL3Y.js.map} +1 -1
- package/dist/{chunk-HBFN5W7Q.js → chunk-JVG5ISPT.js} +4 -4
- package/dist/{chunk-HBFN5W7Q.js.map → chunk-JVG5ISPT.js.map} +1 -1
- package/dist/{chunk-JL4QMM46.js → chunk-LFQDB5OD.js} +5 -5
- package/dist/{chunk-JL4QMM46.js.map → chunk-LFQDB5OD.js.map} +1 -1
- package/dist/{chunk-U2PNMMDB.js → chunk-LKFHUDEW.js} +7 -7
- package/dist/{chunk-U2PNMMDB.js.map → chunk-LKFHUDEW.js.map} +1 -1
- package/dist/{chunk-2SVX3MQQ.js → chunk-MW42XVPD.js} +3 -3
- package/dist/{chunk-2SVX3MQQ.js.map → chunk-MW42XVPD.js.map} +1 -1
- package/dist/{chunk-S4TRYMCU.js → chunk-MXAACRWE.js} +6 -6
- package/dist/{chunk-S4TRYMCU.js.map → chunk-MXAACRWE.js.map} +1 -1
- package/dist/{chunk-ZN3WYGIQ.js → chunk-N66NC6QK.js} +121 -25
- package/dist/chunk-N66NC6QK.js.map +1 -0
- package/dist/{chunk-DUPE2CRU.js → chunk-NKOTA5TM.js} +3 -3
- package/dist/{chunk-DUPE2CRU.js.map → chunk-NKOTA5TM.js.map} +1 -1
- package/dist/{chunk-RGLNH7A5.js → chunk-NLOBBJAA.js} +3 -3
- package/dist/{chunk-RGLNH7A5.js.map → chunk-NLOBBJAA.js.map} +1 -1
- package/dist/{chunk-FXDLS23K.js → chunk-NS6RGPWR.js} +3 -3
- package/dist/{chunk-FXDLS23K.js.map → chunk-NS6RGPWR.js.map} +1 -1
- package/dist/{chunk-ZWOZL4XX.js → chunk-O5W3QWJ6.js} +5 -5
- package/dist/{chunk-ZWOZL4XX.js.map → chunk-O5W3QWJ6.js.map} +1 -1
- package/dist/{chunk-PD4FX34E.js → chunk-O7LS6OZR.js} +4 -4
- package/dist/{chunk-PD4FX34E.js.map → chunk-O7LS6OZR.js.map} +1 -1
- package/dist/{chunk-K6BHDFX3.js → chunk-QKSLDQM2.js} +3 -3
- package/dist/{chunk-K6BHDFX3.js.map → chunk-QKSLDQM2.js.map} +1 -1
- package/dist/{chunk-CDHIF2NV.js → chunk-QNKD2SQM.js} +8 -8
- package/dist/{chunk-CDHIF2NV.js.map → chunk-QNKD2SQM.js.map} +1 -1
- package/dist/{chunk-SE3CGQRO.js → chunk-RLOWPCGG.js} +3 -3
- package/dist/{chunk-SE3CGQRO.js.map → chunk-RLOWPCGG.js.map} +1 -1
- package/dist/{chunk-R57QP43T.js → chunk-SVKN5ZHX.js} +4 -4
- package/dist/{chunk-R57QP43T.js.map → chunk-SVKN5ZHX.js.map} +1 -1
- package/dist/{chunk-NJ4RO3CT.js → chunk-SWVUXEBT.js} +5 -5
- package/dist/{chunk-NJ4RO3CT.js.map → chunk-SWVUXEBT.js.map} +1 -1
- package/dist/{chunk-GGT4GJD6.js → chunk-TWNIAF7K.js} +3 -3
- package/dist/{chunk-GGT4GJD6.js.map → chunk-TWNIAF7K.js.map} +1 -1
- package/dist/{chunk-4TCTMRR5.js → chunk-UAYENYS2.js} +5 -5
- package/dist/{chunk-4TCTMRR5.js.map → chunk-UAYENYS2.js.map} +1 -1
- package/dist/{chunk-DHTSVJ4G.js → chunk-UCCJUFOG.js} +9 -9
- package/dist/{chunk-DHTSVJ4G.js.map → chunk-UCCJUFOG.js.map} +1 -1
- package/dist/{chunk-HDRC6ITF.js → chunk-UT3TOV2Q.js} +3 -3
- package/dist/{chunk-HDRC6ITF.js.map → chunk-UT3TOV2Q.js.map} +1 -1
- package/dist/{chunk-6KER77RS.js → chunk-UVQXRDRO.js} +7 -7
- package/dist/{chunk-6KER77RS.js.map → chunk-UVQXRDRO.js.map} +1 -1
- package/dist/{chunk-R52P43LZ.js → chunk-UXPINIDN.js} +3 -3
- package/dist/{chunk-R52P43LZ.js.map → chunk-UXPINIDN.js.map} +1 -1
- package/dist/chunk-V6PY7C6S.js +18 -0
- package/dist/chunk-V6PY7C6S.js.map +1 -0
- package/dist/{chunk-45DFYIK5.js → chunk-VD6PB3VA.js} +3 -3
- package/dist/{chunk-45DFYIK5.js.map → chunk-VD6PB3VA.js.map} +1 -1
- package/dist/{chunk-7AWOMWCQ.js → chunk-WXL5RP6P.js} +7 -7
- package/dist/{chunk-7AWOMWCQ.js.map → chunk-WXL5RP6P.js.map} +1 -1
- package/dist/{chunk-IMP5VHEN.js → chunk-XKDL4QS6.js} +3 -3
- package/dist/{chunk-IMP5VHEN.js.map → chunk-XKDL4QS6.js.map} +1 -1
- package/dist/{chunk-H26K66EU.js → chunk-Y57NW6G7.js} +3 -3
- package/dist/{chunk-H26K66EU.js.map → chunk-Y57NW6G7.js.map} +1 -1
- package/dist/{chunk-2OQP7UY4.js → chunk-YZJUPYPO.js} +5 -5
- package/dist/{chunk-2OQP7UY4.js.map → chunk-YZJUPYPO.js.map} +1 -1
- package/dist/{chunk-JYK6JVR3.js → chunk-Z4MBCKG5.js} +8 -8
- package/dist/{chunk-JYK6JVR3.js.map → chunk-Z4MBCKG5.js.map} +1 -1
- package/dist/components/accordion/index.js +5 -5
- package/dist/components/action-icon/index.js +4 -4
- package/dist/components/alert/index.js +6 -6
- package/dist/components/ambient-background/index.js +1 -1
- package/dist/components/app-shell/index.js +6 -6
- package/dist/components/aspect-ratio/index.js +1 -1
- package/dist/components/autocomplete/index.js +7 -6
- package/dist/components/autocomplete/index.js.map +1 -1
- package/dist/components/avatar/index.js +1 -1
- package/dist/components/badge/index.js +3 -3
- package/dist/components/breadcrumb/index.js +1 -1
- package/dist/components/button/index.js +4 -4
- package/dist/components/button-group/index.js +2 -2
- package/dist/components/button-multi-select/index.js +7 -7
- package/dist/components/button-select/index.js +7 -7
- package/dist/components/calendar/index.js +6 -6
- package/dist/components/camera/index.js +15 -14
- package/dist/components/card/card.d.ts.map +1 -1
- package/dist/components/card/index.js +2 -2
- package/dist/components/carousel/index.js +3 -3
- package/dist/components/chart/index.js +1 -1
- package/dist/components/checkbox/index.js +6 -6
- package/dist/components/choice-card-group/index.js +5 -5
- package/dist/components/circular-progress/index.js +1 -1
- package/dist/components/clipboard/index.js +6 -6
- package/dist/components/code/index.js +2 -2
- package/dist/components/code-block/chrome.js +7 -7
- package/dist/components/code-block/index.js +8 -8
- package/dist/components/code-block/static.js +4 -1
- package/dist/components/code-block/static.js.map +1 -1
- package/dist/components/collapse/index.js +2 -2
- package/dist/components/combobox/index.js +7 -6
- package/dist/components/combobox-list/index.js +9 -8
- package/dist/components/compare/index.js +2 -2
- package/dist/components/container/index.js +1 -1
- package/dist/components/data-table/index.js +33 -33
- package/dist/components/date-picker/index.js +16 -15
- package/dist/components/date-picker/index.js.map +1 -1
- package/dist/components/divider/index.js +2 -2
- package/dist/components/download-button/index.js +5 -5
- package/dist/components/drawer/index.js +6 -6
- package/dist/components/field/index.js +2 -2
- package/dist/components/figure/index.js +2 -2
- package/dist/components/file-item/index.js +8 -8
- package/dist/components/file-preview/index.js +6 -6
- package/dist/components/file-queue-summary/index.js +2 -2
- package/dist/components/file-trigger/index.js +5 -5
- package/dist/components/file-upload/index.js +10 -10
- package/dist/components/flex/index.js +2 -2
- package/dist/components/gallery/index.js +4 -4
- package/dist/components/grid/index.js +1 -1
- package/dist/components/hover-card/hover-card.d.ts +44 -26
- package/dist/components/hover-card/hover-card.d.ts.map +1 -1
- package/dist/components/hover-card/index.js +36 -54
- package/dist/components/hover-card/index.js.map +1 -1
- package/dist/components/image/index.js +2 -2
- package/dist/components/image-cropper/index.js +7 -7
- package/dist/components/indicator/index.js +1 -1
- package/dist/components/input/index.js +3 -3
- package/dist/components/kbd/index.js +3 -3
- package/dist/components/lightbox/index.js +9 -9
- package/dist/components/mark/index.js +2 -2
- package/dist/components/menu/index.js +5 -5
- package/dist/components/modal/index.js +6 -6
- package/dist/components/multi-combobox-list/index.js +11 -10
- package/dist/components/multi-select/index.js +10 -9
- package/dist/components/multi-select/index.js.map +1 -1
- package/dist/components/nav-link/index.js +5 -5
- package/dist/components/nav-link/tanstack.js +5 -5
- package/dist/components/notification/index.js +7 -7
- package/dist/components/number-input/index.js +7 -6
- package/dist/components/overlays/index.js +8 -8
- package/dist/components/password-input/index.js +4 -4
- package/dist/components/photo-capture/index.js +18 -17
- package/dist/components/photo-capture/index.js.map +1 -1
- package/dist/components/pill/index.js +3 -3
- package/dist/components/pills-input/index.js +6 -6
- package/dist/components/pin-input/index.js +3 -3
- package/dist/components/popover/index.d.ts +1 -1
- package/dist/components/popover/index.d.ts.map +1 -1
- package/dist/components/popover/index.js +3 -2
- package/dist/components/popover/popover.d.ts +44 -29
- package/dist/components/popover/popover.d.ts.map +1 -1
- package/dist/components/progress/index.js +2 -2
- package/dist/components/radio-group/index.js +4 -4
- package/dist/components/rating/index.js +3 -3
- package/dist/components/schedule/index.js +10 -10
- package/dist/components/segment-group/index.js +3 -3
- package/dist/components/select/index.js +8 -7
- package/dist/components/skeleton/index.js +2 -2
- package/dist/components/slider/index.js +4 -4
- package/dist/components/spinner/index.js +2 -2
- package/dist/components/spotlight/index.js +16 -15
- package/dist/components/spotlight/index.js.map +1 -1
- package/dist/components/switch/index.js +3 -3
- package/dist/components/table/index.js +3 -3
- package/dist/components/tabs/index.js +3 -3
- package/dist/components/tags-input/index.js +9 -8
- package/dist/components/tags-input/index.js.map +1 -1
- package/dist/components/text/index.js +2 -2
- package/dist/components/text-input/index.js +3 -3
- package/dist/components/textarea/index.js +3 -3
- package/dist/components/theme-icon/index.js +3 -3
- package/dist/components/time-input/index.js +9 -8
- package/dist/components/time-input/index.js.map +1 -1
- package/dist/components/timeline/index.js +1 -1
- package/dist/components/title/index.js +2 -2
- package/dist/components/tooltip/index.js +4 -4
- package/dist/components/tree-multi-select/index.js +11 -10
- package/dist/components/tree-multi-select/index.js.map +1 -1
- package/dist/components/tree-select/index.js +8 -7
- package/dist/components/tree-select/index.js.map +1 -1
- package/dist/index.js +2 -2
- package/dist/lib/cn.d.ts.map +1 -1
- package/dist/lib/cn.js +1 -1
- package/dist/lib/placement.d.ts +42 -1
- package/dist/lib/placement.d.ts.map +1 -1
- package/dist/lib/slide-on-switch.d.ts +69 -0
- package/dist/lib/slide-on-switch.d.ts.map +1 -0
- package/package.json +1 -1
- package/src/components/card/card.test.tsx +10 -0
- package/src/components/card/card.tsx +4 -1
- package/src/components/hover-card/hover-card.tsx +89 -167
- package/src/components/popover/index.ts +2 -0
- package/src/components/popover/popover.test.tsx +131 -0
- package/src/components/popover/popover.tsx +191 -53
- package/src/lib/cn.test.ts +9 -0
- package/src/lib/cn.ts +9 -1
- package/src/lib/placement.test.ts +37 -0
- package/src/lib/placement.ts +60 -1
- package/src/lib/slide-on-switch.ts +99 -0
- package/dist/chunk-G52U24GR.js +0 -10
- package/dist/chunk-G52U24GR.js.map +0 -1
- package/dist/chunk-QP4I37PA.js +0 -14
- package/dist/chunk-QP4I37PA.js.map +0 -1
- package/dist/chunk-Z5WYYDG2.js.map +0 -1
- package/dist/chunk-ZN3WYGIQ.js.map +0 -1
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import '../../chunk-FMMKEYHB.js';
|
|
3
|
-
export { Drawer } from '../../chunk-
|
|
4
|
-
import '../../chunk-
|
|
3
|
+
export { Drawer } from '../../chunk-O7LS6OZR.js';
|
|
4
|
+
import '../../chunk-DA4QII2N.js';
|
|
5
5
|
import '../../chunk-7P32XCEU.js';
|
|
6
6
|
import '../../chunk-H7WOMZXO.js';
|
|
7
|
-
import '../../chunk-
|
|
7
|
+
import '../../chunk-BE2LWUHY.js';
|
|
8
8
|
import '../../chunk-6N6J2DOE.js';
|
|
9
9
|
import '../../chunk-BUIHQJGE.js';
|
|
10
10
|
import '../../chunk-XXOR34T4.js';
|
|
11
|
-
import '../../chunk-
|
|
11
|
+
import '../../chunk-D2QIPQ74.js';
|
|
12
12
|
import '../../chunk-R5LYFTHA.js';
|
|
13
13
|
import '../../chunk-WYCMIIRR.js';
|
|
14
|
-
import '../../chunk-
|
|
14
|
+
import '../../chunk-C6NVU4F7.js';
|
|
15
15
|
import '../../chunk-GIPQUKCN.js';
|
|
16
|
-
import '../../chunk-
|
|
16
|
+
import '../../chunk-4ASNIDV7.js';
|
|
17
17
|
//# sourceMappingURL=index.js.map
|
|
18
18
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
export { Field } from '../../chunk-
|
|
2
|
+
export { Field } from '../../chunk-VD6PB3VA.js';
|
|
3
3
|
import '../../chunk-WYCMIIRR.js';
|
|
4
4
|
import '../../chunk-GIPQUKCN.js';
|
|
5
|
-
import '../../chunk-
|
|
5
|
+
import '../../chunk-4ASNIDV7.js';
|
|
6
6
|
//# sourceMappingURL=index.js.map
|
|
7
7
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { Figure } from '../../chunk-
|
|
1
|
+
export { Figure } from '../../chunk-2HIX6DKN.js';
|
|
2
2
|
import '../../chunk-J43LSYQO.js';
|
|
3
3
|
import '../../chunk-WYCMIIRR.js';
|
|
4
4
|
import '../../chunk-GIPQUKCN.js';
|
|
5
|
-
import '../../chunk-
|
|
5
|
+
import '../../chunk-4ASNIDV7.js';
|
|
6
6
|
//# sourceMappingURL=index.js.map
|
|
7
7
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
export { FileItem } from '../../chunk-
|
|
3
|
-
import '../../chunk-
|
|
2
|
+
export { FileItem } from '../../chunk-QNKD2SQM.js';
|
|
3
|
+
import '../../chunk-QKSLDQM2.js';
|
|
4
4
|
import '../../chunk-SDVZFXQ2.js';
|
|
5
|
-
import '../../chunk-
|
|
5
|
+
import '../../chunk-Y57NW6G7.js';
|
|
6
6
|
import '../../chunk-J43LSYQO.js';
|
|
7
7
|
import '../../chunk-SKPM2FRX.js';
|
|
8
|
-
import '../../chunk-
|
|
8
|
+
import '../../chunk-SWVUXEBT.js';
|
|
9
9
|
import '../../chunk-TCFB23JT.js';
|
|
10
10
|
import '../../chunk-EIBDLRAR.js';
|
|
11
11
|
import '../../chunk-HBWV5EPU.js';
|
|
@@ -13,13 +13,13 @@ import '../../chunk-AHM6SGEU.js';
|
|
|
13
13
|
import '../../chunk-IPYHTCFL.js';
|
|
14
14
|
import '../../chunk-6N6J2DOE.js';
|
|
15
15
|
import '../../chunk-BUIHQJGE.js';
|
|
16
|
-
import '../../chunk-
|
|
16
|
+
import '../../chunk-6YNLRQ25.js';
|
|
17
17
|
import '../../chunk-XXOR34T4.js';
|
|
18
|
-
import '../../chunk-
|
|
18
|
+
import '../../chunk-D2QIPQ74.js';
|
|
19
19
|
import '../../chunk-R5LYFTHA.js';
|
|
20
20
|
import '../../chunk-WYCMIIRR.js';
|
|
21
|
-
import '../../chunk-
|
|
21
|
+
import '../../chunk-C6NVU4F7.js';
|
|
22
22
|
import '../../chunk-GIPQUKCN.js';
|
|
23
|
-
import '../../chunk-
|
|
23
|
+
import '../../chunk-4ASNIDV7.js';
|
|
24
24
|
//# sourceMappingURL=index.js.map
|
|
25
25
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { FILE_KIND_ICONS } from '../../chunk-SDVZFXQ2.js';
|
|
3
|
-
import { DownloadButton, DOWNLOAD_BUTTON_DEFAULT_TRANSLATIONS } from '../../chunk-
|
|
4
|
-
import { Image } from '../../chunk-
|
|
3
|
+
import { DownloadButton, DOWNLOAD_BUTTON_DEFAULT_TRANSLATIONS } from '../../chunk-DJLNGWMM.js';
|
|
4
|
+
import { Image } from '../../chunk-Y57NW6G7.js';
|
|
5
5
|
import '../../chunk-J43LSYQO.js';
|
|
6
|
-
import { Button } from '../../chunk-
|
|
6
|
+
import { Button } from '../../chunk-SWVUXEBT.js';
|
|
7
7
|
import { openFile, extensionOf, formatFileSize, fileKind, viewableType, inlineType, useObjectUrl } from '../../chunk-TCFB23JT.js';
|
|
8
8
|
import '../../chunk-EIBDLRAR.js';
|
|
9
9
|
import { useMediaQuery } from '../../chunk-HDYORQZN.js';
|
|
@@ -13,12 +13,12 @@ import { useLocale } from '../../chunk-IPYHTCFL.js';
|
|
|
13
13
|
import '../../chunk-6N6J2DOE.js';
|
|
14
14
|
import { useIsomorphicLayoutEffect } from '../../chunk-BUIHQJGE.js';
|
|
15
15
|
import { mergeIcons, iconStroke } from '../../chunk-XXOR34T4.js';
|
|
16
|
-
import { Spinner } from '../../chunk-
|
|
16
|
+
import { Spinner } from '../../chunk-D2QIPQ74.js';
|
|
17
17
|
import { composeChildren } from '../../chunk-R5LYFTHA.js';
|
|
18
18
|
import { props } from '../../chunk-WYCMIIRR.js';
|
|
19
|
-
import { focusStyles } from '../../chunk-
|
|
19
|
+
import { focusStyles } from '../../chunk-C6NVU4F7.js';
|
|
20
20
|
import { TYPOGRAPHY_SHADE_CLASSES, TEXT_COLOR_CLASSES } from '../../chunk-GIPQUKCN.js';
|
|
21
|
-
import { cn } from '../../chunk-
|
|
21
|
+
import { cn } from '../../chunk-4ASNIDV7.js';
|
|
22
22
|
import { ark } from '@ark-ui/react';
|
|
23
23
|
import { CircleAlert, RotateCw, ExternalLink } from 'lucide-react';
|
|
24
24
|
import { createContext, useState, useRef, useContext, useSyncExternalStore, useEffect } from 'react';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
export { FileQueueSummary } from '../../chunk-
|
|
2
|
+
export { FileQueueSummary } from '../../chunk-7BOSX65U.js';
|
|
3
3
|
import '../../chunk-JYKP4RSG.js';
|
|
4
4
|
import '../../chunk-WYCMIIRR.js';
|
|
5
|
-
import '../../chunk-
|
|
5
|
+
import '../../chunk-4ASNIDV7.js';
|
|
6
6
|
//# sourceMappingURL=index.js.map
|
|
7
7
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
export { FileTrigger } from '../../chunk-
|
|
3
|
-
import '../../chunk-
|
|
4
|
-
import '../../chunk-
|
|
2
|
+
export { FileTrigger } from '../../chunk-UT3TOV2Q.js';
|
|
3
|
+
import '../../chunk-SWVUXEBT.js';
|
|
4
|
+
import '../../chunk-D2QIPQ74.js';
|
|
5
5
|
import '../../chunk-R5LYFTHA.js';
|
|
6
6
|
import '../../chunk-WYCMIIRR.js';
|
|
7
|
-
import '../../chunk-
|
|
7
|
+
import '../../chunk-C6NVU4F7.js';
|
|
8
8
|
import '../../chunk-GIPQUKCN.js';
|
|
9
|
-
import '../../chunk-
|
|
9
|
+
import '../../chunk-4ASNIDV7.js';
|
|
10
10
|
//# sourceMappingURL=index.js.map
|
|
11
11
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { FileItem, isInFlight } from '../../chunk-
|
|
3
|
-
import '../../chunk-
|
|
2
|
+
import { FileItem, isInFlight } from '../../chunk-QNKD2SQM.js';
|
|
3
|
+
import '../../chunk-QKSLDQM2.js';
|
|
4
4
|
import '../../chunk-SDVZFXQ2.js';
|
|
5
|
-
import { FileQueueSummary } from '../../chunk-
|
|
6
|
-
import '../../chunk-
|
|
5
|
+
import { FileQueueSummary } from '../../chunk-7BOSX65U.js';
|
|
6
|
+
import '../../chunk-Y57NW6G7.js';
|
|
7
7
|
import '../../chunk-J43LSYQO.js';
|
|
8
|
-
import { Field, fieldA11yProps } from '../../chunk-
|
|
8
|
+
import { Field, fieldA11yProps } from '../../chunk-VD6PB3VA.js';
|
|
9
9
|
import '../../chunk-SKPM2FRX.js';
|
|
10
|
-
import { Button } from '../../chunk-
|
|
10
|
+
import { Button } from '../../chunk-SWVUXEBT.js';
|
|
11
11
|
import { formatFileSize } from '../../chunk-TCFB23JT.js';
|
|
12
12
|
import '../../chunk-JYKP4RSG.js';
|
|
13
13
|
import '../../chunk-EIBDLRAR.js';
|
|
@@ -16,14 +16,14 @@ import '../../chunk-AHM6SGEU.js';
|
|
|
16
16
|
import { useLocale } from '../../chunk-IPYHTCFL.js';
|
|
17
17
|
import '../../chunk-6N6J2DOE.js';
|
|
18
18
|
import '../../chunk-BUIHQJGE.js';
|
|
19
|
-
import '../../chunk-
|
|
19
|
+
import '../../chunk-6YNLRQ25.js';
|
|
20
20
|
import { iconStroke, mergeIcons } from '../../chunk-XXOR34T4.js';
|
|
21
|
-
import '../../chunk-
|
|
21
|
+
import '../../chunk-D2QIPQ74.js';
|
|
22
22
|
import '../../chunk-R5LYFTHA.js';
|
|
23
23
|
import { props } from '../../chunk-WYCMIIRR.js';
|
|
24
|
-
import '../../chunk-
|
|
24
|
+
import '../../chunk-C6NVU4F7.js';
|
|
25
25
|
import { TYPOGRAPHY_SHADE_CLASSES } from '../../chunk-GIPQUKCN.js';
|
|
26
|
-
import { cn } from '../../chunk-
|
|
26
|
+
import { cn } from '../../chunk-4ASNIDV7.js';
|
|
27
27
|
import { useFieldContext } from '@ark-ui/react/field';
|
|
28
28
|
import { FileUpload as FileUpload$1 } from '@ark-ui/react/file-upload';
|
|
29
29
|
import { UploadCloud } from 'lucide-react';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { Flex } from '../../chunk-
|
|
1
|
+
export { Flex } from '../../chunk-UXPINIDN.js';
|
|
2
2
|
import '../../chunk-XFEPUGUZ.js';
|
|
3
3
|
import '../../chunk-WYCMIIRR.js';
|
|
4
|
-
import '../../chunk-
|
|
4
|
+
import '../../chunk-4ASNIDV7.js';
|
|
5
5
|
//# sourceMappingURL=index.js.map
|
|
6
6
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { Figure } from '../../chunk-
|
|
2
|
+
import { Figure } from '../../chunk-2HIX6DKN.js';
|
|
3
3
|
import '../../chunk-AZ2VUAGX.js';
|
|
4
|
-
import { Image } from '../../chunk-
|
|
4
|
+
import { Image } from '../../chunk-Y57NW6G7.js';
|
|
5
5
|
import { MEDIA_RADIUS } from '../../chunk-J43LSYQO.js';
|
|
6
6
|
import { useOpenIndexTrigger } from '../../chunk-RNRD6ER5.js';
|
|
7
7
|
import { useElementSize } from '../../chunk-2LI3VPDP.js';
|
|
@@ -12,9 +12,9 @@ import '../../chunk-6N6J2DOE.js';
|
|
|
12
12
|
import { useIsomorphicLayoutEffect } from '../../chunk-BUIHQJGE.js';
|
|
13
13
|
import '../../chunk-XXOR34T4.js';
|
|
14
14
|
import { props } from '../../chunk-WYCMIIRR.js';
|
|
15
|
-
import { focusStyles } from '../../chunk-
|
|
15
|
+
import { focusStyles } from '../../chunk-C6NVU4F7.js';
|
|
16
16
|
import '../../chunk-GIPQUKCN.js';
|
|
17
|
-
import { cn } from '../../chunk-
|
|
17
|
+
import { cn } from '../../chunk-4ASNIDV7.js';
|
|
18
18
|
import { ark } from '@ark-ui/react';
|
|
19
19
|
import { useRef, useMemo } from 'react';
|
|
20
20
|
import { match, P } from 'ts-pattern';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { GAP_CLASSES } from '../../chunk-XFEPUGUZ.js';
|
|
2
2
|
import { props } from '../../chunk-WYCMIIRR.js';
|
|
3
|
-
import { cn } from '../../chunk-
|
|
3
|
+
import { cn } from '../../chunk-4ASNIDV7.js';
|
|
4
4
|
import { ark } from '@ark-ui/react';
|
|
5
5
|
import { cva } from 'class-variance-authority';
|
|
6
6
|
import { jsx } from 'react/jsx-runtime';
|
|
@@ -1,25 +1,52 @@
|
|
|
1
1
|
import { HoverCard as Ark } from "@ark-ui/react/hover-card";
|
|
2
2
|
import { type ReactNode } from "react";
|
|
3
|
-
import { type LogicalPosition } from "../../lib/placement";
|
|
3
|
+
import { type LogicalPosition, type Placement, type PlacementProps } from "../../lib/placement";
|
|
4
4
|
import type { WithTestId } from "../../lib/test-id";
|
|
5
|
-
|
|
5
|
+
/**
|
|
6
|
+
* HoverCard — a rich preview panel on Ark UI's HoverCard, shown after a short
|
|
7
|
+
* hover/focus delay. It sits between `Popover` (a clickable, focus-trapping
|
|
8
|
+
* panel with no delay) and `Tooltip` (a delayed hint with no rich content):
|
|
9
|
+
* HoverCard is delayed *and* rich — the "hover a username, see a profile
|
|
10
|
+
* card" pattern. Ark owns the open/close state, the open/close delays,
|
|
11
|
+
* positioning, and dismiss-on-outside-interaction; the kit adds the portaled,
|
|
12
|
+
* animated panel chrome (reusing `Popover`'s surface).
|
|
13
|
+
*
|
|
14
|
+
* Unlike `Tooltip`, there's no single-call convenience form — a hover card's
|
|
15
|
+
* content is arbitrary rich markup, so it's compound-only, like `Popover`:
|
|
16
|
+
*
|
|
17
|
+
* <HoverCard.Root>
|
|
18
|
+
* <HoverCard.Trigger asChild>
|
|
19
|
+
* <a href="/norm">@the-norm</a>
|
|
20
|
+
* </HoverCard.Trigger>
|
|
21
|
+
* <HoverCard.Content>
|
|
22
|
+
* Rich <strong>preview</strong> content.
|
|
23
|
+
* </HoverCard.Content>
|
|
24
|
+
* </HoverCard.Root>
|
|
25
|
+
*
|
|
26
|
+
* Ark's machine defaults to a 600ms open delay and a 300ms close delay —
|
|
27
|
+
* long enough that an incidental pass of the cursor doesn't pop a card open.
|
|
28
|
+
* `HoverCard.Group` puts several trigger targets (e.g. a row of avatars) on
|
|
29
|
+
* one *shared* card instead: Ark's own HoverCard machine supports multiple
|
|
30
|
+
* named triggers under a single `Root`/`Content`, so hovering from one
|
|
31
|
+
* target to the next while the card is already open just repositions the
|
|
32
|
+
* same panel — no close/reopen, no delay replay — and it visibly slides
|
|
33
|
+
* between targets.
|
|
34
|
+
*
|
|
35
|
+
* Keep its content a preview. Ark's machine ignores touch, never lets focus
|
|
36
|
+
* into the card, and puts no `aria-expanded`/`aria-controls` on the trigger,
|
|
37
|
+
* because a hover card previews where its trigger *link* goes. For a card
|
|
38
|
+
* people act on (a copy button, a "View profile" link), use
|
|
39
|
+
* `<Popover.Root mode="hover">`. It keeps the delayed hover preview, and a
|
|
40
|
+
* click, tap or Enter pins it as a focusable, dismissable popover.
|
|
41
|
+
*/
|
|
6
42
|
/** `position` accepts Ark's physical placements plus the logical, RTL-aware
|
|
7
43
|
* horizontal sides `start` / `end` (resolved to `left` / `right` by direction). */
|
|
8
|
-
export type HoverCardPosition = LogicalPosition<
|
|
9
|
-
export type HoverCardRootProps = Omit<Ark.RootProps, "positioning" | "onOpenChange"> & {
|
|
44
|
+
export type HoverCardPosition = LogicalPosition<Placement>;
|
|
45
|
+
export type HoverCardRootProps = Omit<Ark.RootProps, "positioning" | "onOpenChange"> & PlacementProps & {
|
|
10
46
|
/** Match the trigger's width (`"target"`), or size to content (`"auto"`,
|
|
11
47
|
* default — a hover card's content is usually much larger than its
|
|
12
48
|
* trigger, unlike a dropdown). */
|
|
13
49
|
width?: "target" | "auto";
|
|
14
|
-
/** Panel placement relative to the trigger. Defaults to Ark's `"bottom"`. */
|
|
15
|
-
position?: HoverCardPosition;
|
|
16
|
-
/** Gap in px between the trigger and the panel. */
|
|
17
|
-
gutter?: number;
|
|
18
|
-
/** Positioner offset. */
|
|
19
|
-
offset?: {
|
|
20
|
-
mainAxis?: number | undefined;
|
|
21
|
-
crossAxis?: number | undefined;
|
|
22
|
-
} | undefined;
|
|
23
50
|
/** Render the panel in a Portal so it escapes clipping ancestors. Default `true`. */
|
|
24
51
|
withinPortal?: boolean;
|
|
25
52
|
/** Portal target. Defaults to the enclosing `Modal`/`Drawer` when there is
|
|
@@ -31,7 +58,7 @@ export type HoverCardRootProps = Omit<Ark.RootProps, "positioning" | "onOpenChan
|
|
|
31
58
|
* interaction, or a controlled `onOpenChange`. */
|
|
32
59
|
onClose?: () => void;
|
|
33
60
|
};
|
|
34
|
-
declare const Root: ({ width, position, gutter, offset, withinPortal, container, openDelay, children, onOpenChange, onClose, ...rest }: HoverCardRootProps) => import("react").JSX.Element;
|
|
61
|
+
declare const Root: ({ width, position, gutter, offset, hideWhenDetached, positioning, withinPortal, container, openDelay, children, onOpenChange, onClose, ...rest }: HoverCardRootProps) => import("react").JSX.Element;
|
|
35
62
|
export type HoverCardContentProps = Ark.ContentProps & WithTestId & {
|
|
36
63
|
/** Identifies which `HoverCard.Group` target this content belongs to —
|
|
37
64
|
* only meaningful inside `HoverCard.Group`, where several `Content`s
|
|
@@ -40,19 +67,10 @@ export type HoverCardContentProps = Ark.ContentProps & WithTestId & {
|
|
|
40
67
|
value?: string;
|
|
41
68
|
};
|
|
42
69
|
declare const Content: ({ className, children, testId, value: _value, ...rest }: HoverCardContentProps) => import("react").JSX.Element;
|
|
43
|
-
export type HoverCardGroupProps = Omit<Ark.RootProps, "positioning" | "onOpenChange" | "children"> & {
|
|
70
|
+
export type HoverCardGroupProps = Omit<Ark.RootProps, "positioning" | "onOpenChange" | "children"> & PlacementProps & {
|
|
44
71
|
/** Match every trigger's width (`"target"`), or size to content (`"auto"`,
|
|
45
72
|
* default). */
|
|
46
73
|
width?: "target" | "auto";
|
|
47
|
-
/** Panel placement relative to the active trigger. Defaults to Ark's `"bottom"`. */
|
|
48
|
-
position?: HoverCardPosition;
|
|
49
|
-
/** Gap in px between the active trigger and the panel. */
|
|
50
|
-
gutter?: number;
|
|
51
|
-
/** Positioner offset. */
|
|
52
|
-
offset?: {
|
|
53
|
-
mainAxis?: number | undefined;
|
|
54
|
-
crossAxis?: number | undefined;
|
|
55
|
-
} | undefined;
|
|
56
74
|
/** Render the panel in a Portal so it escapes clipping ancestors. Default `true`. */
|
|
57
75
|
withinPortal?: boolean;
|
|
58
76
|
/** Portal target. Defaults to the enclosing `Modal`/`Drawer` when there is
|
|
@@ -99,7 +117,7 @@ export type HoverCardGroupProps = Omit<Ark.RootProps, "positioning" | "onOpenCha
|
|
|
99
117
|
* as a props update on the *same* `Content`/`Positioner`/`Content` element
|
|
100
118
|
* tree, not an unmount-and-remount of a different one, which is what keeps
|
|
101
119
|
* it one real, continuous DOM node to slide. Paired with a CSS transition on
|
|
102
|
-
* the positioner's `transform` (`
|
|
120
|
+
* the positioner's `transform` (`slideStyle`, applied by `Content`
|
|
103
121
|
* whenever `sliding` is set), that reposition visibly slides the panel from
|
|
104
122
|
* one target to the next.
|
|
105
123
|
*
|
|
@@ -111,7 +129,7 @@ export type HoverCardGroupProps = Omit<Ark.RootProps, "positioning" | "onOpenCha
|
|
|
111
129
|
* trigger elements still land exactly there, since `Content` is portaled
|
|
112
130
|
* away separately.
|
|
113
131
|
*/
|
|
114
|
-
declare const Group: ({ width, position, gutter, offset, withinPortal, container, openDelay, children, onOpenChange, onClose, ...rest }: HoverCardGroupProps) => import("react").JSX.Element;
|
|
132
|
+
declare const Group: ({ width, position, gutter, offset, hideWhenDetached, positioning, withinPortal, container, openDelay, children, onOpenChange, onClose, ...rest }: HoverCardGroupProps) => import("react").JSX.Element;
|
|
115
133
|
export declare const HoverCard: {
|
|
116
134
|
Root: typeof Root;
|
|
117
135
|
Trigger: import("react").ForwardRefExoticComponent<Ark.TriggerProps & import("react").RefAttributes<HTMLButtonElement>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"hover-card.d.ts","sourceRoot":"","sources":["../../../src/components/hover-card/hover-card.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,SAAS,IAAI,GAAG,EAAE,MAAM,0BAA0B,CAAA;AAG3D,OAAO,
|
|
1
|
+
{"version":3,"file":"hover-card.d.ts","sourceRoot":"","sources":["../../../src/components/hover-card/hover-card.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,SAAS,IAAI,GAAG,EAAE,MAAM,0BAA0B,CAAA;AAG3D,OAAO,EAAiB,KAAK,SAAS,EAAc,MAAM,OAAO,CAAA;AAGjE,OAAO,EACL,KAAK,eAAe,EACpB,KAAK,SAAS,EACd,KAAK,cAAc,EAEpB,MAAM,qBAAqB,CAAA;AAQ5B,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAA;AAGnD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AAEH;oFACoF;AACpF,MAAM,MAAM,iBAAiB,GAAG,eAAe,CAAC,SAAS,CAAC,CAAA;AAmB1D,MAAM,MAAM,kBAAkB,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,EAAE,aAAa,GAAG,cAAc,CAAC,GAClF,cAAc,GAAG;IACf;;uCAEmC;IACnC,KAAK,CAAC,EAAE,QAAQ,GAAG,MAAM,CAAA;IACzB,qFAAqF;IACrF,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB;mEAC+D;IAC/D,SAAS,CAAC,EAAE,WAAW,GAAG,IAAI,CAAA;IAC9B,gFAAgF;IAChF,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI,CAAA;IACtC;uDACmD;IACnD,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;CACrB,CAAA;AAEH,QAAA,MAAM,IAAI,qJAcP,kBAAkB,gCAwBpB,CAAA;AAED,MAAM,MAAM,qBAAqB,GAAG,GAAG,CAAC,YAAY,GAClD,UAAU,GAAG;IACX;;;8EAG0E;IAC1E,KAAK,CAAC,EAAE,MAAM,CAAA;CACf,CAAA;AAEH,QAAA,MAAM,OAAO,4DAMV,qBAAqB,gCAiBvB,CAAA;AAED,MAAM,MAAM,mBAAmB,GAAG,IAAI,CAAC,GAAG,CAAC,SAAS,EAAE,aAAa,GAAG,cAAc,GAAG,UAAU,CAAC,GAChG,cAAc,GAAG;IACf;oBACgB;IAChB,KAAK,CAAC,EAAE,QAAQ,GAAG,MAAM,CAAA;IACzB,qFAAqF;IACrF,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB;mEAC+D;IAC/D,SAAS,CAAC,EAAE,WAAW,GAAG,IAAI,CAAA;IAC9B,gFAAgF;IAChF,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI,CAAA;IACtC;uEACmE;IACnE,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;IACpB;;;+BAG2B;IAC3B,QAAQ,CAAC,EAAE,SAAS,CAAA;CACrB,CAAA;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyCG;AACH,QAAA,MAAM,KAAK,qJAcR,mBAAmB,gCAqCrB,CAAA;AAED,eAAO,MAAM,SAAS;;;;;CAKrB,CAAA"}
|
|
@@ -1,24 +1,19 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import { slideStyle, popoverChrome, splitGroupChildren, useSlideAfterPlaced, activeGroupContent } from '../../chunk-N66NC6QK.js';
|
|
3
|
+
import { toPositioning } from '../../chunk-V6PY7C6S.js';
|
|
4
4
|
import { useOverlayContainer } from '../../chunk-7P32XCEU.js';
|
|
5
5
|
import '../../chunk-H7WOMZXO.js';
|
|
6
6
|
import '../../chunk-PMUCGFY5.js';
|
|
7
7
|
import '../../chunk-BUIHQJGE.js';
|
|
8
8
|
import { props } from '../../chunk-WYCMIIRR.js';
|
|
9
9
|
import '../../chunk-GIPQUKCN.js';
|
|
10
|
-
import { cn } from '../../chunk-
|
|
10
|
+
import { cn } from '../../chunk-4ASNIDV7.js';
|
|
11
11
|
import { HoverCard as HoverCard$1 } from '@ark-ui/react/hover-card';
|
|
12
12
|
import { useLocaleContext } from '@ark-ui/react/locale';
|
|
13
13
|
import { Portal } from '@ark-ui/react/portal';
|
|
14
|
-
import { createContext, useContext
|
|
14
|
+
import { createContext, useContext } from 'react';
|
|
15
15
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
16
16
|
|
|
17
|
-
var hoverCardSlideStyle = {
|
|
18
|
-
transitionProperty: "transform",
|
|
19
|
-
transitionDuration: "200ms",
|
|
20
|
-
transitionTimingFunction: "cubic-bezier(0.32, 0.72, 0, 1)"
|
|
21
|
-
};
|
|
22
17
|
var HoverCardContext = createContext({
|
|
23
18
|
width: "auto",
|
|
24
19
|
withinPortal: true,
|
|
@@ -26,9 +21,11 @@ var HoverCardContext = createContext({
|
|
|
26
21
|
});
|
|
27
22
|
var Root = ({
|
|
28
23
|
width = "auto",
|
|
29
|
-
position
|
|
24
|
+
position,
|
|
30
25
|
gutter,
|
|
31
26
|
offset,
|
|
27
|
+
hideWhenDetached,
|
|
28
|
+
positioning,
|
|
32
29
|
withinPortal = true,
|
|
33
30
|
container,
|
|
34
31
|
openDelay,
|
|
@@ -44,12 +41,11 @@ var Root = ({
|
|
|
44
41
|
lazyMount: true,
|
|
45
42
|
unmountOnExit: true,
|
|
46
43
|
openDelay,
|
|
47
|
-
positioning:
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
},
|
|
44
|
+
positioning: toPositioning(
|
|
45
|
+
{ position, gutter, offset, hideWhenDetached, positioning },
|
|
46
|
+
dir,
|
|
47
|
+
width
|
|
48
|
+
),
|
|
53
49
|
onOpenChange: ({ open }) => {
|
|
54
50
|
onOpenChange?.(open);
|
|
55
51
|
if (!open) onClose?.();
|
|
@@ -68,7 +64,7 @@ var Content = ({
|
|
|
68
64
|
}) => {
|
|
69
65
|
const { width, withinPortal, container, sliding } = useContext(HoverCardContext);
|
|
70
66
|
const portalContainer = useOverlayContainer(container);
|
|
71
|
-
const panel = /* @__PURE__ */ jsx(HoverCard$1.Positioner, { style: sliding ?
|
|
67
|
+
const panel = /* @__PURE__ */ jsx(HoverCard$1.Positioner, { style: sliding ? slideStyle : void 0, children: /* @__PURE__ */ jsx(
|
|
72
68
|
HoverCard$1.Content,
|
|
73
69
|
{
|
|
74
70
|
tabIndex: -1,
|
|
@@ -81,12 +77,13 @@ var Content = ({
|
|
|
81
77
|
if (!withinPortal) return panel;
|
|
82
78
|
return /* @__PURE__ */ jsx(Portal, { container: portalContainer, children: panel });
|
|
83
79
|
};
|
|
84
|
-
var isGroupContent = (node) => isValidElement(node) && node.type === Content;
|
|
85
80
|
var Group = ({
|
|
86
81
|
width = "auto",
|
|
87
|
-
position
|
|
82
|
+
position,
|
|
88
83
|
gutter,
|
|
89
84
|
offset,
|
|
85
|
+
hideWhenDetached,
|
|
86
|
+
positioning,
|
|
90
87
|
withinPortal = true,
|
|
91
88
|
container,
|
|
92
89
|
openDelay,
|
|
@@ -96,52 +93,37 @@ var Group = ({
|
|
|
96
93
|
...rest
|
|
97
94
|
}) => {
|
|
98
95
|
const { dir } = useLocaleContext();
|
|
99
|
-
const
|
|
100
|
-
const
|
|
101
|
-
|
|
102
|
-
const [sliding, setSliding] = useState(false);
|
|
103
|
-
const slidingRafRef = useRef(null);
|
|
104
|
-
useEffect(
|
|
105
|
-
() => () => {
|
|
106
|
-
if (slidingRafRef.current != null) cancelAnimationFrame(slidingRafRef.current);
|
|
107
|
-
},
|
|
108
|
-
[]
|
|
109
|
-
);
|
|
110
|
-
return /* @__PURE__ */ jsx(HoverCardContext.Provider, { value: { width, withinPortal, container, sliding }, children: /* @__PURE__ */ jsxs(
|
|
96
|
+
const { contents, triggers } = splitGroupChildren(children, Content);
|
|
97
|
+
const slide = useSlideAfterPlaced();
|
|
98
|
+
return /* @__PURE__ */ jsx(HoverCardContext.Provider, { value: { width, withinPortal, container, sliding: slide.sliding }, children: /* @__PURE__ */ jsxs(
|
|
111
99
|
HoverCard$1.Root,
|
|
112
100
|
{
|
|
113
101
|
lazyMount: true,
|
|
114
102
|
unmountOnExit: true,
|
|
115
103
|
openDelay,
|
|
116
|
-
positioning:
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
104
|
+
positioning: toPositioning(
|
|
105
|
+
{
|
|
106
|
+
position,
|
|
107
|
+
gutter,
|
|
108
|
+
offset,
|
|
109
|
+
hideWhenDetached,
|
|
110
|
+
positioning: {
|
|
111
|
+
...positioning,
|
|
112
|
+
updatePosition: slide.updatePosition(positioning?.updatePosition)
|
|
113
|
+
}
|
|
114
|
+
},
|
|
115
|
+
dir,
|
|
116
|
+
width
|
|
117
|
+
),
|
|
122
118
|
onOpenChange: ({ open }) => {
|
|
123
119
|
onOpenChange?.(open);
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
slidingRafRef.current = null;
|
|
127
|
-
setSliding(true);
|
|
128
|
-
});
|
|
129
|
-
} else {
|
|
130
|
-
if (slidingRafRef.current != null) {
|
|
131
|
-
cancelAnimationFrame(slidingRafRef.current);
|
|
132
|
-
slidingRafRef.current = null;
|
|
133
|
-
}
|
|
134
|
-
setSliding(false);
|
|
135
|
-
onClose?.();
|
|
136
|
-
}
|
|
120
|
+
slide.onOpenChange(open);
|
|
121
|
+
if (!open) onClose?.();
|
|
137
122
|
},
|
|
138
123
|
...rest,
|
|
139
124
|
children: [
|
|
140
125
|
triggers,
|
|
141
|
-
/* @__PURE__ */ jsx(HoverCard$1.Context, { children: (api) =>
|
|
142
|
-
const active = contents.find((c) => c.props.value === api.triggerValue);
|
|
143
|
-
return active ? cloneElement(active, { key: "hover-card-group-content" }) : null;
|
|
144
|
-
} })
|
|
126
|
+
/* @__PURE__ */ jsx(HoverCard$1.Context, { children: (api) => activeGroupContent(contents, api.triggerValue) })
|
|
145
127
|
]
|
|
146
128
|
}
|
|
147
129
|
) });
|
|
@@ -1 +1 @@
|
|
|
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EAAM;AACR,UAAA,aAAA,CAAc,OAAA,GAAU,sBAAsB,MAAM;AAClD,YAAA,aAAA,CAAc,OAAA,GAAU,IAAA;AACxB,YAAA,UAAA,CAAW,IAAI,CAAA;AAAA,UACjB,CAAC,CAAA;AAAA,QACH,CAAA,MAAO;AACL,UAAA,IAAI,aAAA,CAAc,WAAW,IAAA,EAAM;AACjC,YAAA,oBAAA,CAAqB,cAAc,OAAO,CAAA;AAC1C,YAAA,aAAA,CAAc,OAAA,GAAU,IAAA;AAAA,UAC1B;AACA,UAAA,UAAA,CAAW,KAAK,CAAA;AAChB,UAAA,OAAA,IAAU;AAAA,QACZ;AAAA,MACF,CAAA;AAAA,MACC,GAAG,IAAA;AAAA,MAEH,QAAA,EAAA;AAAA,QAAA,QAAA;AAAA,wBACD,GAAA,CAACA,WAAA,CAAI,OAAA,EAAJ,EACE,WAAC,GAAA,KAAQ;AACR,UAAA,MAAM,MAAA,GAAS,SAAS,IAAA,CAAK,CAAC,MAAM,CAAA,CAAE,KAAA,CAAM,KAAA,KAAU,GAAA,CAAI,YAAY,CAAA;AAUtE,UAAA,OAAO,SAAS,YAAA,CAAa,MAAA,EAAQ,EAAE,GAAA,EAAK,0BAAA,EAA4B,CAAA,GAAI,IAAA;AAAA,QAC9E,CAAA,EACF;AAAA;AAAA;AAAA,GACF,EACF,CAAA;AAEJ,CAAA;AAEO,IAAM,SAAA,GAAY;AAAA,EACvB,IAAA;AAAA,EACA,SAASA,WAAA,CAAI,OAAA;AAAA,EACb,OAAA;AAAA,EACA;AACF","file":"index.js","sourcesContent":["\"use client\"\n\nimport { HoverCard as Ark } from \"@ark-ui/react/hover-card\"\nimport { useLocaleContext } from \"@ark-ui/react/locale\"\nimport { Portal } from \"@ark-ui/react/portal\"\nimport {\n Children,\n cloneElement,\n createContext,\n isValidElement,\n type ReactElement,\n type ReactNode,\n useContext,\n useEffect,\n useRef,\n useState,\n} from \"react\"\nimport { cn } from \"../../lib/cn\"\nimport { useOverlayContainer } from \"../../lib/overlay-container\"\nimport { type LogicalPosition, resolveLogicalPlacement } from \"../../lib/placement\"\nimport { props } from \"../../lib/props\"\nimport type { WithTestId } from \"../../lib/test-id\"\nimport { popoverChrome } from \"../popover/popover\"\n\n/**\n * HoverCard — a rich preview panel on Ark UI's HoverCard, shown after a short\n * hover/focus delay. It sits between `Popover` (a clickable, focus-trapping\n * panel with no delay) and `Tooltip` (a delayed hint with no rich content):\n * HoverCard is delayed *and* rich — the \"hover a username, see a profile\n * card\" pattern. Ark owns the open/close state, the open/close delays,\n * positioning, and dismiss-on-outside-interaction; the kit adds the portaled,\n * animated panel chrome (reusing `Popover`'s surface).\n *\n * Unlike `Tooltip`, there's no single-call convenience form — a hover card's\n * content is arbitrary rich markup, so it's compound-only, like `Popover`:\n *\n * <HoverCard.Root>\n * <HoverCard.Trigger asChild>\n * <a href=\"/norm\">@the-norm</a>\n * </HoverCard.Trigger>\n * <HoverCard.Content>\n * Rich <strong>preview</strong> content.\n * </HoverCard.Content>\n * </HoverCard.Root>\n *\n * Ark's machine defaults to a 600ms open delay and a 300ms close delay —\n * long enough that an incidental pass of the cursor doesn't pop a card open.\n * `HoverCard.Group` puts several trigger targets (e.g. a row of avatars) on\n * one *shared* card instead: Ark's own HoverCard machine supports multiple\n * named triggers under a single `Root`/`Content`, so hovering from one\n * target to the next while the card is already open just repositions the\n * same panel — no close/reopen, no delay replay — and it visibly slides\n * between targets.\n *\n * Keep its content a preview. Ark's machine ignores touch, never lets focus\n * into the card, and puts no `aria-expanded`/`aria-controls` on the trigger,\n * because a hover card previews where its trigger *link* goes. For a card\n * people act on (a copy button, a \"View profile\" link), use\n * `<Popover.Root mode=\"hover\">`. It keeps the delayed hover preview, and a\n * click, tap or Enter pins it as a focusable, dismissable popover.\n */\n\n/** Slide transition for `HoverCard.Group`'s shared positioner — Ark sets the\n * positioner's `transform: translate3d(var(--x), var(--y), 0)` inline\n * (`@zag-js/popper`); animating `transform` itself makes the browser\n * interpolate that translate smoothly between two trigger anchors when the\n * group's active trigger changes. Passed as `style` (not a class) so it\n * merges with — rather than replaces — Ark's own inline `transform`/\n * `position` (Ark's `mergeProps` shallow-merges style objects); same\n * override-the-real-style technique `Tabs.Indicator` / `SegmentGroup` use\n * for their sliding pill. Only applied inside `Group`, and only once\n * `HoverCardContextValue.sliding` is true (see `Group`) — never on the very\n * first open, where the positioner's `--x`/`--y` haven't been computed yet\n * (the panel briefly sits at its unset `transform: none` origin, the\n * viewport's top-left, before floating-ui places it); animating *that*\n * jump would read as the panel sliding in from the top of the screen\n * instead of just appearing. A standalone `Root` never gets this at all: it\n * also repositions on scroll/resize (`autoUpdate`), where an animated\n * `transform` would look laggy rather than responsive. */\nconst hoverCardSlideStyle = {\n transitionProperty: \"transform\",\n transitionDuration: \"200ms\",\n transitionTimingFunction: \"cubic-bezier(0.32, 0.72, 0, 1)\",\n} as const\n\ntype HoverCardPlacement = NonNullable<NonNullable<Ark.RootProps[\"positioning\"]>[\"placement\"]>\n\n/** `position` accepts Ark's physical placements plus the logical, RTL-aware\n * horizontal sides `start` / `end` (resolved to `left` / `right` by direction). */\nexport type HoverCardPosition = LogicalPosition<HoverCardPlacement>\n\ntype HoverCardContextValue = {\n width: \"target\" | \"auto\"\n withinPortal: boolean\n container?: HTMLElement | null\n /** Whether this `Content` is `HoverCard.Group`'s single shared panel *and*\n * has already completed its first open — `Group` flips this true one\n * frame after opening, once the panel has a real, computed position to\n * slide *from*. Gates the slide transition (see `hoverCardSlideStyle`) so\n * only a later switch between targets animates, never the initial reveal. */\n sliding: boolean\n}\nconst HoverCardContext = createContext<HoverCardContextValue>({\n width: \"auto\",\n withinPortal: true,\n sliding: false,\n})\n\nexport type HoverCardRootProps = Omit<Ark.RootProps, \"positioning\" | \"onOpenChange\"> & {\n /** Match the trigger's width (`\"target\"`), or size to content (`\"auto\"`,\n * default — a hover card's content is usually much larger than its\n * trigger, unlike a dropdown). */\n width?: \"target\" | \"auto\"\n /** Panel placement relative to the trigger. Defaults to Ark's `\"bottom\"`. */\n position?: HoverCardPosition\n /** Gap in px between the trigger and the panel. */\n gutter?: number\n /** Positioner offset. */\n offset?:\n | {\n mainAxis?: number | undefined\n crossAxis?: number | undefined\n }\n | undefined\n /** Render the panel in a Portal so it escapes clipping ancestors. Default `true`. */\n withinPortal?: boolean\n /** Portal target. Defaults to the enclosing `Modal`/`Drawer` when there is\n * one (so the panel stays above it), else `document.body`. */\n container?: HTMLElement | null\n /** Fires when the card opens or closes (flattened from Ark's detail object). */\n onOpenChange?: (open: boolean) => void\n /** Fires on close (any source) — pointer/focus leaving, Escape, outside\n * interaction, or a controlled `onOpenChange`. */\n onClose?: () => void\n}\n\nconst Root = ({\n width = \"auto\",\n position = \"bottom\",\n gutter,\n offset,\n withinPortal = true,\n container,\n openDelay,\n children,\n onOpenChange,\n onClose,\n ...rest\n}: HoverCardRootProps) => {\n const { dir } = useLocaleContext()\n\n return (\n <HoverCardContext.Provider value={{ width, withinPortal, container, sliding: false }}>\n <Ark.Root\n lazyMount\n unmountOnExit\n openDelay={openDelay}\n positioning={{\n sameWidth: width === \"target\",\n placement: resolveLogicalPlacement(position, dir),\n gutter,\n offset,\n }}\n onOpenChange={({ open }) => {\n onOpenChange?.(open)\n if (!open) onClose?.()\n }}\n {...rest}\n >\n {children}\n </Ark.Root>\n </HoverCardContext.Provider>\n )\n}\n\nexport type HoverCardContentProps = Ark.ContentProps &\n WithTestId & {\n /** Identifies which `HoverCard.Group` target this content belongs to —\n * only meaningful inside `HoverCard.Group`, where several `Content`s\n * share one panel and `Group` picks the one whose `value` matches the\n * active trigger. Ignored (and never forwarded to the DOM) otherwise. */\n value?: string\n }\n\nconst Content = ({\n className,\n children,\n testId,\n value: _value,\n ...rest\n}: HoverCardContentProps) => {\n const { width, withinPortal, container, sliding } = useContext(HoverCardContext)\n const portalContainer = useOverlayContainer(container)\n const panel = (\n <Ark.Positioner style={sliding ? hoverCardSlideStyle : undefined}>\n <Ark.Content\n tabIndex={-1}\n className={cn(popoverChrome, width === \"target\" ? \"w-full\" : \"w-max\", className)}\n {...props({ \"data-testid\": testId })}\n {...rest}\n >\n {children}\n </Ark.Content>\n </Ark.Positioner>\n )\n if (!withinPortal) return panel\n return <Portal container={portalContainer}>{panel}</Portal>\n}\n\nconst isGroupContent = (node: ReactNode): node is ReactElement<HoverCardContentProps> =>\n isValidElement(node) && node.type === Content\n\nexport type HoverCardGroupProps = Omit<\n Ark.RootProps,\n \"positioning\" | \"onOpenChange\" | \"children\"\n> & {\n /** Match every trigger's width (`\"target\"`), or size to content (`\"auto\"`,\n * default). */\n width?: \"target\" | \"auto\"\n /** Panel placement relative to the active trigger. Defaults to Ark's `\"bottom\"`. */\n position?: HoverCardPosition\n /** Gap in px between the active trigger and the panel. */\n gutter?: number\n /** Positioner offset. */\n offset?:\n | {\n mainAxis?: number | undefined\n crossAxis?: number | undefined\n }\n | undefined\n /** Render the panel in a Portal so it escapes clipping ancestors. Default `true`. */\n withinPortal?: boolean\n /** Portal target. Defaults to the enclosing `Modal`/`Drawer` when there is\n * one (so the panel stays above it), else `document.body`. */\n container?: HTMLElement | null\n /** Fires when the card opens or closes (flattened from Ark's detail object). */\n onOpenChange?: (open: boolean) => void\n /** Fires on close (any source) — pointer/focus leaving the whole group,\n * Escape, outside interaction, or a controlled `onOpenChange`. */\n onClose?: () => void\n /** `HoverCard.Trigger` (one per hover target, each with its own `value`)\n * and `HoverCard.Content` (one per target's content, `value`-matched to\n * its trigger) — the same parts `HoverCard.Root` uses, just several of\n * each instead of one. */\n children?: ReactNode\n}\n\n/**\n * One shared card across several hover targets (e.g. a row of avatars) — the\n * same `HoverCard.Trigger` / `HoverCard.Content` parts `HoverCard.Root` uses,\n * just several of each, disambiguated by a shared `value`:\n *\n * <HoverCard.Group>\n * <HoverCard.Trigger value=\"ada\">\n * <Avatar name=\"Ada Lovelace\" />\n * </HoverCard.Trigger>\n * <HoverCard.Trigger value=\"grace\">\n * <Avatar name=\"Grace Hopper\" />\n * </HoverCard.Trigger>\n *\n * <HoverCard.Content value=\"ada\">Ada's card content</HoverCard.Content>\n * <HoverCard.Content value=\"grace\">Grace's card content</HoverCard.Content>\n * </HoverCard.Group>\n *\n * Ark's HoverCard machine natively supports several named triggers under a\n * single `Root`/`Content` (a `triggerValue`, which `HoverCard.Trigger`'s\n * `value` already sets — it's a plain `Ark.Trigger` re-export): hovering from\n * one target to the next while the card is already open just repositions the\n * *same* panel instead of closing one and opening another — no unmount, no\n * delay replay. `Group` renders every `Trigger` child as-is (they need no\n * help — the machine already treats each `value` as a distinct target), but\n * intercepts every `Content` child: only the one whose `value` matches the\n * live `triggerValue` (read via Ark's `Context` render prop) is ever\n * rendered, in that one shared position — so React reconciles a value change\n * as a props update on the *same* `Content`/`Positioner`/`Content` element\n * tree, not an unmount-and-remount of a different one, which is what keeps\n * it one real, continuous DOM node to slide. Paired with a CSS transition on\n * the positioner's `transform` (`hoverCardSlideStyle`, applied by `Content`\n * whenever `sliding` is set), that reposition visibly slides the panel from\n * one target to the next.\n *\n * `Trigger`/`Content` must be `Group`'s own direct children — it only scans\n * one level (like `Timeline`/`Breadcrumb`), so wrapping them in an inner\n * `<div>` hides them from it entirely. `Group` (like `Root`) renders no DOM\n * node of its own, so for row-level layout (e.g. overlapping avatars via\n * `-space-x-2`), wrap `Group` itself from the outside instead — the actual\n * trigger elements still land exactly there, since `Content` is portaled\n * away separately.\n */\nconst Group = ({\n width = \"auto\",\n position = \"bottom\",\n gutter,\n offset,\n withinPortal = true,\n container,\n openDelay,\n children,\n onOpenChange,\n onClose,\n ...rest\n}: HoverCardGroupProps) => {\n const { dir } = useLocaleContext()\n const items = Children.toArray(children)\n const contents = items.filter(isGroupContent)\n const triggers = items.filter((item) => !isGroupContent(item))\n\n // False until one frame after opening, once the panel has a real computed\n // position to slide *from* — see `hoverCardSlideStyle`'s doc comment.\n // Reset on every close so the *next* pioneer open doesn't animate either.\n const [sliding, setSliding] = useState(false)\n const slidingRafRef = useRef<number | null>(null)\n useEffect(\n () => () => {\n if (slidingRafRef.current != null) cancelAnimationFrame(slidingRafRef.current)\n },\n [],\n )\n\n return (\n <HoverCardContext.Provider value={{ width, withinPortal, container, sliding }}>\n <Ark.Root\n lazyMount\n unmountOnExit\n openDelay={openDelay}\n positioning={{\n sameWidth: width === \"target\",\n placement: resolveLogicalPlacement(position, dir),\n gutter,\n offset,\n }}\n onOpenChange={({ open }) => {\n onOpenChange?.(open)\n if (open) {\n slidingRafRef.current = requestAnimationFrame(() => {\n slidingRafRef.current = null\n setSliding(true)\n })\n } else {\n if (slidingRafRef.current != null) {\n cancelAnimationFrame(slidingRafRef.current)\n slidingRafRef.current = null\n }\n setSliding(false)\n onClose?.()\n }\n }}\n {...rest}\n >\n {triggers}\n <Ark.Context>\n {(api) => {\n const active = contents.find((c) => c.props.value === api.triggerValue)\n // Force a stable `key`, overriding whatever each `Content` was\n // authored with (e.g. `key={person.handle}` in a `.map()`) — this\n // slot only ever renders one at a time, but a *different* key\n // switching in here reads to React as a different component,\n // unmounting the real Positioner/Content DOM tree and mounting a\n // fresh one instead of updating it in place. That fresh mount is\n // exactly what breaks the \"one shared, sliding panel\" contract:\n // its position starts unset again, so every switch would look\n // like the panel jumping in from the top instead of sliding.\n return active ? cloneElement(active, { key: \"hover-card-group-content\" }) : null\n }}\n </Ark.Context>\n </Ark.Root>\n </HoverCardContext.Provider>\n )\n}\n\nexport const HoverCard = {\n Root,\n Trigger: Ark.Trigger,\n Content,\n Group,\n}\n"]}
|
|
1
|
+
{"version":3,"sources":["../../../src/components/hover-card/hover-card.tsx"],"names":["Ark"],"mappings":";;;;;;;;;;;;;;;AA6EA,IAAM,mBAAmB,aAAA,CAAqC;AAAA,EAC5D,KAAA,EAAO,MAAA;AAAA,EACP,YAAA,EAAc,IAAA;AAAA,EACd,OAAA,EAAS;AACX,CAAC,CAAA;AAoBD,IAAM,OAAO,CAAC;AAAA,EACZ,KAAA,GAAQ,MAAA;AAAA,EACR,QAAA;AAAA,EACA,MAAA;AAAA,EACA,MAAA;AAAA,EAC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EAAS,IAAA;AAAA,MACT,aAAA,EAAa,IAAA;AAAA,MACb,SAAA;AAAA,MACA,WAAA,EAAa,aAAA;AAAA,QACX;AAAA,UACE,QAAA;AAAA,UACA,MAAA;AAAA,UACA,MAAA;AAAA,UACA,gBAAA;AAAA,UACA,WAAA,EAAa;AAAA,YACX,GAAG,WAAA;AAAA,YACH,cAAA,EAAgB,KAAA,CAAM,cAAA,CAAe,WAAA,EAAa,cAAc;AAAA;AAClE,SACF;AAAA,QACA,GAAA;AAAA,QACA;AAAA,OACF;AAAA,MACA,YAAA,EAAc,CAAC,EAAE,IAAA,EAAK,KAAM;AAC1B,QAAA,YAAA,GAAe,IAAI,CAAA;AACnB,QAAA,KAAA,CAAM,aAAa,IAAI,CAAA;AACvB,QAAA,IAAI,CAAC,MAAM,OAAA,IAAU;AAAA,MACvB,CAAA;AAAA,MACC,GAAG,IAAA;AAAA,MAEH,QAAA,EAAA;AAAA,QAAA,QAAA;AAAA,wBACD,GAAA,CAACA,WAAA,CAAI,OAAA,EAAJ,EAAa,QAAA,EAAA,CAAC,QAAQ,kBAAA,CAAmB,QAAA,EAAU,GAAA,CAAI,YAAY,CAAA,EAAE;AAAA;AAAA;AAAA,GACxE,EACF,CAAA;AAEJ,CAAA;AAEO,IAAM,SAAA,GAAY;AAAA,EACvB,IAAA;AAAA,EACA,SAASA,WAAA,CAAI,OAAA;AAAA,EACb,OAAA;AAAA,EACA;AACF","file":"index.js","sourcesContent":["\"use client\"\n\nimport { HoverCard as Ark } from \"@ark-ui/react/hover-card\"\nimport { useLocaleContext } from \"@ark-ui/react/locale\"\nimport { Portal } from \"@ark-ui/react/portal\"\nimport { createContext, type ReactNode, useContext } from \"react\"\nimport { cn } from \"../../lib/cn\"\nimport { useOverlayContainer } from \"../../lib/overlay-container\"\nimport {\n type LogicalPosition,\n type Placement,\n type PlacementProps,\n toPositioning,\n} from \"../../lib/placement\"\nimport { props } from \"../../lib/props\"\nimport {\n activeGroupContent,\n slideStyle,\n splitGroupChildren,\n useSlideAfterPlaced,\n} from \"../../lib/slide-on-switch\"\nimport type { WithTestId } from \"../../lib/test-id\"\nimport { popoverChrome } from \"../popover/popover\"\n\n/**\n * HoverCard — a rich preview panel on Ark UI's HoverCard, shown after a short\n * hover/focus delay. It sits between `Popover` (a clickable, focus-trapping\n * panel with no delay) and `Tooltip` (a delayed hint with no rich content):\n * HoverCard is delayed *and* rich — the \"hover a username, see a profile\n * card\" pattern. Ark owns the open/close state, the open/close delays,\n * positioning, and dismiss-on-outside-interaction; the kit adds the portaled,\n * animated panel chrome (reusing `Popover`'s surface).\n *\n * Unlike `Tooltip`, there's no single-call convenience form — a hover card's\n * content is arbitrary rich markup, so it's compound-only, like `Popover`:\n *\n * <HoverCard.Root>\n * <HoverCard.Trigger asChild>\n * <a href=\"/norm\">@the-norm</a>\n * </HoverCard.Trigger>\n * <HoverCard.Content>\n * Rich <strong>preview</strong> content.\n * </HoverCard.Content>\n * </HoverCard.Root>\n *\n * Ark's machine defaults to a 600ms open delay and a 300ms close delay —\n * long enough that an incidental pass of the cursor doesn't pop a card open.\n * `HoverCard.Group` puts several trigger targets (e.g. a row of avatars) on\n * one *shared* card instead: Ark's own HoverCard machine supports multiple\n * named triggers under a single `Root`/`Content`, so hovering from one\n * target to the next while the card is already open just repositions the\n * same panel — no close/reopen, no delay replay — and it visibly slides\n * between targets.\n *\n * Keep its content a preview. Ark's machine ignores touch, never lets focus\n * into the card, and puts no `aria-expanded`/`aria-controls` on the trigger,\n * because a hover card previews where its trigger *link* goes. For a card\n * people act on (a copy button, a \"View profile\" link), use\n * `<Popover.Root mode=\"hover\">`. It keeps the delayed hover preview, and a\n * click, tap or Enter pins it as a focusable, dismissable popover.\n */\n\n/** `position` accepts Ark's physical placements plus the logical, RTL-aware\n * horizontal sides `start` / `end` (resolved to `left` / `right` by direction). */\nexport type HoverCardPosition = LogicalPosition<Placement>\n\ntype HoverCardContextValue = {\n width: \"target\" | \"auto\"\n withinPortal: boolean\n container?: HTMLElement | null\n /** Whether this `Content` is `HoverCard.Group`'s single shared panel *and*\n * its open has been placed once — `Group` flips this true after the first\n * placement lands, once the panel has a real position to slide *from*\n * (see `useSlideAfterPlaced`). Gates the slide transition (`slideStyle`)\n * so only a later switch between targets animates, never the reveal. */\n sliding: boolean\n}\nconst HoverCardContext = createContext<HoverCardContextValue>({\n width: \"auto\",\n withinPortal: true,\n sliding: false,\n})\n\nexport type HoverCardRootProps = Omit<Ark.RootProps, \"positioning\" | \"onOpenChange\"> &\n PlacementProps & {\n /** Match the trigger's width (`\"target\"`), or size to content (`\"auto\"`,\n * default — a hover card's content is usually much larger than its\n * trigger, unlike a dropdown). */\n width?: \"target\" | \"auto\"\n /** Render the panel in a Portal so it escapes clipping ancestors. Default `true`. */\n withinPortal?: boolean\n /** Portal target. Defaults to the enclosing `Modal`/`Drawer` when there is\n * one (so the panel stays above it), else `document.body`. */\n container?: HTMLElement | null\n /** Fires when the card opens or closes (flattened from Ark's detail object). */\n onOpenChange?: (open: boolean) => void\n /** Fires on close (any source) — pointer/focus leaving, Escape, outside\n * interaction, or a controlled `onOpenChange`. */\n onClose?: () => void\n }\n\nconst Root = ({\n width = \"auto\",\n position,\n gutter,\n offset,\n hideWhenDetached,\n positioning,\n withinPortal = true,\n container,\n openDelay,\n children,\n onOpenChange,\n onClose,\n ...rest\n}: HoverCardRootProps) => {\n const { dir } = useLocaleContext()\n\n return (\n <HoverCardContext.Provider value={{ width, withinPortal, container, sliding: false }}>\n <Ark.Root\n lazyMount\n unmountOnExit\n openDelay={openDelay}\n positioning={toPositioning(\n { position, gutter, offset, hideWhenDetached, positioning },\n dir,\n width,\n )}\n onOpenChange={({ open }) => {\n onOpenChange?.(open)\n if (!open) onClose?.()\n }}\n {...rest}\n >\n {children}\n </Ark.Root>\n </HoverCardContext.Provider>\n )\n}\n\nexport type HoverCardContentProps = Ark.ContentProps &\n WithTestId & {\n /** Identifies which `HoverCard.Group` target this content belongs to —\n * only meaningful inside `HoverCard.Group`, where several `Content`s\n * share one panel and `Group` picks the one whose `value` matches the\n * active trigger. Ignored (and never forwarded to the DOM) otherwise. */\n value?: string\n }\n\nconst Content = ({\n className,\n children,\n testId,\n value: _value,\n ...rest\n}: HoverCardContentProps) => {\n const { width, withinPortal, container, sliding } = useContext(HoverCardContext)\n const portalContainer = useOverlayContainer(container)\n const panel = (\n <Ark.Positioner style={sliding ? slideStyle : undefined}>\n <Ark.Content\n tabIndex={-1}\n className={cn(popoverChrome, width === \"target\" ? \"w-full\" : \"w-max\", className)}\n {...props({ \"data-testid\": testId })}\n {...rest}\n >\n {children}\n </Ark.Content>\n </Ark.Positioner>\n )\n if (!withinPortal) return panel\n return <Portal container={portalContainer}>{panel}</Portal>\n}\n\nexport type HoverCardGroupProps = Omit<Ark.RootProps, \"positioning\" | \"onOpenChange\" | \"children\"> &\n PlacementProps & {\n /** Match every trigger's width (`\"target\"`), or size to content (`\"auto\"`,\n * default). */\n width?: \"target\" | \"auto\"\n /** Render the panel in a Portal so it escapes clipping ancestors. Default `true`. */\n withinPortal?: boolean\n /** Portal target. Defaults to the enclosing `Modal`/`Drawer` when there is\n * one (so the panel stays above it), else `document.body`. */\n container?: HTMLElement | null\n /** Fires when the card opens or closes (flattened from Ark's detail object). */\n onOpenChange?: (open: boolean) => void\n /** Fires on close (any source) — pointer/focus leaving the whole group,\n * Escape, outside interaction, or a controlled `onOpenChange`. */\n onClose?: () => void\n /** `HoverCard.Trigger` (one per hover target, each with its own `value`)\n * and `HoverCard.Content` (one per target's content, `value`-matched to\n * its trigger) — the same parts `HoverCard.Root` uses, just several of\n * each instead of one. */\n children?: ReactNode\n }\n\n/**\n * One shared card across several hover targets (e.g. a row of avatars) — the\n * same `HoverCard.Trigger` / `HoverCard.Content` parts `HoverCard.Root` uses,\n * just several of each, disambiguated by a shared `value`:\n *\n * <HoverCard.Group>\n * <HoverCard.Trigger value=\"ada\">\n * <Avatar name=\"Ada Lovelace\" />\n * </HoverCard.Trigger>\n * <HoverCard.Trigger value=\"grace\">\n * <Avatar name=\"Grace Hopper\" />\n * </HoverCard.Trigger>\n *\n * <HoverCard.Content value=\"ada\">Ada's card content</HoverCard.Content>\n * <HoverCard.Content value=\"grace\">Grace's card content</HoverCard.Content>\n * </HoverCard.Group>\n *\n * Ark's HoverCard machine natively supports several named triggers under a\n * single `Root`/`Content` (a `triggerValue`, which `HoverCard.Trigger`'s\n * `value` already sets — it's a plain `Ark.Trigger` re-export): hovering from\n * one target to the next while the card is already open just repositions the\n * *same* panel instead of closing one and opening another — no unmount, no\n * delay replay. `Group` renders every `Trigger` child as-is (they need no\n * help — the machine already treats each `value` as a distinct target), but\n * intercepts every `Content` child: only the one whose `value` matches the\n * live `triggerValue` (read via Ark's `Context` render prop) is ever\n * rendered, in that one shared position — so React reconciles a value change\n * as a props update on the *same* `Content`/`Positioner`/`Content` element\n * tree, not an unmount-and-remount of a different one, which is what keeps\n * it one real, continuous DOM node to slide. Paired with a CSS transition on\n * the positioner's `transform` (`slideStyle`, applied by `Content`\n * whenever `sliding` is set), that reposition visibly slides the panel from\n * one target to the next.\n *\n * `Trigger`/`Content` must be `Group`'s own direct children — it only scans\n * one level (like `Timeline`/`Breadcrumb`), so wrapping them in an inner\n * `<div>` hides them from it entirely. `Group` (like `Root`) renders no DOM\n * node of its own, so for row-level layout (e.g. overlapping avatars via\n * `-space-x-2`), wrap `Group` itself from the outside instead — the actual\n * trigger elements still land exactly there, since `Content` is portaled\n * away separately.\n */\nconst Group = ({\n width = \"auto\",\n position,\n gutter,\n offset,\n hideWhenDetached,\n positioning,\n withinPortal = true,\n container,\n openDelay,\n children,\n onOpenChange,\n onClose,\n ...rest\n}: HoverCardGroupProps) => {\n const { dir } = useLocaleContext()\n const { contents, triggers } = splitGroupChildren(children, Content)\n const slide = useSlideAfterPlaced()\n\n return (\n <HoverCardContext.Provider value={{ width, withinPortal, container, sliding: slide.sliding }}>\n <Ark.Root\n lazyMount\n unmountOnExit\n openDelay={openDelay}\n positioning={toPositioning(\n {\n position,\n gutter,\n offset,\n hideWhenDetached,\n positioning: {\n ...positioning,\n updatePosition: slide.updatePosition(positioning?.updatePosition),\n },\n },\n dir,\n width,\n )}\n onOpenChange={({ open }) => {\n onOpenChange?.(open)\n slide.onOpenChange(open)\n if (!open) onClose?.()\n }}\n {...rest}\n >\n {triggers}\n <Ark.Context>{(api) => activeGroupContent(contents, api.triggerValue)}</Ark.Context>\n </Ark.Root>\n </HoverCardContext.Provider>\n )\n}\n\nexport const HoverCard = {\n Root,\n Trigger: Ark.Trigger,\n Content,\n Group,\n}\n"]}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import '../../chunk-AZ2VUAGX.js';
|
|
3
|
-
export { IMAGE_WIDTHS, Image, resolveSources } from '../../chunk-
|
|
3
|
+
export { IMAGE_WIDTHS, Image, resolveSources } from '../../chunk-Y57NW6G7.js';
|
|
4
4
|
import '../../chunk-J43LSYQO.js';
|
|
5
5
|
import '../../chunk-HBWV5EPU.js';
|
|
6
6
|
import '../../chunk-AHM6SGEU.js';
|
|
7
7
|
import '../../chunk-BUIHQJGE.js';
|
|
8
8
|
import '../../chunk-XXOR34T4.js';
|
|
9
9
|
import '../../chunk-WYCMIIRR.js';
|
|
10
|
-
import '../../chunk-
|
|
10
|
+
import '../../chunk-4ASNIDV7.js';
|
|
11
11
|
//# sourceMappingURL=index.js.map
|
|
12
12
|
//# sourceMappingURL=index.js.map
|