diff --git a/docs/forms/forms-selects.html b/docs/forms/forms-selects.html index c82cb169..981cebe2 100644 --- a/docs/forms/forms-selects.html +++ b/docs/forms/forms-selects.html @@ -54,7 +54,7 @@ -

If there is a select menu with too many options to show on the device's screen, the framework will automatically create a new "page" populated with a standard list view that contains all the options. This allows us to use the native scrolling included on the device for moving through a long list. The text inside the label is used as the title for this page.

+

If there is a select menu with too many options to show on the device's screen, the framework will automatically create a new "page" populated with a standard list view that contains all the options. This allows us to use the native scrolling included on the device for moving through a long list. The text inside the label is used as the title for this page.

@@ -126,7 +126,7 @@

Placeholder options

-

It's common for developers to include a "null" option in their select element to force a user to choose an option. jQuery Mobile detects these null options and hides them in the overlay menu, showing only valid choices to the user. Examples of null options are either:

+

It's common for developers to include a "null" option in their select element to force a user to choose an option. If a placeholder option is present in your markup, jQuery Mobile will hide them in the overlay menu, showing only valid choices to the user, and display the placeholder text inside the menu as a header. Examples of null options are either:

+
@@ -177,11 +176,10 @@ $.mobile.selectmenu.prototype.options.hidePlaceholderMenuItems = false; -
- +

Disabled options

-

jQuery Mobile will automatically disable and style option tags with the disabled="disabled" attribute. In the demo below, the second option "Rush: 3 days" has been set to disabled.

+

jQuery Mobile will automatically disable and style option tags with the disabled attribute. In the demo below, the second option "Rush: 3 days" has been set to disabled.

@@ -192,10 +190,9 @@ $.mobile.selectmenu.prototype.options.hidePlaceholderMenuItems = false;
-

Optgroup support

-

If a select menu contains optgroup elements, jQuery Mobile will create a divider based on their label attribute:

+

If a select menu contains optgroup elements, jQuery Mobile will create a divider & group items based on the label attribute's text:

@@ -207,14 +204,98 @@ $.mobile.selectmenu.prototype.options.hidePlaceholderMenuItems = false; - - - + + +
- + +

Multiple selects

+

If the multiple attribute is present in your markup, jQuery Mobile will enhance the element with a few extra considerations:

+ + + +
+ + +
+ +

When a select is large enough to where the menu will open in a new page, the placeholder text is displayed in the button when no items are selected, and the label text is displayed in the menu's header. This differs from smaller overlay menus where the placeholder text is displayed in both the button and the header, and from full-page single selects where the placeholder text is not used at all.

+ +
+ + +
+ + diff --git a/docs/lists/lists-themes.html b/docs/lists/lists-themes.html index d604610b..617869e3 100755 --- a/docs/lists/lists-themes.html +++ b/docs/lists/lists-themes.html @@ -19,7 +19,7 @@
-

All the standard button swatches can be applied to lists. The framework assigns a default list theme swatch of "c" (silver in the default theme) and swatch "b" (blue in default theme) for dividers. Below is a default themed list.

+

All the standard button swatches can be applied to lists. The framework assigns a default list theme swatch of "c" (silver in the default theme) and swatch "b" (blue in default theme) for dividers. Below is a default themed list.

<ul data-role="listview" data-inset="true"> @@ -30,9 +30,9 @@
  • Outbox 0
  • Sent 328
  • - -

    Theming list items

    -

    The list item color scheme can be changed to any button color theme swatch by adding the data-theme attribute to the list, and setting the letter theme swatch. Here is the same list above with the "a" swatch applied.

    + +

    Theming list items

    +

    The list item color scheme can be changed to any button color theme swatch by adding the data-theme attribute to the list, and setting the letter theme swatch. Here is the same list above with the "a" swatch applied.

    <ul data-role="listview" data-inset="true" data-theme="d"> @@ -47,7 +47,7 @@

    Theming dividers

    -

    The theme for list dividers can be set by adding the data-dividertheme to the list and specifying a swatch letter. Here is an example of the same list above with swatch "d" set on the dividers.

    +

    The theme for list dividers can be set by adding the data-dividertheme to the list and specifying a swatch letter. Here is an example of the same list above with swatch "d" set on the dividers.

    <ul data-role="listview" data-inset="true" data-theme="d" data-dividertheme="c"> @@ -62,7 +62,7 @@

    Theming count bubbles

    -

    The theme for count bubbles can be set by adding the data-counttheme to the list and specifying a swatch letter. Here is an example with swatch "e" set on the dividers.

    +

    The theme for count bubbles can be set by adding the data-counttheme to the list and specifying a swatch letter. Here is an example with swatch "e" set on the dividers.

    <ul data-role="listview" data-inset="true" data-theme="a" data-dividertheme="d" data-counttheme="e"> @@ -75,9 +75,26 @@
  • Sent 328
  • +

    Theming icons

    + +

    The default icon for each list item is arrow-r. To override this, set the data-icon attribute on the desired list item to the name of a standard icon. To prevent icons from appearing altogether, set the data-icon attribute to "false".

    +
    +
    +<li data-icon="info"><a href="#">Notices</a></li>
    +<li data-icon="alert"><a href="#">Alerts</a></li>
    +<li data-icon="false"><a href="#">All Notifications</a></li>
    +
    +
    + +

    Theming split buttons

    -

    For split lists which a second button, the framework default to "b" for the theme swatch (blue in the default theme) Here is a default split list:

    +

    For split lists which a second button, the framework default to "b" for the theme swatch (blue in the default theme) Here is a default split list:

    • @@ -179,4 +196,4 @@
    - \ No newline at end of file + diff --git a/themes/default/jquery.mobile.forms.select.css b/themes/default/jquery.mobile.forms.select.css index 7ae20245..01e97451 100644 --- a/themes/default/jquery.mobile.forms.select.css +++ b/themes/default/jquery.mobile.forms.select.css @@ -22,10 +22,10 @@ label.ui-select { font-size: 16px; line-height: 1.4; font-weight: normal; margi .ui-selectmenu-screen { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 99; } .ui-screen-hidden, .ui-selectmenu-list .ui-li .ui-icon { display: none; } .ui-selectmenu-list .ui-li .ui-icon { display: block; } -.ui-selectmenu-placeholder { display: none; } +.ui-li.ui-selectmenu-placeholder { display: none; } .min-width-480px label.ui-select { display: inline-block; width: 20%; margin: 0 2% 0 0; } .min-width-480px .ui-select { width: 60%; display: inline-block; } /* when no placeholder is defined in a multiple select, the header height doesn't even extend past the close button. this shim's content in there */ -.ui-selectmenu .ui-header h1:after { content: '.'; visibility: hidden; } \ No newline at end of file +.ui-selectmenu .ui-header h1:after { content: '.'; visibility: hidden; }