design: update header button design

This commit is contained in:
James Xylight committed 2025-07-04 19:14:54 -07:00
1 parent 3706b31fda
commit a8e30203f1
7 files changed
+158 -193

No files matched your search

+1 -1
View File
@@ -37,7 +37,7 @@
{...rest}
{href}
class="{highlight
? 'text-blue-500'
? 'text-sky-500'
: ''} hover:underline max-w-full inline-flex items-center gap-1 {clazz}"
>
{@render icon?.()}
+12 -21
View File
@@ -46,17 +46,8 @@
/>
</div>
{/if}
<Entity name={site.site.name} label={new URL(site.site.actor_id).hostname}>
{#snippet customIcon()}
<Avatar
width={32}
url={site.site.icon}
alt={site.site.name}
circle={false}
/>
{/snippet}
</Entity>
<Avatar width={32} url={site.site.icon} alt="" circle={false} />
<h2 class="font-medium text-lg -my-2">{site.site.name}</h2>
<div class="flex flex-col gap-1">
{#if taglines && taglines.length > 0}
<Markdown
@@ -78,6 +69,15 @@
<Markdown source={site.site.description} />
<div class="my-4"></div>
<Markdown source={site.site.sidebar} />
{#if version}
<div class="w-max">
<Badge label="Lemmy version">
<Icon src={ServerStack} micro size="14" />
{version}
</Badge>
</div>
{/if}
</Expandable>
<hr class="border-slate-200 dark:border-zinc-900 my-1" />
@@ -132,7 +132,7 @@
</Expandable>
{/if}
<div class="flex flex-row flex-wrap gap-1">
<div class="flex flex-row flex-wrap gap-1 my-2 text-xs">
<Link highlight href="/modlog">
{$t('routes.modlog.title')}
</Link>
@@ -145,14 +145,5 @@
{$t('routes.instances')}
</Link>
</div>
{#if version}
<div class="w-max">
<Badge label="Lemmy version">
<Icon src={ServerStack} micro size="14" />
{version}
</Badge>
</div>
{/if}
</div>
</StickyCard>
@@ -126,14 +126,14 @@
<Button
disabled={subscribing}
loading={subscribing}
size="lg"
color={subscribed == 'NotSubscribed' ? 'primary' : 'secondary'}
onclick={async () => {
subscribed =
(await subscribe())?.community_view.subscribed ??
'NotSubscribed'
}}
class="relative px-8 z-[inherit]"
class="relative z-[inherit]"
rounding="pill"
>
{#snippet prefix()}
<Icon
@@ -154,21 +154,21 @@
.map(c => c.community.id)
.includes(community.id)}
<Button
size="square-lg"
color="secondary"
rounding="xl"
size="custom"
rounding="pill"
class="h-9 aspect-square"
href="/c/{fullCommunityName(
community.name,
community.actor_id,
)}/settings"
style="height: 38px; width: 38px;"
>
<Icon src={Cog6Tooth} size="16" mini />
</Button>
{/if}
<Menu placement="top-end">
{#snippet target()}
<Button rounding="xl" size="custom" style="height: 38px; width: 38px;">
<Button size="custom" rounding="pill" class="h-8.5 aspect-square">
{#snippet prefix()}
<Icon src={EllipsisHorizontal} size="16" mini />
{/snippet}