There is 1 update.
 
 
Book Versions / cid:jira-generated-image-avatar-4e1ae485-1e57-4ced-864c-5341844d9f38 BVERSION-56 Open

Add multilingual feature

 
View issue   ·   Add comment
 

1 update

 
cid:jira-generated-image-avatar-e29281b6-3af5-407e-aae3-46379bda6040 Changes by Paul Pantiru on 18/Dec/24 08:07
 
Description: Add support for managing and displaying book content in multiple languages.
h2. Functionality
* Enable/disable multilingual support for a book
* Configure supported languages per book
* Store translated page titles
* Display content in different languages using translation macros
* Support for both versioned and unversioned pages
* Maintain translation inheritance through version chain

h2. Technical Implementation
h3. New Classes

_BookVersions.Code.PageTitleTransaltionClass_
* language (String, required) - Language code
* title (String) - Translated page title
* status (StaticList) - Translation status ("not_translated", "in_progress", "translated") \{code}

 _BookVersions.Code.MultilingualClass_
* enabled (Boolean, required) - Enable/disable feature
* supportedLanguages (StaticList, multiple) - List of supported languages \{code}

h3. Document Structure
* New Languages space under each book containing configuration
* Translation objects stored on: WebHome for unversioned pages / Version-specific content pages for versioned pages
* Translation macro for managing content translations

{code:java}
MyBook
├── Page1 (versioned page)
│   ├── WebHome (redirect)
│   ├── v1.0/ (hidden)
│   │   ├── PageTitleTransaltionClass objects
│   │   └── Content with translation macros
│   └── v2.0/ (hidden)
│       ├── PageTitleTransaltionClass objects
│       └── Content with translation macros
├── UnversionedPage (unversioned page)
│   └── WebHome
│       ├── PageTitleTransaltionClass objects
│       └── Content with translation macros
├── Versions
├── Variants
├── Libraries
└── Languages
    └── WebHome
        └── MultilingualClass object  {code}
h3. New Templates
* Modified templates for versioned/unversioned pages to support multilingual content
* Templates should wrap content in translation macro for default language

h3. Administration
* New administration section in Languages space
* Interface for enabling/disabling multilingual support
* Management of supported languages

h3. Navigation
* Language selector in book navigation menu
* Visual indicators for untranslated content

h2. Acceptance Criteria
* Can enable/disable multilingual support for a book
* Can configure supported languages
* Can add translated titles for pages
* Can add translated content using macros
* Translation inheritance works through version chain
* Language selection persists during navigation
*
Content properly falls back to default language when If translation is missing show warning message or an empty page

h2. Additional Notes
* Translation objects should be migrated when switching between versioned/unversioned pages
* Titles will use translation objects when multilingual is enabled (default language may or may not use an object)
* Content translation is managed through macros