Skip to content

[BUG] Tooltip of a disabled slider is drawn under the next slider #4232

Todo

Description

@omkar-334

Follow-up to #3632 and #4209, which fixed this for enabled sliders and left the disabled case out.

Describe your context

Dash dev with #4209 applied.

  • OS: macOS
  • Browser: Chrome

Describe the bug
image
A disabled slider with an always-visible tooltip still has its tooltip painted under the slider that comes after it.

.dash-slider-root[data-disabled] sets opacity: 0.5 in components/dash-core-components/src/components/css/sliders.css. Opacity below 1 makes the root a stacking context, so the tooltip's z-index cannot reach past its own slider, and the next slider is painted on top in DOM order.

Expected behavior

The tooltip of a disabled slider is drawn above the next slider, the same as for an enabled one.

Reproducing code

from dash import Dash, dcc, html

app = Dash(__name__)

tooltip = {"placement": "bottom", "always_visible": True}
app.layout = html.Div(
    [
        dcc.Slider(0, 100, 1, value=10, id="first", disabled=True, tooltip=tooltip),
        dcc.Slider(0, 20, 5, value=10, id="second", tooltip=tooltip),
    ]
)

if __name__ == "__main__":
    app.run(debug=True)

Possible fix

Fade the root's children and not the root itself:

.dash-slider-root[data-disabled] > * {
    opacity: 0.5;
}

This worked when I tried it during #4209. It was left out there because it changes how every disabled slider is blended: the thumb is no longer composited with the track as one group, so the track shows through the thumb a little more. The tooltip anchor would also need to be left out of the fade, or the tooltip stays half transparent.

Activity

  1. added
    bug
    P3
    sev-4
    on Dec 2, 2026
  2. added theissue type on Dec 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

P3bugsev-4size: 1

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions