hyperframes 0.9.54 → 0.9.56

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 (316) hide show
  1. package/dist/{add-OVHVUHQR.js → add-KW7OTOWF.js} +23 -23
  2. package/dist/{agentPromptGenerator-L2B3HMHF.js → agentPromptGenerator-NNXUWNU4.js} +14 -13
  3. package/dist/{animatedGifPrep-YMJH33FX.js → animatedGifPrep-6ATQHQON.js} +15 -14
  4. package/dist/api.d.ts +4 -2
  5. package/dist/api.js +46 -44
  6. package/dist/{appHistory-T3ZLA7QN.js → appHistory-KHX53SGI.js} +6 -4
  7. package/dist/{asset-ORCN4EVH.js → asset-QVINGJRK.js} +2 -2
  8. package/dist/{assetCataloger-X23VB66T.js → assetCataloger-DENJPUBH.js} +15 -14
  9. package/dist/{audio-NHNXBUI2.js → audio-LB7HQYPJ.js} +28 -27
  10. package/dist/{auth-DQDDXQFC.js → auth-7AGRVI5A.js} +2 -2
  11. package/dist/{autoUpdate-LF7BJN34.js → autoUpdate-ITCP2JDM.js} +4 -4
  12. package/dist/{avatars-KFUMWRVX.js → avatars-2K2C74EQ.js} +19 -17
  13. package/dist/{backgroundChecks-Y6RHADW6.js → backgroundChecks-UOTBCWPN.js} +5 -5
  14. package/dist/backgroundChecksWorker.js +5 -5
  15. package/dist/{batchRender-CMG4SVBX.js → batchRender-Z7ESYQDS.js} +9 -7
  16. package/dist/{beats-JXZBK7JI.js → beats-TG6ZB3XH.js} +14 -14
  17. package/dist/{benchmark-CLU6JUGY.js → benchmark-RU5MLZHE.js} +20 -20
  18. package/dist/{billing-5GMYFDMC.js → billing-VB5PYYSN.js} +19 -19
  19. package/dist/{browser-S4R6LZMF.js → browser-VSQRY5GG.js} +12 -12
  20. package/dist/{bundleWithLocalizedFonts-SFUFSBEU.js → bundleWithLocalizedFonts-XDPJE355.js} +1 -1
  21. package/dist/{capture-A3FLQIDI.js → capture-M4FL7MWI.js} +25 -24
  22. package/dist/{capture-NL7V23HG.js → capture-TQCFWPAT.js} +4 -4
  23. package/dist/{captureCompositionFrame-R7GYVNTF.js → captureCompositionFrame-XF67Q6YK.js} +20 -19
  24. package/dist/{captureFile-LXMDM5TD.js → captureFile-F254H22J.js} +3 -3
  25. package/dist/{catalog-42I7W7AU.js → catalog-24EGH662.js} +23 -23
  26. package/dist/catalog-artifact/media-vectors.json +205 -0
  27. package/dist/{catch-up-TFSQZQZD.js → catch-up-L23HGDLB.js} +16 -16
  28. package/dist/{check-CXRQZBLD.js → check-F4HQVV2M.js} +56 -53
  29. package/dist/{checkAudio-AJUH6RU6.js → checkAudio-6DT3ONR7.js} +17 -16
  30. package/dist/{checkBrowser-4BLSYI25.js → checkBrowser-S7P4X7QV.js} +46 -45
  31. package/dist/{chunk-Q42L7V5T.js → chunk-2GRCTZNS.js} +1 -1
  32. package/dist/{chunk-EKANCN4D.js → chunk-2ZOJCSLJ.js} +3 -3
  33. package/dist/{chunk-ER22SVLT.js → chunk-3GVHDPEP.js} +1 -1
  34. package/dist/{chunk-MPU2CRFV.js → chunk-43CQTZGB.js} +13 -14
  35. package/dist/{chunk-63ESYLBY.js → chunk-4DJGUZJR.js} +2 -2
  36. package/dist/{chunk-B6AK5P2D.js → chunk-4GPKDDQZ.js} +7 -7
  37. package/dist/{chunk-KYUCSRZU.js → chunk-4WSJ5MUN.js} +1 -1
  38. package/dist/{chunk-T5S7U5C6.js → chunk-52XHPMCX.js} +1 -1
  39. package/dist/chunk-56T2OGYR.js +5085 -0
  40. package/dist/{chunk-4Q3Q4NFK.js → chunk-5GSCSZOS.js} +2 -2
  41. package/dist/{chunk-3L2POG2J.js → chunk-5IE5ZI66.js} +37 -8
  42. package/dist/{chunk-SWAG64KW.js → chunk-5ZDNSYTO.js} +8 -13
  43. package/dist/{chunk-N7M2SNAF.js → chunk-664QGMR4.js} +2 -2
  44. package/dist/chunk-677JGYQL.js +91 -0
  45. package/dist/{chunk-GA6QR6LN.js → chunk-6LONEKJR.js} +253 -158
  46. package/dist/{chunk-LEIR7IDJ.js → chunk-6LU6JICP.js} +80 -1
  47. package/dist/{chunk-SVIA7POL.js → chunk-6XRXUMFG.js} +2 -2
  48. package/dist/{chunk-4ZFNNWUX.js → chunk-7DKWEIH4.js} +10 -10
  49. package/dist/{chunk-GEUM7NDY.js → chunk-7E7VKASF.js} +2 -2
  50. package/dist/{chunk-5HJZGP54.js → chunk-7F4RAWDS.js} +2 -2
  51. package/dist/{chunk-OWS4ZWEY.js → chunk-7HQC5MDZ.js} +1 -1
  52. package/dist/{chunk-P4YIRU76.js → chunk-7QFFS657.js} +1 -1
  53. package/dist/{chunk-AYESPEPQ.js → chunk-7QFLMCTD.js} +6 -1
  54. package/dist/chunk-AGTBMLNM.js +42 -0
  55. package/dist/{chunk-BNONW4QT.js → chunk-AN6KWGYI.js} +2 -2
  56. package/dist/{chunk-JAAIW4JR.js → chunk-ANYW22IT.js} +1 -1
  57. package/dist/{chunk-JRSBBFUU.js → chunk-APCVZGU6.js} +402 -110
  58. package/dist/{chunk-7WRLK2K4.js → chunk-B6BWLFAF.js} +2 -2
  59. package/dist/{chunk-VCKUDUPN.js → chunk-BA33QNKK.js} +199 -15
  60. package/dist/{chunk-WPSPW7SI.js → chunk-BMVUB2CY.js} +6 -6
  61. package/dist/{chunk-5XLTJMCN.js → chunk-BPYNILOZ.js} +5 -5
  62. package/dist/{chunk-H5KHQ6KS.js → chunk-BR7GOCQJ.js} +1 -1
  63. package/dist/{chunk-6SRBTOGD.js → chunk-BTJYK56C.js} +3 -3
  64. package/dist/{chunk-EA5W2DWO.js → chunk-BUG5AOPJ.js} +3 -3
  65. package/dist/{chunk-7RI3U46M.js → chunk-BW4H55SU.js} +1 -1
  66. package/dist/{chunk-SDFGDNWV.js → chunk-BZXW5QU7.js} +1 -1
  67. package/dist/{chunk-WPD7JH6F.js → chunk-CBG6MIT2.js} +2 -2
  68. package/dist/{chunk-O7TIBLSJ.js → chunk-CKIVYAKG.js} +80 -15
  69. package/dist/{chunk-YVCPUVHV.js → chunk-CKIYT34K.js} +1 -1
  70. package/dist/{chunk-DWDCE4PO.js → chunk-CLRHKYOK.js} +6 -6
  71. package/dist/{chunk-3IUBSGD2.js → chunk-CNXZCMJZ.js} +2 -2
  72. package/dist/{chunk-F64VFCVC.js → chunk-CPSD7337.js} +51 -28
  73. package/dist/{chunk-73UFPVUC.js → chunk-CUO2HF4M.js} +2 -2
  74. package/dist/{chunk-JSYLOPVJ.js → chunk-CWIOKI2R.js} +1 -1
  75. package/dist/{chunk-IB6FFEDH.js → chunk-CXFW7YPT.js} +42 -48
  76. package/dist/{chunk-YNF3SH26.js → chunk-CZCZ5YXT.js} +3 -2
  77. package/dist/{chunk-SUG2AA33.js → chunk-D3WRRPHI.js} +10 -10
  78. package/dist/{chunk-CWXJZB44.js → chunk-DDCXMXAD.js} +11 -11
  79. package/dist/{chunk-X6TDH2OM.js → chunk-DUZ6Z2ZN.js} +1 -1
  80. package/dist/{chunk-DXVK3NMV.js → chunk-EBRN4YJH.js} +3 -3
  81. package/dist/{chunk-RBBWUYMG.js → chunk-EGR2ZFFP.js} +4 -4
  82. package/dist/{chunk-AU4ZBCR3.js → chunk-EKSS3KI7.js} +1 -1
  83. package/dist/{chunk-TMV76KPG.js → chunk-EUP7ODOV.js} +1 -1
  84. package/dist/{chunk-E2DHBP6C.js → chunk-FGGRBKWL.js} +1 -1
  85. package/dist/{chunk-GIOLHGCC.js → chunk-GTC2STHN.js} +116 -27
  86. package/dist/{chunk-E7T5SMDK.js → chunk-GWSMTN55.js} +51 -10
  87. package/dist/{chunk-QGKRHG4Q.js → chunk-HCQXGGVY.js} +18 -18
  88. package/dist/{chunk-WAAXVZIT.js → chunk-HOCV5AW6.js} +2 -2
  89. package/dist/{chunk-7RGWVZOS.js → chunk-HVG656G6.js} +3 -3
  90. package/dist/{chunk-D4EGZYDN.js → chunk-ICDGP335.js} +13 -10
  91. package/dist/{chunk-NKAW4RVE.js → chunk-IDGWNOBX.js} +1 -1
  92. package/dist/{chunk-YU5LSWA2.js → chunk-IHX3AFTY.js} +2 -2
  93. package/dist/{chunk-CAYQATCT.js → chunk-IO7PRQQC.js} +1 -1
  94. package/dist/{chunk-BDWLBCTG.js → chunk-IRZUZ32B.js} +5 -5
  95. package/dist/{chunk-QONV77VI.js → chunk-IT2QBRVS.js} +1 -1
  96. package/dist/{chunk-PXLGDX2S.js → chunk-JDXALWOM.js} +39 -24
  97. package/dist/{chunk-E7X54BVP.js → chunk-JPEIUGS5.js} +1 -1
  98. package/dist/{chunk-4IUOWNDS.js → chunk-JQKCRTVQ.js} +2 -2
  99. package/dist/{chunk-UZJ7Y7WU.js → chunk-KRYXZVA2.js} +3 -3
  100. package/dist/{chunk-CIYNUD7Q.js → chunk-L27Z3PZT.js} +1 -1
  101. package/dist/{chunk-CBCB6GPL.js → chunk-L5CBCPUH.js} +60 -33
  102. package/dist/{chunk-BBDWXUO3.js → chunk-L5NPBGQB.js} +15 -22
  103. package/dist/{chunk-B5HSHXE2.js → chunk-LH5FRVAO.js} +12 -7
  104. package/dist/{chunk-YBLBI3O2.js → chunk-LK7F7P2X.js} +6 -3
  105. package/dist/{chunk-4WK4O5FI.js → chunk-LRQEIKFT.js} +67 -27
  106. package/dist/{chunk-FUPEHRNT.js → chunk-LRWWCTSJ.js} +2 -2
  107. package/dist/{chunk-RXJUMVCA.js → chunk-MDRLJ737.js} +5 -2
  108. package/dist/{chunk-VK3MQSA2.js → chunk-MK4RH5L7.js} +5 -2
  109. package/dist/{chunk-AROERRUJ.js → chunk-MP52CUHL.js} +2 -2
  110. package/dist/{chunk-ATKA5KHE.js → chunk-MPOWSPBD.js} +3 -3
  111. package/dist/{chunk-H7DKHNBF.js → chunk-MVLAPENI.js} +36 -8
  112. package/dist/{chunk-2PASB3PC.js → chunk-NCJSN6SV.js} +5 -5
  113. package/dist/{chunk-DVTRMGYG.js → chunk-NFST2HIM.js} +2 -2
  114. package/dist/{chunk-C7LNWZ7G.js → chunk-OXT2LXZB.js} +8 -6
  115. package/dist/{chunk-MEGSQW2I.js → chunk-OZDELWQP.js} +2 -29
  116. package/dist/{chunk-EB4IWBBC.js → chunk-PCKKKICA.js} +18 -4
  117. package/dist/{chunk-SOMX57XG.js → chunk-PGHROSLJ.js} +4 -4
  118. package/dist/{chunk-Q3ESTCZH.js → chunk-PGJYA6I3.js} +11 -11
  119. package/dist/{chunk-NKUUNSII.js → chunk-PHAZT6EB.js} +1 -1
  120. package/dist/{chunk-KCF6Q54R.js → chunk-PUTPYYE4.js} +1 -1
  121. package/dist/{chunk-NRGNEP3R.js → chunk-PVF32NRA.js} +2 -2
  122. package/dist/{chunk-32DAUKF5.js → chunk-Q2TT62RQ.js} +4 -4
  123. package/dist/{chunk-EXXIFMUX.js → chunk-QBADK3LD.js} +13 -5
  124. package/dist/{chunk-DOLVT6CH.js → chunk-QJDMX53S.js} +1 -1
  125. package/dist/{chunk-F7B2YDPM.js → chunk-QNIID7EN.js} +6 -8
  126. package/dist/{chunk-FICKJQU2.js → chunk-QTZICZWT.js} +4 -4
  127. package/dist/{chunk-Y6UCMYJZ.js → chunk-R2LP7QPB.js} +1 -1
  128. package/dist/{chunk-YUDWGRNZ.js → chunk-RCGNYXWK.js} +14 -14
  129. package/dist/{chunk-CNZOKODL.js → chunk-RFULFCYW.js} +3 -3
  130. package/dist/{chunk-26RTKW2U.js → chunk-RRT6URIP.js} +2 -2
  131. package/dist/{chunk-IR2GEREV.js → chunk-SEC76O65.js} +1 -1
  132. package/dist/{chunk-3NXY6O4X.js → chunk-SGWDJLFL.js} +1 -1
  133. package/dist/{chunk-RXSPJW77.js → chunk-T5HYPGST.js} +4 -4
  134. package/dist/{chunk-77U3646W.js → chunk-TVZTTWU7.js} +2 -2
  135. package/dist/{chunk-ELA3IV4P.js → chunk-TY7EHE4Q.js} +2 -2
  136. package/dist/{chunk-75TCOXNT.js → chunk-UHVKV5IF.js} +1 -1
  137. package/dist/{chunk-SULPT5X6.js → chunk-UIMXEY4U.js} +6 -6
  138. package/dist/{chunk-KWTTELUY.js → chunk-UVPLW55S.js} +37 -1
  139. package/dist/{chunk-EKCGL4MV.js → chunk-VC4YMXUQ.js} +1 -1
  140. package/dist/{chunk-H2GJDFF6.js → chunk-VCSQLM36.js} +14 -9
  141. package/dist/{chunk-VT2K6I4A.js → chunk-VVXSMYXQ.js} +3 -3
  142. package/dist/{chunk-NCLBKHCX.js → chunk-W4AR7UZH.js} +2 -2
  143. package/dist/{chunk-TM7D3NOR.js → chunk-WFB4XPJR.js} +45 -11
  144. package/dist/{chunk-PAA5FUUL.js → chunk-WGWKT7ME.js} +3 -3
  145. package/dist/{chunk-LRXARA5O.js → chunk-WHX2OV4C.js} +1 -1
  146. package/dist/{chunk-O6E5HSVF.js → chunk-WUY74LHU.js} +2 -2
  147. package/dist/{chunk-RZJ7BHXB.js → chunk-XD5T43S7.js} +1 -1
  148. package/dist/{chunk-3NPZZT2K.js → chunk-XEVAW42J.js} +9 -9
  149. package/dist/{chunk-JHOCK3DG.js → chunk-XFF4XJZO.js} +11 -3
  150. package/dist/{chunk-4NG5GSTO.js → chunk-XKNNZ4WR.js} +1 -1
  151. package/dist/{chunk-3IHRXHJQ.js → chunk-XLP34AJR.js} +2 -2
  152. package/dist/{chunk-QKYGGUOQ.js → chunk-YDNBMPP3.js} +4 -4
  153. package/dist/{chunk-PLOVBMJF.js → chunk-YFWFCKKF.js} +291 -235
  154. package/dist/{chunk-EZQJFCWA.js → chunk-YOMFN6HH.js} +2 -2
  155. package/dist/{chunk-TRAPS5WB.js → chunk-YQSVPHOS.js} +27 -37
  156. package/dist/{chunk-OTWFSHYH.js → chunk-YWH7HWDP.js} +269 -145
  157. package/dist/chunk-YXX6CIHL.js +25 -0
  158. package/dist/{chunk-TW4DB2NK.js → chunk-Z72VXQPN.js} +2 -2
  159. package/dist/{chunk-KTLRJZFK.js → chunk-ZIF44RW2.js} +9 -10
  160. package/dist/{clean-JK4VQMTH.js → clean-VB6BH3FV.js} +30 -29
  161. package/dist/cli.js +66 -66
  162. package/dist/{cloud-JZ2WKHQG.js → cloud-7KRPD2K4.js} +4 -4
  163. package/dist/{cloud-LU4FVT33.js → cloud-A67BW6OH.js} +3 -3
  164. package/dist/{cloudrun-QBXSGBGX.js → cloudrun-VKBARVVT.js} +22 -9
  165. package/dist/{compare-YE5BTDCG.js → compare-SE55PMC3.js} +45 -44
  166. package/dist/{compiler-QEA5UQRG.js → compiler-WK7ABGRW.js} +6 -6
  167. package/dist/{component-MGT5ZJ4M.js → component-XT2AT3RY.js} +3 -3
  168. package/dist/{compositions-7OF6FDCH.js → compositions-ZZWLQNDQ.js} +25 -23
  169. package/dist/{contactSheet-CCHQAZLA.js → contactSheet-MXOASCDR.js} +4 -4
  170. package/dist/{curve-JQLVUDXR.js → curve-4RQQKZ2K.js} +19 -17
  171. package/dist/{cuts-MCJP6LMJ.js → cuts-M3QU2CBE.js} +20 -18
  172. package/dist/{delete-PUYEW3RJ.js → delete-5ZZNPK5G.js} +7 -7
  173. package/dist/{deploy-M4XGMJM5.js → deploy-VR5SQP4U.js} +9 -4
  174. package/dist/{describeProject-P7CBZ6NW.js → describeProject-NU5BVVIA.js} +14 -13
  175. package/dist/{destroy-6XJWSH2A.js → destroy-FFS62PAW.js} +9 -4
  176. package/dist/{deterministicFonts-OXGNMVJE.js → deterministicFonts-FQQNGORI.js} +4 -4
  177. package/dist/{diff-BATSO64W.js → diff-NQGTF6GR.js} +58 -52
  178. package/dist/{dist-T62DJJZX.js → dist-6GYOC3BU.js} +4 -4
  179. package/dist/{dist-G6W7GKGP.js → dist-APXZ5EN2.js} +3 -3
  180. package/dist/{dist-PC3EMMET.js → dist-B7IBHWIW.js} +18 -15
  181. package/dist/{doctor-ONTGSPYF.js → doctor-FATJGTPD.js} +22 -21
  182. package/dist/{energy-FNZICGW2.js → energy-PHDK6SKL.js} +20 -18
  183. package/dist/{events-LBHSU7C2.js → events-25VQ2O66.js} +10 -10
  184. package/dist/{events-6TNBAVVY.js → events-OIWXSBZA.js} +25 -22
  185. package/dist/{events-ENJZNXWG.js → events-RXVHG2NT.js} +5 -5
  186. package/dist/{execute-RXTEBACV.js → execute-MKP4Z573.js} +36 -35
  187. package/dist/{extract-F2CWTMLX.js → extract-YYNYXPOC.js} +20 -18
  188. package/dist/{face-7HL4CP32.js → face-JSTMFQRM.js} +21 -19
  189. package/dist/{feedback-4NDDMECH.js → feedback-PY6LMZCX.js} +19 -19
  190. package/dist/{ffmpeg-3LL345SO.js → ffmpeg-KLIB55FK.js} +13 -12
  191. package/dist/{figma-474E54NB.js → figma-ACFOXVPM.js} +3 -3
  192. package/dist/fontLocalizeCli.js +20 -19
  193. package/dist/{frames-EZWGM7QQ.js → frames-BLZCBXO7.js} +22 -20
  194. package/dist/{generate-I75DZWDU.js → generate-DMVEKZEV.js} +33 -31
  195. package/dist/{get-BHU6CBWO.js → get-3WZDQ5YM.js} +7 -7
  196. package/dist/{gpuPolicy-6J2STCV2.js → gpuPolicy-TT6UCOLQ.js} +13 -12
  197. package/dist/{grade-compare-D4TBMCBG.js → grade-compare-F5DJ53XH.js} +47 -44
  198. package/dist/hangReport.js +2 -2
  199. package/dist/{heifImagePrep-VLYGRKSS.js → heifImagePrep-UV23RWOG.js} +16 -15
  200. package/dist/{help-2CUXKYJ6.js → help-QMP5KFYW.js} +1 -1
  201. package/dist/{history-LVAVYTAN.js → history-UOZ4RDEZ.js} +21 -18
  202. package/dist/hyperframe.manifest.json +1 -1
  203. package/dist/hyperframe.runtime.iife.js +76 -76
  204. package/dist/hyperframes-player.global.js +1 -1
  205. package/dist/{info-SUZOEH6L.js → info-A6KSO64E.js} +21 -20
  206. package/dist/{init-XI5QN3A6.js → init-OQU46K3Q.js} +52 -47
  207. package/dist/{ink-OVDZOCQJ.js → ink-HGRKLGII.js} +20 -18
  208. package/dist/{inspect-INBCGPBD.js → inspect-BKENKUXF.js} +44 -43
  209. package/dist/{installer-JNQKFCTN.js → installer-Z6FTR7BJ.js} +8 -8
  210. package/dist/{keyframes-LYZJK4RH.js → keyframes-UDQGWKPW.js} +14 -14
  211. package/dist/{lambda-DUDXZV6X.js → lambda-SHXQFHLE.js} +23 -22
  212. package/dist/{layout-JKUJW6A4.js → layout-CJAVQ4D3.js} +44 -43
  213. package/dist/{lint-NKDC7IJ2.js → lint-RAPNYPWS.js} +15 -15
  214. package/dist/{lintProject-5Z34NNS4.js → lintProject-JZRM7UKH.js} +3 -3
  215. package/dist/{list-5HUMDJYL.js → list-4BKFMJQN.js} +7 -7
  216. package/dist/{localPage-RRBRFR4Y.js → localPage-BJW2TP77.js} +14 -13
  217. package/dist/{login-C3SHKITR.js → login-S5VZAGCI.js} +4 -4
  218. package/dist/{look-3TX2U4BE.js → look-V2I6BGUY.js} +20 -18
  219. package/dist/{manager-MOR255LW.js → manager-OS2FYJI5.js} +14 -13
  220. package/dist/{manager-45VB2G5F.js → manager-WQWU5VJ4.js} +5 -5
  221. package/dist/{measure-ZAKBHNGY.js → measure-RO5R2SUZ.js} +11 -11
  222. package/dist/{media-treatment-QJ35DSED.js → media-treatment-CS7BVMJW.js} +21 -20
  223. package/dist/{media-use-YBKHJVXL.js → media-use-W3DGCKFB.js} +5 -5
  224. package/dist/{models-OQHKG7B4.js → models-ZOGYW2SC.js} +18 -17
  225. package/dist/{motionShot-TWQTREFH.js → motionShot-IMRI7W7T.js} +24 -23
  226. package/dist/{normalize-audio-PXHPUOMD.js → normalize-audio-HXTFAZUK.js} +14 -14
  227. package/dist/{open-TVGO5KVF.js → open-LJDQ37KV.js} +25 -24
  228. package/dist/{parakeetRunner-MVJMZSIG.js → parakeetRunner-CKMSKDH6.js} +21 -20
  229. package/dist/{pipeline-4S5UE4O4.js → pipeline-ZNCYOTUH.js} +16 -15
  230. package/dist/{plan-AMBZUX55.js → plan-NCFS5T6W.js} +28 -27
  231. package/dist/{play-KEAESNBM.js → play-5UZDFFXJ.js} +39 -32
  232. package/dist/{preflight-K3CM3W55.js → preflight-H5XYFKFF.js} +16 -15
  233. package/dist/{present-42WDBGBA.js → present-EFXUFT5Y.js} +62 -46
  234. package/dist/{preview-KSHBU7ZR.js → preview-RV7ALGDQ.js} +35 -33
  235. package/dist/{probe-TMSXGCL4.js → probe-UB6DM2Q3.js} +20 -18
  236. package/dist/{producer-KXRSJPJF.js → producer-2PKB5CW5.js} +1 -1
  237. package/dist/{progress-IY6U35WH.js → progress-S36VQBQW.js} +3 -1
  238. package/dist/{projectConfig-LOHNVOJG.js → projectConfig-EUH5DILC.js} +12 -12
  239. package/dist/{publication-LYPU7NTZ.js → publication-VI2AXXKR.js} +6 -6
  240. package/dist/{publish-PYZXDQJW.js → publish-225GB7R4.js} +25 -25
  241. package/dist/{remove-background-HVX52VOF.js → remove-background-W2RLEQHJ.js} +17 -16
  242. package/dist/{render-CM4MCNVA.js → render-KXKBSNOQ.js} +9 -8
  243. package/dist/{render-57ZYQ53S.js → render-WMWCCMWI.js} +71 -54
  244. package/dist/{render-5KMA5P2U.js → render-Y3JKWEN4.js} +42 -39
  245. package/dist/{render-batch-URBBGOVC.js → render-batch-GK6CDHKN.js} +10 -9
  246. package/dist/renderSetupWorker.js +8 -8
  247. package/dist/{resolver-UPUCU4XT.js → resolver-5CRZD5XB.js} +9 -9
  248. package/dist/{reverse-UYS7KVE2.js → reverse-YPYKKQSJ.js} +1 -1
  249. package/dist/{run-4LNEWQLG.js → run-FQ76QNES.js} +7 -7
  250. package/dist/{sam-EGFXZF56.js → sam-A4NXDWSU.js} +4 -1
  251. package/dist/{screenshotCapture-IF5AO5XM.js → screenshotCapture-R6VE66NR.js} +16 -15
  252. package/dist/{service-OEOC34BD.js → service-P3IKHZFC.js} +18 -17
  253. package/dist/{share-NS7CMVSU.js → share-BU4VQL3B.js} +21 -20
  254. package/dist/{sherpa-QBTXL6JA.js → sherpa-44GLXY3A.js} +20 -19
  255. package/dist/sherpaWorker.js +5 -3
  256. package/dist/{sites-QK3F4AUS.js → sites-TAX3JLNX.js} +3 -1
  257. package/dist/skills/hyperframes/SKILL.md +2 -2
  258. package/dist/skills/hyperframes/references/format.md +11 -2
  259. package/dist/skills/hyperframes/references/overlays.md +1 -1
  260. package/dist/skills/hyperframes/references/plugin-installation.md +33 -22
  261. package/dist/skills/hyperframes/references/sound.md +1 -0
  262. package/dist/skills/hyperframes/scripts/plugin-cli.mjs +18 -13
  263. package/dist/skills/hyperframes/scripts/plugin-cli.test.mjs +64 -40
  264. package/dist/skills/hyperframes-cli/SKILL.md +2 -2
  265. package/dist/skills/media-use/SKILL.md +1 -1
  266. package/dist/skills/media-use/audio/scripts/lib/bgm.mjs +4 -1
  267. package/dist/skills/media-use/audio/scripts/lib/bgm.test.mjs +62 -1
  268. package/dist/skills/media-use/audio/scripts/lib/python.mjs +9 -1
  269. package/dist/skills/media-use/audio/scripts/lib/python.test.mjs +16 -0
  270. package/dist/skills/media-use/scripts/lib/bundled-sfx-provider.mjs +27 -2
  271. package/dist/skills/media-use/scripts/lib/bundled-sfx-provider.test.mjs +40 -1
  272. package/dist/skills/media-use/scripts/lib/local-media-search.mjs +52 -23
  273. package/dist/skills/media-use/scripts/lib/local-media-search.test.mjs +73 -4
  274. package/dist/skills/media-use/scripts/lib/ltx-video-provider.mjs +3 -1
  275. package/dist/skills/media-use/scripts/lib/ltx-video-provider.test.mjs +16 -1
  276. package/dist/skills/media-use/scripts/resolve.mjs +4 -14
  277. package/dist/skills/media-use/scripts/transcribe.mjs +19 -3
  278. package/dist/skills/media-use/scripts/transcribe.test.mjs +60 -0
  279. package/dist/{skills-S5U2MQAI.js → skills-H4OZQ6VR.js} +15 -14
  280. package/dist/{skillsUpdateCheck-UZ7CZ6VC.js → skillsUpdateCheck-U3XZX7UE.js} +5 -5
  281. package/dist/{snapshot-YWFWQTAV.js → snapshot-FJQVXBFB.js} +59 -56
  282. package/dist/{src-N2SMYJ44.js → src-O6BHCR4O.js} +18 -17
  283. package/dist/{src-UQ3K3UW2.js → src-PAM5LJ6K.js} +12 -11
  284. package/dist/{start-4IA5GG5D.js → start-R7CYOQ5S.js} +31 -29
  285. package/dist/{state-7OIPR4BG.js → state-YFRV6TQH.js} +3 -1
  286. package/dist/{staticProjectServer-5JP25RRX.js → staticProjectServer-4X2OSUN4.js} +29 -28
  287. package/dist/{status-ITCKXFBF.js → status-VN3FAN4M.js} +21 -21
  288. package/dist/studio/assets/{hyperframes-player-Oju91F6x.js → hyperframes-player-SRLbmEDB.js} +1 -1
  289. package/dist/studio/assets/{index-B0VEzzD2.js → index-CgyBYe2L.js} +130 -130
  290. package/dist/studio/assets/{index-XEm_N45R.js → index-yuN1pZrv.js} +1 -1
  291. package/dist/studio/assets/{pausedVideoDecoder-p6zibxVM.js → pausedVideoDecoder-DtvSF8bV.js} +1 -1
  292. package/dist/studio/index.html +1 -1
  293. package/dist/{studio-api-GENM2XVL.js → studio-api-V3TMIWFB.js} +18 -15
  294. package/dist/{studioSelectionClient-W2S3H2VO.js → studioSelectionClient-S46TNAAZ.js} +2 -1
  295. package/dist/{studioServer-SWR5Q3PD.js → studioServer-GY2ZTR2E.js} +90 -77
  296. package/dist/{sync-CK6TTCXO.js → sync-2V3JYCDE.js} +20 -18
  297. package/dist/{synthesize-EXNEBJSY.js → synthesize-TQELPMS5.js} +5 -5
  298. package/dist/{system-JBPJHNTG.js → system-2YOII5LZ.js} +3 -3
  299. package/dist/{telemetry-T4HQ6AKZ.js → telemetry-KMRZ3IJV.js} +10 -10
  300. package/dist/{templates-7O7NOIUC.js → templates-EEFY4FPS.js} +129 -37
  301. package/dist/{timeline-P2PLN53O.js → timeline-HSRGYZ3Q.js} +28 -27
  302. package/dist/{tokens-SPQN27VG.js → tokens-NYFORL53.js} +2 -2
  303. package/dist/{transcribe-YJQ3DDDI.js → transcribe-CNIQYQ52.js} +37 -35
  304. package/dist/{transcribe-SCZG6IM4.js → transcribe-GFFWRWK3.js} +17 -16
  305. package/dist/{tts-5OAB5XX6.js → tts-NPMDYSXP.js} +1 -1
  306. package/dist/{update-JYPZW35A.js → update-BDMPUNNA.js} +17 -16
  307. package/dist/{updateCheck-5M2JJTH3.js → updateCheck-43UZ2USJ.js} +4 -4
  308. package/dist/{upgrade-BP62FM6V.js → upgrade-Z5B57UWL.js} +7 -7
  309. package/dist/{urlDownloader-WOZQCE6P.js → urlDownloader-KDZ76BKM.js} +12 -11
  310. package/dist/{validate-NEC5QLH7.js → validate-UQKZNR5K.js} +35 -34
  311. package/dist/{video-XEEBISSO.js → video-VR4363OG.js} +15 -14
  312. package/dist/{voices-GCHA27JA.js → voices-GUWAM3TH.js} +31 -29
  313. package/dist/warmCheck.js +56 -53
  314. package/dist/warmCheckClient.js +2 -2
  315. package/package.json +2 -1
  316. package/dist/chunk-XGEJPKRY.js +0 -5069
@@ -9,7 +9,7 @@ import {
9
9
  mkdirOwnedWithinProject,
10
10
  pinProjectRecord,
11
11
  realFilePath
12
- } from "./chunk-ER22SVLT.js";
12
+ } from "./chunk-3GVHDPEP.js";
13
13
  import {
14
14
  atomicTempPath,
15
15
  cannotHardLink,
@@ -18,28 +18,33 @@ import {
18
18
  refuseReadOnly,
19
19
  renameWithRetryAsync,
20
20
  replaceFileAtomically
21
- } from "./chunk-KCF6Q54R.js";
21
+ } from "./chunk-PUTPYYE4.js";
22
22
  import {
23
- isSafePath
24
- } from "./chunk-KWTTELUY.js";
23
+ isSafePath,
24
+ realProjectRoot,
25
+ realpath
26
+ } from "./chunk-UVPLW55S.js";
27
+ import {
28
+ namesAnotherNetworkRoot
29
+ } from "./chunk-6EMFSRTW.js";
25
30
  import {
26
31
  hyperframesCacheDir
27
32
  } from "./chunk-JOQR4AP6.js";
28
33
 
29
- // ../studio-server/dist/chunk-Z5DBB25C.js
34
+ // ../studio-server/dist/chunk-LUUWFSIH.js
30
35
  import { randomUUID as randomUUID7 } from "crypto";
31
36
  import { mkdir as mkdir2, readdir as readdir4, rm as rm3, rmdir, stat as stat2, writeFile as writeFile2 } from "fs/promises";
32
37
  import {
33
- existsSync as existsSync3,
34
- lstatSync as lstatSync4,
38
+ existsSync as existsSync4,
39
+ lstatSync as lstatSync5,
35
40
  statSync as statSync5,
36
- mkdirSync as mkdirSync5,
41
+ mkdirSync as mkdirSync6,
37
42
  readdirSync as readdirSync4,
38
43
  readFileSync as readFileSync9,
39
44
  realpathSync,
40
- rmSync as rmSync3
45
+ rmSync as rmSync4
41
46
  } from "fs";
42
- import { dirname as dirname5, isAbsolute as isAbsolute5, join as join8, relative as relative5, resolve as resolve8, sep as sep5 } from "path";
47
+ import { basename as basename4, dirname as dirname6, isAbsolute as isAbsolute5, join as join9, relative as relative5, resolve as resolve8, sep as sep5 } from "path";
43
48
  import { createHash, randomUUID } from "crypto";
44
49
  import { readFileSync as readFileSync2 } from "fs";
45
50
  import { isAbsolute, relative, resolve, sep } from "path";
@@ -77,52 +82,55 @@ import {
77
82
  stat,
78
83
  writeFile
79
84
  } from "fs/promises";
80
- import { dirname, join as join2 } from "path";
85
+ import { basename as basename2, dirname as dirname2, join as join3 } from "path";
81
86
  import { pipeline } from "stream/promises";
82
87
  import { resolve as resolve3 } from "path";
88
+ import { lstatSync as lstatSync2, mkdirSync as mkdirSync2, renameSync, rmdirSync, rmSync as rmSync2 } from "fs";
89
+ import { basename, dirname, join as join2 } from "path";
83
90
  import { extname as extname2 } from "path";
84
91
  import { randomUUID as randomUUID5 } from "crypto";
85
- import { readdirSync as readdirSync2, renameSync, statSync as statSync3 } from "fs";
92
+ import { readdirSync as readdirSync2, renameSync as renameSync2, statSync as statSync3 } from "fs";
86
93
  import { lstat as lstat2, readdir as readdir3, rm as rm2 } from "fs/promises";
87
94
  import { tmpdir } from "os";
88
- import { dirname as dirname2, join as join4 } from "path";
95
+ import { dirname as dirname3, join as join5 } from "path";
89
96
  import { randomUUID as randomUUID4 } from "crypto";
90
- import { existsSync, mkdirSync as mkdirSync2, readFileSync as readFileSync4, statSync as statSync2, utimesSync } from "fs";
91
- import { basename, join as join3, resolve as resolve4 } from "path";
97
+ import { existsSync, mkdirSync as mkdirSync3, readFileSync as readFileSync4, statSync as statSync2, utimesSync } from "fs";
98
+ import { basename as basename3, join as join4, resolve as resolve4 } from "path";
92
99
  import { createHash as createHash5, randomUUID as randomUUID6 } from "crypto";
93
- import { createReadStream as createReadStream2, existsSync as existsSync2, readFileSync as readFileSync7, renameSync as renameSync2, statSync as statSync4 } from "fs";
94
- import { isAbsolute as isAbsolute4, join as join7, resolve as resolve7 } from "path";
100
+ import { createReadStream as createReadStream2, existsSync as existsSync3, readFileSync as readFileSync7, renameSync as renameSync3, statSync as statSync4 } from "fs";
101
+ import { isAbsolute as isAbsolute4, join as join8, resolve as resolve7 } from "path";
95
102
  import { createHash as createHash4 } from "crypto";
96
103
  import {
97
104
  closeSync as closeSync2,
98
105
  constants as constants3,
106
+ existsSync as existsSync2,
99
107
  fstatSync as fstatSync2,
100
- lstatSync as lstatSync2,
108
+ lstatSync as lstatSync3,
101
109
  openSync as openSync2,
102
110
  readFileSync as readFileSync5,
103
111
  unlinkSync
104
112
  } from "fs";
105
- import { isAbsolute as isAbsolute3, join as join5, relative as relative3, resolve as resolve5, sep as sep3 } from "path";
113
+ import { isAbsolute as isAbsolute3, join as join6, parse, relative as relative3, resolve as resolve5, sep as sep3 } from "path";
106
114
  import {
107
115
  closeSync as closeSync3,
108
116
  constants as constants4,
109
117
  fstatSync as fstatSync3,
110
- lstatSync as lstatSync3,
118
+ lstatSync as lstatSync4,
111
119
  openSync as openSync3,
112
- mkdirSync as mkdirSync3,
120
+ mkdirSync as mkdirSync4,
113
121
  readFileSync as readFileSync6,
114
122
  readdirSync as readdirSync3,
115
- rmSync as rmSync2,
123
+ rmSync as rmSync3,
116
124
  ftruncateSync,
117
125
  writeSync,
118
126
  writeFileSync as writeFileSync2
119
127
  } from "fs";
120
- import { dirname as dirname3, join as join6, relative as relative4, resolve as resolve6, sep as sep4 } from "path";
121
- import { closeSync as closeSync4, constants as constants5, mkdirSync as mkdirSync4, openSync as openSync4, readFileSync as readFileSync8, writeSync as writeSync2 } from "fs";
122
- import { dirname as dirname4 } from "path";
128
+ import { dirname as dirname4, join as join7, relative as relative4, resolve as resolve6, sep as sep4 } from "path";
129
+ import { closeSync as closeSync4, constants as constants5, mkdirSync as mkdirSync5, openSync as openSync4, readFileSync as readFileSync8, writeSync as writeSync2 } from "fs";
130
+ import { dirname as dirname5 } from "path";
123
131
  import { readdirSync as readdirSync5 } from "fs";
124
132
  import { rm as rm4, stat as stat3 } from "fs/promises";
125
- import { join as join9 } from "path";
133
+ import { join as join10 } from "path";
126
134
  var RECEIPT_TTL_MS = 1e4;
127
135
  var receipts = /* @__PURE__ */ new Map();
128
136
  var overwriteListeners = /* @__PURE__ */ new Set();
@@ -716,6 +724,86 @@ async function stopServingAndClose(path) {
716
724
  )
717
725
  );
718
726
  }
727
+ var DRIVE = /^[a-z]:/i;
728
+ function withoutTrailingDotsAndSpaces(name) {
729
+ let end = name.length;
730
+ while (end > 0 && (name[end - 1] === "." || name[end - 1] === " ")) end -= 1;
731
+ return name.slice(0, end);
732
+ }
733
+ var isPlainName = (name) => withoutTrailingDotsAndSpaces(name) !== "" && !DRIVE.test(name) && !(process.platform === "win32" && name.includes(":"));
734
+ function isRelativeProjectPath(path) {
735
+ return !path.includes("\\") && path.split("/").every(isPlainName);
736
+ }
737
+ var inTheWay = (at) => new Error(`${at} is in the way; move or delete it, then try again.`);
738
+ var changedWhileWriting = (folder) => new Error(`${folder} changed while history was writing to it, so it stopped.`);
739
+ function folderWithin(root, path, make) {
740
+ if (!isRelativeProjectPath(path)) throw new Error(`${path} is not a path inside the project.`);
741
+ let folder = realProjectRoot(root);
742
+ const names = path.split("/").slice(0, -1);
743
+ for (const [depth, name] of names.entries()) {
744
+ const next = join2(folder, name);
745
+ let made = false;
746
+ if (!lstatSync2(next, { throwIfNoEntry: false })) {
747
+ if (!make) return null;
748
+ made = makeFolder(next);
749
+ }
750
+ const real = lstatSync2(next, { throwIfNoEntry: false })?.isDirectory() ? realpath(next) : void 0;
751
+ if (real === void 0 || dirname(real) !== folder) {
752
+ if (made) rmdirSync(next);
753
+ throw inTheWay(names.slice(0, depth + 1).join("/"));
754
+ }
755
+ folder = real;
756
+ }
757
+ return folder;
758
+ }
759
+ function makeFolder(path) {
760
+ try {
761
+ mkdirSync2(path);
762
+ return true;
763
+ } catch (error) {
764
+ if (error.code !== "EEXIST") throw error;
765
+ return false;
766
+ }
767
+ }
768
+ function assertStillWithin(folder) {
769
+ let real;
770
+ try {
771
+ real = realpath(folder);
772
+ } catch {
773
+ real = void 0;
774
+ }
775
+ if (real !== folder) throw changedWhileWriting(folder);
776
+ }
777
+ function assertLandedIn(folder, path) {
778
+ assertStillWithin(folder);
779
+ if (dirname(path) !== folder || !lstatSync2(path, { throwIfNoEntry: false })?.isFile())
780
+ throw changedWhileWriting(folder);
781
+ }
782
+ async function removeWithin(folder, path, keep) {
783
+ const at = join2(folder, basename(path));
784
+ const standing = lstatSync2(at, { throwIfNoEntry: false });
785
+ if (!standing) return;
786
+ if (standing.isDirectory()) throw inTheWay(path);
787
+ const aside = atomicTempPath(at);
788
+ assertStillWithin(folder);
789
+ try {
790
+ renameSync(at, aside);
791
+ } catch (error) {
792
+ if (error.code === "ENOENT") return;
793
+ throw error;
794
+ }
795
+ try {
796
+ assertLandedIn(folder, aside);
797
+ await keep?.(aside);
798
+ } catch (error) {
799
+ try {
800
+ renameSync(aside, at);
801
+ } catch {
802
+ }
803
+ throw error;
804
+ }
805
+ rmSync2(aside, { force: true });
806
+ }
719
807
  var BLOB_HASH = /^[0-9a-f]{64}$/;
720
808
  var READ_ONCE_AT_MOST_BYTES = 64 * 1024;
721
809
  var READS_BEFORE_LEAVING_IT = 3;
@@ -724,9 +812,16 @@ var isSettling = (file, now) => Math.abs(now - Math.max(file.mtimeMs, file.ctime
724
812
  var unchanged = (before, after) => before.size === after.size && before.mtimeMs === after.mtimeMs && before.ctimeMs === after.ctimeMs;
725
813
  function blobPath(dir, hash) {
726
814
  if (!BLOB_HASH.test(hash)) throw new Error("That is not a history blob.");
727
- return join2(dir, hash.slice(0, 2), hash);
815
+ return join3(dir, hash.slice(0, 2), hash);
728
816
  }
729
- var readBlob = (dir, hash) => readFile2(blobPath(dir, hash));
817
+ var sha256 = (bytes) => createHash3("sha256").update(bytes).digest("hex");
818
+ var damaged = () => new Error("History's copy of this version is damaged, so it was not used. Nothing was changed.");
819
+ async function readChecked(path, hash) {
820
+ const bytes = await readFile2(path);
821
+ if (sha256(bytes) !== hash) throw damaged();
822
+ return bytes;
823
+ }
824
+ var readBlob = (dir, hash) => readChecked(blobPath(dir, hash), hash);
730
825
  async function hashFile(path) {
731
826
  const hash = createHash3("sha256");
732
827
  for await (const chunk of createReadStream(path)) hash.update(chunk);
@@ -756,31 +851,37 @@ function onRestoredInPlace(listener) {
756
851
  inPlaceListeners.add(listener);
757
852
  return () => inPlaceListeners.delete(listener);
758
853
  }
759
- async function cloneOrCopy(from, to, hash, beforeReplace) {
854
+ async function cloneOrCopy(from, hash, root, path, beforeReplace) {
855
+ const folder = folderWithin(root, path, true);
856
+ const to = join3(folder, basename2(path));
857
+ const servedAs = join3(root, path);
760
858
  refuseReadOnly(to);
761
- await mkdir(dirname(to), { recursive: true });
762
859
  const temp = atomicTempPath(to);
763
860
  try {
764
- await copyFile(from, temp, constants2.COPYFILE_FICLONE);
765
- await stopServingAndClose(to);
861
+ await copyFile(from, temp, constants2.COPYFILE_FICLONE | constants2.COPYFILE_EXCL);
862
+ assertLandedIn(folder, temp);
863
+ if (await hashFile(temp) !== hash) throw damaged();
864
+ await stopServingAndClose(servedAs);
766
865
  try {
767
866
  await renameWithRetryAsync(temp, to, {
768
867
  rename: async (from2, to2) => {
769
868
  beforeReplace?.();
869
+ assertStillWithin(folder);
770
870
  await rename(from2, to2);
771
871
  }
772
872
  });
773
873
  } catch (error) {
774
874
  if (!isWindowsHold(error)) throw error;
775
- await writeInPlace(temp, to, hash);
875
+ await writeInPlace(temp, folder, to, servedAs, hash);
776
876
  }
777
877
  } finally {
778
878
  await rm(temp, { force: true });
779
879
  }
780
880
  }
781
- async function writeInPlace(temp, to, hash) {
881
+ async function writeInPlace(temp, folder, to, servedAs, hash) {
782
882
  let outcome = "failed";
783
883
  try {
884
+ assertLandedIn(folder, to);
784
885
  await copyFile(temp, to);
785
886
  const handle = await open(to, "r+");
786
887
  try {
@@ -790,7 +891,7 @@ async function writeInPlace(temp, to, hash) {
790
891
  }
791
892
  outcome = await hashFile(to) === hash ? "restored" : "mismatch";
792
893
  } finally {
793
- for (const listener of inPlaceListeners) listener(to, outcome);
894
+ for (const listener of inPlaceListeners) listener(servedAs, outcome);
794
895
  }
795
896
  if (outcome === "mismatch")
796
897
  throw new Error("The file was written in place, but it does not match the copy history kept.");
@@ -801,7 +902,7 @@ var listDir = (path) => readdir2(path, { withFileTypes: true }).catch((error) =>
801
902
  });
802
903
  async function openBlobStore(dir) {
803
904
  const sizes = /* @__PURE__ */ new Map();
804
- const asideDir = join2(dirname(dir), "aside");
905
+ const asideDir = join3(dirname2(dir), "aside");
805
906
  const asideSizes = /* @__PURE__ */ new Map();
806
907
  const holds = /* @__PURE__ */ new Map();
807
908
  await mkdir(dir, { recursive: true });
@@ -811,11 +912,11 @@ async function openBlobStore(dir) {
811
912
  ])
812
913
  for (const shard of await listDir(root)) {
813
914
  if (!shard.isDirectory()) {
814
- if (shard.name.startsWith("incoming-")) await rm(join2(root, shard.name), { force: true });
915
+ if (shard.name.startsWith("incoming-")) await rm(join3(root, shard.name), { force: true });
815
916
  continue;
816
917
  }
817
- for (const hash of await listDir(join2(root, shard.name)))
818
- found.set(hash.name, (await stat(join2(root, shard.name, hash.name))).size);
918
+ for (const hash of await listDir(join3(root, shard.name)))
919
+ found.set(hash.name, (await stat(join3(root, shard.name, hash.name))).size);
819
920
  }
820
921
  for (const hash of asideSizes.keys()) holds.set(hash, /* @__PURE__ */ new Set(["*"]));
821
922
  const pathOf = (hash) => blobPath(sizes.has(hash) ? dir : asideDir, hash);
@@ -840,14 +941,14 @@ async function openBlobStore(dir) {
840
941
  await write();
841
942
  });
842
943
  const putBytes = async (bytes, mode) => {
843
- const hash = createHash3("sha256").update(bytes).digest("hex");
944
+ const hash = sha256(bytes);
844
945
  if (sizes.has(hash)) return hash;
845
- const temp = join2(dir, `incoming-${randomUUID3()}`);
946
+ const temp = join3(dir, `incoming-${randomUUID3()}`);
846
947
  try {
847
948
  await withFolderMadeIfMissing(dir, () => writeFile(temp, bytes, { mode }));
848
949
  await chmod(temp, mode & 4095);
849
950
  const to = blobPath(dir, hash);
850
- await withFolderMadeIfMissing(dirname(to), () => renameWithRetryAsync(temp, to));
951
+ await withFolderMadeIfMissing(dirname2(to), () => renameWithRetryAsync(temp, to));
851
952
  } catch (error) {
852
953
  await rm(temp, { force: true });
853
954
  throw error;
@@ -858,7 +959,7 @@ async function openBlobStore(dir) {
858
959
  const putIfUnchanged = async (absPath) => {
859
960
  const small = await readIfSmall(absPath);
860
961
  if (small) return small.moved ? null : putBytes(small.bytes, small.mode);
861
- const temp = join2(dir, `incoming-${randomUUID3()}`);
962
+ const temp = join3(dir, `incoming-${randomUUID3()}`);
862
963
  await mkdir(dir, { recursive: true });
863
964
  const before = await stat(absPath);
864
965
  const moved = await cloneOrStream(absPath, temp).then(async () => !unchanged(before, await stat(absPath))).catch(async (error) => {
@@ -874,7 +975,7 @@ async function openBlobStore(dir) {
874
975
  await rm(temp, { force: true });
875
976
  return hash;
876
977
  }
877
- await mkdir(dirname(blobPath(dir, hash)), { recursive: true });
978
+ await mkdir(dirname2(blobPath(dir, hash)), { recursive: true });
878
979
  const size = (await stat(temp)).size;
879
980
  await renameWithRetryAsync(temp, blobPath(dir, hash));
880
981
  file(hash, size);
@@ -890,8 +991,8 @@ async function openBlobStore(dir) {
890
991
  },
891
992
  reference: (absPath) => hashFile(absPath),
892
993
  has: (hash) => sizes.has(hash) || asideSizes.has(hash),
893
- read: (hash) => readFile2(pathOf(hash)),
894
- writeTo: async (hash, absPath, beforeReplace) => cloneOrCopy(pathOf(hash), absPath, hash, beforeReplace),
994
+ read: (hash) => readChecked(pathOf(hash), hash),
995
+ writeTo: async (hash, root, path, beforeReplace) => cloneOrCopy(pathOf(hash), hash, root, path, beforeReplace),
895
996
  async release(held) {
896
997
  for (const [hash, path] of held) {
897
998
  holds.get(hash)?.delete(path);
@@ -906,13 +1007,13 @@ async function openBlobStore(dir) {
906
1007
  return;
907
1008
  }
908
1009
  const to = blobPath(asideDir, hash);
909
- await mkdir(dirname(to), { recursive: true });
1010
+ await mkdir(dirname2(to), { recursive: true });
910
1011
  const moved = remove && await renameWithRetryAsync(absPath, to).then(
911
1012
  () => true,
912
1013
  () => false
913
1014
  );
914
1015
  if (!moved) {
915
- const temp = join2(asideDir, `incoming-${randomUUID3()}`);
1016
+ const temp = join3(asideDir, `incoming-${randomUUID3()}`);
916
1017
  await cloneOrStream(absPath, temp).catch(async (error) => {
917
1018
  await rm(temp, { force: true });
918
1019
  throw error;
@@ -967,12 +1068,12 @@ function uncopiedOnlyHashes(log, sizeOf) {
967
1068
  }
968
1069
  return [...uncopied].filter((hash) => !copied.has(hash));
969
1070
  }
970
- var ID_PATH = join3(".hyperframes", "history-id");
1071
+ var ID_PATH = join4(".hyperframes", "history-id");
971
1072
  var ID_SHAPE = /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/;
972
1073
  var isHistoryId = (name) => ID_SHAPE.test(name);
973
1074
  function readId(projectDir) {
974
1075
  try {
975
- const id = readFileSync4(join3(projectDir, ID_PATH), "utf-8").trim();
1076
+ const id = readFileSync4(join4(projectDir, ID_PATH), "utf-8").trim();
976
1077
  return ID_SHAPE.test(id) ? id : null;
977
1078
  } catch {
978
1079
  return null;
@@ -985,11 +1086,11 @@ function isRecordedFolder(historyDir, folder) {
985
1086
  return sameFolder({ ino: was.ino, birthtimeMs: was.born ?? NaN }, folder);
986
1087
  const unreadableSo0878KeptTheId = typeof was?.dir !== "string";
987
1088
  if (unreadableSo0878KeptTheId) return true;
988
- return !isCopyOf0878Folder(was.dir, basename(historyDir), folder);
1089
+ return !isCopyOf0878Folder(was.dir, basename3(historyDir), folder);
989
1090
  }
990
1091
  function readRecord(historyDir) {
991
1092
  try {
992
- return JSON.parse(readFileSync4(join3(historyDir, "project.json"), "utf-8"));
1093
+ return JSON.parse(readFileSync4(join4(historyDir, "project.json"), "utf-8"));
993
1094
  } catch {
994
1095
  return null;
995
1096
  }
@@ -1007,17 +1108,17 @@ function projectHistoryId(projectDir, historyRoot) {
1007
1108
  const dir = resolve4(projectDir);
1008
1109
  const folder = statSync2(dir);
1009
1110
  let id = readId(dir);
1010
- if (!id && existsSync(join3(dir, ID_PATH)))
1111
+ if (!id && existsSync(join4(dir, ID_PATH)))
1011
1112
  throw new HistoryIdError(
1012
- `${join3(dir, ID_PATH)} holds no history id this version can read; move it aside to start anew.`
1113
+ `${join4(dir, ID_PATH)} holds no history id this version can read; move it aside to start anew.`
1013
1114
  );
1014
- if (!id || existsSync(join3(historyRoot, id)) && !isRecordedFolder(join3(historyRoot, id), folder)) {
1115
+ if (!id || existsSync(join4(historyRoot, id)) && !isRecordedFolder(join4(historyRoot, id), folder)) {
1015
1116
  id = randomUUID4();
1016
- mkdirOwnedWithinProject(dir, join3(dir, ".hyperframes"));
1017
- replaceFileAtomically(join3(dir, ID_PATH), `${id}
1117
+ mkdirOwnedWithinProject(dir, join4(dir, ".hyperframes"));
1118
+ replaceFileAtomically(join4(dir, ID_PATH), `${id}
1018
1119
  `);
1019
1120
  }
1020
- recordProject(join3(historyRoot, id), dir, folder);
1121
+ recordProject(join4(historyRoot, id), dir, folder);
1021
1122
  return id;
1022
1123
  }
1023
1124
  var HistoryIdError = class extends Error {
@@ -1029,7 +1130,7 @@ var HistoryIdError = class extends Error {
1029
1130
  function markUsed(historyDir) {
1030
1131
  const now = /* @__PURE__ */ new Date();
1031
1132
  try {
1032
- utimesSync(join3(historyDir, "project.json"), now, now);
1133
+ utimesSync(join4(historyDir, "project.json"), now, now);
1033
1134
  } catch {
1034
1135
  return;
1035
1136
  }
@@ -1041,8 +1142,8 @@ function recordProject(historyDir, dir, folder) {
1041
1142
  markUsed(historyDir);
1042
1143
  return;
1043
1144
  }
1044
- mkdirSync2(historyDir, { recursive: true });
1045
- replaceFileAtomically(join3(historyDir, "project.json"), JSON.stringify(record), 420);
1145
+ mkdirSync3(historyDir, { recursive: true });
1146
+ replaceFileAtomically(join4(historyDir, "project.json"), JSON.stringify(record), 420);
1046
1147
  }
1047
1148
  var DAY_MS = 24 * 60 * 60 * 1e3;
1048
1149
  var KEEP_GONE_PROJECT_HISTORY_MS = 14 * DAY_MS;
@@ -1050,7 +1151,7 @@ var PRUNED_PREFIX = ".pruned-";
1050
1151
  var LAST_PRUNE_FILE = ".last-prune";
1051
1152
  function listProjectHistories(historyRoot) {
1052
1153
  return namesIn(historyRoot).filter(isHistoryId).flatMap((id) => {
1053
- const home = join4(historyRoot, id);
1154
+ const home = join5(historyRoot, id);
1054
1155
  const projectDir = readRecord(home)?.dir;
1055
1156
  if (typeof projectDir !== "string" || readId(projectDir) !== id) return [];
1056
1157
  return [{ id, projectDir, lastUsedMs: lastUsed(home) }];
@@ -1091,13 +1192,13 @@ async function pruneWithin(historyRoot, {
1091
1192
  }
1092
1193
  async function pruneEntry(historyRoot, name, run) {
1093
1194
  if (name.startsWith(PRUNED_PREFIX)) {
1094
- if (!run.dryRun) await rm2(join4(historyRoot, name), { recursive: true, force: true });
1195
+ if (!run.dryRun) await rm2(join5(historyRoot, name), { recursive: true, force: true });
1095
1196
  return null;
1096
1197
  }
1097
1198
  return isHistoryId(name) ? pruneOne(historyRoot, name, run) : null;
1098
1199
  }
1099
1200
  async function pruneOne(historyRoot, id, run) {
1100
- const home = join4(historyRoot, id);
1201
+ const home = join5(historyRoot, id);
1101
1202
  if (abandonedProject(home, id, run.now, run.tempDir) === null) return null;
1102
1203
  const release = await takeUnlessBusy(home);
1103
1204
  if (!release) return null;
@@ -1127,12 +1228,12 @@ async function takeUnlessBusy(home) {
1127
1228
  }
1128
1229
  }
1129
1230
  function recheckAndMoveAway(historyRoot, id, { now, dryRun, tempDir }) {
1130
- const home = join4(historyRoot, id);
1231
+ const home = join5(historyRoot, id);
1131
1232
  const projectDir = abandonedProject(home, id, now, tempDir);
1132
1233
  if (projectDir === null) return null;
1133
1234
  if (dryRun) return { projectDir, trash: null };
1134
- const trash = join4(historyRoot, `${PRUNED_PREFIX}${id}-${randomUUID5()}`);
1135
- renameSync(home, trash);
1235
+ const trash = join5(historyRoot, `${PRUNED_PREFIX}${id}-${randomUUID5()}`);
1236
+ renameSync2(home, trash);
1136
1237
  return { projectDir, trash };
1137
1238
  }
1138
1239
  function abandonedProject(home, id, now, tempDir) {
@@ -1143,7 +1244,7 @@ function abandonedProject(home, id, now, tempDir) {
1143
1244
  return projectGone(dir, id, record?.dev, tempDir) ? dir : null;
1144
1245
  }
1145
1246
  function projectGone(dir, id, dev, tempDir) {
1146
- if (!statSync3(join4(dir, ID_PATH), { throwIfNoEntry: false }))
1247
+ if (!statSync3(join5(dir, ID_PATH), { throwIfNoEntry: false }))
1147
1248
  return diskStillHere(dir, dev, tempDir);
1148
1249
  const there = readId(dir);
1149
1250
  return there !== null && there !== id;
@@ -1152,21 +1253,21 @@ function diskStillHere(dir, dev, tempDir) {
1152
1253
  let at = dir;
1153
1254
  let stat4 = statSync3(at, { throwIfNoEntry: false });
1154
1255
  while (!stat4) {
1155
- if (dirname2(at) === at) return false;
1156
- at = dirname2(at);
1256
+ if (dirname3(at) === at) return false;
1257
+ at = dirname3(at);
1157
1258
  stat4 = statSync3(at, { throwIfNoEntry: false });
1158
1259
  }
1159
1260
  if (typeof dev === "number") return stat4.dev === dev;
1160
1261
  return at === dir || isSafePath(tempDir, at);
1161
1262
  }
1162
1263
  function lastUsed(home) {
1163
- const mtime = (file) => statSync3(join4(home, file), { throwIfNoEntry: false })?.mtimeMs ?? 0;
1264
+ const mtime = (file) => statSync3(join5(home, file), { throwIfNoEntry: false })?.mtimeMs ?? 0;
1164
1265
  return Math.max(mtime("project.json"), mtime("log.jsonl"));
1165
1266
  }
1166
1267
  async function bytesIn(dir) {
1167
1268
  let total = 0;
1168
1269
  for (const entry of await readdir3(dir, { withFileTypes: true })) {
1169
- const path = join4(dir, entry.name);
1270
+ const path = join5(dir, entry.name);
1170
1271
  total += entry.isDirectory() ? await bytesIn(path) : (await lstat2(path)).size;
1171
1272
  }
1172
1273
  return total;
@@ -1181,7 +1282,7 @@ function prunedWithinADay(stamp, now) {
1181
1282
  }
1182
1283
  var pruning = /* @__PURE__ */ new Set();
1183
1284
  function pruneGoneProjectHistoriesDaily(historyRoot, now, { onError, budgetMs } = {}) {
1184
- const stamp = join4(historyRoot, LAST_PRUNE_FILE);
1285
+ const stamp = join5(historyRoot, LAST_PRUNE_FILE);
1185
1286
  if (pruning.has(historyRoot) || prunedWithinADay(stamp, now)) return;
1186
1287
  pruning.add(historyRoot);
1187
1288
  setImmediate(() => {
@@ -1194,10 +1295,22 @@ var records = (state, kind) => [
1194
1295
  ...state[kind].unversioned
1195
1296
  ];
1196
1297
  var protectedRevisions = (state) => /* @__PURE__ */ new Set([state.currentRevision, ...state.renders?.retainedRevisions ?? []]);
1298
+ var canonicalUnlessOnAnotherShare = (projectDir, path) => namesAnotherNetworkRoot(projectDir, path) ? resolve5(path) : realFilePath(path);
1299
+ var recordedFileGone = (projectDir, path) => namesAnotherNetworkRoot(projectDir, path) || !existsSync2(path);
1300
+ function spelledInsideArtifactsFolder(projectDir, path, kind) {
1301
+ if (!isAbsolute3(path) || namesAnotherNetworkRoot(projectDir, path)) return false;
1302
+ if (parse(resolve5(path)).root.toLowerCase() !== parse(resolve5(projectDir)).root.toLowerCase())
1303
+ return false;
1304
+ const parts = resolve5(path).split(sep3).map((part) => part.toLowerCase());
1305
+ return parts.some(
1306
+ (part, i) => part === ".hyperframes" && parts[i + 1] === "artifacts" && parts[i + 2] === kind && i + 3 < parts.length
1307
+ );
1308
+ }
1197
1309
  function managedPath(projectDir, path, kind) {
1310
+ if (!spelledInsideArtifactsFolder(projectDir, path, kind)) return false;
1198
1311
  const canonicalProject = realFilePath(resolve5(projectDir));
1199
1312
  const canonicalPath = realFilePath(path);
1200
- const root = join5(canonicalProject, ".hyperframes", "artifacts", kind);
1313
+ const root = join6(canonicalProject, ".hyperframes", "artifacts", kind);
1201
1314
  const rel = relative3(root, canonicalPath);
1202
1315
  return isAbsolute3(path) && rel !== "" && rel !== ".." && !rel.startsWith(`..${sep3}`) && !isAbsolute3(rel) && pinProjectRecord(canonicalProject, relative3(canonicalProject, canonicalPath)) === canonicalPath;
1203
1316
  }
@@ -1222,7 +1335,7 @@ function planArtifactCleanup(projectDir, state, render) {
1222
1335
  const path = record.image ?? record.report;
1223
1336
  if (!path || record.status === "cleaned") continue;
1224
1337
  if (removable(record, path, kind)) candidates.push({ kind, record, path });
1225
- else keepPaths.add(realFilePath(path));
1338
+ else keepPaths.add(canonicalUnlessOnAnotherShare(projectDir, path));
1226
1339
  }
1227
1340
  }
1228
1341
  for (const { kind, record, path } of candidates) {
@@ -1261,7 +1374,7 @@ function stillPendingAfterUnlink(item) {
1261
1374
  if (!stat4.isFile() || stat4.isSymbolicLink()) return false;
1262
1375
  const hash = createHash4("sha256").update(readFileSync5(descriptor)).digest("hex");
1263
1376
  if (hash !== item.hash) return false;
1264
- const current = lstatSync2(item.path);
1377
+ const current = lstatSync3(item.path);
1265
1378
  if (current.dev !== stat4.dev || current.ino !== stat4.ino) return false;
1266
1379
  unlinkSync(item.path);
1267
1380
  return false;
@@ -1275,7 +1388,7 @@ function finishArtifactCleanup(projectDir, state) {
1275
1388
  const protectedIds = protectedRevisions(state);
1276
1389
  const referenced = new Set(
1277
1390
  kinds.flatMap(
1278
- (kind) => records(state, kind).flatMap((record) => record.image ?? record.report ?? []).map(realFilePath)
1391
+ (kind) => records(state, kind).flatMap((record) => record.image ?? record.report ?? []).map((path) => canonicalUnlessOnAnotherShare(projectDir, path))
1279
1392
  )
1280
1393
  );
1281
1394
  state.pendingArtifactCleanup = (state.pendingArtifactCleanup ?? []).filter((item) => {
@@ -1296,16 +1409,16 @@ var SNAPSHOT_GRACE_MS = 24 * 60 * 60 * 1e3;
1296
1409
  var OWNER = ".capture-owner.json";
1297
1410
  var ownedMarkers = /* @__PURE__ */ new Map();
1298
1411
  var UUID = /^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/i;
1299
- var rootOf = (project) => join6(resolve6(project), ".hyperframes", "artifacts", "snapshots");
1412
+ var rootOf = (project) => join7(resolve6(project), ".hyperframes", "artifacts", "snapshots");
1300
1413
  function ordinaryPath(project, path) {
1301
1414
  const root = resolve6(project);
1302
1415
  const rel = relative4(root, path);
1303
1416
  if (rel === ".." || rel.startsWith(`..${sep4}`)) return false;
1304
1417
  let current = root;
1305
1418
  for (const part of rel.split(sep4).filter(Boolean)) {
1306
- current = join6(current, part);
1419
+ current = join7(current, part);
1307
1420
  try {
1308
- if (lstatSync3(current).isSymbolicLink()) return false;
1421
+ if (lstatSync4(current).isSymbolicLink()) return false;
1309
1422
  } catch {
1310
1423
  return false;
1311
1424
  }
@@ -1315,9 +1428,9 @@ function ordinaryPath(project, path) {
1315
1428
  function createSnapshotParents(project, path) {
1316
1429
  let parent = resolve6(project);
1317
1430
  for (const part of relative4(parent, path).split(sep4).filter(Boolean)) {
1318
- parent = join6(parent, part);
1431
+ parent = join7(parent, part);
1319
1432
  try {
1320
- mkdirSync3(parent);
1433
+ mkdirSync4(parent);
1321
1434
  } catch (error) {
1322
1435
  if (!(error instanceof Error && "code" in error && error.code === "EEXIST")) throw error;
1323
1436
  }
@@ -1326,10 +1439,10 @@ function createSnapshotParents(project, path) {
1326
1439
  }
1327
1440
  function ownSnapshotRun(project, path) {
1328
1441
  const root = rootOf(project);
1329
- if (dirname3(path) !== root || !UUID.test(path.slice(root.length + 1))) return;
1442
+ if (dirname4(path) !== root || !UUID.test(path.slice(root.length + 1))) return;
1330
1443
  createSnapshotParents(project, root);
1331
- mkdirSync3(path);
1332
- const marker = join6(path, OWNER);
1444
+ mkdirSync4(path);
1445
+ const marker = join7(path, OWNER);
1333
1446
  const fd = openSync3(marker, "wx");
1334
1447
  try {
1335
1448
  writeFileSync2(fd, JSON.stringify({ version: 1, pid: process.pid }));
@@ -1343,7 +1456,7 @@ function missingFile(error) {
1343
1456
  }
1344
1457
  function retainedOutput(path) {
1345
1458
  try {
1346
- lstatSync3(join6(path, ".user-output"));
1459
+ lstatSync4(join7(path, ".user-output"));
1347
1460
  return true;
1348
1461
  } catch (error) {
1349
1462
  return !missingFile(error);
@@ -1372,7 +1485,7 @@ function openOwner(marker, access) {
1372
1485
  const fd = openSync3(marker, access | (constants4.O_NOFOLLOW ?? 0) | (constants4.O_NONBLOCK ?? 0));
1373
1486
  try {
1374
1487
  const current = fstatSync3(fd);
1375
- const named = lstatSync3(marker);
1488
+ const named = lstatSync4(marker);
1376
1489
  if (!ordinaryOwner(current) || !ordinaryOwner(named) || !sameOwnerFile(named, current))
1377
1490
  throw new Error("Snapshot owner changed while opening.");
1378
1491
  return fd;
@@ -1395,7 +1508,7 @@ function releasedOwner(owner) {
1395
1508
  function liveOwner(path) {
1396
1509
  if (retainedOutput(path)) return true;
1397
1510
  try {
1398
- const marker = join6(path, OWNER);
1511
+ const marker = join7(path, OWNER);
1399
1512
  const owner = readOwner(marker);
1400
1513
  if (releasedOwner(owner)) return false;
1401
1514
  const pid = ownerPid(owner);
@@ -1410,7 +1523,7 @@ function recordsOf(state) {
1410
1523
  function containingRun(root, path) {
1411
1524
  if (!path) return null;
1412
1525
  const name = relative4(root, resolve6(path)).split(sep4)[0];
1413
- return name && UUID.test(name) ? join6(root, name) : null;
1526
+ return name && UUID.test(name) ? join7(root, name) : null;
1414
1527
  }
1415
1528
  function keepContainingRun(keep, root, path) {
1416
1529
  const run = containingRun(root, path);
@@ -1435,9 +1548,9 @@ function runsOnDisk(root) {
1435
1548
  return [];
1436
1549
  }
1437
1550
  return entries.filter((entry) => entry.isDirectory() && UUID.test(entry.name)).flatMap((entry) => {
1438
- const path = join6(root, entry.name);
1551
+ const path = join7(root, entry.name);
1439
1552
  try {
1440
- const stat4 = lstatSync3(path);
1553
+ const stat4 = lstatSync4(path);
1441
1554
  return [{ path, stat: stat4 }];
1442
1555
  } catch {
1443
1556
  return [];
@@ -1473,24 +1586,24 @@ function retireReferences(records2, root, path) {
1473
1586
  }
1474
1587
  function unchangedRun(project, run) {
1475
1588
  if (!ordinaryPath(project, run.path)) return false;
1476
- const current = lstatSync3(run.path);
1589
+ const current = lstatSync4(run.path);
1477
1590
  return current.isDirectory() && current.dev === run.dev && current.ino === run.ino && current.mtimeMs === run.mtimeMs;
1478
1591
  }
1479
1592
  function finishSnapshotCleanup(project, runs) {
1480
1593
  for (const run of runs) {
1481
1594
  try {
1482
1595
  if (!unchangedRun(project, run) || liveOwner(run.path)) continue;
1483
- rmSync2(run.path, { recursive: true });
1596
+ rmSync3(run.path, { recursive: true });
1484
1597
  } catch {
1485
1598
  }
1486
1599
  }
1487
1600
  }
1488
1601
  function releaseSnapshotRun(project, path) {
1489
- const marker = join6(path, OWNER);
1602
+ const marker = join7(path, OWNER);
1490
1603
  const expected = ownedMarkers.get(marker);
1491
1604
  if (!expected) return;
1492
1605
  try {
1493
- if (dirname3(path) !== rootOf(project) || !ordinaryPath(project, path)) return;
1606
+ if (dirname4(path) !== rootOf(project) || !ordinaryPath(project, path)) return;
1494
1607
  const fd = openOwner(marker, constants4.O_RDWR);
1495
1608
  try {
1496
1609
  if (!sameOwnerFile(expected, fstatSync3(fd))) return;
@@ -1513,7 +1626,7 @@ function retainSnapshotOutput(project, path) {
1513
1626
  createSnapshotParents(project, resolve6(path));
1514
1627
  try {
1515
1628
  writeFileSync2(
1516
- join6(run, ".user-output"),
1629
+ join7(run, ".user-output"),
1517
1630
  "Explicit --output; retained until manual cleanup.\n",
1518
1631
  { flag: "wx" }
1519
1632
  );
@@ -1538,7 +1651,7 @@ var emptyState = () => ({
1538
1651
  snapshots: collection()
1539
1652
  });
1540
1653
  function readState(dir) {
1541
- if (!existsSync2(statePath(dir))) return emptyState();
1654
+ if (!existsSync3(statePath(dir))) return emptyState();
1542
1655
  const state = JSON.parse(readFileSync7(statePath(dir), "utf8"));
1543
1656
  if (state.version !== 1 || !state.checks || !state.snapshots || !state.revisions || !state.files)
1544
1657
  throw new Error("Unsupported video-state schema.");
@@ -1554,7 +1667,7 @@ async function updateState(dir, update) {
1554
1667
  state = readState(dir);
1555
1668
  } catch (error) {
1556
1669
  if (!(error instanceof SyntaxError)) throw error;
1557
- renameSync2(statePath(dir), `${statePath(dir)}.invalid-${randomUUID6()}`);
1670
+ renameSync3(statePath(dir), `${statePath(dir)}.invalid-${randomUUID6()}`);
1558
1671
  state = emptyState();
1559
1672
  }
1560
1673
  update(state);
@@ -1618,7 +1731,7 @@ async function fileHashes(dir) {
1618
1731
  (a, b) => a.path.localeCompare(b.path)
1619
1732
  )) {
1620
1733
  const hash = createHash5("sha256");
1621
- for await (const chunk of createReadStream2(join7(dir, path))) hash.update(chunk);
1734
+ for await (const chunk of createReadStream2(join8(dir, path))) hash.update(chunk);
1622
1735
  files[path] = hash.digest("hex");
1623
1736
  }
1624
1737
  return files;
@@ -1661,7 +1774,7 @@ async function recordArtifacts(projectDir, capture, artifactsToRecord) {
1661
1774
  attribution
1662
1775
  };
1663
1776
  const artifacts = kind === "check" ? state.checks : state.snapshots;
1664
- dropSupersededArtifacts(artifacts, artifact);
1777
+ dropSupersededArtifacts(projectDir, artifacts, artifact);
1665
1778
  const list = revision ? artifacts.revisions[revision] ??= [] : artifacts.unversioned;
1666
1779
  list.push(record);
1667
1780
  records2.push(record);
@@ -1679,17 +1792,17 @@ function attributionOf(unchanged2, revision) {
1679
1792
  if (!unchanged2) return "inputs-changed";
1680
1793
  return revision ? "recorded-revision" : "unversioned";
1681
1794
  }
1682
- function supersedes(artifact, previous) {
1683
- if (previous.status !== "cleaned" && !existsSync2(previous.image ?? previous.report ?? ""))
1684
- return true;
1795
+ function supersedes(projectDir, artifact, previous) {
1796
+ const path = previous.image ?? previous.report ?? "";
1797
+ if (previous.status !== "cleaned" && recordedFileGone(projectDir, path)) return true;
1685
1798
  if (previous.id === artifact.id) return true;
1686
1799
  if (artifact.image && previous.image === artifact.image) return true;
1687
1800
  return Boolean(artifact.report && previous.report === artifact.report);
1688
1801
  }
1689
- function dropSupersededArtifacts(artifacts, artifact) {
1802
+ function dropSupersededArtifacts(projectDir, artifacts, artifact) {
1690
1803
  for (const list of [...Object.values(artifacts.revisions), artifacts.unversioned]) {
1691
1804
  for (let i = list.length - 1; i >= 0; i--) {
1692
- if (supersedes(artifact, list[i])) list.splice(i, 1);
1805
+ if (supersedes(projectDir, artifact, list[i])) list.splice(i, 1);
1693
1806
  }
1694
1807
  }
1695
1808
  }
@@ -1717,7 +1830,7 @@ async function forgetRecordedArtifacts(projectDir, paths) {
1717
1830
  });
1718
1831
  }
1719
1832
  function artifactDirectory(projectDir, kind) {
1720
- const path = join7(resolve7(projectDir), ".hyperframes", "artifacts", kind, randomUUID6());
1833
+ const path = join8(resolve7(projectDir), ".hyperframes", "artifacts", kind, randomUUID6());
1721
1834
  if (kind === "snapshots") ownSnapshotRun(projectDir, path);
1722
1835
  return path;
1723
1836
  }
@@ -1819,7 +1932,7 @@ function writeLog(file, log) {
1819
1932
  ...log.entries.map((entry) => ({ type: "entry", entry })),
1820
1933
  ...[...log.pins].map((id) => ({ type: "pin", id, pinned: true }))
1821
1934
  ];
1822
- mkdirSync4(dirname4(file), { recursive: true });
1935
+ mkdirSync5(dirname5(file), { recursive: true });
1823
1936
  replaceFileAtomically(file, records2.map((r) => `${JSON.stringify(r)}
1824
1937
  `).join(""), 420);
1825
1938
  }
@@ -1915,10 +2028,11 @@ async function inFirstCopySlot(copy) {
1915
2028
  var MEDIA_LEDGER = ".media/manifest.jsonl";
1916
2029
  var KEPT_HIDDEN_PATHS = /* @__PURE__ */ new Set([...STUDIO_SIGNATURE_MANIFEST_PATHS, MEDIA_LEDGER]);
1917
2030
  function isHistoryPath(path) {
2031
+ if (!isRelativeProjectPath(path)) return false;
1918
2032
  if (KEPT_HIDDEN_PATHS.has(path)) return true;
1919
2033
  return !path.split("/").some((segment) => segment.startsWith("."));
1920
2034
  }
1921
- var logFileIn = (home) => join8(home, "log.jsonl");
2035
+ var logFileIn = (home) => join9(home, "log.jsonl");
1922
2036
  function listOf(log) {
1923
2037
  const undone = undoneIds(log.entries);
1924
2038
  return log.entries.map((entry) => ({
@@ -1958,20 +2072,21 @@ async function removeEmptyFolders(dir) {
1958
2072
  throw error;
1959
2073
  }
1960
2074
  for (const entry of entries)
1961
- if (entry.isDirectory()) await removeEmptyFolders(join8(dir, entry.name));
2075
+ if (entry.isDirectory()) await removeEmptyFolders(join9(dir, entry.name));
2076
+ assertStillWithin(dirname6(dir));
1962
2077
  await rmdir(dir);
1963
2078
  }
1964
2079
  function fileLeftIn(dir, at, deleted) {
1965
2080
  for (const entry of readdirSync4(dir, { withFileTypes: true })) {
1966
2081
  const path = `${at}/${entry.name}`;
1967
- const left = entry.isDirectory() ? fileLeftIn(join8(dir, entry.name), path, deleted) : deleted.has(path) ? void 0 : path;
2082
+ const left = entry.isDirectory() ? fileLeftIn(join9(dir, entry.name), path, deleted) : deleted.has(path) ? void 0 : path;
1968
2083
  if (left) return left;
1969
2084
  }
1970
2085
  return void 0;
1971
2086
  }
1972
2087
  function ignoresCase(dir) {
1973
- const self = statSync5(join8(dir, ID_PATH), { throwIfNoEntry: false });
1974
- const other = statSync5(join8(dir, ID_PATH.toUpperCase()), { throwIfNoEntry: false });
2088
+ const self = statSync5(join9(dir, ID_PATH), { throwIfNoEntry: false });
2089
+ const other = statSync5(join9(dir, ID_PATH.toUpperCase()), { throwIfNoEntry: false });
1975
2090
  return self !== void 0 && other?.ino === self.ino && other.dev === self.dev;
1976
2091
  }
1977
2092
  var blocks = (removed, added) => added.startsWith(`${removed}/`) || removed.startsWith(`${added}/`);
@@ -2024,7 +2139,7 @@ var Engine = class {
2024
2139
  this.projectId = projectId;
2025
2140
  this.blobs = blobs;
2026
2141
  this.dir = resolve8(options.projectDir);
2027
- this.home = join8(options.historyRoot, projectId);
2142
+ this.home = join9(options.historyRoot, projectId);
2028
2143
  this.foldsCase = ignoresCase(this.dir);
2029
2144
  const folder = statSync5(this.dir, { throwIfNoEntry: false });
2030
2145
  if (!folder || readId(this.dir) !== projectId || !isRecordedFolder(this.home, folder))
@@ -2110,7 +2225,7 @@ var Engine = class {
2110
2225
  this.owesVideoState = true;
2111
2226
  if (record) saveRecord(this.logFile, this.log, record);
2112
2227
  else writeLog(this.logFile, this.log);
2113
- if (!existsSync3(join8(this.home, "project.json")))
2228
+ if (!existsSync4(join9(this.home, "project.json")))
2114
2229
  recordProject(this.home, this.dir, this.folder);
2115
2230
  }
2116
2231
  replaced() {
@@ -2167,7 +2282,7 @@ var Engine = class {
2167
2282
  });
2168
2283
  }
2169
2284
  async storeBytes(bytes) {
2170
- const staged = join8(this.home, `overwrote-${randomUUID7()}`);
2285
+ const staged = join9(this.home, `overwrote-${randomUUID7()}`);
2171
2286
  await mkdir2(this.home, { recursive: true });
2172
2287
  await writeFile2(staged, bytes);
2173
2288
  try {
@@ -2233,9 +2348,9 @@ var Engine = class {
2233
2348
  this.saveAdopting();
2234
2349
  }
2235
2350
  saveAdopting() {
2236
- const file = join8(this.home, "adopting.json");
2237
- if (!this.adopting.size) return rmSync3(file, { force: true });
2238
- mkdirSync5(this.home, { recursive: true });
2351
+ const file = join9(this.home, "adopting.json");
2352
+ if (!this.adopting.size) return rmSync4(file, { force: true });
2353
+ mkdirSync6(this.home, { recursive: true });
2239
2354
  replaceFileAtomically(file, JSON.stringify([...this.adopting.keys()]), 420);
2240
2355
  }
2241
2356
  /** A file still changing stays named until a whole copy of it lands; the next open retries it. */
@@ -2309,7 +2424,7 @@ var Engine = class {
2309
2424
  }
2310
2425
  readStatCache() {
2311
2426
  try {
2312
- const files = JSON.parse(readFileSync9(join8(this.home, "stat.json"), "utf-8"));
2427
+ const files = JSON.parse(readFileSync9(join9(this.home, "stat.json"), "utf-8"));
2313
2428
  return new Map(Object.entries(files));
2314
2429
  } catch {
2315
2430
  return /* @__PURE__ */ new Map();
@@ -2318,7 +2433,7 @@ var Engine = class {
2318
2433
  readAdopting() {
2319
2434
  try {
2320
2435
  return new Set(
2321
- JSON.parse(readFileSync9(join8(this.home, "adopting.json"), "utf-8"))
2436
+ JSON.parse(readFileSync9(join9(this.home, "adopting.json"), "utf-8"))
2322
2437
  );
2323
2438
  } catch {
2324
2439
  return /* @__PURE__ */ new Set();
@@ -2326,8 +2441,8 @@ var Engine = class {
2326
2441
  }
2327
2442
  saveStatCache() {
2328
2443
  const files = JSON.stringify(Object.fromEntries(this.tracked));
2329
- mkdirSync5(this.home, { recursive: true });
2330
- replaceFileAtomically(join8(this.home, "stat.json"), files, 420);
2444
+ mkdirSync6(this.home, { recursive: true });
2445
+ replaceFileAtomically(join9(this.home, "stat.json"), files, 420);
2331
2446
  }
2332
2447
  /**
2333
2448
  * Takes in every write since the last sweep and files each change to its writer. ponytail: always the whole
@@ -2376,7 +2491,7 @@ var Engine = class {
2376
2491
  /** The file's hash once copied in, or why there is none: gone, or still changing through every read. */
2377
2492
  async storeIfPresent(path) {
2378
2493
  try {
2379
- const abs = join8(this.dir, path);
2494
+ const abs = join9(this.dir, path);
2380
2495
  const { size } = await stat2(abs);
2381
2496
  if (isUncopied(path, size)) return { hash: await this.blobs.reference(abs) };
2382
2497
  const hash = await this.blobs.put(abs);
@@ -2698,7 +2813,7 @@ var Engine = class {
2698
2813
  const parts = path.split("/");
2699
2814
  for (let depth = 1; depth <= parts.length; depth += 1) {
2700
2815
  const at = parts.slice(0, depth).join("/");
2701
- const stat4 = lstatSync4(join8(this.dir, at), { throwIfNoEntry: false });
2816
+ const stat4 = lstatSync5(join9(this.dir, at), { throwIfNoEntry: false });
2702
2817
  if (!stat4) return void 0;
2703
2818
  if (at === path || !stat4.isDirectory()) return { at, stat: stat4 };
2704
2819
  }
@@ -2710,7 +2825,7 @@ var Engine = class {
2710
2825
  if (!standing) return void 0;
2711
2826
  if (standing.stat.isSymbolicLink()) return standing.at;
2712
2827
  if (standing.at === path && !standing.stat.isDirectory()) return void 0;
2713
- const real = realpathSync.native(join8(this.dir, standing.at));
2828
+ const real = realpathSync.native(join9(this.dir, standing.at));
2714
2829
  const at = relative5(realpathSync.native(this.dir), real).split(sep5).join("/");
2715
2830
  if (standing.at !== path) return deleted.has(at) ? void 0 : at;
2716
2831
  return fileLeftIn(real, at, deleted);
@@ -2748,22 +2863,29 @@ var Engine = class {
2748
2863
  /** Writes one project file (null deletes it), first leaving the running operation's receipt for its echo. */
2749
2864
  async writeProjectFile(path, hash) {
2750
2865
  this.assertWritable();
2751
- const absPath = join8(this.dir, path);
2866
+ const absPath = join9(this.dir, path);
2752
2867
  const { writeToken } = this;
2753
2868
  if (writeToken) {
2754
2869
  const version = hash === null ? DELETED_VERSION : hashVersion(hash);
2755
2870
  recordFileWriteReceipt(absPath, { path, version, writeToken });
2756
2871
  }
2757
- const standing = lstatSync4(absPath, { throwIfNoEntry: false });
2758
- if (standing?.isFile() && isUncopied(path, standing.size))
2759
- await this.blobs.keep(path, absPath, hash === null);
2872
+ const folder = folderWithin(this.dir, path, hash !== null);
2873
+ if (!folder) return;
2874
+ const at = join9(folder, basename4(path));
2875
+ const standing = lstatSync5(at, { throwIfNoEntry: false });
2876
+ const uncopied = standing?.isFile() === true && isUncopied(path, standing.size);
2760
2877
  if (hash === null) {
2761
2878
  this.assertWritable();
2762
- rmSync3(absPath, { force: true });
2763
- } else {
2764
- await removeEmptyFolders(absPath);
2765
- await this.blobs.writeTo(hash, absPath, () => this.assertWritable());
2879
+ await removeWithin(
2880
+ folder,
2881
+ path,
2882
+ uncopied ? (aside) => this.blobs.keep(path, aside, true) : void 0
2883
+ );
2884
+ return;
2766
2885
  }
2886
+ if (uncopied) await this.blobs.keep(path, at, false);
2887
+ await removeEmptyFolders(at);
2888
+ await this.blobs.writeTo(hash, this.dir, path, () => this.assertWritable());
2767
2889
  }
2768
2890
  entry(id) {
2769
2891
  const entry = this.log.entries.find((candidate) => candidate.id === id);
@@ -2906,7 +3028,7 @@ var Engine = class {
2906
3028
  },
2907
3029
  checkout: (entryId, side, emptyDir) => this.queue(async () => {
2908
3030
  this.entry(entryId);
2909
- if (!existsSync3(this.dir)) throw new Error(`The project folder is gone: ${this.dir}`);
3031
+ if (!existsSync4(this.dir)) throw new Error(`The project folder is gone: ${this.dir}`);
2910
3032
  const dest = resolve8(emptyDir);
2911
3033
  if (isWithin(this.dir, dest))
2912
3034
  throw new Error(`Checkout writes outside the project only: ${dest}`);
@@ -2917,10 +3039,11 @@ var Engine = class {
2917
3039
  if (!this.blobs.has(hash))
2918
3040
  throw new Error(`The version of ${path} from then is not kept.`);
2919
3041
  try {
2920
- for (const [path, hash] of files) await this.blobs.writeTo(hash, join8(dest, path));
3042
+ await mkdir2(dest, { recursive: true });
3043
+ for (const [path, hash] of files) await this.blobs.writeTo(hash, dest, path);
2921
3044
  } catch (error) {
2922
3045
  for (const name of await readdir4(dest).catch(() => []))
2923
- await rm3(join8(dest, name), { recursive: true, force: true });
3046
+ await rm3(join9(dest, name), { recursive: true, force: true });
2924
3047
  throw error;
2925
3048
  }
2926
3049
  }),
@@ -2961,7 +3084,7 @@ var Engine = class {
2961
3084
  };
2962
3085
  function isWithin(dir, path) {
2963
3086
  let probe = resolve8(path);
2964
- while (!existsSync3(probe) && dirname5(probe) !== probe) probe = dirname5(probe);
3087
+ while (!existsSync4(probe) && dirname6(probe) !== probe) probe = dirname6(probe);
2965
3088
  const rel = relative5(realpathSync.native(dir), realpathSync.native(probe));
2966
3089
  return rel === "" || rel !== ".." && !rel.startsWith(`..${sep5}`) && !isAbsolute5(rel);
2967
3090
  }
@@ -2982,16 +3105,16 @@ var HistoryRefusedError = class extends Error {
2982
3105
  }
2983
3106
  };
2984
3107
  async function openProjectHistory(options) {
2985
- if (!existsSync3(options.projectDir))
3108
+ if (!existsSync4(options.projectDir))
2986
3109
  throw new HistoryClosedError(`${options.projectDir} is gone or now another project.`);
2987
3110
  const projectId = projectHistoryId(options.projectDir, options.historyRoot);
2988
3111
  const release = await takeHistoryOwnership(
2989
- join8(options.historyRoot, projectId),
3112
+ join9(options.historyRoot, projectId),
2990
3113
  options.ownerWaitMs ?? 5e3,
2991
3114
  options.ownerUrl
2992
3115
  );
2993
3116
  try {
2994
- const blobs = await openBlobStore(join8(options.historyRoot, projectId, "blobs"));
3117
+ const blobs = await openBlobStore(join9(options.historyRoot, projectId, "blobs"));
2995
3118
  const closedWindow = options.closedWindowAfterOwnership?.() ?? options.closedWindow;
2996
3119
  const engine = new Engine({ ...options, closedWindow }, projectId, blobs);
2997
3120
  await engine.queue(async () => {
@@ -3015,7 +3138,7 @@ async function openProjectHistory(options) {
3015
3138
  function readProjectHistory(options) {
3016
3139
  const dir = resolve8(options.projectDir);
3017
3140
  const id = readId(dir);
3018
- const home = id && isRecordedFolder(join8(options.historyRoot, id), statSync5(dir)) ? join8(options.historyRoot, id) : null;
3141
+ const home = id && isRecordedFolder(join9(options.historyRoot, id), statSync5(dir)) ? join9(options.historyRoot, id) : null;
3019
3142
  const read = home && readLog(logFileIn(home), () => {
3020
3143
  });
3021
3144
  const log = withoutHiddenPaths(read || { baseline: /* @__PURE__ */ new Map(), entries: [], pins: /* @__PURE__ */ new Set() });
@@ -3024,7 +3147,7 @@ function readProjectHistory(options) {
3024
3147
  peek: (point) => peekOf(log, point),
3025
3148
  readBlob: async (hash) => {
3026
3149
  if (!home) throw new Error("That is not a history blob.");
3027
- return readBlob(join8(home, "blobs"), hash);
3150
+ return readBlob(join9(home, "blobs"), hash);
3028
3151
  }
3029
3152
  };
3030
3153
  }
@@ -3052,10 +3175,10 @@ async function blobSizes(blobs, hashes) {
3052
3175
  return sizes;
3053
3176
  }
3054
3177
  async function reclaimOne(home, dryRun) {
3055
- const log = readLog(join9(home, "log.jsonl"), () => {
3178
+ const log = readLog(join10(home, "log.jsonl"), () => {
3056
3179
  });
3057
3180
  if (!log) return 0;
3058
- const blobs = join9(home, "blobs");
3181
+ const blobs = join10(home, "blobs");
3059
3182
  const sizes = await blobSizes(blobs, namedHashes(log));
3060
3183
  let bytes = 0;
3061
3184
  for (const hash of uncopiedOnlyHashes(log, (known) => sizes.get(known) ?? 0)) {
@@ -3069,7 +3192,7 @@ async function reclaimOne(home, dryRun) {
3069
3192
  async function reclaimUncopiedBlobs(historyRoot, { dryRun = false, onError } = {}) {
3070
3193
  const reclaimed = [];
3071
3194
  for (const id of historyIds(historyRoot)) {
3072
- const home = join9(historyRoot, id);
3195
+ const home = join10(historyRoot, id);
3073
3196
  let release;
3074
3197
  try {
3075
3198
  release = await takeHistoryOwnership(home, 0);
@@ -3126,6 +3249,7 @@ export {
3126
3249
  serveWhileOpen,
3127
3250
  onRestoredInPlace,
3128
3251
  isUncopiedMedia,
3252
+ isHistoryId,
3129
3253
  HistoryIdError,
3130
3254
  listProjectHistories,
3131
3255
  pruneGoneProjectHistories,