Twitter Bootstrap modal opening/closing causes fixed header to jump

后端 未结 14 2387
旧时难觅i
旧时难觅i 2021-01-08 01:39

I am almost done with a simple 2-page website for my registered domain names. Unfortunately I have one small issue I can\'t seem to fix: a jumpy header when a Twitter Bootst

14条回答
  •  無奈伤痛
    2021-01-08 01:51

    When the modal opens, the "modal-open" class is added to the HTML element which hides overflow. You can change this by over-writing the "modal-open" class with overflow: inherit. This will keep the scrollbar in view, just as it is when the modal is closed. Keep in mind that this will change the overflow option whenever any modal is opened on the page. Hope this helps. Good luck!

提交回复
热议问题