@uiw/react-native
Version:
UIW for React Native
41 lines (40 loc) • 1.17 kB
TypeScript
import React from 'react';
import { IconsName } from '../Icon';
export type TabsItemIconTypes = IconsName | React.ReactElement | React.ReactNode | JSX.Element;
/** 样式集合类型 */
export interface TabsItemStyle {
/** 宽度 */
width?: number;
/** 文字粗细 */
titleFontWeight?: '100' | '200' | '300' | '400' | '500' | '600' | '700' | '800' | '900' | 'bold' | 'normal';
/** 文字大小 */
titleSize?: number;
/** icon 大小 */
iconSize?: number;
/** border 宽度 */
borderWidth?: number;
/** border 粗细 */
borderHeight?: number;
}
export interface TabsItemProps {
/** 显示的文字 */
title: string;
/** 样式集合 */
style?: TabsItemStyle;
/**
* 点击时触发
* void
* @param title type: string title 文字
*/
onPress?: (title: string) => void;
/** 图标 */
icon?: TabsItemIconTypes;
activeColor?: string;
value?: number;
onChange?: (value: number) => void;
index?: number;
defaultColor?: string;
children?: React.ReactNode;
}
declare function TabsItem(props: TabsItemProps): React.JSX.Element;
export default TabsItem;