fix(notification): address review suggestions

- ChronikFuerDichBox: move update() inside the failure branch so success
  path skips it, matching NotificationDropdown's pattern
- NotificationDropdown test: add role=alert assertion for mark-all-read
  failure to match existing dismiss-failure coverage in ChronikFuerDichBox
- +page.server.ts: use getErrorMessage(undefined) instead of null so the
  missing-notificationId 400 goes through the same i18n pipeline as other errors

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Marcel
2026-05-20 07:31:26 +02:00
committed by marcel
parent 728f9cd1b0
commit 392097287c
3 changed files with 20 additions and 3 deletions

View File

@@ -81,8 +81,8 @@ function href(n: NotificationItem): string {
return async ({ result, update }) => {
if (result.type === 'failure' || result.type === 'error') {
errorMessage = m.notification_error_generic();
await update({ reset: false, invalidateAll: false });
}
await update({ reset: false, invalidateAll: false });
};
}}
>
@@ -129,8 +129,8 @@ function href(n: NotificationItem): string {
return async ({ result, update }) => {
if (result.type === 'failure' || result.type === 'error') {
errorMessage = m.notification_error_generic();
await update({ reset: false, invalidateAll: false });
}
await update({ reset: false, invalidateAll: false });
};
}}
>