etr2460 commented on a change in pull request #11778:
URL: 
https://github.com/apache/incubator-superset/pull/11778#discussion_r532340489



##########
File path: superset-frontend/src/dashboard/components/SliceHeaderControls.jsx
##########
@@ -123,6 +125,9 @@ class SliceHeaderControls extends React.PureComponent {
   }
 
   handleMenuClick({ key, domEvent }) {
+    const menu = document.querySelector(

Review comment:
       let's move this const into the specific download as image case, that way 
it's also covered by the comment showing the hackiness

##########
File path: superset-frontend/src/dashboard/components/HeaderActionsDropdown.jsx
##########
@@ -137,6 +139,9 @@ class HeaderActionsDropdown extends React.PureComponent {
   }
 
   handleMenuClick({ key, domEvent }) {
+    const menu = document.querySelector(

Review comment:
       let's move this const into the specific download as image case, that way 
it's also covered by the comment showing the hackiness

##########
File path: superset-frontend/src/dashboard/components/HeaderActionsDropdown.jsx
##########
@@ -87,6 +87,8 @@ const DropdownButton = styled.div`
   margin-left: ${({ theme }) => theme.gridUnit * 2.5}px;
 `;
 
+const screenshotNodeSelector = '.dashboard';

Review comment:
       super nit: since this is a constant, prefer SCREENSHOT_NODE_SELECTOR
   
   

##########
File path: superset-frontend/src/dashboard/components/SliceHeaderControls.jsx
##########
@@ -87,6 +87,8 @@ const RefreshTooltip = styled.div`
   color: ${({ theme }) => theme.colors.grayscale.base};
 `;
 
+const screenshotNodeSelector = '.dashboard-component-chart-holder';

Review comment:
       super nit: since this is a constant, prefer `SCREENSHOT_NODE_SELECTOR`




----------------------------------------------------------------
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:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to