import type { CollectionStore, CollectionStoreItem } from "../collection/collection-store.js";
import type { CompositeStoreFunctions, CompositeStoreItem, CompositeStoreOptions, CompositeStoreState } from "../composite/composite-store.js";
import type { Store, StoreOptions, StoreProps } from "../utils/store.js";
import type { SetState } from "../utils/types.js";
type Item = CompositeStoreItem & {
    dimmed?: boolean;
};
type Panel = CollectionStoreItem & {
    tabId?: string | null;
};
export declare function createTabStore(props?: TabStoreProps): TabStore;
export type TabStoreItem = Item;
export type TabStorePanel = Panel;
export interface TabStoreState extends CompositeStoreState<Item> {
    /**
     * @default "horizontal"
     */
    orientation: CompositeStoreState<Item>["orientation"];
    /**
     * @default true
     */
    focusLoop: CompositeStoreState<Item>["focusLoop"];
    /**
     * The id of the tab whose panel is currently visible. If it's `undefined`, it
     * will be automatically set to the first enabled tab.
     *
     * Live examples:
     * - [Tab with React Router](https://ariakit.org/examples/tab-react-router)
     */
    selectedId: TabStoreState["activeId"];
    /**
     * Whether the tab should be selected when it receives focus. If it's set to
     * `false`, the tab will be selected only when it's clicked.
     *
     * Live examples:
     * - [Tab with React Router](https://ariakit.org/examples/tab-react-router)
     * @default true
     */
    selectOnMove?: boolean;
}
export interface TabStoreFunctions extends CompositeStoreFunctions<Item> {
    /**
     * Sets the `selectedId` state without moving focus. If you want to move focus,
     * use the `select` function instead.
     *
     * Live examples:
     * - [Tab with React Router](https://ariakit.org/examples/tab-react-router)
     * @example
     * // Selects the tab with id "tab-1"
     * store.setSelectedId("tab-1");
     * // Toggles between "tab-1" and "tab-2"
     * store.setSelectedId((id) => id === "tab-1" ? "tab-2" : "tab-1"));
     * // Selects the first tab
     * store.setSelectedId(store.first());
     * // Selects the next tab
     * store.setSelectedId(store.next());
     */
    setSelectedId: SetState<TabStoreState["selectedId"]>;
    /**
     * A collection store containing the tab panels.
     */
    panels: CollectionStore<Panel>;
    /**
     * Selects the tab for the given id and moves focus to it. If you want to set
     * the `selectedId` state without moving focus, use the `setSelectedId`
     * function instead.
     * @param id The id of the tab to select.
     * @example
     * // Selects the tab with id "tab-1"
     * store.select("tab-1");
     * // Selects the first tab
     * store.select(store.first());
     * // Selects the next tab
     * store.select(store.next());
     */
    select: TabStore["move"];
}
export interface TabStoreOptions extends StoreOptions<TabStoreState, "orientation" | "focusLoop" | "selectedId" | "selectOnMove">, CompositeStoreOptions<Item> {
    /**
     * The id of the tab whose panel is currently visible. If it's `undefined`, it
     * will be automatically set to the first enabled tab.
     */
    defaultSelectedId?: TabStoreState["selectedId"];
}
export type TabStoreProps = TabStoreOptions & StoreProps<TabStoreState>;
export type TabStore = TabStoreFunctions & Store<TabStoreState>;
export {};
