vendor and env first commit

This commit is contained in:
2025-03-28 08:52:46 +01:00
parent f8388bc81b
commit 8f26283832
10976 changed files with 1349952 additions and 2 deletions
@@ -0,0 +1,25 @@
<?php
namespace Vanguard\Announcements\Hooks;
use Illuminate\Contracts\View\View;
use Vanguard\Announcements\Repositories\AnnouncementsRepository;
use Vanguard\Plugins\Contracts\Hook;
class NavbarItemsHook implements Hook
{
public function __construct(private readonly AnnouncementsRepository $announcements)
{
}
/**
* Execute the hook action.
*/
public function handle(): View
{
$announcements = $this->announcements->latest(5);
$announcements->load('creator');
return view('announcements::partials.navbar.list', compact('announcements'));
}
}
@@ -0,0 +1,17 @@
<?php
namespace Vanguard\Announcements\Hooks;
use Illuminate\Contracts\View\View;
use Vanguard\Plugins\Contracts\Hook;
class ScriptsHook implements Hook
{
/**
* Execute the hook action.
*/
public function handle(): View
{
return view('announcements::partials.scripts');
}
}
@@ -0,0 +1,17 @@
<?php
namespace Vanguard\Announcements\Hooks;
use Illuminate\Contracts\View\View;
use Vanguard\Plugins\Contracts\Hook;
class StylesHook implements Hook
{
/**
* Execute the hook action.
*/
public function handle(): View
{
return view('announcements::partials.styles');
}
}