-
-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
398d45f
commit 909b174
Showing
10 changed files
with
176 additions
and
94 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
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
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
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
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,71 @@ | ||
part of 'home.dart'; | ||
|
||
final class _MarkdownCopyPage extends StatelessWidget { | ||
final String text; | ||
final List<Widget> actions; | ||
final String heroTag; | ||
|
||
const _MarkdownCopyPage({ | ||
required this.text, | ||
required this.actions, | ||
required this.heroTag, | ||
}); | ||
|
||
// @override | ||
// State<_MarkdownCopyPage> createState() => _MarkdownCopyPageState(); | ||
// } | ||
|
||
// final class _MarkdownCopyPageState extends State<_MarkdownCopyPage> | ||
// with SingleTickerProviderStateMixin { | ||
// late final _animeCtrl = AnimationController( | ||
// vsync: this, | ||
// duration: Durations.medium1, | ||
// ); | ||
|
||
// @override | ||
// void initState() { | ||
// super.initState(); | ||
// _animeCtrl.forward(); | ||
// } | ||
|
||
// @override | ||
// Widget build(BuildContext context) { | ||
// return PopScope( | ||
// canPop: true, | ||
// onPopInvoked: (_) async { | ||
// await _animeCtrl.reverse(); | ||
// }, | ||
// child: _buildBody(), | ||
// ); | ||
// } | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
return Scaffold( | ||
appBar: CustomAppBar( | ||
title: Text(l10n.raw), | ||
centerTitle: false, | ||
actions: actions, | ||
), | ||
body: _buildBody(), | ||
); | ||
} | ||
|
||
Widget _buildBody() { | ||
return Hero( | ||
tag: heroTag, | ||
child: SingleChildScrollView( | ||
padding: const EdgeInsets.symmetric(vertical: 7, horizontal: 13), | ||
child: SelectableText( | ||
text, | ||
autofocus: true, | ||
showCursor: true, | ||
style: TextStyle( | ||
fontSize: 14, | ||
color: UIs.textColor.fromBool(RNode.dark.value), | ||
), | ||
), | ||
), | ||
); | ||
} | ||
} |
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