forked from jquery-archive/jquery-mobile
-
Notifications
You must be signed in to change notification settings - Fork 0
plugin: buttonMarkup
louy edited this page Dec 19, 2010
·
3 revisions
Turn a link into a button that has rounded corners and an icon.
$(selector).buttonMarkup(options);
Roles that can be added to an anchor before turning it into a button:
-
data-icon: accepts a string for various icon classes. Specify the portion after the
ui-icon-
in the class name. For example, 'arrow-l', 'arrow-d' - data-theme: accepts a letter to override the button's theme (a,b,c). If unspecified, theme will inherit from closest ui-bar parent, or fallback to "c"
- data-iconPos: 'left', 'right', 'top', 'bottom', 'notext' (for buttons that should be icon-only)
- corners: true (round corners or not)
- shadow: true (shadow or not)
- iconshadow: true (should icons have an inner shadow?)
- wrapperEls: 'span' (div is useful when calling buttonMarkup on an element containing block-level elements, like an LI in a listview)