@hyperframes/studio 0.8.114 → 0.8.115

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 (155) hide show
  1. package/dist/assets/{hyperframes-player-aXNJKiIg.js → hyperframes-player-C-9N8nk0.js} +1 -1
  2. package/dist/assets/{index-Bn2RJNTJ.js → index-BoUM6Xqb.js} +1 -1
  3. package/dist/assets/{index-Dz7doz9l.js → index-CAvZ0AA-.js} +201 -201
  4. package/dist/assets/{index-C9N-DGjC.js → index-CVuorIMv.js} +1 -1
  5. package/dist/assets/{index-BYnsJnJV.css → index-t1LH6H5H.css} +1 -1
  6. package/dist/{chunk-K47E2ZJA.js → chunk-5EKWJZLM.js} +504 -17
  7. package/dist/chunk-5EKWJZLM.js.map +1 -0
  8. package/dist/{chunk-VWT7STY3.js → chunk-J6Q572FA.js} +2 -2
  9. package/dist/{chunk-BIUXP3PG.js → chunk-TXZMMOMA.js} +43 -276
  10. package/dist/chunk-TXZMMOMA.js.map +1 -0
  11. package/dist/{domEditingLayers-V67MS4WP.js → domEditingLayers-D7VYFJJD.js} +3 -5
  12. package/dist/index.d.ts +43 -19
  13. package/dist/index.html +2 -2
  14. package/dist/index.js +2939 -2596
  15. package/dist/index.js.map +1 -1
  16. package/dist/player.js +2 -2
  17. package/dist/styles.css +1 -1
  18. package/package.json +9 -8
  19. package/src/App.tsx +2 -2
  20. package/src/components/LinkedSelectionToggle.tsx +3 -2
  21. package/src/components/dock/Dock.tsx +5 -7
  22. package/src/components/editor/CanvasContextMenu.tsx +3 -2
  23. package/src/components/editor/DomEditCropHandles.test.tsx +27 -0
  24. package/src/components/editor/DomEditCropHandles.tsx +7 -4
  25. package/src/components/editor/DomEditOverlay.tsx +5 -1
  26. package/src/components/editor/FileTreeNodes.tsx +13 -10
  27. package/src/components/editor/MotionPathOverlay.tsx +7 -2
  28. package/src/components/editor/PropertyPanelEmptyState.tsx +12 -2
  29. package/src/components/editor/SnapToolbar.test.tsx +100 -1
  30. package/src/components/editor/SnapToolbar.tsx +43 -5
  31. package/src/components/editor/anchoredResizeCommitFeedsOffset.test.ts +48 -1
  32. package/src/components/editor/audioFxTelemetry.ts +2 -3
  33. package/src/components/editor/commitPreflightHandles.test.tsx +2 -2
  34. package/src/components/editor/cropResize.ts +4 -3
  35. package/src/components/editor/domEditingDom.ts +4 -0
  36. package/src/components/editor/domEditingLayers.ts +1 -5
  37. package/src/components/editor/manualEdits.ts +1 -0
  38. package/src/components/editor/manualEditsParsing.ts +7 -0
  39. package/src/components/editor/marqueeCommit.test.tsx +106 -37
  40. package/src/components/editor/marqueeCommit.ts +24 -8
  41. package/src/components/editor/motionPathCommit.test.ts +29 -1
  42. package/src/components/editor/motionPathCommit.ts +21 -9
  43. package/src/components/editor/probeSourceElement.test.ts +45 -0
  44. package/src/components/editor/probeSourceElement.ts +39 -15
  45. package/src/components/editor/propertyPanelFlatTextSection.tsx +10 -7
  46. package/src/components/editor/propertyPanelFxAddMenu.tsx +11 -2
  47. package/src/components/editor/propertyPanelFxCarveModule.tsx +15 -5
  48. package/src/components/editor/propertyPanelFxNodeOpenBody.tsx +3 -0
  49. package/src/components/editor/propertyPanelFxNodeParams.tsx +15 -2
  50. package/src/components/editor/propertyPanelFxNodeRow.tsx +3 -0
  51. package/src/components/editor/propertyPanelFxPresetRun.tsx +10 -2
  52. package/src/components/editor/propertyPanelFxSection.test.tsx +56 -0
  53. package/src/components/editor/propertyPanelFxSection.tsx +30 -28
  54. package/src/components/editor/propertyPanelTypes.ts +6 -3
  55. package/src/components/editor/useDomEditNudge.test.tsx +37 -0
  56. package/src/components/editor/useDomEditNudge.ts +2 -0
  57. package/src/components/editor/useDomEditOverlayGestures.ts +5 -0
  58. package/src/components/editor/useDomEditZOrder.ts +12 -2
  59. package/src/components/nle/useTimelineEditCallbacks.test.tsx +1 -0
  60. package/src/components/nle/useTimelineEditCallbacks.ts +7 -1
  61. package/src/components/sidebar/AssetContextMenu.tsx +4 -4
  62. package/src/components/ui/menuStyle.test.ts +61 -0
  63. package/src/components/ui/menuStyle.ts +10 -0
  64. package/src/contexts/DomEditContext.tsx +1 -1
  65. package/src/contexts/TimelineEditContext.tsx +1 -0
  66. package/src/domEditExports.test.tsx +9 -1
  67. package/src/hooks/domEditCommitRunner.ts +1 -1
  68. package/src/hooks/elementOffsetStager.ts +5 -4
  69. package/src/hooks/gsapDragCommit.ts +2 -20
  70. package/src/hooks/gsapDragPositionCommit.ts +18 -3
  71. package/src/hooks/gsapGestureOutcome.test.ts +161 -0
  72. package/src/hooks/gsapGestureOutcome.ts +64 -0
  73. package/src/hooks/gsapKeyframeCommit.ts +3 -12
  74. package/src/hooks/gsapResizeIntercept.test.ts +33 -0
  75. package/src/hooks/gsapResizeIntercept.ts +1 -0
  76. package/src/hooks/gsapScriptCommitTypes.ts +5 -0
  77. package/src/hooks/gsapShared.writeTarget.test.ts +20 -0
  78. package/src/hooks/keyframeCacheAstLoad.ts +6 -5
  79. package/src/hooks/plainRotation.ts +3 -2
  80. package/src/hooks/previewPromotionSelection.test.tsx +1 -1
  81. package/src/hooks/refreshTimelineRowText.test.ts +65 -0
  82. package/src/hooks/refreshTimelineRowText.ts +29 -0
  83. package/src/hooks/useAnimatedPropertyCommit.test.tsx +46 -5
  84. package/src/hooks/useAnimatedPropertyCommit.ts +2 -2
  85. package/src/hooks/useBlockedTimelineEditToast.ts +12 -3
  86. package/src/hooks/useDomEditPositionPatchCommit.ts +18 -23
  87. package/src/hooks/useDomEditTextCommits.test.tsx +18 -0
  88. package/src/hooks/useDomEditTextCommits.ts +5 -1
  89. package/src/hooks/useDomEditWiring.ts +4 -2
  90. package/src/hooks/useDomGeometryCommit.test.tsx +25 -6
  91. package/src/hooks/useDomGeometryCommit.ts +7 -4
  92. package/src/hooks/useDomGeometryCommits.test.tsx +1 -0
  93. package/src/hooks/useDomGeometryCommits.ts +3 -2
  94. package/src/hooks/useDomSelection.test.ts +26 -0
  95. package/src/hooks/useDomSelection.ts +10 -3
  96. package/src/hooks/useDomSelectionTypes.ts +6 -1
  97. package/src/hooks/useEnableKeyframes.test.ts +2 -2
  98. package/src/hooks/useEnableKeyframes.ts +5 -3
  99. package/src/hooks/useExternalFileChangeCoordinator.test.tsx +102 -0
  100. package/src/hooks/useExternalFileChangeCoordinator.ts +31 -6
  101. package/src/hooks/useGestureCommit.test.tsx +225 -55
  102. package/src/hooks/useGestureCommit.ts +86 -55
  103. package/src/hooks/useGsapAwareEditing.test.tsx +11 -6
  104. package/src/hooks/useGsapAwareEditing.ts +96 -195
  105. package/src/hooks/useGsapAwareGroupMove.ts +179 -0
  106. package/src/hooks/useGsapKeyframeOps.sdkUsage.test.tsx +114 -0
  107. package/src/hooks/useGsapKeyframeOps.ts +36 -10
  108. package/src/hooks/useGsapScriptCommits.test.tsx +57 -0
  109. package/src/hooks/useGsapScriptCommits.ts +3 -0
  110. package/src/hooks/useGsapSelectionHandlers.test.tsx +1 -1
  111. package/src/hooks/useGsapSelectionHandlers.ts +24 -18
  112. package/src/hooks/useGsapTweenCache.ts +18 -12
  113. package/src/hooks/usePopulateKeyframeCacheForFile.test.tsx +76 -2
  114. package/src/hooks/usePreviewInteraction.test.ts +21 -0
  115. package/src/hooks/usePreviewInteraction.ts +2 -0
  116. package/src/hooks/useRenderClipContent.test.ts +18 -0
  117. package/src/hooks/useRenderClipContent.ts +4 -5
  118. package/src/hooks/useTimelineDeleteOps.test.tsx +30 -22
  119. package/src/hooks/useTimelineDeleteOps.ts +21 -27
  120. package/src/hooks/useTimelineEditing.test.tsx +1 -1
  121. package/src/player/components/AutomationSelectionMenu.tsx +3 -2
  122. package/src/player/components/ClipContextMenu.test.tsx +73 -0
  123. package/src/player/components/ClipContextMenu.tsx +33 -31
  124. package/src/player/components/KeyframeDiamondContextMenu.tsx +8 -9
  125. package/src/player/components/OutOfSyncBadge.tsx +5 -5
  126. package/src/player/components/TextClipContent.test.ts +19 -0
  127. package/src/player/components/TextClipContent.tsx +27 -0
  128. package/src/player/components/TrackGapContextMenu.tsx +3 -6
  129. package/src/player/components/clipMenuToolItems.test.tsx +23 -0
  130. package/src/player/components/clipMenuToolItems.tsx +13 -9
  131. package/src/player/components/timelineCallbacks.ts +1 -0
  132. package/src/player/components/timelineClipDragGestureLifecycle.ts +1 -1
  133. package/src/player/components/timelineClipGestureHandlers.test.ts +94 -0
  134. package/src/player/components/timelineClipGestureHandlers.ts +20 -2
  135. package/src/player/components/timelineEditing.ts +3 -1
  136. package/src/player/components/timelineLinkSelection.ts +35 -1
  137. package/src/player/components/useTimelineClipDrag.keyboard.test.tsx +14 -0
  138. package/src/player/components/useTimelineClipDrag.ts +6 -7
  139. package/src/player/hooks/timelinePlayerSync.test.ts +6 -0
  140. package/src/player/hooks/timelinePlayerSync.ts +6 -1
  141. package/src/player/lib/timelineElementHelpers.test.ts +87 -1
  142. package/src/player/lib/timelineElementHelpers.ts +6 -15
  143. package/src/player/lib/timelineText.ts +40 -0
  144. package/src/player/store/timelineElement.ts +12 -0
  145. package/src/styles/theme.css +3 -0
  146. package/src/utils/keyframeUsage.ts +79 -0
  147. package/src/utils/previewFeatureUsage.test.ts +32 -0
  148. package/src/utils/previewFeatureUsage.ts +46 -0
  149. package/src/utils/studioTelemetry.test.ts +107 -0
  150. package/src/utils/studioTelemetry.ts +49 -4
  151. package/src/webmcp/StudioAgentTools.tsx +2 -2
  152. package/dist/chunk-BIUXP3PG.js.map +0 -1
  153. package/dist/chunk-K47E2ZJA.js.map +0 -1
  154. /package/dist/{chunk-VWT7STY3.js.map → chunk-J6Q572FA.js.map} +0 -0
  155. /package/dist/{domEditingLayers-V67MS4WP.js.map → domEditingLayers-D7VYFJJD.js.map} +0 -0
