AI Implementation feature(880): Authenticated Shell, Quick Tabs and Change Password 1.04 (#19)
This commit was merged in pull request #19.
This commit is contained in:
@@ -36,3 +36,14 @@ export function deriveCountdownText(
|
||||
}
|
||||
return secondsToEnd == null ? '00:00:00' : formatDdHhMm(secondsToEnd);
|
||||
}
|
||||
|
||||
export const LED_COLOR_BY_STATE: Readonly<Record<EventState, string>> = {
|
||||
running: 'var(--color-success)',
|
||||
countdown: 'var(--color-warning)',
|
||||
stopped: 'var(--color-danger)',
|
||||
unconfigured: 'var(--color-secondary)',
|
||||
};
|
||||
|
||||
export function ledBackgroundColor(state: EventState): string {
|
||||
return LED_COLOR_BY_STATE[state];
|
||||
}
|
||||
|
||||
@@ -4,9 +4,19 @@ import {
|
||||
EventSourceLike,
|
||||
EventState,
|
||||
EventStatePayload,
|
||||
LED_COLOR_BY_STATE,
|
||||
ledBackgroundColor,
|
||||
} from './event-status.pure';
|
||||
|
||||
export { EventState, EventStatePayload, EventSourceLike, deriveCountdownText, formatDdHhMm } from './event-status.pure';
|
||||
export {
|
||||
EventState,
|
||||
EventStatePayload,
|
||||
EventSourceLike,
|
||||
deriveCountdownText,
|
||||
formatDdHhMm,
|
||||
LED_COLOR_BY_STATE,
|
||||
ledBackgroundColor,
|
||||
} from './event-status.pure';
|
||||
|
||||
@Injectable({ providedIn: 'root' })
|
||||
export class EventStatusStore {
|
||||
|
||||
Reference in New Issue
Block a user