• This repository has been archived on 18/Sep/2019
  • Stars
    star
    163
  • Rank 231,102 (Top 5 %)
  • Language
    Swift
  • License
    MIT License
  • Created over 8 years ago
  • Updated about 8 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

HoverConversion realized vertical paging with UITableView. UIViewController will be paged when reaching top or bottom of UITableView contentOffset.

HoverConversion

Platform Language Version Carthage compatible License

ManiacDev.com referred.
https://maniacdev.com/2016/09/hoverconversion-a-swift-ui-component-for-navigating-between-multiple-table-views

HoverConversion realized vertical paging with UITableView. UIViewController will be paging when reaching top or bottom of UITableView's contentOffset.

Featrue

  • Vertical paging with UITableView
  • Seamless transitioning
  • Transitioning with navigationView pan gesture
  • Selected cell that related to UIViewController is highlighting
  • Support Swift2.3
  • Support Swift3

To run the example project, clone the repo, and run pod install from the Example directory first.

Installation

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

pod "HoverConversion"

Usage

If you install from cocoapods, You have to write import HoverConversion.

Storyboard or Xib

Set custom class of UINavigationController to HCNavigationController. In addition, set module to HoverConversion. And set HCRootViewController as navigationController's first viewController.

Code

Set HCNavigationController as self.window.rootViewController. And set HCRootViewController as navigationController's first viewController.

HCPagingViewController

If you want to show vertical contents, please use HCPagingViewController.

let vc = HCPagingViewController(indexPath: indexPath)
vc.dataSource = self
navigationController?.pushViewController(vc, animated: true)

HCContentViewController

A content included in HCPagingViewController is HCContentViewController.
Return HCContentViewController (or subclass) with this delegate method.

extension ViewController: HCPagingViewControllerDataSource {
    func pagingViewController(viewController: HCPagingViewController, viewControllerFor indexPath: NSIndexPath) -> HCContentViewController? {
        guard 0 <= indexPath.row && indexPath.row < twitterManager.users.count else { return nil }
        let vc = UserTimelineViewController()
        vc.user = twitterManager.users[indexPath.row]
        return vc
    }
}

HCNextHeaderView

Return HCNextHeaderView (or subclass) with this delegate method.

extension ViewController: HCPagingViewControllerDataSource {
    func pagingViewController(viewController: HCPagingViewController, nextHeaderViewFor indexPath: NSIndexPath) -> HCNextHeaderView? {
        guard 0 <= indexPath.row && indexPath.row < twitterManager.users.count else { return nil }
        let view = NextHeaderView()
        view.user = twitterManager.users[indexPath.row]
        return view
    }
}

Stop transitioning

If you want to load more contents from server and want to stop transitioning, you can use canPaging in HCContentViewController.

//Stop transitioning to previous ViewController
canPaging[.prev] = false //Default true

//Stop transitioning to next ViewController
canPaging[.next] = false //Default true

Requirements

  • Xcode 7.3 or greater
  • iOS 8.0 or greater
  • MisterFusion - Swift DSL for AutoLayout

Special Thanks

Those OSS are used in sample project!

Author

marty-suzuki, [email protected]

License

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

More Repositories

1

ReverseExtension

A UITableView extension that enables cell insertion from the bottom of a table view.
Swift
1,675
star
2

SAHistoryNavigationViewController

SAHistoryNavigationViewController realizes iOS task manager like UI in UINavigationContoller. Support 3D Touch!
Swift
1,569
star
3

iOSDesignPatternSamples

This is Github user search demo app which made by many variety of design patterns. You can compare differences in MVC, MVP, MVVM and Flux.
Swift
690
star
4

URLEmbeddedView

URLEmbeddedView automatically caches the object that is confirmed the Open Graph Protocol.
Swift
650
star
5

SABlurImageView

You can use blur effect and it's animation easily to call only two methods.
Swift
557
star
6

MisterFusion

MisterFusion is Swift DSL for AutoLayout. It is the extremely clear, but concise syntax, in addition, can be used in both Swift and Objective-C. Support Safe Area and Size Class.
Swift
314
star
7

SAInboxViewController

UIViewController subclass inspired by "Inbox by google" animated transitioning.
Swift
297
star
8

SACollectionViewVerticalScalingFlowLayout

UICollectionViewLayout that performs scaling up and down automatically on disappearing cells, and applies UIDynamics.
Swift
272
star
9

SAParallaxViewControllerSwift

