Skip to content

Commit bbb3de0

Browse files
committed
format
1 parent a194012 commit bbb3de0

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

+5814
-9939
lines changed

.husky/pre-commit

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
pnpm exec lint-staged
1+
npx lint-staged

.lintstagedrc.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
module.exports = {
2+
"*.{js,jsx,ts,tsx,json,css,scss,md}": ["prettier --write"],
3+
};

.prettierignore

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
node_modules
2+
dist
3+
dist-ssr
4+
*.local
5+
.vscode
6+
.idea
7+
.DS_Store
8+
*.suo
9+
*.ntvs*
10+
*.njsproj
11+
*.sln
12+
*.sw?

.prettierrc

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"semi": true,
3+
"singleQuote": false,
4+
"printWidth": 100,
5+
"tabWidth": 2,
6+
"useTabs": false,
7+
"trailingComma": "es5",
8+
"bracketSpacing": true,
9+
"arrowParens": "always",
10+
"endOfLine": "lf"
11+
}

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
## Will Update Soon
2+
23
[<img src="https://api.gitsponsors.com/api/badge/img?id=893877383" height="20">](https://api.gitsponsors.com/api/badge/link?p=avu8PEBqeodNoj/Hp8y9knBOiyzvEoPmzb+4dQrnHuxXrqqE6eIioiDuQ75gFUoAHbXSv9FJg1BIruoDdOmGmqcRCXM/8ZWALMr7QWO9FiSEaJo0iOsb8pXXcqq2jWvlywpIOymJcrIJ2CSX0dwYfQ==)

app/api/questions/route.ts

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,6 @@ export async function GET() {
4141
companies: companies,
4242
});
4343
} catch (error) {
44-
return NextResponse.json(
45-
{ error: "Failed to load questions" },
46-
{ status: 500 }
47-
);
44+
return NextResponse.json({ error: "Failed to load questions" }, { status: 500 });
4845
}
4946
}

app/api/solutions/route.ts

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -9,19 +9,14 @@ export async function GET(request: Request) {
99
const language = searchParams.get("language") || "cpp";
1010

1111
if (!id) {
12-
return NextResponse.json(
13-
{ error: "Question ID is required" },
14-
{ status: 400 }
15-
);
12+
return NextResponse.json({ error: "Question ID is required" }, { status: 400 });
1613
}
1714

1815
if (!process.env.GEMINI_API_KEY) {
1916
throw new Error("GEMINI_API_KEY is not configured");
2017
}
2118

22-
const apiKey =
23-
new Headers(request.headers).get("x-gemini-key") ||
24-
process.env.GEMINI_API_KEY;
19+
const apiKey = new Headers(request.headers).get("x-gemini-key") || process.env.GEMINI_API_KEY;
2520
if (!apiKey) {
2621
throw new Error("GEMINI_API_KEY is not configured");
2722
}
@@ -53,9 +48,7 @@ export async function GET(request: Request) {
5348
return NextResponse.json({ solution });
5449
} catch (error: any) {
5550
console.error("API Error:", error.message || error);
56-
const message =
57-
error.message ||
58-
"An unknown error occurred while generating the solution";
51+
const message = error.message || "An unknown error occurred while generating the solution";
5952
return NextResponse.json({ error: message }, { status: 500 });
6053
}
6154
}

app/layout.tsx

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,7 @@ const font = Poppins({
1414
weight: ["100", "200", "300", "400", "500", "600", "700", "800", "900"],
1515
});
1616

17-
export default function RootLayout({
18-
children,
19-
}: {
20-
children: React.ReactNode;
21-
}) {
17+
export default function RootLayout({ children }: { children: React.ReactNode }) {
2218
return (
2319
<ClerkProvider
2420
appearance={{

app/not-found.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ import Custom404Component from "@/components/Custom404Component";
22

33
export default function NotFound() {
44
return <Custom404Component />;
5-
}
5+
}

app/not-found/page.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,7 @@ export default function NotFound() {
77
return (
88
<div className="flex flex-col items-center justify-center min-h-screen py-2">
99
<h1 className="text-6xl font-bold">404 - Page Not Found</h1>
10-
<p className="mt-4 text-xl">
11-
Sorry, the page you are looking for does not exist.
12-
</p>
10+
<p className="mt-4 text-xl">Sorry, the page you are looking for does not exist.</p>
1311
<Suspense fallback={<div>Loading additional information...</div>}>
1412
<Custom404Component />
1513
</Suspense>

app/page.tsx

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -57,15 +57,13 @@ export default function Home() {
5757
"absolute inset-0 z-0 [mask-image:radial-gradient(50vw_circle_at_center,white,transparent)]"
5858
)}
5959
/>
60-
<AnimatedGradientText>
61-
🐧 | Proudly Open Source{" "}
62-
</AnimatedGradientText>
60+
<AnimatedGradientText>🐧 | Proudly Open Source </AnimatedGradientText>
6361
<motion.div variants={itemVariants}>
6462
<BlurIn
6563
word={
6664
<>
67-
Padhlo <SparkleText className="inline" text="DSA" /> kahin
68-
se, practice hogi yahi se.
65+
Padhlo <SparkleText className="inline" text="DSA" /> kahin se, practice hogi
66+
yahi se.
6967
</>
7068
}
7169
className="font-display text-center text-4xl font-bold w-full lg:w-auto max-w-4xl mx-auto -z-10"
@@ -77,15 +75,12 @@ export default function Home() {
7775
variants={itemVariants}
7876
>
7977
{" "}
80-
Suffer from <NumberTicker value={8000} />+ company-wise LeetCode
81-
questions like a true Codejeet. Kyunki naukri ke liye sab kuch
82-
chalega!
78+
Suffer from <NumberTicker value={8000} />+ company-wise LeetCode questions like a true
79+
Codejeet. Kyunki naukri ke liye sab kuch chalega!
8380
</motion.h2>
8481
<motion.div variants={itemVariants} className="z-20">
8582
<Link href="/dashboard">
86-
<RainbowButton className={cn("shadow-2xl mb-4")}>
87-
Get Started
88-
</RainbowButton>
83+
<RainbowButton className={cn("shadow-2xl mb-4")}>Get Started</RainbowButton>
8984
</Link>
9085
</motion.div>
9186
<motion.div variants={itemVariants}>

components.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,4 @@
1818
"hooks": "@/hooks"
1919
},
2020
"iconLibrary": "lucide"
21-
}
21+
}

components/AnimatedImage.tsx

Lines changed: 3 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -13,25 +13,13 @@ interface AnimatedImageProps {
1313
className?: string;
1414
}
1515

16-
const AnimatedImage: React.FC<AnimatedImageProps> = ({
17-
src,
18-
alt,
19-
width,
20-
height,
21-
className,
22-
}) => {
16+
const AnimatedImage: React.FC<AnimatedImageProps> = ({ src, alt, width, height, className }) => {
2317
const x = useMotionValue(0);
2418
const y = useMotionValue(0);
2519

2620
const springConfig = { stiffness: 300, damping: 30 };
27-
const rotateX = useSpring(
28-
useTransform(y, [-300, 300], [5, -5]),
29-
springConfig
30-
);
31-
const rotateY = useSpring(
32-
useTransform(x, [-300, 300], [-5, 5]),
33-
springConfig
34-
);
21+
const rotateX = useSpring(useTransform(y, [-300, 300], [5, -5]), springConfig);
22+
const rotateY = useSpring(useTransform(x, [-300, 300], [-5, 5]), springConfig);
3523

3624
const handleMouseMove = (event: React.MouseEvent<HTMLDivElement>) => {
3725
const rect = event.currentTarget.getBoundingClientRect();

components/Footer.tsx

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,7 @@ const Footer = () => {
1313
</div>
1414
{/* Right Side */}
1515
<div className="flex items-center space-x-4">
16-
<a
17-
href="https://twitter.com/shydev69"
18-
target="_blank"
19-
rel="noopener noreferrer"
20-
>
16+
<a href="https://twitter.com/shydev69" target="_blank" rel="noopener noreferrer">
2117
<BsTwitterX size={24} />
2218
</a>
2319
</div>

0 commit comments

Comments
 (0)