diff options
author | Chris <ccbrown112@gmail.com> | 2017-08-03 19:40:53 -0500 |
---|---|---|
committer | Joram Wilander <jwawilander@gmail.com> | 2017-08-03 20:40:53 -0400 |
commit | e06686dbf4173e5f1af672209037642166ac0ba5 (patch) | |
tree | e9f63fa5a688e718f70b40daf218d72244ea8bf5 /webapp/components | |
parent | df1ff4ec977b76587dfc50885874f08fd9748071 (diff) | |
download | chat-e06686dbf4173e5f1af672209037642166ac0ba5.tar.gz chat-e06686dbf4173e5f1af672209037642166ac0ba5.tar.bz2 chat-e06686dbf4173e5f1af672209037642166ac0ba5.zip |
fix caret position after autocomplete (#7118)
Diffstat (limited to 'webapp/components')
-rw-r--r-- | webapp/components/suggestion/suggestion_box.jsx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/webapp/components/suggestion/suggestion_box.jsx b/webapp/components/suggestion/suggestion_box.jsx index 008fc2ffb..11fda2643 100644 --- a/webapp/components/suggestion/suggestion_box.jsx +++ b/webapp/components/suggestion/suggestion_box.jsx @@ -275,7 +275,7 @@ export default class SuggestionBox extends React.Component { // set the caret position after the next rendering window.requestAnimationFrame(() => { if (textbox.value === newValue) { - Utils.setCaretPosition(textbox, newValue.length); + Utils.setCaretPosition(textbox, prefix.length + term.length + 1); } }); |