diff --git a/src/lib/components/lemmy/community/CommunityCard.svelte b/src/lib/components/lemmy/community/CommunityCard.svelte index 0cd8e429..26aaaed1 100644 --- a/src/lib/components/lemmy/community/CommunityCard.svelte +++ b/src/lib/components/lemmy/community/CommunityCard.svelte @@ -106,6 +106,8 @@ Plus, } from 'svelte-hero-icons' import ItemList from '../generic/ItemList.svelte' + import CommonList from '$lib/components/ui/layout/CommonList.svelte' + import SidebarButton from '$lib/components/ui/sidebar/SidebarButton.svelte' let loading = $state({ blocking: false, @@ -209,19 +211,44 @@
{#snippet title()} - + {$t('cards.community.moderators')} {/snippet} - ({ - id: m.moderator.id, - name: m.moderator.name, - url: userLink(m.moderator), - avatar: m.moderator.avatar, - instance: new URL(m.moderator.actor_id).hostname, - }))} - /> + + {#snippet item(moderator)} + + {#snippet customIcon()} + + {/snippet} + {#snippet label()} +
+ + {moderator.moderator.display_name ?? + moderator.moderator.name} + + + {new URL(moderator.moderator.actor_id).hostname} + +
+ {/snippet} +
+ {/snippet} +
{/if} diff --git a/src/lib/components/ui/layout/Shell.svelte b/src/lib/components/ui/layout/Shell.svelte index d988666a..390b3256 100644 --- a/src/lib/components/ui/layout/Shell.svelte +++ b/src/lib/components/ui/layout/Shell.svelte @@ -59,7 +59,7 @@ style: 'grid-area: sidebar; width: 100% !important;', })} {@render main?.({ - class: `w-full bg-slate-50 dark:bg-zinc-925 justify-self-center border-x border-slate-200 dark:border-zinc-900 max-lg:pb-22`, + class: `w-full bg-slate-50 dark:bg-zinc-925 justify-self-center border-x border-slate-200 dark:border-zinc-900 max-lg:pb-22 pb-3 sm:pb-6`, style: 'grid-area: main', })} {@render suffix?.({ diff --git a/src/lib/components/ui/sidebar/Sidebar.svelte b/src/lib/components/ui/sidebar/Sidebar.svelte index 5fc97db1..7e8d1b75 100644 --- a/src/lib/components/ui/sidebar/Sidebar.svelte +++ b/src/lib/components/ui/sidebar/Sidebar.svelte @@ -117,11 +117,12 @@ {#snippet item(prof, index)} {/snippet} +
  • + + {$t('account.accounts')} + +
  • -
    - - {$t('account.accounts')} - {/if}
    @@ -143,9 +144,37 @@ {/snippet} - i.community)} - /> + + {#snippet item(moderate)} + + {#snippet customIcon()} + {/snippet} + {#snippet label()} +
    + {moderate.community.title} + + {new URL(moderate.community.actor_id).hostname} + +
    + {/snippet} +
    + {/snippet} +

    {/if} diff --git a/src/routes/communities/+page.svelte b/src/routes/communities/+page.svelte index 09a2d145..e283b100 100644 --- a/src/routes/communities/+page.svelte +++ b/src/routes/communities/+page.svelte @@ -22,6 +22,7 @@ } from 'svelte-hero-icons' import { expoOut } from 'svelte/easing' import { fly } from 'svelte/transition' + import SearchBar from '../search/SearchBar.svelte' let { data } = $props() @@ -51,34 +52,8 @@
    -
    - -
    - - -
    -
    -
    + +
    -
    +
    -

    +
    {#await data.comments.value then comments} {#if data.thread.value.showContext || data.thread.value.singleThread}
    {/if} {/await} -
    +
    diff --git a/src/routes/search/SearchBar.svelte b/src/routes/search/SearchBar.svelte index 92f0d68f..2f1b1c6d 100644 --- a/src/routes/search/SearchBar.svelte +++ b/src/routes/search/SearchBar.svelte @@ -14,30 +14,28 @@ let searchElement = $state() -
    - -
    - - -
    -
    +
    +
    + + +
    diff --git a/src/routes/settings/+page.svelte b/src/routes/settings/+page.svelte index 94f7a1a7..ca5582e7 100644 --- a/src/routes/settings/+page.svelte +++ b/src/routes/settings/+page.svelte @@ -70,6 +70,7 @@ import Section from './Section.svelte' import Setting from './Setting.svelte' import ToggleSetting from './ToggleSetting.svelte' + import Expandable from '$lib/components/ui/Expandable.svelte' let importing = $state(false) let importText = $state('') @@ -182,50 +183,10 @@ {/snippet}
    -
    - - - - - -
    -
    - {#if profile.current?.jwt} -
    -
    - -
    -
    - {/if}
    {#if env.PUBLIC_XYLIGHT_MODE} @@ -606,7 +567,7 @@
    - + {#snippet title()} {$t('settings.moderation.replyPresets.title')} {/snippet} @@ -630,76 +591,70 @@ {/snippet} - {#each settings.moderation.presets as preset, index (preset)} - -
    - - - {preset.title} - - -
    - - - removalTemplate(input, { - postTitle: '', - communityLink: '[!community@example.com]()', - reason: '', - username: '@Bob', - })} - /> -
    -
    -
    - {/each} - - -
    + {#each settings.moderation.presets as preset, index (preset)} +
  • + + {#snippet title()} + {preset.title} + {/snippet} +
    + + + removalTemplate(input, { + postTitle: '', + communityLink: '[!community@example.com]()', + reason: '', + username: '@Bob', + })} + /> + + +
    +
    +
  • + {/each} +
  • + +
  • diff --git a/src/routes/settings/Setting.svelte b/src/routes/settings/Setting.svelte index 11c34932..23d7ef6c 100644 --- a/src/routes/settings/Setting.svelte +++ b/src/routes/settings/Setting.svelte @@ -22,6 +22,7 @@ description?: import('svelte').Snippet children?: import('svelte').Snippet icon?: IconSource + adaptive?: boolean } let { @@ -37,6 +38,7 @@ description, children, icon, + adaptive = true, }: Props = $props() @@ -74,7 +76,7 @@ {/if}
    {/if} -
    +
    {#if icon}