chore: decrease token text size in word zoom card, don't deselect token on second click (#3410)

pull/2245/head
ggurdin 4 months ago committed by GitHub
parent 7afe08fc67
commit 5c63aa95c5
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -265,7 +265,8 @@ class MessageOverlayController extends State<MessageSelectionOverlay>
}
/// Update [selectedSpan]
void updateSelectedSpan(PangeaTokenText? selectedSpan, [bool force = false]) {
void updateSelectedSpan(PangeaTokenText? selectedSpan) {
if (selectedSpan == _selectedSpan) return;
if (selectedMorph != null) {
selectedMorph = null;
}
@ -276,12 +277,7 @@ class MessageOverlayController extends State<MessageSelectionOverlay>
);
}
if (selectedSpan == _selectedSpan && !force) {
_selectedSpan = null;
} else {
_selectedSpan = selectedSpan;
}
_selectedSpan = selectedSpan;
if (mounted) setState(() {});
if (selectedToken != null && isNewToken(selectedToken!)) {
_onSelectNewToken(selectedToken!);

@ -88,7 +88,7 @@ class WordZoomWidget extends StatelessWidget {
token.text.content,
textAlign: TextAlign.center,
style: TextStyle(
fontSize: 32.0,
fontSize: 28.0,
fontWeight: FontWeight.w600,
height: 1.2,
color:

Loading…
Cancel
Save