FremyCompany / css-grid-polyfill

A working implementation of css grids for current browsers.
MIT License
1.11k stars 82 forks source link

Continuous scroll to top in IE10+ #30

Closed fregante closed 9 years ago

fregante commented 9 years ago

Apparently the relayout event is being triggered often in IE and so it scrolls to the top each time. It would be great to avoid the scroll everywhere at least.

Do you see this bug in your demos?

FremyCompany commented 9 years ago

I understand the issue. During a relayout, the grid may collapse to 0px height temporarily, causing the page to not feature a scrollbar for a very short time. I can add some code to make sure this won't happen, however.

fregante commented 9 years ago

Ah, I see, that makes sense

FremyCompany commented 9 years ago

Tentative fix: https://github.com/FremyCompany/css-grid-polyfill/commit/e32c6b9d40c86fa8c0709591cb3ea65690d1a0c3

PS: I also merged this commit into the browserify branch so that you can test using your current setup.

fregante commented 9 years ago

Thank you so much for this! I'll be testing it in the morning :)

fregante commented 9 years ago

Cool, this seems to work!