import 'package:flutter/material.dart'; import 'package:google_fonts/google_fonts.dart'; import 'package:tanami_app/core/styles/app_color.dart'; class TextWidget { //Text Size 11 Widget text11W400(String text, {Color? clr}) { return Text(text, style: GoogleFonts.dmSans( fontSize: 11, fontWeight: FontWeight.w400, color: clr ?? AppColor.plainWhite)); } Widget text11W500(String text, {Color? clr}) { return Text(text, style: GoogleFonts.dmSans( fontSize: 11, fontWeight: FontWeight.w500, color: clr ?? AppColor.plainWhite)); } Widget text11W700(String text, {Color? clr}) { return Text(text, style: GoogleFonts.dmSans( fontSize: 11, fontWeight: FontWeight.w700, color: clr ?? AppColor.plainWhite)); } //Text Size 12 Widget text12W400(String text, {Color? clr}) { return Text(text, style: GoogleFonts.dmSans( fontSize: 12, fontWeight: FontWeight.w400, color: clr ?? AppColor.plainWhite)); } Widget text12W500(String text, {Color? clr}) { return Text(text, style: GoogleFonts.dmSans( fontSize: 12, fontWeight: FontWeight.w500, color: clr ?? AppColor.plainWhite)); } Widget text12W700(String text, {Color? clr, TextDecoration? txtDec, Color? decClr}) { return Text(text, style: GoogleFonts.dmSans( fontSize: 12, decorationColor: decClr ?? AppColor.plainWhite, decoration: txtDec ?? TextDecoration.none, fontWeight: FontWeight.w700, color: clr ?? AppColor.plainWhite)); } //Text Size 13 Widget text13W500(String text, {Color? clr}) { return Text(text, style: GoogleFonts.dmSans( fontSize: 13, fontWeight: FontWeight.w500, color: clr ?? AppColor.plainWhite)); } //Text Size 14 Widget text14W400( String text, { Color? clr, TextDecoration? textDecoration, TextAlign? txtAlign, int? maxLine, TextOverflow? txtOverflow, }) { return Text(text, textAlign: txtAlign ?? TextAlign.center, maxLines: maxLine ?? 20, overflow: txtOverflow ?? TextOverflow.ellipsis, style: GoogleFonts.dmSans( fontSize: 14, fontWeight: FontWeight.w400, decoration: textDecoration ?? TextDecoration.none, color: clr ?? AppColor.plainWhite)); } Widget text14W500( String text, { Color? clr, TextDecoration? textDecoration, TextAlign? txtAlign, }) { return Text(text, textAlign: txtAlign ?? TextAlign.center, style: GoogleFonts.dmSans( fontSize: 14, fontWeight: FontWeight.w500, decoration: textDecoration ?? TextDecoration.none, color: clr ?? AppColor.plainWhite)); } Widget text14W600( String text, { Color? clr, TextDecoration? textDecoration, TextAlign? txtAlign, }) { return Text(text, textAlign: txtAlign ?? TextAlign.center, style: GoogleFonts.dmSans( fontSize: 14, fontWeight: FontWeight.w600, decoration: textDecoration ?? TextDecoration.none, color: clr ?? AppColor.plainWhite)); } Widget text14W700(String text, {Color? clr, TextDecoration? textDecoration, TextAlign? txtAlign}) { return Text(text, textAlign: txtAlign ?? TextAlign.center, style: GoogleFonts.dmSans( fontSize: 14, fontWeight: FontWeight.w700, decoration: textDecoration ?? TextDecoration.none, color: clr ?? AppColor.plainWhite)); } //Text Size 15 Widget text15W400( String text, { Color? clr, TextDecoration? textDecoration, TextAlign? txtAlign, }) { return Text(text, textAlign: txtAlign ?? TextAlign.center, style: GoogleFonts.dmSans( decoration: textDecoration ?? TextDecoration.none, decorationColor: clr ?? AppColor.plainWhite, fontSize: 15, fontWeight: FontWeight.w400, color: clr ?? AppColor.plainWhite)); } Widget text15W500( String text, { Color? clr, TextDecoration? textDecoration, }) { return Text(text, textAlign: TextAlign.center, style: GoogleFonts.dmSans( fontSize: 15, decorationColor: AppColor.hintTextColor, decoration: textDecoration ?? TextDecoration.none, fontWeight: FontWeight.w500, color: clr ?? AppColor.plainWhite)); } Widget text15W700( String text, { Color? clr, TextDecoration? textDecoration, }) { return Text(text, textAlign: TextAlign.center, style: GoogleFonts.dmSans( fontSize: 15, decorationColor: AppColor.hintTextColor, decoration: textDecoration ?? TextDecoration.none, fontWeight: FontWeight.w700, color: clr ?? AppColor.plainWhite)); } //Text Size 17 Widget text17W600( String text, { Color? clr, TextDecoration? textDecoration, }) { return Text(text, textAlign: TextAlign.center, style: GoogleFonts.dmSans( fontSize: 17, decorationColor: AppColor.hintTextColor, decoration: textDecoration ?? TextDecoration.none, fontWeight: FontWeight.w600, color: clr ?? AppColor.plainWhite)); } Widget text17W700( String text, { Color? clr, TextDecoration? textDecoration, }) { return Text(text, textAlign: TextAlign.center, style: GoogleFonts.dmSans( fontSize: 17, decorationColor: AppColor.hintTextColor, decoration: textDecoration ?? TextDecoration.none, fontWeight: FontWeight.w700, color: clr ?? AppColor.plainWhite)); } //Text Size 18 Widget text18W700( String text, { Color? clr, TextDecoration? textDecoration, }) { return Text(text, textAlign: TextAlign.center, style: GoogleFonts.dmSans( fontSize: 18, decorationColor: AppColor.hintTextColor, decoration: textDecoration ?? TextDecoration.none, fontWeight: FontWeight.w700, color: clr ?? AppColor.plainWhite)); } //Text Size 22 Widget text22W400(String text, {Color? clr}) { return Text(text, style: GoogleFonts.dmSans( fontSize: 22, fontWeight: FontWeight.w400, color: clr ?? AppColor.plainWhite)); } Widget text22W700(String text, {Color? clr}) { return Text(text, style: GoogleFonts.dmSans( fontSize: 22, fontWeight: FontWeight.w700, color: clr ?? AppColor.plainWhite)); } Widget text22W900(String text, {Color? clr}) { return Text(text, style: GoogleFonts.dmSans( fontSize: 22, fontWeight: FontWeight.w900, color: clr ?? AppColor.plainWhite)); } //Text Size 20 Widget text20W700(String text, {Color? clr}) { return Text(text, style: GoogleFonts.dmSans( fontSize: 20, fontWeight: FontWeight.w700, color: clr ?? AppColor.plainWhite)); } //Text Size 28 Widget text28W700(String text, {Color? clr}) { return Text(text, style: GoogleFonts.dmSans( fontSize: 28, fontWeight: FontWeight.w700, color: clr ?? AppColor.plainWhite)); } }