Skip to content

Commit 631a578

Browse files
committed
fix(website): repair the mobile menu and the landing mock on phones
backdrop-filter on .navbar made it the containing block for its own fixed-position child. Docusaurus renders the mobile drawer inside the navbar, so .navbar-sidebar was clamped to the 60px bar and every link below its header was clipped by the drawer's own overflow — on docs pages that left the sidebar navigation unreachable. The blur moves to a pseudo-element, the drawer gets an opaque background instead of the navbar's translucent one, and the bar's Download CTA steps aside while the drawer is open rather than sitting on top of its close button. Stacked under 780px the landing mock now leads with the editor stage rather than with the agent panel, and the transport's timecode no longer wraps into a slab covering half the preview. Docs tables widened the document past the viewport on a phone: the `display: table` override had dropped Infima's scroll container. They scroll inside their own card again under 768px, and a table with real headers — the platform matrix — keeps them, since hiding thead left its columns of check marks unlabelled.
1 parent 030ccf1 commit 631a578

3 files changed

Lines changed: 190 additions & 3 deletions

File tree

‎.claude/launch.json‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,12 @@
2626
"runtimeExecutable": "npm",
2727
"runtimeArgs": ["--prefix", "website", "run", "serve", "--", "--port", "3111"],
2828
"port": 3111
29+
},
30+
{
31+
"name": "docs-dev",
32+
"runtimeExecutable": "npm",
33+
"runtimeArgs": ["--prefix", "website", "run", "dev", "--", "--port", "3112"],
34+
"port": 3112
2935
}
3036
]
3137
}

‎website/src/css/custom.css‎

Lines changed: 117 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -153,10 +153,25 @@ body {
153153
height: 60px;
154154
min-height: 60px;
155155
padding: 0 28px;
156-
backdrop-filter: blur(16px) saturate(140%);
156+
background: transparent;
157157
border-bottom: 1px solid var(--os-border-soft);
158158
}
159159

160+
/* The frosted background is painted by a pseudo-element rather than on .navbar
161+
itself: backdrop-filter turns an element into the containing block for its
162+
fixed-position descendants, and Docusaurus renders the mobile menu
163+
(.navbar-sidebar, position: fixed) *inside* the navbar. Filtering the bar
164+
collapsed the whole drawer into the 60px strip — header visible, every link
165+
clipped away. */
166+
.navbar::before {
167+
content: "";
168+
position: absolute;
169+
inset: 0;
170+
z-index: -1;
171+
background: var(--os-nav-bg);
172+
backdrop-filter: blur(16px) saturate(140%);
173+
}
174+
160175
.navbar__inner {
161176
gap: 18px;
162177
}
@@ -213,8 +228,10 @@ body {
213228
}
214229

215230
/* Docusaurus auto-appends an "opens in new tab" glyph to every external
216-
navbar link; the design has none, so it's suppressed here. */
217-
.navbar__link [class*="iconExternalLink"] {
231+
navbar link; the design has none, so it's suppressed here — in the mobile
232+
drawer too, where the same items are rendered as .menu__link. */
233+
.navbar__link [class*="iconExternalLink"],
234+
.navbar-sidebar .menu__link [class*="iconExternalLink"] {
218235
display: none;
219236
}
220237

@@ -304,6 +321,65 @@ body {
304321
display: none;
305322
}
306323

324+
/* ---- mobile menu ----
325+
Below 996px Docusaurus hides the navbar links and moves them into the
326+
.navbar-sidebar drawer, where a navbar pill (GitHub, Download) is rendered
327+
as a row of a menu list instead. */
328+
329+
.navbar-sidebar {
330+
background: var(--os-surface);
331+
border-right: 1px solid var(--os-border);
332+
box-shadow: var(--os-elev-pop);
333+
}
334+
335+
.navbar-sidebar__brand {
336+
border-bottom: 1px solid var(--os-border-soft);
337+
box-shadow: none;
338+
}
339+
340+
/* Groups the theme switch with the close button on the right of the drawer
341+
header instead of leaving it stuck to the wordmark. */
342+
.navbar-sidebar__brand > [class*="toggle_"] {
343+
margin-left: auto;
344+
}
345+
346+
/* The drawer covers 83vw, so the bar's right-hand CTA would otherwise sit on
347+
top of the drawer's own close button. */
348+
.navbar-sidebar--show .navbar__items--right {
349+
display: none;
350+
}
351+
352+
.navbar-sidebar .navbar-github-link,
353+
.navbar-sidebar .navbar-download-cta {
354+
display: flex;
355+
justify-content: center;
356+
width: 100%;
357+
margin-top: 4px;
358+
padding: 10px 14px !important;
359+
font-size: 13.5px;
360+
}
361+
362+
@media (max-width: 996px) {
363+
.navbar {
364+
padding: 0 16px;
365+
}
366+
367+
/* The rule separates the wordmark from the nav links; at this width the
368+
links are in the drawer, so it divides the brand from nothing. */
369+
.navbar__brand {
370+
margin-right: 0;
371+
padding-right: 0;
372+
}
373+
374+
.navbar__brand::after {
375+
display: none;
376+
}
377+
378+
.navbar__items--right .navbar-download-cta {
379+
padding: 6px 12px !important;
380+
}
381+
}
382+
307383
/* ---- footer ---- */
308384

309385
.footer {
@@ -393,10 +469,26 @@ body {
393469
box-shadow: none;
394470
}
395471

472+
/* The docs' two-column "fact card" tables carry an empty header row, which is
473+
what this hides. A table with real headers — the platform matrix in
474+
Installation — keeps them, or its ✅/❌ columns say nothing. */
396475
.theme-doc-markdown table thead {
397476
display: none;
398477
}
399478

479+
.theme-doc-markdown table:has(thead th:not(:empty)) thead {
480+
display: table-header-group;
481+
}
482+
483+
.theme-doc-markdown table th {
484+
border: none;
485+
padding: 0.75rem 1rem;
486+
font-size: 0.85em;
487+
font-weight: 600;
488+
color: var(--os-muted);
489+
text-align: left;
490+
}
491+
400492
.theme-doc-markdown table tr {
401493
border-top: 1px solid var(--os-border-soft);
402494
background: transparent;
@@ -411,12 +503,34 @@ body {
411503
padding: 0.75rem 1rem;
412504
}
413505

506+
/* A bare repo URL is one unbreakable word, which sets the table's minimum
507+
width and drags the whole page past the viewport on a phone. Scoped to
508+
links: prose has to keep breaking on word boundaries, or a narrow column
509+
shreds it one letter per line. */
510+
.theme-doc-markdown table td a {
511+
overflow-wrap: anywhere;
512+
}
513+
414514
.theme-doc-markdown table td:first-child {
415515
width: 160px;
416516
color: var(--os-muted);
417517
font-weight: 400;
418518
}
419519

520+
@media (max-width: 768px) {
521+
/* display: table above dropped Infima's scroll container, so a table wider
522+
than the screen (the platform matrix) widened the document instead of
523+
scrolling inside its own card. */
524+
.theme-doc-markdown table {
525+
display: block;
526+
overflow-x: auto;
527+
}
528+
529+
.theme-doc-markdown table td:first-child {
530+
width: auto;
531+
}
532+
}
533+
420534
.theme-doc-markdown pre {
421535
border-radius: 12px;
422536
border: 1px solid var(--os-border);

‎website/src/pages/index.module.css‎

Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,9 +210,24 @@
210210
min-height: 340px;
211211
}
212212

213+
/* Stacked, the mock has to read top-down: the editor is the product and the
214+
agent panel is the sub-plot, so the stage goes first and the panel's right
215+
border becomes the rule between them. Ordered in CSS rather than in the
216+
markup so the desktop grid keeps its natural sidebar-then-stage source order. */
213217
@media (max-width: 780px) {
214218
.visualBody {
215219
grid-template-columns: 1fr;
220+
min-height: 0;
221+
}
222+
223+
.stage {
224+
order: 1;
225+
}
226+
227+
.agentPanel {
228+
order: 2;
229+
border-right: none;
230+
border-top: 1px solid var(--os-border);
216231
}
217232
}
218233

@@ -349,11 +364,14 @@
349364
color: #fff;
350365
}
351366

367+
/* nowrap: the transport floats over the preview, and a wrapped timecode
368+
doubles its height into a slab covering half the frame on a phone. */
352369
.transportTime {
353370
font-family: var(--ifm-font-family-monospace);
354371
font-size: 11px;
355372
color: var(--os-fg);
356373
margin-left: 4px;
374+
white-space: nowrap;
357375
}
358376

359377
.meta {
@@ -788,3 +806,52 @@
788806
color: var(--os-fg-2);
789807
}
790808

809+
/* ---- phone ----
810+
The 28px section gutter is a third of the width of a small phone; every
811+
inner padding here is scaled to give the mock and the cards room to breathe
812+
rather than to change their design. */
813+
814+
@media (max-width: 600px) {
815+
.hero {
816+
padding: 64px 20px 0;
817+
}
818+
819+
.visualSection {
820+
padding: 32px 16px 72px;
821+
}
822+
823+
.features {
824+
padding: 0 20px 72px;
825+
}
826+
827+
.quickStart {
828+
padding: 0 20px 76px;
829+
}
830+
831+
.agentPanel {
832+
padding: 14px;
833+
gap: 12px;
834+
}
835+
836+
.stageFrame {
837+
padding: 16px;
838+
min-height: 0;
839+
}
840+
841+
.transport {
842+
gap: 6px;
843+
bottom: 10px;
844+
padding: 6px 8px;
845+
}
846+
847+
.timeline {
848+
padding: 10px 12px 12px;
849+
}
850+
851+
/* The icon is centred against a three-line paragraph on desktop; on a phone
852+
the same text runs to seven lines and leaves the badge stranded mid-card. */
853+
.bentoCaptions {
854+
align-items: flex-start;
855+
}
856+
}
857+

0 commit comments

Comments
 (0)