"use client"; import BoltOutlinedIcon from "@mui/icons-material/BoltOutlined"; import LanguageOutlinedIcon from "@mui/icons-material/LanguageOutlined"; import LockOpenOutlinedIcon from "@mui/icons-material/LockOpenOutlined"; import VerifiedUserOutlinedIcon from "@mui/icons-material/VerifiedUserOutlined"; import { Button } from "@12-apps/ui/form/Button"; import { Box } from "@12-apps/ui/mui/Box"; import { Stack } from "@12-apps/ui/mui/Stack"; import { Text } from "@12-apps/ui/typography/Text"; import type { AiCapability } from "../guide"; import type { AiCapabilitiesCopy, AiLandingCopy } from "./copy"; import { AiCapabilities } from "./ai-capabilities"; import { FeatureBadge, type FeatureBadgeItem } from "./feature-badge"; /** * The ICONS for the landing's reassurance strip, keyed by the copy's own ids. * * The package keeps the icons and the host keeps the words: an icon is not * copy, and a pack that had to ship React elements could not be a plain data * file. An id the map does not know renders without an icon rather than * throwing — a host adding a fifth point should get its words on screen. */ const TRUST_ICONS: Readonly> = { login: , install: , permissions: , surface: , }; function trustBadges(trust: AiLandingCopy["trust"]): FeatureBadgeItem[] { return trust.map((point) => ({ icon: TRUST_ICONS[point.id], label: point.label, caption: point.caption, })); } /** The single-column marketing hero: eyebrow + headline + description + CTA. */ function Hero({ onStart, copy, }: { onStart: () => void; copy: AiLandingCopy; }): React.JSX.Element { return ( {copy.eyebrow} {copy.titleLead}{" "} {copy.titleEmphasis} {" "} {copy.titleTail} {copy.lede} ); } /** * Homepage-style marketing landing for the AI integration (shown before the * owner starts): a hero, the permission reassurance, a trust/feature strip, and * the capability highlights. `onStart` begins the guided flow. `permissionModel` * and `capabilities` are REQUIRED host copy — the package ships no default * sentence (FUT-760). */ export function AiLanding({ onStart, permissionModel, capabilities, copy, capabilitiesCopy, }: { onStart: () => void; permissionModel: string; capabilities: readonly AiCapability[]; copy: AiLandingCopy; capabilitiesCopy: AiCapabilitiesCopy; }): React.JSX.Element { return ( {permissionModel} {trustBadges(copy.trust).map((f) => ( ))} ); }