2013-07-21 110 views
0

enter image description here清单项目

的底部jQuery Mobile的ListView的差距我想在列表视图的底部摆脱的差距。

这里是我的CSS

.myParagraph.ui-li-desc { 
     color:#333; 
     overflow:show; 
     white-space:normal; 
     height:28px; 
     margin-bottom:0px; 
    } 

这里是我的标记:

listitems_markup = '<li><img src="' + itemThumbnail + '""><div class="myParagraph"><p>You viewed ' + itemName + '</p><p>You spent '+itemTimeSpent+' on this activity</p><p>You '+itemRating+' this item</p></div><p class="ui-li-aside">'+itemViewedTime+'</p></li>'; 

我将如何摆脱这种差距?

+0

尝试li.myParagraph.ui丽递减或重要保证金 – Hushme

+0

@Hushme试图.li.myParagraph.ui丽递减didnt工作,你如何做重要的保证金? – Dot

+0

margin-bottom:0px!important; – Hushme

回答

1

试试这个

 listitems_markup = '<li class="nomarigin"><img src="' + itemThumbnail + '""> 
<div class="myParagraph"><p>You viewed ' + itemName + '</p><p>You spent '+itemTimeSpent+' on this activity</p><p>You '+itemRating+' this item</p></div><p class="ui-li-aside">'+itemViewedTime+'</p></li>'; 

在CSS

.nomarigin {margin-bottom:0 !important;} 
+0

谢谢,我试过了,它现在看起来很整洁,但我想通了,它不能摆脱差距,因为在移动视图较小的屏幕上,对listview的描述很长,并且它将文本包装到div中,所以在移动视图中出现更大的差距。没关系,我会放弃这种方式,但加入你的nomargin使它更加整洁。谢谢 – Dot