/** * Await-compatible older-history result with a causal commit receipt. * * `committed` flips synchronously before the accepted older window is exposed * to React. Returning this exact object preserves the receipt directly; * synchronous wrappers that discard it remain supported through receipt * capture, while replacing it asynchronously with a plain promise does not. */ export type OlderHistoryLoadReceipt = Promise & { readonly committed: boolean; readonly tailPreserved?: boolean; }; /** * Source-compatible public callback accepted by MessageTimeline. * * The callback historically returned `void`, which permits consumers to * return any synchronous value or promise. Receipt-aware loaders opt into the * stronger runtime contract by returning (or synchronously creating through a * wrapper) an {@link OlderHistoryLoadReceipt}. */ export type OlderHistoryLoader = () => unknown; type OlderHistoryReceiptCapture = (receipt: OlderHistoryLoadReceipt) => void; /** Bind a receipt before a synchronous forwarding stack can publish state. */ export declare function invokeOlderHistoryLoaderWithReceiptCapture(load: OlderHistoryLoader, capture: OlderHistoryReceiptCapture, preserveTail?: boolean): unknown; /** * Build an await-compatible older-history receipt for custom timeline hosts. * Call `markCommitted` immediately before publishing an accepted older window. */ export declare function createOlderHistoryLoadReceipt(load: (markCommitted: () => void, preserveTail: boolean, markTailPreserved: () => void) => boolean | Promise): OlderHistoryLoadReceipt; export {};