From 731178e144136a314ec7245431a780a58abf8778 Mon Sep 17 00:00:00 2001 From: Chris Liechty Date: Thu, 13 Nov 2014 09:44:23 -0700 Subject: [PATCH] Release v0.8.19 --- bower.json | 2 +- dist/angular-agility.js | 7 +------ dist/angular-agility.min.js | 4 ++-- package.json | 2 +- 4 files changed, 5 insertions(+), 10 deletions(-) diff --git a/bower.json b/bower.json index 5c32057..41c39b4 100644 --- a/bower.json +++ b/bower.json @@ -1,6 +1,6 @@ { "name": "angular-agility", - "version": "0.8.18", + "version": "0.8.19", "homepage": "https://github.com/AngularAgility/AngularAgility", "authors": [ "John Culviner " diff --git a/dist/angular-agility.js b/dist/angular-agility.js index 2f7764a..32bdd06 100644 --- a/dist/angular-agility.js +++ b/dist/angular-agility.js @@ -1,5 +1,5 @@ /* -angular-agility "version":"0.8.18" @ 2014-11-09T18:26:01 +angular-agility "version":"0.8.19" @ 2014-11-13T09:44:02 Copyright (c) 2014 - John Culviner Licensed under the MIT license */ @@ -1878,11 +1878,6 @@ angular } element.on('click', submit); - - if (attrs.type === 'submit') { - //this should be the form's default 'on enter' behavior for submission - ngForm.$aaFormExtensions.$onEnterKey = submit; - } } }; }]); diff --git a/dist/angular-agility.min.js b/dist/angular-agility.min.js index 6127dbc..f735a03 100644 --- a/dist/angular-agility.min.js +++ b/dist/angular-agility.min.js @@ -1,7 +1,7 @@ /* -angular-agility "version":"0.8.18" @ 2014-11-09T18:26:01 +angular-agility "version":"0.8.19" @ 2014-11-13T09:44:02 Copyright (c) 2014 - John Culviner Licensed under the MIT license */ -!function(){"use strict";angular.module("aa.notify",[]).factory("aaNotify",["aaNotifyConfig","$rootScope","$sce",function(a,b,c){return{success:function(b,c){return a.notifyConfigs[a.defaultNotifyConfig].namedDefaults.success(b,c,this)},info:function(b,c){return a.notifyConfigs[a.defaultNotifyConfig].namedDefaults.info(b,c,this)},warning:function(b,c){return a.notifyConfigs[a.defaultNotifyConfig].namedDefaults.warning(b,c,this)},danger:function(b,c){return a.notifyConfigs[a.defaultNotifyConfig].namedDefaults.danger(b,c,this)},error:function(b,c){return a.notifyConfigs[a.defaultNotifyConfig].namedDefaults.error(b,c,this)},add:function(d,e,f){return f=f||a.notifyConfigs[a.defaultNotifyConfig],angular.isString(f)&&(f=a.notifyConfigs[f]),e=e||f.defaultTargetContainerName,d=angular.extend(angular.copy(f.options),d),d.messageHandle={},f.optionsTransformer&&f.optionsTransformer(d,c),d.template=f.templateUrl||f.templateName,b.$broadcast("aaNotifyContainer-"+e+"-add",d),d.messageHandle},remove:function(c,d){d=d||a.notifyConfigs[a.defaultNotifyConfig].defaultTargetContainerName,b.$broadcast("aaNotifyContainer-"+d+"-remove",c)},clearAll:function(c){c=c||a.notifyConfigs[a.defaultNotifyConfig].defaultTargetContainerName,b.$broadcast("aaNotifyContainer-"+c+"-clearAll")}}}]).directive("aaNotify",["$timeout",function(a){return{template:'
',replace:!0,link:function(b,c,d){b.notifications=[];var e=d.containerName||"default";b.$on("aaNotifyContainer-"+e+"-add",function(c,d){d.replaceExisting&&(b.notifications.length=0),b.notifications.push(d),d.ttl>0&&a(function(){var a=b.notifications.indexOf(d);a>-1&&b.notifications.splice(a,1)},d.ttl)}),b.$on("aaNotifyContainer-"+e+"-remove",function(a,c){for(var d=b.notifications.length-1;d>=0;d--)if(b.notifications[d].messageHandle===c){b.notifications.splice(d,1);break}}),b.$on("aaNotifyContainer-"+e+"-clearAll",function(){b.notifications.length=0}),b.close=function(a){b.notifications.splice(b.notifications.indexOf(a),1),angular.isFunction(a.onClose)&&a.onClose()}}}}]).provider("aaNotifyConfig",function(){var a=this;a.notifyConfigs={},a.addOrUpdateNotifyConfig=function(b,c){var d=a.notifyConfigs[b]=a.notifyConfigs[b]||{};d.name=b,angular.extend(d,c),d.template&&(d.templateName="aaNotifyTemplate-"+d.name)},a.addOrUpdateNotifyConfig("default",{template:'
 {{notification.message}}
',options:{ttl:4e3,replaceExisting:!1},namedDefaults:{success:function(a,b,c){return c.add(angular.extend({message:a,messageType:"success"},b))},info:function(a,b,c){return c.add(angular.extend({message:a,messageType:"info"},b))},warning:function(a,b,c){return c.add(angular.extend({message:a,messageType:"warning"},b))},danger:function(a,b,c){return c.add(angular.extend({message:a,messageType:"danger"},b))},error:function(a,b,c){return c.add(angular.extend({message:a,messageType:"error"},b))}},defaultTargetContainerName:"default",optionsTransformer:function(a,b){a.cssClasses||(a.cssClasses=""),"success"===a.messageType?a.cssClasses+="alert-success":"info"===a.messageType?a.cssClasses+="alert-info":"warning"===a.messageType?a.cssClasses+="alert-warning":("danger"===a.messageType||"error"===a.messageType)&&(a.cssClasses+="alert-danger alert-error"),a.allowHtml&&(a.message=b.trustAsHtml(a.message))}}),a.defaultNotifyConfig="default",this.$get=function(){return{notifyConfigs:a.notifyConfigs,defaultNotifyConfig:a.defaultNotifyConfig}}}).run(["aaNotifyConfig","$templateCache",function(a,b){angular.forEach(a.notifyConfigs,function(a){a.templateName&&b.put(a.templateName,a.template)})}])}(),angular.module("aa.select2",[]).directive("aaSelect2",["$q",function(a){"use strict";return{require:"ngModel",template:'',replace:!0,link:function(b,c,d,e){function f(a){return Object.keys?0===Object.keys(a).length:"{}"===JSON.stringify(a)}var g=angular.copy(b.$eval(d.aaSelect2));if(!angular.isObject(g)||f(g))throw'aa-select2 options must be specified. Ex:
-1))throw new Error("the name attribute value needs to contain a '.' char");d=b.split(".");var e=d[d.length-2],f=d[d.length-1];e=this.resolveModelName(e,b,c);var g=c.validations[e];g?(this.checkIfAlreadyMerged(e+"."+f)||g[f]&&g[f]["aa-inherit"]&&this.mergeInheritedAttributes(g[f],g[f]["aa-inherit"],g,c.validations),this.addAttributes(a,g[f])):console.log("nopes");var h=c.globals;h&&this.addAttributes(a,h,g,c)},checkIfAlreadyMerged:function(a){return this.mergedAttrs.indexOf(a)<0?(this.mergedAttrs.push(a),!1):!0},addAttributes:function(a,b){for(var c in b)"aa-inherit"!==c&&("required"!==c?a.attr(c,b[c]):a.prop(c,b[c]))},mergeInheritedAttributes:function(a,b,c,d){var e=this.getInheritedAttributes(b,c,d);e["aa-inherit"]&&!this.checkIfAlreadyMerged(e["aa-inherit"])&&this.mergeInheritedAttributes(e,e["aa-inherit"],c,d);for(var f in e)a.hasOwnProperty(f)||"aa-inherit"!==f&&(a[f]=e[f])},getInheritedAttributes:function(a,b,c){if(a.indexOf(".")<0)return b[a];var d=a.split(".");return c[d[0]][d[1]]},resolveModelName:function(a,b,c){return c.resolveFn?c.resolveFn(b):c.resolve&&c.resolve[a]?c.resolve[a]:a}}}])}(),function(){"use strict";angular.module("aa.formExtensions",["aa.notify"]).config(["aaNotifyConfigProvider","$httpProvider","$provide",function(a,b,c){a.addOrUpdateNotifyConfig("aaFormExtensionsValidationErrors",{template:'
There are some validation errors:
  • {{ error.message }} 
',options:{ttl:0,showField:function(a){a.field.$element[0].focus()}}}),c.factory("aaLoadingWatcher",["$rootScope",function(a){function b(){a.aaIsLoading=d.isLoading=c>0,a.$$phase||a.$apply()}var c=0,d={isLoading:!1,increment:function(){c++,b()},decrement:function(){c--,b()}};return d}]),c.factory("aaAjaxInterceptor",["aaLoadingWatcher","$q","aaFormExtensions",function(a,b,c){return{request:function(b){return a.increment(),b},response:function(b){return a.decrement(),b},responseError:function(d){return a.decrement(),c.ajaxValidationErrorMappingStrategy&&c.ajaxValidationErrorMappingStrategy(d,c.availableForms),b.reject(d)}}}]),b.interceptors.push("aaAjaxInterceptor"),c.decorator("$controller",["$delegate",function(a){return function(b,c){function d(a){c.$scope.$$aaFormExtensionsTodos||(c.$scope.$$aaFormExtensionsTodos=[]),c.$scope.$$aaFormExtensionsTodos.push(a)}return!c.$aaFormExtensions&&c.$scope&&(c.$aaFormExtensions={$addChangeDependency:function(a,b,c){d({type:"$addChangeDependency",args:[a,b],targetFormName:c})},$resetChanged:function(a,b){d({type:"$resetChanged",args:[a],targetFormName:b})},$reset:function(a,b){d({type:"$reset",args:[a],targetFormName:b})},$clearErrors:function(a,b){d({type:"$clearErrors",args:[a],targetFormName:b})},$addValidationError:function(a,b,c){d({type:"$addValidationError",args:[a,b],targetFormName:c})}}),a.apply(this,arguments)}}])}])}(),function(){"use strict";function a(b,c){var d;if(d=b.attr(c))return d;var e=b.parent();return e.length?(d=e.attr(c),d?d:a(e,c)):void 0}function b(a,b){var c=document.createElement("div");c.innerHTML=b,a.length||(a=[a]);for(var d=a.length-1;d>=0;d--){for(var e=a[d],f=c.firstChild.cloneNode(!0),g=f;g.firstChild;)g=g.firstChild;var h=e.parentNode,i=e.nextSibling;g.appendChild(e),i?h.insertBefore(f,i):h.appendChild(f)}}function c(a){var b=Array.prototype.slice.call(arguments,1);return a.replace(/{(\d+)}/g,function(a,c){return"undefined"!=typeof b[c]?b[c]:a})}angular.module("aa.formExtensions").provider("aaFormExtensions",function(){var d=this;this.defaultLblCol="sm-2",this.defaultLabelStrategy="bootstrap3InlineForm",this.labelStrategies={bootstrap3InlineForm:function(b,c,e){var f=a(b,"aa-lbl-col")||d.defaultLblCol,g=a(b,"aa-lbl-class")||"",h=angular.element("