cours/.obsidian/snippets/[user] Daily Note - Sticky Headings.css
Oscar Plaisant 602a41e7f8 update
2024-12-25 22:30:24 +01:00

73 lines
1.7 KiB
CSS
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/*
Daily note styles for Sticky Headings plugin. Disables plugin on non-daily note pages.
Enable 'PrevToH1' option in plugin settings
https://github.com/replete/obsidian-minimal-theme-css-snippets
*/
.obsidian-sticky-heading {
display:none; /* Enable only for some templates */
.dailynote & {
display:flex;
}
background:linear-gradient(0deg, transparent, var(--bg2) 20%);
&:has(.obsidian-sticky-heading_inner:not(:empty)) {
padding:8px 0 16px 0;
}
.obsidian-sticky-heading_inner {
background:transparent;
.HyperMD-header {
margin-top:0 !important;
margin-bottom:0 !important;
/* second item */
+ .HyperMD-header {
padding:0 !important;
h1, h2, h3, h4, h5, h6 {
font-size:14px;
}
}
/* Hide 3rd onwards items */
+ .HyperMD-header ~ .HyperMD-header {
display:none;
}
.cm-header[class*=cm-header-] {
margin-top:0 !important;
margin-bottom:0 !important;
}
}
}
.obsidian-sticky-heading_text {
margin-top:0;
h1, h2, h3, h4, h5, h6 {
font-size:18px;
}
}
/* Hide the H* level text */
.obsidian-sticky-heading_level {
/* color: transparent; */
display:none;
/* &::before {
content:'';
color: var(--tx2);
display:block;
position:absolute;
right:0;
top:50%;
transform: translateY(-50%);
font-size:1rem
} */
}
}