Skip to content

Commit f669fb6

Browse files
GeneAIclaude
authored andcommitted
fix: Make GitHub Issues link clickable in FAQ page
- Updated FAQ data structure to support ReactNode answers - Added answerText for structured data compatibility - GitHub Issues URL now renders as a proper link 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <[email protected]>
1 parent 8d974c1 commit f669fb6

File tree

1 file changed

+25
-3
lines changed

1 file changed

+25
-3
lines changed

website/app/faq/page.tsx

Lines changed: 25 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,22 @@
11
import type { Metadata } from 'next';
2+
import type { ReactNode } from 'react';
3+
import Link from 'next/link';
24
import Navigation from '@/components/Navigation';
35
import Footer from '@/components/Footer';
46
import { generateMetadata, generateStructuredData } from '@/lib/metadata';
57

6-
const faqData = [
8+
interface FAQItem {
9+
question: string;
10+
answer: string | ReactNode;
11+
answerText?: string; // Plain text version for structured data
12+
}
13+
14+
interface FAQCategory {
15+
category: string;
16+
questions: FAQItem[];
17+
}
18+
19+
const faqData: FAQCategory[] = [
720
{
821
category: 'General',
922
questions: [
@@ -85,7 +98,16 @@ const faqData = [
8598
},
8699
{
87100
question: 'How do I report bugs?',
88-
answer: 'Report bugs via GitHub Issues at https://github.com/Smart-AI-Memory/empathy-framework/issues. Include your environment details, steps to reproduce, and expected vs actual behavior.',
101+
answer: (
102+
<>
103+
Report bugs via{' '}
104+
<Link href="https://github.com/Smart-AI-Memory/empathy-framework/issues" className="text-[var(--primary)] hover:underline" target="_blank" rel="noopener noreferrer">
105+
GitHub Issues
106+
</Link>
107+
. Include your environment details, steps to reproduce, and expected vs actual behavior.
108+
</>
109+
),
110+
answerText: 'Report bugs via GitHub Issues at https://github.com/Smart-AI-Memory/empathy-framework/issues. Include your environment details, steps to reproduce, and expected vs actual behavior.',
89111
},
90112
{
91113
question: 'Can I contribute to the project?',
@@ -106,7 +128,7 @@ export default function FAQPage() {
106128
questions: faqData.flatMap(category =>
107129
category.questions.map(q => ({
108130
question: q.question,
109-
answer: q.answer,
131+
answer: q.answerText ?? (typeof q.answer === 'string' ? q.answer : ''),
110132
}))
111133
),
112134
});

0 commit comments

Comments
 (0)