mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2025-10-11 03:24:12 +02:00
No need for spaces after npubs anymore
This commit is contained in:
@@ -189,7 +189,7 @@ class NewPostViewModel : ViewModel() {
|
|||||||
userSuggestionAnchor?.let {
|
userSuggestionAnchor?.let {
|
||||||
val lastWord = message.text.substring(0, it.end).substringAfterLast("\n").substringAfterLast(" ")
|
val lastWord = message.text.substring(0, it.end).substringAfterLast("\n").substringAfterLast(" ")
|
||||||
val lastWordStart = it.end - lastWord.length
|
val lastWordStart = it.end - lastWord.length
|
||||||
val wordToInsert = "@${item.pubkeyNpub()} "
|
val wordToInsert = "@${item.pubkeyNpub()}"
|
||||||
|
|
||||||
message = TextFieldValue(
|
message = TextFieldValue(
|
||||||
message.text.replaceRange(lastWordStart, it.end, wordToInsert),
|
message.text.replaceRange(lastWordStart, it.end, wordToInsert),
|
||||||
|
Reference in New Issue
Block a user