From a650238d96af7f84be9b19fd995d9765c4895c99 Mon Sep 17 00:00:00 2001
From: Wolfgang Müller
Date: Wed, 26 Feb 2025 16:23:47 +0100
Subject: frontend: Simplify Pill handling

Where before we handled the styling of pills (such as their icons and
colours) in multiple different places, instead centralize all of this in
the base Pill component.
---
 frontend/src/lib/tabs/ComicDetails.svelte | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

(limited to 'frontend/src/lib/tabs/ComicDetails.svelte')

diff --git a/frontend/src/lib/tabs/ComicDetails.svelte b/frontend/src/lib/tabs/ComicDetails.svelte
index 89eb053..9992c82 100644
--- a/frontend/src/lib/tabs/ComicDetails.svelte
+++ b/frontend/src/lib/tabs/ComicDetails.svelte
@@ -3,7 +3,7 @@
 	import { CategoryLabel, CensorshipLabel, LanguageLabel, RatingLabel } from '$lib/Enums';
 	import { href } from '$lib/Navigation';
 	import { formatListSize, joinText } from '$lib/Utils';
-	import AssociationPill from '$lib/pills/AssociationPill.svelte';
+	import Pill from '$lib/pills/Pill.svelte';
 	import TagPill from '$lib/pills/TagPill.svelte';
 	import { formatDistance, formatISO9075 } from 'date-fns';
 	import Header from './DetailsHeader.svelte';
@@ -87,7 +87,7 @@
 		<Section title="Artists">
 			{#each comic.artists as { id, name } (id)}
 				<a href={filterFor('artists', id)}>
-					<AssociationPill {name} type="artist" />
+					<Pill {name} style="artist" />
 				</a>
 			{/each}
 		</Section>
@@ -96,7 +96,7 @@
 		<Section title="Circles">
 			{#each comic.circles as { id, name } (id)}
 				<a href={filterFor('circles', id)}>
-					<AssociationPill {name} type="circle" />
+					<Pill {name} style="circle" />
 				</a>
 			{/each}
 		</Section>
@@ -105,7 +105,7 @@
 		<Section title="Characters">
 			{#each comic.characters as { id, name } (id)}
 				<a href={filterFor('characters', id)}>
-					<AssociationPill {name} type="character" />
+					<Pill {name} style="character" />
 				</a>
 			{/each}
 		</Section>
@@ -114,7 +114,7 @@
 		<Section title="Worlds">
 			{#each comic.worlds as { id, name } (id)}
 				<a href={filterFor('worlds', id)}>
-					<AssociationPill {name} type="world" />
+					<Pill {name} style="world" />
 				</a>
 			{/each}
 		</Section>
-- 
cgit v1.2.3-2-gb3c3

