Skip to content

New Dropdown ignore dense property #5047

Open
@michep

Description

@michep

Duplicate Check

Describe the bug

New Dropdown control does not differ if dense=False or dense=True.

Code sample

Code
import flet as ft
def main(page: ft.Page):
    page.theme_mode = ft.ThemeMode.LIGHT

    new_ddd = ft.Dropdown(
        options=[
            ft.dropdown.Option("new DD, dense"),
        ],
        dense=True,
    )
    new_dd = ft.Dropdown(
        options=[
            ft.dropdown.Option("new DD, not dense"),
        ],
    )
    old_ddd = ft.DropdownM2(
        options=[
            ft.dropdown.Option("old DD, dense"),
        ],
        dense=True,
    )
    old_dd = ft.DropdownM2(
        options=[
            ft.dropdown.Option("old DD, not dense"),
        ],
    )
    row = ft.Row([new_ddd, new_dd, old_dd, old_ddd])
    page.add(row)

ft.app(main)

To reproduce

run sample code

Expected behavior

Dropdown control with dense=True should have "dense" look, like old one.

Screenshots / Videos

Captures

Image

Operating System

Windows

Operating system details

Windows 11

Flet version

0.27.5

Regression

Yes, it used to work in a previous Flet version (please specify the version in additional details)

Suggestions

No response

Logs

Logs
[Paste your logs here]

Additional details

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions