ember-source 2.0.0 → 2.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of ember-source might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 86a3455e34f5406a537f434ae5eb905a965067c1
4
- data.tar.gz: da0fc33f176bf0caa31cdcd93c3e4575e22fb5bb
3
+ metadata.gz: 45499c9207754276970daaaf7962746303a12a72
4
+ data.tar.gz: 522a436237cde74c5b9550edc08995f85f6a36ed
5
5
  SHA512:
6
- metadata.gz: ebbd0a6cf64068ac827217c5417004b65e964ac9d63bc9484e1e2ff7bfb198d8adac13e261a5309035b53f42637bbb38185331b0aadb81f0b0fa0189da9e287d
7
- data.tar.gz: c365c89dd36aed0a4e46bec34a5e10465eac163d2961246258734d1b9798affe44aab77f2c87a29dc91531aabe8461a882a038dd5945a001bba49d7cd8a90923
6
+ metadata.gz: fd0b9392a655ee076794ef87f91f55669fab2255c24ad1b96840724abe3a3d5337b7cd031bf73b5ce852e7ef60aa95e7754bd43527a0330bd52de0b25ac34b69
7
+ data.tar.gz: 76d77b09f1e7fd5ac7bea83e62152f50ff1e2dafc3145547326d3322d4f0e741aeaa88d612096bc1384b26cb8d9ea23db1704adfae8cc85d2b3c4af31ef97260
data/VERSION CHANGED
@@ -1 +1 @@
1
- 2.0.0
1
+ 2.0.2
@@ -5,7 +5,7 @@
5
5
  * Portions Copyright 2008-2011 Apple Inc. All rights reserved.
6
6
  * @license Licensed under MIT license
7
7
  * See https://raw.github.com/emberjs/ember.js/master/LICENSE
8
- * @version 2.0.0
8
+ * @version 2.0.2
9
9
  */
10
10
 
