Skip to content

Record your screen, ship a demo. Free and open-source, GPU-accelerated, no watermarks, no subscriptions. Windows, macOS, Linux. Actively maintained.

fix(editor): say when "fill frame" only fills some of the clips

Etienne Lescot511a099c1754
diff --git a/src/components/ai-edition/NewEditorShell.module.css b/src/components/ai-edition/NewEditorShell.module.css
index b3855eed3..b5c5910d9 100644
--- a/src/components/ai-edition/NewEditorShell.module.css
+++ b/src/components/ai-edition/NewEditorShell.module.css
@@ -987,6 +987,12 @@
color: var(--fg-2);
margin: 4px var(--sp-4) 8px;
}
+/* Caveat under a control, when the control is true but not the whole story. */
+.paneHint {
+ margin: -2px var(--sp-4) 8px;
+ font: 400 var(--fs-app-sm)/1.4 var(--font-body);
+ color: var(--meta);
+}
.uploadBtn {
display: flex;
align-items: center;
diff --git a/src/components/ai-edition/RightPanes.tsx b/src/components/ai-edition/RightPanes.tsx
index ef1369540..6cae93bc3 100644
--- a/src/components/ai-edition/RightPanes.tsx
+++ b/src/components/ai-edition/RightPanes.tsx
@@ -1544,6 +1544,15 @@ export function VideoEffectsPane() {
const nativeFormats = useMemo(() => (document ? collectNativeFormats(document) : []), [document]);
const nativeTokens = useMemo(() => new Set(nativeFormats.map((f) => f.token)), [nativeFormats]);
const frameIsFilled = fillsFrame(settings, nativeTokens);
+ // One output frame cannot be filled by clips of different shapes — the screen path
+ // contain-fits (see compositeLayout.ts), so anything not in the chosen shape keeps its
+ // bars. The switch is honest about the SETTINGS; without this it would also be read as a
+ // claim about the picture, and be wrong on every mixed timeline.
+ const clipsStillFramed = useMemo(() => {
+ const filled = nativeFormats.find((f) => f.token === settings.aspectRatio);
+ const total = nativeFormats.reduce((n, f) => n + f.clipCount, 0);
+ return total - (filled?.clipCount ?? 0);
+ }, [nativeFormats, settings.aspectRatio]);
// Le rayon natif = rayon de base de la fixture (~24px @1920) × cette échelle. Diviser la
// valeur px de l'UI par ce même rayon de base fait que le coin natif ≈ les px affichés
@@ -1589,6 +1598,11 @@ export function VideoEffectsPane() {
onChange={toggleFillFrame}
/>
</div>
+ {frameIsFilled && clipsStillFramed > 0 ? (
+ <div className={styles.paneHint} role="note">
+ {ts("effects.fillFrameMixed")}
+ </div>
+ ) : null}
<div className={styles.sliderGrid}>
<SliderCell
label={ts("effects.shadow")}
diff --git a/src/components/ai-edition/fillFrame.test.ts b/src/components/ai-edition/fillFrame.test.ts
index 5afeafa59..78011e5bc 100644
--- a/src/components/ai-edition/fillFrame.test.ts
+++ b/src/components/ai-edition/fillFrame.test.ts
@@ -40,6 +40,17 @@ describe("fillsFrame reads the four settings, not a stored flag", () => {
expect(fillsFrame({ ...FILLED, aspectRatio: "9:16" as AspectRatio }, mixed)).toBe(true);
});
+ it("is a claim about the SETTINGS, not about every clip on a mixed timeline", () => {
+ // Deliberate, and the pane says so out loud: one output frame cannot be filled by
+ // clips of different shapes, because the screen path contain-fits. With 16:9 and 9:16
+ // on the timeline, whichever shape is chosen leaves the other letterboxed — so this
+ // reads true while background is still visible on some clips, and `clipsStillFramed`
+ // in VideoEffectsPane is what stops that from being a silent lie.
+ const mixed = new Set<AspectRatio>(["16:9", "9:16"]);
+ expect(fillsFrame({ ...FILLED, aspectRatio: "16:9" as AspectRatio }, mixed)).toBe(true);
+ expect(fillsFrame({ ...FILLED, aspectRatio: "9:16" as AspectRatio }, mixed)).toBe(true);
+ });
+
it("is false for a timeline whose shapes are unknown", () => {
// No clips probed yet — there is nothing to fill, so the toggle must not read ON.
expect(fillsFrame(FILLED, new Set())).toBe(false);
diff --git a/src/i18n/locales/ar/settings.json b/src/i18n/locales/ar/settings.json
index 4a139e1e9..e1a9eebf0 100644
--- a/src/i18n/locales/ar/settings.json
+++ b/src/i18n/locales/ar/settings.json
@@ -76,6 +76,7 @@
"padding": "المسافة البادئة",
"frame": "الإطار",
"fillFrame": "ملء الإطار",
+ "fillFrameMixed": "المقاطع ذات الشكل المختلف لا تزال تُظهر الخلفية.",
"motion": "الحركة",
"help": "تنسيق إطار التسجيل: ضبابية الخلفية، والظل، وضبابية الحركة، واستدارة الزوايا، والحشو حول الفيديو."
},
diff --git a/src/i18n/locales/en/settings.json b/src/i18n/locales/en/settings.json
index 1de8adcfe..f4c16ca36 100644
--- a/src/i18n/locales/en/settings.json
+++ b/src/i18n/locales/en/settings.json
@@ -82,6 +82,7 @@
"padding": "Padding",
"frame": "Frame",
"fillFrame": "Fill frame",
+ "fillFrameMixed": "Clips in another shape still show the background.",
"motion": "Motion",
"help": "Frame styling for the recording: background blur, drop shadow, motion blur, corner radius, and padding around the video."
},
diff --git a/src/i18n/locales/es/settings.json b/src/i18n/locales/es/settings.json
index 52208d6d1..c0736ddad 100644
--- a/src/i18n/locales/es/settings.json
+++ b/src/i18n/locales/es/settings.json
@@ -75,6 +75,7 @@
"padding": "Relleno",
"frame": "Marco",
"fillFrame": "Llenar el marco",
+ "fillFrameMixed": "Los clips con otra forma siguen mostrando el fondo.",
"motion": "Movimiento",
"on": "activado",
"help": "Estilo del marco de la grabación: desenfoque de fondo, sombra, desenfoque de movimiento, radio de esquinas y margen alrededor del vídeo."
diff --git a/src/i18n/locales/fr/settings.json b/src/i18n/locales/fr/settings.json
index e62aac1ed..4fd9c4a08 100644
--- a/src/i18n/locales/fr/settings.json
+++ b/src/i18n/locales/fr/settings.json
@@ -75,6 +75,7 @@
"padding": "Marge",
"frame": "Cadre",
"fillFrame": "Plein cadre",
+ "fillFrameMixed": "Les clips d'une autre forme affichent encore le fond.",
"motion": "Mouvement",
"on": "activé",
"help": "Mise en forme du cadre de l'enregistrement : flou d'arrière-plan, ombre portée, flou de mouvement, arrondi des coins et marge autour de la vidéo."
diff --git a/src/i18n/locales/it/settings.json b/src/i18n/locales/it/settings.json
index f2b79fa9d..e5da5b5a7 100644
--- a/src/i18n/locales/it/settings.json
+++ b/src/i18n/locales/it/settings.json
@@ -76,6 +76,7 @@
"padding": "Spaziatura",
"frame": "Cornice",
"fillFrame": "Riempi la cornice",
+ "fillFrameMixed": "Le clip con un'altra forma mostrano ancora lo sfondo.",
"motion": "Movimento",
"help": "Stile della cornice della registrazione: sfocatura dello sfondo, ombra, sfocatura di movimento, raggio degli angoli e margine attorno al video."
},
diff --git a/src/i18n/locales/ja-JP/settings.json b/src/i18n/locales/ja-JP/settings.json
index 066b21cc1..ee0246775 100644
--- a/src/i18n/locales/ja-JP/settings.json
+++ b/src/i18n/locales/ja-JP/settings.json
@@ -75,6 +75,7 @@
"padding": "余白",
"frame": "フレーム",
"fillFrame": "フレームいっぱい",
+ "fillFrameMixed": "別の形状のクリップには背景が残ります。",
"motion": "モーション",
"on": "オン",
"help": "録画フレームのスタイル設定: 背景ぼかし、ドロップシャドウ、モーションブラー、角丸、動画まわりの余白。"
diff --git a/src/i18n/locales/ko-KR/settings.json b/src/i18n/locales/ko-KR/settings.json
index 3114bad4c..b105588e2 100644
--- a/src/i18n/locales/ko-KR/settings.json
+++ b/src/i18n/locales/ko-KR/settings.json
@@ -76,6 +76,7 @@
"padding": "여백",
"frame": "프레임",
"fillFrame": "프레임 채우기",
+ "fillFrameMixed": "다른 비율의 클립에는 배경이 그대로 남습니다.",
"motion": "모션",
"help": "녹화 프레임 스타일: 배경 흐림, 그림자, 모션 블러, 모서리 둥글기, 영상 주변 여백."
},
diff --git a/src/i18n/locales/pt-BR/settings.json b/src/i18n/locales/pt-BR/settings.json
index e074edc6c..550392d35 100644
--- a/src/i18n/locales/pt-BR/settings.json
+++ b/src/i18n/locales/pt-BR/settings.json
@@ -76,6 +76,7 @@
"padding": "Espaçamento",
"frame": "Moldura",
"fillFrame": "Preencher a moldura",
+ "fillFrameMixed": "Clipes com outro formato ainda mostram o fundo.",
"motion": "Movimento",
"help": "Estilo do quadro da gravação: desfoque de fundo, sombra, desfoque de movimento, raio dos cantos e margem em volta do vídeo."
},
diff --git a/src/i18n/locales/ru/settings.json b/src/i18n/locales/ru/settings.json
index 8c500fd0a..a704885ad 100644
--- a/src/i18n/locales/ru/settings.json
+++ b/src/i18n/locales/ru/settings.json
@@ -76,6 +76,7 @@
"padding": "Отступ",
"frame": "Рамка",
"fillFrame": "Во весь кадр",
+ "fillFrameMixed": "Клипы другой формы по-прежнему показывают фон.",
"motion": "Движение",
"help": "Оформление кадра записи: размытие фона, тень, размытие движения, скругление углов и отступ вокруг видео."
},
diff --git a/src/i18n/locales/tr/settings.json b/src/i18n/locales/tr/settings.json
index 36c5687fa..4e0e7278e 100644
--- a/src/i18n/locales/tr/settings.json
+++ b/src/i18n/locales/tr/settings.json
@@ -75,6 +75,7 @@
"padding": "Dolgu",
"frame": "Çerçeve",
"fillFrame": "Çerçeveyi doldur",
+ "fillFrameMixed": "Başka bir orandaki klipler arka planı göstermeye devam eder.",
"motion": "Hareket",
"on": "açık",
"help": "Kayıt çerçevesinin biçimi: arka plan bulanıklığı, gölge, hareket bulanıklığı, köşe yuvarlaklığı ve videonun çevresindeki boşluk."
diff --git a/src/i18n/locales/vi/settings.json b/src/i18n/locales/vi/settings.json
index aeffb8a4b..a5b68fac3 100644
--- a/src/i18n/locales/vi/settings.json
+++ b/src/i18n/locales/vi/settings.json
@@ -75,6 +75,7 @@
"padding": "Phần đệm",
"frame": "Khung",
"fillFrame": "Lấp đầy khung",
+ "fillFrameMixed": "Các clip có tỉ lệ khác vẫn hiển thị nền.",
"motion": "Chuyển động",
"on": "bật",
"help": "Kiểu khung của bản ghi: làm mờ nền, đổ bóng, mờ chuyển động, bo góc và khoảng đệm quanh video."
diff --git a/src/i18n/locales/zh-CN/settings.json b/src/i18n/locales/zh-CN/settings.json
index b6a2ad67d..fc7b87c3f 100644
--- a/src/i18n/locales/zh-CN/settings.json
+++ b/src/i18n/locales/zh-CN/settings.json
@@ -75,6 +75,7 @@
"padding": "内边距",
"frame": "画框",
"fillFrame": "填满画框",
+ "fillFrameMixed": "其他比例的片段仍会显示背景。",
"motion": "运动",
"on": "开",
"help": "录制画面的边框样式:背景模糊、投影、运动模糊、圆角半径以及视频四周的内边距。"
diff --git a/src/i18n/locales/zh-TW/settings.json b/src/i18n/locales/zh-TW/settings.json
index 3aec2f390..dc3f01c1a 100644
--- a/src/i18n/locales/zh-TW/settings.json
+++ b/src/i18n/locales/zh-TW/settings.json
@@ -76,6 +76,7 @@
"padding": "內邊距",
"frame": "外框",
"fillFrame": "填滿外框",
+ "fillFrameMixed": "其他比例的片段仍會顯示背景。",
"motion": "動態",
"on": "開",
"help": "錄製畫面的外框樣式:背景模糊、陰影、動態模糊、圓角半徑,以及影片四周的內距。"