Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(dashboard): drag preview not working #21432

Merged
merged 1 commit into from
Sep 12, 2022

Conversation

stephenLYZ
Copy link
Member

SUMMARY

Currently the drag preview of react-dnd was broken since we introduce position: 'fixed' inside the drag container from #21198. To fix this, we use createPortal to ensure that the parent container is not affected and that the dropdown is also displayed properly.

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

before

2022-09-12.12.22.42.mov

after

2022-09-12.12.11.41.mov

TESTING INSTRUCTIONS

ADDITIONAL INFORMATION

  • Has associated issue:
  • Required feature flags:
  • 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

@codecov
Copy link

codecov bot commented Sep 12, 2022

Codecov Report

Merging #21432 (bb8eed6) into master (7401f15) will not change coverage.
The diff coverage is 100.00%.

@@           Coverage Diff           @@
##           master   #21432   +/-   ##
=======================================
  Coverage   66.56%   66.56%           
=======================================
  Files        1791     1791           
  Lines       68591    68591           
  Branches     7319     7319           
=======================================
  Hits        45656    45656           
  Misses      21046    21046           
  Partials     1889     1889           
Flag Coverage Δ
javascript 52.74% <100.00%> (ø)

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

Impacted Files Coverage Δ
...frontend/src/components/Chart/ChartContextMenu.tsx 44.00% <100.00%> (ø)

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

@michael-s-molina
Copy link
Member

michael-s-molina commented Sep 12, 2022

@stephenLYZ I'm still able to reproduce the issue. If I remove ChartContextMenu completely, the error still happens so I don't think it's related to that component.

Screen.Recording.2022-09-12.at.7.33.44.AM.mov

@stephenLYZ
Copy link
Member Author

stephenLYZ commented Sep 12, 2022

@stephenLYZ I'm still able to reproduce the issue. If I remove ChartContextMenu completely, the error still happens so I don't think it's related to that component.

Screen.Recording.2022-09-12.at.7.33.44.AM.mov

@michael-s-molina This is actually another problem with the pivot table v2, because it also uses fixed position , and we may need to use another PR to solve it. But for the rest of the chart, everything looks fine. During my troubleshooting, I found that this commit was fine before, but afterwards the behavior was not as expected, so I'm guessing that this is what's affecting it.

@michael-s-molina
Copy link
Member

@michael-s-molina This is actually another problem with the pivot table v2, because it also uses fixed position , and we may need to use another PR to solve it. But for the rest of the chart, everything looks fine. During my troubleshooting, I found that this commit was fine before, but afterwards the behavior was not as expected, so I'm guessing that this is what's affecting it.

Oh, thanks for clarifying that. LGTM

@stephenLYZ stephenLYZ merged commit 99628d3 into apache:master Sep 12, 2022
@mistercrunch
Copy link
Member

200w

@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 2.1.0 and removed 🚢 2.1.3 labels Mar 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels size/XS 🚢 2.1.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants