GithubHelp home page GithubHelp logo

Comments (5)

lkzhao avatar lkzhao commented on August 27, 2024 6

.overFullScreen support is implemented in 0.3.0

from hero.

fruitcoder avatar fruitcoder commented on August 27, 2024

Could you point out how the community could help you with this issue? I love your framework but for context transitions it's sometimes necessary to show "where you come from", because it's better to understand the context. Isn't it sufficient to store a snapshot of the presenting view controller instead of a pointer to it?

from hero.

lkzhao avatar lkzhao commented on August 27, 2024

@fruitcoder Yes, we can start working on this now. For the past few week I have been trying to clean up the existing API and drop the zPosition modifier that was needed to make Hero transitions.

About your suggestion with keeping a snapshot of the presentingVC. The problem is that it doesn't work when the screen rotates on the presented VC. Ideally the presentingVC should also rotate and re-layout its subviews.

There are 2 problems to be solved:

  1. Hero currently doesn't store any state information after the transition. This makes it far easy to debug and also make view controller transitions independent. You can transition from any VC to any other VC without knowing which VC presented what. Many of the navigation helpers like hero_replaceViewController & hero_unwindToViewController depend on this.

  2. The snapshots that Hero takes have to stay after the transition. Theses snapshots are in a container view during the transition. Which VC should we insert these snapshot into? Who should keep track of them? Any still, when the screen rotates, these snapshots won't be updated.

I am also not very familiar with UIPresentationController. I have to spend some time on that and see if that is something we can use to maintain state information.

from hero.

fuxlud avatar fuxlud commented on August 27, 2024

Thank a lot for this amazing library!

This issue is still happening to me - I can still see black background when transition finished.


       let vc = MyViewController(...)
        vc.hero.isEnabled = true
        vc.hero.modalAnimationType = .selectBy(presenting: .pull(direction: .left), dismissing: .pull(direction: .right))
        vc.modalPresentationStyle = .overCurrentContext
        vc.view.backgroundColor = .clear
        present(vc2, animated: true, completion: nil)

When I set animated property to false present(vc2, animated: false, completion: nil) the background is transperent, but then I do not see the transition

from hero.

szoszig avatar szoszig commented on August 27, 2024

Any news on this?

from hero.

Related Issues (20)

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.