Skip to content
pubscout

split_button_m3e

0.2.1, released a year ago by bruckcode.de

Material 3 Expressive Split Button widget for Flutter with sizes, variants, and menus.

WASM-ready
$ flutter pub add split_button_m3e
Source repository

What it does

Provides a two-segment split button widget containing a primary action segment and a trailing menu trigger segment. Supports multiple sizes from XS to XL, different shapes and emphases, token-driven dimensions, and accessibility features.

AI-written summary of version 0.2.1, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You need a Material 3 Expressive split button with a primary action and a dropdown menu.
  • You want token-driven sizing and shapes aligned with Material 3 measurement boards.

Skip it when

  • You are not using Material design or the companion m3e_design package.
  • You only need a standard single-action button or a basic popup menu button.

Strengths

  • Follows Material 3 Expressive specifications with token-driven sizes and shapes.
  • Independent focusable segments meeting minimum touch targets of 48x48dp.

Weaknesses

  • Relies on the custom m3e_design dependency.
  • Limited platform/ecosystem scope compared to core Material components.

Setup

Kind
Flutter widgets
Effort
Low
Code generation
No
Direct dependencies
1

Add split_button_m3e and m3e_design to your pubspec.yaml dependencies.

SplitButtonM3E<String>(
  size: SplitButtonM3ESize.md,
  shape: SplitButtonM3EShape.round,
  emphasis: SplitButtonM3EEmphasis.tonal,
  label: 'Save',
  leadingIcon: Icons.save_outlined,
  onPressed: () => debugPrint('Primary pressed'),
  items: const [
    SplitButtonM3EItem<String>(value: 'draft', child: 'Save as draft'),
    SplitButtonM3EItem<String>(value: 'close', child: 'Save & close'),
  ],
  onSelected: (v) => debugPrint('Selected: $v'),
)

Alternatives

Packages that do the same job and could replace split_button_m3e.

Works with

Packages commonly used together with split_button_m3e: ones it builds on, ones built on it, and its own family.