Skip to content

armgit / Cap

Public Imported from GitHub
0

Open source Loom alternative. Beautiful, shareable screen recordings.

feat: Prev-recordings thumbnail state fixes

Richie McIlroy81a5250b8819
diff --git a/.github/workflows/debug.yml b/.github/workflows/debug.yml
index 2872fa99c..513746a64 100644
--- a/.github/workflows/debug.yml
+++ b/.github/workflows/debug.yml
@@ -53,7 +53,7 @@ jobs:
- name: Create .env file in root
run: |
echo "appVersion=debug" >> .env
- echo "CAP_DESKTOP_SENTRY_URL=https://efd3156d9c0a8a49bee3ee675bec80d8@o4506859771527168.ingest.us.sentry.io/4506859844403200" >> .env
+ echo "CAP_DESKTOP_SENTRY_URL=https://6a3b6a09e6ae976c2ad6fff710e88748@o4506859771527168.ingest.us.sentry.io/4508330917101568" >> .env
echo "NEXT_PUBLIC_URL=${{ secrets.NEXT_PUBLIC_URL }}" >> .env
echo 'NEXTAUTH_URL=${NEXT_PUBLIC_URL}' >> .env
echo 'VITE_SERVER_URL=${NEXT_PUBLIC_URL}' >> .env
diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml
index 74160d06b..5d70f3b2e 100644
--- a/.github/workflows/main.yml
+++ b/.github/workflows/main.yml
@@ -50,7 +50,7 @@ jobs:
echo "appVersion=${{ steps.get_version.outputs.appVersion }}" >> .env
echo "NEXT_PUBLIC_ENVIRONMENT=production" >> .env
echo "NEXT_PUBLIC_LOCAL_MODE=false" >> .env
- echo "CAP_DESKTOP_SENTRY_URL=https://efd3156d9c0a8a49bee3ee675bec80d8@o4506859771527168.ingest.us.sentry.io/4506859844403200" >> .env
+ echo "CAP_DESKTOP_SENTRY_URL=https://6a3b6a09e6ae976c2ad6fff710e88748@o4506859771527168.ingest.us.sentry.io/4508330917101568" >> .env
- name: Copy .env to apps/desktop
run: cp .env apps/desktop/.env
diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml
index cbc5895f3..70896056d 100644
--- a/.github/workflows/publish.yml
+++ b/.github/workflows/publish.yml
@@ -128,7 +128,7 @@ jobs:
- name: Create .env file in root
run: |
echo "appVersion=${{ needs.draft.outputs.version }}" >> .env
- echo "CAP_DESKTOP_SENTRY_URL=https://efd3156d9c0a8a49bee3ee675bec80d8@o4506859771527168.ingest.us.sentry.io/4506859844403200" >> .env
+ echo "CAP_DESKTOP_SENTRY_URL=https://6a3b6a09e6ae976c2ad6fff710e88748@o4506859771527168.ingest.us.sentry.io/4508330917101568" >> .env
echo "NEXT_PUBLIC_URL=${{ secrets.NEXT_PUBLIC_URL }}" >> .env
echo 'NEXTAUTH_URL=${NEXT_PUBLIC_URL}' >> .env
echo 'VITE_SERVER_URL=${NEXT_PUBLIC_URL}' >> .env
diff --git a/apps/desktop/src-tauri/src/lib.rs b/apps/desktop/src-tauri/src/lib.rs
index 6f69d0cb2..70446b91c 100644
--- a/apps/desktop/src-tauri/src/lib.rs
+++ b/apps/desktop/src-tauri/src/lib.rs
@@ -511,35 +511,92 @@ async fn get_rendered_video(
project: ProjectConfiguration,
) -> Result<PathBuf, String> {
let editor_instance = upsert_editor_instance(&app, video_id.clone()).await;
- get_rendered_video_impl(editor_instance, project, false).await
+ let output_path = editor_instance
+ .project_path
+ .join("output")
+ .join("result.mp4");
+
+ // If the file doesn't exist, return an error to trigger the progress-enabled path
+ if !output_path.exists() {
+ return Err("Rendered video does not exist".to_string());
+ }
+
+ Ok(output_path)
+}
+
+#[tauri::command]
+#[specta::specta]
+async fn get_rendered_video_with_progress(
+ app: AppHandle,
+ video_id: String,
+ project: ProjectConfiguration,
+ progress_channel: tauri::ipc::Channel<RenderProgress>,
+) -> Result<PathBuf, String> {
+ get_rendered_video_impl(app, video_id, project, Some(progress_channel)).await
}
async fn get_rendered_video_impl(
- editor_instance: Arc<EditorInstance>,
+ app: AppHandle,
+ video_id: String,
project: ProjectConfiguration,
- force_render: bool,
+ progress_channel: Option<tauri::ipc::Channel<RenderProgress>>,
) -> Result<PathBuf, String> {
+ let editor_instance = upsert_editor_instance(&app, video_id.clone()).await;
let output_path = editor_instance
.project_path
.join("output")
.join("result.mp4");
- if !force_render && output_path.exists() {
+ // If the file exists, return it immediately
+ if output_path.exists() {
return Ok(output_path);
}
- cap_export::export_video_to_file(
- project,
- output_path.clone(),
- |_| {},
- &editor_instance.project_path,
- editor_instance.audio.clone(),
- editor_instance.meta(),
- editor_instance.render_constants.clone(),
- editor_instance.cursor.clone(),
- )
- .await
- .map_err(|e| e.to_string())?;
+ // If we need to render and have a progress channel, use it
+ if let Some(progress) = progress_channel {
+ let (duration, _size) =
+ get_video_metadata(app.clone(), video_id.clone(), Some(VideoType::Screen))
+ .await
+ .unwrap();
+
+ // 30 FPS (calculated for output video)
+ let total_frames = (duration * 30.0).round() as u32;
+
+ progress
+ .send(RenderProgress::EstimatedTotalFrames { total_frames })
+ .ok();
+
+ cap_export::export_video_to_file(
+ project,
+ output_path.clone(),
+ move |current_frame| {
+ progress
+ .send(RenderProgress::FrameRendered { current_frame })
+ .ok();
+ },
+ &editor_instance.project_path,
+ editor_instance.audio.clone(),
+ editor_instance.meta(),
+ editor_instance.render_constants.clone(),
+ editor_instance.cursor.clone(),
+ )
+ .await
+ .map_err(|e| e.to_string())?;
+ } else {
+ // Render without progress updates
+ cap_export::export_video_to_file(
+ project,
+ output_path.clone(),
+ |_| {},
+ &editor_instance.project_path,
+ editor_instance.audio.clone(),
+ editor_instance.meta(),
+ editor_instance.render_constants.clone(),
+ editor_instance.cursor.clone(),
+ )
+ .await
+ .map_err(|e| e.to_string())?;
+ }
Ok(output_path)
}
@@ -1224,7 +1281,7 @@ async fn upload_rendered_video(
.emit(&app)
.ok();
- let output_path = match get_rendered_video_impl(editor_instance.clone(), project, false).await {
+ let output_path = match get_rendered_video(app.clone(), video_id.clone(), project).await {
Ok(path) => {
// Emit rendering complete
UploadProgress {
@@ -1841,6 +1898,8 @@ pub async fn run() {
get_current_recording,
render_to_file,
get_rendered_video,
+ get_rendered_video_with_progress,
+ render_video_with_progress,
copy_file_to_path,
copy_video_to_clipboard,
copy_screenshot_to_clipboard,
@@ -2120,8 +2179,8 @@ pub async fn run() {
tokio::task::yield_now().await;
});
}
- CapWindowId::Settings { .. } => {
- // Don't quit the app when settings window is closed
+ CapWindowId::Settings | CapWindowId::Upgrade => {
+ // Don't quit the app when settings or upgrade window is closed
return;
}
_ => {}
@@ -2330,7 +2389,6 @@ async fn reupload_rendered_video(
return Err("No sharing metadata found".to_string());
};
- // Emit initial rendering progress
UploadProgress {
stage: "rendering".to_string(),
progress: 0.0,
@@ -2339,10 +2397,8 @@ async fn reupload_rendered_video(
.emit(&app)
.ok();
- // Pass true to force_render to ensure we create a new video
- let output_path = match get_rendered_video_impl(editor_instance.clone(), project, true).await {
+ let output_path = match get_rendered_video(app.clone(), video_id.clone(), project).await {
Ok(path) => {
- // Emit rendering complete
UploadProgress {
stage: "rendering".to_string(),
progress: 1.0,
@@ -2403,3 +2459,49 @@ async fn reupload_rendered_video(
fn global_message_dialog(app: AppHandle, message: String) {
app.dialog().message(message).show(|_| {});
}
+
+#[tauri::command]
+#[specta::specta]
+async fn render_video_with_progress(
+ app: AppHandle,
+ video_id: String,
+ project: ProjectConfiguration,
+ progress_channel: tauri::ipc::Channel<RenderProgress>,
+) -> Result<PathBuf, String> {
+ let editor_instance = upsert_editor_instance(&app, video_id.clone()).await;
+ let output_path = editor_instance
+ .project_path
+ .join("output")
+ .join("result.mp4");
+
+ let (duration, _size) =
+ get_video_metadata(app.clone(), video_id.clone(), Some(VideoType::Screen))
+ .await
+ .unwrap();
+
+ // 30 FPS (calculated for output video)
+ let total_frames = (duration * 30.0).round() as u32;
+
+ progress_channel
+ .send(RenderProgress::EstimatedTotalFrames { total_frames })
+ .ok();
+
+ cap_export::export_video_to_file(
+ project,
+ output_path.clone(),
+ move |current_frame| {
+ progress_channel
+ .send(RenderProgress::FrameRendered { current_frame })
+ .ok();
+ },
+ &editor_instance.project_path,
+ editor_instance.audio.clone(),
+ editor_instance.meta(),
+ editor_instance.render_constants.clone(),
+ editor_instance.cursor.clone(),
+ )
+ .await
+ .map_err(|e| e.to_string())?;
+
+ Ok(output_path)
+}
diff --git a/apps/desktop/src-tauri/src/windows.rs b/apps/desktop/src-tauri/src/windows.rs
index d62ca949e..37c963c24 100644
--- a/apps/desktop/src-tauri/src/windows.rs
+++ b/apps/desktop/src-tauri/src/windows.rs
@@ -181,8 +181,11 @@ impl ShowCapWindow {
Self::Upgrade => {
let mut window_builder = self
.window_builder(app, "/upgrade")
- .inner_size(800.0, 850.0)
+ .inner_size(800.0, 800.0)
.resizable(false)
+ .focused(true)
+ .visible(true)
+ .always_on_top(true)
.maximized(false)
.transparent(true);
@@ -263,6 +266,7 @@ impl ShowCapWindow {
.fullscreen(false)
.shadow(true)
.always_on_top(true)
+ .transparent(true)
.visible_on_all_workspaces(true)
.content_protected(true)
.inner_size(width, height)
diff --git a/apps/desktop/src/routes/(window-chrome)/upgrade.tsx b/apps/desktop/src/routes/(window-chrome)/upgrade.tsx
index c4e4cfbc2..e49585a56 100644
--- a/apps/desktop/src/routes/(window-chrome)/upgrade.tsx
+++ b/apps/desktop/src/routes/(window-chrome)/upgrade.tsx
@@ -9,7 +9,7 @@ import { getCurrentWindow } from "@tauri-apps/api/window";
export default function Page() {
const proFeatures = [
"Unlimited cloud storage & Shareable links",
- "Connect custom S3 storage bucket (soon!)",
+ "Connect custom S3 storage bucket",
"Advanced teams features",
"Unlimited views",
"Password protected videos",
@@ -105,20 +105,23 @@ export default function Page() {
{!upgradeComplete() && (
<>
<div class="text-center">
- <h1 class="text-4xl md:text-5xl mb-3 tracking-[-.05em] font-medium">
+ <h1 class="text-4xl md:text-4xl mb-3 tracking-[-.05em] font-medium">
Upgrade to Cap Pro
</h1>
<p class="text-base font-normal leading-6 text-gray-400">
Cap is currently in public beta, and we're offering special early
- adopter pricing to our first users. This pricing will be locked in
- for the lifetime of your subscription.
+ adopter pricing to our first users.{" "}
+ <span class="text-gray-500">
+ This pricing will be locked in for the lifetime of your
+ subscription.
+ </span>
</p>
</div>
<div class="flex flex-col p-[1rem] gap-[0.75rem] text-[0.875rem] font-[400] flex-1 bg-gray-100">
- <div class="border text-card-foreground shadow-sm bg-blue-300 p-3 md:p-8 rounded-xl flex-grow border-blue-500/20">
+ <div class="border text-card-foreground shadow-sm bg-blue-300 p-3 md:p-3 rounded-xl flex-grow border-blue-500/20">
<div class="space-y-3">
<div class="flex flex-col space-y-1.5 pt-6 px-6 pb-3">
- <h3 class="font-medium tracking-tight text-3xl text-gray-50">
+ <h3 class="font-medium tracking-tight text-2xl text-gray-50">
Cap Pro — Early Adopter Pricing
</h3>
<p class="text-[0.875rem] leading-[1.25rem] text-gray-50/80">
diff --git a/apps/desktop/src/routes/editor/Header.tsx b/apps/desktop/src/routes/editor/Header.tsx
index 5a3cc2ff0..d1a2b5f40 100644
--- a/apps/desktop/src/routes/editor/Header.tsx
+++ b/apps/desktop/src/routes/editor/Header.tsx
@@ -209,7 +209,7 @@ function ExportButton() {
renderProgress: 0,
totalFrames: 0,
message: "Preparing to render...",
- mediaPath: p,
+ mediaPath: path,
stage: "rendering",
});
diff --git a/apps/desktop/src/routes/in-progress-recording.tsx b/apps/desktop/src/routes/in-progress-recording.tsx
index 751d9d564..727fd2e9a 100644
--- a/apps/desktop/src/routes/in-progress-recording.tsx
+++ b/apps/desktop/src/routes/in-progress-recording.tsx
@@ -53,7 +53,7 @@ export default function () {
return (
<div
- class="text-gray-400 flex flex-row items-stretch bg-gray-500 w-full h-full animate-in fade-in"
+ class="text-gray-400 flex flex-row items-stretch bg-gray-500 w-full h-full rounded-[0.75rem] animate-in fade-in"
data-tauri-drag-region
>
<div class="flex flex-row justify-between p-[0.25rem] flex-1">
diff --git a/apps/desktop/src/routes/prev-recordings.tsx b/apps/desktop/src/routes/prev-recordings.tsx
index 6345d250f..fa3575d87 100644
--- a/apps/desktop/src/routes/prev-recordings.tsx
+++ b/apps/desktop/src/routes/prev-recordings.tsx
@@ -178,65 +178,102 @@ export default function () {
progress: 0,
renderProgress: 0,
totalFrames: 0,
- message: "Preparing to render...",
+ message: "Preparing...",
mediaPath: media.path,
stage: "rendering",
});
try {
if (isRecording) {
- console.log("Setting up render progress channel");
- const progress = new Channel<RenderProgress>();
- progress.onmessage = (p) => {
- console.log("Progress channel message:", p);
- if (
- p.type === "FrameRendered" &&
- progressState.type === "copying"
- ) {
- console.log(
- "Frame rendered in copy:",
- p.current_frame,
- "Current state:",
- progressState
- );
- setProgressState({
- ...progressState,
- renderProgress: p.current_frame,
- });
- }
- if (
- p.type === "EstimatedTotalFrames" &&
- progressState.type === "copying"
- ) {
- console.log(
- "Got total frames in copy:",
- p.total_frames
- );
- setProgressState({
- ...progressState,
- totalFrames: p.total_frames,
- });
- }
- };
-
- console.log("Starting render to file");
- const outputPath = await commands.renderToFile(
- mediaId,
- presets.getDefaultConfig() ?? DEFAULT_PROJECT_CONFIG,
- progress
- );
- console.log("Render to file completed");
-
- await commands.copyVideoToClipboard(outputPath);
+ let outputPath: string;
+
+ try {
+ // First try to get existing rendered video
+ outputPath = await commands.getRenderedVideo(
+ mediaId,
+ presets.getDefaultConfig() ?? DEFAULT_PROJECT_CONFIG
+ );
+ console.log("Using existing rendered video");
+
+ // Show quick progress animation for existing video
+ setProgressState({
+ type: "copying",
+ progress: 0,
+ renderProgress: 100,
+ totalFrames: 100,
+ message: "Copying to clipboard...",
+ mediaPath: media.path,
+ stage: "rendering",
+ });
+
+ await commands.copyVideoToClipboard(outputPath);
+ } catch (error) {
+ console.log(
+ "Need to render video with progress:",
+ error
+ );
+ const progress = new Channel<RenderProgress>();
+ progress.onmessage = (p) => {
+ console.log("Progress channel message:", p);
+ if (
+ p.type === "FrameRendered" &&
+ progressState.type === "copying"
+ ) {
+ console.log(
+ "Frame rendered:",
+ p.current_frame,
+ "Total frames:",
+ progressState.totalFrames
+ );
+ setProgressState({
+ ...progressState,
+ message: "Rendering video...",
+ renderProgress: p.current_frame,
+ });
+ }
+ if (
+ p.type === "EstimatedTotalFrames" &&
+ progressState.type === "copying"
+ ) {
+ console.log("Got total frames:", p.total_frames);
+ setProgressState({
+ ...progressState,
+ totalFrames: p.total_frames,
+ });
+ }
+ };
+
+ outputPath = await commands.renderVideoWithProgress(
+ mediaId,
+ presets.getDefaultConfig() ??
+ DEFAULT_PROJECT_CONFIG,
+ progress
+ );
+ console.log("Video rendered, copying to clipboard");
+ await commands.copyVideoToClipboard(outputPath);
+ }
} else {
+ // For screenshots, show quick progress animation
+ setProgressState({
+ type: "copying",
+ progress: 50,
+ renderProgress: 100,
+ totalFrames: 100,
+ message: "Copying image to clipboard...",
+ mediaPath: media.path,
+ stage: "rendering",
+ });
await commands.copyScreenshotToClipboard(media.path);
}
setProgressState({
type: "copying",
progress: 100,
+ renderProgress: 100,
+ totalFrames: 100,
message: "Copied successfully!",
mediaPath: media.path,
+ stage: "rendering",
});
setTimeout(() => {
@@ -257,7 +294,9 @@ export default function () {
progress: 0,
renderProgress: 0,
totalFrames: 0,
- message: "Preparing to render...",
+ message: isRecording
+ ? "Choose where to save video..."
+ : "Choose where to save image...",
mediaPath: media.path,
stage: "rendering",
});
@@ -291,45 +330,103 @@ export default function () {
}
if (isRecording) {
- const progress = new Channel<RenderProgress>();
- progress.onmessage = (p) => {
- if (
- p.type === "FrameRendered" &&
- progressState.type === "saving"
- ) {
- setProgressState({
- ...progressState,
- renderProgress: p.current_frame,
- });
- }
- if (
- p.type === "EstimatedTotalFrames" &&
- progressState.type === "saving"
- ) {
- console.log("Total frames: ", p.total_frames);
- setProgressState({
- ...progressState,
- totalFrames: p.total_frames,
- });
- }
- };
-
- const output_path = await commands.renderToFile(
- mediaId,
- presets.getDefaultConfig() ?? DEFAULT_PROJECT_CONFIG,
- progress
- );
-
- await commands.copyFileToPath(output_path, savePath);
+ let outputPath: string;
+
+ try {
+ // First try to get existing rendered video
+ outputPath = await commands.getRenderedVideo(
+ mediaId,
+ presets.getDefaultConfig() ?? DEFAULT_PROJECT_CONFIG
+ );
+ console.log("Using existing rendered video");
+
+ // Show quick progress animation for existing video
+ setProgressState({
+ type: "saving",
+ progress: 0,
+ renderProgress: 100,
+ totalFrames: 100,
+ message: "Saving video...",
+ mediaPath: media.path,
+ stage: "rendering",
+ });
+ } catch (error) {
+ // If it doesn't exist, render with progress
+ console.log("Need to render video:", error);
+ const progress = new Channel<RenderProgress>();
+ progress.onmessage = (p) => {
+ console.log("Progress channel message:", p);
+ if (
+ p.type === "FrameRendered" &&
+ progressState.type === "saving"
+ ) {
+ console.log(
+ "Frame rendered:",
+ p.current_frame,
+ "Total frames:",
+ progressState.totalFrames
+ );
+ setProgressState({
+ ...progressState,
+ message: "Rendering video...",
+ renderProgress: p.current_frame,
+ });
+ }
+ if (
+ p.type === "EstimatedTotalFrames" &&
+ progressState.type === "saving"
+ ) {
+ console.log("Got total frames:", p.total_frames);
+ setProgressState({
+ ...progressState,
+ totalFrames: p.total_frames,
+ });
+ }
+ };
+
+ outputPath = await commands.renderVideoWithProgress(
+ mediaId,
+ presets.getDefaultConfig() ??
+ DEFAULT_PROJECT_CONFIG,
+ progress
+ );
+ }
+
+ // Show copying progress
+ setProgressState({
+ type: "saving",
+ progress: 50,
+ renderProgress: 100,
+ totalFrames: 100,
+ message: "Copying file...",
+ mediaPath: media.path,
+ stage: "rendering",
+ });
+
+ await commands.copyFileToPath(outputPath, savePath);
} else {
+ // For screenshots, show quick progress animation
+ setProgressState({
+ type: "saving",
+ progress: 50,
+ renderProgress: 0,
+ totalFrames: 0,
+ message: "Saving image...",
+ mediaPath: media.path,
+ stage: "rendering",
+ });
+
await commands.copyFileToPath(media.path, savePath);
}
setProgressState({
type: "saving",
progress: 100,
+ renderProgress: 100,
+ totalFrames: 100,
message: "Saved successfully!",
mediaPath: media.path,
+ stage: "rendering",
});
setTimeout(() => {
@@ -360,6 +457,12 @@ export default function () {
return;
}
+ const isUpgraded = await commands.checkUpgradedAndUpdate();
+ if (!isUpgraded) {
+ await commands.openUpgradeWindow();
+ return;
+ }
+
setProgressState({
type: "uploading",
renderProgress: 0,
@@ -372,47 +475,9 @@ export default function () {
try {
let res: UploadResult;
if (isRecording) {
- const progress = new Channel<RenderProgress>();
- progress.onmessage = (p) => {
- console.log("Upload render progress:", p);
- if (
- p.type === "FrameRendered" &&
- progressState.type === "uploading"
- ) {
- console.log(
- "Frame rendered in upload:",
- p.current_frame,
- "Current state:",
- progressState
- );
- setProgressState({
- ...progressState,
- renderProgress: Math.round(
- (p.current_frame /
- (progressState.totalFrames || 1)) *
- 100
- ),
- });
- }
- if (
- p.type === "EstimatedTotalFrames" &&
- progressState.type === "uploading"
- ) {
- console.log(
- "Got total frames in upload:",
- p.total_frames
- );
- setProgressState({
- ...progressState,
- totalFrames: p.total_frames,
- });
- }
- };
-
- await commands.renderToFile(
+ const outputPath = await commands.getRenderedVideo(
mediaId,
- presets.getDefaultConfig() ?? DEFAULT_PROJECT_CONFIG,
- progress
+ presets.getDefaultConfig() ?? DEFAULT_PROJECT_CONFIG
);
res = await commands.uploadRenderedVideo(
@@ -430,7 +495,9 @@ export default function () {
case "PlanCheckFailed":
throw new Error("Plan check failed");
case "UpgradeRequired":
- throw new Error("Upgrade required");
+ setProgressState({ type: "idle" });
+ setShowUpgradeTooltip(true);
+ return;
default:
break;
}
@@ -531,9 +598,11 @@ export default function () {
>
{(state) => (
<h3 class="text-sm font-medium mb-3 text-gray-50">
- {state().stage === "rendering"
- ? "Rendering video"
- : "Copying to clipboard"}
+ {isRecording
+ ? state().stage === "rendering"
+ ? "Rendering video"
+ : "Copying to clipboard"
+ : "Copying image to clipboard"}
</h3>
)}
</Match>
@@ -545,9 +614,11 @@ export default function () {
>
{(state) => (
<h3 class="text-sm font-medium mb-3 text-gray-50">
- {state().stage === "rendering"
- ? "Rendering video"
- : "Saving file"}
+ {isRecording
+ ? state().stage === "rendering"
+ ? "Rendering video"
+ : "Saving video"
+ : "Saving image"}
</h3>
)}
</Match>
@@ -731,17 +802,7 @@ export default function () {
}
tooltipPlacement="left"
onClick={() => {
- uploadMedia.mutate(undefined, {
- onError: (error) => {
- if (error.message === "Upgrade required") {
- setShowUpgradeTooltip(true);
- setTimeout(
- () => setShowUpgradeTooltip(false),
- 10000
- );
- }
- },
- });
+ uploadMedia.mutate();
}}
disabled={
copyMedia.isPending ||
diff --git a/apps/desktop/src/utils/tauri.ts b/apps/desktop/src/utils/tauri.ts
index 42ce8c5b6..1de0c5df6 100644
--- a/apps/desktop/src/utils/tauri.ts
+++ b/apps/desktop/src/utils/tauri.ts
@@ -62,6 +62,12 @@ async renderToFile(videoId: string, project: ProjectConfiguration, progressChann
async getRenderedVideo(videoId: string, project: ProjectConfiguration) : Promise<string> {
return await TAURI_INVOKE("get_rendered_video", { videoId, project });
},
+async getRenderedVideoWithProgress(videoId: string, project: ProjectConfiguration, progressChannel: TAURI_CHANNEL<RenderProgress>) : Promise<string> {
+ return await TAURI_INVOKE("get_rendered_video_with_progress", { videoId, project, progressChannel });
+},
+async renderVideoWithProgress(videoId: string, project: ProjectConfiguration, progressChannel: TAURI_CHANNEL<RenderProgress>) : Promise<string> {
+ return await TAURI_INVOKE("render_video_with_progress", { videoId, project, progressChannel });
+},
async copyFileToPath(src: string, dst: string) : Promise<null> {
return await TAURI_INVOKE("copy_file_to_path", { src, dst });
},
diff --git a/apps/web/components/pages/PricingPage.tsx b/apps/web/components/pages/PricingPage.tsx
index 9cc8e07cd..ad0491a0f 100644
--- a/apps/web/components/pages/PricingPage.tsx
+++ b/apps/web/components/pages/PricingPage.tsx
@@ -155,7 +155,7 @@ export const PricingPage = () => {
</div>
<div className="grid grid-cols-1 md:grid-cols-3 gap-3 items-stretch">
<Card
- className={`bg-white rounded-xl min-h-[600px] flex-grow ${
+ className={`bg-gray-100 rounded-xl min-h-[600px] flex-grow ${
initialRender ? "fade-in-down animate-delay-2" : ""
}`}
>
@@ -172,7 +172,7 @@ export const PricingPage = () => {
<CardContent>
<Button
href="/download"
- className="w-full bg-gray-100 hover:bg-gray-200"
+ className="w-full hover:bg-gray-200"
variant="white"
size="lg"
>