diff options
Diffstat (limited to 'project/templates/tags')
-rw-r--r-- | project/templates/tags/application.xhtml | 30 | ||||
-rw-r--r-- | project/templates/tags/base_tag.xhtml | 43 | ||||
-rw-r--r-- | project/templates/tags/binding.xhtml | 30 | ||||
-rw-r--r-- | project/templates/tags/compsci.xhtml | 30 | ||||
-rw-r--r-- | project/templates/tags/copyright.xhtml | 30 | ||||
-rw-r--r-- | project/templates/tags/esoteric.xhtml | 30 | ||||
-rw-r--r-- | project/templates/tags/language.xhtml | 30 | ||||
-rw-r--r-- | project/templates/tags/legal.xhtml | 30 | ||||
-rw-r--r-- | project/templates/tags/library.xhtml | 30 | ||||
-rw-r--r-- | project/templates/tags/maps.xhtml | 30 | ||||
-rw-r--r-- | project/templates/tags/mathematics.xhtml | 30 | ||||
-rw-r--r-- | project/templates/tags/politics.xhtml | 30 | ||||
-rw-r--r-- | project/templates/tags/programming.xhtml | 30 | ||||
-rw-r--r-- | project/templates/tags/transport.xhtml | 30 | ||||
-rw-r--r-- | project/templates/tags/videogames.xhtml | 30 |
15 files changed, 99 insertions, 364 deletions
diff --git a/project/templates/tags/application.xhtml b/project/templates/tags/application.xhtml index 82c2a5f..421fa20 100644 --- a/project/templates/tags/application.xhtml +++ b/project/templates/tags/application.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Application Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Application</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'application' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Application") }}{%- endblock -%} +{%- block content %}{{ tag_content ("Application") }}{% endblock -%} +{%- block footer -%}{{ tag_footer ("application.xhtml") }}{%- endblock -%} diff --git a/project/templates/tags/base_tag.xhtml b/project/templates/tags/base_tag.xhtml new file mode 100644 index 0000000..a2c8b9f --- /dev/null +++ b/project/templates/tags/base_tag.xhtml @@ -0,0 +1,43 @@ + +{%- extends "base_plain.xhtml" -%} + + + +{%- macro tag_title(label) -%}{{ label | capitalize }} Tag{%- endmacro -%} + + + +{%- block style %} + <link href="/css/index.css" rel="stylesheet" /> +{% endblock -%} + + + +{%- macro tag_content(label) %} +<h4>Tag: {{ label | capitalize }}</h4> + +<ul class="index"> + {%- for item in articles -%} + {%- if label|lower in item.taglist -%} + {%- if item.updated -%} + {%- set postclass = "update" -%} + {%- set postverb = "Updated" -%} + {%- else -%} + {%- set postclass = "post" -%} + {%- set postverb = "Posted" -%} + {%- endif %} + <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> + <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> + <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> + {%- endif -%} + {%- endfor %} +</ul> +{% endmacro -%} + + + +{%- macro tag_footer(anchor) -%} + {{ plain_footer ('tags/' ~ anchor) }} +{%- endmacro -%} + + diff --git a/project/templates/tags/binding.xhtml b/project/templates/tags/binding.xhtml index 794e595..b27a954 100644 --- a/project/templates/tags/binding.xhtml +++ b/project/templates/tags/binding.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Binding Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Binding</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'binding' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Binding") }}{%- endblock -%} +{%- block content -%}{{ tag_content ("Binding") }}{%- endblock -%} +{%- block footer -%}{{ tag_footer ("binding.xhtml") }}{%- endblock -%} diff --git a/project/templates/tags/compsci.xhtml b/project/templates/tags/compsci.xhtml index 741cf51..cf2160b 100644 --- a/project/templates/tags/compsci.xhtml +++ b/project/templates/tags/compsci.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Compsci Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Compsci</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'compsci' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Compsci") }}{%- endblock -%} +{%- block content %}{{ tag_content ("Compsci") }}{% endblock -%} +{%- block footer -%}{{ tag_footer ("compsci.xhtml") }}{%- endblock -%} diff --git a/project/templates/tags/copyright.xhtml b/project/templates/tags/copyright.xhtml index dfe6295..d37a6e3 100644 --- a/project/templates/tags/copyright.xhtml +++ b/project/templates/tags/copyright.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Copyright Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Copyright</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'copyright' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Copyright") }}{%- endblock -%} +{%- block content %}{{ tag_content ("Copyright") }}{% endblock -%} +{%- block footer -%}{{ tag_footer ("copyright.xhtml") }}{%- endblock -%} diff --git a/project/templates/tags/esoteric.xhtml b/project/templates/tags/esoteric.xhtml index 917851c..015c0c2 100644 --- a/project/templates/tags/esoteric.xhtml +++ b/project/templates/tags/esoteric.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Esoteric Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Esoteric</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'esoteric' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Esoteric") }}{%- endblock -%} +{%- block content %}{{ tag_content ("Esoteric") }}{% endblock -%} +{%- block footer -%}{{ tag_footer ("esoteric.xhtml") }}{%- endblock -%} diff --git a/project/templates/tags/language.xhtml b/project/templates/tags/language.xhtml index 7669da9..801ed77 100644 --- a/project/templates/tags/language.xhtml +++ b/project/templates/tags/language.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Language Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Language</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'language' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Language") }}{%- endblock -%} +{%- block content %}{{ tag_content ("Language") }}{% endblock -%} +{%- block footer -%}{{ tag_footer ("language.xhtml") }}{%- endblock -%} diff --git a/project/templates/tags/legal.xhtml b/project/templates/tags/legal.xhtml index 1d97d7a..109e751 100644 --- a/project/templates/tags/legal.xhtml +++ b/project/templates/tags/legal.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Legal Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Legal</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'legal' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Legal") }}{%- endblock -%} +{%- block content %}{{ tag_content ("Legal") }}{% endblock -%} +{%- block footer -%}{{ tag_footer ("legal.xhtml") }}{%- endblock -%} diff --git a/project/templates/tags/library.xhtml b/project/templates/tags/library.xhtml index 3f9c2fc..e3a47c5 100644 --- a/project/templates/tags/library.xhtml +++ b/project/templates/tags/library.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Library Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Library</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'library' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Library") }}{%- endblock -%} +{%- block content %}{{ tag_content ("Library") }}{% endblock -%} +{%- block footer -%}{{ tag_footer ("library.xhtml") }}{%- endblock -%} diff --git a/project/templates/tags/maps.xhtml b/project/templates/tags/maps.xhtml index 8fe15e5..c61e928 100644 --- a/project/templates/tags/maps.xhtml +++ b/project/templates/tags/maps.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Maps Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Maps</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'maps' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Maps") }}{%- endblock -%} +{%- block content %}{{ tag_content ("Maps") }}{% endblock -%} +{%- block footer -%}{{ tag_footer ("maps.xhtml") }}{%- endblock -%} diff --git a/project/templates/tags/mathematics.xhtml b/project/templates/tags/mathematics.xhtml index 4441004..38a0022 100644 --- a/project/templates/tags/mathematics.xhtml +++ b/project/templates/tags/mathematics.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Mathematics Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Mathematics</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'mathematics' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Mathematics") }}{%- endblock -%} +{%- block content %}{{ tag_content ("Mathematics") }}{% endblock -%} +{%- block footer -%}{{ tag_footer ("mathematics.xhtml") }}{%- endblock -%} diff --git a/project/templates/tags/politics.xhtml b/project/templates/tags/politics.xhtml index 7cc490f..15fd2a9 100644 --- a/project/templates/tags/politics.xhtml +++ b/project/templates/tags/politics.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Politics Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Politics</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'politics' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Politics") }}{%- endblock -%} +{%- block content %}{{ tag_content ("Politics") }}{% endblock -%} +{%- block footer -%}{{ tag_footer ("politics.xhtml") }}{%- endblock -%} diff --git a/project/templates/tags/programming.xhtml b/project/templates/tags/programming.xhtml index d4ca315..d5a0035 100644 --- a/project/templates/tags/programming.xhtml +++ b/project/templates/tags/programming.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Programming Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Programming</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'programming' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Programming") }}{%- endblock -%} +{%- block content %}{{ tag_content ("Programming") }}{% endblock -%} +{%- block footer -%}{{ tag_footer ("programming.xhtml") }}{%- endblock -%} diff --git a/project/templates/tags/transport.xhtml b/project/templates/tags/transport.xhtml index 0881d37..d5d3c3c 100644 --- a/project/templates/tags/transport.xhtml +++ b/project/templates/tags/transport.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Transport Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Transport</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'transport' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Transport") }}{%- endblock -%} +{%- block content %}{{ tag_content ("Transport") }}{% endblock -%} +{%- block footer -%}{{ tag_footer ("transport.xhtml") }}{%- endblock -%} diff --git a/project/templates/tags/videogames.xhtml b/project/templates/tags/videogames.xhtml index ea820a8..2f87308 100644 --- a/project/templates/tags/videogames.xhtml +++ b/project/templates/tags/videogames.xhtml @@ -1,32 +1,10 @@ -{%- extends "base_plain.xhtml" -%} +{%- extends "tags/base_tag.xhtml" -%} -{%- block title -%}Videogames Tag{%- endblock -%} - - - -{%- block style %} - <link href="/css/index.css" rel="stylesheet" /> -{% endblock -%} - - - -{%- block content %} -<h4>Tag: Videogames</h4> - -<ul class="index"> - {%- for item in articles -%} - {%- if 'videogames' in item.taglist -%} - {%- if item.updated -%}{%- set postclass = "update" -%}{%- else -%}{%- set postclass = "post" -%}{%- endif -%} - {%- if item.updated -%}{%- set postverb = "Updated" -%}{%- else -%}{%- set postverb = "Posted" -%}{%- endif %} - <li><a href="{{ item.anchor }}">{{ item.title }}</a><br /> - <span class="taglist">{{ item.taglist | join(", ") }}</span><br /> - <span class="{{ postclass }}">({{ postverb }} {{ item.postdate }})</span></li> - {%- endif -%} - {%- endfor %} -</ul> -{% endblock -%} +{%- block title -%}{{ tag_title ("Videogames") }}{%- endblock -%} +{%- block content %}{{ tag_content ("Videogames") }}{% endblock -%} +{%- block footer -%}{{ tag_footer ("videogames.xhtml") }}{%- endblock -%} |