/** * Trust chrome — the DECISION, not a rendering. * * `decideChrome` says whether a piece of copy counts as adapted for this * viewer. Nothing in the SDK renders a visible mark from it by default; the * react package exports `InlineMark` for integrators who opt into one, and * the impression beacon reports the decision so chrome state stays * measurable. * * The honesty constraint (the part W5 exists for): `marked` must NOT be true * for copy that was merely served. Before content-source signalling, the * silent static-fallback path was indistinguishable on the wire from live * generation — so a client marking "everything that came down a stream" * would have been labelling stored copy as adapted. Claiming static copy is * adapted is a worse failure than under-claiming generated copy, because one * under-claims and the other lies. */ import type { ContentSource } from "./wire.js"; /** Where the viewer's "show me the standard version" preference lives. */ export declare const STANDARD_MODE_KEY = "st:standard"; export interface ChromeDecision { /** Does this copy count as adapted for this viewer? (Feed an opt-in * disclosure mark, and the impression beacon, from this.) */ marked: boolean; /** * Why, in one machine-readable word. Reported on the impression, so the * chrome state of real traffic is measurable rather than assumed. */ reason: "generated" | "cached" | "static" | "viewer-opted-out"; } /** * Should this copy carry the adaptation mark? * * `cached` counts as adapted: the copy WAS generated, for an earlier viewer in * the same variant × context bucket. It is not fresh, but it is not authored * either, and calling it authored would be the same lie in the other * direction. */ export declare function decideChrome(contentSource: ContentSource, viewerPrefersStandard: boolean): ChromeDecision; /** * Read the viewer's preference. * * Any failure — no storage, disabled storage, SSR, a privacy mode that throws * on access — means "no stated preference", which is the marked default. A * storage error must never be a route to an unmarked creative. */ export declare function viewerPrefersStandard(storage?: Storage): boolean; /** Persist the viewer's preference. Silent on failure, for the same reason. */ export declare function setViewerPrefersStandard(value: boolean, storage?: Storage): void; //# sourceMappingURL=trust.d.ts.map