RadzenSlider step is applied to base 0, instead of Min value

Hi everybody,

I have the following slider:

<RadzenSlider TValue="int" Style="width: 70%; margin-top: 12px" Min="110" Max="560" Step="45" Value="380" Placeholder="Specify ventilation grill width" Change=@(args => OnValueChanged(args, PropertyWeb.Property.ConstraintTypeId)) />

When I move the slider from its default position to left, the next value is 360. I would expect it to be 335. My analysis says that the control applies the step to base 0, instead of Min value.

Is this a bug, or do you know a workaround other than programming an individual logic around?

Thanks.

Regards, Martin

Push up a little bit.

Hey @refactorer,

Radzen.Blazor is open source released under MIT license. We accept pull requests!

@enchev Hey Vladimir,

Good idea :wink:

Unfortunately, I was not able to compile the whole solution so I could not really run the demo project in order to see, if my changes are working. Therefore, I don't want to post a pull request. But I upload the changed file as an attachement to this post. I think, this should do the trick, while preserving existing code running as usual. Please let me know, if you are fine with this as well.

RadzenSlider.razor.zip (2.8 KB)

Has anybody reviewed my work?

Hey @refactorer,

We've not reviewed your project. How do we know what you've changed? Do you want us to compare file by file? Please use GitHub to submit your pull request as all other contributors do.

Hey, @enchev
Well, I thought that if I only provide the file I changed, it would not be that heavy to know what I've changed. :wink: But ok, I'll send a pull request, if you are more comfortable with.

Done. https://github.com/radzenhq/radzen-blazor/pull/318

We couldn't accept the pull request (reasons described in my comment). We will however change the default behavior to be what you are requesting - it seems to be what <input type="rage"> does.

Hi @korchev

Your help is very apreciated. Thank you.