import { useMemo, useState } from "react"; import { OutlineButton } from "@/components/outline-button"; import { grants, taglines } from "@/lib/content"; export function GrantLetter() { const [door, setDoor] = useState(grants[0].program); const [name, setName] = useState(""); const [org, setOrg] = useState(""); const [copied, setCopied] = useState(false); const program = grants.find((g) => g.program === door) ?? grants[0]; const letter = useMemo(() => { const who = name.trim() || "[Name]"; const house = org.trim() || "[Agency / office]"; return `Dear ${house}, I am writing from the Perlas Foundation in Los Angeles to inquire about a single pilot under ${program.door}. ${taglines.federal} The named program is ${program.program}. What we actually deliver: ${program.deliver} We are sequencing EIN and 501(c)(3) determination first, then one pilot grant — not five frontiers. We do not write height, dress size, race, or genetic-fitness language into policy, grants, or bylaws. We do not ask for a weapons catalog or a city charter. Adult artists who choose this house receive safety, pay, files, health access, and a path that does not require a private sponsor. I would be grateful for the correct program officer and any current notice of funding that matches this work. Respectfully, ${who} Perlas Foundation Los Angeles`; }, [name, org, program]); async function copy() { try { await navigator.clipboard.writeText(letter); setCopied(true); window.setTimeout(() => setCopied(false), 1800); } catch { setCopied(false); } } return (
{letter}