Sha256: 1e84096c85ea42881a1ea356f3cd9403caf680635e5538bf6e3270aad5ae6369
Contents?: true
Size: 748 Bytes
Versions: 14
Compression:
Stored size: 748 Bytes
Contents
$(document).ready(function() { var enableNav = function() { $('#editable-elements .nav a').click(function(e) { var index = parseInt($(this).attr('href').match(/block-(.+)/)[1]); $('#editable-elements .wrapper ul li.block').hide(); $('#block-' + index).show(); $(this).parent().find('.on').removeClass('on'); $(this).addClass('on'); e.preventDefault(); }); } enableNav(); $.subscribe('form.saved.success', function(event, data) { if (data.editable_elements != '') { $('#editable-elements').replaceWith(data.editable_elements); enableNav(); $('textarea.html').tinymce(TinyMceDefaultSettings); } }, []); $('textarea.html').tinymce(TinyMceDefaultSettings); });
Version data entries
14 entries across 14 versions & 1 rubygems