diff --git a/angular-toggle-switch.js b/angular-toggle-switch.js index eabf75a..564a491 100644 --- a/angular-toggle-switch.js +++ b/angular-toggle-switch.js @@ -22,7 +22,6 @@ replace: true, require:'ngModel', scope: { - disabled: '@', onLabel: '@', offLabel: '@', knobLabel: '@' @@ -55,6 +54,10 @@ } }); + attrs.$observe('disabled', function(val){ + scope.disabled = val; + }); + ngModelCtrl.$formatters.push(function(modelValue){ return modelValue; }); diff --git a/bower.json b/bower.json index 7f2cbd6..829fb76 100644 --- a/bower.json +++ b/bower.json @@ -11,8 +11,8 @@ "url": "https://github.com/cgarvis/angular-toggle-switch.git" }, "devDependencies": { - "angular": ">=1.0", - "angular-mocks": ">=1.0" + "angular": "~1.4.0", + "angular-mocks": "~1.4.0" }, "ignore": [ "**/.*", @@ -20,5 +20,8 @@ "karma.conf.js", "package.json", ".travis.yml" - ] + ], + "resolutions": { + "angular": "~1.4.0" + } }