hyperframes 0.8.115 → 0.8.117

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 (163) hide show
  1. package/dist/{add-ZSLFODRZ.js → add-IIQPNPGC.js} +16 -16
  2. package/dist/{animatedGifPrep-72A45YER.js → animatedGifPrep-Z2SW4EP4.js} +7 -7
  3. package/dist/{asset-SGDOHBBN.js → asset-G2YFF22T.js} +2 -2
  4. package/dist/{assetCataloger-Q7BCDARF.js → assetCataloger-D5JB2JMJ.js} +3 -3
  5. package/dist/{auth-5JGFN7SV.js → auth-TLQUVQZM.js} +2 -2
  6. package/dist/{autoUpdate-ZVTMYO7Z.js → autoUpdate-H6AOMII5.js} +2 -2
  7. package/dist/{backgroundChecks-IY3G5G2D.js → backgroundChecks-RYFTDMFT.js} +3 -3
  8. package/dist/backgroundChecksWorker.js +3 -3
  9. package/dist/{batchRender-QVLLL5DN.js → batchRender-YIAVYPWT.js} +4 -4
  10. package/dist/{beats-66KZIB5V.js → beats-VO3VHQWQ.js} +13 -13
  11. package/dist/{benchmark-AWFKSWQH.js → benchmark-34XZJT2Q.js} +13 -13
  12. package/dist/{browser-J54EXMCE.js → browser-LACRZ6JL.js} +10 -10
  13. package/dist/{bundleWithLocalizedFonts-BLLHP2TO.js → bundleWithLocalizedFonts-EYKE5ZX6.js} +2 -2
  14. package/dist/{capture-D4HRSVSK.js → capture-MMS22F4Q.js} +2 -2
  15. package/dist/{capture-SLI2I5BS.js → capture-ZQTC6I6C.js} +10 -10
  16. package/dist/{catalog-BUMLQU7L.js → catalog-TH4AFNHA.js} +16 -16
  17. package/dist/{check-HEZUK62C.js → check-3ECOPYGB.js} +33 -33
  18. package/dist/{checkBrowser-RVJM6IUO.js → checkBrowser-6KZQZ56A.js} +32 -32
  19. package/dist/{chunk-T5HXGUM3.js → chunk-2LT5WBQR.js} +1 -1
  20. package/dist/{chunk-IEE7GIVX.js → chunk-2NC676XZ.js} +2 -2
  21. package/dist/{chunk-WZYHTXZY.js → chunk-5KSSEDQS.js} +1 -1
  22. package/dist/{chunk-TWJT2RGZ.js → chunk-6QJZ5ELI.js} +4 -4
  23. package/dist/{chunk-4HIF3LI3.js → chunk-6SHCWTLO.js} +5 -5
  24. package/dist/{chunk-M7XTMZF5.js → chunk-7CXLMMUA.js} +2 -2
  25. package/dist/{chunk-ZBQP54CD.js → chunk-7PWGR3MW.js} +5 -5
  26. package/dist/{chunk-2H37RGJ2.js → chunk-AFG4DOYJ.js} +10 -10
  27. package/dist/{chunk-VDASTWUM.js → chunk-AFUXSLNG.js} +2 -2
  28. package/dist/{chunk-3YTWSGBV.js → chunk-AGLQPT3K.js} +4 -4
  29. package/dist/{chunk-XMAL2A7Y.js → chunk-AIYKVE4Y.js} +1 -1
  30. package/dist/{chunk-SK53U3PF.js → chunk-AJU4HUC6.js} +1 -1
  31. package/dist/{chunk-SC7ICSIU.js → chunk-AWEJWZVO.js} +1 -1
  32. package/dist/{chunk-IOJAVV6J.js → chunk-BPZSP7ZJ.js} +1 -1
  33. package/dist/{chunk-Y2Y4LBJD.js → chunk-BRWHMATR.js} +3 -3
  34. package/dist/{chunk-2DX6JYL2.js → chunk-CUU2MHZJ.js} +2 -2
  35. package/dist/{chunk-TMCJPHPP.js → chunk-D5DP3BQJ.js} +1 -1
  36. package/dist/{chunk-3J4EBX5M.js → chunk-DZNISW63.js} +1 -1
  37. package/dist/{chunk-YNHP6OFJ.js → chunk-EGBBEKJJ.js} +2 -2
  38. package/dist/{chunk-P73WQPSB.js → chunk-EH2XJW65.js} +1 -1
  39. package/dist/{chunk-UUDQD62L.js → chunk-FSLYPQ5Z.js} +1 -1
  40. package/dist/{chunk-BQG33YTI.js → chunk-IUNDV47P.js} +1 -1
  41. package/dist/{chunk-XJQ7TRLG.js → chunk-JQJPJ6VZ.js} +1 -1
  42. package/dist/{chunk-74RAXWDF.js → chunk-KGFTVLNQ.js} +1 -1
  43. package/dist/{chunk-SOEQWMNS.js → chunk-KKWOE65F.js} +2 -2
  44. package/dist/{chunk-HPWPLV5J.js → chunk-L3MEJHF4.js} +3 -3
  45. package/dist/chunk-L6TT37IY.js +3541 -0
  46. package/dist/{chunk-HOBR4IHC.js → chunk-LAV6WGPA.js} +7 -7
  47. package/dist/{chunk-SSZYJCAL.js → chunk-LX3VVPMN.js} +2 -2
  48. package/dist/{chunk-AXXK3LWL.js → chunk-MIBZTWN4.js} +1 -1
  49. package/dist/{chunk-YJEGT5L6.js → chunk-NITBGIHR.js} +2 -2
  50. package/dist/{chunk-PZTEY73C.js → chunk-NRTZ2JPC.js} +1 -1
  51. package/dist/{chunk-KLZ7OCHR.js → chunk-O27US3U4.js} +3 -3
  52. package/dist/{chunk-3R6P5BIG.js → chunk-P3REWAFF.js} +2 -2
  53. package/dist/{chunk-QXNRRMBQ.js → chunk-PEZCMM6X.js} +2 -2
  54. package/dist/{chunk-BDNCUMZM.js → chunk-QNC5C6DU.js} +1 -1
  55. package/dist/{chunk-2GWVY66H.js → chunk-QNQJ3WAL.js} +1 -1
  56. package/dist/{chunk-MPB7BQT7.js → chunk-R6BVKVII.js} +1 -1
  57. package/dist/{chunk-SAO3NQPF.js → chunk-SH4GCZVF.js} +1 -1
  58. package/dist/{chunk-6SEUZGID.js → chunk-SXOYBUM7.js} +3 -3
  59. package/dist/{chunk-PLP4K6WZ.js → chunk-TC26HGZB.js} +169 -92
  60. package/dist/{chunk-RDMAU7AJ.js → chunk-TRLP3CSL.js} +1 -1
  61. package/dist/{chunk-5YSA3YXO.js → chunk-UDAEVABF.js} +9 -9
  62. package/dist/{chunk-ORAISNGN.js → chunk-UWROQP7K.js} +10 -10
  63. package/dist/{chunk-QMFCL2ZN.js → chunk-XTBM64YY.js} +2 -2
  64. package/dist/{chunk-4P2TOD7N.js → chunk-XZEU47V2.js} +1 -1
  65. package/dist/{chunk-CVBWF2MD.js → chunk-YB4QYTVZ.js} +1 -1
  66. package/dist/{chunk-5MXN7WM4.js → chunk-Z3QXVEZM.js} +13 -5
  67. package/dist/{clean-X6Y252ZC.js → clean-CU7GAMS4.js} +17 -17
  68. package/dist/cli.js +50 -50
  69. package/dist/{cloud-EE4GALWR.js → cloud-QT372KIW.js} +4 -4
  70. package/dist/{cloudrun-Y6A42KHE.js → cloudrun-3LJRT5XM.js} +5 -5
  71. package/dist/{compare-K6XJZ3OC.js → compare-IOPOTPI2.js} +27 -27
  72. package/dist/{compiler-DYACPLUW.js → compiler-66K2RT7V.js} +3 -3
  73. package/dist/{component-T6IYSCFP.js → component-URUXOWQL.js} +3 -3
  74. package/dist/{compositions-4KUTNS5L.js → compositions-GT4Z5OLP.js} +12 -12
  75. package/dist/{delete-C64TWAPE.js → delete-COWZD2Z3.js} +2 -2
  76. package/dist/{deterministicFonts-A4CNCSAL.js → deterministicFonts-O7BTFDJU.js} +2 -2
  77. package/dist/{dist-KNGSQALD.js → dist-HJS3UTNS.js} +3 -3
  78. package/dist/{dist-HRBNHR4M.js → dist-JAOG6MYW.js} +1 -1
  79. package/dist/{doctor-WJXZK5QN.js → doctor-WKGV26CY.js} +11 -11
  80. package/dist/{events-QRWJBSV4.js → events-BMKJDGYG.js} +9 -9
  81. package/dist/{events-FVG3Y6Q4.js → events-TR7DJB73.js} +10 -10
  82. package/dist/{feedback-NQHRUOZP.js → feedback-TFJPY3BO.js} +11 -11
  83. package/dist/{figma-MEX4CSIM.js → figma-YGJ6Z7LR.js} +3 -3
  84. package/dist/fontLocalizeCli.js +10 -10
  85. package/dist/{get-CMJIHGSA.js → get-AYASBZBE.js} +2 -2
  86. package/dist/{gpuPolicy-5S4OZDME.js → gpuPolicy-H6MUFZ7D.js} +7 -7
  87. package/dist/{grade-compare-NIDMIUGZ.js → grade-compare-2T2NKG27.js} +27 -27
  88. package/dist/{gsapParser-KVMPC2SC.js → gsapParser-ZGBBDA54.js} +30 -12
  89. package/dist/{gsapParserAcorn-SZANFUAQ.js → gsapParserAcorn-FLWABPQM.js} +1 -1
  90. package/dist/{help-G6AWAWJW.js → help-AH4GQKJV.js} +1 -1
  91. package/dist/{history-ZBOK2JQF.js → history-DG67TNAR.js} +17 -17
  92. package/dist/hyperframe-runtime.js +50 -50
  93. package/dist/hyperframe.manifest.json +1 -1
  94. package/dist/hyperframe.runtime.iife.js +50 -50
  95. package/dist/hyperframes-player.global.js +1 -1
  96. package/dist/{info-2ORQZ6I2.js → info-EEH52AYK.js} +12 -12
  97. package/dist/{init-3PSKH6UR.js → init-VONKWUCG.js} +23 -23
  98. package/dist/{inspect-NR54RMEE.js → inspect-IQM3SHDV.js} +28 -28
  99. package/dist/{installer-YQUWHYBZ.js → installer-PA5MGVDO.js} +5 -5
  100. package/dist/{keyframes-KT7T4AEV.js → keyframes-6HCXBPLQ.js} +13 -13
  101. package/dist/{lambda-3FF4V3X3.js → lambda-YIHWNJEH.js} +6 -6
  102. package/dist/{layout-RB3M37ER.js → layout-YLB6OPZY.js} +28 -28
  103. package/dist/{lint-HR57M5YP.js → lint-2EFYARRR.js} +13 -13
  104. package/dist/{lintProject-TOLC6HDS.js → lintProject-FDJYTOVM.js} +1 -1
  105. package/dist/{list-YDXYHXHF.js → list-QIHEPPHZ.js} +2 -2
  106. package/dist/{login-N6UNRVYW.js → login-UZUODUQC.js} +4 -4
  107. package/dist/{media-treatment-UXJOTNRO.js → media-treatment-FG4RMJXK.js} +13 -13
  108. package/dist/{models-Z3XFMGXB.js → models-SUK4QOJ5.js} +8 -8
  109. package/dist/{motionShot-KQMCXJ77.js → motionShot-BEHZNNNU.js} +12 -12
  110. package/dist/{normalize-audio-XJQMDWRV.js → normalize-audio-H3YZQLBO.js} +12 -12
  111. package/dist/{pipeline-U3OISHWV.js → pipeline-5LVBTW62.js} +7 -7
  112. package/dist/{play-XP77PML5.js → play-CRJFW3QL.js} +22 -22
  113. package/dist/{preflight-CANFVC4Y.js → preflight-3MQ7JMHN.js} +8 -8
  114. package/dist/{present-MWGA3O4S.js → present-NQBKJXIK.js} +18 -18
  115. package/dist/{preview-X5GWZ3Q6.js → preview-FWHELX4C.js} +18 -18
  116. package/dist/{producer-B2IHU7MA.js → producer-LKUMV4PJ.js} +1 -1
  117. package/dist/{projectConfig-2A64YU5H.js → projectConfig-LKX4GGB2.js} +7 -7
  118. package/dist/{publication-CFYBPLRS.js → publication-AFF2GNOK.js} +3 -3
  119. package/dist/{publish-WE6AS77D.js → publish-OIXKASHL.js} +9 -9
  120. package/dist/{remove-background-XSDOCVN5.js → remove-background-GEIGOOB6.js} +8 -8
  121. package/dist/{render-HVZUCLYW.js → render-CRILOZHZ.js} +22 -22
  122. package/dist/{render-5TMRIC73.js → render-J3OXL3L3.js} +13 -13
  123. package/dist/{render-QX6AKB6Y.js → render-QVLJLHQ7.js} +4 -4
  124. package/dist/{render-batch-QJXFVTDE.js → render-batch-3JQIYKPW.js} +4 -4
  125. package/dist/{renderCancellation-WSSSHRFR.js → renderCancellation-XHKRCKT5.js} +7 -7
  126. package/dist/renderSetupWorker.js +1 -1
  127. package/dist/{resolver-WTXO6WXA.js → resolver-BT3HKPZI.js} +5 -5
  128. package/dist/{sherpa-S6ZBBEFO.js → sherpa-QGPYYPAD.js} +8 -8
  129. package/dist/{skills-CDRSTETB.js → skills-CZJLCXUA.js} +12 -12
  130. package/dist/{skillsUpdateCheck-FKREJXSF.js → skillsUpdateCheck-OXJP2M7T.js} +3 -3
  131. package/dist/{snapshot-T4PFSXTH.js → snapshot-QZJWBKZN.js} +28 -28
  132. package/dist/{src-5BZDQAVN.js → src-J5MXEA24.js} +9 -9
  133. package/dist/{src-IZMCUYK7.js → src-SMYS3ES6.js} +6 -6
  134. package/dist/{staticProjectServer-VN4ARAH4.js → staticProjectServer-6PXSZKJQ.js} +16 -16
  135. package/dist/{status-OJZWJB53.js → status-SN6EI5XW.js} +7 -7
  136. package/dist/studio/assets/{hyperframes-player-C-9N8nk0.js → hyperframes-player-5fcgSstJ.js} +1 -1
  137. package/dist/studio/assets/{index-CAvZ0AA-.js → index-C5qKdpgl.js} +205 -203
  138. package/dist/studio/assets/{index-BoUM6Xqb.js → index-XJSawwYe.js} +1 -1
  139. package/dist/studio/assets/{index-CVuorIMv.js → index-tg2LXUeu.js} +1 -1
  140. package/dist/studio/{chunk-TXZMMOMA.js → chunk-3F47EFCT.js} +100 -2
  141. package/dist/studio/chunk-3F47EFCT.js.map +1 -0
  142. package/dist/studio/{domEditingLayers-D7VYFJJD.js → domEditingLayers-OL7GLSS4.js} +2 -2
  143. package/dist/studio/index.d.ts +132 -41
  144. package/dist/studio/index.html +1 -1
  145. package/dist/studio/index.js +1184 -1084
  146. package/dist/studio/index.js.map +1 -1
  147. package/dist/{studio-api-CIO2NKK5.js → studio-api-NDOUNA7Q.js} +10 -10
  148. package/dist/{studioServer-G5GNYWDI.js → studioServer-KOZN6A7J.js} +42 -42
  149. package/dist/{system-PPNNGVIM.js → system-SQ6LYDVJ.js} +7 -7
  150. package/dist/{telemetry-GMDMISOX.js → telemetry-JK7FY3NA.js} +10 -10
  151. package/dist/{timeline-5LSQX4OS.js → timeline-I6XEIRSM.js} +17 -17
  152. package/dist/{tokens-VBXAT7CK.js → tokens-AMSWSL2S.js} +2 -2
  153. package/dist/{transcribe-GYCAIIEQ.js → transcribe-XGX6PHHX.js} +13 -13
  154. package/dist/{transcribe-VGYAWRXS.js → transcribe-YTDPY4NU.js} +8 -8
  155. package/dist/{updateCheck-AZEREUQV.js → updateCheck-MW2L5VMR.js} +2 -2
  156. package/dist/{upgrade-S63QN2LA.js → upgrade-ERWPVZRE.js} +2 -2
  157. package/dist/{urlDownloader-SM6ODN5O.js → urlDownloader-QNEGOWQO.js} +6 -6
  158. package/dist/{validate-7MNUK5MH.js → validate-HSIBDBTS.js} +17 -17
  159. package/dist/{video-JEOHARTC.js → video-GMTTFD2W.js} +7 -7
  160. package/package.json +1 -1
  161. package/dist/chunk-RRPJEHHW.js +0 -3541
  162. package/dist/studio/chunk-TXZMMOMA.js.map +0 -1
  163. /package/dist/studio/{domEditingLayers-D7VYFJJD.js.map → domEditingLayers-OL7GLSS4.js.map} +0 -0
@@ -20,7 +20,7 @@ import {
20
20
  splitElementInHtml,
21
21
  unwrapElementsFromHtml,
22
22
  wrapElementsInHtml
23
- } from "./chunk-TWJT2RGZ.js";
23
+ } from "./chunk-6QJZ5ELI.js";
24
24
  import {
25
25
  atomicTempPath,
26
26
  createFileAtomically,
@@ -33,7 +33,7 @@ import {
33
33
  measureAudio,
34
34
  requiredFfmpeg,
35
35
  resolveLocalAudioPath
36
- } from "./chunk-MPB7BQT7.js";
36
+ } from "./chunk-R6BVKVII.js";
37
37
  import {
38
38
  PROXY_PARAMS_VERSION,
39
39
  PROXY_PENDING_RETRY_AFTER_SECONDS,
@@ -59,11 +59,11 @@ import {
59
59
  shouldPrewarmProxy,
60
60
  waitForProxy,
61
61
  walkDir
62
- } from "./chunk-QMFCL2ZN.js";
62
+ } from "./chunk-XTBM64YY.js";
63
63
  import {
64
64
  findTimelineScript,
65
65
  parseGsapScriptAcorn
66
- } from "./chunk-RDMAU7AJ.js";
66
+ } from "./chunk-TRLP3CSL.js";
67
67
  import {
68
68
  STUDIO_MANUAL_EDITS_PATH
69
69
  } from "./chunk-KC5XXX3X.js";
@@ -78,16 +78,16 @@ import {
78
78
  formatRenderOutputTimestamp,
79
79
  parseFps,
80
80
  sameInstant
81
- } from "./chunk-IEE7GIVX.js";
81
+ } from "./chunk-2NC676XZ.js";
82
82
  import {
83
83
  MagicString,
84
84
  VALID_CANVAS_RESOLUTIONS,
85
85
  unrollComputedTimeline
86
- } from "./chunk-UUDQD62L.js";
86
+ } from "./chunk-FSLYPQ5Z.js";
87
87
  import {
88
88
  addScenePartsManifest,
89
89
  ensureHfIds
90
- } from "./chunk-M7XTMZF5.js";
90
+ } from "./chunk-7CXLMMUA.js";
91
91
  import {
92
92
  findStartTags,
93
93
  injectScriptsIntoHtml,
@@ -97,7 +97,7 @@ import {
97
97
  resolveRateSpec,
98
98
  sourceTimeAt,
99
99
  stripEmbeddedRuntimeScripts
100
- } from "./chunk-RRPJEHHW.js";
100
+ } from "./chunk-L6TT37IY.js";
101
101
  import {
102
102
  ProjectRootMissingError,
103
103
  folderGone,
@@ -110,7 +110,7 @@ import {
110
110
  import {
111
111
  isWithinProjectRoot,
112
112
  readProjectFile
113
- } from "./chunk-YJEGT5L6.js";
113
+ } from "./chunk-NITBGIHR.js";
114
114
  import {
115
115
  FFPROBE_PATH_ENV,
116
116
  findFfBinary
@@ -2185,9 +2185,11 @@ var PROP_TO_GROUP2 = /* @__PURE__ */ new Map();
2185
2185
  for (const [group, props] of Object.entries(PROPERTY_GROUPS2)) {
2186
2186
  for (const p of props) PROP_TO_GROUP2.set(p, group);
2187
2187
  }
2188
+ function writesProperty(animation, property) {
2189
+ return property in animation.properties || !!animation.fromProperties && property in animation.fromProperties || !!animation.keyframes?.keyframes.some((k) => property in k.properties);
2190
+ }
2188
2191
  function isXYPositionWrite(a) {
2189
- const xy = (props) => !!props && ("x" in props || "y" in props);
2190
- return a.propertyGroup === "position" && (xy(a.properties) || xy(a.fromProperties) || !!a.keyframes?.keyframes.some((k) => xy(k.properties)));
2192
+ return a.propertyGroup === "position" && (writesProperty(a, "x") || writesProperty(a, "y"));
2191
2193
  }
2192
2194
  function classifyPropertyGroup2(prop) {
2193
2195
  return PROP_TO_GROUP2.get(prop) ?? "other";
@@ -2202,6 +2204,30 @@ function classifyTweenPropertyGroup(properties) {
2202
2204
  if (groups.size === 1) return groups.values().next().value;
2203
2205
  return void 0;
2204
2206
  }
2207
+ function knownStart(animation) {
2208
+ if (animation.resolvedStart !== void 0) return animation.resolvedStart;
2209
+ return typeof animation.position === "number" ? animation.position : void 0;
2210
+ }
2211
+ function positionHoldForAnimation(animation, animations) {
2212
+ if (!animation.keyframes) return null;
2213
+ const start = knownStart(animation) ?? 0;
2214
+ if (!(start > 1e-3)) return null;
2215
+ const first = [...animation.keyframes.keyframes].sort(
2216
+ (left, right) => left.percentage - right.percentage
2217
+ )[0];
2218
+ if (!first) return null;
2219
+ const earlier = animations.filter((other) => {
2220
+ const otherStart = knownStart(other);
2221
+ return other !== animation && !other.global && other.targetSelector === animation.targetSelector && otherStart !== void 0 && otherStart < start - 1e-3;
2222
+ });
2223
+ const position = {};
2224
+ for (const [property, value] of Object.entries(first.properties)) {
2225
+ if (classifyPropertyGroup2(property) !== "position" || typeof value !== "number") continue;
2226
+ if (earlier.some((other) => writesProperty(other, property))) continue;
2227
+ position[property] = value;
2228
+ }
2229
+ return Object.keys(position).length > 0 ? position : null;
2230
+ }
2205
2231
  function mergePercentageKeyframes(keyframes) {
2206
2232
  const byPercentage = /* @__PURE__ */ new Map();
2207
2233
  for (const keyframe of keyframes) {
@@ -3378,6 +3404,41 @@ function resolveTimelinePositions(anims, labelDefs = []) {
3378
3404
  });
3379
3405
  while (labelIdx < sortedLabels.length) defineLabel(sortedLabels[labelIdx++]);
3380
3406
  }
3407
+ function collectAddLabelDefs(ast, ref, scope, sortedCalls) {
3408
+ const callKeys = sortedCalls.map((c) => ({
3409
+ site: callSiteStart(c),
3410
+ order: c.node.__hfOrder
3411
+ }));
3412
+ const comesAfter = (site, order, labelSite, labelOrder) => {
3413
+ if (site === void 0) return false;
3414
+ if (site !== labelSite) return site > labelSite;
3415
+ return (order ?? -Infinity) > (labelOrder ?? -Infinity);
3416
+ };
3417
+ const defs = [];
3418
+ simple(ast, {
3419
+ // fallow-ignore-next-line complexity
3420
+ CallExpression(node) {
3421
+ const callee = node.callee;
3422
+ const objMatches = ref.kind === "identifier" ? callee.object?.type === "Identifier" && callee.object.name === ref.name : sameMemberAccess(callee.object, ref.node);
3423
+ if (callee?.type !== "MemberExpression" || !objMatches || callee.property?.name !== "addLabel")
3424
+ return;
3425
+ const nameNode = node.arguments?.[0];
3426
+ const name = typeof nameNode?.value === "string" ? nameNode.value : void 0;
3427
+ if (!name) return;
3428
+ const posVal = resolveNode(node.arguments?.[1], scope);
3429
+ const position = typeof posVal === "number" || typeof posVal === "string" ? posVal : void 0;
3430
+ const labelStart = node.__hfSiteStart ?? callee.property?.start;
3431
+ const labelOrder = node.__hfOrder;
3432
+ let order = sortedCalls.length;
3433
+ if (labelStart !== void 0) {
3434
+ order = callKeys.findIndex((k) => comesAfter(k.site, k.order, labelStart, labelOrder));
3435
+ if (order === -1) order = sortedCalls.length;
3436
+ }
3437
+ defs.push({ name, position, order });
3438
+ }
3439
+ });
3440
+ return defs;
3441
+ }
3381
3442
  function compareByLoc(a, b) {
3382
3443
  const aLoc = a.node.callee?.property?.loc?.start;
3383
3444
  const bLoc = b.node.callee?.property?.loc?.start;
@@ -3430,7 +3491,7 @@ function parseGsapScriptAcornForWrite(script) {
3430
3491
  (call) => tweenCallToAnimation(call, scope, script, identifierBindings)
3431
3492
  );
3432
3493
  applyTimelineDefaults(rawAnims, detection.defaults);
3433
- resolveTimelinePositions(rawAnims);
3494
+ resolveTimelinePositions(rawAnims, collectAddLabelDefs(ast, ref, scope, calls));
3434
3495
  const animations = assignStableIds(rawAnims);
3435
3496
  const located = calls.map((call, i) => ({
3436
3497
  id: animations[i].id,
@@ -3704,7 +3765,8 @@ function overwritePosition(ms, call, position) {
3704
3765
  if (call.positionArg) {
3705
3766
  ms.overwrite(call.positionArg.start, call.positionArg.end, valueToCode(position));
3706
3767
  } else {
3707
- ms.appendLeft(call.node.end - 1, `, ${valueToCode(position)}`);
3768
+ const last = call.node.arguments.at(-1);
3769
+ ms.appendLeft(last ? last.end : call.node.end - 1, `, ${valueToCode(position)}`);
3708
3770
  }
3709
3771
  }
3710
3772
  function shiftPositionsInScript(script, targetSelector, delta, root) {
@@ -4426,6 +4488,33 @@ function materializeKeyframesFromScript(script, animationId, keyframes, easeEach
4426
4488
  }
4427
4489
  return ms.toString();
4428
4490
  }
4491
+ function replaceTweenWithKeyframesInScript(script, animationId, edit) {
4492
+ const parsed = parseGsapScriptAcornForWrite(script);
4493
+ const target = parsed?.located.find((l) => l.id === animationId);
4494
+ const call = target?.call;
4495
+ if (!target || call?.varsArg?.type !== "ObjectExpression") return null;
4496
+ const { animation } = target;
4497
+ if (animation.method !== "to" && animation.method !== "from" && animation.method !== "fromTo")
4498
+ return null;
4499
+ const ms = new MagicString(script);
4500
+ const start = animation.resolvedStart ?? animation.position;
4501
+ const moved = typeof start !== "number" || Math.abs(start - edit.position) > 5e-4;
4502
+ const kept = preservedVarsEntries(call.varsArg, script).filter(
4503
+ (e) => !/^\s*duration\s*:/.test(e) && !(moved && /^\s*delay\s*:/.test(e))
4504
+ );
4505
+ const sorted = [...edit.keyframes].sort((a, b) => a.percentage - b.percentage);
4506
+ const parts = [`keyframes: ${buildKeyframeObjectCode(sorted, edit.easeEach)}`, ...kept];
4507
+ parts.push(`duration: ${valueToCode(edit.duration)}`);
4508
+ if (edit.ease) parts.push(`ease: ${JSON.stringify(edit.ease)}`);
4509
+ if (animation.hasUnresolvedSelector || animation.targetSelector !== edit.targetSelector) {
4510
+ const selectorArg = call.node.arguments[0];
4511
+ ms.overwrite(selectorArg.start, selectorArg.end, JSON.stringify(edit.targetSelector));
4512
+ }
4513
+ convertMethodToTo(ms, animation, call, call.varsArg);
4514
+ overwriteVarsArg(ms, call, `{ ${parts.join(", ")} }`);
4515
+ if (moved) overwritePosition(ms, call, edit.position);
4516
+ return ms.toString();
4517
+ }
4429
4518
  function addAnimationWithKeyframesToScript(script, targetSelector, position, duration, keyframes, ease, easeEach) {
4430
4519
  const parsed = parseGsapScriptAcornForWrite(script);
4431
4520
  if (!parsed) return { script, id: "" };
@@ -4764,7 +4853,8 @@ function insertInheritedStateSetInScript(script, selector, position, properties)
4764
4853
  const tlDecl = findTimelineDeclarationStatement(parsed.ast, parsed.timelineVar);
4765
4854
  const firstLocated = parsed.located[0];
4766
4855
  if (tlDecl) {
4767
- ms.appendLeft(tlDecl.end, "\n" + code);
4856
+ const ownLineEnd = script[tlDecl.end] === "\n" ? "" : "\n";
4857
+ ms.appendLeft(tlDecl.end, "\n" + code + ownLineEnd);
4768
4858
  } else if (firstLocated) {
4769
4859
  const firstCall = firstLocated.call;
4770
4860
  const exprStmt = findEnclosingExpressionStatement(firstCall.ancestors);
@@ -4786,38 +4876,15 @@ function removeStudioHoldSets(script, parsed) {
4786
4876
  for (const hold of staleHolds) removeCallFromMagicString(ms, hold.call, script);
4787
4877
  return ms.toString();
4788
4878
  }
4789
- function animationStart(animation) {
4790
- if (animation.resolvedStart !== void 0) return animation.resolvedStart;
4791
- return typeof animation.position === "number" ? animation.position : 0;
4792
- }
4793
- function positionProperties(properties) {
4794
- const position = {};
4795
- for (const [property, value] of Object.entries(properties)) {
4796
- if (classifyPropertyGroup2(property) === "position" && typeof value === "number") {
4797
- position[property] = value;
4798
- }
4799
- }
4800
- return position;
4801
- }
4802
- function positionHoldForAnimation(animation) {
4803
- if (!animation.keyframes) return null;
4804
- if (!(animationStart(animation) > 1e-3)) return null;
4805
- const first = [...animation.keyframes.keyframes].sort(
4806
- (left, right) => left.percentage - right.percentage
4807
- )[0];
4808
- if (!first) return null;
4809
- const position = positionProperties(first.properties);
4810
- return Object.keys(position).length > 0 ? position : null;
4811
- }
4812
4879
  function syncPositionHoldsBeforeKeyframes(script) {
4813
4880
  const parsed = parseGsapScriptAcornForWrite(script);
4814
4881
  if (!parsed) return script;
4815
4882
  let result = removeStudioHoldSets(script, parsed);
4816
4883
  const current = parseGsapScriptAcornForWrite(result);
4817
4884
  if (!current) return result;
4818
- for (const entry of current.located) {
4819
- const animation = entry.animation;
4820
- const position = positionHoldForAnimation(animation);
4885
+ const animations = current.located.map((entry) => entry.animation);
4886
+ for (const animation of animations) {
4887
+ const position = positionHoldForAnimation(animation, animations);
4821
4888
  if (!position) continue;
4822
4889
  result = insertInheritedStateSetInScript(result, animation.targetSelector, 0, {
4823
4890
  ...position,
@@ -5157,23 +5224,23 @@ import { createHash as createHash32 } from "crypto";
5157
5224
  import { existsSync as existsSync7, readFileSync as readFileSync10, statSync as statSync7 } from "fs";
5158
5225
  import { join as join12, resolve as resolve52 } from "path";
5159
5226
  import { execFile } from "child_process";
5160
- import { existsSync as existsSync8, readFileSync as readFileSync11, statSync as statSync8 } from "fs";
5227
+ import { closeSync as closeSync32, openSync as openSync32, readFileSync as readFileSync11, rmSync as rmSync5, statSync as statSync8 } from "fs";
5161
5228
  import { dirname as dirname52, join as join13, relative as relative4, sep as sep22 } from "path";
5162
5229
  import { createHash as createHash5, randomBytes } from "crypto";
5163
- import { existsSync as existsSync9 } from "fs";
5164
- import { existsSync as existsSync10, readFileSync as readFileSync12, statSync as statSync9 } from "fs";
5230
+ import { existsSync as existsSync8 } from "fs";
5231
+ import { existsSync as existsSync9, readFileSync as readFileSync12, statSync as statSync9 } from "fs";
5165
5232
  import { join as join14, resolve as resolve6 } from "path";
5166
5233
  import { execFile as execFile2, spawn as spawn2 } from "child_process";
5167
5234
  import { promisify } from "util";
5168
- import { closeSync as closeSync32, constants as constants3, fstatSync as fstatSync3, openSync as openSync32, readSync } from "fs";
5235
+ import { closeSync as closeSync4, constants as constants3, fstatSync as fstatSync3, openSync as openSync4, readSync } from "fs";
5169
5236
  import { streamSSE as streamSSE2 } from "hono/streaming";
5170
- import { existsSync as existsSync11 } from "fs";
5237
+ import { existsSync as existsSync10 } from "fs";
5171
5238
  import { basename as basename22, dirname as dirname6, extname as extname2, join as join15, posix } from "path";
5172
- import { existsSync as existsSync12, readFileSync as readFileSync13 } from "fs";
5239
+ import { existsSync as existsSync11, readFileSync as readFileSync13 } from "fs";
5173
5240
  import { homedir as homedir2 } from "os";
5174
5241
  import { join as join16 } from "path";
5175
5242
  import { createHash as createHash6 } from "crypto";
5176
- import { readFileSync as readFileSync14, readdirSync as readdirSync5, rmSync as rmSync5 } from "fs";
5243
+ import { readFileSync as readFileSync14, readdirSync as readdirSync5, rmSync as rmSync6 } from "fs";
5177
5244
  import { join as join17 } from "path";
5178
5245
  async function filterCompositionFiles(projectDir, files) {
5179
5246
  const htmlFiles = files.filter((f) => f.endsWith(".html") && !isInHiddenOrVendorDir(f));
@@ -5853,7 +5920,7 @@ function requestSubPath(url, route) {
5853
5920
  return decodeURIComponent(segments.slice(start + routeSegments.length).join("/"));
5854
5921
  }
5855
5922
  async function loadGsapParser() {
5856
- return import("./gsapParser-KVMPC2SC.js");
5923
+ return import("./gsapParser-ZGBBDA54.js");
5857
5924
  }
5858
5925
  function isDanglingSymlinkInProject(projectDir, lexicalPath) {
5859
5926
  if (!isSafePath(projectDir, dirname32(lexicalPath))) return false;
@@ -6413,6 +6480,21 @@ function bakeVisibilityOnDelete(document2, anim) {
6413
6480
  } catch {
6414
6481
  }
6415
6482
  }
6483
+ function replaceInPlaceUnlessSetOrUnknown(scriptText, body) {
6484
+ const edit = { ...body, easeEach: resolveReplacementEaseEach(scriptText, body) };
6485
+ const inPlace = replaceTweenWithKeyframesInScript(scriptText, body.animationId, edit);
6486
+ if (inPlace !== null) return inPlace;
6487
+ const script = removeAnimationFromScript(scriptText, body.animationId);
6488
+ return addAnimationWithKeyframesToScript(
6489
+ script,
6490
+ body.targetSelector,
6491
+ body.position,
6492
+ body.duration,
6493
+ body.keyframes,
6494
+ body.ease,
6495
+ edit.easeEach
6496
+ ).script;
6497
+ }
6416
6498
  function resolveReplacementEaseEach(scriptText, request) {
6417
6499
  if (request.easeEach !== void 0) return request.easeEach;
6418
6500
  const original = parseGsapScriptAcorn(scriptText).animations.find(
@@ -6484,7 +6566,7 @@ async function prepareGsapMutationScript(c, res, firstMutation) {
6484
6566
  let block = extractGsapScriptBlock(html);
6485
6567
  if (!block && (firstMutation.type === "add" || firstMutation.type === "add-with-keyframes")) {
6486
6568
  const compId = html.match(/data-composition-id="([^"]+)"/)?.[1] ?? "main";
6487
- const { GSAP_CDN } = await import("./dist-KNGSQALD.js");
6569
+ const { GSAP_CDN } = await import("./dist-HJS3UTNS.js");
6488
6570
  const bootstrap = [
6489
6571
  `<script src="${GSAP_CDN}"></script>`,
6490
6572
  "<script>",
@@ -6819,17 +6901,7 @@ function executeGsapMutationAcorn(body, block, respond) {
6819
6901
  if (keyframesWritePosition(body.keyframes) || keyframesWriteRotation(body.keyframes)) {
6820
6902
  stripStudioEditsFromTarget(block.document, body.targetSelector);
6821
6903
  }
6822
- const script = removeAnimationFromScript(block.scriptText, body.animationId);
6823
- const added = addAnimationWithKeyframesToScript(
6824
- script,
6825
- body.targetSelector,
6826
- body.position,
6827
- body.duration,
6828
- body.keyframes,
6829
- body.ease,
6830
- resolveReplacementEaseEach(block.scriptText, body)
6831
- );
6832
- return added.script;
6904
+ return replaceInPlaceUnlessSetOrUnknown(block.scriptText, body);
6833
6905
  }
6834
6906
  case "split-animations": {
6835
6907
  if (typeof body.originalId !== "string" || !body.originalId || typeof body.newId !== "string" || !body.newId || typeof body.splitTime !== "number" || !Number.isFinite(body.splitTime) || typeof body.elementStart !== "number" || !Number.isFinite(body.elementStart) || typeof body.elementDuration !== "number" || !Number.isFinite(body.elementDuration) || body.elementDuration <= 0) {
@@ -7151,17 +7223,7 @@ async function executeGsapMutationRecast(body, block, respond) {
7151
7223
  if (keyframesWritePosition(body.keyframes) || keyframesWriteRotation(body.keyframes)) {
7152
7224
  stripStudioEditsFromTarget(block.document, body.targetSelector);
7153
7225
  }
7154
- const script = removeAnimationFromScript2(block.scriptText, body.animationId);
7155
- const added = addAnimationWithKeyframesToScript2(
7156
- script,
7157
- body.targetSelector,
7158
- body.position,
7159
- body.duration,
7160
- body.keyframes,
7161
- body.ease,
7162
- resolveReplacementEaseEach(block.scriptText, body)
7163
- );
7164
- return added.script;
7226
+ return replaceInPlaceUnlessSetOrUnknown(block.scriptText, body);
7165
7227
  }
7166
7228
  case "split-animations": {
7167
7229
  if (typeof body.originalId !== "string" || !body.originalId || typeof body.newId !== "string" || !body.newId || typeof body.splitTime !== "number" || !Number.isFinite(body.splitTime) || typeof body.elementStart !== "number" || !Number.isFinite(body.elementStart) || typeof body.elementDuration !== "number" || !Number.isFinite(body.elementDuration) || body.elementDuration <= 0) {
@@ -9767,7 +9829,7 @@ function freezeFrameMediaTime(input) {
9767
9829
  return input.mediaStart + sourceTimeAt(rate, Math.max(0, input.playhead - input.clipStart));
9768
9830
  }
9769
9831
  function freezeExtractArgs(src, mediaTime, output) {
9770
- return ["-n", "-ss", String(round3(mediaTime)), "-i", src, "-frames:v", "1", output];
9832
+ return ["-y", "-ss", String(round3(mediaTime)), "-i", src, "-frames:v", "1", output];
9771
9833
  }
9772
9834
  var randomStillToken = () => randomBytes(4).toString("hex");
9773
9835
  function freezeStillFileName(clipId, playhead, token = randomStillToken()) {
@@ -9938,6 +10000,15 @@ function readExpected(absPath, expectedVersion) {
9938
10000
  }
9939
10001
  return fileContentVersion(content) === expectedVersion ? { content } : { error: "file conflict", status: 409 };
9940
10002
  }
10003
+ function claimStillNameBeforeExtracting(path) {
10004
+ try {
10005
+ closeSync32(openSync32(path, "wx"));
10006
+ return true;
10007
+ } catch (error) {
10008
+ if (error.code === "EEXIST") return false;
10009
+ throw error;
10010
+ }
10011
+ }
9941
10012
  async function extractStill(projectDir, absPath, source, playhead, tools) {
9942
10013
  const fileDir = dirname52(absPath);
9943
10014
  const mediaPath = pinWithinProject(projectDir, relative4(projectDir, join13(fileDir, source.src)));
@@ -9949,17 +10020,18 @@ async function extractStill(projectDir, absPath, source, playhead, tools) {
9949
10020
  if (!imagePath || dirname52(imagePath) !== freezeDir) {
9950
10021
  return { error: `forbidden freeze path: ${fileName}`, status: 403 };
9951
10022
  }
9952
- if (existsSync8(imagePath))
10023
+ if (!claimStillNameBeforeExtracting(imagePath))
9953
10024
  return { error: `freeze still already exists: ${fileName}`, status: 409 };
9954
10025
  const extracted = await tools.extract(freezeExtractArgs(mediaPath, source.mediaTime, imagePath));
9955
- if (!extracted.ok) {
9956
- return {
9957
- error: `Could not extract the frame: ${extracted.error ?? "ffmpeg failed"}`,
9958
- status: 500
9959
- };
10026
+ const partialOrNoFrame = !extracted.ok || statSync8(imagePath).size === 0;
10027
+ if (partialOrNoFrame) {
10028
+ rmSync5(imagePath, { force: true });
10029
+ const reason = extracted.ok ? "no frame at this time" : extracted.error ?? "ffmpeg failed";
10030
+ return { error: `Could not extract the frame: ${reason}`, status: 500 };
9960
10031
  }
9961
10032
  const depth = relative4(projectDir, fileDir).split(sep22).filter(Boolean).length;
9962
- return { imageSrc: `${"../".repeat(depth)}${FREEZE_DIR.join("/")}/${fileName}` };
10033
+ const stillPath = `${FREEZE_DIR.join("/")}/${fileName}`;
10034
+ return { imageSrc: `${"../".repeat(depth)}${stillPath}`, stillPath, imagePath };
9963
10035
  }
9964
10036
  function writeFolded(projectDir, absPath, path, before, after, options) {
9965
10037
  if (readFileSync11(absPath, "utf-8") !== before) {
@@ -9993,17 +10065,21 @@ function registerFreezeFrameRoutes(api, adapter, extract = ffmpegExtractor, stil
9993
10065
  stillToken
9994
10066
  });
9995
10067
  if ("error" in still) return c.json({ error: still.error }, still.status);
9996
- const { imageSrc } = still;
10068
+ const { imageSrc, stillPath, imagePath } = still;
9997
10069
  const folded = applyFreezeFrameToHtml(before, {
9998
10070
  target: body.target,
9999
10071
  playhead: body.playhead,
10000
10072
  imageSrc
10001
10073
  });
10002
- if (!folded) return c.json({ error: "Freeze target was not found in the file" }, 400);
10074
+ const failAndRemoveStill = (error, status) => {
10075
+ rmSync5(imagePath, { force: true });
10076
+ return c.json({ error }, status);
10077
+ };
10078
+ if (!folded) return failAndRemoveStill("Freeze target was not found in the file", 400);
10003
10079
  const written = writeFolded(project.dir, absPath, body.path, before, folded.html, {
10004
10080
  token: body.transactionToken ?? c.req.header("X-Hyperframes-Write-Token")
10005
10081
  });
10006
- if ("error" in written) return c.json({ error: written.error }, written.status);
10082
+ if ("error" in written) return failAndRemoveStill(written.error, written.status);
10007
10083
  const { version, writeToken, backupPath } = written;
10008
10084
  return c.json({
10009
10085
  ok: true,
@@ -10014,7 +10090,8 @@ function registerFreezeFrameRoutes(api, adapter, extract = ffmpegExtractor, stil
10014
10090
  writeToken,
10015
10091
  backupPath,
10016
10092
  freezeId: folded.freezeId,
10017
- imageSrc
10093
+ imageSrc,
10094
+ stillPath
10018
10095
  });
10019
10096
  });
10020
10097
  }
@@ -10068,7 +10145,7 @@ function registerLoudnessRoutes(api, adapter, measure = defaultMeasure) {
10068
10145
  } catch (error) {
10069
10146
  return c.json({ error: error instanceof Error ? error.message : String(error) }, 400);
10070
10147
  }
10071
- if (!existsSync9(file)) return c.json({ error: "file not found" }, 404);
10148
+ if (!existsSync8(file)) return c.json({ error: "file not found" }, 404);
10072
10149
  try {
10073
10150
  const measurement = await measure(file, request.window);
10074
10151
  const plan = absoluteLoudnessPlan(
@@ -10189,7 +10266,7 @@ function decodeOnce(cachePath, mediaPath, decode) {
10189
10266
  }
10190
10267
  function readCachedBins(cacheDir, cachePath) {
10191
10268
  try {
10192
- if (!isWaveformCacheDirectory(cacheDir) || !existsSync10(cachePath)) return null;
10269
+ if (!isWaveformCacheDirectory(cacheDir) || !existsSync9(cachePath)) return null;
10193
10270
  const parsed = JSON.parse(readFileSync12(cachePath, "utf-8"));
10194
10271
  return Array.isArray(parsed) && parsed.every((n) => typeof n === "number") ? parsed : null;
10195
10272
  } catch {
@@ -10322,7 +10399,7 @@ function registerFontRoutes(api) {
10322
10399
  if (!located) return c.json({ error: "font not found" }, 404);
10323
10400
  let fd;
10324
10401
  try {
10325
- fd = openSync32(located.path, constants3.O_RDONLY | constants3.O_NOFOLLOW);
10402
+ fd = openSync4(located.path, constants3.O_RDONLY | constants3.O_NOFOLLOW);
10326
10403
  } catch {
10327
10404
  return c.json({ error: "font file not accessible" }, 404);
10328
10405
  }
@@ -10344,7 +10421,7 @@ function registerFontRoutes(api) {
10344
10421
  } catch {
10345
10422
  return c.json({ error: "failed to read font file" }, 500);
10346
10423
  } finally {
10347
- closeSync32(fd);
10424
+ closeSync4(fd);
10348
10425
  }
10349
10426
  });
10350
10427
  }
@@ -10509,7 +10586,7 @@ function uniqueAssetPath(projectDir, assetPath, taken) {
10509
10586
  const ext = extname2(assetPath);
10510
10587
  const withoutExt = assetPath.slice(0, -ext.length);
10511
10588
  let candidate = assetPath;
10512
- for (let index = 2; taken.has(candidate) || existsSync11(join15(projectDir, candidate)); index++) {
10589
+ for (let index = 2; taken.has(candidate) || existsSync10(join15(projectDir, candidate)); index++) {
10513
10590
  candidate = `${withoutExt}-${index}${ext}`;
10514
10591
  }
10515
10592
  return candidate;
@@ -10570,7 +10647,7 @@ function registerMediaRoutes(api, adapter, options = {}) {
10570
10647
  }
10571
10648
  const filePath = resolveWithinProject(project.dir, assetPath);
10572
10649
  if (!filePath) return c.json({ error: "forbidden" }, 403);
10573
- if (!existsSync11(filePath)) return c.json({ error: "media not found" }, 404);
10650
+ if (!existsSync10(filePath)) return c.json({ error: "media not found" }, 404);
10574
10651
  return c.json({ path: assetPath, metadata: await readMediaMetadata(filePath) });
10575
10652
  });
10576
10653
  api.post(
@@ -10592,7 +10669,7 @@ function registerMediaRoutes(api, adapter, options = {}) {
10592
10669
  }
10593
10670
  const inputPath = resolveWithinProject(project.dir, inputAssetPath);
10594
10671
  if (!inputPath) return c.json({ error: "forbidden" }, 403);
10595
- if (!existsSync11(inputPath)) return c.json({ error: "input media not found" }, 404);
10672
+ if (!existsSync10(inputPath)) return c.json({ error: "input media not found" }, 404);
10596
10673
  const inputIsVideo = isVideoPath(inputAssetPath);
10597
10674
  const inputIsImage = isImagePath(inputAssetPath);
10598
10675
  if (!inputIsVideo && !inputIsImage) {
@@ -10686,7 +10763,7 @@ function registerMediaRoutes(api, adapter, options = {}) {
10686
10763
  }
10687
10764
  function readGlobalAssets(home = homedir2()) {
10688
10765
  const manifestPath = join16(home, ".media", "manifest.jsonl");
10689
- if (!existsSync12(manifestPath)) return [];
10766
+ if (!existsSync11(manifestPath)) return [];
10690
10767
  const out = [];
10691
10768
  for (const line of readFileSync13(manifestPath, "utf8").split("\n")) {
10692
10769
  if (!line.trim()) continue;
@@ -10947,7 +11024,7 @@ ${key}`).digest("hex").slice(0, 32)}.html`);
10947
11024
  const file = fileFor(key);
10948
11025
  replaceFileAtomically(file, html, 420);
10949
11026
  for (const name of readdirSync5(dir)) {
10950
- if (join17(dir, name) !== file) rmSync5(join17(dir, name), { force: true });
11027
+ if (join17(dir, name) !== file) rmSync6(join17(dir, name), { force: true });
10951
11028
  }
10952
11029
  } catch {
10953
11030
  }
@@ -1793,7 +1793,7 @@ function parseGsapScriptAcornForWrite(script) {
1793
1793
  (call) => tweenCallToAnimation(call, scope, script, identifierBindings)
1794
1794
  );
1795
1795
  applyTimelineDefaults(rawAnims, detection.defaults);
1796
- resolveTimelinePositions(rawAnims);
1796
+ resolveTimelinePositions(rawAnims, collectAddLabelDefs(ast, ref, scope, calls));
1797
1797
  const animations = assignStableIds(rawAnims);
1798
1798
  const located = calls.map((call, i) => ({
1799
1799
  id: animations[i].id,
@@ -6,23 +6,23 @@ var __filename = __hf_fileURLToPath(import.meta.url);
6
6
  var __dirname = __hf_dirname(__filename);
7
7
  import {
8
8
  serveStaticProjectHtml
9
- } from "./chunk-Y2Y4LBJD.js";
9
+ } from "./chunk-BRWHMATR.js";
10
10
  import {
11
11
  AUDIT_SEEK_OPTIONS,
12
12
  installPageFunctionGuard,
13
13
  seekCompositionTimeline,
14
14
  waitForCompositionFonts
15
- } from "./chunk-ZBQP54CD.js";
15
+ } from "./chunk-7PWGR3MW.js";
16
16
  import {
17
17
  launchManagedBrowser,
18
18
  resolveManagedGpuMode
19
- } from "./chunk-P73WQPSB.js";
19
+ } from "./chunk-EH2XJW65.js";
20
20
  import {
21
21
  resolveDiagnosticNavigationTimeoutMs
22
- } from "./chunk-SC7ICSIU.js";
22
+ } from "./chunk-AWEJWZVO.js";
23
23
  import {
24
24
  resolveProject
25
- } from "./chunk-XJQ7TRLG.js";
25
+ } from "./chunk-JQJPJ6VZ.js";
26
26
  import {
27
27
  c
28
28
  } from "./chunk-ZTZA4UWZ.js";
@@ -36,7 +36,7 @@ import {
36
36
  import {
37
37
  printDeprecationNotice,
38
38
  withMeta
39
- } from "./chunk-T5HXGUM3.js";
39
+ } from "./chunk-2LT5WBQR.js";
40
40
  import {
41
41
  normalizeErrorMessage
42
42
  } from "./chunk-KNU5COPB.js";
@@ -669,7 +669,7 @@ async function collectTweenBoundaries(page) {
669
669
  });
670
670
  }
671
671
  async function bundleProjectHtml(projectDir) {
672
- const { bundleToSingleHtml } = await import("./compiler-DYACPLUW.js");
672
+ const { bundleToSingleHtml } = await import("./compiler-66K2RT7V.js");
673
673
  return bundleToSingleHtml(projectDir);
674
674
  }
675
675
  async function alignViewportToComposition(page, url) {
@@ -691,8 +691,8 @@ async function alignViewportToComposition(page, url) {
691
691
  async function runLayoutAudit(projectDir, opts) {
692
692
  const { ensureBrowser } = await import("./manager-CT3D67CG.js");
693
693
  const puppeteer = await import("puppeteer-core");
694
- const { buildChromeArgs } = await import("./src-IZMCUYK7.js");
695
- const { assertWebGpuAdapterAvailable, compositionRequiresWebGpu, resolveLocalBrowserGpuMode } = await import("./gpuPolicy-5S4OZDME.js");
694
+ const { buildChromeArgs } = await import("./src-SMYS3ES6.js");
695
+ const { assertWebGpuAdapterAvailable, compositionRequiresWebGpu, resolveLocalBrowserGpuMode } = await import("./gpuPolicy-H6MUFZ7D.js");
696
696
  const html = await bundleProjectHtml(projectDir);
697
697
  const server = await serveStaticProjectHtml(
698
698
  projectDir,
@@ -8,17 +8,17 @@ import {
8
8
  installPageFunctionGuard,
9
9
  resolveCliChromeGpuMode,
10
10
  seekCompositionTimeline
11
- } from "./chunk-ZBQP54CD.js";
11
+ } from "./chunk-7PWGR3MW.js";
12
12
  import {
13
13
  resolveCompositionViewportFromHtml
14
14
  } from "./chunk-5Z63TBTX.js";
15
15
  import {
16
16
  launchManagedBrowser,
17
17
  resolveManagedGpuMode
18
- } from "./chunk-P73WQPSB.js";
18
+ } from "./chunk-EH2XJW65.js";
19
19
  import {
20
20
  resolveProject
21
- } from "./chunk-XJQ7TRLG.js";
21
+ } from "./chunk-JQJPJ6VZ.js";
22
22
  import {
23
23
  c
24
24
  } from "./chunk-ZTZA4UWZ.js";
@@ -32,7 +32,7 @@ import {
32
32
  import {
33
33
  printDeprecationNotice,
34
34
  withMeta
35
- } from "./chunk-T5HXGUM3.js";
35
+ } from "./chunk-2LT5WBQR.js";
36
36
  import {
37
37
  normalizeErrorMessage
38
38
  } from "./chunk-KNU5COPB.js";
@@ -221,7 +221,7 @@ function extractCompositionErrorsFromLint(lintResult) {
221
221
  async function localizeRemoteAssets(html) {
222
222
  let dir;
223
223
  try {
224
- const { loadProducer } = await import("./producer-B2IHU7MA.js");
224
+ const { loadProducer } = await import("./producer-LKUMV4PJ.js");
225
225
  const { localizeRemoteMediaSources, localizeRemoteImageSources, localizeRemoteFontFaces } = await loadProducer();
226
226
  dir = mkdtempSync(join(tmpdir(), "hf-validate-assets-"));
227
227
  const assetDir = dir;
@@ -242,10 +242,10 @@ async function localizeRemoteAssets(html) {
242
242
  }
243
243
  async function validateInBrowser(project, opts) {
244
244
  const projectDir = project.dir;
245
- const { bundleToSingleHtml } = await import("./compiler-DYACPLUW.js");
245
+ const { bundleToSingleHtml } = await import("./compiler-66K2RT7V.js");
246
246
  const { ensureBrowser } = await import("./manager-CT3D67CG.js");
247
- const { serveStaticProjectHtml } = await import("./staticProjectServer-VN4ARAH4.js");
248
- const { lintProject } = await import("./lintProject-TOLC6HDS.js");
247
+ const { serveStaticProjectHtml } = await import("./staticProjectServer-6PXSZKJQ.js");
248
+ const { lintProject } = await import("./lintProject-FDJYTOVM.js");
249
249
  const lintResult = await lintProject(projectDir);
250
250
  const compositionErrors = extractCompositionErrorsFromLint(lintResult);
251
251
  const html = await bundleToSingleHtml(projectDir);
@@ -266,9 +266,9 @@ async function validateInBrowser(project, opts) {
266
266
  try {
267
267
  const browser = await ensureBrowser();
268
268
  const puppeteer = await import("puppeteer-core");
269
- const { buildChromeArgs, analyzeClipMediaFit } = await import("./src-IZMCUYK7.js");
269
+ const { buildChromeArgs, analyzeClipMediaFit } = await import("./src-SMYS3ES6.js");
270
270
  const requestedGpuMode = resolveCliChromeGpuMode();
271
- const { assertWebGpuAdapterAvailable, compositionRequiresWebGpu } = await import("./gpuPolicy-5S4OZDME.js");
271
+ const { assertWebGpuAdapterAvailable, compositionRequiresWebGpu } = await import("./gpuPolicy-H6MUFZ7D.js");
272
272
  const resolvedGpuMode = await resolveManagedGpuMode(requestedGpuMode, browser.executablePath);
273
273
  const requiresWebGpu = compositionRequiresWebGpu(html);
274
274
  const chromeBrowser = await launchManagedBrowser(puppeteer.default, {