Skip to content

Commit

Permalink
feat: save crop per recording
Browse files Browse the repository at this point in the history
  • Loading branch information
jrafaaael committed May 12, 2024
1 parent 939737e commit fb15aeb
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/routes/[id]/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
appearence
} from './stores/general-appearance.store';
import { zooms } from './stores/zooms.store';
import { crop } from './stores/crop.store';
import { getBlobDuration } from './utils/get-blob-duration';
import Header from './components/header.svelte';
import Toolbox from './components/toolbox/toolbox.svelte';
Expand All @@ -36,6 +37,8 @@
zooms.load(values?.zooms ?? []);
$background = values?.background ?? DEFAULT_BACKGROUND;
$appearence = values?.appearence ?? DEFAULT_APPEARENCE;
$crop = values?.crop ? values?.crop : null;
if (values?.trimmings) {
$edits = values?.trimmings;
}
Expand Down Expand Up @@ -68,7 +71,8 @@
background: $background,
appearence: $appearence,
zooms: $zooms,
trimmings: $edits
trimmings: $edits,
crop: $crop
};
localStorage.setItem($page.params.id, JSON.stringify(values));
Expand Down

0 comments on commit fb15aeb

Please sign in to comment.