import { ReactElement, ReactNode } from 'react'; import { MenuProps } from '../../../../../../../../../src/components/Menu'; import { IconNamesType } from '../../../../../../../../../src/utils'; export interface TabProps extends React.HTMLAttributes { id?: string; key?: string; children: ReactNode; disabled?: boolean; icon?: IconNamesType; } export interface TabLinkProps extends React.HTMLAttributes { children: ReactNode; disabled?: boolean; href: string; icon?: IconNamesType; id?: string; } export interface ClosableTabProps extends Omit { onClose?: (index: number) => void; } export interface TabListProps extends React.HTMLAttributes { children: ReactElement[]; } export interface TabPanelProps extends React.HTMLAttributes { children: ReactNode; } export interface TabPanelsProps { children: ReactElement[]; } interface Oritentation { orientation?: "horizontal" | "vertical"; } interface CommonTabsProps extends React.HTMLAttributes { defaultIndex?: number; index?: number; initialFocus?: boolean; children: ReactElement | [ReactElement, ReactElement]; onTabChange?: (index: number) => void; onTabPanelChange?: (index: number) => void; } export interface HorizontalTabsProps extends CommonTabsProps, Oritentation { orientation?: "horizontal"; hasCarousel?: boolean; carouselDropdown?: ReactElement; leftCarouselButtonAriaLabel?: string; rightCarouselButtonAriaLabel?: string; } export interface VerticalTabsProps extends CommonTabsProps, Oritentation { orientation: "vertical"; scrollable?: boolean; } export type TabsProps = HorizontalTabsProps | VerticalTabsProps; export {};