Update react tooltip imports
[MAILPOET-5482]
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import { ReactNode } from 'react';
|
||||
import { Place } from 'react-tooltip';
|
||||
import { PlacesType } from 'react-tooltip';
|
||||
import { Tag } from '../../tag';
|
||||
import { Tooltip } from '../../tooltip/tooltip';
|
||||
|
||||
@@ -7,7 +7,7 @@ type BadgeProps = {
|
||||
name: string;
|
||||
tooltip?: string | ReactNode;
|
||||
tooltipId?: string;
|
||||
tooltipPlace?: Place;
|
||||
tooltipPlace?: PlacesType;
|
||||
type?: 'average' | 'good' | 'excellent' | 'critical' | 'unknown';
|
||||
isInverted?: boolean;
|
||||
};
|
||||
|
@@ -1,12 +1,12 @@
|
||||
import { __, _x } from '@wordpress/i18n';
|
||||
import { Place } from 'react-tooltip';
|
||||
import { PlacesType } from 'react-tooltip';
|
||||
import { Badge } from './badge';
|
||||
|
||||
type StatsBadgeProps = {
|
||||
stat: string;
|
||||
rate: number;
|
||||
tooltipId?: string;
|
||||
tooltipPlace?: Place;
|
||||
tooltipPlace?: PlacesType;
|
||||
isInverted?: boolean;
|
||||
};
|
||||
|
||||
|
@@ -1,5 +1,5 @@
|
||||
import classnames from 'classnames';
|
||||
import ReactTooltip, { TooltipProps } from 'react-tooltip';
|
||||
import { Tooltip as ReactTooltip, ITooltip } from 'react-tooltip';
|
||||
|
||||
export function Tooltip({
|
||||
effect,
|
||||
@@ -10,7 +10,7 @@ export function Tooltip({
|
||||
className,
|
||||
children,
|
||||
...props
|
||||
}: TooltipProps) {
|
||||
}: ITooltip) {
|
||||
return (
|
||||
<ReactTooltip
|
||||
effect={effect || 'solid'}
|
||||
|
@@ -1,5 +1,5 @@
|
||||
import PropTypes from 'prop-types';
|
||||
import ReactTooltip from 'react-tooltip';
|
||||
import { Tooltip as ReactTooltip } from 'react-tooltip';
|
||||
import ReactHtmlParser from 'react-html-parser';
|
||||
|
||||
function Tooltip(props) {
|
||||
@@ -40,7 +40,6 @@ function Tooltip(props) {
|
||||
className="mailpoet-tooltip-message"
|
||||
multiline
|
||||
id={tooltipId}
|
||||
efect="solid"
|
||||
place={props.place}
|
||||
>
|
||||
{tooltip}
|
||||
|
Reference in New Issue
Block a user