Skip to content
Advertisement

Div will always shift up after refreshing the page

I have 2 divs on the webpage, the flipbook that is created using turnjs and another div containing the buttons. When I load the page, the divs are in the center of the page: https://imgur.com/a/lLb2g2l . After I refresh the page, the divs will shift up and stay there even after refreshing the page. This is how the page looks after refreshing: https://imgur.com/a/guwW0RT .

This is the html:

JavaScript

This is the css:

JavaScript

How do I ensure that the contents will not shift up after the page refreshes?

Advertisement

Answer

You just need to do some css updates, here are the few css classes are updated,

JavaScript
Advertisement