heroSectionSemibold static method

TextStyle heroSectionSemibold(
  1. BuildContext context, {
  2. String? fontFamily,
  3. Color? color,
})

Implementation

static TextStyle heroSectionSemibold(BuildContext context, {String? fontFamily, Color? color}) {
  final deviceType = ResponsiveHelper.getDeviceType(context);
  switch (deviceType) {
    case DeviceType.mobile:
      return TextStyle(
        fontFamily: fontFamily ?? AppTypography.fontFamily,
        fontSize: AppTypography.mobileFontSizeHeroSection,
        fontWeight: AppTypography.fontWeightSemibold,
        height: AppTypography.mobileLineHeightHeroSection / AppTypography.mobileFontSizeHeroSection,
        color: color ?? Colors.black,
      );
    case DeviceType.tablet:
      return TextStyle(
        fontFamily: fontFamily ?? AppTypography.fontFamily,
        fontSize: AppTypography.tabletFontSizeHeroSection,
        fontWeight: AppTypography.fontWeightSemibold,
        height: AppTypography.tabletLineHeightHeroSection / AppTypography.tabletFontSizeHeroSection,
        color: color ?? Colors.black,
      );
    case DeviceType.desktop:
      return TextStyle(
        fontFamily: fontFamily ?? AppTypography.fontFamily,
        fontSize: AppTypography.desktopFontSizeHeroSection,
        fontWeight: AppTypography.fontWeightSemibold,
        height: AppTypography.desktopLineHeightHeroSection / AppTypography.desktopFontSizeHeroSection,
        color: color ?? Colors.black,
      );
  }
}