{"version":3,"file":"FloatingMicButton-BmkhEhau.cjs","sources":["../../lib/vowel/components/FloatingCursorProvider.tsx","../../lib/vowel/components/VowelProviderSimple.tsx","../../node_modules/lucide-react/dist/esm/shared/src/utils.js","../../node_modules/lucide-react/dist/esm/defaultAttributes.js","../../node_modules/lucide-react/dist/esm/Icon.js","../../node_modules/lucide-react/dist/esm/createLucideIcon.js","../../node_modules/lucide-react/dist/esm/icons/brain.js","../../node_modules/lucide-react/dist/esm/icons/loader-circle.js","../../node_modules/lucide-react/dist/esm/icons/message-circle.js","../../node_modules/lucide-react/dist/esm/icons/mic-off.js","../../node_modules/lucide-react/dist/esm/icons/mic.js","../../node_modules/lucide-react/dist/esm/icons/moon.js","../../node_modules/lucide-react/dist/esm/icons/pause.js","../../node_modules/lucide-react/dist/esm/icons/settings.js","../../node_modules/lucide-react/dist/esm/icons/sparkles.js","../../node_modules/lucide-react/dist/esm/icons/sun.js","../../node_modules/lucide-react/dist/esm/icons/wrench.js","../../node_modules/lucide-react/dist/esm/icons/x.js","../../lib/vowel/components/Modal.tsx","../../lib/vowel/components/VowelSettingsModal.tsx","../../lib/vowel/components/FloatingMicButton.tsx"],"sourcesContent":["/**\n * @fileoverview Floating Cursor Provider - React Context for cursor state\n * \n * Internal provider that manages floating cursor state in React applications.\n * Automatically wrapped by VowelProvider - users don't interact with this directly.\n * \n * @module @vowel.to/client/components\n * @author vowel.to\n * @license Proprietary\n */\n\nimport { createContext, useContext, useState, useEffect, type ReactNode } from 'react';\nimport type { FloatingCursorConfig, FloatingCursorUpdate } from '../types';\n\n/**\n * Floating cursor context state\n */\nexport interface FloatingCursorContextType {\n  /** Current cursor position and state */\n  cursorState: FloatingCursorUpdate | null;\n  \n  /** Whether cursor is enabled */\n  isEnabled: boolean;\n  \n  /** Cursor configuration */\n  config: FloatingCursorConfig;\n  \n  /** Update cursor position and text */\n  updateCursor: (update: FloatingCursorUpdate) => void;\n  \n  /** Show cursor in resting position */\n  showResting: (text?: string) => void;\n  \n  /** Hide cursor */\n  hide: () => void;\n  \n  /** Enable cursor */\n  enable: () => void;\n  \n  /** Disable cursor */\n  disable: () => void;\n}\n\nconst FloatingCursorContext = createContext<FloatingCursorContextType | null>(null);\n\n/**\n * Props for FloatingCursorProvider\n * \n * Note: This is an internal component. Users don't use this directly.\n * It's automatically included in VowelProvider.\n */\nexport interface FloatingCursorProviderProps {\n  /** Floating cursor configuration */\n  config: FloatingCursorConfig;\n  \n  /** Children to render */\n  children: ReactNode;\n}\n\n/**\n * Floating Cursor Provider (Internal)\n * \n * Provides floating cursor state management for React applications.\n * This is automatically wrapped by VowelProvider - users don't need to use this directly.\n * \n * The actual cursor rendering happens in FloatingCursorRenderer, which can be:\n * - Automatically included in VowelAgent (default)\n * - Rendered separately for custom placement\n * \n * @example This is internal - users use VowelProvider instead\n * ```tsx\n * <VowelProvider client={client} floatingCursor={{ enabled: true }}>\n *   <VowelAgent /> // Cursor automatically included\n * </VowelProvider>\n * ```\n */\nexport function FloatingCursorProvider({\n  config,\n  children,\n}: FloatingCursorProviderProps) {\n  const [cursorState, setCursorState] = useState<FloatingCursorUpdate | null>(null);\n  const [isEnabled, setIsEnabled] = useState(config.enabled);\n  const [currentConfig] = useState(config);\n\n  const contextValue: FloatingCursorContextType = {\n    cursorState,\n    isEnabled,\n    config: currentConfig,\n    \n    updateCursor: (update: FloatingCursorUpdate) => {\n      console.log('🎯 [FloatingCursorProvider] Updating cursor:', update);\n      setCursorState(update);\n    },\n    \n    showResting: (text = 'Ready') => {\n      console.log('🎯 [FloatingCursorProvider] Showing resting position');\n      setCursorState({\n        x: 50,\n        y: 91,\n        text,\n        isIdle: true,\n      });\n    },\n    \n    hide: () => {\n      console.log('🎯 [FloatingCursorProvider] Hiding cursor');\n      setCursorState(null);\n    },\n    \n    enable: () => {\n      console.log('🎯 [FloatingCursorProvider] Enabling cursor');\n      setIsEnabled(true);\n    },\n    \n    disable: () => {\n      console.log('🎯 [FloatingCursorProvider] Disabling cursor');\n      setIsEnabled(false);\n      setCursorState(null);\n    },\n  };\n\n  // Expose context globally so VowelClient can detect React mode\n  useEffect(() => {\n    if (typeof window !== 'undefined') {\n      (window as any).__vowelFloatingCursorContext = contextValue;\n      console.log('🎯 [FloatingCursorProvider] Exposed context globally for VowelClient detection');\n      \n      return () => {\n        (window as any).__vowelFloatingCursorContext = null;\n        console.log('🎯 [FloatingCursorProvider] Removed global context reference');\n      };\n    }\n  }, [contextValue]);\n\n  return (\n    <FloatingCursorContext.Provider value={contextValue}>\n      {children}\n    </FloatingCursorContext.Provider>\n  );\n}\n\n/**\n * Hook to access floating cursor context\n * \n * Use this in custom components that need to control the floating cursor.\n * \n * @example\n * ```tsx\n * function MyAutomationComponent() {\n *   const { updateCursor } = useFloatingCursor();\n *   \n *   const handleAction = () => {\n *     updateCursor({ x: 50, y: 50, text: 'Clicking button', isIdle: false });\n *   };\n *   \n *   return <button onClick={handleAction}>Perform Action</button>;\n * }\n * ```\n */\nexport function useFloatingCursor(): FloatingCursorContextType {\n  const context = useContext(FloatingCursorContext);\n  \n  if (!context) {\n    throw new Error('useFloatingCursor must be used within a VowelProvider with floatingCursor enabled');\n  }\n  \n  return context;\n}\n\n/**\n * Optional hook that returns null if not in FloatingCursorProvider\n * \n * Use this for components that work with or without cursor support.\n * \n * @example\n * ```tsx\n * function MyComponent() {\n *   const cursor = useFloatingCursorOptional();\n *   \n *   const handleAction = () => {\n *     // Only update cursor if available\n *     cursor?.updateCursor({ x: 50, y: 50, text: 'Action', isIdle: false });\n *   };\n * }\n * ```\n */\nexport function useFloatingCursorOptional(): FloatingCursorContextType | null {\n  return useContext(FloatingCursorContext);\n}\n\n\n","/**\n * @fileoverview Vowel Provider - React Context wrapper for Vowel client\n * \n * This file contains the `VowelProvider` React component which wraps the Vowel\n * client in a React Context, making it accessible throughout your React application.\n * It provides hooks for accessing the client, session state, and control functions.\n * \n * Features:\n * - React Context integration\n * - Automatic state synchronization\n * - Type-safe hooks (useVowel)\n * - Session lifecycle management\n * - Event notification support\n * \n * @module @vowel.to/client/components\n * @author vowel.to\n * @license MIT\n */\n\nimport {\n  createContext,\n  useContext,\n  useState,\n  useEffect,\n  useCallback,\n  useMemo,\n  useRef,\n  type ReactNode,\n} from \"react\";\nimport { Vowel } from \"../core\";\nimport type { VoiceSessionState } from \"../managers\";\nimport { FloatingCursorProvider } from \"./FloatingCursorProvider\";\nimport type { FloatingCursorConfig } from \"../types\";\nimport \"../styles/styles.css\";\n\n/**\n * Vowel Context type\n */\nexport interface VowelContextType {\n  /** Vowel client instance (null if not initialized) */\n  client: Vowel | null;\n  \n  /** Current session state */\n  state: VoiceSessionState;\n  \n  /** Start a voice session */\n  startSession: () => Promise<void>;\n  \n  /** Stop the current session */\n  stopSession: () => void;\n  \n  /** Toggle session on/off */\n  toggleSession: () => Promise<void>;\n  \n  /** Clear transcript history */\n  clearTranscripts: () => void;\n  \n  /**\n   * Notify the AI about an app event\n   * Triggers an AI voice response without requiring user speech input\n   * \n   * @param eventDetails - Description of the event\n   * @param context - Optional context data\n   */\n  notifyEvent: (eventDetails: string, context?: Record<string, any>) => Promise<void>;\n  \n  /**\n   * Send text to the AI for processing\n   * Lower-level method for custom text interactions\n   * \n   * @param text - Text to send to the AI\n   */\n  sendText: (text: string) => Promise<void>;\n  \n  /**\n   * Update the dynamic context that gets appended to system prompt.\n   * Context is stringified, wrapped in `<context>` tags and sent via session.update.\n   * \n   * When context changes, a session.update event is automatically sent\n   * to update the system prompt so the AI knows about the current context.\n   * \n   * @param context - Context object to append to system prompt. Use null to clear.\n   * \n   * @example\n   * ```tsx\n   * const { updateContext } = useVowel();\n   * \n   * useEffect(() => {\n   *   updateContext({ page: 'product', productId: 'iphone-15-pro' });\n   *   return () => updateContext(null); // Clear on unmount\n   * }, [product]);\n   * ```\n   */\n  updateContext: (context: Record<string, unknown> | null) => void;\n  \n  /**\n   * Get current context value\n   * \n   * @returns Current context object (null if no context set)\n   * \n   * @example\n   * ```tsx\n   * const { getContext } = useVowel();\n   * const currentContext = getContext();\n   * ```\n   */\n  getContext: () => Record<string, unknown> | null;\n}\n\nconst VowelContext = createContext<VowelContextType | null>(null);\n\n/**\n * Props for VowelProvider\n */\nexport interface VowelProviderProps {\n  /** Vowel client instance (can be null if not yet initialized) */\n  client: Vowel | null;\n  \n  /** Children to render */\n  children: ReactNode;\n  \n  /** \n   * Optional: Floating cursor configuration for React mode\n   * When enabled, cursor will be rendered as a native React component\n   * \n   * @default { enabled: true } (enabled by default)\n   * \n   * Set to false to disable:\n   * @example\n   * ```tsx\n   * <VowelProvider client={client} floatingCursor={false}>\n   *   <VowelAgent />\n   * </VowelProvider>\n   * ```\n   * \n   * Or customize appearance:\n   * @example\n   * ```tsx\n   * <VowelProvider \n   *   client={client}\n   *   floatingCursor={{ \n   *     enabled: true,\n   *     appearance: { cursorColor: '#2563eb' }\n   *   }}\n   * >\n   *   <VowelAgent />\n   * </VowelProvider>\n   * ```\n  */\n  floatingCursor?: FloatingCursorConfig | false;\n\n  /**\n   * How to handle transient null clients.\n   *\n   * - `sticky` (default): keep the last known good client across transient nulls.\n   * - `strict`: immediately clear the active client when prop becomes null.\n   */\n  clientMode?: \"sticky\" | \"strict\";\n\n  /**\n   * In sticky mode, how long to wait before releasing an idle client after prop=null.\n   *\n   * This timeout is ignored while a session is live (connected/connecting/resuming/disconnecting).\n   *\n   * @default 5000\n   */\n  nullClientGraceMs?: number;\n}\n\n/**\n * Default empty state when no client is available\n */\nconst defaultEmptyState: VoiceSessionState = {\n  isConnecting: false,\n  isConnected: false,\n  isDisconnecting: false,\n  isResuming: false,\n  status: \"\",\n  transcripts: [],\n  isUserSpeaking: false,\n  isAIThinking: false,\n  isToolExecuting: false,\n  isAISpeaking: false,\n  isHibernated: false,\n  error: null,\n};\n\n/**\n * Provider component for Vowel voice agent\n * Wrap your app with this to enable voice interactions\n * \n * This is the ONLY provider users need to manage.\n * Floating cursor is enabled by default and automatically wrapped.\n * \n * @example Basic usage (floating cursor enabled by default)\n * ```tsx\n * import { VowelProvider, VowelAgent } from '@vowel.to/client/react';\n * import { vowel } from './vowel.client';\n * \n * function App() {\n *   return (\n *     <VowelProvider client={vowel}>\n *       <VowelAgent />\n *     </VowelProvider>\n *   );\n * }\n * ```\n * \n * @example Disable floating cursor\n * ```tsx\n * <VowelProvider client={vowel} floatingCursor={false}>\n *   <VowelAgent />\n * </VowelProvider>\n * ```\n * \n * @example Customize floating cursor\n * ```tsx\n * <VowelProvider \n *   client={vowel}\n *   floatingCursor={{ \n *     enabled: true,\n *     appearance: { cursorColor: '#2563eb' }\n *   }}\n * >\n *   <VowelAgent />\n * </VowelProvider>\n * ```\n */\nexport function VowelProvider({\n  client,\n  children,\n  floatingCursor,\n  clientMode = \"sticky\",\n  nullClientGraceMs = 5000,\n}: VowelProviderProps) {\n  // Active client is sticky by default so transient null props do not tear down UI/session state.\n  const [activeClient, setActiveClient] = useState<Vowel | null>(client);\n\n  // Use default empty state when no active client is available\n  const [state, setState] = useState<VoiceSessionState>(\n    activeClient?.state ?? defaultEmptyState\n  );\n\n  // Track previous active client for diagnostics.\n  const previousClientRef = useRef<Vowel | null>(activeClient);\n\n  // Update active client based on configured null-handling mode.\n  useEffect(() => {\n    if (client) {\n      setActiveClient((previous) => (previous === client ? previous : client));\n      return;\n    }\n\n    if (clientMode === \"strict\") {\n      setActiveClient(null);\n    }\n  }, [client, clientMode]);\n\n  // In sticky mode, release idle client after grace period when prop remains null.\n  useEffect(() => {\n    if (clientMode !== \"sticky\" || client || !activeClient) {\n      return;\n    }\n\n    const hasLiveSession =\n      state.isConnected ||\n      state.isConnecting ||\n      state.isResuming ||\n      state.isDisconnecting;\n\n    if (hasLiveSession) {\n      console.log(\"🔔 [VowelProvider] Sticky mode retaining live client while prop is null\");\n      return;\n    }\n\n    const timeoutId = globalThis.setTimeout(() => {\n      setActiveClient((current) => (current === activeClient ? null : current));\n    }, nullClientGraceMs);\n\n    return () => {\n      globalThis.clearTimeout(timeoutId);\n    };\n  }, [clientMode, client, activeClient, state.isConnected, state.isConnecting, state.isResuming, state.isDisconnecting, nullClientGraceMs]);\n\n  useEffect(() => {\n    // If no active client, nothing to subscribe to\n    if (!activeClient) {\n      console.log(\"🔔 [VowelProvider] No client available, using default empty state\");\n      setState(defaultEmptyState);\n      return;\n    }\n\n    if (previousClientRef.current !== activeClient) {\n      console.log(\"🔁 [VowelProvider] Active client changed\");\n      previousClientRef.current = activeClient;\n    }\n\n    console.log(\"🔔 [VowelProvider] Subscribing to state changes from client:\", activeClient);\n\n    // Sync immediately in case state changed before subscription mounted.\n    setState(activeClient.state ?? defaultEmptyState);\n    \n    // Subscribe to state changes from the client\n    const unsubscribe = activeClient.onStateChange((newState) => {\n      console.log(\"🔔 [VowelProvider] Received state update:\", newState);\n      setState(newState);\n    });\n\n    return () => {\n      console.log(\"🔕 [VowelProvider] Unsubscribing from state changes\");\n      unsubscribe();\n    };\n  }, [activeClient]);\n\n  // Memoize functions to prevent unnecessary re-renders\n  const startSession = useCallback(() => activeClient?.startSession() ?? Promise.resolve(), [activeClient]);\n  const stopSession = useCallback(() => activeClient?.stopSession(), [activeClient]);\n  const toggleSession = useCallback(() => activeClient?.toggleSession() ?? Promise.resolve(), [activeClient]);\n  const clearTranscripts = useCallback(() => activeClient?.clearTranscripts(), [activeClient]);\n  const notifyEvent = useCallback(\n    (eventDetails: string, context?: Record<string, any>) => \n      activeClient?.notifyEvent(eventDetails, context) ?? Promise.resolve(),\n    [activeClient]\n  );\n  const sendText = useCallback((text: string) => activeClient?.sendText(text) ?? Promise.resolve(), [activeClient]);\n  const updateContext = useCallback(\n    (context: Record<string, unknown> | null) => activeClient?.updateContext(context),\n    [activeClient]\n  );\n  const getContext = useCallback(() => activeClient?.getContext() ?? null, [activeClient]);\n\n  // Memoize context value to prevent unnecessary re-renders\n  const contextValue: VowelContextType = useMemo(() => ({\n    client: activeClient,\n    state,\n    startSession,\n    stopSession,\n    toggleSession,\n    clearTranscripts,\n    notifyEvent,\n    sendText,\n    updateContext,\n    getContext,\n  }), [activeClient, state, startSession, stopSession, toggleSession, clearTranscripts, notifyEvent, sendText, updateContext, getContext]);\n\n  // Main content\n  const content = (\n    <VowelContext.Provider value={contextValue}>\n      {children}\n    </VowelContext.Provider>\n  );\n\n  // Determine floating cursor config\n  // Default: enabled with default settings\n  // User can pass false to disable, or config object to customize\n  const shouldEnableFloatingCursor = floatingCursor !== false;\n  const floatingCursorConfig: FloatingCursorConfig = \n    typeof floatingCursor === 'object' \n      ? floatingCursor \n      : { enabled: true }; // Default config\n\n  // If floating cursor enabled, wrap with FloatingCursorProvider\n  if (shouldEnableFloatingCursor && floatingCursorConfig.enabled) {\n    console.log('🎯 [VowelProvider] Wrapping with FloatingCursorProvider (React mode)');\n    return (\n      <FloatingCursorProvider config={floatingCursorConfig}>\n        {content}\n      </FloatingCursorProvider>\n    );\n  }\n\n  // No floating cursor - return content directly\n  console.log('🎯 [VowelProvider] No floating cursor (disabled or web component mode)');\n  return content;\n}\n\n/**\n * Hook to access Vowel context\n * \n * @example\n * ```tsx\n * function MyComponent() {\n *   const { state, toggleSession, client } = useVowel();\n *   \n *   // Don't render if client is not available yet\n *   if (!client) {\n *     return null;\n *   }\n *   \n *   return (\n *     <button onClick={toggleSession}>\n *       {state.isConnected ? 'Stop' : 'Start'} Voice\n *     </button>\n *   );\n * }\n * ```\n */\nexport function useVowel(): VowelContextType {\n  const context = useContext(VowelContext);\n  console.log(\"[useVowel] context\", context);\n\n  if (!context) {\n    throw new Error(\"useVowel must be used within a VowelProvider\");\n  }\n  return context;\n}\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nconst toKebabCase = (string) => string.replace(/([a-z0-9])([A-Z])/g, \"$1-$2\").toLowerCase();\nconst toCamelCase = (string) => string.replace(\n  /^([A-Z])|[\\s-_]+(\\w)/g,\n  (match, p1, p2) => p2 ? p2.toUpperCase() : p1.toLowerCase()\n);\nconst toPascalCase = (string) => {\n  const camelCase = toCamelCase(string);\n  return camelCase.charAt(0).toUpperCase() + camelCase.slice(1);\n};\nconst mergeClasses = (...classes) => classes.filter((className, index, array) => {\n  return Boolean(className) && className.trim() !== \"\" && array.indexOf(className) === index;\n}).join(\" \").trim();\nconst hasA11yProp = (props) => {\n  for (const prop in props) {\n    if (prop.startsWith(\"aria-\") || prop === \"role\" || prop === \"title\") {\n      return true;\n    }\n  }\n};\n\nexport { hasA11yProp, mergeClasses, toCamelCase, toKebabCase, toPascalCase };\n//# sourceMappingURL=utils.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nvar defaultAttributes = {\n  xmlns: \"http://www.w3.org/2000/svg\",\n  width: 24,\n  height: 24,\n  viewBox: \"0 0 24 24\",\n  fill: \"none\",\n  stroke: \"currentColor\",\n  strokeWidth: 2,\n  strokeLinecap: \"round\",\n  strokeLinejoin: \"round\"\n};\n\nexport { defaultAttributes as default };\n//# sourceMappingURL=defaultAttributes.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport { forwardRef, createElement } from 'react';\nimport defaultAttributes from './defaultAttributes.js';\nimport { mergeClasses, hasA11yProp } from './shared/src/utils.js';\n\nconst Icon = forwardRef(\n  ({\n    color = \"currentColor\",\n    size = 24,\n    strokeWidth = 2,\n    absoluteStrokeWidth,\n    className = \"\",\n    children,\n    iconNode,\n    ...rest\n  }, ref) => createElement(\n    \"svg\",\n    {\n      ref,\n      ...defaultAttributes,\n      width: size,\n      height: size,\n      stroke: color,\n      strokeWidth: absoluteStrokeWidth ? Number(strokeWidth) * 24 / Number(size) : strokeWidth,\n      className: mergeClasses(\"lucide\", className),\n      ...!children && !hasA11yProp(rest) && { \"aria-hidden\": \"true\" },\n      ...rest\n    },\n    [\n      ...iconNode.map(([tag, attrs]) => createElement(tag, attrs)),\n      ...Array.isArray(children) ? children : [children]\n    ]\n  )\n);\n\nexport { Icon as default };\n//# sourceMappingURL=Icon.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport { forwardRef, createElement } from 'react';\nimport { mergeClasses, toKebabCase, toPascalCase } from './shared/src/utils.js';\nimport Icon from './Icon.js';\n\nconst createLucideIcon = (iconName, iconNode) => {\n  const Component = forwardRef(\n    ({ className, ...props }, ref) => createElement(Icon, {\n      ref,\n      iconNode,\n      className: mergeClasses(\n        `lucide-${toKebabCase(toPascalCase(iconName))}`,\n        `lucide-${iconName}`,\n        className\n      ),\n      ...props\n    })\n  );\n  Component.displayName = toPascalCase(iconName);\n  return Component;\n};\n\nexport { createLucideIcon as default };\n//# sourceMappingURL=createLucideIcon.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n  [\"path\", { d: \"M12 18V5\", key: \"adv99a\" }],\n  [\"path\", { d: \"M15 13a4.17 4.17 0 0 1-3-4 4.17 4.17 0 0 1-3 4\", key: \"1e3is1\" }],\n  [\"path\", { d: \"M17.598 6.5A3 3 0 1 0 12 5a3 3 0 1 0-5.598 1.5\", key: \"1gqd8o\" }],\n  [\"path\", { d: \"M17.997 5.125a4 4 0 0 1 2.526 5.77\", key: \"iwvgf7\" }],\n  [\"path\", { d: \"M18 18a4 4 0 0 0 2-7.464\", key: \"efp6ie\" }],\n  [\"path\", { d: \"M19.967 17.483A4 4 0 1 1 12 18a4 4 0 1 1-7.967-.517\", key: \"1gq6am\" }],\n  [\"path\", { d: \"M6 18a4 4 0 0 1-2-7.464\", key: \"k1g0md\" }],\n  [\"path\", { d: \"M6.003 5.125a4 4 0 0 0-2.526 5.77\", key: \"q97ue3\" }]\n];\nconst Brain = createLucideIcon(\"brain\", __iconNode);\n\nexport { __iconNode, Brain as default };\n//# sourceMappingURL=brain.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [[\"path\", { d: \"M21 12a9 9 0 1 1-6.219-8.56\", key: \"13zald\" }]];\nconst LoaderCircle = createLucideIcon(\"loader-circle\", __iconNode);\n\nexport { __iconNode, LoaderCircle as default };\n//# sourceMappingURL=loader-circle.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n  [\n    \"path\",\n    {\n      d: \"M2.992 16.342a2 2 0 0 1 .094 1.167l-1.065 3.29a1 1 0 0 0 1.236 1.168l3.413-.998a2 2 0 0 1 1.099.092 10 10 0 1 0-4.777-4.719\",\n      key: \"1sd12s\"\n    }\n  ]\n];\nconst MessageCircle = createLucideIcon(\"message-circle\", __iconNode);\n\nexport { __iconNode, MessageCircle as default };\n//# sourceMappingURL=message-circle.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n  [\"path\", { d: \"M12 19v3\", key: \"npa21l\" }],\n  [\"path\", { d: \"M15 9.34V5a3 3 0 0 0-5.68-1.33\", key: \"1gzdoj\" }],\n  [\"path\", { d: \"M16.95 16.95A7 7 0 0 1 5 12v-2\", key: \"cqa7eg\" }],\n  [\"path\", { d: \"M18.89 13.23A7 7 0 0 0 19 12v-2\", key: \"16hl24\" }],\n  [\"path\", { d: \"m2 2 20 20\", key: \"1ooewy\" }],\n  [\"path\", { d: \"M9 9v3a3 3 0 0 0 5.12 2.12\", key: \"r2i35w\" }]\n];\nconst MicOff = createLucideIcon(\"mic-off\", __iconNode);\n\nexport { __iconNode, MicOff as default };\n//# sourceMappingURL=mic-off.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n  [\"path\", { d: \"M12 19v3\", key: \"npa21l\" }],\n  [\"path\", { d: \"M19 10v2a7 7 0 0 1-14 0v-2\", key: \"1vc78b\" }],\n  [\"rect\", { x: \"9\", y: \"2\", width: \"6\", height: \"13\", rx: \"3\", key: \"s6n7sd\" }]\n];\nconst Mic = createLucideIcon(\"mic\", __iconNode);\n\nexport { __iconNode, Mic as default };\n//# sourceMappingURL=mic.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n  [\n    \"path\",\n    {\n      d: \"M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401\",\n      key: \"kfwtm\"\n    }\n  ]\n];\nconst Moon = createLucideIcon(\"moon\", __iconNode);\n\nexport { __iconNode, Moon as default };\n//# sourceMappingURL=moon.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n  [\"rect\", { x: \"14\", y: \"3\", width: \"5\", height: \"18\", rx: \"1\", key: \"kaeet6\" }],\n  [\"rect\", { x: \"5\", y: \"3\", width: \"5\", height: \"18\", rx: \"1\", key: \"1wsw3u\" }]\n];\nconst Pause = createLucideIcon(\"pause\", __iconNode);\n\nexport { __iconNode, Pause as default };\n//# sourceMappingURL=pause.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n  [\n    \"path\",\n    {\n      d: \"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915\",\n      key: \"1i5ecw\"\n    }\n  ],\n  [\"circle\", { cx: \"12\", cy: \"12\", r: \"3\", key: \"1v7zrd\" }]\n];\nconst Settings = createLucideIcon(\"settings\", __iconNode);\n\nexport { __iconNode, Settings as default };\n//# sourceMappingURL=settings.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n  [\n    \"path\",\n    {\n      d: \"M11.017 2.814a1 1 0 0 1 1.966 0l1.051 5.558a2 2 0 0 0 1.594 1.594l5.558 1.051a1 1 0 0 1 0 1.966l-5.558 1.051a2 2 0 0 0-1.594 1.594l-1.051 5.558a1 1 0 0 1-1.966 0l-1.051-5.558a2 2 0 0 0-1.594-1.594l-5.558-1.051a1 1 0 0 1 0-1.966l5.558-1.051a2 2 0 0 0 1.594-1.594z\",\n      key: \"1s2grr\"\n    }\n  ],\n  [\"path\", { d: \"M20 2v4\", key: \"1rf3ol\" }],\n  [\"path\", { d: \"M22 4h-4\", key: \"gwowj6\" }],\n  [\"circle\", { cx: \"4\", cy: \"20\", r: \"2\", key: \"6kqj1y\" }]\n];\nconst Sparkles = createLucideIcon(\"sparkles\", __iconNode);\n\nexport { __iconNode, Sparkles as default };\n//# sourceMappingURL=sparkles.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n  [\"circle\", { cx: \"12\", cy: \"12\", r: \"4\", key: \"4exip2\" }],\n  [\"path\", { d: \"M12 2v2\", key: \"tus03m\" }],\n  [\"path\", { d: \"M12 20v2\", key: \"1lh1kg\" }],\n  [\"path\", { d: \"m4.93 4.93 1.41 1.41\", key: \"149t6j\" }],\n  [\"path\", { d: \"m17.66 17.66 1.41 1.41\", key: \"ptbguv\" }],\n  [\"path\", { d: \"M2 12h2\", key: \"1t8f8n\" }],\n  [\"path\", { d: \"M20 12h2\", key: \"1q8mjw\" }],\n  [\"path\", { d: \"m6.34 17.66-1.41 1.41\", key: \"1m8zz5\" }],\n  [\"path\", { d: \"m19.07 4.93-1.41 1.41\", key: \"1shlcs\" }]\n];\nconst Sun = createLucideIcon(\"sun\", __iconNode);\n\nexport { __iconNode, Sun as default };\n//# sourceMappingURL=sun.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n  [\n    \"path\",\n    {\n      d: \"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z\",\n      key: \"1ngwbx\"\n    }\n  ]\n];\nconst Wrench = createLucideIcon(\"wrench\", __iconNode);\n\nexport { __iconNode, Wrench as default };\n//# sourceMappingURL=wrench.js.map\n","/**\n * @license lucide-react v0.545.0 - ISC\n *\n * This source code is licensed under the ISC license.\n * See the LICENSE file in the root directory of this source tree.\n */\n\nimport createLucideIcon from '../createLucideIcon.js';\n\nconst __iconNode = [\n  [\"path\", { d: \"M18 6 6 18\", key: \"1bl5f8\" }],\n  [\"path\", { d: \"m6 6 12 12\", key: \"d8bk6v\" }]\n];\nconst X = createLucideIcon(\"x\", __iconNode);\n\nexport { __iconNode, X as default };\n//# sourceMappingURL=x.js.map\n","/**\n * @fileoverview Modal Component - Simple Portal-based Modal\n * \n * Simple modal overlay with inline styles - no external dependencies.\n * Used for settings and other dialogs in the vowel client.\n * \n * @module @vowel.to/client/components\n * @author vowel.to\n * @license Proprietary\n */\n\nimport React, { useEffect } from 'react';\nimport { createPortal } from 'react-dom';\nimport { X } from 'lucide-react';\nimport { cn, VOWEL_UI_SCOPE_CLASS } from '../utils';\n\n/**\n * Modal component props\n */\nexport interface ModalProps {\n  /** Whether the modal is open */\n  isOpen: boolean;\n  \n  /** Close handler */\n  onClose: () => void;\n  \n  /** Modal children/content */\n  children: React.ReactNode;\n  \n  /** Custom className for modal content */\n  className?: string;\n  \n  /** Whether to show close button */\n  showCloseButton?: boolean;\n}\n\n/**\n * Modal Component\n * \n * Simple modal with portal rendering and inline styles.\n * \n * @example\n * ```tsx\n * <Modal\n *   isOpen={isOpen}\n *   onClose={() => setIsOpen(false)}\n *   title=\"Settings\"\n * >\n *   <p>Modal content here</p>\n * </Modal>\n * ```\n */\nexport function Modal({\n  isOpen,\n  onClose,\n  children,\n  className = '',\n  showCloseButton = true,\n}: ModalProps) {\n  // Lock body scroll when modal is open\n  useEffect(() => {\n    if (isOpen) {\n      document.body.style.overflow = 'hidden';\n      return () => {\n        document.body.style.overflow = '';\n      };\n    }\n  }, [isOpen]);\n\n  // Handle escape key\n  useEffect(() => {\n    const handleEscape = (e: KeyboardEvent) => {\n      if (e.key === 'Escape' && isOpen) {\n        onClose();\n      }\n    };\n    \n    document.addEventListener('keydown', handleEscape);\n    return () => document.removeEventListener('keydown', handleEscape);\n  }, [isOpen, onClose]);\n\n  if (!isOpen) return null;\n\n  const modalContent = (\n    <div className={cn(VOWEL_UI_SCOPE_CLASS, \"fixed inset-0 z-[999999] flex items-center justify-center p-4\")}>\n      {/* Overlay */}\n      <div\n        onClick={onClose}\n        className=\"fixed inset-0 bg-black/75 dark:bg-black/80 animate-[vowel-fadeIn_0.2s_ease-in-out]\"\n      />\n      \n      {/* Modal Content */}\n      <div\n        onClick={(e) => e.stopPropagation()}\n        className={cn(\n          \"relative w-full max-w-[800px] max-h-[90vh]\",\n          \"bg-white dark:bg-gray-900\",\n          \"rounded-lg shadow-xl\",\n          \"flex flex-col\",\n          \"animate-[vowel-slideIn_0.2s_ease-out]\",\n          className\n        )}\n      >\n        {/* Close button in top right corner */}\n        {showCloseButton && (\n          <button\n            onClick={onClose}\n            className={cn(\n              \"absolute top-4 right-4 z-10\",\n              \"p-2 rounded-md\",\n              \"text-gray-500 dark:text-gray-400\",\n              \"hover:bg-gray-100 dark:hover:bg-gray-800\",\n              \"hover:text-gray-900 dark:hover:text-gray-100\",\n              \"transition-colors\",\n              \"flex items-center justify-center\"\n            )}\n            aria-label=\"Close\"\n          >\n            <X size={20} />\n          </button>\n        )}\n        \n        {/* Body */}\n        <div className=\"flex-1 overflow-y-auto p-6\">\n          {children}\n        </div>\n      </div>\n      \n      {/* Inline styles for animations */}\n      <style>{`\n        @keyframes vowel-fadeIn {\n          from { opacity: 0; }\n          to { opacity: 1; }\n        }\n        \n        @keyframes vowel-slideIn {\n          from {\n            opacity: 0;\n            transform: scale(0.95) translateY(-10px);\n          }\n          to {\n            opacity: 1;\n            transform: scale(1) translateY(0);\n          }\n        }\n      `}</style>\n    </div>\n  );\n\n  // Render in portal\n  return createPortal(modalContent, document.body);\n}\n","/**\n * @fileoverview Vowel Settings Modal Component\n * \n * Settings modal for voice agent configuration with microphone selection.\n * Allows users to select and switch between available microphone devices.\n * \n * This component is self-contained and automatically manages device loading,\n * device switching, and session state. It can work with either:\n * - VowelProvider context (via useVowel hook)\n * - Explicit client prop\n * \n * @module @vowel.to/client/components\n * @author vowel.to\n * @license Proprietary\n */\n\nimport { useState, useEffect, useCallback } from 'react';\nimport { Settings, Mic, Moon, Sun } from 'lucide-react';\nimport { Modal } from './Modal';\nimport { cn } from '../utils';\nimport { useVowel } from './VowelProviderSimple';\nimport { getOperatingSystem } from '../utils/device-detection';\nimport type { Vowel } from '../core/VowelClient';\n\n/**\n * Mock data for Storybook (internal use only)\n */\nexport interface VowelSettingsModalMock {\n  /** Mock devices to display */\n  devices?: MediaDeviceInfo[];\n  /** Mock selected device ID */\n  selectedDeviceId?: string;\n  /** Mock current device label */\n  currentDeviceLabel?: string;\n  /** Mock loading state */\n  isLoading?: boolean;\n}\n\n/**\n * VowelSettingsModal component props\n */\nexport interface VowelSettingsModalProps {\n  /** Whether modal is open */\n  isOpen: boolean;\n  \n  /** Close handler */\n  onClose: () => void;\n  \n  /** Optional Vowel client instance (will use useVowel() hook if not provided) */\n  client?: Vowel | null;\n  \n  /** Custom className */\n  className?: string;\n  \n  /** @internal Mock data for Storybook (not part of public API) */\n  __mock?: VowelSettingsModalMock;\n}\n\n/**\n * VowelSettingsModal Component\n * \n * Self-contained settings modal that automatically manages microphone devices.\n * Works with VowelProvider context or explicit client prop.\n * \n * @example With VowelProvider (automatic)\n * ```tsx\n * <VowelProvider client={vowel}>\n *   <VowelSettingsModal\n *     isOpen={isOpen}\n *     onClose={() => setIsOpen(false)}\n *   />\n * </VowelProvider>\n * ```\n * \n * @example With explicit client prop\n * ```tsx\n * <VowelSettingsModal\n *   isOpen={isOpen}\n *   onClose={() => setIsOpen(false)}\n *   client={vowelClient}\n * />\n * ```\n */\nexport function VowelSettingsModal({\n  isOpen,\n  onClose,\n  client: clientProp,\n  className,\n  __mock,\n}: VowelSettingsModalProps) {\n  // Mock mode - use mock data if provided\n  const isMockMode = !!__mock;\n  \n  // Try to get client from context (skip in mock mode)\n  // Note: useVowel() will throw if not in provider - we'll handle that\n  let contextClient: Vowel | null = null;\n  if (!isMockMode) {\n    try {\n      const context = useVowel();\n      contextClient = context?.client || null;\n    } catch {\n      // Not in VowelProvider - that's okay, will use prop or show error\n      contextClient = null;\n    }\n  }\n  \n  // Use prop if provided, otherwise use context (null in mock mode)\n  const client = isMockMode ? null : (clientProp || contextClient);\n\n  // Internal state management\n  const [devices, setDevices] = useState<MediaDeviceInfo[]>(__mock?.devices || []);\n  const [selectedDeviceId, setSelectedDeviceId] = useState<string | null>(__mock?.selectedDeviceId || null);\n  const [currentDeviceLabel, setCurrentDeviceLabel] = useState<string | null>(__mock?.currentDeviceLabel || null);\n  const [isLoadingDevices, setIsLoadingDevices] = useState(__mock?.isLoading || false);\n  const [isChangingDevice, setIsChangingDevice] = useState(false);\n  const [needsPermission, setNeedsPermission] = useState(false);\n  const [isRequestingPermission, setIsRequestingPermission] = useState(false);\n  const [isDarkMode, setIsDarkMode] = useState(false);\n  \n  const isIOS = getOperatingSystem() === 'ios';\n\n  // Initialize dark mode state from client\n  useEffect(() => {\n    if (!isMockMode && client) {\n      setIsDarkMode(client.getDarkMode());\n    }\n  }, [client, isMockMode]);\n\n  // Auto-load devices when modal opens (skip in mock mode)\n  useEffect(() => {\n    if (isMockMode) {\n      // In mock mode, use mock data\n      if (__mock?.devices) {\n        setDevices(__mock.devices);\n      }\n      if (__mock?.selectedDeviceId) {\n        setSelectedDeviceId(__mock.selectedDeviceId);\n      }\n      if (__mock?.currentDeviceLabel) {\n        setCurrentDeviceLabel(__mock.currentDeviceLabel);\n      }\n      setIsLoadingDevices(__mock?.isLoading || false);\n      return;\n    }\n\n    if (!isOpen || !client) {\n      // Reset state when modal closes\n      if (!isOpen) {\n        setDevices([]);\n        setSelectedDeviceId(null);\n        setCurrentDeviceLabel(null);\n        setIsLoadingDevices(false);\n        setIsChangingDevice(false);\n      }\n      return;\n    }\n\n    const loadDevices = async () => {\n      setIsLoadingDevices(true);\n      setNeedsPermission(false);\n      \n      try {\n        // First check if we have permission (without triggering getUserMedia)\n        const hasPermission = await client.hasMicrophonePermission();\n        \n        // Get devices - don't require permission in useEffect (not a user gesture on iOS)\n        const availableDevices = await client.getAvailableMicrophones(false);\n        \n        // Check if devices have labels (indicates permission was granted)\n        const hasLabels = availableDevices.some(d => d.label && d.label.length > 0);\n        \n        if (availableDevices.length === 0 || (!hasLabels && !hasPermission)) {\n          // No devices or no labels - need to request permission\n          // On iOS, this MUST be done via a button click (user gesture)\n          setNeedsPermission(true);\n          setDevices([]);\n        } else {\n          setDevices(availableDevices);\n          \n          const currentDevice = client.getCurrentMicrophone();\n          if (currentDevice) {\n            setSelectedDeviceId(currentDevice.deviceId);\n            setCurrentDeviceLabel(currentDevice.label || 'Default Microphone');\n          } else if (availableDevices.length > 0) {\n            // No current device, use first available\n            setSelectedDeviceId(availableDevices[0].deviceId);\n            setCurrentDeviceLabel(availableDevices[0].label || 'Default Microphone');\n          }\n        }\n      } catch (error) {\n        console.error('Error loading devices:', error);\n        setNeedsPermission(true);\n      } finally {\n        setIsLoadingDevices(false);\n      }\n    };\n\n    loadDevices();\n  }, [isOpen, client, isMockMode, __mock]);\n\n  // Handler for requesting permission (must be called from user gesture)\n  const handleRequestPermission = useCallback(async () => {\n    if (!client) return;\n    \n    setIsRequestingPermission(true);\n    try {\n      const granted = await client.requestMicrophonePermission();\n      if (granted) {\n        // Permission granted - reload devices with labels\n        const availableDevices = await client.getAvailableMicrophones(false);\n        setDevices(availableDevices);\n        setNeedsPermission(false);\n        \n        if (availableDevices.length > 0) {\n          setSelectedDeviceId(availableDevices[0].deviceId);\n          setCurrentDeviceLabel(availableDevices[0].label || 'Default Microphone');\n        }\n      } else {\n        console.warn('Microphone permission denied');\n      }\n    } catch (error) {\n      console.error('Error requesting permission:', error);\n    } finally {\n      setIsRequestingPermission(false);\n    }\n  }, [client]);\n\n  // Handle dark mode toggle\n  const handleDarkModeToggle = () => {\n    if (!isMockMode && client) {\n      client.toggleDarkMode();\n      setIsDarkMode(client.getDarkMode());\n    } else {\n      // Mock mode - just toggle local state\n      setIsDarkMode(!isDarkMode);\n    }\n  };\n\n  // Handle device change\n  const handleDeviceChange = async (deviceId: string) => {\n    // In mock mode, just update local state\n    if (isMockMode) {\n      setSelectedDeviceId(deviceId);\n      const device = devices.find(d => d.deviceId === deviceId);\n      if (device) {\n        setCurrentDeviceLabel(device.label || 'Unknown Device');\n      }\n      return;\n    }\n\n    if (!client) return;\n\n    setSelectedDeviceId(deviceId);\n    setIsChangingDevice(true);\n\n    try {\n      // Check if session is active - if so, switch device\n      // If not, just set preference for next connection\n      const state = client.state;\n      \n      if (state.isConnected) {\n        // Active session - switch device (will restart audio stream)\n        await client.switchMicrophoneDevice(deviceId);\n      } else {\n        // No active session - just set preference\n        client.setMicrophoneDevice(deviceId);\n      }\n\n      // Update current device label\n      const device = devices.find(d => d.deviceId === deviceId);\n      if (device) {\n        setCurrentDeviceLabel(device.label || 'Unknown Device');\n      }\n    } catch (error) {\n      console.error('Error switching device:', error);\n      // Revert selection on error\n      const currentDevice = client.getCurrentMicrophone();\n      if (currentDevice) {\n        setSelectedDeviceId(currentDevice.deviceId);\n        setCurrentDeviceLabel(currentDevice.label || 'Default Microphone');\n      }\n    } finally {\n      setIsChangingDevice(false);\n    }\n  };\n\n  // Show error if no client available (skip in mock mode)\n  if (!isMockMode && !client) {\n    return (\n      <Modal isOpen={isOpen} onClose={onClose} className={cn('max-w-md', className)}>\n        <div className=\"space-y-4\">\n          <div className=\"flex items-center gap-2 mb-2\">\n            <Settings className=\"w-5 h-5 text-gray-700 dark:text-gray-300\" />\n            <h2 className=\"text-lg font-semibold text-gray-900 dark:text-gray-100\">\n              Settings\n            </h2>\n          </div>\n          <p className=\"text-sm text-red-600 dark:text-red-400\">\n            Vowel client not available. Please ensure VowelProvider is set up correctly or pass a client prop.\n          </p>\n        </div>\n      </Modal>\n    );\n  }\n\n  return (\n    <Modal\n      isOpen={isOpen}\n      onClose={onClose}\n      className={cn('max-w-md', className)}\n    >\n      <div className=\"space-y-4\">\n        {/* Header with Settings icon */}\n        <div className=\"flex items-center gap-2 mb-2\">\n          <Settings className=\"w-5 h-5 text-gray-700 dark:text-gray-300\" />\n          <h2 className=\"text-lg font-semibold text-gray-900 dark:text-gray-100\">\n            Settings\n          </h2>\n        </div>\n\n        {/* Dark Mode Toggle */}\n        <div className=\"space-y-3 pb-4 border-b border-gray-200 dark:border-gray-700\">\n          <label className=\"block text-sm font-medium text-gray-700 dark:text-gray-300\">\n            Appearance\n          </label>\n          <button\n            onClick={handleDarkModeToggle}\n            className={cn(\n              'w-full flex items-center justify-between px-4 py-3',\n              'border border-gray-300 dark:border-gray-600 rounded-md',\n              'bg-white dark:bg-gray-800',\n              'hover:bg-gray-50 dark:hover:bg-gray-700',\n              'transition-colors',\n              'text-sm font-medium text-gray-900 dark:text-gray-100'\n            )}\n          >\n            <div className=\"flex items-center gap-3\">\n              {isDarkMode ? (\n                <Moon className=\"w-4 h-4 text-gray-600 dark:text-gray-400\" />\n              ) : (\n                <Sun className=\"w-4 h-4 text-gray-600 dark:text-gray-400\" />\n              )}\n              <span>Dark Mode</span>\n            </div>\n            <div className={cn(\n              'relative w-11 h-6 rounded-full transition-colors',\n              isDarkMode ? 'bg-blue-600' : 'bg-gray-300'\n            )}>\n              <div className={cn(\n                'absolute top-0.5 left-0.5 w-5 h-5 bg-white rounded-full transition-transform',\n                isDarkMode ? 'translate-x-5' : 'translate-x-0'\n              )} />\n            </div>\n          </button>\n        </div>\n\n        {/* Microphone Selection */}\n        <div className=\"space-y-3\">\n          <label className=\"block text-sm font-medium text-gray-700 dark:text-gray-300\">\n            Microphone\n          </label>\n          \n          {/* Permission request UI - shown when we need microphone permission */}\n          {needsPermission && !isLoadingDevices ? (\n            <div className=\"space-y-3\">\n              <p className=\"text-sm text-gray-600 dark:text-gray-400\">\n                {isIOS \n                  ? \"Tap the button below to allow microphone access. This is required to detect available microphones.\"\n                  : \"Microphone access is required to detect available devices.\"\n                }\n              </p>\n              <button\n                onClick={handleRequestPermission}\n                disabled={isRequestingPermission}\n                className={cn(\n                  'w-full flex items-center justify-center gap-2 px-4 py-2',\n                  'bg-blue-600 dark:bg-blue-500 text-white rounded-md',\n                  'hover:bg-blue-700 dark:hover:bg-blue-600',\n                  'focus:outline-none focus:ring-2 focus:ring-blue-500 focus:ring-offset-2 dark:focus:ring-offset-gray-900',\n                  'text-sm font-medium',\n                  'disabled:opacity-50 disabled:cursor-not-allowed',\n                  'transition-colors'\n                )}\n              >\n                <Mic className=\"w-4 h-4\" />\n                {isRequestingPermission ? 'Requesting access...' : 'Allow Microphone Access'}\n              </button>\n            </div>\n          ) : (\n            <>\n              <select\n                value={selectedDeviceId || ''}\n                onChange={(e) => handleDeviceChange(e.target.value)}\n                disabled={isLoadingDevices || isChangingDevice || devices.length === 0}\n                className={cn(\n                  'w-full px-3 py-2',\n                  'border border-gray-300 dark:border-gray-600 rounded-md',\n                  'bg-white dark:bg-gray-800 text-gray-900 dark:text-gray-100',\n                  'focus:outline-none focus:ring-2 focus:ring-blue-500 dark:focus:ring-blue-400 focus:border-transparent',\n                  'text-sm',\n                  'disabled:opacity-50 disabled:cursor-not-allowed',\n                  'transition-colors'\n                )}\n              >\n                {isLoadingDevices ? (\n                  <option value=\"\">Loading devices...</option>\n                ) : devices.length === 0 ? (\n                  <option value=\"\">No microphones available</option>\n                ) : (\n                  devices.map((device) => (\n                    <option key={device.deviceId} value={device.deviceId}>\n                      {device.label || `Microphone ${device.deviceId.slice(0, 8)}`}\n                    </option>\n                  ))\n                )}\n              </select>\n              \n              {isChangingDevice && (\n                <p className=\"text-sm text-blue-600 dark:text-blue-400 mt-2\">\n                  Switching device...\n                </p>\n              )}\n              \n              {currentDeviceLabel && !isChangingDevice && (\n                <p className=\"text-sm text-gray-600 dark:text-gray-400 mt-2\">\n                  Current: {currentDeviceLabel}\n                </p>\n              )}\n            </>\n          )}\n        </div>\n      </div>\n    </Modal>\n  );\n}\n\n","/**\n * @fileoverview Floating Microphone Button Component\n * \n * A floating microphone button displayed in controlled tabs, showing the current\n * voice session state with animations and allowing users to stop the session.\n * \n * @module @vowel.to/client/components\n * @author vowel.to\n * @license Proprietary\n */\n\nimport { useState } from 'react';\nimport { Mic, MicOff, Loader2, Sparkles, Brain, MessageCircle, Settings, Pause, Wrench, Moon } from 'lucide-react';\nimport { cn, VOWEL_UI_SCOPE_CLASS } from '../utils';\nimport { VowelSettingsModal, type VowelSettingsModalMock } from './VowelSettingsModal';\nimport type { Vowel } from '../core/VowelClient';\n\n/**\n * Voice session state (subset used for UI display)\n */\nexport interface FloatingMicButtonState {\n  /** Whether voice session is connected */\n  isConnected?: boolean;\n  \n  /** Whether voice session is connecting */\n  isConnecting?: boolean;\n  \n  /** Whether voice session is disconnecting */\n  isDisconnecting?: boolean;\n  \n  /** Whether user is speaking */\n  isUserSpeaking?: boolean;\n  \n  /** Whether AI is speaking */\n  isAiSpeaking?: boolean;\n  \n  /** Whether AI is thinking */\n  isAiThinking?: boolean;\n  \n  /** Whether AI is executing a tool */\n  isToolExecuting?: boolean;\n  \n  /** Whether session is hibernated (sleeping) */\n  isHibernated?: boolean;\n  \n  /** Whether session is resuming */\n  isResuming?: boolean;\n  \n  /** Whether session is paused */\n  isPaused?: boolean;\n  \n  /** Whether there is an error */\n  hasError?: boolean;\n}\n\n/**\n * FloatingMicButton component props\n */\nexport interface FloatingMicButtonProps extends FloatingMicButtonState {\n  /** Custom className */\n  className?: string;\n  \n  /** Position (default: bottom-right) */\n  position?: 'bottom-right' | 'bottom-left' | 'top-right' | 'top-left';\n  \n  /** Z-index for positioning */\n  zIndex?: number;\n  \n  /** Click handler */\n  onClick?: () => void;\n  \n  /** Button title/tooltip */\n  title?: string;\n  \n  /** If true, don't apply fixed positioning (for inline use) */\n  inline?: boolean;\n  \n  /** If true, show action icon (what will happen on click) instead of current state */\n  showActionIcon?: boolean;\n  \n  /** If true, show settings button */\n  showSettings?: boolean;\n  \n  /** Settings button click handler (optional - if not provided, modal is managed internally) */\n  onSettingsClick?: () => void;\n  \n  /** Optional Vowel client instance (for settings modal - will use useVowel() hook if not provided) */\n  client?: Vowel | null;\n  \n  /** @internal Mock data for settings modal in Storybook (not part of public API) */\n  __mockSettings?: VowelSettingsModalMock;\n}\n\n/**\n * FloatingMicButton Component\n * \n * Displays a floating microphone button that shows voice session state.\n * \n * @example\n * ```tsx\n * <FloatingMicButton\n *   isConnected={true}\n *   isUserSpeaking={false}\n *   onClick={handleStop}\n * />\n * ```\n */\nexport function FloatingMicButton({\n  isConnected = false,\n  isConnecting = false,\n  isDisconnecting = false,\n  isUserSpeaking = false,\n  isAiSpeaking = false,\n  isAiThinking = false,\n  isToolExecuting = false,\n  isHibernated = false,\n  isResuming = false,\n  isPaused = false,\n  hasError = false,\n  className,\n  position = 'bottom-right',\n  zIndex = 999998,\n  onClick,\n  title = 'Stop voice session & close tab',\n  inline = false,\n  showActionIcon = false,\n  showSettings = false,\n  onSettingsClick,\n  client,\n  __mockSettings,\n}: FloatingMicButtonProps) {\n  // Debug logging for prop changes (helps verify r2wc is passing updates)\n  console.log('[FloatingMicButton] Rendering with props:', {\n    isConnected,\n    isConnecting,\n    isDisconnecting,\n    isUserSpeaking,\n    isAiSpeaking,\n    isAiThinking,\n    isResuming,\n    hasError\n  });\n  \n  // Internal settings modal state (only used if onSettingsClick is not provided)\n  const [isSettingsOpen, setIsSettingsOpen] = useState(false);\n  \n  // Handle settings click - use callback if provided, otherwise manage internally\n  const handleSettingsClick = () => {\n    if (onSettingsClick) {\n      onSettingsClick();\n    } else {\n      setIsSettingsOpen(true);\n    }\n  };\n  \n  // Determine button state and styling\n  const getButtonState = () => {\n    // Error state takes priority over everything\n    if (hasError) return 'error';\n    // Disconnecting state takes priority (show immediately when disconnect starts)\n    if (isDisconnecting) return 'disconnecting';\n    if (isResuming) return 'resuming';\n    if (isConnecting) return 'connecting';\n    if (isPaused) return 'paused';\n    // Hibernation state - show sleeping icon\n    if (isHibernated) return 'hibernated';\n    if (isAiSpeaking) return 'ai-speaking';\n    if (isToolExecuting) return 'tool-executing';\n    if (isAiThinking) return 'ai-thinking';\n    if (isUserSpeaking) return 'user-speaking';\n    if (isConnected) return 'connected';\n    return 'disconnected';\n  };\n\n  const buttonState = getButtonState();\n  \n  // Extra logging for AI speaking state\n  if (isAiSpeaking) {\n    console.log('🔊 [FloatingMicButton] AI IS SPEAKING! Button state:', buttonState);\n    console.log('🔊 [FloatingMicButton] Should show purple background and pulse');\n  }\n\n  // Position classes\n  const positionClasses = {\n    'bottom-right': 'bottom-6 right-6',\n    'bottom-left': 'bottom-6 left-6',\n    'top-right': 'top-6 right-6',\n    'top-left': 'top-6 left-6',\n  };\n\n  // Get inline background style for all states (hardcoded gradients)\n  const getBackgroundStyle = () => {\n    switch (buttonState) {\n      case 'error':\n        return {\n          background: 'linear-gradient(135deg, #ef4444 0%, #dc2626 100%)'\n        };\n      case 'disconnecting':\n        return {\n          background: 'linear-gradient(135deg, #4a5568 0%, #1a202c 100%)' // Same as disconnected (gray)\n        };\n      case 'resuming':\n        return {\n          background: 'linear-gradient(135deg, #3b82f6 0%, #6366f1 50%, #ec4899 100%)',\n          backgroundSize: '400% 400%'\n        };\n      case 'connecting':\n        return {\n          background: 'linear-gradient(135deg, #fbbf24 0%, #f97316 100%)'\n        };\n      case 'paused':\n        return {\n          background: 'linear-gradient(135deg, #64748b 0%, #475569 100%)'\n        };\n      case 'hibernated':\n        return {\n          background: 'linear-gradient(135deg, #4c51bf 0%, #6b46c1 50%, #805ad5 100%)' // Deep purple/blue for sleeping\n        };\n      case 'user-speaking':\n        return {\n          background: 'linear-gradient(135deg, #3b82f6 0%, #2563eb 100%)'\n        };\n      case 'tool-executing':\n        return {\n          background: 'linear-gradient(135deg, #f59e0b 0%, #d97706 100%)' // Amber - slightly different shade\n        };\n      case 'ai-thinking':\n        return {\n          background: 'linear-gradient(135deg, #eab308 0%, #ca8a04 100%)' // Yellow\n        };\n      case 'ai-speaking':\n        return {\n          background: 'linear-gradient(135deg, #a855f7 0%, #9333ea 100%)'\n        };\n      case 'connected':\n        return {\n          background: 'linear-gradient(135deg, #22c55e 0%, #16a34a 100%)'\n        };\n      default: // disconnected\n        return {\n          background: 'linear-gradient(135deg, #4a5568 0%, #1a202c 100%)'\n        };\n    }\n  };\n\n  // Additional classes for animations (pulse, gradient shift)\n  const getAnimationClass = () => {\n    switch (buttonState) {\n      case 'error':\n        return 'animate-pulse';\n      case 'resuming':\n        return 'vowel-animate-gradient-shift';\n      case 'hibernated':\n        return 'animate-pulse';\n      case 'user-speaking':\n      case 'ai-speaking':\n        return 'animate-pulse';\n      default:\n        return '';\n    }\n  };\n\n  // Border color based on state\n  const getBorderClass = () => {\n    switch (buttonState) {\n      case 'error':\n        return 'border-red-300/50';\n      case 'disconnecting':\n        return 'border-white/50'; // Same as disconnected\n      case 'resuming':\n        return 'border-blue-300/50';\n      case 'connecting':\n        return 'border-yellow-300/50';\n      case 'paused':\n        return 'border-slate-400/50';\n      case 'hibernated':\n        return 'border-indigo-300/50';\n      case 'user-speaking':\n        return 'border-blue-300/50';\n      case 'tool-executing':\n        return 'border-amber-300/50';\n      case 'ai-thinking':\n        return 'border-yellow-300/50';\n      case 'ai-speaking':\n        return 'border-purple-300/50';\n      case 'connected':\n        return 'border-green-400/50';\n      default:\n        return 'border-white/50';\n    }\n  };\n\n  // Shadow based on state\n  const getShadowClass = () => {\n    switch (buttonState) {\n      case 'error':\n        return 'shadow-[0_8px_24px_rgba(239,68,68,0.5)]';\n      case 'disconnecting':\n        return 'shadow-[0_8px_24px_rgba(0,0,0,0.3)]'; // Same as disconnected\n      case 'resuming':\n      case 'user-speaking':\n        return 'shadow-[0_8px_24px_rgba(59,130,246,0.5)]';\n      case 'connecting':\n      case 'ai-thinking':\n        return 'shadow-[0_8px_24px_rgba(234,179,8,0.5)]';\n      case 'tool-executing':\n        return 'shadow-[0_8px_24px_rgba(245,158,11,0.5)]'; // Amber shadow\n      case 'paused':\n        return 'shadow-[0_8px_24px_rgba(100,116,139,0.3)]';\n      case 'hibernated':\n        return 'shadow-[0_8px_24px_rgba(107,70,193,0.4)]';\n      case 'ai-speaking':\n        return 'shadow-[0_8px_24px_rgba(168,85,247,0.5)]';\n      case 'connected':\n        return 'shadow-[0_8px_24px_rgba(34,197,94,0.3)]';\n      default:\n        return 'shadow-[0_8px_24px_rgba(0,0,0,0.3)]';\n    }\n  };\n\n  // Icon to show based on state\n  const getIcon = () => {\n    // Error state: MicOff icon (same as disconnected)\n    if (hasError) {\n      return <MicOff className=\"w-8 h-8\" />;\n    }\n    \n    // Disconnecting state: Spinner (same as connecting)\n    if (isDisconnecting) {\n      return <Loader2 className=\"w-8 h-8 animate-spin\" />;\n    }\n    \n    // Loading states\n    if (isConnecting || isResuming) {\n      return <Loader2 className=\"w-8 h-8 animate-spin\" />;\n    }\n    \n    // Paused state: Pause icon\n    if (isPaused) {\n      return <Pause className=\"w-8 h-8\" />;\n    }\n    \n    // Hibernated state: Moon icon (sleeping)\n    if (isHibernated) {\n      return <Moon className=\"w-8 h-8\" />;\n    }\n    \n    // AI speaking: Sparkles/stars icon\n    if (isAiSpeaking) {\n      return <Sparkles className=\"w-8 h-8\" />;\n    }\n    \n    // Tool executing: Wrench icon (different shade of yellow)\n    if (isToolExecuting) {\n      return <Wrench className=\"w-8 h-8\" />;\n    }\n    \n    // AI thinking: Brain icon\n    if (isAiThinking) {\n      return <Brain className=\"w-8 h-8\" />;\n    }\n    \n    // User speaking: MessageCircle (speaking head)\n    if (isUserSpeaking) {\n      return <MessageCircle className=\"w-8 h-8\" />;\n    }\n    \n    // Action icon mode: Show what will happen when clicked\n    // - When connected, show Mic (currently on)\n    // - When disconnected, show MicOff (currently off)\n    if (showActionIcon) {\n      return isConnected \n        ? <Mic className=\"w-8 h-8\" />\n        : <MicOff className=\"w-8 h-8\" />;\n    }\n    \n    // Current state mode: Show current state\n    // - When connected, show Mic (currently on)\n    // - When disconnected, show MicOff (currently off)\n    return isConnected\n      ? <Mic className=\"w-8 h-8\" />\n      : <MicOff className=\"w-8 h-8\" />;\n  };\n\n  // Show ping effect for speaking states and error state\n  const showPing = isUserSpeaking || isAiSpeaking || hasError;\n  \n  // Hover state for settings button\n  const [isHovered, setIsHovered] = useState(false);\n\n  return (\n    <>\n      {/* Custom animations */}\n      <style>\n        {`\n          @keyframes vowel-gradient-shift {\n            0% { background-position: 0% 50%; }\n            50% { background-position: 100% 50%; }\n            100% { background-position: 0% 50%; }\n          }\n          \n          @keyframes vowel-ping {\n            75%, 100% {\n              transform: scale(2);\n              opacity: 0;\n            }\n          }\n          \n          .vowel-animate-gradient-shift {\n            animation: vowel-gradient-shift 3s ease infinite;\n          }\n          \n          .vowel-animate-ping-effect {\n            animation: vowel-ping 1s cubic-bezier(0, 0, 0.2, 1) infinite;\n          }\n          \n          /* Show settings button on hover */\n          .vowel-mic-button-container:hover .vowel-settings-button {\n            opacity: 1 !important;\n            pointer-events: auto !important;\n          }\n          \n          /* Also show when hovering over the settings button itself */\n          .vowel-settings-button:hover {\n            opacity: 1 !important;\n            pointer-events: auto !important;\n          }\n        `}\n      </style>\n\n      <div\n        className={cn(\n          VOWEL_UI_SCOPE_CLASS,\n          !inline && \"fixed\",\n          !inline && positionClasses[position],\n          className\n        )}\n        style={!inline ? { zIndex } : undefined}\n      >\n        {/* Container for button and settings */}\n        <div \n          className=\"vowel-mic-button-container\" \n          style={{ padding: '15px', position: 'relative' }}\n          onMouseEnter={() => setIsHovered(true)}\n          onMouseLeave={() => setIsHovered(false)}\n        >\n          {/* Settings button - top right corner (shown on hover) */}\n          {showSettings && (\n            <button\n              onClick={(e) => {\n                e.stopPropagation();\n                handleSettingsClick();\n              }}\n              className={cn(\n                \"vowel-settings-button absolute top-0 right-0\",\n                \"w-[37.5px] h-[37.5px] rounded-lg\",\n                \"flex items-center justify-center\",\n                \"bg-white dark:bg-gray-800\",\n                \"border-[1.5px] border-blue-400 dark:border-blue-500\",\n                \"shadow-sm\",\n                \"text-blue-600 dark:text-blue-400\",\n                \"cursor-pointer\",\n                \"transition-all duration-200\",\n                \"z-10\",\n                \"hover:bg-blue-50 dark:hover:bg-gray-700\",\n                isHovered ? \"opacity-100 pointer-events-auto\" : \"opacity-0 pointer-events-none\"\n              )}\n              title=\"Settings\"\n              aria-label=\"Settings\"\n            >\n              <Settings className=\"w-[17.5px] h-[17.5px]\" />\n            </button>\n          )}\n          \n          {/* Main microphone button */}\n          <button\n            onClick={onClick}\n            title={title}\n            aria-label={title}\n            className={cn(\n              \"relative w-20 h-20 rounded-2xl border-2\",\n              \"flex items-center justify-center\",\n              \"text-white cursor-pointer\",\n              \"transition-all duration-300 ease-in-out\",\n              \"hover:scale-105 hover:shadow-[0_12px_32px_rgba(0,0,0,0.4)]\",\n              \"active:scale-95\",\n              \"overflow-hidden backdrop-blur-sm\",\n              getAnimationClass(),\n              getBorderClass(),\n              getShadowClass()\n            )}\n            style={getBackgroundStyle()}\n          >\n          {/* Ping effect for speaking states */}\n          {showPing && (\n            <span\n              className=\"absolute inset-0 rounded-2xl bg-current opacity-40 vowel-animate-ping-effect pointer-events-none\"\n            />\n          )}\n\n          {/* Gradient overlay */}\n          <div\n            className={cn(\n              \"absolute inset-0 rounded-2xl\",\n              \"bg-gradient-to-br from-white/10 to-transparent\",\n              \"transition-opacity duration-300 pointer-events-none\",\n              \"group-hover:opacity-80\"\n            )}\n          />\n\n          {/* Icon */}\n          <div className=\"relative z-10\">\n            {getIcon()}\n          </div>\n        </button>\n        </div>\n      </div>\n      \n      {/* Settings Modal - only show if managing internally (no onSettingsClick provided) */}\n      {showSettings && !onSettingsClick && (\n        <VowelSettingsModal\n          isOpen={isSettingsOpen}\n          onClose={() => setIsSettingsOpen(false)}\n          client={client}\n          __mock={__mockSettings}\n        />\n      )}\n    </>\n  );\n}\n"],"names":["createContext","useState","useEffect","useContext","useRef","useCallback","useMemo","jsx","forwardRef","createElement","__iconNode","jsxs","cn","VOWEL_UI_SCOPE_CLASS","createPortal","getOperatingSystem","Fragment","Loader2"],"mappings":";;;;;;;;AA2CA,MAAM,qBAAA,GAAwBA,oBAAgD,IAAI,CAAA;AAiC3E,SAAS,sBAAA,CAAuB;AAAA,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