Connect, collaborate, and grow with a community of TypeScript developers
shiny smooth animations on the landing cards (#263)
Ernesto Resendec7ef6602ddf8
diff --git a/package.json b/package.jsonindex a7280011..30ffcac9 100644--- a/package.json+++ b/package.json@@ -46,6 +46,8 @@"clsx": "^2.0.0","cmdk": "^0.2.0","date-fns": "^2.30.0",+ "framer-motion": "^10.12.22",+ "framer-motion-3d": "^10.12.22","lodash": "^4.17.21","lucide-react": "^0.260.0","monaco-editor": "^0.40.0",diff --git a/pnpm-lock.yaml b/pnpm-lock.yamlindex f22e6883..8dadf0aa 100644--- a/pnpm-lock.yaml+++ b/pnpm-lock.yaml@@ -97,6 +97,12 @@ dependencies:date-fns:specifier: ^2.30.0version: 2.30.0+ framer-motion:+ specifier: ^10.12.22+ version: 10.12.22([email protected])([email protected])+ framer-motion-3d:+ specifier: ^10.12.22+ version: 10.12.22(@react-three/[email protected])([email protected])([email protected])([email protected])lodash:specifier: ^4.17.21version: 4.17.21@@ -267,6 +273,19 @@ packages:dependencies:regenerator-runtime: 0.13.11+ /@emotion/[email protected]:+ resolution: {integrity: sha512-u5WtneEAr5IDG2Wv65yhunPSMLIpuKsbuOktRojfrEiEvRyC85LgPMZI63cr7NUqT8ZIGdSVg8ZKGxIug4lXcA==}+ requiresBuild: true+ dependencies:+ '@emotion/memoize': 0.7.4+ dev: false+ optional: true++ /@emotion/[email protected]:+ resolution: {integrity: sha512-Ja/Vfqe3HpuzRsG1oBtWTHk2PGZ7GR+2Vz5iYGelAw8dx32K0y7PjVuxK6z1nMpZOqAFsRUPCkK1YjJ56qJlgw==}+ dev: false+ optional: true+/@esbuild-kit/[email protected]:resolution: {integrity: sha512-BDXFbYOJzT/NBEtp71cvsrGPwGAMGRB/349rwKuoxNSiKjPraNNnlK6MIIabViCjqZugu6j+xeMDlEkWdHHJSg==}dependencies:@@ -1868,6 +1887,41 @@ packages:'@babel/runtime': 7.22.6dev: false+ resolution: {integrity: sha512-x9QdsaB/Wm/6NGvRXQahPPWfn2dQce7Fg3C2r00NNzyDdqRKw32YavL+WEqjZOOd0nvFpzv7FtaKc+VCOTR59w==}+ peerDependencies:+ expo: '>=43.0'+ expo-asset: '>=8.4'+ expo-gl: '>=11.0'+ react: '>=18.0'+ react-dom: '>=18.0'+ react-native: '>=0.64'+ three: '>=0.133'+ peerDependenciesMeta:+ expo:+ optional: true+ expo-asset:+ optional: true+ expo-gl:+ optional: true+ react-dom:+ optional: true+ react-native:+ optional: true+ dependencies:+ '@babel/runtime': 7.22.6+ '@types/react-reconciler': 0.26.7+ its-fine: 1.1.1([email protected])+ react: 18.2.0+ react-dom: 18.2.0([email protected])+ react-reconciler: 0.27.0([email protected])+ react-use-measure: 2.1.1([email protected])([email protected])+ scheduler: 0.21.0+ suspend-react: 0.1.3([email protected])+ three: 0.154.0+ zustand: 3.7.2([email protected])+ dev: false+/@rushstack/[email protected]:resolution: {integrity: sha512-V+MvGwaHH03hYhY+k6Ef/xKd6RYlc4q8WBx+2ANmipHJcKuktNcI/NgEsJgdSUF6Lw32njT6OnrRsKYCdgHjYw==}dev: true@@ -2017,6 +2071,18 @@ packages:dependencies:'@types/react': 18.2.15+ /@types/[email protected]:+ resolution: {integrity: sha512-mBDYl8x+oyPX/VBb3E638N0B7xG+SPk/EAMcVPeexqus/5aTpTphQi0curhhshOqRrc9t6OPoJfEUkbymse/lQ==}+ dependencies:+ '@types/react': 18.2.15+ dev: false++ /@types/[email protected]:+ resolution: {integrity: sha512-8tu6lHzEgYPlfDf/J6GOQdIc+gs+S2yAqlby3zTsB3SP2svlqTYe5fwZNtZyfactP74ShooP2vvi1BOp9ZemWw==}+ dependencies:+ '@types/react': 18.2.15+ dev: false+/@types/[email protected]:resolution: {integrity: sha512-bo5fEO5toQeyCp0zVHBeggclqf5SQ/Z5blfFmjwO5dkMVGPgmiwZsJh9nu/Bo5L7IHTuGWrja6LxJVE2uB5ZrQ==}dependencies:@@ -2920,6 +2986,10 @@ packages:'@babel/runtime': 7.22.6dev: false+ resolution: {integrity: sha512-XRRe6Glud4rd/ZGQfiV1ruXSfbvfJedlV9Y6zOlP+2K04vBYiJEte6stfFkCP03aMnY5tsipamumUjL14fofug==}+ dev: false+resolution: {integrity: sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==}peerDependencies:@@ -3642,6 +3712,40 @@ packages:resolution: {integrity: sha512-MhLuK+2gUcnZe8ZHlaaINnQLl0xRIGRfcGk2yl8xoQAfHrSsL3rYu6FCmBdkdbhc9EPlwyGHewaRsvwRMJtAlA==}dev: true+ /[email protected](@react-three/[email protected])([email protected])([email protected])([email protected]):+ resolution: {integrity: sha512-ZnOBotP1m9SdSxz6C3SIEHcNmtXBJKxbhceakte7TT1LCjC7HWZUZzL74Dxa2/qpB/3qbyxTarnT9ORcx/MyLA==}+ peerDependencies:+ '@react-three/fiber': ^8.2.2+ react: '>=18.0'+ react-dom: '>=18.0'+ three: '>=0.133'+ dependencies:+ framer-motion: 10.12.22([email protected])([email protected])+ react: 18.2.0+ react-dom: 18.2.0([email protected])+ react-merge-refs: 2.0.2+ three: 0.154.0+ dev: false++ resolution: {integrity: sha512-bBGYPOxvxcfzS7/py9MEqDucmXBkVl2g42HNlXXPieSTSGGkr8L7+MilCnrU6uX3HrNk/tcB++1SkWE8BosHFw==}+ peerDependencies:+ react: ^18.0.0+ react-dom: ^18.0.0+ peerDependenciesMeta:+ react:+ optional: true+ react-dom:+ optional: true+ dependencies:+ react: 18.2.0+ react-dom: 18.2.0([email protected])+ tslib: 2.6.0+ optionalDependencies:+ '@emotion/is-prop-valid': 0.8.8+ dev: false+resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==}@@ -4281,6 +4385,15 @@ packages:resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==}dev: true+ resolution: {integrity: sha512-v1Ia1xl20KbuSGlwoaGsW0oxsw8Be+TrXweidxD9oT/1lAh6O3K3/GIM95Tt6WCiv6W+h2M7RB1TwdoAjQyyKw==}+ peerDependencies:+ react: '>=18.0'+ dependencies:+ '@types/react-reconciler': 0.28.2+ react: 18.2.0+ dev: false+resolution: {integrity: sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg==}engines: {node: '>= 10.13.0'}@@ -5622,6 +5735,21 @@ packages:- supports-colordev: false+ resolution: {integrity: sha512-V5BGTwGa2r+/t0A/BZMS6L7VPXY0CU8xtAhkT3XUoI1WJJhhtvulvoiZkJ5Jt9YAW23m4xFWmhQ+C5HwjtTFhQ==}+ dev: false++ resolution: {integrity: sha512-HmMDKciQjYmBRGuuhIaKA1ba/7a+UsM5FzOZsMO2JYHt9Jh8reCb7j1eDC95NOyUlKM9KRyvdx0flBuDvYSBoA==}+ engines: {node: '>=0.10.0'}+ peerDependencies:+ react: ^18.0.0+ dependencies:+ loose-envify: 1.4.0+ react: 18.2.0+ scheduler: 0.21.0+ dev: false+resolution: {integrity: sha512-63C4YQBUt0m6ALadE9XV56hV8BgJWDmmTPY758iIJjfQKt2nYwoUrPk0LXRXcB/yIj82T1/Ixfdpdk68LwIB0A==}engines: {node: '>=10'}@@ -5706,6 +5834,17 @@ packages:refractor: 3.6.0dev: false+ resolution: {integrity: sha512-nocZhN26cproIiIduswYpV5y5lQpSQS1y/4KuvUCjSKmw7ZWIS/+g3aFnX3WdBkyuGUtTLif3UTqnLLhbDoQig==}+ peerDependencies:+ react: '>=16.13'+ react-dom: '>=16.13'+ dependencies:+ debounce: 1.2.1+ react: 18.2.0+ react-dom: 18.2.0([email protected])+ dev: false+resolution: {integrity: sha512-/3IjMdb2L9QbBdWiW5e3P2/npwMBaU9mHCSCUzNln0ZCYbcfTsGbTJrU/kGemdH2IWmB2ioZ+zkxtmq6g09fGQ==}engines: {node: '>=0.10.0'}@@ -5974,6 +6113,12 @@ packages:is-regex: 1.1.4dev: true+ resolution: {integrity: sha512-1r87x5fz9MXqswA2ERLo0EbOAU74DpIUO090gIasYTqlVoJeMcl+Z1Rg7WHz+qtPujhS/hGIt9kxZOYBV3faRQ==}+ dependencies:+ loose-envify: 1.4.0+ dev: false+resolution: {integrity: sha512-CtuThmgHNg7zIZWAXi3AsyIzA3n4xx7aNyjwC2VJldO2LMVDhFK+63xGqq6CsJH4rTAt6/M+N4GhZiDYPx9eUw==}dependencies:@@ -6274,6 +6419,14 @@ packages:resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==}engines: {node: '>= 0.4'}+ resolution: {integrity: sha512-aqldKgX9aZqpoDp3e8/BZ8Dm7x1pJl+qI3ZKxDN0i/IQTWUwBx/ManmlVJ3wowqbno6c2bmiIfs+Um6LbsjJyQ==}+ peerDependencies:+ react: '>=17.0'+ dependencies:+ react: 18.2.0+ dev: false+resolution: {integrity: sha512-L1dapNV6vu2s/4Sputv8xGsCdAVlb5nRDMFU/E27D44l5U6cw1g0dGd45uLc+OXjNMmF4ntiMdCimzcjFKQI8Q==}engines: {node: ^14.18.0 || >=16.0.0}@@ -6379,6 +6532,10 @@ packages:dependencies:any-promise: 1.3.0+ resolution: {integrity: sha512-Uzz8C/5GesJzv8i+Y2prEMYUwodwZySPcNhuJUdsVMH2Yn4Nm8qlbQe6qRN5fOhg55XB0WiLfTPBxVHxpE60ug==}+ dev: false+resolution: {integrity: sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==}dev: true@@ -6836,6 +6993,18 @@ packages:resolution: {integrity: sha512-m46AKbrzKVzOzs/DZgVnG5H55N1sv1M8qZU3A8RIKbs3mrACDNeIOeilDymVb2HdmP8uwshOCF4uJ8uM9rCqJw==}dev: false+ resolution: {integrity: sha512-PIJDIZKtokhof+9+60cpockVOq05sJzHCriyvaLBmEJixseQ1a5Kdov6fWZfWOu5SK9c+FhH1jU0tntLxRJYMA==}+ engines: {node: '>=12.7.0'}+ peerDependencies:+ react: '>=16.8'+ peerDependenciesMeta:+ react:+ optional: true+ dependencies:+ react: 18.2.0+ dev: false+resolution: {integrity: sha512-Tat5r8jOMG1Vcsj8uldMyqYKC5IZvQif8zetmLHs9WoZlntTHmIoNM8TpLRY31ExncuUvUOXehd0kvahkuHjDw==}engines: {node: '>=12.7.0'}diff --git a/src/components/landing/fake-challenge-card.tsx b/src/components/landing/fake-challenge-card.tsxindex de77c991..bfae8827 100644--- a/src/components/landing/fake-challenge-card.tsx+++ b/src/components/landing/fake-challenge-card.tsx@@ -1,42 +1,75 @@import { clsx } from 'clsx';+import { motion, stagger, type AnimationProps, type SVGMotionProps } from 'framer-motion';++function getRandomWidth() {+ const min = 100;+ const range = 240 - min;+ let rand = Math.random();+ rand = Math.floor(Math.random() * range);+ rand = rand + min;++ return rand;+}export type FakeChallengeCardProps = {title: string;className?: string;difficulty?: 'EASY' | 'MEDIUM' | 'HARD';+ animation?: AnimationProps;};const COLORS_BY_DIFFICULTY = {BEGINNER: 'dark:bg-pink-300 bg-pink-600',EASY: 'dark:bg-green-300 bg-green-600',- MEDIUM:- 'dark:bg-yellow-300 bg-yellow-600',+ MEDIUM: 'dark:bg-yellow-300 bg-yellow-600',HARD: 'dark:bg-red-300 bg-red-600',- EXTREME:- 'dark:bg-orange-300 bg-orange-600',+ EXTREME: 'dark:bg-orange-300 bg-orange-600',};-export const FakeChallengeCard = ({ title, className, difficulty }: FakeChallengeCardProps) => {+const codeLineProps = {+ width: 0,+ rx: '4.5',+ height: 10,+ initial: { width: 0 },+ transition: { duration: 0.5, delay: 0.15 },+} as SVGMotionProps<SVGRectElement>;++export const FakeChallengeCard = ({+ title,+ className,+ difficulty,+ animation,+}: FakeChallengeCardProps) => {return (- <div+ <motion.div+ {...animation}+ whileHover={{+ scale: 1.06,+ skew: -2,+ transition: { delay: 0, duration: 0.2, type: 'keyframes' },+ }}className={clsx(className, {- 'flex w-[320px] flex-col gap-3 rounded-2xl border duration-300 border-neutral-300 bg-zinc-100 group/card hover:-skew-x-6 dark:hover:border-zinc-600 p-7 drop-shadow-[0_0_15px_rgba(49,49,49,0.2)] dark:border-zinc-800 dark:bg-zinc-900 dark:drop-shadow-[0_0_15px_rgba(49,49,49,0.35)] hover:shadow-[2rem_2rem_2rem_-1rem_#0004,inset_1rem_1rem_4rem_-1rem_#fff1]':+ 'card-container group/card flex w-[320px] select-none flex-col gap-3 rounded-2xl border border-neutral-300 bg-zinc-100 p-7 drop-shadow-[0_0_15px_rgba(49,49,49,0.2)] transition-shadow duration-500 hover:shadow-[2rem_2rem_2rem_-1rem_#0004,inset_1rem_1rem_4rem_-1rem_#fff1] dark:border-zinc-800 dark:bg-zinc-900 dark:drop-shadow-[0_0_15px_rgba(49,49,49,0.35)]':true,})}><p className="translate-x-1 text-lg font-medium">{title}</p><div className="flex gap-3">- <div className={`duration-300 group-hover/card:-translate-x-1 group-hover/card:-translate-y-1 group-hover/card:shadow-[0.75rem_0.75rem_1rem_-0.25rem_#0008] inline-flex w-fit translate-x-1 items-center rounded-full border border-transparent px-2.5 py-0.5 text-xs font-semibold text-primary-foreground ${COLORS_BY_DIFFICULTY[difficulty || 'HARD']}`}>- { difficulty || 'HARD' }+ <div+ className={`inline-flex w-fit translate-x-1 items-center rounded-full border border-transparent px-2.5 py-0.5 text-xs font-semibold text-primary-foreground ${+ COLORS_BY_DIFFICULTY[difficulty || 'HARD']+ }`}+ >+ {difficulty || 'HARD'}</div>- <div className="duration-300 group-hover/card:-translate-x-2 group-hover/card:-translate-y-1 group-hover/card:shadow-[0.75rem_0.75rem_1rem_-0.25rem_#0008] px-2.5 flex w-fit items-center justify-center rounded-full bg-transparent py-1 pl-1.5 pr-2 text-xs font-bold text-neutral-700 dark:bg-zinc-700 bg-neutral-300 dark:text-white">+ <div className="flex w-fit items-center justify-center rounded-full bg-neutral-300 bg-transparent px-2.5 py-1 pl-1.5 pr-2 text-xs font-bold text-neutral-700 duration-300 dark:bg-zinc-700 dark:text-white">@you</div></div><div className="translate-x-1 text-xs">Implement the built-in <code>Pick</code> type.</div>- <div className="h-56 mt-4 flex-grow rounded-xl group-hover/card:-translate-x-3 group-hover/card:-translate-y-3 group-hover/card:shadow-[1rem_1rem_2.5rem_-1rem_#0008] duration-300 bg-zinc-300/70 p-4 dark:bg-zinc-800/70">+ <div className="mt-4 h-56 flex-grow rounded-xl bg-zinc-300/70 p-4 dark:bg-zinc-800/70"><svgwidth="256"height="193"@@ -44,18 +77,69 @@ export const FakeChallengeCard = ({ title, className, difficulty }: FakeChallengfill="none"xmlns="http://www.w3.org/2000/svg">- <rect width="234" height="9" rx="4.5" fill="#2B2B32" />- <rect y="109" width="234" height="9" rx="4.5" fill="#2B2B32" />- <rect y="90" width="234" height="9" rx="4.5" fill="#2B2B32" />- <rect y="19" width="123" height="9" rx="4.5" fill="#544048" />- <rect y="38" width="142" height="9" rx="4.5" fill="#544048" />- <rect y="128" width="130" height="9" rx="4.5" fill="#544048" />- <rect y="147" width="189" height="9" rx="4.5" fill="#544048" />- <rect y="57" width="142" height="9" rx="4.5" fill="#404F54" />- <rect y="166" width="142" height="9" rx="4.5" fill="#404F54" />- <rect y="184" width="142" height="9" rx="4.5" fill="#404F54" />+ <motion.rect+ {...codeLineProps}+ animate={{ width: getRandomWidth() }}+ y="0"+ fill="#2B2B32"+ />+ <motion.rect+ {...codeLineProps}+ animate={{ width: getRandomWidth() }}+ y="19"+ fill="#544048"+ />+ <motion.rect+ {...codeLineProps}+ animate={{ width: getRandomWidth() }}+ y="38"+ fill="#544048"+ />+ <motion.rect+ {...codeLineProps}+ animate={{ width: getRandomWidth() }}+ y="57"+ fill="#404F54"+ />+ <motion.rect+ {...codeLineProps}+ animate={{ width: getRandomWidth() }}+ y="90"+ fill="#2B2B32"+ />+ <motion.rect+ {...codeLineProps}+ animate={{ width: getRandomWidth() }}+ y="109"+ fill="#2B2B32"+ />+ <motion.rect+ {...codeLineProps}+ animate={{ width: getRandomWidth() }}+ transition={{ delay: 0.3, duration: 0.5 }}+ y="128"+ fill="#544048"+ />+ <motion.rect+ {...codeLineProps}+ animate={{ width: getRandomWidth() }}+ y="147"+ fill="#544048"+ />+ <motion.rect+ {...codeLineProps}+ animate={{ width: getRandomWidth() }}+ y="166"+ fill="#404F54"+ />+ <motion.rect+ {...codeLineProps}+ animate={{ width: getRandomWidth() }}+ y="184"+ fill="#404F54"+ /></svg></div>- </div>+ </motion.div>);};diff --git a/src/components/landing/hero.tsx b/src/components/landing/hero.tsxindex 330f47a4..90f198f6 100644--- a/src/components/landing/hero.tsx+++ b/src/components/landing/hero.tsx@@ -1,15 +1,17 @@-import { Github } from "lucide-react"+'use client'++import { Github } from 'lucide-react';+import { motion } from 'framer-motion';import { Button } from '~/components/ui/button';import { FakeChallengeCard } from '~/components/landing/fake-challenge-card';import Link from 'next/link';-const TypeHeroLogo = () => {return (<svgfill="none"viewBox="0 0 164 164"- className="h-28 sm:h-44 w-28 sm:w-44 rounded-3xl sm:rounded-[2rem]"+ className="h-28 w-28 rounded-3xl sm:h-44 sm:w-44 sm:rounded-[2rem]"xmlns="http://www.w3.org/2000/svg"><path@@ -30,62 +32,99 @@ const TypeHeroLogo = () => {);};-const Hero = () => (-<section className="lg:overflow-x-hidden">- {/* <svg className="pointer-events-none mix-blend-soft-light opacity-50 z-10 absolute left-0 top-0 h-full w-full" id="grain">+const Hero = () => {+ return (+ <section className="lg:overflow-x-hidden">+ {/* <svg className="pointer-events-none mix-blend-soft-light opacity-50 z-10 absolute left-0 top-0 h-full w-full" id="grain"><filter id="noise"><feTurbulence type="fractalNoise" baseFrequency="1" numOctaves="5" stitchTiles="stitch"></feTurbulence></filter><rect width="100%" height="100%" filter="url(#noise)"></rect></svg> */}- <div className="mb-[56px] container md:px-24 items-center justify-center grid lg:grid-cols-2 min-h-[calc(100lvh_-_112px)]">- <div className="flex w-full flex-col justify-center items-center lg:items-start gap-10">- <div className="relative flex w-full items-center justify-center lg:justify-start gap-4">- <div className="absolute left-1/2 top-1/2 -z-10 hidden h-56 w-56 -translate-x-[15%] -translate-y-[50%] rounded-full bg-slate-400/10 blur-3xl dark:block"></div>- <div className="absolute right-1/2 top-1/2 -z-10 hidden h-56 w-56 -translate-y-[40%] rounded-full bg-[#3178c6]/20 blur-3xl dark:block"></div>- <TypeHeroLogo />- <h1 className="bg-gradient-to-r from-[#3178c6] to-black bg-clip-text text-6xl sm:text-8xl font-extrabold sm:leading-[5.5rem] text-transparent dark:to-white">- type- <br />- hero- </h1>+ <div className="container mb-[56px] grid min-h-[calc(100lvh_-_112px)] items-center justify-center md:px-24 lg:grid-cols-2">+ <div className="flex w-full flex-col items-center justify-center gap-10 lg:items-start">+ <div className="relative flex w-full items-center justify-center gap-4 lg:justify-start">+ <div className="absolute left-1/2 top-1/2 -z-10 hidden h-56 w-56 -translate-x-[15%] -translate-y-[50%] rounded-full bg-slate-400/10 blur-3xl dark:block"></div>+ <div className="absolute right-1/2 top-1/2 -z-10 hidden h-56 w-56 -translate-y-[40%] rounded-full bg-[#3178c6]/20 blur-3xl dark:block"></div>+ <TypeHeroLogo />+ <h1 className="bg-gradient-to-r from-[#3178c6] to-black bg-clip-text text-6xl font-extrabold text-transparent dark:to-white sm:text-8xl sm:leading-[5.5rem]">+ type+ <br />+ hero+ </h1>+ </div>++ <p className="max-w-[50ch] bg-transparent px-8 text-center leading-9 text-black/50 dark:text-white/50 lg:px-0 lg:text-left">+ Connect, collaborate, and grow with a community of TypeScript developers. Elevate your+ skills trough interactive coding challenges, discussions, and knowledge sharing+ </p>+ <div className="flex gap-3">+ <Button className="group relative flex items-center gap-2 overflow-hidden rounded-xl px-4 py-2 font-bold duration-500 dark:hover:text-white">+ <div className="absolute h-44 w-44 -translate-x-full rounded-full bg-[#3178C6] duration-500 group-hover:translate-x-0" />+ <Link className="z-10" href="/explore">+ Explore challenges+ </Link>+ </Button>+ <Button+ className="flex items-center gap-2 rounded-xl border-2 px-4 py-2 dark:text-white"+ asChild+ variant="outline"+ >+ <a className="inline-flex gap-1" href="https://github.com/">+ <Github className="h-4 w-4" />+ GitHub+ </a>+ </Button>+ </div></div>-- <p className="max-w-[50ch] bg-transparent leading-9 px-8 lg:px-0 text-center lg:text-left text-black/50 dark:text-white/50">- Connect, collaborate, and grow with a community of TypeScript developers. Elevate your- skills trough interactive coding challenges, discussions, and knowledge sharing- </p>- <div className="flex gap-3">- <Button className="font-bold relative rounded-xl py-2 px-4 flex items-center gap-2 group dark:hover:text-white duration-500 overflow-hidden">- <div className="absolute -translate-x-full h-44 w-44 group-hover:translate-x-0 duration-500 rounded-full bg-[#3178C6]"/>- <Link className="z-10" href="/explore">Explore challenges</Link>- </Button>- <Button- className="border-2 rounded-xl py-2 px-4 flex items-center gap-2 dark:text-white"- asChild- variant="outline"- >- <a className="inline-flex gap-1" href="https://github.com/">- <Github className="h-4 w-4" />- GitHub- </a>- </Button>++ <div className="group relative hidden h-[800px] overflow-visible rounded-full lg:block">+ <motion.div+ initial={{ opacity: 0 }}+ animate={{ opacity: 1 }}+ transition={{ duration: 0.6, delay: 0.3 }}+ className="moving-grid-background absolute -inset-40 top-1/2 -z-30 aspect-square -translate-y-1/2 translate-x-[-30px] rounded-full shadow-[inset_0_0_5rem_3rem] shadow-background" />+ <FakeChallengeCard+ animation={{+ initial: {+ opacity: 0,+ y: 270,+ x: 20,+ },+ animate: {+ y: 260,+ opacity: 1,+ transition: {+ duration: 0.5,+ },+ },+ }}+ className="absolute z-10"+ title="Implement a JSON parser type"+ />+ <FakeChallengeCard+ animation={{+ initial: {+ y: 80,+ x: 140,+ opacity: 0,+ },+ animate: {+ y: 70,+ opacity: 1,+ },+ transition: {+ duration: 0.5,+ delay: 0.3,+ }+ }}+ difficulty="EASY"+ className="absolute"+ title="Implement a generic type"+ /></div></div>-- <div className="relative h-[800px] group rounded-full lg:block overflow-visible hidden">- <div className="moving-grid-background top-1/2 -translate-y-1/2 rounded-full -inset-40 absolute -z-30 aspect-square translate-x-[-30px] shadow-[inset_0_0_5rem_3rem] shadow-background" />- <FakeChallengeCard- className="absolute group-hover:z-10 group-hover:translate-x-[27px] group-hover:translate-y-[256px] xl:group-hover:translate-x-[77px] translate-x-[100px] xl:translate-x-[190px] translate-y-[116px]"- title="Implement a JSON parser type"- />- <FakeChallengeCard- difficulty="EASY"- className="absolute group-hover:translate-x-[100px] group-hover:translate-y-[116px] xl:group-hover:translate-x-[190px] translate-x-[27px] xl:translate-x-[77px] translate-y-[256px]"- title="Implement a generic type"- />- </div>- </div>- </section>-)-export default Hero+ </section>+ );+};+export default Hero;