Feature Request: Selectively disable Obsidian tooltips using data attributes

Use case or problem

In cases where we want to show our own tooltip based on the aria-label, and don’t want the default Obsidian tooltip to also be shown.

Proposed solution

The tooltip that appears in the DOM tree seems to get the label text from the aria-label attribute of the target element, so checking for a secondary attribute in the element or its ancestor will suffice. Something like:

if(element.closest('[data-show-obsidian-tooltips=false]')) {
   // Do not show tooltip
}

Current workaround

Using the plugin obsidian-hider, but it will require manual install of the plugin for every user.

1 Like

and the hider plugin will hide ALL tooltips…

There’s actually an (undocumented) way to disable tooltips via CSS:

.your-element {
  --no-tooltip: true;
}
1 Like

Thanks you!

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.