Skip to content

Commit 5351fb6

Browse files
authored
Fix value checking of Picker (#778)
1 parent a052794 commit 5351fb6

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

packages/core/src/components/Picker/PickerInputContainer.tsx

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,14 +53,15 @@ const PickerInputContainer: React.FC<
5353
selectedLabel = selectedValue
5454
.map(
5555
(value) =>
56-
options.find((option) => option.value === value)?.label.toString() ||
57-
value
56+
options
57+
.find((option) => option.value.toString() === value.toString())
58+
?.label.toString() || value
5859
)
5960
.join(", ");
6061
} else {
6162
selectedLabel =
6263
options
63-
.find((option) => option.value === selectedValue)
64+
.find((option) => option.value.toString() === selectedValue?.toString())
6465
?.label.toString() || selectedValue;
6566
}
6667

0 commit comments

Comments
 (0)