logsdx
Version:
<div align="center"><img alt="logsdx" width="300" src="https://github.com/user-attachments/assets/cc2a3b55-5bfd-44e8-a330-bfa146b50059" /></div>
44 lines (43 loc) • 1.74 kB
TypeScript
import type { z } from "zod";
import { tokenSchema, tokenListSchema } from "./index";
import type { JsonSchemaOptions } from "./types";
import type { Theme } from "../types";
export declare function parseToken(token: unknown): z.infer<typeof tokenSchema>;
export declare function parseTokenSafe(token: unknown): {
success: boolean;
data?: z.infer<typeof tokenSchema>;
error?: z.ZodError;
};
export declare function parseTokenList(tokens: unknown): z.infer<typeof tokenListSchema>;
export declare function parseTokenListSafe(tokens: unknown): {
success: boolean;
data?: z.infer<typeof tokenListSchema>;
error?: z.ZodError;
};
export declare function createTokenJsonSchemaOptions(): JsonSchemaOptions;
export declare function convertTokenSchemaToJson(): import("zod-to-json-schema").JsonSchema7Type & {
$schema?: string | undefined;
definitions?: {
[key: string]: import("zod-to-json-schema").JsonSchema7Type;
} | undefined;
};
export declare function parseTheme(theme: unknown): Theme;
export declare function parseThemeSafe(theme: unknown): {
success: boolean;
data?: Theme;
error?: z.ZodError;
};
export declare function createThemeValidationError(error: unknown): Error;
export declare function validateTheme(theme: unknown): Theme;
export declare function validateThemeSafe(theme: unknown): {
success: boolean;
data?: Theme;
error?: z.ZodError;
};
export declare function createThemeJsonSchemaOptions(): JsonSchemaOptions;
export declare function convertThemeSchemaToJson(): import("zod-to-json-schema").JsonSchema7Type & {
$schema?: string | undefined;
definitions?: {
[key: string]: import("zod-to-json-schema").JsonSchema7Type;
} | undefined;
};