From dc4db405d2991d3ec6a114f3b08d3fccd057d3ee Mon Sep 17 00:00:00 2001
From: Wolfgang Müller
Date: Thu, 13 Feb 2025 17:52:16 +0100
Subject: frontend: Migrate to Svelte 5

---
 frontend/src/lib/components/Select.svelte | 27 ++++++++++++++++++---------
 1 file changed, 18 insertions(+), 9 deletions(-)

(limited to 'frontend/src/lib/components/Select.svelte')

diff --git a/frontend/src/lib/components/Select.svelte b/frontend/src/lib/components/Select.svelte
index dece4a5..44828d3 100644
--- a/frontend/src/lib/components/Select.svelte
+++ b/frontend/src/lib/components/Select.svelte
@@ -2,19 +2,28 @@
 	import type { ListItem } from '$lib/Utils';
 	import Svelecte from 'svelecte';
 
-	let inputId: string;
-	let valueAsObject = false;
-	let multiple = false;
-
 	type Item = number | string | ListItem;
 	type Value = Item | Item[] | undefined | null;
 
-	export let clearable = false;
-	export let placeholder = 'Select...';
-	export let options: ListItem[] | undefined;
-	export let value: Value;
+	interface Props {
+		id: string;
+		object?: boolean;
+		multi?: boolean;
+		clearable?: boolean;
+		placeholder?: string;
+		options: ListItem[] | undefined;
+		value: Value;
+	}
 
-	export { inputId as id, valueAsObject as object, multiple as multi };
+	let {
+		id: inputId,
+		object: valueAsObject = false,
+		multi: multiple = false,
+		clearable = false,
+		placeholder = 'Select...',
+		options,
+		value = $bindable()
+	}: Props = $props();
 </script>
 
 {#if options !== null && options !== undefined}
-- 
cgit v1.2.3-2-gb3c3

