From b266678fe4bb8c4053688fd037693fa2f930ac14 Mon Sep 17 00:00:00 2001 From: gantiro Date: Tue, 15 Jul 2025 22:51:38 +0700 Subject: Optimize timeline performance --- apps/web/src/types/timeline.ts | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'apps/web/src/types') diff --git a/apps/web/src/types/timeline.ts b/apps/web/src/types/timeline.ts index 17dbb5d1..146205c4 100644 --- a/apps/web/src/types/timeline.ts +++ b/apps/web/src/types/timeline.ts @@ -1,5 +1,6 @@ import { MediaType } from "@/stores/media-store"; import { generateUUID } from "@/lib/utils"; +import { ReactNode } from "react"; export type TrackType = "media" | "text" | "audio"; @@ -155,3 +156,22 @@ export function validateElementTrackCompatibility( return { isValid: true }; } + +export interface TimelineTick { + left: number; + label?: string; + isMajor?: boolean; +} + +export interface TimelineCanvasRulerWrapperProps { + children: ReactNode; + onMouseDown?: (e: React.MouseEvent) => void; + className?: string; +} + +export interface TimelineCanvasRulerProps { + zoomLevel: number; + duration: number; + width: number; + height?: number; +} -- cgit v1.3.1