Skip to content

[Material 3] Support dividers in DropdownMenu #128502

@navaronbracke

Description

@navaronbracke

Is there an existing issue for this?

Use case

The Material 3 specification has a section about Dividers in DropdownMenus.

See item 6 in the spec: https://m3.material.io/components/menus/specs

However, the DropdownMenu API currently only allows a list of DropdownMenuEntryitems, which each require a value and a label. This prevents using a Divider, as the divider has no real value.

Proposal

Implement a new DropdownMenuEntry subclass, DropdownMenuDivider, which has no value or label and just inserts a Divider per the Material 3 example (using the M3 divider specs). No selection change should happen when a Divider is tapped.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Issues that are less important to the Flutter projectc: new featureNothing broken; request for a new capabilityc: proposalA detailed proposal for a change to Flutterf: material designflutter/packages/flutter/material repository.frameworkflutter/packages/flutter repository. See also f: labels.team-designOwned by Design Languages teamtriaged-designTriaged by Design Languages team

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions