Editor: Fix lag

This commit is contained in:
Thomas Ricouard 2024-01-15 15:03:28 +01:00
parent a8f8933e11
commit d9f115ba67

View file

@ -591,11 +591,16 @@ extension StatusEditor {
} }
private func resetAutoCompletion() { private func resetAutoCompletion() {
withAnimation { if !tagsSuggestions.isEmpty ||
tagsSuggestions = [] !mentionsSuggestions.isEmpty ||
mentionsSuggestions = [] currentSuggestionRange != nil ||
currentSuggestionRange = nil showRecentsTagsInline {
showRecentsTagsInline = false withAnimation {
tagsSuggestions = []
mentionsSuggestions = []
currentSuggestionRange = nil
showRecentsTagsInline = false
}
} }
} }