From 1cf9314b6c7dfc4b831f8a8d0b5e29728ed70da5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=AB=A0=E6=96=87=E8=BD=A9?= <12812285557@qq.com> Date: Tue, 7 Sep 2021 14:26:49 +0800 Subject: [PATCH] =?UTF-8?q?=E9=80=82=E5=BA=94=E7=91=9E=E5=BA=93=E5=85=8B?= =?UTF-8?q?=E4=B8=BB=E9=A2=98=E5=81=9A=E4=BA=86=E6=9B=B4=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- example/lib/main.dart | 2 +- lib/src/parser/unfocus_parser.dart | 4 +--- lib/src/view/box_view.dart | 4 ++-- lib/src/view/title_view.dart | 2 +- lib/src/views/info_view.dart | 4 ++-- lib/src/widgets/logger_fab.dart | 2 +- 6 files changed, 8 insertions(+), 10 deletions(-) diff --git a/example/lib/main.dart b/example/lib/main.dart index dad4868..ecee1fc 100644 --- a/example/lib/main.dart +++ b/example/lib/main.dart @@ -17,7 +17,7 @@ class MyApp extends StatelessWidget { return MaterialApp( title: 'PowerLogger\nDemo', home: MyHomePage(title: 'PowerLogger Demo'), - theme: ThemeData.dark(), + //theme: ThemeData.dark(), ); } } diff --git a/lib/src/parser/unfocus_parser.dart b/lib/src/parser/unfocus_parser.dart index 5c89233..4e85a7a 100644 --- a/lib/src/parser/unfocus_parser.dart +++ b/lib/src/parser/unfocus_parser.dart @@ -10,9 +10,7 @@ class UnfocusParser extends StatelessWidget { @override Widget build(BuildContext context) { return Material( - color: Theme.of(context).brightness == Brightness.light - ? Colors.black12 - : Colors.white10, + color: Colors.white10, child: ListTile( onTap: () => Navigator.push( context, diff --git a/lib/src/view/box_view.dart b/lib/src/view/box_view.dart index 6e0b7d9..64a4af2 100644 --- a/lib/src/view/box_view.dart +++ b/lib/src/view/box_view.dart @@ -21,12 +21,12 @@ class BoxView extends StatelessWidget { crossAxisAlignment: CrossAxisAlignment.start, children: [ DefaultTextStyle( - style: Theme.of(context).textTheme.caption!, + style: TextStyle(fontSize: 16,color: Colors.red), child: title, ), child == null ? SizedBox() : SizedBox(height: 10), DefaultTextStyle( - style: Theme.of(context).textTheme.bodyText2!, + style: TextStyle(fontSize: 15,color: Color(0xFF333333)), child: child ?? SizedBox(), ), children == null ? SizedBox() : SizedBox(height: 10), diff --git a/lib/src/view/title_view.dart b/lib/src/view/title_view.dart index e57f591..8797ad1 100644 --- a/lib/src/view/title_view.dart +++ b/lib/src/view/title_view.dart @@ -9,7 +9,7 @@ class TitleView extends StatelessWidget { return Padding( padding: EdgeInsets.symmetric(horizontal: 5, vertical: 10), child: DefaultTextStyle( - style: Theme.of(context).textTheme.headline4!, + style: TextStyle(fontSize: 26,color: Color(0xFF666666)), child: title, ), ); diff --git a/lib/src/views/info_view.dart b/lib/src/views/info_view.dart index e6b2aff..ecf3a8a 100644 --- a/lib/src/views/info_view.dart +++ b/lib/src/views/info_view.dart @@ -72,7 +72,7 @@ class _InfoViewState extends State delegate: SliverChildListDelegate([ ListTile( title: Text('Package Info'), - tileColor: Theme.of(context).accentColor.withOpacity(0.2), + tileColor: Colors.blue.withOpacity(0.2), ), InfoTile(title: 'appName', subTitle: packageInfo!.appName), InfoTile( @@ -82,7 +82,7 @@ class _InfoViewState extends State InfoTile(title: 'version', subTitle: packageInfo!.version), ListTile( title: Text('Device Info'), - tileColor: Theme.of(context).accentColor.withOpacity(0.1), + tileColor: Colors.blue.withOpacity(0.1), ), ])), _buildView(), diff --git a/lib/src/widgets/logger_fab.dart b/lib/src/widgets/logger_fab.dart index 9f52f95..1d54eab 100644 --- a/lib/src/widgets/logger_fab.dart +++ b/lib/src/widgets/logger_fab.dart @@ -105,7 +105,7 @@ class _FabButton extends StatelessWidget { Widget build(BuildContext context) { return Container( decoration: BoxDecoration( - color: Theme.of(context).accentColor, + color: Colors.blue, borderRadius: BorderRadius.circular(25), boxShadow: [ BoxShadow(