Commit e92e4868 authored by Kaushal Modi's avatar Kaushal Modi

Do .Get on favicon resources only if enabled

Fixes #5.
parent 681d1795
......@@ -24,6 +24,14 @@ This theme can be tweaked using the following =[Params]= variables in
# Go date formats: https://golang.org/pkg/time/#pkg-constants
dateform = "Mon Jan 2, 2006"
# Set favicons to true only if the following files are present in the project assets/ dir:
# - safari-pinned-tab.svg
# - manifest.json
# - favicon-16x16.png
# - favicon-32x32.png
# - apple-touch-icon.png
favicons = false
themecolorbase = "red" # Valid values: "red", "orange", "yellow", "green", "cyan", "blue", "magenta", "brown"
#+end_example
** Isso comment support
......
......@@ -8,6 +8,14 @@ theme = ["hugo-debugprint", "hugo-atom-feed", "hugo-jf2", "hugo-search-fuse-js",
themecolorbase = "red" # Valid values: "red", "orange", "yellow", "green", "cyan", "blue", "magenta", "brown"
# Set favicons to true only if the following files are present in the project assets/ dir:
# - safari-pinned-tab.svg
# - manifest.json
# - favicon-16x16.png
# - favicon-32x32.png
# - apple-touch-icon.png
favicons = false
# These inline CSS files have to live in layouts/partials/.
custom_inline_css = [ # Pygments Trac theme
# "css/trac_pygments.css" # Needs pygmentsUseClasses to be true
......
......@@ -126,15 +126,17 @@
{{ partialCached "mathjax.html" $ }}
{{ end }}
<!-- Icons -->
<!-- Favicons -->
<!-- Generated using https://realfavicongenerator.net/ -->
<link rel="apple-touch-icon" sizes="180x180" href="{{ (resources.Get "apple-touch-icon.png" | fingerprint).RelPermalink }}">
<link rel="icon" type="image/png" sizes="32x32" href="{{ (resources.Get "favicon-32x32.png" | fingerprint).RelPermalink }}">
<link rel="icon" type="image/png" sizes="16x16" href="{{ (resources.Get "favicon-16x16.png" | fingerprint).RelPermalink }}">
<link rel="manifest" href="{{ (resources.Get "manifest.json" | fingerprint).RelPermalink }}">
<link rel="mask-icon" href="{{ (resources.Get "safari-pinned-tab.svg" | fingerprint).RelPermalink }}" color="#5bbad5">
<meta name="msapplication-TileColor" content="#ffc40d" />
<meta name="theme-color" content="#ffffff" />
{{ if (.Param "favicons") }}
<link rel="apple-touch-icon" sizes="180x180" href="{{ (resources.Get "apple-touch-icon.png" | fingerprint).RelPermalink }}">
<link rel="icon" type="image/png" sizes="32x32" href="{{ (resources.Get "favicon-32x32.png" | fingerprint).RelPermalink }}">
<link rel="icon" type="image/png" sizes="16x16" href="{{ (resources.Get "favicon-16x16.png" | fingerprint).RelPermalink }}">
<link rel="manifest" href="{{ (resources.Get "manifest.json" | fingerprint).RelPermalink }}">
<link rel="mask-icon" href="{{ (resources.Get "safari-pinned-tab.svg" | fingerprint).RelPermalink }}" color="#5bbad5">
<meta name="msapplication-TileColor" content="#ffc40d" />
<meta name="theme-color" content="#ffffff" />
{{ end }}
<!-- Webmention, Opengraph and Twitter -->
{{ partialCached "indieweb-head.html" . }}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment