-
Notifications
You must be signed in to change notification settings - Fork 543
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Select text option for chat messages (#1726)
Closes #1725 #1688 (comment) https://github.com/user-attachments/assets/f9e24e05-59b1-4e07-9f36-2071b887a510
- Loading branch information
Showing
3 changed files
with
64 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
import 'package:flutter/material.dart'; | ||
import 'package:friend_private/backend/schema/message.dart'; | ||
|
||
import 'widgets/markdown_message_widget.dart'; | ||
|
||
class SelectTextScreen extends StatelessWidget { | ||
final ServerMessage message; | ||
const SelectTextScreen({super.key, required this.message}); | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return Scaffold( | ||
backgroundColor: Theme.of(context).colorScheme.primary, | ||
appBar: AppBar( | ||
backgroundColor: Theme.of(context).colorScheme.primary, | ||
automaticallyImplyLeading: true, | ||
title: const Text('Select Text'), | ||
centerTitle: false, | ||
leading: IconButton( | ||
icon: const Icon(Icons.arrow_back_ios_new), | ||
onPressed: () { | ||
Navigator.pop(context); | ||
}, | ||
), | ||
elevation: 0, | ||
), | ||
body: Padding( | ||
padding: const EdgeInsets.all(10.0), | ||
child: SelectionArea(child: getMarkdownWidget(context, message.text)), | ||
), | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters