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

[Drawer] Adjustments to the mini variant to improve UI/UX #30205

Closed
wants to merge 4 commits into from
Closed

[Drawer] Adjustments to the mini variant to improve UI/UX #30205

wants to merge 4 commits into from

Conversation

devzgabriel
Copy link

@devzgabriel devzgabriel commented Dec 14, 2021

@mui-pr-bot
Copy link

mui-pr-bot commented Dec 14, 2021

No bundle size changes

Generated by 🚫 dangerJS against 687772f

@devzgabriel
Copy link
Author

Before:
image

After:
image

@danilo-leal danilo-leal added component: drawer This is the name of the generic UI component, not the React module! new feature New feature or request labels Dec 14, 2021
@danilo-leal danilo-leal changed the title [docs] refactored drawer to improve UI/UX [Drawer] Adjustments to improve UI/UX Dec 14, 2021
@danilo-leal
Copy link
Contributor

Hey! Thanks for contributing :)

Although I like that on your proposal the drawer icons are now aligned with the hamburger menu icon + the spacing is symmetrical, the changes added a flick whenever opening/closing the drawer, which didn't happen previously (videos attached below). So, if you're willing to try, I guess we could explore finding out an approach to have the alignment+spacing adjusted without introducing the flickering.

drawer-before.mov
drawer-after.mov

@danilo-leal danilo-leal changed the title [Drawer] Adjustments to improve UI/UX [Drawer] Adjustments to the mini variant to improve UI/UX Dec 14, 2021
@danilo-leal danilo-leal self-requested a review December 14, 2021 16:02
@devzgabriel
Copy link
Author

@danilo-leal
Thanks for the review!
I updated the PR preventing flickering.

Copy link
Contributor

@danilo-leal danilo-leal left a comment

Choose a reason for hiding this comment

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

The flickering was solved but the slightly unaligned icons came back 😅

Screen Shot 2021-12-14 at 15 43 26

@michaldudak
Copy link
Member

I'm afraid this change can break layouts that depend on the current width of the drawer.
Additionally, IMO the components now looks worse when there's a scrollbar present (on Windows):

current:
image

proposed:
image

@devzgabriel
Copy link
Author

devzgabriel commented Dec 15, 2021

The problem with the scrollbar was solved in the last commit. That's why the slightly misaligned icons came back
Screenshot from 2021-12-15 07-24-05

But I still find PR viable because the way the button texts are hidden is more elegant at the code level.

@gurkerl83
Copy link

Hi, I used the mini-drawer variant with some pain at first :). It needed some adjustments to make it look and behave as you want it to be; for the adjusted mini-drawer to work, your screen size requires >= 'MD.'

I can not provide a link to a demo or video but how it works within an app; maybe this helps.

Link to the demo: https://millipede.me/docs/perspective/strategy
Sources: https://github.com/project-millipede/millipede-docs

Thx!

@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged label Feb 4, 2022
@siriwatknp
Copy link
Member

👋 The migration PR has been merged.

Please follow these steps to make sure that the contents are all updated. (Sorry for the inconvenience)

  1. pull latest master from upstream to your branch
  2. if your PR has changes on the *.md or demo files, you are likely to encounter conflict because all of them have been moved to the new folder.
    2.1 revert the change on those markdown files you did
    2.2 pull latest master from upstream (you should not see conflict)
    2.3 make the changes again at docs/data/material/*
  3. run yarn docs:api
    • you might see the changes in docs/pages/material/api/* if your PR touches some of the components
    • it is okay if there is no changes

If you are struggle with the steps above, feel free to tag @siriwatknp

@siriwatknp
Copy link
Member

Closed this PR (I can't update @devzgabriel's branch) and open another one with the fix)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: drawer This is the name of the generic UI component, not the React module! new feature New feature or request PR: out-of-date The pull request has merge conflicts and can't be merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants