   checkPageType()
   sortableBrick()
   initSubmitLinks()
+  handleMagicReadMore()
+
   $('#page_page_type').change ->
     checkPageType()
-

        sortForm.trigger('submit')
      )

window.initSubmitLinks = (selector = null)->
  selector ||= $('body')


    , 1500
  , 50

handleMagicReadMore = ->
  $('.simple_form.edit_brick').submit ->
  removeEmptyParagraphs()

$(document).ajaxSuccess ->
  loadTextEditor($("body"))
  handleMagicReadMore()
  sortableBrick()

$(document).ready ->
