plotly / dash-core-components

OBSOLETE: now part of https://github.com/plotly/dash
https://dash.plotly.com
MIT License
271 stars 145 forks source link

dcc.RangeSlider tooltip broken between 0 and 10 #919

Closed mtwichan closed 3 years ago

mtwichan commented 3 years ago

The tooltip in the dcc.RangeSlider breaks between 0 and 10, but appears to work properly in the dcc.Slider.

This issue appeared in the past for the dcc.Slider as a result of a bug with the library that dcc.Slider is wrapped around: https://github.com/plotly/dash-core-components/issues/763

If this is the case, and it appears to be fixed, than perhaps the dcc.RangeSlider library needs to be updated as well?

The top slider in the .gif below is a dcc.RangeSlider and the bottom is a dcc.Slider.

slider-issue

Sample code:

from dash import Dash
import dash_core_components as dcc
import dash_html_components as html

# Build App
app = Dash(__name__)
app.layout = html.Div([
    html.Div(
        [
            dcc.RangeSlider(
                min=-50,
                max=50,
                step=0.5,
                value=[5, 15],
                # allowCross=False,
                tooltip={"always_visible": True}
            ),
        ]
    ),
    html.Div(
        [
            dcc.Slider(
                min=0,
                max=20,
                step=0.5,
                value=5,
                tooltip={"always_visible": True}
            )
        ], style={"marginTop": "25%"})
]
)

app.run_server(port=8060, debug=True)

Dependencies:

dash==1.19.0
dash-core-components==1.15.0
dash-html-components==1.1.2
dash-renderer==1.9.0
dash-table==4.11.2

CC: @kully

mtwichan commented 3 years ago

The original component appears to be working correctly: https://ant.design/components/slider/#header

ant1j commented 3 years ago

still an issue for me as well...