/** * Resolves the `--toruk-*` custom properties for one mounted widget. * * Three inputs feed the result, in increasing precedence: * 1. the Core-derived palette for the resolved light/dark mode (`@/design-tokens`); * 2. the active template variant's token overrides (Erebus' purple, Neptune's cyan); * 3. the embedder's theme — the long-standing public options (`textInput.sendButtonColor`, * `userMessage.backgroundColor`, …), mapped onto tokens so every existing configuration * keeps working unchanged against the new token-driven components. * * This lives in the widget rather than in `@/design-tokens` because only the widget knows the * theme shape and the reactive graph; the token module stays a plain data + merge layer. */ import { type Accessor } from 'solid-js'; import { type TorukTokenMap, type TorukThemeMode } from '@/design-tokens'; import type { BotProps } from '@/widget/types'; type WidgetTheme = Pick; type DesignTokenInputs = { /** Resolved chat surface colour. May be `transparent` on gradient variants. */ backgroundColor: Accessor; /** The variant's own base colour, used when the chat surface is transparent. */ themeBaseColor: Accessor; /** Variant-supplied token overrides. */ variantTokens: Accessor; /** The embedder's theme, as already spread onto BotProps. */ theme: Accessor; }; export declare function resolveFontTokens(fonts: Pick): TorukTokenMap; export declare function createDesignTokens(inputs: DesignTokenInputs): { mode: Accessor; tokens: Accessor; }; export {};