forked from eatvio/eatvio_app
31 lines
801 B
Dart
31 lines
801 B
Dart
import 'package:flutter/material.dart';
|
|
import '../core/app_export.dart';
|
|
|
|
/// A collection of pre-defined text styles for customizing text appearance,
|
|
/// categorized by different font families and weights.
|
|
/// Additionally, this class includes extensions on [TextStyle] to easily apply specific font families to text.
|
|
|
|
class CustomTextStyles {
|
|
// Headline style
|
|
static get headlineSmallMulish => theme.textTheme.headlineSmall!.mulish;
|
|
// Title text style
|
|
static get titleMediumSegoeUI =>
|
|
theme.textTheme.titleMedium!.segoeUI.copyWith(
|
|
fontWeight: FontWeight.w600,
|
|
);
|
|
}
|
|
|
|
extension on TextStyle {
|
|
TextStyle get mulish {
|
|
return copyWith(
|
|
fontFamily: 'Mulish',
|
|
);
|
|
}
|
|
|
|
TextStyle get segoeUI {
|
|
return copyWith(
|
|
fontFamily: 'Segoe UI',
|
|
);
|
|
}
|
|
}
|