-
Notifications
You must be signed in to change notification settings - Fork 14.1k
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
chore: make control panel sub sections look better #24736
Conversation
97478a3
to
d86dd78
Compare
@@ -18,6 +18,8 @@ | |||
*/ | |||
import React from 'react'; | |||
import { t, RollingType, ComparisonType } from '@superset-ui/core'; | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The linter will likely whine about this extra line break, I would think.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it didn't, in python I like to add line breaks in-between external packages and local imports
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
@kasiazjc @mistercrunch Could we try something that does not include the |
@michael-s-molina I know that it's not perfect, but the line is a temp solution until we get rid of the upper case in labels (and in general in the app). With the current implementation and the number of different components and font sizes it's not easy to define a clear and easy hierarchy (we have to work with 12px font size too, because 14 is too big and overpowers the whole control panel). We had a version with line and without a line, and it seems for now the line makes the most sense (from the feedback I got), but curious to hear your opinion. Side by side mocks below: What is the perfect case scenario is this version - labels are sentence case and there is no line below subheader, but it's sadly not something that we can take up right now |
Thank you for the context @kasiazjc. I think that because of the uppercase limitation, neither solution is able to clearly define the information hierarchy at this point. I personally prefer the version without additional lines because it has less visual overload and it's more clear which items will be collapsed when I click on the collapse panel arrows. It's not a blocker for me though given that the solution to this problem lies in SIP-82. |
+1 on @michael-s-molina's #24736 (comment). I don't disagree that the UX could be improved (see SIP-82 for details) but I'm not sure the proposal outlined in this PR actually makes things clearer. Actuality I think it makes things more convoluted (due to the additional of more lines). Granted there's a margin around the horizontal lines, but I could perceive users being confused around the chevron behavior, i.e., for it's not overly apparent (without really focusing on the elements) what will be collapsed when one would close the |
Thanks for feedback @john-bodley! I hear you and @michael-s-molina and can see how the line could be confusing + it's cluttering control panel more. To be honest, internally, I've heard feedback both ways - as the hierarchy and typography is not perfect, in the end settled on this solution to try to make the subheader stand out more. Saying that, from my perspective - I think in this iteration we can get rid of the line and keep the font weight, color + spacings, as this already is a big improvement. Hopefully we will get to the next phase soon and get rid of the upper case labels, so that the control panel will be less cluttered |
ok, killing the |
building on this PR is this one -> preset-io#583 |
Recent design proposals point towards removing the uppercase usage across the board, and this PR starts the process with form labels. it builds upon apache#24736 that started to address hierarchy-is-unclear issue in Explore control panel and makes things a bit neater on top of it.
Codecov Report
@@ Coverage Diff @@
## master #24736 +/- ##
==========================================
- Coverage 68.94% 68.94% -0.01%
==========================================
Files 1901 1902 +1
Lines 73898 73902 +4
Branches 8175 8175
==========================================
+ Hits 50951 50952 +1
- Misses 20834 20837 +3
Partials 2113 2113
Flags with carried forward coverage won't be shown. Click here to find out more.
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
...rset-frontend/packages/superset-ui-chart-controls/src/components/ControlSubSectionHeader.tsx
Outdated
Show resolved
Hide resolved
f48e883
to
e03c810
Compare
(cherry picked from commit 22a0fe5)
Back in #24736, I tried to make form labels(headers) not use `text-transform: uppercase;`, but somehow it got reverted. Here I'm trying to do the same and maybe push further into tab headers.
SUMMARY
Improving the control panel section to make the hierarchy around the subsection look more clear. Currently it's unclear what is a section/sub-section/header. Bolding and adding an
<hr/>
as suggested by @kasiazjc helps quite a bitBEFORE/AFTER SCREENSHOTS OR ANIMATED GIF
before
after