Fix sign-in, title bar, formatting
This commit is contained in:
parent
e996702408
commit
de8d898289
@ -67,10 +67,8 @@ Future<bool> isLoggedIn(BuildContext context) async {
|
|||||||
final prefs = await SharedPreferences.getInstance();
|
final prefs = await SharedPreferences.getInstance();
|
||||||
|
|
||||||
final token = prefs.getString('token');
|
final token = prefs.getString('token');
|
||||||
if (token == null){
|
if (token == null) {
|
||||||
prefs.remove('id');
|
prefs.remove('id');
|
||||||
loggedIn = false;
|
|
||||||
user = User as User?;
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -52,21 +52,16 @@ class _SideMenuState extends State<SideMenu> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
appBar: AppBar(
|
appBar: AppBar(
|
||||||
backgroundColor: Theme.of(context).colorScheme.inversePrimary,
|
backgroundColor: Theme.of(context).colorScheme.inversePrimary,
|
||||||
title: Row(
|
title: Text('SkanTravels',
|
||||||
children: [
|
|
||||||
const SizedBox(width: 55),
|
|
||||||
Text('SkanTravels',
|
|
||||||
style: GoogleFonts.jacquesFrancois(
|
style: GoogleFonts.jacquesFrancois(
|
||||||
fontSize: 30,
|
fontSize: 30,
|
||||||
color: Colors.black,
|
color: Colors.black,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
drawer: Drawer(
|
drawer: Drawer(
|
||||||
child: ListView(
|
child: ListView(
|
||||||
@ -148,5 +143,5 @@ Widget build(BuildContext context) {
|
|||||||
),
|
),
|
||||||
body: widget.body,
|
body: widget.body,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Reference in New Issue
Block a user