Sencha触摸列表自定义披露图标

时间:2014-05-12 10:43:32

标签: css sencha-touch-2 disclosure

我有自定义图标显示为列表组件的公开图标。我做了CSS。我的图标颜色是灰色的。它显示为蓝色。

我的CSS:

.myList .x-list-disclosure
{
    width:48px !important;
    height:48px !important;
    top:0px !important;
    margin:1em 0 0 0 !important;
    background-image:none !important;
    color:transparent !important;
    -webkit-mask-box-image:url('../resources/images/next.png') !important;
    -webkit-mask:none !important;
}

.x-list .x-list-disclosure:before {
  position:absolute;
  top:0;
  right:0;
  bottom:0;
  left:0;
  content:'';
  font-family:$font-family;
  color:transparent;
  font-size:48px;
  text-align:center;
  line-height:48px;
  text-shadow:none !important;
}

问题:我的图标显示蓝色的原因是什么(即使是浅灰色)
我使用的CSS有什么问题。

1 个答案:

答案 0 :(得分:0)

这是因为,background-color类的Sencha .x-list .x-list-disclosure是#006bb6。当你使用-webkit-mask-box-image时,它是透明的,显示背景颜色,即蓝色而不是浅灰色。因此,如果您想更改图标的颜色,请执行以下操作:

.myList .x-list-disclosure {
    background-color: grey !important;
}

我希望,我的解释能满足您的疑问。

相关问题