mirror of
https://github.com/ant-design/ant-design.git
synced 2024-12-16 18:09:22 +08:00
502dac12aa
* docs: fix code * feat: lint * feat: prettier * feat: test * feat: review * feat: format html * feat: format html
18 lines
493 B
TypeScript
18 lines
493 B
TypeScript
import React from 'react';
|
|
import { CheckOutlined, CloseOutlined } from '@ant-design/icons';
|
|
import { Space, Switch } from 'antd';
|
|
|
|
const App: React.FC = () => (
|
|
<Space direction="vertical">
|
|
<Switch checkedChildren="开启" unCheckedChildren="关闭" defaultChecked />
|
|
<Switch checkedChildren="1" unCheckedChildren="0" />
|
|
<Switch
|
|
checkedChildren={<CheckOutlined />}
|
|
unCheckedChildren={<CloseOutlined />}
|
|
defaultChecked
|
|
/>
|
|
</Space>
|
|
);
|
|
|
|
export default App;
|