import * as React from 'react'; import { OverrideProps } from '@mui/types'; import { CreateSlotsAndSlotProps, SlotProps } from '../../types/slot'; import { SxProps } from '../../types/theme'; export interface TabSlots { /** * The component that renders the root. * @default 'button' */ root?: React.ElementType; } export type TabSlotsAndSlotProps = CreateSlotsAndSlotProps; }>; export interface TabOwnProps { /** * Icon to display in the tab. */ icon?: React.ReactNode; /** * Icon position relative to the label * @default 'side' */ iconPosition?: 'top' | 'side'; /** * If `true`, the component is disabled. * @default false */ disabled?: boolean; /** * You can provide your own value. Otherwise, it falls back to the child position index. */ value?: number | string; /** * Callback invoked when new value is being set. */ onChange?: (event: React.SyntheticEvent, value: number | string) => void; } export interface TabTypeMap

{ props: P & TabOwnProps & { /** * The system prop that allows defining system overrides as well as additional CSS styles. */ sx?: SxProps; } & TabSlotsAndSlotProps; defaultComponent: D; } export type TabProps = OverrideProps, D>; export interface TabOwnerState extends TabProps { /** * The content direction flow. * @default 'horizontal' */ orientation?: 'horizontal' | 'vertical'; /** * If `true`, the tab is activated by mouse or keyboard. */ active: boolean; /** * If `true`, the tab is disabled. */ disabled: boolean; /** * If `true`, the tab is disabled. */ selected: boolean; /** * @internal */ row: boolean; }