mirror of
https://codeberg.org/MarkusThielker/next-ory.git
synced 2025-07-03 05:19:18 +00:00
NORY-8: add sidebar to the application
Moved theme toggle and logout button to the footer of the sidebar
This commit is contained in:
parent
7d04a8faa1
commit
101601c287
6 changed files with 121 additions and 33 deletions
3
dashboard/src/app/application/page.tsx
Normal file
3
dashboard/src/app/application/page.tsx
Normal file
|
@ -0,0 +1,3 @@
|
|||
export default async function ApplicationPage() {
|
||||
return <></>;
|
||||
}
|
|
@ -5,6 +5,8 @@ import { cn } from '@/lib/utils';
|
|||
import { Toaster } from '@/components/ui/sonner';
|
||||
import React from 'react';
|
||||
import { ThemeProvider } from 'next-themes';
|
||||
import { SidebarProvider, SidebarTrigger } from '@/components/ui/sidebar';
|
||||
import { AppSidebar } from '@/components/app-sidebar';
|
||||
|
||||
const inter = Inter({ subsets: ['latin'] });
|
||||
|
||||
|
@ -53,8 +55,14 @@ export default function RootLayout({ children }: Readonly<{ children: React.Reac
|
|||
enableSystem
|
||||
disableTransitionOnChange
|
||||
>
|
||||
{children}
|
||||
<Toaster/>
|
||||
<SidebarProvider>
|
||||
<AppSidebar/>
|
||||
<SidebarTrigger className="m-2"/>
|
||||
<main className="w-full min-h-screen">
|
||||
{children}
|
||||
<Toaster/>
|
||||
</main>
|
||||
</SidebarProvider>
|
||||
</ThemeProvider>
|
||||
</main>
|
||||
</body>
|
||||
|
|
|
@ -1,16 +1,3 @@
|
|||
'use server';
|
||||
|
||||
import React from 'react';
|
||||
import { ThemeToggle } from '@/components/themeToggle';
|
||||
import { LogoutButton } from '@/components/auth/logout';
|
||||
|
||||
export default async function Page() {
|
||||
return (
|
||||
<div className="flex flex-col min-h-screen items-center text-3xl relative space-y-4">
|
||||
<div className="absolute flex flex-row w-fit items-center space-x-4 top-4 right-4">
|
||||
<ThemeToggle/>
|
||||
<LogoutButton/>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
export default async function RootPage() {
|
||||
return <></>;
|
||||
}
|
||||
|
|
3
dashboard/src/app/user/page.tsx
Normal file
3
dashboard/src/app/user/page.tsx
Normal file
|
@ -0,0 +1,3 @@
|
|||
export default async function UserPage() {
|
||||
return <></>;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue