Skip to content

[dashboard scoped filter] Improve scrollbar inside modal - #8553

Merged
graceguo-supercat merged 3 commits into
feature--dashboard-scoped-filterfrom
scoped-filter-modal-improvement
Nov 15, 2019
Merged

graceguo-supercat merged 3 commits into
feature--dashboard-scoped-filterfrom
scoped-filter-modal-improvement

Conversation

@graceguo-supercat

@graceguo-supercat graceguo-supercat commented Nov 13, 2019 •

Copy link
Copy Markdown

CATEGORY

Choose one

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

SUMMARY

A few UI updates based on designer's review:

  1. show tab name and filter name as regular font-weight, not bold. Only show All filters and All charts bold font.
  2. improve scrollbar behavior when content is long:

Before: scroll bar is outside of modal
oXKrPLR0no

After: modal should have fixed height. when content is overflow, should show scroll bar inside modal, and keep modal header and footer in the fixed position.
ZfYLu60NAF

TEST PLAN

manual test

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

@kenchendesign

@rusackas

Copy link
Copy Markdown
Member

@graceguo-supercat This looks like a good improvement to me! I'm wondering about a couple enhancements, which I can look at in a follow-up PR if you'd like:

• Would it be even better if just the individual tree were to scroll? In this case, that would be just the right side's tree. Optionally, it could even leave the Expand/Collapse/Search pinned to the top.

• I see the Less file has some significant-looking static values (128px, 64px, ...). I didn't look super closely at these, but if they're making space for other elements (i.e. a header), would it add value to use Less variables, so that we can tweak more easily in the future? I've been meaning to make a pass at the Less files in general looking for this sort of thing, hoping we can use more Less variables for "style guide" kind of things.

@rusackas rusackas left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM, aside from a couple small areas of potential enhancement I mentioned in a separate comment.

@graceguo-supercat
graceguo-supercat force-pushed the scoped-filter-redux-v2 branch 2 times, most recently from 015a390 to 83269e9 Compare November 13, 2019 22:35
@graceguo-supercat
graceguo-supercat changed the base branch from scoped-filter-redux-v2 to feature--dashboard-scoped-filter November 13, 2019 22:36
@graceguo-supercat
graceguo-supercat changed the base branch from feature--dashboard-scoped-filter to scoped-filter-redux-v2 November 14, 2019 06:07
@graceguo-supercat
graceguo-supercat changed the base branch from scoped-filter-redux-v2 to feature--dashboard-scoped-filter November 14, 2019 06:08
@graceguo-supercat
graceguo-supercat force-pushed the scoped-filter-modal-improvement branch 5 times, most recently from b16fed4 to ef8a811 Compare November 14, 2019 06:23
@graceguo-supercat
graceguo-supercat changed the base branch from feature--dashboard-scoped-filter to scoped-filter-redux-v2 November 14, 2019 06:24
@graceguo-supercat

graceguo-supercat commented Nov 14, 2019 •

Copy link
Copy Markdown
Author

@graceguo-supercat This looks like a good improvement to me! I'm wondering about a couple enhancements, which I can look at in a follow-up PR if you'd like:

• Would it be even better if just the individual tree were to scroll? In this case, that would be just the right side's tree. Optionally, it could even leave the Expand/Collapse/Search pinned to the top.

Yes! I talked to @kenchendesign and he told me that this is standard interaction behavior for modals actually sidebar and content should scroll separately.

I added this changed!

For standardize css variables, I would like to do it when we have style guide. currently we prefer to use 8px as unit for padding/margin spacing.

@etr2460 etr2460 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

a couple css nits, otherwise lgtm


