Sha256: 661b448910127d7bdf5caba33ed8690248d056e71dcf336bac0d75143db0daad
Contents?: true
Size: 731 Bytes
Versions: 19
Compression:
Stored size: 731 Bytes
Contents
# These next three methods hijack jquery_ujs data-confirm and do it our own way with a double click confirm if <%= !!EffectiveBootstrap.use_custom_data_confirm %> && $.rails $(document).on 'confirm', (event) -> $obj = $(event.target) if $obj.data('confirmed') true else $obj.data('confirm-original', $obj.html()) $obj.html($obj.data('confirm')) $obj.data('confirmed', true) setTimeout( (-> $obj.data('confirmed', false) $obj.html($obj.data('confirm-original')) ) , 4000) false # don't show the confirmation dialog $.rails.confirm = (message) -> true $(document).on 'confirm:complete', (event) -> $(event.target).data('confirmed')
Version data entries
19 entries across 19 versions & 1 rubygems