Files
NapCatQQ/.pnpm-store/v3/files/53/2d3c51dc18a504c6c402491e0128707ea304bb417e0879151cfa26dcbdbc96a90d27b11af072cd3c5144700e951834aed99562dcfc2e1a3e36336f6b2b16ba
T
TanTan e311ca3275
Build NapCat Artifacts / Type Check & Test (push) Waiting to run
docs: 仓库链接指向本镜像仓库
2026-11-13 09:25:58 +08:00

43 lines
1.9 KiB
Plaintext

import { AriaTabProps, AriaTabPanelProps, AriaTabListProps } from "@react-types/tabs";
import { DOMAttributes, FocusableElement, RefObject } from "@react-types/shared";
import { TabListState } from "@react-stately/tabs";
export interface TabAria {
/** Props for the tab element. */
tabProps: DOMAttributes;
/** Whether the tab is currently selected. */
isSelected: boolean;
/** Whether the tab is disabled. */
isDisabled: boolean;
/** Whether the tab is currently in a pressed state. */
isPressed: boolean;
}
/**
* Provides the behavior and accessibility implementation for a tab.
* When selected, the associated tab panel is shown.
*/
export function useTab<T>(props: AriaTabProps, state: TabListState<T>, ref: RefObject<FocusableElement | null>): TabAria;
export interface TabPanelAria {
/** Props for the tab panel element. */
tabPanelProps: DOMAttributes;
}
/**
* Provides the behavior and accessibility implementation for a tab panel. A tab panel is a container for
* the contents of a tab, and is shown when the tab is selected.
*/
export function useTabPanel<T>(props: AriaTabPanelProps, state: TabListState<T> | null, ref: RefObject<Element | null>): TabPanelAria;
export interface AriaTabListOptions<T> extends Omit<AriaTabListProps<T>, 'children'> {
}
export interface TabListAria {
/** Props for the tablist container. */
tabListProps: DOMAttributes;
}
/**
* Provides the behavior and accessibility implementation for a tab list.
* Tabs organize content into multiple sections and allow users to navigate between them.
*/
export function useTabList<T>(props: AriaTabListOptions<T>, state: TabListState<T>, ref: RefObject<HTMLElement | null>): TabListAria;
export type { AriaTabListProps, AriaTabPanelProps, AriaTabProps } from '@react-types/tabs';
export type { Orientation } from '@react-types/shared';
//# sourceMappingURL=types.d.ts.map