From ee44a5f6fb493effe44b3d9c69a1a580f78b32a7 Mon Sep 17 00:00:00 2001 From: ct Date: Tue, 15 Jul 2025 00:50:10 +0800 Subject: [PATCH] Update --- .../js/modules/editor/partials/editor-controls.jsx | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/resources/js/modules/editor/partials/editor-controls.jsx b/resources/js/modules/editor/partials/editor-controls.jsx index c19cabd..12f74de 100644 --- a/resources/js/modules/editor/partials/editor-controls.jsx +++ b/resources/js/modules/editor/partials/editor-controls.jsx @@ -4,10 +4,12 @@ import { Button } from '@/components/ui/button'; import { cn } from '@/lib/utils'; import { useMitt } from '@/plugins/MittContext'; import useVideoEditorStore from '@/stores/VideoEditorStore'; -import { Download, Play, Square, SquarePen } from 'lucide-react'; +import useMediaStore from '@/stores/MediaStore'; +import { Download, Play, Square, SquarePen, RefreshCw } from 'lucide-react'; const EditorControls = ({ className = '', onEditClick = () => {}, isEditActive = false }) => { const { videoIsPlaying } = useVideoEditorStore(); + const { init } = useMediaStore(); const emitter = useMitt(); const handlePlay = () => { @@ -26,6 +28,11 @@ const EditorControls = ({ className = '', onEditClick = () => {}, isEditActive = emitter.emit('open-ai-editor-sheet'); }; + const handleRefresh = () => { + handleReset(); + init(); + }; + const togglePlayPause = () => { if (videoIsPlaying) { handleReset(); @@ -58,6 +65,10 @@ const EditorControls = ({ className = '', onEditClick = () => {}, isEditActive = + +