Skip to content
This repository has been archived by the owner on May 29, 2019. It is now read-only.

Commit

Permalink
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions src/buttons/buttons.js
Original file line number Diff line number Diff line change
@@ -16,11 +16,7 @@ angular.module('ui.bootstrap.buttons', [])

//model -> UI
ngModelCtrl.$render = function () {
if (angular.equals(ngModelCtrl.$modelValue, scope.$eval(attrs.btnRadio))){
element.addClass(activeClass);
} else {
element.removeClass(activeClass);
}
element.toggleClass(activeClass, angular.equals(ngModelCtrl.$modelValue, scope.$eval(attrs.btnRadio)));
};

//ui->model
@@ -53,11 +49,7 @@ angular.module('ui.bootstrap.buttons', [])

//model -> UI
ngModelCtrl.$render = function () {
if (angular.equals(ngModelCtrl.$modelValue, trueValue)) {
element.addClass(activeClass);
} else {
element.removeClass(activeClass);
}
element.toggleClass(activeClass, angular.equals(ngModelCtrl.$modelValue, trueValue));
};

//ui->model

0 comments on commit e63ebba

Please sign in to comment.