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

Allow resizing width of SQL Lab left bar / editor #8099

Merged
merged 5 commits into from
Aug 26, 2019

Conversation

betodealmeida
Copy link
Member

@betodealmeida betodealmeida commented Aug 23, 2019

CATEGORY

Choose one

  • Bug Fix
  • Enhancement (new features, refinement)
  • Refactor
  • Add tests
  • Build / Development Environment
  • Documentation

SUMMARY

This PR adds a gutter for resizing the width of SQL Lab left bar and editor. Currently, the setting is not persisted, since in the cases we observed the use was more circumstantial.

BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

sqllab_resize_width

Note that the gutter is not vertically centered, which I found more intuitive. I can move it to the center.

TEST PLAN

See video above.

ADDITIONAL INFORMATION

  • Has associated issue:
  • Changes UI
  • Requires DB Migration.
  • Confirm DB Migration upgrade and downgrade tested.
  • Introduces new feature or API
  • Removes existing feature or API

REVIEWERS

@etr2460 @graceguo-supercat

<Split
ref={this.sqlEditorRef}
className={this.props.hideLeftBar ? 'SqlEditor-expanded' : 'SqlEditor'}
sizes={[INITIAL_WEST_PERCENT, INITIAL_EAST_PERCENT]}
Copy link

@graceguo-supercat graceguo-supercat Aug 23, 2019

Choose a reason for hiding this comment

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

do you want user's setting be persist when they reload page or switch tabs?

Copy link
Member Author

Choose a reason for hiding this comment

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

I don't think this should be persisted, since in my experience it's more circumstantial. For some of our tables the metadata is too big and users want momentarily to expand it. What are your thoughts?

@betodealmeida betodealmeida changed the title [WIP] Allow resizing width of SQL Lab left bar / editor Allow resizing width of SQL Lab left bar / editor Aug 23, 2019
@betodealmeida betodealmeida added enhancement:request Enhancement request submitted by anyone from the community .css sqllab Namespace | Anything related to the SQL Lab lyft Related to Lyft labels Aug 23, 2019
Copy link

@graceguo-supercat graceguo-supercat left a comment

Choose a reason for hiding this comment

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

LGTM

@codecov-io
Copy link

Codecov Report

Merging #8099 into master will decrease coverage by 0.03%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master   #8099      +/-   ##
=========================================
- Coverage   65.93%   65.9%   -0.04%     
=========================================
  Files         485     485              
  Lines       22887   22925      +38     
  Branches     2521    2538      +17     
=========================================
+ Hits        15090   15108      +18     
- Misses       7666    7685      +19     
- Partials      131     132       +1
Impacted Files Coverage Δ
superset/assets/src/SqlLab/constants.js 100% <100%> (ø) ⬆️
...uperset/assets/src/SqlLab/components/SqlEditor.jsx 57.66% <100%> (+2.27%) ⬆️
.../src/explore/components/ControlPanelsContainer.jsx 68.35% <0%> (-11.65%) ⬇️
...uperset/assets/src/SqlLab/components/SouthPane.jsx 85.71% <0%> (-5.72%) ⬇️
superset/assets/src/explore/controlUtils.js 94.8% <0%> (-2.21%) ⬇️
superset/assets/src/explore/store.js 92.3% <0%> (-1.45%) ⬇️
superset/sql_lab.py 76.84% <0%> (-0.17%) ⬇️
superset/assets/src/explore/controls.jsx 42.85% <0%> (ø) ⬆️
...rset/assets/src/explore/reducers/exploreReducer.js 33.33% <0%> (+1.75%) ⬆️

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 279307c...e8fe5b9. Read the comment docs.

@betodealmeida betodealmeida merged commit ed3360b into apache:master Aug 26, 2019
graceguo-supercat pushed a commit to airbnb/superset-fork that referenced this pull request Aug 29, 2019
etr2460 pushed a commit to etr2460/incubator-superset that referenced this pull request Aug 30, 2019
@timalive
Copy link

timalive commented Jun 8, 2020

I am strugging to get this to work in version 35.2. Any ideas why that could be?

@mistercrunch mistercrunch added 🏷️ bot A label used by `supersetbot` to keep track of which PR where auto-tagged with release labels 🚢 0.35.0 labels Feb 28, 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 enhancement:request Enhancement request submitted by anyone from the community lyft Related to Lyft size/M sqllab Namespace | Anything related to the SQL Lab 🚢 0.35.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants