New Branch Structure
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Stylist\Console;
|
||||
|
||||
use Illuminate\Console\Command;
|
||||
use Modules\Stylist\Diagnostics\ThemeInspector;
|
||||
|
||||
final class InspectThemesCommand extends Command
|
||||
{
|
||||
protected $signature = 'stylist:inspect';
|
||||
protected $description = 'Display installed themes, inheritance, entry views, and view counts.';
|
||||
|
||||
public function __construct(private readonly ThemeInspector $inspector)
|
||||
{
|
||||
parent::__construct();
|
||||
}
|
||||
|
||||
public function handle(): int
|
||||
{
|
||||
$themes = $this->inspector->themes();
|
||||
$this->table(['Key', 'Name', 'Parent', 'Entry view', 'Views', 'Path'], array_map(fn (array $theme): array => [
|
||||
$theme['key'], $theme['name'], $theme['parent'] ?? '—', $theme['entry_view'], $theme['views'], $theme['path'],
|
||||
], $themes));
|
||||
|
||||
return self::SUCCESS;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user