Merge branch 'develop-1.0.0' of github.com:ant-design/ant-design into develop-1.0.0

This commit is contained in:
afc163 2016-04-11 10:57:17 +08:00
commit c9c4b8d445
15 changed files with 19 additions and 19 deletions

View File

@ -17,7 +17,8 @@ english: TreeSelect
| 参数 | 说明 | 类型 | 默认值 |
|-----------|------------------------------------------|------------|--------|
| value | 指定当前选中的条目 | string/Array<String> | 无 |
| value | 指定当前选中的条目 | 通常: String/Array<String>. 设置labelInValue: {value:String,label:React.Node}/Array<{value,label}>. 设置treeCheckStrictly(halfChecked默认为false): {value:String,label:React.Node, halfChecked}/Array<{value,label,halfChecked}>. | 无 |
| labelInValue | 是否把 label 嵌入到 value 里,设置后参考以上 value 类型写法 | boolean | false |
| defaultValue | 指定默认选中的条目 | string/Array<String> | 无 |
| multiple | 支持多选 | boolean | false |
| tags | 可以把随意输入的条目作为 tag输入项不需要与下拉选项匹配 | boolean |false |
@ -37,7 +38,6 @@ english: TreeSelect
| treeDefaultExpandAll | 默认展开所有树节点 | bool | false |
| treeCheckable | 显示checkbox | bool | false |
| treeCheckStrictly | checkable状态下节点选择完全受控父子节点选中状态不再关联| bool | false |
| treeHalfCheckedValues | 半选的树节点用于想要在checkable下节点选择完全受控时需要设置treeCheckStrictly | array | - |
| filterTreeNode | 是否根据输入项进行筛选返回值true | function(treeNode) | - |
| treeNodeFilterProp | 输入项过滤对应的 treeNode 属性 | String | 'value' |
| treeNodeLabelProp | 作为显示的prop设置 | String | 'title' |
@ -52,5 +52,5 @@ english: TreeSelect
| disabled | 是否禁用 | Boolean | false |
| key | 此项必须设置(其值在整个树范围内唯一) | String | - |
| value | 默认根据此属性值进行筛选 | String | - |
| title | 树节点显示的内容 | String | '---' |
| title | 树节点显示的内容 | String/element | '---' |
| isLeaf | 是否是叶子节点 | bool | false |

View File

@ -45,6 +45,6 @@ english: Tree
|-----------|------------------------------------------|------------|--------|
|disabled | 禁掉响应 | bool | false |
|disableCheckbox | 禁掉 checkbox | bool | false |
|title | 标题 | String | '---' |
|title | 标题 | String/element | '---' |
|key | 被树的 (default)ExpandedKeys / (default)CheckedKeys / (default)SelectedKeys 属性所用。注意:整个树范围内的所有节点的 key 值不能重复! | String | 内部计算出的节点位置 |
|isLeaf | 设置为叶子节点 | bool | false |

View File

@ -100,7 +100,7 @@
"gh-pages": "^0.11.0",
"history": "^2.0.1",
"jest-cli": "^0.10.0",
"jsonml-to-react-component": "~0.1.0",
"jsonml-to-react-component": "~0.2.0",
"jsonml.js": "^0.1.0",
"jsonp": "^0.2.0",
"lesshint": "^1.2.1",

View File

@ -1,6 +1,6 @@
import React from 'react';
import classNames from 'classnames';
import { Modal, Carousel } from '../../../';
import { Modal, Carousel } from 'antd';
function isGood(className) {
return /\bgood\b/i.test(className);

View File

@ -48,7 +48,7 @@ export default class Article extends React.Component {
return (
<li key={node[1]}>
<Link to={{ pathname: location.pathname, query: { scrollTo: node[1] } }}>
{toReactComponent([], node[1])}
{toReactComponent(node[1])}
</Link>
</li>
);

View File

@ -1,7 +1,7 @@
import React from 'react';
import { Link } from 'react-router';
import classNames from 'classnames';
import { Row, Col, Icon, Affix } from '../../../';
import { Row, Col, Icon, Affix } from 'antd';
import Demo from '../Demo';
import * as utils from '../utils';
import demosList from '../../../_data/demos-list';

View File

@ -1,5 +1,5 @@
import React from 'react';
import { Select } from '../../../';
import { Select } from 'antd';
import { version as antdVersion } from '../../../package.json';
import { docVersions } from '../../website.config';
const Option = Select.Option;

View File

@ -1,7 +1,7 @@
import React from 'react';
import { Link } from 'react-router';
import enquire from 'enquire.js';
import { Select, Menu, Row, Col, Icon } from '../../../';
import { Select, Menu, Row, Col, Icon } from 'antd';
const Option = Select.Option;
import './index.less';

View File

@ -4,7 +4,7 @@ import ScrollElement from 'rc-scroll-anim/lib/ScrollElement';
import TweenOne from 'rc-tween-one';
import GitHubButton from 'react-github-button';
import 'react-github-button/assets/style.css';
import { Icon } from '../../../';
import { Icon } from 'antd';
import QueueAnim from 'rc-queue-anim';
export default class Banner extends React.Component {

View File

@ -2,7 +2,7 @@ import React from 'react';
import { Link } from 'react-router';
import TweenOne from 'rc-tween-one';
import ScrollOverPack from 'rc-scroll-anim/lib/ScrollOverPack';
import { Icon, Button } from '../../../';
import { Icon, Button } from 'antd';
import QueueAnim from 'rc-queue-anim';
const clientHeight = document.documentElement.clientHeight;

View File

@ -2,7 +2,7 @@ import React from 'react';
import { Link } from 'react-router';
import TweenOne from 'rc-tween-one';
import ScrollOverPack from 'rc-scroll-anim/lib/ScrollOverPack';
import { Icon, Button } from '../../../';
import { Icon, Button } from 'antd';
import QueueAnim from 'rc-queue-anim';
export default class Page2 extends React.Component {

View File

@ -2,7 +2,7 @@ import React from 'react';
import { Link } from 'react-router';
import TweenOne from 'rc-tween-one';
import ScrollOverPack from 'rc-scroll-anim/lib/ScrollOverPack';
import { Icon, Button } from '../../../';
import { Icon, Button } from 'antd';
import QueueAnim from 'rc-queue-anim';
export default class Page3 extends React.Component {

View File

@ -1,6 +1,6 @@
import React from 'react';
import CopyToClipboard from 'react-copy-to-clipboard';
import { Icon } from '../../../';
import { Icon } from 'antd';
export default class CopyableIcon extends React.Component {
constructor(props) {

View File

@ -1,7 +1,7 @@
import React from 'react';
import { Link } from 'react-router';
import scrollIntoView from 'dom-scroll-into-view';
import { Row, Col, Menu } from '../../../';
import { Row, Col, Menu } from 'antd';
import config from '../../website.config';
const SubMenu = Menu.SubMenu;

View File

@ -9,7 +9,7 @@ function isHeading(type) {
}
export function jsonmlToComponent(pathname, jsonml) {
return toReactComponent([
return toReactComponent(jsonml, [
[(node) => React.isValidElement(node), (node, index) => {
return React.cloneElement(node, { key: index });
}],
@ -23,11 +23,11 @@ export function jsonmlToComponent(pathname, jsonml) {
id: children,
...getAttributes(node),
}, [
<span key="title">{ children.map(toReactComponent.bind(null, [])) }</span>,
<span key="title">{ children.map((child) => toReactComponent(child)) }</span>,
<Link to={{ pathname, query: { scrollTo: children } }} className="anchor" key="anchor">#</Link>,
]);
}],
], jsonml);
]);
}
export function setTitle(title) {