/**
 * Saved Searches & Smart Folders
 *
 * Service for managing saved searches and smart folders that
 * automatically group plugins based on dynamic queries.
 *
 * @since v1.68.0
 */
import type { SearchResultType } from './search-types.js';
/**
 * A saved search definition
 */
export interface SavedSearch {
    /** Unique identifier */
    id: string;
    /** Display name */
    name: string;
    /** Optional description */
    description?: string;
    /** The search query string */
    query: string;
    /** Icon for display */
    icon?: string;
    /** Creation timestamp */
    createdAt: number;
    /** Last used timestamp */
    lastUsedAt?: number;
    /** Usage count */
    useCount: number;
    /** Whether this is a smart folder (auto-updating) */
    isSmartFolder: boolean;
    /** Scopes to search */
    scopes?: SearchResultType[];
    /** Color for UI */
    color?: string;
    /** Sort order for display */
    sortOrder?: number;
    /** Whether pinned to top */
    pinned?: boolean;
}
/**
 * Smart folder configuration
 */
export interface SmartFolderConfig {
    /** Auto-refresh interval in ms (0 = manual only) */
    refreshInterval: number;
    /** Maximum items to show */
    maxItems: number;
    /** Show count badge */
    showCount: boolean;
    /** Notification on new items */
    notifyOnNew: boolean;
}
/**
 * Default smart folder config
 */
export declare const DEFAULT_SMART_FOLDER_CONFIG: SmartFolderConfig;
/**
 * Built-in saved searches
 */
export declare const BUILTIN_SEARCHES: SavedSearch[];
/**
 * Saved searches service
 */
export declare class SavedSearchesService {
    private searches;
    private smartFolderConfigs;
    constructor();
    /**
     * Get all saved searches
     */
    getAll(): SavedSearch[];
    /**
     * Get smart folders only
     */
    getSmartFolders(): SavedSearch[];
    /**
     * Get regular saved searches only
     */
    getSavedSearches(): SavedSearch[];
    /**
     * Get a saved search by ID
     */
    get(id: string): SavedSearch | undefined;
    /**
     * Create a new saved search
     */
    create(data: Omit<SavedSearch, 'id' | 'createdAt' | 'useCount'>): SavedSearch;
    /**
     * Update a saved search
     */
    update(id: string, updates: Partial<Omit<SavedSearch, 'id' | 'createdAt'>>): SavedSearch | undefined;
    /**
     * Delete a saved search
     */
    delete(id: string): boolean;
    /**
     * Record usage of a saved search
     */
    recordUsage(id: string): void;
    /**
     * Save current search as new saved search
     */
    saveCurrentSearch(query: string, name: string, options?: {
        description?: string;
        icon?: string;
        isSmartFolder?: boolean;
        scopes?: SearchResultType[];
    }): SavedSearch;
    /**
     * Pin/unpin a saved search
     */
    togglePin(id: string): boolean;
    /**
     * Get smart folder config
     */
    getSmartFolderConfig(id: string): SmartFolderConfig;
    /**
     * Set smart folder config
     */
    setSmartFolderConfig(id: string, config: Partial<SmartFolderConfig>): void;
    /**
     * Validate a search query
     */
    validateQuery(query: string): {
        valid: boolean;
        errors: string[];
    };
    /**
     * Search saved searches by name
     */
    search(query: string): SavedSearch[];
    /**
     * Get recently used searches
     */
    getRecentlyUsed(limit?: number): SavedSearch[];
    /**
     * Get frequently used searches
     */
    getFrequentlyUsed(limit?: number): SavedSearch[];
    /**
     * Export searches to JSON
     */
    export(): string;
    /**
     * Import searches from JSON
     */
    import(json: string): number;
    /**
     * Clear all custom searches (keeps built-ins)
     */
    clearCustom(): number;
    /**
     * Get count of searches
     */
    count(): {
        total: number;
        custom: number;
        builtin: number;
    };
}
/**
 * Get the global saved searches service
 */
export declare function getSavedSearchesService(): SavedSearchesService;
/**
 * Reset the saved searches service
 */
export declare function resetSavedSearchesService(): void;
//# sourceMappingURL=saved-searches.d.ts.map