@jenesei-software/jenesei-kit-react 1.3.19 → 1.3.21
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/build/area-BG04bpxi.cjs +2 -0
- package/build/area-BG04bpxi.cjs.map +1 -0
- package/build/{area-CD8KKIM0.js → area-D4BoNEmX.js} +2 -2
- package/build/{area-CD8KKIM0.js.map → area-D4BoNEmX.js.map} +1 -1
- package/build/area-occQcGnD.js +19 -0
- package/build/area-occQcGnD.js.map +1 -0
- package/build/area-outside.cjs.js +1 -1
- package/build/area-outside.es.js +1 -1
- package/build/{area-Dup_lUb9.cjs → area-pCo19R2g.cjs} +2 -2
- package/build/{area-Dup_lUb9.cjs.map → area-pCo19R2g.cjs.map} +1 -1
- package/build/area-preview.cjs.js +1 -1
- package/build/area-preview.es.js +1 -1
- package/build/area-scroll.cjs.js +1 -1
- package/build/area-scroll.es.js +3 -2
- package/build/area-scroll.es.js.map +1 -1
- package/build/area-skeleton.cjs.js +1 -1
- package/build/area-skeleton.d.ts +6 -1
- package/build/area-skeleton.es.js +1 -1
- package/build/area-smooth.cjs.js +1 -1
- package/build/area-smooth.es.js +1 -1
- package/build/{area-BWxBop5m.js → area.styles-BSqCfPE4.js} +3 -18
- package/build/area.styles-BSqCfPE4.js.map +1 -0
- package/build/area.styles-BuceLNra.cjs +27 -0
- package/build/area.styles-BuceLNra.cjs.map +1 -0
- package/build/build-info.txt +3 -3
- package/build/{component-GKvpOWlO.cjs → component-5Utdcc2G.cjs} +7 -7
- package/build/{component-GKvpOWlO.cjs.map → component-5Utdcc2G.cjs.map} +1 -1
- package/build/component-86oA9dYz.cjs +2 -0
- package/build/component-86oA9dYz.cjs.map +1 -0
- package/build/{component.styles-0apMzB81.js → component-B--Ljzf8.js} +5 -75
- package/build/component-B--Ljzf8.js.map +1 -0
- package/build/component-Bq9jd15r.cjs +2 -0
- package/build/component-Bq9jd15r.cjs.map +1 -0
- package/build/{component.styles-euSUJAiA.js → component-C3BrgaVs.js} +5 -38
- package/build/component-C3BrgaVs.js.map +1 -0
- package/build/component-C7SV3z2B.js +10 -0
- package/build/component-C7SV3z2B.js.map +1 -0
- package/build/{component.styles-CwTYpBx_.js → component-C9TJVTRc.js} +11 -64
- package/build/component-C9TJVTRc.js.map +1 -0
- package/build/{component-6hRanOkU.cjs → component-CLqcB5mM.cjs} +2 -2
- package/build/{component-6hRanOkU.cjs.map → component-CLqcB5mM.cjs.map} +1 -1
- package/build/{component-B80It4vM.js → component-CS7C3l76.js} +5 -5
- package/build/component-CS7C3l76.js.map +1 -0
- package/build/{component-DpVp9dB1.js → component-CUiqQLEQ.js} +2 -2
- package/build/{component-DpVp9dB1.js.map → component-CUiqQLEQ.js.map} +1 -1
- package/build/{component.styles-AEJ_tw7Y.js → component-CWIsglCv.js} +4 -25
- package/build/component-CWIsglCv.js.map +1 -0
- package/build/component-CZPL9hGj.cjs +2 -0
- package/build/component-CZPL9hGj.cjs.map +1 -0
- package/build/{component-8NOxwZJO.cjs → component-Cc8X-Z80.cjs} +2 -2
- package/build/{component-8NOxwZJO.cjs.map → component-Cc8X-Z80.cjs.map} +1 -1
- package/build/{component.styles-KBaixm0o.js → component-CeZFnxeP.js} +4 -56
- package/build/component-CeZFnxeP.js.map +1 -0
- package/build/component-Cp8VTqb2.js +21 -0
- package/build/component-Cp8VTqb2.js.map +1 -0
- package/build/{component-CKBpm4U4.js → component-CqQpLjWf.js} +2 -3
- package/build/{component-CKBpm4U4.js.map → component-CqQpLjWf.js.map} +1 -1
- package/build/component-DAMiuCOk.js +39 -0
- package/build/component-DAMiuCOk.js.map +1 -0
- package/build/component-DBZIl6Pf.cjs +2 -0
- package/build/component-DBZIl6Pf.cjs.map +1 -0
- package/build/component-DC6wk9OC.cjs +2 -0
- package/build/component-DC6wk9OC.cjs.map +1 -0
- package/build/{component-mzzOCXSx.js → component-DEZX8aBs.js} +2 -2
- package/build/{component-mzzOCXSx.js.map → component-DEZX8aBs.js.map} +1 -1
- package/build/component-DgtdqEgO.cjs +2 -0
- package/build/component-DgtdqEgO.cjs.map +1 -0
- package/build/component-Dt1QKoQc.cjs +2 -0
- package/build/component-Dt1QKoQc.cjs.map +1 -0
- package/build/component-DvuH4WLo.cjs +2 -0
- package/build/component-DvuH4WLo.cjs.map +1 -0
- package/build/{component.styles-C4Bz4OTl.js → component-HpOulBAQ.js} +5 -17
- package/build/component-HpOulBAQ.js.map +1 -0
- package/build/component-O7HvTkOa.js +64 -0
- package/build/component-O7HvTkOa.js.map +1 -0
- package/build/component-PvY4ZuKa.cjs +2 -0
- package/build/component-PvY4ZuKa.cjs.map +1 -0
- package/build/component-SobV8wHk.cjs +2 -0
- package/build/component-SobV8wHk.cjs.map +1 -0
- package/build/component-VZLVznEM.cjs +2 -0
- package/build/component-VZLVznEM.cjs.map +1 -0
- package/build/component-accordion.cjs.js +1 -1
- package/build/component-accordion.d.ts +1 -1
- package/build/component-accordion.es.js +3 -2
- package/build/component-accordion.es.js.map +1 -1
- package/build/component-button-group.cjs.js +1 -1
- package/build/component-button-group.es.js +4 -3
- package/build/component-button-group.es.js.map +1 -1
- package/build/component-button.cjs.js +1 -1
- package/build/component-button.es.js +3 -3
- package/build/component-checkbox-group.cjs.js +1 -1
- package/build/component-checkbox-group.es.js +8 -7
- package/build/component-checkbox-group.es.js.map +1 -1
- package/build/component-checkbox.cjs.js +1 -1
- package/build/component-checkbox.es.js +6 -5
- package/build/component-checkbox.es.js.map +1 -1
- package/build/component-date-picker.cjs.js +1 -1
- package/build/component-date-picker.es.js +15 -14
- package/build/component-date-picker.es.js.map +1 -1
- package/build/component-icon.cjs.js +1 -1
- package/build/component-icon.d.ts +16 -3
- package/build/component-icon.es.js +6 -5
- package/build/component-image-button.cjs.js +1 -1
- package/build/component-image-button.es.js +1 -1
- package/build/component-image-select.cjs.js +1 -1
- package/build/component-image-select.es.js +8 -7
- package/build/component-image-select.es.js.map +1 -1
- package/build/component-image-slider.cjs.js +1 -1
- package/build/component-image-slider.es.js +5 -4
- package/build/component-image-slider.es.js.map +1 -1
- package/build/component-image.cjs.js +1 -1
- package/build/component-image.es.js +3 -2
- package/build/component-image.es.js.map +1 -1
- package/build/component-input-otp.cjs.js +1 -1
- package/build/component-input-otp.es.js +5 -4
- package/build/component-input-otp.es.js.map +1 -1
- package/build/component-input.cjs.js +1 -1
- package/build/component-input.es.js +15 -15
- package/build/component-iyi7lqrB.cjs +2 -0
- package/build/{component-Bj7sLW9s.cjs.map → component-iyi7lqrB.cjs.map} +1 -1
- package/build/component-map.cjs.js +1 -1
- package/build/component-map.es.js +13 -12
- package/build/component-map.es.js.map +1 -1
- package/build/component-pagination.cjs.js +1 -1
- package/build/component-pagination.es.js +1 -1
- package/build/component-range.cjs.js +1 -1
- package/build/component-range.es.js +5 -4
- package/build/component-range.es.js.map +1 -1
- package/build/component-ripple.cjs.js +1 -1
- package/build/component-select.cjs.js +1 -1
- package/build/component-select.d.ts +1 -1
- package/build/component-select.es.js +18 -18
- package/build/component-separator.cjs.js +1 -1
- package/build/component-separator.es.js +3 -2
- package/build/component-separator.es.js.map +1 -1
- package/build/component-stack.cjs.js +1 -1
- package/build/component-stack.es.js +1 -1
- package/build/component-textarea.cjs.js +1 -1
- package/build/component-textarea.es.js +5 -5
- package/build/component-toggle.cjs.js +1 -1
- package/build/component-toggle.es.js +4 -3
- package/build/component-toggle.es.js.map +1 -1
- package/build/component-tooltip.cjs.js +1 -1
- package/build/component-tooltip.es.js +9 -9
- package/build/component-typography.cjs.js +1 -1
- package/build/component-typography.es.js +6 -6
- package/build/component.components-Cck7T25y.cjs +2 -0
- package/build/component.components-Cck7T25y.cjs.map +1 -0
- package/build/{component.components-C9TkSqTp.js → component.components-NP2aSgyb.js} +8 -43
- package/build/component.components-NP2aSgyb.js.map +1 -0
- package/build/{component.constants-C8li5_tq.js → component.constants-3UuU_a__.js} +3 -3
- package/build/{component.constants-C8li5_tq.js.map → component.constants-3UuU_a__.js.map} +1 -1
- package/build/{component.constants-CnMky3Ym.js → component.constants-B0mODNks.js} +9 -35
- package/build/component.constants-B0mODNks.js.map +1 -0
- package/build/component.constants-CoFHa30V.cjs +2 -0
- package/build/{component.constants-B-ZMDpFv.cjs.map → component.constants-CoFHa30V.cjs.map} +1 -1
- package/build/component.constants-vNAPiC5p.cjs +2 -0
- package/build/component.constants-vNAPiC5p.cjs.map +1 -0
- package/build/component.styles-CD6ZzRrk.cjs +14 -0
- package/build/component.styles-CD6ZzRrk.cjs.map +1 -0
- package/build/{component.styles-BnJjm_ES.js → component.styles-SZ5VuhNG.js} +2 -19
- package/build/component.styles-SZ5VuhNG.js.map +1 -0
- package/build/component.types-BRZsYWlH.cjs +2 -0
- package/build/component.types-BRZsYWlH.cjs.map +1 -0
- package/build/{component.types-BoTWSvjd.js → component.types-Cysm3D4v.js} +5 -214
- package/build/component.types-Cysm3D4v.js.map +1 -0
- package/build/consts.cjs.js +1 -1
- package/build/consts.cjs.js.map +1 -1
- package/build/consts.d.ts +18 -16
- package/build/consts.es.js +28 -26
- package/build/consts.es.js.map +1 -1
- package/build/{context.functions-CQ9GerPb.js → context-B1DS5U6M.js} +3 -33
- package/build/{context.functions-CQ9GerPb.js.map → context-B1DS5U6M.js.map} +1 -1
- package/build/{context.functions-BD15C8_y.js → context-BxU5kwVR.js} +3 -33
- package/build/context-BxU5kwVR.js.map +1 -0
- package/build/{context.hooks-BzMTkJNv.js → context-CU_dgoUl.js} +3 -11
- package/build/context-CU_dgoUl.js.map +1 -0
- package/build/context-Cr9zS5ai.cjs +2 -0
- package/build/context-Cr9zS5ai.cjs.map +1 -0
- package/build/context-_4lcMeym.cjs +2 -0
- package/build/context-_4lcMeym.cjs.map +1 -0
- package/build/context-app.cjs.js +1 -1
- package/build/context-app.es.js +18 -17
- package/build/context-app.es.js.map +1 -1
- package/build/context-cookie.cjs.js +1 -1
- package/build/context-cookie.es.js +2 -1
- package/build/context-cookie.es.js.map +1 -1
- package/build/context-dialog.cjs.js +1 -1
- package/build/context-dialog.es.js +13 -12
- package/build/context-dialog.es.js.map +1 -1
- package/build/context-geolocation.cjs.js +1 -1
- package/build/context-geolocation.es.js +2 -1
- package/build/context-geolocation.es.js.map +1 -1
- package/build/context-local-storage.cjs.js +1 -1
- package/build/context-local-storage.es.js +2 -1
- package/build/context-local-storage.es.js.map +1 -1
- package/build/context-q6vhN54o.cjs +2 -0
- package/build/{context.functions-ohI9H54j.cjs.map → context-q6vhN54o.cjs.map} +1 -1
- package/build/context-sonner.cjs.js +1 -1
- package/build/context-sonner.es.js +18 -17
- package/build/context-sonner.es.js.map +1 -1
- package/build/context.constants-BVl2x1gR.js +8556 -0
- package/build/context.constants-BVl2x1gR.js.map +1 -0
- package/build/context.constants-BgXWD3zz.cjs +32 -0
- package/build/context.constants-BgXWD3zz.cjs.map +1 -0
- package/build/{context.constants-BCpaUfFz.js → context.constants-D-s5XvZX.js} +14 -52
- package/build/context.constants-D-s5XvZX.js.map +1 -0
- package/build/context.constants-YhrMPIvq.cjs +1750 -0
- package/build/context.constants-YhrMPIvq.cjs.map +1 -0
- package/build/context.functions-54_96FIi.js +36 -0
- package/build/context.functions-54_96FIi.js.map +1 -0
- package/build/context.functions-Bk5xMi0w.cjs +2 -0
- package/build/context.functions-Bk5xMi0w.cjs.map +1 -0
- package/build/context.functions-BoRkDnCa.cjs +2 -0
- package/build/context.functions-BoRkDnCa.cjs.map +1 -0
- package/build/context.functions-X5gRRpKi.js +35 -0
- package/build/context.functions-X5gRRpKi.js.map +1 -0
- package/build/context.hooks-99wJ8TBG.cjs +2 -0
- package/build/context.hooks-99wJ8TBG.cjs.map +1 -0
- package/build/context.hooks-B16qxQQY.cjs +2 -0
- package/build/context.hooks-B16qxQQY.cjs.map +1 -0
- package/build/context.hooks-DjwMqRSt.js +13 -0
- package/build/context.hooks-DjwMqRSt.js.map +1 -0
- package/build/context.hooks-Dkb5yK8Z.cjs +2 -0
- package/build/context.hooks-Dkb5yK8Z.cjs.map +1 -0
- package/build/context.hooks-KS9z3sac.js +13 -0
- package/build/context.hooks-KS9z3sac.js.map +1 -0
- package/build/context.hooks-OTo7Znss.cjs +2 -0
- package/build/context.hooks-OTo7Znss.cjs.map +1 -0
- package/build/context.hooks-fo2TeZoK.js +44 -0
- package/build/context.hooks-fo2TeZoK.js.map +1 -0
- package/build/context.hooks-uRILnzQk.js +13 -0
- package/build/context.hooks-uRILnzQk.js.map +1 -0
- package/build/index.cjs.js +1 -1
- package/build/index.d.ts +38 -24
- package/build/index.es.js +282 -283
- package/build/index.es.js.map +1 -1
- package/build/style-error.cjs.js +1 -1
- package/build/style-error.es.js +4 -4
- package/build/style-theme.cjs.js +1 -1
- package/build/style-theme.es.js +13 -13
- package/build/types.d.ts +3 -3
- package/build/{use-CnGHh8iL.js → use-BI2JJFUm.js} +8 -9
- package/build/{use-CnGHh8iL.js.map → use-BI2JJFUm.js.map} +1 -1
- package/build/{use-BLwltPMc.cjs → use-CtF6jyms.cjs} +3 -3
- package/build/{use-BLwltPMc.cjs.map → use-CtF6jyms.cjs.map} +1 -1
- package/package.json +1 -1
- package/build/area-BDMDiVi1.js +0 -68
- package/build/area-BDMDiVi1.js.map +0 -1
- package/build/area-BWxBop5m.js.map +0 -1
- package/build/area-Bopd6mWj.cjs +0 -2
- package/build/area-Bopd6mWj.cjs.map +0 -1
- package/build/area-CmCMHnRA.cjs +0 -27
- package/build/area-CmCMHnRA.cjs.map +0 -1
- package/build/area-Cvp3eBBo.js +0 -114
- package/build/area-Cvp3eBBo.js.map +0 -1
- package/build/area-DqLK4RX5.cjs +0 -40
- package/build/area-DqLK4RX5.cjs.map +0 -1
- package/build/component-5o60aes-.cjs +0 -52
- package/build/component-5o60aes-.cjs.map +0 -1
- package/build/component-B80It4vM.js.map +0 -1
- package/build/component-BfppCwz9.cjs +0 -88
- package/build/component-BfppCwz9.cjs.map +0 -1
- package/build/component-Bj7sLW9s.cjs +0 -2
- package/build/component-BxetIWe6.cjs +0 -245
- package/build/component-BxetIWe6.cjs.map +0 -1
- package/build/component-ClnOIQaN.js +0 -66
- package/build/component-ClnOIQaN.js.map +0 -1
- package/build/component-b4tMFkpE.cjs +0 -2
- package/build/component-b4tMFkpE.cjs.map +0 -1
- package/build/component-eqTj4VVc.js +0 -728
- package/build/component-eqTj4VVc.js.map +0 -1
- package/build/component-jPLOz52P.js +0 -186
- package/build/component-jPLOz52P.js.map +0 -1
- package/build/component.components-BZX00SGG.cjs +0 -16
- package/build/component.components-BZX00SGG.cjs.map +0 -1
- package/build/component.components-C9TkSqTp.js.map +0 -1
- package/build/component.constants-B-ZMDpFv.cjs +0 -2
- package/build/component.constants-CnMky3Ym.js.map +0 -1
- package/build/component.constants-Dg6JcWmd.cjs +0 -22
- package/build/component.constants-Dg6JcWmd.cjs.map +0 -1
- package/build/component.styles-0apMzB81.js.map +0 -1
- package/build/component.styles-AEJ_tw7Y.js.map +0 -1
- package/build/component.styles-BO8xaSCQ.cjs +0 -65
- package/build/component.styles-BO8xaSCQ.cjs.map +0 -1
- package/build/component.styles-BVQQkX5c.cjs +0 -57
- package/build/component.styles-BVQQkX5c.cjs.map +0 -1
- package/build/component.styles-BYG4iVCR.cjs +0 -10
- package/build/component.styles-BYG4iVCR.cjs.map +0 -1
- package/build/component.styles-BZ9QLlOU.cjs +0 -39
- package/build/component.styles-BZ9QLlOU.cjs.map +0 -1
- package/build/component.styles-BnJjm_ES.js.map +0 -1
- package/build/component.styles-BviHtzJH.cjs +0 -22
- package/build/component.styles-BviHtzJH.cjs.map +0 -1
- package/build/component.styles-C4Bz4OTl.js.map +0 -1
- package/build/component.styles-C8ONgWei.cjs +0 -47
- package/build/component.styles-C8ONgWei.cjs.map +0 -1
- package/build/component.styles-CHqowxsZ.js +0 -81
- package/build/component.styles-CHqowxsZ.js.map +0 -1
- package/build/component.styles-CLn52hJD.cjs +0 -14
- package/build/component.styles-CLn52hJD.cjs.map +0 -1
- package/build/component.styles-CXyyc0xg.cjs +0 -32
- package/build/component.styles-CXyyc0xg.cjs.map +0 -1
- package/build/component.styles-CtZeOnGH.js +0 -120
- package/build/component.styles-CtZeOnGH.js.map +0 -1
- package/build/component.styles-CwTYpBx_.js.map +0 -1
- package/build/component.styles-CxlbZwr4.cjs +0 -225
- package/build/component.styles-CxlbZwr4.cjs.map +0 -1
- package/build/component.styles-CyCy2ymw.cjs +0 -21
- package/build/component.styles-CyCy2ymw.cjs.map +0 -1
- package/build/component.styles-DWDGLfbF.js +0 -137
- package/build/component.styles-DWDGLfbF.js.map +0 -1
- package/build/component.styles-DqJURuJl.js +0 -1370
- package/build/component.styles-DqJURuJl.js.map +0 -1
- package/build/component.styles-FMHm5NHm.cjs +0 -99
- package/build/component.styles-FMHm5NHm.cjs.map +0 -1
- package/build/component.styles-Hx-MJSWX.cjs +0 -137
- package/build/component.styles-Hx-MJSWX.cjs.map +0 -1
- package/build/component.styles-KBaixm0o.js.map +0 -1
- package/build/component.styles-SZTM0cRW.js +0 -1046
- package/build/component.styles-SZTM0cRW.js.map +0 -1
- package/build/component.styles-_keFf_Qj.cjs +0 -13
- package/build/component.styles-_keFf_Qj.cjs.map +0 -1
- package/build/component.styles-cMafDDpP.js +0 -233
- package/build/component.styles-cMafDDpP.js.map +0 -1
- package/build/component.styles-euSUJAiA.js.map +0 -1
- package/build/component.types-BoTWSvjd.js.map +0 -1
- package/build/component.types-WiRcl02d.cjs +0 -176
- package/build/component.types-WiRcl02d.cjs.map +0 -1
- package/build/context.constants-BCpaUfFz.js.map +0 -1
- package/build/context.constants-BLQ_1jZI.cjs +0 -32
- package/build/context.constants-BLQ_1jZI.cjs.map +0 -1
- package/build/context.constants-Cio0nsYA.js +0 -393
- package/build/context.constants-Cio0nsYA.js.map +0 -1
- package/build/context.constants-y9s5VGN2.cjs +0 -99
- package/build/context.constants-y9s5VGN2.cjs.map +0 -1
- package/build/context.functions-80N-5MqM.cjs +0 -2
- package/build/context.functions-80N-5MqM.cjs.map +0 -1
- package/build/context.functions-BD15C8_y.js.map +0 -1
- package/build/context.functions-ohI9H54j.cjs +0 -2
- package/build/context.hooks-BIIK-2HN.js +0 -527
- package/build/context.hooks-BIIK-2HN.js.map +0 -1
- package/build/context.hooks-BzMTkJNv.js.map +0 -1
- package/build/context.hooks-DNnrgKb0.cjs +0 -72
- package/build/context.hooks-DNnrgKb0.cjs.map +0 -1
- package/build/context.hooks-u408Pxw8.cjs +0 -2
- package/build/context.hooks-u408Pxw8.cjs.map +0 -1
- package/build/floating-ui.react-Byi6bLb1.js +0 -1818
- package/build/floating-ui.react-Byi6bLb1.js.map +0 -1
- package/build/floating-ui.react-DZzvtpim.cjs +0 -2
- package/build/floating-ui.react-DZzvtpim.cjs.map +0 -1
- package/build/style-BzxSHZDV.js +0 -61
- package/build/style-BzxSHZDV.js.map +0 -1
- package/build/style-D8DUzG0C.cjs +0 -32
- package/build/style-D8DUzG0C.cjs.map +0 -1
- package/build/theme.global-BzunMIsv.js +0 -1318
- package/build/theme.global-BzunMIsv.js.map +0 -1
- package/build/theme.global-D67h5YeA.cjs +0 -173
- package/build/theme.global-D67h5YeA.cjs.map +0 -1
|
@@ -1,728 +0,0 @@
|
|
|
1
|
-
import { j as jsxRuntimeExports } from "./jsx-runtime-BrDlu8eK.js";
|
|
2
|
-
import { u as useScreenWidth } from "./context.hooks-BmwyZ1p3.js";
|
|
3
|
-
import { useMemo, useState, useRef, useEffect, useLayoutEffect, useCallback, memo } from "react";
|
|
4
|
-
import { u as useDeepCompareMemoize } from "./use-DT0XgvJT.js";
|
|
5
|
-
import { createLink } from "@tanstack/react-router";
|
|
6
|
-
import { J as JeneseiPalette, K as KEY_SIZE_DATA } from "./theme.global-BzunMIsv.js";
|
|
7
|
-
import styled, { keyframes, css, useTheme } from "styled-components";
|
|
8
|
-
import { a as useFloating, b as autoUpdate, o as offset, f as flip, s as shift } from "./floating-ui.react-Byi6bLb1.js";
|
|
9
|
-
import { AnimatePresence, motion } from "framer-motion";
|
|
10
|
-
import ReactDOM__default from "react-dom";
|
|
11
|
-
import { g as addOutline, c as addFont, i as addAlwaysOutline } from "./style-RL73t3JD.js";
|
|
12
|
-
import { a as addSX } from "./style-plT9Ah7t.js";
|
|
13
|
-
import { b as Stack } from "./component-mzzOCXSx.js";
|
|
14
|
-
const shadowPulse = keyframes`
|
|
15
|
-
0% {
|
|
16
|
-
text-shadow: 0 0 0 rgba(0, 0, 0, 0);
|
|
17
|
-
}
|
|
18
|
-
50% {
|
|
19
|
-
text-shadow: 4px 4px 10px rgba(0, 0, 0, 0.5);
|
|
20
|
-
}
|
|
21
|
-
100% {
|
|
22
|
-
text-shadow: 0 0 0 rgba(0, 0, 0, 0);
|
|
23
|
-
}
|
|
24
|
-
`;
|
|
25
|
-
function toStyledCSS(value) {
|
|
26
|
-
return css`
|
|
27
|
-
${value.shadow && value.shadow === "shadowPulse" && css`
|
|
28
|
-
animation: ${shadowPulse} 2s infinite;
|
|
29
|
-
`};
|
|
30
|
-
${value.letterSpacing && css`
|
|
31
|
-
letter-spacing: ${value.letterSpacing};
|
|
32
|
-
`};
|
|
33
|
-
${value.flex && css`
|
|
34
|
-
flex: ${value.flex};
|
|
35
|
-
`};
|
|
36
|
-
${value.cursor && css`
|
|
37
|
-
cursor: ${value.cursor};
|
|
38
|
-
`};
|
|
39
|
-
${value.overflow && css`
|
|
40
|
-
overflow: ${value.overflow};
|
|
41
|
-
`};
|
|
42
|
-
${value.line !== void 0 ? value.line === 1 ? css`
|
|
43
|
-
text-overflow: ellipsis;
|
|
44
|
-
overflow: hidden;
|
|
45
|
-
white-space: nowrap;
|
|
46
|
-
width: -webkit-fill-available;
|
|
47
|
-
max-width: fit-content;
|
|
48
|
-
` : css`
|
|
49
|
-
word-break: break-word;
|
|
50
|
-
white-space: normal;
|
|
51
|
-
text-overflow: ellipsis;
|
|
52
|
-
display: -webkit-box;
|
|
53
|
-
overflow: hidden;
|
|
54
|
-
-webkit-box-orient: vertical;
|
|
55
|
-
-webkit-line-clamp: ${value.line};
|
|
56
|
-
width: fit-content;
|
|
57
|
-
overflow-wrap: anywhere;
|
|
58
|
-
` : css``};
|
|
59
|
-
${value.family && css`
|
|
60
|
-
font-family: ${value.family};
|
|
61
|
-
`};
|
|
62
|
-
${value.weight && css`
|
|
63
|
-
font-weight: ${value.weight};
|
|
64
|
-
`};
|
|
65
|
-
${value.height && css`
|
|
66
|
-
line-height: ${value.height}px;
|
|
67
|
-
`};
|
|
68
|
-
${value.color && css`
|
|
69
|
-
color: ${JeneseiPalette[value.color]};
|
|
70
|
-
`};
|
|
71
|
-
${value.align && css`
|
|
72
|
-
text-align: ${value.align};
|
|
73
|
-
`};
|
|
74
|
-
${value.wrap && css`
|
|
75
|
-
text-wrap: ${value.wrap};
|
|
76
|
-
`};
|
|
77
|
-
${value.decoration && css`
|
|
78
|
-
text-decoration: ${value.decoration};
|
|
79
|
-
`};
|
|
80
|
-
${value.transform && css`
|
|
81
|
-
text-transform: ${value.transform};
|
|
82
|
-
`};
|
|
83
|
-
${value.isHoverUnderlining && css`
|
|
84
|
-
&:hover {
|
|
85
|
-
text-decoration: underline;
|
|
86
|
-
}
|
|
87
|
-
`};
|
|
88
|
-
${value.isNoUserSelect && css`
|
|
89
|
-
user-select: none;
|
|
90
|
-
-webkit-user-select: none;
|
|
91
|
-
-moz-user-select: none;
|
|
92
|
-
-ms-user-select: none;
|
|
93
|
-
`};
|
|
94
|
-
${"size" in value && value.size && css`
|
|
95
|
-
font-size: ${value.size}px;
|
|
96
|
-
`};
|
|
97
|
-
${"variant" in value && value.variant ? value.variant === "h1" ? css`
|
|
98
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h1 * props.theme.font.sizeDefault.default}px;
|
|
99
|
-
line-height: ${(props) => props.theme.font.lineHeight};
|
|
100
|
-
margin: 0;
|
|
101
|
-
@media (max-width: ${(props) => props.theme.screens.tablet.width}px) {
|
|
102
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h1 * props.theme.font.sizeDefault.tablet}px;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
@media (max-width: ${(props) => props.theme.screens.mobile.width}px) {
|
|
106
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h1 * props.theme.font.sizeDefault.mobile}px;
|
|
107
|
-
}
|
|
108
|
-
` : value.variant === "h2" ? css`
|
|
109
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h2 * props.theme.font.sizeDefault.default}px;
|
|
110
|
-
line-height: ${(props) => props.theme.font.lineHeight};
|
|
111
|
-
margin: 0;
|
|
112
|
-
@media (max-width: ${(props) => props.theme.screens.tablet.width}px) {
|
|
113
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h2 * props.theme.font.sizeDefault.tablet}px;
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
@media (max-width: ${(props) => props.theme.screens.mobile.width}px) {
|
|
117
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h2 * props.theme.font.sizeDefault.mobile}px;
|
|
118
|
-
}
|
|
119
|
-
` : value.variant === "h3" ? css`
|
|
120
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h3 * props.theme.font.sizeDefault.default}px;
|
|
121
|
-
line-height: ${(props) => props.theme.font.lineHeight};
|
|
122
|
-
margin: 0;
|
|
123
|
-
@media (max-width: ${(props) => props.theme.screens.tablet.width}px) {
|
|
124
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h3 * props.theme.font.sizeDefault.tablet}px;
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
@media (max-width: ${(props) => props.theme.screens.mobile.width}px) {
|
|
128
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h3 * props.theme.font.sizeDefault.mobile}px;
|
|
129
|
-
}
|
|
130
|
-
` : value.variant === "h4" ? css`
|
|
131
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h4 * props.theme.font.sizeDefault.default}px;
|
|
132
|
-
line-height: ${(props) => props.theme.font.lineHeight};
|
|
133
|
-
margin: 0;
|
|
134
|
-
@media (max-width: ${(props) => props.theme.screens.tablet.width}px) {
|
|
135
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h4 * props.theme.font.sizeDefault.tablet}px;
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
@media (max-width: ${(props) => props.theme.screens.mobile.width}px) {
|
|
139
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h4 * props.theme.font.sizeDefault.mobile}px;
|
|
140
|
-
}
|
|
141
|
-
` : value.variant === "h5" ? css`
|
|
142
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h5 * props.theme.font.sizeDefault.default}px;
|
|
143
|
-
line-height: ${(props) => props.theme.font.lineHeight};
|
|
144
|
-
margin: 0;
|
|
145
|
-
@media (max-width: ${(props) => props.theme.screens.tablet.width}px) {
|
|
146
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h5 * props.theme.font.sizeDefault.tablet}px;
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
@media (max-width: ${(props) => props.theme.screens.mobile.width}px) {
|
|
150
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h5 * props.theme.font.sizeDefault.mobile}px;
|
|
151
|
-
}
|
|
152
|
-
` : value.variant === "h6" ? css`
|
|
153
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h6 * props.theme.font.sizeDefault.default}px;
|
|
154
|
-
line-height: ${(props) => props.theme.font.lineHeight};
|
|
155
|
-
margin: 0;
|
|
156
|
-
@media (max-width: ${(props) => props.theme.screens.tablet.width}px) {
|
|
157
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h6 * props.theme.font.sizeDefault.tablet}px;
|
|
158
|
-
}
|
|
159
|
-
|
|
160
|
-
@media (max-width: ${(props) => props.theme.screens.mobile.width}px) {
|
|
161
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h6 * props.theme.font.sizeDefault.mobile}px;
|
|
162
|
-
}
|
|
163
|
-
` : value.variant === "h7" ? css`
|
|
164
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h7 * props.theme.font.sizeDefault.default}px;
|
|
165
|
-
line-height: ${(props) => props.theme.font.lineHeight};
|
|
166
|
-
margin: 0;
|
|
167
|
-
@media (max-width: ${(props) => props.theme.screens.tablet.width}px) {
|
|
168
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h7 * props.theme.font.sizeDefault.tablet}px;
|
|
169
|
-
}
|
|
170
|
-
|
|
171
|
-
@media (max-width: ${(props) => props.theme.screens.mobile.width}px) {
|
|
172
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h7 * props.theme.font.sizeDefault.mobile}px;
|
|
173
|
-
}
|
|
174
|
-
` : value.variant === "h8" ? css`
|
|
175
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h8 * props.theme.font.sizeDefault.default}px;
|
|
176
|
-
line-height: ${(props) => props.theme.font.lineHeight};
|
|
177
|
-
margin: 0;
|
|
178
|
-
@media (max-width: ${(props) => props.theme.screens.tablet.width}px) {
|
|
179
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h8 * props.theme.font.sizeDefault.tablet}px;
|
|
180
|
-
}
|
|
181
|
-
|
|
182
|
-
@media (max-width: ${(props) => props.theme.screens.mobile.width}px) {
|
|
183
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h8 * props.theme.font.sizeDefault.mobile}px;
|
|
184
|
-
}
|
|
185
|
-
` : value.variant === "h9" ? css`
|
|
186
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h9 * props.theme.font.sizeDefault.default}px;
|
|
187
|
-
line-height: ${(props) => props.theme.font.lineHeight};
|
|
188
|
-
margin: 0;
|
|
189
|
-
@media (max-width: ${(props) => props.theme.screens.tablet.width}px) {
|
|
190
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h9 * props.theme.font.sizeDefault.tablet}px;
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
@media (max-width: ${(props) => props.theme.screens.mobile.width}px) {
|
|
194
|
-
font-size: ${(props) => props.theme.font.sizeHeading.h9 * props.theme.font.sizeDefault.mobile}px;
|
|
195
|
-
}
|
|
196
|
-
` : null : null};
|
|
197
|
-
`;
|
|
198
|
-
}
|
|
199
|
-
const addSXTypography = css`
|
|
200
|
-
${(props) => {
|
|
201
|
-
const rawSX = props.$sxTypography;
|
|
202
|
-
if (!rawSX) return null;
|
|
203
|
-
return toStyledCSS(rawSX.default);
|
|
204
|
-
}}
|
|
205
|
-
|
|
206
|
-
${(props) => {
|
|
207
|
-
const rawSX = props.$sxTypography;
|
|
208
|
-
if (!rawSX) return null;
|
|
209
|
-
return Object.entries(rawSX).filter(([key]) => key !== "default").map(([deviceKey, value]) => {
|
|
210
|
-
var _a;
|
|
211
|
-
const screenWidth = (_a = props.theme.screens[deviceKey]) == null ? void 0 : _a.width;
|
|
212
|
-
if (!screenWidth) return null;
|
|
213
|
-
return css`
|
|
214
|
-
@media (max-width: ${screenWidth}px) {
|
|
215
|
-
${toStyledCSS(value)}
|
|
216
|
-
}
|
|
217
|
-
`;
|
|
218
|
-
});
|
|
219
|
-
}}
|
|
220
|
-
`;
|
|
221
|
-
const TypographyCSS = css`
|
|
222
|
-
font-style: normal;
|
|
223
|
-
position: relative;
|
|
224
|
-
overflow: visible;
|
|
225
|
-
text-overflow: ellipsis;
|
|
226
|
-
overflow-wrap: anywhere;
|
|
227
|
-
line-height: ${(props) => props.theme.font.lineHeight};
|
|
228
|
-
${addSXTypography};
|
|
229
|
-
${addSX}
|
|
230
|
-
`;
|
|
231
|
-
const Title = styled.span`
|
|
232
|
-
${TypographyCSS}
|
|
233
|
-
${addOutline}
|
|
234
|
-
`;
|
|
235
|
-
function useOverflowing(props) {
|
|
236
|
-
const isCheckSize = useMemo(() => (props == null ? void 0 : props.isCheckSize) ?? true, [props == null ? void 0 : props.isCheckSize]);
|
|
237
|
-
const isParentMode = useMemo(() => (props == null ? void 0 : props.mode) === "parent", [props == null ? void 0 : props.mode]);
|
|
238
|
-
const [isOverflowing, setIsOverflowing] = useState(
|
|
239
|
-
(props == null ? void 0 : props.isOverflowing) !== void 0 ? props == null ? void 0 : props.isOverflowing : false
|
|
240
|
-
);
|
|
241
|
-
const ref = useRef(null);
|
|
242
|
-
const dependencies = useDeepCompareMemoize(props == null ? void 0 : props.dependencies);
|
|
243
|
-
useEffect(() => {
|
|
244
|
-
if (!isCheckSize) return;
|
|
245
|
-
const checkOverflow = () => {
|
|
246
|
-
const el = ref.current;
|
|
247
|
-
if (!el) return;
|
|
248
|
-
const scrollWidth = el.scrollWidth;
|
|
249
|
-
const scrollHeight = el.scrollHeight;
|
|
250
|
-
const clientWidth = isParentMode && el.parentElement ? el.parentElement.clientWidth : el.clientWidth;
|
|
251
|
-
const clientHeight = isParentMode && el.parentElement ? el.parentElement.clientHeight : el.clientHeight;
|
|
252
|
-
setIsOverflowing(scrollWidth > clientWidth || scrollHeight > clientHeight);
|
|
253
|
-
};
|
|
254
|
-
checkOverflow();
|
|
255
|
-
window.addEventListener("resize", checkOverflow);
|
|
256
|
-
return () => window.removeEventListener("resize", checkOverflow);
|
|
257
|
-
}, [dependencies, isCheckSize, isParentMode]);
|
|
258
|
-
return { isDisabled: !isOverflowing, ref, isOverflowing };
|
|
259
|
-
}
|
|
260
|
-
const Popover = (props) => {
|
|
261
|
-
var _a, _b, _c, _d;
|
|
262
|
-
const theme = useTheme();
|
|
263
|
-
return ReactDOM__default.createPortal(
|
|
264
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(AnimatePresence, { children: props.isOpen && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
265
|
-
"div",
|
|
266
|
-
{
|
|
267
|
-
tabIndex: -1,
|
|
268
|
-
ref: props.ref,
|
|
269
|
-
style: {
|
|
270
|
-
position: "absolute",
|
|
271
|
-
top: 0,
|
|
272
|
-
left: 0,
|
|
273
|
-
...props.floatingStyles,
|
|
274
|
-
transform: props.floatingStyles.transform,
|
|
275
|
-
zIndex: 9999
|
|
276
|
-
},
|
|
277
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
278
|
-
PopoverWrapper,
|
|
279
|
-
{
|
|
280
|
-
tabIndex: -1,
|
|
281
|
-
$isShowAlwaysOutline: props.isShowAlwaysOutline,
|
|
282
|
-
$genre: props.genre ?? "black",
|
|
283
|
-
$font: {
|
|
284
|
-
size: ((_a = props.font) == null ? void 0 : _a.size) ?? KEY_SIZE_DATA[props.size ?? "medium"].font,
|
|
285
|
-
weight: ((_b = props.font) == null ? void 0 : _b.weight) ?? 700,
|
|
286
|
-
family: ((_c = props.font) == null ? void 0 : _c.family) ?? theme.font.family,
|
|
287
|
-
height: (_d = props.font) == null ? void 0 : _d.height
|
|
288
|
-
},
|
|
289
|
-
className: props.className,
|
|
290
|
-
initial: { opacity: 0, scale: 0.95 },
|
|
291
|
-
animate: { opacity: 1, scale: 1 },
|
|
292
|
-
exit: { opacity: 0, scale: 0.95 },
|
|
293
|
-
transition: { duration: 0.2 },
|
|
294
|
-
$sx: props.sx,
|
|
295
|
-
$size: props.size,
|
|
296
|
-
$sxTypography: props.sxTypography,
|
|
297
|
-
$maxHeight: props.maxHeight,
|
|
298
|
-
$maxWidth: props.maxWidth,
|
|
299
|
-
children: props.children
|
|
300
|
-
}
|
|
301
|
-
)
|
|
302
|
-
}
|
|
303
|
-
) }),
|
|
304
|
-
document.body
|
|
305
|
-
);
|
|
306
|
-
};
|
|
307
|
-
const usePopover = (props) => {
|
|
308
|
-
const { onFocus, onBlur, onBlurReference } = props;
|
|
309
|
-
const [isOpen, setIsOpen] = useState(false);
|
|
310
|
-
const [minWidth, setMinWidth] = useState(void 0);
|
|
311
|
-
const [wasEverOpen, setWasEverOpen] = useState(false);
|
|
312
|
-
const {
|
|
313
|
-
refs,
|
|
314
|
-
floatingStyles,
|
|
315
|
-
update,
|
|
316
|
-
placement: actualPlacement
|
|
317
|
-
} = useFloating({
|
|
318
|
-
open: isOpen,
|
|
319
|
-
placement: props.placement,
|
|
320
|
-
middleware: [offset(props.offset ?? 8), flip(), shift()],
|
|
321
|
-
whileElementsMounted: autoUpdate
|
|
322
|
-
});
|
|
323
|
-
const clickOutsideHandler = useRef(null);
|
|
324
|
-
const hoverCloseTimeout = useRef(null);
|
|
325
|
-
const hoverOffset = useMemo(
|
|
326
|
-
() => props.hoverOffset ?? props.offset ?? DEFAULT_POPOVER_OFFSET,
|
|
327
|
-
[props.hoverOffset, props.offset]
|
|
328
|
-
);
|
|
329
|
-
const hoverCloseDelay = useMemo(() => props.hoverCloseDelay ?? DEFAULT_POPOVER_CLOSE_DELAY, [props.hoverCloseDelay]);
|
|
330
|
-
useEffect(() => {
|
|
331
|
-
if (props.isDisabled) return;
|
|
332
|
-
const refEl = refs.reference.current;
|
|
333
|
-
if (!refEl) return;
|
|
334
|
-
if ((props.mode === "click" || props.mode === "clickOpen") && refEl instanceof HTMLElement) {
|
|
335
|
-
const handleClick = () => {
|
|
336
|
-
if (props.mode === "click") {
|
|
337
|
-
setIsOpen((prev) => !prev);
|
|
338
|
-
} else if (props.mode === "clickOpen") {
|
|
339
|
-
setIsOpen(true);
|
|
340
|
-
}
|
|
341
|
-
};
|
|
342
|
-
refEl.addEventListener("click", handleClick);
|
|
343
|
-
return () => {
|
|
344
|
-
refEl.removeEventListener("click", handleClick);
|
|
345
|
-
};
|
|
346
|
-
} else if (props.mode === "hover" && refEl instanceof HTMLElement) {
|
|
347
|
-
const handleMouseEnter = () => {
|
|
348
|
-
setIsOpen(true);
|
|
349
|
-
};
|
|
350
|
-
const handleMouseLeave = () => {
|
|
351
|
-
if (hoverCloseTimeout.current) clearTimeout(hoverCloseTimeout.current);
|
|
352
|
-
hoverCloseTimeout.current = setTimeout(() => setIsOpen(false), hoverCloseDelay);
|
|
353
|
-
};
|
|
354
|
-
refEl.addEventListener("mouseenter", handleMouseEnter);
|
|
355
|
-
refEl.addEventListener("mouseleave", handleMouseLeave);
|
|
356
|
-
return () => {
|
|
357
|
-
refEl.removeEventListener("mouseenter", handleMouseEnter);
|
|
358
|
-
refEl.removeEventListener("mouseleave", handleMouseLeave);
|
|
359
|
-
if (hoverCloseTimeout.current) clearTimeout(hoverCloseTimeout.current);
|
|
360
|
-
};
|
|
361
|
-
}
|
|
362
|
-
}, [props.mode, refs.reference, hoverCloseDelay, props.isDisabled]);
|
|
363
|
-
useEffect(() => {
|
|
364
|
-
if (!isOpen || !refs.reference.current || !refs.floating.current || props.isDisabled) return;
|
|
365
|
-
const cleanup = autoUpdate(refs.reference.current, refs.floating.current, update);
|
|
366
|
-
return () => cleanup();
|
|
367
|
-
}, [isOpen, refs.reference, refs.floating, update, props.isDisabled]);
|
|
368
|
-
useEffect(() => {
|
|
369
|
-
if (!isOpen || !refs.reference.current || !refs.floating.current || props.isDisabled) return;
|
|
370
|
-
if (props.isClickOutside) {
|
|
371
|
-
clickOutsideHandler.current = (e) => {
|
|
372
|
-
const refEl = refs.reference.current;
|
|
373
|
-
const floatingEl = refs.floating.current;
|
|
374
|
-
const otherRefs = props.refsExcludeClickOutside || [];
|
|
375
|
-
if (refEl instanceof HTMLElement && floatingEl instanceof HTMLElement && !refEl.contains(e.target) && !floatingEl.contains(e.target) && !otherRefs.some((ref) => {
|
|
376
|
-
var _a;
|
|
377
|
-
if (typeof ref === "object" && ref !== null && "current" in ref) {
|
|
378
|
-
return (_a = ref.current) == null ? void 0 : _a.contains(e.target);
|
|
379
|
-
}
|
|
380
|
-
return false;
|
|
381
|
-
})) {
|
|
382
|
-
setIsOpen(false);
|
|
383
|
-
}
|
|
384
|
-
};
|
|
385
|
-
document.addEventListener("mousedown", clickOutsideHandler.current);
|
|
386
|
-
}
|
|
387
|
-
return () => {
|
|
388
|
-
if (clickOutsideHandler.current) {
|
|
389
|
-
document.removeEventListener("mousedown", clickOutsideHandler.current);
|
|
390
|
-
clickOutsideHandler.current = null;
|
|
391
|
-
}
|
|
392
|
-
if (hoverCloseTimeout.current) {
|
|
393
|
-
clearTimeout(hoverCloseTimeout.current);
|
|
394
|
-
}
|
|
395
|
-
};
|
|
396
|
-
}, [isOpen, refs.reference, refs.floating, props.isClickOutside, props.isDisabled, props.refsExcludeClickOutside]);
|
|
397
|
-
useEffect(() => {
|
|
398
|
-
if (!isOpen || !props.isFloatingHover || !refs.reference.current || !refs.floating.current || props.isDisabled)
|
|
399
|
-
return;
|
|
400
|
-
const refEl = refs.reference.current;
|
|
401
|
-
const floatingEl = refs.floating.current;
|
|
402
|
-
const handleMouseMove = (e) => {
|
|
403
|
-
const mouseX = e.clientX;
|
|
404
|
-
const mouseY = e.clientY;
|
|
405
|
-
const refRect = refEl.getBoundingClientRect();
|
|
406
|
-
const floatingRect = floatingEl.getBoundingClientRect();
|
|
407
|
-
const isInsideRef = mouseX >= refRect.left - hoverOffset && mouseX <= refRect.right + hoverOffset && mouseY >= refRect.top - hoverOffset && mouseY <= refRect.bottom + hoverOffset;
|
|
408
|
-
const isInsideFloating = mouseX >= floatingRect.left - hoverOffset && mouseX <= floatingRect.right + hoverOffset && mouseY >= floatingRect.top - hoverOffset && mouseY <= floatingRect.bottom + hoverOffset;
|
|
409
|
-
if (isInsideRef || isInsideFloating) {
|
|
410
|
-
if (hoverCloseTimeout.current) {
|
|
411
|
-
clearTimeout(hoverCloseTimeout.current);
|
|
412
|
-
hoverCloseTimeout.current = null;
|
|
413
|
-
}
|
|
414
|
-
} else {
|
|
415
|
-
if (hoverCloseTimeout.current) clearTimeout(hoverCloseTimeout.current);
|
|
416
|
-
hoverCloseTimeout.current = setTimeout(() => setIsOpen(false), hoverCloseDelay);
|
|
417
|
-
}
|
|
418
|
-
};
|
|
419
|
-
document.addEventListener("mousemove", handleMouseMove);
|
|
420
|
-
return () => {
|
|
421
|
-
document.removeEventListener("mousemove", handleMouseMove);
|
|
422
|
-
if (hoverCloseTimeout.current) {
|
|
423
|
-
clearTimeout(hoverCloseTimeout.current);
|
|
424
|
-
}
|
|
425
|
-
};
|
|
426
|
-
}, [isOpen, props.isFloatingHover, refs.reference, refs.floating, hoverOffset, hoverCloseDelay, props.isDisabled]);
|
|
427
|
-
useLayoutEffect(() => {
|
|
428
|
-
if (!props.isWidthAsContent || !refs.reference.current) return;
|
|
429
|
-
const rect = refs.reference.current.getBoundingClientRect();
|
|
430
|
-
setMinWidth(rect.width);
|
|
431
|
-
}, [props.isWidthAsContent, refs.reference]);
|
|
432
|
-
const open = useCallback(() => {
|
|
433
|
-
if (props.isDisabled) return;
|
|
434
|
-
setIsOpen(true);
|
|
435
|
-
}, [props.isDisabled]);
|
|
436
|
-
const close = useCallback(() => {
|
|
437
|
-
if (props.isDisabled) return;
|
|
438
|
-
setIsOpen(false);
|
|
439
|
-
}, [props.isDisabled]);
|
|
440
|
-
const toggle = useCallback(() => {
|
|
441
|
-
if (props.isDisabled) return;
|
|
442
|
-
setIsOpen((prev) => !prev);
|
|
443
|
-
}, [props.isDisabled]);
|
|
444
|
-
const combinedStyles = useMemo(() => {
|
|
445
|
-
return {
|
|
446
|
-
...floatingStyles,
|
|
447
|
-
minWidth: props.isWidthAsContent && minWidth ? `${minWidth}px` : void 0,
|
|
448
|
-
maxWidth: props.isWidthAsContent && minWidth ? `${minWidth}px` : void 0
|
|
449
|
-
};
|
|
450
|
-
}, [floatingStyles, props.isWidthAsContent, minWidth]);
|
|
451
|
-
useEffect(() => {
|
|
452
|
-
if (isOpen) {
|
|
453
|
-
onFocus == null ? void 0 : onFocus();
|
|
454
|
-
setWasEverOpen(true);
|
|
455
|
-
}
|
|
456
|
-
}, [isOpen, onFocus]);
|
|
457
|
-
useEffect(() => {
|
|
458
|
-
if (!isOpen && wasEverOpen) {
|
|
459
|
-
onBlur == null ? void 0 : onBlur();
|
|
460
|
-
}
|
|
461
|
-
}, [isOpen, wasEverOpen, onBlur]);
|
|
462
|
-
useEffect(() => {
|
|
463
|
-
if (!isOpen || props.isDisabled) return;
|
|
464
|
-
const handleFocusIn = (e) => {
|
|
465
|
-
const refEl = refs.reference.current;
|
|
466
|
-
const floatingEl = refs.floating.current;
|
|
467
|
-
const otherRefs = props.refsExcludeClickOutside || [];
|
|
468
|
-
const isInside = refEl instanceof HTMLElement && refEl.contains(e.target) || floatingEl instanceof HTMLElement && floatingEl.contains(e.target) || otherRefs.some((ref) => {
|
|
469
|
-
if (ref && "current" in ref && ref.current && ref.current instanceof HTMLElement) {
|
|
470
|
-
return ref.current.contains(e.target);
|
|
471
|
-
}
|
|
472
|
-
return false;
|
|
473
|
-
});
|
|
474
|
-
if (!isInside) {
|
|
475
|
-
setIsOpen(false);
|
|
476
|
-
}
|
|
477
|
-
};
|
|
478
|
-
document.addEventListener("focusin", handleFocusIn);
|
|
479
|
-
return () => {
|
|
480
|
-
document.removeEventListener("focusin", handleFocusIn);
|
|
481
|
-
};
|
|
482
|
-
}, [isOpen, refs.reference, refs.floating, props.refsExcludeClickOutside, props.isDisabled]);
|
|
483
|
-
useEffect(() => {
|
|
484
|
-
if (!refs.reference.current || props.isDisabled || !onBlurReference) return;
|
|
485
|
-
const refEl = refs.reference.current;
|
|
486
|
-
const otherRefs = props.refsExcludeBlur || [];
|
|
487
|
-
const handleBlur = (e) => {
|
|
488
|
-
if (refEl instanceof HTMLElement && !refEl.contains(e.relatedTarget) && !otherRefs.some((ref) => {
|
|
489
|
-
if (ref && "current" in ref && ref.current && ref.current instanceof HTMLElement)
|
|
490
|
-
return ref.current.contains(e.relatedTarget);
|
|
491
|
-
})) {
|
|
492
|
-
onBlurReference();
|
|
493
|
-
}
|
|
494
|
-
};
|
|
495
|
-
if (refEl instanceof HTMLElement) refEl.addEventListener("blur", handleBlur, true);
|
|
496
|
-
return () => {
|
|
497
|
-
if (refEl instanceof HTMLElement) refEl.removeEventListener("blur", handleBlur, true);
|
|
498
|
-
};
|
|
499
|
-
}, [refs.reference, props.isDisabled, onBlurReference, props.refsExcludeBlur]);
|
|
500
|
-
const getIsInside = useCallback(
|
|
501
|
-
(target) => {
|
|
502
|
-
if (!target) return false;
|
|
503
|
-
const refEl = refs.reference.current;
|
|
504
|
-
const floatingEl = refs.floating.current;
|
|
505
|
-
const otherRefs = props.refsExcludeBlur || [];
|
|
506
|
-
return refEl instanceof HTMLElement && refEl.contains(target) || floatingEl instanceof HTMLElement && floatingEl.contains(target) || otherRefs.some((ref) => {
|
|
507
|
-
if (ref && "current" in ref && ref.current && ref.current instanceof HTMLElement) {
|
|
508
|
-
return ref.current.contains(target);
|
|
509
|
-
}
|
|
510
|
-
return false;
|
|
511
|
-
});
|
|
512
|
-
},
|
|
513
|
-
[refs.reference, refs.floating, props.refsExcludeBlur]
|
|
514
|
-
);
|
|
515
|
-
return {
|
|
516
|
-
getIsInside,
|
|
517
|
-
isOpen,
|
|
518
|
-
setIsOpen,
|
|
519
|
-
open,
|
|
520
|
-
close,
|
|
521
|
-
toggle,
|
|
522
|
-
refReference: refs.setReference,
|
|
523
|
-
refFloating: refs.setFloating,
|
|
524
|
-
floatingStyles: combinedStyles,
|
|
525
|
-
placement: actualPlacement
|
|
526
|
-
};
|
|
527
|
-
};
|
|
528
|
-
const addPopoverGenre = css`
|
|
529
|
-
${(props) => css`
|
|
530
|
-
background: ${props.theme.colors.button[props.$genre].background.rest};
|
|
531
|
-
border-color: ${props.theme.colors.button[props.$genre].border.rest};
|
|
532
|
-
color: ${props.theme.colors.button[props.$genre].color.rest};
|
|
533
|
-
/* box-shadow: ${props.theme.effects.button}; */
|
|
534
|
-
`};
|
|
535
|
-
`;
|
|
536
|
-
const addPopoverSize = css`
|
|
537
|
-
${(props) => addPopoverSizeConstructor({
|
|
538
|
-
...KEY_SIZE_DATA[props.$size ?? "medium"]
|
|
539
|
-
})};
|
|
540
|
-
`;
|
|
541
|
-
const addPopoverSizeConstructor = (props) => css`
|
|
542
|
-
display: flex;
|
|
543
|
-
border-radius: ${props.radius}px;
|
|
544
|
-
padding: ${props.padding}px;
|
|
545
|
-
gap: ${props.padding - 2}px;
|
|
546
|
-
`;
|
|
547
|
-
const PopoverWrapper = styled(motion.div)`
|
|
548
|
-
max-width: ${(props) => props.$maxWidth || "100%"};
|
|
549
|
-
max-height: ${(props) => props.$maxHeight || "100%"};
|
|
550
|
-
overflow: auto;
|
|
551
|
-
flex-direction: column;
|
|
552
|
-
${addFont};
|
|
553
|
-
${addPopoverSize};
|
|
554
|
-
${addAlwaysOutline};
|
|
555
|
-
${addSXTypography};
|
|
556
|
-
${addPopoverGenre};
|
|
557
|
-
${addSX};
|
|
558
|
-
`;
|
|
559
|
-
const DEFAULT_POPOVER_OFFSET = 8;
|
|
560
|
-
const DEFAULT_POPOVER_CLOSE_DELAY = 100;
|
|
561
|
-
const TooltipContainer = styled(Stack)`
|
|
562
|
-
display: flex;
|
|
563
|
-
width: fit-content;
|
|
564
|
-
height: fit-content;
|
|
565
|
-
`;
|
|
566
|
-
const addTooltipBoxSize = css`
|
|
567
|
-
${(props) => addTooltipBoxSizeConstructor({
|
|
568
|
-
...KEY_SIZE_DATA[props.size ?? "medium"]
|
|
569
|
-
})};
|
|
570
|
-
`;
|
|
571
|
-
const addTooltipBoxSizeConstructor = (props) => css`
|
|
572
|
-
gap: 0px;
|
|
573
|
-
padding: ${props.padding}px ${props.padding}px 0px ${props.padding}px;
|
|
574
|
-
:after {
|
|
575
|
-
content: '';
|
|
576
|
-
display: block;
|
|
577
|
-
height: ${props.padding}px;
|
|
578
|
-
width: 100%;
|
|
579
|
-
}
|
|
580
|
-
`;
|
|
581
|
-
const TooltipBox = styled(Popover)`
|
|
582
|
-
${addTooltipBoxSize};
|
|
583
|
-
`;
|
|
584
|
-
const Tooltip = memo((props) => {
|
|
585
|
-
if (props.isDisabled) return /* @__PURE__ */ jsxRuntimeExports.jsx(TooltipContainer, { sx: props.sx, children: props.children });
|
|
586
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(TooltipContent, { ...props });
|
|
587
|
-
});
|
|
588
|
-
const TooltipContent = (props) => {
|
|
589
|
-
const { isOpen, refReference, refFloating, floatingStyles } = usePopover({
|
|
590
|
-
placement: props.placement ?? DEFAULT_TOOLTIP_PLACEMENT_FALLBACK,
|
|
591
|
-
offset: props.offset ?? DEFAULT_TOOLTIP_OFFSET_FALLBACK,
|
|
592
|
-
mode: props.mode ?? "hover",
|
|
593
|
-
isClickOutside: props.isClickOutside ?? true,
|
|
594
|
-
isFloatingHover: props.isFloatingHover ?? true,
|
|
595
|
-
isWidthAsContent: props.isWidthAsContent ?? false,
|
|
596
|
-
hoverCloseDelay: props.hoverCloseDelay ?? void 0,
|
|
597
|
-
hoverOffset: props.hoverOffset ?? void 0
|
|
598
|
-
});
|
|
599
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
600
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(TooltipContainer, { sx: props.sx, ref: refReference, children: props.children }),
|
|
601
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
602
|
-
TooltipBox,
|
|
603
|
-
{
|
|
604
|
-
size: props.size,
|
|
605
|
-
isOpen,
|
|
606
|
-
genre: props.genre,
|
|
607
|
-
floatingStyles,
|
|
608
|
-
ref: refFloating,
|
|
609
|
-
maxHeight: props.maxHeight,
|
|
610
|
-
maxWidth: props.maxWidth,
|
|
611
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
612
|
-
Typography,
|
|
613
|
-
{
|
|
614
|
-
sx: props.sxTypography ?? {
|
|
615
|
-
default: {
|
|
616
|
-
size: 14
|
|
617
|
-
}
|
|
618
|
-
},
|
|
619
|
-
children: props.content
|
|
620
|
-
}
|
|
621
|
-
)
|
|
622
|
-
}
|
|
623
|
-
)
|
|
624
|
-
] });
|
|
625
|
-
};
|
|
626
|
-
Tooltip.displayName = "Tooltip";
|
|
627
|
-
const DEFAULT_TOOLTIP_PLACEMENT_FALLBACK = "bottom-start";
|
|
628
|
-
const DEFAULT_TOOLTIP_OFFSET_FALLBACK = 8;
|
|
629
|
-
const TypographyWithRef = (props) => {
|
|
630
|
-
const { screenActual } = useScreenWidth();
|
|
631
|
-
const cssProps = useMemo(
|
|
632
|
-
() => ({
|
|
633
|
-
$sxTypography: props.sx,
|
|
634
|
-
style: props.style,
|
|
635
|
-
className: props.className,
|
|
636
|
-
$sx: props.sxStandard,
|
|
637
|
-
$isDisabledOutline: props.isDisabledOutline,
|
|
638
|
-
$isOutlineBoxShadow: props.isOutlineBoxShadow,
|
|
639
|
-
$isReadOnly: props.isReadOnly,
|
|
640
|
-
onClick: props.onClick ? props.onClick : () => {
|
|
641
|
-
}
|
|
642
|
-
}),
|
|
643
|
-
[
|
|
644
|
-
props.sx,
|
|
645
|
-
props.style,
|
|
646
|
-
props.className,
|
|
647
|
-
props.sxStandard,
|
|
648
|
-
props.onClick,
|
|
649
|
-
props.isDisabledOutline,
|
|
650
|
-
props.isOutlineBoxShadow,
|
|
651
|
-
props.isReadOnly
|
|
652
|
-
]
|
|
653
|
-
);
|
|
654
|
-
const screenSX = useMemo(() => {
|
|
655
|
-
var _a, _b;
|
|
656
|
-
return ((_a = props.sx) == null ? void 0 : _a[screenActual]) ?? ((_b = props.sx) == null ? void 0 : _b.default);
|
|
657
|
-
}, [props.sx, screenActual]);
|
|
658
|
-
if (screenSX && "variant" in screenSX) {
|
|
659
|
-
if (screenSX.variant === "h7" || screenSX.variant === "h8" || screenSX.variant === "h9") {
|
|
660
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
661
|
-
Title,
|
|
662
|
-
{
|
|
663
|
-
ref: props.ref,
|
|
664
|
-
as: props.isAnchor ? "a" : props.isParagraph ? "p" : props.isSpan ? "span" : "span",
|
|
665
|
-
href: props.href,
|
|
666
|
-
...cssProps,
|
|
667
|
-
children: props.children
|
|
668
|
-
}
|
|
669
|
-
);
|
|
670
|
-
} else {
|
|
671
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
672
|
-
Title,
|
|
673
|
-
{
|
|
674
|
-
ref: props.ref,
|
|
675
|
-
as: props.isAnchor ? "a" : props.isParagraph ? "p" : props.isSpan ? "span" : screenSX.variant,
|
|
676
|
-
href: props.href,
|
|
677
|
-
...cssProps,
|
|
678
|
-
children: props.children
|
|
679
|
-
}
|
|
680
|
-
);
|
|
681
|
-
}
|
|
682
|
-
}
|
|
683
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
684
|
-
Title,
|
|
685
|
-
{
|
|
686
|
-
ref: props.ref,
|
|
687
|
-
as: props.isAnchor ? "a" : props.isParagraph ? "p" : props.isSpan ? "span" : "span",
|
|
688
|
-
href: props.href,
|
|
689
|
-
...cssProps,
|
|
690
|
-
children: props.children
|
|
691
|
-
}
|
|
692
|
-
);
|
|
693
|
-
};
|
|
694
|
-
const Typography = (props) => {
|
|
695
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(TypographyWithRef, { ...props });
|
|
696
|
-
};
|
|
697
|
-
const TypographySizeIsAnchor = (props) => {
|
|
698
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(TypographyWithRef, { isAnchor: true, ...props, ref: props.ref, href: props.href });
|
|
699
|
-
};
|
|
700
|
-
const TypographyLink = createLink(TypographySizeIsAnchor);
|
|
701
|
-
const TypographyTooltip = memo((props) => {
|
|
702
|
-
const { isDisabled, ref } = useOverflowing({
|
|
703
|
-
isCheckSize: props.tooltip.isDisabled !== void 0 ? !props.tooltip.isDisabled : true,
|
|
704
|
-
dependencies: [props.children]
|
|
705
|
-
});
|
|
706
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(Tooltip, { isDisabled, content: props.children, ...props.tooltip, children: /* @__PURE__ */ jsxRuntimeExports.jsx(TypographyWithRef, { ref, ...props.typography, style: { position: "relative" }, children: props.children }) });
|
|
707
|
-
});
|
|
708
|
-
TypographyTooltip.displayName = "TypographyTooltip";
|
|
709
|
-
TypographyWithRef.displayName = "TypographyWithRef";
|
|
710
|
-
TypographySizeIsAnchor.displayName = "TypographySizeIsAnchor";
|
|
711
|
-
export {
|
|
712
|
-
DEFAULT_TOOLTIP_PLACEMENT_FALLBACK as D,
|
|
713
|
-
Popover as P,
|
|
714
|
-
TooltipContainer as T,
|
|
715
|
-
addTooltipBoxSize as a,
|
|
716
|
-
addTooltipBoxSizeConstructor as b,
|
|
717
|
-
TooltipBox as c,
|
|
718
|
-
Tooltip as d,
|
|
719
|
-
TooltipContent as e,
|
|
720
|
-
DEFAULT_TOOLTIP_OFFSET_FALLBACK as f,
|
|
721
|
-
addSXTypography as g,
|
|
722
|
-
Title as h,
|
|
723
|
-
Typography as i,
|
|
724
|
-
TypographyLink as j,
|
|
725
|
-
TypographyTooltip as k,
|
|
726
|
-
usePopover as u
|
|
727
|
-
};
|
|
728
|
-
//# sourceMappingURL=component-eqTj4VVc.js.map
|