According to ng2-bootstrap documentation, there's a panelClass
annotation available for panels. But I can't get it to work.
This is my markup:
<accordion>
<accordion-group [panelClass]="panel-primary">
<div accordion-heading>
test
</div>
test
</accordion-group>
</accordion>
But that produces:
<accordion-group>
<div class="panel panel-default">
<div class="panel-heading">
<h4 class="panel-title">
<a class="accordion-toggle" href="" tabindex="0">
<!--template bindings={}-->
<div accordion-heading="">
test
</div>
</a>
</h4>
</div>
<div class="panel-collapse collapse" aria-expanded="false" aria-hidden="true" style="display: none;">
<div class="panel-body">
test
</div>
</div>
</div>
</accordion-group>
I am using ng2-bootstrap v1.1.13.
What am I doing wrong?
You have to use simple quote like this : [panelClass]=" 'panel-primary' "
Binding is done with string variable. In your case, Angular2 search for a panel-primary attribute and not the litteral string 'panel-primary'.