Paragraphs view mode

Component ID

2431923

Component name

Paragraphs view mode

Component type

module

Maintenance status

Development status

Component security advisory coverage

not-covered

Component created

Component changed

Component body

Overview

This module allows content editor to switch paragraph view modes in node submit form.

Requirements

Features

  • View mode is setup as a property of paragraphs and is available to all paragraphs types.
  • Only the view modes enabled in bundle settings will be shown in a dropdown list when creating paragraphs
  • Field formatter to render the paragraphs as the view mode selected.

Example of use

  • Create an image paragraph type with an image field and a text field.
  • Setup 3 view modes and make them available in your paragraph type:
    • Image centre
    • Image float left
    • Image float right
  • Add paragraphs field in your content type as how you would normally do with paragraphs
  • In manage display, select the new field formatter "Paragraphs view mode" instead of original "Paragraphs items" formatter.
  • Now content editor can select view mode when they create contents:
    view mode selection

Discussion of this feature can be found https://www.drupal.org/node/2222415