Only use Month and Year for photo date
This commit is contained in:
@@ -10,7 +10,6 @@
|
||||
import { throttle } from '$utils/functions'
|
||||
import { swipe } from '$utils/interactions/swipe'
|
||||
import dayjs from 'dayjs'
|
||||
import advancedFormat from 'dayjs/plugin/advancedFormat.js'
|
||||
import anime from 'animejs'
|
||||
import type { AnimeTimelineInstance } from 'animejs'
|
||||
// Components
|
||||
@@ -29,8 +28,6 @@
|
||||
export let limit: number
|
||||
export let offset: number
|
||||
|
||||
dayjs.extend(advancedFormat)
|
||||
|
||||
enum directions { PREV, NEXT }
|
||||
|
||||
let innerWidth: number
|
||||
@@ -377,7 +374,7 @@
|
||||
{/if}
|
||||
</span>
|
||||
</a>
|
||||
<span class="sep">·</span> <time datetime={dayjs(currentPhoto.date_taken).format('YYYY-MM-DD')}>{dayjs(currentPhoto.date_taken).format('MMMM, Do YYYY')}</time>
|
||||
<span class="sep">·</span> <time datetime={dayjs(currentPhoto.date_taken).format('YYYY-MM-DD')}>{dayjs(currentPhoto.date_taken).format('MMMM YYYY')}</time>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -5,7 +5,6 @@
|
||||
import anime from 'animejs'
|
||||
import type { AnimeTimelineInstance } from 'animejs'
|
||||
import dayjs from 'dayjs'
|
||||
import advancedFormat from 'dayjs/plugin/advancedFormat.js'
|
||||
import relativeTime from 'dayjs/plugin/relativeTime.js'
|
||||
import { getAssetUrlKey } from '$utils/helpers'
|
||||
import { DURATION } from '$utils/contants'
|
||||
@@ -22,7 +21,6 @@
|
||||
export let photos: any[]
|
||||
export let totalPhotos: number
|
||||
|
||||
dayjs.extend(advancedFormat)
|
||||
dayjs.extend(relativeTime)
|
||||
|
||||
const { params } = $page
|
||||
@@ -290,7 +288,7 @@
|
||||
<p class="info text-info">
|
||||
{#if city}<Icon class="icon" icon="map-pin" label="Map pin" /> {city} <span class="sep">·</span>{/if}
|
||||
<time datetime={dayjs(date_taken).format('YYYY-MM-DD')}>
|
||||
{dayjs(date_taken).format('MMMM, Do YYYY')}
|
||||
{dayjs(date_taken).format('MMMM YYYY')}
|
||||
</time>
|
||||
</p>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user