jekyll-theme-mdui 0.5.1.2 → 0.5.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 70f6d34cd8819a88c071063c5800f5e10c9e17a5
4
- data.tar.gz: f0cafb4f98881adb5742526375d8df608066139c
3
+ metadata.gz: 34b945e63d0ee5772a79b48138c3983cac5639d9
4
+ data.tar.gz: e6688f4b9e3a22c3bdeab5c44e0367615ca81f27
5
5
  SHA512:
6
- metadata.gz: 8f4de2fcc7ad2f092ac44332379f247064f91a34dc04d30546c52d9bd4cc313f64258e29f39d6690b9f14c575ecd82f53780ebe6621fbb1130001ad02bff49cd
7
- data.tar.gz: d4de540a227f84142873ea734e93212ef7db71f005b909897a62478915042eeb0c2e10f3d1462119dc3cbec236fdac5d65e04e58a5673460c31362f38eb53cdb
6
+ metadata.gz: cc5058d0fcfd7abd365b6a28ab0da5ec668b9e7e0859c882009280b9e89e96c9be126dabb9d3d1dbb03f907cbda5a6dd3a3188f7cf36f1f832bd5916fb8ed2d9
7
+ data.tar.gz: e72dd0187b9672614b573e1626e6cde21ba134a0ee243edfcad93dc600a30c5e4545bec2a6557e67d0344132aaa87731d788ff752451e7b65b9a9ce421642560
data/README.md CHANGED
@@ -18,7 +18,7 @@
18
18
 
19
19
  ## General
20
20
 
