React-custom-scrollbars: RTL support?

Created on 11 Jul 2016  路  6Comments  路  Source: malte-wessel/react-custom-scrollbars

Hi there,

I was wondering if there is any plan for implementing RTL support?

question

Most helpful comment

you can use this option
renderView={props => (

);}

All 6 comments

Hey! What exactly do you need?

@malte-wessel, i am too interested in RTL, this means that if you have direction="rtl" you will see both scrollbars - native & custom< because you hiding native scrollbar with margin right, but for RTL you need the opposite.

@malte-wessel currently, as @Hazantip mentioned, one of the scrollbars appears on the left in rtl. This results in 2 scrollbars showing in both sides.

I believe that the expected behavior is for the scrollbar(s) to appear in the right both in left to right and right to left because this is the default behavior on the web as I see it in every rtl supported site.

you can use this option
renderView={props => (

);}

Hi @HamidBasri, I have the same issue,
renderView={props => (<div {...props} style={{ ...props.style, marginLeft: props.style.marginRight, marginRight: 0, }} /> );}
The solution that you proposed only hide the legacy scrollbar but the custom scrollbar is still showing on the right side instead of on the left.

Thanks!

Hi @HamidBasri, I have the same issue,
renderView={props => (<div {...props} style={{ ...props.style, marginLeft: props.style.marginRight, marginRight: 0, }} /> );}
The solution that you proposed only hide the legacy scrollbar but the custom scrollbar is still showing on the right side instead of on the left.

Thanks!

Hi @ilanbd, you should set bottom and top props too!

The default value I guess is 2px;

In my case I set it like:
style={{...scrollProps.style, left: '2px', bottom: '20px', top: '20px', borderRadius:'3px'}}`

Cheers!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

limbosounds picture limbosounds  路  4Comments

simonkberg picture simonkberg  路  3Comments

ilfa picture ilfa  路  5Comments

magnetronnie picture magnetronnie  路  3Comments

Amdingo picture Amdingo  路  4Comments