angular / components

Component infrastructure and Material Design components for Angular
https://material.angular.io
MIT License
24.33k stars 6.74k forks source link

bug(material/datepicker): descender of letter gets cut off with `outline` appearance #22125

Closed PhilippeMorier closed 3 years ago

PhilippeMorier commented 3 years ago

Overview of the Issue

When having a datepicker with the appearance set to outline the descenders within the label (for placeholder) get slightly cut off.

Descender Source: https://typography.fandom.com/wiki/Descender

Angular and Material Versions

"@angular/animations": "^11.2.4", "@angular/cdk": "^11.2.3", "@angular/common": "^11.2.4", "@angular/compiler": "^11.2.4", "@angular/core": "^11.2.4", "@angular/forms": "^11.2.4", "@angular/material": "^11.2.3", "@angular/material-moment-adapter": "^11.2.3", "@angular/platform-browser": "^11.2.4", "@angular/platform-browser-dynamic": "^11.2.4", "@angular/router": "^11.2.4", "core-js": "^3.9.1", "moment": "^2.29.1", "rxjs": "^6.6.6", "tslib": "^2.1.0", "zone.js": "^0.11.4"

Motivation for or Use Case

I'd like to use the datepicker with the appearance outline without cut off descenders. It doesn't provide an optimal UX and overall impression.

Browsers and Operating System

Issue observed on macOS Big Sur 11.2.2 with following browsers:

Reproduce the Error

See this Stackblitz.

Screenshots

Cut off "g"
2021-03-04 07 50 12 2021-03-04 07 56 36

Related Issues

N/A

Suggest a Fix

One could set the height of the label to 19px or remove overflow: hidden; on .mat-form-field-label but that doesn't feel like we're fixing the root cause 🤕 .

crisbeto commented 3 years ago

I believe that this has the same root cause as https://github.com/angular/components/issues/20370.

angular-automatic-lock-bot[bot] commented 3 years ago

This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.