chivoTextTheme static method

TextTheme chivoTextTheme(
  1. [TextTheme? textTheme]
)

Applies the Chivo font family from Google Fonts to every TextStyle in the given textTheme.

See:

Implementation

static TextTheme chivoTextTheme([TextTheme? textTheme]) {
  textTheme ??= ThemeData.light().textTheme;
  return TextTheme(
    displayLarge: GoogleFonts.chivo(textStyle: textTheme.displayLarge),
    displayMedium: GoogleFonts.chivo(textStyle: textTheme.displayMedium),
    displaySmall: GoogleFonts.chivo(textStyle: textTheme.displaySmall),
    headlineLarge: GoogleFonts.chivo(textStyle: textTheme.headlineLarge),
    headlineMedium: GoogleFonts.chivo(textStyle: textTheme.headlineMedium),
    headlineSmall: GoogleFonts.chivo(textStyle: textTheme.headlineSmall),
    titleLarge: GoogleFonts.chivo(textStyle: textTheme.titleLarge),
    titleMedium: GoogleFonts.chivo(textStyle: textTheme.titleMedium),
    titleSmall: GoogleFonts.chivo(textStyle: textTheme.titleSmall),
    bodyLarge: GoogleFonts.chivo(textStyle: textTheme.bodyLarge),
    bodyMedium: GoogleFonts.chivo(textStyle: textTheme.bodyMedium),
    bodySmall: GoogleFonts.chivo(textStyle: textTheme.bodySmall),
    labelLarge: GoogleFonts.chivo(textStyle: textTheme.labelLarge),
    labelMedium: GoogleFonts.chivo(textStyle: textTheme.labelMedium),
    labelSmall: GoogleFonts.chivo(textStyle: textTheme.labelSmall),
  );
}