From ba9745a6eb0eeeb42a5bcd99e4b0a2b3d308e855 Mon Sep 17 00:00:00 2001 From: Greg Guthe Date: Thu, 5 Sep 2013 00:22:51 -0400 Subject: [PATCH] Save commit message on keyup Refs: #1775 --- js/id/ui/commit.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/js/id/ui/commit.js b/js/id/ui/commit.js index c813d1cf8..6ba09910d 100644 --- a/js/id/ui/commit.js +++ b/js/id/ui/commit.js @@ -52,7 +52,10 @@ iD.ui.Commit = function(context) { var commentField = commentSection.append('textarea') .attr('placeholder', t('commit.description_placeholder')) - .property('value', context.storage('comment') || ''); + .property('value', context.storage('comment') || '') + .on('keyup.save', function () { + context.storage('comment', this.value); + }); commentField.node().select();