Files
sendewerk/src/lib/components/AppIcon.svelte
T
2026-10-23 21:33:15 +02:00

24 lines
471 B
Svelte

<script lang="ts">
let { name, label, size = '1em' }: { name: string; label?: string; size?: string } = $props();
</script>
<svg
width={size}
height={size}
role={label ? 'img' : undefined}
aria-label={label}
aria-hidden={label ? undefined : 'true'}
class="app-icon"
>
<use href={`/icons/classic-regular.svg#${name || 'circle'}`} />
</svg>
<style>
.app-icon {
display: inline-block;
flex: none;
fill: currentColor;
vertical-align: -0.125em;
}
</style>