React-native-slider: Vertical Slider

Created on 12 May 2019  路  11Comments  路  Source: callstack/react-native-slider

Describe the Feature

Same slider but for vertical orientation
Is it supported?

feature request

Most helpful comment

We got it working with:

transform: [ { rotate: "-90deg" } ]

Note the _negative_ 90 degrees. That helps slide things up and down in the correct direction.

vertical slider

All 11 comments

You can probably rotate view with your styles tho.

<Slider style={{ transform: [{ rotate: '90deg' }] }} />

Let me know if it doesn't work, I'll be glad to reopen that.

@CHaNGeTe did you have any luck? I tried this but the sliding on Android is odd ... it's hard to get it to move and when it does it often moves in the opposite direction of the gesture.

Nope, I am considering using https://www.npmjs.com/package/rn-vertical-slider for the vertical one

We got it working with:

transform: [ { rotate: "-90deg" } ]

Note the _negative_ 90 degrees. That helps slide things up and down in the correct direction.

vertical slider

I want multiple vertical sliders side by side with steps. Also, want to change the thumb with a different image. Using this library, if you rotate the slider, it keeps the width and height size same as before and so it doesn't work if you want multiple sliders in a row. Please provide any solution.

Meanwhile there is a nice tutorial here to make a vertical slider.

I am not able to set height and width of slider. It is still behaving as horizontal slider in styles

Link to snack reproducible code:
https://snack.expo.io/@yajana/slider

I had to use React Native Elements Slider with orientation= vertical

orientation= vertical

Hi. Could you specify how you get vertical slider from React Native Elements Slider?
My code is
` style={{ flex: 1 }}
>

    <Slider
      orientation="vertical"
      trackStyle={{ height: 10, backgroundColor: "lightgrey" }}
      thumbStyle={{ height: 40, width: 40, backgroundColor: "red" }}
    />

`

But my slider is still horizontal

Still not able to allign the slider vertically, any luck anybody?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

akrger picture akrger  路  6Comments

pdandradeb picture pdandradeb  路  5Comments

gdoudeng picture gdoudeng  路  5Comments

EJohnF picture EJohnF  路  8Comments

a-koka picture a-koka  路  3Comments