{% extends "cosinnus/base.html" %}
{% load i18n thumbnail cosinnus_tags %}

{% block page_title %}{% trans "Map" %}{% endblock %}

{% block extrahead %}
    {{ block.super }}
    
    {% comment %}  
    	TODO FIXME: clean up COSINNUS_MAP_MARKER_ICONS so they are not in global context anymore, but instead get
    	put into a proper global cosinnus Object (once this object has been created)
    {% endcomment %}
	<script type="text/javascript">var COSINNUS_MAP_MARKER_ICONS = JSON.parse('{{ markers|safe }}');</script>
    <script type="text/javascript">var COSINNUS_MAP_TOPICS_HTML = '{% render_cosinnus_topics_field "escape" %}';</script>
    
	{% include 'cosinnus/map/static_dependencies.html' %}
{% endblock extrahead %}

{% block main_page %}
    <div class="row">
    	{% include 'cosinnus/common/internet_explorer_not_supported.html' %}
    
        {% comment %} Settings for this map are initialized in the extraheader, and passed in a router.js, and uses a lot of
                       the default settings defined in map.js.        
        {% endcomment %}
        <div id="map-fullscreen" class="map-root"></div>
        {% comment %}
            {% include 'cosinnus/common/init_client_module.html' with module='map' id=1 height=400 settings=settings %}
            {% include 'cosinnus/common/init_client_module.html' with module='map' id=2 height=800 settings=settings %}
        {% endcomment %}
    </div>

{% endblock main_page %}
