From ab82db63465de33a6f482ef5007edb9ea544ad2f Mon Sep 17 00:00:00 2001 From: Maze Winther Date: Mon, 21 Jul 2025 21:42:44 +0200 Subject: Merge pull request [#395](https://github.com/mazeincoding/AppCut/issues/395) --- apps/web/src/components/editor/timeline/index.tsx | 23 ++++++++++++++++++++--- apps/web/src/components/ui/scroll-area.tsx | 9 +++++++-- 2 files changed, 27 insertions(+), 5 deletions(-) (limited to 'apps/web/src/components') diff --git a/apps/web/src/components/editor/timeline/index.tsx b/apps/web/src/components/editor/timeline/index.tsx index f9a6cb8c..987215fa 100644 --- a/apps/web/src/components/editor/timeline/index.tsx +++ b/apps/web/src/components/editor/timeline/index.tsx @@ -878,7 +878,13 @@ export function Timeline() { {/* Timeline Ruler */}
{ + // Check if this is horizontal scrolling - if so, don't handle it here + if (e.shiftKey || Math.abs(e.deltaX) > Math.abs(e.deltaY)) { + return; // Let ScrollArea handle horizontal scrolling + } + handleWheel(e); + }} onMouseDown={handleSelectionMouseDown} onClick={handleTimelineContentClick} data-ruler-area @@ -999,7 +1005,13 @@ export function Timeline() { {/* Timeline Tracks Content */}
{ + // Check if this is horizontal scrolling - if so, don't handle it here + if (e.shiftKey || Math.abs(e.deltaX) > Math.abs(e.deltaY)) { + return; // Let ScrollArea handle horizontal scrolling + } + handleWheel(e); + }} onMouseDown={(e) => { handleTimelineMouseDown(e); handleSelectionMouseDown(e); @@ -1013,7 +1025,12 @@ export function Timeline() { containerRef={tracksContainerRef} isActive={selectionBox?.isActive || false} /> - +
, - React.ComponentPropsWithoutRef ->(({ className, children, ...props }, ref) => ( + React.ComponentPropsWithoutRef & { + type?: "auto" | "always" | "scroll" | "hover"; + showHorizontalScrollbar?: boolean; + } +>(({ className, children, type, showHorizontalScrollbar, ...props }, ref) => ( {children} + {showHorizontalScrollbar && } )); -- cgit v1.3.1