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 2022/05/19 10:11:40 UTC

[GitHub] [superset] villebro commented on a diff in pull request #20126: feat(dashboard): Add create chart button in dashboard edit mode

villebro commented on code in PR #20126:
URL: https://github.com/apache/superset/pull/20126#discussion_r876872786


##########
superset-frontend/src/dashboard/components/SliceAdder.jsx:
##########
@@ -240,6 +271,18 @@ class SliceAdder extends React.Component {
       MARGIN_BOTTOM;
     return (
       <div className="slice-adder-container">
+        <NewChartButtonContainer>
+          <NewChartButton
+            buttonStyle="link"
+            buttonSize="xsmall"
+            onClick={() =>
+              window.open('/chart/add', '_blank', 'noopener noreferrer')

Review Comment:
   It could be interesting to implement broadcasting so that the list is updated when a chart is created the chart list is refreshed when the new chart is saved: https://developer.mozilla.org/en-US/docs/Web/API/Broadcast_Channel_API



-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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