improvements

export_module_ui_ux_enhancement_signup
Sikander Saleem 3 days ago
parent 189bc7889a
commit f38ae9560d

@ -4,6 +4,7 @@ import 'package:provider/provider.dart';
import 'package:test_sa/extensions/context_extension.dart'; import 'package:test_sa/extensions/context_extension.dart';
import 'package:test_sa/extensions/enum_extensions.dart'; import 'package:test_sa/extensions/enum_extensions.dart';
import 'package:test_sa/extensions/int_extensions.dart'; import 'package:test_sa/extensions/int_extensions.dart';
import 'package:test_sa/extensions/text_extensions.dart';
import 'package:test_sa/extensions/widget_extensions.dart'; import 'package:test_sa/extensions/widget_extensions.dart';
import 'package:test_sa/new_views/app_style/app_text_style.dart'; import 'package:test_sa/new_views/app_style/app_text_style.dart';
import 'package:test_sa/new_views/common_widgets/app_loading_manager.dart'; import 'package:test_sa/new_views/common_widgets/app_loading_manager.dart';
@ -262,7 +263,7 @@ class _SingleItemDropDownMenuState<T extends Base, X extends LoadingListNotifier
isExpanded: true, isExpanded: true,
hint: Text( hint: Text(
isEmpty || widget.enabled == false ? context.translation.noDataFound : context.translation.select, isEmpty || widget.enabled == false ? context.translation.noDataFound : context.translation.select,
style: Theme.of(context).textTheme.bodyLarge, style: AppTextStyles.heading5.copyWith(color: AppColor.textStyleColor(context)),
), ),
style: TextStyle(color: Theme.of(context).primaryColor, fontSize: 12), style: TextStyle(color: Theme.of(context).primaryColor, fontSize: 12),
underline: const SizedBox.shrink(), underline: const SizedBox.shrink(),
@ -280,12 +281,12 @@ class _SingleItemDropDownMenuState<T extends Base, X extends LoadingListNotifier
items: ((X == NullableLoadingProvider) ? widget.staticData : provider?.items as List<T>)?.map<DropdownMenuItem<T>>((value) { items: ((X == NullableLoadingProvider) ? widget.staticData : provider?.items as List<T>)?.map<DropdownMenuItem<T>>((value) {
return DropdownMenuItem<T>( return DropdownMenuItem<T>(
value: value, value: value,
child: Text( child: Text(value.name ?? "", // Null-aware operator for value.name
value.name ?? "", // Null-aware operator for value.name maxLines: 1,
maxLines: 1, overflow: TextOverflow.ellipsis,
overflow: TextOverflow.ellipsis, style: AppTextStyles.heading5.copyWith(color: AppColor.textStyleColor(context))
style: Theme.of(context).textTheme.bodyMedium?.copyWith(fontWeight: FontWeight.w500, color: context.isDark ? AppColor.white10 : AppColor.black10), // Theme.of(context).textTheme.bodyMedium?.copyWith(fontWeight: FontWeight.w500, color: context.isDark ? AppColor.white10 : AppColor.black10),
), ),
); );
}).toList(), }).toList(),
), ),

@ -246,19 +246,45 @@ class _LoginPageState extends State<LoginPage> {
16.height, 16.height,
AppFilledButton(label: context.translation.signIn, buttonColor: AppColor.primary10, maxWidth: true, onPressed: _login), AppFilledButton(label: context.translation.signIn, buttonColor: AppColor.primary10, maxWidth: true, onPressed: _login),
16.height, 16.height,
Row( Text.rich(
mainAxisAlignment: MainAxisAlignment.center, TextSpan(
children: [ children: [
"Don't have an account? ".bodyText(context).custom(color: AppColor.textStyleColor(context)), TextSpan(text: "Don't have an account? ", style: AppTextStyles.bodyText.copyWith(color: AppColor.textStyleColor(context))),
"Sign Up".bodyText(context).custom(color: AppColor.primary10, fontWeight: FontWeight.w600).onPress(() { TextSpan(
Navigator.pushNamed(context, SignUpScreen.routeName); text: "Sign Up",
}), style: AppTextStyles.bodyText.copyWith(color: AppColor.primary10),
" OR ".bodyText(context).custom(color: AppColor.textStyleColor(context)), recognizer: TapGestureRecognizer()
"Request a Demo".bodyText(context).custom(color: AppColor.primary10, fontWeight: FontWeight.w600).onPress(() { ..onTap = () {
Navigator.pushNamed(context, ApplicationDemoRequestFormScreen.routeName); Navigator.pushNamed(context, SignUpScreen.routeName);
}), }),
], TextSpan(
), text: " OR ",
style: AppTextStyles.bodyText.copyWith(color: AppColor.textStyleColor(context)),
),
TextSpan(
text: "Request a Demo",
style: AppTextStyles.bodyText.copyWith(color: AppColor.primary10),
recognizer: TapGestureRecognizer()
..onTap = () {
Navigator.pushNamed(context, ApplicationDemoRequestFormScreen.routeName);
}),
],
),
// textAlign: TextAlign.center, // Direct alignment parameter
).center,
// Row(
// mainAxisAlignment: MainAxisAlignment.center,
// children: [
// "Don't have an account? ".bodyText(context).custom(color: AppColor.textStyleColor(context)),
// "Sign Up".bodyText(context).custom(color: AppColor.primary10, fontWeight: FontWeight.w600).onPress(() {
// Navigator.pushNamed(context, SignUpScreen.routeName);
// }),
// " OR ".bodyText(context).custom(color: AppColor.textStyleColor(context)),
// "Request a Demo".bodyText(context).custom(color: AppColor.primary10, fontWeight: FontWeight.w600).onPress(() {
// Navigator.pushNamed(context, ApplicationDemoRequestFormScreen.routeName);
// }),
// ],
// ),
// Demo Request Button // Demo Request Button
24.height, 24.height,

Loading…
Cancel
Save