mirror of
https://github.com/Dr-Blank/Vaani.git
synced 2025-12-07 03:29:29 +00:00
fix: bug login not shown for some languages (#73)
* fix language preventing logging in * make eye blink once
This commit is contained in:
parent
4663ff9094
commit
28ceca5408
4 changed files with 162 additions and 132 deletions
|
|
@ -13,6 +13,37 @@ class OnboardingSinglePage extends HookConsumerWidget {
|
||||||
super.key,
|
super.key,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context, WidgetRef ref) {
|
||||||
|
return Scaffold(
|
||||||
|
body: LayoutBuilder(
|
||||||
|
builder: (BuildContext context, BoxConstraints constraints) {
|
||||||
|
return Center(
|
||||||
|
child: SingleChildScrollView(
|
||||||
|
child: ConstrainedBox(
|
||||||
|
constraints: BoxConstraints(
|
||||||
|
maxWidth: 600,
|
||||||
|
minWidth:
|
||||||
|
constraints.maxWidth < 600 ? constraints.maxWidth : 0,
|
||||||
|
),
|
||||||
|
child: const Padding(
|
||||||
|
padding: EdgeInsets.symmetric(vertical: 20.0),
|
||||||
|
child: SafeArea(child: OnboardingBody()),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
||||||
|
},
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
class OnboardingBody extends HookConsumerWidget {
|
||||||
|
const OnboardingBody({
|
||||||
|
super.key,
|
||||||
|
});
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context, WidgetRef ref) {
|
Widget build(BuildContext context, WidgetRef ref) {
|
||||||
final apiSettings = ref.watch(apiSettingsProvider);
|
final apiSettings = ref.watch(apiSettingsProvider);
|
||||||
|
|
@ -39,10 +70,9 @@ class OnboardingSinglePage extends HookConsumerWidget {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
return Scaffold(
|
return Column(
|
||||||
body: SingleChildScrollView(
|
|
||||||
child: Column(
|
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
|
crossAxisAlignment: CrossAxisAlignment.center,
|
||||||
children: [
|
children: [
|
||||||
Padding(
|
Padding(
|
||||||
padding: const EdgeInsets.all(8.0),
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
|
@ -82,6 +112,9 @@ class OnboardingSinglePage extends HookConsumerWidget {
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
const SizedBox.square(
|
||||||
|
dimension: 16.0,
|
||||||
|
),
|
||||||
AnimatedSwitcher(
|
AnimatedSwitcher(
|
||||||
duration: 500.ms,
|
duration: 500.ms,
|
||||||
transitionBuilder: fadeSlideTransitionBuilder,
|
transitionBuilder: fadeSlideTransitionBuilder,
|
||||||
|
|
@ -96,8 +129,6 @@ class OnboardingSinglePage extends HookConsumerWidget {
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
),
|
|
||||||
),
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -130,11 +130,11 @@ class UserLoginMultipleAuth extends HookConsumerWidget {
|
||||||
return Center(
|
return Center(
|
||||||
child: InactiveFocusScopeObserver(
|
child: InactiveFocusScopeObserver(
|
||||||
child: AutofillGroup(
|
child: AutofillGroup(
|
||||||
child: Padding(
|
|
||||||
padding: const EdgeInsets.all(8.0),
|
|
||||||
child: Column(
|
child: Column(
|
||||||
children: [
|
children: [
|
||||||
Wrap(
|
Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: Wrap(
|
||||||
// mainAxisAlignment: MainAxisAlignment.center,
|
// mainAxisAlignment: MainAxisAlignment.center,
|
||||||
spacing: 10,
|
spacing: 10,
|
||||||
runAlignment: WrapAlignment.center,
|
runAlignment: WrapAlignment.center,
|
||||||
|
|
@ -174,10 +174,11 @@ class UserLoginMultipleAuth extends HookConsumerWidget {
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
const SizedBox.square(
|
|
||||||
dimension: 8,
|
|
||||||
),
|
),
|
||||||
switch (methodChoice.value) {
|
|
||||||
|
Padding(
|
||||||
|
padding: const EdgeInsets.all(8.0),
|
||||||
|
child: switch (methodChoice.value) {
|
||||||
AuthMethodChoice.authToken => UserLoginWithToken(
|
AuthMethodChoice.authToken => UserLoginWithToken(
|
||||||
server: server,
|
server: server,
|
||||||
addServer: addServer,
|
addServer: addServer,
|
||||||
|
|
@ -192,8 +193,8 @@ class UserLoginMultipleAuth extends HookConsumerWidget {
|
||||||
openIDButtonText: openIDButtonText,
|
openIDButtonText: openIDButtonText,
|
||||||
),
|
),
|
||||||
},
|
},
|
||||||
],
|
|
||||||
),
|
),
|
||||||
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -29,6 +29,7 @@ class UserLoginWithPassword extends HookConsumerWidget {
|
||||||
final usernameController = useTextEditingController();
|
final usernameController = useTextEditingController();
|
||||||
final passwordController = useTextEditingController();
|
final passwordController = useTextEditingController();
|
||||||
final isPasswordVisibleAnimationController = useAnimationController(
|
final isPasswordVisibleAnimationController = useAnimationController(
|
||||||
|
initialValue: 1,
|
||||||
duration: const Duration(milliseconds: 500),
|
duration: const Duration(milliseconds: 500),
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
@ -92,8 +93,6 @@ class UserLoginWithPassword extends HookConsumerWidget {
|
||||||
return Center(
|
return Center(
|
||||||
child: InactiveFocusScopeObserver(
|
child: InactiveFocusScopeObserver(
|
||||||
child: AutofillGroup(
|
child: AutofillGroup(
|
||||||
child: Padding(
|
|
||||||
padding: const EdgeInsets.all(8.0),
|
|
||||||
child: Column(
|
child: Column(
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
children: [
|
children: [
|
||||||
|
|
@ -164,7 +163,6 @@ class UserLoginWithPassword extends HookConsumerWidget {
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
2
shelfsdk
2
shelfsdk
|
|
@ -1 +1 @@
|
||||||
Subproject commit ac8e94df7b28c4334165a11c3b445cd0cc497495
|
Subproject commit 5cc545ca87c05615473ab9c363cfa29e341d1e2a
|
||||||
Loading…
Add table
Add a link
Reference in a new issue