在头像右侧添加图标-Ionic [英] Adding an icon to the right of an Avatar - Ionic
问题描述
我要在离子头像列表项的右侧添加一个图标.
I'm looking ti add an icon to the right of an ionic avatar list item.
我的代码:
<ion-item class="animated flipInX item-divider gold" ng-show="(myArray.length > 0)">My Stuff</ion-item>
<div ng-repeat="item in array">
<ion-list>
<ion-item class="animated flipInX item-avatar" ng-click="showAcceptRequest(item)">
<img ng-src={{item['Picture']}}>
<h2>{{item['SenderName']}}</h2>
<p>{{item['EntityName']}}</p>
</ion-item>
</div>
</ion-list>
显示带有头像名称和一些子信息的头像图片.我想在该单元格的右侧添加一个离子子,但我的位置已全部关闭.有人可以照亮吗?
This shows an avatar picture with there name and some sub-info. I'd like to add an ionicon to the right of this cell but my positioning is all off. Can someone shed some light?
例如:
<i class="icon ion-ios-telephone-outline"></i>
JSFiddle:
http://jsfiddle.net/m3x6nb1d/8/
基本上希望图标位于表格单元格的右侧...
Basically want the icon to be level on the right of the table cell...
推荐答案
这对我有用,粘贴了我的示例,尝试重新创建
This worked for me, pasting my example, try to re-create
<ion-content>
<ion-list class="item-icon-right">
<ion-item>
<i class='icon ion-social-facebook'> </i> Facebook
</ion-item>
</ion-list>
<ion-content>
是的,item-icon-right类应该完成这项工作.
So yeah, item-icon-right class should do the job.
适用于普通图标,如果它不适用于图像,则应查看如何使用img align属性将图像添加到右侧. 示例 http://www.w3schools.com/tags/tryit.asp?filename= tryhtml_img_align
Works with normal icons,if it doesn't work with images then you should see how to add image to the right with img align attribute. Example http://www.w3schools.com/tags/tryit.asp?filename=tryhtml_img_align
这篇关于在头像右侧添加图标-Ionic的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!