Intermediate
Intermediate
Requires Bootstrap 5. Add the CDN tags below to your page (styles in
<head>, scripts before </body>). The downloaded file already includes them.<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css"><script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/js/bootstrap.bundle.min.js"></script>Colour-coded stacking Bootstrap 5 toasts that auto-dismiss, using the Toast JavaScript API. Free to copy or download.<div class="d-flex gap-2 flex-wrap justify-content-center">
<button class="btn btn-success" onclick="show('success','Saved successfully!')">Success</button>
<button class="btn btn-danger" onclick="show('danger','Something failed.')">Error</button>
<button class="btn btn-primary" onclick="show('primary','Just so you know.')">Info</button>
</div>
<div class="toast-container position-fixed top-0 end-0 p-3" id="tc"></div>Free to use.This component uses Bootstrap 5 (linked above). Copy any file, or download a ready-to-open .html page with the CDN links already included.