uccser/cs-field-guide

View on GitHub
csfieldguide/templates/interactives/base/iframe.html

Summary

Maintainability
Test Coverage
{% extends "base.html" %}

{% load static %}

{% block title %}
  {{ interactive.name }}
{% endblock title %}

{% block body %}
  {% if not interactive.translation_available %}
    {% with model=interactive %}
      {% include 'generic/not-available-warning.html' %}
    {% endwith %}
  {% else %}
    <style>
      body { padding-top: 0 !important; }
    </style>
    <div class="interactive">
      {% block interactive_html %}
      {% endblock interactive_html %}
    </div>

    <link rel="stylesheet" href="{% static 'css/interactive-iframe.css' %}">
    {% block interactive_css %}
    {% endblock interactive_css %}

    {% block interactive_js %}
    {% endblock interactive_js %}

    <script type="text/javascript" src="{% static 'js/iframe-resizer-content-window.js' %}"></script>
  {% endif %}
{% endblock body %}