You are here

form-mode-manager-add-list.html.twig in Form mode manager 8

Default implementation to present a list of bundles as specific form mode.

Available variables:

  • bundles: A list of bundles, each with the following properties:

    • description: Bundle description.
    • add_link: Link to create an entity of this bundle as specific Form mode.
  • add_bundle_message: The message shown when there are no bundles. Only

File

templates/form-mode-manager-add-list.html.twig
View source
  1. {#
  2. /**
  3. * @file
  4. * Default implementation to present a list of bundles as specific form mode.
  5. *
  6. * Available variables:
  7. * - bundles: A list of bundles, each with the following properties:
  8. * - description: Bundle description.
  9. * - add_link: Link to create an entity of this bundle as specific Form mode.
  10. * - add_bundle_message: The message shown when there are no bundles. Only
  11. *
  12. * @see template_preprocess_form_mode_manager_add_list()
  13. *
  14. * @ingroup themeable
  15. */
  16. #}
  17. {% if types is not empty %}
  18. <dl>
  19. {% for type in types %}
  20. <dt>{{ type.add_link }}</dt>
  21. <dd>{{ type.description }}</dd>
  22. {% endfor %}
  23. </dl>
  24. {% else %}
  25. <p>
  26. {% set create_content = path('node.type_add') %}
  27. {% trans %}
  28. You have not created any content types yet. Go to the <a href="{{ create_content }}">content type creation page</a> to add a new content type.
  29. {% endtrans %}
  30. </p>
  31. {% endif %}