Add custom render hooks to our footer (#1942)

This commit is contained in:
Boy132 2025-11-27 23:55:59 +01:00 committed by GitHub
parent d16e7dd876
commit efa8eef57c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 15 additions and 1 deletions

View File

@ -0,0 +1,9 @@
<?php
namespace App\Enums;
enum CustomRenderHooks: string
{
case FooterStart = 'pelican::footer.start';
case FooterEnd = 'pelican::footer.end';
}

View File

@ -1,7 +1,10 @@
<footer class="flex flex-col items-center justify-center text-center space-y-2 p-4 text-gray-600 dark:text-gray-400"> <footer class="flex flex-col items-center justify-center text-center space-y-2 p-4 text-gray-600 dark:text-gray-400">
{{ \Filament\Support\Facades\FilamentView::renderHook(\App\Enums\CustomRenderHooks::FooterStart->value) }}
<a class="font-semibold" href="https://pelican.dev/docs/#core-team" target="_blank"> <a class="font-semibold" href="https://pelican.dev/docs/#core-team" target="_blank">
&copy; {{ date('Y') }} Pelican &copy; {{ date('Y') }} Pelican
</a> </a>
@if(config('app.debug')) @if(config('app.debug'))
<div class="flex space-x-1 text-xs"> <div class="flex space-x-1 text-xs">
<x-filament::icon <x-filament::icon
@ -11,4 +14,6 @@
<span>{{ round(microtime(true) - LARAVEL_START, 3) }}s</span> <span>{{ round(microtime(true) - LARAVEL_START, 3) }}s</span>
</div> </div>
@endif @endif
</footer>
{{ \Filament\Support\Facades\FilamentView::renderHook(\App\Enums\CustomRenderHooks::FooterEnd->value) }}
</footer>