prefix className for popover

This commit is contained in:
afc163 2015-06-17 20:15:09 +08:00
parent 64036bebf1
commit 8100539f8d
2 changed files with 5 additions and 4 deletions

View File

@ -2,6 +2,7 @@
var React = require('react');
var Tooltip = require('rc-tooltip');
var prefixCls = 'ant-popover';
module.exports = React.createClass({
getDefaultProps() {
@ -13,10 +14,10 @@ module.exports = React.createClass({
},
render() {
var overlay = <div>
<div className="popover-title">
<div className={prefixCls + '-title'}>
{this.props.title}
</div>
<div className="popover-content">
<div className={prefixCls + '-content'}>
{this.props.overlay}
</div>
</div>;
@ -30,7 +31,7 @@ module.exports = React.createClass({
return (
<Tooltip placement={this.props.placement}
prefixCls="popover"
prefixCls={prefixCls}
renderPopupToBody={false}
transitionName={transitionName}
trigger={this.props.trigger}

View File

@ -29,7 +29,7 @@
//** Popover outer arrow color
@popover-arrow-outer-color: fadein(@popover-border-color, 5%);
.popover {
.@{popoverPrefixClass} {
position: absolute;
top: 0;
left: 0;