-
-
Notifications
You must be signed in to change notification settings - Fork 7
Note Toolbar URIs
Note Toolbar also provides a URI format that you can use to execute commands, focus on folders, open menus (only within Note Toolbar Callouts), and open toolbar settings, from within your notes.
Make sure URIs are wrapped in angle brackets <
>
(when used within Obsidian) or properly encoded.
> [!note-toolbar]
> - [Command URI](<obsidian://note-toolbar?command=workspace:toggle-pin>)
> - [Folder URI](obsidian://note-toolbar?folder=Demos)
> - <hr>
> - [Menu URI](obsidian://note-toolbar?menu=Tools)
> - [Menu URI with ID](obsidian://note-toolbar?menu=7fb30215-d92c-43ce-8158-b79096672bd1)
Tip
All URIs support a vault
parameter, which you can use to specify the vault to open, before executing a command. For example, obsidian://note-toolbar?vault=Personal&command=...
opens the Personal vault before executing the command.
Options available:
Format
obsidian://note-toolbar?command=COMMANDID
Notes:
- You will have to figure out command IDs on your own in order for this to work. I will very likely add a Copy URI for command helper/command in the future, but for now there's a number of ways to do this:
- add a command item to a toolbar and inspect it
- use a Templater script:
<% (await tp.system.suggester((item) => item.name, app.commands.listCommands(f => f.name))).id %>
Thanks @Moyf! - use Advanced URI
- You can use either
command=
orcommandid=
as both work the same.
Focuses on the given folder in the file explorer. This has the same behavior as clicking on a bookmarked folder.
Format
obsidian://note-toolbar?folder=FOLDERNAME
Opens the given toolbar as a menu. This works only when used within Note Toolbar Callouts.
Format
obsidian://note-toolbar?menu=TOOLBAR_NAME or TOOLBAR_ID
Opens the settings for the current, or provided toolbar.
Format
Open the current toolbar on the current note's settings:
obsidian://note-toolbar?toolbarsettings
Open the settings of the provided toolbar (if it exists):
obsidian://note-toolbar?toolbarsettings=TOOLBAR_NAME
Items to be aware of when using URIs:
- URIs don't appear to work in notes that were opened in a new window, as the focus is returned to the main window on click. If that's not suitable for you, use data elements.
Make sure to escape URIs (when used within Obsidian) in angle brackets <
>
if the URI contains special characters like :
.
Otherwise you must properly encode your URIs, which means converting special characters into a code. You can do using an online tool like this one ↗.
-
%20
-
:
becomes%3A
-
/
becomes%2F
-
%
becomes%25
Examples:
> [!note-toolbar]
> - [Toggle pin](<obsidian://note-toolbar?command=workspace:toggle-pin>)
> - [Toggle pin](obsidian://note-toolbar?command=workspace%3Atoggle-pin)
> - [Tools Menu](<obsidian://note-toolbar?menu=Tools Menu>)
> - [Tools Menu](obsidian://note-toolbar?menu=Tools%20Menu)
Read Next: Commands
User Guide • Examples • Support • Discussions ↗ • Release Notes ↗ • Roadmap
Note Toolbar by Chris Gurney • Buy me a coffee ☕️