mirror of
				https://github.com/pelican-dev/panel.git
				synced 2025-11-04 14:56:51 +01:00 
			
		
		
		
	
		
			
				
	
	
		
			33 lines
		
	
	
		
			799 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
			
		
		
	
	
			33 lines
		
	
	
		
			799 B
		
	
	
	
		
			PHP
		
	
	
	
	
	
<?php
 | 
						|
 | 
						|
namespace App\Filament\Admin\Widgets;
 | 
						|
 | 
						|
use Filament\Actions\CreateAction;
 | 
						|
use Filament\Widgets\Widget;
 | 
						|
 | 
						|
class CanaryWidget extends Widget
 | 
						|
{
 | 
						|
    protected static string $view = 'filament.admin.widgets.canary-widget';
 | 
						|
 | 
						|
    protected static bool $isLazy = false;
 | 
						|
 | 
						|
    protected static ?int $sort = 1;
 | 
						|
 | 
						|
    public static function canView(): bool
 | 
						|
    {
 | 
						|
        return config('app.version') === 'canary';
 | 
						|
    }
 | 
						|
 | 
						|
    public function getViewData(): array
 | 
						|
    {
 | 
						|
        return [
 | 
						|
            'actions' => [
 | 
						|
                CreateAction::make()
 | 
						|
                    ->label(trans('admin/dashboard.sections.intro-developers.button_issues'))
 | 
						|
                    ->icon('tabler-brand-github')
 | 
						|
                    ->url('https://github.com/pelican-dev/panel/issues', true),
 | 
						|
            ],
 | 
						|
        ];
 | 
						|
    }
 | 
						|
}
 |