material_admin-8.x-1.0-alpha7/templates/misc/description.html.twig
templates/misc/description.html.twig
{#
/**
* @file
* Description styling
*
* Available variables:
* - description: Either a singleton (markup), or an array in the format:
* - content: A description of the form element, may not be set.
* - attributes: (optional) A list of HTML attributes to apply to the
* description content wrapper. Will only be set when description is set.
#}
{%
set description_classes = [
'description',
description_display == 'invisible' ? 'visually-hidden',
]
%}
{% if description is not iterable %}
{%
set description = {
content: description,
attributes: create_attribute({}),
}
%}
{% endif %}
{% if description.content is not empty %}
<div{{ description.attributes.addClass(description_classes) }}>
<a class="tooltipped" data-position="bottom" data-enter-delay="50" data-tooltip="{{ render_var(description.content) | e('html_attr') }}"> <i class="material-icons" aria-hidden="true">help_outline</i> Info </a>
</div>
{% endif %}
