feat: Enhance UI components with improved styles and responsiveness across various views
This commit is contained in:
@@ -24,7 +24,9 @@ Alpine.store('notifications', {
|
||||
},
|
||||
|
||||
addNotification(notification) {
|
||||
notification = notification[0];
|
||||
// Livewire dispatches pass args as an array; unwrap if needed.
|
||||
if (Array.isArray(notification)) notification = notification[0];
|
||||
if (!notification || typeof notification !== 'object') return;
|
||||
notification.show = false;
|
||||
notification.id = Date.now() + Math.floor(Math.random() * 1000);
|
||||
notification.type = notification.type || 'success';
|
||||
|
||||
Reference in New Issue
Block a user