X-Git-Url: https://git.mdrn.pl/fnpeditor.git/blobdiff_plain/413a5f1dc25d5c8a788127f40816f39c49cd0d1c..cc4f5cb5ab7df9decf14fbbcbe2736a9d76ef294:/src/editor/views/dialog/dialog.js?ds=sidebyside diff --git a/src/editor/views/dialog/dialog.js b/src/editor/views/dialog/dialog.js index 0d4bbd4..04d8f74 100644 --- a/src/editor/views/dialog/dialog.js +++ b/src/editor/views/dialog/dialog.js @@ -38,7 +38,7 @@ define(function(require) { throw new Error('Field type {type} not recognized.'.replace('{type}', field.type)); } body.append( - _.template(template)(_.extend({description: ''}, field)) + _.template(template)(_.extend({description: '', initialValue: ''}, field)) ); }); @@ -48,7 +48,7 @@ define(function(require) { this.$el.modal({backdrop: 'static'}); this.$el.modal('show'); - this.$('textarea').focus(); + this.$('textarea, input').first().focus(); }, onExecute: function(e) { e.preventDefault();