ember-source 2.12.0.beta.1 → 2.12.0.beta.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -6,10 +6,11 @@
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.12.0-beta.1
9
+ * @version 2.12.0-beta.2
10
10
  */
11
11
 
12
12
  var enifed, requireModule, Ember;
13
+ var mainContext = this; // Used in ember-environment/lib/global.js
13
14
 
14
15
  (function() {
15
16
  var isNode = typeof window === 'undefined' &&
@@ -28569,6 +28570,36 @@ enifed('ember-glimmer/tests/integration/helpers/input-test', ['exports', 'ember-
28569
28570
  this.assertAttr('type', 'password');
28570
28571
  };
28571
28572
 
28573
+ _class2.prototype['@test a subexpression can be used to determine type'] = function testASubexpressionCanBeUsedToDetermineType() {
28574
+ var _this11 = this;
28575
+
28576
+ this.render('{{input type=(if isTruthy trueType falseType)}}', {
28577
+ isTruthy: true,
28578
+ trueType: 'text',
28579
+ falseType: 'password'
28580
+ });
28581
+
28582
+ this.assertAttr('type', 'text');
28583
+
28584
+ this.runTask(function () {
28585
+ return _this11.rerender();
28586
+ });
28587
+
28588
+ this.assertAttr('type', 'text');
28589
+
28590
+ this.runTask(function () {
28591
+ return _emberMetal.set(_this11.context, 'isTruthy', false);
28592
+ });
28593
+
28594
+ this.assertAttr('type', 'password');
28595
+
28596
+ this.runTask(function () {
28597
+ return _emberMetal.set(_this11.context, 'isTruthy', true);
28598
+ });
28599
+
28600
+ this.assertAttr('type', 'text');
28601
+ };
28602
+
28572
28603
  return _class2;
28573
28604
  })(InputRenderingTest));
28574
28605
 
