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

for inspiration - scrollbars #173

Closed
cintaccs opened this issue Feb 16, 2020 · 3 comments
Closed

for inspiration - scrollbars #173

cintaccs opened this issue Feb 16, 2020 · 3 comments

Comments

@cintaccs
Copy link

Description

I used

/* width */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

/* Track */
::-webkit-scrollbar-track {
    background: white;
    border-left: 1px solid whitesmoke;
}

/* Handle */
::-webkit-scrollbar-thumb {
    background: whitesmoke;
    background: gainsboro;
}

/* Handle on hover */
::-webkit-scrollbar-thumb:hover {
    background: dimgray;
}

to get rid of the web effect of the scroll bars. I know it is only webkit / chrome / edge .. but ...

@motss
Copy link
Owner

motss commented Feb 16, 2020

Does it cover the UI on other OSes like Linux and Windows? I've yet to try this.

@cintaccs
Copy link
Author

cintaccs commented Feb 16, 2020

no it is ignored on FF e.g.
Screenshot 2020-02-16 at 17 13 39

and in chrome

Screenshot 2020-02-16 at 17 13 55

again the coloring can be discussed - but getting rid of the 90´s browserlook is generally appreciated :-)

I see no difference in this behavior in between Mac OS Chrome/Safari and Windows Chrome (as I recall).

@motss
Copy link
Owner

motss commented Feb 26, 2020

I decided to add this suggestion to mimic that of Android datepicker's scrollbar.

The following CSS works for all Webkit browsers and modern Firefox:

.year-list-view__full-list {
  max-height: calc(48px * 7);
  overflow-y: auto;

  scrollbar-color: var(--app-datepicker-scrollbar-thumb-bg-color, rgba(0, 0, 0, .35)) rgba(0, 0, 0, 0);
  scrollbar-width: thin;
}
.year-list-view__full-list::-webkit-scrollbar {
  width: 8px;
  background-color: rgba(0, 0, 0, 0);
}
.year-list-view__full-list::-webkit-scrollbar-thumb {
  background-color: var(--app-datepicker-scrollbar-thumb-bg-color, rgba(0, 0, 0, .35));
  border-radius: 50px;
}
.year-list-view__full-list::-webkit-scrollbar-thumb:hover {
  background-color: var(--app-datepicker-scrollbar-thumb-hover-bg-color, rgba(0, 0, 0, .5));
}

👍 Thanks for such suggestion!

@motss motss mentioned this issue Feb 26, 2020
23 tasks
@motss motss closed this as completed in 69a32da Feb 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants