mirror of
https://gitlab.ub.uni-bielefeld.de/sfb1288inf/nopaque.git
synced 2024-12-27 20:04:17 +00:00
92 lines
3.1 KiB
Django/Jinja
92 lines
3.1 KiB
Django/Jinja
{% extends "base.html.j2" %}
|
|
{% import "materialize/wtf.html.j2" as wtf %}
|
|
{% import 'corpora/_analysis/concordance.html.j2' as concordance_extension %}
|
|
{% import 'corpora/_analysis/reader.html.j2' as reader_extension %}
|
|
{% import 'corpora/_analysis/static_visualization.html.j2' as static_visualization_extension %}
|
|
|
|
{% set extensions =
|
|
{
|
|
'corpus-analysis-app-concordance-extension': concordance_extension,
|
|
'corpus-analysis-app-reader-extension': reader_extension,
|
|
'corpus-analysis-app-static-visualizations-extension': static_visualization_extension
|
|
}
|
|
%}
|
|
|
|
|
|
{% block main_attribs %} class="service-scheme" data-service="corpus-analysis" id="corpus-analysis-app-container"{% endblock main_attribs %}
|
|
|
|
|
|
{% block page_content %}
|
|
<ul class="row tabs no-autoinit" id="corpus-analysis-app-extension-tabs">
|
|
<li class="tab col s3"><a class="active" href="#corpus-analysis-app-home-container"><i class="nopaque-icons service-icons left" data-service="corpus-analysis"></i>Corpus analysis</a></li>
|
|
{% for id, extension in extensions.items() if extension.name != 'Static Visualization (beta)' %}
|
|
<li class="tab col s3">
|
|
<a href="#{{ id }}-container"><i class="material-icons left">{{ extension.icon }}</i>{{ extension.name }}</a>
|
|
</li>
|
|
{% endfor %}
|
|
</ul>
|
|
|
|
<div id="corpus-analysis-app-home-container">
|
|
<h1>{{ title }}</h1>
|
|
|
|
<div class="row" id="corpus-analysis-app-extension-cards">
|
|
{% for id, extension in extensions.items() if extension.name != 'Static Visualization (beta)' %}
|
|
<div class="col s3">
|
|
<div class="card extension-selector hoverable" data-target="{{ id }}-container">
|
|
<div class="card-content">
|
|
<span class="card-title">{{ extension.name }}</span>
|
|
<p>{{ extension.description }}</p>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{% endfor %}
|
|
</div>
|
|
|
|
{{ static_visualization_extension.container_content('corpus-analysis-app-static-visualizations-extension') }}
|
|
</div>
|
|
|
|
|
|
{% for id, extension in extensions.items() if extension.name != 'Static Visualization (beta)' %}
|
|
<div id="{{ id }}-container">
|
|
{{ extension.container_content(id) }}
|
|
</div>
|
|
{% endfor %}
|
|
{% endblock page_content %}
|
|
|
|
{% block modals %}
|
|
{{ super() }}
|
|
<div class="modal no-autoinit" id="corpus-analysis-app-init-modal">
|
|
<div class="modal-content">
|
|
<h4>We are preparing your analysis session</h4>
|
|
<p>
|
|
Our server works as hard as it can to prepare your analysis session. Please be patient and give it some time.<br>
|
|
If initialization takes longer than usual or an error occurs, <a onclick="window.location.reload()" href="#">reload the page</a>.
|
|
</p>
|
|
<div class="progress">
|
|
<div class="indeterminate"></div>
|
|
</div>
|
|
<p class="status-text"></p>
|
|
<p class="errors error-color-text hide"></p>
|
|
</div>
|
|
</div>
|
|
|
|
{% for id, extension in extensions.items() %}
|
|
{{ extension.modals(id) }}
|
|
{% endfor %}
|
|
{% endblock modals %}
|
|
|
|
{% block scripts %}
|
|
{{ super() }}
|
|
<script>
|
|
const corpusAnalysisApp = new CorpusAnalysisApp({{ corpus.hashid|tojson }});
|
|
</script>
|
|
|
|
{% for id, extension in extensions.items() %}
|
|
{{ extension.scripts(id) }}
|
|
{% endfor %}
|
|
|
|
<script>
|
|
corpusAnalysisApp.init();
|
|
</script>
|
|
{% endblock scripts %}
|