Closed bartoszlenar closed 3 years ago
Hi @bartoszlenar . I'm going to work on the adaptation to Spanish.
Thank you, @restebanlm. If anything in the issue description is not clear enough, or if you need any additional help or technical guidance, let me know in the comments.
I hope the pull I sent you is useful.
It's great. Thank you.
Already merged in #18
Feature description
ValidatorSettings
so it can be nicely used fromValidator.Factory.Create
.Feature in action
Feature implementation walkthrough
Spanish
directory inside and thenSpanishTranslation.cs
.SpanishTranslation.cs
could be (and should be...) entirely based on the file EnglishTranslation.cs. Please copy-paste the content and replace English phrases with the Spanish ones."Must be equal to {value}"
, don't translate the text between curly brackets{
and}
. The Polish version for this is"Musi być równe {value}"
. As you can see,{value}
stays as it was."Musi być równe {value|culture=pl-PL}"
. So after the variable name (value
) there is a pipeline character|
and then parameter (culture
) with the valuepl-PL
- culture code, the string that goes to the CultureInfo.GetCultureInfo method. To truly understand how it works, please read the section about message arguments in the docsSpanishTranslation.cs
, please createSpanishTranslationExtensions.cs
and copy-paste the content from theEnglishTranslationExtensions.cs
. Just find-and-replaceEnglish
withSpanish
should work just fine.English
- copy-paste it and replaceEnglish
withSpanish
. You can notice thatPolish
is done in a similar way.