Open cassied opened 1 year ago
I found a workaround for this issue, adding this scss rule:
label.mat-mdc-floating-label {
&:not(.mdc-floating-label--float-above) {
width: 100%
}
mat-label {
text-overflow: ellipsis;
overflow: hidden;
}
}
Is this a regression?
The previous version in which this bug was not present was
14.2.7
Description
Currently updating from v. 14.2.7 to 16.2.7 (16.2.8 on stackblitz), and I noticed that the date picker isn't handling long labels correctly. Instead of showing an ellipsis, it's overflowing to behind the calendar icon. See examples below:
Version 16.2.8 (bad): https://stackblitz.com/edit/8enoqa?file=src%2Fexample%2Fdatepicker-overview-example.html
Version 14.2.7 (good): https://stackblitz.com/edit/c2yh3u?file=src%2Fapp%2Fdatepicker-overview-example.html
Note: Version 15.2.9 is also showing an incorrect label.
Reproduction
StackBlitz link: https://stackblitz.com/edit/8enoqa?file=src%2Fexample%2Fdatepicker-overview-example.html Steps to reproduce:
Expected Behavior
The label should fit in the allotted space and not show behind the calendar icon.
Actual Behavior
The datepicker label is filling the entire input, behind the calendar icon.
Environment