bug(Text field): cdkAutosizeMinRows and cdkAutosizeMaxRows not working
- Langage dominant
- TypeScript
- Étoiles
- 25k
- Forks
- 6.8k
- Merge moyen
- 1 j 8 h
- PR mergées (30 j)
- 91
Description
### Is this a regression?
- [X] Yes, this behavior used to work in the previous version
### The previous version in which this bug was not present was
14.2.7
### Description
cdkAutosizeMinRows and cdkAutosizeMaxRows are not working properly.
### Reproduction
Steps to reproduce:
1. Go to https://material.angular.io/cdk/text-field/examples
2. In the "Auto-resizing textarea" example, type a few lines
### Expected Behavior
In the example, it should grow to 5 lines. I tested the example on stackblitz and changed the min/max values and the size doesn't respect those.
### Actual Behavior
In the example, after the 3rd one, the textarea stopped growing.
In stackblitz, there didn't seem to be any logic based on the value I was entering. There seems to be a hard stop at 6 lines, and it looks like it is 2 lines off (max of 5 shows 3 lines, max of6 shows 4 lines, ...).
### Environment
- Angular: 15.0.0
- CDK/Material: 15.0.2
- Browser(s): Chrome Version 108.0.5359.98 (Official Build) (64-bit)
- Operating System (e.g. Windows, macOS, Ubuntu): Windows 10
Guide de contribution
Ouvrir le guide de contribution
Piste de recherche
Commencez par les exemples CDK text-field à l’adresse https://material.angular.io/cdk/text-field/examples et reproduisez le problème dans l’exemple « Auto-resizing textarea » avec les versions signalées Angular 15.0.0 et CDK/Material 15.0.2. Comparez cdkAutosizeMinRows et cdkAutosizeMaxRows avec la croissance réelle de la zone de texte ; le travail est terminé lorsque l’exemple respecte les deux valeurs.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- angular, typescript
- Domaine
- frontend
- Type d'issue
- Bug
- Difficulté
- 3/5
- Temps estimé
- 1-2 jours
- Activité
- À l'abandon
- Clarté
- Plutôt claire
- Accessibilité débutants
- 48/100