svrjs-nextjs-website/components/shared/FAQ.tsx

40 lines
1.2 KiB
TypeScript
Raw Normal View History

2024-06-15 18:41:36 +02:00
import { questions } from "@/constants";
2024-06-15 17:30:51 +02:00
import React from "react";
2024-06-15 18:41:36 +02:00
import {
Accordion,
AccordionContent,
AccordionItem,
AccordionTrigger,
} from "../ui/accordion";
2024-06-15 17:30:51 +02:00
const Faq = () => {
2024-06-15 18:41:36 +02:00
return (
<section id="faq" className="wrapper container py-24 md:py-28">
<h2 className="text-3xl md:text-5xl font-bold mb-4 text-black dark:bg-clip-text dark:text-transparent dark:bg-gradient-to-b dark:from-white dark:to-neutral-400">
Frequently Asked Question
</h2>
2024-06-16 13:13:09 +02:00
<p className="text-lg text-muted-foreground text-start mt-4 mb-8">
2024-06-15 18:41:36 +02:00
Find answers to common questions about SVRJS
</p>
<Accordion
type="single"
collapsible={true}
className="w-full AccordionRoot"
>
{questions.map(({ question, answer, key }) => (
<AccordionItem key={key} value={key} className="border-b">
<AccordionTrigger className="text-left text-lg">
{question}
</AccordionTrigger>
<AccordionContent className="text-[1rem] text-muted-foreground">
{answer}
</AccordionContent>
</AccordionItem>
))}
</Accordion>
</section>
);
2024-06-15 17:30:51 +02:00
};
export default Faq;