From df09ee4c177f36022330acb9845b02796c3db9b6 Mon Sep 17 00:00:00 2001 From: Rongjian Zhang Date: Wed, 29 Jan 2020 12:44:10 +0800 Subject: [PATCH] fix(gitlab): syntax highlight in dark mode --- lib/widgets/blob_view.dart | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/widgets/blob_view.dart b/lib/widgets/blob_view.dart index e1c45fc..af3042e 100644 --- a/lib/widgets/blob_view.dart +++ b/lib/widgets/blob_view.dart @@ -55,7 +55,9 @@ class BlobView extends StatelessWidget { child: HighlightView( payload, language: _language, - theme: themeMap[codeProvider.theme], + theme: themeMap[theme.brightness == Brightness.dark + ? codeProvider.themeDark + : codeProvider.theme], padding: CommonStyle.padding, textStyle: TextStyle( fontSize: codeProvider.fontSize.toDouble(),