Merge branch 'master' into page-header-button

This commit is contained in:
陈帅 2019-04-21 14:51:56 +08:00
commit 6d1d685393
61 changed files with 151 additions and 116 deletions

View File

@ -767,7 +767,7 @@ exports[`renders ./components/alert/demo/icon.md correctly 1`] = `
<span
class="ant-alert-description"
>
Detailed description and advices about successful copywriting.
Detailed description and advice about successful copywriting.
</span>
</div>
<div
@ -804,7 +804,7 @@ exports[`renders ./components/alert/demo/icon.md correctly 1`] = `
<span
class="ant-alert-description"
>
Additional description and informations about copywriting.
Additional description and information about copywriting.
</span>
</div>
<div

View File

@ -12,7 +12,7 @@ title:
## en-US
Decent icon make information more clear and more friendly.
A relevant icon makes information clearer and more friendly.
````jsx
import { Alert, Icon } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
Decent icon make information more clear and more friendly.
A relevant icon will make information clearer and more friendly.
````jsx
import { Alert } from 'antd';
@ -24,13 +24,13 @@ ReactDOM.render(
<Alert message="Error" type="error" showIcon />
<Alert
message="Success Tips"
description="Detailed description and advices about successful copywriting."
description="Detailed description and advice about successful copywriting."
type="success"
showIcon
/>
<Alert
message="Informational Notes"
description="Additional description and informations about copywriting."
description="Additional description and information about copywriting."
type="info"
showIcon
/>

View File

@ -11,7 +11,7 @@ title:
## en-US
Smoothly and unaffectedly unmount Alert.
Smoothly unmount Alert upon close.
````jsx
import { Alert } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
Usually used for messages remind.
Usually used for reminders and notifications.
````jsx
import { Avatar, Badge } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
Image, Icon and letter are supported, and the latter two kinds avatar can have custom colors and background colors.
Image, Icon and letter are supported, and the latter two kinds of avatar can have custom colors and background colors.
````jsx
import { Avatar } from 'antd';

View File

@ -11,8 +11,8 @@ title:
## en-US
New feature after 3.16.0. We preset a series of colorful Badge style for different situation usage.
And you can always set it to a hex color string for custom color.
New feature after 3.16.0. We preset a series of colorful Badge styles for use in different situations.
You can also set it to a hex color string for custom color.
````jsx
import { Badge } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
Accordion mode, only one panel can be expanded at a time. The first panel will be expanded by default.
In accordion mode, only one panel can be expanded at a time. The first panel will be expanded by default.
````jsx
import { Collapse } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
More than one panel can be expanded at a time, the first panel is initialized to be active in this case.
By default, any number of panels can be expanded at a time. The first panel is expanded in this example.
````jsx
import { Collapse } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
You can disable showing arrow icon by passing `showArrow={false}` to `CollapsePanel` component.
You can hide the arrow icon by passing `showArrow={false}` to `CollapsePanel` component.
````jsx
import { Collapse } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
Comment can be used as editor, user can customize the editor component.
Comment can be used as an editor, so the user can customize the contents of the component.
````jsx
import {

View File

@ -11,7 +11,7 @@ title:
## en-US
Divider default type is `horizontal`. Support inner text inside Divider.
Divider is `horizontal` by default. You can add text within Divider.
````jsx
import { Divider } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
Set orientation of divider to left or right.
Set `orientation="left/right"` to align the inner text.
````jsx
import { Divider } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
Use form in drawer with submit button.
Use a form in Drawer with a submit button.
```jsx
import {

View File

@ -11,7 +11,7 @@ title:
## en-US
Open a new drawer on top of an existing drawer to handle multi branch tasks
Open a new drawer on top of an existing drawer to handle multi branch tasks.
```jsx
import { Drawer, Button } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
Basic drawer.
The Drawer can appear from any edge of the screen.
```jsx
import { Drawer, Button, Radio } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
Use when you need to quickly preview the outline of the object. Such as list item preview.
Use Drawer to quickly preview details of an object, such as those in a list.
```jsx
import {

View File

@ -5,15 +5,15 @@ subtitle:
title: Drawer
---
Panel slides from screen edge.
A panel which slides in from the edge of the screen.
## When To Use
A Drawer is a panel that is typically overlaid on top of a page and slides in from the side. It contains a set of information or actions. Since that user can interact with the Drawer without leaving the current page, tasks can be achieved more efficient within the same context.
A Drawer is a panel that is typically overlaid on top of a page and slides in from the side. It contains a set of information or actions. Since the user can interact with the Drawer without leaving the current page, tasks can be achieved more efficiently within the same context.
* Use a Form to create or edit a set of information.
* Processing subtasks. When subtasks are too heavy for Popover and we still want to keep the subtasks in the context of the main task, Drawer comes very handy.
* When a same Form is needed in multiple places.
* Processing subtasks. When subtasks are too heavy for a Popover and we still want to keep the subtasks in the context of the main task, Drawer comes very handy.
* When the same Form is needed in multiple places.
## API

View File

@ -33,7 +33,7 @@ export interface CustomIconComponentProps {
style?: React.CSSProperties;
spin?: boolean;
rotate?: number;
['aria-hidden']?: string;
['aria-hidden']?: React.AriaAttributes['aria-hidden'];
}
export type ThemeType = 'filled' | 'outlined' | 'twoTone';

View File

@ -7,7 +7,7 @@ export const svgBaseProps = {
width: '1em',
height: '1em',
fill: 'currentColor',
['aria-hidden']: 'true',
['aria-hidden']: true,
focusable: 'false',
};

View File

@ -11,7 +11,7 @@ title:
## en-US
Creating a grid list by setting the `grid` property of List
Create a grid layout by setting the `grid` property of List.
````jsx
import { List, Card } from 'antd';

View File

@ -13,7 +13,7 @@ title:
## en-US
An example of infinite list & virtualized loading using [react-virtualized](https://github.com/bvaughn/react-virtualized). [Learn more](https://blog.jscrambler.com/optimizing-react-rendering-through-virtualization/)
An example of infinite list & virtualized loading using [react-virtualized](https://github.com/bvaughn/react-virtualized). [Learn more](https://blog.jscrambler.com/optimizing-react-rendering-through-virtualization/).
`Virtualized` rendering is a technique to mount big sets of data. It reduces the amount of rendered DOM nodes by tracking and hiding whatever isn't currently visible.

View File

@ -1,7 +1,7 @@
---
order: 5
title:
zh-CN: 响应式的栅格列表
zh-CN: 响应式的栅格列表
en-US: Responsive grid list
---
@ -11,7 +11,7 @@ title:
## en-US
Responsive grid list. The size property is as same as [Layout Grid](https://ant.design/components/grid/#Col).
Responsive grid list. The size property the is as same as [Layout Grid](https://ant.design/components/grid/#Col).
````jsx
import { List, Card } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
Setting `itemLayout` property with `vertical` to create a vertical list.
Set the `itemLayout` property to `vertical` to create a vertical list.
````jsx
import { List, Avatar, Icon } from 'antd';

View File

@ -9,7 +9,7 @@ title: LocaleProvider
## Usage
`LocaleProvider` takes use of [context](https://facebook.github.io/react/docs/context.html), a feature of React, to accomplish global effectiveness by wrapping the app only once.
`LocaleProvider` makes use of [context](https://facebook.github.io/react/docs/context.html), a feature of React, to accomplish global effectiveness by wrapping the app only once.
```jsx
import { LocaleProvider } from 'antd';
@ -23,7 +23,7 @@ moment.locale('fr');
return <LocaleProvider locale={fr_FR}><App /></LocaleProvider>;
```
We provide some locale like English, Chinese, Russian, German, French and etc, all locale packages can be found in [here](https://github.com/ant-design/ant-design/blob/master/components/locale-provider/).
We provide some locales like English, Chinese, Russian, German, French etc. All locale packages can be found in [here](https://github.com/ant-design/ant-design/blob/master/components/locale-provider/).
Note: if you need to use antd's UMD dist file, please use `antd/dist/antd-with-locales.js` and corresponding moment locale:
@ -41,7 +41,7 @@ If you can't find your language, you are welcome to create a locale package base
### Other localization needs
This component aims for localization of the built-in text, if you want to support other documents, we recommend using [react-intl](https://github.com/yahoo/react-intl), refer to [Intl demo 1](http://github.com/ant-design/intl-example) and [Intl demo 2](http://yiminghe.me/learning-react/examples/react-intl.html?locale=en-US).
This component aims to provide localization of the built-in text. If you want to support other documents, we recommend using [react-intl](https://github.com/yahoo/react-intl), refer to [Intl demo 1](http://github.com/ant-design/intl-example) and [Intl demo 2](http://yiminghe.me/learning-react/examples/react-intl.html?locale=en-US).
## API

View File

@ -68,7 +68,7 @@ exports[`renders ./components/message/demo/thenable.md correctly 1`] = `
type="button"
>
<span>
Display a sequence of message
Display sequential messages
</span>
</button>
`;

View File

@ -11,7 +11,7 @@ title:
## en-US
Normal messages as feedbacks.
Normal message for information.
````jsx
import { message, Button } from 'antd';

View File

@ -2,7 +2,7 @@
order: 3
title:
zh-CN: 加载中
en-US: Message of loading
en-US: Message with loading indicator
---
## zh-CN

View File

@ -10,7 +10,7 @@ title:
可以通过 then 接口在关闭后运行 callback 。以上用例将在每个 message 将要结束时通过 then 显示新的 message 。
## en-US
`message` provides promise interface for `onClose`. The above example will display a new message when old message is about to finish.
`message` provides a promise interface for `onClose`. The above example will display a new message when the old message is about to close.
````jsx
import { message, Button } from 'antd';
@ -22,7 +22,7 @@ const success = () => {
};
ReactDOM.render(
<Button onClick={success}>Display a sequence of message</Button>,
<Button onClick={success}>Display sequential messages</Button>,
mountNode
);
````

View File

@ -11,7 +11,7 @@ title:
## en-US
Asynchronously close a modal dialog when a user clicked OK button, for example,
Asynchronously close a modal dialog when a the OK button is pressed. For example,
you can use this pattern when you submit a form.
````jsx

View File

@ -11,7 +11,7 @@ title:
## en-US
Passing `okButtonProps` and `cancelButtonProps` can customize the ok button and cancel button props.
Passing `okButtonProps` and `cancelButtonProps` will customize the OK button and cancel button props.
````jsx
import { Modal, Button } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
To use `confirm()` to popup confirmation modal dialog. Let onCancel/onOk function return a promise object to
Use `confirm()` to show a confirmation modal dialog. Let onCancel/onOk function return a promise object to
delay closing the dialog.
````jsx

View File

@ -11,7 +11,7 @@ title:
## en-US
`Modal.destroyAll()` could destroy all confirmation modal dialogs. Usually, you can use it in router change event to destroy confirm modal dialog automatically
`Modal.destroyAll()` will destroy all confirmation modal dialogs. Usually, you can use it in router change event to destroy confirm modal dialog automatically.
```jsx
import { Modal, Button } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
To use `confirm()` to popup a confirmation modal dialog.
Use `confirm()` to show a confirmation modal dialog.
````jsx
import { Modal, Button } from 'antd';

View File

@ -13,8 +13,8 @@ title:
## en-US
A more complex example which define a customized footer button bar,
the dialog will change to loading state after clicking submit button, when the loading is over,
A more complex example which define a customized footer button bar.
The dialog will change to loading state after clicking the submit button, and when the loading is done,
the modal dialog will be closed.
You could set `footer` to `null` if you don't need default footer buttons.

View File

@ -11,7 +11,7 @@ title:
## en-US
Manually updateing and destroying a modal from `Modal.method`.
Manually updating and destroying a modal from `Modal.method`.
````jsx
import { Modal, Button } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
A notification box can pop up from `topRight` or `bottomRight` or `bottomLeft` or `topLeft`.
A notification box can appear from the `topRight`, `bottomRight`, `bottomLeft` or `topLeft` of the viewport.
````jsx
import { Button, Select, notification } from 'antd';

View File

@ -11,7 +11,7 @@ title:
## en-US
There are 12 `placement` options available. Use `arrowPointAtCenter` if you want arrow point at the center of target.
There are 12 `placement` options available. Use `arrowPointAtCenter` if you want the arrow to point at the center of target.
````jsx
import { Popconfirm, message, Button } from 'antd';

View File

@ -5,13 +5,13 @@ title: Skeleton
cols: 1
---
Provide a placeholder at the place which need waiting for loading.
Provide a placeholder while you wait for content to load, or to visualise content that doesn't exist yet.
## When To Use
- When resource needs long time to load, like low network speed.
- The component contains much information. Such as List or Card.
- Only works when loading data at first time.
- Could be replaced by Spin in all situation, but provide better user experience than spin if it works.
- When a resource needs long time to load.
- When the component contains lots of information, such as List or Card.
- Only works when loading data for the first time.
- Could be replaced by Spin in any situation, but can provide a better user experience.
## API

View File

@ -11,7 +11,7 @@ title:
## en-US
Embedding content into `Spin` will alter it into loading state.
Embedding content into `Spin` will set it into loading state.
````jsx
import { Spin, Switch, Alert } from 'antd';

View File

@ -1,6 +1,6 @@
---
order: 1
title:
title:
zh-CN: 各种大小
en-US: Size
---
@ -11,7 +11,7 @@ title:
## en-US
A small `Spin` use in loading text, default `Spin` use in loading card-level block, and large `Spin` use in loading **page**.
A small `Spin` is used for loading text, default sized `Spin` for loading a card-level block, and large `Spin` used for loading a **page**.
````jsx
import { Spin } from 'antd';

View File

@ -1,6 +1,6 @@
import * as React from 'react';
import * as ReactDOM from 'react-dom';
import RcTable from 'rc-table';
import RcTable, { INTERNAL_COL_DEFINE } from 'rc-table';
import * as PropTypes from 'prop-types';
import classNames from 'classnames';
import shallowEqual from 'shallowequal';
@ -779,6 +779,9 @@ export default class Table<T> extends React.Component<TableProps<T>, TableState<
fixed: rowSelection.fixed,
width: rowSelection.columnWidth,
title: rowSelection.columnTitle,
[INTERNAL_COL_DEFINE]: {
className: `${prefixCls}-selection-col`,
},
};
if (rowSelection.type !== 'radio') {
const checkboxAllDisabled = data.every(

View File

@ -26,7 +26,9 @@ exports[`Table.rowSelection fix selection column on the left 1`] = `
class=""
>
<colgroup>
<col />
<col
class="ant-table-selection-col"
/>
<col />
</colgroup>
<thead
@ -250,7 +252,9 @@ exports[`Table.rowSelection fix selection column on the left 1`] = `
class="ant-table-fixed"
>
<colgroup>
<col />
<col
class="ant-table-selection-col"
/>
</colgroup>
<thead
class="ant-table-thead"

View File

@ -2427,7 +2427,9 @@ exports[`renders ./components/table/demo/dynamic-settings.md correctly 1`] = `
<col
class="ant-table-expand-icon-col"
/>
<col />
<col
class="ant-table-selection-col"
/>
<col
style="width:150px;min-width:150px"
/>
@ -4860,7 +4862,9 @@ exports[`renders ./components/table/demo/expand-children.md correctly 1`] = `
class=""
>
<colgroup>
<col />
<col
class="ant-table-selection-col"
/>
<col />
<col
style="width:12%;min-width:12%"
@ -12415,7 +12419,9 @@ exports[`renders ./components/table/demo/row-selection.md correctly 1`] = `
class=""
>
<colgroup>
<col />
<col
class="ant-table-selection-col"
/>
<col />
<col />
<col />
@ -12842,7 +12848,9 @@ exports[`renders ./components/table/demo/row-selection-and-operation.md correctl
class=""
>
<colgroup>
<col />
<col
class="ant-table-selection-col"
/>
<col />
<col />
<col />
@ -13539,7 +13547,9 @@ exports[`renders ./components/table/demo/row-selection-custom.md correctly 1`] =
class=""
>
<colgroup>
<col />
<col
class="ant-table-selection-col"
/>
<col />
<col />
<col />

View File

@ -11,7 +11,7 @@ title:
## en-US
Two compacted table size: `middle` and `small`, `small` size is used in Modal only.
There are two compacted table sizes: `middle` and `small`. The `small` size is used in Modals only.
````jsx
import { Table } from 'antd';

View File

@ -310,22 +310,6 @@
padding: @table-padding-vertical @table-padding-horizontal;
}
&-thead > tr > th.@{table-prefix-cls}-selection-column-custom {
.@{table-prefix-cls}-selection {
margin-right: -15px;
}
}
&-thead > tr > th.@{table-prefix-cls}-selection-column,
&-tbody > tr > td.@{table-prefix-cls}-selection-column {
width: @table-selection-column-width;
text-align: center;
.@{ant-prefix}-radio-wrapper {
margin-right: 0;
}
}
&-expand-icon-th,
&-row-expand-icon-cell {
width: 50px;
@ -561,10 +545,6 @@
content: '.';
}
}
&[class*='@{table-prefix-cls}-row-level-0'] .@{table-prefix-cls}-selection-column > span {
display: inline-block;
}
}
tr&-expanded-row {
@ -685,6 +665,32 @@
&&-scroll-position-right &-fixed-right {
box-shadow: none;
}
// ========================== Row Selection ==========================
colgroup {
> col.@{table-prefix-cls}-selection-col {
width: @table-selection-column-width;
}
}
&-thead > tr > th.@{table-prefix-cls}-selection-column-custom {
.@{table-prefix-cls}-selection {
margin-right: -15px;
}
}
&-thead > tr > th.@{table-prefix-cls}-selection-column,
&-tbody > tr > td.@{table-prefix-cls}-selection-column {
text-align: center;
.@{ant-prefix}-radio-wrapper {
margin-right: 0;
}
}
&-row[class*='@{table-prefix-cls}-row-level-0'] .@{table-prefix-cls}-selection-column > span {
display: inline-block;
}
}
@import './size';

View File

@ -11,8 +11,8 @@ title:
## en-US
We preset a series of colorful tag style for different situation usage.
And you can always set it to a hex color string for custom color.
We preset a series of colorful tag styles for use in different situations.
You can also set it to a hex color string for custom color.
````jsx
import { Tag } from 'antd';

View File

@ -8,7 +8,7 @@ Vertical display timeline.
## When To Use
- When a series of information needs to be ordered by time (ascend or descend).
- When a series of information needs to be ordered by time (ascending or descending).
- When you need a timeline to make a visual connection.
## API

View File

@ -39,7 +39,7 @@ exports[`renders ./components/tooltip/demo/auto-adjust-overflow.md correctly 1`]
type="button"
>
<span>
Ingore / 不处理
Ignore / 不处理
</span>
</button>
</div>
@ -47,7 +47,7 @@ exports[`renders ./components/tooltip/demo/auto-adjust-overflow.md correctly 1`]
exports[`renders ./components/tooltip/demo/basic.md correctly 1`] = `
<span>
Tooltip will show when mouse enter.
Tooltip will show on mouse enter.
</span>
`;

View File

@ -12,7 +12,7 @@ debug: true
## en-US
Adjust popup placement automatically when popup is invisible
Adjust placement automatically when tooltip is invisible.
````jsx
import { Tooltip, Button } from 'antd';
@ -31,7 +31,7 @@ ReactDOM.render(
</Tooltip>
<br />
<Tooltip placement="left" title="Prompt Text" getPopupContainer={trigger => trigger.parentElement} autoAdjustOverflow={false}>
<Button>Ingore / 不处理</Button>
<Button>Ignore / 不处理</Button>
</Tooltip>
</div>,
mountNode

View File

@ -18,7 +18,7 @@ import { Tooltip } from 'antd';
ReactDOM.render(
<Tooltip title="prompt text">
<span>Tooltip will show when mouse enter.</span>
<span>Tooltip will show on mouse enter.</span>
</Tooltip>,
mountNode
);

View File

@ -11,7 +11,7 @@ title:
## en-US
The ToolTip has 12 placements choice.
There are 12 placement options available.
````jsx
import { Tooltip, Button } from 'antd';

View File

@ -2,7 +2,7 @@
order: 1
title:
zh-CN: 受控操作示例
en-US: basic controlled example
en-US: Controlled Tree
---
## zh-CN
@ -11,7 +11,7 @@ title:
## en-US
basic controlled example
Controlled mode lets parent nodes reflect the status of child nodes more intelligently.
````jsx
import { Tree } from 'antd';

View File

@ -2,7 +2,7 @@
order: 0
title:
zh-CN: 基本
en-US: basic
en-US: Basic
---
## zh-CN

View File

@ -96,8 +96,6 @@ import 'antd/dist/antd.css'; // or 'antd/dist/antd.less'
}
```
> Note: Don't set `libraryDirectory` if you are using webpack 1.
This allows you to import components from antd without having to manually import the corresponding stylesheet. The antd babel plugin will automatically import stylesheets.
```jsx

View File

@ -102,8 +102,6 @@ import 'antd/dist/antd.css'; // or 'antd/dist/antd.less'
}
```
> 注意webpack 1 无需设置 `libraryDirectory`
然后只需从 antd 引入模块即可,无需单独引入样式。等同于下面手动引入的方式。
```jsx

View File

@ -80,7 +80,7 @@
"rc-slider": "~8.6.5",
"rc-steps": "~3.3.0",
"rc-switch": "~1.9.0",
"rc-table": "~6.4.0",
"rc-table": "~6.5.0",
"rc-tabs": "~9.6.0",
"rc-time-picker": "~3.6.1",
"rc-tooltip": "~3.7.3",
@ -190,7 +190,7 @@
"stylelint-config-rational-order": "^0.1.0",
"stylelint-config-standard": "^18.2.0",
"stylelint-declaration-block-no-ignored-properties": "^1.1.0",
"stylelint-order": "^2.0.0",
"stylelint-order": "^3.0.0",
"typescript": "~3.4.1",
"unified": "^7.0.0",
"xhr-mock": "^2.4.1",

View File

@ -1,4 +1,4 @@
/* eslint-disable import/no-dynamic-require */
/* eslint-disable import/no-dynamic-require, no-console */
const chalk = require('chalk');
const path = require('path');
const fetch = require('node-fetch');
@ -14,21 +14,23 @@ function exitProcess(code = 1) {
process.exit(code);
}
async function checkCommit() {
const { current, files } = await git.status();
async function checkVersion() {
const { versions } = await fetch('http://registry.npmjs.org/antd').then(res => res.json());
if (version in versions) {
console.log(chalk.yellow('😈 Current version already exists. Forget update package.json?'));
console.log(chalk.cyan(' => Current:'), version);
exitProcess();
}
}
async function checkBranch({ current }) {
if (current !== 'master') {
console.log(chalk.yellow('🤔 You are not in the master branch!'));
exitProcess();
}
}
async function checkCommit({ files }) {
if (files.length) {
console.log(chalk.yellow('🙄 You forgot something to commit.'));
files.forEach(({ path: filePath, working_dir: mark }) => {
@ -36,7 +38,9 @@ async function checkCommit() {
});
exitProcess();
}
}
async function checkRemote() {
const { remote } = await git.fetch('origin', 'master');
if (remote.indexOf('ant-design/ant-design') === -1 || true) {
console.log(chalk.yellow('😓 Your remote origin is not ant-design. Do you fork it?'));
@ -44,4 +48,16 @@ async function checkCommit() {
}
}
checkCommit();
async function checkAll() {
const status = await git.status();
await checkVersion();
await checkBranch(status);
await checkCommit(status);
await checkRemote();
}
checkAll();

View File

@ -1,8 +1,8 @@
import * as React from 'react';
import CopyToClipboard from 'react-copy-to-clipboard';
import { Icon as AntdIcon, Badge } from 'antd';
import { ThemeType, IconProps } from 'antd/lib/icon';
import classNames from 'classnames';
import { ThemeType, IconProps } from '../../../../components/icon';
const Icon: React.SFC<IconProps> = AntdIcon;

View File

@ -8,7 +8,7 @@ import debounce from 'lodash/debounce';
import Category from './Category';
import { FilledIcon, OutlinedIcon, TwoToneIcon } from './themeIcons';
import { categories, Categories, CategoriesKeys } from './fields';
import { ThemeType } from '../../../../components/icon';
import { ThemeType } from 'antd/lib/icon';
interface IconDisplayProps extends InjectedIntlProps {}

View File

@ -1,5 +1,5 @@
import * as React from 'react';
import { CustomIconComponentProps } from '../../../../components/icon';
import { CustomIconComponentProps } from 'antd/lib/icon';
export const FilledIcon: React.SFC<CustomIconComponentProps> = props => {
const path =
@ -7,7 +7,7 @@ export const FilledIcon: React.SFC<CustomIconComponentProps> = props => {
'704c0 53 43 96 96 96h704c53 0 96-43 96-96V16' +
'0c0-53-43-96-96-96z';
return (
<svg {...props} viewBox="0 0 1024 1024">
<svg {...props as any} viewBox="0 0 1024 1024">
<path d={path} />
</svg>
);
@ -21,7 +21,7 @@ export const OutlinedIcon: React.SFC<CustomIconComponentProps> = props => {
'12-12V172c0-6.6 5.4-12 12-12h680c6.6 0 12 5.4' +
' 12 12v680c0 6.6-5.4 12-12 12z';
return (
<svg {...props} viewBox="0 0 1024 1024">
<svg {...props as any} viewBox="0 0 1024 1024">
<path d={path} />
</svg>
);
@ -34,7 +34,7 @@ export const TwoToneIcon: React.SFC<CustomIconComponentProps> = props => {
'066 16 512z m496 368V144c203.41 0 368 164.622 3' +
'68 368 0 203.41-164.622 368-368 368z';
return (
<svg {...props} viewBox="0 0 1024 1024">
<svg {...props as any} viewBox="0 0 1024 1024">
<path d={path} />
</svg>
);