chiark / gitweb /
theme: prefix also theme-related config with M_ to avoid confusion.
authorVladimír Vondruš <mosra@centrum.cz>
Mon, 6 Nov 2017 16:53:15 +0000 (17:53 +0100)
committerVladimír Vondruš <mosra@centrum.cz>
Mon, 6 Nov 2017 17:10:41 +0000 (18:10 +0100)
Sorry. A fully breaking change for the Pelican theme.

doc/pelican/theme.rst
pelican-theme/templates/article.html
pelican-theme/templates/author.html
pelican-theme/templates/base.html
pelican-theme/templates/base_blog.html
pelican-theme/templates/category.html
pelican-theme/templates/tag.html
site/pelicanconf.py

index 23a11e4ad193a5407f071e65f601d0d6519291ed..e23acce865be3bdcb43f08412d59b43267f38e83 100644 (file)
@@ -57,18 +57,18 @@ The most minimal configuration to use the theme is the following. Basically you
 need to tell Pelican where the theme resides (it's in the ``pelican-theme/``
 subdir of your m.css submodule), then you tell it to put the static contents of
 the theme into a ``static/`` directory in the root of your webserver; the
-``CSS_FILES`` variable is a list of CSS files that the theme needs. You can put
-there any files you need, but there need to be at least the files mentioned on
-the `CSS themes <{filename}/css/themes.rst>`_ page. Lastly, the theme uses some
-Jinja2 filters from the `m.htmlsanity <{filename}/plugins/htmlsanity.rst>`_
+:py:`M_CSS_FILES` variable is a list of CSS files that the theme needs. You can
+put there any files you need, but there need to be at least the files mentioned
+on the `CSS themes <{filename}/css/themes.rst>`_ page. Lastly, the theme uses
+some Jinja2 filters from the `m.htmlsanity <{filename}/plugins/htmlsanity.rst>`_
 plugin, so that plugin needs to be loaded as well.
 
 .. code:: py
 
     THEME = 'm.css/pelican-theme'
     THEME_STATIC_DIR = 'static'
-    CSS_FILES = ['https://fonts.googleapis.com/css?family=Source+Code+Pro:400,400i,600,600i%7CSource+Sans+Pro:400,400i,600&amp;subset=latin-ext',
-                 '/static/m-dark.css']
+    M_CSS_FILES = ['https://fonts.googleapis.com/css?family=Source+Code+Pro:400,400i,600,600i%7CSource+Sans+Pro:400,400i,600&amp;subset=latin-ext',
+                   '/static/m-dark.css']
     DIRECT_TEMPLATES = ['index']
 
     PLUGIN_PATHS += ['m.css/pelican-plugins']
@@ -76,11 +76,17 @@ plugin, so that plugin needs to be loaded as well.
 
 Here you can take advantage of the ``pelicanconf.py`` and ``publishconf.py``
 distinction --- use ``m-dark.css`` for local development and override the
-:py:`CSS_FILES` to use the smaller, faster and more compatible ``m-dark.compiled.css``
+:py:`M_CSS_FILES` to use the smaller, faster and more compatible ``m-dark.compiled.css``
 for publishing.
 
 .. note-info::
 
+    To reduce confusion, new configuration variables specific to m.css theme
+    and plugins are prefixed with ``M_``. Configuration variables without
+    prefix are builtin Pelican options.
+
+.. note-warning::
+
     The above configuration should be enough to produce a (mostly empty)
     version of your website using the theme without any errors during
     processing. If that's not the case, please :gh:`report a bug <mosra/m.css/issues/new>`.
@@ -93,37 +99,37 @@ Value of :py:`SITENAME` is used in the :html:`<title>` tag, separated with a
 ``|`` character from page title. If page title is the same as :py:`SITENAME`
 (for example on the index page), only the page title is shown. The static part
 of the website with pages is treated differently from the "blog" part with
-articles and there are two additional configuration options :py:`BLOGURL` and
-:py:`BLOGNAME` that control how various parts of the theme link to the blog and
-how blog pages are named in the :html:`<title>` element. The :py:`BLOGURL` can
-be either absolute or relative to :py:`SITEURL`.
+articles and there are two additional configuration options :py:`M_BLOG_URL` and
+:py:`M_BLOG_NAME` that control how various parts of the theme link to the blog
+and how blog pages are named in the :html:`<title>` element. The :py:`M_BLOG_URL`
+can be either absolute or relative to :py:`SITEURL`.
 
 .. code:: py
 
     SITENAME = 'Your Brand'
     SITEURL = ''
 
