Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/fdzsergio/SFFocusViewLayout
UICollectionViewLayout with focused content
https://github.com/fdzsergio/SFFocusViewLayout
carthage cocoapods ios swift uicollectionviewlayout
Last synced: 3 months ago
JSON representation
UICollectionViewLayout with focused content
- Host: GitHub
- URL: https://github.com/fdzsergio/SFFocusViewLayout
- Owner: fdzsergio
- License: mit
- Created: 2015-10-07T11:22:14.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2018-09-29T16:30:27.000Z (about 6 years ago)
- Last Synced: 2024-06-17T20:19:05.991Z (5 months ago)
- Topics: carthage, cocoapods, ios, swift, uicollectionviewlayout
- Language: Swift
- Homepage:
- Size: 3.96 MB
- Stars: 1,763
- Watchers: 39
- Forks: 181
- Open Issues: 13
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG
- License: LICENSE
Awesome Lists containing this project
- awesome-ios - SFFocusViewLayout - UICollectionViewLayout with focused content. (UI / Tag)
- awesome-ios-star - SFFocusViewLayout - UICollectionViewLayout with focused content. (UI / Tag)
- awesome-ios - SFFocusViewLayout - `UICollectionViewLayout` with focused content. [•](https://raw.githubusercontent.com/fdzsergio/SFFocusViewLayout/master/Screenshots/SFFocusViewLayout.gif) (Content / Layout)
- Awesome-Mobile-UI - SFFocusViewLayout - C | ![SFFocusViewLayout](resources/SFFocusViewLayout.gif) | (ALL)
README
# SFFocusViewLayout
[![Travis CI](https://travis-ci.org/fdzsergio/SFFocusViewLayout.svg?branch=master)](https://travis-ci.org/fdzsergio/SFFocusViewLayout)
[![codecov.io](https://codecov.io/github/fdzsergio/SFFocusViewLayout/coverage.svg?branch=master)](https://codecov.io/github/fdzsergio/SFFocusViewLayout?branch=master)
[![Swift Version](https://img.shields.io/badge/Swift-4.2.x-orange.svg)]()
[![Version](https://img.shields.io/cocoapods/v/SFFocusViewLayout.svg?style=flat)](http://cocoapods.org/pods/SFFocusViewLayout)
[![Swift Package Manager compatible](https://img.shields.io/badge/Swift%20Package%20Manager-compatible-brightgreen.svg)](https://github.com/apple/swift-package-manager)
[![Carthage compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/Carthage/Carthage)
[![Platform](https://img.shields.io/cocoapods/p/SFFocusViewLayout.svg?style=flat)](http://cocoapods.org/pods/SFFocusViewLayout)
[![License](https://img.shields.io/cocoapods/l/SFFocusViewLayout.svg?style=flat)](http://cocoapods.org/pods/SFFocusViewLayout)## Overview
SFFocusViewLayout is a UICollectionViewLayout subclass for displaying focused content on UICollectionView which is the largest cell of all.
## Usage
SFFocusViewLayout contains three properties to customize the interface.
```swift
var standardHeight: CGFloat
var focusedHeight: CGFloat
var dragOffset: CGFloat
```- _focusedHeight_ is the height cells should be when focused. Defaults to 280
- _standardHeight_ is the height cells should be when collapsed. Defaults to 100
- _dragOffset_ is the amount the user needs to scroll before the featured cell changes. Defaults to 180## Versions
### Swift
If you want to use a Swift 3 implementation of this framework use a 3.0 or greater version```ruby
pod 'SFFocusViewLayout', '~> 3.0'
```### Objective–C
If you want to use a Objective–C implementation of this framework use a 2.0 or greater version```ruby
pod 'SFFocusViewLayout', '~> 2.0'
```## Installation
### CocoaPods
SFFocusViewLayout is available through [CocoaPods](http://cocoapods.org). To install
it, simply add the following line to your Podfile:```ruby
pod 'SFFocusViewLayout'
```
### CarthageYou can also install it via [Carthage](https://github.com/Carthage/Carthage). To do so, add the following to your Cartfile:
```terminal
github 'fdzsergio/SFFocusViewLayout'
```## Roadmap
- [x] Carthage support
- [x] Swift compatible
- [x] Swift version
- [x] Tests
- [x] Upgrade to Swift 3## Author
Sergio Fernández, [email protected]
## Acknowledgement
This framework is heavily inspired by the Ultravisual example of [Ray Wenderlich](http://www.raywenderlich.com/99087/swift-expanding-cells-ios-collection-views).
## License
SFFocusViewLayout is available under the MIT license. See the [LICENSE](https://raw.githubusercontent.com/fdzsergio/SFFocusViewLayout/master/LICENSE) file for more info.