aboutsummaryrefslogtreecommitdiff
path: root/src/config.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/config.ts')
-rw-r--r--src/config.ts8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/config.ts b/src/config.ts
index d1d369e..5cd23e6 100644
--- a/src/config.ts
+++ b/src/config.ts
@@ -1,7 +1,7 @@
export interface Config {
warmup: number;
prepare : number;
- tabatas : number;
+ tabatas : string[];
cycles : number;
work : number;
rest : number;
@@ -9,8 +9,8 @@ export interface Config {
export function init(): Config {
return {
- warmup: 120,
- tabatas: 4,
+ warmup: 180,
+ tabatas: [],
prepare: 10,
cycles: 8,
work: 20,
@@ -19,5 +19,5 @@ export function init(): Config {
}
export function getDuration(c: Config): number {
- return c.warmup + c.tabatas * (c.prepare + (c.cycles * (c.work + c.rest)))
+ return c.warmup + c.tabatas.length * (c.prepare + (c.cycles * (c.work + c.rest)))
}