language stringclasses 1
value | owner stringlengths 2 15 | repo stringlengths 2 21 | sha stringlengths 45 45 | message stringlengths 7 36.3k | path stringlengths 1 199 | patch stringlengths 15 102k | is_multipart bool 2
classes |
|---|---|---|---|---|---|---|---|
Other | emberjs | ember.js | 7ba9475a3a364a4083928ca4ac29859c73130cf5.json | Remove trailing whitespace | packages/ember-old-router/lib/application/system/application.js | @@ -254,7 +254,7 @@ Ember.Application = Ember.Namespace.extend(
/**
Should the application initialize itself after it's created. You can
- set this to `false` if you'd like to choose when to initialize your
+ set this to `false` if you'd like to choose when to initialize your
application. This def... | true |
Other | emberjs | ember.js | 7ba9475a3a364a4083928ca4ac29859c73130cf5.json | Remove trailing whitespace | packages/ember-old-router/lib/router.js | @@ -219,7 +219,7 @@ var merge = function(original, hash) {
first argument and a hash of the URL's dynamic segments and values as its
second argument.
- The following route structure when loaded with the URL
+ The following route structure when loaded with the URL
"#/fixed/thefirstvalue/anotherFixed/thesec... | true |
Other | emberjs | ember.js | 7ba9475a3a364a4083928ca4ac29859c73130cf5.json | Remove trailing whitespace | packages/ember-runtime/lib/mixins/array.js | @@ -313,9 +313,9 @@ Ember.Array = Ember.Mixin.create(Ember.Enumerable, /** @scope Ember.Array.protot
@method arrayContentWillChange
@param {Number} startIdx The starting index in the array that will change.
- @param {Number} removeAmt The number of items that will be removed. If you
+ @param {Number}... | true |
Other | emberjs | ember.js | 7ba9475a3a364a4083928ca4ac29859c73130cf5.json | Remove trailing whitespace | packages/ember-runtime/lib/mixins/enumerable.js | @@ -103,7 +103,7 @@ Ember.Enumerable = Ember.Mixin.create({
@method nextObject
@param {Number} index the current index of the iteration
- @param {Object} previousObject the value returned by the last call to
+ @param {Object} previousObject the value returned by the last call to
`nextObject`.
... | true |
Other | emberjs | ember.js | 7ba9475a3a364a4083928ca4ac29859c73130cf5.json | Remove trailing whitespace | packages/ember-runtime/lib/mixins/mutable_array.js | @@ -45,11 +45,11 @@ Ember.MutableArray = Ember.Mixin.create(Ember.Array, Ember.MutableEnumerable,
passed array. You should also call `this.enumerableContentDidChange()`
@method replace
- @param {Number} idx Starting index in the array to replace. If
+ @param {Number} idx Starting index in the array t... | true |
Other | emberjs | ember.js | 7ba9475a3a364a4083928ca4ac29859c73130cf5.json | Remove trailing whitespace | packages/ember-runtime/lib/system/core_object.js | @@ -236,14 +236,14 @@ CoreObject.PrototypeMixin = Mixin.create({
view.get('classNames'); // ['ember-view', 'bar', 'foo', 'baz']
```
Adding a single property that is not an array will just add it in the array:
-
+
```javascript
var view = App.FooBarView.create({
classNames: 'baz'
... | true |
Other | emberjs | ember.js | 7ba9475a3a364a4083928ca4ac29859c73130cf5.json | Remove trailing whitespace | packages/ember-runtime/tests/suites/enumerable/reject.js | @@ -25,7 +25,7 @@ suite.test('should be the inverse of filter', function() {
rejected = obj.reject(isEven);
deepEqual(filtered, [2,4], 'filtered evens');
- deepEqual(rejected, [1,3], 'rejected evens');
+ deepEqual(rejected, [1,3], 'rejected evens');
});
// ................................................... | true |
Other | emberjs | ember.js | 7ba9475a3a364a4083928ca4ac29859c73130cf5.json | Remove trailing whitespace | packages/ember-views/lib/views/collection_view.js | @@ -37,7 +37,7 @@ var get = Ember.get, set = Ember.set, fmt = Ember.String.fmt;
Given an empty `<body>` and the following code:
- ```javascript
+ ```javascript
someItemsView = Ember.CollectionView.create({
classNames: ['a-collection'],
content: ['A','B','C'], | true |
Other | emberjs | ember.js | 7ba9475a3a364a4083928ca4ac29859c73130cf5.json | Remove trailing whitespace | packages/ember-views/lib/views/view.js | @@ -731,15 +731,15 @@ class:
* `mouseEnter`
* `mouseLeave`
- Form events:
+ Form events:
* `submit`
* `change`
* `focusIn`
* `focusOut`
* `input`
- HTML5 drag and drop events:
+ HTML5 drag and drop events:
* `dragStart`
* `drag`
@@ -1478,7 +1478,7 @@ Ember.View = Ember.CoreView.... | true |
Other | emberjs | ember.js | 2c57dcf26baade027b78a08309b50db97a2feb14.json | Remove tab indentation | packages/rsvp/lib/main.js | @@ -245,35 +245,35 @@ define("rsvp",
}
function all(promises) {
- var i, results = [];
- var allPromise = new Promise();
- var remaining = promises.length;
+ var i, results = [];
+ var allPromise = new Promise();
+ var remaining = promises.length;
if (remaining === 0) {
... | false |
Other | emberjs | ember.js | 531db2ef0b3b62315ba322fa69d0257ff34c9193.json | Improve Ember.Array slice implementation
Add support for negative index arguments. | packages/ember-runtime/lib/mixins/array.js | @@ -160,6 +160,10 @@ Ember.Array = Ember.Mixin.create(Ember.Enumerable, /** @scope Ember.Array.protot
var length = get(this, 'length') ;
if (none(beginIndex)) beginIndex = 0 ;
if (none(endIndex) || (endIndex > length)) endIndex = length ;
+
+ if (beginIndex < 0) beginIndex = length + beginIndex;
+ ... | true |
Other | emberjs | ember.js | 531db2ef0b3b62315ba322fa69d0257ff34c9193.json | Improve Ember.Array slice implementation
Add support for negative index arguments. | packages/ember-runtime/tests/mixins/array_test.js | @@ -37,12 +37,7 @@ var TestArray = Ember.Object.extend(Ember.Array, {
length: Ember.computed(function() {
return this._content.length;
- }),
-
- slice: function() {
- return this._content.slice();
- }
-
+ })
});
@@ -74,6 +69,24 @@ test("the return value of slice has Ember.Array applied", function(... | true |
Other | emberjs | ember.js | ffa4493782813ed92d06ea5ce0bed3c14df5ec5e.json | Fix ArrayProxy arrangedObject handling - Fixes #2120, #2138 | packages/ember-runtime/lib/system/array_proxy.js | @@ -6,6 +6,8 @@ require('ember-runtime/system/object');
@submodule ember-runtime
*/
+var OUT_OF_RANGE_EXCEPTION = "Index out of range";
+var EMPTY = [];
var get = Ember.get, set = Ember.set;
@@ -211,12 +213,100 @@ Ember.ArrayProxy = Ember.Object.extend(Ember.MutableArray,
// No dependencies since Enumerab... | true |
Other | emberjs | ember.js | ffa4493782813ed92d06ea5ce0bed3c14df5ec5e.json | Fix ArrayProxy arrangedObject handling - Fixes #2120, #2138 | packages/ember-runtime/tests/system/array_proxy/arranged_content_test.js | @@ -0,0 +1,297 @@
+var array;
+
+module("Ember.ArrayProxy - arrangedContent", {
+ setup: function() {
+ Ember.run(function() {
+ array = Ember.ArrayProxy.createWithMixins({
+ content: Ember.A([1,2,4,5]),
+ arrangedContent: Ember.computed(function() {
+ var content = this.get('content');
... | true |
Other | emberjs | ember.js | 7357a1f1d1513cda1326ff60a4d0dc629907d154.json | Fix failing test
This package couldn't be required from test. | packages/ember-runtime/tests/core/is_empty_test.js | @@ -1,4 +1,3 @@
-require('ember-metal/core');
module("Ember.isEmpty");
test("Ember.isEmpty", function() { | false |
Other | emberjs | ember.js | d232a68ead674ce5a507a5ab6e86d8499a5ba3c1.json | extract Ember.isEmpty into ember-metal
Ember computed.empty should always have identical semantics | packages/ember-metal/lib/computed.js | @@ -437,7 +437,7 @@ Ember.computed.not = function(dependentKey) {
Ember.computed.empty = function(dependentKey) {
return Ember.computed(dependentKey, function(key) {
var val = get(this, dependentKey);
- return val === undefined || val === null || val === '' || (Ember.isArray(val) && get(val, 'length') === 0... | true |
Other | emberjs | ember.js | d232a68ead674ce5a507a5ab6e86d8499a5ba3c1.json | extract Ember.isEmpty into ember-metal
Ember computed.empty should always have identical semantics | packages/ember-metal/lib/core.js | @@ -228,3 +228,30 @@ Ember.merge = function(original, updates) {
original[prop] = updates[prop];
}
};
+/**
+ Verifies that a value is `null` or an empty string, empty array,
+ or empty function.
+
+ Constrains the rules on `Ember.isNone` by returning false for empty
+ string and empty arrays.
+
+ ```javas... | true |
Other | emberjs | ember.js | d232a68ead674ce5a507a5ab6e86d8499a5ba3c1.json | extract Ember.isEmpty into ember-metal
Ember computed.empty should always have identical semantics | packages/ember-metal/tests/core/is_empty_test.js | @@ -2,8 +2,7 @@ module("Ember.isEmpty");
test("Ember.isEmpty", function() {
var string = "string", fn = function() {},
- object = {length: 0},
- arrayProxy = Ember.ArrayProxy.create({ content: Ember.A([]) });
+ object = {length: 0};
equal(true, Ember.isEmpty(null), "for null");
equal(... | true |
Other | emberjs | ember.js | d232a68ead674ce5a507a5ab6e86d8499a5ba3c1.json | extract Ember.isEmpty into ember-metal
Ember computed.empty should always have identical semantics | packages/ember-runtime/lib/core.js | @@ -106,34 +106,6 @@ Ember.isNone = function(obj) {
};
Ember.none = Ember.deprecateFunc("Ember.none is deprecated. Please use Ember.isNone instead.", Ember.isNone);
-/**
- Verifies that a value is `null` or an empty string, empty array,
- or empty function.
-
- Constrains the rules on `Ember.isNone` by returning... | true |
Other | emberjs | ember.js | d232a68ead674ce5a507a5ab6e86d8499a5ba3c1.json | extract Ember.isEmpty into ember-metal
Ember computed.empty should always have identical semantics | packages/ember-runtime/tests/core/is_empty_test.js | @@ -0,0 +1,8 @@
+require('ember-metal/core');
+module("Ember.isEmpty");
+
+test("Ember.isEmpty", function() {
+ var arrayProxy = Ember.ArrayProxy.create({ content: Ember.A([]) });
+
+ equal(true, Ember.isEmpty(arrayProxy), "for an ArrayProxy that has empty content");
+}); | true |
Other | emberjs | ember.js | 4f340e6c73032af032d068ebd5bf7cce95d96732.json | Remove unnecessary '#'
'#' is unnecessary for putting return value. | packages/ember-runtime/lib/system/core_object.js | @@ -342,7 +342,7 @@ CoreObject.PrototypeMixin = Mixin.create({
}
});
teacher = App.Teacher.create()
- teacher.toString(); // #=> "<App.Teacher:ember1026:Tom Dale>"
+ teacher.toString(); //=> "<App.Teacher:ember1026:Tom Dale>"
@method toString
@return {String} strin... | false |
Other | emberjs | ember.js | 0c77f3643bb9877b427d260a76f649bb675e033e.json | Remove unused variable
- `meta` is not used in `Ember.Array`.
- `defineProperty` is not used in `Ember.Observable`. | packages/ember-runtime/lib/mixins/array.js | @@ -9,7 +9,7 @@ require('ember-runtime/mixins/enumerable');
// HELPERS
//
-var get = Ember.get, set = Ember.set, meta = Ember.meta, map = Ember.EnumerableUtils.map, cacheFor = Ember.cacheFor;
+var get = Ember.get, set = Ember.set, map = Ember.EnumerableUtils.map, cacheFor = Ember.cacheFor;
function none(obj) { r... | true |
Other | emberjs | ember.js | 0c77f3643bb9877b427d260a76f649bb675e033e.json | Remove unused variable
- `meta` is not used in `Ember.Array`.
- `defineProperty` is not used in `Ember.Observable`. | packages/ember-runtime/lib/mixins/observable.js | @@ -3,7 +3,7 @@
@submodule ember-runtime
*/
-var get = Ember.get, set = Ember.set, defineProperty = Ember.defineProperty;
+var get = Ember.get, set = Ember.set;
/**
## Overview | true |
Other | emberjs | ember.js | f3d0fd3e0d6a3dc75d3e5e14119f295d7ced488a.json | Fix typo in Ember.String#classify doc | packages/ember-runtime/lib/system/string.js | @@ -158,7 +158,7 @@ Ember.String = {
},
/**
- Returns the lowerCaseCamel form of a string.
+ Returns the lowerCamelCase form of a string.
```javascript
'innerHTML'.camelize(); // 'innerHTML' | false |
Other | emberjs | ember.js | aedbf8b2092fb03e1e71105054ce3c5a010e7cd2.json | document the init function for Ember.CoreObject | packages/ember-runtime/lib/system/core_object.js | @@ -161,6 +161,45 @@ CoreObject.PrototypeMixin = Mixin.create({
isInstance: true,
+ /**
+ An overridable method called when objects are instantiated. By default,
+ does nothing unless it is overridden during class definition.
+
+ Example:
+
+ ```javascript
+ App.Person = Ember.Object.extend({
+ ... | false |
Other | emberjs | ember.js | 4c606ac2dc11bb68d28c5e4c10543811e0f89617.json | check document before shy test | packages/ember-views/lib/system/utils.js | @@ -8,7 +8,8 @@
// Internet Explorer prior to 9 does not allow setting innerHTML if the first element
// is a "zero-scope" element. This problem can be worked around by making
// the first node an invisible text node. We, like Modernizr, use ­
-var needsShy = (function(){
+
+var needsShy = this.document && (func... | true |
Other | emberjs | ember.js | 4c606ac2dc11bb68d28c5e4c10543811e0f89617.json | check document before shy test | packages/metamorph/lib/main.js | @@ -9,15 +9,15 @@ define("metamorph",
var K = function(){},
guid = 0,
- document = window.document,
+ document = this.document,
// Feature-detect the W3C range API, the extended check is for IE9 which only partially supports ranges
- supportsRange = ('createRange' in docu... | true |
Other | emberjs | ember.js | 68676afbbe8ab0f9169b06c5edf033c553c0e501.json | check jQuery before extending it | packages/ember-views/lib/system/jquery_ext.js | @@ -2,12 +2,13 @@
@module ember
@submodule ember-views
*/
+if (Ember.$) {
+ // http://www.whatwg.org/specs/web-apps/current-work/multipage/dnd.html#dndevents
+ var dragEvents = Ember.String.w('dragstart drag dragenter dragleave dragover drop dragend');
-// http://www.whatwg.org/specs/web-apps/current-work/multip... | false |
Other | emberjs | ember.js | 2f6f06e5d1b7ab9550b060f9596a0b3d515b351e.json | remove unused function | packages/ember-runtime/tests/legacy_1x/system/object/base_test.js | @@ -26,14 +26,6 @@ var obj, obj1, don, don1 ; // global variables
var get = Ember.get, set = Ember.set;
-function inArray(item, array) {
- var len = array.length, idx;
- for (idx=0; idx<len; idx++) {
- if (array[idx] === item) { return idx; }
- }
- return -1;
-}
-
module("A new Ember.Object instance", {
... | false |
Other | emberjs | ember.js | 526f588870e5833a70c4133b4c13ed94fe751a9f.json | Add support for global mutation listeners | packages/ember-handlebars/lib/views/metamorph_view.js | @@ -11,22 +11,30 @@ require("ember-views/views/view");
var set = Ember.set, get = Ember.get;
var Metamorph = requireModule('metamorph');
+function notifyMutationListeners() {
+ Ember.run.once(Ember.View, 'notifyMutationListeners');
+}
+
// DOMManager should just abstract dom manipulation between jquery and metamo... | true |
Other | emberjs | ember.js | 526f588870e5833a70c4133b4c13ed94fe751a9f.json | Add support for global mutation listeners | packages/ember-handlebars/tests/controls/checkbox_test.js | @@ -73,7 +73,7 @@ test("checked property mirrors input value", function() {
equal(checkboxView.$().prop('checked'), true, "changing the value property changes the DOM");
- checkboxView.remove();
+ Ember.run(function() { checkboxView.remove(); });
Ember.run(function() { checkboxView.append(); });
equal(... | true |
Other | emberjs | ember.js | 526f588870e5833a70c4133b4c13ed94fe751a9f.json | Add support for global mutation listeners | packages/ember-routing/lib/helpers/shared.js | @@ -8,13 +8,15 @@ Ember.onLoad('Ember.Handlebars', function() {
function resolveParams(context, params, options) {
var resolved = handlebarsResolve(context, params, options);
return map.call(resolved, unwrap);
- }
- function unwrap(object) {
- if (Ember.ControllerMixin.detect(object)) {
- retur... | true |
Other | emberjs | ember.js | 526f588870e5833a70c4133b4c13ed94fe751a9f.json | Add support for global mutation listeners | packages/ember-views/lib/views/view.js | @@ -2187,17 +2187,24 @@ Ember.View = Ember.CoreView.extend(
// once the view has been inserted into the DOM, legal manipulations
// are done on the DOM element.
+function notifyMutationListeners() {
+ Ember.run.once(Ember.View, 'notifyMutationListeners');
+}
+
var DOMManager = {
prepend: function(view, htm... | true |
Other | emberjs | ember.js | 526f588870e5833a70c4133b4c13ed94fe751a9f.json | Add support for global mutation listeners | packages/ember-views/tests/views/view/is_visible_test.js | @@ -51,7 +51,9 @@ test("should hide views when isVisible is false", function() {
set(view, 'isVisible', true);
ok(view.$().is(':visible'), "the view is visible");
- view.remove();
+ Ember.run(function() {
+ view.remove();
+ });
});
test("should hide element if isVisible is false before element is crea... | true |
Other | emberjs | ember.js | 526f588870e5833a70c4133b4c13ed94fe751a9f.json | Add support for global mutation listeners | packages/ember-views/tests/views/view/remove_test.js | @@ -89,7 +89,10 @@ test("removes view from parent view", function() {
ok(parentView.$('div').length, "precond - has a child DOM element");
- child.removeFromParent();
+ Ember.run(function() {
+ child.removeFromParent();
+ });
+
ok(!get(child, 'parentView'), 'no longer has parentView');
ok(indexOf(get... | true |
Other | emberjs | ember.js | d433d59690eac9a368432e01324d6424a3480d95.json | expose RSVP on the ember namespace | packages/ember-runtime/lib/ext.js | @@ -1,2 +1,3 @@
+require('ember-runtime/ext/ember');
require('ember-runtime/ext/string');
require('ember-runtime/ext/function'); | true |
Other | emberjs | ember.js | d433d59690eac9a368432e01324d6424a3480d95.json | expose RSVP on the ember namespace | packages/ember-runtime/lib/ext/ember.js | @@ -0,0 +1,8 @@
+/**
+ Expose RSVP implementation
+
+ @class RSVP
+ @namespace Ember
+ @constructor
+*/
+Ember.RSVP = requireModule('rsvp'); | true |
Other | emberjs | ember.js | eedefb4183249eaf8c29d8ebb6dce78113bccc52.json | Reuse path variable | packages/ember-routing/lib/location/hash_location.js | @@ -67,7 +67,7 @@ Ember.HashLocation = Ember.Object.extend({
set(self, 'lastSetURL', null);
- callback(location.hash.substr(1));
+ callback(path);
});
});
}, | false |
Other | emberjs | ember.js | 532dec210363bc7f412eb2ac5bef9e8a9adc52fd.json | Normalize controller lookup, fix #2025 | packages/container/lib/main.js | @@ -76,7 +76,6 @@ define("container",
register: function(type, name, factory, options) {
var fullName;
-
if (type.indexOf(':') !== -1){
options = factory;
factory = name;
@@ -86,14 +85,20 @@ define("container",
fullName = type + ":" + name;
}
- ... | true |
Other | emberjs | ember.js | 532dec210363bc7f412eb2ac5bef9e8a9adc52fd.json | Normalize controller lookup, fix #2025 | packages/container/tests/container_test.js | @@ -225,6 +225,20 @@ test("The container respect the resolver hook for `has`", function() {
ok(container.has('controller:post'), "the `has` method uses the resolver hook");
});
+test("The container normalizes names before resolving", function() {
+ var container = new Container();
+ var PostController = factory... | true |
Other | emberjs | ember.js | 532dec210363bc7f412eb2ac5bef9e8a9adc52fd.json | Normalize controller lookup, fix #2025 | packages/ember-application/lib/system/application.js | @@ -594,6 +594,7 @@ Ember.Application.reopenClass({
Ember.Container.defaultContainer = Ember.Container.defaultContainer || container;
container.set = Ember.set;
+ container.normalize = normalize;
container.resolver = resolverFor(namespace);
container.optionsForType('view', { singleton: false })... | true |
Other | emberjs | ember.js | 532dec210363bc7f412eb2ac5bef9e8a9adc52fd.json | Normalize controller lookup, fix #2025 | packages/ember-application/tests/system/application_test.js | @@ -233,15 +233,17 @@ module("Ember.Application Depedency Injection", {
application = Ember.Application.create().initialize();
});
- application.Person = Ember.Object.extend({});
- application.Orange = Ember.Object.extend({});
- application.Email = Ember.Object.extend({});
- application.User ... | true |
Other | emberjs | ember.js | 532dec210363bc7f412eb2ac5bef9e8a9adc52fd.json | Normalize controller lookup, fix #2025 | packages/ember-application/tests/system/controller_test.js | @@ -26,4 +26,3 @@ test("If a controller specifies an unavailable dependency, it raises", function(
container.lookup('controller:post');
}, /controller:posts/);
});
- | true |
Other | emberjs | ember.js | 17b2dcda78c5336ac2bc958a3a1b4c82446e60bb.json | Move resolution logic to shared file | packages/ember-routing/lib/helpers.js | @@ -1,3 +1,4 @@
+require('ember-routing/helpers/shared');
require('ember-routing/helpers/link_to');
require('ember-routing/helpers/outlet');
require('ember-routing/helpers/render'); | true |
Other | emberjs | ember.js | 17b2dcda78c5336ac2bc958a3a1b4c82446e60bb.json | Move resolution logic to shared file | packages/ember-routing/lib/helpers/action.js | @@ -9,28 +9,14 @@ require('ember-handlebars/helpers/view');
Ember.onLoad('Ember.Handlebars', function(Handlebars) {
- var resolveParams = Ember.Handlebars.resolveParams,
+ var resolveParams = Ember.Router.resolveParams,
isSimpleClick = Ember.ViewUtils.isSimpleClick;
var EmberHandlebars = Ember.Handle... | true |
Other | emberjs | ember.js | 17b2dcda78c5336ac2bc958a3a1b4c82446e60bb.json | Move resolution logic to shared file | packages/ember-routing/lib/helpers/shared.js | @@ -0,0 +1,22 @@
+require('ember-routing/system/router');
+
+Ember.onLoad('Ember.Handlebars', function() {
+ var handlebarsResolve = Ember.Handlebars.resolveParams,
+ map = Ember.ArrayPolyfills.map,
+ get = Ember.get;
+
+ function resolveParams(context, params, options) {
+ var resolved = handlebarsResol... | true |
Other | emberjs | ember.js | 5f43e5bee2ac922240ad4d2c4bd0e218777e784e.json | Fix typo in _resetSubControllers | packages/ember-runtime/lib/controllers/array_controller.js | @@ -207,7 +207,7 @@ Ember.ArrayController = Ember.ArrayProxy.extend(Ember.ControllerMixin,
var subControllers = get(this, '_subControllers');
forEach(subControllers, function(subController) {
- if (subControllers) { subController.destroy(); }
+ if (subController) { subController.destroy(); }
... | false |
Other | emberjs | ember.js | 37d7f49150008193d8ad5b14c3916b89ddc14e83.json | Fix broken link in code comment | packages/ember-old-router/lib/application/system/application.js | @@ -93,7 +93,7 @@ var get = Ember.get, set = Ember.set;
To learn more about the advantages of event delegation and the Ember view
layer, and a list of the event listeners that are setup by default, visit the
- [Ember View Layer guide](http://emberjs.com/guides/view_layer#toc_event-delegation).
+ [Ember View L... | false |
Other | emberjs | ember.js | 47ff6316a2a00e8ddd375f7c9a009797b051be43.json | Fix missing reuturn in CollectionView docs
`createChildView` has to return the call to `this._super`, otherwise
everything breaks. | packages/ember-views/lib/views/collection_view.js | @@ -110,7 +110,7 @@ var get = Ember.get, set = Ember.set, fmt = Ember.String.fmt;
} else {
viewClass = App.SongView;
}
- this._super(viewClass, attrs);
+ return this._super(viewClass, attrs);
}
});
``` | false |
Other | emberjs | ember.js | 5e20dcc7248a5cfd31414415ceaf9db61533dea2.json | Add missing arguments in code comment | packages/ember-metal/lib/events.js | @@ -109,6 +109,7 @@ function actionsDiff(obj, eventName, otherActions) {
@param {String} eventName
@param {Object|Function} targetOrMethod A target object or a function
@param {Function|String} method A function or the name of a function to be called on `target`
+ @param {Boolean} once A flag whether a functi... | false |
Other | emberjs | ember.js | c19dcf8009961977c7c6d0305b84542e9ae65393.json | Fix code comment
- Add missing arguments
- Fix order of type and argument name
- Fix argument name | packages/ember-metal/lib/accessors.js | @@ -290,7 +290,7 @@ Ember.setPath = Ember.deprecateFunc('setPath is deprecated since set now support
@method trySet
@for Ember
@param {Object} obj The object to modify.
- @param {String} keyName The property key to set
+ @param {String} path The property path to set
@param {Object} value The value to set
... | true |
Other | emberjs | ember.js | c19dcf8009961977c7c6d0305b84542e9ae65393.json | Fix code comment
- Add missing arguments
- Fix order of type and argument name
- Fix argument name | packages/ember-metal/lib/binding.js | @@ -78,7 +78,7 @@ Binding.prototype = {
`get()` - see that method for more information.
@method from
- @param {String} propertyPath the property path to connect to
+ @param {String} path the property path to connect to
@return {Ember.Binding} `this`
*/
from: function(path) {
@@ -96,7 +96,7 ... | true |
Other | emberjs | ember.js | c19dcf8009961977c7c6d0305b84542e9ae65393.json | Fix code comment
- Add missing arguments
- Fix order of type and argument name
- Fix argument name | packages/ember-metal/lib/map.js | @@ -136,8 +136,8 @@ OrderedSet.prototype = {
/**
@method forEach
- @param {Function} function
- @param target
+ @param {Function} fn
+ @param self
*/
forEach: function(fn, self) {
// allow mutation during iteration | true |
Other | emberjs | ember.js | c19dcf8009961977c7c6d0305b84542e9ae65393.json | Fix code comment
- Add missing arguments
- Fix order of type and argument name
- Fix argument name | packages/ember-metal/lib/utils.js | @@ -80,7 +80,7 @@ Ember.generateGuid = function generateGuid(obj, prefix) {
@method guidFor
@for Ember
- @param obj {Object} any object, string, number, Element, or primitive
+ @param {Object} obj any object, string, number, Element, or primitive
@return {String} the unique guid for this instance.
*/
Emb... | true |
Other | emberjs | ember.js | c19dcf8009961977c7c6d0305b84542e9ae65393.json | Fix code comment
- Add missing arguments
- Fix order of type and argument name
- Fix argument name | packages/ember-runtime/lib/core.js | @@ -63,7 +63,7 @@ var toString = Object.prototype.toString;
@method typeOf
@for Ember
- @param item {Object} the item to check
+ @param {Object} item the item to check
@return {String} the type
*/
Ember.typeOf = function(item) {
@@ -297,7 +297,7 @@ function _copy(obj, deep, seen, copies) {
@method c... | true |
Other | emberjs | ember.js | c19dcf8009961977c7c6d0305b84542e9ae65393.json | Fix code comment
- Add missing arguments
- Fix order of type and argument name
- Fix argument name | packages/ember-runtime/lib/mixins/array.js | @@ -257,7 +257,7 @@ Ember.Array = Ember.Mixin.create(Ember.Enumerable, /** @scope Ember.Array.protot
@method addArrayObserver
@param {Object} target The observer object.
@param {Hash} opts Optional hash of configuration options including
- `willChange`, `didChange`, and a `context` option.
+ `w... | true |
Other | emberjs | ember.js | c19dcf8009961977c7c6d0305b84542e9ae65393.json | Fix code comment
- Add missing arguments
- Fix order of type and argument name
- Fix argument name | packages/ember-runtime/lib/mixins/copyable.js | @@ -33,7 +33,7 @@ Ember.Copyable = Ember.Mixin.create(
an exception.
@method copy
- @param deep {Boolean} if `true`, a deep copy of the object should be made
+ @param {Boolean} deep if `true`, a deep copy of the object should be made
@return {Object} copy of receiver
*/
copy: Ember.required... | true |
Other | emberjs | ember.js | c19dcf8009961977c7c6d0305b84542e9ae65393.json | Fix code comment
- Add missing arguments
- Fix order of type and argument name
- Fix argument name | packages/ember-runtime/lib/mixins/enumerable.js | @@ -730,8 +730,8 @@ Ember.Enumerable = Ember.Mixin.create(
mixin.
@method addEnumerableObserver
- @param target {Object}
- @param opts {Hash}
+ @param {Object} target
+ @param {Hash} opts
*/
addEnumerableObserver: function(target, opts) {
var willChange = (opts && opts.willChange) || ... | true |
Other | emberjs | ember.js | c19dcf8009961977c7c6d0305b84542e9ae65393.json | Fix code comment
- Add missing arguments
- Fix order of type and argument name
- Fix argument name | packages/ember-runtime/lib/mixins/observable.js | @@ -108,7 +108,7 @@ Ember.Observable = Ember.Mixin.create(/** @scope Ember.Observable.prototype */ {
not defined upfront.
@method get
- @param {String} key The property to retrieve
+ @param {String} keyName The property to retrieve
@return {Object} The property value or undefined.
*/
get: f... | true |
Other | emberjs | ember.js | 1de089bdbbff3dde332034e4e7c9d5fa4ac1569b.json | Remove unused variables | packages/container/lib/main.js | @@ -2,12 +2,6 @@ define("container",
[],
function() {
- var objectCreate = Object.create || function(parent) {
- function F() {}
- F.prototype = parent;
- return new F();
- };
-
function InheritingDict(parent) {
this.parent = parent;
this.dict = {}; | true |
Other | emberjs | ember.js | 1de089bdbbff3dde332034e4e7c9d5fa4ac1569b.json | Remove unused variables | packages/ember-handlebars/lib/loader.js | @@ -30,8 +30,7 @@ Ember.Handlebars.bootstrap = function(ctx) {
Ember.$(selectors, ctx)
.each(function() {
// Get a reference to the script tag
- var script = Ember.$(this),
- type = script.attr('type');
+ var script = Ember.$(this);
var compile = (script.attr('type') === 'text/x-raw-h... | true |
Other | emberjs | ember.js | 778f5a069a4027a85ab659645edca592d857732b.json | Remove reference to therubyracer from README.md
therubyracer doesn't currently work to build ember.js, and this patch removes an instruction to use it. | README.md | @@ -100,8 +100,9 @@ NOTE: Due to the rename, these instructions may be in flux
builds of Ember.js
If you are building under Linux, you will need a JavaScript runtime for
-minification. You can either install nodejs or `gem install
-therubyracer`.
+minification, for which we recommend installing nodejs. Alterna... | false |
Other | emberjs | ember.js | c87cc34c015753904e96c35143c37f4d2fc63054.json | Fix broken link | packages/ember-application/lib/system/application.js | @@ -96,7 +96,7 @@ var get = Ember.get, set = Ember.set,
To learn more about the advantages of event delegation and the Ember view
layer, and a list of the event listeners that are setup by default, visit the
- [Ember View Layer guide](http://emberjs.com/guides/view_layer#toc_event-delegation).
+ [Ember View L... | false |
Other | emberjs | ember.js | f78d6a1b4986b8d846d78b21fe7a8aa844ed83d5.json | Add support for /-separated namespace lookup
The default resolver hook now supports names
like "controller:foo/bar", which resolves to
Foo.BarController, assuming Foo is a registered
namespace. | packages/ember-application/lib/system/application.js | @@ -5,6 +5,7 @@
var get = Ember.get, set = Ember.set,
classify = Ember.String.classify,
+ capitalize = Ember.String.capitalize,
decamelize = Ember.String.decamelize;
/**
@@ -644,7 +645,8 @@ Ember.Application.reopenClass({
function resolverFor(namespace) {
return function(fullName) {
var name... | true |
Other | emberjs | ember.js | f78d6a1b4986b8d846d78b21fe7a8aa844ed83d5.json | Add support for /-separated namespace lookup
The default resolver hook now supports names
like "controller:foo/bar", which resolves to
Foo.BarController, assuming Foo is a registered
namespace. | packages/ember-application/tests/system/application_test.js | @@ -217,7 +217,8 @@ test("Minimal Application initialized with just an application template", functi
equal(trim(Ember.$('#qunit-fixture').text()), 'Hello World');
});
-var locator;
+var locator, originalLookup = Ember.lookup, lookup;
+
module("Ember.Application Depedency Injection", {
setup: function(){
... | true |
Other | emberjs | ember.js | 8e13610d210cb024894656cce57e06a48ed96944.json | Hide {{control}} behind a flag - Fixes #2073 | packages/ember-routing/lib/helpers/control.js | @@ -3,68 +3,72 @@
@submodule ember-routing
*/
+if (Ember.ENV.EXPERIMENTAL_CONTROL_HELPER) {
+ var get = Ember.get, set = Ember.set;
-var get = Ember.get, set = Ember.set;
+ /**
+ The control helper is currently under development and is considered experimental.
+ To enable it, set `ENV.EXPERIMENTAL_CONTROL... | true |
Other | emberjs | ember.js | 8e13610d210cb024894656cce57e06a48ed96944.json | Hide {{control}} behind a flag - Fixes #2073 | packages/ember-routing/tests/helpers/control_test.js | @@ -1,22 +1,6 @@
/*global QUnit*/
-var container, view;
-
-module("Handlebars {{control}} helper", {
- setup: function() {
- container = new Ember.Container();
- container.options('template', { instantiate: false });
- container.options('view', { singleton: false });
- container.register('controller:paren... | true |
Other | emberjs | ember.js | 8e13610d210cb024894656cce57e06a48ed96944.json | Hide {{control}} behind a flag - Fixes #2073 | tests/ember_configuration.js | @@ -28,6 +28,8 @@
ENV['STUB_OBJECT_CREATE'] = !Object.create;
}
+ ENV['EXPERIMENTAL_CONTROL_HELPER'] = true;
+
EmberDev.distros = {
spade: 'ember-spade.js',
build: 'ember.js', | true |
Other | emberjs | ember.js | f0600f0ba9f2e375a997f2a655b01bbaffb48236.json | Allow 0 as the value of a tag
This was broken by a refactor to the render buffer: 079630b | packages/ember-views/lib/system/render_buffer.js | @@ -352,7 +352,7 @@ Ember._RenderBuffer.prototype =
for (prop in props) {
if (props.hasOwnProperty(prop)) {
var value = props[prop];
- if (value) {
+ if (value || typeof(value) === 'number') {
if (value === true) {
buffer.push(' ' + prop + '="' + ... | true |
Other | emberjs | ember.js | f0600f0ba9f2e375a997f2a655b01bbaffb48236.json | Allow 0 as the value of a tag
This was broken by a refactor to the render buffer: 079630b | packages/ember-views/tests/system/render_buffer_test.js | @@ -15,6 +15,26 @@ test("RenderBuffers combine strings", function() {
equal("<div>ab</div>", buffer.string(), "Multiple pushes should concatenate");
});
+test("value of 0 is included in output", function() {
+ var buffer, $el;
+
+ buffer = new Ember.RenderBuffer('input');
+ buffer.prop('value', 0);
+ buffer.p... | true |
Other | emberjs | ember.js | aab99e5f036957e90e46dfce76282d93132f4a72.json | Add failing test for #2050 | packages/ember-runtime/tests/controllers/array_controller_test.js | @@ -21,3 +21,8 @@ Ember.MutableArrayTests.extend({
return obj.toArray ? obj.toArray() : obj.slice();
}
}).run();
+
+test("defaults it's `content` to an empty array", function () {
+ var Controller = Ember.ArrayController.extend();
+ equal(Controller.create().get("content"), [], "`ArrayController` defaults it... | false |
Other | emberjs | ember.js | e644762e3eef776409692e0c0ec1ddb260633d4c.json | Add download links for VirtualBox and Vagrant | CONTRIBUTING.md | @@ -64,21 +64,21 @@ then that will speed the process along.
The stack needed to build emberjs can be quite complex to setup for new developers. A VagrantFile is here to ease things for newcomers.
Using Vagrant to buid latest version of Ember.js is quite simple. Just follow nexts 4 steps:
-1. Install Vagrant
-2. Ret... | false |
Other | emberjs | ember.js | 9758b1e1635be19ccd577de9557f3016f69fe1f3.json | Fix false redirect alarm in Router.didTransition
In some cases didTransition believed a redirect had occurred when this was not
the case. This in turn prevented currentPath from being set among other issues. | packages/ember-routing/lib/system/route.js | @@ -40,7 +40,7 @@ Ember.Route = Ember.Object.extend({
@param {...Object} models the
*/
transitionTo: function() {
- this.transitioned = true;
+ if (this._checkingRedirect) { this.redirected = true; }
return this.router.transitionTo.apply(this.router, arguments);
},
@@ -53,7 +53,7 @@ Ember.Rou... | true |
Other | emberjs | ember.js | 9758b1e1635be19ccd577de9557f3016f69fe1f3.json | Fix false redirect alarm in Router.didTransition
In some cases didTransition believed a redirect had occurred when this was not
the case. This in turn prevented currentPath from being set among other issues. | packages/ember-routing/lib/system/router.js | @@ -69,7 +69,7 @@ Ember.Router = Ember.Object.extend({
didTransition: function(infos) {
// Don't do any further action here if we redirected
for (var i=0, l=infos.length; i<l; i++) {
- if (infos[i].handler.transitioned) { return; }
+ if (infos[i].handler.redirected) { return; }
}
var ... | true |
Other | emberjs | ember.js | 9758b1e1635be19ccd577de9557f3016f69fe1f3.json | Fix false redirect alarm in Router.didTransition
In some cases didTransition believed a redirect had occurred when this was not
the case. This in turn prevented currentPath from being set among other issues. | packages/ember/tests/routing/basic_test.js | @@ -1172,6 +1172,42 @@ test("Redirecting from the middle of a route aborts the remainder of the routes"
equal(router.get('location').getURL(), "/home");
});
+test("Transitioning from a parent event does not prevent currentPath from being set", function() {
+ Router.map(function() {
+ this.resource("foo", func... | true |
Other | emberjs | ember.js | 3df5ddfd4f01555da31a18d6b8d2fbbf82b11ea3.json | Tack the raw function onto bound helpers | packages/ember-handlebars/lib/ext.js | @@ -246,7 +246,7 @@ Ember.Handlebars.registerHelper('helperMissing', function(path, options) {
Ember.Handlebars.registerBoundHelper = function(name, fn) {
var dependentKeys = slice.call(arguments, 2);
- Ember.Handlebars.registerHelper(name, function() {
+ function helper() {
var properties = slice.call(arg... | false |
Other | emberjs | ember.js | 03cebf38d091604046b0f7704804fe54630bdab9.json | Wrap the hashchange event in an Ember.run | packages/ember-routing/lib/location/hash_location.js | @@ -61,12 +61,14 @@ Ember.HashLocation = Ember.Object.extend({
var guid = Ember.guidFor(this);
Ember.$(window).bind('hashchange.ember-location-'+guid, function() {
- var path = location.hash.substr(1);
- if (get(self, 'lastSetURL') === path) { return; }
+ Ember.run(function() {
+ var p... | false |
Other | emberjs | ember.js | 3ff578ca023a8c25f22a62dfbd870d171740cf13.json | Test the URL for app reset | packages/ember-application/tests/system/reset_test.js | @@ -64,7 +64,7 @@ test("When an application is reset, the ApplicationView is torn down", function(
});
test("When an application is reset, the router URL is reset to `/`", function() {
- var location;
+ var location, router;
Ember.run(function() {
application = Application.create();
@@ -78,7 +78,7 @@ te... | false |
Other | emberjs | ember.js | eb0fa874223641e8905077f2ab89e1676cea5117.json | Fix handling of keywords in bind helpers
Fixes #1315 | packages/ember-handlebars/lib/helpers/binding.js | @@ -21,22 +21,18 @@ function bind(property, options, preserveContext, shouldDisplay, valueNormalizer
inverse = options.inverse,
view = data.view,
currentContext = this,
- pathRoot, path, normalized,
- observer, i;
+ normalized, observer, i;
normalized = normalizePath(currentCont... | true |
Other | emberjs | ember.js | eb0fa874223641e8905077f2ab89e1676cea5117.json | Fix handling of keywords in bind helpers
Fixes #1315 | packages/ember-handlebars/tests/handlebars_test.js | @@ -354,6 +354,27 @@ test("Ember.View should update when a property changes and the bind helper is us
equal(view.$('#first').text(), "bazam", "view updates when a bound property changes");
});
+test("Ember.View should not use keyword incorrectly - Issue #1315", function() {
+ container.register('template', 'foo'... | true |
Other | emberjs | ember.js | 737c2872ef21f973dd265031764631515d6ed716.json | Fix typo in evented mixin. | packages/ember-runtime/lib/mixins/evented.js | @@ -83,7 +83,7 @@ Ember.Evented = Ember.Mixin.create({
event.
```javascript
- person.on('didEat', food) {
+ person.on('didEat', function(food) {
console.log('person ate some ' + food);
});
| false |
Other | emberjs | ember.js | e142d7f522d4cfbf443102d0147da5cd41d4e957.json | Update documentation on router logging | packages/ember-application/lib/system/application.js | @@ -114,7 +114,14 @@ var get = Ember.get, set = Ember.set,
### Routing
In addition to creating your application's router, `Ember.Application` is
- also responsible for telling the router when to start routing.
+ also responsible for telling the router when to start routing. Transitions
+ between routes can b... | false |
Other | emberjs | ember.js | 5ee0487184539babef74afa92f20e8a11c3f80e5.json | Fix failing test written in 9d3ecef - Fixes #1982 | packages/ember-runtime/lib/controllers/array_controller.js | @@ -136,20 +136,22 @@ Ember.ArrayController = Ember.ArrayProxy.extend(Ember.ControllerMixin,
objectAtContent: function(idx) {
var length = get(this, 'length'),
- object = get(this,'arrangedContent').objectAt(idx),
- controllerClass = this.lookupItemController(object);
-
- if (controllerClass ... | false |
Other | emberjs | ember.js | 6b11eeb9ca71f110c3881050c41eaa039347f0eb.json | Allow 0 as the value of a tag | packages/ember-views/lib/system/render_buffer.js | @@ -331,7 +331,7 @@ Ember._RenderBuffer.prototype =
this.elementAttributes = null;
}
- if (value) {
+ if (value || typeof value === 'number') {
buffer.push(' value="' + this._escapeAttribute(value) + '"');
this.elementValue = null;
@@ -391,7 +391,7 @@ Ember._RenderBuffer.prototype =
... | true |
Other | emberjs | ember.js | 6b11eeb9ca71f110c3881050c41eaa039347f0eb.json | Allow 0 as the value of a tag | packages/ember-views/tests/system/render_buffer_test.js | @@ -17,6 +17,26 @@ test("RenderBuffers combine strings", function() {
equal("<div>ab</div>", cleanedString, "Multiple pushes should concatenate");
});
+test("value of 0 is included in output", function() {
+ var buffer, $el;
+
+ buffer = new Ember.RenderBuffer('input');
+ buffer.val(0);
+ buffer.pushOpeningTa... | true |
Other | emberjs | ember.js | 0f740430c0fcfdeb41d9c7e5bb412651db688b18.json | Add start of {{render}} documentation | packages/ember-routing/lib/helpers/render.js | @@ -9,6 +9,23 @@ require('ember-handlebars/helpers/view');
Ember.onLoad('Ember.Handlebars', function(Handlebars) {
+ /**
+ Renders the named template in the current context using the singleton
+ instance of the same-named controller.
+
+ If a view class with the same name exists, uses the view class.
+
+... | false |
Other | emberjs | ember.js | e7ea6a3d0d2c1f74c0dbe8f75430ec04cecb8a49.json | Create activate and deactivate hooks for router | packages/ember-routing/lib/system/route.js | @@ -10,9 +10,26 @@ var get = Ember.get, set = Ember.set,
Ember.Route = Ember.Object.extend({
exit: function() {
+ this.deactivate();
teardownView(this);
},
+ enter: function() {
+ this.activate();
+ },
+
+ /**
+ This hook is executed when the router completely exits this route. It is
+ no... | false |
Other | emberjs | ember.js | a089eb4ffdacd617fcd613068f7a354379a9c874.json | Add rake task for building pull requests | Gemfile | @@ -9,4 +9,5 @@ gem "uglifier", :git => "https://github.com/lautis/uglifier.git"
group :development do
gem "rack"
gem "kicker"
+ gem "grit"
end | true |
Other | emberjs | ember.js | a089eb4ffdacd617fcd613068f7a354379a9c874.json | Add rake task for building pull requests | Gemfile.lock | @@ -26,24 +26,40 @@ GIT
GEM
remote: http://rubygems.org/
specs:
+ coderay (1.0.8)
colored (1.2)
+ diff-lcs (1.2.0)
execjs (1.4.0)
multi_json (~> 1.0)
+ grit (2.5.0)
+ diff-lcs (~> 1.1)
+ mime-types (~> 1.15)
+ posix-spawn (~> 0.3.6)
json (1.7.6)
kicker (2.6.1)
... | true |
Other | emberjs | ember.js | a089eb4ffdacd617fcd613068f7a354379a9c874.json | Add rake task for building pull requests | Rakefile | @@ -481,3 +481,31 @@ namespace :release do
end
task :default => :test
+
+
+desc "Build Ember.js from a given fork & branch"
+task :build, :username, :branch do |t, args|
+ require "grit"
+
+ if args.to_hash.keys.length != 2
+ puts "Usage: rake build[wycats,some-cool-feature]"
+ exit 1
+ end
+
+ username, ... | true |
Other | emberjs | ember.js | 04df12c25fe3c9afb21b5e055e74d58ce3339f2f.json | Prevent overwrite on view registration
See #1553 | packages/ember-views/lib/views/view.js | @@ -58,7 +58,10 @@ Ember.CoreView = Ember.Object.extend(Ember.Evented, {
// Register the view for event handling. This hash is used by
// Ember.EventDispatcher to dispatch incoming events.
- if (!this.isVirtual) Ember.View.views[this.elementId] = this;
+ if (!this.isVirtual) {
+ Ember.assert("Att... | false |
Other | emberjs | ember.js | 8c6064902d1221cc83b5fe5e1f391cf81d46fa48.json | CollectionView cleans up emptyView - Fixes #1957
Previously, if emptyView was a class, CollectionView would create an
instance but never destroy it. | packages/ember-views/lib/views/collection_view.js | @@ -241,6 +241,10 @@ Ember.CollectionView = Ember.ContainerView.extend(
if (content) { content.removeArrayObserver(this); }
this._super();
+
+ if (this._createdEmptyView) {
+ this._createdEmptyView.destroy();
+ }
},
arrayWillChange: function(content, start, removedCount) {
@@ -310,9 +314,... | false |
Other | emberjs | ember.js | 96b56b147152e3e8eccc2b6591c278c6854e7b38.json | Remove old ember_ debug methods | .jshintrc | @@ -7,10 +7,6 @@
"Handlebars",
"Metamorph",
"RSVP",
- "ember_assert",
- "ember_warn",
- "ember_deprecate",
- "ember_deprecateFunc",
"require",
"requireModule",
"equal", | true |
Other | emberjs | ember.js | 96b56b147152e3e8eccc2b6591c278c6854e7b38.json | Remove old ember_ debug methods | packages/ember-debug/lib/main.js | @@ -142,10 +142,3 @@ Ember.deprecateFunc = function(message, func) {
return func.apply(this, arguments);
};
};
-
-if ('undefined' !== typeof window) {
- window.ember_assert = Ember.deprecateFunc("ember_assert is deprecated. Please use Ember.assert instead.", Ember.assert);
- window.embe... | true |
Other | emberjs | ember.js | 96b56b147152e3e8eccc2b6591c278c6854e7b38.json | Remove old ember_ debug methods | packages/ember-metal/lib/core.js | @@ -128,15 +128,6 @@ if ('undefined' === typeof Ember.deprecateFunc) {
Ember.deprecateFunc = function(_, func) { return func; };
}
-// These are deprecated but still supported
-
-if ('undefined' === typeof ember_assert) { exports.ember_assert = Ember.K; }
-if ('undefined' === typeof ember_warn) { exports.ember_wa... | true |
Other | emberjs | ember.js | fae401b9a681ee126336199cd874dbabbad76923.json | remove traces of eachHelper | packages/ember-handlebars/lib/helpers/collection.js | @@ -201,7 +201,6 @@ Ember.Handlebars.registerHelper('collection', function(path, options) {
hash.emptyView = emptyViewClass;
itemHash._context = Ember.computed.alias('content');
- delete hash.eachHelper;
var viewString = view.toString();
| true |
Other | emberjs | ember.js | fae401b9a681ee126336199cd874dbabbad76923.json | remove traces of eachHelper | packages/ember-handlebars/lib/helpers/each.js | @@ -273,8 +273,6 @@ Ember.Handlebars.registerHelper('each', function(path, options) {
if (path === '') { path = "this"; }
options.hash.keyword = keywordName;
- } else {
- options.hash.eachHelper = 'each';
}
options.hash.dataSourceBinding = path; | true |
Other | emberjs | ember.js | 2f5adaa7a2ed502932e33dc441d613098c6af79a.json | Render values with val. Fixes #1828
In jQuery 1.9, setting the value of an input with
`attr(` is no longer supported. Here we explode
`applyAttributeBindings` to handle value properties
with `val(` instead. of `attr(`. This required adding
an duck of value handling in jQuery to `RenderBuffer` | packages/ember-handlebars/tests/controls/text_field_test.js | @@ -141,6 +141,35 @@ test("value binding works properly for inputs that haven't been created", functi
equal(textField.$().val(), 'ohai', "value is reflected in the input element once it is created");
});
+test("value binding sets value on the element", function() {
+ Ember.run(function() {
+ textField = Ember... | true |
Other | emberjs | ember.js | 2f5adaa7a2ed502932e33dc441d613098c6af79a.json | Render values with val. Fixes #1828
In jQuery 1.9, setting the value of an input with
`attr(` is no longer supported. Here we explode
`applyAttributeBindings` to handle value properties
with `val(` instead. of `attr(`. This required adding
an duck of value handling in jQuery to `RenderBuffer` | packages/ember-views/lib/system/render_buffer.js | @@ -104,6 +104,19 @@ Ember._RenderBuffer.prototype =
*/
elementAttributes: null,
+ /**
+ The value for this attribute. Values cannot be set via attr after
+ jQuery 1.9, they need to be set with val() instead.
+
+ You should not maintain this value yourself, rather, you should use
+ the `val()` meth... | true |
Other | emberjs | ember.js | 2f5adaa7a2ed502932e33dc441d613098c6af79a.json | Render values with val. Fixes #1828
In jQuery 1.9, setting the value of an input with
`attr(` is no longer supported. Here we explode
`applyAttributeBindings` to handle value properties
with `val(` instead. of `attr(`. This required adding
an duck of value handling in jQuery to `RenderBuffer` | packages/ember-views/lib/views/view.js | @@ -2321,17 +2321,57 @@ Ember.View.views = {};
Ember.View.childViewsProperty = childViewsProperty;
Ember.View.applyAttributeBindings = function(elem, name, value) {
+ if (name === 'value') {
+ Ember.View.applyValueBinding(elem, value);
+ } else {
+ Ember.View.applyAttributeBinding(elem, name, value);
+ }
+... | true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.