Skip to content

Add 'danger' method to match bootstrap class#158

Closed
danswiser wants to merge 2 commits intolaracasts:masterfrom
danswiser:patch-1
Closed

Add 'danger' method to match bootstrap class#158
danswiser wants to merge 2 commits intolaracasts:masterfrom
danswiser:patch-1

Conversation

@danswiser
Copy link

There are four "standard" bootstrap alert classes in addition to the other less standard alerts. The four "proper" alert types are success, info, warning and danger. The alert-danger class does not match the ->error() method name like the other methods do. This leads to confusing behavior.

flash($message)->info();      => class="alert alert-info"
flash($message)->success();   => class="alert alert-success"
flash($message)->warning();   => class="alert alert-warning"
flash($message)->danger();   Does not exist
flash($message)->error();      => class="alert alert-danger"

The original ->error() method remains unchanged for backwards compatibility.

@danswiser danswiser closed this by deleting the head repository Aug 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant