How to split page into sections that don't get folded when minimizing headers

Things I have tried

What I’m trying to do

I would like to split my notes into sections as well as utilize headers that minimize the content below. For example I will add a subheading with ##, write my content below, and then split the section using --- to get a full line across the bottom.

I would like to be able to minimize each section but not have the line --- be absorbed. Is there a way to do this?

1 Like

I don’t think there is. If you want content to not get folded, it needs to appear before the first heading or under a heading of a higher level than the ones you’re folding (like an h2 of your folding h3s).

If you just want a line between folded headings, you could probably add that with a CSS snippet (maybe adding border-top to headings).

Thanks for the response! I sadly don’t know anything about CSS so unsure where to even start or what to look for.

You could either use the minimal theme and customise it with the style settings plugin to make each header have a line at the bottom.

Or use this css snippet:

.h1-l .markdown-reading-view h1:not(.embedded-note-title),.h1-l .mod-cm6 .cm-editor .HyperMD-header-1, .h2-l .markdown-reading-view h2,.h2-l .mod-cm6 .cm-editor .HyperMD-header-2, .h3-l .markdown-reading-view h3,.h3-l .mod-cm6 .cm-editor .HyperMD-header-3, .h4-l .markdown-reading-view h4,.h4-l .mod-cm6 .cm-editor .HyperMD-header-4, .h5-l .markdown-reading-view h5,.h5-l .mod-cm6 .cm-editor .HyperMD-header-5, .h6-l .markdown-reading-view h6,.h6-l .mod-cm6 .cm-editor .HyperMD-header-6{
	border-bottom:1px solid var(--color-base-50);
1 Like

Another option I’ve seen recently in Obsidian is to put in an extra header with its content being the HTML equivalent of - - -:

## <hr>

This works perfectly, thank you! And thank you as well @shallash for your reply as well

1 Like

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