Skip to content

Commit 0edb559

Browse files
feat: upgrade feature cards with gsap, add issue template, and fix next.js swc dev binding issue
1 parent 5ec6322 commit 0edb559

6 files changed

Lines changed: 525 additions & 53 deletions

File tree

Lines changed: 15 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,65 +1,64 @@
1-
name: 🐛 Bug Report
2-
description: Create a report to help us improve CommitPulse
3-
title: 'bug: <short description of the issue>'
4-
labels: ['bug', 'triage']
1+
name: Bug Report
2+
description: Create a report to help us improve
3+
title: 'Bug: '
4+
labels: ['bug']
55
body:
66
- type: markdown
77
attributes:
88
value: |
99
Thank you for reporting an issue! Please fill out this form as completely as possible.
1010
1111
💡 **Pro-Tip:** Once you submit this issue, you can claim it for yourself by commenting `/claim`! Only you, as the author of the issue, have permission to claim it.
12+
1213
- type: textarea
1314
id: description
1415
attributes:
1516
label: Description
1617
description: A clear and concise description of what the bug is.
1718
validations:
1819
required: true
20+
1921
- type: textarea
20-
id: steps-to-reproduce
22+
id: reproduction
2123
attributes:
2224
label: Steps to Reproduce
2325
description: How can we reproduce this bug? Please be specific.
24-
placeholder: |
26+
value: |
2527
1. Go to '...'
2628
2. Click on '....'
2729
3. Scroll down to '....'
2830
4. See error
2931
validations:
3032
required: true
33+
3134
- type: textarea
32-
id: expected-behavior
35+
id: expected
3336
attributes:
3437
label: Expected Behavior
3538
description: What did you expect to happen?
3639
validations:
3740
required: true
41+
3842
- type: textarea
3943
id: screenshots
4044
attributes:
4145
label: Screenshots / Logs
4246
description: If applicable, drag and drop screenshots or paste error logs here to help explain your problem.
4347
validations:
4448
required: false
49+
4550
- type: input
4651
id: username
4752
attributes:
4853
label: GitHub Username (If applicable)
4954
description: The GitHub username you were trying to generate a badge for.
5055
validations:
5156
required: false
52-
- type: dropdown
53-
id: browser
57+
58+
- type: textarea
59+
id: environment
5460
attributes:
5561
label: Environment
5662
description: What browser/environment are you experiencing this in?
57-
options:
58-
- Chrome
59-
- Firefox
60-
- Safari
61-
- Edge
62-
- GitHub Mobile App
63-
- Other
6463
validations:
6564
required: true

app/page.test.tsx

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,31 @@ vi.mock('next/link', () => ({
2929
),
3030
}));
3131

32+
// Mock GSAP so FeatureCards don't break in JSDOM
33+
vi.mock('gsap', () => {
34+
const tween = { kill: vi.fn() };
35+
const timeline = {
36+
to: vi.fn().mockReturnThis(),
37+
fromTo: vi.fn().mockReturnThis(),
38+
set: vi.fn().mockReturnThis(),
39+
kill: vi.fn(),
40+
};
41+
return {
42+
default: {
43+
registerPlugin: vi.fn(),
44+
set: vi.fn(),
45+
to: vi.fn().mockReturnValue(tween),
46+
fromTo: vi.fn().mockReturnValue(tween),
47+
timeline: vi.fn().mockReturnValue(timeline),
48+
context: vi.fn((_fn: any) => ({ revert: vi.fn() })),
49+
},
50+
};
51+
});
52+
53+
vi.mock('gsap/ScrollTrigger', () => ({
54+
ScrollTrigger: {},
55+
}));
56+
3257
// Mock framer-motion
3358
vi.mock('framer-motion', () => ({
3459
motion: {

app/page.tsx

Lines changed: 13 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ import { CustomizeCTA } from './components/CustomizeCTA';
1111
import { useRecentSearches } from '@/hooks/useRecentSearches';
1212
import { useDebounce } from '@/hooks/useDebounce';
1313
import { Footer } from '@/app/components/Footer';
14+
import InteractiveViewer from '@/components/InteractiveViewer';
15+
import { FeatureCard, FeatureCardsSection } from '@/components/FeatureCards';
1416

1517
const Icons = {
1618
Github: () => (
@@ -423,63 +425,38 @@ export default function LandingPage() {
423425

424426
<CustomizeCTA />
425427

426-
<div className="grid gap-6 md:grid-cols-3">
428+
<FeatureCardsSection>
427429
<FeatureCard
428430
icon={<Icons.Zap />}
429-
accent="text-black dark:text-white"
431+
accent="text-white"
432+
accentColor="#10b981"
433+
index={0}
430434
title="Real-time Sync"
431435
desc="Pulled directly from GitHub GraphQL API. Your streak updates as fast as your code pushes."
432436
/>
433437
<FeatureCard
434438
icon={<Icons.Copy />}
435-
accent="text-black dark:text-white"
439+
accent="text-white"
440+
accentColor="#8b5cf6"
441+
index={1}
436442
title="Theme Engine"
437443
desc="Switch between Neon, Dracula, or custom HEX modes via simple URL management."
438444
/>
439445
<FeatureCard
440446
icon={<Icons.Box />}
441-
accent="text-black dark:text-white"
447+
accent="text-white"
448+
accentColor="#06b6d4"
449+
index={2}
442450
title="Isometric Math"
443451
desc="Sophisticated 3D projection formulas turn 2D data into digital architecture."
444452
/>
445-
</div>
453+
</FeatureCardsSection>
446454
<Footer />
447455
</main>
448456
</div>
449457
);
450458
}
451459

452-
function FeatureCard({
453-
icon,
454-
title,
455-
desc,
456-
accent,
457-
}: {
458-
icon: ReactNode;
459-
title: string;
460-
desc: string;
461-
accent: string;
462-
}) {
463-
return (
464-
<motion.div
465-
whileHover={{ y: -5, scale: 1.02 }}
466-
transition={{ type: 'spring', stiffness: 300 }}
467-
className="group relative overflow-hidden rounded-3xl border border-black/5 bg-white/60 p-8 shadow-xl shadow-black/5 hover:border-emerald-500/30 dark:border-white/10 dark:bg-[#0a0a0a]/80 dark:shadow-2xl dark:shadow-black/50 dark:hover:border-emerald-500/40 dark:hover:bg-[#111] transition-all duration-300 backdrop-blur-xl"
468-
>
469-
<div className="absolute -right-20 -top-20 h-40 w-40 rounded-full bg-emerald-500/10 blur-3xl transition-all duration-500 group-hover:bg-emerald-500/20" />
470-
<div
471-
className={`mb-6 w-fit rounded-2xl bg-gradient-to-br from-gray-100 to-gray-50 p-3.5 text-black shadow-sm ring-1 ring-black/5 dark:from-white/10 dark:to-white/5 dark:text-white dark:ring-white/10 ${accent}`}
472-
>
473-
{icon}
474-
</div>
475-
<h3 className="mb-3 text-lg font-bold text-gray-900 dark:text-white tracking-tight">
476-
{title}
477-
</h3>
478-
<p className="text-sm leading-relaxed text-gray-600 dark:text-white/65">{desc}</p>
479-
</motion.div>
480-
);
481-
}
482-
483460
const STEPS = [
484461
{
485462
n: '01',

0 commit comments

Comments
 (0)