import { type SearchBox, type StandaloneSearchBox } from '@coveo/headless/commerce';
import { type CSSResultGroup, LitElement } from 'lit';
import type { InitializableComponent } from '../../../decorators/types';
import { AriaLiveRegionController } from '../../../utils/accessibility-utils';
import type { CommerceBindings } from '../atomic-commerce-interface/atomic-commerce-interface';
import '../atomic-commerce-search-box-instant-products/atomic-commerce-search-box-instant-products';
import '../atomic-commerce-search-box-query-suggestions/atomic-commerce-search-box-query-suggestions';
import '../atomic-commerce-search-box-recent-queries/atomic-commerce-search-box-recent-queries';
import '@coveo/atomic-legacy/atomic-suggestion-renderer';
/**
 * The `atomic-commerce-search-box` component enables users to perform product searches with built-in query suggestions and optional redirection to a search page.
 *
 * @slot default - The default slot where you can add child components to the search box.
 *
 * @part wrapper - The search box wrapper.
 * @part input - The search box input.
 * @part loading - The search box loading animation.
 * @part clear-button - The button to clear the search box of input.
 * @part clear-icon - The clear button's icon.
 * @part submit-button - The search box submit button.
 * @part submit-icon - The search box submit button's icon.
 * @part suggestions - A list of suggested query corrections on each panel.
 * @part suggestions-left - A list of suggested query corrections on the left panel.
 * @part suggestions-right - A list of suggested query corrections on the right panel.
 * @part suggestions-wrapper - The wrapper that contains suggestion panels.
 * @part suggestions-single-list - The wrapper that contains 1 suggestion list.
 * @part suggestions-double-list - The wrapper that contains 2 suggestion lists.
 * @part suggestion - A suggested query correction.
 * @part active-suggestion - The currently active suggestion.
 * @part suggestion-divider - An item in the list that separates groups of suggestions.
 * @part suggestion-with-query - An item in the list that will update the search box query.
 *
 * @part query-suggestion-item - A suggestion from the `atomic-commerce-search-box-query-suggestions` component.
 * @part query-suggestion-content - The contents of a suggestion from the `atomic-commerce-search-box-query-suggestions` component.
 * @part query-suggestion-icon - The icon of a suggestion from the `atomic-commerce-search-box-query-suggestions` component.
 * @part query-suggestion-text - The text of a suggestion from the `atomic-commerce-search-box-query-suggestions` component.
 *
 * @part recent-query-item - A suggestion from the `atomic-commerce-search-box-recent-queries` component.
 * @part recent-query-content - The contents of a suggestion from the `atomic-commerce-search-box-recent-queries` component.
 * @part recent-query-icon - The icon of a suggestion from the `atomic-commerce-search-box-recent-queries` component.
 * @part recent-query-text - The text of a suggestion from the `atomic-commerce-search-box-recent-queries` component.
 * @part recent-query-text-highlight - The highlighted portion of the text of a suggestion from the `atomic-commerce-search-box-recent-queries` component.
 * @part recent-query-title-item - The clear button above suggestions from the `atomic-commerce-search-box-recent-queries` component.
 * @part recent-query-title-content - The contents of the clear button above suggestions from the `atomic-commerce-search-box-recent-queries` component.
 * @part recent-query-title - The "recent searches" text of the clear button above suggestions from the `atomic-commerce-search-box-recent-queries` component.
 * @part recent-query-clear - The "clear" text of the clear button above suggestions from the `atomic-commerce-search-box-recent-queries` component.
 *
 * @part instant-results-item - An instant product rendered by an `atomic-commerce-search-box-instant-products` component.
 * @part instant-results-show-all - The clickable suggestion to show all items for the current instant product search rendered by an `atomic-commerce-search-box-instant-products` component.
 * @part instant-results-show-all-button - The button inside the clickable suggestion from the `atomic-commerce-search-box-instant-products` component.
 *
 * @event redirect - Event that is emitted when a standalone search box redirection is triggered. By default, the search box will directly change the URL and redirect accordingly, so if you want to handle the redirection differently, use this event.
 */
