💄 fix span type warning in site

This commit is contained in:
afc163 2018-12-26 21:44:34 +08:00
parent 7fa4e7aed3
commit 4da04acff9
No known key found for this signature in database
GPG Key ID: 738F973FCE5C6B48
2 changed files with 4 additions and 4 deletions

View File

@ -4,7 +4,7 @@ import { Col, Row } from '..';
describe('Grid', () => {
it('should render Col', () => {
const wrapper = render(<Col span="2" />);
const wrapper = render(<Col span={2} />);
expect(wrapper).toMatchSnapshot();
});
@ -14,11 +14,11 @@ describe('Grid', () => {
});
it('renders wrapped Col correctly', () => {
const MyCol = () => <Col span="12" />;
const MyCol = () => <Col span={12} />;
const wrapper = render(
<Row gutter={20}>
<div>
<Col span="12" />
<Col span={12} />
</div>
<MyCol />
</Row>,

View File

@ -117,7 +117,7 @@ export default class ComponentDoc extends React.Component {
</section>
<Row gutter={16}>
<Col
span={isSingleCol ? '24' : '12'}
span={isSingleCol ? 24 : 12}
className={isSingleCol ? 'code-boxes-col-1-1' : 'code-boxes-col-2-1'}
>
{leftChildren}