headline1 static method
- BuildContext context
A text style for the app's headline 1.
The headline 1 text style is used for the app's main title and is typically displayed in a large font size.
Implementation
static TextStyle headline1(BuildContext context) => TextStyle(
// The font size is set to 34sp which is a large font size.
fontSize: 34.sp,
// The font weight is set to bold which makes the text thicker and more
// prominent.
fontWeight: FontWeight.bold,
// The color is set to the onPrimary color of the theme which is the
// default color for text on the primary color.
color: Theme.of(context).colorScheme.onPrimary,
);