.react-checkbox-tree {
.rct-title .root {
font-weight: bold;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

i see here we're using font-weight: bold; but below it's font-weight: 700;. Can we standardize?

@graceguo-supercat graceguo-supercat Nov 14, 2019 •

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

i choose font-weight: bold. So i fixed the font-weight: 700.

@rusackas rusackas Nov 14, 2019 •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Not to sidetrack the discussion, but I'm considering if it's worth moving some of these values (and other related typographic treatments) to LESS variables, so we can use font-weight: @bold and set/theme that to be 700 (or whatever!) globally. I can address that separately, just floating the idea ;)

@graceguo-supercat graceguo-supercat changed the title [dashboard scoped filter] Improve scroll inside modal [dashboard scoped filter] Improve scrollbar inside modal Nov 14, 2019
@graceguo-supercat
graceguo-supercat force-pushed the scoped-filter-modal-improvement branch from ed6655a to ad871eb Compare November 14, 2019 21:03
@codecov-io

Copy link
Copy Markdown

Codecov Report

Merging #8553 into scoped-filter-redux-v2 will not change coverage.
The diff coverage is 0%.

Impacted file tree graph

@@                  Coverage Diff                   @@
##           scoped-filter-redux-v2   #8553   +/-   ##
======================================================
  Coverage                      66%     66%           
======================================================
  Files                         474     474           
  Lines                       23197   23197           
  Branches                     2484    2484           
======================================================
  Hits                        15311   15311           
  Misses                       7728    7728           
  Partials                      158     158
Impacted Files Coverage Δ
...sets/src/dashboard/util/getFilterFieldNodesTree.js 0% <ø> (ø) ⬆️
...ponents/filterscope/renderFilterFieldTreeNodes.jsx 0% <ø> (ø) ⬆️
...ard/components/filterscope/FilterScopeSelector.jsx 1.45% <0%> (ø) ⬆️

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 5f42413...ad871eb. Read the comment docs.

@graceguo-supercat
graceguo-supercat changed the base branch from scoped-filter-redux-v2 to feature--dashboard-scoped-filter November 15, 2019 01:09
@graceguo-supercat
graceguo-supercat force-pushed the scoped-filter-modal-improvement branch from ad871eb to 7d3b7ee Compare November 15, 2019 01:23
@graceguo-supercat
graceguo-supercat force-pushed the scoped-filter-modal-improvement branch from 7d3b7ee to ccd1b59 Compare November 15, 2019 01:27
@graceguo-supercat
graceguo-supercat merged commit 26e6b6f into feature--dashboard-scoped-filter Nov 15, 2019
graceguo-supercat pushed a commit that referenced this pull request Nov 18, 2019
* [WIP][dashboard scoped filter] part 1: scope selector modal (#8557)

* filter scope selector modal

* add single-field-edit in multi-edit mode switch

* fix code review comments (round 1)

* refactory after design review

* fix a few props initial value

* [WIP][dashboard scoped filter] part 2: add algorithm to convert checked ids to scope object (#8564)

* convert ids to scope object

* use lodash helpers to make code readable

* [WIP][dashboard scoped filter] part 3: merge filter scope settings into dashboard redux state (#8522)

* merge filter scope settings into dashboard redux state

* fix/add unit tests

* minor bug fixes

* fix save filter Scopes behavior

* resolve review comments

* fix save filter scope settings

* minor comments

* [dashboard scoped filter] Improve scrollbar inside modal (#8553)

* improve scroll inside modal

* make left pane and right pane scroll separately

* fix review comments

* force show filter_box as unchecked (#8587)
@graceguo-supercat
graceguo-supercat deleted the scoped-filter-modal-improvement branch November 25, 2019 23:31
qfcwell pushed a commit to qfcwell/superset that referenced this pull request May 12, 2026
* [WIP][dashboard scoped filter] part 1: scope selector modal (apache#8557)

* filter scope selector modal

* add single-field-edit in multi-edit mode switch

* fix code review comments (round 1)

* refactory after design review

* fix a few props initial value

* [WIP][dashboard scoped filter] part 2: add algorithm to convert checked ids to scope object (apache#8564)

* convert ids to scope object

* use lodash helpers to make code readable

* [WIP][dashboard scoped filter] part 3: merge filter scope settings into dashboard redux state (apache#8522)

* merge filter scope settings into dashboard redux state

* fix/add unit tests

* minor bug fixes

* fix save filter Scopes behavior

* resolve review comments

* fix save filter scope settings

* minor comments

* [dashboard scoped filter] Improve scrollbar inside modal (apache#8553)

* improve scroll inside modal

* make left pane and right pane scroll separately

* fix review comments

* force show filter_box as unchecked (apache#8587)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants