/** * Shared voice-mode glow helpers: the audio-intensity reducer and the * theme-derived accent colors. The DOM * applier that consumes these lives in `voiceGlowController.ts`; callers own * their own animation loop, target and gating. * * This module is intentionally pure (no DOM / CSS imports) so it stays unit * testable. */ import { Color } from "../../../../../base/common/color.js"; import { IColorTheme } from "../../../../../platform/theme/common/themeService.js"; /** * Whether the connected voice input owns a visible surface. */ export declare function shouldRenderVoiceInputGlow(connected: boolean, active: boolean, ownsVoice: boolean): boolean; /** * Reduce an analyser's frequency data to a normalized [0, 1] intensity. Returns * a small resting value when no analyser is available (before capture/playback). * `dataArray` is a ref-cell reused across frames, lazily sized to the bin count. */ export declare function readVoiceGlowIntensity(analyser: AnalyserNode | null, dataArray: { value: Uint8Array | undefined; }): number; /** Resolved accents shared by all connected voice states. */ export interface IVoiceGlowColors { readonly listening: Color; readonly speaking: Color; readonly background: Color; } /** * Blue accents used before theme colors are resolved. */ export declare const DEFAULT_VOICE_GLOW_COLORS: IVoiceGlowColors; /** * Resolve the shared listening/speaking accent from the active theme. */ export declare function resolveVoiceGlowColors(theme: Pick): IVoiceGlowColors; /** Which of the two talking states a rim is showing. */ export type VoiceRimMood = "cool" | "warm"; /** Whether the surrounding surface is light or dark. */ export type GlowThemeKind = "light" | "dark"; /** * Tune a raw accent into the color a rim actually paints with: hue nudged off the * accent, saturation bounded so a washed-out or neon theme color still reads as * light, and lightness pinned so the rim carries the same weight in any theme. * * Shared with the dictation microphone glow, so an open microphone is the same * color whichever feature opened it. */ export declare function resolveVoiceRimAccent(accent: Color, mood: VoiceRimMood, theme: GlowThemeKind, background?: Color): IVoiceRimAccent; /** The HSL parts a rim paints with, as resolved by {@link resolveVoiceRimAccent}. */ export interface IVoiceRimAccent { readonly hue: number; readonly saturation: number; readonly lightness: number; } /** * Box-shadow for a voice mic/icon button glow, shared by surfaces that light up * the microphone glyph in addition to the input border. */ export declare function computeVoiceMicGlowBoxShadow(intensity: number, colors?: IVoiceGlowColors): string;