Skip to content
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 data-bs-theme dark does not change text color #6796

Open
3 tasks done
averwhy opened this issue Apr 22, 2024 · 1 comment
Open
3 tasks done

Modal data-bs-theme dark does not change text color #6796

averwhy opened this issue Apr 22, 2024 · 1 comment
Labels

Comments

@averwhy
Copy link

averwhy commented Apr 22, 2024

Prerequisites

Describe the bug

I have this modal:

      <Modal.Header closeButton data-bs-theme="dark">
          <Modal.Title id="contained-modal-title-vcenter">
            Simulator
          </Modal.Title>
        </Modal.Header>
        <Modal.Body>
            <ProgressBar animated now={45} />
        </Modal.Body>
        <Modal.Footer>
          <Button onClick={props.onHide}>Close</Button>
        </Modal.Footer>
      </Modal>

However, when rendered, the text is the same color as the background, making it only visible when highlighted

Expected behavior

Text should be white/readable

To Reproduce

No response

Reproducible Example

https://github.com/averwhy/noisyProject/blob/main/src/components/simulator.jsx#L72-L94

Screenshots

image

What operating system(s) are you seeing the problem on?

Windows

What browser(s) are you seeing the problem on?

Firefox

What version of React-Bootstrap are you using?

2.10.2

What version of Bootstrap are you using?

10.5.0

Additional context

No response

@confidential-nt
Copy link

confidential-nt commented May 12, 2024

The issue was with Bootstrap's internal CSS, not React Bootstrap. I was able to reproduce the bug and resolved it by setting --bs-modal-color to var(--bs-body-color).

from
KakaoTalk_Photo_2024-05-12-21-37-31

to
KakaoTalk_Photo_2024-05-12-21-37-18

I have created a PR to fix this issue. Please review it.

twbs/bootstrap#39977

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants