mirror of
https://github.com/immich-app/immich.git
synced 2026-05-18 03:10:24 +03:00
chore: tags styling (#27984)
This commit is contained in:
@@ -6,8 +6,7 @@
|
|||||||
import { getAssetActions } from '$lib/services/asset.service';
|
import { getAssetActions } from '$lib/services/asset.service';
|
||||||
import { removeTag } from '$lib/utils/asset-utils';
|
import { removeTag } from '$lib/utils/asset-utils';
|
||||||
import { getAssetInfo, type AssetResponseDto } from '@immich/sdk';
|
import { getAssetInfo, type AssetResponseDto } from '@immich/sdk';
|
||||||
import { Badge, IconButton, Link, Text } from '@immich/ui';
|
import { Badge, Link, Text } from '@immich/ui';
|
||||||
import { mdiClose } from '@mdi/js';
|
|
||||||
import { t } from 'svelte-i18n';
|
import { t } from 'svelte-i18n';
|
||||||
|
|
||||||
interface Props {
|
interface Props {
|
||||||
@@ -44,21 +43,15 @@
|
|||||||
</div>
|
</div>
|
||||||
<section class="flex flex-wrap pt-2 gap-1" data-testid="detail-panel-tags">
|
<section class="flex flex-wrap pt-2 gap-1" data-testid="detail-panel-tags">
|
||||||
{#each tags as tag (tag.id)}
|
{#each tags as tag (tag.id)}
|
||||||
<Badge size="small" class="items-center px-0" shape="round">
|
<Badge
|
||||||
<Link
|
onClose={() => handleRemove(tag.id)}
|
||||||
href={Route.tags({ path: tag.value })}
|
size="small"
|
||||||
class="text-light no-underline rounded-full hover:bg-primary-400 px-2"
|
shape="round"
|
||||||
>
|
translations={{ close: $t('remove_tag') }}
|
||||||
|
>
|
||||||
|
<Link href={Route.tags({ path: tag.value })} underline={false} class="px-2 font-light">
|
||||||
{tag.value}
|
{tag.value}
|
||||||
</Link>
|
</Link>
|
||||||
<IconButton
|
|
||||||
aria-label={$t('remove_tag')}
|
|
||||||
icon={mdiClose}
|
|
||||||
onclick={() => handleRemove(tag.id)}
|
|
||||||
size="tiny"
|
|
||||||
class="hover:bg-primary-400"
|
|
||||||
shape="round"
|
|
||||||
/>
|
|
||||||
</Badge>
|
</Badge>
|
||||||
{/each}
|
{/each}
|
||||||
<HeaderActionButton action={Tag} />
|
<HeaderActionButton action={Tag} />
|
||||||
|
|||||||
Reference in New Issue
Block a user