const liveboardEmbed = new LiveboardEmbed(document.getElementById('ts-embed'), {
frameParams: {
width: '100%',
height: '100%',
},
liveboardId: '<%=liveboardGUID%>',
locale: 'es-ES',
});
Customize locale
The display language of the embedded ThoughtSpot UI is determined by the user’s system locale. If your browser locale matches one of the locale options supported by ThoughtSpot, the ThoughtSpot UI automatically changes to that locale. If your browser locale is not supported by ThoughtSpot, the embedded UI is displayed in US English by default. For example, if your browser locale is an unsupported Central American locale, such as Spanish (Mexico) (es-MX), ThoughtSpot launches in en-US. If your browser doesn’t allow you to change the locale, ThoughtSpot launches in the OS locale.
If your organization manages your browser settings, and your administrator or developer has already set your browser locale, ThoughtSpot automatically defaults to that locale.
You can set locale via ThoughtSpot UI, API, and Visual Embed SDK.
Set Locale in the SDK🔗
If you want to set your embedded app view to a specific locale for your application users, you can configure the locale
property in the SDK.
Supported locale IDs🔗
Locale | Language |
---|---|
| Egyptian Arabic |
| Dansk |
| Deutsch |
| English (Australia) |
| English (Canada) |
| English (Germany) |
| English (India) |
| English (United Kingdom) |
| English (United States) |
| Español (Latinoamérica) |
| Español (España) |
| Suomi |
| Français (Canada) |
| Français (France) |
| Italiano |
| Japanese (Japan)/ 日本語 |
| Norsk |
| Nederland |
| Português (Brasil) |
| Português (Portugal) |
| Russian (Russia) |
| Svenska |
| 中文(简体) |
| 中文 (繁體) |
This example sets the locale of the embedded Liveboard to Español
.
The locale
property defines the overall language of the app, and the default formats for numbers, dates, and currencies. To override the default number, date, and currency format set by the locale
parameter, define the following attributes in the init
code as shown in this example:
init({
//...
numberFormatLocale: 'en-US',
dateFormatLocale: 'en-IN',
currencyFormat: 'USD',
});
-
numberFormatLocale
String
Specify your preferred locale identifier. The numbers on the embedded visualizations will be displayed as per the defined format. For example, if you specifyen-US
, large numbers on the visualizations will be displayed with the comma thousands separator and a period decimals separator as shown here:sxxx,xxx.xx
-
dateFormatLocale
String
Specify your preferred locale identifier. For example, settingen_US
shows the date format asMM/dd/yyyy
. -
currencyFormat
String
Specify a three-digit currency ISO code. For example, to set currency format to United States dollar, specifyUSD
.
Locale settings in the UI🔗
ThoughtSpot application users can set their locale preference on the Profile settings page. To open the profile settings page, click the user icon on the top navigation bar and then edit your locale preference.
For more information, see ThoughtSpot Product Documentation.
Set locale via REST API🔗
The following REST API v1 and v2 endpoints allow updating locale preference for ThoughtSpot users:
Limitations🔗
-
ThoughtSpot does not translate column names, object titles, description text, formulas, or metadata entered by the user. For example, if you name a visualization Sales performance in any variant of English and subsequently change the locale to Español, the name of the visualization remains Sales performance.
-
If you specify a currency when uploading data, that currency format does not change when the locale changes.
-
ThoughtSpot translates keywords, operators, and error messages. See Keyword reference for all supported languages.