We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 3902c50 + 0c3319d commit 3a56882Copy full SHA for 3a56882
1 file changed
addon/components/ember-inline-edit.js
@@ -29,6 +29,7 @@ export default Component.extend({
29
30
showSaveButton: true,
31
showCancelButton: true,
32
+ saveOnFocusOut: false,
33
34
editorClass: '',
35
buttonContainerClass: '',
@@ -64,7 +65,11 @@ export default Component.extend({
64
65
if (this.onOutsideClick) {
66
this.onOutsideClick(this.value) && set(this, 'isEditing', false)
67
} else {
- this.send('cancel')
68
+ if(this.saveOnFocusOut) {
69
+ this.send('save')
70
+ } else {
71
+ this.send('cancel')
72
+ }
73
}
74
75
},
0 commit comments