You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Open the modal. The <nav class="bd-subnavbar py-2" aria-label="Secondary navigation"> is stiky by css, but it will not be affected at all while modal opens.
Then add the sticky-top class <nav class="bd-subnavbar py-2 sticky-top" aria-label="Secondary navigation">
open the browser inspector
open the modal again
Result:
The nav element will have two js-added properties
padding-right:17px;
margin-right:-17px;
Example test attached:
Ps: The same issue, lives in scrollbar.js too, as it is a copy of modal code
The text was updated successfully, but these errors were encountered:
While a modal is opened, the code tries to make some magic with padding/margin on fixed elements
Although line 459 adds
paddingRight
on.sticky-top
and line 460 reverts this, adding negativemarginRight
bootstrap/js/src/modal.js
Line 460 in 0795a77
bootstrap/js/src/modal.js
Line 459 in 0795a77
Replicate:
<nav class="bd-subnavbar py-2" aria-label="Secondary navigation">
isstiky
by css, but it will not be affected at all while modal opens.sticky-top
class<nav class="bd-subnavbar py-2 sticky-top" aria-label="Secondary navigation">
Result:
The
nav
element will have two js-added propertiesExample test attached:

Ps: The same issue, lives in scrollbar.js too, as it is a copy of modal code
The text was updated successfully, but these errors were encountered: