@remotion/studio 4.0.401 → 4.0.403
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/components/Menu/MenuSubItem.d.ts +1 -0
- package/dist/components/Menu/MenuSubItem.js +13 -5
- package/dist/components/NewComposition/ComboBox.d.ts +1 -0
- package/dist/components/NewComposition/MenuContent.js +18 -12
- package/dist/components/RenderModal/WebRenderModal.js +29 -4
- package/dist/components/RenderModal/WebRenderModalAudio.d.ts +9 -1
- package/dist/components/RenderModal/WebRenderModalAudio.js +51 -2
- package/dist/components/RenderModal/WebRenderModalBasic.d.ts +2 -1
- package/dist/components/RenderModal/WebRenderModalBasic.js +21 -60
- package/dist/components/RenderModal/WebRenderModalPicture.js +2 -60
- package/dist/components/RenderModal/quality-options.d.ts +3 -0
- package/dist/components/RenderModal/quality-options.js +26 -0
- package/dist/components/RenderModal/use-encodable-audio-codecs.d.ts +2 -0
- package/dist/components/RenderModal/use-encodable-audio-codecs.js +49 -0
- package/dist/components/RenderModal/use-encodable-video-codecs.d.ts +2 -0
- package/dist/components/RenderModal/use-encodable-video-codecs.js +49 -0
- package/dist/esm/{chunk-71hmw645.js → chunk-64385d31.js} +629 -453
- package/dist/esm/internals.mjs +629 -453
- package/dist/esm/previewEntry.mjs +643 -467
- package/dist/esm/renderEntry.mjs +1 -1
- package/package.json +9 -9
|
@@ -10,7 +10,7 @@ import { Internals as Internals65 } from "remotion";
|
|
|
10
10
|
|
|
11
11
|
// src/components/Editor.tsx
|
|
12
12
|
import { PlayerInternals as PlayerInternals19 } from "@remotion/player";
|
|
13
|
-
import
|
|
13
|
+
import React177, { useCallback as useCallback134, useEffect as useEffect82, useMemo as useMemo137 } from "react";
|
|
14
14
|
import { Internals as Internals61 } from "remotion";
|
|
15
15
|
|
|
16
16
|
// src/helpers/colors.ts
|
|
@@ -1875,7 +1875,8 @@ var MenuSubItem = ({
|
|
|
1875
1875
|
subMenu,
|
|
1876
1876
|
onQuitMenu,
|
|
1877
1877
|
subMenuActivated,
|
|
1878
|
-
setSubMenuActivated
|
|
1878
|
+
setSubMenuActivated,
|
|
1879
|
+
disabled
|
|
1879
1880
|
}) => {
|
|
1880
1881
|
const [hovered, setHovered] = useState10(false);
|
|
1881
1882
|
const ref = useRef6(null);
|
|
@@ -1888,21 +1889,29 @@ var MenuSubItem = ({
|
|
|
1888
1889
|
const style = useMemo14(() => {
|
|
1889
1890
|
return {
|
|
1890
1891
|
...container4,
|
|
1891
|
-
backgroundColor: selected ? CLEAR_HOVER : "transparent"
|
|
1892
|
+
backgroundColor: selected && !disabled ? CLEAR_HOVER : "transparent",
|
|
1893
|
+
opacity: disabled ? 0.5 : 1,
|
|
1894
|
+
cursor: disabled ? "not-allowed" : "default"
|
|
1892
1895
|
};
|
|
1893
|
-
}, [selected]);
|
|
1896
|
+
}, [selected, disabled]);
|
|
1894
1897
|
const onPointerUp = useCallback8((e) => {
|
|
1898
|
+
if (disabled) {
|
|
1899
|
+
return;
|
|
1900
|
+
}
|
|
1895
1901
|
if (subMenu) {
|
|
1896
1902
|
setSubMenuActivated("with-mouse");
|
|
1897
1903
|
setHovered(true);
|
|
1898
1904
|
return;
|
|
1899
1905
|
}
|
|
1900
1906
|
onActionChosen(id, e);
|
|
1901
|
-
}, [id, onActionChosen, setSubMenuActivated, subMenu]);
|
|
1907
|
+
}, [disabled, id, onActionChosen, setSubMenuActivated, subMenu]);
|
|
1902
1908
|
const onPointerEnter = useCallback8(() => {
|
|
1909
|
+
if (disabled) {
|
|
1910
|
+
return;
|
|
1911
|
+
}
|
|
1903
1912
|
onItemSelected(id);
|
|
1904
1913
|
setHovered(true);
|
|
1905
|
-
}, [id, onItemSelected]);
|
|
1914
|
+
}, [disabled, id, onItemSelected]);
|
|
1906
1915
|
const onPointerLeave = useCallback8(() => {
|
|
1907
1916
|
setHovered(false);
|
|
1908
1917
|
}, []);
|
|
@@ -2021,6 +2030,9 @@ var MenuContent = ({
|
|
|
2021
2030
|
const onItemSelected = useCallback9((id) => {
|
|
2022
2031
|
setSelectedItem(id);
|
|
2023
2032
|
}, []);
|
|
2033
|
+
const isItemSelectable = useCallback9((v) => {
|
|
2034
|
+
return v.type !== "divider" && !v.disabled;
|
|
2035
|
+
}, []);
|
|
2024
2036
|
const onArrowUp = useCallback9(() => {
|
|
2025
2037
|
setSelectedItem((prevItem) => {
|
|
2026
2038
|
if (prevItem === null) {
|
|
@@ -2030,31 +2042,31 @@ var MenuContent = ({
|
|
|
2030
2042
|
if (topItemCanBeUnselected && index === 0 || prevItem === null) {
|
|
2031
2043
|
return null;
|
|
2032
2044
|
}
|
|
2033
|
-
const previousItems = values.filter((v, i) => i < index && v
|
|
2045
|
+
const previousItems = values.filter((v, i) => i < index && isItemSelectable(v));
|
|
2034
2046
|
if (previousItems.length > 0) {
|
|
2035
2047
|
return previousItems[previousItems.length - 1].id;
|
|
2036
2048
|
}
|
|
2037
|
-
const
|
|
2038
|
-
if (
|
|
2039
|
-
return
|
|
2049
|
+
const firstSelectable = values.find((v) => isItemSelectable(v));
|
|
2050
|
+
if (firstSelectable) {
|
|
2051
|
+
return firstSelectable.id;
|
|
2040
2052
|
}
|
|
2041
2053
|
throw new Error("could not find previous item");
|
|
2042
2054
|
});
|
|
2043
|
-
}, [topItemCanBeUnselected, values]);
|
|
2055
|
+
}, [topItemCanBeUnselected, values, isItemSelectable]);
|
|
2044
2056
|
const onArrowDown = useCallback9(() => {
|
|
2045
2057
|
setSelectedItem((prevItem) => {
|
|
2046
2058
|
const index = values.findIndex((val) => val.id === prevItem);
|
|
2047
|
-
const nextItem = values.find((v, i) => i > index && v
|
|
2059
|
+
const nextItem = values.find((v, i) => i > index && isItemSelectable(v));
|
|
2048
2060
|
if (nextItem) {
|
|
2049
2061
|
return nextItem.id;
|
|
2050
2062
|
}
|
|
2051
|
-
const
|
|
2052
|
-
if (
|
|
2053
|
-
return
|
|
2063
|
+
const lastSelectable = values.slice().reverse().find((v) => isItemSelectable(v));
|
|
2064
|
+
if (lastSelectable) {
|
|
2065
|
+
return lastSelectable.id;
|
|
2054
2066
|
}
|
|
2055
2067
|
throw new Error("could not find next item");
|
|
2056
2068
|
});
|
|
2057
|
-
}, [values]);
|
|
2069
|
+
}, [values, isItemSelectable]);
|
|
2058
2070
|
const onEnter = useCallback9(() => {
|
|
2059
2071
|
if (selectedItem === null) {
|
|
2060
2072
|
return onHide();
|
|
@@ -2066,6 +2078,9 @@ var MenuContent = ({
|
|
|
2066
2078
|
if (item.type === "divider") {
|
|
2067
2079
|
throw new Error("cannot find divider");
|
|
2068
2080
|
}
|
|
2081
|
+
if (item.disabled) {
|
|
2082
|
+
return;
|
|
2083
|
+
}
|
|
2069
2084
|
if (item.subMenu) {
|
|
2070
2085
|
return setSubMenuActivated("without-mouse");
|
|
2071
2086
|
}
|
|
@@ -2243,7 +2258,8 @@ var MenuContent = ({
|
|
|
2243
2258
|
onQuitMenu: onHide,
|
|
2244
2259
|
onNextMenu,
|
|
2245
2260
|
subMenuActivated,
|
|
2246
|
-
setSubMenuActivated
|
|
2261
|
+
setSubMenuActivated,
|
|
2262
|
+
disabled: item.disabled
|
|
2247
2263
|
}, item.id);
|
|
2248
2264
|
})
|
|
2249
2265
|
});
|
|
@@ -42296,8 +42312,12 @@ var RenderModalWithLoader = (props) => {
|
|
|
42296
42312
|
|
|
42297
42313
|
// src/components/RenderModal/WebRenderModal.tsx
|
|
42298
42314
|
import { getDefaultOutLocation as getDefaultOutLocation2 } from "@remotion/studio-shared";
|
|
42299
|
-
import {
|
|
42300
|
-
|
|
42315
|
+
import {
|
|
42316
|
+
getDefaultAudioCodecForContainer,
|
|
42317
|
+
renderMediaOnWeb,
|
|
42318
|
+
renderStillOnWeb
|
|
42319
|
+
} from "@remotion/web-renderer";
|
|
42320
|
+
import { useCallback as useCallback130, useContext as useContext82, useMemo as useMemo134, useState as useState83 } from "react";
|
|
42301
42321
|
|
|
42302
42322
|
// src/icons/certificate.tsx
|
|
42303
42323
|
import { jsx as jsx256 } from "react/jsx-runtime";
|
|
@@ -42311,6 +42331,90 @@ var CertificateIcon = (props) => /* @__PURE__ */ jsx256("svg", {
|
|
|
42311
42331
|
})
|
|
42312
42332
|
});
|
|
42313
42333
|
|
|
42334
|
+
// src/components/RenderModal/use-encodable-audio-codecs.ts
|
|
42335
|
+
import {
|
|
42336
|
+
getEncodableAudioCodecs,
|
|
42337
|
+
getSupportedAudioCodecsForContainer
|
|
42338
|
+
} from "@remotion/web-renderer";
|
|
42339
|
+
import { useEffect as useEffect79, useRef as useRef44, useState as useState81 } from "react";
|
|
42340
|
+
var useEncodableAudioCodecs = (container60) => {
|
|
42341
|
+
const cacheRef = useRef44({});
|
|
42342
|
+
const [codecsByContainer, setCodecsByContainer] = useState81(() => {
|
|
42343
|
+
return {
|
|
42344
|
+
[container60]: getSupportedAudioCodecsForContainer(container60)
|
|
42345
|
+
};
|
|
42346
|
+
});
|
|
42347
|
+
useEffect79(() => {
|
|
42348
|
+
const cached = cacheRef.current[container60];
|
|
42349
|
+
if (cached) {
|
|
42350
|
+
return;
|
|
42351
|
+
}
|
|
42352
|
+
const supported = getSupportedAudioCodecsForContainer(container60);
|
|
42353
|
+
cacheRef.current[container60] = {
|
|
42354
|
+
codecs: supported,
|
|
42355
|
+
status: "fetching"
|
|
42356
|
+
};
|
|
42357
|
+
getEncodableAudioCodecs(container60).then((encodable) => {
|
|
42358
|
+
cacheRef.current[container60] = {
|
|
42359
|
+
codecs: encodable,
|
|
42360
|
+
status: "done"
|
|
42361
|
+
};
|
|
42362
|
+
setCodecsByContainer((prev) => ({
|
|
42363
|
+
...prev,
|
|
42364
|
+
[container60]: encodable
|
|
42365
|
+
}));
|
|
42366
|
+
}).catch(() => {
|
|
42367
|
+
cacheRef.current[container60] = {
|
|
42368
|
+
codecs: supported,
|
|
42369
|
+
status: "done"
|
|
42370
|
+
};
|
|
42371
|
+
});
|
|
42372
|
+
}, [container60]);
|
|
42373
|
+
return codecsByContainer[container60] ?? getSupportedAudioCodecsForContainer(container60);
|
|
42374
|
+
};
|
|
42375
|
+
|
|
42376
|
+
// src/components/RenderModal/use-encodable-video-codecs.ts
|
|
42377
|
+
import {
|
|
42378
|
+
getEncodableVideoCodecs,
|
|
42379
|
+
getSupportedVideoCodecsForContainer
|
|
42380
|
+
} from "@remotion/web-renderer";
|
|
42381
|
+
import { useEffect as useEffect80, useRef as useRef45, useState as useState82 } from "react";
|
|
42382
|
+
var useEncodableVideoCodecs = (container60) => {
|
|
42383
|
+
const cacheRef = useRef45({});
|
|
42384
|
+
const [codecsByContainer, setCodecsByContainer] = useState82(() => {
|
|
42385
|
+
return {
|
|
42386
|
+
[container60]: getSupportedVideoCodecsForContainer(container60)
|
|
42387
|
+
};
|
|
42388
|
+
});
|
|
42389
|
+
useEffect80(() => {
|
|
42390
|
+
const cached = cacheRef.current[container60];
|
|
42391
|
+
if (cached) {
|
|
42392
|
+
return;
|
|
42393
|
+
}
|
|
42394
|
+
const supported = getSupportedVideoCodecsForContainer(container60);
|
|
42395
|
+
cacheRef.current[container60] = {
|
|
42396
|
+
codecs: supported,
|
|
42397
|
+
status: "fetching"
|
|
42398
|
+
};
|
|
42399
|
+
getEncodableVideoCodecs(container60).then((encodable) => {
|
|
42400
|
+
cacheRef.current[container60] = {
|
|
42401
|
+
codecs: encodable,
|
|
42402
|
+
status: "done"
|
|
42403
|
+
};
|
|
42404
|
+
setCodecsByContainer((prev) => ({
|
|
42405
|
+
...prev,
|
|
42406
|
+
[container60]: encodable
|
|
42407
|
+
}));
|
|
42408
|
+
}).catch(() => {
|
|
42409
|
+
cacheRef.current[container60] = {
|
|
42410
|
+
codecs: supported,
|
|
42411
|
+
status: "done"
|
|
42412
|
+
};
|
|
42413
|
+
});
|
|
42414
|
+
}, [container60]);
|
|
42415
|
+
return codecsByContainer[container60] ?? getSupportedVideoCodecsForContainer(container60);
|
|
42416
|
+
};
|
|
42417
|
+
|
|
42314
42418
|
// src/components/RenderModal/WebRendererExperimentalBadge.tsx
|
|
42315
42419
|
import { jsx as jsx257, jsxs as jsxs135 } from "react/jsx-runtime";
|
|
42316
42420
|
var row8 = {
|
|
@@ -42514,26 +42618,165 @@ var WebRenderModalAdvanced = ({
|
|
|
42514
42618
|
};
|
|
42515
42619
|
|
|
42516
42620
|
// src/components/RenderModal/WebRenderModalAudio.tsx
|
|
42621
|
+
import { getSupportedAudioCodecsForContainer as getSupportedAudioCodecsForContainer2 } from "@remotion/web-renderer";
|
|
42622
|
+
import { useMemo as useMemo130 } from "react";
|
|
42623
|
+
|
|
42624
|
+
// src/components/RenderModal/quality-options.tsx
|
|
42517
42625
|
import { jsx as jsx259 } from "react/jsx-runtime";
|
|
42626
|
+
var QUALITY_OPTIONS = [
|
|
42627
|
+
{ value: "very-low", label: "Very Low" },
|
|
42628
|
+
{ value: "low", label: "Low" },
|
|
42629
|
+
{ value: "medium", label: "Medium" },
|
|
42630
|
+
{ value: "high", label: "High" },
|
|
42631
|
+
{ value: "very-high", label: "Very High" }
|
|
42632
|
+
];
|
|
42633
|
+
var getQualityOptions = (selectedQuality, setQuality) => {
|
|
42634
|
+
return QUALITY_OPTIONS.map(({ value, label: label11 }) => ({
|
|
42635
|
+
label: label11,
|
|
42636
|
+
onClick: () => setQuality(value),
|
|
42637
|
+
leftItem: selectedQuality === value ? /* @__PURE__ */ jsx259(Checkmark, {}) : null,
|
|
42638
|
+
id: value,
|
|
42639
|
+
keyHint: null,
|
|
42640
|
+
quickSwitcherLabel: null,
|
|
42641
|
+
subMenu: null,
|
|
42642
|
+
type: "item",
|
|
42643
|
+
value
|
|
42644
|
+
}));
|
|
42645
|
+
};
|
|
42646
|
+
|
|
42647
|
+
// src/components/RenderModal/WebRenderModalAudio.tsx
|
|
42648
|
+
import { jsx as jsx260, jsxs as jsxs137, Fragment as Fragment45 } from "react/jsx-runtime";
|
|
42518
42649
|
var container60 = {
|
|
42519
42650
|
flex: 1,
|
|
42520
42651
|
overflowY: "auto"
|
|
42521
42652
|
};
|
|
42522
|
-
var
|
|
42523
|
-
|
|
42653
|
+
var fallbackNoticeStyle = {
|
|
42654
|
+
backgroundColor: "rgba(59, 130, 246, 0.15)",
|
|
42655
|
+
border: "1px solid rgba(59, 130, 246, 0.4)",
|
|
42656
|
+
borderRadius: 4,
|
|
42657
|
+
padding: "8px 12px",
|
|
42658
|
+
marginLeft: 16,
|
|
42659
|
+
marginRight: 16,
|
|
42660
|
+
marginTop: 8,
|
|
42661
|
+
fontSize: 13,
|
|
42662
|
+
lineHeight: 1.4,
|
|
42663
|
+
color: "#60a5fa"
|
|
42664
|
+
};
|
|
42665
|
+
var humanReadableWebAudioCodec = (audioCodec) => {
|
|
42666
|
+
switch (audioCodec) {
|
|
42667
|
+
case "aac":
|
|
42668
|
+
return "AAC";
|
|
42669
|
+
case "opus":
|
|
42670
|
+
return "Opus";
|
|
42671
|
+
default:
|
|
42672
|
+
return audioCodec;
|
|
42673
|
+
}
|
|
42674
|
+
};
|
|
42675
|
+
var WebRenderModalAudio = ({
|
|
42676
|
+
muted,
|
|
42677
|
+
setMuted,
|
|
42678
|
+
audioCodec,
|
|
42679
|
+
setAudioCodec,
|
|
42680
|
+
audioBitrate,
|
|
42681
|
+
setAudioBitrate,
|
|
42682
|
+
container: videoContainer,
|
|
42683
|
+
encodableCodecs,
|
|
42684
|
+
effectiveAudioCodec
|
|
42685
|
+
}) => {
|
|
42686
|
+
const containerSupported = useMemo130(() => getSupportedAudioCodecsForContainer2(videoContainer), [videoContainer]);
|
|
42687
|
+
const audioCodecOptions = useMemo130(() => {
|
|
42688
|
+
return containerSupported.map((codec) => {
|
|
42689
|
+
const isEncodable = encodableCodecs.includes(codec);
|
|
42690
|
+
return {
|
|
42691
|
+
label: humanReadableWebAudioCodec(codec),
|
|
42692
|
+
onClick: () => setAudioCodec(codec),
|
|
42693
|
+
leftItem: audioCodec === codec ? /* @__PURE__ */ jsx260(Checkmark, {}) : null,
|
|
42694
|
+
id: codec,
|
|
42695
|
+
keyHint: null,
|
|
42696
|
+
quickSwitcherLabel: null,
|
|
42697
|
+
subMenu: null,
|
|
42698
|
+
type: "item",
|
|
42699
|
+
value: codec,
|
|
42700
|
+
disabled: !isEncodable
|
|
42701
|
+
};
|
|
42702
|
+
});
|
|
42703
|
+
}, [containerSupported, encodableCodecs, audioCodec, setAudioCodec]);
|
|
42704
|
+
const audioBitrateOptions = useMemo130(() => getQualityOptions(audioBitrate, setAudioBitrate), [audioBitrate, setAudioBitrate]);
|
|
42705
|
+
return /* @__PURE__ */ jsxs137("div", {
|
|
42524
42706
|
style: container60,
|
|
42525
42707
|
className: VERTICAL_SCROLLBAR_CLASSNAME,
|
|
42526
|
-
children:
|
|
42527
|
-
|
|
42528
|
-
|
|
42529
|
-
|
|
42530
|
-
|
|
42708
|
+
children: [
|
|
42709
|
+
/* @__PURE__ */ jsx260(MutedSetting, {
|
|
42710
|
+
enforceAudioTrack: false,
|
|
42711
|
+
muted,
|
|
42712
|
+
setMuted
|
|
42713
|
+
}),
|
|
42714
|
+
!muted ? /* @__PURE__ */ jsxs137(Fragment45, {
|
|
42715
|
+
children: [
|
|
42716
|
+
/* @__PURE__ */ jsx260(RenderModalHr, {}),
|
|
42717
|
+
/* @__PURE__ */ jsxs137("div", {
|
|
42718
|
+
style: optionRow,
|
|
42719
|
+
children: [
|
|
42720
|
+
/* @__PURE__ */ jsxs137("div", {
|
|
42721
|
+
style: label5,
|
|
42722
|
+
children: [
|
|
42723
|
+
"Audio Quality",
|
|
42724
|
+
/* @__PURE__ */ jsx260(Spacing, {
|
|
42725
|
+
x: 0.5
|
|
42726
|
+
})
|
|
42727
|
+
]
|
|
42728
|
+
}),
|
|
42729
|
+
/* @__PURE__ */ jsx260("div", {
|
|
42730
|
+
style: rightRow,
|
|
42731
|
+
children: /* @__PURE__ */ jsx260(Combobox, {
|
|
42732
|
+
values: audioBitrateOptions,
|
|
42733
|
+
selectedId: audioBitrate,
|
|
42734
|
+
title: "Audio Quality"
|
|
42735
|
+
})
|
|
42736
|
+
})
|
|
42737
|
+
]
|
|
42738
|
+
}),
|
|
42739
|
+
/* @__PURE__ */ jsxs137("div", {
|
|
42740
|
+
style: optionRow,
|
|
42741
|
+
children: [
|
|
42742
|
+
/* @__PURE__ */ jsxs137("div", {
|
|
42743
|
+
style: label5,
|
|
42744
|
+
children: [
|
|
42745
|
+
"Audio Codec",
|
|
42746
|
+
/* @__PURE__ */ jsx260(Spacing, {
|
|
42747
|
+
x: 0.5
|
|
42748
|
+
})
|
|
42749
|
+
]
|
|
42750
|
+
}),
|
|
42751
|
+
/* @__PURE__ */ jsx260("div", {
|
|
42752
|
+
style: rightRow,
|
|
42753
|
+
children: /* @__PURE__ */ jsx260(Combobox, {
|
|
42754
|
+
values: audioCodecOptions,
|
|
42755
|
+
selectedId: audioCodec,
|
|
42756
|
+
title: "Audio Codec"
|
|
42757
|
+
})
|
|
42758
|
+
})
|
|
42759
|
+
]
|
|
42760
|
+
}),
|
|
42761
|
+
effectiveAudioCodec !== audioCodec ? /* @__PURE__ */ jsxs137("div", {
|
|
42762
|
+
style: fallbackNoticeStyle,
|
|
42763
|
+
children: [
|
|
42764
|
+
humanReadableWebAudioCodec(audioCodec),
|
|
42765
|
+
" is not available in this browser. Using ",
|
|
42766
|
+
humanReadableWebAudioCodec(effectiveAudioCodec),
|
|
42767
|
+
" ",
|
|
42768
|
+
"instead."
|
|
42769
|
+
]
|
|
42770
|
+
}) : null
|
|
42771
|
+
]
|
|
42772
|
+
}) : null
|
|
42773
|
+
]
|
|
42531
42774
|
});
|
|
42532
42775
|
};
|
|
42533
42776
|
|
|
42534
42777
|
// src/components/RenderModal/WebRenderModalBasic.tsx
|
|
42535
|
-
import { useMemo as
|
|
42536
|
-
import { jsx as
|
|
42778
|
+
import { useMemo as useMemo131 } from "react";
|
|
42779
|
+
import { jsx as jsx261, jsxs as jsxs138, Fragment as Fragment46 } from "react/jsx-runtime";
|
|
42537
42780
|
var tabContainer2 = {
|
|
42538
42781
|
flex: 1
|
|
42539
42782
|
};
|
|
@@ -42547,8 +42790,9 @@ var WebRenderModalBasic = ({
|
|
|
42547
42790
|
onFrameSetDirectly,
|
|
42548
42791
|
container: container61,
|
|
42549
42792
|
setContainerFormat,
|
|
42550
|
-
codec,
|
|
42551
42793
|
setCodec,
|
|
42794
|
+
encodableVideoCodecs,
|
|
42795
|
+
effectiveVideoCodec,
|
|
42552
42796
|
startFrame,
|
|
42553
42797
|
setStartFrame,
|
|
42554
42798
|
endFrame,
|
|
@@ -42559,7 +42803,7 @@ var WebRenderModalBasic = ({
|
|
|
42559
42803
|
logLevel,
|
|
42560
42804
|
setLogLevel
|
|
42561
42805
|
}) => {
|
|
42562
|
-
const imageFormatOptions =
|
|
42806
|
+
const imageFormatOptions = useMemo131(() => {
|
|
42563
42807
|
return [
|
|
42564
42808
|
{
|
|
42565
42809
|
label: "PNG",
|
|
@@ -42581,12 +42825,12 @@ var WebRenderModalBasic = ({
|
|
|
42581
42825
|
}
|
|
42582
42826
|
];
|
|
42583
42827
|
}, [imageFormat, setStillFormat]);
|
|
42584
|
-
const logLevelOptions =
|
|
42828
|
+
const logLevelOptions = useMemo131(() => {
|
|
42585
42829
|
return ["trace", "verbose", "info", "warn", "error"].map((level) => {
|
|
42586
42830
|
return {
|
|
42587
42831
|
label: humanReadableLogLevel(level),
|
|
42588
42832
|
onClick: () => setLogLevel(level),
|
|
42589
|
-
leftItem: logLevel === level ? /* @__PURE__ */
|
|
42833
|
+
leftItem: logLevel === level ? /* @__PURE__ */ jsx261(Checkmark, {}) : null,
|
|
42590
42834
|
id: level,
|
|
42591
42835
|
keyHint: null,
|
|
42592
42836
|
quickSwitcherLabel: null,
|
|
@@ -42596,12 +42840,12 @@ var WebRenderModalBasic = ({
|
|
|
42596
42840
|
};
|
|
42597
42841
|
});
|
|
42598
42842
|
}, [logLevel, setLogLevel]);
|
|
42599
|
-
const containerOptions =
|
|
42843
|
+
const containerOptions = useMemo131(() => {
|
|
42600
42844
|
return [
|
|
42601
42845
|
{
|
|
42602
42846
|
label: "MP4",
|
|
42603
42847
|
onClick: () => setContainerFormat("mp4"),
|
|
42604
|
-
leftItem: container61 === "mp4" ? /* @__PURE__ */
|
|
42848
|
+
leftItem: container61 === "mp4" ? /* @__PURE__ */ jsx261(Checkmark, {}) : null,
|
|
42605
42849
|
id: "mp4",
|
|
42606
42850
|
keyHint: null,
|
|
42607
42851
|
quickSwitcherLabel: null,
|
|
@@ -42612,7 +42856,7 @@ var WebRenderModalBasic = ({
|
|
|
42612
42856
|
{
|
|
42613
42857
|
label: "WebM",
|
|
42614
42858
|
onClick: () => setContainerFormat("webm"),
|
|
42615
|
-
leftItem: container61 === "webm" ? /* @__PURE__ */
|
|
42859
|
+
leftItem: container61 === "webm" ? /* @__PURE__ */ jsx261(Checkmark, {}) : null,
|
|
42616
42860
|
id: "webm",
|
|
42617
42861
|
keyHint: null,
|
|
42618
42862
|
quickSwitcherLabel: null,
|
|
@@ -42622,97 +42866,58 @@ var WebRenderModalBasic = ({
|
|
|
42622
42866
|
}
|
|
42623
42867
|
];
|
|
42624
42868
|
}, [container61, setContainerFormat]);
|
|
42625
|
-
const
|
|
42626
|
-
|
|
42627
|
-
|
|
42628
|
-
|
|
42629
|
-
|
|
42630
|
-
|
|
42631
|
-
|
|
42632
|
-
|
|
42633
|
-
|
|
42634
|
-
|
|
42635
|
-
|
|
42636
|
-
|
|
42637
|
-
|
|
42638
|
-
|
|
42639
|
-
|
|
42640
|
-
|
|
42641
|
-
|
|
42642
|
-
|
|
42643
|
-
|
|
42644
|
-
|
|
42645
|
-
|
|
42646
|
-
type: "item",
|
|
42647
|
-
value: "h265"
|
|
42648
|
-
},
|
|
42649
|
-
{
|
|
42650
|
-
label: "VP8",
|
|
42651
|
-
onClick: () => setCodec("vp8"),
|
|
42652
|
-
leftItem: codec === "vp8" ? /* @__PURE__ */ jsx260(Checkmark, {}) : null,
|
|
42653
|
-
id: "vp8",
|
|
42654
|
-
keyHint: null,
|
|
42655
|
-
quickSwitcherLabel: null,
|
|
42656
|
-
subMenu: null,
|
|
42657
|
-
type: "item",
|
|
42658
|
-
value: "vp8"
|
|
42659
|
-
},
|
|
42660
|
-
{
|
|
42661
|
-
label: "VP9",
|
|
42662
|
-
onClick: () => setCodec("vp9"),
|
|
42663
|
-
leftItem: codec === "vp9" ? /* @__PURE__ */ jsx260(Checkmark, {}) : null,
|
|
42664
|
-
id: "vp9",
|
|
42665
|
-
keyHint: null,
|
|
42666
|
-
quickSwitcherLabel: null,
|
|
42667
|
-
subMenu: null,
|
|
42668
|
-
type: "item",
|
|
42669
|
-
value: "vp9"
|
|
42670
|
-
},
|
|
42671
|
-
{
|
|
42672
|
-
label: "AV1",
|
|
42673
|
-
onClick: () => setCodec("av1"),
|
|
42674
|
-
leftItem: codec === "av1" ? /* @__PURE__ */ jsx260(Checkmark, {}) : null,
|
|
42675
|
-
id: "av1",
|
|
42676
|
-
keyHint: null,
|
|
42677
|
-
quickSwitcherLabel: null,
|
|
42678
|
-
subMenu: null,
|
|
42679
|
-
type: "item",
|
|
42680
|
-
value: "av1"
|
|
42681
|
-
}
|
|
42682
|
-
];
|
|
42683
|
-
}, [codec, setCodec]);
|
|
42684
|
-
return /* @__PURE__ */ jsxs137("div", {
|
|
42869
|
+
const codecLabels = useMemo131(() => ({
|
|
42870
|
+
h264: "H.264",
|
|
42871
|
+
h265: "H.265",
|
|
42872
|
+
vp8: "VP8",
|
|
42873
|
+
vp9: "VP9",
|
|
42874
|
+
av1: "AV1"
|
|
42875
|
+
}), []);
|
|
42876
|
+
const codecOptions = useMemo131(() => {
|
|
42877
|
+
return encodableVideoCodecs.map((c) => ({
|
|
42878
|
+
label: codecLabels[c],
|
|
42879
|
+
onClick: () => setCodec(c),
|
|
42880
|
+
leftItem: effectiveVideoCodec === c ? /* @__PURE__ */ jsx261(Checkmark, {}) : null,
|
|
42881
|
+
id: c,
|
|
42882
|
+
keyHint: null,
|
|
42883
|
+
quickSwitcherLabel: null,
|
|
42884
|
+
subMenu: null,
|
|
42885
|
+
type: "item",
|
|
42886
|
+
value: c
|
|
42887
|
+
}));
|
|
42888
|
+
}, [encodableVideoCodecs, effectiveVideoCodec, setCodec, codecLabels]);
|
|
42889
|
+
return /* @__PURE__ */ jsxs138("div", {
|
|
42685
42890
|
style: tabContainer2,
|
|
42686
42891
|
children: [
|
|
42687
|
-
renderMode === "still" ? /* @__PURE__ */
|
|
42892
|
+
renderMode === "still" ? /* @__PURE__ */ jsxs138(Fragment46, {
|
|
42688
42893
|
children: [
|
|
42689
|
-
/* @__PURE__ */
|
|
42894
|
+
/* @__PURE__ */ jsxs138("div", {
|
|
42690
42895
|
style: optionRow,
|
|
42691
42896
|
children: [
|
|
42692
|
-
/* @__PURE__ */
|
|
42897
|
+
/* @__PURE__ */ jsx261("div", {
|
|
42693
42898
|
style: label5,
|
|
42694
42899
|
children: "Format"
|
|
42695
42900
|
}),
|
|
42696
|
-
/* @__PURE__ */
|
|
42901
|
+
/* @__PURE__ */ jsx261("div", {
|
|
42697
42902
|
style: rightRow,
|
|
42698
|
-
children: /* @__PURE__ */
|
|
42903
|
+
children: /* @__PURE__ */ jsx261(SegmentedControl, {
|
|
42699
42904
|
items: imageFormatOptions,
|
|
42700
42905
|
needsWrapping: true
|
|
42701
42906
|
})
|
|
42702
42907
|
})
|
|
42703
42908
|
]
|
|
42704
42909
|
}),
|
|
42705
|
-
resolvedComposition.durationInFrames > 1 ? /* @__PURE__ */
|
|
42910
|
+
resolvedComposition.durationInFrames > 1 ? /* @__PURE__ */ jsxs138("div", {
|
|
42706
42911
|
style: optionRow,
|
|
42707
42912
|
children: [
|
|
42708
|
-
/* @__PURE__ */
|
|
42913
|
+
/* @__PURE__ */ jsx261("div", {
|
|
42709
42914
|
style: label5,
|
|
42710
42915
|
children: "Frame"
|
|
42711
42916
|
}),
|
|
42712
|
-
/* @__PURE__ */
|
|
42917
|
+
/* @__PURE__ */ jsx261("div", {
|
|
42713
42918
|
style: rightRow,
|
|
42714
|
-
children: /* @__PURE__ */
|
|
42715
|
-
children: /* @__PURE__ */
|
|
42919
|
+
children: /* @__PURE__ */ jsx261(RightAlignInput, {
|
|
42920
|
+
children: /* @__PURE__ */ jsx261(InputDragger, {
|
|
42716
42921
|
value: frame2,
|
|
42717
42922
|
onTextChange: onFrameChanged,
|
|
42718
42923
|
placeholder: `0-${resolvedComposition.durationInFrames - 1}`,
|
|
@@ -42729,18 +42934,18 @@ var WebRenderModalBasic = ({
|
|
|
42729
42934
|
]
|
|
42730
42935
|
}) : null
|
|
42731
42936
|
]
|
|
42732
|
-
}) : /* @__PURE__ */
|
|
42937
|
+
}) : /* @__PURE__ */ jsxs138(Fragment46, {
|
|
42733
42938
|
children: [
|
|
42734
|
-
/* @__PURE__ */
|
|
42939
|
+
/* @__PURE__ */ jsxs138("div", {
|
|
42735
42940
|
style: optionRow,
|
|
42736
42941
|
children: [
|
|
42737
|
-
/* @__PURE__ */
|
|
42942
|
+
/* @__PURE__ */ jsx261("div", {
|
|
42738
42943
|
style: label5,
|
|
42739
42944
|
children: "Container"
|
|
42740
42945
|
}),
|
|
42741
|
-
/* @__PURE__ */
|
|
42946
|
+
/* @__PURE__ */ jsx261("div", {
|
|
42742
42947
|
style: rightRow,
|
|
42743
|
-
children: /* @__PURE__ */
|
|
42948
|
+
children: /* @__PURE__ */ jsx261(Combobox, {
|
|
42744
42949
|
values: containerOptions,
|
|
42745
42950
|
selectedId: container61,
|
|
42746
42951
|
title: "Container"
|
|
@@ -42748,32 +42953,32 @@ var WebRenderModalBasic = ({
|
|
|
42748
42953
|
})
|
|
42749
42954
|
]
|
|
42750
42955
|
}),
|
|
42751
|
-
/* @__PURE__ */
|
|
42956
|
+
/* @__PURE__ */ jsxs138("div", {
|
|
42752
42957
|
style: optionRow,
|
|
42753
42958
|
children: [
|
|
42754
|
-
/* @__PURE__ */
|
|
42959
|
+
/* @__PURE__ */ jsxs138("div", {
|
|
42755
42960
|
style: label5,
|
|
42756
42961
|
children: [
|
|
42757
42962
|
"Codec",
|
|
42758
|
-
/* @__PURE__ */
|
|
42963
|
+
/* @__PURE__ */ jsx261(Spacing, {
|
|
42759
42964
|
x: 0.5
|
|
42760
42965
|
}),
|
|
42761
|
-
/* @__PURE__ */
|
|
42966
|
+
/* @__PURE__ */ jsx261(OptionExplainerBubble, {
|
|
42762
42967
|
id: "videoCodecOption"
|
|
42763
42968
|
})
|
|
42764
42969
|
]
|
|
42765
42970
|
}),
|
|
42766
|
-
/* @__PURE__ */
|
|
42971
|
+
/* @__PURE__ */ jsx261("div", {
|
|
42767
42972
|
style: rightRow,
|
|
42768
|
-
children: /* @__PURE__ */
|
|
42973
|
+
children: /* @__PURE__ */ jsx261(Combobox, {
|
|
42769
42974
|
values: codecOptions,
|
|
42770
|
-
selectedId:
|
|
42975
|
+
selectedId: effectiveVideoCodec,
|
|
42771
42976
|
title: "Codec"
|
|
42772
42977
|
})
|
|
42773
42978
|
})
|
|
42774
42979
|
]
|
|
42775
42980
|
}),
|
|
42776
|
-
/* @__PURE__ */
|
|
42981
|
+
/* @__PURE__ */ jsx261(FrameRangeSetting, {
|
|
42777
42982
|
durationInFrames: resolvedComposition.durationInFrames,
|
|
42778
42983
|
startFrame: startFrame ?? 0,
|
|
42779
42984
|
endFrame: endFrame ?? resolvedComposition.durationInFrames - 1,
|
|
@@ -42782,7 +42987,7 @@ var WebRenderModalBasic = ({
|
|
|
42782
42987
|
})
|
|
42783
42988
|
]
|
|
42784
42989
|
}),
|
|
42785
|
-
/* @__PURE__ */
|
|
42990
|
+
/* @__PURE__ */ jsx261(RenderModalOutputName, {
|
|
42786
42991
|
existence: false,
|
|
42787
42992
|
inputStyle: input,
|
|
42788
42993
|
outName,
|
|
@@ -42790,24 +42995,24 @@ var WebRenderModalBasic = ({
|
|
|
42790
42995
|
validationMessage,
|
|
42791
42996
|
label: "Download name"
|
|
42792
42997
|
}),
|
|
42793
|
-
/* @__PURE__ */
|
|
42998
|
+
/* @__PURE__ */ jsxs138("div", {
|
|
42794
42999
|
style: optionRow,
|
|
42795
43000
|
children: [
|
|
42796
|
-
/* @__PURE__ */
|
|
43001
|
+
/* @__PURE__ */ jsxs138("div", {
|
|
42797
43002
|
style: label5,
|
|
42798
43003
|
children: [
|
|
42799
43004
|
"Log Level ",
|
|
42800
|
-
/* @__PURE__ */
|
|
43005
|
+
/* @__PURE__ */ jsx261(Spacing, {
|
|
42801
43006
|
x: 0.5
|
|
42802
43007
|
}),
|
|
42803
|
-
/* @__PURE__ */
|
|
43008
|
+
/* @__PURE__ */ jsx261(OptionExplainerBubble, {
|
|
42804
43009
|
id: "logLevelOption"
|
|
42805
43010
|
})
|
|
42806
43011
|
]
|
|
42807
43012
|
}),
|
|
42808
|
-
/* @__PURE__ */
|
|
43013
|
+
/* @__PURE__ */ jsx261("div", {
|
|
42809
43014
|
style: rightRow,
|
|
42810
|
-
children: /* @__PURE__ */
|
|
43015
|
+
children: /* @__PURE__ */ jsx261(Combobox, {
|
|
42811
43016
|
values: logLevelOptions,
|
|
42812
43017
|
selectedId: logLevel,
|
|
42813
43018
|
title: "Log Level"
|
|
@@ -42820,8 +43025,8 @@ var WebRenderModalBasic = ({
|
|
|
42820
43025
|
};
|
|
42821
43026
|
|
|
42822
43027
|
// src/components/RenderModal/WebRenderModalLicense.tsx
|
|
42823
|
-
import { useCallback as useCallback128, useMemo as
|
|
42824
|
-
import { jsx as
|
|
43028
|
+
import { useCallback as useCallback128, useMemo as useMemo132 } from "react";
|
|
43029
|
+
import { jsx as jsx262, jsxs as jsxs139, Fragment as Fragment47 } from "react/jsx-runtime";
|
|
42825
43030
|
var row9 = {
|
|
42826
43031
|
display: "flex",
|
|
42827
43032
|
flexDirection: "row",
|
|
@@ -42935,21 +43140,21 @@ var WebRenderModalLicense = ({
|
|
|
42935
43140
|
const onLicenseKeyChange = useCallback128((e) => {
|
|
42936
43141
|
setLicenseKey(e.target.value);
|
|
42937
43142
|
}, [setLicenseKey]);
|
|
42938
|
-
const licenseValidation =
|
|
43143
|
+
const licenseValidation = useMemo132(() => {
|
|
42939
43144
|
if (licenseKey === null || licenseKey === "free-license") {
|
|
42940
43145
|
return { valid: true, message: null };
|
|
42941
43146
|
}
|
|
42942
43147
|
return validateLicenseKey(licenseKey);
|
|
42943
43148
|
}, [licenseKey]);
|
|
42944
|
-
return /* @__PURE__ */
|
|
43149
|
+
return /* @__PURE__ */ jsxs139("div", {
|
|
42945
43150
|
style: tabContainer3,
|
|
42946
43151
|
children: [
|
|
42947
|
-
/* @__PURE__ */
|
|
43152
|
+
/* @__PURE__ */ jsxs139("div", {
|
|
42948
43153
|
style: descriptionStyle,
|
|
42949
43154
|
children: [
|
|
42950
43155
|
"Remotion is free if you are an individual or company with a headcount of 3 or less. See",
|
|
42951
43156
|
" ",
|
|
42952
|
-
/* @__PURE__ */
|
|
43157
|
+
/* @__PURE__ */ jsx262("a", {
|
|
42953
43158
|
style: descriptionLink,
|
|
42954
43159
|
href: "https://remotion.dev/license",
|
|
42955
43160
|
children: "LICENSE.md"
|
|
@@ -42957,18 +43162,18 @@ var WebRenderModalLicense = ({
|
|
|
42957
43162
|
"."
|
|
42958
43163
|
]
|
|
42959
43164
|
}),
|
|
42960
|
-
/* @__PURE__ */
|
|
43165
|
+
/* @__PURE__ */ jsx262("div", {
|
|
42961
43166
|
style: row9,
|
|
42962
|
-
children: /* @__PURE__ */
|
|
43167
|
+
children: /* @__PURE__ */ jsxs139("div", {
|
|
42963
43168
|
style: justifyCenter,
|
|
42964
43169
|
children: [
|
|
42965
|
-
/* @__PURE__ */
|
|
43170
|
+
/* @__PURE__ */ jsx262(Checkbox, {
|
|
42966
43171
|
checked: licenseKey === "free-license",
|
|
42967
43172
|
onChange: onFreeLicenseChange,
|
|
42968
43173
|
name: "free-license",
|
|
42969
43174
|
rounded: true
|
|
42970
43175
|
}),
|
|
42971
|
-
/* @__PURE__ */
|
|
43176
|
+
/* @__PURE__ */ jsxs139("div", {
|
|
42972
43177
|
style: checkboxLabel,
|
|
42973
43178
|
onClick: onFreeLicenseChange,
|
|
42974
43179
|
children: [
|
|
@@ -42980,34 +43185,34 @@ var WebRenderModalLicense = ({
|
|
|
42980
43185
|
]
|
|
42981
43186
|
})
|
|
42982
43187
|
}),
|
|
42983
|
-
licenseKey === "free-license" ? /* @__PURE__ */
|
|
43188
|
+
licenseKey === "free-license" ? /* @__PURE__ */ jsxs139("div", {
|
|
42984
43189
|
style: paddedDescriptionStyle,
|
|
42985
43190
|
children: [
|
|
42986
43191
|
"Enjoy Remotion! Add the following to",
|
|
42987
43192
|
" ",
|
|
42988
|
-
/* @__PURE__ */
|
|
43193
|
+
/* @__PURE__ */ jsx262("code", {
|
|
42989
43194
|
style: codeStyle,
|
|
42990
43195
|
children: "remotion.config.ts"
|
|
42991
43196
|
}),
|
|
42992
43197
|
" to persist this setting:",
|
|
42993
|
-
/* @__PURE__ */
|
|
43198
|
+
/* @__PURE__ */ jsx262("div", {
|
|
42994
43199
|
style: codeLine,
|
|
42995
43200
|
children: "Config.setPublicLicenseKey('free-license');"
|
|
42996
43201
|
})
|
|
42997
43202
|
]
|
|
42998
43203
|
}) : null,
|
|
42999
|
-
/* @__PURE__ */
|
|
43204
|
+
/* @__PURE__ */ jsx262("div", {
|
|
43000
43205
|
style: row9,
|
|
43001
|
-
children: /* @__PURE__ */
|
|
43206
|
+
children: /* @__PURE__ */ jsxs139("div", {
|
|
43002
43207
|
style: justifyCenter,
|
|
43003
43208
|
children: [
|
|
43004
|
-
/* @__PURE__ */
|
|
43209
|
+
/* @__PURE__ */ jsx262(Checkbox, {
|
|
43005
43210
|
checked: licenseKey !== "free-license" && licenseKey !== null,
|
|
43006
43211
|
onChange: onCompanyLicenseChange,
|
|
43007
43212
|
name: "company-license",
|
|
43008
43213
|
rounded: true
|
|
43009
43214
|
}),
|
|
43010
|
-
/* @__PURE__ */
|
|
43215
|
+
/* @__PURE__ */ jsx262("div", {
|
|
43011
43216
|
style: checkboxLabel,
|
|
43012
43217
|
onClick: onCompanyLicenseChange,
|
|
43013
43218
|
children: "I have a Company License"
|
|
@@ -43015,12 +43220,12 @@ var WebRenderModalLicense = ({
|
|
|
43015
43220
|
]
|
|
43016
43221
|
})
|
|
43017
43222
|
}),
|
|
43018
|
-
licenseKey !== "free-license" && licenseKey !== null ? /* @__PURE__ */
|
|
43223
|
+
licenseKey !== "free-license" && licenseKey !== null ? /* @__PURE__ */ jsxs139("div", {
|
|
43019
43224
|
style: paddedDescriptionStyle,
|
|
43020
43225
|
children: [
|
|
43021
43226
|
"Add your public license from",
|
|
43022
43227
|
" ",
|
|
43023
|
-
/* @__PURE__ */
|
|
43228
|
+
/* @__PURE__ */ jsx262("a", {
|
|
43024
43229
|
href: "https://remotion.pro/dashboard",
|
|
43025
43230
|
target: "_blank",
|
|
43026
43231
|
style: descriptionLink,
|
|
@@ -43028,11 +43233,11 @@ var WebRenderModalLicense = ({
|
|
|
43028
43233
|
}),
|
|
43029
43234
|
" ",
|
|
43030
43235
|
"key below.",
|
|
43031
|
-
/* @__PURE__ */
|
|
43236
|
+
/* @__PURE__ */ jsx262(Spacing, {
|
|
43032
43237
|
y: 1,
|
|
43033
43238
|
block: true
|
|
43034
43239
|
}),
|
|
43035
|
-
/* @__PURE__ */
|
|
43240
|
+
/* @__PURE__ */ jsx262(RemotionInput, {
|
|
43036
43241
|
value: licenseKey,
|
|
43037
43242
|
onChange: onLicenseKeyChange,
|
|
43038
43243
|
placeholder: "remotion.pro public license key (starts with rm_pub_)",
|
|
@@ -43041,33 +43246,33 @@ var WebRenderModalLicense = ({
|
|
|
43041
43246
|
style: inputStyle2,
|
|
43042
43247
|
autoFocus: true
|
|
43043
43248
|
}),
|
|
43044
|
-
licenseValidation.message ? /* @__PURE__ */
|
|
43249
|
+
licenseValidation.message ? /* @__PURE__ */ jsxs139(Fragment47, {
|
|
43045
43250
|
children: [
|
|
43046
|
-
/* @__PURE__ */
|
|
43251
|
+
/* @__PURE__ */ jsx262(Spacing, {
|
|
43047
43252
|
y: 1,
|
|
43048
43253
|
block: true
|
|
43049
43254
|
}),
|
|
43050
|
-
/* @__PURE__ */
|
|
43255
|
+
/* @__PURE__ */ jsx262(ValidationMessage, {
|
|
43051
43256
|
message: licenseValidation.message,
|
|
43052
43257
|
align: "flex-start",
|
|
43053
43258
|
type: "error"
|
|
43054
43259
|
})
|
|
43055
43260
|
]
|
|
43056
43261
|
}) : null,
|
|
43057
|
-
licenseValidation.valid && licenseKey.length > 0 ? /* @__PURE__ */
|
|
43262
|
+
licenseValidation.valid && licenseKey.length > 0 ? /* @__PURE__ */ jsxs139(Fragment47, {
|
|
43058
43263
|
children: [
|
|
43059
|
-
/* @__PURE__ */
|
|
43264
|
+
/* @__PURE__ */ jsx262(Spacing, {
|
|
43060
43265
|
y: 1,
|
|
43061
43266
|
block: true
|
|
43062
43267
|
}),
|
|
43063
43268
|
"Add the following to",
|
|
43064
43269
|
" ",
|
|
43065
|
-
/* @__PURE__ */
|
|
43270
|
+
/* @__PURE__ */ jsx262("code", {
|
|
43066
43271
|
style: codeStyle,
|
|
43067
43272
|
children: "remotion.config.ts"
|
|
43068
43273
|
}),
|
|
43069
43274
|
" to persist this setting:",
|
|
43070
|
-
/* @__PURE__ */
|
|
43275
|
+
/* @__PURE__ */ jsx262("div", {
|
|
43071
43276
|
style: codeLineSmall,
|
|
43072
43277
|
children: "Config.setPublicLicenseKey('" + licenseKey + "');"
|
|
43073
43278
|
})
|
|
@@ -43075,12 +43280,12 @@ var WebRenderModalLicense = ({
|
|
|
43075
43280
|
}) : null
|
|
43076
43281
|
]
|
|
43077
43282
|
}) : null,
|
|
43078
|
-
licenseKey === null ? /* @__PURE__ */
|
|
43283
|
+
licenseKey === null ? /* @__PURE__ */ jsxs139("div", {
|
|
43079
43284
|
style: descriptionStyle,
|
|
43080
43285
|
children: [
|
|
43081
43286
|
"If you are not eligible for the free license, you need to obtain a",
|
|
43082
43287
|
" ",
|
|
43083
|
-
/* @__PURE__ */
|
|
43288
|
+
/* @__PURE__ */ jsx262("a", {
|
|
43084
43289
|
style: descriptionLink,
|
|
43085
43290
|
target: "_blank",
|
|
43086
43291
|
href: "https://remotion.pro/license",
|
|
@@ -43094,8 +43299,8 @@ var WebRenderModalLicense = ({
|
|
|
43094
43299
|
};
|
|
43095
43300
|
|
|
43096
43301
|
// src/components/RenderModal/WebRenderModalPicture.tsx
|
|
43097
|
-
import { useCallback as useCallback129, useMemo as
|
|
43098
|
-
import { jsx as
|
|
43302
|
+
import { useCallback as useCallback129, useMemo as useMemo133 } from "react";
|
|
43303
|
+
import { jsx as jsx263, jsxs as jsxs140 } from "react/jsx-runtime";
|
|
43099
43304
|
var tabContainer4 = {
|
|
43100
43305
|
flex: 1
|
|
43101
43306
|
};
|
|
@@ -43108,84 +43313,26 @@ var WebRenderModalPicture = ({
|
|
|
43108
43313
|
transparent,
|
|
43109
43314
|
setTransparent
|
|
43110
43315
|
}) => {
|
|
43111
|
-
const qualityOptions =
|
|
43112
|
-
return [
|
|
43113
|
-
{
|
|
43114
|
-
label: "Very Low",
|
|
43115
|
-
onClick: () => setVideoBitrate("very-low"),
|
|
43116
|
-
leftItem: videoBitrate === "very-low" ? /* @__PURE__ */ jsx262(Checkmark, {}) : null,
|
|
43117
|
-
id: "very-low",
|
|
43118
|
-
keyHint: null,
|
|
43119
|
-
quickSwitcherLabel: null,
|
|
43120
|
-
subMenu: null,
|
|
43121
|
-
type: "item",
|
|
43122
|
-
value: "very-low"
|
|
43123
|
-
},
|
|
43124
|
-
{
|
|
43125
|
-
label: "Low",
|
|
43126
|
-
onClick: () => setVideoBitrate("low"),
|
|
43127
|
-
leftItem: videoBitrate === "low" ? /* @__PURE__ */ jsx262(Checkmark, {}) : null,
|
|
43128
|
-
id: "low",
|
|
43129
|
-
keyHint: null,
|
|
43130
|
-
quickSwitcherLabel: null,
|
|
43131
|
-
subMenu: null,
|
|
43132
|
-
type: "item",
|
|
43133
|
-
value: "low"
|
|
43134
|
-
},
|
|
43135
|
-
{
|
|
43136
|
-
label: "Medium",
|
|
43137
|
-
onClick: () => setVideoBitrate("medium"),
|
|
43138
|
-
leftItem: videoBitrate === "medium" ? /* @__PURE__ */ jsx262(Checkmark, {}) : null,
|
|
43139
|
-
id: "medium",
|
|
43140
|
-
keyHint: null,
|
|
43141
|
-
quickSwitcherLabel: null,
|
|
43142
|
-
subMenu: null,
|
|
43143
|
-
type: "item",
|
|
43144
|
-
value: "medium"
|
|
43145
|
-
},
|
|
43146
|
-
{
|
|
43147
|
-
label: "High",
|
|
43148
|
-
onClick: () => setVideoBitrate("high"),
|
|
43149
|
-
leftItem: videoBitrate === "high" ? /* @__PURE__ */ jsx262(Checkmark, {}) : null,
|
|
43150
|
-
id: "high",
|
|
43151
|
-
keyHint: null,
|
|
43152
|
-
quickSwitcherLabel: null,
|
|
43153
|
-
subMenu: null,
|
|
43154
|
-
type: "item",
|
|
43155
|
-
value: "high"
|
|
43156
|
-
},
|
|
43157
|
-
{
|
|
43158
|
-
label: "Very High",
|
|
43159
|
-
onClick: () => setVideoBitrate("very-high"),
|
|
43160
|
-
leftItem: videoBitrate === "very-high" ? /* @__PURE__ */ jsx262(Checkmark, {}) : null,
|
|
43161
|
-
id: "very-high",
|
|
43162
|
-
keyHint: null,
|
|
43163
|
-
quickSwitcherLabel: null,
|
|
43164
|
-
subMenu: null,
|
|
43165
|
-
type: "item",
|
|
43166
|
-
value: "very-high"
|
|
43167
|
-
}
|
|
43168
|
-
];
|
|
43169
|
-
}, [videoBitrate, setVideoBitrate]);
|
|
43316
|
+
const qualityOptions = useMemo133(() => getQualityOptions(videoBitrate, setVideoBitrate), [videoBitrate, setVideoBitrate]);
|
|
43170
43317
|
const onTransparentChanged = useCallback129((e) => {
|
|
43171
43318
|
setTransparent(e.target.checked);
|
|
43172
43319
|
}, [setTransparent]);
|
|
43173
43320
|
if (renderMode !== "video") {
|
|
43174
43321
|
return null;
|
|
43175
43322
|
}
|
|
43176
|
-
return /* @__PURE__ */
|
|
43323
|
+
return /* @__PURE__ */ jsxs140("div", {
|
|
43177
43324
|
style: tabContainer4,
|
|
43178
43325
|
children: [
|
|
43179
|
-
/* @__PURE__ */
|
|
43326
|
+
/* @__PURE__ */ jsxs140("div", {
|
|
43180
43327
|
style: optionRow,
|
|
43181
43328
|
children: [
|
|
43182
|
-
/* @__PURE__ */
|
|
43329
|
+
/* @__PURE__ */ jsx263("div", {
|
|
43183
43330
|
style: label5,
|
|
43184
43331
|
children: "Quality"
|
|
43185
43332
|
}),
|
|
43186
|
-
/* @__PURE__ */
|
|
43333
|
+
/* @__PURE__ */ jsx263("div", {
|
|
43187
43334
|
style: rightRow,
|
|
43188
|
-
children: /* @__PURE__ */
|
|
43335
|
+
children: /* @__PURE__ */ jsx263(Combobox, {
|
|
43189
43336
|
values: qualityOptions,
|
|
43190
43337
|
selectedId: videoBitrate,
|
|
43191
43338
|
title: "Quality"
|
|
@@ -43193,7 +43340,7 @@ var WebRenderModalPicture = ({
|
|
|
43193
43340
|
})
|
|
43194
43341
|
]
|
|
43195
43342
|
}),
|
|
43196
|
-
/* @__PURE__ */
|
|
43343
|
+
/* @__PURE__ */ jsx263(NumberSetting, {
|
|
43197
43344
|
name: "Keyframe Interval",
|
|
43198
43345
|
formatter: (v) => `${v}s`,
|
|
43199
43346
|
min: 1,
|
|
@@ -43202,16 +43349,16 @@ var WebRenderModalPicture = ({
|
|
|
43202
43349
|
value: keyframeIntervalInSeconds,
|
|
43203
43350
|
onValueChanged: setKeyframeIntervalInSeconds
|
|
43204
43351
|
}),
|
|
43205
|
-
/* @__PURE__ */
|
|
43352
|
+
/* @__PURE__ */ jsxs140("div", {
|
|
43206
43353
|
style: optionRow,
|
|
43207
43354
|
children: [
|
|
43208
|
-
/* @__PURE__ */
|
|
43355
|
+
/* @__PURE__ */ jsx263("div", {
|
|
43209
43356
|
style: label5,
|
|
43210
43357
|
children: "Transparent"
|
|
43211
43358
|
}),
|
|
43212
|
-
/* @__PURE__ */
|
|
43359
|
+
/* @__PURE__ */ jsx263("div", {
|
|
43213
43360
|
style: rightRow,
|
|
43214
|
-
children: /* @__PURE__ */
|
|
43361
|
+
children: /* @__PURE__ */ jsx263(Checkbox, {
|
|
43215
43362
|
checked: transparent,
|
|
43216
43363
|
onChange: onTransparentChanged,
|
|
43217
43364
|
name: "transparent"
|
|
@@ -43224,7 +43371,7 @@ var WebRenderModalPicture = ({
|
|
|
43224
43371
|
};
|
|
43225
43372
|
|
|
43226
43373
|
// src/components/RenderModal/WebRenderModal.tsx
|
|
43227
|
-
import { jsx as
|
|
43374
|
+
import { jsx as jsx264, jsxs as jsxs141 } from "react/jsx-runtime";
|
|
43228
43375
|
var invalidCharacters2 = ["?", "*", "+", ":", "%"];
|
|
43229
43376
|
var isValidStillExtension2 = (extension, stillImageFormat) => {
|
|
43230
43377
|
if (stillImageFormat === "jpeg" && extension === "jpg") {
|
|
@@ -43284,48 +43431,64 @@ var WebRenderModal = ({
|
|
|
43284
43431
|
resolved: { result: resolvedComposition },
|
|
43285
43432
|
unresolved: unresolvedComposition
|
|
43286
43433
|
} = context;
|
|
43287
|
-
const [isVideo] =
|
|
43434
|
+
const [isVideo] = useState83(() => {
|
|
43288
43435
|
return typeof resolvedComposition.durationInFrames === "undefined" ? true : resolvedComposition.durationInFrames > 1;
|
|
43289
43436
|
});
|
|
43290
|
-
const [renderMode, setRenderMode] =
|
|
43291
|
-
const [tab, setTab] =
|
|
43292
|
-
const [imageFormat, setImageFormat] =
|
|
43293
|
-
const [frame2, setFrame] =
|
|
43294
|
-
const [logLevel, setLogLevel] =
|
|
43295
|
-
const [inputProps, setInputProps] =
|
|
43296
|
-
const [delayRenderTimeout, setDelayRenderTimeout] =
|
|
43297
|
-
const [mediaCacheSizeInBytes, setMediaCacheSizeInBytes] =
|
|
43298
|
-
const [saving, setSaving] =
|
|
43299
|
-
const [codec, setCodec] =
|
|
43300
|
-
const [container61, setContainer] =
|
|
43301
|
-
const [
|
|
43302
|
-
const [
|
|
43303
|
-
const [
|
|
43304
|
-
const [
|
|
43305
|
-
const [
|
|
43306
|
-
const [
|
|
43307
|
-
const [
|
|
43308
|
-
const [
|
|
43309
|
-
const [
|
|
43310
|
-
const
|
|
43437
|
+
const [renderMode, setRenderMode] = useState83(isVideo ? "video" : "still");
|
|
43438
|
+
const [tab, setTab] = useState83("general");
|
|
43439
|
+
const [imageFormat, setImageFormat] = useState83("png");
|
|
43440
|
+
const [frame2, setFrame] = useState83(() => initialFrame);
|
|
43441
|
+
const [logLevel, setLogLevel] = useState83(() => initialLogLevel);
|
|
43442
|
+
const [inputProps, setInputProps] = useState83(() => defaultProps);
|
|
43443
|
+
const [delayRenderTimeout, setDelayRenderTimeout] = useState83(30000);
|
|
43444
|
+
const [mediaCacheSizeInBytes, setMediaCacheSizeInBytes] = useState83(null);
|
|
43445
|
+
const [saving, setSaving] = useState83(false);
|
|
43446
|
+
const [codec, setCodec] = useState83("h264");
|
|
43447
|
+
const [container61, setContainer] = useState83("mp4");
|
|
43448
|
+
const [audioCodec, setAudioCodec] = useState83("aac");
|
|
43449
|
+
const [audioBitrate, setAudioBitrate] = useState83("medium");
|
|
43450
|
+
const [videoBitrate, setVideoBitrate] = useState83("high");
|
|
43451
|
+
const [hardwareAcceleration, setHardwareAcceleration] = useState83("no-preference");
|
|
43452
|
+
const [keyframeIntervalInSeconds, setKeyframeIntervalInSeconds] = useState83(5);
|
|
43453
|
+
const [startFrame, setStartFrame] = useState83(() => inFrameMark ?? null);
|
|
43454
|
+
const [endFrame, setEndFrame] = useState83(() => outFrameMark ?? null);
|
|
43455
|
+
const [renderProgress, setRenderProgress] = useState83(null);
|
|
43456
|
+
const [transparent, setTransparent] = useState83(false);
|
|
43457
|
+
const [muted, setMuted] = useState83(false);
|
|
43458
|
+
const [licenseKey, setLicenseKey] = useState83(initialLicenseKey);
|
|
43459
|
+
const encodableAudioCodecs = useEncodableAudioCodecs(container61);
|
|
43460
|
+
const encodableVideoCodecs = useEncodableVideoCodecs(container61);
|
|
43461
|
+
const effectiveAudioCodec = useMemo134(() => {
|
|
43462
|
+
if (encodableAudioCodecs.includes(audioCodec)) {
|
|
43463
|
+
return audioCodec;
|
|
43464
|
+
}
|
|
43465
|
+
return encodableAudioCodecs[0] ?? audioCodec;
|
|
43466
|
+
}, [audioCodec, encodableAudioCodecs]);
|
|
43467
|
+
const effectiveVideoCodec = useMemo134(() => {
|
|
43468
|
+
if (encodableVideoCodecs.includes(codec)) {
|
|
43469
|
+
return codec;
|
|
43470
|
+
}
|
|
43471
|
+
return encodableVideoCodecs[0] ?? codec;
|
|
43472
|
+
}, [codec, encodableVideoCodecs]);
|
|
43473
|
+
const finalEndFrame = useMemo134(() => {
|
|
43311
43474
|
if (endFrame === null) {
|
|
43312
43475
|
return resolvedComposition.durationInFrames - 1;
|
|
43313
43476
|
}
|
|
43314
43477
|
return Math.max(0, Math.min(resolvedComposition.durationInFrames - 1, endFrame));
|
|
43315
43478
|
}, [endFrame, resolvedComposition.durationInFrames]);
|
|
43316
|
-
const finalStartFrame =
|
|
43479
|
+
const finalStartFrame = useMemo134(() => {
|
|
43317
43480
|
if (startFrame === null) {
|
|
43318
43481
|
return 0;
|
|
43319
43482
|
}
|
|
43320
43483
|
return Math.max(0, Math.min(finalEndFrame, startFrame));
|
|
43321
43484
|
}, [finalEndFrame, startFrame]);
|
|
43322
|
-
const frameRange =
|
|
43485
|
+
const frameRange = useMemo134(() => {
|
|
43323
43486
|
if (startFrame === null && endFrame === null) {
|
|
43324
43487
|
return null;
|
|
43325
43488
|
}
|
|
43326
43489
|
return [finalStartFrame, finalEndFrame];
|
|
43327
43490
|
}, [endFrame, finalEndFrame, finalStartFrame, startFrame]);
|
|
43328
|
-
const [initialOutName] =
|
|
43491
|
+
const [initialOutName] = useState83(() => {
|
|
43329
43492
|
return getDefaultOutLocation2({
|
|
43330
43493
|
compositionName: resolvedComposition.id,
|
|
43331
43494
|
defaultExtension: renderMode === "still" ? imageFormat : isVideo ? container61 : imageFormat,
|
|
@@ -43334,7 +43497,7 @@ var WebRenderModal = ({
|
|
|
43334
43497
|
clientSideRender: true
|
|
43335
43498
|
});
|
|
43336
43499
|
});
|
|
43337
|
-
const [outName, setOutName] =
|
|
43500
|
+
const [outName, setOutName] = useState83(() => initialOutName);
|
|
43338
43501
|
const setStillFormat = useCallback130((format) => {
|
|
43339
43502
|
setImageFormat(format);
|
|
43340
43503
|
setOutName((prev) => {
|
|
@@ -43344,6 +43507,7 @@ var WebRenderModal = ({
|
|
|
43344
43507
|
}, []);
|
|
43345
43508
|
const setContainerFormat = useCallback130((newContainer) => {
|
|
43346
43509
|
setContainer(newContainer);
|
|
43510
|
+
setAudioCodec(getDefaultAudioCodecForContainer(newContainer));
|
|
43347
43511
|
setOutName((prev) => {
|
|
43348
43512
|
const newFileName = getStringBeforeSuffix(prev) + "." + newContainer;
|
|
43349
43513
|
return newFileName;
|
|
@@ -43356,14 +43520,14 @@ var WebRenderModal = ({
|
|
|
43356
43520
|
const newFileName = getStringBeforeSuffix(prev) + "." + container61;
|
|
43357
43521
|
return newFileName;
|
|
43358
43522
|
});
|
|
43359
|
-
} else {
|
|
43523
|
+
} else if (newMode === "still") {
|
|
43360
43524
|
setOutName((prev) => {
|
|
43361
43525
|
const newFileName = getStringBeforeSuffix(prev) + "." + imageFormat;
|
|
43362
43526
|
return newFileName;
|
|
43363
43527
|
});
|
|
43364
43528
|
}
|
|
43365
43529
|
}, [container61, imageFormat]);
|
|
43366
|
-
const renderTabOptions =
|
|
43530
|
+
const renderTabOptions = useMemo134(() => {
|
|
43367
43531
|
const options = [
|
|
43368
43532
|
{
|
|
43369
43533
|
label: "Still",
|
|
@@ -43401,7 +43565,7 @@ var WebRenderModal = ({
|
|
|
43401
43565
|
const onOutNameChange = useCallback130((e) => {
|
|
43402
43566
|
setOutName(e.target.value);
|
|
43403
43567
|
}, []);
|
|
43404
|
-
const outnameValidation =
|
|
43568
|
+
const outnameValidation = useMemo134(() => {
|
|
43405
43569
|
if (renderMode === "still") {
|
|
43406
43570
|
return validateOutnameForStill({
|
|
43407
43571
|
outName,
|
|
@@ -43502,7 +43666,9 @@ var WebRenderModal = ({
|
|
|
43502
43666
|
delayRenderTimeoutInMilliseconds: delayRenderTimeout,
|
|
43503
43667
|
mediaCacheSizeInBytes,
|
|
43504
43668
|
logLevel,
|
|
43505
|
-
videoCodec:
|
|
43669
|
+
videoCodec: effectiveVideoCodec,
|
|
43670
|
+
audioCodec: effectiveAudioCodec,
|
|
43671
|
+
audioBitrate,
|
|
43506
43672
|
container: container61,
|
|
43507
43673
|
videoBitrate,
|
|
43508
43674
|
hardwareAcceleration,
|
|
@@ -43531,7 +43697,9 @@ var WebRenderModal = ({
|
|
|
43531
43697
|
delayRenderTimeout,
|
|
43532
43698
|
mediaCacheSizeInBytes,
|
|
43533
43699
|
logLevel,
|
|
43534
|
-
|
|
43700
|
+
effectiveVideoCodec,
|
|
43701
|
+
effectiveAudioCodec,
|
|
43702
|
+
audioBitrate,
|
|
43535
43703
|
container61,
|
|
43536
43704
|
videoBitrate,
|
|
43537
43705
|
hardwareAcceleration,
|
|
@@ -43556,30 +43724,30 @@ var WebRenderModal = ({
|
|
|
43556
43724
|
await onRenderVideo();
|
|
43557
43725
|
}
|
|
43558
43726
|
}, [renderMode, onRenderStill, onRenderVideo]);
|
|
43559
|
-
return /* @__PURE__ */
|
|
43727
|
+
return /* @__PURE__ */ jsxs141("div", {
|
|
43560
43728
|
style: outerModalStyle,
|
|
43561
43729
|
children: [
|
|
43562
|
-
/* @__PURE__ */
|
|
43730
|
+
/* @__PURE__ */ jsx264(ModalHeader, {
|
|
43563
43731
|
title: `Render ${resolvedComposition.id}`
|
|
43564
43732
|
}),
|
|
43565
|
-
/* @__PURE__ */
|
|
43733
|
+
/* @__PURE__ */ jsxs141("div", {
|
|
43566
43734
|
style: container59,
|
|
43567
43735
|
children: [
|
|
43568
|
-
/* @__PURE__ */
|
|
43736
|
+
/* @__PURE__ */ jsx264(SegmentedControl, {
|
|
43569
43737
|
items: renderTabOptions,
|
|
43570
43738
|
needsWrapping: false
|
|
43571
43739
|
}),
|
|
43572
|
-
/* @__PURE__ */
|
|
43740
|
+
/* @__PURE__ */ jsx264("div", {
|
|
43573
43741
|
style: flexer
|
|
43574
43742
|
}),
|
|
43575
|
-
/* @__PURE__ */
|
|
43743
|
+
/* @__PURE__ */ jsxs141(Button, {
|
|
43576
43744
|
autoFocus: true,
|
|
43577
43745
|
onClick: onRender,
|
|
43578
43746
|
style: buttonStyle7,
|
|
43579
43747
|
disabled: !outnameValidation.valid,
|
|
43580
43748
|
children: [
|
|
43581
43749
|
renderProgress ? `Rendering... ${renderProgress.renderedFrames}/${finalEndFrame}` : `Render ${renderMode}`,
|
|
43582
|
-
/* @__PURE__ */
|
|
43750
|
+
/* @__PURE__ */ jsx264(ShortcutHint, {
|
|
43583
43751
|
keyToPress: "↵",
|
|
43584
43752
|
cmdOrCtrl: true
|
|
43585
43753
|
})
|
|
@@ -43587,94 +43755,94 @@ var WebRenderModal = ({
|
|
|
43587
43755
|
})
|
|
43588
43756
|
]
|
|
43589
43757
|
}),
|
|
43590
|
-
/* @__PURE__ */
|
|
43758
|
+
/* @__PURE__ */ jsx264("div", {
|
|
43591
43759
|
style: container59,
|
|
43592
|
-
children: /* @__PURE__ */
|
|
43760
|
+
children: /* @__PURE__ */ jsx264(WebRendererExperimentalBadge, {})
|
|
43593
43761
|
}),
|
|
43594
|
-
/* @__PURE__ */
|
|
43762
|
+
/* @__PURE__ */ jsxs141("div", {
|
|
43595
43763
|
style: horizontalLayout,
|
|
43596
43764
|
children: [
|
|
43597
|
-
/* @__PURE__ */
|
|
43765
|
+
/* @__PURE__ */ jsxs141("div", {
|
|
43598
43766
|
style: leftSidebar,
|
|
43599
43767
|
children: [
|
|
43600
|
-
/* @__PURE__ */
|
|
43768
|
+
/* @__PURE__ */ jsxs141(VerticalTab, {
|
|
43601
43769
|
style: horizontalTab,
|
|
43602
43770
|
selected: tab === "general",
|
|
43603
43771
|
onClick: () => setTab("general"),
|
|
43604
43772
|
children: [
|
|
43605
|
-
/* @__PURE__ */
|
|
43773
|
+
/* @__PURE__ */ jsx264("div", {
|
|
43606
43774
|
style: iconContainer,
|
|
43607
|
-
children: /* @__PURE__ */
|
|
43775
|
+
children: /* @__PURE__ */ jsx264(FileIcon, {
|
|
43608
43776
|
style: icon6
|
|
43609
43777
|
})
|
|
43610
43778
|
}),
|
|
43611
43779
|
"General"
|
|
43612
43780
|
]
|
|
43613
43781
|
}),
|
|
43614
|
-
/* @__PURE__ */
|
|
43782
|
+
/* @__PURE__ */ jsxs141(VerticalTab, {
|
|
43615
43783
|
style: horizontalTab,
|
|
43616
43784
|
selected: tab === "data",
|
|
43617
43785
|
onClick: () => setTab("data"),
|
|
43618
43786
|
children: [
|
|
43619
|
-
/* @__PURE__ */
|
|
43787
|
+
/* @__PURE__ */ jsx264("div", {
|
|
43620
43788
|
style: iconContainer,
|
|
43621
|
-
children: /* @__PURE__ */
|
|
43789
|
+
children: /* @__PURE__ */ jsx264(DataIcon, {
|
|
43622
43790
|
style: icon6
|
|
43623
43791
|
})
|
|
43624
43792
|
}),
|
|
43625
43793
|
"Input Props"
|
|
43626
43794
|
]
|
|
43627
43795
|
}),
|
|
43628
|
-
renderMode === "video" ? /* @__PURE__ */
|
|
43796
|
+
renderMode === "video" ? /* @__PURE__ */ jsxs141(VerticalTab, {
|
|
43629
43797
|
style: horizontalTab,
|
|
43630
43798
|
selected: tab === "picture",
|
|
43631
43799
|
onClick: () => setTab("picture"),
|
|
43632
43800
|
children: [
|
|
43633
|
-
/* @__PURE__ */
|
|
43801
|
+
/* @__PURE__ */ jsx264("div", {
|
|
43634
43802
|
style: iconContainer,
|
|
43635
|
-
children: /* @__PURE__ */
|
|
43803
|
+
children: /* @__PURE__ */ jsx264(PicIcon, {
|
|
43636
43804
|
style: icon6
|
|
43637
43805
|
})
|
|
43638
43806
|
}),
|
|
43639
43807
|
"Picture"
|
|
43640
43808
|
]
|
|
43641
43809
|
}) : null,
|
|
43642
|
-
renderMode === "video" ? /* @__PURE__ */
|
|
43810
|
+
renderMode === "video" ? /* @__PURE__ */ jsxs141(VerticalTab, {
|
|
43643
43811
|
style: horizontalTab,
|
|
43644
43812
|
selected: tab === "audio",
|
|
43645
43813
|
onClick: () => setTab("audio"),
|
|
43646
43814
|
children: [
|
|
43647
|
-
/* @__PURE__ */
|
|
43815
|
+
/* @__PURE__ */ jsx264("div", {
|
|
43648
43816
|
style: iconContainer,
|
|
43649
|
-
children: /* @__PURE__ */
|
|
43817
|
+
children: /* @__PURE__ */ jsx264(AudioIcon, {
|
|
43650
43818
|
style: icon6
|
|
43651
43819
|
})
|
|
43652
43820
|
}),
|
|
43653
43821
|
"Audio"
|
|
43654
43822
|
]
|
|
43655
43823
|
}) : null,
|
|
43656
|
-
/* @__PURE__ */
|
|
43824
|
+
/* @__PURE__ */ jsxs141(VerticalTab, {
|
|
43657
43825
|
style: horizontalTab,
|
|
43658
43826
|
selected: tab === "advanced",
|
|
43659
43827
|
onClick: () => setTab("advanced"),
|
|
43660
43828
|
children: [
|
|
43661
|
-
/* @__PURE__ */
|
|
43829
|
+
/* @__PURE__ */ jsx264("div", {
|
|
43662
43830
|
style: iconContainer,
|
|
43663
|
-
children: /* @__PURE__ */
|
|
43831
|
+
children: /* @__PURE__ */ jsx264(GearIcon, {
|
|
43664
43832
|
style: icon6
|
|
43665
43833
|
})
|
|
43666
43834
|
}),
|
|
43667
43835
|
"Other"
|
|
43668
43836
|
]
|
|
43669
43837
|
}),
|
|
43670
|
-
/* @__PURE__ */
|
|
43838
|
+
/* @__PURE__ */ jsxs141(VerticalTab, {
|
|
43671
43839
|
style: horizontalTab,
|
|
43672
43840
|
selected: tab === "license",
|
|
43673
43841
|
onClick: () => setTab("license"),
|
|
43674
43842
|
children: [
|
|
43675
|
-
/* @__PURE__ */
|
|
43843
|
+
/* @__PURE__ */ jsx264("div", {
|
|
43676
43844
|
style: iconContainer,
|
|
43677
|
-
children: /* @__PURE__ */
|
|
43845
|
+
children: /* @__PURE__ */ jsx264(CertificateIcon, {
|
|
43678
43846
|
style: icon6
|
|
43679
43847
|
})
|
|
43680
43848
|
}),
|
|
@@ -43683,10 +43851,10 @@ var WebRenderModal = ({
|
|
|
43683
43851
|
})
|
|
43684
43852
|
]
|
|
43685
43853
|
}),
|
|
43686
|
-
/* @__PURE__ */
|
|
43854
|
+
/* @__PURE__ */ jsx264("div", {
|
|
43687
43855
|
style: optionsPanel,
|
|
43688
43856
|
className: VERTICAL_SCROLLBAR_CLASSNAME,
|
|
43689
|
-
children: tab === "general" ? /* @__PURE__ */
|
|
43857
|
+
children: tab === "general" ? /* @__PURE__ */ jsx264(WebRenderModalBasic, {
|
|
43690
43858
|
renderMode,
|
|
43691
43859
|
resolvedComposition,
|
|
43692
43860
|
imageFormat,
|
|
@@ -43696,8 +43864,9 @@ var WebRenderModal = ({
|
|
|
43696
43864
|
onFrameSetDirectly,
|
|
43697
43865
|
container: container61,
|
|
43698
43866
|
setContainerFormat,
|
|
43699
|
-
codec,
|
|
43700
43867
|
setCodec,
|
|
43868
|
+
encodableVideoCodecs,
|
|
43869
|
+
effectiveVideoCodec,
|
|
43701
43870
|
startFrame: finalStartFrame,
|
|
43702
43871
|
setStartFrame,
|
|
43703
43872
|
endFrame: finalEndFrame,
|
|
@@ -43707,7 +43876,7 @@ var WebRenderModal = ({
|
|
|
43707
43876
|
validationMessage: outnameValidation.valid ? null : outnameValidation.error.message,
|
|
43708
43877
|
logLevel,
|
|
43709
43878
|
setLogLevel
|
|
43710
|
-
}) : tab === "data" ? /* @__PURE__ */
|
|
43879
|
+
}) : tab === "data" ? /* @__PURE__ */ jsx264(DataEditor, {
|
|
43711
43880
|
defaultProps: inputProps,
|
|
43712
43881
|
setDefaultProps: setInputProps,
|
|
43713
43882
|
unresolvedComposition,
|
|
@@ -43716,7 +43885,7 @@ var WebRenderModal = ({
|
|
|
43716
43885
|
saving,
|
|
43717
43886
|
setSaving,
|
|
43718
43887
|
readOnlyStudio: false
|
|
43719
|
-
}) : tab === "picture" ? /* @__PURE__ */
|
|
43888
|
+
}) : tab === "picture" ? /* @__PURE__ */ jsx264(WebRenderModalPicture, {
|
|
43720
43889
|
renderMode,
|
|
43721
43890
|
videoBitrate,
|
|
43722
43891
|
setVideoBitrate,
|
|
@@ -43724,10 +43893,17 @@ var WebRenderModal = ({
|
|
|
43724
43893
|
setKeyframeIntervalInSeconds,
|
|
43725
43894
|
transparent,
|
|
43726
43895
|
setTransparent
|
|
43727
|
-
}) : tab === "audio" ? /* @__PURE__ */
|
|
43896
|
+
}) : tab === "audio" ? /* @__PURE__ */ jsx264(WebRenderModalAudio, {
|
|
43728
43897
|
muted,
|
|
43729
|
-
setMuted
|
|
43730
|
-
|
|
43898
|
+
setMuted,
|
|
43899
|
+
audioCodec,
|
|
43900
|
+
setAudioCodec,
|
|
43901
|
+
audioBitrate,
|
|
43902
|
+
setAudioBitrate,
|
|
43903
|
+
container: container61,
|
|
43904
|
+
encodableCodecs: encodableAudioCodecs,
|
|
43905
|
+
effectiveAudioCodec
|
|
43906
|
+
}) : tab === "advanced" ? /* @__PURE__ */ jsx264(WebRenderModalAdvanced, {
|
|
43731
43907
|
renderMode,
|
|
43732
43908
|
delayRenderTimeout,
|
|
43733
43909
|
setDelayRenderTimeout,
|
|
@@ -43735,7 +43911,7 @@ var WebRenderModal = ({
|
|
|
43735
43911
|
setMediaCacheSizeInBytes,
|
|
43736
43912
|
hardwareAcceleration,
|
|
43737
43913
|
setHardwareAcceleration
|
|
43738
|
-
}) : /* @__PURE__ */
|
|
43914
|
+
}) : /* @__PURE__ */ jsx264(WebRenderModalLicense, {
|
|
43739
43915
|
licenseKey,
|
|
43740
43916
|
setLicenseKey,
|
|
43741
43917
|
initialPublicLicenseKey: initialLicenseKey
|
|
@@ -43747,10 +43923,10 @@ var WebRenderModal = ({
|
|
|
43747
43923
|
});
|
|
43748
43924
|
};
|
|
43749
43925
|
var WebRenderModalWithLoader = (props) => {
|
|
43750
|
-
return /* @__PURE__ */
|
|
43751
|
-
children: /* @__PURE__ */
|
|
43926
|
+
return /* @__PURE__ */ jsx264(DismissableModal, {
|
|
43927
|
+
children: /* @__PURE__ */ jsx264(ResolveCompositionBeforeModal, {
|
|
43752
43928
|
compositionId: props.compositionId,
|
|
43753
|
-
children: /* @__PURE__ */
|
|
43929
|
+
children: /* @__PURE__ */ jsx264(WebRenderModal, {
|
|
43754
43930
|
...props
|
|
43755
43931
|
})
|
|
43756
43932
|
})
|
|
@@ -43758,11 +43934,11 @@ var WebRenderModalWithLoader = (props) => {
|
|
|
43758
43934
|
};
|
|
43759
43935
|
|
|
43760
43936
|
// src/components/UpdateModal/UpdateModal.tsx
|
|
43761
|
-
import { useCallback as useCallback133, useMemo as
|
|
43937
|
+
import { useCallback as useCallback133, useMemo as useMemo136 } from "react";
|
|
43762
43938
|
|
|
43763
43939
|
// src/components/CopyButton.tsx
|
|
43764
|
-
import { useCallback as useCallback131, useEffect as
|
|
43765
|
-
import { jsx as
|
|
43940
|
+
import { useCallback as useCallback131, useEffect as useEffect81, useState as useState84 } from "react";
|
|
43941
|
+
import { jsx as jsx265, jsxs as jsxs142 } from "react/jsx-runtime";
|
|
43766
43942
|
var iconStyle8 = {
|
|
43767
43943
|
width: 16,
|
|
43768
43944
|
height: 16,
|
|
@@ -43772,7 +43948,7 @@ var buttonContainerStyle = {
|
|
|
43772
43948
|
display: "flex",
|
|
43773
43949
|
minWidth: "114px"
|
|
43774
43950
|
};
|
|
43775
|
-
var copyIcon = /* @__PURE__ */
|
|
43951
|
+
var copyIcon = /* @__PURE__ */ jsx265("svg", {
|
|
43776
43952
|
"aria-hidden": "true",
|
|
43777
43953
|
focusable: "false",
|
|
43778
43954
|
"data-prefix": "far",
|
|
@@ -43782,7 +43958,7 @@ var copyIcon = /* @__PURE__ */ jsx264("svg", {
|
|
|
43782
43958
|
xmlns: "http://www.w3.org/2000/svg",
|
|
43783
43959
|
viewBox: "0 0 384 512",
|
|
43784
43960
|
style: iconStyle8,
|
|
43785
|
-
children: /* @__PURE__ */
|
|
43961
|
+
children: /* @__PURE__ */ jsx265("path", {
|
|
43786
43962
|
fill: "currentColor",
|
|
43787
43963
|
d: "M336 64h-80c0-35.3-28.7-64-64-64s-64 28.7-64 64H48C21.5 64 0 85.5 0 112v352c0 26.5 21.5 48 48 48h288c26.5 0 48-21.5 48-48V112c0-26.5-21.5-48-48-48zM192 40c13.3 0 24 10.7 24 24s-10.7 24-24 24-24-10.7-24-24 10.7-24 24-24zm144 418c0 3.3-2.7 6-6 6H54c-3.3 0-6-2.7-6-6V118c0-3.3 2.7-6 6-6h42v36c0 6.6 5.4 12 12 12h168c6.6 0 12-5.4 12-12v-36h42c3.3 0 6 2.7 6 6z"
|
|
43788
43964
|
})
|
|
@@ -43791,7 +43967,7 @@ var labelStyle5 = {
|
|
|
43791
43967
|
fontSize: 14
|
|
43792
43968
|
};
|
|
43793
43969
|
var CopyButton = ({ textToCopy, label: label11, labelWhenCopied }) => {
|
|
43794
|
-
const [copied, setCopied] =
|
|
43970
|
+
const [copied, setCopied] = useState84(false);
|
|
43795
43971
|
const onClick = useCallback131(() => {
|
|
43796
43972
|
copyText(textToCopy).then(() => {
|
|
43797
43973
|
setCopied(Date.now());
|
|
@@ -43799,23 +43975,23 @@ var CopyButton = ({ textToCopy, label: label11, labelWhenCopied }) => {
|
|
|
43799
43975
|
showNotification(`Could not copy: ${err.message}`, 2000);
|
|
43800
43976
|
});
|
|
43801
43977
|
}, [textToCopy]);
|
|
43802
|
-
|
|
43978
|
+
useEffect81(() => {
|
|
43803
43979
|
if (!copied) {
|
|
43804
43980
|
return;
|
|
43805
43981
|
}
|
|
43806
43982
|
const to = setTimeout(() => setCopied(false), 2000);
|
|
43807
43983
|
return () => clearTimeout(to);
|
|
43808
43984
|
}, [copied]);
|
|
43809
|
-
return /* @__PURE__ */
|
|
43985
|
+
return /* @__PURE__ */ jsxs142(Button, {
|
|
43810
43986
|
onClick,
|
|
43811
43987
|
buttonContainerStyle,
|
|
43812
43988
|
children: [
|
|
43813
43989
|
copyIcon,
|
|
43814
|
-
/* @__PURE__ */
|
|
43990
|
+
/* @__PURE__ */ jsx265(Spacing, {
|
|
43815
43991
|
x: 1.5
|
|
43816
43992
|
}),
|
|
43817
43993
|
" ",
|
|
43818
|
-
/* @__PURE__ */
|
|
43994
|
+
/* @__PURE__ */ jsx265("span", {
|
|
43819
43995
|
style: labelStyle5,
|
|
43820
43996
|
children: copied ? labelWhenCopied : label11
|
|
43821
43997
|
})
|
|
@@ -43824,8 +44000,8 @@ var CopyButton = ({ textToCopy, label: label11, labelWhenCopied }) => {
|
|
|
43824
44000
|
};
|
|
43825
44001
|
|
|
43826
44002
|
// src/components/UpdateModal/OpenIssueButton.tsx
|
|
43827
|
-
import { useCallback as useCallback132, useMemo as
|
|
43828
|
-
import { jsx as
|
|
44003
|
+
import { useCallback as useCallback132, useMemo as useMemo135, useState as useState85 } from "react";
|
|
44004
|
+
import { jsx as jsx266 } from "react/jsx-runtime";
|
|
43829
44005
|
var svgStyle3 = {
|
|
43830
44006
|
width: "11px",
|
|
43831
44007
|
height: "11px"
|
|
@@ -43839,18 +44015,18 @@ var buttonStyle8 = {
|
|
|
43839
44015
|
alignItems: "center"
|
|
43840
44016
|
};
|
|
43841
44017
|
var OpenIssueButton = ({ link: link4 }) => {
|
|
43842
|
-
const [hovered, setHovered] =
|
|
44018
|
+
const [hovered, setHovered] = useState85(false);
|
|
43843
44019
|
const buttonTooltip = `Open GitHub issue in new Tab`;
|
|
43844
44020
|
const handleClick = useCallback132(() => {
|
|
43845
44021
|
window.open(link4, "_blank");
|
|
43846
44022
|
}, [link4]);
|
|
43847
|
-
const svgFillColor =
|
|
44023
|
+
const svgFillColor = useMemo135(() => {
|
|
43848
44024
|
return hovered ? "white" : LIGHT_TEXT;
|
|
43849
44025
|
}, [hovered]);
|
|
43850
|
-
const openInEditorSvg = /* @__PURE__ */
|
|
44026
|
+
const openInEditorSvg = /* @__PURE__ */ jsx266("svg", {
|
|
43851
44027
|
viewBox: "0 0 512 512",
|
|
43852
44028
|
style: svgStyle3,
|
|
43853
|
-
children: /* @__PURE__ */
|
|
44029
|
+
children: /* @__PURE__ */ jsx266("path", {
|
|
43854
44030
|
fill: svgFillColor,
|
|
43855
44031
|
d: "M320 0c-17.7 0-32 14.3-32 32s14.3 32 32 32h82.7L201.4 265.4c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L448 109.3V192c0 17.7 14.3 32 32 32s32-14.3 32-32V32c0-17.7-14.3-32-32-32H320zM80 32C35.8 32 0 67.8 0 112V432c0 44.2 35.8 80 80 80H400c44.2 0 80-35.8 80-80V320c0-17.7-14.3-32-32-32s-32 14.3-32 32V432c0 8.8-7.2 16-16 16H80c-8.8 0-16-7.2-16-16V112c0-8.8 7.2-16 16-16H192c17.7 0 32-14.3 32-32s-14.3-32-32-32H80z"
|
|
43856
44032
|
})
|
|
@@ -43861,7 +44037,7 @@ var OpenIssueButton = ({ link: link4 }) => {
|
|
|
43861
44037
|
const onPointerLeave = useCallback132(() => {
|
|
43862
44038
|
setHovered(false);
|
|
43863
44039
|
}, []);
|
|
43864
|
-
return /* @__PURE__ */
|
|
44040
|
+
return /* @__PURE__ */ jsx266("button", {
|
|
43865
44041
|
title: buttonTooltip,
|
|
43866
44042
|
type: "button",
|
|
43867
44043
|
onPointerEnter,
|
|
@@ -43873,7 +44049,7 @@ var OpenIssueButton = ({ link: link4 }) => {
|
|
|
43873
44049
|
};
|
|
43874
44050
|
|
|
43875
44051
|
// src/components/KnownBugs.tsx
|
|
43876
|
-
import { jsx as
|
|
44052
|
+
import { jsx as jsx267, jsxs as jsxs143 } from "react/jsx-runtime";
|
|
43877
44053
|
var container61 = {
|
|
43878
44054
|
display: "flex",
|
|
43879
44055
|
flexDirection: "row",
|
|
@@ -43885,29 +44061,29 @@ var text4 = {
|
|
|
43885
44061
|
};
|
|
43886
44062
|
var KnownBugs = ({ bugs }) => {
|
|
43887
44063
|
const bugElements = bugs.map((bug) => {
|
|
43888
|
-
return /* @__PURE__ */
|
|
44064
|
+
return /* @__PURE__ */ jsxs143("div", {
|
|
43889
44065
|
style: container61,
|
|
43890
44066
|
children: [
|
|
43891
|
-
/* @__PURE__ */
|
|
44067
|
+
/* @__PURE__ */ jsxs143("div", {
|
|
43892
44068
|
style: text4,
|
|
43893
44069
|
children: [
|
|
43894
44070
|
"\uD83E\uDEB2 ",
|
|
43895
44071
|
bug.title
|
|
43896
44072
|
]
|
|
43897
44073
|
}),
|
|
43898
|
-
/* @__PURE__ */
|
|
44074
|
+
/* @__PURE__ */ jsx267(OpenIssueButton, {
|
|
43899
44075
|
link: bug.link
|
|
43900
44076
|
})
|
|
43901
44077
|
]
|
|
43902
44078
|
}, bug.description + bug.link);
|
|
43903
44079
|
});
|
|
43904
|
-
return /* @__PURE__ */
|
|
44080
|
+
return /* @__PURE__ */ jsx267("div", {
|
|
43905
44081
|
children: bugElements
|
|
43906
44082
|
});
|
|
43907
44083
|
};
|
|
43908
44084
|
|
|
43909
44085
|
// src/components/UpdateModal/UpdateModal.tsx
|
|
43910
|
-
import { jsx as
|
|
44086
|
+
import { jsx as jsx268, jsxs as jsxs144, Fragment as Fragment48 } from "react/jsx-runtime";
|
|
43911
44087
|
var container62 = {
|
|
43912
44088
|
padding: 20,
|
|
43913
44089
|
paddingTop: 0
|
|
@@ -43941,7 +44117,7 @@ var commands = {
|
|
|
43941
44117
|
unknown: "npx remotion upgrade"
|
|
43942
44118
|
};
|
|
43943
44119
|
var UpdateModal = ({ info, knownBugs }) => {
|
|
43944
|
-
const hasKnownBugs =
|
|
44120
|
+
const hasKnownBugs = useMemo136(() => {
|
|
43945
44121
|
return knownBugs && knownBugs?.length > 0;
|
|
43946
44122
|
}, [knownBugs]);
|
|
43947
44123
|
const command = commands[info.packageManager];
|
|
@@ -43950,17 +44126,17 @@ var UpdateModal = ({ info, knownBugs }) => {
|
|
|
43950
44126
|
showNotification(`Could not copy: ${err.message}`, 2000);
|
|
43951
44127
|
});
|
|
43952
44128
|
}, [command]);
|
|
43953
|
-
return /* @__PURE__ */
|
|
44129
|
+
return /* @__PURE__ */ jsxs144(DismissableModal, {
|
|
43954
44130
|
children: [
|
|
43955
|
-
/* @__PURE__ */
|
|
44131
|
+
/* @__PURE__ */ jsx268(ModalHeader, {
|
|
43956
44132
|
title: "Update available"
|
|
43957
44133
|
}),
|
|
43958
|
-
/* @__PURE__ */
|
|
44134
|
+
/* @__PURE__ */ jsxs144("div", {
|
|
43959
44135
|
style: container62,
|
|
43960
44136
|
children: [
|
|
43961
|
-
hasKnownBugs ? /* @__PURE__ */
|
|
44137
|
+
hasKnownBugs ? /* @__PURE__ */ jsxs144(Fragment48, {
|
|
43962
44138
|
children: [
|
|
43963
|
-
/* @__PURE__ */
|
|
44139
|
+
/* @__PURE__ */ jsxs144("div", {
|
|
43964
44140
|
style: title7,
|
|
43965
44141
|
children: [
|
|
43966
44142
|
"The currently installed version ",
|
|
@@ -43968,42 +44144,42 @@ var UpdateModal = ({ info, knownBugs }) => {
|
|
|
43968
44144
|
" has the following known bugs:"
|
|
43969
44145
|
]
|
|
43970
44146
|
}),
|
|
43971
|
-
/* @__PURE__ */
|
|
44147
|
+
/* @__PURE__ */ jsx268(KnownBugs, {
|
|
43972
44148
|
bugs: knownBugs
|
|
43973
44149
|
}),
|
|
43974
|
-
/* @__PURE__ */
|
|
44150
|
+
/* @__PURE__ */ jsx268("div", {
|
|
43975
44151
|
style: { height: "20px" }
|
|
43976
44152
|
}),
|
|
43977
|
-
/* @__PURE__ */
|
|
44153
|
+
/* @__PURE__ */ jsx268("div", {
|
|
43978
44154
|
style: text5,
|
|
43979
44155
|
children: "To upgrade, run the following command:"
|
|
43980
44156
|
})
|
|
43981
44157
|
]
|
|
43982
|
-
}) : /* @__PURE__ */
|
|
44158
|
+
}) : /* @__PURE__ */ jsx268("div", {
|
|
43983
44159
|
style: title7,
|
|
43984
44160
|
children: "A new update for Remotion is available! Run the following command:"
|
|
43985
44161
|
}),
|
|
43986
|
-
/* @__PURE__ */
|
|
44162
|
+
/* @__PURE__ */ jsxs144(Row, {
|
|
43987
44163
|
align: "center",
|
|
43988
44164
|
children: [
|
|
43989
|
-
/* @__PURE__ */
|
|
43990
|
-
children: /* @__PURE__ */
|
|
44165
|
+
/* @__PURE__ */ jsx268(Flex, {
|
|
44166
|
+
children: /* @__PURE__ */ jsx268("pre", {
|
|
43991
44167
|
onClick,
|
|
43992
44168
|
style: code,
|
|
43993
44169
|
children: command
|
|
43994
44170
|
})
|
|
43995
44171
|
}),
|
|
43996
|
-
/* @__PURE__ */
|
|
44172
|
+
/* @__PURE__ */ jsx268(Spacing, {
|
|
43997
44173
|
x: 1
|
|
43998
44174
|
}),
|
|
43999
|
-
/* @__PURE__ */
|
|
44175
|
+
/* @__PURE__ */ jsx268(CopyButton, {
|
|
44000
44176
|
textToCopy: command,
|
|
44001
44177
|
label: "Copy",
|
|
44002
44178
|
labelWhenCopied: "Copied!"
|
|
44003
44179
|
})
|
|
44004
44180
|
]
|
|
44005
44181
|
}),
|
|
44006
|
-
/* @__PURE__ */
|
|
44182
|
+
/* @__PURE__ */ jsxs144("div", {
|
|
44007
44183
|
style: text5,
|
|
44008
44184
|
children: [
|
|
44009
44185
|
"This will upgrade Remotion from ",
|
|
@@ -44014,12 +44190,12 @@ var UpdateModal = ({ info, knownBugs }) => {
|
|
|
44014
44190
|
"."
|
|
44015
44191
|
]
|
|
44016
44192
|
}),
|
|
44017
|
-
/* @__PURE__ */
|
|
44193
|
+
/* @__PURE__ */ jsxs144("div", {
|
|
44018
44194
|
style: text5,
|
|
44019
44195
|
children: [
|
|
44020
44196
|
"Read the",
|
|
44021
44197
|
" ",
|
|
44022
|
-
/* @__PURE__ */
|
|
44198
|
+
/* @__PURE__ */ jsx268("a", {
|
|
44023
44199
|
style: link4,
|
|
44024
44200
|
target: "_blank",
|
|
44025
44201
|
href: "https://github.com/remotion-dev/remotion/releases",
|
|
@@ -44038,24 +44214,24 @@ var UpdateModal = ({ info, knownBugs }) => {
|
|
|
44038
44214
|
};
|
|
44039
44215
|
|
|
44040
44216
|
// src/components/Modals.tsx
|
|
44041
|
-
import { jsx as
|
|
44217
|
+
import { jsx as jsx269, jsxs as jsxs145, Fragment as Fragment49 } from "react/jsx-runtime";
|
|
44042
44218
|
var Modals = ({ readOnlyStudio }) => {
|
|
44043
44219
|
const { selectedModal: modalContextType } = useContext83(ModalsContext);
|
|
44044
44220
|
const canRender = useContext83(StudioServerConnectionCtx).previewServerState.type === "connected";
|
|
44045
|
-
return /* @__PURE__ */
|
|
44221
|
+
return /* @__PURE__ */ jsxs145(Fragment49, {
|
|
44046
44222
|
children: [
|
|
44047
|
-
modalContextType && modalContextType.type === "duplicate-comp" && /* @__PURE__ */
|
|
44223
|
+
modalContextType && modalContextType.type === "duplicate-comp" && /* @__PURE__ */ jsx269(DuplicateComposition, {
|
|
44048
44224
|
compositionType: modalContextType.compositionType,
|
|
44049
44225
|
compositionId: modalContextType.compositionId
|
|
44050
44226
|
}),
|
|
44051
|
-
modalContextType && modalContextType.type === "delete-comp" && /* @__PURE__ */
|
|
44227
|
+
modalContextType && modalContextType.type === "delete-comp" && /* @__PURE__ */ jsx269(DeleteComposition, {
|
|
44052
44228
|
compositionId: modalContextType.compositionId
|
|
44053
44229
|
}),
|
|
44054
|
-
modalContextType && modalContextType.type === "rename-comp" && /* @__PURE__ */
|
|
44230
|
+
modalContextType && modalContextType.type === "rename-comp" && /* @__PURE__ */ jsx269(RenameComposition, {
|
|
44055
44231
|
compositionId: modalContextType.compositionId
|
|
44056
44232
|
}),
|
|
44057
|
-
modalContextType && modalContextType.type === "input-props-override" && /* @__PURE__ */
|
|
44058
|
-
modalContextType && modalContextType.type === "web-render" && /* @__PURE__ */
|
|
44233
|
+
modalContextType && modalContextType.type === "input-props-override" && /* @__PURE__ */ jsx269(OverrideInputPropsModal, {}),
|
|
44234
|
+
modalContextType && modalContextType.type === "web-render" && /* @__PURE__ */ jsx269(WebRenderModalWithLoader, {
|
|
44059
44235
|
type: "web-render",
|
|
44060
44236
|
initialFrame: modalContextType.initialFrame,
|
|
44061
44237
|
compositionId: modalContextType.compositionId,
|
|
@@ -44065,7 +44241,7 @@ var Modals = ({ readOnlyStudio }) => {
|
|
|
44065
44241
|
initialLogLevel: modalContextType.initialLogLevel,
|
|
44066
44242
|
initialLicenseKey: modalContextType.initialLicenseKey
|
|
44067
44243
|
}),
|
|
44068
|
-
modalContextType && canRender && modalContextType.type === "server-render" && /* @__PURE__ */
|
|
44244
|
+
modalContextType && canRender && modalContextType.type === "server-render" && /* @__PURE__ */ jsx269(RenderModalWithLoader, {
|
|
44069
44245
|
initialFrame: modalContextType.initialFrame,
|
|
44070
44246
|
initialDarkMode: modalContextType.initialDarkMode,
|
|
44071
44247
|
compositionId: modalContextType.compositionId,
|
|
@@ -44114,28 +44290,28 @@ var Modals = ({ readOnlyStudio }) => {
|
|
|
44114
44290
|
initialChromeMode: modalContextType.initialChromeMode,
|
|
44115
44291
|
renderDefaults: modalContextType.renderDefaults
|
|
44116
44292
|
}),
|
|
44117
|
-
modalContextType && canRender && modalContextType.type === "render-progress" && /* @__PURE__ */
|
|
44293
|
+
modalContextType && canRender && modalContextType.type === "render-progress" && /* @__PURE__ */ jsx269(RenderStatusModal, {
|
|
44118
44294
|
jobId: modalContextType.jobId
|
|
44119
44295
|
}),
|
|
44120
|
-
modalContextType && modalContextType.type === "update" && /* @__PURE__ */
|
|
44296
|
+
modalContextType && modalContextType.type === "update" && /* @__PURE__ */ jsx269(UpdateModal, {
|
|
44121
44297
|
info: modalContextType.info,
|
|
44122
44298
|
knownBugs: modalContextType.knownBugs
|
|
44123
44299
|
}),
|
|
44124
|
-
modalContextType && modalContextType.type === "install-packages" && /* @__PURE__ */
|
|
44300
|
+
modalContextType && modalContextType.type === "install-packages" && /* @__PURE__ */ jsx269(InstallPackageModal, {
|
|
44125
44301
|
packageManager: modalContextType.packageManager
|
|
44126
44302
|
}),
|
|
44127
|
-
modalContextType && modalContextType.type === "quick-switcher" && /* @__PURE__ */
|
|
44303
|
+
modalContextType && modalContextType.type === "quick-switcher" && /* @__PURE__ */ jsx269(QuickSwitcher_default, {
|
|
44128
44304
|
readOnlyStudio,
|
|
44129
44305
|
invocationTimestamp: modalContextType.invocationTimestamp,
|
|
44130
44306
|
initialMode: modalContextType.mode
|
|
44131
44307
|
}),
|
|
44132
|
-
/* @__PURE__ */
|
|
44308
|
+
/* @__PURE__ */ jsx269(AskAiModal, {})
|
|
44133
44309
|
]
|
|
44134
44310
|
});
|
|
44135
44311
|
};
|
|
44136
44312
|
|
|
44137
44313
|
// src/components/Editor.tsx
|
|
44138
|
-
import { jsx as
|
|
44314
|
+
import { jsx as jsx270, jsxs as jsxs146 } from "react/jsx-runtime";
|
|
44139
44315
|
var background2 = {
|
|
44140
44316
|
backgroundColor: BACKGROUND,
|
|
44141
44317
|
display: "flex",
|
|
@@ -44151,7 +44327,7 @@ var Editor = ({ Root, readOnlyStudio }) => {
|
|
|
44151
44327
|
triggerOnWindowResize: false,
|
|
44152
44328
|
shouldApplyCssTransforms: true
|
|
44153
44329
|
});
|
|
44154
|
-
|
|
44330
|
+
useEffect82(() => {
|
|
44155
44331
|
if (readOnlyStudio) {
|
|
44156
44332
|
return;
|
|
44157
44333
|
}
|
|
@@ -44165,11 +44341,11 @@ var Editor = ({ Root, readOnlyStudio }) => {
|
|
|
44165
44341
|
window.removeEventListener("beforeunload", listenToChanges);
|
|
44166
44342
|
};
|
|
44167
44343
|
}, [readOnlyStudio]);
|
|
44168
|
-
const [canvasMounted, setCanvasMounted] =
|
|
44344
|
+
const [canvasMounted, setCanvasMounted] = React177.useState(false);
|
|
44169
44345
|
const onMounted = useCallback134(() => {
|
|
44170
44346
|
setCanvasMounted(true);
|
|
44171
44347
|
}, []);
|
|
44172
|
-
const value =
|
|
44348
|
+
const value = useMemo137(() => {
|
|
44173
44349
|
if (!size4) {
|
|
44174
44350
|
return null;
|
|
44175
44351
|
}
|
|
@@ -44178,41 +44354,41 @@ var Editor = ({ Root, readOnlyStudio }) => {
|
|
|
44178
44354
|
canvasSize: size4
|
|
44179
44355
|
};
|
|
44180
44356
|
}, [size4]);
|
|
44181
|
-
const MemoRoot =
|
|
44182
|
-
return
|
|
44357
|
+
const MemoRoot = useMemo137(() => {
|
|
44358
|
+
return React177.memo(Root);
|
|
44183
44359
|
}, [Root]);
|
|
44184
|
-
return /* @__PURE__ */
|
|
44360
|
+
return /* @__PURE__ */ jsx270(HigherZIndex, {
|
|
44185
44361
|
onEscape: noop,
|
|
44186
44362
|
onOutsideClick: noop,
|
|
44187
|
-
children: /* @__PURE__ */
|
|
44363
|
+
children: /* @__PURE__ */ jsxs146(TimelineZoomContext, {
|
|
44188
44364
|
children: [
|
|
44189
|
-
/* @__PURE__ */
|
|
44365
|
+
/* @__PURE__ */ jsx270(Internals61.CurrentScaleContext.Provider, {
|
|
44190
44366
|
value,
|
|
44191
|
-
children: /* @__PURE__ */
|
|
44367
|
+
children: /* @__PURE__ */ jsxs146("div", {
|
|
44192
44368
|
style: background2,
|
|
44193
44369
|
children: [
|
|
44194
|
-
canvasMounted ? /* @__PURE__ */
|
|
44195
|
-
/* @__PURE__ */
|
|
44370
|
+
canvasMounted ? /* @__PURE__ */ jsx270(MemoRoot, {}) : null,
|
|
44371
|
+
/* @__PURE__ */ jsxs146(Internals61.CanUseRemotionHooksProvider, {
|
|
44196
44372
|
children: [
|
|
44197
|
-
/* @__PURE__ */
|
|
44373
|
+
/* @__PURE__ */ jsx270(EditorContent, {
|
|
44198
44374
|
readOnlyStudio,
|
|
44199
|
-
children: /* @__PURE__ */
|
|
44375
|
+
children: /* @__PURE__ */ jsx270(TopPanel, {
|
|
44200
44376
|
drawRef,
|
|
44201
44377
|
bufferStateDelayInMilliseconds: BUFFER_STATE_DELAY_IN_MILLISECONDS,
|
|
44202
44378
|
onMounted,
|
|
44203
44379
|
readOnlyStudio
|
|
44204
44380
|
})
|
|
44205
44381
|
}),
|
|
44206
|
-
/* @__PURE__ */
|
|
44382
|
+
/* @__PURE__ */ jsx270(GlobalKeybindings, {})
|
|
44207
44383
|
]
|
|
44208
44384
|
})
|
|
44209
44385
|
]
|
|
44210
44386
|
})
|
|
44211
44387
|
}),
|
|
44212
|
-
/* @__PURE__ */
|
|
44388
|
+
/* @__PURE__ */ jsx270(Modals, {
|
|
44213
44389
|
readOnlyStudio
|
|
44214
44390
|
}),
|
|
44215
|
-
/* @__PURE__ */
|
|
44391
|
+
/* @__PURE__ */ jsx270(NotificationCenter, {})
|
|
44216
44392
|
]
|
|
44217
44393
|
})
|
|
44218
44394
|
});
|
|
@@ -44222,9 +44398,9 @@ var Editor = ({ Root, readOnlyStudio }) => {
|
|
|
44222
44398
|
import { PlayerInternals as PlayerInternals20 } from "@remotion/player";
|
|
44223
44399
|
|
|
44224
44400
|
// src/state/preview-size.tsx
|
|
44225
|
-
import { useCallback as useCallback135, useContext as useContext84, useMemo as
|
|
44401
|
+
import { useCallback as useCallback135, useContext as useContext84, useMemo as useMemo138, useState as useState86 } from "react";
|
|
44226
44402
|
import { Internals as Internals62 } from "remotion";
|
|
44227
|
-
import { jsx as
|
|
44403
|
+
import { jsx as jsx271 } from "react/jsx-runtime";
|
|
44228
44404
|
var key5 = "remotion.previewSize";
|
|
44229
44405
|
var persistPreviewSizeOption = (option) => {
|
|
44230
44406
|
localStorage.setItem(key5, JSON.stringify(option));
|
|
@@ -44243,8 +44419,8 @@ var loadPreviewSizeOption = () => {
|
|
|
44243
44419
|
return JSON.parse(item2);
|
|
44244
44420
|
};
|
|
44245
44421
|
var PreviewSizeProvider = ({ children }) => {
|
|
44246
|
-
const [size4, setSizeState] =
|
|
44247
|
-
const [translation, setTranslation] =
|
|
44422
|
+
const [size4, setSizeState] = useState86(() => loadPreviewSizeOption());
|
|
44423
|
+
const [translation, setTranslation] = useState86(() => {
|
|
44248
44424
|
return {
|
|
44249
44425
|
x: 0,
|
|
44250
44426
|
y: 0
|
|
@@ -44258,7 +44434,7 @@ var PreviewSizeProvider = ({ children }) => {
|
|
|
44258
44434
|
return newVal;
|
|
44259
44435
|
});
|
|
44260
44436
|
}, []);
|
|
44261
|
-
const previewSizeCtx =
|
|
44437
|
+
const previewSizeCtx = useMemo138(() => {
|
|
44262
44438
|
return {
|
|
44263
44439
|
size: editorZoomGestures ? size4 : {
|
|
44264
44440
|
size: size4.size,
|
|
@@ -44272,17 +44448,17 @@ var PreviewSizeProvider = ({ children }) => {
|
|
|
44272
44448
|
setTranslation
|
|
44273
44449
|
};
|
|
44274
44450
|
}, [editorZoomGestures, size4, setSize, translation]);
|
|
44275
|
-
return /* @__PURE__ */
|
|
44451
|
+
return /* @__PURE__ */ jsx271(Internals62.PreviewSizeContext.Provider, {
|
|
44276
44452
|
value: previewSizeCtx,
|
|
44277
44453
|
children
|
|
44278
44454
|
});
|
|
44279
44455
|
};
|
|
44280
44456
|
|
|
44281
44457
|
// src/components/CheckerboardProvider.tsx
|
|
44282
|
-
import { useCallback as useCallback136, useMemo as
|
|
44283
|
-
import { jsx as
|
|
44458
|
+
import { useCallback as useCallback136, useMemo as useMemo139, useState as useState87 } from "react";
|
|
44459
|
+
import { jsx as jsx272 } from "react/jsx-runtime";
|
|
44284
44460
|
var CheckerboardProvider = ({ children }) => {
|
|
44285
|
-
const [checkerboard, setCheckerboardState] =
|
|
44461
|
+
const [checkerboard, setCheckerboardState] = useState87(() => loadCheckerboardOption());
|
|
44286
44462
|
const setCheckerboard = useCallback136((newValue) => {
|
|
44287
44463
|
setCheckerboardState((prevState) => {
|
|
44288
44464
|
const newVal = newValue(prevState);
|
|
@@ -44290,40 +44466,40 @@ var CheckerboardProvider = ({ children }) => {
|
|
|
44290
44466
|
return newVal;
|
|
44291
44467
|
});
|
|
44292
44468
|
}, []);
|
|
44293
|
-
const checkerboardCtx =
|
|
44469
|
+
const checkerboardCtx = useMemo139(() => {
|
|
44294
44470
|
return {
|
|
44295
44471
|
checkerboard,
|
|
44296
44472
|
setCheckerboard
|
|
44297
44473
|
};
|
|
44298
44474
|
}, [checkerboard, setCheckerboard]);
|
|
44299
|
-
return /* @__PURE__ */
|
|
44475
|
+
return /* @__PURE__ */ jsx272(CheckerboardContext.Provider, {
|
|
44300
44476
|
value: checkerboardCtx,
|
|
44301
44477
|
children
|
|
44302
44478
|
});
|
|
44303
44479
|
};
|
|
44304
44480
|
|
|
44305
44481
|
// src/components/MediaVolumeProvider.tsx
|
|
44306
|
-
import { useMemo as
|
|
44482
|
+
import { useMemo as useMemo140, useState as useState88 } from "react";
|
|
44307
44483
|
import { Internals as Internals63 } from "remotion";
|
|
44308
|
-
import { jsx as
|
|
44484
|
+
import { jsx as jsx273 } from "react/jsx-runtime";
|
|
44309
44485
|
var MediaVolumeProvider = ({ children }) => {
|
|
44310
|
-
const [mediaMuted, setMediaMuted] =
|
|
44311
|
-
const [mediaVolume, setMediaVolume] =
|
|
44312
|
-
const mediaVolumeContextValue =
|
|
44486
|
+
const [mediaMuted, setMediaMuted] = useState88(() => loadMuteOption());
|
|
44487
|
+
const [mediaVolume, setMediaVolume] = useState88(1);
|
|
44488
|
+
const mediaVolumeContextValue = useMemo140(() => {
|
|
44313
44489
|
return {
|
|
44314
44490
|
mediaMuted,
|
|
44315
44491
|
mediaVolume
|
|
44316
44492
|
};
|
|
44317
44493
|
}, [mediaMuted, mediaVolume]);
|
|
44318
|
-
const setMediaVolumeContextValue =
|
|
44494
|
+
const setMediaVolumeContextValue = useMemo140(() => {
|
|
44319
44495
|
return {
|
|
44320
44496
|
setMediaMuted,
|
|
44321
44497
|
setMediaVolume
|
|
44322
44498
|
};
|
|
44323
44499
|
}, []);
|
|
44324
|
-
return /* @__PURE__ */
|
|
44500
|
+
return /* @__PURE__ */ jsx273(Internals63.MediaVolumeContext.Provider, {
|
|
44325
44501
|
value: mediaVolumeContextValue,
|
|
44326
|
-
children: /* @__PURE__ */
|
|
44502
|
+
children: /* @__PURE__ */ jsx273(Internals63.SetMediaVolumeContext.Provider, {
|
|
44327
44503
|
value: setMediaVolumeContextValue,
|
|
44328
44504
|
children
|
|
44329
44505
|
})
|
|
@@ -44331,24 +44507,24 @@ var MediaVolumeProvider = ({ children }) => {
|
|
|
44331
44507
|
};
|
|
44332
44508
|
|
|
44333
44509
|
// src/components/ModalsProvider.tsx
|
|
44334
|
-
import { useMemo as
|
|
44335
|
-
import { jsx as
|
|
44510
|
+
import { useMemo as useMemo141, useState as useState89 } from "react";
|
|
44511
|
+
import { jsx as jsx274 } from "react/jsx-runtime";
|
|
44336
44512
|
var ModalsProvider = ({ children }) => {
|
|
44337
|
-
const [modalContextType, setModalContextType] =
|
|
44338
|
-
const modalsContext =
|
|
44513
|
+
const [modalContextType, setModalContextType] = useState89(null);
|
|
44514
|
+
const modalsContext = useMemo141(() => {
|
|
44339
44515
|
return {
|
|
44340
44516
|
selectedModal: modalContextType,
|
|
44341
44517
|
setSelectedModal: setModalContextType
|
|
44342
44518
|
};
|
|
44343
44519
|
}, [modalContextType]);
|
|
44344
|
-
return /* @__PURE__ */
|
|
44520
|
+
return /* @__PURE__ */ jsx274(ModalsContext.Provider, {
|
|
44345
44521
|
value: modalsContext,
|
|
44346
44522
|
children
|
|
44347
44523
|
});
|
|
44348
44524
|
};
|
|
44349
44525
|
|
|
44350
44526
|
// src/components/SetTimelineInOutProvider.tsx
|
|
44351
|
-
import { useEffect as
|
|
44527
|
+
import { useEffect as useEffect83, useMemo as useMemo142, useState as useState90 } from "react";
|
|
44352
44528
|
|
|
44353
44529
|
// src/state/marks.ts
|
|
44354
44530
|
var localStorageKey5 = () => `remotion.editor.marksv2`;
|
|
@@ -44364,20 +44540,20 @@ var loadMarks = () => {
|
|
|
44364
44540
|
};
|
|
44365
44541
|
|
|
44366
44542
|
// src/components/SetTimelineInOutProvider.tsx
|
|
44367
|
-
import { jsx as
|
|
44543
|
+
import { jsx as jsx275 } from "react/jsx-runtime";
|
|
44368
44544
|
var SetTimelineInOutProvider = ({ children }) => {
|
|
44369
|
-
const [inAndOutFrames, setInAndOutFrames] =
|
|
44370
|
-
const setTimelineInOutContextValue =
|
|
44545
|
+
const [inAndOutFrames, setInAndOutFrames] = useState90(() => loadMarks());
|
|
44546
|
+
const setTimelineInOutContextValue = useMemo142(() => {
|
|
44371
44547
|
return {
|
|
44372
44548
|
setInAndOutFrames
|
|
44373
44549
|
};
|
|
44374
44550
|
}, []);
|
|
44375
|
-
|
|
44551
|
+
useEffect83(() => {
|
|
44376
44552
|
persistMarks(inAndOutFrames);
|
|
44377
44553
|
}, [inAndOutFrames]);
|
|
44378
|
-
return /* @__PURE__ */
|
|
44554
|
+
return /* @__PURE__ */ jsx275(TimelineInOutContext.Provider, {
|
|
44379
44555
|
value: inAndOutFrames,
|
|
44380
|
-
children: /* @__PURE__ */
|
|
44556
|
+
children: /* @__PURE__ */ jsx275(SetTimelineInOutContext.Provider, {
|
|
44381
44557
|
value: setTimelineInOutContextValue,
|
|
44382
44558
|
children
|
|
44383
44559
|
})
|
|
@@ -44385,15 +44561,15 @@ var SetTimelineInOutProvider = ({ children }) => {
|
|
|
44385
44561
|
};
|
|
44386
44562
|
|
|
44387
44563
|
// src/components/ShowGuidesProvider.tsx
|
|
44388
|
-
import { useCallback as useCallback137, useMemo as
|
|
44389
|
-
import { jsx as
|
|
44564
|
+
import { useCallback as useCallback137, useMemo as useMemo143, useRef as useRef46, useState as useState91 } from "react";
|
|
44565
|
+
import { jsx as jsx276 } from "react/jsx-runtime";
|
|
44390
44566
|
var ShowGuidesProvider = ({ children }) => {
|
|
44391
|
-
const [guidesList, setGuidesList] =
|
|
44392
|
-
const [selectedGuideId, setSelectedGuideId] =
|
|
44393
|
-
const [hoveredGuideId, setHoveredGuideId] =
|
|
44394
|
-
const [editorShowGuides, setEditorShowGuidesState] =
|
|
44395
|
-
const shouldCreateGuideRef =
|
|
44396
|
-
const shouldDeleteGuideRef =
|
|
44567
|
+
const [guidesList, setGuidesList] = useState91(() => loadGuidesList());
|
|
44568
|
+
const [selectedGuideId, setSelectedGuideId] = useState91(null);
|
|
44569
|
+
const [hoveredGuideId, setHoveredGuideId] = useState91(null);
|
|
44570
|
+
const [editorShowGuides, setEditorShowGuidesState] = useState91(() => loadEditorShowGuidesOption());
|
|
44571
|
+
const shouldCreateGuideRef = useRef46(false);
|
|
44572
|
+
const shouldDeleteGuideRef = useRef46(false);
|
|
44397
44573
|
const setEditorShowGuides = useCallback137((newValue) => {
|
|
44398
44574
|
setEditorShowGuidesState((prevState) => {
|
|
44399
44575
|
const newVal = newValue(prevState);
|
|
@@ -44401,7 +44577,7 @@ var ShowGuidesProvider = ({ children }) => {
|
|
|
44401
44577
|
return newVal;
|
|
44402
44578
|
});
|
|
44403
44579
|
}, []);
|
|
44404
|
-
const editorShowGuidesCtx =
|
|
44580
|
+
const editorShowGuidesCtx = useMemo143(() => {
|
|
44405
44581
|
return {
|
|
44406
44582
|
editorShowGuides,
|
|
44407
44583
|
setEditorShowGuides,
|
|
@@ -44421,17 +44597,17 @@ var ShowGuidesProvider = ({ children }) => {
|
|
|
44421
44597
|
selectedGuideId,
|
|
44422
44598
|
hoveredGuideId
|
|
44423
44599
|
]);
|
|
44424
|
-
return /* @__PURE__ */
|
|
44600
|
+
return /* @__PURE__ */ jsx276(EditorShowGuidesContext.Provider, {
|
|
44425
44601
|
value: editorShowGuidesCtx,
|
|
44426
44602
|
children
|
|
44427
44603
|
});
|
|
44428
44604
|
};
|
|
44429
44605
|
|
|
44430
44606
|
// src/components/ShowRulersProvider.tsx
|
|
44431
|
-
import { useCallback as useCallback138, useMemo as
|
|
44432
|
-
import { jsx as
|
|
44607
|
+
import { useCallback as useCallback138, useMemo as useMemo144, useState as useState92 } from "react";
|
|
44608
|
+
import { jsx as jsx277 } from "react/jsx-runtime";
|
|
44433
44609
|
var ShowRulersProvider = ({ children }) => {
|
|
44434
|
-
const [editorShowRulers, setEditorShowRulersState] =
|
|
44610
|
+
const [editorShowRulers, setEditorShowRulersState] = useState92(() => loadEditorShowRulersOption());
|
|
44435
44611
|
const setEditorShowRulers = useCallback138((newValue) => {
|
|
44436
44612
|
setEditorShowRulersState((prevState) => {
|
|
44437
44613
|
const newVal = newValue(prevState);
|
|
@@ -44439,23 +44615,23 @@ var ShowRulersProvider = ({ children }) => {
|
|
|
44439
44615
|
return newVal;
|
|
44440
44616
|
});
|
|
44441
44617
|
}, []);
|
|
44442
|
-
const editorShowRulersCtx =
|
|
44618
|
+
const editorShowRulersCtx = useMemo144(() => {
|
|
44443
44619
|
return {
|
|
44444
44620
|
editorShowRulers,
|
|
44445
44621
|
setEditorShowRulers
|
|
44446
44622
|
};
|
|
44447
44623
|
}, [editorShowRulers, setEditorShowRulers]);
|
|
44448
|
-
return /* @__PURE__ */
|
|
44624
|
+
return /* @__PURE__ */ jsx277(EditorShowRulersContext.Provider, {
|
|
44449
44625
|
value: editorShowRulersCtx,
|
|
44450
44626
|
children
|
|
44451
44627
|
});
|
|
44452
44628
|
};
|
|
44453
44629
|
|
|
44454
44630
|
// src/components/ZoomGesturesProvider.tsx
|
|
44455
|
-
import { useCallback as useCallback139, useMemo as
|
|
44456
|
-
import { jsx as
|
|
44631
|
+
import { useCallback as useCallback139, useMemo as useMemo145, useState as useState93 } from "react";
|
|
44632
|
+
import { jsx as jsx278 } from "react/jsx-runtime";
|
|
44457
44633
|
var ZoomGesturesProvider = ({ children }) => {
|
|
44458
|
-
const [editorZoomGestures, setEditorZoomGesturesState] =
|
|
44634
|
+
const [editorZoomGestures, setEditorZoomGesturesState] = useState93(() => loadEditorZoomGesturesOption());
|
|
44459
44635
|
const setEditorZoomGestures = useCallback139((newValue) => {
|
|
44460
44636
|
setEditorZoomGesturesState((prevState) => {
|
|
44461
44637
|
const newVal = newValue(prevState);
|
|
@@ -44463,40 +44639,40 @@ var ZoomGesturesProvider = ({ children }) => {
|
|
|
44463
44639
|
return newVal;
|
|
44464
44640
|
});
|
|
44465
44641
|
}, []);
|
|
44466
|
-
const editorZoomGesturesCtx =
|
|
44642
|
+
const editorZoomGesturesCtx = useMemo145(() => {
|
|
44467
44643
|
return {
|
|
44468
44644
|
editorZoomGestures,
|
|
44469
44645
|
setEditorZoomGestures
|
|
44470
44646
|
};
|
|
44471
44647
|
}, [editorZoomGestures, setEditorZoomGestures]);
|
|
44472
|
-
return /* @__PURE__ */
|
|
44648
|
+
return /* @__PURE__ */ jsx278(EditorZoomGesturesContext.Provider, {
|
|
44473
44649
|
value: editorZoomGesturesCtx,
|
|
44474
44650
|
children
|
|
44475
44651
|
});
|
|
44476
44652
|
};
|
|
44477
44653
|
|
|
44478
44654
|
// src/components/EditorContexts.tsx
|
|
44479
|
-
import { jsx as
|
|
44655
|
+
import { jsx as jsx279 } from "react/jsx-runtime";
|
|
44480
44656
|
var EditorContexts = ({ children, readOnlyStudio }) => {
|
|
44481
|
-
return /* @__PURE__ */
|
|
44482
|
-
children: /* @__PURE__ */
|
|
44483
|
-
children: /* @__PURE__ */
|
|
44657
|
+
return /* @__PURE__ */ jsx279(ZodProvider, {
|
|
44658
|
+
children: /* @__PURE__ */ jsx279(VisualControlsProvider, {
|
|
44659
|
+
children: /* @__PURE__ */ jsx279(PreviewServerConnection, {
|
|
44484
44660
|
readOnlyStudio,
|
|
44485
|
-
children: /* @__PURE__ */
|
|
44486
|
-
children: /* @__PURE__ */
|
|
44487
|
-
children: /* @__PURE__ */
|
|
44488
|
-
children: /* @__PURE__ */
|
|
44489
|
-
children: /* @__PURE__ */
|
|
44490
|
-
children: /* @__PURE__ */
|
|
44491
|
-
children: /* @__PURE__ */
|
|
44492
|
-
children: /* @__PURE__ */
|
|
44493
|
-
children: /* @__PURE__ */
|
|
44494
|
-
children: /* @__PURE__ */
|
|
44661
|
+
children: /* @__PURE__ */ jsx279(RenderQueueContextProvider, {
|
|
44662
|
+
children: /* @__PURE__ */ jsx279(KeybindingContextProvider, {
|
|
44663
|
+
children: /* @__PURE__ */ jsx279(CheckerboardProvider, {
|
|
44664
|
+
children: /* @__PURE__ */ jsx279(ZoomGesturesProvider, {
|
|
44665
|
+
children: /* @__PURE__ */ jsx279(ShowRulersProvider, {
|
|
44666
|
+
children: /* @__PURE__ */ jsx279(ShowGuidesProvider, {
|
|
44667
|
+
children: /* @__PURE__ */ jsx279(PreviewSizeProvider, {
|
|
44668
|
+
children: /* @__PURE__ */ jsx279(ModalsProvider, {
|
|
44669
|
+
children: /* @__PURE__ */ jsx279(MediaVolumeProvider, {
|
|
44670
|
+
children: /* @__PURE__ */ jsx279(PlayerInternals20.PlayerEmitterProvider, {
|
|
44495
44671
|
currentPlaybackRate: null,
|
|
44496
|
-
children: /* @__PURE__ */
|
|
44497
|
-
children: /* @__PURE__ */
|
|
44498
|
-
children: /* @__PURE__ */
|
|
44499
|
-
children: /* @__PURE__ */
|
|
44672
|
+
children: /* @__PURE__ */ jsx279(SidebarContextProvider, {
|
|
44673
|
+
children: /* @__PURE__ */ jsx279(FolderContextProvider, {
|
|
44674
|
+
children: /* @__PURE__ */ jsx279(HighestZIndexProvider, {
|
|
44675
|
+
children: /* @__PURE__ */ jsx279(SetTimelineInOutProvider, {
|
|
44500
44676
|
children
|
|
44501
44677
|
})
|
|
44502
44678
|
})
|
|
@@ -44519,7 +44695,7 @@ var EditorContexts = ({ children, readOnlyStudio }) => {
|
|
|
44519
44695
|
|
|
44520
44696
|
// src/components/Notifications/ServerDisconnected.tsx
|
|
44521
44697
|
import { useContext as useContext85 } from "react";
|
|
44522
|
-
import { jsx as
|
|
44698
|
+
import { jsx as jsx280, jsxs as jsxs147 } from "react/jsx-runtime";
|
|
44523
44699
|
var container63 = {
|
|
44524
44700
|
position: "fixed",
|
|
44525
44701
|
justifyContent: "flex-end",
|
|
@@ -44564,26 +44740,26 @@ var ServerDisconnected = () => {
|
|
|
44564
44740
|
}
|
|
44565
44741
|
const base64Favicon = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkCAYAAABw4pVUAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAARiSURBVHgB7d1NThRBFAfw/2tGgru5gXMD8QZ4AmVjAi6kN0TiAm8gnkBcGARNumcx4E48Ae0JaE9gewLHlQSZelaNgyHGL/RVd1X3+y10RQL58+rVx1QBKKWUUkoppZRSSimllFJKKVUjQs32stEiJcktZiwxzKL9Fvqzb6S0/44JVBKbtwa9aj29U6JjagtkJzsYzBEyBi9d5utsQIULCcxvelgo03R5jBarJZCXw/17E+bt82r4Hy4gtuEQekUbK8h7IHvDV5vMZht+VAlRfmYw3EhXKrSA10Ce2X7RIzpGDVzlgM1wPb2bI2JeA9nN99/b/waoV+XCmTAex1g13gLZyUZrdjjJ0CAbTB5bMN4C2ctHxwxaRABiCsZLIG6KmxC/R2BiCCaBBwn4NgJk10B2GOWj3Wz/IQLlpUL28oOjyy4AG1AZppuhVYt4hWRZ1o8gDGc6rL4YHjxCQMQDOcNCEI38bxnmLTc9d30PARAPZAITZP/4A1ctx3bjcw0NEw8koeQ64tRnu25qeggTb+q2/BmRcyv9K7yw3MTOsmiFuLMOtICblJzS5+Mm+opoIBOgFYHMuL5yVHcoooFQuwJxag9FNJCIG/rv1BqKaCDfzshbqbZQxAJxK3SJI9qATUPJstdef0axQGJbof+jwRc6eQ2PxAIx4DZXx3duSrybv3oCTyR7yACdYR762sIXDKQbFfId4ZGPJi8YCA3QLf05YvF+IhYIEV1Dx9hNu8XdbLQFQV6OcDuFaFNyKiwWiJ19DNBN/VN8XoMQrRABDFqCEJ32CiBisT08rRAZAwjRQAKjgcgQO+rVQARMb3gJ0UAkML+DEA1EwAQkdkNMcnOx1Zcxf8V9ol7y88GSm4tdDKRy1xsgSIes/0BM4ndN5HZ7OzZkMePperqSQ5jkkFWhO6r76WrYJ4b2N+YTumF60QeeSG6/d2DI4rHvW1eCPaT9Q9YZw/sVOMlZVoUWM8zpg/Su97dVJGdZFVrKhbFR05MdYoFcwWmF1rF9kbG8UeP7KaI3qBp628QTHrueUccwdZHw/ZDWNHY7tU1u1B2GIxqIYSO2Dd0Ud79wnq/eaOpBgR4EMVDW/oijINu87d7U6hYaJBrInA0k0iu4bvVtZ1KrBRrm4Vr06GNkF3cO7RCVhvK4pmiFOISkjOStk1lVrBQIiPh5SAyN3fWKWeMuEBjxCmEkh3bVvokAzd5idL2iQqDEA1nASXmK+XFIfeTCo5gFAudllvo8G20TUeNVElMQ58QrxLHD1jbB3GumSnhsz7qHE9BhTEGc87aOm16KJHi7rfqj8yfI53E1j/l9eK8L651stJUQeXx/iuzU1QztZLGIsRp+xvtOh3Qo3/qCedumEC6qZetpJztwz7O6UAa4FNsP7ELTfXbWbskUdjgq9M9VCJoFcwvTlfyPDd9t3XNJjA+2IZcGpmxi+7tpjW3OupurJziZhtKWPzWhlFJKKaWUUkoppZRSSiml/uwrgZ/Bfwo/wccAAAAASUVORK5CYII=";
|
|
44566
44742
|
fav.setAttribute("href", base64Favicon);
|
|
44567
|
-
return /* @__PURE__ */
|
|
44743
|
+
return /* @__PURE__ */ jsx280("div", {
|
|
44568
44744
|
style: container63,
|
|
44569
44745
|
className: "css-reset",
|
|
44570
|
-
children: /* @__PURE__ */
|
|
44746
|
+
children: /* @__PURE__ */ jsxs147("div", {
|
|
44571
44747
|
style: message,
|
|
44572
44748
|
children: [
|
|
44573
44749
|
"The studio server has disconnected. ",
|
|
44574
|
-
/* @__PURE__ */
|
|
44575
|
-
window.remotion_studioServerCommand ? /* @__PURE__ */
|
|
44750
|
+
/* @__PURE__ */ jsx280("br", {}),
|
|
44751
|
+
window.remotion_studioServerCommand ? /* @__PURE__ */ jsxs147("span", {
|
|
44576
44752
|
children: [
|
|
44577
44753
|
"Run",
|
|
44578
44754
|
" ",
|
|
44579
|
-
/* @__PURE__ */
|
|
44755
|
+
/* @__PURE__ */ jsx280("code", {
|
|
44580
44756
|
style: inlineCode,
|
|
44581
44757
|
children: window.remotion_studioServerCommand
|
|
44582
44758
|
}),
|
|
44583
44759
|
" ",
|
|
44584
44760
|
"to run it again."
|
|
44585
44761
|
]
|
|
44586
|
-
}) : /* @__PURE__ */
|
|
44762
|
+
}) : /* @__PURE__ */ jsx280("span", {
|
|
44587
44763
|
children: "Fast refresh will not work."
|
|
44588
44764
|
})
|
|
44589
44765
|
]
|
|
@@ -44748,7 +44924,7 @@ var injectCSS = () => {
|
|
|
44748
44924
|
};
|
|
44749
44925
|
|
|
44750
44926
|
// src/Studio.tsx
|
|
44751
|
-
import { jsx as
|
|
44927
|
+
import { jsx as jsx281, jsxs as jsxs148 } from "react/jsx-runtime";
|
|
44752
44928
|
var getServerDisconnectedDomElement = () => {
|
|
44753
44929
|
return document.getElementById("server-disconnected-overlay");
|
|
44754
44930
|
};
|
|
@@ -44756,27 +44932,27 @@ var Studio = ({ rootComponent, readOnly }) => {
|
|
|
44756
44932
|
useLayoutEffect2(() => {
|
|
44757
44933
|
injectCSS();
|
|
44758
44934
|
}, []);
|
|
44759
|
-
return /* @__PURE__ */
|
|
44935
|
+
return /* @__PURE__ */ jsx281(Internals65.CompositionManagerProvider, {
|
|
44760
44936
|
onlyRenderComposition: null,
|
|
44761
44937
|
currentCompositionMetadata: null,
|
|
44762
44938
|
initialCompositions: [],
|
|
44763
44939
|
initialCanvasContent: null,
|
|
44764
|
-
children: /* @__PURE__ */
|
|
44940
|
+
children: /* @__PURE__ */ jsx281(Internals65.RemotionRootContexts, {
|
|
44765
44941
|
frameState: null,
|
|
44766
44942
|
audioEnabled: window.remotion_audioEnabled,
|
|
44767
44943
|
videoEnabled: window.remotion_videoEnabled,
|
|
44768
44944
|
logLevel: window.remotion_logLevel,
|
|
44769
44945
|
numberOfAudioTags: window.remotion_numberOfAudioTags,
|
|
44770
44946
|
audioLatencyHint: window.remotion_audioLatencyHint ?? "interactive",
|
|
44771
|
-
children: /* @__PURE__ */
|
|
44772
|
-
children: /* @__PURE__ */
|
|
44947
|
+
children: /* @__PURE__ */ jsx281(Internals65.ResolveCompositionConfigInStudio, {
|
|
44948
|
+
children: /* @__PURE__ */ jsxs148(EditorContexts, {
|
|
44773
44949
|
readOnlyStudio: readOnly,
|
|
44774
44950
|
children: [
|
|
44775
|
-
/* @__PURE__ */
|
|
44951
|
+
/* @__PURE__ */ jsx281(Editor, {
|
|
44776
44952
|
readOnlyStudio: readOnly,
|
|
44777
44953
|
Root: rootComponent
|
|
44778
44954
|
}),
|
|
44779
|
-
readOnly ? null : createPortal(/* @__PURE__ */
|
|
44955
|
+
readOnly ? null : createPortal(/* @__PURE__ */ jsx281(ServerDisconnected, {}), getServerDisconnectedDomElement())
|
|
44780
44956
|
]
|
|
44781
44957
|
})
|
|
44782
44958
|
})
|