From 58c0247f6b8f0df055143b4735838df4380406bd Mon Sep 17 00:00:00 2001 From: Yiannis Christodoulou Date: Wed, 4 Jun 2025 15:02:51 +0300 Subject: [PATCH] fix deic issues: #61, #62, #63, #64, #65 - keep icons in popup menu but do not allow to click (rather than disapear) #61 - New item: When activating Play Preview #62 - dragable ball on mobile #63 - mobile: dragging the popup menu small issue #64 - mobile vertical direction #65 --- .../client/src/components/EditingTools.tsx | 22 ++- .../src/components/TimelineControls.tsx | 185 ++++++++++-------- .../client/src/styles/EditingTools.css | 99 ++++++++++ .../client/src/styles/TimelineControls.css | 12 +- .../client/src/styles/TwoRowTooltip.css | 20 ++ 5 files changed, 243 insertions(+), 95 deletions(-) diff --git a/frontend-tools/video-editor/client/src/components/EditingTools.tsx b/frontend-tools/video-editor/client/src/components/EditingTools.tsx index 1b8c0eb2..6f2978c6 100644 --- a/frontend-tools/video-editor/client/src/components/EditingTools.tsx +++ b/frontend-tools/video-editor/client/src/components/EditingTools.tsx @@ -1,4 +1,5 @@ import '../styles/EditingTools.css'; +import { useEffect, useState } from 'react'; interface EditingToolsProps { onSplit: () => void; @@ -29,6 +30,18 @@ const EditingTools = ({ isPlaying = false, isPlayingSegments = false, }: EditingToolsProps) => { + const [isSmallScreen, setIsSmallScreen] = useState(false); + + useEffect(() => { + const checkScreenSize = () => { + setIsSmallScreen(window.innerWidth <= 640); + }; + + checkScreenSize(); + window.addEventListener('resize', checkScreenSize); + return () => window.removeEventListener('resize', checkScreenSize); + }, []); + // Handle play button click with iOS fix const handlePlay = () => { // Ensure lastSeekedPosition is used when play is clicked @@ -47,7 +60,7 @@ const EditingTools = ({
{/* Play Segments button */} - )} + if (createdSegment) { + // Set this segment as selected to show its tooltip + setSelectedSegmentId(createdSegment.id); + logger.debug("Created and selected new segment:", createdSegment.id); + } + }, 100); // Small delay to ensure state is updated + }} + > + + + + + + + New + + {/* Go to start button - play from beginning of cutaway (until next segment) */}