mirror of
https://gitlab.unicamp.br/infimecc_drupal11_modules/structural_pages.git
synced 2026-03-10 10:27:41 -03:00
Add content translations for site_sections taxonomy terms
Taxonomy term names are content, not interface strings, so .po files don't translate them. This adds programmatic content translations via the ContentLanguageSettings API and addTranslation/setName on each term. - Add _structural_pages_term_translations() with pt-br name map - Add _structural_pages_add_term_translations() to create/update translations - Add _structural_pages_ensure_content_translation() using ContentLanguageSettings API - Add config/optional for new installs with content_translation enabled - Remove term name entries from .po file (ineffective for content) - Add update hook 10004 to fix existing installations Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,17 @@
|
||||
langcode: en
|
||||
status: true
|
||||
dependencies:
|
||||
config:
|
||||
- taxonomy.vocabulary.site_sections
|
||||
module:
|
||||
- content_translation
|
||||
- taxonomy
|
||||
id: taxonomy_term.site_sections
|
||||
target_entity_type_id: taxonomy_term
|
||||
target_bundle: site_sections
|
||||
default_langcode: site_default
|
||||
language_alterable: true
|
||||
content_translation_enabled: true
|
||||
third_party_settings:
|
||||
content_translation:
|
||||
enabled: true
|
||||
Reference in New Issue
Block a user