Move login/signup back buttons closer to center of screen (#5496)

This commit is contained in:
Kelrap 2026-01-28 14:33:56 -05:00 committed by GitHub
parent bbda3b646b
commit 4daee5a6de
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 88 additions and 10 deletions

View file

@ -19,12 +19,26 @@ class SpaceCodeOnboardingView extends StatelessWidget {
Widget build(BuildContext context) {
return PangeaLoginScaffold(
customAppBar: AppBar(
leading: BackButton(
onPressed: () => pLogoutAction(
context,
bypassWarning: true,
title: ConstrainedBox(
constraints: const BoxConstraints(
maxWidth: 450,
),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
BackButton(
onPressed: () => pLogoutAction(
context,
bypassWarning: true,
),
),
const SizedBox(
width: 40.0,
),
],
),
),
automaticallyImplyLeading: false,
),
showAppName: false,
mainAssetUrl: controller.profile?.avatarUrl,

View file

@ -21,9 +21,24 @@ class LoginOptionsView extends StatelessWidget {
final theme = Theme.of(context);
return Scaffold(
appBar: AppBar(
title: Text(
L10n.of(context).loginToAccount,
title: ConstrainedBox(
constraints: const BoxConstraints(
maxWidth: 450,
),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
BackButton(
onPressed: Navigator.of(context).pop,
),
Text(L10n.of(context).loginToAccount),
const SizedBox(
width: 40.0,
),
],
),
),
automaticallyImplyLeading: false,
),
body: SafeArea(
child: Center(

View file

@ -15,9 +15,24 @@ class PasswordLoginView extends StatelessWidget {
key: controller.formKey,
child: Scaffold(
appBar: AppBar(
title: Text(
L10n.of(context).loginWithEmail,
title: ConstrainedBox(
constraints: const BoxConstraints(
maxWidth: 450,
),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
BackButton(
onPressed: Navigator.of(context).pop,
),
Text(L10n.of(context).loginWithEmail),
const SizedBox(
width: 40.0,
),
],
),
),
automaticallyImplyLeading: false,
),
body: SafeArea(
child: Center(

View file

@ -27,7 +27,23 @@ class SignupPageView extends StatelessWidget {
return Form(
key: controller.formKey,
child: Scaffold(
appBar: AppBar(),
appBar: AppBar(
title: SizedBox(
width: 450,
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
BackButton(
onPressed: Navigator.of(context).pop,
),
const SizedBox(
width: 40.0,
),
],
),
),
automaticallyImplyLeading: false,
),
body: SafeArea(
child: Center(
child: ConstrainedBox(

View file

@ -15,7 +15,25 @@ class SignupWithEmailView extends StatelessWidget {
return Form(
key: controller.formKey,
child: Scaffold(
appBar: AppBar(),
appBar: AppBar(
title: ConstrainedBox(
constraints: const BoxConstraints(
maxWidth: 450,
),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
BackButton(
onPressed: Navigator.of(context).pop,
),
const SizedBox(
width: 40.0,
),
],
),
),
automaticallyImplyLeading: false,
),
body: SafeArea(
child: Center(
child: ConstrainedBox(