<?php

namespace App\Modules\Settings\Localization\Resources;

use Illuminate\Http\Request;
use Illuminate\Http\Resources\Json\JsonResource;

class LanguageResource extends JsonResource
{
    /**
     * @return array<string, mixed>
     */
    public function toArray(Request $request): array
    {
        return [
            'id' => $this->id,
            'code' => $this->code,
            'name' => $this->name,
            'native_name' => $this->native_name,
            'is_default' => $this->is_default,
            'is_rtl' => $this->is_rtl,
            'is_active' => $this->is_active,
        ];
    }
}
