使用angualr UI引导添加类手风琴标题? [英] Add class to accordion heading using angualr ui bootstrap?

查看:217
本文介绍了使用angualr UI引导添加类手风琴标题?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想用纳克级一类有条件地添加到手风琴标题,但现在看来,甚至没有设置明确的类元素上获得preserved。我有这样的:

I want use ng-class to conditionally add a class to the accordion-heading, but it appears that not even setting a class explicitly on the element gets preserved. I have this:

<div accordion close-others="true">
    <div ng-repeat="currItem in items" accordion-group>
        <div accordion-heading class="myClass">My Heading {{$index}}</div>
        <div class="accordion-inner myClass">asdf asdf asdf</div>
    </div>
</div>

和小提琴: http://jsfiddle.net/Zmhx5/1/

当我检查手风琴标题元素,类 MyClass的是无处可寻。有一些原因,我不能添加类手风琴标题?

When I inspect the accordion heading element, the class myClass is nowhere to be found. Is there some reason I can't add classes to the accordion heading?

推荐答案

您可以把CSS指令内手风琴标题标签:

You can put the CSS inside the directive accordion-heading tags:

<accordion-heading>
    <div class="myClass">My Heading {{$index}}</div>
</accordion-heading>

这篇关于使用angualr UI引导添加类手风琴标题?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