ant-design/components/tooltip/index.jsx
2015-06-10 22:10:51 +08:00

22 lines
415 B
JavaScript

'use strict';
var React = require('react');
var Tooltip = require('rc-tooltip');
module.exports = React.createClass({
getDefaultProps: function () {
return {
placement: 'top'
};
},
render: function() {
return (
<Tooltip placement={this.props.placement}
prefixCls="ant-tooltip"
overlay={this.props.title}>
{this.props.children}
</Tooltip>
);
}
});