skills/m3-web-flutter/SKILL.md
Implement Material Design 3 in Flutter using the built-in material library with M3 theming and dynamic color. Covers theme setup, color schemes, and M3 Expressive packages. Use this when building M3-styled Flutter applications for mobile, web, or desktop.
npx skillsauth add shelbeely/shelbeely-agent-skills m3-web-flutterInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Flutter has built-in M3 support since version 3.16. The material library provides M3 components, dynamic color, and theming. Full M3 Expressive support is being developed as modular packages (m3e_design).
Keywords: Material Design 3, M3, Flutter, Dart, cross-platform, dynamic color, Material You, m3e_design, mobile
M3 is built into Flutter — no additional packages needed for baseline:
MaterialApp(
theme: ThemeData(
useMaterial3: true,
colorSchemeSeed: const Color(0xFF6750A4),
),
darkTheme: ThemeData(
useMaterial3: true,
brightness: Brightness.dark,
colorSchemeSeed: const Color(0xFF6750A4),
),
home: const MyApp(),
);
On Android 12+, use the device's wallpaper-based dynamic color:
import 'package:dynamic_color/dynamic_color.dart';
DynamicColorBuilder(
builder: (ColorScheme? lightDynamic, ColorScheme? darkDynamic) {
return MaterialApp(
theme: ThemeData(
colorScheme: lightDynamic ?? ColorScheme.fromSeed(
seedColor: const Color(0xFF6750A4),
),
useMaterial3: true,
),
darkTheme: ThemeData(
colorScheme: darkDynamic ?? ColorScheme.fromSeed(
seedColor: const Color(0xFF6750A4),
brightness: Brightness.dark,
),
useMaterial3: true,
),
);
},
);
FilledButton(onPressed: () {}, child: const Text('Filled')),
OutlinedButton(onPressed: () {}, child: const Text('Outlined')),
TextButton(onPressed: () {}, child: const Text('Text')),
FilledButton.tonal(onPressed: () {}, child: const Text('Tonal')),
ElevatedButton(onPressed: () {}, child: const Text('Elevated')),
Card(
elevation: 1,
child: Padding(
padding: const EdgeInsets.all(16),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text('Title', style: Theme.of(context).textTheme.titleMedium),
Text('Content', style: Theme.of(context).textTheme.bodyMedium),
],
),
),
),
TextField(
decoration: const InputDecoration(
labelText: 'Email',
border: OutlineInputBorder(),
),
),
NavigationBar(
selectedIndex: currentIndex,
onDestinationSelected: (index) => setState(() => currentIndex = index),
destinations: const [
NavigationDestination(icon: Icon(Icons.home), label: 'Home'),
NavigationDestination(icon: Icon(Icons.search), label: 'Search'),
NavigationDestination(icon: Icon(Icons.settings), label: 'Settings'),
],
),
# pubspec.yaml
dependencies:
m3e_design: ^latest
M3 Expressive adds enhanced shapes, motion, typography, and new components to Flutter's M3 implementation.
useMaterial3: true set in ThemeDatacolorSchemeSeed or ColorScheme.fromSeed used for color generationTheme.of(context).textTheme for M3 type scaleFilledButton, not RaisedButton)tools
Guide for creating effective skills. This skill should be used when users want to create a new skill (or update an existing skill) that extends Claude's capabilities with specialized knowledge, workflows, or tool integrations.
development
Generate Material Design 3 color themes programmatically from a source color using @material/material-color-utilities, the same engine that powers the Material Theme Builder. Use this when the user asks to generate an M3 color palette, create a custom theme from a brand color, or export M3 tokens to CSS, JSON, or framework configs.
testing
Applies Material Design 3 Expressive typography principles including variable fonts, type scales, and hierarchy. Use this when working on text styling, type hierarchy, readable interfaces, or when the user asks to apply Material Design 3 typography guidelines.
testing
Applies Material Design 3 Expressive shape and containment principles including rounded corners, morphing shapes, and container design. Use this when working on component shapes, borders, containment, or when the user asks to apply Material Design 3 shape guidelines.