1
0
Fork 0
mirror of https://github.com/seanmorley15/AdventureLog.git synced 2025-07-20 21:39:37 +02:00

Add support for end date to adventure

This commit is contained in:
Sean Morley 2024-08-18 12:30:12 -04:00
parent 276ea42138
commit 03e0530e90
9 changed files with 66 additions and 5 deletions

View file

@ -221,7 +221,14 @@
{#if adventure.date && adventure.date !== ''}
<div class="inline-flex items-center">
<Calendar class="w-5 h-5 mr-1" />
<p>{new Date(adventure.date).toLocaleDateString(undefined, { timeZone: 'UTC' })}</p>
<p>
{new Date(adventure.date).toLocaleDateString(undefined, {
timeZone: 'UTC'
})}{adventure.end_date && adventure.end_date !== ''
? ' - ' +
new Date(adventure.end_date).toLocaleDateString(undefined, { timeZone: 'UTC' })
: ''}
</p>
</div>
{/if}
{#if adventure.activity_types && adventure.activity_types.length > 0}