@remotion/studio 4.0.482 → 4.0.484
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/components/Canvas.js +19 -0
- package/dist/components/ColorPicker/ColorPicker.js +65 -3
- package/dist/components/ColorPicker/ColorPickerPopup.d.ts +1 -0
- package/dist/components/ColorPicker/ColorPickerPopup.js +3 -2
- package/dist/components/InspectorPanel/EasingInspector.js +184 -10
- package/dist/components/InspectorPanel/KeyframeEasingNavigator.d.ts +14 -0
- package/dist/components/InspectorPanel/KeyframeEasingNavigator.js +146 -0
- package/dist/components/InspectorPanel/KeyframeInspector.d.ts +1 -1
- package/dist/components/InspectorPanel/KeyframeInspector.js +228 -5
- package/dist/components/InspectorPanel/SequenceInspectorHeader.d.ts +17 -0
- package/dist/components/InspectorPanel/SequenceInspectorHeader.js +93 -0
- package/dist/components/InspectorPanel/SequenceSelectionInspector.js +4 -58
- package/dist/components/InspectorPanel/common.d.ts +12 -0
- package/dist/components/InspectorPanel/common.js +78 -1
- package/dist/components/InspectorPanel/easing-inspector-selection.d.ts +14 -0
- package/dist/components/InspectorPanel/easing-inspector-selection.js +18 -0
- package/dist/components/InspectorPanel/keyframe-easing-navigator-items.d.ts +24 -0
- package/dist/components/InspectorPanel/keyframe-easing-navigator-items.js +40 -0
- package/dist/components/InspectorPanel/keyframe-inspector-frame.d.ts +8 -0
- package/dist/components/InspectorPanel/keyframe-inspector-frame.js +14 -0
- package/dist/components/InspectorPanel/styles.d.ts +1 -0
- package/dist/components/InspectorPanel/styles.js +9 -1
- package/dist/components/InspectorSequenceSection.js +47 -10
- package/dist/components/Preview.js +1 -1
- package/dist/components/SelectedOutlineOverlay.d.ts +2 -0
- package/dist/components/SelectedOutlineOverlay.js +33 -12
- package/dist/components/SelectedOutlineUvControls.js +461 -2
- package/dist/components/Timeline/EasingEditorModal.js +48 -5
- package/dist/components/Timeline/Timeline.js +2 -1
- package/dist/components/Timeline/TimelineDeleteKeybindings.js +11 -1
- package/dist/components/Timeline/TimelineEffectItem.js +8 -5
- package/dist/components/Timeline/TimelineEffectPropItem.js +82 -1
- package/dist/components/Timeline/TimelineExpandedKeyframeRow.js +2 -2
- package/dist/components/Timeline/TimelineKeyframeControls.js +37 -7
- package/dist/components/Timeline/TimelineKeyframeEasingLine.d.ts +4 -0
- package/dist/components/Timeline/TimelineKeyframeEasingLine.js +12 -6
- package/dist/components/Timeline/TimelineKeyframedValue.js +1 -0
- package/dist/components/Timeline/TimelineRowChrome.js +6 -4
- package/dist/components/Timeline/TimelineSelection.d.ts +7 -1
- package/dist/components/Timeline/TimelineSelection.js +19 -3
- package/dist/components/Timeline/TimelineSequence.js +20 -8
- package/dist/components/Timeline/TimelineSequenceItem.js +64 -28
- package/dist/components/Timeline/TimelineSequenceName.d.ts +1 -0
- package/dist/components/Timeline/TimelineSequenceName.js +7 -6
- package/dist/components/Timeline/TimelineSequencePropItem.d.ts +1 -1
- package/dist/components/Timeline/TimelineSequencePropItem.js +80 -1
- package/dist/components/Timeline/TimelineSequenceRightEdgeDragHandle.d.ts +40 -1
- package/dist/components/Timeline/TimelineSequenceRightEdgeDragHandle.js +308 -1
- package/dist/components/Timeline/TimelineSlider.js +17 -3
- package/dist/components/Timeline/TimelineTrack.js +2 -4
- package/dist/components/Timeline/delete-selected-timeline-item.d.ts +8 -2
- package/dist/components/Timeline/delete-selected-timeline-item.js +80 -1
- package/dist/components/Timeline/get-animation-item-selection-for-frame.d.ts +18 -0
- package/dist/components/Timeline/get-animation-item-selection-for-frame.js +49 -0
- package/dist/components/Timeline/get-easing-selection-after-keyframe-delete.d.ts +15 -0
- package/dist/components/Timeline/get-easing-selection-after-keyframe-delete.js +26 -0
- package/dist/components/Timeline/save-sequence-prop.js +2 -0
- package/dist/components/Timeline/should-subscribe-to-sequence-props.d.ts +4 -0
- package/dist/components/Timeline/should-subscribe-to-sequence-props.js +10 -0
- package/dist/components/Timeline/update-selected-easing.d.ts +1 -0
- package/dist/components/Timeline/update-selected-easing.js +4 -3
- package/dist/components/Timeline/use-sequence-freeze-frame-menu-item.d.ts +2 -1
- package/dist/components/Timeline/use-sequence-freeze-frame-menu-item.js +19 -13
- package/dist/components/element-drag-and-drop.d.ts +3 -0
- package/dist/components/element-drag-and-drop.js +30 -0
- package/dist/components/import-assets.d.ts +11 -0
- package/dist/components/import-assets.js +23 -1
- package/dist/components/selected-outline-uv.d.ts +71 -1
- package/dist/components/selected-outline-uv.js +332 -10
- package/dist/esm/{chunk-nkqfa5bw.js → chunk-9erwh79m.js} +11896 -9019
- package/dist/esm/internals.mjs +11896 -9019
- package/dist/esm/previewEntry.mjs +11923 -9046
- package/dist/esm/renderEntry.mjs +1 -1
- package/dist/helpers/timeline-layout.d.ts +3 -3
- package/dist/helpers/timeline-layout.js +3 -1
- package/dist/helpers/use-menu-structure.js +0 -14
- package/package.json +11 -11
|
@@ -20,6 +20,7 @@ const saveSequenceProps = ({ changes, setPropStatuses, clientId, undoLabel, redo
|
|
|
20
20
|
previous: prev,
|
|
21
21
|
fieldKey: change.fieldKey,
|
|
22
22
|
value: change.value,
|
|
23
|
+
defaultValue: change.defaultValue,
|
|
23
24
|
schema: change.schema,
|
|
24
25
|
}),
|
|
25
26
|
apiCall: () => (0, call_api_1.callApi)('/api/save-sequence-props', {
|
|
@@ -45,6 +46,7 @@ const saveSequenceProps = ({ changes, setPropStatuses, clientId, undoLabel, redo
|
|
|
45
46
|
previous: prev,
|
|
46
47
|
fieldKey: change.fieldKey,
|
|
47
48
|
value: change.value,
|
|
49
|
+
defaultValue: change.defaultValue,
|
|
48
50
|
schema: change.schema,
|
|
49
51
|
}));
|
|
50
52
|
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.shouldSubscribeToSequenceProps = void 0;
|
|
4
|
+
const shouldSubscribeToSequenceProps = (sequence, previewConnected) => {
|
|
5
|
+
return (sequence.showInTimeline &&
|
|
6
|
+
Boolean(sequence.controls) &&
|
|
7
|
+
previewConnected &&
|
|
8
|
+
Boolean(sequence.getStack()));
|
|
9
|
+
};
|
|
10
|
+
exports.shouldSubscribeToSequenceProps = shouldSubscribeToSequenceProps;
|
|
@@ -23,6 +23,7 @@ export type SelectedEasingUpdate = {
|
|
|
23
23
|
readonly currentEasing: TimelineEasingValue;
|
|
24
24
|
readonly propStatus: CanUpdateSequencePropStatusKeyframed;
|
|
25
25
|
};
|
|
26
|
+
export declare const canEditEasingForInterpolationFunction: (interpolationFunction: string) => boolean;
|
|
26
27
|
export declare const getSelectedEasingUpdate: ({ selection, sequences, overrideIdsToNodePaths, propStatuses, }: {
|
|
27
28
|
selection: {
|
|
28
29
|
readonly type: "easing";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.updateSelectedTimelineEasings = exports.getTimelineEasingValueForSelection = exports.getEasingSelections = exports.makeEasingDragOverride = exports.getSelectedEasingUpdates = exports.getSelectedEasingUpdate = void 0;
|
|
3
|
+
exports.updateSelectedTimelineEasings = exports.getTimelineEasingValueForSelection = exports.getEasingSelections = exports.makeEasingDragOverride = exports.getSelectedEasingUpdates = exports.getSelectedEasingUpdate = exports.canEditEasingForInterpolationFunction = void 0;
|
|
4
4
|
const studio_shared_1 = require("@remotion/studio-shared");
|
|
5
5
|
const remotion_1 = require("remotion");
|
|
6
6
|
const call_update_keyframe_settings_1 = require("./call-update-keyframe-settings");
|
|
@@ -8,6 +8,7 @@ const find_track_for_node_path_info_1 = require("./find-track-for-node-path-info
|
|
|
8
8
|
const parse_keyframe_field_from_node_path_1 = require("./parse-keyframe-field-from-node-path");
|
|
9
9
|
const canEditEasingForInterpolationFunction = (interpolationFunction) => interpolationFunction === 'interpolate' ||
|
|
10
10
|
interpolationFunction === 'interpolateColors';
|
|
11
|
+
exports.canEditEasingForInterpolationFunction = canEditEasingForInterpolationFunction;
|
|
11
12
|
const isEasingSelection = (selection) => selection.type === 'easing';
|
|
12
13
|
const getSelectedEasingUpdate = ({ selection, sequences, overrideIdsToNodePaths, propStatuses, }) => {
|
|
13
14
|
var _a;
|
|
@@ -33,7 +34,7 @@ const getSelectedEasingUpdate = ({ selection, sequences, overrideIdsToNodePaths,
|
|
|
33
34
|
}
|
|
34
35
|
const sequencePropStatus = (_a = remotion_1.Internals.getPropStatusesCtx(propStatuses, nodePath)) === null || _a === void 0 ? void 0 : _a[field.fieldKey];
|
|
35
36
|
if ((sequencePropStatus === null || sequencePropStatus === void 0 ? void 0 : sequencePropStatus.status) !== 'keyframed' ||
|
|
36
|
-
!canEditEasingForInterpolationFunction(sequencePropStatus.interpolationFunction)) {
|
|
37
|
+
!(0, exports.canEditEasingForInterpolationFunction)(sequencePropStatus.interpolationFunction)) {
|
|
37
38
|
return null;
|
|
38
39
|
}
|
|
39
40
|
return {
|
|
@@ -60,7 +61,7 @@ const getSelectedEasingUpdate = ({ selection, sequences, overrideIdsToNodePaths,
|
|
|
60
61
|
? effectStatus.props[field.fieldKey]
|
|
61
62
|
: null;
|
|
62
63
|
if ((effectPropStatus === null || effectPropStatus === void 0 ? void 0 : effectPropStatus.status) !== 'keyframed' ||
|
|
63
|
-
!canEditEasingForInterpolationFunction(effectPropStatus.interpolationFunction)) {
|
|
64
|
+
!(0, exports.canEditEasingForInterpolationFunction)(effectPropStatus.interpolationFunction)) {
|
|
64
65
|
return null;
|
|
65
66
|
}
|
|
66
67
|
return {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import type { CanUpdateSequencePropStatus, SequencePropsSubscriptionKey, TSequence } from 'remotion';
|
|
2
2
|
import type { ComboboxValue } from '../NewComposition/ComboBox';
|
|
3
3
|
import { type SetPropStatuses } from './save-sequence-prop';
|
|
4
|
+
export declare const shouldShowFreezeFrameMenuItem: (sequence: TSequence) => boolean;
|
|
4
5
|
export declare const useSequenceFreezeFrameMenuItem: ({ clientId, nodePath, propStatusesForOverride, sequence, sequenceFrameOffset, setPropStatuses, timelinePosition, validatedSource, }: {
|
|
5
6
|
readonly clientId: string | null;
|
|
6
7
|
readonly nodePath: SequencePropsSubscriptionKey | null;
|
|
@@ -10,4 +11,4 @@ export declare const useSequenceFreezeFrameMenuItem: ({ clientId, nodePath, prop
|
|
|
10
11
|
readonly setPropStatuses: SetPropStatuses;
|
|
11
12
|
readonly timelinePosition: number;
|
|
12
13
|
readonly validatedSource: string | null;
|
|
13
|
-
}) => ComboboxValue;
|
|
14
|
+
}) => ComboboxValue | null;
|
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.useSequenceFreezeFrameMenuItem = void 0;
|
|
3
|
+
exports.useSequenceFreezeFrameMenuItem = exports.shouldShowFreezeFrameMenuItem = void 0;
|
|
4
4
|
const react_1 = require("react");
|
|
5
5
|
const save_sequence_prop_1 = require("./save-sequence-prop");
|
|
6
|
+
const shouldShowFreezeFrameMenuItem = (sequence) => {
|
|
7
|
+
return sequence.type !== 'audio';
|
|
8
|
+
};
|
|
9
|
+
exports.shouldShowFreezeFrameMenuItem = shouldShowFreezeFrameMenuItem;
|
|
6
10
|
const useSequenceFreezeFrameMenuItem = ({ clientId, nodePath, propStatusesForOverride, sequence, sequenceFrameOffset, setPropStatuses, timelinePosition, validatedSource, }) => {
|
|
7
11
|
const freezeStatus = propStatusesForOverride === null || propStatusesForOverride === void 0 ? void 0 : propStatusesForOverride.freeze;
|
|
8
12
|
const isFrozen = (freezeStatus === null || freezeStatus === void 0 ? void 0 : freezeStatus.status) === 'static' &&
|
|
@@ -57,17 +61,19 @@ const useSequenceFreezeFrameMenuItem = ({ clientId, nodePath, propStatusesForOve
|
|
|
57
61
|
timelinePosition,
|
|
58
62
|
validatedSource,
|
|
59
63
|
]);
|
|
60
|
-
return (0, react_1.useMemo)(() => (
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
64
|
+
return (0, react_1.useMemo)(() => (0, exports.shouldShowFreezeFrameMenuItem)(sequence)
|
|
65
|
+
? {
|
|
66
|
+
type: 'item',
|
|
67
|
+
id: 'toggle-freeze-frame',
|
|
68
|
+
keyHint: null,
|
|
69
|
+
label: isFrozen ? 'Unfreeze frame' : 'Freeze frame',
|
|
70
|
+
leftItem: null,
|
|
71
|
+
disabled: !canToggleFreeze,
|
|
72
|
+
onClick: onToggleFreezeFrame,
|
|
73
|
+
quickSwitcherLabel: null,
|
|
74
|
+
subMenu: null,
|
|
75
|
+
value: 'toggle-freeze-frame',
|
|
76
|
+
}
|
|
77
|
+
: null, [canToggleFreeze, isFrozen, onToggleFreezeFrame, sequence]);
|
|
72
78
|
};
|
|
73
79
|
exports.useSequenceFreezeFrameMenuItem = useSequenceFreezeFrameMenuItem;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getElementDragData = exports.hasElementDragType = void 0;
|
|
4
|
+
const studio_shared_1 = require("@remotion/studio-shared");
|
|
5
|
+
const hasElementDragType = (dataTransfer) => {
|
|
6
|
+
var _a;
|
|
7
|
+
return Array.from((_a = dataTransfer === null || dataTransfer === void 0 ? void 0 : dataTransfer.types) !== null && _a !== void 0 ? _a : []).includes(studio_shared_1.ELEMENT_DRAG_MIME_TYPE);
|
|
8
|
+
};
|
|
9
|
+
exports.hasElementDragType = hasElementDragType;
|
|
10
|
+
const getElementDragData = (dataTransfer) => {
|
|
11
|
+
if (!dataTransfer) {
|
|
12
|
+
return null;
|
|
13
|
+
}
|
|
14
|
+
for (const type of [
|
|
15
|
+
studio_shared_1.ELEMENT_DRAG_MIME_TYPE,
|
|
16
|
+
'application/json',
|
|
17
|
+
'text/plain',
|
|
18
|
+
]) {
|
|
19
|
+
const raw = dataTransfer.getData(type);
|
|
20
|
+
if (!raw) {
|
|
21
|
+
continue;
|
|
22
|
+
}
|
|
23
|
+
const parsed = (0, studio_shared_1.parseElementDragData)(raw);
|
|
24
|
+
if (parsed) {
|
|
25
|
+
return parsed;
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
return null;
|
|
29
|
+
};
|
|
30
|
+
exports.getElementDragData = getElementDragData;
|
|
@@ -72,3 +72,14 @@ export declare const insertComponent: ({ component, compositionFile, composition
|
|
|
72
72
|
compositionId: string;
|
|
73
73
|
dropPosition: InsertElementDropPosition | null;
|
|
74
74
|
}) => Promise<void>;
|
|
75
|
+
export declare const insertElement: ({ compositionFile, compositionId, dropPosition, element, }: {
|
|
76
|
+
compositionFile: string;
|
|
77
|
+
compositionId: string;
|
|
78
|
+
dropPosition: InsertElementDropPosition | null;
|
|
79
|
+
element: {
|
|
80
|
+
slug: string;
|
|
81
|
+
displayName: string;
|
|
82
|
+
sourceCode: string;
|
|
83
|
+
dimensions: import("@remotion/studio-shared").ComponentDimensions;
|
|
84
|
+
};
|
|
85
|
+
}) => Promise<void>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.insertComponent = exports.insertExistingAssets = exports.insertRemoteAudio = exports.importRemoteAsset = exports.importAssets = exports.pickFilesToImport = exports.getComponentDimensions = exports.getAssetElementFromPath = exports.getAssetElement = void 0;
|
|
3
|
+
exports.insertElement = exports.insertComponent = exports.insertExistingAssets = exports.insertRemoteAudio = exports.importRemoteAsset = exports.importAssets = exports.pickFilesToImport = exports.getComponentDimensions = exports.getAssetElementFromPath = exports.getAssetElement = void 0;
|
|
4
4
|
const media_utils_1 = require("@remotion/media-utils");
|
|
5
5
|
const studio_shared_1 = require("@remotion/studio-shared");
|
|
6
6
|
const remotion_1 = require("remotion");
|
|
@@ -569,3 +569,25 @@ const insertComponent = async ({ component, compositionFile, compositionId, drop
|
|
|
569
569
|
}
|
|
570
570
|
};
|
|
571
571
|
exports.insertComponent = insertComponent;
|
|
572
|
+
const insertElement = async ({ compositionFile, compositionId, dropPosition, element, }) => {
|
|
573
|
+
try {
|
|
574
|
+
const response = await (0, call_api_1.callApi)('/api/insert-element', {
|
|
575
|
+
compositionFile,
|
|
576
|
+
compositionId,
|
|
577
|
+
element,
|
|
578
|
+
position: getCenteredPosition({
|
|
579
|
+
dimensions: element.dimensions,
|
|
580
|
+
dropPosition,
|
|
581
|
+
}),
|
|
582
|
+
});
|
|
583
|
+
if (!response.success) {
|
|
584
|
+
(0, NotificationCenter_1.showNotification)(`Could not add Element: ${response.reason}`, 4000);
|
|
585
|
+
return;
|
|
586
|
+
}
|
|
587
|
+
(0, NotificationCenter_1.showNotification)(`Added ${element.displayName} to source file`, 2000);
|
|
588
|
+
}
|
|
589
|
+
catch (error) {
|
|
590
|
+
(0, NotificationCenter_1.showNotification)(`Could not add Element: ${error instanceof Error ? error.message : String(error)}`, 4000);
|
|
591
|
+
}
|
|
592
|
+
};
|
|
593
|
+
exports.insertElement = insertElement;
|
|
@@ -1,13 +1,35 @@
|
|
|
1
1
|
import type { CanUpdateSequencePropStatusKeyframed, CanUpdateSequencePropStatusStatic, GetEffectDragOverrides, PropStatuses, InteractivitySchemaField, SequencePropsSubscriptionKey, InteractivitySchema, TSequence } from 'remotion';
|
|
2
2
|
import { type OutlinePoint } from './selected-outline-geometry';
|
|
3
3
|
export type UvCoordinate = readonly [number, number];
|
|
4
|
+
type UvEllipseDimensions = {
|
|
5
|
+
readonly width: number;
|
|
6
|
+
readonly height: number;
|
|
7
|
+
};
|
|
4
8
|
export type UvCoordinateFieldSchema = Extract<InteractivitySchemaField, {
|
|
5
9
|
type: 'uv-coordinate';
|
|
6
10
|
}>;
|
|
11
|
+
export type NumericUvEllipseFieldSchema = Extract<InteractivitySchemaField, {
|
|
12
|
+
type: 'number' | 'rotation-degrees';
|
|
13
|
+
}>;
|
|
14
|
+
export type UvEllipseControlField = {
|
|
15
|
+
readonly fieldKey: string;
|
|
16
|
+
readonly fieldSchema: NumericUvEllipseFieldSchema;
|
|
17
|
+
readonly fieldDefault: number | null | undefined;
|
|
18
|
+
readonly propStatus: CanUpdateSequencePropStatusStatic | CanUpdateSequencePropStatusKeyframed;
|
|
19
|
+
readonly value: number;
|
|
20
|
+
};
|
|
21
|
+
export type UvEllipseControls = {
|
|
22
|
+
readonly width: UvEllipseControlField;
|
|
23
|
+
readonly height: UvEllipseControlField;
|
|
24
|
+
readonly rotation: UvEllipseControlField | null;
|
|
25
|
+
readonly innerScale: UvEllipseControlField | null;
|
|
26
|
+
};
|
|
7
27
|
export type SelectedOutlineUvHandle = {
|
|
8
28
|
readonly clientId: string;
|
|
9
29
|
readonly propStatus: CanUpdateSequencePropStatusStatic | CanUpdateSequencePropStatusKeyframed;
|
|
10
30
|
readonly effectIndex: number;
|
|
31
|
+
readonly effectValues: Record<string, unknown>;
|
|
32
|
+
readonly ellipseControls: UvEllipseControls | null;
|
|
11
33
|
readonly fieldDefault: UvCoordinate | undefined;
|
|
12
34
|
readonly fieldKey: string;
|
|
13
35
|
readonly fieldSchema: UvCoordinateFieldSchema;
|
|
@@ -17,12 +39,49 @@ export type SelectedOutlineUvHandle = {
|
|
|
17
39
|
readonly sourceFrame: number;
|
|
18
40
|
readonly value: UvCoordinate;
|
|
19
41
|
};
|
|
20
|
-
type UvConnectionHandle = Pick<SelectedOutlineUvHandle, 'effectIndex' | 'fieldKey' | 'fieldSchema' | 'value'
|
|
42
|
+
type UvConnectionHandle = Pick<SelectedOutlineUvHandle, 'effectIndex' | 'fieldKey' | 'fieldSchema' | 'value'> & {
|
|
43
|
+
readonly effectValues?: Record<string, unknown>;
|
|
44
|
+
readonly ellipseControls?: UvEllipseControls | null;
|
|
45
|
+
};
|
|
21
46
|
type UvHandleConnectionLine = {
|
|
22
47
|
readonly key: string;
|
|
23
48
|
readonly from: OutlinePoint;
|
|
24
49
|
readonly to: OutlinePoint;
|
|
25
50
|
};
|
|
51
|
+
type UvHandleConnectionEllipse = {
|
|
52
|
+
readonly key: string;
|
|
53
|
+
readonly points: readonly OutlinePoint[];
|
|
54
|
+
};
|
|
55
|
+
export type UvEllipseResizeAxis = 'width' | 'height';
|
|
56
|
+
export type UvEllipseResizeControl = {
|
|
57
|
+
readonly key: string;
|
|
58
|
+
readonly axis: UvEllipseResizeAxis;
|
|
59
|
+
readonly field: UvEllipseControlField;
|
|
60
|
+
readonly position: OutlinePoint;
|
|
61
|
+
readonly cursor: string;
|
|
62
|
+
};
|
|
63
|
+
export type UvEllipseRotationControl = {
|
|
64
|
+
readonly key: string;
|
|
65
|
+
readonly field: UvEllipseControlField;
|
|
66
|
+
readonly position: OutlinePoint;
|
|
67
|
+
readonly cursor: string;
|
|
68
|
+
};
|
|
69
|
+
export type UvEllipseStartControl = {
|
|
70
|
+
readonly key: string;
|
|
71
|
+
readonly field: UvEllipseControlField;
|
|
72
|
+
readonly position: OutlinePoint;
|
|
73
|
+
readonly cursor: string;
|
|
74
|
+
};
|
|
75
|
+
export type UvEllipseInteractiveControls = {
|
|
76
|
+
readonly handle: SelectedOutlineUvHandle;
|
|
77
|
+
readonly center: OutlinePoint;
|
|
78
|
+
readonly width: number;
|
|
79
|
+
readonly height: number;
|
|
80
|
+
readonly rotation: number;
|
|
81
|
+
readonly resize: readonly UvEllipseResizeControl[];
|
|
82
|
+
readonly rotationControl: UvEllipseRotationControl | null;
|
|
83
|
+
readonly startControl: UvEllipseStartControl | null;
|
|
84
|
+
};
|
|
26
85
|
type SelectedEffectFields = {
|
|
27
86
|
readonly allFields: boolean;
|
|
28
87
|
readonly fieldKeys: ReadonlySet<string>;
|
|
@@ -33,9 +92,20 @@ export declare const getUvHandleConnectionLines: ({ handles, points, }: {
|
|
|
33
92
|
readonly handles: readonly UvConnectionHandle[];
|
|
34
93
|
readonly points: readonly [OutlinePoint, OutlinePoint, OutlinePoint, OutlinePoint];
|
|
35
94
|
}) => UvHandleConnectionLine[];
|
|
95
|
+
export declare const getUvHandleConnectionEllipses: ({ handles, dimensions, points, }: {
|
|
96
|
+
readonly handles: readonly UvConnectionHandle[];
|
|
97
|
+
readonly dimensions?: UvEllipseDimensions | null | undefined;
|
|
98
|
+
readonly points: readonly [OutlinePoint, OutlinePoint, OutlinePoint, OutlinePoint];
|
|
99
|
+
}) => UvHandleConnectionEllipse[];
|
|
100
|
+
export declare const getUvEllipseInteractiveControls: ({ handles, dimensions, points, }: {
|
|
101
|
+
readonly handles: readonly SelectedOutlineUvHandle[];
|
|
102
|
+
readonly dimensions?: UvEllipseDimensions | null | undefined;
|
|
103
|
+
readonly points: readonly [OutlinePoint, OutlinePoint, OutlinePoint, OutlinePoint];
|
|
104
|
+
}) => UvEllipseInteractiveControls[];
|
|
36
105
|
export declare const getUvCoordinateForPoint: (points: readonly [OutlinePoint, OutlinePoint, OutlinePoint, OutlinePoint], point: OutlinePoint) => UvCoordinate;
|
|
37
106
|
export declare function constrainUv(value: UvCoordinate, schema: UvCoordinateFieldSchema): UvCoordinate;
|
|
38
107
|
export declare function roundUvCoordinate(value: UvCoordinate, schema: UvCoordinateFieldSchema): UvCoordinate;
|
|
108
|
+
export declare const roundNumericUvEllipseValue: (value: number, schema: NumericUvEllipseFieldSchema) => number;
|
|
39
109
|
export declare const getSelectedUvHandles: ({ propStatuses, clientId, getEffectDragOverrides, nodePath, selectedEffects, sequence, sourceFrame, }: {
|
|
40
110
|
readonly propStatuses: PropStatuses;
|
|
41
111
|
readonly clientId: string | null;
|