-
-
Notifications
You must be signed in to change notification settings - Fork 79.1k
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
Modal "close" button using dark variant not aligned to the right #39716
Comments
Have the same problem since 5.3.3 but even not in dark mode. |
Hello @Batman08. Bug reports must include a live demo of the issue. Per our contributing guidelines, please create a reduced test case on CodePen or StackBlitz and report back with your link, Bootstrap version, and specific browser and Operating System details. |
Updated issue with live demo |
Thanks for the reproducible use case @Batman08 Adding an extra <div class="modal-header bg-dark" data-bs-theme="dark">
<h1 class="modal-title fs-5 text-white" id="exampleModalIssueLabel">Modal Issue</h1>
<button type="button" class="btn-close" aria-label="Close"></button>
</div> |
Thank you for the suggested fix. |
Prerequisites
Describe the issue
If you use the dark variant of the modal "close" button as show here;
https://getbootstrap.com/docs/5.3/components/close-button/#dark-variant
Then it looks like the change done here:
#39373 (comment)
i.e. "The space-between is not used anymore as the position of the btn-close is based on the margin now."
This means the "close" button doesn't get pushed to the far right and instead sits next to the title on the left.
Reduced test cases
https://codepen.io/Batman08/pen/bGJbxQa
What operating system(s) are you seeing the problem on?
Windows
What browser(s) are you seeing the problem on?
Chrome
What version of Bootstrap are you using?
5.3.3
The text was updated successfully, but these errors were encountered: