Uploaded image for project: 'ui-tenant-settings'
  1. ui-tenant-settings
  2. UITEN-102

use ReactIntl to localize language, region, and currency values

    XMLWordPrintable

Details

    • Task
    • Status: Closed (View Workflow)
    • P3
    • Resolution: Won't Do
    • None
    • None
    • None
    • Firebird Sprint 97
    • 1
    • Firebird

    Description

      ReactIntl can now be used to provide locale-specific translations of language, region, and currency values. As long as we have a list of ISO codes, we can use formatDisplayName to correctly localize the values:

      // When locale is `en`
      formatDisplayName('zh-Hans-SG'); //=> Simplified Chinese (Singapore)
      // When locale is `zh`
      formatDisplayName('zh-Hans-SG'); //=> 简体中文(新加坡)
      
      // When locale is `en`...
      // ISO-4217 currency code to localized display name
      formatDisplayName('CNY', {type: 'currency'}); //=> Chinese Yuan
      // ISO-3166 two letters region code to localized display name
      formatDisplayName('UN', {type: 'region'}); //=> United Nations
      

      TestRail: Results

        Attachments

          Issue Links

            Activity

              People

                mikita_siadykh Mikita Siadykh
                zburke Zak_Burke
                Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved:

                  TestRail: Runs

                    TestRail: Cases