Skip to content

Commit da9735d

Browse files
committed
compose: Clamp max scale factor of _Banner label
To avoid wasting a lot of vertical space in the edit-message compose box (coming up) with large text-scale settings. Related: zulip#1023
1 parent e70bf9d commit da9735d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/widgets/compose_box.dart

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1437,7 +1437,9 @@ abstract class _Banner extends StatelessWidget {
14371437
Expanded(
14381438
child: Padding(
14391439
padding: const EdgeInsets.symmetric(vertical: 4),
1440-
child: Text(style: labelTextStyle,
1440+
child: Text(
1441+
style: labelTextStyle,
1442+
textScaler: MediaQuery.textScalerOf(context).clamp(maxScaleFactor: 1.5),
14411443
getLabel(zulipLocalizations)))),
14421444
if (trailing != null) ...[
14431445
const SizedBox(width: 8),

0 commit comments

Comments
 (0)