create-video 4.0.255 → 4.0.256
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.
- package/dist/add-tailwind.d.ts +1 -2
- package/dist/add-tailwind.js +14 -21
- package/dist/esm/index.mjs +12 -11
- package/dist/init.js +1 -2
- package/dist/list-of-remotion-packages.js +1 -0
- package/dist/patch-package-json.js +1 -1
- package/dist/test/patch-package-json.test.js +1 -1
- package/package.json +2 -2
package/dist/add-tailwind.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
export declare const
|
|
2
|
-
export declare const addTailwindConfigJs: (projectRoot: string) => void;
|
|
1
|
+
export declare const addPostcssConfig: (projectRoot: string) => void;
|
|
3
2
|
export declare const addTailwindRootCss: (projectRoot: string) => void;
|
|
4
3
|
export declare const addTailwindToConfig: (projectRoot: string) => void;
|
package/dist/add-tailwind.js
CHANGED
|
@@ -3,40 +3,33 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.addTailwindToConfig = exports.addTailwindRootCss = exports.
|
|
6
|
+
exports.addTailwindToConfig = exports.addTailwindRootCss = exports.addPostcssConfig = void 0;
|
|
7
7
|
const fs_1 = __importDefault(require("fs"));
|
|
8
8
|
const path_1 = __importDefault(require("path"));
|
|
9
|
-
const
|
|
10
|
-
const
|
|
11
|
-
fs_1.default.writeFileSync(
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
};
|
|
16
|
-
exports.addTailwindStyleCss = addTailwindStyleCss;
|
|
17
|
-
const addTailwindConfigJs = (projectRoot) => {
|
|
18
|
-
const tailwindConfigFile = path_1.default.join(projectRoot, 'tailwind.config.js');
|
|
19
|
-
fs_1.default.writeFileSync(tailwindConfigFile, `/* eslint-env node */
|
|
20
|
-
module.exports = {
|
|
21
|
-
content: ["./src/**/*.{ts,tsx,js,jsx}"],
|
|
22
|
-
theme: {
|
|
23
|
-
extend: {},
|
|
9
|
+
const addPostcssConfig = (projectRoot) => {
|
|
10
|
+
const postcssConfigMjs = path_1.default.join(projectRoot, 'postcss.config.mjs');
|
|
11
|
+
fs_1.default.writeFileSync(postcssConfigMjs, `
|
|
12
|
+
export default {
|
|
13
|
+
plugins: {
|
|
14
|
+
"@tailwindcss/postcss": {},
|
|
24
15
|
},
|
|
25
|
-
plugins: [],
|
|
26
16
|
};
|
|
27
|
-
|
|
17
|
+
`.trim() + '\n');
|
|
28
18
|
};
|
|
29
|
-
exports.
|
|
19
|
+
exports.addPostcssConfig = addPostcssConfig;
|
|
30
20
|
const addTailwindRootCss = (projectRoot) => {
|
|
31
21
|
const rootFileTsx = path_1.default.join(projectRoot, 'src', 'Root.tsx');
|
|
32
22
|
const rootFileJsx = path_1.default.join(projectRoot, 'src', 'Root.jsx');
|
|
23
|
+
const indexCss = path_1.default.join(projectRoot, 'src', 'index.css');
|
|
33
24
|
const rootFile = fs_1.default.existsSync(rootFileTsx) ? rootFileTsx : rootFileJsx;
|
|
34
25
|
if (!fs_1.default.existsSync(rootFile)) {
|
|
35
26
|
throw new Error('No Root file found');
|
|
36
27
|
}
|
|
37
28
|
const root = fs_1.default.readFileSync(rootFile, 'utf-8');
|
|
38
|
-
const newFile = `import "./
|
|
29
|
+
const newFile = `import "./index.css";\n${root}`;
|
|
39
30
|
fs_1.default.writeFileSync(rootFile, newFile);
|
|
31
|
+
const css = `@import "tailwindcss";\n`;
|
|
32
|
+
fs_1.default.writeFileSync(indexCss, css);
|
|
40
33
|
};
|
|
41
34
|
exports.addTailwindRootCss = addTailwindRootCss;
|
|
42
35
|
const addTailwindToConfig = (projectRoot) => {
|
|
@@ -60,7 +53,7 @@ const addTailwindToConfig = (projectRoot) => {
|
|
|
60
53
|
const tailLines = lines.slice(lastImportLine + 1);
|
|
61
54
|
const newLines = [
|
|
62
55
|
...headerLines,
|
|
63
|
-
`import { enableTailwind } from '@remotion/tailwind';`,
|
|
56
|
+
`import { enableTailwind } from '@remotion/tailwind-v4';`,
|
|
64
57
|
...tailLines,
|
|
65
58
|
'Config.overrideWebpackConfig(enableTailwind);',
|
|
66
59
|
];
|
package/dist/esm/index.mjs
CHANGED
|
@@ -32,6 +32,7 @@ var listOfRemotionPackages = [
|
|
|
32
32
|
"@remotion/studio-shared",
|
|
33
33
|
"@remotion/zod-types",
|
|
34
34
|
"@remotion/tailwind",
|
|
35
|
+
"@remotion/tailwind-v4",
|
|
35
36
|
"@remotion/transitions",
|
|
36
37
|
"@remotion/install-whisper-cpp",
|
|
37
38
|
"@remotion/openai-whisper",
|
|
@@ -314,12 +315,12 @@ var FEATURED_TEMPLATES = [
|
|
|
314
315
|
repoName: "template-overlay",
|
|
315
316
|
description: "Overlays for video editing software",
|
|
316
317
|
longerDescription: `
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
318
|
+
<span>
|
|
319
|
+
A starter template to create overlays to use in conventional video
|
|
320
|
+
editing software.{' '}
|
|
321
|
+
<a href="/docs/overlay">Read more about creating overlays.</a>
|
|
322
|
+
</span>
|
|
323
|
+
`,
|
|
323
324
|
promoVideo: {
|
|
324
325
|
muxId: "zgy7XK01009y33Vfzhns02cZS00rOyeZ6WaanaxcrDysqmU",
|
|
325
326
|
height: 720,
|
|
@@ -339,11 +340,11 @@ var FEATURED_TEMPLATES = [
|
|
|
339
340
|
org: "remotion-dev",
|
|
340
341
|
repoName: "template-code-hike",
|
|
341
342
|
description: "Beautiful code animations",
|
|
342
|
-
longerDescription:
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
343
|
+
longerDescription: `
|
|
344
|
+
Add code snippets and animate between them using
|
|
345
|
+
<a href="https://codehike.org/">Code Hike</a>. Supports many languages,
|
|
346
|
+
TypeScript error annotations, and many themes.
|
|
347
|
+
`,
|
|
347
348
|
promoVideo: {
|
|
348
349
|
muxId: "fKwnpTAOqvnZpu00fwEezi00cpF3927NumGcS1gGdUj8A",
|
|
349
350
|
width: 1080,
|
package/dist/init.js
CHANGED
|
@@ -100,9 +100,8 @@ const init = async () => {
|
|
|
100
100
|
});
|
|
101
101
|
(0, patch_readme_1.patchReadmeMd)(projectRoot, pkgManager, selectedTemplate);
|
|
102
102
|
if (shouldOverrideTailwind) {
|
|
103
|
-
(0, add_tailwind_1.addTailwindStyleCss)(projectRoot);
|
|
104
103
|
(0, add_tailwind_1.addTailwindToConfig)(projectRoot);
|
|
105
|
-
(0, add_tailwind_1.
|
|
104
|
+
(0, add_tailwind_1.addPostcssConfig)(projectRoot);
|
|
106
105
|
(0, add_tailwind_1.addTailwindRootCss)(projectRoot);
|
|
107
106
|
}
|
|
108
107
|
(0, create_public_folder_1.createPublicFolder)(projectRoot);
|
|
@@ -41,7 +41,7 @@ const patchPackageJson = ({ projectRoot, projectName, latestRemotionVersion, pac
|
|
|
41
41
|
const newDependenciesWithTailwind = addTailwind
|
|
42
42
|
? {
|
|
43
43
|
...newDependencies,
|
|
44
|
-
'@remotion/tailwind': latestRemotionVersion,
|
|
44
|
+
'@remotion/tailwind-v4': latestRemotionVersion,
|
|
45
45
|
}
|
|
46
46
|
: newDependencies;
|
|
47
47
|
const newPackageJson = JSON.stringify({
|
|
@@ -45,7 +45,7 @@ for (const packageManager of packageManagers) {
|
|
|
45
45
|
dependencies: {
|
|
46
46
|
...packageJson.dependencies,
|
|
47
47
|
'@remotion/cli': latestRemotionVersion,
|
|
48
|
-
'@remotion/tailwind': latestRemotionVersion,
|
|
48
|
+
'@remotion/tailwind-v4': latestRemotionVersion,
|
|
49
49
|
remotion: latestRemotionVersion,
|
|
50
50
|
},
|
|
51
51
|
sideEffects: ['*.css'],
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"url": "https://github.com/remotion-dev/remotion/tree/main/packages/create-video"
|
|
4
4
|
},
|
|
5
5
|
"name": "create-video",
|
|
6
|
-
"version": "4.0.
|
|
6
|
+
"version": "4.0.256",
|
|
7
7
|
"description": "Create a new Remotion project",
|
|
8
8
|
"main": "dist/index.js",
|
|
9
9
|
"bin": {
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"@types/tar": "6.1.1",
|
|
28
28
|
"react": "19.0.0",
|
|
29
29
|
"eslint": "9.14.0",
|
|
30
|
-
"@remotion/eslint-config-internal": "4.0.
|
|
30
|
+
"@remotion/eslint-config-internal": "4.0.256"
|
|
31
31
|
},
|
|
32
32
|
"exports": {
|
|
33
33
|
"./package.json": "./package.json",
|