Select data-overlay-theme not changing from 'a' past jqm1.1.1 #5051

Closed
tsehested opened this Issue Sep 21, 2012 · 11 comments

Projects

None yet

6 participants

@tsehested

Tried with static and dynamic updated selects.

http://jsbin.com/owipah/82/

@MauriceG
Contributor

Hi @tsehested

I think, the data-overlay-themeattribute is just used for "full-screen" non-native selects: http://jsbin.com/owipah/85/edit

But the select menu page background defaults to swatch a since non-native selects base on popups (jQM 1.2).

Maurice

@tsehested

It is non native... worked fine in jqm 1.1.1

From: Maurice Gottlieb [mailto:notifications@github.com]
Sent: 21 September 2012 08:55 PM
To: jquery/jquery-mobile
Cc: tsehested
Subject: Re: [jquery-mobile] Select data-overlay-theme not changing from 'a' past jqm1.1.1 (#5051)

Hi @tsehested https://github.com/tsehested

I think, the data-overlay-themeattribute is just used for "full-screen" non-native selects: http://jsbin.com/owipah/85/edit

But the select menu page background defaults to swatch a since non-native selects base on popups (jQM 1.2).

Maurice


Reply to this email directly or view it on GitHub #5051 (comment) .

https://github.com/notifications/beacon/Jshd8sI44GVrKZBvymxqKLtJZlPUV2hwzIZ7akOnpDsU9laOl4uZiKYvqF4cjHMk.gif

@MauriceG
Contributor

yes, non native select

@tsehested

The data-theme-overlay should do exactly that... theme the popup with the theme specified... does not work past jqm 1.1.1 ...

T

@globalmatt
Contributor

I'm seeing this too in jQM 1.2. The popup menu border is always black, no matter what you set data-overlay-theme to.

@arschmitz
Member

There was a major re-factor of custom selects in 1.2 while they were previously based on the dialog widget and opened in essentially a separate page. in 1.2 they are based on the popup. In the popup widget documented here http://jquerymobile.com/demos/1.2.0/docs/pages/popup/options.html you will see the data-overlay-theme option only styles the overlay not the popup. to style the popup you need to use data-theme. @gabrielschulhof can you confirm this is the correct and desired behavior. if this is correct maybe this should be noted in the docs since this is a change from 1.1 @agcolom?

@lobbin
Contributor
lobbin commented Oct 23, 2012

Never the less, theme of popup is fixed into theme "a". Maybe using overlayTheme as my pull request does is not the correct procedure, but in that case it should be using the default popup theme instead, not a fixed one.

@arschmitz
Member

you can change the theme and it is not fixed to a see http://jsbin.com/owipah/164/edit you only have one option in your select menus which means it is always the active option and themed blue.

@lobbin
Contributor
lobbin commented Oct 23, 2012

No I can't change theme. The theme is fixed, check this line:
https://github.com/jquery/jquery-mobile/blob/master/js/widgets/forms/select.custom.js#L42

Generated code ends up as data-theme="a" and class ui-body-a is applied to all popups in your example.

@arschmitz
Member

http://jsbin.com/owipah/167/edit

the actual buttons in the select receive the themeing the overlay works as it did before when it is open in a dialog and still serves the same function. in my example on the ones that open as popups you will see all the buttons are colored according to their theme but with the border is not updated according to the overlay. the ones that open as dialogs use the data-theme for the select and the overlay theme for the over lay all is as stated in the docs. So the problem is the overlay not styling the border only when it opens as a popup. Your pull looks good to me to fix that. @gabrielschulhof Maybe you could take a look when you have a second.

@lobbin
Contributor
lobbin commented Oct 24, 2012

Yes, didn't make it clear it was about the frame border, sorry about that :)

@gabrielschulhof gabrielschulhof pushed a commit that closed this issue Oct 24, 2012
@lobbin lobbin Select.custom: fixed listbox overlayTheme regression. Fixed #5051 Sel…
…ect data-overlay-theme not changing from 'a' past jqm1.1.1
3413961
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment