[flutter_markdown] Do not modify children of an Element after construction (#2758)

Do not modify children of a markdown Element after construction

The children list of an Element became unmodifiable in https://github.com/dart-lang/markdown/pull/463, so this just changes flutter_markdown to not modify the children, in a test.

Fixes https://github.com/dart-lang/markdown/issues/480
diff --git a/packages/flutter_markdown/test/custom_syntax_test.dart b/packages/flutter_markdown/test/custom_syntax_test.dart
index 7fee7ce..6254a1b 100644
--- a/packages/flutter_markdown/test/custom_syntax_test.dart
+++ b/packages/flutter_markdown/test/custom_syntax_test.dart
@@ -160,9 +160,10 @@
 
   @override
   bool onMatch(md.InlineParser parser, Match match) {
-    final md.Element el = md.Element.withTag('wikilink');
-    el.attributes['href'] = match[1]!.replaceAll(' ', '_');
-    el.children!.add(md.Element.text('span', match[1]!));
+    final String link = match[1]!;
+    final md.Element el =
+        md.Element('wikilink', <md.Element>[md.Element.text('span', link)])
+          ..attributes['href'] = link.replaceAll(' ', '_');
 
     parser.addNode(el);
     return true;