Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to achieve the transition effect with height CSS properties. #13

Open
aga5tya opened this issue May 26, 2017 · 1 comment
Open

Comments

@aga5tya
Copy link

aga5tya commented May 26, 2017

@jl- First off thanks for the wonderful module.!

I have incorporated the package in a personal project of mine, but i am unable to get the transistion effect when assigning height properties in 'vh' units to the Deck parent component. I tried with other units too, like percentages, couldn't figure out.

Here's one finding i could stumble upon, when the window is resized even a little, the animation/transistions work just fine from next mousewheel action.

Additionally, im using this with server rendered nextjs framework. I quickly spun off a sample where this can be replicated. Any help is highly appreciated.

Repo

@aga5tya
Copy link
Author

aga5tya commented May 27, 2017

Digging further, i see that the deck has 0 height when this.calcDimension() is fired on the componentDidMount lifecycle of Deck component.
Around here.

This is because the children have not yet rendered whose height decides the Deck height post render.

For now i'm overriding the height to be 100vh on the deck component so its begins the computation on dimensions. I can create a PR, let me know if there is an other way around since mine kinda is a hacky way of fixing it. @jl-

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant