-
-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add settings page UI #22
Merged
Merged
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
bc9d769
add settings page UI
SkidGod4444 8d71342
update lock-file
SkidGod4444 24757ca
chore: format code with Prettier
github-actions[bot] 05e1722
fix linting issue
SkidGod4444 2e27916
fix linting issue
SkidGod4444 a49ebb5
Update InfoBar
SkidGod4444 4534add
add dashboard page
SkidGod4444 c6a6848
add dashboard page
SkidGod4444 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,6 +5,7 @@ node_modules | |
.pnp | ||
.pnp.js | ||
|
||
|
||
# Local env files | ||
.env | ||
.env.local | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +0,0 @@ | ||
public-hoist-pattern[]=* | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,125 @@ | ||
"use client"; | ||
import { IconCoins, IconInfoSquareRounded } from "@tabler/icons-react"; | ||
import { Card, CardContent, CardHeader, CardTitle } from "@/components/ui/card"; | ||
import { Tabs, TabsContent, TabsList, TabsTrigger } from "@/components/ui/tabs"; | ||
|
||
export default function Home() { | ||
return ( | ||
<div className="flex flex-col h-full w-full items-start overflow-hidden px-5 md:px-2"> | ||
<Tabs defaultValue="overview" className="space-y-5"> | ||
<TabsList> | ||
<TabsTrigger value="overview">Overview</TabsTrigger> | ||
<TabsTrigger value="analytics">Analytics</TabsTrigger> | ||
<TabsTrigger value="reports">Reports</TabsTrigger> | ||
<TabsTrigger value="notifications">Notifications</TabsTrigger> | ||
</TabsList> | ||
<TabsContent value="overview" className="space-y-4"> | ||
<div className="grid gap-4 md:grid-cols-3 lg:grid-cols-5"> | ||
<Card> | ||
<CardHeader className="flex flex-row items-center justify-between space-y-0 pb-2"> | ||
<CardTitle className="text-sm font-medium"> | ||
Queries Resolved | ||
</CardTitle> | ||
<IconInfoSquareRounded className="size-5 text-muted-foreground" /> | ||
</CardHeader> | ||
<CardContent> | ||
<div className="text-2xl font-bold">45,321</div> | ||
<p className="text-xs text-muted-foreground"> | ||
+20.1% from last month | ||
</p> | ||
</CardContent> | ||
</Card> | ||
<Card> | ||
<CardHeader className="flex flex-row items-center justify-between space-y-0 pb-2"> | ||
<CardTitle className="text-sm font-medium">Mails</CardTitle> | ||
<svg | ||
xmlns="http://www.w3.org/2000/svg" | ||
viewBox="0 0 24 24" | ||
fill="none" | ||
stroke="currentColor" | ||
strokeLinecap="round" | ||
strokeLinejoin="round" | ||
strokeWidth="2" | ||
className="h-4 w-4 text-muted-foreground" | ||
> | ||
<path d="M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2" /> | ||
<circle cx="9" cy="7" r="4" /> | ||
<path d="M22 21v-2a4 4 0 0 0-3-3.87M16 3.13a4 4 0 0 1 0 7.75" /> | ||
</svg> | ||
</CardHeader> | ||
<CardContent> | ||
<div className="text-2xl font-bold">+2350</div> | ||
<p className="text-xs text-muted-foreground"> | ||
+180.1% from last month | ||
</p> | ||
</CardContent> | ||
</Card> | ||
<Card> | ||
<CardHeader className="flex flex-row items-center justify-between space-y-0 pb-2"> | ||
<CardTitle className="text-sm font-medium">Sales</CardTitle> | ||
<svg | ||
xmlns="http://www.w3.org/2000/svg" | ||
viewBox="0 0 24 24" | ||
fill="none" | ||
stroke="currentColor" | ||
strokeLinecap="round" | ||
strokeLinejoin="round" | ||
strokeWidth="2" | ||
className="h-4 w-4 text-muted-foreground" | ||
> | ||
<rect width="20" height="14" x="2" y="5" rx="2" /> | ||
<path d="M2 10h20" /> | ||
</svg> | ||
</CardHeader> | ||
<CardContent> | ||
<div className="text-2xl font-bold">+12,234</div> | ||
<p className="text-xs text-muted-foreground"> | ||
+19% from last month | ||
</p> | ||
</CardContent> | ||
</Card> | ||
<Card> | ||
<CardHeader className="flex flex-row items-center justify-between space-y-0 pb-2"> | ||
<CardTitle className="text-sm font-medium"> | ||
Events Logged | ||
</CardTitle> | ||
<svg | ||
xmlns="http://www.w3.org/2000/svg" | ||
viewBox="0 0 24 24" | ||
fill="none" | ||
stroke="currentColor" | ||
strokeLinecap="round" | ||
strokeLinejoin="round" | ||
strokeWidth="2" | ||
className="h-4 w-4 text-muted-foreground" | ||
> | ||
<path d="M22 12h-4l-3 9L9 3l-3 9H2" /> | ||
</svg> | ||
</CardHeader> | ||
<CardContent> | ||
<div className="text-2xl font-bold">+573</div> | ||
<p className="text-xs text-muted-foreground"> | ||
+201 since last hour | ||
</p> | ||
</CardContent> | ||
</Card> | ||
<Card> | ||
<CardHeader className="flex flex-row items-center justify-between space-y-0 pb-2"> | ||
<CardTitle className="text-sm font-medium"> | ||
Credits Left | ||
</CardTitle> | ||
<IconCoins className="size-5 text-muted-foreground" /> | ||
</CardHeader> | ||
<CardContent> | ||
<div className="text-2xl font-bold">2346</div> | ||
<p className="text-xs text-muted-foreground"> | ||
+201 since last hour | ||
</p> | ||
</CardContent> | ||
</Card> | ||
</div> | ||
</TabsContent> | ||
</Tabs> | ||
</div> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
"use client"; | ||
import InfoBreadCrumb from "@/components/custom/infobar/bread-crumb"; | ||
import BillingSettings from "@/components/custom/settings/billing.settings"; | ||
import ThemeSettings from "@/components/custom/settings/theme.settings"; | ||
import React from "react"; | ||
|
||
export default function SettingsPage() { | ||
return ( | ||
<div className="flex flex-col h-full w-full items-start overflow-hidden px-5 md:px-2"> | ||
<InfoBreadCrumb /> | ||
<div className="flex flex-col gap-10"> | ||
<BillingSettings /> | ||
<ThemeSettings /> | ||
</div> | ||
</div> | ||
); | ||
} |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,49 @@ | ||
import type { Metadata } from "next"; | ||
import localFont from "next/font/local"; | ||
import { GeistSans } from "geist/font/sans"; | ||
import "./globals.css"; | ||
|
||
const geistSans = localFont({ | ||
src: "./fonts/GeistVF.woff", | ||
variable: "--font-geist-sans", | ||
weight: "100 900", | ||
}); | ||
const geistMono = localFont({ | ||
src: "./fonts/GeistMonoVF.woff", | ||
variable: "--font-geist-mono", | ||
weight: "100 900", | ||
}); | ||
import { ThemeProvider } from "@/hooks/theme-provider"; | ||
import { SidebarProvider } from "@/components/ui/sidebar"; | ||
import { AppSidebar } from "@/components/custom/sidebar/sidebar"; | ||
import { cookies } from "next/headers"; | ||
import Infobar from "@/components/custom/infobar/infobar"; | ||
import ProgressBar from "@/components/custom/progress.bar"; | ||
|
||
export const metadata: Metadata = { | ||
title: "Create Next App", | ||
title: "Plura", | ||
description: "Generated by create next app", | ||
}; | ||
|
||
export default function RootLayout({ | ||
async function RootLayout({ | ||
children, | ||
}: Readonly<{ | ||
children: React.ReactNode; | ||
}>) { | ||
const cookieStore = await cookies(); | ||
const defaultOpen = cookieStore.get("plura-sidebar:state")?.value === "true"; | ||
|
||
SkidGod4444 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
return ( | ||
<html lang="en"> | ||
<html lang="en" suppressHydrationWarning> | ||
<body | ||
className={`${geistSans.variable} ${geistMono.variable} antialiased`} | ||
className={`min-h-screen bg-background font-sans ${GeistSans.variable} antialiased`} | ||
> | ||
{children} | ||
<ThemeProvider | ||
attribute="class" | ||
defaultTheme="dark" | ||
enableSystem | ||
disableTransitionOnChange | ||
> | ||
<SidebarProvider defaultOpen={defaultOpen}> | ||
<AppSidebar /> | ||
<div className="p-2"> | ||
<ProgressBar /> | ||
<Infobar /> | ||
{children} | ||
</div> | ||
</SidebarProvider> | ||
</ThemeProvider> | ||
</body> | ||
</html> | ||
); | ||
} | ||
|
||
export default RootLayout; |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Implement missing tab content sections.
The component includes tab triggers for "Analytics", "Reports", and "Notifications" but lacks their corresponding
TabsContent
implementations. This creates a confusing user experience when users click these tabs.Consider either:
Example implementation structure: