Skip to content

Commit 12f4f16

Browse files
committed
fix mobile nav
1 parent a023c18 commit 12f4f16

File tree

2 files changed

+36
-0
lines changed

2 files changed

+36
-0
lines changed

AGENTS.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Repository Guidelines
2+
3+
## Project Structure & Module Organization
4+
The site is a Docusaurus 3 app. Author content in `docs/` (guides, CLI docs under `docs/cli/`) and `blog/` (Markdown posts). React-based customizations live in `src/` (`src/pages/index.tsx`, `src/components/`), while static assets and JSON feeds ship from `static/`. Build artifacts land in `build/` and should never be committed. Automation scripts sit in `scripts/`, notably `scripts/prebuild.sh`, which normalizes CLI docs and samples before every build.
5+
6+
## Build, Test, and Development Commands
7+
Install dependencies with `npm install`. Use `npm run start` for local dev; it runs `scripts/prebuild.sh`, then serves the docs with hot reload. Execute `npm run build` for production-ready static output and `npm run serve` to smoke-test the generated `build/`. Run `npm run typecheck` to catch TS issues without compiling, and `npm run clear` if you need to reset the Docusaurus cache.
8+
9+
## Coding Style & Naming Conventions
10+
Write prose in Markdown or MDX with frontmatter; use kebab-case filenames such as `docs/networking/private-endpoints.mdx`. React/TypeScript follows 2-space indentation, named exports when practical, and TypeScript types declared near component definitions. Tailwind utility classes are available; co-locate component styles via `.module.css` when utilities are insufficient. Keep metadata files (`_category_.json`) lean and descriptive.
11+
12+
## External Dependencies & Prebuild Notes
13+
The prebuild step shells into `../defang/src/cmd/gendocs` (requires Go) and ingests `../samples/samples`. Keep those repositories updated locally, or vendor them into `defang-docs/defang` and `defang-docs/samples` when working in CI or preview branches.

src/css/custom.css

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -402,6 +402,29 @@ footer.footer--dark .footer__link-item:hover {
402402
max-width: 100% !important;
403403
}
404404

405+
@media (max-width: 996px) {
406+
.navbar-sidebar {
407+
display: flex;
408+
flex-direction: column;
409+
height: 100vh;
410+
max-height: none;
411+
}
412+
413+
.navbar-sidebar__items {
414+
flex: 1 1 auto;
415+
background: var(--ifm-navbar-background-color);
416+
}
417+
418+
.navbar-sidebar__items .menu__link {
419+
@apply text-foreground;
420+
}
421+
422+
.navbar-sidebar__items .menu__link.menu__link--active,
423+
.navbar-sidebar__items .menu__link.menu__link--sublist {
424+
@apply text-primary;
425+
}
426+
}
427+
405428
.blog-post-page main img,
406429
.blog-list-page article img {
407430
border-radius: 2rem;

0 commit comments

Comments
 (0)