diff --git a/packages/eui/src/components/tool_tip/tool_tip_arrow.tsx b/packages/eui/src/components/tool_tip/tool_tip_arrow.tsx index 0b5eb348597..31acc346319 100644 --- a/packages/eui/src/components/tool_tip/tool_tip_arrow.tsx +++ b/packages/eui/src/components/tool_tip/tool_tip_arrow.tsx @@ -7,15 +7,14 @@ */ import React, { HTMLAttributes, FunctionComponent } from 'react'; -import { useEuiTheme } from '../../services'; +import { useEuiMemoizedStyles } from '../../services'; import { ToolTipPositions } from './tool_tip_popover'; import { euiToolTipStyles } from './tool_tip.styles'; export const EuiToolTipArrow: FunctionComponent< { position: ToolTipPositions } & HTMLAttributes > = ({ position, ...props }) => { - const euiTheme = useEuiTheme(); - const styles = euiToolTipStyles(euiTheme); + const styles = useEuiMemoizedStyles(euiToolTipStyles); const cssStyles = [styles.euiToolTip__arrow, styles.arrowPositions[position]]; return
;