This commit is contained in:
Nopylacetat
2023-10-20 19:25:44 +02:00
parent b4e49ea4ff
commit 96c4635254
2 changed files with 11 additions and 9 deletions

View File

@@ -16,7 +16,8 @@ class Application extends StatelessWidget {
return MaterialApp( return MaterialApp(
title: 'Maggs\' Victory Voyage', title: 'Maggs\' Victory Voyage',
theme: ThemeData( theme: ThemeData(
colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepPurple), colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepPurple)
.copyWith(background: Colors.pink[50]),
useMaterial3: true, useMaterial3: true,
), ),
home: const SplashPage(), home: const SplashPage(),

View File

@@ -15,23 +15,24 @@ class LoginPage extends StatelessWidget {
width: width / 2, width: width / 2,
child: Column( child: Column(
children: [ children: [
const Text('Please enter your first name', const Text('Welcome!',
style: TextStyle( style: TextStyle(
color: Colors.pink, fontSize: 35,
fontWeight: FontWeight.bold,
color: Colors.white,
)), )),
const Padding(padding: EdgeInsets.symmetric(vertical: 20)),
TextField( TextField(
controller: username, controller: username,
decoration: const InputDecoration( decoration: const InputDecoration(
label: Text('Username!'), label: Text('Username'),
border: OutlineInputBorder(),
), ),
), ),
TextButton( const Padding(padding: EdgeInsets.symmetric(vertical: 20)),
ElevatedButton(
onPressed: () => DbHelper.login(username.text), onPressed: () => DbHelper.login(username.text),
child: const Text('Login'), child: const Text('Login'),
),
TextButton(
onPressed: () => DbHelper.logout(),
child: const Text('Logout'),
) )
], ],
), ),