[Python] How to make combobox in flet?

Discussão em 'Python' iniciado por Stack, Março 27, 2025.

  1. Stack

    Stack Membro Participativo

    I'm working on small chat app and frontend of it written in Flet. I would like to add search functionality with following flow:

    • There's search field in UserControl;
    • User clicks on this field, enters some value, say Te;
    • App calls DB with /search route and gets ['Tet', 'Test'] as an answer;
    • This list of values is shown to user in dropdown where user may select one. If nothing is found ( = [] 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.

    • ft.TextField doesn't have dropdown;
    • ft.Dropdown doesn't have text field to write anything;

    So, how do I implement that?

    Continue reading...

Compartilhe esta Página