base.html 5.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  1. <!DOCTYPE html>
  2. <html lang="{{ DEFAULT_LANG }}">
  3. <head>
  4. {% block head %}
  5. <meta name="author" content="{% block meta_author %}{% endblock %}" />
  6. <meta name="description" content="{% block meta_description %}{% endblock %}" />
  7. <meta name="keywords" content="{% block meta_keywords %}{% endblock %}" />
  8. <title>{% block title %}{{ SITENAME }}{% endblock title %}</title>
  9. <meta charset="utf-8" />
  10. <meta name="generator" content="Pelican {{ PELICAN_VERSION }}">
  11. <link rel="stylesheet" id="responsive-style-css" href="{{ SiteProtoDomainTLD }}/theme/css/main.css" type="text/css" media="all" />
  12. <link rel="shortcut icon" type="image/x-icon" href='{{ SiteProtoDomainTLD }}/favicon.ico' />
  13. {% if FEED_ALL_ATOM %}
  14. <link href="{{ FEED_DOMAIN }}/{{ FEED_ALL_ATOM }}" type="application/atom+xml" rel="alternate" title="{{ SITENAME }} Full Atom Feed" />
  15. {% endif %}
  16. {% if FEED_ALL_RSS %}
  17. <link href="{{ FEED_DOMAIN }}/{{ FEED_ALL_RSS }}" type="application/rss+xml" rel="alternate" title="{{ SITENAME }} Full RSS Feed" />
  18. {% endif %}
  19. {% if FEED_ATOM %}
  20. <link href="{{ FEED_DOMAIN }}/{{ FEED_ATOM }}" type="application/atom+xml" rel="alternate" title="{{ SITENAME }} Atom Feed" />
  21. {% endif %}
  22. {% if FEED_RSS %}
  23. <link href="{{ FEED_DOMAIN }}/{{ FEED_RSS }}" type="application/rss+xml" rel="alternate" title="{{ SITENAME }} RSS Feed" />
  24. {% endif %}
  25. {% if CATEGORY_FEED_ATOM and category %}
  26. <link href="{{ FEED_DOMAIN }}/{{ CATEGORY_FEED_ATOM|format(category.slug) }}" type="application/atom+xml" rel="alternate" title="{{ SITENAME }} Categories Atom Feed" />
  27. {% endif %}
  28. {% if CATEGORY_FEED_RSS and category %}
  29. <link href="{{ FEED_DOMAIN }}/{{ CATEGORY_FEED_RSS|format(category.slug) }}" type="application/rss+xml" rel="alternate" title="{{ SITENAME }} Categories RSS Feed" />
  30. {% endif %}
  31. {% if TAG_FEED_ATOM and tag %}
  32. <link href="{{ FEED_DOMAIN }}/{{ TAG_FEED_ATOM|format(tag.slug) }}" type="application/atom+xml" rel="alternate" title="{{ SITENAME }} Tags Atom Feed" />
  33. {% endif %}
  34. {% if TAG_FEED_RSS and tag %}
  35. <link href="{{ FEED_DOMAIN }}/{{ TAG_FEED_RSS|format(tag.slug) }}" type="application/rss+xml" rel="alternate" title="{{ SITENAME }} Tags RSS Feed" />
  36. {% endif %}
  37. {% endblock head %}
  38. </head>
  39. <body>
  40. <header title="First view with nav and either a big picture or a bar.">
  41. <nav>
  42. <ul>
  43. {% for title, link in MENUITEMS %}
  44. <li{% if page == pagePrime %} class="active"{% endif %}><a href="{{ link }}">{{ title }}</a></li>
  45. {% endfor %}
  46. {% if DISPLAY_PAGES_ON_MENU %}
  47. {% for page in pages %}
  48. {% if page.title == "Home" %}
  49. <!--TODO: Change this to the offset to the root instead of the absolute root. -->
  50. <li>
  51. <a href="/">
  52. <img src="/logo.svg" alt="{{SITENAME}} Logo" class="logo">
  53. </a>
  54. </li>
  55. {% else %}
  56. <li{% if page == pagePrime %} class="active"{% endif %}><a href="{{ SiteProtoDomainTLD }}/{{ page.url }}">{{ page.title }}</a></li>
  57. {% endif %}
  58. {% endfor %}
  59. {% else %}
  60. {% if DISPLAY_CATEGORIES_ON_MENU %}
  61. {% for cat, null in categories %}
  62. <li{% if cat == category %} class="active"{% endif %}><a href="{{ SiteProtoDomainTLD }}/{{ cat.url }}">{{ cat }}</a></li>
  63. {% endfor %}
  64. {% endif %}
  65. {% endif %}
  66. </ul>
  67. <ul>
  68. <li><a href="#sitemap">Sitemap</a></li>
  69. </ul>
  70. </nav>
  71. </header>
  72. {% block content %}
  73. {% endblock %}
  74. {% block widgets %}
  75. <section title="Widgets and Sitemap" class="widgets">
  76. <!--NOTE: Some templates put a block searchform here.-->
  77. <a id="sitemap"></a>
  78. <div class="widget">
  79. <h1>Pages</h1>
  80. <ul>
  81. {% for page in pages %}
  82. <li><a href="{{ SiteProtoDomainTLD }}/{{ page.url }}">{{ page.title }}</a></li>
  83. {% endfor %}
  84. </ul>
  85. </div>
  86. {% block categories %}
  87. {% if categories %}
  88. <div class="widget">
  89. <h1>Category</h1>
  90. <ul>
  91. {% for category, article in categories%}
  92. <li><a href="{{ SiteProtoDomainTLD }}/{{ category.url }}" >{{ category.name }} </a></li>
  93. {% endfor %}
  94. </ul>
  95. </div>
  96. {% endif %}
  97. {% endblock %}
  98. {% block tagcloud %}
  99. {% if tags %}
  100. <div class="widget">
  101. <h1>Tags</h1>
  102. <div class="tags-max-width">
  103. {% for tag, articles in tags %}
  104. <span><a href="{{ SiteProtoDomainTLD }}/{{ tag.url }}">{{ tag.name }}</a></span>
  105. {% endfor %}
  106. </div>
  107. </div>
  108. {% endif %}
  109. {% endblock %}
  110. {% block links %}
  111. {% if LINKS %}
  112. <div class="widget">
  113. <h1>Links</h1>
  114. <ul>
  115. {% for name, link in LINKS %}
  116. <li><a href="{{ link }}">{{ name }}</a></li>
  117. {% endfor %}
  118. {% for name, link in SOCIAL %}
  119. <li><a href="{{ link }}">{{ name }}</a></li>
  120. {% endfor %}
  121. </ul>
  122. </div>
  123. {% endif %}
  124. {% endblock %}
  125. </section>
  126. {% endblock widgets %}
  127. <!--NOTE: Some templates put a block footer here.-->
  128. </body>
  129. </html>