Skip to content

bug(datepicker): For some locales, the format used on display is not matching the short date format #31870

@rsi21

Description

@rsi21

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

Hello,

We use the Material date picker to fill several dates and then display them with 'shortDate' pipe.
We also work/switch with from several locales, and we notice some inconsistencies for some of them:

  • de-DE
Image
  • nl-NL
Image

If we look at fr-FR for example, the display is correct and consistent:

Image

I know CDRL is used behind the scene for locale management here, but as datePicker and shortDate are both provided by Angular, i suspect more an inconstentcy between both components.

Reproduction

Steps to reproduce:

  1. Use a sample angular 20 application, and declare provideNativeDateAdapter()
  2. Use natively the DatePicker component to select the date
  3. Use the shortDate pipe to display the select date with the datepicker

Expected Behavior

Consistent display between datePicker and shortDate pipe format.

Actual Behavior

Image

Environment

  • Angular: 20.2.2
  • CDK/Material: 20.2.2
  • Browser(s): Chrome
  • Operating System (e.g. Windows, macOS, Ubuntu): Wndows

Metadata

Metadata

Assignees

No one assigned

    Labels

    P4A relatively minor issue that is not relevant to core functionsarea: material/datepicker

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions