<?php

namespace App\Enums;

enum ConditionSeverity: string
{
    case Low      = 'low';
    case Medium   = 'medium';
    case High     = 'high';
    case Critical = 'critical';

    public function label(): string
    {
        return match ($this) {
            self::Low      => 'Baja',
            self::Medium   => 'Media',
            self::High     => 'Alta',
            self::Critical => 'Crítica',
        };
    }

    public function color(): string
    {
        return match ($this) {
            self::Low      => 'gray',
            self::Medium   => 'amber',
            self::High     => 'orange',
            self::Critical => 'rose',
        };
    }
}
