Fixup delta_to_markdown (#1601)

pull/1602/head
agu 1 year ago committed by GitHub
parent c40ccbe205
commit 3a41fc92e2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 10
      lib/src/packages/quill_markdown/delta_to_markdown.dart

@ -310,15 +310,15 @@ abstract class _NodeVisitor<T> {
extension _NodeX on Node { extension _NodeX on Node {
T accept<T>(_NodeVisitor<T> visitor, [T? context]) { T accept<T>(_NodeVisitor<T> visitor, [T? context]) {
switch (runtimeType) { switch (runtimeType) {
case Root _: case Root:
return visitor.visitRoot(this as Root, context); return visitor.visitRoot(this as Root, context);
case Block _: case Block:
return visitor.visitBlock(this as Block, context); return visitor.visitBlock(this as Block, context);
case Line _: case Line:
return visitor.visitLine(this as Line, context); return visitor.visitLine(this as Line, context);
case QuillText _: case QuillText:
return visitor.visitText(this as QuillText, context); return visitor.visitText(this as QuillText, context);
case Embed _: case Embed:
return visitor.visitEmbed(this as Embed, context); return visitor.visitEmbed(this as Embed, context);
} }
throw Exception('Container of type $runtimeType cannot be visited'); throw Exception('Container of type $runtimeType cannot be visited');

Loading…
Cancel
Save