diff --git a/package.json b/package.json
index 83c6c193..b0934faf 100644
--- a/package.json
+++ b/package.json
@@ -20,7 +20,7 @@
"linkify-it": "^5.0.0",
"marked": "^5.1.2",
"marked-linkify-it": "^3.1.10",
- "mono-svelte": "^1.6.26",
+ "mono-svelte": "latest",
"nprogress": "^0.2.0",
"postcss": "^8.4.30",
"rollup-plugin-visualizer": "^5.9.2",
diff --git a/src/lib/components/lemmy/post/Post.svelte b/src/lib/components/lemmy/post/Post.svelte
index 53bb1a54..27772d79 100644
--- a/src/lib/components/lemmy/post/Post.svelte
+++ b/src/lib/components/lemmy/post/Post.svelte
@@ -128,7 +128,7 @@
title={hideTitle ? undefined : tags?.title ? tags.title : post.post.name}
read={post.read}
style="grid-area: meta;"
- edited={post.post.updated != undefined}
+ edited={post.post.updated}
tags={tags?.tags}
{view}
>
diff --git a/src/lib/components/lemmy/post/PostActions.svelte b/src/lib/components/lemmy/post/PostActions.svelte
index 6f3f09ae..ab2007f8 100644
--- a/src/lib/components/lemmy/post/PostActions.svelte
+++ b/src/lib/components/lemmy/post/PostActions.svelte
@@ -3,6 +3,7 @@
import PostVote from './PostVote.svelte'
import { getInstance, site } from '$lib/lemmy.js'
import {
+ ArrowsUpDown,
ArrowTopRightOnSquare,
Bookmark,
BookmarkSlash,
@@ -11,6 +12,7 @@
ChatBubbleOvalLeft,
ChatBubbleOvalLeftEllipsis,
CheckBadge,
+ Clock,
EllipsisHorizontal,
Eye,
EyeSlash,
@@ -20,6 +22,7 @@
Language,
MapPin,
Newspaper,
+ Pencil,
PencilSquare,
ServerStack,
Share,
@@ -60,6 +63,9 @@
import { publishedToDate } from '$lib/components/util/date'
import TextProps from '$lib/components/ui/text/TextProps.svelte'
import { communityLink, userLink } from '$lib/lemmy/generic'
+ import RelativeDate, {
+ formatRelativeDate,
+ } from '$lib/components/util/RelativeDate.svelte'
export let post: PostView
export let view: View = 'cozy'
@@ -214,6 +220,53 @@
>
+ {$t('cards.site.stats')}
+
+
+
+
+ {publishedToDate(post.post.published).toLocaleDateString(undefined, {
+ dateStyle: 'short',
+ })}
+
+
+ {#if post.post.updated}
+ {@const editedTime = formatRelativeDate(
+ publishedToDate(post.post.updated),
+ {
+ style: 'long',
+ }
+ )}
+
+
+
+
+ {/if}
+
+ {#if post.counts.score}
+ {@const ratio =
+ post.counts.upvotes / (post.counts.upvotes + post.counts.downvotes)}
+
+
+ {$t('post.actions.vote.score')}
+ •
+
+ •
+
+
+ {/if}
{$t('post.actions.more.creator')}
-
-
- {$t('post.actions.more.actions')}
+
+ {$t('post.actions.more.actions')}
+
{#if $profile?.user && $profile?.jwt && $profile.user.local_user_view.person.id == post.creator.id}
(editing = true)}>
diff --git a/src/lib/components/lemmy/post/PostMeta.svelte b/src/lib/components/lemmy/post/PostMeta.svelte
index 557e4cbb..394dc676 100644
--- a/src/lib/components/lemmy/post/PostMeta.svelte
+++ b/src/lib/components/lemmy/post/PostMeta.svelte
@@ -43,7 +43,9 @@
import Avatar from '$lib/components/ui/Avatar.svelte'
import { Badge, Material, Popover } from 'mono-svelte'
import UserLink from '$lib/components/lemmy/user/UserLink.svelte'
- import RelativeDate from '$lib/components/util/RelativeDate.svelte'
+ import RelativeDate, {
+ formatRelativeDate,
+ } from '$lib/components/util/RelativeDate.svelte'
import type { Community, Person, SubscribedType } from 'lemmy-js-client'
import {
Bookmark,
@@ -65,6 +67,7 @@
import { t } from '$lib/translations'
import { Pencil, type IconSource } from 'svelte-hero-icons'
import CommunityHeader from '../community/CommunityHeader.svelte'
+ import { publishedToDate } from '$lib/components/util/date'
export let community: Community | undefined = undefined
export let showCommunity: boolean = true
@@ -75,7 +78,7 @@
export let title: string | undefined = undefined
export let id: number | undefined = undefined
export let read: boolean = false
- export let edited: boolean = false
+ export let edited: string | undefined = undefined
export let view: View = 'cozy'
@@ -167,7 +170,15 @@
{/if}
{#if edited}
-
+
+
+
{/if}
- new URL(url).hostname.split('.').slice(-2).join('.')
-{#if openMediaBias}
- {#await import('$lib/components/mbfc/MBFCModal.svelte') then { default: MbfcModal }}
-
- {/await}
-{/if}
-