Edited Time format logic

it was forcing using 'en' or 'id' time format
This commit is contained in:
Kim MinJae 2021-04-26 23:58:03 +09:00 committed by GitHub
parent 80d974cad9
commit a4ec0365f2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -46,15 +46,9 @@
<img src={originalResin.image} alt={originalResin.label} class="h-6 w-6 inline" /></td
>
<td class="pr-2 text-white text-center">
{#if $t('calculator.resin.timeFormat') === 'en'}
{dayjs(new Date(stepTime[i + 1]))
.locale('en')
.locale($t('calculator.resin.timeFormat'))
.fromNow()}
{:else}
{dayjs(new Date(stepTime[i + 1]))
.locale('id')
.fromNow()}
{/if}
</td>
</tr>
{/each}