Fix error

This commit is contained in:
Adria Navarro 2023-10-03 13:12:50 +02:00
parent 0702bc6c33
commit f7e92992a8
1 changed files with 3 additions and 1 deletions

View File

@ -27,10 +27,12 @@
value = Array.isArray(val) ? val : [val] value = Array.isArray(val) ? val : [val]
} }
} }
$: selectedValue = multiple || !value ? value : value[0]
</script> </script>
<Select <Select
value={multiple ? value : value[0]} value={selectedValue}
autocomplete autocomplete
on:change={onChange} on:change={onChange}
{options} {options}