@remotion/studio 4.0.524 → 4.0.526

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 (230) hide show
  1. package/dist/api/focus-default-props-path.js +7 -1
  2. package/dist/api/restart-studio.d.ts +1 -1
  3. package/dist/api/restart-studio.js +1 -1
  4. package/dist/components/ActionTooltip.d.ts +2 -0
  5. package/dist/components/ActionTooltip.js +14 -4
  6. package/dist/components/AgentPrompt.d.ts +6 -0
  7. package/dist/components/AgentPrompt.js +107 -0
  8. package/dist/components/AppLaunchButton.js +2 -0
  9. package/dist/components/AssetFileIcon.js +2 -0
  10. package/dist/components/AssetSelectorItem.d.ts +1 -23
  11. package/dist/components/AssetSelectorItem.js +10 -200
  12. package/dist/components/AssetSelectorModal.d.ts +6 -0
  13. package/dist/components/AssetSelectorModal.js +174 -0
  14. package/dist/components/Canvas.js +21 -4
  15. package/dist/components/CaptionInspector.js +9 -3
  16. package/dist/components/CheckboardToggle.js +2 -1
  17. package/dist/{error-overlay/remotion-overlay → components}/CodeFrame.d.ts +2 -0
  18. package/dist/components/CodeFrame.js +77 -0
  19. package/dist/components/ColorPicker/AlphaSlider.js +1 -1
  20. package/dist/components/ColorPicker/HueSlider.js +1 -1
  21. package/dist/components/ColorPicker/SaturationValueArea.js +1 -1
  22. package/dist/components/CompositionSelector.js +1 -0
  23. package/dist/components/CompositionSelectorItem.js +7 -17
  24. package/dist/components/CurrentAsset.js +5 -4
  25. package/dist/components/EditorGuides/Guide.js +1 -1
  26. package/dist/components/ElementInstallConfirmation.js +100 -61
  27. package/dist/components/FilePreview.js +4 -0
  28. package/dist/components/FixComputedValueModal.js +64 -96
  29. package/dist/components/FullscreenToggle.js +1 -1
  30. package/dist/components/GenerateWithAgentModal.d.ts +9 -0
  31. package/dist/components/GenerateWithAgentModal.js +39 -0
  32. package/dist/components/GlobalKeybindings.js +14 -0
  33. package/dist/components/InlineEditableTitle.js +2 -0
  34. package/dist/components/InspectorLocationCopy.js +1 -1
  35. package/dist/components/InspectorOpenInEditor.d.ts +1 -0
  36. package/dist/components/InspectorOpenInEditor.js +25 -18
  37. package/dist/components/InspectorPanel/CollapsibleInspectorSection.d.ts +7 -0
  38. package/dist/components/InspectorPanel/CollapsibleInspectorSection.js +14 -0
  39. package/dist/components/InspectorPanel/CollapsibleInspectorSectionHeader.d.ts +1 -1
  40. package/dist/components/InspectorPanel/CollapsibleInspectorSectionHeader.js +19 -8
  41. package/dist/components/InspectorPanel/CompositionInspector.js +30 -13
  42. package/dist/components/InspectorPanel/CompositionInspectorHeader.js +6 -7
  43. package/dist/components/InspectorPanel/CompositionMetadata.js +4 -0
  44. package/dist/components/InspectorPanel/ConnectedCompositionsSection.js +6 -12
  45. package/dist/components/InspectorPanel/ElementLibraryButton.js +2 -0
  46. package/dist/components/InspectorPanel/GuideInspector.js +2 -3
  47. package/dist/components/InspectorPanel/KeyframeSettings.js +5 -6
  48. package/dist/components/InspectorPanel/MultiSequenceInspector.js +2 -1
  49. package/dist/components/InspectorPanel/SequenceInspectorHeader.js +4 -12
  50. package/dist/components/InspectorPanel/SequenceSelectionInspector.js +4 -3
  51. package/dist/components/InspectorPanel/common.d.ts +4 -0
  52. package/dist/components/InspectorPanel/common.js +14 -2
  53. package/dist/components/InspectorPanel/styles.d.ts +0 -3
  54. package/dist/components/InspectorPanel/styles.js +1 -27
  55. package/dist/components/InspectorPanel/use-composition-actions.d.ts +2 -0
  56. package/dist/components/InspectorPanel/use-composition-actions.js +15 -0
  57. package/dist/components/InspectorPanel/use-inspector-section-expanded.d.ts +1 -0
  58. package/dist/components/InspectorPanel/use-inspector-section-expanded.js +21 -0
  59. package/dist/components/InspectorSequenceSection.js +61 -43
  60. package/dist/components/InspectorSourceLocation.js +1 -0
  61. package/dist/components/KeyboardShortcutsSettings.js +12 -4
  62. package/dist/components/LoopToggle.js +2 -1
  63. package/dist/components/LutPreview.d.ts +4 -0
  64. package/dist/components/LutPreview.js +192 -0
  65. package/dist/components/Menu/MenuItem.js +1 -2
  66. package/dist/components/MenuBuildIndicator.js +1 -1
  67. package/dist/components/MenuCompositionName.js +4 -9
  68. package/dist/components/Modals.js +4 -6
  69. package/dist/components/ModelsSettings.js +15 -4
  70. package/dist/components/MuteToggle.js +2 -1
  71. package/dist/components/NewComposition/CodemodFooter.js +1 -0
  72. package/dist/components/NewComposition/DeleteComposition.js +42 -6
  73. package/dist/components/NewComposition/DeleteFolder.js +1 -0
  74. package/dist/components/NewComposition/DuplicateComposition.js +5 -0
  75. package/dist/components/NewComposition/InputDragger.js +2 -2
  76. package/dist/components/NewComposition/NewFolder.js +29 -2
  77. package/dist/components/NewComposition/RenameFolder.js +1 -0
  78. package/dist/components/NewComposition/duplicate-composition-api.d.ts +3 -2
  79. package/dist/components/NewComposition/duplicate-composition-api.js +9 -2
  80. package/dist/components/OutlineToggle.js +2 -1
  81. package/dist/components/PlayPause.js +1 -1
  82. package/dist/components/Preview.js +0 -3
  83. package/dist/components/PreviewToolbar.js +3 -6
  84. package/dist/components/PreviewToolbarOverflowButton.js +2 -1
  85. package/dist/components/QuickSwitcher/QuickSwitcherContent.js +1 -1
  86. package/dist/components/QuickSwitcher/QuickSwitcherResult.js +4 -9
  87. package/dist/components/RenderButton.js +40 -4
  88. package/dist/components/RenderModal/SchemaEditor/scroll-to-default-props-path.d.ts +1 -0
  89. package/dist/components/RenderModal/SchemaEditor/scroll-to-default-props-path.js +2 -1
  90. package/dist/components/RenderModal/WebRenderModal.js +10 -2
  91. package/dist/components/RenderModal/WebRenderModalBasic.js +1 -1
  92. package/dist/components/RenderModal/render-modals.js +3 -0
  93. package/dist/components/RenderQueue/RenderQueueCopyToClipboard.js +1 -1
  94. package/dist/components/RenderQueue/RenderQueueItemCancelButton.js +1 -1
  95. package/dist/components/RenderQueue/actions.d.ts +2 -1
  96. package/dist/components/RenderQueue/actions.js +2 -1
  97. package/dist/components/RendersTab.js +2 -0
  98. package/dist/components/RulersAndGuidesToggle.js +2 -1
  99. package/dist/components/SegmentedButton.d.ts +1 -0
  100. package/dist/components/SegmentedButton.js +9 -3
  101. package/dist/components/SelectedOutlineElement.js +22 -6
  102. package/dist/components/SelectedOutlinePolygon.js +4 -2
  103. package/dist/components/SettingsButton.js +11 -2
  104. package/dist/components/SettingsContext.d.ts +8 -0
  105. package/dist/components/SettingsContext.js +57 -2
  106. package/dist/components/SettingsModal.d.ts +1 -2
  107. package/dist/components/SettingsModal.js +27 -6
  108. package/dist/components/SettingsModalFooter.js +17 -3
  109. package/dist/components/SidebarCollapserControls.js +1 -1
  110. package/dist/components/SkillsSettings.d.ts +5 -0
  111. package/dist/components/SkillsSettings.js +49 -15
  112. package/dist/components/SnappingToggle.js +2 -1
  113. package/dist/components/Splitter/SplitterHandle.js +1 -2
  114. package/dist/components/Tabs/vertical.d.ts +1 -1
  115. package/dist/components/Tabs/vertical.js +16 -2
  116. package/dist/components/Timeline/EasingEditorModal.js +2 -2
  117. package/dist/components/Timeline/Timeline.js +10 -11
  118. package/dist/components/Timeline/TimelineAssetField.js +178 -9
  119. package/dist/components/Timeline/TimelineDragHandler.js +1 -2
  120. package/dist/components/Timeline/TimelineEffectItem.d.ts +1 -0
  121. package/dist/components/Timeline/TimelineEffectItem.js +2 -2
  122. package/dist/components/Timeline/TimelineEffectPropItem.d.ts +1 -0
  123. package/dist/components/Timeline/TimelineEffectPropItem.js +2 -2
  124. package/dist/components/Timeline/TimelineExpandedRow.js +2 -2
  125. package/dist/components/Timeline/TimelineHeightContainer.js +11 -1
  126. package/dist/components/Timeline/TimelineInOutDragHandler.js +1 -2
  127. package/dist/components/Timeline/TimelineKeyframeControls.js +15 -1
  128. package/dist/components/Timeline/TimelineLayerChildren.d.ts +3 -3
  129. package/dist/components/Timeline/TimelineLayerChildren.js +11 -9
  130. package/dist/components/Timeline/TimelineLayerEye.d.ts +1 -1
  131. package/dist/components/Timeline/TimelineLayerEye.js +6 -3
  132. package/dist/components/Timeline/TimelineList.js +9 -3
  133. package/dist/components/Timeline/TimelineSchemaField.js +10 -7
  134. package/dist/components/Timeline/TimelineSelection.d.ts +17 -4
  135. package/dist/components/Timeline/TimelineSelection.js +121 -52
  136. package/dist/components/Timeline/TimelineSequence.js +8 -8
  137. package/dist/components/Timeline/TimelineSequenceItem.d.ts +2 -0
  138. package/dist/components/Timeline/TimelineSequenceItem.js +29 -23
  139. package/dist/components/Timeline/TimelineSequenceRightEdgeDragHandle.js +3 -12
  140. package/dist/components/Timeline/TimelineTranslateField.js +25 -12
  141. package/dist/components/Timeline/TimelineVirtualization.d.ts +3 -3
  142. package/dist/components/Timeline/TimelineZoomControls.js +1 -1
  143. package/dist/components/Timeline/get-sequence-context-menu-items.d.ts +3 -1
  144. package/dist/components/Timeline/get-sequence-context-menu-items.js +152 -51
  145. package/dist/components/Timeline/normalize-font-weight-for-keyframe.d.ts +1 -0
  146. package/dist/components/Timeline/normalize-font-weight-for-keyframe.js +19 -0
  147. package/dist/components/Timeline/timeline-display-groups.d.ts +9 -0
  148. package/dist/components/Timeline/timeline-display-groups.js +66 -0
  149. package/dist/components/Timeline/timeline-field-display-utils.js +4 -2
  150. package/dist/components/Timeline/timeline-translate-utils.d.ts +17 -0
  151. package/dist/components/Timeline/timeline-translate-utils.js +53 -12
  152. package/dist/components/Timeline/use-open-sequence-in-apps.d.ts +2 -0
  153. package/dist/components/Timeline/use-open-sequence-in-apps.js +17 -0
  154. package/dist/components/Timeline/use-timeline-asset-drop.js +20 -6
  155. package/dist/components/Timeline/use-timeline-expanded-tree.d.ts +2 -1
  156. package/dist/components/Timeline/use-timeline-expanded-tree.js +1 -2
  157. package/dist/components/Timeline/use-timeline-keyframe-drag.js +4 -4
  158. package/dist/components/TimelineCombobox.js +1 -0
  159. package/dist/components/UndoRedoButtons.js +11 -0
  160. package/dist/components/UpdateStatusContext.d.ts +2 -2
  161. package/dist/components/UpdateStatusContext.js +6 -7
  162. package/dist/components/UpdatesSettings.js +6 -6
  163. package/dist/components/WebMcp.js +40 -41
  164. package/dist/components/asset-context-menu.d.ts +32 -0
  165. package/dist/components/asset-context-menu.js +242 -0
  166. package/dist/components/composition-menu-items.d.ts +4 -6
  167. package/dist/components/composition-menu-items.js +212 -42
  168. package/dist/components/folder-menu-items.js +44 -0
  169. package/dist/components/get-open-in-menu-items.d.ts +6 -5
  170. package/dist/components/get-open-in-menu-items.js +16 -10
  171. package/dist/components/import-assets.d.ts +24 -1
  172. package/dist/components/import-assets.js +3 -1
  173. package/dist/components/keyboard-shortcuts.d.ts +4 -4
  174. package/dist/components/keyboard-shortcuts.js +5 -0
  175. package/dist/components/selected-outline-order.js +18 -12
  176. package/dist/components/use-open-in-menu-apps.d.ts +14 -0
  177. package/dist/components/use-open-in-menu-apps.js +33 -0
  178. package/dist/error-overlay/remotion-overlay/ErrorDisplay.js +2 -2
  179. package/dist/error-overlay/remotion-overlay/OpenInEditor.d.ts +1 -0
  180. package/dist/error-overlay/remotion-overlay/OpenInEditor.js +3 -3
  181. package/dist/error-overlay/remotion-overlay/StackFrame.d.ts +5 -1
  182. package/dist/error-overlay/remotion-overlay/StackFrame.js +26 -19
  183. package/dist/esm/{LazyModels-hc33szyn.mjs → LazyModels-mtggyjye.mjs} +3 -3
  184. package/dist/esm/{LazyModels-sg40rjw6.mjs → LazyModels-nk7py0zt.mjs} +3 -3
  185. package/dist/esm/{TranscriptionModal-3ctnxpt6.mjs → TranscriptionModal-ymnx1c7m.mjs} +6 -6
  186. package/dist/esm/{VideoMattingModal-b0r7e60n.mjs → VideoMattingModal-05vpczks.mjs} +6 -6
  187. package/dist/esm/{index-er3mh6em.mjs → index-0gewwxse.mjs} +7031 -5834
  188. package/dist/esm/{index-q5xv20xx.mjs → index-4dsz9035.mjs} +8 -8
  189. package/dist/esm/{index-wbmp5srk.mjs → index-5bfxbpca.mjs} +1 -1
  190. package/dist/esm/{index-e3zwf3e7.mjs → index-5gd8k9yv.mjs} +1 -1
  191. package/dist/esm/{index-c37kme2v.mjs → index-bs39wngg.mjs} +4929 -3801
  192. package/dist/esm/{index-yfrysr5f.mjs → index-cdy8v54v.mjs} +17 -3
  193. package/dist/esm/{index-9qtvmwtx.mjs → index-eb5txqp6.mjs} +12 -9
  194. package/dist/esm/{index-q2epbw93.mjs → index-f97r9e2g.mjs} +4 -21
  195. package/dist/esm/{index-2j3d1g81.mjs → index-g7k2dvar.mjs} +1 -1
  196. package/dist/esm/{index-1b9skrrd.mjs → index-x40wwfmt.mjs} +3 -3
  197. package/dist/esm/index.mjs +12 -6
  198. package/dist/esm/internals.mjs +7 -7
  199. package/dist/esm/previewEntry.mjs +7 -7
  200. package/dist/helpers/client-id.d.ts +1 -0
  201. package/dist/helpers/client-id.js +8 -4
  202. package/dist/helpers/cube-lut.d.ts +12 -0
  203. package/dist/helpers/cube-lut.js +160 -0
  204. package/dist/helpers/get-git-menu-item.d.ts +4 -0
  205. package/dist/helpers/get-git-menu-item.js +8 -1
  206. package/dist/helpers/get-preview-file-type.d.ts +1 -1
  207. package/dist/helpers/get-preview-file-type.js +3 -0
  208. package/dist/helpers/get-sequence-double-click-action.d.ts +3 -3
  209. package/dist/helpers/get-sequence-double-click-action.js +2 -2
  210. package/dist/helpers/open-in-editor.d.ts +5 -2
  211. package/dist/helpers/open-in-editor.js +12 -4
  212. package/dist/helpers/pointer-session.d.ts +1 -0
  213. package/dist/helpers/pointer-session.js +10 -1
  214. package/dist/helpers/settings-tab-availability.d.ts +14 -0
  215. package/dist/helpers/settings-tab-availability.js +35 -0
  216. package/dist/helpers/studio-runtime-config.d.ts +1 -1
  217. package/dist/helpers/use-create-composition.js +5 -0
  218. package/dist/helpers/use-keybinding.d.ts +1 -1
  219. package/dist/helpers/use-keyboard-shortcut-label.d.ts +2 -2
  220. package/dist/helpers/use-media-metadata.js +5 -1
  221. package/dist/helpers/use-menu-structure.js +21 -13
  222. package/dist/helpers/use-rename-composition.js +6 -1
  223. package/dist/icons/lut.d.ts +4 -0
  224. package/dist/icons/lut.js +6 -0
  225. package/dist/icons/sparkles.d.ts +4 -0
  226. package/dist/icons/sparkles.js +6 -0
  227. package/dist/state/modals.d.ts +25 -3
  228. package/dist/state/z-index.js +1 -3
  229. package/package.json +19 -19
  230. package/dist/error-overlay/remotion-overlay/CodeFrame.js +0 -62
