From 5b053fe23da2f164278ac8035f3d4a0502158d2d Mon Sep 17 00:00:00 2001 From: Talyor Chen Date: Wed, 23 Feb 2022 14:47:04 -0500 Subject: [PATCH 1/2] fix(tooltip-not-dissapeared): make the tooltip disappear when mouse away --- superset-frontend/src/components/Button/index.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/superset-frontend/src/components/Button/index.tsx b/superset-frontend/src/components/Button/index.tsx index 725ac6dd5dfaa..a2ac0885f08ab 100644 --- a/superset-frontend/src/components/Button/index.tsx +++ b/superset-frontend/src/components/Button/index.tsx @@ -204,6 +204,7 @@ export default function Button(props: ButtonProps) { color: grayscale.base, backgroundColor: backgroundColorDisabled, borderColor: borderColorDisabled, + pointerEvents: 'none', }, marginLeft: 0, '& + .superset-button': { @@ -228,7 +229,7 @@ export default function Button(props: ButtonProps) { > {/* this ternary wraps the button in a span so that the tooltip shows up when the button is disabled. */} - {disabled ? {button} : button} + {disabled ? {button} : button} ); } From cf10f6522226989340d4197efa0d6c7293c16fd6 Mon Sep 17 00:00:00 2001 From: Talyor Chen Date: Fri, 25 Feb 2022 07:14:35 -0500 Subject: [PATCH 2/2] fix(tooltip-not-dissapeared): change css props instead of sytles props --- superset-frontend/src/components/Button/index.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/superset-frontend/src/components/Button/index.tsx b/superset-frontend/src/components/Button/index.tsx index aa711cd9b835e..63a017836a1f7 100644 --- a/superset-frontend/src/components/Button/index.tsx +++ b/superset-frontend/src/components/Button/index.tsx @@ -232,7 +232,7 @@ export default function Button(props: ButtonProps) { {/* this ternary wraps the button in a span so that the tooltip shows up when the button is disabled. */} {disabled ? ( - {button} + {button} ) : ( button )}