ContosoUniversityDotNetCore-Pages icon indicating copy to clipboard operation
ContosoUniversityDotNetCore-Pages copied to clipboard

'Data' portion of string is truncated from output in ´[Display(Name="...")]' attributes

Open ranolfi opened this issue 3 years ago • 0 comments

I tried adding the following attribute to this line:

[Display(Name = "Data de Início")]

The rendered output is:

image

Upon investigation, I found this portion of code in file TagConventions.cs:

// Just assume a "Data." prefix for attributes.
            Labels
                .Always
                .ModifyWith(er => er.CurrentTag.Text(er.CurrentTag.Text().Replace("Data ", "")));

This really difficults things because 'Data' is Portuguese for 'Date'.

Most of all, I'm wondering what is the rationale behind that portion of code (introduced in ef7152a8), and whether it can safely be removed.

ranolfi avatar Jul 01 '21 16:07 ranolfi