UNPKG

@brizy/ui

Version:
12 lines (11 loc) 669 B
import React from "react"; import AntTabs from "antd/lib/tabs"; import { BRZ_PREFIX } from "../constants"; export const Tabs = props => { const { defaultActiveKey, activeKey, size, type, tabPosition, onChange, onEdit, children } = props; return (React.createElement(AntTabs, { className: `${BRZ_PREFIX}-tabs`, defaultActiveKey: defaultActiveKey, activeKey: activeKey, tabPosition: tabPosition, size: size, type: type, onChange: onChange, onEdit: onEdit }, children)); }; export const TabPane = props => { const { key, tab, children } = props; return (React.createElement(AntTabs.TabPane, Object.assign({}, props, { key: key, tab: tab }), children)); };