Skip to content
This repository has been archived by the owner on Feb 4, 2022. It is now read-only.

Commit

Permalink
🐛 Fix cursor jumping to text start after community autocompletion
Browse files Browse the repository at this point in the history
  • Loading branch information
Komposten committed Jun 19, 2020
1 parent c42cf19 commit f397d31
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/services/text_autocompletion.dart
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ class TextAutocompletionService {
'c/$communityName ' +
text.substring(cursorPosition);
var newSelection = TextSelection.collapsed(
offset: cursorPosition - lastWord.length + communityName.length + 4);
offset: cursorPosition - lastWord.length + communityName.length + 3);

textController.value =
TextEditingValue(text: newText, selection: newSelection);
Expand Down

0 comments on commit f397d31

Please sign in to comment.