mousemke / flounder

Style-able dropdown replacement for native dropdowns
MIT License
9 stars 10 forks source link

[CSS] Remove redundant “DISABLED” class from “selectedDisplayed” div #188

Closed conor-cafferkey-sociomantic closed 6 years ago

conor-cafferkey-sociomantic commented 6 years ago

Currently

Both the refs.flounder div and the refs.selectedDisplayed div get classes.DISABLED when the Flounder is disabled.

Problem

It’s redundant to give both divs classes.DISABLED since refs.selectedDisplayed is inside refs.flounder.

What’s more, if you programmatically change the selected option of a disabled Flounder (e.g. setByValue) then refs.selectedDisplayed loses classes.DISABLED.

Wanted

Don’t add redundant classes.DISABLED to refs.selectedDisplayed. (Unless there’s a good reason that I’m missing?)