ui : give the discover chips a border colour and a shadow

The fact chips, the chat template chip, the copy chip and the Hugging
Face link drew a bare border with no colour and no shadow, while the
cards around them drew shadow-xs where the rest of the app draws
shadow-sm.

Assisted-by: pi:llama.cpp/DeepSeek-V4.1-Flash
This commit is contained in:
Aleksander Grygier
2026-09-28 12:10:13 +02:00
parent 3134109a8e
commit f24212e504
8 changed files with 12 additions and 10 deletions
@@ -39,7 +39,7 @@
<button
aria-label="Copy chat template"
class="inline-flex cursor-pointer items-center gap-1.5 rounded-md border px-2 py-1 text-xs font-medium transition-colors hover:bg-muted"
class="inline-flex cursor-pointer items-center gap-1.5 rounded-md border border-border/30 px-2 py-1 text-xs font-medium shadow-sm transition-colors hover:bg-muted dark:border-border/20"
onclick={() => void copy()}
type="button"
>
@@ -144,7 +144,7 @@
</script>
{#if bitDepthRows.length}
<section class="rounded-3xl border border-border/30 bg-muted/60 shadow-xs dark:border-border/20">
<section class="rounded-3xl border border-border/30 bg-muted/60 shadow-sm dark:border-border/20">
<!-- One chip per file, each an independent download action with its own
lifecycle state; nothing here selects anything. -->
<div class="flex w-full flex-col divide-y divide-border/50 px-4 pb-1 dark:divide-border/35">
@@ -96,7 +96,7 @@
<button
{...props}
aria-label={tooltipText}
class="group relative inline-flex h-auto cursor-pointer items-center gap-1 rounded-md! border px-2 py-1 text-left font-mono text-xs shadow-xs transition-[background-color,border-color,transform] duration-200 ease-[cubic-bezier(0.23,1,0.32,1)] active:scale-[0.97]
class="group relative inline-flex h-auto cursor-pointer items-center gap-1 rounded-md! border px-2 py-1 text-left font-mono text-xs shadow-sm transition-[background-color,border-color,transform] duration-200 ease-[cubic-bezier(0.23,1,0.32,1)] active:scale-[0.97]
border-green-600/25 bg-green-500/5 hover:border-destructive/50 hover:bg-destructive/10 dark:border-green-500/30 dark:bg-green-500/10 dark:hover:border-destructive/50 dark:hover:bg-destructive/15"
onclick={() => onRequestDelete?.(entry.repoWithTag)}
type="button"
@@ -185,7 +185,7 @@
<button
{...props}
aria-label={tooltipText}
class="group relative inline-flex h-auto cursor-pointer items-center gap-1 overflow-hidden rounded-md! border px-2 py-1 text-left font-mono text-xs shadow-xs transition-[background-color,border-color,transform] duration-200 ease-[cubic-bezier(0.23,1,0.32,1)] active:scale-[0.97]
class="group relative inline-flex h-auto cursor-pointer items-center gap-1 overflow-hidden rounded-md! border px-2 py-1 text-left font-mono text-xs shadow-sm transition-[background-color,border-color,transform] duration-200 ease-[cubic-bezier(0.23,1,0.32,1)] active:scale-[0.97]
border-border/30 bg-background hover:bg-muted-foreground/10 dark:border-border/20 dark:bg-muted-foreground/15 dark:text-secondary-foreground dark:hover:bg-muted-foreground/25
{entry.isFailed ? 'border-destructive!' : ''}"
onclick={() => void startDownload()}
@@ -222,7 +222,7 @@
inside the chip cancels (stops and discards the partial files). The X slot
is reserved, so the chip never reflows when the affordance fades in -->
<div
class="group relative inline-flex h-auto items-center gap-1 overflow-hidden rounded-md! border px-2 py-1 text-left font-mono text-xs shadow-xs transition-[background-color,border-color,transform] duration-200 ease-[cubic-bezier(0.23,1,0.32,1)] active:scale-[0.97]
class="group relative inline-flex h-auto items-center gap-1 overflow-hidden rounded-md! border px-2 py-1 text-left font-mono text-xs shadow-sm transition-[background-color,border-color,transform] duration-200 ease-[cubic-bezier(0.23,1,0.32,1)] active:scale-[0.97]
{entry.isPaused
? 'border-yellow-600/40 bg-yellow-500/10 hover:bg-yellow-500/20 dark:border-yellow-500/30 dark:bg-yellow-500/10'
: 'border-border/30 bg-background hover:bg-muted-foreground/10 dark:border-border/20 dark:bg-muted-foreground/15'}"
@@ -75,7 +75,7 @@
</div>
<a
class="inline-flex shrink-0 items-center gap-1.5 rounded-md border px-2.5 py-1.5 text-xs font-medium transition-colors hover:bg-muted"
class="inline-flex shrink-0 items-center gap-1.5 rounded-md border border-border/30 px-2.5 py-1.5 text-xs font-medium shadow-sm transition-colors hover:bg-muted dark:border-border/20"
href={HuggingFaceService.getModelUrl(modelId)}
rel="noopener noreferrer"
target="_blank"
@@ -50,7 +50,7 @@
{#if gguf?.chat_template}
<button
class="inline-flex items-center gap-1.5 rounded-md border px-2.5 py-1 text-xs font-medium transition-colors hover:bg-muted"
class="inline-flex items-center gap-1.5 rounded-md border border-border/30 px-2.5 py-1 text-xs font-medium shadow-sm transition-colors hover:bg-muted dark:border-border/20"
onclick={() => (chatTemplateOpen = true)}
type="button"
>
@@ -8,7 +8,9 @@
</script>
<!-- Metadata chip: label | value pair, matching the HF model page style -->
<span class="inline-flex items-center divide-x divide-border rounded-md border text-xs">
<span
class="inline-flex items-center divide-x divide-border rounded-md border border-border/30 text-xs shadow-sm dark:border-border/20"
>
<span class="px-2.5 py-1 text-muted-foreground">{label}</span>
<span class="px-2.5 py-1 font-medium">{value}</span>
@@ -10,7 +10,7 @@
{#if readme}
<section
class="p-3 rounded-3xl border border-border/30 bg-muted/60 shadow-xs dark:border-border/20"
class="p-3 rounded-3xl border border-border/30 bg-muted/60 shadow-sm dark:border-border/20"
>
<MarkdownContent allowHtml class="prose-sm max-w-none" content={readme} />
</section>
@@ -45,7 +45,7 @@
<!-- Download options: quant rows, CTA, terminal command -->
<div
class="rounded-3xl border border-border/30 bg-muted/40 p-4 shadow-xs dark:border-border/20 dark:bg-muted/50"
class="rounded-3xl border border-border/30 bg-muted/40 p-4 shadow-sm dark:border-border/20 dark:bg-muted/50"
>
<div class="space-y-3 divide-y divide-border/50 dark:divide-border/35 pb-1">
{#each [0, 1, 2] as _, index (index)}