@remotion/studio 4.0.495 → 4.0.496

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (50) hide show
  1. package/dist/components/AssetSelectorItem.js +7 -7
  2. package/dist/components/CompositionSelectorItem.js +5 -23
  3. package/dist/components/CurrentAsset.js +4 -3
  4. package/dist/components/InlineCompositionName.js +1 -1
  5. package/dist/components/InlineEditableTitle.d.ts +1 -0
  6. package/dist/components/InlineEditableTitle.js +56 -11
  7. package/dist/components/InspectorInfoHeader.d.ts +2 -0
  8. package/dist/components/InspectorInfoHeader.js +16 -4
  9. package/dist/components/InspectorLocationCopy.js +2 -2
  10. package/dist/components/InspectorPanel/CompositionInspectorHeader.js +11 -6
  11. package/dist/components/InspectorPanel/EasingInspector.js +1 -1
  12. package/dist/components/InspectorPanel/KeyframeInspector.js +7 -8
  13. package/dist/components/InspectorPanel/KeyframeSettings.js +1 -1
  14. package/dist/components/InspectorPanel/SequenceInspectorHeader.js +28 -3
  15. package/dist/components/InspectorPanel/SequenceSelectionInspector.js +2 -2
  16. package/dist/components/InspectorPanel/common.d.ts +4 -2
  17. package/dist/components/InspectorPanel/common.js +18 -18
  18. package/dist/components/InspectorPanel/styles.d.ts +0 -3
  19. package/dist/components/InspectorPanel/styles.js +5 -40
  20. package/dist/components/InspectorSequenceSection.js +12 -2
  21. package/dist/components/InspectorSourceLocation.d.ts +1 -0
  22. package/dist/components/InspectorSourceLocation.js +5 -1
  23. package/dist/components/NewComposition/ComboBox.d.ts +2 -1
  24. package/dist/components/NewComposition/ComboBox.js +32 -7
  25. package/dist/components/PlaybackRateSelector.js +3 -3
  26. package/dist/components/PreviewToolbar.js +3 -3
  27. package/dist/components/RenderButton.d.ts +1 -0
  28. package/dist/components/RenderButton.js +51 -7
  29. package/dist/components/RenderModal/SchemaEditor/ZodDiscriminatedUnionEditor.js +1 -1
  30. package/dist/components/RenderModal/SchemaEditor/ZodEnumEditor.js +1 -1
  31. package/dist/components/RenderModal/SchemaEditor/ZodStaticFileEditor.js +1 -1
  32. package/dist/components/SizeSelector.js +3 -3
  33. package/dist/components/Timeline/TimelineAssetField.js +1 -1
  34. package/dist/components/Timeline/TimelineEnumField.js +1 -1
  35. package/dist/components/Timeline/TimelineFieldLabel.js +3 -3
  36. package/dist/components/Timeline/TimelineKeyframeControls.js +26 -6
  37. package/dist/components/Timeline/TimelineRowChrome.js +10 -2
  38. package/dist/components/Timeline/TimelineRowLayoutContext.d.ts +3 -0
  39. package/dist/components/Timeline/TimelineRowLayoutContext.js +6 -0
  40. package/dist/components/layout.d.ts +1 -0
  41. package/dist/components/layout.js +2 -1
  42. package/dist/components/open-in-new-window.d.ts +2 -0
  43. package/dist/components/open-in-new-window.js +28 -0
  44. package/dist/esm/{chunk-784jbkzs.js → chunk-0v4n7nkh.js} +565 -376
  45. package/dist/esm/internals.mjs +565 -376
  46. package/dist/esm/previewEntry.mjs +565 -376
  47. package/dist/esm/renderEntry.mjs +1 -1
  48. package/dist/helpers/inject-css.js +4 -2
  49. package/dist/icons/scissors.js +1 -1
  50. package/package.json +11 -11
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.keyframeEditorValue = exports.keyframeEditorLabel = exports.keyframeEditorRow = exports.detailValue = exports.detailLabel = exports.detailRow = exports.guideDetailsContainer = exports.detailsBeforeInlineAction = exports.inspectorActionSection = exports.detailsWithInlineAction = exports.detailsContainer = exports.centeredMessage = exports.selectedContainer = exports.resolveLinkStyle = exports.defaultPropsWarningMessages = exports.defaultPropsWarningContainer = exports.sectionHeaderEnd = exports.sectionHeaderStart = exports.sectionHeaderTitle = exports.sectionHeaderRow = exports.sequenceHeaderSubtitle = exports.sequenceHeaderTitle = exports.sequenceHeader = exports.inspectorSectionBody = exports.sectionHeader = exports.sequenceHeaderDivider = exports.inspectorSectionDivider = exports.inspectorOverviewSection = exports.compositionVisualControlsSection = exports.compositionDefaultPropsSection = exports.scrollableContainer = exports.container = void 0;
3
+ exports.keyframeEditorValue = exports.keyframeEditorRow = exports.detailValue = exports.detailLabel = exports.detailRow = exports.guideDetailsContainer = exports.detailsBeforeInlineAction = exports.inspectorActionSection = exports.detailsWithInlineAction = exports.detailsContainer = exports.centeredMessage = exports.selectedContainer = exports.resolveLinkStyle = exports.defaultPropsWarningMessages = exports.defaultPropsWarningContainer = exports.sectionHeaderEnd = exports.sectionHeaderStart = exports.sectionHeaderTitle = exports.sectionHeaderRow = exports.sequenceHeaderSubtitle = exports.inspectorSectionBody = exports.sectionHeader = exports.sequenceHeaderDivider = exports.inspectorSectionDivider = exports.inspectorOverviewSection = exports.compositionVisualControlsSection = exports.compositionDefaultPropsSection = exports.scrollableContainer = exports.container = void 0;
4
4
  const colors_1 = require("../../helpers/colors");
5
5
  const InspectorPanelLayout_1 = require("../InspectorPanelLayout");
6
6
  exports.container = {
@@ -50,31 +50,6 @@ exports.inspectorSectionBody = {
50
50
  minWidth: 0,
51
51
  paddingBottom: 8,
52
52
  };
53
- exports.sequenceHeader = {
54
- backgroundColor: colors_1.BACKGROUND,
55
- display: 'flex',
56
- flexDirection: 'column',
57
- minWidth: 0,
58
- padding: `6px ${InspectorPanelLayout_1.INSPECTOR_PANEL_HORIZONTAL_PADDING}px 4px`,
59
- };
60
- exports.sequenceHeaderTitle = {
61
- alignSelf: 'stretch',
62
- backgroundColor: colors_1.BACKGROUND,
63
- border: 'none',
64
- color: colors_1.WHITE,
65
- display: 'flex',
66
- fontFamily: 'sans-serif',
67
- fontSize: 12,
68
- lineHeight: '18px',
69
- margin: 0,
70
- maxWidth: '100%',
71
- minWidth: 0,
72
- overflow: 'hidden',
73
- padding: 0,
74
- textAlign: 'left',
75
- textOverflow: 'ellipsis',
76
- whiteSpace: 'nowrap',
77
- };
78
53
  exports.sequenceHeaderSubtitle = {
79
54
  alignSelf: 'flex-start',
80
55
  backgroundColor: colors_1.BACKGROUND,
@@ -182,6 +157,10 @@ exports.detailRow = {
182
157
  exports.detailLabel = {
183
158
  color: colors_1.LIGHT_TEXT,
184
159
  fontSize: 13,
160
+ minWidth: 0,
161
+ overflow: 'hidden',
162
+ textOverflow: 'ellipsis',
163
+ whiteSpace: 'nowrap',
185
164
  };
186
165
  exports.detailValue = {
187
166
  color: colors_1.WHITE,
@@ -192,22 +171,8 @@ exports.detailValue = {
192
171
  wordBreak: 'break-word',
193
172
  };
194
173
  exports.keyframeEditorRow = {
195
- alignItems: 'flex-start',
196
- display: 'flex',
197
- gap: 12,
198
- justifyContent: 'space-between',
199
- minWidth: 0,
200
174
  padding: '10px 0',
201
175
  };
202
- exports.keyframeEditorLabel = {
203
- color: colors_1.LIGHT_TEXT,
204
- fontSize: 13,
205
- lineHeight: '22px',
206
- minWidth: 0,
207
- overflow: 'hidden',
208
- textOverflow: 'ellipsis',
209
- whiteSpace: 'nowrap',
210
- };
211
176
  exports.keyframeEditorValue = {
212
177
  alignItems: 'center',
213
178
  display: 'flex',
@@ -5,10 +5,11 @@ const jsx_runtime_1 = require("react/jsx-runtime");
5
5
  const react_1 = require("react");
6
6
  const client_id_1 = require("../helpers/client-id");
7
7
  const colors_1 = require("../helpers/colors");
8
+ const get_preview_file_type_1 = require("../helpers/get-preview-file-type");
8
9
  const timeline_layout_1 = require("../helpers/timeline-layout");
9
10
  const plus_1 = require("../icons/plus");
10
11
  const modals_1 = require("../state/modals");
11
- const CurrentAsset_1 = require("./CurrentAsset");
12
+ const AssetFileIcon_1 = require("./AssetFileIcon");
12
13
  const InlineAction_1 = require("./InlineAction");
13
14
  const common_1 = require("./InspectorPanel/common");
14
15
  const styles_1 = require("./InspectorPanel/styles");
@@ -41,6 +42,11 @@ const plusIcon = {
41
42
  width: 15,
42
43
  height: 15,
43
44
  };
45
+ const assetSelectorIcon = {
46
+ flexShrink: 0,
47
+ height: 18,
48
+ width: 18,
49
+ };
44
50
  const remoteSourceLabel = {
45
51
  color: colors_1.LIGHT_TEXT,
46
52
  display: 'flex',
@@ -135,6 +141,7 @@ const hasSequenceControls = (sequence) => {
135
141
  };
136
142
  exports.hasSequenceControls = hasSequenceControls;
137
143
  const InspectorSequenceSection = ({ sequence, validatedLocation, nodePathInfo, keyframeDisplayOffset, renderTransformControls, }) => {
144
+ var _a;
138
145
  const { tree } = (0, use_timeline_expanded_tree_1.useTimelineExpandedTree)({
139
146
  sequence,
140
147
  nodePathInfo,
@@ -155,6 +162,9 @@ const InspectorSequenceSection = ({ sequence, validatedLocation, nodePathInfo, k
155
162
  (0, timeline_asset_link_1.openTimelineAssetLink)(localAsset, selectAsset);
156
163
  }
157
164
  }, [localAsset, selectAsset]);
165
+ const localAssetFileName = localAsset
166
+ ? ((_a = localAsset.assetPath.split('/').pop()) !== null && _a !== void 0 ? _a : localAsset.assetPath)
167
+ : null;
158
168
  const getIsExpanded = (0, react_1.useCallback)((candidate) => {
159
169
  return !collapsedKeys.has(getInspectorExpansionKey(candidate));
160
170
  }, [collapsedKeys]);
@@ -232,7 +242,7 @@ const InspectorSequenceSection = ({ sequence, validatedLocation, nodePathInfo, k
232
242
  if (controlRows.length === 0 && !showEffectsSection) {
233
243
  return (jsx_runtime_1.jsx("div", { style: container, children: jsx_runtime_1.jsx(common_1.InspectorSection, { header: "Controls", children: jsx_runtime_1.jsx("div", { style: emptyState, children: "No schema" }) }) }));
234
244
  }
235
- return (jsx_runtime_1.jsxs("div", { style: container, children: [controlRows.length > 0 ? (jsx_runtime_1.jsx(TimelineSelection_1.TimelineSelectionOrderProvider, { items: controlSelectableItems, children: controlGroups.map((group) => (jsx_runtime_1.jsxs(common_1.InspectorSection, { header: group.label, children: [group.id === 'source' && localAsset ? (jsx_runtime_1.jsx(CurrentAsset_1.AssetInfo, { assetName: localAsset.assetPath, contentSized: true, onAssetClick: jumpToAsset, readOnlyStudio: true })) : null, group.id === 'source' && remoteAsset && remoteSourceParts ? (jsx_runtime_1.jsxs("div", { style: remoteSourceLabel, title: remoteAsset.href, children: [
245
+ return (jsx_runtime_1.jsxs("div", { style: container, children: [controlRows.length > 0 ? (jsx_runtime_1.jsx(TimelineSelection_1.TimelineSelectionOrderProvider, { items: controlSelectableItems, children: controlGroups.map((group) => (jsx_runtime_1.jsxs(common_1.InspectorSection, { header: group.label, children: [group.id === 'source' && localAsset ? (jsx_runtime_1.jsx(common_1.InspectorInlineAction, { disabled: false, onClick: jumpToAsset, renderIcon: (color) => (jsx_runtime_1.jsx(AssetFileIcon_1.AssetFileIcon, { color: color, fileType: (0, get_preview_file_type_1.getPreviewFileType)(localAsset.assetPath), style: assetSelectorIcon })), size: "compact", title: localAsset.assetPath, children: localAssetFileName })) : null, group.id === 'source' && remoteAsset && remoteSourceParts ? (jsx_runtime_1.jsxs("div", { style: remoteSourceLabel, title: remoteAsset.href, children: [
236
246
  jsx_runtime_1.jsx("span", { style: remoteSourceLeading, children: remoteSourceParts.leading }), jsx_runtime_1.jsx("span", { style: remoteSourceTrailing, children: remoteSourceParts.trailing })
237
247
  ] })) : null, group.id === 'transforms' ? renderTransformControls() : null, group.id === 'source' ? null : group.rows.map(renderRow)] }, group.id))) })) : null, showEffectsSection ? (jsx_runtime_1.jsx(common_1.InspectorSection, { header: effectsHeader, children: effectRows.length > 0 ? (jsx_runtime_1.jsx(TimelineSelection_1.TimelineSelectionOrderProvider, { items: effectSelectableItems, children: effectRows.map(renderRow) })) : null })) : null] }));
238
248
  };
@@ -5,4 +5,5 @@ export declare const InspectorSourceLocation: React.FC<{
5
5
  readonly canOpen: boolean;
6
6
  readonly onOpen: () => void;
7
7
  readonly renderIcon?: (color: string) => React.ReactNode;
8
+ readonly size?: 'default' | 'inline-action';
8
9
  }>;
@@ -5,6 +5,7 @@ const jsx_runtime_1 = require("react/jsx-runtime");
5
5
  const react_1 = require("react");
6
6
  const colors_1 = require("../helpers/colors");
7
7
  const format_file_location_1 = require("../helpers/format-file-location");
8
+ const common_1 = require("./InspectorPanel/common");
8
9
  const source_attribution_1 = require("./Timeline/TimelineStack/source-attribution");
9
10
  const sourceLocationStyle = {
10
11
  alignSelf: 'flex-start',
@@ -40,7 +41,7 @@ const sourceLocationLabelStyle = {
40
41
  textOverflow: 'ellipsis',
41
42
  whiteSpace: 'nowrap',
42
43
  };
43
- const InspectorSourceLocation = ({ location, canOpen, onOpen, renderIcon }) => {
44
+ const InspectorSourceLocation = ({ location, canOpen, onOpen, renderIcon, size = 'default' }) => {
44
45
  const [hovered, setHovered] = (0, react_1.useState)(false);
45
46
  const validLocation = (0, react_1.useMemo)(() => {
46
47
  if (!(location === null || location === void 0 ? void 0 : location.source) || location.line === null) {
@@ -80,6 +81,9 @@ const InspectorSourceLocation = ({ location, canOpen, onOpen, renderIcon }) => {
80
81
  if (!label) {
81
82
  return null;
82
83
  }
84
+ if (size === 'inline-action') {
85
+ return (jsx_runtime_1.jsx(common_1.InspectorInlineAction, { disabled: !canOpen, onClick: onClick, renderIcon: (iconColor) => renderIcon === null || renderIcon === void 0 ? void 0 : renderIcon(iconColor), size: "compact", title: fileLocation !== null && fileLocation !== void 0 ? fileLocation : undefined, children: label }));
86
+ }
83
87
  return (jsx_runtime_1.jsxs("button", { type: "button", style: style, title: fileLocation !== null && fileLocation !== void 0 ? fileLocation : undefined, onClick: onClick, onPointerEnter: () => setHovered(true), onPointerLeave: () => setHovered(false), children: [renderIcon ? renderIcon(color) : null, jsx_runtime_1.jsx("span", { style: sourceLocationLabelStyle, children: label })
84
88
  ] }));
85
89
  };
@@ -1,4 +1,5 @@
1
1
  import React from 'react';
2
+ export type ComboboxSize = 'default' | 'compact' | 'small';
2
3
  type DividerItem = {
3
4
  type: 'divider';
4
5
  id: string;
@@ -26,6 +27,6 @@ export declare const Combobox: React.FC<{
26
27
  readonly selectedId: string | number;
27
28
  readonly style?: React.CSSProperties;
28
29
  readonly title: string;
29
- readonly small?: boolean;
30
+ readonly size?: ComboboxSize;
30
31
  }>;
31
32
  export {};
@@ -24,8 +24,17 @@ const container = {
24
24
  backgroundColor: colors_1.INPUT_BACKGROUND,
25
25
  borderWidth: 1,
26
26
  borderStyle: 'solid',
27
+ borderRadius: 4,
28
+ fontFamily: 'inherit',
27
29
  maxWidth: '100%',
28
30
  };
31
+ const compactContainer = {
32
+ ...container,
33
+ boxSizing: 'border-box',
34
+ borderRadius: 0,
35
+ height: layout_1.COMPACT_CONTROL_ROW_HEIGHT + 2,
36
+ padding: '5px 6px',
37
+ };
29
38
  const smallContainer = {
30
39
  ...container,
31
40
  padding: '3px 4px',
@@ -34,16 +43,25 @@ const label = {
34
43
  flex: 1,
35
44
  overflow: 'hidden',
36
45
  textOverflow: 'ellipsis',
46
+ color: 'inherit',
47
+ fontFamily: 'inherit',
37
48
  fontSize: 14,
49
+ lineHeight: '21px',
50
+ minWidth: 0,
38
51
  textAlign: 'left',
39
52
  whiteSpace: 'nowrap',
40
53
  };
54
+ const compactLabel = {
55
+ ...label,
56
+ fontSize: 12,
57
+ lineHeight: '16px',
58
+ };
41
59
  const smallLabel = {
42
60
  ...label,
43
61
  fontSize: 11,
44
- lineHeight: 1,
62
+ lineHeight: '12px',
45
63
  };
46
- const Combobox = ({ values, selectedId, style: customStyle, title, small = false }) => {
64
+ const Combobox = ({ values, selectedId, style: customStyle, title, size: controlSize = 'default', }) => {
47
65
  const [hovered, setIsHovered] = (0, react_1.useState)(false);
48
66
  const [opened, setOpened] = (0, react_1.useState)(false);
49
67
  const ref = (0, react_1.useRef)(null);
@@ -163,7 +181,11 @@ const Combobox = ({ values, selectedId, style: customStyle, title, small = false
163
181
  const selected = values.find((v) => v.id === selectedId);
164
182
  const style = (0, react_1.useMemo)(() => {
165
183
  return {
166
- ...(small ? smallContainer : container),
184
+ ...(controlSize === 'small'
185
+ ? smallContainer
186
+ : controlSize === 'compact'
187
+ ? compactContainer
188
+ : container),
167
189
  ...(customStyle !== null && customStyle !== void 0 ? customStyle : {}),
168
190
  userSelect: 'none',
169
191
  WebkitUserSelect: 'none',
@@ -177,11 +199,14 @@ const Combobox = ({ values, selectedId, style: customStyle, title, small = false
177
199
  ? colors_1.WHITE_ALPHA_05
178
200
  : colors_1.BLACK_ALPHA_60,
179
201
  };
180
- }, [customStyle, hovered, opened, small]);
202
+ }, [controlSize, customStyle, hovered, opened]);
203
+ const selectedLabelStyle = controlSize === 'small'
204
+ ? smallLabel
205
+ : controlSize === 'compact'
206
+ ? compactLabel
207
+ : label;
181
208
  return (jsx_runtime_1.jsxs(jsx_runtime_1.Fragment, { children: [
182
- jsx_runtime_1.jsxs("button", { ref: ref, title: title, tabIndex: tabIndex, type: "button", style: style, className: is_menu_item_1.MENU_INITIATOR_CLASSNAME, children: [selected ? (jsx_runtime_1.jsx("div", { title: typeof selected.label === 'string' ? selected.label : undefined, style: small ? smallLabel : label, children: selected === null || selected === void 0 ? void 0 : selected.label })) : null, jsx_runtime_1.jsx(layout_1.Spacing, { x: small ? 0.5 : 1 }),
183
- " ",
184
- jsx_runtime_1.jsx(caret_1.CaretDown, { small: small })
209
+ jsx_runtime_1.jsxs("button", { ref: ref, title: title, tabIndex: tabIndex, type: "button", style: style, className: is_menu_item_1.MENU_INITIATOR_CLASSNAME, children: [selected ? (jsx_runtime_1.jsx("div", { title: typeof selected.label === 'string' ? selected.label : undefined, style: selectedLabelStyle, children: selected === null || selected === void 0 ? void 0 : selected.label })) : null, jsx_runtime_1.jsx(layout_1.Spacing, { x: controlSize === 'default' ? 1 : 0.5 }), ' ', jsx_runtime_1.jsx(caret_1.CaretDown, { small: controlSize === 'small' })
185
210
  ] }), portalStyle
186
211
  ? react_dom_1.default.createPortal(jsx_runtime_1.jsx("div", { style: styles_1.fullScreenOverlay, onPointerDown: onOverlayPointerDown, children: jsx_runtime_1.jsx("div", { style: styles_1.outerPortal, className: "css-reset", children: jsx_runtime_1.jsx(z_index_1.HigherZIndex, { onOutsideClick: onHide, onEscape: onHide, children: jsx_runtime_1.jsx("div", { style: portalStyle, children: jsx_runtime_1.jsx(MenuContent_1.MenuContent, { onNextMenu: noop_1.noop, onPreviousMenu: noop_1.noop, values: values, onHide: onHide, leaveLeftSpace: true, preselectIndex: values.findIndex((v) => selected && v.id === selected.id), topItemCanBeUnselected: false, fixedHeight: derivedMaxHeight }) }) }) }) }), (0, portals_1.getPortal)(currentZIndex))
187
212
  : null] }));
@@ -16,13 +16,13 @@ const getPlaybackRateLabel = (playbackRate) => {
16
16
  return `${playbackRate}x`;
17
17
  };
18
18
  const accessibilityLabel = 'Change the playback rate';
19
- const comboStyle = { width: 80 };
19
+ const comboStyle = { width: 64 };
20
20
  const PlaybackRateSelector = ({ playbackRate, setPlaybackRate }) => {
21
21
  const { canvasContent } = (0, react_1.useContext)(remotion_1.Internals.CompositionManager);
22
22
  const isStill = (0, is_current_selected_still_1.useIsStill)();
23
23
  const style = (0, react_1.useMemo)(() => {
24
24
  return {
25
- padding: ControlButton_1.CONTROL_BUTTON_PADDING,
25
+ padding: ControlButton_1.CONTROL_BUTTON_PADDING - 2,
26
26
  };
27
27
  }, []);
28
28
  const items = (0, react_1.useMemo)(() => {
@@ -54,6 +54,6 @@ const PlaybackRateSelector = ({ playbackRate, setPlaybackRate }) => {
54
54
  if (isStill || canvasContent === null || canvasContent.type === 'asset') {
55
55
  return null;
56
56
  }
57
- return (jsx_runtime_1.jsx("div", { style: style, "aria-label": accessibilityLabel, children: jsx_runtime_1.jsx(ComboBox_1.Combobox, { title: accessibilityLabel, style: comboStyle, selectedId: String(playbackRate), values: items }) }));
57
+ return (jsx_runtime_1.jsx("div", { style: style, "aria-label": accessibilityLabel, children: jsx_runtime_1.jsx(ComboBox_1.Combobox, { size: "compact", title: accessibilityLabel, style: comboStyle, selectedId: String(playbackRate), values: items }) }));
58
58
  };
59
59
  exports.PlaybackRateSelector = PlaybackRateSelector;
@@ -26,7 +26,7 @@ const SizeSelector_1 = require("./SizeSelector");
26
26
  const SnappingToggle_1 = require("./SnappingToggle");
27
27
  const TimelineZoomControls_1 = require("./Timeline/TimelineZoomControls");
28
28
  const TimelineInOutToggle_1 = require("./TimelineInOutToggle");
29
- const TOOLBAR_HEIGHT = 50;
29
+ const TOOLBAR_HEIGHT = 40;
30
30
  const container = {
31
31
  display: 'flex',
32
32
  justifyContent: 'center',
@@ -64,7 +64,7 @@ const scrollIndicatorRight = {
64
64
  };
65
65
  const sideContainer = {
66
66
  width: 300,
67
- height: 36,
67
+ height: 30,
68
68
  display: 'flex',
69
69
  flexDirection: 'row',
70
70
  alignItems: 'center',
@@ -169,7 +169,7 @@ const PreviewToolbar = ({ readOnlyStudio, bufferStateDelayInMilliseconds }) => {
169
169
  jsx_runtime_1.jsx(PreviewToolbarControl, { children: jsx_runtime_1.jsx(CheckboardToggle_1.CheckboardToggle, {}) }), jsx_runtime_1.jsx(PreviewToolbarControl, { children: jsx_runtime_1.jsx(OutlineToggle_1.OutlineToggle, { disabled: readOnlyStudio }) }), jsx_runtime_1.jsx(PreviewToolbarControl, { children: jsx_runtime_1.jsx(SnappingToggle_1.SnappingToggle, { disabled: readOnlyStudio }) })
170
170
  ] })) : null, jsx_runtime_1.jsx(layout_1.Spacing, { x: 1 }), canvasContent && isFullscreenSupported ? (jsx_runtime_1.jsx(PreviewToolbarControl, { children: jsx_runtime_1.jsx(FullscreenToggle_1.FullScreenToggle, {}) })) : null, jsx_runtime_1.jsx(layout_1.Flex, {}), isMobileLayout && (jsx_runtime_1.jsxs(jsx_runtime_1.Fragment, { children: [
171
171
  jsx_runtime_1.jsx(layout_1.Flex, {}), jsx_runtime_1.jsx(PreviewToolbarControl, { children: jsx_runtime_1.jsx(SizeSelector_1.SizeSelector, {}) }), isStill || isVideoComposition ? (jsx_runtime_1.jsx(PreviewToolbarControl, { children: jsx_runtime_1.jsx(PlaybackRateSelector_1.PlaybackRateSelector, { setPlaybackRate: setPlaybackRate, playbackRate: playbackRate }) })) : null] })), jsx_runtime_1.jsxs("div", { style: sideContainer, children: [
172
- jsx_runtime_1.jsx(layout_1.Flex, {}), !isMobileLayout && jsx_runtime_1.jsx(FpsCounter_1.FpsCounter, { playbackSpeed: playbackRate }), jsx_runtime_1.jsx(layout_1.Spacing, { x: 2 }), jsx_runtime_1.jsx(PreviewToolbarControl, { children: jsx_runtime_1.jsx(RenderButton_1.RenderButton, { readOnlyStudio: readOnlyStudio }) }), jsx_runtime_1.jsx(layout_1.Spacing, { x: 1.5 })
172
+ jsx_runtime_1.jsx(layout_1.Flex, {}), !isMobileLayout && jsx_runtime_1.jsx(FpsCounter_1.FpsCounter, { playbackSpeed: playbackRate }), jsx_runtime_1.jsx(layout_1.Spacing, { x: 2 }), jsx_runtime_1.jsx(PreviewToolbarControl, { children: jsx_runtime_1.jsx(RenderButton_1.RenderButton, { readOnlyStudio: readOnlyStudio, size: "compact" }) }), jsx_runtime_1.jsx(layout_1.Spacing, { x: 1.5 })
173
173
  ] }), jsx_runtime_1.jsx(PlaybackKeyboardShortcutsManager_1.PlaybackKeyboardShortcutsManager, { setPlaybackRate: setPlaybackRate }), jsx_runtime_1.jsx(PlaybackRatePersistor_1.PlaybackRatePersistor, {}), jsx_runtime_1.jsx("div", { ref: rightScrollIndicatorRef, style: scrollIndicatorRight })
174
174
  ] }));
175
175
  };
@@ -2,4 +2,5 @@ import React from 'react';
2
2
  export type RenderType = 'server-render' | 'client-render' | 'render-command';
3
3
  export declare const RenderButton: React.FC<{
4
4
  readonly readOnlyStudio: boolean;
5
+ readonly size?: 'default' | 'compact';
5
6
  }>;
@@ -65,9 +65,47 @@ const dropdownTriggerStyle = {
65
65
  const mainButtonContent = {
66
66
  paddingLeft: 4,
67
67
  paddingRight: 6,
68
+ minWidth: 0,
68
69
  };
69
70
  const label = {
71
+ color: 'inherit',
72
+ fontFamily: 'inherit',
70
73
  fontSize: 14,
74
+ lineHeight: '21px',
75
+ minWidth: 0,
76
+ overflow: 'hidden',
77
+ textOverflow: 'ellipsis',
78
+ whiteSpace: 'nowrap',
79
+ };
80
+ const compactSplitButtonSegmentHeight = layout_1.COMPACT_CONTROL_ROW_HEIGHT;
81
+ const compactMainButtonStyle = {
82
+ ...mainButtonStyle,
83
+ boxSizing: 'border-box',
84
+ height: compactSplitButtonSegmentHeight,
85
+ paddingLeft: 6,
86
+ paddingRight: 6,
87
+ paddingTop: 6,
88
+ paddingBottom: 6,
89
+ fontSize: 12,
90
+ };
91
+ const compactDropdownTriggerStyle = {
92
+ ...dropdownTriggerStyle,
93
+ boxSizing: 'border-box',
94
+ height: compactSplitButtonSegmentHeight,
95
+ paddingLeft: 5,
96
+ paddingRight: 5,
97
+ paddingTop: 6,
98
+ paddingBottom: 6,
99
+ };
100
+ const compactMainButtonContent = {
101
+ ...mainButtonContent,
102
+ paddingLeft: 2,
103
+ paddingRight: 4,
104
+ };
105
+ const compactLabel = {
106
+ ...label,
107
+ fontSize: 12,
108
+ lineHeight: '16px',
71
109
  };
72
110
  const RENDER_TYPE_STORAGE_KEY = 'remotion.renderType';
73
111
  const getInitialRenderType = (readOnlyStudio) => {
@@ -85,7 +123,7 @@ const getInitialRenderType = (readOnlyStudio) => {
85
123
  }
86
124
  return 'server-render';
87
125
  };
88
- const RenderButton = ({ readOnlyStudio, }) => {
126
+ const RenderButton = ({ readOnlyStudio, size: controlSize = 'default' }) => {
89
127
  const { inFrame, outFrame } = (0, in_out_1.useTimelineInOutFramePosition)();
90
128
  const { setSelectedModal } = (0, react_1.useContext)(modals_1.ModalsContext);
91
129
  const [preferredRenderType, setPreferredRenderType] = (0, react_1.useState)(() => getInitialRenderType(readOnlyStudio));
@@ -153,11 +191,12 @@ const RenderButton = ({ readOnlyStudio, }) => {
153
191
  const iconStyle = (0, react_1.useMemo)(() => {
154
192
  return {
155
193
  style: {
156
- height: 16,
194
+ height: controlSize === 'compact' ? 14 : 16,
157
195
  color: colors_1.CURRENT_COLOR,
196
+ flexShrink: 0,
158
197
  },
159
198
  };
160
- }, []);
199
+ }, [controlSize]);
161
200
  const video = remotion_1.Internals.useVideo();
162
201
  const { getCurrentFrame } = player_1.PlayerInternals.usePlayer();
163
202
  const { props } = (0, react_1.useContext)(remotion_1.Internals.EditorPropsContext);
@@ -385,10 +424,11 @@ const RenderButton = ({ readOnlyStudio, }) => {
385
424
  return {
386
425
  ...splitButtonContainer,
387
426
  borderColor: colors_1.BLACK_ALPHA_60,
427
+ borderRadius: controlSize === 'compact' ? 0 : 4,
388
428
  opacity: 1,
389
429
  cursor: 'pointer',
390
430
  };
391
- }, []);
431
+ }, [controlSize]);
392
432
  const renderLabel = renderType === 'server-render'
393
433
  ? 'Render'
394
434
  : renderType === 'render-command'
@@ -399,9 +439,13 @@ const RenderButton = ({ readOnlyStudio, }) => {
399
439
  }
400
440
  return (jsx_runtime_1.jsxs(jsx_runtime_1.Fragment, { children: [
401
441
  jsx_runtime_1.jsx("button", { style: { display: 'none' }, id: "render-modal-button-server", disabled: !canServerRender, onClick: () => openServerRenderModal(false), type: "button" }), ' ', jsx_runtime_1.jsx("button", { style: { display: 'none' }, id: "render-modal-button-client", onClick: openClientRenderModal, type: "button" }), jsx_runtime_1.jsxs("div", { ref: containerRef, style: containerStyle, title: tooltip, children: [
402
- jsx_runtime_1.jsx("button", { type: "button", style: mainButtonStyle, onClick: onClick, id: "render-modal-button", children: jsx_runtime_1.jsxs(layout_1.Row, { align: "center", style: mainButtonContent, children: [
403
- jsx_runtime_1.jsx(render_1.ThinRenderIcon, { fill: colors_1.CURRENT_COLOR_LOWERCASE, svgProps: iconStyle }), jsx_runtime_1.jsx(layout_1.Spacing, { x: 1 }), jsx_runtime_1.jsx("span", { style: label, children: renderLabel })
404
- ] }) }), jsx_runtime_1.jsx("div", { style: dividerStyle }), jsx_runtime_1.jsx("button", { ref: dropdownRef, type: "button", style: dropdownTriggerStyle, className: is_menu_item_1.MENU_INITIATOR_CLASSNAME, onPointerDown: onPointerDown, onClick: onClickDropdown, children: jsx_runtime_1.jsx(caret_1.CaretDown, {}) })
442
+ jsx_runtime_1.jsx("button", { type: "button", style: controlSize === 'compact' ? compactMainButtonStyle : mainButtonStyle, onClick: onClick, id: "render-modal-button", children: jsx_runtime_1.jsxs(layout_1.Row, { align: "center", style: controlSize === 'compact'
443
+ ? compactMainButtonContent
444
+ : mainButtonContent, children: [
445
+ jsx_runtime_1.jsx(render_1.ThinRenderIcon, { fill: colors_1.CURRENT_COLOR_LOWERCASE, svgProps: iconStyle }), jsx_runtime_1.jsx(layout_1.Spacing, { x: controlSize === 'compact' ? 0.75 : 1 }), jsx_runtime_1.jsx("span", { style: controlSize === 'compact' ? compactLabel : label, children: renderLabel })
446
+ ] }) }), jsx_runtime_1.jsx("div", { style: dividerStyle }), jsx_runtime_1.jsx("button", { ref: dropdownRef, type: "button", style: controlSize === 'compact'
447
+ ? compactDropdownTriggerStyle
448
+ : dropdownTriggerStyle, className: is_menu_item_1.MENU_INITIATOR_CLASSNAME, onPointerDown: onPointerDown, onClick: onClickDropdown, children: jsx_runtime_1.jsx(caret_1.CaretDown, {}) })
405
449
  ] }), portalStyle
406
450
  ? react_dom_1.default.createPortal(jsx_runtime_1.jsx("div", { style: styles_1.fullScreenOverlay, children: jsx_runtime_1.jsx("div", { style: styles_1.outerPortal, className: "css-reset", children: jsx_runtime_1.jsx(z_index_1.HigherZIndex, { onOutsideClick: onHideDropdown, onEscape: onHideDropdown, children: jsx_runtime_1.jsx("div", { style: portalStyle, onPointerDown: onMenuPointerDown, children: jsx_runtime_1.jsx(MenuContent_1.MenuContent, { onNextMenu: () => { }, onPreviousMenu: () => { }, values: dropdownValues, onHide: onHideDropdown, leaveLeftSpace: false, preselectIndex: dropdownValues.findIndex((v) => v.id === renderType), topItemCanBeUnselected: false, fixedHeight: derivedMaxHeight }) }) }) }) }), (0, portals_1.getPortal)(currentZIndex))
407
451
  : null] }));
@@ -47,7 +47,7 @@ const ZodDiscriminatedUnionEditor = ({ schema, setValue, value, mayPad, jsonPath
47
47
  return {
48
48
  discriminator,
49
49
  markup: (jsx_runtime_1.jsxs(Fieldset_1.Fieldset, { shouldPad: mayPad, children: [
50
- jsx_runtime_1.jsx(SchemaLabel_1.SchemaLabel, { handleClick: null, jsonPath: [...jsonPath, discriminator], onRemove: onRemove, suffix: null, valid: zodValidation.success }), jsx_runtime_1.jsx(ComboBox_1.Combobox, { title: "Select type", values: comboBoxValues, selectedId: value[discriminator], small: true })
50
+ jsx_runtime_1.jsx(SchemaLabel_1.SchemaLabel, { handleClick: null, jsonPath: [...jsonPath, discriminator], onRemove: onRemove, suffix: null, valid: zodValidation.success }), jsx_runtime_1.jsx(ComboBox_1.Combobox, { title: "Select type", values: comboBoxValues, selectedId: value[discriminator], size: "small" })
51
51
  ] }, 'replacement')),
52
52
  };
53
53
  }, [
@@ -39,7 +39,7 @@ const ZodEnumEditor = ({ schema, jsonPath, setValue, value, onRemove }) => {
39
39
  }, [enumValues, onChange, value]);
40
40
  const zodValidation = (0, react_1.useMemo)(() => (0, zod_schema_type_1.zodSafeParse)(schema, value), [schema, value]);
41
41
  return (jsx_runtime_1.jsxs(Fieldset_1.Fieldset, { shouldPad: true, children: [
42
- jsx_runtime_1.jsx(SchemaLabel_1.SchemaLabel, { handleClick: null, jsonPath: jsonPath, onRemove: onRemove, valid: zodValidation.success, suffix: null }), jsx_runtime_1.jsx("div", { style: isRoot ? undefined : container, children: jsx_runtime_1.jsx(ComboBox_1.Combobox, { values: comboBoxValues, selectedId: value, title: value, small: true }) }), jsx_runtime_1.jsx(ZodFieldValidation_1.ZodFieldValidation, { path: jsonPath, zodValidation: zodValidation })
42
+ jsx_runtime_1.jsx(SchemaLabel_1.SchemaLabel, { handleClick: null, jsonPath: jsonPath, onRemove: onRemove, valid: zodValidation.success, suffix: null }), jsx_runtime_1.jsx("div", { style: isRoot ? undefined : container, children: jsx_runtime_1.jsx(ComboBox_1.Combobox, { values: comboBoxValues, selectedId: value, title: value, size: "small" }) }), jsx_runtime_1.jsx(ZodFieldValidation_1.ZodFieldValidation, { path: jsonPath, zodValidation: zodValidation })
43
43
  ] }));
44
44
  };
45
45
  exports.ZodEnumEditor = ZodEnumEditor;
@@ -38,7 +38,7 @@ const ZodStaticFileEditor = ({ schema, jsonPath, setValue, value, onRemove, mayP
38
38
  });
39
39
  }, [onChange, staticFiles, value]);
40
40
  return (jsx_runtime_1.jsxs(Fieldset_1.Fieldset, { shouldPad: mayPad, children: [
41
- jsx_runtime_1.jsx(SchemaLabel_1.SchemaLabel, { handleClick: null, jsonPath: jsonPath, onRemove: onRemove, valid: zodValidation.success, suffix: null }), jsx_runtime_1.jsx("div", { style: isRoot ? undefined : container, children: jsx_runtime_1.jsx(ComboBox_1.Combobox, { values: comboBoxValues, selectedId: value, title: value, small: true }) }), jsx_runtime_1.jsx(ZodFieldValidation_1.ZodFieldValidation, { path: jsonPath, zodValidation: zodValidation })
41
+ jsx_runtime_1.jsx(SchemaLabel_1.SchemaLabel, { handleClick: null, jsonPath: jsonPath, onRemove: onRemove, valid: zodValidation.success, suffix: null }), jsx_runtime_1.jsx("div", { style: isRoot ? undefined : container, children: jsx_runtime_1.jsx(ComboBox_1.Combobox, { values: comboBoxValues, selectedId: value, title: value, size: "small" }) }), jsx_runtime_1.jsx(ZodFieldValidation_1.ZodFieldValidation, { path: jsonPath, zodValidation: zodValidation })
42
42
  ] }));
43
43
  };
44
44
  exports.ZodStaticFileEditor = ZodStaticFileEditor;
@@ -46,7 +46,7 @@ const getPreviewSizeLabel = (previewSize) => {
46
46
  };
47
47
  exports.getPreviewSizeLabel = getPreviewSizeLabel;
48
48
  const accessibilityLabel = 'Preview Size';
49
- const comboStyle = { width: 80 };
49
+ const comboStyle = { width: 64 };
50
50
  const getUniqueSizes = (size) => {
51
51
  const customPreviewSizes = [size, ...commonPreviewSizes];
52
52
  const uniqueSizes = [];
@@ -72,7 +72,7 @@ const SizeSelector = () => {
72
72
  const { canvasContent } = (0, react_1.useContext)(remotion_1.Internals.CompositionManager);
73
73
  const style = (0, react_1.useMemo)(() => {
74
74
  return {
75
- padding: ControlButton_1.CONTROL_BUTTON_PADDING,
75
+ padding: ControlButton_1.CONTROL_BUTTON_PADDING - 2,
76
76
  };
77
77
  }, []);
78
78
  const zoomable = (0, react_1.useMemo)(() => {
@@ -114,6 +114,6 @@ const SizeSelector = () => {
114
114
  if (!zoomable) {
115
115
  return null;
116
116
  }
117
- return (jsx_runtime_1.jsx("div", { style: style, "aria-label": accessibilityLabel, children: jsx_runtime_1.jsx(ComboBox_1.Combobox, { title: accessibilityLabel, style: comboStyle, selectedId: String(size.size), values: items }) }));
117
+ return (jsx_runtime_1.jsx("div", { style: style, "aria-label": accessibilityLabel, children: jsx_runtime_1.jsx(ComboBox_1.Combobox, { size: "compact", title: accessibilityLabel, style: comboStyle, selectedId: String(size.size), values: items }) }));
118
118
  };
119
119
  exports.SizeSelector = SizeSelector;
@@ -109,7 +109,7 @@ const TimelineStaticFileAssetField = ({ propStatus, effectiveValue, onSave, onDr
109
109
  },
110
110
  ];
111
111
  }, [current, onSelect, staticFiles, upload]);
112
- return (jsx_runtime_1.jsx(ComboBox_1.Combobox, { small: true, title: current, selectedId: current, values: items, style: comboboxStyle }));
112
+ return (jsx_runtime_1.jsx(ComboBox_1.Combobox, { size: "small", title: current, selectedId: current, values: items, style: comboboxStyle }));
113
113
  };
114
114
  const TimelineAssetField = (props) => {
115
115
  var _a;
@@ -37,6 +37,6 @@ const TimelineEnumField = ({ field, propStatus, effectiveValue, onSave, onDragVa
37
37
  disabled: false,
38
38
  }));
39
39
  }, [variantKeys, onSelect]);
40
- return (jsx_runtime_1.jsx(ComboBox_1.Combobox, { small: true, title: field.key, selectedId: current, values: items, style: comboboxStyle }));
40
+ return (jsx_runtime_1.jsx(ComboBox_1.Combobox, { size: "small", title: field.key, selectedId: current, values: items, style: comboboxStyle }));
41
41
  };
42
42
  exports.TimelineEnumField = TimelineEnumField;
@@ -19,13 +19,13 @@ const fieldNameBase = {
19
19
  minWidth: 0,
20
20
  };
21
21
  const TimelineFieldLabel = ({ rowDepth, selected, label, stacked = false }) => {
22
- const { basePadding } = (0, react_1.useContext)(TimelineRowLayoutContext_1.TimelineRowLayoutContext);
22
+ const { basePadding, highlightSelectedLabel } = (0, react_1.useContext)(TimelineRowLayoutContext_1.TimelineRowLayoutContext);
23
23
  const labelRowStyle = (0, react_1.useMemo)(() => ({
24
24
  ...(0, timeline_field_row_layout_1.getTimelineFieldLabelRowStyle)(rowDepth, basePadding),
25
- ...(0, TimelineSelection_1.getTimelineSelectedLabelStyle)(selected, true),
25
+ ...(0, TimelineSelection_1.getTimelineSelectedLabelStyle)(selected && highlightSelectedLabel, true),
26
26
  ...(stacked ? { flex: `0 0 ${timeline_layout_1.SCHEMA_FIELD_ROW_HEIGHT}px` } : null),
27
27
  alignSelf: 'stretch',
28
- }), [basePadding, rowDepth, selected, stacked]);
28
+ }), [basePadding, highlightSelectedLabel, rowDepth, selected, stacked]);
29
29
  const fieldNameStyle = (0, react_1.useMemo)(() => ({
30
30
  ...fieldNameBase,
31
31
  color: (0, TimelineSelection_1.getTimelineColor)(selected, true),
@@ -18,6 +18,9 @@ const TimelineKeyframeDiamondIcon_1 = require("./TimelineKeyframeDiamondIcon");
18
18
  const TimelineKeyframeTracksContext_1 = require("./TimelineKeyframeTracksContext");
19
19
  const TimelineSelection_1 = require("./TimelineSelection");
20
20
  const update_selected_easing_1 = require("./update-selected-easing");
21
+ const NAV_BUTTON_SIZE = 14;
22
+ const INSPECTOR_NAV_BUTTON_WIDTH = NAV_BUTTON_SIZE / 2;
23
+ const INSPECTOR_PREVIOUS_BUTTON_EXTRA_GAP = 1;
21
24
  const controlsContainerStyle = {
22
25
  alignItems: 'center',
23
26
  display: 'flex',
@@ -25,6 +28,12 @@ const controlsContainerStyle = {
25
28
  gap: 1,
26
29
  marginRight: 4,
27
30
  };
31
+ const inspectorControlsContainerStyle = {
32
+ ...controlsContainerStyle,
33
+ paddingLeft: NAV_BUTTON_SIZE -
34
+ INSPECTOR_NAV_BUTTON_WIDTH -
35
+ INSPECTOR_PREVIOUS_BUTTON_EXTRA_GAP,
36
+ };
28
37
  const navButtonStyle = {
29
38
  alignItems: 'center',
30
39
  background: 'none',
@@ -33,13 +42,20 @@ const navButtonStyle = {
33
42
  cursor: 'pointer',
34
43
  display: 'flex',
35
44
  flexShrink: 0,
36
- height: 14,
45
+ height: NAV_BUTTON_SIZE,
37
46
  justifyContent: 'center',
38
47
  lineHeight: 1,
39
48
  outline: 'none',
40
49
  padding: 0,
41
50
  userSelect: 'none',
42
- width: 14,
51
+ width: NAV_BUTTON_SIZE,
52
+ };
53
+ const inspectorNavButtonStyle = {
54
+ width: INSPECTOR_NAV_BUTTON_WIDTH,
55
+ };
56
+ const inspectorPreviousNavButtonStyle = {
57
+ ...inspectorNavButtonStyle,
58
+ marginRight: INSPECTOR_PREVIOUS_BUTTON_EXTRA_GAP,
43
59
  };
44
60
  const isKeyframedStatus = (status) => {
45
61
  return status.status === 'keyframed';
@@ -48,7 +64,7 @@ const diamondButtonStyle = {
48
64
  ...navButtonStyle,
49
65
  background: 'none',
50
66
  };
51
- const svgStyle = { display: 'block' };
67
+ const svgStyle = { display: 'block', flexShrink: 0 };
52
68
  const isKeyframeControlSelection = (selection) => {
53
69
  return (selection.type === 'sequence-prop' ||
54
70
  selection.type === 'sequence-effect-prop');
@@ -454,23 +470,27 @@ const TimelineKeyframeControls = ({ fieldKey, propStatus, nodePath, fileName, ke
454
470
  const nextDisabled = nextDisplayFrame === null;
455
471
  const previousStyle = (0, react_1.useMemo)(() => ({
456
472
  ...navButtonStyle,
473
+ ...(mode === 'inspector' ? inspectorPreviousNavButtonStyle : null),
457
474
  cursor: previousDisabled ? 'default' : 'pointer',
458
475
  opacity: previousDisabled ? 0.35 : 1,
459
476
  visibility: showNavigationButtons ? 'visible' : 'hidden',
460
- }), [previousDisabled, showNavigationButtons]);
477
+ }), [mode, previousDisabled, showNavigationButtons]);
461
478
  const nextStyle = (0, react_1.useMemo)(() => ({
462
479
  ...navButtonStyle,
480
+ ...(mode === 'inspector' ? inspectorNavButtonStyle : null),
463
481
  cursor: nextDisabled ? 'default' : 'pointer',
464
482
  opacity: nextDisabled ? 0.35 : 1,
465
483
  visibility: showNavigationButtons ? 'visible' : 'hidden',
466
- }), [nextDisabled, showNavigationButtons]);
484
+ }), [mode, nextDisabled, showNavigationButtons]);
467
485
  const diamondStyle = (0, react_1.useMemo)(() => ({
468
486
  ...diamondButtonStyle,
469
487
  cursor: canToggleKeyframe && clientId ? 'pointer' : 'default',
470
488
  opacity: canToggleKeyframe && clientId ? 1 : 0.35,
471
489
  }), [canToggleKeyframe, clientId]);
472
490
  const diamondColor = hasKeyframeAtCurrentFrame ? colors_1.BLUE : colors_1.LIGHT_TEXT;
473
- return (jsx_runtime_1.jsxs("div", { style: controlsContainerStyle, children: [
491
+ return (jsx_runtime_1.jsxs("div", { style: mode === 'inspector'
492
+ ? inspectorControlsContainerStyle
493
+ : controlsContainerStyle, children: [
474
494
  jsx_runtime_1.jsx("button", { type: "button", style: previousStyle, disabled: previousDisabled, onPointerDown: previousDisabled ? undefined : onPrevious, "aria-label": "Go to previous keyframe", title: "Previous keyframe", children: jsx_runtime_1.jsx("svg", { width: "14", height: "14", viewBox: "0 0 10 10", style: svgStyle, children: jsx_runtime_1.jsx("path", { d: "M7 1.5L3 5L7 8.5Z", fill: colors_1.LIGHT_GRAY }) }) }), jsx_runtime_1.jsx("button", { type: "button", style: diamondStyle, disabled: !canToggleKeyframe || !clientId, onPointerDown: canToggleKeyframe && clientId ? onToggleKeyframe : undefined, "aria-label": hasKeyframeAtCurrentFrame ? 'Remove keyframe' : 'Add keyframe', title: hasKeyframeAtCurrentFrame ? 'Remove keyframe' : 'Add keyframe', children: jsx_runtime_1.jsx(TimelineKeyframeDiamondIcon_1.TimelineKeyframeDiamondIcon, { color: diamondColor, size: 12 }) }), jsx_runtime_1.jsx("button", { type: "button", style: nextStyle, disabled: nextDisabled, onPointerDown: nextDisabled ? undefined : onNext, "aria-label": "Go to next keyframe", title: "Next keyframe", children: jsx_runtime_1.jsx("svg", { width: "14", height: "14", viewBox: "0 0 10 10", style: svgStyle, children: jsx_runtime_1.jsx("path", { d: "M3 1.5L7 5L3 8.5Z", fill: colors_1.LIGHT_GRAY }) }) })
475
495
  ] }));
476
496
  };
@@ -26,7 +26,7 @@ const keyframeControlsColumnBaseStyle = {
26
26
  };
27
27
  const TimelineRowChrome = ({ depth, eye, keyframeControls, arrow, children, style, selected, selectable, selectionItem, onSelect, showSelectedBackground, containsSelection, outerHeight, onDragLeave, onDragOver, onDrop, onDoubleClick, }) => {
28
28
  const ref = (0, react_1.useRef)(null);
29
- const { basePadding, keyframeControlsPadding } = (0, react_1.useContext)(TimelineRowLayoutContext_1.TimelineRowLayoutContext);
29
+ const { basePadding, keyframeControlsPadding, rowBorderRadius, rowHorizontalMargin, } = (0, react_1.useContext)(TimelineRowLayoutContext_1.TimelineRowLayoutContext);
30
30
  const indentWidth = (0, timeline_row_layout_1.getTimelineRowIndentWidth)(depth);
31
31
  (0, TimelineSelection_1.useTimelineFocusableItem)(selectionItem, ref);
32
32
  const keyframeControlsColumnStyle = (0, react_1.useMemo)(() => ({
@@ -64,7 +64,15 @@ const TimelineRowChrome = ({ depth, eye, keyframeControls, arrow, children, styl
64
64
  ...rowBase,
65
65
  ...style,
66
66
  backgroundColor: outerHeight === null ? highlightBackground : undefined,
67
- }), [style, outerHeight, highlightBackground]);
67
+ borderRadius: rowBorderRadius,
68
+ margin: `0 ${rowHorizontalMargin}px`,
69
+ }), [
70
+ style,
71
+ outerHeight,
72
+ highlightBackground,
73
+ rowBorderRadius,
74
+ rowHorizontalMargin,
75
+ ]);
68
76
  const outerStyle = (0, react_1.useMemo)(() => {
69
77
  if (outerHeight === null) {
70
78
  return undefined;