@remotion/cli 3.2.21 → 3.2.23-ensure-ffmpeg.123

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 (650) hide show
  1. package/LICENSE.md +8 -8
  2. package/dist/ansi/ansi-diff.d.ts +0 -0
  3. package/dist/ansi/ansi-diff.js +0 -0
  4. package/dist/ansi/ansi-regex.d.ts +0 -0
  5. package/dist/ansi/ansi-regex.js +0 -0
  6. package/dist/ansi/ansi-split.d.ts +0 -0
  7. package/dist/ansi/ansi-split.js +0 -0
  8. package/dist/benchmark.d.ts +1 -0
  9. package/dist/benchmark.js +186 -0
  10. package/dist/chalk/index.d.ts +0 -0
  11. package/dist/chalk/index.js +0 -0
  12. package/dist/code-frame.d.ts +0 -0
  13. package/dist/code-frame.js +0 -0
  14. package/dist/composition-prompts.d.ts +8 -0
  15. package/dist/composition-prompts.js +26 -0
  16. package/dist/compositions.d.ts +1 -1
  17. package/dist/compositions.js +7 -4
  18. package/dist/config/bitrate.d.ts +4 -0
  19. package/dist/config/bitrate.js +21 -0
  20. package/dist/config/browser-executable.d.ts +0 -0
  21. package/dist/config/browser-executable.js +0 -0
  22. package/dist/config/browser.d.ts +0 -0
  23. package/dist/config/browser.js +0 -0
  24. package/dist/config/chromium-flags.d.ts +0 -0
  25. package/dist/config/chromium-flags.js +0 -0
  26. package/dist/config/codec.d.ts +0 -0
  27. package/dist/config/codec.js +0 -0
  28. package/dist/config/concurrency.d.ts +0 -0
  29. package/dist/config/concurrency.js +0 -0
  30. package/dist/config/crf.d.ts +1 -2
  31. package/dist/config/crf.js +1 -9
  32. package/dist/config/enforce-audio-track.d.ts +0 -0
  33. package/dist/config/enforce-audio-track.js +0 -0
  34. package/dist/config/entry-point.d.ts +2 -0
  35. package/dist/config/entry-point.js +12 -0
  36. package/dist/config/env-file.d.ts +0 -0
  37. package/dist/config/env-file.js +0 -0
  38. package/dist/config/every-nth-frame.d.ts +1 -2
  39. package/dist/config/every-nth-frame.js +3 -11
  40. package/dist/config/ffmpeg-executable.d.ts +0 -0
  41. package/dist/config/ffmpeg-executable.js +0 -0
  42. package/dist/config/ffmpeg-override.d.ts +3 -0
  43. package/dist/config/ffmpeg-override.js +12 -0
  44. package/dist/config/frame-range.d.ts +0 -0
  45. package/dist/config/frame-range.js +0 -0
  46. package/dist/config/height.d.ts +2 -0
  47. package/dist/config/height.js +15 -0
  48. package/dist/config/image-format.d.ts +0 -0
  49. package/dist/config/image-format.js +8 -1
  50. package/dist/config/image-sequence.d.ts +0 -0
  51. package/dist/config/image-sequence.js +0 -0
  52. package/dist/config/index.d.ts +12 -4
  53. package/dist/config/index.js +26 -12
  54. package/dist/config/keyboard-shortcuts.d.ts +0 -0
  55. package/dist/config/keyboard-shortcuts.js +0 -0
  56. package/dist/config/log.d.ts +0 -0
  57. package/dist/config/log.js +0 -0
  58. package/dist/config/max-timeline-tracks.d.ts +0 -0
  59. package/dist/config/max-timeline-tracks.js +0 -0
  60. package/dist/config/muted.d.ts +0 -0
  61. package/dist/config/muted.js +0 -0
  62. package/dist/config/number-of-gif-loops.d.ts +1 -2
  63. package/dist/config/number-of-gif-loops.js +3 -9
  64. package/dist/config/output-location.d.ts +0 -0
  65. package/dist/config/output-location.js +0 -0
  66. package/dist/config/override-webpack.d.ts +0 -0
  67. package/dist/config/override-webpack.js +0 -0
  68. package/dist/config/overwrite.d.ts +3 -1
  69. package/dist/config/overwrite.js +2 -3
  70. package/dist/config/pixel-format.d.ts +0 -0
  71. package/dist/config/pixel-format.js +0 -0
  72. package/dist/config/preview-server.d.ts +0 -0
  73. package/dist/config/preview-server.js +0 -0
  74. package/dist/config/prores-profile.d.ts +0 -0
  75. package/dist/config/prores-profile.js +0 -0
  76. package/dist/config/public-dir.d.ts +0 -0
  77. package/dist/config/public-dir.js +0 -0
  78. package/dist/config/quality.d.ts +0 -0
  79. package/dist/config/quality.js +0 -0
  80. package/dist/config/scale.d.ts +0 -0
  81. package/dist/config/scale.js +0 -0
  82. package/dist/config/still-frame.d.ts +0 -0
  83. package/dist/config/still-frame.js +0 -0
  84. package/dist/config/timeout.d.ts +0 -0
  85. package/dist/config/timeout.js +0 -0
  86. package/dist/config/webpack-caching.d.ts +0 -0
  87. package/dist/config/webpack-caching.js +0 -0
  88. package/dist/config/width.d.ts +2 -0
  89. package/dist/config/width.js +17 -0
  90. package/dist/determine-image-format.d.ts +11 -0
  91. package/dist/determine-image-format.js +48 -0
  92. package/dist/download-progress.d.ts +0 -0
  93. package/dist/download-progress.js +0 -0
  94. package/dist/editor/components/AudioWaveform.d.ts +0 -0
  95. package/dist/editor/components/AudioWaveform.js +0 -0
  96. package/dist/editor/components/AudioWaveformBar.d.ts +0 -0
  97. package/dist/editor/components/AudioWaveformBar.js +0 -0
  98. package/dist/editor/components/Canvas.d.ts +0 -0
  99. package/dist/editor/components/Canvas.js +9 -2
  100. package/dist/editor/components/CheckboardToggle.d.ts +0 -0
  101. package/dist/editor/components/CheckboardToggle.js +0 -0
  102. package/dist/editor/components/ClipboardIcon.d.ts +0 -0
  103. package/dist/editor/components/ClipboardIcon.js +0 -0
  104. package/dist/editor/components/CollapsedCompositionSelector.d.ts +0 -0
  105. package/dist/editor/components/CollapsedCompositionSelector.js +0 -0
  106. package/dist/editor/components/CompositionSelector.d.ts +0 -0
  107. package/dist/editor/components/CompositionSelector.js +0 -0
  108. package/dist/editor/components/CompositionSelectorItem.d.ts +0 -0
  109. package/dist/editor/components/CompositionSelectorItem.js +0 -0
  110. package/dist/editor/components/ControlButton.d.ts +0 -0
  111. package/dist/editor/components/ControlButton.js +0 -0
  112. package/dist/editor/components/CopyButton.d.ts +0 -0
  113. package/dist/editor/components/CopyButton.js +0 -0
  114. package/dist/editor/components/CurrentComposition.d.ts +0 -0
  115. package/dist/editor/components/CurrentComposition.js +0 -0
  116. package/dist/editor/components/Editor.d.ts +0 -0
  117. package/dist/editor/components/Editor.js +4 -2
  118. package/dist/editor/components/EditorContent.d.ts +0 -0
  119. package/dist/editor/components/EditorContent.js +0 -0
  120. package/dist/editor/components/EditorContexts.d.ts +0 -0
  121. package/dist/editor/components/EditorContexts.js +0 -0
  122. package/dist/editor/components/FpsCounter.d.ts +0 -0
  123. package/dist/editor/components/FpsCounter.js +0 -0
  124. package/dist/editor/components/FramePersistor.d.ts +0 -0
  125. package/dist/editor/components/FramePersistor.js +0 -0
  126. package/dist/editor/components/GlobalKeybindings.d.ts +0 -0
  127. package/dist/editor/components/GlobalKeybindings.js +20 -1
  128. package/dist/editor/components/InitialCompositionLoader.d.ts +0 -0
  129. package/dist/editor/components/InitialCompositionLoader.js +0 -0
  130. package/dist/editor/components/KeyboardShortcutsExplainer.d.ts +2 -0
  131. package/dist/editor/components/KeyboardShortcutsExplainer.js +56 -0
  132. package/dist/editor/components/KeyboardShortcutsModal.d.ts +0 -0
  133. package/dist/editor/components/KeyboardShortcutsModal.js +0 -0
  134. package/dist/editor/components/LoopToggle.d.ts +0 -0
  135. package/dist/editor/components/LoopToggle.js +0 -0
  136. package/dist/editor/components/Menu/MenuDivider.d.ts +0 -0
  137. package/dist/editor/components/Menu/MenuDivider.js +0 -0
  138. package/dist/editor/components/Menu/MenuItem.d.ts +0 -0
  139. package/dist/editor/components/Menu/MenuItem.js +0 -0
  140. package/dist/editor/components/Menu/MenuSubItem.d.ts +0 -0
  141. package/dist/editor/components/Menu/MenuSubItem.js +0 -0
  142. package/dist/editor/components/Menu/SubMenu.d.ts +0 -0
  143. package/dist/editor/components/Menu/SubMenu.js +0 -0
  144. package/dist/editor/components/Menu/portals.d.ts +0 -0
  145. package/dist/editor/components/Menu/portals.js +0 -0
  146. package/dist/editor/components/Menu/styles.d.ts +0 -0
  147. package/dist/editor/components/Menu/styles.js +0 -0
  148. package/dist/editor/components/MenuBuildIndicator.d.ts +0 -0
  149. package/dist/editor/components/MenuBuildIndicator.js +0 -0
  150. package/dist/editor/components/MenuToolbar.d.ts +0 -0
  151. package/dist/editor/components/MenuToolbar.js +3 -449
  152. package/dist/editor/components/ModalContainer.d.ts +0 -0
  153. package/dist/editor/components/ModalContainer.js +0 -0
  154. package/dist/editor/components/ModalHeader.d.ts +0 -0
  155. package/dist/editor/components/ModalHeader.js +0 -0
  156. package/dist/editor/components/MuteToggle.d.ts +0 -0
  157. package/dist/editor/components/MuteToggle.js +0 -0
  158. package/dist/editor/components/NewComposition/CancelButton.d.ts +0 -0
  159. package/dist/editor/components/NewComposition/CancelButton.js +0 -0
  160. package/dist/editor/components/NewComposition/ComboBox.d.ts +2 -1
  161. package/dist/editor/components/NewComposition/ComboBox.js +0 -0
  162. package/dist/editor/components/NewComposition/CopyHint.d.ts +0 -0
  163. package/dist/editor/components/NewComposition/CopyHint.js +0 -0
  164. package/dist/editor/components/NewComposition/InputDragger.d.ts +0 -0
  165. package/dist/editor/components/NewComposition/InputDragger.js +0 -0
  166. package/dist/editor/components/NewComposition/MenuContent.d.ts +0 -0
  167. package/dist/editor/components/NewComposition/MenuContent.js +7 -0
  168. package/dist/editor/components/NewComposition/NewCompAspectRatio.d.ts +0 -0
  169. package/dist/editor/components/NewComposition/NewCompAspectRatio.js +0 -0
  170. package/dist/editor/components/NewComposition/NewCompCode.d.ts +0 -0
  171. package/dist/editor/components/NewComposition/NewCompCode.js +0 -0
  172. package/dist/editor/components/NewComposition/NewCompDuration.d.ts +0 -0
  173. package/dist/editor/components/NewComposition/NewCompDuration.js +0 -0
  174. package/dist/editor/components/NewComposition/NewComposition.d.ts +0 -0
  175. package/dist/editor/components/NewComposition/NewComposition.js +3 -0
  176. package/dist/editor/components/NewComposition/RemInput.d.ts +0 -0
  177. package/dist/editor/components/NewComposition/RemInput.js +1 -1
  178. package/dist/editor/components/NewComposition/ToggleAspectRatio.d.ts +0 -0
  179. package/dist/editor/components/NewComposition/ToggleAspectRatio.js +0 -0
  180. package/dist/editor/components/NewComposition/ValidationMessage.d.ts +0 -0
  181. package/dist/editor/components/NewComposition/ValidationMessage.js +0 -0
  182. package/dist/editor/components/NewComposition/new-comp-layout.d.ts +0 -0
  183. package/dist/editor/components/NewComposition/new-comp-layout.js +0 -0
  184. package/dist/editor/components/NewComposition/render-aspect-ratio.d.ts +0 -0
  185. package/dist/editor/components/NewComposition/render-aspect-ratio.js +0 -0
  186. package/dist/editor/components/NoRegisterRoot.d.ts +0 -0
  187. package/dist/editor/components/NoRegisterRoot.js +0 -0
  188. package/dist/editor/components/Notifications/ColorDot.d.ts +0 -0
  189. package/dist/editor/components/Notifications/ColorDot.js +0 -0
  190. package/dist/editor/components/Notifications/Notification.d.ts +0 -0
  191. package/dist/editor/components/Notifications/Notification.js +0 -0
  192. package/dist/editor/components/Notifications/NotificationCenter.d.ts +0 -0
  193. package/dist/editor/components/Notifications/NotificationCenter.js +1 -1
  194. package/dist/editor/components/Notifications/ServerDisconnected.d.ts +0 -0
  195. package/dist/editor/components/Notifications/ServerDisconnected.js +0 -0
  196. package/dist/editor/components/PlayPause.d.ts +0 -0
  197. package/dist/editor/components/PlayPause.js +8 -1
  198. package/dist/editor/components/PlaybackKeyboardShortcutsManager.d.ts +0 -0
  199. package/dist/editor/components/PlaybackKeyboardShortcutsManager.js +3 -0
  200. package/dist/editor/components/PlaybackRatePersistor.d.ts +0 -0
  201. package/dist/editor/components/PlaybackRatePersistor.js +0 -0
  202. package/dist/editor/components/PlaybackRateSelector.d.ts +0 -0
  203. package/dist/editor/components/PlaybackRateSelector.js +1 -0
  204. package/dist/editor/components/Preview.d.ts +0 -0
  205. package/dist/editor/components/Preview.js +0 -0
  206. package/dist/editor/components/PreviewToolbar.d.ts +0 -0
  207. package/dist/editor/components/PreviewToolbar.js +0 -0
  208. package/dist/editor/components/QuickSwitcher/AlgoliaCredit.d.ts +2 -0
  209. package/dist/editor/components/QuickSwitcher/AlgoliaCredit.js +11 -0
  210. package/dist/editor/components/QuickSwitcher/NoResults.d.ts +6 -0
  211. package/dist/editor/components/QuickSwitcher/NoResults.js +20 -0
  212. package/dist/editor/components/QuickSwitcher/QuickSwitcher.d.ts +7 -0
  213. package/dist/editor/components/QuickSwitcher/QuickSwitcher.js +16 -0
  214. package/dist/editor/components/QuickSwitcher/QuickSwitcherContent.d.ts +6 -0
  215. package/dist/editor/components/QuickSwitcher/QuickSwitcherContent.js +269 -0
  216. package/dist/editor/components/QuickSwitcher/QuickSwitcherResult.d.ts +21 -0
  217. package/dist/editor/components/QuickSwitcher/QuickSwitcherResult.js +109 -0
  218. package/dist/editor/components/QuickSwitcher/agolia-search.d.ts +2 -0
  219. package/dist/editor/components/QuickSwitcher/agolia-search.js +40 -0
  220. package/dist/editor/components/QuickSwitcher/algolia-search.d.ts +29 -0
  221. package/dist/editor/components/QuickSwitcher/algolia-search.js +63 -0
  222. package/dist/editor/components/QuickSwitcher/fuzzy-search.d.ts +2 -0
  223. package/dist/editor/components/QuickSwitcher/fuzzy-search.js +26 -0
  224. package/dist/editor/components/ResetZoomButton.d.ts +0 -0
  225. package/dist/editor/components/ResetZoomButton.js +0 -0
  226. package/dist/editor/components/RichTimelineToggle.d.ts +0 -0
  227. package/dist/editor/components/RichTimelineToggle.js +0 -0
  228. package/dist/editor/components/SizeSelector.d.ts +0 -0
  229. package/dist/editor/components/SizeSelector.js +2 -1
  230. package/dist/editor/components/Splitter/SplitterContainer.d.ts +0 -0
  231. package/dist/editor/components/Splitter/SplitterContainer.js +0 -0
  232. package/dist/editor/components/Splitter/SplitterContext.d.ts +0 -0
  233. package/dist/editor/components/Splitter/SplitterContext.js +0 -0
  234. package/dist/editor/components/Splitter/SplitterElement.d.ts +0 -0
  235. package/dist/editor/components/Splitter/SplitterElement.js +0 -0
  236. package/dist/editor/components/Splitter/SplitterHandle.d.ts +0 -0
  237. package/dist/editor/components/Splitter/SplitterHandle.js +0 -0
  238. package/dist/editor/components/Thumbnail.d.ts +0 -0
  239. package/dist/editor/components/Thumbnail.js +0 -0
  240. package/dist/editor/components/TimeValue.d.ts +0 -0
  241. package/dist/editor/components/TimeValue.js +0 -0
  242. package/dist/editor/components/Timeline/LoopedIndicator.d.ts +0 -0
  243. package/dist/editor/components/Timeline/LoopedIndicator.js +0 -0
  244. package/dist/editor/components/Timeline/LoopedTimelineIndicators.d.ts +0 -0
  245. package/dist/editor/components/Timeline/LoopedTimelineIndicators.js +0 -0
  246. package/dist/editor/components/Timeline/MaxTimelineTracks.d.ts +0 -0
  247. package/dist/editor/components/Timeline/MaxTimelineTracks.js +0 -0
  248. package/dist/editor/components/Timeline/Timeline.d.ts +0 -0
  249. package/dist/editor/components/Timeline/Timeline.js +1 -1
  250. package/dist/editor/components/Timeline/TimelineCollapseToggle.d.ts +0 -0
  251. package/dist/editor/components/Timeline/TimelineCollapseToggle.js +0 -0
  252. package/dist/editor/components/Timeline/TimelineDragHandler.d.ts +0 -0
  253. package/dist/editor/components/Timeline/TimelineDragHandler.js +0 -0
  254. package/dist/editor/components/Timeline/TimelineInOutPointer.d.ts +0 -0
  255. package/dist/editor/components/Timeline/TimelineInOutPointer.js +0 -0
  256. package/dist/editor/components/Timeline/TimelineInOutPointerHandle.d.ts +0 -0
  257. package/dist/editor/components/Timeline/TimelineInOutPointerHandle.js +0 -0
  258. package/dist/editor/components/Timeline/TimelineList.d.ts +0 -0
  259. package/dist/editor/components/Timeline/TimelineList.js +0 -0
  260. package/dist/editor/components/Timeline/TimelineListItem.d.ts +0 -0
  261. package/dist/editor/components/Timeline/TimelineListItem.js +0 -0
  262. package/dist/editor/components/Timeline/TimelinePlayCursorSyncer.d.ts +0 -0
  263. package/dist/editor/components/Timeline/TimelinePlayCursorSyncer.js +0 -0
  264. package/dist/editor/components/Timeline/TimelineScrollable.d.ts +0 -0
  265. package/dist/editor/components/Timeline/TimelineScrollable.js +0 -0
  266. package/dist/editor/components/Timeline/TimelineSequence.d.ts +0 -0
  267. package/dist/editor/components/Timeline/TimelineSequence.js +0 -0
  268. package/dist/editor/components/Timeline/TimelineSequenceFrame.d.ts +0 -0
  269. package/dist/editor/components/Timeline/TimelineSequenceFrame.js +0 -0
  270. package/dist/editor/components/Timeline/TimelineSlider.d.ts +0 -0
  271. package/dist/editor/components/Timeline/TimelineSlider.js +1 -1
  272. package/dist/editor/components/Timeline/TimelineSliderHandle.d.ts +0 -0
  273. package/dist/editor/components/Timeline/TimelineSliderHandle.js +0 -0
  274. package/dist/editor/components/Timeline/TimelineTimeIndicators.d.ts +0 -0
  275. package/dist/editor/components/Timeline/TimelineTimeIndicators.js +0 -0
  276. package/dist/editor/components/Timeline/TimelineTracks.d.ts +0 -0
  277. package/dist/editor/components/Timeline/TimelineTracks.js +0 -0
  278. package/dist/editor/components/Timeline/TimelineVideoInfo.d.ts +0 -0
  279. package/dist/editor/components/Timeline/TimelineVideoInfo.js +0 -0
  280. package/dist/editor/components/Timeline/TimelineZoomControls.d.ts +0 -0
  281. package/dist/editor/components/Timeline/TimelineZoomControls.js +0 -0
  282. package/dist/editor/components/Timeline/imperative-state.d.ts +0 -0
  283. package/dist/editor/components/Timeline/imperative-state.js +0 -0
  284. package/dist/editor/components/Timeline/is-collapsed.d.ts +0 -0
  285. package/dist/editor/components/Timeline/is-collapsed.js +0 -0
  286. package/dist/editor/components/Timeline/timeline-refs.d.ts +0 -0
  287. package/dist/editor/components/Timeline/timeline-refs.js +0 -0
  288. package/dist/editor/components/Timeline/timeline-scroll-logic.d.ts +0 -0
  289. package/dist/editor/components/Timeline/timeline-scroll-logic.js +0 -0
  290. package/dist/editor/components/Timeline/timeline-state-reducer.d.ts +0 -0
  291. package/dist/editor/components/Timeline/timeline-state-reducer.js +0 -0
  292. package/dist/editor/components/TimelineInOutToggle.d.ts +0 -0
  293. package/dist/editor/components/TimelineInOutToggle.js +4 -1
  294. package/dist/editor/components/TopPanel.d.ts +0 -0
  295. package/dist/editor/components/TopPanel.js +0 -0
  296. package/dist/editor/components/UpdateCheck.d.ts +0 -0
  297. package/dist/editor/components/UpdateCheck.js +0 -0
  298. package/dist/editor/components/UpdateModal/UpdateModal.d.ts +0 -0
  299. package/dist/editor/components/UpdateModal/UpdateModal.js +0 -0
  300. package/dist/editor/components/ZoomPersistor.d.ts +0 -0
  301. package/dist/editor/components/ZoomPersistor.js +0 -0
  302. package/dist/editor/components/layout.d.ts +0 -0
  303. package/dist/editor/components/layout.js +0 -0
  304. package/dist/editor/helpers/calculate-timeline.d.ts +0 -0
  305. package/dist/editor/helpers/calculate-timeline.js +0 -0
  306. package/dist/editor/helpers/checkerboard-background.d.ts +0 -0
  307. package/dist/editor/helpers/checkerboard-background.js +0 -0
  308. package/dist/editor/helpers/colors.d.ts +0 -0
  309. package/dist/editor/helpers/colors.js +0 -0
  310. package/dist/editor/helpers/copy-text.d.ts +0 -0
  311. package/dist/editor/helpers/copy-text.js +0 -0
  312. package/dist/editor/helpers/create-folder-tree.d.ts +0 -0
  313. package/dist/editor/helpers/create-folder-tree.js +0 -0
  314. package/dist/editor/helpers/get-effective-translation.d.ts +0 -0
  315. package/dist/editor/helpers/get-effective-translation.js +0 -0
  316. package/dist/editor/helpers/get-left-of-timeline-slider.d.ts +0 -0
  317. package/dist/editor/helpers/get-left-of-timeline-slider.js +0 -0
  318. package/dist/editor/helpers/get-sequence-visible-range.d.ts +0 -0
  319. package/dist/editor/helpers/get-sequence-visible-range.js +0 -0
  320. package/dist/editor/helpers/get-timeline-nestedness.d.ts +0 -0
  321. package/dist/editor/helpers/get-timeline-nestedness.js +0 -0
  322. package/dist/editor/helpers/get-timeline-sequence-hash.d.ts +0 -0
  323. package/dist/editor/helpers/get-timeline-sequence-hash.js +0 -0
  324. package/dist/editor/helpers/get-timeline-sequence-layout.d.ts +0 -0
  325. package/dist/editor/helpers/get-timeline-sequence-layout.js +0 -0
  326. package/dist/editor/helpers/get-timeline-sequence-sort-key.d.ts +0 -0
  327. package/dist/editor/helpers/get-timeline-sequence-sort-key.js +0 -0
  328. package/dist/editor/helpers/is-composition-still.d.ts +0 -0
  329. package/dist/editor/helpers/is-composition-still.js +0 -0
  330. package/dist/editor/helpers/is-current-selected-still.d.ts +0 -0
  331. package/dist/editor/helpers/is-current-selected-still.js +0 -0
  332. package/dist/editor/helpers/noop.d.ts +0 -0
  333. package/dist/editor/helpers/noop.js +0 -0
  334. package/dist/editor/helpers/persist-open-folders.d.ts +0 -0
  335. package/dist/editor/helpers/persist-open-folders.js +0 -0
  336. package/dist/editor/helpers/pick-color.d.ts +0 -0
  337. package/dist/editor/helpers/pick-color.js +0 -0
  338. package/dist/editor/helpers/timeline-layout.d.ts +0 -0
  339. package/dist/editor/helpers/timeline-layout.js +0 -0
  340. package/dist/editor/helpers/use-compact-ui.d.ts +0 -0
  341. package/dist/editor/helpers/use-compact-ui.js +0 -0
  342. package/dist/editor/helpers/use-keybinding.d.ts +1 -0
  343. package/dist/editor/helpers/use-keybinding.js +3 -1
  344. package/dist/editor/helpers/use-menu-structure.d.ts +7 -0
  345. package/dist/editor/helpers/use-menu-structure.js +575 -0
  346. package/dist/editor/helpers/validate-new-comp-data.d.ts +0 -0
  347. package/dist/editor/helpers/validate-new-comp-data.js +0 -0
  348. package/dist/editor/icons/Checkmark.d.ts +0 -0
  349. package/dist/editor/icons/Checkmark.js +0 -0
  350. package/dist/editor/icons/caret.d.ts +0 -0
  351. package/dist/editor/icons/caret.js +0 -0
  352. package/dist/editor/icons/film.d.ts +0 -0
  353. package/dist/editor/icons/film.js +0 -0
  354. package/dist/editor/icons/folder.d.ts +0 -0
  355. package/dist/editor/icons/folder.js +0 -0
  356. package/dist/editor/icons/jump-to-start.d.ts +0 -0
  357. package/dist/editor/icons/jump-to-start.js +0 -0
  358. package/dist/editor/icons/keys.d.ts +0 -0
  359. package/dist/editor/icons/keys.js +0 -0
  360. package/dist/editor/icons/lock.d.ts +0 -0
  361. package/dist/editor/icons/lock.js +0 -0
  362. package/dist/editor/icons/media-volume.d.ts +0 -0
  363. package/dist/editor/icons/media-volume.js +0 -0
  364. package/dist/editor/icons/minus.d.ts +0 -0
  365. package/dist/editor/icons/minus.js +0 -0
  366. package/dist/editor/icons/pause.d.ts +0 -0
  367. package/dist/editor/icons/pause.js +0 -0
  368. package/dist/editor/icons/play.d.ts +0 -0
  369. package/dist/editor/icons/play.js +0 -0
  370. package/dist/editor/icons/plus.d.ts +0 -0
  371. package/dist/editor/icons/plus.js +0 -0
  372. package/dist/editor/icons/step-back.d.ts +0 -0
  373. package/dist/editor/icons/step-back.js +0 -0
  374. package/dist/editor/icons/step-forward.d.ts +0 -0
  375. package/dist/editor/icons/step-forward.js +0 -0
  376. package/dist/editor/icons/still.d.ts +0 -0
  377. package/dist/editor/icons/still.js +0 -0
  378. package/dist/editor/icons/timeline.d.ts +0 -0
  379. package/dist/editor/icons/timeline.js +0 -0
  380. package/dist/editor/icons/timelineInOutPointer.d.ts +0 -0
  381. package/dist/editor/icons/timelineInOutPointer.js +0 -0
  382. package/dist/editor/state/aspect-ratio-locked.d.ts +0 -0
  383. package/dist/editor/state/aspect-ratio-locked.js +0 -0
  384. package/dist/editor/state/checkerboard.d.ts +0 -0
  385. package/dist/editor/state/checkerboard.js +0 -0
  386. package/dist/editor/state/folders.d.ts +0 -0
  387. package/dist/editor/state/folders.js +0 -0
  388. package/dist/editor/state/highest-z-index.d.ts +0 -0
  389. package/dist/editor/state/highest-z-index.js +0 -0
  390. package/dist/editor/state/in-out.d.ts +0 -0
  391. package/dist/editor/state/in-out.js +0 -0
  392. package/dist/editor/state/input-dragger-click-lock.d.ts +0 -0
  393. package/dist/editor/state/input-dragger-click-lock.js +0 -0
  394. package/dist/editor/state/keybindings.d.ts +0 -0
  395. package/dist/editor/state/keybindings.js +0 -0
  396. package/dist/editor/state/loop.d.ts +0 -0
  397. package/dist/editor/state/loop.js +0 -0
  398. package/dist/editor/state/marks.d.ts +0 -0
  399. package/dist/editor/state/marks.js +0 -0
  400. package/dist/editor/state/modals.d.ts +4 -1
  401. package/dist/editor/state/modals.js +0 -0
  402. package/dist/editor/state/mute.d.ts +0 -0
  403. package/dist/editor/state/mute.js +0 -0
  404. package/dist/editor/state/playbackrate.d.ts +0 -0
  405. package/dist/editor/state/playbackrate.js +0 -0
  406. package/dist/editor/state/preview-size.d.ts +0 -0
  407. package/dist/editor/state/preview-size.js +0 -0
  408. package/dist/editor/state/render-frame.d.ts +0 -0
  409. package/dist/editor/state/render-frame.js +0 -0
  410. package/dist/editor/state/rich-timeline.d.ts +0 -0
  411. package/dist/editor/state/rich-timeline.js +0 -0
  412. package/dist/editor/state/sidebar.d.ts +0 -0
  413. package/dist/editor/state/sidebar.js +0 -0
  414. package/dist/editor/state/timeline-ref.d.ts +0 -0
  415. package/dist/editor/state/timeline-ref.js +0 -0
  416. package/dist/editor/state/timeline-zoom.d.ts +0 -0
  417. package/dist/editor/state/timeline-zoom.js +0 -0
  418. package/dist/editor/state/timeline.d.ts +0 -0
  419. package/dist/editor/state/timeline.js +0 -0
  420. package/dist/editor/state/z-index.d.ts +0 -0
  421. package/dist/editor/state/z-index.js +1 -0
  422. package/dist/entry-point.d.ts +5 -0
  423. package/dist/entry-point.js +46 -0
  424. package/dist/event-source-events.d.ts +3 -0
  425. package/dist/event-source-events.js +0 -0
  426. package/dist/event-source.d.ts +0 -0
  427. package/dist/event-source.js +12 -10
  428. package/dist/find-closest-package-json.d.ts +0 -0
  429. package/dist/find-closest-package-json.js +0 -0
  430. package/dist/format-bytes.d.ts +0 -0
  431. package/dist/format-bytes.js +0 -0
  432. package/dist/get-cli-options.d.ts +17 -6
  433. package/dist/get-cli-options.js +40 -54
  434. package/dist/get-composition-id.d.ts +7 -1
  435. package/dist/get-composition-id.js +30 -7
  436. package/dist/get-composition-with-dimension-override.d.ts +12 -0
  437. package/dist/get-composition-with-dimension-override.js +16 -0
  438. package/dist/get-config-file-name.d.ts +0 -0
  439. package/dist/get-config-file-name.js +0 -0
  440. package/dist/get-env.d.ts +1 -1
  441. package/dist/get-env.js +60 -8
  442. package/dist/get-filename.d.ts +2 -1
  443. package/dist/get-filename.js +2 -1
  444. package/dist/get-final-output-codec.d.ts +9 -5
  445. package/dist/get-final-output-codec.js +51 -48
  446. package/dist/get-input-props.d.ts +0 -0
  447. package/dist/get-input-props.js +0 -0
  448. package/dist/get-latest-remotion-version.d.ts +0 -0
  449. package/dist/get-latest-remotion-version.js +0 -0
  450. package/dist/get-network-address.d.ts +1 -0
  451. package/dist/get-network-address.js +16 -0
  452. package/dist/get-render-media-options.d.ts +8 -0
  453. package/dist/get-render-media-options.js +52 -0
  454. package/dist/handle-common-errors.d.ts +0 -0
  455. package/dist/handle-common-errors.js +0 -0
  456. package/dist/image-formats.d.ts +0 -0
  457. package/dist/image-formats.js +0 -0
  458. package/dist/index.d.ts +39 -11
  459. package/dist/index.js +32 -20
  460. package/dist/initialize-cli.d.ts +1 -0
  461. package/dist/{initialize-render-cli.js → initialize-cli.js} +4 -4
  462. package/dist/is-javascript.d.ts +0 -0
  463. package/dist/is-javascript.js +0 -0
  464. package/dist/lambda-command.d.ts +1 -1
  465. package/dist/lambda-command.js +3 -6
  466. package/dist/list-of-remotion-packages.d.ts +0 -0
  467. package/dist/list-of-remotion-packages.js +3 -0
  468. package/dist/load-config.d.ts +0 -0
  469. package/dist/load-config.js +0 -0
  470. package/dist/log.d.ts +0 -0
  471. package/dist/log.js +0 -0
  472. package/dist/make-progress-bar.d.ts +0 -0
  473. package/dist/make-progress-bar.js +0 -0
  474. package/dist/parse-command-line.d.ts +4 -1
  475. package/dist/parse-command-line.js +13 -12
  476. package/dist/preview-server/dev-middleware/compatible-api.d.ts +0 -0
  477. package/dist/preview-server/dev-middleware/compatible-api.js +0 -0
  478. package/dist/preview-server/dev-middleware/get-paths.d.ts +0 -0
  479. package/dist/preview-server/dev-middleware/get-paths.js +0 -0
  480. package/dist/preview-server/dev-middleware/index.d.ts +0 -0
  481. package/dist/preview-server/dev-middleware/index.js +0 -0
  482. package/dist/preview-server/dev-middleware/is-color-supported.d.ts +0 -0
  483. package/dist/preview-server/dev-middleware/is-color-supported.js +0 -0
  484. package/dist/preview-server/dev-middleware/middleware.d.ts +0 -0
  485. package/dist/preview-server/dev-middleware/middleware.js +0 -0
  486. package/dist/preview-server/dev-middleware/range-parser.d.ts +0 -0
  487. package/dist/preview-server/dev-middleware/range-parser.js +0 -0
  488. package/dist/preview-server/dev-middleware/ready.d.ts +0 -0
  489. package/dist/preview-server/dev-middleware/ready.js +0 -0
  490. package/dist/preview-server/dev-middleware/setup-hooks.d.ts +0 -0
  491. package/dist/preview-server/dev-middleware/setup-hooks.js +15 -4
  492. package/dist/preview-server/dev-middleware/setup-output-filesystem.d.ts +0 -0
  493. package/dist/preview-server/dev-middleware/setup-output-filesystem.js +0 -0
  494. package/dist/preview-server/dev-middleware/types.d.ts +0 -0
  495. package/dist/preview-server/dev-middleware/types.js +0 -0
  496. package/dist/preview-server/error-overlay/entry-basic.d.ts +0 -0
  497. package/dist/preview-server/error-overlay/entry-basic.js +0 -0
  498. package/dist/preview-server/error-overlay/react-overlay/effects/format-warning.d.ts +0 -0
  499. package/dist/preview-server/error-overlay/react-overlay/effects/format-warning.js +0 -0
  500. package/dist/preview-server/error-overlay/react-overlay/effects/map-error-to-react-stack.d.ts +0 -0
  501. package/dist/preview-server/error-overlay/react-overlay/effects/map-error-to-react-stack.js +0 -0
  502. package/dist/preview-server/error-overlay/react-overlay/effects/proxy-console.d.ts +0 -0
  503. package/dist/preview-server/error-overlay/react-overlay/effects/proxy-console.js +0 -0
  504. package/dist/preview-server/error-overlay/react-overlay/effects/resolve-file-source.d.ts +0 -0
  505. package/dist/preview-server/error-overlay/react-overlay/effects/resolve-file-source.js +0 -0
  506. package/dist/preview-server/error-overlay/react-overlay/effects/stack-trace-limit.d.ts +0 -0
  507. package/dist/preview-server/error-overlay/react-overlay/effects/stack-trace-limit.js +0 -0
  508. package/dist/preview-server/error-overlay/react-overlay/effects/unhandled-error.d.ts +0 -0
  509. package/dist/preview-server/error-overlay/react-overlay/effects/unhandled-error.js +0 -0
  510. package/dist/preview-server/error-overlay/react-overlay/effects/unhandled-rejection.d.ts +0 -0
  511. package/dist/preview-server/error-overlay/react-overlay/effects/unhandled-rejection.js +0 -0
  512. package/dist/preview-server/error-overlay/react-overlay/index.d.ts +0 -0
  513. package/dist/preview-server/error-overlay/react-overlay/index.js +0 -0
  514. package/dist/preview-server/error-overlay/react-overlay/listen-to-runtime-errors.d.ts +0 -0
  515. package/dist/preview-server/error-overlay/react-overlay/listen-to-runtime-errors.js +0 -0
  516. package/dist/preview-server/error-overlay/react-overlay/utils/get-file-source.d.ts +0 -0
  517. package/dist/preview-server/error-overlay/react-overlay/utils/get-file-source.js +0 -0
  518. package/dist/preview-server/error-overlay/react-overlay/utils/get-lines-around.d.ts +0 -0
  519. package/dist/preview-server/error-overlay/react-overlay/utils/get-lines-around.js +0 -0
  520. package/dist/preview-server/error-overlay/react-overlay/utils/get-source-map.d.ts +0 -0
  521. package/dist/preview-server/error-overlay/react-overlay/utils/get-source-map.js +0 -0
  522. package/dist/preview-server/error-overlay/react-overlay/utils/get-stack-frames.d.ts +0 -0
  523. package/dist/preview-server/error-overlay/react-overlay/utils/get-stack-frames.js +0 -0
  524. package/dist/preview-server/error-overlay/react-overlay/utils/open-in-editor.d.ts +0 -0
  525. package/dist/preview-server/error-overlay/react-overlay/utils/open-in-editor.js +0 -0
  526. package/dist/preview-server/error-overlay/react-overlay/utils/parser.d.ts +0 -0
  527. package/dist/preview-server/error-overlay/react-overlay/utils/parser.js +0 -0
  528. package/dist/preview-server/error-overlay/react-overlay/utils/stack-frame.d.ts +0 -0
  529. package/dist/preview-server/error-overlay/react-overlay/utils/stack-frame.js +0 -0
  530. package/dist/preview-server/error-overlay/react-overlay/utils/unmapper.d.ts +0 -0
  531. package/dist/preview-server/error-overlay/react-overlay/utils/unmapper.js +0 -0
  532. package/dist/preview-server/error-overlay/remotion-overlay/AskOnDiscord.d.ts +0 -0
  533. package/dist/preview-server/error-overlay/remotion-overlay/AskOnDiscord.js +1 -0
  534. package/dist/preview-server/error-overlay/remotion-overlay/Button.d.ts +0 -0
  535. package/dist/preview-server/error-overlay/remotion-overlay/Button.js +0 -0
  536. package/dist/preview-server/error-overlay/remotion-overlay/CodeFrame.d.ts +0 -0
  537. package/dist/preview-server/error-overlay/remotion-overlay/CodeFrame.js +0 -0
  538. package/dist/preview-server/error-overlay/remotion-overlay/DismissButton.d.ts +0 -0
  539. package/dist/preview-server/error-overlay/remotion-overlay/DismissButton.js +0 -0
  540. package/dist/preview-server/error-overlay/remotion-overlay/ErrorDisplay.d.ts +0 -0
  541. package/dist/preview-server/error-overlay/remotion-overlay/ErrorDisplay.js +0 -0
  542. package/dist/preview-server/error-overlay/remotion-overlay/ErrorLoader.d.ts +0 -0
  543. package/dist/preview-server/error-overlay/remotion-overlay/ErrorLoader.js +0 -0
  544. package/dist/preview-server/error-overlay/remotion-overlay/ErrorMessage.d.ts +0 -0
  545. package/dist/preview-server/error-overlay/remotion-overlay/ErrorMessage.js +0 -0
  546. package/dist/preview-server/error-overlay/remotion-overlay/ErrorTitle.d.ts +0 -0
  547. package/dist/preview-server/error-overlay/remotion-overlay/ErrorTitle.js +0 -0
  548. package/dist/preview-server/error-overlay/remotion-overlay/HelpLink.d.ts +0 -0
  549. package/dist/preview-server/error-overlay/remotion-overlay/HelpLink.js +1 -0
  550. package/dist/preview-server/error-overlay/remotion-overlay/OpenInEditor.d.ts +0 -0
  551. package/dist/preview-server/error-overlay/remotion-overlay/OpenInEditor.js +1 -0
  552. package/dist/preview-server/error-overlay/remotion-overlay/Overlay.d.ts +0 -0
  553. package/dist/preview-server/error-overlay/remotion-overlay/Overlay.js +0 -0
  554. package/dist/preview-server/error-overlay/remotion-overlay/SearchGitHubIssues.d.ts +0 -0
  555. package/dist/preview-server/error-overlay/remotion-overlay/SearchGitHubIssues.js +1 -0
  556. package/dist/preview-server/error-overlay/remotion-overlay/ShortcutHint.d.ts +1 -0
  557. package/dist/preview-server/error-overlay/remotion-overlay/ShortcutHint.js +3 -3
  558. package/dist/preview-server/error-overlay/remotion-overlay/StackFrame.d.ts +0 -0
  559. package/dist/preview-server/error-overlay/remotion-overlay/StackFrame.js +0 -0
  560. package/dist/preview-server/error-overlay/remotion-overlay/Symbolicating.d.ts +0 -0
  561. package/dist/preview-server/error-overlay/remotion-overlay/Symbolicating.js +0 -0
  562. package/dist/preview-server/error-overlay/remotion-overlay/carets.d.ts +0 -0
  563. package/dist/preview-server/error-overlay/remotion-overlay/carets.js +0 -0
  564. package/dist/preview-server/error-overlay/remotion-overlay/format-location.d.ts +0 -0
  565. package/dist/preview-server/error-overlay/remotion-overlay/format-location.js +0 -0
  566. package/dist/preview-server/error-overlay/remotion-overlay/get-help-link.d.ts +0 -0
  567. package/dist/preview-server/error-overlay/remotion-overlay/get-help-link.js +0 -0
  568. package/dist/preview-server/error-overlay/remotion-overlay/index.d.ts +0 -0
  569. package/dist/preview-server/error-overlay/remotion-overlay/index.js +0 -0
  570. package/dist/preview-server/get-package-manager.d.ts +1 -1
  571. package/dist/preview-server/get-package-manager.js +10 -1
  572. package/dist/preview-server/hot-middleware/client.d.ts +0 -0
  573. package/dist/preview-server/hot-middleware/client.js +0 -0
  574. package/dist/preview-server/hot-middleware/index.d.ts +0 -0
  575. package/dist/preview-server/hot-middleware/index.js +1 -2
  576. package/dist/preview-server/hot-middleware/process-update.d.ts +0 -0
  577. package/dist/preview-server/hot-middleware/process-update.js +0 -0
  578. package/dist/preview-server/hot-middleware/strip-ansi.d.ts +0 -0
  579. package/dist/preview-server/hot-middleware/strip-ansi.js +0 -0
  580. package/dist/preview-server/hot-middleware/types.d.ts +0 -0
  581. package/dist/preview-server/hot-middleware/types.js +0 -0
  582. package/dist/preview-server/live-events.d.ts +0 -0
  583. package/dist/preview-server/live-events.js +0 -0
  584. package/dist/preview-server/project-info.d.ts +0 -0
  585. package/dist/preview-server/project-info.js +9 -1
  586. package/dist/preview-server/routes.d.ts +2 -1
  587. package/dist/preview-server/routes.js +5 -3
  588. package/dist/preview-server/serve-static.d.ts +0 -0
  589. package/dist/preview-server/serve-static.js +0 -0
  590. package/dist/preview-server/start-server.d.ts +1 -1
  591. package/dist/preview-server/start-server.js +13 -6
  592. package/dist/preview-server/update-available.d.ts +0 -0
  593. package/dist/preview-server/update-available.js +2 -2
  594. package/dist/preview.d.ts +1 -1
  595. package/dist/preview.js +24 -8
  596. package/dist/previewEntry.d.ts +0 -0
  597. package/dist/previewEntry.js +0 -0
  598. package/dist/print-error.d.ts +0 -0
  599. package/dist/print-error.js +0 -0
  600. package/dist/print-help.d.ts +0 -0
  601. package/dist/print-help.js +14 -3
  602. package/dist/progress-bar.d.ts +0 -0
  603. package/dist/progress-bar.js +3 -1
  604. package/dist/render.d.ts +1 -1
  605. package/dist/render.js +55 -48
  606. package/dist/resolve-from.d.ts +0 -0
  607. package/dist/resolve-from.js +0 -0
  608. package/dist/select-composition.d.ts +7 -0
  609. package/dist/select-composition.js +51 -0
  610. package/dist/setup-cache.d.ts +0 -0
  611. package/dist/setup-cache.js +0 -0
  612. package/dist/smooth-zoom.d.ts +0 -0
  613. package/dist/smooth-zoom.js +0 -0
  614. package/dist/step.d.ts +0 -0
  615. package/dist/step.js +0 -0
  616. package/dist/still.d.ts +1 -1
  617. package/dist/still.js +41 -42
  618. package/dist/truthy.d.ts +0 -0
  619. package/dist/truthy.js +0 -0
  620. package/dist/upgrade.d.ts +1 -1
  621. package/dist/upgrade.js +4 -2
  622. package/dist/user-passed-output-location.d.ts +3 -2
  623. package/dist/user-passed-output-location.js +5 -7
  624. package/dist/versions.d.ts +0 -0
  625. package/dist/versions.js +1 -1
  626. package/package.json +13 -12
  627. package/dist/bundle.d.ts +0 -1
  628. package/dist/bundle.js +0 -32
  629. package/dist/check-version.d.ts +0 -1
  630. package/dist/check-version.js +0 -14
  631. package/dist/config/bundle-out-dir.d.ts +0 -2
  632. package/dist/config/bundle-out-dir.js +0 -12
  633. package/dist/config/get-public-path.d.ts +0 -2
  634. package/dist/config/get-public-path.js +0 -12
  635. package/dist/editor/components/Button.d.ts +0 -4
  636. package/dist/editor/components/Button.js +0 -24
  637. package/dist/editor/components/PreviewZoomControls.d.ts +0 -2
  638. package/dist/editor/components/PreviewZoomControls.js +0 -49
  639. package/dist/editor/helpers/normalize-wheel.d.ts +0 -5
  640. package/dist/editor/helpers/normalize-wheel.js +0 -20
  641. package/dist/initialize-render-cli.d.ts +0 -1
  642. package/dist/prepare-entry-point.d.ts +0 -12
  643. package/dist/prepare-entry-point.js +0 -37
  644. package/dist/validate-ffmpeg-version.d.ts +0 -3
  645. package/dist/validate-ffmpeg-version.js +0 -17
  646. package/dist/warn-about-ffmpeg-version.d.ts +0 -5
  647. package/dist/warn-about-ffmpeg-version.js +0 -38
  648. package/dist/webpack-cache.d.ts +0 -12
  649. package/dist/webpack-cache.js +0 -66
  650. package/vitest.config.ts +0 -9