-    BLOGNAME = 'Your Brand Blog'
-    BLOGURL = 'blog/'
+    M_BLOG_NAME = 'Your Brand Blog'
+    M_BLOG_URL = 'blog/'
 
 Theme color :html:`<meta>` tag used by `CSS themes`_ can be specified with
-the :py:`THEME_COLOR` variable. If not set, no theme color :html:`<meta>` tag
+the :py:`M_THEME_COLOR` variable. If not set, no theme color :html:`<meta>` tag
 is present. Example configuration for the builtin dark theme:
 
 .. code:: py
 
-    THEME_COLOR = '#22272e'
+    M_THEME_COLOR = '#22272e'
 
 `Top navbar`_
 -------------
 
-:py:`SITE_LOGO` is an image file that will be used as a brand logo on left side
-of the navbar, :py:`SITE_LOGO_TEXT` is brand logo text. Specifying just one of
-these does the expected thing. The brand logo/text is a link that leads to
-:py:`SITTEURL`.
+:py:`M_SITE_LOGO` is an image file that will be used as a brand logo on left
+side of the navbar, :py:`M_SITE_LOGO_TEXT` is brand logo text. Specifying just
+one of these does the expected thing. The brand logo/text is a link that leads
+to :py:`SITTEURL`.
 
-:py:`LINKS_NAVBAR1` and :py:`LINKS_NAVBAR2` variables contain links to put in
-the top navbar. On narrow screens, the navbar is divided into two columns,
+:py:`M_LINKS_NAVBAR1` and :py:`M_LINKS_NAVBAR2` variables contain links to put
+in the top navbar. On narrow screens, the navbar is divided into two columns,
 links from the first variable are in the left column while links from the
 second variable are in the right column. Omit the second variable if you want
 the links to be in a single column.
@@ -144,25 +150,25 @@ documentation:
 
 .. code:: py
 
-    SITE_LOGO_TEXT = 'Your Brand'
+    M_SITE_LOGO_TEXT = 'Your Brand'
 
-    LINKS_NAVBAR1 = [('Features', 'features/', 'features', []),
-                     ('Showcase', 'showcase/', 'showcase', []),
-                     ('Download', 'download/', 'download', [])]
+    M_LINKS_NAVBAR1 = [('Features', 'features/', 'features', []),
+                       ('Showcase', 'showcase/', 'showcase', []),
+                       ('Download', 'download/', 'download', [])]
 
-    LINKS_NAVBAR2 = [('Blog', 'blog/', '[blog]', [
-                        ('News', 'blog/news/', ''),
-                        ('Archive', 'blog/archive/', '')]),
-                     ('Contact', 'contact/', 'contact', [])]
+    M_LINKS_NAVBAR2 = [('Blog', 'blog/', '[blog]', [
+                            ('News', 'blog/news/', ''),
+                            ('Archive', 'blog/archive/', '')]),
+                       ('Contact', 'contact/', 'contact', [])]
 
 `Footer navigation`_
 --------------------
 
-Similarly to the top navbar, :py:`LINKS_FOOTER1`, :py:`LINKS_FOOTER2`,
-:py:`LINKS_FOOTER3` and :py:`LINKS_FOOTER4` variables contain links to put in
-the footer navigation. The links are arranged in four columns, which get
-reduced to just two columns on small screens. Omitting :py:`LINKS_FOOTER4` will
-fill the last column with a *Blog* entry, linking to the Archives page and
+Similarly to the top navbar, :py:`M_LINKS_FOOTER1`, :py:`M_LINKS_FOOTER2`,
+:py:`M_LINKS_FOOTER3` and :py:`M_LINKS_FOOTER4` variables contain links to put
+in the footer navigation. The links are arranged in four columns, which get
+reduced to just two columns on small screens. Omitting :py:`M_LINKS_FOOTER4`
+will fill the last column with a *Blog* entry, linking to the Archives page and
 listing all blog categories; omitting any of the remaining variables will make
 given column empty.
 
@@ -171,7 +177,7 @@ is used for column header, if link URL of the first item is empty, given column
 header is just a plain :html:`<h3>` without a link. The URLs are processed in
 the same way as in the `top navbar`_.
 
