@remotion/studio 4.0.510 → 4.0.511

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.
@@ -32,9 +32,7 @@ export type TimelineSequenceFromDragTarget = {
32
32
  readonly sequenceKeyframes: TimelineSequenceKeyframeDragTarget[];
33
33
  };
34
34
  type TimelineSequenceKeyframeDragTarget = {
35
- readonly fileName: string;
36
35
  readonly fieldKey: string;
37
- readonly nodePath: SequencePropsSubscriptionKey;
38
36
  readonly schema: InteractivitySchema;
39
37
  readonly status: CanUpdateSequencePropStatusKeyframed;
40
38
  };
@@ -70,15 +70,7 @@ const getKeyframedSequenceDragTargets = ({ nodePath, sequence, propStatuses, })
70
70
  const sequenceKeyframes = sequenceSchema === undefined
71
71
  ? []
72
72
  : Object.entries(status.props).flatMap(([fieldKey, propStatus]) => propStatus.status === 'keyframed'
73
- ? [
74
- {
75
- fileName: nodePath.absolutePath,
76
- fieldKey,
77
- nodePath,
78
- schema: sequenceSchema,
79
- status: propStatus,
80
- },
81
- ]
73
+ ? [{ fieldKey, schema: sequenceSchema, status: propStatus }]
82
74
  : []);
