Record your screen, ship a demo. Free and open-source, GPU-accelerated, no watermarks, no subscriptions. Windows, macOS, Linux. Actively maintained.
TypeScript cross-platformelectronffmpegopen-sourceproduct-demorustscreen-capturescreen-recorderscreen-recordingscreen-studioscreencastspeech-to-texttypescriptvideo-editingvideo-editorwaylandwgpuwhisper
rm blur
Siddharth332b6b7d38f5
diff --git a/src/components/video-editor/KeyboardShortcutsHelp.tsx b/src/components/video-editor/KeyboardShortcutsHelp.tsxindex b90b377e4..23311225c 100644--- a/src/components/video-editor/KeyboardShortcutsHelp.tsx+++ b/src/components/video-editor/KeyboardShortcutsHelp.tsx@@ -2,6 +2,7 @@ import { HelpCircle, Settings2 } from "lucide-react";import { useScopedT } from "@/contexts/I18nContext";import { useShortcuts } from "@/contexts/ShortcutsContext";import { FIXED_SHORTCUTS, formatBinding, SHORTCUT_ACTIONS } from "@/lib/shortcuts";+import { BLUR_REGIONS_ENABLED } from "./featureFlags";export function KeyboardShortcutsHelp() {const { shortcuts, isMac, openConfig } = useShortcuts();@@ -26,14 +27,16 @@ export function KeyboardShortcutsHelp() {</div><div className="space-y-1.5 text-[10px]">- {SHORTCUT_ACTIONS.map((action) => (- <div key={action} className="flex items-center justify-between">- <span className="text-slate-400">{t(`actions.${action}`)}</span>- <kbd className="px-1 py-0.5 bg-white/5 border border-white/10 rounded text-[#34B27B] font-mono">- {formatBinding(shortcuts[action], isMac)}- </kbd>- </div>- ))}+ {SHORTCUT_ACTIONS.filter((action) => BLUR_REGIONS_ENABLED || action !== "addBlur").map(+ (action) => (+ <div key={action} className="flex items-center justify-between">+ <span className="text-slate-400">{t(`actions.${action}`)}</span>+ <kbd className="px-1 py-0.5 bg-white/5 border border-white/10 rounded text-[#34B27B] font-mono">+ {formatBinding(shortcuts[action], isMac)}+ </kbd>+ </div>+ ),+ )}<div className="pt-1 border-t border-white/5 mt-1 space-y-1.5">{FIXED_SHORTCUTS.map((fixed) => (diff --git a/src/components/video-editor/SettingsPanel.tsx b/src/components/video-editor/SettingsPanel.tsxindex b9bfeca0f..e584d0abd 100644--- a/src/components/video-editor/SettingsPanel.tsx+++ b/src/components/video-editor/SettingsPanel.tsx@@ -66,6 +66,7 @@ import {DEFAULT_SOURCE_DIMENSIONS,DEFAULT_WEBCAM_SETTINGS,} from "./editorDefaults";+import { BLUR_REGIONS_ENABLED } from "./featureFlags";import { KeyboardShortcutsHelp } from "./KeyboardShortcutsHelp";import type {AnnotationRegion,@@ -782,7 +783,7 @@ export function SettingsPanel({);}- if (selectedBlur && onBlurDataChange && onBlurDelete) {+ if (BLUR_REGIONS_ENABLED && selectedBlur && onBlurDataChange && onBlurDelete) {return (<div className="editor-inspector-shell flex min-w-0 flex-col h-full overflow-hidden"><div className="min-h-0 flex-1 overflow-hidden">diff --git a/src/components/video-editor/ShortcutsConfigDialog.tsx b/src/components/video-editor/ShortcutsConfigDialog.tsxindex c5e950397..dcd073513 100644--- a/src/components/video-editor/ShortcutsConfigDialog.tsx+++ b/src/components/video-editor/ShortcutsConfigDialog.tsx@@ -22,6 +22,7 @@ import {type ShortcutConflict,type ShortcutsConfig,} from "@/lib/shortcuts";+import { BLUR_REGIONS_ENABLED } from "./featureFlags";const MODIFIER_KEYS = new Set(["Control", "Shift", "Alt", "Meta"]);@@ -143,61 +144,63 @@ export function ShortcutsConfigDialog() {<p className="text-[10px] text-slate-500 mb-2 uppercase tracking-wide font-semibold">{t("configurable")}</p>- {SHORTCUT_ACTIONS.map((action) => {- const isCapturing = captureFor === action;- const hasConflict = conflict?.forAction === action;- return (- <div key={action}>- <div className="flex items-center justify-between py-1.5 px-1 border-b border-white/5">- <span className="text-sm text-slate-300">{t(`actions.${action}`)}</span>- <button- type="button"- onClick={() => {- setConflict(null);- setCaptureFor(isCapturing ? null : action);- }}- title={isCapturing ? t("pressEscToCancel") : t("clickToChange")}- className={[- "px-2 py-1 rounded text-xs font-mono border transition-all min-w-[90px] text-center select-none",- isCapturing- ? "bg-[#34B27B]/20 border-[#34B27B] text-[#34B27B] animate-pulse"- : hasConflict- ? "bg-amber-500/10 border-amber-500/50 text-amber-400"- : "bg-white/5 border-white/10 text-slate-200 hover:border-[#34B27B]/50 hover:text-[#34B27B] cursor-pointer",- ].join(" ")}- >- {isCapturing ? t("pressKey") : formatBinding(draft[action], isMac)}- </button>- </div>- {hasConflict && conflict?.conflictWith.type === "configurable" && (- <div className="flex items-center justify-between px-1 py-1.5 mb-0.5 bg-amber-500/10 border border-amber-500/20 rounded text-xs">- <span className="text-amber-400">- ⚠{" "}- {t("alreadyUsedBy", {- action: t(`actions.${conflict.conflictWith.action}`),- })}- </span>- <div className="flex gap-1.5">- <button- type="button"- onClick={handleSwap}- className="px-2 py-0.5 bg-amber-500/20 hover:bg-amber-500/30 border border-amber-500/40 rounded text-amber-300 font-medium transition-colors"- >- {t("swap")}- </button>- <button- type="button"- onClick={handleCancelConflict}- className="px-2 py-0.5 bg-white/5 hover:bg-white/10 border border-white/10 rounded text-slate-400 transition-colors"- >- {tc("actions.cancel")}- </button>- </div>+ {SHORTCUT_ACTIONS.filter((action) => BLUR_REGIONS_ENABLED || action !== "addBlur").map(+ (action) => {+ const isCapturing = captureFor === action;+ const hasConflict = conflict?.forAction === action;+ return (+ <div key={action}>+ <div className="flex items-center justify-between py-1.5 px-1 border-b border-white/5">+ <span className="text-sm text-slate-300">{t(`actions.${action}`)}</span>+ <button+ type="button"+ onClick={() => {+ setConflict(null);+ setCaptureFor(isCapturing ? null : action);+ }}+ title={isCapturing ? t("pressEscToCancel") : t("clickToChange")}+ className={[+ "px-2 py-1 rounded text-xs font-mono border transition-all min-w-[90px] text-center select-none",+ isCapturing+ ? "bg-[#34B27B]/20 border-[#34B27B] text-[#34B27B] animate-pulse"+ : hasConflict+ ? "bg-amber-500/10 border-amber-500/50 text-amber-400"+ : "bg-white/5 border-white/10 text-slate-200 hover:border-[#34B27B]/50 hover:text-[#34B27B] cursor-pointer",+ ].join(" ")}+ >+ {isCapturing ? t("pressKey") : formatBinding(draft[action], isMac)}+ </button></div>- )}- </div>- );- })}+ {hasConflict && conflict?.conflictWith.type === "configurable" && (+ <div className="flex items-center justify-between px-1 py-1.5 mb-0.5 bg-amber-500/10 border border-amber-500/20 rounded text-xs">+ <span className="text-amber-400">+ ⚠{" "}+ {t("alreadyUsedBy", {+ action: t(`actions.${conflict.conflictWith.action}`),+ })}+ </span>+ <div className="flex gap-1.5">+ <button+ type="button"+ onClick={handleSwap}+ className="px-2 py-0.5 bg-amber-500/20 hover:bg-amber-500/30 border border-amber-500/40 rounded text-amber-300 font-medium transition-colors"+ >+ {t("swap")}+ </button>+ <button+ type="button"+ onClick={handleCancelConflict}+ className="px-2 py-0.5 bg-white/5 hover:bg-white/10 border border-white/10 rounded text-slate-400 transition-colors"+ >+ {tc("actions.cancel")}+ </button>+ </div>+ </div>+ )}+ </div>+ );+ },+ )}</div><div className="space-y-0.5 mt-2">diff --git a/src/components/video-editor/featureFlags.ts b/src/components/video-editor/featureFlags.tsnew file mode 100644index 000000000..8bf73f726--- /dev/null+++ b/src/components/video-editor/featureFlags.ts@@ -0,0 +1 @@+export const BLUR_REGIONS_ENABLED = false;diff --git a/src/components/video-editor/timeline/TimelineEditor.tsx b/src/components/video-editor/timeline/TimelineEditor.tsxindex 12ac0b0a5..6f6d8f545 100644--- a/src/components/video-editor/timeline/TimelineEditor.tsx+++ b/src/components/video-editor/timeline/TimelineEditor.tsx@@ -29,6 +29,7 @@ import { matchesShortcut } from "@/lib/shortcuts";import { cn } from "@/lib/utils";import { ASPECT_RATIOS, type AspectRatio, getAspectRatioLabel } from "@/utils/aspectRatioUtils";import { formatShortcut } from "@/utils/platformUtils";+import { BLUR_REGIONS_ENABLED } from "../featureFlags";import type { AnnotationRegion, SpeedRegion, TrimRegion, ZoomRegion } from "../types";import BackgroundWaveform from "./BackgroundWaveform";import Item from "./Item";@@ -849,21 +850,23 @@ function Timeline({))}</Row>- <Row id={BLUR_ROW_ID} isEmpty={blurItems.length === 0} hint={t("hints.pressBlur")}>- {blurItems.map((item) => (- <Item- id={item.id}- key={item.id}- rowId={item.rowId}- span={item.span}- isSelected={item.id === selectedBlurId}- onSelect={() => onSelectBlur?.(item.id)}- variant={item.variant}- >- {item.label}- </Item>- ))}- </Row>+ {BLUR_REGIONS_ENABLED && (+ <Row id={BLUR_ROW_ID} isEmpty={blurItems.length === 0} hint={t("hints.pressBlur")}>+ {blurItems.map((item) => (+ <Item+ id={item.id}+ key={item.id}+ rowId={item.rowId}+ span={item.span}+ isSelected={item.id === selectedBlurId}+ onSelect={() => onSelectBlur?.(item.id)}+ variant={item.variant}+ >+ {item.label}+ </Item>+ ))}+ </Row>+ )}<Row id={SPEED_ROW_ID} isEmpty={speedItems.length === 0} hint={t("hints.pressSpeed")}>{speedItems.map((item) => (@@ -1276,7 +1279,7 @@ export default function TimelineEditor({if (matchesShortcut(e, keyShortcuts.addAnnotation, isMac)) {handleAddAnnotation();}- if (matchesShortcut(e, keyShortcuts.addBlur, isMac)) {+ if (BLUR_REGIONS_ENABLED && matchesShortcut(e, keyShortcuts.addBlur, isMac)) {handleAddBlur();}if (matchesShortcut(e, keyShortcuts.addSpeed, isMac)) {@@ -1558,25 +1561,27 @@ export default function TimelineEditor({><MessageSquare className="w-4 h-4" /></Button>- <Button- onClick={handleAddBlur}- variant="ghost"- size="icon"- className="h-7 w-7 rounded-lg text-slate-400 hover:text-[#7dd3fc] hover:bg-[#7dd3fc]/10 transition-all"- title={t("buttons.addBlur")}- >- <svg- className="w-4 h-4"- viewBox="0 0 24 24"- fill="none"- stroke="currentColor"- strokeWidth="2"+ {BLUR_REGIONS_ENABLED && (+ <Button+ onClick={handleAddBlur}+ variant="ghost"+ size="icon"+ className="h-7 w-7 rounded-lg text-slate-400 hover:text-[#7dd3fc] hover:bg-[#7dd3fc]/10 transition-all"+ title={t("buttons.addBlur")}>- <circle cx="8" cy="12" r="3" />- <circle cx="16" cy="12" r="3" />- <path d="M6 6h12M6 18h12" />- </svg>- </Button>+ <svg+ className="w-4 h-4"+ viewBox="0 0 24 24"+ fill="none"+ stroke="currentColor"+ strokeWidth="2"+ >+ <circle cx="8" cy="12" r="3" />+ <circle cx="16" cy="12" r="3" />+ <path d="M6 6h12M6 18h12" />+ </svg>+ </Button>+ )}<ButtononClick={handleAddSpeed}variant="ghost"