Skip to content

Commit 6ee2266

Browse files
committed
More progress
1 parent a65942d commit 6ee2266

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+481
-822
lines changed

src/app/(authenticated)/dashboard/layout.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,12 @@ export default function DashboardLayout({
1616
return (
1717
<>
1818
<div className="shadow-md">
19-
<div className="mx-auto flex max-w-screen-xl items-center justify-between px-3 py-4">
19+
<div className="mx-auto flex max-w-screen-lg items-center justify-between px-4 py-4">
2020
<DashboardHeader />
2121
</div>
2222
</div>
2323
<div className="min-h-[calc(100vh-72px)] bg-muted">
24-
<div className="mx-auto max-w-screen-xl px-3 pb-16 pt-6">
24+
<div className="mx-auto max-w-screen-lg px-4 pb-16 pt-6">
2525
{children}
2626
</div>
2727
</div>
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
'use client';
2+
3+
import { useTheme } from 'next-themes';
4+
import { dark } from '@clerk/themes';
5+
import { OrganizationProfile } from '@clerk/nextjs';
6+
7+
export const OrgProfile = () => {
8+
const { resolvedTheme } = useTheme();
9+
const baseTheme = resolvedTheme === 'dark' ? dark : undefined;
10+
11+
return (
12+
<OrganizationProfile
13+
appearance={{ baseTheme }}
14+
routing="path"
15+
path="/dashboard/org"
16+
afterLeaveOrganizationUrl="/onboarding/select-org"
17+
/>
18+
);
19+
};
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
import { OrgProfile } from './OrgProfile';
2+
3+
export default function Page() {
4+
return <OrgProfile />;
5+
}

src/app/(authenticated)/dashboard/organization-profile/[[...organization-profile]]/page.tsx

Lines changed: 0 additions & 23 deletions
This file was deleted.

src/app/(authenticated)/dashboard/page.tsx

Lines changed: 3 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -2,36 +2,10 @@ import { useTranslations } from 'next-intl';
22

33
import { TitleBar } from '@/components/dashboard/TitleBar';
44

5-
const DashboardIndexPage = () => {
5+
export default function Page() {
66
const t = useTranslations('DashboardIndex');
77

88
return (
9-
<>
10-
<TitleBar
11-
title={t('title_bar')}
12-
description={t('title_bar_description')}
13-
/>
14-
<div className="flex h-[600px] flex-col items-center justify-center rounded-md bg-card p-5">
15-
<div className="size-16 rounded-full bg-muted p-3 [&_svg]:stroke-muted-foreground [&_svg]:stroke-2">
16-
<svg
17-
xmlns="http://www.w3.org/2000/svg"
18-
viewBox="0 0 24 24"
19-
fill="none"
20-
strokeLinecap="round"
21-
strokeLinejoin="round"
22-
>
23-
<path d="M0 0h24v24H0z" stroke="none" />
24-
<path d="M12 3l8 4.5v9L12 21l-8-4.5v-9L12 3M12 12l8-4.5M12 12v9M12 12L4 7.5" />
25-
</svg>
26-
</div>
27-
<div className="mt-3 text-center">
28-
<div className="text-xl font-semibold">
29-
{t('message_state_title')}
30-
</div>
31-
</div>
32-
</div>
33-
</>
9+
<TitleBar title={t('title_bar')} description={t('title_bar_description')} />
3410
);
35-
};
36-
37-
export default DashboardIndexPage;
11+
}

src/app/(authenticated)/dashboard/user-profile/[[...user-profile]]/page.tsx

Lines changed: 0 additions & 22 deletions
This file was deleted.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
'use client';
2+
3+
import { useTheme } from 'next-themes';
4+
import { dark } from '@clerk/themes';
5+
import { UserProfile as ClerkUserProfile } from '@clerk/nextjs';
6+
7+
export const UserProfile = () => {
8+
const { resolvedTheme } = useTheme();
9+
const baseTheme = resolvedTheme === 'dark' ? dark : undefined;
10+
11+
return (
12+
<ClerkUserProfile
13+
appearance={{ baseTheme }}
14+
routing="path"
15+
path="/dashboard/user"
16+
/>
17+
);
18+
};
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
import { UserProfile } from './UserProfile';
2+
3+
export default function Page() {
4+
return <UserProfile />;
5+
}

src/app/(authenticated)/layout.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { redirect } from 'next/navigation';
22
import { auth as clerkAuth } from '@clerk/nextjs/server';
33

4-
export default async function CenteredLayout({
4+
export default async function AuthenticatedLayout({
55
children,
66
}: {
77
children: React.ReactNode;

src/app/layout.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import { getLocale } from 'next-intl/server';
66
import { enUS, frFR } from '@clerk/localizations';
77
import { ClerkProvider } from '@clerk/nextjs';
88

9-
import { ThemeProvider } from '@/components/ThemeProvider';
9+
import { ThemeProvider } from '@/components/layout/ThemeProvider';
1010

1111
export const metadata: Metadata = {
1212
icons: [

0 commit comments

Comments
 (0)