summaryrefslogtreecommitdiffstats
path: root/js/vendor
diff options
context:
space:
mode:
authorBernhard Posselt <dev@bernhard-posselt.com>2015-03-09 12:09:38 +0100
committerBernhard Posselt <dev@bernhard-posselt.com>2015-03-09 12:09:38 +0100
commit3bcea62e8dcb4b5f2e45e6701725e904ad115676 (patch)
tree839704689a6807322452cf55dac40e852a577c3e /js/vendor
parent0537cff4ce3d520a0401c5f2d6d7ab73d4f99169 (diff)
fix feed ordering and fix #744
Diffstat (limited to 'js/vendor')
-rw-r--r--js/vendor/angular-animate/.bower.json10
-rw-r--r--js/vendor/angular-animate/angular-animate.js2
-rw-r--r--js/vendor/angular-animate/angular-animate.min.js2
-rw-r--r--js/vendor/angular-animate/bower.json4
-rw-r--r--js/vendor/angular-animate/package.json2
-rw-r--r--js/vendor/angular-mocks/.bower.json10
-rw-r--r--js/vendor/angular-mocks/angular-mocks.js101
-rw-r--r--js/vendor/angular-mocks/bower.json4
-rw-r--r--js/vendor/angular-mocks/package.json2
-rw-r--r--js/vendor/angular-route/.bower.json10
-rw-r--r--js/vendor/angular-route/angular-route.js2
-rw-r--r--js/vendor/angular-route/angular-route.min.js2
-rw-r--r--js/vendor/angular-route/bower.json4
-rw-r--r--js/vendor/angular-route/package.json2
-rw-r--r--js/vendor/angular-sanitize/.bower.json10
-rw-r--r--js/vendor/angular-sanitize/angular-sanitize.js2
-rw-r--r--js/vendor/angular-sanitize/angular-sanitize.min.js2
-rw-r--r--js/vendor/angular-sanitize/bower.json4
-rw-r--r--js/vendor/angular-sanitize/package.json2
-rw-r--r--js/vendor/angular/.bower.json8
-rw-r--r--js/vendor/angular/angular.js449
-rw-r--r--js/vendor/angular/angular.min.js554
-rw-r--r--js/vendor/angular/angular.min.js.gzipbin50113 -> 50065 bytes
-rw-r--r--js/vendor/angular/angular.min.js.map4
-rw-r--r--js/vendor/angular/bower.json2
-rw-r--r--js/vendor/angular/package.json2
-rw-r--r--js/vendor/es6-shim/.bower.json8
-rw-r--r--js/vendor/es6-shim/CHANGELOG.md4
-rw-r--r--js/vendor/es6-shim/bower.json2
-rw-r--r--js/vendor/es6-shim/component.json2
-rw-r--r--js/vendor/es6-shim/es6-sham.js4
-rw-r--r--js/vendor/es6-shim/es6-sham.min.js4
-rw-r--r--js/vendor/es6-shim/es6-shim.js33
-rw-r--r--js/vendor/es6-shim/es6-shim.map2
-rw-r--r--js/vendor/es6-shim/es6-shim.min.js8
-rw-r--r--js/vendor/es6-shim/package.json2
-rw-r--r--js/vendor/js-url/.bower.json5
37 files changed, 669 insertions, 601 deletions
diff --git a/js/vendor/angular-animate/.bower.json b/js/vendor/angular-animate/.bower.json
index 929eae425..a7d66856d 100644
--- a/js/vendor/angular-animate/.bower.json
+++ b/js/vendor/angular-animate/.bower.json
@@ -1,17 +1,17 @@
{
"name": "angular-animate",
- "version": "1.4.0-build.3861+sha.2c4ffd6",
+ "version": "1.4.0-build.3887+sha.41fdb3d",
"main": "./angular-animate.js",
"ignore": [],
"dependencies": {
- "angular": "1.4.0-build.3861+sha.2c4ffd6"
+ "angular": "1.4.0-build.3887+sha.41fdb3d"
},
"homepage": "https://github.com/angular/bower-angular-animate",
- "_release": "1.4.0-build.3861+sha.2c4ffd6",
+ "_release": "1.4.0-build.3887+sha.41fdb3d",
"_resolution": {
"type": "version",
- "tag": "v1.4.0-build.3861+sha.2c4ffd6",
- "commit": "be16ba6f29a5cab8d1099dbb08cfe923f727a6a3"
+ "tag": "v1.4.0-build.3887+sha.41fdb3d",
+ "commit": "d0e73b77a630da6a8084bd43fea3759e924fcb13"
},
"_source": "git://github.com/angular/bower-angular-animate.git",
"_target": "~1.4.*",
diff --git a/js/vendor/angular-animate/angular-animate.js b/js/vendor/angular-animate/angular-animate.js
index 1cd53aa8f..692f4e654 100644
--- a/js/vendor/angular-animate/angular-animate.js
+++ b/js/vendor/angular-animate/angular-animate.js
@@ -1,5 +1,5 @@
/**
- * @license AngularJS v1.4.0-build.3861+sha.2c4ffd6
+ * @license AngularJS v1.4.0-build.3887+sha.41fdb3d
* (c) 2010-2015 Google, Inc. http://angularjs.org
* License: MIT
*/
diff --git a/js/vendor/angular-animate/angular-animate.min.js b/js/vendor/angular-animate/angular-animate.min.js
index b0901fd51..95e24467d 100644
--- a/js/vendor/angular-animate/angular-animate.min.js
+++ b/js/vendor/angular-animate/angular-animate.min.js
@@ -1,5 +1,5 @@
/*
- AngularJS v1.4.0-build.3861+sha.2c4ffd6
+ AngularJS v1.4.0-build.3887+sha.41fdb3d
(c) 2010-2015 Google, Inc. http://angularjs.org
License: MIT
*/
diff --git a/js/vendor/angular-animate/bower.json b/js/vendor/angular-animate/bower.json
index d0a33bfd0..3123b8bcc 100644
--- a/js/vendor/angular-animate/bower.json
+++ b/js/vendor/angular-animate/bower.json
@@ -1,9 +1,9 @@
{
"name": "angular-animate",
- "version": "1.4.0-build.3861+sha.2c4ffd6",
+ "version": "1.4.0-build.3887+sha.41fdb3d",
"main": "./angular-animate.js",
"ignore": [],
"dependencies": {
- "angular": "1.4.0-build.3861+sha.2c4ffd6"
+ "angular": "1.4.0-build.3887+sha.41fdb3d"
}
}
diff --git a/js/vendor/angular-animate/package.json b/js/vendor/angular-animate/package.json
index f5f4395db..0bbce26b3 100644
--- a/js/vendor/angular-animate/package.json
+++ b/js/vendor/angular-animate/package.json
@@ -1,6 +1,6 @@
{
"name": "angular-animate",
- "version": "1.4.0-build.3861+sha.2c4ffd6",
+ "version": "1.4.0-build.3887+sha.41fdb3d",
"description": "AngularJS module for animations",
"main": "index.js",
"scripts": {
diff --git a/js/vendor/angular-mocks/.bower.json b/js/vendor/angular-mocks/.bower.json
index 8733b39f7..5b1e6dfa6 100644
--- a/js/vendor/angular-mocks/.bower.json
+++ b/js/vendor/angular-mocks/.bower.json
@@ -1,17 +1,17 @@
{
"name": "angular-mocks",
- "version": "1.4.0-build.3861+sha.2c4ffd6",
+ "version": "1.4.0-build.3887+sha.41fdb3d",
"main": "./angular-mocks.js",
"ignore": [],
"dependencies": {
- "angular": "1.4.0-build.3861+sha.2c4ffd6"
+ "angular": "1.4.0-build.3887+sha.41fdb3d"
},
"homepage": "https://github.com/angular/bower-angular-mocks",
- "_release": "1.4.0-build.3861+sha.2c4ffd6",
+ "_release": "1.4.0-build.3887+sha.41fdb3d",
"_resolution": {
"type": "version",
- "tag": "v1.4.0-build.3861+sha.2c4ffd6",
- "commit": "2bdbc872a7194935080ca6c2ece9d8969813ff70"
+ "tag": "v1.4.0-build.3887+sha.41fdb3d",
+ "commit": "c8dd069840aefe73ea8bb53bb06a17b7778292e2"
},
"_source": "git://github.com/angular/bower-angular-mocks.git",
"_target": "~1.4.*",
diff --git a/js/vendor/angular-mocks/angular-mocks.js b/js/vendor/angular-mocks/angular-mocks.js
index 8adaba81e..12edf51cf 100644
--- a/js/vendor/angular-mocks/angular-mocks.js
+++ b/js/vendor/angular-mocks/angular-mocks.js
@@ -1,5 +1,5 @@
/**
- * @license AngularJS v1.4.0-build.3861+sha.2c4ffd6
+ * @license AngularJS v1.4.0-build.3887+sha.41fdb3d
* (c) 2010-2015 Google, Inc. http://angularjs.org
* License: MIT
*/
@@ -66,8 +66,6 @@ angular.mock.$Browser = function() {
self.$$checkUrlChange = angular.noop;
- self.cookieHash = {};
- self.lastCookieHash = {};
self.deferredFns = [];
self.deferredNextId = 0;
@@ -147,11 +145,6 @@ angular.mock.$Browser.prototype = {
});
},
- addPollFn: function(pollFn) {
- this.pollFns.push(pollFn);
- return pollFn;
- },
-
url: function(url, replace, state) {
if (angular.isUndefined(state)) {
state = null;
@@ -170,25 +163,6 @@ angular.mock.$Browser.prototype = {
return this.$$state;
},
- cookies: function(name, value) {
- if (name) {
- if (angular.isUndefined(value)) {
- delete this.cookieHash[name];
- } else {
- if (angular.isString(value) && //strings only
- value.length <= 4096) { //strict cookie storage limits
- this.cookieHash[name] = value;
- }
- }
- } else {
- if (!angular.equals(this.cookieHash, this.lastCookieHash)) {
- this.lastCookieHash = angular.copy(this.cookieHash);
- this.cookieHash = angular.copy(this.cookieHash);
- }
- return this.cookieHash;
- }
- },
-
notifyWhenNoOutstandingRequests: function(fn) {
fn();
}
@@ -1814,6 +1788,77 @@ angular.mock.$RootElementProvider = function() {
};
/**
+ * @ngdoc service
+ * @name $controller
+ * @description
+ * A decorator for {@link ng.$controller} with additional `bindings` parameter, useful when testing
+ * controllers of directives that use {@link $compile#-bindtocontroller- `bindToController`}.
+ *
+ *
+ * ## Example
+ *
+ * ```js
+ *
+ * // Directive definition ...
+ *
+ * myMod.directive('myDirective', {
+ * controller: 'MyDirectiveController',
+ * bindToController: {
+ * name: '@'
+ * }
+ * });
+ *
+ *
+ * // Controller definition ...
+ *
+ * myMod.controller('MyDirectiveController', ['log', function($log) {
+ * $log.info(this.name);
+ * })];
+ *
+ *
+ * // In a test ...
+ *
+ * describe('myDirectiveController', function() {
+ * it('should write the bound name to the log', inject(function($controller, $log) {
+ * var ctrl = $controller('MyDirective', { /* no locals &#42;/ }, { name: 'Clark Kent' });
+ * expect(ctrl.name).toEqual('Clark Kent');
+ * expect($log.info.logs).toEqual(['Clark Kent']);
+ * });
+ * });
+ *
+ * ```
+ *
+ * @param {Function|string} constructor If called with a function then it's considered to be the
+ * controller constructor function. Otherwise it's considered to be a string which is used
+ * to retrieve the controller constructor using the following steps:
+ *
+ * * check if a controller with given name is registered via `$controllerProvider`
+ * * check if evaluating the string on the current scope returns a constructor
+ * * if $controllerProvider#allowGlobals, check `window[constructor]` on the global
+ * `window` object (not recommended)
+ *
+ * The string can use the `controller as property` syntax, where the controller instance is published
+ * as the specified property on the `scope`; the `scope` must be injected into `locals` param for this
+ * to work correctly.
+ *
+ * @param {Object} locals Injection locals for Controller.
+ * @param {Object=} bindings Properties to add to the controller before invoking the constructor. This is used
+ * to simulate the `bindToController` feature and simplify certain kinds of tests.
+ * @return {Object} Instance of given controller.
+ */
+angular.mock.$ControllerDecorator = ['$delegate', function($delegate) {
+ return function(expression, locals, later, ident) {
+ if (later && typeof later === 'object') {
+ var create = $delegate(expression, locals, true, ident);
+ angular.extend(create.instance, later);
+ return create();
+ }
+ return $delegate(expression, locals, later, ident);
+ };
+}];
+
+
+/**
* @ngdoc module
* @name ngMock
* @packageName angular-mocks
@@ -1841,6 +1886,7 @@ angular.module('ngMock', ['ng']).provider({
$provide.decorator('$$rAF', angular.mock.$RAFDecorator);
$provide.decorator('$$asyncCallback', angular.mock.$AsyncCallbackDecorator);
$provide.decorator('$rootScope', angular.mock.$RootScopeDecorator);
+ $provide.decorator('$controller', angular.mock.$ControllerDecorator);
}]);
/**
@@ -2176,7 +2222,6 @@ if (window.jasmine || window.mocha) {
if (injector) {
injector.get('$rootElement').off();
- injector.get('$browser').pollFns.length = 0;
}
// clean up jquery's fragment cache
diff --git a/js/vendor/angular-mocks/bower.json b/js/vendor/angular-mocks/bower.json
index 623f56bfc..91621c43d 100644
--- a/js/vendor/angular-mocks/bower.json
+++ b/js/vendor/angular-mocks/bower.json
@@ -1,9 +1,9 @@
{
"name": "angular-mocks",
- "version": "1.4.0-build.3861+sha.2c4ffd6",
+ "version": "1.4.0-build.3887+sha.41fdb3d",
"main": "./angular-mocks.js",
"ignore": [],
"dependencies": {
- "angular": "1.4.0-build.3861+sha.2c4ffd6"
+ "angular": "1.4.0-build.3887+sha.41fdb3d"
}
}
diff --git a/js/vendor/angular-mocks/package.json b/js/vendor/angular-mocks/package.json
index b5d3cc097..1493c10e6 100644
--- a/js/vendor/angular-mocks/package.json
+++ b/js/vendor/angular-mocks/package.json
@@ -1,6 +1,6 @@
{
"name": "angular-mocks",
- "version": "1.4.0-build.3861+sha.2c4ffd6",
+ "version": "1.4.0-build.3887+sha.41fdb3d",
"description": "AngularJS mocks for testing",
"main": "angular-mocks.js",
"scripts": {
diff --git a/js/vendor/angular-route/.bower.json b/js/vendor/angular-route/.bower.json
index 8ca74fbb2..e29907a8e 100644
--- a/js/vendor/angular-route/.bower.json
+++ b/js/vendor/angular-route/.bower.json
@@ -1,17 +1,17 @@
{
"name": "angular-route",
- "version": "1.4.0-build.3861+sha.2c4ffd6",
+ "version": "1.4.0-build.3887+sha.41fdb3d",
"main": "./angular-route.js",
"ignore": [],
"dependencies": {
- "angular": "1.4.0-build.3861+sha.2c4ffd6"
+ "angular": "1.4.0-build.3887+sha.41fdb3d"
},
"homepage": "https://github.com/angular/bower-angular-route",
- "_release": "1.4.0-build.3861+sha.2c4ffd6",
+ "_release": "1.4.0-build.3887+sha.41fdb3d",
"_resolution": {
"type": "version",
- "tag": "v1.4.0-build.3861+sha.2c4ffd6",
- "commit": "4a40fd1ba34f0f9c49d54ef0336bf80d69dfdbfc"
+ "tag": "v1.4.0-build.3887+sha.41fdb3d",
+ "commit": "db971dfa4584d4b6b41c562cf571dfa7918bc531"
},
"_source": "git://github.com/angular/bower-angular-route.git",
"_target": "~1.4.*",
diff --git a/js/vendor/angular-route/angular-route.js b/js/vendor/angular-route/angular-route.js
index 643a485ba..db6ea2610 100644
--- a/js/vendor/angular-route/angular-route.js
+++ b/js/vendor/angular-route/angular-route.js
@@ -1,5 +1,5 @@
/**
- * @license AngularJS v1.4.0-build.3861+sha.2c4ffd6
+ * @license AngularJS v1.4.0-build.3887+sha.41fdb3d
* (c) 2010-2015 Google, Inc. http://angularjs.org
* License: MIT
*/
diff --git a/js/vendor/angular-route/angular-route.min.js b/js/vendor/angular-route/angular-route.min.js
index 64ef25939..42a5ec1a0 100644
--- a/js/vendor/angular-route/angular-route.min.js
+++ b/js/vendor/angular-route/angular-route.min.js
@@ -1,5 +1,5 @@
/*
- AngularJS v1.4.0-build.3861+sha.2c4ffd6
+ AngularJS v1.4.0-build.3887+sha.41fdb3d
(c) 2010-2015 Google, Inc. http://angularjs.org
License: MIT
*/
diff --git a/js/vendor/angular-route/bower.json b/js/vendor/angular-route/bower.json
index 8f177498c..9844781a2 100644
--- a/js/vendor/angular-route/bower.json
+++ b/js/vendor/angular-route/bower.json
@@ -1,9 +1,9 @@
{
"name": "angular-route",
- "version": "1.4.0-build.3861+sha.2c4ffd6",
+ "version": "1.4.0-build.3887+sha.41fdb3d",
"main": "./angular-route.js",
"ignore": [],
"dependencies": {
- "angular": "1.4.0-build.3861+sha.2c4ffd6"
+ "angular": "1.4.0-build.3887+sha.41fdb3d"
}
}
diff --git a/js/vendor/angular-route/package.json b/js/vendor/angular-route/package.json
index c6e47b10e..163eea8d6 100644
--- a/js/vendor/angular-route/package.json
+++ b/js/vendor/angular-route/package.json
@@ -1,6 +1,6 @@
{
"name": "angular-route",
- "version": "1.4.0-build.3861+sha.2c4ffd6",
+ "version": "1.4.0-build.3887+sha.41fdb3d",
"description": "AngularJS router module",
"main": "index.js",
"scripts": {
diff --git a/js/vendor/angular-sanitize/.bower.json b/js/vendor/angular-sanitize/.bower.json
index d7c943f00..e62ece359 100644
--- a/js/vendor/angular-sanitize/.bower.json
+++ b/js/vendor/angular-sanitize/.bower.json
@@ -1,17 +1,17 @@
{
"name": "angular-sanitize",
- "version": "1.4.0-build.3861+sha.2c4ffd6",
+ "version": "1.4.0-build.3887+sha.41fdb3d",
"main": "./angular-sanitize.js",
"ignore": [],
"dependencies": {
- "angular": "1.4.0-build.3861+sha.2c4ffd6"
+ "angular": "1.4.0-build.3887+sha.41fdb3d"
},
"homepage": "https://github.com/angular/bower-angular-sanitize",
- "_release": "1.4.0-build.3861+sha.2c4ffd6",
+ "_release": "1.4.0-build.3887+sha.41fdb3d",
"_resolution": {
"type": "version",
- "tag": "v1.4.0-build.3861+sha.2c4ffd6",
- "commit": "83ee1f28e0dfdc29868cc3969296fa150021219c"
+ "tag": "v1.4.0-build.3887+sha.41fdb3d",
+ "commit": "04da02845b41f357b0757261ee9ec1d98f77814b"
},
"_source": "git://github.com/angular/bower-angular-sanitize.git",
"_target": "~1.4.*",
diff --git a/js/vendor/angular-sanitize/angular-sanitize.js b/js/vendor/angular-sanitize/angular-sanitize.js
index 1887a27c8..2fe34fdda 100644
--- a/js/vendor/angular-sanitize/angular-sanitize.js
+++ b/js/vendor/angular-sanitize/angular-sanitize.js
@@ -1,5 +1,5 @@
/**
- * @license AngularJS v1.4.0-build.3861+sha.2c4ffd6
+ * @license AngularJS v1.4.0-build.3887+sha.41fdb3d
* (c) 2010-2015 Google, Inc. http://angularjs.org
* License: MIT
*/
diff --git a/js/vendor/angular-sanitize/angular-sanitize.min.js b/js/vendor/angular-sanitize/angular-sanitize.min.js
index 7040d30c2..61f58fe2a 100644
--- a/js/vendor/angular-sanitize/angular-sanitize.min.js
+++ b/js/vendor/angular-sanitize/angular-sanitize.min.js
@@ -1,5 +1,5 @@
/*
- AngularJS v1.4.0-build.3861+sha.2c4ffd6
+ AngularJS v1.4.0-build.3887+sha.41fdb3d
(c) 2010-2015 Google, Inc. http://angularjs.org
License: MIT
*/
diff --git a/js/vendor/angular-sanitize/bower.json b/js/vendor/angular-sanitize/bower.json
index 3d91d6f89..73065a850 100644
--- a/js/vendor/angular-sanitize/bower.json
+++ b/js/vendor/angular-sanitize/bower.json
@@ -1,9 +1,9 @@
{
"name": "angular-sanitize",
- "version": "1.4.0-build.3861+sha.2c4ffd6",
+ "version": "1.4.0-build.3887+sha.41fdb3d",
"main": "./angular-sanitize.js",
"ignore": [],
"dependencies": {
- "angular": "1.4.0-build.3861+sha.2c4ffd6"
+ "angular": "1.4.0-build.3887+sha.41fdb3d"
}
}
diff --git a/js/vendor/angular-sanitize/package.json b/js/vendor/angular-sanitize/package.json
index b68adbbce..f6cfe8145 100644
--- a/js/vendor/angular-sanitize/package.json
+++ b/js/vendor/angular-sanitize/package.json
@@ -1,6 +1,6 @@
{
"name": "angular-sanitize",
- "version": "1.4.0-build.3861+sha.2c4ffd6",
+ "version": "1.4.0-build.3887+sha.41fdb3d",
"description": "AngularJS module for sanitizing HTML",
"main": "index.js",
"scripts": {
diff --git a/js/vendor/angular/.bower.json b/js/vendor/angular/.bower.json
index 1bb053d51..ec1614632 100644
--- a/js/vendor/angular/.bower.json
+++ b/js/vendor/angular/.bower.json
@@ -1,15 +1,15 @@
{
"name": "angular",
- "version": "1.4.0-build.3861+sha.2c4ffd6",
+ "version": "1.4.0-build.3887+sha.41fdb3d",
"main": "./angular.js",
"ignore": [],
"dependencies": {},
"homepage": "https://github.com/angular/bower-angular",
- "_release": "1.4.0-build.3861+sha.2c4ffd6",
+ "_release": "1.4.0-build.3887+sha.41fdb3d",
"_resolution": {
"type": "version",
- "tag": "v1.4.0-build.3861+sha.2c4ffd6",
- "commit": "c4af1994feb8d0135a83e6ec6ff3cb74d26cb530"
+ "tag": "v1.4.0-build.3887+sha.41fdb3d",
+ "commit": "c522cd5df7ccc23adb57788146c41c40ef402b03"
},
"_source": "git://github.com/angular/bower-angular.git",
"_target": "~1.4.*",
diff --git a/js/vendor/angular/angular.js b/js/vendor/angular/angular.js
index 32c4d1b81..d2beecf03 100644
--- a/js/vendor/angular/angular.js
+++ b/js/vendor/angular/angular.js
@@ -1,5 +1,5 @@
/**
- * @license AngularJS v1.4.0-build.3861+sha.2c4ffd6
+ * @license AngularJS v1.4.0-build.3887+sha.41fdb3d
* (c) 2010-2015 Google, Inc. http://angularjs.org
* License: MIT
*/
@@ -57,7 +57,7 @@ function minErr(module, ErrorConstructor) {
return match;
});
- message += '\nhttp://errors.angularjs.org/1.4.0-build.3861+sha.2c4ffd6/' +
+ message += '\nhttp://errors.angularjs.org/1.4.0-build.3887+sha.41fdb3d/' +
(module ? module + '/' : '') + code;
for (i = SKIP_INDEXES, paramPrefix = '?'; i < templateArgs.length; i++, paramPrefix = '&') {
@@ -98,6 +98,7 @@ function minErr(module, ErrorConstructor) {
extend: true,
toInt: true,
inherit: true,
+ merge: true,
noop: true,
identity: true,
valueFn: true,
@@ -134,6 +135,8 @@ function minErr(module, ErrorConstructor) {
toJsonReplacer: true,
toJson: true,
fromJson: true,
+ convertTimezoneToLocal: true,
+ timezoneToOffset: true,
startingTag: true,
tryDecodeURIComponent: true,
parseKeyValue: true,
@@ -387,6 +390,31 @@ function setHashKey(obj, h) {
}
}
+
+function baseExtend(dst, objs, deep) {
+ var h = dst.$$hashKey;
+
+ for (var i = 0, ii = objs.length; i < ii; ++i) {
+ var obj = objs[i];
+ if (!isObject(obj) && !isFunction(obj)) continue;
+ var keys = Object.keys(obj);
+ for (var j = 0, jj = keys.length; j < jj; j++) {
+ var key = keys[j];
+ var src = obj[key];
+
+ if (deep && isObject(src)) {
+ if (!isObject(dst[key])) dst[key] = isArray(src) ? [] : {};
+ baseExtend(dst[key], [src], true);
+ } else {
+ dst[key] = src;
+ }
+ }
+ }
+
+ setHashKey(dst, h);
+ return dst;
+}
+
/**
* @ngdoc function
* @name angular.extend
@@ -397,30 +425,45 @@ function setHashKey(obj, h) {
* Extends the destination object `dst` by copying own enumerable properties from the `src` object(s)
* to `dst`. You can specify multiple `src` objects. If you want to preserve original objects, you can do so
* by passing an empty object as the target: `var object = angular.extend({}, object1, object2)`.
- * Note: Keep in mind that `angular.extend` does not support recursive merge (deep copy).
+ *
+ * **Note:** Keep in mind that `angular.extend` does not support recursive merge (deep copy). Use
+ * {@link angular.merge} for this.
*
* @param {Object} dst Destination object.
* @param {...Object} src Source object(s).
+ * @param {boolean=} deep if the last parameter is set to `true`, objects are recursively merged
+ * (deep copy). Defaults to `false`.
* @returns {Object} Reference to `dst`.
*/
function extend(dst) {
- var h = dst.$$hashKey;
+ return baseExtend(dst, slice.call(arguments, 1), false);
+}
- for (var i = 1, ii = arguments.length; i < ii; i++) {
- var obj = arguments[i];
- if (obj) {
- var keys = Object.keys(obj);
- for (var j = 0, jj = keys.length; j < jj; j++) {
- var key = keys[j];
- dst[key] = obj[key];
- }
- }
- }
- setHashKey(dst, h);
- return dst;
+/**
+* @ngdoc function
+* @name angular.merge
+* @module ng
+* @kind function
+*
+* @description
+* Deeply extends the destination object `dst` by copying own enumerable properties from the `src` object(s)
+* to `dst`. You can specify multiple `src` objects. If you want to preserve original objects, you can do so
+* by passing an empty object as the target: `var object = angular.merge({}, object1, object2)`.
+*
+* Unlike {@link angular.extend extend()}, `merge()` recursively descends into object properties of source
+* objects, performing a deep copy.
+*
+* @param {Object} dst Destination object.
+* @param {...Object} src Source object(s).
+* @returns {Object} Reference to `dst`.
+*/
+function merge(dst) {
+ return baseExtend(dst, slice.call(arguments, 1), true);
}
+
+
function toInt(str) {
return parseInt(str, 10);
}
@@ -547,6 +590,12 @@ function isString(value) {return typeof value === 'string';}
* @description
* Determines if a reference is a `Number`.
*
+ * This includes the "special" numbers `NaN`, `+Infinity` and `-Infinity`.
+ *
+ * If you wish to exclude these then you can use the native
+ * [`isFinite'](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/isFinite)
+ * method.
+ *
* @param {*} value Reference to check.
* @returns {boolean} True if `value` is a `Number`.
*/
@@ -929,10 +978,11 @@ function equals(o1, o2) {
} else if (isDate(o1)) {
if (!isDate(o2)) return false;
return equals(o1.getTime(), o2.getTime());
- } else if (isRegExp(o1) && isRegExp(o2)) {
- return o1.toString() == o2.toString();
+ } else if (isRegExp(o1)) {
+ return isRegExp(o2) ? o1.toString() == o2.toString() : false;
} else {
- if (isScope(o1) || isScope(o2) || isWindow(o1) || isWindow(o2) || isArray(o2)) return false;
+ if (isScope(o1) || isScope(o2) || isWindow(o1) || isWindow(o2) ||
+ isArray(o2) || isDate(o2) || isRegExp(o2)) return false;
keySet = {};
for (key in o1) {
if (key.charAt(0) === '$' || isFunction(o1[key])) continue;
@@ -1012,18 +1062,15 @@ var csp = function() {
var jq = function() {
if (isDefined(jq.name_)) return jq.name_;
var el;
- var i, ii = ngAttrPrefixes.length;
+ var i, ii = ngAttrPrefixes.length, prefix, name;
for (i = 0; i < ii; ++i) {
- if (el = document.querySelector('[' +