diff --git a/frontend/app_flowy/lib/user/presentation/sign_in_screen.dart b/frontend/app_flowy/lib/user/presentation/sign_in_screen.dart index cfb135a55c..8182c95111 100644 --- a/frontend/app_flowy/lib/user/presentation/sign_in_screen.dart +++ b/frontend/app_flowy/lib/user/presentation/sign_in_screen.dart @@ -4,7 +4,6 @@ import 'package:app_flowy/user/presentation/router.dart'; import 'package:app_flowy/user/presentation/widgets/background.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flowy_infra/size.dart'; -import 'package:flowy_infra/text_style.dart'; import 'package:flowy_infra_ui/style_widget/text.dart'; import 'package:flowy_infra_ui/widget/rounded_button.dart'; import 'package:flowy_infra_ui/widget/rounded_input_field.dart'; @@ -17,7 +16,6 @@ import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:dartz/dartz.dart'; import 'package:flowy_infra/image.dart'; import 'package:app_flowy/generated/locale_keys.g.dart'; -import 'package:textstyle_extensions/textstyle_extensions.dart'; class SignInScreen extends StatelessWidget { final AuthRouter router; @@ -103,7 +101,8 @@ class SignUpPrompt extends StatelessWidget { color: Theme.of(context).hintColor, ), TextButton( - style: TextButton.styleFrom(textStyle: TextStyles.body1), + style: TextButton.styleFrom( + textStyle: Theme.of(context).textTheme.bodyMedium), onPressed: () => router.pushSignUpScreen(context), child: Text( LocaleKeys.signUp_buttonText.tr(), @@ -145,8 +144,7 @@ class ForgetPasswordButton extends StatelessWidget { Widget build(BuildContext context) { return TextButton( style: TextButton.styleFrom( - textStyle: TextStyles.body1, - ), + textStyle: Theme.of(context).textTheme.bodyMedium), onPressed: () => router.pushForgetPasswordScreen(context), child: Text( LocaleKeys.signIn_forgotPassword.tr(), @@ -169,7 +167,6 @@ class PasswordTextField extends StatelessWidget { builder: (context, state) { return RoundedInputField( obscureText: true, - style: TextStyles.body1.size(FontSizes.s14), obscureIcon: svgWidget("home/hide"), obscureHideIcon: svgWidget("home/show"), hintText: LocaleKeys.signIn_passwordHint.tr(), @@ -200,7 +197,6 @@ class EmailTextField extends StatelessWidget { builder: (context, state) { return RoundedInputField( hintText: LocaleKeys.signIn_emailHint.tr(), - style: TextStyles.body1.size(FontSizes.s14), errorText: context .read() .state diff --git a/frontend/app_flowy/lib/user/presentation/sign_up_screen.dart b/frontend/app_flowy/lib/user/presentation/sign_up_screen.dart index 79cb1eec5d..7074b218bb 100644 --- a/frontend/app_flowy/lib/user/presentation/sign_up_screen.dart +++ b/frontend/app_flowy/lib/user/presentation/sign_up_screen.dart @@ -3,8 +3,7 @@ import 'package:app_flowy/user/application/sign_up_bloc.dart'; import 'package:app_flowy/user/presentation/router.dart'; import 'package:app_flowy/user/presentation/widgets/background.dart'; import 'package:easy_localization/easy_localization.dart'; -import 'package:flowy_infra/size.dart'; -import 'package:flowy_infra/text_style.dart'; +import 'package:flowy_infra_ui/style_widget/text.dart'; import 'package:flowy_infra_ui/widget/rounded_button.dart'; import 'package:flowy_infra_ui/widget/rounded_input_field.dart'; import 'package:flowy_infra_ui/widget/spacing.dart'; @@ -16,7 +15,6 @@ import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:dartz/dartz.dart'; import 'package:flowy_infra/image.dart'; import 'package:app_flowy/generated/locale_keys.g.dart'; -import 'package:textstyle_extensions/textstyle_extensions.dart'; class SignUpScreen extends StatelessWidget { final AuthRouter router; @@ -90,15 +88,18 @@ class SignUpPrompt extends StatelessWidget { return Row( mainAxisAlignment: MainAxisAlignment.center, children: [ - Text( + FlowyText.medium( LocaleKeys.signUp_alreadyHaveAnAccount.tr(), - style: TextStyle(color: Theme.of(context).hintColor, fontSize: 12), + color: Theme.of(context).hintColor, ), TextButton( - style: TextButton.styleFrom(textStyle: TextStyles.body1), + style: TextButton.styleFrom( + textStyle: Theme.of(context).textTheme.bodyMedium), onPressed: () => Navigator.pop(context), - child: Text(LocaleKeys.signIn_buttonText.tr(), - style: TextStyle(color: Theme.of(context).colorScheme.primary)), + child: FlowyText.medium( + LocaleKeys.signIn_buttonText.tr(), + color: Theme.of(context).colorScheme.primary, + ), ), ], ); @@ -139,7 +140,6 @@ class PasswordTextField extends StatelessWidget { obscureText: true, obscureIcon: svgWidget("home/hide"), obscureHideIcon: svgWidget("home/show"), - style: TextStyles.body1.size(FontSizes.s14), hintText: LocaleKeys.signUp_passwordHint.tr(), normalBorderColor: Theme.of(context).colorScheme.outline, errorBorderColor: Theme.of(context).colorScheme.error, @@ -173,7 +173,6 @@ class RepeatPasswordTextField extends StatelessWidget { obscureText: true, obscureIcon: svgWidget("home/hide"), obscureHideIcon: svgWidget("home/show"), - style: TextStyles.body1.size(FontSizes.s14), hintText: LocaleKeys.signUp_repeatPasswordHint.tr(), normalBorderColor: Theme.of(context).colorScheme.outline, errorBorderColor: Theme.of(context).colorScheme.error, diff --git a/frontend/app_flowy/lib/user/presentation/skip_log_in_screen.dart b/frontend/app_flowy/lib/user/presentation/skip_log_in_screen.dart index 6e6baf97ad..e54ebefac9 100644 --- a/frontend/app_flowy/lib/user/presentation/skip_log_in_screen.dart +++ b/frontend/app_flowy/lib/user/presentation/skip_log_in_screen.dart @@ -3,8 +3,8 @@ import 'package:app_flowy/user/presentation/router.dart'; import 'package:app_flowy/user/presentation/widgets/background.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:flowy_infra/size.dart'; -import 'package:flowy_infra/text_style.dart'; import 'package:flowy_infra/uuid.dart'; +import 'package:flowy_infra_ui/style_widget/text.dart'; import 'package:flowy_infra_ui/widget/rounded_button.dart'; import 'package:flowy_infra_ui/widget/spacing.dart'; import 'package:flowy_sdk/log.dart'; @@ -13,7 +13,6 @@ import 'package:flowy_sdk/protobuf/flowy-folder/protobuf.dart'; import 'package:flowy_sdk/protobuf/flowy-error/errors.pb.dart'; import 'package:flowy_sdk/protobuf/flowy-user/user_profile.pb.dart'; import 'package:flutter/material.dart'; -import 'package:textstyle_extensions/textstyle_extensions.dart'; import 'package:url_launcher/url_launcher.dart'; import 'package:dartz/dartz.dart' as dartz; import 'package:app_flowy/generated/locale_keys.g.dart'; @@ -61,22 +60,23 @@ class _SkipLogInScreenState extends State { mainAxisAlignment: MainAxisAlignment.spaceEvenly, children: [ InkWell( - child: Text( + hoverColor: Colors.transparent, + onTap: () => + _launchURL('https://github.com/AppFlowy-IO/appflowy'), + child: FlowyText.medium( LocaleKeys.githubStarText.tr(), - style: TextStyles.general(color: Colors.blue).underline, + color: Theme.of(context).colorScheme.primary, + decoration: TextDecoration.underline, ), - onTap: () { - _launchURL('https://github.com/AppFlowy-IO/appflowy'); - }, ), InkWell( - child: Text( + hoverColor: Colors.transparent, + onTap: () => _launchURL('https://www.appflowy.io/blog'), + child: FlowyText.medium( LocaleKeys.subscribeNewsletterText.tr(), - style: TextStyles.general(color: Colors.blue).underline, + color: Theme.of(context).colorScheme.primary, + decoration: TextDecoration.underline, ), - onTap: () { - _launchURL('https://www.appflowy.io/blog'); - }, ), ], ) diff --git a/frontend/app_flowy/lib/user/presentation/widgets/background.dart b/frontend/app_flowy/lib/user/presentation/widgets/background.dart index c7d7b25e3c..fe3bdd2a15 100644 --- a/frontend/app_flowy/lib/user/presentation/widgets/background.dart +++ b/frontend/app_flowy/lib/user/presentation/widgets/background.dart @@ -1,6 +1,7 @@ import 'dart:math'; import 'package:flowy_infra/image.dart'; +import 'package:flowy_infra/size.dart'; import 'package:flowy_infra_ui/style_widget/text.dart'; import 'package:flowy_infra_ui/widget/spacing.dart'; import 'package:flutter/material.dart'; @@ -47,7 +48,7 @@ class FlowyLogoTitle extends StatelessWidget { const VSpace(30), FlowyText.semibold( title, - fontSize: 24, + fontSize: FontSizes.s24, ), ], ), diff --git a/frontend/app_flowy/lib/workspace/presentation/home/menu/app/header/header.dart b/frontend/app_flowy/lib/workspace/presentation/home/menu/app/header/header.dart index 5b278a590b..497e9e7a33 100644 --- a/frontend/app_flowy/lib/workspace/presentation/home/menu/app/header/header.dart +++ b/frontend/app_flowy/lib/workspace/presentation/home/menu/app/header/header.dart @@ -3,8 +3,8 @@ import 'package:app_flowy/workspace/presentation/widgets/pop_up_action.dart'; import 'package:appflowy_popover/appflowy_popover.dart'; import 'package:easy_localization/easy_localization.dart'; import 'package:expandable/expandable.dart'; +import 'package:flowy_infra/color_extension.dart'; import 'package:flowy_infra/icon_data.dart'; -import 'package:flowy_infra/text_style.dart'; import 'package:flowy_infra_ui/style_widget/text.dart'; import 'package:flowy_sdk/protobuf/flowy-folder/app.pb.dart'; import 'package:flutter/material.dart'; @@ -102,7 +102,7 @@ class MenuAppHeader extends StatelessWidget { Widget _renderCreateViewButton(BuildContext context) { return Tooltip( message: LocaleKeys.menuAppHeader_addPageTooltip.tr(), - textStyle: TextStyles.caption.textColor(Colors.white), + textStyle: AFThemeExtension.of(context).caption.textColor(Colors.white), child: AddButton( onSelected: (pluginBuilder) { context.read().add( diff --git a/frontend/app_flowy/lib/workspace/presentation/home/menu/menu.dart b/frontend/app_flowy/lib/workspace/presentation/home/menu/menu.dart index fa245a3872..b68f205684 100644 --- a/frontend/app_flowy/lib/workspace/presentation/home/menu/menu.dart +++ b/frontend/app_flowy/lib/workspace/presentation/home/menu/menu.dart @@ -224,7 +224,9 @@ class MenuTopBar extends StatelessWidget { const Spacer(), Tooltip( richMessage: sidebarTooltipTextSpan( - LocaleKeys.sideBar_closeSidebar.tr()), + context, + LocaleKeys.sideBar_closeSidebar.tr(), + ), child: FlowyIconButton( width: 28, hoverColor: Colors.transparent, diff --git a/frontend/app_flowy/lib/workspace/presentation/home/menu/menu_user.dart b/frontend/app_flowy/lib/workspace/presentation/home/menu/menu_user.dart index 812e648a62..4dec3ec306 100644 --- a/frontend/app_flowy/lib/workspace/presentation/home/menu/menu_user.dart +++ b/frontend/app_flowy/lib/workspace/presentation/home/menu/menu_user.dart @@ -2,9 +2,9 @@ import 'package:app_flowy/startup/startup.dart'; import 'package:app_flowy/workspace/application/menu/menu_user_bloc.dart'; import 'package:app_flowy/workspace/presentation/settings/settings_dialog.dart'; import 'package:app_flowy/workspace/presentation/settings/widgets/settings_user_view.dart'; +import 'package:flowy_infra/color_extension.dart'; import 'package:flowy_infra/image.dart'; import 'package:flowy_infra/size.dart'; -import 'package:flowy_infra/text_style.dart'; import 'package:flowy_infra_ui/style_widget/text.dart'; import 'package:flowy_infra_ui/widget/spacing.dart'; import 'package:flowy_sdk/protobuf/flowy-user/protobuf.dart' show UserProfilePB; @@ -75,7 +75,7 @@ class MenuUser extends StatelessWidget { final userProfile = context.read().state.userProfile; return Tooltip( message: LocaleKeys.settings_menu_open.tr(), - textStyle: TextStyles.caption.textColor(Colors.white), + textStyle: AFThemeExtension.of(context).caption.textColor(Colors.white), child: IconButton( onPressed: () { showDialog( diff --git a/frontend/app_flowy/lib/workspace/presentation/home/navigation.dart b/frontend/app_flowy/lib/workspace/presentation/home/navigation.dart index 9680072f20..9845d2e79a 100644 --- a/frontend/app_flowy/lib/workspace/presentation/home/navigation.dart +++ b/frontend/app_flowy/lib/workspace/presentation/home/navigation.dart @@ -3,16 +3,17 @@ import 'dart:io'; import 'package:app_flowy/generated/locale_keys.g.dart'; import 'package:app_flowy/workspace/application/home/home_bloc.dart'; import 'package:app_flowy/workspace/presentation/home/home_stack.dart'; +import 'package:flowy_infra/color_extension.dart'; import 'package:flowy_infra/image.dart'; import 'package:flowy_infra/notifier.dart'; import 'package:flowy_infra/size.dart'; -import 'package:flowy_infra/text_style.dart'; import 'package:flowy_infra_ui/style_widget/icon_button.dart'; import 'package:flowy_infra_ui/style_widget/text.dart'; import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; import 'package:styled_widget/styled_widget.dart'; import 'package:easy_localization/easy_localization.dart'; +import 'package:textstyle_extensions/textstyle_extensions.dart'; typedef NaviAction = void Function(); @@ -100,7 +101,9 @@ class FlowyNavigation extends StatelessWidget { turns: const AlwaysStoppedAnimation(180 / 360), child: Tooltip( richMessage: sidebarTooltipTextSpan( - LocaleKeys.sideBar_openSidebar.tr()), + context, + LocaleKeys.sideBar_openSidebar.tr(), + ), child: FlowyIconButton( width: 24, hoverColor: Colors.transparent, @@ -200,18 +203,16 @@ class EllipsisNaviItem extends NavigationItem { NavigationCallback get action => (id) {}; } -TextSpan sidebarTooltipTextSpan(String hintText) => TextSpan( +TextSpan sidebarTooltipTextSpan(BuildContext context, String hintText) => + TextSpan( children: [ TextSpan( text: "$hintText\n", - style: TextStyles.caption, + style: AFThemeExtension.of(context).callout.textColor(Colors.white), ), TextSpan( text: Platform.isMacOS ? "⌘+\\" : "Ctrl+\\", - style: TextStyles.general( - fontSize: FontSizes.s11, - color: Colors.white60, - ), + style: AFThemeExtension.of(context).caption.textColor(Colors.white60), ), ], ); diff --git a/frontend/app_flowy/lib/workspace/presentation/settings/widgets/settings_appearance_view.dart b/frontend/app_flowy/lib/workspace/presentation/settings/widgets/settings_appearance_view.dart index a14acd9e2d..2e7ddaa51c 100644 --- a/frontend/app_flowy/lib/workspace/presentation/settings/widgets/settings_appearance_view.dart +++ b/frontend/app_flowy/lib/workspace/presentation/settings/widgets/settings_appearance_view.dart @@ -2,11 +2,9 @@ import 'package:app_flowy/generated/locale_keys.g.dart'; import 'package:app_flowy/workspace/application/appearance.dart'; import 'package:app_flowy/workspace/presentation/widgets/toggle/toggle_style.dart'; import 'package:easy_localization/easy_localization.dart'; -import 'package:flowy_infra/size.dart'; -import 'package:flowy_infra/text_style.dart'; +import 'package:flowy_infra_ui/style_widget/text.dart'; import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; -import 'package:textstyle_extensions/textstyle_extensions.dart'; import '../../widgets/toggle/toggle.dart'; @@ -21,19 +19,13 @@ class SettingsAppearanceView extends StatelessWidget { children: [ Row( children: [ - Text( - LocaleKeys.settings_appearance_lightLabel.tr(), - style: TextStyles.body1.size(FontSizes.s14), - ), + FlowyText.medium(LocaleKeys.settings_appearance_lightLabel.tr()), Toggle( value: Theme.of(context).brightness == Brightness.dark, onChanged: (_) => setTheme(context), style: ToggleStyle.big, ), - Text( - LocaleKeys.settings_appearance_darkLabel.tr(), - style: TextStyles.body1.size(FontSizes.s14), - ), + FlowyText.medium(LocaleKeys.settings_appearance_darkLabel.tr()) ], ), ], diff --git a/frontend/app_flowy/lib/workspace/presentation/settings/widgets/settings_language_view.dart b/frontend/app_flowy/lib/workspace/presentation/settings/widgets/settings_language_view.dart index edf229bee0..2beca2105e 100644 --- a/frontend/app_flowy/lib/workspace/presentation/settings/widgets/settings_language_view.dart +++ b/frontend/app_flowy/lib/workspace/presentation/settings/widgets/settings_language_view.dart @@ -1,12 +1,10 @@ import 'package:app_flowy/generated/locale_keys.g.dart'; import 'package:app_flowy/workspace/application/appearance.dart'; import 'package:easy_localization/easy_localization.dart'; -import 'package:flowy_infra/size.dart'; -import 'package:flowy_infra/text_style.dart'; +import 'package:flowy_infra_ui/style_widget/text.dart'; import 'package:flutter/material.dart'; import 'package:flowy_infra/language.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; -import 'package:textstyle_extensions/textstyle_extensions.dart'; class SettingsLanguageView extends StatelessWidget { const SettingsLanguageView({Key? key}) : super(key: key); @@ -19,10 +17,7 @@ class SettingsLanguageView extends StatelessWidget { children: [ Row( children: [ - Text( - LocaleKeys.settings_menu_language.tr(), - style: TextStyles.body1.size(FontSizes.s14), - ), + FlowyText.medium(LocaleKeys.settings_menu_language.tr()), const LanguageSelectorDropdown(), ], ), @@ -87,10 +82,7 @@ class _LanguageSelectorDropdownState extends State { value: locale, child: Padding( padding: const EdgeInsets.all(12.0), - child: Text( - languageFromLocale(locale), - style: TextStyles.body1.size(FontSizes.s14), - ), + child: FlowyText.medium(languageFromLocale(locale)), ), ); }).toList(), diff --git a/frontend/app_flowy/lib/workspace/presentation/widgets/dialogs.dart b/frontend/app_flowy/lib/workspace/presentation/widgets/dialogs.dart index f8b91ae513..2a0241692b 100644 --- a/frontend/app_flowy/lib/workspace/presentation/widgets/dialogs.dart +++ b/frontend/app_flowy/lib/workspace/presentation/widgets/dialogs.dart @@ -1,5 +1,4 @@ import 'package:easy_localization/easy_localization.dart'; -import 'package:flowy_infra/text_style.dart'; import 'package:flowy_infra_ui/style_widget/text.dart'; import 'package:flowy_infra_ui/widget/buttons/primary_button.dart'; import 'package:flowy_infra_ui/widget/buttons/secondary_button.dart'; @@ -11,6 +10,7 @@ import 'package:flowy_infra_ui/style_widget/text_input.dart'; import 'package:flowy_infra_ui/widget/dialog/styled_dialogs.dart'; export 'package:flowy_infra_ui/widget/dialog/styled_dialogs.dart'; import 'package:app_flowy/generated/locale_keys.g.dart'; +import 'package:textstyle_extensions/textstyle_extensions.dart'; class NavigatorTextFieldDialog extends StatefulWidget { final String value; @@ -56,10 +56,8 @@ class _CreateTextFieldDialog extends State { FlowyFormTextInput( hintText: LocaleKeys.dialogCreatePageNameHint.tr(), initialValue: widget.value, - textStyle: TextStyles.general( - fontSize: 24, - fontWeight: FontWeight.w400, - ), + textStyle: + Theme.of(context).textTheme.bodySmall!.size(FontSizes.s24), autoFocus: true, onChanged: (text) { newValue = text; diff --git a/frontend/app_flowy/lib/workspace/presentation/widgets/left_bar_item.dart b/frontend/app_flowy/lib/workspace/presentation/widgets/left_bar_item.dart index d609ae6566..f1af8efef6 100644 --- a/frontend/app_flowy/lib/workspace/presentation/widgets/left_bar_item.dart +++ b/frontend/app_flowy/lib/workspace/presentation/widgets/left_bar_item.dart @@ -1,11 +1,8 @@ import 'package:app_flowy/workspace/application/view/view_listener.dart'; import 'package:app_flowy/workspace/application/view/view_service.dart'; -import 'package:flowy_infra/size.dart'; -import 'package:flowy_infra/text_style.dart'; import 'package:flowy_sdk/log.dart'; import 'package:flowy_sdk/protobuf/flowy-folder/view.pb.dart'; import 'package:flutter/material.dart'; -import 'package:textstyle_extensions/textstyle_extensions.dart'; class ViewLeftBarItem extends StatefulWidget { final ViewPB view; @@ -63,11 +60,11 @@ class _ViewLeftBarItemState extends State { focusNode: _focusNode, scrollPadding: EdgeInsets.zero, decoration: const InputDecoration( - contentPadding: EdgeInsets.zero, + contentPadding: EdgeInsets.symmetric(vertical: 4.0), border: InputBorder.none, isDense: true, ), - style: TextStyles.body1.size(FontSizes.s14), + style: Theme.of(context).textTheme.bodyMedium, // cursorColor: widget.cursorColor, // obscureText: widget.enableObscure, ), diff --git a/frontend/app_flowy/packages/flowy_infra_ui/lib/style_widget/text.dart b/frontend/app_flowy/packages/flowy_infra_ui/lib/style_widget/text.dart index b6bc836487..e8a766a57a 100644 --- a/frontend/app_flowy/packages/flowy_infra_ui/lib/style_widget/text.dart +++ b/frontend/app_flowy/packages/flowy_infra_ui/lib/style_widget/text.dart @@ -8,6 +8,7 @@ class FlowyText extends StatelessWidget { final TextAlign? textAlign; final int? maxLines; final Color? color; + final TextDecoration? decoration; const FlowyText( this.title, { @@ -18,6 +19,7 @@ class FlowyText extends StatelessWidget { this.textAlign, this.color, this.maxLines = 1, + this.decoration, }) : super(key: key); const FlowyText.regular( @@ -28,6 +30,7 @@ class FlowyText extends StatelessWidget { this.color, this.textAlign, this.maxLines = 1, + this.decoration, }) : fontWeight = FontWeight.w400, super(key: key); @@ -39,6 +42,7 @@ class FlowyText extends StatelessWidget { this.color, this.textAlign, this.maxLines = 1, + this.decoration, }) : fontWeight = FontWeight.w500, super(key: key); @@ -50,6 +54,7 @@ class FlowyText extends StatelessWidget { this.color, this.textAlign, this.maxLines = 1, + this.decoration, }) : fontWeight = FontWeight.w600, super(key: key); @@ -64,6 +69,7 @@ class FlowyText extends StatelessWidget { fontSize: fontSize, fontWeight: fontWeight, color: color, + decoration: decoration, ), ); } diff --git a/frontend/app_flowy/packages/flowy_infra_ui/lib/widget/rounded_input_field.dart b/frontend/app_flowy/packages/flowy_infra_ui/lib/widget/rounded_input_field.dart index 4c9abc7a4e..c453780fb6 100644 --- a/frontend/app_flowy/packages/flowy_infra_ui/lib/widget/rounded_input_field.dart +++ b/frontend/app_flowy/packages/flowy_infra_ui/lib/widget/rounded_input_field.dart @@ -15,7 +15,7 @@ class RoundedInputField extends StatefulWidget { final Color? cursorColor; final Color? focusBorderColor; final String errorText; - final TextStyle style; + final TextStyle? style; final ValueChanged? onChanged; final Function(String)? onEditingComplete; final String? initialValue; @@ -42,7 +42,7 @@ class RoundedInputField extends StatefulWidget { this.errorBorderColor, this.focusBorderColor, this.cursorColor, - this.style = const TextStyle(fontSize: 20, fontWeight: FontWeight.w500), + this.style, this.margin = EdgeInsets.zero, this.padding = EdgeInsets.zero, this.contentPadding = const EdgeInsets.symmetric(horizontal: 10), @@ -113,7 +113,7 @@ class _RoundedInputFieldState extends State { cursorColor: widget.cursorColor ?? Theme.of(context).colorScheme.primary, obscureText: obscuteText, - style: widget.style, + style: widget.style ?? Theme.of(context).textTheme.bodyMedium, decoration: InputDecoration( contentPadding: widget.contentPadding, hintText: widget.hintText,