Code:
import 'package:flutter/material.dart';
import 'package:google_fonts/google_fonts.dart';
import 'package:insta/utils/colors.dart';
class CustomText extends StatelessWidget {
const CustomText(
{Key? key,
required this.size,
required this.text,
required this.textColor,
required this.fontWeight})
: super(key: key);
final double size;
final String text;
final Color textColor;
final FontWeight fontWeight;
@override
Widget build(BuildContext context) {
return Text(
text,
style: GoogleFonts.poppins(
color: textColor,
fontSize: size,
fontWeight: fontWeight,
),
);
}
}
Comments
Post a Comment