Slider: customize colors

Created on 7 Feb 2019  路  1Comment  路  Source: react-component/slider

I tried everything on the issues page to customize it but none of it worked.
I need help guys. I need to change the colors

Most helpful comment

Using handleStyle and trackStyle totally works for me. Found this : https://github.com/react-component/slider/issues/288

<Range
      min={0}
      max={2000}
      step={50}
      defaultValue={[100, 800]}
      value={state}
      allowCross={false}
      onChange={setState}
      handleStyle={[
        { backgroundColor: "yellow", borderColor: "green" },
        { backgroundColor: "red", borderColor: "green" }
      ]}
      trackStyle={[
        { backgroundColor: "yellow", borderColor: "green" },
        { backgroundColor: "red" }
      ]}
    />

>All comments

Using handleStyle and trackStyle totally works for me. Found this : https://github.com/react-component/slider/issues/288

<Range
      min={0}
      max={2000}
      step={50}
      defaultValue={[100, 800]}
      value={state}
      allowCross={false}
      onChange={setState}
      handleStyle={[
        { backgroundColor: "yellow", borderColor: "green" },
        { backgroundColor: "red", borderColor: "green" }
      ]}
      trackStyle={[
        { backgroundColor: "yellow", borderColor: "green" },
        { backgroundColor: "red" }
      ]}
    />
Was this page helpful?
0 / 5 - 0 ratings