@remotion/studio 4.0.468 → 4.0.470
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.
- package/dist/Studio.js +1 -1
- package/dist/api/save-render-output.js +3 -12
- package/dist/components/AudioWaveform.d.ts +1 -0
- package/dist/components/AudioWaveform.js +41 -23
- package/dist/components/CompositionSelectorItem.js +1 -1
- package/dist/components/ContextMenu.d.ts +1 -0
- package/dist/components/ContextMenu.js +8 -3
- package/dist/components/EditorContent.js +5 -4
- package/dist/components/EditorGuides/Guide.js +1 -1
- package/dist/components/ExpandedTracksProvider.js +3 -8
- package/dist/components/Menu/MenuItem.d.ts +1 -1
- package/dist/components/Menu/MenuItem.js +2 -2
- package/dist/components/Menu/MenuSubItem.js +5 -5
- package/dist/components/MenuBuildIndicator.js +0 -1
- package/dist/components/NewComposition/InputDragger.js +1 -0
- package/dist/components/Preview.js +4 -1
- package/dist/components/PreviewToolbar.js +2 -4
- package/dist/components/SelectedOutlineOverlay.d.ts +18 -0
- package/dist/components/SelectedOutlineOverlay.js +645 -0
- package/dist/components/Timeline/Timeline.js +18 -3
- package/dist/components/Timeline/TimelineDeleteKeybindings.d.ts +2 -0
- package/dist/components/Timeline/TimelineDeleteKeybindings.js +86 -0
- package/dist/components/Timeline/TimelineDragHandler.js +19 -244
- package/dist/components/Timeline/{TimelineEffectGroupRow.d.ts → TimelineEffectItem.d.ts} +1 -1
- package/dist/components/Timeline/{TimelineEffectGroupRow.js → TimelineEffectItem.js} +61 -35
- package/dist/components/Timeline/{TimelineEffectFieldRow.d.ts → TimelineEffectPropItem.d.ts} +4 -1
- package/dist/components/Timeline/{TimelineEffectFieldRow.js → TimelineEffectPropItem.js} +100 -16
- package/dist/components/Timeline/TimelineExpandArrowButton.js +5 -1
- package/dist/components/Timeline/TimelineExpandedKeyframeRow.d.ts +11 -0
- package/dist/components/Timeline/TimelineExpandedKeyframeRow.js +55 -0
- package/dist/components/Timeline/TimelineExpandedRow.d.ts +1 -0
- package/dist/components/Timeline/TimelineExpandedRow.js +29 -11
- package/dist/components/Timeline/TimelineExpandedSection.d.ts +1 -0
- package/dist/components/Timeline/TimelineExpandedSection.js +4 -4
- package/dist/components/Timeline/TimelineExpandedTrackKeyframes.d.ts +1 -1
- package/dist/components/Timeline/TimelineExpandedTrackKeyframes.js +9 -120
- package/dist/components/Timeline/TimelineFieldLabel.d.ts +6 -0
- package/dist/components/Timeline/TimelineFieldLabel.js +30 -0
- package/dist/components/Timeline/TimelineInOutDragHandler.d.ts +2 -0
- package/dist/components/Timeline/TimelineInOutDragHandler.js +324 -0
- package/dist/components/Timeline/TimelineInOutPointer.js +3 -1
- package/dist/components/Timeline/TimelineInOutPointerHandle.d.ts +1 -0
- package/dist/components/Timeline/TimelineInOutPointerHandle.js +5 -4
- package/dist/components/Timeline/TimelineItemStack.d.ts +5 -0
- package/dist/components/Timeline/TimelineItemStack.js +82 -0
- package/dist/components/Timeline/TimelineKeyframeControls.d.ts +17 -0
- package/dist/components/Timeline/TimelineKeyframeControls.js +217 -0
- package/dist/components/Timeline/TimelineKeyframeDiamond.d.ts +7 -0
- package/dist/components/Timeline/TimelineKeyframeDiamond.js +88 -0
- package/dist/components/Timeline/TimelineKeyframedValue.d.ts +8 -0
- package/dist/components/Timeline/TimelineKeyframedValue.js +36 -0
- package/dist/components/Timeline/TimelineLayerEye.js +1 -0
- package/dist/components/Timeline/TimelineList.js +3 -11
- package/dist/components/Timeline/TimelineMediaInfo.d.ts +13 -1
- package/dist/components/Timeline/TimelineMediaInfo.js +33 -80
- package/dist/components/Timeline/TimelineRowChrome.d.ts +10 -1
- package/dist/components/Timeline/TimelineRowChrome.js +64 -6
- package/dist/components/Timeline/TimelineSchemaField.js +7 -2
- package/dist/components/Timeline/TimelineSelection.d.ts +85 -0
- package/dist/components/Timeline/TimelineSelection.js +417 -0
- package/dist/components/Timeline/TimelineSequence.d.ts +2 -0
- package/dist/components/Timeline/TimelineSequence.js +18 -6
- package/dist/components/Timeline/TimelineSequenceFrame.js +1 -0
- package/dist/components/Timeline/{TimelineListItem.d.ts → TimelineSequenceItem.d.ts} +2 -2
- package/dist/components/Timeline/{TimelineListItem.js → TimelineSequenceItem.js} +148 -63
- package/dist/components/Timeline/TimelineSequenceName.d.ts +7 -0
- package/dist/components/Timeline/TimelineSequenceName.js +50 -0
- package/dist/components/Timeline/{TimelineFieldRow.d.ts → TimelineSequencePropItem.d.ts} +5 -3
- package/dist/components/Timeline/TimelineSequencePropItem.js +183 -0
- package/dist/components/Timeline/TimelineTimeIndicators.js +0 -1
- package/dist/components/Timeline/TimelineTrack.d.ts +5 -0
- package/dist/components/Timeline/TimelineTrack.js +66 -0
- package/dist/components/Timeline/TimelineTracks.js +2 -16
- package/dist/components/Timeline/TimelineTranslateField.js +14 -22
- package/dist/components/Timeline/TimelineUvCoordinateField.d.ts +11 -0
- package/dist/components/Timeline/TimelineUvCoordinateField.js +126 -0
- package/dist/components/Timeline/TimelineVideoInfo.js +11 -12
- package/dist/components/Timeline/call-add-keyframe.d.ts +23 -0
- package/dist/components/Timeline/call-add-keyframe.js +54 -0
- package/dist/components/Timeline/call-delete-keyframe.d.ts +21 -0
- package/dist/components/Timeline/call-delete-keyframe.js +50 -0
- package/dist/components/Timeline/delete-selected-keyframe.d.ts +11 -0
- package/dist/components/Timeline/delete-selected-keyframe.js +51 -0
- package/dist/components/Timeline/delete-selected-timeline-item.d.ts +17 -0
- package/dist/components/Timeline/delete-selected-timeline-item.js +183 -0
- package/dist/components/Timeline/duplicate-selected-timeline-item.d.ts +13 -0
- package/dist/components/Timeline/duplicate-selected-timeline-item.js +66 -0
- package/dist/components/Timeline/find-track-for-node-path-info.d.ts +7 -0
- package/dist/components/Timeline/find-track-for-node-path-info.js +13 -0
- package/dist/components/Timeline/get-keyframe-navigation.d.ts +9 -0
- package/dist/components/Timeline/get-keyframe-navigation.js +26 -0
- package/dist/components/Timeline/get-node-keyframes.d.ts +11 -0
- package/dist/components/Timeline/get-node-keyframes.js +23 -0
- package/dist/components/Timeline/get-timeline-keyframes.js +6 -8
- package/dist/components/Timeline/parse-keyframe-field-from-node-path.d.ts +8 -0
- package/dist/components/Timeline/parse-keyframe-field-from-node-path.js +26 -0
- package/dist/components/Timeline/save-sequence-prop.d.ts +14 -2
- package/dist/components/Timeline/save-sequence-prop.js +42 -7
- package/dist/components/Timeline/timeline-field-row-layout.d.ts +1 -0
- package/dist/components/Timeline/timeline-field-row-layout.js +11 -1
- package/dist/components/Timeline/timeline-row-layout.d.ts +1 -0
- package/dist/components/Timeline/timeline-row-layout.js +2 -1
- package/dist/components/Timeline/timeline-translate-utils.d.ts +2 -0
- package/dist/components/Timeline/timeline-translate-utils.js +20 -0
- package/dist/components/Timeline/use-expanded-track-keyframe-rows.d.ts +17 -0
- package/dist/components/Timeline/use-expanded-track-keyframe-rows.js +52 -0
- package/dist/components/Timeline/use-open-sequence-in-editor.d.ts +6 -0
- package/dist/components/Timeline/use-open-sequence-in-editor.js +31 -0
- package/dist/components/composition-menu-items.js +32 -1
- package/dist/error-overlay/remotion-overlay/OpenInEditor.js +0 -1
- package/dist/esm/{chunk-8q828zk7.js → chunk-dny42qnq.js} +10566 -6221
- package/dist/esm/internals.mjs +10566 -6221
- package/dist/esm/previewEntry.mjs +10548 -6203
- package/dist/esm/renderEntry.mjs +3 -1
- package/dist/helpers/colors.d.ts +1 -1
- package/dist/helpers/colors.js +1 -1
- package/dist/helpers/format-file-location.d.ts +9 -0
- package/dist/helpers/format-file-location.js +27 -0
- package/dist/helpers/get-box-quads-polyfill-internals.d.ts +82 -0
- package/dist/helpers/get-box-quads-polyfill-internals.js +2395 -0
- package/dist/helpers/get-box-quads-ponyfill.d.ts +10 -0
- package/dist/helpers/get-box-quads-ponyfill.js +23 -0
- package/dist/helpers/open-in-editor.d.ts +1 -1
- package/dist/helpers/open-in-editor.js +11 -26
- package/dist/helpers/timeline-layout.d.ts +8 -7
- package/dist/helpers/timeline-layout.js +9 -8
- package/dist/helpers/timeline-node-path-key.d.ts +2 -0
- package/dist/helpers/timeline-node-path-key.js +10 -0
- package/dist/helpers/use-menu-structure.js +8 -16
- package/dist/renderEntry.js +2 -2
- package/package.json +10 -10
- package/dist/components/Timeline/TimelineFieldRow.js +0 -113
- package/dist/components/Timeline/TimelineStack/index.d.ts +0 -8
- package/dist/components/Timeline/TimelineStack/index.js +0 -119
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export type GetBoxQuadsBox = 'margin' | 'border' | 'padding' | 'content';
|
|
2
|
+
export type GetBoxQuadsPonyfillOptions = {
|
|
3
|
+
readonly box?: GetBoxQuadsBox;
|
|
4
|
+
readonly relativeTo?: Element;
|
|
5
|
+
};
|
|
6
|
+
/**
|
|
7
|
+
* Returns border/margin/padding/content box quads for an element.
|
|
8
|
+
* Uses the native API when available, otherwise the getBoxQuads ponyfill.
|
|
9
|
+
*/
|
|
10
|
+
export declare const getBoxQuadsPonyfill: (element: Element, options?: GetBoxQuadsPonyfillOptions | undefined) => readonly DOMQuad[] | null;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getBoxQuadsPonyfill = void 0;
|
|
4
|
+
const get_box_quads_polyfill_internals_js_1 = require("./get-box-quads-polyfill-internals.js");
|
|
5
|
+
const hasNativeGetBoxQuads = (element) => {
|
|
6
|
+
return (typeof element.getBoxQuads === 'function');
|
|
7
|
+
};
|
|
8
|
+
/**
|
|
9
|
+
* Returns border/margin/padding/content box quads for an element.
|
|
10
|
+
* Uses the native API when available, otherwise the getBoxQuads ponyfill.
|
|
11
|
+
*/
|
|
12
|
+
const getBoxQuadsPonyfill = (element, options) => {
|
|
13
|
+
try {
|
|
14
|
+
if (hasNativeGetBoxQuads(element)) {
|
|
15
|
+
return element.getBoxQuads(options);
|
|
16
|
+
}
|
|
17
|
+
return (0, get_box_quads_polyfill_internals_js_1.getBoxQuads)(element, options);
|
|
18
|
+
}
|
|
19
|
+
catch (_a) {
|
|
20
|
+
return null;
|
|
21
|
+
}
|
|
22
|
+
};
|
|
23
|
+
exports.getBoxQuadsPonyfill = getBoxQuadsPonyfill;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { SymbolicatedStackFrame } from '@remotion/studio-shared';
|
|
2
2
|
import type { OriginalPosition } from '../error-overlay/react-overlay/utils/get-source-map';
|
|
3
|
-
export declare const openInEditor: (stack: SymbolicatedStackFrame) => Promise<
|
|
3
|
+
export declare const openInEditor: (stack: SymbolicatedStackFrame) => Promise<import("@remotion/studio-shared").OpenInEditorResponse>;
|
|
4
4
|
export declare const openOriginalPositionInEditor: (originalPosition: OriginalPosition) => Promise<void>;
|
|
5
5
|
export declare const preloadCompositionComponentInfo: ({ compositionFile, compositionId, }: {
|
|
6
6
|
compositionFile: string;
|
|
@@ -1,22 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.openCompositionComponentInEditor = exports.preloadCompositionComponentInfo = exports.openOriginalPositionInEditor = exports.openInEditor = void 0;
|
|
4
|
+
const call_api_1 = require("../components/call-api");
|
|
4
5
|
const openInEditor = (stack) => {
|
|
5
6
|
const { originalFileName, originalLineNumber, originalColumnNumber, originalFunctionName, originalScriptCode, } = stack;
|
|
6
|
-
return
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
7
|
+
return (0, call_api_1.callApi)('/api/open-in-editor', {
|
|
8
|
+
stack: {
|
|
9
|
+
originalFileName,
|
|
10
|
+
originalLineNumber,
|
|
11
|
+
originalColumnNumber,
|
|
12
|
+
originalFunctionName,
|
|
13
|
+
originalScriptCode,
|
|
10
14
|
},
|
|
11
|
-
body: JSON.stringify({
|
|
12
|
-
stack: {
|
|
13
|
-
originalFileName,
|
|
14
|
-
originalLineNumber,
|
|
15
|
-
originalColumnNumber,
|
|
16
|
-
originalFunctionName,
|
|
17
|
-
originalScriptCode,
|
|
18
|
-
},
|
|
19
|
-
}),
|
|
20
15
|
});
|
|
21
16
|
};
|
|
22
17
|
exports.openInEditor = openInEditor;
|
|
@@ -44,20 +39,10 @@ const loadCompositionComponentInfo = async ({ compositionFile, compositionId, })
|
|
|
44
39
|
return existing;
|
|
45
40
|
}
|
|
46
41
|
const promise = (async () => {
|
|
47
|
-
const
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
'content-type': 'application/json',
|
|
51
|
-
},
|
|
52
|
-
body: JSON.stringify({
|
|
53
|
-
compositionFile,
|
|
54
|
-
compositionId,
|
|
55
|
-
}),
|
|
42
|
+
const body = await (0, call_api_1.callApi)('/api/composition-component-info', {
|
|
43
|
+
compositionFile,
|
|
44
|
+
compositionId,
|
|
56
45
|
});
|
|
57
|
-
const body = (await response.json());
|
|
58
|
-
if (!body.success) {
|
|
59
|
-
throw new Error(body.error);
|
|
60
|
-
}
|
|
61
46
|
return {
|
|
62
47
|
location: body.location,
|
|
63
48
|
canAddSequence: body.canAddSequence,
|
|
@@ -52,10 +52,11 @@ export declare const getExpandedTrackHeight: ({ sequence, nodePathInfo, getIsExp
|
|
|
52
52
|
getIsExpanded: GetIsExpanded;
|
|
53
53
|
codeValues: CodeValues;
|
|
54
54
|
}) => number;
|
|
55
|
-
export declare const
|
|
56
|
-
export declare const
|
|
57
|
-
export declare const
|
|
58
|
-
export declare const
|
|
59
|
-
export declare const
|
|
60
|
-
export declare const
|
|
61
|
-
export declare const
|
|
55
|
+
export declare const TIMELINE_LAYER_FILMSTRIP_HEIGHT = 26;
|
|
56
|
+
export declare const TIMELINE_VIDEO_INFO_WAVEFORM_HEIGHT = 17;
|
|
57
|
+
export declare const TIMELINE_LAYER_HEIGHT_VIDEO: number;
|
|
58
|
+
export declare const TIMELINE_LAYER_HEIGHT_IMAGE = 26;
|
|
59
|
+
export declare const TIMELINE_LAYER_HEIGHT_AUDIO = 34;
|
|
60
|
+
export declare const TIMELINE_LAYER_HEIGHT_DEFAULT = 21;
|
|
61
|
+
export declare const TIMELINE_LIST_ITEM_ROW_HEIGHT = 21;
|
|
62
|
+
export declare const getTimelineLayerHeight: (type: "audio" | "image" | "other" | "sequence" | "video") => number;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getTimelineLayerHeight = exports.
|
|
3
|
+
exports.getTimelineLayerHeight = exports.TIMELINE_LIST_ITEM_ROW_HEIGHT = exports.TIMELINE_LAYER_HEIGHT_DEFAULT = exports.TIMELINE_LAYER_HEIGHT_AUDIO = exports.TIMELINE_LAYER_HEIGHT_IMAGE = exports.TIMELINE_LAYER_HEIGHT_VIDEO = exports.TIMELINE_VIDEO_INFO_WAVEFORM_HEIGHT = exports.TIMELINE_LAYER_FILMSTRIP_HEIGHT = exports.getExpandedTrackHeight = exports.getTreeRowHeight = exports.flattenVisibleTreeNodes = exports.buildTimelineTree = exports.EXPANDED_SECTION_PADDING_RIGHT = exports.TREE_GROUP_ROW_HEIGHT = exports.TIMELINE_TRACK_EXPANDED_HEIGHT = exports.TIMELINE_ITEM_BORDER_BOTTOM = exports.TIMELINE_BORDER = exports.TIMELINE_PADDING = exports.SCHEMA_FIELD_ROW_HEIGHT = exports.getFieldsToShow = exports.getEffectFieldsToShow = void 0;
|
|
4
4
|
const studio_shared_1 = require("@remotion/studio-shared");
|
|
5
5
|
const studio_shared_2 = require("@remotion/studio-shared");
|
|
6
6
|
Object.defineProperty(exports, "getEffectFieldsToShow", { enumerable: true, get: function () { return studio_shared_2.getEffectFieldsToShow; } });
|
|
@@ -138,14 +138,15 @@ const getExpandedTrackHeight = ({ sequence, nodePathInfo, getIsExpanded, codeVal
|
|
|
138
138
|
return totalRowsHeight + separators;
|
|
139
139
|
};
|
|
140
140
|
exports.getExpandedTrackHeight = getExpandedTrackHeight;
|
|
141
|
-
exports.
|
|
142
|
-
exports.TIMELINE_LAYER_HEIGHT_IMAGE = 58;
|
|
143
|
-
exports.TIMELINE_LAYER_HEIGHT_AUDIO = 58;
|
|
144
|
-
exports.TIMELINE_LAYER_HEIGHT_DEFAULT = 25;
|
|
145
|
-
// The horizontal row inside a timeline list item (eye + arrow + label).
|
|
146
|
-
exports.TIMELINE_LIST_ITEM_ROW_HEIGHT = 25;
|
|
141
|
+
exports.TIMELINE_LAYER_FILMSTRIP_HEIGHT = 26;
|
|
147
142
|
// The waveform stripe rendered underneath the filmstrip in TimelineVideoInfo.
|
|
148
|
-
exports.TIMELINE_VIDEO_INFO_WAVEFORM_HEIGHT =
|
|
143
|
+
exports.TIMELINE_VIDEO_INFO_WAVEFORM_HEIGHT = 17;
|
|
144
|
+
exports.TIMELINE_LAYER_HEIGHT_VIDEO = 2 + exports.TIMELINE_LAYER_FILMSTRIP_HEIGHT + exports.TIMELINE_VIDEO_INFO_WAVEFORM_HEIGHT;
|
|
145
|
+
exports.TIMELINE_LAYER_HEIGHT_IMAGE = 26;
|
|
146
|
+
exports.TIMELINE_LAYER_HEIGHT_AUDIO = 34;
|
|
147
|
+
exports.TIMELINE_LAYER_HEIGHT_DEFAULT = 21;
|
|
148
|
+
// The horizontal row inside a timeline list item (eye + arrow + label).
|
|
149
|
+
exports.TIMELINE_LIST_ITEM_ROW_HEIGHT = 21;
|
|
149
150
|
const getTimelineLayerHeight = (type) => {
|
|
150
151
|
if (type === 'video') {
|
|
151
152
|
return exports.TIMELINE_LAYER_HEIGHT_VIDEO;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.timelineNodePathInfoToKey = void 0;
|
|
4
|
+
const studio_shared_1 = require("@remotion/studio-shared");
|
|
5
|
+
const timelineNodePathInfoToKey = (info) => [
|
|
6
|
+
(0, studio_shared_1.stringifySequenceExpandedRowKey)(info.sequenceSubscriptionKey),
|
|
7
|
+
info.auxiliaryKeys.join('.'),
|
|
8
|
+
info.index,
|
|
9
|
+
].join('.');
|
|
10
|
+
exports.timelineNodePathInfoToKey = timelineNodePathInfoToKey;
|
|
@@ -114,7 +114,6 @@ const getFileMenu = ({ readOnlyStudio, closeMenu, previewServerState, setSelecte
|
|
|
114
114
|
originalFunctionName: null,
|
|
115
115
|
originalScriptCode: null,
|
|
116
116
|
})
|
|
117
|
-
.then((res) => res.json())
|
|
118
117
|
.then(({ success }) => {
|
|
119
118
|
if (!success) {
|
|
120
119
|
(0, NotificationCenter_1.showNotification)(`Could not open ${window.remotion_editorName}`, 2000);
|
|
@@ -664,20 +663,12 @@ const useMenuStructure = (closeMenu, readOnlyStudio) => {
|
|
|
664
663
|
type: 'item',
|
|
665
664
|
quickSwitcherLabel: 'Open spring() Editor',
|
|
666
665
|
},
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
readOnlyStudio || remotion_packageManager === 'unknown'
|
|
671
|
-
? null
|
|
672
|
-
: {
|
|
673
|
-
id: 'install',
|
|
674
|
-
label: 'Packages',
|
|
675
|
-
leaveLeftPadding: false,
|
|
676
|
-
items: [
|
|
677
|
-
{
|
|
666
|
+
readOnlyStudio || remotion_packageManager === 'unknown'
|
|
667
|
+
? null
|
|
668
|
+
: {
|
|
678
669
|
id: 'install-packages',
|
|
679
670
|
value: 'install-packages',
|
|
680
|
-
label: 'Install
|
|
671
|
+
label: 'Install package',
|
|
681
672
|
onClick: () => {
|
|
682
673
|
closeMenu();
|
|
683
674
|
setSelectedModal({
|
|
@@ -689,10 +680,11 @@ const useMenuStructure = (closeMenu, readOnlyStudio) => {
|
|
|
689
680
|
keyHint: null,
|
|
690
681
|
leftItem: null,
|
|
691
682
|
subMenu: null,
|
|
692
|
-
quickSwitcherLabel: `Install
|
|
683
|
+
quickSwitcherLabel: `Install package`,
|
|
693
684
|
},
|
|
694
|
-
|
|
695
|
-
|
|
685
|
+
].filter(remotion_1.Internals.truthy),
|
|
686
|
+
quickSwitcherLabel: null,
|
|
687
|
+
},
|
|
696
688
|
{
|
|
697
689
|
id: 'help',
|
|
698
690
|
label: 'Help',
|
package/dist/renderEntry.js
CHANGED
|
@@ -186,13 +186,13 @@ const renderContent = (Root) => {
|
|
|
186
186
|
defaultPixelFormat: bundleMode.compositionDefaultPixelFormat,
|
|
187
187
|
defaultProResProfile: bundleMode.compositionDefaultProResProfile,
|
|
188
188
|
defaultSampleRate: bundleMode.compositionDefaultSampleRate,
|
|
189
|
-
}, initialCompositions: [], children: jsx_runtime_1.jsx(remotion_1.Internals.RemotionRootContexts, { frameState: null, audioEnabled: window.remotion_audioEnabled, videoEnabled: window.remotion_videoEnabled, logLevel: (_a = window.remotion_logLevel) !== null && _a !== void 0 ? _a : 'info', numberOfAudioTags: 0, audioLatencyHint: (_b = window.remotion_audioLatencyHint) !== null && _b !== void 0 ? _b : 'playback', children: jsx_runtime_1.jsxs(remotion_1.Internals.RenderAssetManagerProvider, { collectAssets: null, children: [
|
|
189
|
+
}, initialCompositions: [], children: jsx_runtime_1.jsx(remotion_1.Internals.RemotionRootContexts, { frameState: null, audioEnabled: window.remotion_audioEnabled, videoEnabled: window.remotion_videoEnabled, logLevel: (_a = window.remotion_logLevel) !== null && _a !== void 0 ? _a : 'info', numberOfAudioTags: 0, audioLatencyHint: (_b = window.remotion_audioLatencyHint) !== null && _b !== void 0 ? _b : 'playback', previewSampleRate: window.remotion_previewSampleRate, children: jsx_runtime_1.jsxs(remotion_1.Internals.RenderAssetManagerProvider, { collectAssets: null, children: [
|
|
190
190
|
jsx_runtime_1.jsx(Root, {}), jsx_runtime_1.jsx(GetVideoComposition, { state: bundleMode })
|
|
191
191
|
] }) }) }));
|
|
192
192
|
renderToDOM(markup);
|
|
193
193
|
}
|
|
194
194
|
if (bundleMode.type === 'evaluation') {
|
|
195
|
-
const markup = (jsx_runtime_1.jsx(remotion_1.Internals.CompositionManagerProvider, { initialCanvasContent: null, onlyRenderComposition: null, currentCompositionMetadata: null, initialCompositions: [], children: jsx_runtime_1.jsx(remotion_1.Internals.RemotionRootContexts, { frameState: null, audioEnabled: window.remotion_audioEnabled, videoEnabled: window.remotion_videoEnabled, logLevel: (_c = window.remotion_logLevel) !== null && _c !== void 0 ? _c : 'info', numberOfAudioTags: 0, audioLatencyHint: (_d = window.remotion_audioLatencyHint) !== null && _d !== void 0 ? _d : 'playback', children: jsx_runtime_1.jsx(remotion_1.Internals.RenderAssetManagerProvider, { collectAssets: null, children: jsx_runtime_1.jsx(Root, {}) }) }) }));
|
|
195
|
+
const markup = (jsx_runtime_1.jsx(remotion_1.Internals.CompositionManagerProvider, { initialCanvasContent: null, onlyRenderComposition: null, currentCompositionMetadata: null, initialCompositions: [], children: jsx_runtime_1.jsx(remotion_1.Internals.RemotionRootContexts, { frameState: null, audioEnabled: window.remotion_audioEnabled, videoEnabled: window.remotion_videoEnabled, logLevel: (_c = window.remotion_logLevel) !== null && _c !== void 0 ? _c : 'info', numberOfAudioTags: 0, audioLatencyHint: (_d = window.remotion_audioLatencyHint) !== null && _d !== void 0 ? _d : 'playback', previewSampleRate: window.remotion_previewSampleRate, children: jsx_runtime_1.jsx(remotion_1.Internals.RenderAssetManagerProvider, { collectAssets: null, children: jsx_runtime_1.jsx(Root, {}) }) }) }));
|
|
196
196
|
renderToDOM(markup);
|
|
197
197
|
}
|
|
198
198
|
if (bundleMode.type === 'index') {
|
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.
|
|
6
|
+
"version": "4.0.470",
|
|
7
7
|
"description": "APIs for interacting with the Remotion Studio",
|
|
8
8
|
"main": "dist",
|
|
9
9
|
"scripts": {
|
|
@@ -25,14 +25,14 @@
|
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"semver": "7.5.3",
|
|
28
|
-
"remotion": "4.0.
|
|
29
|
-
"@remotion/player": "4.0.
|
|
30
|
-
"@remotion/media-utils": "4.0.
|
|
31
|
-
"@remotion/renderer": "4.0.
|
|
32
|
-
"@remotion/web-renderer": "4.0.
|
|
33
|
-
"@remotion/studio-shared": "4.0.
|
|
34
|
-
"@remotion/timeline-utils": "4.0.
|
|
35
|
-
"@remotion/zod-types": "4.0.
|
|
28
|
+
"remotion": "4.0.470",
|
|
29
|
+
"@remotion/player": "4.0.470",
|
|
30
|
+
"@remotion/media-utils": "4.0.470",
|
|
31
|
+
"@remotion/renderer": "4.0.470",
|
|
32
|
+
"@remotion/web-renderer": "4.0.470",
|
|
33
|
+
"@remotion/studio-shared": "4.0.470",
|
|
34
|
+
"@remotion/timeline-utils": "4.0.470",
|
|
35
|
+
"@remotion/zod-types": "4.0.470",
|
|
36
36
|
"@jridgewell/trace-mapping": "0.3.31",
|
|
37
37
|
"mediabunny": "1.45.0",
|
|
38
38
|
"memfs": "3.4.3",
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
"react": "19.2.3",
|
|
44
44
|
"react-dom": "19.2.3",
|
|
45
45
|
"@types/semver": "7.5.3",
|
|
46
|
-
"@remotion/eslint-config-internal": "4.0.
|
|
46
|
+
"@remotion/eslint-config-internal": "4.0.470",
|
|
47
47
|
"eslint": "9.19.0",
|
|
48
48
|
"@typescript/native-preview": "7.0.0-dev.20260217.1"
|
|
49
49
|
},
|
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.TimelineFieldRow = void 0;
|
|
4
|
-
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
-
const react_1 = require("react");
|
|
6
|
-
const remotion_1 = require("remotion");
|
|
7
|
-
const client_id_1 = require("../../helpers/client-id");
|
|
8
|
-
const timeline_layout_1 = require("../../helpers/timeline-layout");
|
|
9
|
-
const save_sequence_prop_1 = require("./save-sequence-prop");
|
|
10
|
-
const timeline_field_row_layout_1 = require("./timeline-field-row-layout");
|
|
11
|
-
const TimelineExpandArrowButton_1 = require("./TimelineExpandArrowButton");
|
|
12
|
-
const TimelineLayerEye_1 = require("./TimelineLayerEye");
|
|
13
|
-
const TimelineRowChrome_1 = require("./TimelineRowChrome");
|
|
14
|
-
const TimelineSchemaField_1 = require("./TimelineSchemaField");
|
|
15
|
-
const fieldRowBase = {
|
|
16
|
-
paddingRight: timeline_layout_1.EXPANDED_SECTION_PADDING_RIGHT,
|
|
17
|
-
};
|
|
18
|
-
const fieldName = {
|
|
19
|
-
fontSize: 12,
|
|
20
|
-
color: 'rgba(255, 255, 255, 0.8)',
|
|
21
|
-
userSelect: 'none',
|
|
22
|
-
};
|
|
23
|
-
const Value = ({ field, nodePath, validatedLocation, schema, codeValue }) => {
|
|
24
|
-
const { getDragOverrides } = (0, react_1.useContext)(remotion_1.Internals.VisualModeDragOverridesContext);
|
|
25
|
-
const { setDragOverrides, clearDragOverrides } = (0, react_1.useContext)(remotion_1.Internals.VisualModeSettersContext);
|
|
26
|
-
const dragOverrideValue = (0, react_1.useMemo)(() => {
|
|
27
|
-
var _a;
|
|
28
|
-
return nodePath === null
|
|
29
|
-
? undefined
|
|
30
|
-
: ((_a = getDragOverrides(nodePath)) !== null && _a !== void 0 ? _a : {})[field.key];
|
|
31
|
-
}, [getDragOverrides, nodePath, field.key]);
|
|
32
|
-
const effectiveValue = remotion_1.Internals.getEffectiveVisualModeValue({
|
|
33
|
-
codeValue,
|
|
34
|
-
dragOverrideValue,
|
|
35
|
-
defaultValue: field.fieldSchema.default,
|
|
36
|
-
shouldResortToDefaultValueIfUndefined: true,
|
|
37
|
-
});
|
|
38
|
-
const { setCodeValues } = (0, react_1.useContext)(remotion_1.Internals.VisualModeSettersContext);
|
|
39
|
-
const { previewServerState } = (0, react_1.useContext)(client_id_1.StudioServerConnectionCtx);
|
|
40
|
-
const clientId = previewServerState.type === 'connected'
|
|
41
|
-
? previewServerState.clientId
|
|
42
|
-
: null;
|
|
43
|
-
const onSave = (0, react_1.useCallback)((value) => {
|
|
44
|
-
if (!codeValue || !codeValue.canUpdate) {
|
|
45
|
-
return Promise.reject(new Error('Cannot save'));
|
|
46
|
-
}
|
|
47
|
-
if (!clientId) {
|
|
48
|
-
return Promise.reject(new Error('Not connected to studio server'));
|
|
49
|
-
}
|
|
50
|
-
const defaultValue = field.fieldSchema.default !== undefined
|
|
51
|
-
? JSON.stringify(field.fieldSchema.default)
|
|
52
|
-
: null;
|
|
53
|
-
const stringifiedValue = JSON.stringify(value);
|
|
54
|
-
if (value === codeValue.codeValue) {
|
|
55
|
-
return Promise.resolve();
|
|
56
|
-
}
|
|
57
|
-
if (defaultValue === stringifiedValue &&
|
|
58
|
-
codeValue.codeValue === undefined) {
|
|
59
|
-
return Promise.resolve();
|
|
60
|
-
}
|
|
61
|
-
return (0, save_sequence_prop_1.saveSequenceProp)({
|
|
62
|
-
fileName: validatedLocation.source,
|
|
63
|
-
nodePath,
|
|
64
|
-
fieldKey: field.key,
|
|
65
|
-
value,
|
|
66
|
-
defaultValue,
|
|
67
|
-
schema,
|
|
68
|
-
setCodeValues,
|
|
69
|
-
clientId,
|
|
70
|
-
});
|
|
71
|
-
}, [
|
|
72
|
-
codeValue,
|
|
73
|
-
clientId,
|
|
74
|
-
field.fieldSchema.default,
|
|
75
|
-
field.key,
|
|
76
|
-
nodePath,
|
|
77
|
-
schema,
|
|
78
|
-
setCodeValues,
|
|
79
|
-
validatedLocation,
|
|
80
|
-
]);
|
|
81
|
-
const onDragValueChange = (0, react_1.useCallback)((value) => {
|
|
82
|
-
if (nodePath === null) {
|
|
83
|
-
throw new Error('Cannot drag value');
|
|
84
|
-
}
|
|
85
|
-
setDragOverrides(nodePath, field.key, value);
|
|
86
|
-
}, [setDragOverrides, nodePath, field.key]);
|
|
87
|
-
const onDragEnd = (0, react_1.useCallback)(() => {
|
|
88
|
-
if (nodePath === null) {
|
|
89
|
-
throw new Error('Cannot clear drag value');
|
|
90
|
-
}
|
|
91
|
-
clearDragOverrides(nodePath);
|
|
92
|
-
}, [clearDragOverrides, nodePath]);
|
|
93
|
-
return (jsx_runtime_1.jsx(TimelineSchemaField_1.TimelineFieldValue, { field: field, propStatus: codeValue, onSave: onSave, onDragValueChange: onDragValueChange, onDragEnd: onDragEnd, effectiveValue: effectiveValue }));
|
|
94
|
-
};
|
|
95
|
-
const TimelineFieldRow = ({ field, validatedLocation, rowDepth, nodePath, schema }) => {
|
|
96
|
-
var _a, _b;
|
|
97
|
-
const { codeValues: visualModeCodeValues } = (0, react_1.useContext)(remotion_1.Internals.VisualModeCodeValuesContext);
|
|
98
|
-
const codeValuesForOverride = remotion_1.Internals.getCodeValuesCtx(visualModeCodeValues, nodePath);
|
|
99
|
-
const codeValue = (_a = codeValuesForOverride === null || codeValuesForOverride === void 0 ? void 0 : codeValuesForOverride[field.key]) !== null && _a !== void 0 ? _a : null;
|
|
100
|
-
const style = (0, react_1.useMemo)(() => {
|
|
101
|
-
return {
|
|
102
|
-
...fieldRowBase,
|
|
103
|
-
height: field.rowHeight,
|
|
104
|
-
};
|
|
105
|
-
}, [field.rowHeight]);
|
|
106
|
-
const labelRowStyle = (0, react_1.useMemo)(() => (0, timeline_field_row_layout_1.getTimelineFieldLabelRowStyle)(rowDepth), [rowDepth]);
|
|
107
|
-
if (codeValue === null) {
|
|
108
|
-
return null;
|
|
109
|
-
}
|
|
110
|
-
return (jsx_runtime_1.jsxs(TimelineRowChrome_1.TimelineRowChrome, { depth: rowDepth, eye: jsx_runtime_1.jsx(TimelineLayerEye_1.TimelineLayerEyeSpacer, {}), arrow: jsx_runtime_1.jsx(TimelineExpandArrowButton_1.TimelineExpandArrowSpacer, {}), style: style, children: [
|
|
111
|
-
jsx_runtime_1.jsx("div", { style: labelRowStyle, children: jsx_runtime_1.jsx("span", { style: fieldName, children: (_b = field.description) !== null && _b !== void 0 ? _b : field.key }) }), codeValue.canUpdate ? (jsx_runtime_1.jsx(Value, { field: field, nodePath: nodePath, validatedLocation: validatedLocation, schema: schema, codeValue: codeValue })) : (jsx_runtime_1.jsx(TimelineSchemaField_1.TimelineNonEditableStatus, { propStatus: codeValue }))] }));
|
|
112
|
-
};
|
|
113
|
-
exports.TimelineFieldRow = TimelineFieldRow;
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import type { TSequence } from 'remotion';
|
|
3
|
-
import type { OriginalPosition } from '../../../error-overlay/react-overlay/utils/get-source-map';
|
|
4
|
-
export declare const TimelineStack: React.FC<{
|
|
5
|
-
readonly isCompact: boolean;
|
|
6
|
-
readonly sequence: TSequence;
|
|
7
|
-
readonly originalLocation: OriginalPosition | null;
|
|
8
|
-
}>;
|
|
@@ -1,119 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.TimelineStack = void 0;
|
|
4
|
-
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
-
const react_1 = require("react");
|
|
6
|
-
const client_id_1 = require("../../../helpers/client-id");
|
|
7
|
-
const colors_1 = require("../../../helpers/colors");
|
|
8
|
-
const get_git_menu_item_1 = require("../../../helpers/get-git-menu-item");
|
|
9
|
-
const open_in_editor_1 = require("../../../helpers/open-in-editor");
|
|
10
|
-
const layout_1 = require("../../layout");
|
|
11
|
-
const NotificationCenter_1 = require("../../Notifications/NotificationCenter");
|
|
12
|
-
const Spinner_1 = require("../../Spinner");
|
|
13
|
-
const source_attribution_1 = require("./source-attribution");
|
|
14
|
-
const TimelineStack = ({ isCompact, sequence, originalLocation }) => {
|
|
15
|
-
const [stackHovered, setStackHovered] = (0, react_1.useState)(false);
|
|
16
|
-
const [titleHovered, setTitleHovered] = (0, react_1.useState)(false);
|
|
17
|
-
const [opening, setOpening] = (0, react_1.useState)(false);
|
|
18
|
-
const connectionStatus = (0, react_1.useContext)(client_id_1.StudioServerConnectionCtx)
|
|
19
|
-
.previewServerState.type;
|
|
20
|
-
const openEditor = (0, react_1.useCallback)(async (location) => {
|
|
21
|
-
if (!window.remotion_editorName) {
|
|
22
|
-
return;
|
|
23
|
-
}
|
|
24
|
-
setOpening(true);
|
|
25
|
-
try {
|
|
26
|
-
await (0, open_in_editor_1.openOriginalPositionInEditor)(location);
|
|
27
|
-
}
|
|
28
|
-
catch (err) {
|
|
29
|
-
(0, NotificationCenter_1.showNotification)(err.message, 2000);
|
|
30
|
-
}
|
|
31
|
-
finally {
|
|
32
|
-
setOpening(false);
|
|
33
|
-
}
|
|
34
|
-
}, []);
|
|
35
|
-
const canOpenInEditor = window.remotion_editorName &&
|
|
36
|
-
connectionStatus === 'connected' &&
|
|
37
|
-
originalLocation;
|
|
38
|
-
const canOpenInGitHub = window.remotion_gitSource && originalLocation;
|
|
39
|
-
const { documentationLink } = sequence;
|
|
40
|
-
const titleHoverable = documentationLink !== null;
|
|
41
|
-
const stackHoverable = !isCompact && (canOpenInEditor || canOpenInGitHub);
|
|
42
|
-
const onClickTitle = (0, react_1.useCallback)(() => {
|
|
43
|
-
if (documentationLink === null) {
|
|
44
|
-
return null;
|
|
45
|
-
}
|
|
46
|
-
window.open(documentationLink, '_blank', 'noopener,noreferrer');
|
|
47
|
-
}, [documentationLink]);
|
|
48
|
-
const onClickStack = (0, react_1.useCallback)(() => {
|
|
49
|
-
if (!originalLocation) {
|
|
50
|
-
return;
|
|
51
|
-
}
|
|
52
|
-
if (canOpenInEditor) {
|
|
53
|
-
openEditor(originalLocation);
|
|
54
|
-
return;
|
|
55
|
-
}
|
|
56
|
-
if (canOpenInGitHub) {
|
|
57
|
-
window.open((0, get_git_menu_item_1.getGitRefUrl)(window.remotion_gitSource, originalLocation), '_blank');
|
|
58
|
-
}
|
|
59
|
-
}, [canOpenInEditor, canOpenInGitHub, openEditor, originalLocation]);
|
|
60
|
-
const onStackPointerEnter = (0, react_1.useCallback)(() => {
|
|
61
|
-
setStackHovered(true);
|
|
62
|
-
}, []);
|
|
63
|
-
const onStackPointerLeave = (0, react_1.useCallback)(() => {
|
|
64
|
-
setStackHovered(false);
|
|
65
|
-
}, []);
|
|
66
|
-
const onTitlePointerEnter = (0, react_1.useCallback)(() => {
|
|
67
|
-
setTitleHovered(true);
|
|
68
|
-
}, []);
|
|
69
|
-
const onTitlePointerLeave = (0, react_1.useCallback)(() => {
|
|
70
|
-
setTitleHovered(false);
|
|
71
|
-
}, []);
|
|
72
|
-
const style = (0, react_1.useMemo)(() => {
|
|
73
|
-
return {
|
|
74
|
-
fontSize: 12,
|
|
75
|
-
color: opening
|
|
76
|
-
? colors_1.VERY_LIGHT_TEXT
|
|
77
|
-
: stackHovered && stackHoverable
|
|
78
|
-
? colors_1.LIGHT_TEXT
|
|
79
|
-
: colors_1.VERY_LIGHT_TEXT,
|
|
80
|
-
marginLeft: 5,
|
|
81
|
-
cursor: stackHoverable ? 'pointer' : undefined,
|
|
82
|
-
display: 'flex',
|
|
83
|
-
flexDirection: 'row',
|
|
84
|
-
alignItems: 'center',
|
|
85
|
-
whiteSpace: 'nowrap',
|
|
86
|
-
textOverflow: 'ellipsis',
|
|
87
|
-
overflow: 'hidden',
|
|
88
|
-
flexShrink: 100000,
|
|
89
|
-
userSelect: 'none',
|
|
90
|
-
WebkitUserSelect: 'none',
|
|
91
|
-
};
|
|
92
|
-
}, [opening, stackHovered, stackHoverable]);
|
|
93
|
-
const titleStyle = (0, react_1.useMemo)(() => {
|
|
94
|
-
const hoverEffect = titleHovered && titleHoverable;
|
|
95
|
-
return {
|
|
96
|
-
fontSize: 12,
|
|
97
|
-
whiteSpace: 'nowrap',
|
|
98
|
-
textOverflow: 'ellipsis',
|
|
99
|
-
overflow: 'hidden',
|
|
100
|
-
lineHeight: 1.2,
|
|
101
|
-
color: opening && isCompact ? colors_1.VERY_LIGHT_TEXT : colors_1.LIGHT_COLOR,
|
|
102
|
-
userSelect: 'none',
|
|
103
|
-
WebkitUserSelect: 'none',
|
|
104
|
-
textDecoration: hoverEffect ? 'underline' : 'none',
|
|
105
|
-
textUnderlineOffset: 2,
|
|
106
|
-
cursor: hoverEffect ? 'pointer' : undefined,
|
|
107
|
-
};
|
|
108
|
-
}, [titleHoverable, isCompact, opening, titleHovered]);
|
|
109
|
-
const text = sequence.displayName.length > 1000
|
|
110
|
-
? sequence.displayName.slice(0, 1000) + '...'
|
|
111
|
-
: sequence.displayName;
|
|
112
|
-
return (jsx_runtime_1.jsxs(jsx_runtime_1.Fragment, { children: [
|
|
113
|
-
jsx_runtime_1.jsx("div", { onPointerEnter: onTitlePointerEnter, onPointerLeave: onTitlePointerLeave, title: documentationLink
|
|
114
|
-
? `Open documentation: ${documentationLink}`
|
|
115
|
-
: text || '<Sequence>', style: titleStyle, onClick: onClickTitle, children: text || '<Sequence>' }), isCompact || !originalLocation ? null : (jsx_runtime_1.jsx("div", { onPointerEnter: onStackPointerEnter, onPointerLeave: onStackPointerLeave, onClick: onClickStack, style: style, children: (0, source_attribution_1.getOriginalSourceAttribution)(originalLocation) })), opening ? (jsx_runtime_1.jsxs(jsx_runtime_1.Fragment, { children: [
|
|
116
|
-
jsx_runtime_1.jsx(layout_1.Spacing, { x: 0.5 }), jsx_runtime_1.jsx(Spinner_1.Spinner, { duration: 0.5, size: 12 })
|
|
117
|
-
] })) : null] }));
|
|
118
|
-
};
|
|
119
|
-
exports.TimelineStack = TimelineStack;
|