You can easily manage languages from the Crystallize PIM user interface. To get started, click the Settings button on the far left side of the screen, then choose Languages from the left-hand panel.
Use the Add language + button to define additional languages. Each one will require a unique code (ex. “en” for English). Use the Yes/No toggles to designate which of the languages to use as your default. Finally, there are (...) buttons on the right of each language row to edit or delete a language. Any content that was created for that particular language will be permanently lost, so proceed carefully.
Building Content in Different Languages
When new products, documents, and folders are added to the catalogue, there will now be as many different “translations” of each of those items as there are languages defined. When you first browse to an item in the catalogue, you’ll be seeing what everything looks like in the default language. You can then use the Language drop-down at the top of the item editing screen to switch to translations in different languages.
Here, for instance, is a chair that we first see in the default language (English):
Using the Language drop-down, we can switch to the Norwegian (Norsk) translation of the same product:
If you alter the structure of one translation (e.g. by adding/removing components), these changes will carry through to the other translations. You must supply your own content for each translation; Crystallize cannot translate one language into another.
As is typical with catalogue items, every translation starts out in a draft version. Changes are automatically saved, but the translations are not publicly available until published.
To change the default language in which you view and browse through the catalogue, use the Language button in the left-hand panel.
It’s important to note that the paths of translations will be in their target language, and that the language code must be specified correctly in order to retrieve these items programmatically. For instance, you could retrieve either of these:
But this would return null:
If you’re ever unsure about an item’s path and language, you can choose Developer from the View drop-down at the top of the screen to bring up the PIM UI’s internal GraphQL API explorer. The path and language of the translation will be displayed there, and can be copied to your clipboard for use elsewhere.