From 0cb1ca0ec115f82cd25dbd79c8b1ef9bfe833d41 Mon Sep 17 00:00:00 2001 From: Hampus Hammarlund Date: Fri, 19 Jul 2024 11:54:58 +0900 Subject: [PATCH] fix: align vocab alternatives to the left --- lib/ui/views/vocab/vocab_view.dart | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/ui/views/vocab/vocab_view.dart b/lib/ui/views/vocab/vocab_view.dart index a775e37..7719cd5 100644 --- a/lib/ui/views/vocab/vocab_view.dart +++ b/lib/ui/views/vocab/vocab_view.dart @@ -171,6 +171,7 @@ class _KanjiReadingPairs extends ViewModelWidget { pairs[0].readings[0].reading, ), fontSize: 32, + textAlign: TextAlign.center, ); } } @@ -397,10 +398,12 @@ class _KanjiReadingPairs extends ViewModelWidget { class _RubyTextWrapper extends StatelessWidget { final List pairs; final double? fontSize; + final TextAlign? textAlign; const _RubyTextWrapper({ required this.pairs, this.fontSize, + this.textAlign, }); @override @@ -416,7 +419,7 @@ class _RubyTextWrapper extends StatelessWidget { } return RubyText( rubyTextData, - textAlign: TextAlign.center, + textAlign: textAlign, style: TextStyle(letterSpacing: 0, height: 1.1, fontSize: fontSize), ); }