     @model.get "id"
 
 
+  showUnsavedNotification: ->
+    @saveButton.text "Save*"
+  removeUnsavedNotification: ->
+    @saveButton.text "Save"
 
   save: ->
     html = @editor.getSession().getValue()

    @model.save null,
      success: (e) =>
        @model.trigger "saved", @model

        if not @hasEditUrl()
          window.location.hash = "#edit/#{ @model.get("id") }"

    @editor = ace.edit "editor"
    @editor.setShowPrintMargin false
    HTMLmode = require("ace/mode/html").Mode
    session = @editor.getSession()
    session.setTabSize(2);
    # session.setUseWrapMode(true);
    session.setMode(new HTMLmode())


    # Hide the line numbering, doesn't work perfectly
