summaryrefslogtreecommitdiff
path: root/apps/web/src/components/editor/media-panel/views/text.tsx
diff options
context:
space:
mode:
authorMaze Winther <mazewinther@gmail.com>2025-07-15 16:55:04 +0200
committerMaze Winther <mazewinther@gmail.com>2025-07-15 16:55:04 +0200
commitdc0e4783fbacad5c7eb3cf0d1141b0166960f809 (patch)
treee4899efc4e2b9f2338c161891278bef3d4ddeb9f /apps/web/src/components/editor/media-panel/views/text.tsx
parentfdeddbe3edf761ad41a5cd6bf9e1fb7f18624453 (diff)
downloadopencut-dc0e4783fbacad5c7eb3cf0d1141b0166960f809.tar.gz
cleanup
Diffstat (limited to 'apps/web/src/components/editor/media-panel/views/text.tsx')
-rw-r--r--apps/web/src/components/editor/media-panel/views/text.tsx6
1 files changed, 4 insertions, 2 deletions
diff --git a/apps/web/src/components/editor/media-panel/views/text.tsx b/apps/web/src/components/editor/media-panel/views/text.tsx
index fad79343..6d0d310b 100644
--- a/apps/web/src/components/editor/media-panel/views/text.tsx
+++ b/apps/web/src/components/editor/media-panel/views/text.tsx
@@ -1,6 +1,6 @@
import { DraggableMediaItem } from "@/components/ui/draggable-item";
import { TIMELINE_CONSTANTS } from "@/constants/timeline-constants";
-import { addTextToTimeline } from "@/lib/timeline-utils";
+import { useTimelineStore } from "@/stores/timeline-store";
import { type TextElement } from "@/types/timeline";
let textData: TextElement = {
@@ -43,7 +43,9 @@ export function TextView() {
content: textData.content,
}}
aspectRatio={1}
- onAddToTimeline={(currentTime) => addTextToTimeline(textData, currentTime)}
+ onAddToTimeline={(currentTime) =>
+ useTimelineStore.getState().addTextAtTime(textData, currentTime)
+ }
showLabel={false}
/>
</div>