sss

SSSheetLayout

This project is written for custom collection view layout like sheet form

Showing:

Popularity

Downloads/wk

0

GitHub Stars

40

Maintenance

Last Commit

4yrs ago

Contributors

1

Package

Dependencies

0

License

MIT

Categories

Readme

SSSheetLayout

CI Status Version License Platform

  • This project is written for custom collection view layout like sheet form
  • In fact, many applications need to show view like sheet, so this project focus to make the collection view scrollable horizontal and vertical. The main feature is keep top and left dock

Screen shot

Requirements

  • iOS 8.0+
  • Xcode 8.0

Installation

SSSheetLayout is available through CocoaPods. To install it, simply add the following line to your Podfile:

pod "SSSheetLayout"

Usage

  1. Set collection view layout with custom type SSSheetLayout

Change layout type

  1. Set datasource for collection view layout (SSSheetLayout)

Set Datasource

  1. How to change size for collection view cell
func collectionView(collectionView: UICollectionView, sizeForItem indexPath: IndexPath) -> CGSize {
    if indexPath.row == 0 {
        return CGSize(width: 100, height: 30)
    }
    return CGSize(width: 50, height: 30)
}
  1. How to keep dock when scroll to max, min offset
func scrollViewDidScroll(_ scrollView: UIScrollView) {
    scrollView.keepDockOffset()
}

Author

Ngô Đắc Du, ngodacdu92@gmail.com

License

SSSheetLayout is available under the MIT license. See the LICENSE file for more info.

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100