/** * Outcome-reason taxonomy (UI-facing) * * Distribution modules render an outcome state when a user can't proceed — * because the admission grant expired, they weren't selected, the window * closed, etc. This union is the *module-facing* taxonomy, narrower than * the freeform strings the journey machine emits. * * `normalizeOutcomeReason` maps every known machine code (and any * already-normalized UI value) to a member of the union. Unknown values * fall back to `"ended"`. * * journey machine code -> UI outcome reason * ---------------------------------------------- * expired -> expired * queue_denied / draw_denied / denied / lost -> not_selected * timed_release_denied -> sold_out * outbid -> outbid * floor_unsold -> floor_unsold * reserve_not_met -> reserve_not_met * completed / already_completed -> completed (a success terminal, not a loss) * won -> won * cancelled -> cancelled * left -> left (voluntary exit: leave/withdraw) * closed / unknown / other -> ended * * The terminal projection carries the outcome TYPE (completed/denied/lost); * mapping it here makes a paying winner, a denied entrant, and a plain loss * render distinct copy rather than collapsing to the generic "ended" panel. * * Static story lanes pass UI values directly (e.g. `"outbid"`); those * pass through unchanged. */ export type OutcomeReason = "expired" | "not_selected" | "sold_out" | "outbid" | "floor_unsold" | "reserve_not_met" | "completed" | "won" | "cancelled" | "left" | "ended"; export declare function normalizeOutcomeReason(reason: string | undefined): OutcomeReason; export declare function normalizeSequenceOutcomeReason(outcome: { type: string; reason?: string; } | undefined, fallbackReason?: string): OutcomeReason;