diff --git a/docs/locale.md b/docs/locale.md new file mode 100644 index 0000000..f13e6fe --- /dev/null +++ b/docs/locale.md @@ -0,0 +1,25 @@ +--- +sidebar_position: 9 +--- + +# Locale + +**What are the languages supported by Topper?** + +Topper supports English and Brazilian Portuguese. + +**How to set a specific locale?** + +By default, Topper will use the locale set on the user's browser. If that locale is not supported it will default to English. + +To set a specific locale, you can set it as query parameter such as: `https://app.topperpay.com/?bt=&locale=en`. The supported values are `en`, `en-US`, `pt` and `pt-BR`. + +When the user user authenticates in Topper, the locale will be set accordingly with the user preferences. + +**Using the [Web SDK](./web-sdk.md):** + +```js +const topper = new TopperWebSdk({ locale: TOPPER_LOCALES.PT }); + +topper.initialize({ bootstrapToken: }); +``` diff --git a/docs/theming.md b/docs/theming.md index 94b7403..6cbd8df 100644 --- a/docs/theming.md +++ b/docs/theming.md @@ -1,5 +1,5 @@ --- -sidebar_position: 9 +sidebar_position: 10 --- # Theming diff --git a/docs/web-sdk.md b/docs/web-sdk.md index 845d379..cac6595 100644 --- a/docs/web-sdk.md +++ b/docs/web-sdk.md @@ -1,5 +1,5 @@ --- -sidebar_position: 10 +sidebar_position: 11 --- # Web SDK