@aussieljk/forkbook 0.0.1-2 → 0.0.1-21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (536) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +35 -53
  3. package/assets/addon-vitest/templates/vitest.config.4.template.ts +2 -2
  4. package/assets/browser/favicon-wrapper.svg +4 -4
  5. package/assets/browser/favicon.svg +1 -1
  6. package/assets/browser/inter-LICENSE.txt +92 -0
  7. package/assets/browser/inter-variable-italic.woff2 +0 -0
  8. package/assets/browser/inter-variable.woff2 +0 -0
  9. package/assets/browser/mirror-ball.png +0 -0
  10. package/assets/builder-vite/iframe.html +8 -24
  11. package/assets/create/rendererAssets/common/Configure.mdx +100 -100
  12. package/assets/create/rendererAssets/common/button.css +7 -7
  13. package/assets/create/rendererAssets/common/header.css +6 -6
  14. package/assets/create/rendererAssets/common/page.css +12 -12
  15. package/assets/create/templates/react-native/index.expo.js +4 -4
  16. package/assets/create/templates/react-native/index.js +5 -5
  17. package/assets/server/base-preview-body.html +32 -32
  18. package/assets/server/base-preview-head.html +86 -86
  19. package/assets/server/template.ejs +31 -26
  20. package/dist/_browser-chunks/{Color-PCLE2J36.js → Color-7FO5YFB5.js} +8 -8
  21. package/dist/_browser-chunks/{DocsRenderer-JXND3PVQ.js → DocsRenderer-DKXSW2OY.js} +2 -2
  22. package/dist/_browser-chunks/WithTooltip-QWFSUQZP.js +199 -0
  23. package/dist/_browser-chunks/{chunk-RBCHTR7C.js → chunk-2ELGJRFZ.js} +1 -1
  24. package/dist/_browser-chunks/{chunk-PFRNG3UC.js → chunk-2WZWS7GJ.js} +5 -5
  25. package/dist/_browser-chunks/{chunk-52CW7FF7.js → chunk-3QNZOMD7.js} +8 -3
  26. package/dist/_browser-chunks/{chunk-LV5PIKV4.js → chunk-3QPZOXB7.js} +6 -8
  27. package/dist/_browser-chunks/{chunk-ODVJ3XZJ.js → chunk-4BOJAE7P.js} +14 -10
  28. package/dist/_browser-chunks/{chunk-2MEPHP35.js → chunk-4KIQBRD2.js} +1 -1
  29. package/dist/_browser-chunks/{chunk-KQ7CRO2B.js → chunk-5Z3MWCFR.js} +12 -12
  30. package/dist/_browser-chunks/chunk-6AKCRYVX.js +6 -0
  31. package/dist/_browser-chunks/{chunk-W5M6NPS3.js → chunk-6SL45YM3.js} +15 -18
  32. package/dist/_browser-chunks/{chunk-2SCZVUKW.js → chunk-AN2LJG5I.js} +1 -1
  33. package/dist/_browser-chunks/{chunk-P6PK47TQ.js → chunk-BLCZ3C5M.js} +48 -83
  34. package/dist/_browser-chunks/{chunk-RSPAQWVJ.js → chunk-BNP234B4.js} +1 -1
  35. package/dist/_browser-chunks/{chunk-JYVGARBG.js → chunk-BSYOFSF6.js} +770 -720
  36. package/dist/_browser-chunks/{chunk-JSBKXXXF.js → chunk-DHTLVXAL.js} +38 -45
  37. package/dist/_browser-chunks/{chunk-GNZY6LOW.js → chunk-DISGPOF4.js} +54 -51
  38. package/dist/_browser-chunks/chunk-DNJ3OSLB.js +6021 -0
  39. package/dist/_browser-chunks/{chunk-6SXYJQST.js → chunk-E6QKKKLO.js} +21 -6
  40. package/dist/_browser-chunks/{chunk-FJGWSWL5.js → chunk-EBSOKHFG.js} +10 -4
  41. package/dist/_browser-chunks/{chunk-CFAOWGL7.js → chunk-ECMVTOVD.js} +1 -1
  42. package/dist/_browser-chunks/{chunk-CFWWCCZV.js → chunk-ENHFQXYS.js} +9 -7
  43. package/dist/_browser-chunks/{chunk-YTIT5NA5.js → chunk-EW2M3URL.js} +91 -84
  44. package/dist/_browser-chunks/chunk-FAOLWWRN.js +20 -0
  45. package/dist/_browser-chunks/{chunk-MFMDGWP6.js → chunk-FCULT3AE.js} +3 -3
  46. package/dist/_browser-chunks/{chunk-46Z7NGAS.js → chunk-HX443LKV.js} +1 -1
  47. package/dist/_browser-chunks/chunk-HZFHNYRC.js +53 -0
  48. package/dist/_browser-chunks/chunk-IFADVEQE.js +669 -0
  49. package/dist/_browser-chunks/{chunk-OQWFVDIN.js → chunk-KQJ4T6JL.js} +31 -25
  50. package/dist/_browser-chunks/{chunk-RNTIV5CE.js → chunk-LYYXDWR2.js} +9 -9
  51. package/dist/_browser-chunks/{chunk-V5M7Q4HT.js → chunk-MJIDTL3X.js} +4 -14
  52. package/dist/_browser-chunks/{chunk-V2G23FV7.js → chunk-N5WQGLI7.js} +1 -1
  53. package/dist/_browser-chunks/{chunk-EIYAKDGP.js → chunk-NA4ITZTK.js} +127 -105
  54. package/dist/_browser-chunks/{chunk-RMYQ3QN3.js → chunk-NK5SGJNG.js} +22 -17
  55. package/dist/_browser-chunks/chunk-NPNIBOPF.js +18 -0
  56. package/dist/_browser-chunks/{chunk-YEKO6BHJ.js → chunk-ONTSNQON.js} +1 -1
  57. package/dist/_browser-chunks/chunk-OOETBSA7.js +502 -0
  58. package/dist/_browser-chunks/chunk-PFYL47RM.js +45 -0
  59. package/dist/_browser-chunks/{chunk-OD6IBQCC.js → chunk-PQRPDA4U.js} +5 -5
  60. package/dist/_browser-chunks/{chunk-2JDQ35OA.js → chunk-PU7D2WDP.js} +0 -11
  61. package/dist/_browser-chunks/chunk-PZQRXPVR.js +21 -0
  62. package/dist/_browser-chunks/{chunk-5WMXI5GW.js → chunk-QFO2B4X2.js} +31 -28
  63. package/dist/_browser-chunks/{chunk-2JT76G3E.js → chunk-SBOQ4QPY.js} +15 -15
  64. package/dist/_browser-chunks/{chunk-ZTQ5MEJ5.js → chunk-UMGDO2ZM.js} +3 -37
  65. package/dist/_browser-chunks/{chunk-5I7E4GMO.js → chunk-WY2LUGOH.js} +1 -1
  66. package/dist/_browser-chunks/chunk-XKTORVEQ.js +255 -0
  67. package/dist/_browser-chunks/chunk-XSVERCGB.js +91 -0
  68. package/dist/_browser-chunks/{chunk-FVSEPWWX.js → chunk-XTQCLWVH.js} +325 -1635
  69. package/dist/_browser-chunks/{chunk-MDOL7KML.js → chunk-YJO5BK52.js} +7 -3
  70. package/dist/_browser-chunks/{chunk-66OCZ54D.js → chunk-ZF37BMDS.js} +6 -2
  71. package/dist/_browser-chunks/{chunk-C3D4HEFY.js → chunk-ZIZCGWCG.js} +348 -170
  72. package/dist/_browser-chunks/{matchers-YLBYSYAF.js → matchers-2HVLNCVO.js} +4 -4
  73. package/dist/_browser-chunks/{react-dom-client-4OHE3QDV.js → react-dom-client-SLBUX3U3.js} +1 -1
  74. package/dist/_node-chunks/{attached-runtime-I2G4WLJI.js → attached-runtime-UC2CB4GH.js} +37 -35
  75. package/dist/_node-chunks/builder-manager-S5UUKVOR.js +1174 -0
  76. package/dist/_node-chunks/{chunk-OUW6R7C3.js → chunk-3335ZZIO.js} +6 -6
  77. package/dist/_node-chunks/{chunk-V2DY426G.js → chunk-3D6N6P2R.js} +283 -306
  78. package/dist/_node-chunks/{chunk-3Y6AAY5H.js → chunk-3ER54PQM.js} +8 -8
  79. package/dist/_node-chunks/{chunk-DC7DKR5K.js → chunk-3H5C52QU.js} +6 -6
  80. package/dist/_node-chunks/chunk-3UI3TQ7R.js +28 -0
  81. package/dist/_node-chunks/{chunk-Q7QNUM5H.js → chunk-4C3ACAHV.js} +6 -6
  82. package/dist/_node-chunks/{chunk-XGIUVY52.js → chunk-4UTCKJEQ.js} +7 -7
  83. package/dist/_node-chunks/chunk-53A5CYDK.js +572 -0
  84. package/dist/_node-chunks/{chunk-4FEANXWU.js → chunk-53PSBDRK.js} +140 -118
  85. package/dist/_node-chunks/{chunk-3W7F2B7P.js → chunk-54MO4QLB.js} +6 -6
  86. package/dist/_node-chunks/{chunk-7GUDZVRQ.js → chunk-5CJMRQZ6.js} +6 -6
  87. package/dist/_node-chunks/chunk-5HOM7B4V.js +20 -0
  88. package/dist/_node-chunks/{chunk-BSKFCWQD.js → chunk-5QG6AXK4.js} +7 -7
  89. package/dist/_node-chunks/chunk-67XVZZUO.js +405 -0
  90. package/dist/_node-chunks/{chunk-EWOX7HPJ.js → chunk-6HQJJDLH.js} +6 -6
  91. package/dist/_node-chunks/chunk-6IPHWCFI.js +29 -0
  92. package/dist/_node-chunks/{chunk-NDWKJ4CL.js → chunk-6XYOFBRD.js} +98 -129
  93. package/dist/_node-chunks/{chunk-TNJIXE37.js → chunk-7IAYDGYH.js} +6 -6
  94. package/dist/_node-chunks/{chunk-ICPBH3E7.js → chunk-7P67PUU2.js} +7 -7
  95. package/dist/_node-chunks/{chunk-XLP2ZKXV.js → chunk-AAK5BBF2.js} +7 -7
  96. package/dist/_node-chunks/{chunk-CCOTJ4FC.js → chunk-BGUVBOOU.js} +10 -10
  97. package/dist/_node-chunks/chunk-BNGBOASQ.js +25 -0
  98. package/dist/_node-chunks/{chunk-VLOXOXXE.js → chunk-BWZWCVVH.js} +9 -9
  99. package/dist/_node-chunks/{chunk-SWO5CDYU.js → chunk-C6HQ6WLU.js} +8 -8
  100. package/dist/_node-chunks/chunk-CJHRH777.js +20 -0
  101. package/dist/_node-chunks/{chunk-IK4FGZLR.js → chunk-COEW4ORP.js} +6 -6
  102. package/dist/_node-chunks/{chunk-JGGFYIG5.js → chunk-CVHDAEDZ.js} +7 -7
  103. package/dist/_node-chunks/{chunk-YCMRA6RX.js → chunk-CXGOQNGI.js} +7 -7
  104. package/dist/_node-chunks/chunk-D4XTQWRM.js +11 -0
  105. package/dist/_node-chunks/{chunk-BS2WMZMR.js → chunk-D5V6CZ6U.js} +7 -7
  106. package/dist/_node-chunks/{chunk-XHL2LVBM.js → chunk-DCTXJ4TT.js} +14 -16
  107. package/dist/_node-chunks/{chunk-WCULS5TP.js → chunk-DP6WFY3D.js} +7 -7
  108. package/dist/_node-chunks/chunk-E23GDXG6.js +271 -0
  109. package/dist/_node-chunks/{chunk-GEFQN7K3.js → chunk-E3ZFMURC.js} +8 -8
  110. package/dist/_node-chunks/{chunk-WZJF2OUH.js → chunk-E6O3NA44.js} +7 -7
  111. package/dist/_node-chunks/{chunk-RWFIFGO5.js → chunk-ECS3WDOU.js} +8 -8
  112. package/dist/_node-chunks/{chunk-XI6B6P47.js → chunk-FB5YJWOH.js} +6 -6
  113. package/dist/_node-chunks/{chunk-3SDUYDXH.js → chunk-FCK5FM6D.js} +7 -7
  114. package/dist/_node-chunks/{chunk-6YKBRP72.js → chunk-FJUGPEJK.js} +6 -6
  115. package/dist/_node-chunks/{chunk-TFEWM4E3.js → chunk-FPYXI76E.js} +75 -75
  116. package/dist/_node-chunks/chunk-GEWVOY3F.js +62 -0
  117. package/dist/_node-chunks/{chunk-ET7PWEO7.js → chunk-GHZ44BFB.js} +14 -13
  118. package/dist/_node-chunks/{chunk-LXBD4UL4.js → chunk-GJMFISS3.js} +8 -8
  119. package/dist/_node-chunks/{chunk-FK7KGTV7.js → chunk-GK2Y2RFX.js} +7 -7
  120. package/dist/_node-chunks/{chunk-FPZB5OI7.js → chunk-GP6YBA2R.js} +6 -6
  121. package/dist/_node-chunks/{chunk-34EO2PUT.js → chunk-GQUFGJ4D.js} +6 -6
  122. package/dist/_node-chunks/{chunk-HMP2G23X.js → chunk-H4CRQDTK.js} +6 -6
  123. package/dist/_node-chunks/{chunk-2BUPBPFB.js → chunk-HCDG54OG.js} +7 -7
  124. package/dist/_node-chunks/{chunk-U5W53R2J.js → chunk-HGJMP4EI.js} +506 -494
  125. package/dist/_node-chunks/chunk-HSX6BDBA.js +18 -0
  126. package/dist/_node-chunks/{chunk-UMUBKI6E.js → chunk-IPFPWMT5.js} +1320 -437
  127. package/dist/_node-chunks/chunk-KRIOC4WF.js +281 -0
  128. package/dist/_node-chunks/{chunk-TINO74G5.js → chunk-KUL2MJ6N.js} +6 -6
  129. package/dist/_node-chunks/{chunk-LO56I6E2.js → chunk-LUR6QTYB.js} +10 -10
  130. package/dist/_node-chunks/{chunk-YZFWBA5L.js → chunk-LYS7TI35.js} +368 -321
  131. package/dist/_node-chunks/chunk-MDTXL6SN.js +2613 -0
  132. package/dist/_node-chunks/{chunk-LCK4ZQKG.js → chunk-MIIPXT4S.js} +9 -9
  133. package/dist/_node-chunks/chunk-MLWGAA2I.js +138 -0
  134. package/dist/_node-chunks/{chunk-42UWAGPW.js → chunk-MWUGCUB5.js} +52 -22
  135. package/dist/_node-chunks/{chunk-JDXXX6LB.js → chunk-MX5MVLEK.js} +6 -6
  136. package/dist/_node-chunks/chunk-N44UIGCO.js +47 -0
  137. package/dist/_node-chunks/{chunk-OISX4AGQ.js → chunk-NP2JHOFY.js} +37 -31
  138. package/dist/_node-chunks/chunk-OMNGOPNG.js +52 -0
  139. package/dist/_node-chunks/{chunk-ZWBCQ4MJ.js → chunk-OO2GTHUF.js} +9 -17
  140. package/dist/_node-chunks/{chunk-F3ZFKBHY.js → chunk-PC57BIYZ.js} +8 -8
  141. package/dist/_node-chunks/chunk-PHWMAF5C.js +49 -0
  142. package/dist/_node-chunks/{chunk-B5J7Q7J4.js → chunk-PLIQQETC.js} +7 -7
  143. package/dist/_node-chunks/{chunk-H32DYT6P.js → chunk-QMYCIS2U.js} +6 -6
  144. package/dist/_node-chunks/{chunk-DUR55DJJ.js → chunk-QZIDK3GX.js} +89 -71
  145. package/dist/_node-chunks/{chunk-UVINFLGY.js → chunk-ROJ6RSIJ.js} +7 -7
  146. package/dist/_node-chunks/{chunk-E6YESGLX.js → chunk-S2NB6QEG.js} +542 -1049
  147. package/dist/_node-chunks/{chunk-TWI4GVH7.js → chunk-S6VCOSQS.js} +6 -6
  148. package/dist/_node-chunks/{chunk-KISMCCP5.js → chunk-SEVOOOB2.js} +474 -479
  149. package/dist/_node-chunks/{chunk-JZOO7GGC.js → chunk-SFT6ZAVN.js} +6 -6
  150. package/dist/_node-chunks/{chunk-RRN2V55B.js → chunk-SXBUK4F6.js} +7 -7
  151. package/dist/_node-chunks/{chunk-WNZ2UMFM.js → chunk-TGF6Q66I.js} +15 -9
  152. package/dist/_node-chunks/{chunk-NIBT7XDZ.js → chunk-TGFHWGGT.js} +9 -6
  153. package/dist/_node-chunks/chunk-TTLSBLPQ.js +620 -0
  154. package/dist/_node-chunks/{chunk-SVTBJ7Q3.js → chunk-UUAEW2AR.js} +6 -6
  155. package/dist/_node-chunks/chunk-VQHM66NL.js +534 -0
  156. package/dist/_node-chunks/{chunk-H4PPVMP5.js → chunk-VSTTY3TM.js} +6 -6
  157. package/dist/_node-chunks/{chunk-2DSIDINN.js → chunk-XDBSAFUB.js} +650 -9
  158. package/dist/_node-chunks/{chunk-OWNFOGTA.js → chunk-XTQQGAUZ.js} +7 -7
  159. package/dist/_node-chunks/{chunk-CXRU72ET.js → chunk-YMJVSFJT.js} +6 -6
  160. package/dist/_node-chunks/{chunk-DHJFTB4K.js → chunk-YXEKWVJQ.js} +7 -7
  161. package/dist/_node-chunks/{chunk-SLWQNBGO.js → chunk-Z6CUUWJO.js} +34 -949
  162. package/dist/_node-chunks/{chunk-TD5PLLQG.js → chunk-ZAIGR7EV.js} +64 -17
  163. package/dist/_node-chunks/{chunk-6KEHV53S.js → chunk-ZCFXEFR6.js} +33 -41
  164. package/dist/_node-chunks/{chunk-FW2HQUBQ.js → chunk-ZHUBOYOD.js} +6 -6
  165. package/dist/_node-chunks/{chunk-MA24JW6C.js → chunk-ZHUBTBP2.js} +25 -8
  166. package/dist/_node-chunks/{chunk-RXNJDRGO.js → chunk-ZSTIFZHY.js} +21 -25
  167. package/dist/_node-chunks/dist-TRTHRODT.js +16 -0
  168. package/dist/_node-chunks/dist-XPLJ5T4W.js +27 -0
  169. package/dist/_node-chunks/{local-runtime-NTKIN2QT.js → local-runtime-AC7MOWYK.js} +21 -22
  170. package/dist/_node-chunks/{mdx-plugin-MWISDWDQ.js → mdx-plugin-ZW26VGEP.js} +2263 -130
  171. package/dist/_node-chunks/{monorepo-LIRFMQXE.js → monorepo-T2KZK62Q.js} +12 -12
  172. package/dist/_node-chunks/{monorepo-optimized-tests-relaxed-limits-no-story-deletion-CPDW4XTW.js → monorepo-optimized-tests-relaxed-limits-no-story-deletion-2CWUUF6H.js} +12 -12
  173. package/dist/_node-chunks/optimized-tests-4AK3PFSX.js +22 -0
  174. package/dist/_node-chunks/{pattern-copy-play-EKHIUAU2.js → pattern-copy-play-CMRGEXHM.js} +12 -12
  175. package/dist/_node-chunks/postinstallAddon-OUQENFYO.js +20 -0
  176. package/dist/_node-chunks/{rehype-external-links-BUN3HUCO.js → rehype-external-links-LHOAIJ2E.js} +9 -9
  177. package/dist/_node-chunks/{rehype-slug-PLADX223.js → rehype-slug-K54MMYY6.js} +9 -9
  178. package/dist/_node-chunks/{relaxed-limits-GBHW6KIQ.js → relaxed-limits-TTL4PWH7.js} +12 -12
  179. package/dist/_node-chunks/{run-NL66VTNR.js → run-6DXBB5F7.js} +294 -30
  180. package/dist/_node-chunks/{run-KDTIZNSY.js → run-BMTV5ZAO.js} +18 -18
  181. package/dist/_node-chunks/{setup-MGC7BQO6.js → setup-FDPYW25Y.js} +9 -9
  182. package/dist/_node-chunks/{vitest.config.4.template-JH2THZFG.js → vitest.config.4.template-2TCFWAAI.js} +9 -9
  183. package/dist/actions/decorator.js +18 -22
  184. package/dist/actions/index.d.ts +4 -4
  185. package/dist/actions/index.js +3 -2
  186. package/dist/addon-a11y/index.d.ts +3 -3
  187. package/dist/addon-a11y/index.js +3 -2
  188. package/dist/addon-a11y/manager.js +41 -38
  189. package/dist/addon-a11y/preset.js +7 -7
  190. package/dist/addon-a11y/preview.d.ts +8 -2
  191. package/dist/addon-a11y/preview.js +3 -2
  192. package/dist/addon-comments/manager.js +353 -0
  193. package/dist/addon-comments/preset.js +80 -0
  194. package/dist/addon-comments/preview.js +101 -0
  195. package/dist/addon-docs/blocks.d.ts +123 -85
  196. package/dist/addon-docs/blocks.js +159 -85
  197. package/dist/addon-docs/index.d.ts +21 -21
  198. package/dist/addon-docs/index.js +3 -3
  199. package/dist/addon-docs/manager.js +6 -6
  200. package/dist/addon-docs/preset.js +12 -12
  201. package/dist/addon-docs/preview.d.ts +3 -1
  202. package/dist/addon-docs/preview.js +1 -1
  203. package/dist/addon-links/index.d.ts +2 -1
  204. package/dist/addon-links/index.js +5 -2
  205. package/dist/addon-links/preview.d.ts +1 -1
  206. package/dist/addon-links/preview.js +5 -2
  207. package/dist/addon-links/react/index.js +4 -1
  208. package/dist/addon-mcp/preset.js +203 -84
  209. package/dist/addon-mcp/preview.js +1 -1
  210. package/dist/addon-mcp/tools/preview-stories/preview-stories-app-script.js +71 -71
  211. package/dist/addon-ondevice-actions/index.js +5 -1
  212. package/dist/addon-ondevice-actions/register.js +5 -1
  213. package/dist/addon-ondevice-controls/index.js +1 -1
  214. package/dist/addon-ondevice-controls/register.js +1 -1
  215. package/dist/addon-pseudo-states/index.d.ts +1 -1
  216. package/dist/addon-pseudo-states/index.js +1 -1
  217. package/dist/addon-pseudo-states/manager.js +2 -2
  218. package/dist/addon-pseudo-states/preview.d.ts +1 -1
  219. package/dist/addon-pseudo-states/preview.js +1 -1
  220. package/dist/addon-themes/index.d.ts +7 -6
  221. package/dist/addon-themes/index.js +2 -2
  222. package/dist/addon-themes/manager.js +4 -4
  223. package/dist/addon-themes/postinstall.js +7 -7
  224. package/dist/addon-themes/preview.js +2 -2
  225. package/dist/addon-vitest/constants.js +8 -8
  226. package/dist/addon-vitest/manager.js +32 -23
  227. package/dist/addon-vitest/node/coverage-reporter.js +11 -11
  228. package/dist/addon-vitest/node/vitest.js +37 -37
  229. package/dist/addon-vitest/postinstall.js +10 -10
  230. package/dist/addon-vitest/preset.js +26 -26
  231. package/dist/addon-vitest/vitest-plugin/global-setup.js +23 -23
  232. package/dist/addon-vitest/vitest-plugin/index.js +83 -73
  233. package/dist/addon-vitest/vitest-plugin/setup-file-with-project-annotations.js +3 -3
  234. package/dist/addon-vitest/vitest-plugin/setup-file.js +1 -1
  235. package/dist/babel/index.d.ts +241 -995
  236. package/dist/babel/index.js +30583 -38
  237. package/dist/backgrounds/index.d.ts +1 -1
  238. package/dist/bin/core.js +122 -110
  239. package/dist/bin/dispatcher.js +18 -16
  240. package/dist/bin/loader.js +17 -16
  241. package/dist/builder-next/index.d.ts +59 -0
  242. package/dist/builder-next/index.js +201 -0
  243. package/dist/builder-vite/index.d.ts +8 -3
  244. package/dist/builder-vite/index.js +80 -25
  245. package/dist/builder-vite/preset.js +13 -13
  246. package/dist/channels/index.d.ts +3 -2
  247. package/dist/channels/index.js +97 -24
  248. package/dist/{chunk-Dr3R0DXk.d.ts → chunk-B-NVyPqN.d.ts} +2 -2
  249. package/dist/{chunk-C2p5r3Vt.d.ts → chunk-B53gRJBs.d.ts} +838 -703
  250. package/dist/{chunk-DoIGKY33.d.ts → chunk-BLZXEm1K.d.ts} +6 -8
  251. package/dist/chunk-BcYKnZln.d.ts +10 -0
  252. package/dist/{chunk-Bpi2tz-6.d.ts → chunk-BspNQvZn.d.ts} +21 -23
  253. package/dist/{chunk-BCoJQE-f.d.ts → chunk-BtKww7r1.d.ts} +6 -4
  254. package/dist/chunk-CFhJCPSB.d.ts +48 -0
  255. package/dist/{chunk-DtHByo32.d.ts → chunk-CFk6djyM.d.ts} +5 -5
  256. package/dist/{chunk-CwQKNaYL.d.ts → chunk-CMx6bGAU.d.ts} +2 -2
  257. package/dist/{chunk-DEVFdzxR.d.ts → chunk-CRmUwbkb.d.ts} +4 -4
  258. package/dist/{chunk-CMeX4WRe.d.ts → chunk-CT2iXaHz.d.ts} +1 -1
  259. package/dist/{chunk-pcFXCimE.d.ts → chunk-CmV7WZzR.d.ts} +124 -2
  260. package/dist/{chunk-BGkgZp-H.d.ts → chunk-D3uSIa6H.d.ts} +9 -1
  261. package/dist/{chunk-DzuY9DXg.d.ts → chunk-DDd8BhTY.d.ts} +2 -2
  262. package/dist/{chunk-Dw1z1Pki.d.ts → chunk-DNCU78oW.d.ts} +160 -323
  263. package/dist/chunk-DVIvUVkS.d.ts +195 -0
  264. package/dist/{chunk-gCX81nOr.d.ts → chunk-DgzPaTw9.d.ts} +3 -3
  265. package/dist/{chunk-Kt1tW-D1.d.ts → chunk-Dm-iHJ-s.d.ts} +3 -3
  266. package/dist/{chunk-C-bavsOH.d.ts → chunk-Dw_4ad2Y.d.ts} +6 -6
  267. package/dist/chunk-Susgfkap.d.ts +20 -0
  268. package/dist/{chunk-B2t1tGRh.d.ts → chunk-bhl-7rRD.d.ts} +40 -15
  269. package/dist/{chunk-BXLImeLy.d.ts → chunk-r-Vjut9o.d.ts} +52 -11
  270. package/dist/cli/index.d.ts +15 -904
  271. package/dist/cli/index.js +49 -5209
  272. package/dist/cli/skills/content/index.d.ts +3 -3
  273. package/dist/cli/skills/content/index.js +3 -3
  274. package/dist/cli/tools/sdk/child-host.d.ts +1 -1
  275. package/dist/cli/tools/sdk/child-host.js +17 -17
  276. package/dist/cli/tools/sdk/index.d.ts +4 -4
  277. package/dist/cli/tools/sdk/index.js +18 -18
  278. package/dist/cli-commands/bin/index.js +7 -7
  279. package/dist/client-logger/index.d.ts +20 -21
  280. package/dist/client-logger/index.js +5 -2
  281. package/dist/common/index.d.ts +32 -44
  282. package/dist/common/index.js +89 -98
  283. package/dist/components/index.d.ts +86 -272
  284. package/dist/components/index.js +2759 -8547
  285. package/dist/core-events/index.d.ts +16 -7
  286. package/dist/core-events/index.js +5 -5
  287. package/dist/core-server/index.d.ts +95 -26
  288. package/dist/core-server/index.js +1675 -408
  289. package/dist/core-server/presets/common-manager.js +837 -1335
  290. package/dist/core-server/presets/common-override-preset.js +12 -10
  291. package/dist/core-server/presets/common-preset.js +100 -282
  292. package/dist/create/bin/index.js +7 -7
  293. package/dist/create/index.js +15 -15
  294. package/dist/csf/csf-utils.d.ts +1 -1
  295. package/dist/csf/index.d.ts +6 -6
  296. package/dist/csf/index.js +90 -159
  297. package/dist/csf-tools/index.d.ts +66 -54
  298. package/dist/csf-tools/index.js +19 -17
  299. package/dist/docs-tools/index.d.ts +332 -16
  300. package/dist/docs-tools/index.js +3 -3
  301. package/dist/highlight/index.d.ts +1 -1
  302. package/dist/instrumenter/index.d.ts +5 -5
  303. package/dist/instrumenter/index.js +31 -19
  304. package/dist/manager/_manager-chunks/{globals-runtime-BvM-NY2g.js → globals-runtime-B4NRbNSS.js} +638 -1731
  305. package/dist/{preview/_chunks/runtime-CqHxptiK.js → manager/_manager-chunks/globals-runtime-BC43T1rL.js} +3413 -173
  306. package/dist/manager/_manager-chunks/{globals-runtime-qKvCZHFY.js → globals-runtime-BJ6EZqH7.js} +1035 -623
  307. package/dist/manager/_manager-chunks/{globals-runtime-Rp_zjGnh.js → globals-runtime-BfXaq_CP.js} +2 -2
  308. package/dist/manager/_manager-chunks/{globals-runtime-C02fvgcd.js → globals-runtime-BkSn_Jpe.js} +411 -379
  309. package/dist/manager/_manager-chunks/{globals-runtime-eLPTIfX-.js → globals-runtime-BnQ7i5wq.js} +232 -370
  310. package/dist/manager/_manager-chunks/globals-runtime-BtduS2C2.js +10601 -0
  311. package/dist/manager/_manager-chunks/globals-runtime-BzuYs3dZ.js +1971 -0
  312. package/dist/manager/_manager-chunks/globals-runtime-CBviMKtt.js +446 -0
  313. package/dist/manager/_manager-chunks/globals-runtime-CS41oTca.js +1808 -0
  314. package/dist/manager/_manager-chunks/{globals-runtime-BmphMP6z.js → globals-runtime-Cisw9IIE.js} +11 -11
  315. package/dist/manager/_manager-chunks/globals-runtime-CoTrrHG3.js +1163 -0
  316. package/dist/manager/_manager-chunks/{globals-runtime-FC201B7s.js → globals-runtime-DCmvKMN5.js} +2 -1
  317. package/dist/manager/_manager-chunks/globals-runtime-DgO0hT2p.js +32 -0
  318. package/dist/manager/_manager-chunks/{globals-runtime-DpNYC-qi.js → globals-runtime-DpvE_zRs.js} +1013 -782
  319. package/dist/manager/_manager-chunks/globals-runtime-Me9Bl-sx.js +156 -0
  320. package/dist/manager/_manager-chunks/globals-runtime-nQMRiA0J.js +19 -0
  321. package/dist/manager/_manager-chunks/globals-runtime-oRjPg2jY.js +8935 -0
  322. package/dist/manager/_manager-chunks/{globals-runtime-sGpNlIJ1.js → globals-runtime-wV08sCKl.js} +715 -620
  323. package/dist/manager/_manager-chunks/{runtime-cp5pazY2.js → runtime-4OQZWibO.js} +1717 -1536
  324. package/dist/manager/_manager-chunks/runtime-BYxbyNm0.js +201 -0
  325. package/dist/manager/_manager-chunks/{runtime-EITvVbkG.js → runtime-BdGkqNEt.js} +1 -2
  326. package/dist/manager/_manager-chunks/runtime-CM4Z8aKR.js +735 -0
  327. package/dist/manager/_manager-chunks/{runtime-eDVAYF7N.js → runtime-Cjo1UL1u.js} +57 -76
  328. package/dist/manager/_manager-chunks/runtime-Cx1-wr6J.js +294 -0
  329. package/dist/manager/_manager-chunks/{runtime-BhkT2CXl.js → runtime-Cxe_uJRb.js} +220 -406
  330. package/dist/manager/_manager-chunks/runtime-D702FFTO.js +551 -0
  331. package/dist/manager/_manager-chunks/{runtime-D94Vq3oR.js → runtime-DnWFp6Zw.js} +8 -534
  332. package/dist/manager/_manager-chunks/{runtime-D0UOWx0U.js → runtime-DoYPE6g6.js} +232 -158
  333. package/dist/manager/_manager-chunks/runtime-P663lpsR.js +528 -0
  334. package/dist/manager/_manager-chunks/{runtime-i-PDAHLR.js → runtime-sppa-0ll.js} +741 -698
  335. package/dist/manager/globals-runtime.js +1 -1
  336. package/dist/manager/globals.d.ts +12 -12
  337. package/dist/manager/globals.js +12 -12
  338. package/dist/manager/runtime.js +1 -1
  339. package/dist/manager-api/index.d.ts +1 -1
  340. package/dist/manager-api/index.js +538 -528
  341. package/dist/manager-errors.d.ts +1 -1
  342. package/dist/manager-errors.js +2 -2
  343. package/dist/mcp/index.d.ts +10 -10
  344. package/dist/mcp/index.js +11 -11
  345. package/dist/mocking-utils/index.d.ts +7 -5
  346. package/dist/mocking-utils/index.js +34 -34
  347. package/dist/mocking-utils/mocker-runtime.js +2 -2
  348. package/dist/next/index.d.ts +231 -0
  349. package/dist/next/index.js +398 -0
  350. package/dist/nextjs-vite/export-mocks/headers/index.js +3 -1
  351. package/dist/nextjs-vite/export-mocks/link/index.d.ts +4 -1
  352. package/dist/nextjs-vite/export-mocks/navigation/index.d.ts +9 -1
  353. package/dist/nextjs-vite/export-mocks/router/index.js +13 -7
  354. package/dist/nextjs-vite/index.d.ts +4 -4
  355. package/dist/nextjs-vite/index.js +10 -5
  356. package/dist/nextjs-vite/node/index.d.ts +2 -2
  357. package/dist/nextjs-vite/node/index.js +7 -7
  358. package/dist/nextjs-vite/node-stand-ins/index.d.ts +68 -0
  359. package/dist/nextjs-vite/node-stand-ins/index.js +145 -0
  360. package/dist/nextjs-vite/preset.js +117 -15
  361. package/dist/nextjs-vite/preview.d.ts +2 -1
  362. package/dist/nextjs-vite/preview.js +1 -1
  363. package/dist/nextjs-vite/vite-plugin/index.d.ts +2 -2
  364. package/dist/nextjs-vite/vite-plugin/index.js +9 -9
  365. package/dist/nextjs-vite-plugin/index.d.ts +2 -3
  366. package/dist/nextjs-vite-plugin/index.js +24 -49
  367. package/dist/nextjs-vite-plugin/mocks/storybook.global.js +8 -8
  368. package/dist/nextjs-vite-plugin/plugins/next-image/alias/next-image.js +2 -2
  369. package/dist/nextjs-vite-plugin/plugins/next-image/alias/next-legacy-image.js +2 -2
  370. package/dist/nextjs-vite-plugin/plugins/next-mocks/alias/router/index.js +10 -6
  371. package/dist/node-logger/index.d.ts +89 -90
  372. package/dist/node-logger/index.js +11 -12
  373. package/dist/oxc-parser/index.js +15 -14
  374. package/dist/oxc-parser/worker.js +10 -10
  375. package/dist/{manager/_manager-chunks/globals-runtime-8HkdnU2F.js → preview/_chunks/runtime-BYRCSYBN.js} +4440 -179
  376. package/dist/preview/_chunks/{runtime-BZSnICCg.js → runtime-Bvh_rfnQ.js} +29 -64
  377. package/dist/preview/_chunks/{runtime-iXdo8CR8.js → runtime-Cbq5WjbL.js} +772 -418
  378. package/dist/preview/_chunks/{runtime-q3wt0e_N.js → runtime-D2MPrqbU.js} +2 -2
  379. package/dist/preview/_chunks/{runtime-DrTjJkPY.js → runtime-DDEUZops.js} +453 -161
  380. package/dist/preview/_chunks/{runtime-BIzIdDbb.js → runtime-DS0s7U3c.js} +482 -334
  381. package/dist/preview/_chunks/{runtime-CsV4HZPV.js → runtime-DsjyhLpG.js} +397 -176
  382. package/dist/preview/_chunks/{runtime-CxZK_Ln3.js → runtime-Dwi6NFcX.js} +3 -3
  383. package/dist/preview/globals.d.ts +10 -10
  384. package/dist/preview/globals.js +10 -10
  385. package/dist/preview/runtime.js +1 -1
  386. package/dist/preview-api/index.d.ts +3 -3
  387. package/dist/preview-api/index.js +12 -10
  388. package/dist/preview-errors.d.ts +1 -1
  389. package/dist/preview-errors.js +2 -2
  390. package/dist/react/docgen/docgen-worker.js +11 -12
  391. package/dist/react/entry-preview-argtypes.js +1 -1
  392. package/dist/react/entry-preview-docs.js +1 -1
  393. package/dist/react/entry-preview.js +2 -1
  394. package/dist/react/index.d.ts +9 -11
  395. package/dist/react/index.js +8 -6
  396. package/dist/react/preset.js +13 -14
  397. package/dist/react/preview.d.ts +1 -1
  398. package/dist/react/preview.js +5 -4
  399. package/dist/react-native/bin/get-stories.js +12 -12
  400. package/dist/react-native/index.d.ts +48 -47
  401. package/dist/react-native/index.js +64 -249
  402. package/dist/react-native/metro/node.d.ts +3 -3
  403. package/dist/react-native/metro/node.js +10 -9
  404. package/dist/react-native/metro/{withStorybook.d.ts → withForkbook.d.ts} +18 -18
  405. package/dist/react-native/metro/{withStorybook.js → withForkbook.js} +27 -26
  406. package/dist/react-native/preview.js +4 -1
  407. package/dist/react-native/scripts/generate.d.ts +1 -1
  408. package/dist/react-native/scripts/generate.js +8 -8
  409. package/dist/react-native/stub.js +1 -1
  410. package/dist/react-native-theming/index.d.ts +2 -58
  411. package/dist/react-native-theming/index.js +63 -2338
  412. package/dist/react-native-ui/index.d.ts +14 -14
  413. package/dist/react-native-ui/index.js +8 -15
  414. package/dist/react-native-ui-common/index.d.ts +32 -12
  415. package/dist/react-native-ui-common/index.js +26 -31
  416. package/dist/react-vite/index.d.ts +2 -2
  417. package/dist/react-vite/node/index.d.ts +3 -3
  418. package/dist/react-vite/node/index.js +7 -7
  419. package/dist/react-vite/preset.d.ts +3 -1
  420. package/dist/react-vite/preset.js +16 -9
  421. package/dist/router/index.d.ts +80 -3
  422. package/dist/router/index.js +66 -12
  423. package/dist/server-errors.d.ts +1 -1
  424. package/dist/server-errors.js +9 -9
  425. package/dist/shared/open-service/index.d.ts +3 -3
  426. package/dist/shared/open-service/index.js +2 -2
  427. package/dist/shared/open-service/services/docgen/worker/docgen-worker.js +9 -9
  428. package/dist/shared/open-service/toolsets/docs/public.d.ts +28 -28
  429. package/dist/telemetry/index.d.ts +38 -274
  430. package/dist/telemetry/index.js +11 -68
  431. package/dist/test/index.d.ts +2 -2
  432. package/dist/test/index.js +765 -511
  433. package/dist/theming/create.d.ts +1 -1
  434. package/dist/theming/create.js +2 -1
  435. package/dist/theming/index.d.ts +6 -6
  436. package/dist/theming/index.js +41 -16
  437. package/dist/types/index.d.ts +2 -2
  438. package/dist/types/index.js +5 -5
  439. package/dist/viewport/index.d.ts +1 -1
  440. package/package.json +69 -69
  441. package/skills/setup/SKILL.md +14 -0
  442. package/skills/stories/SKILL.md +21 -0
  443. package/skills/write-story/SKILL.md +14 -0
  444. package/template/nextjs-vite/cli/js/Button.jsx +2 -2
  445. package/template/nextjs-vite/cli/js/Button.stories.js +6 -6
  446. package/template/nextjs-vite/cli/js/Configure.mdx +100 -100
  447. package/template/nextjs-vite/cli/js/Header.jsx +1 -1
  448. package/template/nextjs-vite/cli/js/Header.stories.js +2 -2
  449. package/template/nextjs-vite/cli/js/Page.jsx +3 -3
  450. package/template/nextjs-vite/cli/js/Page.stories.js +2 -2
  451. package/template/nextjs-vite/cli/ts/Button.stories.ts +6 -6
  452. package/template/nextjs-vite/cli/ts/Button.tsx +2 -2
  453. package/template/nextjs-vite/cli/ts/Configure.mdx +84 -84
  454. package/template/nextjs-vite/cli/ts/Header.stories.ts +2 -2
  455. package/template/nextjs-vite/cli/ts/Header.tsx +1 -1
  456. package/template/nextjs-vite/cli/ts/Page.stories.ts +2 -2
  457. package/template/nextjs-vite/cli/ts/Page.tsx +3 -3
  458. package/template/react/cli/js/Button.jsx +2 -2
  459. package/template/react/cli/js/Button.stories.js +6 -6
  460. package/template/react/cli/js/Header.jsx +1 -1
  461. package/template/react/cli/js/Header.stories.js +2 -2
  462. package/template/react/cli/js/Page.jsx +3 -3
  463. package/template/react/cli/js/Page.stories.js +2 -2
  464. package/template/react/cli/ts/Button.stories.ts +6 -6
  465. package/template/react/cli/ts/Button.tsx +2 -2
  466. package/template/react/cli/ts/Header.stories.ts +2 -2
  467. package/template/react/cli/ts/Header.tsx +1 -1
  468. package/template/react/cli/ts/Page.stories.ts +2 -2
  469. package/template/react/cli/ts/Page.tsx +3 -3
  470. package/template/react-vite/cli/js/Button.jsx +2 -2
  471. package/template/react-vite/cli/js/Button.stories.js +6 -6
  472. package/template/react-vite/cli/js/Header.jsx +1 -1
  473. package/template/react-vite/cli/js/Header.stories.js +2 -2
  474. package/template/react-vite/cli/js/Page.jsx +3 -3
  475. package/template/react-vite/cli/js/Page.stories.js +2 -2
  476. package/template/react-vite/cli/ts/Button.stories.ts +6 -6
  477. package/template/react-vite/cli/ts/Button.tsx +2 -2
  478. package/template/react-vite/cli/ts/Header.stories.ts +2 -2
  479. package/template/react-vite/cli/ts/Header.tsx +1 -1
  480. package/template/react-vite/cli/ts/Page.stories.ts +2 -2
  481. package/template/react-vite/cli/ts/Page.tsx +3 -3
  482. package/assets/browser/nunito-sans-bold-italic.woff2 +0 -0
  483. package/assets/browser/nunito-sans-bold.woff2 +0 -0
  484. package/assets/browser/nunito-sans-italic.woff2 +0 -0
  485. package/assets/browser/nunito-sans-regular.woff2 +0 -0
  486. package/dist/_browser-chunks/WithTooltip-XSQFTBMB.js +0 -1619
  487. package/dist/_browser-chunks/chunk-5P4QA6MY.js +0 -20
  488. package/dist/_browser-chunks/chunk-JMC7AIKT.js +0 -108
  489. package/dist/_node-chunks/builder-manager-VVHYQXCH.js +0 -1661
  490. package/dist/_node-chunks/chunk-2RU7BKEW.js +0 -23
  491. package/dist/_node-chunks/chunk-3BKIBF5S.js +0 -3008
  492. package/dist/_node-chunks/chunk-3T4ZSNPH.js +0 -662
  493. package/dist/_node-chunks/chunk-5DQFEZEA.js +0 -40
  494. package/dist/_node-chunks/chunk-6LMWA44H.js +0 -3837
  495. package/dist/_node-chunks/chunk-BXVYT7SB.js +0 -36
  496. package/dist/_node-chunks/chunk-CQKMLL5J.js +0 -33
  497. package/dist/_node-chunks/chunk-EHUNOMDD.js +0 -52345
  498. package/dist/_node-chunks/chunk-FY6UXW6G.js +0 -11
  499. package/dist/_node-chunks/chunk-GRBLDJCR.js +0 -989
  500. package/dist/_node-chunks/chunk-IDEL2J23.js +0 -23
  501. package/dist/_node-chunks/chunk-JPAZLYJ3.js +0 -29
  502. package/dist/_node-chunks/chunk-MK2KYAI6.js +0 -5414
  503. package/dist/_node-chunks/chunk-NPO45IMH.js +0 -33
  504. package/dist/_node-chunks/chunk-QEQLR22M.js +0 -1877
  505. package/dist/_node-chunks/chunk-RZMQ7S3L.js +0 -92
  506. package/dist/_node-chunks/chunk-SIEXZVCR.js +0 -51
  507. package/dist/_node-chunks/chunk-TEQGGSP7.js +0 -33
  508. package/dist/_node-chunks/chunk-TFCEV2XX.js +0 -155
  509. package/dist/_node-chunks/chunk-UBOGWBEA.js +0 -148
  510. package/dist/_node-chunks/chunk-W4OMYLSP.js +0 -1297
  511. package/dist/_node-chunks/chunk-WAXVSN3O.js +0 -18
  512. package/dist/_node-chunks/chunk-ZMAMXQKP.js +0 -4731
  513. package/dist/_node-chunks/dist-VTSTZKUB.js +0 -16
  514. package/dist/_node-chunks/globby-OEMHPBFY.js +0 -2884
  515. package/dist/_node-chunks/jiti-NFX6UU74.js +0 -3848
  516. package/dist/_node-chunks/lib-MDVARD7W.js +0 -366
  517. package/dist/_node-chunks/optimized-tests-HDOLR3EY.js +0 -22
  518. package/dist/_node-chunks/postinstallAddon-GYGMWDL6.js +0 -20
  519. package/dist/_node-chunks/session-id-KIIVOQLR.js +0 -23
  520. package/dist/chunk-BTVrWliM.d.ts +0 -115
  521. package/dist/chunk-BfBzpgct.d.ts +0 -916
  522. package/dist/chunk-BxWufQms.d.ts +0 -142
  523. package/dist/chunk-DaVb55-_.d.ts +0 -124
  524. package/dist/core-server/presets/common-manager.css +0 -170
  525. package/dist/manager/_manager-chunks/globals-runtime-BIKBO23x.js +0 -3389
  526. package/dist/manager/_manager-chunks/globals-runtime-DkAPXCvc.js +0 -9766
  527. package/dist/manager/_manager-chunks/globals-runtime-DtcOnYHR.js +0 -5357
  528. package/dist/manager/_manager-chunks/globals-runtime-ZHrQFa3-.js +0 -10463
  529. package/dist/manager/_manager-chunks/runtime-B1L9TH89.js +0 -452
  530. package/dist/manager/_manager-chunks/runtime-BK0zF7FN.js +0 -22
  531. package/dist/manager/_manager-chunks/runtime-Bly6WJLN.js +0 -998
  532. package/dist/manager/_manager-chunks/runtime-DMig8mT7.js +0 -77
  533. package/dist/preview/_chunks/runtime-BTPtVY1p.js +0 -1102
  534. package/dist/preview/_chunks/runtime-BwSxqk3t.js +0 -63
  535. package/dist/preview/_chunks/runtime-DZToXfvO.js +0 -9767
  536. package/dist/preview/_chunks/runtime-DuHdxMFA.js +0 -387
