UNPKG

839 BTypeScriptView Raw
1import * as React from 'react';
2import { TabsProps as RcTabsProps, TabPaneProps } from 'rc-tabs';
3import { SizeType } from '../config-provider/SizeContext';
4export declare type TabsType = 'line' | 'card' | 'editable-card';
5export declare type TabsPosition = 'top' | 'right' | 'bottom' | 'left';
6export { TabPaneProps };
7export interface TabsProps extends Omit<RcTabsProps, 'editable'> {
8 type?: TabsType;
9 size?: SizeType;
10 hideAdd?: boolean;
11 centered?: boolean;
12 addIcon?: React.ReactNode;
13 onEdit?: (e: React.MouseEvent | React.KeyboardEvent | string, action: 'add' | 'remove') => void;
14}
15declare function Tabs({ type, className, size: propSize, onEdit, hideAdd, centered, addIcon, ...props }: TabsProps): JSX.Element;
16declare namespace Tabs {
17 var TabPane: typeof import("rc-tabs").TabPane;
18}
19export default Tabs;