 
   didChangeSelection: ->
     triggerEvent("selectionchange", onElement: @element, bubbles: false)
+
+  # Private
+
+  saveAndNotify: =>
+    @save()
+    triggerEvent("input", onElement: @element)

    @save()

  didEditAttachment: (attachment) ->
    @save()

  didRemoveAttachment: (attachment) ->
    triggerEvent("trix-attachment-remove", onElement: @element, attributes: {attachment})

    @save()

  didChangeDocument: (document) ->
    defer @saveAndNotify

  shouldAcceptFile: (file) ->
    triggerEvent("trix-file-accept", onElement: @element, attributes: {file})