@@ -1,27 +1,18 @@
1
1
  import { a as __toESM, n as __esmMin, r as __exportAll } from "./globals-runtime-BdGkqNEt.js";
2
- import { A as unknown, C as object, D as safeInteger, E as record, O as safeParse, S as number, T as pipe, U as dedent, W as init_esm, _ as custom, b as minLength, f as T, g as check, h as array, j as variant, k as string, p as init_dist$1, v as init_dist, w as optional, x as minValue, y as literal } from "./globals-runtime-eLPTIfX-.js";
3
- import { $ as once, Q as logger, Y as init_core_events, Z as init_client_logger, c as init_channel_slot, et as Channel, h as NAVIGATE_URL, o as init_channels, s as getChannel } from "./globals-runtime-DpNYC-qi.js";
4
- import { C as init_dist$2, w as scope } from "./globals-runtime-DtcOnYHR.js";
5
- import { E as parse, S as init_main$1, _ as curriedOpacify$1, b as init_index_browser, c as Link$1, d as Router, g as curriedLighten$1, h as curriedDarken$1, j as require_react, l as init_dist$4, m as useNavigate$1, p as useLocation, s as BrowserRouter, u as MemoryRouter$1, v as init_polished_esm, w as stringify, x as nanoid, y as rgba } from "./globals-runtime-ZHrQFa3-.js";
6
- import { C as Assertion, D as use, E as init_chai, K as init_isEqual, M as init_deepsignal_core_module, N as l, O as utils_exports, T as expect$2, X as require_memoizerific, Y as isPlainObject$2, j as g, n as deletedDiff, q as isEqual, r as init_deleted, w as assert } from "./globals-runtime-BvM-NY2g.js";
7
- import { _ as n, f, h as j, m as init_signals_core_module, p as g$1, v as y } from "./globals-runtime-BIKBO23x.js";
8
- import { a as customMatchers, c as setState, d as isMockFunction, f as mocks, i as JestExtend, l as fn$1, n as JestAsymmetricMatchers, o as getState, p as spyOn$1, r as JestChaiExpect, s as init_dist$5, t as GLOBAL_EXPECT, u as init_dist$6 } from "./globals-runtime-FC201B7s.js";
9
- import { a as matchers_exports, i as init_matchers, r as userEvent$1, t as init_esm$1 } from "./globals-runtime-8HkdnU2F.js";
10
- import { r as init_dom_esm, t as dom_esm_exports } from "./globals-runtime-DkAPXCvc.js";
11
- import { C as init_manager_errors, S as UniversalStoreFollowerTimeoutError, _ as StatusTypeIdMismatchError$2, b as OpenServiceStaticSnapshotLoadError, c as init_instrumenter, i as init_manager_api, l as instrument, m as addons, v as init_preview_errors, x as StatusTypeIdMismatchError$1, y as OpenServiceStaticSnapshotInvalidError } from "./globals-runtime-qKvCZHFY.js";
2
+ import { C as pipe, D as string, E as safeParse, H as init_esm, O as unknown, S as optional, T as safeInteger, V as dedent, _ as literal, b as number, d as init_dist$1, g as init_dist, h as custom, k as variant, m as check, p as array, u as T, v as minLength, w as record, x as object, y as minValue } from "./globals-runtime-BnQ7i5wq.js";
3
+ import { $ as once, Q as logger, Y as init_core_events, Z as init_client_logger, c as init_channel_slot, et as Channel, h as NAVIGATE_URL, o as init_channels, s as getChannel } from "./globals-runtime-DpvE_zRs.js";
4
+ import { a as BrowserRouter, c as MemoryRouter$1, d as useLocation, f as useNavigate$1, l as Router, o as Link$1, s as init_dist$3 } from "./globals-runtime-CoTrrHG3.js";
5
+ import { i as require_react } from "./globals-runtime-nQMRiA0J.js";
6
+ import { C as use, D as l, E as init_deepsignal_core_module, R as init_isEqual, S as init_chai, T as g, V as isPlainObject$2, b as assert, n as deletedDiff, r as init_deleted, w as utils_exports, x as expect$2, y as Assertion, z as isEqual } from "./globals-runtime-B4NRbNSS.js";
7
+ import { d as g$1, f as init_signals_core_module, g as y, h as n, p as j, u as f } from "./globals-runtime-CS41oTca.js";
8
+ import { Ws as require_memoizerific, o as init_index_browser, s as nanoid } from "./globals-runtime-oRjPg2jY.js";
9
+ import { a as rgba, c as stringify, i as init_polished_esm, n as curriedLighten$1, o as init_main$1, r as curriedOpacify$1, t as curriedDarken$1, u as parse } from "./globals-runtime-BzuYs3dZ.js";
10
+ import { a as customMatchers, c as setState, d as isMockFunction, f as mocks, i as JestExtend, l as fn$1, n as JestAsymmetricMatchers, o as getState, p as spyOn$1, r as JestChaiExpect, s as init_dist$4, t as GLOBAL_EXPECT, u as init_dist$5 } from "./globals-runtime-DCmvKMN5.js";
11
+ import { a as init_dom_esm, i as dom_esm_exports, o as init_matchers, r as userEvent$1, s as matchers_exports, t as init_esm$1 } from "./globals-runtime-BC43T1rL.js";
12
+ import { A as init_open_service, B as init_manager_errors, C as OpenServiceMissingServiceError, D as OpenServiceRemoteCommandUnhandledError, E as OpenServiceRemoteCommandDisconnectedError, F as init_preview_errors, I as OpenServiceStaticSnapshotInvalidError, L as OpenServiceStaticSnapshotLoadError, M as init_dev_server, O as OpenServiceUnimplementedOperationError, P as StatusTypeIdMismatchError$2, R as StatusTypeIdMismatchError$1, S as OpenServiceMissingChannelError, T as OpenServiceRemoteCommandConfigDriftError, _ as OpenServiceAsyncSchemaError, b as OpenServiceInvalidStaticPathError, c as init_instrumenter, f as init_csf_utils, g as OpenServiceAsyncRecipeError, i as init_manager_api, j as StatusTypeIdMismatchError, k as OpenServiceValidationError, l as instrument, m as addons, p as sanitize, v as OpenServiceCyclicStateError, w as OpenServiceOperationNameCollisionError, x as OpenServiceLoadedDrainExceededError, y as OpenServiceInternalServiceError, z as UniversalStoreFollowerTimeoutError } from "./globals-runtime-BJ6EZqH7.js";
12
13
  //#region src/storybook-error.ts
