@@ -26,7 +26,6 @@ import {
2626 STUDIO_MOTION_PANEL_ENABLED ,
2727} from "./components/editor/manualEditingAvailability" ;
2828import { getStudioMotionForSelection } from "./components/editor/studioMotion" ;
29- import { getTimelineElementKey , isTimelineElementActiveAtTime } from "./utils/timelineInspector" ;
3029import type { DomEditSelection } from "./components/editor/domEditing" ;
3130import { AskAgentModal } from "./components/AskAgentModal" ;
3231import { StudioHeader } from "./components/StudioHeader" ;
@@ -79,7 +78,6 @@ export function StudioApp() {
7978 const captionSync = useCaptionSync ( projectId ) ;
8079 const currentTime = usePlayerStore ( ( s ) => s . currentTime ) ;
8180 const timelineElements = usePlayerStore ( ( s ) => s . elements ) ;
82- const selectedTimelineElementId = usePlayerStore ( ( s ) => s . selectedElementId ) ;
8381 const setSelectedTimelineElementId = usePlayerStore ( ( s ) => s . setSelectedElementId ) ;
8482 const timelineDuration = usePlayerStore ( ( s ) => s . duration ) ;
8583 const isPlaying = usePlayerStore ( ( s ) => s . isPlaying ) ;
@@ -284,14 +282,6 @@ export function StudioApp() {
284282 domEditSession . domEditSelection ,
285283 )
286284 : null ;
287- const selectedTimelineElement = useMemo (
288- ( ) =>
289- selectedTimelineElementId
290- ? ( timelineElements . find ( ( el ) => getTimelineElementKey ( el ) === selectedTimelineElementId ) ??
291- null )
292- : null ,
293- [ selectedTimelineElementId , timelineElements ] ,
294- ) ;
295285 const designPanelActive =
296286 STUDIO_INSPECTOR_PANELS_ENABLED && panelLayout . rightPanelTab === "design" ;
297287 const motionPanelActive =
@@ -300,11 +290,7 @@ export function StudioApp() {
300290 panelLayout . rightPanelTab === "motion" ;
301291 const inspectorPanelActive = designPanelActive || motionPanelActive ;
302292 const shouldShowSelectedDomBounds =
303- inspectorPanelActive &&
304- ! panelLayout . rightCollapsed &&
305- ! isPlaying &&
306- ( ! selectedTimelineElement ||
307- isTimelineElementActiveAtTime ( currentTime , selectedTimelineElement ) ) ;
293+ inspectorPanelActive && ! panelLayout . rightCollapsed && ! isPlaying ;
308294 const inspectorButtonActive =
309295 STUDIO_INSPECTOR_PANELS_ENABLED && ! panelLayout . rightCollapsed && inspectorPanelActive ;
310296
0 commit comments