<?php

namespace App\Enums;

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

enum IsActive: int
{
    use WithCommentEnum, WithValueEnum;

    case ACTIVE = 1;
    case INACTIVE = 2;

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

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