Refactoring

This commit is contained in:
Ali
2021-04-18 20:15:23 +04:00
parent 0ab87d6bbc
commit 2efced46b3
50 changed files with 301 additions and 298 deletions

View File

@@ -644,10 +644,10 @@ class ChatMessageTextBubbleContentNode: ChatMessageBubbleContentNode {
func animateFrom(sourceView: UIView, widthDifference: CGFloat, transition: ContainedViewLayoutTransition) {
self.view.addSubview(sourceView)
sourceView.layer.animateAlpha(from: 1.0, to: 0.0, duration: 0.15, removeOnCompletion: false, completion: { [weak sourceView] _ in
sourceView.layer.animateAlpha(from: 1.0, to: 0.0, duration: 0.1, removeOnCompletion: false, completion: { [weak sourceView] _ in
sourceView?.removeFromSuperview()
})
self.textNode.layer.animateAlpha(from: 0.0, to: 1.0, duration: 0.1)
self.textNode.layer.animateAlpha(from: 0.0, to: 1.0, duration: 0.08)
let offset = CGPoint(
x: sourceView.frame.minX - (self.textNode.frame.minX - 0.0),