move biometrics to appbar

This commit is contained in:
ryleedavis 2023-05-04 16:17:00 -06:00
parent 8fd0caac44
commit 8d7db30328

View file

@ -55,7 +55,6 @@ class LockscreenView extends ConsumerStatefulWidget {
final VoidCallback? onSuccess; final VoidCallback? onSuccess;
final String customKeyLabel; final String customKeyLabel;
@override @override
ConsumerState<LockscreenView> createState() => _LockscreenViewState(); ConsumerState<LockscreenView> createState() => _LockscreenViewState();
} }
@ -223,18 +222,21 @@ class _LockscreenViewState extends ConsumerState<LockscreenView> {
}, },
) )
: Container(), : Container(),
), actions: [
body: SafeArea( // check prefs and hide if user has biometrics toggle off?
child: Column( Column(
mainAxisAlignment: MainAxisAlignment.center, mainAxisAlignment: MainAxisAlignment.center,
children: [ children: [
// check prefs and hide if user has biometrics toggle off?
Padding( Padding(
padding: const EdgeInsets.only(right: 40.0), padding: const EdgeInsets.only(
right: 16.0,
),
child: Row( child: Row(
mainAxisAlignment: MainAxisAlignment.end, mainAxisAlignment: MainAxisAlignment.end,
children: [ children: [
if (ref.read(prefsChangeNotifierProvider).useBiometrics == if (ref
.read(prefsChangeNotifierProvider)
.useBiometrics ==
true) true)
CustomTextButton( CustomTextButton(
text: "Use biometrics", text: "Use biometrics",
@ -245,9 +247,14 @@ class _LockscreenViewState extends ConsumerState<LockscreenView> {
], ],
), ),
), ),
const SizedBox( ],
height: 55,
), ),
],
),
body: SafeArea(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Shake( Shake(
animationDuration: const Duration(milliseconds: 700), animationDuration: const Duration(milliseconds: 700),
animationRange: 12, animationRange: 12,