@remotion/studio 4.0.513 → 4.0.515

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 (204) hide show
  1. package/dist/Studio.js +2 -1
  2. package/dist/api/install-package.js +14 -1
  3. package/dist/components/AskAiModal.js +1 -1
  4. package/dist/components/AssetSelector.js +2 -0
  5. package/dist/components/AssetSelectorItem.d.ts +2 -1
  6. package/dist/components/AssetSelectorItem.js +19 -16
  7. package/dist/components/AudioWaveform.d.ts +3 -0
  8. package/dist/components/AudioWaveform.js +65 -199
  9. package/dist/components/Canvas.js +40 -5
  10. package/dist/components/CanvasOrLoading.js +5 -0
  11. package/dist/components/CompositionSelector.js +2 -0
  12. package/dist/components/ConfigureDefaultEditorModal.js +17 -11
  13. package/dist/components/Editor.js +16 -1
  14. package/dist/components/ElementInstallConfirmation.d.ts +1 -0
  15. package/dist/components/ElementInstallConfirmation.js +4 -2
  16. package/dist/components/FixComputedValueModal.d.ts +9 -0
  17. package/dist/components/FixComputedValueModal.js +217 -0
  18. package/dist/components/InitialCompositionLoader.js +19 -0
  19. package/dist/components/InlineDropdown.js +4 -4
  20. package/dist/components/InspectorInfoHeader.js +3 -3
  21. package/dist/components/InspectorOpenInEditor.js +3 -1
  22. package/dist/components/InspectorPanel/CompositionInspector.js +37 -5
  23. package/dist/components/InspectorPanel/CompositionInspectorHeader.js +2 -2
  24. package/dist/components/InspectorPanel/ConnectedCompositionsSection.js +1 -1
  25. package/dist/components/InspectorPanel/EasingInspector.js +1 -1
  26. package/dist/components/InspectorPanel/KeyframeInspector.js +2 -2
  27. package/dist/components/InspectorPanel/SequenceInspectorHeader.js +1 -1
  28. package/dist/components/InspectorPanel/SequenceSelectionInspector.js +35 -6
  29. package/dist/components/InspectorPanel/common.d.ts +5 -5
  30. package/dist/components/InspectorPanel/common.js +8 -8
  31. package/dist/components/InspectorPanel/styles.d.ts +1 -1
  32. package/dist/components/InspectorPanel/styles.js +4 -2
  33. package/dist/components/InspectorSourceLocation.d.ts +1 -1
  34. package/dist/components/InspectorSourceLocation.js +2 -2
  35. package/dist/components/InstallPackage.d.ts +1 -1
  36. package/dist/components/InstallPackage.js +38 -6
  37. package/dist/components/LicenseKeyValidation.js +2 -2
  38. package/dist/components/Menu/MenuDivider.js +1 -1
  39. package/dist/components/Modals.js +11 -3
  40. package/dist/components/NewComposition/CodemodFooter.d.ts +1 -0
  41. package/dist/components/NewComposition/CodemodFooter.js +10 -8
  42. package/dist/components/NewComposition/DeleteComposition.js +1 -1
  43. package/dist/components/NewComposition/DeleteFolder.js +1 -1
  44. package/dist/components/NewComposition/DuplicateComposition.js +7 -2
  45. package/dist/components/NewComposition/NewComposition.js +1 -1
  46. package/dist/components/NewComposition/NewFolder.js +1 -1
  47. package/dist/components/NewComposition/RenameComposition.js +1 -1
  48. package/dist/components/NewComposition/RenameFolder.js +1 -1
  49. package/dist/components/NewComposition/duplicate-composition-api.d.ts +16 -0
  50. package/dist/components/NewComposition/duplicate-composition-api.js +16 -0
  51. package/dist/components/NoRegisterRoot.js +1 -1
  52. package/dist/components/QuickSwitcher/ExplorerQuickSwitcherTrigger.js +4 -3
  53. package/dist/components/QuickSwitcher/QuickSwitcherContent.js +1 -0
  54. package/dist/components/QuickSwitcher/fuzzy-search.js +1 -1
  55. package/dist/components/RefreshCompositionOverlay.js +1 -1
  56. package/dist/components/RenderButton.js +6 -3
  57. package/dist/components/RenderModal/GuiRenderStatus.js +3 -1
  58. package/dist/components/RenderModal/RenderModalOutputName.js +3 -3
  59. package/dist/components/RenderModal/WebRenderModal.js +10 -4
  60. package/dist/components/RenderModal/WebRenderModalAdvanced.d.ts +2 -0
  61. package/dist/components/RenderModal/WebRenderModalAdvanced.js +9 -2
  62. package/dist/components/RenderModal/render-modals.js +5 -1
  63. package/dist/components/RenderQueue/ClientRenderQueueProcessor.js +5 -1
  64. package/dist/components/RenderQueue/RenderQueueItem.js +3 -1
  65. package/dist/components/RenderQueue/RenderQueueOpenInFolder.js +3 -1
  66. package/dist/components/RenderQueue/RenderQueueRemoveItem.js +1 -1
  67. package/dist/components/RenderQueue/actions.js +12 -2
  68. package/dist/components/RenderQueue/client-side-render-types.d.ts +1 -0
  69. package/dist/components/RenderingSettings.d.ts +2 -0
  70. package/dist/components/RenderingSettings.js +355 -0
  71. package/dist/components/SelectedOutlineCanvasRotation.d.ts +1 -0
  72. package/dist/components/SelectedOutlineCanvasRotation.js +11 -4
  73. package/dist/components/SelectedOutlineElement.js +3 -3
  74. package/dist/components/SelectedOutlinePolygon.d.ts +2 -0
  75. package/dist/components/SelectedOutlinePolygon.js +54 -9
  76. package/dist/components/SettingsContext.d.ts +4 -1
  77. package/dist/components/SettingsContext.js +9 -2
  78. package/dist/components/SettingsModal.d.ts +1 -1
  79. package/dist/components/SettingsModal.js +10 -1
  80. package/dist/components/SettingsModalFooter.js +1 -1
  81. package/dist/components/StudioSettings.d.ts +2 -0
  82. package/dist/components/StudioSettings.js +185 -0
  83. package/dist/components/Timeline/LoopedIndicator.js +1 -1
  84. package/dist/components/Timeline/LoopedTimelineIndicators.d.ts +3 -0
  85. package/dist/components/Timeline/LoopedTimelineIndicators.js +22 -14
  86. package/dist/components/Timeline/Timeline.js +11 -9
  87. package/dist/components/Timeline/TimelineAssetField.d.ts +2 -2
  88. package/dist/components/Timeline/TimelineAssetField.js +1 -1
  89. package/dist/components/Timeline/TimelineClipboardKeybindings.js +6 -2
  90. package/dist/components/Timeline/TimelineDragHandler.js +62 -76
  91. package/dist/components/Timeline/TimelineEffectItem.js +23 -6
  92. package/dist/components/Timeline/TimelineEffectPropItem.d.ts +4 -2
  93. package/dist/components/Timeline/TimelineEffectPropItem.js +22 -13
  94. package/dist/components/Timeline/TimelineExpandArrowButton.js +10 -7
  95. package/dist/components/Timeline/TimelineExpandedKeyframeRow.js +4 -1
  96. package/dist/components/Timeline/TimelineExpandedRow.d.ts +1 -1
  97. package/dist/components/Timeline/TimelineExpandedRow.js +4 -4
  98. package/dist/components/Timeline/TimelineExpandedSection.js +8 -5
  99. package/dist/components/Timeline/TimelineHeightContainer.d.ts +0 -4
  100. package/dist/components/Timeline/TimelineHeightContainer.js +4 -4
  101. package/dist/components/Timeline/TimelineImageInfo.d.ts +1 -0
  102. package/dist/components/Timeline/TimelineImageInfo.js +3 -2
  103. package/dist/components/Timeline/TimelineKeyframeControls.js +6 -1
  104. package/dist/components/Timeline/TimelineList.d.ts +1 -5
  105. package/dist/components/Timeline/TimelineList.js +14 -9
  106. package/dist/components/Timeline/TimelinePinchZoom.js +5 -5
  107. package/dist/components/Timeline/TimelineRowChrome.d.ts +1 -2
  108. package/dist/components/Timeline/TimelineRowChrome.js +50 -7
  109. package/dist/components/Timeline/TimelineSchemaField.d.ts +7 -3
  110. package/dist/components/Timeline/TimelineSchemaField.js +71 -13
  111. package/dist/components/Timeline/TimelineScrollable.js +3 -1
  112. package/dist/components/Timeline/TimelineSelection.d.ts +13 -5
  113. package/dist/components/Timeline/TimelineSelection.js +95 -106
  114. package/dist/components/Timeline/TimelineSequence.js +59 -25
  115. package/dist/components/Timeline/TimelineSequenceItem.d.ts +1 -1
  116. package/dist/components/Timeline/TimelineSequenceItem.js +21 -12
  117. package/dist/components/Timeline/TimelineSequenceName.js +1 -1
  118. package/dist/components/Timeline/TimelineSequencePropItem.d.ts +2 -1
  119. package/dist/components/Timeline/TimelineSequencePropItem.js +3 -3
  120. package/dist/components/Timeline/TimelineSequenceRightEdgeDragHandle.js +33 -10
  121. package/dist/components/Timeline/TimelineSlider.js +42 -33
  122. package/dist/components/Timeline/TimelineTimeIndicators.js +90 -98
  123. package/dist/components/Timeline/TimelineTrack.js +4 -1
  124. package/dist/components/Timeline/TimelineTracks.d.ts +0 -2
  125. package/dist/components/Timeline/TimelineTracks.js +11 -4
  126. package/dist/components/Timeline/TimelineTransformOriginField.js +1 -1
  127. package/dist/components/Timeline/TimelineVideoInfo.d.ts +4 -4
  128. package/dist/components/Timeline/TimelineVideoInfo.js +155 -63
  129. package/dist/components/Timeline/TimelineViewport.d.ts +12 -0
  130. package/dist/components/Timeline/TimelineViewport.js +62 -0
  131. package/dist/components/Timeline/TimelineVirtualization.d.ts +22 -0
  132. package/dist/components/Timeline/TimelineVirtualization.js +144 -0
  133. package/dist/components/Timeline/TimelineZoomControls.js +16 -8
  134. package/dist/components/Timeline/call-add-keyframe.js +31 -3
  135. package/dist/components/Timeline/call-delete-keyframe.js +13 -3
  136. package/dist/components/Timeline/call-move-keyframe.js +11 -1
  137. package/dist/components/Timeline/call-update-keyframe-settings.js +31 -3
  138. package/dist/components/Timeline/delete-selected-timeline-item.js +8 -3
  139. package/dist/components/Timeline/duplicate-selected-timeline-item.js +4 -2
  140. package/dist/components/Timeline/get-timeline-keyframes.d.ts +1 -2
  141. package/dist/components/Timeline/get-timeline-keyframes.js +1 -8
  142. package/dist/components/Timeline/get-timeline-sequence-visible-layout.d.ts +30 -0
  143. package/dist/components/Timeline/get-timeline-sequence-visible-layout.js +61 -0
  144. package/dist/components/Timeline/save-effect-prop.js +3 -3
  145. package/dist/components/Timeline/split-selected-timeline-item.js +2 -2
  146. package/dist/components/Timeline/timeline-scroll-logic.d.ts +24 -0
  147. package/dist/components/Timeline/timeline-scroll-logic.js +127 -4
  148. package/dist/components/Timeline/use-timeline-height.d.ts +3 -5
  149. package/dist/components/Timeline/use-timeline-height.js +16 -18
  150. package/dist/components/UpdateCheck.d.ts +2 -10
  151. package/dist/components/UpdateCheck.js +8 -2
  152. package/dist/components/VisualControls/VisualControlHandle.js +8 -0
  153. package/dist/components/delete-jsx-node-api.d.ts +2 -0
  154. package/dist/components/delete-jsx-node-api.js +12 -0
  155. package/dist/components/effect-drag-and-drop.js +6 -3
  156. package/dist/components/effect-operations-api.d.ts +8 -0
  157. package/dist/components/effect-operations-api.js +52 -0
  158. package/dist/components/element-install-api.d.ts +3 -0
  159. package/dist/components/element-install-api.js +19 -0
  160. package/dist/components/import-assets.js +20 -9
  161. package/dist/components/reorder-sequence-api.d.ts +2 -0
  162. package/dist/components/reorder-sequence-api.js +12 -0
  163. package/dist/components/split-jsx-sequence-api.d.ts +2 -0
  164. package/dist/components/split-jsx-sequence-api.js +12 -0
  165. package/dist/components/split-video-from-audio-api.d.ts +2 -0
  166. package/dist/components/split-video-from-audio-api.js +12 -0
  167. package/dist/error-overlay/remotion-overlay/Overlay.js +1 -1
  168. package/dist/error-overlay/remotion-overlay/log-studio-error.js +4 -0
  169. package/dist/esm/{chunk-r46yxrjr.js → chunk-s6k99gh2.js} +1 -1
  170. package/dist/esm/{chunk-tv7r0jy3.js → chunk-v5a8vpv4.js} +11479 -7851
  171. package/dist/esm/index.mjs +7 -5
  172. package/dist/esm/internals.mjs +11479 -7851
  173. package/dist/esm/previewEntry.mjs +11311 -7683
  174. package/dist/esm/renderEntry.mjs +3 -4
  175. package/dist/helpers/browser-studio-operations.d.ts +5 -0
  176. package/dist/helpers/browser-studio-operations.js +27 -1
  177. package/dist/helpers/colors.d.ts +1 -1
  178. package/dist/helpers/colors.js +1 -1
  179. package/dist/helpers/get-timeline-max-zoom.d.ts +26 -0
  180. package/dist/helpers/get-timeline-max-zoom.js +45 -0
  181. package/dist/helpers/inject-css.js +7 -5
  182. package/dist/helpers/render-codec-label.d.ts +1 -1
  183. package/dist/helpers/retry-payload.js +1 -0
  184. package/dist/helpers/studio-runtime-config.d.ts +1 -1
  185. package/dist/helpers/studio-runtime-config.js +2 -3
  186. package/dist/helpers/timeline-layout.d.ts +3 -1
  187. package/dist/helpers/timeline-layout.js +6 -1
  188. package/dist/helpers/url-state.js +3 -2
  189. package/dist/helpers/use-max-media-duration.js +5 -3
  190. package/dist/helpers/use-media-metadata.js +37 -20
  191. package/dist/helpers/use-menu-structure.js +67 -84
  192. package/dist/helpers/use-runtime-values.d.ts +2 -1
  193. package/dist/helpers/use-runtime-values.js +7 -3
  194. package/dist/icons/cloud-download.d.ts +4 -0
  195. package/dist/icons/cloud-download.js +8 -0
  196. package/dist/icons/remotion-triangle.d.ts +2 -0
  197. package/dist/icons/remotion-triangle.js +7 -0
  198. package/dist/renderEntry.js +1 -1
  199. package/dist/state/composition-list.d.ts +13 -0
  200. package/dist/state/composition-list.js +21 -0
  201. package/dist/state/modals.d.ts +8 -2
  202. package/dist/state/timeline-zoom.d.ts +1 -2
  203. package/dist/state/timeline-zoom.js +9 -5
  204. package/package.json +14 -13
