histoire
Version:
A fast story book powered by Vite
36 lines • 1.61 kB
TypeScript
import { z } from 'zod/v4';
/** Shared event size ceiling, measured in encoded bytes. */
export declare const UI_CHANNEL_BYTES: number;
/** Reject non-JSON values and oversized payloads before feature code executes. */
export declare function assertUiPayload(value: unknown): void;
/** Check Vite's complete custom-event frame before a feature admits bounded work. */
export declare function isUiChannelEventWithinBudget(event: string, data: unknown, reservedBytes?: number): boolean;
/** Browser correlation identity cannot collide with another client's cancellation. */
export declare const uiRequestIdSchema: z.ZodObject<{
requestId: z.ZodString;
}, z.core.$strict>;
/** Exact capture request with browser viewport bounds shared with MCP. */
export declare const uiScreenshotSchema: z.ZodObject<{
requestId: z.ZodString;
targets: z.ZodArray<z.ZodObject<{
storyId: z.ZodString;
variantId: z.ZodString;
frameKey: z.ZodOptional<z.ZodString>;
propsOverride: z.ZodOptional<z.ZodCustom<Record<string, unknown>, Record<string, unknown>>>;
}, z.core.$strict>>;
viewport: z.ZodObject<{
width: z.ZodNumber;
height: z.ZodNumber;
}, z.core.$strict>;
scale: z.ZodUnion<readonly [z.ZodLiteral<1>, z.ZodLiteral<2>, z.ZodLiteral<3>]>;
format: z.ZodEnum<{
png: "png";
webp: "webp";
}>;
background: z.ZodString;
}, z.core.$strict>;
/** Exact operation cancellation request. */
export declare const uiMcpCancelSchema: z.ZodObject<{
operationId: z.ZodString;
}, z.core.$strict>;
//# sourceMappingURL=validation.d.ts.map