@remotion/studio 4.0.502 → 4.0.504
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/api/install-package.d.ts +2 -1
- package/dist/api/install-package.js +6 -2
- package/dist/components/AssetSelectorItem.js +4 -16
- package/dist/components/Canvas.js +41 -54
- package/dist/components/CheckboardToggle.js +3 -1
- package/dist/components/ColorPicker/AlphaSlider.js +14 -10
- package/dist/components/ColorPicker/HueSlider.js +14 -10
- package/dist/components/ColorPicker/SaturationValueArea.js +14 -12
- package/dist/components/CompositionContextButton.js +1 -1
- package/dist/components/CompositionSelectorItem.js +2 -3
- package/dist/components/ConfigureDefaultEditorModal.d.ts +2 -0
- package/dist/components/ConfigureDefaultEditorModal.js +151 -0
- package/dist/components/ConfirmationDialog.js +6 -3
- package/dist/components/ContextMenu.js +0 -2
- package/dist/components/ControlButton.d.ts +4 -2
- package/dist/components/ControlButton.js +6 -20
- package/dist/components/Editor.js +1 -4
- package/dist/components/EditorContent.js +1 -1
- package/dist/components/EditorGuides/Guide.js +48 -74
- package/dist/components/EditorRuler/Ruler.d.ts +1 -0
- package/dist/components/EditorRuler/Ruler.js +3 -1
- package/dist/components/EditorRuler/index.js +26 -23
- package/dist/components/EffectPickerModal.js +68 -7
- package/dist/components/ElementInstallConfirmation.d.ts +12 -0
- package/dist/components/ElementInstallConfirmation.js +205 -0
- package/dist/components/ForceSpecificCursor.js +14 -0
- package/dist/components/FullscreenToggle.js +1 -2
- package/dist/components/InitialCompositionLoader.js +1 -14
- package/dist/components/InlineAction.d.ts +4 -4
- package/dist/components/InlineAction.js +6 -4
- package/dist/components/InspectorLocationCopy.d.ts +1 -0
- package/dist/components/InspectorLocationCopy.js +7 -3
- package/dist/components/InspectorOpenInEditor.d.ts +5 -0
- package/dist/components/InspectorOpenInEditor.js +135 -0
- package/dist/components/InspectorPanel/AlignmentControls.js +1 -1
- package/dist/components/InspectorPanel/CompositionInspectorHeader.js +3 -3
- package/dist/components/InspectorPanel/CompositionMetadata.js +8 -7
- package/dist/components/InspectorPanel/KeyframeEasingNavigator.js +2 -2
- package/dist/components/InspectorPanel/KeyframeInspector.js +2 -3
- package/dist/components/InspectorPanel/SequenceInspectorHeader.js +2 -2
- package/dist/components/InspectorPanel/styles.js +4 -0
- package/dist/components/InspectorSequenceSection.js +2 -2
- package/dist/components/LoopToggle.js +1 -1
- package/dist/components/Menu/MenuItem.js +13 -6
- package/dist/components/Menu/MenuSubItem.js +3 -1
- package/dist/components/MenuBuildIndicator.d.ts +3 -1
- package/dist/components/MenuBuildIndicator.js +6 -4
- package/dist/components/MenuCompositionName.js +1 -1
- package/dist/components/MenuToolbar.js +1 -1
- package/dist/components/MobilePanel.d.ts +1 -2
- package/dist/components/MobilePanel.js +6 -6
- package/dist/components/ModalContainer.js +1 -1
- package/dist/components/ModalFooter.d.ts +1 -0
- package/dist/components/ModalFooter.js +2 -2
- package/dist/components/Modals.js +11 -2
- package/dist/components/MuteToggle.js +2 -1
- package/dist/components/NewComposition/ComboBox.d.ts +1 -0
- package/dist/components/NewComposition/ComboBox.js +2 -2
- package/dist/components/NewComposition/InputDragger.d.ts +4 -0
- package/dist/components/NewComposition/InputDragger.js +26 -32
- package/dist/components/Notifications/NotificationCenter.js +12 -2
- package/dist/components/OutlineToggle.js +10 -2
- package/dist/components/PlayPause.js +1 -5
- package/dist/components/PlaybackRateSelector.js +2 -1
- package/dist/components/PreviewToolbar.js +8 -7
- package/dist/components/PreviewToolbarOverflowButton.d.ts +0 -1
- package/dist/components/PreviewToolbarOverflowButton.js +2 -75
- package/dist/components/QuickSwitcher/QuickSwitcherContent.js +1 -2
- package/dist/components/RenderButton.d.ts +0 -1
- package/dist/components/RenderButton.js +10 -9
- package/dist/components/RenderModal/FrameRangeSetting.js +6 -1
- package/dist/components/RenderModal/InlineEyeIcon.js +1 -1
- package/dist/components/RenderModal/InlineRemoveButton.js +1 -1
- package/dist/components/RenderModal/MultiRangeSlider.js +8 -8
- package/dist/components/RenderModal/RenderModalEnvironmentVariables.js +1 -9
- package/dist/components/RenderModal/RenderModalOutputName.js +12 -3
- package/dist/components/RenderModal/SchemaEditor/SchemaResetButton.js +1 -1
- package/dist/components/RenderModal/ServerRenderModal.js +2 -17
- package/dist/components/RenderModal/WebRenderModal.js +3 -17
- package/dist/components/RenderModal/layout.js +7 -5
- package/dist/components/RenderModal/render-modals.js +18 -15
- package/dist/components/RenderQueue/RenderQueueCopyToClipboard.js +1 -1
- package/dist/components/RenderQueue/RenderQueueDownloadItem.js +1 -1
- package/dist/components/RenderQueue/RenderQueueItemCancelButton.js +1 -1
- package/dist/components/RenderQueue/RenderQueueOpenInFolder.js +1 -1
- package/dist/components/RenderQueue/RenderQueueRemoveItem.js +1 -1
- package/dist/components/RenderQueue/RenderQueueRepeat.js +2 -15
- package/dist/components/SelectedOutlineCropControls.js +7 -6
- package/dist/components/SelectedOutlineElement.js +32 -38
- package/dist/components/SelectedOutlineUvControls.js +25 -24
- package/dist/components/ShowGuidesProvider.js +2 -0
- package/dist/components/SidebarCollapserControls.js +2 -2
- package/dist/components/SidebarRenderButton.js +2 -16
- package/dist/components/SizeSelector.js +2 -1
- package/dist/components/SnappingToggle.js +1 -2
- package/dist/components/Spinner.d.ts +1 -0
- package/dist/components/Spinner.js +2 -2
- package/dist/components/Splitter/SplitterContainer.d.ts +1 -0
- package/dist/components/Splitter/SplitterContainer.js +4 -1
- package/dist/components/Splitter/SplitterContext.d.ts +4 -3
- package/dist/components/Splitter/SplitterContext.js +3 -2
- package/dist/components/Splitter/SplitterElement.js +6 -1
- package/dist/components/Splitter/SplitterHandle.js +18 -68
- package/dist/components/Tabs/vertical.d.ts +1 -0
- package/dist/components/Tabs/vertical.js +8 -10
- package/dist/components/TimeValue.js +26 -8
- package/dist/components/Timeline/EasingEditorModal.js +27 -19
- package/dist/components/Timeline/Timeline.js +1 -1
- package/dist/components/Timeline/TimelineAssetField.js +1 -1
- package/dist/components/Timeline/TimelineClipboardKeybindings.js +3 -6
- package/dist/components/Timeline/TimelineDeleteKeybindings.js +5 -7
- package/dist/components/Timeline/TimelineDragHandler.js +38 -7
- package/dist/components/Timeline/TimelineExpandedKeyframeRow.js +2 -1
- package/dist/components/Timeline/TimelineInOutDragHandler.js +26 -11
- package/dist/components/Timeline/TimelineKeyframeEasingLine.d.ts +1 -1
- package/dist/components/Timeline/TimelineKeyframeEasingLine.js +2 -2
- package/dist/components/Timeline/TimelineLayerEye.js +36 -4
- package/dist/components/Timeline/TimelineSelection.js +16 -24
- package/dist/components/Timeline/TimelineSequence.js +7 -3
- package/dist/components/Timeline/TimelineSequenceItem.js +24 -18
- package/dist/components/Timeline/TimelineSequenceRightEdgeDragHandle.d.ts +1 -1
- package/dist/components/Timeline/TimelineSequenceRightEdgeDragHandle.js +76 -43
- package/dist/components/Timeline/TimelineStack/get-stack.js +7 -2
- package/dist/components/Timeline/TimelineZoomControls.d.ts +3 -1
- package/dist/components/Timeline/TimelineZoomControls.js +24 -12
- package/dist/components/Timeline/get-sequence-context-menu-items.d.ts +4 -2
- package/dist/components/Timeline/get-sequence-context-menu-items.js +38 -2
- package/dist/components/Timeline/should-subscribe-to-source-file.d.ts +1 -0
- package/dist/components/Timeline/should-subscribe-to-source-file.js +11 -0
- package/dist/components/Timeline/use-expanded-track-keyframe-rows.js +2 -3
- package/dist/components/Timeline/use-open-sequence-in-editor.d.ts +3 -1
- package/dist/components/Timeline/use-open-sequence-in-editor.js +5 -2
- package/dist/components/Timeline/use-sequence-props-subscription.js +2 -0
- package/dist/components/Timeline/use-timeline-asset-drop.js +3 -7
- package/dist/components/Timeline/use-timeline-keyframe-drag.js +31 -16
- package/dist/components/TimelineInOutToggle.js +3 -3
- package/dist/components/TopPanel.js +3 -2
- package/dist/components/UndoRedoButtons.js +6 -5
- package/dist/components/UpdateCheck.d.ts +2 -0
- package/dist/components/UpdateCheck.js +29 -11
- package/dist/components/UpdateModal/UpdateModal.js +58 -19
- package/dist/components/VisualControls/ClickableFileName.js +5 -2
- package/dist/components/composition-menu-items.d.ts +2 -4
- package/dist/components/composition-menu-items.js +32 -55
- package/dist/components/element-install-request.d.ts +3 -0
- package/dist/components/element-install-request.js +17 -0
- package/dist/components/folder-menu-items.js +1 -1
- package/dist/components/handle-drop.d.ts +2 -3
- package/dist/components/handle-drop.js +11 -4
- package/dist/components/import-assets.d.ts +7 -6
- package/dist/components/import-assets.js +5 -16
- package/dist/components/use-default-editor-info.d.ts +4 -0
- package/dist/components/use-default-editor-info.js +47 -0
- package/dist/error-overlay/remotion-overlay/OpenInEditor.js +1 -1
- package/dist/error-overlay/remotion-overlay/StackFrame.js +1 -1
- package/dist/esm/{chunk-fjv75ty4.js → chunk-43m68z1k.js} +8689 -7374
- package/dist/esm/internals.mjs +8689 -7374
- package/dist/esm/previewEntry.mjs +8668 -7353
- package/dist/esm/renderEntry.mjs +1 -1
- package/dist/helpers/inject-css.js +58 -67
- package/dist/helpers/install-required-package.d.ts +3 -2
- package/dist/helpers/install-required-package.js +20 -15
- package/dist/helpers/open-in-editor.d.ts +3 -3
- package/dist/helpers/open-in-editor.js +10 -6
- package/dist/helpers/pointer-session.d.ts +9 -0
- package/dist/helpers/pointer-session.js +94 -0
- package/dist/helpers/use-menu-structure.js +109 -51
- package/dist/icons/audio.d.ts +1 -1
- package/dist/icons/audio.js +1 -1
- package/dist/icons/caret.js +1 -1
- package/dist/icons/certificate.d.ts +1 -1
- package/dist/icons/certificate.js +1 -1
- package/dist/icons/custom-editor.d.ts +4 -0
- package/dist/icons/custom-editor.js +11 -0
- package/dist/icons/data.d.ts +1 -1
- package/dist/icons/data.js +2 -2
- package/dist/icons/editor.d.ts +6 -0
- package/dist/icons/editor.js +52 -0
- package/dist/icons/effects.d.ts +5 -0
- package/dist/icons/effects.js +8 -0
- package/dist/icons/ellipsis.js +1 -1
- package/dist/icons/external-link.d.ts +5 -0
- package/dist/icons/external-link.js +10 -0
- package/dist/icons/fullscreen.js +1 -1
- package/dist/icons/gear.d.ts +1 -1
- package/dist/icons/gear.js +1 -1
- package/dist/icons/gif.d.ts +1 -1
- package/dist/icons/gif.js +1 -1
- package/dist/icons/input-props.d.ts +2 -0
- package/dist/icons/input-props.js +9 -0
- package/dist/icons/jump-to-start.js +2 -2
- package/dist/icons/magnet.d.ts +3 -1
- package/dist/icons/magnet.js +2 -2
- package/dist/icons/media-volume.d.ts +6 -2
- package/dist/icons/media-volume.js +8 -6
- package/dist/icons/minus.d.ts +3 -1
- package/dist/icons/minus.js +2 -2
- package/dist/icons/pause.js +1 -1
- package/dist/icons/play.js +1 -1
- package/dist/icons/plus.js +1 -1
- package/dist/icons/redo.js +2 -2
- package/dist/icons/step-back.js +2 -2
- package/dist/icons/step-forward.js +2 -2
- package/dist/icons/timelineInOutPointer.js +2 -2
- package/dist/icons/undo.js +2 -2
- package/dist/state/editor-guides.d.ts +1 -0
- package/dist/state/editor-guides.js +1 -0
- package/dist/state/modals.d.ts +2 -0
- package/dist/state/z-index.d.ts +1 -0
- package/dist/state/z-index.js +34 -18
- package/package.json +12 -13
- package/dist/components/StudioCanvasCapture.d.ts +0 -5
- package/dist/components/StudioCanvasCapture.js +0 -40
- package/dist/components/canvas-capture-enabled.d.ts +0 -1
- package/dist/components/canvas-capture-enabled.js +0 -4
- package/dist/components/use-element-overwrite-confirmation.d.ts +0 -2
- package/dist/components/use-element-overwrite-confirmation.js +0 -73
|
@@ -39,6 +39,7 @@ const player_1 = require("@remotion/player");
|
|
|
39
39
|
const react_1 = __importStar(require("react"));
|
|
40
40
|
const remotion_1 = require("remotion");
|
|
41
41
|
const get_left_of_timeline_slider_1 = require("../../helpers/get-left-of-timeline-slider");
|
|
42
|
+
const pointer_session_1 = require("../../helpers/pointer-session");
|
|
42
43
|
const in_out_1 = require("../../state/in-out");
|
|
43
44
|
const z_index_1 = require("../../state/z-index");
|
|
44
45
|
const ContextMenu_1 = require("../ContextMenu");
|
|
@@ -86,6 +87,7 @@ const TimelineInOutDragHandlerInner = () => {
|
|
|
86
87
|
const { inFrame, outFrame } = (0, in_out_1.useTimelineInOutFramePosition)();
|
|
87
88
|
const { setInAndOutFrames } = (0, in_out_1.useTimelineSetInOutFramePosition)();
|
|
88
89
|
const onInPointerDown = (0, react_1.useCallback)((e) => {
|
|
90
|
+
var _a, _b;
|
|
89
91
|
if (e.button !== 0) {
|
|
90
92
|
return;
|
|
91
93
|
}
|
|
@@ -108,9 +110,14 @@ const TimelineInOutDragHandlerInner = () => {
|
|
|
108
110
|
dragging: 'in',
|
|
109
111
|
initialOffset: getClientXWithScroll(e.clientX),
|
|
110
112
|
boundaries: [-Infinity, outMarker - inMarker],
|
|
113
|
+
button: e.button,
|
|
114
|
+
pointerId: e.pointerId,
|
|
115
|
+
target: e.currentTarget,
|
|
111
116
|
});
|
|
117
|
+
(_b = (_a = e.currentTarget).setPointerCapture) === null || _b === void 0 ? void 0 : _b.call(_a, e.pointerId);
|
|
112
118
|
}, [isHighestContext, videoConfig, inFrame, get, outFrame]);
|
|
113
119
|
const onOutPointerDown = (0, react_1.useCallback)((e) => {
|
|
120
|
+
var _a, _b;
|
|
114
121
|
if (e.button !== 0) {
|
|
115
122
|
return;
|
|
116
123
|
}
|
|
@@ -133,7 +140,11 @@ const TimelineInOutDragHandlerInner = () => {
|
|
|
133
140
|
dragging: 'out',
|
|
134
141
|
initialOffset: getClientXWithScroll(e.clientX),
|
|
135
142
|
boundaries: [inMarker - outMarker, Infinity],
|
|
143
|
+
button: e.button,
|
|
144
|
+
pointerId: e.pointerId,
|
|
145
|
+
target: e.currentTarget,
|
|
136
146
|
});
|
|
147
|
+
(_b = (_a = e.currentTarget).setPointerCapture) === null || _b === void 0 ? void 0 : _b.call(_a, e.pointerId);
|
|
137
148
|
}, [isHighestContext, videoConfig, inFrame, get, outFrame]);
|
|
138
149
|
const onPointerMoveInOut = (0, react_1.useCallback)((e) => {
|
|
139
150
|
if (!videoConfig) {
|
|
@@ -264,18 +275,22 @@ const TimelineInOutDragHandlerInner = () => {
|
|
|
264
275
|
if (inOutDragging.dragging === false) {
|
|
265
276
|
return;
|
|
266
277
|
}
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
278
|
+
return (0, pointer_session_1.startPointerSession)({
|
|
279
|
+
event: inOutDragging,
|
|
280
|
+
target: inOutDragging.target,
|
|
281
|
+
onMove: onPointerMoveInOut,
|
|
282
|
+
onEnd: (reason, endEvent) => {
|
|
283
|
+
if ((reason === 'pointerup' || reason === 'buttons-released') &&
|
|
284
|
+
endEvent) {
|
|
285
|
+
onPointerUpInOut(endEvent);
|
|
286
|
+
}
|
|
287
|
+
else {
|
|
288
|
+
onPointerCancelInOut();
|
|
289
|
+
}
|
|
290
|
+
},
|
|
291
|
+
});
|
|
277
292
|
}, [
|
|
278
|
-
inOutDragging
|
|
293
|
+
inOutDragging,
|
|
279
294
|
onPointerCancelInOut,
|
|
280
295
|
onPointerMoveInOut,
|
|
281
296
|
onPointerUpInOut,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { SequenceNodePathInfo } from '../../helpers/get-timeline-sequence-sort-key';
|
|
3
3
|
export declare const getTimelineKeyframeEasingLineStyle: (selected: boolean) => React.CSSProperties;
|
|
4
|
-
export declare const TimelineKeyframeEasingLineVisual: React.
|
|
4
|
+
export declare const TimelineKeyframeEasingLineVisual: React.NamedExoticComponent<{
|
|
5
5
|
readonly selected: boolean;
|
|
6
6
|
}>;
|
|
7
7
|
export declare const TimelineKeyframeEasingLine: React.NamedExoticComponent<{
|
|
@@ -72,11 +72,11 @@ const getTimelineKeyframeEasingLineStyle = (selected) => ({
|
|
|
72
72
|
outline: selected ? `1px solid ${colors_1.BLUE}` : undefined,
|
|
73
73
|
});
|
|
74
74
|
exports.getTimelineKeyframeEasingLineStyle = getTimelineKeyframeEasingLineStyle;
|
|
75
|
-
const
|
|
75
|
+
const TimelineKeyframeEasingLineVisualUnmemoized = ({ selected }) => {
|
|
76
76
|
const lineStyle = (0, react_1.useMemo)(() => (0, exports.getTimelineKeyframeEasingLineStyle)(selected), [selected]);
|
|
77
77
|
return jsx_runtime_1.jsx("div", { style: lineStyle });
|
|
78
78
|
};
|
|
79
|
-
exports.TimelineKeyframeEasingLineVisual =
|
|
79
|
+
exports.TimelineKeyframeEasingLineVisual = react_1.default.memo(TimelineKeyframeEasingLineVisualUnmemoized);
|
|
80
80
|
const TimelineKeyframeEasingLineUnmemoized = ({ fromFrame, toFrame, rowHeight, nodePathInfo, segmentIndex }) => {
|
|
81
81
|
const buttonRef = (0, react_1.useRef)(null);
|
|
82
82
|
const videoConfig = (0, remotion_1.useVideoConfig)();
|
|
@@ -4,6 +4,7 @@ exports.TimelineLayerEyeSpacer = exports.TimelineLayerEye = exports.timelineLaye
|
|
|
4
4
|
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
5
|
const react_1 = require("react");
|
|
6
6
|
const colors_1 = require("../../helpers/colors");
|
|
7
|
+
const pointer_session_1 = require("../../helpers/pointer-session");
|
|
7
8
|
const eyeIcon = {
|
|
8
9
|
width: 12,
|
|
9
10
|
color: colors_1.CURRENT_COLOR,
|
|
@@ -30,6 +31,10 @@ exports.timelineLayerIconContainer = {
|
|
|
30
31
|
flexShrink: 0,
|
|
31
32
|
};
|
|
32
33
|
let layerPointedDown = null;
|
|
34
|
+
let stopLayerPointerSession = null;
|
|
35
|
+
let lastPaintedLayerEye = null;
|
|
36
|
+
const layerEyeActions = new WeakMap();
|
|
37
|
+
const TIMELINE_LAYER_EYE_ATTR = 'data-timeline-layer-eye';
|
|
33
38
|
const TimelineLayerEye = ({ onInvoked, hidden, type }) => {
|
|
34
39
|
const renderAction = (0, react_1.useCallback)((color) => {
|
|
35
40
|
if (hidden) {
|
|
@@ -49,11 +54,29 @@ const TimelineLayerEye = ({ onInvoked, hidden, type }) => {
|
|
|
49
54
|
}
|
|
50
55
|
e.preventDefault();
|
|
51
56
|
e.stopPropagation();
|
|
57
|
+
stopLayerPointerSession === null || stopLayerPointerSession === void 0 ? void 0 : stopLayerPointerSession();
|
|
52
58
|
layerPointedDown = hidden ? 'enable' : 'disable';
|
|
53
59
|
onInvoked(layerPointedDown);
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
60
|
+
lastPaintedLayerEye = e.currentTarget;
|
|
61
|
+
stopLayerPointerSession = (0, pointer_session_1.startPointerSession)({
|
|
62
|
+
event: e,
|
|
63
|
+
target: e.currentTarget,
|
|
64
|
+
onMove: (moveEvent) => {
|
|
65
|
+
var _a, _b;
|
|
66
|
+
const pointedElement = (_a = document
|
|
67
|
+
.elementFromPoint(moveEvent.clientX, moveEvent.clientY)) === null || _a === void 0 ? void 0 : _a.closest(`[${TIMELINE_LAYER_EYE_ATTR}]`);
|
|
68
|
+
if (!pointedElement || pointedElement === lastPaintedLayerEye) {
|
|
69
|
+
return;
|
|
70
|
+
}
|
|
71
|
+
lastPaintedLayerEye = pointedElement;
|
|
72
|
+
(_b = layerEyeActions.get(pointedElement)) === null || _b === void 0 ? void 0 : _b();
|
|
73
|
+
},
|
|
74
|
+
onEnd: () => {
|
|
75
|
+
layerPointedDown = null;
|
|
76
|
+
lastPaintedLayerEye = null;
|
|
77
|
+
stopLayerPointerSession = null;
|
|
78
|
+
},
|
|
79
|
+
});
|
|
57
80
|
}, [hidden, onInvoked]);
|
|
58
81
|
const onDragStart = (0, react_1.useCallback)((e) => {
|
|
59
82
|
e.preventDefault();
|
|
@@ -64,10 +87,19 @@ const TimelineLayerEye = ({ onInvoked, hidden, type }) => {
|
|
|
64
87
|
onInvoked(layerPointedDown);
|
|
65
88
|
}
|
|
66
89
|
}, [onInvoked]);
|
|
90
|
+
const registerLayerEye = (0, react_1.useCallback)((element) => {
|
|
91
|
+
if (element) {
|
|
92
|
+
layerEyeActions.set(element, () => {
|
|
93
|
+
if (layerPointedDown) {
|
|
94
|
+
onInvoked(layerPointedDown);
|
|
95
|
+
}
|
|
96
|
+
});
|
|
97
|
+
}
|
|
98
|
+
}, [onInvoked]);
|
|
67
99
|
const onDoubleClick = (0, react_1.useCallback)((e) => {
|
|
68
100
|
e.stopPropagation();
|
|
69
101
|
}, []);
|
|
70
|
-
return (jsx_runtime_1.jsx("div", { style: exports.timelineLayerIconContainer, draggable: false, onDragStart: onDragStart, onDoubleClick: onDoubleClick, onPointerEnter: onPointerEnter, onPointerDown: onPointerDown, children: renderAction(colors_1.LIGHT_COLOR) }));
|
|
102
|
+
return (jsx_runtime_1.jsx("div", { ref: registerLayerEye, [TIMELINE_LAYER_EYE_ATTR]: true, style: exports.timelineLayerIconContainer, draggable: false, onDragStart: onDragStart, onDoubleClick: onDoubleClick, onPointerEnter: onPointerEnter, onPointerDown: onPointerDown, children: renderAction(colors_1.LIGHT_COLOR) }));
|
|
71
103
|
};
|
|
72
104
|
exports.TimelineLayerEye = TimelineLayerEye;
|
|
73
105
|
const spacerStyle = {
|
|
@@ -8,6 +8,7 @@ const remotion_1 = require("remotion");
|
|
|
8
8
|
const client_id_1 = require("../../helpers/client-id");
|
|
9
9
|
const colors_1 = require("../../helpers/colors");
|
|
10
10
|
const interactivity_enabled_1 = require("../../helpers/interactivity-enabled");
|
|
11
|
+
const pointer_session_1 = require("../../helpers/pointer-session");
|
|
11
12
|
const timeline_layout_1 = require("../../helpers/timeline-layout");
|
|
12
13
|
const timeline_node_path_key_1 = require("../../helpers/timeline-node-path-key");
|
|
13
14
|
const use_keybinding_1 = require("../../helpers/use-keybinding");
|
|
@@ -16,6 +17,7 @@ const ExpandedTracksProvider_1 = require("../ExpandedTracksProvider");
|
|
|
16
17
|
const options_sidebar_tabs_1 = require("../options-sidebar-tabs");
|
|
17
18
|
const get_node_keyframes_1 = require("./get-node-keyframes");
|
|
18
19
|
const get_timeline_easing_segments_1 = require("./get-timeline-easing-segments");
|
|
20
|
+
const imperative_state_1 = require("./imperative-state");
|
|
19
21
|
const timeline_expanded_filter_1 = require("./timeline-expanded-filter");
|
|
20
22
|
const timeline_refs_1 = require("./timeline-refs");
|
|
21
23
|
const TimelineClipboardKeybindings_1 = require("./TimelineClipboardKeybindings");
|
|
@@ -570,7 +572,6 @@ const TimelineSelectableItemsProvider = ({ children, timeline }) => {
|
|
|
570
572
|
const { getIsExpanded } = (0, react_1.useContext)(ExpandedTracksProvider_1.ExpandedTracksGetterContext);
|
|
571
573
|
const { propStatuses } = (0, react_1.useContext)(remotion_1.Internals.VisualModePropStatusesContext);
|
|
572
574
|
const { getDragOverrides, getEffectDragOverrides } = (0, react_1.useContext)(remotion_1.Internals.VisualModeDragOverridesContext);
|
|
573
|
-
const timelinePosition = remotion_1.Internals.Timeline.useTimelinePosition();
|
|
574
575
|
const { selectedItems } = (0, exports.useTimelineSelection)();
|
|
575
576
|
const selectableItems = (0, react_1.useMemo)(() => (0, exports.getSelectableTimelineItems)({
|
|
576
577
|
getDragOverrides,
|
|
@@ -579,7 +580,7 @@ const TimelineSelectableItemsProvider = ({ children, timeline }) => {
|
|
|
579
580
|
propStatuses,
|
|
580
581
|
selectedItems,
|
|
581
582
|
timeline,
|
|
582
|
-
timelinePosition,
|
|
583
|
+
timelinePosition: (0, imperative_state_1.getCurrentFrame)(),
|
|
583
584
|
}), [
|
|
584
585
|
getDragOverrides,
|
|
585
586
|
getEffectDragOverrides,
|
|
@@ -587,7 +588,6 @@ const TimelineSelectableItemsProvider = ({ children, timeline }) => {
|
|
|
587
588
|
propStatuses,
|
|
588
589
|
selectedItems,
|
|
589
590
|
timeline,
|
|
590
|
-
timelinePosition,
|
|
591
591
|
]);
|
|
592
592
|
return (jsx_runtime_1.jsx(exports.TimelineSelectionOrderProvider, { items: selectableItems, children: children }));
|
|
593
593
|
};
|
|
@@ -910,10 +910,7 @@ const useTimelineMarqueeSelection = () => {
|
|
|
910
910
|
event.target.closest(`[${exports.TIMELINE_SCRUBBER_ATTR}]`)) {
|
|
911
911
|
return;
|
|
912
912
|
}
|
|
913
|
-
const { currentTarget: target
|
|
914
|
-
if (target.setPointerCapture) {
|
|
915
|
-
target.setPointerCapture(pointerId);
|
|
916
|
-
}
|
|
913
|
+
const { currentTarget: target } = event;
|
|
917
914
|
const initialBounds = target.getBoundingClientRect();
|
|
918
915
|
const marqueeBounds = {
|
|
919
916
|
bottom: initialBounds.bottom,
|
|
@@ -937,13 +934,6 @@ const useTimelineMarqueeSelection = () => {
|
|
|
937
934
|
const extendSelection = event.metaKey || event.ctrlKey;
|
|
938
935
|
const selectionBeforeMarquee = selectedItems;
|
|
939
936
|
const cleanup = () => {
|
|
940
|
-
var _a;
|
|
941
|
-
window.removeEventListener('pointermove', onPointerMove);
|
|
942
|
-
window.removeEventListener('pointerup', onPointerUp);
|
|
943
|
-
window.removeEventListener('pointercancel', onPointerCancel);
|
|
944
|
-
if ((_a = target.hasPointerCapture) === null || _a === void 0 ? void 0 : _a.call(target, pointerId)) {
|
|
945
|
-
target.releasePointerCapture(pointerId);
|
|
946
|
-
}
|
|
947
937
|
document.body.style.userSelect = previousUserSelect;
|
|
948
938
|
document.body.style.webkitUserSelect = previousWebkitUserSelect;
|
|
949
939
|
setMarqueeRect(null);
|
|
@@ -979,16 +969,18 @@ const useTimelineMarqueeSelection = () => {
|
|
|
979
969
|
const onPointerMove = (moveEvent) => {
|
|
980
970
|
updateSelection(moveEvent.clientX, moveEvent.clientY);
|
|
981
971
|
};
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
989
|
-
|
|
990
|
-
|
|
991
|
-
|
|
972
|
+
(0, pointer_session_1.startPointerSession)({
|
|
973
|
+
event,
|
|
974
|
+
target,
|
|
975
|
+
onMove: onPointerMove,
|
|
976
|
+
onEnd: (reason, endEvent) => {
|
|
977
|
+
if ((reason === 'pointerup' || reason === 'buttons-released') &&
|
|
978
|
+
endEvent) {
|
|
979
|
+
updateSelection(endEvent.clientX, endEvent.clientY);
|
|
980
|
+
}
|
|
981
|
+
cleanup();
|
|
982
|
+
},
|
|
983
|
+
});
|
|
992
984
|
}, [
|
|
993
985
|
canSelect,
|
|
994
986
|
getMarqueeSelection,
|
|
@@ -53,6 +53,7 @@ const ConfirmationDialog_1 = require("../ConfirmationDialog");
|
|
|
53
53
|
const ContextMenu_1 = require("../ContextMenu");
|
|
54
54
|
const InitialCompositionLoader_1 = require("../InitialCompositionLoader");
|
|
55
55
|
const NotificationCenter_1 = require("../Notifications/NotificationCenter");
|
|
56
|
+
const use_default_editor_info_1 = require("../use-default-editor-info");
|
|
56
57
|
const use_select_asset_1 = require("../use-select-asset");
|
|
57
58
|
const disable_sequence_interactivity_1 = require("./disable-sequence-interactivity");
|
|
58
59
|
const duplicate_selected_timeline_item_1 = require("./duplicate-selected-timeline-item");
|
|
@@ -197,6 +198,7 @@ const TimelineSequenceInner = ({ s, connectedCompositions, windowWidth, nodePath
|
|
|
197
198
|
const { previewServerState } = (0, react_1.useContext)(client_id_1.StudioServerConnectionCtx);
|
|
198
199
|
const previewConnected = previewServerState.type === 'connected';
|
|
199
200
|
const previewInteractive = previewConnected && (0, interactivity_enabled_1.isStudioInteractivityEnabled)();
|
|
201
|
+
const editorInfo = (0, use_default_editor_info_1.useDefaultEditorInfo)((0, use_default_editor_info_1.canUseEditorPicker)(previewConnected));
|
|
200
202
|
const { setPropStatuses } = (0, react_1.useContext)(remotion_1.Internals.VisualModeSettersContext);
|
|
201
203
|
const timelinePosition = remotion_1.Internals.Timeline.useTimelinePosition();
|
|
202
204
|
const selectAsset = (0, use_select_asset_1.useSelectAsset)();
|
|
@@ -208,11 +210,11 @@ const TimelineSequenceInner = ({ s, connectedCompositions, windowWidth, nodePath
|
|
|
208
210
|
root: window.remotion_cwd,
|
|
209
211
|
}), [originalLocation]);
|
|
210
212
|
const canOpenInEditor = Boolean(window.remotion_editorName && previewConnected && originalLocation);
|
|
211
|
-
const openInEditor = (0, react_1.useCallback)(() => {
|
|
213
|
+
const openInEditor = (0, react_1.useCallback)((editorId) => {
|
|
212
214
|
if (!canOpenInEditor || !originalLocation) {
|
|
213
215
|
return;
|
|
214
216
|
}
|
|
215
|
-
(0, open_in_editor_1.openOriginalPositionInEditor)(originalLocation).catch((err) => {
|
|
217
|
+
(0, open_in_editor_1.openOriginalPositionInEditor)(originalLocation, editorId).catch((err) => {
|
|
216
218
|
(0, NotificationCenter_1.showNotification)(err.message, 2000);
|
|
217
219
|
});
|
|
218
220
|
}, [canOpenInEditor, originalLocation]);
|
|
@@ -238,7 +240,7 @@ const TimelineSequenceInner = ({ s, connectedCompositions, windowWidth, nodePath
|
|
|
238
240
|
}));
|
|
239
241
|
return;
|
|
240
242
|
}
|
|
241
|
-
openInEditor();
|
|
243
|
+
openInEditor(null);
|
|
242
244
|
}, [
|
|
243
245
|
canOpenInEditor,
|
|
244
246
|
connectedCompositions,
|
|
@@ -344,6 +346,7 @@ const TimelineSequenceInner = ({ s, connectedCompositions, windowWidth, nodePath
|
|
|
344
346
|
deleteDisabled,
|
|
345
347
|
disableInteractivityDisabled,
|
|
346
348
|
duplicateDisabled,
|
|
349
|
+
editorInfo,
|
|
347
350
|
fileLocation,
|
|
348
351
|
includeSourceEditItems: (0, interactivity_enabled_1.isStudioInteractivityEnabled)(),
|
|
349
352
|
onDeleteSequenceFromSource,
|
|
@@ -363,6 +366,7 @@ const TimelineSequenceInner = ({ s, connectedCompositions, windowWidth, nodePath
|
|
|
363
366
|
deleteDisabled,
|
|
364
367
|
disableInteractivityDisabled,
|
|
365
368
|
duplicateDisabled,
|
|
369
|
+
editorInfo,
|
|
366
370
|
fileLocation,
|
|
367
371
|
freezeFrameMenuItem,
|
|
368
372
|
onDeleteSequenceFromSource,
|
|
@@ -196,7 +196,7 @@ const TimelineSequenceItem = ({ children, connectedCompositions, nestedDepth, se
|
|
|
196
196
|
const [sequenceDropIndicator, setSequenceDropIndicator] = (0, react_1.useState)(null);
|
|
197
197
|
const [sequenceDropRejection, setSequenceDropRejection] = (0, react_1.useState)(null);
|
|
198
198
|
const timelinePosition = remotion_1.Internals.Timeline.useTimelinePosition();
|
|
199
|
-
const { canOpenInEditor, openInEditor, originalLocation } = (0, use_open_sequence_in_editor_1.useOpenSequenceInEditor)(sequence);
|
|
199
|
+
const { canOpenInEditor, editorInfo, openInEditor, originalLocation } = (0, use_open_sequence_in_editor_1.useOpenSequenceInEditor)(sequence);
|
|
200
200
|
const fileLocation = (0, react_1.useMemo)(() => (0, format_file_location_1.formatFileLocation)({
|
|
201
201
|
location: originalLocation,
|
|
202
202
|
root: window.remotion_cwd,
|
|
@@ -580,7 +580,7 @@ const TimelineSequenceItem = ({ children, connectedCompositions, nestedDepth, se
|
|
|
580
580
|
}));
|
|
581
581
|
return;
|
|
582
582
|
}
|
|
583
|
-
openInEditor();
|
|
583
|
+
openInEditor(null);
|
|
584
584
|
}, [
|
|
585
585
|
canOpenInEditor,
|
|
586
586
|
connectedCompositions,
|
|
@@ -714,6 +714,7 @@ const TimelineSequenceItem = ({ children, connectedCompositions, nestedDepth, se
|
|
|
714
714
|
deleteDisabled,
|
|
715
715
|
disableInteractivityDisabled,
|
|
716
716
|
duplicateDisabled,
|
|
717
|
+
editorInfo,
|
|
717
718
|
fileLocation,
|
|
718
719
|
includeSourceEditItems: (0, interactivity_enabled_1.isStudioInteractivityEnabled)(),
|
|
719
720
|
onDeleteSequenceFromSource,
|
|
@@ -741,22 +742,26 @@ const TimelineSequenceItem = ({ children, connectedCompositions, nestedDepth, se
|
|
|
741
742
|
},
|
|
742
743
|
]
|
|
743
744
|
: []),
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
745
|
+
...(canCrop
|
|
746
|
+
? [
|
|
747
|
+
{
|
|
748
|
+
type: 'item',
|
|
749
|
+
id: 'crop',
|
|
750
|
+
keyHint: null,
|
|
751
|
+
label: 'Crop',
|
|
752
|
+
leftItem: null,
|
|
753
|
+
disabled: false,
|
|
754
|
+
onClick: onCrop,
|
|
755
|
+
quickSwitcherLabel: null,
|
|
756
|
+
subMenu: null,
|
|
757
|
+
value: 'crop',
|
|
758
|
+
},
|
|
759
|
+
{
|
|
760
|
+
type: 'divider',
|
|
761
|
+
id: 'crop-divider',
|
|
762
|
+
},
|
|
763
|
+
]
|
|
764
|
+
: []),
|
|
760
765
|
{
|
|
761
766
|
type: 'item',
|
|
762
767
|
id: 'rename-sequence',
|
|
@@ -784,6 +789,7 @@ const TimelineSequenceItem = ({ children, connectedCompositions, nestedDepth, se
|
|
|
784
789
|
deleteDisabled,
|
|
785
790
|
disableInteractivityDisabled,
|
|
786
791
|
duplicateDisabled,
|
|
792
|
+
editorInfo,
|
|
787
793
|
fileLocation,
|
|
788
794
|
freezeFrameMenuItem,
|
|
789
795
|
nodePathInfo === null || nodePathInfo === void 0 ? void 0 : nodePathInfo.supportsEffects,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { CanUpdateSequencePropStatus, CanUpdateSequencePropStatusKeyframed, OverrideIdToNodePaths, PropStatuses, SequencePropsSubscriptionKey, TSequence
|
|
2
|
+
import type { CanUpdateSequencePropStatus, CanUpdateSequencePropStatusKeyframed, InteractivitySchema, OverrideIdToNodePaths, PropStatuses, SequencePropsSubscriptionKey, TSequence } from 'remotion';
|
|
3
3
|
import type { SequenceNodePathInfo } from '../../helpers/get-timeline-sequence-sort-key';
|
|
4
4
|
import type { MoveEffectKeyframeChange, MoveSequenceKeyframeChange } from './call-move-keyframe';
|
|
5
5
|
import { type SaveSequencePropChange } from './save-sequence-prop';
|
|
@@ -9,6 +9,7 @@ const no_react_1 = require("remotion/no-react");
|
|
|
9
9
|
const calculate_timeline_1 = require("../../helpers/calculate-timeline");
|
|
10
10
|
const client_id_1 = require("../../helpers/client-id");
|
|
11
11
|
const colors_1 = require("../../helpers/colors");
|
|
12
|
+
const pointer_session_1 = require("../../helpers/pointer-session");
|
|
12
13
|
const sort_by_nonce_history_1 = require("../../helpers/sort-by-nonce-history");
|
|
13
14
|
const timeline_layout_1 = require("../../helpers/timeline-layout");
|
|
14
15
|
const editor_snapping_1 = require("../../state/editor-snapping");
|
|
@@ -604,6 +605,7 @@ const TimelineSequenceLeftEdgeDragHandle = ({ nodePathInfo, windowWidth, timelin
|
|
|
604
605
|
});
|
|
605
606
|
}, []);
|
|
606
607
|
const onPointerDown = (0, react_1.useCallback)((e) => {
|
|
608
|
+
var _a, _b;
|
|
607
609
|
if (e.button !== 0) {
|
|
608
610
|
return;
|
|
609
611
|
}
|
|
@@ -632,8 +634,11 @@ const TimelineSequenceLeftEdgeDragHandle = ({ nodePathInfo, windowWidth, timelin
|
|
|
632
634
|
latestDeltaFrames: 0,
|
|
633
635
|
pxPerFrame,
|
|
634
636
|
pointerId: e.pointerId,
|
|
637
|
+
button: e.button,
|
|
638
|
+
target: e.currentTarget,
|
|
635
639
|
targets,
|
|
636
640
|
};
|
|
641
|
+
(_b = (_a = e.currentTarget).setPointerCapture) === null || _b === void 0 ? void 0 : _b.call(_a, e.pointerId);
|
|
637
642
|
document.body.style.userSelect = 'none';
|
|
638
643
|
document.body.style.webkitUserSelect = 'none';
|
|
639
644
|
(0, ForceSpecificCursor_1.forceSpecificCursor)('ew-resize');
|
|
@@ -687,20 +692,27 @@ const TimelineSequenceLeftEdgeDragHandle = ({ nodePathInfo, windowWidth, timelin
|
|
|
687
692
|
}
|
|
688
693
|
finishDrag(false);
|
|
689
694
|
};
|
|
690
|
-
const
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
695
|
+
const activeDragState = dragStateRef.current;
|
|
696
|
+
if (!activeDragState) {
|
|
697
|
+
return;
|
|
698
|
+
}
|
|
699
|
+
return (0, pointer_session_1.startPointerSession)({
|
|
700
|
+
event: activeDragState,
|
|
701
|
+
target: activeDragState.target,
|
|
702
|
+
onMove,
|
|
703
|
+
onEnd: (reason, endEvent) => {
|
|
704
|
+
if ((reason === 'pointerup' || reason === 'buttons-released') &&
|
|
705
|
+
endEvent) {
|
|
706
|
+
onUp(endEvent);
|
|
707
|
+
}
|
|
708
|
+
else if (endEvent) {
|
|
709
|
+
onCancel(endEvent);
|
|
710
|
+
}
|
|
711
|
+
else {
|
|
712
|
+
finishDrag(false);
|
|
713
|
+
}
|
|
714
|
+
},
|
|
715
|
+
});
|
|
704
716
|
}, [dragging, finishDrag]);
|
|
705
717
|
const style = {
|
|
706
718
|
...baseStyle,
|
|
@@ -801,6 +813,7 @@ const useTimelineSequenceFromDrag = ({ nodePathInfo, windowWidth, timelineDurati
|
|
|
801
813
|
});
|
|
802
814
|
}, []);
|
|
803
815
|
const onPointerDown = (0, react_1.useCallback)((e) => {
|
|
816
|
+
var _a, _b;
|
|
804
817
|
if (e.button !== 0) {
|
|
805
818
|
return;
|
|
806
819
|
}
|
|
@@ -831,8 +844,11 @@ const useTimelineSequenceFromDrag = ({ nodePathInfo, windowWidth, timelineDurati
|
|
|
831
844
|
latestDeltaFrames: 0,
|
|
832
845
|
pxPerFrame,
|
|
833
846
|
pointerId: e.pointerId,
|
|
847
|
+
button: e.button,
|
|
848
|
+
target: e.currentTarget,
|
|
834
849
|
targets,
|
|
835
850
|
};
|
|
851
|
+
(_b = (_a = e.currentTarget).setPointerCapture) === null || _b === void 0 ? void 0 : _b.call(_a, e.pointerId);
|
|
836
852
|
document.body.style.userSelect = 'none';
|
|
837
853
|
document.body.style.webkitUserSelect = 'none';
|
|
838
854
|
setDragging(true);
|
|
@@ -900,20 +916,27 @@ const useTimelineSequenceFromDrag = ({ nodePathInfo, windowWidth, timelineDurati
|
|
|
900
916
|
}
|
|
901
917
|
finishDrag(false);
|
|
902
918
|
};
|
|
903
|
-
const
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
|
|
910
|
-
|
|
911
|
-
|
|
912
|
-
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
919
|
+
const activeDragState = dragStateRef.current;
|
|
920
|
+
if (!activeDragState) {
|
|
921
|
+
return;
|
|
922
|
+
}
|
|
923
|
+
return (0, pointer_session_1.startPointerSession)({
|
|
924
|
+
event: activeDragState,
|
|
925
|
+
target: activeDragState.target,
|
|
926
|
+
onMove,
|
|
927
|
+
onEnd: (reason, endEvent) => {
|
|
928
|
+
if ((reason === 'pointerup' || reason === 'buttons-released') &&
|
|
929
|
+
endEvent) {
|
|
930
|
+
onUp(endEvent);
|
|
931
|
+
}
|
|
932
|
+
else if (endEvent) {
|
|
933
|
+
onCancel(endEvent);
|
|
934
|
+
}
|
|
935
|
+
else {
|
|
936
|
+
finishDrag(false);
|
|
937
|
+
}
|
|
938
|
+
},
|
|
939
|
+
});
|
|
917
940
|
}, [dragging, finishDrag]);
|
|
918
941
|
return {
|
|
919
942
|
dragging,
|
|
@@ -994,6 +1017,7 @@ const TimelineSequenceRightEdgeDragHandle = ({ nodePathInfo, windowWidth, timeli
|
|
|
994
1017
|
});
|
|
995
1018
|
}, []);
|
|
996
1019
|
const onPointerDown = (0, react_1.useCallback)((e) => {
|
|
1020
|
+
var _a, _b;
|
|
997
1021
|
if (e.button !== 0) {
|
|
998
1022
|
return;
|
|
999
1023
|
}
|
|
@@ -1022,8 +1046,11 @@ const TimelineSequenceRightEdgeDragHandle = ({ nodePathInfo, windowWidth, timeli
|
|
|
1022
1046
|
latestDeltaFrames: 0,
|
|
1023
1047
|
pxPerFrame,
|
|
1024
1048
|
pointerId: e.pointerId,
|
|
1049
|
+
button: e.button,
|
|
1050
|
+
target: e.currentTarget,
|
|
1025
1051
|
targets,
|
|
1026
1052
|
};
|
|
1053
|
+
(_b = (_a = e.currentTarget).setPointerCapture) === null || _b === void 0 ? void 0 : _b.call(_a, e.pointerId);
|
|
1027
1054
|
document.body.style.userSelect = 'none';
|
|
1028
1055
|
document.body.style.webkitUserSelect = 'none';
|
|
1029
1056
|
(0, ForceSpecificCursor_1.forceSpecificCursor)('ew-resize');
|
|
@@ -1072,21 +1099,27 @@ const TimelineSequenceRightEdgeDragHandle = ({ nodePathInfo, windowWidth, timeli
|
|
|
1072
1099
|
}
|
|
1073
1100
|
finishDrag(false);
|
|
1074
1101
|
};
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
}
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1102
|
+
const activeDragState = dragStateRef.current;
|
|
1103
|
+
if (!activeDragState) {
|
|
1104
|
+
return;
|
|
1105
|
+
}
|
|
1106
|
+
return (0, pointer_session_1.startPointerSession)({
|
|
1107
|
+
event: activeDragState,
|
|
1108
|
+
target: activeDragState.target,
|
|
1109
|
+
onMove,
|
|
1110
|
+
onEnd: (reason, endEvent) => {
|
|
1111
|
+
if ((reason === 'pointerup' || reason === 'buttons-released') &&
|
|
1112
|
+
endEvent) {
|
|
1113
|
+
onUp(endEvent);
|
|
1114
|
+
}
|
|
1115
|
+
else if (endEvent) {
|
|
1116
|
+
onCancel(endEvent);
|
|
1117
|
+
}
|
|
1118
|
+
else {
|
|
1119
|
+
finishDrag(false);
|
|
1120
|
+
}
|
|
1121
|
+
},
|
|
1122
|
+
});
|
|
1090
1123
|
}, [dragging, finishDrag]);
|
|
1091
1124
|
const style = {
|
|
1092
1125
|
...baseStyle,
|
|
@@ -7,6 +7,7 @@ const get_location_of_sequence_1 = require("../../../helpers/get-location-of-seq
|
|
|
7
7
|
const traceMapCache = {};
|
|
8
8
|
const traceMapPromises = {};
|
|
9
9
|
const browserStudioOriginalSourcePrefix = 'browser-studio-original://';
|
|
10
|
+
const studioOriginalSourcePrefix = 'studio-original://';
|
|
10
11
|
const getSourceMapCache = async (fileName) => {
|
|
11
12
|
if (traceMapCache[fileName]) {
|
|
12
13
|
return traceMapCache[fileName];
|
|
@@ -33,11 +34,15 @@ const getOriginalLocationFromStack = async (stack, type) => {
|
|
|
33
34
|
if (!location) {
|
|
34
35
|
return null;
|
|
35
36
|
}
|
|
36
|
-
|
|
37
|
+
const originalSourcePrefix = [
|
|
38
|
+
browserStudioOriginalSourcePrefix,
|
|
39
|
+
studioOriginalSourcePrefix,
|
|
40
|
+
].find((prefix) => location.fileName.startsWith(prefix));
|
|
41
|
+
if (originalSourcePrefix) {
|
|
37
42
|
return {
|
|
38
43
|
column: location.columnNumber,
|
|
39
44
|
line: location.lineNumber,
|
|
40
|
-
source: decodeURIComponent(location.fileName.slice(
|
|
45
|
+
source: decodeURIComponent(location.fileName.slice(originalSourcePrefix.length)),
|
|
41
46
|
};
|
|
42
47
|
}
|
|
43
48
|
const map = await getSourceMapCache(location.fileName);
|