From fcf42fddbaac4074374cdb696098b199e2ab7b60 Mon Sep 17 00:00:00 2001 From: singerdmx Date: Sun, 3 Jan 2021 04:46:34 -0800 Subject: [PATCH] Trim url before launch --- lib/widgets/editor.dart | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/widgets/editor.dart b/lib/widgets/editor.dart index 4fbd5a6b..c2649383 100644 --- a/lib/widgets/editor.dart +++ b/lib/widgets/editor.dart @@ -344,7 +344,7 @@ class _QuillEditorSelectionGestureDetectorBuilder String link = segment.style.attributes[Attribute.link.key].value; if (getEditor().widget.readOnly && link != null && - urlRegExp.firstMatch(link) != null) { + urlRegExp.firstMatch(link.trim()) != null) { launchUrl(link); } }