11
11
  (function() {
@@ -2323,7 +2323,7 @@ enifed('ember-metal/chains', ['exports', 'ember-metal/core', 'ember-metal/proper
2323
2323
  }
2324
2324
 
2325
2325
  function isVolatile(obj) {
2326
- return !(isObject(obj) && obj.isDescriptor && !obj._volatile);
2326
+ return !(isObject(obj) && obj.isDescriptor && obj._volatile === false);
2327
2327
  }
2328
2328
 
2329
2329
  function Chains() {}
@@ -4059,7 +4059,7 @@ enifed('ember-metal/core', ['exports'], function (exports) {
4059
4059
 
4060
4060
  @class Ember
4061
4061
  @static
4062
- @version 2.0.0
4062
+ @version 2.0.2
4063
4063
  @public
4064
4064
  */
4065
4065
 
@@ -4093,11 +4093,11 @@ enifed('ember-metal/core', ['exports'], function (exports) {
4093
4093
 
4094
4094
  @property VERSION
4095
4095
  @type String
4096
- @default '2.0.0'
4096
+ @default '2.0.2'
4097
4097
  @static
4098
4098
  @public
4099
4099
  */
4100
- Ember.VERSION = '2.0.0';
4100
+ Ember.VERSION = '2.0.2';
4101
4101
 
4102
4102
  /**
4103
4103
  The hash of environment variables used to control various configuration
@@ -4384,6 +4384,29 @@ enifed('ember-metal/dictionary', ['exports'], function (exports) {
4384
4384
  return dict;
4385
4385
  }
4386
4386
  });
4387
+ enifed("ember-metal/empty_object", ["exports"], function (exports) {
4388
+ // This exists because `Object.create(null)` is absurdly slow compared
4389
+ // to `new EmptyObject()`. In either case, you want a null prototype
4390
+ // when you're treating the object instances as arbitrary dictionaries
4391
+ // and don't want your keys colliding with build-in methods on the
4392
+ // default object prototype.
4393
+
4394
+ "use strict";
4395
+
4396
+ var proto = Object.create(null, {
4397
+ // without this, we will always still end up with (new
4398
+ // EmptyObject()).constructor === Object
4399
+ constructor: {
4400
+ value: undefined,
4401
+ enumerable: false,
4402
+ writable: true
4403
+ }
4404
+ });
4405
+
4406
+ function EmptyObject() {}
4407
+ EmptyObject.prototype = proto;
4408
+ exports.default = EmptyObject;
4409
+ });
4387
4410
  enifed('ember-metal/environment', ['exports', 'ember-metal/core'], function (exports, _emberMetalCore) {
4388
4411
  'use strict';
4389
4412
 
@@ -7176,7 +7199,7 @@ enifed('ember-metal/mixin', ['exports', 'ember-metal/core', 'ember-metal/merge',
7176
7199
  @method aliasMethod
7177
7200
  @for Ember
7178
7201
  @param {String} methodName name of the method to alias
7179
- @private
7202
+ @public
7180
7203
  */
7181
7204
 
7182
7205
  function aliasMethod(methodName) {
@@ -9988,7 +10011,7 @@ enifed('ember-metal/streams/utils', ['exports', 'ember-metal/core', './stream'],
9988
10011
  });
9989
10012
 
9990
10013
  for (i = 0, l = array.length; i < l; i++) {
9991
- subscribe(array[i], stream.notify, stream);
10014
+ stream.addDependency(array[i]);
9992
10015
  }
9993
10016
 
9994
10017
  // used by angle bracket components to detect an attribute was provided
@@ -12015,7 +12038,7 @@ enifed('ember-template-compiler/system/compile_options', ['exports', 'ember-meta
12015
12038
 
12016
12039
  options.buildMeta = function buildMeta(program) {
12017
12040
  return {
12018
- revision: 'Ember@2.0.0',
12041
+ revision: 'Ember@2.0.2',
12019
12042
  loc: program.loc,
12020
12043
  moduleName: options.moduleName
12021
12044
  };
@@ -18432,7 +18455,12 @@ enifed("htmlbars-util/morph-utils", ["exports"], function (exports) {
18432
18455
  current = current.nextMorph;
18433
18456
  }
18434
18457
  } else if (node.morphList) {
18435
- nodes.push(node.morphList);
18458
+ var current = node.morphList.firstChildMorph;
18459
+
18460
+ while (current) {
18461
+ nodes.push(current);
18462
+ current = current.nextMorph;
18463
+ }
18436
18464
  }
18437
18465
  }
18438
18466
  }
@@ -5,7 +5,7 @@
5
5
  * Portions Copyright 2008-2011 Apple Inc. All rights reserved.
6
6
  * @license Licensed under MIT license
7
7
  * See https://raw.github.com/emberjs/ember.js/master/LICENSE
8
- * @version 2.0.0
8
+ * @version 2.0.2
9
9
  */
10
10
 
11
11
  (function() {
@@ -5,7 +5,7 @@
5
5
  * Portions Copyright 2008-2011 Apple Inc. All rights reserved.
6
6
  * @license Licensed under MIT license
7
7
  * See https://raw.github.com/emberjs/ember.js/master/LICENSE
8
- * @version 2.0.0
8
+ * @version 2.0.2
9
9
  */
10
10
 
11
11
  (function() {
@@ -4264,7 +4264,13 @@ enifed('ember-application/system/application', ['exports', 'dag-map', 'container
4264
4264
  instanceInitializers: Object.create(null),
4265
4265
 
4266
4266
  /**
4267
- Initializer receives an object which has the following attributes:
4267
+ The goal of initializers should be to register dependencies and injections.
4268
+ This phase runs once. Because these initializers may load code, they are
4269
+ allowed to defer application readiness and advance it. If you need to access
4270
+ the container or store you should use an InstanceInitializer that will be run
4271
+ after all initializers and therefore after all code is loaded and the app is
4272
+ ready.
4273
+ Initializer receives an object which has the following attributes:
4268
4274
  `name`, `before`, `after`, `initialize`. The only required attribute is
4269
4275
  `initialize`, all others are optional.
4270
4276
  * `name` allows you to specify under which name the initializer is registered.
@@ -4339,6 +4345,7 @@ enifed('ember-application/system/application', ['exports', 'dag-map', 'container
4339
4345
  ```javascript
4340
4346
  Ember.Application.initializer({
4341
4347
  name: 'preload-data',
4348
+ after: 'ember-data', // ember-data must be loaded before we can access store
4342
4349
  initialize: function(container, application) {
4343
4350
  var store = container.lookup('store:main');
4344
4351
  store.pushPayload(preloadedData);
@@ -4357,7 +4364,62 @@ enifed('ember-application/system/application', ['exports', 'dag-map', 'container
4357
4364
  @method initializer
4358
4365
  @param initializer {Object}
4359
4366
  @public
4360
- */
4367
+ */
4368
+
4369
+ /**
4370
+ InstanceInitializers run after all initializers have run. Because
4371
+ instanceInitializers run after the app is fully set up. We have access
4372
+ to the store, container, and other items. However, these initializers run
4373
+ after code has loaded and are not allowed to defer readiness.
4374
+ InstanceInitializer receives an object which has the following attributes:
4375
+ `name`, `before`, `after`, `initialize`. The only required attribute is
4376
+ `initialize`, all others are optional.
4377
+ * `name` allows you to specify under which name the instanceInitializer is
4378
+ registered. This must be a unique name, as trying to register two
4379
+ instanceInitializer with the same name will result in an error.
4380
+ ```javascript
4381
+ Ember.Application.instanceInitializer({
4382
+ name: 'namedinstanceInitializer',
4383
+ initialize: function(application) {
4384
+ Ember.debug('Running namedInitializer!');
4385
+ }
4386
+ });
4387
+ ```
4388
+ * `before` and `after` are used to ensure that this initializer is ran prior
4389
+ or after the one identified by the value. This value can be a single string
4390
+ or an array of strings, referencing the `name` of other initializers.
4391
+ * See Ember.Application.initializer for discussion on the usage of before
4392
+ and after.
4393
+ Example instanceInitializer to preload data into the store.
4394
+ ```javascript
4395
+ Ember.Application.initializer({
4396
+ name: 'preload-data',
4397
+ initialize: function(application) {
4398
+ var userConfig, userConfigEncoded, store;
4399
+ // We have a HTML escaped JSON representation of the user's basic
4400
+ // configuration generated server side and stored in the DOM of the main
4401
+ // index.html file. This allows the app to have access to a set of data
4402
+ // without making any additional remote calls. Good for basic data that is
4403
+ // needed for immediate rendering of the page. Keep in mind, this data,
4404
+ // like all local models and data can be manipulated by the user, so it
4405
+ // should not be relied upon for security or authorization.
4406
+ //
4407
+ // Grab the encoded data from the meta tag
4408
+ userConfigEncoded = Ember.$('head meta[name=app-user-config]').attr('content');
4409
+ // Unescape the text, then parse the resulting JSON into a real object
4410
+ userConfig = JSON.parse(unescape(userConfigEncoded));
4411
+ // Lookup the store
4412
+ store = application.container.lookup('service:store');
4413
+ // Push the encoded JSON into the store
4414
+ store.pushPayload(userConfig);
4415
+ }
4416
+ });
4417
+ ```
4418
+ @method instanceInitializer
4419
+ @param instanceInitializer
4420
+ @public
4421
+ */
4422
+
4361
4423
  initializer: buildInitializerMethod('initializers', 'initializer'),
4362
4424
 
4363
4425
  /**
@@ -8647,7 +8709,7 @@ enifed('ember-htmlbars/keywords/outlet', ['exports', 'ember-metal/core', 'ember-
8647
8709
 
8648
8710
  'use strict';
8649
8711
 
8650
- _emberHtmlbarsTemplatesTopLevelView.default.meta.revision = 'Ember@2.0.0';
8712
+ _emberHtmlbarsTemplatesTopLevelView.default.meta.revision = 'Ember@2.0.2';
8651
8713
 
8652
8714
  /**
8653
8715
  The `{{outlet}}` helper lets you specify where a child routes will render in
@@ -11907,6 +11969,8 @@ enifed('ember-metal-views/renderer', ['exports', 'ember-metal/run_loop', 'ember-
11907
11969
  }; // set attrs the first time
11908
11970
 
11909
11971
  Renderer.prototype.componentInitAttrs = function (component, attrs) {
11972
+ // for attrs-proxy support
11973
+ component.trigger('_internalDidReceiveAttrs');
11910
11974
  component.trigger('didInitAttrs', { attrs: attrs });
11911
11975
  component.trigger('didReceiveAttrs', { newAttrs: attrs });
11912
11976
  }; // set attrs the first time
@@ -11947,6 +12011,8 @@ enifed('ember-metal-views/renderer', ['exports', 'ember-metal/run_loop', 'ember-
11947
12011
  _emberMetalProperty_set.set(component, 'attrs', newAttrs);
11948
12012
  }
11949
12013
 
12014
+ // for attrs-proxy support
12015
+ component.trigger('_internalDidReceiveAttrs');
11950
12016
  component.trigger('didUpdateAttrs', { oldAttrs: oldAttrs, newAttrs: newAttrs });
11951
12017
  component.trigger('didReceiveAttrs', { oldAttrs: oldAttrs, newAttrs: newAttrs });
11952
12018
  };
@@ -12835,7 +12901,7 @@ enifed('ember-metal/chains', ['exports', 'ember-metal/core', 'ember-metal/proper
12835
12901
  }
12836
12902
 
12837
12903
  function isVolatile(obj) {
12838
- return !(isObject(obj) && obj.isDescriptor && !obj._volatile);
12904
+ return !(isObject(obj) && obj.isDescriptor && obj._volatile === false);
12839
12905
  }
12840
12906
 
12841
12907
  function Chains() {}
@@ -14571,7 +14637,7 @@ enifed('ember-metal/core', ['exports'], function (exports) {
14571
14637
 
14572
14638
  @class Ember
14573
14639
  @static
14574
- @version 2.0.0
14640
+ @version 2.0.2
14575
14641
  @public
14576
14642
  */
14577
14643
 
@@ -14605,11 +14671,11 @@ enifed('ember-metal/core', ['exports'], function (exports) {
14605
14671
 
14606
14672
  @property VERSION
14607
14673
  @type String
14608
- @default '2.0.0'
14674
+ @default '2.0.2'
14609
14675
  @static
14610
14676
  @public
14611
14677
  */
14612
- Ember.VERSION = '2.0.0';
14678
+ Ember.VERSION = '2.0.2';
14613
14679
 
14614
14680
  /**
14615
14681
  The hash of environment variables used to control various configuration
@@ -14896,6 +14962,29 @@ enifed('ember-metal/dictionary', ['exports'], function (exports) {
14896
14962
  return dict;
14897
14963
  }
14898
14964
  });
14965
+ enifed("ember-metal/empty_object", ["exports"], function (exports) {
14966
+ // This exists because `Object.create(null)` is absurdly slow compared
14967
+ // to `new EmptyObject()`. In either case, you want a null prototype
14968
+ // when you're treating the object instances as arbitrary dictionaries
14969
+ // and don't want your keys colliding with build-in methods on the
14970
+ // default object prototype.
14971
+
14972
+ "use strict";
14973
+
14974
+ var proto = Object.create(null, {
14975
+ // without this, we will always still end up with (new
14976
+ // EmptyObject()).constructor === Object
14977
+ constructor: {
14978
+ value: undefined,
14979
+ enumerable: false,
14980
+ writable: true
14981
+ }
14982
+ });
14983
+
14984
+ function EmptyObject() {}
14985
+ EmptyObject.prototype = proto;
14986
+ exports.default = EmptyObject;
14987
+ });
14899
14988
  enifed('ember-metal/environment', ['exports', 'ember-metal/core'], function (exports, _emberMetalCore) {
14900
14989
  'use strict';
14901
14990
 
@@ -17688,7 +17777,7 @@ enifed('ember-metal/mixin', ['exports', 'ember-metal/core', 'ember-metal/merge',
17688
17777
  @method aliasMethod
17689
17778
  @for Ember
17690
17779
  @param {String} methodName name of the method to alias
17691
- @private
17780
+ @public
17692
17781
  */
17693
17782
 
17694
17783
  function aliasMethod(methodName) {
@@ -20500,7 +20589,7 @@ enifed('ember-metal/streams/utils', ['exports', 'ember-metal/core', './stream'],
20500
20589
  });
20501
20590
 
20502
20591
  for (i = 0, l = array.length; i < l; i++) {
20503
- subscribe(array[i], stream.notify, stream);
20592
+ stream.addDependency(array[i]);
20504
20593
  }
20505
20594
 
20506
20595
  // used by angle bracket components to detect an attribute was provided
@@ -22444,8 +22533,80 @@ enifed('ember-routing-htmlbars/keywords/link-to', ['exports', 'ember-metal/strea
22444
22533
  });
22445
22534
  // assert
22446
22535
  enifed('ember-routing-htmlbars/keywords/render', ['exports', 'ember-metal/core', 'ember-metal/property_get', 'ember-metal/error', 'ember-metal/streams/utils', 'ember-runtime/system/string', 'ember-routing/system/generate_controller', 'ember-htmlbars/node-managers/view-node-manager'], function (exports, _emberMetalCore, _emberMetalProperty_get, _emberMetalError, _emberMetalStreamsUtils, _emberRuntimeSystemString, _emberRoutingSystemGenerate_controller, _emberHtmlbarsNodeManagersViewNodeManager) {
22536
+ /**
22537
+ @module ember
22538
+ @submodule ember-templates
22539
+ */
22540
+
22447
22541
  'use strict';
22448
22542
 
22543
+ /**
22544
+ Calling ``{{render}}`` from within a template will insert another
22545
+ template that matches the provided name. The inserted template will
22546
+ access its properties on its own controller (rather than the controller
22547
+ of the parent template).
22548
+ If a view class with the same name exists, the view class also will be used.
22549
+ Note: A given controller may only be used *once* in your app in this manner.
22550
+ A singleton instance of the controller will be created for you.
22551
+ Example:
22552
+
22553
+ ```javascript
22554
+ App.NavigationController = Ember.Controller.extend({
22555
+ who: "world"
22556
+ });
22557
+ ```
22558
+
22559
+ ```handlebars
22560
+ <!-- navigation.hbs -->
22561
+ Hello, {{who}}.
22562
+ ```
22563
+
22564
+ ```handlebars
22565
+ <!-- application.hbs -->
22566
+ <h1>My great app</h1>
22567
+ {{render "navigation"}}
22568
+ ```
22569
+
22570
+ ```html
22571
+ <h1>My great app</h1>
22572
+ <div class='ember-view'>
22573
+ Hello, world.
22574
+ </div>
22575
+ ```
22576
+
22577
+ Optionally you may provide a second argument: a property path
22578
+ that will be bound to the `model` property of the controller.
22579
+ If a `model` property path is specified, then a new instance of the
22580
+ controller will be created and `{{render}}` can be used multiple times
22581
+ with the same name.
22582
+
22583
+ For example if you had this `author` template.
22584
+
22585
+ ```handlebars
22586
+ <div class="author">
22587
+ Written by {{firstName}} {{lastName}}.
22588
+ Total Posts: {{postCount}}
22589
+ </div>
22590
+ ```
22591
+
22592
+ You could render it inside the `post` template using the `render` helper.
22593
+
22594
+ ```handlebars
22595
+ <div class="post">
22596
+ <h1>{{title}}</h1>
22597
+ <div>{{body}}</div>
22598
+ {{render "author" author}}
22599
+ </div>
22600
+ ```
22601
+
22602
+ @method render
22603
+ @for Ember.Templates.helpers
22604
+ @param {String} name
22605
+ @param {Object?} context
22606
+ @param {Hash} options
22607
+ @return {String} HTML string
22608
+ @public
22609
+ */
22449
22610
  exports.default = {
22450
22611
  willRender: function (renderNode, env) {
22451
22612
  if (env.view.ownerView._outlets) {
@@ -22676,7 +22837,7 @@ enifed('ember-routing-views/views/link', ['exports', 'ember-metal/core', 'ember-
22676
22837
 
22677
22838
  'use strict';
22678
22839
 
22679
- _emberHtmlbarsTemplatesLinkTo.default.meta.revision = 'Ember@2.0.0';
22840
+ _emberHtmlbarsTemplatesLinkTo.default.meta.revision = 'Ember@2.0.2';
22680
22841
 
22681
22842
  var linkComponentClassNameBindings = ['active', 'loading', 'disabled'];
22682
22843
 
@@ -23178,7 +23339,7 @@ enifed('ember-routing-views/views/outlet', ['exports', 'ember-views/views/view',
23178
23339
 
23179
23340
  'use strict';
23180
23341
 
23181
- _emberHtmlbarsTemplatesTopLevelView.default.meta.revision = 'Ember@2.0.0';
23342
+ _emberHtmlbarsTemplatesTopLevelView.default.meta.revision = 'Ember@2.0.2';
23182
23343
 
23183
23344
  var CoreOutletView = _emberViewsViewsView.default.extend({
23184
23345
  defaultTemplate: _emberHtmlbarsTemplatesTopLevelView.default,
@@ -25619,7 +25780,7 @@ enifed('ember-routing/system/route', ['exports', 'ember-metal/core', 'ember-meta
25619
25780
  // if you just want to transition the query parameters without changing the route
25620
25781
  this.transitionTo({queryParams: {sort: 'date'}});
25621
25782
  ```
25622
- See also 'replaceWith'.
25783
+ See also [replaceWith](#method_replaceWith).
25623
25784
  Simple Transition Example
25624
25785
  ```javascript
25625
25786
  App.Router.map(function() {
@@ -25715,7 +25876,7 @@ enifed('ember-routing/system/route', ['exports', 'ember-metal/core', 'ember-meta
25715
25876
  @param {...Object} models the model(s) to be used while transitioning
25716
25877
  to the route.
25717
25878
  @since 1.2.0
25718
- @private
25879
+ @public
25719
25880
  */
25720
25881
  intermediateTransitionTo: function () {
25721
25882
  var router = this.router;
@@ -26350,13 +26511,14 @@ enifed('ember-routing/system/route', ['exports', 'ember-metal/core', 'ember-meta
26350
26511
  },
26351
26512
 
26352
26513
  /**
26353
- Returns the model of a parent (or any ancestor) route
26514
+ Returns the resolved model of a parent (or any ancestor) route
26354
26515
  in a route hierarchy. During a transition, all routes
26355
26516
  must resolve a model object, and if a route
26356
26517
  needs access to a parent route's model in order to
26357
26518
  resolve a model (or just reuse the model from a parent),
26358
26519
  it can call `this.modelFor(theNameOfParentRoute)` to
26359
- retrieve it.
26520
+ retrieve it. If the ancestor route's model was a promise,
26521
+ its resolved result is returned.
26360
26522
  Example
26361
26523
  ```javascript
26362
26524
  App.Router.map(function() {
@@ -26873,10 +27035,11 @@ enifed('ember-routing/system/router', ['exports', 'ember-metal/core', 'ember-met
26873
27035
  The `location` property determines the type of URL's that your
26874
27036
  application will use.
26875
27037
  The following location types are currently available:
26876
- * `auto`
26877
- * `hash`
26878
- * `history`
26879
- * `none`
27038
+ * `history` - use the browser's history API to make the URLs look just like any standard URL
27039
+ * `hash` - use `#` to separate the server part of the URL from the Ember part: `/blog/#/posts/new`
27040
+ * `none` - do not store the Ember URL in the actual browser URL (mainly used for testing)
27041
+ * `auto` - use the best option based on browser capabilites: `history` if possible, then `hash` if possible, otherwise `none`
27042
+ Note: If using ember-cli, this value is defaulted to `auto` by the `locationType` setting of `/config/environment.js`
26880
27043
  @property location
26881
27044
  @default 'hash'
26882
27045
  @see {Ember.Location}
@@ -26997,6 +27160,20 @@ enifed('ember-routing/system/router', ['exports', 'ember-metal/core', 'ember-met
26997
27160
  Handles updating the paths and notifying any listeners of the URL
26998
27161
  change.
26999
27162
  Triggers the router level `didTransition` hook.
27163
+ For example, to notify google analytics when the route changes,
27164
+ you could use this hook. (Note: requires also including GA scripts, etc.)
27165
+ ```javascript
27166
+ var Router = Ember.Router.extend({
27167
+ location: config.locationType,
27168
+ didTransition: function() {
27169
+ this._super(...arguments);
27170
+ return ga('send', 'pageview', {
27171
+ 'page': this.get('url'),
27172
+ 'title': this.get('url')
27173
+ });
27174
+ }
27175
+ });
27176
+ ```
27000
27177
  @method didTransition
27001
27178
  @public
27002
27179
  @since 1.2.0
@@ -28218,7 +28395,7 @@ enifed('ember-runtime', ['exports', 'ember-metal', 'ember-runtime/core', 'ember-
28218
28395
  _emberMetal.default.Observable = _emberRuntimeMixinsObservable.default;
28219
28396
 
28220
28397
  _emberMetal.default.typeOf = _emberRuntimeUtils.typeOf;
28221
- _emberMetal.default.isArray = Array.isArray;
28398
+ _emberMetal.default.isArray = _emberRuntimeUtils.isArray;
28222
28399
 
28223
28400
  // ES6TODO: this seems a less than ideal way/place to add properties to Ember.computed
28224
28401
  var EmComputed = _emberMetal.default.computed;
@@ -28406,7 +28583,13 @@ enifed('ember-runtime/computed/reduce_computed_macros', ['exports', 'ember-metal
28406
28583
  return _emberMetalComputed.computed(dependentKey + '.[]', function () {
28407
28584
  var _this = this;
28408
28585
 
28409
- return _emberMetalProperty_get.get(this, dependentKey).reduce(function (previousValue, currentValue, index, array) {
28586
+ var arr = _emberMetalProperty_get.get(this, dependentKey);
28587
+
28588
+ if (arr === null || typeof arr !== 'object') {
28589
+ return initialValue;
28590
+ }
28591
+
28592
+ return arr.reduce(function (previousValue, currentValue, index, array) {
28410
28593
  return callback.call(_this, previousValue, currentValue, index, array);
28411
28594
  }, initialValue);
28412
28595
  }).readOnly();
@@ -28997,6 +29180,10 @@ enifed('ember-runtime/computed/reduce_computed_macros', ['exports', 'ember-metal
28997
29180
  var items = itemsKey === '@this' ? this : _emberMetalProperty_get.get(this, itemsKey);
28998
29181
  var sortProperties = _emberMetalProperty_get.get(this, sortPropertiesKey);
28999
29182
 
29183
+ if (items === null || typeof items !== 'object') {
29184
+ return _emberMetalCore.default.A();
29185
+ }
29186
+
29000
29187
  // TODO: Ideally we'd only do this if things have changed
29001
29188
  if (cp._sortPropObservers) {
29002
29189
  cp._sortPropObservers.forEach(function (args) {
@@ -29767,7 +29954,7 @@ enifed('ember-runtime/mixins/-proxy', ['exports', 'ember-metal/core', 'ember-met
29767
29954
  });
29768
29955
  });
29769
29956
  // Ember.assert
29770
- enifed('ember-runtime/mixins/action_handler', ['exports', 'ember-metal/core', 'ember-metal/mixin', 'ember-metal/property_get', 'ember-metal/deprecate_property'], function (exports, _emberMetalCore, _emberMetalMixin, _emberMetalProperty_get, _emberMetalDeprecate_property) {
29957
+ enifed('ember-runtime/mixins/action_handler', ['exports', 'ember-metal/core', 'ember-metal/mixin', 'ember-metal/property_get'], function (exports, _emberMetalCore, _emberMetalMixin, _emberMetalProperty_get) {
29771
29958
  /**
29772
29959
  @module ember
29773
29960
  @submodule ember-runtime
@@ -29937,14 +30124,37 @@ enifed('ember-runtime/mixins/action_handler', ['exports', 'ember-metal/core', 'e
29937
30124
  _emberMetalCore.default.assert('The `target` for ' + this + ' (' + target + ') does not have a `send` method', typeof target.send === 'function');
29938
30125
  (_target = target).send.apply(_target, arguments);
29939
30126
  }
30127
+ },
30128
+
30129
+ willMergeMixin: function (props) {
30130
+ _emberMetalCore.default.assert('Specifying `_actions` and `actions` in the same mixin is not supported.', !props.actions || !props._actions);
30131
+
30132
+ if (props._actions) {
30133
+ _emberMetalCore.default.deprecate('Specifying actions in `_actions` is deprecated, please use `actions` instead.', false, { id: 'ember-runtime.action-handler-_actions', until: '3.0.0' });
30134
+
30135
+ props.actions = props._actions;
30136
+ delete props._actions;
30137
+ }
29940
30138
  }
29941
30139
  });
29942
30140
 
29943
30141
  exports.default = ActionHandler;
29944
30142
 
29945
30143
  function deprecateUnderscoreActions(factory) {
29946
- _emberMetalDeprecate_property.deprecateProperty(factory.prototype, '_actions', 'actions', {
29947
- id: 'ember-runtime.action-handler-_actions', until: '3.0.0'
30144
+ function deprecate() {
30145
+ _emberMetalCore.default.deprecate('Usage of `_actions` is deprecated, use `actions` instead.', false, { id: 'ember-runtime.action-handler-_actions', until: '3.0.0' });
30146
+ }
30147
+
30148
+ Object.defineProperty(factory.prototype, '_actions', {
30149
+ configurable: true,
30150
+ enumerable: false,
30151
+ set: function (value) {
30152
+ _emberMetalCore.default.assert('You cannot set `_actions` on ' + this + ', please use `actions` instead.');
30153
+ },
30154
+ get: function () {
30155
+ deprecate();
30156
+ return _emberMetalProperty_get.get(this, 'actions');
30157
+ }
29948
30158
  });
29949
30159
  }
29950
30160
  });
@@ -30501,7 +30711,7 @@ enifed('ember-runtime/mixins/controller', ['exports', 'ember-metal/mixin', 'embe
30501
30711
  consumer of actions for the controller.
30502
30712
  @property target
30503
30713
  @default null
30504
- @private
30714
+ @public
30505
30715
  */
30506
30716
  target: null,
30507
30717
 
@@ -32355,9 +32565,10 @@ enifed('ember-runtime/mixins/observable', ['exports', 'ember-metal/core', 'ember
32355
32565
 
32356
32566
  ```javascript
32357
32567
  Ember.Object.extend({
32358
- valueObserver: function() {
32568
+ valueObserver: Ember.observer('value', function(sender, key, value, rev) {
32359
32569
  // Executes whenever the "value" property changes
32360
- }.observes('value')
32570
+ // See the addObserver method for more information about the callback arguments
32571
+ })
32361
32572
  });
32362
32573
  ```
32363
32574
 
@@ -36440,7 +36651,7 @@ enifed('ember-template-compiler/system/compile_options', ['exports', 'ember-meta
36440
36651
 
36441
36652
  options.buildMeta = function buildMeta(program) {
36442
36653
  return {
36443
- revision: 'Ember@2.0.0',
36654
+ revision: 'Ember@2.0.2',
36444
36655
  loc: program.loc,
36445
36656
  moduleName: options.moduleName
36446
36657
  };
@@ -37817,7 +38028,7 @@ enifed('ember-views', ['exports', 'ember-runtime', 'ember-views/system/jquery',
37817
38028
  exports.default = _emberRuntime.default;
37818
38029
  });
37819
38030
  // for the side effect of extending Ember.run.queues
37820
- enifed('ember-views/compat/attrs-proxy', ['exports', 'ember-metal/mixin', 'ember-metal/utils', 'ember-metal/property_events', 'ember-metal/events'], function (exports, _emberMetalMixin, _emberMetalUtils, _emberMetalProperty_events, _emberMetalEvents) {
38031
+ enifed('ember-views/compat/attrs-proxy', ['exports', 'ember-metal/mixin', 'ember-metal/utils', 'ember-metal/property_events', 'ember-metal/events', 'ember-metal/empty_object'], function (exports, _emberMetalMixin, _emberMetalUtils, _emberMetalProperty_events, _emberMetalEvents, _emberMetalEmpty_object) {
37821
38032
  'use strict';
37822
38033
 
37823
38034
  exports.deprecation = deprecation;
@@ -37833,9 +38044,38 @@ enifed('ember-views/compat/attrs-proxy', ['exports', 'ember-metal/mixin', 'ember
37833
38044
  return val && val[MUTABLE_CELL];
37834
38045
  }
37835
38046
 
38047
+ function setupAvoidPropagating(instance) {
38048
+ // This caches the list of properties to avoid setting onto the component instance
38049
+ // inside `_propagateAttrsToThis`. We cache them so that every instantiated component
38050
+ // does not have to pay the calculation penalty.
38051
+ var constructor = instance.constructor;
38052
+ if (!constructor.__avoidPropagating) {
38053
+ constructor.__avoidPropagating = new _emberMetalEmpty_object.default();
38054
+ var i = undefined,
38055
+ l = undefined;
38056
+ for (i = 0, l = instance.concatenatedProperties.length; i < l; i++) {
38057
+ var prop = instance.concatenatedProperties[i];
38058
+
38059
+ constructor.__avoidPropagating[prop] = true;
38060
+ }
38061
+
38062
+ for (i = 0, l = instance.mergedProperties.length; i < l; i++) {
38063
+ var prop = instance.mergedProperties[i];
38064
+
38065
+ constructor.__avoidPropagating[prop] = true;
38066
+ }
38067
+ }
38068
+ }
38069
+
37836
38070
  var AttrsProxyMixin = {
37837
38071
  attrs: null,
37838
38072
 
38073
+ init: function () {
38074
+ this._super.apply(this, arguments);
38075
+
38076
+ setupAvoidPropagating(this);
38077
+ },
38078
+
37839
38079
  getAttr: function (key) {
37840
38080
  var attrs = this.attrs;
37841
38081
  if (!attrs) {
@@ -37864,11 +38104,7 @@ enifed('ember-views/compat/attrs-proxy', ['exports', 'ember-metal/mixin', 'ember
37864
38104
  var attrs = this.attrs;
37865
38105
 
37866
38106
  for (var prop in attrs) {
37867
- if (prop !== 'attrs' &&
37868
- // These list of properties are concatenated and merged properties of
37869
- // Ember.View / Ember.Component. Setting them here results in them being
37870
- // completely stomped and not handled properly, BAIL OUT!
37871
- prop !== 'actions' && prop !== 'classNames' && prop !== 'classNameBindings' && prop !== 'attributeBindings') {
38107
+ if (prop !== 'attrs' && !this.constructor.__avoidPropagating[prop]) {
37872
38108
  this.set(prop, this.getAttr(prop));
37873
38109
  }
37874
38110
  }
@@ -37878,7 +38114,7 @@ enifed('ember-views/compat/attrs-proxy', ['exports', 'ember-metal/mixin', 'ember
37878
38114
  this._isDispatchingAttrs = false;
37879
38115
  }),
37880
38116
 
37881
- didReceiveAttrs: function () {
38117
+ _internalDidReceiveAttrs: function () {
37882
38118
  this._super();
37883
38119
  this._isDispatchingAttrs = true;
37884
38120
  this._propagateAttrsToThis();
@@ -40959,6 +41195,45 @@ enifed('ember-views/views/component', ['exports', 'ember-metal/core', 'ember-run
40959
41195
  @property hasBlockParams
40960
41196
  @returns Boolean
40961
41197
  */
41198
+
41199
+ /**
41200
+ Enables components to take a list of parameters as arguments
41201
+ For example a component that takes two parameters with the names
41202
+ `name` and `age`:
41203
+ ```javascript
41204
+ let MyComponent = Ember.Component.extend;
41205
+ MyComponent.reopenClass({
41206
+ positionalParams: ['name', 'age']
41207
+ });
41208
+ ```
41209
+ It can then be invoked like this:
41210
+ ```hbs
41211
+ {{my-component "John" 38}}
41212
+ ```
41213
+ The parameters can be refered to just like named parameters:
41214
+ ```hbs
41215
+ Name: {{attrs.name}}, Age: {{attrs.age}}.
41216
+ ```
41217
+ Using a string instead of an array allows for an arbitrary number of
41218
+ parameters:
41219
+ ```javascript
41220
+ let MyComponent = Ember.Component.extend;
41221
+ MyComponent.reopenClass({
41222
+ positionalParams: 'names'
41223
+ });
41224
+ ```
41225
+ It can then be invoked like this:
41226
+ ```hbs
41227
+ {{my-component "John" "Michael" "Scott"}}
41228
+ ```
41229
+ The parameters can then be refered to by enumerating over the list:
41230
+ ```hbs
41231
+ {{#each attrs.names as |name|}}{{name}}{{/each}}
41232
+ ```
41233
+ @static
41234
+ @public
41235
+ @property positionalParams
41236
+ */
40962
41237
  });
40963
41238
 
40964
41239
  Component.reopenClass({
@@ -40971,7 +41246,7 @@ enifed('ember-views/views/component', ['exports', 'ember-metal/core', 'ember-run
40971
41246
  enifed('ember-views/views/container_view', ['exports', 'ember-metal/core', 'ember-runtime/mixins/mutable_array', 'ember-views/views/view', 'ember-metal/property_get', 'ember-metal/property_set', 'ember-metal/mixin', 'ember-metal/events', 'ember-htmlbars/templates/container-view'], function (exports, _emberMetalCore, _emberRuntimeMixinsMutable_array, _emberViewsViewsView, _emberMetalProperty_get, _emberMetalProperty_set, _emberMetalMixin, _emberMetalEvents, _emberHtmlbarsTemplatesContainerView) {
40972
41247
  'use strict';
40973
41248
 
40974
- _emberHtmlbarsTemplatesContainerView.default.meta.revision = 'Ember@2.0.0';
41249
+ _emberHtmlbarsTemplatesContainerView.default.meta.revision = 'Ember@2.0.2';
40975
41250
 
40976
41251
  /**
40977
41252
  @module ember
@@ -46145,7 +46420,12 @@ enifed("htmlbars-util/morph-utils", ["exports"], function (exports) {
46145
46420
  current = current.nextMorph;
46146
46421
  }
46147
46422
  } else if (node.morphList) {
46148
- nodes.push(node.morphList);
46423
+ var current = node.morphList.firstChildMorph;
46424
+
46425
+ while (current) {
46426
+ nodes.push(current);
46427
+ current = current.nextMorph;
46428
+ }
46149
46429
  }
46150
46430
  }
46151
46431
  }