{% load i18n %} {# @description A live example: a page of the site running in a frame, beside the source the docs build holds for it. Works without scripts: "Start again" is a link aimed at the frame, and the source files are a radio group. #} {# @prop example:dict | description:"From LiveExamples: id, title, address, available, and sources (each with name and html, the highlighted code)." #}

{% if example.title %} {{ example.title }} {% else %} {% translate "Live example" %} {% endif %}

{% if example.available %} {% endif %}
{% if example.available %}
{% else %}
{% translate "This example isn't available on this site. Its source is still shown." %}
{% endif %}
{% if example.sources|length == 1 %} {% for source in example.sources %}

{{ source.name }}

{{ source.html }}
{% endfor %} {% else %}
{% for source in example.sources %}
{{ source.html }}
{% endfor %}
{% endif %}