Skip to content

Obsidian auto collapse linked mentions

Problem¶

When you open Obsidian, linked mentions aren’t auto collapsed. Making them harder to read.

Workaround¶

CSS workaround hack ✅¶

I’m using this workaround.
CSS to always collapse linked mentions.
Place a CSS file in your vault in /.obsidian/snippets.

/* backlinks in document - hide expanded parts */
.search-result-file-matches {
    display: None !important;
}
/* backlinks in document - keep the font color grayish instead of white */
.tree-item-self {
    color: var(--nav-item-color) !important;
}
/* hide all arrows, since collapsable arrows don't work anymore */
.search-results-children .tree-item-icon.collapse-icon {
  display: none;
}

cons:

  • you can’t expand backlinks anymore
  • search results are also affected!

source original forum post, my reply

3rd party plugin¶

untested

forum posts requesting this feature
- 20341
- 7487
- 49136