GithubHelp home page GithubHelp logo

Comments (13)

heidji avatar heidji commented on May 18, 2024

i will look at it, thanks

from ionic4-hidenav.

heidji avatar heidji commented on May 18, 2024

i didn't have much time to dive too deep into it, could you please check if the problem still persists with the new version?

from ionic4-hidenav.

rastafan avatar rastafan commented on May 18, 2024

@heidji thanks for your work on this.
We tried with the new version. Unfortunately, we are still getting an error, event though it's a different one.

ERROR TypeError: Cannot read property 'scrollTop' of undefined
    at HidenavShService.resetContent (ionic4-hidenav.js:1050)
    at SafeSubscriber._next (ionic4-hidenav.js:1521)
    at SafeSubscriber.__tryOrUnsub (Subscriber.js:183)
    at SafeSubscriber.next (Subscriber.js:122)
    at Subscriber._next (Subscriber.js:72)
    at Subscriber.next (Subscriber.js:49)
    at HTMLElement.handler (fromEvent.js:20)
    at ZoneDelegate.invokeTask (zone-evergreen.js:391)
    at Object.onInvokeTask (core.js:34182)
    at ZoneDelegate.invokeTask (zone-evergreen.js:390)

It happens most of the time, but not always. It still looks like some sort of race condition, but we might be wrong.

Feel free to ask for more details and tests if needed.
Thank you.

from ionic4-hidenav.

heidji avatar heidji commented on May 18, 2024

from ionic4-hidenav.

rastafan avatar rastafan commented on May 18, 2024

Yes, the inner content of the super-tabs is not correctly placed on tab change.
After changing tab with a shrunk header, the content of the destination tab appears as if the header was not shrunk, but then it gets in place correctly after touching/scrolling it.
When the error reported is not shown, the content appears correctly placed.
It is the same behaviour showed in the gif of the original post, after the error is thrown.
This is a screenshot of the original problem in the example project
(This is a screenshot of the original problem in the example project, haven't tried the example project yet)

from ionic4-hidenav.

heidji avatar heidji commented on May 18, 2024

from ionic4-hidenav.

rastafan avatar rastafan commented on May 18, 2024

Hi @heidji, any news on this issue?

from ionic4-hidenav.

heidji avatar heidji commented on May 18, 2024

I honestly could not reproduce that, how exactly does it happen?

from ionic4-hidenav.

rastafan avatar rastafan commented on May 18, 2024

Ok, the error is gone. It was my fault.

The problem was a caused by having a ViewChild pointing at SuperTabs with "static" set to "true" :

@ViewChild('supertabs', { static: true }) supertabs: SuperTabs;

and then, a reference to the variable "supertabs" in constructor (which did not give any error as long as static was true).

Setting "static" to "false" and moving the reference to IonViewWillEnter solved the issue.

Just a last question before closing:

Supertabs content appears to be extra-long compared to the content of each tab, with a lot of white space at the bottom. Do you happen to know what it may be related to?

Thanks a lot again for your help.

from ionic4-hidenav.

heidji avatar heidji commented on May 18, 2024

from ionic4-hidenav.

rastafan avatar rastafan commented on May 18, 2024

I see, didn't check through enough it seems, sorry.
We'll manage to make it shorter somehow. I think i can close thi issue now.
Thanks again for your support. Great job so far!

from ionic4-hidenav.

rastafan avatar rastafan commented on May 18, 2024

Just a little update: turns out the main problem was a tab change call before the component was completely initialized. I avoided it and everything seems to be alright.

from ionic4-hidenav.

heidji avatar heidji commented on May 18, 2024

from ionic4-hidenav.

Related Issues (9)

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.