This is an automated email from the ASF dual-hosted git repository.
beto pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/superset.git
The following commit(s) were added to refs/heads/master by this push:
new 04f7eca display tooltip when disabled (#16837)
04f7eca is described below
commit 04f7ecad1cebba2dd247ba40b71928fb0cef1def
Author: AAfghahi <[email protected]>
AuthorDate: Fri Sep 24 15:56:33 2021 -0400
display tooltip when disabled (#16837)
---
superset-frontend/src/components/Button/index.tsx | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/superset-frontend/src/components/Button/index.tsx
b/superset-frontend/src/components/Button/index.tsx
index 5199d26..7daf0eb 100644
--- a/superset-frontend/src/components/Button/index.tsx
+++ b/superset-frontend/src/components/Button/index.tsx
@@ -224,7 +224,9 @@ export default function Button(props: ButtonProps) {
id={`${kebabCase(tooltip)}-tooltip`}
title={tooltip}
>
- {button}
+ {/* this ternary wraps the button in a span so that the tooltip shows
up
+ when the button is disabled. */}
+ {disabled ? <span>{button}</span> : button}
</Tooltip>
);
}