feature(gui): adjusted color settings for buttons and settings screen

This commit is contained in:
Patryk Hegenberg 2024-05-27 22:25:13 +02:00
parent d9501024db
commit cd43fd6041
3 changed files with 34 additions and 7 deletions

View file

@ -183,7 +183,7 @@ class ReceiveScreenState extends State<ReceiveScreen> {
ElevatedButton( ElevatedButton(
style: ElevatedButton.styleFrom( style: ElevatedButton.styleFrom(
backgroundColor: Constants.textColor, backgroundColor: Constants.textColor,
foregroundColor: Constants.highlightColor, foregroundColor: Constants.backColor,
shape: RoundedRectangleBorder( shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(20), borderRadius: BorderRadius.circular(20),
), ),

View file

@ -106,7 +106,7 @@ class SendScreenState extends State<SendScreen> {
ElevatedButton( ElevatedButton(
style: ElevatedButton.styleFrom( style: ElevatedButton.styleFrom(
backgroundColor: Constants.textColor, backgroundColor: Constants.textColor,
foregroundColor: Constants.highlightColor, foregroundColor: Constants.backColor,
shape: RoundedRectangleBorder( shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(20), borderRadius: BorderRadius.circular(20),
), ),

View file

@ -1,5 +1,6 @@
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:shared_preferences/shared_preferences.dart'; import 'package:shared_preferences/shared_preferences.dart';
import 'package:flutter_test_gui/consts/consts.dart';
class SettingsScreen extends StatefulWidget { class SettingsScreen extends StatefulWidget {
@override @override
@ -50,8 +51,11 @@ class _SettingsScreenState extends State<SettingsScreen> {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
return Scaffold( return Scaffold(
backgroundColor: Constants.backColor,
appBar: AppBar( appBar: AppBar(
title: const Text('Settings'), title: const Text('Settings'),
backgroundColor: const Color(0xFF292c3c), //0xFF282C34),
foregroundColor: Constants.textColor,
), ),
body: Padding( body: Padding(
padding: const EdgeInsets.all(16.0), padding: const EdgeInsets.all(16.0),
@ -59,25 +63,48 @@ class _SettingsScreenState extends State<SettingsScreen> {
children: [ children: [
TextField( TextField(
controller: _appEnvironmentController, controller: _appEnvironmentController,
decoration: const InputDecoration(labelText: 'App Environment'), decoration: const InputDecoration(
labelText: 'App Environment',
labelStyle: TextStyle(color: Constants.highlightColor)),
style: const TextStyle(color: Constants.textColor),
), ),
TextField( TextField(
controller: _appHostController, controller: _appHostController,
decoration: const InputDecoration(labelText: 'App Host'), decoration: const InputDecoration(
labelText: 'App Host',
labelStyle: TextStyle(color: Constants.highlightColor)),
style: const TextStyle(color: Constants.textColor),
), ),
TextField( TextField(
controller: _appPortController, controller: _appPortController,
decoration: const InputDecoration(labelText: 'App Port'), decoration: const InputDecoration(
labelText: 'App Port',
labelStyle: TextStyle(color: Constants.highlightColor)),
style: const TextStyle(color: Constants.textColor),
), ),
TextField( TextField(
controller: _appOriginController, controller: _appOriginController,
decoration: const InputDecoration(labelText: 'App Origin'), decoration: const InputDecoration(
labelText: 'App Origin',
labelStyle: TextStyle(color: Constants.highlightColor)),
style: const TextStyle(color: Constants.textColor),
), ),
TextField( TextField(
controller: _appRelayController, controller: _appRelayController,
decoration: const InputDecoration(labelText: 'App Relay'), decoration: const InputDecoration(
labelText: 'App Relay',
labelStyle: TextStyle(color: Constants.highlightColor)),
style: const TextStyle(color: Constants.textColor),
), ),
Spacer(),
ElevatedButton( ElevatedButton(
style: ElevatedButton.styleFrom(
backgroundColor: Constants.textColor,
foregroundColor: Constants.backColor,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(20),
),
),
onPressed: () async { onPressed: () async {
await saveSettings(); await saveSettings();
Navigator.pop(context); Navigator.pop(context);