You are here

README.txt in Entity Translation Unified Form 8

Same filename and directory in other branches
  1. 7 README.txt
# INTRODUCTION

Entity Translation Unified Form allows creation of multilingual node content on one form.

# Configuration

Visit the content language page (admin/config/regional/content-language). Next to a content-translatable entity type, enable "Place all content-translatable fields for all enabled languages inline on the node add/edit form". When that box is checked, a new select box will appear for the "Display Mode".

1) Enable translateable for your content type (leftmost checkbox)
2) Check /enable "Place all content-translateable fields for all enabled languages inline on the entity add/edit form and select "inline mode"
3) Check /enable "Enable side-by-side UI mode on the node add/edit form

Do not disable sync mode unless you really know what you're doing.

remember to also adjust translateability on your "fields" for the content type

recommend using field groups to place non-translateable fields in those groups so they don't whack out the node edit form

recommend to stick with Inline mode.


By default, the Inline Mode will be the selected Display Mode. If the "Display Mode" is set to "Tabbed Mode", please see the requirements below.

# Display Modes

There are two display mode plugins included with this module:

* Inline Mode
* Tabbed Mode

Additional modes can be added using the Drupal plugin system. Copy and extend one of the classes in the src/Plugin/EntityTranslationUnifiedFormMode folder to the same subfolder in your own module to add a mode.

## Inline Mode

In this mode, the additional language fields are displayed after the current language field. Field titles are appended with their language in parentheses. i.e. Title (English)

## Inline Mode with side by side mode

There is a new side-by-side mode, in the content type settings under publishing options enable the checkbox for this mode.
For complex content types, create two form groups in the form display, one a details group and the other a sidebar group, put the non-translateable fields in the details group and move this group underneith the translatable fields, put other fields as you wish in the sidebar group.  This ensures optimal view mode, side by side only works 992px and higher.


## Tabbed Mode

This mode applies the "A11Y Accordion Tabs" js from https://github.com/matthiasott/a11y-accordion-tabs.

Much of the style and integration was taken and adapted from the "A11Y Paragraphs Tabs" Drupal module: https://www.drupal.org/project/a11y_paragraphs_tabs

### Tabbed Mode Requirements

The A11Y Accordion Tabs js library must be placed in the Drupal /libraries path:

* Download the "A11Y Accordion Tabs" js library:
    https://github.com/matthiasott/a11y-accordion-tabs
* Extract and rename it to "a11y-accordion-tabs", so the assets are at:
    /libraries/a11y-accordion-tabs/a11y-accordion-tabs.js

### Installing A11Y Accordion Tabs using composer

In composer.json under repositories, add the following:
    {
        "type": "package",
        "package": {
            "name": "matthiasott/a11y-accordion-tabs",
            "version": "0.4.1",
            "dist": {
                "url": "https://github.com/matthiasott/a11y-accordion-tabs/archive/v0.4.1.zip",
                "type": "zip"
            },
            "type": "drupal-library"
        }
    },

Then run the following command:
    composer require matthiasott/a11y-accordion-tabs

Also, for the preview functionality to work correctly you must also use the following drupal core patch:
https://www.drupal.org/files/issues/2020-06-20/node-preview_current_language-3150728-12.patch

File

README.txt
View source
  1. # INTRODUCTION
  2. Entity Translation Unified Form allows creation of multilingual node content on one form.
  3. # Configuration
  4. Visit the content language page (admin/config/regional/content-language). Next to a content-translatable entity type, enable "Place all content-translatable fields for all enabled languages inline on the node add/edit form". When that box is checked, a new select box will appear for the "Display Mode".
  5. 1) Enable translateable for your content type (leftmost checkbox)
  6. 2) Check /enable "Place all content-translateable fields for all enabled languages inline on the entity add/edit form and select "inline mode"
  7. 3) Check /enable "Enable side-by-side UI mode on the node add/edit form
  8. Do not disable sync mode unless you really know what you're doing.
  9. remember to also adjust translateability on your "fields" for the content type
  10. recommend using field groups to place non-translateable fields in those groups so they don't whack out the node edit form
  11. recommend to stick with Inline mode.
  12. By default, the Inline Mode will be the selected Display Mode. If the "Display Mode" is set to "Tabbed Mode", please see the requirements below.
  13. # Display Modes
  14. There are two display mode plugins included with this module:
  15. * Inline Mode
  16. * Tabbed Mode
  17. Additional modes can be added using the Drupal plugin system. Copy and extend one of the classes in the src/Plugin/EntityTranslationUnifiedFormMode folder to the same subfolder in your own module to add a mode.
  18. ## Inline Mode
  19. In this mode, the additional language fields are displayed after the current language field. Field titles are appended with their language in parentheses. i.e. Title (English)
  20. ## Inline Mode with side by side mode
  21. There is a new side-by-side mode, in the content type settings under publishing options enable the checkbox for this mode.
  22. For complex content types, create two form groups in the form display, one a details group and the other a sidebar group, put the non-translateable fields in the details group and move this group underneith the translatable fields, put other fields as you wish in the sidebar group. This ensures optimal view mode, side by side only works 992px and higher.
  23. ## Tabbed Mode
  24. This mode applies the "A11Y Accordion Tabs" js from https://github.com/matthiasott/a11y-accordion-tabs.
  25. Much of the style and integration was taken and adapted from the "A11Y Paragraphs Tabs" Drupal module: https://www.drupal.org/project/a11y_paragraphs_tabs
  26. ### Tabbed Mode Requirements
  27. The A11Y Accordion Tabs js library must be placed in the Drupal /libraries path:
  28. * Download the "A11Y Accordion Tabs" js library:
  29. https://github.com/matthiasott/a11y-accordion-tabs
  30. * Extract and rename it to "a11y-accordion-tabs", so the assets are at:
  31. /libraries/a11y-accordion-tabs/a11y-accordion-tabs.js
  32. ### Installing A11Y Accordion Tabs using composer
  33. In composer.json under repositories, add the following:
  34. {
  35. "type": "package",
  36. "package": {
  37. "name": "matthiasott/a11y-accordion-tabs",
  38. "version": "0.4.1",
  39. "dist": {
  40. "url": "https://github.com/matthiasott/a11y-accordion-tabs/archive/v0.4.1.zip",
  41. "type": "zip"
  42. },
  43. "type": "drupal-library"
  44. }
  45. },
  46. Then run the following command:
  47. composer require matthiasott/a11y-accordion-tabs
  48. Also, for the preview functionality to work correctly you must also use the following drupal core patch:
  49. https://www.drupal.org/files/issues/2020-06-20/node-preview_current_language-3150728-12.patch