diff --git a/src/lib/components/lemmy/post/Post.svelte b/src/lib/components/lemmy/post/Post.svelte index a22224c2..337a513c 100644 --- a/src/lib/components/lemmy/post/Post.svelte +++ b/src/lib/components/lemmy/post/Post.svelte @@ -1,20 +1,20 @@ - {#if post.post.embed_title != post.post.name || view == 'compact'} + > + + + {#if post.post.embed_title != post.post.name || view == "compact"} - {#if post.post.body && !post.post.nsfw && view != 'compact'} + {#if post.post.body && !post.post.nsfw && view != "compact"} {/if} @@ -89,8 +91,8 @@ bind:post on:edit={(e) => { toast({ - content: 'The post was edited successfully.', - type: 'success', + content: "The post was edited successfully.", + type: "success", }) }} /> diff --git a/src/lib/components/lemmy/post/PostFeed.svelte b/src/lib/components/lemmy/post/PostFeed.svelte index 1e868f46..2942e6e2 100644 --- a/src/lib/components/lemmy/post/PostFeed.svelte +++ b/src/lib/components/lemmy/post/PostFeed.svelte @@ -1,14 +1,61 @@ {:else} - {#each posts as post, index} + {#each combinedPosts as post, index} {#if !($userSettings.hidePosts.deleted && post.post.deleted) && !($userSettings.hidePosts.removed && post.post.removed)} - + + { + if (viewPost == post.post.id) viewPost = -1 + else viewPost = post.post.id + }} + > + {#if post.withCrossposts} + + {#if viewPost == post.post.id} + + {:else} + + {/if} + {post.crossposts.length} crosspost{post.crossposts.length == 1 + ? "" + : "s"} + + {/if} + + + {#if post.withCrossposts && viewPost == post.post.id} + + + Crossposts + {post.crossposts.length} + + {#each post.crossposts as crosspost, index} + + + + {/each} + + {/if} {/if} {/each} diff --git a/src/lib/components/lemmy/post/PostMeta.svelte b/src/lib/components/lemmy/post/PostMeta.svelte index e5fc3091..8fffeb32 100644 --- a/src/lib/components/lemmy/post/PostMeta.svelte +++ b/src/lib/components/lemmy/post/PostMeta.svelte @@ -1,10 +1,10 @@