@anoki/fse-ui 1.0.639 → 1.0.640
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/index.cjs10.js +1 -1
- package/dist/index.cjs122.js +1 -1
- package/dist/index.cjs123.js +1 -1
- package/dist/index.cjs124.js +1 -1
- package/dist/index.cjs125.js +1 -1
- package/dist/index.cjs126.js +1 -1
- package/dist/index.cjs127.js +1 -1
- package/dist/index.cjs128.js +1 -1
- package/dist/index.cjs129.js +1 -1
- package/dist/index.cjs130.js +1 -1
- package/dist/index.cjs131.js +1 -1
- package/dist/index.cjs132.js +1 -1
- package/dist/index.cjs133.js +1 -1
- package/dist/index.cjs134.js +1 -1
- package/dist/index.cjs135.js +1 -1
- package/dist/index.cjs136.js +1 -1
- package/dist/index.cjs137.js +1 -1
- package/dist/index.cjs138.js +1 -1
- package/dist/index.cjs139.js +1 -1
- package/dist/index.cjs140.js +1 -1
- package/dist/index.cjs141.js +1 -1
- package/dist/index.cjs142.js +1 -1
- package/dist/index.cjs143.js +1 -1
- package/dist/index.cjs147.js +1 -1
- package/dist/index.cjs148.js +1 -1
- package/dist/index.cjs149.js +1 -1
- package/dist/index.cjs151.js +1 -1
- package/dist/index.cjs152.js +1 -1
- package/dist/index.cjs153.js +1 -1
- package/dist/index.cjs154.js +1 -1
- package/dist/index.cjs155.js +1 -1
- package/dist/index.cjs156.js +1 -1
- package/dist/index.cjs157.js +1 -1
- package/dist/index.cjs158.js +1 -1
- package/dist/index.cjs159.js +1 -1
- package/dist/index.cjs161.js +1 -1
- package/dist/index.cjs162.js +1 -1
- package/dist/index.cjs163.js +1 -1
- package/dist/index.cjs164.js +1 -1
- package/dist/index.cjs165.js +1 -1
- package/dist/index.cjs166.js +1 -1
- package/dist/index.cjs167.js +1 -1
- package/dist/index.cjs169.js +1 -1
- package/dist/index.cjs170.js +1 -1
- package/dist/index.cjs171.js +1 -1
- package/dist/index.cjs172.js +1 -1
- package/dist/index.cjs173.js +1 -1
- package/dist/index.cjs174.js +1 -1
- package/dist/index.cjs175.js +1 -1
- package/dist/index.cjs209.js +1 -1
- package/dist/index.cjs209.js.map +1 -1
- package/dist/index.cjs211.js +2 -0
- package/dist/index.cjs211.js.map +1 -0
- package/dist/index.cjs219.js +1 -1
- package/dist/index.cjs22.js +1 -1
- package/dist/index.cjs225.js +1 -1
- package/dist/index.cjs228.js +1 -1
- package/dist/index.cjs229.js +1 -1
- package/dist/index.cjs236.js +1 -1
- package/dist/index.cjs246.js +1 -1
- package/dist/index.cjs25.js +1 -1
- package/dist/index.cjs251.js +1 -1
- package/dist/index.cjs253.js +1 -1
- package/dist/index.cjs278.js +1 -1
- package/dist/index.cjs279.js +1 -1
- package/dist/index.cjs280.js +1 -1
- package/dist/index.cjs318.js +1 -1
- package/dist/index.cjs355.js +1 -1
- package/dist/index.cjs356.js +1 -1
- package/dist/index.cjs363.js +1 -1
- package/dist/index.cjs363.js.map +1 -1
- package/dist/index.cjs364.js +1 -1
- package/dist/index.cjs364.js.map +1 -1
- package/dist/index.cjs365.js +1 -1
- package/dist/index.cjs365.js.map +1 -1
- package/dist/index.cjs366.js +1 -1
- package/dist/index.cjs366.js.map +1 -1
- package/dist/index.cjs367.js +1 -1
- package/dist/index.cjs367.js.map +1 -1
- package/dist/index.cjs368.js +1 -1
- package/dist/index.cjs368.js.map +1 -1
- package/dist/index.cjs369.js +1 -1
- package/dist/index.cjs369.js.map +1 -1
- package/dist/index.cjs370.js +1 -1
- package/dist/index.cjs370.js.map +1 -1
- package/dist/index.cjs373.js +1 -1
- package/dist/index.cjs373.js.map +1 -1
- package/dist/index.cjs374.js +1 -1
- package/dist/index.cjs374.js.map +1 -1
- package/dist/index.cjs375.js +1 -1
- package/dist/index.cjs375.js.map +1 -1
- package/dist/index.cjs376.js +1 -1
- package/dist/index.cjs376.js.map +1 -1
- package/dist/index.cjs377.js +1 -1
- package/dist/index.cjs377.js.map +1 -1
- package/dist/index.cjs378.js +1 -1
- package/dist/index.cjs378.js.map +1 -1
- package/dist/index.cjs382.js +1 -1
- package/dist/index.cjs382.js.map +1 -1
- package/dist/index.cjs383.js +1 -1
- package/dist/index.cjs383.js.map +1 -1
- package/dist/index.cjs384.js +1 -1
- package/dist/index.cjs384.js.map +1 -1
- package/dist/index.cjs385.js +1 -1
- package/dist/index.cjs385.js.map +1 -1
- package/dist/index.cjs386.js +1 -1
- package/dist/index.cjs386.js.map +1 -1
- package/dist/index.cjs387.js +2 -0
- package/dist/index.cjs387.js.map +1 -0
- package/dist/index.cjs388.js +2 -0
- package/dist/index.cjs388.js.map +1 -0
- package/dist/index.cjs400.js +1 -1
- package/dist/index.cjs400.js.map +1 -1
- package/dist/index.cjs401.js +1 -4
- package/dist/index.cjs401.js.map +1 -1
- package/dist/index.cjs402.js +1 -1
- package/dist/index.cjs402.js.map +1 -1
- package/dist/index.cjs403.js +1 -1
- package/dist/index.cjs403.js.map +1 -1
- package/dist/index.cjs404.js +1 -1
- package/dist/index.cjs404.js.map +1 -1
- package/dist/index.cjs405.js +1 -1
- package/dist/index.cjs405.js.map +1 -1
- package/dist/index.cjs407.js +1 -38
- package/dist/index.cjs407.js.map +1 -1
- package/dist/index.cjs408.js +1 -1
- package/dist/index.cjs408.js.map +1 -1
- package/dist/index.cjs409.js +1 -1
- package/dist/index.cjs409.js.map +1 -1
- package/dist/index.cjs410.js +1 -1
- package/dist/index.cjs410.js.map +1 -1
- package/dist/index.cjs411.js +1 -1
- package/dist/index.cjs411.js.map +1 -1
- package/dist/index.cjs412.js +1 -1
- package/dist/index.cjs412.js.map +1 -1
- package/dist/index.cjs413.js +1 -1
- package/dist/index.cjs413.js.map +1 -1
- package/dist/index.cjs414.js +1 -1
- package/dist/index.cjs414.js.map +1 -1
- package/dist/index.cjs415.js +1 -1
- package/dist/index.cjs415.js.map +1 -1
- package/dist/index.cjs416.js +1 -1
- package/dist/index.cjs416.js.map +1 -1
- package/dist/index.cjs417.js +5 -0
- package/dist/index.cjs417.js.map +1 -0
- package/dist/index.cjs418.js +2 -0
- package/dist/index.cjs418.js.map +1 -0
- package/dist/index.cjs419.js +2 -0
- package/dist/index.cjs419.js.map +1 -0
- package/dist/index.cjs420.js +2 -0
- package/dist/index.cjs420.js.map +1 -0
- package/dist/index.cjs421.js +2 -0
- package/dist/index.cjs421.js.map +1 -0
- package/dist/index.cjs422.js +39 -0
- package/dist/index.cjs422.js.map +1 -0
- package/dist/index.cjs423.js +1 -1
- package/dist/index.cjs423.js.map +1 -1
- package/dist/index.cjs424.js +2 -0
- package/dist/index.cjs424.js.map +1 -0
- package/dist/index.cjs425.js +2 -0
- package/dist/index.cjs425.js.map +1 -0
- package/dist/{index.cjs406.js → index.cjs426.js} +2 -2
- package/dist/{index.cjs406.js.map → index.cjs426.js.map} +1 -1
- package/dist/index.cjs427.js +2 -0
- package/dist/index.cjs427.js.map +1 -0
- package/dist/index.cjs428.js +2 -0
- package/dist/index.cjs428.js.map +1 -0
- package/dist/index.cjs429.js +2 -0
- package/dist/index.cjs429.js.map +1 -0
- package/dist/index.cjs430.js +2 -0
- package/dist/index.cjs430.js.map +1 -0
- package/dist/index.cjs431.js +2 -0
- package/dist/index.cjs431.js.map +1 -0
- package/dist/index.cjs432.js +2 -0
- package/dist/index.cjs432.js.map +1 -0
- package/dist/index.cjs439.js +1 -1
- package/dist/index.cjs442.js +1 -1
- package/dist/index.cjs445.js +1 -1
- package/dist/index.cjs453.js +1 -1
- package/dist/index.cjs453.js.map +1 -1
- package/dist/index.cjs454.js +1 -1
- package/dist/index.cjs454.js.map +1 -1
- package/dist/index.cjs455.js +1 -1
- package/dist/index.cjs455.js.map +1 -1
- package/dist/index.cjs456.js +1 -1
- package/dist/index.cjs456.js.map +1 -1
- package/dist/index.cjs457.js +1 -1
- package/dist/index.cjs457.js.map +1 -1
- package/dist/index.cjs458.js +1 -1
- package/dist/index.cjs458.js.map +1 -1
- package/dist/index.cjs459.js +1 -1
- package/dist/index.cjs459.js.map +1 -1
- package/dist/index.cjs57.js +1 -1
- package/dist/index.cjs6.js +1 -1
- package/dist/index.cjs7.js +1 -1
- package/dist/index.cjs8.js +1 -1
- package/dist/index.cjs9.js +1 -1
- package/dist/index.es10.js +2 -2
- package/dist/index.es122.js +1 -1
- package/dist/index.es123.js +1 -1
- package/dist/index.es124.js +1 -1
- package/dist/index.es125.js +1 -1
- package/dist/index.es126.js +1 -1
- package/dist/index.es127.js +1 -1
- package/dist/index.es128.js +1 -1
- package/dist/index.es129.js +1 -1
- package/dist/index.es130.js +1 -1
- package/dist/index.es131.js +1 -1
- package/dist/index.es132.js +1 -1
- package/dist/index.es133.js +1 -1
- package/dist/index.es134.js +1 -1
- package/dist/index.es135.js +1 -1
- package/dist/index.es136.js +1 -1
- package/dist/index.es137.js +1 -1
- package/dist/index.es138.js +1 -1
- package/dist/index.es139.js +1 -1
- package/dist/index.es140.js +1 -1
- package/dist/index.es141.js +1 -1
- package/dist/index.es142.js +1 -1
- package/dist/index.es143.js +1 -1
- package/dist/index.es147.js +1 -1
- package/dist/index.es148.js +1 -1
- package/dist/index.es149.js +1 -1
- package/dist/index.es151.js +1 -1
- package/dist/index.es152.js +1 -1
- package/dist/index.es153.js +1 -1
- package/dist/index.es154.js +1 -1
- package/dist/index.es155.js +1 -1
- package/dist/index.es156.js +1 -1
- package/dist/index.es157.js +1 -1
- package/dist/index.es158.js +1 -1
- package/dist/index.es159.js +1 -1
- package/dist/index.es161.js +1 -1
- package/dist/index.es162.js +1 -1
- package/dist/index.es163.js +1 -1
- package/dist/index.es164.js +1 -1
- package/dist/index.es165.js +1 -1
- package/dist/index.es166.js +1 -1
- package/dist/index.es167.js +1 -1
- package/dist/index.es169.js +1 -1
- package/dist/index.es170.js +1 -1
- package/dist/index.es171.js +1 -1
- package/dist/index.es172.js +1 -1
- package/dist/index.es173.js +1 -1
- package/dist/index.es174.js +1 -1
- package/dist/index.es175.js +1 -1
- package/dist/index.es209.js +27 -2
- package/dist/index.es209.js.map +1 -1
- package/dist/index.es211.js +5 -0
- package/dist/index.es211.js.map +1 -0
- package/dist/index.es219.js +1 -1
- package/dist/index.es22.js +1 -1
- package/dist/index.es225.js +7 -7
- package/dist/index.es228.js +1 -1
- package/dist/index.es229.js +1 -1
- package/dist/index.es236.js +8 -8
- package/dist/index.es246.js +1 -1
- package/dist/index.es25.js +1 -1
- package/dist/index.es251.js +1 -1
- package/dist/index.es253.js +14 -14
- package/dist/index.es278.js +1 -1
- package/dist/index.es279.js +1 -1
- package/dist/index.es280.js +7 -7
- package/dist/index.es318.js +4 -4
- package/dist/index.es355.js +1 -1
- package/dist/index.es356.js +1 -1
- package/dist/index.es363.js +7 -2
- package/dist/index.es363.js.map +1 -1
- package/dist/index.es364.js +25 -5
- package/dist/index.es364.js.map +1 -1
- package/dist/index.es365.js +64 -23
- package/dist/index.es365.js.map +1 -1
- package/dist/index.es366.js +27 -65
- package/dist/index.es366.js.map +1 -1
- package/dist/index.es367.js +32 -29
- package/dist/index.es367.js.map +1 -1
- package/dist/index.es368.js +620 -31
- package/dist/index.es368.js.map +1 -1
- package/dist/index.es369.js +10 -621
- package/dist/index.es369.js.map +1 -1
- package/dist/index.es370.js +15 -11
- package/dist/index.es370.js.map +1 -1
- package/dist/index.es373.js +5 -52
- package/dist/index.es373.js.map +1 -1
- package/dist/index.es374.js +24 -45
- package/dist/index.es374.js.map +1 -1
- package/dist/index.es375.js +68 -7
- package/dist/index.es375.js.map +1 -1
- package/dist/index.es376.js +2 -125
- package/dist/index.es376.js.map +1 -1
- package/dist/index.es377.js +2 -15
- package/dist/index.es377.js.map +1 -1
- package/dist/index.es378.js +13 -133
- package/dist/index.es378.js.map +1 -1
- package/dist/index.es382.js +114 -167
- package/dist/index.es382.js.map +1 -1
- package/dist/index.es383.js +133 -48
- package/dist/index.es383.js.map +1 -1
- package/dist/index.es384.js +12 -7
- package/dist/index.es384.js.map +1 -1
- package/dist/index.es385.js +15 -4
- package/dist/index.es385.js.map +1 -1
- package/dist/index.es386.js +9 -15
- package/dist/index.es386.js.map +1 -1
- package/dist/index.es387.js +53 -0
- package/dist/index.es387.js.map +1 -0
- package/dist/index.es388.js +56 -0
- package/dist/index.es388.js.map +1 -0
- package/dist/index.es400.js +10 -23
- package/dist/index.es400.js.map +1 -1
- package/dist/index.es401.js +42 -106
- package/dist/index.es401.js.map +1 -1
- package/dist/index.es402.js +7 -15
- package/dist/index.es402.js.map +1 -1
- package/dist/index.es403.js +207 -512
- package/dist/index.es403.js.map +1 -1
- package/dist/index.es404.js +173 -122
- package/dist/index.es404.js.map +1 -1
- package/dist/index.es405.js +4 -129
- package/dist/index.es405.js.map +1 -1
- package/dist/index.es407.js +11 -68
- package/dist/index.es407.js.map +1 -1
- package/dist/index.es408.js +204 -8
- package/dist/index.es408.js.map +1 -1
- package/dist/index.es409.js +22 -14
- package/dist/index.es409.js.map +1 -1
- package/dist/index.es410.js +391 -60
- package/dist/index.es410.js.map +1 -1
- package/dist/index.es411.js +24 -3
- package/dist/index.es411.js.map +1 -1
- package/dist/index.es412.js +29 -23
- package/dist/index.es412.js.map +1 -1
- package/dist/index.es413.js +5 -23
- package/dist/index.es413.js.map +1 -1
- package/dist/index.es414.js +5 -13
- package/dist/index.es414.js.map +1 -1
- package/dist/index.es415.js +3 -28
- package/dist/index.es415.js.map +1 -1
- package/dist/index.es416.js +24 -5
- package/dist/index.es416.js.map +1 -1
- package/dist/index.es417.js +113 -0
- package/dist/index.es417.js.map +1 -0
- package/dist/index.es418.js +19 -0
- package/dist/index.es418.js.map +1 -0
- package/dist/index.es419.js +526 -0
- package/dist/index.es419.js.map +1 -0
- package/dist/index.es420.js +130 -0
- package/dist/index.es420.js.map +1 -0
- package/dist/index.es421.js +132 -0
- package/dist/index.es421.js.map +1 -0
- package/dist/index.es422.js +72 -0
- package/dist/index.es422.js.map +1 -0
- package/dist/index.es423.js +9 -15
- package/dist/index.es423.js.map +1 -1
- package/dist/index.es424.js +17 -0
- package/dist/index.es424.js.map +1 -0
- package/dist/index.es425.js +65 -0
- package/dist/index.es425.js.map +1 -0
- package/dist/{index.es406.js → index.es426.js} +2 -2
- package/dist/{index.es406.js.map → index.es426.js.map} +1 -1
- package/dist/index.es427.js +7 -0
- package/dist/index.es427.js.map +1 -0
- package/dist/index.es428.js +26 -0
- package/dist/index.es428.js.map +1 -0
- package/dist/index.es429.js +26 -0
- package/dist/index.es429.js.map +1 -0
- package/dist/index.es430.js +16 -0
- package/dist/index.es430.js.map +1 -0
- package/dist/index.es431.js +31 -0
- package/dist/index.es431.js.map +1 -0
- package/dist/index.es432.js +8 -0
- package/dist/index.es432.js.map +1 -0
- package/dist/index.es439.js +2 -2
- package/dist/index.es442.js +3 -3
- package/dist/index.es445.js +9 -9
- package/dist/index.es453.js +4 -2
- package/dist/index.es453.js.map +1 -1
- package/dist/index.es454.js +3 -2
- package/dist/index.es454.js.map +1 -1
- package/dist/index.es455.js +2 -3
- package/dist/index.es455.js.map +1 -1
- package/dist/index.es456.js +4 -2
- package/dist/index.es456.js.map +1 -1
- package/dist/index.es457.js +4 -3
- package/dist/index.es457.js.map +1 -1
- package/dist/index.es458.js +3 -4
- package/dist/index.es458.js.map +1 -1
- package/dist/index.es459.js +2 -6
- package/dist/index.es459.js.map +1 -1
- package/dist/index.es57.js +1 -1
- package/dist/index.es6.js +1 -1
- package/dist/index.es7.js +1 -1
- package/dist/index.es8.js +1 -1
- package/dist/index.es9.js +2 -2
- package/dist/styles/index.css +1 -1
- package/dist/styles/typography.css +1 -1
- package/package.json +1 -1
- package/dist/index.cjs210.js +0 -2
- package/dist/index.cjs210.js.map +0 -1
- package/dist/index.cjs362.js +0 -2
- package/dist/index.cjs362.js.map +0 -1
- package/dist/index.cjs372.js +0 -2
- package/dist/index.cjs372.js.map +0 -1
- package/dist/index.cjs379.js +0 -2
- package/dist/index.cjs379.js.map +0 -1
- package/dist/index.cjs380.js +0 -2
- package/dist/index.cjs380.js.map +0 -1
- package/dist/index.cjs381.js +0 -2
- package/dist/index.cjs381.js.map +0 -1
- package/dist/index.cjs389.js +0 -2
- package/dist/index.cjs389.js.map +0 -1
- package/dist/index.cjs390.js +0 -2
- package/dist/index.cjs390.js.map +0 -1
- package/dist/index.cjs391.js +0 -2
- package/dist/index.cjs391.js.map +0 -1
- package/dist/index.cjs392.js +0 -2
- package/dist/index.cjs392.js.map +0 -1
- package/dist/index.cjs393.js +0 -2
- package/dist/index.cjs393.js.map +0 -1
- package/dist/index.cjs394.js +0 -2
- package/dist/index.cjs394.js.map +0 -1
- package/dist/index.cjs395.js +0 -2
- package/dist/index.cjs395.js.map +0 -1
- package/dist/index.cjs396.js +0 -2
- package/dist/index.cjs396.js.map +0 -1
- package/dist/index.cjs397.js +0 -2
- package/dist/index.cjs397.js.map +0 -1
- package/dist/index.cjs398.js +0 -2
- package/dist/index.cjs398.js.map +0 -1
- package/dist/index.cjs399.js +0 -2
- package/dist/index.cjs399.js.map +0 -1
- package/dist/index.es210.js +0 -30
- package/dist/index.es210.js.map +0 -1
- package/dist/index.es362.js +0 -5
- package/dist/index.es362.js.map +0 -1
- package/dist/index.es372.js +0 -14
- package/dist/index.es372.js.map +0 -1
- package/dist/index.es379.js +0 -221
- package/dist/index.es379.js.map +0 -1
- package/dist/index.es380.js +0 -17
- package/dist/index.es380.js.map +0 -1
- package/dist/index.es381.js +0 -72
- package/dist/index.es381.js.map +0 -1
- package/dist/index.es389.js +0 -15
- package/dist/index.es389.js.map +0 -1
- package/dist/index.es390.js +0 -208
- package/dist/index.es390.js.map +0 -1
- package/dist/index.es391.js +0 -25
- package/dist/index.es391.js.map +0 -1
- package/dist/index.es392.js +0 -28
- package/dist/index.es392.js.map +0 -1
- package/dist/index.es393.js +0 -396
- package/dist/index.es393.js.map +0 -1
- package/dist/index.es394.js +0 -9
- package/dist/index.es394.js.map +0 -1
- package/dist/index.es395.js +0 -28
- package/dist/index.es395.js.map +0 -1
- package/dist/index.es396.js +0 -32
- package/dist/index.es396.js.map +0 -1
- package/dist/index.es397.js +0 -8
- package/dist/index.es397.js.map +0 -1
- package/dist/index.es398.js +0 -8
- package/dist/index.es398.js.map +0 -1
- package/dist/index.es399.js +0 -6
- package/dist/index.es399.js.map +0 -1
package/dist/index.es384.js
CHANGED
@@ -1,12 +1,17 @@
|
|
1
|
-
import { __assign as m } from "./index.es395.js";
|
2
1
|
import * as r from "react";
|
3
|
-
import
|
4
|
-
import
|
5
|
-
|
6
|
-
|
2
|
+
import f from "react-dom";
|
3
|
+
import { Primitive as u } from "./index.es367.js";
|
4
|
+
import { useLayoutEffect as c } from "./index.es405.js";
|
5
|
+
import { j as l } from "./index.es196.js";
|
6
|
+
var p = "Portal", d = r.forwardRef((e, a) => {
|
7
|
+
var o;
|
8
|
+
const { container: s, ...i } = e, [m, n] = r.useState(!1);
|
9
|
+
c(() => n(!0), []);
|
10
|
+
const t = s || m && ((o = globalThis == null ? void 0 : globalThis.document) == null ? void 0 : o.body);
|
11
|
+
return t ? f.createPortal(/* @__PURE__ */ l.jsx(u.div, { ...i, ref: a }), t) : null;
|
7
12
|
});
|
8
|
-
|
13
|
+
d.displayName = p;
|
9
14
|
export {
|
10
|
-
|
15
|
+
d as Portal
|
11
16
|
};
|
12
17
|
//# sourceMappingURL=index.es384.js.map
|
package/dist/index.es384.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.es384.js","sources":["../node_modules/react-
|
1
|
+
{"version":3,"file":"index.es384.js","sources":["../node_modules/@radix-ui/react-portal/dist/index.mjs"],"sourcesContent":["\"use client\";\n\n// packages/react/portal/src/portal.tsx\nimport * as React from \"react\";\nimport ReactDOM from \"react-dom\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useLayoutEffect } from \"@radix-ui/react-use-layout-effect\";\nimport { jsx } from \"react/jsx-runtime\";\nvar PORTAL_NAME = \"Portal\";\nvar Portal = React.forwardRef((props, forwardedRef) => {\n const { container: containerProp, ...portalProps } = props;\n const [mounted, setMounted] = React.useState(false);\n useLayoutEffect(() => setMounted(true), []);\n const container = containerProp || mounted && globalThis?.document?.body;\n return container ? ReactDOM.createPortal(/* @__PURE__ */ jsx(Primitive.div, { ...portalProps, ref: forwardedRef }), container) : null;\n});\nPortal.displayName = PORTAL_NAME;\nvar Root = Portal;\nexport {\n Portal,\n Root\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":["PORTAL_NAME","Portal","React","props","forwardedRef","containerProp","portalProps","mounted","setMounted","useLayoutEffect","container","_a","ReactDOM","jsx","Primitive"],"mappings":";;;;;AAQA,IAAIA,IAAc,UACdC,IAASC,EAAM,WAAW,CAACC,GAAOC,MAAiB;;AACrD,QAAM,EAAE,WAAWC,GAAe,GAAGC,EAAa,IAAGH,GAC/C,CAACI,GAASC,CAAU,IAAIN,EAAM,SAAS,EAAK;AAClDO,EAAAA,EAAgB,MAAMD,EAAW,EAAI,GAAG,CAAA,CAAE;AAC1C,QAAME,IAAYL,KAAiBE,OAAWI,IAAA,yCAAY,aAAZ,gBAAAA,EAAsB;AACpE,SAAOD,IAAYE,EAAS,aAA6BC,gBAAAA,EAAG,IAACC,EAAU,KAAK,EAAE,GAAGR,GAAa,KAAKF,EAAc,CAAA,GAAGM,CAAS,IAAI;AACnI,CAAC;AACDT,EAAO,cAAcD;","x_google_ignoreList":[0]}
|
package/dist/index.es385.js
CHANGED
@@ -1,7 +1,18 @@
|
|
1
|
-
import * as
|
2
|
-
var
|
3
|
-
|
1
|
+
import * as r from "react";
|
2
|
+
var t = 0;
|
3
|
+
function a() {
|
4
|
+
r.useEffect(() => {
|
5
|
+
const e = document.querySelectorAll("[data-radix-focus-guard]");
|
6
|
+
return document.body.insertAdjacentElement("afterbegin", e[0] ?? n()), document.body.insertAdjacentElement("beforeend", e[1] ?? n()), t++, () => {
|
7
|
+
t === 1 && document.querySelectorAll("[data-radix-focus-guard]").forEach((o) => o.remove()), t--;
|
8
|
+
};
|
9
|
+
}, []);
|
10
|
+
}
|
11
|
+
function n() {
|
12
|
+
const e = document.createElement("span");
|
13
|
+
return e.setAttribute("data-radix-focus-guard", ""), e.tabIndex = 0, e.style.outline = "none", e.style.opacity = "0", e.style.position = "fixed", e.style.pointerEvents = "none", e;
|
14
|
+
}
|
4
15
|
export {
|
5
|
-
|
16
|
+
a as useFocusGuards
|
6
17
|
};
|
7
18
|
//# sourceMappingURL=index.es385.js.map
|
package/dist/index.es385.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.es385.js","sources":["../node_modules/@radix-ui/react-
|
1
|
+
{"version":3,"file":"index.es385.js","sources":["../node_modules/@radix-ui/react-focus-guards/dist/index.mjs"],"sourcesContent":["\"use client\";\n\n// packages/react/focus-guards/src/focus-guards.tsx\nimport * as React from \"react\";\nvar count = 0;\nfunction FocusGuards(props) {\n useFocusGuards();\n return props.children;\n}\nfunction useFocusGuards() {\n React.useEffect(() => {\n const edgeGuards = document.querySelectorAll(\"[data-radix-focus-guard]\");\n document.body.insertAdjacentElement(\"afterbegin\", edgeGuards[0] ?? createFocusGuard());\n document.body.insertAdjacentElement(\"beforeend\", edgeGuards[1] ?? createFocusGuard());\n count++;\n return () => {\n if (count === 1) {\n document.querySelectorAll(\"[data-radix-focus-guard]\").forEach((node) => node.remove());\n }\n count--;\n };\n }, []);\n}\nfunction createFocusGuard() {\n const element = document.createElement(\"span\");\n element.setAttribute(\"data-radix-focus-guard\", \"\");\n element.tabIndex = 0;\n element.style.outline = \"none\";\n element.style.opacity = \"0\";\n element.style.position = \"fixed\";\n element.style.pointerEvents = \"none\";\n return element;\n}\nvar Root = FocusGuards;\nexport {\n FocusGuards,\n Root,\n useFocusGuards\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":["count","useFocusGuards","React","edgeGuards","createFocusGuard","node","element"],"mappings":";AAIA,IAAIA,IAAQ;AAKZ,SAASC,IAAiB;AACxB,EAAAC,EAAM,UAAU,MAAM;AACpB,UAAMC,IAAa,SAAS,iBAAiB,0BAA0B;AACvE,oBAAS,KAAK,sBAAsB,cAAcA,EAAW,CAAC,KAAKC,GAAkB,GACrF,SAAS,KAAK,sBAAsB,aAAaD,EAAW,CAAC,KAAKC,GAAkB,GACpFJ,KACO,MAAM;AACX,MAAIA,MAAU,KACZ,SAAS,iBAAiB,0BAA0B,EAAE,QAAQ,CAACK,MAASA,EAAK,QAAQ,GAEvFL;AAAA,IACD;AAAA,EACF,GAAE,EAAE;AACP;AACA,SAASI,IAAmB;AAC1B,QAAME,IAAU,SAAS,cAAc,MAAM;AAC7C,SAAAA,EAAQ,aAAa,0BAA0B,EAAE,GACjDA,EAAQ,WAAW,GACnBA,EAAQ,MAAM,UAAU,QACxBA,EAAQ,MAAM,UAAU,KACxBA,EAAQ,MAAM,WAAW,SACzBA,EAAQ,MAAM,gBAAgB,QACvBA;AACT;","x_google_ignoreList":[0]}
|
package/dist/index.es386.js
CHANGED
@@ -1,18 +1,12 @@
|
|
1
|
-
import {
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
}, u = document.activeElement;
|
10
|
-
return c.focus(), document.addEventListener("keydown", s), () => {
|
11
|
-
document.removeEventListener("keydown", s), n && (u == null || u.focus());
|
12
|
-
};
|
13
|
-
}, [n, t]);
|
14
|
-
};
|
1
|
+
import { __assign as m } from "./index.es411.js";
|
2
|
+
import * as r from "react";
|
3
|
+
import { RemoveScroll as e } from "./index.es412.js";
|
4
|
+
import t from "./index.es413.js";
|
5
|
+
var s = r.forwardRef(function(a, o) {
|
6
|
+
return r.createElement(e, m({}, a, { ref: o, sideCar: t }));
|
7
|
+
});
|
8
|
+
s.classNames = e.classNames;
|
15
9
|
export {
|
16
|
-
|
10
|
+
s as default
|
17
11
|
};
|
18
12
|
//# sourceMappingURL=index.es386.js.map
|
package/dist/index.es386.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.es386.js","sources":["../
|
1
|
+
{"version":3,"file":"index.es386.js","sources":["../node_modules/react-remove-scroll/dist/es2015/Combination.js"],"sourcesContent":["import { __assign } from \"tslib\";\nimport * as React from 'react';\nimport { RemoveScroll } from './UI';\nimport SideCar from './sidecar';\nvar ReactRemoveScroll = React.forwardRef(function (props, ref) { return (React.createElement(RemoveScroll, __assign({}, props, { ref: ref, sideCar: SideCar }))); });\nReactRemoveScroll.classNames = RemoveScroll.classNames;\nexport default ReactRemoveScroll;\n"],"names":["ReactRemoveScroll","React","props","ref","RemoveScroll","__assign","SideCar"],"mappings":";;;;AAIG,IAACA,IAAoBC,EAAM,WAAW,SAAUC,GAAOC,GAAK;AAAE,SAAQF,EAAM,cAAcG,GAAcC,EAAS,CAAE,GAAEH,GAAO,EAAE,KAAKC,GAAK,SAASG,GAAS,CAAC;AAAK,CAAA;AACnKN,EAAkB,aAAaI,EAAa;","x_google_ignoreList":[0]}
|
@@ -0,0 +1,53 @@
|
|
1
|
+
var S = function(r) {
|
2
|
+
if (typeof document > "u")
|
3
|
+
return null;
|
4
|
+
var u = Array.isArray(r) ? r[0] : r;
|
5
|
+
return u.ownerDocument.body;
|
6
|
+
}, f = /* @__PURE__ */ new WeakMap(), v = /* @__PURE__ */ new WeakMap(), p = {}, h = 0, W = function(r) {
|
7
|
+
return r && (r.host || W(r.parentNode));
|
8
|
+
}, D = function(r, u) {
|
9
|
+
return u.map(function(e) {
|
10
|
+
if (r.contains(e))
|
11
|
+
return e;
|
12
|
+
var n = W(e);
|
13
|
+
return n && r.contains(n) ? n : (console.error("aria-hidden", e, "in not contained inside", r, ". Doing nothing"), null);
|
14
|
+
}).filter(function(e) {
|
15
|
+
return !!e;
|
16
|
+
});
|
17
|
+
}, E = function(r, u, e, n) {
|
18
|
+
var i = D(u, Array.isArray(r) ? r : [r]);
|
19
|
+
p[e] || (p[e] = /* @__PURE__ */ new WeakMap());
|
20
|
+
var o = p[e], l = [], s = /* @__PURE__ */ new Set(), b = new Set(i), y = function(t) {
|
21
|
+
!t || s.has(t) || (s.add(t), y(t.parentNode));
|
22
|
+
};
|
23
|
+
i.forEach(y);
|
24
|
+
var A = function(t) {
|
25
|
+
!t || b.has(t) || Array.prototype.forEach.call(t.children, function(a) {
|
26
|
+
if (s.has(a))
|
27
|
+
A(a);
|
28
|
+
else
|
29
|
+
try {
|
30
|
+
var c = a.getAttribute(n), w = c !== null && c !== "false", d = (f.get(a) || 0) + 1, M = (o.get(a) || 0) + 1;
|
31
|
+
f.set(a, d), o.set(a, M), l.push(a), d === 1 && w && v.set(a, !0), M === 1 && a.setAttribute(e, "true"), w || a.setAttribute(n, "true");
|
32
|
+
} catch (k) {
|
33
|
+
console.error("aria-hidden: cannot operate on ", a, k);
|
34
|
+
}
|
35
|
+
});
|
36
|
+
};
|
37
|
+
return A(u), s.clear(), h++, function() {
|
38
|
+
l.forEach(function(t) {
|
39
|
+
var a = f.get(t) - 1, c = o.get(t) - 1;
|
40
|
+
f.set(t, a), o.set(t, c), a || (v.has(t) || t.removeAttribute(n), v.delete(t)), c || t.removeAttribute(e);
|
41
|
+
}), h--, h || (f = /* @__PURE__ */ new WeakMap(), f = /* @__PURE__ */ new WeakMap(), v = /* @__PURE__ */ new WeakMap(), p = {});
|
42
|
+
};
|
43
|
+
}, C = function(r, u, e) {
|
44
|
+
e === void 0 && (e = "data-aria-hidden");
|
45
|
+
var n = Array.from(Array.isArray(r) ? r : [r]), i = S(r);
|
46
|
+
return i ? (n.push.apply(n, Array.from(i.querySelectorAll("[aria-live]"))), E(n, i, e, "aria-hidden")) : function() {
|
47
|
+
return null;
|
48
|
+
};
|
49
|
+
};
|
50
|
+
export {
|
51
|
+
C as hideOthers
|
52
|
+
};
|
53
|
+
//# sourceMappingURL=index.es387.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.es387.js","sources":["../node_modules/aria-hidden/dist/es2015/index.js"],"sourcesContent":["var getDefaultParent = function (originalTarget) {\n if (typeof document === 'undefined') {\n return null;\n }\n var sampleTarget = Array.isArray(originalTarget) ? originalTarget[0] : originalTarget;\n return sampleTarget.ownerDocument.body;\n};\nvar counterMap = new WeakMap();\nvar uncontrolledNodes = new WeakMap();\nvar markerMap = {};\nvar lockCount = 0;\nvar unwrapHost = function (node) {\n return node && (node.host || unwrapHost(node.parentNode));\n};\nvar correctTargets = function (parent, targets) {\n return targets\n .map(function (target) {\n if (parent.contains(target)) {\n return target;\n }\n var correctedTarget = unwrapHost(target);\n if (correctedTarget && parent.contains(correctedTarget)) {\n return correctedTarget;\n }\n console.error('aria-hidden', target, 'in not contained inside', parent, '. Doing nothing');\n return null;\n })\n .filter(function (x) { return Boolean(x); });\n};\n/**\n * Marks everything except given node(or nodes) as aria-hidden\n * @param {Element | Element[]} originalTarget - elements to keep on the page\n * @param [parentNode] - top element, defaults to document.body\n * @param {String} [markerName] - a special attribute to mark every node\n * @param {String} [controlAttribute] - html Attribute to control\n * @return {Undo} undo command\n */\nvar applyAttributeToOthers = function (originalTarget, parentNode, markerName, controlAttribute) {\n var targets = correctTargets(parentNode, Array.isArray(originalTarget) ? originalTarget : [originalTarget]);\n if (!markerMap[markerName]) {\n markerMap[markerName] = new WeakMap();\n }\n var markerCounter = markerMap[markerName];\n var hiddenNodes = [];\n var elementsToKeep = new Set();\n var elementsToStop = new Set(targets);\n var keep = function (el) {\n if (!el || elementsToKeep.has(el)) {\n return;\n }\n elementsToKeep.add(el);\n keep(el.parentNode);\n };\n targets.forEach(keep);\n var deep = function (parent) {\n if (!parent || elementsToStop.has(parent)) {\n return;\n }\n Array.prototype.forEach.call(parent.children, function (node) {\n if (elementsToKeep.has(node)) {\n deep(node);\n }\n else {\n try {\n var attr = node.getAttribute(controlAttribute);\n var alreadyHidden = attr !== null && attr !== 'false';\n var counterValue = (counterMap.get(node) || 0) + 1;\n var markerValue = (markerCounter.get(node) || 0) + 1;\n counterMap.set(node, counterValue);\n markerCounter.set(node, markerValue);\n hiddenNodes.push(node);\n if (counterValue === 1 && alreadyHidden) {\n uncontrolledNodes.set(node, true);\n }\n if (markerValue === 1) {\n node.setAttribute(markerName, 'true');\n }\n if (!alreadyHidden) {\n node.setAttribute(controlAttribute, 'true');\n }\n }\n catch (e) {\n console.error('aria-hidden: cannot operate on ', node, e);\n }\n }\n });\n };\n deep(parentNode);\n elementsToKeep.clear();\n lockCount++;\n return function () {\n hiddenNodes.forEach(function (node) {\n var counterValue = counterMap.get(node) - 1;\n var markerValue = markerCounter.get(node) - 1;\n counterMap.set(node, counterValue);\n markerCounter.set(node, markerValue);\n if (!counterValue) {\n if (!uncontrolledNodes.has(node)) {\n node.removeAttribute(controlAttribute);\n }\n uncontrolledNodes.delete(node);\n }\n if (!markerValue) {\n node.removeAttribute(markerName);\n }\n });\n lockCount--;\n if (!lockCount) {\n // clear\n counterMap = new WeakMap();\n counterMap = new WeakMap();\n uncontrolledNodes = new WeakMap();\n markerMap = {};\n }\n };\n};\n/**\n * Marks everything except given node(or nodes) as aria-hidden\n * @param {Element | Element[]} originalTarget - elements to keep on the page\n * @param [parentNode] - top element, defaults to document.body\n * @param {String} [markerName] - a special attribute to mark every node\n * @return {Undo} undo command\n */\nexport var hideOthers = function (originalTarget, parentNode, markerName) {\n if (markerName === void 0) { markerName = 'data-aria-hidden'; }\n var targets = Array.from(Array.isArray(originalTarget) ? originalTarget : [originalTarget]);\n var activeParentNode = parentNode || getDefaultParent(originalTarget);\n if (!activeParentNode) {\n return function () { return null; };\n }\n // we should not hide ariaLive elements - https://github.com/theKashey/aria-hidden/issues/10\n targets.push.apply(targets, Array.from(activeParentNode.querySelectorAll('[aria-live]')));\n return applyAttributeToOthers(targets, activeParentNode, markerName, 'aria-hidden');\n};\n/**\n * Marks everything except given node(or nodes) as inert\n * @param {Element | Element[]} originalTarget - elements to keep on the page\n * @param [parentNode] - top element, defaults to document.body\n * @param {String} [markerName] - a special attribute to mark every node\n * @return {Undo} undo command\n */\nexport var inertOthers = function (originalTarget, parentNode, markerName) {\n if (markerName === void 0) { markerName = 'data-inert-ed'; }\n var activeParentNode = parentNode || getDefaultParent(originalTarget);\n if (!activeParentNode) {\n return function () { return null; };\n }\n return applyAttributeToOthers(originalTarget, activeParentNode, markerName, 'inert');\n};\n/**\n * @returns if current browser supports inert\n */\nexport var supportsInert = function () {\n return typeof HTMLElement !== 'undefined' && HTMLElement.prototype.hasOwnProperty('inert');\n};\n/**\n * Automatic function to \"suppress\" DOM elements - _hide_ or _inert_ in the best possible way\n * @param {Element | Element[]} originalTarget - elements to keep on the page\n * @param [parentNode] - top element, defaults to document.body\n * @param {String} [markerName] - a special attribute to mark every node\n * @return {Undo} undo command\n */\nexport var suppressOthers = function (originalTarget, parentNode, markerName) {\n if (markerName === void 0) { markerName = 'data-suppressed'; }\n return (supportsInert() ? inertOthers : hideOthers)(originalTarget, parentNode, markerName);\n};\n"],"names":["getDefaultParent","originalTarget","sampleTarget","counterMap","uncontrolledNodes","markerMap","lockCount","unwrapHost","node","correctTargets","parent","targets","target","correctedTarget","x","applyAttributeToOthers","parentNode","markerName","controlAttribute","markerCounter","hiddenNodes","elementsToKeep","elementsToStop","keep","el","deep","attr","alreadyHidden","counterValue","markerValue","e","hideOthers","activeParentNode"],"mappings":"AAAA,IAAIA,IAAmB,SAAUC,GAAgB;AAC7C,MAAI,OAAO,WAAa;AACpB,WAAO;AAEX,MAAIC,IAAe,MAAM,QAAQD,CAAc,IAAIA,EAAe,CAAC,IAAIA;AACvE,SAAOC,EAAa,cAAc;AACtC,GACIC,IAAa,oBAAI,QAAS,GAC1BC,IAAoB,oBAAI,QAAS,GACjCC,IAAY,CAAE,GACdC,IAAY,GACZC,IAAa,SAAUC,GAAM;AAC7B,SAAOA,MAASA,EAAK,QAAQD,EAAWC,EAAK,UAAU;AAC3D,GACIC,IAAiB,SAAUC,GAAQC,GAAS;AAC5C,SAAOA,EACF,IAAI,SAAUC,GAAQ;AACvB,QAAIF,EAAO,SAASE,CAAM;AACtB,aAAOA;AAEX,QAAIC,IAAkBN,EAAWK,CAAM;AACvC,WAAIC,KAAmBH,EAAO,SAASG,CAAe,IAC3CA,KAEX,QAAQ,MAAM,eAAeD,GAAQ,2BAA2BF,GAAQ,iBAAiB,GAClF;AAAA,EACV,CA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N,kBAAQ,MAAM,mCAAmCtB,GAAMsB,CAAC;AAAA,QAC5E;AAAA,IAEA,CAAS;AAAA,EACJ;AACD,SAAAL,EAAKT,CAAU,GACfK,EAAe,MAAO,GACtBf,KACO,WAAY;AACf,IAAAc,EAAY,QAAQ,SAAUZ,GAAM;AAChC,UAAIoB,IAAezB,EAAW,IAAIK,CAAI,IAAI,GACtCqB,IAAcV,EAAc,IAAIX,CAAI,IAAI;AAC5C,MAAAL,EAAW,IAAIK,GAAMoB,CAAY,GACjCT,EAAc,IAAIX,GAAMqB,CAAW,GAC9BD,MACIxB,EAAkB,IAAII,CAAI,KAC3BA,EAAK,gBAAgBU,CAAgB,GAEzCd,EAAkB,OAAOI,CAAI,IAE5BqB,KACDrB,EAAK,gBAAgBS,CAAU;AAAA,IAE/C,CAAS,GACDX,KACKA,MAEDH,IAAa,oBAAI,QAAS,GAC1BA,IAAa,oBAAI,QAAS,GAC1BC,IAAoB,oBAAI,QAAS,GACjCC,IAAY,CAAE;AAAA,EAErB;AACL,GAQW0B,IAAa,SAAU9B,GAAgBe,GAAYC,GAAY;AACtE,EAAIA,MAAe,WAAUA,IAAa;AAC1C,MAAIN,IAAU,MAAM,KAAK,MAAM,QAAQV,CAAc,IAAIA,IAAiB,CAACA,CAAc,CAAC,GACtF+B,IAAiChC,EAAiBC,CAAc;AACpE,SAAK+B,KAILrB,EAAQ,KAAK,MAAMA,GAAS,MAAM,KAAKqB,EAAiB,iBAAiB,aAAa,CAAC,CAAC,GACjFjB,EAAuBJ,GAASqB,GAAkBf,GAAY,aAAa,KAJvE,WAAY;AAAE,WAAO;AAAA,EAAO;AAK3C;","x_google_ignoreList":[0]}
|
@@ -0,0 +1,56 @@
|
|
1
|
+
import * as l from "react";
|
2
|
+
import { composeRefs as y } from "./index.es364.js";
|
3
|
+
import { j as f } from "./index.es196.js";
|
4
|
+
// @__NO_SIDE_EFFECTS__
|
5
|
+
function b(e) {
|
6
|
+
const t = /* @__PURE__ */ S(e), o = l.forwardRef((n, r) => {
|
7
|
+
const { children: i, ...a } = n, s = l.Children.toArray(i), p = s.find(g);
|
8
|
+
if (p) {
|
9
|
+
const c = p.props.children, m = s.map((u) => u === p ? l.Children.count(c) > 1 ? l.Children.only(null) : l.isValidElement(c) ? c.props.children : null : u);
|
10
|
+
return /* @__PURE__ */ f.jsx(t, { ...a, ref: r, children: l.isValidElement(c) ? l.cloneElement(c, void 0, m) : null });
|
11
|
+
}
|
12
|
+
return /* @__PURE__ */ f.jsx(t, { ...a, ref: r, children: i });
|
13
|
+
});
|
14
|
+
return o.displayName = `${e}.Slot`, o;
|
15
|
+
}
|
16
|
+
// @__NO_SIDE_EFFECTS__
|
17
|
+
function S(e) {
|
18
|
+
const t = l.forwardRef((o, n) => {
|
19
|
+
const { children: r, ...i } = o;
|
20
|
+
if (l.isValidElement(r)) {
|
21
|
+
const a = x(r), s = E(i, r.props);
|
22
|
+
return r.type !== l.Fragment && (s.ref = n ? y(n, a) : a), l.cloneElement(r, s);
|
23
|
+
}
|
24
|
+
return l.Children.count(r) > 1 ? l.Children.only(null) : null;
|
25
|
+
});
|
26
|
+
return t.displayName = `${e}.SlotClone`, t;
|
27
|
+
}
|
28
|
+
var d = Symbol("radix.slottable");
|
29
|
+
// @__NO_SIDE_EFFECTS__
|
30
|
+
function h(e) {
|
31
|
+
const t = ({ children: o }) => /* @__PURE__ */ f.jsx(f.Fragment, { children: o });
|
32
|
+
return t.displayName = `${e}.Slottable`, t.__radixId = d, t;
|
33
|
+
}
|
34
|
+
function g(e) {
|
35
|
+
return l.isValidElement(e) && typeof e.type == "function" && "__radixId" in e.type && e.type.__radixId === d;
|
36
|
+
}
|
37
|
+
function E(e, t) {
|
38
|
+
const o = { ...t };
|
39
|
+
for (const n in t) {
|
40
|
+
const r = e[n], i = t[n];
|
41
|
+
/^on[A-Z]/.test(n) ? r && i ? o[n] = (...s) => {
|
42
|
+
i(...s), r(...s);
|
43
|
+
} : r && (o[n] = r) : n === "style" ? o[n] = { ...r, ...i } : n === "className" && (o[n] = [r, i].filter(Boolean).join(" "));
|
44
|
+
}
|
45
|
+
return { ...e, ...o };
|
46
|
+
}
|
47
|
+
function x(e) {
|
48
|
+
var n, r;
|
49
|
+
let t = (n = Object.getOwnPropertyDescriptor(e.props, "ref")) == null ? void 0 : n.get, o = t && "isReactWarning" in t && t.isReactWarning;
|
50
|
+
return o ? e.ref : (t = (r = Object.getOwnPropertyDescriptor(e, "ref")) == null ? void 0 : r.get, o = t && "isReactWarning" in t && t.isReactWarning, o ? e.props.ref : e.props.ref || e.ref);
|
51
|
+
}
|
52
|
+
export {
|
53
|
+
b as createSlot,
|
54
|
+
h as createSlottable
|
55
|
+
};
|
56
|
+
//# sourceMappingURL=index.es388.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"file":"index.es388.js","sources":["../node_modules/@radix-ui/react-slot/dist/index.mjs"],"sourcesContent":["// packages/react/slot/src/slot.tsx\nimport * as React from \"react\";\nimport { composeRefs } from \"@radix-ui/react-compose-refs\";\nimport { Fragment as Fragment2, jsx } from \"react/jsx-runtime\";\n// @__NO_SIDE_EFFECTS__\nfunction createSlot(ownerName) {\n const SlotClone = /* @__PURE__ */ createSlotClone(ownerName);\n const Slot2 = React.forwardRef((props, forwardedRef) => {\n const { children, ...slotProps } = props;\n const childrenArray = React.Children.toArray(children);\n const slottable = childrenArray.find(isSlottable);\n if (slottable) {\n const newElement = slottable.props.children;\n const newChildren = childrenArray.map((child) => {\n if (child === slottable) {\n if (React.Children.count(newElement) > 1) return React.Children.only(null);\n return React.isValidElement(newElement) ? newElement.props.children : null;\n } else {\n return child;\n }\n });\n return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children: React.isValidElement(newElement) ? React.cloneElement(newElement, void 0, newChildren) : null });\n }\n return /* @__PURE__ */ jsx(SlotClone, { ...slotProps, ref: forwardedRef, children });\n });\n Slot2.displayName = `${ownerName}.Slot`;\n return Slot2;\n}\nvar Slot = /* @__PURE__ */ createSlot(\"Slot\");\n// @__NO_SIDE_EFFECTS__\nfunction createSlotClone(ownerName) {\n const SlotClone = React.forwardRef((props, forwardedRef) => {\n const { children, ...slotProps } = props;\n if (React.isValidElement(children)) {\n const childrenRef = getElementRef(children);\n const props2 = mergeProps(slotProps, children.props);\n if (children.type !== React.Fragment) {\n props2.ref = forwardedRef ? composeRefs(forwardedRef, childrenRef) : childrenRef;\n }\n return React.cloneElement(children, props2);\n }\n return React.Children.count(children) > 1 ? React.Children.only(null) : null;\n });\n SlotClone.displayName = `${ownerName}.SlotClone`;\n return SlotClone;\n}\nvar SLOTTABLE_IDENTIFIER = Symbol(\"radix.slottable\");\n// @__NO_SIDE_EFFECTS__\nfunction createSlottable(ownerName) {\n const Slottable2 = ({ children }) => {\n return /* @__PURE__ */ jsx(Fragment2, { children });\n };\n Slottable2.displayName = `${ownerName}.Slottable`;\n Slottable2.__radixId = SLOTTABLE_IDENTIFIER;\n return Slottable2;\n}\nvar Slottable = /* @__PURE__ */ createSlottable(\"Slottable\");\nfunction isSlottable(child) {\n return React.isValidElement(child) && typeof child.type === \"function\" && \"__radixId\" in child.type && child.type.__radixId === SLOTTABLE_IDENTIFIER;\n}\nfunction mergeProps(slotProps, childProps) {\n const overrideProps = { ...childProps };\n for (const propName in childProps) {\n const slotPropValue = slotProps[propName];\n const childPropValue = childProps[propName];\n const isHandler = /^on[A-Z]/.test(propName);\n if (isHandler) {\n if (slotPropValue && childPropValue) {\n overrideProps[propName] = (...args) => {\n childPropValue(...args);\n slotPropValue(...args);\n };\n } else if (slotPropValue) {\n overrideProps[propName] = slotPropValue;\n }\n } else if (propName === \"style\") {\n overrideProps[propName] = { ...slotPropValue, ...childPropValue };\n } else if (propName === \"className\") {\n overrideProps[propName] = [slotPropValue, childPropValue].filter(Boolean).join(\" \");\n }\n }\n return { ...slotProps, ...overrideProps };\n}\nfunction getElementRef(element) {\n let getter = Object.getOwnPropertyDescriptor(element.props, \"ref\")?.get;\n let mayWarn = getter && \"isReactWarning\" in getter && getter.isReactWarning;\n if (mayWarn) {\n return element.ref;\n }\n getter = Object.getOwnPropertyDescriptor(element, \"ref\")?.get;\n mayWarn = getter && \"isReactWarning\" in getter && getter.isReactWarning;\n if (mayWarn) {\n return element.props.ref;\n }\n return element.props.ref || element.ref;\n}\nexport {\n Slot as Root,\n Slot,\n Slottable,\n createSlot,\n createSlottable\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":["createSlot","ownerName","SlotClone","createSlotClone","Slot2","React","props","forwardedRef","children","slotProps","childrenArray","slottable","isSlottable","newElement","newChildren","child","jsx","childrenRef","getElementRef","props2","mergeProps","composeRefs","SLOTTABLE_IDENTIFIER","createSlottable","Slottable2","Fragment2","childProps","overrideProps","propName","slotPropValue","childPropValue","args","element","getter","_a","mayWarn","_b"],"mappings":";;;;AAKA,SAASA,EAAWC,GAAW;AAC7B,QAAMC,IAA4B,gBAAAC,EAAgBF,CAAS,GACrDG,IAAQC,EAAM,WAAW,CAACC,GAAOC,MAAiB;AACtD,UAAM,EAAE,UAAAC,GAAU,GAAGC,EAAS,IAAKH,GAC7BI,IAAgBL,EAAM,SAAS,QAAQG,CAAQ,GAC/CG,IAAYD,EAAc,KAAKE,CAAW;AAChD,QAAID,GAAW;AACb,YAAME,IAAaF,EAAU,MAAM,UAC7BG,IAAcJ,EAAc,IAAI,CAACK,MACjCA,MAAUJ,IACRN,EAAM,SAAS,MAAMQ,CAAU,IAAI,IAAUR,EAAM,SAAS,KAAK,IAAI,IAClEA,EAAM,eAAeQ,CAAU,IAAIA,EAAW,MAAM,WAAW,OAE/DE,CAEV;AACD,aAAuBC,gBAAAA,EAAAA,IAAId,GAAW,EAAE,GAAGO,GAAW,KAAKF,GAAc,UAAUF,EAAM,eAAeQ,CAAU,IAAIR,EAAM,aAAaQ,GAAY,QAAQC,CAAW,IAAI,MAAM;AAAA,IACxL;AACI,WAAuBE,gBAAAA,EAAAA,IAAId,GAAW,EAAE,GAAGO,GAAW,KAAKF,GAAc,UAAAC,G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,IAAI,IAAIG,MAAS;AACrC,MAAAD,EAAe,GAAGC,CAAI,GACtBF,EAAc,GAAGE,CAAI;AAAA,IACtB,IACQF,MACTF,EAAcC,CAAQ,IAAIC,KAEnBD,MAAa,UACtBD,EAAcC,CAAQ,IAAI,EAAE,GAAGC,GAAe,GAAGC,EAAgB,IACxDF,MAAa,gBACtBD,EAAcC,CAAQ,IAAI,CAACC,GAAeC,CAAc,EAAE,OAAO,OAAO,EAAE,KAAK,GAAG;AAAA,EAExF;AACE,SAAO,EAAE,GAAGrB,GAAW,GAAGkB,EAAe;AAC3C;AACA,SAAST,EAAcc,GAAS;;AAC9B,MAAIC,KAASC,IAAA,OAAO,yBAAyBF,EAAQ,OAAO,KAAK,MAApD,gBAAAE,EAAuD,KAChEC,IAAUF,KAAU,oBAAoBA,KAAUA,EAAO;AAC7D,SAAIE,IACKH,EAAQ,OAEjBC,KAASG,IAAA,OAAO,yBAAyBJ,GAAS,KAAK,MAA9C,gBAAAI,EAAiD,KAC1DD,IAAUF,KAAU,oBAAoBA,KAAUA,EAAO,gBACrDE,IACKH,EAAQ,MAAM,MAEhBA,EAAQ,MAAM,OAAOA,EAAQ;AACtC;","x_google_ignoreList":[0]}
|
package/dist/index.es400.js
CHANGED
@@ -1,27 +1,14 @@
|
|
1
|
-
import * as
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
});
|
11
|
-
return s(function() {
|
12
|
-
var n = c.get(t);
|
13
|
-
if (n) {
|
14
|
-
var u = new Set(n), r = new Set(e), i = t.current;
|
15
|
-
u.forEach(function(a) {
|
16
|
-
r.has(a) || o(a, null);
|
17
|
-
}), r.forEach(function(a) {
|
18
|
-
u.has(a) || o(a, i);
|
19
|
-
});
|
20
|
-
}
|
21
|
-
c.set(t, e);
|
22
|
-
}, [e]), t;
|
1
|
+
import * as r from "react";
|
2
|
+
function o(t) {
|
3
|
+
const e = r.useRef(t);
|
4
|
+
return r.useEffect(() => {
|
5
|
+
e.current = t;
|
6
|
+
}), r.useMemo(() => (...n) => {
|
7
|
+
var u;
|
8
|
+
return (u = e.current) == null ? void 0 : u.call(e, ...n);
|
9
|
+
}, []);
|
23
10
|
}
|
24
11
|
export {
|
25
|
-
|
12
|
+
o as useCallbackRef
|
26
13
|
};
|
27
14
|
//# sourceMappingURL=index.es400.js.map
|
package/dist/index.es400.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.es400.js","sources":["../node_modules/use-callback-ref/dist/
|
1
|
+
{"version":3,"file":"index.es400.js","sources":["../node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs"],"sourcesContent":["// packages/react/use-callback-ref/src/use-callback-ref.tsx\nimport * as React from \"react\";\nfunction useCallbackRef(callback) {\n const callbackRef = React.useRef(callback);\n React.useEffect(() => {\n callbackRef.current = callback;\n });\n return React.useMemo(() => (...args) => callbackRef.current?.(...args), []);\n}\nexport {\n useCallbackRef\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":["useCallbackRef","callback","callbackRef","React","args","_a"],"mappings":";AAEA,SAASA,EAAeC,GAAU;AAChC,QAAMC,IAAcC,EAAM,OAAOF,CAAQ;AACzC,SAAAE,EAAM,UAAU,MAAM;AACpB,IAAAD,EAAY,UAAUD;AAAA,EAC1B,CAAG,GACME,EAAM,QAAQ,MAAM,IAAIC;;AAAS,YAAAC,IAAAH,EAAY,YAAZ,gBAAAG,EAAA,KAAAH,GAAsB,GAAGE;AAAA,KAAO,EAAE;AAC5E;","x_google_ignoreList":[0]}
|
package/dist/index.es401.js
CHANGED
@@ -1,113 +1,49 @@
|
|
1
|
-
import
|
2
|
-
import
|
3
|
-
import {
|
4
|
-
import {
|
5
|
-
import {
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
},
|
10
|
-
|
11
|
-
},
|
12
|
-
|
13
|
-
}
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
`);
|
20
|
-
}, K = 0, f = [];
|
21
|
-
function z(t) {
|
22
|
-
var c = n.useRef([]), E = n.useRef([0, 0]), d = n.useRef(), h = n.useState(K++)[0], m = n.useState(I)[0], g = n.useRef(t);
|
23
|
-
n.useEffect(function() {
|
24
|
-
g.current = t;
|
25
|
-
}, [t]), n.useEffect(function() {
|
26
|
-
if (t.inert) {
|
27
|
-
document.body.classList.add("block-interactivity-".concat(h));
|
28
|
-
var e = x([t.lockRef.current], (t.shards || []).map(B), !0).filter(Boolean);
|
29
|
-
return e.forEach(function(r) {
|
30
|
-
return r.classList.add("allow-interactivity-".concat(h));
|
31
|
-
}), function() {
|
32
|
-
document.body.classList.remove("block-interactivity-".concat(h)), e.forEach(function(r) {
|
33
|
-
return r.classList.remove("allow-interactivity-".concat(h));
|
34
|
-
});
|
35
|
-
};
|
1
|
+
import r from "react";
|
2
|
+
import { createContextScope as y } from "./index.es365.js";
|
3
|
+
import { useComposedRefs as S } from "./index.es364.js";
|
4
|
+
import { createSlot as M } from "./index.es388.js";
|
5
|
+
import { j as d } from "./index.es196.js";
|
6
|
+
function D(s) {
|
7
|
+
const m = s + "CollectionProvider", [A, E] = y(m), [N, f] = A(
|
8
|
+
m,
|
9
|
+
{ collectionRef: { current: null }, itemMap: /* @__PURE__ */ new Map() }
|
10
|
+
), p = (c) => {
|
11
|
+
const { scope: e, children: l } = c, o = r.useRef(null), t = r.useRef(/* @__PURE__ */ new Map()).current;
|
12
|
+
return /* @__PURE__ */ d.jsx(N, { scope: e, itemMap: t, collectionRef: o, children: l });
|
13
|
+
};
|
14
|
+
p.displayName = m;
|
15
|
+
const a = s + "CollectionSlot", _ = M(a), C = r.forwardRef(
|
16
|
+
(c, e) => {
|
17
|
+
const { scope: l, children: o } = c, t = f(a, l), n = S(e, t.collectionRef);
|
18
|
+
return /* @__PURE__ */ d.jsx(_, { ref: n, children: o });
|
36
19
|
}
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
return !1;
|
44
|
-
var y = T(v, C);
|
45
|
-
if (!y)
|
46
|
-
return !0;
|
47
|
-
if (y ? a = v : (a = v === "v" ? "h" : "v", y = T(v, C)), !y)
|
48
|
-
return !1;
|
49
|
-
if (!d.current && "changedTouches" in e && (u || i) && (d.current = a), !a)
|
50
|
-
return !0;
|
51
|
-
var P = d.current || a;
|
52
|
-
return W(P, r, e, P === "h" ? u : i);
|
53
|
-
}, []), S = n.useCallback(function(e) {
|
54
|
-
var r = e;
|
55
|
-
if (!(!f.length || f[f.length - 1] !== m)) {
|
56
|
-
var l = "deltaY" in r ? Y(r) : b(r), o = c.current.filter(function(a) {
|
57
|
-
return a.name === r.type && (a.target === r.target || r.target === a.shadowParent) && p(a.delta, l);
|
58
|
-
})[0];
|
59
|
-
if (o && o.should) {
|
60
|
-
r.cancelable && r.preventDefault();
|
61
|
-
return;
|
62
|
-
}
|
63
|
-
if (!o) {
|
64
|
-
var u = (g.current.shards || []).map(B).filter(Boolean).filter(function(a) {
|
65
|
-
return a.contains(r.target);
|
66
|
-
}), i = u.length > 0 ? k(r, u[0]) : !g.current.noIsolation;
|
67
|
-
i && r.cancelable && r.preventDefault();
|
68
|
-
}
|
20
|
+
);
|
21
|
+
C.displayName = a;
|
22
|
+
const u = s + "CollectionItemSlot", R = "data-radix-collection-item", T = M(u), x = r.forwardRef(
|
23
|
+
(c, e) => {
|
24
|
+
const { scope: l, children: o, ...t } = c, n = r.useRef(null), I = S(e, n), i = f(u, l);
|
25
|
+
return r.useEffect(() => (i.itemMap.set(n, { ref: n, ...t }), () => void i.itemMap.delete(n))), /* @__PURE__ */ d.jsx(T, { [R]: "", ref: I, children: o });
|
69
26
|
}
|
70
|
-
}, []), R = n.useCallback(function(e, r, l, o) {
|
71
|
-
var u = { name: e, delta: r, target: l, should: o, shadowParent: O(l) };
|
72
|
-
c.current.push(u), setTimeout(function() {
|
73
|
-
c.current = c.current.filter(function(i) {
|
74
|
-
return i !== u;
|
75
|
-
});
|
76
|
-
}, 1);
|
77
|
-
}, []), w = n.useCallback(function(e) {
|
78
|
-
E.current = b(e), d.current = void 0;
|
79
|
-
}, []), L = n.useCallback(function(e) {
|
80
|
-
R(e.type, Y(e), e.target, k(e, t.lockRef.current));
|
81
|
-
}, []), M = n.useCallback(function(e) {
|
82
|
-
R(e.type, b(e), e.target, k(e, t.lockRef.current));
|
83
|
-
}, []);
|
84
|
-
n.useEffect(function() {
|
85
|
-
return f.push(m), t.setCallbacks({
|
86
|
-
onScrollCapture: L,
|
87
|
-
onWheelCapture: L,
|
88
|
-
onTouchMoveCapture: M
|
89
|
-
}), document.addEventListener("wheel", S, s), document.addEventListener("touchmove", S, s), document.addEventListener("touchstart", w, s), function() {
|
90
|
-
f = f.filter(function(e) {
|
91
|
-
return e !== m;
|
92
|
-
}), document.removeEventListener("wheel", S, s), document.removeEventListener("touchmove", S, s), document.removeEventListener("touchstart", w, s);
|
93
|
-
};
|
94
|
-
}, []);
|
95
|
-
var X = t.removeScrollBar, D = t.inert;
|
96
|
-
return n.createElement(
|
97
|
-
n.Fragment,
|
98
|
-
null,
|
99
|
-
D ? n.createElement(m, { styles: F(h) }) : null,
|
100
|
-
X ? n.createElement(A, { gapMode: t.gapMode }) : null
|
101
27
|
);
|
102
|
-
|
103
|
-
function O(
|
104
|
-
|
105
|
-
|
106
|
-
|
28
|
+
x.displayName = u;
|
29
|
+
function O(c) {
|
30
|
+
const e = f(s + "CollectionConsumer", c);
|
31
|
+
return r.useCallback(() => {
|
32
|
+
const o = e.collectionRef.current;
|
33
|
+
if (!o) return [];
|
34
|
+
const t = Array.from(o.querySelectorAll(`[${R}]`));
|
35
|
+
return Array.from(e.itemMap.values()).sort(
|
36
|
+
(i, v) => t.indexOf(i.ref.current) - t.indexOf(v.ref.current)
|
37
|
+
);
|
38
|
+
}, [e.collectionRef, e.itemMap]);
|
39
|
+
}
|
40
|
+
return [
|
41
|
+
{ Provider: p, Slot: C, ItemSlot: x },
|
42
|
+
O,
|
43
|
+
E
|
44
|
+
];
|
107
45
|
}
|
108
46
|
export {
|
109
|
-
|
110
|
-
Y as getDeltaXY,
|
111
|
-
b as getTouchXY
|
47
|
+
D as createCollection
|
112
48
|
};
|
113
49
|
//# sourceMappingURL=index.es401.js.map
|
package/dist/index.es401.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.es401.js","sources":["../node_modules/react-remove-scroll/dist/es2015/SideEffect.js"],"sourcesContent":["import { __spreadArray } from \"tslib\";\nimport * as React from 'react';\nimport { RemoveScrollBar } from 'react-remove-scroll-bar';\nimport { styleSingleton } from 'react-style-singleton';\nimport { nonPassive } from './aggresiveCapture';\nimport { handleScroll, locationCouldBeScrolled } from './handleScroll';\nexport var getTouchXY = function (event) {\n return 'changedTouches' in event ? [event.changedTouches[0].clientX, event.changedTouches[0].clientY] : [0, 0];\n};\nexport var getDeltaXY = function (event) { return [event.deltaX, event.deltaY]; };\nvar extractRef = function (ref) {\n return ref && 'current' in ref ? ref.current : ref;\n};\nvar deltaCompare = function (x, y) { return x[0] === y[0] && x[1] === y[1]; };\nvar generateStyle = function (id) { return \"\\n .block-interactivity-\".concat(id, \" {pointer-events: none;}\\n .allow-interactivity-\").concat(id, \" {pointer-events: all;}\\n\"); };\nvar idCounter = 0;\nvar lockStack = [];\nexport function RemoveScrollSideCar(props) {\n var shouldPreventQueue = React.useRef([]);\n var touchStartRef = React.useRef([0, 0]);\n var activeAxis = React.useRef();\n var id = React.useState(idCounter++)[0];\n var Style = React.useState(styleSingleton)[0];\n var lastProps = React.useRef(props);\n React.useEffect(function () {\n lastProps.current = props;\n }, [props]);\n React.useEffect(function () {\n if (props.inert) {\n document.body.classList.add(\"block-interactivity-\".concat(id));\n var allow_1 = __spreadArray([props.lockRef.current], (props.shards || []).map(extractRef), true).filter(Boolean);\n allow_1.forEach(function (el) { return el.classList.add(\"allow-interactivity-\".concat(id)); });\n return function () {\n document.body.classList.remove(\"block-interactivity-\".concat(id));\n allow_1.forEach(function (el) { return el.classList.remove(\"allow-interactivity-\".concat(id)); });\n };\n }\n return;\n }, [props.inert, props.lockRef.current, props.shards]);\n var shouldCancelEvent = React.useCallback(function (event, parent) {\n if (('touches' in event && event.touches.length === 2) || (event.type === 'wheel' && event.ctrlKey)) {\n return !lastProps.current.allowPinchZoom;\n }\n var touch = getTouchXY(event);\n var touchStart = touchStartRef.current;\n var deltaX = 'deltaX' in event ? event.deltaX : touchStart[0] - touch[0];\n var deltaY = 'deltaY' in event ? event.deltaY : touchStart[1] - touch[1];\n var currentAxis;\n var target = event.target;\n var moveDirection = Math.abs(deltaX) > Math.abs(deltaY) ? 'h' : 'v';\n // allow horizontal touch move on Range inputs. They will not cause any scroll\n if ('touches' in event && moveDirection === 'h' && target.type === 'range') {\n return false;\n }\n var canBeScrolledInMainDirection = locationCouldBeScrolled(moveDirection, target);\n if (!canBeScrolledInMainDirection) {\n return true;\n }\n if (canBeScrolledInMainDirection) {\n currentAxis = moveDirection;\n }\n else {\n currentAxis = moveDirection === 'v' ? 'h' : 'v';\n canBeScrolledInMainDirection = locationCouldBeScrolled(moveDirection, target);\n // other axis might be not scrollable\n }\n if (!canBeScrolledInMainDirection) {\n return false;\n }\n if (!activeAxis.current && 'changedTouches' in event && (deltaX || deltaY)) {\n activeAxis.current = currentAxis;\n }\n if (!currentAxis) {\n return true;\n }\n var cancelingAxis = activeAxis.current || currentAxis;\n return handleScroll(cancelingAxis, parent, event, cancelingAxis === 'h' ? deltaX : deltaY, true);\n }, []);\n var shouldPrevent = React.useCallback(function (_event) {\n var event = _event;\n if (!lockStack.length || lockStack[lockStack.length - 1] !== Style) {\n // not the last active\n return;\n }\n var delta = 'deltaY' in event ? getDeltaXY(event) : getTouchXY(event);\n var sourceEvent = shouldPreventQueue.current.filter(function (e) { return e.name === event.type && (e.target === event.target || event.target === e.shadowParent) && deltaCompare(e.delta, delta); })[0];\n // self event, and should be canceled\n if (sourceEvent && sourceEvent.should) {\n if (event.cancelable) {\n event.preventDefault();\n }\n return;\n }\n // outside or shard event\n if (!sourceEvent) {\n var shardNodes = (lastProps.current.shards || [])\n .map(extractRef)\n .filter(Boolean)\n .filter(function (node) { return node.contains(event.target); });\n var shouldStop = shardNodes.length > 0 ? shouldCancelEvent(event, shardNodes[0]) : !lastProps.current.noIsolation;\n if (shouldStop) {\n if (event.cancelable) {\n event.preventDefault();\n }\n }\n }\n }, []);\n var shouldCancel = React.useCallback(function (name, delta, target, should) {\n var event = { name: name, delta: delta, target: target, should: should, shadowParent: getOutermostShadowParent(target) };\n shouldPreventQueue.current.push(event);\n setTimeout(function () {\n shouldPreventQueue.current = shouldPreventQueue.current.filter(function (e) { return e !== event; });\n }, 1);\n }, []);\n var scrollTouchStart = React.useCallback(function (event) {\n touchStartRef.current = getTouchXY(event);\n activeAxis.current = undefined;\n }, []);\n var scrollWheel = React.useCallback(function (event) {\n shouldCancel(event.type, getDeltaXY(event), event.target, shouldCancelEvent(event, props.lockRef.current));\n }, []);\n var scrollTouchMove = React.useCallback(function (event) {\n shouldCancel(event.type, getTouchXY(event), event.target, shouldCancelEvent(event, props.lockRef.current));\n }, []);\n React.useEffect(function () {\n lockStack.push(Style);\n props.setCallbacks({\n onScrollCapture: scrollWheel,\n onWheelCapture: scrollWheel,\n onTouchMoveCapture: scrollTouchMove,\n });\n document.addEventListener('wheel', shouldPrevent, nonPassive);\n document.addEventListener('touchmove', shouldPrevent, nonPassive);\n document.addEventListener('touchstart', scrollTouchStart, nonPassive);\n return function () {\n lockStack = lockStack.filter(function (inst) { return inst !== Style; });\n document.removeEventListener('wheel', shouldPrevent, nonPassive);\n document.removeEventListener('touchmove', shouldPrevent, nonPassive);\n document.removeEventListener('touchstart', scrollTouchStart, nonPassive);\n };\n }, []);\n var removeScrollBar = props.removeScrollBar, inert = props.inert;\n return (React.createElement(React.Fragment, null,\n inert ? React.createElement(Style, { styles: generateStyle(id) }) : null,\n removeScrollBar ? React.createElement(RemoveScrollBar, { gapMode: props.gapMode }) : null));\n}\nfunction getOutermostShadowParent(node) {\n var shadowParent = null;\n while (node !== null) {\n if (node instanceof ShadowRoot) {\n shadowParent = node.host;\n node = node.host;\n }\n node = node.parentNode;\n }\n return shadowParent;\n}\n"],"names":["getTouchXY","event","getDeltaXY","extractRef","ref","deltaCompare","x","y","generateStyle","id","idCounter","lockStack","RemoveScrollSideCar","props","shouldPreventQueue","React","touchStartRef","activeAxis","Style","styleSingleton","lastProps","allow_1","__spreadArray","el","shouldCancelEvent","parent","touch","touchStart","deltaX","deltaY","currentAxis","target","moveDirection","canBeScrolledInMainDirection","locationCouldBeScrolled","cancelingAxis","handleScroll","shouldPrevent","_event","delta","sourceEvent","e","shardNodes","node","shouldStop","shouldCancel","name","should","getOutermostShadowParent","scrollTouchStart","scrollWheel","scrollTouchMove","nonPassive","inst","removeScrollBar","inert","RemoveScrollBar","shadowParent"],"mappings":";;;;;;AAMU,IAACA,IAAa,SAAUC,GAAO;AACrC,SAAO,oBAAoBA,IAAQ,CAACA,EAAM,eAAe,CAAC,EAAE,SAASA,EAAM,eAAe,CAAC,EAAE,OAAO,IAAI,CAAC,GAAG,CAAC;AACjH,GACWC,IAAa,SAAUD,GAAO;AAAE,SAAO,CAACA,EAAM,QAAQA,EAAM,MAAM;AAAE,GAC3EE,IAAa,SAAUC,GAAK;AAC5B,SAAOA,KAAO,aAAaA,IAAMA,EAAI,UAAUA;AACnD,GACIC,IAAe,SAAUC,GAAGC,GAAG;AAAE,SAAOD,EAAE,CAAC,MAAMC,EAAE,CAAC,KAAKD,EAAE,CAAC,MAAMC,EAAE,CAAC;AAAI,GACzEC,IAAgB,SAAUC,GAAI;AAAE,SAAO;AAAA,yBAA4B,OAAOA,GAAI;AAAA,wBAAmD,EAAE,OAAOA,GAAI;AAAA,CAA2B;AAAI,GAC7KC,IAAY,GACZC,IAAY,CAAE;AACX,SAASC,EAAoBC,GAAO;AACvC,MAAIC,IAAqBC,EAAM,OAAO,EAAE,GACpCC,IAAgBD,EAAM,OAAO,CAAC,GAAG,CAAC,CAA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,aAAa;AAAA,MACf,iBAAiBqC;AAAA,MACjB,gBAAgBA;AAAA,MAChB,oBAAoBC;AAAA,IAChC,CAAS,GACD,SAAS,iBAAiB,SAASd,GAAee,CAAU,GAC5D,SAAS,iBAAiB,aAAaf,GAAee,CAAU,GAChE,SAAS,iBAAiB,cAAcH,GAAkBG,CAAU,GAC7D,WAAY;AACf,MAAAzC,IAAYA,EAAU,OAAO,SAAU0C,GAAM;AAAE,eAAOA,MAASnC;AAAA,OAAQ,GACvE,SAAS,oBAAoB,SAASmB,GAAee,CAAU,GAC/D,SAAS,oBAAoB,aAAaf,GAAee,CAAU,GACnE,SAAS,oBAAoB,cAAcH,GAAkBG,CAAU;AAAA,IAC1E;AAAA,EACJ,GAAE,EAAE;AACL,MAAIE,IAAkBzC,EAAM,iBAAiB0C,IAAQ1C,EAAM;AAC3D,SAAQE,EAAM;AAAA,IAAcA,EAAM;AAAA,IAAU;AAAA,IACxCwC,IAAQxC,EAAM,cAAcG,GAAO,EAAE,QAAQV,EAAcC,CAAE,EAAG,CAAA,IAAI;AAAA,IACpE6C,IAAkBvC,EAAM,cAAcyC,GAAiB,EAAE,SAAS3C,EAAM,SAAS,IAAI;AAAA,EAAI;AACjG;AACA,SAASmC,EAAyBL,GAAM;AAEpC,WADIc,IAAe,MACZd,MAAS;AACZ,IAAIA,aAAgB,eAChBc,IAAed,EAAK,MACpBA,IAAOA,EAAK,OAEhBA,IAAOA,EAAK;AAEhB,SAAOc;AACX;","x_google_ignoreList":[0]}
|
1
|
+
{"version":3,"file":"index.es401.js","sources":["../node_modules/@radix-ui/react-collection/dist/index.mjs"],"sourcesContent":["\"use client\";\n\n// packages/react/collection/src/collection.tsx\nimport React from \"react\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { createSlot } from \"@radix-ui/react-slot\";\nimport { jsx } from \"react/jsx-runtime\";\nfunction createCollection(name) {\n const PROVIDER_NAME = name + \"CollectionProvider\";\n const [createCollectionContext, createCollectionScope] = createContextScope(PROVIDER_NAME);\n const [CollectionProviderImpl, useCollectionContext] = createCollectionContext(\n PROVIDER_NAME,\n { collectionRef: { current: null }, itemMap: /* @__PURE__ */ new Map() }\n );\n const CollectionProvider = (props) => {\n const { scope, children } = props;\n const ref = React.useRef(null);\n const itemMap = React.useRef(/* @__PURE__ */ new Map()).current;\n return /* @__PURE__ */ jsx(CollectionProviderImpl, { scope, itemMap, collectionRef: ref, children });\n };\n CollectionProvider.displayName = PROVIDER_NAME;\n const COLLECTION_SLOT_NAME = name + \"CollectionSlot\";\n const CollectionSlotImpl = createSlot(COLLECTION_SLOT_NAME);\n const CollectionSlot = React.forwardRef(\n (props, forwardedRef) => {\n const { scope, children } = props;\n const context = useCollectionContext(COLLECTION_SLOT_NAME, scope);\n const composedRefs = useComposedRefs(forwardedRef, context.collectionRef);\n return /* @__PURE__ */ jsx(CollectionSlotImpl, { ref: composedRefs, children });\n }\n );\n CollectionSlot.displayName = COLLECTION_SLOT_NAME;\n const ITEM_SLOT_NAME = name + \"CollectionItemSlot\";\n const ITEM_DATA_ATTR = \"data-radix-collection-item\";\n const CollectionItemSlotImpl = createSlot(ITEM_SLOT_NAME);\n const CollectionItemSlot = React.forwardRef(\n (props, forwardedRef) => {\n const { scope, children, ...itemData } = props;\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n const context = useCollectionContext(ITEM_SLOT_NAME, scope);\n React.useEffect(() => {\n context.itemMap.set(ref, { ref, ...itemData });\n return () => void context.itemMap.delete(ref);\n });\n return /* @__PURE__ */ jsx(CollectionItemSlotImpl, { ...{ [ITEM_DATA_ATTR]: \"\" }, ref: composedRefs, children });\n }\n );\n CollectionItemSlot.displayName = ITEM_SLOT_NAME;\n function useCollection(scope) {\n const context = useCollectionContext(name + \"CollectionConsumer\", scope);\n const getItems = React.useCallback(() => {\n const collectionNode = context.collectionRef.current;\n if (!collectionNode) return [];\n const orderedNodes = Array.from(collectionNode.querySelectorAll(`[${ITEM_DATA_ATTR}]`));\n const items = Array.from(context.itemMap.values());\n const orderedItems = items.sort(\n (a, b) => orderedNodes.indexOf(a.ref.current) - orderedNodes.indexOf(b.ref.current)\n );\n return orderedItems;\n }, [context.collectionRef, context.itemMap]);\n return getItems;\n }\n return [\n { Provider: CollectionProvider, Slot: CollectionSlot, ItemSlot: CollectionItemSlot },\n useCollection,\n createCollectionScope\n ];\n}\nexport {\n createCollection\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":["createCollection","name","PROVIDER_NAME","createCollectionContext","createCollectionScope","createContextScope","CollectionProviderImpl","useCollectionContext","CollectionProvider","props","scope","children","ref","React","itemMap","jsx","COLLECTION_SLOT_NAME","CollectionSlotImpl","createSlot","CollectionSlot","forwardedRef","context","composedRefs","useComposedRefs","ITEM_SLOT_NAME","ITEM_DATA_ATTR","CollectionItemSlotImpl","CollectionItemSlot","itemData","useCollection","collectionNode","orderedNodes","a","b"],"mappings":";;;;;AAQA,SAASA,EAAiBC,GAAM;AAC9B,QAAMC,IAAgBD,IAAO,sBACvB,CAACE,GAAyBC,CAAqB,IAAIC,EAAmBH,CAAa,GACnF,CAACI,GAAwBC,CAAoB,IAAIJ;AAAA,IACrDD;AAAA,IACA,EAAE,eAAe,EAAE,SAAS,KAAI,GAAI,SAAyB,oBAAI,IAAK,EAAA;AAAA,EACvE,GACKM,IAAqB,CAACC,MAAU;AACpC,UAAM,EAAE,OAAAC,GAAO,UAAAC,EAAQ,IAAKF,GACtBG,IAAMC,EAAM,OAAO,IAAI,GACvBC,IAAUD,EAAM,OAAuB,oBAAI,IAAG,CAAE,EAAE;AACxD,WAAuBE,gBAAAA,EAAG,IAACT,GAAwB,EAAE,OAAAI,GAAO,SAAAI,GAAS,eAAeF,GAAK,UAAAD,GAAU;AAAA,EACpG;AACD,EAAAH,EAAmB,cAAcN;AACjC,QAAMc,IAAuBf,IAAO,kBAC9BgB,IAAqBC,EAAWF,CAAoB,GACpDG,IAAiBN,EAAM;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GAAGC,MAAMF,EAAa,QAAQC,EAAE,IAAI,OAAO,IAAID,EAAa,QAAQE,EAAE,IAAI,OAAO;AAAA,MACnF;AAAA,IAEF,GAAE,CAACZ,EAAQ,eAAeA,EAAQ,OAAO,CAAC;AAAA,EAE/C;AACE,SAAO;AAAA,IACL,EAAE,UAAUb,GAAoB,MAAMW,GAAgB,UAAUQ,EAAoB;AAAA,IACpFE;AAAA,IACAzB;AAAA,EACD;AACH;","x_google_ignoreList":[0]}
|
package/dist/index.es402.js
CHANGED
@@ -1,19 +1,11 @@
|
|
1
|
-
import
|
2
|
-
import
|
3
|
-
var
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
var t = e.read();
|
8
|
-
if (!t)
|
9
|
-
throw new Error("Sidecar medium not found");
|
10
|
-
return n.createElement(t, d({}, a));
|
11
|
-
};
|
12
|
-
i.isSideCarExport = !0;
|
13
|
-
function p(r, e) {
|
14
|
-
return r.useMedium(e), i;
|
1
|
+
import * as t from "react";
|
2
|
+
import "./index.es196.js";
|
3
|
+
var r = t.createContext(void 0);
|
4
|
+
function n(o) {
|
5
|
+
const e = t.useContext(r);
|
6
|
+
return o || e || "ltr";
|
15
7
|
}
|
16
8
|
export {
|
17
|
-
|
9
|
+
n as useDirection
|
18
10
|
};
|
19
11
|
//# sourceMappingURL=index.es402.js.map
|
package/dist/index.es402.js.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.es402.js","sources":["../node_modules/
|
1
|
+
{"version":3,"file":"index.es402.js","sources":["../node_modules/@radix-ui/react-direction/dist/index.mjs"],"sourcesContent":["// packages/react/direction/src/direction.tsx\nimport * as React from \"react\";\nimport { jsx } from \"react/jsx-runtime\";\nvar DirectionContext = React.createContext(void 0);\nvar DirectionProvider = (props) => {\n const { dir, children } = props;\n return /* @__PURE__ */ jsx(DirectionContext.Provider, { value: dir, children });\n};\nfunction useDirection(localDir) {\n const globalDir = React.useContext(DirectionContext);\n return localDir || globalDir || \"ltr\";\n}\nvar Provider = DirectionProvider;\nexport {\n DirectionProvider,\n Provider,\n useDirection\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":["DirectionContext","React","useDirection","localDir","globalDir"],"mappings":";;AAGA,IAAIA,IAAmBC,EAAM,cAAc,MAAM;AAKjD,SAASC,EAAaC,GAAU;AAC9B,QAAMC,IAAYH,EAAM,WAAWD,CAAgB;AACnD,SAAOG,KAAYC,KAAa;AAClC;","x_google_ignoreList":[0]}
|