Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
66 commits
Select commit Hold shift + click to select a range
bb938b0
refactor: redesign discussion components with brutalist terminal aest…
ElhamDevelopmentStudio Aug 1, 2025
334be66
refactor: update discussion thread and panel components
ElhamDevelopmentStudio Aug 1, 2025
7ceee91
config: add discussions configuration file
ElhamDevelopmentStudio Aug 1, 2025
9fb6bdd
refactor: redesign problem library and filters with monospace typography
ElhamDevelopmentStudio Aug 1, 2025
9f0536b
refactor: redesign problem reader and workspace components
ElhamDevelopmentStudio Aug 1, 2025
b48fbb3
config: add problems configuration file
ElhamDevelopmentStudio Aug 2, 2025
9ee82aa
refactor: redesign leaderboard client with OpenSolve design
ElhamDevelopmentStudio Aug 2, 2025
4a9c8b4
config: add leaderboards configuration file
ElhamDevelopmentStudio Aug 2, 2025
bfd0255
refactor: redesign trails board component
ElhamDevelopmentStudio Aug 2, 2025
a1481ac
refactor: update admin and staff problem components
ElhamDevelopmentStudio Aug 2, 2025
a54e44c
refactor: update icon system to use hugeicons-react
ElhamDevelopmentStudio Aug 2, 2025
0346571
docs: update redesign checklist
ElhamDevelopmentStudio Aug 2, 2025
8d0cf14
refactor: redesign auth pages with OpenSolve design system
ElhamDevelopmentStudio Aug 2, 2025
22b8049
refactor: redesign discussion pages with OpenSolve design system
ElhamDevelopmentStudio Aug 3, 2025
74e411e
refactor: update problem detail pages with new design system
ElhamDevelopmentStudio Aug 3, 2025
1f3ea87
refactor: update problem trails and not-found pages
ElhamDevelopmentStudio Aug 3, 2025
a2777c0
refactor: update leaderboard pages with brutalist design
ElhamDevelopmentStudio Aug 3, 2025
f29757c
refactor: update tags page and reader layout
ElhamDevelopmentStudio Aug 3, 2025
a6fd686
refactor: update platform pages with new design system
ElhamDevelopmentStudio Aug 3, 2025
d0433d3
chore: complete UI redesign migration to OpenSolve design system
ElhamDevelopmentStudio Aug 3, 2025
e7b17c2
refactor: landing page for a better ui
ElhamDevelopmentStudio Nov 20, 2025
2ffbeea
feat: added new design system
ElhamDevelopmentStudio Nov 20, 2025
f82fddd
Merge branch 'main' of github.com-elham:ElhamDevelopmentStudio/open-s…
ElhamDevelopmentStudio Nov 20, 2025
ed179a7
fix: linters and conflicts
ElhamDevelopmentStudio Nov 20, 2025
a7dc428
feat: redesigned auth pages
ElhamDevelopmentStudio Nov 20, 2025
5809375
config: update auth configuration structure
ElhamDevelopmentStudio Aug 13, 2024
b62ea90
config: add configuration files for various features
ElhamDevelopmentStudio Aug 13, 2025
069c310
docs: update documentation
ElhamDevelopmentStudio Aug 13, 2025
994600c
feat: update icons component
ElhamDevelopmentStudio Aug 14, 2025
0b39955
feat: enhance problem components
ElhamDevelopmentStudio Aug 14, 2025
2707d9d
feat: improve problem workspace
ElhamDevelopmentStudio Aug 15, 2025
4fe0bf7
feat: improve contest overview and detail
ElhamDevelopmentStudio Aug 16, 2025
7cd7635
feat: enhance contest scoreboard and clarifications
ElhamDevelopmentStudio Aug 17, 2025
857ad81
feat: improve submissions components
ElhamDevelopmentStudio Aug 17, 2025
06773a0
feat: enhance profile component
ElhamDevelopmentStudio Aug 18, 2025
c1f84b4
feat: improve proposal components
ElhamDevelopmentStudio Aug 19, 2025
0ce70d3
feat: update staff problem editor
ElhamDevelopmentStudio Aug 20, 2025
a59512d
feat: enhance dashboard with submission charts
ElhamDevelopmentStudio Aug 20, 2025
9b00bf7
feat: improve reader layout
ElhamDevelopmentStudio Aug 21, 2025
d84786e
feat: update difficulty page
ElhamDevelopmentStudio Aug 22, 2025
25c2087
feat: enhance workspace problem pages
ElhamDevelopmentStudio Aug 23, 2025
4adab2e
feat: update problem submissions page
ElhamDevelopmentStudio Aug 23, 2025
920805a
feat: improve teams page
ElhamDevelopmentStudio Aug 24, 2025
4569837
feat: update share page
ElhamDevelopmentStudio Aug 25, 2025
46c9a19
feat: improve user profile page
ElhamDevelopmentStudio Aug 26, 2025
53c1ad9
feat: update problem not-found page
ElhamDevelopmentStudio Aug 27, 2025
ff8112a
config: add admin, settings, staff, and workspace-hub configs
ElhamDevelopmentStudio Aug 13, 2025
19a42f7
feat: refine auth utilities
ElhamDevelopmentStudio Aug 13, 2025
98a55b7
feat: improve email service
ElhamDevelopmentStudio Aug 14, 2025
f66e181
feat: update auth components and pages
ElhamDevelopmentStudio Aug 14, 2025
b41526d
feat: enhance settings pages
ElhamDevelopmentStudio Aug 15, 2025
6c5c114
feat: improve workspace pages
ElhamDevelopmentStudio Aug 16, 2025
b09cfa7
feat: enhance admin dashboard
ElhamDevelopmentStudio Aug 17, 2025
4d7e959
feat: improve admin analytics
ElhamDevelopmentStudio Aug 18, 2025
5906045
feat: enhance admin audit
ElhamDevelopmentStudio Aug 18, 2025
20b9213
feat: improve admin contests
ElhamDevelopmentStudio Aug 19, 2025
928b2d3
feat: enhance admin discussions
ElhamDevelopmentStudio Aug 19, 2025
456e715
feat: improve admin submissions
ElhamDevelopmentStudio Aug 20, 2025
103d2d6
feat: enhance admin system
ElhamDevelopmentStudio Aug 21, 2025
d61653a
feat: improve admin problems and users
ElhamDevelopmentStudio Aug 21, 2025
39e9b88
feat: enhance staff problems
ElhamDevelopmentStudio Aug 22, 2025
f9e555a
feat: improve staff proposals
ElhamDevelopmentStudio Aug 22, 2025
3fea924
feat: update problem library
ElhamDevelopmentStudio Aug 23, 2025
bb85043
feat: enhance submission detail
ElhamDevelopmentStudio Aug 24, 2025
9be1ad5
feat: add confirm dialog component
ElhamDevelopmentStudio Aug 25, 2025
30332ab
docs: update documentation
ElhamDevelopmentStudio Aug 28, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"prisma.pinToPrisma6": true
}
771 changes: 472 additions & 299 deletions AGENTS.md

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions AUTH_QUICKSTART.md
Original file line number Diff line number Diff line change
Expand Up @@ -236,3 +236,4 @@ Session is auto-loaded in tRPC context. Use appropriate procedure type:
- [ ] Review audit logs regularly
- [ ] Test 2FA enrollment & recovery flows
- [ ] Test email deliverability across providers

142 changes: 95 additions & 47 deletions app/(auth)/auth/forgot-password/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,27 +2,27 @@

import { useForm } from "react-hook-form";
import { zodResolver } from "@hookform/resolvers/zod";
import Link from "next/link";
import { toast } from "sonner";

import { trpc } from "@/lib/trpc/client";
import { requestPasswordResetSchema, type RequestPasswordResetInput } from "@/lib/validators/auth";
import { Button } from "@/components/ui/button";
import {
Form,
FormControl,
FormField,
FormItem,
FormLabel,
FormMessage,
Button,
Input,
Card,
CardContent,
CardDescription,
CardHeader,
CardTitle,
} from "@/components/ui";
import { toast } from "sonner";
import Link from "next/link";
} from "@/components/ui/form";
import { Input } from "@/components/ui/input";
import { ArrowRight, CheckCircle2, Mail } from "@/components/icons";
import { authConfig } from "@/config/auth";

export default function ForgotPasswordPage() {
const { forgotPassword } = authConfig;

const form = useForm<RequestPasswordResetInput>({
resolver: zodResolver(requestPasswordResetSchema),
defaultValues: {
Expand All @@ -45,47 +45,95 @@ export default function ForgotPasswordPage() {
};

return (
<Card className="w-full max-w-md">
<CardHeader>
<CardTitle>Reset Password</CardTitle>
<CardDescription>
Enter your email address and we&apos;ll send you a link to reset your password.
</CardDescription>
</CardHeader>
<CardContent className="space-y-4">
<Form {...form}>
<form onSubmit={form.handleSubmit(handleSubmit)} className="space-y-4">
<FormField
control={form.control}
name="email"
render={({ field }) => (
<FormItem>
<FormLabel>Email</FormLabel>
<FormControl>
<Input
type="email"
placeholder="you@example.com"
autoComplete="email"
{...field}
/>
</FormControl>
<FormMessage />
</FormItem>
)}
/>
<section className="border-2 border-border bg-background p-6 shadow-primary/20">
<div className="mb-6 flex items-center justify-between font-mono text-xs font-bold uppercase tracking-[0.08em]">
<span className="flex items-center gap-2 text-primary">
<Mail className="h-3.5 w-3.5" />
{forgotPassword.badge}
</span>
<span className="text-muted-foreground">[03] Password reset</span>
</div>

<div className="mb-6 space-y-3">
<h1 className="bg-linear-to-br from-foreground via-foreground to-foreground/70 bg-clip-text font-mono text-2xl font-black leading-tight text-transparent">
{forgotPassword.headline}
</h1>
<p className="font-mono text-sm leading-relaxed text-muted-foreground">
{forgotPassword.description}
</p>
</div>

<Button type="submit" className="w-full" disabled={resetMutation.isPending}>
{resetMutation.isPending ? "Sending..." : "Send Reset Link"}
</Button>
</form>
</Form>
<div className="mb-6 border-2 border-border bg-background/50 p-4">
<div className="mb-3 font-mono text-xs font-bold uppercase text-primary/80">
Security notes
</div>
<div className="space-y-2">
{forgotPassword.security.map((note) => (
<div key={note} className="flex items-start gap-2">
<CheckCircle2 className="mt-0.5 h-3.5 w-3.5 text-primary" />
<span className="font-mono text-xs text-muted-foreground">{note}</span>
</div>
))}
</div>
</div>

<Form {...form}>
<form onSubmit={form.handleSubmit(handleSubmit)} className="space-y-4">
<FormField
control={form.control}
name="email"
render={({ field }) => (
<FormItem>
<FormLabel className="font-mono text-sm font-bold uppercase">
Email address
</FormLabel>
<FormControl>
<Input
type="email"
placeholder="you@example.com"
autoComplete="email"
className="h-11 rounded-none border-2 border-border bg-background font-mono text-sm transition-colors focus:border-primary"
{...field}
/>
</FormControl>
<FormMessage className="font-mono text-xs" />
</FormItem>
)}
/>

<Button
type="submit"
disabled={resetMutation.isPending}
className="h-11 w-full rounded-none border-2 border-primary bg-primary font-mono text-sm font-bold uppercase tracking-wide text-primary-foreground shadow-sm shadow-primary/20 transition-all hover:shadow-md hover:shadow-primary/30"
>
{resetMutation.isPending ? "Sending reset link..." : "Send reset link"}
</Button>
</form>
</Form>

<div className="text-center text-sm">
<Link href="/sign-in" className="text-primary hover:underline">
<div className="mt-6 space-y-3 border-t border-border pt-6 font-mono text-xs text-muted-foreground">
<div className="flex items-center justify-between">
<span>Remember your password?</span>
<Link
href="/sign-in"
className="inline-flex items-center gap-1 text-foreground underline-offset-4 hover:underline"
>
Back to sign in
<ArrowRight className="h-3.5 w-3.5" />
</Link>
</div>
</CardContent>
</Card>
<div className="flex items-center justify-between">
<span>Need an account?</span>
<Link
href="/sign-up"
className="inline-flex items-center gap-1 text-primary underline-offset-4 hover:underline"
>
Create account
<ArrowRight className="h-3.5 w-3.5" />
</Link>
</div>
</div>
</section>
);
}

Loading
Loading