mirror of https://github.com/logseq/logseq
parent
b34325be77
commit
82639cb07a
|
@ -87,11 +87,13 @@
|
|||
(string/trim)))
|
||||
|
||||
(defn replace-tags-with-page-refs
|
||||
"Replace tags in content with page-ref ids"
|
||||
"Replace tags in content with page-ref ids. Ignore case because tags in
|
||||
content can have any case and still have a valid ref"
|
||||
[content tags]
|
||||
(reduce
|
||||
(fn [content tag]
|
||||
(string/replace content
|
||||
(common-util/replace-ignore-case
|
||||
content
|
||||
(str "#" (:block/original-name tag))
|
||||
(str page-ref/left-brackets
|
||||
page-ref-special-chars
|
||||
|
|
Loading…
Reference in New Issue