superset icon indicating copy to clipboard operation
superset copied to clipboard

feat: Explore chart link in a new tab on Dashboard

Open opus-42 opened this issue 2 years ago • 1 comments

Feat(dashboard): Explore chart button in a new tab

SUMMARY

The "explore chart" button used to open in a new tab in previous 1.X versions. This features was useful as it easily allow editor to modify dashboard while keeping the dashboard view on the original tab. This small PR modify current behavior to open Explore Chart in a new tab.

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

TESTING INSTRUCTIONS

  1. Go to a Dashboard
  2. In the Slice Dropdown Menu, click on "Explore Chart"
  3. This will open a new tab

ADDITIONAL INFORMATION

  • [X] Has associated issue: see #20646
  • [ ] Required feature flags:
  • [X] Changes UI
  • [ ] Includes DB Migration (follow approval process in SIP-59)
    • [ ] Migration is atomic, supports rollback & is backwards-compatible
    • [ ] Confirm DB migration upgrade and downgrade tested
    • [ ] Runtime estimates and downtime expectations provided
  • [ ] Introduces new feature or API
  • [ ] Removes existing feature or API

opus-42 avatar Sep 19 '22 21:09 opus-42

Codecov Report

Merging #21521 (7b6f02f) into master (f27e20e) will not change coverage. The diff coverage is n/a.

@@           Coverage Diff           @@
##           master   #21521   +/-   ##
=======================================
  Coverage   66.66%   66.66%           
=======================================
  Files        1793     1793           
  Lines       68499    68499           
  Branches     7278     7278           
=======================================
  Hits        45666    45666           
  Misses      20969    20969           
  Partials     1864     1864           
Flag Coverage Δ
javascript 52.82% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...dashboard/components/SliceHeaderControls/index.tsx 70.21% <ø> (ø)

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

codecov[bot] avatar Sep 19 '22 22:09 codecov[bot]

Cmd-click (alt-click on Windows) should open in a new tab. It is well documented that same-tab should be the default.

philihp avatar Sep 20 '22 22:09 philihp

Like @philihp said, it's a link so user can just cmd+click (or, alternatively, click on chart's title, which does the same thing) to open in a new tab. The old behaviour was changed to stay in the same tab by default, as it grants us the benefits of recently implemented Single Page App architecture.

kgabryje avatar Sep 26 '22 15:09 kgabryje

Clear for me. Thank you for your comments

opus-42 avatar Sep 26 '22 16:09 opus-42