mirror of https://github.com/vector-im/riot-web
Fix AccessibleTooltipButton leaking tooltipclassname into the DOM
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>pull/21833/head
parent
793c3554dc
commit
1b08c1e9df
|
@ -16,7 +16,7 @@ limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
import classnames from 'classnames';
|
import classNames from 'classnames';
|
||||||
|
|
||||||
import AccessibleButton from "./AccessibleButton";
|
import AccessibleButton from "./AccessibleButton";
|
||||||
import {IProps} from "./AccessibleButton";
|
import {IProps} from "./AccessibleButton";
|
||||||
|
@ -52,15 +52,11 @@ export default class AccessibleTooltipButton extends React.PureComponent<IToolti
|
||||||
};
|
};
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
const {title, children, ...props} = this.props;
|
const {title, children, tooltipClassName, ...props} = this.props;
|
||||||
const tooltipClassName = classnames(
|
|
||||||
"mx_AccessibleTooltipButton_tooltip",
|
|
||||||
this.props.tooltipClassName,
|
|
||||||
);
|
|
||||||
|
|
||||||
const tip = this.state.hover ? <Tooltip
|
const tip = this.state.hover ? <Tooltip
|
||||||
className="mx_AccessibleTooltipButton_container"
|
className="mx_AccessibleTooltipButton_container"
|
||||||
tooltipClassName={tooltipClassName}
|
tooltipClassName={classNames("mx_AccessibleTooltipButton_tooltip", tooltipClassName)}
|
||||||
label={title}
|
label={title}
|
||||||
/> : <div />;
|
/> : <div />;
|
||||||
return (
|
return (
|
||||||
|
|
Loading…
Reference in New Issue