Sha256: d3912c2236eb2f106b13fc434f12b1427f3ab166401752d6a374e3283eed2848

Contents?: true

Size: 554 Bytes

Versions: 3

Compression:

Stored size: 554 Bytes

Contents

#= require tao/form/shared/fields/moment_picker/result/base

class Tao.Form.MomentPicker.Result extends Tao.Form.MomentPicker.ResultBase

  @attribute 'active', type: 'boolean'

  _connected: ->
    super
    @jq.attr('tabindex', '0') unless @disabled

  _bind: ->
    super

    @on 'click', '.link-clear', (e) =>
      return if @disabled
      @clear() && @trigger('clear')
      false

  _disabledChanged: ->
    if @disabled
      @jq.removeAttr 'tabindex'
    else
      @jq.attr 'tabindex', '0'

TaoComponent.register Tao.Form.MomentPicker.Result

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
tao_form-0.1.2 lib/assets/javascripts/tao/form/fields/moment_picker/result.coffee
tao_form-0.1.1 lib/assets/javascripts/tao/form/fields/moment_picker/result.coffee
tao_form-0.1.0 lib/assets/javascripts/tao/form/fields/moment_picker/result.coffee