question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Slider range points both at start of bar when rendered

See original GitHub issue

Steps to reproduce

html `

<div ng-controller="BudgetCtrl" class="md-accent"> <article> Min Value:
Max Value:
<rzslider rz-slider-model="minRangeSlider.minValue" rz-slider-high="minRangeSlider.maxValue" rz-slider-options="minRangeSlider.options"></rzslider> </article> </div>`

js `
app.controller(‘BudgetCtrl’, function ($scope, $timeout) {

    //Range slider config
    $scope.minRangeSlider = {
        minValue: 180,
        maxValue: 320,
        options: {
            floor: 100,
            ceil: 800,
            step: 20,
            showSelectionBar: true,
            getSelectionBarColor: function(value) {
                return '#ff8351';
            },
            getPointerColor: function(value) {
                return '#ff8351';
            },
            translate: function(value) {
                return '$' + value;
            }
        }
    };

    $scope.refreshSlider = function() {
        $timeout(function (){
           $scope.$broadcast('rzSliderForceRender');
        });
    };
});`

Expected behaviour

slider range points should be spread given configuration in two different spots on the bar.

Actual behaviour

both range points are located at the start of the bar (overlapped). When click on any part of the bar, including the point itself, the points are reset to the correct spots on the bar.

(i’m a newbie to AngularJS and FE development in general so this could be my own fault)

See below for screenshot:

screen shot 2016-06-11 at 10 49 31 pm

A side question I have is how to change the color in the inner circle of the point (currently it’s always blueish). Didn’t find an API for that in the sourc ecode.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:15 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
ValentinHcommented, Jun 26, 2019

This is a different library, you should open an issue there.

0reactions
hardik-singhalcommented, Jun 26, 2019
Read more comments on GitHub >

github_iconTop Results From Across the Web

Fixed point at 0 in Slider range component - Stack Overflow
Slider has range, max, min, and two possible value. One of value is set fixed at 0, another one can drag to change...
Read more >
onchange vs. oninput for Range Sliders - Impressive Webs
I think the expected behaviour in such a case is that the value should display instantly, as the user is moving the slider,...
Read more >
<input type="range"> - HTML: HyperText Markup Language
By default, browsers render range inputs as sliders with the knob sliding left and right. To create a vertical range, wherein the knob...
Read more >
Flutter Slider widgets: A deep dive with examples
Slider is one of the basic Flutter widgets that can be used to select from a range of values by moving the slider...
Read more >
Range Slider · Issue #76 · ocornut/imgui - GitHub
I am right now creating a group with a couple of dummies, a scrollbar, and rendering two sliders on top of it. I...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found