-Footer fine print can be specified via :py:`FINE_PRINT`. Contents of the
+Footer fine print can be specified via :py:`M_FINE_PRINT`. Contents of the
 variable are processed as :abbr:`reST <reStructuredText>`, so you can use all
 the formatting and linking capabilities in there.
 
@@ -181,19 +187,19 @@ documentation, populating the last column implicitly:
 
 .. code:: py
 
-    LINKS_FOOTER1 = [('Your Brand', '/'),
-                     ('Features', 'features/'),
-                     ('Showcase', 'showcase/')]
+    M_LINKS_FOOTER1 = [('Your Brand', '/'),
+                       ('Features', 'features/'),
+                       ('Showcase', 'showcase/')]
 
-    LINKS_FOOTER2 = [('Download', 'download/'),
-                     ('Packages', 'download/packages/'),
-                     ('Source', 'download/source/')]
+    M_LINKS_FOOTER2 = [('Download', 'download/'),
+                       ('Packages', 'download/packages/'),
+                       ('Source', 'download/source/')]
 
-    LINKS_FOOTER3 = [('Contact', ''),
-                     ('E-mail', 'mailto:you@your.brand'),
-                     ('GitHub', 'https://github.com/your-brand')]
+    M_LINKS_FOOTER3 = [('Contact', ''),
+                       ('E-mail', 'mailto:you@your.brand'),
+                       ('GitHub', 'https://github.com/your-brand')]
 
