Sha256: f995f270bfd63da44b9578c675dc5636833432f2557e0f2c77da4c42a588978c
Contents?: true
Size: 980 Bytes
Versions: 19
Compression:
Stored size: 980 Bytes
Contents
class Backbone.Poised.LinkedStringControl extends Backbone.Poised.LinkedControl initialize: (options = {}) => super @options = _.chain(options) .pick('attribute', 'rows', 'placeholder') .defaults type: 'text' placeholder: null rows: 1 .value() render: => super if @options.rows > 1 @subviews.textarea1 = new Backbone.Poised.Textarea(_.defaults(model: @model1, @options)) @$control1.append(@subviews.textarea1.render().el) @subviews.textarea2 = new Backbone.Poised.Textarea(_.defaults(model: @model2, @options)) @$control2.append(@subviews.textarea2.render().el) else @subviews.textfield1 = new Backbone.Poised.Textfield(_.defaults(model: @model1, @options)) @$control1.append(@subviews.textfield1.render().el) @subviews.textfield2 = new Backbone.Poised.Textfield(_.defaults(model: @model2, @options)) @$control2.append(@subviews.textfield2.render().el) this
Version data entries
19 entries across 19 versions & 1 rubygems