Expose dynamic audio on the v2 schedule API
This commit is contained in:
@@ -149,6 +149,7 @@ export type V2ScheduleBlock = {
|
||||
endMinutes: number;
|
||||
overnight: boolean;
|
||||
durationMinutes: number;
|
||||
dynamicAudio: boolean;
|
||||
proclamationIds: string[];
|
||||
};
|
||||
|
||||
@@ -162,7 +163,12 @@ export type V2Schedule = {
|
||||
* marks a range that crosses midnight (end clock time before start), and
|
||||
* `durationMinutes` counts the wrap as the next day. */
|
||||
export function serializeScheduleBlock(
|
||||
block: { id: string; startMinutes: number; endMinutes: number },
|
||||
block: {
|
||||
id: string;
|
||||
startMinutes: number;
|
||||
endMinutes: number;
|
||||
dynamicAudio?: boolean;
|
||||
},
|
||||
proclamationIds: string[]
|
||||
): V2ScheduleBlock {
|
||||
return {
|
||||
@@ -173,6 +179,7 @@ export function serializeScheduleBlock(
|
||||
endMinutes: block.endMinutes,
|
||||
overnight: isOvernight(block),
|
||||
durationMinutes: blockDuration(block),
|
||||
dynamicAudio: block.dynamicAudio === true,
|
||||
proclamationIds
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user