@aussieljk/forkbook 0.0.1-5 → 0.0.1-7

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.
Files changed (314) hide show
  1. package/dist/_browser-chunks/{Color-GTF4GM7L.js → Color-2YRIFQLC.js} +1 -1
  2. package/dist/_browser-chunks/WithTooltip-4R5JMWZ7.js +196 -0
  3. package/dist/_browser-chunks/{chunk-MJY6ITYT.js → chunk-4EFKUJG2.js} +10 -10
  4. package/dist/_browser-chunks/chunk-6AKCRYVX.js +6 -0
  5. package/dist/_browser-chunks/{chunk-FVSEPWWX.js → chunk-DAUHYZUB.js} +550 -1621
  6. package/dist/_browser-chunks/chunk-E47B5255.js +1149 -0
  7. package/dist/_browser-chunks/{chunk-K6GRZSXS.js → chunk-EQKMUQF3.js} +4 -3
  8. package/dist/_browser-chunks/{chunk-GU3X2J4S.js → chunk-FRAOQJDI.js} +3 -1
  9. package/dist/_browser-chunks/{chunk-2SCZVUKW.js → chunk-H4ZHAXN3.js} +1 -1
  10. package/dist/_browser-chunks/{chunk-HOSBMS2F.js → chunk-HTL5ODCB.js} +1 -1
  11. package/dist/_browser-chunks/{chunk-ZLWA5RIE.js → chunk-I4ATZPNZ.js} +1 -1
  12. package/dist/_browser-chunks/{chunk-6SHRDXGF.js → chunk-IJYLSHY7.js} +173 -87
  13. package/dist/_browser-chunks/{chunk-SZCSXISG.js → chunk-NA4ITZTK.js} +7 -5
  14. package/dist/_browser-chunks/chunk-NGMQJMCY.js +53 -0
  15. package/dist/_browser-chunks/{chunk-K2B36HKM.js → chunk-O24AZJZ7.js} +1 -1
  16. package/dist/_browser-chunks/{chunk-NMRSYACM.js → chunk-SFMQDIN2.js} +4 -3
  17. package/dist/_browser-chunks/{chunk-ZTQ5MEJ5.js → chunk-UMGDO2ZM.js} +3 -37
  18. package/dist/_browser-chunks/chunk-WVF42CP2.js +6027 -0
  19. package/dist/_browser-chunks/{chunk-52CW7FF7.js → chunk-YYWKZ7O3.js} +3 -1
  20. package/dist/_node-chunks/{attached-runtime-IOE3BXIY.js → attached-runtime-WFZCCGUB.js} +29 -29
  21. package/dist/_node-chunks/{builder-manager-GDFEGD72.js → builder-manager-DHKHRZK4.js} +155 -148
  22. package/dist/_node-chunks/{chunk-M2QB5ALN.js → chunk-3ZCGT6VF.js} +6 -6
  23. package/dist/_node-chunks/{chunk-SUJXQU74.js → chunk-4HGC3G6B.js} +46 -15
  24. package/dist/_node-chunks/{chunk-WMQ2VCTF.js → chunk-5PYQ573S.js} +7 -7
  25. package/dist/_node-chunks/{chunk-TYCDPVIH.js → chunk-64JPAW3T.js} +6 -6
  26. package/dist/_node-chunks/chunk-6CB3XSQ2.js +495 -0
  27. package/dist/_node-chunks/{chunk-MHDKWHOA.js → chunk-6K3ZE4HN.js} +6 -6
  28. package/dist/_node-chunks/{chunk-3DCJB2D4.js → chunk-6QZ3PX5R.js} +6 -6
  29. package/dist/_node-chunks/{chunk-6DOJKR3V.js → chunk-7HVDL6M3.js} +29843 -51588
  30. package/dist/_node-chunks/chunk-7PMQPS5E.js +347 -0
  31. package/dist/_node-chunks/{chunk-L5CY6HKG.js → chunk-7V5AOV2J.js} +7 -7
  32. package/dist/_node-chunks/{chunk-AXJJB2K6.js → chunk-7VHCAGBJ.js} +8 -8
  33. package/dist/_node-chunks/{chunk-3DX6THMV.js → chunk-ATX7SHS7.js} +8 -8
  34. package/dist/_node-chunks/{chunk-SDXU22OH.js → chunk-BQC6WCUS.js} +6 -6
  35. package/dist/_node-chunks/{chunk-D6B2DRQZ.js → chunk-BR4WDRY6.js} +8 -8
  36. package/dist/_node-chunks/{chunk-SJZQ44OR.js → chunk-BRHJ4P3A.js} +6 -6
  37. package/dist/_node-chunks/{chunk-N4FLP7AO.js → chunk-CBBFNVFZ.js} +7 -7
  38. package/dist/_node-chunks/{chunk-PHXCOTMO.js → chunk-CDFQORVD.js} +34 -949
  39. package/dist/_node-chunks/{chunk-SR3BCYEH.js → chunk-CENNLCU7.js} +6 -6
  40. package/dist/_node-chunks/{chunk-OTFIQXHR.js → chunk-CNMMDQC3.js} +27 -50
  41. package/dist/_node-chunks/{chunk-E4C2H45J.js → chunk-DMDZPUHM.js} +6 -6
  42. package/dist/_node-chunks/{chunk-45LRLOYO.js → chunk-DT45EUDD.js} +60 -134
  43. package/dist/_node-chunks/{chunk-KQFHT7SW.js → chunk-EAL4RVEF.js} +6 -6
  44. package/dist/_node-chunks/chunk-EFFWFE6W.js +11 -0
  45. package/dist/_node-chunks/{chunk-MDGNN3FJ.js → chunk-ESCZ2NSB.js} +6 -6
  46. package/dist/_node-chunks/{chunk-T2I453AJ.js → chunk-ESZIQTUH.js} +7 -7
  47. package/dist/_node-chunks/{chunk-HWY2CAUH.js → chunk-F3SAYS4R.js} +6 -6
  48. package/dist/_node-chunks/{chunk-LSP54OYM.js → chunk-FTUQ7T3V.js} +25 -8
  49. package/dist/_node-chunks/{chunk-AAAUVDWT.js → chunk-FVFSSIGA.js} +10 -10
  50. package/dist/_node-chunks/{chunk-GS4VNNSS.js → chunk-G2AANC4A.js} +6 -6
  51. package/dist/_node-chunks/{chunk-SAAQFJL4.js → chunk-HUMAXGH2.js} +6 -6
  52. package/dist/_node-chunks/{chunk-A4XRNDN4.js → chunk-I535GEPH.js} +7 -7
  53. package/dist/_node-chunks/{chunk-CK4EHW3K.js → chunk-J3Q56GX3.js} +25 -25
  54. package/dist/_node-chunks/{chunk-U47PBQZ3.js → chunk-JDKYP7FW.js} +10 -10
  55. package/dist/_node-chunks/{chunk-7TUSIVWS.js → chunk-JED5F3H2.js} +6 -6
  56. package/dist/_node-chunks/{chunk-UM5G27IC.js → chunk-JMS4H7QB.js} +7 -7
  57. package/dist/_node-chunks/{chunk-GR65OLAH.js → chunk-JOSJ64KD.js} +7 -7
  58. package/dist/_node-chunks/{chunk-XUHEL63G.js → chunk-JPHSU5OI.js} +6 -6
  59. package/dist/_node-chunks/{chunk-NYWD5LYM.js → chunk-JQICISDD.js} +6 -6
  60. package/dist/_node-chunks/{chunk-I3DKGHVD.js → chunk-JTLOSDYL.js} +9 -9
  61. package/dist/_node-chunks/{chunk-5KAJVK4E.js → chunk-K5RUOW42.js} +7 -7
  62. package/dist/_node-chunks/{chunk-UKEJISQU.js → chunk-KHWCZDIW.js} +650 -9
  63. package/dist/_node-chunks/chunk-KWER36VB.js +20 -0
  64. package/dist/_node-chunks/{chunk-YTBTCM22.js → chunk-LJTP5PAJ.js} +6 -6
  65. package/dist/_node-chunks/chunk-LZYYZ62Y.js +19 -0
  66. package/dist/_node-chunks/{chunk-CGXW2HFE.js → chunk-M7ZVSBNU.js} +6 -6
  67. package/dist/_node-chunks/{chunk-BTFSFATC.js → chunk-MBIIJTGQ.js} +11 -10
  68. package/dist/_node-chunks/{chunk-VBSVLIXU.js → chunk-MF3AT3JQ.js} +6 -6
  69. package/dist/_node-chunks/{chunk-AX2ALHBK.js → chunk-MF5BYASO.js} +9 -6
  70. package/dist/_node-chunks/{chunk-JJNO3SFI.js → chunk-MJFMB4WD.js} +9 -9
  71. package/dist/_node-chunks/{chunk-E4TBS4MV.js → chunk-MRWBN46D.js} +8 -8
  72. package/dist/_node-chunks/{chunk-QQXFB4YA.js → chunk-MZQXEAI6.js} +9 -9
  73. package/dist/_node-chunks/{chunk-TZ2TZW2K.js → chunk-NLPC2DDQ.js} +6 -6
  74. package/dist/_node-chunks/{chunk-HCX5R46Q.js → chunk-NQAFLS5U.js} +8 -8
  75. package/dist/_node-chunks/{chunk-5LE7GXEC.js → chunk-NSZGBFPR.js} +6 -6
  76. package/dist/_node-chunks/{chunk-WHDCECIV.js → chunk-NUYBFTOU.js} +7 -7
  77. package/dist/_node-chunks/{chunk-RCPKLP3X.js → chunk-O7VJA7SM.js} +7 -7
  78. package/dist/_node-chunks/{chunk-2GY2FKLH.js → chunk-OGJ7LDX3.js} +7 -7
  79. package/dist/_node-chunks/{chunk-F4Q7OCCN.js → chunk-OWT6AVWK.js} +8 -8
  80. package/dist/_node-chunks/{chunk-LCXIUTOU.js → chunk-P3GOMPP3.js} +7 -7
  81. package/dist/_node-chunks/{chunk-KCAPE7OJ.js → chunk-PQLXHVWK.js} +6 -6
  82. package/dist/_node-chunks/{chunk-V45RRBTK.js → chunk-Q6QRFKHB.js} +8 -8
  83. package/dist/_node-chunks/{chunk-VJSOHPVD.js → chunk-QSP42ZBM.js} +6 -6
  84. package/dist/_node-chunks/{chunk-7XUQM6SR.js → chunk-QWDR5OWQ.js} +14 -14
  85. package/dist/_node-chunks/{chunk-YLKS7U3M.js → chunk-QWRQXG2V.js} +8 -8
  86. package/dist/_node-chunks/{chunk-4WO3GNZQ.js → chunk-R6AKCXPH.js} +6 -6
  87. package/dist/_node-chunks/{chunk-AXQ6LLSE.js → chunk-RCY7TLET.js} +8 -8
  88. package/dist/_node-chunks/chunk-RKKMQA6N.js +620 -0
  89. package/dist/_node-chunks/{chunk-BV3QRFE6.js → chunk-RZ7UEP4N.js} +6 -6
  90. package/dist/_node-chunks/{chunk-OSJFTZ5N.js → chunk-S3HB4EWT.js} +6 -6
  91. package/dist/_node-chunks/{chunk-QZVFIEOM.js → chunk-SHH7JROR.js} +6 -6
  92. package/dist/_node-chunks/{chunk-Q33BYVLY.js → chunk-SWHTDOB4.js} +7 -7
  93. package/dist/_node-chunks/{chunk-ZPPVG262.js → chunk-SZYMLCHF.js} +6 -6
  94. package/dist/_node-chunks/{chunk-ES5QZBSB.js → chunk-TOGDRW2W.js} +6 -6
  95. package/dist/_node-chunks/{chunk-J64XMUPF.js → chunk-U3E7E4Q2.js} +10 -10
  96. package/dist/_node-chunks/{chunk-RECGEABN.js → chunk-U6DHF3RM.js} +7 -7
  97. package/dist/_node-chunks/{chunk-OB2XHL53.js → chunk-UAG3XK32.js} +31 -30
  98. package/dist/_node-chunks/{chunk-BBD2KUV4.js → chunk-UF6Q6L5C.js} +22 -20
  99. package/dist/_node-chunks/chunk-UGXN7JTT.js +18 -0
  100. package/dist/_node-chunks/{chunk-EWAGCBER.js → chunk-UNCBLHIP.js} +8 -8
  101. package/dist/_node-chunks/chunk-UPJMGWMZ.js +25 -0
  102. package/dist/_node-chunks/chunk-UVV24PG4.js +69 -0
  103. package/dist/_node-chunks/{chunk-E6KXSYWR.js → chunk-WBB4NQ6H.js} +6 -6
  104. package/dist/_node-chunks/{chunk-B2IOB2V3.js → chunk-WHOF2BJB.js} +7 -7
  105. package/dist/_node-chunks/{chunk-FA36CEN4.js → chunk-WME5NEJA.js} +6 -6
  106. package/dist/_node-chunks/{chunk-BFZG4UTW.js → chunk-X63YMAHP.js} +7 -7
  107. package/dist/_node-chunks/chunk-Y2GHAOKI.js +25 -0
  108. package/dist/_node-chunks/{chunk-AXG3EMKS.js → chunk-Y6G64J5S.js} +7 -15
  109. package/dist/_node-chunks/chunk-YVIPYJ53.js +2609 -0
  110. package/dist/_node-chunks/{chunk-NDGTNFUN.js → chunk-YZWUD7I5.js} +16 -13
  111. package/dist/_node-chunks/{chunk-VN3A5CEH.js → chunk-ZIDIYSJQ.js} +7 -7
  112. package/dist/_node-chunks/chunk-ZSGOW4WQ.js +20 -0
  113. package/dist/_node-chunks/dist-5EG56KTF.js +16 -0
  114. package/dist/_node-chunks/dist-UEXSNGGQ.js +27 -0
  115. package/dist/_node-chunks/{local-runtime-RW6AAWSX.js → local-runtime-UN5QK2SE.js} +20 -20
  116. package/dist/_node-chunks/{mdx-plugin-BKWCT6CB.js → mdx-plugin-6M6CMNL3.js} +2263 -130
  117. package/dist/_node-chunks/{monorepo-ZFJ6HM34.js → monorepo-253VKW4B.js} +11 -11
  118. package/dist/_node-chunks/{monorepo-optimized-tests-relaxed-limits-no-story-deletion-C3EW4VJW.js → monorepo-optimized-tests-relaxed-limits-no-story-deletion-3ZOE54OQ.js} +11 -11
  119. package/dist/_node-chunks/optimized-tests-JSWLRMEI.js +22 -0
  120. package/dist/_node-chunks/{pattern-copy-play-2ZMJNCBS.js → pattern-copy-play-CCCJRMSL.js} +9 -9
  121. package/dist/_node-chunks/postinstallAddon-VMANBHPR.js +20 -0
  122. package/dist/_node-chunks/{rehype-external-links-RT5Z62RV.js → rehype-external-links-LJTPLCGD.js} +9 -9
  123. package/dist/_node-chunks/{rehype-slug-H5TWHJ6G.js → rehype-slug-KQI7ULEZ.js} +9 -9
  124. package/dist/_node-chunks/{relaxed-limits-DYLWZGE4.js → relaxed-limits-MUE2NI7S.js} +11 -11
  125. package/dist/_node-chunks/{run-65LLGSVR.js → run-PGZMPNMS.js} +246 -13
  126. package/dist/_node-chunks/{run-BQQLK454.js → run-SYLR25HA.js} +17 -17
  127. package/dist/_node-chunks/session-id-J4A25UQ6.js +23 -0
  128. package/dist/_node-chunks/{setup-NEO7XX66.js → setup-XZWSUYPG.js} +8 -8
  129. package/dist/_node-chunks/{vitest.config.4.template-6P3FZQTY.js → vitest.config.4.template-T25YYRGV.js} +7 -7
  130. package/dist/actions/decorator.js +2 -1
  131. package/dist/actions/index.js +2 -1
  132. package/dist/addon-a11y/index.js +2 -1
  133. package/dist/addon-a11y/manager.js +6 -5
  134. package/dist/addon-a11y/preset.js +7 -7
  135. package/dist/addon-a11y/preview.js +2 -1
  136. package/dist/addon-docs/blocks.js +28 -14
  137. package/dist/addon-docs/manager.js +2 -2
  138. package/dist/addon-docs/preset.js +10 -10
  139. package/dist/addon-links/index.js +3 -2
  140. package/dist/addon-links/preview.d.ts +1 -1
  141. package/dist/addon-links/preview.js +3 -2
  142. package/dist/addon-links/react/index.js +2 -1
  143. package/dist/addon-mcp/preset.js +8 -8
  144. package/dist/addon-mcp/tools/preview-stories/preview-stories-app-script.js +21 -44
  145. package/dist/addon-ondevice-actions/index.js +5 -1
  146. package/dist/addon-ondevice-actions/register.js +5 -1
  147. package/dist/addon-themes/postinstall.js +7 -7
  148. package/dist/addon-vitest/constants.js +8 -8
  149. package/dist/addon-vitest/manager.js +2 -2
  150. package/dist/addon-vitest/node/coverage-reporter.js +8 -8
  151. package/dist/addon-vitest/node/vitest.js +16 -16
  152. package/dist/addon-vitest/postinstall.js +10 -10
  153. package/dist/addon-vitest/preset.js +15 -16
  154. package/dist/addon-vitest/vitest-plugin/global-setup.js +7 -7
  155. package/dist/addon-vitest/vitest-plugin/index.js +17 -17
  156. package/dist/babel/index.d.ts +91 -842
  157. package/dist/babel/index.js +13 -19
  158. package/dist/bin/core.js +61 -60
  159. package/dist/bin/dispatcher.js +16 -11
  160. package/dist/bin/loader.js +16 -15
  161. package/dist/builder-vite/index.js +15 -15
  162. package/dist/builder-vite/preset.js +13 -13
  163. package/dist/{chunk-Jf7j2Ot0.d.ts → chunk-BGhyFTJO.d.ts} +1 -1
  164. package/dist/{chunk-Ce6uhJuR.d.ts → chunk-B_ZhEPlo.d.ts} +1 -1
  165. package/dist/{chunk-CZHsX9Zo.d.ts → chunk-CMaYrou5.d.ts} +1 -1
  166. package/dist/chunk-CV4-Z2pn.d.ts +30 -0
  167. package/dist/{chunk-B2t1tGRh.d.ts → chunk-CYuvV2sR.d.ts} +11 -13
  168. package/dist/{chunk-DpljNJTz.d.ts → chunk-LrH1y9J2.d.ts} +39 -0
  169. package/dist/cli/index.d.ts +13 -866
  170. package/dist/cli/index.js +42 -4952
  171. package/dist/cli/tools/sdk/child-host.d.ts +1 -1
  172. package/dist/cli/tools/sdk/child-host.js +17 -17
  173. package/dist/cli/tools/sdk/index.d.ts +1 -1
  174. package/dist/cli/tools/sdk/index.js +18 -18
  175. package/dist/cli-commands/bin/index.js +7 -7
  176. package/dist/client-logger/index.js +3 -1
  177. package/dist/common/index.d.ts +5 -4
  178. package/dist/common/index.js +35 -37
  179. package/dist/components/index.d.ts +14 -231
  180. package/dist/components/index.js +2512 -8359
  181. package/dist/core-events/index.d.ts +3 -2
  182. package/dist/core-events/index.js +3 -1
  183. package/dist/core-server/index.d.ts +2 -2
  184. package/dist/core-server/index.js +450 -147
  185. package/dist/core-server/presets/common-manager.js +62 -866
  186. package/dist/core-server/presets/common-override-preset.js +12 -10
  187. package/dist/core-server/presets/common-preset.js +39 -40
  188. package/dist/create/bin/index.js +7 -7
  189. package/dist/create/index.js +15 -15
  190. package/dist/csf/index.d.ts +1 -1
  191. package/dist/csf/index.js +27 -93
  192. package/dist/csf-tools/index.d.ts +14 -12
  193. package/dist/csf-tools/index.js +14 -14
  194. package/dist/instrumenter/index.js +3 -1
  195. package/dist/manager/_manager-chunks/{globals-runtime-BgVwdR45.js → globals-runtime-4fCHtNC6.js} +1 -1
  196. package/dist/manager/_manager-chunks/{globals-runtime-DW1HVuLt.js → globals-runtime-BKPOYSwp.js} +410 -379
  197. package/dist/manager/_manager-chunks/{globals-runtime-zVfMhZAt.js → globals-runtime-BMIT8BJb.js} +1 -1
  198. package/dist/manager/_manager-chunks/{globals-runtime-CUBVmgcG.js → globals-runtime-BO0pfoqL.js} +4 -4
  199. package/dist/manager/_manager-chunks/{globals-runtime-Bke4A4DG.js → globals-runtime-BZKYJxYC.js} +1 -1
  200. package/dist/manager/_manager-chunks/{globals-runtime-D_YKR9nf.js → globals-runtime-Bpc_ftuT.js} +1252 -539
  201. package/dist/manager/_manager-chunks/{globals-runtime-DCOX9nD5.js → globals-runtime-CBviMKtt.js} +1 -17
  202. package/dist/manager/_manager-chunks/{globals-runtime-CTB3rhS1.js → globals-runtime-CI-C7ncS.js} +10 -10
  203. package/dist/manager/_manager-chunks/{globals-runtime-Cr3nYYcT.js → globals-runtime-CI_p54Ha.js} +59 -60
  204. package/dist/manager/_manager-chunks/{globals-runtime-CiLcg4q9.js → globals-runtime-CTyYXvUm.js} +1 -1
  205. package/dist/manager/_manager-chunks/{globals-runtime-DqNrRmOM.js → globals-runtime-CoCzM1V_.js} +93 -2146
  206. package/dist/manager/_manager-chunks/{globals-runtime-CXKb33hg.js → globals-runtime-CzEhVGVp.js} +141 -54
  207. package/dist/manager/_manager-chunks/{globals-runtime-CF4o9_wT.js → globals-runtime-D82vqOGq.js} +2 -1
  208. package/dist/manager/_manager-chunks/{globals-runtime-ALpzCL93.js → globals-runtime-DB8fVA5g.js} +2 -145
  209. package/dist/manager/_manager-chunks/{globals-runtime-DMvB3-IM.js → globals-runtime-DMq1Phbl.js} +153 -141
  210. package/dist/manager/_manager-chunks/globals-runtime-DOPUchia.js +5282 -0
  211. package/dist/manager/_manager-chunks/{globals-runtime-BcNHymiF.js → globals-runtime-Dbt08xWQ.js} +1 -1
  212. package/dist/manager/_manager-chunks/{globals-runtime-m07udJ_K.js → globals-runtime-kmPSyf3j.js} +637 -1730
  213. package/dist/manager/_manager-chunks/{runtime-DMig8mT7.js → runtime-5o_11Jae.js} +4 -3
  214. package/dist/manager/_manager-chunks/{runtime-DrjpEyLM.js → runtime-B4U0u9p4.js} +5 -147
  215. package/dist/manager/_manager-chunks/{runtime-B-eSQdxk.js → runtime-BM30BmeT.js} +503 -44
  216. package/dist/manager/_manager-chunks/{runtime-EITvVbkG.js → runtime-BdGkqNEt.js} +1 -2
  217. package/dist/manager/_manager-chunks/{runtime-a5zd7km2.js → runtime-Cf0p9DUx.js} +5 -531
  218. package/dist/manager/_manager-chunks/{runtime-Cdz2BHhM.js → runtime-D-nYLsdk.js} +57 -34
  219. package/dist/manager/_manager-chunks/runtime-D09XMY6V.js +294 -0
  220. package/dist/manager/_manager-chunks/{runtime-Bldwclun.js → runtime-DvrwKw7z.js} +92 -303
  221. package/dist/manager/_manager-chunks/{runtime-DGHNKNQl.js → runtime-DzxaTqVN.js} +10 -29
  222. package/dist/manager/_manager-chunks/runtime-P663lpsR.js +528 -0
  223. package/dist/manager/_manager-chunks/{runtime-Cmu7D8A0.js → runtime-ecY5qnmo.js} +193 -184
  224. package/dist/manager/globals-runtime.js +1 -1
  225. package/dist/manager/runtime.js +1 -1
  226. package/dist/manager-api/index.d.ts +1 -1
  227. package/dist/manager-api/index.js +22 -28
  228. package/dist/manager-errors.d.ts +1 -1
  229. package/dist/mcp/index.js +8 -8
  230. package/dist/mocking-utils/index.js +16 -11
  231. package/dist/nextjs-vite/index.js +3 -2
  232. package/dist/nextjs-vite/node/index.js +7 -7
  233. package/dist/nextjs-vite/node-stand-ins/index.d.ts +68 -0
  234. package/dist/nextjs-vite/node-stand-ins/index.js +145 -0
  235. package/dist/nextjs-vite/preset.js +93 -14
  236. package/dist/nextjs-vite/vite-plugin/index.js +7 -7
  237. package/dist/nextjs-vite-plugin/index.d.ts +1 -2
  238. package/dist/nextjs-vite-plugin/index.js +12 -27
  239. package/dist/nextjs-vite-plugin/mocks/storybook.global.js +8 -8
  240. package/dist/node-logger/index.d.ts +65 -72
  241. package/dist/node-logger/index.js +11 -12
  242. package/dist/oxc-parser/index.js +11 -13
  243. package/dist/oxc-parser/worker.js +10 -10
  244. package/dist/preview/_chunks/{runtime-DVM_AHbR.js → runtime-6P-h06Te.js} +51 -50
  245. package/dist/preview/_chunks/{runtime-BoxmlDdB.js → runtime-B9KKIDGa.js} +202 -81
  246. package/dist/preview/_chunks/{runtime-BIzIdDbb.js → runtime-BPwAnlRx.js} +482 -334
  247. package/dist/preview/_chunks/{runtime-q3wt0e_N.js → runtime-BUnOhg9h.js} +2 -2
  248. package/dist/preview/_chunks/runtime-Bcv1hJky.js +6305 -0
  249. package/dist/preview/_chunks/{runtime-CqHxptiK.js → runtime-C1jgT6tJ.js} +93 -2145
  250. package/dist/preview/_chunks/{runtime-D7B4bVe_.js → runtime-C8QFpkFV.js} +6 -6
  251. package/dist/preview/_chunks/{runtime-CijtAN7R.js → runtime-DdqR8Fd0.js} +15 -6
  252. package/dist/preview/_chunks/{runtime-B3y8ocOg.js → runtime-DvBfMhis.js} +2 -2
  253. package/dist/preview/_chunks/{runtime-BZSnICCg.js → runtime-WapFVPAh.js} +29 -29
  254. package/dist/preview/runtime.js +1 -1
  255. package/dist/preview-api/index.d.ts +1 -1
  256. package/dist/preview-api/index.js +2 -1
  257. package/dist/preview-errors.d.ts +1 -1
  258. package/dist/react/docgen/docgen-worker.js +11 -12
  259. package/dist/react/entry-preview.js +2 -1
  260. package/dist/react/index.js +6 -4
  261. package/dist/react/preset.js +13 -14
  262. package/dist/react/preview.js +3 -2
  263. package/dist/react-native/bin/get-stories.js +8 -8
  264. package/dist/react-native/index.js +25 -211
  265. package/dist/react-native/metro/node.js +10 -9
  266. package/dist/react-native/metro/withStorybook.js +11 -10
  267. package/dist/react-native/scripts/generate.js +8 -8
  268. package/dist/react-vite/node/index.js +7 -7
  269. package/dist/react-vite/preset.js +7 -7
  270. package/dist/router/index.js +3 -1
  271. package/dist/server-errors.d.ts +1 -1
  272. package/dist/server-errors.js +9 -9
  273. package/dist/shared/open-service/index.d.ts +1 -1
  274. package/dist/shared/open-service/services/docgen/worker/docgen-worker.js +9 -9
  275. package/dist/telemetry/index.js +43 -45
  276. package/dist/test/index.js +808 -573
  277. package/dist/theming/create.js +2 -1
  278. package/dist/theming/index.js +22 -1
  279. package/dist/types/index.d.ts +1 -1
  280. package/package.json +21 -44
  281. package/dist/_browser-chunks/WithTooltip-V55S6YCY.js +0 -1619
  282. package/dist/_browser-chunks/chunk-5P4QA6MY.js +0 -20
  283. package/dist/_browser-chunks/chunk-UDQ3XQFC.js +0 -108
  284. package/dist/_node-chunks/chunk-6QQTZT3Z.js +0 -19
  285. package/dist/_node-chunks/chunk-BRD332PB.js +0 -3008
  286. package/dist/_node-chunks/chunk-E2XKJLXK.js +0 -4731
  287. package/dist/_node-chunks/chunk-F2LQJXAB.js +0 -29
  288. package/dist/_node-chunks/chunk-MCZZMBPA.js +0 -20
  289. package/dist/_node-chunks/chunk-MMFUHYSU.js +0 -23
  290. package/dist/_node-chunks/chunk-UGFY5LEG.js +0 -18
  291. package/dist/_node-chunks/chunk-UO5ZOCSQ.js +0 -662
  292. package/dist/_node-chunks/chunk-UW35FCXF.js +0 -20
  293. package/dist/_node-chunks/chunk-VMUXW2E2.js +0 -5414
  294. package/dist/_node-chunks/chunk-VNXE7UJL.js +0 -51
  295. package/dist/_node-chunks/chunk-VRJJ43P2.js +0 -11
  296. package/dist/_node-chunks/chunk-WCJUS7OC.js +0 -1877
  297. package/dist/_node-chunks/chunk-WMBMSNB7.js +0 -36
  298. package/dist/_node-chunks/chunk-YV2QBXU6.js +0 -3823
  299. package/dist/_node-chunks/chunk-ZZNBVMBU.js +0 -25
  300. package/dist/_node-chunks/dist-VFUGPNLK.js +0 -16
  301. package/dist/_node-chunks/globby-N7LO32D3.js +0 -2884
  302. package/dist/_node-chunks/jiti-SJDZ7LQB.js +0 -3848
  303. package/dist/_node-chunks/lib-4HD6QL5R.js +0 -366
  304. package/dist/_node-chunks/optimized-tests-LVKXZ3HQ.js +0 -22
  305. package/dist/_node-chunks/postinstallAddon-I6MAL6PW.js +0 -20
  306. package/dist/_node-chunks/session-id-6Z2RXBTG.js +0 -23
  307. package/dist/chunk-BfBzpgct.d.ts +0 -916
  308. package/dist/core-server/presets/common-manager.css +0 -170
  309. package/dist/manager/_manager-chunks/globals-runtime-Bon7UvQk.js +0 -9766
  310. package/dist/manager/_manager-chunks/globals-runtime-DDOIxI_l.js +0 -1584
  311. package/dist/manager/_manager-chunks/runtime-CuJiHYCp.js +0 -22
  312. package/dist/manager/_manager-chunks/runtime-DFhLVh8q.js +0 -456
  313. package/dist/preview/_chunks/runtime-BTPtVY1p.js +0 -1102
  314. package/dist/preview/_chunks/runtime-DZToXfvO.js +0 -9767
