React-custom-scrollbars: Is there a way to make the scroll bar be hidden when the contents are not scrollable?

Created on 11 Mar 2018  路  2Comments  路  Source: malte-wessel/react-custom-scrollbars

I would like to hide (display: none) the scrollbar when the contents are not scrollable, i.e. when the content fits within the container. Any suggestions?

Most helpful comment

Adding this hideTracksWhenNotNeeded does not fully hide the scrollbar container that contains the track and thumb. This means that the scrollbar container interferes with any content that is on a lower z-index to the scrollbar, for example.

All 2 comments

@joetidee There is a hideTracksWhenNotNeeded prop you can use.

Adding this hideTracksWhenNotNeeded does not fully hide the scrollbar container that contains the track and thumb. This means that the scrollbar container interferes with any content that is on a lower z-index to the scrollbar, for example.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

leofle picture leofle  路  4Comments

luxotus picture luxotus  路  4Comments

hank7444 picture hank7444  路  5Comments

mhemrg picture mhemrg  路  4Comments

bunkat picture bunkat  路  5Comments