@remotion/renderer 4.0.504 → 4.0.506
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/client.d.ts +18 -0
- package/dist/client.js +3 -1
- package/dist/esm/client.mjs +722 -666
- package/dist/esm/index.mjs +21 -4
- package/dist/index.d.ts +3 -1
- package/dist/index.js +3 -1
- package/dist/options/default-coding-agent.d.ts +18 -0
- package/dist/options/default-coding-agent.js +48 -0
- package/dist/options/index.d.ts +16 -0
- package/dist/options/index.js +2 -0
- package/dist/serve-handler/index.js +14 -1
- package/package.json +13 -13
package/dist/esm/index.mjs
CHANGED
|
@@ -17826,8 +17826,16 @@ var serveHandler = async (request, response, config) => {
|
|
|
17826
17826
|
headers["Content-Length"] = String(streamOpts.end - streamOpts.start + 1);
|
|
17827
17827
|
}
|
|
17828
17828
|
headers["Cache-Control"] = "no-cache, no-store, must-revalidate";
|
|
17829
|
+
const readStream = stream;
|
|
17830
|
+
response.on("close", () => {
|
|
17831
|
+
readStream.destroy();
|
|
17832
|
+
});
|
|
17833
|
+
if (response.destroyed) {
|
|
17834
|
+
readStream.destroy();
|
|
17835
|
+
return;
|
|
17836
|
+
}
|
|
17829
17837
|
response.writeHead(response.statusCode || 200, headers);
|
|
17830
|
-
|
|
17838
|
+
readStream.pipe(response);
|
|
17831
17839
|
};
|
|
17832
17840
|
|
|
17833
17841
|
// src/serve-static.ts
|
|
@@ -25608,8 +25616,16 @@ var getVideoMetadata = async (videoSource, options2) => {
|
|
|
25608
25616
|
};
|
|
25609
25617
|
// src/options/chrome-mode.tsx
|
|
25610
25618
|
import { jsx as jsx7, jsxs as jsxs7, Fragment as Fragment7 } from "react/jsx-runtime";
|
|
25611
|
-
// src/options/default-
|
|
25619
|
+
// src/options/default-coding-agent.tsx
|
|
25612
25620
|
import { jsx as jsx8, jsxs as jsxs8, Fragment as Fragment8 } from "react/jsx-runtime";
|
|
25621
|
+
var defaultCodingAgentIds = [
|
|
25622
|
+
"codex",
|
|
25623
|
+
"cursor",
|
|
25624
|
+
"github-copilot",
|
|
25625
|
+
"claude-code"
|
|
25626
|
+
];
|
|
25627
|
+
// src/options/default-editor.tsx
|
|
25628
|
+
import { jsx as jsx9, jsxs as jsxs9, Fragment as Fragment9 } from "react/jsx-runtime";
|
|
25613
25629
|
var defaultEditorIds = [
|
|
25614
25630
|
"vscode",
|
|
25615
25631
|
"cursor",
|
|
@@ -25623,9 +25639,9 @@ var customEditorTargetPathPlaceholder = "%TARGET_PATH%";
|
|
|
25623
25639
|
var customEditorLineNumberPlaceholder = "%LINE_NUMBER%";
|
|
25624
25640
|
var customEditorColumnNumberPlaceholder = "%COLUMN_NUMBER%";
|
|
25625
25641
|
// src/options/number-of-gif-loops.tsx
|
|
25626
|
-
import { jsx as jsx9, jsxs as jsxs9, Fragment as Fragment9 } from "react/jsx-runtime";
|
|
25627
|
-
// src/options/on-browser-download.tsx
|
|
25628
25642
|
import { jsx as jsx10, jsxs as jsxs10, Fragment as Fragment10 } from "react/jsx-runtime";
|
|
25643
|
+
// src/options/on-browser-download.tsx
|
|
25644
|
+
import { jsx as jsx11, jsxs as jsxs11, Fragment as Fragment11 } from "react/jsx-runtime";
|
|
25629
25645
|
// src/index.ts
|
|
25630
25646
|
var RenderInternals = {
|
|
25631
25647
|
resolveConcurrency,
|
|
@@ -25738,6 +25754,7 @@ export {
|
|
|
25738
25754
|
extractAudio,
|
|
25739
25755
|
ensureBrowser,
|
|
25740
25756
|
defaultEditorIds,
|
|
25757
|
+
defaultCodingAgentIds,
|
|
25741
25758
|
customEditorTargetPathPlaceholder,
|
|
25742
25759
|
customEditorLineNumberPlaceholder,
|
|
25743
25760
|
customEditorColumnNumberPlaceholder,
|
package/dist/index.d.ts
CHANGED
|
@@ -19,7 +19,7 @@ export { extractAudio } from './extract-audio';
|
|
|
19
19
|
export type { FfmpegOverrideFn } from './ffmpeg-override';
|
|
20
20
|
export { FileExtension } from './file-extensions';
|
|
21
21
|
export { FrameRange, FrameRangeTuple, FrameSelection, OpenEndedFrameRange, ResolvedFrameRange, SingleFrameRange, } from './frame-range';
|
|
22
|
-
export { GetCompositionsOptions,
|
|
22
|
+
export { GetCompositionsOptions, LegacyGetCompositionsOptions, getCompositions, } from './get-compositions';
|
|
23
23
|
export { SilentPart, getSilentParts } from './get-silent-parts';
|
|
24
24
|
export { VideoMetadata, getVideoMetadata } from './get-video-metadata';
|
|
25
25
|
export { ImageFormat, StillImageFormat, VideoImageFormat, validateSelectedPixelFormatAndImageFormatCombination, } from './image-format';
|
|
@@ -31,6 +31,8 @@ export type { ChromiumOptions } from './open-browser';
|
|
|
31
31
|
export { ChromeMode } from './options/chrome-mode';
|
|
32
32
|
export { ColorSpace } from './options/color-space';
|
|
33
33
|
export type { Concurrency } from './options/concurrency';
|
|
34
|
+
export { defaultCodingAgentIds } from './options/default-coding-agent';
|
|
35
|
+
export type { DefaultCodingAgent } from './options/default-coding-agent';
|
|
34
36
|
export { customEditorColumnNumberPlaceholder, customEditorLineNumberPlaceholder, customEditorTargetPathPlaceholder, defaultEditorIds, } from './options/default-editor';
|
|
35
37
|
export type { BuiltInEditor, CustomEditor, DefaultEditor, } from './options/default-editor';
|
|
36
38
|
export type { DeleteAfter } from './options/delete-after';
|
package/dist/index.js
CHANGED
|
@@ -36,7 +36,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
36
36
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.RenderInternals = exports.validateOutputFilename = exports.stitchFramesToVideo = exports.selectComposition = exports.renderStill = exports.renderMedia = exports.renderFrames = exports.defaultEditorIds = exports.customEditorTargetPathPlaceholder = exports.customEditorLineNumberPlaceholder = exports.customEditorColumnNumberPlaceholder = exports.openBrowser = exports.makeCancelSignal = exports.validateSelectedPixelFormatAndImageFormatCombination = exports.getVideoMetadata = exports.getSilentParts = exports.getCompositions = exports.extractAudio = exports.ErrorWithStackFrame = exports.ensureBrowser = exports.combineChunks = void 0;
|
|
39
|
+
exports.RenderInternals = exports.validateOutputFilename = exports.stitchFramesToVideo = exports.selectComposition = exports.renderStill = exports.renderMedia = exports.renderFrames = exports.defaultEditorIds = exports.customEditorTargetPathPlaceholder = exports.customEditorLineNumberPlaceholder = exports.customEditorColumnNumberPlaceholder = exports.defaultCodingAgentIds = exports.openBrowser = exports.makeCancelSignal = exports.validateSelectedPixelFormatAndImageFormatCombination = exports.getVideoMetadata = exports.getSilentParts = exports.getCompositions = exports.extractAudio = exports.ErrorWithStackFrame = exports.ensureBrowser = exports.combineChunks = void 0;
|
|
40
40
|
const execa_1 = __importDefault(require("execa"));
|
|
41
41
|
const download_file_1 = require("./assets/download-file");
|
|
42
42
|
const browser_1 = require("./browser");
|
|
@@ -109,6 +109,8 @@ const make_cancel_signal_1 = require("./make-cancel-signal");
|
|
|
109
109
|
Object.defineProperty(exports, "makeCancelSignal", { enumerable: true, get: function () { return make_cancel_signal_1.makeCancelSignal; } });
|
|
110
110
|
const open_browser_2 = require("./open-browser");
|
|
111
111
|
Object.defineProperty(exports, "openBrowser", { enumerable: true, get: function () { return open_browser_2.openBrowser; } });
|
|
112
|
+
const default_coding_agent_1 = require("./options/default-coding-agent");
|
|
113
|
+
Object.defineProperty(exports, "defaultCodingAgentIds", { enumerable: true, get: function () { return default_coding_agent_1.defaultCodingAgentIds; } });
|
|
112
114
|
const default_editor_1 = require("./options/default-editor");
|
|
113
115
|
Object.defineProperty(exports, "customEditorColumnNumberPlaceholder", { enumerable: true, get: function () { return default_editor_1.customEditorColumnNumberPlaceholder; } });
|
|
114
116
|
Object.defineProperty(exports, "customEditorLineNumberPlaceholder", { enumerable: true, get: function () { return default_editor_1.customEditorLineNumberPlaceholder; } });
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export declare const defaultCodingAgentIds: readonly ["codex", "cursor", "github-copilot", "claude-code"];
|
|
2
|
+
export type DefaultCodingAgent = (typeof defaultCodingAgentIds)[number];
|
|
3
|
+
export declare const defaultCodingAgentOption: {
|
|
4
|
+
name: string;
|
|
5
|
+
cliFlag: "coding-agent";
|
|
6
|
+
description: () => import("react/jsx-runtime").JSX.Element;
|
|
7
|
+
ssrName: null;
|
|
8
|
+
docLink: string;
|
|
9
|
+
type: "claude-code" | "codex" | "cursor" | "github-copilot" | null;
|
|
10
|
+
getValue: ({ commandLine }: {
|
|
11
|
+
commandLine: Record<string, unknown>;
|
|
12
|
+
}) => {
|
|
13
|
+
value: "claude-code" | "codex" | "cursor" | "github-copilot" | null;
|
|
14
|
+
source: string;
|
|
15
|
+
};
|
|
16
|
+
setConfig(value: "claude-code" | "codex" | "cursor" | "github-copilot" | null): void;
|
|
17
|
+
id: "coding-agent";
|
|
18
|
+
};
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.defaultCodingAgentOption = exports.defaultCodingAgentIds = void 0;
|
|
4
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
+
exports.defaultCodingAgentIds = [
|
|
6
|
+
'codex',
|
|
7
|
+
'cursor',
|
|
8
|
+
'github-copilot',
|
|
9
|
+
'claude-code',
|
|
10
|
+
];
|
|
11
|
+
const cliFlag = 'coding-agent';
|
|
12
|
+
let defaultCodingAgent = null;
|
|
13
|
+
const validateDefaultCodingAgent = (value, source) => {
|
|
14
|
+
if (value === null) {
|
|
15
|
+
return null;
|
|
16
|
+
}
|
|
17
|
+
if (typeof value !== 'string' ||
|
|
18
|
+
!exports.defaultCodingAgentIds.includes(value)) {
|
|
19
|
+
throw new TypeError(`${source} must be one of: ${exports.defaultCodingAgentIds.join(', ')}. Received: ${JSON.stringify(value)}`);
|
|
20
|
+
}
|
|
21
|
+
return value;
|
|
22
|
+
};
|
|
23
|
+
exports.defaultCodingAgentOption = {
|
|
24
|
+
name: 'Default coding agent',
|
|
25
|
+
cliFlag,
|
|
26
|
+
description: () => (jsx_runtime_1.jsxs(jsx_runtime_1.Fragment, { children: ["Set the default coding agent for Remotion Studio. Available coding agents:", ' ', jsx_runtime_1.jsx("code", { children: exports.defaultCodingAgentIds.join(', ') }),
|
|
27
|
+
"."] })),
|
|
28
|
+
ssrName: null,
|
|
29
|
+
docLink: 'https://www.remotion.dev/docs/config#setdefaultcodingagent',
|
|
30
|
+
type: null,
|
|
31
|
+
getValue: ({ commandLine }) => {
|
|
32
|
+
const cliValue = commandLine[cliFlag];
|
|
33
|
+
if (cliValue !== undefined && cliValue !== null) {
|
|
34
|
+
return {
|
|
35
|
+
value: validateDefaultCodingAgent(cliValue, `--${cliFlag}`),
|
|
36
|
+
source: 'cli',
|
|
37
|
+
};
|
|
38
|
+
}
|
|
39
|
+
return {
|
|
40
|
+
value: defaultCodingAgent,
|
|
41
|
+
source: 'config',
|
|
42
|
+
};
|
|
43
|
+
},
|
|
44
|
+
setConfig(value) {
|
|
45
|
+
defaultCodingAgent = validateDefaultCodingAgent(value, 'Config.setDefaultCodingAgent()');
|
|
46
|
+
},
|
|
47
|
+
id: cliFlag,
|
|
48
|
+
};
|
package/dist/options/index.d.ts
CHANGED
|
@@ -1032,6 +1032,22 @@ export declare const allOptions: {
|
|
|
1032
1032
|
setConfig: (value: boolean) => void;
|
|
1033
1033
|
id: "dark-mode";
|
|
1034
1034
|
};
|
|
1035
|
+
defaultCodingAgentOption: {
|
|
1036
|
+
name: string;
|
|
1037
|
+
cliFlag: "coding-agent";
|
|
1038
|
+
description: () => import("react/jsx-runtime").JSX.Element;
|
|
1039
|
+
ssrName: null;
|
|
1040
|
+
docLink: string;
|
|
1041
|
+
type: "claude-code" | "codex" | "cursor" | "github-copilot" | null;
|
|
1042
|
+
getValue: ({ commandLine }: {
|
|
1043
|
+
commandLine: Record<string, unknown>;
|
|
1044
|
+
}) => {
|
|
1045
|
+
value: "claude-code" | "codex" | "cursor" | "github-copilot" | null;
|
|
1046
|
+
source: string;
|
|
1047
|
+
};
|
|
1048
|
+
setConfig(value: "claude-code" | "codex" | "cursor" | "github-copilot" | null): void;
|
|
1049
|
+
id: "coding-agent";
|
|
1050
|
+
};
|
|
1035
1051
|
defaultEditorOption: {
|
|
1036
1052
|
name: string;
|
|
1037
1053
|
cliFlag: "editor";
|
package/dist/options/index.js
CHANGED
|
@@ -18,6 +18,7 @@ const config_1 = require("./config");
|
|
|
18
18
|
const crf_1 = require("./crf");
|
|
19
19
|
const cross_site_isolation_1 = require("./cross-site-isolation");
|
|
20
20
|
const dark_mode_1 = require("./dark-mode");
|
|
21
|
+
const default_coding_agent_1 = require("./default-coding-agent");
|
|
21
22
|
const default_editor_1 = require("./default-editor");
|
|
22
23
|
const delete_after_1 = require("./delete-after");
|
|
23
24
|
const disable_git_source_1 = require("./disable-git-source");
|
|
@@ -154,6 +155,7 @@ exports.allOptions = {
|
|
|
154
155
|
imageSequencePatternOption: image_sequence_pattern_1.imageSequencePatternOption,
|
|
155
156
|
mediaCacheSizeInBytesOption: video_cache_size_1.mediaCacheSizeInBytesOption,
|
|
156
157
|
darkModeOption: dark_mode_1.darkModeOption,
|
|
158
|
+
defaultCodingAgentOption: default_coding_agent_1.defaultCodingAgentOption,
|
|
157
159
|
defaultEditorOption: default_editor_1.defaultEditorOption,
|
|
158
160
|
publicLicenseKeyOption: public_license_key_1.publicLicenseKeyOption,
|
|
159
161
|
isProductionOption: is_production_1.isProductionOption,
|
|
@@ -202,7 +202,20 @@ const serveHandler = async (request, response, config) => {
|
|
|
202
202
|
headers['Content-Length'] = String(streamOpts.end - streamOpts.start + 1);
|
|
203
203
|
}
|
|
204
204
|
headers['Cache-Control'] = 'no-cache, no-store, must-revalidate';
|
|
205
|
+
const readStream = stream;
|
|
206
|
+
// Chrome's media demuxer aborts Range requests constantly while seeking
|
|
207
|
+
// <Video>/<Audio>. Without this, an aborted request leaves the piped stream
|
|
208
|
+
// stranded on backpressure and its file descriptor open for the life of the
|
|
209
|
+
// render process. 'close' fires on completion as well as abort, and
|
|
210
|
+
// destroy() on an already-ended stream is a no-op.
|
|
211
|
+
response.on('close', () => {
|
|
212
|
+
readStream.destroy();
|
|
213
|
+
});
|
|
214
|
+
if (response.destroyed) {
|
|
215
|
+
readStream.destroy();
|
|
216
|
+
return;
|
|
217
|
+
}
|
|
205
218
|
response.writeHead(response.statusCode || 200, headers);
|
|
206
|
-
|
|
219
|
+
readStream.pipe(response);
|
|
207
220
|
};
|
|
208
221
|
exports.serveHandler = serveHandler;
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"url": "https://github.com/remotion-dev/remotion/tree/main/packages/renderer"
|
|
4
4
|
},
|
|
5
5
|
"name": "@remotion/renderer",
|
|
6
|
-
"version": "4.0.
|
|
6
|
+
"version": "4.0.506",
|
|
7
7
|
"description": "Render Remotion videos using Node.js or Bun",
|
|
8
8
|
"main": "dist/index.js",
|
|
9
9
|
"types": "dist/index.d.ts",
|
|
@@ -22,11 +22,11 @@
|
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
24
|
"execa": "5.1.1",
|
|
25
|
-
"remotion": "4.0.
|
|
26
|
-
"@remotion/streaming": "4.0.
|
|
25
|
+
"remotion": "4.0.506",
|
|
26
|
+
"@remotion/streaming": "4.0.506",
|
|
27
27
|
"source-map": "0.8.0",
|
|
28
28
|
"ws": "8.21.0",
|
|
29
|
-
"@remotion/licensing": "4.0.
|
|
29
|
+
"@remotion/licensing": "4.0.506"
|
|
30
30
|
},
|
|
31
31
|
"peerDependencies": {
|
|
32
32
|
"react": ">=16.8.0",
|
|
@@ -40,19 +40,19 @@
|
|
|
40
40
|
"react-dom": "19.2.3",
|
|
41
41
|
"@typescript/native-preview": "7.0.0-dev.20260217.1",
|
|
42
42
|
"@types/ws": "8.5.10",
|
|
43
|
-
"@remotion/example-videos": "4.0.
|
|
44
|
-
"@remotion/eslint-config-internal": "4.0.
|
|
43
|
+
"@remotion/example-videos": "4.0.506",
|
|
44
|
+
"@remotion/eslint-config-internal": "4.0.506",
|
|
45
45
|
"eslint": "9.19.0",
|
|
46
46
|
"@types/node": "20.12.14"
|
|
47
47
|
},
|
|
48
48
|
"optionalDependencies": {
|
|
49
|
-
"@remotion/compositor-darwin-arm64": "4.0.
|
|
50
|
-
"@remotion/compositor-darwin-x64": "4.0.
|
|
51
|
-
"@remotion/compositor-linux-arm64-gnu": "4.0.
|
|
52
|
-
"@remotion/compositor-linux-arm64-musl": "4.0.
|
|
53
|
-
"@remotion/compositor-linux-x64-gnu": "4.0.
|
|
54
|
-
"@remotion/compositor-linux-x64-musl": "4.0.
|
|
55
|
-
"@remotion/compositor-win32-x64-msvc": "4.0.
|
|
49
|
+
"@remotion/compositor-darwin-arm64": "4.0.506",
|
|
50
|
+
"@remotion/compositor-darwin-x64": "4.0.506",
|
|
51
|
+
"@remotion/compositor-linux-arm64-gnu": "4.0.506",
|
|
52
|
+
"@remotion/compositor-linux-arm64-musl": "4.0.506",
|
|
53
|
+
"@remotion/compositor-linux-x64-gnu": "4.0.506",
|
|
54
|
+
"@remotion/compositor-linux-x64-musl": "4.0.506",
|
|
55
|
+
"@remotion/compositor-win32-x64-msvc": "4.0.506"
|
|
56
56
|
},
|
|
57
57
|
"keywords": [
|
|
58
58
|
"remotion",
|