Skip to content

Commit

Permalink
fix(editor): trim html link label when pasting
Browse files Browse the repository at this point in the history
  • Loading branch information
andelf authored and tiensonqin committed Nov 10, 2022
1 parent ab82397 commit 6ef87a5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/frontend/extensions/html_parser.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@
:h5 (block-transform 5 children)
:h6 (block-transform 6 children)
:a (let [href (:href attrs)
label (or (map-join children) "")
label (or (string/trim (map-join children)) "")
has-img-tag? (util/safe-re-find #"\[:img" (str x))]
(when-not (string/blank? href)
(if has-img-tag?
Expand Down

0 comments on commit 6ef87a5

Please sign in to comment.