Latest 1.1.1
Homepage https://github.com/ssuchanowski/THTinderNavigationController
License MIT
Platforms ios 8.0, requires ARC
Authors ,

THTinderNavigationController

Installation

THTinderNavigationController is available through CocoaPods. In case original author Tgy31 would like to set a pod for himself I’ve hypned my twitter handle at the end of pod name. To install it, simply add the following line to your Podfile:

pod 'THTinderNavigationController-ssuchanowski'

How to use

Create a THTinderNavigationController.

THTinderNavigationController *tinderNavigationController = [[THTinderNavigationController alloc] init];

THTinderNavigationController can take any UIView as a navigationBarItem. Just set its navBarItemViews property.

tinderNavigationController.navbarItemViews = @[
                                               [[NavigationBarItem alloc] init],
                                               [[NavigationBarItem alloc] init],
                                               [[NavigationBarItem alloc] init]
                                               ];

To animate your view based on its position, the view must respond to - (void)updateViewWithRatio:(CGFloat)ration in THTinderNavigationBarItem protocol.

In the demo, to change the color:

- (void)updateViewWithRatio:(CGFloat)ratio
{
//    Color change animation

    self.coloredView.alpha = ratio;
}

In the demo, to change the size:

- (void)updateViewWithRatio:(CGFloat)ratio
{
//    Size change animation

    ratio = ratio/2.0 + 0.5;
    CGFloat height = self.frame.size.height * ratio;
    CGFloat width = self.frame.size.width * ratio;
    CGFloat x = (self.frame.size.width - width) / 2.0;
    CGFloat y = (self.frame.size.height - height) / 2.0;
    self.coloredView.frame = CGRectMake(x, y, width, height);
    self.coloredView.layer.cornerRadius = height/2.0;
}

TODO

  • Build better readme
  • Add usage samples

Latest podspec

{
    "name": "THTinderNavigationController-ssuchanowski",
    "version": "1.1.1",
    "summary": "iOS navigation component based on Tinder app",
    "description": "                 iOS navigation component based on Tinder app. This is a fork of https://github.com/Tgy31 repositoryn",
    "homepage": "https://github.com/ssuchanowski/THTinderNavigationController",
    "license": {
        "type": "MIT",
        "file": "LICENSE"
    },
    "authors": {
        "Sebastian Suchanowski": "[email protected]",
        "Tanguy Hu00e9lesbeux": "[email protected]"
    },
    "social_media_url": "http://twitter.com/ssuchanowski",
    "platforms": {
        "ios": "8.0"
    },
    "source": {
        "git": "https://github.com/ssuchanowski/THTinderNavigationController.git",
        "tag": "1.1.1"
    },
    "source_files": "THTinderNavigationController/**/*.{h,m}",
    "requires_arc": true
}

Pin It on Pinterest

Share This