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

187
Visualizações
Unintended ion-textarea focus on ion-modal backdrop click, native keyboard showing for a short time

I've been working on an app that opens a modal with a few buttons and an ion-textarea. After clicking the backdrop of the modal, the textarea would focus for a short period of time and open the native keyboard of the device, which is unintended. After looking on StackOverflow and the ionic framework forum, I didn't find a fix for this bug so I tried fixing it myself.

Eventually, I figured out that adding an ion-input to the page and hiding it from the user, prevents the modal from focussing on the textarea on modal dismiss.

This might not be the most clean fix, but it sure beats the user from seeing the keyboard for a short time when he does not click the ion-textarea element.

HTML: <ion-input class="keyboard-focus-bugfix"></ion-input>

SCSS:

.keyboard-focus-bugfix {
  display: none;
}
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