@@ -11,6 +11,8 @@ import { usePlayerStore } from "../player";
11
11
  import type { DomEditSelection } from "../components/editor/domEditing";
12
12
  import type { GsapAnimation } from "@hyperframes/core/gsap-parser";
13
13
  import type { CommitMutationOptions } from "./gsapScriptCommitTypes";
14
+ import { trackPreviewEditResult } from "../utils/previewFeatureUsage";
15
+ import { observeGsapGesture } from "./gsapGestureOutcome";
14
16
  import { roundTo3 } from "../utils/rounding";
15
17
  import { classifyPropertyGroup } from "@hyperframes/core/gsap-parser";
16
18
  import { isInstantHold, idSelector, writeTargetSelector, tweenTargetsElement } from "./gsapShared";
@@ -72,6 +74,7 @@ interface GestureSessionRef {
72
74
  commitMutation?: (
73
75
  mutation: Record<string, unknown>,
74
76
  options: CommitMutationOptions,
77
+ selection?: DomEditSelection,
75
78
  ) => Promise<void>;
76
79
  }
77
80
 
@@ -81,6 +84,12 @@ function reloadOnlyLast(index: number, count: number): Partial<CommitMutationOpt
81
84
  return index === count - 1 ? { softReload: true } : { skipReload: true };
82
85
  }
83
86
 
87
+ function recordingEnd(selection: DomEditSelection): number | undefined {
88
+ const start = Number.parseFloat(selection.dataAttributes?.start ?? "0") || 0;
89
+ const duration = Number.parseFloat(selection.dataAttributes?.duration ?? "0") || 0;
90
+ return duration > 0 ? start + duration : undefined;
91
+ }
92
+
84
93
  let gestureRecordingCommitCounter = 0;
85
94
 
86
95
  interface UseGestureCommitParams {
@@ -95,7 +104,7 @@ interface UseGestureCommitParams {
95
104
  export interface UseGestureCommitResult {
96
105
  gestureState: "idle" | "recording";
97
106
  gestureRecording: ReturnType<typeof useGestureRecording>;
98
- handleToggleRecording: () => void;
107
+ handleToggleRecording: (method?: "button" | "keyboard") => void;
99
108
  }
100
109
 
101
110
  // fallow-ignore-next-line complexity
@@ -111,11 +120,13 @@ export function useGestureCommit({
111
120
  const [gestureState, setGestureState] = useState<"idle" | "recording">("idle");
112
121
  const gestureStateRef = useRef<"idle" | "recording">("idle");
113
122
  const recordingAutoStopRef = useRef<ReturnType<typeof setInterval>>(undefined);
123
+ const recordingMethodRef = useRef<"button" | "keyboard">("button");
114
124
  const recordingStartTimeRef = useRef(0);
115
125
  const commitInFlightRef = useRef(false);
116
126
  // Capture selection at recording start so commit always targets the recorded element,
117
127
  // even if the user's selection changes mid-recording.
118
128
  const capturedSelectionRef = useRef<DomEditSelection | null>(null);
129
+ const capturedAnimationsRef = useRef<GsapAnimation[]>([]);
119
130
 
120
131
  // Unmount: clear auto-stop interval
121
132
  useEffect(() => () => clearInterval(recordingAutoStopRef.current), []);
@@ -206,6 +217,12 @@ export function useGestureCommit({
206
217
  return;
207
218
  }
208
219
  if (liveSession.commitMutation) {
220
+ const writer = liveSession.commitMutation;
221
+ const outcome = observeGsapGesture((_selection, mutation, options) =>
222
+ writer(mutation, options, sel),
223
+ );
224
+ const commit = (mutation: Record<string, unknown>, options: CommitMutationOptions) =>
225
+ outcome.commit!(sel, mutation, options);
209
226
  const recStart = recordingStartTimeRef.current;
210
227
  const rawKeyframes = sortedPcts.map((pct) => ({
211
228
  percentage: pct,
@@ -216,7 +233,7 @@ export function useGestureCommit({
216
233
  const hasPositionProps = keyframes.some((kf) =>
217
234
  Object.keys(kf.properties).some((k) => classifyPropertyGroup(k) === "position"),
218
235
  );
219
- const allAnims = liveSession.selectedGsapAnimations ?? [];
236
+ const allAnims = capturedAnimationsRef.current;
220
237
  const existingPositionTween = hasPositionProps
221
238
  ? allAnims.find(
222
239
  (a) =>
@@ -228,7 +245,7 @@ export function useGestureCommit({
228
245
  if (isInstantHold(existingPositionTween)) {
229
246
  // An instant hold is not a tween to merge into — replace it with the
230
247
  // recorded motion (which already starts from the held position).
231
- await liveSession.commitMutation(
248
+ await commit(
232
249
  {
233
250
  type: "replace-with-keyframes",
234
251
  animationId: existingPositionTween.id,
@@ -237,7 +254,7 @@ export function useGestureCommit({
237
254
  duration: roundTo3(duration),
238
255
  keyframes,
239
256
  },
240
- { label: "Gesture recording (replace set)", softReload: true },
257
+ { label: "Gesture recording (replace set)", softReload: true, keyframeAction: "add" },
241
258
  );
242
259
  } else {
243
260
  const tweenStart = existingPositionTween.resolvedStart ?? 0;
@@ -274,7 +291,7 @@ export function useGestureCommit({
274
291
 
275
292
  const merged = [...preserved, ...mapped].sort((a, b) => a.percentage - b.percentage);
276
293
 
277
- await liveSession.commitMutation(
294
+ await commit(
278
295
  {
279
296
  type: "replace-with-keyframes",
280
297
  animationId: existingPositionTween.id,
@@ -286,7 +303,7 @@ export function useGestureCommit({
286
303
  duration: tweenDur,
287
304
  keyframes: merged,
288
305
  },
289
- { label: "Gesture recording (merge)", softReload: true },
306
+ { label: "Gesture recording (merge)", softReload: true, keyframeAction: "add" },
290
307
  );
291
308
  } else {
292
309
  // Emit one tween per property group so a mixed-prop gesture (e.g.
@@ -294,7 +311,7 @@ export function useGestureCommit({
294
311
  // tween that the position-only drag intercept can't edit.
295
312
  const keyframeGroups = partitionKeyframesByGroup(keyframes);
296
313
  for (const [index, groupKfs] of keyframeGroups.entries()) {
297
- await liveSession.commitMutation(
314
+ await commit(
298
315
  {
299
316
  type: "add-with-keyframes",
300
317
  targetSelector: writeSelector,
@@ -320,7 +337,7 @@ export function useGestureCommit({
320
337
  // No existing tween — same per-group split as the new-range branch above.
321
338
  const keyframeGroups = partitionKeyframesByGroup(keyframes);
322
339
  for (const [index, groupKfs] of keyframeGroups.entries()) {
323
- await liveSession.commitMutation(
340
+ await commit(
324
341
  {
325
342
  type: "add-with-keyframes",
326
343
  targetSelector: writeSelector,
@@ -338,6 +355,7 @@ export function useGestureCommit({
338
355
  );
339
356
  }
340
357
  }
358
+ trackPreviewEditResult("gesture_recording", recordingMethodRef.current, outcome.finish());
341
359
  }
342
360
  showToast(`Recorded ${sortedPcts.length} keyframes`, "info");
343
361
  } catch (err) {
@@ -351,58 +369,71 @@ export function useGestureCommit({
351
369
  }
352
370
  }, [gestureRecording, showToast, isGestureRecordingRef, domEditSessionRef]);
353
371
 
354
- // fallow-ignore-next-line complexity
355
- const handleToggleRecording = useCallback(() => {
356
- if (gestureStateRef.current === "recording") {
357
- if (readOnlyPreview) {
358
- cancelRecording();
372
+ const armAutoStop = useCallback(
373
+ (elementEnd: number | undefined) => {
374
+ clearInterval(recordingAutoStopRef.current);
375
+ const autoStopAt = elementEnd ?? Infinity;
376
+ recordingAutoStopRef.current = setInterval(() => {
377
+ const { currentTime: t, duration: d } = usePlayerStore.getState();
378
+ const limit = Math.min(autoStopAt, d);
379
+ if (limit > 0 && t >= limit - 0.05) {
380
+ void stopAndCommitRecording();
381
+ }
382
+ }, 100);
383
+ },
384
+ [stopAndCommitRecording],
385
+ );
386
+
387
+ const startRecording = useCallback(
388
+ (method: "button" | "keyboard") => {
389
+ if (readOnlyPreview) return;
390
+ const sel = domEditSessionRef.current.domEditSelection;
391
+ if (!sel) {
392
+ showToast("Select an element first", "error");
393
+ return;
394
+ }
395
+ const iframe = previewIframeRef.current;
396
+ if (!iframe) {
397
+ showToast("Preview not ready — try again", "error");
359
398
  return;
360
399
  }
361
- void stopAndCommitRecording();
362
- return;
363
- }
364
- if (readOnlyPreview) return;
365
- const sel = domEditSessionRef.current.domEditSelection;
366
- if (!sel) {
367
- showToast("Select an element first", "error");
368
- return;
369
- }
370
- const iframe = previewIframeRef.current;
371
- if (!iframe) {
372
- showToast("Preview not ready — try again", "error");
373
- return;
374
- }
375
400
 
376
- const store = usePlayerStore.getState();
377
- recordingStartTimeRef.current = store.currentTime;
378
- const elStart = Number.parseFloat(sel.dataAttributes?.start ?? "0") || 0;
379
- const elDur = Number.parseFloat(sel.dataAttributes?.duration ?? "0") || 0;
380
- const elementEnd = elDur > 0 ? elStart + elDur : undefined;
381
- capturedSelectionRef.current = sel;
382
- gestureRecording.startRecording(sel.element, iframe, elementEnd);
383
- gestureStateRef.current = "recording";
384
- isGestureRecordingRef.current = true;
385
- setGestureState("recording");
401
+ const store = usePlayerStore.getState();
402
+ recordingMethodRef.current = method;
403
+ recordingStartTimeRef.current = store.currentTime;
404
+ const elementEnd = recordingEnd(sel);
405
+ capturedSelectionRef.current = sel;
406
+ capturedAnimationsRef.current = domEditSessionRef.current.selectedGsapAnimations ?? [];
407
+ gestureRecording.startRecording(sel.element, iframe, elementEnd);
408
+ gestureStateRef.current = "recording";
409
+ isGestureRecordingRef.current = true;
410
+ setGestureState("recording");
386
411
 
387
- clearInterval(recordingAutoStopRef.current);
388
- const autoStopAt = elementEnd ?? Infinity;
389
- recordingAutoStopRef.current = setInterval(() => {
390
- const { currentTime: t, duration: d } = usePlayerStore.getState();
391
- const limit = Math.min(autoStopAt, d);
392
- if (limit > 0 && t >= limit - 0.05) {
393
- void stopAndCommitRecording();
412
+ armAutoStop(elementEnd);
413
+ },
414
+ [
415
+ gestureRecording,
416
+ showToast,
417
+ previewIframeRef,
418
+ domEditSessionRef,
419
+ isGestureRecordingRef,
420
+ readOnlyPreview,
421
+ armAutoStop,
422
+ ],
423
+ );
424
+
425
+ const handleToggleRecording = useCallback(
426
+ (method: "button" | "keyboard" = "button") => {
427
+ if (commitInFlightRef.current) return;
428
+ if (gestureStateRef.current === "recording") {
429
+ if (readOnlyPreview) cancelRecording();
430
+ else void stopAndCommitRecording();
431
+ return;
394
432
  }
395
- }, 100);
396
- }, [
397
- gestureRecording,
398
- showToast,
399
- stopAndCommitRecording,
400
- cancelRecording,
401
- previewIframeRef,
402
- domEditSessionRef,
403
- isGestureRecordingRef,
404
- readOnlyPreview,
405
- ]);
433
+ startRecording(method);
434
+ },
435
+ [cancelRecording, readOnlyPreview, startRecording, stopAndCommitRecording],
436
+ );
406
437
 
407
438
  return useStableHandlers({ gestureState, gestureRecording, handleToggleRecording }, projectId);
408
439
  }
@@ -74,7 +74,7 @@ function mountResizeHandler(
74
74
  size: { width: number; height: number },
75
75
  offset?: { x: number; y: number },
76
76
  restore?: () => void,
77
- ) => Promise<void>)
77
+ ) => Promise<void | import("../utils/previewFeatureUsage").GeometryCommitResult>)
78
78
  | null = null;
79
79
  let property: ReturnType<typeof useGsapAwareEditing>["commitAnimatedProperty"] | null = null;
80
80
  function Harness() {
@@ -131,13 +131,18 @@ function mountGroupHandler({
131
131
  "trackGsapInteractionFailure" | "stageElementPositionOffset" | "handleDomRotationCommit"
132
132
  >
133
133
  >) {
134
- let groupCommit!: (updates: DomEditGroupPathOffsetCommit[]) => Promise<void>;
134
+ let groupCommit!: (
135
+ updates: DomEditGroupPathOffsetCommit[],
136
+ ) => Promise<void | import("../utils/previewFeatureUsage").GeometryCommitResult>;
135
137
  let pathOffsetCommit!: (
136
138
  selection: DomEditSelection,
137
139
  next: { x: number; y: number },
138
140
  route?: { plainTranslate?: boolean },
139
- ) => Promise<void>;
140
- let rotationCommit!: (selection: DomEditSelection, next: RotationCommit) => Promise<void>;
141
+ ) => Promise<void | import("../utils/previewFeatureUsage").GeometryCommitResult>;
142
+ let rotationCommit!: (
143
+ selection: DomEditSelection,
144
+ next: RotationCommit,
145
+ ) => Promise<void | import("../utils/previewFeatureUsage").GeometryCommitResult>;
141
146
  function Harness() {
142
147
  const editing = useGsapAwareEditing({
143
148
  domEditSelection: null,
@@ -589,7 +594,7 @@ describe("useGsapAwareEditing anchored resize", () => {
589
594
  h.selection.element.setAttribute("data-hf-drag-initial-offset-x", "0");
590
595
  h.selection.element.setAttribute("data-hf-drag-initial-offset-y", "0");
591
596
 
592
- let commit!: Promise<void>;
597
+ let commit!: Promise<void | import("../utils/previewFeatureUsage").GeometryCommitResult>;
593
598
  act(() => {
594
599
  commit = h.resize(h.selection, { width: 300, height: 200 }, { x: -50.2, y: -25.6 });
595
600
  });
@@ -636,7 +641,7 @@ describe("useGsapAwareEditing anchored resize", () => {
636
641
  s: DomEditSelection,
637
642
  m: unknown,
638
643
  o: { coalesceKey?: string; label?: string; softReload?: boolean },
639
- ) => Promise<void>,
644
+ ) => Promise<void | import("../utils/previewFeatureUsage").GeometryCommitResult>,
640
645
  _fetch: unknown,
641
646
  options?: { preflightOnly?: boolean },
642
647
  ) => {