Ramotion / folding-cell

:octocat: πŸ“ƒ FoldingCell is an expanding content cell with animation made by @Ramotion

Home Page:https://www.ramotion.com/folding-cell/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Weird animation with last cells

penpens opened this issue Β· comments

Hi,
First of all thanks for this repo πŸ˜„
I just have to report a weird animation with the last cells.
I attach a video of the animation.
Cheers

https://streamable.com/fi0o4

Hi penpens,
I had the same issue. The weird animation is more related to the UITableView behaviour, rather than to the folding cell.
This solved my issue - https://forums.developer.apple.com/thread/86703

fix that works for me
if func tableView(didselectrowat...)
in block uiview.animate add next block of code after tableView.endupdates()
"if cell.frame.maxY > tableView.frame.maxY {
tableView.scrollToRow(at: indexPath, at: UITableView.ScrollPosition.bottom, animated: true)
}"