N00nDay / stwui

Opinionated yet customizable Svelte-TailwindCSS component library
stwui.vercel.app
MIT License
451 stars 21 forks source link

First option is keeping gray background color even though it is not selected one. #179

Closed hardcommitoneself closed 1 year ago

hardcommitoneself commented 1 year ago

Current Behavior

I have selected the third one, but the first one has still gray background.

image

Expected Behavior

Any non-selected options shouldn't have special background.

Steps To Reproduce

No response

Link to Reproduction / Stackblitz

No response

More Information

No response

N00nDay commented 1 year ago

The grey background does not indicate that an option is selected. The check mark and bold text is what indicates that an option is selected.

The background is focus indicator. The reason the first option is highlighted when opening the select/dropdown has to do with keyboard usability. Every input in STWUI can be used directly from your keyboard like their html counterparts allowing for a user to never have to use a mouse.

In html you would see the option with a ring around it instead of the highlighting behavior of STWUI.

N00nDay commented 1 year ago

This is in the works and should be resolved today.