diff --git a/lib/consts.dart b/lib/consts.dart index 5f896a42..6330eef2 100644 --- a/lib/consts.dart +++ b/lib/consts.dart @@ -3,16 +3,12 @@ import 'package:google_fonts/google_fonts.dart'; final kColorTransparent = MaterialStateProperty.all(Colors.transparent); const kColorBg = Colors.white; -final kColorGrey50 = Colors.grey.shade50; final kColorGrey100 = Colors.grey.shade100; -final kColorGrey200 = Colors.grey.shade200; -final kColorGrey300 = Colors.grey.shade300; -final kColorGrey400 = Colors.grey.shade400; final kColorGrey500 = Colors.grey.shade500; -final kColorErrorMsg = kColorGrey500; final kCodeStyle = GoogleFonts.sourceCodePro(); final kCodeHintStyle = kCodeStyle.copyWith(color: kColorGrey500); +const kHintOpacity = 0.6; const kTextStyleButton = TextStyle(fontWeight: FontWeight.bold); diff --git a/lib/main.dart b/lib/main.dart index 327b1fcd..77018fba 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -29,6 +29,7 @@ class App extends StatelessWidget { fontFamily: GoogleFonts.openSans().fontFamily, colorSchemeSeed: Colors.blue, useMaterial3: true, + brightness: Brightness.light, ), home: const HomePage(), ); diff --git a/lib/screens/home_page/editor_pane/details_card/details_card.dart b/lib/screens/home_page/editor_pane/details_card/details_card.dart index c6a59668..6ae18385 100644 --- a/lib/screens/home_page/editor_pane/details_card/details_card.dart +++ b/lib/screens/home_page/editor_pane/details_card/details_card.dart @@ -35,8 +35,10 @@ class _EditorPaneRequestDetailsCardState data: MultiSplitViewThemeData( dividerThickness: 3, dividerPainter: DividerPainters.background( - color: kColorGrey200, - highlightedColor: kColorGrey400, + color: Theme.of(context).colorScheme.surfaceVariant, + highlightedColor: Theme.of(context).colorScheme.outline.withOpacity( + kHintOpacity, + ), animationEnabled: false, ), ), diff --git a/lib/screens/home_page/editor_pane/url_card.dart b/lib/screens/home_page/editor_pane/url_card.dart index 3c95de24..5c924ab5 100644 --- a/lib/screens/home_page/editor_pane/url_card.dart +++ b/lib/screens/home_page/editor_pane/url_card.dart @@ -71,14 +71,14 @@ class _DropdownButtonHTTPMethodState @override Widget build(BuildContext context) { - final Color color = Theme.of(context).colorScheme.surface; + final surfaceColor = Theme.of(context).colorScheme.surface; final activeId = ref.watch(activeIdStateProvider); final collection = ref.read(collectionStateNotifierProvider); final idIdx = collection.indexWhere((m) => m.id == activeId); final method = ref.watch( collectionStateNotifierProvider.select((value) => value[idIdx].method)); return DropdownButton( - focusColor: color, + focusColor: surfaceColor, value: method, icon: const Icon(Icons.unfold_more_rounded), elevation: 4, @@ -136,7 +136,11 @@ class _URLTextFieldState extends ConsumerState { style: kCodeStyle, decoration: InputDecoration( hintText: "Enter API endpoint like api.foss42.com/country/codes", - hintStyle: kCodeHintStyle, + hintStyle: kCodeStyle.copyWith( + color: Theme.of(context).colorScheme.outline.withOpacity( + kHintOpacity, + ), + ), border: InputBorder.none, ), onChanged: (value) { diff --git a/lib/screens/home_page/home_page.dart b/lib/screens/home_page/home_page.dart index c04176f6..13dee374 100644 --- a/lib/screens/home_page/home_page.dart +++ b/lib/screens/home_page/home_page.dart @@ -32,10 +32,13 @@ class HomePageState extends State { Expanded( child: MultiSplitViewTheme( data: MultiSplitViewThemeData( - dividerThickness: 4, + dividerThickness: 3, dividerPainter: DividerPainters.background( - color: kColorGrey200, - highlightedColor: kColorGrey400, + color: Theme.of(context).colorScheme.surfaceVariant, + highlightedColor: + Theme.of(context).colorScheme.outline.withOpacity( + kHintOpacity, + ), animationEnabled: false, ), ),