forked from iluwatar/java-design-patterns
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlabels.html
More file actions
35 lines (34 loc) · 1.26 KB
/
labels.html
File metadata and controls
35 lines (34 loc) · 1.26 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
<!-- Template for labels
Parameters:
- include.useLinks: if the labels should be made up of <a> elements (currently only used by the+
sidebar in the patterns.html overview)
- include.categories: list of categories
- include.tags: list of tags
-->
{% include sortedlabels.html %}
<span class="tags">
{% for tag in sortedTags %}
{% if include.tags contains tag.name %}
{% if include.useLinks %}
<a href="javascript:;" class="tag-label" tag="{{ tag.name }}">{{ tag.name }}</a>
{% else %}
<span class="tag-label">{{ tag.name }}</span>
{% endif %}
{% endif %}
{% endfor %}
</span>
<span class="cats">
{% for cat in sortedCats %}
{% if include.categories contains cat.name %}
{% if include.useLinks %}
<a href="javascript:;" class="cat-label" category="{{ cat.name }}">
<i class="{{ cat.icon }}" aria-hidden="true"></i>
{{ cat.name }}</a>
{% else %}
<span class="cat-label">
<i class="{{ cat.icon }}" aria-hidden="true"></i>
{{ cat.name }}</span>
{% endif %}
{% endif %}
{% endfor %}
</span>