Merge eeac3af99b
into 01f9e43e59
This commit is contained in:
commit
f33ff33f11
|
@ -1,6 +0,0 @@
|
|||
/*!
|
||||
* enquire.js v2.1.6 - Awesome Media Queries in JavaScript
|
||||
* Copyright (c) 2017 Nick Williams - http://wicky.nillia.ms/enquire.js
|
||||
* License: MIT */
|
||||
|
||||
!function(a){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=a();else if("function"==typeof define&&define.amd)define([],a);else{var b;b="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this,b.enquire=a()}}(function(){return function a(b,c,d){function e(g,h){if(!c[g]){if(!b[g]){var i="function"==typeof require&&require;if(!h&&i)return i(g,!0);if(f)return f(g,!0);var j=new Error("Cannot find module '"+g+"'");throw j.code="MODULE_NOT_FOUND",j}var k=c[g]={exports:{}};b[g][0].call(k.exports,function(a){var c=b[g][1][a];return e(c?c:a)},k,k.exports,a,b,c,d)}return c[g].exports}for(var f="function"==typeof require&&require,g=0;g<d.length;g++)e(d[g]);return e}({1:[function(a,b,c){function d(a,b){this.query=a,this.isUnconditional=b,this.handlers=[],this.mql=window.matchMedia(a);var c=this;this.listener=function(a){c.mql=a.currentTarget||a,c.assess()},this.mql.addListener(this.listener)}var e=a(3),f=a(4).each;d.prototype={constuctor:d,addHandler:function(a){var b=new e(a);this.handlers.push(b),this.matches()&&b.on()},removeHandler:function(a){var b=this.handlers;f(b,function(c,d){if(c.equals(a))return c.destroy(),!b.splice(d,1)})},matches:function(){return this.mql.matches||this.isUnconditional},clear:function(){f(this.handlers,function(a){a.destroy()}),this.mql.removeListener(this.listener),this.handlers.length=0},assess:function(){var a=this.matches()?"on":"off";f(this.handlers,function(b){b[a]()})}},b.exports=d},{3:3,4:4}],2:[function(a,b,c){function d(){if(!window.matchMedia)throw new Error("matchMedia not present, legacy browsers require a polyfill");this.queries={},this.browserIsIncapable=!window.matchMedia("only all").matches}var e=a(1),f=a(4),g=f.each,h=f.isFunction,i=f.isArray;d.prototype={constructor:d,register:function(a,b,c){var d=this.queries,f=c&&this.browserIsIncapable;return d[a]||(d[a]=new e(a,f)),h(b)&&(b={match:b}),i(b)||(b=[b]),g(b,function(b){h(b)&&(b={match:b}),d[a].addHandler(b)}),this},unregister:function(a,b){var c=this.queries[a];return c&&(b?c.removeHandler(b):(c.clear(),delete this.queries[a])),this}},b.exports=d},{1:1,4:4}],3:[function(a,b,c){function d(a){this.options=a,!a.deferSetup&&this.setup()}d.prototype={constructor:d,setup:function(){this.options.setup&&this.options.setup(),this.initialised=!0},on:function(){!this.initialised&&this.setup(),this.options.match&&this.options.match()},off:function(){this.options.unmatch&&this.options.unmatch()},destroy:function(){this.options.destroy?this.options.destroy():this.off()},equals:function(a){return this.options===a||this.options.match===a}},b.exports=d},{}],4:[function(a,b,c){function d(a,b){var c=0,d=a.length;for(c;c<d&&b(a[c],c)!==!1;c++);}function e(a){return"[object Array]"===Object.prototype.toString.apply(a)}function f(a){return"function"==typeof a}b.exports={isFunction:f,isArray:e,each:d}},{}],5:[function(a,b,c){var d=a(2);b.exports=new d},{2:2}]},{},[5])(5)});
|
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -199,7 +199,7 @@ commento = false
|
|||
paypal = ""
|
||||
patreon = ""
|
||||
|
||||
# possible share name: ["facebook","twitter", "reddit", "linkedin", "tumblr", "weibo", "douban", "line", "pocket", "feedly", "hatena", "pinterest", "delicious", "google"]
|
||||
# possible share name: ["facebook", "twitter", "reddit", "linkedin", "tumblr", "weibo", "douban", "line", "telegram", "whatsapp", "pocket", "feedly", "hatena", "pinterest"]
|
||||
[[share]]
|
||||
name = "facebook"
|
||||
username = ""
|
||||
|
|
|
@ -2,7 +2,9 @@
|
|||
|
||||
<main class="main inner" data-sidebar-position="{{ $.Param "sidebarPosition" }}">
|
||||
<div class="list__main {{ if $.Param "enableSidebar" }}{{ if eq ($.Param "sidebarPosition") "left" }}mr{{ else }}lm{{ end }}{{ else }}lmr{{ end }}">
|
||||
{{ if $.Param "enableBreadcrumb" }}
|
||||
{{ partial "body/breadcrumb" . }}
|
||||
{{ end }}
|
||||
<header class="list__header">
|
||||
<h5 class="list__header--title capitalize h5">{{.Title}}</h5>
|
||||
</header>
|
||||
|
|
|
@ -2,7 +2,9 @@
|
|||
|
||||
<main class="main inner" data-sidebar-position="{{ $.Param "sidebarPosition" }}">
|
||||
<div class="list__main {{ if $.Param "enableSidebar" }}{{ if eq ($.Param "sidebarPosition") "left" }}mr{{ else }}lm{{ end }}{{ else }}lmr{{ end }}">
|
||||
{{ if $.Param "enableBreadcrumb" }}
|
||||
{{ partial "body/breadcrumb" . }}
|
||||
{{ end }}
|
||||
<header class="list__header">
|
||||
<h5 class="list__header--title capitalize h5">{{ .Title }}</h5>
|
||||
</header>
|
||||
|
|
|
@ -40,37 +40,29 @@
|
|||
{{ partial "svgs/share/line.svg" (dict "width" 35 "height" 35) }}
|
||||
</a>
|
||||
{{ else if eq (lower .name) "telegram" }}
|
||||
<a href='https://telegram.me/share/url?url=' onclick='window.open('https://telegram.me/share/url?url='+encodeURIComponent(location.href)+'&bodytext=&tags=&text='+encodeURIComponent(document.title));return false;' class="donation__item" target="_blank" rel="noreferrer" title="{{ i18n "line" | default "Telegram" }}" aria-label="Telegram Share Button" data-type="share">
|
||||
<a href='https://telegram.me/share/url?url=' onclick='window.open('https://telegram.me/share/url?url='+encodeURIComponent(location.href)+'&bodytext=&tags=&text='+encodeURIComponent(document.title));return false;' class="donation__item" target="_blank" rel="noreferrer" title="{{ i18n "telegram" | default "Telegram" }}" aria-label="Telegram Share Button" data-type="share">
|
||||
{{ partial "svgs/social/telegram.svg" (dict "width" 35 "height" 35) }}
|
||||
</a>
|
||||
{{ else if eq (lower .name) "whatsapp" }}
|
||||
<a href="https://web.whatsapp.com/send?text={{ $ctx.Title }} - {{ $ctx.Permalink | absLangURL }}" data-href="{{ $ctx.Permalink | absLangURL }}" class="donation__item" target="_blank" rel="noreferrer" title="{{ i18n "line" | default "WhatsApp" }}" aria-label="WhatsApp Share Button" data-type="share">
|
||||
<a href="https://web.whatsapp.com/send?text={{ $ctx.Title }} - {{ $ctx.Permalink | absLangURL }}" data-href="{{ $ctx.Permalink | absLangURL }}" class="donation__item" target="_blank" rel="noreferrer" title="{{ i18n "whatsapp" | default "WhatsApp" }}" aria-label="WhatsApp Share Button" data-type="share">
|
||||
{{ partial "svgs/social/whatsapp.svg" (dict "width" 35 "height" 35) }}
|
||||
</a>
|
||||
{{ else if eq (lower .name) "pocket" }}
|
||||
<a href="https://getpocket.com/save?url={{ $ctx.Permalink | absLangURL }}" class="donation__item" target="_blank" rel="noreferrer" title="{{ i18n "line" | default "Pocket" }}" aria-label="Pocket Share Button" data-type="share">
|
||||
<a href="https://getpocket.com/save?url={{ $ctx.Permalink | absLangURL }}" class="donation__item" target="_blank" rel="noreferrer" title="{{ i18n "pocket" | default "Pocket" }}" aria-label="Pocket Share Button" data-type="share">
|
||||
{{ partial "svgs/share/pocket.svg" (dict "width" 35 "height" 35) }}
|
||||
</a>
|
||||
{{ else if eq (lower .name) "feedly" }}
|
||||
<a href="https://feedly.com/i/subscription/feed/{{ .Permalink | absLangURL }}index.xml" class="donation__item" target="_blank" rel="noreferrer" title="{{ i18n "line" | default "Feedly" }}" aria-label="Feedly Share Button" data-type="share">
|
||||
<a href="https://feedly.com/i/subscription/feed/{{ .Permalink | absLangURL }}index.xml" class="donation__item" target="_blank" rel="noreferrer" title="{{ i18n "feedly" | default "Feedly" }}" aria-label="Feedly Share Button" data-type="share">
|
||||
{{ partial "svgs/share/feedly.svg" (dict "width" 35 "height" 35) }}
|
||||
</a>
|
||||
{{ else if eq (lower .name) "hatena" }}
|
||||
<a href="https://b.hatena.ne.jp/entry/panel/?btitle={{ $ctx.Title }}&url={{ $ctx.Permalink | absLangURL }}" title="{{ i18n "Hatena Blog" | default "Hatena Blog" }}" aria-label="Hatena Blog Share Button" class="donation__item" target="_blank" rel="noreferrer" data-type="share">
|
||||
<a href="https://b.hatena.ne.jp/entry/panel/?btitle={{ $ctx.Title }}&url={{ $ctx.Permalink | absLangURL }}" title="{{ i18n "hatena" | default "Hatena Blog" }}" aria-label="Hatena Blog Share Button" class="donation__item" target="_blank" rel="noreferrer" data-type="share">
|
||||
{{ partial "svgs/share/hatena.svg" (dict "width" 35 "height" 35) }}
|
||||
</a>
|
||||
{{ else if eq (lower .name) "pinterest" }}
|
||||
<a href="http://www.pinterest.com/pin/create/button/?url={{ $ctx.Permalink | absLangURL }}{{ if $.Param "featured_image" }}&media={{ (print "images/" ($.Param "featured_image")) | absURL }}{{ else if $.Param "image" }}&media={{ $.Param "image" | absURL }}{{end}}&description={{ $ctx.Description }}" title="{{ i18n "Pinterest" | default "Pinterest" }}" aria-label="Pinterest Share Button" class="donation__item" target="_blank" rel="noreferrer" data-type="share">
|
||||
<a href="http://www.pinterest.com/pin/create/button/?url={{ $ctx.Permalink | absLangURL }}{{ if $.Param "featured_image" }}&media={{ (print "images/" ($.Param "featured_image")) | absURL }}{{ else if $.Param "image" }}&media={{ $.Param "image" | absURL }}{{end}}&description={{ $ctx.Description }}" title="{{ i18n "pinterest" | default "Pinterest" }}" aria-label="Pinterest Share Button" class="donation__item" target="_blank" rel="noreferrer" data-type="share">
|
||||
{{ partial "svgs/share/pinterest.svg" (dict "width" 35 "height" 35) }}
|
||||
</a>
|
||||
{{ else if eq (lower .name) "delicious" }}
|
||||
<a href="http://www.delicious.com/save?url={{ $ctx.Permalink | absLangURL }}&title={{ $ctx.Title }}" title="{{ i18n "Delicious" | default "Delicious" }}" aria-label="Delicious Share Button" class="donation__item" target="_blank" rel="noreferrer" data-type="share">
|
||||
{{ partial "svgs/share/delicious.svg" (dict "width" 35 "height" 35) }}
|
||||
</a>
|
||||
{{ else if eq (lower .name) "google" }}
|
||||
<a href="https://www.google.com/bookmarks/mark?op=add&bkmk={{ $ctx.Permalink | absLangURL }}&title={{ $ctx.Title }}" title="{{ i18n "Google Bookmark" | default "Google Bookmark" }}" aria-label="Google Bookmark Share Button" class="donation__item" target="_blank" rel="noreferrer" data-type="share">
|
||||
{{ partial "svgs/share/google.svg" (dict "width" 35 "height" 35) }}
|
||||
</a>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
</div>
|
||||
|
|
|
@ -9,14 +9,11 @@
|
|||
{{ end }}
|
||||
|
||||
{{ if $.Param "enableSearch" }}
|
||||
{{ $fuse := resources.Get "js/fuse.min.js" | resources.Fingerprint }}
|
||||
<script defer src="{{ $fuse.RelPermalink }}"></script>
|
||||
<script defer src="https://cdn.jsdelivr.net/npm/fuse.js@6.4.0"></script>
|
||||
{{ end }}
|
||||
|
||||
{{ $enquire := resources.Get "js/enquire.min.js" | resources.Fingerprint }}
|
||||
<script src="{{ $enquire.RelPermalink }}"></script>
|
||||
{{ $lazysizes := resources.Get "js/lazysizes.min.js" | resources.Fingerprint }}
|
||||
<script defer src="{{ $lazysizes.RelPermalink }}"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/enquire.js@2.1.6/dist/enquire.min.js"></script>
|
||||
<script defer src="https://cdn.jsdelivr.net/npm/lazysizes@5.2.2/lazysizes.min.js"></script>
|
||||
{{ $getParents := resources.Get "js/helper/getParents.js" | resources.Minify | resources.Fingerprint }}
|
||||
<script defer src="{{ $getParents.RelPermalink }}"></script>
|
||||
{{ $fadeinout := resources.Get "js/helper/fadeinout.js" | resources.Minify | resources.Fingerprint }}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{{ if and (.Site.Params.baiduAnalytics) (not .Site.IsServer) }}
|
||||
{{ if and (.Site.Params.baiduAnalytics) (not hugo.IsServer) }}
|
||||
<script>
|
||||
{{ $baiduAnalyticsId := .Site.Params.baiduAnalytics }}
|
||||
var baiduAnalyticsId = JSON.parse({{ $baiduAnalyticsId | jsonify }});
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{{ if and (not .Site.IsServer) (not ($.Param "disableAdsense")) }}
|
||||
{{ if and (not hugo.IsServer) (not ($.Param "disableAdsense")) }}
|
||||
<script async src="//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
|
||||
<ins
|
||||
class="adsbygoogle"
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
{{ if not .Site.IsServer }}
|
||||
{{ if not hugo.IsServer }}
|
||||
{{ template "_internal/google_analytics.html" . }}
|
||||
{{ template "_internal/google_analytics_async.html" . }}
|
||||
{{ end }}
|
|
@ -1,10 +1,10 @@
|
|||
{{ if and ($.Site.Params.googleTagManager) (not .Site.IsServer) }}
|
||||
{{ if and ($.Site.Params.googleTagManager) (not hugo.IsServer) }}
|
||||
<!-- Google Tag Manager (noscript) -->
|
||||
<noscript><iframe src="https://www.googletagmanager.com/ns.html?id={{ $.Site.Params.googleTagManager }}" height="0" width="0" style="display:none;visibility:hidden"></iframe></noscript>
|
||||
<!-- End Google Tag Manager (noscript) -->
|
||||
{{ end }}
|
||||
|
||||
{{ if and ($.Site.Params.googleTagManager) (not .Site.IsServer) }}
|
||||
{{ if and ($.Site.Params.googleTagManager) (not hugo.IsServer) }}
|
||||
<!-- Google Tag Manager -->
|
||||
<!-- create dataLayer -->
|
||||
<script>
|
||||
|
|
Loading…
Reference in New Issue