ember-source 2.3.2 → 2.4.0.beta.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 1caa63bd14eac73fa56a206f41914e6387c98b3e
4
- data.tar.gz: 9e0817dfaf11c16bd5fcb2eb27c177fbb0ef0d4f
3
+ metadata.gz: 3d248ec7455a8ff0d33802b918af36a160af5001
4
+ data.tar.gz: 549b3ce547a79457548187d6e3181f42d9436e6b
5
5
  SHA512:
6
- metadata.gz: 1aafe1e9507844f75c22c4f78bf658fcb6a994ea8cd22fe64aab67189473d04c069030963fec5cdf72af9495d2a0fa0365b314ef2184223aba7d16ed89c2fe48
7
- data.tar.gz: b982f12203e23ab06eb99dc5241e34479e347bffb6c5c54516f523a1167f002ea490ffee489724c6f5bcee2908d7290846d3bba8688145b3f2acbe56b4b0b56b
6
+ metadata.gz: fc86947a332e9a0323d9309dc75ac569f2db8ccbd4b046a28ed76ccfbf4578168274fd71281a7e00bbe43a9ab440f31511b68370c83cc5abc80078c4f9d19cf1
7
+ data.tar.gz: 786ea74b6f413c9058710a390f5213c2aeef33216c1305eb27c70620ee1f45c47deda711638c5062c5a21a922aa9cc2b70f76a6e6d3fc1ea21f9c22638fff987
data/VERSION CHANGED
@@ -1 +1 @@
1
- 2.3.2
1
+ 2.4.0-beta.2
@@ -6,7 +6,7 @@
6
6
  * Portions Copyright 2008-2011 Apple Inc. All rights reserved.
7
7
  * @license Licensed under MIT license
8
8
  * See https://raw.github.com/emberjs/ember.js/master/LICENSE
9
- * @version 2.3.2
9
+ * @version 2.4.0-beta.2
10
10
  */
11
11
 
12
12
  var enifed, requireModule, require, requirejs, Ember;
@@ -43,8 +43,14 @@ var mainContext = this;
43
43
  requirejs = require = requireModule = function(name) {
44
44
  return internalRequire(name, null);
45
45
  }
46
+
47
+ // setup `require` module
46
48
  require['default'] = require;
47
49
 
50
+ require.has = function registryHas(moduleName) {
51
+ return !!registry[moduleName] || !!registry[moduleName + '/index'];
52
+ };
53
+
48
54
  function missingModule(name, referrerName) {
49
55
  if (referrerName) {
50
56
  throw new Error('Could not find module ' + name + ' required by: ' + referrerName);
@@ -53,7 +59,15 @@ var mainContext = this;
53
59
  }
54
60
  }
55
61
 
