text method

YYDialog text({
  1. dynamic padding,
  2. dynamic text,
  3. dynamic color,
  4. dynamic fontSize,
  5. dynamic alignment,
  6. dynamic textAlign,
  7. dynamic maxLines,
  8. dynamic textDirection,
  9. dynamic overflow,
  10. dynamic fontWeight,
  11. dynamic fontFamily,
})

Implementation

YYDialog text(
    {padding,
    text,
    color,
    fontSize,
    alignment,
    textAlign,
    maxLines,
    textDirection,
    overflow,
    fontWeight,
    fontFamily}) {
  return this.widget(
    Padding(
      padding: padding ?? EdgeInsets.all(0.0),
      child: Align(
        alignment: alignment ?? Alignment.centerLeft,
        child: Text(
          text ?? "",
          textAlign: textAlign,
          maxLines: maxLines,
          textDirection: textDirection,
          overflow: overflow,
          style: TextStyle(
            color: color ?? Colors.black,
            fontSize: fontSize ?? 14.0,
            fontWeight: fontWeight,
            fontFamily: fontFamily,
          ),
        ),
      ),
    ),
  );
}