Shadcn-ified the landing page

This commit is contained in:
2026-02-02 23:29:10 +01:00
parent 9b7f65155d
commit 383097b9e4
2 changed files with 16 additions and 14 deletions
+2 -4
View File
@@ -4,7 +4,7 @@ import { Timer, Zap, Trophy, Users, ArrowRight, Play } from "lucide-react";
import { Button } from "@/components/ui/button"; import { Button } from "@/components/ui/button";
import Link from "next/link"; import Link from "next/link";
const Landing = () => { export default function Landing() {
const features = [ const features = [
{ {
icon: Timer, icon: Timer,
@@ -183,6 +183,4 @@ const Landing = () => {
</section> </section>
</div> </div>
); );
}; }
export default Landing;
+13 -9
View File
@@ -17,14 +17,11 @@ const buttonVariants = cva(
"border-2 border-primary/50 bg-transparent text-primary hover:bg-primary/10 hover:border-primary", "border-2 border-primary/50 bg-transparent text-primary hover:bg-primary/10 hover:border-primary",
secondary: secondary:
"bg-secondary text-secondary-foreground hover:bg-secondary/80", "bg-secondary text-secondary-foreground hover:bg-secondary/80",
ghost: ghost: "text-muted-foreground hover:text-foreground hover:bg-secondary",
"text-muted-foreground hover:text-foreground hover:bg-secondary", link: "text-primary underline-offset-4 hover:underline",
link: hero: "bg-primary text-primary-foreground px-8 py-6 text-lg font-bold glow-purple hover:glow-purple-intense",
"text-primary underline-offset-4 hover:underline",
hero:
"bg-primary text-primary-foreground px-8 py-6 text-lg font-bold glow-purple hover:glow-purple-intense hover:scale-105",
"hero-outline": "hero-outline":
"border-2 border-primary/50 bg-transparent text-primary px-8 py-6 text-lg font-bold hover:bg-primary/10 hover:border-primary hover:scale-105", "border-2 border-primary/50 bg-transparent text-primary px-8 py-6 text-lg font-bold hover:bg-primary/10 hover:border-primary hover:ring-2 hover:ring-primary/30",
}, },
size: { size: {
default: "h-10 px-4 py-2", default: "h-10 px-4 py-2",
@@ -42,7 +39,8 @@ const buttonVariants = cva(
); );
export interface ButtonProps export interface ButtonProps
extends React.ButtonHTMLAttributes<HTMLButtonElement>, extends
React.ButtonHTMLAttributes<HTMLButtonElement>,
VariantProps<typeof buttonVariants> { VariantProps<typeof buttonVariants> {
asChild?: boolean; asChild?: boolean;
} }
@@ -50,7 +48,13 @@ export interface ButtonProps
const Button = React.forwardRef<HTMLButtonElement, ButtonProps>( const Button = React.forwardRef<HTMLButtonElement, ButtonProps>(
({ className, variant, size, asChild = false, ...props }, ref) => { ({ className, variant, size, asChild = false, ...props }, ref) => {
const Comp = asChild ? Slot : "button"; const Comp = asChild ? Slot : "button";
return <Comp className={cn(buttonVariants({ variant, size, className }))} ref={ref} {...props} />; return (
<Comp
className={cn(buttonVariants({ variant, size, className }))}
ref={ref}
{...props}
/>
);
}, },
); );
Button.displayName = "Button"; Button.displayName = "Button";