Skip to content

Radio hover css behaves differently in Beta 5/6 #3263

@literalpie

Description

@literalpie

Bug report

Current behavior

If you do a css selector like .radio:hover, beta 4 and below would apply the styles when you hover the label associated with the radio element. In beta 6, this is not the case.

Expected behavior

It would be nice if the beta 4 behavior could be brought back.

Reproducible example

Shows the two versions side-by-side. A workaround is added to App.css and commented out
https://stackblitz.com/edit/vitejs-vite-bwvxcdt3?file=src%2FApp.tsx,src%2FApp.css

Base UI version

1.0.0-beta.6

Which browser are you using?

Chrome and Safari

Which OS are you using?

macOS

Additional context

This also applies to Checkbox, and other css states like :active.

I suspect this might just be an expected outcome of #3205.

My workaround is using a css selector like .radio:hover, .radio:has(~ label:hover)

Metadata

Metadata

Assignees

No one assigned

    Labels

    component: radio groupChanges related to the radio group component.type: expected behaviorThe current behavior is already the one expected.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions