mirror of
https://github.com/cpvalente/ontime.git
synced 2026-08-19 22:24:11 +00:00
refactor: add options to hide schedule
This commit is contained in:
committed by
Carlos Valente
parent
8bd7645c95
commit
7b932ef0f7
@@ -1,5 +1,4 @@
|
||||
import { MaybeNumber, OntimeEvent } from 'ontime-types';
|
||||
import { MILLIS_PER_MINUTE, MILLIS_PER_SECOND } from 'ontime-utils';
|
||||
import { OntimeEvent } from 'ontime-types';
|
||||
|
||||
/**
|
||||
* @description Returns trimmed event list array
|
||||
@@ -20,15 +19,3 @@ export function trimRundown(rundown: OntimeEvent[], selectedId: string | null, l
|
||||
const trimmedRundown = rundown.slice(startIndex, endIndex);
|
||||
return trimmedRundown;
|
||||
}
|
||||
|
||||
/**
|
||||
* @description Returns amount of seconds in a date given in milliseconds. For studio clock second indicator
|
||||
* @param {MaybeNumber} millis time to format
|
||||
* @returns amount of elapsed seconds
|
||||
*/
|
||||
export function secondsInMillis(millis: MaybeNumber): number {
|
||||
if (!millis) {
|
||||
return 0;
|
||||
}
|
||||
return Math.floor((millis % MILLIS_PER_MINUTE) / MILLIS_PER_SECOND);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user