react-native-slider icon indicating copy to clipboard operation
react-native-slider copied to clipboard

Styling the slider

Open kimsean opened this issue 3 years ago • 15 comments

where can i find the StyleSheet.js and ViewStylePropTypes.js in the package ?

kimsean avatar Jan 08 '21 06:01 kimsean

Second that - how can we customize this?

lucidlive avatar Jan 13 '21 18:01 lucidlive

Any updates on this? I have no clue how I can style the slider in a more sophisticated way than just changing three colors.

RRaideRR avatar Feb 01 '21 12:02 RRaideRR

There are 3 props to set colours of the slider

minimumTrackTintColor
maximumTrackTintColor
thumbTintColor

Rest of view styles can be passed with style prop

wojteg1337 avatar Feb 01 '21 16:02 wojteg1337

Yes, but which props can be used? They refer to stylesheet.js

krini avatar Feb 16 '21 09:02 krini

Was also looking around for StyleSheet.js and ViewStylePropTypes.js but could not find it in this repo...

For instance, if i want to change the size of the slider handel, how can i do that?

mansdahlstrom1 avatar Feb 23 '21 16:02 mansdahlstrom1

I am also looking for that @mansdahlstrom1, have you found a way?

srinu6 avatar Mar 17 '21 08:03 srinu6

Just use another slider. You can try @sharcoux/slider but anyone will do.

Sharcoux avatar Mar 17 '21 11:03 Sharcoux

Just use another slider. You can try @sharcoux/slider but anyone will do.

That was also my solution. I used https://www.npmjs.com/package/rn-range-slider

krini avatar Mar 17 '21 12:03 krini

I am also looking for that @mansdahlstrom1, have you found a way?

No not really, sorry

mansdahlstrom1 avatar Mar 17 '21 12:03 mansdahlstrom1

I also searched for this configuration setting, but no luck. I had to look for another library

AntonRunDev avatar Feb 06 '23 13:02 AntonRunDev

Is this still the case...can we not customise the styles?

matt-dalton avatar Jul 24 '23 13:07 matt-dalton

Hi! There is still no way to change the slider handler's size?

virginiab10 avatar Aug 08 '23 20:08 virginiab10

By using the default thumb it's indeed currently still unsupported. There's still an option to use the image as a thumb, and to customize the size of the image. Thank you for the patience!

BartoszKlonowski avatar Aug 09 '23 00:08 BartoszKlonowski

By using the default thumb it's indeed currently still unsupported. There's still an option to use the image as a thumb, and to customize the size of the image. Thank you for the patience!

Thanks for the response! Could you give me a code example where you pass an image as a prop?

virginiab10 avatar Aug 09 '23 00:08 virginiab10

@virginiab10 There are plenty of examples around, especially in the example app of this repository. You can check these lines of example app or this line from the rn-slider-repro-app I prepared for this repository.

BartoszKlonowski avatar Aug 09 '23 09:08 BartoszKlonowski