Skip to content

Instantly share code, notes, and snippets.

View SwCake1's full-sized avatar
🎯
Focusing

Vladislav Samokhin SwCake1

🎯
Focusing
View GitHub Profile
override func animateLayoutTransition(_ context: ASContextTransitioning) {
if textNode.text == "" {
let finalTextFrame = context.finalFrame(for: textNode)
var finalButtonFrame = context.initialFrame(for: cancelButton)
finalButtonFrame.origin.x = UIScreen.main.bounds.width
UIView.animate(withDuration: 0.1, animations: {