Skip to content

Commit

Permalink
[tt] fix location select text
Browse files Browse the repository at this point in the history
  • Loading branch information
a-type committed Jul 19, 2024
1 parent 71d8cc9 commit 1144a30
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion apps/trip-tick/web/src/components/weather/LocationSelect.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,9 @@ function LocationSelectAutocomplete({
}
}
},
itemToString: (item) => {
return item?.text ?? '';
},
});

const contentRef = useRef<HTMLDivElement>(null);
Expand Down Expand Up @@ -214,7 +217,9 @@ function LocationSelectAutocomplete({
<span className="">{item.text}</span>
</div>
))}
{!options && <div className="p-2 text-center">No results found</div>}
{!options?.length && (
<div className="px-2 text-center">No results found</div>
)}
</PopoverContent>
</Popover>
);
Expand Down

0 comments on commit 1144a30

Please sign in to comment.