Go to Tag,Notebook (or Notes) via links and by highlighting text in editor

Hi

This plugin allows for creating and using #tags and @notebooks as links.

Tags are #anything
Notebooks are @anything
Notes are exact id of note like 1cf78e9edd344fc8bc5678978f1c6169

Tags and notebooks can contain space and it will work.
For example #My diary is fine.

basic usage:

  1. Highlight text of hashtag or notebook in editor
  2. Right click
  3. Choose "Convert text to tag or notebook"

It will convert text to working link visible and clickable in preview pane.

Secondary usage:

  1. Highlight text like @mynotebook
  2. Right-click
  3. Choose - Go to item via highlighted text

This will go to first notebook or hashtag that matches the text.
This is useful if someone doesn't want to use mouse in preview pane.

It is available from Plugins->Search.
Or you can download it as .jpl.
Works on 1.5.14 and 1.6.7 and up.

P.S

  1. If menu entry won't appear on first load of joplin, changing notebook to different should make it appear.
    If you happen to have such behavior please report it here EditorContextMenu entry isn't shown at start - but works after switching to other notebook · Issue #4151 · laurent22/joplin · GitHub
  2. As for now linking to search isn't implemented because its not avail to plugins.https://github.com/laurent22/joplin/blob/dev/packages/app-desktop/gui/MainScreen/commands/search.ts
10 Likes

Just thinking out loud here, but i think that @notebook and #tags could be rendered as links in preview pane (or at least be as such onClick).
It would require ContentScript plugin.

(Also tags containing space would have to be parsed in some way like camelCase or underscore)

I like the idea, though would favor specifying the internal ID of a tag/notebook instead of its name (it currently can only be looked up directly in sqlite, if I am not mistaken). Otherwise you will get linking issues, if tags/notebooks are renamed.

Indeed, there would be a mixup.

The ID would have to be stored somewhere.

So i basically see that there would be dual approach:

  1. To have plain text #tags, and they would work until tag is renamed.
  2. Allow to insert tags/notebooks as [#tag](123-tagID) syntax with some button or right-click menu entry.

That's it for now.

1 Like

In order to implement it, i wait for Joplin release that will allow webviewApi.executeCommand from ContentScript

when this will be released, it will be possible to render #asdf and @asdf as links to tag or notebook respectively.

FYI, for some reason I cannot get this plugin to work. I see other items when I right-click, but nothing related to this. I tried uninstalling and reinstalling and the "switch notebooks" trick. I realize I've been commenting on all your plugins all day, thanks again for your hard work. :slight_smile: I am on Joplin 1.6.6.

No problem:)
I'm checking 1.6.6 and see it i have same issue.

So the problem is probably having other plugins installed.
I turned all of them off and right-click menu started to appear.

But there is another problem in 1.6.6. Basically those plugins
that depend on highlighting text and using highlighted text won't work.

The temporary work around might to use 1.6.4.

1 Like

Are you able to replicate this consistently with 1.6.6? And if so, with which plugins?

One user reported that it was introduced in 1.6.5 (so reverting to 1.6.4 worked)

Its about selectedText and replaceSelection commands. It breaks backlinks plugin, for example, b/c it uses selectedText as away to retrieve text from editor.
Other that use selectedText are also affected.

New release - convert text to #tag or @notebook and click it in preview pane like normal links.

Download available in OP.

@john you can install with .jpl file or wait a bit for it to appear in Search
@bela53 this version includes links that can have title changed and it will still work :smiley: as You suggested

2 Likes

Works really well, thanks!

I think this was actually @bela53's suggestion :slight_smile:

1 Like

True! I gotta edit post. Sorry @bela53!

Error, plugin doesn't seem to work here
Joplin 1.6.7 (prod, win32)

My bad, I need to use the right format of #Anatomy to make this work.

This plugin combos well with a pinned note, having all tags in one organized spot to navigate from.

{7B7638F9-9359-4BCB-B0C8-DD5B22D1B710}

In retrospect an error message with a short instruction of including the hash or at symbol as part of the string to make this plugin work, would be more helpful. Although I've come to realize there isn't much of hand holding and feed-forward when it comes to using Joplin's rich features and add-ons in general, instead I'm rewarded for digging gold nuggets.

1 Like

Yes, it seems unclear from the error that # or @ are required.
I'll update error message,
thanks for pointing this out.

These are early days of plugins. Probably developers of plugins don't know what users don't know so most of them still have rough edges.
Things are added in realtime with help of community.

The text in popup is changed, now, to have more info about problem.

2 Likes

Hi
I am running Joplin 2.8.8 on Ubuntu 18.04 and v1.3.7 of this plugin.
I have disabled all other plugins for testing.
Here is the behavior I am seeing.
I add a link to a notebook in the editor as suggested (@notebook name then right click)
This works as expected.
The link works in the Viewer.
In the editor, ctrl-click shows it is a link but does not go anywhere.
The rich text editor does not recognize it as a link.
Also, if I edit the note in any way in the rich text editor (even just add a return to some text), the notebook link is replaced by just a # and the link is broken.

I hope this is the correct place to report this. Thanks.'

Edit: I should mention I disabled all other plugins except the Rich Markdown plugin

2 Likes

Is there any updated information about this Plugin? I installed it and successfully turned a text into a link as in below attached screenshot, and then I tried to click the link while holding CTRL button, but nothing happened (I don't even sure what should happen without a visual communication introduction)..., and then I tried to read through this thread which referred by the plugin, but I noticed the last reply of this thread is nearly a year ago... So, is there any updated information about this plugin? Something I don't know but I should know or so?

Reference screenshot as below:
2023-12-30_004440