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

Fixed overflowed scroll sidenav on desktop #62

Merged
merged 1 commit into from
Jan 11, 2021

Conversation

Smankusors
Copy link
Member

Proposed changes

There's additional 60px because it's problem with mobile devices. Without it, when hiding the address bar, there's some kind of jumpy effect, or rather re-rendering effect that makes UX not really smooth. But this fix comes with another issue, see Dogfalo#4719. It's fixed on mobile. But in desktop, the scrollbar doesn't look good.

So, instead of using calc(100% + 60px), I think using 100vh is more appropriate. Here is an article explaining this.

I also deleted a temporary fix (I can't find the documentation about -moz-calc thing)

I hope this didn't create another new issue... so tell me if you found one 😉

Screenshots (if appropriate) or codepen:

Before : https://codepen.io/smankusors/pen/VwKdwPG

After : https://codepen.io/smankusors/pen/NWRzWjq

Types of changes

  • Bug fix (non-breaking change which fixes an issue).
  • New feature (non-breaking change which adds functionality).
  • Breaking change (fix or feature that would cause existing functionality to change).

Checklist:

  • I have read the CONTRIBUTING document.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@DanielRuf
Copy link

-moz-calc is an old / deprecated vendor-prefixed version of calc for old Mozilla Firefox versions.

@Smankusors
Copy link
Member Author

-moz-calc is an old / deprecated vendor-prefixed version of calc for old Mozilla Firefox versions.

and.... this is.... Firefox at 2010? I think we can safely delete this, right?

@DanielRuf
Copy link

Correct, see also https://caniuse.com/calc

Copy link

@Pierstoval Pierstoval left a comment

Choose a reason for hiding this comment

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

I think it's okay to move forward on this 👍

Especially since next versions of Materialize are not likely to be used by older systems IMO

Copy link

@DanielRuf DanielRuf left a comment

Choose a reason for hiding this comment

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

LGTM

@DanielRuf DanielRuf merged commit 35d694e into materializecss:v1-dev Jan 11, 2021
@Smankusors Smankusors deleted the fix-sidenav-height branch September 5, 2021 10:01
@Smankusors Smankusors added the bug Something isn't working label Apr 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working component: sidenav
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants