import { useEffect, useState } from "react"; import { Buildings, Stack, FileText, ShieldCheck, SealCheck, Check, } from "@phosphor-icons/react"; import { api, type RunSummary } from "./lib/api"; import { Intake } from "./components/Intake"; import { CinIntake } from "./components/CinIntake"; import { Ledger } from "./components/Ledger"; import { Draft } from "./components/Draft"; import { Board } from "./components/Board"; import { Handoff } from "./components/Handoff"; const STEPS = [ { id: "intake", label: "Issuer", icon: Buildings }, { id: "ledger", label: "Disclosure ledger", icon: Stack }, { id: "draft", label: "Draft", icon: FileText }, { id: "board", label: "Consistency check", icon: ShieldCheck }, { id: "handoff", label: "Handoff", icon: SealCheck }, ] as const; type StepId = (typeof STEPS)[number]["id"]; function IntakeTabs({ onStarted }: { onStarted: (r: RunSummary) => void }) { const [mode, setMode] = useState<"listed" | "cin">("listed"); return ( <>

Select an issuer

A listed company can be found by search and read from its own filing. A company that has not listed yet has no exchange history at all, so it is identified by its Corporate Identity Number and its records are the ones it supplies.

{mode === "listed" ? : } ); } export function App() { const [step, setStep] = useState("intake"); const [run, setRun] = useState(null); const [health, setHealth] = useState(null); useEffect(() => { api.health().then(setHealth).catch(() => setHealth(null)); }, []); const reached = (id: StepId) => { if (!run) return id === "intake"; return STEPS.findIndex((s) => s.id === id) <= STEPS.findIndex((s) => s.id === step); }; return (
PrimaryDraft the IPO offer document that checks itself
{health && ( <> {health.rule_count} deterministic checks {health.companies} real BSE SME issuers narrative AI {health.llm?.enabled ? "on" : "off"} )}
{step === "intake" && ( { setRun(r); setStep("ledger"); }} /> )} {step === "ledger" && run && ( setStep("draft")} /> )} {step === "draft" && run && ( setStep("board")} /> )} {step === "board" && run && ( setStep("handoff")} /> )} {step === "handoff" && run && }
); }