Sha256: 6d91691b0094622781c2481d6a5849684ce0ce81da152f7902a00c98c1aef199

Contents?: true

Size: 511 Bytes

Versions: 5

Compression:

Stored size: 511 Bytes

Contents

ready = ->

  jQuery.fn.apply_initial_auto_hide = ->

    # The tool buttons and the .show_only_in_edit_mode elements first are hidden via css (in case JavaScript does not work).
    # In order to use .hide() and .show() of jQuery, we need to restore the display css property
    # and hide the elements via jQuery.
    this.find( ".save_button,.cancel_button,.show_only_in_edit_mode" ).css( "visibility", "visible" ).hide()

    return this

  $( document ).apply_initial_auto_hide()

$(document).ready(ready)

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
edit_mode-1.0.5 lib/assets/javascripts/edit_mode/initial_auto_hide.js.coffee
edit_mode-1.0.4 lib/assets/javascripts/edit_mode/initial_auto_hide.js.coffee
edit_mode-1.0.3 lib/assets/javascripts/edit_mode/initial_auto_hide.js.coffee
edit_mode-1.0.2 lib/assets/javascripts/edit_mode/initial_auto_hide.js.coffee
edit_mode-1.0.1 lib/assets/javascripts/edit_mode/initial_auto_hide.js.coffee