Make option select component select placeholder option whenever the value is nullish
This commit is contained in:
parent
3778589d0f
commit
82baab3d9d
|
@ -98,7 +98,7 @@
|
|||
$: isOptionsObject = options.every(o => typeof o === "object")
|
||||
|
||||
$: selectedOption = isOptionsObject
|
||||
? options.find(o => o.value === value)
|
||||
? options.find(o => o.value === value || (o.value === "" && value == null))
|
||||
: {}
|
||||
|
||||
$: if (open && selectMenu) {
|
||||
|
|
Loading…
Reference in New Issue