@@ -0,0 +1,1149 @@
1
+ import {
2
+ ARROW_DOWN,
3
+ ARROW_LEFT,
4
+ ARROW_RIGHT,
5
+ ARROW_UP,
6
+ COMPOSITE_KEYS,
7
+ CompositeRootContext,
8
+ EMPTY_ARRAY,
9
+ EMPTY_OBJECT,
10
+ END,
11
+ HOME,
12
+ MODIFIER_KEYS,
13
+ TransitionStatusDataAttributes_exports,
14
+ activeElement,
15
+ contains,
16
+ createChangeEventDetails,
17
+ error,
18
+ findNonDisabledListIndex,
19
+ formatErrorMessage_default,
20
+ getCssDimensions,
21
+ getMaxListIndex,
22
+ getMinListIndex,
23
+ getParentNode,
24
+ getTarget,
25
+ getWindow,
26
+ inertValue,
27
+ isHTMLElement,
28
+ isIndexOutOfListBounds,
29
+ isLastTraversableNode,
30
+ isListIndexDisabled,
31
+ isNativeInput,
32
+ isReactVersionAtLeast,
33
+ ownerDocument,
34
+ reason_parts_exports,
35
+ scrollIntoViewIfNeeded,
36
+ transitionStatusMapping,
37
+ useBaseUiId,
38
+ useButton,
39
+ useCompositeRootContext,
40
+ useDirection,
41
+ useForcedRerendering,
42
+ useIsoLayoutEffect,
43
+ useMergedRefs,
44
+ useOpenChangeComplete,
45
+ useRefWithInit,
46
+ useRenderElement,
47
+ useStableCallback,
48
+ useSyncExternalStore,
49
+ useTransitionStatus
50
+ } from "./chunk-DAUHYZUB.js";
51
+ import {
52
+ __export
53
+ } from "./chunk-IMSF75WX.js";
54
+
55
+ // ../../node_modules/@base-ui/react/tabs/index.parts.mjs
56
+ var index_parts_exports = {};
57
+ __export(index_parts_exports, {
58
+ Indicator: () => TabsIndicator,
59
+ List: () => TabsList,
60
+ Panel: () => TabsPanel,
61
+ Root: () => TabsRoot,
62
+ Tab: () => TabsTab
63
+ });
64
+
65
+ // ../../node_modules/@base-ui/react/tabs/root/TabsRoot.mjs
66
+ import * as React5 from "react";
67
+
68
+ // ../../node_modules/@base-ui/utils/useControlled.mjs
69
+ import * as React from "react";
70
+ function useControlled({
71
+ controlled,
72
+ default: defaultProp,
73
+ name,
74
+ state = "value"
75
+ }) {
76
+ let {
77
+ current: isControlled
78
+ } = React.useRef(controlled !== void 0), [valueState, setValue] = React.useState(() => defaultProp), value = isControlled && controlled !== void 0 ? controlled : valueState;
79
+ if (process.env.NODE_ENV !== "production") {
80
+ React.useEffect(() => {
81
+ isControlled !== (controlled !== void 0) && error([`A component is changing the ${isControlled ? "" : "un"}controlled ${state} state of ${name} to be ${isControlled ? "un" : ""}controlled.`, "Elements should not switch from uncontrolled to controlled (or vice versa).", `Decide between using a controlled or uncontrolled ${name} element for the lifetime of the component.`, "The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.", "More info: https://fb.me/react-controlled-components"].join(`
82
+ `));
83
+ }, [state, name, controlled]);
84
+ let {
85
+ current: defaultValue
86
+ } = React.useRef(defaultProp);
87
+ React.useEffect(() => {
88
+ !isControlled && serializeToDevModeString(defaultValue) !== serializeToDevModeString(defaultProp) && error([`A component is changing the default ${state} state of an uncontrolled ${name} after being initialized. To suppress this warning opt to use a controlled ${name}.`].join(`
89
+ `));
90
+ }, [defaultProp]);
91
+ }
92
+ let setValueIfUncontrolled = React.useCallback((newValue) => {
93
+ isControlled || setValue(newValue);
94
+ }, []);
95
+ return [value, setValueIfUncontrolled];
96
+ }
97
+ function serializeToDevModeString(input) {
98
+ let nextId = 0, seen = /* @__PURE__ */ new WeakMap();
99
+ try {
100
+ return JSON.stringify(input, function(key, value) {
101
+ if (!(key === "_owner" && this != null && typeof this == "object" && "$$typeof" in this)) {
102
+ if (typeof value == "bigint")
103
+ return `__bigint__:${value}`;
104
+ if (value !== null && typeof value == "object") {
105
+ let id = seen.get(value);
106
+ if (id !== void 0)
107
+ return `__object__:${id}`;
108
+ seen.set(value, nextId), nextId += 1;
109
+ }
110
+ return value;
111
+ }
112
+ }) ?? `__top__:${typeof input}`;
113
+ } catch {
114
+ return "__unserializable__";
115
+ }
116
+ }
117
+
118
+ // ../../node_modules/@base-ui/react/internals/composite/list/CompositeList.mjs
119
+ import * as React3 from "react";
120
+
121
+ // ../../node_modules/@base-ui/react/internals/composite/list/CompositeListContext.mjs
122
+ import * as React2 from "react";
123
+ var CompositeListContext = React2.createContext({
124
+ register: () => {
125
+ },
126
+ unregister: () => {
127
+ },
128
+ subscribeMapChange: () => () => {
129
+ },
130
+ nextIndexRef: {
131
+ current: 0
132
+ }
133
+ });
134
+ process.env.NODE_ENV !== "production" && (CompositeListContext.displayName = "CompositeListContext");
135
+ function useCompositeListContext() {
136
+ return React2.useContext(CompositeListContext);
137
+ }
138
+
139
+ // ../../node_modules/@base-ui/react/internals/composite/list/CompositeList.mjs
140
+ import { jsx as _jsx } from "react/jsx-runtime";
141
+ function CompositeList(props) {
142
+ let {
143
+ children,
144
+ elementsRef,
145
+ labelsRef,
146
+ onMapChange: onMapChangeProp
147
+ } = props, onMapChange = useStableCallback(onMapChangeProp), [, setMapTick] = React3.useState(0), listeners = useRefWithInit(createListeners).current, map = useRefWithInit(createMap).current, nextIndexRef = React3.useRef(0), isDirtyRef = React3.useRef(!0), itemsRef = React3.useRef(null), mutationObserverRef = React3.useRef(null), scheduleMapUpdate = useStableCallback(() => {
148
+ isDirtyRef.current || (isDirtyRef.current = !0, setMapTick((tick) => tick + 1));
149
+ }), register = useStableCallback((node, registration) => {
150
+ map.set(node, registration), scheduleMapUpdate();
151
+ }), unregister = useStableCallback((node) => {
152
+ map.delete(node), scheduleMapUpdate();
153
+ }), syncRefs = useStableCallback((items) => {
154
+ let nextMap = /* @__PURE__ */ new Map();
155
+ return elementsRef.current.length = 0, labelsRef && (labelsRef.current.length = 0), items.forEach((item) => {
156
+ nextMap.set(item.element, {
157
+ ...item.registration.metadata ?? {},
158
+ index: item.index
159
+ }), elementsRef.current[item.index] = item.element, labelsRef && (labelsRef.current[item.index] = item.registration.label !== void 0 ? item.registration.label : item.registration.textRef?.current?.textContent ?? item.element.textContent);
160
+ }), nextIndexRef.current = elementsRef.current.length, nextMap;
161
+ });
162
+ function observe(sortedNodes) {
163
+ if (mutationObserverRef.current?.disconnect(), mutationObserverRef.current = null, typeof MutationObserver != "function" || sortedNodes.length < 2)
164
+ return;
165
+ let mutationObserver = new MutationObserver((entries) => {
166
+ if (!hasMovedNode(entries))
167
+ return;
168
+ let previousConnectedNode = null;
169
+ for (let node of sortedNodes)
170
+ if (node.isConnected) {
171
+ if (previousConnectedNode && sortByDocumentPosition(previousConnectedNode, node) > 0) {
172
+ mutationObserver.disconnect(), scheduleMapUpdate();
173
+ return;
174
+ }
175
+ previousConnectedNode = node;
176
+ }
177
+ });
178
+ mutationObserverRef.current = mutationObserver;
179
+ let roots = /* @__PURE__ */ new Set();
180
+ for (let i = 1; i < sortedNodes.length; i += 1) {
181
+ let root = getCommonAncestor(sortedNodes[i - 1], sortedNodes[i]);
182
+ root && roots.add(root);
183
+ }
184
+ roots.forEach((root) => mutationObserver.observe(root, {
185
+ childList: !0
186
+ }));
187
+ }
188
+ let flush = useStableCallback(() => {
189
+ let [items, automaticNodes] = getCompositeListSnapshot(map), nextMap = syncRefs(items), previousItems = itemsRef.current, changed = !previousItems || previousItems.length !== items.length || items.some((item, index2) => {
190
+ let previousItem = previousItems[index2];
191
+ return item.index !== previousItem.index || item.element !== previousItem.element || item.registration.index !== previousItem.registration.index || item.registration.metadata !== previousItem.registration.metadata;
192
+ });
193
+ observe(automaticNodes), itemsRef.current = items, isDirtyRef.current = !1, changed && (listeners.forEach((listener) => listener(nextMap)), onMapChange(nextMap));
194
+ });
195
+ useIsoLayoutEffect(() => (!isDirtyRef.current && itemsRef.current && syncRefs(itemsRef.current), () => {
196
+ elementsRef.current = [], labelsRef && (labelsRef.current = []);
197
+ }), [elementsRef, labelsRef, syncRefs]), useIsoLayoutEffect(() => {
198
+ isDirtyRef.current && flush();
199
+ }), useIsoLayoutEffect(() => () => {
200
+ mutationObserverRef.current?.disconnect(), isDirtyRef.current = !0;
201
+ }, []);
202
+ let subscribeMapChange = useStableCallback((fn) => (listeners.add(fn), () => {
203
+ listeners.delete(fn);
204
+ })), contextValue = React3.useMemo(() => ({
205
+ register,
206
+ unregister,
207
+ subscribeMapChange,
208
+ nextIndexRef
209
+ }), [register, unregister, subscribeMapChange, nextIndexRef]);
210
+ return _jsx(CompositeListContext.Provider, {
211
+ value: contextValue,
212
+ children
213
+ });
214
+ }
215
+ function createMap() {
216
+ return /* @__PURE__ */ new Map();
217
+ }
218
+ function createListeners() {
219
+ return /* @__PURE__ */ new Set();
220
+ }
221
+ function getCompositeListSnapshot(map) {
222
+ let reservedIndices = /* @__PURE__ */ new Set(), items = [], automaticItems = [];
223
+ map.forEach((registration, node) => {
224
+ if (!node.isConnected)
225
+ return;
226
+ let index2 = registration.index, item = {
227
+ index: index2 ?? -1,
228
+ element: node,
229
+ registration
230
+ };
231
+ index2 === null ? automaticItems.push(item) : index2 >= 0 && (reservedIndices.add(index2), items.push(item));
232
+ });
233
+ let nextAutomaticIndex = 0;
234
+ return automaticItems.sort((a, b) => sortByDocumentPosition(a.element, b.element)), automaticItems.forEach((item) => {
235
+ for (; reservedIndices.has(nextAutomaticIndex); )
236
+ nextAutomaticIndex += 1;
237
+ item.index = nextAutomaticIndex, items.push(item), nextAutomaticIndex += 1;
238
+ }), reservedIndices.size > 0 && items.sort((a, b) => a.index - b.index), [items, automaticItems.map((item) => item.element)];
239
+ }
240
+ function getCommonAncestor(firstNode, lastNode) {
241
+ let ancestor = firstNode.parentElement;
242
+ for (; ancestor && !ancestor.contains(lastNode); )
243
+ ancestor = ancestor.parentElement;
244
+ return ancestor;
245
+ }
246
+ function hasMovedNode(entries) {
247
+ for (let entry of entries)
248
+ for (let i = 0; i < entry.removedNodes.length; i += 1)
249
+ if (entry.removedNodes[i].isConnected)
250
+ return !0;
251
+ return !1;
252
+ }
253
+ function sortByDocumentPosition(a, b) {
254
+ return a.nextElementSibling === b ? -1 : b.nextElementSibling === a ? 1 : a.compareDocumentPosition(b) & Node.DOCUMENT_POSITION_FOLLOWING ? -1 : 1;
255
+ }
256
+
257
+ // ../../node_modules/@base-ui/react/tabs/root/TabsRootContext.mjs
258
+ import * as React4 from "react";
259
+ var TabsRootContext = React4.createContext(void 0);
260
+ process.env.NODE_ENV !== "production" && (TabsRootContext.displayName = "TabsRootContext");
261
+ function useTabsRootContext() {
262
+ let context = React4.useContext(TabsRootContext);
263
+ if (context === void 0)
264
+ throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: TabsRootContext is missing. Tabs parts must be placed within <Tabs.Root>." : formatErrorMessage_default(64));
265
+ return context;
266
+ }
267
+
268
+ // ../../node_modules/@base-ui/react/tabs/root/TabsRootDataAttributes.mjs
269
+ var activationDirection = "data-activation-direction";
270
+
271
+ // ../../node_modules/@base-ui/react/tabs/root/stateAttributesMapping.mjs
272
+ var tabsStateAttributesMapping = {
273
+ tabActivationDirection: (dir) => ({
274
+ [activationDirection]: dir
275
+ })
276
+ };
277
+
278
+ // ../../node_modules/@base-ui/react/tabs/root/TabsRoot.mjs
279
+ import { jsx as _jsx2 } from "react/jsx-runtime";
280
+ var TabsRoot = React5.forwardRef(function(componentProps, forwardedRef) {
281
+ let {
282
+ className,
283
+ defaultValue: defaultValueProp = 0,
284
+ onValueChange: onValueChangeProp,
285
+ orientation = "horizontal",
286
+ render,
287
+ value: valueProp,
288
+ style,
289
+ ...elementProps
290
+ } = componentProps, hasExplicitDefaultValueProp = componentProps.defaultValue !== void 0, tabPanelRefs = React5.useRef([]), [mountedTabPanels, setMountedTabPanels] = React5.useState(() => /* @__PURE__ */ new Map()), [value, setValue] = useControlled({
291
+ controlled: valueProp,
292
+ default: defaultValueProp,
293
+ name: "Tabs",
294
+ state: "value"
295
+ }), isControlled = valueProp !== void 0, [tabMap, setTabMap] = React5.useState(() => /* @__PURE__ */ new Map()), lastKnownTabElementRef = React5.useRef(void 0), getTabElementBySelectedValue = React5.useCallback((selectedValue) => findTabElement(tabMap, selectedValue), [tabMap]), [activationDirectionState, setActivationDirectionState] = React5.useState(() => ({
296
+ previousValue: value,
297
+ tabActivationDirection: "none"
298
+ })), {
299
+ previousValue,
300
+ tabActivationDirection: committedTabActivationDirection
301
+ } = activationDirectionState, tabActivationDirection = committedTabActivationDirection, directionComputationIncomplete = !1;
302
+ previousValue !== value && (tabActivationDirection = computeActivationDirection(previousValue, value, orientation, tabMap), directionComputationIncomplete = previousValue != null && value != null && getTabElementBySelectedValue(value) == null);
303
+ let nextPreviousValue = directionComputationIncomplete ? previousValue : value, shouldSyncActivationDirectionState = previousValue !== nextPreviousValue || committedTabActivationDirection !== tabActivationDirection;
304
+ useIsoLayoutEffect(() => {
305
+ shouldSyncActivationDirectionState && setActivationDirectionState({
306
+ previousValue: nextPreviousValue,
307
+ tabActivationDirection
308
+ });
309
+ }, [nextPreviousValue, shouldSyncActivationDirectionState, tabActivationDirection]);
310
+ let onValueChange = useStableCallback((newValue, eventDetails) => {
311
+ let activationDirection2 = computeActivationDirection(value, newValue, orientation, tabMap);
312
+ eventDetails.activationDirection = activationDirection2, onValueChangeProp?.(newValue, eventDetails), !eventDetails.isCanceled && setValue(() => newValue);
313
+ }), notifyAutomaticValueChange = useStableCallback((nextValue, reason) => {
314
+ onValueChangeProp?.(nextValue, createChangeEventDetails(reason, void 0, void 0, {
315
+ activationDirection: "none"
316
+ }));
317
+ }), registerMountedTabPanel = useStableCallback((panelValue, panelId) => (setMountedTabPanels((prev) => {
318
+ let next = new Map(prev);
319
+ return next.set(panelValue, panelId), next;
320
+ }), () => {
321
+ setMountedTabPanels((prev) => {
322
+ if (prev.get(panelValue) !== panelId)
323
+ return prev;
324
+ let next = new Map(prev);
325
+ return next.delete(panelValue), next;
326
+ });
327
+ })), getTabPanelIdByValue = React5.useCallback((tabValue) => mountedTabPanels.get(tabValue), [mountedTabPanels]), getTabIdByPanelValue = React5.useCallback((tabPanelValue) => {
328
+ for (let tabMetadata of tabMap.values())
329
+ if (tabPanelValue === tabMetadata.value)
330
+ return tabMetadata.id;
331
+ }, [tabMap]), tabsContextValue = React5.useMemo(() => ({
332
+ getTabElementBySelectedValue,
333
+ getTabIdByPanelValue,
334
+ getTabPanelIdByValue,
335
+ onValueChange,
336
+ orientation,
337
+ registerMountedTabPanel,
338
+ setTabMap,
339
+ tabActivationDirection,
340
+ value
341
+ }), [getTabElementBySelectedValue, getTabIdByPanelValue, getTabPanelIdByValue, onValueChange, orientation, registerMountedTabPanel, setTabMap, tabActivationDirection, value]), selectedTabMetadata = React5.useMemo(() => {
342
+ for (let tabMetadata of tabMap.values())
343
+ if (tabMetadata.value === value)
344
+ return tabMetadata;
345
+ }, [tabMap, value]), firstEnabledTabValue = React5.useMemo(() => {
346
+ for (let tabMetadata of tabMap.values())
347
+ if (!tabMetadata.disabled)
348
+ return tabMetadata.value;
349
+ }, [tabMap]), shouldNotifyInitialValueChangeRef = React5.useRef(!hasExplicitDefaultValueProp), initialDefaultValueRef = React5.useRef(defaultValueProp), shouldHonorDisabledDefaultValueRef = React5.useRef(hasExplicitDefaultValueProp), didRegisterTabsRef = React5.useRef(!1);
350
+ useIsoLayoutEffect(() => {
351
+ if (isControlled)
352
+ return;
353
+ function commitAutomaticValueChange(fallbackValue, fallbackReason) {
354
+ setValue(() => fallbackValue), setActivationDirectionState({
355
+ previousValue: fallbackValue,
356
+ tabActivationDirection: "none"
357
+ }), notifyAutomaticValueChange(fallbackValue, fallbackReason), shouldNotifyInitialValueChangeRef.current = !1;
358
+ }
359
+ if (tabMap.size === 0) {
360
+ didRegisterTabsRef.current && value !== null && !lastKnownTabElementRef.current?.isConnected && commitAutomaticValueChange(null, reason_parts_exports.missing);
361
+ return;
362
+ }
363
+ didRegisterTabsRef.current = !0, lastKnownTabElementRef.current = tabMap.keys().next().value;
364
+ let selectionIsDisabled = selectedTabMetadata?.disabled, selectionIsMissing = selectedTabMetadata == null && value !== null;
365
+ if (!selectionIsDisabled && value === initialDefaultValueRef.current && (shouldHonorDisabledDefaultValueRef.current = !1), shouldHonorDisabledDefaultValueRef.current && selectionIsDisabled && value === initialDefaultValueRef.current)
366
+ return;
367
+ let shouldNotifyInitialValueChange = shouldNotifyInitialValueChangeRef.current;
368
+ if (selectionIsDisabled || selectionIsMissing) {
369
+ let fallbackValue = firstEnabledTabValue ?? null;
370
+ if (value === fallbackValue) {
371
+ shouldNotifyInitialValueChangeRef.current = !1;
372
+ return;
373
+ }
374
+ let fallbackReason = reason_parts_exports.missing;
375
+ shouldNotifyInitialValueChange ? fallbackReason = reason_parts_exports.initial : selectionIsDisabled && (fallbackReason = reason_parts_exports.disabled), commitAutomaticValueChange(fallbackValue, fallbackReason);
376
+ return;
377
+ }
378
+ shouldNotifyInitialValueChange && selectedTabMetadata != null && (notifyAutomaticValueChange(value, reason_parts_exports.initial), shouldNotifyInitialValueChangeRef.current = !1);
379
+ }, [firstEnabledTabValue, isControlled, notifyAutomaticValueChange, selectedTabMetadata, setValue, tabMap, value]);
380
+ let element = useRenderElement("div", componentProps, {
381
+ state: {
382
+ orientation,
383
+ tabActivationDirection
384
+ },
385
+ ref: forwardedRef,
386
+ props: elementProps,
387
+ stateAttributesMapping: tabsStateAttributesMapping
388
+ });
389
+ return _jsx2(TabsRootContext.Provider, {
390
+ value: tabsContextValue,
391
+ children: _jsx2(CompositeList, {
392
+ elementsRef: tabPanelRefs,
393
+ children: element
394
+ })
395
+ });
396
+ });
397
+ process.env.NODE_ENV !== "production" && (TabsRoot.displayName = "TabsRoot");
398
+ function findTabElement(tabMap, value) {
399
+ for (let [tabElement, tabMetadata] of tabMap.entries())
400
+ if (value === tabMetadata.value)
401
+ return tabElement;
402
+ return null;
403
+ }
404
+ function computeActivationDirection(oldValue, newValue, orientation, tabMap) {
405
+ if (oldValue == null || newValue == null)
406
+ return "none";
407
+ let [positionProp, backward, forward] = orientation === "horizontal" ? ["left", "left", "right"] : ["top", "up", "down"], oldTab = findTabElement(tabMap, oldValue), newTab = findTabElement(tabMap, newValue);
408
+ if (oldTab == null || newTab == null)
409
+ return oldTab !== newTab && (typeof oldValue == "number" || typeof oldValue == "string") && typeof oldValue == typeof newValue ? newValue > oldValue ? forward : backward : "none";
410
+ let oldPosition = oldTab.getBoundingClientRect()[positionProp], newPosition = newTab.getBoundingClientRect()[positionProp];
411
+ return newPosition < oldPosition ? backward : newPosition > oldPosition ? forward : "none";
412
+ }
413
+
414
+ // ../../node_modules/@base-ui/react/tabs/tab/TabsTab.mjs
415
+ import * as React9 from "react";
416
+
417
+ // ../../node_modules/@base-ui/react/internals/composite/constants.mjs
418
+ var ACTIVE_COMPOSITE_ITEM = "data-composite-item-active";
419
+
420
+ // ../../node_modules/@base-ui/react/internals/composite/item/useCompositeItem.mjs
421
+ import * as React7 from "react";
422
+
423
+ // ../../node_modules/@base-ui/react/internals/composite/list/useCompositeListItem.mjs
424
+ import * as React6 from "react";
425
+ function useCompositeListItem(params = {}) {
426
+ let {
427
+ guess,
428
+ label,
429
+ metadata,
430
+ textRef,
431
+ index: externalIndex
432
+ } = params, {
433
+ register,
434
+ unregister,
435
+ subscribeMapChange,
436
+ nextIndexRef
437
+ } = useCompositeListContext(), indexRef = React6.useRef(-1), [internalIndex, setInternalIndex] = React6.useState(externalIndex == null && guess ? () => {
438
+ if (indexRef.current === -1) {
439
+ let newIndex = nextIndexRef.current;
440
+ nextIndexRef.current += 1, indexRef.current = newIndex;
441
+ }
442
+ return indexRef.current;
443
+ } : -1), index2 = externalIndex ?? internalIndex, componentRef = React6.useRef(null), ref = React6.useCallback((node) => {
444
+ let previousNode = componentRef.current;
445
+ previousNode && unregister(previousNode), componentRef.current = node, node && register(node, {
446
+ metadata: metadata ?? null,
447
+ index: externalIndex ?? null,
448
+ label,
449
+ textRef
450
+ });
451
+ }, [externalIndex, register, unregister, metadata, label, textRef]);
452
+ return useIsoLayoutEffect(() => {
453
+ if (externalIndex == null)
454
+ return subscribeMapChange((map) => {
455
+ let i = componentRef.current ? map.get(componentRef.current)?.index : null;
456
+ i != null && setInternalIndex(i);
457
+ });
458
+ }, [externalIndex, subscribeMapChange]), {
459
+ ref,
460
+ index: index2
461
+ };
462
+ }
463
+
464
+ // ../../node_modules/@base-ui/react/internals/composite/item/useCompositeItem.mjs
465
+ function useCompositeItem(params = {}) {
466
+ let {
467
+ highlightItemOnHover,
468
+ highlightedIndex,
469
+ onHighlightedIndexChange
470
+ } = useCompositeRootContext(), {
471
+ ref,
472
+ index: index2
473
+ } = useCompositeListItem(params), isHighlighted = highlightedIndex === index2, itemRef = React7.useRef(null), mergedRef = useMergedRefs(ref, itemRef);
474
+ return {
475
+ compositeProps: {
476
+ tabIndex: isHighlighted ? 0 : -1,
477
+ onFocus() {
478
+ onHighlightedIndexChange(index2);
479
+ },
480
+ onMouseMove() {
481
+ let item = itemRef.current;
482
+ if (!highlightItemOnHover || !item)
483
+ return;
484
+ let disabled = item.hasAttribute("disabled") || item.ariaDisabled === "true";
485
+ !isHighlighted && !disabled && item.focus();
486
+ }
487
+ },
488
+ compositeRef: mergedRef,
489
+ index: index2
490
+ };
491
+ }
492
+
493
+ // ../../node_modules/@base-ui/react/tabs/list/TabsListContext.mjs
494
+ import * as React8 from "react";
495
+ var TabsListContext = React8.createContext(void 0);
496
+ process.env.NODE_ENV !== "production" && (TabsListContext.displayName = "TabsListContext");
497
+ function useTabsListContext() {
498
+ let context = React8.useContext(TabsListContext);
499
+ if (context === void 0)
500
+ throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: TabsListContext is missing. TabsList parts must be placed within <Tabs.List>." : formatErrorMessage_default(65));
501
+ return context;
502
+ }
503
+
504
+ // ../../node_modules/@base-ui/react/tabs/tab/TabsTab.mjs
505
+ var TabsTab = React9.forwardRef(function(componentProps, forwardedRef) {
506
+ let {
507
+ className,
508
+ disabled = !1,
509
+ render,
510
+ value,
511
+ id: idProp,
512
+ nativeButton = !0,
513
+ style,
514
+ ...elementProps
515
+ } = componentProps, {
516
+ value: activeTabValue,
517
+ getTabPanelIdByValue,
518
+ onValueChange,
519
+ orientation,
520
+ tabActivationDirection
521
+ } = useTabsRootContext(), {
522
+ activateOnFocus,
523
+ registerTabResizeObserverElement,
524
+ tabsListElement
525
+ } = useTabsListContext(), {
526
+ highlightedIndex,
527
+ onHighlightedIndexChange
528
+ } = useCompositeRootContext(), id = useBaseUiId(idProp), tabMetadata = React9.useMemo(() => ({
529
+ disabled,
530
+ id,
531
+ value
532
+ }), [disabled, id, value]), {
533
+ compositeProps,
534
+ compositeRef,
535
+ index: index2
536
+ // hook is used instead of the CompositeItem component
537
+ // because the index is needed for Tab internals
538
+ } = useCompositeItem({
539
+ metadata: tabMetadata
540
+ }), active = value === activeTabValue, isNavigatingRef = React9.useRef(!1), unobserveTabElementRef = React9.useRef(null), observeTabElement = useStableCallback((element2) => {
541
+ unobserveTabElementRef.current?.(), unobserveTabElementRef.current = element2 ? registerTabResizeObserverElement(element2) : null;
542
+ });
543
+ useIsoLayoutEffect(() => {
544
+ if (isNavigatingRef.current) {
545
+ isNavigatingRef.current = !1;
546
+ return;
547
+ }
548
+ if (!(active && index2 > -1 && highlightedIndex !== index2))
549
+ return;
550
+ let listElement = tabsListElement;
551
+ if (listElement != null) {
552
+ let activeEl = activeElement(ownerDocument(listElement));
553
+ if (activeEl && contains(listElement, activeEl))
554
+ return;
555
+ }
556
+ disabled || onHighlightedIndexChange(index2);
557
+ }, [active, index2, highlightedIndex, onHighlightedIndexChange, disabled, tabsListElement]);
558
+ let {
559
+ getButtonProps,
560
+ buttonRef
561
+ } = useButton({
562
+ disabled,
563
+ native: nativeButton,
564
+ focusableWhenDisabled: !0
565
+ }), tabPanelId = getTabPanelIdByValue(value), isPressingRef = React9.useRef(!1), isMainButtonRef = React9.useRef(!1);
566
+ function activate(event) {
567
+ onValueChange(value, createChangeEventDetails(reason_parts_exports.none, event.nativeEvent, void 0, {
568
+ activationDirection: "none"
569
+ }));
570
+ }
571
+ function onClick(event) {
572
+ active || disabled || activate(event);
573
+ }
574
+ function onFocus(event) {
575
+ active || disabled || activateOnFocus && (!isPressingRef.current || // keyboard or touch focus
576
+ isMainButtonRef.current) && activate(event);
577
+ }
578
+ function onPointerDown(event) {
579
+ if (active || disabled)
580
+ return;
581
+ isPressingRef.current = !0, isMainButtonRef.current = event.button === 0;
582
+ let doc = ownerDocument(event.currentTarget);
583
+ function handlePointerEnd() {
584
+ isPressingRef.current = !1, isMainButtonRef.current = !1, doc.removeEventListener("pointerup", handlePointerEnd), doc.removeEventListener("pointercancel", handlePointerEnd);
585
+ }
586
+ doc.addEventListener("pointerup", handlePointerEnd), doc.addEventListener("pointercancel", handlePointerEnd);
587
+ }
588
+ return useRenderElement("button", componentProps, {
589
+ state: {
590
+ disabled,
591
+ active,
592
+ orientation,
593
+ tabActivationDirection
594
+ },
595
+ ref: [forwardedRef, buttonRef, compositeRef, observeTabElement],
596
+ props: [compositeProps, {
597
+ role: "tab",
598
+ "aria-controls": tabPanelId,
599
+ "aria-selected": active,
600
+ id,
601
+ onClick,
602
+ onFocus,
603
+ onPointerDown,
604
+ [ACTIVE_COMPOSITE_ITEM]: active ? "" : void 0,
605
+ onKeyDownCapture() {
606
+ isNavigatingRef.current = !0;
607
+ }
608
+ }, elementProps, getButtonProps],
609
+ stateAttributesMapping: tabsStateAttributesMapping
610
+ });
611
+ });
612
+ process.env.NODE_ENV !== "production" && (TabsTab.displayName = "TabsTab");
613
+
614
+ // ../../node_modules/@base-ui/react/tabs/indicator/TabsIndicator.mjs
615
+ import * as React13 from "react";
616
+
617
+ // ../../node_modules/@base-ui/react/internals/PrehydrationScript.mjs
618
+ import "react";
619
+
620
+ // ../../node_modules/@base-ui/utils/hydration.mjs
621
+ import * as React10 from "react";
622
+ var emptySubscribe = () => () => {
623
+ }, getTrue = () => !0, getFalse = () => !1;
624
+ function useIsHydratedModern() {
625
+ return useSyncExternalStore(emptySubscribe, getTrue, getFalse);
626
+ }
627
+ function useIsHydratedLegacy() {
628
+ let [hydrated, setHydrated] = React10.useState(!1);
629
+ return React10.useEffect(() => {
630
+ setHydrated(!0);
631
+ }, []), hydrated;
632
+ }
633
+ var useIsHydrated = isReactVersionAtLeast(18) ? useIsHydratedModern : useIsHydratedLegacy;
634
+ function useIsHydrating() {
635
+ return !useIsHydrated();
636
+ }
637
+
638
+ // ../../node_modules/@base-ui/react/internals/csp-context/CSPContext.mjs
639
+ import * as React11 from "react";
640
+ var CSPContext = React11.createContext(void 0);
641
+ process.env.NODE_ENV !== "production" && (CSPContext.displayName = "CSPContext");
642
+ var DEFAULT_CSP_CONTEXT_VALUE = {
643
+ disableStyleElements: !1
644
+ };
645
+ function useCSPContext() {
646
+ return React11.useContext(CSPContext) ?? DEFAULT_CSP_CONTEXT_VALUE;
647
+ }
648
+
649
+ // ../../node_modules/@base-ui/react/internals/PrehydrationScript.mjs
650
+ import { jsx as _jsx3 } from "react/jsx-runtime";
651
+ function PrehydrationScript(props) {
652
+ let {
653
+ script: script2
654
+ } = props, {
655
+ nonce
656
+ } = useCSPContext();
657
+ return useIsHydrating() ? _jsx3("script", {
658
+ nonce,
659
+ dangerouslySetInnerHTML: {
660
+ __html: script2
661
+ },
662
+ suppressHydrationWarning: !0
663
+ }) : null;
664
+ }
665
+
666
+ // ../../node_modules/@base-ui/react/utils/getElementTransform.mjs
667
+ function getElementTransform(element, computedStyle) {
668
+ let transform = (computedStyle ?? getWindow(element).getComputedStyle(element)).transform, translateX = 0, translateY = 0, scale = 1;
669
+ if (transform && transform !== "none") {
670
+ let matrix = transform.match(/matrix(?:3d)?\(([^)]+)\)/);
671
+ if (matrix) {
672
+ let values = matrix[1].split(", ").map(parseFloat);
673
+ values.length === 6 ? (translateX = values[4], translateY = values[5], scale = Math.sqrt(values[0] * values[0] + values[1] * values[1])) : values.length === 16 && (translateX = values[12], translateY = values[13], scale = values[0]);
674
+ }
675
+ }
676
+ return {
677
+ x: translateX,
678
+ y: translateY,
679
+ scale
680
+ };
681
+ }
682
+
683
+ // ../../node_modules/@base-ui/react/tabs/indicator/TabsIndicatorCssVars.mjs
684
+ var activeTabLeft = "--active-tab-left", activeTabRight = "--active-tab-right", activeTabTop = "--active-tab-top", activeTabBottom = "--active-tab-bottom", activeTabWidth = "--active-tab-width", activeTabHeight = "--active-tab-height";
685
+
686
+ // ../../node_modules/@base-ui/react/tabs/indicator/TabsIndicator.mjs
687
+ import { jsx as _jsx4, jsxs as _jsxs } from "react/jsx-runtime";
688
+ var _PrehydrationScript, stateAttributesMapping = {
689
+ ...tabsStateAttributesMapping,
690
+ activeTabPosition: () => null,
691
+ activeTabSize: () => null
692
+ }, MAX_LAYOUT_ROUNDING_ERROR = 2, TabsIndicator = React13.forwardRef(function(componentProps, forwardedRef) {
693
+ let {
694
+ className,
695
+ render,
696
+ renderBeforeHydration = !1,
697
+ style: styleProp,
698
+ ...elementProps
699
+ } = componentProps, {
700
+ getTabElementBySelectedValue,
701
+ orientation,
702
+ tabActivationDirection,
703
+ value
704
+ } = useTabsRootContext(), {
705
+ tabsListElement,
706
+ registerIndicatorUpdateListener
707
+ } = useTabsListContext(), rerender = useForcedRerendering();
708
+ React13.useEffect(() => registerIndicatorUpdateListener(rerender), [registerIndicatorUpdateListener, rerender]);
709
+ let left = 0, right = 0, top = 0, bottom = 0, width = 0, height = 0, isTabSelected = !1;
710
+ if (value != null && tabsListElement != null) {
711
+ let activeTab = getTabElementBySelectedValue(value);
712
+ if (activeTab != null) {
713
+ isTabSelected = !0;
714
+ let {
715
+ width: computedWidth,
716
+ height: computedHeight
717
+ } = getCssDimensions(activeTab), {
718
+ width: tabListWidth,
719
+ height: tabListHeight
720
+ } = getCssDimensions(tabsListElement), tabRect = activeTab.getBoundingClientRect(), tabsListRect = tabsListElement.getBoundingClientRect(), scaleX = tabListWidth > 0 ? tabsListRect.width / tabListWidth : 1, scaleY = tabListHeight > 0 ? tabsListRect.height / tabListHeight : 1, layoutOffset = getLayoutOffset(activeTab, tabsListElement);
721
+ left = layoutOffset.left, top = layoutOffset.top;
722
+ let rectLeft = (tabRect.left - tabsListRect.left) / scaleX + tabsListElement.scrollLeft - tabsListElement.clientLeft, rectTop = (tabRect.top - tabsListRect.top) / scaleY + tabsListElement.scrollTop - tabsListElement.clientTop, tabTranslation = getActiveTabTranslation(activeTab);
723
+ Math.abs(rectLeft - tabTranslation.x - left) <= MAX_LAYOUT_ROUNDING_ERROR && Math.abs(rectTop - tabTranslation.y - top) <= MAX_LAYOUT_ROUNDING_ERROR && (left = rectLeft, top = rectTop), width = computedWidth, height = computedHeight, right = tabsListElement.scrollWidth - left - width, bottom = tabsListElement.scrollHeight - top - height;
724
+ }
725
+ }
726
+ let activeTabPosition = isTabSelected ? {
727
+ left,
728
+ right,
729
+ top,
730
+ bottom
731
+ } : null, activeTabSize = isTabSelected ? {
732
+ width,
733
+ height
734
+ } : null, style = isTabSelected ? {
735
+ [activeTabLeft]: `${left}px`,
736
+ [activeTabRight]: `${right}px`,
737
+ [activeTabTop]: `${top}px`,
738
+ [activeTabBottom]: `${bottom}px`,
739
+ [activeTabWidth]: `${width}px`,
740
+ [activeTabHeight]: `${height}px`
741
+ } : void 0, displayIndicator = isTabSelected && width > 0 && height > 0, element = useRenderElement("span", componentProps, {
742
+ state: {
743
+ orientation,
744
+ activeTabPosition,
745
+ activeTabSize,
746
+ tabActivationDirection
747
+ },
748
+ ref: forwardedRef,
749
+ props: [{
750
+ role: "presentation",
751
+ style,
752
+ hidden: !displayIndicator
753
+ // do not display the indicator before the layout is settled
754
+ }, elementProps, {
755
+ suppressHydrationWarning: !0
756
+ }],
757
+ stateAttributesMapping
758
+ });
759
+ return value == null ? null : _jsxs(React13.Fragment, {
760
+ children: [element, renderBeforeHydration && (_PrehydrationScript || (_PrehydrationScript = _jsx4(PrehydrationScript, {
761
+ script: ""
762
+ })))]
763
+ });
764
+ });
765
+ process.env.NODE_ENV !== "production" && (TabsIndicator.displayName = "TabsIndicator");
766
+ function getLayoutOffset(element, ancestor) {
767
+ let elementOffset = getCumulativeOffset(element), ancestorOffset = getCumulativeOffset(ancestor), left = elementOffset.left - ancestorOffset.left - ancestor.clientLeft, top = elementOffset.top - ancestorOffset.top - ancestor.clientTop, node = getParentNode(element);
768
+ for (; isHTMLElement(node) && node !== ancestor && !isLastTraversableNode(node); )
769
+ left -= node.scrollLeft, top -= node.scrollTop, node = getParentNode(node);
770
+ return {
771
+ left,
772
+ top
773
+ };
774
+ }
775
+ function getCumulativeOffset(element) {
776
+ let left = 0, top = 0, currentElement = element;
777
+ for (; currentElement != null; ) {
778
+ left += currentElement.offsetLeft, top += currentElement.offsetTop;
779
+ let offsetParent = currentElement.offsetParent;
780
+ offsetParent != null && (left += offsetParent.clientLeft, top += offsetParent.clientTop), currentElement = offsetParent;
781
+ }
782
+ return {
783
+ left,
784
+ top
785
+ };
786
+ }
787
+ function getActiveTabTranslation(element) {
788
+ let computedStyle = getWindow(element).getComputedStyle(element), {
789
+ x,
790
+ y
791
+ } = getElementTransform(element, computedStyle), translateX = x, translateY = y, {
792
+ translate
793
+ } = computedStyle;
794
+ if (translate && translate !== "none") {
795
+ let parts = translate.split(" ");
796
+ translateX += resolveTranslateLength(parts[0], element.offsetWidth), translateY += resolveTranslateLength(parts[1], element.offsetHeight);
797
+ }
798
+ return {
799
+ x: translateX,
800
+ y: translateY
801
+ };
802
+ }
803
+ function resolveTranslateLength(value, referenceSize) {
804
+ if (!value)
805
+ return 0;
806
+ let numeric = parseFloat(value);
807
+ return Number.isFinite(numeric) ? value.endsWith("%") ? numeric / 100 * referenceSize : numeric : 0;
808
+ }
809
+
810
+ // ../../node_modules/@base-ui/react/tabs/panel/TabsPanel.mjs
811
+ import * as React14 from "react";
812
+
813
+ // ../../node_modules/@base-ui/react/tabs/panel/TabsPanelDataAttributes.mjs
814
+ var index = "data-index";
815
+ var startingStyle = TransitionStatusDataAttributes_exports.startingStyle, endingStyle = TransitionStatusDataAttributes_exports.endingStyle;
816
+
817
+ // ../../node_modules/@base-ui/react/tabs/panel/TabsPanel.mjs
818
+ var stateAttributesMapping2 = {
819
+ ...tabsStateAttributesMapping,
820
+ ...transitionStatusMapping
821
+ }, TabsPanel = React14.forwardRef(function(componentProps, forwardedRef) {
822
+ let {
823
+ className,
824
+ value,
825
+ render,
826
+ keepMounted = !1,
827
+ style,
828
+ ...elementProps
829
+ } = componentProps, {
830
+ value: selectedValue,
831
+ getTabIdByPanelValue,
832
+ orientation,
833
+ tabActivationDirection,
834
+ registerMountedTabPanel
835
+ } = useTabsRootContext(), id = useBaseUiId(), {
836
+ ref: listItemRef,
837
+ index: index2
838
+ } = useCompositeListItem(), open = value === selectedValue, {
839
+ mounted,
840
+ transitionStatus,
841
+ setMounted
842
+ } = useTransitionStatus(open), hidden = !mounted, correspondingTabId = getTabIdByPanelValue(value), state = {
843
+ hidden,
844
+ orientation,
845
+ tabActivationDirection,
846
+ transitionStatus
847
+ }, panelRef = React14.useRef(null), element = useRenderElement("div", componentProps, {
848
+ state,
849
+ ref: [forwardedRef, listItemRef, panelRef],
850
+ props: [{
851
+ "aria-labelledby": correspondingTabId,
852
+ hidden,
853
+ id,
854
+ role: "tabpanel",
855
+ tabIndex: open ? 0 : -1,
856
+ inert: inertValue(!open),
857
+ // Computed key: a plain literal key fails the DOM-props excess property check.
858
+ [index]: index2
859
+ }, elementProps],
860
+ stateAttributesMapping: stateAttributesMapping2
861
+ });
862
+ return useOpenChangeComplete({
863
+ open,
864
+ ref: panelRef,
865
+ onComplete() {
866
+ open || setMounted(!1);
867
+ }
868
+ }), useIsoLayoutEffect(() => {
869
+ if (!(id == null || hidden && !keepMounted))
870
+ return registerMountedTabPanel(value, id);
871
+ }, [hidden, keepMounted, value, id, registerMountedTabPanel]), keepMounted || mounted ? element : null;
872
+ });
873
+ process.env.NODE_ENV !== "production" && (TabsPanel.displayName = "TabsPanel");
874
+
875
+ // ../../node_modules/@base-ui/react/tabs/list/TabsList.mjs
876
+ import * as React17 from "react";
877
+
878
+ // ../../node_modules/@base-ui/react/internals/composite/root/CompositeRoot.mjs
879
+ import * as React16 from "react";
880
+
881
+ // ../../node_modules/@base-ui/react/internals/composite/root/useCompositeRoot.mjs
882
+ import * as React15 from "react";
883
+
884
+ // ../../node_modules/@base-ui/utils/isElementDisabled.mjs
885
+ function isElementDisabled(element) {
886
+ return element == null || element.hasAttribute("disabled") || element.getAttribute("aria-disabled") === "true";
887
+ }
888
+
889
+ // ../../node_modules/@base-ui/react/internals/composite/root/useCompositeRoot.mjs
890
+ function useCompositeRoot(params) {
891
+ let {
892
+ loopFocus = !0,
893
+ orientation = "both",
894
+ grid,
895
+ onLoop,
896
+ direction,
897
+ highlightedIndex: externalHighlightedIndex,
898
+ onHighlightedIndexChange: externalSetHighlightedIndex,
899
+ rootRef: externalRef,
900
+ enableHomeAndEndKeys = !1,
901
+ stopEventPropagation,
902
+ disabledIndices,
903
+ modifierKeys = EMPTY_ARRAY
904
+ } = params, [internalHighlightedIndex, internalSetHighlightedIndex] = React15.useState(0), isGrid = grid != null, rootRef = React15.useRef(null), mergedRef = useMergedRefs(rootRef, externalRef), elementsRef = React15.useRef([]), hasSetDefaultIndexRef = React15.useRef(!1), highlightedElementRef = React15.useRef(null), highlightedIndex = externalHighlightedIndex ?? internalHighlightedIndex, onHighlightedIndexChange = useStableCallback((index2, shouldScrollIntoView = !1) => {
905
+ if (highlightedElementRef.current = elementsRef.current[index2] ?? null, (externalSetHighlightedIndex ?? internalSetHighlightedIndex)(index2), shouldScrollIntoView) {
906
+ let newActiveItem = elementsRef.current[index2];
907
+ scrollIntoViewIfNeeded(rootRef.current, newActiveItem, direction, orientation);
908
+ }
909
+ }), onMapChange = useStableCallback((map) => {
910
+ if (map.size === 0)
911
+ return;
912
+ if (hasSetDefaultIndexRef.current) {
913
+ let elements = elementsRef.current, nextIndex = elements.indexOf(highlightedElementRef.current);
914
+ if (nextIndex === -1) {
915
+ let replacement = elements[highlightedIndex];
916
+ !replacement || isListIndexDisabled(elements, highlightedIndex, disabledIndices) ? onHighlightedIndexChange(getFallbackIndex(elements, disabledIndices)) : highlightedElementRef.current = replacement;
917
+ } else nextIndex !== highlightedIndex && onHighlightedIndexChange(nextIndex);
918
+ return;
919
+ }
920
+ hasSetDefaultIndexRef.current = !0;
921
+ let sortedElements = Array.from(map.keys()), activeItem = sortedElements.find((compositeElement) => compositeElement?.hasAttribute(ACTIVE_COMPOSITE_ITEM)) ?? null, activeIndex = activeItem ? map.get(activeItem)?.index ?? -1 : -1;
922
+ if (activeIndex !== -1)
923
+ onHighlightedIndexChange(activeIndex);
924
+ else if (isListIndexDisabled(sortedElements, highlightedIndex, disabledIndices)) {
925
+ let firstEnabledIndex = findNonDisabledListIndex(sortedElements, {
926
+ disabledIndices
927
+ });
928
+ isIndexOutOfListBounds(sortedElements, firstEnabledIndex) || onHighlightedIndexChange(firstEnabledIndex);
929
+ }
930
+ scrollIntoViewIfNeeded(rootRef.current, activeItem, direction, orientation);
931
+ });
932
+ useIsoLayoutEffect(() => {
933
+ if (disabledIndices == null || externalHighlightedIndex != null || !hasSetDefaultIndexRef.current)
934
+ return;
935
+ let elements = elementsRef.current;
936
+ if (isListIndexDisabled(elements, highlightedIndex, disabledIndices)) {
937
+ let firstEnabledIndex = findNonDisabledListIndex(elements, {
938
+ disabledIndices
939
+ });
940
+ isIndexOutOfListBounds(elements, firstEnabledIndex) || onHighlightedIndexChange(firstEnabledIndex);
941
+ }
942
+ }, [disabledIndices, externalHighlightedIndex, highlightedIndex, elementsRef, onHighlightedIndexChange]);
943
+ let wrappedOnLoop = useStableCallback((event, prevIndex, nextIndex) => onLoop ? onLoop(event, prevIndex, nextIndex, elementsRef) : nextIndex), onKeyDown = useStableCallback((event) => {
944
+ let isHomeOrEnd = event.key === HOME || event.key === END;
945
+ if (!COMPOSITE_KEYS.has(event.key) || !enableHomeAndEndKeys && isHomeOrEnd || isModifierKeySet(event, modifierKeys) || !rootRef.current)
946
+ return;
947
+ let isRtl = direction === "rtl", horizontalForwardKey = isRtl ? ARROW_LEFT : ARROW_RIGHT, horizontalBackwardKey = isRtl ? ARROW_RIGHT : ARROW_LEFT, forwardKey = orientation === "vertical" ? ARROW_DOWN : horizontalForwardKey, backwardKey = orientation === "vertical" ? ARROW_UP : horizontalBackwardKey, target = getTarget(event.nativeEvent);
948
+ if (target != null && isNativeInput(target) && !isElementDisabled(target)) {
949
+ let selectionStart = target.selectionStart, selectionEnd = target.selectionEnd, textContent = target.value;
950
+ if (selectionStart == null || event.shiftKey || selectionStart !== selectionEnd || event.key !== backwardKey && selectionStart < textContent.length || event.key !== forwardKey && selectionStart > 0)
951
+ return;
952
+ }
953
+ let nextIndex = highlightedIndex, minIndex = getMinListIndex(elementsRef, disabledIndices), maxIndex = getMaxListIndex(elementsRef, disabledIndices);
954
+ grid != null && (nextIndex = grid({
955
+ disabledIndices,
956
+ elementsRef,
957
+ event,
958
+ highlightedIndex,
959
+ loopFocus,
960
+ maxIndex,
961
+ minIndex,
962
+ onLoop: wrappedOnLoop,
963
+ orientation,
964
+ rtl: isRtl
965
+ }));
966
+ let isForwardKey = orientation !== "vertical" && event.key === horizontalForwardKey || orientation !== "horizontal" && event.key === ARROW_DOWN, isBackwardKey = orientation !== "vertical" && event.key === horizontalBackwardKey || orientation !== "horizontal" && event.key === ARROW_UP;
967
+ enableHomeAndEndKeys && (event.key === HOME ? nextIndex = minIndex : event.key === END && (nextIndex = maxIndex)), nextIndex === highlightedIndex && (isForwardKey || isBackwardKey) && (loopFocus && nextIndex === maxIndex && isForwardKey ? (nextIndex = minIndex, onLoop && (nextIndex = onLoop(event, highlightedIndex, nextIndex, elementsRef))) : loopFocus && nextIndex === minIndex && isBackwardKey ? (nextIndex = maxIndex, onLoop && (nextIndex = onLoop(event, highlightedIndex, nextIndex, elementsRef))) : nextIndex = findNonDisabledListIndex(elementsRef.current, {
968
+ startingIndex: nextIndex,
969
+ decrement: isBackwardKey,
970
+ disabledIndices
971
+ })), nextIndex !== highlightedIndex && !isIndexOutOfListBounds(elementsRef.current, nextIndex) && (stopEventPropagation && event.stopPropagation(), (isGrid || isHomeOrEnd || isForwardKey || isBackwardKey) && event.preventDefault(), onHighlightedIndexChange(nextIndex, !0), queueMicrotask(() => {
972
+ elementsRef.current[nextIndex]?.focus();
973
+ }));
974
+ });
975
+ return {
976
+ props: {
977
+ ref: mergedRef,
978
+ onFocus(event) {
979
+ let element = rootRef.current, target = getTarget(event.nativeEvent);
980
+ !element || target == null || !isNativeInput(target) || target.setSelectionRange(0, target.value.length);
981
+ },
982
+ onKeyDown
983
+ },
984
+ highlightedIndex,
985
+ onHighlightedIndexChange,
986
+ elementsRef,
987
+ onMapChange,
988
+ relayKeyboardEvent: onKeyDown
989
+ };
990
+ }
991
+ function getFallbackIndex(elements, disabledIndices) {
992
+ let fallbackIndex = -1;
993
+ for (let index2 = 0; index2 < elements.length; index2 += 1) {
994
+ let element = elements[index2];
995
+ if (!(!element || isListIndexDisabled(elements, index2, disabledIndices))) {
996
+ if (element.hasAttribute(ACTIVE_COMPOSITE_ITEM))
997
+ return index2;
998
+ fallbackIndex === -1 && (fallbackIndex = index2);
999
+ }
1000
+ }
1001
+ return Math.max(fallbackIndex, 0);
1002
+ }
1003
+ function isModifierKeySet(event, ignoredModifierKeys) {
1004
+ for (let key of MODIFIER_KEYS)
1005
+ if (!ignoredModifierKeys.includes(key) && event.getModifierState(key))
1006
+ return !0;
1007
+ return !1;
1008
+ }
1009
+
1010
+ // ../../node_modules/@base-ui/react/internals/composite/root/CompositeRoot.mjs
1011
+ import { jsx as _jsx5 } from "react/jsx-runtime";
1012
+ function CompositeRoot(componentProps) {
1013
+ let {
1014
+ render,
1015
+ className,
1016
+ style,
1017
+ refs = EMPTY_ARRAY,
1018
+ props = EMPTY_ARRAY,
1019
+ state = EMPTY_OBJECT,
1020
+ stateAttributesMapping: stateAttributesMapping3,
1021
+ highlightedIndex: highlightedIndexProp,
1022
+ onHighlightedIndexChange: onHighlightedIndexChangeProp,
1023
+ orientation,
1024
+ grid,
1025
+ loopFocus,
1026
+ onLoop,
1027
+ enableHomeAndEndKeys,
1028
+ onMapChange: onMapChangeProp,
1029
+ stopEventPropagation = !0,
1030
+ rootRef,
1031
+ disabledIndices,
1032
+ modifierKeys,
1033
+ highlightItemOnHover = !1,
1034
+ tag = "div",
1035
+ ...elementProps
1036
+ } = componentProps, direction = useDirection(), {
1037
+ props: defaultProps,
1038
+ highlightedIndex,
1039
+ onHighlightedIndexChange,
1040
+ elementsRef,
1041
+ onMapChange: onMapChangeUnwrapped,
1042
+ relayKeyboardEvent
1043
+ } = useCompositeRoot({
1044
+ grid,
1045
+ loopFocus,
1046
+ onLoop,
1047
+ orientation,
1048
+ highlightedIndex: highlightedIndexProp,
1049
+ onHighlightedIndexChange: onHighlightedIndexChangeProp,
1050
+ rootRef,
1051
+ stopEventPropagation,
1052
+ enableHomeAndEndKeys,
1053
+ direction,
1054
+ disabledIndices,
1055
+ modifierKeys
1056
+ }), element = useRenderElement(tag, componentProps, {
1057
+ state,
1058
+ ref: refs,
1059
+ props: [defaultProps, ...props, elementProps],
1060
+ stateAttributesMapping: stateAttributesMapping3
1061
+ }), contextValue = React16.useMemo(() => ({
1062
+ highlightedIndex,
1063
+ onHighlightedIndexChange,
1064
+ highlightItemOnHover,
1065
+ relayKeyboardEvent
1066
+ }), [highlightedIndex, onHighlightedIndexChange, highlightItemOnHover, relayKeyboardEvent]);
1067
+ return _jsx5(CompositeRootContext.Provider, {
1068
+ value: contextValue,
1069
+ children: _jsx5(CompositeList, {
1070
+ elementsRef,
1071
+ onMapChange: (newMap) => {
1072
+ onMapChangeProp?.(newMap), onMapChangeUnwrapped(newMap);
1073
+ },
1074
+ children: element
1075
+ })
1076
+ });
1077
+ }
1078
+
1079
+ // ../../node_modules/@base-ui/react/tabs/list/TabsList.mjs
1080
+ import { jsx as _jsx6 } from "react/jsx-runtime";
1081
+ var TabsList = React17.forwardRef(function(componentProps, forwardedRef) {
1082
+ let {
1083
+ activateOnFocus = !1,
1084
+ className,
1085
+ loopFocus = !0,
1086
+ render,
1087
+ style,
1088
+ ...elementProps
1089
+ } = componentProps, {
1090
+ orientation,
1091
+ setTabMap,
1092
+ tabActivationDirection
1093
+ } = useTabsRootContext(), [highlightedTabIndex, setHighlightedTabIndex] = React17.useState(0), [tabsListElement, setTabsListElement] = React17.useState(null), indicatorUpdateListenersRef = React17.useRef(/* @__PURE__ */ new Set()), tabResizeObserverElementsRef = React17.useRef(/* @__PURE__ */ new Set()), resizeObserverRef = React17.useRef(null);
1094
+ useIsoLayoutEffect(() => {
1095
+ if (typeof ResizeObserver > "u")
1096
+ return;
1097
+ let resizeObserver = new ResizeObserver(() => {
1098
+ indicatorUpdateListenersRef.current.forEach((listener) => {
1099
+ listener();
1100
+ });
1101
+ });
1102
+ return resizeObserverRef.current = resizeObserver, tabsListElement && resizeObserver.observe(tabsListElement), tabResizeObserverElementsRef.current.forEach((element) => {
1103
+ resizeObserver.observe(element);
1104
+ }), () => {
1105
+ resizeObserver.disconnect(), resizeObserverRef.current = null;
1106
+ };
1107
+ }, [tabsListElement]);
1108
+ let registerIndicatorUpdateListener = useStableCallback((listener) => (indicatorUpdateListenersRef.current.add(listener), () => {
1109
+ indicatorUpdateListenersRef.current.delete(listener);
1110
+ })), registerTabResizeObserverElement = useStableCallback((element) => (tabResizeObserverElementsRef.current.add(element), resizeObserverRef.current?.observe(element), () => {
1111
+ tabResizeObserverElementsRef.current.delete(element), resizeObserverRef.current?.unobserve(element);
1112
+ })), state = {
1113
+ orientation,
1114
+ tabActivationDirection
1115
+ }, defaultProps = {
1116
+ "aria-orientation": orientation === "vertical" ? "vertical" : void 0,
1117
+ role: "tablist"
1118
+ }, tabsListContextValue = React17.useMemo(() => ({
1119
+ activateOnFocus,
1120
+ registerIndicatorUpdateListener,
1121
+ registerTabResizeObserverElement,
1122
+ tabsListElement
1123
+ }), [activateOnFocus, registerIndicatorUpdateListener, registerTabResizeObserverElement, tabsListElement]);
1124
+ return _jsx6(TabsListContext.Provider, {
1125
+ value: tabsListContextValue,
1126
+ children: _jsx6(CompositeRoot, {
1127
+ render,
1128
+ className,
1129
+ style,
1130
+ state,
1131
+ refs: [forwardedRef, setTabsListElement],
1132
+ props: [defaultProps, elementProps],
1133
+ stateAttributesMapping: tabsStateAttributesMapping,
1134
+ highlightedIndex: highlightedTabIndex,
1135
+ enableHomeAndEndKeys: !0,
1136
+ loopFocus,
1137
+ orientation,
1138
+ onHighlightedIndexChange: setHighlightedTabIndex,
1139
+ onMapChange: setTabMap,
1140
+ disabledIndices: EMPTY_ARRAY
1141
+ })
1142
+ });
1143
+ });
1144
+ process.env.NODE_ENV !== "production" && (TabsList.displayName = "TabsList");
1145
+
1146
+ export {
1147
+ useCSPContext,
1148
+ index_parts_exports
1149
+ };