From bbad8eb5c5df5b3a3fd123da33fed46476535f62 Mon Sep 17 00:00:00 2001 From: Pablo Vazquez Date: Thu, 20 Sep 2018 16:38:17 +0200 Subject: [PATCH] Remove unused project macros file The only macro was render_secondary_navigation, which is in the _navigation.pug template together with the other Blender Cloud navigation macros. --- src/templates/projects/_macros.pug | 58 ------------------------------ 1 file changed, 58 deletions(-) delete mode 100644 src/templates/projects/_macros.pug diff --git a/src/templates/projects/_macros.pug b/src/templates/projects/_macros.pug deleted file mode 100644 index c44ab7b2..00000000 --- a/src/templates/projects/_macros.pug +++ /dev/null @@ -1,58 +0,0 @@ -include ../mixins/components - -| {% macro render_secondary_navigation(project, navigation_links, title) %} - -| {% if project.category == 'course' %} -| {% set category_url = url_for('cloud.courses') %} -| {% elif project.category == 'workshop' %} -| {% set category_url = url_for('cloud.workshops') %} -| {% elif project.category == 'film' %} -| {% set category_url = url_for('cloud.open_projects') %} -| {% else %} -| {% set category_url = url_for('main.homepage') %} -| {% endif %} - -+nav-secondary() - | {% if project.url != 'blender-cloud' %} - | {% if not project.is_private %} - li.text-capitalize - a.nav-link.text-muted.px-0(href="{{ category_url }}") - | {% if project.category == 'film' %} - span Open Projects - | {% elif project.category == 'assets' %} - span Libraries - | {% else %} - span {{ project.category }} - | {% endif %} - li.px-1 - i.pi-angle-right - | {% endif %} - - +nav-secondary-link( - class="px-1 font-weight-bold{% if title == 'landing' %} active{% endif %}", - href="{{url_for('projects.view', project_url=project.url, _external=True)}}") - span {{ project.name }} - | {% endif %} - - | {% for link in navigation_links %} - +nav-secondary-link( - href="{{ link['url'] }}", - class="{% if link['slug'] == title %}active{% endif %}") - span {{ link['label'] }} - | {% endfor %} - - | {% if project.nodes_featured %} - | {# In some cases featured_nodes might might be embedded #} - | {% if '_id' in project.nodes_featured[0] %} - | {% set featured_node_id=project.nodes_featured[0]._id %} - | {% else %} - | {% set featured_node_id=project.nodes_featured[0] %} - | {% endif %} - +nav-secondary-link( - href="{{ url_for('projects.view_node', project_url=project.url, node_id=featured_node_id) }}", - title="Explore {{ project.name }}", - class="{% if title == 'project' %}active{% endif %}") - span Browse - | {% endif %} - -| {% endmacro %}