@@ -0,0 +1,242 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.useAssetContextMenuItems = exports.getAssetContextMenuItems = exports.getAssetActionAvailability = void 0;
4
+ const react_1 = require("react");
5
+ const no_react_1 = require("remotion/no-react");
6
+ const browser_studio_operations_1 = require("../helpers/browser-studio-operations");
7
+ const client_id_1 = require("../helpers/client-id");
8
+ const copy_text_1 = require("../helpers/copy-text");
9
+ const get_file_manager_name_1 = require("../helpers/get-file-manager-name");
10
+ const get_preview_file_type_1 = require("../helpers/get-preview-file-type");
11
+ const open_in_remotion_convert_1 = require("../helpers/open-in-remotion-convert");
12
+ const modals_1 = require("../state/modals");
13
+ const NotificationCenter_1 = require("./Notifications/NotificationCenter");
14
+ const open_in_new_window_1 = require("./open-in-new-window");
15
+ const actions_1 = require("./RenderQueue/actions");
16
+ const use_delete_asset_1 = require("./use-delete-asset");
17
+ const getAssetActionAvailability = ({ browserStudioCanMutateAssets, readOnlyStudio, connectionStatus, publicFolderExists, }) => {
18
+ return {
19
+ mutationsDisabled: browserStudioCanMutateAssets !== true &&
20
+ (readOnlyStudio || connectionStatus !== 'connected'),
21
+ fileExplorerDisabled: browserStudioCanMutateAssets !== null ||
22
+ publicFolderExists === null ||
23
+ readOnlyStudio ||
24
+ connectionStatus !== 'connected',
25
+ };
26
+ };
27
+ exports.getAssetActionAvailability = getAssetActionAvailability;
28
+ const getAssetContextMenuItems = ({ relativePath, fileManagerName, copyFileName, copyStaticFilePath, copyAbsolutePath, openAssetInConvert, openAssetInExplorer, renameAsset, deleteAsset, fileExplorerAvailable, fileExplorerDisabled, mutationsDisabled, }) => {
29
+ const previewFileType = (0, get_preview_file_type_1.getPreviewFileType)(relativePath);
30
+ const canOpenInConvert = previewFileType === 'audio' || previewFileType === 'video';
31
+ const items = [
32
+ (0, open_in_new_window_1.getOpenInNewWindowMenuItem)(`/assets/${relativePath}`),
33
+ canOpenInConvert
34
+ ? {
35
+ id: 'open-asset-in-convert',
36
+ keyHint: null,
37
+ label: 'Open in Remotion Convert',
38
+ leftItem: null,
39
+ onClick: openAssetInConvert,
40
+ quickSwitcherLabel: 'Open asset in Remotion Convert',
41
+ subMenu: null,
42
+ type: 'item',
43
+ value: 'open-asset-in-convert',
44
+ }
45
+ : null,
46
+ {
47
+ type: 'divider',
48
+ id: 'open-in-new-window-divider',
49
+ },
50
+ {
51
+ id: 'copy-asset-file-name',
52
+ keyHint: null,
53
+ label: 'Copy file name',
54
+ leftItem: null,
55
+ onClick: copyFileName,
56
+ quickSwitcherLabel: 'Copy asset file name',
57
+ subMenu: null,
58
+ type: 'item',
59
+ value: 'copy-asset-file-name',
60
+ },
61
+ {
62
+ id: 'copy-asset-static-file-path',
63
+ keyHint: null,
64
+ label: 'Copy staticFile() path',
65
+ leftItem: null,
66
+ onClick: copyStaticFilePath,
67
+ quickSwitcherLabel: 'Copy staticFile() path',
68
+ subMenu: null,
69
+ type: 'item',
70
+ value: 'copy-asset-static-file-path',
71
+ },
72
+ copyAbsolutePath
73
+ ? {
74
+ id: 'copy-asset-absolute-path',
75
+ keyHint: null,
76
+ label: 'Copy absolute path',
77
+ leftItem: null,
78
+ onClick: copyAbsolutePath,
79
+ quickSwitcherLabel: 'Copy asset absolute path',
80
+ subMenu: null,
81
+ type: 'item',
82
+ value: 'copy-asset-absolute-path',
83
+ }
84
+ : null,
85
+ {
86
+ type: 'divider',
87
+ id: 'asset-file-actions-divider',
88
+ },
89
+ fileExplorerAvailable
90
+ ? {
91
+ id: 'open-asset-in-explorer',
92
+ keyHint: null,
93
+ label: `Show in ${fileManagerName}`,
94
+ leftItem: null,
95
+ onClick: openAssetInExplorer,
96
+ quickSwitcherLabel: `Show asset in ${fileManagerName}`,
97
+ subMenu: null,
98
+ type: 'item',
99
+ value: 'open-asset-in-explorer',
100
+ disabled: fileExplorerDisabled,
101
+ }
102
+ : null,
103
+ {
104
+ id: 'rename-asset',
105
+ keyHint: null,
106
+ label: 'Rename...',
107
+ leftItem: null,
108
+ onClick: renameAsset,
109
+ quickSwitcherLabel: 'Rename asset...',
110
+ subMenu: null,
111
+ type: 'item',
112
+ value: 'rename-asset',
113
+ disabled: mutationsDisabled,
114
+ },
115
+ {
116
+ id: 'delete-asset',
117
+ keyHint: null,
118
+ label: 'Delete...',
119
+ leftItem: null,
120
+ onClick: deleteAsset,
121
+ quickSwitcherLabel: 'Delete asset...',
122
+ subMenu: null,
123
+ type: 'item',
124
+ value: 'delete-asset',
125
+ disabled: mutationsDisabled,
126
+ },
127
+ ];
128
+ return items.filter(no_react_1.NoReactInternals.truthy);
129
+ };
130
+ exports.getAssetContextMenuItems = getAssetContextMenuItems;
131
+ const useAssetContextMenuItems = ({ relativePath, readOnlyStudio, }) => {
132
+ var _a;
133
+ const fileManagerName = (0, get_file_manager_name_1.getFileManagerName)(window.remotion_fileSystemPlatform);
134
+ const { setSelectedModal } = (0, react_1.useContext)(modals_1.SetSelectedModalContext);
135
+ const connectionStatus = (0, react_1.useContext)(client_id_1.StudioServerConnectionCtx)
136
+ .previewServerState.type;
137
+ const fileName = (_a = relativePath === null || relativePath === void 0 ? void 0 : relativePath.split('/').pop()) !== null && _a !== void 0 ? _a : null;
138
+ const copyFileName = (0, react_1.useCallback)(() => {
139
+ if (fileName === null) {
140
+ return;
141
+ }
142
+ (0, copy_text_1.copyText)(fileName)
143
+ .then(() => {
144
+ (0, NotificationCenter_1.showNotification)(`Copied '${fileName}' to clipboard`, 1000);
145
+ })
146
+ .catch((err) => {
147
+ (0, NotificationCenter_1.showNotification)(`Could not copy: ${err.message}`, 2000);
148
+ });
149
+ }, [fileName]);
150
+ const copyStaticFilePath = (0, react_1.useCallback)(() => {
151
+ if (relativePath === null) {
152
+ return;
153
+ }
154
+ const content = `staticFile("${relativePath}")`;
155
+ (0, copy_text_1.copyText)(content)
156
+ .then(() => {
157
+ (0, NotificationCenter_1.showNotification)(`Copied '${content}' to clipboard`, 1000);
158
+ })
159
+ .catch((err) => {
160
+ (0, NotificationCenter_1.showNotification)(`Could not copy: ${err.message}`, 2000);
161
+ });
162
+ }, [relativePath]);
163
+ const copyAbsolutePath = (0, react_1.useCallback)(() => {
164
+ if (relativePath === null || window.remotion_publicFolderExists === null) {
165
+ return;
166
+ }
167
+ const content = `${window.remotion_publicFolderExists}/${relativePath}`;
168
+ (0, copy_text_1.copyText)(content)
169
+ .then(() => {
170
+ (0, NotificationCenter_1.showNotification)(`Copied '${content}' to clipboard`, 1000);
171
+ })
172
+ .catch((err) => {
173
+ (0, NotificationCenter_1.showNotification)(`Could not copy: ${err.message}`, 2000);
174
+ });
175
+ }, [relativePath]);
176
+ const openAssetInConvert = (0, react_1.useCallback)(() => {
177
+ if (relativePath === null) {
178
+ return;
179
+ }
180
+ (0, open_in_remotion_convert_1.openInRemotionConvert)({ relativePath });
181
+ }, [relativePath]);
182
+ const openAssetInExplorer = (0, react_1.useCallback)(() => {
183
+ if (relativePath === null || !window.remotion_publicFolderExists) {
184
+ (0, NotificationCenter_1.showNotification)('Could not find the public folder', 2000);
185
+ return;
186
+ }
187
+ (0, actions_1.openInFileExplorer)({
188
+ directory: window.remotion_publicFolderExists + '/' + relativePath,
189
+ }).catch((err) => {
190
+ (0, NotificationCenter_1.showNotification)(`Could not open file: ${err.message}`, 2000);
191
+ });
192
+ }, [relativePath]);
193
+ const { mutationsDisabled, fileExplorerDisabled } = (0, exports.getAssetActionAvailability)({
194
+ browserStudioCanMutateAssets: (0, browser_studio_operations_1.getBrowserStudioOperations)() === null ? null : true,
195
+ readOnlyStudio,
196
+ connectionStatus,
197
+ publicFolderExists: window.remotion_publicFolderExists,
198
+ });
199
+ const deleteAsset = (0, use_delete_asset_1.useDeleteAsset)(relativePath);
200
+ const renameAsset = (0, react_1.useCallback)(() => {
201
+ if (relativePath === null) {
202
+ return;
203
+ }
204
+ setSelectedModal({
205
+ type: 'rename-static-file',
206
+ relativePath,
207
+ });
208
+ }, [relativePath, setSelectedModal]);
209
+ const getContextMenuItems = (0, react_1.useCallback)(() => {
210
+ if (relativePath === null) {
211
+ return [];
212
+ }
213
+ return (0, exports.getAssetContextMenuItems)({
214
+ relativePath,
215
+ fileManagerName,
216
+ copyFileName,
217
+ copyStaticFilePath,
218
+ copyAbsolutePath: window.remotion_publicFolderExists === null ? null : copyAbsolutePath,
219
+ openAssetInConvert,
220
+ openAssetInExplorer,
221
+ renameAsset,
222
+ deleteAsset,
223
+ fileExplorerAvailable: (0, browser_studio_operations_1.getBrowserStudioOperations)() === null,
224
+ fileExplorerDisabled,
225
+ mutationsDisabled,
226
+ });
227
+ }, [
228
+ copyFileName,
229
+ copyStaticFilePath,
230
+ copyAbsolutePath,
231
+ deleteAsset,
232
+ fileExplorerDisabled,
233
+ fileManagerName,
234
+ mutationsDisabled,
235
+ openAssetInConvert,
236
+ openAssetInExplorer,
237
+ renameAsset,
238
+ relativePath,
239
+ ]);
240
+ return { fileExplorerDisabled, fileManagerName, getContextMenuItems };
241
+ };
242
+ exports.useAssetContextMenuItems = useAssetContextMenuItems;
@@ -1,9 +1,9 @@
1
- import type { EditorPickerId } from '@remotion/studio-shared';
2
1
  import type { SetStateAction } from 'react';
