@remotion/cli 3.0.29 → 3.1.0

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 (415) hide show
  1. package/dist/chalk/symbols.d.ts +111 -0
  2. package/dist/chalk/symbols.js +75 -0
  3. package/dist/chalk/utilities.d.ts +2 -0
  4. package/dist/chalk/utilities.js +37 -0
  5. package/dist/compositions.js +10 -4
  6. package/dist/editor/components/CompositionManager.d.ts +4 -0
  7. package/dist/editor/components/CompositionManager.js +60 -0
  8. package/dist/editor/components/CopyButton.js +1 -1
  9. package/dist/editor/components/Editor.js +2 -1
  10. package/dist/editor/components/GlobalKeybindings.js +26 -11
  11. package/dist/editor/components/KeyboardShortcutsModal.js +1 -1
  12. package/dist/editor/components/Menu/MenuItem.d.ts +1 -1
  13. package/dist/editor/components/MenuToolbar.js +24 -2
  14. package/dist/editor/components/NewComposition/MenuContent.js +42 -7
  15. package/dist/editor/components/Notifications/ColorDot.d.ts +4 -0
  16. package/dist/editor/components/Notifications/ColorDot.js +22 -0
  17. package/dist/editor/components/Notifications/Notification.d.ts +8 -0
  18. package/dist/editor/components/Notifications/Notification.js +31 -0
  19. package/dist/editor/components/Notifications/NotificationCenter.d.ts +13 -0
  20. package/dist/editor/components/Notifications/NotificationCenter.js +39 -0
  21. package/dist/editor/components/PlayPause.js +53 -7
  22. package/dist/editor/components/PlaybackKeyboardShortcutsManager.js +18 -3
  23. package/dist/editor/components/TimelineInOutToggle.js +21 -6
  24. package/dist/editor/components/UpdateModal/UpdateModal.js +1 -1
  25. package/dist/editor/helpers/copy-text.d.ts +1 -1
  26. package/dist/editor/helpers/copy-text.js +5 -4
  27. package/dist/editor/helpers/pick-color.d.ts +1 -0
  28. package/dist/editor/helpers/pick-color.js +36 -0
  29. package/dist/editor/helpers/use-keybinding.d.ts +6 -1
  30. package/dist/editor/helpers/use-keybinding.js +10 -5
  31. package/dist/editor/state/keybindings.js +3 -1
  32. package/dist/editor/state/z-index.js +6 -1
  33. package/dist/get-cli-options.d.ts +3 -1
  34. package/dist/get-cli-options.js +7 -1
  35. package/dist/image-formats.js +2 -1
  36. package/dist/index.d.ts +3 -1
  37. package/dist/parse-command-line.d.ts +2 -0
  38. package/dist/parse-command-line.js +9 -3
  39. package/dist/preview-server/error-overlay/remotion-overlay/AskOnDiscord.d.ts +3 -1
  40. package/dist/preview-server/error-overlay/remotion-overlay/AskOnDiscord.js +20 -2
  41. package/dist/preview-server/error-overlay/remotion-overlay/Button.js +4 -4
  42. package/dist/preview-server/error-overlay/remotion-overlay/ErrorDisplay.d.ts +1 -0
  43. package/dist/preview-server/error-overlay/remotion-overlay/ErrorDisplay.js +5 -2
  44. package/dist/preview-server/error-overlay/remotion-overlay/ErrorLoader.d.ts +1 -0
  45. package/dist/preview-server/error-overlay/remotion-overlay/ErrorLoader.js +2 -2
  46. package/dist/preview-server/error-overlay/remotion-overlay/ErrorMessage.d.ts +4 -0
  47. package/dist/preview-server/error-overlay/remotion-overlay/ErrorMessage.js +67 -0
  48. package/dist/preview-server/error-overlay/remotion-overlay/ErrorTitle.js +5 -9
  49. package/dist/preview-server/error-overlay/remotion-overlay/HelpLink.d.ts +6 -0
  50. package/dist/preview-server/error-overlay/remotion-overlay/HelpLink.js +31 -0
  51. package/dist/preview-server/error-overlay/remotion-overlay/OpenInEditor.d.ts +1 -0
  52. package/dist/preview-server/error-overlay/remotion-overlay/OpenInEditor.js +20 -2
  53. package/dist/preview-server/error-overlay/remotion-overlay/Overlay.js +8 -7
  54. package/dist/preview-server/error-overlay/remotion-overlay/SearchGitHubIssues.d.ts +1 -0
  55. package/dist/preview-server/error-overlay/remotion-overlay/SearchGitHubIssues.js +20 -2
  56. package/dist/preview-server/error-overlay/remotion-overlay/ShortcutHint.d.ts +5 -0
  57. package/dist/preview-server/error-overlay/remotion-overlay/ShortcutHint.js +16 -0
  58. package/dist/preview-server/error-overlay/remotion-overlay/StackFrame.js +1 -1
  59. package/dist/preview-server/error-overlay/remotion-overlay/carets.d.ts +4 -2
  60. package/dist/preview-server/error-overlay/remotion-overlay/carets.js +2 -2
  61. package/dist/preview-server/error-overlay/remotion-overlay/get-help-link.d.ts +5 -0
  62. package/dist/preview-server/error-overlay/remotion-overlay/get-help-link.js +19 -0
  63. package/dist/preview-server/fast-refresh/helpers.d.ts +39 -0
  64. package/dist/preview-server/fast-refresh/helpers.js +145 -0
  65. package/dist/preview-server/fast-refresh/index.d.ts +30 -0
  66. package/dist/preview-server/fast-refresh/index.js +86 -0
  67. package/dist/preview-server/fast-refresh/loader.d.ts +35 -0
  68. package/dist/preview-server/fast-refresh/loader.js +81 -0
  69. package/dist/preview-server/fast-refresh/runtime.d.ts +35 -0
  70. package/dist/preview-server/fast-refresh/runtime.js +32 -0
  71. package/dist/preview-server/static-preview.d.ts +1 -0
  72. package/dist/preview-server/static-preview.js +40 -0
  73. package/dist/preview-server/webpack-cache.d.ts +12 -0
  74. package/dist/preview-server/webpack-cache.js +66 -0
  75. package/dist/progress-bar.d.ts +3 -1
  76. package/dist/progress-bar.js +4 -3
  77. package/dist/render.js +13 -14
  78. package/dist/setup-cache.d.ts +4 -1
  79. package/dist/setup-cache.js +1 -1
  80. package/dist/still.js +1 -1
  81. package/package.json +10 -12
  82. package/tsconfig.json +2 -1
  83. package/vitest.config.ts +9 -0
  84. package/dist/ansi/ansi-diff.d.ts.map +0 -1
  85. package/dist/ansi/ansi-diff.js.map +0 -1
  86. package/dist/ansi/ansi-regex.d.ts.map +0 -1
  87. package/dist/ansi/ansi-regex.js.map +0 -1
  88. package/dist/ansi/ansi-split.d.ts.map +0 -1
  89. package/dist/ansi/ansi-split.js.map +0 -1
  90. package/dist/check-version.d.ts.map +0 -1
  91. package/dist/check-version.js.map +0 -1
  92. package/dist/code-frame.d.ts.map +0 -1
  93. package/dist/code-frame.js.map +0 -1
  94. package/dist/compositions.d.ts.map +0 -1
  95. package/dist/compositions.js.map +0 -1
  96. package/dist/download-progress.d.ts.map +0 -1
  97. package/dist/download-progress.js.map +0 -1
  98. package/dist/editor/components/AudioWaveform.d.ts.map +0 -1
  99. package/dist/editor/components/AudioWaveform.js.map +0 -1
  100. package/dist/editor/components/AudioWaveformBar.d.ts.map +0 -1
  101. package/dist/editor/components/AudioWaveformBar.js.map +0 -1
  102. package/dist/editor/components/Canvas.d.ts.map +0 -1
  103. package/dist/editor/components/Canvas.js.map +0 -1
  104. package/dist/editor/components/CheckboardToggle.d.ts.map +0 -1
  105. package/dist/editor/components/CheckboardToggle.js.map +0 -1
  106. package/dist/editor/components/ClipboardIcon.d.ts.map +0 -1
  107. package/dist/editor/components/ClipboardIcon.js.map +0 -1
  108. package/dist/editor/components/CompositionSelector.d.ts.map +0 -1
  109. package/dist/editor/components/CompositionSelector.js.map +0 -1
  110. package/dist/editor/components/CompositionSelectorItem.d.ts.map +0 -1
  111. package/dist/editor/components/CompositionSelectorItem.js.map +0 -1
  112. package/dist/editor/components/ControlButton.d.ts.map +0 -1
  113. package/dist/editor/components/ControlButton.js.map +0 -1
  114. package/dist/editor/components/CopyButton.d.ts.map +0 -1
  115. package/dist/editor/components/CopyButton.js.map +0 -1
  116. package/dist/editor/components/CurrentComposition.d.ts.map +0 -1
  117. package/dist/editor/components/CurrentComposition.js.map +0 -1
  118. package/dist/editor/components/Editor.d.ts.map +0 -1
  119. package/dist/editor/components/Editor.js.map +0 -1
  120. package/dist/editor/components/EditorContent.d.ts.map +0 -1
  121. package/dist/editor/components/EditorContent.js.map +0 -1
  122. package/dist/editor/components/FpsCounter.d.ts.map +0 -1
  123. package/dist/editor/components/FpsCounter.js.map +0 -1
  124. package/dist/editor/components/FramePersistor.d.ts.map +0 -1
  125. package/dist/editor/components/FramePersistor.js.map +0 -1
  126. package/dist/editor/components/GlobalKeybindings.d.ts.map +0 -1
  127. package/dist/editor/components/GlobalKeybindings.js.map +0 -1
  128. package/dist/editor/components/KeyboardShortcutsModal.d.ts.map +0 -1
  129. package/dist/editor/components/KeyboardShortcutsModal.js.map +0 -1
  130. package/dist/editor/components/LoadingIndicator.d.ts.map +0 -1
  131. package/dist/editor/components/LoadingIndicator.js.map +0 -1
  132. package/dist/editor/components/LoopToggle.d.ts.map +0 -1
  133. package/dist/editor/components/LoopToggle.js.map +0 -1
  134. package/dist/editor/components/Menu/MenuDivider.d.ts.map +0 -1
  135. package/dist/editor/components/Menu/MenuDivider.js.map +0 -1
  136. package/dist/editor/components/Menu/MenuItem.d.ts.map +0 -1
  137. package/dist/editor/components/Menu/MenuItem.js.map +0 -1
  138. package/dist/editor/components/Menu/MenuSubItem.d.ts.map +0 -1
  139. package/dist/editor/components/Menu/MenuSubItem.js.map +0 -1
  140. package/dist/editor/components/Menu/SubMenu.d.ts.map +0 -1
  141. package/dist/editor/components/Menu/SubMenu.js.map +0 -1
  142. package/dist/editor/components/Menu/portals.d.ts.map +0 -1
  143. package/dist/editor/components/Menu/portals.js.map +0 -1
  144. package/dist/editor/components/Menu/styles.d.ts.map +0 -1
  145. package/dist/editor/components/Menu/styles.js.map +0 -1
  146. package/dist/editor/components/MenuToolbar.d.ts.map +0 -1
  147. package/dist/editor/components/MenuToolbar.js.map +0 -1
  148. package/dist/editor/components/ModalContainer.d.ts.map +0 -1
  149. package/dist/editor/components/ModalContainer.js.map +0 -1
  150. package/dist/editor/components/ModalHeader.d.ts.map +0 -1
  151. package/dist/editor/components/ModalHeader.js.map +0 -1
  152. package/dist/editor/components/MuteToggle.d.ts.map +0 -1
  153. package/dist/editor/components/MuteToggle.js.map +0 -1
  154. package/dist/editor/components/NewComposition/CancelButton.d.ts.map +0 -1
  155. package/dist/editor/components/NewComposition/CancelButton.js.map +0 -1
  156. package/dist/editor/components/NewComposition/ComboBox.d.ts.map +0 -1
  157. package/dist/editor/components/NewComposition/ComboBox.js.map +0 -1
  158. package/dist/editor/components/NewComposition/CopyHint.d.ts.map +0 -1
  159. package/dist/editor/components/NewComposition/CopyHint.js.map +0 -1
  160. package/dist/editor/components/NewComposition/InputDragger.d.ts.map +0 -1
  161. package/dist/editor/components/NewComposition/InputDragger.js.map +0 -1
  162. package/dist/editor/components/NewComposition/MenuContent.d.ts.map +0 -1
  163. package/dist/editor/components/NewComposition/MenuContent.js.map +0 -1
  164. package/dist/editor/components/NewComposition/NewCompAspectRatio.d.ts.map +0 -1
  165. package/dist/editor/components/NewComposition/NewCompAspectRatio.js.map +0 -1
  166. package/dist/editor/components/NewComposition/NewCompCode.d.ts.map +0 -1
  167. package/dist/editor/components/NewComposition/NewCompCode.js.map +0 -1
  168. package/dist/editor/components/NewComposition/NewCompDuration.d.ts.map +0 -1
  169. package/dist/editor/components/NewComposition/NewCompDuration.js.map +0 -1
  170. package/dist/editor/components/NewComposition/NewComposition.d.ts.map +0 -1
  171. package/dist/editor/components/NewComposition/NewComposition.js.map +0 -1
  172. package/dist/editor/components/NewComposition/RemInput.d.ts.map +0 -1
  173. package/dist/editor/components/NewComposition/RemInput.js.map +0 -1
  174. package/dist/editor/components/NewComposition/ToggleAspectRatio.d.ts.map +0 -1
  175. package/dist/editor/components/NewComposition/ToggleAspectRatio.js.map +0 -1
  176. package/dist/editor/components/NewComposition/ValidationMessage.d.ts.map +0 -1
  177. package/dist/editor/components/NewComposition/ValidationMessage.js.map +0 -1
  178. package/dist/editor/components/NewComposition/new-comp-layout.d.ts.map +0 -1
  179. package/dist/editor/components/NewComposition/new-comp-layout.js.map +0 -1
  180. package/dist/editor/components/NewComposition/render-aspect-ratio.d.ts.map +0 -1
  181. package/dist/editor/components/NewComposition/render-aspect-ratio.js.map +0 -1
  182. package/dist/editor/components/PlayPause.d.ts.map +0 -1
  183. package/dist/editor/components/PlayPause.js.map +0 -1
  184. package/dist/editor/components/PlaybackKeyboardShortcutsManager.d.ts.map +0 -1
  185. package/dist/editor/components/PlaybackKeyboardShortcutsManager.js.map +0 -1
  186. package/dist/editor/components/PlaybackRatePersistor.d.ts.map +0 -1
  187. package/dist/editor/components/PlaybackRatePersistor.js.map +0 -1
  188. package/dist/editor/components/PlaybackRateSelector.d.ts.map +0 -1
  189. package/dist/editor/components/PlaybackRateSelector.js.map +0 -1
  190. package/dist/editor/components/Preview.d.ts.map +0 -1
  191. package/dist/editor/components/Preview.js.map +0 -1
  192. package/dist/editor/components/PreviewToolbar.d.ts.map +0 -1
  193. package/dist/editor/components/PreviewToolbar.js.map +0 -1
  194. package/dist/editor/components/RichTimelineToggle.d.ts.map +0 -1
  195. package/dist/editor/components/RichTimelineToggle.js.map +0 -1
  196. package/dist/editor/components/SizeSelector.d.ts.map +0 -1
  197. package/dist/editor/components/SizeSelector.js.map +0 -1
  198. package/dist/editor/components/Splitter/SplitterContainer.d.ts.map +0 -1
  199. package/dist/editor/components/Splitter/SplitterContainer.js.map +0 -1
  200. package/dist/editor/components/Splitter/SplitterContext.d.ts.map +0 -1
  201. package/dist/editor/components/Splitter/SplitterContext.js.map +0 -1
  202. package/dist/editor/components/Splitter/SplitterElement.d.ts.map +0 -1
  203. package/dist/editor/components/Splitter/SplitterElement.js.map +0 -1
  204. package/dist/editor/components/Splitter/SplitterHandle.d.ts.map +0 -1
  205. package/dist/editor/components/Splitter/SplitterHandle.js.map +0 -1
  206. package/dist/editor/components/Thumbnail.d.ts.map +0 -1
  207. package/dist/editor/components/Thumbnail.js.map +0 -1
  208. package/dist/editor/components/TimeValue.d.ts.map +0 -1
  209. package/dist/editor/components/TimeValue.js.map +0 -1
  210. package/dist/editor/components/Timeline/LoopedIndicator.d.ts.map +0 -1
  211. package/dist/editor/components/Timeline/LoopedIndicator.js.map +0 -1
  212. package/dist/editor/components/Timeline/LoopedTimelineIndicators.d.ts.map +0 -1
  213. package/dist/editor/components/Timeline/LoopedTimelineIndicators.js.map +0 -1
  214. package/dist/editor/components/Timeline/MaxTimelineTracks.d.ts.map +0 -1
  215. package/dist/editor/components/Timeline/MaxTimelineTracks.js.map +0 -1
  216. package/dist/editor/components/Timeline/Timeline.d.ts.map +0 -1
  217. package/dist/editor/components/Timeline/Timeline.js.map +0 -1
  218. package/dist/editor/components/Timeline/TimelineCollapseToggle.d.ts.map +0 -1
  219. package/dist/editor/components/Timeline/TimelineCollapseToggle.js.map +0 -1
  220. package/dist/editor/components/Timeline/TimelineDragHandler.d.ts.map +0 -1
  221. package/dist/editor/components/Timeline/TimelineDragHandler.js.map +0 -1
  222. package/dist/editor/components/Timeline/TimelineInOutPointer.d.ts.map +0 -1
  223. package/dist/editor/components/Timeline/TimelineInOutPointer.js.map +0 -1
  224. package/dist/editor/components/Timeline/TimelineInOutPointerHandle.d.ts.map +0 -1
  225. package/dist/editor/components/Timeline/TimelineInOutPointerHandle.js.map +0 -1
  226. package/dist/editor/components/Timeline/TimelineList.d.ts.map +0 -1
  227. package/dist/editor/components/Timeline/TimelineList.js.map +0 -1
  228. package/dist/editor/components/Timeline/TimelineListItem.d.ts.map +0 -1
  229. package/dist/editor/components/Timeline/TimelineListItem.js.map +0 -1
  230. package/dist/editor/components/Timeline/TimelineSequence.d.ts.map +0 -1
  231. package/dist/editor/components/Timeline/TimelineSequence.js.map +0 -1
  232. package/dist/editor/components/Timeline/TimelineSequenceFrame.d.ts.map +0 -1
  233. package/dist/editor/components/Timeline/TimelineSequenceFrame.js.map +0 -1
  234. package/dist/editor/components/Timeline/TimelineSlider.d.ts.map +0 -1
  235. package/dist/editor/components/Timeline/TimelineSlider.js.map +0 -1
  236. package/dist/editor/components/Timeline/TimelineSliderHandle.d.ts.map +0 -1
  237. package/dist/editor/components/Timeline/TimelineSliderHandle.js.map +0 -1
  238. package/dist/editor/components/Timeline/TimelineTracks.d.ts.map +0 -1
  239. package/dist/editor/components/Timeline/TimelineTracks.js.map +0 -1
  240. package/dist/editor/components/Timeline/TimelineVideoInfo.d.ts.map +0 -1
  241. package/dist/editor/components/Timeline/TimelineVideoInfo.js.map +0 -1
  242. package/dist/editor/components/Timeline/is-collapsed.d.ts.map +0 -1
  243. package/dist/editor/components/Timeline/is-collapsed.js.map +0 -1
  244. package/dist/editor/components/Timeline/timeline-refs.d.ts.map +0 -1
  245. package/dist/editor/components/Timeline/timeline-refs.js.map +0 -1
  246. package/dist/editor/components/Timeline/timeline-state-reducer.d.ts.map +0 -1
  247. package/dist/editor/components/Timeline/timeline-state-reducer.js.map +0 -1
  248. package/dist/editor/components/TimelineInOutToggle.d.ts.map +0 -1
  249. package/dist/editor/components/TimelineInOutToggle.js.map +0 -1
  250. package/dist/editor/components/TopPanel.d.ts.map +0 -1
  251. package/dist/editor/components/TopPanel.js.map +0 -1
  252. package/dist/editor/components/UpdateCheck.d.ts.map +0 -1
  253. package/dist/editor/components/UpdateCheck.js.map +0 -1
  254. package/dist/editor/components/UpdateModal/UpdateModal.d.ts.map +0 -1
  255. package/dist/editor/components/UpdateModal/UpdateModal.js.map +0 -1
  256. package/dist/editor/components/layout.d.ts.map +0 -1
  257. package/dist/editor/components/layout.js.map +0 -1
  258. package/dist/editor/helpers/calculate-timeline.d.ts.map +0 -1
  259. package/dist/editor/helpers/calculate-timeline.js.map +0 -1
  260. package/dist/editor/helpers/checkerboard-background.d.ts.map +0 -1
  261. package/dist/editor/helpers/checkerboard-background.js.map +0 -1
  262. package/dist/editor/helpers/colors.d.ts.map +0 -1
  263. package/dist/editor/helpers/colors.js.map +0 -1
  264. package/dist/editor/helpers/copy-text.d.ts.map +0 -1
  265. package/dist/editor/helpers/copy-text.js.map +0 -1
  266. package/dist/editor/helpers/create-folder-tree.d.ts.map +0 -1
  267. package/dist/editor/helpers/create-folder-tree.js.map +0 -1
  268. package/dist/editor/helpers/get-left-of-timeline-slider.d.ts.map +0 -1
  269. package/dist/editor/helpers/get-left-of-timeline-slider.js.map +0 -1
  270. package/dist/editor/helpers/get-sequence-visible-range.d.ts.map +0 -1
  271. package/dist/editor/helpers/get-sequence-visible-range.js.map +0 -1
  272. package/dist/editor/helpers/get-timeline-nestedness.d.ts.map +0 -1
  273. package/dist/editor/helpers/get-timeline-nestedness.js.map +0 -1
  274. package/dist/editor/helpers/get-timeline-sequence-hash.d.ts.map +0 -1
  275. package/dist/editor/helpers/get-timeline-sequence-hash.js.map +0 -1
  276. package/dist/editor/helpers/get-timeline-sequence-layout.d.ts.map +0 -1
  277. package/dist/editor/helpers/get-timeline-sequence-layout.js.map +0 -1
  278. package/dist/editor/helpers/get-timeline-sequence-sort-key.d.ts.map +0 -1
  279. package/dist/editor/helpers/get-timeline-sequence-sort-key.js.map +0 -1
  280. package/dist/editor/helpers/is-composition-still.d.ts.map +0 -1
  281. package/dist/editor/helpers/is-composition-still.js.map +0 -1
  282. package/dist/editor/helpers/is-current-selected-still.d.ts.map +0 -1
  283. package/dist/editor/helpers/is-current-selected-still.js.map +0 -1
  284. package/dist/editor/helpers/noop.d.ts.map +0 -1
  285. package/dist/editor/helpers/noop.js.map +0 -1
  286. package/dist/editor/helpers/persist-open-folders.d.ts.map +0 -1
  287. package/dist/editor/helpers/persist-open-folders.js.map +0 -1
  288. package/dist/editor/helpers/timeline-layout.d.ts.map +0 -1
  289. package/dist/editor/helpers/timeline-layout.js.map +0 -1
  290. package/dist/editor/helpers/use-keybinding.d.ts.map +0 -1
  291. package/dist/editor/helpers/use-keybinding.js.map +0 -1
  292. package/dist/editor/helpers/validate-new-comp-data.d.ts.map +0 -1
  293. package/dist/editor/helpers/validate-new-comp-data.js.map +0 -1
  294. package/dist/editor/icons/Checkmark.d.ts.map +0 -1
  295. package/dist/editor/icons/Checkmark.js.map +0 -1
  296. package/dist/editor/icons/caret.d.ts.map +0 -1
  297. package/dist/editor/icons/caret.js.map +0 -1
  298. package/dist/editor/icons/film.d.ts.map +0 -1
  299. package/dist/editor/icons/film.js.map +0 -1
  300. package/dist/editor/icons/folder.d.ts.map +0 -1
  301. package/dist/editor/icons/folder.js.map +0 -1
  302. package/dist/editor/icons/keys.d.ts.map +0 -1
  303. package/dist/editor/icons/keys.js.map +0 -1
  304. package/dist/editor/icons/lock.d.ts.map +0 -1
  305. package/dist/editor/icons/lock.js.map +0 -1
  306. package/dist/editor/icons/media-volume.d.ts.map +0 -1
  307. package/dist/editor/icons/media-volume.js.map +0 -1
  308. package/dist/editor/icons/pause.d.ts.map +0 -1
  309. package/dist/editor/icons/pause.js.map +0 -1
  310. package/dist/editor/icons/play.d.ts.map +0 -1
  311. package/dist/editor/icons/play.js.map +0 -1
  312. package/dist/editor/icons/step-back.d.ts.map +0 -1
  313. package/dist/editor/icons/step-back.js.map +0 -1
  314. package/dist/editor/icons/step-forward.d.ts.map +0 -1
  315. package/dist/editor/icons/step-forward.js.map +0 -1
  316. package/dist/editor/icons/still.d.ts.map +0 -1
  317. package/dist/editor/icons/still.js.map +0 -1
  318. package/dist/editor/icons/timeline.d.ts.map +0 -1
  319. package/dist/editor/icons/timeline.js.map +0 -1
  320. package/dist/editor/icons/timelineInOutPointer.d.ts.map +0 -1
  321. package/dist/editor/icons/timelineInOutPointer.js.map +0 -1
  322. package/dist/editor/state/aspect-ratio-locked.d.ts.map +0 -1
  323. package/dist/editor/state/aspect-ratio-locked.js.map +0 -1
  324. package/dist/editor/state/checkerboard.d.ts.map +0 -1
  325. package/dist/editor/state/checkerboard.js.map +0 -1
  326. package/dist/editor/state/highest-z-index.d.ts.map +0 -1
  327. package/dist/editor/state/highest-z-index.js.map +0 -1
  328. package/dist/editor/state/input-dragger-click-lock.d.ts.map +0 -1
  329. package/dist/editor/state/input-dragger-click-lock.js.map +0 -1
  330. package/dist/editor/state/keybindings.d.ts.map +0 -1
  331. package/dist/editor/state/keybindings.js.map +0 -1
  332. package/dist/editor/state/loop.d.ts.map +0 -1
  333. package/dist/editor/state/loop.js.map +0 -1
  334. package/dist/editor/state/marks.d.ts.map +0 -1
  335. package/dist/editor/state/marks.js.map +0 -1
  336. package/dist/editor/state/modals.d.ts.map +0 -1
  337. package/dist/editor/state/modals.js.map +0 -1
  338. package/dist/editor/state/mute.d.ts.map +0 -1
  339. package/dist/editor/state/mute.js.map +0 -1
  340. package/dist/editor/state/playbackrate.d.ts.map +0 -1
  341. package/dist/editor/state/playbackrate.js.map +0 -1
  342. package/dist/editor/state/preview-size.d.ts.map +0 -1
  343. package/dist/editor/state/preview-size.js.map +0 -1
  344. package/dist/editor/state/render-frame.d.ts.map +0 -1
  345. package/dist/editor/state/render-frame.js.map +0 -1
  346. package/dist/editor/state/rich-timeline.d.ts.map +0 -1
  347. package/dist/editor/state/rich-timeline.js.map +0 -1
  348. package/dist/editor/state/timeline-ref.d.ts.map +0 -1
  349. package/dist/editor/state/timeline-ref.js.map +0 -1
  350. package/dist/editor/state/timeline.d.ts.map +0 -1
  351. package/dist/editor/state/timeline.js.map +0 -1
  352. package/dist/editor/state/z-index.d.ts.map +0 -1
  353. package/dist/editor/state/z-index.js.map +0 -1
  354. package/dist/get-cli-options.d.ts.map +0 -1
  355. package/dist/get-cli-options.js.map +0 -1
  356. package/dist/get-composition-id.d.ts.map +0 -1
  357. package/dist/get-composition-id.js.map +0 -1
  358. package/dist/get-config-file-name.d.ts.map +0 -1
  359. package/dist/get-config-file-name.js.map +0 -1
  360. package/dist/get-env.d.ts.map +0 -1
  361. package/dist/get-env.js.map +0 -1
  362. package/dist/get-filename.d.ts.map +0 -1
  363. package/dist/get-filename.js.map +0 -1
  364. package/dist/get-input-props.d.ts.map +0 -1
  365. package/dist/get-input-props.js.map +0 -1
  366. package/dist/handle-common-errors.d.ts.map +0 -1
  367. package/dist/handle-common-errors.js.map +0 -1
  368. package/dist/image-formats.d.ts.map +0 -1
  369. package/dist/image-formats.js.map +0 -1
  370. package/dist/index.d.ts.map +0 -1
  371. package/dist/index.js.map +0 -1
  372. package/dist/initialize-render-cli.d.ts.map +0 -1
  373. package/dist/initialize-render-cli.js.map +0 -1
  374. package/dist/is-javascript.d.ts.map +0 -1
  375. package/dist/is-javascript.js.map +0 -1
  376. package/dist/lambda-command.d.ts.map +0 -1
  377. package/dist/lambda-command.js.map +0 -1
  378. package/dist/load-config.d.ts.map +0 -1
  379. package/dist/load-config.js.map +0 -1
  380. package/dist/log.d.ts.map +0 -1
  381. package/dist/log.js.map +0 -1
  382. package/dist/make-progress-bar.d.ts.map +0 -1
  383. package/dist/make-progress-bar.js.map +0 -1
  384. package/dist/parse-command-line.d.ts.map +0 -1
  385. package/dist/parse-command-line.js.map +0 -1
  386. package/dist/preview.d.ts.map +0 -1
  387. package/dist/preview.js.map +0 -1
  388. package/dist/previewEntry.d.ts.map +0 -1
  389. package/dist/previewEntry.js.map +0 -1
  390. package/dist/print-error.d.ts.map +0 -1
  391. package/dist/print-error.js.map +0 -1
  392. package/dist/print-help.d.ts.map +0 -1
  393. package/dist/print-help.js.map +0 -1
  394. package/dist/progress-bar.d.ts.map +0 -1
  395. package/dist/progress-bar.js.map +0 -1
  396. package/dist/render.d.ts.map +0 -1
  397. package/dist/render.js.map +0 -1
  398. package/dist/resolve-from.d.ts.map +0 -1
  399. package/dist/resolve-from.js.map +0 -1
  400. package/dist/setup-cache.d.ts.map +0 -1
  401. package/dist/setup-cache.js.map +0 -1
  402. package/dist/step.d.ts.map +0 -1
  403. package/dist/step.js.map +0 -1
  404. package/dist/still.d.ts.map +0 -1
  405. package/dist/still.js.map +0 -1
  406. package/dist/upgrade.d.ts.map +0 -1
  407. package/dist/upgrade.js.map +0 -1
  408. package/dist/user-passed-output-location.d.ts.map +0 -1
  409. package/dist/user-passed-output-location.js.map +0 -1
  410. package/dist/validate-ffmpeg-version.d.ts.map +0 -1
  411. package/dist/validate-ffmpeg-version.js.map +0 -1
  412. package/dist/versions.d.ts.map +0 -1
  413. package/dist/versions.js.map +0 -1
  414. package/dist/warn-about-ffmpeg-version.d.ts.map +0 -1
  415. package/dist/warn-about-ffmpeg-version.js.map +0 -1
