Skip to content

Commit 2e31798

Browse files
committed
removed hardcoded keys
1 parent e044a90 commit 2e31798

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

lib/widgets/markdown_field.dart

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,8 @@ class MarkdownField extends StatelessWidget {
121121
return Padding(
122122
padding: padding,
123123
child: TextField(
124-
key: const ValueKey<String>("markdown_editor_plus"),
124+
key: key,
125+
// const ValueKey<String>("markdown_editor_plus"),
125126
maxLines: expands ? null : maxLines,
126127
minLines: expands ? null : minLines,
127128
expands: expands,

lib/widgets/markdown_parse.dart

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,8 @@ class MarkdownParse extends StatelessWidget {
105105
@override
106106
Widget build(BuildContext context) {
107107
return Markdown(
108-
key: const Key("default-markdown-formatter"),
108+
key: key,
109+
// const Key("default-markdown-formatter"),
109110
data: data,
110111
selectable: selectable,
111112
padding: const EdgeInsets.all(8),

lib/widgets/markdown_parse_body.dart

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,8 @@ class MarkdownParseBody extends StatelessWidget {
9595
return Padding(
9696
padding: const EdgeInsets.all(8.0),
9797
child: MarkdownBody(
98-
key: const Key("default-non-scrolling-markdown-formatter"),
98+
key: key,
99+
// const Key("default-non-scrolling-markdown-formatter"),
99100
data: data,
100101
selectable: selectable,
101102
shrinkWrap: shrinkWrap,

0 commit comments

Comments
 (0)