Hide link preview/pop-up for non-existent notes

mano on the Discord channel suggested it would be better for there not to be a hover pop-up for links to non-existent notes.

As Obsidian’s fantastic dev team gave these pop-ups their own class when the note doesn’t exist, they can be hd=idden with CSS:

.mod-empty {
  display: none !important;
}

(I also remove the underlining from links to non-existent notes as I don’t consider them links and I think it makes for a better user experience :grinning: )

5 Likes

@Crow just wanna thank you for sharing this snippet in the forum! I almost lost this one.

Have a great day!

1 Like

Thank you for the nice little snippet. Do you by any chance know how this can be done with the hover editor plugin as well (That is obsidian core plugin preview is indeed hidden but the hover editor still pop ups with the note creation suggestion line)?

Oh found it. Just need to add this snippet

.popover:has(.empty-state) {
  display: none !important;
}