pvojtechovsky / obsidian-link-with-alias

Obsidian plugin for handy creation of links and alias in front matter of target document
MIT License
35 stars 1 forks source link

[BUG] Invalid link is created when autocompletion option without alias is chosen #11

Closed pvojtechovsky closed 1 year ago

pvojtechovsky commented 1 year ago

Describe the bug Invalid link is created when autocompletion option without alias is chosen

To Reproduce Steps to reproduce the behavior:

  1. write some text. e.g. "display text"
  2. select it and run command create link with alias
  3. autocompletion is opened, choose some option with pure link without alias and press enter
  4. the link is replaced by selected pure link without display text - as expected and then this plugin restores origin display text ("display text") bug: the link name is lost and there remains just invalid link like [[|display text]] expected:

Expected behavior The link contains selected pure link name together with origin display text like [[link name|display text]]