@remotion/promo-pages 4.0.475 → 4.0.477

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 (278) hide show
  1. package/dist/Homepage.js +1397 -949
  2. package/dist/cn.d.ts +2 -0
  3. package/dist/cn.js +5 -0
  4. package/dist/components/3DEngine/ButtonDemo.d.ts +2 -0
  5. package/dist/components/3DEngine/ButtonDemo.js +43 -0
  6. package/dist/components/3DEngine/Faces.d.ts +5 -0
  7. package/dist/components/3DEngine/Faces.js +7 -0
  8. package/dist/components/3DEngine/Outer.d.ts +8 -0
  9. package/dist/components/3DEngine/Outer.js +56 -0
  10. package/dist/components/3DEngine/Switch.d.ts +4 -0
  11. package/dist/components/3DEngine/Switch.js +4 -0
  12. package/dist/components/3DEngine/get-child-node-from.d.ts +1 -0
  13. package/dist/components/3DEngine/get-child-node-from.js +14 -0
  14. package/dist/components/3DEngine/hover-transforms.d.ts +9 -0
  15. package/dist/components/3DEngine/hover-transforms.js +177 -0
  16. package/dist/components/BackButton.d.ts +6 -0
  17. package/dist/components/BackButton.js +9 -0
  18. package/dist/components/CommandCopyButton.d.ts +5 -0
  19. package/dist/components/CommandCopyButton.js +4 -0
  20. package/dist/components/Homepage.d.ts +6 -0
  21. package/dist/components/Homepage.js +20 -0
  22. package/dist/components/ManageTeamMembers.d.ts +2 -0
  23. package/dist/components/ManageTeamMembers.js +42 -0
  24. package/dist/components/Spinner.d.ts +3 -0
  25. package/dist/components/Spinner.js +4 -0
  26. package/dist/components/TeamPicture.d.ts +1 -0
  27. package/dist/components/TeamPicture.js +4 -0
  28. package/dist/components/design.d.ts +1 -0
  29. package/dist/components/design.js +33 -0
  30. package/dist/components/experts/ExpertsPage.d.ts +11 -0
  31. package/dist/components/experts/ExpertsPage.js +50 -0
  32. package/dist/components/experts/experts-data.d.ts +19 -0
  33. package/dist/components/experts/experts-data.js +391 -0
  34. package/dist/components/experts/experts-icons.d.ts +8 -0
  35. package/dist/components/experts/experts-icons.js +42 -0
  36. package/dist/components/experts.d.ts +3 -0
  37. package/dist/components/experts.js +2 -0
  38. package/dist/components/homepage/AutomationsSection.d.ts +3 -0
  39. package/dist/components/homepage/AutomationsSection.js +85 -0
  40. package/dist/components/homepage/BackgroundAnimation.d.ts +2 -0
  41. package/dist/components/homepage/BackgroundAnimation.js +66 -0
  42. package/dist/components/homepage/ChooseTemplate.d.ts +2 -0
  43. package/dist/components/homepage/ChooseTemplate.js +25 -0
  44. package/dist/components/homepage/CommunityStats.d.ts +3 -0
  45. package/dist/components/homepage/CommunityStats.js +6 -0
  46. package/dist/components/homepage/CommunityStatsItems.d.ts +7 -0
  47. package/dist/components/homepage/CommunityStatsItems.js +58 -0
  48. package/dist/components/homepage/Demo/Card.d.ts +15 -0
  49. package/dist/components/homepage/Demo/Card.js +174 -0
  50. package/dist/components/homepage/Demo/Cards.d.ts +15 -0
  51. package/dist/components/homepage/Demo/Cards.js +57 -0
  52. package/dist/components/homepage/Demo/Comp.d.ts +38 -0
  53. package/dist/components/homepage/Demo/Comp.js +72 -0
  54. package/dist/components/homepage/Demo/CurrentCountry.d.ts +9 -0
  55. package/dist/components/homepage/Demo/CurrentCountry.js +48 -0
  56. package/dist/components/homepage/Demo/DemoError.d.ts +2 -0
  57. package/dist/components/homepage/Demo/DemoError.js +10 -0
  58. package/dist/components/homepage/Demo/DemoErrorIcon.d.ts +2 -0
  59. package/dist/components/homepage/Demo/DemoErrorIcon.js +16 -0
  60. package/dist/components/homepage/Demo/DemoRender.d.ts +33 -0
  61. package/dist/components/homepage/Demo/DemoRender.js +107 -0
  62. package/dist/components/homepage/Demo/DigitWheel.d.ts +9 -0
  63. package/dist/components/homepage/Demo/DigitWheel.js +94 -0
  64. package/dist/components/homepage/Demo/DisplayedEmoji.d.ts +5 -0
  65. package/dist/components/homepage/Demo/DisplayedEmoji.js +59 -0
  66. package/dist/components/homepage/Demo/DoneCheckmark.d.ts +2 -0
  67. package/dist/components/homepage/Demo/DoneCheckmark.js +20 -0
  68. package/dist/components/homepage/Demo/DownloadNudge.d.ts +2 -0
  69. package/dist/components/homepage/Demo/DownloadNudge.js +27 -0
  70. package/dist/components/homepage/Demo/DragAndDropNudge.d.ts +3 -0
  71. package/dist/components/homepage/Demo/DragAndDropNudge.js +26 -0
  72. package/dist/components/homepage/Demo/EmojiCard.d.ts +10 -0
  73. package/dist/components/homepage/Demo/EmojiCard.js +120 -0
  74. package/dist/components/homepage/Demo/Minus.d.ts +5 -0
  75. package/dist/components/homepage/Demo/Minus.js +11 -0
  76. package/dist/components/homepage/Demo/PlayPauseButton.d.ts +5 -0
  77. package/dist/components/homepage/Demo/PlayPauseButton.js +47 -0
  78. package/dist/components/homepage/Demo/PlayerControls.d.ts +8 -0
  79. package/dist/components/homepage/Demo/PlayerControls.js +15 -0
  80. package/dist/components/homepage/Demo/PlayerSeekBar.d.ts +11 -0
  81. package/dist/components/homepage/Demo/PlayerSeekBar.js +216 -0
  82. package/dist/components/homepage/Demo/PlayerVolume.d.ts +5 -0
  83. package/dist/components/homepage/Demo/PlayerVolume.js +53 -0
  84. package/dist/components/homepage/Demo/Progress.d.ts +4 -0
  85. package/dist/components/homepage/Demo/Progress.js +14 -0
  86. package/dist/components/homepage/Demo/Spinner.d.ts +5 -0
  87. package/dist/components/homepage/Demo/Spinner.js +37 -0
  88. package/dist/components/homepage/Demo/Switcher.d.ts +6 -0
  89. package/dist/components/homepage/Demo/Switcher.js +25 -0
  90. package/dist/components/homepage/Demo/Temperature.d.ts +6 -0
  91. package/dist/components/homepage/Demo/Temperature.js +21 -0
  92. package/dist/components/homepage/Demo/TemperatureNumber.d.ts +5 -0
  93. package/dist/components/homepage/Demo/TemperatureNumber.js +36 -0
  94. package/dist/components/homepage/Demo/ThemeNudge.d.ts +3 -0
  95. package/dist/components/homepage/Demo/ThemeNudge.js +35 -0
  96. package/dist/components/homepage/Demo/TimeDisplay.d.ts +6 -0
  97. package/dist/components/homepage/Demo/TimeDisplay.js +27 -0
  98. package/dist/components/homepage/Demo/TrendingRepos.d.ts +6 -0
  99. package/dist/components/homepage/Demo/TrendingRepos.js +65 -0
  100. package/dist/components/homepage/Demo/icons.d.ts +10 -0
  101. package/dist/components/homepage/Demo/icons.js +22 -0
  102. package/dist/components/homepage/Demo/index.d.ts +2 -0
  103. package/dist/components/homepage/Demo/index.js +95 -0
  104. package/dist/components/homepage/Demo/math.d.ts +10 -0
  105. package/dist/components/homepage/Demo/math.js +29 -0
  106. package/dist/components/homepage/Demo/types.d.ts +6 -0
  107. package/dist/components/homepage/Demo/types.js +0 -0
  108. package/dist/components/homepage/EditorStarterSection.d.ts +3 -0
  109. package/dist/components/homepage/EditorStarterSection.js +8 -0
  110. package/dist/components/homepage/EvaluateRemotion.d.ts +3 -0
  111. package/dist/components/homepage/EvaluateRemotion.js +21 -0
  112. package/dist/components/homepage/FreePricing.d.ts +4 -0
  113. package/dist/components/homepage/FreePricing.js +133 -0
  114. package/dist/components/homepage/GetStartedStrip.d.ts +2 -0
  115. package/dist/components/homepage/GetStartedStrip.js +14 -0
  116. package/dist/components/homepage/GitHubButton.d.ts +2 -0
  117. package/dist/components/homepage/GitHubButton.js +7 -0
  118. package/dist/components/homepage/IconForTemplate.d.ts +6 -0
  119. package/dist/components/homepage/IconForTemplate.js +105 -0
  120. package/dist/components/homepage/IfYouKnowReact.d.ts +3 -0
  121. package/dist/components/homepage/IfYouKnowReact.js +23 -0
  122. package/dist/components/homepage/MoreTemplatesButton.d.ts +2 -0
  123. package/dist/components/homepage/MoreTemplatesButton.js +11 -0
  124. package/dist/components/homepage/MuxVideo.d.ts +7 -0
  125. package/dist/components/homepage/MuxVideo.js +45 -0
  126. package/dist/components/homepage/NewsletterButton.d.ts +2 -0
  127. package/dist/components/homepage/NewsletterButton.js +38 -0
  128. package/dist/components/homepage/ParameterizeAndEdit.d.ts +2 -0
  129. package/dist/components/homepage/ParameterizeAndEdit.js +22 -0
  130. package/dist/components/homepage/Pricing.d.ts +2 -0
  131. package/dist/components/homepage/Pricing.js +15 -0
  132. package/dist/components/homepage/PricingBulletPoint.d.ts +6 -0
  133. package/dist/components/homepage/PricingBulletPoint.js +19 -0
  134. package/dist/components/homepage/RealMp4Videos.d.ts +2 -0
  135. package/dist/components/homepage/RealMp4Videos.js +41 -0
  136. package/dist/components/homepage/Spacer.d.ts +2 -0
  137. package/dist/components/homepage/Spacer.js +4 -0
  138. package/dist/components/homepage/TemplateIcon.d.ts +5 -0
  139. package/dist/components/homepage/TemplateIcon.js +24 -0
  140. package/dist/components/homepage/TextInput.d.ts +7 -0
  141. package/dist/components/homepage/TextInput.js +34 -0
  142. package/dist/components/homepage/TrustedByBanner.d.ts +2 -0
  143. package/dist/components/homepage/TrustedByBanner.js +27 -0
  144. package/dist/components/homepage/VideoApps.d.ts +4 -0
  145. package/dist/components/homepage/VideoApps.js +72 -0
  146. package/dist/components/homepage/VideoAppsShowcase.d.ts +3 -0
  147. package/dist/components/homepage/VideoAppsShowcase.js +139 -0
  148. package/dist/components/homepage/VideoAppsTitle.d.ts +4 -0
  149. package/dist/components/homepage/VideoAppsTitle.js +4 -0
  150. package/dist/components/homepage/VideoPlayerWithControls.d.ts +20 -0
  151. package/dist/components/homepage/VideoPlayerWithControls.js +105 -0
  152. package/dist/components/homepage/WriteInReact.d.ts +2 -0
  153. package/dist/components/homepage/WriteInReact.js +10 -0
  154. package/dist/components/homepage/YouAreHere.d.ts +2 -0
  155. package/dist/components/homepage/YouAreHere.js +23 -0
  156. package/dist/components/homepage/layout/Button.d.ts +22 -0
  157. package/dist/components/homepage/layout/Button.js +30 -0
  158. package/dist/components/homepage/layout/colors.d.ts +13 -0
  159. package/dist/components/homepage/layout/colors.js +14 -0
  160. package/dist/components/homepage/layout/use-color-mode.d.ts +21 -0
  161. package/dist/components/homepage/layout/use-color-mode.js +22 -0
  162. package/dist/components/homepage/layout/use-el-size.d.ts +5 -0
  163. package/dist/components/homepage/layout/use-el-size.js +40 -0
  164. package/dist/components/homepage/layout/use-mobile-layout.d.ts +1 -0
  165. package/dist/components/homepage/layout/use-mobile-layout.js +6 -0
  166. package/dist/components/icons/blank.d.ts +3 -0
  167. package/dist/components/icons/blank.js +4 -0
  168. package/dist/components/icons/brain.d.ts +2 -0
  169. package/dist/components/icons/brain.js +4 -0
  170. package/dist/components/icons/clone.d.ts +2 -0
  171. package/dist/components/icons/clone.js +2 -0
  172. package/dist/components/icons/code-hike.d.ts +3 -0
  173. package/dist/components/icons/code-hike.js +4 -0
  174. package/dist/components/icons/cubes.d.ts +3 -0
  175. package/dist/components/icons/cubes.js +4 -0
  176. package/dist/components/icons/editor.d.ts +3 -0
  177. package/dist/components/icons/editor.js +4 -0
  178. package/dist/components/icons/electron.d.ts +4 -0
  179. package/dist/components/icons/electron.js +4 -0
  180. package/dist/components/icons/js.d.ts +3 -0
  181. package/dist/components/icons/js.js +4 -0
  182. package/dist/components/icons/music.d.ts +2 -0
  183. package/dist/components/icons/music.js +4 -0
  184. package/dist/components/icons/next.d.ts +4 -0
  185. package/dist/components/icons/next.js +4 -0
  186. package/dist/components/icons/overlay.d.ts +3 -0
  187. package/dist/components/icons/overlay.js +4 -0
  188. package/dist/components/icons/prompt-to-video.d.ts +2 -0
  189. package/dist/components/icons/prompt-to-video.js +4 -0
  190. package/dist/components/icons/recorder.d.ts +3 -0
  191. package/dist/components/icons/recorder.js +4 -0
  192. package/dist/components/icons/remix.d.ts +3 -0
  193. package/dist/components/icons/remix.js +4 -0
  194. package/dist/components/icons/render-server.d.ts +3 -0
  195. package/dist/components/icons/render-server.js +4 -0
  196. package/dist/components/icons/skia.d.ts +3 -0
  197. package/dist/components/icons/skia.js +4 -0
  198. package/dist/components/icons/stargazer.d.ts +3 -0
  199. package/dist/components/icons/stargazer.js +4 -0
  200. package/dist/components/icons/still.d.ts +3 -0
  201. package/dist/components/icons/still.js +4 -0
  202. package/dist/components/icons/tailwind.d.ts +3 -0
  203. package/dist/components/icons/tailwind.js +4 -0
  204. package/dist/components/icons/tiktok.d.ts +3 -0
  205. package/dist/components/icons/tiktok.js +4 -0
  206. package/dist/components/icons/timeline.d.ts +3 -0
  207. package/dist/components/icons/timeline.js +4 -0
  208. package/dist/components/icons/ts.d.ts +3 -0
  209. package/dist/components/icons/ts.js +4 -0
  210. package/dist/components/icons/undo.d.ts +3 -0
  211. package/dist/components/icons/undo.js +2 -0
  212. package/dist/components/icons/vercel.d.ts +4 -0
  213. package/dist/components/icons/vercel.js +4 -0
  214. package/dist/components/icons/waveform.d.ts +3 -0
  215. package/dist/components/icons/waveform.js +4 -0
  216. package/dist/components/prompts/CardLikeButton.d.ts +5 -0
  217. package/dist/components/prompts/CardLikeButton.js +49 -0
  218. package/dist/components/prompts/ClipboardIcon.d.ts +5 -0
  219. package/dist/components/prompts/ClipboardIcon.js +4 -0
  220. package/dist/components/prompts/CopyPromptButton.d.ts +4 -0
  221. package/dist/components/prompts/CopyPromptButton.js +13 -0
  222. package/dist/components/prompts/LikeButton.d.ts +5 -0
  223. package/dist/components/prompts/LikeButton.js +49 -0
  224. package/dist/components/prompts/MuxPlayer.d.ts +8 -0
  225. package/dist/components/prompts/MuxPlayer.js +21 -0
  226. package/dist/components/prompts/NewBackButton.d.ts +5 -0
  227. package/dist/components/prompts/NewBackButton.js +8 -0
  228. package/dist/components/prompts/Page.d.ts +8 -0
  229. package/dist/components/prompts/Page.js +7 -0
  230. package/dist/components/prompts/PromptsGallery.d.ts +7 -0
  231. package/dist/components/prompts/PromptsGallery.js +60 -0
  232. package/dist/components/prompts/PromptsShow.d.ts +5 -0
  233. package/dist/components/prompts/PromptsShow.js +17 -0
  234. package/dist/components/prompts/PromptsSubmit.d.ts +2 -0
  235. package/dist/components/prompts/PromptsSubmit.js +173 -0
  236. package/dist/components/prompts/config.d.ts +1 -0
  237. package/dist/components/prompts/config.js +1 -0
  238. package/dist/components/prompts/prompt-helpers.d.ts +8 -0
  239. package/dist/components/prompts/prompt-helpers.js +76 -0
  240. package/dist/components/prompts/prompt-types.d.ts +14 -0
  241. package/dist/components/prompts/prompt-types.js +0 -0
  242. package/dist/components/prompts/use-heart-animation.d.ts +5 -0
  243. package/dist/components/prompts/use-heart-animation.js +29 -0
  244. package/dist/components/team/TeamCards.d.ts +6 -0
  245. package/dist/components/team/TeamCards.js +19 -0
  246. package/dist/components/team/TitleTeamCards.d.ts +2 -0
  247. package/dist/components/team/TitleTeamCards.js +6 -0
  248. package/dist/components/team/TrustSection.d.ts +2 -0
  249. package/dist/components/team/TrustSection.js +59 -0
  250. package/dist/components/team.d.ts +3 -0
  251. package/dist/components/team.js +15 -0
  252. package/dist/components/template-modal-content.d.ts +5 -0
  253. package/dist/components/template-modal-content.js +73 -0
  254. package/dist/components/templates.d.ts +2 -0
  255. package/dist/components/templates.js +27 -0
  256. package/dist/design.js +1180 -766
  257. package/dist/experts.js +655 -554
  258. package/dist/helpers/mobile-layout.d.ts +1 -0
  259. package/dist/helpers/mobile-layout.js +6 -0
  260. package/dist/helpers/use-el-size.d.ts +5 -0
  261. package/dist/helpers/use-el-size.js +40 -0
  262. package/dist/homepage/Pricing.js +1174 -760
  263. package/dist/main.d.ts +1 -0
  264. package/dist/main.js +6 -0
  265. package/dist/prompts/PromptsGallery.js +1176 -762
  266. package/dist/prompts/PromptsShow.js +1180 -766
  267. package/dist/prompts/PromptsSubmit.js +1182 -768
  268. package/dist/prompts-show.d.ts +1 -0
  269. package/dist/prompts-show.js +20 -0
  270. package/dist/prompts-submit.d.ts +1 -0
  271. package/dist/prompts-submit.js +6 -0
  272. package/dist/prompts.d.ts +1 -0
  273. package/dist/prompts.js +6 -0
  274. package/dist/team.d.ts +1 -0
  275. package/dist/team.js +1172 -758
  276. package/dist/template-modal-content.js +1179 -765
  277. package/dist/templates.js +1172 -758
  278. package/package.json +13 -13
