import type { ConversationsTheme } from '../../../posthog-conversations-types'; export declare const WIDGET_CONTAINER_ID = "ph-conversations-widget-container"; export declare const DEFAULT_PRIMARY_COLOR = "#5375ff"; export declare const DEFAULT_ON_PRIMARY_COLOR: string; export type ThemeToken = 'primary' | 'on-primary' | 'bg' | 'surface' | 'text' | 'muted' | 'border' | 'agent-bubble' | 'font' | 'radius' | 'launcher-shadow' | 'window-shadow'; /** `var(--ph-conv-, )`. The fallback is the light value used when no theme sets the token. */ export declare const cssVar: (token: ThemeToken, fallback: string) => string; /** * Calculate contrasting text color (black or white) based on background brightness * Uses HSP (Highly Sensitive Purity) brightness formula */ export declare function getContrastTextColor(hexColor: string): string; /** * Merge a theme patch over a base theme. `dark` is merged one level deeper. * A key the patch sets to undefined is removed, so a later merge falls back to the value beneath it. */ export declare function mergeThemes(base: ConversationsTheme | undefined, patch: ConversationsTheme | undefined): { dark: { primary?: string; primaryText?: string; background?: string; surface?: string; text?: string; mutedText?: string; border?: string; agentBubble?: string; }; colorScheme?: "light" | "dark" | "auto"; fontFamily?: string; borderRadius?: string; launcherShadow?: string; windowShadow?: string; primary?: string; primaryText?: string; background?: string; surface?: string; text?: string; mutedText?: string; border?: string; agentBubble?: string; }; /** * Build the widget's theme stylesheet. * * Rules select the container by attribute rather than by id so they stay below the specificity of * `#ph-conversations-widget-container`: any rule a customer writes for the container overrides * the SDK's values. `:where()` would do the same but is missing from browsers we still support. */ export declare function buildThemeCss(remoteColor: string | undefined, theme: ConversationsTheme): string;