提交 b0a95601 编写于 作者: Y yiminghe

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

......@@ -4,6 +4,13 @@
---
## 0.9.2 `2015-10-26`
* Tooltip 的 title 为空时不展示浮层。[9b53117](9b5311791e73270c7c16a602ac74dd59719a5f76)
* 修复 Upload 文件列表链接的 target 属性。[340a170](340a1702b6a7b065ac02d417c891e1886dfe470d)
* 修复 Datepicker 设置 defaultValue 时星期顺序错误的问题。[9ef1450](9ef14500f3abfcc7081f8dceab8187ec835e3918)
* 修复一些小的样式问题。
## 0.9.1 `2015-09-26`
* 添加 Pagination pageSize 发生变化的回调。[#317](https://github.com/ant-design/ant-design/issues/317)
......
......@@ -10,6 +10,14 @@ export default React.createClass({
mouseLeaveDelay: 0.1
};
},
getInitialState() {
return {
visible: false
};
},
onVisibleChange(visible) {
this.setState({ visible });
},
render() {
let transitionName = ({
top: 'zoom-down',
......@@ -17,12 +25,21 @@ export default React.createClass({
left: 'zoom-right',
right: 'zoom-left'
})[this.props.placement];
// Hide tooltip when there is no title
let visible = this.state.visible;
if (!this.props.title) {
visible = false;
}
return (
this.props.title ? <Tooltip transitionName={transitionName}
<Tooltip transitionName={transitionName}
overlay={this.props.title}
visible={visible}
onVisibleChange={this.onVisibleChange}
{...this.props}>
{this.props.children}
</Tooltip> : this.props.children
</Tooltip>
);
}
});
......@@ -32,7 +32,7 @@ $ npm install antd@beta --save
我们提供了开发构建的命令行工具,可以安装到全局直接使用。
```bash
$ npm install antd-bin -g
$ npm install antd-bin@0.6.x -g
```
或者安装到仓库下,使用 `package.json``scripts` 字段来配置命令:
......
{
"name": "antd",
"version": "0.10.0-beta7",
"stableVersion": "0.9.1",
"stableVersion": "0.9.2",
"title": "Ant Design",
"description": "一个 UI 设计语言",
"homepage": "http://ant.design/",
......
......@@ -53,7 +53,7 @@ InstantClickChangeFns.push(function () {
InstantClickChangeFns.push(function () {
var versionsHistory = {
'0.9.1': '09x.ant.design'
'0.9.2': '09x.ant.design'
};
versionsHistory[antdVersion.latest] =
versionsHistory[antdVersion.latest] || 'http://ant.design';
......
......@@ -10,7 +10,7 @@ body {
}
body {
font-family: "Helvetica Neue",Helvetica,"Hiragino Sans GB","Microsoft YaHei","微软雅黑",SimSun,sans-serif;
font-family: "Helvetica Neue",Helvetica,"PingFang SC","Hiragino Sans GB","Microsoft YaHei","微软雅黑",SimSun,sans-serif;
line-height: 1.5;
color: #777;
font-size: 14px;
......
......@@ -52,6 +52,7 @@
background-color: @tooltip-bg;
border-radius: @border-radius-base;
box-shadow: @overlay-shadow;
min-height: 34px;
}
// Arrows
......
......@@ -10,7 +10,7 @@
// ------ Base & Require ------
@body-background : #fff;
@font-family : "Helvetica Neue",Helvetica,"Hiragino Sans GB","STHeitiSC-Light","Microsoft YaHei","微软雅黑",Arial,sans-serif;
@font-family : "Helvetica Neue",Helvetica,"PingFang SC","Hiragino Sans GB","Microsoft YaHei","微软雅黑",Arial,sans-serif;
@code-family : Consolas,Menlo,Courier,monospace;
@text-color : #666;
@font-size-base : 12px;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册