13
14
  function parseErrorCode({ code, category }) {
14
- return `SB_${category}_${String(code).padStart(4, "0")}`;
15
- }
16
- function appendErrorRef(url) {
17
- if (/^(?!.*storybook\.js\.org)|[?&]ref=error\b/.test(url)) return url;
18
- try {
19
- const urlObj = new URL(url);
20
- urlObj.searchParams.set("ref", "error");
21
- return urlObj.toString();
22
- } catch {
23
- return url;
24
- }
15
+ return `FB_${category}_${String(code).padStart(4, "0")}`;
25
16
  }
26
17
  var StorybookError;
27
18
  function init_storybook_error() {
@@ -33,7 +24,7 @@ function init_storybook_error() {
33
24
  category: this.category
34
25
  });
35
26
  }
36
- /** Overrides the default `Error.name` property in the format: SB_<CATEGORY>_<CODE>. */
27
+ /** Overrides the default `Error.name` property in the format: FB_<CATEGORY>_<CODE>. */
37
28
  get name() {
38
29
  const errorName = this._name || this.constructor.name;
39
30
  return `${this.fullErrorCode} (${errorName})`;
@@ -58,12 +49,12 @@ function init_storybook_error() {
58
49
  /** Generates the error message along with additional documentation link (if applicable). */
59
50
  static getFullMessage({ documentation, code, category, message }) {
60
51
  let page;
61
- if (documentation === true) page = `https://storybook.js.org/error/${parseErrorCode({
52
+ if (documentation === true) page = `https://forkbook.ljk.dev/error/${parseErrorCode({
62
53
  code,
63
54
  category
64
- })}?ref=error`;
65
- else if (typeof documentation === "string") page = appendErrorRef(documentation);
66
- else if (Array.isArray(documentation)) page = `\n${documentation.map((doc) => `\t- ${appendErrorRef(doc)}`).join("\n")}`;
55
+ })}`;
56
+ else if (typeof documentation === "string") page = documentation;
57
+ else if (Array.isArray(documentation)) page = `\n${documentation.map((doc) => `\t- ${doc}`).join("\n")}`;
67
58
  return `${message}${page != null ? `\n\nMore info: ${page}\n` : ""}`;
