summaryrefslogtreecommitdiff
path: root/apps/web/src/components
diff options
context:
space:
mode:
authorMaze Winther <mazewinther@gmail.com>2026-02-02 19:14:37 +0100
committerMaze Winther <mazewinther@gmail.com>2026-02-02 19:14:37 +0100
commite88a059222470d6b5e40baf1d81a314940a98955 (patch)
tree75ea5d3aaded536377a14ef517104787254d4dbe /apps/web/src/components
parentc3f0d640ef366fe4d94ff995ee8fe5ef282b9c1e (diff)
downloadopencut-e88a059222470d6b5e40baf1d81a314940a98955.tar.gz
increase zoom of buttons + refactor
Diffstat (limited to 'apps/web/src/components')
-rw-r--r--apps/web/src/components/editor/timeline/timeline-toolbar.tsx12
1 files changed, 7 insertions, 5 deletions
diff --git a/apps/web/src/components/editor/timeline/timeline-toolbar.tsx b/apps/web/src/components/editor/timeline/timeline-toolbar.tsx
index 33cf83ae..6ac6fba5 100644
--- a/apps/web/src/components/editor/timeline/timeline-toolbar.tsx
+++ b/apps/web/src/components/editor/timeline/timeline-toolbar.tsx
@@ -51,11 +51,13 @@ export function TimelineToolbar({
setZoomLevel: ({ zoom }: { zoom: number }) => void;
}) {
const handleZoom = ({ direction }: { direction: "in" | "out" }) => {
- const zoomFactor = 1.25;
const newZoomLevel =
direction === "in"
- ? Math.min(TIMELINE_CONSTANTS.ZOOM_MAX, zoomLevel * zoomFactor)
- : Math.max(minZoom, zoomLevel / zoomFactor);
+ ? Math.min(
+ TIMELINE_CONSTANTS.ZOOM_MAX,
+ zoomLevel * TIMELINE_CONSTANTS.ZOOM_BUTTON_FACTOR,
+ )
+ : Math.max(minZoom, zoomLevel / TIMELINE_CONSTANTS.ZOOM_BUTTON_FACTOR);
setZoomLevel({ zoom: newZoomLevel });
};
@@ -297,7 +299,7 @@ function ToolbarRightSection({
type="button"
onClick={() => onZoom({ direction: "out" })}
>
- <HugeiconsIcon icon={SearchAddIcon} />
+ <HugeiconsIcon icon={SearchMinusIcon} />
</Button>
<Slider
className="w-28"
@@ -315,7 +317,7 @@ function ToolbarRightSection({
type="button"
onClick={() => onZoom({ direction: "in" })}
>
- <HugeiconsIcon icon={SearchMinusIcon} />
+ <HugeiconsIcon icon={SearchAddIcon} />
</Button>
</div>
</div>