My-slider-v2 - how to set light to off at beginning of slider

Hi.
I have a little problem that is driving me crazy.
I have created this card:

type: custom:my-slider-v2
entity: light.kontor_taklys_hl
mode: brightness
styles:
  container:
    #- border-radius: 100px
    - overflow: visible
    #- margin-top: 0px
  card:
    - height: 35px
  track:
    #- overflow: auto
    - background: black
    - border-radius: 90px
  progress:
    - background: |
        [[[
          return `rgb(${entity.attributes.rgb_color})`
        ]]]
    - border-radius: 90px
  thumb:
    - background: white
    - top: 3px
    - right: 3px
    - height: 27px
    - width: 25px
    - border-radius: 90px
    - padding: 0 5px

I looks like this:

image

All well and good so far.
And if I push it to the right, the light gets to 100% and the thumb stops where it is supposed to:

image

But when I want to turn the light off, it looks like this:

image

Pretty amazing that the thumb is able to go outside the card :slight_smile:
But how to I get it to stop here for the lights to go off:

image

Right now, that position is 10% brightness.

Thanks.

I know this is an old thread, but for anyone who searched for this… Add and play with the value of sliderMin:

sliderMin: 12

Works for me.

Daymn.
Thank you!

1 Like