Do not show minutes if days is available
Also show seconds only when seconds is 0
This commit is contained in:
parent
1054fb965c
commit
f78935ead7
1 changed files with 2 additions and 2 deletions
|
@ -9,8 +9,8 @@
|
|||
<span class="total-time">
|
||||
<template v-if="time.days">{{ time.days }} <span>{{ time.days === 1 ? 'day' : 'days' }}</span></template>
|
||||
<template v-if="time.hours">{{ time.hours }} <span>hr</span></template>
|
||||
<template v-if="time.mins">{{ time.mins }} <span>mins</span></template>
|
||||
<template v-if="time.seconds && Object.keys(time).length === 1">{{ time.seconds }} <span>s</span></template>
|
||||
<template v-if="time.mins && !time.days">{{ time.mins }} <span>mins</span></template>
|
||||
<template v-if="time.seconds && Object.keys(time).length === 1 || time.seconds === 0">{{ time.seconds }} <span>s</span></template>
|
||||
</span>
|
||||
`,
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue