Skip to content

Commit

Permalink
update color classes
Browse files Browse the repository at this point in the history
  • Loading branch information
Boy132 committed Nov 8, 2024
1 parent 9f26697 commit 99ac970
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions resources/views/filament/pages/health.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
if(! function_exists('backgroundColor')) {
function backgroundColor($status) {
return match ($status) {
Spatie\Health\Enums\Status::ok()->value => 'bg-emerald-100',
Spatie\Health\Enums\Status::warning()->value => 'bg-yellow-100',
Spatie\Health\Enums\Status::skipped()->value => 'bg-blue-100',
Spatie\Health\Enums\Status::failed()->value, Spatie\Health\Enums\Status::crashed()->value => 'bg-red-100',
default => 'bg-gray-100'
Spatie\Health\Enums\Status::ok()->value => 'text-success-100',
Spatie\Health\Enums\Status::warning()->value => 'text-warning-100',
Spatie\Health\Enums\Status::skipped()->value => 'text-primary-100',
Spatie\Health\Enums\Status::failed()->value, Spatie\Health\Enums\Status::crashed()->value => 'text-danger-100',
default => 'text-gray-100'
};
}
}
Expand All @@ -15,10 +15,10 @@ function backgroundColor($status) {
function iconColor($status)
{
return match ($status) {
Spatie\Health\Enums\Status::ok()->value => 'text-emerald-500',
Spatie\Health\Enums\Status::warning()->value => 'text-yellow-500',
Spatie\Health\Enums\Status::skipped()->value => 'text-blue-500',
Spatie\Health\Enums\Status::failed()->value, Spatie\Health\Enums\Status::crashed()->value => 'text-red-500',
Spatie\Health\Enums\Status::ok()->value => 'text-success-500',
Spatie\Health\Enums\Status::warning()->value => 'text-warning-500',
Spatie\Health\Enums\Status::skipped()->value => 'text-primary-500',
Spatie\Health\Enums\Status::failed()->value, Spatie\Health\Enums\Status::crashed()->value => 'text-danger-500',
default => 'text-gray-500'
};
}
Expand All @@ -32,7 +32,7 @@ function icon($status)
Spatie\Health\Enums\Status::warning()->value => 'tabler-exclamation-circle',
Spatie\Health\Enums\Status::skipped()->value => 'tabler-circle-chevron-right',
Spatie\Health\Enums\Status::failed()->value, Spatie\Health\Enums\Status::crashed()->value => 'tabler-circle-x',
default => ''
default => 'tabler-help-circle'
};
}
}
Expand Down Expand Up @@ -64,7 +64,7 @@ function icon($status)
@endif

@if ($lastRanAt)
<div class="{{ $lastRanAt->diffInMinutes() > 5 ? 'text-red-500' : 'text-gray-400 dark:text-gray-200' }} text-md text-center font-medium">
<div class="{{ $lastRanAt->diffInMinutes() > 5 ? 'text-danger-500' : 'text-gray-400 dark:text-gray-200' }} text-md text-center font-medium">
Check results from {{ $lastRanAt->diffForHumans() }}
</div>
@endif
Expand Down

0 comments on commit 99ac970

Please sign in to comment.