Better Home view too
This commit is contained in:
@@ -30,34 +30,76 @@ class _HomeScreenState extends State<HomeScreen> {
|
|||||||
'assets/images/cluster-photo-00.jpg',
|
'assets/images/cluster-photo-00.jpg',
|
||||||
fit: BoxFit.cover,
|
fit: BoxFit.cover,
|
||||||
),
|
),
|
||||||
|
Container(
|
||||||
|
color: Colors.black.withOpacity(0.4), // dim overlay
|
||||||
|
),
|
||||||
Center(
|
Center(
|
||||||
child: Padding(
|
child: Padding(
|
||||||
padding: const EdgeInsets.all(16.0),
|
padding: const EdgeInsets.symmetric(horizontal: 24.0),
|
||||||
child: Column(
|
child: Column(
|
||||||
mainAxisSize: MainAxisSize.min,
|
mainAxisSize: MainAxisSize.min,
|
||||||
children: [
|
children: [
|
||||||
TextField(
|
const Text(
|
||||||
controller: _controller,
|
"🔍 Look up a 42 student",
|
||||||
decoration: const InputDecoration(
|
style: TextStyle(
|
||||||
hintText: 'Enter login',
|
fontSize: 24,
|
||||||
border: OutlineInputBorder(),
|
fontWeight: FontWeight.bold,
|
||||||
filled: true,
|
color: Colors.white,
|
||||||
fillColor: Colors.white,
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
const SizedBox(height: 10),
|
const SizedBox(height: 24),
|
||||||
ElevatedButton(
|
TextField(
|
||||||
onPressed: () {
|
controller: _controller,
|
||||||
_handleInput(context, _controller.text);
|
style: const TextStyle(color: Colors.black),
|
||||||
},
|
decoration: InputDecoration(
|
||||||
child: const Text('Submit'),
|
hintText: 'Enter login',
|
||||||
|
filled: true,
|
||||||
|
fillColor: Colors.white,
|
||||||
|
border: OutlineInputBorder(
|
||||||
|
borderRadius: BorderRadius.circular(12),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
const SizedBox(height: 16),
|
||||||
|
SizedBox(
|
||||||
|
width: double.infinity,
|
||||||
|
child: ElevatedButton(
|
||||||
|
onPressed: () {
|
||||||
|
_handleInput(context, _controller.text);
|
||||||
|
},
|
||||||
|
style: ElevatedButton.styleFrom(
|
||||||
|
padding: const EdgeInsets.symmetric(vertical: 14),
|
||||||
|
shape: RoundedRectangleBorder(
|
||||||
|
borderRadius: BorderRadius.circular(12),
|
||||||
|
),
|
||||||
|
backgroundColor: Colors.blueAccent,
|
||||||
|
),
|
||||||
|
child: const Text(
|
||||||
|
'Submit',
|
||||||
|
style: TextStyle(fontSize: 16),
|
||||||
|
),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
Positioned(
|
||||||
|
bottom: 12,
|
||||||
|
right: 12,
|
||||||
|
child: Text(
|
||||||
|
"Made by vvaas",
|
||||||
|
style: TextStyle(
|
||||||
|
color: Colors.white.withOpacity(0.7),
|
||||||
|
fontSize: 12,
|
||||||
|
fontStyle: FontStyle.italic,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Reference in New Issue
Block a user