package/dist/team.js CHANGED
@@ -217,7 +217,7 @@ var TitleTeamCards = () => {
217
217
  import * as React23 from "react";
218
218
  import * as React3 from "react";
219
219
  import { Fragment as Fragment2, jsx as jsx44 } from "react/jsx-runtime";
220
- import React52, { useCallback as useCallback26, useRef as useRef210, useState as useState22 } from "react";
220
+ import React52, { useCallback as useCallback27, useRef as useRef210, useState as useState22 } from "react";
221
221
 
222
222
  // ../../node_modules/.bun/clsx@2.1.1/node_modules/clsx/dist/clsx.mjs
223
223
  function r(e) {
@@ -4354,6 +4354,7 @@ import { useContext as useContext8, useMemo as useMemo7 } from "react";
4354
4354
  import { jsx as jsx7 } from "react/jsx-runtime";
4355
4355
  import {
4356
4356
  forwardRef as forwardRef3,
4357
+ useCallback as useCallback6,
4357
4358
  useContext as useContext17,
4358
4359
  useEffect as useEffect3,
4359
4360
  useMemo as useMemo14,
@@ -4392,14 +4393,14 @@ import {
4392
4393
  useRef as useRef9,
4393
4394
  useState as useState6
4394
4395
  } from "react";
4395
- import React15, { useCallback as useCallback6, useImperativeHandle, useMemo as useMemo16, useRef as useRef8 } from "react";
4396
+ import React15, { useCallback as useCallback7, useImperativeHandle, useMemo as useMemo16, useRef as useRef8 } from "react";
4396
4397
  import { useEffect as useEffect4, useMemo as useMemo15, useRef as useRef7 } from "react";
4397
4398
  import { jsx as jsx13 } from "react/jsx-runtime";
4398
4399
  import { jsx as jsx14 } from "react/jsx-runtime";
4399
4400
  import { useContext as useContext18, useLayoutEffect as useLayoutEffect4, useState as useState8 } from "react";
4400
4401
  import {
4401
4402
  createContext as createContext17,
4402
- useCallback as useCallback7,
4403
+ useCallback as useCallback8,
4403
4404
  useImperativeHandle as useImperativeHandle3,
4404
4405
  useLayoutEffect as useLayoutEffect3,
4405
4406
  useMemo as useMemo17,
@@ -4407,7 +4408,7 @@ import {
4407
4408
  useState as useState7
4408
4409
  } from "react";
4409
4410
  import { jsx as jsx15 } from "react/jsx-runtime";
4410
- import { forwardRef as forwardRef7, useCallback as useCallback13, useContext as useContext30 } from "react";
4411
+ import { forwardRef as forwardRef7, useCallback as useCallback14, useContext as useContext30 } from "react";
4411
4412
  import React16, { createContext as createContext18, useMemo as useMemo18 } from "react";
4412
4413
  import { jsx as jsx16 } from "react/jsx-runtime";
4413
4414
  import { useContext as useContext19 } from "react";
@@ -4415,7 +4416,7 @@ import { createContext as createContext19, useEffect as useEffect6, useState as
4415
4416
  import { jsx as jsx17 } from "react/jsx-runtime";
4416
4417
  import { createContext as createContext20, useMemo as useMemo19, useReducer } from "react";
4417
4418
  import { jsx as jsx18 } from "react/jsx-runtime";
4418
- import { useCallback as useCallback12 } from "react";
4419
+ import { useCallback as useCallback13 } from "react";
4419
4420
  import React22, {
4420
4421
  forwardRef as forwardRef5,
4421
4422
  useContext as useContext28,
@@ -4429,7 +4430,7 @@ import { useContext as useContext21, useLayoutEffect as useLayoutEffect5, useRef
4429
4430
  import React19, {
4430
4431
  createContext as createContext21,
4431
4432
  createRef as createRef2,
4432
- useCallback as useCallback8,
4433
+ useCallback as useCallback9,
4433
4434
  useContext as useContext20,
4434
4435
  useEffect as useEffect7,
4435
4436
  useMemo as useMemo21,
@@ -4442,16 +4443,16 @@ import { useRef as useRef13 } from "react";
4442
4443
  import { useContext as useContext23, useEffect as useEffect8, useMemo as useMemo22, useState as useState11 } from "react";
4443
4444
  import { useContext as useContext22 } from "react";
4444
4445
  import {
4445
- useCallback as useCallback11,
4446
+ useCallback as useCallback12,
4446
4447
  useContext as useContext26,
4447
4448
  useEffect as useEffect12,
4448
4449
  useLayoutEffect as useLayoutEffect7,
4449
4450
  useRef as useRef18
4450
4451
  } from "react";
4451
- import { useCallback as useCallback10, useMemo as useMemo25, useRef as useRef16 } from "react";
4452
+ import { useCallback as useCallback11, useMemo as useMemo25, useRef as useRef16 } from "react";
4452
4453
  import { useContext as useContext25, useMemo as useMemo24 } from "react";
4453
4454
  import React20, {
4454
- useCallback as useCallback9,
4455
+ useCallback as useCallback10,
4455
4456
  useContext as useContext24,
4456
4457
  useEffect as useEffect9,
4457
4458
  useLayoutEffect as useLayoutEffect6,
@@ -4479,7 +4480,7 @@ import { jsx as jsx222 } from "react/jsx-runtime";
4479
4480
  import { jsx as jsx23 } from "react/jsx-runtime";
4480
4481
  import {
4481
4482
  forwardRef as forwardRef8,
4482
- useCallback as useCallback14,
4483
+ useCallback as useCallback15,
4483
4484
  useEffect as useEffect16,
4484
4485
  useImperativeHandle as useImperativeHandle6,
4485
4486
  useMemo as useMemo29,
@@ -4490,7 +4491,7 @@ import { jsx as jsx24 } from "react/jsx-runtime";
4490
4491
  import {
4491
4492
  createContext as createContext23,
4492
4493
  forwardRef as forwardRef9,
4493
- useCallback as useCallback15,
4494
+ useCallback as useCallback16,
4494
4495
  useContext as useContext31,
4495
4496
  useLayoutEffect as useLayoutEffect9,
4496
4497
  useMemo as useMemo30,
@@ -4499,7 +4500,7 @@ import {
4499
4500
  import { jsx as jsx25 } from "react/jsx-runtime";
4500
4501
  import {
4501
4502
  forwardRef as forwardRef10,
4502
- useCallback as useCallback16,
4503
+ useCallback as useCallback17,
4503
4504
  useContext as useContext32,
4504
4505
  useEffect as useEffect17,
4505
4506
  useImperativeHandle as useImperativeHandle7,
@@ -4508,16 +4509,16 @@ import {
4508
4509
  useState as useState16
4509
4510
  } from "react";
4510
4511
  import { jsx as jsx26 } from "react/jsx-runtime";
4511
- import { forwardRef as forwardRef11, useCallback as useCallback17, useState as useState17 } from "react";
4512
+ import { forwardRef as forwardRef11, useCallback as useCallback18, useState as useState17 } from "react";
4512
4513
  import { jsx as jsx27 } from "react/jsx-runtime";
4513
- import { useCallback as useCallback18, useContext as useContext33, useLayoutEffect as useLayoutEffect10, useRef as useRef24 } from "react";
4514
+ import { useCallback as useCallback19, useContext as useContext33, useLayoutEffect as useLayoutEffect10, useRef as useRef24 } from "react";
4514
4515
  import { jsx as jsx28 } from "react/jsx-runtime";
4515
- import React29, { forwardRef as forwardRef12, useCallback as useCallback19, useRef as useRef25 } from "react";
4516
+ import React29, { forwardRef as forwardRef12, useCallback as useCallback20, useRef as useRef25 } from "react";
4516
4517
  import { jsx as jsx29 } from "react/jsx-runtime";
4517
4518
  import { createRef as createRef3 } from "react";
4518
4519
  import React30 from "react";
4519
4520
  import {
4520
- useCallback as useCallback20,
4521
+ useCallback as useCallback21,
4521
4522
  useImperativeHandle as useImperativeHandle8,
4522
4523
  useMemo as useMemo32,
4523
4524
  useRef as useRef26,
@@ -4532,9 +4533,9 @@ import { jsx as jsx322 } from "react/jsx-runtime";
4532
4533
  import React33 from "react";
4533
4534
  import React34, { createContext as createContext25 } from "react";
4534
4535
  import React35, { useContext as useContext35 } from "react";
4535
- import { useCallback as useCallback23 } from "react";
4536
+ import { useCallback as useCallback24 } from "react";
4536
4537
  import {
4537
- useCallback as useCallback21,
4538
+ useCallback as useCallback22,
4538
4539
  useContext as useContext36,
4539
4540
  useEffect as useEffect18,
4540
4541
  useLayoutEffect as useLayoutEffect11,
@@ -4544,7 +4545,7 @@ import {
4544
4545
  import { jsx as jsx33 } from "react/jsx-runtime";
4545
4546
  import React37, {
4546
4547
  forwardRef as forwardRef13,
4547
- useCallback as useCallback22,
4548
+ useCallback as useCallback23,
4548
4549
  useContext as useContext37,
4549
4550
  useEffect as useEffect20,
4550
4551
  useImperativeHandle as useImperativeHandle9,
@@ -4565,7 +4566,7 @@ import {
4565
4566
  import React40 from "react";
4566
4567
  import { jsx as jsx37 } from "react/jsx-runtime";
4567
4568
  import React42 from "react";
4568
- import { forwardRef as forwardRef16, useCallback as useCallback24, useContext as useContext39 } from "react";
4569
+ import { forwardRef as forwardRef16, useCallback as useCallback25, useContext as useContext39 } from "react";
4569
4570
  import {
4570
4571
  forwardRef as forwardRef15,
4571
4572
  useContext as useContext38,
@@ -5745,7 +5746,7 @@ var getComponentsToAddStacksTo = () => componentsToAddStacksTo;
5745
5746
  var addSequenceStackTraces = (component) => {
5746
5747
  componentsToAddStacksTo.push(component);
5747
5748
  };
5748
- var VERSION = "4.0.475";
5749
+ var VERSION = "4.0.477";
5749
5750
  var checkMultipleRemotionVersions = () => {
5750
5751
  if (typeof globalThis === "undefined") {
5751
5752
  return;
@@ -6179,6 +6180,18 @@ var hiddenField = {
6179
6180
  default: false,
6180
6181
  description: "Hidden"
6181
6182
  };
6183
+ var showInTimelineField = {
6184
+ type: "hidden"
6185
+ };
6186
+ var sequenceNameField = {
6187
+ type: "hidden"
6188
+ };
6189
+ var extendSchemaWithSequenceName = (schema) => {
6190
+ return {
6191
+ name: sequenceNameField,
6192
+ ...schema
6193
+ };
6194
+ };
6182
6195
  var durationInFramesField = {
6183
6196
  type: "number",
6184
6197
  default: undefined,
@@ -6192,9 +6205,17 @@ var fromField = {
6192
6205
  step: 1,
6193
6206
  hiddenFromList: true
6194
6207
  };
6195
- var sequenceSchema = {
6208
+ var freezeField = {
6209
+ type: "number",
6210
+ default: null,
6211
+ step: 1,
6212
+ hiddenFromList: true
6213
+ };
6214
+ var sequenceSchema = extendSchemaWithSequenceName({
6196
6215
  hidden: hiddenField,
6216
+ showInTimeline: showInTimelineField,
6197
6217
  from: fromField,
6218
+ freeze: freezeField,
6198
6219
  durationInFrames: durationInFramesField,
6199
6220
  layout: {
6200
6221
  type: "enum",
@@ -6205,12 +6226,14 @@ var sequenceSchema = {
6205
6226
  none: {}
6206
6227
  }
6207
6228
  }
6208
- };
6209
- var sequenceSchemaWithoutFrom = {
6229
+ });
6230
+ var sequenceSchemaWithoutFrom = extendSchemaWithSequenceName({
6210
6231
  hidden: hiddenField,
6232
+ showInTimeline: showInTimelineField,
6233
+ freeze: freezeField,
6211
6234
  durationInFrames: durationInFramesField,
6212
6235
  layout: sequenceSchema.layout
6213
- };
6236
+ });
6214
6237
  var sequenceSchemaDefaultLayoutNone = {
6215
6238
  ...sequenceSchema,
6216
6239
  layout: {
@@ -6554,81 +6577,6 @@ function bezier(mX1, mY1, mX2, mY2) {
6554
6577
  return calcBezier(getTForX(clampedX), mY1, mY2);
6555
6578
  };
6556
6579
  }
6557
- var clampUnit = (t) => Math.min(1, Math.max(0, t));
6558
-
6559
- class Easing {
6560
- static step0(n) {
6561
- return n > 0 ? 1 : 0;
6562
- }
6563
- static step1(n) {
6564
- return n >= 1 ? 1 : 0;
6565
- }
6566
- static linear(t) {
6567
- return t;
6568
- }
6569
- static ease(t) {
6570
- return Easing.bezier(0.42, 0, 1, 1)(t);
6571
- }
6572
- static quad(t) {
6573
- return t * t;
6574
- }
6575
- static cubic(t) {
6576
- return t * t * t;
6577
- }
6578
- static poly(n) {
6579
- return (t) => t ** n;
6580
- }
6581
- static sin(t) {
6582
- return 1 - Math.cos(t * Math.PI / 2);
6583
- }
6584
- static circle(t) {
6585
- const u = clampUnit(t);
6586
- return 1 - Math.sqrt(1 - u * u);
6587
- }
6588
- static exp(t) {
6589
- return 2 ** (10 * (t - 1));
6590
- }
6591
- static elastic(bounciness = 1) {
6592
- const p = bounciness * Math.PI;
6593
- return (t) => 1 - Math.cos(t * Math.PI / 2) ** 3 * Math.cos(t * p);
6594
- }
6595
- static back(s = 1.70158) {
6596
- return (t) => t * t * ((s + 1) * t - s);
6597
- }
6598
- static bounce(t) {
6599
- const u = clampUnit(t);
6600
- if (u < 1 / 2.75) {
6601
- return 7.5625 * u * u;
6602
- }
6603
- if (u < 2 / 2.75) {
6604
- const t2_ = u - 1.5 / 2.75;
6605
- return 7.5625 * t2_ * t2_ + 0.75;
6606
- }
6607
- if (u < 2.5 / 2.75) {
6608
- const t2_ = u - 2.25 / 2.75;
6609
- return 7.5625 * t2_ * t2_ + 0.9375;
6610
- }
6611
- const t2 = u - 2.625 / 2.75;
6612
- return 7.5625 * t2 * t2 + 0.984375;
6613
- }
6614
- static bezier(x1, y1, x2, y2) {
6615
- return bezier(x1, y1, x2, y2);
6616
- }
6617
- static in(easing) {
6618
- return easing;
6619
- }
6620
- static out(easing) {
6621
- return (t) => 1 - easing(1 - t);
6622
- }
6623
- static inOut(easing) {
6624
- return (t) => {
6625
- if (t < 0.5) {
6626
- return easing(t * 2) / 2;
6627
- }
6628
- return 1 - easing((1 - t) * 2) / 2;
6629
- };
6630
- }
6631
- }
6632
6580
  var normalizeNumber = (value) => {
6633
6581
  return Math.round(value * 1e6) / 1e6;
6634
6582
  };
@@ -7131,128 +7079,478 @@ function interpolate(input, inputRange, outputRange, options) {
7131
7079
  checkInfiniteRange("outputRange", outputRange);
7132
7080
  return interpolateNumber({ input, inputRange, outputRange, options });
7133
7081
  }
7134
- var NUMBER = "[-+]?\\d*\\.?\\d+";
7135
- var PERCENTAGE = NUMBER + "%";
7136
- function call(...args) {
7137
- return "\\(\\s*(" + args.join(")\\s*,\\s*(") + ")\\s*\\)";
7138
- }
7139
- var MODERN_VALUE = "(?:none|[-+]?\\d*\\.?\\d+(?:%|deg|rad|grad|turn)?)";
7140
- function modernColorCall(name) {
7141
- return new RegExp(name + "\\(\\s*(" + MODERN_VALUE + ")\\s+(" + MODERN_VALUE + ")\\s+(" + MODERN_VALUE + ")(?:\\s*\\/\\s*(" + MODERN_VALUE + "))?\\s*\\)");
7142
- }
7143
- function getMatchers() {
7144
- const cachedMatchers = {
7145
- rgb: undefined,
7146
- rgba: undefined,
7147
- hsl: undefined,
7148
- hsla: undefined,
7149
- hex3: undefined,
7150
- hex4: undefined,
7151
- hex5: undefined,
7152
- hex6: undefined,
7153
- hex8: undefined,
7154
- oklch: undefined,
7155
- oklab: undefined,
7156
- lab: undefined,
7157
- lch: undefined,
7158
- hwb: undefined
7159
- };
7160
- if (cachedMatchers.rgb === undefined) {
7161
- cachedMatchers.rgb = new RegExp("rgb" + call(NUMBER, NUMBER, NUMBER));
7162
- cachedMatchers.rgba = new RegExp("rgba" + call(NUMBER, NUMBER, NUMBER, NUMBER));
7163
- cachedMatchers.hsl = new RegExp("hsl" + call(NUMBER, PERCENTAGE, PERCENTAGE));
7164
- cachedMatchers.hsla = new RegExp("hsla" + call(NUMBER, PERCENTAGE, PERCENTAGE, NUMBER));
7165
- cachedMatchers.hex3 = /^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/;
7166
- cachedMatchers.hex4 = /^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/;
7167
- cachedMatchers.hex6 = /^#([0-9a-fA-F]{6})$/;
7168
- cachedMatchers.hex8 = /^#([0-9a-fA-F]{8})$/;
7169
- cachedMatchers.oklch = modernColorCall("oklch");
7170
- cachedMatchers.oklab = modernColorCall("oklab");
7171
- cachedMatchers.lab = modernColorCall("lab");
7172
- cachedMatchers.lch = modernColorCall("lch");
7173
- cachedMatchers.hwb = modernColorCall("hwb");
7174
- }
7175
- return cachedMatchers;
7176
- }
7177
- function hue2rgb(p, q, t) {
7178
- if (t < 0) {
7179
- t += 1;
7180
- }
7181
- if (t > 1) {
7182
- t -= 1;
7082
+ var validateFrame = ({
7083
+ allowFloats,
7084
+ durationInFrames,
7085
+ frame
7086
+ }) => {
7087
+ if (typeof frame === "undefined") {
7088
+ throw new TypeError(`Argument missing for parameter "frame"`);
7183
7089
  }
7184
- if (t < 1 / 6) {
7185
- return p + (q - p) * 6 * t;
7090
+ if (typeof frame !== "number") {
7091
+ throw new TypeError(`Argument passed for "frame" is not a number: ${frame}`);
7186
7092
  }
7187
- if (t < 1 / 2) {
7188
- return q;
7093
+ if (!Number.isFinite(frame)) {
7094
+ throw new RangeError(`Frame ${frame} is not finite`);
7189
7095
  }
7190
- if (t < 2 / 3) {
7191
- return p + (q - p) * (2 / 3 - t) * 6;
7096
+ if (frame % 1 !== 0 && !allowFloats) {
7097
+ throw new RangeError(`Argument for frame must be an integer, but got ${frame}`);
7192
7098
  }
7193
- return p;
7194
- }
7195
- function hslToRgb(h, s, l) {
7196
- const q = l < 0.5 ? l * (1 + s) : l + s - l * s;
7197
- const p = 2 * l - q;
7198
- const r2 = hue2rgb(p, q, h + 1 / 3);
7199
- const g = hue2rgb(p, q, h);
7200
- const b2 = hue2rgb(p, q, h - 1 / 3);
7201
- return Math.round(r2 * 255) << 24 | Math.round(g * 255) << 16 | Math.round(b2 * 255) << 8;
7202
- }
7203
- function parse255(str) {
7204
- const int = Number.parseInt(str, 10);
7205
- if (int < 0) {
7206
- return 0;
7099
+ if (frame < 0 && frame < -durationInFrames) {
7100
+ throw new RangeError(`Cannot use frame ${frame}: Duration of composition is ${durationInFrames}, therefore the lowest frame that can be rendered is ${-durationInFrames}`);
7207
7101
  }
7208
- if (int > 255) {
7209
- return 255;
7102
+ if (frame > durationInFrames - 1) {
7103
+ throw new RangeError(`Cannot use frame ${frame}: Duration of composition is ${durationInFrames}, therefore the highest frame that can be rendered is ${durationInFrames - 1}`);
7210
7104
  }
7211
- return int;
7212
- }
7213
- function parse360(str) {
7214
- const int = Number.parseFloat(str);
7215
- return (int % 360 + 360) % 360 / 360;
7216
- }
7217
- function parse1(str) {
7218
- const num = Number.parseFloat(str);
7219
- if (num < 0) {
7220
- return 0;
7105
+ };
7106
+ var validateSpringDuration = (dur) => {
7107
+ if (typeof dur === "undefined") {
7108
+ return;
7221
7109
  }
7222
- if (num > 1) {
7223
- return 255;
7110
+ if (typeof dur !== "number") {
7111
+ throw new TypeError(`A "duration" of a spring must be a "number" but is "${typeof dur}"`);
7224
7112
  }
7225
- return Math.round(num * 255);
7226
- }
7227
- function parsePercentage(str) {
7228
- const int = Number.parseFloat(str);
7229
- if (int < 0) {
7230
- return 0;
7113
+ if (Number.isNaN(dur)) {
7114
+ throw new TypeError('A "duration" of a spring is NaN, which it must not be');
7231
7115
  }
7232
- if (int > 100) {
7233
- return 1;
7116
+ if (!Number.isFinite(dur)) {
7117
+ throw new TypeError('A "duration" of a spring must be finite, but is ' + dur);
7234
7118
  }
7235
- return int / 100;
7236
- }
7237
- function parseModernComponent(str, percentScale) {
7238
- if (str === "none")
7239
- return 0;
7240
- if (str.endsWith("%")) {
7241
- return Number.parseFloat(str) / 100 * percentScale;
7119
+ if (dur <= 0) {
7120
+ throw new TypeError('A "duration" of a spring must be positive, but is ' + dur);
7242
7121
  }
7243
- return Number.parseFloat(str);
7244
- }
7245
- function parseHueAngle(str) {
7246
- if (str === "none")
7247
- return 0;
7248
- if (str.endsWith("rad")) {
7249
- return Number.parseFloat(str) * 180 / Math.PI;
7122
+ };
7123
+ var defaultSpringConfig = {
7124
+ damping: 10,
7125
+ mass: 1,
7126
+ stiffness: 100,
7127
+ overshootClamping: false
7128
+ };
7129
+ var advanceCache = {};
7130
+ function advance({
7131
+ animation,
7132
+ now,
7133
+ config
7134
+ }) {
7135
+ const { toValue: toValue2, lastTimestamp, current, velocity } = animation;
7136
+ const deltaTime = Math.min(now - lastTimestamp, 64);
7137
+ if (config.damping <= 0) {
7138
+ throw new Error("Spring damping must be greater than 0, otherwise the spring() animation will never end, causing an infinite loop.");
7139
+ }
7140
+ const c2 = config.damping;
7141
+ const m = config.mass;
7142
+ const k = config.stiffness;
7143
+ const cacheKey = [
7144
+ toValue2,
7145
+ lastTimestamp,
7146
+ current,
7147
+ velocity,
7148
+ c2,
7149
+ m,
7150
+ k,
7151
+ now
7152
+ ].join("-");
7153
+ if (advanceCache[cacheKey]) {
7154
+ return advanceCache[cacheKey];
7155
+ }
7156
+ const v0 = -velocity;
7157
+ const x0 = toValue2 - current;
7158
+ const zeta = c2 / (2 * Math.sqrt(k * m));
7159
+ const omega0 = Math.sqrt(k / m);
7160
+ const omega1 = omega0 * Math.sqrt(1 - zeta ** 2);
7161
+ const t = deltaTime / 1000;
7162
+ const sin1 = Math.sin(omega1 * t);
7163
+ const cos1 = Math.cos(omega1 * t);
7164
+ const underDampedEnvelope = Math.exp(-zeta * omega0 * t);
7165
+ const underDampedFrag1 = underDampedEnvelope * (sin1 * ((v0 + zeta * omega0 * x0) / omega1) + x0 * cos1);
7166
+ const underDampedPosition = toValue2 - underDampedFrag1;
7167
+ const underDampedVelocity = zeta * omega0 * underDampedFrag1 - underDampedEnvelope * (cos1 * (v0 + zeta * omega0 * x0) - omega1 * x0 * sin1);
7168
+ const criticallyDampedEnvelope = Math.exp(-omega0 * t);
7169
+ const criticallyDampedPosition = toValue2 - criticallyDampedEnvelope * (x0 + (v0 + omega0 * x0) * t);
7170
+ const criticallyDampedVelocity = criticallyDampedEnvelope * (v0 * (t * omega0 - 1) + t * x0 * omega0 * omega0);
7171
+ const animationNode = {
7172
+ toValue: toValue2,
7173
+ prevPosition: current,
7174
+ lastTimestamp: now,
7175
+ current: zeta < 1 ? underDampedPosition : criticallyDampedPosition,
7176
+ velocity: zeta < 1 ? underDampedVelocity : criticallyDampedVelocity
7177
+ };
7178
+ advanceCache[cacheKey] = animationNode;
7179
+ return animationNode;
7180
+ }
7181
+ var calculationCache = {};
7182
+ function springCalculation({
7183
+ frame,
7184
+ fps,
7185
+ config = {}
7186
+ }) {
7187
+ const from = 0;
7188
+ const to = 1;
7189
+ const cacheKey = [
7190
+ frame,
7191
+ fps,
7192
+ config.damping,
7193
+ config.mass,
7194
+ config.overshootClamping,
7195
+ config.stiffness
7196
+ ].join("-");
7197
+ if (calculationCache[cacheKey]) {
7198
+ return calculationCache[cacheKey];
7199
+ }
7200
+ let animation = {
7201
+ lastTimestamp: 0,
7202
+ current: from,
7203
+ toValue: to,
7204
+ velocity: 0,
7205
+ prevPosition: 0
7206
+ };
7207
+ const frameClamped = Math.max(0, frame);
7208
+ const unevenRest = frameClamped % 1;
7209
+ for (let f = 0;f <= Math.floor(frameClamped); f++) {
7210
+ if (f === Math.floor(frameClamped)) {
7211
+ f += unevenRest;
7212
+ }
7213
+ const time = f / fps * 1000;
7214
+ animation = advance({
7215
+ animation,
7216
+ now: time,
7217
+ config: {
7218
+ ...defaultSpringConfig,
7219
+ ...config
7220
+ }
7221
+ });
7222
+ }
7223
+ calculationCache[cacheKey] = animation;
7224
+ return animation;
7225
+ }
7226
+ var cache = new Map;
7227
+ function measureSpring({
7228
+ fps,
7229
+ config = {},
7230
+ threshold = 0.005
7231
+ }) {
7232
+ if (typeof threshold !== "number") {
7233
+ throw new TypeError(`threshold must be a number, got ${threshold} of type ${typeof threshold}`);
7234
+ }
7235
+ if (threshold === 0) {
7236
+ return Infinity;
7237
+ }
7238
+ if (threshold === 1) {
7239
+ return 0;
7240
+ }
7241
+ if (isNaN(threshold)) {
7242
+ throw new TypeError("Threshold is NaN");
7243
+ }
7244
+ if (!Number.isFinite(threshold)) {
7245
+ throw new TypeError("Threshold is not finite");
7246
+ }
7247
+ if (threshold < 0) {
7248
+ throw new TypeError("Threshold is below 0");
7249
+ }
7250
+ const cacheKey = [
7251
+ fps,
7252
+ config.damping,
7253
+ config.mass,
7254
+ config.overshootClamping,
7255
+ config.stiffness,
7256
+ threshold
7257
+ ].join("-");
7258
+ if (cache.has(cacheKey)) {
7259
+ return cache.get(cacheKey);
7260
+ }
7261
+ validateFps(fps, "to the measureSpring() function", false);
7262
+ let frame = 0;
7263
+ let finishedFrame = 0;
7264
+ const calc = () => {
7265
+ return springCalculation({
7266
+ fps,
7267
+ frame,
7268
+ config
7269
+ });
7270
+ };
7271
+ let animation = calc();
7272
+ const calcDifference = () => {
7273
+ return Math.abs(animation.current - animation.toValue);
7274
+ };
7275
+ let difference = calcDifference();
7276
+ while (difference >= threshold) {
7277
+ frame++;
7278
+ animation = calc();
7279
+ difference = calcDifference();
7280
+ }
7281
+ finishedFrame = frame;
7282
+ for (let i = 0;i < 20; i++) {
7283
+ frame++;
7284
+ animation = calc();
7285
+ difference = calcDifference();
7286
+ if (difference >= threshold) {
7287
+ i = 0;
7288
+ finishedFrame = frame + 1;
7289
+ }
7290
+ }
7291
+ cache.set(cacheKey, finishedFrame);
7292
+ return finishedFrame;
7293
+ }
7294
+ function spring({
7295
+ frame: passedFrame,
7296
+ fps,
7297
+ config = {},
7298
+ from = 0,
7299
+ to = 1,
7300
+ durationInFrames: passedDurationInFrames,
7301
+ durationRestThreshold,
7302
+ delay = 0,
7303
+ reverse = false
7304
+ }) {
7305
+ validateSpringDuration(passedDurationInFrames);
7306
+ validateFrame({
7307
+ frame: passedFrame,
7308
+ durationInFrames: Infinity,
7309
+ allowFloats: true
7310
+ });
7311
+ validateFps(fps, "to spring()", false);
7312
+ const needsToCalculateNaturalDuration = reverse || typeof passedDurationInFrames !== "undefined";
7313
+ const naturalDuration = needsToCalculateNaturalDuration ? measureSpring({
7314
+ fps,
7315
+ config,
7316
+ threshold: durationRestThreshold
7317
+ }) : undefined;
7318
+ const naturalDurationGetter = needsToCalculateNaturalDuration ? {
7319
+ get: () => naturalDuration
7320
+ } : {
7321
+ get: () => {
7322
+ throw new Error("did not calculate natural duration, this is an error with Remotion. Please report");
7323
+ }
7324
+ };
7325
+ const reverseProcessed = reverse ? (passedDurationInFrames ?? naturalDurationGetter.get()) - passedFrame : passedFrame;
7326
+ const delayProcessed = reverseProcessed + (reverse ? delay : -delay);
7327
+ const durationProcessed = passedDurationInFrames === undefined ? delayProcessed : delayProcessed / (passedDurationInFrames / naturalDurationGetter.get());
7328
+ if (passedDurationInFrames && delayProcessed > passedDurationInFrames) {
7329
+ return to;
7330
+ }
7331
+ const spr = springCalculation({
7332
+ fps,
7333
+ frame: durationProcessed,
7334
+ config
7335
+ });
7336
+ const inner = config.overshootClamping ? to >= from ? Math.min(spr.current, to) : Math.max(spr.current, to) : spr.current;
7337
+ const interpolated = from === 0 && to === 1 ? inner : interpolate(inner, [0, 1], [from, to]);
7338
+ return interpolated;
7339
+ }
7340
+ var clampUnit = (t) => Math.min(1, Math.max(0, t));
7341
+ var springEasingDurationInFrames = 30;
7342
+
7343
+ class Easing {
7344
+ static step0(n) {
7345
+ return n > 0 ? 1 : 0;
7346
+ }
7347
+ static step1(n) {
7348
+ return n >= 1 ? 1 : 0;
7349
+ }
7350
+ static linear(t) {
7351
+ return t;
7352
+ }
7353
+ static ease(t) {
7354
+ return Easing.bezier(0.42, 0, 1, 1)(t);
7355
+ }
7356
+ static quad(t) {
7357
+ return t * t;
7358
+ }
7359
+ static cubic(t) {
7360
+ return t * t * t;
7361
+ }
7362
+ static poly(n) {
7363
+ return (t) => t ** n;
7364
+ }
7365
+ static sin(t) {
7366
+ return 1 - Math.cos(t * Math.PI / 2);
7367
+ }
7368
+ static circle(t) {
7369
+ const u = clampUnit(t);
7370
+ return 1 - Math.sqrt(1 - u * u);
7371
+ }
7372
+ static exp(t) {
7373
+ return 2 ** (10 * (t - 1));
7374
+ }
7375
+ static elastic(bounciness = 1) {
7376
+ const p = bounciness * Math.PI;
7377
+ return (t) => 1 - Math.cos(t * Math.PI / 2) ** 3 * Math.cos(t * p);
7378
+ }
7379
+ static back(s = 1.70158) {
7380
+ return (t) => t * t * ((s + 1) * t - s);
7381
+ }
7382
+ static spring(config = {}) {
7383
+ return (t) => {
7384
+ if (t <= 0) {
7385
+ return 0;
7386
+ }
7387
+ if (t >= 1) {
7388
+ return 1;
7389
+ }
7390
+ return spring({
7391
+ fps: springEasingDurationInFrames,
7392
+ frame: t * springEasingDurationInFrames,
7393
+ config,
7394
+ durationInFrames: springEasingDurationInFrames
7395
+ });
7396
+ };
7397
+ }
7398
+ static bounce(t) {
7399
+ const u = clampUnit(t);
7400
+ if (u < 1 / 2.75) {
7401
+ return 7.5625 * u * u;
7402
+ }
7403
+ if (u < 2 / 2.75) {
7404
+ const t2_ = u - 1.5 / 2.75;
7405
+ return 7.5625 * t2_ * t2_ + 0.75;
7406
+ }
7407
+ if (u < 2.5 / 2.75) {
7408
+ const t2_ = u - 2.25 / 2.75;
7409
+ return 7.5625 * t2_ * t2_ + 0.9375;
7410
+ }
7411
+ const t2 = u - 2.625 / 2.75;
7412
+ return 7.5625 * t2 * t2 + 0.984375;
7413
+ }
7414
+ static bezier(x1, y1, x2, y2) {
7415
+ return bezier(x1, y1, x2, y2);
7416
+ }
7417
+ static in(easing) {
7418
+ return easing;
7419
+ }
7420
+ static out(easing) {
7421
+ return (t) => 1 - easing(1 - t);
7422
+ }
7423
+ static inOut(easing) {
7424
+ return (t) => {
7425
+ if (t < 0.5) {
7426
+ return easing(t * 2) / 2;
7427
+ }
7428
+ return 1 - easing((1 - t) * 2) / 2;
7429
+ };
7250
7430
  }
7251
- if (str.endsWith("grad"))
7252
- return Number.parseFloat(str) * 0.9;
7253
- if (str.endsWith("turn"))
7254
- return Number.parseFloat(str) * 360;
7255
- return Number.parseFloat(str);
7431
+ }
7432
+ var NUMBER = "[-+]?\\d*\\.?\\d+";
7433
+ var PERCENTAGE = NUMBER + "%";
7434
+ function call(...args) {
7435
+ return "\\(\\s*(" + args.join(")\\s*,\\s*(") + ")\\s*\\)";
7436
+ }
7437
+ var MODERN_VALUE = "(?:none|[-+]?\\d*\\.?\\d+(?:%|deg|rad|grad|turn)?)";
7438
+ function modernColorCall(name) {
7439
+ return new RegExp(name + "\\(\\s*(" + MODERN_VALUE + ")\\s+(" + MODERN_VALUE + ")\\s+(" + MODERN_VALUE + ")(?:\\s*\\/\\s*(" + MODERN_VALUE + "))?\\s*\\)");
7440
+ }
7441
+ function getMatchers() {
7442
+ const cachedMatchers = {
7443
+ rgb: undefined,
7444
+ rgba: undefined,
7445
+ hsl: undefined,
7446
+ hsla: undefined,
7447
+ hex3: undefined,
7448
+ hex4: undefined,
7449
+ hex5: undefined,
7450
+ hex6: undefined,
7451
+ hex8: undefined,
7452
+ oklch: undefined,
7453
+ oklab: undefined,
7454
+ lab: undefined,
7455
+ lch: undefined,
7456
+ hwb: undefined
7457
+ };
7458
+ if (cachedMatchers.rgb === undefined) {
7459
+ cachedMatchers.rgb = new RegExp("rgb" + call(NUMBER, NUMBER, NUMBER));
7460
+ cachedMatchers.rgba = new RegExp("rgba" + call(NUMBER, NUMBER, NUMBER, NUMBER));
7461
+ cachedMatchers.hsl = new RegExp("hsl" + call(NUMBER, PERCENTAGE, PERCENTAGE));
7462
+ cachedMatchers.hsla = new RegExp("hsla" + call(NUMBER, PERCENTAGE, PERCENTAGE, NUMBER));
7463
+ cachedMatchers.hex3 = /^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/;
7464
+ cachedMatchers.hex4 = /^#([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/;
7465
+ cachedMatchers.hex6 = /^#([0-9a-fA-F]{6})$/;
7466
+ cachedMatchers.hex8 = /^#([0-9a-fA-F]{8})$/;
7467
+ cachedMatchers.oklch = modernColorCall("oklch");
7468
+ cachedMatchers.oklab = modernColorCall("oklab");
7469
+ cachedMatchers.lab = modernColorCall("lab");
7470
+ cachedMatchers.lch = modernColorCall("lch");
7471
+ cachedMatchers.hwb = modernColorCall("hwb");
7472
+ }
7473
+ return cachedMatchers;
7474
+ }
7475
+ function hue2rgb(p, q, t) {
7476
+ if (t < 0) {
7477
+ t += 1;
7478
+ }
7479
+ if (t > 1) {
7480
+ t -= 1;
7481
+ }
7482
+ if (t < 1 / 6) {
7483
+ return p + (q - p) * 6 * t;
7484
+ }
7485
+ if (t < 1 / 2) {
7486
+ return q;
7487
+ }
7488
+ if (t < 2 / 3) {
7489
+ return p + (q - p) * (2 / 3 - t) * 6;
7490
+ }
7491
+ return p;
7492
+ }
7493
+ function hslToRgb(h, s, l) {
7494
+ const q = l < 0.5 ? l * (1 + s) : l + s - l * s;
7495
+ const p = 2 * l - q;
7496
+ const r2 = hue2rgb(p, q, h + 1 / 3);
7497
+ const g = hue2rgb(p, q, h);
7498
+ const b2 = hue2rgb(p, q, h - 1 / 3);
7499
+ return Math.round(r2 * 255) << 24 | Math.round(g * 255) << 16 | Math.round(b2 * 255) << 8;
7500
+ }
7501
+ function parse255(str) {
7502
+ const int = Number.parseInt(str, 10);
7503
+ if (int < 0) {
7504
+ return 0;
7505
+ }
7506
+ if (int > 255) {
7507
+ return 255;
7508
+ }
7509
+ return int;
7510
+ }
7511
+ function parse360(str) {
7512
+ const int = Number.parseFloat(str);
7513
+ return (int % 360 + 360) % 360 / 360;
7514
+ }
7515
+ function parse1(str) {
7516
+ const num = Number.parseFloat(str);
7517
+ if (num < 0) {
7518
+ return 0;
7519
+ }
7520
+ if (num > 1) {
7521
+ return 255;
7522
+ }
7523
+ return Math.round(num * 255);
7524
+ }
7525
+ function parsePercentage(str) {
7526
+ const int = Number.parseFloat(str);
7527
+ if (int < 0) {
7528
+ return 0;
7529
+ }
7530
+ if (int > 100) {
7531
+ return 1;
7532
+ }
7533
+ return int / 100;
7534
+ }
7535
+ function parseModernComponent(str, percentScale) {
7536
+ if (str === "none")
7537
+ return 0;
7538
+ if (str.endsWith("%")) {
7539
+ return Number.parseFloat(str) / 100 * percentScale;
7540
+ }
7541
+ return Number.parseFloat(str);
7542
+ }
7543
+ function parseHueAngle(str) {
7544
+ if (str === "none")
7545
+ return 0;
7546
+ if (str.endsWith("rad")) {
7547
+ return Number.parseFloat(str) * 180 / Math.PI;
7548
+ }
7549
+ if (str.endsWith("grad"))
7550
+ return Number.parseFloat(str) * 0.9;
7551
+ if (str.endsWith("turn"))
7552
+ return Number.parseFloat(str) * 360;
7553
+ return Number.parseFloat(str);
7256
7554
  }
7257
7555
  function parseModernAlpha(str) {
7258
7556
  if (str === undefined || str === "none")
@@ -8124,10 +8422,12 @@ var mergeValues = ({
8124
8422
  var stackToOverrideMap = {};
8125
8423
  var wrapInSchema = ({
8126
8424
  Component,
8425
+ componentIdentity,
8127
8426
  schema,
8128
8427
  supportsEffects
8129
8428
  }) => {
8130
- const flatSchema = getFlatSchemaWithAllKeys(schema);
8429
+ const schemaWithSequenceName = extendSchemaWithSequenceName(schema);
8430
+ const flatSchema = getFlatSchemaWithAllKeys(schemaWithSequenceName);
8131
8431
  const flatKeys = Object.keys(flatSchema);
8132
8432
  const Wrapped = forwardRef2((props, ref) => {
8133
8433
  const env = useRemotionEnvironment();
@@ -8166,15 +8466,16 @@ var wrapInSchema = ({
8166
8466
  const currentRuntimeValueDotNotation = useMemo13(() => readValuesFromProps(props, flatKeys), runtimeValues);
8167
8467
  const controls = useMemo13(() => {
8168
8468
  return {
8169
- schema,
8469
+ schema: schemaWithSequenceName,
8170
8470
  currentRuntimeValueDotNotation,
8171
8471
  overrideId,
8172
- supportsEffects
8472
+ supportsEffects,
8473
+ componentIdentity
8173
8474
  };
8174
8475
  }, [currentRuntimeValueDotNotation, overrideId]);
8175
8476
  const { merged: valuesDotNotation, propsToDelete } = useMemo13(() => {
8176
8477
  return computeEffectiveSchemaValuesDotNotation({
8177
- schema,
8478
+ schema: schemaWithSequenceName,
8178
8479
  currentValue: currentRuntimeValueDotNotation,
8179
8480
  overrideValues: nodePath === null ? {} : getDragOverrides(nodePath),
8180
8481
  propStatus: nodePath === null ? undefined : getPropStatusesCtx(propStatuses, nodePath),
@@ -8187,7 +8488,7 @@ var wrapInSchema = ({
8187
8488
  propStatuses,
8188
8489
  frame
8189
8490
  ]);
8190
- const activeKeys = selectActiveKeys(schema, valuesDotNotation);
8491
+ const activeKeys = selectActiveKeys(schemaWithSequenceName, valuesDotNotation);
8191
8492
  const mergedProps = mergeValues({
8192
8493
  props,
8193
8494
  valuesDotNotation,
@@ -8206,6 +8507,7 @@ var wrapInSchema = ({
8206
8507
  var EMPTY_EFFECTS = [];
8207
8508
  var RegularSequenceRefForwardingFunction = ({
8208
8509
  from = 0,
8510
+ freeze,
8209
8511
  durationInFrames = Infinity,
8210
8512
  children,
8211
8513
  name,
@@ -8221,7 +8523,7 @@ var RegularSequenceRefForwardingFunction = ({
8221
8523
  _remotionInternalPremountDisplay: premountDisplay,
8222
8524
  _remotionInternalPostmountDisplay: postmountDisplay,
8223
8525
  _remotionInternalIsMedia: isMedia,
8224
- _remotionInternalRefForOutline: refForOutline,
8526
+ _remotionInternalRefForOutline: passedRefForOutline,
8225
8527
  ...other
8226
8528
  }, ref) => {
8227
8529
  const { layout = "absolute-fill" } = other;
@@ -8229,6 +8531,7 @@ var RegularSequenceRefForwardingFunction = ({
8229
8531
  const parentSequence = useContext17(SequenceContext);
8230
8532
  const { rootId } = useTimelineContext();
8231
8533
  const cumulatedFrom = parentSequence ? parentSequence.cumulatedFrom + parentSequence.relativeFrom : 0;
8534
+ const absoluteFrom = (parentSequence?.absoluteFrom ?? 0) + from;
8232
8535
  const nonce = useNonce();
8233
8536
  if (layout !== "absolute-fill" && layout !== "none") {
8234
8537
  throw new TypeError(`The layout prop of <Sequence /> expects either "absolute-fill" or "none", but you passed: ${layout}`);
@@ -8248,11 +8551,24 @@ var RegularSequenceRefForwardingFunction = ({
8248
8551
  if (!Number.isFinite(from)) {
8249
8552
  throw new TypeError(`The "from" prop of a sequence must be finite, but got ${from}.`);
8250
8553
  }
8554
+ if (typeof freeze !== "undefined" && freeze !== null) {
8555
+ if (typeof freeze !== "number") {
8556
+ throw new TypeError(`The "freeze" prop of <Sequence /> must be a number, but is of type ${typeof freeze}.`);
8557
+ }
8558
+ if (Number.isNaN(freeze)) {
8559
+ throw new TypeError(`The "freeze" prop of <Sequence /> must be a real number, but it is NaN.`);
8560
+ }
8561
+ if (!Number.isFinite(freeze)) {
8562
+ throw new TypeError(`The "freeze" prop of <Sequence /> must be finite, but it is ${freeze}.`);
8563
+ }
8564
+ }
8251
8565
  const absoluteFrame = useTimelinePosition();
8252
8566
  const videoConfig = useVideoConfig();
8253
8567
  const parentSequenceDuration = parentSequence ? Math.min(parentSequence.durationInFrames - from, durationInFrames) : durationInFrames;
8254
8568
  const actualDurationInFrames = Math.max(0, Math.min(videoConfig.durationInFrames - from, parentSequenceDuration));
8255
8569
  const { registerSequence, unregisterSequence } = useContext17(SequenceManager);
8570
+ const wrapperRefForOutline = useRef6(null);
8571
+ const refForOutline = other.layout === "none" ? passedRefForOutline ?? null : passedRefForOutline ?? wrapperRefForOutline;
8256
8572
  const premounting = useMemo14(() => {
8257
8573
  return parentSequence?.premounting || Boolean(other._remotionInternalIsPremounting);
8258
8574
  }, [other._remotionInternalIsPremounting, parentSequence?.premounting]);
@@ -8266,6 +8582,7 @@ var RegularSequenceRefForwardingFunction = ({
8266
8582
  const cumulatedNegativeFrom = currentSequenceStart - firstFrame;
8267
8583
  const contextValue = useMemo14(() => {
8268
8584
  return {
8585
+ absoluteFrom,
8269
8586
  cumulatedFrom,
8270
8587
  relativeFrom: from,
8271
8588
  cumulatedNegativeFrom,
@@ -8281,6 +8598,7 @@ var RegularSequenceRefForwardingFunction = ({
8281
8598
  };
8282
8599
  }, [
8283
8600
  cumulatedFrom,
8601
+ absoluteFrom,
8284
8602
  from,
8285
8603
  actualDurationInFrames,
8286
8604
  parentSequence,
@@ -8296,7 +8614,7 @@ var RegularSequenceRefForwardingFunction = ({
8296
8614
  const timelineClipName = useMemo14(() => {
8297
8615
  return name ?? "";
8298
8616
  }, [name]);
8299
- const resolvedDocumentationLink = documentationLink ?? (name === undefined ? "https://www.remotion.dev/docs/sequence" : null);
8617
+ const resolvedDocumentationLink = documentationLink ?? "https://www.remotion.dev/docs/sequence";
8300
8618
  const env = useRemotionEnvironment();
8301
8619
  const isInsideSeries = useContext17(IsInsideSeriesContext);
8302
8620
  const inheritedStack = other?.stack ?? null;
@@ -8409,7 +8727,19 @@ var RegularSequenceRefForwardingFunction = ({
8409
8727
  ]);
8410
8728
  const endThreshold = Math.ceil(cumulatedFrom + from + durationInFrames - 1);
8411
8729
  const content = absoluteFrame < cumulatedFrom + from ? null : absoluteFrame > endThreshold ? null : children;
8730
+ const frozenContent = content === null || typeof freeze === "undefined" || freeze === null ? content : /* @__PURE__ */ jsx12(Freeze, {
8731
+ frame: freeze,
8732
+ children: content
8733
+ });
8412
8734
  const styleIfThere = other.layout === "none" ? undefined : other.style;
8735
+ const sequenceRef = useCallback6((node) => {
8736
+ wrapperRefForOutline.current = node;
8737
+ if (typeof ref === "function") {
8738
+ ref(node);
8739
+ } else if (ref) {
8740
+ ref.current = node;
8741
+ }
8742
+ }, [ref]);
8413
8743
  const defaultStyle = useMemo14(() => {
8414
8744
  return {
8415
8745
  flexDirection: undefined,
@@ -8426,11 +8756,11 @@ var RegularSequenceRefForwardingFunction = ({
8426
8756
  }
8427
8757
  return /* @__PURE__ */ jsx12(SequenceContext.Provider, {
8428
8758
  value: contextValue,
8429
- children: content === null ? null : other.layout === "none" ? content : /* @__PURE__ */ jsx12(AbsoluteFill, {
8430
- ref,
8759
+ children: frozenContent === null ? null : other.layout === "none" ? frozenContent : /* @__PURE__ */ jsx12(AbsoluteFill, {
8760
+ ref: sequenceRef,
8431
8761
  style: defaultStyle,
8432
8762
  className: other.className,
8433
- children: content
8763
+ children: frozenContent
8434
8764
  })
8435
8765
  });
8436
8766
  };
@@ -8510,11 +8840,13 @@ var SequenceInner = forwardRef3(SequenceRefForwardingFunction);
8510
8840
  var SequenceWithoutSchema = SequenceInner;
8511
8841
  var Sequence = wrapInSchema({
8512
8842
  Component: SequenceInner,
8843
+ componentIdentity: "dev.remotion.remotion.Sequence",
8513
8844
  schema: sequenceSchema,
8514
8845
  supportsEffects: false
8515
8846
  });
8516
8847
  var SequenceWithoutFrom = wrapInSchema({
8517
8848
  Component: SequenceInner,
8849
+ componentIdentity: null,
8518
8850
  schema: sequenceSchemaWithoutFrom,
8519
8851
  supportsEffects: false
8520
8852
  });
@@ -8832,7 +9164,7 @@ var CanvasRefForwardingFunction = ({ width, height, fit, className, style, effec
8832
9164
  }
8833
9165
  return document.createElement("canvas");
8834
9166
  }, []);
8835
- const draw = useCallback6((imageData) => {
9167
+ const draw = useCallback7((imageData) => {
8836
9168
  const canvas = canvasRef.current;
8837
9169
  const canvasWidth = width ?? imageData.displayWidth;
8838
9170
  const canvasHeight = height ?? imageData.displayHeight;
@@ -8923,10 +9255,10 @@ var decodeImage = async ({
8923
9255
  if (!selectedTrack) {
8924
9256
  throw new Error("No selected track");
8925
9257
  }
8926
- const cache = [];
9258
+ const cache2 = [];
8927
9259
  let durationFound = null;
8928
9260
  const getFrameByIndex = async (frameIndex) => {
8929
- const foundInCache = cache.find((c2) => c2.frameIndex === frameIndex);
9261
+ const foundInCache = cache2.find((c2) => c2.frameIndex === frameIndex);
8930
9262
  if (foundInCache && foundInCache.frame) {
8931
9263
  return foundInCache;
8932
9264
  }
@@ -8937,7 +9269,7 @@ var decodeImage = async ({
8937
9269
  if (foundInCache) {
8938
9270
  foundInCache.frame = frame.image;
8939
9271
  } else {
8940
- cache.push({
9272
+ cache2.push({
8941
9273
  frame: frame.image,
8942
9274
  frameIndex,
8943
9275
  timeInSeconds: frame.image.timestamp / 1e6
@@ -8950,7 +9282,7 @@ var decodeImage = async ({
8950
9282
  };
8951
9283
  };
8952
9284
  const clearCache = (closeToTimeInSec) => {
8953
- const itemsInCache = cache.filter((c2) => c2.frame);
9285
+ const itemsInCache = cache2.filter((c2) => c2.frame);
8954
9286
  const sortByClosestToCurrentTime = itemsInCache.sort((a2, b2) => {
8955
9287
  const aDiff = Math.abs(a2.timeInSeconds - closeToTimeInSec);
8956
9288
  const bDiff = Math.abs(b2.timeInSeconds - closeToTimeInSec);
@@ -8973,7 +9305,7 @@ var decodeImage = async ({
8973
9305
  loopBehavior,
8974
9306
  timeInSec
8975
9307
  });
8976
- const framesBefore = cache.filter((c2) => c2.timeInSeconds <= actualTimeInSec);
9308
+ const framesBefore = cache2.filter((c2) => c2.timeInSeconds <= actualTimeInSec);
8977
9309
  const biggestIndex = framesBefore.map((c2) => c2.frameIndex).reduce((a2, b2) => Math.max(a2, b2), 0);
8978
9310
  let i = biggestIndex;
8979
9311
  while (true) {
@@ -9016,7 +9348,7 @@ var decodeImage = async ({
9016
9348
  timeInSec
9017
9349
  });
9018
9350
  await ensureFrameBeforeAndAfter({ timeInSec: actualTimeInSec, loopBehavior });
9019
- const itemsInCache = cache.filter((c2) => c2.frame);
9351
+ const itemsInCache = cache2.filter((c2) => c2.frame);
9020
9352
  const closest = itemsInCache.reduce((a2, b2) => {
9021
9353
  const aDiff = Math.abs(a2.timeInSeconds - actualTimeInSec);
9022
9354
  const bDiff = Math.abs(b2.timeInSeconds - actualTimeInSec);
@@ -9053,6 +9385,7 @@ var resolveAnimatedImageSource = (src) => {
9053
9385
  var animatedImageSchema = {
9054
9386
  durationInFrames: durationInFramesField,
9055
9387
  from: fromField,
9388
+ freeze: freezeField,
9056
9389
  playbackRate: {
9057
9390
  type: "number",
9058
9391
  min: 0,
@@ -9252,6 +9585,7 @@ var AnimatedImageInner = ({
9252
9585
  };
9253
9586
  var AnimatedImage = wrapInSchema({
9254
9587
  Component: AnimatedImageInner,
9588
+ componentIdentity: "dev.remotion.remotion.AnimatedImage",
9255
9589
  schema: animatedImageSchema,
9256
9590
  supportsEffects: true
9257
9591
  });
@@ -9298,7 +9632,7 @@ var RenderAssetManager = createContext17({
9298
9632
  var RenderAssetManagerProvider = ({ children, collectAssets }) => {
9299
9633
  const [renderAssets, setRenderAssets] = useState7([]);
9300
9634
  const renderAssetsRef = useRef10([]);
9301
- const registerRenderAsset = useCallback7((renderAsset) => {
9635
+ const registerRenderAsset = useCallback8((renderAsset) => {
9302
9636
  validateRenderAsset(renderAsset);
9303
9637
  renderAssetsRef.current = [...renderAssetsRef.current, renderAsset];
9304
9638
  setRenderAssets(renderAssetsRef.current);
@@ -9315,7 +9649,7 @@ var RenderAssetManagerProvider = ({ children, collectAssets }) => {
9315
9649
  };
9316
9650
  }, []);
9317
9651
  }
9318
- const unregisterRenderAsset = useCallback7((id) => {
9652
+ const unregisterRenderAsset = useCallback8((id) => {
9319
9653
  renderAssetsRef.current = renderAssetsRef.current.filter((a2) => a2.id !== id);
9320
9654
  setRenderAssets(renderAssetsRef.current);
9321
9655
  }, []);
@@ -9477,7 +9811,7 @@ var Loop = ({
9477
9811
  durationInFrames,
9478
9812
  from,
9479
9813
  name: name ?? "<Loop>",
9480
- _remotionInternalDocumentationLink: name === undefined ? "https://www.remotion.dev/docs/loop" : undefined,
9814
+ _remotionInternalDocumentationLink: "https://www.remotion.dev/docs/loop",
9481
9815
  _remotionInternalLoopDisplay: loopDisplay,
9482
9816
  layout: props.layout,
9483
9817
  style,
@@ -10120,7 +10454,7 @@ var SharedAudioContextProvider = ({ children, audioLatencyHint, audioEnabled, pr
10120
10454
  }, []);
10121
10455
  const prevEndTimes = useRef12({ scheduledEndTime: null, mediaEndTime: null });
10122
10456
  const nodesToResume = useRef12(new Map);
10123
- const unscheduleAudioNode = useCallback8((node) => {
10457
+ const unscheduleAudioNode = useCallback9((node) => {
10124
10458
  nodesToResume.current.delete(node);
10125
10459
  }, []);
10126
10460
  const scheduleAudioNode = useMemo21(() => {
@@ -10174,7 +10508,7 @@ var SharedAudioContextProvider = ({ children, audioLatencyHint, audioEnabled, pr
10174
10508
  };
10175
10509
  };
10176
10510
  }, [ctxAndGain, logLevel]);
10177
- const resume = useCallback8(() => {
10511
+ const resume = useCallback9(() => {
10178
10512
  if (!ctxAndGain) {
10179
10513
  return Promise.resolve();
10180
10514
  }
@@ -10201,10 +10535,10 @@ var SharedAudioContextProvider = ({ children, audioLatencyHint, audioEnabled, pr
10201
10535
  });
10202
10536
  return resumePromise.catch(() => {});
10203
10537
  }, [ctxAndGain, logLevel]);
10204
- const getIsResumingAudioContext = useCallback8(() => {
10538
+ const getIsResumingAudioContext = useCallback9(() => {
10205
10539
  return isResuming.current;
10206
10540
  }, []);
10207
- const suspend = useCallback8(() => {
10541
+ const suspend = useCallback9(() => {
10208
10542
  if (!ctxAndGain) {
10209
10543
  return Promise.resolve();
10210
10544
  }
@@ -10278,7 +10612,7 @@ var SharedAudioTagsContextProvider = ({ children, numberOfAudioTags }) => {
10278
10612
  };
10279
10613
  }, [refs]);
10280
10614
  const takenAudios = useRef12(new Array(numberOfAudioTags).fill(false));
10281
- const rerenderAudios = useCallback8(() => {
10615
+ const rerenderAudios = useCallback9(() => {
10282
10616
  refs.forEach(({ ref, id }) => {
10283
10617
  const data = audios.current?.find((a2) => a2.id === id);
10284
10618
  const { current } = ref;
@@ -10299,7 +10633,7 @@ var SharedAudioTagsContextProvider = ({ children, numberOfAudioTags }) => {
10299
10633
  });
10300
10634
  });
10301
10635
  }, [refs]);
10302
- const registerAudio = useCallback8((options) => {
10636
+ const registerAudio = useCallback9((options) => {
10303
10637
  const { aud, audioId, premounting, postmounting } = options;
10304
10638
  const found = audios.current?.find((a2) => a2.audioId === audioId);
10305
10639
  if (found) {
@@ -10328,7 +10662,7 @@ var SharedAudioTagsContextProvider = ({ children, numberOfAudioTags }) => {
10328
10662
  rerenderAudios();
10329
10663
  return newElem;
10330
10664
  }, [numberOfAudioTags, refs, rerenderAudios]);
10331
- const unregisterAudio = useCallback8((id) => {
10665
+ const unregisterAudio = useCallback9((id) => {
10332
10666
  const cloned = [...takenAudios.current];
10333
10667
  const index = refs.findIndex((r2) => r2.id === id);
10334
10668
  if (index === -1) {
@@ -10339,7 +10673,7 @@ var SharedAudioTagsContextProvider = ({ children, numberOfAudioTags }) => {
10339
10673
  audios.current = audios.current?.filter((a2) => a2.id !== id);
10340
10674
  rerenderAudios();
10341
10675
  }, [refs, rerenderAudios]);
10342
- const updateAudio = useCallback8(({
10676
+ const updateAudio = useCallback9(({
10343
10677
  aud,
10344
10678
  audioId,
10345
10679
  id,
@@ -10373,7 +10707,7 @@ var SharedAudioTagsContextProvider = ({ children, numberOfAudioTags }) => {
10373
10707
  rerenderAudios();
10374
10708
  }
10375
10709
  }, [rerenderAudios]);
10376
- const playAllAudios = useCallback8(() => {
10710
+ const playAllAudios = useCallback9(() => {
10377
10711
  refs.forEach((ref) => {
10378
10712
  const audio = audios.current.find((a2) => a2.el === ref.ref);
10379
10713
  if (audio?.premounting) {
@@ -10921,7 +11255,7 @@ var useBufferManager = (logLevel, mountTime) => {
10921
11255
  const env = useRemotionEnvironment();
10922
11256
  const rendering = env.isRendering;
10923
11257
  const buffering = useRef15(false);
10924
- const addBlock = useCallback9((block) => {
11258
+ const addBlock = useCallback10((block) => {
10925
11259
  if (rendering) {
10926
11260
  return {
10927
11261
  unblock: () => {
@@ -10947,7 +11281,7 @@ var useBufferManager = (logLevel, mountTime) => {
10947
11281
  }
10948
11282
  };
10949
11283
  }, [rendering]);
10950
- const listenForBuffering = useCallback9((callback) => {
11284
+ const listenForBuffering = useCallback10((callback) => {
10951
11285
  setOnBufferingCallbacks((c2) => [...c2, callback]);
10952
11286
  return {
10953
11287
  remove: () => {
@@ -10955,7 +11289,7 @@ var useBufferManager = (logLevel, mountTime) => {
10955
11289
  }
10956
11290
  };
10957
11291
  }, []);
10958
- const listenForResume = useCallback9((callback) => {
11292
+ const listenForResume = useCallback10((callback) => {
10959
11293
  setOnResumeCallbacks((c2) => [...c2, callback]);
10960
11294
  return {
10961
11295
  remove: () => {
@@ -11069,7 +11403,7 @@ var useBufferUntilFirstFrame = ({
11069
11403
  }) => {
11070
11404
  const bufferingRef = useRef16(false);
11071
11405
  const { delayPlayback } = useBufferState();
11072
- const bufferUntilFirstFrame = useCallback10((requestedTime) => {
11406
+ const bufferUntilFirstFrame = useCallback11((requestedTime) => {
11073
11407
  if (mediaType !== "video") {
11074
11408
  return;
11075
11409
  }
@@ -11459,7 +11793,7 @@ var useMediaPlayback = ({
11459
11793
  throw new Error("useMediaPlayback must be used inside a <BufferingContext>");
11460
11794
  }
11461
11795
  const isVariableFpsVideoMap = useRef18({});
11462
- const onVariableFpsVideoDetected = useCallback11(() => {
11796
+ const onVariableFpsVideoDetected = useCallback12(() => {
11463
11797
  if (!src) {
11464
11798
  return;
11465
11799
  }
@@ -11850,7 +12184,7 @@ var AudioForDevelopmentForwardRefFunction = (props, ref) => {
11850
12184
  premounting: Boolean(sequenceContext?.premounting),
11851
12185
  postmounting: Boolean(sequenceContext?.postmounting)
11852
12186
  });
11853
- const getStack = useCallback12(() => {
12187
+ const getStack = useCallback13(() => {
11854
12188
  return _remotionInternalStack ?? null;
11855
12189
  }, [_remotionInternalStack]);
11856
12190
  useMediaInTimeline({
@@ -11866,7 +12200,7 @@ var AudioForDevelopmentForwardRefFunction = (props, ref) => {
11866
12200
  premountDisplay: sequenceContext?.premountDisplay ?? null,
11867
12201
  postmountDisplay: sequenceContext?.postmountDisplay ?? null,
11868
12202
  loopDisplay: undefined,
11869
- documentationLink: name === undefined ? "https://www.remotion.dev/docs/html5-audio" : null,
12203
+ documentationLink: "https://www.remotion.dev/docs/html5-audio",
11870
12204
  refForOutline: null
11871
12205
  });
11872
12206
  useMediaPlayback({
@@ -12096,7 +12430,7 @@ var AudioRefForwardingFunction = (props, ref) => {
12096
12430
  throw new TypeError(`The \`<Html5Audio>\` tag requires a string for \`src\`, but got ${JSON.stringify(props.src)} instead.`);
12097
12431
  }
12098
12432
  const preloadedSrc = usePreload(props.src);
12099
- const onError = useCallback13((e) => {
12433
+ const onError = useCallback14((e) => {
12100
12434
  console.log(e.currentTarget.error);
12101
12435
  const errMessage = `Could not play audio with src ${preloadedSrc}: ${e.currentTarget.error}. See https://remotion.dev/docs/media-playback-error for help.`;
12102
12436
  if (loop) {
@@ -12110,7 +12444,7 @@ var AudioRefForwardingFunction = (props, ref) => {
12110
12444
  console.warn(errMessage);
12111
12445
  }
12112
12446
  }, [loop, onRemotionError, preloadedSrc]);
12113
- const onDuration = useCallback13((src, durationInSeconds) => {
12447
+ const onDuration = useCallback14((src, durationInSeconds) => {
12114
12448
  setDurations({ type: "got-duration", durationInSeconds, src });
12115
12449
  }, [setDurations]);
12116
12450
  const durationFetched = durations[getAbsoluteSrc(preloadedSrc)] ?? durations[getAbsoluteSrc(props.src)];
@@ -12202,6 +12536,7 @@ var resolveSolidPixelDensity = (pixelDensity) => {
12202
12536
  var solidSchema = {
12203
12537
  durationInFrames: durationInFramesField,
12204
12538
  from: fromField,
12539
+ freeze: freezeField,
12205
12540
  color: {
12206
12541
  type: "color",
12207
12542
  default: "transparent",
@@ -12256,7 +12591,7 @@ var SolidInner = ({
12256
12591
  return canvas;
12257
12592
  }, []);
12258
12593
  const chainState = useEffectChainState();
12259
- const canvasRef = useCallback14((canvas) => {
12594
+ const canvasRef = useCallback15((canvas) => {
12260
12595
  setOutputCanvas(canvas);
12261
12596
  if (typeof reference === "function") {
12262
12597
  reference(canvas);
@@ -12340,6 +12675,7 @@ var SolidOuter = forwardRef8(({
12340
12675
  style,
12341
12676
  name,
12342
12677
  from,
12678
+ freeze,
12343
12679
  hidden,
12344
12680
  showInTimeline,
12345
12681
  pixelDensity,
@@ -12353,6 +12689,7 @@ var SolidOuter = forwardRef8(({
12353
12689
  return /* @__PURE__ */ jsx24(Sequence, {
12354
12690
  layout: "none",
12355
12691
  from,
12692
+ freeze,
12356
12693
  hidden,
12357
12694
  showInTimeline,
12358
12695
  _experimentalControls: controls,
@@ -12360,7 +12697,7 @@ var SolidOuter = forwardRef8(({
12360
12697
  durationInFrames,
12361
12698
  name: name ?? "<Solid>",
12362
12699
  _remotionInternalRefForOutline: actualRef,
12363
- _remotionInternalDocumentationLink: name === undefined ? "https://www.remotion.dev/docs/solid" : undefined,
12700
+ _remotionInternalDocumentationLink: "https://www.remotion.dev/docs/solid",
12364
12701
  ...props2,
12365
12702
  children: /* @__PURE__ */ jsx24(SolidInner, {
12366
12703
  reference: actualRef,
@@ -12377,6 +12714,7 @@ var SolidOuter = forwardRef8(({
12377
12714
  });
12378
12715
  var Solid = wrapInSchema({
12379
12716
  Component: SolidOuter,
12717
+ componentIdentity: "dev.remotion.remotion.Solid",
12380
12718
  schema: solidSchema,
12381
12719
  supportsEffects: true
12382
12720
  });
@@ -12466,7 +12804,7 @@ var HtmlInCanvasContent = forwardRef9(({
12466
12804
  const offscreenRef = useRef22(null);
12467
12805
  const divRef = useRef22(null);
12468
12806
  const canvasSizeKey = `${width}x${height}@${resolvedPixelDensity}`;
12469
- const setLayoutCanvasRef = useCallback15((node) => {
12807
+ const setLayoutCanvasRef = useCallback16((node) => {
12470
12808
  canvas2dRef.current = node;
12471
12809
  if (typeof ref === "function") {
12472
12810
  ref(node);
@@ -12488,7 +12826,7 @@ var HtmlInCanvasContent = forwardRef9(({
12488
12826
  const initializedRef = useRef22(false);
12489
12827
  const onInitCleanupRef = useRef22(null);
12490
12828
  const unmountedRef = useRef22(false);
12491
- const onPaintCb = useCallback15(async () => {
12829
+ const onPaintCb = useCallback16(async () => {
12492
12830
  const element = divRef.current;
12493
12831
  if (!element) {
12494
12832
  throw new Error("Canvas or scene element not found");
@@ -12661,7 +12999,7 @@ var HtmlInCanvasInner = forwardRef9(({
12661
12999
  const resolvedDuration = durationInFrames ?? videoDuration;
12662
13000
  const memoizedEffectDefinitions = useMemoizedEffectDefinitions(effects);
12663
13001
  const actualRef = useRef22(null);
12664
- const setCanvasRef = useCallback15((node) => {
13002
+ const setCanvasRef = useCallback16((node) => {
12665
13003
  actualRef.current = node;
12666
13004
  if (typeof ref === "function") {
12667
13005
  ref(node);
@@ -12672,7 +13010,7 @@ var HtmlInCanvasInner = forwardRef9(({
12672
13010
  return /* @__PURE__ */ jsx25(Sequence, {
12673
13011
  durationInFrames: resolvedDuration,
12674
13012
  name: name ?? "<HtmlInCanvas>",
12675
- _remotionInternalDocumentationLink: name === undefined ? "https://www.remotion.dev/docs/remotion/html-in-canvas" : undefined,
13013
+ _remotionInternalDocumentationLink: "https://www.remotion.dev/docs/remotion/html-in-canvas",
12676
13014
  _experimentalControls: controls,
12677
13015
  _remotionInternalEffects: memoizedEffectDefinitions,
12678
13016
  _remotionInternalRefForOutline: actualRef,
@@ -12696,11 +13034,13 @@ HtmlInCanvasInner.displayName = "HtmlInCanvas";
12696
13034
  var htmlInCanvasSchema = {
12697
13035
  durationInFrames: durationInFramesField,
12698
13036
  from: fromField,
13037
+ freeze: freezeField,
12699
13038
  ...sequenceVisualStyleSchema,
12700
13039
  hidden: hiddenField
12701
13040
  };
12702
13041
  var HtmlInCanvasWrapped = wrapInSchema({
12703
13042
  Component: HtmlInCanvasInner,
13043
+ componentIdentity: "dev.remotion.remotion.HtmlInCanvas",
12704
13044
  schema: htmlInCanvasSchema,
12705
13045
  supportsEffects: true
12706
13046
  });
@@ -12718,6 +13058,7 @@ function truncateSrcForLabel(src) {
12718
13058
  var canvasImageSchema = {
12719
13059
  durationInFrames: durationInFramesField,
12720
13060
  from: fromField,
13061
+ freeze: freezeField,
12721
13062
  fit: {
12722
13063
  type: "enum",
12723
13064
  default: "fill",
@@ -12823,7 +13164,7 @@ var CanvasImageContent = forwardRef10(({
12823
13164
  }
12824
13165
  return document.createElement("canvas");
12825
13166
  }, []);
12826
- const canvasRef = useCallback16((canvas) => {
13167
+ const canvasRef = useCallback17((canvas) => {
12827
13168
  setOutputCanvas(canvas);
12828
13169
  if (refForOutline) {
12829
13170
  refForOutline.current = canvas;
@@ -12970,6 +13311,7 @@ var CanvasImageInner = forwardRef10(({
12970
13311
  delayRenderTimeoutInMilliseconds,
12971
13312
  durationInFrames,
12972
13313
  from,
13314
+ freeze,
12973
13315
  hidden,
12974
13316
  name,
12975
13317
  showInTimeline,
@@ -12991,6 +13333,7 @@ var CanvasImageInner = forwardRef10(({
12991
13333
  layout: "none",
12992
13334
  from: from ?? 0,
12993
13335
  durationInFrames: durationInFrames ?? Infinity,
13336
+ freeze,
12994
13337
  hidden,
12995
13338
  showInTimeline: showInTimeline ?? true,
12996
13339
  name: name ?? "<CanvasImage>",
@@ -13023,6 +13366,7 @@ var CanvasImageInner = forwardRef10(({
13023
13366
  });
13024
13367
  var CanvasImage = wrapInSchema({
13025
13368
  Component: CanvasImageInner,
13369
+ componentIdentity: "dev.remotion.remotion.CanvasImage",
13026
13370
  schema: canvasImageSchema,
13027
13371
  supportsEffects: true
13028
13372
  });
@@ -13040,11 +13384,11 @@ var IFrameRefForwarding = ({
13040
13384
  retries: delayRenderRetries ?? undefined,
13041
13385
  timeoutInMilliseconds: delayRenderTimeoutInMilliseconds ?? undefined
13042
13386
  }));
13043
- const didLoad = useCallback17((e) => {
13387
+ const didLoad = useCallback18((e) => {
13044
13388
  continueRender2(handle);
13045
13389
  onLoad?.(e);
13046
13390
  }, [handle, onLoad, continueRender2]);
13047
- const didGetError = useCallback17((e) => {
13391
+ const didGetError = useCallback18((e) => {
13048
13392
  continueRender2(handle);
13049
13393
  if (onError) {
13050
13394
  onError(e);
@@ -13086,7 +13430,7 @@ var ImgContent = ({
13086
13430
  if (!_propsValid) {
13087
13431
  throw new Error("typecheck error");
13088
13432
  }
13089
- const imageCallbackRef = useCallback18((img) => {
13433
+ const imageCallbackRef = useCallback19((img) => {
13090
13434
  imageRef.current = img;
13091
13435
  refForOutline.current = img;
13092
13436
  if (typeof ref === "function") {
@@ -13096,7 +13440,7 @@ var ImgContent = ({
13096
13440
  }
13097
13441
  }, [ref, refForOutline]);
13098
13442
  const actualSrc = usePreload(src);
13099
- const retryIn = useCallback18((timeout) => {
13443
+ const retryIn = useCallback19((timeout) => {
13100
13444
  if (!imageRef.current) {
13101
13445
  return;
13102
13446
  }
@@ -13114,7 +13458,7 @@ var ImgContent = ({
13114
13458
  }, timeout);
13115
13459
  }, []);
13116
13460
  const { delayRender: delayRender2, continueRender: continueRender2, cancelRender: cancelRender2 } = useDelayRender();
13117
- const didGetError = useCallback18((e) => {
13461
+ const didGetError = useCallback19((e) => {
13118
13462
  if (!errors.current) {
13119
13463
  return;
13120
13464
  }
@@ -13224,6 +13568,7 @@ var NativeImgInner = ({
13224
13568
  src,
13225
13569
  from,
13226
13570
  durationInFrames,
13571
+ freeze,
13227
13572
  _experimentalControls: controls,
13228
13573
  _remotionInternalRefForOutline: refForOutline,
13229
13574
  ...props2
@@ -13235,8 +13580,9 @@ var NativeImgInner = ({
13235
13580
  layout: "none",
13236
13581
  from: from ?? 0,
13237
13582
  durationInFrames: durationInFrames ?? Infinity,
13583
+ freeze,
13238
13584
  _remotionInternalStack: stack,
13239
- _remotionInternalDocumentationLink: name === undefined ? "https://www.remotion.dev/docs/img" : undefined,
13585
+ _remotionInternalDocumentationLink: "https://www.remotion.dev/docs/img",
13240
13586
  _remotionInternalIsMedia: { type: "image", src },
13241
13587
  name: name ?? "<Img>",
13242
13588
  _experimentalControls: controls,
@@ -13254,6 +13600,7 @@ var CanvasImageWithPrivateProps = CanvasImage;
13254
13600
  var imgSchema = {
13255
13601
  durationInFrames: durationInFramesField,
13256
13602
  from: fromField,
13603
+ freeze: freezeField,
13257
13604
  ...sequenceVisualStyleSchema,
13258
13605
  hidden: hiddenField
13259
13606
  };
@@ -13309,6 +13656,7 @@ var ImgInner = ({
13309
13656
  src,
13310
13657
  from,
13311
13658
  durationInFrames,
13659
+ freeze,
13312
13660
  _experimentalControls: controls,
13313
13661
  width,
13314
13662
  height,
@@ -13333,6 +13681,7 @@ var ImgInner = ({
13333
13681
  src,
13334
13682
  from,
13335
13683
  durationInFrames,
13684
+ freeze,
13336
13685
  _experimentalControls: controls,
13337
13686
  width,
13338
13687
  height,
@@ -13374,11 +13723,12 @@ var ImgInner = ({
13374
13723
  delayRenderTimeoutInMilliseconds,
13375
13724
  from,
13376
13725
  durationInFrames,
13726
+ freeze,
13377
13727
  hidden,
13378
13728
  name: name ?? "<Img>",
13379
13729
  showInTimeline,
13380
13730
  stack,
13381
- _remotionInternalDocumentationLink: name === undefined ? "https://www.remotion.dev/docs/img" : undefined,
13731
+ _remotionInternalDocumentationLink: "https://www.remotion.dev/docs/img",
13382
13732
  _experimentalControls: controls,
13383
13733
  _remotionInternalRefForOutline: refForOutline,
13384
13734
  ...canvasProps
@@ -13386,6 +13736,7 @@ var ImgInner = ({
13386
13736
  };
13387
13737
  var Img = wrapInSchema({
13388
13738
  Component: ImgInner,
13739
+ componentIdentity: "dev.remotion.remotion.Img",
13389
13740
  schema: imgSchema,
13390
13741
  supportsEffects: true
13391
13742
  });
@@ -13393,6 +13744,7 @@ addSequenceStackTraces(Img);
13393
13744
  var interactiveElementSchema = {
13394
13745
  durationInFrames: durationInFramesField,
13395
13746
  from: fromField,
13747
+ freeze: freezeField,
13396
13748
  ...sequenceVisualStyleSchema,
13397
13749
  hidden: hiddenField
13398
13750
  };
@@ -13408,6 +13760,7 @@ var makeInteractiveElement = (tag, displayName) => {
13408
13760
  const {
13409
13761
  durationInFrames,
13410
13762
  from,
13763
+ freeze,
13411
13764
  hidden,
13412
13765
  name,
13413
13766
  showInTimeline,
@@ -13416,7 +13769,7 @@ var makeInteractiveElement = (tag, displayName) => {
13416
13769
  ...props2
13417
13770
  } = propsWithControls;
13418
13771
  const refForOutline = useRef25(null);
13419
- const callbackRef = useCallback19((element) => {
13772
+ const callbackRef = useCallback20((element) => {
13420
13773
  refForOutline.current = element;
13421
13774
  setRef(ref, element);
13422
13775
  }, [ref]);
@@ -13424,11 +13777,13 @@ var makeInteractiveElement = (tag, displayName) => {
13424
13777
  layout: "none",
13425
13778
  from: from ?? 0,
13426
13779
  durationInFrames: durationInFrames ?? Infinity,
13780
+ freeze,
13427
13781
  hidden,
13428
13782
  name: name ?? displayName,
13429
13783
  showInTimeline: showInTimeline ?? true,
13430
13784
  _experimentalControls,
13431
13785
  _remotionInternalStack: stack,
13786
+ _remotionInternalDocumentationLink: "https://www.remotion.dev/docs/interactive",
13432
13787
  _remotionInternalRefForOutline: refForOutline,
13433
13788
  children: React29.createElement(tag, {
13434
13789
  ...props2,
@@ -13439,6 +13794,7 @@ var makeInteractiveElement = (tag, displayName) => {
13439
13794
  Inner.displayName = displayName;
13440
13795
  const Wrapped = wrapInSchema({
13441
13796
  Component: Inner,
13797
+ componentIdentity: `dev.remotion.remotion.${displayName.slice(1, -1)}`,
13442
13798
  schema: interactiveElementSchema,
13443
13799
  supportsEffects: false
13444
13800
  });
@@ -13495,14 +13851,14 @@ var CompositionManagerProvider = ({
13495
13851
  const [canvasContent, setCanvasContent] = useState18(initialCanvasContent);
13496
13852
  const [compositions, setCompositions] = useState18(initialCompositions);
13497
13853
  const currentcompositionsRef = useRef26(compositions);
13498
- const updateCompositions = useCallback20((updateComps) => {
13854
+ const updateCompositions = useCallback21((updateComps) => {
13499
13855
  setCompositions((comps) => {
13500
13856
  const updated = updateComps(comps);
13501
13857
  currentcompositionsRef.current = updated;
13502
13858
  return updated;
13503
13859
  });
13504
13860
  }, []);
13505
- const registerComposition = useCallback20((comp) => {
13861
+ const registerComposition = useCallback21((comp) => {
13506
13862
  updateCompositions((comps) => {
13507
13863
  if (comps.find((c2) => c2.id === comp.id)) {
13508
13864
  throw new Error(`Multiple composition with id ${comp.id} are registered.`);
@@ -13510,12 +13866,12 @@ var CompositionManagerProvider = ({
13510
13866
  return [...comps, comp];
13511
13867
  });
13512
13868
  }, [updateCompositions]);
13513
- const unregisterComposition = useCallback20((id) => {
13869
+ const unregisterComposition = useCallback21((id) => {
13514
13870
  setCompositions((comps) => {
13515
13871
  return comps.filter((c2) => c2.id !== id);
13516
13872
  });
13517
13873
  }, []);
13518
- const registerFolder = useCallback20((name, parent, nonce, stack) => {
13874
+ const registerFolder = useCallback21((name, parent, nonce, stack) => {
13519
13875
  setFolders((prevFolders) => {
13520
13876
  return [
13521
13877
  ...prevFolders,
@@ -13528,7 +13884,7 @@ var CompositionManagerProvider = ({
13528
13884
  ];
13529
13885
  });
13530
13886
  }, []);
13531
- const unregisterFolder = useCallback20((name, parent) => {
13887
+ const unregisterFolder = useCallback21((name, parent) => {
13532
13888
  setFolders((prevFolders) => {
13533
13889
  return prevFolders.filter((p) => !(p.name === name && p.parent === parent));
13534
13890
  });
@@ -14167,7 +14523,7 @@ var OffthreadVideoForRendering = ({
14167
14523
  continueRender2,
14168
14524
  delayRender2
14169
14525
  ]);
14170
- const onErr = useCallback21(() => {
14526
+ const onErr = useCallback22(() => {
14171
14527
  if (onError) {
14172
14528
  onError?.(new Error("Failed to load image with src " + imageSrc));
14173
14529
  } else {
@@ -14177,7 +14533,7 @@ var OffthreadVideoForRendering = ({
14177
14533
  const className = useMemo35(() => {
14178
14534
  return [OBJECTFIT_CONTAIN_CLASS_NAME, props2.className].filter(truthy).join(" ");
14179
14535
  }, [props2.className]);
14180
- const onImageFrame = useCallback21((img) => {
14536
+ const onImageFrame = useCallback22((img) => {
14181
14537
  if (onVideoFrame) {
14182
14538
  onVideoFrame(img);
14183
14539
  }
@@ -14310,7 +14666,7 @@ var VideoForDevelopmentRefForwardingFunction = (props2, ref) => {
14310
14666
  mediaVolume
14311
14667
  });
14312
14668
  warnAboutTooHighVolume(userPreferredVolume);
14313
- const getStack = useCallback22(() => {
14669
+ const getStack = useCallback23(() => {
14314
14670
  return _remotionInternalStack ?? null;
14315
14671
  }, [_remotionInternalStack]);
14316
14672
  useMediaInTimeline({
@@ -14326,7 +14682,7 @@ var VideoForDevelopmentRefForwardingFunction = (props2, ref) => {
14326
14682
  premountDisplay: parentSequence?.premountDisplay ?? null,
14327
14683
  postmountDisplay: parentSequence?.postmountDisplay ?? null,
14328
14684
  loopDisplay: undefined,
14329
- documentationLink: name === undefined ? onlyWarnForMediaSeekingError ? "https://www.remotion.dev/docs/offthreadvideo" : "https://www.remotion.dev/docs/html5-video" : null,
14685
+ documentationLink: onlyWarnForMediaSeekingError ? "https://www.remotion.dev/docs/offthreadvideo" : "https://www.remotion.dev/docs/html5-video",
14330
14686
  refForOutline: videoRef
14331
14687
  });
14332
14688
  useMediaPlayback({
@@ -14457,6 +14813,7 @@ var VideoForDevelopmentRefForwardingFunction = (props2, ref) => {
14457
14813
  isClientSideRendering: false
14458
14814
  });
14459
14815
  return /* @__PURE__ */ jsx34("video", {
14816
+ ...nativeProps,
14460
14817
  ref: videoRef,
14461
14818
  muted: muted || mediaMuted || userPreferredVolume <= 0,
14462
14819
  playsInline: true,
@@ -14465,7 +14822,7 @@ var VideoForDevelopmentRefForwardingFunction = (props2, ref) => {
14465
14822
  style: actualStyle,
14466
14823
  disableRemotePlayback: true,
14467
14824
  crossOrigin: crossOriginValue,
14468
- ...nativeProps
14825
+ controls: false
14469
14826
  });
14470
14827
  };
14471
14828
  var VideoForPreview = forwardRef13(VideoForDevelopmentRefForwardingFunction);
@@ -14485,7 +14842,7 @@ var InnerOffthreadVideo = (props2) => {
14485
14842
  if (environment.isClientSideRendering) {
14486
14843
  throw new Error("<OffthreadVideo> is not supported in @remotion/web-renderer. Use <Video> from @remotion/media instead. See https://remotion.dev/docs/client-side-rendering/limitations");
14487
14844
  }
14488
- const onDuration = useCallback23(() => {
14845
+ const onDuration = useCallback24(() => {
14489
14846
  return;
14490
14847
  }, []);
14491
14848
  if (typeof props2.src !== "string") {
@@ -14855,40 +15212,17 @@ var Internals = {
14855
15212
  makeStaticDragOverride,
14856
15213
  makeKeyframedDragOverride,
14857
15214
  resolveDragOverrideValue,
14858
- getStaticDragOverrideValue,
14859
- OverrideIdsToNodePathsGettersContext,
14860
- OverrideIdsToNodePathsSettersContext,
14861
- findPropsToDelete,
14862
- makeSequencePropsSubscriptionKey,
14863
- getPropStatusesCtx,
14864
- getEffectPropStatusesCtx,
14865
- hiddenField,
14866
- durationInFramesField,
14867
- fromField
14868
- };
14869
- var validateFrame = ({
14870
- allowFloats,
14871
- durationInFrames,
14872
- frame
14873
- }) => {
14874
- if (typeof frame === "undefined") {
14875
- throw new TypeError(`Argument missing for parameter "frame"`);
14876
- }
14877
- if (typeof frame !== "number") {
14878
- throw new TypeError(`Argument passed for "frame" is not a number: ${frame}`);
14879
- }
14880
- if (!Number.isFinite(frame)) {
14881
- throw new RangeError(`Frame ${frame} is not finite`);
14882
- }
14883
- if (frame % 1 !== 0 && !allowFloats) {
14884
- throw new RangeError(`Argument for frame must be an integer, but got ${frame}`);
14885
- }
14886
- if (frame < 0 && frame < -durationInFrames) {
14887
- throw new RangeError(`Cannot use frame ${frame}: Duration of composition is ${durationInFrames}, therefore the lowest frame that can be rendered is ${-durationInFrames}`);
14888
- }
14889
- if (frame > durationInFrames - 1) {
14890
- throw new RangeError(`Cannot use frame ${frame}: Duration of composition is ${durationInFrames}, therefore the highest frame that can be rendered is ${durationInFrames - 1}`);
14891
- }
15215
+ getStaticDragOverrideValue,
15216
+ OverrideIdsToNodePathsGettersContext,
15217
+ OverrideIdsToNodePathsSettersContext,
15218
+ findPropsToDelete,
15219
+ makeSequencePropsSubscriptionKey,
15220
+ getPropStatusesCtx,
15221
+ getEffectPropStatusesCtx,
15222
+ hiddenField,
15223
+ durationInFramesField,
15224
+ freezeField,
15225
+ fromField
14892
15226
  };
14893
15227
  var flattenChildren = (children) => {
14894
15228
  const childrenArray = React40.Children.toArray(children);
@@ -14962,257 +15296,24 @@ var SeriesInner = (props2) => {
14962
15296
  });
14963
15297
  }, [props2.children]);
14964
15298
  return /* @__PURE__ */ jsx37(IsInsideSeriesContainer, {
14965
- children: /* @__PURE__ */ jsx37(Sequence, {
14966
- layout: "none",
14967
- name: "<Series>",
14968
- _remotionInternalDocumentationLink: "https://www.remotion.dev/docs/series",
14969
- ...props2,
14970
- children: childrenValue
14971
- })
14972
- });
14973
- };
14974
- var Series = Object.assign(wrapInSchema({
14975
- Component: SeriesInner,
14976
- schema: sequenceSchemaDefaultLayoutNone,
14977
- supportsEffects: false
14978
- }), {
14979
- Sequence: SeriesSequence
14980
- });
14981
- addSequenceStackTraces(Series);
14982
- var validateSpringDuration = (dur) => {
14983
- if (typeof dur === "undefined") {
14984
- return;
14985
- }
14986
- if (typeof dur !== "number") {
14987
- throw new TypeError(`A "duration" of a spring must be a "number" but is "${typeof dur}"`);
14988
- }
14989
- if (Number.isNaN(dur)) {
14990
- throw new TypeError('A "duration" of a spring is NaN, which it must not be');
14991
- }
14992
- if (!Number.isFinite(dur)) {
14993
- throw new TypeError('A "duration" of a spring must be finite, but is ' + dur);
14994
- }
14995
- if (dur <= 0) {
14996
- throw new TypeError('A "duration" of a spring must be positive, but is ' + dur);
14997
- }
14998
- };
14999
- var defaultSpringConfig = {
15000
- damping: 10,
15001
- mass: 1,
15002
- stiffness: 100,
15003
- overshootClamping: false
15004
- };
15005
- var advanceCache = {};
15006
- function advance({
15007
- animation,
15008
- now,
15009
- config
15010
- }) {
15011
- const { toValue: toValue2, lastTimestamp, current, velocity } = animation;
15012
- const deltaTime = Math.min(now - lastTimestamp, 64);
15013
- if (config.damping <= 0) {
15014
- throw new Error("Spring damping must be greater than 0, otherwise the spring() animation will never end, causing an infinite loop.");
15015
- }
15016
- const c2 = config.damping;
15017
- const m = config.mass;
15018
- const k = config.stiffness;
15019
- const cacheKey = [
15020
- toValue2,
15021
- lastTimestamp,
15022
- current,
15023
- velocity,
15024
- c2,
15025
- m,
15026
- k,
15027
- now
15028
- ].join("-");
15029
- if (advanceCache[cacheKey]) {
15030
- return advanceCache[cacheKey];
15031
- }
15032
- const v0 = -velocity;
15033
- const x0 = toValue2 - current;
15034
- const zeta = c2 / (2 * Math.sqrt(k * m));
15035
- const omega0 = Math.sqrt(k / m);
15036
- const omega1 = omega0 * Math.sqrt(1 - zeta ** 2);
15037
- const t = deltaTime / 1000;
15038
- const sin1 = Math.sin(omega1 * t);
15039
- const cos1 = Math.cos(omega1 * t);
15040
- const underDampedEnvelope = Math.exp(-zeta * omega0 * t);
15041
- const underDampedFrag1 = underDampedEnvelope * (sin1 * ((v0 + zeta * omega0 * x0) / omega1) + x0 * cos1);
15042
- const underDampedPosition = toValue2 - underDampedFrag1;
15043
- const underDampedVelocity = zeta * omega0 * underDampedFrag1 - underDampedEnvelope * (cos1 * (v0 + zeta * omega0 * x0) - omega1 * x0 * sin1);
15044
- const criticallyDampedEnvelope = Math.exp(-omega0 * t);
15045
- const criticallyDampedPosition = toValue2 - criticallyDampedEnvelope * (x0 + (v0 + omega0 * x0) * t);
15046
- const criticallyDampedVelocity = criticallyDampedEnvelope * (v0 * (t * omega0 - 1) + t * x0 * omega0 * omega0);
15047
- const animationNode = {
15048
- toValue: toValue2,
15049
- prevPosition: current,
15050
- lastTimestamp: now,
15051
- current: zeta < 1 ? underDampedPosition : criticallyDampedPosition,
15052
- velocity: zeta < 1 ? underDampedVelocity : criticallyDampedVelocity
15053
- };
15054
- advanceCache[cacheKey] = animationNode;
15055
- return animationNode;
15056
- }
15057
- var calculationCache = {};
15058
- function springCalculation({
15059
- frame,
15060
- fps,
15061
- config = {}
15062
- }) {
15063
- const from = 0;
15064
- const to = 1;
15065
- const cacheKey = [
15066
- frame,
15067
- fps,
15068
- config.damping,
15069
- config.mass,
15070
- config.overshootClamping,
15071
- config.stiffness
15072
- ].join("-");
15073
- if (calculationCache[cacheKey]) {
15074
- return calculationCache[cacheKey];
15075
- }
15076
- let animation = {
15077
- lastTimestamp: 0,
15078
- current: from,
15079
- toValue: to,
15080
- velocity: 0,
15081
- prevPosition: 0
15082
- };
15083
- const frameClamped = Math.max(0, frame);
15084
- const unevenRest = frameClamped % 1;
15085
- for (let f = 0;f <= Math.floor(frameClamped); f++) {
15086
- if (f === Math.floor(frameClamped)) {
15087
- f += unevenRest;
15088
- }
15089
- const time = f / fps * 1000;
15090
- animation = advance({
15091
- animation,
15092
- now: time,
15093
- config: {
15094
- ...defaultSpringConfig,
15095
- ...config
15096
- }
15097
- });
15098
- }
15099
- calculationCache[cacheKey] = animation;
15100
- return animation;
15101
- }
15102
- var cache = new Map;
15103
- function measureSpring({
15104
- fps,
15105
- config = {},
15106
- threshold = 0.005
15107
- }) {
15108
- if (typeof threshold !== "number") {
15109
- throw new TypeError(`threshold must be a number, got ${threshold} of type ${typeof threshold}`);
15110
- }
15111
- if (threshold === 0) {
15112
- return Infinity;
15113
- }
15114
- if (threshold === 1) {
15115
- return 0;
15116
- }
15117
- if (isNaN(threshold)) {
15118
- throw new TypeError("Threshold is NaN");
15119
- }
15120
- if (!Number.isFinite(threshold)) {
15121
- throw new TypeError("Threshold is not finite");
15122
- }
15123
- if (threshold < 0) {
15124
- throw new TypeError("Threshold is below 0");
15125
- }
15126
- const cacheKey = [
15127
- fps,
15128
- config.damping,
15129
- config.mass,
15130
- config.overshootClamping,
15131
- config.stiffness,
15132
- threshold
15133
- ].join("-");
15134
- if (cache.has(cacheKey)) {
15135
- return cache.get(cacheKey);
15136
- }
15137
- validateFps(fps, "to the measureSpring() function", false);
15138
- let frame = 0;
15139
- let finishedFrame = 0;
15140
- const calc = () => {
15141
- return springCalculation({
15142
- fps,
15143
- frame,
15144
- config
15145
- });
15146
- };
15147
- let animation = calc();
15148
- const calcDifference = () => {
15149
- return Math.abs(animation.current - animation.toValue);
15150
- };
15151
- let difference = calcDifference();
15152
- while (difference >= threshold) {
15153
- frame++;
15154
- animation = calc();
15155
- difference = calcDifference();
15156
- }
15157
- finishedFrame = frame;
15158
- for (let i = 0;i < 20; i++) {
15159
- frame++;
15160
- animation = calc();
15161
- difference = calcDifference();
15162
- if (difference >= threshold) {
15163
- i = 0;
15164
- finishedFrame = frame + 1;
15165
- }
15166
- }
15167
- cache.set(cacheKey, finishedFrame);
15168
- return finishedFrame;
15169
- }
15170
- function spring({
15171
- frame: passedFrame,
15172
- fps,
15173
- config = {},
15174
- from = 0,
15175
- to = 1,
15176
- durationInFrames: passedDurationInFrames,
15177
- durationRestThreshold,
15178
- delay = 0,
15179
- reverse = false
15180
- }) {
15181
- validateSpringDuration(passedDurationInFrames);
15182
- validateFrame({
15183
- frame: passedFrame,
15184
- durationInFrames: Infinity,
15185
- allowFloats: true
15186
- });
15187
- validateFps(fps, "to spring()", false);
15188
- const needsToCalculateNaturalDuration = reverse || typeof passedDurationInFrames !== "undefined";
15189
- const naturalDuration = needsToCalculateNaturalDuration ? measureSpring({
15190
- fps,
15191
- config,
15192
- threshold: durationRestThreshold
15193
- }) : undefined;
15194
- const naturalDurationGetter = needsToCalculateNaturalDuration ? {
15195
- get: () => naturalDuration
15196
- } : {
15197
- get: () => {
15198
- throw new Error("did not calculate natural duration, this is an error with Remotion. Please report");
15199
- }
15200
- };
15201
- const reverseProcessed = reverse ? (passedDurationInFrames ?? naturalDurationGetter.get()) - passedFrame : passedFrame;
15202
- const delayProcessed = reverseProcessed + (reverse ? delay : -delay);
15203
- const durationProcessed = passedDurationInFrames === undefined ? delayProcessed : delayProcessed / (passedDurationInFrames / naturalDurationGetter.get());
15204
- if (passedDurationInFrames && delayProcessed > passedDurationInFrames) {
15205
- return to;
15206
- }
15207
- const spr = springCalculation({
15208
- fps,
15209
- frame: durationProcessed,
15210
- config
15299
+ children: /* @__PURE__ */ jsx37(Sequence, {
15300
+ layout: "none",
15301
+ name: "<Series>",
15302
+ _remotionInternalDocumentationLink: "https://www.remotion.dev/docs/series",
15303
+ ...props2,
15304
+ children: childrenValue
15305
+ })
15211
15306
  });
15212
- const inner = config.overshootClamping ? to >= from ? Math.min(spr.current, to) : Math.max(spr.current, to) : spr.current;
15213
- const interpolated = from === 0 && to === 1 ? inner : interpolate(inner, [0, 1], [from, to]);
15214
- return interpolated;
15215
- }
15307
+ };
15308
+ var Series = Object.assign(wrapInSchema({
15309
+ Component: SeriesInner,
15310
+ componentIdentity: "dev.remotion.remotion.Series",
15311
+ schema: sequenceSchemaDefaultLayoutNone,
15312
+ supportsEffects: false
15313
+ }), {
15314
+ Sequence: SeriesSequence
15315
+ });
15316
+ addSequenceStackTraces(Series);
15216
15317
  var problematicCharacters = {
15217
15318
  "%3A": ":",
15218
15319
  "%2F": "/",
@@ -15671,7 +15772,7 @@ var VideoForwardingFunction = (props2, ref) => {
15671
15772
  throw new TypeError(`The \`<Html5Video>\` tag requires a string for \`src\`, but got ${JSON.stringify(props2.src)} instead.`);
15672
15773
  }
15673
15774
  const preloadedSrc = usePreload(props2.src);
15674
- const onDuration = useCallback24((src, durationInSeconds) => {
15775
+ const onDuration = useCallback25((src, durationInSeconds) => {
15675
15776
  setDurations({ type: "got-duration", durationInSeconds, src });
15676
15777
  }, [setDurations]);
15677
15778
  const durationFetched = durations[getAbsoluteSrc(preloadedSrc)] ?? durations[getAbsoluteSrc(props2.src)];
@@ -15781,7 +15882,7 @@ addSequenceStackTraces(Composition);
15781
15882
  addSequenceStackTraces(Folder);
15782
15883
 
15783
15884
  // ../shapes/dist/esm/index.mjs
15784
- import React, { useCallback as useCallback25, useMemo as useMemo40, useRef as useRef29 } from "react";
15885
+ import React, { useCallback as useCallback26, useMemo as useMemo40, useRef as useRef29 } from "react";
15785
15886
  import { version } from "react-dom";
15786
15887
  import { jsx as jsx40, jsxs as jsxs4 } from "react/jsx-runtime";
15787
15888
  import { jsx as jsx210 } from "react/jsx-runtime";
@@ -15793,6 +15894,7 @@ import { jsx as jsx72 } from "react/jsx-runtime";
15793
15894
  import { jsx as jsx82 } from "react/jsx-runtime";
15794
15895
  import { jsx as jsx92 } from "react/jsx-runtime";
15795
15896
  import { jsx as jsx102 } from "react/jsx-runtime";
15897
+ import { jsx as jsx112 } from "react/jsx-runtime";
15796
15898
  var unitDir = (from, to) => {
15797
15899
  const dx = to[0] - from[0];
15798
15900
  const dy = to[1] - from[1];
@@ -15951,6 +16053,7 @@ var RenderSvg = ({
15951
16053
  pixelDensity,
15952
16054
  durationInFrames,
15953
16055
  from,
16056
+ freeze,
15954
16057
  hidden,
15955
16058
  name,
15956
16059
  showInTimeline,
@@ -15971,10 +16074,10 @@ var RenderSvg = ({
15971
16074
  };
15972
16075
  }, [pathStyle]);
15973
16076
  const outlineRef = useRef29(null);
15974
- const setSvgRef = useCallback25((node) => {
16077
+ const setSvgRef = useCallback26((node) => {
15975
16078
  outlineRef.current = node;
15976
16079
  }, []);
15977
- const setCanvasRef = useCallback25((canvas) => {
16080
+ const setCanvasRef = useCallback26((canvas) => {
15978
16081
  outlineRef.current = canvas;
15979
16082
  }, []);
15980
16083
  const memoizedEffectDefinitions = Internals.useMemoizedEffectDefinitions(effects);
@@ -16059,6 +16162,7 @@ var RenderSvg = ({
16059
16162
  return /* @__PURE__ */ jsx40(Sequence, {
16060
16163
  layout: "none",
16061
16164
  from,
16165
+ freeze,
16062
16166
  hidden,
16063
16167
  showInTimeline,
16064
16168
  _experimentalControls: controls,
@@ -16109,56 +16213,477 @@ var colorField = ({
16109
16213
  description
16110
16214
  };
16111
16215
  };
16112
- var enumField = ({
16113
- defaultValue,
16114
- description,
16115
- variants
16216
+ var enumField = ({
16217
+ defaultValue,
16218
+ description,
16219
+ variants
16220
+ }) => {
16221
+ return {
16222
+ type: "enum",
16223
+ default: defaultValue,
16224
+ description,
16225
+ variants: Object.fromEntries(variants.map((variant) => [variant, {}]))
16226
+ };
16227
+ };
16228
+ var makeShapeSchema = (shapeFields) => {
16229
+ return {
16230
+ from: Internals.sequenceSchema.from,
16231
+ freeze: Internals.sequenceSchema.freeze,
16232
+ durationInFrames: Internals.sequenceSchema.durationInFrames,
16233
+ ...shapeFields,
16234
+ fill: colorField({
16235
+ defaultValue: "#0b84ff",
16236
+ description: "Fill"
16237
+ }),
16238
+ ...Internals.sequenceVisualStyleSchema,
16239
+ hidden: Internals.sequenceSchema.hidden
16240
+ };
16241
+ };
16242
+ var arrowSchema = makeShapeSchema({
16243
+ length: numberField({
16244
+ defaultValue: 300,
16245
+ description: "Length",
16246
+ min: 0
16247
+ }),
16248
+ headWidth: numberField({
16249
+ defaultValue: 185,
16250
+ description: "Head Width",
16251
+ min: 0
16252
+ }),
16253
+ headLength: numberField({
16254
+ defaultValue: 120,
16255
+ description: "Head Length",
16256
+ min: 0
16257
+ }),
16258
+ shaftWidth: numberField({
16259
+ defaultValue: 80,
16260
+ description: "Shaft Width",
16261
+ min: 0
16262
+ }),
16263
+ direction: enumField({
16264
+ defaultValue: "right",
16265
+ description: "Direction",
16266
+ variants: ["right", "left", "up", "down"]
16267
+ }),
16268
+ cornerRadius: numberField({
16269
+ defaultValue: 0,
16270
+ description: "Corner Radius",
16271
+ min: 0
16272
+ })
16273
+ });
16274
+ var ArrowInner = ({
16275
+ length: length2,
16276
+ headWidth,
16277
+ headLength,
16278
+ shaftWidth,
16279
+ direction,
16280
+ cornerRadius,
16281
+ ...props
16282
+ }) => {
16283
+ return /* @__PURE__ */ jsx210(RenderSvg, {
16284
+ defaultName: "<Arrow>",
16285
+ documentationLink: "https://www.remotion.dev/docs/shapes/arrow",
16286
+ ...makeArrow({
16287
+ length: length2,
16288
+ headWidth,
16289
+ headLength,
16290
+ shaftWidth,
16291
+ direction,
16292
+ cornerRadius
16293
+ }),
16294
+ ...props
16295
+ });
16296
+ };
16297
+ var Arrow = Internals.wrapInSchema({
16298
+ Component: ArrowInner,
16299
+ componentIdentity: "dev.remotion.shapes.Arrow",
16300
+ schema: arrowSchema,
16301
+ supportsEffects: true
16302
+ });
16303
+ Internals.addSequenceStackTraces(Arrow);
16304
+ var shortenVector = (vector, radius) => {
16305
+ const [x, y] = vector;
16306
+ const currentLength = Math.sqrt(x * x + y * y);
16307
+ const scalingFactor = (currentLength - radius) / currentLength;
16308
+ return [x * scalingFactor, y * scalingFactor];
16309
+ };
16310
+ var scaleVectorToLength = (vector, length2) => {
16311
+ const [x, y] = vector;
16312
+ const currentLength = Math.sqrt(x * x + y * y);
16313
+ const scalingFactor = length2 / currentLength;
16314
+ return [x * scalingFactor, y * scalingFactor];
16315
+ };
16316
+ var joinPoints = (points, {
16317
+ edgeRoundness,
16318
+ cornerRadius,
16319
+ roundCornerStrategy
16320
+ }) => {
16321
+ return points.map(([x, y], i) => {
16322
+ const prevPointIndex = i === 0 ? points.length - 2 : i - 1;
16323
+ const prevPoint = points[prevPointIndex];
16324
+ const nextPointIndex = i === points.length - 1 ? 1 : i + 1;
16325
+ const nextPoint = points[nextPointIndex];
16326
+ const middleOfLine = [(x + nextPoint[0]) / 2, (y + nextPoint[1]) / 2];
16327
+ const prevPointMiddleOfLine = [
16328
+ (x + prevPoint[0]) / 2,
16329
+ (y + prevPoint[1]) / 2
16330
+ ];
16331
+ const prevVector = [x - prevPoint[0], y - prevPoint[1]];
16332
+ const nextVector = [nextPoint[0] - x, nextPoint[1] - y];
16333
+ if (i === 0) {
16334
+ if (edgeRoundness !== null) {
16335
+ return [
16336
+ {
16337
+ type: "M",
16338
+ x: middleOfLine[0],
16339
+ y: middleOfLine[1]
16340
+ }
16341
+ ];
16342
+ }
16343
+ if (cornerRadius !== 0) {
16344
+ const computeRadius = shortenVector(nextVector, cornerRadius);
16345
+ return [
16346
+ {
16347
+ type: "M",
16348
+ x: computeRadius[0] + x,
16349
+ y: computeRadius[1] + y
16350
+ }
16351
+ ];
16352
+ }
16353
+ return [
16354
+ {
16355
+ type: "M",
16356
+ x,
16357
+ y
16358
+ }
16359
+ ];
16360
+ }
16361
+ if (cornerRadius && edgeRoundness !== null) {
16362
+ throw new Error(`"cornerRadius" and "edgeRoundness" cannot be specified at the same time.`);
16363
+ }
16364
+ if (edgeRoundness === null) {
16365
+ if (cornerRadius === 0) {
16366
+ return [
16367
+ {
16368
+ type: "L",
16369
+ x,
16370
+ y
16371
+ }
16372
+ ];
16373
+ }
16374
+ const prevVectorMinusRadius = shortenVector(prevVector, cornerRadius);
16375
+ const prevVectorLength = scaleVectorToLength(prevVector, cornerRadius);
16376
+ const nextVectorMinusRadius = scaleVectorToLength(nextVector, cornerRadius);
16377
+ const firstDraw = [
16378
+ prevPoint[0] + prevVectorMinusRadius[0],
16379
+ prevPoint[1] + prevVectorMinusRadius[1]
16380
+ ];
16381
+ return [
16382
+ {
16383
+ type: "L",
16384
+ x: firstDraw[0],
16385
+ y: firstDraw[1]
16386
+ },
16387
+ roundCornerStrategy === "arc" ? {
16388
+ type: "a",
16389
+ rx: cornerRadius,
16390
+ ry: cornerRadius,
16391
+ xAxisRotation: 0,
16392
+ dx: prevVectorLength[0] + nextVectorMinusRadius[0],
16393
+ dy: prevVectorLength[1] + nextVectorMinusRadius[1],
16394
+ largeArcFlag: false,
16395
+ sweepFlag: true
16396
+ } : {
16397
+ type: "C",
16398
+ x: firstDraw[0] + prevVectorLength[0] + nextVectorMinusRadius[0],
16399
+ y: firstDraw[1] + prevVectorLength[1] + nextVectorMinusRadius[1],
16400
+ cp1x: x,
16401
+ cp1y: y,
16402
+ cp2x: x,
16403
+ cp2y: y
16404
+ }
16405
+ ];
16406
+ }
16407
+ const controlPoint1 = [
16408
+ prevPointMiddleOfLine[0] + prevVector[0] * edgeRoundness * 0.5,
16409
+ prevPointMiddleOfLine[1] + prevVector[1] * edgeRoundness * 0.5
16410
+ ];
16411
+ const controlPoint2 = [
16412
+ middleOfLine[0] - nextVector[0] * edgeRoundness * 0.5,
16413
+ middleOfLine[1] - nextVector[1] * edgeRoundness * 0.5
16414
+ ];
16415
+ return [
16416
+ {
16417
+ type: "C",
16418
+ cp1x: controlPoint1[0],
16419
+ cp1y: controlPoint1[1],
16420
+ cp2x: controlPoint2[0],
16421
+ cp2y: controlPoint2[1],
16422
+ x: middleOfLine[0],
16423
+ y: middleOfLine[1]
16424
+ }
16425
+ ];
16426
+ }).flat(1);
16427
+ };
16428
+ var ensurePositive = (name, value) => {
16429
+ if (typeof value !== "number" || value <= 0) {
16430
+ throw new Error(`"${name}" must be a positive number, got ${value}`);
16431
+ }
16432
+ };
16433
+ var pointerInterval = ({
16434
+ availableLength,
16435
+ pointerBaseWidth,
16436
+ pointerPosition
16437
+ }) => {
16438
+ const center = availableLength * pointerPosition;
16439
+ const half = pointerBaseWidth / 2;
16440
+ return {
16441
+ center,
16442
+ start: Math.max(0, center - half),
16443
+ end: Math.min(availableLength, center + half)
16444
+ };
16445
+ };
16446
+ var areSamePoint = (a2, b2) => {
16447
+ return a2[0] === b2[0] && a2[1] === b2[1];
16448
+ };
16449
+ var normalizeClosedPoints = (points) => {
16450
+ const deduplicated = points.reduce((acc, entry) => {
16451
+ const previous = acc[acc.length - 1];
16452
+ if (previous && areSamePoint(previous.point, entry.point)) {
16453
+ acc[acc.length - 1] = {
16454
+ point: previous.point,
16455
+ round: previous.round && entry.round
16456
+ };
16457
+ return acc;
16458
+ }
16459
+ return [...acc, entry];
16460
+ }, []);
16461
+ if (deduplicated.length === 0) {
16462
+ return deduplicated;
16463
+ }
16464
+ const first = deduplicated[0];
16465
+ const last = deduplicated[deduplicated.length - 1];
16466
+ if (areSamePoint(first.point, last.point)) {
16467
+ const [firstEntry, ...rest] = deduplicated;
16468
+ const withoutLast = rest.slice(0, -1);
16469
+ const mergedFirst = {
16470
+ point: firstEntry.point,
16471
+ round: firstEntry.round && last.round
16472
+ };
16473
+ return [mergedFirst, ...withoutLast, mergedFirst];
16474
+ }
16475
+ return [...deduplicated, first];
16476
+ };
16477
+ var unitDir2 = (from, to) => {
16478
+ const dx = to[0] - from[0];
16479
+ const dy = to[1] - from[1];
16480
+ const len = Math.sqrt(dx * dx + dy * dy);
16481
+ if (len === 0) {
16482
+ return [0, 0];
16483
+ }
16484
+ return [dx / len, dy / len];
16485
+ };
16486
+ var makeInstructions2 = ({
16487
+ points,
16488
+ edgeRoundness,
16489
+ cornerRadius
16490
+ }) => {
16491
+ const rawPoints = points.map((p) => p.point);
16492
+ if (edgeRoundness !== null || cornerRadius === 0) {
16493
+ return [
16494
+ ...joinPoints(rawPoints, {
16495
+ edgeRoundness,
16496
+ cornerRadius,
16497
+ roundCornerStrategy: "arc"
16498
+ }),
16499
+ {
16500
+ type: "Z"
16501
+ }
16502
+ ];
16503
+ }
16504
+ const uniquePoints = areSamePoint(points[0].point, points[points.length - 1].point) ? points.slice(0, -1) : points;
16505
+ const firstPoint = uniquePoints[0];
16506
+ const startDir = firstPoint.round ? unitDir2(uniquePoints[0].point, uniquePoints[1].point) : null;
16507
+ const startPoint = startDir ? [
16508
+ firstPoint.point[0] + startDir[0] * cornerRadius,
16509
+ firstPoint.point[1] + startDir[1] * cornerRadius
16510
+ ] : firstPoint.point;
16511
+ const instructions = [
16512
+ { type: "M", x: startPoint[0], y: startPoint[1] }
16513
+ ];
16514
+ for (let i = 1;i < uniquePoints.length; i++) {
16515
+ const current = uniquePoints[i];
16516
+ if (!current.round) {
16517
+ instructions.push({
16518
+ type: "L",
16519
+ x: current.point[0],
16520
+ y: current.point[1]
16521
+ });
16522
+ continue;
16523
+ }
16524
+ const previous = uniquePoints[i - 1].point;
16525
+ const next = uniquePoints[(i + 1) % uniquePoints.length].point;
16526
+ const incoming = unitDir2(previous, current.point);
16527
+ const outgoing = unitDir2(current.point, next);
16528
+ const arcStart = [
16529
+ current.point[0] - incoming[0] * cornerRadius,
16530
+ current.point[1] - incoming[1] * cornerRadius
16531
+ ];
16532
+ instructions.push({
16533
+ type: "L",
16534
+ x: arcStart[0],
16535
+ y: arcStart[1]
16536
+ }, {
16537
+ type: "a",
16538
+ rx: cornerRadius,
16539
+ ry: cornerRadius,
16540
+ xAxisRotation: 0,
16541
+ dx: incoming[0] * cornerRadius + outgoing[0] * cornerRadius,
16542
+ dy: incoming[1] * cornerRadius + outgoing[1] * cornerRadius,
16543
+ largeArcFlag: false,
16544
+ sweepFlag: true
16545
+ });
16546
+ }
16547
+ if (firstPoint.round) {
16548
+ const previous = uniquePoints[uniquePoints.length - 1].point;
16549
+ const incoming = unitDir2(previous, firstPoint.point);
16550
+ instructions.push({
16551
+ type: "L",
16552
+ x: firstPoint.point[0] - incoming[0] * cornerRadius,
16553
+ y: firstPoint.point[1] - incoming[1] * cornerRadius
16554
+ }, {
16555
+ type: "a",
16556
+ rx: cornerRadius,
16557
+ ry: cornerRadius,
16558
+ xAxisRotation: 0,
16559
+ dx: incoming[0] * cornerRadius + startDir[0] * cornerRadius,
16560
+ dy: incoming[1] * cornerRadius + startDir[1] * cornerRadius,
16561
+ largeArcFlag: false,
16562
+ sweepFlag: true
16563
+ });
16564
+ }
16565
+ instructions.push({ type: "Z" });
16566
+ return instructions;
16567
+ };
16568
+ var makeCallout = ({
16569
+ width = 500,
16570
+ height = 200,
16571
+ pointerLength = 40,
16572
+ pointerBaseWidth = 60,
16573
+ pointerPosition = 0.5,
16574
+ pointerDirection = "down",
16575
+ edgeRoundness = null,
16576
+ cornerRadius = 0
16116
16577
  }) => {
16117
- return {
16118
- type: "enum",
16119
- default: defaultValue,
16120
- description,
16121
- variants: Object.fromEntries(variants.map((variant) => [variant, {}]))
16578
+ ensurePositive("width", width);
16579
+ ensurePositive("height", height);
16580
+ ensurePositive("pointerLength", pointerLength);
16581
+ ensurePositive("pointerBaseWidth", pointerBaseWidth);
16582
+ if (typeof pointerPosition !== "number" || pointerPosition < 0 || pointerPosition > 1) {
16583
+ throw new Error(`"pointerPosition" must be a number between 0 and 1, got ${pointerPosition}`);
16584
+ }
16585
+ const horizontalInterval = pointerInterval({
16586
+ availableLength: width,
16587
+ pointerBaseWidth,
16588
+ pointerPosition
16589
+ });
16590
+ const verticalInterval = pointerInterval({
16591
+ availableLength: height,
16592
+ pointerBaseWidth,
16593
+ pointerPosition
16594
+ });
16595
+ const pointsByDirection = {
16596
+ up: [
16597
+ { point: [0, pointerLength], round: true },
16598
+ { point: [horizontalInterval.start, pointerLength], round: false },
16599
+ { point: [horizontalInterval.center, 0], round: false },
16600
+ { point: [horizontalInterval.end, pointerLength], round: false },
16601
+ { point: [width, pointerLength], round: true },
16602
+ { point: [width, height + pointerLength], round: true },
16603
+ { point: [0, height + pointerLength], round: true },
16604
+ { point: [0, pointerLength], round: true }
16605
+ ],
16606
+ down: [
16607
+ { point: [0, 0], round: true },
16608
+ { point: [width, 0], round: true },
16609
+ { point: [width, height], round: true },
16610
+ { point: [horizontalInterval.end, height], round: false },
16611
+ {
16612
+ point: [horizontalInterval.center, height + pointerLength],
16613
+ round: false
16614
+ },
16615
+ { point: [horizontalInterval.start, height], round: false },
16616
+ { point: [0, height], round: true },
16617
+ { point: [0, 0], round: true }
16618
+ ],
16619
+ left: [
16620
+ { point: [pointerLength, 0], round: true },
16621
+ { point: [width + pointerLength, 0], round: true },
16622
+ { point: [width + pointerLength, height], round: true },
16623
+ { point: [pointerLength, height], round: true },
16624
+ { point: [pointerLength, verticalInterval.end], round: false },
16625
+ { point: [0, verticalInterval.center], round: false },
16626
+ { point: [pointerLength, verticalInterval.start], round: false },
16627
+ { point: [pointerLength, 0], round: true }
16628
+ ],
16629
+ right: [
16630
+ { point: [0, 0], round: true },
16631
+ { point: [width, 0], round: true },
16632
+ { point: [width, verticalInterval.start], round: false },
16633
+ { point: [width + pointerLength, verticalInterval.center], round: false },
16634
+ { point: [width, verticalInterval.end], round: false },
16635
+ { point: [width, height], round: true },
16636
+ { point: [0, height], round: true },
16637
+ { point: [0, 0], round: true }
16638
+ ]
16122
16639
  };
16123
- };
16124
- var makeShapeSchema = (shapeFields) => {
16640
+ const points = normalizeClosedPoints(pointsByDirection[pointerDirection]);
16641
+ const instructions = makeInstructions2({ points, edgeRoundness, cornerRadius });
16642
+ const path = serializeInstructions(instructions);
16643
+ const shapeWidth = pointerDirection === "left" || pointerDirection === "right" ? width + pointerLength : width;
16644
+ const shapeHeight = pointerDirection === "up" || pointerDirection === "down" ? height + pointerLength : height;
16645
+ const bodyX = pointerDirection === "left" ? pointerLength : 0;
16646
+ const bodyY = pointerDirection === "up" ? pointerLength : 0;
16125
16647
  return {
16126
- from: Internals.sequenceSchema.from,
16127
- durationInFrames: Internals.sequenceSchema.durationInFrames,
16128
- ...shapeFields,
16129
- fill: colorField({
16130
- defaultValue: "#0b84ff",
16131
- description: "Fill"
16132
- }),
16133
- ...Internals.sequenceVisualStyleSchema,
16134
- hidden: Internals.sequenceSchema.hidden
16648
+ width: shapeWidth,
16649
+ height: shapeHeight,
16650
+ instructions,
16651
+ path,
16652
+ transformOrigin: `${bodyX + width / 2} ${bodyY + height / 2}`
16135
16653
  };
16136
16654
  };
16137
- var arrowSchema = makeShapeSchema({
16138
- length: numberField({
16139
- defaultValue: 300,
16140
- description: "Length",
16141
- min: 0
16655
+ var calloutSchema = makeShapeSchema({
16656
+ width: numberField({
16657
+ defaultValue: 500,
16658
+ description: "Width",
16659
+ min: 1
16142
16660
  }),
16143
- headWidth: numberField({
16144
- defaultValue: 185,
16145
- description: "Head Width",
16146
- min: 0
16661
+ height: numberField({
16662
+ defaultValue: 200,
16663
+ description: "Height",
16664
+ min: 1
16147
16665
  }),
16148
- headLength: numberField({
16149
- defaultValue: 120,
16150
- description: "Head Length",
16151
- min: 0
16666
+ pointerLength: numberField({
16667
+ defaultValue: 40,
16668
+ description: "Pointer Length",
16669
+ min: 1
16152
16670
  }),
16153
- shaftWidth: numberField({
16154
- defaultValue: 80,
16155
- description: "Shaft Width",
16156
- min: 0
16671
+ pointerBaseWidth: numberField({
16672
+ defaultValue: 60,
16673
+ description: "Pointer Base Width",
16674
+ min: 1
16157
16675
  }),
16158
- direction: enumField({
16159
- defaultValue: "right",
16160
- description: "Direction",
16161
- variants: ["right", "left", "up", "down"]
16676
+ pointerPosition: numberField({
16677
+ defaultValue: 0.5,
16678
+ description: "Pointer Position",
16679
+ min: 0,
16680
+ max: 1,
16681
+ step: 0.01
16682
+ }),
16683
+ pointerDirection: enumField({
16684
+ defaultValue: "down",
16685
+ description: "Pointer Direction",
16686
+ variants: ["up", "down", "left", "right"]
16162
16687
  }),
16163
16688
  cornerRadius: numberField({
16164
16689
  defaultValue: 0,
@@ -16166,35 +16691,40 @@ var arrowSchema = makeShapeSchema({
16166
16691
  min: 0
16167
16692
  })
16168
16693
  });
16169
- var ArrowInner = ({
16170
- length: length2,
16171
- headWidth,
16172
- headLength,
16173
- shaftWidth,
16174
- direction,
16694
+ var CalloutInner = ({
16695
+ width,
16696
+ height,
16697
+ pointerLength,
16698
+ pointerBaseWidth,
16699
+ pointerPosition,
16700
+ pointerDirection,
16701
+ edgeRoundness,
16175
16702
  cornerRadius,
16176
16703
  ...props
16177
16704
  }) => {
16178
- return /* @__PURE__ */ jsx210(RenderSvg, {
16179
- defaultName: "<Arrow>",
16180
- documentationLink: "https://www.remotion.dev/docs/shapes/arrow",
16181
- ...makeArrow({
16182
- length: length2,
16183
- headWidth,
16184
- headLength,
16185
- shaftWidth,
16186
- direction,
16705
+ return /* @__PURE__ */ jsx310(RenderSvg, {
16706
+ defaultName: "<Callout>",
16707
+ documentationLink: "https://www.remotion.dev/docs/shapes/callout",
16708
+ ...makeCallout({
16709
+ width,
16710
+ height,
16711
+ pointerLength,
16712
+ pointerBaseWidth,
16713
+ pointerPosition,
16714
+ pointerDirection,
16715
+ edgeRoundness,
16187
16716
  cornerRadius
16188
16717
  }),
16189
16718
  ...props
16190
16719
  });
16191
16720
  };
16192
- var Arrow = Internals.wrapInSchema({
16193
- Component: ArrowInner,
16194
- schema: arrowSchema,
16721
+ var Callout = Internals.wrapInSchema({
16722
+ Component: CalloutInner,
16723
+ componentIdentity: "dev.remotion.shapes.Callout",
16724
+ schema: calloutSchema,
16195
16725
  supportsEffects: true
16196
16726
  });
16197
- Internals.addSequenceStackTraces(Arrow);
16727
+ Internals.addSequenceStackTraces(Callout);
16198
16728
  var makeCircle = ({ radius }) => {
16199
16729
  const instructions = [
16200
16730
  {
@@ -16243,7 +16773,7 @@ var circleSchema = makeShapeSchema({
16243
16773
  })
16244
16774
  });
16245
16775
  var CircleInner = ({ radius, ...props }) => {
16246
- return /* @__PURE__ */ jsx310(RenderSvg, {
16776
+ return /* @__PURE__ */ jsx43(RenderSvg, {
16247
16777
  defaultName: "<Circle>",
16248
16778
  documentationLink: "https://www.remotion.dev/docs/shapes/circle",
16249
16779
  ...makeCircle({ radius }),
@@ -16252,6 +16782,7 @@ var CircleInner = ({ radius, ...props }) => {
16252
16782
  };
16253
16783
  var Circle = Internals.wrapInSchema({
16254
16784
  Component: CircleInner,
16785
+ componentIdentity: "dev.remotion.shapes.Circle",
16255
16786
  schema: circleSchema,
16256
16787
  supportsEffects: true
16257
16788
  });
@@ -16299,7 +16830,7 @@ var ellipseSchema = makeShapeSchema({
16299
16830
  })
16300
16831
  });
16301
16832
  var EllipseInner = ({ rx, ry, ...props }) => {
16302
- return /* @__PURE__ */ jsx43(RenderSvg, {
16833
+ return /* @__PURE__ */ jsx52(RenderSvg, {
16303
16834
  defaultName: "<Ellipse>",
16304
16835
  documentationLink: "https://www.remotion.dev/docs/shapes/ellipse",
16305
16836
  ...makeEllipse({ rx, ry }),
@@ -16308,6 +16839,7 @@ var EllipseInner = ({ rx, ry, ...props }) => {
16308
16839
  };
16309
16840
  var Ellipse = Internals.wrapInSchema({
16310
16841
  Component: EllipseInner,
16842
+ componentIdentity: "dev.remotion.shapes.Ellipse",
16311
16843
  schema: ellipseSchema,
16312
16844
  supportsEffects: true
16313
16845
  });
@@ -16431,7 +16963,7 @@ var HeartInner = ({
16431
16963
  depthAdjustment = 0,
16432
16964
  ...props
16433
16965
  }) => {
16434
- return /* @__PURE__ */ jsx52(RenderSvg, {
16966
+ return /* @__PURE__ */ jsx62(RenderSvg, {
16435
16967
  defaultName: "<Heart>",
16436
16968
  documentationLink: "https://www.remotion.dev/docs/shapes/heart",
16437
16969
  ...makeHeart({
@@ -16445,6 +16977,7 @@ var HeartInner = ({
16445
16977
  };
16446
16978
  var Heart = Internals.wrapInSchema({
16447
16979
  Component: HeartInner,
16980
+ componentIdentity: "dev.remotion.shapes.Heart",
16448
16981
  schema: heartSchema,
16449
16982
  supportsEffects: true
16450
16983
  });
@@ -16589,7 +17122,7 @@ var PieInner = ({
16589
17122
  rotation,
16590
17123
  ...props
16591
17124
  }) => {
16592
- return /* @__PURE__ */ jsx62(RenderSvg, {
17125
+ return /* @__PURE__ */ jsx72(RenderSvg, {
16593
17126
  defaultName: "<Pie>",
16594
17127
  documentationLink: "https://www.remotion.dev/docs/shapes/pie",
16595
17128
  ...makePie({ radius, progress, closePath, counterClockwise, rotation }),
@@ -16598,134 +17131,11 @@ var PieInner = ({
16598
17131
  };
16599
17132
  var Pie = Internals.wrapInSchema({
16600
17133
  Component: PieInner,
17134
+ componentIdentity: "dev.remotion.shapes.Pie",
16601
17135
  schema: pieSchema,
16602
17136
  supportsEffects: true
16603
17137
  });
16604
17138
  Internals.addSequenceStackTraces(Pie);
16605
- var shortenVector = (vector, radius) => {
16606
- const [x, y] = vector;
16607
- const currentLength = Math.sqrt(x * x + y * y);
16608
- const scalingFactor = (currentLength - radius) / currentLength;
16609
- return [x * scalingFactor, y * scalingFactor];
16610
- };
16611
- var scaleVectorToLength = (vector, length2) => {
16612
- const [x, y] = vector;
16613
- const currentLength = Math.sqrt(x * x + y * y);
16614
- const scalingFactor = length2 / currentLength;
16615
- return [x * scalingFactor, y * scalingFactor];
16616
- };
16617
- var joinPoints = (points, {
16618
- edgeRoundness,
16619
- cornerRadius,
16620
- roundCornerStrategy
16621
- }) => {
16622
- return points.map(([x, y], i) => {
16623
- const prevPointIndex = i === 0 ? points.length - 2 : i - 1;
16624
- const prevPoint = points[prevPointIndex];
16625
- const nextPointIndex = i === points.length - 1 ? 1 : i + 1;
16626
- const nextPoint = points[nextPointIndex];
16627
- const middleOfLine = [(x + nextPoint[0]) / 2, (y + nextPoint[1]) / 2];
16628
- const prevPointMiddleOfLine = [
16629
- (x + prevPoint[0]) / 2,
16630
- (y + prevPoint[1]) / 2
16631
- ];
16632
- const prevVector = [x - prevPoint[0], y - prevPoint[1]];
16633
- const nextVector = [nextPoint[0] - x, nextPoint[1] - y];
16634
- if (i === 0) {
16635
- if (edgeRoundness !== null) {
16636
- return [
16637
- {
16638
- type: "M",
16639
- x: middleOfLine[0],
16640
- y: middleOfLine[1]
16641
- }
16642
- ];
16643
- }
16644
- if (cornerRadius !== 0) {
16645
- const computeRadius = shortenVector(nextVector, cornerRadius);
16646
- return [
16647
- {
16648
- type: "M",
16649
- x: computeRadius[0] + x,
16650
- y: computeRadius[1] + y
16651
- }
16652
- ];
16653
- }
16654
- return [
16655
- {
16656
- type: "M",
16657
- x,
16658
- y
16659
- }
16660
- ];
16661
- }
16662
- if (cornerRadius && edgeRoundness !== null) {
16663
- throw new Error(`"cornerRadius" and "edgeRoundness" cannot be specified at the same time.`);
16664
- }
16665
- if (edgeRoundness === null) {
16666
- if (cornerRadius === 0) {
16667
- return [
16668
- {
16669
- type: "L",
16670
- x,
16671
- y
16672
- }
16673
- ];
16674
- }
16675
- const prevVectorMinusRadius = shortenVector(prevVector, cornerRadius);
16676
- const prevVectorLength = scaleVectorToLength(prevVector, cornerRadius);
16677
- const nextVectorMinusRadius = scaleVectorToLength(nextVector, cornerRadius);
16678
- const firstDraw = [
16679
- prevPoint[0] + prevVectorMinusRadius[0],
16680
- prevPoint[1] + prevVectorMinusRadius[1]
16681
- ];
16682
- return [
16683
- {
16684
- type: "L",
16685
- x: firstDraw[0],
16686
- y: firstDraw[1]
16687
- },
16688
- roundCornerStrategy === "arc" ? {
16689
- type: "a",
16690
- rx: cornerRadius,
16691
- ry: cornerRadius,
16692
- xAxisRotation: 0,
16693
- dx: prevVectorLength[0] + nextVectorMinusRadius[0],
16694
- dy: prevVectorLength[1] + nextVectorMinusRadius[1],
16695
- largeArcFlag: false,
16696
- sweepFlag: true
16697
- } : {
16698
- type: "C",
16699
- x: firstDraw[0] + prevVectorLength[0] + nextVectorMinusRadius[0],
16700
- y: firstDraw[1] + prevVectorLength[1] + nextVectorMinusRadius[1],
16701
- cp1x: x,
16702
- cp1y: y,
16703
- cp2x: x,
16704
- cp2y: y
16705
- }
16706
- ];
16707
- }
16708
- const controlPoint1 = [
16709
- prevPointMiddleOfLine[0] + prevVector[0] * edgeRoundness * 0.5,
16710
- prevPointMiddleOfLine[1] + prevVector[1] * edgeRoundness * 0.5
16711
- ];
16712
- const controlPoint2 = [
16713
- middleOfLine[0] - nextVector[0] * edgeRoundness * 0.5,
16714
- middleOfLine[1] - nextVector[1] * edgeRoundness * 0.5
16715
- ];
16716
- return [
16717
- {
16718
- type: "C",
16719
- cp1x: controlPoint1[0],
16720
- cp1y: controlPoint1[1],
16721
- cp2x: controlPoint2[0],
16722
- cp2y: controlPoint2[1],
16723
- x: middleOfLine[0],
16724
- y: middleOfLine[1]
16725
- }
16726
- ];
16727
- }).flat(1);
16728
- };
16729
17139
  function polygon({
16730
17140
  points,
16731
17141
  radius,
@@ -16806,7 +17216,7 @@ var PolygonInner = ({
16806
17216
  edgeRoundness,
16807
17217
  ...props
16808
17218
  }) => {
16809
- return /* @__PURE__ */ jsx72(RenderSvg, {
17219
+ return /* @__PURE__ */ jsx82(RenderSvg, {
16810
17220
  defaultName: "<Polygon>",
16811
17221
  documentationLink: "https://www.remotion.dev/docs/shapes/polygon",
16812
17222
  ...makePolygon({
@@ -16820,6 +17230,7 @@ var PolygonInner = ({
16820
17230
  };
16821
17231
  var Polygon = Internals.wrapInSchema({
16822
17232
  Component: PolygonInner,
17233
+ componentIdentity: "dev.remotion.shapes.Polygon",
16823
17234
  schema: polygonSchema,
16824
17235
  supportsEffects: true
16825
17236
  });
@@ -16876,7 +17287,7 @@ var RectInner = ({
16876
17287
  cornerRadius,
16877
17288
  ...props
16878
17289
  }) => {
16879
- return /* @__PURE__ */ jsx82(RenderSvg, {
17290
+ return /* @__PURE__ */ jsx92(RenderSvg, {
16880
17291
  defaultName: "<Rect>",
16881
17292
  documentationLink: "https://www.remotion.dev/docs/shapes/rect",
16882
17293
  ...makeRect({ height, width, edgeRoundness, cornerRadius }),
@@ -16885,6 +17296,7 @@ var RectInner = ({
16885
17296
  };
16886
17297
  var Rect = Internals.wrapInSchema({
16887
17298
  Component: RectInner,
17299
+ componentIdentity: "dev.remotion.shapes.Rect",
16888
17300
  schema: rectSchema,
16889
17301
  supportsEffects: true
16890
17302
  });
@@ -16979,7 +17391,7 @@ var StarInner = ({
16979
17391
  edgeRoundness,
16980
17392
  ...props
16981
17393
  }) => {
16982
- return /* @__PURE__ */ jsx92(RenderSvg, {
17394
+ return /* @__PURE__ */ jsx102(RenderSvg, {
16983
17395
  defaultName: "<Star>",
16984
17396
  documentationLink: "https://www.remotion.dev/docs/shapes/star",
16985
17397
  ...makeStar({
@@ -16994,6 +17406,7 @@ var StarInner = ({
16994
17406
  };
16995
17407
  var Star = Internals.wrapInSchema({
16996
17408
  Component: StarInner,
17409
+ componentIdentity: "dev.remotion.shapes.Star",
16997
17410
  schema: starSchema,
16998
17411
  supportsEffects: true
16999
17412
  });
@@ -17090,7 +17503,7 @@ var TriangleInner = ({
17090
17503
  cornerRadius,
17091
17504
  ...props
17092
17505
  }) => {
17093
- return /* @__PURE__ */ jsx102(RenderSvg, {
17506
+ return /* @__PURE__ */ jsx112(RenderSvg, {
17094
17507
  defaultName: "<Triangle>",
17095
17508
  documentationLink: "https://www.remotion.dev/docs/shapes/triangle",
17096
17509
  ...makeTriangle({ length: length2, direction, edgeRoundness, cornerRadius }),
@@ -17099,6 +17512,7 @@ var TriangleInner = ({
17099
17512
  };
17100
17513
  var Triangle = Internals.wrapInSchema({
17101
17514
  Component: TriangleInner,
17515
+ componentIdentity: "dev.remotion.shapes.Triangle",
17102
17516
  schema: triangleSchema,
17103
17517
  supportsEffects: true
17104
17518
  });
@@ -18179,7 +18593,7 @@ import { jsx as jsx83, jsxs as jsxs32 } from "react/jsx-runtime";
18179
18593
  import { jsx as jsx93 } from "react/jsx-runtime";
18180
18594
  import React72 from "react";
18181
18595
  import { jsx as jsx103 } from "react/jsx-runtime";
18182
- import { jsx as jsx112 } from "react/jsx-runtime";
18596
+ import { jsx as jsx113 } from "react/jsx-runtime";
18183
18597
  import { jsx as jsx122 } from "react/jsx-runtime";
18184
18598
  import * as React36 from "react";
18185
18599
  import * as ReactDOM4 from "react-dom";
@@ -18739,7 +19153,7 @@ var Button = ({
18739
19153
  const [dimensions, setDimensions] = useState22(null);
18740
19154
  const ref = useRef210(null);
18741
19155
  const { isActive, progress } = useHoverTransforms(ref, Boolean(disabled || loading));
18742
- const onPointerEnter = useCallback26((e) => {
19156
+ const onPointerEnter = useCallback27((e) => {
18743
19157
  if (e.pointerType !== "mouse") {
18744
19158
  return;
18745
19159
  }
@@ -18776,7 +19190,7 @@ var Button = ({
18776
19190
  const isDisabled = disabled || loading;
18777
19191
  const isAnchor = !asChild && "href" in rest && rest.href !== undefined;
18778
19192
  const sharedClasses = cn("text-text", "inline-flex", "justify-center", "bg-button-bg", "items-center", "font-brand", "border-solid", "text-[1em]", "rounded-lg", "border-black", "border-2", "border-b-4", "cursor-pointer", "px-4", "h-12", "flex-row", "items-center", "relative", "overflow-hidden", isDisabled && "cursor-default opacity-50", className);
18779
- const preventInteraction = useCallback26((e) => {
19193
+ const preventInteraction = useCallback27((e) => {
18780
19194
  e.preventDefault();
18781
19195
  e.stopPropagation();
18782
19196
  }, []);
@@ -18987,7 +19401,7 @@ var Link = ({
18987
19401
  className,
18988
19402
  ...props
18989
19403
  }) => {
18990
- return /* @__PURE__ */ jsx112("a", {
19404
+ return /* @__PURE__ */ jsx113("a", {
18991
19405
  ...props,
18992
19406
  className: cn(className, "text-brand underline underline-offset-4"),
18993
19407
  children: props.children