Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

147
Visualizações
Is there any way to catch keypress events in mobile browser keyboard?

I built a filter functionality for a list of banks. It works fine in desktop: When the user puts in any name, the keypress event occurs and later it call the filter() function.

However, it does not work on mobile, since no keypress event is triggered.

The goal is whenever user put any letter in input filed, it should call that filter() function on mobile. Is there any way to do this?

(this website is built on wix so it use its velo api)

let debounceTimer;

export function search_keyPress(event) { //enable onKeypress for input form , search is the id of input

$w("#clearSearch").show(); //show the cross mark to clear inputs

$w("#search").value; // value of input field

    if (debounceTimer) {
        clearTimeout(debounceTimer);
        debounceTimer = undefined;
    }

    debounceTimer = setTimeout(() => {
        filter($w("#search").value); //ID of input form
    }, 200);
}

let searchWord;

function filter(search) {
    if (searchWord !== search) {
        $w("#bankTableDataset").setFilter(wixData.filter().contains('bankName', search)); // ID of the dataset
        searchWord = search;
    }
}
about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda