Permalink
Browse files

Fixes #4227 - Button+data-iconpos="notext" in listview

Cause: The css to position the arrow indicator in a list was also
being applied to the button icon if it appeared in the list.

How fixed: Used '>' css to target only direct children
  • Loading branch information...
1 parent 6a45815 commit 4b276de999310348e8071109b38428a8ffab0b53 Jason Scott committed Apr 28, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 css/structure/jquery.mobile.button.css
@@ -42,7 +42,7 @@
/*btn icon positioning*/
.ui-btn-icon-notext .ui-icon { display: block; z-index: 0;}
-.ui-btn-icon-left .ui-btn-inner .ui-icon, .ui-btn-icon-right .ui-btn-inner .ui-icon { position: absolute; top: 50%; margin-top: -9px; }
+.ui-btn-icon-left > .ui-btn-inner > .ui-icon, .ui-btn-icon-right > .ui-btn-inner > .ui-icon { position: absolute; top: 50%; margin-top: -9px; }
.ui-btn-icon-top .ui-btn-inner .ui-icon, .ui-btn-icon-bottom .ui-btn-inner .ui-icon { position: absolute; left: 50%; margin-left: -9px; }
.ui-btn-icon-left .ui-icon { left: 10px; }
.ui-btn-icon-right .ui-icon { right: 10px; }

6 comments on commit 4b276de

Member

jaspermdegroot replied May 11, 2012

@jasondscott @gseguin This change is causing the icons of split buttons being out of position.

Contributor

toddparker replied May 11, 2012

I just saw that on test. The disc and button are a bit mis-aligned, right?

Member

jaspermdegroot replied May 11, 2012

Yes, that's right. They need the rule that does not apply anymore after this change.

Member

jaspermdegroot replied May 11, 2012

adding this rule to listview.css should fix it:

.ui-li-link-alt .ui-btn-icon-notext .ui-btn-inner .ui-icon { position: absolute; top: 50%; margin-top: -9px; }

Member

gseguin replied May 11, 2012

@ugomobi can you submit a PR with that change and I'll land it? Thanks.

Contributor

jasondscott replied May 11, 2012

I just submitted the fix.
#4342

Please sign in to comment.