text: /*! ng-notifications-bar - v0.0.14 (http://beletsky.net/ng-notifications-bar/) */
  !function(root,factory){"object"==typeof exports?module.exports=factory(root,require("angular")):"function"==typeof define&&define.amd?define(["angular"],function(angular){return root.ngNotificationsBar=factory(root,angular)}):root.ngNotificationsBar=factory(root,root.angular)}(this,function(window,angular){var module=angular.module("ngNotificationsBar",[]);return module.provider("notificationsConfig",function(){function setHideDelay(value){config.hideDelay=value}function getHideDelay(){return config.hideDelay}function setAcceptHTML(value){config.acceptHTML=value}function getAcceptHTML(){return config.acceptHTML}function setAutoHide(value){config.autoHide=value}function getAutoHide(){return config.autoHide}var config={};return{setHideDelay:setHideDelay,setAutoHide:setAutoHide,setAcceptHTML:setAcceptHTML,$get:function(){return{getHideDelay:getHideDelay,getAutoHide:getAutoHide,getAcceptHTML:getAcceptHTML}}}}),module.factory("notifications",["$rootScope",function($rootScope){var showError=function(message){$rootScope.$broadcast("notifications:error",message)},showWarning=function(message){$rootScope.$broadcast("notifications:warning",message)},showSuccess=function(message){$rootScope.$broadcast("notifications:success",message)},closeAll=function(){$rootScope.$broadcast("notifications:closeAll")};return{showError:showError,showWarning:showWarning,showSuccess:showSuccess,closeAll:closeAll}}]),module.directive("notificationsBar",["notificationsConfig","$timeout",function(notificationsConfig,$timeout){return{restrict:"EA",template:function(elem,attr){var acceptHTML=notificationsConfig.getAcceptHTML()||!1,iconClasses=attr.closeicon||"glyphicon glyphicon-remove";return acceptHTML?'					<div class="notifications-container" ng-if="notifications.length">						<div class="{{note.type}}" ng-repeat="note in notifications">							<span class="message" ng-bind-html="note.message"></span>							<span class="'+iconClasses+' close-click" ng-click="close($index)"></span>						</div>					</div>				':'					<div class="notifications-container" ng-if="notifications.length">						<div class="{{note.type}}" ng-repeat="note in notifications">							<span class="message" >{{note.message}}</span>							<span class="'+iconClasses+' close-click" ng-click="close($index)"></span>						</div>					</div>				'},link:function(scope){var notifications=scope.notifications=[],autoHideDelay=notificationsConfig.getHideDelay()||3e3,autoHide=notificationsConfig.getAutoHide()||!1,removeById=function(id){var found=-1;notifications.forEach(function(el,index){el.id===id&&(found=index)}),found>=0&&notifications.splice(found,1)},notificationHandler=function(event,data,type){var message,hide=autoHide,hideDelay=autoHideDelay;"object"==typeof data?(message=data.message,hide="undefined"==typeof data.hide?autoHide:!!data.hide,hideDelay=data.hideDelay||hideDelay):message=data;var id="notif_"+(new Date).getTime();if(notifications.push({id:id,type:type,message:message}),hide)var timer=$timeout(function(){removeById(id),$timeout.cancel(timer)},hideDelay)};scope.$on("notifications:error",function(event,data){notificationHandler(event,data,"error")}),scope.$on("notifications:warning",function(event,data){notificationHandler(event,data,"warning")}),scope.$on("notifications:success",function(event,data){notificationHandler(event,data,"success")}),scope.$on("notifications:closeAll",function(){notifications.length=0}),scope.close=function(index){notifications.splice(index,1)}}}}]),module});