@@ -0,0 +1,67 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ErrorMessage = void 0;
4
+ const jsx_runtime_1 = require("react/jsx-runtime");
5
+ const player_1 = require("@remotion/player");
6
+ const react_1 = require("react");
7
+ const colors_1 = require("../../../editor/helpers/colors");
8
+ const carets_1 = require("./carets");
9
+ const fontSize = 24;
10
+ const lineHeight = 1.5;
11
+ const maxLines = 2;
12
+ const buttonSize = 32;
13
+ const maskImage = 'linear-gradient(to bottom, white 60%, transparent)';
14
+ const container = {
15
+ position: 'relative',
16
+ marginBottom: 15,
17
+ };
18
+ const messageContainer = {
19
+ fontSize,
20
+ lineHeight,
21
+ overflow: 'hidden',
22
+ };
23
+ const moreLine = {
24
+ width: '100%',
25
+ display: 'flex',
26
+ justifyContent: 'center',
27
+ position: 'absolute',
28
+ border: `1px solid ${colors_1.INPUT_BORDER_COLOR_HOVERED}`,
29
+ height: 0,
30
+ marginTop: 4,
31
+ };
32
+ const moreButton = {
33
+ height: buttonSize,
34
+ width: buttonSize,
35
+ borderRadius: buttonSize / 2,
36
+ backgroundColor: colors_1.INPUT_BACKGROUND,
37
+ border: `1px solid ${colors_1.INPUT_BORDER_COLOR_UNHOVERED}`,
38
+ marginTop: -buttonSize / 2,
39
+ display: 'flex',
40
+ justifyContent: 'center',
41
+ alignItems: 'center',
42
+ cursor: 'pointer',
43
+ color: 'white',
44
+ };
45
+ const ErrorMessage = ({ message }) => {
46
+ const [expanded, setExpanded] = (0, react_1.useState)(false);
47
+ const ref = (0, react_1.useRef)(null);
48
+ const size = player_1.PlayerInternals.useElementSize(ref, {
49
+ shouldApplyCssTransforms: false,
50
+ triggerOnWindowResize: true,
51
+ });
52
+ const errorLines = size ? size.height / (lineHeight * fontSize) : null;
53
+ const style = (0, react_1.useMemo)(() => {
54
+ const isExpanded = expanded || (errorLines !== null && errorLines <= maxLines);
55
+ return {
56
+ ...messageContainer,
57
+ maxHeight: isExpanded ? undefined : fontSize * lineHeight * maxLines,
58
+ maskImage: isExpanded ? undefined : maskImage,
59
+ WebkitMaskImage: isExpanded ? undefined : maskImage,
60
+ };
61
+ }, [errorLines, expanded]);
62
+ const toggle = (0, react_1.useCallback)(() => {
63
+ setExpanded((e) => !e);
64
+ }, []);
65
+ return ((0, jsx_runtime_1.jsxs)("div", { style: container, children: [(0, jsx_runtime_1.jsx)("div", { style: style, children: (0, jsx_runtime_1.jsx)("div", { ref: ref, children: message }) }), errorLines !== null && errorLines > maxLines ? ((0, jsx_runtime_1.jsx)("div", { style: moreLine, children: (0, jsx_runtime_1.jsx)("button", { type: "button", onClick: toggle, style: moreButton, children: (0, jsx_runtime_1.jsx)(carets_1.CaretDown, { invert: expanded }) }) })) : null] }));
66
+ };
67
+ exports.ErrorMessage = ErrorMessage;
@@ -4,6 +4,7 @@ exports.ErrorTitle = void 0;
4
4
  const jsx_runtime_1 = require("react/jsx-runtime");
5
5
  const react_overlay_1 = require("../react-overlay");
6
6
  const DismissButton_1 = require("./DismissButton");
7
+ const ErrorMessage_1 = require("./ErrorMessage");
7
8
  const Symbolicating_1 = require("./Symbolicating");
8
9
  const title = {
9
10
  marginBottom: 8,
@@ -14,17 +15,12 @@ const title = {
14
15
  const left = {
15
16
  flex: 1,
16
17
  paddingRight: 14,
17
- lineHeight: 1.5,
18
- whiteSpace: 'pre',
19
- fontSize: '1.5em',
20
18
  fontWeight: 'bold',
21
- overflowX: 'auto',
19
+ maxWidth: '100%',
22
20
  };
23
21
  const errName = {
24
- fontSize: '0.8em',
25
- background: 'linear-gradient(90deg,#4290f5,#42e9f5)',
26
- WebkitBackgroundClip: 'text',
27
- WebkitTextFillColor: 'transparent',
22
+ fontSize: 18,
23
+ color: '#4290f5',
28
24
  display: 'inline-block',
29
25
  };
30
26
  const row = {
@@ -36,6 +32,6 @@ const spacer = {
36
32
  width: 5,
37
33
  };
38
34
  const ErrorTitle = ({ name, message, symbolicating }) => {
39
- return ((0, jsx_runtime_1.jsxs)("div", { style: title, children: [(0, jsx_runtime_1.jsxs)("div", { style: left, children: [(0, jsx_runtime_1.jsx)("span", { style: errName, children: name }), (0, jsx_runtime_1.jsx)("br", {}), (0, jsx_runtime_1.jsxs)("div", { style: row, children: [symbolicating ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(Symbolicating_1.Symbolicating, {}), (0, jsx_runtime_1.jsx)("div", { style: spacer })] })) : null, (0, jsx_runtime_1.jsx)("div", { children: message })] })] }), (0, react_overlay_1.didUnmountReactApp)() ? null : (0, jsx_runtime_1.jsx)(DismissButton_1.DismissButton, {})] }));
35
+ return ((0, jsx_runtime_1.jsxs)("div", { style: title, children: [(0, jsx_runtime_1.jsxs)("div", { style: left, children: [(0, jsx_runtime_1.jsx)("span", { style: errName, children: name }), (0, jsx_runtime_1.jsx)("br", {}), (0, jsx_runtime_1.jsxs)("div", { style: row, children: [symbolicating ? ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [(0, jsx_runtime_1.jsx)(Symbolicating_1.Symbolicating, {}), (0, jsx_runtime_1.jsx)("div", { style: spacer })] })) : null, (0, jsx_runtime_1.jsx)(ErrorMessage_1.ErrorMessage, { message: message })] })] }), (0, react_overlay_1.didUnmountReactApp)() ? null : (0, jsx_runtime_1.jsx)(DismissButton_1.DismissButton, {})] }));
40
36
  };
41
37
  exports.ErrorTitle = ErrorTitle;
@@ -0,0 +1,6 @@
1
+ import React from 'react';
2
+ import type { THelpLink } from './get-help-link';
3
+ export declare const HelpLink: React.FC<{
4
+ canHaveKeyboardShortcuts: boolean;
5
+ link: THelpLink;
6
+ }>;
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.HelpLink = void 0;
4
+ const jsx_runtime_1 = require("react/jsx-runtime");
5
+ const react_1 = require("react");
6
+ const use_keybinding_1 = require("../../../editor/helpers/use-keybinding");
7
+ const Button_1 = require("./Button");
8
+ const ShortcutHint_1 = require("./ShortcutHint");
9
+ const HelpLink = ({ canHaveKeyboardShortcuts, link }) => {
10
+ const openLink = (0, react_1.useCallback)(() => {
11
+ window.open(link.url, '_blank');
12
+ }, [link]);
13
+ const { registerKeybinding } = (0, use_keybinding_1.useKeybinding)();
14
+ (0, react_1.useEffect)(() => {
15
+ if (!canHaveKeyboardShortcuts) {
16
+ return;
17
+ }
18
+ const onEditor = () => {
19
+ openLink();
20
+ };
21
+ const { unregister } = registerKeybinding({
22
+ event: 'keydown',
23
+ key: 'h',
24
+ callback: onEditor,
25
+ commandCtrlKey: true,
26
+ });
27
+ return () => unregister();
28
+ }, [canHaveKeyboardShortcuts, openLink, registerKeybinding]);
29
+ return ((0, jsx_runtime_1.jsxs)(Button_1.Button, { onClick: openLink, children: ["Help: ", '"', link.title, '"', canHaveKeyboardShortcuts ? ((0, jsx_runtime_1.jsx)(ShortcutHint_1.ShortcutHint, { keyToPress: "h", cmdOrCtrl: true })) : null] }));
30
+ };
31
+ exports.HelpLink = HelpLink;
@@ -2,4 +2,5 @@ import React from 'react';
2
2
  import type { SymbolicatedStackFrame } from '../react-overlay/utils/stack-frame';
3
3
  export declare const OpenInEditor: React.FC<{
4
4
  stack: SymbolicatedStackFrame;
5
+ canHaveKeyboardShortcuts: boolean;
5
6
  }>;
@@ -4,7 +4,9 @@ exports.OpenInEditor = void 0;
4
4
  const jsx_runtime_1 = require("react/jsx-runtime");
5
5
  /* eslint-disable no-console */
6
6
  const react_1 = require("react");
7
+ const use_keybinding_1 = require("../../../editor/helpers/use-keybinding");
7
8
  const Button_1 = require("./Button");
9
+ const ShortcutHint_1 = require("./ShortcutHint");
8
10
  const initialState = { type: 'idle' };
9
11
  const reducer = (state, action) => {
10
12
  if (action.type === 'start') {
@@ -29,9 +31,10 @@ const reducer = (state, action) => {
29
31
  }
30
32
  return state;
31
33
  };
32
- const OpenInEditor = ({ stack }) => {
34
+ const OpenInEditor = ({ stack, canHaveKeyboardShortcuts }) => {
33
35
  const isMounted = (0, react_1.useRef)(true);
34
36
  const [state, dispatch] = (0, react_1.useReducer)(reducer, initialState);
37
+ const { registerKeybinding } = (0, use_keybinding_1.useKeybinding)();
35
38
  const dispatchIfMounted = (0, react_1.useCallback)((payload) => {
36
39
  if (isMounted.current === false)
37
40
  return;
@@ -72,6 +75,21 @@ const OpenInEditor = ({ stack }) => {
72
75
  isMounted.current = false;
73
76
  };
74
77
  }, []);
78
+ (0, react_1.useEffect)(() => {
79
+ if (!canHaveKeyboardShortcuts) {
80
+ return;
81
+ }
82
+ const onEditor = () => {
83
+ openInBrowser();
84
+ };
85
+ const { unregister } = registerKeybinding({
86
+ event: 'keydown',
87
+ key: 'o',
88
+ callback: onEditor,
89
+ commandCtrlKey: true,
90
+ });
91
+ return () => unregister();
92
+ }, [canHaveKeyboardShortcuts, openInBrowser, registerKeybinding]);
75
93
  const label = (0, react_1.useMemo)(() => {
76
94
  switch (state.type) {
77
95
  case 'error':
@@ -86,6 +104,6 @@ const OpenInEditor = ({ stack }) => {
86
104
  throw new Error('invalid state');
87
105
  }
88
106
  }, [state.type]);
89
- return ((0, jsx_runtime_1.jsx)(Button_1.Button, { onClick: openInBrowser, disabled: state.type !== 'idle', children: label }));
107
+ return ((0, jsx_runtime_1.jsxs)(Button_1.Button, { onClick: openInBrowser, disabled: state.type !== 'idle', children: [label, canHaveKeyboardShortcuts ? ((0, jsx_runtime_1.jsx)(ShortcutHint_1.ShortcutHint, { keyToPress: "o", cmdOrCtrl: true })) : null] }));
90
108
  };
91
109
  exports.OpenInEditor = OpenInEditor;
@@ -4,6 +4,7 @@ exports.Overlay = exports.setErrorsRef = void 0;
4
4
  const jsx_runtime_1 = require("react/jsx-runtime");
5
5
  const react_1 = require("react");
6
6
  const remotion_1 = require("remotion");
7
+ const keybindings_1 = require("../../../editor/state/keybindings");
7
8
  const ErrorLoader_1 = require("./ErrorLoader");
8
9
  exports.setErrorsRef = (0, react_1.createRef)();
9
10
  const errorsAreTheSame = (first, second) => {
@@ -38,12 +39,12 @@ const Overlay = () => {
38
39
  if (errors.errors.length === 0) {
39
40
  return null;
40
41
  }
41
- return ((0, jsx_runtime_1.jsx)(remotion_1.AbsoluteFill, { style: {
42
- backgroundColor: BACKGROUND_COLOR,
43
- overflow: 'auto',
44
- color: 'white',
45
- }, children: errors.errors.map((err) => {
46
- return (0, jsx_runtime_1.jsx)(ErrorLoader_1.ErrorLoader, { error: err }, err.stack);
47
- }) }));
42
+ return ((0, jsx_runtime_1.jsx)(keybindings_1.KeybindingContextProvider, { children: (0, jsx_runtime_1.jsx)(remotion_1.AbsoluteFill, { style: {
43
+ backgroundColor: BACKGROUND_COLOR,
44
+ overflow: 'auto',
45
+ color: 'white',
46
+ }, children: errors.errors.map((err, i) => {
47
+ return ((0, jsx_runtime_1.jsx)(ErrorLoader_1.ErrorLoader, { keyboardShortcuts: i === 0, error: err }, err.stack));
48
+ }) }) }));
48
49
  };
49
50
  exports.Overlay = Overlay;
@@ -1,4 +1,5 @@
1
1
  import React from 'react';
2
2
  export declare const SearchGithubIssues: React.FC<{
3
3
  message: string;
4
+ canHaveKeyboardShortcuts: boolean;
4
5
  }>;
@@ -3,11 +3,29 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.SearchGithubIssues = void 0;
4
4
  const jsx_runtime_1 = require("react/jsx-runtime");
5
5
  const react_1 = require("react");
6
+ const use_keybinding_1 = require("../../../editor/helpers/use-keybinding");
6
7
  const Button_1 = require("./Button");
7
- const SearchGithubIssues = ({ message }) => {
8
+ const ShortcutHint_1 = require("./ShortcutHint");
9
+ const SearchGithubIssues = ({ message, canHaveKeyboardShortcuts }) => {
8
10
  const openInBrowser = (0, react_1.useCallback)(() => {
9
11
  window.open(`https://github.com/remotion-dev/remotion/issues?q=${encodeURIComponent(message)}`, '_blank');
10
12
  }, [message]);
11
- return (0, jsx_runtime_1.jsx)(Button_1.Button, { onClick: openInBrowser, children: "Search GitHub Issues" });
13
+ const { registerKeybinding } = (0, use_keybinding_1.useKeybinding)();
14
+ (0, react_1.useEffect)(() => {
15
+ if (!canHaveKeyboardShortcuts) {
16
+ return;
17
+ }
18
+ const onEditor = () => {
19
+ openInBrowser();
20
+ };
21
+ const { unregister } = registerKeybinding({
22
+ event: 'keydown',
23
+ key: 'g',
24
+ callback: onEditor,
25
+ commandCtrlKey: true,
26
+ });
27
+ return () => unregister();
28
+ }, [canHaveKeyboardShortcuts, openInBrowser, registerKeybinding]);
29
+ return ((0, jsx_runtime_1.jsxs)(Button_1.Button, { onClick: openInBrowser, children: ["Search GitHub Issues", ' ', canHaveKeyboardShortcuts ? ((0, jsx_runtime_1.jsx)(ShortcutHint_1.ShortcutHint, { keyToPress: "g", cmdOrCtrl: true })) : null] }));
12
30
  };
13
31
  exports.SearchGithubIssues = SearchGithubIssues;
@@ -0,0 +1,5 @@
1
+ import React from 'react';
2
+ export declare const ShortcutHint: React.FC<{
3
+ keyToPress: string;
4
+ cmdOrCtrl: boolean;
5
+ }>;
@@ -0,0 +1,16 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.ShortcutHint = void 0;
4
+ const jsx_runtime_1 = require("react/jsx-runtime");
5
+ const cmdOrCtrlCharacter = window.navigator.platform.startsWith('Mac')
6
+ ? '⌘'
7
+ : 'Ctrl';
8
+ const container = {
9
+ display: 'inline-block',
10
+ marginLeft: 6,
11
+ opacity: 0.6,
12
+ };
13
+ const ShortcutHint = ({ keyToPress, cmdOrCtrl }) => {
14
+ return ((0, jsx_runtime_1.jsxs)("span", { style: container, children: [cmdOrCtrl ? `${cmdOrCtrlCharacter}+` : '', keyToPress.toUpperCase()] }));
15
+ };
16
+ exports.ShortcutHint = ShortcutHint;
@@ -41,7 +41,7 @@ const StackElement = ({ s, lineNumberWidth, isFirst, defaultFunctionName }) => {
41
41
  const toggleCodeFrame = (0, react_1.useCallback)(() => {
42
42
  setShowCodeFrame((f) => !f);
43
43
  }, []);
44
- return ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsxs)("div", { style: header, children: [(0, jsx_runtime_1.jsxs)("div", { style: left, children: [(0, jsx_runtime_1.jsx)("div", { style: fnName, children: (_a = s.originalFunctionName) !== null && _a !== void 0 ? _a : defaultFunctionName }), s.originalFileName ? ((0, jsx_runtime_1.jsxs)("div", { style: location, children: [(0, format_location_1.formatLocation)(s.originalFileName), ":", s.originalLineNumber] })) : null] }), s.originalScriptCode && s.originalScriptCode.length > 0 ? ((0, jsx_runtime_1.jsx)(Button_1.Button, { onClick: toggleCodeFrame, children: showCodeFrame ? (0, jsx_runtime_1.jsx)(carets_1.CaretDown, {}) : (0, jsx_runtime_1.jsx)(carets_1.CaretRight, {}) })) : null] }), (0, jsx_runtime_1.jsx)("div", { children: s.originalScriptCode &&
44
+ return ((0, jsx_runtime_1.jsxs)("div", { children: [(0, jsx_runtime_1.jsxs)("div", { style: header, children: [(0, jsx_runtime_1.jsxs)("div", { style: left, children: [(0, jsx_runtime_1.jsx)("div", { style: fnName, children: (_a = s.originalFunctionName) !== null && _a !== void 0 ? _a : defaultFunctionName }), s.originalFileName ? ((0, jsx_runtime_1.jsxs)("div", { style: location, children: [(0, format_location_1.formatLocation)(s.originalFileName), ":", s.originalLineNumber] })) : null] }), s.originalScriptCode && s.originalScriptCode.length > 0 ? ((0, jsx_runtime_1.jsx)(Button_1.Button, { onClick: toggleCodeFrame, children: showCodeFrame ? (0, jsx_runtime_1.jsx)(carets_1.CaretDown, { invert: false }) : (0, jsx_runtime_1.jsx)(carets_1.CaretRight, {}) })) : null] }), (0, jsx_runtime_1.jsx)("div", { children: s.originalScriptCode &&
45
45
  s.originalScriptCode.length > 0 &&
46
46
  showCodeFrame ? ((0, jsx_runtime_1.jsx)(CodeFrame_1.CodeFrame, { lineNumberWidth: lineNumberWidth, source: s.originalScriptCode })) : null })] }));
47
47
  };
@@ -1,3 +1,5 @@
1
- /// <reference types="react" />
1
+ import React from 'react';
2
2
  export declare const CaretRight: () => JSX.Element;
3
- export declare const CaretDown: () => JSX.Element;
3
+ export declare const CaretDown: React.FC<{
4
+ invert: boolean;
5
+ }>;
@@ -6,7 +6,7 @@ const CaretRight = () => {
6
6
  return ((0, jsx_runtime_1.jsx)("svg", { style: { height: 20 }, "aria-hidden": "true", focusable: "false", role: "img", viewBox: "0 0 192 512", children: (0, jsx_runtime_1.jsx)("path", { fill: "currentColor", d: "M0 384.662V127.338c0-17.818 21.543-26.741 34.142-14.142l128.662 128.662c7.81 7.81 7.81 20.474 0 28.284L34.142 398.804C21.543 411.404 0 402.48 0 384.662z" }) }));
7
7
  };
8
8
  exports.CaretRight = CaretRight;
9
- const CaretDown = () => {
10
- return ((0, jsx_runtime_1.jsx)("svg", { "aria-hidden": "true", focusable: "false", role: "img", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 320 512", style: { height: 20 }, children: (0, jsx_runtime_1.jsx)("path", { fill: "currentColor", d: "M31.3 192h257.3c17.8 0 26.7 21.5 14.1 34.1L174.1 354.8c-7.8 7.8-20.5 7.8-28.3 0L17.2 226.1C4.6 213.5 13.5 192 31.3 192z" }) }));
9
+ const CaretDown = ({ invert }) => {
10
+ return ((0, jsx_runtime_1.jsx)("svg", { "aria-hidden": "true", focusable: "false", role: "img", xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 320 512", style: { height: 20, transform: invert ? `rotate(180deg)` : '' }, children: (0, jsx_runtime_1.jsx)("path", { fill: "currentColor", d: "M31.3 192h257.3c17.8 0 26.7 21.5 14.1 34.1L174.1 354.8c-7.8 7.8-20.5 7.8-28.3 0L17.2 226.1C4.6 213.5 13.5 192 31.3 192z" }) }));
11
11
  };
12
12
  exports.CaretDown = CaretDown;
@@ -0,0 +1,5 @@
1
+ export declare type THelpLink = {
2
+ url: string;
3
+ title: string;
4
+ };
5
+ export declare const getHelpLink: (message: string) => THelpLink | null;
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.getHelpLink = void 0;
4
+ const getHelpLink = (message) => {
5
+ if (message.includes('See https://www.remotion.dev/docs/the-fundamentals#defining-compositions')) {
6
+ return {
7
+ title: 'Defining compositions',
8
+ url: 'See https://www.remotion.dev/docs/the-fundamentals#defining-compositions',
9
+ };
10
+ }
11
+ if (message.includes('https://remotion.dev/docs/wrong-composition-mount')) {
12
+ return {
13
+ title: 'Wrongly mounted <Composition>',
14
+ url: 'https://remotion.dev/docs/wrong-composition-mount',
15
+ };
16
+ }
17
+ return null;
18
+ };
19
+ exports.getHelpLink = getHelpLink;
@@ -0,0 +1,39 @@
1
+ /**
2
+ * Source code is adapted from https://github.com/WebHotelier/webpack-fast-refresh#readme and rewritten in Typescript. This file is MIT licensed.
3
+ */
4
+ /**
5
+ * MIT License
6
+ *
7
+ * Copyright (c) Facebook, Inc. and its affiliates.
8
+ *
9
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
10
+ * of this software and associated documentation files (the "Software"), to deal
11
+ * in the Software without restriction, including without limitation the rights
12
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
13
+ * copies of the Software, and to permit persons to whom the Software is
14
+ * furnished to do so, subject to the following conditions:
15
+ *
16
+ * The above copyright notice and this permission notice shall be included in all
17
+ * copies or substantial portions of the Software.
18
+ *
19
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
22
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
23
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
24
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
25
+ * SOFTWARE.
26
+ */
27
+ declare function registerExportsForReactRefresh(moduleExports: unknown, moduleID: unknown): void;
28
+ declare function isReactRefreshBoundary(moduleExports: unknown): boolean;
29
+ declare function shouldInvalidateReactRefreshBoundary(prevExports: unknown, nextExports: unknown): boolean;
30
+ declare function getRefreshBoundarySignature(moduleExports: unknown): any[];
31
+ declare function scheduleUpdate(): void;
32
+ declare const _default: {
33
+ registerExportsForReactRefresh: typeof registerExportsForReactRefresh;
34
+ isReactRefreshBoundary: typeof isReactRefreshBoundary;
35
+ shouldInvalidateReactRefreshBoundary: typeof shouldInvalidateReactRefreshBoundary;
36
+ getRefreshBoundarySignature: typeof getRefreshBoundarySignature;
37
+ scheduleUpdate: typeof scheduleUpdate;
38
+ };
39
+ export default _default;
@@ -0,0 +1,145 @@
1
+ "use strict";
2
+ /**
3
+ * Source code is adapted from https://github.com/WebHotelier/webpack-fast-refresh#readme and rewritten in Typescript. This file is MIT licensed.
4
+ */
5
+ /**
6
+ * MIT License
7
+ *
8
+ * Copyright (c) Facebook, Inc. and its affiliates.
9
+ *
10
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
11
+ * of this software and associated documentation files (the "Software"), to deal
12
+ * in the Software without restriction, including without limitation the rights
13
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
14
+ * copies of the Software, and to permit persons to whom the Software is
15
+ * furnished to do so, subject to the following conditions:
16
+ *
17
+ * The above copyright notice and this permission notice shall be included in all
18
+ * copies or substantial portions of the Software.
19
+ *
20
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
21
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
22
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
23
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
24
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
25
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
26
+ * SOFTWARE.
27
+ */
28
+ Object.defineProperty(exports, "__esModule", { value: true });
29
+ // This file is copied from the Metro JavaScript bundler, with minor tweaks for
30
+ // webpack compatibility.
31
+ //
32
+ // https://github.com/facebook/metro/blob/d6b9685c730d0d63577db40f41369157f28dfa3a/packages/metro/src/lib/polyfills/require.js
33
+ const RefreshRuntime = require('react-refresh/runtime');
34
+ function isSafeExport(key) {
35
+ return (key === '__esModule' ||
36
+ key === '__N_SSG' ||
37
+ key === '__N_SSP' ||
38
+ key === 'config');
39
+ }
40
+ function registerExportsForReactRefresh(moduleExports, moduleID) {
41
+ RefreshRuntime.register(moduleExports, moduleID + ' %exports%');
42
+ if (moduleExports === null ||
43
+ moduleExports === undefined ||
44
+ typeof moduleExports !== 'object') {
45
+ // Exit if we can't iterate over exports.
46
+ // (This is important for legacy environments.)
47
+ return;
48
+ }
49
+ for (const key in moduleExports) {
50
+ if (isSafeExport(key)) {
51
+ continue;
52
+ }
53
+ // @ts-expect-error
54
+ const exportValue = moduleExports[key];
55
+ const typeID = moduleID + ' %exports% ' + key;
56
+ RefreshRuntime.register(exportValue, typeID);
57
+ }
58
+ }
59
+ function isReactRefreshBoundary(moduleExports) {
60
+ if (RefreshRuntime.isLikelyComponentType(moduleExports)) {
61
+ return true;
62
+ }
63
+ if (moduleExports === null ||
64
+ moduleExports === undefined ||
65
+ typeof moduleExports !== 'object') {
66
+ // Exit if we can't iterate over exports.
67
+ return false;
68
+ }
69
+ let hasExports = false;
70
+ let areAllExportsComponents = true;
71
+ for (const key in moduleExports) {
72
+ hasExports = true;
73
+ if (isSafeExport(key)) {
74
+ continue;
75
+ }
76
+ // @ts-expect-error
77
+ const exportValue = moduleExports[key];
78
+ if (!RefreshRuntime.isLikelyComponentType(exportValue)) {
79
+ areAllExportsComponents = false;
80
+ }
81
+ }
82
+ return hasExports && areAllExportsComponents;
83
+ }
84
+ function shouldInvalidateReactRefreshBoundary(prevExports, nextExports) {
85
+ const prevSignature = getRefreshBoundarySignature(prevExports);
86
+ const nextSignature = getRefreshBoundarySignature(nextExports);
87
+ if (prevSignature.length !== nextSignature.length) {
88
+ return true;
89
+ }
90
+ for (let i = 0; i < nextSignature.length; i++) {
91
+ if (prevSignature[i] !== nextSignature[i]) {
92
+ return true;
93
+ }
94
+ }
95
+ return false;
96
+ }
97
+ function getRefreshBoundarySignature(moduleExports) {
98
+ const signature = [];
99
+ signature.push(RefreshRuntime.getFamilyByType(moduleExports));
100
+ if (moduleExports === null ||
101
+ moduleExports === undefined ||
102
+ typeof moduleExports !== 'object') {
103
+ // Exit if we can't iterate over exports.
104
+ // (This is important for legacy environments.)
105
+ return signature;
106
+ }
107
+ for (const key in moduleExports) {
108
+ if (isSafeExport(key)) {
109
+ continue;
110
+ }
111
+ // @ts-expect-error
112
+ const exportValue = moduleExports[key];
113
+ signature.push(key);
114
+ signature.push(RefreshRuntime.getFamilyByType(exportValue));
115
+ }
116
+ return signature;
117
+ }
118
+ function scheduleUpdate() {
119
+ var _a, _b;
120
+ const execute = () => {
121
+ try {
122
+ RefreshRuntime.performReactRefresh();
123
+ }
124
+ catch (err) {
125
+ console.warn('Warning: Failed to re-render. We will retry on the next Fast Refresh event.\n' +
126
+ err);
127
+ }
128
+ };
129
+ // Only trigger refresh if the webpack HMR state is idle
130
+ if (((_a = module.hot) === null || _a === void 0 ? void 0 : _a.status()) === 'idle') {
131
+ return;
132
+ }
133
+ (_b = module.hot) === null || _b === void 0 ? void 0 : _b.addStatusHandler((status) => {
134
+ if (status === 'idle') {
135
+ execute();
136
+ }
137
+ });
138
+ }
139
+ exports.default = {
140
+ registerExportsForReactRefresh,
141
+ isReactRefreshBoundary,
142
+ shouldInvalidateReactRefreshBoundary,
143
+ getRefreshBoundarySignature,
144
+ scheduleUpdate,
145
+ };
@@ -0,0 +1,30 @@
1
+ /**
2
+ * Source code is adapted from https://github.com/WebHotelier/webpack-fast-refresh#readme and rewritten in Typescript. This file is MIT licensed.
3
+ */
4
+ /**
5
+ * The MIT License (MIT)
6
+ *
7
+ * Copyright (c) 2020 Vercel, Inc.
8
+ *
9
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
10
+ * of this software and associated documentation files (the "Software"), to deal
11
+ * in the Software without restriction, including without limitation the rights
12
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
13
+ * copies of the Software, and to permit persons to whom the Software is
14
+ * furnished to do so, subject to the following conditions:
15
+ *
16
+ * The above copyright notice and this permission notice shall be included in all
17
+ * copies or substantial portions of the Software.
18
+ *
19
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
22
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
23
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
24
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
25
+ * SOFTWARE.
26
+ */
27
+ import webpack from 'webpack';
28
+ export declare class ReactFreshWebpackPlugin {
29
+ apply(compiler: webpack.Compiler): void;
30
+ }