any custom value can be set. */ case Translatable; /** * A field can be translated. A prefix is prepended on initial localization like this: * `[Translate to :]` */ case PrefixLanguageTitle; /** * A field is excluded from the translation editing - means, it always has the same value * as the default translation */ case Excluded; public static function tryFromFieldConfiguration(array $fieldConfiguration): self { $l10nMode = $fieldConfiguration['l10n_mode'] ?? null; if ($l10nMode === 'exclude') { return self::Excluded; } if ($l10nMode === 'prefixLangTitle') { return self::PrefixLanguageTitle; } return self::Translatable; } }