Color and thickness

3 posts, 0 answers
  1. Louis
    Louis avatar
    85 posts
    Member since:
    Jun 2011

    Posted 07 Jan 2017 Link to this post


    1) How I can change the color slider when user select another value of the slide.  Example, selecting 1 the slider become yellow, selecting 2 it's become red, etc.  I have to use the sliderChange I guess.  But what are the JS instructions?

    2)  And it's possible the change the thickness of the slider?


    Thank a lot for your precious help.

  2. Eduardo Serra
    Eduardo Serra avatar
    119 posts

    Posted 09 Jan 2017 Link to this post

    Hello Louis,

    The color of the slider can be changed using the following using CSS, and we can dinamically change it, when the change event is triggered, using jQuery like this:

    $(".k-slider-track", top).css("background-color", "#00ff00");
    $(".k-slider-selection", top).css("background-color", "#00ff00");

    I have prepared a sample in the Kendo UI Dojo that demonstrates this approach; you can take a look at it here.

    Regarding your second question, there is no support for changing the width of our Kendo UI Slider; I encourage you to participate in the Kendo UI Feedback and Feature Request Portal and, if enough people vote on your request, developers might include it in future releases of Kendo UI Professional.

    I hope this helps!

    Eduardo Serra
    Telerik by Progress
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
  3. Louis
    Louis avatar
    85 posts
    Member since:
    Jun 2011

    Posted 09 Jan 2017 in reply to Eduardo Serra Link to this post

    A BIG THANK YOU Eduardo .


    This information really help me.  Happy new year to you and all the telerik members.

Back to Top