"use client"; /** * Summary Display * * COPIED VERBATIM FROM: components/onboarding/steps/summary-step.tsx:99-149 * Renders summary sections with editable cards */ import { Edit2 } from "lucide-react"; import type { ReactNode } from "react"; import { ANIMATION_CLASSES, getStaggerStyle, STAGGER_PRESETS, } from "../animations"; import { cx } from "../lib/utils"; import { OnboardingCard } from "../primitives/onboarding-card"; import type { SummaryDisplayProps } from "../types/fields"; /** * Render value helper * COPIED VERBATIM FROM: components/onboarding/steps/summary-step.tsx:70-86 */ function renderValue(value: string | string[] | ReactNode) { if (Array.isArray(value)) { return ( ); } if (typeof value === "string") { return {value}; } return value; } export function SummaryDisplay({ sections }: SummaryDisplayProps) { return (
{sections.map((section, sectionIndex) => (
{section.icon && (
{section.icon}
)}

{section.title}

{section.onEdit && ( )}
{section.items.map((item, itemIndex) => (
{item.icon} {item.label}
{renderValue(item.value)}
))}
))}
); }