shitton of changes #2

Closed
NerfedJabolo wants to merge 6 commits from main into main
6 changed files with 63 additions and 27 deletions
Showing only changes of commit ed8ccd0e2f - Show all commits

3
.gitignore vendored
View file

@ -34,3 +34,6 @@ yarn-error.log*
# typescript # typescript
*.tsbuildinfo *.tsbuildinfo
next-env.d.ts next-env.d.ts
#bun
bun.lockb

9
app/docs/page.tsx Normal file
View file

@ -0,0 +1,9 @@
import Sidebar from '@/components/shared/Sidebar';
export default function Page() {
return (
<>
<Sidebar />
</>
);
}

View file

@ -1,16 +1,17 @@
import type { Metadata } from "next"; import type { Metadata } from 'next';
import { Poppins } from "next/font/google"; import { Poppins } from 'next/font/google';
import "./globals.css"; import './globals.css';
import { ThemeProvider } from "@/components/shared/providers/themeprovider"; import { ThemeProvider } from '@/components/shared/providers/themeprovider';
import Navbar from '@/components/shared/Navbar';
const poppins = Poppins({ const poppins = Poppins({
weight: ["400", "600", "700", "900"], weight: ['400', '600', '700', '900'],
subsets: ["latin"], subsets: ['latin'],
}); });
export const metadata: Metadata = { export const metadata: Metadata = {
title: "SVRJS - A Web Server running on Nodejs", title: 'SVRJS - A Web Server running on Nodejs',
description: "Open Source Software Library", description: 'Open Source Software Library',
}; };
export default function RootLayout({ export default function RootLayout({
@ -27,6 +28,7 @@ export default function RootLayout({
enableSystem enableSystem
disableTransitionOnChange disableTransitionOnChange
> >
<Navbar />
{children} {children}
</ThemeProvider> </ThemeProvider>
</body> </body>

View file

@ -1,13 +1,11 @@
import About from "@/components/shared/About"; import About from '@/components/shared/About';
import Hero from "@/components/shared/Hero"; import Hero from '@/components/shared/Hero';
import HowItWorks from "@/components/shared/HowItWorks"; import HowItWorks from '@/components/shared/HowItWorks';
import Navbar from "@/components/shared/Navbar"; import Newsletter from '@/components/shared/Newsletter';
import Newsletter from "@/components/shared/Newsletter";
const RootPage = () => { const RootPage = () => {
return ( return (
<> <>
<Navbar />
<Hero /> <Hero />
<HowItWorks /> <HowItWorks />
<About /> <About />

View file

@ -1,17 +1,17 @@
"use client"; 'use client';
import { import {
NavigationMenu, NavigationMenu,
NavigationMenuItem, NavigationMenuItem,
NavigationMenuList, NavigationMenuList,
} from "@radix-ui/react-navigation-menu"; } from '@radix-ui/react-navigation-menu';
import Image from "next/image"; import Image from 'next/image';
import Link from "next/link"; import Link from 'next/link';
import ThemeToggle from "../ui/theme-toggle"; import ThemeToggle from '../ui/theme-toggle';
import { NAVBAR } from "@/constants"; import { NAVBAR } from '@/constants';
import { buttonVariants } from "../ui/button"; import { buttonVariants } from '../ui/button';
import MobileNav from "./MobileNav"; import MobileNav from './MobileNav';
import { usePathname } from "next/navigation"; import { usePathname } from 'next/navigation';
const Navbar = () => { const Navbar = () => {
const pathname = usePathname(); const pathname = usePathname();
@ -50,9 +50,9 @@ const Navbar = () => {
href={href} href={href}
target={target} target={target}
className={`text-[18px] tracking-tight ${ className={`text-[18px] tracking-tight ${
pathname == href ? "bg-accent/40" : "" pathname == href ? 'bg-accent/40' : ''
} ${buttonVariants({ } ${buttonVariants({
variant: "ghost", variant: 'ghost',
})}`} })}`}
> >
{label} {label}
@ -61,12 +61,12 @@ const Navbar = () => {
</nav> </nav>
<div className="hidden md:flex gap-2 items-center"> <div className="hidden md:flex gap-2 items-center">
{NAVBAR.rightLinks?.map(({ href = "", label, target }) => ( {NAVBAR.rightLinks?.map(({ href = '', label, target }) => (
<Link <Link
key={label} key={label}
href={href} href={href}
target={target} target={target}
className={`border ${buttonVariants({ variant: "ghost" })}`} className={`border ${buttonVariants({ variant: 'ghost' })}`}
> >
<Image <Image
src="/next.svg" src="/next.svg"

View file

@ -0,0 +1,24 @@
import React from 'react';
const Sidebar = () => {
return (
<div className="w-[250px] h-[100vh] border-r dark:border-r-slate-800 pl-4 pt-2">
<span className="flex flex-col gap-2">
<h2 className="text-2xl font-bold">First use</h2>
<ul className="pl-4 flex flex-col gap-2">
<li>System requirements</li>
<li>Installation</li>
<li>Features</li>
<li>SVR.JS files</li>
<li>SVR.JS utilities</li>
<li>SVR.JS commands</li>
<li>Updating SVR.JS</li>
<li>Common problems</li>
<li>Bun support</li>
</ul>
</span>
</div>
);
};
export default Sidebar;