Skip to content

armgit / Cap

Public Imported from GitHub
0

Open source Loom alternative. Beautiful, shareable screen recordings.

feat(desktop): add setClipSegmentSpeedAudioMode project action

Richie McIlroy80f4cbc5f0c9
diff --git a/apps/desktop/src/routes/editor/context.ts b/apps/desktop/src/routes/editor/context.ts
index 7ed1ea051..ecf69d553 100644
--- a/apps/desktop/src/routes/editor/context.ts
+++ b/apps/desktop/src/routes/editor/context.ts
@@ -37,6 +37,7 @@ import {
type FrameData,
} from "~/utils/socket";
import {
+ type ClipSpeedAudioMode,
commands,
type EditorPreviewQuality,
events,
@@ -959,6 +960,18 @@ export const [EditorContextProvider, useEditorContext] = createContextProvider(
}),
);
},
+ setClipSegmentSpeedAudioMode: (
+ index: number,
+ speedAudioMode: ClipSpeedAudioMode,
+ ) => {
+ setProject(
+ "timeline",
+ "segments",
+ index,
+ "speedAudioMode",
+ speedAudioMode,
+ );
+ },
};
let projectSaveTimeout: number | undefined;