remotion 4.0.142 → 4.0.144

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 (54) hide show
  1. package/LICENSE.md +4 -0
  2. package/bunfig.toml +2 -0
  3. package/dist/cjs/CanUseRemotionHooks.d.ts +1 -1
  4. package/dist/cjs/Img.js +3 -2
  5. package/dist/cjs/Sequence.d.ts +14 -13
  6. package/dist/cjs/audio/Audio.d.ts +2 -1
  7. package/dist/cjs/audio/AudioForPreview.d.ts +7 -6
  8. package/dist/cjs/audio/AudioForPreview.js +2 -2
  9. package/dist/cjs/audio/AudioForRendering.d.ts +1 -0
  10. package/dist/cjs/audio/AudioForRendering.js +2 -2
  11. package/dist/cjs/audio/props.d.ts +2 -0
  12. package/dist/cjs/audio/use-audio-frame.d.ts +2 -1
  13. package/dist/cjs/audio/use-audio-frame.js +7 -2
  14. package/dist/cjs/default-css.d.ts +1 -1
  15. package/dist/cjs/default-css.js +3 -3
  16. package/dist/cjs/get-static-files.js +4 -0
  17. package/dist/cjs/index.d.ts +3 -3
  18. package/dist/cjs/internals.d.ts +1 -6
  19. package/dist/cjs/internals.js +0 -5
  20. package/dist/cjs/interpolate.d.ts +1 -1
  21. package/dist/cjs/loop/index.d.ts +13 -5
  22. package/dist/cjs/loop/index.js +38 -3
  23. package/dist/cjs/no-react.d.ts +5 -0
  24. package/dist/cjs/no-react.js +4 -0
  25. package/dist/cjs/series/index.js +4 -3
  26. package/dist/cjs/series/is-inside-series.d.ts +9 -0
  27. package/dist/cjs/series/is-inside-series.js +44 -0
  28. package/dist/cjs/spring/index.d.ts +2 -2
  29. package/dist/cjs/spring/index.js +8 -9
  30. package/dist/cjs/spring/measure-spring.d.ts +1 -1
  31. package/dist/cjs/spring/measure-spring.js +0 -2
  32. package/dist/cjs/spring/spring-utils.d.ts +1 -3
  33. package/dist/cjs/spring/spring-utils.js +3 -3
  34. package/dist/cjs/use-video-config.d.ts +1 -2
  35. package/dist/cjs/use-video-config.js +1 -2
  36. package/dist/cjs/version.d.ts +6 -1
  37. package/dist/cjs/version.js +7 -2
  38. package/dist/cjs/video/OffthreadVideoForRendering.js +2 -2
  39. package/dist/cjs/video/Video.d.ts +3 -2
  40. package/dist/cjs/video/VideoForPreview.d.ts +7 -7
  41. package/dist/cjs/video/VideoForPreview.js +5 -7
  42. package/dist/cjs/video/VideoForRendering.d.ts +1 -0
  43. package/dist/cjs/video/VideoForRendering.js +2 -2
  44. package/dist/cjs/video/index.d.ts +1 -1
  45. package/dist/cjs/video/props.d.ts +3 -0
  46. package/dist/cjs/video/video-fragment.js +9 -5
  47. package/dist/cjs/watch-static-file.js +4 -0
  48. package/dist/esm/index.mjs +576 -546
  49. package/dist/esm/no-react.mjs +3 -0
  50. package/dist/esm/version.mjs +6 -1
  51. package/ensure-correct-version.ts +47 -0
  52. package/happydom.ts +6 -0
  53. package/package.json +3 -1
  54. package/test.ts +1 -0
@@ -781,6 +781,9 @@ const NoReactInternals = {
781
781
  ENABLE_V5_BREAKING_CHANGES,
782
782
  MIN_NODE_VERSION: 16,
783
783
  MIN_BUN_VERSION: '1.0.3',
784
+ colorNames,
785
+ DATE_TOKEN,
786
+ FILE_TOKEN,
784
787
  };
785
788
 
786
789
  export { NoReactInternals, interpolate, random };
@@ -1,4 +1,9 @@
1
1
  // Automatically generated on publish
2
- const VERSION = '4.0.142';
2
+ /**
3
+ * @description Provides the current version number of the Remotion library.
4
+ * @see [Documentation](https://remotion.dev/docs/version)
5
+ * @returns {string} The current version of the remotion package
6
+ */
7
+ const VERSION = '4.0.144';
3
8
 
4
9
  export { VERSION };
@@ -0,0 +1,47 @@
1
+ const path = require('node:path');
2
+ const fs = require('node:fs');
3
+ const cp = require('node:child_process');
4
+
5
+ const packageJson = JSON.parse(fs.readFileSync('package.json'));
6
+ const {version} = packageJson;
7
+ const src =
8
+ `
9
+ // Automatically generated on publish
10
+
11
+ /**
12
+ * @description Provides the current version number of the Remotion library.
13
+ * @see [Documentation](https://remotion.dev/docs/version)
14
+ * @returns {string} The current version of the remotion package
15
+ */
16
+ export const VERSION = '${version}';
17
+ `.trim() + '\n';
18
+
19
+ fs.writeFileSync(path.resolve(process.cwd(), 'src/version.ts'), src);
20
+
21
+ cp.execSync('pnpm build');
22
+
23
+ const distFile = fs.readFileSync('dist/esm/version.mjs', 'utf-8');
24
+
25
+ if (!distFile.includes(version)) {
26
+ console.log('In dist file, did not include version');
27
+ process.exit(1);
28
+ }
29
+
30
+ const distFileCjs = fs.readFileSync('dist/cjs/version.js', 'utf-8');
31
+
32
+ if (!distFileCjs.includes(version)) {
33
+ console.log('In dist file, did not include version');
34
+ process.exit(1);
35
+ }
36
+
37
+ console.log('Updated version to v' + version);
38
+
39
+ const wrongDistFileExists = fs.existsSync('dist/index.js', 'utf-8');
40
+ if (wrongDistFileExists) {
41
+ throw new Error('Wrong dist file exists');
42
+ }
43
+
44
+ const wrongDistFileExists2 = fs.existsSync('dist/index.mjs', 'utf-8');
45
+ if (wrongDistFileExists2) {
46
+ throw new Error('Wrong dist file exists');
47
+ }
package/happydom.ts ADDED
@@ -0,0 +1,6 @@
1
+ import {GlobalRegistrator} from '@happy-dom/global-registrator';
2
+
3
+ GlobalRegistrator.register();
4
+ window.origin = 'http://localhost:3000';
5
+ // @ts-expect-error
6
+ window.remotion_staticBase = '/static-abcdef';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "remotion",
3
- "version": "4.0.142",
3
+ "version": "4.0.144",
4
4
  "description": "Render videos in React",
5
5
  "main": "dist/cjs/index.js",
6
6
  "types": "dist/cjs/index.d.ts",
@@ -21,6 +21,8 @@
21
21
  "@jonny/eslint-config": "3.0.281",
22
22
  "@rollup/plugin-typescript": "^8.2.0",
23
23
  "@testing-library/react": "14.0.0",
24
+ "@happy-dom/global-registrator": "14.5.1",
25
+ "happy-dom": "14.5.1",
24
26
  "@types/node": "18.14.6",
25
27
  "@types/react": "18.2.48",
26
28
  "@types/react-dom": "18.2.18",
package/test.ts ADDED
@@ -0,0 +1 @@
1
+ import 'whatwg-mimetype';