🇦🇪 🇨🇳 🇫🇷 🇮🇹 🇳🇱 🇵🇹 🇪🇸
Support • Installation • Contributing
Spryker OS is initially equipped with English (US) and German (Germany) translations. This package extends support to include the following additional languages:
- Arabic (United Arab Emirates) - ar_AE
- Chinese (China) - zh_CN
- French (France) - fr_FR
- Italian (Italy) - it_IT
- Dutch (Netherlands) - nl_NL
- Portuguese (Portugal) - pt_PT
- Spanish (Spain) - es_ES
Note
The initial version of these translations are created by AI. By releasing these to our community on GitHub and accepting PRs, we aim to improve this AI-generated baseline further with YOUR contributions!
Try it yourself for generating your customer-specific project translations to any language by installing the Spryker Community Toolkit.
Install the translations composer package:
composer require spryker-community/spryker-translations
The translations for the Yves storefront depend on the Spryker Suite you are using. You can find them under the Yves/[Your-Spryker-Suite]
directory in this repository.
Append the new translations for the desired languages to the project glossary data/import/common/common/glossary.csv
.
You can find them at vendor/spryker-community/spryker-translations/Yves/[Your-Spryker-Suite]/glossary/[Your-Language-Locale].csv
.
For instance, if you are using the Spryker B2C suite and need the translations for Spanish (Spain), you can easily run the following command:
cat vendor/spryker-community/spryker-translations/Yves/b2c-demo-shop/glossary/es_ES.csv >> data/import/common/common/glossary.csv
console data:import:glossary
Extend the translator configuration at the project level for loading the translations.
<?php
namespace Pyz\Zed\Translator;
use Spryker\Zed\Translator\TranslatorConfig as SprykerTranslatorConfig;
class TranslatorConfig extends SprykerTranslatorConfig
{
/**
* @return array<string>
*/
public function getCoreTranslationFilePathPatterns(): array
{
$coreTranslationFilePathPatterns = parent::getCoreTranslationFilePathPatterns();
// load all translations for all locales
$coreTranslationFilePathPatterns[] = APPLICATION_VENDOR_DIR . '/spryker-community/spryker-translations/Zed/*/[a-z][a-z]_[A-Z][A-Z].csv';
// or only load the es_ES specific translations
$coreTranslationFilePathPatterns[] = APPLICATION_VENDOR_DIR . '/spryker-community/spryker-translations/Zed/*/es_ES.csv';
return $coreTranslationFilePathPatterns;
}
}
console cache:empty-all
We love being international here. The more languages Spryker OS will speak, the happier we will be. There is already a lot of happiness at Spryker, but let's bring some more! We love contributions, big or small.
Give us a hand. Please don't forget to read the contribution guidelines.
This package is released under the MIT license
Supported with ❤️ by the Spryker Community