textStyle method

TextStyle textStyle(
  1. Color color, {
  2. bool bold = false,
  3. FontWeight? fontWeight,
  4. double? letterSpacing,
  5. double? height,
})

Implementation

TextStyle textStyle(
  Color color, {
  bool bold = false,
  FontWeight? fontWeight,
  double? letterSpacing,
  double? height,
}) {
  return TextStyle(
    color: color,
    fontSize: sp,
    fontWeight: fontWeight ?? (bold ? FontWeight.bold : FontWeight.normal),
    letterSpacing: letterSpacing,
    height: height,
    decoration: TextDecoration.none,
  );
}