Slider: Disable changing slider value with Click to use only dragging.

Created on 1 Feb 2017  路  4Comments  路  Source: react-component/slider

How is it possible in your excellent component? May be I can do it by my self if you help me with some advice.

Most helpful comment

@ihhha You can use css pointer-events (http://caniuse.com/#search=pointer-events) to have this functionality.

.rc-slider {
    pointer-events: none;
    .rc-slider-handle {
        pointer-events: auto;
    }
}

All 4 comments

I don't understand your use case, it's weirdo, can you provide more info?

Close for no response.

@ihhha You can use css pointer-events (http://caniuse.com/#search=pointer-events) to have this functionality.

.rc-slider {
    pointer-events: none;
    .rc-slider-handle {
        pointer-events: auto;
    }
}

@kvrmd Thanks. Finally I've used CSS. But just decrease rc-slider height so it's hard to click on it to move handler )

Was this page helpful?
0 / 5 - 0 ratings