/** True only for literal loopback hosts, never lookalike DNS names such as 127.example.com. */ export declare function isLoopbackHostname(hostname: string): boolean; /** * True when the page is local: an ordinary loopback document, or a desktop webview. * * This is what gates the SDK on the page side. The gate's purpose is to stop a REMOTE WEBSITE from * driving a developer's local bridge — a desktop app's own webview is not that, and treating it as * remote is what made Reticle refuse to start inside a packaged Electron or Tauri app. */ export declare function isLocalPage(protocol: string, hostname: string): boolean; /** * What `URL.origin` yields for a scheme that has no tuple origin — and what a browser puts in the * `Origin` header for the same. Desktop webviews are the common case: `tauri://localhost` on * macOS/Linux, `app://.` or `file://` in a packaged Electron renderer. */ export declare const OPAQUE_ORIGIN = "null"; /** * True when an Origin carries no attributable host — a desktop webview or a `file://` document. * Such an origin cannot be checked against `isLoopbackHostname`; callers must fall back to the * pairing token, exactly as they do for a request that omits `Origin` entirely. */ export declare function isOpaqueOrigin(origin: string): boolean; /** * Best-effort classifier for labels and tool names that can trigger irreversible effects. * * `role` is the resolved ARIA role of the control. An `option` is a value picker: its text names * the value, not an action, so "Payment" as a select choice is not a payment. Callers that have no * role (a tool name, a click with no role on the descriptor) omit it and the text decides. */ export declare function isDangerousActionText(text: string, role?: string): boolean; export declare const OutwardAction: { readonly INVITE: "invite"; readonly SEND: "send"; readonly SHARE: "share"; readonly DELETE: "delete"; readonly PAY: "pay"; readonly PUBLISH: "publish"; readonly REVOKE: "revoke"; readonly TRANSFER: "transfer"; readonly SIGN_OUT: "sign out"; readonly CHANGE_ROLE: "change role"; readonly CREATE_KEY: "create key"; /** Reassigning, reopening, archiving, approving: changing an item's state for everyone. */ readonly CHANGE_STATE: "change state"; }; export type OutwardAction = (typeof OutwardAction)[keyof typeof OutwardAction]; /** The outward action a control would take, from its text and role; value pickers take none. */ export declare function outwardActionOf(text: string, role?: string): OutwardAction | undefined; /** * The outward actions a journey asks for in so many words. "Invite a teammate" asks for invite; * "she does not send an invite" and "without sending" ask for nothing. Pure. */ export declare function outwardActionsAsked(journey: string): OutwardAction[]; /** What the Harness says, and the journey records, when it would not press one. */ export declare const outwardRefusal: (action: OutwardAction) => string;