skills/material-design-3-typography/SKILL.md
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.
npx skillsauth add shelbeely/shelbeely-agent-skills material-design-3-typographyInstall 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.
This skill guides the implementation of Material Design 3 (M3) typography — from the baseline Material You type scale through to M3 Expressive's 30-style expanded type system — to create clear, readable, and emotionally engaging text hierarchies.
Keywords: Material Design 3, M3, typography, type scale, variable fonts, text hierarchy, readability, font weights, line height, letter spacing, emphasized type, medium contrast, Material You
M3 typography focuses on:
M3 defines a comprehensive type scale with specific roles for different UI elements. These 15 baseline styles form the foundation of all M3 typography:
Display Large:
Display Medium:
Display Small:
Headline Large:
Headline Medium:
Headline Small:
Title Large:
Title Medium:
Title Small:
Body Large:
Body Medium:
Body Small:
Label Large:
Label Medium:
Label Small:
M3 Expressive adds 15 emphasized variants — one for each baseline style. Emphasized styles are bolder, larger, or more dynamic for highlighting key moments, calls to action, and editorial emphasis:
| Role | Baseline | Emphasized | |------|----------|------------| | Display Large | 57px / 400 | 57px / 700 | | Display Medium | 45px / 400 | 45px / 700 | | Display Small | 36px / 400 | 36px / 700 | | Headline Large | 32px / 400 | 32px / 700 | | Headline Medium | 28px / 400 | 28px / 700 | | Headline Small | 24px / 400 | 24px / 600 | | Title Large | 22px / 400 | 22px / 700 | | Title Medium | 16px / 500 | 16px / 700 | | Title Small | 14px / 500 | 14px / 700 | | Body Large | 16px / 400 | 16px / 700 | | Body Medium | 14px / 400 | 14px / 700 | | Body Small | 12px / 400 | 12px / 700 | | Label Large | 14px / 500 | 14px / 800 | | Label Medium | 12px / 500 | 12px / 800 | | Label Small | 11px / 500 | 11px / 800 |
When to use emphasized styles:
Pairing baseline and emphasized:
M3 Expressive introduces "medium contrast" as the default typography approach:
Roboto (Default for M3):
Roboto Flex (Variable font):
Consider these characteristics when choosing brand fonts:
Display Fonts:
Body Fonts:
@font-face {
font-family: 'Roboto Flex';
src: url('RobotoFlex-Variable.woff2') format('woff2-variations');
font-weight: 100 900;
font-stretch: 75% 125%;
}
.dynamic-text {
font-family: 'Roboto Flex', sans-serif;
font-variation-settings:
'wght' 400,
'wdth' 100;
}
Define typography tokens using CSS custom properties. M3 Expressive adds emphasized variants alongside baseline:
:root {
/* Font families */
--md-sys-typescale-font-family-brand: 'Roboto', sans-serif;
--md-sys-typescale-font-family-plain: 'Roboto', sans-serif;
/* Display Large — Baseline */
--md-sys-typescale-display-large-font: var(--md-sys-typescale-font-family-brand);
--md-sys-typescale-display-large-size: 3.562rem;
--md-sys-typescale-display-large-line-height: 4rem;
--md-sys-typescale-display-large-weight: 400;
--md-sys-typescale-display-large-tracking: -0.25px;
/* Display Large — Emphasized (M3 Expressive) */
--md-sys-typescale-display-large-emphasized-weight: 700;
/* Headline Large — Baseline */
--md-sys-typescale-headline-large-font: var(--md-sys-typescale-font-family-brand);
--md-sys-typescale-headline-large-size: 2rem;
--md-sys-typescale-headline-large-line-height: 2.5rem;
--md-sys-typescale-headline-large-weight: 400;
--md-sys-typescale-headline-large-tracking: 0;
/* Headline Large — Emphasized (M3 Expressive) */
--md-sys-typescale-headline-large-emphasized-weight: 700;
/* Body Large — Baseline */
--md-sys-typescale-body-large-font: var(--md-sys-typescale-font-family-plain);
--md-sys-typescale-body-large-size: 1rem;
--md-sys-typescale-body-large-line-height: 1.5rem;
--md-sys-typescale-body-large-weight: 400;
--md-sys-typescale-body-large-tracking: 0.5px;
/* Body Large — Emphasized (M3 Expressive) */
--md-sys-typescale-body-large-emphasized-weight: 700;
/* Label Large — Baseline */
--md-sys-typescale-label-large-font: var(--md-sys-typescale-font-family-plain);
--md-sys-typescale-label-large-size: 0.875rem;
--md-sys-typescale-label-large-line-height: 1.25rem;
--md-sys-typescale-label-large-weight: 500;
--md-sys-typescale-label-large-tracking: 0.1px;
/* Label Large — Emphasized (M3 Expressive) */
--md-sys-typescale-label-large-emphasized-weight: 800;
}
Create reusable type classes for both baseline and emphasized styles:
/* Baseline styles */
.display-large {
font-family: var(--md-sys-typescale-display-large-font);
font-size: var(--md-sys-typescale-display-large-size);
line-height: var(--md-sys-typescale-display-large-line-height);
font-weight: var(--md-sys-typescale-display-large-weight);
letter-spacing: var(--md-sys-typescale-display-large-tracking);
}
.headline-large {
font-family: var(--md-sys-typescale-headline-large-font);
font-size: var(--md-sys-typescale-headline-large-size);
line-height: var(--md-sys-typescale-headline-large-line-height);
font-weight: var(--md-sys-typescale-headline-large-weight);
letter-spacing: var(--md-sys-typescale-headline-large-tracking);
}
.body-large {
font-family: var(--md-sys-typescale-body-large-font);
font-size: var(--md-sys-typescale-body-large-size);
line-height: var(--md-sys-typescale-body-large-line-height);
font-weight: var(--md-sys-typescale-body-large-weight);
letter-spacing: var(--md-sys-typescale-body-large-tracking);
}
/* Emphasized styles (M3 Expressive) */
.display-large-emphasized {
font-family: var(--md-sys-typescale-display-large-font);
font-size: var(--md-sys-typescale-display-large-size);
line-height: var(--md-sys-typescale-display-large-line-height);
font-weight: var(--md-sys-typescale-display-large-emphasized-weight);
letter-spacing: var(--md-sys-typescale-display-large-tracking);
}
.headline-large-emphasized {
font-family: var(--md-sys-typescale-headline-large-font);
font-size: var(--md-sys-typescale-headline-large-size);
line-height: var(--md-sys-typescale-headline-large-line-height);
font-weight: var(--md-sys-typescale-headline-large-emphasized-weight);
letter-spacing: var(--md-sys-typescale-headline-large-tracking);
}
.body-large-emphasized {
font-family: var(--md-sys-typescale-body-large-font);
font-size: var(--md-sys-typescale-body-large-size);
line-height: var(--md-sys-typescale-body-large-line-height);
font-weight: var(--md-sys-typescale-body-large-emphasized-weight);
letter-spacing: var(--md-sys-typescale-body-large-tracking);
}
.label-large-emphasized {
font-family: var(--md-sys-typescale-label-large-font);
font-size: var(--md-sys-typescale-label-large-size);
line-height: var(--md-sys-typescale-label-large-line-height);
font-weight: var(--md-sys-typescale-label-large-emphasized-weight);
letter-spacing: var(--md-sys-typescale-label-large-tracking);
}
/* Mobile-first base sizes */
:root {
--fluid-display-large: clamp(2.5rem, 5vw + 1rem, 3.562rem);
--fluid-headline-large: clamp(1.5rem, 3vw + 0.5rem, 2rem);
}
.display-large {
font-size: var(--fluid-display-large);
}
/* Or use container queries for component-level responsiveness */
@container (min-width: 600px) {
.card-title {
font-size: var(--md-sys-typescale-title-large-size);
}
}
font-display: swap to prevent text blocking@font-face {
font-family: 'Roboto';
src: url('roboto.woff2') format('woff2');
font-display: swap;
/* Subset to Latin characters */
unicode-range: U+0000-00FF, U+0131, U+0152-0153;
}
Variable Font Animations:
@keyframes weight-shift {
from { font-variation-settings: 'wght' 300; }
to { font-variation-settings: 'wght' 700; }
}
.animated-heading {
animation: weight-shift 2s ease-in-out infinite alternate;
}
Gradient Text:
.gradient-headline {
background: linear-gradient(
90deg,
var(--md-sys-color-primary),
var(--md-sys-color-tertiary)
);
-webkit-background-clip: text;
-webkit-text-fill-color: transparent;
background-clip: text;
}
/* Single line truncation */
.truncate {
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
/* Multi-line truncation */
.truncate-multi {
display: -webkit-box;
-webkit-line-clamp: 3;
-webkit-box-orient: vertical;
overflow: hidden;
}
<div class="card">
<h3 class="title-large">Card Title</h3>
<p class="body-medium">Card description text goes here.</p>
</div>
<header>
<h1 class="headline-large">Page Title</h1>
<p class="body-large">Supporting description or subtitle</p>
</header>
<button class="label-large">Action</button>
<li>
<span class="title-medium">List Item Title</span>
<span class="body-small">Supporting text</span>
</li>
When implementing M3 typography, ensure:
examples/type-scale.html — Interactive HTML example showing the complete M3 type scale (display, headline, title, body, label) with correct sizes, weights, and line heights. Open in a browser to preview the hierarchy.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 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.
testing
Applies Material Design 3 Expressive motion and animation principles to create natural, intuitive, and engaging user experiences. Use this when implementing animations, transitions, micro-interactions, or when the user asks to apply Material Design 3 motion guidelines.