Giter VIP home page Giter VIP logo

imageopentransition's Introduction

Pod version Language Awesome

ImageOpenTransition Icon

Description

Beautiful and precise transitions between ViewControllers images written in Swift.

  • Supports multiple images transition

  • Simply provide the imageView you would like to transition from, and to, and all the rest is free

  • No need to dig in transition API for a beautiful transition

Demo

ImageOpenTransition Icon ImageOpenTransition Icon

Code

let transitionObjectAvatar = ImageScaleTransitionObject(viewToAnimateFrom: cell.imgAvater,
                                                                    viewToAnimateTo: vc.imgAvatar,
                                                                    duration: 0.4)
            
//Example of explicitly defining a final frame:
let transitionObjectCover = ImageScaleTransitionObject(viewToAnimateFrom: cell.imgCover,
                                                                   viewToAnimateTo: vc.imgCover,
                                                                   duration: 0.4,
                                                                   frameToAnimateToCover)
            
self.imageScalePresentTransition = ImageScaleTransitionDelegate(transitionObjects: [transitionObjectCover ,transitionObjectAvatar], 
                                                                            usingNavigationController: usingNavigationController, 
                                                                            duration: 0.4)

Usage

  • Create "ImageScaleTransitionObject" For each image you woould like to animate. Pass the UIImageView to animate from, and the UIImageView to animate to.

  • You must pass the ImageView you would like to animate to. You can or allocate it before the controller is presented, or call "loadView", it's your choice.

  • The frame you would like to animate to, is optional. You can use it in cases the UIImageView you would like to animate to, has no frame yet, and you rather calculate it programmatically.

**Use the example project for better reference.

Supports

Story boards/non story-board Translucent/non-translucent NavigationController/ non-navigationController

Installation

Cocoapods

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

pod 'ImageOpenTransition'

Manually

  1. Download and drop /ImageOpenTransition folder in your project.
  2. Congratulations!

Author

Matan made this with ❤️.

##License

Copyright 2013-2016 Jive Software, Inc.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

imageopentransition's People

Contributors

lfarah avatar mcmatan avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.