83
75
  const effectKeyframes = status.effects.flatMap((effectStatus) => {
84
76
  var _a;
@@ -93,9 +85,7 @@ const getKeyframedSequenceDragTargets = ({ nodePath, sequence, propStatuses, })
93
85
  ? [
94
86
  {
95
87
  effectIndex: effectStatus.effectIndex,
96
- fileName: nodePath.absolutePath,
97
88
  fieldKey,
98
- nodePath,
99
89
  schema: effectSchema,
100
90
  status: propStatus,
101
91
  },
@@ -362,16 +352,16 @@ const getTimelineSequenceFromDragKeyframeMoves = ({ targets, deltaFrames, }) =>
362
352
  }
363
353
  return {
364
354
  sequenceKeyframes: targets.flatMap((target) => target.sequenceKeyframes.flatMap((keyframeTarget) => keyframeTarget.status.keyframes.map((keyframe) => ({
365
- fileName: keyframeTarget.fileName,
366
- nodePath: keyframeTarget.nodePath,
355
+ fileName: target.fileName,
356
+ nodePath: target.nodePath,
367
357
  fieldKey: keyframeTarget.fieldKey,
368
358
  fromFrame: keyframe.frame,
369
359
  toFrame: keyframe.frame + deltaFrames,
370
360
  schema: keyframeTarget.schema,
371
361
  })))),
372
362
  effectKeyframes: targets.flatMap((target) => target.effectKeyframes.flatMap((keyframeTarget) => keyframeTarget.status.keyframes.map((keyframe) => ({
373
- fileName: keyframeTarget.fileName,
374
- nodePath: keyframeTarget.nodePath,
363
+ fileName: target.fileName,
364
+ nodePath: target.nodePath,
375
365
  effectIndex: keyframeTarget.effectIndex,
376
366
  fieldKey: keyframeTarget.fieldKey,
377
367
  fromFrame: keyframe.frame,
@@ -520,7 +510,6 @@ const getTimelineSequenceFromDragTargets = ({ draggedNodePathInfo, selectedItems
520
510
  : [draggedNodePathInfo];
521
511
  const tracks = (0, calculate_timeline_1.calculateTimeline)({ sequences, overrideIdsToNodePaths });
522
512
  const targets = new Map();
523
- const includedKeyframeNodePaths = new Set();
524
513
  for (const nodePathInfo of targetNodePathInfos) {
525
514
  const track = findSequenceTrack({ tracks, nodePathInfo });
526
515
  const originalSequence = track
@@ -538,42 +527,11 @@ const getTimelineSequenceFromDragTargets = ({ draggedNodePathInfo, selectedItems
538
527
  }
539
528
  const key = (0, studio_shared_1.stringifySequenceSubscriptionKey)(nodePath);
540
529
  if (!targets.has(key)) {
541
- const descendants = sequences.filter((candidate) => {
542
- var _a;
543
- var _b;
544
- let parentId = candidate.id;
545
- while (parentId !== null) {
546
- if (parentId === originalSequence.id) {
547
- return true;
548
- }
549
- parentId = (_b = (_a = sequences.find((sequence) => sequence.id === parentId)) === null || _a === void 0 ? void 0 : _a.parent) !== null && _b !== void 0 ? _b : null;
550
- }
551
- return false;
552
- });
553
- const descendantKeyframes = descendants.flatMap((sequence) => {
554
- var _a;
555
- const overrideId = (_a = sequence.controls) === null || _a === void 0 ? void 0 : _a.overrideId;
556
- const descendantNodePath = overrideId
557
- ? overrideIdsToNodePaths[overrideId]
558
- : undefined;
559
- if (descendantNodePath === undefined) {
560
- return [];
561
- }
562
- const descendantNodePathKey = (0, studio_shared_1.stringifySequenceSubscriptionKey)(descendantNodePath);
563
- if (includedKeyframeNodePaths.has(descendantNodePathKey)) {
564
- return [];
565
- }
566
- includedKeyframeNodePaths.add(descendantNodePathKey);
567
- return [
568
- getKeyframedSequenceDragTargets({
569
- nodePath: descendantNodePath,
570
- sequence,
571
- propStatuses,
572
- }),
573
- ];
530
+ const { effectKeyframes, sequenceKeyframes } = getKeyframedSequenceDragTargets({
531
+ nodePath,
532
+ sequence: originalSequence,
533
+ propStatuses,
574
534
  });
575
- const effectKeyframes = descendantKeyframes.flatMap((descendant) => descendant.effectKeyframes);
576
- const sequenceKeyframes = descendantKeyframes.flatMap((descendant) => descendant.sequenceKeyframes);
577
535
  targets.set(key, {
578
536
  canSnapToTimelineStart: originalSequence.parent === null,
579
537
  effectKeyframes,
@@ -600,16 +558,9 @@ const clearDurationDragOverrides = ({ clearDragOverrides, targets, }) => {
600
558
  const clearFromDragOverrides = ({ clearDragOverrides, clearEffectDragOverrides, targets, }) => {
601
559
  for (const target of targets) {
602
560
  clearDragOverrides(target.nodePath);
603
- for (const keyframeTarget of target.sequenceKeyframes) {
604
- clearDragOverrides(keyframeTarget.nodePath);
605
- }
606
- const effectIndexes = new Set(target.effectKeyframes.map((keyframe) => `${(0, studio_shared_1.stringifySequenceSubscriptionKey)(keyframe.nodePath)}:${keyframe.effectIndex}`));
607
- for (const keyframeTarget of target.effectKeyframes) {
608
- const key = `${(0, studio_shared_1.stringifySequenceSubscriptionKey)(keyframeTarget.nodePath)}:${keyframeTarget.effectIndex}`;
609
- if (!effectIndexes.delete(key)) {
610
- continue;
611
- }
612
- clearEffectDragOverrides(keyframeTarget.nodePath, keyframeTarget.effectIndex);
561
+ const effectIndexes = new Set(target.effectKeyframes.map((keyframe) => keyframe.effectIndex));
562
+ for (const effectIndex of effectIndexes) {
563
+ clearEffectDragOverrides(target.nodePath, effectIndex);
613
564
  }
614
565
  }
615
566
  };
@@ -965,7 +916,7 @@ const useTimelineSequenceFromDrag = ({ nodePathInfo, windowWidth, timelineDurati
965
916
  });
966
917
  latestRef.current.setDragOverrides(target.nodePath, 'from', remotion_1.Internals.makeStaticDragOverride(nextFrom));
967
918
  for (const keyframeTarget of target.sequenceKeyframes) {
968
- latestRef.current.setDragOverrides(keyframeTarget.nodePath, keyframeTarget.fieldKey, {
919
+ latestRef.current.setDragOverrides(target.nodePath, keyframeTarget.fieldKey, {
969
920
  type: 'keyframed',
970
921
  status: shiftKeyframedStatus({
971
922
  status: keyframeTarget.status,
@@ -974,7 +925,7 @@ const useTimelineSequenceFromDrag = ({ nodePathInfo, windowWidth, timelineDurati
974
925
  });
975
926
  }
976
927
  for (const keyframeTarget of target.effectKeyframes) {
977
- latestRef.current.setEffectDragOverrides(keyframeTarget.nodePath, keyframeTarget.effectIndex, keyframeTarget.fieldKey, {
928
+ latestRef.current.setEffectDragOverrides(target.nodePath, keyframeTarget.effectIndex, keyframeTarget.fieldKey, {
978
929
  type: 'keyframed',
979
930
  status: shiftKeyframedStatus({
980
931
  status: keyframeTarget.status,
@@ -64772,15 +64772,7 @@ var getKeyframedSequenceDragTargets = ({
64772
64772
  return { effectKeyframes: [], sequenceKeyframes: [] };
64773
64773
  }
64774
64774
  const sequenceSchema = sequence.controls?.schema;
64775
- const sequenceKeyframes = sequenceSchema === undefined ? [] : Object.entries(status.props).flatMap(([fieldKey, propStatus]) => propStatus.status === "keyframed" ? [
64776
- {
64777
- fileName: nodePath.absolutePath,
64778
- fieldKey,
64779
- nodePath,
64780
- schema: sequenceSchema,
64781
- status: propStatus
64782
- }
64783
- ] : []);
64775
+ const sequenceKeyframes = sequenceSchema === undefined ? [] : Object.entries(status.props).flatMap(([fieldKey, propStatus]) => propStatus.status === "keyframed" ? [{ fieldKey, schema: sequenceSchema, status: propStatus }] : []);
64784
64776
  const effectKeyframes = status.effects.flatMap((effectStatus) => {
64785
64777
  if (!effectStatus.canUpdate) {
64786
64778
  return [];
@@ -64792,9 +64784,7 @@ var getKeyframedSequenceDragTargets = ({
64792
64784
  return Object.entries(effectStatus.props).flatMap(([fieldKey, propStatus]) => propStatus.status === "keyframed" ? [
64793
64785
  {
64794
64786
  effectIndex: effectStatus.effectIndex,
64795
- fileName: nodePath.absolutePath,
64796
64787
  fieldKey,
64797
- nodePath,
64798
64788
  schema: effectSchema,
64799
64789
  status: propStatus
64800
64790
  }
@@ -65066,16 +65056,16 @@ var getTimelineSequenceFromDragKeyframeMoves = ({
65066
65056
  }
65067
65057
  return {
65068
65058
  sequenceKeyframes: targets.flatMap((target) => target.sequenceKeyframes.flatMap((keyframeTarget) => keyframeTarget.status.keyframes.map((keyframe) => ({
65069
- fileName: keyframeTarget.fileName,
65070
- nodePath: keyframeTarget.nodePath,
65059
+ fileName: target.fileName,
65060
+ nodePath: target.nodePath,
65071
65061
  fieldKey: keyframeTarget.fieldKey,
65072
65062
  fromFrame: keyframe.frame,
65073
65063
  toFrame: keyframe.frame + deltaFrames,
65074
65064
  schema: keyframeTarget.schema
65075
65065
  })))),
65076
65066
  effectKeyframes: targets.flatMap((target) => target.effectKeyframes.flatMap((keyframeTarget) => keyframeTarget.status.keyframes.map((keyframe) => ({
65077
- fileName: keyframeTarget.fileName,
65078
- nodePath: keyframeTarget.nodePath,
65067
+ fileName: target.fileName,
65068
+ nodePath: target.nodePath,
65079
65069
  effectIndex: keyframeTarget.effectIndex,
65080
65070
  fieldKey: keyframeTarget.fieldKey,
65081
65071
  fromFrame: keyframe.frame,
@@ -65214,7 +65204,6 @@ var getTimelineSequenceFromDragTargets = ({
65214
65204
  const targetNodePathInfos = draggedItemIsSelected && selectedSequenceItems.length > 1 ? selectedSequenceItems.map((item2) => item2.nodePathInfo) : [draggedNodePathInfo];
65215
65205
  const tracks = calculateTimeline({ sequences, overrideIdsToNodePaths });
65216
65206
  const targets = new Map;
65217
- const includedKeyframeNodePaths = new Set;
65218
65207
  for (const nodePathInfo of targetNodePathInfos) {
65219
65208
  const track = findSequenceTrack({ tracks, nodePathInfo });
65220
65209
  const originalSequence = track ? sequences.find((sequence) => sequence.id === track.sequence.id) : null;
@@ -65227,37 +65216,11 @@ var getTimelineSequenceFromDragTargets = ({
65227
65216
  }
65228
65217
  const key6 = stringifySequenceSubscriptionKey3(nodePath);
65229
65218
  if (!targets.has(key6)) {
65230
- const descendants = sequences.filter((candidate) => {
65231
- let parentId = candidate.id;
65232
- while (parentId !== null) {
65233
- if (parentId === originalSequence.id) {
65234
- return true;
65235
- }
65236
- parentId = sequences.find((sequence) => sequence.id === parentId)?.parent ?? null;
65237
- }
65238
- return false;
65239
- });
65240
- const descendantKeyframes = descendants.flatMap((sequence) => {
65241
- const overrideId = sequence.controls?.overrideId;
65242
- const descendantNodePath = overrideId ? overrideIdsToNodePaths[overrideId] : undefined;
65243
- if (descendantNodePath === undefined) {
65244
- return [];
65245
- }
65246
- const descendantNodePathKey = stringifySequenceSubscriptionKey3(descendantNodePath);
65247
- if (includedKeyframeNodePaths.has(descendantNodePathKey)) {
65248
- return [];
65249
- }
65250
- includedKeyframeNodePaths.add(descendantNodePathKey);
65251
- return [
65252
- getKeyframedSequenceDragTargets({
65253
- nodePath: descendantNodePath,
65254
- sequence,
65255
- propStatuses
65256
- })
65257
- ];
65219
+ const { effectKeyframes, sequenceKeyframes } = getKeyframedSequenceDragTargets({
65220
+ nodePath,
65221
+ sequence: originalSequence,
65222
+ propStatuses
65258
65223
  });
65259
- const effectKeyframes = descendantKeyframes.flatMap((descendant) => descendant.effectKeyframes);
65260
- const sequenceKeyframes = descendantKeyframes.flatMap((descendant) => descendant.sequenceKeyframes);
65261
65224
  targets.set(key6, {
65262
65225
  canSnapToTimelineStart: originalSequence.parent === null,
65263
65226
  effectKeyframes,
@@ -65293,16 +65256,9 @@ var clearFromDragOverrides = ({
65293
65256
  }) => {
65294
65257
  for (const target of targets) {
65295
65258
  clearDragOverrides(target.nodePath);
65296
- for (const keyframeTarget of target.sequenceKeyframes) {
65297
- clearDragOverrides(keyframeTarget.nodePath);
65298
- }
65299
- const effectIndexes = new Set(target.effectKeyframes.map((keyframe) => `${stringifySequenceSubscriptionKey3(keyframe.nodePath)}:${keyframe.effectIndex}`));
65300
- for (const keyframeTarget of target.effectKeyframes) {
65301
- const key6 = `${stringifySequenceSubscriptionKey3(keyframeTarget.nodePath)}:${keyframeTarget.effectIndex}`;
65302
- if (!effectIndexes.delete(key6)) {
65303
- continue;
65304
- }
65305
- clearEffectDragOverrides(keyframeTarget.nodePath, keyframeTarget.effectIndex);
65259
+ const effectIndexes = new Set(target.effectKeyframes.map((keyframe) => keyframe.effectIndex));
65260
+ for (const effectIndex of effectIndexes) {
65261
+ clearEffectDragOverrides(target.nodePath, effectIndex);
65306
65262
  }
65307
65263
  }
65308
65264
  };
@@ -65662,7 +65618,7 @@ var useTimelineSequenceFromDrag = ({
65662
65618
  });
65663
65619
  latestRef.current.setDragOverrides(target.nodePath, "from", Internals118.makeStaticDragOverride(nextFrom));
65664
65620
  for (const keyframeTarget of target.sequenceKeyframes) {
65665
- latestRef.current.setDragOverrides(keyframeTarget.nodePath, keyframeTarget.fieldKey, {
65621
+ latestRef.current.setDragOverrides(target.nodePath, keyframeTarget.fieldKey, {
65666
65622
  type: "keyframed",
65667
65623
  status: shiftKeyframedStatus({
65668
65624
  status: keyframeTarget.status,
@@ -65671,7 +65627,7 @@ var useTimelineSequenceFromDrag = ({
65671
65627
  });
65672
65628
  }
65673
65629
  for (const keyframeTarget of target.effectKeyframes) {
65674
- latestRef.current.setEffectDragOverrides(keyframeTarget.nodePath, keyframeTarget.effectIndex, keyframeTarget.fieldKey, {
65630
+ latestRef.current.setEffectDragOverrides(target.nodePath, keyframeTarget.effectIndex, keyframeTarget.fieldKey, {
65675
65631
  type: "keyframed",
65676
65632
  status: shiftKeyframedStatus({
65677
65633
  status: keyframeTarget.status,
@@ -64825,15 +64825,7 @@ var getKeyframedSequenceDragTargets = ({
64825
64825
  return { effectKeyframes: [], sequenceKeyframes: [] };
64826
64826
  }
64827
64827
  const sequenceSchema = sequence.controls?.schema;
64828
- const sequenceKeyframes = sequenceSchema === undefined ? [] : Object.entries(status.props).flatMap(([fieldKey, propStatus]) => propStatus.status === "keyframed" ? [
64829
- {
64830
- fileName: nodePath.absolutePath,
64831
- fieldKey,
64832
- nodePath,
64833
- schema: sequenceSchema,
64834
- status: propStatus
64835
- }
64836
- ] : []);
64828
+ const sequenceKeyframes = sequenceSchema === undefined ? [] : Object.entries(status.props).flatMap(([fieldKey, propStatus]) => propStatus.status === "keyframed" ? [{ fieldKey, schema: sequenceSchema, status: propStatus }] : []);
64837
64829
  const effectKeyframes = status.effects.flatMap((effectStatus) => {
64838
64830
  if (!effectStatus.canUpdate) {
64839
64831
  return [];
@@ -64845,9 +64837,7 @@ var getKeyframedSequenceDragTargets = ({
64845
64837
  return Object.entries(effectStatus.props).flatMap(([fieldKey, propStatus]) => propStatus.status === "keyframed" ? [
64846
64838
  {
64847
64839
  effectIndex: effectStatus.effectIndex,
64848
- fileName: nodePath.absolutePath,
64849
64840
  fieldKey,
64850
- nodePath,
64851
64841
  schema: effectSchema,
64852
64842
  status: propStatus
64853
64843
  }
@@ -65119,16 +65109,16 @@ var getTimelineSequenceFromDragKeyframeMoves = ({
65119
65109
  }
65120
65110
  return {
65121
65111
  sequenceKeyframes: targets.flatMap((target) => target.sequenceKeyframes.flatMap((keyframeTarget) => keyframeTarget.status.keyframes.map((keyframe) => ({
65122
- fileName: keyframeTarget.fileName,
65123
- nodePath: keyframeTarget.nodePath,
65112
+ fileName: target.fileName,
65113
+ nodePath: target.nodePath,
65124
65114
  fieldKey: keyframeTarget.fieldKey,
65125
65115
  fromFrame: keyframe.frame,
65126
65116
  toFrame: keyframe.frame + deltaFrames,
65127
65117
  schema: keyframeTarget.schema
65128
65118
  })))),
65129
65119
  effectKeyframes: targets.flatMap((target) => target.effectKeyframes.flatMap((keyframeTarget) => keyframeTarget.status.keyframes.map((keyframe) => ({
65130
- fileName: keyframeTarget.fileName,
65131
- nodePath: keyframeTarget.nodePath,
65120
+ fileName: target.fileName,
65121
+ nodePath: target.nodePath,
65132
65122
  effectIndex: keyframeTarget.effectIndex,
65133
65123
  fieldKey: keyframeTarget.fieldKey,
65134
65124
  fromFrame: keyframe.frame,
@@ -65267,7 +65257,6 @@ var getTimelineSequenceFromDragTargets = ({
65267
65257
  const targetNodePathInfos = draggedItemIsSelected && selectedSequenceItems.length > 1 ? selectedSequenceItems.map((item2) => item2.nodePathInfo) : [draggedNodePathInfo];
65268
65258
  const tracks = calculateTimeline({ sequences, overrideIdsToNodePaths });
65269
65259
  const targets = new Map;
65270
- const includedKeyframeNodePaths = new Set;
65271
65260
  for (const nodePathInfo of targetNodePathInfos) {
65272
65261
  const track = findSequenceTrack({ tracks, nodePathInfo });
65273
65262
  const originalSequence = track ? sequences.find((sequence) => sequence.id === track.sequence.id) : null;
@@ -65280,37 +65269,11 @@ var getTimelineSequenceFromDragTargets = ({
65280
65269
  }
65281
65270
  const key6 = stringifySequenceSubscriptionKey3(nodePath);
65282
65271
  if (!targets.has(key6)) {
65283
- const descendants = sequences.filter((candidate) => {
65284
- let parentId = candidate.id;
65285
- while (parentId !== null) {
65286
- if (parentId === originalSequence.id) {
65287
- return true;
65288
- }
65289
- parentId = sequences.find((sequence) => sequence.id === parentId)?.parent ?? null;
65290
- }
65291
- return false;
65292
- });
65293
- const descendantKeyframes = descendants.flatMap((sequence) => {
65294
- const overrideId = sequence.controls?.overrideId;
65295
- const descendantNodePath = overrideId ? overrideIdsToNodePaths[overrideId] : undefined;
65296
- if (descendantNodePath === undefined) {
65297
- return [];
65298
- }
65299
- const descendantNodePathKey = stringifySequenceSubscriptionKey3(descendantNodePath);
65300
- if (includedKeyframeNodePaths.has(descendantNodePathKey)) {
65301
- return [];
65302
- }
65303
- includedKeyframeNodePaths.add(descendantNodePathKey);
65304
- return [
65305
- getKeyframedSequenceDragTargets({
65306
- nodePath: descendantNodePath,
65307
- sequence,
65308
- propStatuses
65309
- })
65310
- ];
65272
+ const { effectKeyframes, sequenceKeyframes } = getKeyframedSequenceDragTargets({
65273
+ nodePath,
65274
+ sequence: originalSequence,
65275
+ propStatuses
65311
65276
  });
65312
- const effectKeyframes = descendantKeyframes.flatMap((descendant) => descendant.effectKeyframes);
65313
- const sequenceKeyframes = descendantKeyframes.flatMap((descendant) => descendant.sequenceKeyframes);
65314
65277
  targets.set(key6, {
65315
65278
  canSnapToTimelineStart: originalSequence.parent === null,
65316
65279
  effectKeyframes,
@@ -65346,16 +65309,9 @@ var clearFromDragOverrides = ({
65346
65309
  }) => {
65347
65310
  for (const target of targets) {
65348
65311
  clearDragOverrides(target.nodePath);
65349
- for (const keyframeTarget of target.sequenceKeyframes) {
65350
- clearDragOverrides(keyframeTarget.nodePath);
65351
- }
65352
- const effectIndexes = new Set(target.effectKeyframes.map((keyframe) => `${stringifySequenceSubscriptionKey3(keyframe.nodePath)}:${keyframe.effectIndex}`));
65353
- for (const keyframeTarget of target.effectKeyframes) {
65354
- const key6 = `${stringifySequenceSubscriptionKey3(keyframeTarget.nodePath)}:${keyframeTarget.effectIndex}`;
65355
- if (!effectIndexes.delete(key6)) {
65356
- continue;
65357
- }
65358
- clearEffectDragOverrides(keyframeTarget.nodePath, keyframeTarget.effectIndex);
65312
+ const effectIndexes = new Set(target.effectKeyframes.map((keyframe) => keyframe.effectIndex));
65313
+ for (const effectIndex of effectIndexes) {
65314
+ clearEffectDragOverrides(target.nodePath, effectIndex);
65359
65315
  }
65360
65316
  }
65361
65317
  };
@@ -65715,7 +65671,7 @@ var useTimelineSequenceFromDrag = ({
65715
65671
  });
65716
65672
  latestRef.current.setDragOverrides(target.nodePath, "from", Internals118.makeStaticDragOverride(nextFrom));
65717
65673
  for (const keyframeTarget of target.sequenceKeyframes) {
65718
- latestRef.current.setDragOverrides(keyframeTarget.nodePath, keyframeTarget.fieldKey, {
65674
+ latestRef.current.setDragOverrides(target.nodePath, keyframeTarget.fieldKey, {
65719
65675
  type: "keyframed",
65720
65676
  status: shiftKeyframedStatus({
65721
65677
  status: keyframeTarget.status,
@@ -65724,7 +65680,7 @@ var useTimelineSequenceFromDrag = ({
65724
65680
  });
65725
65681
  }
65726
65682
  for (const keyframeTarget of target.effectKeyframes) {
65727
- latestRef.current.setEffectDragOverrides(keyframeTarget.nodePath, keyframeTarget.effectIndex, keyframeTarget.fieldKey, {
65683
+ latestRef.current.setEffectDragOverrides(target.nodePath, keyframeTarget.effectIndex, keyframeTarget.fieldKey, {
65728
65684
  type: "keyframed",
65729
65685
  status: shiftKeyframedStatus({
65730
65686
  status: keyframeTarget.status,
@@ -65435,15 +65435,7 @@ var getKeyframedSequenceDragTargets = ({
65435
65435
  return { effectKeyframes: [], sequenceKeyframes: [] };
65436
65436
  }
65437
65437
  const sequenceSchema = sequence.controls?.schema;
65438
- const sequenceKeyframes = sequenceSchema === undefined ? [] : Object.entries(status.props).flatMap(([fieldKey, propStatus]) => propStatus.status === "keyframed" ? [
65439
- {
65440
- fileName: nodePath.absolutePath,
65441
- fieldKey,
65442
- nodePath,
65443
- schema: sequenceSchema,
65444
- status: propStatus
65445
- }
65446
- ] : []);
65438
+ const sequenceKeyframes = sequenceSchema === undefined ? [] : Object.entries(status.props).flatMap(([fieldKey, propStatus]) => propStatus.status === "keyframed" ? [{ fieldKey, schema: sequenceSchema, status: propStatus }] : []);
65447
65439
  const effectKeyframes = status.effects.flatMap((effectStatus) => {
65448
65440
  if (!effectStatus.canUpdate) {
65449
65441
  return [];
@@ -65455,9 +65447,7 @@ var getKeyframedSequenceDragTargets = ({
65455
65447
  return Object.entries(effectStatus.props).flatMap(([fieldKey, propStatus]) => propStatus.status === "keyframed" ? [
65456
65448
  {
65457
65449
  effectIndex: effectStatus.effectIndex,
65458
- fileName: nodePath.absolutePath,
65459
65450
  fieldKey,
65460
- nodePath,
65461
65451
  schema: effectSchema,
65462
65452
  status: propStatus
65463
65453
  }
@@ -65729,16 +65719,16 @@ var getTimelineSequenceFromDragKeyframeMoves = ({
65729
65719
  }
65730
65720
  return {
65731
65721
  sequenceKeyframes: targets.flatMap((target) => target.sequenceKeyframes.flatMap((keyframeTarget) => keyframeTarget.status.keyframes.map((keyframe) => ({
65732
- fileName: keyframeTarget.fileName,
65733
- nodePath: keyframeTarget.nodePath,
65722
+ fileName: target.fileName,
65723
+ nodePath: target.nodePath,
65734
65724
  fieldKey: keyframeTarget.fieldKey,
65735
65725
  fromFrame: keyframe.frame,
65736
65726
  toFrame: keyframe.frame + deltaFrames,
65737
65727
  schema: keyframeTarget.schema
65738
65728
  })))),
65739
65729
  effectKeyframes: targets.flatMap((target) => target.effectKeyframes.flatMap((keyframeTarget) => keyframeTarget.status.keyframes.map((keyframe) => ({
65740
- fileName: keyframeTarget.fileName,
65741
- nodePath: keyframeTarget.nodePath,
65730
+ fileName: target.fileName,
65731
+ nodePath: target.nodePath,
65742
65732
  effectIndex: keyframeTarget.effectIndex,
65743
65733
  fieldKey: keyframeTarget.fieldKey,
65744
65734
  fromFrame: keyframe.frame,
@@ -65877,7 +65867,6 @@ var getTimelineSequenceFromDragTargets = ({
65877
65867
  const targetNodePathInfos = draggedItemIsSelected && selectedSequenceItems.length > 1 ? selectedSequenceItems.map((item2) => item2.nodePathInfo) : [draggedNodePathInfo];
65878
65868
  const tracks = calculateTimeline({ sequences, overrideIdsToNodePaths });
65879
65869
  const targets = new Map;
65880
- const includedKeyframeNodePaths = new Set;
65881
65870
  for (const nodePathInfo of targetNodePathInfos) {
65882
65871
  const track = findSequenceTrack({ tracks, nodePathInfo });
65883
65872
  const originalSequence = track ? sequences.find((sequence) => sequence.id === track.sequence.id) : null;
@@ -65890,37 +65879,11 @@ var getTimelineSequenceFromDragTargets = ({
65890
65879
  }
65891
65880
  const key6 = stringifySequenceSubscriptionKey3(nodePath);
65892
65881
  if (!targets.has(key6)) {
65893
- const descendants = sequences.filter((candidate) => {
65894
- let parentId = candidate.id;
65895
- while (parentId !== null) {
65896
- if (parentId === originalSequence.id) {
65897
- return true;
65898
- }
65899
- parentId = sequences.find((sequence) => sequence.id === parentId)?.parent ?? null;
65900
- }
65901
- return false;
65902
- });
65903
- const descendantKeyframes = descendants.flatMap((sequence) => {
65904
- const overrideId = sequence.controls?.overrideId;
65905
- const descendantNodePath = overrideId ? overrideIdsToNodePaths[overrideId] : undefined;
65906
- if (descendantNodePath === undefined) {
65907
- return [];
65908
- }
65909
- const descendantNodePathKey = stringifySequenceSubscriptionKey3(descendantNodePath);
65910
- if (includedKeyframeNodePaths.has(descendantNodePathKey)) {
65911
- return [];
65912
- }
65913
- includedKeyframeNodePaths.add(descendantNodePathKey);
65914
- return [
65915
- getKeyframedSequenceDragTargets({
65916
- nodePath: descendantNodePath,
65917
- sequence,
65918
- propStatuses
65919
- })
65920
- ];
65882
+ const { effectKeyframes, sequenceKeyframes } = getKeyframedSequenceDragTargets({
65883
+ nodePath,
65884
+ sequence: originalSequence,
65885
+ propStatuses
65921
65886
  });
65922
- const effectKeyframes = descendantKeyframes.flatMap((descendant) => descendant.effectKeyframes);
65923
- const sequenceKeyframes = descendantKeyframes.flatMap((descendant) => descendant.sequenceKeyframes);
65924
65887
  targets.set(key6, {
65925
65888
  canSnapToTimelineStart: originalSequence.parent === null,
65926
65889
  effectKeyframes,
@@ -65956,16 +65919,9 @@ var clearFromDragOverrides = ({
65956
65919
  }) => {
65957
65920
  for (const target of targets) {
65958
65921
  clearDragOverrides(target.nodePath);
65959
- for (const keyframeTarget of target.sequenceKeyframes) {
65960
- clearDragOverrides(keyframeTarget.nodePath);
65961
- }
65962
- const effectIndexes = new Set(target.effectKeyframes.map((keyframe) => `${stringifySequenceSubscriptionKey3(keyframe.nodePath)}:${keyframe.effectIndex}`));
65963
- for (const keyframeTarget of target.effectKeyframes) {
65964
- const key6 = `${stringifySequenceSubscriptionKey3(keyframeTarget.nodePath)}:${keyframeTarget.effectIndex}`;
65965
- if (!effectIndexes.delete(key6)) {
65966
- continue;
65967
- }
65968
- clearEffectDragOverrides(keyframeTarget.nodePath, keyframeTarget.effectIndex);
65922
+ const effectIndexes = new Set(target.effectKeyframes.map((keyframe) => keyframe.effectIndex));
65923
+ for (const effectIndex of effectIndexes) {
65924
+ clearEffectDragOverrides(target.nodePath, effectIndex);
65969
65925
  }
65970
65926
  }
65971
65927
  };
@@ -66325,7 +66281,7 @@ var useTimelineSequenceFromDrag = ({
66325
66281
  });
66326
66282
  latestRef.current.setDragOverrides(target.nodePath, "from", Internals118.makeStaticDragOverride(nextFrom));
66327
66283
  for (const keyframeTarget of target.sequenceKeyframes) {
66328
- latestRef.current.setDragOverrides(keyframeTarget.nodePath, keyframeTarget.fieldKey, {
66284
+ latestRef.current.setDragOverrides(target.nodePath, keyframeTarget.fieldKey, {
66329
66285
  type: "keyframed",
66330
66286
  status: shiftKeyframedStatus({
66331
66287
  status: keyframeTarget.status,
@@ -66334,7 +66290,7 @@ var useTimelineSequenceFromDrag = ({
66334
66290
  });
66335
66291
  }
66336
66292
  for (const keyframeTarget of target.effectKeyframes) {
66337
- latestRef.current.setEffectDragOverrides(keyframeTarget.nodePath, keyframeTarget.effectIndex, keyframeTarget.fieldKey, {
66293
+ latestRef.current.setEffectDragOverrides(target.nodePath, keyframeTarget.effectIndex, keyframeTarget.fieldKey, {
66338
66294
  type: "keyframed",
66339
66295
  status: shiftKeyframedStatus({
66340
66296
  status: keyframeTarget.status,
@@ -214,7 +214,7 @@ var renderContent = (Root) => {
214
214
  renderToDOM(/* @__PURE__ */ jsx("div", {
215
215
  children: /* @__PURE__ */ jsx(DelayedSpinner, {})
216
216
  }));
217
- import("./chunk-axbagh08.js").then(({ StudioInternals }) => {
217
+ import("./chunk-s8gwjng0.js").then(({ StudioInternals }) => {
218
218
  window.remotion_isStudio = true;
219
219
  window.remotion_isReadOnlyStudio = true;
220
220
  window.remotion_inputProps = "{}";
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "url": "https://github.com/remotion-dev/remotion/tree/main/packages/studio"
4
4
  },
5
5
  "name": "@remotion/studio",
6
- "version": "4.0.510",
6
+ "version": "4.0.511",
7
7
  "description": "APIs for interacting with the Remotion Studio",
8
8
  "main": "dist",
9
9
  "scripts": {
@@ -24,17 +24,17 @@
24
24
  "react-dom": ">=16.8.0"
25
25
  },
26
26
  "dependencies": {
27
- "@remotion/studio-protocol": "4.0.510",
27
+ "@remotion/studio-protocol": "4.0.511",
28
28
  "semver": "7.5.3",
29
- "remotion": "4.0.510",
30
- "@remotion/captions": "4.0.510",
31
- "@remotion/player": "4.0.510",
32
- "@remotion/media-utils": "4.0.510",
33
- "@remotion/renderer": "4.0.510",
34
- "@remotion/web-renderer": "4.0.510",
35
- "@remotion/studio-shared": "4.0.510",
36
- "@remotion/timeline-utils": "4.0.510",
37
- "@remotion/zod-types": "4.0.510",
29
+ "remotion": "4.0.511",
30
+ "@remotion/captions": "4.0.511",
31
+ "@remotion/player": "4.0.511",
32
+ "@remotion/media-utils": "4.0.511",
33
+ "@remotion/renderer": "4.0.511",
34
+ "@remotion/web-renderer": "4.0.511",
35
+ "@remotion/studio-shared": "4.0.511",
36
+ "@remotion/timeline-utils": "4.0.511",
37
+ "@remotion/zod-types": "4.0.511",
38
38
  "@jridgewell/trace-mapping": "0.3.31",
39
39
  "mediabunny": "1.50.8",
40
40
  "memfs": "3.4.3",
@@ -45,7 +45,7 @@
45
45
  "react": "19.2.3",
46
46
  "react-dom": "19.2.3",
47
47
  "@types/semver": "7.5.3",
48
- "@remotion/eslint-config-internal": "4.0.510",
48
+ "@remotion/eslint-config-internal": "4.0.511",
49
49
  "eslint": "9.19.0",
50
50
  "@typescript/native-preview": "7.0.0-dev.20260217.1"
51
51
  },