Skip to content

Commit 144f90d

Browse files
authored
Set scroll-margin-top to all heading inside <main/> (#1454)
Before (header's opacity is set to 0.9 to describe) <img width="1065" height="675" alt="before" src="https://github.com/user-attachments/assets/dd7ae9af-f624-4a28-bab5-f6743b5650dd" /> After <img width="1065" height="675" alt="after" src="https://github.com/user-attachments/assets/5e27c63e-1bfa-4bb5-ac93-bb1d0facbabb" />
1 parent 70995a4 commit 144f90d

File tree

1 file changed

+1
-1
lines changed
  • lib/rdoc/generator/template/aliki/css

1 file changed

+1
-1
lines changed

lib/rdoc/generator/template/aliki/css/rdoc.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,6 @@ h6:target {
308308
margin-left: calc(-1 * var(--space-5));
309309
padding-left: calc(var(--space-5) / 2);
310310
border-left: calc(var(--space-5) / 2) solid var(--border-color);
311-
scroll-margin-top: calc(var(--layout-header-height) + 2rem);
312311
}
313312

314313
main .anchor-link:target {
@@ -944,6 +943,7 @@ main h5,
944943
main h6 {
945944
font-family: var(--font-heading);
946945
color: var(--highlight-color);
946+
scroll-margin-top: calc(var(--layout-header-height) + 2rem);
947947
}
948948

949949
/* Heading size hierarchy */

0 commit comments

Comments
 (0)