fix(a11y): add aria-hidden to decorative SVG and use text-xs for WCAG 12px minimum

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Marcel
2026-04-20 00:24:36 +02:00
parent 80e10e1755
commit dc349947ef

View File

@@ -3,7 +3,7 @@ let { percentage }: { percentage: number } = $props();
</script>
<div class="flex flex-col items-center">
<svg width="36" height="36" viewBox="0 0 20 20">
<svg width="36" height="36" viewBox="0 0 20 20" aria-hidden="true">
<circle cx="10" cy="10" r="7" fill="none" stroke="var(--c-line)" stroke-width="2" />
<circle
class="fill-arc"
@@ -19,7 +19,7 @@ let { percentage }: { percentage: number } = $props();
/>
</svg>
<span
class="block text-center font-sans text-[10px] font-bold {percentage > 0 ? 'text-accent' : 'text-gray-400'}"
class="block text-center font-sans text-xs font-bold {percentage > 0 ? 'text-accent' : 'text-gray-400'}"
>
{percentage}%
</span>