Pony.fm/resources/assets/scripts/app/directives/progress-bar.coffee

6 lines
216 B
CoffeeScript
Raw Normal View History

2015-08-31 17:42:21 +02:00
angular.module('ponyfm').directive 'pfmProgressBar', () ->
2015-10-25 03:35:37 +01:00
(scope, element, attrs) ->
scope.$watch attrs.pfmProgressBar, (val) ->
return if !val?
$(element).css 'width', val + '%'