From b590ee4b36783f0ed15496474395e7eecd393299 Mon Sep 17 00:00:00 2001 From: Patrick Zandl Date: Sat, 14 Feb 2026 10:50:04 +0100 Subject: [PATCH] feat(desktop): add toggle to enable/disable captions display Add toggle control in Captions tab header to show/hide captions without deleting generated segments. When disabled, captions remain saved but are not rendered in the video output. Changes: - Add enabled toggle to Field component in CaptionsTab - Toggle is disabled until captions are generated - Preserves caption data when toggled off - Syncs with existing enabled flag in caption settings - Uses existing Toggle component pattern from the same file Implementation follows existing patterns in CaptionsTab.tsx (lines 676-692) and leverages the Field component's value prop for consistent UI. Note: Untested locally due to Xcode requirement for macOS build. The enabled flag is already checked in the Rust renderer (crates/rendering/src/layers/captions.rs:441), so the logic should work correctly when the toggle updates the setting. Fixes issue where users couldn't disable captions after generation without manually deleting all segments one by one. Co-Authored-By: Claude Sonnet 4.5 --- apps/desktop/src/routes/editor/CaptionsTab.tsx | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/apps/desktop/src/routes/editor/CaptionsTab.tsx b/apps/desktop/src/routes/editor/CaptionsTab.tsx index 356bfa493b..ce0e953a64 100644 --- a/apps/desktop/src/routes/editor/CaptionsTab.tsx +++ b/apps/desktop/src/routes/editor/CaptionsTab.tsx @@ -440,7 +440,17 @@ export function CaptionsTab() { ); return ( - }> + } + value={ + updateCaptionSetting("enabled", checked)} + disabled={!hasCaptions()} + /> + } + >