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 | f67eb2be75bf8f7130d3213f7123a88b1b3479f4.json | Remove unused _valueDidChange function. | packages/sproutcore-handlebars/lib/controls/text_field.js | @@ -54,10 +54,6 @@ SC.TextField = SC.View.extend(
set(this, 'value', this.$().val());
},
- _valueDidChange: function() {
- SC.run.once(this, this._updateElementValue);
- },
-
_updateElementValue: function() {
this.$().val(get(this, 'value'));
} | false |
Other | emberjs | ember.js | 7e07f49637323180f8896a6480aa449ebe48faf3.json | Remove unused _valueDidChange function. | packages/sproutcore-handlebars/lib/controls/text_field.js | @@ -54,10 +54,6 @@ SC.TextField = SC.View.extend(
set(this, 'value', this.$().val());
},
- _valueDidChange: function() {
- SC.run.once(this, this._updateElementValue);
- },
-
_updateElementValue: function() {
this.$().val(get(this, 'value'));
} | false |
Other | emberjs | ember.js | fd70391367ef0c4588a4262634495ffc242fbde5.json | add pan to test | packages/sproutcore-touch/lib/gesture_recognizers/pinch.js | @@ -88,7 +88,6 @@ SC.PinchGestureRecognizer = SC.Gesture.extend({
touchEnd: function(evt, view) {
this.state = SC.Gesture.ENDED;
- //this.scale = 0;
this.redispatchEventToView(view,'touchend');
},
| true |
Other | emberjs | ember.js | fd70391367ef0c4588a4262634495ffc242fbde5.json | add pan to test | packages/sproutcore-touch/tests/system/gesture_support.js | @@ -290,6 +290,60 @@ test("when 2 fingers move closer together, gesture should be in BEGAN state", fu
console.groupEnd();
});
+
+test("pan test", function() {
+ view = SC.View.create({
+ elementId: 'gestureTest',
+
+ pinchStart: function(recognizer, scale) {
+ numStart++;
+ startScale = scale;
+ ... | true |
Other | emberjs | ember.js | 12213887e27c14c48926f85df51565609fa90b4d.json | Add pan gesture recognizer | packages/sproutcore-touch/lib/gesture_recognizers.js | @@ -1,2 +1,3 @@
require('sproutcore-touch/gesture_recognizers/pinch')
+require('sproutcore-touch/gesture_recognizers/pan')
require('sproutcore-touch/gesture_recognizers/tap') | true |
Other | emberjs | ember.js | 12213887e27c14c48926f85df51565609fa90b4d.json | Add pan gesture recognizer | packages/sproutcore-touch/lib/gesture_recognizers/pan.js | @@ -0,0 +1,113 @@
+// ==========================================================================
+// Project: SproutCore Runtime
+// Copyright: ©2011 Strobe Inc. and contributors.
+// License: Licensed under MIT license (see license.js)
+// ==========================================================================
+... | true |
Other | emberjs | ember.js | 2c2136d26e09ba5069d3d1f3354b27142a174e19.json | Get the package name back in the QUnit header | packages/qunit/lib/qunit-runner.js | @@ -24,7 +24,9 @@ if (!packageName) {
QUnit.config.autostart = false;
QUnit.config.autorun = false;
- $('h1 > a').text(packageName);
+ jQuery(function() {
+ $('h1 > a').text(packageName);
+ });
QUnit.jsDump.setParser('object', function(obj) {
return obj.toString(); | false |
Other | emberjs | ember.js | 85400050dc62f9d2cef0d27296571063b262c997.json | Fix bugs introduced by rebasing | packages/sproutcore-touch/lib/gesture_recognizers/pinch.js | @@ -42,7 +42,6 @@ SC.PinchGestureRecognizer = SC.Gesture.extend({
touchMove: function(evt, view) {
var touches = evt.originalEvent.targetTouches;
- console.log('Pinch got touchMove');
if(touches.length !== get(this, 'numberOfTouches')) {
return;
}
@@ -53,15 +52,15 @@ SC.PinchGestureRecogni... | true |
Other | emberjs | ember.js | 85400050dc62f9d2cef0d27296571063b262c997.json | Fix bugs introduced by rebasing | packages/sproutcore-touch/lib/system/gesture.js | @@ -31,7 +31,7 @@ SC.Gesture = SC.Object.extend({
view.$().trigger(eventName,true);
},
- notifyViewOfPinchEvent: function(view, eventName, data) {
+ notifyViewOfGestureEvent: function(view, eventName, data) {
var handler = view[eventName];
if (SC.typeOf(handler) === 'function') { | true |
Other | emberjs | ember.js | 85400050dc62f9d2cef0d27296571063b262c997.json | Fix bugs introduced by rebasing | packages/sproutcore-touch/tests/system/gesture_support.js | @@ -223,8 +223,12 @@ window.shit = function () {
SC.run(function(){
var myview = SC.View.create({
elementId: 'gestureTest',
+
+ scale: 1,
+
pinchChange: function(recognizer, scale) {
- var string = 'scale3d('+scale+','+scale+',1)';
+ this.scale *= scale;
+ var string = 's... | true |
Other | emberjs | ember.js | 85400050dc62f9d2cef0d27296571063b262c997.json | Fix bugs introduced by rebasing | packages/sproutcore-views/lib/system/event_dispatcher.js | @@ -115,8 +115,6 @@ SC.EventDispatcher = SC.Object.extend(
result = self._bubbleEvent(view,evt,eventName);
}
- evt.stopPropagation();
-
return result;
});
},
@@ -144,6 +142,8 @@ SC.EventDispatcher = SC.Object.extend(
result = handler.call(object, evt, view);
}
+ ev... | true |
Other | emberjs | ember.js | a4a41d1f80e6c8d0e607d67b85efe2e0a2b954a7.json | Reduce delta threshold for now. | packages/sproutcore-touch/lib/gesture_recognizers/pinch.js | @@ -20,7 +20,7 @@ SC.PinchGestureRecognizer = SC.Gesture.extend({
_currentDistanceBetweenTouches: null,
_previousDistanceBetweenTouches: null,
- _deltaThreshold: 10,
+ _deltaThreshold: 0,
scale: 0,
| false |
Other | emberjs | ember.js | 6ac8c130aa3d23f3a20430c5d92e3eb00c4e3133.json | add support for gesture event dispatching | packages/sproutcore-touch/lib/system/gesture.js | @@ -29,6 +29,14 @@ SC.Gesture = SC.Object.extend({
redispatchEventToView: function(view, eventName) {
view.$().trigger(eventName,true);
+ },
+
+ notifyViewOfPinchEvent: function(view, eventName, data) {
+ var handler = view[eventName];
+
+ if (SC.typeOf(handler) === 'function') {
+ handler.call(v... | false |
Other | emberjs | ember.js | e29fbe0e225ed9a76a1f128ede3542f4f3b10bf5.json | Add unit test for POSSIBLE state | packages/sproutcore-touch/tests/system/gesture_support.js | @@ -7,6 +7,7 @@
var set = SC.set;
var get = SC.get;
var application = null;
+var view;
function generateTouchEvent(touches) {
@@ -20,6 +21,7 @@ module("Test Gesture Recognizer",{
teardown: function() {
application.destroy();
+ if(view) view.destroy();
}
});
@@ -45,7 +47,7 @@ test("gesturabl... | false |
Other | emberjs | ember.js | 1f800c3b339805ea0d072e62ad9fcf01fafac674.json | Add unit tests for new SC.EventManager API | packages/sproutcore-views/tests/system/event_dispatcher_test.js | @@ -123,3 +123,55 @@ test("should not interfere with event propagation", function() {
same(receivedEvent.target, SC.$('#propagate-test-div')[0], "target property is the element that was clicked");
});
+test("should dispatch events to nearest event manager", function() {
+ var receivedEvent=0;
+ view = SC.Contai... | false |
Other | emberjs | ember.js | e39d5f81ea9a2cd0e66c669200930042c6f17ed2.json | Update event dispatcher to use SC.EventManager API | packages/sproutcore-views/lib/system/event_dispatcher.js | @@ -99,7 +99,52 @@ SC.EventDispatcher = SC.Object.extend(
setupHandler: function(rootElement, event, eventName) {
rootElement.delegate('.sc-view', event + '.sproutcore', function(evt) {
var view = SC.View.views[this.id],
- result = true, handler;
+ result = true, manager = null,
+ ... | false |
Other | emberjs | ember.js | 919aa2b91b253dda2202f7e816fc499b712b1a78.json | Fix bug with view extension | packages/sproutcore-touch/lib/system/view.js | @@ -29,11 +29,10 @@ SC.View.reopen(
}
}
- console.log('setting gestures property to ',gestures);
set(this, 'gestures', gestures);
}
- return;
+ return this._super();
}
}); | false |
Other | emberjs | ember.js | d8b40bb876f12f33254c921bb26dd263e692ca60.json | Remove unneeded "subproject" | vendor/ruby/1.9.1/bundler/gems/abbot-from-scratch-754164ff560e | @@ -1 +0,0 @@
-Subproject commit 754164ff560e2597b62fb326358fb8b9f7fc3ed4 | false |
Other | emberjs | ember.js | 572dad409d67949453874e3361e19558726a84fb.json | Add unit test for relative paths in collection. | packages/sproutcore-handlebars/tests/views/collection_view_test.js | @@ -8,7 +8,7 @@
var set = SC.set, setPath = SC.setPath;
var view;
-module("SC.HandlebarsCollectionView", {
+module("sproutcore-handlebars/tests/views/collection_view_test", {
setup: function() {
window.TemplateTests = SC.Namespace.create();
},
@@ -28,7 +28,24 @@ test("passing a block to the collection he... | false |
Other | emberjs | ember.js | 1cc312437c249fcae4d4e25dd8b18b1eb562d9ba.json | Resolve merge conflict in unknown property test | packages/sproutcore-metal/lib/properties.js | @@ -161,7 +161,11 @@ var WATCHED_DESC = {
function w_get(obj, keyName) {
var m = meta(obj, false);
- return m.values ? m.values[keyName] : undefined;
+ if (m.values) {
+ if (m.values[keyName] !== undefined) { return m.values[keyName]; }
+ obj.unknownProperty(keyName);
+ };
+ return undefined;
}
func... | true |
Other | emberjs | ember.js | 1cc312437c249fcae4d4e25dd8b18b1eb562d9ba.json | Resolve merge conflict in unknown property test | packages/sproutcore-metal/tests/watching/watch_test.js | @@ -85,6 +85,21 @@ test("watching an object THEN defining it should work also", function() {
});
+test("accessing a watched unknown property triggers call to unknownProperty", function(){
+ var unknownPropertyWasCalled = false;
+ var watchedPropertyName = 'foo'
+
+ var obj = {
+ unknownProperty: function... | true |
Other | emberjs | ember.js | 9f2caece30bcf6ffab4a39dd8cd510b6081d749e.json | Improve error messaging in handlebars helper. | packages/sproutcore-handlebars/lib/helpers/binding.js | @@ -8,7 +8,7 @@
require('sproutcore-handlebars/ext');
require('sproutcore-handlebars/views/bindable_span');
-var get = SC.get, getPath = SC.getPath;
+var get = SC.get, getPath = SC.getPath, fmt = SC.String.fmt;
(function() {
// Binds a property into the DOM. This will create a hook in DOM that the
@@ -76,14 +... | true |
Other | emberjs | ember.js | 9f2caece30bcf6ffab4a39dd8cd510b6081d749e.json | Improve error messaging in handlebars helper. | packages/sproutcore-handlebars/lib/helpers/view.js | @@ -12,7 +12,7 @@ var get = SC.get, set = SC.set;
/** @private */
SC.Handlebars.ViewHelper = SC.Object.create({
-
+
viewClassFromHTMLOptions: function(viewClass, options) {
var extensions = {},
classes = options['class'],
@@ -54,20 +54,21 @@ SC.Handlebars.ViewHelper = SC.Object.create({
if... | true |
Other | emberjs | ember.js | 9f2caece30bcf6ffab4a39dd8cd510b6081d749e.json | Improve error messaging in handlebars helper. | packages/sproutcore-handlebars/tests/handlebars_test.js | @@ -952,12 +952,12 @@ test("should be able to bind element attributes using {{bindAttr}}", function()
equals(view.$('img').attr('alt'), "The SproutCore Logo", "updates alt attribute when content object is a hash");
SC.run(function() {
- set(view, 'content', {
+ set(view, 'content', SC.Object.create({
... | true |
Other | emberjs | ember.js | 64919852a8bc2eb56c72f50209b3186abce8209a.json | Require bpm in Gemfile | Gemfile | @@ -2,6 +2,7 @@
source "http://rubygems.org"
gem "rake"
+gem "bpm"
gem "spade"
gem "uglifier"
| false |
Other | emberjs | ember.js | 1ead162c5a9cd28e85e7209bbd9c7df1cd043373.json | Put ownerConstructor on class and prototype mixins | packages/sproutcore-runtime/lib/system/core_object.js | @@ -104,6 +104,9 @@ var ClassMixin = SC.Mixin.create({
Class.ClassMixin = SC.Mixin.create(this.ClassMixin);
Class.PrototypeMixin = SC.Mixin.create(this.PrototypeMixin);
+ Class.ClassMixin.ownerConstructor = Class;
+ Class.PrototypeMixin.ownerConstructor = Class;
+
var PrototypeMixin = Class.Proto... | false |
Other | emberjs | ember.js | ebfc867c0ddff8e7839c530f3112943d81a45eb9.json | Fix Gemfile since a new spade gem was released | Gemfile | @@ -2,11 +2,7 @@
source "http://rubygems.org"
gem "rake"
-if spade_path = ENV["SPADE_PATH"]
- gem "spade", :path => spade_path
-else
- gem "spade"
-end
+gem "spade"
gem "uglifier"
if abbot_path = ENV["ABBOT_PATH"] | false |
Other | emberjs | ember.js | 9b0aa65af9c44e512f6bd1bec43bcfbbbff54f5c.json | Fix Mixins w/ toString() in IE | packages/sproutcore-metal/lib/mixin.js | @@ -116,7 +116,11 @@ function mergeMixins(mixins, m, descs, values, base) {
values[key] = value;
}
}
-
+
+ // manually copy toString() because some JS engines do not enumerate it
+ if (props.hasOwnProperty('toString')) {
+ base.toString = props.toString;
+ }
... | false |
Other | emberjs | ember.js | 464afe0d3ac3a8f6d2b13d297a095ca3c61b464b.json | Replace String [] usage with charAt for IE7. | packages/sproutcore-metal/lib/accessors.js | @@ -146,9 +146,9 @@ function normalizePath(path) {
path && path!=='');
if (path==='*') return path; //special case...
- var first = path[0];
+ var first = path.charAt(0);
if(first==='.') return 'this'+path;
- if (first==='*' && path[1]!=='.') return 'this.'+path.slice(1);
+ if (first==='*' && path.... | false |
Other | emberjs | ember.js | 5b6b584068404b8cd230d88bf390d551ae717990.json | Put package name in QUnit header | packages/qunit/lib/qunit-runner.js | @@ -17,6 +17,7 @@ if (!packageName) {
QUnit.config.autostart = false;
QUnit.onload();
+ $('h1 > a').text(packageName);
QUnit.jsDump.setParser('object', function(obj) {
return obj.toString(); | false |
Other | emberjs | ember.js | 33f01b458ce5809270475429b9f9915e1765a9ed.json | Fix whitespace and JSLint for core object | packages/sproutcore-runtime/lib/system/core_object.js | @@ -22,19 +22,19 @@ function makeCtor() {
// Note: avoid accessing any properties on the object since it makes the
// method a lot faster. This is glue code so we want it to be as fast as
// possible.
-
+
var isPrepared = false, initMixins, init = false, hasChains = false;
-
+
var Class = function()... | false |
Other | emberjs | ember.js | 90e77f5af84e46ebcdc3777477d2dcf527148790.json | Restore helpful comment about inline templates | packages/sproutcore-handlebars/lib/loader.js | @@ -23,6 +23,7 @@ SC.$(document).ready(function() {
view, viewPath;
if (templateName) {
+ // For templates which have a name, we save them and then remove them from the DOM
SC.TEMPLATES[templateName] = template;
// Remove script tag from DOM
@@ -34,6 +35,13 @@ SC.$(document).ready(fun... | false |
Other | emberjs | ember.js | 40f7d959cce2c431fb4b40076e1d0ef0c6aa8f99.json | Add documentation for render buffer | packages/sproutcore-views/lib/system/render_buffer.js | @@ -7,12 +7,13 @@
var get = SC.get, set = SC.set;
-/*
- TODO Document SC.RenderBuffer class itself
-*/
-
/**
@class
+
+ SC.RenderBuffer gathers information regarding the a view and generates the
+ final representation. SC.RenderBuffer will generate HTML which can be pushed
+ to the DOM.
+
@extends SC.O... | false |
Other | emberjs | ember.js | 91c78754bac4a1b1d32e991de68a1553b467178e.json | Add an unbound output helper. | packages/sproutcore-handlebars/lib/helpers.js | @@ -7,3 +7,4 @@
require("sproutcore-handlebars/helpers/binding");
require("sproutcore-handlebars/helpers/collection");
require("sproutcore-handlebars/helpers/view");
+require("sproutcore-handlebars/helpers/unbound"); | true |
Other | emberjs | ember.js | 91c78754bac4a1b1d32e991de68a1553b467178e.json | Add an unbound output helper. | packages/sproutcore-handlebars/lib/helpers/unbound.js | @@ -0,0 +1,24 @@
+// ==========================================================================
+// Project: SproutCore Handlebar Views
+// Copyright: ©2011 Strobe Inc. and contributors.
+// License: Licensed under MIT license (see license.js)
+// ====================================================================... | true |
Other | emberjs | ember.js | 91c78754bac4a1b1d32e991de68a1553b467178e.json | Add an unbound output helper. | packages/sproutcore-handlebars/tests/handlebars_test.js | @@ -1032,3 +1032,19 @@ test("should use the childView's renderBuffer", function() {
ok(calledRenderBuffer);
});
+
+test("should be able to output a property without binding", function(){
+ var template = SC.Handlebars.compile('<div>{{raw content.aRawString}}</div>');
+ var content = SC.Object.create({
+ aR... | true |
Other | emberjs | ember.js | 4831430c8e9de7925d26a80b967a173ebbc47567.json | Add tests for isClass/isInstance implementation | packages/sproutcore-runtime/tests/system/object/extend_test.js | @@ -8,8 +8,10 @@ module('SC.Object.extend');
test('Basic extend', function() {
var SomeClass = SC.Object.extend({ foo: 'BAR' });
+ ok(SomeClass.isClass, "A class has isClass of true");
var obj = new SomeClass();
equals(obj.foo, 'BAR');
+ ok(obj.isInstance, "An instance of a class has isInstance of true");... | false |
Other | emberjs | ember.js | d4ff579ce3ec69673f3b003ce319959a3a3eab77.json | Expose current index in CollectionViews | packages/sproutcore-views/lib/views/collection_view.js | @@ -181,7 +181,8 @@ SC.CollectionView = SC.View.extend(
for (idx = 0; idx < len; idx++) {
item = addedObjects.objectAt(idx);
view = this.createChildView(itemViewClass, {
- content: item
+ content: item,
+ index: idx
});
buffer = buffer + view.rende... | false |
Other | emberjs | ember.js | b6c4ef5785fa7ca515408c02cd7879957044492f.json | Update build process and bump version | Rakefile | @@ -95,7 +95,7 @@ trap "INT" do
$threads.each(&:kill)
end
-VERSION = "2.0"
+VERSION = File.read("VERSION")
def spade_update_task(package)
path = "packages/#{package}"
@@ -219,5 +219,66 @@ namespace :test do
spade_preview_task "sproutcore-datastore", [metal_installed, datastore_spade_boot] + datastore_te... | true |
Other | emberjs | ember.js | b6c4ef5785fa7ca515408c02cd7879957044492f.json | Update build process and bump version | VERSION | @@ -0,0 +1 @@
+2.0.beta.1
\ No newline at end of file | true |
Other | emberjs | ember.js | b6c4ef5785fa7ca515408c02cd7879957044492f.json | Update build process and bump version | packages/sproutcore-datastore/package.json | @@ -4,7 +4,7 @@
"description": "The SproutCore data store",
"homepage": "http://sproutcore.com",
"author": "Strobe Inc., Apple, Inc., and contributors",
- "version": "2.0",
+ "version": "2.0.beta.1",
"dependencies": {
"sproutcore-runtime": "2.0",
"sproutcore-datetime": "2.0", | true |
Other | emberjs | ember.js | b6c4ef5785fa7ca515408c02cd7879957044492f.json | Update build process and bump version | packages/sproutcore-datetime/package.json | @@ -4,7 +4,7 @@
"description": "A rich date time class with utilities",
"homepage": "http://sproutcore.com",
"author": "Strobe Inc., Apple, Inc., and contributors",
- "version": "2.0",
+ "version": "2.0.beta.1",
"dependencies": {
"sproutcore-runtime": "2.0",
"sproutcore-preprocessor": "~> 0.0.2" | true |
Other | emberjs | ember.js | b6c4ef5785fa7ca515408c02cd7879957044492f.json | Update build process and bump version | packages/sproutcore-handlebars/package.json | @@ -4,7 +4,7 @@
"description": "Extensions to the Handlebars templating engine for use with SproutCore. These extensions make Handlebars aware of property observing, which allows it to automatically update the DOM when the referenced properties change. It also provides Handlebars helpers for creating SproutCore view... | true |
Other | emberjs | ember.js | b6c4ef5785fa7ca515408c02cd7879957044492f.json | Update build process and bump version | packages/sproutcore-indexset/package.json | @@ -4,7 +4,7 @@
"description": "Provides an observable, enumerable IndexSet",
"homepage": "http://sproutcore.com",
"author": "Strobe Inc., Apple, Inc., and contributors",
- "version": "2.0",
+ "version": "2.0.beta.1",
"dependencies": {
"sproutcore-runtime": "2.0",
"sproutcore-preprocessor": "~> ... | true |
Other | emberjs | ember.js | b6c4ef5785fa7ca515408c02cd7879957044492f.json | Update build process and bump version | packages/sproutcore-metal/package.json | @@ -4,6 +4,6 @@
"summary": "JavaScript on Steroids",
"homepage": "http://github.com/sproutcore/sproutcore20",
"author": "Charles Jolley",
- "version": "2.0",
+ "version": "2.0.beta.1",
"directories": { "lib": "lib" }
} | true |
Other | emberjs | ember.js | b6c4ef5785fa7ca515408c02cd7879957044492f.json | Update build process and bump version | packages/sproutcore-runtime/package.json | @@ -5,7 +5,7 @@
"homepage": "http://sproutcore.com",
"author": "Charles Jolley",
- "version": "2.0",
+ "version": "2.0.beta.1",
"dependencies": {
"sproutcore-metal": "2.0", | true |
Other | emberjs | ember.js | b6c4ef5785fa7ca515408c02cd7879957044492f.json | Update build process and bump version | packages/sproutcore-views/package.json | @@ -4,7 +4,7 @@
"description": "The SproutCore view system",
"homepage": "http://sproutcore.com",
"author": "Yehuda Katz",
- "version": "2.0",
+ "version": "2.0.beta.1",
"dependencies": {
"jquery": "1.6",
"sproutcore-runtime": "2.0", | true |
Other | emberjs | ember.js | f2702e91bcbb9fa1ba4527c0e5eededb5f0aac39.json | Use attributeBindings instead of renderBuffer. | packages/sproutcore-handlebars/lib/controls/button.js | @@ -11,12 +11,9 @@ SC.Button = SC.View.extend({
classNameBindings: ['isActive'],
tagName: 'button',
+ attributeBindings: ['type'],
type: 'button',
- renderBuffer: function(tagName) {
- return SC.RenderBuffer(tagName).attr('type', get(this, 'type'));
- },
-
targetObject: function() {
var t... | false |
Other | emberjs | ember.js | a40723de2b2b28d24ccd876b9a72d10e5410aed5.json | Add tests for SC.Button type property | packages/sproutcore-handlebars/tests/controls/button_test.js | @@ -112,3 +112,14 @@ test("should not trigger action if mouse leaves area before mouseup", function()
ok(wasClicked);
});
+
+test("should by default be of type='button'", function() {
+ button.append();
+ equals(button.$().attr('type'), 'button');
+});
+
+test("should have a configurable type", function() {
+ ... | false |
Other | emberjs | ember.js | 8039b7e95d148d3d839e7bf8d30f44ecbea02ed7.json | Add a configurable type property to SC.Button. | packages/sproutcore-handlebars/lib/controls/button.js | @@ -11,6 +11,11 @@ SC.Button = SC.View.extend({
classNameBindings: ['isActive'],
tagName: 'button',
+ type: 'button',
+
+ renderBuffer: function(tagName) {
+ return SC.RenderBuffer(tagName).attr('type', this.get('type'));
+ }
targetObject: function() {
var target = get(this, 'target'); | false |
Other | emberjs | ember.js | b058cafaac2b2bff3451073ceee232887f862b5e.json | Add attribute bindings to SC.View. | packages/sproutcore-views/lib/views/view.js | @@ -7,7 +7,7 @@
/*globals sc_assert */
require("sproutcore-views/system/render_buffer");
-var get = SC.get, set = SC.set;
+var get = SC.get, set = SC.set, addObserver = SC.addObserver;
/**
@static
@@ -29,7 +29,7 @@ SC.View = SC.Object.extend(
/** @scope SC.View.prototype */ {
/** @private */
- concaten... | true |
Other | emberjs | ember.js | b058cafaac2b2bff3451073ceee232887f862b5e.json | Add attribute bindings to SC.View. | packages/sproutcore-views/tests/views/view/attribute_bindings_test.js | @@ -0,0 +1,40 @@
+// ==========================================================================
+// Project: SproutCore Views
+// Copyright: ©2006-2011 Strobe Inc. and contributors.
+// License: Licensed under MIT license (see license.js)
+// =========================================================================... | true |
Other | emberjs | ember.js | b058cafaac2b2bff3451073ceee232887f862b5e.json | Add attribute bindings to SC.View. | packages/sproutcore-views/tests/views/view/class_name_bindings_test.js | @@ -8,7 +8,7 @@ var set = SC.set, get = SC.get;
require('sproutcore-views/views/view');
-module("SC.View - Bound Class Names");
+module("SC.View - Class Name Bindings");
test("should apply bound class names to the element", function() {
var view = SC.View.create({ | true |
Other | emberjs | ember.js | 9dcb6813beeb1092b80dca7d83d36e274acd79a4.json | Handle submit events | packages/sproutcore-views/lib/system/event_dispatcher.js | @@ -56,6 +56,7 @@ SC.EventDispatcher = SC.Object.extend(
focusout : 'focusOut',
mouseenter : 'mouseEnter',
mouseleave : 'mouseLeave',
+ submit : 'submit',
change : 'change'
};
| false |
Other | emberjs | ember.js | dfdec1f9a1f3ba3b403d5e0849707f1f8f9f8321.json | Expose Handlebars as a global | packages/handlebars/lib/main.js | @@ -473,7 +473,7 @@ if (typeof module !== 'undefined' && require.main === module) {
};
;
// lib/handlebars/base.js
-var Handlebars = {};
+Handlebars = {};
Handlebars.VERSION = "1.0.beta.2";
| false |
Other | emberjs | ember.js | eb3c5aa562461d238c8d1b02c80b428858416c38.json | Update Handlebars to 1.0.0.beta.3 | packages/handlebars/lib/main.js | @@ -3,9 +3,9 @@
var handlebars = (function(){
var parser = {trace: function trace() { },
yy: {},
-symbols_: {"error":2,"root":3,"program":4,"EOF":5,"statements":6,"simpleInverse":7,"statement":8,"openInverse":9,"closeBlock":10,"openBlock":11,"mustache":12,"partial":13,"CONTENT":14,"COMMENT":15,"OPEN_BLOCK":16,"inMus... | false |
Other | emberjs | ember.js | 18761cc3d1b65152083a80e7fb6b3f00fb8e2b56.json | Fix spelling of META_DESC.configurable | packages/sproutcore-metal/lib/utils.js | @@ -127,7 +127,7 @@ SC.guidFor = function(obj) {
var META_DESC = {
writable: true,
- confgurable: false,
+ configurable: false,
enumerable: false,
value: null
}; | false |
Other | emberjs | ember.js | d519a0ae042bfdb0221ce76342e6f4dcdb7e7e71.json | Update Rakefile to include runtime and metal | Rakefile | @@ -28,19 +28,20 @@ def compile_package_task(package)
end
namespace :sproutcore do
- %w(metal handlebars views datastore).each do |package|
+ %w(metal runtime handlebars views datastore).each do |package|
task package => compile_package_task("sproutcore-#{package}")
end
end
task :handlebars => compile... | false |
Other | emberjs | ember.js | 6b74623a85af5fe88cd30260f6453af626bf8486.json | Add overall sproutcore wrapper framework. | package.json | @@ -3,12 +3,6 @@
"dependencies": {
"jquery": "1.6",
"qunit": "1.0",
- "sproutcore-indexset": "2.0",
- "sproutcore-datetime": "2.0",
- "sproutcore-metal": "2.0",
- "sproutcore-runtime": "2.0",
- "sproutcore-views": "2.0",
- "sproutcore-datastore": "2.0",
- "sproutcore-handlebars": "2.0"... | true |
Other | emberjs | ember.js | 6b74623a85af5fe88cd30260f6453af626bf8486.json | Add overall sproutcore wrapper framework. | packages/sproutcore/lib/main.js | @@ -0,0 +1,10 @@
+// ==========================================================================
+// Project: SproutCore
+// Copyright: ©2011 Strobe Inc. and contributors.
+// License: Licensed under MIT license (see license.js)
+// ==========================================================================
+
+requir... | true |
Other | emberjs | ember.js | 6b74623a85af5fe88cd30260f6453af626bf8486.json | Add overall sproutcore wrapper framework. | packages/sproutcore/package.json | @@ -0,0 +1,11 @@
+{
+ "name": "sproutcore",
+ "description": "SproutCore - JavaScript Application Framework",
+ "version": "2.0",
+ "dependencies": {
+ "sproutcore-metal": "2.0",
+ "sproutcore-views": "2.0",
+ "sproutcore-datastore": "2.0",
+ "sproutcore-handlebars": "2.0"
+ }
+} | true |
Other | emberjs | ember.js | f5674b2e4aec71b4beb9336d4a66fa37ec0b6b44.json | Add indexset to global package.json for testing. | package.json | @@ -3,6 +3,7 @@
"dependencies": {
"jquery": "1.6",
"qunit": "1.0",
+ "sproutcore-indexset": "2.0",
"sproutcore-metal": "2.0",
"sproutcore-runtime": "2.0",
"sproutcore-views": "2.0", | false |
Other | emberjs | ember.js | c4839016aa566a21958e4649b9878615f2d2a284.json | Fix failing unit tests after rebase. | packages/sproutcore-handlebars/lib/controls/button.js | @@ -13,7 +13,7 @@ SC.Button = SC.View.extend({
tagName: 'button',
targetObject: function() {
- var target = this.get('target');
+ var target = get(this, 'target');
if (SC.typeOf(target) === "string") {
return SC.getPath(target); | true |
Other | emberjs | ember.js | c4839016aa566a21958e4649b9878615f2d2a284.json | Fix failing unit tests after rebase. | packages/sproutcore-handlebars/lib/controls/checkbox.js | @@ -7,6 +7,8 @@
require("sproutcore-views/views/view");
require("sproutcore-handlebars/ext");
+var set = SC.set, get = SC.get;
+
// TODO: Be explicit in the class documentation that you
// *MUST* set the value of a checkbox through SproutCore.
// Updating the value of a checkbox directly via jQuery objects
@@ -2... | true |
Other | emberjs | ember.js | c4839016aa566a21958e4649b9878615f2d2a284.json | Fix failing unit tests after rebase. | packages/sproutcore-handlebars/tests/controls/checkbox_test.js | @@ -68,11 +68,12 @@ test("checking the checkbox updates the value", function() {
checkboxView = SC.Checkbox.create({ value: true });
checkboxView.append();
- equals(checkboxView.get('value'), true, "precond - initially starts with a true value");
+ equals(get(checkboxView, 'value'), true, "precond - initially... | true |
Other | emberjs | ember.js | c4839016aa566a21958e4649b9878615f2d2a284.json | Fix failing unit tests after rebase. | packages/sproutcore-handlebars/tests/controls/text_field_test.js | @@ -66,7 +66,7 @@ test("value binding works properly for inputs that haven't been created", functi
});
});
- equals(get(textField, 'value'), "", "precond - default value is null");
+ equals(get(textField, 'value'), null, "precond - default value is null");
equals(textField.$('input').length, 0, "precond ... | true |
Other | emberjs | ember.js | c4839016aa566a21958e4649b9878615f2d2a284.json | Fix failing unit tests after rebase. | packages/sproutcore-handlebars/tests/views/collection_view_test.js | @@ -186,7 +186,7 @@ test("tagName works in the #collection helper", function() {
equals(view.$('li').length, 2, "rerenders with correct number of items");
SC.run(function() {
- view.childViews[0].set('content', ['bing', 'bat', 'bang']);
+ set(view.childViews[0], 'content', ['bing', 'bat', 'bang']);
});... | true |
Other | emberjs | ember.js | c5386b931e4fe302d8a86a2a5493fdf56d0f5b44.json | fix incorrect require paths | packages/sproutcore-metal/tests/suites/copyable/copy.js | @@ -4,7 +4,7 @@
// License: Licensed under MIT license (see license.js)
// ==========================================================================
-require('sproutcore-metal/~tests/suites/copyable/suite');
+require('sproutcore-metal/~tests/suites/copyable');
var suite = SC.CopyableTests;
| true |
Other | emberjs | ember.js | c5386b931e4fe302d8a86a2a5493fdf56d0f5b44.json | fix incorrect require paths | packages/sproutcore-metal/tests/suites/copyable/frozenCopy.js | @@ -4,7 +4,7 @@
// License: Licensed under MIT license (see license.js)
// ==========================================================================
-require('sproutcore-metal/~tests/suites/copyable/suite');
+require('sproutcore-metal/~tests/suites/copyable');
var suite = SC.CopyableTests;
| true |
Other | emberjs | ember.js | 06b851a09e42c7f73949547b057b732481e09628.json | Add destroyed method back to CoreObject | packages/sproutcore-metal/lib/system/core_object.js | @@ -14,6 +14,7 @@ require('sproutcore-metal/system/mixin');
var rewatch = SC.rewatch;
var classToString = SC.Mixin.prototype.toString;
+var set = SC.set, get = SC.get;
function makeCtor() {
@@ -61,6 +62,13 @@ Object.PrototypeMixin = SC.Mixin.create({
init: function() {},
+ isDestroyed: false,
+
+... | false |
Other | emberjs | ember.js | b0b3058ff84d7da0ae0ca6c5c2c694869bf2d22a.json | Add query dependency to views | packages/sproutcore-views/package.json | @@ -6,6 +6,7 @@
"author": "Yehuda Katz",
"version": "2.0",
"dependencies": {
+ "jquery": "1.6",
"sproutcore-runtime": "2.0",
"sproutcore-preprocessor": "~> 0.0.2"
}, | false |
Other | emberjs | ember.js | f8050dd3ac117545d24a8fbafe1651fa56b5f51e.json | Add qunit as a package (with a test runner) | packages/qunit/lib/qunit-runner.js | @@ -0,0 +1,34 @@
+/*globals QUnit spade */
+
+require('jquery');
+var qunit = require('./qunit');
+
+var packageName = location.search.match(/package=([^&]+)&?/)[1];
+
+if (!packageName) {
+ $('#qunit-header').text('Pass package=foo on URL to test package');
+} else {
+ require(packageName);
+ $.extend(window, qunit... | true |
Other | emberjs | ember.js | f8050dd3ac117545d24a8fbafe1651fa56b5f51e.json | Add qunit as a package (with a test runner) | packages/qunit/lib/qunit-style.css | @@ -0,0 +1,226 @@
+/**
+ * QUnit - A JavaScript Unit Testing Framework
+ *
+ * http://docs.jquery.com/QUnit
+ *
+ * Copyright (c) 2011 John Resig, Jörn Zaefferer
+ * Dual licensed under the MIT (MIT-LICENSE.txt)
+ * or GPL (GPL-LICENSE.txt) licenses.
+ */
+
+/** Font Family and Sizes */
+
+#qunit-tests, #qunit-header... | true |
Other | emberjs | ember.js | f8050dd3ac117545d24a8fbafe1651fa56b5f51e.json | Add qunit as a package (with a test runner) | packages/qunit/lib/qunit.js | @@ -0,0 +1,1448 @@
+/**
+ * QUnit - A JavaScript Unit Testing Framework
+ *
+ * http://docs.jquery.com/QUnit
+ *
+ * Copyright (c) 2011 John Resig, Jörn Zaefferer
+ * Dual licensed under the MIT (MIT-LICENSE.txt)
+ * or GPL (GPL-LICENSE.txt) licenses.
+ */
+
+(function(window) {
+
+var defined = {
+ setTimeout: typeof... | true |
Other | emberjs | ember.js | f8050dd3ac117545d24a8fbafe1651fa56b5f51e.json | Add qunit as a package (with a test runner) | packages/qunit/package.json | @@ -0,0 +1,7 @@
+{
+ "name": "qunit",
+ "version": "1.0.0",
+ "dependencies": {
+ "jquery": "1.6"
+ }
+} | true |
Other | emberjs | ember.js | fb2c6691ac9556c99566ed0487f915debf0b7502.json | Add jquery as an explicit package. | packages/jquery/lib/jquery.js | @@ -0,0 +1,18 @@
+/*!
+ * jQuery JavaScript Library v1.6.1
+ * http://jquery.com/
+ *
+ * Copyright 2011, John Resig
+ * Dual licensed under the MIT or GPL Version 2 licenses.
+ * http://jquery.org/license
+ *
+ * Includes Sizzle.js
+ * http://sizzlejs.com/
+ * Copyright 2011, The Dojo Foundation
+ * Released under the... | true |
Other | emberjs | ember.js | fb2c6691ac9556c99566ed0487f915debf0b7502.json | Add jquery as an explicit package. | packages/jquery/lib/main.js | @@ -0,0 +1 @@
+require('./jquery'); | true |
Other | emberjs | ember.js | fb2c6691ac9556c99566ed0487f915debf0b7502.json | Add jquery as an explicit package. | packages/jquery/package.json | @@ -0,0 +1,5 @@
+{
+ "name": "jquery",
+ "description": "Simple DOM iteration",
+ "version": "1.6"
+}
\ No newline at end of file | true |
Other | emberjs | ember.js | 35390fdb51f25189e302108477b2ec3a708924fb.json | Test the keyUp method | lib/sproutcore-handlebars/lib/controls/text_field.js | @@ -1,3 +1,4 @@
+require("sproutcore-handlebars/ext");
require("sproutcore-views/views/view");
/** @class */
@@ -10,7 +11,7 @@ SC.TextField = SC.View.extend(
cancel: function(event) { },
type: "text",
- value: null,
+ value: "",
placeholder: null,
defaultTemplate: function() {
@@ -29,17 +30,21 @@ ... | true |
Other | emberjs | ember.js | 35390fdb51f25189e302108477b2ec3a708924fb.json | Test the keyUp method | lib/sproutcore-handlebars/tests/controls/text_field_test.js | @@ -51,21 +51,49 @@ test("input type is configurable when creating view", function() {
});
test("value binding works properly for inputs that haven't been created", function() {
- var view = SC.TextField.create({
+ textField = SC.TextField.create({
valueBinding: 'TestObject.value'
});
- equals(view.get... | true |
Other | emberjs | ember.js | b152cc8ae2b332c526367ef95982038de4ad7f8f.json | Add required dependency | lib/sproutcore-handlebars/lib/controls/checkbox.js | @@ -1,4 +1,5 @@
require("sproutcore-views/views/view");
+require("sproutcore-handlebars/ext");
// TODO: Be explicit in the class documentation that you
// *MUST* set the value of a checkbox through SproutCore. | false |
Other | emberjs | ember.js | 1eab95116f8bf710020ec549fb81e242084d10db.json | Add all.js to gitignore. | .gitignore | @@ -5,5 +5,5 @@ Gemfile.lock
spade-boot.js
docs/jsdoc
docs/output
-tests/all.js
+lib/*/tests/all.js
test_*.html | false |
Other | emberjs | ember.js | f258fc8366a4449f3fff2e62aea9013ce74c08ce.json | Reduce time waiting for server to boot | Rakefile | @@ -110,7 +110,7 @@ end
def spade_preview_task(package, deps)
task package => deps do
$threads << Thread.new { sh "cd lib/#{package} && spade preview" }
- sleep 5
+ sleep 3
sh "open http://localhost:4020/test_#{package}.html"
$threads.each(&:join)
end | false |
Other | emberjs | ember.js | d2aa28541d4192a91ba520b2072823874efb103d.json | Fix @each on non-Array-controllers from the root | lib/sproutcore-runtime/lib/mixins/array.js | @@ -474,6 +474,7 @@ SC.CoreArray =
this._teardownContentObservers(start, removedCount);
var willChangeObservers = this._kvo_array_will_change;
this._notifyArrayObservers(willChangeObservers, start, removedCount, addedCount);
+ this.teardownEnumerablePropertyChains(start, removedCount);
},
/** ... | true |
Other | emberjs | ember.js | d2aa28541d4192a91ba520b2072823874efb103d.json | Fix @each on non-Array-controllers from the root | lib/sproutcore-runtime/lib/private/property_chain.js | @@ -80,6 +80,28 @@ SC._PropertyChain = SC.Object.extend(
*/
nextProperty: null,
+ /**
+ @type Boolean
+ @default true
+ */
+ isCopyable: true,
+
+ /**
+ @type Boolean
+ @default true
+ */
+ copy: function() {
+ var ret = SC._PropertyChain.create();
+
+ for (var prop in this) {
+ if ... | true |
Other | emberjs | ember.js | 5e0efb0edd83e4a86d7df2d3d419d88183051ab9.json | Fix escaping of {{mustaches}} and {{{mustaches}}}. | lib/sproutcore-handlebars/lib/ext.js | @@ -32,6 +32,10 @@ require("handlebars");
Note that you won't usually need to use SC.Handlebars yourself. Instead, use
SC.View, which takes care of integration into the view layer for you.
*/
+
+require("handlebars");
+require("sproutcore-views/system/render_buffer");
+
SC.Handlebars = {};
SC.Handlebars.Comp... | true |
Other | emberjs | ember.js | 5e0efb0edd83e4a86d7df2d3d419d88183051ab9.json | Fix escaping of {{mustaches}} and {{{mustaches}}}. | lib/sproutcore-handlebars/lib/helpers/binding.js | @@ -29,7 +29,8 @@ require('sproutcore-handlebars/views/bindable_span');
displayTemplate: fn,
inverseTemplate: inverse,
property: property,
- previousContext: this
+ previousContext: this,
+ isEscaped: options.hash.escaped
});
view.get('childViews').push(bi... | true |
Other | emberjs | ember.js | 5e0efb0edd83e4a86d7df2d3d419d88183051ab9.json | Fix escaping of {{mustaches}} and {{{mustaches}}}. | lib/sproutcore-handlebars/lib/views/bindable_span.js | @@ -104,6 +104,10 @@ SC._BindableSpanView = SC.View.extend(
@param {SC.RenderBuffer} buffer
*/
render: function(buffer) {
+ // If not invoked via a triple-mustache ({{{foo}}}), escape
+ // the content of the template.
+ if(this.get('isEscaped')) { buffer.set('escapeContent', true); }
+
var shou... | true |
Other | emberjs | ember.js | 5e0efb0edd83e4a86d7df2d3d419d88183051ab9.json | Fix escaping of {{mustaches}} and {{{mustaches}}}. | lib/sproutcore-handlebars/tests/handlebars_test.js | @@ -66,6 +66,32 @@ test("should allow values from normal JavaScript hash objects to be used", funct
equals(view.$().text(), "Señor CFC (and Fido)", "prints out values from a hash");
});
+test("should escape HTML in normal mustaches", function() {
+ var view = SC.View.create({
+ template: SC.Handlebars.compile... | true |
Other | emberjs | ember.js | 5e0efb0edd83e4a86d7df2d3d419d88183051ab9.json | Fix escaping of {{mustaches}} and {{{mustaches}}}. | lib/sproutcore-views/lib/system/render_buffer.js | @@ -59,9 +59,24 @@ SC._RenderBuffer = SC.Object.extend(
elementStyle: null,
/**
- @type SC.RenderBuffer
- @default null
+ RenderBuffer supports plugging in escaping functionality via
+ the boolean `escapeContent` property and the `escapeFunction`
+ property.
+
+ If `escapeContent` is set to tr... | true |
Other | emberjs | ember.js | 4b612aa3c46c973b91df14835d95c9023fabc65a.json | Add handlebars to exclusion list | docs/sc.conf | @@ -9,7 +9,7 @@
v: true,
// exclude tests or private
- E: ["docs/", "tests/", "private/", "tmp/"],
+ E: ["docs/", "handlebars/", "tests/", "private/", "tmp/"],
// some extra variables I want to include
D: {generatedBy: "SproutCore", copyright: "2011"}, | false |
Other | emberjs | ember.js | dc09141f4bb0c5f81774b142efacb46162b82ca1.json | Fix documentation in sproutcore-views | lib/sproutcore-views/lib/system/application.js | @@ -8,6 +8,8 @@
require("sproutcore-views/system/event_dispatcher");
/**
+ @class
+
An SC.Application instance serves as the namespace in which you define your
application's classes. You can also override the configuration of your
application.
@@ -28,9 +30,13 @@ require("sproutcore-views/system/event_disp... | true |
Other | emberjs | ember.js | dc09141f4bb0c5f81774b142efacb46162b82ca1.json | Fix documentation in sproutcore-views | lib/sproutcore-views/lib/system/event_dispatcher.js | @@ -6,16 +6,18 @@
// ==========================================================================
/**
- @private
+ @ignore
SC.EventDispatcher handles delegating browser events to their corresponding
SC.Views. For example, when you click on a view, SC.EventDispatcher ensures
that that view's `mouseDown` m... | true |
Other | emberjs | ember.js | dc09141f4bb0c5f81774b142efacb46162b82ca1.json | Fix documentation in sproutcore-views | lib/sproutcore-views/lib/system/render_buffer.js | @@ -5,22 +5,64 @@
// License: Licensed under MIT license (see license.js)
// ==========================================================================
+/*
+ TODO Document SC.RenderBuffer class itself
+*/
+
+/**
+ @class
+ @extends SC.Object
+*/
SC.RenderBuffer = function(tagName) {
return SC._RenderBuffer... | true |
Other | emberjs | ember.js | dc09141f4bb0c5f81774b142efacb46162b82ca1.json | Fix documentation in sproutcore-views | lib/sproutcore-views/lib/views/collection_view.js | @@ -1,43 +1,67 @@
+// ==========================================================================
+// Project: SproutCore - JavaScript Application Framework
+// Copyright: ©2006-2011 Strobe Inc. and contributors.
+// Portions ©2008-2011 Apple Inc. All rights reserved.
+// License: Licensed under MIT licen... | true |
Other | emberjs | ember.js | dc09141f4bb0c5f81774b142efacb46162b82ca1.json | Fix documentation in sproutcore-views | lib/sproutcore-views/lib/views/view.js | @@ -7,17 +7,32 @@
require("sproutcore-views/system/render_buffer");
-// Global hash of shared templates. This will automatically be populated
-// by the build tools so that you can store your Handlebars templates in
-// separate files that get loaded into JavaScript at buildtime.
+/**
+ @static
+
+ Global hash o... | true |
Other | emberjs | ember.js | bb4492a3ca9afe2680d5d37b2d01238e74972a3c.json | Fix typo: view => emptyView | lib/sproutcore-views/lib/views/collection_view.js | @@ -151,7 +151,7 @@ SC.CollectionView = SC.View.extend({
this.set('emptyView', emptyView);
emptyView.createElement().$().appendTo(elem);
- this.childViews = [view];
+ this.childViews = [emptyView];
}
}
}); | false |
Other | emberjs | ember.js | 456ac96f9f4876a84e345301f0d1a2c9175ae782.json | Update Rakefile to build SC single-file JS | Rakefile | @@ -1,10 +1,70 @@
require "bundler/setup"
require "sproutcore"
+def uglify(string)
+ IO.popen("uglifyjs", "r+") do |io|
+ io.puts string
+ io.close_write
+ return io.read
+ end
+end
+
SproutCore::Compiler.intermediate = "tmp/intermediate"
SproutCore::Compiler.output = "tmp/static"
-tasks = Sprout... | false |
Other | emberjs | ember.js | ceb66b5505674f29534552adf72d69d819c322a0.json | Add support for classNameBindings in SC.View. | lib/sproutcore-views/lib/views/view.js | @@ -15,7 +15,7 @@ SC.TEMPLATES = SC.Object.create();
SC.View = SC.Object.extend(
/** @scope SC.View.prototype */ {
- concatenatedProperties: ['classNames'],
+ concatenatedProperties: ['classNames', 'classNameBindings'],
/** walk like a duck */
isView: YES,
@@ -145,6 +145,105 @@ SC.View = SC.Object.extend(... | true |
Other | emberjs | ember.js | ceb66b5505674f29534552adf72d69d819c322a0.json | Add support for classNameBindings in SC.View. | lib/sproutcore-views/tests/views/view/class_name_bindings_test.js | @@ -0,0 +1,42 @@
+require('sproutcore-views/views/view');
+
+module("SC.View - Bound Class Names");
+
+test("should apply bound class names to the element", function() {
+ var view = SC.View.create({
+ classNameBindings: ['priority', 'isUrgent', 'isClassified:classified', 'canIgnore'],
+
+ priority: 'high',
+ ... | true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.