You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2019/07/02 21:58:40 UTC

[GitHub] [incubator-superset] etr2460 commented on a change in pull request #7812: [dashboard] Fix URLShortLinkButton position after click anchor link

etr2460 commented on a change in pull request #7812: [dashboard] Fix URLShortLinkButton position after click anchor link
URL: https://github.com/apache/incubator-superset/pull/7812#discussion_r299702295
 
 

 ##########
 File path: superset/assets/src/dashboard/components/gridComponents/Tabs.jsx
 ##########
 @@ -100,7 +101,14 @@ class Tabs extends React.PureComponent {
     }
   }
 
-  handleClickTab(tabIndex) {
+  handleClickTab(tabIndex, ev) {
+    const target = ev.target;
+    // special handler for clicking on anchor link (or whitespace nearby):
+    // only show URLShortLinkButton but do not change tab
+    if (ANCHOR_LINK_TAGNAMES.includes(target.tagName)) {
 
 Review comment:
   instead of targeting the `tagName`, could we use something more specific like a CSS class or id?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org