@@ -3,7 +3,7 @@ import type { LiveEventsServer } from './live-events';
3
3
  export declare const startServer: (entry: string, userDefinedComponent: string, options: {
4
4
  webpackOverride: WebpackOverrideFn;
5
5
  getCurrentInputProps: () => object;
6
- envVariables?: Record<string, string>;
6
+ getEnvVariables: () => Record<string, string>;
7
7
  port: number | null;
8
8
  maxTimelineTracks?: number;
9
9
  remotionRoot: string;
@@ -12,6 +12,7 @@ const http_1 = __importDefault(require("http"));
12
12
  const os_1 = __importDefault(require("os"));
13
13
  const path_1 = __importDefault(require("path"));
14
14
  const config_1 = require("../config");
15
+ const log_1 = require("../log");
15
16
  const dev_middleware_1 = require("./dev-middleware");
16
17
  const hot_middleware_1 = require("./hot-middleware");
17
18
  const live_events_1 = require("./live-events");
@@ -25,7 +26,7 @@ const startServer = async (entry, userDefinedComponent, options) => {
25
26
  outDir: tmpDir,
26
27
  environment: 'development',
27
28
  webpackOverride: (_a = options === null || options === void 0 ? void 0 : options.webpackOverride) !== null && _a !== void 0 ? _a : config_1.ConfigInternals.getWebpackOverrideFn(),
28
- envVariables: (_b = options === null || options === void 0 ? void 0 : options.envVariables) !== null && _b !== void 0 ? _b : {},
29
+ envVariables: (_b = options === null || options === void 0 ? void 0 : options.getEnvVariables()) !== null && _b !== void 0 ? _b : {},
29
30
  maxTimelineTracks: (_c = options === null || options === void 0 ? void 0 : options.maxTimelineTracks) !== null && _c !== void 0 ? _c : 15,
30
31
  entryPoints: [
31
32
  require.resolve('./hot-middleware/client'),
@@ -61,16 +62,22 @@ const startServer = async (entry, userDefinedComponent, options) => {
61
62
  response,
62
63
  liveEventsServer,
63
64
  getCurrentInputProps: options.getCurrentInputProps,
65
+ getEnvVariables: options.getEnvVariables,
64
66
  remotionRoot: options.remotionRoot,
65
67
  userPassedPublicDir: options.userPassedPublicDir,
66
68
  });
67
69
  })
68
70
  .catch((err) => {
69
- response.setHeader('content-type', 'application/json');
70
- response.writeHead(500);
71
- response.end(JSON.stringify({
72
- err: err.message,
73
- }));
71
+ log_1.Log.error(`Error while calling ${request.url}`, err);
72
+ if (!response.headersSent) {
73
+ response.setHeader('content-type', 'application/json');
74
+ response.writeHead(500);
75
+ }
76
+ if (!response.writableEnded) {
77
+ response.end(JSON.stringify({
78
+ err: err.message,
79
+ }));
80
+ }
74
81
  });
75
82
  });
