Alert example 2
From Bootstrap for MediaWiki
| Component | ||
|---|---|---|
| Name | Alert | |
| Description | Alerts in light mode and dark mode | |
| Provider | Skin | |
| Note | Dark mode needs the CSS marked "Bootstrap dark mode" on MediaWiki:Common.css, because the Chameleon skin leaves out Bootstrap's dark mode. | |
| Reference | getbootstrap.com - color modes | |
| Styling | For all possible color styles and corresponding examples, see colors. | |
Light mode
- Code
<div class="alert alert-primary" role="alert">A simple primary alert.</div>
<div class="alert alert-danger" role="alert">A simple danger alert.</div>
- Result
A simple primary alert.
A simple danger alert.
Dark mode
The code is the same as for light mode, see Color modes.
- Result
A simple primary alert.
A simple danger alert.
