У меня есть расширяемое древовидное представление, когда я расширяю ячейку, которая находится близко к основанию, ячейки, которые вне рамки обрезаются и не перерисовываются.
Это начальное представление табличного представления Должны быть остальные ячейки внутри ячейки VF008.

Когда развернуто

Ячейка остается обрезанной при прокрутке вверх

вот мой код
func treeView(_ treeView: CITreeView, atIndexPath indexPath: IndexPath, withTreeViewNode treeViewNode: CITreeViewNode) -> UITableViewCell {
let cell = treeView.dequeueReusableCell(withIdentifier: "TreeViewCellIdentifier", for: indexPath) as! CITreeViewCell
let dataObj = treeViewNode.item as! CITreeViewData
cell.kodLabel.text = dataObj.kod
cell.adLabel.text = dataObj.name
cell.kasaLabel.text = dataObj.kasa.replacingOccurrences(of: ",", with: ".")
cell.setupCell(level: treeViewNode.level)
cell.selectionStyle = .none
print("indexPAth:\(indexPath.row)")
return cell
}
функция setupCell
func setupCell(level:Int)
{
self.leadingConstraint.constant = leadingValueForChildrenCell * CGFloat(level + 1)
switch level {
case 0:
self.contentView.backgroundColor = .systemTeal
case 1:
self.contentView.backgroundColor = .lightGray
case 2:
self.contentView.backgroundColor = .clear
default:
self.contentView.backgroundColor = .black
}
self.layoutIfNeeded()
}
что мне не хватает здесь?