(bugfix): fix Helm completing-read containing extra spaces on non-match (#309)

This commit is contained in:
Jethro Kuan
2020-03-16 17:42:57 +08:00
committed by GitHub
parent 08667d9c7d
commit c14ac7b613

View File

@@ -613,10 +613,10 @@ specified via the #+ROAM_ALIAS property."
(defun org-roam---helm-candidate-transformer (candidates _source)
"Transforms CANDIDATES for Helm-based completing read.
SOURCE is not used."
(let ((prefixed-pattern (propertize
" " 'display
(propertize "[?]" 'face 'helm-ff-prefix))))
(cons (concat prefixed-pattern " " helm-pattern)
(let ((prefix (propertize "[?] "
'face 'helm-ff-prefix)))
(cons (propertize helm-pattern
'display (concat prefix helm-pattern))
candidates)))
(cl-defun org-roam--completing-read (prompt choices &key