bug(cdkTextareaAutosize): Autosize does not properly compute line heights when min-height or height is set via css
- 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?
- [ ] Yes, this behavior used to work in the previous version
### The previous version in which this bug was not present was
_No response_
### Description
When `height` or `min-height` is set on a `textarea`, cdkTextareaAutosize does not properly calculate the line height.
I have a pull request ready to fix this issue, and will submit it shortly.
### Reproduction
StackBlitz link: https://stackblitz.com/edit/components-issue-mopjkj?file=src%2Fapp%2Fexample-component.css
### Expected Behavior
`height` and `min-height` should not affect the line height used to calculate the height based on min rows.
### Actual Behavior
`height` and `min-height` do affect the line height.
### Environment
- Angular: 16.2
- CDK/Material: 16.2
- Browser(s): Chrome (current)
Guide de contribution
Ouvrir le guide de contribution
Piste de recherche
Commencez par l’implémentation de cdkTextareaAutosize et reproduisez le comportement à l’aide de l’exemple StackBlitz lié, en particulier de son fichier src/app/example-component.css. Vérifiez comment CSS height et min-height influencent la hauteur de ligne calculée, puis confirmez que le dimensionnement de min-row n’utilise plus ces 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
- 25/100