{#if notification.type === 'success'}
diff --git a/frontend/viewer/src/lib/notifications/notifications.ts b/frontend/viewer/src/lib/notifications/notifications.ts
index 671c93741..5fd18deed 100644
--- a/frontend/viewer/src/lib/notifications/notifications.ts
+++ b/frontend/viewer/src/lib/notifications/notifications.ts
@@ -1,4 +1,4 @@
-import {writable, type Writable, type Readable, readonly} from 'svelte/store';
+import {writable, type Writable} from 'svelte/store';
interface NotificationAction {
label: string;
@@ -11,7 +11,7 @@ export class AppNotification {
return this._notifications;
}
- public static display(message: string, type: 'success' | 'error' | 'info' | 'warning', timeout: 'short' | 'long' | number = 'short') {
+ public static display(message: string, type: 'success' | 'error' | 'info' | 'warning', timeout: 'short' | 'long' | number = 'short'): void {
const notification = new AppNotification(message, type);
this._notifications.update(notifications => [...notifications, notification]);
if (timeout === -1) return;
@@ -23,7 +23,7 @@ export class AppNotification {
}, timeout);
}
- public static displayAction(message: string, type: 'success' | 'error' | 'info' | 'warning', action: NotificationAction) {
+ public static displayAction(message: string, type: 'success' | 'error' | 'info' | 'warning', action: NotificationAction): void {
const notification = new AppNotification(message, type, action);
this._notifications.update(notifications => [...notifications, notification]);
}
diff --git a/frontend/viewer/src/lib/parts-of-speech.ts b/frontend/viewer/src/lib/parts-of-speech.ts
index c31e96bd2..69a20fc02 100644
--- a/frontend/viewer/src/lib/parts-of-speech.ts
+++ b/frontend/viewer/src/lib/parts-of-speech.ts
@@ -9,6 +9,9 @@ export function usePartsOfSpeech(): Readable
{
partsOfSpeechStore = writable([], (set) => {
useLexboxApi().GetPartsOfSpeech().then(partsOfSpeech => {
set(partsOfSpeech);
+ }).catch(error => {
+ console.error('Failed to load parts of speech', error);
+ throw error;
});
});
}
diff --git a/frontend/viewer/src/lib/search-bar/SearchBar.svelte b/frontend/viewer/src/lib/search-bar/SearchBar.svelte
index 2b57c4b28..ac2380288 100644
--- a/frontend/viewer/src/lib/search-bar/SearchBar.svelte
+++ b/frontend/viewer/src/lib/search-bar/SearchBar.svelte
@@ -1,6 +1,6 @@