56
- function internalRequire(name, referrerName) {
62
+ function internalRequire(_name, referrerName) {
63
+ var name = _name;
64
+ var mod = registry[name];
65
+
66
+ if (!mod) {
67
+ name = name + '/index';
68
+ mod = registry[name];
69
+ }
70
+
57
71
  var exports = seen[name];
58
72
 
59
73
  if (exports !== undefined) {
@@ -62,11 +76,10 @@ var mainContext = this;
62
76
 
63
77
  exports = seen[name] = {};
64
78
 
65
- if (!registry[name]) {
66
- missingModule(name, referrerName);
79
+ if (!mod) {
80
+ missingModule(_name, referrerName);
67
81
  }
68
82
 
69
- var mod = registry[name];
70
83
  var deps = mod.deps;
71
84
  var callback = mod.callback;
72
85
  var length = deps.length;
@@ -197,19 +210,8 @@ enifed('backburner/deferred-action-queues', ['exports', 'backburner/utils', 'bac
197
210
  };
198
211
  });
199
212
  enifed('backburner/platform', ['exports'], function (exports) {
200
- // In IE 6-8, try/finally doesn't work without a catch.
201
- // Unfortunately, this is impossible to test for since wrapping it in a parent try/catch doesn't trigger the bug.
202
- // This tests for another broken try/catch behavior that only exhibits in the same versions of IE.
203
213
  'use strict';
204
214
 
205
- var needsIETryCatchFix = (function (e, x) {
206
- try {
207
- x();
208
- } catch (e) {} // jshint ignore:line
209
- return !!e;
210
- })();
211
-
212
- exports.needsIETryCatchFix = needsIETryCatchFix;
213
215
  var platform;
214
216
 
215
217
  /* global self */
@@ -537,9 +539,6 @@ enifed('backburner', ['exports', 'backburner/utils', 'backburner/platform', 'bac
537
539
  };
538
540
  }
539
541
 
540
- // ms of delay before we conclude a timeout was lost
541
- var TIMEOUT_STALLED_THRESHOLD = 1000;
542
-
543
542
  Backburner.prototype = {
544
543
  begin: function () {
545
544
  var options = this.options;
@@ -901,8 +900,6 @@ enifed('backburner', ['exports', 'backburner/utils', 'backburner/platform', 'bac
901
900
  return fn;
902
901
  }
903
902
 
904
- this._reinstallStalledTimerTimeout();
905
-
906
903
  // find position to insert
907
904
  var i = _backburnerBinarySearch.default(executeAt, this._timers);
908
905
 
@@ -1099,21 +1096,6 @@ enifed('backburner', ['exports', 'backburner/utils', 'backburner/platform', 'bac
1099
1096
  this._installTimerTimeout();
1100
1097
  },
1101
1098
 
1102
- _reinstallStalledTimerTimeout: function () {
1103
- if (!this._timerTimeoutId) {
1104
- return;
1105
- }
1106
- // if we have a timer we should always have a this._timerTimeoutId
1107
- var minExpiresAt = this._timers[0];
1108
- var delay = _backburnerUtils.now() - minExpiresAt;
1109
- // threshold of a second before we assume that the currently
1110
- // installed timeout will not run, so we don't constantly reinstall
1111
- // timeouts that are delayed but good still
1112
- if (delay < TIMEOUT_STALLED_THRESHOLD) {
1113
- return;
1114
- }
1115
- },
1116
-
1117
1099
  _reinstallTimerTimeout: function () {
1118
1100
  this._clearTimerTimeout();
1119
1101
  this._installTimerTimeout();
@@ -1142,14 +1124,6 @@ enifed('backburner', ['exports', 'backburner/utils', 'backburner/platform', 'bac
1142
1124
  Backburner.prototype.scheduleOnce = Backburner.prototype.deferOnce;
1143
1125
  Backburner.prototype.later = Backburner.prototype.setTimeout;
1144
1126
 
1145
- if (_backburnerPlatform.needsIETryCatchFix) {
1146
- var originalRun = Backburner.prototype.run;
1147
- Backburner.prototype.run = _backburnerUtils.wrapInTryCatch(originalRun);
1148
-
1149
- var originalEnd = Backburner.prototype.end;
1150
- Backburner.prototype.end = _backburnerUtils.wrapInTryCatch(originalEnd);
1151
- }
1152
-
1153
1127
  function getOnError(options) {
1154
1128
  return options.onError || options.onErrorTarget && options.onErrorTarget[options.onErrorMethod];
1155
1129
  }
@@ -1285,7 +1259,8 @@ enifed('container/container', ['exports', 'ember-metal/core', 'ember-metal/debug
1285
1259
  @private
1286
1260
  @method lookup
1287
1261
  @param {String} fullName
1288
- @param {Object} options
1262
+ @param {Object} [options]
1263
+ @param {String} [options.source] The fullname of the request source (used for local lookup)
1289
1264
  @return {any}
1290
1265
  */
1291
1266
  lookup: function (fullName, options) {
@@ -1298,11 +1273,13 @@ enifed('container/container', ['exports', 'ember-metal/core', 'ember-metal/debug
1298
1273
  @private
1299
1274
  @method lookupFactory
1300
1275
  @param {String} fullName
1276
+ @param {Object} [options]
1277
+ @param {String} [options.source] The fullname of the request source (used for local lookup)
1301
1278
  @return {any}
1302
1279
  */
1303
- lookupFactory: function (fullName) {
1280
+ lookupFactory: function (fullName, options) {
1304
1281
  _emberMetalDebug.assert('fullName must be a proper full name', this.registry.validateFullName(fullName));
1305
- return factoryFor(this, this.registry.normalize(fullName));
1282
+ return factoryFor(this, this.registry.normalize(fullName), options);
1306
1283
  },
1307
1284
 
1308
1285
  /**
@@ -1353,10 +1330,22 @@ enifed('container/container', ['exports', 'ember-metal/core', 'ember-metal/debug
1353
1330
  return container.registry.getOption(fullName, 'singleton') !== false;
1354
1331
  }
1355
1332
 
1356
- function lookup(container, fullName, options) {
1357
- options = options || {};
1333
+ function lookup(container, _fullName, _options) {
1334
+ var options = _options || {};
1335
+ var fullName = _fullName;
1336
+
1337
+ if (_emberMetalFeatures.default('ember-htmlbars-local-lookup')) {
1338
+ if (options.source) {
1339
+ fullName = container.registry.expandLocalLookup(fullName, options);
1340
+
1341
+ // if expandLocalLookup returns falsey, we do not support local lookup
1342
+ if (!fullName) {
1343
+ return;
1344
+ }
1345
+ }
1346
+ }
1358
1347
 
1359
- if (container.cache[fullName] && options.singleton !== false) {
1348
+ if (container.cache[fullName] !== undefined && options.singleton !== false) {
1360
1349
  return container.cache[fullName];
1361
1350
  }
1362
1351
 
@@ -1409,12 +1398,26 @@ enifed('container/container', ['exports', 'ember-metal/core', 'ember-metal/debug
1409
1398
  return hash;
1410
1399
  }
1411
1400
 
1412
- function factoryFor(container, fullName) {
1401
+ function factoryFor(container, _fullName, _options) {
1402
+ var options = _options || {};
1403
+ var registry = container.registry;
1404
+ var fullName = _fullName;
1405
+
1406
+ if (_emberMetalFeatures.default('ember-htmlbars-local-lookup')) {
1407
+ if (options.source) {
1408
+ fullName = registry.expandLocalLookup(fullName, options);
1409
+
1410
+ // if expandLocalLookup returns falsey, we do not support local lookup
1411
+ if (!fullName) {
1412
+ return;
1413
+ }
1414
+ }
1415
+ }
1416
+
1413
1417
  var cache = container.factoryCache;
1414
1418
  if (cache[fullName]) {
1415
1419
  return cache[fullName];
1416
1420
  }
1417
- var registry = container.registry;
1418
1421
  var factory = registry.resolve(fullName);
1419
1422
  if (factory === undefined) {
1420
1423
  return;
@@ -1605,6 +1608,32 @@ enifed('container/container', ['exports', 'ember-metal/core', 'ember-metal/debug
1605
1608
 
1606
1609
  exports.default = Container;
1607
1610
  });
1611
+ enifed('container/index', ['exports', 'ember-metal/core', 'container/registry', 'container/container', 'container/owner'], function (exports, _emberMetalCore, _containerRegistry, _containerContainer, _containerOwner) {
1612
+ 'use strict';
1613
+
1614
+ /*
1615
+ Public api for the container is still in flux.
1616
+ The public api, specified on the application namespace should be considered the stable api.
1617
+ // @module container
1618
+ @private
1619
+ */
1620
+
1621
+ /*
1622
+ Flag to enable/disable model factory injections (disabled by default)
1623
+ If model factory injections are enabled, models should not be
1624
+ accessed globally (only through `container.lookupFactory('model:modelName'))`);
1625
+ */
1626
+ _emberMetalCore.default.MODEL_FACTORY_INJECTIONS = false;
1627
+
1628
+ if (_emberMetalCore.default.ENV && typeof _emberMetalCore.default.ENV.MODEL_FACTORY_INJECTIONS !== 'undefined') {
1629
+ _emberMetalCore.default.MODEL_FACTORY_INJECTIONS = !!_emberMetalCore.default.ENV.MODEL_FACTORY_INJECTIONS;
1630
+ }
1631
+
1632
+ exports.Registry = _containerRegistry.default;
1633
+ exports.Container = _containerContainer.default;
1634
+ exports.getOwner = _containerOwner.getOwner;
1635
+ exports.setOwner = _containerOwner.setOwner;
1636
+ });
1608
1637
  enifed('container/owner', ['exports', 'ember-metal/symbol'], function (exports, _emberMetalSymbol) {
1609
1638
  /**
1610
1639
  @module ember
@@ -1677,7 +1706,7 @@ enifed('container/owner', ['exports', 'ember-metal/symbol'], function (exports,
1677
1706
  object[OWNER] = owner;
1678
1707
  }
1679
1708
  });
1680
- enifed('container/registry', ['exports', 'ember-metal/debug', 'ember-metal/dictionary', 'ember-metal/assign', 'container/container'], function (exports, _emberMetalDebug, _emberMetalDictionary, _emberMetalAssign, _containerContainer) {
1709
+ enifed('container/registry', ['exports', 'ember-metal/features', 'ember-metal/debug', 'ember-metal/dictionary', 'ember-metal/empty_object', 'ember-metal/assign', 'container/container'], function (exports, _emberMetalFeatures, _emberMetalDebug, _emberMetalDictionary, _emberMetalEmpty_object, _emberMetalAssign, _containerContainer) {
1681
1710
  'use strict';
1682
1711
 
1683
1712
  var VALID_FULL_NAME_REGEXP = /^[^:]+.+:[^:]+$/;
@@ -1713,6 +1742,7 @@ enifed('container/registry', ['exports', 'ember-metal/debug', 'ember-metal/dicti
1713
1742
  this._factoryTypeInjections = _emberMetalDictionary.default(null);
1714
1743
  this._factoryInjections = _emberMetalDictionary.default(null);
1715
1744
 
1745
+ this._localLookupCache = new _emberMetalEmpty_object.default();
1716
1746
  this._normalizeCache = _emberMetalDictionary.default(null);
1717
1747
  this._resolveCache = _emberMetalDictionary.default(null);
1718
1748
  this._failCache = _emberMetalDictionary.default(null);
@@ -1863,6 +1893,8 @@ enifed('container/registry', ['exports', 'ember-metal/debug', 'ember-metal/dicti
1863
1893
 
1864
1894
  var normalizedName = this.normalize(fullName);
1865
1895
 
1896
+ this._localLookupCache = new _emberMetalEmpty_object.default();
1897
+
1866
1898
  delete this.registrations[normalizedName];
1867
1899
  delete this._resolveCache[normalizedName];
1868
1900
  delete this._failCache[normalizedName];
@@ -1893,13 +1925,17 @@ enifed('container/registry', ['exports', 'ember-metal/debug', 'ember-metal/dicti
1893
1925
  @private
1894
1926
  @method resolve
1895
1927
  @param {String} fullName
1928
+ @param {Object} [options]
1929
+ @param {String} [options.source] the fullname of the request source (used for local lookups)
1896
1930
  @return {Function} fullName's factory
1897
1931
  */
1898
- resolve: function (fullName) {
1932
+ resolve: function (fullName, options) {
1899
1933
  _emberMetalDebug.assert('fullName must be a proper full name', this.validateFullName(fullName));
1900
- var factory = resolve(this, this.normalize(fullName));
1934
+ var factory = resolve(this, this.normalize(fullName), options);
1901
1935
  if (factory === undefined && this.fallback) {
1902
- factory = this.fallback.resolve(fullName);
1936
+ var _fallback;
1937
+
1938
+ factory = (_fallback = this.fallback).resolve.apply(_fallback, arguments);
1903
1939
  }
1904
1940
  return factory;
1905
1941
  },
@@ -1976,11 +2012,19 @@ enifed('container/registry', ['exports', 'ember-metal/debug', 'ember-metal/dicti
1976
2012
  @private
1977
2013
  @method has
1978
2014
  @param {String} fullName
2015
+ @param {Object} [options]
2016
+ @param {String} [options.source] the fullname of the request source (used for local lookups)
1979
2017
  @return {Boolean}
1980
2018
  */
1981
- has: function (fullName) {
2019
+ has: function (fullName, options) {
1982
2020
  _emberMetalDebug.assert('fullName must be a proper full name', this.validateFullName(fullName));
1983
- return has(this, this.normalize(fullName));
2021
+
2022
+ var source = undefined;
2023
+ if (_emberMetalFeatures.default('ember-htmlbars-local-lookup')) {
2024
+ source = options && options.source && this.normalize(options.source);
2025
+ }
2026
+
2027
+ return has(this, this.normalize(fullName), source);
1984
2028
  },
1985
2029
 
1986
2030
  /**
@@ -2022,8 +2066,8 @@ enifed('container/registry', ['exports', 'ember-metal/debug', 'ember-metal/dicti
2022
2066
  @param {String} fullName
2023
2067
  @param {Object} options
2024
2068
  */
2025
- options: function (fullName, options) {
2026
- options = options || {};
2069
+ options: function (fullName, _options) {
2070
+ var options = _options || {};
2027
2071
  var normalizedName = this.normalize(fullName);
2028
2072
  this._options[normalizedName] = options;
2029
2073
  },
@@ -2345,9 +2389,75 @@ enifed('container/registry', ['exports', 'ember-metal/debug', 'ember-metal/dicti
2345
2389
  };
2346
2390
  }
2347
2391
 
2348
- function resolve(registry, normalizedName) {
2392
+ if (_emberMetalFeatures.default('ember-htmlbars-local-lookup')) {
2393
+ /**
2394
+ Given a fullName and a source fullName returns the fully resolved
2395
+ fullName. Used to allow for local lookup.
2396
+ ```javascript
2397
+ var registry = new Registry();
2398
+ // the twitter factory is added to the module system
2399
+ registry.expandLocalLookup('component:post-title', { source: 'template:post' }) // => component:post/post-title
2400
+ ```
2401
+ @private
2402
+ @method expandLocalLookup
2403
+ @param {String} fullName
2404
+ @param {Object} [options]
2405
+ @param {String} [options.source] the fullname of the request source (used for local lookups)
2406
+ @return {String} fullName
2407
+ */
2408
+ Registry.prototype.expandLocalLookup = function Registry_expandLocalLookup(fullName, options) {
2409
+ if (this.resolver && this.resolver.expandLocalLookup) {
2410
+ _emberMetalDebug.assert('fullName must be a proper full name', this.validateFullName(fullName));
2411
+ _emberMetalDebug.assert('options.source must be provided to expandLocalLookup', options && options.source);
2412
+ _emberMetalDebug.assert('options.source must be a proper full name', this.validateFullName(options.source));
2413
+
2414
+ var normalizedFullName = this.normalize(fullName);
2415
+ var normalizedSource = this.normalize(options.source);
2416
+
2417
+ return expandLocalLookup(this, normalizedFullName, normalizedSource);
2418
+ } else if (this.fallback) {
2419
+ return this.fallback.expandLocalLookup(fullName, options);
2420
+ } else {
2421
+ return null;
2422
+ }
2423
+ };
2424
+ }
2425
+
2426
+ function expandLocalLookup(registry, normalizedName, normalizedSource) {
2427
+ var cache = registry._localLookupCache;
2428
+ var normalizedNameCache = cache[normalizedName];
2429
+
2430
+ if (!normalizedNameCache) {
2431
+ normalizedNameCache = cache[normalizedName] = new _emberMetalEmpty_object.default();
2432
+ }
2433
+
2434
+ var cached = normalizedNameCache[normalizedSource];
2435
+
2436
+ if (cached !== undefined) {
2437
+ return cached;
2438
+ }
2439
+
2440
+ var expanded = registry.resolver.expandLocalLookup(normalizedName, normalizedSource);
2441
+
2442
+ return normalizedNameCache[normalizedSource] = expanded;
2443
+ }
2444
+
2445
+ function resolve(registry, normalizedName, options) {
2446
+ if (_emberMetalFeatures.default('ember-htmlbars-local-lookup')) {
2447
+ if (options && options.source) {
2448
+ // when `source` is provided expand normalizedName
2449
+ // and source into the full normalizedName
2450
+ normalizedName = registry.expandLocalLookup(normalizedName, options);
2451
+
2452
+ // if expandLocalLookup returns falsey, we do not support local lookup
2453
+ if (!normalizedName) {
2454
+ return;
2455
+ }
2456
+ }
2457
+ }
2458
+
2349
2459
  var cached = registry._resolveCache[normalizedName];
2350
- if (cached) {
2460
+ if (cached !== undefined) {
2351
2461
  return cached;
2352
2462
  }
2353
2463
  if (registry._failCache[normalizedName]) {
@@ -2360,49 +2470,25 @@ enifed('container/registry', ['exports', 'ember-metal/debug', 'ember-metal/dicti
2360
2470
  resolved = registry.resolver.resolve(normalizedName);
2361
2471
  }
2362
2472
 
2363
- resolved = resolved || registry.registrations[normalizedName];
2473
+ if (resolved === undefined) {
2474
+ resolved = registry.registrations[normalizedName];
2475
+ }
2364
2476
 
2365
- if (resolved) {
2366
- registry._resolveCache[normalizedName] = resolved;
2367
- } else {
2477
+ if (resolved === undefined) {
2368
2478
  registry._failCache[normalizedName] = true;
2479
+ } else {
2480
+ registry._resolveCache[normalizedName] = resolved;
2369
2481
  }
2370
2482
 
2371
2483
  return resolved;
2372
2484
  }
2373
2485
 
2374
- function has(registry, fullName) {
2375
- return registry.resolve(fullName) !== undefined;
2486
+ function has(registry, fullName, source) {
2487
+ return registry.resolve(fullName, { source: source }) !== undefined;
2376
2488
  }
2377
2489
 
2378
2490
  exports.default = Registry;
2379
2491
  });
2380
- enifed('container', ['exports', 'ember-metal/core', 'container/registry', 'container/container', 'container/owner'], function (exports, _emberMetalCore, _containerRegistry, _containerContainer, _containerOwner) {
2381
- 'use strict';
2382
-
2383
- /*
2384
- Public api for the container is still in flux.
2385
- The public api, specified on the application namespace should be considered the stable api.
2386
- // @module container
2387
- @private
2388
- */
2389
-
2390
- /*
2391
- Flag to enable/disable model factory injections (disabled by default)
2392
- If model factory injections are enabled, models should not be
2393
- accessed globally (only through `container.lookupFactory('model:modelName'))`);
2394
- */
2395
- _emberMetalCore.default.MODEL_FACTORY_INJECTIONS = false;
2396
-
2397
- if (_emberMetalCore.default.ENV && typeof _emberMetalCore.default.ENV.MODEL_FACTORY_INJECTIONS !== 'undefined') {
2398
- _emberMetalCore.default.MODEL_FACTORY_INJECTIONS = !!_emberMetalCore.default.ENV.MODEL_FACTORY_INJECTIONS;
2399
- }
2400
-
2401
- exports.Registry = _containerRegistry.default;
2402
- exports.Container = _containerContainer.default;
2403
- exports.getOwner = _containerOwner.getOwner;
2404
- exports.setOwner = _containerOwner.setOwner;
2405
- });
2406
2492
  enifed('ember-metal/alias', ['exports', 'ember-metal/debug', 'ember-metal/property_get', 'ember-metal/property_set', 'ember-metal/error', 'ember-metal/properties', 'ember-metal/computed', 'ember-metal/utils', 'ember-metal/meta', 'ember-metal/dependent_keys'], function (exports, _emberMetalDebug, _emberMetalProperty_get, _emberMetalProperty_set, _emberMetalError, _emberMetalProperties, _emberMetalComputed, _emberMetalUtils, _emberMetalMeta, _emberMetalDependent_keys) {
2407
2493
  'use strict';
2408
2494
 
@@ -3104,9 +3190,9 @@ enifed('ember-metal/chains', ['exports', 'ember-metal/debug', 'ember-metal/prope
3104
3190
  },
3105
3191
 
3106
3192
  // key: the string key that is part of a path changed
3107
- // revalidate: boolean the chains that are watching this value should revalidate
3108
- // callback: function that will be called with the the object and path that
3109
- // will be/are invalidated by this key change depending on the
3193
+ // revalidate: boolean; the chains that are watching this value should revalidate
3194
+ // callback: function that will be called with the object and path that
3195
+ // will be/are invalidated by this key change, depending on
3110
3196
  // whether the revalidate flag is passed
3111
3197
  notify: function (key, revalidate, callback) {
3112
3198
  var nodes = this.chains[key];
@@ -3463,6 +3549,8 @@ enifed('ember-metal/computed', ['exports', 'ember-metal/debug', 'ember-metal/pro
3463
3549
 
3464
3550
  function UNDEFINED() {}
3465
3551
 
3552
+ var DEEP_EACH_REGEX = /\.@each\.[^.]+\./;
3553
+
3466
3554
  // ..........................................................
3467
3555
  // COMPUTED PROPERTY
3468
3556
  //
@@ -3690,6 +3778,7 @@ enifed('ember-metal/computed', ['exports', 'ember-metal/debug', 'ember-metal/pro
3690
3778
  var args;
3691
3779
 
3692
3780
  var addArg = function (property) {
3781
+ _emberMetalDebug.warn('Dependent keys containing @each only work one level deep. ' + 'You cannot use nested forms like todos.@each.owner.name or todos.@each.owner.@each.name. ' + 'Please create an intermediary computed property.', DEEP_EACH_REGEX.test(property) === false, { id: 'ember-metal.computed-deep-each' });
3693
3782
  args.push(property);
3694
3783
  };
3695
3784
 
@@ -4770,9 +4859,11 @@ enifed('ember-metal/computed_macros', ['exports', 'ember-metal/debug', 'ember-me
4770
4859
  });
4771
4860
  }
4772
4861
  });
4773
- enifed('ember-metal/core', ['exports'], function (exports) {
4862
+ enifed('ember-metal/core', ['exports', 'require'], function (exports, _require) {
4774
4863
  /*globals Ember:true,ENV,EmberENV */
4775
4864
 
4865
+ 'use strict';
4866
+
4776
4867
  /**
4777
4868
  @module ember
4778
4869
  @submodule ember-metal
@@ -4793,12 +4884,10 @@ enifed('ember-metal/core', ['exports'], function (exports) {
4793
4884
 
4794
4885
  @class Ember
4795
4886
  @static
4796
- @version 2.3.2
4887
+ @version 2.4.0-beta.2
4797
4888
  @public
4798
4889
  */
4799
4890
 
4800
- 'use strict';
4801
-
4802
4891
  if ('undefined' === typeof Ember) {
4803
4892
  // Create core object. Make it act like an instance of Ember.Namespace so that
4804
4893
  // objects assigned to it are given a sane string representation.
@@ -4824,7 +4913,7 @@ enifed('ember-metal/core', ['exports'], function (exports) {
4824
4913
 
4825
4914
  // The debug functions are exported to globals with `require` to
4826
4915
  // prevent babel-plugin-filter-imports from removing them.
4827
- var debugModule = Ember.__loader.require('ember-metal/debug');
4916
+ var debugModule = _require.default('ember-metal/debug');
4828
4917
  Ember.assert = debugModule.assert;
4829
4918
  Ember.warn = debugModule.warn;
4830
4919
  Ember.debug = debugModule.debug;
@@ -4837,11 +4926,11 @@ enifed('ember-metal/core', ['exports'], function (exports) {
4837
4926
 
4838
4927
  @property VERSION
4839
4928
  @type String
4840
- @default '2.3.2'
4929
+ @default '2.4.0-beta.2'
4841
4930
  @static
4842
4931
  @public
4843
4932
  */
4844
- Ember.VERSION = '2.3.2';
4933
+ Ember.VERSION = '2.4.0-beta.2';
4845
4934
 
4846
4935
  /**
4847
4936
  The hash of environment variables used to control various configuration
@@ -5107,18 +5196,24 @@ enifed('ember-metal/deprecate_property', ['exports', 'ember-metal/debug', 'ember
5107
5196
  });
5108
5197
  }
5109
5198
  });
5110
- enifed('ember-metal/dictionary', ['exports'], function (exports) {
5199
+ enifed('ember-metal/dictionary', ['exports', 'ember-metal/empty_object'], function (exports, _emberMetalEmpty_object) {
5200
+ 'use strict';
5201
+
5202
+ exports.default = makeDictionary;
5203
+
5111
5204
  // the delete is meant to hint at runtimes that this object should remain in
5112
5205
  // dictionary mode. This is clearly a runtime specific hack, but currently it
5113
5206
  // appears worthwhile in some usecases. Please note, these deletes do increase
5114
5207
  // the cost of creation dramatically over a plain Object.create. And as this
5115
5208
  // only makes sense for long-lived dictionaries that aren't instantiated often.
5116
- 'use strict';
5117
-
5118
- exports.default = makeDictionary;
5119
5209
 
5120
5210
  function makeDictionary(parent) {
5121
- var dict = Object.create(parent);
5211
+ var dict;
5212
+ if (parent === null) {
5213
+ dict = new _emberMetalEmpty_object.default();
5214
+ } else {
5215
+ dict = Object.create(parent);
5216
+ }
5122
5217
  dict['_dict'] = null;
5123
5218
  delete dict['_dict'];
5124
5219
  return dict;
@@ -5739,74 +5834,293 @@ enifed('ember-metal/get_properties', ['exports', 'ember-metal/property_get'], fu
5739
5834
  return ret;
5740
5835
  }
5741
5836
  });
5742
- enifed('ember-metal/injected_property', ['exports', 'ember-metal/debug', 'ember-metal/computed', 'ember-metal/alias', 'ember-metal/properties', 'container/owner'], function (exports, _emberMetalDebug, _emberMetalComputed, _emberMetalAlias, _emberMetalProperties, _containerOwner) {
5743
- 'use strict';
5744
-
5837
+ enifed('ember-metal/index', ['exports', 'require', 'ember-metal/core', 'ember-metal/debug', 'ember-metal/features', 'ember-metal/assign', 'ember-metal/merge', 'ember-metal/instrumentation', 'ember-metal/utils', 'ember-metal/meta', 'ember-metal/error', 'ember-metal/cache', 'ember-metal/logger', 'ember-metal/property_get', 'ember-metal/events', 'ember-metal/observer_set', 'ember-metal/property_events', 'ember-metal/properties', 'ember-metal/property_set', 'ember-metal/map', 'ember-metal/get_properties', 'ember-metal/set_properties', 'ember-metal/watch_key', 'ember-metal/chains', 'ember-metal/watch_path', 'ember-metal/watching', 'ember-metal/expand_properties', 'ember-metal/computed', 'ember-metal/alias', 'ember-metal/computed_macros', 'ember-metal/observer', 'ember-metal/mixin', 'ember-metal/binding', 'ember-metal/run_loop', 'ember-metal/libraries', 'ember-metal/is_none', 'ember-metal/is_empty', 'ember-metal/is_blank', 'ember-metal/is_present', 'backburner'], function (exports, _require, _emberMetalCore, _emberMetalDebug, _emberMetalFeatures, _emberMetalAssign, _emberMetalMerge, _emberMetalInstrumentation, _emberMetalUtils, _emberMetalMeta, _emberMetalError, _emberMetalCache, _emberMetalLogger, _emberMetalProperty_get, _emberMetalEvents, _emberMetalObserver_set, _emberMetalProperty_events, _emberMetalProperties, _emberMetalProperty_set, _emberMetalMap, _emberMetalGet_properties, _emberMetalSet_properties, _emberMetalWatch_key, _emberMetalChains, _emberMetalWatch_path, _emberMetalWatching, _emberMetalExpand_properties, _emberMetalComputed, _emberMetalAlias, _emberMetalComputed_macros, _emberMetalObserver, _emberMetalMixin, _emberMetalBinding, _emberMetalRun_loop, _emberMetalLibraries, _emberMetalIs_none, _emberMetalIs_empty, _emberMetalIs_blank, _emberMetalIs_present, _backburner) {
5745
5838
  /**
5746
- Read-only property that returns the result of a container lookup.
5747
-
5748
- @class InjectedProperty
5749
- @namespace Ember
5750
- @constructor
5751
- @param {String} type The container type the property will lookup
5752
- @param {String} name (optional) The name the property will lookup, defaults
5753
- to the property's name
5754
- @private
5839
+ @module ember
5840
+ @submodule ember-metal
5755
5841
  */
5756
- function InjectedProperty(type, name) {
5757
- this.type = type;
5758
- this.name = name;
5759
5842
 
5760
- this._super$Constructor(injectedPropertyGet);
5761
- AliasedPropertyPrototype.oneWay.call(this);
5762
- }
5843
+ // BEGIN IMPORTS
5844
+ 'use strict';
5763
5845
 
5764
- function injectedPropertyGet(keyName) {
5765
- var desc = this[keyName];
5766
- var owner = _containerOwner.getOwner(this);
5846
+ _emberMetalComputed.computed.empty = _emberMetalComputed_macros.empty;
5847
+ _emberMetalComputed.computed.notEmpty = _emberMetalComputed_macros.notEmpty;
5848
+ _emberMetalComputed.computed.none = _emberMetalComputed_macros.none;
5849
+ _emberMetalComputed.computed.not = _emberMetalComputed_macros.not;
5850
+ _emberMetalComputed.computed.bool = _emberMetalComputed_macros.bool;
5851
+ _emberMetalComputed.computed.match = _emberMetalComputed_macros.match;
5852
+ _emberMetalComputed.computed.equal = _emberMetalComputed_macros.equal;
5853
+ _emberMetalComputed.computed.gt = _emberMetalComputed_macros.gt;
5854
+ _emberMetalComputed.computed.gte = _emberMetalComputed_macros.gte;
5855
+ _emberMetalComputed.computed.lt = _emberMetalComputed_macros.lt;
5856
+ _emberMetalComputed.computed.lte = _emberMetalComputed_macros.lte;
5857
+ _emberMetalComputed.computed.alias = _emberMetalAlias.default;
5858
+ _emberMetalComputed.computed.oneWay = _emberMetalComputed_macros.oneWay;
5859
+ _emberMetalComputed.computed.reads = _emberMetalComputed_macros.oneWay;
5860
+ _emberMetalComputed.computed.readOnly = _emberMetalComputed_macros.readOnly;
5861
+ _emberMetalComputed.computed.defaultTo = _emberMetalComputed_macros.defaultTo;
5862
+ _emberMetalComputed.computed.deprecatingAlias = _emberMetalComputed_macros.deprecatingAlias;
5863
+ _emberMetalComputed.computed.and = _emberMetalComputed_macros.and;
5864
+ _emberMetalComputed.computed.or = _emberMetalComputed_macros.or;
5865
+ _emberMetalComputed.computed.any = _emberMetalComputed_macros.any;
5767
5866
 
5768
- _emberMetalDebug.assert('InjectedProperties should be defined with the Ember.inject computed property macros.', desc && desc.isDescriptor && desc.type);
5769
- _emberMetalDebug.assert('Attempting to lookup an injected property on an object without a container, ensure that the object was instantiated via a container.', owner);
5867
+ // END IMPORTS
5770
5868
 
5771
- return owner.lookup(desc.type + ':' + (desc.name || keyName));
5772
- }
5869
+ // BEGIN EXPORTS
5870
+ var EmberInstrumentation = _emberMetalCore.default.Instrumentation = {};
5871
+ EmberInstrumentation.instrument = _emberMetalInstrumentation.instrument;
5872
+ EmberInstrumentation.subscribe = _emberMetalInstrumentation.subscribe;
5873
+ EmberInstrumentation.unsubscribe = _emberMetalInstrumentation.unsubscribe;
5874
+ EmberInstrumentation.reset = _emberMetalInstrumentation.reset;
5773
5875
 
5774
- InjectedProperty.prototype = Object.create(_emberMetalProperties.Descriptor.prototype);
5876
+ _emberMetalCore.default.instrument = _emberMetalInstrumentation.instrument;
5877
+ _emberMetalCore.default.subscribe = _emberMetalInstrumentation.subscribe;
5775
5878
 
5776
- var InjectedPropertyPrototype = InjectedProperty.prototype;
5777
- var ComputedPropertyPrototype = _emberMetalComputed.ComputedProperty.prototype;
5778
- var AliasedPropertyPrototype = _emberMetalAlias.AliasedProperty.prototype;
5879
+ _emberMetalCore.default._Cache = _emberMetalCache.default;
5779
5880
 
5780
- InjectedPropertyPrototype._super$Constructor = _emberMetalComputed.ComputedProperty;
5881
+ _emberMetalCore.default.generateGuid = _emberMetalUtils.generateGuid;
5882
+ _emberMetalCore.default.GUID_KEY = _emberMetalUtils.GUID_KEY;
5883
+ _emberMetalCore.default.platform = {
5884
+ defineProperty: true,
5885
+ hasPropertyAccessors: true
5886
+ };
5781
5887
 
5782
- InjectedPropertyPrototype.get = ComputedPropertyPrototype.get;
5783
- InjectedPropertyPrototype.readOnly = ComputedPropertyPrototype.readOnly;
5888
+ _emberMetalCore.default.Error = _emberMetalError.default;
5889
+ _emberMetalCore.default.guidFor = _emberMetalUtils.guidFor;
5890
+ _emberMetalCore.default.META_DESC = _emberMetalMeta.META_DESC;
5891
+ _emberMetalCore.default.meta = _emberMetalMeta.meta;
5892
+ _emberMetalCore.default.inspect = _emberMetalUtils.inspect;
5784
5893
 
5785
- InjectedPropertyPrototype.teardown = ComputedPropertyPrototype.teardown;
5894
+ _emberMetalCore.default.tryCatchFinally = _emberMetalUtils.deprecatedTryCatchFinally;
5895
+ _emberMetalCore.default.makeArray = _emberMetalUtils.makeArray;
5896
+ _emberMetalCore.default.canInvoke = _emberMetalUtils.canInvoke;
5897
+ _emberMetalCore.default.tryInvoke = _emberMetalUtils.tryInvoke;
5898
+ _emberMetalCore.default.wrap = _emberMetalUtils.wrap;
5899
+ _emberMetalCore.default.apply = _emberMetalUtils.apply;
5900
+ _emberMetalCore.default.applyStr = _emberMetalUtils.applyStr;
5901
+ _emberMetalCore.default.uuid = _emberMetalUtils.uuid;
5786
5902
 
5787
- exports.default = InjectedProperty;
5788
- });
5789
- enifed('ember-metal/instrumentation', ['exports', 'ember-metal/core'], function (exports, _emberMetalCore) {
5790
- 'use strict';
5903
+ _emberMetalCore.default.Logger = _emberMetalLogger.default;
5791
5904
 
5792
- exports.instrument = instrument;
5793
- exports._instrumentStart = _instrumentStart;
5794
- exports.subscribe = subscribe;
5795
- exports.unsubscribe = unsubscribe;
5796
- exports.reset = reset;
5905
+ _emberMetalCore.default.get = _emberMetalProperty_get.get;
5906
+ _emberMetalCore.default.getWithDefault = _emberMetalProperty_get.getWithDefault;
5907
+ _emberMetalCore.default.normalizeTuple = _emberMetalProperty_get.normalizeTuple;
5908
+ _emberMetalCore.default._getPath = _emberMetalProperty_get._getPath;
5797
5909
 
5798
- /**
5799
- The purpose of the Ember Instrumentation module is
5800
- to provide efficient, general-purpose instrumentation
5801
- for Ember.
5802
-
5803
- Subscribe to a listener by using `Ember.subscribe`:
5804
-
5805
- ```javascript
5806
- Ember.subscribe("render", {
5807
- before: function(name, timestamp, payload) {
5808
-
5809
- },
5910
+ _emberMetalCore.default.on = _emberMetalEvents.on;
5911
+ _emberMetalCore.default.addListener = _emberMetalEvents.addListener;
5912
+ _emberMetalCore.default.removeListener = _emberMetalEvents.removeListener;
5913
+ _emberMetalCore.default._suspendListener = _emberMetalEvents.suspendListener;
5914
+ _emberMetalCore.default._suspendListeners = _emberMetalEvents.suspendListeners;
5915
+ _emberMetalCore.default.sendEvent = _emberMetalEvents.sendEvent;
5916
+ _emberMetalCore.default.hasListeners = _emberMetalEvents.hasListeners;
5917
+ _emberMetalCore.default.watchedEvents = _emberMetalEvents.watchedEvents;
5918
+ _emberMetalCore.default.listenersFor = _emberMetalEvents.listenersFor;
5919
+ _emberMetalCore.default.accumulateListeners = _emberMetalEvents.accumulateListeners;
5920
+
5921
+ _emberMetalCore.default._ObserverSet = _emberMetalObserver_set.default;
5922
+
5923
+ _emberMetalCore.default.propertyWillChange = _emberMetalProperty_events.propertyWillChange;
5924
+ _emberMetalCore.default.propertyDidChange = _emberMetalProperty_events.propertyDidChange;
5925
+ _emberMetalCore.default.overrideChains = _emberMetalProperty_events.overrideChains;
5926
+ _emberMetalCore.default.beginPropertyChanges = _emberMetalProperty_events.beginPropertyChanges;
5927
+ _emberMetalCore.default.endPropertyChanges = _emberMetalProperty_events.endPropertyChanges;
5928
+ _emberMetalCore.default.changeProperties = _emberMetalProperty_events.changeProperties;
5929
+
5930
+ _emberMetalCore.default.defineProperty = _emberMetalProperties.defineProperty;
5931
+
5932
+ _emberMetalCore.default.set = _emberMetalProperty_set.set;
5933
+ _emberMetalCore.default.trySet = _emberMetalProperty_set.trySet;
5934
+
5935
+ _emberMetalCore.default.OrderedSet = _emberMetalMap.OrderedSet;
5936
+ _emberMetalCore.default.Map = _emberMetalMap.Map;
5937
+ _emberMetalCore.default.MapWithDefault = _emberMetalMap.MapWithDefault;
5938
+
5939
+ _emberMetalCore.default.getProperties = _emberMetalGet_properties.default;
5940
+ _emberMetalCore.default.setProperties = _emberMetalSet_properties.default;
5941
+
5942
+ _emberMetalCore.default.watchKey = _emberMetalWatch_key.watchKey;
5943
+ _emberMetalCore.default.unwatchKey = _emberMetalWatch_key.unwatchKey;
5944
+
5945
+ _emberMetalCore.default.flushPendingChains = _emberMetalChains.flushPendingChains;
5946
+ _emberMetalCore.default.removeChainWatcher = _emberMetalChains.removeChainWatcher;
5947
+ _emberMetalCore.default._ChainNode = _emberMetalChains.ChainNode;
5948
+ _emberMetalCore.default.finishChains = _emberMetalChains.finishChains;
5949
+
5950
+ _emberMetalCore.default.watchPath = _emberMetalWatch_path.watchPath;
5951
+ _emberMetalCore.default.unwatchPath = _emberMetalWatch_path.unwatchPath;
5952
+
5953
+ _emberMetalCore.default.watch = _emberMetalWatching.watch;
5954
+ _emberMetalCore.default.isWatching = _emberMetalWatching.isWatching;
5955
+ _emberMetalCore.default.unwatch = _emberMetalWatching.unwatch;
5956
+ _emberMetalCore.default.rewatch = _emberMetalWatching.rewatch;
5957
+ _emberMetalCore.default.destroy = _emberMetalWatching.destroy;
5958
+
5959
+ _emberMetalCore.default.expandProperties = _emberMetalExpand_properties.default;
5960
+
5961
+ _emberMetalCore.default.ComputedProperty = _emberMetalComputed.ComputedProperty;
5962
+ _emberMetalCore.default.computed = _emberMetalComputed.computed;
5963
+ _emberMetalCore.default.cacheFor = _emberMetalComputed.cacheFor;
5964
+
5965
+ _emberMetalCore.default.addObserver = _emberMetalObserver.addObserver;
5966
+ _emberMetalCore.default.observersFor = _emberMetalObserver.observersFor;
5967
+ _emberMetalCore.default.removeObserver = _emberMetalObserver.removeObserver;
5968
+ _emberMetalCore.default._suspendObserver = _emberMetalObserver._suspendObserver;
5969
+ _emberMetalCore.default._suspendObservers = _emberMetalObserver._suspendObservers;
5970
+
5971
+ _emberMetalCore.default.IS_BINDING = _emberMetalMixin.IS_BINDING;
5972
+ _emberMetalCore.default.required = _emberMetalMixin.required;
5973
+ _emberMetalCore.default.aliasMethod = _emberMetalMixin.aliasMethod;
5974
+ _emberMetalCore.default.observer = _emberMetalMixin.observer;
5975
+ _emberMetalCore.default.immediateObserver = _emberMetalMixin._immediateObserver;
5976
+ _emberMetalCore.default.mixin = _emberMetalMixin.mixin;
5977
+ _emberMetalCore.default.Mixin = _emberMetalMixin.Mixin;
5978
+
5979
+ _emberMetalCore.default.bind = _emberMetalBinding.bind;
5980
+ _emberMetalCore.default.Binding = _emberMetalBinding.Binding;
5981
+ _emberMetalCore.default.isGlobalPath = _emberMetalBinding.isGlobalPath;
5982
+
5983
+ _emberMetalCore.default.run = _emberMetalRun_loop.default;
5984
+
5985
+ /**
5986
+ @class Backburner
5987
+ @for Ember
5988
+ @private
5989
+ */
5990
+ _emberMetalCore.default.Backburner = _backburner.default;
5991
+ // this is the new go forward, once Ember Data updates to using `_Backburner` we
5992
+ // can remove the non-underscored version.
5993
+ _emberMetalCore.default._Backburner = _backburner.default;
5994
+
5995
+ _emberMetalCore.default.libraries = new _emberMetalLibraries.default();
5996
+ _emberMetalCore.default.libraries.registerCoreLibrary('Ember', _emberMetalCore.default.VERSION);
5997
+
5998
+ _emberMetalCore.default.isNone = _emberMetalIs_none.default;
5999
+ _emberMetalCore.default.isEmpty = _emberMetalIs_empty.default;
6000
+ _emberMetalCore.default.isBlank = _emberMetalIs_blank.default;
6001
+ _emberMetalCore.default.isPresent = _emberMetalIs_present.default;
6002
+
6003
+ if (_emberMetalFeatures.default('ember-metal-ember-assign')) {
6004
+ _emberMetalCore.default.assign = Object.assign || _emberMetalAssign.default;
6005
+ _emberMetalCore.default.merge = _emberMetalMerge.default;
6006
+ } else {
6007
+ _emberMetalCore.default.merge = _emberMetalMerge.default;
6008
+ }
6009
+
6010
+ _emberMetalCore.default.FEATURES = _emberMetalFeatures.FEATURES;
6011
+ _emberMetalCore.default.FEATURES.isEnabled = _emberMetalFeatures.default;
6012
+
6013
+ /**
6014
+ A function may be assigned to `Ember.onerror` to be called when Ember
6015
+ internals encounter an error. This is useful for specialized error handling
6016
+ and reporting code.
6017
+
6018
+ ```javascript
6019
+ Ember.onerror = function(error) {
6020
+ Em.$.ajax('/report-error', 'POST', {
6021
+ stack: error.stack,
6022
+ otherInformation: 'whatever app state you want to provide'
6023
+ });
6024
+ };
6025
+ ```
6026
+
6027
+ Internally, `Ember.onerror` is used as Backburner's error handler.
6028
+
6029
+ @event onerror
6030
+ @for Ember
6031
+ @param {Exception} error the error object
6032
+ @public
6033
+ */
6034
+ _emberMetalCore.default.onerror = null;
6035
+ // END EXPORTS
6036
+
6037
+ // do this for side-effects of updating Ember.assert, warn, etc when
6038
+ // ember-debug is present
6039
+ // This needs to be called before any deprecateFunc
6040
+ if (_require.has('ember-debug')) {
6041
+ _require.default('ember-debug');
6042
+ } else {
6043
+ _emberMetalCore.default.Debug = {};
6044
+
6045
+ if (_emberMetalFeatures.default('ember-debug-handlers')) {
6046
+ _emberMetalCore.default.Debug.registerDeprecationHandler = function () {};
6047
+ _emberMetalCore.default.Debug.registerWarnHandler = function () {};
6048
+ }
6049
+ }
6050
+
6051
+ _emberMetalCore.default.create = _emberMetalDebug.deprecateFunc('Ember.create is deprecated in favor of Object.create', { id: 'ember-metal.ember-create', until: '3.0.0' }, Object.create);
6052
+ _emberMetalCore.default.keys = _emberMetalDebug.deprecateFunc('Ember.keys is deprecated in favor of Object.keys', { id: 'ember-metal.ember.keys', until: '3.0.0' }, Object.keys);
6053
+
6054
+ exports.default = _emberMetalCore.default;
6055
+ });
6056
+ enifed('ember-metal/injected_property', ['exports', 'ember-metal/debug', 'ember-metal/computed', 'ember-metal/alias', 'ember-metal/properties', 'container/owner'], function (exports, _emberMetalDebug, _emberMetalComputed, _emberMetalAlias, _emberMetalProperties, _containerOwner) {
6057
+ 'use strict';
6058
+
6059
+ /**
6060
+ Read-only property that returns the result of a container lookup.
6061
+
6062
+ @class InjectedProperty
6063
+ @namespace Ember
6064
+ @constructor
6065
+ @param {String} type The container type the property will lookup
6066
+ @param {String} name (optional) The name the property will lookup, defaults
6067
+ to the property's name
6068
+ @private
6069
+ */
6070
+ function InjectedProperty(type, name) {
6071
+ this.type = type;
6072
+ this.name = name;
6073
+
6074
+ this._super$Constructor(injectedPropertyGet);
6075
+ AliasedPropertyPrototype.oneWay.call(this);
6076
+ }
6077
+
6078
+ function injectedPropertyGet(keyName) {
6079
+ var desc = this[keyName];
6080
+ var owner = _containerOwner.getOwner(this);
6081
+
6082
+ _emberMetalDebug.assert('InjectedProperties should be defined with the Ember.inject computed property macros.', desc && desc.isDescriptor && desc.type);
6083
+ _emberMetalDebug.assert('Attempting to lookup an injected property on an object without a container, ensure that the object was instantiated via a container.', owner);
6084
+
6085
+ return owner.lookup(desc.type + ':' + (desc.name || keyName));
6086
+ }
6087
+
6088
+ InjectedProperty.prototype = Object.create(_emberMetalProperties.Descriptor.prototype);
6089
+
6090
+ var InjectedPropertyPrototype = InjectedProperty.prototype;
6091
+ var ComputedPropertyPrototype = _emberMetalComputed.ComputedProperty.prototype;
6092
+ var AliasedPropertyPrototype = _emberMetalAlias.AliasedProperty.prototype;
6093
+
6094
+ InjectedPropertyPrototype._super$Constructor = _emberMetalComputed.ComputedProperty;
6095
+
6096
+ InjectedPropertyPrototype.get = ComputedPropertyPrototype.get;
6097
+ InjectedPropertyPrototype.readOnly = ComputedPropertyPrototype.readOnly;
6098
+
6099
+ InjectedPropertyPrototype.teardown = ComputedPropertyPrototype.teardown;
6100
+
6101
+ exports.default = InjectedProperty;
6102
+ });
6103
+ enifed('ember-metal/instrumentation', ['exports', 'ember-metal/core'], function (exports, _emberMetalCore) {
6104
+ 'use strict';
6105
+
6106
+ exports.instrument = instrument;
6107
+ exports._instrumentStart = _instrumentStart;
6108
+ exports.subscribe = subscribe;
6109
+ exports.unsubscribe = unsubscribe;
6110
+ exports.reset = reset;
6111
+
6112
+ /**
6113
+ The purpose of the Ember Instrumentation module is
6114
+ to provide efficient, general-purpose instrumentation
6115
+ for Ember.
6116
+
6117
+ Subscribe to a listener by using `Ember.subscribe`:
6118
+
6119
+ ```javascript
6120
+ Ember.subscribe("render", {
6121
+ before: function(name, timestamp, payload) {
6122
+
6123
+ },
5810
6124
 
5811
6125
  after: function(name, timestamp, payload) {
5812
6126
 
@@ -6178,13 +6492,18 @@ enifed('ember-metal/is_present', ['exports', 'ember-metal/is_blank'], function (
6178
6492
  Ember.isPresent(null); // false
6179
6493
  Ember.isPresent(undefined); // false
6180
6494
  Ember.isPresent(''); // false
6181
- Ember.isPresent([]); // false
6182
- Ember.isPresent('\n\t'); // false
6183
6495
  Ember.isPresent(' '); // false
6496
+ Ember.isPresent('\n\t'); // false
6497
+ Ember.isPresent([]); // false
6498
+ Ember.isPresent({ length: 0 }) // false
6499
+ Ember.isPresent(false); // true
6500
+ Ember.isPresent(true); // true
6501
+ Ember.isPresent('string'); // true
6502
+ Ember.isPresent(0); // true
6503
+ Ember.isPresent(function() {}) // true
6184
6504
  Ember.isPresent({}); // true
6185
6505
  Ember.isPresent(false); // true
6186
6506
  Ember.isPresent('\n\t Hello'); // true
6187
- Ember.isPresent('Hello world'); // true
6188
6507
  Ember.isPresent([1,2,3]); // true
6189
6508
  ```
6190
6509
 
@@ -7968,7 +8287,7 @@ enifed('ember-metal/mixin', ['exports', 'ember-metal/core', 'ember-metal/error',
7968
8287
  //filters will be created as a separate array during the object's initialization
7969
8288
  App.Filterable = Ember.Mixin.create({
7970
8289
  init: function() {
7971
- this._super.apply(this, arguments);
8290
+ this._super(...arguments);
7972
8291
  this.set("filters", Ember.A());
7973
8292
  }
7974
8293
  });
@@ -8703,6 +9022,7 @@ enifed('ember-metal/properties', ['exports', 'ember-metal/debug', 'ember-metal/f
8703
9022
  exports.Descriptor = Descriptor;
8704
9023
  exports.MANDATORY_SETTER_FUNCTION = MANDATORY_SETTER_FUNCTION;
8705
9024
  exports.DEFAULT_GETTER_FUNCTION = DEFAULT_GETTER_FUNCTION;
9025
+ exports.INHERITING_GETTER_FUNCTION = INHERITING_GETTER_FUNCTION;
8706
9026
  exports.defineProperty = defineProperty;
8707
9027
 
8708
9028
  // ..........................................................
@@ -8721,14 +9041,33 @@ enifed('ember-metal/properties', ['exports', 'ember-metal/debug', 'ember-metal/f
8721
9041
  this.isDescriptor = true;
8722
9042
  }
8723
9043
 
9044
+ var REDEFINE_SUPPORTED = (function () {
9045
+ // https://github.com/spalger/kibana/commit/b7e35e6737df585585332857a4c397dc206e7ff9
9046
+ var a = Object.create(Object.prototype, {
9047
+ prop: {
9048
+ configurable: true,
9049
+ value: 1
9050
+ }
9051
+ });
9052
+
9053
+ Object.defineProperty(a, 'prop', {
9054
+ configurable: true,
9055
+ value: 2
9056
+ });
9057
+
9058
+ return a.prop === 2;
9059
+ })();
8724
9060
  // ..........................................................
8725
9061
  // DEFINING PROPERTIES API
8726
9062
  //
8727
9063
 
8728
9064
  function MANDATORY_SETTER_FUNCTION(name) {
8729
- return function SETTER_FUNCTION(value) {
9065
+ function SETTER_FUNCTION(value) {
8730
9066
  _emberMetalDebug.assert('You must use Ember.set() to set the `' + name + '` property (of ' + this + ') to `' + value + '`.', false);
8731
- };
9067
+ }
9068
+
9069
+ SETTER_FUNCTION.isMandatorySetter = true;
9070
+ return SETTER_FUNCTION;
8732
9071
  }
8733
9072
 
8734
9073
  function DEFAULT_GETTER_FUNCTION(name) {
@@ -8738,6 +9077,16 @@ enifed('ember-metal/properties', ['exports', 'ember-metal/debug', 'ember-metal/f
8738
9077
  };
8739
9078
  }
8740
9079
 
9080
+ function INHERITING_GETTER_FUNCTION(name) {
9081
+ function IGETTER_FUNCTION() {
9082
+ var proto = Object.getPrototypeOf(this);
9083
+ return proto && proto[name];
9084
+ }
9085
+
9086
+ IGETTER_FUNCTION.isInheritingGetter = true;
9087
+ return IGETTER_FUNCTION;
9088
+ }
9089
+
8741
9090
  /**
8742
9091
  NOTE: This is a low-level method used by other parts of the API. You almost
8743
9092
  never want to call this method directly. Instead you should use
@@ -8826,12 +9175,19 @@ enifed('ember-metal/properties', ['exports', 'ember-metal/debug', 'ember-metal/f
8826
9175
  if (_emberMetalFeatures.default('mandatory-setter')) {
8827
9176
  if (watching) {
8828
9177
  meta.writeValues(keyName, data);
8829
- Object.defineProperty(obj, keyName, {
9178
+
9179
+ var defaultDescriptor = {
8830
9180
  configurable: true,
8831
9181
  enumerable: true,
8832
9182
  set: MANDATORY_SETTER_FUNCTION(keyName),
8833
9183
  get: DEFAULT_GETTER_FUNCTION(keyName)
8834
- });
9184
+ };
9185
+
9186
+ if (REDEFINE_SUPPORTED) {
9187
+ Object.defineProperty(obj, keyName, defaultDescriptor);
9188
+ } else {
9189
+ handleBrokenPhantomDefineProperty(obj, keyName, defaultDescriptor);
9190
+ }
8835
9191
  } else {
8836
9192
  obj[keyName] = data;
8837
9193
  }
@@ -8860,6 +9216,12 @@ enifed('ember-metal/properties', ['exports', 'ember-metal/debug', 'ember-metal/f
8860
9216
 
8861
9217
  return this;
8862
9218
  }
9219
+
9220
+ function handleBrokenPhantomDefineProperty(obj, keyName, desc) {
9221
+ // https://github.com/ariya/phantomjs/issues/11856
9222
+ Object.defineProperty(obj, keyName, { configurable: true, writable: true, value: 'iCry' });
9223
+ Object.defineProperty(obj, keyName, desc);
9224
+ }
8863
9225
  });
8864
9226
  enifed('ember-metal/property_events', ['exports', 'ember-metal/utils', 'ember-metal/meta', 'ember-metal/events', 'ember-metal/observer_set', 'ember-metal/symbol'], function (exports, _emberMetalUtils, _emberMetalMeta, _emberMetalEvents, _emberMetalObserver_set, _emberMetalSymbol) {
8865
9227
  'use strict';
@@ -9144,7 +9506,7 @@ enifed('ember-metal/property_events', ['exports', 'ember-metal/utils', 'ember-me
9144
9506
  exports.endPropertyChanges = endPropertyChanges;
9145
9507
  exports.changeProperties = changeProperties;
9146
9508
  });
9147
- enifed('ember-metal/property_get', ['exports', 'ember-metal/core', 'ember-metal/debug', 'ember-metal/features', 'ember-metal/error', 'ember-metal/path_cache', 'ember-metal/meta'], function (exports, _emberMetalCore, _emberMetalDebug, _emberMetalFeatures, _emberMetalError, _emberMetalPath_cache, _emberMetalMeta) {
9509
+ enifed('ember-metal/property_get', ['exports', 'ember-metal/core', 'ember-metal/debug', 'ember-metal/error', 'ember-metal/path_cache'], function (exports, _emberMetalCore, _emberMetalDebug, _emberMetalError, _emberMetalPath_cache) {
9148
9510
  /**
9149
9511
  @module ember-metal
9150
9512
  */
@@ -9202,7 +9564,6 @@ enifed('ember-metal/property_get', ['exports', 'ember-metal/core', 'ember-metal/
9202
9564
  return obj;
9203
9565
  }
9204
9566
 
9205
- var meta = _emberMetalMeta.peekMeta(obj);
9206
9567
  var value = obj[keyName];
9207
9568
  var desc = value !== null && typeof value === 'object' && value.isDescriptor ? value : undefined;
9208
9569
  var ret;
@@ -9214,15 +9575,7 @@ enifed('ember-metal/property_get', ['exports', 'ember-metal/core', 'ember-metal/
9214
9575
  if (desc) {
9215
9576
  return desc.get(obj, keyName);
9216
9577
  } else {
9217
- if (_emberMetalFeatures.default('mandatory-setter')) {
9218
- if (meta && meta.peekWatching(keyName) > 0) {
9219
- ret = meta.peekValues(keyName);
9220
- } else {
9221
- ret = value;
9222
- }
9223
- } else {
9224
- ret = value;
9225
- }
9578
+ ret = value;
9226
9579
 
9227
9580
  if (ret === undefined && 'object' === typeof obj && !(keyName in obj) && 'function' === typeof obj.unknownProperty) {
9228
9581
  return obj.unknownProperty(keyName);
@@ -9333,7 +9686,7 @@ enifed('ember-metal/property_get', ['exports', 'ember-metal/core', 'ember-metal/
9333
9686
 
9334
9687
  exports.default = get;
9335
9688
  });
9336
- enifed('ember-metal/property_set', ['exports', 'ember-metal/debug', 'ember-metal/features', 'ember-metal/property_get', 'ember-metal/property_events', 'ember-metal/properties', 'ember-metal/error', 'ember-metal/path_cache', 'ember-metal/meta'], function (exports, _emberMetalDebug, _emberMetalFeatures, _emberMetalProperty_get, _emberMetalProperty_events, _emberMetalProperties, _emberMetalError, _emberMetalPath_cache, _emberMetalMeta) {
9689
+ enifed('ember-metal/property_set', ['exports', 'ember-metal/debug', 'ember-metal/features', 'ember-metal/property_get', 'ember-metal/property_events', 'ember-metal/properties', 'ember-metal/error', 'ember-metal/path_cache', 'ember-metal/meta', 'ember-metal/utils'], function (exports, _emberMetalDebug, _emberMetalFeatures, _emberMetalProperty_get, _emberMetalProperty_events, _emberMetalProperties, _emberMetalError, _emberMetalPath_cache, _emberMetalMeta, _emberMetalUtils) {
9337
9690
  'use strict';
9338
9691
 
9339
9692
  exports.set = set;
@@ -9390,20 +9743,23 @@ enifed('ember-metal/property_set', ['exports', 'ember-metal/debug', 'ember-metal
9390
9743
  obj.setUnknownProperty(keyName, value);
9391
9744
  } else if (meta && meta.peekWatching(keyName) > 0) {
9392
9745
  if (meta.proto !== obj) {
9393
- if (_emberMetalFeatures.default('mandatory-setter')) {
9394
- currentValue = meta.peekValues(keyName);
9395
- } else {
9396
- currentValue = obj[keyName];
9397
- }
9746
+ currentValue = obj[keyName];
9398
9747
  }
9399
9748
  // only trigger a change if the value has changed
9400
9749
  if (value !== currentValue) {
9401
9750
  _emberMetalProperty_events.propertyWillChange(obj, keyName);
9751
+
9402
9752
  if (_emberMetalFeatures.default('mandatory-setter')) {
9403
9753
  if (currentValue === undefined && !(keyName in obj) || !Object.prototype.propertyIsEnumerable.call(obj, keyName)) {
9404
9754
  _emberMetalProperties.defineProperty(obj, keyName, null, value); // setup mandatory setter
9405
9755
  } else {
9406
- meta.writeValues(keyName, value);
9756
+ var descriptor = _emberMetalUtils.lookupDescriptor(obj, keyName);
9757
+ var isMandatorySetter = descriptor && descriptor.set && descriptor.set.isMandatorySetter;
9758
+ if (isMandatorySetter) {
9759
+ meta.writeValues(keyName, value);
9760
+ } else {
9761
+ obj[keyName] = value;
9762
+ }
9407
9763
  }
9408
9764
  } else {
9409
9765
  obj[keyName] = value;
@@ -11267,6 +11623,7 @@ enifed('ember-metal/utils', ['exports'], function (exports) {
11267
11623
  exports.inspect = inspect;
11268
11624
  exports.apply = apply;
11269
11625
  exports.applyStr = applyStr;
11626
+ exports.lookupDescriptor = lookupDescriptor;
11270
11627
  var _uuid = 0;
11271
11628
 
11272
11629
  /**
@@ -11800,18 +12157,32 @@ enifed('ember-metal/utils', ['exports'], function (exports) {
11800
12157
  }
11801
12158
  }
11802
12159
 
12160
+ function lookupDescriptor(obj, keyName) {
12161
+ var current = obj;
12162
+ while (current) {
12163
+ var descriptor = Object.getOwnPropertyDescriptor(current, keyName);
12164
+
12165
+ if (descriptor) {
12166
+ return descriptor;
12167
+ }
12168
+
12169
+ current = Object.getPrototypeOf(current);
12170
+ }
12171
+
12172
+ return null;
12173
+ }
12174
+
11803
12175
  exports.GUID_KEY = GUID_KEY;
11804
12176
  exports.makeArray = makeArray;
11805
12177
  exports.canInvoke = canInvoke;
11806
12178
  });
11807
- enifed('ember-metal/watch_key', ['exports', 'ember-metal/features', 'ember-metal/meta', 'ember-metal/properties'], function (exports, _emberMetalFeatures, _emberMetalMeta, _emberMetalProperties) {
12179
+ enifed('ember-metal/watch_key', ['exports', 'ember-metal/features', 'ember-metal/meta', 'ember-metal/properties', 'ember-metal/utils'], function (exports, _emberMetalFeatures, _emberMetalMeta, _emberMetalProperties, _emberMetalUtils) {
11808
12180
  'use strict';
11809
12181
 
11810
12182
  exports.watchKey = watchKey;
11811
12183
  exports.unwatchKey = unwatchKey;
11812
12184
 
11813
- var handleMandatorySetter = undefined,
11814
- lookupDescriptor = undefined;
12185
+ var handleMandatorySetter = undefined;
11815
12186
 
11816
12187
  function watchKey(obj, keyName, meta) {
11817
12188
  // can't watch length on Array - it is special...
@@ -11836,6 +12207,7 @@ enifed('ember-metal/watch_key', ['exports', 'ember-metal/features', 'ember-metal
11836
12207
  }
11837
12208
 
11838
12209
  if (_emberMetalFeatures.default('mandatory-setter')) {
12210
+ // NOTE: this is dropped for prod + minified builds
11839
12211
  handleMandatorySetter(m, obj, keyName);
11840
12212
  }
11841
12213
  } else {
@@ -11844,23 +12216,11 @@ enifed('ember-metal/watch_key', ['exports', 'ember-metal/features', 'ember-metal
11844
12216
  }
11845
12217
 
11846
12218
  if (_emberMetalFeatures.default('mandatory-setter')) {
11847
- lookupDescriptor = function lookupDescriptor(obj, keyName) {
11848
- var current = obj;
11849
- while (current) {
11850
- var descriptor = Object.getOwnPropertyDescriptor(current, keyName);
11851
-
11852
- if (descriptor) {
11853
- return descriptor;
11854
- }
11855
-
11856
- current = Object.getPrototypeOf(current);
11857
- }
11858
-
11859
- return null;
11860
- };
11861
-
12219
+ // Future traveler, although this code looks scary. It merely exists in
12220
+ // development to aid in development asertions. Production builds of
12221
+ // ember strip this entire block out
11862
12222
  handleMandatorySetter = function handleMandatorySetter(m, obj, keyName) {
11863
- var descriptor = lookupDescriptor(obj, keyName);
12223
+ var descriptor = _emberMetalUtils.lookupDescriptor(obj, keyName);
11864
12224
  var configurable = descriptor ? descriptor.configurable : true;
11865
12225
  var isWritable = descriptor ? descriptor.writable : true;
11866
12226
  var hasValue = descriptor ? 'value' in descriptor : true;
@@ -11873,13 +12233,21 @@ enifed('ember-metal/watch_key', ['exports', 'ember-metal/features', 'ember-metal
11873
12233
 
11874
12234
  // this x in Y deopts, so keeping it in this function is better;
11875
12235
  if (configurable && isWritable && hasValue && keyName in obj) {
11876
- m.writeValues(keyName, obj[keyName]);
11877
- Object.defineProperty(obj, keyName, {
12236
+ var desc = {
11878
12237
  configurable: true,
11879
12238
  enumerable: Object.prototype.propertyIsEnumerable.call(obj, keyName),
11880
12239
  set: _emberMetalProperties.MANDATORY_SETTER_FUNCTION(keyName),
11881
- get: _emberMetalProperties.DEFAULT_GETTER_FUNCTION(keyName)
11882
- });
12240
+ get: undefined
12241
+ };
12242
+
12243
+ if (Object.prototype.hasOwnProperty.call(obj, keyName)) {
12244
+ m.writeValues(keyName, obj[keyName]);
12245
+ desc.get = _emberMetalProperties.DEFAULT_GETTER_FUNCTION(keyName);
12246
+ } else {
12247
+ desc.get = _emberMetalProperties.INHERITING_GETTER_FUNCTION(keyName);
12248
+ }
12249
+
12250
+ Object.defineProperty(obj, keyName, desc);
11883
12251
  }
11884
12252
  };
11885
12253
  }
@@ -11892,6 +12260,7 @@ enifed('ember-metal/watch_key', ['exports', 'ember-metal/features', 'ember-metal
11892
12260
 
11893
12261
  var possibleDesc = obj[keyName];
11894
12262
  var desc = possibleDesc !== null && typeof possibleDesc === 'object' && possibleDesc.isDescriptor ? possibleDesc : undefined;
12263
+
11895
12264
  if (desc && desc.didUnwatch) {
11896
12265
  desc.didUnwatch(obj, keyName);
11897
12266
  }
@@ -11901,22 +12270,30 @@ enifed('ember-metal/watch_key', ['exports', 'ember-metal/features', 'ember-metal
11901
12270
  }
11902
12271
 
11903
12272
  if (_emberMetalFeatures.default('mandatory-setter')) {
12273
+ // It is true, the following code looks quite WAT. But have no fear, It
12274
+ // exists purely to improve development ergonomics and is removed from
12275
+ // ember.min.js and ember.prod.js builds.
12276
+ //
12277
+ // Some further context: Once a property is watched by ember, bypassing `set`
12278
+ // for mutation, will bypass observation. This code exists to assert when
12279
+ // that occurs, and attempt to provide more helpful feedback. The alternative
12280
+ // is tricky to debug partially observable properties.
11904
12281
  if (!desc && keyName in obj) {
11905
- Object.defineProperty(obj, keyName, {
11906
- configurable: true,
11907
- enumerable: Object.prototype.propertyIsEnumerable.call(obj, keyName),
11908
- set: function (val) {
11909
- // redefine to set as enumerable
12282
+ var maybeMandatoryDescriptor = _emberMetalUtils.lookupDescriptor(obj, keyName);
12283
+
12284
+ if (maybeMandatoryDescriptor.set && maybeMandatoryDescriptor.set.isMandatorySetter) {
12285
+ if (maybeMandatoryDescriptor.get && maybeMandatoryDescriptor.get.isInheritingGetter) {
12286
+ delete obj[keyName];
12287
+ } else {
11910
12288
  Object.defineProperty(obj, keyName, {
11911
12289
  configurable: true,
12290
+ enumerable: Object.prototype.propertyIsEnumerable.call(obj, keyName),
11912
12291
  writable: true,
11913
- enumerable: true,
11914
- value: val
12292
+ value: m.peekValues(keyName)
11915
12293
  });
11916
12294
  m.deleteFromValues(keyName);
11917
- },
11918
- get: _emberMetalProperties.DEFAULT_GETTER_FUNCTION(keyName)
11919
- });
12295
+ }
12296
+ }
11920
12297
  }
11921
12298
  }
11922
12299
  } else if (count > 1) {
@@ -12071,235 +12448,16 @@ enifed('ember-metal/watching', ['exports', 'ember-metal/chains', 'ember-metal/wa
12071
12448
  }
12072
12449
  }
12073
12450
  // remove chainWatcher in node object
12074
- if (node._watching) {
12075
- nodeObject = node._object;
12076
- if (nodeObject) {
12077
- _emberMetalChains.removeChainWatcher(nodeObject, node._key, node);
12078
- }
12079
- }
12080
- }
12081
- }
12082
- }
12083
- }
12084
- });
12085
- enifed('ember-metal', ['exports', 'ember-metal/core', 'ember-metal/debug', 'ember-metal/features', 'ember-metal/assign', 'ember-metal/merge', 'ember-metal/instrumentation', 'ember-metal/utils', 'ember-metal/meta', 'ember-metal/error', 'ember-metal/cache', 'ember-metal/logger', 'ember-metal/property_get', 'ember-metal/events', 'ember-metal/observer_set', 'ember-metal/property_events', 'ember-metal/properties', 'ember-metal/property_set', 'ember-metal/map', 'ember-metal/get_properties', 'ember-metal/set_properties', 'ember-metal/watch_key', 'ember-metal/chains', 'ember-metal/watch_path', 'ember-metal/watching', 'ember-metal/expand_properties', 'ember-metal/computed', 'ember-metal/alias', 'ember-metal/computed_macros', 'ember-metal/observer', 'ember-metal/mixin', 'ember-metal/binding', 'ember-metal/run_loop', 'ember-metal/libraries', 'ember-metal/is_none', 'ember-metal/is_empty', 'ember-metal/is_blank', 'ember-metal/is_present', 'backburner'], function (exports, _emberMetalCore, _emberMetalDebug, _emberMetalFeatures, _emberMetalAssign, _emberMetalMerge, _emberMetalInstrumentation, _emberMetalUtils, _emberMetalMeta, _emberMetalError, _emberMetalCache, _emberMetalLogger, _emberMetalProperty_get, _emberMetalEvents, _emberMetalObserver_set, _emberMetalProperty_events, _emberMetalProperties, _emberMetalProperty_set, _emberMetalMap, _emberMetalGet_properties, _emberMetalSet_properties, _emberMetalWatch_key, _emberMetalChains, _emberMetalWatch_path, _emberMetalWatching, _emberMetalExpand_properties, _emberMetalComputed, _emberMetalAlias, _emberMetalComputed_macros, _emberMetalObserver, _emberMetalMixin, _emberMetalBinding, _emberMetalRun_loop, _emberMetalLibraries, _emberMetalIs_none, _emberMetalIs_empty, _emberMetalIs_blank, _emberMetalIs_present, _backburner) {
12086
- /**
12087
- @module ember
12088
- @submodule ember-metal
12089
- */
12090
-
12091
- // BEGIN IMPORTS
12092
- 'use strict';
12093
-
12094
- _emberMetalComputed.computed.empty = _emberMetalComputed_macros.empty;
12095
- _emberMetalComputed.computed.notEmpty = _emberMetalComputed_macros.notEmpty;
12096
- _emberMetalComputed.computed.none = _emberMetalComputed_macros.none;
12097
- _emberMetalComputed.computed.not = _emberMetalComputed_macros.not;
12098
- _emberMetalComputed.computed.bool = _emberMetalComputed_macros.bool;
12099
- _emberMetalComputed.computed.match = _emberMetalComputed_macros.match;
12100
- _emberMetalComputed.computed.equal = _emberMetalComputed_macros.equal;
12101
- _emberMetalComputed.computed.gt = _emberMetalComputed_macros.gt;
12102
- _emberMetalComputed.computed.gte = _emberMetalComputed_macros.gte;
12103
- _emberMetalComputed.computed.lt = _emberMetalComputed_macros.lt;
12104
- _emberMetalComputed.computed.lte = _emberMetalComputed_macros.lte;
12105
- _emberMetalComputed.computed.alias = _emberMetalAlias.default;
12106
- _emberMetalComputed.computed.oneWay = _emberMetalComputed_macros.oneWay;
12107
- _emberMetalComputed.computed.reads = _emberMetalComputed_macros.oneWay;
12108
- _emberMetalComputed.computed.readOnly = _emberMetalComputed_macros.readOnly;
12109
- _emberMetalComputed.computed.defaultTo = _emberMetalComputed_macros.defaultTo;
12110
- _emberMetalComputed.computed.deprecatingAlias = _emberMetalComputed_macros.deprecatingAlias;
12111
- _emberMetalComputed.computed.and = _emberMetalComputed_macros.and;
12112
- _emberMetalComputed.computed.or = _emberMetalComputed_macros.or;
12113
- _emberMetalComputed.computed.any = _emberMetalComputed_macros.any;
12114
-
12115
- // END IMPORTS
12116
-
12117
- // BEGIN EXPORTS
12118
- var EmberInstrumentation = _emberMetalCore.default.Instrumentation = {};
12119
- EmberInstrumentation.instrument = _emberMetalInstrumentation.instrument;
12120
- EmberInstrumentation.subscribe = _emberMetalInstrumentation.subscribe;
12121
- EmberInstrumentation.unsubscribe = _emberMetalInstrumentation.unsubscribe;
12122
- EmberInstrumentation.reset = _emberMetalInstrumentation.reset;
12123
-
12124
- _emberMetalCore.default.instrument = _emberMetalInstrumentation.instrument;
12125
- _emberMetalCore.default.subscribe = _emberMetalInstrumentation.subscribe;
12126
-
12127
- _emberMetalCore.default._Cache = _emberMetalCache.default;
12128
-
12129
- _emberMetalCore.default.generateGuid = _emberMetalUtils.generateGuid;
12130
- _emberMetalCore.default.GUID_KEY = _emberMetalUtils.GUID_KEY;
12131
- _emberMetalCore.default.platform = {
12132
- defineProperty: true,
12133
- hasPropertyAccessors: true
12134
- };
12135
-
12136
- _emberMetalCore.default.Error = _emberMetalError.default;
12137
- _emberMetalCore.default.guidFor = _emberMetalUtils.guidFor;
12138
- _emberMetalCore.default.META_DESC = _emberMetalMeta.META_DESC;
12139
- _emberMetalCore.default.meta = _emberMetalMeta.meta;
12140
- _emberMetalCore.default.inspect = _emberMetalUtils.inspect;
12141
-
12142
- _emberMetalCore.default.tryCatchFinally = _emberMetalUtils.deprecatedTryCatchFinally;
12143
- _emberMetalCore.default.makeArray = _emberMetalUtils.makeArray;
12144
- _emberMetalCore.default.canInvoke = _emberMetalUtils.canInvoke;
12145
- _emberMetalCore.default.tryInvoke = _emberMetalUtils.tryInvoke;
12146
- _emberMetalCore.default.wrap = _emberMetalUtils.wrap;
12147
- _emberMetalCore.default.apply = _emberMetalUtils.apply;
12148
- _emberMetalCore.default.applyStr = _emberMetalUtils.applyStr;
12149
- _emberMetalCore.default.uuid = _emberMetalUtils.uuid;
12150
-
12151
- _emberMetalCore.default.Logger = _emberMetalLogger.default;
12152
-
12153
- _emberMetalCore.default.get = _emberMetalProperty_get.get;
12154
- _emberMetalCore.default.getWithDefault = _emberMetalProperty_get.getWithDefault;
12155
- _emberMetalCore.default.normalizeTuple = _emberMetalProperty_get.normalizeTuple;
12156
- _emberMetalCore.default._getPath = _emberMetalProperty_get._getPath;
12157
-
12158
- _emberMetalCore.default.on = _emberMetalEvents.on;
12159
- _emberMetalCore.default.addListener = _emberMetalEvents.addListener;
12160
- _emberMetalCore.default.removeListener = _emberMetalEvents.removeListener;
12161
- _emberMetalCore.default._suspendListener = _emberMetalEvents.suspendListener;
12162
- _emberMetalCore.default._suspendListeners = _emberMetalEvents.suspendListeners;
12163
- _emberMetalCore.default.sendEvent = _emberMetalEvents.sendEvent;
12164
- _emberMetalCore.default.hasListeners = _emberMetalEvents.hasListeners;
12165
- _emberMetalCore.default.watchedEvents = _emberMetalEvents.watchedEvents;
12166
- _emberMetalCore.default.listenersFor = _emberMetalEvents.listenersFor;
12167
- _emberMetalCore.default.accumulateListeners = _emberMetalEvents.accumulateListeners;
12168
-
12169
- _emberMetalCore.default._ObserverSet = _emberMetalObserver_set.default;
12170
-
12171
- _emberMetalCore.default.propertyWillChange = _emberMetalProperty_events.propertyWillChange;
12172
- _emberMetalCore.default.propertyDidChange = _emberMetalProperty_events.propertyDidChange;
12173
- _emberMetalCore.default.overrideChains = _emberMetalProperty_events.overrideChains;
12174
- _emberMetalCore.default.beginPropertyChanges = _emberMetalProperty_events.beginPropertyChanges;
12175
- _emberMetalCore.default.endPropertyChanges = _emberMetalProperty_events.endPropertyChanges;
12176
- _emberMetalCore.default.changeProperties = _emberMetalProperty_events.changeProperties;
12177
-
12178
- _emberMetalCore.default.defineProperty = _emberMetalProperties.defineProperty;
12179
-
12180
- _emberMetalCore.default.set = _emberMetalProperty_set.set;
12181
- _emberMetalCore.default.trySet = _emberMetalProperty_set.trySet;
12182
-
12183
- _emberMetalCore.default.OrderedSet = _emberMetalMap.OrderedSet;
12184
- _emberMetalCore.default.Map = _emberMetalMap.Map;
12185
- _emberMetalCore.default.MapWithDefault = _emberMetalMap.MapWithDefault;
12186
-
12187
- _emberMetalCore.default.getProperties = _emberMetalGet_properties.default;
12188
- _emberMetalCore.default.setProperties = _emberMetalSet_properties.default;
12189
-
12190
- _emberMetalCore.default.watchKey = _emberMetalWatch_key.watchKey;
12191
- _emberMetalCore.default.unwatchKey = _emberMetalWatch_key.unwatchKey;
12192
-
12193
- _emberMetalCore.default.flushPendingChains = _emberMetalChains.flushPendingChains;
12194
- _emberMetalCore.default.removeChainWatcher = _emberMetalChains.removeChainWatcher;
12195
- _emberMetalCore.default._ChainNode = _emberMetalChains.ChainNode;
12196
- _emberMetalCore.default.finishChains = _emberMetalChains.finishChains;
12197
-
12198
- _emberMetalCore.default.watchPath = _emberMetalWatch_path.watchPath;
12199
- _emberMetalCore.default.unwatchPath = _emberMetalWatch_path.unwatchPath;
12200
-
12201
- _emberMetalCore.default.watch = _emberMetalWatching.watch;
12202
- _emberMetalCore.default.isWatching = _emberMetalWatching.isWatching;
12203
- _emberMetalCore.default.unwatch = _emberMetalWatching.unwatch;
12204
- _emberMetalCore.default.rewatch = _emberMetalWatching.rewatch;
12205
- _emberMetalCore.default.destroy = _emberMetalWatching.destroy;
12206
-
12207
- _emberMetalCore.default.expandProperties = _emberMetalExpand_properties.default;
12208
-
12209
- _emberMetalCore.default.ComputedProperty = _emberMetalComputed.ComputedProperty;
12210
- _emberMetalCore.default.computed = _emberMetalComputed.computed;
12211
- _emberMetalCore.default.cacheFor = _emberMetalComputed.cacheFor;
12212
-
12213
- _emberMetalCore.default.addObserver = _emberMetalObserver.addObserver;
12214
- _emberMetalCore.default.observersFor = _emberMetalObserver.observersFor;
12215
- _emberMetalCore.default.removeObserver = _emberMetalObserver.removeObserver;
12216
- _emberMetalCore.default._suspendObserver = _emberMetalObserver._suspendObserver;
12217
- _emberMetalCore.default._suspendObservers = _emberMetalObserver._suspendObservers;
12218
-
12219
- _emberMetalCore.default.IS_BINDING = _emberMetalMixin.IS_BINDING;
12220
- _emberMetalCore.default.required = _emberMetalMixin.required;
12221
- _emberMetalCore.default.aliasMethod = _emberMetalMixin.aliasMethod;
12222
- _emberMetalCore.default.observer = _emberMetalMixin.observer;
12223
- _emberMetalCore.default.immediateObserver = _emberMetalMixin._immediateObserver;
12224
- _emberMetalCore.default.mixin = _emberMetalMixin.mixin;
12225
- _emberMetalCore.default.Mixin = _emberMetalMixin.Mixin;
12226
-
12227
- _emberMetalCore.default.bind = _emberMetalBinding.bind;
12228
- _emberMetalCore.default.Binding = _emberMetalBinding.Binding;
12229
- _emberMetalCore.default.isGlobalPath = _emberMetalBinding.isGlobalPath;
12230
-
12231
- _emberMetalCore.default.run = _emberMetalRun_loop.default;
12232
-
12233
- /**
12234
- @class Backburner
12235
- @for Ember
12236
- @private
12237
- */
12238
- _emberMetalCore.default.Backburner = _backburner.default;
12239
- // this is the new go forward, once Ember Data updates to using `_Backburner` we
12240
- // can remove the non-underscored version.
12241
- _emberMetalCore.default._Backburner = _backburner.default;
12242
-
12243
- _emberMetalCore.default.libraries = new _emberMetalLibraries.default();
12244
- _emberMetalCore.default.libraries.registerCoreLibrary('Ember', _emberMetalCore.default.VERSION);
12245
-
12246
- _emberMetalCore.default.isNone = _emberMetalIs_none.default;
12247
- _emberMetalCore.default.isEmpty = _emberMetalIs_empty.default;
12248
- _emberMetalCore.default.isBlank = _emberMetalIs_blank.default;
12249
- _emberMetalCore.default.isPresent = _emberMetalIs_present.default;
12250
-
12251
- if (_emberMetalFeatures.default('ember-metal-ember-assign')) {
12252
- _emberMetalCore.default.assign = Object.assign || _emberMetalAssign.default;
12253
- _emberMetalCore.default.merge = _emberMetalMerge.default;
12254
- } else {
12255
- _emberMetalCore.default.merge = _emberMetalMerge.default;
12256
- }
12257
-
12258
- _emberMetalCore.default.FEATURES = _emberMetalFeatures.FEATURES;
12259
- _emberMetalCore.default.FEATURES.isEnabled = _emberMetalFeatures.default;
12260
-
12261
- /**
12262
- A function may be assigned to `Ember.onerror` to be called when Ember
12263
- internals encounter an error. This is useful for specialized error handling
12264
- and reporting code.
12265
-
12266
- ```javascript
12267
- Ember.onerror = function(error) {
12268
- Em.$.ajax('/report-error', 'POST', {
12269
- stack: error.stack,
12270
- otherInformation: 'whatever app state you want to provide'
12271
- });
12272
- };
12273
- ```
12274
-
12275
- Internally, `Ember.onerror` is used as Backburner's error handler.
12276
-
12277
- @event onerror
12278
- @for Ember
12279
- @param {Exception} error the error object
12280
- @public
12281
- */
12282
- _emberMetalCore.default.onerror = null;
12283
- // END EXPORTS
12284
-
12285
- // do this for side-effects of updating Ember.assert, warn, etc when
12286
- // ember-debug is present
12287
- // This needs to be called before any deprecateFunc
12288
- if (_emberMetalCore.default.__loader.registry['ember-debug']) {
12289
- requireModule('ember-debug');
12290
- } else {
12291
- _emberMetalCore.default.Debug = {};
12292
-
12293
- if (_emberMetalFeatures.default('ember-debug-handlers')) {
12294
- _emberMetalCore.default.Debug.registerDeprecationHandler = function () {};
12295
- _emberMetalCore.default.Debug.registerWarnHandler = function () {};
12451
+ if (node._watching) {
12452
+ nodeObject = node._object;
12453
+ if (nodeObject) {
12454
+ _emberMetalChains.removeChainWatcher(nodeObject, node._key, node);
12455
+ }
12456
+ }
12457
+ }
12458
+ }
12296
12459
  }
12297
12460
  }
12298
-
12299
- _emberMetalCore.default.create = _emberMetalDebug.deprecateFunc('Ember.create is deprecated in favor of Object.create', { id: 'ember-metal.ember-create', until: '3.0.0' }, Object.create);
12300
- _emberMetalCore.default.keys = _emberMetalDebug.deprecateFunc('Ember.keys is deprecated in favor of Object.keys', { id: 'ember-metal.ember.keys', until: '3.0.0' }, Object.keys);
12301
-
12302
- exports.default = _emberMetalCore.default;
12303
12461
  });
12304
12462
  enifed('ember-runtime/compare', ['exports', 'ember-runtime/utils', 'ember-runtime/mixins/comparable'], function (exports, _emberRuntimeUtils, _emberRuntimeMixinsComparable) {
12305
12463
  'use strict';
@@ -12323,28 +12481,59 @@ enifed('ember-runtime/compare', ['exports', 'ember-runtime/utils', 'ember-runtim
12323
12481
  //
12324
12482
  // the spaceship operator
12325
12483
  //
12484
+ // `. ___
12485
+ // __,' __`. _..----....____
12486
+ // __...--.'``;. ,. ;``--..__ .' ,-._ _.-'
12487
+ // _..-''-------' `' `' `' O ``-''._ (,;') _,'
12488
+ // ,'________________ \`-._`-','
12489
+ // `._ ```````````------...___ '-.._'-:
12490
+ // ```--.._ ,. ````--...__\-.
12491
+ // `.--. `-` "INFINTIY IS LESS ____ | |`
12492
+ // `. `. THAN BEYOND" ,'`````. ; ;`
12493
+ // `._`. __________ `. \'__/`
12494
+ // `-:._____/______/___/____`. \ `
12495
+ // | `._ `. \
12496
+ // `._________`-. `. `.___
12497
+ // SSt `------'`
12326
12498
  function spaceship(a, b) {
12327
12499
  var diff = a - b;
12328
12500
  return (diff > 0) - (diff < 0);
12329
12501
  }
12330
12502
 
12331
12503
  /**
12332
- This will compare two javascript values of possibly different types.
12333
- It will tell you which one is greater than the other by returning:
12504
+ Compares two javascript values and returns:
12334
12505
 
12335
12506
  - -1 if the first is smaller than the second,
12336
12507
  - 0 if both are equal,
12337
12508
  - 1 if the first is greater than the second.
12338
12509
 
12339
- The order is calculated based on `Ember.ORDER_DEFINITION`, if types are different.
12340
- In case they have the same type an appropriate comparison for this type is made.
12341
-
12342
12510
  ```javascript
12343
12511
  Ember.compare('hello', 'hello'); // 0
12344
12512
  Ember.compare('abc', 'dfg'); // -1
12345
12513
  Ember.compare(2, 1); // 1
12346
12514
  ```
12347
12515
 
12516
+ If the types of the two objects are different precedence occurs in the
12517
+ following order, with types earlier in the list considered `<` types
12518
+ later in the list:
12519
+
12520
+ - undefined
12521
+ - null
12522
+ - boolean
12523
+ - number
12524
+ - string
12525
+ - array
12526
+ - object
12527
+ - instance
12528
+ - function
12529
+ - class
12530
+ - date
12531
+
12532
+ ```javascript
12533
+ Ember.compare('hello', 50); // 1
12534
+ Ember.compare(50, 'hello'); // -1
12535
+ ```
12536
+
12348
12537
  @method compare
12349
12538
  @for Ember
12350
12539
  @param {Object} v First value to compare
@@ -13264,19 +13453,21 @@ enifed('ember-runtime/copy', ['exports', 'ember-metal/debug', 'ember-runtime/sys
13264
13453
  }
13265
13454
 
13266
13455
  /**
13267
- Creates a clone of the passed object. This function can take just about
13268
- any type of object and create a clone of it, including primitive values
13269
- (which are not actually cloned because they are immutable).
13456
+ Creates a shallow copy of the passed object. A deep copy of the object is
13457
+ returned if the optional `deep` argument is `true`.
13270
13458
 
13271
- If the passed object implements the `copy()` method, then this function
13272
- will simply call that method and return the result. Please see
13273
- `Ember.Copyable` for further details.
13459
+ If the passed object implements the `Ember.Copyable` interface, then this
13460
+ function will delegate to the object's `copy()` method and return the
13461
+ result. See `Ember.Copyable` for further details.
13462
+
13463
+ For primitive values (which are immutable in JavaScript), the passed object
13464
+ is simply returned.
13274
13465
 
13275
13466
  @method copy
13276
13467
  @for Ember
13277
13468
  @param {Object} obj The object to clone
13278
- @param {Boolean} deep If true, a deep copy of the object is made
13279
- @return {Object} The cloned object
13469
+ @param {Boolean} [deep=false] If true, a deep copy of the object is made.
13470
+ @return {Object} The copied object
13280
13471
  @public
13281
13472
  */
13282
13473
 
@@ -13458,7 +13649,7 @@ enifed('ember-runtime/ext/function', ['exports', 'ember-metal/core', 'ember-meta
13458
13649
  }
13459
13650
  });
13460
13651
  // Ember.EXTEND_PROTOTYPES
13461
- enifed('ember-runtime/ext/rsvp', ['exports', 'ember-metal/core', 'ember-metal/debug', 'ember-metal/logger', 'ember-metal/run_loop', 'rsvp'], function (exports, _emberMetalCore, _emberMetalDebug, _emberMetalLogger, _emberMetalRun_loop, _rsvp) {
13652
+ enifed('ember-runtime/ext/rsvp', ['exports', 'ember-metal/core', 'require', 'ember-metal/debug', 'ember-metal/logger', 'ember-metal/run_loop', 'rsvp'], function (exports, _emberMetalCore, _require, _emberMetalDebug, _emberMetalLogger, _emberMetalRun_loop, _rsvp) {
13462
13653
  'use strict';
13463
13654
 
13464
13655
  exports.onerrorDefault = onerrorDefault;
@@ -13519,8 +13710,8 @@ enifed('ember-runtime/ext/rsvp', ['exports', 'ember-metal/core', 'ember-metal/de
13519
13710
  if (error && error.name !== 'TransitionAborted') {
13520
13711
  if (_emberMetalCore.default.testing) {
13521
13712
  // ES6TODO: remove when possible
13522
- if (!Test && _emberMetalCore.default.__loader.registry[testModuleName]) {
13523
- Test = requireModule(testModuleName)['default'];
13713
+ if (!Test && _require.has(testModuleName)) {
13714
+ Test = _require.default(testModuleName)['default'];
13524
13715
  }
13525
13716
 
13526
13717
  if (Test && Test.adapter) {
@@ -13658,6 +13849,118 @@ enifed('ember-runtime/ext/string', ['exports', 'ember-metal/core', 'ember-runtim
13658
13849
  }
13659
13850
  });
13660
13851
  // Ember.EXTEND_PROTOTYPES
13852
+ enifed('ember-runtime/index', ['exports', 'ember-metal', 'ember-runtime/is-equal', 'ember-runtime/compare', 'ember-runtime/copy', 'ember-runtime/inject', 'ember-runtime/system/namespace', 'ember-runtime/system/object', 'ember-runtime/system/container', 'ember-runtime/system/array_proxy', 'ember-runtime/system/object_proxy', 'ember-runtime/system/core_object', 'ember-runtime/system/native_array', 'ember-runtime/system/string', 'ember-runtime/system/lazy_load', 'ember-runtime/mixins/array', 'ember-runtime/mixins/comparable', 'ember-runtime/mixins/copyable', 'ember-runtime/mixins/enumerable', 'ember-runtime/mixins/freezable', 'ember-runtime/mixins/-proxy', 'ember-runtime/mixins/observable', 'ember-runtime/mixins/action_handler', 'ember-runtime/mixins/mutable_enumerable', 'ember-runtime/mixins/mutable_array', 'ember-runtime/mixins/target_action_support', 'ember-runtime/mixins/evented', 'ember-runtime/mixins/promise_proxy', 'ember-runtime/computed/reduce_computed_macros', 'ember-runtime/controllers/controller', 'ember-runtime/mixins/controller', 'ember-runtime/system/service', 'ember-runtime/ext/rsvp', 'ember-runtime/ext/string', 'ember-runtime/ext/function', 'ember-runtime/utils', 'ember-metal/features', 'ember-runtime/mixins/registry_proxy', 'ember-runtime/mixins/container_proxy', 'ember-runtime/string_registry'], function (exports, _emberMetal, _emberRuntimeIsEqual, _emberRuntimeCompare, _emberRuntimeCopy, _emberRuntimeInject, _emberRuntimeSystemNamespace, _emberRuntimeSystemObject, _emberRuntimeSystemContainer, _emberRuntimeSystemArray_proxy, _emberRuntimeSystemObject_proxy, _emberRuntimeSystemCore_object, _emberRuntimeSystemNative_array, _emberRuntimeSystemString, _emberRuntimeSystemLazy_load, _emberRuntimeMixinsArray, _emberRuntimeMixinsComparable, _emberRuntimeMixinsCopyable, _emberRuntimeMixinsEnumerable, _emberRuntimeMixinsFreezable, _emberRuntimeMixinsProxy, _emberRuntimeMixinsObservable, _emberRuntimeMixinsAction_handler, _emberRuntimeMixinsMutable_enumerable, _emberRuntimeMixinsMutable_array, _emberRuntimeMixinsTarget_action_support, _emberRuntimeMixinsEvented, _emberRuntimeMixinsPromise_proxy, _emberRuntimeComputedReduce_computed_macros, _emberRuntimeControllersController, _emberRuntimeMixinsController, _emberRuntimeSystemService, _emberRuntimeExtRsvp, _emberRuntimeExtString, _emberRuntimeExtFunction, _emberRuntimeUtils, _emberMetalFeatures, _emberRuntimeMixinsRegistry_proxy, _emberRuntimeMixinsContainer_proxy, _emberRuntimeString_registry) {
13853
+ /**
13854
+ @module ember
13855
+ @submodule ember-runtime
13856
+ */
13857
+
13858
+ // BEGIN IMPORTS
13859
+ 'use strict';
13860
+
13861
+ // END IMPORTS
13862
+
13863
+ // BEGIN EXPORTS
13864
+ _emberMetal.default.compare = _emberRuntimeCompare.default;
13865
+ _emberMetal.default.copy = _emberRuntimeCopy.default;
13866
+ _emberMetal.default.isEqual = _emberRuntimeIsEqual.default;
13867
+
13868
+ _emberMetal.default.inject = _emberRuntimeInject.default;
13869
+
13870
+ _emberMetal.default.Array = _emberRuntimeMixinsArray.default;
13871
+
13872
+ _emberMetal.default.Comparable = _emberRuntimeMixinsComparable.default;
13873
+ _emberMetal.default.Copyable = _emberRuntimeMixinsCopyable.default;
13874
+
13875
+ _emberMetal.default.Freezable = _emberRuntimeMixinsFreezable.Freezable;
13876
+ _emberMetal.default.FROZEN_ERROR = _emberRuntimeMixinsFreezable.FROZEN_ERROR;
13877
+
13878
+ _emberMetal.default.MutableEnumerable = _emberRuntimeMixinsMutable_enumerable.default;
13879
+ _emberMetal.default.MutableArray = _emberRuntimeMixinsMutable_array.default;
13880
+
13881
+ _emberMetal.default.TargetActionSupport = _emberRuntimeMixinsTarget_action_support.default;
13882
+ _emberMetal.default.Evented = _emberRuntimeMixinsEvented.default;
13883
+
13884
+ _emberMetal.default.PromiseProxyMixin = _emberRuntimeMixinsPromise_proxy.default;
13885
+
13886
+ _emberMetal.default.Observable = _emberRuntimeMixinsObservable.default;
13887
+
13888
+ _emberMetal.default.typeOf = _emberRuntimeUtils.typeOf;
13889
+ _emberMetal.default.isArray = _emberRuntimeUtils.isArray;
13890
+
13891
+ // ES6TODO: this seems a less than ideal way/place to add properties to Ember.computed
13892
+ var EmComputed = _emberMetal.default.computed;
13893
+
13894
+ EmComputed.sum = _emberRuntimeComputedReduce_computed_macros.sum;
13895
+ EmComputed.min = _emberRuntimeComputedReduce_computed_macros.min;
13896
+ EmComputed.max = _emberRuntimeComputedReduce_computed_macros.max;
13897
+ EmComputed.map = _emberRuntimeComputedReduce_computed_macros.map;
13898
+ EmComputed.sort = _emberRuntimeComputedReduce_computed_macros.sort;
13899
+ EmComputed.setDiff = _emberRuntimeComputedReduce_computed_macros.setDiff;
13900
+ EmComputed.mapBy = _emberRuntimeComputedReduce_computed_macros.mapBy;
13901
+ EmComputed.filter = _emberRuntimeComputedReduce_computed_macros.filter;
13902
+ EmComputed.filterBy = _emberRuntimeComputedReduce_computed_macros.filterBy;
13903
+ EmComputed.uniq = _emberRuntimeComputedReduce_computed_macros.uniq;
13904
+ EmComputed.union = _emberRuntimeComputedReduce_computed_macros.union;
13905
+ EmComputed.intersect = _emberRuntimeComputedReduce_computed_macros.intersect;
13906
+ EmComputed.collect = _emberRuntimeComputedReduce_computed_macros.collect;
13907
+
13908
+ _emberMetal.default.String = _emberRuntimeSystemString.default;
13909
+ _emberMetal.default.Object = _emberRuntimeSystemObject.default;
13910
+ _emberMetal.default.Container = _emberRuntimeSystemContainer.Container;
13911
+ _emberMetal.default.Registry = _emberRuntimeSystemContainer.Registry;
13912
+
13913
+ if (_emberMetalFeatures.default('ember-container-inject-owner')) {
13914
+ _emberMetal.default.getOwner = _emberRuntimeSystemContainer.getOwner;
13915
+ _emberMetal.default.setOwner = _emberRuntimeSystemContainer.setOwner;
13916
+
13917
+ _emberMetal.default._RegistryProxyMixin = _emberRuntimeMixinsRegistry_proxy.default;
13918
+ _emberMetal.default._ContainerProxyMixin = _emberRuntimeMixinsContainer_proxy.default;
13919
+ }
13920
+
13921
+ _emberMetal.default.Namespace = _emberRuntimeSystemNamespace.default;
13922
+ _emberMetal.default.Enumerable = _emberRuntimeMixinsEnumerable.default;
13923
+ _emberMetal.default.ArrayProxy = _emberRuntimeSystemArray_proxy.default;
13924
+ _emberMetal.default.ObjectProxy = _emberRuntimeSystemObject_proxy.default;
13925
+ _emberMetal.default.ActionHandler = _emberRuntimeMixinsAction_handler.default;
13926
+ _emberMetal.default.CoreObject = _emberRuntimeSystemCore_object.default;
13927
+ _emberMetal.default.NativeArray = _emberRuntimeSystemNative_array.default;
13928
+ // ES6TODO: Currently we must rely on the global from ember-metal/core to avoid circular deps
13929
+ // Ember.A = A;
13930
+ _emberMetal.default.onLoad = _emberRuntimeSystemLazy_load.onLoad;
13931
+ _emberMetal.default.runLoadHooks = _emberRuntimeSystemLazy_load.runLoadHooks;
13932
+
13933
+ _emberMetal.default.Controller = _emberRuntimeControllersController.default;
13934
+ _emberMetal.default.ControllerMixin = _emberRuntimeMixinsController.default;
13935
+
13936
+ _emberMetal.default.Service = _emberRuntimeSystemService.default;
13937
+
13938
+ _emberMetal.default._ProxyMixin = _emberRuntimeMixinsProxy.default;
13939
+
13940
+ _emberMetal.default.RSVP = _emberRuntimeExtRsvp.default;
13941
+ // END EXPORTS
13942
+
13943
+ /**
13944
+ Defines the hash of localized strings for the current language. Used by
13945
+ the `Ember.String.loc()` helper. To localize, add string values to this
13946
+ hash.
13947
+
13948
+ @property STRINGS
13949
+ @for Ember
13950
+ @type Object
13951
+ @private
13952
+ */
13953
+ Object.defineProperty(_emberMetal.default, 'STRINGS', {
13954
+ configurable: false,
13955
+ get: _emberRuntimeString_registry.getStrings,
13956
+ set: _emberRuntimeString_registry.setStrings
13957
+ });
13958
+
13959
+ exports.default = _emberMetal.default;
13960
+ });
13961
+ // just for side effect of extending Ember.RSVP
13962
+ // just for side effect of extending String.prototype
13963
+ // just for side effect of extending Function.prototype
13661
13964
  enifed('ember-runtime/inject', ['exports', 'ember-metal/debug', 'ember-metal/injected_property'], function (exports, _emberMetalDebug, _emberMetalInjected_property) {
13662
13965
  'use strict';
13663
13966
 
@@ -13740,16 +14043,34 @@ enifed('ember-runtime/inject', ['exports', 'ember-metal/debug', 'ember-metal/inj
13740
14043
  });
13741
14044
  enifed('ember-runtime/is-equal', ['exports'], function (exports) {
13742
14045
  /**
13743
- Compares two objects, returning true if they are logically equal. This is
13744
- a deeper comparison than a simple triple equal. For sets it will compare the
13745
- internal objects. For any other object that implements `isEqual()` it will
13746
- respect that method.
14046
+ Compares two objects, returning true if they are equal.
13747
14047
 
13748
14048
  ```javascript
13749
14049
  Ember.isEqual('hello', 'hello'); // true
13750
14050
  Ember.isEqual(1, 2); // false
14051
+ ```
14052
+
14053
+ `isEqual` is a more specific comparison than a triple equal comparison.
14054
+ It will call the `isEqual` instance method on the objects being
14055
+ compared, allowing finer control over when objects should be considered
14056
+ equal to each other.
14057
+
14058
+ ```javascript
14059
+ let Person = Ember.Object.extend({
14060
+ isEqual(other) { return this.ssn == other.ssn; }
14061
+ });
14062
+
14063
+ let personA = Person.create({name: 'Muhammad Ali', ssn: '123-45-6789'});
14064
+ let personB = Person.create({name: 'Cassius Clay', ssn: '123-45-6789'});
14065
+
14066
+ Ember.isEqual(personA, personB); // true
14067
+ ```
14068
+
14069
+ Due to the expense of array comparisons, collections will never be equal to
14070
+ each other even if each of their items are equal to each other.
14071
+
14072
+ ```javascript
13751
14073
  Ember.isEqual([4, 2], [4, 2]); // false
13752
- Ember.isEqual({ isEqual() { return true;} }, null) // true
13753
14074
  ```
13754
14075
 
13755
14076
  @method isEqual
@@ -13931,7 +14252,7 @@ enifed('ember-runtime/mixins/action_handler', ['exports', 'ember-metal/debug', '
13931
14252
  }
13932
14253
  });
13933
14254
  ```
13934
- It is also possible to call `this._super.apply(this, arguments)` from within an
14255
+ It is also possible to call `this._super(...arguments)` from within an
13935
14256
  action handler if it overrides a handler defined on a parent
13936
14257
  class or mixin:
13937
14258
  Take for example the following routes:
@@ -13947,7 +14268,7 @@ enifed('ember-runtime/mixins/action_handler', ['exports', 'ember-metal/debug', '
13947
14268
  actions: {
13948
14269
  debugRouteInformation: function() {
13949
14270
  // also call the debugRouteInformation of mixed in App.DebugRoute
13950
- this._super.apply(this, arguments);
14271
+ this._super(...arguments);
13951
14272
  // show additional annoyance
13952
14273
  window.alert(...);
13953
14274
  }
@@ -14367,7 +14688,7 @@ enifed('ember-runtime/mixins/array', ['exports', 'ember-metal/core', 'ember-meta
14367
14688
  * `arrayDidChange(observedObj, start, removeCount, addCount)` - This method will be
14368
14689
  called just after the array is modified.
14369
14690
  Both callbacks will be passed the observed object, starting index of the
14370
- change as well a a count of the items to be removed and added. You can use
14691
+ change as well as a count of the items to be removed and added. You can use
14371
14692
  these callbacks to optionally inspect the array during the change, clear
14372
14693
  caches, or do any other bookkeeping necessary.
14373
14694
  In addition to passing a target, you can also include an options hash
@@ -17052,7 +17373,7 @@ enifed('ember-runtime/mixins/promise_proxy', ['exports', 'ember-metal/property_g
17052
17373
  proxy.get('isFulfilled') //=> false
17053
17374
  ```
17054
17375
 
17055
- When the the $.getJSON completes, and the promise is fulfilled
17376
+ When the $.getJSON completes, and the promise is fulfilled
17056
17377
  with json, the life cycle attributes will update accordingly.
17057
17378
 
17058
17379
  ```javascript
@@ -18202,7 +18523,7 @@ enifed('ember-runtime/system/core_object', ['exports', 'ember-metal/debug', 'emb
18202
18523
  // alerts 'Name is Steve'.
18203
18524
  ```
18204
18525
  NOTE: If you do override `init` for a framework class like `Ember.View`,
18205
- be sure to call `this._super.apply(this, arguments)` in your
18526
+ be sure to call `this._super(...arguments)` in your
18206
18527
  `init` declaration! If you don't, Ember may not have an opportunity to
18207
18528
  do important setup work, and you'll see strange behavior in your
18208
18529
  application.
@@ -19367,7 +19688,7 @@ enifed('ember-runtime/system/native_array', ['exports', 'ember-metal/core', 'emb
19367
19688
  classNames: ['pagination'],
19368
19689
 
19369
19690
  init: function() {
19370
- this._super.apply(this, arguments);
19691
+ this._super(...arguments);
19371
19692
  if (!this.get('content')) {
19372
19693
  this.set('content', Ember.A());
19373
19694
  }
@@ -19884,14 +20205,14 @@ enifed('ember-runtime/utils', ['exports', 'ember-runtime/mixins/array', 'ember-r
19884
20205
  /**
19885
20206
  Returns true if the passed object is an array or Array-like.
19886
20207
 
19887
- Ember Array Protocol:
20208
+ Objects are considered Array-like if any of the following are true:
19888
20209
 
19889
- - the object has an objectAt property
19890
20210
  - the object is a native Array
20211
+ - the object has an objectAt property
19891
20212
  - the object is an Object, and has a length property
19892
20213
 
19893
20214
  Unlike `Ember.typeOf` this method returns true even if the passed object is
19894
- not formally array but appears to be array-like (i.e. implements `Ember.Array`)
20215
+ not formally an array but appears to be array-like (i.e. implements `Ember.Array`)
19895
20216
 
19896
20217
  ```javascript
19897
20218
  Ember.isArray(); // false
@@ -19928,7 +20249,7 @@ enifed('ember-runtime/utils', ['exports', 'ember-runtime/mixins/array', 'ember-r
19928
20249
  }
19929
20250
 
19930
20251
  /**
19931
- Returns a consistent type for the passed item.
20252
+ Returns a consistent type for the passed object.
19932
20253
 
19933
20254
  Use this instead of the built-in `typeof` to get the type of an item.
19934
20255
  It will return the same result across all browsers and includes a bit
@@ -20007,118 +20328,6 @@ enifed('ember-runtime/utils', ['exports', 'ember-runtime/mixins/array', 'ember-r
20007
20328
  return ret;
20008
20329
  }
20009
20330
  });
20010
- enifed('ember-runtime', ['exports', 'ember-metal', 'ember-runtime/is-equal', 'ember-runtime/compare', 'ember-runtime/copy', 'ember-runtime/inject', 'ember-runtime/system/namespace', 'ember-runtime/system/object', 'ember-runtime/system/container', 'ember-runtime/system/array_proxy', 'ember-runtime/system/object_proxy', 'ember-runtime/system/core_object', 'ember-runtime/system/native_array', 'ember-runtime/system/string', 'ember-runtime/system/lazy_load', 'ember-runtime/mixins/array', 'ember-runtime/mixins/comparable', 'ember-runtime/mixins/copyable', 'ember-runtime/mixins/enumerable', 'ember-runtime/mixins/freezable', 'ember-runtime/mixins/-proxy', 'ember-runtime/mixins/observable', 'ember-runtime/mixins/action_handler', 'ember-runtime/mixins/mutable_enumerable', 'ember-runtime/mixins/mutable_array', 'ember-runtime/mixins/target_action_support', 'ember-runtime/mixins/evented', 'ember-runtime/mixins/promise_proxy', 'ember-runtime/computed/reduce_computed_macros', 'ember-runtime/controllers/controller', 'ember-runtime/mixins/controller', 'ember-runtime/system/service', 'ember-runtime/ext/rsvp', 'ember-runtime/ext/string', 'ember-runtime/ext/function', 'ember-runtime/utils', 'ember-metal/features', 'ember-runtime/mixins/registry_proxy', 'ember-runtime/mixins/container_proxy', 'ember-runtime/string_registry'], function (exports, _emberMetal, _emberRuntimeIsEqual, _emberRuntimeCompare, _emberRuntimeCopy, _emberRuntimeInject, _emberRuntimeSystemNamespace, _emberRuntimeSystemObject, _emberRuntimeSystemContainer, _emberRuntimeSystemArray_proxy, _emberRuntimeSystemObject_proxy, _emberRuntimeSystemCore_object, _emberRuntimeSystemNative_array, _emberRuntimeSystemString, _emberRuntimeSystemLazy_load, _emberRuntimeMixinsArray, _emberRuntimeMixinsComparable, _emberRuntimeMixinsCopyable, _emberRuntimeMixinsEnumerable, _emberRuntimeMixinsFreezable, _emberRuntimeMixinsProxy, _emberRuntimeMixinsObservable, _emberRuntimeMixinsAction_handler, _emberRuntimeMixinsMutable_enumerable, _emberRuntimeMixinsMutable_array, _emberRuntimeMixinsTarget_action_support, _emberRuntimeMixinsEvented, _emberRuntimeMixinsPromise_proxy, _emberRuntimeComputedReduce_computed_macros, _emberRuntimeControllersController, _emberRuntimeMixinsController, _emberRuntimeSystemService, _emberRuntimeExtRsvp, _emberRuntimeExtString, _emberRuntimeExtFunction, _emberRuntimeUtils, _emberMetalFeatures, _emberRuntimeMixinsRegistry_proxy, _emberRuntimeMixinsContainer_proxy, _emberRuntimeString_registry) {
20011
- /**
20012
- @module ember
20013
- @submodule ember-runtime
20014
- */
20015
-
20016
- // BEGIN IMPORTS
20017
- 'use strict';
20018
-
20019
- // END IMPORTS
20020
-
20021
- // BEGIN EXPORTS
20022
- _emberMetal.default.compare = _emberRuntimeCompare.default;
20023
- _emberMetal.default.copy = _emberRuntimeCopy.default;
20024
- _emberMetal.default.isEqual = _emberRuntimeIsEqual.default;
20025
-
20026
- _emberMetal.default.inject = _emberRuntimeInject.default;
20027
-
20028
- _emberMetal.default.Array = _emberRuntimeMixinsArray.default;
20029
-
20030
- _emberMetal.default.Comparable = _emberRuntimeMixinsComparable.default;
20031
- _emberMetal.default.Copyable = _emberRuntimeMixinsCopyable.default;
20032
-
20033
- _emberMetal.default.Freezable = _emberRuntimeMixinsFreezable.Freezable;
20034
- _emberMetal.default.FROZEN_ERROR = _emberRuntimeMixinsFreezable.FROZEN_ERROR;
20035
-
20036
- _emberMetal.default.MutableEnumerable = _emberRuntimeMixinsMutable_enumerable.default;
20037
- _emberMetal.default.MutableArray = _emberRuntimeMixinsMutable_array.default;
20038
-
20039
- _emberMetal.default.TargetActionSupport = _emberRuntimeMixinsTarget_action_support.default;
20040
- _emberMetal.default.Evented = _emberRuntimeMixinsEvented.default;
20041
-
20042
- _emberMetal.default.PromiseProxyMixin = _emberRuntimeMixinsPromise_proxy.default;
20043
-
20044
- _emberMetal.default.Observable = _emberRuntimeMixinsObservable.default;
20045
-
20046
- _emberMetal.default.typeOf = _emberRuntimeUtils.typeOf;
20047
- _emberMetal.default.isArray = _emberRuntimeUtils.isArray;
20048
-
20049
- // ES6TODO: this seems a less than ideal way/place to add properties to Ember.computed
20050
- var EmComputed = _emberMetal.default.computed;
20051
-
20052
- EmComputed.sum = _emberRuntimeComputedReduce_computed_macros.sum;
20053
- EmComputed.min = _emberRuntimeComputedReduce_computed_macros.min;
20054
- EmComputed.max = _emberRuntimeComputedReduce_computed_macros.max;
20055
- EmComputed.map = _emberRuntimeComputedReduce_computed_macros.map;
20056
- EmComputed.sort = _emberRuntimeComputedReduce_computed_macros.sort;
20057
- EmComputed.setDiff = _emberRuntimeComputedReduce_computed_macros.setDiff;
20058
- EmComputed.mapBy = _emberRuntimeComputedReduce_computed_macros.mapBy;
20059
- EmComputed.filter = _emberRuntimeComputedReduce_computed_macros.filter;
20060
- EmComputed.filterBy = _emberRuntimeComputedReduce_computed_macros.filterBy;
20061
- EmComputed.uniq = _emberRuntimeComputedReduce_computed_macros.uniq;
20062
- EmComputed.union = _emberRuntimeComputedReduce_computed_macros.union;
20063
- EmComputed.intersect = _emberRuntimeComputedReduce_computed_macros.intersect;
20064
- EmComputed.collect = _emberRuntimeComputedReduce_computed_macros.collect;
20065
-
20066
- _emberMetal.default.String = _emberRuntimeSystemString.default;
20067
- _emberMetal.default.Object = _emberRuntimeSystemObject.default;
20068
- _emberMetal.default.Container = _emberRuntimeSystemContainer.Container;
20069
- _emberMetal.default.Registry = _emberRuntimeSystemContainer.Registry;
20070
-
20071
- if (_emberMetalFeatures.default('ember-container-inject-owner')) {
20072
- _emberMetal.default.getOwner = _emberRuntimeSystemContainer.getOwner;
20073
- _emberMetal.default.setOwner = _emberRuntimeSystemContainer.setOwner;
20074
-
20075
- _emberMetal.default._RegistryProxyMixin = _emberRuntimeMixinsRegistry_proxy.default;
20076
- _emberMetal.default._ContainerProxyMixin = _emberRuntimeMixinsContainer_proxy.default;
20077
- }
20078
-
20079
- _emberMetal.default.Namespace = _emberRuntimeSystemNamespace.default;
20080
- _emberMetal.default.Enumerable = _emberRuntimeMixinsEnumerable.default;
20081
- _emberMetal.default.ArrayProxy = _emberRuntimeSystemArray_proxy.default;
20082
- _emberMetal.default.ObjectProxy = _emberRuntimeSystemObject_proxy.default;
20083
- _emberMetal.default.ActionHandler = _emberRuntimeMixinsAction_handler.default;
20084
- _emberMetal.default.CoreObject = _emberRuntimeSystemCore_object.default;
20085
- _emberMetal.default.NativeArray = _emberRuntimeSystemNative_array.default;
20086
- // ES6TODO: Currently we must rely on the global from ember-metal/core to avoid circular deps
20087
- // Ember.A = A;
20088
- _emberMetal.default.onLoad = _emberRuntimeSystemLazy_load.onLoad;
20089
- _emberMetal.default.runLoadHooks = _emberRuntimeSystemLazy_load.runLoadHooks;
20090
-
20091
- _emberMetal.default.Controller = _emberRuntimeControllersController.default;
20092
- _emberMetal.default.ControllerMixin = _emberRuntimeMixinsController.default;
20093
-
20094
- _emberMetal.default.Service = _emberRuntimeSystemService.default;
20095
-
20096
- _emberMetal.default._ProxyMixin = _emberRuntimeMixinsProxy.default;
20097
-
20098
- _emberMetal.default.RSVP = _emberRuntimeExtRsvp.default;
20099
- // END EXPORTS
20100
-
20101
- /**
20102
- Defines the hash of localized strings for the current language. Used by
20103
- the `Ember.String.loc()` helper. To localize, add string values to this
20104
- hash.
20105
-
20106
- @property STRINGS
20107
- @for Ember
20108
- @type Object
20109
- @private
20110
- */
20111
- Object.defineProperty(_emberMetal.default, 'STRINGS', {
20112
- configurable: false,
20113
- get: _emberRuntimeString_registry.getStrings,
20114
- set: _emberRuntimeString_registry.setStrings
20115
- });
20116
-
20117
- exports.default = _emberMetal.default;
20118
- });
20119
- // just for side effect of extending Ember.RSVP
20120
- // just for side effect of extending String.prototype
20121
- // just for side effect of extending Function.prototype
20122
20331
  enifed('rsvp/-internal', ['exports', 'rsvp/utils', 'rsvp/instrument', 'rsvp/config'], function (exports, _rsvpUtils, _rsvpInstrument, _rsvpConfig) {
20123
20332
  'use strict';
20124
20333