export declare class AtomicCommerceSearchBox extends LitElement implements InitializableComponent<CommerceBindings> {
    static shadowRootOptions: {
        delegatesFocus: boolean;
        clonable?: boolean;
        customElementRegistry?: CustomElementRegistry | null;
        mode: ShadowRootMode;
        serializable?: boolean;
        slotAssignment?: SlotAssignmentMode;
    };
    static styles: CSSResultGroup;
    bindings: CommerceBindings;
    error: Error;
    isExpanded: boolean;
    private searchBoxState;
    private textAreaRef;
    private searchBoxSuggestionEventsQueue;
    private suggestionManager;
    searchBox: SearchBox | StandaloneSearchBox;
    protected searchBoxAriaMessage: AriaLiveRegionController;
    protected suggestionsAriaMessage: AriaLiveRegionController;
    /**
     * The amount of queries displayed when the user interacts with the search box.
     * By default, a mix of query suggestions and recent queries will be shown.
     * You can configure those settings using the following components as children:
     *  - atomic-commerce-search-box-query-suggestions
     *  - atomic-commerce-search-box-recent-queries
     */
    numberOfQueries: number;
    /**
     * Defining this option makes the search box standalone (see [Use a
     * Standalone Search Box](https://docs.coveo.com/en/atomic/latest/usage/ssb/)).
     *
     * This option defines the default URL the user should be redirected to, when a query is submitted.
     * If a query pipeline redirect is triggered, it will redirect to that URL instead
     * (see [query pipeline triggers](https://docs.coveo.com/en/1458)).
     */
    redirectionUrl?: string;
    /**
     * The timeout for suggestion queries, in milliseconds.
     * If a suggestion query times out, the suggestions from that particular query won't be shown.
     */
    suggestionTimeout: number;
    /**
     * The delay for suggestion queries on input, in milliseconds.
     *
     * The suggestion request will be delayed until the end user stops typing for at least the specified amount of time.
     *
     * This delay is used to avoid sending too many requests to the Coveo Platform when the user is typing, as well as reducing potential input lag on low end devices.
     * A higher delay will reduce input lag, at the cost of suggestions freshness.
     */
    suggestionDelay: number;
    /**
     * Whether to prevent the user from triggering searches and query suggestions from the component.
     * Perfect for use cases where you need to disable the search conditionally.
     * For the specific case when you need to disable the search based on the length of the query, refer to {@link minimumQueryLength}.
     */
    disableSearch: boolean;
    /**
     * The minimum query length required to enable search.
     * For example, to disable the search for empty queries, set this to `1`.
     */
    minimumQueryLength: number;
    /**
     * Whether to clear all active query filters when the end user submits a new query from the search box.
     * Setting this option to "false" is not recommended and can lead to an increasing number of queries returning no products.
     */
    clearFilters: boolean;
    connectedCallback(): void;
    willUpdate(): void;
    initialize(): void;
    private initializeSearchboxController;
    private initializeSuggestionManager;
    watchRedirectionUrl(): void;
    private isStandaloneSearchBox;
    private updateBreakpoints;
    private get isSearchDisabledForEndUser();
    private get textAreaLabel();
    private get suggestionBindings();
    private get partialSuggestionBindings();
    private get searchBoxOptions();
    private registerNewSearchBoxController;
    private registerSearchboxSuggestionEvents;
    private onInput;
    private onFocus;
    private onSubmit;
    private onKeyDown;
    private triggerTextAreaChange;
    private announceNewActiveSuggestionToScreenReader;
    private announceNewSuggestionsToScreenReader;
    private updateQueryWithoutQuerySuggestionTrigger;
    private renderAbsolutePositionSpacer;
    private renderTextBox;
    private renderSuggestions;
    private renderPanel;
    private renderSuggestion;
    private renderSlotContent;
    render(): import("lit-html").TemplateResult<1>;
    private announceClearSearchBoxToScreenReader;
}
declare global {
    interface HTMLElementTagNameMap {
        'atomic-commerce-search-box': AtomicCommerceSearchBox;
    }
}
