From 37f359ee2149abe147bba0a7dd4e1ff775dc2a56 Mon Sep 17 00:00:00 2001 From: Andreas Deininger Date: Sat, 15 Jan 2022 14:34:54 +0100 Subject: [PATCH 001/254] Completing German, English and Spanish translation (#728) --- i18n/de.yaml | 13 +++++++++++-- i18n/en.yaml | 3 +++ i18n/es.yaml | 3 +++ 3 files changed, 17 insertions(+), 2 deletions(-) diff --git a/i18n/de.yaml b/i18n/de.yaml index fcb53301..9a816e4a 100644 --- a/i18n/de.yaml +++ b/i18n/de.yaml @@ -6,8 +6,8 @@ - id: read_time translation: - one: "1 min" - other: "{{ .Count }} min" + one: "1 Minute" + other: "{{ .Count }} Minuten" - id: toc translation: "Inhaltsverzeichnis" @@ -15,5 +15,14 @@ - id: translations translation: "Übersetzungen" +- id: home + translation: "Home" + - id: edit_post translation: "Bearbeiten" + +- id: code_copy + translation: "Kopieren" + +- id: code_copied + translation: "Kopiert!" diff --git a/i18n/en.yaml b/i18n/en.yaml index 24d11f93..4758d365 100644 --- a/i18n/en.yaml +++ b/i18n/en.yaml @@ -18,6 +18,9 @@ - id: home translation: "Home" +- id: edit_post + translation: "Edit" + - id: code_copy translation: "copy" diff --git a/i18n/es.yaml b/i18n/es.yaml index 0d3d69ad..5e90ebbf 100644 --- a/i18n/es.yaml +++ b/i18n/es.yaml @@ -18,6 +18,9 @@ - id: home translation: "Inicio" +- id: edit_post + translation: "Editar" + - id: code_copy translation: "copiar" From b0ab8ea4959c07fe13c1667297e986e1d65aafe1 Mon Sep 17 00:00:00 2001 From: Thiago Perrotta Date: Fri, 21 Jan 2022 13:28:25 -0500 Subject: [PATCH 002/254] Add option to add word count to metadata (#740) Usage: ShowWordCount: true --- i18n/de.yaml | 5 +++++ i18n/en.yaml | 5 +++++ i18n/es.yaml | 7 ++++++- i18n/fr.yaml | 5 +++++ i18n/it.yaml | 5 +++++ i18n/nl.yaml | 5 +++++ i18n/pt.yaml | 5 +++++ layouts/partials/post_meta.html | 4 ++++ 8 files changed, 40 insertions(+), 1 deletion(-) diff --git a/i18n/de.yaml b/i18n/de.yaml index 9a816e4a..47254190 100644 --- a/i18n/de.yaml +++ b/i18n/de.yaml @@ -9,6 +9,11 @@ one: "1 Minute" other: "{{ .Count }} Minuten" +- id: words + translation: + one : "Wort" + other: "{{ .Count }} Wörter" + - id: toc translation: "Inhaltsverzeichnis" diff --git a/i18n/en.yaml b/i18n/en.yaml index 4758d365..3dc15790 100644 --- a/i18n/en.yaml +++ b/i18n/en.yaml @@ -9,6 +9,11 @@ one : "1 min" other: "{{ .Count }} min" +- id: words + translation: + one : "word" + other: "{{ .Count }} words" + - id: toc translation: "Table of Contents" diff --git a/i18n/es.yaml b/i18n/es.yaml index 5e90ebbf..163bfc41 100644 --- a/i18n/es.yaml +++ b/i18n/es.yaml @@ -9,6 +9,11 @@ one : "1 min" other: "{{ .Count }} min" +- id: words + translation: + one : "palabra" + other: "{{ .Count }} palabras" + - id: toc translation: "Tabla de Contenidos" @@ -25,4 +30,4 @@ translation: "copiar" - id: code_copied - translation: "¡copiado!" \ No newline at end of file + translation: "¡copiado!" diff --git a/i18n/fr.yaml b/i18n/fr.yaml index 2e652114..46ad398b 100644 --- a/i18n/fr.yaml +++ b/i18n/fr.yaml @@ -9,6 +9,11 @@ one : "1 min" other: "{{ .Count }} min" +- id: words + translation: + one : "mot" + other: "{{ .Count }} mots" + - id: toc translation: "Table des Matières" diff --git a/i18n/it.yaml b/i18n/it.yaml index 58de6060..ef41db4e 100644 --- a/i18n/it.yaml +++ b/i18n/it.yaml @@ -9,6 +9,11 @@ one: "1 minuto" other: "{{ .Count }} minuti" +- id: words + translation: + one : "parola" + other: "{{ .Count }} parole" + - id: toc translation: "Tabella dei Contenuti" diff --git a/i18n/nl.yaml b/i18n/nl.yaml index 63a99319..e9d06fa5 100644 --- a/i18n/nl.yaml +++ b/i18n/nl.yaml @@ -9,6 +9,11 @@ one: "1 min" other: "{{ .Count }} min" +- id: words + translation: + one : "woord" + other: "{{ .Count }} woorden" + - id: toc translation: "Inhoudsopgave" diff --git a/i18n/pt.yaml b/i18n/pt.yaml index b30e4297..f449de9c 100644 --- a/i18n/pt.yaml +++ b/i18n/pt.yaml @@ -9,6 +9,11 @@ one: "1 minuto" other: "{{ .Count }} minutos" +- id: words + translation: + one : "palavra" + other: "{{ .Count }} palavras" + - id: toc translation: "Conteúdo" diff --git a/layouts/partials/post_meta.html b/layouts/partials/post_meta.html index 9225f13a..f7134fbf 100644 --- a/layouts/partials/post_meta.html +++ b/layouts/partials/post_meta.html @@ -8,6 +8,10 @@ {{- $scratch.Add "meta" (slice (i18n "read_time" .ReadingTime | default (printf "%d min" .ReadingTime))) }} {{- end }} +{{- if (.Param "ShowWordCount") -}} +{{- $scratch.Add "meta" (slice (i18n "words" .WordCount | default (printf "%d words" .WordCount))) }} +{{- end }} + {{- with (partial "author.html" .) }} {{- $scratch.Add "meta" (slice .) }} {{- end }} From d52bced73599a6efaf66a8d843bda0380e378ed7 Mon Sep 17 00:00:00 2001 From: yuyin <38490578+yuyinws@users.noreply.github.com> Date: Sat, 22 Jan 2022 02:29:36 +0800 Subject: [PATCH 003/254] complete simplified/traditional Chinese (#756) --- i18n/zh-tw.yaml | 3 +++ i18n/zh.yaml | 3 +++ 2 files changed, 6 insertions(+) diff --git a/i18n/zh-tw.yaml b/i18n/zh-tw.yaml index f6dee2d7..c6b0e7fd 100644 --- a/i18n/zh-tw.yaml +++ b/i18n/zh-tw.yaml @@ -18,6 +18,9 @@ - id: home translation: "首頁" +- id: edit_post + translation: "編輯" + - id: code_copy translation: "複製" diff --git a/i18n/zh.yaml b/i18n/zh.yaml index 006528b6..7f15ab08 100644 --- a/i18n/zh.yaml +++ b/i18n/zh.yaml @@ -18,6 +18,9 @@ - id: home translation: "主页" +- id: edit_post + translation: "编辑" + - id: code_copy translation: "复制" From 530044033e8a9d87d5297b936e37cbfb2b5562e3 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 22 Jan 2022 00:25:35 +0530 Subject: [PATCH 004/254] Add `UseHugoToc` so that Hugo's default ToC can be used. Usage => UseHugoToc: true closes: #747 --- layouts/partials/toc.html | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/layouts/partials/toc.html b/layouts/partials/toc.html index 7a4c0198..d9b8b234 100644 --- a/layouts/partials/toc.html +++ b/layouts/partials/toc.html @@ -8,6 +8,9 @@
+ {{- if (.Param "UseHugoToc") }} + {{- .TableOfContents -}} + {{- else }} {{- $largest := 6 -}} {{- range $headers -}} {{- $headerLevel := index (findRE "[1-6]" . 1) 0 -}} @@ -87,6 +90,7 @@ {{- end -}} {{- end }} + {{- end }}
From c9f7c54ae67614e9af6f4212262411e31aca0f70 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 5 Feb 2022 17:50:49 +0530 Subject: [PATCH 005/254] Rename fuse.js -> fuse.basic.min.js - denoting we are using basic version --- assets/js/{fuse.js => fuse.basic.min.js} | 0 layouts/partials/head.html | 2 +- 2 files changed, 1 insertion(+), 1 deletion(-) rename assets/js/{fuse.js => fuse.basic.min.js} (100%) diff --git a/assets/js/fuse.js b/assets/js/fuse.basic.min.js similarity index 100% rename from assets/js/fuse.js rename to assets/js/fuse.basic.min.js diff --git a/layouts/partials/head.html b/layouts/partials/head.html index 86ee5747..2fabbe60 100644 --- a/layouts/partials/head.html +++ b/layouts/partials/head.html @@ -72,7 +72,7 @@ {{- if (eq .Layout `search`) -}} {{- $fastsearch := resources.Get "js/fastsearch.js" | js.Build (dict "params" (dict "fuseOpts" .Site.Params.fuseOpts)) }} -{{- $fusejs := resources.Get "js/fuse.js" }} +{{- $fusejs := resources.Get "js/fuse.basic.min.js" }} {{- if not .Site.Params.assets.disableFingerprinting }} {{- $search := (slice $fusejs $fastsearch ) | resources.Concat "assets/js/search.js" | minify | fingerprint }} From 81ddc76efb25349f0dcc41ef14143414b13b2fc0 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 5 Feb 2022 17:54:35 +0530 Subject: [PATCH 006/254] Update `fuse.js` v6.4.6 to v6.5.3 basic - https://github.com/krisk/Fuse/releases/tag/v6.5.3 --- assets/js/fuse.basic.min.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/assets/js/fuse.basic.min.js b/assets/js/fuse.basic.min.js index 3ca4e666..025c4457 100644 --- a/assets/js/fuse.basic.min.js +++ b/assets/js/fuse.basic.min.js @@ -1,9 +1,9 @@ /** - * Fuse.js v6.4.6 - Lightweight fuzzy-search (http://fusejs.io) + * Fuse.js v6.5.3 - Lightweight fuzzy-search (http://fusejs.io) * * Copyright (c) 2021 Kiro Risk (http://kiro.me) * All Rights Reserved. Apache Software License 2.0 * * http://www.apache.org/licenses/LICENSE-2.0 */ -var e,t;e=this,t=function(){"use strict";function e(t){return(e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(t)}function t(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function n(e,t){for(var n=0;ne.length)&&(t=e.length);for(var n=0,r=new Array(t);n0&&void 0!==arguments[0]?arguments[0]:3,t=new Map,n=Math.pow(10,e);return{get:function(e){var r=e.match(w).length;if(t.has(r))return t.get(r);var i=1/Math.sqrt(r),o=parseFloat(Math.round(i*n)/n);return t.set(r,o),o},clear:function(){t.clear()}}}var _=function(){function e(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=n.getFn,i=void 0===r?x.getFn:r;t(this,e),this.norm=L(3),this.getFn=i,this.isCreated=!1,this.setIndexRecords()}return r(e,[{key:"setSources",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];this.docs=e}},{key:"setIndexRecords",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];this.records=e}},{key:"setKeys",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];this.keys=t,this._keysMap={},t.forEach((function(t,n){e._keysMap[t.id]=n}))}},{key:"create",value:function(){var e=this;!this.isCreated&&this.docs.length&&(this.isCreated=!0,u(this.docs[0])?this.docs.forEach((function(t,n){e._addString(t,n)})):this.docs.forEach((function(t,n){e._addObject(t,n)})),this.norm.clear())}},{key:"add",value:function(e){var t=this.size();u(e)?this._addString(e,t):this._addObject(e,t)}},{key:"removeAt",value:function(e){this.records.splice(e,1);for(var t=e,n=this.size();t2&&void 0!==arguments[2]?arguments[2]:{},r=n.getFn,i=void 0===r?x.getFn:r,o=new _({getFn:i});return o.setKeys(e.map(b)),o.setSources(t),o.create(),o}function O(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.errors,r=void 0===n?0:n,i=t.currentLocation,o=void 0===i?0:i,a=t.expectedLocation,c=void 0===a?0:a,s=t.distance,h=void 0===s?x.distance:s,u=t.ignoreLocation,l=void 0===u?x.ignoreLocation:u,d=r/e.length;if(l)return d;var f=Math.abs(c-o);return h?d+f/h:f?1:d}function A(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:x.minMatchCharLength,n=[],r=-1,i=-1,o=0,a=e.length;o=t&&n.push([r,i]),r=-1)}return e[o-1]&&o-r>=t&&n.push([r,o-1]),n}function j(e){for(var t={},n=0,r=e.length;n1&&void 0!==arguments[1]?arguments[1]:{},o=i.location,a=void 0===o?x.location:o,c=i.threshold,s=void 0===c?x.threshold:c,h=i.distance,u=void 0===h?x.distance:h,l=i.includeMatches,d=void 0===l?x.includeMatches:l,f=i.findAllMatches,v=void 0===f?x.findAllMatches:f,y=i.minMatchCharLength,g=void 0===y?x.minMatchCharLength:y,p=i.isCaseSensitive,m=void 0===p?x.isCaseSensitive:p,b=i.ignoreLocation,k=void 0===b?x.ignoreLocation:b;if(t(this,e),this.options={location:a,threshold:s,distance:u,includeMatches:d,findAllMatches:v,minMatchCharLength:g,isCaseSensitive:m,ignoreLocation:k},this.pattern=m?n:n.toLowerCase(),this.chunks=[],this.pattern.length){var M=function(e,t){r.chunks.push({pattern:e,alphabet:j(e),startIndex:t})},w=this.pattern.length;if(w>32){for(var L=0,_=w%32,S=w-_;L3&&void 0!==arguments[3]?arguments[3]:{},i=r.location,o=void 0===i?x.location:i,a=r.distance,c=void 0===a?x.distance:a,s=r.threshold,h=void 0===s?x.threshold:s,u=r.findAllMatches,l=void 0===u?x.findAllMatches:u,d=r.minMatchCharLength,f=void 0===d?x.minMatchCharLength:d,v=r.includeMatches,y=void 0===v?x.includeMatches:v,p=r.ignoreLocation,m=void 0===p?x.ignoreLocation:p;if(t.length>32)throw new Error(g(32));for(var b,k=t.length,M=e.length,w=Math.max(0,Math.min(o,M)),L=h,_=w,S=f>1||y,j=S?Array(M):[];(b=e.indexOf(t,_))>-1;){var E=O(t,{currentLocation:b,expectedLocation:w,distance:c,ignoreLocation:m});if(L=Math.min(E,L),_=b+k,S)for(var I=0;I=J;U-=1){var q=U-1,B=n[e.charAt(q)];if(S&&(j[q]=+!!B),T[U]=(T[U+1]<<1|1)&B,$&&(T[U]|=(C[U+1]|C[U])<<1|1|C[U+1]),T[U]&N&&(F=O(t,{errors:$,currentLocation:q,expectedLocation:w,distance:c,ignoreLocation:m}))<=L){if(L=F,(_=q)<=w)break;J=Math.max(1,2*w-_)}}var V=O(t,{errors:$+1,currentLocation:w,expectedLocation:w,distance:c,ignoreLocation:m});if(V>L)break;C=T}var G={isMatch:_>=0,score:Math.max(.001,F)};if(S){var H=A(j,f);H.length?y&&(G.indices=H):G.isMatch=!1}return G}(e,n,i,{location:a+o,distance:s,threshold:h,findAllMatches:u,minMatchCharLength:l,includeMatches:r,ignoreLocation:d}),m=p.isMatch,b=p.score,k=p.indices;m&&(y=!0),v+=b,m&&k&&(f=[].concat(c(f),c(k)))}));var p={isMatch:y,score:y?v/this.chunks.length:1};return y&&r&&(p.indices=f),p}}]),e}(),I=[];function C(e,t){for(var n=0,r=I.length;n-1&&(n.refIndex=e.idx),t.matches.push(n)}}))}function N(e,t){t.score=e.score}function $(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.includeMatches,i=void 0===r?x.includeMatches:r,o=n.includeScore,a=void 0===o?x.includeScore:o,c=[];return i&&c.push(P),a&&c.push(N),e.map((function(e){var n=e.idx,r={item:t[n],refIndex:n};return c.length&&c.forEach((function(t){t(e,r)})),r}))}var D=function(){function e(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=arguments.length>2?arguments[2]:void 0;if(t(this,e),this.options=a({},x,{},r),this.options.useExtendedSearch)throw new Error("Extended search is not available");this._keyStore=new m(this.options.keys),this.setCollection(n,i)}return r(e,[{key:"setCollection",value:function(e,t){if(this._docs=e,t&&!(t instanceof _))throw new Error("Incorrect 'index' type");this._myIndex=t||S(this.options.keys,this._docs,{getFn:this.options.getFn})}},{key:"add",value:function(e){f(e)&&(this._docs.push(e),this._myIndex.add(e))}},{key:"remove",value:function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:function(){return!1},t=[],n=0,r=this._docs.length;n1&&void 0!==arguments[1]?arguments[1]:{},n=t.limit,r=void 0===n?-1:n,i=this.options,o=i.includeMatches,a=i.includeScore,c=i.shouldSort,s=i.sortFn,h=i.ignoreFieldNorm,d=u(e)?u(this._docs[0])?this._searchStringList(e):this._searchObjectList(e):this._searchLogical(e);return F(d,{ignoreFieldNorm:h}),c&&d.sort(s),l(r)&&r>-1&&(d=d.slice(0,r)),$(d,this._docs,{includeMatches:o,includeScore:a})}},{key:"_searchStringList",value:function(e){var t=C(e,this.options),n=this._myIndex.records,r=[];return n.forEach((function(e){var n=e.v,i=e.i,o=e.n;if(f(n)){var a=t.searchIn(n),c=a.isMatch,s=a.score,h=a.indices;c&&r.push({item:n,idx:i,matches:[{score:s,value:n,norm:o,indices:h}]})}})),r}},{key:"_searchLogical",value:function(e){throw new Error("Logical search is not available")}},{key:"_searchObjectList",value:function(e){var t=this,n=C(e,this.options),r=this._myIndex,i=r.keys,o=r.records,a=[];return o.forEach((function(e){var r=e.$,o=e.i;if(f(r)){var s=[];i.forEach((function(e,i){s.push.apply(s,c(t._findMatches({key:e,value:r[i],searcher:n})))})),s.length&&a.push({idx:o,item:r,matches:s})}})),a}},{key:"_findMatches",value:function(e){var t=e.key,n=e.value,r=e.searcher;if(!f(n))return[];var i=[];if(h(n))n.forEach((function(e){var n=e.v,o=e.i,a=e.n;if(f(n)){var c=r.searchIn(n),s=c.isMatch,h=c.score,u=c.indices;s&&i.push({score:h,key:t,value:n,idx:o,norm:a,indices:u})}}));else{var o=n.v,a=n.n,c=r.searchIn(o),s=c.isMatch,u=c.score,l=c.indices;s&&i.push({score:u,key:t,value:o,norm:a,indices:l})}return i}}]),e}();return D.version="6.4.6",D.createIndex=S,D.parseIndex=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.getFn,r=void 0===n?x.getFn:n,i=e.keys,o=e.records,a=new _({getFn:r});return a.setKeys(i),a.setIndexRecords(o),a},D.config=x,D},"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e=e||self).Fuse=t(); \ No newline at end of file +var e,t;e=this,t=function(){"use strict";function e(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function t(t){for(var n=1;ne.length)&&(t=e.length);for(var n=0,r=new Array(t);n0&&void 0!==arguments[0]?arguments[0]:1,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:3,n=new Map,r=Math.pow(10,t);return{get:function(t){var i=t.match(_).length;if(n.has(i))return n.get(i);var o=1/Math.pow(i,.5*e),a=parseFloat(Math.round(o*r)/r);return n.set(i,a),a},clear:function(){n.clear()}}}var O=function(){function e(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=t.getFn,i=void 0===n?L.getFn:n,o=t.fieldNormWeight,a=void 0===o?L.fieldNormWeight:o;r(this,e),this.norm=S(a,3),this.getFn=i,this.isCreated=!1,this.setIndexRecords()}return o(e,[{key:"setSources",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];this.docs=e}},{key:"setIndexRecords",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];this.records=e}},{key:"setKeys",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];this.keys=t,this._keysMap={},t.forEach((function(t,n){e._keysMap[t.id]=n}))}},{key:"create",value:function(){var e=this;!this.isCreated&&this.docs.length&&(this.isCreated=!0,u(this.docs[0])?this.docs.forEach((function(t,n){e._addString(t,n)})):this.docs.forEach((function(t,n){e._addObject(t,n)})),this.norm.clear())}},{key:"add",value:function(e){var t=this.size();u(e)?this._addString(e,t):this._addObject(e,t)}},{key:"removeAt",value:function(e){this.records.splice(e,1);for(var t=e,n=this.size();t2&&void 0!==arguments[2]?arguments[2]:{},r=n.getFn,i=void 0===r?L.getFn:r,o=n.fieldNormWeight,a=void 0===o?L.fieldNormWeight:o,c=new O({getFn:i,fieldNormWeight:a});return c.setKeys(e.map(k)),c.setSources(t),c.create(),c}function j(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.errors,r=void 0===n?0:n,i=t.currentLocation,o=void 0===i?0:i,a=t.expectedLocation,c=void 0===a?0:a,s=t.distance,h=void 0===s?L.distance:s,u=t.ignoreLocation,l=void 0===u?L.ignoreLocation:u,d=r/e.length;if(l)return d;var f=Math.abs(c-o);return h?d+f/h:f?1:d}function E(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:L.minMatchCharLength,n=[],r=-1,i=-1,o=0,a=e.length;o=t&&n.push([r,i]),r=-1)}return e[o-1]&&o-r>=t&&n.push([r,o-1]),n}var I=32;function C(e){for(var t={},n=0,r=e.length;n1&&void 0!==arguments[1]?arguments[1]:{},o=i.location,a=void 0===o?L.location:o,c=i.threshold,s=void 0===c?L.threshold:c,h=i.distance,u=void 0===h?L.distance:h,l=i.includeMatches,d=void 0===l?L.includeMatches:l,f=i.findAllMatches,v=void 0===f?L.findAllMatches:f,g=i.minMatchCharLength,y=void 0===g?L.minMatchCharLength:g,p=i.isCaseSensitive,m=void 0===p?L.isCaseSensitive:p,b=i.ignoreLocation,k=void 0===b?L.ignoreLocation:b;if(r(this,e),this.options={location:a,threshold:s,distance:u,includeMatches:d,findAllMatches:v,minMatchCharLength:y,isCaseSensitive:m,ignoreLocation:k},this.pattern=m?t:t.toLowerCase(),this.chunks=[],this.pattern.length){var M=function(e,t){n.chunks.push({pattern:e,alphabet:C(e),startIndex:t})},w=this.pattern.length;if(w>I){for(var x=0,_=w%I,S=w-_;x3&&void 0!==arguments[3]?arguments[3]:{},i=r.location,o=void 0===i?L.location:i,a=r.distance,c=void 0===a?L.distance:a,s=r.threshold,h=void 0===s?L.threshold:s,u=r.findAllMatches,l=void 0===u?L.findAllMatches:u,d=r.minMatchCharLength,f=void 0===d?L.minMatchCharLength:d,v=r.includeMatches,g=void 0===v?L.includeMatches:v,y=r.ignoreLocation,m=void 0===y?L.ignoreLocation:y;if(t.length>I)throw new Error(p(I));for(var b,k=t.length,M=e.length,w=Math.max(0,Math.min(o,M)),x=h,_=w,S=f>1||g,O=S?Array(M):[];(b=e.indexOf(t,_))>-1;){var A=j(t,{currentLocation:b,expectedLocation:w,distance:c,ignoreLocation:m});if(x=Math.min(A,x),_=b+k,S)for(var C=0;C=T;R-=1){var U=R-1,B=n[e.charAt(U)];if(S&&(O[U]=+!!B),J[R]=(J[R+1]<<1|1)&B,$&&(J[R]|=(F[R+1]|F[R])<<1|1|F[R+1]),J[R]&W&&(N=j(t,{errors:$,currentLocation:U,expectedLocation:w,distance:c,ignoreLocation:m}))<=x){if(x=N,(_=U)<=w)break;T=Math.max(1,2*w-_)}}if(j(t,{errors:$+1,currentLocation:w,expectedLocation:w,distance:c,ignoreLocation:m})>x)break;F=J}var V={isMatch:_>=0,score:Math.max(.001,N)};if(S){var q=E(O,f);q.length?g&&(V.indices=q):V.isMatch=!1}return V}(e,n,i,{location:a+o,distance:s,threshold:h,findAllMatches:u,minMatchCharLength:l,includeMatches:r,ignoreLocation:d}),m=y.isMatch,b=y.score,k=y.indices;m&&(g=!0),v+=b,m&&k&&(f=[].concat(c(f),c(k)))}));var y={isMatch:g,score:g?v/this.chunks.length:1};return g&&r&&(y.indices=f),y}}]),e}(),N=[];function P(e,t){for(var n=0,r=N.length;n-1&&(n.refIndex=e.idx),t.matches.push(n)}}))}function D(e,t){t.score=e.score}function K(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.includeMatches,i=void 0===r?L.includeMatches:r,o=n.includeScore,a=void 0===o?L.includeScore:o,c=[];return i&&c.push($),a&&c.push(D),e.map((function(e){var n=e.idx,r={item:t[n],refIndex:n};return c.length&&c.forEach((function(t){t(e,r)})),r}))}var T=function(){function e(n){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=arguments.length>2?arguments[2]:void 0;if(r(this,e),this.options=t(t({},L),i),this.options.useExtendedSearch)throw new Error(y);this._keyStore=new b(this.options.keys),this.setCollection(n,o)}return o(e,[{key:"setCollection",value:function(e,t){if(this._docs=e,t&&!(t instanceof O))throw new Error("Incorrect 'index' type");this._myIndex=t||A(this.options.keys,this._docs,{getFn:this.options.getFn,fieldNormWeight:this.options.fieldNormWeight})}},{key:"add",value:function(e){f(e)&&(this._docs.push(e),this._myIndex.add(e))}},{key:"remove",value:function(){for(var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:function(){return!1},t=[],n=0,r=this._docs.length;n1&&void 0!==arguments[1]?arguments[1]:{},n=t.limit,r=void 0===n?-1:n,i=this.options,o=i.includeMatches,a=i.includeScore,c=i.shouldSort,s=i.sortFn,h=i.ignoreFieldNorm,d=u(e)?u(this._docs[0])?this._searchStringList(e):this._searchObjectList(e):this._searchLogical(e);return W(d,{ignoreFieldNorm:h}),c&&d.sort(s),l(r)&&r>-1&&(d=d.slice(0,r)),K(d,this._docs,{includeMatches:o,includeScore:a})}},{key:"_searchStringList",value:function(e){var t=P(e,this.options),n=this._myIndex.records,r=[];return n.forEach((function(e){var n=e.v,i=e.i,o=e.n;if(f(n)){var a=t.searchIn(n),c=a.isMatch,s=a.score,h=a.indices;c&&r.push({item:n,idx:i,matches:[{score:s,value:n,norm:o,indices:h}]})}})),r}},{key:"_searchLogical",value:function(e){throw new Error("Logical search is not available")}},{key:"_searchObjectList",value:function(e){var t=this,n=P(e,this.options),r=this._myIndex,i=r.keys,o=r.records,a=[];return o.forEach((function(e){var r=e.$,o=e.i;if(f(r)){var s=[];i.forEach((function(e,i){s.push.apply(s,c(t._findMatches({key:e,value:r[i],searcher:n})))})),s.length&&a.push({idx:o,item:r,matches:s})}})),a}},{key:"_findMatches",value:function(e){var t=e.key,n=e.value,r=e.searcher;if(!f(n))return[];var i=[];if(h(n))n.forEach((function(e){var n=e.v,o=e.i,a=e.n;if(f(n)){var c=r.searchIn(n),s=c.isMatch,h=c.score,u=c.indices;s&&i.push({score:h,key:t,value:n,idx:o,norm:a,indices:u})}}));else{var o=n.v,a=n.n,c=r.searchIn(o),s=c.isMatch,u=c.score,l=c.indices;s&&i.push({score:u,key:t,value:o,norm:a,indices:l})}return i}}]),e}();return T.version="6.5.3",T.createIndex=A,T.parseIndex=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.getFn,r=void 0===n?L.getFn:n,i=t.fieldNormWeight,o=void 0===i?L.fieldNormWeight:i,a=e.keys,c=e.records,s=new O({getFn:r,fieldNormWeight:o});return s.setKeys(a),s.setIndexRecords(c),s},T.config=L,T},"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).Fuse=t(); \ No newline at end of file From 06f97458a77e0b9836c90e33db3deeab6832f980 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 5 Feb 2022 18:40:37 +0530 Subject: [PATCH 007/254] Delete FUNDING.yml --- .github/FUNDING.yml | 12 ------------ 1 file changed, 12 deletions(-) delete mode 100644 .github/FUNDING.yml diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml deleted file mode 100644 index 6a78a557..00000000 --- a/.github/FUNDING.yml +++ /dev/null @@ -1,12 +0,0 @@ -# These are supported funding model platforms - -github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2] -patreon: # Replace with a single Patreon username -open_collective: # Replace with a single Open Collective username -ko_fi: adityatelange -tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel -community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry -liberapay: # Replace with a single Liberapay username -issuehunt: # Replace with a single IssueHunt username -otechie: # Replace with a single Otechie username -custom: ['https://www.buymeacoffee.com/adityatelange'] From 43c810c3e20bcf04e17a3e26a4ceacd9dfd9f22a Mon Sep 17 00:00:00 2001 From: Jannik Arndt Date: Tue, 15 Feb 2022 15:31:21 +0100 Subject: [PATCH 008/254] Remove duplicate call to hugo.Generator (#786) --- layouts/partials/head.html | 3 --- 1 file changed, 3 deletions(-) diff --git a/layouts/partials/head.html b/layouts/partials/head.html index 2fabbe60..0d3fa72d 100644 --- a/layouts/partials/head.html +++ b/layouts/partials/head.html @@ -104,9 +104,6 @@ -{{- /* Generator */}} -{{ hugo.Generator }} - {{- /* RSS */}} {{ range .AlternativeOutputFormats -}} From 15b984bd215b7c4a73385e76486ec93b0aadcc53 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Fri, 11 Mar 2022 19:32:37 +0530 Subject: [PATCH 009/254] Fix `pre` getting a dark background fixes: #723 --- assets/css/common/post-single.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assets/css/common/post-single.css b/assets/css/common/post-single.css index 79ccbec6..9988572f 100644 --- a/assets/css/common/post-single.css +++ b/assets/css/common/post-single.css @@ -154,7 +154,7 @@ } .post-content .highlight:not(table), -.post-content pre { +.post-content .highlight pre { margin: 10px auto; background: var(--hljs-bg) !important; border-radius: var(--radius); From 912eddde0a79b883fc8fdc88d23d297b8be1bb22 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Fri, 11 Mar 2022 20:31:57 +0530 Subject: [PATCH 010/254] Revert "Fix `pre` getting a dark background" This reverts commit 15b984bd215b7c4a73385e76486ec93b0aadcc53. --- assets/css/common/post-single.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/assets/css/common/post-single.css b/assets/css/common/post-single.css index 9988572f..79ccbec6 100644 --- a/assets/css/common/post-single.css +++ b/assets/css/common/post-single.css @@ -154,7 +154,7 @@ } .post-content .highlight:not(table), -.post-content .highlight pre { +.post-content pre { margin: 10px auto; background: var(--hljs-bg) !important; border-radius: var(--radius); From 26315a9e4cccb69bc75126c875ff2ab80a7b7547 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?W=C3=81NG=20Xu=C4=9Bru=C3=AC?= <1175567+xen0n@users.noreply.github.com> Date: Fri, 11 Mar 2022 23:06:14 +0800 Subject: [PATCH 011/254] Add icon for Bilibili (#814) The icon is re-drawn by myself to use outlines, referring to the icon used on bilibili.com and the simpleicons version (which all used fills). --- layouts/partials/svg.html | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/layouts/partials/svg.html b/layouts/partials/svg.html index 89446be5..51a0fc17 100644 --- a/layouts/partials/svg.html +++ b/layouts/partials/svg.html @@ -21,6 +21,14 @@ style="font-variation-settings:normal" d="M1.774 18.063V5.466h5.51c1.978 0 3.116 1.326 3.055 2.806-.043 1.049-.711 2.988-2.643 2.988h-5.93H7.73c1.224 0 3.532 1.13 3.532 3.532 0 2.4-1.873 3.27-3.318 3.27zm12.57-4.459h7.89s.012-4.18-4.167-4.18c-5.237 0-5.277 9.11-.3 9.11 3.06 0 3.935-1.806 3.935-1.806M15.526 5.823h4.987" /> +{{- else if (eq $icon_name "bilibili") -}} + + + + + + + {{- else if (eq $icon_name "buymeacoffee") -}} Date: Fri, 11 Mar 2022 20:43:51 +0530 Subject: [PATCH 012/254] Add icon for pgp key (#784) --- layouts/partials/svg.html | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/layouts/partials/svg.html b/layouts/partials/svg.html index 51a0fc17..31e3af0d 100644 --- a/layouts/partials/svg.html +++ b/layouts/partials/svg.html @@ -330,6 +330,12 @@ d="M7.144 19.532l1.049-5.751c.11-.606.691-1.002 1.304-.948 2.155.192 6.877.1 8.818-4.002 2.554-5.397-.59-7.769-6.295-7.769H7.43a1.97 1.97 0 0 0-1.944 1.655L2.77 19.507a.857.857 0 0 0 .846.994h2.368a1.18 1.18 0 0 0 1.161-.969zM7.967 22.522a.74.74 0 0 0 .666.416h2.313c.492 0 .923-.351 1.003-.837l.759-4.601c.095-.523.597-.866 1.127-.819 1.86.166 5.567-.118 6.85-3.821.554-1.6.705-2.954.408-4.018" style="font-variation-settings:normal" stroke="currentColor" stroke-linejoin="miter" /> +{{- else if (eq $icon_name "pgpkey") -}} + + + + {{- else if (eq $icon_name "phone") -}} From 2a1390bef78e6d6456cf1cce3c98aa3927410e77 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Fri, 11 Mar 2022 20:49:27 +0530 Subject: [PATCH 013/254] Match `key` as well for `pgpkey` icon amend to 53fd4bb857d29a651487a77a62c4c91901a1582a --- layouts/partials/svg.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/layouts/partials/svg.html b/layouts/partials/svg.html index 31e3af0d..9b679100 100644 --- a/layouts/partials/svg.html +++ b/layouts/partials/svg.html @@ -330,7 +330,7 @@ d="M7.144 19.532l1.049-5.751c.11-.606.691-1.002 1.304-.948 2.155.192 6.877.1 8.818-4.002 2.554-5.397-.59-7.769-6.295-7.769H7.43a1.97 1.97 0 0 0-1.944 1.655L2.77 19.507a.857.857 0 0 0 .846.994h2.368a1.18 1.18 0 0 0 1.161-.969zM7.967 22.522a.74.74 0 0 0 .666.416h2.313c.492 0 .923-.351 1.003-.837l.759-4.601c.095-.523.597-.866 1.127-.819 1.86.166 5.567-.118 6.85-3.821.554-1.6.705-2.954.408-4.018" style="font-variation-settings:normal" stroke="currentColor" stroke-linejoin="miter" /> -{{- else if (eq $icon_name "pgpkey") -}} +{{- else if or (eq $icon_name "pgpkey") (eq $icon_name "key") -}} From 80928d9f2327809b7ecccf36930e4b726a7d10b2 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 12 Mar 2022 19:33:29 +0530 Subject: [PATCH 014/254] Fix `pre` getting a dark background fixes: #723 --- assets/css/common/post-single.css | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/assets/css/common/post-single.css b/assets/css/common/post-single.css index 79ccbec6..b9b97097 100644 --- a/assets/css/common/post-single.css +++ b/assets/css/common/post-single.css @@ -153,8 +153,7 @@ border-radius: var(--radius); } -.post-content .highlight:not(table), -.post-content pre { +.post-content .highlight:not(table) { margin: 10px auto; background: var(--hljs-bg) !important; border-radius: var(--radius); @@ -207,8 +206,8 @@ margin: auto 0; padding: 10px; color: rgb(213, 213, 214); - background: 0 0; - border-radius: 0; + background: var(--hljs-bg) !important; + border-radius: var(--radius); overflow-x: auto; word-break: break-all; } From 42c3c937a1089dd1f48ea113e660a3941a8646a6 Mon Sep 17 00:00:00 2001 From: Emil Erlandsson Date: Sun, 13 Mar 2022 10:56:42 +0100 Subject: [PATCH 015/254] Add Swedish (sv) translation sv.yaml (#829) --- i18n/sv.yaml | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 i18n/sv.yaml diff --git a/i18n/sv.yaml b/i18n/sv.yaml new file mode 100644 index 00000000..65ce4226 --- /dev/null +++ b/i18n/sv.yaml @@ -0,0 +1,28 @@ +- id: prev_page + translation: "Förra Sidan" + +- id: next_page + translation: "Nästa Sida" + +- id: read_time + translation: + one: "1 min" + other: "{{ .Count }} min" + +- id: toc + translation: "Innehållsförteckning" + +- id: translations + translation: "Översättningar" + +- id: home + translation: "Hem" + +- id: edit_post + translation: "Redigera" + +- id: code_copy + translation: "kopiera" + +- id: code_copied + translation: "kopierad!" From 5a5b0840edbf0dd0d532ab29bfb35c7acf2ade15 Mon Sep 17 00:00:00 2001 From: lavaicer <52038323+lavaicer@users.noreply.github.com> Date: Fri, 18 Mar 2022 00:51:53 +0800 Subject: [PATCH 016/254] Update zh.yaml MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit trans words -> 字 (#837) --- i18n/zh.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/i18n/zh.yaml b/i18n/zh.yaml index 7f15ab08..c341e039 100644 --- a/i18n/zh.yaml +++ b/i18n/zh.yaml @@ -9,6 +9,11 @@ one : "1 分钟" other: "{{ .Count }} 分钟" +- id: words + translation: + one: "字" + other: {{ .Count }}字 + - id: toc translation: "目录" From 16293e957831c67075e79285a5d04b8964b6a3bc Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Thu, 17 Mar 2022 22:33:05 +0530 Subject: [PATCH 017/254] Add missing quotes to zh: words --- i18n/zh.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/i18n/zh.yaml b/i18n/zh.yaml index c341e039..959325b6 100644 --- a/i18n/zh.yaml +++ b/i18n/zh.yaml @@ -12,7 +12,7 @@ - id: words translation: one: "字" - other: {{ .Count }}字 + other: "{{ .Count }}字" - id: toc translation: "目录" From e83d84012678105cf0ee854fba6e133b84a8e895 Mon Sep 17 00:00:00 2001 From: Fernando Filho Date: Fri, 18 Mar 2022 04:09:20 -0300 Subject: [PATCH 018/254] add social icon for Deezer (#811) Co-authored-by: Aditya Telange <21258296+adityatelange@users.noreply.github.com> --- layouts/partials/svg.html | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/layouts/partials/svg.html b/layouts/partials/svg.html index 9b679100..be788786 100644 --- a/layouts/partials/svg.html +++ b/layouts/partials/svg.html @@ -113,6 +113,11 @@ +{{- else if (eq $icon_name "deezer") -}} + + + {{- else if (eq $icon_name "discogs") -}} Date: Fri, 18 Mar 2022 09:12:56 +0200 Subject: [PATCH 019/254] Add kaggle icon to social icons (#830) --- layouts/partials/svg.html | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/layouts/partials/svg.html b/layouts/partials/svg.html index be788786..7b989274 100644 --- a/layouts/partials/svg.html +++ b/layouts/partials/svg.html @@ -243,6 +243,10 @@ +{{- else if (eq $icon_name "kaggle") -}} + + + {{- else if (eq $icon_name "kakaotalk") -}} From 375155061d42c6d7eb44ad4fe980d4ae021de66b Mon Sep 17 00:00:00 2001 From: Philipp Bastian <98668015+bikeophilipp@users.noreply.github.com> Date: Fri, 18 Mar 2022 08:31:37 +0100 Subject: [PATCH 020/254] Add icons for 'komoot' and 'letterboxd' (#799) * Add 'komoot' and 'letterboxd' icon to svg.html --- layouts/partials/svg.html | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/layouts/partials/svg.html b/layouts/partials/svg.html index 7b989274..f8f89633 100644 --- a/layouts/partials/svg.html +++ b/layouts/partials/svg.html @@ -271,11 +271,19 @@ +{{- else if (eq $icon_name "komoot") -}} + + + {{- else if (eq $icon_name "lastfm") -}} +{{- else if (eq $icon_name "letterboxd") -}} + + + {{- else if (eq $icon_name "liberapay") -}} From 496b84659727bc2403214a56778edca7fc7597eb Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Fri, 25 Mar 2022 19:48:54 +0530 Subject: [PATCH 021/254] Removing unit from `img`'s height attribute for label.icon https://developer.mozilla.org/en-US/docs/Web/HTML/Element/img#attr-height --- layouts/partials/header.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/layouts/partials/header.html b/layouts/partials/header.html index cc636598..f95a7a65 100644 --- a/layouts/partials/header.html +++ b/layouts/partials/header.html @@ -47,7 +47,7 @@ {{- if .Site.Params.label.icon }} logo + height="{{- .Site.Params.label.iconHeight | default "30" -}}"> {{- end -}} {{- $label_text -}} From 975972e04181007c61302054d18735dc440a0586 Mon Sep 17 00:00:00 2001 From: Chiahong <36815907+ChiahongHong@users.noreply.github.com> Date: Fri, 25 Mar 2022 22:21:23 +0800 Subject: [PATCH 022/254] Update Taiwanese Chinese translation (#848) --- i18n/zh-tw.yaml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/i18n/zh-tw.yaml b/i18n/zh-tw.yaml index c6b0e7fd..7b9d9db3 100644 --- a/i18n/zh-tw.yaml +++ b/i18n/zh-tw.yaml @@ -9,6 +9,11 @@ one : "1 分鐘" other: "{{ .Count }} 分鐘" +- id: words + translation: + one: "字" + other: "{{ .Count }} 字" + - id: toc translation: "目錄" From 575cc0ca8c4e5904c7ae77e76db812c52e5f8ed1 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sun, 27 Mar 2022 18:44:06 +0530 Subject: [PATCH 023/254] Use `site` function instead of `.Site` or `$.Site` - The site function provides global access to the same data as the .Site page method. - Current context (`.`) is never considered. --- layouts/_default/archives.html | 2 +- layouts/_default/baseof.html | 4 +- layouts/_default/index.json | 2 +- layouts/_default/list.html | 8 +-- layouts/_default/rss.xml | 22 ++++---- layouts/_default/single.html | 4 +- layouts/_default/terms.html | 2 +- layouts/partials/author.html | 4 +- layouts/partials/breadcrumbs.html | 4 +- layouts/partials/cover.html | 6 +- layouts/partials/edit_post.html | 8 +-- layouts/partials/footer.html | 12 ++-- layouts/partials/head.html | 56 +++++++++---------- layouts/partials/header.html | 30 +++++----- layouts/partials/home_info.html | 4 +- layouts/partials/index_profile.html | 6 +- layouts/partials/post_canonical.html | 4 +- layouts/partials/post_meta.html | 2 +- layouts/partials/templates/opengraph.html | 10 ++-- layouts/partials/templates/schema_json.html | 28 +++++----- layouts/partials/templates/twitter_cards.html | 6 +- layouts/partials/translation_list.html | 4 +- layouts/robots.txt | 2 +- 23 files changed, 115 insertions(+), 115 deletions(-) diff --git a/layouts/_default/archives.html b/layouts/_default/archives.html index 435d2a1e..e400e2c5 100644 --- a/layouts/_default/archives.html +++ b/layouts/_default/archives.html @@ -11,7 +11,7 @@ {{- $pages := where site.RegularPages "Type" "in" site.Params.mainSections }} -{{- if .Site.Params.ShowAllPagesInArchive }} +{{- if site.Params.ShowAllPagesInArchive }} {{- $pages = site.RegularPages }} {{- end }} diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index 6dfe7415..3d13f07a 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -1,5 +1,5 @@ - + {{- partial "head.html" . }} @@ -9,7 +9,7 @@ {{- if (or (ne .Kind `page` ) (eq .Layout `archives`) (eq .Layout `search`)) -}} {{- print "list" -}} {{- end -}} -{{- if eq $.Site.Params.defaultTheme `dark` -}} +{{- if eq site.Params.defaultTheme `dark` -}} {{- print " dark" }} {{- end -}} " id="top"> diff --git a/layouts/_default/index.json b/layouts/_default/index.json index 2c86f7c4..feeb437d 100644 --- a/layouts/_default/index.json +++ b/layouts/_default/index.json @@ -1,5 +1,5 @@ {{- $.Scratch.Add "index" slice -}} -{{- range .Site.RegularPages -}} +{{- range site.RegularPages -}} {{- if and (not .Params.searchHidden) (ne .Layout `archives`) (ne .Layout `search`) }} {{- $.Scratch.Add "index" (dict "title" .Title "content" .Plain "permalink" .Permalink "summary" .Summary) -}} {{- end }} diff --git a/layouts/_default/list.html b/layouts/_default/list.html index 0cc1ad9e..f4ff6eca 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -1,6 +1,6 @@ {{- define "main" }} -{{- if (and .Site.Params.profileMode.enabled .IsHome) }} +{{- if (and site.Params.profileMode.enabled .IsHome) }} {{- partial "index_profile.html" . }} {{- else }} {{/* if not profileMode */}} @@ -32,7 +32,7 @@ {{- $paginator := .Paginate $pages }} -{{- if and .IsHome .Site.Params.homeInfoParams (eq $paginator.PageNumber 1) }} +{{- if and .IsHome site.Params.homeInfoParams (eq $paginator.PageNumber 1) }} {{- partial "home_info.html" . }} {{- end }} @@ -41,7 +41,7 @@ {{- $class := "post-entry" }} -{{- $user_preferred := or .Site.Params.disableSpecial1stPost .Site.Params.homeInfoParams }} +{{- $user_preferred := or site.Params.disableSpecial1stPost site.Params.homeInfoParams }} {{- if (and $.IsHome (eq $paginator.PageNumber 1) (eq $index 0) (not $user_preferred)) }} {{- $class = "first-entry" }} {{- else if $term }} @@ -49,7 +49,7 @@ {{- end }}
- {{- $isHidden := (.Site.Params.cover.hidden | default .Site.Params.cover.hiddenInList) }} + {{- $isHidden := (site.Params.cover.hidden | default site.Params.cover.hiddenInList) }} {{- partial "cover.html" (dict "cxt" . "IsHome" true "isHidden" $isHidden) }}

diff --git a/layouts/_default/rss.xml b/layouts/_default/rss.xml index eca41b7e..134d50d4 100644 --- a/layouts/_default/rss.xml +++ b/layouts/_default/rss.xml @@ -1,31 +1,31 @@ {{- $pctx := . -}} -{{- if .IsHome -}}{{ $pctx = .Site }}{{- end -}} +{{- if .IsHome -}}{{ $pctx = site }}{{- end -}} {{- $pages := slice -}} {{- if or $.IsHome $.IsSection -}} {{- $pages = $pctx.RegularPages -}} {{- else -}} {{- $pages = $pctx.Pages -}} {{- end -}} -{{- $limit := .Site.Config.Services.RSS.Limit -}} +{{- $limit := site.Config.Services.RSS.Limit -}} {{- if ge $limit 1 -}} {{- $pages = $pages | first $limit -}} {{- end -}} {{- printf "" | safeHTML }} - {{ if eq .Title .Site.Title }}{{ .Site.Title }}{{ else }}{{ with .Title }}{{.}} on {{ end }}{{ .Site.Title }}{{ end }} + {{ if eq .Title site.Title }}{{ site.Title }}{{ else }}{{ with .Title }}{{.}} on {{ end }}{{ site.Title }}{{ end }} {{ .Permalink }} - Recent content {{ if ne .Title .Site.Title }}{{ with .Title }}in {{.}} {{ end }}{{ end }}on {{ .Site.Title }} - {{- with $.Site.Params.images }} + Recent content {{ if ne .Title site.Title }}{{ with .Title }}in {{.}} {{ end }}{{ end }}on {{ site.Title }} + {{- with site.Params.images }} {{ index . 0 | absURL }} {{ index . 0 | absURL }} {{- end }} - Hugo -- gohugo.io{{ with .Site.LanguageCode }} - {{.}}{{end}}{{ with .Site.Author.email }} - {{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}{{end}}{{ with .Site.Author.email }} - {{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}{{end}}{{ with .Site.Copyright }} + Hugo -- gohugo.io{{ with site.LanguageCode }} + {{.}}{{end}}{{ with site.Author.email }} + {{.}}{{ with site.Author.name }} ({{.}}){{end}}{{end}}{{ with site.Author.email }} + {{.}}{{ with site.Author.name }} ({{.}}){{end}}{{end}}{{ with site.Copyright }} {{.}}{{end}}{{ if not .Date.IsZero }} {{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}{{ end }} {{- with .OutputFormats.Get "RSS" -}} @@ -37,10 +37,10 @@ {{ .Title }} {{ .Permalink }} {{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }} - {{ with .Site.Author.email }}{{.}}{{ with $.Site.Author.name }} ({{.}}){{end}}{{end}} + {{ with site.Author.email }}{{.}}{{ with site.Author.name }} ({{.}}){{end}}{{end}} {{ .Permalink }} {{ with .Description | html }}{{ . }}{{ else }}{{ .Summary | html }}{{ end -}} - {{- if .Site.Params.ShowFullTextinRSS }} + {{- if site.Params.ShowFullTextinRSS }} {{ (printf "" .Content) | safeHTML }} {{- end }} diff --git a/layouts/_default/single.html b/layouts/_default/single.html index 1d983fd0..d313500a 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -21,7 +21,7 @@ {{- end }}

- {{- $isHidden := .Params.cover.hidden | default .Site.Params.cover.hiddenInSingle | default .Site.Params.cover.hidden }} + {{- $isHidden := .Params.cover.hidden | default site.Params.cover.hiddenInSingle | default site.Params.cover.hidden }} {{- partial "cover.html" (dict "cxt" . "IsHome" false "isHidden" $isHidden) }} {{- if (.Param "ShowToc") }} {{- partial "toc.html" . }} @@ -46,7 +46,7 @@ {{- if (.Param "ShowPostNavLinks") }} {{- partial "post_nav_links.html" . }} {{- end }} - {{- if (and .Site.Params.ShowShareButtons (ne .Params.disableShare true)) }} + {{- if (and site.Params.ShowShareButtons (ne .Params.disableShare true)) }} {{- partial "share_icons.html" . -}} {{- end }} diff --git a/layouts/_default/terms.html b/layouts/_default/terms.html index d5a9e66e..6fd26540 100644 --- a/layouts/_default/terms.html +++ b/layouts/_default/terms.html @@ -16,7 +16,7 @@ {{- range $key, $value := .Data.Terms.Alphabetical }} {{- $name := .Name }} {{- $count := .Count }} - {{- with $.Site.GetPage (printf "/%s/%s" $type $name) }} + {{- with site.GetPage (printf "/%s/%s" $type $name) }}
  • {{ .Name }} {{ $count }}
  • diff --git a/layouts/partials/author.html b/layouts/partials/author.html index 4582b126..8f2758fa 100644 --- a/layouts/partials/author.html +++ b/layouts/partials/author.html @@ -1,5 +1,5 @@ -{{- if or .Params.author .Site.Params.author }} -{{- $author := (.Params.author | default .Site.Params.author) }} +{{- if or .Params.author site.Params.author }} +{{- $author := (.Params.author | default site.Params.author) }} {{- $author_type := (printf "%T" $author) }} {{- if (or (eq $author_type "[]string") (eq $author_type "[]interface {}")) }} {{- (delimit $author ", " ) }} diff --git a/layouts/partials/breadcrumbs.html b/layouts/partials/breadcrumbs.html index 742254a3..7e8257b7 100644 --- a/layouts/partials/breadcrumbs.html +++ b/layouts/partials/breadcrumbs.html @@ -1,6 +1,6 @@ {{- if (.Param "ShowBreadCrumbs") -}} diff --git a/layouts/partials/social_icons.html b/layouts/partials/social_icons.html index 3f8d6a35..958a8590 100644 --- a/layouts/partials/social_icons.html +++ b/layouts/partials/social_icons.html @@ -1,6 +1,6 @@ {{- $currentPage := . }} - +
    From 2ecb08a5bac9723f264a1ee767494d2599a15aa3 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Fri, 15 Dec 2023 22:08:25 +0530 Subject: [PATCH 229/254] Plainify items insize toc list --- layouts/partials/toc.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/layouts/partials/toc.html b/layouts/partials/toc.html index d9b8b234..28f8694c 100644 --- a/layouts/partials/toc.html +++ b/layouts/partials/toc.html @@ -71,10 +71,10 @@ {{- end -}} {{- end }}
  • - {{- $header | safeHTML -}} + {{- $header | plainify | safeHTML -}} {{- else }}
  • - {{- $header | safeHTML -}} + {{- $header | plainify | safeHTML -}} {{- end -}} {{- end -}} From 6864770ad4dd67fe381e143ca48bdd81c38835ce Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Fri, 15 Dec 2023 22:09:15 +0530 Subject: [PATCH 230/254] Fix social icons extraneous margin --- assets/css/common/main.css | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/assets/css/common/main.css b/assets/css/common/main.css index 50022ac1..cd5c76fb 100644 --- a/assets/css/common/main.css +++ b/assets/css/common/main.css @@ -28,14 +28,12 @@ } .social-icons { - padding: 12px 0; -} - -.social-icons a:not(:last-of-type) { - margin-inline-end: 12px; + display: flex; + gap: 1rem; } .social-icons a svg { + display: block; height: 26px; width: 26px; } From 705ebeb72982dca772d2307cf3936710866dae99 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Fri, 15 Dec 2023 22:09:48 +0530 Subject: [PATCH 231/254] table styles update - reduce margins - rm reduced fontsize --- assets/css/common/post-single.css | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/assets/css/common/post-single.css b/assets/css/common/post-single.css index 14dc701b..7e40eea1 100644 --- a/assets/css/common/post-single.css +++ b/assets/css/common/post-single.css @@ -130,19 +130,18 @@ } .post-content table { - margin-bottom: 32px; + margin-bottom: var(--content-gap); } .post-content table th, .post-content table:not(.highlighttable, .highlight table, .gist .highlight) td { min-width: 80px; - padding: 12px 8px; + padding: 8px 5px; line-height: 1.5; border-bottom: 1px solid var(--border); } .post-content table th { - font-size: 14px; text-align: start; } From 28ec7a407d5c44789d6f608419dc147692a00327 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 16 Dec 2023 00:32:25 +0530 Subject: [PATCH 232/254] Revert "Fix social icons extraneous margin" This reverts commit 6864770ad4dd67fe381e143ca48bdd81c38835ce. --- assets/css/common/main.css | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/assets/css/common/main.css b/assets/css/common/main.css index cd5c76fb..50022ac1 100644 --- a/assets/css/common/main.css +++ b/assets/css/common/main.css @@ -28,12 +28,14 @@ } .social-icons { - display: flex; - gap: 1rem; + padding: 12px 0; +} + +.social-icons a:not(:last-of-type) { + margin-inline-end: 12px; } .social-icons a svg { - display: block; height: 26px; width: 26px; } From 65c2720ab99368c2125fa39ed1433e0677683b75 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 16 Dec 2023 13:09:19 +0530 Subject: [PATCH 233/254] lazy load cover images in lists only --- layouts/_default/list.html | 2 +- layouts/_default/single.html | 2 +- layouts/partials/cover.html | 11 ++++++----- 3 files changed, 8 insertions(+), 7 deletions(-) diff --git a/layouts/_default/list.html b/layouts/_default/list.html index 833f9239..2640f164 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -65,7 +65,7 @@
    {{- $isHidden := (.Param "cover.hiddenInList") | default (.Param "cover.hidden") | default false }} - {{- partial "cover.html" (dict "cxt" . "IsHome" true "isHidden" $isHidden) }} + {{- partial "cover.html" (dict "cxt" . "IsSingle" false "isHidden" $isHidden) }}

    {{- .Title }} diff --git a/layouts/_default/single.html b/layouts/_default/single.html index ee0fec43..837f6197 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -22,7 +22,7 @@ {{- end }}

    {{- $isHidden := (.Param "cover.hiddenInSingle") | default (.Param "cover.hidden") | default false }} - {{- partial "cover.html" (dict "cxt" . "IsHome" false "isHidden" $isHidden) }} + {{- partial "cover.html" (dict "cxt" . "IsSingle" true "isHidden" $isHidden) }} {{- if (.Param "ShowToc") }} {{- partial "toc.html" . }} {{- end }} diff --git a/layouts/partials/cover.html b/layouts/partials/cover.html index 0f8bfbce..e92b5557 100644 --- a/layouts/partials/cover.html +++ b/layouts/partials/cover.html @@ -1,9 +1,10 @@ {{- with .cxt}} {{/* Apply proper context from dict */}} {{- if (and .Params.cover.image (not $.isHidden)) }} {{- $alt := (.Params.cover.alt | default .Params.cover.caption | plainify) }} +{{- $loading := cond $.IsSingle "eager" "lazy" }}
    {{- $responsiveImages := (.Params.cover.responsiveImages | default site.Params.cover.responsiveImages) | default true }} - {{- $addLink := (and site.Params.cover.linkFullImages (not $.IsHome)) }} + {{- $addLink := (and site.Params.cover.linkFullImages $.IsSingle) }} {{- $pageBundleCover := (.Resources.ByType "image").GetMatch (printf "*%s*" (.Params.cover.image)) }} {{- $globalResourcesCover := (resources.ByType "image").GetMatch (printf "*%s*" (.Params.cover.image)) }} {{- $cover := (or $pageBundleCover $globalResourcesCover)}} @@ -17,7 +18,7 @@ {{- end -}} {{- $prod := (hugo.IsProduction | or (eq site.Params.env "production")) }} {{- if (and (in $processableFormats $cover.MediaType.SubType) ($responsiveImages) (eq $prod true)) }} - {{ $alt }} {{- else }}{{/* Unprocessable image or responsive images disabled */}} - {{ $alt }} + {{ $alt }} {{- end }} {{- else }}{{/* For absolute urls and external links, no img processing here */}} {{- if $addLink }}{{ end -}} - {{ $alt }} + {{ $alt }} {{- end }} {{- if $addLink }}{{ end -}} {{/* Display Caption */}} - {{- if not $.IsHome }} + {{- if $.IsSingle }} {{ with .Params.cover.caption }}

    {{ . | markdownify }}

    {{- end }} {{- end }}
    From 60984fd13658db175e8945467d3dd799f2fdcc32 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 16 Dec 2023 14:06:46 +0530 Subject: [PATCH 234/254] Add icon for 'draft' posts https://fonts.google.com/icons?selected=Material%20Symbols%20Outlined%3Aedit_note%3AFILL%400%3Bwght%40400%3BGRAD%400%3Bopsz%4048 LICENSE: https://developers.google.com/fonts/faq#can_i_use_any_font_in_a_commercial_product --- assets/css/common/post-entry.css | 10 +++++++--- layouts/_default/archives.html | 13 ++++++++++--- layouts/_default/list.html | 11 +++++++++-- layouts/_default/single.html | 11 +++++++++-- 4 files changed, 35 insertions(+), 10 deletions(-) diff --git a/assets/css/common/post-entry.css b/assets/css/common/post-entry.css index 885aa2a4..c3cba370 100644 --- a/assets/css/common/post-entry.css +++ b/assets/css/common/post-entry.css @@ -80,13 +80,17 @@ bottom: 0; } -.entry-cover, -.entry-isdraft { - font-size: 14px; +.entry-hint { color: var(--secondary); } +.entry-hint-parent { + display: flex; + justify-content: space-between; +} + .entry-cover { + font-size: 14px; margin-bottom: var(--gap); text-align: center; } diff --git a/layouts/_default/archives.html b/layouts/_default/archives.html index d2c4d76b..b38e39a1 100644 --- a/layouts/_default/archives.html +++ b/layouts/_default/archives.html @@ -6,7 +6,7 @@ {{- if (.Param "ShowRssButtonInSectionTermList") }} {{- $rss := (.OutputFormats.Get "rss") }} {{- if (eq .Kind `page`) }} - {{- $rss = (.Parent.OutputFormats.Get "rss") }} + {{- $rss = (.Parent.OutputFormats.Get "rss") }} {{- end }} {{- with $rss }} @@ -46,9 +46,16 @@ {{- range .Pages }} {{- if eq .Kind "page" }}
    -

    +

    {{- .Title | markdownify }} - {{- if .Draft }}  [draft]{{- end }} + {{- if .Draft }} + + + + + + {{- end }}

    {{- partial "post_meta.html" . -}} diff --git a/layouts/_default/list.html b/layouts/_default/list.html index 2640f164..81aea6e4 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -67,9 +67,16 @@ {{- $isHidden := (.Param "cover.hiddenInList") | default (.Param "cover.hidden") | default false }} {{- partial "cover.html" (dict "cxt" . "IsSingle" false "isHidden" $isHidden) }}
    -

    +

    {{- .Title }} - {{- if .Draft }}  [draft]{{- end }} + {{- if .Draft }} + + + + + + {{- end }}

    {{- if (ne (.Param "hideSummary") true) }} diff --git a/layouts/_default/single.html b/layouts/_default/single.html index 837f6197..19a624f4 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -3,9 +3,16 @@
    {{ partial "breadcrumbs.html" . }} -

    +

    {{ .Title }} - {{- if .Draft }}  [draft]{{- end }} + {{- if .Draft }} + + + + + + {{- end }}

    {{- if .Description }}
    From 86362ebd72776c78c1c30e660ceb903d235f493d Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 16 Dec 2023 19:28:05 +0530 Subject: [PATCH 235/254] Update README.md --- README.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 7a80ccab..14b0bf91 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@

    ☄️ Fast | ☁️ Fluent | 🌙 Smooth | 📱 Responsive


    -> Hugo PaperMod is a theme based on [hugo-paper](https://github.com/nanxiaobei/hugo-paper/tree/4330c8b12aa48bfdecbcad6ad66145f679a430b3). +> Hugo PaperMod is a theme based on [hugo-paper](https://github.com/nanxiaobei/hugo-paper/tree/4330c8b12aa48bfdecbcad6ad66145f679a430b3).
    > The goal of this project is to add more features and customization to the og theme. **Documentation** can be found here: [**📚 Wiki**](https://github.com/adityatelange/hugo-PaperMod/wiki) @@ -11,10 +11,12 @@ **ExampleSite** can be found here: [**exampleSite**](https://github.com/adityatelange/hugo-PaperMod/tree/exampleSite). Demo is built up with [exampleSite](https://github.com/adityatelange/hugo-PaperMod/tree/exampleSite) as source. [![hugo-papermod](https://img.shields.io/badge/Hugo--Themes-@PaperMod-blue)](https://themes.gohugo.io/themes/hugo-papermod/) -[![Minimum Hugo Version](https://img.shields.io/static/v1?label=HUGO-version&message=>0.97.1&color=blue&logo=hugo)](https://github.com/gohugoio/hugo/releases/tag/v0.97.1) +[![Minimum Hugo Version](https://img.shields.io/static/v1?label=min-HUGO-version&message=>=0.97.1&color=blue&logo=hugo)](https://github.com/gohugoio/hugo/releases/tag/v0.97.1) [![Discord](https://img.shields.io/discord/971046860317921340?label=Discord&logo=discord)](https://discord.gg/ahpmTvhVmp) [![GitHub](https://img.shields.io/github/license/adityatelange/hugo-PaperMod)](https://github.com/adityatelange/hugo-PaperMod/blob/master/LICENSE) ![code-size](https://img.shields.io/github/languages/code-size/adityatelange/hugo-PaperMod) +[![X (formerly Twitter) URL](https://img.shields.io/badge/-Share%20on%20X-gray?style=flat&logo=x)](https://x.com/intent/tweet/?text=Checkout%20Hugo%20PaperMod%20%E2%9C%A8%0AA%20fast,%20clean,%20responsive%20Hugo%20theme.&url=https://github.com/adityatelange/hugo-PaperMod&hashtags=Hugo,PaperMod) + --- From 102e089bc3c1cf30a0f5b204c0182e0ce72b6880 Mon Sep 17 00:00:00 2001 From: Razon Yang Date: Sat, 4 Nov 2023 15:01:23 +0530 Subject: [PATCH 236/254] [PATCH] tpl/embedded: Make Open Graph's series optional cherry-picked from https://github.com/gohugoio/hugo/commit/b82b547acb404cdb883154cc4991137d46caa22a --- layouts/partials/templates/opengraph.html | 2 ++ 1 file changed, 2 insertions(+) diff --git a/layouts/partials/templates/opengraph.html b/layouts/partials/templates/opengraph.html index 9e8df143..631dda14 100644 --- a/layouts/partials/templates/opengraph.html +++ b/layouts/partials/templates/opengraph.html @@ -41,12 +41,14 @@ {{- /* If it is part of a series, link to related articles */}} {{- $permalink := .Permalink }} {{- $siteSeries := site.Taxonomies.series }} +{{- if $siteSeries }} {{ with .Params.series }}{{- range $name := . }} {{- $series := index $siteSeries ($name | urlize) }} {{- range $page := first 6 $series.Pages }} {{- if ne $page.Permalink $permalink }}{{ end }} {{- end }} {{ end }}{{ end }} +{{- end }} {{- /* Facebook Page Admin ID for Domain Insights */}} {{- with site.Social.facebook_admin }}{{ end }} From 3fb112bc851ae88d7457300a262c7a30a7522454 Mon Sep 17 00:00:00 2001 From: Joe Mooring Date: Sat, 4 Nov 2023 15:05:42 +0530 Subject: [PATCH 237/254] [PATCH] tpl/tplimpl: Deprecate .Site.Social usage with internal templates cherry-picked from https://github.com/gohugoio/hugo/commit/4910312ee75a1c67fad68c259ad9576dca854c62 --- layouts/partials/templates/opengraph.html | 13 ++++++++++++- layouts/partials/templates/twitter_cards.html | 15 +++++++++++++-- 2 files changed, 25 insertions(+), 3 deletions(-) diff --git a/layouts/partials/templates/opengraph.html b/layouts/partials/templates/opengraph.html index 631dda14..b7fe84c7 100644 --- a/layouts/partials/templates/opengraph.html +++ b/layouts/partials/templates/opengraph.html @@ -50,5 +50,16 @@ {{ end }}{{ end }} {{- end }} +{{- /* Deprecate site.Social.facebook_admin in favor of site.Params.social.facebook_admin */}} +{{- $facebookAdmin := "" }} +{{- with site.Params.social.facebook_admin }} + {{- $facebookAdmin = . }} +{{- else }} + {{- with site.Social.facebook_admin }} + {{- $facebookAdmin = . }} + {{- warnf "The social key in site configuration is deprecated. Use params.social.facebook_admin instead." }} + {{- end }} +{{- end }} + {{- /* Facebook Page Admin ID for Domain Insights */}} -{{- with site.Social.facebook_admin }}{{ end }} +{{ with $facebookAdmin }}{{ end }} diff --git a/layouts/partials/templates/twitter_cards.html b/layouts/partials/templates/twitter_cards.html index bd46e376..bdb59239 100644 --- a/layouts/partials/templates/twitter_cards.html +++ b/layouts/partials/templates/twitter_cards.html @@ -28,6 +28,17 @@ {{- end }} -{{ with site.Social.twitter -}} +{{- /* Deprecate site.Social.twitter in favor of site.Params.social.twitter */}} +{{- $twitterSite := "" }} +{{- with site.Params.social.twitter }} + {{- $twitterSite = . }} +{{- else }} + {{- with site.Social.twitter }} + {{- $twitterSite = . }} + {{- warnf "The social key in site configuration is deprecated. Use params.social.twitter instead." }} + {{- end }} +{{- end }} + +{{- with $twitterSite }} -{{ end -}} +{{- end }} From 87df659c185b91ab09f8eb978b3aab5945b0f8b5 Mon Sep 17 00:00:00 2001 From: Joe Mooring Date: Sat, 4 Nov 2023 15:08:01 +0530 Subject: [PATCH 238/254] [PATCH] tpl/tplimpl: Fix deprecation logic in embedded templates cherry-picked from https://github.com/gohugoio/hugo/commit/cb98e9061b3d62b6f1e635a6cf9a8be57dc3f56c --- layouts/partials/templates/opengraph.html | 6 ++++-- layouts/partials/templates/twitter_cards.html | 12 +++++++++--- 2 files changed, 13 insertions(+), 5 deletions(-) diff --git a/layouts/partials/templates/opengraph.html b/layouts/partials/templates/opengraph.html index b7fe84c7..38fbd246 100644 --- a/layouts/partials/templates/opengraph.html +++ b/layouts/partials/templates/opengraph.html @@ -52,8 +52,10 @@ {{- /* Deprecate site.Social.facebook_admin in favor of site.Params.social.facebook_admin */}} {{- $facebookAdmin := "" }} -{{- with site.Params.social.facebook_admin }} - {{- $facebookAdmin = . }} +{{- with site.Params.social }} + {{- if reflect.IsMap . }} + {{- $facebookAdmin = .facebook_admin }} + {{- end }} {{- else }} {{- with site.Social.facebook_admin }} {{- $facebookAdmin = . }} diff --git a/layouts/partials/templates/twitter_cards.html b/layouts/partials/templates/twitter_cards.html index bdb59239..0e7760aa 100644 --- a/layouts/partials/templates/twitter_cards.html +++ b/layouts/partials/templates/twitter_cards.html @@ -30,8 +30,10 @@ {{- /* Deprecate site.Social.twitter in favor of site.Params.social.twitter */}} {{- $twitterSite := "" }} -{{- with site.Params.social.twitter }} - {{- $twitterSite = . }} +{{- with site.Params.social }} + {{- if reflect.IsMap . }} + {{- $twitterSite = .twitter }} + {{- end }} {{- else }} {{- with site.Social.twitter }} {{- $twitterSite = . }} @@ -40,5 +42,9 @@ {{- end }} {{- with $twitterSite }} - + {{- $content := . }} + {{- if not (strings.HasPrefix . "@") }} + {{- $content = printf "@%v" $twitterSite }} + {{- end }} + {{- end }} From cf62fa3c40ea9a2527b5081db699e28c0e391985 Mon Sep 17 00:00:00 2001 From: Joe Mooring Date: Sat, 4 Nov 2023 15:19:28 +0530 Subject: [PATCH 239/254] [PATCH] tpl/tplimpl: Use .Language.LanguageCode in built-in templates cherry-pick from https://github.com/gohugoio/hugo/commit/ff77a927f9c032f5a65eff2daf1f7f8c04103711 --- layouts/_default/rss.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/layouts/_default/rss.xml b/layouts/_default/rss.xml index 44f14986..db57edac 100644 --- a/layouts/_default/rss.xml +++ b/layouts/_default/rss.xml @@ -23,8 +23,8 @@ {{ index . 0 | absURL }} {{- end }} - Hugo -- gohugo.io{{ with site.LanguageCode }} - {{.}}{{end}}{{ with site.Author.email }} + Hugo -- gohugo.io + {{ site.Language.LanguageCode }}{{ with site.Author.email }} {{.}}{{ with site.Author.name }} ({{.}}){{end}}{{end}}{{ with site.Author.email }} {{.}}{{ with site.Author.name }} ({{.}}){{end}}{{end}}{{ with site.Copyright }} {{.}}{{end}}{{ if not .Date.IsZero }} From 00488d01463fc8c8db9fbda3f6060a0b5b373464 Mon Sep 17 00:00:00 2001 From: Joe Mooring Date: Sat, 4 Nov 2023 15:23:31 +0530 Subject: [PATCH 240/254] [PATCH] tpl/tplimpl: Deprecate .Site.Author usage in RSS template cherry-pick from https://github.com/gohugoio/hugo/commit/d4016dd5cd57a27f19a5472c6031d156066860b7 --- layouts/_default/rss.xml | 68 ++++++++++++++++++++++++++-------------- 1 file changed, 45 insertions(+), 23 deletions(-) diff --git a/layouts/_default/rss.xml b/layouts/_default/rss.xml index db57edac..22b2e6ed 100644 --- a/layouts/_default/rss.xml +++ b/layouts/_default/rss.xml @@ -1,21 +1,43 @@ -{{- $pctx := . -}} -{{- if .IsHome -}}{{ $pctx = site }}{{- end -}} -{{- $pages := slice -}} -{{- if or $.IsHome $.IsSection -}} -{{- $pages = $pctx.RegularPages -}} -{{- else -}} -{{- $pages = $pctx.Pages -}} -{{- end -}} -{{- $limit := site.Config.Services.RSS.Limit -}} -{{- if ge $limit 1 -}} -{{- $pages = $pages | first $limit -}} -{{- end -}} +{{- /* Deprecate site.Author.email in favor of site.Params.author.email */}} +{{- $authorEmail := "" }} +{{- with site.Params.author.email }} + {{- $authorEmail = . }} +{{- else }} + {{- with site.Author.email }} + {{- $authorEmail = . }} + {{- warnf "The author key in site configuration is deprecated. Use params.author.email instead." }} + {{- end }} +{{- end }} + +{{- /* Deprecate site.Author.name in favor of site.Params.author.name */}} +{{- $authorName := "" }} +{{- with site.Params.author.name }} + {{- $authorName = . }} +{{- else }} + {{- with site.Author.name }} + {{- $authorName = . }} + {{- warnf "The author key in site configuration is deprecated. Use params.author.name instead." }} + {{- end }} +{{- end }} + +{{- $pctx := . }} +{{- if .IsHome }}{{ $pctx = .Site }}{{ end }} +{{- $pages := slice }} +{{- if or $.IsHome $.IsSection }} +{{- $pages = $pctx.RegularPages }} +{{- else }} +{{- $pages = $pctx.Pages }} +{{- end }} +{{- $limit := .Site.Config.Services.RSS.Limit }} +{{- if ge $limit 1 }} +{{- $pages = $pages | first $limit }} +{{- end }} {{- printf "" | safeHTML }} - + - {{ if eq .Title site.Title }}{{ site.Title }}{{ else }}{{ with .Title }}{{.}} on {{ end }}{{ site.Title }}{{ end }} + {{ if eq .Title .Site.Title }}{{ .Site.Title }}{{ else }}{{ with .Title }}{{ . }} on {{ end }}{{ .Site.Title }}{{ end }} {{ .Permalink }} - Recent content {{ if ne .Title site.Title }}{{ with .Title }}in {{.}} {{ end }}{{ end }}on {{ site.Title }} + Recent content {{ if ne .Title .Site.Title }}{{ with .Title }}in {{ . }} {{ end }}{{ end }}on {{ .Site.Title }} {{- with site.Params.images }} {{ site.Title }} @@ -24,21 +46,21 @@ {{- end }} Hugo -- gohugo.io - {{ site.Language.LanguageCode }}{{ with site.Author.email }} - {{.}}{{ with site.Author.name }} ({{.}}){{end}}{{end}}{{ with site.Author.email }} - {{.}}{{ with site.Author.name }} ({{.}}){{end}}{{end}}{{ with site.Copyright }} - {{.}}{{end}}{{ if not .Date.IsZero }} + {{ site.Language.LanguageCode }}{{ with $authorEmail }} + {{.}}{{ with $authorName }} ({{ . }}){{ end }}{{ end }}{{ with $authorEmail }} + {{ . }}{{ with $authorName }} ({{ . }}){{ end }}{{ end }}{{ with .Site.Copyright }} + {{ . }}{{ end }}{{ if not .Date.IsZero }} {{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}{{ end }} - {{- with .OutputFormats.Get "RSS" -}} + {{- with .OutputFormats.Get "RSS" }} {{ printf "" .Permalink .MediaType | safeHTML }} - {{- end -}} - {{ range $pages }} + {{- end }} + {{- range $pages }} {{- if and (ne .Layout `search`) (ne .Layout `archives`) }} {{ .Title }} {{ .Permalink }} {{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }} - {{ with site.Author.email }}{{.}}{{ with site.Author.name }} ({{.}}){{end}}{{end}} + {{- with $authorEmail }}{{ . }}{{ with $authorName }} ({{ . }}){{ end }}{{ end }} {{ .Permalink }} {{ with .Description | html }}{{ . }}{{ else }}{{ .Summary | html }}{{ end -}} {{- if site.Params.ShowFullTextinRSS }} From ff7443b17f597e2307a590c805e39df1d935ebc6 Mon Sep 17 00:00:00 2001 From: Joe Mooring Date: Sat, 4 Nov 2023 15:34:56 +0530 Subject: [PATCH 241/254] [PATCH] tpl/tplimpl: Fix deprecation logic in RSS template cherry-pick from https://github.com/gohugoio/hugo/commit/23fcfb7f741a417f53a8ef4997bb68e64631df01 --- layouts/_default/rss.xml | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) diff --git a/layouts/_default/rss.xml b/layouts/_default/rss.xml index 22b2e6ed..3b28fbf6 100644 --- a/layouts/_default/rss.xml +++ b/layouts/_default/rss.xml @@ -1,7 +1,11 @@ {{- /* Deprecate site.Author.email in favor of site.Params.author.email */}} {{- $authorEmail := "" }} -{{- with site.Params.author.email }} - {{- $authorEmail = . }} +{{- with site.Params.author }} + {{- if reflect.IsMap . }} + {{- with .email }} + {{- $authorEmail = . }} + {{- end }} + {{- end }} {{- else }} {{- with site.Author.email }} {{- $authorEmail = . }} @@ -11,8 +15,14 @@ {{- /* Deprecate site.Author.name in favor of site.Params.author.name */}} {{- $authorName := "" }} -{{- with site.Params.author.name }} - {{- $authorName = . }} +{{- with site.Params.author }} + {{- if reflect.IsMap . }} + {{- with .name }} + {{- $authorName = . }} + {{- end }} + {{- else }} + {{- $authorName = . }} + {{- end }} {{- else }} {{- with site.Author.name }} {{- $authorName = . }} From f51ad4981904a9cb0ad9729b6d204532fef4371d Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 4 Nov 2023 15:36:08 +0530 Subject: [PATCH 242/254] replace .Site with site & fix whitespace --- layouts/_default/rss.xml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/layouts/_default/rss.xml b/layouts/_default/rss.xml index 3b28fbf6..b6a7ec06 100644 --- a/layouts/_default/rss.xml +++ b/layouts/_default/rss.xml @@ -31,23 +31,23 @@ {{- end }} {{- $pctx := . }} -{{- if .IsHome }}{{ $pctx = .Site }}{{ end }} +{{- if .IsHome }}{{ $pctx = site }}{{ end }} {{- $pages := slice }} {{- if or $.IsHome $.IsSection }} {{- $pages = $pctx.RegularPages }} {{- else }} {{- $pages = $pctx.Pages }} {{- end }} -{{- $limit := .Site.Config.Services.RSS.Limit }} +{{- $limit := site.Config.Services.RSS.Limit }} {{- if ge $limit 1 }} {{- $pages = $pages | first $limit }} {{- end }} {{- printf "" | safeHTML }} - {{ if eq .Title .Site.Title }}{{ .Site.Title }}{{ else }}{{ with .Title }}{{ . }} on {{ end }}{{ .Site.Title }}{{ end }} + {{ if eq .Title site.Title }}{{ site.Title }}{{ else }}{{ with .Title }}{{ . }} on {{ end }}{{ site.Title }}{{ end }} {{ .Permalink }} - Recent content {{ if ne .Title .Site.Title }}{{ with .Title }}in {{ . }} {{ end }}{{ end }}on {{ .Site.Title }} + Recent content {{ if ne .Title site.Title }}{{ with .Title }}in {{ . }} {{ end }}{{ end }}on {{ site.Title }} {{- with site.Params.images }} {{ site.Title }} @@ -58,7 +58,7 @@ Hugo -- gohugo.io {{ site.Language.LanguageCode }}{{ with $authorEmail }} {{.}}{{ with $authorName }} ({{ . }}){{ end }}{{ end }}{{ with $authorEmail }} - {{ . }}{{ with $authorName }} ({{ . }}){{ end }}{{ end }}{{ with .Site.Copyright }} + {{ . }}{{ with $authorName }} ({{ . }}){{ end }}{{ end }}{{ with site.Copyright }} {{ . }}{{ end }}{{ if not .Date.IsZero }} {{ .Date.Format "Mon, 02 Jan 2006 15:04:05 -0700" | safeHTML }}{{ end }} {{- with .OutputFormats.Get "RSS" }} @@ -78,6 +78,6 @@ {{- end }} {{- end }} - {{ end }} + {{- end }} From e3ad0aeb705409639a4a4d860075a2924e00eb23 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 16 Dec 2023 19:59:55 +0530 Subject: [PATCH 243/254] Bump minimum Hugo version to 0.112.4 * language.LanguageCode is required for Fix/hugo depr 0.120.x #1328 --- .github/ISSUE_TEMPLATE/bug_report.md | 2 +- .github/workflows/gh-pages.yml | 4 ++-- README.md | 2 +- layouts/_default/baseof.html | 4 ++-- theme.toml | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index b7d5b289..d88b750f 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -26,7 +26,7 @@ Please fill the template below - Device/Os: [e.g. Android 10] - Type: [e.g. Desktop/Mobile] - Browser and version [e.g. Chrome 86.0]: - - Hugo Version [ >=0.97.1 expected]: + - Hugo Version [ >=0.112.4 expected]: - Theme Version [e.g. v4.0, master, or commit-id ]: **Steps to reproduce the behavior:** diff --git a/.github/workflows/gh-pages.yml b/.github/workflows/gh-pages.yml index c7b8351a..f4acb7e0 100644 --- a/.github/workflows/gh-pages.yml +++ b/.github/workflows/gh-pages.yml @@ -15,7 +15,7 @@ on: hugoVersion: description: "Hugo Version" required: false - default: "0.97.1" + default: "0.112.4" # Allow one concurrent deployment concurrency: @@ -38,7 +38,7 @@ jobs: build: runs-on: ubuntu-latest env: - HUGO_VERSION: "0.97.1" + HUGO_VERSION: "0.112.4" steps: - name: Check version if: ${{ github.event.inputs.hugoVersion }} diff --git a/README.md b/README.md index 14b0bf91..12bd8cb6 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,7 @@ **ExampleSite** can be found here: [**exampleSite**](https://github.com/adityatelange/hugo-PaperMod/tree/exampleSite). Demo is built up with [exampleSite](https://github.com/adityatelange/hugo-PaperMod/tree/exampleSite) as source. [![hugo-papermod](https://img.shields.io/badge/Hugo--Themes-@PaperMod-blue)](https://themes.gohugo.io/themes/hugo-papermod/) -[![Minimum Hugo Version](https://img.shields.io/static/v1?label=min-HUGO-version&message=>=0.97.1&color=blue&logo=hugo)](https://github.com/gohugoio/hugo/releases/tag/v0.97.1) +[![Minimum Hugo Version](https://img.shields.io/static/v1?label=min-HUGO-version&message=>=v0.112.4&color=blue&logo=hugo)](https://github.com/gohugoio/hugo/releases/tag/v0.112.4) [![Discord](https://img.shields.io/discord/971046860317921340?label=Discord&logo=discord)](https://discord.gg/ahpmTvhVmp) [![GitHub](https://img.shields.io/github/license/adityatelange/hugo-PaperMod)](https://github.com/adityatelange/hugo-PaperMod/blob/master/LICENSE) ![code-size](https://img.shields.io/github/languages/code-size/adityatelange/hugo-PaperMod) diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index d2de5eec..df611bfb 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -1,5 +1,5 @@ -{{- if lt hugo.Version "0.97.1" }} -{{- errorf "=> hugo v0.97.1 or greater is required for hugo-PaperMod to build " }} +{{- if lt hugo.Version "0.112.4" }} +{{- errorf "=> hugo v0.112.4 or greater is required for hugo-PaperMod to build " }} {{- end -}} diff --git a/theme.toml b/theme.toml index aa26fe06..f659f5c9 100644 --- a/theme.toml +++ b/theme.toml @@ -37,7 +37,7 @@ features = [ "scroll-to-top", "search" ] -min_version = "0.97.1" +min_version = "0.112.4" [author] name = "Aditya Telange" From 5f624757ae894d46c2e96e6ba6c0720a4ec7771a Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 16 Dec 2023 20:07:15 +0530 Subject: [PATCH 244/254] Workflows: Update release bin path for hugo linux-amd64.deb --- .github/workflows/gh-pages.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/gh-pages.yml b/.github/workflows/gh-pages.yml index f4acb7e0..4d35f1de 100644 --- a/.github/workflows/gh-pages.yml +++ b/.github/workflows/gh-pages.yml @@ -45,7 +45,7 @@ jobs: run: export HUGO_VERSION="${{ github.event.inputs.hugoVersion }}" - name: Install Hugo CLI run: | - wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_${HUGO_VERSION}_Linux-64bit.deb \ + wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_${HUGO_VERSION}_linux-amd64.deb \ && sudo dpkg -i ${{ runner.temp }}/hugo.deb - name: Checkout uses: actions/checkout@v3 From f8e125c7eef82323b11fc2dfc67110dfc7454dd8 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 16 Dec 2023 20:59:08 +0530 Subject: [PATCH 245/254] Add padding to social-icons for better tap sizing --- assets/css/common/main.css | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/assets/css/common/main.css b/assets/css/common/main.css index 50022ac1..25ae4dae 100644 --- a/assets/css/common/main.css +++ b/assets/css/common/main.css @@ -27,12 +27,10 @@ margin-inline-start: auto; } -.social-icons { - padding: 12px 0; -} -.social-icons a:not(:last-of-type) { - margin-inline-end: 12px; +.social-icons a { + display: inline-flex; + padding: 10px; } .social-icons a svg { From 69e5e085ab0b8d0cae03d9c189c4b262890646ac Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 16 Dec 2023 20:59:36 +0530 Subject: [PATCH 246/254] improved profile mode spacing --- assets/css/common/profile-mode.css | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/assets/css/common/profile-mode.css b/assets/css/common/profile-mode.css index 58f28198..9e98df55 100644 --- a/assets/css/common/profile-mode.css +++ b/assets/css/common/profile-mode.css @@ -10,19 +10,20 @@ text-align: center; } -.profile .profile_inner h1 { - padding: 12px 0; +.profile .profile_inner { + display: flex; + flex-direction: column; + align-items: center; + gap: 10px; } .profile img { - display: inline-table; border-radius: 50%; } .buttons { flex-wrap: wrap; max-width: 400px; - margin: 0 auto; } .button { From fb1c0aeb6fd5b1b1cfc17a977754cc6d0f03b486 Mon Sep 17 00:00:00 2001 From: Aditya Telange <21258296+adityatelange@users.noreply.github.com> Date: Sat, 16 Dec 2023 21:38:24 +0530 Subject: [PATCH 247/254] social icons refactor Params.socialIcons --- layouts/partials/home_info.html | 2 +- layouts/partials/index_profile.html | 2 +- layouts/partials/social_icons.html | 5 +++-- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/layouts/partials/home_info.html b/layouts/partials/home_info.html index efae956e..aece5327 100644 --- a/layouts/partials/home_info.html +++ b/layouts/partials/home_info.html @@ -7,7 +7,7 @@ {{ .Content | markdownify }}
    - {{ partial "social_icons.html" site.Params.socialIcons }} + {{ partial "social_icons.html" }}
    {{- end -}} diff --git a/layouts/partials/index_profile.html b/layouts/partials/index_profile.html index d9ddbda5..6882f39b 100644 --- a/layouts/partials/index_profile.html +++ b/layouts/partials/index_profile.html @@ -32,7 +32,7 @@ {{- end }}

    {{ .title | default site.Title | markdownify }}

    {{ .subtitle | markdownify }} - {{- partial "social_icons.html" site.Params.socialIcons -}} + {{- partial "social_icons.html" -}} {{- with .buttons }}
    diff --git a/layouts/partials/social_icons.html b/layouts/partials/social_icons.html index 876b77c6..761129eb 100644 --- a/layouts/partials/social_icons.html +++ b/layouts/partials/social_icons.html @@ -1,6 +1,7 @@
    - {{ partial "social_icons.html" }} + {{ partial "social_icons.html" (dict "align" site.Params.homeInfoParams.AlignSocialIconsTo) }}
    {{- end -}} diff --git a/layouts/partials/social_icons.html b/layouts/partials/social_icons.html index 761129eb..ce76a308 100644 --- a/layouts/partials/social_icons.html +++ b/layouts/partials/social_icons.html @@ -1,4 +1,4 @@ -