76
83
  const desiredPort = (_d = options === null || options === void 0 ? void 0 : options.port) !== null && _d !== void 0 ? _d : undefined;
File without changes
@@ -9,7 +9,7 @@ const get_latest_remotion_version_1 = require("../get-latest-remotion-version");
9
9
  const get_package_manager_1 = require("./get-package-manager");
10
10
  const isUpdateAvailable = async ({ remotionRoot, currentVersion, }) => {
11
11
  const latest = await (0, get_latest_remotion_version_1.getLatestRemotionVersion)();
12
- const pkgManager = (0, get_package_manager_1.getPackageManager)(remotionRoot);
12
+ const pkgManager = (0, get_package_manager_1.getPackageManager)(remotionRoot, undefined);
13
13
  return {
14
14
  updateAvailable: semver_1.default.lt(currentVersion, latest),
15
15
  currentVersion,
@@ -28,7 +28,7 @@ exports.getRemotionVersion = getRemotionVersion;
28
28
  const isUpdateAvailableWithTimeout = (remotionRoot) => {
29
29
  const version = (0, exports.getRemotionVersion)();
30
30
  const threeSecTimeout = new Promise((resolve) => {
31
- const pkgManager = (0, get_package_manager_1.getPackageManager)(remotionRoot);
31
+ const pkgManager = (0, get_package_manager_1.getPackageManager)(remotionRoot, undefined);
32
32
  setTimeout(() => {
33
33
  resolve({
34
34
  currentVersion: version,
package/dist/preview.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const previewCommand: (remotionRoot: string) => Promise<void>;
1
+ export declare const previewCommand: (remotionRoot: string, args: string[]) => Promise<void>;
package/dist/preview.js CHANGED
@@ -6,10 +6,12 @@ Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.previewCommand = void 0;
7
7
  const better_opn_1 = __importDefault(require("better-opn"));
8
8
  const path_1 = __importDefault(require("path"));
9
+ const chalk_1 = require("./chalk");
9
10
  const config_1 = require("./config");
11
+ const entry_point_1 = require("./entry-point");
10
12
  const get_env_1 = require("./get-env");
11
13
  const get_input_props_1 = require("./get-input-props");
12
- const initialize_render_cli_1 = require("./initialize-render-cli");
14
+ const get_network_address_1 = require("./get-network-address");
13
15
  const log_1 = require("./log");
14
16
  const parse_command_line_1 = require("./parse-command-line");
15
17
  const start_server_1 = require("./preview-server/start-server");
@@ -30,17 +32,17 @@ const waitForLiveEventsListener = () => {
30
32
  });
31
33
  });
32
34
  };
33
- const previewCommand = async (remotionRoot) => {
34
- const file = parse_command_line_1.parsedCli._[1];
35
+ const previewCommand = async (remotionRoot, args) => {
36
+ const { file, reason } = (0, entry_point_1.findEntryPoint)(args, remotionRoot);
37
+ log_1.Log.verbose('Entry point:', file, 'reason:', reason);
35
38
  if (!file) {
36
39
  log_1.Log.error('The preview command requires you to specify a root file. For example');
37
- log_1.Log.error(' npx remotion preview src/index.tsx');
40
+ log_1.Log.error(' npx remotion preview src/index.ts');
38
41
  log_1.Log.error('See https://www.remotion.dev/docs/register-root for more information.');
39
42
  process.exit(1);
40
43
  }
41
44
  const { port: desiredPort } = parse_command_line_1.parsedCli;
42
45
  const fullPath = path_1.default.join(process.cwd(), file);
43
- await (0, initialize_render_cli_1.initializeRenderCli)(remotionRoot, 'preview');
44
46
  let inputProps = (0, get_input_props_1.getInputProps)((newProps) => {
45
47
  waitForLiveEventsListener().then((listener) => {
46
48
  inputProps = newProps;
@@ -50,10 +52,18 @@ const previewCommand = async (remotionRoot) => {
50
52
  });
51
53
  });
52
54
  });
53
- const envVariables = await (0, get_env_1.getEnvironmentVariables)();
55
+ let envVariables = await (0, get_env_1.getEnvironmentVariables)((newEnvVariables) => {
56
+ waitForLiveEventsListener().then((listener) => {
57
+ envVariables = newEnvVariables;
58
+ listener.sendEventToClient({
59
+ type: 'new-env-variables',
60
+ newEnvVariables,
61
+ });
62
+ });
63
+ });
54
64
  const { port, liveEventsServer } = await (0, start_server_1.startServer)(path_1.default.resolve(__dirname, 'previewEntry.js'), fullPath, {
55
65
  getCurrentInputProps: () => inputProps,
56
- envVariables,
66
+ getEnvVariables: () => envVariables,
57
67
  port: desiredPort,
58
68
  maxTimelineTracks: config_1.ConfigInternals.getMaxTimelineTracks(),
59
69
  remotionRoot,
@@ -62,7 +72,13 @@ const previewCommand = async (remotionRoot) => {
62
72
  webpackOverride: config_1.ConfigInternals.getWebpackOverrideFn(),
63
73
  });
64
74
  setLiveEventsListener(liveEventsServer);
65
- log_1.Log.info(`Server running on http://localhost:${port}`);
75
+ const networkAddress = (0, get_network_address_1.getNetworkAddress)();
76
+ if (networkAddress) {
77
+ log_1.Log.info(`Server ready - Local: ${chalk_1.chalk.underline(`http://localhost:${port}`)}, Network: ${chalk_1.chalk.underline(`http://${networkAddress}:${port}`)}`);
78
+ }
79
+ else {
80
+ log_1.Log.info(`Running on http://localhost:${port}`);
81
+ }
66
82
  (0, better_opn_1.default)(`http://localhost:${port}`);
67
83
  await new Promise(noop);
68
84
  };
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -11,7 +11,7 @@ const printFlags = (flags) => {
11
11
  });
12
12
  };
13
13
  const printHelp = () => {
14
- log_1.Log.info(`@remotion/cli ${packagejson.version} © ${new Date().getFullYear()} Jonny Burger`);
14
+ log_1.Log.info(`@remotion/cli ${packagejson.version} © ${new Date().getFullYear()} The Remotion developers`);
15
15
  log_1.Log.info();
16
16
  log_1.Log.info('Available commands:');
17
17
  log_1.Log.info('');
@@ -19,7 +19,7 @@ const printHelp = () => {
19
19
  log_1.Log.info(chalk_1.chalk.gray('Start the preview server.'));
20
20
  printFlags([['--props', 'Pass input props as filename or as JSON']]);
21
21
  log_1.Log.info();
22
- log_1.Log.info('remotion render <entry-point.ts> <comp-name> <output-file.mp4>');
22
+ log_1.Log.info('remotion render <entry-point.ts> <comp-id> <output-file.mp4>');
23
23
  log_1.Log.info(chalk_1.chalk.gray('Render video, audio or an image sequence.'));
24
24
  printFlags([
25
25
  ['--props', 'Pass input props as filename or as JSON'],
@@ -31,6 +31,8 @@ const printHelp = () => {
31
31
  ['--overwrite', 'Overwrite if file exists, default true'],
32
32
  ['--sequence', 'Output as an image sequence'],
33
33
  ['--codec', 'Video of audio codec'],
34
+ ['--audio-bitrate', 'Customize the output audio bitrate'],
35
+ ['--video-bitrate', 'Customize the output video bitrate'],
34
36
  ['--crf', 'FFMPEG CRF value, controls quality, see docs for info'],
35
37
  ['--browser-executable', 'Custom path for browser executable'],
36
38
  ['--frames', 'Render a portion or a still of a video'],
@@ -40,7 +42,7 @@ const printHelp = () => {
40
42
  ['--env-file', 'Specify a location for a dotenv file'],
41
43
  ]);
42
44
  log_1.Log.info();
43
- log_1.Log.info('remotion still <entry-point.ts> <comp-name> <still.png>');
45
+ log_1.Log.info('remotion still <entry-point.ts> <comp-id> <still.png>');
44
46
  log_1.Log.info(chalk_1.chalk.gray('Render a still frame and save it as an image.'));
45
47
  printFlags([
46
48
  ['--frame', 'Which frame to render (default 0)'],
@@ -59,11 +61,20 @@ const printHelp = () => {
59
61
  log_1.Log.info('remotion compositions <index-file.ts>');
60
62
  log_1.Log.info(chalk_1.chalk.gray('Prints the available compositions.'));
61
63
  log_1.Log.info();
64
+ log_1.Log.info('remotion benchmark <index-file.ts> <list-of-compositions>');
65
+ log_1.Log.info(chalk_1.chalk.gray('Benchmarks rendering a composition. Same options as for render.'));
66
+ log_1.Log.info();
62
67
  log_1.Log.info('remotion ' + versions_1.VERSIONS_COMMAND);
63
68
  log_1.Log.info(chalk_1.chalk.gray('Prints and validates versions of all Remotion packages.'));
64
69
  log_1.Log.info();
65
70
  log_1.Log.info('remotion upgrade');
66
71
  log_1.Log.info(chalk_1.chalk.gray('Ensure Remotion is on the newest version.'));
72
+ printFlags([
73
+ [
74
+ '--package-manager',
75
+ 'Force a specific package manager, defaults to use from lockfile',
76
+ ],
77
+ ]);
67
78
  log_1.Log.info();
68
79
  log_1.Log.info('Visit https://www.remotion.dev/docs/cli for browsable CLI documentation.');
69
80
  };
File without changes
@@ -34,7 +34,9 @@ const makeBundlingProgress = ({ progress, steps, doneIn, }) => [
34
34
  doneIn === null
35
35
  ? (progress * 100).toFixed(0) + '%'
36
36
  : chalk_1.chalk.gray(`${doneIn}ms`),
37
- ].join(' ');
37
+ ]
38
+ .filter(truthy_1.truthy)
39
+ .join(' ');
38
40
  exports.makeBundlingProgress = makeBundlingProgress;
39
41
  const makeRenderingProgress = ({ frames, totalFrames, steps, concurrency, doneIn, }) => {
40
42
  const progress = frames / totalFrames;
package/dist/render.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const render: (remotionRoot: string) => Promise<void>;
1
+ export declare const render: (remotionRoot: string, args: string[]) => Promise<void>;
package/dist/render.js CHANGED
@@ -12,18 +12,20 @@ const path_1 = __importDefault(require("path"));
12
12
  const remotion_1 = require("remotion");
13
13
  const chalk_1 = require("./chalk");
14
14
  const config_1 = require("./config");
15
+ const entry_point_1 = require("./entry-point");
15
16
  const get_cli_options_1 = require("./get-cli-options");
16
- const get_composition_id_1 = require("./get-composition-id");
17
+ const get_composition_with_dimension_override_1 = require("./get-composition-with-dimension-override");
17
18
  const get_filename_1 = require("./get-filename");
18
- const initialize_render_cli_1 = require("./initialize-render-cli");
19
+ const get_render_media_options_1 = require("./get-render-media-options");
20
+ const image_formats_1 = require("./image-formats");
19
21
  const log_1 = require("./log");
20
22
  const parse_command_line_1 = require("./parse-command-line");
21
23
  const progress_bar_1 = require("./progress-bar");
22
24
  const setup_cache_1 = require("./setup-cache");
23
- const validate_ffmpeg_version_1 = require("./validate-ffmpeg-version");
24
- const render = async (remotionRoot) => {
25
+ const user_passed_output_location_1 = require("./user-passed-output-location");
26
+ const render = async (remotionRoot, args) => {
25
27
  const startTime = Date.now();
26
- const file = parse_command_line_1.parsedCli._[1];
28
+ const { file, remainingArgs, reason: entryPointReason, } = (0, entry_point_1.findEntryPoint)(args, remotionRoot);
27
29
  if (!file) {
28
30
  log_1.Log.error('No entry point specified. Pass more arguments:');
29
31
  log_1.Log.error(' npx remotion render [entry-point] [composition-name] [out-name]');
@@ -34,25 +36,22 @@ const render = async (remotionRoot) => {
34
36
  ? file
35
37
  : path_1.default.join(process.cwd(), file);
36
38
  const downloadMap = renderer_1.RenderInternals.makeDownloadMap();
37
- await (0, initialize_render_cli_1.initializeRenderCli)(remotionRoot, 'sequence');
39
+ if (parse_command_line_1.parsedCli.frame) {
40
+ log_1.Log.error('--frame flag was passed to the `render` command. This flag only works with the `still` command. Did you mean `--frames`? See reference: https://www.remotion.dev/docs/cli/');
41
+ process.exit(1);
42
+ }
38
43
  log_1.Log.verbose('Asset dirs', downloadMap.assetDir);
39
- const { codec, proResProfile, concurrency, frameRange, shouldOutputImageSequence, overwrite, inputProps, envVariables, quality, browser, crf, pixelFormat, imageFormat, browserExecutable, ffmpegExecutable, ffprobeExecutable, scale, chromiumOptions, port, numberOfGifLoops, everyNthFrame, puppeteerTimeout, muted, enforceAudioTrack, publicDir, } = await (0, get_cli_options_1.getCliOptions)({
44
+ const { concurrency, frameRange, shouldOutputImageSequence, overwrite, inputProps, envVariables, quality, browser, browserExecutable, ffmpegExecutable, ffprobeExecutable, scale, chromiumOptions, port, everyNthFrame, puppeteerTimeout, publicDir, height, width, } = await (0, get_cli_options_1.getCliOptions)({
40
45
  isLambda: false,
41
46
  type: 'series',
47
+ remotionRoot,
42
48
  });
43
- const relativeOutputLocation = (0, get_filename_1.getOutputFilename)({
44
- codec,
45
- imageSequence: shouldOutputImageSequence,
46
- compositionName: (0, get_composition_id_1.getCompositionId)(),
47
- defaultExtension: renderer_1.RenderInternals.getFileExtensionFromCodec(codec, 'final'),
48
- });
49
- const absoluteOutputFile = (0, get_cli_options_1.getAndValidateAbsoluteOutputFile)(relativeOutputLocation, overwrite);
50
- const compositionId = (0, get_composition_id_1.getCompositionId)();
51
- log_1.Log.info(chalk_1.chalk.gray(`Composition = ${compositionId}, Codec = ${codec}, Output = ${relativeOutputLocation}`));
52
- log_1.Log.verbose('Browser executable: ', browserExecutable);
53
- await (0, validate_ffmpeg_version_1.checkAndValidateFfmpegVersion)({
49
+ const ffmpegVersion = await renderer_1.RenderInternals.getFfmpegVersion({
54
50
  ffmpegExecutable,
51
+ remotionRoot,
55
52
  });
53
+ log_1.Log.verbose('FFMPEG Version:', ffmpegVersion ? ffmpegVersion.join('.') : 'Built from source');
54
+ log_1.Log.verbose('Browser executable: ', browserExecutable);
56
55
  const browserInstance = (0, renderer_1.openBrowser)(browser, {
57
56
  browserExecutable,
58
57
  shouldDumpIo: renderer_1.RenderInternals.isEqualOrBelowLogLevel(config_1.ConfigInternals.Logging.getLogLevel(), 'verbose'),
@@ -93,21 +92,38 @@ const render = async (remotionRoot) => {
93
92
  inputProps,
94
93
  puppeteerInstance,
95
94
  envVariables,
96
- timeoutInMilliseconds: config_1.ConfigInternals.getCurrentPuppeteerTimeout(),
95
+ timeoutInMilliseconds: puppeteerTimeout,
97
96
  chromiumOptions,
98
97
  browserExecutable,
99
98
  downloadMap,
99
+ port,
100
100
  });
101
- const config = comps.find((c) => c.id === compositionId);
102
- if (!config) {
103
- throw new Error(`Cannot find composition with ID ${compositionId}`);
104
- }
101
+ const { compositionId, config, reason, argsAfterComposition } = await (0, get_composition_with_dimension_override_1.getCompositionWithDimensionOverride)({
102
+ validCompositions: comps,
103
+ height,
104
+ width,
105
+ args: remainingArgs,
106
+ });
107
+ const { codec, reason: codecReason } = (0, get_cli_options_1.getFinalCodec)({
108
+ downloadName: null,
109
+ outName: (0, user_passed_output_location_1.getUserPassedOutputLocation)(argsAfterComposition),
110
+ });
111
+ (0, get_cli_options_1.validateFfmepgCanUseCodec)(codec, remotionRoot);
105
112
  renderer_1.RenderInternals.validateEvenDimensionsWithCodec({
106
113
  width: config.width,
107
114
  height: config.height,
108
115
  codec,
109
116
  scale,
110
117
  });
118
+ const relativeOutputLocation = (0, get_filename_1.getOutputFilename)({
119
+ codec,
120
+ imageSequence: shouldOutputImageSequence,
121
+ compositionName: compositionId,
122
+ defaultExtension: renderer_1.RenderInternals.getFileExtensionFromCodec(codec, 'final'),
123
+ args: argsAfterComposition,
124
+ });
125
+ log_1.Log.info(chalk_1.chalk.gray(`Entry point = ${file} (${entryPointReason}), Composition = ${compositionId} (${reason}), Codec = ${codec} (${codecReason}), Output = ${relativeOutputLocation}`));
126
+ const absoluteOutputFile = (0, get_cli_options_1.getAndValidateAbsoluteOutputFile)(relativeOutputLocation, overwrite);
111
127
  const outputDir = shouldOutputImageSequence
112
128
  ? absoluteOutputFile
113
129
  : await fs_1.default.promises.mkdtemp(path_1.default.join(os_1.default.tmpdir(), 'react-motion-render'));
@@ -146,6 +162,7 @@ const render = async (remotionRoot) => {
146
162
  downloads,
147
163
  }));
148
164
  };
165
+ const imageFormat = (0, image_formats_1.getImageFormat)(shouldOutputImageSequence ? undefined : codec);
149
166
  if (shouldOutputImageSequence) {
150
167
  fs_1.default.mkdirSync(absoluteOutputFile, {
151
168
  recursive: true,
@@ -195,19 +212,18 @@ const render = async (remotionRoot) => {
195
212
  log_1.Log.info();
196
213
  log_1.Log.info();
197
214
  log_1.Log.info(chalk_1.chalk.green('\nYour image sequence is ready!'));
215
+ log_1.Log.info(chalk_1.chalk.cyan(`▶ ${absoluteOutputFile}`));
198
216
  return;
199
217
  }
200
- await (0, renderer_1.renderMedia)({
218
+ const options = await (0, get_render_media_options_1.getRenderMediaOptions)({
219
+ config,
201
220
  outputLocation: absoluteOutputFile,
221
+ serveUrl: urlOrBundle,
202
222
  codec,
203
- composition: config,
204
- crf,
205
- envVariables,
206
- ffmpegExecutable,
207
- ffprobeExecutable,
208
- frameRange,
209
- imageFormat,
210
- inputProps,
223
+ remotionRoot,
224
+ });
225
+ await (0, renderer_1.renderMedia)({
226
+ ...options,
211
227
  onProgress: (update) => {
212
228
  encodedDoneIn = update.encodedDoneIn;
213
229
  encodedFrames = update.encodedFrames;
@@ -217,24 +233,15 @@ const render = async (remotionRoot) => {
217
233
  updateRenderProgress();
218
234
  },
219
235
  puppeteerInstance,
220
- overwrite,
221
- concurrency,
222
- pixelFormat,
223
- proResProfile,
224
- quality,
225
- serveUrl: urlOrBundle,
226
236
  onDownload,
227
- dumpBrowserLogs: renderer_1.RenderInternals.isEqualOrBelowLogLevel(config_1.ConfigInternals.Logging.getLogLevel(), 'verbose'),
228
- chromiumOptions,
229
- timeoutInMilliseconds: config_1.ConfigInternals.getCurrentPuppeteerTimeout(),
230
- scale,
231
- port,
232
- numberOfGifLoops,
233
- everyNthFrame,
234
- verbose: renderer_1.RenderInternals.isEqualOrBelowLogLevel(config_1.ConfigInternals.Logging.getLogLevel(), 'verbose'),
235
237
  downloadMap,
236
- muted,
237
- enforceAudioTrack,
238
+ onSlowestFrames: (slowestFrames) => {
239
+ log_1.Log.verbose();
240
+ log_1.Log.verbose(`Slowest frames:`);
241
+ slowestFrames.forEach(({ frame, time }) => {
242
+ log_1.Log.verbose(`Frame ${frame} (${time.toFixed(3)}ms)`);
243
+ });
244
+ },
238
245
  });
239
246
  log_1.Log.info();
240
247
  log_1.Log.info();
File without changes
File without changes
@@ -0,0 +1,7 @@
1
+ import type { getCompositions } from '@remotion/renderer';
2
+ export declare type Await<T> = T extends PromiseLike<infer U> ? U : T;
3
+ export declare const selectComposition: (validCompositions: Await<ReturnType<typeof getCompositions>>) => Promise<{
4
+ compositionId: string;
5
+ reason: string;
6
+ }>;
7
+ export declare const selectCompositions: (validCompositions: Await<ReturnType<typeof getCompositions>>) => Promise<string[]>;
@@ -0,0 +1,51 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.selectCompositions = exports.selectComposition = void 0;
4
+ const composition_prompts_1 = require("./composition-prompts");
5
+ const chalk_1 = require("./chalk");
6
+ const selectComposition = async (validCompositions) => {
7
+ if (validCompositions.length === 1) {
8
+ const onlyComposition = validCompositions[0];
9
+ if (onlyComposition) {
10
+ return {
11
+ compositionId: onlyComposition.id,
12
+ reason: 'Only composition',
13
+ };
14
+ }
15
+ }
16
+ const selectedComposition = (await (0, composition_prompts_1.selectAsync)({
17
+ message: 'Select composition:',
18
+ optionsPerPage: 5,
19
+ type: 'select',
20
+ choices: validCompositions.map((comp) => {
21
+ return {
22
+ value: comp.id,
23
+ title: chalk_1.chalk.bold(comp.id),
24
+ };
25
+ }),
26
+ }));
27
+ return { compositionId: selectedComposition, reason: 'Selected' };
28
+ };
29
+ exports.selectComposition = selectComposition;
30
+ const selectCompositions = async (validCompositions) => {
31
+ if (validCompositions.length === 1) {
32
+ const onlyComposition = validCompositions[0];
33
+ if (onlyComposition) {
34
+ return [onlyComposition.id];
35
+ }
36
+ }
37
+ const selectedComposition = await (0, composition_prompts_1.selectAsync)({
38
+ message: 'Select compositions:',
39
+ optionsPerPage: 5,
40
+ type: 'multiselect',
41
+ min: 1,
42
+ choices: validCompositions.map((comp) => {
43
+ return {
44
+ value: comp.id,
45
+ title: chalk_1.chalk.bold(comp.id),
46
+ };
47
+ }),
48
+ });
49
+ return selectedComposition;
50
+ };
51
+ exports.selectCompositions = selectCompositions;
File without changes
File without changes
File without changes
File without changes
package/dist/step.d.ts CHANGED
File without changes
package/dist/step.js CHANGED
File without changes
package/dist/still.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const still: (remotionRoot: string) => Promise<void>;
1
+ export declare const still: (remotionRoot: string, args: string[]) => Promise<void>;
package/dist/still.js CHANGED
@@ -9,65 +9,45 @@ const fs_1 = require("fs");
9
9
  const path_1 = __importDefault(require("path"));
10
10
  const chalk_1 = require("./chalk");
11
11
  const config_1 = require("./config");
12
+ const determine_image_format_1 = require("./determine-image-format");
13
+ const entry_point_1 = require("./entry-point");
12
14
  const get_cli_options_1 = require("./get-cli-options");
13
- const get_composition_id_1 = require("./get-composition-id");
14
- const initialize_render_cli_1 = require("./initialize-render-cli");
15
+ const get_composition_with_dimension_override_1 = require("./get-composition-with-dimension-override");
15
16
  const log_1 = require("./log");
16
17
  const parse_command_line_1 = require("./parse-command-line");
17
18
  const progress_bar_1 = require("./progress-bar");
18
19
  const setup_cache_1 = require("./setup-cache");
19
20
  const truthy_1 = require("./truthy");
20
21
  const user_passed_output_location_1 = require("./user-passed-output-location");
21
- const still = async (remotionRoot) => {
22
+ const still = async (remotionRoot, args) => {
23
+ var _a, _b;
22
24
  const startTime = Date.now();
23
- const file = parse_command_line_1.parsedCli._[1];
25
+ const { file, remainingArgs, reason: entryPointReason, } = (0, entry_point_1.findEntryPoint)(args, remotionRoot);
26
+ if (!file) {
27
+ log_1.Log.error('No entry point specified. Pass more arguments:');
28
+ log_1.Log.error(' npx remotion render [entry-point] [composition-name] [out-name]');
29
+ log_1.Log.error('Documentation: https://www.remotion.dev/docs/render');
30
+ process.exit(1);
31
+ }
24
32
  const fullPath = renderer_1.RenderInternals.isServeUrl(file)
25
33
  ? file
26
34
  : path_1.default.join(process.cwd(), file);
27
- await (0, initialize_render_cli_1.initializeRenderCli)(remotionRoot, 'still');
28
- const userPassedOutput = (0, user_passed_output_location_1.getUserPassedOutputLocation)();
29
- if ((userPassedOutput === null || userPassedOutput === void 0 ? void 0 : userPassedOutput.endsWith('.jpeg')) ||
30
- (userPassedOutput === null || userPassedOutput === void 0 ? void 0 : userPassedOutput.endsWith('.jpg'))) {
31
- log_1.Log.verbose('Output file has a JPEG extension, setting the image format to JPEG.');
32
- config_1.Config.Rendering.setImageFormat('jpeg');
33
- }
34
- if (userPassedOutput === null || userPassedOutput === void 0 ? void 0 : userPassedOutput.endsWith('.png')) {
35
- log_1.Log.verbose('Output file has a PNG extension, setting the image format to PNG.');
36
- config_1.Config.Rendering.setImageFormat('png');
35
+ if (parse_command_line_1.parsedCli.frames) {
36
+ log_1.Log.error('--frames flag was passed to the `still` command. This flag only works with the `render` command. Did you mean `--frame`? See reference: https://www.remotion.dev/docs/cli/');
37
+ process.exit(1);
37
38
  }
38
- const { inputProps, envVariables, quality, browser, imageFormat, stillFrame, browserExecutable, chromiumOptions, scale, ffmpegExecutable, ffprobeExecutable, overwrite, puppeteerTimeout, port, publicDir, } = await (0, get_cli_options_1.getCliOptions)({
39
+ const { inputProps, envVariables, quality, browser, stillFrame, browserExecutable, chromiumOptions, scale, ffmpegExecutable, ffprobeExecutable, overwrite, puppeteerTimeout, port, publicDir, height, width, } = await (0, get_cli_options_1.getCliOptions)({
39
40
  isLambda: false,
40
41
  type: 'still',
42
+ remotionRoot,
41
43
  });
42
44
  log_1.Log.verbose('Browser executable: ', browserExecutable);
43
- const compositionId = (0, get_composition_id_1.getCompositionId)();
44
- const relativeOutputLocation = (0, user_passed_output_location_1.getOutputLocation)({
45
- compositionId,
46
- defaultExtension: imageFormat,
47
- });
48
- const absoluteOutputLocation = (0, get_cli_options_1.getAndValidateAbsoluteOutputFile)(relativeOutputLocation, overwrite);
49
- log_1.Log.info(chalk_1.chalk.gray(`Output = ${relativeOutputLocation}, Format = ${imageFormat}, Composition = ${compositionId}`));
50
- if (imageFormat === 'none') {
51
- log_1.Log.error('No image format was selected - this is probably an error in Remotion - please post your command on Github Issues for help.');
52
- process.exit(1);
53
- }
54
- if (imageFormat === 'png' && !absoluteOutputLocation.endsWith('.png')) {
55
- log_1.Log.warn(`Rendering a PNG, expected a .png extension but got ${absoluteOutputLocation}`);
56
- }
57
- if (imageFormat === 'jpeg' &&
58
- !absoluteOutputLocation.endsWith('.jpg') &&
59
- !absoluteOutputLocation.endsWith('.jpeg')) {
60
- log_1.Log.warn(`Rendering a JPEG, expected a .jpg or .jpeg extension but got ${absoluteOutputLocation}`);
61
- }
62
45
  const browserInstance = (0, renderer_1.openBrowser)(browser, {
63
46
  browserExecutable,
64
47
  chromiumOptions,
65
48
  shouldDumpIo: renderer_1.RenderInternals.isEqualOrBelowLogLevel(config_1.ConfigInternals.Logging.getLogLevel(), 'verbose'),
66
49
  forceDeviceScaleFactor: scale,
67
50
  });
68
- (0, fs_1.mkdirSync)(path_1.default.join(absoluteOutputLocation, '..'), {
69
- recursive: true,
70
- });
71
51
  const steps = [
72
52
  renderer_1.RenderInternals.isServeUrl(fullPath) ? null : 'bundling',
73
53
  'rendering',
@@ -87,10 +67,29 @@ const still = async (remotionRoot) => {
87
67
  ffprobeExecutable,
88
68
  downloadMap,
89
69
  });
90
- const composition = comps.find((c) => c.id === compositionId);
91
- if (!composition) {
92
- throw new Error(`Cannot find composition with ID ${compositionId}`);
93
- }
70
+ const { compositionId, config, reason, argsAfterComposition } = await (0, get_composition_with_dimension_override_1.getCompositionWithDimensionOverride)({
71
+ validCompositions: comps,
72
+ height,
73
+ width,
74
+ args: remainingArgs,
75
+ });
76
+ const { format: imageFormat, source } = (0, determine_image_format_1.determineFinalImageFormat)({
77
+ cliFlag: (_a = parse_command_line_1.parsedCli['image-format']) !== null && _a !== void 0 ? _a : null,
78
+ configImageFormat: (_b = config_1.ConfigInternals.getUserPreferredImageFormat()) !== null && _b !== void 0 ? _b : null,
79
+ downloadName: null,
80
+ outName: (0, user_passed_output_location_1.getUserPassedOutputLocation)(argsAfterComposition),
81
+ isLambda: false,
82
+ });
83
+ const relativeOutputLocation = (0, user_passed_output_location_1.getOutputLocation)({
84
+ compositionId,
85
+ defaultExtension: imageFormat,
86
+ args: argsAfterComposition,
87
+ });
88
+ const absoluteOutputLocation = (0, get_cli_options_1.getAndValidateAbsoluteOutputFile)(relativeOutputLocation, overwrite);
89
+ (0, fs_1.mkdirSync)(path_1.default.join(absoluteOutputLocation, '..'), {
90
+ recursive: true,
91
+ });
92
+ log_1.Log.info(chalk_1.chalk.gray(`Entry point = ${file} (${entryPointReason}), Output = ${relativeOutputLocation}, Format = ${imageFormat} (${source}), Composition = ${compositionId} (${reason})`));
94
93
  const renderProgress = (0, progress_bar_1.createOverwriteableCliOutput)((0, parse_command_line_1.quietFlagProvided)());
95
94
  const renderStart = Date.now();
96
95
  const downloads = [];
@@ -127,7 +126,7 @@ const still = async (remotionRoot) => {
127
126
  };
128
127
  };
129
128
  await (0, renderer_1.renderStill)({
130
- composition,
129
+ composition: config,
131
130
  frame: stillFrame,
132
131
  output: absoluteOutputLocation,
133
132
  serveUrl: urlOrBundle,
package/dist/truthy.d.ts CHANGED
File without changes
package/dist/truthy.js CHANGED
File without changes
package/dist/upgrade.d.ts CHANGED
@@ -1 +1 @@
1
- export declare const upgrade: (remotionRoot: string) => Promise<void>;
1
+ export declare const upgrade: (remotionRoot: string, packageManager: string | undefined) => Promise<void>;