make text selectable #10

This commit is contained in:
otsmr 2025-02-10 20:29:00 +01:00
parent 6be7044a39
commit 34ff5c05ec
2 changed files with 2 additions and 2 deletions

View file

@ -28,7 +28,7 @@ class FormattedStringWidget extends StatelessWidget {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
return Text( return SelectableText(
formatString(longString), formatString(longString),
style: TextStyle(fontSize: 18, color: Colors.black), style: TextStyle(fontSize: 18, color: Colors.black),
textAlign: TextAlign.center, textAlign: TextAlign.center,

View file

@ -57,7 +57,7 @@ class ChatListEntry extends StatelessWidget {
83, 68, 137, 255), // Set the background color 83, 68, 137, 255), // Set the background color
borderRadius: BorderRadius.circular(12.0), // Set border radius borderRadius: BorderRadius.circular(12.0), // Set border radius
), ),
child: Text( child: SelectableText(
content.text, content.text,
style: TextStyle( style: TextStyle(
color: Colors.white, // Set text color for contrast color: Colors.white, // Set text color for contrast