Sha256: ec3ad11df4ebc921654866a61d5dae853e384540f38019a4ca2ce3ccaeb511e3

Contents?: true

Size: 511 Bytes

Versions: 12

Compression:

Stored size: 511 Bytes

Contents

class Tenon.features.tenonContent.BottombarToggler
  constructor: (@$container) ->
    @_toggleBottombars()
    $(document).on('cocoon:after-insert', '.tenon-content', @_toggleBottombars)
    $(document).on('cocoon:after-remove', '.tenon-content', @_toggleBottombars)

  _toggleBottombars: =>
    # Hide them all
    @$container.find('.tn-tc-bottombar').hide()

    # Then show the one in the last visible row
    @$container
      .find('.tn-tc-row:visible:last')
      .find('.tn-tc-bottombar')
      .show()

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
tenon-1.1.8 app/assets/javascripts/tenon/features/tenon_content/bottombar_toggler.js.coffee
tenon-1.1.7 app/assets/javascripts/tenon/features/tenon_content/bottombar_toggler.js.coffee
tenon-1.1.6 app/assets/javascripts/tenon/features/tenon_content/bottombar_toggler.js.coffee
tenon-1.1.5 app/assets/javascripts/tenon/features/tenon_content/bottombar_toggler.js.coffee
tenon-1.1.4 app/assets/javascripts/tenon/features/tenon_content/bottombar_toggler.js.coffee
tenon-1.1.3 app/assets/javascripts/tenon/features/tenon_content/bottombar_toggler.js.coffee
tenon-1.1.2 app/assets/javascripts/tenon/features/tenon_content/bottombar_toggler.js.coffee
tenon-1.1.1 app/assets/javascripts/tenon/features/tenon_content/bottombar_toggler.js.coffee
tenon-1.0.76 app/assets/javascripts/tenon/features/tenon_content/bottombar_toggler.js.coffee
tenon-1.0.75 app/assets/javascripts/tenon/features/tenon_content/bottombar_toggler.js.coffee
tenon-1.0.74 app/assets/javascripts/tenon/features/tenon_content/bottombar_toggler.js.coffee
tenon-1.0.73 app/assets/javascripts/tenon/features/tenon_content/bottombar_toggler.js.coffee