diff --git a/src/lib/components/lemmy/comment/CommentItem.svelte b/src/lib/components/lemmy/comment/CommentItem.svelte index 9850dcf2..5c62448f 100644 --- a/src/lib/components/lemmy/comment/CommentItem.svelte +++ b/src/lib/components/lemmy/comment/CommentItem.svelte @@ -29,7 +29,7 @@ diff --git a/src/lib/components/lemmy/community/CommunityItem.svelte b/src/lib/components/lemmy/community/CommunityItem.svelte index c1fd1456..2e9acd8c 100644 --- a/src/lib/components/lemmy/community/CommunityItem.svelte +++ b/src/lib/components/lemmy/community/CommunityItem.svelte @@ -37,7 +37,7 @@ community = $bindable(), view = 'compact', showCounts = true, - class: clazz = 'py-4 flex flex-col gap-4 text-sm max-w-full relative', + class: clazz = 'flex flex-col gap-4 text-sm max-w-full relative', icon, children, }: Props = $props() @@ -51,10 +51,10 @@
{#if icon}{@render icon()}{:else if community.community.nsfw && settings.nsfwBlur} -
+
{:else} {#snippet children({ subscribe, subscribing })} + {@const subscribed = isSubscribed(community.subscribed)}
{:else}
    {#if data.communities.value.length == 0} - + - {#each sliced as community, index (community.community.id)} -
    - -
    - {/each} -
+ + {#snippet item(community, index)} + + {/snippet} + {/if} {/if} diff --git a/src/routes/inbox/+page.svelte b/src/routes/inbox/+page.svelte index 241e35ec..ea3f1892 100644 --- a/src/routes/inbox/+page.svelte +++ b/src/routes/inbox/+page.svelte @@ -2,6 +2,7 @@ import { goto } from '$app/navigation' import { page } from '$app/state' import { notifications, profile } from '$lib/auth.svelte.js' + import CommonList from '$lib/components/ui/layout/CommonList.svelte' import Header from '$lib/components/ui/layout/pages/Header.svelte' import Tabs from '$lib/components/ui/layout/pages/Tabs.svelte' import Pageination from '$lib/components/ui/Pageination.svelte' @@ -10,8 +11,6 @@ import { getClient } from '$lib/lemmy.svelte.js' import { Button } from 'mono-svelte' import { ArrowPath, Check, Icon, Inbox } from 'svelte-hero-icons' - import { expoOut } from 'svelte/easing' - import { fly } from 'svelte/transition' import InboxItem from './InboxItem.svelte' let { data } = $props() @@ -63,129 +62,113 @@ {$t('routes.inbox.title')} -
-
- - href.includes('?') - ? '?' + addSearchParam(page.url.searchParams, href).toString() - : `${href}${page.url.search}`} - defaultRoute="?type=all" - class="overflow-auto" - /> - - '?' + addSearchParam(page.url.searchParams, href).toString()} - defaultRoute="?unreadOnly=true" - class="overflow-auto" - /> -
-
- {$t('routes.inbox.title')} - -
- - -
-
-
-
- {#if !data.inbox?.value || (data.inbox.value?.length ?? 0) == 0} - - {:else} - {#each data.inbox.value as item, index} - {#if item.creator.id != profile.current.user?.local_user_view.person.id} -
- -
- {/if} - {/each} - {/if} - {#if !(data.page == 1 && (data?.inbox?.value.length ?? 0) == 0)} -
- - `?page=${page}`} - /> - -
- {/if} + + href.includes('?') + ? '?' + addSearchParam(page.url.searchParams, href).toString() + : `${href}${page.url.search}`} + defaultRoute="?type=all" + class="overflow-auto" + /> + + '?' + addSearchParam(page.url.searchParams, href).toString()} + defaultRoute="?unreadOnly=true" + class="overflow-auto" + />
+
+ {$t('routes.inbox.title')} + +
+ + +
+
+ +
+ +{#if !data.inbox?.value || (data.inbox.value?.length ?? 0) == 0} + +{:else} + + {#snippet item(item)} + + {/snippet} + +{/if} +{#if !(data.page == 1 && (data?.inbox?.value.length ?? 0) == 0)} +
+ + `?page=${page}`} + /> + +
+{/if} diff --git a/src/routes/inbox/InboxItem.svelte b/src/routes/inbox/InboxItem.svelte index 02e2ca7d..54906864 100644 --- a/src/routes/inbox/InboxItem.svelte +++ b/src/routes/inbox/InboxItem.svelte @@ -65,12 +65,7 @@ {#snippet title()}
- +
{#if item.type == 'comment_reply'} diff --git a/src/routes/moderation/+page.svelte b/src/routes/moderation/+page.svelte index 1e679808..63acd254 100644 --- a/src/routes/moderation/+page.svelte +++ b/src/routes/moderation/+page.svelte @@ -1,7 +1,10 @@