NmTheme class

Theme configuration: palette × preset (style, density, iconography), with optional per-axis overrides.

Annotations

Constructors

NmTheme({NmPalette palette = NmPalette.blue, NmPreset preset = NmPreset.workspace, NmStyle? style, NmDensity? density, NmIconography? iconography, NmFugueVariant? fugueVariant, ThemeMode mode = ThemeMode.system, NmBreakpoints breakpoints = const NmBreakpoints(), NmCtaFill ctaFill = NmCtaFill.bright, NmSurfaceTone surfaceTone = NmSurfaceTone.calm})
Creates an NmTheme.
const

Properties

breakpoints → NmBreakpoints
Form-factor widths.
final
ctaFill → NmCtaFill
Primary-button fill of the expressive style: the palette's bright gradient or the deeper AA one.
final
density → NmDensity?
Overrides the preset's density.
final
effectiveDensity → NmDensity
density, else the preset's.
no setter
effectiveIconography → NmIconography
iconography, else the preset's.
no setter
effectiveStyle → NmStyle
style, else the preset's.
no setter
fugueVariant → NmFugueVariant?
Fugue with or without shadows (defaults per style).
final
hashCode → int
The hash code for this object.
no setterinherited
iconography → NmIconography?
Overrides the preset's iconography.
final
mode → ThemeMode
Light, dark or system.
final
palette → NmPalette
Accent palette.
final
preset → NmPreset
Style, density and iconography defaults.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
style → NmStyle?
Overrides the preset's style.
final
surfaceTone → NmSurfaceTone
Surface intensity derived from the palette: calm (as tuned) or vivid.
final

Methods

copyWith({NmPalette? palette, NmPreset? preset, NmStyle? style, NmDensity? density, NmIconography? iconography, NmFugueVariant? fugueVariant, ThemeMode? mode, NmBreakpoints? breakpoints, NmCtaFill? ctaFill, NmSurfaceTone? surfaceTone}) → NmTheme
A copy with the given fields replaced.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toCupertino(Brightness brightness) → CupertinoThemeData
Cupertino theme matching toThemeData.
tokens(Brightness brightness) → NmTokens
Token set for brightness.
toString() → String
A string representation of this object.
inherited
toThemeData(Brightness brightness) → ThemeData
Material 3 theme with NmTokens attached as an extension.

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Constants

fontFallback → const List<String>
Font fallback chain. SF Pro is the design face; it is used where the platform provides it and is not bundled (licensing).
monoFallback → const List<String>
Monospace chain for data (domains, IDs, codes).