A recent commit [1] broke mesage formatting in compact message mode.
Linkify was stripping all formatting, and the style was never passed
back before displaying it.
We can just wrap the TextSpan linkify returns in another TextSpan with
the current span style and with an only child that is the linkified
text span.
[1]: 6c7c51b029c9be8664c958279f632313bac5f193
---
lib/page/buffer.dart | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/lib/page/buffer.dart b/lib/page/buffer.dart
index 231d9dc..efb22aa 100644
--- a/lib/page/buffer.dart+++ b/lib/page/buffer.dart
@@ -429,7 +429,7 @@ class _CompactMessageItem extends StatelessWidget {
var textStyle = TextStyle(color: Theme.of(context).textTheme.bodyText1!.color);
List<TextSpan> textSpans;
- if (ctcp != null && ctcp.cmd == 'ACTION') {+ if (ctcp != null) { textStyle = textStyle.apply(fontStyle: FontStyle.italic);
if (ctcp.cmd == 'ACTION') {
@@ -442,7 +442,8 @@ class _CompactMessageItem extends StatelessWidget {
}
textSpans = textSpans.map((span) {
- return linkify(context, span.text!, linkStyle: TextStyle(decoration: TextDecoration.underline));+ var linkSpan = linkify(context, span.text!, linkStyle: TextStyle(decoration: TextDecoration.underline));+ return TextSpan(style: span.style, children: [linkSpan]); }).toList();
List<Widget> stack = [];
base-commit: 5d84adafc1d8b61b05eaecb15d040e7297867a8d
--
2.39.0