68
59
  }
69
60
  };
@@ -92,6 +83,13 @@ function init_instances() {
92
83
  }
93
84
  //#endregion
94
85
  //#region src/shared/universal-store/index.ts
86
+ /**
87
+ * Whether `event` has the type `type`. A custom event's `type` is any string, so a `switch` on
88
+ * `event.type` cannot narrow an event union to one payload, but this check can.
89
+ */
90
+ function hasType(event, type) {
91
+ return event.type === type;
92
+ }
95
93
  var CHANNEL_EVENT_PREFIX, ProgressState, UniversalStore;
96
94
  function init_universal_store() {
97
95
  return (init_universal_store = __esmMin((() => {
@@ -371,8 +369,8 @@ function init_universal_store() {
371
369
  */
372
370
  onStateChange(listener) {
373
371
  this.debug("onStateChange", { listener });
374
- return this.subscribe(UniversalStore.InternalEventType.SET_STATE, ({ payload }, eventInfo) => {
375
- listener(payload.state, payload.previousState, eventInfo);
372
+ return this.subscribe(UniversalStore.InternalEventType.SET_STATE, (event, eventInfo) => {
373
+ if (hasType(event, UniversalStore.InternalEventType.SET_STATE)) listener(event.payload.state, event.payload.previousState, eventInfo);
376
374
  });
377
375
  }
378
376
  emitToChannel(event, eventInfo) {
@@ -455,10 +453,9 @@ function init_universal_store() {
455
453
  });
456
454
  }
457
455
  }
458
- if (this.actor.type === UniversalStore.ActorType.FOLLOWER) switch (event.type) {
459
- case UniversalStore.InternalEventType.EXISTING_STATE_RESPONSE:
460
- this.debug("handleChannelEvents: Setting state from leader's existing state response", { event });
461
- if (this.syncing?.state !== ProgressState.PENDING) break;
456
+ if (this.actor.type === UniversalStore.ActorType.FOLLOWER && hasType(event, UniversalStore.InternalEventType.EXISTING_STATE_RESPONSE)) {
457
+ this.debug("handleChannelEvents: Setting state from leader's existing state response", { event });
458
+ if (this.syncing?.state === ProgressState.PENDING) {
462
459
  this.syncing.resolve?.();
463
460
  const setStateEvent = {
464
461
  type: UniversalStore.InternalEventType.SET_STATE,
@@ -469,11 +466,11 @@ function init_universal_store() {
469
466
  };
470
467
  this.state = event.payload;
471
468
  this.emitToListeners(setStateEvent, eventInfo);
469
+ }
472
470
  }
473
- switch (event.type) {
474
- case UniversalStore.InternalEventType.SET_STATE:
475
- this.debug("handleChannelEvents: Setting state", { event });
476
- this.state = event.payload.state;
471
+ if (hasType(event, UniversalStore.InternalEventType.SET_STATE)) {
472
+ this.debug("handleChannelEvents: Setting state", { event });
473
+ this.state = event.payload.state;
477
474
  }
478
475
  this.emitToListeners(event, { actor: eventInfo.actor });
479
476
  }
@@ -500,6 +497,14 @@ function init_universal_store() {
500
497
  })))();
501
498
  }
502
499
  //#endregion
500
+ //#region src/shared/global.ts
501
+ var global;
502
+ function init_global() {
503
+ return (init_global = __esmMin((() => {
504
+ global = globalThis;
505
+ })))();
506
+ }
507
+ //#endregion
503
508
  //#region src/shared/utils/local-hosts.ts
504
509
  var LOOPBACK_HOSTNAMES, matchesHostname;
505
510
  function init_local_hosts() {
@@ -565,13 +570,15 @@ function init_announce() {
565
570
  }
566
571
  //#endregion
567
572
  //#region src/shared/useCopyButton.ts
568
- function useCopyButton({ children = "Copy", childrenOnCopy = "Copied!", content, onCopy, ariaLabel = false, ariaLabelOnCopy = false, duration = 3e3 }) {
569
- const [copied, setCopied] = (0, import_react$5.useState)(false);
570
- const timerRef = (0, import_react$5.useRef)(null);
571
- (0, import_react$5.useEffect)(() => () => {
573
+ function useCopyButton({ children, childrenOnCopy, content, onCopy, ariaLabel = false, ariaLabelOnCopy = false, duration = 3e3 }) {
574
+ const label = children === void 0 ? "Copy" : children;
575
+ const labelOnCopy = childrenOnCopy === void 0 ? "Copied!" : childrenOnCopy;
576
+ const [copied, setCopied] = (0, import_react$6.useState)(false);
577
+ const timerRef = (0, import_react$6.useRef)(null);
578
+ (0, import_react$6.useEffect)(() => () => {
572
579
  if (timerRef.current) clearTimeout(timerRef.current);
573
580
  }, []);
574
- const handleClick = (0, import_react$5.useCallback)((e) => {
581
+ const handleClick = (0, import_react$6.useCallback)((e) => {
575
582
  if (timerRef.current) clearTimeout(timerRef.current);
576
583
  const announcement = typeof ariaLabelOnCopy === "string" ? ariaLabelOnCopy : "Copied to clipboard";
577
584
  navigator.clipboard?.writeText(content).then(() => {
@@ -591,8 +598,8 @@ function useCopyButton({ children = "Copy", childrenOnCopy = "Copied!", content,
591
598
  duration
592
599
  ]);
593
600
  return {
594
- children: copied ? childrenOnCopy : children,
595
- buttonProps: (0, import_react$5.useMemo)(() => ({
601
+ children: copied ? labelOnCopy : label,
602
+ buttonProps: (0, import_react$6.useMemo)(() => ({
596
603
  onClick: handleClick,
597
604
  ariaLabel: copied ? ariaLabelOnCopy : ariaLabel
598
605
  }), [
@@ -603,10 +610,10 @@ function useCopyButton({ children = "Copy", childrenOnCopy = "Copied!", content,
603
610
  ])
604
611
  };
605
612
  }
606
- var import_react$5;
613
+ var import_react$6;
607
614
  function init_useCopyButton() {
608
615
  return (init_useCopyButton = __esmMin((() => {
609
- import_react$5 = require_react();
616
+ import_react$6 = require_react();
610
617
  init_announce();
611
618
  })))();
612
619
  }
@@ -635,176 +642,8 @@ function formatIssues(issues) {
635
642
  return path === "" ? issue.message : `${path}: ${issue.message}`;
636
643
  }).join("\n");
637
644
  }
638
- //#endregion
639
- //#region src/server-errors.ts
640
- var OpenServiceValidationError, OpenServiceMissingServiceError, OpenServiceInternalServiceError, OpenServiceUnimplementedOperationError, OpenServiceInvalidStaticPathError, OpenServiceAsyncSchemaError, OpenServiceLoadedDrainExceededError, OpenServiceMissingChannelError, OpenServiceRemoteCommandDisconnectedError, OpenServiceRemoteCommandUnhandledError, OpenServiceRemoteCommandConfigDriftError, OpenServiceAsyncRecipeError, OpenServiceCyclicStateError, OpenServiceOperationNameCollisionError, StatusTypeIdMismatchError;
641
- function init_server_errors() {
642
- return (init_server_errors = __esmMin((() => {
643
- init_storybook_error();
644
- OpenServiceValidationError = class extends StorybookError {
645
- constructor(data) {
646
- super({
647
- name: "OpenServiceValidationError",
648
- category: "CORE-COMMON",
649
- code: 5,
650
- message: `Invalid ${data.phase} for ${data.kind} "${data.serviceId}.${data.name}":\n${formatIssues(data.issues)}`
651
- });
652
- this.data = data;
653
- }
654
- };
655
- OpenServiceMissingServiceError = class extends StorybookError {
656
- constructor(data) {
657
- super({
658
- name: "OpenServiceMissingServiceError",
659
- category: "CORE-COMMON",
660
- code: 7,
661
- message: `No registered service with id "${data.serviceId}" exists in this environment.`
662
- });
663
- this.data = data;
664
- }
665
- };
666
- OpenServiceInternalServiceError = class extends StorybookError {
667
- constructor(data) {
668
- super({
669
- name: "OpenServiceInternalServiceError",
670
- category: "CORE-COMMON",
671
- code: 19,
672
- message: `Service "${data.serviceId}" is internal. Pass { internal: true } to getService() only if you intentionally depend on an unstable OSA surface. Internal services may change without notice.`
673
- });
674
- this.data = data;
675
- }
676
- };
677
- OpenServiceUnimplementedOperationError = class extends StorybookError {
678
- constructor(data) {
679
- super({
680
- name: "OpenServiceUnimplementedOperationError",
681
- category: "CORE-COMMON",
682
- code: 8,
683
- message: `${data.kind[0].toUpperCase()}${data.kind.slice(1)} "${data.serviceId}.${data.name}" is not implemented for this environment.`
684
- });
685
- this.data = data;
686
- }
687
- };
688
- OpenServiceInvalidStaticPathError = class extends StorybookError {
689
- constructor(data) {
690
- super({
691
- name: "OpenServiceInvalidStaticPathError",
692
- category: "CORE-COMMON",
693
- code: 10,
694
- message: `Invalid static path "${data.path}" for query "${data.serviceId}.${data.name}": use a relative path with forward slashes and no ".." segments.`
695
- });
696
- this.data = data;
697
- }
698
- };
699
- OpenServiceAsyncSchemaError = class extends StorybookError {
700
- constructor(data) {
701
- super({
702
- name: "OpenServiceAsyncSchemaError",
703
- category: "CORE-COMMON",
704
- code: 9,
705
- message: `Async schema for ${data.kind} "${data.serviceId}.${data.name}" (${data.phase}): query input and output schemas must validate synchronously.`
706
- });
707
- this.data = data;
708
- }
709
- };
710
- OpenServiceLoadedDrainExceededError = class extends StorybookError {
711
- constructor(data) {
712
- super({
713
- name: "OpenServiceLoadedDrainExceededError",
714
- category: "CORE-COMMON",
715
- code: 11,
716
- message: `Query "${data.serviceId}.${data.name}".loaded(...) did not settle after ${data.iterations} drain iterations. Check for handlers that keep discovering new dependencies after every state change.`
717
- });
718
- this.data = data;
719
- }
720
- };
721
- OpenServiceMissingChannelError = class extends StorybookError {
722
- constructor(data = {}) {
723
- super({
724
- name: "OpenServiceMissingChannelError",
725
- category: "CORE-COMMON",
726
- code: 13,
727
- message: data.serviceId ? `Cannot register service "${data.serviceId}": the Forkbook addons channel is not installed in this runtime.` : "The Forkbook addons channel is not installed in this runtime."
728
- });
729
- this.data = data;
730
- }
731
- };
732
- OpenServiceRemoteCommandDisconnectedError = class extends StorybookError {
733
- constructor(data) {
734
- super({
735
- name: "OpenServiceRemoteCommandDisconnectedError",
736
- category: "CORE-COMMON",
737
- code: 14,
738
- message: `Service "${data.serviceId}" was unregistered before a remote command resolved.`
739
- });
740
- this.data = data;
741
- }
742
- };
743
- OpenServiceRemoteCommandUnhandledError = class extends StorybookError {
744
- constructor(data) {
745
- super({
746
- name: "OpenServiceRemoteCommandUnhandledError",
747
- category: "CORE-COMMON",
748
- code: 15,
749
- message: data.delegated ? `The Forkbook this runtime is attached to did not acknowledge remote command "${data.serviceId}.${data.commandName}" in time — it may be busy or unreachable. Retry; note the command may still have executed on that instance.` : `No runtime acknowledged remote command "${data.serviceId}.${data.commandName}"; its handler is not implemented in any connected runtime.`
750
- });
751
- this.data = data;
752
- }
753
- };
754
- OpenServiceRemoteCommandConfigDriftError = class extends StorybookError {
755
- constructor(data) {
756
- super({
757
- name: "OpenServiceRemoteCommandConfigDriftError",
758
- category: "CORE-COMMON",
759
- code: 30,
760
- message: `The Forkbook this runtime is attached to reported it has no handler for remote command "${data.serviceId}.${data.commandName}". The two processes are running different configurations (for example a feature flag enabled in one but not the other). Restart the attached Forkbook with a configuration matching this process.`
761
- });
762
- this.data = data;
763
- }
764
- };
765
- OpenServiceAsyncRecipeError = class extends StorybookError {
766
- constructor() {
767
- super({
768
- name: "OpenServiceAsyncRecipeError",
769
- category: "CORE-COMMON",
770
- code: 31,
771
- message: "setState recipes must be synchronous. A write after an await would change state without authoring a sync entry. Split the command into one setState per synchronous step."
772
- });
773
- }
774
- };
775
- OpenServiceCyclicStateError = class extends StorybookError {
776
- constructor() {
777
- super({
778
- name: "OpenServiceCyclicStateError",
779
- category: "CORE-COMMON",
780
- code: 32,
781
- message: "Service state must be JSON-serializable, but the value is cyclic or nested more than 256 levels deep. Store an id and look the value up in a query instead of a reference."
782
- });
783
- }
784
- };
785
- OpenServiceOperationNameCollisionError = class extends StorybookError {
786
- constructor(data) {
787
- super({
788
- name: "OpenServiceOperationNameCollisionError",
789
- category: "CORE-COMMON",
790
- code: 16,
791
- message: `Service "${data.serviceId}" cannot register "${data.operationName}" as both a query and a command.`
792
- });
793
- this.data = data;
794
- }
795
- };
796
- StatusTypeIdMismatchError = class extends StorybookError {
797
- constructor(data) {
798
- super({
799
- name: "StatusTypeIdMismatchError",
800
- category: "CORE-SERVER",
801
- code: 16,
802
- message: `Status has typeId "${data.status.typeId}" but was added to store with typeId "${data.typeId}". Full status: ${JSON.stringify(data.status, null, 2)}`
803
- });
804
- this.data = data;
805
- }
806
- };
807
- })))();
645
+ function init_errors() {
646
+ return (init_errors = __esmMin((() => {})))();
808
647
  }
809
648
  //#endregion
810
649
  //#region src/shared/status-store/index.ts
@@ -924,7 +763,7 @@ function init_status_store() {
924
763
  return (init_status_store = __esmMin((() => {
925
764
  init_manager_errors();
926
765
  init_preview_errors();
927
- init_server_errors();
766
+ init_dev_server();
928
767
  STATUS_VALUE_PREFIX = "status-value:";
929
768
  STATUS_VALUES = [
930
769
  "status-value:pending",
@@ -1041,7 +880,7 @@ function clonePlain(value, depth = 0) {
1041
880
  var FORBIDDEN_KEYS, MAX_DEPTH;
1042
881
  function init_plain_object() {
1043
882
  return (init_plain_object = __esmMin((() => {
1044
- init_server_errors();
883
+ init_open_service();
1045
884
  FORBIDDEN_KEYS = /* @__PURE__ */ new Set([
1046
885
  "__proto__",
1047
886
  "constructor",
@@ -1422,65 +1261,13 @@ function init_patch_recorder() {
1422
1261
  return (init_patch_recorder = __esmMin((() => {
1423
1262
  init_signals_core_module();
1424
1263
  init_deepsignal_core_module();
1425
- init_server_errors();
1264
+ init_open_service();
1426
1265
  init_plain_object();
1427
1266
  init_service_channel();
1428
1267
  activeDrafts = /* @__PURE__ */ new WeakMap();
1429
1268
  })))();
1430
1269
  }
1431
1270
  //#endregion
1432
- //#region src/shared/open-service/query-state.ts
1433
- /**
1434
- * Expands a `(data, lifecycle)` pair into the full {@link QueryState} surfaced to subscribers.
1435
- *
1436
- * The single source of truth for the derived booleans, shared by the runtime's subscription
1437
- * emissions and `useServiceQuery`'s first-render seed so they can never drift apart. The booleans
1438
- * intentionally follow our `load` vocabulary: `isLoading` is "any load in flight" (TanStack's
1439
- * `isFetching`) and `isInitialLoading` is "the first load with nothing to show yet".
1440
- *
1441
- * Unlike TanStack Query, a subscription here can attach to a query whose `data` is already cached in
1442
- * service state (e.g. revisiting an already-extracted component): its per-subscription lifecycle
1443
- * still starts `pending`/`loading`, but `data` is present from the first emission. `isInitialLoading`
1444
- * therefore also requires `data === undefined`, so consumers gate a "nothing yet" skeleton on it
1445
- * without flashing it over already-available data while a background (re)load runs.
1446
- */
1447
- function buildQueryState(data, lifecycle) {
1448
- const isPending = lifecycle.status === "pending";
1449
- const isLoading = lifecycle.loadStatus === "loading";
1450
- return {
1451
- data,
1452
- error: lifecycle.error,
1453
- status: lifecycle.status,
1454
- loadStatus: lifecycle.loadStatus,
1455
- isPending,
1456
- isSuccess: lifecycle.status === "success",
1457
- isError: lifecycle.status === "error",
1458
- isLoading,
1459
- isInitialLoading: isPending && isLoading && data === void 0,
1460
- isRefreshing: isLoading && !isPending
1461
- };
1462
- }
1463
- /** Coerces an unknown thrown value into an `Error` for the `error` field of a {@link QueryState}. */
1464
- function toError(value) {
1465
- return value instanceof Error ? value : new Error(String(value));
1466
- }
1467
- function seedQueryState(query, input, selector) {
1468
- try {
1469
- const output = query.get(input);
1470
- return buildQueryState(selector ? selector(output) : output, {
1471
- status: "pending",
1472
- error: void 0,
1473
- loadStatus: "loading"
1474
- });
1475
- } catch (error) {
1476
- return buildQueryState(void 0, {
1477
- status: "error",
1478
- error: toError(error),
1479
- loadStatus: "idle"
1480
- });
1481
- }
1482
- }
1483
- //#endregion
1484
1271
  //#region src/shared/open-service/service-validation.ts
1485
1272
  /**
1486
1273
  * Re-throws asynchronous subscription failures on the microtask queue so they are not silently
@@ -1528,11 +1315,11 @@ function validateSchemaSync(schema, value, meta) {
1528
1315
  }
1529
1316
  function init_service_validation() {
1530
1317
  return (init_service_validation = __esmMin((() => {
1531
- init_server_errors();
1318
+ init_open_service();
1532
1319
  })))();
1533
1320
  }
1534
1321
  //#endregion
1535
- //#region src/shared/open-service/query-runtime.ts
1322
+ //#region src/shared/open-service/query-load-registry.ts
1536
1323
  /**
1537
1324
  * Returns a deterministic JSON encoding so the same logical input always produces the same key.
1538
1325
  *
@@ -1596,10 +1383,10 @@ function surfaceRejections(settlements) {
1596
1383
  async function drainCollector(collector, settledKeys, serviceId, queryName) {
1597
1384
  let iterations = 0;
1598
1385
  while (collector.size > 0) {
1599
- if (iterations++ > MAX_DRAIN_ITERATIONS) throw new OpenServiceLoadedDrainExceededError({
1386
+ if (iterations++ > 32) throw new OpenServiceLoadedDrainExceededError({
1600
1387
  serviceId,
1601
1388
  name: queryName,
1602
- iterations: MAX_DRAIN_ITERATIONS
1389
+ iterations: 32
1603
1390
  });
1604
1391
  const pending = [...collector];
1605
1392
  collector.clear();
@@ -1624,6 +1411,18 @@ function detachSnapshot(value) {
1624
1411
  if (value === null || typeof value !== "object") return value;
1625
1412
  return JSON.parse(JSON.stringify(value));
1626
1413
  }
1414
+ var inFlightLoads, nextLoadScopeSequence, nextLoadScopeId, EMPTY_SET;
1415
+ function init_query_load_registry() {
1416
+ return (init_query_load_registry = __esmMin((() => {
1417
+ init_open_service();
1418
+ inFlightLoads = /* @__PURE__ */ new Map();
1419
+ nextLoadScopeSequence = 0;
1420
+ nextLoadScopeId = () => String(nextLoadScopeSequence += 1);
1421
+ EMPTY_SET = /* @__PURE__ */ new Set();
1422
+ })))();
1423
+ }
1424
+ //#endregion
1425
+ //#region src/shared/open-service/query-handler.ts
1627
1426
  /**
1628
1427
  * Validates query input synchronously, falling through to the dedicated async-schema error if a
1629
1428
  * schema returns a Promise.
@@ -1665,30 +1464,247 @@ function runHandlerSync(refs, queryName, queryDef, validatedInput, selfQueries,
1665
1464
  },
1666
1465
  getService
1667
1466
  };
1668
- return queryDef.handler(validatedInput, handlerCtx);
1467
+ return queryDef.handler(validatedInput, handlerCtx);
1468
+ }
1469
+ /**
1470
+ * Builds the shared synchronous `get(input)` for a query: validate input → fire the load per the
1471
+ * caller's policy → run the handler against `selfQueries` → validate output.
1472
+ *
1473
+ * The three query surfaces — the default consumer query ({@link createDefaultQuery}), the reactive
1474
+ * subscription-load wrappers ({@link buildReactiveLoadQueries}), and the awaited load-body wrappers
1475
+ * ({@link buildLoadWrappedQueries}) — differ only in (a) which `self.queries` map the handler sees
1476
+ * and (b) how a load-backed read fires its `load`. Everything else (the validate → run → validate
1477
+ * skeleton, the zero-arg input resolution) is identical, so each surface passes its own `selfQueries`
1478
+ * map and `fireLoad` policy and shares this body.
1479
+ *
1480
+ * `fireLoad` is invoked only for queries that declare a `load`; queries without one skip it. Pass
1481
+ * `selfQueries` by reference even when it is the same map being populated by the caller — `get`
1482
+ * closes over the reference, which is fully built by the time any handler runs.
1483
+ */
1484
+ function createQueryGet(refs, queryName, queryDef, selfQueries, fireLoad) {
1485
+ return function get(input) {
1486
+ const validatedInput = validateQueryInput(refs, queryName, queryDef, arguments.length === 0 ? void 0 : input);
1487
+ if (queryDef.load) fireLoad?.(validatedInput);
1488
+ return validateQueryOutput(refs, queryName, queryDef, runHandlerSync(refs, queryName, queryDef, validatedInput, selfQueries, refs.registryApi.getService));
1489
+ };
1490
+ }
1491
+ function init_query_handler() {
1492
+ return (init_query_handler = __esmMin((() => {
1493
+ init_open_service();
1494
+ init_service_validation();
1495
+ })))();
1496
+ }
1497
+ //#endregion
1498
+ //#region src/shared/open-service/query-state.ts
1499
+ /**
1500
+ * Expands a `(data, lifecycle)` pair into the full {@link QueryState} surfaced to subscribers.
1501
+ *
1502
+ * The single source of truth for the derived booleans, shared by the runtime's subscription
1503
+ * emissions and `useServiceQuery`'s first-render seed so they can never drift apart. The booleans
1504
+ * intentionally follow our `load` vocabulary: `isLoading` is "any load in flight" (TanStack's
1505
+ * `isFetching`) and `isInitialLoading` is "the first load with nothing to show yet".
1506
+ *
1507
+ * Unlike TanStack Query, a subscription here can attach to a query whose `data` is already cached in
1508
+ * service state (e.g. revisiting an already-extracted component): its per-subscription lifecycle
1509
+ * still starts `pending`/`loading`, but `data` is present from the first emission. `isInitialLoading`
1510
+ * therefore also requires `data === undefined`, so consumers gate a "nothing yet" skeleton on it
1511
+ * without flashing it over already-available data while a background (re)load runs.
1512
+ */
1513
+ function buildQueryState(data, lifecycle) {
1514
+ const isPending = lifecycle.status === "pending";
1515
+ const isLoading = lifecycle.loadStatus === "loading";
1516
+ return {
1517
+ data,
1518
+ error: lifecycle.error,
1519
+ status: lifecycle.status,
1520
+ loadStatus: lifecycle.loadStatus,
1521
+ isPending,
1522
+ isSuccess: lifecycle.status === "success",
1523
+ isError: lifecycle.status === "error",
1524
+ isLoading,
1525
+ isInitialLoading: isPending && isLoading && data === void 0,
1526
+ isRefreshing: isLoading && !isPending
1527
+ };
1528
+ }
1529
+ /** Coerces an unknown thrown value into an `Error` for the `error` field of a {@link QueryState}. */
1530
+ function toError(value) {
1531
+ return value instanceof Error ? value : new Error(String(value));
1532
+ }
1533
+ function seedQueryState(query, input, selector) {
1534
+ try {
1535
+ const output = query.get(input);
1536
+ return buildQueryState(selector ? selector(output) : output, {
1537
+ status: "pending",
1538
+ error: void 0,
1539
+ loadStatus: "loading"
1540
+ });
1541
+ } catch (error) {
1542
+ return buildQueryState(void 0, {
1543
+ status: "error",
1544
+ error: toError(error),
1545
+ loadStatus: "idle"
1546
+ });
1547
+ }
1548
+ }
1549
+ //#endregion
1550
+ //#region src/shared/open-service/query-subscribe.ts
1551
+ /**
1552
+ * Runs a query's `load` as the body of a subscription's reactive effect.
1553
+ *
1554
+ * Unlike {@link runLoadBody}, this is invoked synchronously inside an `effect()`, so the external
1555
+ * signals the load reads in its synchronous prefix are tracked — when they later change, the effect
1556
+ * re-runs and the load re-fires, turning it into a reactive async resource. Loads are therefore an
1557
+ * idempotent warming step (the documented guideline, now a hard contract); one-shot side effects
1558
+ * belong in a command.
1559
+ *
1560
+ * Writes go through gated commands: if `isCurrent()` flips to false because a newer run started
1561
+ * (deps changed again), this run's later writes are dropped, so a slow stale load cannot clobber the
1562
+ * newer result. Sibling reads use the default queries — their loads fire-and-forget — so transitive
1563
+ * dependencies stay warm without the `.loaded()` drain, which is only meaningful for awaited pulls.
1564
+ */
1565
+ async function runReactiveLoad(refs, queryName, queryDef, validatedInput, isCurrent) {
1566
+ if (!queryDef.load) return;
1567
+ const loadCtx = {
1568
+ self: {
1569
+ get state() {
1570
+ return refs.state;
1571
+ },
1572
+ queries: refs.reactiveLoadQueries,
1573
+ commands: refs.buildGatedCommands(isCurrent)
1574
+ },
1575
+ getService: refs.registryApi.getService
1576
+ };
1577
+ await Promise.resolve(queryDef.load(validatedInput, loadCtx));
1578
+ }
1579
+ /**
1580
+ * Subscribes to a query by running its handler inside a deep-signal-aware `computed()` and
1581
+ * notifying through an `effect()`. The callback receives a {@link QueryState} combining the current
1582
+ * `data` (the synchronous handler result, or the selected slice) with the per-subscription `load`
1583
+ * lifecycle (`status` / `loadStatus` / `error`).
1584
+ *
1585
+ * The first emission is **synchronous**: `subscribe()` invokes the callback once with the current
1586
+ * {@link QueryState} before it returns the unsubscribe handle. The runtime kicks `load` off in the
1587
+ * background but does not wait for it — subscribers see the current state immediately (a load-backed
1588
+ * query already reads `loading`, since the reactive-load effect runs synchronously here) and
1589
+ * follow-up emissions as the load settles (or re-fires) and tracked state changes.
1590
+ *
1591
+ * Three layers keep emissions precise:
1592
+ *
1593
+ * 1. **Fine-grained reads** — the handler (and the optional `selector`) read through the deep-signal
1594
+ * proxy, so the computed only re-runs when the exact fields it touched change. A write to an
1595
+ * unrelated key or field never re-runs the handler.
1596
+ * 2. **Lifecycle signal** — a separate per-subscription signal carries `status`/`loadStatus`/`error`,
1597
+ * updated by the reactive-load effect. The emit effect reads both it and the data computed, so a
1598
+ * status change (e.g. a background re-load) fires the callback even when the selected slice is
1599
+ * unchanged.
1600
+ * 3. **Object dedup** — the whole emitted `QueryState` is compared with the previously emitted one via
1601
+ * `isEqual`; a re-run that produces a deeply-equal state (e.g. a load rewriting an equal payload
1602
+ * with no status change) does not fire the callback.
1603
+ *
1604
+ * Error sources all surface as `status: 'error'` (keeping the last successful `data`): input
1605
+ * validation failure, a synchronous handler / output-validation throw, and a `load` rejection.
1606
+ */
1607
+ function subscribeToQuery(refs, queryName, queryDef, rawInput, selector, callback) {
1608
+ let active = true;
1609
+ let validatedInput;
1610
+ try {
1611
+ validatedInput = validateQueryInput(refs, queryName, queryDef, rawInput);
1612
+ } catch (error) {
1613
+ callback(buildQueryState(void 0, {
1614
+ status: "error",
1615
+ error: toError(error),
1616
+ loadStatus: "idle"
1617
+ }));
1618
+ return () => {
1619
+ active = false;
1620
+ };
1621
+ }
1622
+ const lifecycle = y({
1623
+ status: queryDef.load ? "pending" : "success",
1624
+ error: void 0,
1625
+ loadStatus: "idle"
1626
+ });
1627
+ let loadTeardown;
1628
+ if (queryDef.load) {
1629
+ let epoch = 0;
1630
+ loadTeardown = j(() => {
1631
+ const myEpoch = ++epoch;
1632
+ const isCurrent = () => myEpoch === epoch;
1633
+ const previous = f(() => lifecycle.value);
1634
+ lifecycle.value = {
1635
+ status: previous.status,
1636
+ error: previous.error,
1637
+ loadStatus: "loading"
1638
+ };
1639
+ runReactiveLoad(refs, queryName, queryDef, validatedInput, isCurrent).then(() => {
1640
+ if (!isCurrent()) return;
1641
+ lifecycle.value = {
1642
+ status: "success",
1643
+ error: void 0,
1644
+ loadStatus: "idle"
1645
+ };
1646
+ }, (error) => {
1647
+ if (!isCurrent()) return;
1648
+ lifecycle.value = {
1649
+ status: "error",
1650
+ error: toError(error),
1651
+ loadStatus: "idle"
1652
+ };
1653
+ });
1654
+ });
1655
+ }
1656
+ const comp = g$1(() => {
1657
+ const output = runHandlerSync(refs, queryName, queryDef, validatedInput, refs.defaultQueries, refs.registryApi.getService);
1658
+ if (selector) {
1659
+ const validated = f(() => validateQueryOutput(refs, queryName, queryDef, output));
1660
+ selector(output);
1661
+ return detachSnapshot(selector(validated));
1662
+ }
1663
+ return detachSnapshot(validateQueryOutput(refs, queryName, queryDef, output));
1664
+ });
1665
+ let hasEmitted = false;
1666
+ let lastEmitted;
1667
+ let lastData;
1668
+ const teardown = j(() => {
1669
+ const life = lifecycle.value;
1670
+ let data;
1671
+ let status = life.status;
1672
+ let error = life.error;
1673
+ try {
1674
+ data = comp.value;
1675
+ lastData = data;
1676
+ } catch (handlerError) {
1677
+ data = lastData;
1678
+ status = "error";
1679
+ error = toError(handlerError);
1680
+ }
1681
+ if (!active) return;
1682
+ const state = buildQueryState(data, {
1683
+ status,
1684
+ error,
1685
+ loadStatus: life.loadStatus
1686
+ });
1687
+ if (hasEmitted && isEqual(state, lastEmitted)) return;
1688
+ hasEmitted = true;
1689
+ lastEmitted = state;
1690
+ callback(state);
1691
+ });
1692
+ return () => {
1693
+ active = false;
1694
+ teardown();
1695
+ loadTeardown?.();
1696
+ };
1669
1697
  }
1670
- /**
1671
- * Builds the shared synchronous `get(input)` for a query: validate input → fire the load per the
1672
- * caller's policy → run the handler against `selfQueries` → validate output.
1673
- *
1674
- * The three query surfaces — the default consumer query ({@link createDefaultQuery}), the reactive
1675
- * subscription-load wrappers ({@link buildReactiveLoadQueries}), and the awaited load-body wrappers
1676
- * ({@link buildLoadWrappedQueries}) — differ only in (a) which `self.queries` map the handler sees
1677
- * and (b) how a load-backed read fires its `load`. Everything else (the validate → run → validate
1678
- * skeleton, the zero-arg input resolution) is identical, so each surface passes its own `selfQueries`
1679
- * map and `fireLoad` policy and shares this body.
1680
- *
1681
- * `fireLoad` is invoked only for queries that declare a `load`; queries without one skip it. Pass
1682
- * `selfQueries` by reference even when it is the same map being populated by the caller — `get`
1683
- * closes over the reference, which is fully built by the time any handler runs.
1684
- */
1685
- function createQueryGet(refs, queryName, queryDef, selfQueries, fireLoad) {
1686
- return function get(input) {
1687
- const validatedInput = validateQueryInput(refs, queryName, queryDef, arguments.length === 0 ? void 0 : input);
1688
- if (queryDef.load) fireLoad?.(validatedInput);
1689
- return validateQueryOutput(refs, queryName, queryDef, runHandlerSync(refs, queryName, queryDef, validatedInput, selfQueries, refs.registryApi.getService));
1690
- };
1698
+ function init_query_subscribe() {
1699
+ return (init_query_subscribe = __esmMin((() => {
1700
+ init_signals_core_module();
1701
+ init_isEqual();
1702
+ init_query_load_registry();
1703
+ init_query_handler();
1704
+ })))();
1691
1705
  }
1706
+ //#endregion
1707
+ //#region src/shared/open-service/query-runtime.ts
1692
1708
  /**
1693
1709
  * Triggers a `load` if one is not already in flight for the same key, or returns the existing
1694
1710
  * promise so concurrent callers share the work.
@@ -1767,34 +1783,6 @@ async function runLoadBody(refs, queryName, queryDef, validatedInput, ancestorCh
1767
1783
  await drainCollector(collector, void 0, refs.serviceId, queryName);
1768
1784
  }
1769
1785
  /**
1770
- * Runs a query's `load` as the body of a subscription's reactive effect.
1771
- *
1772
- * Unlike {@link runLoadBody}, this is invoked synchronously inside an `effect()`, so the external
1773
- * signals the load reads in its synchronous prefix are tracked — when they later change, the effect
1774
- * re-runs and the load re-fires, turning it into a reactive async resource. Loads are therefore an
1775
- * idempotent warming step (the documented guideline, now a hard contract); one-shot side effects
1776
- * belong in a command.
1777
- *
1778
- * Writes go through gated commands: if `isCurrent()` flips to false because a newer run started
1779
- * (deps changed again), this run's later writes are dropped, so a slow stale load cannot clobber the
1780
- * newer result. Sibling reads use the default queries — their loads fire-and-forget — so transitive
1781
- * dependencies stay warm without the `.loaded()` drain, which is only meaningful for awaited pulls.
1782
- */
1783
- async function runReactiveLoad(refs, queryName, queryDef, validatedInput, isCurrent) {
1784
- if (!queryDef.load) return;
1785
- const loadCtx = {
1786
- self: {
1787
- get state() {
1788
- return refs.state;
1789
- },
1790
- queries: refs.reactiveLoadQueries,
1791
- commands: refs.buildGatedCommands(isCurrent)
1792
- },
1793
- getService: refs.registryApi.getService
1794
- };
1795
- await Promise.resolve(queryDef.load(validatedInput, loadCtx));
1796
- }
1797
- /**
1798
1786
  * Builds the `ctx.self.queries` map used inside a *reactive subscription load* body.
1799
1787
  *
1800
1788
  * `.get()` here fires the dependency's `load` fire-and-forget (deduped via {@link inFlightLoads}),
@@ -1946,10 +1934,10 @@ async function runLoaded(refs, queryName, queryDef, rawInput, parentAncestorChai
1946
1934
  let iterations = 0;
1947
1935
  let hasMoreWork = true;
1948
1936
  while (hasMoreWork) {
1949
- if (iterations++ > MAX_DRAIN_ITERATIONS) throw new OpenServiceLoadedDrainExceededError({
1937
+ if (iterations++ > 32) throw new OpenServiceLoadedDrainExceededError({
1950
1938
  serviceId: refs.serviceId,
1951
1939
  name: queryName,
1952
- iterations: MAX_DRAIN_ITERATIONS
1940
+ iterations: 32
1953
1941
  });
1954
1942
  while (session.collector.size > 0) {
1955
1943
  const pending = [...session.collector];
@@ -2019,143 +2007,20 @@ function createDefaultQuery(refs, queryName, queryDef) {
2019
2007
  subscribe
2020
2008
  };
2021
2009
  }
2022
- /**
2023
- * Subscribes to a query by running its handler inside a deep-signal-aware `computed()` and
2024
- * notifying through an `effect()`. The callback receives a {@link QueryState} combining the current
2025
- * `data` (the synchronous handler result, or the selected slice) with the per-subscription `load`
2026
- * lifecycle (`status` / `loadStatus` / `error`).
2027
- *
2028
- * The first emission is **synchronous**: `subscribe()` invokes the callback once with the current
2029
- * {@link QueryState} before it returns the unsubscribe handle. The runtime kicks `load` off in the
2030
- * background but does not wait for it — subscribers see the current state immediately (a load-backed
2031
- * query already reads `loading`, since the reactive-load effect runs synchronously here) and
2032
- * follow-up emissions as the load settles (or re-fires) and tracked state changes.
2033
- *
2034
- * Three layers keep emissions precise:
2035
- *
2036
- * 1. **Fine-grained reads** — the handler (and the optional `selector`) read through the deep-signal
2037
- * proxy, so the computed only re-runs when the exact fields it touched change. A write to an
2038
- * unrelated key or field never re-runs the handler.
2039
- * 2. **Lifecycle signal** — a separate per-subscription signal carries `status`/`loadStatus`/`error`,
2040
- * updated by the reactive-load effect. The emit effect reads both it and the data computed, so a
2041
- * status change (e.g. a background re-load) fires the callback even when the selected slice is
2042
- * unchanged.
2043
- * 3. **Object dedup** — the whole emitted `QueryState` is compared with the previously emitted one via
2044
- * `isEqual`; a re-run that produces a deeply-equal state (e.g. a load rewriting an equal payload
2045
- * with no status change) does not fire the callback.
2046
- *
2047
- * Error sources all surface as `status: 'error'` (keeping the last successful `data`): input
2048
- * validation failure, a synchronous handler / output-validation throw, and a `load` rejection.
2049
- */
2050
- function subscribeToQuery(refs, queryName, queryDef, rawInput, selector, callback) {
2051
- let active = true;
2052
- let validatedInput;
2053
- try {
2054
- validatedInput = validateQueryInput(refs, queryName, queryDef, rawInput);
2055
- } catch (error) {
2056
- callback(buildQueryState(void 0, {
2057
- status: "error",
2058
- error: toError(error),
2059
- loadStatus: "idle"
2060
- }));
2061
- return () => {
2062
- active = false;
2063
- };
2064
- }
2065
- const lifecycle = y({
2066
- status: queryDef.load ? "pending" : "success",
2067
- error: void 0,
2068
- loadStatus: "idle"
2069
- });
2070
- let loadTeardown;
2071
- if (queryDef.load) {
2072
- let epoch = 0;
2073
- loadTeardown = j(() => {
2074
- const myEpoch = ++epoch;
2075
- const isCurrent = () => myEpoch === epoch;
2076
- const previous = f(() => lifecycle.value);
2077
- lifecycle.value = {
2078
- status: previous.status,
2079
- error: previous.error,
2080
- loadStatus: "loading"
2081
- };
2082
- runReactiveLoad(refs, queryName, queryDef, validatedInput, isCurrent).then(() => {
2083
- if (!isCurrent()) return;
2084
- lifecycle.value = {
2085
- status: "success",
2086
- error: void 0,
2087
- loadStatus: "idle"
2088
- };
2089
- }, (error) => {
2090
- if (!isCurrent()) return;
2091
- lifecycle.value = {
2092
- status: "error",
2093
- error: toError(error),
2094
- loadStatus: "idle"
2095
- };
2096
- });
2097
- });
2098
- }
2099
- const comp = g$1(() => {
2100
- const output = runHandlerSync(refs, queryName, queryDef, validatedInput, refs.defaultQueries, refs.registryApi.getService);
2101
- if (selector) {
2102
- const validated = f(() => validateQueryOutput(refs, queryName, queryDef, output));
2103
- selector(output);
2104
- return detachSnapshot(selector(validated));
2105
- }
2106
- return detachSnapshot(validateQueryOutput(refs, queryName, queryDef, output));
2107
- });
2108
- let hasEmitted = false;
2109
- let lastEmitted;
2110
- let lastData;
2111
- const teardown = j(() => {
2112
- const life = lifecycle.value;
2113
- let data;
2114
- let status = life.status;
2115
- let error = life.error;
2116
- try {
2117
- data = comp.value;
2118
- lastData = data;
2119
- } catch (handlerError) {
2120
- data = lastData;
2121
- status = "error";
2122
- error = toError(handlerError);
2123
- }
2124
- if (!active) return;
2125
- const state = buildQueryState(data, {
2126
- status,
2127
- error,
2128
- loadStatus: life.loadStatus
2129
- });
2130
- if (hasEmitted && isEqual(state, lastEmitted)) return;
2131
- hasEmitted = true;
2132
- lastEmitted = state;
2133
- callback(state);
2134
- });
2135
- return () => {
2136
- active = false;
2137
- teardown();
2138
- loadTeardown?.();
2139
- };
2140
- }
2141
2010
  /** Builds the runtime query map for one service runtime. */
2142
2011
  function buildQueries$1(refs) {
2143
2012
  const result = {};
2144
2013
  for (const [name, queryDef] of refs.queryDefinitions) result[name] = createDefaultQuery(refs, name, queryDef);
2145
2014
  return result;
2146
2015
  }
2147
- var MAX_DRAIN_ITERATIONS, inFlightLoads, nextLoadScopeSequence, nextLoadScopeId, activeHandlerLoadSession, EMPTY_SET;
2016
+ var activeHandlerLoadSession;
2148
2017
  function init_query_runtime() {
2149
2018
  return (init_query_runtime = __esmMin((() => {
2150
- init_signals_core_module();
2151
- init_isEqual();
2152
- init_server_errors();
2019
+ init_open_service();
2153
2020
  init_service_validation();
2154
- MAX_DRAIN_ITERATIONS = 32;
2155
- inFlightLoads = /* @__PURE__ */ new Map();
2156
- nextLoadScopeSequence = 0;
2157
- nextLoadScopeId = () => String(nextLoadScopeSequence += 1);
2158
- EMPTY_SET = /* @__PURE__ */ new Set();
2021
+ init_query_load_registry();
2022
+ init_query_handler();
2023
+ init_query_subscribe();
2159
2024
  })))();
2160
2025
  }
2161
2026
  //#endregion
@@ -2758,7 +2623,7 @@ function init_service_runtime() {
2758
2623
  return (init_service_runtime = __esmMin((() => {
2759
2624
  init_signals_core_module();
2760
2625
  init_deepsignal_core_module();
2761
- init_server_errors();
2626
+ init_open_service();
2762
2627
  init_patch_recorder();
2763
2628
  init_plain_object();
2764
2629
  init_query_runtime();
@@ -3239,7 +3104,7 @@ function init_service_transport() {
3239
3104
  return (init_service_transport = __esmMin((() => {
3240
3105
  init_dist();
3241
3106
  init_client_logger();
3242
- init_server_errors();
3107
+ init_open_service();
3243
3108
  init_service_channel();
3244
3109
  init_service_error_serialization();
3245
3110
  init_service_sync();
@@ -3443,7 +3308,7 @@ var REGISTRY_SYMBOL, serviceRegistryApi;
3443
3308
  function init_service_registry() {
3444
3309
  return (init_service_registry = __esmMin((() => {
3445
3310
  init_channel_slot();
3446
- init_server_errors();
3311
+ init_open_service();
3447
3312
  init_service_channel();
3448
3313
  init_service_runtime();
3449
3314
  init_service_sync();
@@ -3541,16 +3406,17 @@ function createExpect() {
3541
3406
  Object.assign(expect, expect$2);
3542
3407
  expect.getState = () => getState(expect);
3543
3408
  expect.setState = (state) => setState(state, expect);
3544
- expect.extend = (expects) => expect$2.extend(expect, expects);
3545
- expect.soft = (...args) => {
3546
- const assert = expect(...args);
3409
+ const chaiExpect = expect$2;
3410
+ expect.extend = (expects) => chaiExpect.extend(expect, expects);
3411
+ Object.assign(expect, { soft: (value, message) => {
3412
+ const assert = expect(value, message);
3547
3413
  expect.setState({ soft: true });
3548
3414
  return assert;
3549
- };
3415
+ } });
3550
3416
  expect.extend(customMatchers);
3551
- expect.unreachable = (message) => {
3417
+ Object.assign(expect, { unreachable: (message) => {
3552
3418
  assert.fail(`expected${message ? ` "${message}" ` : " "}not to be reached`);
3553
- };
3419
+ } });
3554
3420
  function assertions(expected) {
3555
3421
  const errorGen = () => /* @__PURE__ */ new Error(`expected number of assertions to be ${expected}, but got ${expect.getState().assertionCalls}`);
3556
3422
  if ("captureStackTrace" in Error && typeof Error.captureStackTrace === "function") Error.captureStackTrace(errorGen(), assertions);
@@ -3583,7 +3449,7 @@ var expect$1;
3583
3449
  function init_expect() {
3584
3450
  return (init_expect = __esmMin((() => {
3585
3451
  init_matchers();
3586
- init_dist$5();
3452
+ init_dist$4();
3587
3453
  init_chai();
3588
3454
  expect$1 = createExpect();
3589
3455
  // @vitest/expect expects this to be set
@@ -3653,9 +3519,9 @@ function mocked(item, _options = {}) {
3653
3519
  var moduleMockSpies, listeners, spyOn;
3654
3520
  function init_spy() {
3655
3521
  return (init_spy = __esmMin((() => {
3656
- init_dist$6();
3522
+ init_dist$5();
3657
3523
  init_dist$1();
3658
- moduleMockSpies = globalThis.__STORYBOOK_MODULE_MOCK_SPIES__ ??= /* @__PURE__ */ new Set();
3524
+ moduleMockSpies = globalThis.__FORKBOOK_MODULE_MOCK_SPIES__ ??= /* @__PURE__ */ new Set();
3659
3525
  listeners = /* @__PURE__ */ new Set();
3660
3526
  spyOn = ((...args) => {
3661
3527
  return reactiveMock(spyOn$1(...args));
@@ -3680,7 +3546,7 @@ function init_testing_library() {
3680
3546
  if (typeof window !== "undefined" && globalThis.location?.href?.includes("viewMode=docs")) once.warn(dedent`
3681
3547
  You are using Testing Library's \`screen\` object while the story is rendered in docs mode. This will likely lead to issues, as multiple stories are rendered in the same page and therefore screen will potentially find multiple elements. Use the \`canvas\` utility from the story context instead, which will scope the queries to each story's canvas.
3682
3548
 
3683
- More info: https://storybook.js.org/docs/writing-tests/interaction-testing?ref=error#querying-the-canvas
3549
+ More info: https://forkbook.ljk.dev/docs/writing-tests/interaction-testing#querying-the-canvas
3684
3550
  `);
3685
3551
  return Reflect.get(target, prop, receiver);
3686
3552
  } });
@@ -3820,52 +3686,53 @@ function init_base() {
3820
3686
  return (init_base = __esmMin((() => {
3821
3687
  easing = { rubber: "cubic-bezier(0.175, 0.885, 0.335, 1.05)" };
3822
3688
  color = {
3823
- primary: "#FF4785",
3824
- secondary: "#006DEB",
3825
- tertiary: "#FAFBFC",
3826
- ancillary: "#22a699",
3827
- orange: "#FC521F",
3828
- gold: "#FFAE00",
3829
- green: "#66BF3C",
3830
- seafoam: "#37D5D3",
3831
- purple: "#6F2CAC",
3832
- ultraviolet: "#2A0481",
3689
+ primary: "#007AFF",
3690
+ secondary: "#007AFF",
3691
+ tertiary: "#F2F2F7",
3692
+ ancillary: "#30B0C7",
3693
+ orange: "#FF9500",
3694
+ gold: "#FFCC00",
3695
+ green: "#34C759",
3696
+ seafoam: "#32ADE6",
3697
+ purple: "#AF52DE",
3698
+ ultraviolet: "#5856D6",
3833
3699
  lightest: "#FFFFFF",
3834
- lighter: "#F6F9FC",
3835
- light: "#EEF2F6",
3836
- mediumlight: "#ECF2F9",
3837
- medium: "#D9E5F2",
3838
- mediumdark: "#737F8C",
3839
- dark: "#5C6570",
3840
- darker: "#454C54",
3841
- darkest: "#2E3338",
3842
- border: "hsl(212 50% 30% / 0.15)",
3843
- positive: "#66BF3C",
3844
- warning: "#E69D00",
3845
- negative: "#FF4400",
3700
+ lighter: "#F2F2F7",
3701
+ light: "#E5E5EA",
3702
+ mediumlight: "#E5E5EA",
3703
+ medium: "#D1D1D6",
3704
+ mediumdark: "#8E8E93",
3705
+ dark: "#636366",
3706
+ darker: "#48484A",
3707
+ darkest: "#1C1C1E",
3708
+ border: "rgba(60, 60, 67, 0.18)",
3709
+ positive: "#34C759",
3710
+ warning: "#FF9500",
3711
+ negative: "#FF3B30",
3846
3712
  critical: "#FFFFFF",
3847
- defaultText: "#2E3338",
3713
+ defaultText: "#1C1C1E",
3848
3714
  inverseText: "#FFFFFF",
3849
- positiveText: "#427C27",
3850
- warningText: "#955B1E",
3851
- negativeText: "#C23400"
3715
+ positiveText: "#248A3D",
3716
+ warningText: "#C93400",
3717
+ negativeText: "#D70015"
3852
3718
  };
3853
3719
  background = {
3854
- app: "#F6F9FC",
3720
+ app: "#F2F2F7",
3855
3721
  bar: color.lightest,
3856
3722
  content: color.lightest,
3857
3723
  preview: color.lightest,
3858
3724
  gridCellSize: 10,
3859
- hoverable: "#DBECFF",
3860
- positive: "#F1FFEB",
3861
- warning: "#FFF9EB",
3862
- negative: "#FFF0EB",
3863
- critical: "#D13800"
3725
+ hoverable: "#E5E5EA",
3726
+ positive: "#EAF9EE",
3727
+ warning: "#FFF4E5",
3728
+ negative: "#FFEBEA",
3729
+ critical: "#D70015"
3864
3730
  };
3865
3731
  typography = {
3866
3732
  fonts: {
3867
3733
  base: [
3868
- "\"Nunito Sans\"",
3734
+ "\"Inter Variable\"",
3735
+ "Inter",
3869
3736
  "-apple-system",
3870
3737
  "\".SFNSText-Regular\"",
3871
3738
  "\"San Francisco\"",
@@ -3913,62 +3780,62 @@ function init_base() {
3913
3780
  muted: color.dark,
3914
3781
  accent: color.secondary,
3915
3782
  inverse: color.lightest,
3916
- positive: "#427C27",
3917
- warning: "#7A4100",
3918
- negative: "#C23400",
3783
+ positive: "#248A3D",
3784
+ warning: "#C93400",
3785
+ negative: "#D70015",
3919
3786
  critical: "#FFFFFF",
3920
- agentic: "#723aa6"
3787
+ agentic: "#8944AB"
3921
3788
  },
3922
3789
  bgColor: {
3923
3790
  default: color.lightest,
3924
3791
  muted: background.app,
3925
- positive: "#F1FFEB",
3926
- warning: "#FFF7EB",
3927
- negative: "#FFF0EB",
3928
- critical: "#D13800",
3929
- agentic: "#f5f0fa"
3792
+ positive: "#EAF9EE",
3793
+ warning: "#FFF4E5",
3794
+ negative: "#FFEBEA",
3795
+ critical: "#D70015",
3796
+ agentic: "#F7EEFC"
3930
3797
  },
3931
3798
  borderColor: {
3932
3799
  default: color.border,
3933
- muted: "hsl(0 0% 0% / 0.1)",
3934
- inverse: "hsl(0 0% 100% / 0.1)",
3935
- positive: "#BFE7AC",
3936
- warning: "#FFCE85",
3937
- negative: "#FFC3AD",
3938
- critical: "hsl(16 100% 100% / 0)",
3939
- agentic: "#e1d2ef"
3800
+ muted: "rgba(0, 0, 0, 0.1)",
3801
+ inverse: "rgba(255, 255, 255, 0.1)",
3802
+ positive: "#B4E9C1",
3803
+ warning: "#FFD9A3",
3804
+ negative: "#FFC2BE",
3805
+ critical: "rgba(255, 255, 255, 0)",
3806
+ agentic: "#E5CCF4"
3940
3807
  }
3941
3808
  },
3942
3809
  dark: {
3943
3810
  fgColor: {
3944
- default: "#C9CCCF",
3945
- muted: "#95999D",
3946
- accent: "#479DFF",
3947
- inverse: "#1B1C1D",
3948
- positive: "#86CE64",
3949
- warning: "#FFAD33",
3950
- negative: "#FF6933",
3951
- critical: "#FF6933",
3952
- agentic: "#b07fdc"
3811
+ default: "#F2F2F7",
3812
+ muted: "#98989F",
3813
+ accent: "#0A84FF",
3814
+ inverse: "#1C1C1E",
3815
+ positive: "#30D158",
3816
+ warning: "#FF9F0A",
3817
+ negative: "#FF453A",
3818
+ critical: "#FF453A",
3819
+ agentic: "#BF5AF2"
3953
3820
  },
3954
3821
  bgColor: {
3955
- default: "#222325",
3956
- muted: "#1B1C1D",
3957
- positive: "hsl(101 100% 100% / 0)",
3958
- warning: "hsl(101 100% 100% / 0)",
3959
- negative: "hsl(101 100% 100% / 0)",
3960
- critical: "hsl(101 100% 100% / 0)",
3961
- agentic: "rgba(114,58,166,0.15)"
3822
+ default: "#1C1C1E",
3823
+ muted: "#000000",
3824
+ positive: "rgba(48, 209, 88, 0)",
3825
+ warning: "rgba(255, 159, 10, 0)",
3826
+ negative: "rgba(255, 69, 58, 0)",
3827
+ critical: "rgba(255, 69, 58, 0)",
3828
+ agentic: "rgba(191, 90, 242, 0.15)"
3962
3829
  },
3963
3830
  borderColor: {
3964
- default: "hsl(0 0% 100% / 0.1)",
3965
- muted: "hsl(0 0% 100% / 0.5)",
3966
- inverse: "hsl(0 0% 0% / 0.1)",
3967
- positive: "hsl(101 52% 64% / 0.15)",
3968
- warning: "hsl(36 100% 64% / 0.15)",
3969
- negative: "hsl(16 100% 64% / 0.15)",
3970
- critical: "#FF6933",
3971
- agentic: "rgba(114,58,166,0.35)"
3831
+ default: "rgba(84, 84, 88, 0.6)",
3832
+ muted: "rgba(255, 255, 255, 0.5)",
3833
+ inverse: "rgba(0, 0, 0, 0.1)",
3834
+ positive: "rgba(48, 209, 88, 0.2)",
3835
+ warning: "rgba(255, 159, 10, 0.2)",
3836
+ negative: "rgba(255, 69, 58, 0.2)",
3837
+ critical: "#FF453A",
3838
+ agentic: "rgba(191, 90, 242, 0.35)"
3972
3839
  }
3973
3840
  }
3974
3841
  };
@@ -3976,36 +3843,37 @@ function init_base() {
3976
3843
  }
3977
3844
  //#endregion
3978
3845
  //#region src/theming/themes/dark.ts
3979
- var theme$1;
3846
+ var border, theme$1;
3980
3847
  function init_dark() {
3981
3848
  return (init_dark = __esmMin((() => {
3982
3849
  init_base();
3850
+ border = "rgba(84, 84, 88, 0.6)";
3983
3851
  theme$1 = {
3984
3852
  base: "dark",
3985
- colorPrimary: "#FF4785",
3986
- colorSecondary: "#479DFF",
3987
- appBg: "#1B1C1D",
3988
- appContentBg: "#222325",
3989
- appHoverBg: "#233952",
3853
+ colorPrimary: "#0A84FF",
3854
+ colorSecondary: "#0A84FF",
3855
+ appBg: "#000000",
3856
+ appContentBg: "#1C1C1E",
3857
+ appHoverBg: "#2C2C2E",
3990
3858
  appPreviewBg: color.lightest,
3991
- appBorderColor: "hsl(0 0% 100% / 0.1)",
3859
+ appBorderColor: border,
3992
3860
  appBorderRadius: 4,
3993
3861
  fontBase: typography.fonts.base,
3994
3862
  fontCode: typography.fonts.mono,
3995
- textColor: "#C9CCCF",
3996
- textInverseColor: "#1B1C1D",
3997
- textMutedColor: "#95999D",
3998
- barTextColor: "#95999D",
3999
- barHoverColor: "#70B3FF",
4000
- barSelectedColor: "#479DFF",
4001
- barBg: "#222325",
4002
- buttonBg: "#1B1C1D",
4003
- buttonBorder: "hsl(0 0% 100% / 0.1)",
4004
- booleanBg: "#1B1C1D",
4005
- booleanSelectedBg: "#292B2E",
4006
- inputBg: "#1B1C1D",
4007
- inputBorder: "hsl(0 0% 100% / 0.1)",
4008
- inputTextColor: "#C9CCCF",
3863
+ textColor: "#F2F2F7",
3864
+ textInverseColor: "#1C1C1E",
3865
+ textMutedColor: "#98989F",
3866
+ barTextColor: "#98989F",
3867
+ barHoverColor: "#F2F2F7",
3868
+ barSelectedColor: "#0A84FF",
3869
+ barBg: "#1C1C1E",
3870
+ buttonBg: "#2C2C2E",
3871
+ buttonBorder: border,
3872
+ booleanBg: "#2C2C2E",
3873
+ booleanSelectedBg: "#3A3A3C",
3874
+ inputBg: "#2C2C2E",
3875
+ inputBorder: border,
3876
+ inputTextColor: "#F2F2F7",
4009
3877
  inputBorderRadius: 4
4010
3878
  };
4011
3879
  })))();
@@ -4022,7 +3890,7 @@ function init_light() {
4022
3890
  colorSecondary: color.secondary,
4023
3891
  appBg: background.app,
4024
3892
  appContentBg: color.lightest,
4025
- appHoverBg: "#DBECFF",
3893
+ appHoverBg: background.hoverable,
4026
3894
  appPreviewBg: color.lightest,
4027
3895
  appBorderColor: color.border,
4028
3896
  appBorderRadius: 4,
@@ -4032,8 +3900,8 @@ function init_light() {
4032
3900
  textInverseColor: color.lightest,
4033
3901
  textMutedColor: color.dark,
4034
3902
  barTextColor: color.dark,
4035
- barHoverColor: "#005CC7",
4036
- barSelectedColor: "#0063D6",
3903
+ barHoverColor: color.darkest,
3904
+ barSelectedColor: color.secondary,
4037
3905
  barBg: color.lightest,
4038
3906
  buttonBg: background.app,
4039
3907
  buttonBorder: color.medium,
@@ -4052,9 +3920,9 @@ var globalWindow, isColorString, isValidColorForPolished, applyPolished, colorFa
4052
3920
  function init_utils() {
4053
3921
  return (init_utils = __esmMin((() => {
4054
3922
  init_client_logger();
4055
- init_dist$2();
3923
+ init_global();
4056
3924
  init_polished_esm();
4057
- ({window: globalWindow} = scope);
3925
+ ({window: globalWindow} = global);
4058
3926
  isColorString = (color) => {
4059
3927
  if (typeof color !== "string") {
4060
3928
  logger.warn(`Color passed to theme object should be a string. Instead ${color}(${typeof color}) was passed.`);
@@ -4180,7 +4048,7 @@ function init_utils$1() {
4180
4048
  ...value,
4181
4049
  ...update
4182
4050
  }).reduce((acc, key) => {
4183
- const diff = deepDiff(value?.[key], update?.[key]);
4051
+ const diff = deepDiff(value[key], update[key]);
4184
4052
  return diff === DEEPLY_EQUAL ? acc : Object.assign(acc, { [key]: diff });
4185
4053
  }, {});
4186
4054
  return update;
@@ -4233,7 +4101,7 @@ function init_utils$1() {
4233
4101
  once.warn(dedent`
4234
4102
  Omitted potentially unsafe URL args.
4235
4103
 
4236
- More info: https://storybook.js.org/docs/writing-stories/args?ref=error#setting-args-through-the-url
4104
+ More info: https://forkbook.ljk.dev/docs/writing-stories/args#setting-args-through-the-url
4237
4105
  `);
4238
4106
  return acc;
4239
4107
  }, {});
@@ -4265,9 +4133,112 @@ function init_utils$1() {
4265
4133
  })))();
4266
4134
  }
4267
4135
  //#endregion
4136
+ //#region src/router/story-paths.ts
4137
+ var APP_ROUTE_SEGMENTS, HOME_PATH, ALL_STORIES_PATH, isRootPageEnabled, RESERVED_URL_PATHS, firstSegment, isReservedUrlPath, trimTrailingSlash, entryUrlPath, buildStoryPathMap, STATE_KEY, state, setStoryPathEntries, subscribeStoryPathEntries, getStoryPathEntriesVersion, storyRouteRegex, toUrlPath, fromUrlPath, buildManagerHref, urlPathDepth;
4138
+ function init_story_paths() {
4139
+ return (init_story_paths = __esmMin((() => {
4140
+ init_csf_utils();
4141
+ APP_ROUTE_SEGMENTS = /* @__PURE__ */ new Set(["settings", "review"]);
4142
+ HOME_PATH = "/home/";
4143
+ ALL_STORIES_PATH = "/all/";
4144
+ isRootPageEnabled = () => globalThis.FORKBOOK_ROOT?.enabled === true;
4145
+ RESERVED_URL_PATHS = ["/", "/all"];
4146
+ firstSegment = (path) => path.split("/").filter(Boolean)[0] ?? "";
4147
+ isReservedUrlPath = (urlPath) => {
4148
+ const path = trimTrailingSlash(urlPath.toLowerCase());
4149
+ if (RESERVED_URL_PATHS.includes(path)) return true;
4150
+ const first = firstSegment(path);
4151
+ return APP_ROUTE_SEGMENTS.has(first) || first.startsWith("_");
4152
+ };
4153
+ trimTrailingSlash = (path) => path.length > 1 ? path.replace(/\/+$/, "") : path;
4154
+ entryUrlPath = (entry) => {
4155
+ const segments = [...entry.title.split("/"), entry.name].map(sanitize).filter(Boolean);
4156
+ if (segments.length < 2) return;
4157
+ const path = `/${segments.join("/")}`;
4158
+ return isReservedUrlPath(path) ? void 0 : path;
4159
+ };
4160
+ buildStoryPathMap = (entries) => {
4161
+ const map = {
4162
+ byId: /* @__PURE__ */ new Map(),
4163
+ byUrl: /* @__PURE__ */ new Map(),
4164
+ entries: /* @__PURE__ */ new Map()
4165
+ };
4166
+ for (const entry of entries) {
4167
+ if (entry.type !== "story" && entry.type !== "docs") continue;
4168
+ map.entries.set(entry.id, entry.type === "docs" ? "docs" : "story");
4169
+ const urlPath = entryUrlPath(entry);
4170
+ if (!urlPath || map.byUrl.has(urlPath)) continue;
4171
+ map.byId.set(entry.id, urlPath);
4172
+ map.byUrl.set(urlPath, {
4173
+ id: entry.id,
4174
+ viewMode: entry.type === "docs" ? "docs" : "story"
4175
+ });
4176
+ }
4177
+ return map;
4178
+ };
4179
+ STATE_KEY = "__FORKBOOK_STORY_PATHS__";
4180
+ state = globalThis[STATE_KEY] ??= {
4181
+ map: buildStoryPathMap([]),
4182
+ version: 0,
4183
+ listeners: /* @__PURE__ */ new Set()
4184
+ };
4185
+ setStoryPathEntries = (entries) => {
4186
+ state.map = buildStoryPathMap(entries);
4187
+ state.version += 1;
4188
+ state.listeners.forEach((listener) => listener());
4189
+ };
4190
+ subscribeStoryPathEntries = (listener) => {
4191
+ state.listeners.add(listener);
4192
+ return () => {
4193
+ state.listeners.delete(listener);
4194
+ };
4195
+ };
4196
+ getStoryPathEntriesVersion = () => state.version;
4197
+ storyRouteRegex = /^\/(story|docs)\/(.+)$/;
4198
+ toUrlPath = (internalPath, map = state.map) => {
4199
+ if (!internalPath || internalPath === "/" || internalPath === "/home/") return "/";
4200
+ if (internalPath === "/all/") return "/all";
4201
+ const match = internalPath.match(storyRouteRegex);
4202
+ if (!match) return internalPath;
4203
+ const [, viewMode, id] = match;
4204
+ const urlPath = map.byId.get(id);
4205
+ if (urlPath && map.byUrl.get(urlPath)?.viewMode === viewMode) return urlPath;
4206
+ return `/_${viewMode}/${id}`;
4207
+ };
4208
+ fromUrlPath = (urlPath, map = state.map) => {
4209
+ let path = urlPath || "/";
4210
+ try {
4211
+ path = decodeURI(path);
4212
+ } catch {}
4213
+ path = path.toLowerCase();
4214
+ if (path === "/index.html") path = "/";
4215
+ const first = firstSegment(path);
4216
+ if (APP_ROUTE_SEGMENTS.has(first)) return path;
4217
+ const trimmed = trimTrailingSlash(path);
4218
+ if (trimmed === "/all") return ALL_STORIES_PATH;
4219
+ if (trimmed === "/") return isRootPageEnabled() ? HOME_PATH : "/";
4220
+ const escaped = trimmed.match(/^\/_(story|docs)\/(.+)$/);
4221
+ if (escaped) return `/${escaped[1]}/${escaped[2]}`;
4222
+ const known = map.byUrl.get(trimmed);
4223
+ if (known) return `/${known.viewMode}/${known.id}`;
4224
+ const segments = trimmed.split("/").filter(Boolean);
4225
+ if (segments.length < 2) return "/";
4226
+ const name = segments[segments.length - 1];
4227
+ const guessedId = `${segments.slice(0, -1).join("-")}--${name}`;
4228
+ const indexed = map.entries.get(guessedId);
4229
+ if (indexed) return `/${indexed}/${guessedId}`;
4230
+ return `/${name === "docs" ? "docs" : "story"}/${guessedId}`;
4231
+ };
4232
+ buildManagerHref = (base, internalPath, query = "") => {
4233
+ return `${base.endsWith("/") ? base : `${base}/`}${toUrlPath(internalPath).slice(1)}${query ? `?${query}` : ""}`;
4234
+ };
4235
+ urlPathDepth = (urlPath) => urlPath.split("/").filter(Boolean).length;
4236
+ })))();
4237
+ }
4238
+ //#endregion
4268
4239
  //#region src/router/router.tsx
4269
4240
  function Match({ children, path: targetPath, startsWith = false }) {
4270
- return /* @__PURE__ */ import_react$4.default.createElement(Location, null, ({ path: urlPath, ...rest }) => children({
4241
+ return /* @__PURE__ */ import_react$5.default.createElement(Location, null, ({ path: urlPath, ...rest }) => children({
4271
4242
  match: getMatch(urlPath, targetPath, startsWith),
4272
4243
  ...rest
4273
4244
  }));
@@ -4276,27 +4247,42 @@ function Route(input) {
4276
4247
  const { children, ...rest } = input;
4277
4248
  if (rest.startsWith === void 0) rest.startsWith = false;
4278
4249
  const matchProps = rest;
4279
- return /* @__PURE__ */ import_react$4.default.createElement(Match, matchProps, ({ match }) => match ? children : null);
4250
+ return /* @__PURE__ */ import_react$5.default.createElement(Match, matchProps, ({ match }) => match ? children : null);
4280
4251
  }
4281
- var import_react$4, document$1, getBase, useNavigate, Link, Location, LocationProvider, BaseLocationProvider, MemoryRouter;
4252
+ var import_react$5, document$1, getBasename, toRouterUrl, useNavigate, Link, Location, LocationProvider, BaseLocationProvider, MemoryRouter;
4282
4253
  function init_router() {
4283
4254
  return (init_router = __esmMin((() => {
4284
- import_react$4 = /* @__PURE__ */ __toESM(require_react(), 1);
4285
- init_dist$2();
4286
- init_dist$4();
4255
+ import_react$5 = /* @__PURE__ */ __toESM(require_react(), 1);
4256
+ init_global();
4257
+ init_dist$3();
4287
4258
  init_core_events();
4288
4259
  init_manager_api();
4260
+ init_story_paths();
4289
4261
  init_utils$1();
4290
- ({document: document$1} = scope);
4291
- getBase = () => `${document$1.location.pathname}?`;
4262
+ ({document: document$1} = global);
4263
+ getBasename = () => {
4264
+ try {
4265
+ return new URL(".", document$1.baseURI).pathname.replace(/\/+$/, "");
4266
+ } catch {
4267
+ return "";
4268
+ }
4269
+ };
4270
+ toRouterUrl = (target) => {
4271
+ const [beforeHash, afterHash] = target.split(/#(.*)/s);
4272
+ const [path, ...queryParts] = beforeHash.split("&");
4273
+ const [hash, ...hashQueryParts] = afterHash === void 0 ? [] : afterHash.split("&");
4274
+ const query = [...queryParts, ...hashQueryParts].join("&");
4275
+ return `${toUrlPath(path || "/")}${query ? `?${query}` : ""}${hash ? `#${hash}` : ""}`;
4276
+ };
4292
4277
  useNavigate = () => {
4293
4278
  const navigate = useNavigate$1();
4294
- return (0, import_react$4.useCallback)((to, { plain, ...options } = {}) => {
4279
+ return (0, import_react$5.useCallback)((to, { plain, ...options } = {}) => {
4295
4280
  if (typeof to === "string" && to.startsWith("#")) return navigate(`${document$1.location.search}${to === "#" ? "" : to}`, options);
4296
4281
  if (typeof to === "string") {
4297
- const target = plain ? to : `?path=${to}`;
4298
- const [search, hash] = target.split("#");
4299
- if (search === document$1.location.search && hash) {
4282
+ const target = plain ? to : toRouterUrl(to);
4283
+ const [url, hash] = target.split("#");
4284
+ const current = `${document$1.location.pathname}${document$1.location.search}`;
4285
+ if ((plain ? url === document$1.location.search : `${getBasename()}${url}` === current) && hash) {
4300
4286
  addons.getChannel().emit(NAVIGATE_URL, `#${hash}`);
4301
4287
  return;
4302
4288
  }
@@ -4305,16 +4291,22 @@ function init_router() {
4305
4291
  if (typeof to === "number") return navigate(to);
4306
4292
  }, []);
4307
4293
  };
4308
- Link = ({ to, children, ...rest }) => /* @__PURE__ */ import_react$4.default.createElement(Link$1, {
4309
- to: `${getBase()}path=${to}`,
4294
+ Link = ({ to, children, ...rest }) => /* @__PURE__ */ import_react$5.default.createElement(Link$1, {
4295
+ to: toRouterUrl(to),
4310
4296
  ...rest
4311
4297
  }, children);
4312
4298
  Link.displayName = "QueryLink";
4313
4299
  Location = ({ children }) => {
4314
4300
  const location = useLocation();
4315
- const { path = "", singleStory } = queryFromLocation(location);
4301
+ const navigate = useNavigate$1();
4302
+ (0, import_react$5.useSyncExternalStore)(subscribeStoryPathEntries, getStoryPathEntriesVersion, getStoryPathEntriesVersion);
4303
+ const { path: legacyPath, singleStory, ...otherQuery } = queryFromLocation(location);
4304
+ const path = legacyPath || fromUrlPath(location.pathname);
4316
4305
  const { viewMode, storyId, refId } = parsePath(path);
4317
- return /* @__PURE__ */ import_react$4.default.createElement(import_react$4.default.Fragment, null, children({
4306
+ (0, import_react$5.useEffect)(() => {
4307
+ if (legacyPath) navigate(`${toUrlPath(legacyPath)}${stringifyQuery(otherQuery)}${location.hash}`, { replace: true });
4308
+ }, [legacyPath]);
4309
+ return /* @__PURE__ */ import_react$5.default.createElement(import_react$5.default.Fragment, null, children({
4318
4310
  path: path || "/",
4319
4311
  location,
4320
4312
  viewMode,
@@ -4326,7 +4318,10 @@ function init_router() {
4326
4318
  Location.displayName = "QueryLocation";
4327
4319
  Match.displayName = "QueryMatch";
4328
4320
  Route.displayName = "Route";
4329
- LocationProvider = (...args) => BrowserRouter(...args);
4321
+ LocationProvider = (props) => BrowserRouter({
4322
+ basename: getBasename() || void 0,
4323
+ ...props
4324
+ });
4330
4325
  BaseLocationProvider = (...args) => Router(...args);
4331
4326
  MemoryRouter = (...args) => MemoryRouter$1(...args);
4332
4327
  })))();
@@ -4334,38 +4329,54 @@ function init_router() {
4334
4329
  //#endregion
4335
4330
  //#region src/router/index.ts
4336
4331
  var router_exports = /* @__PURE__ */ __exportAll({
4332
+ ALL_STORIES_PATH: () => ALL_STORIES_PATH,
4337
4333
  BaseLocationProvider: () => BaseLocationProvider,
4338
4334
  DEEPLY_EQUAL: () => DEEPLY_EQUAL,
4335
+ HOME_PATH: () => HOME_PATH,
4339
4336
  Link: () => Link,
4340
4337
  Location: () => Location,
4341
4338
  LocationProvider: () => LocationProvider,
4342
4339
  Match: () => Match,
4343
4340
  MemoryRouter: () => MemoryRouter,
4341
+ RESERVED_URL_PATHS: () => RESERVED_URL_PATHS,
4344
4342
  Route: () => Route,
4345
4343
  buildArgsParam: () => buildArgsParam,
4344
+ buildManagerHref: () => buildManagerHref,
4345
+ buildStoryPathMap: () => buildStoryPathMap,
4346
4346
  deepDiff: () => deepDiff,
4347
+ entryUrlPath: () => entryUrlPath,
4348
+ fromUrlPath: () => fromUrlPath,
4349
+ getBasename: () => getBasename,
4347
4350
  getMatch: () => getMatch,
4351
+ getStoryPathEntriesVersion: () => getStoryPathEntriesVersion,
4352
+ isReservedUrlPath: () => isReservedUrlPath,
4348
4353
  parsePath: () => parsePath,
4349
4354
  queryFromLocation: () => queryFromLocation,
4355
+ setStoryPathEntries: () => setStoryPathEntries,
4350
4356
  stringifyQuery: () => stringifyQuery,
4357
+ subscribeStoryPathEntries: () => subscribeStoryPathEntries,
4358
+ toRouterUrl: () => toRouterUrl,
4359
+ toUrlPath: () => toUrlPath,
4360
+ urlPathDepth: () => urlPathDepth,
4351
4361
  useNavigate: () => useNavigate
4352
4362
  });
4353
4363
  function init_router$1() {
4354
4364
  return (init_router$1 = __esmMin((() => {
4355
4365
  init_utils$1();
4356
4366
  init_router();
4367
+ init_story_paths();
4357
4368
  })))();
4358
4369
  }
4359
4370
  //#endregion
4360
4371
  //#region src/shared/universal-store/use-universal-store-manager.ts
4361
- var import_react$3, useUniversalStore;
4372
+ var import_react$4, useUniversalStore;
4362
4373
  function init_use_universal_store_manager() {
4363
4374
  return (init_use_universal_store_manager = __esmMin((() => {
4364
- import_react$3 = /* @__PURE__ */ __toESM(require_react(), 1);
4375
+ import_react$4 = /* @__PURE__ */ __toESM(require_react(), 1);
4365
4376
  init_isEqual();
4366
4377
  useUniversalStore = (universalStore, selector) => {
4367
- const snapshotRef = import_react$3.useRef(selector ? selector(universalStore.getState()) : universalStore.getState());
4368
- const subscribe = import_react$3.useCallback((listener) => universalStore.onStateChange((state, previousState) => {
4378
+ const snapshotRef = import_react$4.useRef(selector ? selector(universalStore.getState()) : universalStore.getState());
4379
+ const subscribe = import_react$4.useCallback((listener) => universalStore.onStateChange((state, previousState) => {
4369
4380
  if (!selector) {
4370
4381
  snapshotRef.current = state;
4371
4382
  listener();
@@ -4378,14 +4389,14 @@ function init_use_universal_store_manager() {
4378
4389
  listener();
4379
4390
  }
4380
4391
  }), [universalStore, selector]);
4381
- const getSnapshot = import_react$3.useCallback(() => {
4392
+ const getSnapshot = import_react$4.useCallback(() => {
4382
4393
  const currentState = universalStore.getState();
4383
4394
  const selectedState = selector ? selector(currentState) : currentState;
4384
4395
  if (isEqual(selectedState, snapshotRef.current)) return snapshotRef.current;
4385
4396
  snapshotRef.current = selectedState;
4386
4397
  return snapshotRef.current;
4387
4398
  }, [universalStore, selector]);
4388
- return [import_react$3.useSyncExternalStore(subscribe, getSnapshot), universalStore.setState];
4399
+ return [import_react$4.useSyncExternalStore(subscribe, getSnapshot), universalStore.setState];
4389
4400
  };
4390
4401
  })))();
4391
4402
  }
@@ -4528,19 +4539,19 @@ function init_test_provider_store() {
4528
4539
  * ```
4529
4540
  */
4530
4541
  function useServiceCommand(service, commandName) {
4531
- return import_react$2.useMemo(() => service.commands[commandName], [service, commandName]);
4542
+ return import_react$3.useMemo(() => service.commands[commandName], [service, commandName]);
4532
4543
  }
4533
- var import_react$2;
4544
+ var import_react$3;
4534
4545
  function init_use_service_command() {
4535
4546
  return (init_use_service_command = __esmMin((() => {
4536
- import_react$2 = /* @__PURE__ */ __toESM(require_react(), 1);
4547
+ import_react$3 = /* @__PURE__ */ __toESM(require_react(), 1);
4537
4548
  })))();
4538
4549
  }
4539
4550
  //#endregion
4540
4551
  //#region src/shared/open-service/use-service-query.ts
4541
4552
  function useServiceQuery(query, input, selector) {
4542
- const subscriptionKeyRef = import_react$1.useRef(null);
4543
- const snapshotRef = import_react$1.useRef(void 0);
4553
+ const subscriptionKeyRef = import_react$2.useRef(null);
4554
+ const snapshotRef = import_react$2.useRef(void 0);
4544
4555
  if (subscriptionKeyRef.current === null || subscriptionKeyRef.current.query !== query || !isEqual(subscriptionKeyRef.current.input, input) || subscriptionKeyRef.current.selector !== selector) {
4545
4556
  subscriptionKeyRef.current = {
4546
4557
  query,
@@ -4550,7 +4561,7 @@ function useServiceQuery(query, input, selector) {
4550
4561
  snapshotRef.current = selector ? seedQueryState(query, input, selector) : seedQueryState(query, input);
4551
4562
  }
4552
4563
  const subscriptionKey = subscriptionKeyRef.current;
4553
- const subscribe = import_react$1.useCallback((listener) => {
4564
+ const subscribe = import_react$2.useCallback((listener) => {
4554
4565
  const { query: q, input: i, selector: s } = subscriptionKey;
4555
4566
  const onQueryState = (queryState) => {
4556
4567
  snapshotRef.current = queryState;
@@ -4558,15 +4569,15 @@ function useServiceQuery(query, input, selector) {
4558
4569
  };
4559
4570
  return s ? q.subscribe(i, s, onQueryState) : q.subscribe(i, onQueryState);
4560
4571
  }, [subscriptionKey]);
4561
- const getSnapshot = import_react$1.useCallback(() => {
4572
+ const getSnapshot = import_react$2.useCallback(() => {
4562
4573
  return snapshotRef.current;
4563
4574
  }, []);
4564
- return import_react$1.useSyncExternalStore(subscribe, getSnapshot);
4575
+ return import_react$2.useSyncExternalStore(subscribe, getSnapshot);
4565
4576
  }
4566
- var import_react$1;
4577
+ var import_react$2;
4567
4578
  function init_use_service_query() {
4568
4579
  return (init_use_service_query = __esmMin((() => {
4569
- import_react$1 = /* @__PURE__ */ __toESM(require_react(), 1);
4580
+ import_react$2 = /* @__PURE__ */ __toESM(require_react(), 1);
4570
4581
  init_isEqual();
4571
4582
  })))();
4572
4583
  }
@@ -4596,6 +4607,66 @@ function init_manager() {
4596
4607
  })))();
4597
4608
  }
4598
4609
  //#endregion
4610
+ //#region src/shared/use-sync-external-store/shim.ts
4611
+ function init_shim() {
4612
+ return (init_shim = __esmMin((() => {})))();
4613
+ }
4614
+ //#endregion
4615
+ //#region src/shared/use-sync-external-store/with-selector.ts
4616
+ function useSyncExternalStoreWithSelector(subscribe, getSnapshot, getServerSnapshot, selector, isEqual) {
4617
+ const instRef = (0, import_react$1.useRef)(null);
4618
+ if (instRef.current === null) instRef.current = {
4619
+ hasValue: false,
4620
+ value: null
4621
+ };
4622
+ const inst = instRef.current;
4623
+ const [getSelection, getServerSelection] = (0, import_react$1.useMemo)(() => {
4624
+ let hasMemo = false;
4625
+ let memoizedSnapshot;
4626
+ let memoizedSelection;
4627
+ const memoizedSelector = (nextSnapshot) => {
4628
+ if (!hasMemo) {
4629
+ hasMemo = true;
4630
+ memoizedSnapshot = nextSnapshot;
4631
+ const nextSelection = selector(nextSnapshot);
4632
+ if (isEqual !== void 0 && inst.hasValue) {
4633
+ const currentSelection = inst.value;
4634
+ if (isEqual(currentSelection, nextSelection)) return memoizedSelection = currentSelection;
4635
+ }
4636
+ return memoizedSelection = nextSelection;
4637
+ }
4638
+ const currentSelection = memoizedSelection;
4639
+ if (Object.is(memoizedSnapshot, nextSnapshot)) return currentSelection;
4640
+ const nextSelection = selector(nextSnapshot);
4641
+ if (isEqual !== void 0 && isEqual(currentSelection, nextSelection)) {
4642
+ memoizedSnapshot = nextSnapshot;
4643
+ return currentSelection;
4644
+ }
4645
+ memoizedSnapshot = nextSnapshot;
4646
+ return memoizedSelection = nextSelection;
4647
+ };
4648
+ return [() => memoizedSelector(getSnapshot()), getServerSnapshot == null ? void 0 : () => memoizedSelector(getServerSnapshot())];
4649
+ }, [
4650
+ getSnapshot,
4651
+ getServerSnapshot,
4652
+ selector,
4653
+ isEqual
4654
+ ]);
4655
+ const value = (0, import_react$1.useSyncExternalStore)(subscribe, getSelection, getServerSelection);
4656
+ (0, import_react$1.useEffect)(() => {
4657
+ inst.hasValue = true;
4658
+ inst.value = value;
4659
+ }, [value]);
4660
+ (0, import_react$1.useDebugValue)(value);
4661
+ return value;
4662
+ }
4663
+ var import_react$1;
4664
+ function init_with_selector() {
4665
+ return (init_with_selector = __esmMin((() => {
4666
+ import_react$1 = require_react();
4667
+ })))();
4668
+ }
4669
+ //#endregion
4599
4670
  //#region src/theming/modules/syntax.ts
4600
4671
  var chromeDark, chromeLight, create;
4601
4672
  function init_syntax() {
@@ -4843,7 +4914,7 @@ function init_css_vars() {
4843
4914
  kebab = (key) => key.replace(/[A-Z]/g, (char) => `-${char.toLowerCase()}`);
4844
4915
  px = (value) => typeof value === "number" ? `${value}px` : value;
4845
4916
  addGroup = (vars, prefix, group, unit = String) => {
4846
- for (const [key, value] of Object.entries(group ?? {})) if (typeof value === "string" || typeof value === "number") vars[`--sb-${prefix}-${kebab(key)}`] = unit(value);
4917
+ for (const [key, value] of Object.entries(group ?? {})) if (typeof value === "string" || typeof value === "number") vars[`--fb-${prefix}-${kebab(key)}`] = unit(value);
4847
4918
  };
4848
4919
  themeToCssVars = (theme) => {
4849
4920
  const vars = {};
@@ -4894,7 +4965,7 @@ function init_ThemeProvider() {
4894
4965
  ...themeToCssVars(theme)
4895
4966
  }), [theme]);
4896
4967
  return /* @__PURE__ */ import_react.default.createElement(ThemeContext.Provider, { value: theme }, /* @__PURE__ */ import_react.default.createElement("div", {
4897
- "data-sb-theme": theme.base,
4968
+ "data-fb-theme": theme.base,
4898
4969
  style
4899
4970
  }, children));
4900
4971
  };
@@ -4903,8 +4974,8 @@ function init_ThemeProvider() {
4903
4974
  //#endregion
4904
4975
  //#region src/theming/global.ts
4905
4976
  var resetCss, globalCss;
4906
- function init_global() {
4907
- return (init_global = __esmMin((() => {
4977
+ function init_global$1() {
4978
+ return (init_global$1 = __esmMin((() => {
4908
4979
  init_base();
4909
4980
  resetCss = `
4910
4981
  body {
@@ -4921,6 +4992,30 @@ body {
4921
4992
  box-sizing: border-box;
4922
4993
  }
4923
4994
 
4995
+ /* 1px neutral scrollbars everywhere (panels, docs, code blocks).
4996
+ Chrome ignores the ::-webkit-scrollbar rules when scrollbar-width is set,
4997
+ so only Firefox gets scrollbar-width. */
4998
+ @supports (-moz-appearance: none) {
4999
+ * {
5000
+ scrollbar-width: thin;
5001
+ scrollbar-color: rgb(120 120 128 / 0.45) transparent;
5002
+ }
5003
+ }
5004
+
5005
+ ::-webkit-scrollbar {
5006
+ width: 1px;
5007
+ height: 1px;
5008
+ }
5009
+
5010
+ ::-webkit-scrollbar-track,
5011
+ ::-webkit-scrollbar-corner {
5012
+ background: transparent;
5013
+ }
5014
+
5015
+ ::-webkit-scrollbar-thumb {
5016
+ background: rgb(120 120 128 / 0.6);
5017
+ }
5018
+
4924
5019
  h1, h2, h3, h4, h5, h6 {
4925
5020
  font-weight: ${typography.weight.regular};
4926
5021
  margin: 0;
@@ -4981,24 +5076,24 @@ pre {
4981
5076
  ${resetCss}
4982
5077
 
4983
5078
  body {
4984
- font-family: var(--sb-font-base);
5079
+ font-family: var(--fb-font-base);
4985
5080
  position: fixed;
4986
5081
  width: 100vw;
4987
5082
  height: 100vh;
4988
5083
  overflow: hidden;
4989
- color: var(--sb-color-default-text);
4990
- background: var(--sb-background-app);
5084
+ color: var(--fb-color-default-text);
5085
+ background: var(--fb-background-app);
4991
5086
  }
4992
5087
 
4993
5088
  code, pre {
4994
- font-family: var(--sb-font-mono);
5089
+ font-family: var(--fb-font-mono);
4995
5090
  }
4996
5091
 
4997
5092
  hr {
4998
- border-top: 1px solid var(--sb-color-border);
5093
+ border-top: 1px solid var(--fb-color-border);
4999
5094
  }
5000
5095
 
5001
- .sb-sr-only, .sb-hidden-until-focus:not(:focus) {
5096
+ .fb-sr-only, .fb-hidden-until-focus:not(:focus) {
5002
5097
  position: absolute;
5003
5098
  width: 1px;
5004
5099
  height: 1px;
@@ -5011,29 +5106,29 @@ hr {
5011
5106
  border: 0;
5012
5107
  }
5013
5108
 
5014
- .sb-hidden-until-focus {
5109
+ .fb-hidden-until-focus {
5015
5110
  opacity: 0;
5016
5111
  transition: opacity 150ms ease-out;
5017
5112
  }
5018
5113
 
5019
- .sb-hidden-until-focus:focus {
5114
+ .fb-hidden-until-focus:focus {
5020
5115
  opacity: 1;
5021
5116
  }
5022
5117
 
5023
- [data-sb-landmark] {
5118
+ [data-fb-landmark] {
5024
5119
  position: relative;
5025
5120
  }
5026
5121
 
5027
- [data-sb-landmark]:focus-visible {
5122
+ [data-fb-landmark]:focus-visible {
5028
5123
  outline: none;
5029
5124
  }
5030
5125
 
5031
- [data-sb-landmark]:focus-visible::after {
5032
- outline: 2px solid var(--sb-color-primary);
5126
+ [data-fb-landmark]:focus-visible::after {
5127
+ outline: 2px solid var(--fb-color-primary);
5033
5128
  outline-offset: -2px;
5034
5129
  }
5035
5130
 
5036
- [data-sb-landmark]::after {
5131
+ [data-fb-landmark]::after {
5037
5132
  content: '';
5038
5133
  position: absolute;
5039
5134
  inset: 0;
@@ -5091,7 +5186,7 @@ function init_theming() {
5091
5186
  init_base();
5092
5187
  init_ThemeProvider();
5093
5188
  init_css_vars();
5094
- init_global();
5189
+ init_global$1();
5095
5190
  init_create();
5096
5191
  init_convert();
5097
5192
  init_ensure();
@@ -5099,4 +5194,4 @@ function init_theming() {
5099
5194
  })))();
5100
5195
  }
5101
5196
  //#endregion
5102
- export { clearAnnouncer as $, create_exports as A, init_events as B, router_exports as C, init_routes as D, queryFromLocation as E, Tag as F, countStatusesByValue as G, NON_AGGREGATED_STATUS_TYPE_IDS as H, USER_TAG_FILTER as I, statusValueShortName as J, createStatusStore as K, init_tags as L, init_test as M, test_exports as N, isReviewManagerRoute as O, BUILT_IN_FILTERS as P, announce as Q, REVIEW_EVENTS as R, init_router$1 as S, init_utils$1 as T, REVIEW_STATUS_TYPE_ID as U, CHANGE_DETECTION_STATUS_TYPE_ID as V, UNIVERSAL_STATUS_STORE_OPTIONS as W, init_useCopyButton as X, toStatusValue as Y, useCopyButton as Z, init_test_provider_store as _, useTheme as a, UniversalStore as at, init_use_universal_store_manager as b, getService as c, init_storybook_error as ct, init_use_service_query as d, destroyAnnouncer as et, useServiceQuery as f, createTestProviderStore as g, UNIVERSAL_TEST_PROVIDER_STORE_OPTIONS as h, init_ThemeProvider as i, matchesHostname as it, init_create as j, create$1 as k, init_manager as l, useServiceCommand as m, theming_exports as n, LOOPBACK_HOSTNAMES as nt, init_css_vars as o, init_universal_store as ot, init_use_service_command as p, init_status_store as q, ThemeProvider as r, init_local_hosts as rt, themeToCssVars as s, StorybookError as st, init_theming as t, init_announce as tt, registerService as u, MockUniversalStore as v, buildArgsParam as w, useUniversalStore as x, init_mock as y, REVIEW_NAMESPACE as z };
5197
+ export { countStatusesByValue as $, setStoryPathEntries as A, init_test as B, init_use_universal_store_manager as C, buildManagerHref as D, router_exports as E, init_routes as F, init_tags as G, BUILT_IN_FILTERS as H, isReviewManagerRoute as I, init_events as J, REVIEW_EVENTS as K, create$1 as L, buildArgsParam as M, init_utils$1 as N, fromUrlPath as O, queryFromLocation as P, UNIVERSAL_STATUS_STORE_OPTIONS as Q, create_exports as R, init_mock as S, init_router$1 as T, Tag as U, test_exports as V, USER_TAG_FILTER as W, NON_AGGREGATED_STATUS_TYPE_IDS as X, CHANGE_DETECTION_STATUS_TYPE_ID as Y, REVIEW_STATUS_TYPE_ID as Z, useServiceCommand as _, UniversalStore as _t, useTheme as a, init_errors as at, init_test_provider_store as b, init_storybook_error as bt, init_with_selector as c, announce as ct, getService as d, init_announce as dt, createStatusStore as et, init_manager as f, LOOPBACK_HOSTNAMES as ft, init_use_service_command as g, init_global as gt, useServiceQuery as h, global as ht, init_ThemeProvider as i, formatIssues as it, toUrlPath as j, init_story_paths as k, useSyncExternalStoreWithSelector as l, clearAnnouncer as lt, init_use_service_query as m, matchesHostname as mt, theming_exports as n, statusValueShortName as nt, init_css_vars as o, init_useCopyButton as ot, registerService as p, init_local_hosts as pt, REVIEW_NAMESPACE as q, ThemeProvider as r, toStatusValue as rt, themeToCssVars as s, useCopyButton as st, init_theming as t, init_status_store as tt, init_shim as u, destroyAnnouncer as ut, UNIVERSAL_TEST_PROVIDER_STORE_OPTIONS as v, init_universal_store as vt, useUniversalStore as w, MockUniversalStore as x, createTestProviderStore as y, StorybookError as yt, init_create as z };