summaryrefslogtreecommitdiffstats
path: root/templates/html/htmljsnavtree.tpl
diff options
context:
space:
mode:
Diffstat (limited to 'templates/html/htmljsnavtree.tpl')
-rw-r--r--templates/html/htmljsnavtree.tpl20
1 files changed, 20 insertions, 0 deletions
diff --git a/templates/html/htmljsnavtree.tpl b/templates/html/htmljsnavtree.tpl
new file mode 100644
index 0000000..a7ad88e
--- /dev/null
+++ b/templates/html/htmljsnavtree.tpl
@@ -0,0 +1,20 @@
+var NAVTREE =
+[
+{% recursetree index.nav %}
+ [ "{{ node.name }}", {% if node.file %}"{{ node.file }}{{ config.HTML_FILE_EXTENSION }}{% if node.anchor %}#{{ node.anchor }}{% endif %}"{% else %}null{% endif %},{% if not node.is_leaf_node %} [
+ {{ children }}
+ ]{% else %} null{% endif %} ]{% if not node.last %},{% endif %}
+{% endrecursetree %}
+];
+
+var NAVTREEINDEX =
+[
+{% with navlist=index.nav|flatten|listsort:config.HTML_FILE_EXTENSION|prepend:'{{file}}'|append:'#{{anchor}}' navpages=navlist|paginate:250 %}
+ {% for page in navpages %}
+ "{{ page.0.file }}{{ config.HTML_FILE_EXTENSION }}{% if page.0.anchor %}#{{ page.0.anchor }}{% endif %}"{% if not forloop.last %},{%endif %}
+ {% with idx=forloop.counter0 entries=page %}
+ {% create forloop.counter0|prepend:'navtreeindex'|append:'.js' from 'htmljsnavindex.tpl' %}
+ {% endwith %}
+ {% endfor %}
+{% endwith %}
+];