import { pattern, UI } from "commonfabric"; interface Reaction { emoji: string; userNames: string[]; } interface Message { id: string; reactions?: Reaction[]; } interface Input { messages: Message[]; } // FIXTURE: map-inline-fallback-receivers // Verifies: inline fallback array-method receivers are transformed structurally // (msg.reactions ?? []).map(fn) → lift(...)(...).mapWithPattern(pattern(...), { msg: { id: ... } }) // (msg.reactions || []).map(fn) → lift(...)(...).mapWithPattern(pattern(...), { msg: { id: ... } }) // Context: Nested map — outer maps messages, inner fallback receivers capture msg.id and message-local reaction data export default pattern(({ messages }) => { return { [UI]: (