import { z } from 'zod'; type TokenMap = Record; type CompoundCondition = Record; declare const TwPluginOptionsSchema: z.ZodObject<{ classProcessor: z.ZodOptional], null>, z.ZodObject<{ css: z.ZodString; classes: z.ZodArray; }, z.core.$strip>>>; tokens: z.ZodOptional>, unknown, z.core.$ZodTypeInternals>, unknown>>>; debug: z.ZodOptional; minify: z.ZodOptional; }, z.core.$strip>; type TwPluginOptionsInput = z.infer; declare const PluginManifestSchema: z.ZodObject<{ name: z.ZodString; setup: z.ZodFunction, z.ZodUnknown>; }, z.core.$strip>; type PluginManifestInput = z.infer; declare const TransformRegistrationSchema: z.ZodFunction, z.ZodUnknown>; declare const TokenRegistrationSchema: z.ZodObject<{ name: z.ZodString; value: z.ZodString; }, z.core.$strip>; type TokenRegistrationInput = z.infer; declare const parseTwPluginOptions: (options: unknown) => { classProcessor?: z.core.$InferOuterFunctionType], null>, z.ZodObject<{ css: z.ZodString; classes: z.ZodArray; }, z.core.$strip>> | undefined; tokens?: Record> | undefined; debug?: boolean | undefined; minify?: boolean | undefined; }; declare const parsePluginManifest: (plugin: unknown) => { name: string; setup: z.core.$InferOuterFunctionType, z.ZodUnknown>; }; declare const parseTokenRegistration: (data: unknown) => { name: string; value: string; }; interface TwClassResult { css: string; classes: string[]; } interface DesignTokens { [key: string]: string | number | DesignTokens; } interface TwPluginOptions { classProcessor?: (classes: string[]) => TwClassResult; tokens?: DesignTokens; debug?: boolean; minify?: boolean; } type VariantResolver = (selector: string) => string; interface UtilityDefinition { [property: string]: string; } interface ComponentConfig { base: string; variants: Record>; compoundVariants: Array<{ class: string; } & CompoundCondition>; defaultVariants: Record; } interface TransformMeta { componentName: string; tag: string; } type TransformFn = (config: ComponentConfig, meta: TransformMeta) => ComponentConfig; type CssHook = (css: string) => string; interface TwContext { addVariant(name: string, resolver: VariantResolver): void; addUtility(name: string, styles: UtilityDefinition): void; addToken(name: string, value: string): void; addTransform(fn: TransformFn): void; onGenerateCSS(hook: CssHook): void; onBuildEnd(hook: () => void | Promise): void; getToken(name: string): string | undefined; subscribeTokens(callback: (tokens: TokenMap) => void): () => void; readonly config: Record; } interface TwPlugin { name: string; setup(ctx: TwContext): void; } interface PluginRegistry { variants: Map; utilities: Map; tokens: Map; transforms: TransformFn[]; cssHooks: CssHook[]; buildHooks: Array<() => void | Promise>; plugins: Set; } interface TokenEngineAPI { getToken?: (name: string) => string | undefined; getTokens?: () => Record | undefined; subscribeTokens?: (callback: (tokens: Record) => void) => () => void; subscribe?: (callback: (tokens: Record) => void) => () => void; } declare function resolveTokenEngine(): TokenEngineAPI | undefined; declare function readToken(engine: TokenEngineAPI | undefined, name: string): string | undefined; interface TransformContext { filename?: string; componentName?: string; tag?: string; } interface TwGlobalRegistry { transforms: Array<(config: ComponentConfig, ctx: TransformContext) => ComponentConfig>; tokens: Record; variants: Map; } declare function getGlobalRegistry(): TwGlobalRegistry; declare function registerTransform(transform: (config: ComponentConfig, ctx: TransformContext) => ComponentConfig): void; declare function registerToken(name: string, value: string): void; declare function createPluginRegistry(): PluginRegistry; declare function resetGlobalRegistry(): void; declare function createPluginContext(registry: PluginRegistry, config?: Record): TwContext; declare function createTw(config?: Record): TwContext & { registry: { plugins: Set; variants: Map; utilities: Map; tokens: Map; }; use: (plugin: TwPlugin) => void; }; /** * Creates a TwContext that writes through to the global (legacy) registry. * Used by createTwPlugin() in the plugin package. */ declare function createGlobalPluginContext(config?: Record): TwContext; declare function use(plugin: TwPlugin): void; declare function presetTokens(tokens: Record): TwPlugin; declare function presetVariants(variants: Record): TwPlugin; declare function presetScrollbar(): TwPlugin; export { type ComponentConfig, type CompoundCondition, type CssHook, type DesignTokens, type PluginManifestInput, PluginManifestSchema, type PluginRegistry, type TokenEngineAPI, type TokenMap, type TokenRegistrationInput, TokenRegistrationSchema, type TransformContext, type TransformFn, type TransformMeta, TransformRegistrationSchema, type TwClassResult, type TwContext, type TwGlobalRegistry, type TwPlugin, type TwPluginOptions, type TwPluginOptionsInput, TwPluginOptionsSchema, type UtilityDefinition, type VariantResolver, createGlobalPluginContext, createPluginContext, createPluginRegistry, createTw, getGlobalRegistry, parsePluginManifest, parseTokenRegistration, parseTwPluginOptions, presetScrollbar, presetTokens, presetVariants, readToken, registerToken, registerTransform, resetGlobalRegistry, resolveTokenEngine, use };