@@ -28580,7 +28611,7 @@ enifed('ember-glimmer/tests/integration/helpers/input-test', ['exports', 'ember-
28580
28611
  }
28581
28612
 
28582
28613
  _class3.prototype['@test dynamic attributes'] = function testDynamicAttributes() {
28583
- var _this11 = this;
28614
+ var _this12 = this;
28584
28615
 
28585
28616
  this.render('{{input\n type=\'checkbox\'\n disabled=disabled\n name=name\n checked=checked\n tabindex=tabindex\n }}', {
28586
28617
  disabled: false,
@@ -28595,7 +28626,7 @@ enifed('ember-glimmer/tests/integration/helpers/input-test', ['exports', 'ember-
28595
28626
  this.assertAttr('tabindex', '10');
28596
28627
 
28597
28628
  this.runTask(function () {
28598
- return _this11.rerender();
28629
+ return _this12.rerender();
28599
28630
  });
28600
28631
 
28601
28632
  this.assertSingleCheckbox();
@@ -28604,9 +28635,9 @@ enifed('ember-glimmer/tests/integration/helpers/input-test', ['exports', 'ember-
28604
28635
  this.assertAttr('tabindex', '10');
28605
28636
 
28606
28637
  this.runTask(function () {
28607
- _emberMetal.set(_this11.context, 'disabled', true);
28608
- _emberMetal.set(_this11.context, 'name', 'updated-name');
28609
- _emberMetal.set(_this11.context, 'tabindex', 11);
28638
+ _emberMetal.set(_this12.context, 'disabled', true);
28639
+ _emberMetal.set(_this12.context, 'name', 'updated-name');
28640
+ _emberMetal.set(_this12.context, 'tabindex', 11);
28610
28641
  });
28611
28642
 
28612
28643
  this.assertSingleCheckbox();
@@ -28615,9 +28646,9 @@ enifed('ember-glimmer/tests/integration/helpers/input-test', ['exports', 'ember-
28615
28646
  this.assertAttr('tabindex', '11');
28616
28647
 
28617
28648
  this.runTask(function () {
28618
- _emberMetal.set(_this11.context, 'disabled', false);
28619
- _emberMetal.set(_this11.context, 'name', 'original-name');
28620
- _emberMetal.set(_this11.context, 'tabindex', 10);
28649
+ _emberMetal.set(_this12.context, 'disabled', false);
28650
+ _emberMetal.set(_this12.context, 'name', 'original-name');
28651
+ _emberMetal.set(_this12.context, 'tabindex', 10);
28621
28652
  });
28622
28653
 
28623
28654
  this.assertSingleCheckbox();
@@ -28627,15 +28658,15 @@ enifed('ember-glimmer/tests/integration/helpers/input-test', ['exports', 'ember-
28627
28658
  };
28628
28659
 
28629
28660
  _class3.prototype['@test `value` property assertion'] = function testValuePropertyAssertion() {
28630
- var _this12 = this;
28661
+ var _this13 = this;
28631
28662
 
28632
28663
  expectAssertion(function () {
28633
- _this12.render('{{input type="checkbox" value=value}}', { value: 'value' });
28664
+ _this13.render('{{input type="checkbox" value=value}}', { value: 'value' });
28634
28665
  }, /you must use `checked=/);
28635
28666
  };
28636
28667
 
28637
28668
  _class3.prototype['@test with a bound type'] = function testWithABoundType(assert) {
28638
- var _this13 = this;
28669
+ var _this14 = this;
28639
28670
 
28640
28671
  this.render('{{input type=inputType checked=isChecked}}', { inputType: 'checkbox', isChecked: true });
28641
28672
 
@@ -28643,26 +28674,26 @@ enifed('ember-glimmer/tests/integration/helpers/input-test', ['exports', 'ember-
28643
28674
  this.assertCheckboxIsChecked();
28644
28675
 
28645
28676
  this.runTask(function () {
28646
- return _this13.rerender();
28677
+ return _this14.rerender();
28647
28678
  });
28648
28679
 
28649
28680
  this.assertCheckboxIsChecked();
28650
28681
 
28651
28682
  this.runTask(function () {
28652
- return _emberMetal.set(_this13.context, 'isChecked', false);
28683
+ return _emberMetal.set(_this14.context, 'isChecked', false);
28653
28684
  });
28654
28685
 
28655
28686
  this.assertCheckboxIsNotChecked();
28656
28687
 
28657
28688
  this.runTask(function () {
28658
- return _emberMetal.set(_this13.context, 'isChecked', true);
28689
+ return _emberMetal.set(_this14.context, 'isChecked', true);
28659
28690
  });
28660
28691
 
28661
28692
  this.assertCheckboxIsChecked();
28662
28693
  };
28663
28694
 
28664
28695
  _class3.prototype['@test with static values'] = function testWithStaticValues(assert) {
28665
- var _this14 = this;
28696
+ var _this15 = this;
28666
28697
 
28667
28698
  this.render('{{input type="checkbox" disabled=false tabindex=10 name="original-name" checked=false}}');
28668
28699
 
@@ -28673,7 +28704,7 @@ enifed('ember-glimmer/tests/integration/helpers/input-test', ['exports', 'ember-
28673
28704
  this.assertAttr('name', 'original-name');
28674
28705
 
28675
28706
  this.runTask(function () {
28676
- return _this14.rerender();
28707
+ return _this15.rerender();
28677
28708
  });
28678
28709
 
28679
28710
  this.assertSingleCheckbox();
@@ -28694,7 +28725,7 @@ enifed('ember-glimmer/tests/integration/helpers/input-test', ['exports', 'ember-
28694
28725
  }
28695
28726
 
28696
28727
  _class4.prototype['@test null values'] = function testNullValues(assert) {
28697
- var _this15 = this;
28728
+ var _this16 = this;
28698
28729
 
28699
28730
  var attributes = ['disabled', 'placeholder', 'name', 'maxlength', 'size', 'tabindex'];
28700
28731
 
@@ -28712,20 +28743,20 @@ enifed('ember-glimmer/tests/integration/helpers/input-test', ['exports', 'ember-
28712
28743
  this.assertAllAttrs(attributes, undefined);
28713
28744
 
28714
28745
  this.runTask(function () {
28715
- return _this15.rerender();
28746
+ return _this16.rerender();
28716
28747
  });
28717
28748
 
28718
28749
  this.assertValue('');
28719
28750
  this.assertAllAttrs(attributes, undefined);
28720
28751
 
28721
28752
  this.runTask(function () {
28722
- _emberMetal.set(_this15.context, 'disabled', true);
28723
- _emberMetal.set(_this15.context, 'value', 'Updated value');
28724
- _emberMetal.set(_this15.context, 'placeholder', 'Updated placeholder');
28725
- _emberMetal.set(_this15.context, 'name', 'updated-name');
28726
- _emberMetal.set(_this15.context, 'maxlength', 11);
28727
- _emberMetal.set(_this15.context, 'size', 21);
28728
- _emberMetal.set(_this15.context, 'tabindex', 31);
28753
+ _emberMetal.set(_this16.context, 'disabled', true);
28754
+ _emberMetal.set(_this16.context, 'value', 'Updated value');
28755
+ _emberMetal.set(_this16.context, 'placeholder', 'Updated placeholder');
28756
+ _emberMetal.set(_this16.context, 'name', 'updated-name');
28757
+ _emberMetal.set(_this16.context, 'maxlength', 11);
28758
+ _emberMetal.set(_this16.context, 'size', 21);
28759
+ _emberMetal.set(_this16.context, 'tabindex', 31);
28729
28760
  });
28730
28761
 
28731
28762
  this.assertDisabled();
@@ -28737,13 +28768,13 @@ enifed('ember-glimmer/tests/integration/helpers/input-test', ['exports', 'ember-
28737
28768
  this.assertAttr('tabindex', '31');
28738
28769
 
28739
28770
  this.runTask(function () {
28740
- _emberMetal.set(_this15.context, 'disabled', null);
28741
- _emberMetal.set(_this15.context, 'value', null);
28742
- _emberMetal.set(_this15.context, 'placeholder', null);
28743
- _emberMetal.set(_this15.context, 'name', null);
28744
- _emberMetal.set(_this15.context, 'maxlength', null);
28771
+ _emberMetal.set(_this16.context, 'disabled', null);
28772
+ _emberMetal.set(_this16.context, 'value', null);
28773
+ _emberMetal.set(_this16.context, 'placeholder', null);
28774
+ _emberMetal.set(_this16.context, 'name', null);
28775
+ _emberMetal.set(_this16.context, 'maxlength', null);
28745
28776
  // set(this.context, 'size', null); //NOTE: this fails with `Error: Failed to set the 'size' property on 'HTMLInputElement': The value provided is 0, which is an invalid size.` (TEST_SUITE=sauce)
28746
- _emberMetal.set(_this15.context, 'tabindex', null);
28777
+ _emberMetal.set(_this16.context, 'tabindex', null);
28747
28778
  });
28748
28779
 
28749
28780
  this.assertAttr('disabled', undefined);
@@ -63786,6 +63817,38 @@ enifed('ember-template-compiler/tests/plugins/transform-input-on-test.lint-test'
63786
63817
  assert.ok(true, 'ember-template-compiler/tests/plugins/transform-input-on-test.js should pass ESLint\n\n');
63787
63818
  });
63788
63819
  });
63820
+ enifed('ember-template-compiler/tests/plugins/transform-input-type-syntax-test', ['exports', 'ember-template-compiler/index'], function (exports, _emberTemplateCompilerIndex) {
63821
+ 'use strict';
63822
+
63823
+ QUnit.module('ember-template-compiler: input type syntax');
63824
+
63825
+ QUnit.test('Can compile an {{input}} helper that has a sub-expression value as its type', function () {
63826
+ expect(0);
63827
+
63828
+ _emberTemplateCompilerIndex.compile('{{input type=(if true \'password\' \'text\')}}');
63829
+ });
63830
+
63831
+ QUnit.test('Can compile an {{input}} helper with a string literal type', function () {
63832
+ expect(0);
63833
+
63834
+ _emberTemplateCompilerIndex.compile('{{input type=\'text\'}}');
63835
+ });
63836
+
63837
+ QUnit.test('Can compile an {{input}} helper with a type stored in a var', function () {
63838
+ expect(0);
63839
+
63840
+ _emberTemplateCompilerIndex.compile('{{input type=_type}}');
63841
+ });
63842
+ });
63843
+ enifed('ember-template-compiler/tests/plugins/transform-input-type-syntax-test.lint-test', ['exports'], function (exports) {
63844
+ 'use strict';
63845
+
63846
+ QUnit.module('ESLint | ember-template-compiler/tests/plugins/transform-input-type-syntax-test.js');
63847
+ QUnit.test('should pass ESLint', function (assert) {
63848
+ assert.expect(1);
63849
+ assert.ok(true, 'ember-template-compiler/tests/plugins/transform-input-type-syntax-test.js should pass ESLint\n\n');
63850
+ });
63851
+ });
63789
63852
  enifed('ember-template-compiler/tests/system/bootstrap-test', ['exports', 'ember-metal', 'ember-views', 'ember-glimmer', 'ember-template-compiler/system/bootstrap', 'internal-test-helpers'], function (exports, _emberMetal, _emberViews, _emberGlimmer, _emberTemplateCompilerSystemBootstrap, _internalTestHelpers) {
63790
63853
  'use strict';
63791
63854
 
data/dist/ember.debug.js CHANGED
@@ -6,10 +6,11 @@
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.12.0-beta.1
9
+ * @version 2.12.0-beta.2
10
10
  */
11
11
 
12
12
  var enifed, requireModule, Ember;
13
+ var mainContext = this; // Used in ember-environment/lib/global.js
13
14
 
14
15
  (function() {
15
16
  var isNode = typeof window === 'undefined' &&
@@ -1323,7 +1324,7 @@ enifed('container/container', ['exports', 'ember-utils', 'ember-environment', 'e
1323
1324
  lookupFactory: function (fullName, options) {
1324
1325
  _emberMetal.assert('fullName must be a proper full name', this.registry.validateFullName(fullName));
1325
1326
 
1326
- _emberMetal.deprecate('Using "_lookupFactory" is deprecated. Please use container.factoryFor instead.', !true, { id: 'container-lookupFactory', until: '2.13.0', url: 'TODO' });
1327
+ _emberMetal.deprecate('Using "_lookupFactory" is deprecated. Please use container.factoryFor instead.', !true, { id: 'container-lookupFactory', until: '2.13.0', url: 'http://emberjs.com/deprecations/v2.x/#toc_migrating-from-_lookupfactory-to-factoryfor' });
1327
1328
 
1328
1329
  return deprecatedFactoryFor(this, this.registry.normalize(fullName), options);
1329
1330
  }
@@ -8958,7 +8959,7 @@ enifed('ember-glimmer/components/text_area', ['exports', 'ember-glimmer/componen
8958
8959
  you only need to setup the action name to the event name property.
8959
8960
 
8960
8961
  ```handlebars
8961
- {{textarea focus-in="alertMessage"}}
8962
+ {{textarea focus-out="alertMessage"}}
8962
8963
  ```
8963
8964
 
8964
8965
  See more about [Text Support Actions](/api/classes/Ember.TextArea.html)
@@ -10391,9 +10392,11 @@ enifed('ember-glimmer/helpers/component', ['exports', 'ember-utils', 'ember-glim
10391
10392
  babelHelpers.classCallCheck(this, ClosureComponentReference);
10392
10393
 
10393
10394
  _CachedReference.call(this);
10394
- this.defRef = args.positional.at(0);
10395
+
10396
+ var firstArg = args.positional.at(0);
10397
+ this.defRef = firstArg;
10398
+ this.tag = firstArg.tag;
10395
10399
  this.env = env;
10396
- this.tag = args.positional.at(0).tag;
10397
10400
  this.symbolTable = symbolTable;
10398
10401
  this.args = args;
10399
10402
  this.lastDefinition = undefined;
@@ -10919,6 +10922,7 @@ enifed("ember-glimmer/helpers/hash", ["exports"], function (exports) {
10919
10922
  @for Ember.Templates.helpers
10920
10923
  @param {Object} options
10921
10924
  @return {Object} Hash
10925
+ @since 2.3.0
10922
10926
  @public
10923
10927
  */
10924
10928
 
@@ -11501,9 +11505,7 @@ enifed('ember-glimmer/helpers/unbound', ['exports', 'ember-metal', 'ember-glimme
11501
11505
  });
11502
11506
  enifed('ember-glimmer/index', ['exports', 'ember-glimmer/helpers/action', 'ember-glimmer/templates/root', 'ember-glimmer/syntax', 'ember-glimmer/template', 'ember-glimmer/components/checkbox', 'ember-glimmer/components/text_field', 'ember-glimmer/components/text_area', 'ember-glimmer/components/link-to', 'ember-glimmer/component', 'ember-glimmer/helper', 'ember-glimmer/environment', 'ember-glimmer/make-bound-helper', 'ember-glimmer/utils/string', 'ember-glimmer/renderer', 'ember-glimmer/template_registry', 'ember-glimmer/setup-registry', 'ember-glimmer/dom'], function (exports, _emberGlimmerHelpersAction, _emberGlimmerTemplatesRoot, _emberGlimmerSyntax, _emberGlimmerTemplate, _emberGlimmerComponentsCheckbox, _emberGlimmerComponentsText_field, _emberGlimmerComponentsText_area, _emberGlimmerComponentsLinkTo, _emberGlimmerComponent, _emberGlimmerHelper, _emberGlimmerEnvironment, _emberGlimmerMakeBoundHelper, _emberGlimmerUtilsString, _emberGlimmerRenderer, _emberGlimmerTemplate_registry, _emberGlimmerSetupRegistry, _emberGlimmerDom) {
11503
11507
  /**
11504
- [Glimmer](https://github.com/tildeio/glimmer) is a [Handlebars](http://handlebarsjs.com/)
11505
- compatible templating engine used by Ember.js.
11506
- Any valid Handlebars syntax is valid in an Ember template.
11508
+ [Glimmer](https://github.com/tildeio/glimmer) is a templating engine used by Ember.js that is compatible with a subset of the [Handlebars](http://handlebarsjs.com/) syntax.
11507
11509
 
11508
11510
  ### Showing a property
11509
11511
 
@@ -11511,15 +11513,13 @@ enifed('ember-glimmer/index', ['exports', 'ember-glimmer/helpers/action', 'ember
11511
11513
  the DOM) to a user. For example, given a component with the property "name",
11512
11514
  that component's template can use the name in several ways:
11513
11515
 
11514
- ```javascript
11515
- // app/components/person.js
11516
+ ```app/components/person.js
11516
11517
  export default Ember.Component.extend({
11517
11518
  name: 'Jill'
11518
11519
  });
11519
11520
  ```
11520
11521
 
11521
- ```handlebars
11522
- {{! app/components/person.hbs }}
11522
+ ```app/components/person.hbs
11523
11523
  {{name}}
11524
11524
  <div>{{name}}</div>
11525
11525
  <span data-name={{name}}></span>
@@ -11827,13 +11827,7 @@ enifed('ember-glimmer/modifiers/action', ['exports', 'ember-utils', 'ember-metal
11827
11827
  registerAction: function (actionState) {
11828
11828
  var actionId = actionState.actionId;
11829
11829
 
11830
- var actions = _emberViews.ActionManager.registeredActions[actionId];
11831
-
11832
- if (!actions) {
11833
- actions = _emberViews.ActionManager.registeredActions[actionId] = [];
11834
- }
11835
-
11836
- actions.push(actionState);
11830
+ _emberViews.ActionManager.registeredActions[actionId] = actionState;
11837
11831
 
11838
11832
  return actionId;
11839
11833
  },
@@ -11841,21 +11835,7 @@ enifed('ember-glimmer/modifiers/action', ['exports', 'ember-utils', 'ember-metal
11841
11835
  unregisterAction: function (actionState) {
11842
11836
  var actionId = actionState.actionId;
11843
11837
 
11844
- var actions = _emberViews.ActionManager.registeredActions[actionId];
11845
-
11846
- if (!actions) {
11847
- return;
11848
- }
11849
-
11850
- var index = actions.indexOf(actionState);
11851
-
11852
- if (index !== -1) {
11853
- actions.splice(index, 1);
11854
- }
11855
-
11856
- if (actions.length === 0) {
11857
- delete _emberViews.ActionManager.registeredActions[actionId];
11858
- }
11838
+ delete _emberViews.ActionManager.registeredActions[actionId];
11859
11839
  }
11860
11840
  };
11861
11841
 
@@ -12027,11 +12007,8 @@ enifed('ember-glimmer/modifiers/action', ['exports', 'ember-utils', 'ember-metal
12027
12007
  if (!actionNameRef[_emberGlimmerHelpersAction.INVOKE]) {
12028
12008
  actionState.actionName = actionNameRef.value();
12029
12009
  }
12030
- actionState.eventName = actionState.getEventName();
12031
12010
 
12032
- // Not sure if this is needed? If we mutate the actionState is that good enough?
12033
- ActionHelper.unregisterAction(actionState);
12034
- ActionHelper.registerAction(actionState);
12011
+ actionState.eventName = actionState.getEventName();
12035
12012
  };
12036
12013
 
12037
12014
  ActionModifierManager.prototype.getDestructor = function getDestructor(modifier) {
@@ -12939,7 +12916,9 @@ babelHelpers.classCallCheck(this, CurlyComponentManager);
12939
12916
  bucket.classRef = args.named.get('class');
12940
12917
  }
12941
12918
 
12942
- processComponentInitializationAssertions(component, props);
12919
+ _emberMetal.runInDebug(function () {
12920
+ processComponentInitializationAssertions(component, props);
12921
+ });
12943
12922
 
12944
12923
  if (environment.isInteractive && component.tagName !== '') {
12945
12924
  component.trigger('willRender');
@@ -13152,7 +13131,9 @@ babelHelpers.classCallCheck(this, TopComponentManager);
13152
13131
  }
13153
13132
  }
13154
13133
 
13155
- processComponentInitializationAssertions(component, {});
13134
+ _emberMetal.runInDebug(function () {
13135
+ processComponentInitializationAssertions(component, {});
13136
+ });
13156
13137
 
13157
13138
  return new ComponentStateBucket(environment, component, args, finalizer);
13158
13139
  };
@@ -21038,7 +21019,10 @@ enifed('ember-metal/mixin', ['exports', 'ember-utils', 'ember-metal/error', 'emb
21038
21019
  post: null
21039
21020
  });
21040
21021
 
21041
- let comment = Comment.create(post: somePost);
21022
+ let comment = Comment.create({
21023
+ post: somePost
21024
+ });
21025
+
21042
21026
  comment.edit(); // outputs 'starting to edit'
21043
21027
  ```
21044
21028
 
@@ -36612,7 +36596,7 @@ babelHelpers.classCallCheck(this, Class);
36612
36596
  }
36613
36597
  });
36614
36598
  let steve = Person.create({
36615
- name: "Steve"
36599
+ name: 'Steve'
36616
36600
  });
36617
36601
  // alerts 'Name is Steve'.
36618
36602
  ```
@@ -36930,8 +36914,8 @@ babelHelpers.classCallCheck(this, Class);
36930
36914
  nonMerged: 'superclass value of nonMerged'
36931
36915
  },
36932
36916
  mergedProperty: {
36933
- page: {replace: false},
36934
- limit: {replace: true}
36917
+ page: { replace: false },
36918
+ limit: { replace: true }
36935
36919
  }
36936
36920
  });
36937
36921
  const FooBar = Bar.extend({
@@ -36939,7 +36923,7 @@ babelHelpers.classCallCheck(this, Class);
36939
36923
  completelyNonMerged: 'subclass value of nonMerged'
36940
36924
  },
36941
36925
  mergedProperty: {
36942
- limit: {replace: false}
36926
+ limit: { replace: false }
36943
36927
  }
36944
36928
  });
36945
36929
  let fooBar = FooBar.create();
@@ -37083,9 +37067,9 @@ babelHelpers.classCallCheck(this, Class);
37083
37067
  }
37084
37068
  });
37085
37069
  let yehuda = Soldier.create({
37086
- name: "Yehuda Katz"
37070
+ name: 'Yehuda Katz'
37087
37071
  });
37088
- yehuda.say("Yes"); // alerts "Yehuda Katz says: Yes, sir!"
37072
+ yehuda.say('Yes'); // alerts "Yehuda Katz says: Yes, sir!"
37089
37073
  ```
37090
37074
  The `create()` on line #17 creates an *instance* of the `Soldier` class.
37091
37075
  The `extend()` on line #8 creates a *subclass* of `Person`. Any instance
@@ -37157,13 +37141,13 @@ babelHelpers.classCallCheck(this, Class);
37157
37141
  o = MyObject.create();
37158
37142
  o.get('name'); // 'an object'
37159
37143
  MyObject.reopen({
37160
- say(msg){
37144
+ say(msg) {
37161
37145
  console.log(msg);
37162
37146
  }
37163
- })
37147
+ });
37164
37148
  o2 = MyObject.create();
37165
- o2.say("hello"); // logs "hello"
37166
- o.say("goodbye"); // logs "goodbye"
37149
+ o2.say('hello'); // logs "hello"
37150
+ o.say('goodbye'); // logs "goodbye"
37167
37151
  ```
37168
37152
  To add functions and properties to the constructor itself,
37169
37153
  see `reopenClass`
@@ -37187,23 +37171,22 @@ babelHelpers.classCallCheck(this, Class);
37187
37171
  These are only available on the class and not on any instance of that class.
37188
37172
  ```javascript
37189
37173
  const Person = Ember.Object.extend({
37190
- name: "",
37174
+ name: '',
37191
37175
  sayHello() {
37192
- alert("Hello. My name is " + this.get('name'));
37176
+ alert(`Hello. My name is ${this.get('name')}`);
37193
37177
  }
37194
37178
  });
37195
37179
  Person.reopenClass({
37196
- species: "Homo sapiens",
37197
- createPerson(newPersonsName){
37198
- return Person.create({
37199
- name:newPersonsName
37200
- });
37180
+ species: 'Homo sapiens',
37181
+
37182
+ createPerson(name) {
37183
+ return Person.create({ name });
37201
37184
  }
37202
37185
  });
37203
37186
  let tom = Person.create({
37204
- name: "Tom Dale"
37187
+ name: 'Tom Dale'
37205
37188
  });
37206
- let yehuda = Person.createPerson("Yehuda Katz");
37189
+ let yehuda = Person.createPerson('Yehuda Katz');
37207
37190
  tom.sayHello(); // "Hello. My name is Tom Dale"
37208
37191
  yehuda.sayHello(); // "Hello. My name is Yehuda Katz"
37209
37192
  alert(Person.species); // "Homo sapiens"
@@ -37950,7 +37933,7 @@ enifed('ember-runtime/system/object_proxy', ['exports', 'ember-runtime/system/ob
37950
37933
  @class ObjectProxy
37951
37934
  @namespace Ember
37952
37935
  @extends Ember.Object
37953
- @extends Ember._ProxyMixin
37936
+ @uses Ember.ProxyMixin
37954
37937
  @public
37955
37938
  */
37956
37939
 
@@ -41657,6 +41640,43 @@ enifed('ember-views/mixins/view_support', ['exports', 'ember-utils', 'ember-meta
41657
41640
  @private
41658
41641
  */
41659
41642
  exports.default = _emberMetal.Mixin.create((_Mixin$create = {
41643
+ /**
41644
+ A list of properties of the view to apply as attributes. If the property
41645
+ is a string value, the value of that string will be applied as the value
41646
+ for an attribute of the property's name.
41647
+ The following example creates a tag like `<div priority="high" />`.
41648
+ ```javascript
41649
+ Ember.Component.extend({
41650
+ attributeBindings: ['priority'],
41651
+ priority: 'high'
41652
+ });
41653
+ ```
41654
+ If the value of the property is a Boolean, the attribute is treated as
41655
+ an HTML Boolean attribute. It will be present if the property is `true`
41656
+ and omitted if the property is `false`.
41657
+ The following example creates markup like `<div visible />`.
41658
+ ```javascript
41659
+ Ember.Component.extend({
41660
+ attributeBindings: ['visible'],
41661
+ visible: true
41662
+ });
41663
+ ```
41664
+ If you would prefer to use a custom value instead of the property name,
41665
+ you can create the same markup as the last example with a binding like
41666
+ this:
41667
+ ```javascript
41668
+ Ember.Component.extend({
41669
+ attributeBindings: ['isVisible:visible'],
41670
+ isVisible: true
41671
+ });
41672
+ ```
41673
+ This list of attributes is inherited from the component's superclasses,
41674
+ as well.
41675
+ @property attributeBindings
41676
+ @type Array
41677
+ @default []
41678
+ @public
41679
+ */
41660
41680
  concatenatedProperties: ['attributeBindings']
41661
41681
  }, _Mixin$create[_emberRuntimeSystemCore_object.POST_INIT] = function () {
41662
41682
  dispatchLifeCycleHook(this, 'didInitAttrs', undefined, this.attrs);
@@ -42300,43 +42320,23 @@ enifed('ember-views/system/event_dispatcher', ['exports', 'ember-utils', 'ember-
42300
42320
  });
42301
42321
 
42302
42322
  rootElement.on(event + '.ember', '[data-ember-action]', function (evt) {
42303
- var actionId = _emberViewsSystemJquery.default(evt.currentTarget).attr('data-ember-action');
42304
- var actions = _emberViewsSystemAction_manager.default.registeredActions[actionId];
42305
-
42306
- // In Glimmer2 this attribute is set to an empty string and an additional
42307
- // attribute it set for each action on a given element. In this case, the
42308
- // attributes need to be read so that a proper set of action handlers can
42309
- // be coalesced.
42310
- if (actionId === '') {
42311
- var attributes = evt.currentTarget.attributes;
42312
- var attributeCount = attributes.length;
42323
+ var attributes = evt.currentTarget.attributes;
42313
42324
 
42314
- actions = [];
42325
+ for (var i = 0; i < attributes.length; i++) {
42326
+ var attr = attributes.item(i);
42327
+ var attrName = attr.name;
42315
42328
 
42316
- for (var i = 0; i < attributeCount; i++) {
42317
- var attr = attributes.item(i);
42318
- var attrName = attr.name;
42329
+ if (attrName.lastIndexOf('data-ember-action-', 0) !== -1) {
42330
+ var action = _emberViewsSystemAction_manager.default.registeredActions[attr.value];
42319
42331
 
42320
- if (attrName.indexOf('data-ember-action-') === 0) {
42321
- actions = actions.concat(_emberViewsSystemAction_manager.default.registeredActions[attr.value]);
42332
+ // We have to check for action here since in some cases, jQuery will trigger
42333
+ // an event on `removeChild` (i.e. focusout) after we've already torn down the
42334
+ // action handlers for the view.
42335
+ if (action && action.eventName === eventName) {
42336
+ action.handler(evt);
42322
42337
  }
42323
42338
  }
42324
42339
  }
42325
-
42326
- // We have to check for actions here since in some cases, jQuery will trigger
42327
- // an event on `removeChild` (i.e. focusout) after we've already torn down the
42328
- // action handlers for the view.
42329
- if (!actions) {
42330
- return;
42331
- }
42332
-
42333
- for (var index = 0; index < actions.length; index++) {
42334
- var action = actions[index];
42335
-
42336
- if (action && action.eventName === eventName) {
42337
- return action.handler(evt);
42338
- }
42339
- }
42340
42340
  });
42341
42341
  },
42342
42342
 
@@ -42976,10 +42976,7 @@ enifed("ember-views/views/view", ["exports"], function (exports) {
42976
42976
  @namespace Ember
42977
42977
  @extends Ember.CoreView
42978
42978
  @deprecated See http://emberjs.com/deprecations/v1.x/#toc_ember-view
42979
- @uses Ember.ViewSupport
42980
- @uses Ember.ChildViewsSupport
42981
42979
  @uses Ember.ClassNamesSupport
42982
- @uses Ember.AttributeBindingsSupport
42983
42980
  @private
42984
42981
  */
42985
42982
  enifed("ember/features", ["exports"], function (exports) {
@@ -43528,7 +43525,7 @@ enifed('ember/index', ['exports', 'require', 'ember-environment', 'ember-utils',
43528
43525
  enifed("ember/version", ["exports"], function (exports) {
43529
43526
  "use strict";
43530
43527
 
43531
- exports.default = "2.12.0-beta.1";
43528
+ exports.default = "2.12.0-beta.2";
43532
43529
  });
43533
43530
  enifed('internal-test-helpers/apply-mixins', ['exports', 'ember-utils'], function (exports, _emberUtils) {
43534
43531
  'use strict';