@@ -36,6 +36,11 @@ import { useSetDocumentClass } from '../util/useSetDocumentClass'
3636import { useRundownAndShowStyleIdsForPlaylist } from '../util/useRundownAndShowStyleIdsForPlaylist'
3737import { RundownPlaylistClientUtil } from '../../lib/rundownPlaylistUtil'
3838import { CurrentPartOrSegmentRemaining } from '../RundownView/RundownTiming/CurrentPartOrSegmentRemaining'
39+ import {
40+ OverUnderClockComponent ,
41+ PlannedEndComponent ,
42+ TimeToPlannedEndComponent ,
43+ } from '../../lib/Components/CounterComponents'
3944
4045interface SegmentUi extends DBSegment {
4146 items : Array < PartUi >
@@ -345,7 +350,7 @@ function DirectorScreenRender({
345350 timingDurations . remainingBudgetOnCurrentSegment ?? timingDurations . remainingTimeOnCurrentPart ?? 0
346351
347352 const expectedStart = PlaylistTiming . getExpectedStart ( playlist . timing )
348- const expectedEnd = PlaylistTiming . getExpectedEnd ( playlist . timing )
353+ const expectedEnd = PlaylistTiming . getExpectedEnd ( playlist . timing ) || 0
349354 const expectedDuration = PlaylistTiming . getExpectedDuration ( playlist . timing )
350355
351356 const overUnderClock = getPlaylistTimingDiff ( playlist , timingDurations ) ?? 0
@@ -354,11 +359,15 @@ function DirectorScreenRender({
354359 < div className = "director-screen" >
355360 < div className = "director-screen__header" >
356361 < div className = "director-screen__header__planned-end" >
357- < div > { RundownUtils . formatTimeToTimecode ( { frameRate : 25 } , expectedEnd || 0 , true ) } </ div >
362+ < div >
363+ < PlannedEndComponent value = { expectedEnd } />
364+ </ div >
358365 PLANNED END
359366 </ div >
360367 < div className = "director-screen__header__planned-duration" >
361- < div > { RundownUtils . formatTimeToTimecode ( { frameRate : 25 } , expectedDuration || 0 , true ) } </ div >
368+ < div >
369+ < TimeToPlannedEndComponent value = { expectedEnd - overUnderClock } />
370+ </ div >
362371 TIME TO PLANNED END
363372 </ div >
364373 < div className = "director-screen__header__over-under" >
@@ -367,7 +376,7 @@ function DirectorScreenRender({
367376 over : Math . floor ( overUnderClock / 1000 ) >= 0 ,
368377 } ) }
369378 >
370- { RundownUtils . formatDiffToTimecode ( overUnderClock , true , false , true , true , true , undefined , true , true ) }
379+ < OverUnderClockComponent value = { overUnderClock } />
371380 </ div >
372381 OVER/UNDER
373382 </ div >
0 commit comments