PromptCultureModels class
Class container for currently-supported Culture Models in Confirm and Choice Prompt.
Properties
| Chinese | |
| Dutch | |
| English | |
| French | |
| German | |
| get |
|
| Italian | |
| Japanese | |
| Portuguese | |
| Spanish |
Methods
| map |
Use Recognizers-Text to normalize various potential Locale strings to a standard. |
Property Details
Chinese
Dutch
English
French
German
getSupportedCultures
static getSupportedCultures: () => PromptCultureModel[]
Property Value
() => PromptCultureModel[]
Italian
Japanese
Portuguese
Spanish
Method Details
mapToNearestLanguage(string)
Use Recognizers-Text to normalize various potential Locale strings to a standard.
static function mapToNearestLanguage(cultureCode: string): string
Parameters
- cultureCode
-
string
Represents locale. Examples: "en-US, en-us, EN".
Returns
string
Normalized locale.
Remarks
This is mostly a copy/paste from https://github.com/microsoft/Recognizers-Text/blob/master/JavaScript/packages/recognizers-text/src/culture.ts#L39 This doesn't directly use Recognizers-Text's MapToNearestLanguage because if they add language support before we do, it will break our prompts.