Skip to content

armgit / Cap

Public Imported from GitHub
0

Open source Loom alternative. Beautiful, shareable screen recordings.

disable main window transition temporarily + add recording delay

Brendan Allan75fcb4cf47ab
diff --git a/apps/desktop/src-tauri/src/recording.rs b/apps/desktop/src-tauri/src/recording.rs
index 1f8048118..1a05fdb8b 100644
--- a/apps/desktop/src-tauri/src/recording.rs
+++ b/apps/desktop/src-tauri/src/recording.rs
@@ -260,6 +260,8 @@ pub async fn start(
let ffmpeg_process = ffmpeg.start();
+ tokio::time::sleep(Duration::from_secs(1)).await;
+
println!("Starting writing to named pipes");
start_writing_tx.send(true).unwrap();
diff --git a/apps/desktop/src/routes/(main).tsx b/apps/desktop/src/routes/(main).tsx
index 80785442c..38243db57 100644
--- a/apps/desktop/src/routes/(main).tsx
+++ b/apps/desktop/src/routes/(main).tsx
@@ -8,7 +8,7 @@ export default function (props: RouteSectionProps) {
return (
<div class="rounded-[1.5rem] bg-gray-100 border border-gray-200 w-screen h-screen flex flex-col overflow-hidden">
<Header />
- <Transition
+ {/*<Transition
mode="outin"
enterClass="opacity-0 -translate-y-0.5"
enterActiveClass="transition-[opacity,transform] duration-200"
@@ -17,19 +17,19 @@ export default function (props: RouteSectionProps) {
exitActiveClass="transition-[opacity,transform] duration-20"
exitToClass="opacity-0"
appear={false}
- >
- <Suspense
- fallback={
- <div class="w-full h-full flex items-center justify-center bg-gray-100">
- <div class="animate-spin">
- <IconCapLogo class="size-[4rem]" />
- </div>
+ >*/}
+ <Suspense
+ fallback={
+ <div class="w-full h-full flex items-center justify-center bg-gray-100">
+ <div class="animate-spin">
+ <IconCapLogo class="size-[4rem]" />
</div>
- }
- >
- {props.children}
- </Suspense>
- </Transition>
+ </div>
+ }
+ >
+ {props.children}
+ </Suspense>
+ {/*</Transition>*/}
</div>
);
}
diff --git a/apps/desktop/src/routes/(main)/index.tsx b/apps/desktop/src/routes/(main)/index.tsx
index 335486aa9..8cccbb98c 100644
--- a/apps/desktop/src/routes/(main)/index.tsx
+++ b/apps/desktop/src/routes/(main)/index.tsx
@@ -96,8 +96,6 @@ export default function () {
const audioDevice = () =>
audioDevicesData().find((d) => d.name === options().audioInputName);
- createEffect(() => console.log(audioDevice()));
-
return (
<>
<KSelect<CaptureWindow | null>