Skip to content

Commit 9185198

Browse files
Kyle McLarenclaude
andcommitted
Add space for anchor links in API method pages
The anchor links are positioned to the left of headings, which requires the method-page container to have padding/margin to prevent clipping. Co-Authored-By: Claude Opus 4.5 <[email protected]>
1 parent 91b7c81 commit 9185198

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/styles/custom.css

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1074,12 +1074,15 @@ html::before {
10741074
gap: 2rem;
10751075
/* Minimum height ensures sticky has room to work even with short content */
10761076
min-height: 70vh;
1077+
/* Space for anchor links that appear to the left of headings */
1078+
padding-left: 2rem;
1079+
margin-left: -2rem;
10771080
}
10781081

10791082
.method-page-left {
10801083
/* Description and parameters - takes natural height */
10811084
min-width: 0; /* Allow shrinking in grid */
1082-
overflow-x: auto; /* Scroll if content too wide */
1085+
/* overflow visible allows anchor links positioned outside to be visible */
10831086
}
10841087

10851088
/* Constrain tables in method-page-left to not overflow */
@@ -1502,6 +1505,7 @@ h2.method-title {
15021505
margin-bottom: 0.75rem;
15031506
}
15041507

1508+
15051509
.method-description {
15061510
color: var(--muted-foreground);
15071511
line-height: 1.6;

0 commit comments

Comments
 (0)