flot-examples.html.twig in Flot 8
{% extends "flot-element.html.twig" %}
{% block content %}
{{ attach_library('flot_examples/flot_examples') }}
{% if title is not null %}
<h3>{{ title }}</h3>
{% endif %}
{% block demo %}
<div class="demo-container" style="{{ demo_container_attributes }}">
{% block container %}
{% if id is defined %}
<div id="{{ id }}" class="demo-placeholder"></div>
{% else %}
<div id="placeholder" class="demo-placeholder"></div>
{% endif %}
{% endblock container %}
</div>
{% endblock demo %}
{% block description %}
{% for paragraph in text %}
{% if paragraph is iterable %}
{% if paragraph.setp == true %}
<p>
{% endif %}
{% for key,snip in paragraph %}
{% if key|trim != "setp" %}
{{ snip }}
{% endif %}
{% endfor %}
{% if paragraph.setp == true %}
</p>
{% endif %}
{% else %}
<p>
{{ paragraph }}
</p>
{% endif %}
{% endfor %}
{% endblock description %}
{% endblock content%}
File
flot_examples/templates/flot-examples.html.twig
View source
- {% extends "flot-element.html.twig" %}
- {% block content %}
- {{ attach_library('flot_examples/flot_examples') }}
- {% if title is not null %}
- <h3>{{ title }}</h3>
- {% endif %}
- {% block demo %}
- <div class="demo-container" style="{{ demo_container_attributes }}">
- {% block container %}
- {% if id is defined %}
- <div id="{{ id }}" class="demo-placeholder"></div>
- {% else %}
- <div id="placeholder" class="demo-placeholder"></div>
- {% endif %}
- {% endblock container %}
- </div>
- {% endblock demo %}
- {% block description %}
- {% for paragraph in text %}
- {% if paragraph is iterable %}
- {% if paragraph.setp == true %}
- <p>
- {% endif %}
- {% for key,snip in paragraph %}
- {% if key|trim != "setp" %}
- {{ snip }}
- {% endif %}
- {% endfor %}
- {% if paragraph.setp == true %}
- </p>
- {% endif %}
- {% else %}
- <p>
- {{ paragraph }}
- </p>
- {% endif %}
- {% endfor %}
- {% endblock description %}
- {% endblock content%}