import { Simplify } from '@mui/types'; import * as React from 'react'; import { ButtonOwnProps } from '../Button'; import { SlotComponentProps } from '../utils'; import { UseTabRootSlotProps } from '../useTab'; import { PolymorphicProps } from '../utils/PolymorphicComponent'; export interface TabRootSlotPropsOverrides { } export interface TabOwnProps extends Omit { /** * 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; /** * The props used for each slot inside the Tab. * @default {} */ slotProps?: { root?: SlotComponentProps<'button', TabRootSlotPropsOverrides, TabOwnerState>; }; /** * The components used for each slot inside the Tab. * Either a string to use a HTML element or a component. * @default {} */ slots?: TabSlots; } export interface TabSlots { /** * The component that renders the root. * @default 'button' */ root?: React.ElementType; } export type TabProps = PolymorphicProps, RootComponentType>; export interface TabTypeMap { props: TabOwnProps & AdditionalProps; defaultComponent: RootComponentType; } export type TabOwnerState = Simplify; export type TabRootSlotProps = Simplify; ownerState: TabOwnerState; }>;