removed decorations from title bar and chaged constant colors to themes

This commit is contained in:
asif
2025-08-30 01:31:56 +05:30
parent bfa0721e79
commit 53caa5b7ae

View File

@@ -32,36 +32,10 @@ class _AccountInfoScreen extends State<AccountInfoScreen> {
int selectedIndex = widget.selectedIndex; int selectedIndex = widget.selectedIndex;
return Scaffold( return Scaffold(
appBar: AppBar( appBar: AppBar(
leading: IconButton(
icon: const Icon(Symbols.arrow_back_ios_new),
onPressed: () {
Navigator.pop(context);
},
),
title: Text( title: Text(
AppLocalizations.of(context).accountInfo, AppLocalizations.of(context).accountInfo,
style: const TextStyle(
color: Colors.black,
fontWeight: FontWeight.w500,
), ),
), ),
centerTitle: false,
actions: [
Padding(
padding: const EdgeInsets.only(right: 10.0),
child: CircleAvatar(
backgroundColor: Colors.grey[200],
radius: 20,
child: SvgPicture.asset(
'assets/images/avatar_male.svg',
width: 40,
height: 40,
fit: BoxFit.cover,
),
),
),
],
),
body: ListView( body: ListView(
padding: const EdgeInsets.all(16.0), padding: const EdgeInsets.all(16.0),
children: [ children: [
@@ -70,7 +44,6 @@ class _AccountInfoScreen extends State<AccountInfoScreen> {
style: const TextStyle(fontWeight: FontWeight.w500, fontSize: 14), style: const TextStyle(fontWeight: FontWeight.w500, fontSize: 14),
), ),
/// Dropdown to change account
DropdownButton<User>( DropdownButton<User>(
value: selectedUser, value: selectedUser,
onChanged: (User? newUser) { onChanged: (User? newUser) {
@@ -130,6 +103,7 @@ class InfoRow extends StatelessWidget {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
final theme = Theme.of(context);
return Container( return Container(
width: double.infinity, width: double.infinity,
margin: const EdgeInsets.symmetric(vertical: 8), margin: const EdgeInsets.symmetric(vertical: 8),
@@ -138,16 +112,16 @@ class InfoRow extends StatelessWidget {
children: [ children: [
Text( Text(
title, title,
style: const TextStyle( style: TextStyle(
fontSize: 15, fontSize: 15,
fontWeight: FontWeight.w500, fontWeight: FontWeight.w500,
color: Colors.black87, color: theme.colorScheme.onSurfaceVariant,
), ),
), ),
const SizedBox(height: 3), const SizedBox(height: 3),
Text( Text(
value, value,
style: const TextStyle(fontSize: 16, color: Colors.black), style: TextStyle(fontSize: 16, color: theme.colorScheme.onSurface),
), ),
], ],
), ),