@@ -4,13 +4,12 @@ import {
4
4
  WHITE,
5
5
  __require,
6
6
  __toESM
7
- } from "./chunk-r46yxrjr.js";
7
+ } from "./chunk-s6k99gh2.js";
8
8
 
9
9
  // src/renderEntry.tsx
10
10
  import { useContext, useEffect, useRef, useState } from "react";
11
11
  import ReactDOM from "react-dom/client";
12
12
  import {
13
- AbsoluteFill,
14
13
  getInputProps,
15
14
  getRemotionEnvironment,
16
15
  continueRender as globalContinueRender,
@@ -57,7 +56,7 @@ var DelayedSpinner = () => {
57
56
  if (!show) {
58
57
  return null;
59
58
  }
60
- return /* @__PURE__ */ jsx(AbsoluteFill, {
59
+ return /* @__PURE__ */ jsx(Internals.AbsoluteFillElement, {
61
60
  style: {
62
61
  justifyContent: "center",
63
62
  alignItems: "center",
@@ -214,7 +213,7 @@ var renderContent = (Root) => {
214
213
  renderToDOM(/* @__PURE__ */ jsx("div", {
215
214
  children: /* @__PURE__ */ jsx(DelayedSpinner, {})
216
215
  }));
217
- import("./chunk-tv7r0jy3.js").then(({ StudioInternals }) => {
216
+ import("./chunk-v5a8vpv4.js").then(({ StudioInternals }) => {
218
217
  window.remotion_isStudio = true;
219
218
  window.remotion_isReadOnlyStudio = true;
220
219
  window.remotion_inputProps = "{}";
@@ -1,3 +1,8 @@
1
1
  import type { BrowserStudioOperations } from '@remotion/studio-shared';
2
2
  export declare const BROWSER_STUDIO_OPERATIONS_READY_EVENT = "remotion-browser-studio-operations-ready";
3
3
  export declare const getBrowserStudioOperations: () => BrowserStudioOperations | null;
4
+ export declare const getBrowserStudioKeyframeOperations: () => import("@remotion/studio-shared").BrowserStudioKeyframeOperations | null;
5
+ export declare const getBrowserStudioEffectOperations: () => import("@remotion/studio-shared").BrowserStudioEffectOperations | null;
6
+ export declare const canUseKeyframeOperations: () => boolean;
7
+ export declare const canUseEffectOperations: () => boolean;
8
+ export declare const canInstallPackages: () => boolean;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getBrowserStudioOperations = exports.BROWSER_STUDIO_OPERATIONS_READY_EVENT = void 0;
3
+ exports.canInstallPackages = exports.canUseEffectOperations = exports.canUseKeyframeOperations = exports.getBrowserStudioEffectOperations = exports.getBrowserStudioKeyframeOperations = exports.getBrowserStudioOperations = exports.BROWSER_STUDIO_OPERATIONS_READY_EVENT = void 0;
4
4
  // Browser Studio may be hosted by a different studio-shared version, so this
5
5
  // handshake intentionally has no shared runtime import.
6
6
  exports.BROWSER_STUDIO_OPERATIONS_READY_EVENT = 'remotion-browser-studio-operations-ready';
@@ -12,3 +12,29 @@ const getBrowserStudioOperations = () => {
12
12
  return (_a = window.remotion_browserStudio) !== null && _a !== void 0 ? _a : null;
13
13
  };
14
14
  exports.getBrowserStudioOperations = getBrowserStudioOperations;
15
+ const getBrowserStudioKeyframeOperations = () => {
16
+ var _a;
17
+ var _b;
18
+ return (_b = (_a = (0, exports.getBrowserStudioOperations)()) === null || _a === void 0 ? void 0 : _a.keyframes) !== null && _b !== void 0 ? _b : null;
19
+ };
20
+ exports.getBrowserStudioKeyframeOperations = getBrowserStudioKeyframeOperations;
21
+ const getBrowserStudioEffectOperations = () => {
22
+ var _a;
23
+ var _b;
24
+ return (_b = (_a = (0, exports.getBrowserStudioOperations)()) === null || _a === void 0 ? void 0 : _a.effects) !== null && _b !== void 0 ? _b : null;
25
+ };
26
+ exports.getBrowserStudioEffectOperations = getBrowserStudioEffectOperations;
27
+ const canUseKeyframeOperations = () => !window.remotion_isReadOnlyStudio ||
28
+ (0, exports.getBrowserStudioKeyframeOperations)() !== null;
29
+ exports.canUseKeyframeOperations = canUseKeyframeOperations;
30
+ const canUseEffectOperations = () => !window.remotion_isReadOnlyStudio ||
31
+ (0, exports.getBrowserStudioEffectOperations)() !== null;
32
+ exports.canUseEffectOperations = canUseEffectOperations;
33
+ const canInstallPackages = () => {
34
+ const browserStudioOperations = (0, exports.getBrowserStudioOperations)();
35
+ if (browserStudioOperations !== null) {
36
+ return true;
37
+ }
38
+ return !window.remotion_isReadOnlyStudio;
39
+ };
40
+ exports.canInstallPackages = canInstallPackages;
@@ -62,7 +62,7 @@ export declare const ERROR_LINK_COLOR = "#58a6ff";
62
62
  export declare const INFO_BLUE = "#60a5fa";
63
63
  export declare const SERVER_DISCONNECTED_BACKGROUND = "#e74c3c";
64
64
  export declare const STACK_FRAME_BORDER_BLUE = "rgb(66, 144, 245)";
65
- export declare const TIMELINE_BACKGROUND_COLOR = "#0F1113";
65
+ export declare const TIMELINE_BACKGROUND_COLOR = "#15181B";
66
66
  export declare const TIMELINE_SELECTED_BACKGROUND_COLOR = "#3B3F42";
67
67
  export declare const TIMELINE_SELECTED_LABEL_BACKGROUND_COLOR = "#B0B0B0";
68
68
  export declare const TIMELINE_BLUE = "#0b84ff";
@@ -68,7 +68,7 @@ exports.ERROR_LINK_COLOR = '#58a6ff';
68
68
  exports.INFO_BLUE = '#60a5fa';
69
69
  exports.SERVER_DISCONNECTED_BACKGROUND = '#e74c3c';
70
70
  exports.STACK_FRAME_BORDER_BLUE = 'rgb(66, 144, 245)';
71
- exports.TIMELINE_BACKGROUND_COLOR = '#0F1113';
71
+ exports.TIMELINE_BACKGROUND_COLOR = '#15181B';
72
72
  exports.TIMELINE_SELECTED_BACKGROUND_COLOR = '#3B3F42';
73
73
  exports.TIMELINE_SELECTED_LABEL_BACKGROUND_COLOR = '#B0B0B0';
74
74
  exports.TIMELINE_BLUE = '#0b84ff';
@@ -0,0 +1,26 @@
1
+ export declare const TIMELINE_MIN_ZOOM = 1;
2
+ export declare const TIMELINE_MAX_ZOOM_FLOOR = 5;
3
+ /**
4
+ * How many frames fill the timeline viewport at max zoom.
5
+ * 30 frames matches the previous 5x cap on a 150-frame composition
6
+ * (5 seconds at 30fps) and keeps a single frame wide enough to trim.
7
+ */
8
+ export declare const TIMELINE_FRAMES_VISIBLE_AT_MAX_ZOOM = 30;
9
+ export declare const getTimelineMaxZoom: (durationInFrames: number) => number;
10
+ export declare const clampTimelineZoom: ({ zoom, durationInFrames, }: {
11
+ zoom: number;
12
+ durationInFrames: number;
13
+ }) => number;
14
+ export declare const timelineZoomToSliderValue: ({ zoom, maxZoom, }: {
15
+ zoom: number;
16
+ maxZoom: number;
17
+ }) => number;
18
+ export declare const sliderValueToTimelineZoom: ({ sliderValue, maxZoom, }: {
19
+ sliderValue: number;
20
+ maxZoom: number;
21
+ }) => number;
22
+ export declare const TIMELINE_ZOOM_SLIDER_PROPS: {
23
+ readonly min: 0;
24
+ readonly max: 1000;
25
+ readonly step: 1;
26
+ };
@@ -0,0 +1,45 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TIMELINE_ZOOM_SLIDER_PROPS = exports.sliderValueToTimelineZoom = exports.timelineZoomToSliderValue = exports.clampTimelineZoom = exports.getTimelineMaxZoom = exports.TIMELINE_FRAMES_VISIBLE_AT_MAX_ZOOM = exports.TIMELINE_MAX_ZOOM_FLOOR = exports.TIMELINE_MIN_ZOOM = void 0;
4
+ exports.TIMELINE_MIN_ZOOM = 1;
5
+ exports.TIMELINE_MAX_ZOOM_FLOOR = 5;
6
+ /**
7
+ * How many frames fill the timeline viewport at max zoom.
8
+ * 30 frames matches the previous 5x cap on a 150-frame composition
9
+ * (5 seconds at 30fps) and keeps a single frame wide enough to trim.
10
+ */
11
+ exports.TIMELINE_FRAMES_VISIBLE_AT_MAX_ZOOM = 30;
12
+ const TIMELINE_ZOOM_SLIDER_MAX = 1000;
13
+ const getTimelineMaxZoom = (durationInFrames) => {
14
+ const frameLevelZoom = durationInFrames / exports.TIMELINE_FRAMES_VISIBLE_AT_MAX_ZOOM;
15
+ return Math.max(exports.TIMELINE_MAX_ZOOM_FLOOR, Math.ceil(frameLevelZoom * 10) / 10);
16
+ };
17
+ exports.getTimelineMaxZoom = getTimelineMaxZoom;
18
+ const clampTimelineZoom = ({ zoom, durationInFrames, }) => {
19
+ const clamped = Math.min((0, exports.getTimelineMaxZoom)(durationInFrames), Math.max(exports.TIMELINE_MIN_ZOOM, zoom));
20
+ return Math.round(clamped * 10) / 10;
21
+ };
22
+ exports.clampTimelineZoom = clampTimelineZoom;
23
+ const timelineZoomToSliderValue = ({ zoom, maxZoom, }) => {
24
+ if (maxZoom <= exports.TIMELINE_MIN_ZOOM) {
25
+ return 0;
26
+ }
27
+ const clampedZoom = Math.min(maxZoom, Math.max(exports.TIMELINE_MIN_ZOOM, zoom));
28
+ const t = Math.log(clampedZoom / exports.TIMELINE_MIN_ZOOM) /
29
+ Math.log(maxZoom / exports.TIMELINE_MIN_ZOOM);
30
+ return Math.round(t * TIMELINE_ZOOM_SLIDER_MAX);
31
+ };
32
+ exports.timelineZoomToSliderValue = timelineZoomToSliderValue;
33
+ const sliderValueToTimelineZoom = ({ sliderValue, maxZoom, }) => {
34
+ if (maxZoom <= exports.TIMELINE_MIN_ZOOM) {
35
+ return exports.TIMELINE_MIN_ZOOM;
36
+ }
37
+ const t = sliderValue / TIMELINE_ZOOM_SLIDER_MAX;
38
+ return exports.TIMELINE_MIN_ZOOM * (maxZoom / exports.TIMELINE_MIN_ZOOM) ** t;
39
+ };
40
+ exports.sliderValueToTimelineZoom = sliderValueToTimelineZoom;
41
+ exports.TIMELINE_ZOOM_SLIDER_PROPS = {
42
+ min: 0,
43
+ max: TIMELINE_ZOOM_SLIDER_MAX,
44
+ step: 1,
45
+ };
@@ -58,22 +58,24 @@ const makeDefaultGlobalCSS = () => {
58
58
 
59
59
  input:focus,
60
60
  textarea:focus,
61
- button:focus:not(.__remotion_input_dragger):not(.__remotion_color_swatch):not(.__remotion-inspector-section-title),
61
+ button:focus:not(.__remotion_input_dragger):not(.__remotion_color_swatch):not(.__remotion-inspector-section-title):not(.__remotion-timeline-expand-arrow-button),
62
62
  a:focus {
63
63
  outline: none;
64
64
  box-shadow: ${colors_1.FOCUS_BOX_SHADOW};
65
65
  }
66
66
 
67
67
  .__remotion-composition-selector-item:focus,
68
- .__remotion-inspector-inline-action:focus,
69
- .__remotion-inspector-section-title:focus {
68
+ .__remotion-inspector-quick-action:focus,
69
+ .__remotion-inspector-section-title:focus,
70
+ .__remotion-timeline-expand-arrow-button:focus {
70
71
  outline: none;
71
72
  box-shadow: none;
72
73
  }
73
74
 
74
75
  .__remotion-composition-selector-item:focus-visible,
75
- .__remotion-inspector-inline-action:focus-visible,
76
- .__remotion-inspector-section-title:focus-visible {
76
+ .__remotion-inspector-quick-action:focus-visible,
77
+ .__remotion-inspector-section-title:focus-visible,
78
+ .__remotion-timeline-expand-arrow-button:focus-visible {
77
79
  box-shadow: ${colors_1.FOCUS_BOX_SHADOW};
78
80
  }
79
81
 
@@ -1,2 +1,2 @@
1
- export declare const renderHumanReadableAudioCodec: (codec: "aac" | "ac3" | "alaw" | "eac3" | "flac" | "mp3" | "opus" | "pcm-f32" | "pcm-f32be" | "pcm-f64" | "pcm-f64be" | "pcm-s16" | "pcm-s16be" | "pcm-s24" | "pcm-s24be" | "pcm-s32" | "pcm-s32be" | "pcm-s8" | "pcm-u8" | "ulaw" | "vorbis" | null) => string;
1
+ export declare const renderHumanReadableAudioCodec: (codec: "aac" | "ac3" | "alaw" | "dts" | "eac3" | "flac" | "mp3" | "opus" | "pcm-f32" | "pcm-f32be" | "pcm-f64" | "pcm-f64be" | "pcm-s16" | "pcm-s16be" | "pcm-s24" | "pcm-s24be" | "pcm-s32" | "pcm-s32be" | "pcm-s8" | "pcm-u8" | "ulaw" | "vorbis" | null) => string;
2
2
  export declare const renderHumanReadableVideoCodec: (codec: "av1" | "avc" | "hevc" | "prores" | "vp8" | "vp9" | null) => string;
@@ -201,6 +201,7 @@ const makeClientRetryPayload = (job) => {
201
201
  initialKeyframeIntervalInSeconds: job.type === 'client-video' ? job.keyframeIntervalInSeconds : null,
202
202
  initialMuted: job.type === 'client-video' ? job.muted : null,
203
203
  initialTransparent: job.type === 'client-video' ? job.transparent : null,
204
+ initialAllowHtmlInCanvas: job.allowHtmlInCanvas,
204
205
  initialPageResponsiveness: job.type === 'client-video' ? job.pageResponsiveness : 'disabled',
205
206
  };
206
207
  };
@@ -2,5 +2,5 @@ export declare const DEFAULT_BUFFER_STATE_DELAY_IN_MILLISECONDS = 300;
2
2
  export declare const getStudioAskAIEnabled: () => boolean;
3
3
  export declare const getStudioInteractivityEnabled: () => boolean;
4
4
  export declare const getStudioKeyboardShortcutsEnabled: () => boolean;
5
- export declare const getStudioMaxTimelineTracks: () => number;
5
+ export declare const getStudioMaxTimelineTracks: () => number | null;
6
6
  export declare const getStudioBufferStateDelayInMilliseconds: () => number;
@@ -1,7 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getStudioBufferStateDelayInMilliseconds = exports.getStudioMaxTimelineTracks = exports.getStudioKeyboardShortcutsEnabled = exports.getStudioInteractivityEnabled = exports.getStudioAskAIEnabled = exports.DEFAULT_BUFFER_STATE_DELAY_IN_MILLISECONDS = void 0;
4
- const studio_shared_1 = require("@remotion/studio-shared");
5
4
  exports.DEFAULT_BUFFER_STATE_DELAY_IN_MILLISECONDS = 300;
6
5
  const defaultStudioRuntimeConfig = {
7
6
  askAIEnabled: false,
@@ -12,6 +11,7 @@ const defaultStudioRuntimeConfig = {
12
11
  keyboardShortcutsEnabled: true,
13
12
  maxTimelineTracks: null,
14
13
  publicLicenseKey: null,
14
+ configFileStudioSettings: null,
15
15
  };
16
16
  const getStudioRuntimeConfig = () => {
17
17
  var _a;
@@ -33,8 +33,7 @@ const getStudioKeyboardShortcutsEnabled = () => {
33
33
  };
34
34
  exports.getStudioKeyboardShortcutsEnabled = getStudioKeyboardShortcutsEnabled;
35
35
  const getStudioMaxTimelineTracks = () => {
36
- var _a;
37
- return (_a = getStudioRuntimeConfig().maxTimelineTracks) !== null && _a !== void 0 ? _a : studio_shared_1.DEFAULT_TIMELINE_TRACKS;
36
+ return getStudioRuntimeConfig().maxTimelineTracks;
38
37
  };
39
38
  exports.getStudioMaxTimelineTracks = getStudioMaxTimelineTracks;
40
39
  const getStudioBufferStateDelayInMilliseconds = () => {
@@ -1,5 +1,5 @@
1
1
  import { type AnySchemaFieldInfo, type DragOverrides, type EffectSchemaFieldInfo, type InteractivitySchemaFieldInfo, type SchemaFieldGroup, type SchemaFieldGroupInfo, type PropStatuses, type SchemaFieldInfo, type SequenceControls, type SaveSequencePropSourceEdit } from '@remotion/studio-shared';
2
- import type { GetDragOverrides, GetEffectDragOverrides, InteractivitySchema as InteractivitySchemaShape, TSequence } from 'remotion';
2
+ import type { GetDragOverrides, GetEffectDragOverrides, InteractivitySchema as InteractivitySchemaShape, RuntimeValueStore, TSequence } from 'remotion';
3
3
  import type { GetIsExpanded } from '../components/ExpandedTracksProvider';
4
4
  import type { SequenceNodePathInfo } from './get-timeline-sequence-sort-key';
5
5
  export { SCHEMA_FIELD_GROUPS, getEffectFieldsToShow, getFieldsToShow, getSchemaFieldGroup, SCHEMA_FIELD_ROW_HEIGHT, } from '@remotion/studio-shared';
@@ -30,6 +30,8 @@ export type TimelineTreeNode = {
30
30
  readonly nodePathInfo: SequenceNodePathInfo;
31
31
  readonly label: string;
32
32
  readonly field: AnySchemaFieldInfo | null;
33
+ readonly runtimeValue: unknown;
34
+ readonly runtimeValueStore: RuntimeValueStore | null;
33
35
  };
34
36
  export declare const buildTimelineTree: ({ sequence, nodePathInfo, getDragOverrides, getEffectDragOverrides, propStatuses, includeTextContent, includeSourceControls, runtimeValues, }: {
35
37
  sequence: TSequence;
@@ -44,6 +44,8 @@ const buildTimelineTree = ({ sequence, nodePathInfo, getDragOverrides, getEffect
44
44
  },
45
45
  label: (_a = f.description) !== null && _a !== void 0 ? _a : f.key,
46
46
  field: f,
47
+ runtimeValue: runtimeValues === null || runtimeValues === void 0 ? void 0 : runtimeValues[f.key],
48
+ runtimeValueStore: null,
47
49
  });
48
50
  }
49
51
  }
@@ -85,6 +87,7 @@ const buildTimelineTree = ({ sequence, nodePathInfo, getDragOverrides, getEffect
85
87
  },
86
88
  children: effectFields.map((f) => {
87
89
  var _a;
90
+ var _b, _c;
88
91
  return ({
89
92
  kind: 'field',
90
93
  nodePathInfo: {
@@ -99,8 +102,10 @@ const buildTimelineTree = ({ sequence, nodePathInfo, getDragOverrides, getEffect
99
102
  numberOfSequencesWithThisNodePath: 0,
100
103
  supportsEffects,
101
104
  },
102
- label: (_a = f.description) !== null && _a !== void 0 ? _a : f.key,
105
+ label: (_b = f.description) !== null && _b !== void 0 ? _b : f.key,
103
106
  field: f,
107
+ runtimeValue: null,
108
+ runtimeValueStore: (_c = (_a = sequence.effectRuntimeValues) === null || _a === void 0 ? void 0 : _a[i]) !== null && _c !== void 0 ? _c : null,
104
109
  });
105
110
  }),
106
111
  };
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getRoute = exports.reloadUrl = exports.clearUrl = exports.replaceUrl = exports.pushUrl = exports.getUrlForRoute = void 0;
4
4
  const getUrlHandlingType = () => {
5
- if (window.remotion_isReadOnlyStudio) {
5
+ if (window.remotion_isReadOnlyStudio || window.remotion_browserStudio) {
6
6
  return 'query-string';
7
7
  }
8
8
  return 'spa';
@@ -32,7 +32,8 @@ const reloadUrl = () => {
32
32
  exports.reloadUrl = reloadUrl;
33
33
  const getRoute = () => {
34
34
  if (getUrlHandlingType() === 'query-string') {
35
- return window.location.search.substring(1);
35
+ const route = window.location.search.substring(1);
36
+ return route.startsWith('/') ? route : '';
36
37
  }
37
38
  return window.location.pathname;
38
39
  };
@@ -2,6 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.useMaxMediaDuration = void 0;
4
4
  const react_1 = require("react");
5
+ const remotion_1 = require("remotion");
5
6
  const is_video_with_last_frame_hold_1 = require("./is-video-with-last-frame-hold");
6
7
  const use_media_metadata_1 = require("./use-media-metadata");
7
8
  const cache = new Map();
@@ -19,7 +20,8 @@ const useMaxMediaDuration = (s, fps) => {
19
20
  var _a;
20
21
  const holdsLastFrame = (0, is_video_with_last_frame_hold_1.isVideoWithLastFrameHold)(s);
21
22
  const src = holdsLastFrame ? null : getSrc(s);
22
- const cacheKey = src ? getCacheKey(src, fps) : null;
23
+ const resolvedSrc = remotion_1.Internals.usePreload(src !== null && src !== void 0 ? src : '');
24
+ const cacheKey = src ? getCacheKey(resolvedSrc, fps) : null;
23
25
  const [maxMediaDuration, setMaxMediaDuration] = (0, react_1.useState)(cacheKey ? ((_a = cache.get(cacheKey)) !== null && _a !== void 0 ? _a : null) : Infinity);
24
26
  (0, react_1.useEffect)(() => {
25
27
  var _a;
@@ -32,7 +34,7 @@ const useMaxMediaDuration = (s, fps) => {
32
34
  return;
33
35
  }
34
36
  let cancelled = false;
35
- (0, use_media_metadata_1.getMediaMetadata)(src)
37
+ (0, use_media_metadata_1.getMediaMetadata)(resolvedSrc)
36
38
  .then((metadata) => {
37
39
  if (cancelled || !metadata) {
38
40
  return;
@@ -50,7 +52,7 @@ const useMaxMediaDuration = (s, fps) => {
50
52
  return () => {
51
53
  cancelled = true;
52
54
  };
53
- }, [cacheKey, fps, src]);
55
+ }, [cacheKey, fps, resolvedSrc, src]);
54
56
  if (holdsLastFrame) {
55
57
  return Infinity;
56
58
  }
@@ -4,6 +4,7 @@ exports.useMediaMetadata = exports.getMediaMetadata = exports.getCachedMediaMeta
4
4
  const media_utils_1 = require("@remotion/media-utils");
5
5
  const mediabunny_1 = require("mediabunny");
6
6
  const react_1 = require("react");
7
+ const remotion_1 = require("remotion");
7
8
  const get_duration_or_compute_1 = require("./get-duration-or-compute");
8
9
  const cache = new Map();
9
10
  const pendingRequests = new Map();
@@ -22,19 +23,38 @@ const safeCall = async (fn) => {
22
23
  };
23
24
  const getMediabunnyMetadata = async (src) => {
24
25
  var _a, _b;
25
- let input;
26
- try {
27
- input = new mediabunny_1.Input({
28
- formats: mediabunny_1.ALL_FORMATS,
29
- source: new mediabunny_1.UrlSource(src),
30
- });
31
- }
32
- catch (_c) {
26
+ const lease = (() => {
27
+ try {
28
+ return remotion_1.Internals.globalMediaResourceManager.acquire({
29
+ key: remotion_1.Internals.getMediabunnyInputResourceKey({
30
+ src,
31
+ credentials: null,
32
+ requestInitFingerprint: null,
33
+ revision: null,
34
+ }),
35
+ create: () => {
36
+ const createdInput = new mediabunny_1.Input({
37
+ formats: mediabunny_1.ALL_FORMATS,
38
+ source: new mediabunny_1.UrlSource(src),
39
+ });
40
+ return {
41
+ resource: createdInput,
42
+ dispose: () => createdInput.dispose(),
43
+ };
44
+ },
45
+ });
46
+ }
47
+ catch (_a) {
48
+ return null;
49
+ }
50
+ })();
51
+ if (lease === null) {
33
52
  return null;
34
53
  }
54
+ const input = lease.resource;
35
55
  try {
36
56
  const [duration, format, videoTrack, audioTrack] = await Promise.all([
37
- safeCall(() => (0, get_duration_or_compute_1.getDurationOrCompute)(input)),
57
+ safeCall(() => lease.getOrCreateValue(remotion_1.Internals.MEDIABUNNY_DURATION_VALUE_KEY, () => (0, get_duration_or_compute_1.getDurationOrCompute)(input))),
38
58
  safeCall(() => input.getFormat()),
39
59
  safeCall(() => input.getPrimaryVideoTrack()),
40
60
  safeCall(() => input.getPrimaryAudioTrack()),
@@ -66,12 +86,7 @@ const getMediabunnyMetadata = async (src) => {
66
86
  };
67
87
  }
68
88
  finally {
69
- try {
70
- input.dispose();
71
- }
72
- catch (_d) {
73
- // ignore
74
- }
89
+ lease.release();
75
90
  }
76
91
  };
77
92
  const getFallbackVideoMetadata = async (src) => {
@@ -121,15 +136,17 @@ const getMediaMetadata = (src) => {
121
136
  };
122
137
  exports.getMediaMetadata = getMediaMetadata;
123
138
  const useMediaMetadata = (src) => {
124
- const [mediaMetadata, setMediaMetadata] = (0, react_1.useState)(src ? (0, exports.getCachedMediaMetadata)(src) : null);
139
+ const resolvedSrc = remotion_1.Internals.usePreload(src !== null && src !== void 0 ? src : '');
140
+ const metadataSrc = src === null ? null : resolvedSrc;
141
+ const [mediaMetadata, setMediaMetadata] = (0, react_1.useState)(metadataSrc ? (0, exports.getCachedMediaMetadata)(metadataSrc) : null);
125
142
  (0, react_1.useEffect)(() => {
126
- const cached = src ? (0, exports.getCachedMediaMetadata)(src) : null;
143
+ const cached = metadataSrc ? (0, exports.getCachedMediaMetadata)(metadataSrc) : null;
127
144
  setMediaMetadata(cached);
128
- if (!src || cached) {
145
+ if (!metadataSrc || cached) {
129
146
  return;
130
147
  }
131
148
  let cancelled = false;
132
- (0, exports.getMediaMetadata)(src)
149
+ (0, exports.getMediaMetadata)(metadataSrc)
133
150
  .then((metadata) => {
134
151
  if (cancelled) {
135
152
  return;
@@ -145,7 +162,7 @@ const useMediaMetadata = (src) => {
145
162
  return () => {
146
163
  cancelled = true;
147
164
  };
148
- }, [src]);
165
+ }, [metadataSrc]);
149
166
  return mediaMetadata;
150
167
  };
151
168
  exports.useMediaMetadata = useMediaMetadata;