github HeroTransitions/Hero 1.2.0

latest releases: 1.6.3, 1.6.2, 1.6.1...
6 years ago
  • add HeroTransitionDelegate for observing transition state and progress

  • add ability to change target state during interactive transition.
    #322

    Just call the following method before calling finish(animate:) and provide the target state similar to apply(modifiers:, to:)

    Hero.shared.changeTarget(modifiers:, to:)

    for example:

    someView.hero.modifiers = [.translate(x: 100)]
    
    // when you want to finish interactive transition
    Hero.shared.changeTarget(modifiers:[.translate(x: -100)], to: someView)
    Hero.shared.finish()
    // this will animate someView to the state of `.translate(x: -100)` instead of `.translate(x: 100)`
  • a number of bug fixes and improvements:

Don't miss a new Hero release

NewReleases is sending notifications on new releases.