RT!
使用了AmazeUI的两个icon,想做排序按钮,但是不知道怎么让两个位置在同一列,也就是上下对齐,请高手帮忙!
var column = ' <a href="##" class="am-icon-sort-asc"></a><a href="##" class="am-icon-sort-desc"></a>';
先谢啦!
————————————————————————————————————
<div style="text-align: center;height: 40px;border: 1px solid blue;">
<a href="##1" class="am-icon-sort-asc" style="border:1px solid green;display: inline-block; height: 50%;width: 12px;"></a>
<a href="##2" class="am-icon-sort-desc" style="border:1px solid red;display: inline-block; height: 50%;width: 12px;"></a>
</div>
<div style="text-align: center;height: 40px;width:20px; border: 1px solid blue;">
<a href="##1" class="am-icon-sort-asc" style="background-color: salmon;display:block; height: 50%;width: 12px;">1</a>
<a href="##2" class="am-icon-sort-desc" style="background-color: aqua;display:block; height: 50%;width: 12px;">1</a>
</div>
对其中一个设置一下央视(这里一下面的那个icon 举例)
position:relative;
left:-5px;
应该就实现了
也可以对下面的那个icon加
position:relative;
left:5px;
fontawesome图标库里有一个 fa-sort刚好对齐的
FontAwesome里面有这个图标http://www.yeahzan.com/fa/faps.html