Features
Configurations
Languages & International
supported languages sparklayer supports a range of languages and when a customer signs in, they'll see the appropriate language native to your store sparklayer currently supports the following languages variable language en english (default) english (default) ar arabic (with full rtl support) zh chinese hr croatian cs czech da danish nl dutch fi finnish fr french de german el greek he hebrew (with full rtl support) hu hungarian it italian ja japanese lt lithuanian no norwegian pt portugese ro romanian ru russian sk slovak es spanish sv swedish by default, sparklayer automatically detects the default language of your store but it is possible manually overwrite this if required with the modification of the language variable in the sparklayer core script / modify the below code with the language variable above, e g fr / language {{ request locale iso code | json }}, / end of code / need a language not listed above? if you require a language that isn't on our list, please support docid\ nnuw1g9z7eaj4m78vk7t9 and we can send details on how to supply translations locale configuration sparklayer provides an intuitive formatting system for dates and currency symbols by utilising the locale of the user's browser this ensures dates and currency symbols are displayed according to the user's regional setting, enhancing the user experience however, if you prefer to implement a standard formatting across your user base, sparklayer offers the option to set a specific locale by adjusting the locale option, you can establish a fixed format for all of your users, irrespective of their individual browser settings / modify the below code with the locale required e g en au / locale 'en au', / end of code / the locale option requires a string input, comprised of a combination of a language code and a two letter country code, delineated by a hyphen ( ) for instance, to set the locale for british english, you would use 'en gb' for american english, 'en us' for australian english, 'en au' for german 'de de' etc this format ensures that the chosen locale accurately reflects both the language and the regional conventions for date formatting and currency symbols for your b2b pricing, any currency prefixes will be removed and instead default to the locale you've set for example, if you set the locale to locale 'en us', this would remove the us prefix before your pricing the locale option only affects the formatting of prices, not the values text and language overwrites sparklayer uses "language strings" to render the text used in the frontend interfaces docid\ ccz1vnh0o6d 722w35xpa and any string can be modified with custom text (i e overwritten) if you're wanting to update specific text elements, it's possible to turn on a special setting within the sparklayer core script that exposes specific code snippets that you can then reference with your overwrites / add the below to your sparklayer core script / showtranslations true, / end of code / when this setting is enabled, the sparklayer interface will then render the special language code snippets in our example below, you can see the language code for the product page interface please note we recommend enabling this setting temporarily or onto a non published theme to ensure it isn't seen by your logged in b2b customers modifying languages to overwrite the text, you need to add specific code snippets to the frontend integration guide docid\ qwxsym9x5 pviogutekcp in our example video below, we've shown how to temporarily switch on the special showtranslations setting (see above) and adding text overwrites for pricing display docid\ s vtljborgmnwjjfsmom9 the formatting works by 'cascading' the variables for example, in the code below, you can see how the pdp table price text has been included / add the below code into the sparklayer core script / translations { en { "pdp table price" "price", } }, / end of code / some important items to note the variable en must be replaced with the specific language of your store (see our languages & international docid\ klrs7wtxn3wncdy8z5zvu with their special codes) the text overwrites must always end the line with a comma updating text that contains dynamic variables for some text content, sparklayer includes dynamic variables, such as pack sizing or special settings dynamic variables are always wrapped in 'camel case' , for example {packsize} and you can find a list of all dynamic text below / add the below code into the sparklayer core script / translations { en { // global "global per unit" "{price} per unit", "global product settings pack size" "this product comes in pack sizes of {packsize}", "min order quantity" "each variant has a minimum order quantity of {minorderquantity}", "max order quantity" "each variant has a maximum order quantity of {maxorderquantity}", "min order parent quantity" "this product has a minimum quantity of {minorderparentquantity} across all variants", "max order parent quantity" "this product has a maximum quantity of {maxorderparentquantity} across all variants", // products "pdp setting info pack size" "this product comes in pack sizes of {packsize}", "pdp price pack size" "pack ({packsize}) {price}", "pdp messaging back order due" "due {restockdate}", "pdp messaging stock qty low stock" "only {qty} available", "pdp messaging stock qty last stock" "last {qty} available", "pdp messaging stock qty in stock" "{qty} available", "product card price breaks cheapest" "from {price} for {qty}+", "product card price breaks saving" "(save {per}%)", "product card messaging back order due" "due {restockdate}", // my order "cart no of order lines" "{numberof} {numberof, plural, =1 {line} other {lines}}", "cart no of order items" "{numberof} {numberof, plural, =1 {item} other {items}}", "cart validation messages minimum order totals" "your order must be more than {amount} to meet the order requirements ", "cart validation messages maximum order totals" "your order must be less than {amount} to meet the order requirements ", "cart validation messages minimum parent quantity" "please note, {productname} has a minimum order quantity of {minimum} ", "cart validation messages maximum parent quantity" "please note, {productname} has a maximum order quantity of {maximum} ", "cart validation messages out of stock" "sorry, {sku} is now unavailable please remove this product from your order before checkout", "cart validation messages limited stock available" "sorry, we only have {qty} of {sku} available right now, please adjust the quantity in your order before checkout", "cart checkout confirm btn complete" "complete order {total}", "cart checkout confirm btn checkout" "complete payment {total}", "cart checkout confirm btn quote" "submit quote {total}", "cart thanks payment blurb" "your order has now been placed and you will shortly receive email confirmation to {email} you can check the status of your order at any time by going to 'my account' ", // my account "account main my details payment on account detail" "your account balance is {balance} with a credit limit of {creditlimit} ", "account main my details payment on account detail without limit" "your account balance is {balance} ", } }, / end of code /