chore(admin-ui): tokenise sidebar hover and focus ring with primary tokens

This commit is contained in:
萝卜
2026-03-16 02:13:45 +08:00
parent 35902de44b
commit 2605e1c287
4 changed files with 70 additions and 2 deletions

View File

@@ -0,0 +1,31 @@
<?php
namespace Tests\Feature;
use Illuminate\Foundation\Testing\RefreshDatabase;
use Tests\TestCase;
class AdminThemeCssShouldDefinePrimaryFocusRingTokenTest extends TestCase
{
use RefreshDatabase;
protected function loginAsPlatformAdmin(): void
{
$this->seed();
$this->post('/admin/login', [
'email' => 'platform.admin@demo.local',
'password' => 'Platform@123456',
])->assertRedirect('/admin');
}
public function test_admin_theme_css_should_define_primary_focus_ring_token(): void
{
$this->loginAsPlatformAdmin();
$css = file_get_contents(public_path('css/admin-theme.css'));
$this->assertIsString($css);
$this->assertStringContainsString('--adm-primary-focus-ring', $css);
}
}