Make active state themeable #3750

Closed
justechn opened this Issue Mar 6, 2012 · 5 comments

Projects

None yet

4 participants

@justechn
justechn commented Mar 6, 2012

I would like to see the active state themeable and not global. Right now all buttons, radio buttons, checkboxes, etc all share the same color when active no matter what the theme is. This makes it difficult to use different color buttons. For example I want a navbar at the top of my page, but I want them themed black and when active I want them a dark grey. The other buttons on the page I want grey/white. Right now this is not possible.

@toddparker
Contributor

Yes, this is something I'd like to get in for 1.2 or 1.3. I will be a nice addition.

@dcarrith
Contributor
dcarrith commented Mar 8, 2012

I simply wrote some code that includes my own custom active state class definitions (which essentially override the defaults) based on which theme is selected. It's a hack, but it served it's purpose. It's great to know that the active state will also be themeable in future releases.

@jaspermdegroot
Member

Maybe it is also a good idea to give buttons a general theme class (ui-btn-a, ui-btn-b, etc.) besides the ones with the current state (up/hover/down). This way it requires less code in case you want to overrule a global definition like the active state styling.

@jaspermdegroot
Member

For accessibility it might be even more important to make the ui-focus state themeable. Good example is the JQM docs where focus on buttons in the header is almost not visible.

update: and we could style ::-moz-selection and ::-webkit-selection as well for each theme

update 2: found another one... ui-br should be themeable too

@jaspermdegroot
Member

An issue we have to look into when we are working on this: #5231

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment