import type { GetSearchSuggestionsQuery } from '@farfetch/blackout-client'; import type { StoreState } from '../../types/index.js'; /** * Retrieves the error thrown by current search term. * * @example * ``` * import { getSearchSuggestionsError } from '@farfetch/blackout-redux'; * * const mapStateToProps = state => ({ * error: getSearchSuggestionsError(state, query) * }); * * ``` * * @param state - Application state. * @param query - Get search suggestions query. * * @returns Search error. */ export declare const getSearchSuggestionsError: (state: StoreState, query: GetSearchSuggestionsQuery) => import("@farfetch/blackout-client").BlackoutError | null | undefined; /** * Retrieves the loading condition from current search term. * * @example * ``` * import { areSearchSuggestionsLoading } from '@farfetch/blackout-redux'; * * const mapStateToProps = state => ({ * isLoading: areSearchSuggestionsLoading(state, query) * }); * * ``` * * @param state - Application state. * @param query - Get search suggestions query. * * @returns Whether a search term response is loading or not. */ export declare const areSearchSuggestionsLoading: (state: StoreState, query: GetSearchSuggestionsQuery) => boolean | undefined; /** * Retrieves the suggestions of a specific search. * * @example * ``` * import { getSearchSuggestionsResult } from '@farfetch/blackout-redux'; * * const mapStateToProps = state => ({ * suggestions: getSearchSuggestionsResult(state, query) * }); * * ``` * * @param state - Application state. * @param query - Get search suggestions query. * * @returns Search suggestions. */ export declare const getSearchSuggestionsResult: (state: StoreState, query: GetSearchSuggestionsQuery) => import("@farfetch/blackout-client").SearchSuggestion[] | null | undefined; /** * Retrieves if the search suggestions has been fetched. * * Will return true if a fetch request * has been made that returned either successfully or failed * and false otherwise. * * @example * ``` * import { areSearchSuggestionsFetched } from '@farfetch/blackout-redux'; * * const mapStateToProps = state => ({ * isFetched: areSearchSuggestionsFetched(state) * }); * ``` * @param state - Application state. * @param query - Get search suggestions query. * * @returns isFetched status of the search suggestions. */ export declare const areSearchSuggestionsFetched: (state: StoreState, query: GetSearchSuggestionsQuery) => boolean;