SAParallaxViewControllerSwift realizes parallax scrolling with blur effect. In addition, it realizes seamless opening transition.
Swift
260
star
10

MartyJunior

You can change tab contents with swipe gesture on middle of UITableView!!
Swift
245
star
11

TheAnimation

Type-safe CAAnimation wrapper. It makes preventing to set wrong type values.
Swift
224
star
12

GitHubSearchWithSwiftUI

SwiftUI and Combine based GitHubSearch example.
Swift
205
star
13

DuctTape

๐Ÿ“ฆ KeyPath dynamicMemberLookup based syntax sugar for Swift.
Swift
175
star
14

NoticeObserveKit

NoticeObserveKit is type-safe NotificationCenter wrapper.
Swift
150
star
15

FluxCapacitor

This is what makes the Flux design pattern possible.
Swift
123
star
16

MSAlertController

MSAlertController has same feature at UIAlertViewController.
Objective-C
117
star
17

Prex

๐Ÿ”Unidirectional data flow architecture with MVP and Flux combination for Swift
Swift
109
star
18

QiitaWithFluxSample

A sample project uses Flux and MVVM features with RxSwift.
Swift
104
star
19

Continuum

NotificationCenter based Lightweight UI / AnyObject binder.
Swift
80
star
20

Ricemill

๐ŸŒพ โ™ป๏ธ ๐Ÿš Unidirectional Input / Output framework with Combine. Supports both of SwiftUI and UIKit.
Swift
63
star
21

PickerButton

PickerButton is subclass of UIButton that presents UIPickerView in UIKeyboard.
Swift
44
star
22

SASecretCommandViewController

You can use secret command with swipe gesture and A, B button. Show a secret mode you want!
Swift
43
star
23

ArtShredder

๐Ÿ“ฑBanksy Shredder for iOS
Swift
42
star
24

SplittableViewKit

A cell of IndexPath(row: 0, section: 0) in UITableView is automatically moved to left view when device rotated.
Swift
37
star
25

UILayoutBuilder

An AutoLayout DSL that intuitive syntax and viewable hierarchy.
Swift
37
star
26

SAWaveToast

Show text with wave animated background and floating animation.
Swift
34
star
27

TicTacToe-SwiftUI

Unidirectional data flow tic-tac-toe sample with SwiftUI.
Swift
23
star
28

SafeAreaExtension

You can handle safeAreaInsets changes of every UIView.
Swift
20
star
29

SABlurImageViewObjc

Objective-C
19
star
30

AnyObservableObject

Swift
18
star
31

ReuseCellConfigure

You can configure ReusableCell without casting!
Swift
17
star
32

GitHubClientTestSample

A GitHub client sample for User Action Logs testing.
Swift
17
star
33

MOAlertController

Objective-C
15
star
34

ConnpassAttendanceChecker

An attendance checking iOS application for https://connpass.com
Swift
14
star
35

SimplestCounterSample

This is simplest Counter App written in many variety of design patterns.
Swift
14
star
36

MyFirstAndroidPractice

I had began learning Android App development since Aug 2021. This is my first Android app project for practice development.
Kotlin
11
star
37

GithubKitForSample

Swift
11
star
38

DiffMVPAndMVVM

MVP and MVVM implementations and test code sample.
Swift
9
star
39

YouTubeSampleWithMVP-DiffableDataSource

This is a YouTube like iOS app sample with the Model-View-Presenter pattern.
Swift
9
star
40

Connpass

Swift
8
star
41

LayoutGuaranteedView

LayoutGuaranteedView is a Phantom Type view holder. It guaranteed that a view had laid out after execute `guaranteeLayout` function.
Swift
8
star
42

Necom

๐Ÿˆ New concept of MVP with Swift
Swift
7
star
43

RxAnyDispatcher

A observer(or observable)-only `Dispatcher` that is used in Flux.
Swift
7
star
44

kmm-with-spm-buildtoolplugin-sample

Kotlin
6
star
45

QiitaApiClient

API client for http://qiita.com/.
Swift
6
star
46

LazyInitializedViewModelInjectionSample

Swift
4
star
47

iOSDC2022LightningTalkSample

Swift
3
star
48

unio-kt

๐Ÿ”„ kProperty based Unidirectional Input / Output framework with Flow.
Kotlin
2
star
49

ReusableView

Swift
1
star
50

LayeredLayout

Swift
1
star
51

ViewIsolatedViewController

Swift
1
star