3
2
  import type { ResolvedStackLocation } from 'remotion';
4
3
  import type { ModalState } from '../state/modals';
5
4
  import type { ComboboxValue } from './NewComposition/ComboBox';
6
- export declare const getCompositionMenuItems: ({ composition, connectionStatus, resolvedLocation, setSelectedModal, closeMenu, readOnlyStudio, includeCompositionManagementItems, editorId, editorName, }: {
5
+ import type { OpenInMenuApps } from './use-open-in-menu-apps';
6
+ export declare const getCompositionMenuItems: ({ composition, connectionStatus, resolvedLocation, setSelectedModal, closeMenu, readOnlyStudio, includeCompositionManagementItems, openInApps, }: {
7
7
  composition: import("remotion").AnyComposition | null;
8
8
  connectionStatus: "connected" | "disconnected" | "init";
9
9
  resolvedLocation: ResolvedStackLocation | null;
@@ -11,8 +11,7 @@ export declare const getCompositionMenuItems: ({ composition, connectionStatus,
11
11
  closeMenu: () => void;
12
12
  readOnlyStudio: boolean;
13
13
  includeCompositionManagementItems: boolean;
14
- editorId: EditorPickerId | null;
15
- editorName: string | null;
14
+ openInApps: OpenInMenuApps;
16
15
  }) => ComboboxValue[];
17
16
  export declare const getCompositionContextMenuItems: (args: Omit<{
18
17
  composition: import("remotion").AnyComposition | null;
@@ -22,8 +21,7 @@ export declare const getCompositionContextMenuItems: (args: Omit<{
22
21
  closeMenu: () => void;
23
22
  readOnlyStudio: boolean;
24
23
  includeCompositionManagementItems: boolean;
25
- editorId: EditorPickerId | null;
26
- editorName: string | null;
24
+ openInApps: OpenInMenuApps;
27
25
  }, "includeCompositionManagementItems"> & {
28
26
  readonly includeCompositionManagementItems: boolean;
29
27
  }) => ComboboxValue[];
@@ -3,11 +3,15 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.getCompositionContextMenuItems = exports.getCompositionMenuItems = void 0;
4
4
  const no_react_1 = require("remotion/no-react");
5
5
  const format_file_location_1 = require("../helpers/format-file-location");
6
+ const get_git_menu_item_1 = require("../helpers/get-git-menu-item");
6
7
  const open_in_editor_1 = require("../helpers/open-in-editor");
8
+ const get_open_in_menu_items_1 = require("./get-open-in-menu-items");
7
9
  const NotificationCenter_1 = require("./Notifications/NotificationCenter");
8
10
  const open_in_new_window_1 = require("./open-in-new-window");
9
- const getCompositionMenuItems = ({ composition, connectionStatus, resolvedLocation, setSelectedModal, closeMenu, readOnlyStudio, includeCompositionManagementItems, editorId, editorName, }) => {
11
+ const actions_1 = require("./RenderQueue/actions");
12
+ const getCompositionMenuItems = ({ composition, connectionStatus, resolvedLocation, setSelectedModal, closeMenu, readOnlyStudio, includeCompositionManagementItems, openInApps, }) => {
10
13
  var _a;
14
+ const { canOpenDesktopApps, canOpenInEditor, codingAgentInfo, defaultEditorId, defaultEditorName, editorInfo, onConfigureApps, } = openInApps;
11
15
  const fileLocation = (0, format_file_location_1.formatFileLocation)({
12
16
  location: resolvedLocation,
13
17
  root: window.remotion_cwd,
@@ -17,68 +21,234 @@ const getCompositionMenuItems = ({ composition, connectionStatus, resolvedLocati
17
21
  name: (_a = composition === null || composition === void 0 ? void 0 : composition.id) !== null && _a !== void 0 ? _a : null,
18
22
  root: window.remotion_cwd,
19
23
  });
20
- const showInEditorDisabled = !editorId ||
21
- !composition ||
22
- connectionStatus !== 'connected' ||
23
- !resolvedLocation;
24
- const openComponentInEditorDisabled = showInEditorDisabled || !(resolvedLocation === null || resolvedLocation === void 0 ? void 0 : resolvedLocation.source);
24
+ const openCompositionInEditorDisabled = !defaultEditorId || !composition || !canOpenInEditor || !resolvedLocation;
25
+ const openComponentInEditorDisabled = openCompositionInEditorDisabled || !(resolvedLocation === null || resolvedLocation === void 0 ? void 0 : resolvedLocation.source);
26
+ const gitSourceName = window.remotion_gitSource
27
+ ? (0, get_git_menu_item_1.getGitSourceName)(window.remotion_gitSource)
28
+ : null;
29
+ const defaultOpenInTarget = (0, get_git_menu_item_1.getDefaultOpenInTarget)({ canOpenInEditor });
30
+ const defaultOpenInName = defaultOpenInTarget === 'editor' ? defaultEditorName : gitSourceName;
31
+ const openCompositionInGitSourceDisabled = !composition || !resolvedLocation;
32
+ const openComponentInGitSourceDisabled = openCompositionInGitSourceDisabled ||
33
+ !(resolvedLocation === null || resolvedLocation === void 0 ? void 0 : resolvedLocation.source) ||
34
+ (!readOnlyStudio && connectionStatus !== 'connected');
25
35
  const copyFileLocationDisabled = !composition || !fileLocation;
36
+ const openWithCodingAgent = async (codingAgentId, codingAgentName) => {
37
+ try {
38
+ const response = await (0, open_in_editor_1.openInCodingAgent)(codingAgentId, codingAgentId === 'copilot' ? null : contextForAgents);
39
+ if (!response.success) {
40
+ (0, NotificationCenter_1.showNotification)(`Could not open ${codingAgentName}`, 2000);
41
+ }
42
+ }
43
+ catch (err) {
44
+ (0, NotificationCenter_1.showNotification)(err.message, 2000);
45
+ }
46
+ };
47
+ const openCompositionWithEditor = async (editorId) => {
48
+ closeMenu();
49
+ if (!composition || !resolvedLocation) {
50
+ return;
51
+ }
52
+ try {
53
+ await (0, open_in_editor_1.openOriginalPositionInEditor)(resolvedLocation, editorId);
54
+ }
55
+ catch (err) {
56
+ (0, NotificationCenter_1.showNotification)(err.message, 2000);
57
+ }
58
+ };
59
+ const openComponentWithEditor = async (editorId) => {
60
+ closeMenu();
61
+ if (!composition || !(resolvedLocation === null || resolvedLocation === void 0 ? void 0 : resolvedLocation.source)) {
62
+ return;
63
+ }
64
+ try {
65
+ await (0, open_in_editor_1.openCompositionComponentInEditor)({
66
+ compositionFile: resolvedLocation.source,
67
+ compositionId: composition.id,
68
+ editorId,
69
+ });
70
+ }
71
+ catch (err) {
72
+ (0, NotificationCenter_1.showNotification)(err.message, 2000);
73
+ }
74
+ };
75
+ const openComponentInGitSource = async () => {
76
+ closeMenu();
77
+ if (!composition || !(resolvedLocation === null || resolvedLocation === void 0 ? void 0 : resolvedLocation.source)) {
78
+ return;
79
+ }
80
+ try {
81
+ const info = await (0, open_in_editor_1.loadCompositionComponentInfo)({
82
+ compositionFile: resolvedLocation.source,
83
+ compositionId: composition.id,
84
+ });
85
+ (0, get_git_menu_item_1.openGitSource)({ folder: false, location: info.location });
86
+ }
87
+ catch (err) {
88
+ (0, NotificationCenter_1.showNotification)(err.message, 2000);
89
+ }
90
+ };
91
+ const openCompositionInFileExplorer = () => {
92
+ if (!(resolvedLocation === null || resolvedLocation === void 0 ? void 0 : resolvedLocation.source)) {
93
+ return;
94
+ }
95
+ (0, actions_1.openInFileExplorer)({ directory: resolvedLocation.source }).catch((err) => {
96
+ (0, NotificationCenter_1.showNotification)(`Could not open file: ${err.message}`, 2000);
97
+ });
98
+ };
99
+ const openComponentInFileExplorer = async () => {
100
+ if (!composition || !(resolvedLocation === null || resolvedLocation === void 0 ? void 0 : resolvedLocation.source)) {
101
+ return;
102
+ }
103
+ try {
104
+ const info = await (0, open_in_editor_1.loadCompositionComponentInfo)({
105
+ compositionFile: resolvedLocation.source,
106
+ compositionId: composition.id,
107
+ });
108
+ await (0, actions_1.openInFileExplorer)({ directory: info.location.source });
109
+ }
110
+ catch (err) {
111
+ (0, NotificationCenter_1.showNotification)(`Could not open file: ${err.message}`, 2000);
112
+ }
113
+ };
114
+ const commonOpenInMenuItems = {
115
+ canOpenDesktopApps,
116
+ codingAgentInfo,
117
+ editorInfo,
118
+ excludeCodingAgentId: null,
119
+ excludeEditorId: defaultOpenInTarget === 'editor' ? defaultEditorId : null,
120
+ excludeGitSource: defaultOpenInTarget === 'git-source',
121
+ folder: false,
122
+ onConfigureApps,
123
+ onOpenInCodingAgent: (codingAgentId, name) => {
124
+ openWithCodingAgent(codingAgentId, name).catch(() => undefined);
125
+ },
126
+ onOpenInGitClient: () => undefined,
127
+ onOpenInTerminal: null,
128
+ };
129
+ const compositionOpenInMenuItems = (0, get_open_in_menu_items_1.getOpenInMenuItems)({
130
+ ...commonOpenInMenuItems,
131
+ editorDisabled: openCompositionInEditorDisabled,
132
+ fileManagerDisabled: !(resolvedLocation === null || resolvedLocation === void 0 ? void 0 : resolvedLocation.source) || connectionStatus !== 'connected',
133
+ gitSourceDisabled: openCompositionInGitSourceDisabled,
134
+ onOpenInEditor: (editorId) => {
135
+ openCompositionWithEditor(editorId).catch(() => undefined);
136
+ },
137
+ onOpenInFileExplorer: openCompositionInFileExplorer,
138
+ onOpenInGitSource: () => {
139
+ closeMenu();
140
+ (0, get_git_menu_item_1.openGitSource)({ folder: false, location: resolvedLocation });
141
+ },
142
+ });
143
+ const componentOpenInMenuItems = (0, get_open_in_menu_items_1.getOpenInMenuItems)({
144
+ ...commonOpenInMenuItems,
145
+ editorDisabled: openComponentInEditorDisabled,
146
+ fileManagerDisabled: !(resolvedLocation === null || resolvedLocation === void 0 ? void 0 : resolvedLocation.source) || connectionStatus !== 'connected',
147
+ gitSourceDisabled: openComponentInGitSourceDisabled,
148
+ onOpenInEditor: (editorId) => {
149
+ openComponentWithEditor(editorId).catch(() => undefined);
150
+ },
151
+ onOpenInFileExplorer: () => {
152
+ openComponentInFileExplorer().catch(() => undefined);
153
+ },
154
+ onOpenInGitSource: () => {
155
+ openComponentInGitSource().catch(() => undefined);
156
+ },
157
+ });
158
+ const hasOpenInItems = defaultOpenInName !== null ||
159
+ compositionOpenInMenuItems.length > 0 ||
160
+ componentOpenInMenuItems.length > 0;
26
161
  return [
27
- editorName
162
+ defaultOpenInTarget && defaultOpenInName
28
163
  ? {
29
- id: 'show-in-editor',
164
+ id: defaultOpenInTarget === 'editor'
165
+ ? 'show-in-editor'
166
+ : 'open-composition-in-git-source',
30
167
  keyHint: null,
31
- label: `Open composition in ${editorName}`,
168
+ label: `Open composition in ${defaultOpenInName}`,
32
169
  leftItem: null,
33
- onClick: async () => {
34
- closeMenu();
35
- if (!composition || !resolvedLocation || !editorId) {
36
- return;
37
- }
38
- try {
39
- await (0, open_in_editor_1.openOriginalPositionInEditor)(resolvedLocation, editorId);
170
+ onClick: () => {
171
+ if (defaultOpenInTarget === 'editor' && defaultEditorId !== null) {
172
+ openCompositionWithEditor(defaultEditorId).catch(() => undefined);
40
173
  }
41
- catch (err) {
42
- (0, NotificationCenter_1.showNotification)(err.message, 2000);
174
+ else if (defaultOpenInTarget === 'git-source') {
175
+ closeMenu();
176
+ (0, get_git_menu_item_1.openGitSource)({ folder: false, location: resolvedLocation });
43
177
  }
44
178
  },
45
- quickSwitcherLabel: `Open composition in ${editorName}`,
179
+ quickSwitcherLabel: `Open composition in ${defaultOpenInName}`,
46
180
  subMenu: null,
47
181
  type: 'item',
48
- value: 'show-in-editor',
49
- disabled: showInEditorDisabled,
182
+ value: defaultOpenInTarget === 'editor'
183
+ ? 'show-in-editor'
184
+ : 'open-composition-in-git-source',
185
+ disabled: defaultOpenInTarget === 'editor'
186
+ ? openCompositionInEditorDisabled
187
+ : openCompositionInGitSourceDisabled,
50
188
  }
51
189
  : null,
52
- editorName
190
+ compositionOpenInMenuItems.length > 0
53
191
  ? {
54
- id: 'open-component-in-editor',
192
+ id: 'open-composition-in-another-app',
55
193
  keyHint: null,
56
- label: `Open component in ${editorName}`,
194
+ label: 'Open composition in...',
57
195
  leftItem: null,
58
- onClick: async () => {
59
- closeMenu();
60
- if (!composition || !(resolvedLocation === null || resolvedLocation === void 0 ? void 0 : resolvedLocation.source) || !editorId) {
61
- return;
62
- }
63
- try {
64
- await (0, open_in_editor_1.openCompositionComponentInEditor)({
65
- compositionFile: resolvedLocation.source,
66
- compositionId: composition.id,
67
- editorId,
68
- });
196
+ onClick: () => undefined,
197
+ quickSwitcherLabel: null,
198
+ subMenu: {
199
+ items: compositionOpenInMenuItems,
200
+ leaveLeftSpace: true,
201
+ preselectIndex: false,
202
+ },
203
+ type: 'item',
204
+ value: 'open-composition-in-another-app',
205
+ }
206
+ : null,
207
+ defaultOpenInTarget && defaultOpenInName
208
+ ? {
209
+ id: defaultOpenInTarget === 'editor'
210
+ ? 'open-component-in-editor'
211
+ : 'open-component-in-git-source',
212
+ keyHint: null,
213
+ label: `Open component in ${defaultOpenInName}`,
214
+ leftItem: null,
215
+ onClick: () => {
216
+ if (defaultOpenInTarget === 'editor' && defaultEditorId !== null) {
217
+ openComponentWithEditor(defaultEditorId).catch(() => undefined);
69
218
  }
70
- catch (err) {
71
- (0, NotificationCenter_1.showNotification)(err.message, 2000);
219
+ else if (defaultOpenInTarget === 'git-source') {
220
+ openComponentInGitSource().catch(() => undefined);
72
221
  }
73
222
  },
74
- quickSwitcherLabel: `Open composition component in ${editorName}`,
223
+ quickSwitcherLabel: `Open composition component in ${defaultOpenInName}`,
75
224
  subMenu: null,
76
225
  type: 'item',
77
- value: 'open-component-in-editor',
78
- disabled: openComponentInEditorDisabled,
226
+ value: defaultOpenInTarget === 'editor'
227
+ ? 'open-component-in-editor'
228
+ : 'open-component-in-git-source',
229
+ disabled: defaultOpenInTarget === 'editor'
230
+ ? openComponentInEditorDisabled
231
+ : openComponentInGitSourceDisabled,
232
+ }
233
+ : null,
234
+ componentOpenInMenuItems.length > 0
235
+ ? {
236
+ id: 'open-component-in-another-app',
237
+ keyHint: null,
238
+ label: 'Open component in...',
239
+ leftItem: null,
240
+ onClick: () => undefined,
241
+ quickSwitcherLabel: null,
242
+ subMenu: {
243
+ items: componentOpenInMenuItems,
244
+ leaveLeftSpace: true,
245
+ preselectIndex: false,
246
+ },
247
+ type: 'item',
248
+ value: 'open-component-in-another-app',
79
249
  }
80
250
  : null,
81
- editorName && includeCompositionManagementItems
251
+ hasOpenInItems && includeCompositionManagementItems
82
252
  ? {
83
253
  type: 'divider',
84
254
  id: 'show-in-editor-divider',
@@ -154,7 +324,7 @@ const getCompositionMenuItems = ({ composition, connectionStatus, resolvedLocati
154
324
  disabled: !composition || readOnlyStudio,
155
325
  }
156
326
  : null,
157
- editorName || includeCompositionManagementItems
327
+ hasOpenInItems || includeCompositionManagementItems
158
328
  ? {
159
329
  type: 'divider',
160
330
  id: 'copy-actions-divider',
@@ -15,6 +15,11 @@ const getFolderMenuItems = ({ closeMenu, connectionStatus, folder, readOnlyStudi
15
15
  location: resolvedLocation,
16
16
  root: window.remotion_cwd,
17
17
  });
18
+ const contextForAgents = (0, format_file_location_1.formatContextForAgents)({
19
+ location: resolvedLocation,
20
+ name: folderId,
21
+ root: window.remotion_cwd,
22
+ });
18
23
  const showInEditorDisabled = !editorId || connectionStatus !== 'connected' || !resolvedLocation;
19
24
  const copyFileLocationDisabled = !fileLocation;
20
25
  const codemodDisabled = readOnlyStudio || !folder.stack;
@@ -44,6 +49,26 @@ const getFolderMenuItems = ({ closeMenu, connectionStatus, folder, readOnlyStudi
44
49
  disabled: showInEditorDisabled,
45
50
  }
46
51
  : null,
52
+ {
53
+ id: 'copy-context-for-agents',
54
+ keyHint: null,
55
+ label: `Copy context for agents`,
56
+ leftItem: null,
57
+ onClick: () => {
58
+ closeMenu();
59
+ if (!contextForAgents) {
60
+ return;
61
+ }
62
+ navigator.clipboard.writeText(contextForAgents).catch((err) => {
63
+ (0, NotificationCenter_1.showNotification)(`Could not copy to clipboard: ${err.message}`, 1000);
64
+ });
65
+ },
66
+ quickSwitcherLabel: null,
67
+ subMenu: null,
68
+ type: 'item',
69
+ value: 'copy-context-for-agents',
70
+ disabled: !contextForAgents,
71
+ },
47
72
  {
48
73
  id: 'copy-folder-file-location',
49
74
  keyHint: null,
@@ -96,6 +121,25 @@ const getFolderMenuItems = ({ closeMenu, connectionStatus, folder, readOnlyStudi
96
121
  value: 'new-composition-in-folder',
97
122
  disabled: codemodDisabled,
98
123
  },
124
+ {
125
+ id: 'new-folder-in-folder',
126
+ keyHint: null,
127
+ label: `New folder...`,
128
+ leftItem: null,
129
+ onClick: () => {
130
+ closeMenu();
131
+ setSelectedModal({
132
+ type: 'new-folder',
133
+ parentName: folderId,
134
+ stack: folder.stack,
135
+ });
136
+ },
137
+ quickSwitcherLabel: 'New folder in folder...',
138
+ subMenu: null,
139
+ type: 'item',
140
+ value: 'new-folder-in-folder',
141
+ disabled: codemodDisabled,
142
+ },
99
143
  {
100
144
  id: 'rename-folder',
101
145
  keyHint: null,
@@ -1,24 +1,25 @@
1
- import type { TerminalId } from '@remotion/studio-shared';
2
- import type { EditorPickerId, GetDefaultCodingAgentInfoResponse, GetDefaultEditorInfoResponse } from '@remotion/studio-shared';
3
- import type { OriginalPosition } from '../error-overlay/react-overlay/utils/get-source-map';
1
+ import type { EditorPickerId, GetDefaultCodingAgentInfoResponse, GetDefaultEditorInfoResponse, TerminalId } from '@remotion/studio-shared';
4
2
  import type { ComboboxValue } from './NewComposition/ComboBox';
5
3
  export declare const getConfigureDefaultAppsMenuItems: ({ hasPreviousItems, onConfigureApps, }: {
6
4
  readonly hasPreviousItems: boolean;
7
5
  readonly onConfigureApps: (() => void) | null;
8
6
  }) => ComboboxValue[];
9
- export declare const getOpenInMenuItems: ({ codingAgentInfo, editorDisabled, editorInfo, excludeCodingAgentId, excludeEditorId, fileManagerDisabled, folder, location, onConfigureApps, onOpenInCodingAgent, onOpenInEditor, onOpenInFileExplorer, onOpenInGitClient, onOpenInTerminal, }: {
7
+ export declare const getOpenInMenuItems: ({ canOpenDesktopApps, codingAgentInfo, editorDisabled, editorInfo, excludeCodingAgentId, excludeEditorId, excludeGitSource, fileManagerDisabled, folder, gitSourceDisabled, onConfigureApps, onOpenInCodingAgent, onOpenInEditor, onOpenInFileExplorer, onOpenInGitClient, onOpenInGitSource, onOpenInTerminal, }: {
8
+ readonly canOpenDesktopApps: boolean;
10
9
  readonly codingAgentInfo: GetDefaultCodingAgentInfoResponse | null;
11
10
  readonly editorDisabled: boolean;
12
11
  readonly editorInfo: GetDefaultEditorInfoResponse | null;
13
12
  readonly excludeCodingAgentId: "claude-code" | "codex" | "copilot" | "cursor" | null;
14
13
  readonly excludeEditorId: EditorPickerId | null;
14
+ readonly excludeGitSource: boolean;
15
15
  readonly fileManagerDisabled: boolean;
16
16
  readonly folder: boolean;
17
- readonly location: OriginalPosition | null;
17
+ readonly gitSourceDisabled: boolean;
18
18
  readonly onConfigureApps: (() => void) | null;
19
19
  readonly onOpenInCodingAgent: (codingAgentId: "claude-code" | "codex" | "copilot" | "cursor", codingAgentName: string) => void;
20
20
  readonly onOpenInEditor: (editorId: EditorPickerId) => void;
21
21
  readonly onOpenInFileExplorer: () => void;
22
22
  readonly onOpenInGitClient: (gitClientId: "github-desktop") => void;
23
+ readonly onOpenInGitSource: () => void;
23
24
  readonly onOpenInTerminal: ((terminalId: TerminalId) => void) | null;
24
25
  }) => ComboboxValue[];