@cmk/fe_utils
Version:
frontend utility library
53 lines (51 loc) • 1.8 kB
TypeScript
import { Ref, ReactNode } from 'react';
import { BadgeProps, BoxProps, TabProps, TooltipProps, TypographyProps, TabsProps } from '@mui/material';
import { FlexProps } from '../_wrapper';
import { IconProps } from '@mdi/react/dist/IconProps';
export type CTabsProps = Omit<TabsProps, 'onChange' | 'value' | 'slotProps'> & {
value: string;
onChange?: (value: string) => void;
items: {
value: string;
label?: ReactNode;
tooltip?: string;
disabled?: boolean;
icon?: string;
sx?: BoxProps['sx'];
isInitialValue?: boolean;
badge?: string;
badgeColor?: string;
badgeProps?: BadgeProps;
}[];
disableIndicator?: boolean;
indicatorColor?: 'primary' | 'secondary';
centered?: boolean;
scrollButtons?: 'auto' | false | true;
textColor?: 'primary' | 'secondary' | 'inherit';
variant?: 'standard' | 'scrollable' | 'fullWidth';
tabVariant?: 'text' | 'outlined' | 'filled';
activeTabFilledColor?: string;
visibleScrollbar?: boolean;
disableBorderBottom?: boolean;
sx?: TabsProps['sx'];
rootInjection?: ReactNode;
activeTabStylesIn?: TabProps['sx'];
ref?: Ref<HTMLDivElement>;
slotProps?: TabsProps['slotProps'] & {
activeTab?: {
tab?: TabProps;
tooltip?: Partial<TooltipProps>;
tabInnerContainer?: FlexProps;
icon?: Partial<IconProps>;
typography?: TypographyProps;
};
inactiveTab?: {
tab?: TabProps;
tooltip?: TooltipProps;
tabInnerContainer?: FlexProps;
icon?: IconProps;
typography?: TypographyProps;
};
};
};
export declare const Tabs: (props: CTabsProps) => import("react/jsx-runtime").JSX.Element;