webform-share-iframe.html.twig in Webform 6.x
Same filename and directory in other branches
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.
See also
1 theme call to webform-share-iframe.html.twig
- WebformShareIframe::getInfo in modules/
webform_share/ src/ Element/ WebformShareIframe.php - Returns the element properties for this element.
File
modules/webform_share/templates/webform-share-iframe.html.twigView source
- {#
- /**
- * @file
- * 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.
- *
- * @see template_preprocess_webform_share_iframe()
- *
- * @ingroup themeable
- */
- #}
- {%
- set classes = [
- 'webform-share-iframe',
- ]
- %}
- <iframe{{ attributes.addClass(classes) }}></iframe>
- {% if javascript %}
- <script src="{{ script }}"></script>
- <script>iFrameResize({{ options }}, '.webform-share-iframe');</script>
- {% endif %}