<?php

namespace App\Http\Requests\Member;

use Illuminate\Foundation\Http\FormRequest;

class SendInterestRequest extends FormRequest
{
    public function authorize(): bool
    {
        return true;
    }

    public function rules(): array
    {
        return [
            // A short message the seeker writes to the freelancer
            // Stored in freelance_matches.seeker_message
            'message' => ['required', 'string', 'min:20', 'max:500'],
        ];
    }

    public function messages(): array
    {
        return [
            'message.required' => __('freelance.validation.message_required'),
            'message.min'      => __('freelance.validation.message_min'),
            'message.max'      => __('freelance.validation.message_max'),
        ];
    }
}
