fix: unnecessary margins in inbox page
This commit is contained in:
1 parent
0d0681b687
commit
22e6f50e52
2 files changed
+30
-30
No files matched your search
@@ -74,35 +74,11 @@
|
||||
<title>{$t('routes.inbox.title')}</title>
|
||||
</svelte:head>
|
||||
|
||||
<div class="flex flex-row gap-2">
|
||||
<Header pageHeader class="sm:flex-row justify-between flex-col">
|
||||
{$t('routes.inbox.title')}
|
||||
|
||||
<div class="flex items-center gap-2">
|
||||
<Button
|
||||
on:click={() => goto($page.url, { invalidateAll: true })}
|
||||
size="square-lg"
|
||||
rounding="xl"
|
||||
title={$t('common.refresh')}
|
||||
>
|
||||
<Icon src={ArrowPath} size="16" mini slot="prefix" />
|
||||
</Button>
|
||||
<Button
|
||||
on:click={markAllAsRead}
|
||||
loading={markingAsRead}
|
||||
disabled={markingAsRead}
|
||||
size="lg"
|
||||
class="h-10"
|
||||
>
|
||||
<Icon src={Check} width={16} mini slot="prefix" />
|
||||
{$t('routes.inbox.markAsRead')}
|
||||
</Button>
|
||||
</div>
|
||||
<div class=" gap-2">
|
||||
<div
|
||||
class="mt-4 mb-0 sticky z-30 mx-auto max-w-full flex gap-2 md:flex-row flex-col
|
||||
items-center px-2 w-max"
|
||||
items-center px-2 w-max"
|
||||
style="top: max(1.5rem, {$contentPadding.top}px);"
|
||||
slot="extended"
|
||||
>
|
||||
<Tabs
|
||||
routes={[
|
||||
@@ -155,12 +131,34 @@
|
||||
defaultRoute="?unreadOnly=true"
|
||||
/>
|
||||
</div>
|
||||
<Header pageHeader class="sm:flex-row justify-between flex-col">
|
||||
{$t('routes.inbox.title')}
|
||||
|
||||
<div class="flex items-center gap-2">
|
||||
<Button
|
||||
on:click={() => goto($page.url, { invalidateAll: true })}
|
||||
size="square-lg"
|
||||
rounding="xl"
|
||||
title={$t('common.refresh')}
|
||||
>
|
||||
<Icon src={ArrowPath} size="16" mini slot="prefix" />
|
||||
</Button>
|
||||
<Button
|
||||
on:click={markAllAsRead}
|
||||
loading={markingAsRead}
|
||||
disabled={markingAsRead}
|
||||
size="lg"
|
||||
class="h-10"
|
||||
>
|
||||
<Icon src={Check} width={16} mini slot="prefix" />
|
||||
{$t('routes.inbox.markAsRead')}
|
||||
</Button>
|
||||
</div>
|
||||
</Header>
|
||||
</div>
|
||||
<div class="mt-4" />
|
||||
|
||||
<div
|
||||
class="flex flex-col list-none flex-1 h-full mt-4 divide-y divide-slate-200 dark:divide-zinc-900 *:py-4"
|
||||
class="flex flex-col list-none flex-1 h-full divide-y divide-slate-200 dark:divide-zinc-900 *:py-4"
|
||||
>
|
||||
{#if !data.data || (data.data?.length ?? 0) == 0}
|
||||
<Placeholder
|
||||
|
||||
@@ -152,7 +152,7 @@
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
<div slot="extended" class="flex gap-2 w-full md:hidden">
|
||||
<div slot="extended" class="flex gap-2 w-full md:hidden mt-1">
|
||||
<Button
|
||||
color={item.read ? 'secondary' : 'primary'}
|
||||
{loading}
|
||||
@@ -165,7 +165,9 @@
|
||||
rounding="pill"
|
||||
>
|
||||
<Icon src={item.read ? EyeSlash : Eye} size="16" micro slot="prefix" />
|
||||
{$t('routes.inbox.item.markRead')}
|
||||
{item.read
|
||||
? $t('post.actions.more.markUnread')
|
||||
: $t('post.actions.more.markRead')}
|
||||
</Button>
|
||||
{#if item.type == 'comment_reply' || item.type == 'person_mention'}
|
||||
<Button href="/comment/{item.item.comment.id}" size="sm" rounding="pill">
|
||||
|
||||
Reference in new issue
Block a user