mirror of
https://github.com/element-hq/element-x-ios.git
synced 2025-03-11 13:59:13 +00:00
Remove reaction summary view scroll animation, keep the buttons in sync with manual horizontal scrolling
This commit is contained in:
parent
2354f4ff99
commit
29cda71b82
@ -43,9 +43,7 @@ struct ReactionsSummaryView: View {
|
||||
HStack {
|
||||
ForEach(reactions, id: \.self) { reaction in
|
||||
ReactionSummaryButton(reaction: reaction, highlighted: selectedReactionKey == reaction.key) { key in
|
||||
withAnimation(.easeInOut) {
|
||||
selectedReactionKey = key
|
||||
}
|
||||
selectedReactionKey = key
|
||||
}
|
||||
.id(reaction.key)
|
||||
}
|
||||
@ -54,6 +52,9 @@ struct ReactionsSummaryView: View {
|
||||
.onAppear {
|
||||
scrollView.scrollTo(selectedReactionKey, anchor: .leading)
|
||||
}
|
||||
.onChange(of: selectedReactionKey) { _ in
|
||||
scrollView.scrollTo(selectedReactionKey)
|
||||
}
|
||||
}
|
||||
}
|
||||
.padding(.top, 24)
|
||||
|
Loading…
x
Reference in New Issue
Block a user