chore(docs): remove Outpost, fix dead home preset, surface missing sections in navbar#309
chore(docs): remove Outpost, fix dead home preset, surface missing sections in navbar#309JohnnyWyles wants to merge 7 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
- Delete docs/osmosis-outpost/ (53 files) — product is no longer maintained by Nabla Studio (their website no longer features it, related assetlist repo dormant since 2023, 4 unresolved TODO placeholders for npm package names). - Delete docs/home/README.mdx (empty file) and sidebars-home.js — the classic preset was mounting an empty doc at /, conflicting with src/pages/index.jsx which already owns / and renders the styled landing. This also resolves the build-time "Duplicate routes found!" warning. - Remove the corresponding docs preset block and osmosis-outpost defineSection from docusaurus.config.js. - Remove broken Outpost card from src/pages/index.jsx landing page. - Remove dead commented-out UIKitReferencePlugins import in docusaurus.config.js (the file plugins/ui-kit-reference-plugin.cjs was already gone).
Each of cosmwasm/, frontend/, osmojs/, telescope/, and beaker/ is its own plugin-content-docs instance with an autogenerated sidebar. Adding _category_.json so their sidebar styling matches overview/ (red className, generated index, description). Beaker uses collapsed: true and a "(legacy)" suffix to signal its soft-deprecation in favour of cw-orch without removing the content.
Three categories under overview/ shared position 4 (educate, integrate, validate), so sidebar ordering fell back to alphabetical. Renumber to 1/2/3 to enforce the intended Educate -> Integrate -> Validate -> Endpoints (5) -> Features (6) sequence. Same fix in osmosis-core/: keys was tied with relaying at position 5; bump keys to 6 so relaying lands first.
Docusaurus's default switches the navbar to the hamburger menu at 996px. After adding the CosmWasm pill and the SDKs dropdown in this PR (9 navbar items + search + GitHub/Discord icons), the desktop layout was overflowing well before 996px, leaving the top bar empty or clipped between roughly 1000px and 1280px. Override the Infima breakpoint in custom.css: between 997px and 1280px, show the hamburger toggle and hide the left-side navbar items and right-side search/social icons. The Launch Dex button and the logo stay visible. The mobile sidebar already contains the full navbar via its existing "Back to main menu" affordance. Tested locally: yarn build clean, no broken-link errors.
3cab1a0 to
a728633
Compare
…drawer Two adjustments to the navbar breakpoint introduced earlier in this PR (originally 997-1280px): - Extend the upper bound from 1280px to 1440px. The desktop layout was still squashing slightly between those values with the current 9 navbar items + dropdown + search; 1440px gives the row enough breathing room. - Constrain the navbar-sidebar drawer that slides in when the hamburger is clicked to a 320px panel within this range, instead of taking over the full viewport. Below 996px, Docusaurus's own full-width mobile drawer continues to apply.
…cSidebar The navbar hamburger now triggers at 1440px to avoid overflow with the nine top-level items added in this PR. The unintended side effect was that Docusaurus's built-in DocSidebar dispatcher reads window size from useWindowSize() (hard-coded 996px threshold) and only renders the desktop docs-sidebar above that width. Every tablet- and small-laptop reader between 997-1440px lost the page TOC because it had moved into the mobile drawer. Swizzle the DocSidebar dispatcher with a local copy that uses its own threshold (768px). The docs sidebar now stays mounted on the page down to 768px, independently of the navbar hamburger which still kicks in at 1440px. The mobile drawer continues to handle below-768 widths. The Desktop and Mobile sub-components are not swizzled; only the dispatcher.
The CSS earlier in this PR shows the hamburger button between 997px and 1440px so the top bar does not overflow, but Docusaurus's own NavbarMobileSidebar component returns null when useWindowSize() === 'desktop' (anything above 996px). The result was a clickable hamburger that opened an empty grey drawer at tablet and small-laptop widths. Swizzle the dispatcher and bypass the shouldRender gate. The drawer renders whenever the navbar has items; the shown state still drives the slide-in animation, body scroll lock and history-pop close are preserved, and below 996px the existing Docusaurus mobile UX is unchanged. Also revert the "Menu" label that I added on the hamburger toggle in the previous push - the icon alone is enough now that the drawer actually contains the items.
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 0ff281c. Configure here.
| } | ||
| window.addEventListener('resize', update); | ||
| return () => window.removeEventListener('resize', update); | ||
| }, []); |
There was a problem hiding this comment.
DocSidebar hydration mismatch on mobile viewports
Medium Severity
The useDocSidebarWindowSize hook uses useState(() => getWindowSize()) as its initializer. During SSR, canUseDOM is false so it returns 'ssr', but during client hydration, canUseDOM is true so it evaluates window.innerWidth and returns 'desktop' or 'mobile'. On viewports ≤768px, the server renders DocSidebarDesktop (because 'ssr' maps to renderDesktop) but the client's first render produces DocSidebarMobile, causing a React hydration mismatch. The official Docusaurus useWindowSize hook explicitly initializes with a constant 'ssr' string and defers the real measurement to useEffect, calling updateWindowSize() immediately on mount. This swizzled version also omits that initial update() call inside useEffect, meaning if the initializer were fixed to 'ssr', the size would never update until a resize event occurs.
Reviewed by Cursor Bugbot for commit 0ff281c. Configure here.


Three independent cleanups bundled into one PR because they all touch
docusaurus.config.jsand reading them together is easier than three small reviews.1. Delete deprecated
osmosis-outpost/section (53 files)The Outpost product is no longer maintained by Nabla Studio — their website no longer features it, the related assetlist repo has been dormant since 2023, and four of the section's pages still contain unresolved
<!-- TODO: add official name of the npm package -->placeholders.docs/osmosis-outpost/(53 files, ~2,180 lines).defineSection('osmosis-outpost')fromdocusaurus.config.js.src/pages/index.jsx.2. Delete empty home preset
docs/home/README.mdxwas empty (0 bytes) but mounted atrouteBasePath: '/'.src/pages/index.jsxalso claims/and renders the actual styled landing page. The build emitted[WARNING] Duplicate routes found!every time as a result.docs/home/README.mdxandsidebars-home.js.docusaurus.config.js, change the classic preset'sdocs: { ... }block todocs: false—src/pages/index.jsxbecomes the sole owner of/.3. Surface previously-invisible sections in the navbar
Five top-level sections —
cosmwasm,frontend,osmojs,telescope,beaker— had no navbar entry, making them reachable only via search or deep links (~33 doc pages affected). This PR makes them all discoverable.CosmWasmas a top-level navbar pill.SDKsdropdown groupingFrontend / OsmoJS / Telescope / Beaker (legacy)._category_.jsonto all five sections so their sidebar styling matchesoverview/(red category headers +descriptions). Beaker uses
collapsed: trueand a(legacy)suffix to telegraph its soft-deprecated status in favour of cw-orch.Developnavbar item fromposition: 'right'to'left'so all content pills cluster together.activeBaseRegex: '(.*ui-kit|.*web-core)'on the Develop item (the regex matched routes that don't exist).UIKitReferencePluginsimport (the referenced plugin file was already gone).4. Fix
_category_.jsonposition collisionsSidebars were ordering some entries alphabetically because multiple categories shared the same
positionvalue:overview/:educate,integrate, andvalidatewere all at position4. Renumber to1 / 2 / 3.endpoints(5) andfeatures(6) stay.osmosis-core/:keysandrelayingwere both at position5. Bumpkeysto6.Verification
yarn buildsucceeds (159s, no broken-link errors, noDuplicate routes found!warning)overview/is Educate → Integrate → Validate → Endpoints → FeaturesThis change has been tested locally by rebuilding the doc website and verified content and links are expected
Note
Medium Risk
Medium risk because it changes Docusaurus routing/navigation config and swizzles core theme components/CSS breakpoints, which could regress site layout or sidebar behavior across viewports.
Overview
Removes the entire deprecated
docs/osmosis-outpostsection and drops its references (including the homepage card anddefineSection('osmosis-outpost')).Fixes a duplicate-route warning by disabling the classic preset
docsinstance (docs: false) sosrc/pages/index.jsxsolely owns/, and deletes the now-unusedsidebars-home.js.Makes previously hard-to-discover sections visible in the navbar (adds
CosmWasmand anSDKsdropdown forfrontend,osmojs,telescope,beaker) and adds_category_.jsonmetadata + ordering tweaks to resolve sidebar position collisions.Adjusts responsive behavior by forcing the navbar hamburger earlier (CSS up to 1440px) and swizzling
DocSidebar/NavbarMobileSidebarso the docs sidebar stays desktop down to 768px while the hamburger drawer still renders correctly above Docusaurus’s default 996px threshold.Reviewed by Cursor Bugbot for commit 0ff281c. Bugbot is set up for automated code reviews on this repo. Configure here.