import type React from 'react'; import type { SafeKey } from "../_util/type"; import type { DropdownProps } from '../dropdown'; import type { TransitionProps } from '../transition'; import type { TabNavListProps } from './TabNavList'; import type { TabPanelProps } from './TabPanelList/TabPanel'; import type { TabsProps } from './Tabs'; export type TriggerProps = { trigger?: 'hover' | 'click'; }; export type IconsType = { add?: React.ReactNode; close?: React.ReactNode; more?: React.ReactNode; }; export type MoreProps = Omit; export type SizeInfo = [width: number, height: number]; export type TabSizeMap = Map; export interface TabOffset { width: number; height: number; left: number; right: number; top: number; } export type TabOffsetMap = Map; export type TabsType = 'line' | 'pills' | 'card'; export type TabPosition = 'left' | 'right' | 'top' | 'bottom'; export interface Tab extends Omit { key: SafeKey; label: React.ReactNode; } type RenderTabBarProps = { id: string; activeKey: SafeKey; animated: AnimatedConfig; tabPosition: TabPosition; mobile: boolean; editConfig: EditableConfig; locale?: TabsLocale; more?: MoreProps; onTabClick: (key: SafeKey, e: React.MouseEvent | React.KeyboardEvent) => void; onTabScroll?: OnTabScroll; extra?: TabBarExtraContent; style?: React.CSSProperties; }; export type RenderTabBar = (props: RenderTabBarProps, DefaultTabBar: React.ComponentType) => React.ReactElement; export interface TabsLocale { dropdownAriaLabel?: string; closeAriaLabel?: string; addAriaLabel?: string; } export type EditableConfig = Pick; export interface AnimatedConfig { indicator?: boolean; tabPane?: boolean; tabPaneTransition?: TransitionProps; } export type OnTabScroll = (info: { direction: 'left' | 'right' | 'top' | 'bottom'; }) => void; export type TabBarExtraPosition = 'left' | 'right'; export type TabBarExtraMap = Partial>; export type TabBarExtraContent = React.ReactNode | TabBarExtraMap; export interface TabsRef { triggerRename: (key: SafeKey) => void; } export {};