diff --git a/docs/pelicanconf.py b/docs/pelicanconf.py index 2793366..3cfd5ca 100644 --- a/docs/pelicanconf.py +++ b/docs/pelicanconf.py @@ -45,6 +45,8 @@ USE_FOLDER_AS_CATEGORY = False MAIN_MENU = True HOME_HIDE_TAGS = True +GITHUB_CORNER_URL = "https://github.com/alexandrevicenzi/Flex" + SOCIAL = ( ("github", "https://github.com/alexandrevicenzi/Flex"), ("rss", "/blog/feeds/all.atom.xml"), diff --git a/templates/base.html b/templates/base.html index 474d887..907a2d3 100644 --- a/templates/base.html +++ b/templates/base.html @@ -12,9 +12,9 @@ {% if page in hidden_pages %} - + {% else %} - + {% endif %} {% if USE_GOOGLE_FONTS != False %} @@ -78,7 +78,7 @@ {% endif %} {% if PLUGINS and 'pelican.plugins.search' in PLUGINS %} - + {% endif %} @@ -89,38 +89,14 @@ {% endif %} - {% if FEED_ALL_ATOM %} - - {% endif %} + {% include "partial/icon.html" %} - {% if FEED_ALL_RSS %} - - {% endif %} + {% include "partial/color.html" %} - {% if FAVICON %} - - - {% endif %} + {% include "partial/feed.html" %} - {% if GOOGLE_ANALYTICS %} - {% include "partial/ga.html" %} - {% endif %} - - {% if GOOGLE_GLOBAL_SITE_TAG %} - {% include "partial/ggst.html" %} - {% endif %} - - {% if BROWSER_COLOR %} - - - - - - - - - - {% endif %} + {% include "partial/ga.html" %} + {% include "partial/ggst.html" %} {% if not PLUGINS or 'seo' not in PLUGINS %} {% if REL_CANONICAL %} @@ -155,103 +131,15 @@ }); {% endif %} - {% if GOOGLE_TAG_MANAGER %} - {% include "partial/gtm.html" %} - {% endif %} - {% if MICROSOFT_CLARITY %} - {% include "partial/clarity.html" %} - {% endif %} + + {% include "partial/gtm.html" %} + {% include "partial/clarity.html" %} - {% if GOOGLE_TAG_MANAGER %} - {% include "partial/gtm_noscript.html" %} - {% endif %} -
{% if GOOGLE_ADSENSE and GOOGLE_ADSENSE.ads.main_menu %} @@ -263,56 +151,21 @@ {% endif %} - {% if MAIN_MENU %} - - {% endif %} + {% include "partial/nav.html" %} {% block content %} {% endblock %} - + {% include "partial/footer.html" %}
- {% if GUAGES %} - {% include "partial/guages.html" %} - {% endif %} - - {% if ADD_THIS_ID %} - - {% endif %} - - {% if (PIWIK_URL and PIWIK_SITE_ID) or (MATOMO_URL and MATOMO_SITE_ID) %} - {% include "partial/matomo.html" %} - {% endif %} - {% include "partial/jsonld.html" %} - - {% if GITHUB_CORNER_URL %} - {% include 'partial/github.html' %} - {% endif %} + {% include "partial/guages.html" %} + {% include "partial/addthis.html" %} + {% include "partial/matomo.html" %} + {% include 'partial/github.html' %} + {% include 'partial/stork.html' %} {% block additional_js %}{% endblock %} - - {% include 'partial/stork_search.html' %} diff --git a/templates/partial/addthis.html b/templates/partial/addthis.html new file mode 100644 index 0000000..7d8bc97 --- /dev/null +++ b/templates/partial/addthis.html @@ -0,0 +1,3 @@ +{% if ADD_THIS_ID %} + +{% endif %} diff --git a/templates/partial/clarity.html b/templates/partial/clarity.html index fd7b935..59dbb90 100644 --- a/templates/partial/clarity.html +++ b/templates/partial/clarity.html @@ -1,7 +1,9 @@ +{% if MICROSOFT_CLARITY %} +{% endif %} diff --git a/templates/partial/color.html b/templates/partial/color.html new file mode 100644 index 0000000..e715c90 --- /dev/null +++ b/templates/partial/color.html @@ -0,0 +1,11 @@ +{% if BROWSER_COLOR %} + + + + + + + + + +{% endif %} diff --git a/templates/partial/feed.html b/templates/partial/feed.html new file mode 100644 index 0000000..28a836a --- /dev/null +++ b/templates/partial/feed.html @@ -0,0 +1,7 @@ +{% if FEED_ALL_ATOM %} + +{% endif %} + +{% if FEED_ALL_RSS %} + +{% endif %} diff --git a/templates/partial/footer.html b/templates/partial/footer.html new file mode 100644 index 0000000..6c559b3 --- /dev/null +++ b/templates/partial/footer.html @@ -0,0 +1,7 @@ + diff --git a/templates/partial/ga.html b/templates/partial/ga.html index 5ce3a5d..fcf5c70 100644 --- a/templates/partial/ga.html +++ b/templates/partial/ga.html @@ -1,4 +1,4 @@ - +{% if GOOGLE_ANALYTICS %} - +{% endif %} diff --git a/templates/partial/ggst.html b/templates/partial/ggst.html index bac7d3a..c306b04 100644 --- a/templates/partial/ggst.html +++ b/templates/partial/ggst.html @@ -1,4 +1,4 @@ - +{% if GOOGLE_GLOBAL_SITE_TAG %} - \ No newline at end of file +{% endif %} diff --git a/templates/partial/github.html b/templates/partial/github.html index 98c521d..f417383 100644 --- a/templates/partial/github.html +++ b/templates/partial/github.html @@ -1,4 +1,5 @@ - +{% if GITHUB_CORNER_URL %} + - +{% endif %} diff --git a/templates/partial/gtm.html b/templates/partial/gtm.html index 3c57902..8bc0135 100644 --- a/templates/partial/gtm.html +++ b/templates/partial/gtm.html @@ -1,4 +1,4 @@ - +{% if GOOGLE_TAG_MANAGER %} - +{% endif %} diff --git a/templates/partial/gtm_noscript.html b/templates/partial/gtm_noscript.html index 3e01e52..5cc4ec8 100644 --- a/templates/partial/gtm_noscript.html +++ b/templates/partial/gtm_noscript.html @@ -1,5 +1,5 @@ - +{% if GOOGLE_TAG_MANAGER %} - +{% endif %} diff --git a/templates/partial/guages.html b/templates/partial/guages.html index e7b0367..5b77010 100644 --- a/templates/partial/guages.html +++ b/templates/partial/guages.html @@ -1,4 +1,4 @@ - +{% if GUAGES %} - +{% endif %} + diff --git a/templates/partial/icon.html b/templates/partial/icon.html new file mode 100644 index 0000000..414d516 --- /dev/null +++ b/templates/partial/icon.html @@ -0,0 +1,4 @@ +{% if FAVICON %} + + +{% endif %} diff --git a/templates/partial/matomo.html b/templates/partial/matomo.html index 7fe966b..3613173 100644 --- a/templates/partial/matomo.html +++ b/templates/partial/matomo.html @@ -1,4 +1,4 @@ - +{% if (PIWIK_URL and PIWIK_SITE_ID) or (MATOMO_URL and MATOMO_SITE_ID) %} - +{% endif %} diff --git a/templates/partial/nav.html b/templates/partial/nav.html new file mode 100644 index 0000000..74031eb --- /dev/null +++ b/templates/partial/nav.html @@ -0,0 +1,17 @@ +{% if MAIN_MENU %} + +{% endif %} diff --git a/templates/partial/sidebar.html b/templates/partial/sidebar.html new file mode 100644 index 0000000..ccd4073 --- /dev/null +++ b/templates/partial/sidebar.html @@ -0,0 +1,92 @@ + diff --git a/templates/partial/stork.html b/templates/partial/stork.html new file mode 100644 index 0000000..2a1efd2 --- /dev/null +++ b/templates/partial/stork.html @@ -0,0 +1,13 @@ +{% if PLUGINS and 'pelican.plugins.search' in PLUGINS %} + {% if STORK_VERSION %} + + + {% else %} + + + {% endif %} +{% endif %} diff --git a/templates/partial/stork_search.html b/templates/partial/stork_search.html deleted file mode 100644 index c514940..0000000 --- a/templates/partial/stork_search.html +++ /dev/null @@ -1,12 +0,0 @@ -{% if PLUGINS and 'pelican.plugins.search' in PLUGINS %} -{% if STORK_VERSION %} - - - -{% endif %}