import React, { ReactNode } from 'react'; interface FigmaQuestionProps { question: string; description?: string; children: ReactNode; onBack?: () => void; onNext?: () => void; nextDisabled?: boolean; backDisabled?: boolean; nextText?: string; backText?: string; showBackButton?: boolean; currentStep?: number; totalSteps?: number; stepTitle?: string; className?: string; } export const EnhancedFigmaQuestion: React.FC = ({ question, description, children, onBack, onNext, nextDisabled = false, backDisabled = false, nextText = "Next", backText = "Back", showBackButton = true, currentStep = 1, totalSteps = 8, stepTitle = "Company Overview & Mission.", className = "" }) => { // Generate the progress indicator dots const renderProgressDots = () => { const dots = []; for (let i = 0; i < totalSteps; i++) { if (i < currentStep - 1) { // Completed steps - elongated orange dots.push(
); } else if (i === currentStep - 1) { // Current step - elongated orange dots.push(
); } else { // Future steps - small gray circles dots.push(
); } } return dots; }; return (
{question}
{children}
{showBackButton && (
{backText}
)}
{nextText}
{/* Step indicator - top left */}
{currentStep} of {totalSteps}
{/* Skip button - top right */}
Skip
{/* Progress indicator and title - top center */}
{renderProgressDots()}
{stepTitle}
); }; // Question Card Component (for Q&A style layout) interface FigmaQuestionCardProps { question: string; description?: string; children: ReactNode; className?: string; } export const FigmaQuestionCard: React.FC = ({ question, description, children, className = "" }) => { return (
Q
{question}
{description && (
{description}
)}
A
{children}
); }; // Enhanced input that matches Figma designs interface EnhancedFigmaInputProps { placeholder?: string; value?: string; onChange?: (value: string) => void; multiline?: boolean; rows?: number; className?: string; } export const EnhancedFigmaInput: React.FC = ({ placeholder = "Type your answer....", value = "", onChange, multiline = false, rows = 4, className = "" }) => { const baseClasses = "self-stretch min-h-40 p-5 relative bg-Neutrals-NeutralSlate100 rounded-xl inline-flex justify-start items-start gap-2.5 overflow-hidden"; const inputClasses = "flex-1 justify-start text-Neutrals-NeutralSlate500 text-base font-normal font-['Inter'] leading-normal bg-transparent border-none outline-none resize-none"; if (multiline) { return (