ZetaColors.dark constructor
- ZetaContrast contrast = ZetaContrast.aa,
- ZetaColorSwatch? primary,
- ZetaColorSwatch? secondary,
- ZetaColorSwatch? error,
- ZetaColorSwatch? cool,
- ZetaColorSwatch? warm,
- Color? white,
- Color? black,
- @Deprecated('This color has been deprecated as of v0.10.0') dynamic link,
- @Deprecated('This color has been deprecated as of v0.10.0') dynamic linkVisited,
- @Deprecated('This color has been deprecated as of v0.10.0') dynamic shadow,
Factory constructor for a dark theme for ZetaColors.
All color options are nullable and default to a pre-defined contrast color if null.
contrast
The primary contrast color. If not supplied, defaults to ZetaContrast.aa.
primary
A color swatch for primary color accent. Defaults to null.
secondary
A color swatch for secondary color accent. Defaults to null.
error
A color swatch for error states. Defaults to null.
cool
A color swatch for cooler color tones. Defaults to null.
warm
A color swatch for warmer color tones. Defaults to null.
white
A color option for white color. Defaults to null.
black
A color option for black color. Defaults to null.
Implementation
factory ZetaColors.dark({
ZetaContrast contrast = ZetaContrast.aa,
ZetaColorSwatch? primary,
ZetaColorSwatch? secondary,
ZetaColorSwatch? error,
ZetaColorSwatch? cool,
ZetaColorSwatch? warm,
Color? white,
Color? black,
@Deprecated('This color has been deprecated as of v0.10.0') link,
@Deprecated('This color has been deprecated as of v0.10.0') linkVisited,
@Deprecated('This color has been deprecated as of v0.10.0') shadow,
}) {
return ZetaColors(
cool: cool,
warm: warm,
white: white ?? ZetaColorBase.white,
black: black ?? ZetaColorBase.black,
primary: primary,
contrast: contrast,
secondary: secondary,
error: error,
brightness: Brightness.dark,
surfaceTertiary: warm?.shade10,
surfaceSecondary: cool?.shade10,
surfacePrimary: black ?? ZetaColorBase.black,
);
}