Fold All Headings and Lists should (optionally) not fold H1

Use case or problem

The Fold All Headings and Lists command is useful for reducing a note to its main headings. If however one uses an H1 heading as the note title, only that heading remains visible, which defeats the purpose.

Proposed solution

Give user the option for the command to leave H1 alone, but fold all other headings (and lists).

Current workaround

Quickly follow up on the Fold All Headings and Lists hotkey with the Fold Less hotkey (command-option-up, option-down in my setup).

1 Like

Have you tried the Creases plugin?

Thanks for pointing it out, I didn’t know that plugin. It does more than I need, though, and I think an built-in option to limit the scope of the folding is preferable.

1 Like

Quickly follow up on the Fold All Headings and Lists hotkey with the Fold Less hotkey (command-option-up, option-down in my setup).

You could combine these into a single command with the Commander plugin’s Macros feature, and optionally assign it to a hotkey and/or button.

1 Like

Thanks, I’ll see into that.

If you are ok with having only one H1 heading per file which is also the same as the file name, then it is already possible in the core of Obsidian.

You can toggle on the “Show Inline Title” under Appearance in the setting menu.

It will show a H1 heading at the top of your notes.

All other headings in your note then should be H2, H3, etc

Thanks, @JayKim, but when I look at the markdown source, the title isn’t actually in there as an H1 heading.

True! I was also having the same issue with the folding mechanisme, doesn’t make sense to fold the main heading of a note. This kind of solved it for me, but then you don’t have the h1 heading in the source.

I agree with your feature request!

2 Likes