WowText.labelLarge constructor

WowText.labelLarge(
  1. String? data, {
  2. String? messageDefault,
  3. Key? key,
  4. int? maxLines = 1,
  5. Color? color,
  6. FontWeight? fontWeight,
  7. TextDecoration? decoration,
  8. FontStyle? fontStyle,
  9. TextAlign? textAlign = TextAlign.start,
  10. bool? softWrap = true,
})

Văn bản kích thước nhỏ hơn/bằng bình thường

data có thể là văn bản hoặc id văn bản trên server

Kiểu mã văn bản: chữ cái in hoa, số, dấu gạch dưới

'HELLO_WORLD' // => đúng
'LANGUAGE_1' // => đúng
'LANGUAGE_1_VN' // => đúng
'HELLO_' // => sai
'_HELLO' // => sai
'1_HELLO' // => sai
'HELLOWORLD' // => sai
'Home_Title' // => sai

Ví dụ

WowText('Hello World'); // => 'Hello world'
WowText('HELLO_WORLD'); // => 'Hello world' với văn bản lưu trên server

Implementation

factory WowText.labelLarge(
  String? data, {
  String? messageDefault,
  Key? key,
  int? maxLines = 1,
  Color? color,
  FontWeight? fontWeight,
  TextDecoration? decoration,
  FontStyle? fontStyle,
  TextAlign? textAlign = TextAlign.start,
  bool? softWrap = true,
}) =>
    WowText(
      data,
      messageDefault: messageDefault,
      style: WowTextStyle.labelLarge.copyWith(
        color: color,
        fontWeight: fontWeight,
        decoration: decoration,
        fontStyle: fontStyle,
      ),
      textAlign: textAlign,
      maxLines: maxLines,
      softWrap: softWrap,
    );