I'm trying to create an input multiple so that it only loads data when I have typed 3 characters, but it's not working, can anyone help me quickly?

Select2

class ProdutosSelect extends Select2
{
    protected function onInit()
    {
        $this->multiple(true);

        $this->options([
            // "language" => [
            //     "inputTooShort" => "Digite pelo menos 3 caracteres...",
            //     "searching" => "Buscando produtos...",
            //     "noResults" => "Nenhum produto encontrado"
            // ],
                "minimumInputLength" => 3,
            "ajax" => [
                "delay" => 400,
            ],
            
        ]);
        
    }   

    protected function dataSource()
    {

    if (!$this->value()) {
        return [];
    }

        return AutoMaker::rawSQL("
            SELECT 
                codigo as value, 
                CONCAT(codigo, ' - ', descricao) AS label
            FROM tb_produtos 
            WHERE fk_cliente = :idCliente
            AND ativo IS TRUE
            AND (
                codigo ILIKE :search
                OR descricao ILIKE :search
            )
            LIMIT 50
        ")
        ->params([
            ":idCliente" => $this->app()->user()->others()['id_cliente'],
            ":search" => "%{$search}%"
        ]);
    }

    protected function fields()
    {
        return [
            Text::create("label"),
            Text::create("value"),
        ];
    }

    protected function actionChange($request, $response)
    {
        // $this->sibling("QuantidadeRenegociacao")->update();
    }
}