File: property.coffee
Defined in: | template |
Method Summary
- ? Gunther.Template.prototype.attribute(name, value) #
- ? Gunther.Template.prototype.boundAttribute(args...) Add a DOM attribute which is "bound" to a model's attribute
- ? Gunther.Template.prototype.property(name, value) Set a property note: this differs from attributes, as per jQuery's API.
- ? Gunther.Template.prototype.boundProperty(args...) Add a property which is "bound" Pass it the property's name, the model, the property, and optionally a value generating function
-
? Gunther.Template.prototype.css(name, value)
Set a style property This method accepts both an object of the form
cssKey: value
or a single name/value pair - ? Gunther.Template.prototype.boundCss(args...) Bind a CSS property to a model's property or properties
- ? Gunther.Template.prototype.toggleClass(className, model, property, toggle) Toggle an element's class based on a property (or set of properties)
Method Details
? Gunther.Template.prototype.attribute(name, value) Source
Public
Properties and Attributes
Set an attribute
Uses jQuery's attr()
method
? Gunther.Template.prototype.boundAttribute(args...) Source
Add a DOM attribute which is "bound" to a model's attribute
? Gunther.Template.prototype.property(name, value) Source
Set a property
note: this differs from attributes, as per jQuery's API. Use this for
properties like checked
on a checkbox
? Gunther.Template.prototype.boundProperty(args...) Source
Add a property which is "bound"
Pass it the property's name, the model, the property, and optionally a value generating function
? Gunther.Template.prototype.css(name, value) Source
Set a style property
This method accepts both an object of the form cssKey: value
or a single
name/value pair
? Gunther.Template.prototype.boundCss(args...) Source
Bind a CSS property to a model's property or properties
? Gunther.Template.prototype.toggleClass(className, model, property, toggle) Source
Toggle an element's class based on a property (or set of properties)