Releases: chiahsien/CHTCollectionViewWaterfallLayout
Releases · chiahsien/CHTCollectionViewWaterfallLayout
1.0.1
- Add PrivacyInfo.xcprivacy privacy manifest (declares no tracking, no data collection, no required-reason API usage)
- Bundle privacy manifest in both SPM targets and CocoaPods
- Update CocoaPods deprecation notice with trunk shutdown date (December 2, 2026) (https://blog.cocoapods.org/CocoaPods-Specs-Repo/)
1.0.0
A major release with a full rewrite of the Swift implementation. The Objective-C implementation is unchanged.
Highlights
- Swift rewrite — The entire Swift source has been rewritten from scratch to align with the Objective-C reference implementation, following modern Swift conventions.
- Platform bump — Minimum deployment target is now iOS 13 / tvOS 13.
- Apple-style documentation — Every public member now has full DocC-compatible documentation comments.
New Features
headerInset/footerInsetproperties — Control margins around section headers and footers independently.minimumContentHeightproperty — Set a minimum content height for the collection view (useful for hidden headers with no content).- Delegate methods —
insetsForHeaderIn:,insetsForFooterIn:,minimumColumnSpacingFor:for per-section customization.
Improvements
- All property setters now skip
invalidateLayout()when the value hasn't changed. - Replaced deprecated
UIScreen.main.scalewithtraitCollection.displayScalefor pixel-alignment calculations. layoutAttributesForSupplementaryView(ofKind:at:)now accepts bothCHTCollectionElementKind*andUICollectionView.elementKindSection*strings.layoutAttributesForElements(in:)deduplicates attributes by index path, preventing potential duplicates.- Eliminated all force-unwraps of
collectionView!— the layout now returns early safely whencollectionViewisnil. - Union rects optimization now uses a proper union of all rects in each batch, not just the first and last.
- Demo projects modernized with programmatic UI and
UIScenelifecycle (storyboards removed). - CI updated to Node.js 24 compatible GitHub Actions.
Breaking Changes
See the migration guide in the README for full details. Summary:
- Deployment target: iOS 9 → iOS 13, tvOS 9 → tvOS 13.
- Swift toolchain:
swift-tools-version5.0 → 5.9 (requires Xcode 15+). - Supplementary view element kind: Headers/footers now use
CHTCollectionElementKindSectionHeader/Footerinstead ofUICollectionView.elementKindSectionHeader/Footer. - Return type:
layoutAttributesForSupplementaryView(ofKind:at:)now returnsUICollectionViewLayoutAttributes?(optional). - Removed: Public
delegateproperty (now private). - Removed: All
@available(*, unavailable, renamed:)migration shims from 0.9.x.
Note on CocoaPods
CocoaPods is no longer actively maintained. We recommend migrating to Swift Package Manager.
0.9.10
0.9.9
0.9.7
0.9.6
0.9.5
0.9.4
Minor update
- Fix for issue when layout is rotated (#100)