diff options
author | Rachel H <rainyday@users.noreply.github.com> | 2017-04-12 09:21:07 -0700 |
---|---|---|
committer | Eugen <eugen@zeonfederated.com> | 2017-04-12 18:21:07 +0200 |
commit | 0930ce5560749f5ede3aa70aef4130ad1a9dc6ba (patch) | |
tree | fee869622b2b1a176074809c94d92978c2e0bd10 | |
parent | 7f0a865b05628fa82ac692ec9a21c418e30dac14 (diff) |
Focus textarea when text is inserted (#1320)
Place space after uploaded filenames
-rw-r--r-- | .gitignore | 4 | ||||
-rw-r--r-- | app/assets/javascripts/components/reducers/compose.jsx | 3 |
2 files changed, 6 insertions, 1 deletions
diff --git a/.gitignore b/.gitignore index 6d540c413..b671bcb96 100644 --- a/.gitignore +++ b/.gitignore @@ -28,3 +28,7 @@ neo4j/ # Ignore Capistrano customizations config/deploy/* + + +# Ignore IDE files +.vscode/ diff --git a/app/assets/javascripts/components/reducers/compose.jsx b/app/assets/javascripts/components/reducers/compose.jsx index 4470ad643..00cc758a5 100644 --- a/app/assets/javascripts/components/reducers/compose.jsx +++ b/app/assets/javascripts/components/reducers/compose.jsx @@ -76,7 +76,8 @@ function appendMedia(state, media) { map.update('media_attachments', list => list.push(media)); map.set('is_uploading', false); map.set('resetFileKey', Math.floor((Math.random() * 0x10000))); - map.update('text', oldText => `${oldText} ${media.get('text_url')}`.trim()); + map.set('focusDate', new Date()); + map.update('text', oldText => `${oldText.trim()} ${media.get('text_url')}`.trim() + ' '); }); }; |