HeroText constructor

const HeroText(
  1. String? text, {
  2. Key? key,
  3. required Object? tag,
  4. required ViewState viewState,
  5. double smallFontSize = 15.0,
  6. double largeFontSize = 48.0,
  7. TextStyle? style,
  8. TextAlign textAlign = TextAlign.center,
  9. TextDirection? textDirection,
  10. double? textScaleFactor,
  11. int maxLines = 1,
  12. Locale? locale,
  13. StrutStyle? strutStyle,
})

Implementation

const HeroText(
  this.text, {
  super.key,
  required this.tag,
  required this.viewState,
  this.smallFontSize = 15.0,
  this.largeFontSize = 48.0,
  this.style,
  this.textAlign = TextAlign.center,
  this.textDirection,
  this.textScaleFactor,
  this.maxLines = 1,
  this.locale,
  this.strutStyle,
}) : assert(
        viewState == ViewState.shrunk || viewState == ViewState.enlarged,
      );