/**
 * Local Storage Utilities
 * Handles conversation persistence in browser localStorage
 * Supports multiple conversations per widget with history
 */
import { ConversationMessage } from '../types';
export interface StoredConversation {
    conversationId: string;
    sessionId?: string;
    messages: ConversationMessage[];
    lastUpdated: string;
}
export interface ConversationHistoryEntry {
    id: string;
    preview: string;
    lastUpdated: string;
    messageCount: number;
}
export interface WidgetStorage {
    activeConversationId: string | null;
    conversations: Record<string, StoredConversation>;
    history: ConversationHistoryEntry[];
}
/**
 * Save conversation to localStorage (updates both conversation and history)
 */
export declare function saveConversation(widgetId: string, conversationId: string, messages: ConversationMessage[]): void;
/**
 * Load active conversation from localStorage (legacy compatibility)
 */
export declare function loadConversation(widgetId: string): StoredConversation | null;
/**
 * Load a specific conversation by ID
 */
export declare function loadConversationById(widgetId: string, conversationId: string): StoredConversation | null;
/**
 * Get conversation history list
 */
export declare function getConversationHistory(widgetId: string): ConversationHistoryEntry[];
/**
 * Set active conversation
 */
export declare function setActiveConversation(widgetId: string, conversationId: string | null): void;
/**
 * Clear current conversation (start fresh, but keep history)
 */
export declare function clearConversation(widgetId: string): void;
/**
 * Delete a specific conversation by ID
 */
export declare function deleteConversation(widgetId: string, conversationId: string): void;
/**
 * Clear all conversations for a widget
 */
export declare function clearAllConversations(widgetId: string): void;
/**
 * Check if localStorage is available
 */
export declare function isStorageAvailable(): boolean;
//# sourceMappingURL=storage.d.ts.map