From e9ab6020f623dee02879e95e344c12c2536d8462 Mon Sep 17 00:00:00 2001 From: Vincent Tourraine Date: Tue, 23 Mar 2021 11:28:13 +0100 Subject: [PATCH] Fix header/footer layout when resizing AcknowListViewController --- CHANGELOG.md | 5 +++++ Sources/AcknowList/AcknowListViewController.swift | 9 +++++++++ 2 files changed, 14 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 843cde2..d220d18 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Changelog +## 2.0.1 (work in progress) + +- Fix header/footer layout when resizing `AcknowListViewController` + + ## 2.0.0 (15 March 2021) - Update `AcknowListViewController` to detect URLs in header and footer diff --git a/Sources/AcknowList/AcknowListViewController.swift b/Sources/AcknowList/AcknowListViewController.swift index 0915b3c..44292a9 100644 --- a/Sources/AcknowList/AcknowListViewController.swift +++ b/Sources/AcknowList/AcknowListViewController.swift @@ -267,6 +267,15 @@ open class AcknowListViewController: UITableViewController { } } + open override func viewWillTransition(to size: CGSize, with coordinator: UIViewControllerTransitionCoordinator) { + super.viewWillTransition(to: size, with: coordinator) + + coordinator.animate(alongsideTransition: nil) { _ in + self.configureHeaderView() + self.configureFooterView() + } + } + // MARK: - Actions /**