diff --git a/src/directive.js b/src/directive.js index e649d99..efac2f3 100644 --- a/src/directive.js +++ b/src/directive.js @@ -20,8 +20,7 @@ angular.module('ngProgress.directive', []) $scope.$watch('color', function (newVal) { if (newVal !== undefined || newVal !== null) { $scope.color = newVal; - $element.eq(0).children().css('background-color', newVal); - $element.eq(0).children().css('color', newVal); + $element.eq(0).children().css({'background-color': newVal, 'color': newVal}); } }); $scope.$watch('height', function (newVal) {