<?php

namespace App\Enums;

use App\Traits\Enums\WithCommentEnum;
use App\Traits\Enums\WithValueEnum;

enum IsActive: int
{
    use WithCommentEnum, WithValueEnum;

    case ACTIVE = 1;
    case INACTIVE = 2;

    public function label(): string
    {
        return match ($this) {
            self::ACTIVE => 'Aktif',
            self::INACTIVE => 'Tidak Aktif',
        };
    }

    public function color(): string
    {
        return match ($this) {
            self::ACTIVE => 'emerald',
            self::INACTIVE => 'red',
        };
    }
}
