mirror of
https://github.com/ant-design/ant-design.git
synced 2024-11-29 05:29:37 +08:00
22 lines
415 B
JavaScript
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>
|
|
);
|
|
}
|
|
});
|