fix: merge edits

chore: bump version
This commit is contained in:
jon brookes 2026-02-15 10:37:43 +00:00
parent 5646ddd9a3
commit 969ea504f3
4 changed files with 19 additions and 30 deletions

View file

@ -79,26 +79,18 @@ class AdminPanelProvider extends PanelProvider
<script>
document.addEventListener("DOMContentLoaded", function() {
if (window.Echo) {
<<<<<<< HEAD
=======
>>>>>>> 4143902e603c7e3e25de5e5f49c1116dd5a5743b
console.log("Setting up Filament Reverb notifications...");
console.log("Available globals:", {
FilamentNotification: typeof FilamentNotification,
Livewire: typeof window.Livewire,
filament: typeof window.filament
});
<<<<<<< HEAD
=======
>>>>>>> 4143902e603c7e3e25de5e5f49c1116dd5a5743b
// Listen for preview site built events
window.Echo.channel("filament-notifications")
.listen("preview-site.built", function(event) {
console.log("🎉 Received preview site built event:", event);
// Use Filament v4 notification system
if (typeof FilamentNotification !== "undefined") {
new FilamentNotification()
@ -128,22 +120,22 @@ class AdminPanelProvider extends PanelProvider
display: block !important;
opacity: 1 !important;
`;
notification.innerHTML = `
<div style="display: flex; align-items: center; justify-content: space-between;">
<div style="margin-right: 15px;">
${event.message}
</div>
<button onclick="this.parentElement.parentElement.remove()"
<button onclick="this.parentElement.parentElement.remove()"
style="background: none; border: none; color: white; font-size: 18px; cursor: pointer; padding: 0;">
×
</button>
</div>
`;
document.body.appendChild(notification);
console.log("✅ Created fallback notification");
// Auto-remove after 5 seconds
setTimeout(() => {
if (notification.parentNode) {
@ -154,11 +146,8 @@ class AdminPanelProvider extends PanelProvider
})
.listen(".preview-site.built", function(event) {
console.log("🔄 Also listening with dot prefix (the working one):", event);
<<<<<<< HEAD
console.log("message:", event.message);
=======
>>>>>>> 4143902e603c7e3e25de5e5f49c1116dd5a5743b
// Use Filament v4 notification system
if (typeof FilamentNotification !== "undefined") {
new FilamentNotification()
@ -188,22 +177,22 @@ class AdminPanelProvider extends PanelProvider
display: block !important;
opacity: 1 !important;
`;
notification.innerHTML = `
<div style="display: flex; align-items: center; justify-content: space-between;">
<div style="margin-right: 15px;">
🔄 ${event.message}
</div>
<button onclick="this.parentElement.parentElement.remove()"
<button onclick="this.parentElement.parentElement.remove()"
style="background: none; border: none; color: white; font-size: 18px; cursor: pointer; padding: 0;">
×
</button>
</div>
`;
document.body.appendChild(notification);
console.log("✅ Created dot prefix fallback notification");
// Auto-remove after 5 seconds
setTimeout(() => {
if (notification.parentNode) {
@ -212,7 +201,7 @@ class AdminPanelProvider extends PanelProvider
}, 5000);
}
});
console.log("✅ Event listeners set up for filament-notifications channel");
} else {
console.error("❌ Echo is not available for Filament notifications");