Updated example to match dark themes

This commit is contained in:
David Peters 2021-09-29 11:44:51 +02:00
parent 2ad75d4f6f
commit fd04725260
2 changed files with 8 additions and 5 deletions

View File

@ -16,10 +16,8 @@ class MyApp extends StatelessWidget {
Widget build(BuildContext context) { Widget build(BuildContext context) {
return MaterialApp( return MaterialApp(
title: 'Miniplayer Demo', title: 'Miniplayer Demo',
theme: ThemeData( theme: ThemeData.light(),
primaryColor: Colors.grey[50], darkTheme: ThemeData.dark(),
visualDensity: VisualDensity.adaptivePlatformDensity,
),
home: MyHomePage(), home: MyHomePage(),
); );
} }

View File

@ -160,7 +160,12 @@ class DetailedPlayer extends StatelessWidget {
.textTheme .textTheme
.bodyText2! .bodyText2!
.copyWith( .copyWith(
color: Colors.black.withOpacity(0.55)), color: Theme.of(context)
.textTheme
.bodyText2!
.color!
.withOpacity(0.55),
),
), ),
], ],
), ),