Skip to content

Commit

Permalink
Merge pull request #67 from bleu-fi/select-search-issue
Browse files Browse the repository at this point in the history
fix select search
  • Loading branch information
luizakp authored Apr 26, 2024
2 parents 9696db8 + ff9a5c4 commit 179b7ba
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export const SearchableSelectField = withConditional<SelectFieldProps>(
)}
>
{formField.value
? field.options.find(
? field.options?.find(
(option) => option.value === formField.value
)?.label
: "Select an option"}
Expand All @@ -61,7 +61,7 @@ export const SearchableSelectField = withConditional<SelectFieldProps>(
<CommandInput placeholder="Search options..." />
<CommandEmpty>No options found.</CommandEmpty>
<CommandGroup className="max-h-80 overflow-y-auto">
{field.options.map((option) => (
{field.options?.map((option) => (
<CommandItem
value={option.label}
key={option.value}
Expand Down

0 comments on commit 179b7ba

Please sign in to comment.