diff --git a/lib/home.dart b/lib/home.dart index 7162f95..90c4dd4 100644 --- a/lib/home.dart +++ b/lib/home.dart @@ -1,5 +1,4 @@ import 'package:flutter/material.dart'; -import 'package:flutterfire_ui/auth.dart'; import 'package:persistent_bottom_nav_bar/persistent_tab_view.dart'; import 'package:ruswipeshare/sell.dart'; import 'profile_screen_custom.dart'; diff --git a/lib/profile_screen_custom.dart b/lib/profile_screen_custom.dart index 964e273..d30657d 100644 --- a/lib/profile_screen_custom.dart +++ b/lib/profile_screen_custom.dart @@ -2,10 +2,13 @@ // for details. All rights reserved. Use of this source code is governed by a // BSD-style license that can be found in the LICENSE file. +// ignore_for_file: implementation_imports + import 'package:firebase_auth/firebase_auth.dart' show ActionCodeSettings, FirebaseAuth, FirebaseAuthException, User; import 'package:flutter/cupertino.dart' hide Title; -import 'package:flutterfire_ui/i10n.dart'; +import 'package:flutter/material.dart'; import 'package:flutter/material.dart' hide Title; +import 'package:flutter_credit_card/flutter_credit_card.dart'; import 'package:flutterfire_ui/auth.dart'; import 'package:flutterfire_ui/src/auth/widgets/internal/loading_button.dart'; @@ -111,10 +114,13 @@ class _EmailVerificationBadgeState extends State { if (state == EmailVerificationState.pending) Row( mainAxisAlignment: MainAxisAlignment.center, - children: const [ - LoadingIndicator(size: 16, borderWidth: 0.5), - SizedBox(width: 16), - Text('Waiting for email verification'), + children: [ + const SizedBox(width: 16), + Wrap( + children: const [ + Text('Log out and log back in to confirm.'), + ], + ), ], ) else @@ -216,12 +222,12 @@ class ProfileScreenCustom extends MultiProviderScreen { final user = auth.currentUser!; final content = Column( - crossAxisAlignment: CrossAxisAlignment.stretch, + crossAxisAlignment: CrossAxisAlignment.center, children: [ Align( child: UserAvatar( auth: auth, - placeholderColor: avatarPlaceholderColor, + placeholderColor: Theme.of(context).colorScheme.primary, shape: avatarShape, size: avatarSize, ), @@ -243,10 +249,13 @@ class ProfileScreenCustom extends MultiProviderScreen { ), ], ...children, - const SizedBox(height: 16), - SignOutButton( - auth: auth, - variant: ButtonVariant.outlined, + const SizedBox(height: 300), + Align( + alignment: Alignment.bottomCenter, + child: SignOutButton( + auth: auth, + variant: ButtonVariant.filled, + ), ), const SizedBox(height: 8), ], @@ -257,8 +266,7 @@ class ProfileScreenCustom extends MultiProviderScreen { child: LayoutBuilder( builder: (context, constraints) { if (constraints.maxWidth > 500) { - return ConstrainedBox( - constraints: const BoxConstraints(maxWidth: 500), + return Expanded( child: content, ); } else { diff --git a/pubspec.lock b/pubspec.lock index 4c9d6c4..c4056d9 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -206,6 +206,14 @@ packages: description: flutter source: sdk version: "0.0.0" + flutter_credit_card: + dependency: "direct main" + description: + name: flutter_credit_card + sha256: "0fc71e8bfb0e126d2c4247830c04e2acf2b831161411a361e9fa9dc1cc41e605" + url: "https://pub.dev" + source: hosted + version: "3.0.5" flutter_dotenv: dependency: "direct main" description: diff --git a/pubspec.yaml b/pubspec.yaml index d8761c8..f84f51f 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -40,6 +40,7 @@ dependencies: flutterfire_ui: ^0.4.3+20 flutter_dotenv: ^5.0.2 persistent_bottom_nav_bar: any + flutter_credit_card: any dev_dependencies: flutter_test: