"use client"; import { MobileIcon } from "@radix-ui/react-icons"; import { cn } from "@ui/lib"; import { CloudIcon, ComputerIcon, PaperclipIcon, StarIcon, WandIcon, } from "lucide-react"; import Image, { type StaticImageData } from "next/image"; import { type JSXElementConstructor, type ReactNode, useState } from "react"; import heroImage from "../../../../public/images/hero.svg"; export const featureTabs: Array<{ id: string; title: string; icon: JSXElementConstructor; subtitle?: string; description?: ReactNode; image?: StaticImageData; imageBorder?: boolean; stack?: { title: string; href: string; icon: JSXElementConstructor; }[]; highlights?: { title: string; description: string; icon: JSXElementConstructor; demoLink?: string; docsLink?: string; }[]; }> = [ { id: "feature1", title: "Feature 1", icon: StarIcon, subtitle: "Do more with our amazing SaaS.", description: "This is a brilliant feature. And below you can see some reasons why. This is basically just a dummy text.", stack: [], image: heroImage, imageBorder: false, highlights: [ { title: "Benefit 1", description: "This is an awesome benefit. And below you can see some reasons why. This is basically just a dummy text.", icon: WandIcon, }, { title: "Benefit 2", description: "This is an awesome benefit. And below you can see some reasons why. This is basically just a dummy text.", icon: ComputerIcon, }, { title: "Benefit 3", description: "This is an awesome benefit. And below you can see some reasons why. This is basically just a dummy text.", icon: MobileIcon, }, ], }, { id: "feature2", title: "Feature 2", icon: CloudIcon, subtitle: "Your SaaS can also do this.", description: "Another dummy text for another feature.", stack: [], image: heroImage, imageBorder: false, highlights: [ { title: "Benefit 1", description: "This is an awesome benefit. And below you can see some reasons why. This is basically just a dummy text.", icon: WandIcon, }, { title: "Benefit 2", description: "This is an awesome benefit. And below you can see some reasons why. This is basically just a dummy text.", icon: ComputerIcon, }, { title: "Benefit 3", description: "This is an awesome benefit. And below you can see some reasons why. This is basically just a dummy text.", icon: MobileIcon, }, ], }, { id: "feature3", title: "Feature 3", icon: PaperclipIcon, subtitle: "We even got a third one.", description: "Of course your SaaS will have more features than this, but this is just a dummy text.", stack: [], image: heroImage, imageBorder: false, highlights: [ { title: "Benefit 1", description: "This is an awesome benefit. And below you can see some reasons why. This is basically just a dummy text.", icon: WandIcon, }, { title: "Benefit 2", description: "This is an awesome benefit. And below you can see some reasons why. This is basically just a dummy text.", icon: ComputerIcon, }, { title: "Benefit 3", description: "This is an awesome benefit. And below you can see some reasons why. This is basically just a dummy text.", icon: MobileIcon, }, ], }, ]; export function Features() { const [selectedTab, setSelectedTab] = useState(featureTabs[0].id); return (

Features your clients will love

In this section you can showcase all the features of your SaaS provides and how they can benefit your clients.

{featureTabs.map((tab) => { return ( ); })}
{featureTabs.map((tab) => { const filteredStack = tab.stack || []; const filteredHighlights = tab.highlights || []; return (

{tab.title}.{" "} {tab.subtitle}

{tab.description && (

{tab.description}

)} {filteredStack?.length > 0 && (
{filteredStack.map( (tool, k) => ( {tool.title} ), )}
)}
{tab.image && ( {tab.title} )}
{filteredHighlights.length > 0 && (
{filteredHighlights.map( (highlight, k) => (
{highlight.title}

{ highlight.description }

), )}
)}
); })}
); }