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): allow users to resize the markdown widget easier #19839

Merged

Conversation

cccs-Dustin
Copy link
Contributor

SUMMARY

This PR was made to fix the issue where users were not easily able to resize the column width of the Markdown widget when editing a dashboard. From my investigation of the code, I found that there was indeed a container handle on the right side of a Markdown widget, it was just very narrow compared to the right side container handles of the other charts within a dashboard.

To fix this issue, I just needed to modify the resizable.less file so that .resizable-container-handle--right behaves the same way as .resizable-container-handle--bottom.

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

Before:
(The resize cursor is not easily selectable, as the handle to resize it is very narrow)
Very Small Column Resize Selection Area

After:
(The resize cursor is now much easier to select, as the handle for it has been widened and is now the same size as the handle on the bottom of the widget)
After Fix - Resize Markdown Width

TESTING INSTRUCTIONS

  1. Go to a dashboard which contains a Markdown widget, or add a Markdown widget to a new or existing dashboard.
  2. Select the "Edit dashboard" button (pencil icon in the top right of the page).
  3. Try to adjust the width of the markdown widget.
  4. You will notice that it is now much easier to select the resize handle compared to before the code changes.

ADDITIONAL INFORMATION

@codecov
Copy link

codecov bot commented Apr 25, 2022

Codecov Report

Merging #19839 (b643225) into master (a1bd5b2) will increase coverage by 0.00%.
The diff coverage is 100.00%.

❗ Current head b643225 differs from pull request most recent head b86c34e. Consider uploading reports for the commit b86c34e to get more accurate results

@@           Coverage Diff           @@
##           master   #19839   +/-   ##
=======================================
  Coverage   66.55%   66.55%           
=======================================
  Files        1692     1692           
  Lines       64801    64802    +1     
  Branches     6657     6657           
=======================================
+ Hits        43128    43129    +1     
  Misses      19973    19973           
  Partials     1700     1700           
Flag Coverage Δ
javascript 51.25% <ø> (ø)

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

Impacted Files Coverage Δ
superset-frontend/src/SqlLab/actions/sqlLab.js 60.39% <ø> (ø)
superset/utils/csv.py 97.67% <100.00%> (+0.05%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a1bd5b2...b86c34e. Read the comment docs.

Copy link
Member

@etr2460 etr2460 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this seems reasonable, assuming you've tested this for all charts/dashboard components (and not only markdown)

@cccs-Dustin
Copy link
Contributor Author

this seems reasonable, assuming you've tested this for all charts/dashboard components (and not only markdown)

I tested with all of the charts/dashboard components. It seems to work correctly for all of them now, not just everything but the markdown component.

@etr2460 etr2460 merged commit 7d3437a into apache:master May 4, 2022
hughhhh pushed a commit to hve-labs/superset that referenced this pull request May 11, 2022
@cccs-Dustin cccs-Dustin deleted the fix-column-resize-of-markdown branch May 11, 2022 17:10
philipher29 pushed a commit to ValtechMobility/superset that referenced this pull request Jun 9, 2022
@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 2.0.0 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.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants