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

CalcHeightOnResize not working for non-window parent #166

Open
elitenoire opened this issue Aug 10, 2019 · 0 comments
Open

CalcHeightOnResize not working for non-window parent #166

elitenoire opened this issue Aug 10, 2019 · 0 comments

Comments

@elitenoire
Copy link

elitenoire commented Aug 10, 2019

I'm using a parent other than the window object and noticed the inline height is not calculated when resizing the browser window.

React-Headroom attaches the resize event handler to the parent prop but I've read that the resize event fires only on the window.

Hence, I implemented this (attached a resize handler to the window object) in my code base and the inline height gets recalculated.

The problem now is that, React-Headroom overrides the height style set in the wrapperStyle prop, so no way to use the new height.

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