Style scrollbar sidebar

Hello,
i made an app with ionic 6 but i can’t set a style for the sidebar scrollbar. I always get the classic browser scrollbar.

can you help me?

thank you

only content is updated

1 Like

it doesn’t work with ionic 6. I tried to update the css in several ways but nothing:
Ionic 6 Angular 14 (forked) - StackBlitz?

The scroll bar isn’t a feature of Ionic but of the web in general. You may find some stackoverflow answer if you take the time an search correctly.

solved with this css

ion-content {
–offset-bottom: auto !important;
–overflow: auto;
background: var(–ion-toolbar-background, var(–ion-background-color, #f4f5f8)) !important;
overflow: auto;

&::-webkit-scrollbar {
width: 15px;
height: 15px;
}

&::-webkit-scrollbar-track {
background: #fff;
}

&::-webkit-scrollbar-track:hover {
background: #f7f7f7;
}

&::-webkit-scrollbar-thumb {
background: #ccc;
}

&::-webkit-scrollbar-thumb:hover {
background: #94173a
}

.inner-scroll {
scrollbar-width: thin;
}
}

bump on the topic, did ionic team fixed this problem?

1 Like

Hi. Have you found the answer? :slight_smile:

Thanks for the solution, it works fine.