I have an angular -ui button that looks like this:
<button uib-btn-checkbox ng-model="sortReverse" class="btn btn-default" ng-init="sortReverse=true"> <i class="fa" ng-class="{'fa-sort-asc': sortReverse===true,'fa-sort-desc': sortReverse===false}"></i></button>
It works great.
Every time a model becomes true, the class active is applied to the element. The docs say you can change the class name of the checked button. Here is a quote:
uibButtonConfig default uibButtonConfig
activeClass (Default: active ) - The class to apply to the marked buttons.
But I donβt understand how exactly this should be done; nowhere could I find examples.
javascript angularjs angular-ui
Hinrich
source share