Skip to content

Commit

Permalink
fix things and add cockpit docs
Browse files Browse the repository at this point in the history
  • Loading branch information
arlyon committed Nov 10, 2024
1 parent 58a439b commit b3fcb80
Show file tree
Hide file tree
Showing 27 changed files with 1,232 additions and 176 deletions.
98 changes: 74 additions & 24 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

37 changes: 31 additions & 6 deletions site/app/cockpit/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import { Header } from "../registry/layout";
import { RefreshingToggle } from "@/components/refreshing-toggle";
import { auth } from "@clerk/nextjs/server";
import { client } from "@/lib/cockpit-client";
import { SidebarProvider, SidebarTrigger } from "@/components/ui/sidebar";

export default async function CockpitPage({ children }) {
const userData = await auth.protect();
Expand All @@ -23,13 +24,37 @@ export default async function CockpitPage({ children }) {

return (
<ClerkProvider>
<Header title="Cockpit" link="/cockpit" suspend={false} />
<div className="relative flex-1 flex">
{children}
<div className="absolute top-4 sm:left-4 px-4 py-2 rounded-xl bg-background border">
<RefreshingToggle initialData={servers} userId={userData.userId} />
<SidebarProvider className="flex flex-col">
<Header title="Cockpit" link="/cockpit" suspend={false} />
<div className="relative flex-1 flex">
{/* <AppSidebar /> */}
{children}
<div className="absolute top-4 left-4 p-1 rounded-xl bg-background border">
<RefreshingToggle initialData={servers} userId={userData.userId} />
</div>
</div>
</div>
</SidebarProvider>
</ClerkProvider>
);
}

import {
Sidebar,
SidebarContent,
SidebarFooter,
SidebarGroup,
SidebarHeader,
} from "@/components/ui/sidebar";

export function AppSidebar() {
return (
<Sidebar>
<SidebarHeader />
<SidebarContent>
<SidebarGroup />
<SidebarGroup />
</SidebarContent>
<SidebarFooter />
</Sidebar>
);
}
2 changes: 1 addition & 1 deletion site/app/cockpit/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const client = new QueryClient();

export default function CockpitPage() {
return (
<div className="flex flex-col w-full flex-1 relative items-center pt-32 justify-center bg-gradient-to-t from-green-950 to-black">
<div className="flex flex-col w-full flex-1 relative items-center pt-32 justify-center bg-gradient-to-b dark:to-green-950 to-green-200 dark:from-black from-white">
<h1 className="text-4xl md:text-6xl font-bold text-center mx-8">
Searching for Litehouses...
</h1>
Expand Down
2 changes: 0 additions & 2 deletions site/app/docs/[[...slug]]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,6 @@ export default async function Page({

const MDX = page.data.body;

console.log(page);

return (
<DocsPage
toc={page.data.toc}
Expand Down
16 changes: 16 additions & 0 deletions site/app/global.css → site/app/globals.css
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,14 @@
--chart-3: 197 37% 24%;
--chart-4: 43 74% 66%;
--chart-5: 27 87% 67%;
--sidebar-background: 0 0% 98%;
--sidebar-foreground: 240 5.3% 26.1%;
--sidebar-primary: 240 5.9% 10%;
--sidebar-primary-foreground: 0 0% 98%;
--sidebar-accent: 240 4.8% 95.9%;
--sidebar-accent-foreground: 240 5.9% 10%;
--sidebar-border: 220 13% 91%;
--sidebar-ring: 217.2 91.2% 59.8%;
}

.dark {
Expand Down Expand Up @@ -56,6 +64,14 @@
--chart-3: 30 80% 55%;
--chart-4: 280 65% 60%;
--chart-5: 340 75% 55%;
--sidebar-background: 240 5.9% 10%;
--sidebar-foreground: 240 4.8% 95.9%;
--sidebar-primary: 224.3 76.3% 48%;
--sidebar-primary-foreground: 0 0% 100%;
--sidebar-accent: 240 3.7% 15.9%;
--sidebar-accent-foreground: 240 4.8% 95.9%;
--sidebar-border: 240 3.7% 15.9%;
--sidebar-ring: 217.2 91.2% 59.8%;
}
}

Expand Down
2 changes: 1 addition & 1 deletion site/app/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { Toaster } from "@/components/ui/sonner";
import "./global.css";
import "./globals.css";
import { Footer } from "@/components/footer";
import { RootProvider } from "fumadocs-ui/provider";
import type { Metadata } from "next";
Expand Down
3 changes: 0 additions & 3 deletions site/app/registry/layout.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { LoginButton } from "@/components/login-button";
import { ManifestEditor } from "@/components/manifest-editor";
import { ThemeToggle } from "@/components/theme-toggle";
import { ClerkProvider } from "@clerk/nextjs";
import { PackageIcon, SearchIcon } from "lucide-react";
Expand Down Expand Up @@ -46,8 +45,6 @@ export const Header = ({
placeholder="Search packages..."
type="text"
/>
<ThemeToggle className="hidden md:inline-flex" />
<ManifestEditor className="hidden md:block" />
<div>
<div className="size-[28px]">
<ErrorBoundary
Expand Down
Loading

0 comments on commit b3fcb80

Please sign in to comment.