merge: load Leaflet maps in admin template preview
This commit is contained in:
@@ -3,6 +3,10 @@
|
||||
|
||||
{% block title %}Preview - {{ preview.title }} - Admin{% endblock %}
|
||||
|
||||
{% block head %}{{ super() }}
|
||||
<link rel="stylesheet" href="{{ url_for('static', filename='vendor/leaflet/leaflet.min.css') }}">
|
||||
{% endblock %}
|
||||
|
||||
{% block admin_content %}
|
||||
<a href="{{ url_for('admin.template_detail', slug=config.slug) }}" class="text-sm text-slate">← Back to template</a>
|
||||
|
||||
@@ -29,3 +33,8 @@
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
{% block scripts %}
|
||||
<script>window.LEAFLET_JS_URL = '{{ url_for("static", filename="vendor/leaflet/leaflet.min.js") }}';</script>
|
||||
<script src="{{ url_for('static', filename='js/article-maps.js') }}"></script>
|
||||
{% endblock %}
|
||||
|
||||
Reference in New Issue
Block a user