Adding the missing search element
This commit is contained in:
@@ -214,8 +214,8 @@ open class NewPostViewModel : ViewModel() {
|
|||||||
userSuggestionAnchor = it.selection
|
userSuggestionAnchor = it.selection
|
||||||
userSuggestionsMainMessage = true
|
userSuggestionsMainMessage = true
|
||||||
if (lastWord.startsWith("@") && lastWord.length > 2) {
|
if (lastWord.startsWith("@") && lastWord.length > 2) {
|
||||||
|
NostrSearchEventOrUserDataSource.search(lastWord.removePrefix("@"))
|
||||||
userSuggestions = LocalCache.findUsersStartingWith(lastWord.removePrefix("@")).sortedWith(compareBy({ account?.isFollowing(it) }, { it.toBestDisplayName() })).reversed()
|
userSuggestions = LocalCache.findUsersStartingWith(lastWord.removePrefix("@")).sortedWith(compareBy({ account?.isFollowing(it) }, { it.toBestDisplayName() })).reversed()
|
||||||
println("AAAA" + lastWord.removePrefix("@") + userSuggestions.size)
|
|
||||||
} else {
|
} else {
|
||||||
NostrSearchEventOrUserDataSource.clear()
|
NostrSearchEventOrUserDataSource.clear()
|
||||||
userSuggestions = emptyList()
|
userSuggestions = emptyList()
|
||||||
|
|||||||
Reference in New Issue
Block a user