Skip to content

Commit 15fffa6

Browse files
committed
🎨 Improve accessibility and handle undefine values (#2020)
1 parent 66081b7 commit 15fffa6

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

src/lib/components/Messages/ErrorMessageAndReturnButton.svelte

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,15 @@
1717
>
1818
<HeadingOne title="エラーが発生しました" />
1919

20-
<Heading tag="h2" class="text-3xl mb-3 text-gray-900 dark:text-gray-300">
21-
{errorStatus}
20+
<Heading
21+
tag="h2"
22+
class="text-3xl mb-3 text-gray-900 dark:text-gray-300"
23+
aria-label="error status"
24+
>
25+
{errorStatus ?? ''}
2226
</Heading>
2327

24-
<p class="dark:text-gray-300">{errorMessage}</p>
28+
<p class="dark:text-gray-300" aria-label="error messages">{errorMessage ?? ''}</p>
2529

2630
<div class="flex justify-center mt-6">
2731
<Button href={returnUrl} color="primary" class="px-6">

0 commit comments

Comments
 (0)