     e.preventDefault()
 
     if confirm 'Are you sure?'
-      @model.destroy(wait: yes)
+      @model.destroy(wait: yes).done =>
+        @keepElement = yes
+
+  dispose: ->
+    if @keepElement and @$el
+      $el = @$el.css position: 'absolute', width: '100%'
+      TweenLite.to $el, .25,
+        scale: .8
+        opacity: 0
+        y: '+300px'
+        rotate: '3deg'
+        onComplete: ->
+          $el.remove()
+
+    super
 
   @mixin FormMixin

      fields: fields
      newTitle: "New #{@bucket.get('singular')}"

  submitForm: (e) ->
    e.preventDefault()
    @submit @model.save(@formParams(), wait: yes)

tpl = require 'templates/entries/edit'

module.exports = class EntryEditView extends PageView
  template: tpl
  optionNames: PageView::optionNames.concat ['bucket', 'user']

