bug: Ion Input ClearInputIcon not working - Angular

Abierto
#30,901 1 comentario 2 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
3/5
Tiempo estimado
1-2 días
Aptitud para principiantes
45/100
Tipo de issue
Error
Claridad
Bastante claro
Estado de actividad
Estancado
Stack tecnológico
angular, typescript
Área
frontend

Línea de trabajo

Comienza con la reproducción enlazada de StackBlitz y el manejo de ion-input en Angular para clearInputIcon; compara el uso como atributo simple con el property binding y el comportamiento existente de clearInput. Se considera terminado cuando el icono indicado se renderiza al habilitar clearInput sin requerir CUSTOM_ELEMENT_SCHEMA y el comportamiento queda documentado si es necesario.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

triage
Prerequisites
Ionic Framework Version

v8.x

Current Behavior

When using ion-input there is a property clearInputIcon where we can put the name of an imported icon as a string, it should replace the icon for the clear option when clearInput property is set to true but I only get the default one

Expected Behavior

When using ion-input there is a property clearInputIcon where we can put the name of an imported icon as a string, it should replace the icon for the clear option when clearInput property is set to true.

Steps to Reproduce
  1. In HTML Set an ion-input
  2. Set property clearInput to true
  3. Set property clearInputIcon to an icon for example "analytics-outline"
  4. In TS/JS import analyticsOutline from ionicons with the addIcons method
  5. You will see that the icon does not change
Code Reproduction URL

https://stackblitz.com/edit/fhf2js9x

Ionic Info

/

Additional Information

I've tested multiple things and the only to make it work is to use the property with binding [] syntax
The problem is that clearInputIcon is not recognized and we need to use the CUSTOM_ELEMENT_SCHEMA which should not happen (since the other properties for example clearInput do not need them).

Without this the component does not seem to recognize and user the clearInputIcon property on the ion-input

Can you check and confirm please ? We should be able to use this property as the other one easily without this, moreover this is not specified in the documentation.

Lenguaje dominante
TypeScript
Estrellas
52.8k
Forks
13.3k
Merge medio
3 d 1 h
PR fusionados (30 d)
86

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de ionic-team/ionic-framework

Todos los issues de ionic-team/ionic-framework

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.