Skip to content

Commit f8ce085

Browse files
author
Lasim
committed
feat: integrate CustomNavbar into documentation layout and update title in index.mdx
1 parent b6a942a commit f8ce085

5 files changed

Lines changed: 10 additions & 23 deletions

File tree

app/docs/[[...slug]]/page.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import { DocsPage, DocsBody } from 'fumadocs-ui/page';
33
import { notFound } from 'next/navigation';
44
import { source } from '@/lib/source';
55
import { generatePageMetadata, getCanonicalUrl } from '@/lib/seo-utils';
6+
import { CustomNavbar } from '@/lib/components/CustomNavbar';
67

78
export default async function Page({
89
params,
@@ -20,6 +21,7 @@ export default async function Page({
2021

2122
return (
2223
<DocsPage toc={page.data.toc} full={page.data.full}>
24+
<CustomNavbar />
2325
<DocsBody>
2426
<h1>{page.data.title}</h1>
2527
<MDX />

app/docs/layout.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,15 +2,15 @@ import { DocsLayout } from 'fumadocs-ui/layouts/docs';
22
import type { ReactNode } from 'react';
33
import { baseOptions } from '../layout.config';
44
import { source } from '../../lib/source';
5-
import { CustomNavbar } from '../../lib/components/CustomNavbar';
65

76
export default function Layout({ children }: { children: ReactNode }) {
87
return (
98
<DocsLayout
109
{...baseOptions}
1110
tree={source.pageTree}
1211
nav={{
13-
component: <CustomNavbar />,
12+
title: 'DeployStack Docs',
13+
url: '/docs',
1414
}}
1515
sidebar={{
1616
defaultOpenLevel: 1,

app/global.css

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,7 @@
1111
@import 'fumadocs-ui/css/preset.css'; /* Core Fumadocs UI styles */
1212

1313
/* Custom navbar styling to match main site */
14-
:root {
15-
--fd-nav-height: 80px; /* Height for custom navbar */
16-
}
14+
/* Navbar height override removed since navbar is now inside content area */
1715

1816
/* Ensure logo and navigation styling matches main site */
1917
.fd-nav-title {

docs/index.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
title: Home
2+
title: DeployStack Documentation
33
description: Welcome to DeployStack documentation. Learn how to automate Docker Compose deployments across cloud providers with Infrastructure as Code templates and one-click deployments.
44
menuTitle: DeployStack Documentation
55
---

lib/components/CustomNavbar.tsx

Lines changed: 4 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ import { GithubIcon, Menu } from 'lucide-react';
55

66
export function CustomNavbar() {
77
return (
8-
<div className="mx-auto sm:px-0 md:px-6 lg:px-8 max-w-7xl">
9-
<header className="md:mt-7 md:bg-slate-50 flex items-center justify-between gap-8 rounded-full lg:border border-border px-2.5 py-5 md:py-1.5 backdrop-blur-lg md:top-6 mx-auto w-full max-w-7xl">
8+
<div className="w-full mb-6 hidden md:block">
9+
<header className="bg-slate-50 flex items-center justify-between gap-8 rounded-full border border-border px-4 py-3 backdrop-blur-lg w-full">
1010
{/* Logo and Main Navigation */}
1111
<div className="flex items-center gap-3">
1212
<div className="ml-3 flex items-center gap-3 mr-10">
@@ -19,7 +19,6 @@ export function CustomNavbar() {
1919
height={24}
2020
className="inline w-[22px] h-[24px] -mt-1"
2121
/>
22-
<span className="ml-2 text-[18px] font-semibold">DeployStack</span>
2322
</Link>
2423
</div>
2524

@@ -29,20 +28,7 @@ export function CustomNavbar() {
2928
<ul className="menu flex gap-6" data-orientation="horizontal">
3029
<li>
3130
<Link href="https://deploystack.io/mcp" className="hover:text-primary transition-colors">
32-
Browse MCP Server
33-
</Link>
34-
</li>
35-
<li>
36-
<Link href="https://deploystack.io/c" className="hover:text-primary transition-colors">
37-
Browse Docker
38-
</Link>
39-
</li>
40-
<li>
41-
<Link
42-
href="/docs"
43-
className="text-primary font-semibold hover:text-primary/80 transition-colors"
44-
>
45-
Documentation
31+
MCP Server
4632
</Link>
4733
</li>
4834
<li>
@@ -86,6 +72,7 @@ export function CustomNavbar() {
8672
{/* Login Button */}
8773
<Link
8874
href="https://cloud.deploystack.io/login"
75+
target="_blank"
8976
className="items-center justify-center gap-2 whitespace-nowrap text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 bg-black text-white shadow hover:bg-gray-800 h-9 px-4 py-2 rounded-full hidden md:inline-flex"
9077
>
9178
Login

0 commit comments

Comments
 (0)