You are here

webform-share-iframe.html.twig in Webform 6.x

Same filename and directory in other branches
  1. 8.5 modules/webform_share/templates/webform-share-iframe.html.twig

Default theme implementation of an iframe used to share a webform.

Available variables:

  • attributes: HTML attributes for the iframe element.
  • javascript: Flag to include JavaScript.
  • option: JavaScript options.

File

modules/webform_share/templates/webform-share-iframe.html.twig
View source
  1. {#
  2. /**
  3. * @file
  4. * Default theme implementation of an iframe used to share a webform.
  5. *
  6. * Available variables:
  7. * - attributes: HTML attributes for the iframe element.
  8. * - javascript: Flag to include JavaScript.
  9. * - option: JavaScript options.
  10. *
  11. * @see template_preprocess_webform_share_iframe()
  12. *
  13. * @ingroup themeable
  14. */
  15. #}
  16. {%
  17. set classes = [
  18. 'webform-share-iframe',
  19. ]
  20. %}
  21. <iframe{{ attributes.addClass(classes) }}></iframe>
  22. {% if javascript %}
  23. <script src="{{ script }}"></script>
  24. <script>iFrameResize({{ options }}, '.webform-share-iframe');</script>
  25. {% endif %}