HasToasts
trait HasToasts
Trait HasToasts.
Provides a fluent interface for dispatching toast notifications from Livewire components.
Properties
| protected object|null | $_beartropy_toast_proxy |
Methods
object
toast()
Get the toast proxy instance.
__construct(object $component)
No description
void
success(string $title, string $message = '', int $duration = 4000, string|null $position = null, string|null $action = null, string|null $actionUrl = null)
No description
void
error(string $title, string $message = '', int $duration = 4000, string|null $position = null, string|null $action = null, string|null $actionUrl = null)
No description
void
info(string $title, string $message = '', int $duration = 4000, string|null $position = null, string|null $action = null, string|null $actionUrl = null)
No description
void
warning(string $title, string $message = '', int $duration = 4000, string|null $position = null, string|null $action = null, string|null $actionUrl = null)
No description
void
send(string $type, string $title, string $message, int $duration, string|null $position, string|null $action, string|null $actionUrl)
No description
Details
at line 24
object
toast()
Get the toast proxy instance.
Allows usage like $this->toast()->success('Message').
at line 28
__construct(object $component)
No description
at line 30
void
success(string $title, string $message = '', int $duration = 4000, string|null $position = null, string|null $action = null, string|null $actionUrl = null)
No description
at line 35
void
error(string $title, string $message = '', int $duration = 4000, string|null $position = null, string|null $action = null, string|null $actionUrl = null)
No description
at line 40
void
info(string $title, string $message = '', int $duration = 4000, string|null $position = null, string|null $action = null, string|null $actionUrl = null)
No description
at line 45
void
warning(string $title, string $message = '', int $duration = 4000, string|null $position = null, string|null $action = null, string|null $actionUrl = null)
No description
at line 50
protected void
send(string $type, string $title, string $message, int $duration, string|null $position, string|null $action, string|null $actionUrl)
No description