I'm working on small chat app and frontend of it written in Flet. I would like to add search functionality with following flow:
Te
;/search
route and gets ['Tet', 'Test']
as an answer;[]
is returned), Nothing is found
option is passed to dropdown.In simpler terms, I would like to have good old combobox, and as of now, I dont see any ft.ComboBox
or similar GUI objects in flet
lib.
So, how do I implement that?
flet.Dropdown has additional parameters: editable, enable_search, enable_filter. Set them to True as in code bottom:
dd = ft.Dropdown(
editable=True,
enable_search=True,
enable_filter=True,
width=200,
options=[
ft.dropdown.Option("Red"),
ft.dropdown.Option("Green"),
ft.dropdown.Option("Blue"),
]
)