21
- [![Version](https://img.shields.io/badge/version-0.5.1-green.svg?style=flat-square)]()
21
+ [![Version](https://img.shields.io/badge/version-0.5.2-green.svg?style=flat-square)]()
22
22
  [![Jekyll](https://img.shields.io/badge/Jekyll-3.5+-green.svg?style=flat-square)](https://jekyllrb.com/)
23
23
  [![Gem](https://img.shields.io/gem/dt/jekyll-theme-mdui.svg?style=flat-square)](https://rubygems.org/gems/jekyll-theme-mdui/)
24
24
 
@@ -30,7 +30,7 @@
30
30
 
31
31
  ## Demo
32
32
 
33
- [KeJun's Blog](https://kejun.space)
33
+ [KeJun's Blog](https://blog.kejun.me)
34
34
 
35
35
  ## Quick start
36
36
 
@@ -0,0 +1,19 @@
1
+ {% if site.data.site.lang == 'zh-CN' %}
2
+ {% assign lang = site.data.lang[site.data.site.lang] %}
3
+ {% else %}
4
+ {% assign lang = site.data.lang.en-US %}
5
+ {% endif %}
6
+ <script src="//cdn1.lncld.net/static/js/3.0.4/av-min.js"></script>
7
+ <script>
8
+ !function(e,n){"object"==typeof exports&&"object"==typeof module?module.exports=n():"function"==typeof define&&define.amd?define("Valine",[],n):"object"==typeof exports?exports.Valine=n():e.Valine=n()}(this,function(){return function(e){function n(i){if(t[i])return t[i].exports;var r=t[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}var t={};return n.m=e,n.c=t,n.i=function(e){return e},n.d=function(e,t,i){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:i})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,n){return Object.prototype.hasOwnProperty.call(e,n)},n.p="",n(n.s=2)}([function(e,n,t){"use strict";function i(e){return e.replace(RegExp("^"+(e.match(/^(\t| )+/)||"")[0],"gm"),"")}function r(e){return(e+"").replace(/"/g,"&quot;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}function a(e){function n(e){var n=o[e.replace(/\*/g,"_")[1]||""],t=v[v.length-1]==e;return n?n[1]?(v[t?"pop":"push"](e),n[0|t]):n[0]:e}function t(){for(var e="";v.length;)e+=n(v[v.length-1]);return e}var l,s,c,d,u,p=/((?:^|\n+)(?:\n---+|\* \*(?: \*)+)\n)|(?:^```(\w*)\n([\s\S]*?)\n```$)|((?:(?:^|\n+)(?:\t| {2,}).+)+\n*)|((?:(?:^|\n)([>*+-]|\d+\.)\s+.*)+)|(?:\!\[([^\]]*?)\]\(([^\)]+?)\))|(\[)|(\](?:\(([^\)]+?)\))?)|(?:(?:^|\n+)([^\s].*)\n(\-{3,}|={3,})(?:\n+|$))|(?:(?:^|\n+)(#{1,3})\s*(.+)(?:\n+|$))|(?:`([^`].*?)`)|( \n\n*|\n{2,}|__|\*\*|[_*])/gm,v=[],f="",h=0,g={};for(e=e.replace(/^\[(.+?)\]:\s*(.+)$/gm,function(e,n,t){return g[n.toLowerCase()]=t,""}).replace(/^\n+|\n+$/g,"");c=p.exec(e);)s=e.substring(h,c.index),h=p.lastIndex,l=c[0],s.match(/[^\\](\\\\)*\\$/)||(c[3]||c[4]?l='<pre class="code '+(c[4]?"poetry":c[2].toLowerCase())+'">'+i(r(c[3]||c[4]).replace(/^\n+|\n+$/g,""))+"</pre>":c[6]?(u=c[6],u.match(/\./)&&(c[5]=c[5].replace(/^\d+/gm,"")),d=a(i(c[5].replace(/^\s*[>*+.-]/gm,""))),">"===u?u="blockquote":(u=u.match(/\./)?"ol":"ul",d=d.replace(/^(.*)(\n|$)/gm,"<li>$1</li>")),l="<"+u+">"+d+"</"+u+">"):c[8]?l='<img src="'+r(c[8])+'" alt="'+r(c[7])+'">':c[10]?(f=f.replace("<a>",'<a href="'+r(c[11]||g[s.toLowerCase()])+'">'),l=t()+"</a>"):c[9]?l="<a>":c[12]||c[14]?(u="h"+(c[14]?c[14].length:"="===c[13][0]?1:2),l="<"+u+">"+a(c[12]||c[15])+"</"+u+">"):c[16]?l="<code>"+r(c[16])+"</code>":(c[17]||c[1])&&(l=n(c[17]||"--"))),f+=s,f+=l;return(f+e.substring(h)+t()).trim()}Object.defineProperty(n,"__esModule",{value:!0});var o={"":["<em>","</em>"],_:["<strong>","</strong>"],"\n":["<br />"]," ":["<br />"],"-":["<hr />"]};n.default=a},function(e,n,t){var i=t(3);"string"==typeof i&&(i=[[e.i,i,""]]);var r={};r.transform=void 0;t(5)(i,r);i.locals&&(e.exports=i.locals)},function(e,n,t){"use strict";function i(e,n){if(!(e instanceof n))throw new TypeError("Cannot call a class as a function")}var r=function(){function e(e,n){for(var t=0;t<n.length;t++){var i=n[t];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(n,t,i){return t&&e(n.prototype,t),i&&e(n,i),n}}(),a=t(0),o=function(e){return e&&e.__esModule?e:{default:e}}(a);t(1);var l={comment:"",rid:"",nick:"unknow",link:"",ua:navigator.userAgent,url:location.pathname,pin:0,like:0},s=console.log,c={}.toString,d=function(){function e(n){i(this,e);var t=this;window.onload=function(){t.init(n),t.bind()}}return r(e,[{key:"init",value:function(e){var n=this,t=e.av||n.v;t&&t.version&&(t.init({appId:e.app_id||e.appId,appKey:e.app_key||e.appKey}),n.v=t);try{n.element="[object HTMLDivElement]"===c.call(e.el)?e.el:document.querySelectorAll(e.el)[0]}catch(e){return void s("The target element does not exist")}n.element.classList.add("valine");var i=e.placeholder||"ヾノ≧∀≦)o来啊,快活啊!",r='<div class="vwrap"><div class="vedit"><textarea class="veditor vinput" placeholder="'+i+'"></textarea></div><div class="vcontrol"><div class=\'vident\'><input placeholder="称呼" class="vnick vinput" type="text"><input placeholder="网址" class="vlink vinput" type="text"></div><div class="vright"><button type="button" class="vsubmit vbtn">回复</button></div></div></div><div class="pd5 txt-right power">Powered By <a href="https://github.com/xCss/Valine" target="_blank">Valine</a></div><ul class="vlist"><li class="vloading"></li><li class="vempty"></li></ul>';n.element.innerHTML=r;var a=n.element.querySelector(".vloading");a.innerHTML='<div class="spinner"><div class="rect1"></div><div class="rect2"></div><div class="rect3"></div><div class="rect4"></div><div class="rect5"></div></div>',n.loading={show:function(){a.setAttribute("style","display:block;")},hide:function(){a.setAttribute("style","display:none;")}};var o=n.element.querySelector(".vempty");o.innerText="还没有评论哦,快来抢沙发吧!",n.nodata={show:function(){o.setAttribute("style","display:block;")},hide:function(){o.setAttribute("style","display:none;")}},n.loading.show(),n.nodata.hide();var l=new n.v.Query("Comment");l.equalTo("url",location.pathname),l.ascending("createdAt"),l.find().then(function(e){n.loading.hide();e.length?(n.nodata.hide(),e.forEach(function(e){var t=document.createElement("li");t.setAttribute("class","vcard"),t.setAttribute("data-id",e.id),t.innerHTML='<div class="vhead"><a href="'+(e.get("link")||"javascript:void(0);")+'" target="_blank" data-id="'+e.id+'">'+e.get("nick")+'</a><span class="vtime">'+p(e.get("createdAt"))+"</span><span rid='"+e.id+"' at='"+e.get("nick")+'\' class="vat">回复</span></div><div class="vcomment">'+e.get("comment")+"</div>";var i=n.element.querySelector(".vlist"),r=i.querySelectorAll("li"),a=t.querySelector(".vat");n.bindAt(a),i.insertBefore(t,r[1])})):n.nodata.show()}).catch(function(e){n.loading.hide(),n.nodata.show()})}},{key:"bind",value:function(){var e=this,n={veditor:"comment",vnick:"nick",vlink:"link"},t={};for(var i in n)!function(){var r=n[i],a=e.element.querySelector("."+i);t[r]=a,a.addEventListener("input",function(e){l[r]=u.encode(a.value.replace(/(^\s*)|(\s*$)/g,""))})}();e.reset=function(){for(var t in n){var i=n[t];e.element.querySelector("."+t).value="",l[i]=""}l.nick="unknow",l.rid=""},e.bindAt=function(e){e.addEventListener("click",function(n){var i=e.getAttribute("at");t.comment.value="@"+i+" ,",t.comment.focus()})},e.element.querySelector(".vsubmit").addEventListener("click",function(n){if(""==l.comment)return void t.comment.focus();""==l.nick&&(l.nick="小调皮"),l.comment=(0,o.default)(l.comment),e.loading.show();var i=e.v.Object.extend("Comment"),r=new i;for(var a in l){var s=l[a];r.set(a,s)}r.save().then(function(n){var t=document.createElement("li");t.setAttribute("class","vcard"),t.setAttribute("data-id",n.id),t.innerHTML='<div class="vhead"><a href="'+(n.get("link")||"javascript:void(0);")+'" target="_blank" data-id="'+n.id+'">'+n.get("nick")+'</a><span class="vtime">'+p(n.get("createdAt"))+"</span><span rid='"+n.id+"' at='"+n.get("nick")+'\' class="vat">回复</span></div><div class="vcomment">'+n.get("comment")+"</div>";var i=e.element.querySelector(".vlist"),r=i.querySelectorAll("li"),a=t.querySelector(".vat");e.bindAt(a),i.insertBefore(t,r[1]),e.reset(),e.loading.hide(),e.nodata.hide()}).catch(function(n){e.loading.hide()})})}}]),e}(),u={encode:function(e){var n="";return 0==e.length?"":(n=e.replace(/&/g,"&amp;"),n=n.replace(/</g,"&lt;"),n=n.replace(/>/g,"&gt;"),n=n.replace(/ /g,"&nbsp;"),n=n.replace(/\'/g,"&#39;"),n=n.replace(/\"/g,"&quot;"))},decode:function(e){var n="";return 0==e.length?"":(n=e.replace(/&amp;/g,"&"),n=n.replace(/&lt;/g,"<"),n=n.replace(/&gt;/g,">"),n=n.replace(/&nbsp;/g," "),n=n.replace(/&#39;/g,"'"),n=n.replace(/&quot;/g,'"'))}},p=function(e){var n=v(e.getDate(),2),t=v(e.getMonth()+1,2);return v(e.getFullYear(),2)+"-"+t+"-"+n+" "+v(e.getHours(),2)+":"+v(e.getMinutes(),2)+":"+v(e.getSeconds(),2)},v=function(e,n){for(var t=e.toString();t.length<n;)t="0"+t;return t};e.exports=d},function(e,n,t){n=e.exports=t(4)(void 0),n.push([e.i,'.valine {\n /************ Loading ************/ }\n .valine * {\n -webkit-box-sizing: border-box;\n box-sizing: border-box;\n font-family: -apple-system, BlinkMacSystemFont, \'Mirages Custom\', \'Merriweather\', \'Open Sans\', "Segoe UI", Roboto, "PingFang SC", "Microsoft Yahei", "WenQuanYi Micro Hei", "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", Helvetica, Arial, sans-serif;\n font-size: 14px;\n line-height: 1.42857143;\n color: #555;\n -webkit-transition: all .3s ease;\n transition: all .3s ease; }\n .valine .vwrap {\n border: 1px solid #dedede;\n border-radius: 4px;\n margin-bottom: 10px;\n overflow: hidden; }\n .valine .vwrap .vcontrol {\n background: #fbfbfb;\n font-size: 0; }\n .valine .vwrap .vcontrol .vident {\n font-size: 14px;\n width: 70%;\n display: inline-block;\n padding: 5px;\n vertical-align: middle; }\n .valine .vwrap .vcontrol .vright {\n font-size: 14px;\n padding: 5px;\n display: inline-block;\n width: 30%;\n text-align: right;\n vertical-align: middle; }\n .valine .vwrap .vcontrol input {\n background: transparent; }\n .valine a {\n text-decoration: none;\n color: #555; }\n .valine a:hover {\n color: #222; }\n .valine ul,\n .valine li {\n list-style: none; }\n .valine .txt-center {\n text-align: center; }\n .valine .txt-right {\n text-align: right; }\n .valine .pd5 {\n padding: 5px; }\n .valine .pd10 {\n padding: 10px; }\n .valine .veditor {\n width: 100%;\n height: 80px; }\n .valine .vinput {\n border: none;\n resize: none;\n outline: none;\n padding: 8px 10px;\n max-width: 100%; }\n .valine .vbtn {\n display: inline-block;\n margin-bottom: 0;\n font-weight: 400;\n text-align: center;\n vertical-align: middle;\n -ms-touch-action: manipulation;\n touch-action: manipulation;\n cursor: pointer;\n border: 1px solid transparent;\n white-space: nowrap;\n padding: 8px 0;\n font-size: 14px;\n line-height: 1.42857143;\n border-radius: 4px;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n outline: none;\n min-width: 60px;\n max-width: 100%; }\n .valine .vbtn:active,\n .valine .vbtn:hover {\n color: #3090e4;\n border-color: #3090e4;\n background-color: #fff; }\n .valine .vlist {\n border-top: 1px solid #dedede;\n border-bottom: 1px solid #dedede;\n padding: 0 10px; }\n .valine .vlist .vcard {\n padding: 8px 0; }\n .valine .vlist .vcard + .vcard {\n border-top: 1px solid #dedede; }\n .valine .vlist .vcard .vhead a {\n font-size: 18px;\n font-weight: 300; }\n .valine .vlist .vcard .vhead .vtime {\n font-size: 12px;\n color: #a9a4a4;\n display: inline-block;\n padding: 0 5px; }\n .valine .vlist .vcard .vhead .vat {\n font-size: 14px;\n color: #999;\n display: inline-block;\n padding: 0 5px;\n cursor: pointer; }\n .valine .vlist .vcard .vhead .vat:hover {\n color: #111; }\n .valine .vlist .vcard .vcomment {\n word-wrap: break-word;\n white-space: pre-wrap;\n word-break: break-all;\n text-align: justify;\n line-height: 1.8; }\n .valine .vlist .vcard .vcomment pre.code {\n overflow: auto; }\n .valine .vlist .vempty {\n padding: 20px;\n text-align: center;\n color: #999; }\n .valine .power {\n color: #999; }\n .valine .spinner {\n margin: 10px auto;\n width: 50px;\n height: 30px;\n text-align: center;\n font-size: 10px; }\n .valine .spinner > div {\n background-color: #9c9c9c;\n height: 100%;\n width: 6px;\n margin-right: 3px;\n display: inline-block;\n -webkit-animation: sk-stretchdelay 1.2s infinite ease-in-out;\n animation: sk-stretchdelay 1.2s infinite ease-in-out; }\n .valine .spinner .rect2 {\n -webkit-animation-delay: -1.1s;\n animation-delay: -1.1s; }\n .valine .spinner .rect3 {\n -webkit-animation-delay: -1.0s;\n animation-delay: -1.0s; }\n .valine .spinner .rect4 {\n -webkit-animation-delay: -0.9s;\n animation-delay: -0.9s; }\n .valine .spinner .rect5 {\n -webkit-animation-delay: -0.8s;\n animation-delay: -0.8s; }\n\n@-webkit-keyframes sk-stretchdelay {\n 0%,\n 40%,\n 100% {\n -webkit-transform: scaleY(0.4); }\n 20% {\n -webkit-transform: scaleY(1); } }\n\n@keyframes sk-stretchdelay {\n 0%,\n 40%,\n 100% {\n transform: scaleY(0.4);\n -webkit-transform: scaleY(0.4); }\n 20% {\n transform: scaleY(1);\n -webkit-transform: scaleY(1); } }\n',""])},function(e,n){function t(e,n){var t=e[1]||"",r=e[3];if(!r)return t;if(n&&"function"==typeof btoa){var a=i(r);return[t].concat(r.sources.map(function(e){return"/*# sourceURL="+r.sourceRoot+e+" */"})).concat([a]).join("\n")}return[t].join("\n")}function i(e){return"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(e))))+" */"}e.exports=function(e){var n=[];return n.toString=function(){return this.map(function(n){var i=t(n,e);return n[2]?"@media "+n[2]+"{"+i+"}":i}).join("")},n.i=function(e,t){"string"==typeof e&&(e=[[null,e,""]]);for(var i={},r=0;r<this.length;r++){var a=this[r][0];"number"==typeof a&&(i[a]=!0)}for(r=0;r<e.length;r++){var o=e[r];"number"==typeof o[0]&&i[o[0]]||(t&&!o[2]?o[2]=t:t&&(o[2]="("+o[2]+") and ("+t+")"),n.push(o))}},n}},function(e,n,t){function i(e,n){for(var t=0;t<e.length;t++){var i=e[t],r=f[i.id];if(r){r.refs++;for(var a=0;a<r.parts.length;a++)r.parts[a](i.parts[a]);for(;a<i.parts.length;a++)r.parts.push(d(i.parts[a],n))}else{for(var o=[],a=0;a<i.parts.length;a++)o.push(d(i.parts[a],n));f[i.id]={id:i.id,refs:1,parts:o}}}}function r(e,n){for(var t=[],i={},r=0;r<e.length;r++){var a=e[r],o=n.base?a[0]+n.base:a[0],l=a[1],s=a[2],c=a[3],d={css:l,media:s,sourceMap:c};i[o]?i[o].parts.push(d):t.push(i[o]={id:o,parts:[d]})}return t}function a(e,n){var t=g(e.insertInto);if(!t)throw new Error("Couldn't find a style target. This probably means that the value for the 'insertInto' parameter is invalid.");var i=y[y.length-1];if("top"===e.insertAt)i?i.nextSibling?t.insertBefore(n,i.nextSibling):t.appendChild(n):t.insertBefore(n,t.firstChild),y.push(n);else{if("bottom"!==e.insertAt)throw new Error("Invalid value for parameter 'insertAt'. Must be 'top' or 'bottom'.");t.appendChild(n)}}function o(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e);var n=y.indexOf(e);n>=0&&y.splice(n,1)}function l(e){var n=document.createElement("style");return e.attrs.type="text/css",c(n,e.attrs),a(e,n),n}function s(e){var n=document.createElement("link");return e.attrs.type="text/css",e.attrs.rel="stylesheet",c(n,e.attrs),a(e,n),n}function c(e,n){Object.keys(n).forEach(function(t){e.setAttribute(t,n[t])})}function d(e,n){var t,i,r,a;if(n.transform&&e.css){if(!(a=n.transform(e.css)))return function(){};e.css=a}if(n.singleton){var c=b++;t=m||(m=l(n)),i=u.bind(null,t,c,!1),r=u.bind(null,t,c,!0)}else e.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(t=s(n),i=v.bind(null,t,n),r=function(){o(t),t.href&&URL.revokeObjectURL(t.href)}):(t=l(n),i=p.bind(null,t),r=function(){o(t)});return i(e),function(n){if(n){if(n.css===e.css&&n.media===e.media&&n.sourceMap===e.sourceMap)return;i(e=n)}else r()}}function u(e,n,t,i){var r=t?"":i.css;if(e.styleSheet)e.styleSheet.cssText=w(n,r);else{var a=document.createTextNode(r),o=e.childNodes;o[n]&&e.removeChild(o[n]),o.length?e.insertBefore(a,o[n]):e.appendChild(a)}}function p(e,n){var t=n.css,i=n.media;if(i&&e.setAttribute("media",i),e.styleSheet)e.styleSheet.cssText=t;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(t))}}function v(e,n,t){var i=t.css,r=t.sourceMap,a=void 0===n.convertToAbsoluteUrls&&r;(n.convertToAbsoluteUrls||a)&&(i=x(i)),r&&(i+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(r))))+" */");var o=new Blob([i],{type:"text/css"}),l=e.href;e.href=URL.createObjectURL(o),l&&URL.revokeObjectURL(l)}var f={},h=function(e){var n;return function(){return void 0===n&&(n=e.apply(this,arguments)),n}}(function(){return window&&document&&document.all&&!window.atob}),g=function(e){var n={};return function(t){return void 0===n[t]&&(n[t]=e.call(this,t)),n[t]}}(function(e){return document.querySelector(e)}),m=null,b=0,y=[],x=t(6);e.exports=function(e,n){if("undefined"!=typeof DEBUG&&DEBUG&&"object"!=typeof document)throw new Error("The style-loader cannot be used in a non-browser environment");n=n||{},n.attrs="object"==typeof n.attrs?n.attrs:{},n.singleton||(n.singleton=h()),n.insertInto||(n.insertInto="head"),n.insertAt||(n.insertAt="bottom");var t=r(e,n);return i(t,n),function(e){for(var a=[],o=0;o<t.length;o++){var l=t[o],s=f[l.id];s.refs--,a.push(s)}if(e){i(r(e,n),n)}for(var o=0;o<a.length;o++){var s=a[o];if(0===s.refs){for(var c=0;c<s.parts.length;c++)s.parts[c]();delete f[s.id]}}}};var w=function(){var e=[];return function(n,t){return e[n]=t,e.filter(Boolean).join("\n")}}()},function(e,n){e.exports=function(e){var n="undefined"!=typeof window&&window.location;if(!n)throw new Error("fixUrls requires window.location");if(!e||"string"!=typeof e)return e;var t=n.protocol+"//"+n.host,i=t+n.pathname.replace(/\/[^\/]*$/,"/");return e.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi,function(e,n){var r=n.trim().replace(/^"(.*)"$/,function(e,n){return n}).replace(/^'(.*)'$/,function(e,n){return n});if(/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/)/i.test(r))return e;var a;return a=0===r.indexOf("//")?r:0===r.indexOf("/")?t+r:i+r.replace(/^\.\//,""),"url("+JSON.stringify(a)+")"})}}])});
9
+ </script>
10
+ <div style="padding:0px 16px;" class="comment"></div>
11
+ <script>
12
+ new Valine({
13
+ av: AV,
14
+ el: '.comment',
15
+ app_id: '{{site.data.site.comment.valine_app_id}}',
16
+ app_key: '{{site.data.site.comment.valine_app_key}}',
17
+ placeholder: '{{site.data.site.comment.valine_placeholder}}'
18
+ });
19
+ </script>
@@ -0,0 +1,8 @@
1
+ {% if site.data.site.custom_css!="" %}
2
+ {% assign css = site.data.site.custom_css %}
3
+ {% endif %}
4
+ {% if site.data.site.custom_js!="" %}
5
+ {% assign js = site.data.site.custom_js %}
6
+ {% endif %}
7
+ <link rel="stylesheet" href="{{ "/assets/css/" | prepend: site.baseurl |append: css }}">
8
+ <script src="{{ "/assets/js/" | prepend: site.baseurl |append: js }}"></script>
@@ -2,7 +2,6 @@
2
2
  <script>
3
3
  $(function() {
4
4
  $("div.lazy").lazyload({
5
- effect : "fadeIn"
6
5
  });
7
6
  });
8
7
  </script>
@@ -12,6 +12,7 @@
12
12
  cursor: pointer;
13
13
  max-height: 245px;
14
14
  min-height: 245px;
15
+ height:245px;
15
16
  background-position: 50% 50%;
16
17
  background-size: cover;
17
18
  background-color: #303033;
@@ -48,7 +49,7 @@
48
49
  <h1><a href="{{post.url| prepend: site.baseurl}}">{{post.title}}</a></h3>
49
50
  </div>
50
51
  {% else %}
51
- <div class="mdui-card-media mdui-ripple k-post-media lazy" data-original="{{post.img}}" style="background-image:url()">
52
+ <div class="mdui-card-media mdui-ripple k-post-media lazy" data-original="{{post.img}}">
52
53
  <div class="mdui-card-media-covered mdui-card-media-covered-gradient">
53
54
  <div class="mdui-card-primary">
54
55
  <div class="mdui-card-primary-title"><a class="mdui-text-color-white-text" href="{{post.url| prepend: site.baseurl}}">{{post.title}}</a></div>
@@ -1,4 +1,4 @@
1
- {% assign aplayer = site.data.meng.aplayer %}
1
+ {% assign aplayer = site.data.meng.music_player %}
2
2
  <style>
3
3
  @media screen and (max-width: 600px){
4
4
  .k-music-card{
@@ -1,7 +1,7 @@
1
1
  {% if site.data.meng.console.switch == true %}
2
2
  {% if site.data.meng.console.theme_info == true %}
3
3
  <script>
4
- console.info("\n %c © Jekyll Theme MDUI | Version: 0.5.1 | https://github.com/KeJunMao/jekyll-theme-mdui \n\n", "color: {{site.data.meng.console.color}}; background:{{site.data.meng.console.background}}; padding:5px 0; border-radius: 5px 5px 5px 5px;");
4
+ console.info("\n %c © Jekyll Theme MDUI | Version: 0.5.2 | https://github.com/KeJunMao/jekyll-theme-mdui \n\n", "color: {{site.data.meng.console.color}}; background:{{site.data.meng.console.background}}; padding:5px 0; border-radius: 5px 5px 5px 5px;");
5
5
  </script>
6
6
  {% endif %}
7
7
  <script>
@@ -0,0 +1,86 @@
1
+ {% assign cplayer = site.data.meng.music_player %}
2
+ <link href="//cdn.bootcss.com/cplayer/2.4.8/cplayer.min.css" rel="stylesheet">
3
+ <style>
4
+ #k-cplayer{
5
+ position: fixed;
6
+ bottom: 130px;
7
+ -webkit-box-shadow: rgba(0, 0, 0, 0.117647) 0px 1px 6px, rgba(0, 0, 0, 0.117647) 0px 1px 4px;
8
+ box-shadow: rgba(0, 0, 0, 0.117647) 0px 1px 6px, rgba(0, 0, 0, 0.117647) 0px 1px 4px;
9
+ transition: transform .5s ease;
10
+ }
11
+
12
+ @media screen and (max-width: 600px){
13
+ #k-cplayer{
14
+ transform:translateX(-300px)
15
+ }
16
+ }
17
+
18
+ c-player .cp-mainbody{
19
+ box-shadow: none;
20
+ -webkit-box-shadow:none;
21
+ }
22
+ .cp-list-button{
23
+ display: none !important;
24
+ }
25
+ .cp-drop-down-menu.cp-drop-down-menu-info{
26
+ display: none;
27
+ }
28
+ .k-music-btn{
29
+ text-align: center;
30
+ line-height: 52px;
31
+ color: #fff;
32
+ width: 20px;
33
+ height: 52px;
34
+ background: {{cplayer.button_color}} none repeat scroll 0% 0%;
35
+ position: relative;
36
+ right: 0px;
37
+ bottom: 0px;
38
+ box-sizing: border-box;
39
+ border-left: none;
40
+ cursor: pointer;
41
+ float: right;
42
+ }
43
+ </style>
44
+ <script src="https://cdn.jsdelivr.net/gh/MoePlayer/cPlayer/dist/cplayer.js"></script>
45
+
46
+ <div id="k-cplayer">
47
+ <div class="k-music-btn">></div>
48
+ </div>
49
+ <script>
50
+ jQuery(document).ready(function ($) {
51
+ var player = new cplayer({
52
+ element: document.getElementById('k-cplayer'),
53
+ playlist: [{
54
+ src: '{{cplayer.music.url}}',
55
+ poster: '{{cplayer.music.pic}}',
56
+ name: '{{cplayer.music.title}}',
57
+ artist: '{{cplayer.music.author}}',
58
+ }, ]
59
+ });
60
+ if($(window).width()<=600){
61
+ var flag = true;
62
+ }else{
63
+ var flag = false;
64
+ }
65
+
66
+ $('.k-music-btn').click(function(){
67
+ if (flag == false){
68
+ $('#k-cplayer').css('transform','translateX(-300px)');
69
+ flag = true;
70
+ }else if(flag == true){
71
+ $('#k-cplayer').css('transform','translateX(0px)');
72
+ flag = false;
73
+ }
74
+ });
75
+ document.addEventListener("visibilitychange", function() {
76
+ if(document.visibilityState == "hidden" ){
77
+ player.pause();
78
+ }
79
+ if(document.visibilityState == "visible"){
80
+ if($(window).width()>600){
81
+ player.play();
82
+ }
83
+ }
84
+ }, false);
85
+ })
86
+ </script>
@@ -16,6 +16,7 @@ layout: compress
16
16
  {% include analytics/google.html %}
17
17
  {% endif %}
18
18
  {% include component/sw.html %}
19
+ {% include component/customCssJS.html %}
19
20
  {% include footer/footer.html %}
20
21
  {% if site.data.site.uiux.meng == true%}
21
22
  {% if site.data.meng.live2d.switch == true %}
@@ -36,7 +37,9 @@ layout: compress
36
37
  {% if site.data.meng.card.switch == true %}
37
38
  {% include meng/card.html %}
38
39
  {% endif %}
39
- {% if site.data.meng.aplayer.switch == true %}
40
+ {% if site.data.meng.music_player.player == "cplayer" %}
41
+ {% include meng/cplayer.html %}
42
+ {% elsif site.data.meng.music_player.player == "aplayer"%}
40
43
  {% include meng/aplayer.html %}
41
44
  {% endif %}
42
45
  {% endif %}
File without changes
File without changes
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-theme-mdui
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.1.2
4
+ version: 0.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - KeJun
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-07-29 00:00:00.000000000 Z
11
+ date: 2017-08-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
@@ -80,6 +80,8 @@ files:
80
80
  - _includes/comment/disqus.html
81
81
  - _includes/comment/gitment.html
82
82
  - _includes/comment/livere.html
83
+ - _includes/comment/valine.html
84
+ - _includes/component/customCssJS.html
83
85
  - _includes/component/nprogress.html
84
86
  - _includes/component/sw.html
85
87
  - _includes/component/totop.html
@@ -108,6 +110,7 @@ files:
108
110
  - _includes/meng/background.html
109
111
  - _includes/meng/card.html
110
112
  - _includes/meng/console.html
113
+ - _includes/meng/cplayer.html
111
114
  - _includes/meng/cursor.html
112
115
  - _includes/meng/head_card.html
113
116
  - _includes/meng/live2d.html
@@ -122,8 +125,10 @@ files:
122
125
  - _layouts/page.html
123
126
  - _layouts/post.html
124
127
  - _layouts/tags.html
128
+ - assets/css/customCss.css
125
129
  - assets/css/global.css
126
130
  - assets/js/History.js
131
+ - assets/js/customJS.js
127
132
  homepage: https://github.com/KeJunMao/jekyll-theme-mdui.git
128
133
  licenses:
129
134
  - MIT