-    FINE_PRINT = """
+    M_FINE_PRINT = """
     Your Brand. Copyright © `You <mailto:you@your.brand>`_, 2017. All rights
     reserved.
     """
index 9802f7a49666bbb963b86c81905d89511fe27a74..563f56a737b4bda550934f08010712c33fb25e81 100644 (file)
@@ -1,6 +1,6 @@
 {% extends "base_blog.html" %}
 
-{% block title %}{{ article.title }} | {{ BLOGNAME }}{% endblock %}
+{% block title %}{{ article.title }} | {{ M_BLOG_NAME }}{% endblock %}
 
 {% block head %}
   {{- super() -}}
index 9ed264998dedd76464f0f7139041b60a5b6aa2a9..45bb872e58a76625a88ec54a0d525ee6ceda2ad8 100644 (file)
@@ -1,9 +1,9 @@
 {% extends "base_blog_section.html" %}
 
-{% block title %}Posts by {{ author }} | {{ BLOGNAME }}{% endblock %}
+{% block title %}Posts by {{ author }} | {{ M_BLOG_NAME }}{% endblock %}
 
 {% block content_title %}
       <div class="m-info m-note">
-        Showing only posts by <em>{{ author }}</em>. <a href="{{ BLOGURL|format_siteurl }}">Show all posts.</a>
+        Showing only posts by <em>{{ author }}</em>. <a href="{{ M_BLOG_URL|format_siteurl }}">Show all posts.</a>
       </div>
 {% endblock %}
index 64e517fe6a37da2f641b56ae76ac0631822a27b6..3c8fcb31911a68a612a2b209393d3071a34826ec 100644 (file)
@@ -4,12 +4,12 @@
   {% block head %}
   <meta charset="UTF-8" />
   <title>{% block title %}{{ SITENAME }}{% endblock title %}</title>
-  {% for href in CSS_FILES %}
+  {% for href in M_CSS_FILES %}
   <link rel="stylesheet" href="{{ href|format_siteurl }}" />
   {% endfor %}
   <meta name="viewport" content="width=device-width, initial-scale=1.0" />
-  {% if THEME_COLOR %}
-  <meta name="theme-color" content="{{ THEME_COLOR }}" />
+  {% if M_THEME_COLOR %}
+  <meta name="theme-color" content="{{ M_THEME_COLOR }}" />
   {% endif %}
   {% if FEED_ALL_ATOM_URL %}
   <link href="{{ FEED_ALL_ATOM_URL|format_siteurl }}" type="application/atom+xml" rel="alternate" title="{{ SITENAME }}" />
   <div class="m-container">
     <div class="m-row">
       <a href="{{ SITEURL }}/" id="m-navbar-brand" class="m-col-t-9 m-col-m-none m-left-m{% if page and page.landing and page.cover and page.navbar_brand_hidden %} m-navbar-brand-hidden{% endif %}">
-        {%- if SITE_LOGO %}<img src="{{ SITE_LOGO }}" />{% endif -%}
-        {{- SITE_LOGO_TEXT -}}
+        {%- if M_SITE_LOGO %}<img src="{{ M_SITE_LOGO }}" />{% endif -%}
+        {{- M_SITE_LOGO_TEXT -}}
       </a>
       <a id="m-navbar-show" href="#navigation" title="Show navigation" class="m-col-t-3 m-hide-m m-text-right">&#9776;</a>
       <a id="m-navbar-hide" href="#" title="Hide navigation" class="m-col-t-3 m-hide-m m-text-right">&#9776;</a>
       <div id="m-navbar-collapse" class="m-col-t-12 m-show-m m-col-m-none m-right-m">
         <div class="m-row">
           <ol class="m-col-t-6 m-col-m-none">
-            {% for title, link, slug, sub in LINKS_NAVBAR1 %}
+            {% for title, link, slug, sub in M_LINKS_NAVBAR1 %}
             <li>
               <a href="{{ link|format_siteurl }}"{% if (page and page.highlight == slug) or slug == page_slug %} id="m-navbar-current"{% endif %}>{{ title }}</a>
               {% if sub %}
@@ -46,7 +46,7 @@
             {% endfor %}
           </ol>
           <ol class="m-col-t-6 m-col-m-none">
-            {% for title, link, slug, sub in LINKS_NAVBAR2 %}
+            {% for title, link, slug, sub in M_LINKS_NAVBAR2 %}
             <li>
               <a href="{{ link|format_siteurl }}"{% if (page and page.highlight == slug) or slug == page_slug %} id="m-navbar-current"{% endif %}>{{ title }}</a>
               {% if sub %}
   <div class="m-container">
     <div class="m-row">
       <div class="m-col-s-3 m-col-t-6">
-        {% if LINKS_FOOTER1 %}
+        {% if M_LINKS_FOOTER1 %}
         <h3>
-          {%- if LINKS_FOOTER1[0][1] %}<a href="{{ LINKS_FOOTER1[0][1]|format_siteurl }}">{% endif %}
-          {{- LINKS_FOOTER1[0][0] -}}
-          {% if LINKS_FOOTER1[0][1] -%}</a>{% endif -%}
+          {%- if M_LINKS_FOOTER1[0][1] %}<a href="{{ M_LINKS_FOOTER1[0][1]|format_siteurl }}">{% endif %}
+          {{- M_LINKS_FOOTER1[0][0] -}}
+          {% if M_LINKS_FOOTER1[0][1] -%}</a>{% endif -%}
         </h3>
         <ul>
-          {% for title, link in LINKS_FOOTER1 %}{% if loop.index0 != 0 %}
+          {% for title, link in M_LINKS_FOOTER1 %}{% if loop.index0 != 0 %}
           <li><a href="{{ link|format_siteurl }}">{{ title }}</a></li>
           {% endif %}{% endfor %}
         </ul>
         {% endif %}
       </div>
       <div class="m-col-s-3 m-col-t-6">
-        {% if LINKS_FOOTER2 %}
+        {% if M_LINKS_FOOTER2 %}
         <h3>
-          {%- if LINKS_FOOTER2[0][1] %}<a href="{{ LINKS_FOOTER2[0][1]|format_siteurl }}">{% endif %}
-          {{- LINKS_FOOTER2[0][0] -}}
-          {% if LINKS_FOOTER2[0][1] %}</a>{% endif -%}
+          {%- if M_LINKS_FOOTER2[0][1] %}<a href="{{ M_LINKS_FOOTER2[0][1]|format_siteurl }}">{% endif %}
+          {{- M_LINKS_FOOTER2[0][0] -}}
+          {% if M_LINKS_FOOTER2[0][1] %}</a>{% endif -%}
         </h3>
         <ul>
-          {% for title, link in LINKS_FOOTER2 %}{% if loop.index0 != 0 %}
+          {% for title, link in M_LINKS_FOOTER2 %}{% if loop.index0 != 0 %}
           <li><a href="{{ link|format_siteurl }}">{{ title }}</a></li>
           {% endif %}{% endfor %}
         </ul>
       </div>
       <div class="m-clearfix-t"></div>
       <div class="m-col-s-3 m-col-t-6">
-        {% if LINKS_FOOTER3 %}
+        {% if M_LINKS_FOOTER3 %}
         <h3>
-          {%- if LINKS_FOOTER3[0][1] %}<a href="{{ LINKS_FOOTER3[0][1]|format_siteurl }}">{% endif %}
-          {{- LINKS_FOOTER3[0][0] -}}
-          {% if LINKS_FOOTER3[0][1] %}</a>{% endif -%}
+          {%- if M_LINKS_FOOTER3[0][1] %}<a href="{{ M_LINKS_FOOTER3[0][1]|format_siteurl }}">{% endif %}
+          {{- M_LINKS_FOOTER3[0][0] -}}
+          {% if M_LINKS_FOOTER3[0][1] %}</a>{% endif -%}
         </h3>
         <ul>
-          {% for title, link in LINKS_FOOTER3 %}{% if loop.index0 != 0 %}
+          {% for title, link in M_LINKS_FOOTER3 %}{% if loop.index0 != 0 %}
           <li><a href="{{ link|format_siteurl }}">{{ title }}</a></li>
           {% endif %}{% endfor %}
         </ul>
         {% endif %}
       </div>
       <div class="m-col-s-3 m-col-t-6">
-        {% if LINKS_FOOTER4 %}
+        {% if M_LINKS_FOOTER4 %}
         <h3>
-          {%- if LINKS_FOOTER4[0][1] %}<a href="{{ LINKS_FOOTER4[0][1]|format_siteurl }}">{% endif %}
-          {{- LINKS_FOOTER4[0][0] -}}
-          {% if LINKS_FOOTER4[0][1] %}</a>{% endif -%}
+          {%- if M_LINKS_FOOTER4[0][1] %}<a href="{{ M_LINKS_FOOTER4[0][1]|format_siteurl }}">{% endif %}
+          {{- M_LINKS_FOOTER4[0][0] -}}
+          {% if M_LINKS_FOOTER4[0][1] %}</a>{% endif -%}
         </h3>
         <ul>
-          {% for title, link in LINKS_FOOTER4 %}{% if loop.index0 != 0 %}
+          {% for title, link in M_LINKS_FOOTER4 %}{% if loop.index0 != 0 %}
           <li><a href="{{ link|format_siteurl }}">{{ title }}</a></li>
           {% endif %}{% endfor %}
         </ul>
         {% else %}
-        <h3><a href="{{ BLOGURL|format_siteurl }}">Blog</a></h3>
+        <h3><a href="{{ M_BLOG_URL|format_siteurl }}">Blog</a></h3>
         <ul>
           {% for cat, null in categories %}
           <li><a href="{{ cat.url|format_siteurl }}">{{ cat }}</a></li>
     </div>
     <div class="m-row">
       <div class="m-col-l-10 m-push-l-1">
-        {% if FINE_PRINT %}
-        {{ FINE_PRINT|render_rst|indent(10) }}
+        {% if M_FINE_PRINT %}
+        {{ M_FINE_PRINT|render_rst|indent(10) }}
         {% endif %}
       </div>
     </div>
index 22cc34748c7e2b3f1b345b8ce72bc0a8bfb8acca..b8a203e1e09fbb4ea2f4df8bf15fbf762d986425 100644 (file)
@@ -1,7 +1,7 @@
 {% set page_slug = '[blog]' %}
 {% extends 'base.html' %}
 
-{% block title %}{{ BLOGNAME }}{% endblock %}
+{% block title %}{{ M_BLOG_NAME }}{% endblock %}
 
 {% block main %}
 {% if article and article.cover %}
index 22e71c51a08171c37925c6177a6b98398db4a153..8feae772f331927a11eef532939ac96c7b3c0a94 100644 (file)
@@ -1,9 +1,9 @@
 {% extends "base_blog_section.html" %}
 
-{% block title %}{{ category }} | {{ BLOGNAME }}{% endblock %}
+{% block title %}{{ category }} | {{ M_BLOG_NAME }}{% endblock %}
 
 {% block content_title %}
       <div class="m-info m-note">
-        Showing only posts in <em>{{ category }}</em>. <a href="{{ BLOGURL|format_siteurl }}">Show all posts.</a>
+        Showing only posts in <em>{{ category }}</em>. <a href="{{ M_BLOG_URL|format_siteurl }}">Show all posts.</a>
       </div>
 {% endblock %}
index 9a81fad171d1625a34e02cad8c9530ae437cd3c2..b7cec94fa88285511f781c9a9aa0b00c8ae3a609 100644 (file)
@@ -1,9 +1,9 @@
 {% extends "base_blog_section.html" %}
 
-{% block title %}Posts tagged {{ tag }} | {{ BLOGNAME }}{% endblock %}
+{% block title %}Posts tagged {{ tag }} | {{ M_BLOG_NAME }}{% endblock %}
 
 {% block content_title %}
       <div class="m-info m-note">
-        Showing only posts tagged <em>{{ tag }}</em>. <a href="{{ BLOGURL|format_siteurl }}">Show all posts.</a>
+        Showing only posts tagged <em>{{ tag }}</em>. <a href="{{ M_BLOG_URL|format_siteurl }}">Show all posts.</a>
       </div>
 {% endblock %}
index 327487382c0f1650aa7dc76c2f70bdcfe0c90fe6..c4c37bc0dd310541a078a807edc386ec4cc82293 100644 (file)
 
 AUTHOR = 'Vladimír Vondruš'
 
-SITE_LOGO_TEXT = 'm.css'
+M_SITE_LOGO_TEXT = 'm.css'
 
 SITENAME = 'm.css'
 SITEURL = ''
 
-BLOGNAME = 'm.css example articles'
-BLOGURL = 'examples/'
+M_BLOG_NAME = 'm.css example articles'
+M_BLOG_URL = 'examples/'
 
 STATIC_URL = '{path}'
 
@@ -51,51 +51,51 @@ TRANSLATION_FEED_ATOM = None
 AUTHOR_FEED_ATOM = None
 AUTHOR_FEED_RSS = None
 
-LINKS_NAVBAR1 = [('Why?', 'why/', 'why', []),
-                 ('CSS', 'css/', 'css', [
-                    ('Grid system', 'css/grid/', 'css/grid'),
-                    ('Typography', 'css/typography/', 'css/typography'),
-                    ('Components', 'css/components/', 'css/components'),
-                    ('Page layout', 'css/page-layout/', 'css/page-layout'),
-                    ('Themes', 'css/themes/', 'css/themes')]),
-                 ('Pelican', 'pelican/', 'pelican', [
-                    ('Writing content', 'pelican/writing-content/', 'pelican/writing-content'),
-                    ('Theme', 'pelican/theme/', 'pelican/theme')])]
-
-LINKS_NAVBAR2 = [('Pelican plugins', 'plugins/', 'plugins', [
-                    ('HTML sanity', 'plugins/htmlsanity/', 'plugins/htmlsanity'),
-                    ('Components', 'plugins/components/', 'plugins/components'),
-                    ('Images', 'plugins/images/', 'plugins/images'),
-                    ('Math and code', 'plugins/math-and-code/', 'plugins/math-and-code'),
-                    ('Links', 'plugins/links/', 'plugins/links')]),
-                 ('GitHub', 'https://github.com/mosra/m.css', '', [])]
-
-LINKS_FOOTER1 = [('m.css', '/'),
-                 ('Why?', 'why/'),
-                 ('GitHub', 'https://github.com/mosra/m.css'),
-                 ('Gitter', 'https://gitter.im/mosra/m.css'),
-                 ('E-mail', 'mailto:mosra@centrum.cz'),
-                 ('Twitter', 'https://twitter.com/czmosra')]
-
-LINKS_FOOTER2 = [('CSS', 'css/'),
-                 ('Grid system', 'css/grid/'),
-                 ('Typography', 'css/typography/'),
-                 ('Components', 'css/components/'),
-                 ('Page layout', 'css/page-layout/'),
-                 ('Themes', 'css/themes/')]
-
-LINKS_FOOTER3 = [('Pelican', 'pelican/'),
-                 ('Writing content', 'pelican/writing-content/'),
-                 ('Theme', 'pelican/theme/')]
-
-LINKS_FOOTER4 = [('Pelican plugins', 'plugins/'),
-                 ('HTML sanity', 'plugins/htmlsanity/'),
-                 ('Components', 'plugins/components/'),
-                 ('Images', 'plugins/images/'),
-                 ('Math and code', 'plugins/math-and-code/'),
-                 ('Links', 'plugins/links/')]
-
-FINE_PRINT = """
+M_LINKS_NAVBAR1 = [('Why?', 'why/', 'why', []),
+                   ('CSS', 'css/', 'css', [
+                        ('Grid system', 'css/grid/', 'css/grid'),
+                        ('Typography', 'css/typography/', 'css/typography'),
+                        ('Components', 'css/components/', 'css/components'),
+                        ('Page layout', 'css/page-layout/', 'css/page-layout'),
+                        ('Themes', 'css/themes/', 'css/themes')]),
+                   ('Pelican', 'pelican/', 'pelican', [
+                        ('Writing content', 'pelican/writing-content/', 'pelican/writing-content'),
+                        ('Theme', 'pelican/theme/', 'pelican/theme')])]
+
+M_LINKS_NAVBAR2 = [('Pelican plugins', 'plugins/', 'plugins', [
+                        ('HTML sanity', 'plugins/htmlsanity/', 'plugins/htmlsanity'),
+                        ('Components', 'plugins/components/', 'plugins/components'),
+                        ('Images', 'plugins/images/', 'plugins/images'),
+                        ('Math and code', 'plugins/math-and-code/', 'plugins/math-and-code'),
+                        ('Links', 'plugins/links/', 'plugins/links')]),
+                   ('GitHub', 'https://github.com/mosra/m.css', '', [])]
+
+M_LINKS_FOOTER1 = [('m.css', '/'),
+                   ('Why?', 'why/'),
+                   ('GitHub', 'https://github.com/mosra/m.css'),
+                   ('Gitter', 'https://gitter.im/mosra/m.css'),
+                   ('E-mail', 'mailto:mosra@centrum.cz'),
+                   ('Twitter', 'https://twitter.com/czmosra')]
+
+M_LINKS_FOOTER2 = [('CSS', 'css/'),
+                   ('Grid system', 'css/grid/'),
+                   ('Typography', 'css/typography/'),
+                   ('Components', 'css/components/'),
+                   ('Page layout', 'css/page-layout/'),
+                   ('Themes', 'css/themes/')]
+
+M_LINKS_FOOTER3 = [('Pelican', 'pelican/'),
+                   ('Writing content', 'pelican/writing-content/'),
+                   ('Theme', 'pelican/theme/')]
+
+M_LINKS_FOOTER4 = [('Pelican plugins', 'plugins/'),
+                   ('HTML sanity', 'plugins/htmlsanity/'),
+                   ('Components', 'plugins/components/'),
+                   ('Images', 'plugins/images/'),
+                   ('Math and code', 'plugins/math-and-code/'),
+                   ('Links', 'plugins/links/')]
+
+M_FINE_PRINT = """
 m.css. Copyright © Vladimír Vondruš 2017. Site powered by `Pelican <https://getpelican.com>`_
 and m.css (yes, I am eating my own dog food). Both the code and site content is
 `available on GitHub under MIT <https://github.com/mosra/m.css>`_. Contact the
@@ -121,13 +121,13 @@ PLUGINS = ['m.abbr',
 
 THEME = '../pelican-theme'
 THEME_STATIC_DIR = 'static'
-THEME_COLOR = '#22272e'
-CSS_FILES = ['https://fonts.googleapis.com/css?family=Source+Code+Pro:400,400i,600%7CSource+Sans+Pro:400,400i,600,600i&amp;subset=latin-ext',
-             '/static/m-dark.css',
-             #'/static/m-debug.css'
-             ]
-#CSS_FILES = ['https://fonts.googleapis.com/css?family=Libre+Baskerville:400,400i,700,700i%7CSource+Code+Pro:400,400i,600',
-             #'/static/m-light.css']
+M_THEME_COLOR = '#22272e'
+M_CSS_FILES = ['https://fonts.googleapis.com/css?family=Source+Code+Pro:400,400i,600%7CSource+Sans+Pro:400,400i,600,600i&amp;subset=latin-ext',
+               '/static/m-dark.css',
+              #'/static/m-debug.css'
+              ]
+#M_CSS_FILES = ['https://fonts.googleapis.com/css?family=Libre+Baskerville:400,400i,700,700i%7CSource+Code+Pro:400,400i,600',
+               #'/static/m-light.css']
 
 FORMATTED_FIELDS = ['summary', 'landing', 'header', 'footer']