jekyll-theme-mdui 0.4.9.9 → 0.5.0

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: cc2a8b7ae5c4c650a7997c23aa2326d409c7c178
4
- data.tar.gz: 26b338220a8e11b086f5e5f7a5b21a520ed1a021
3
+ metadata.gz: 822de3144aa0a3cb7f13ef51e527ca2450274ac8
4
+ data.tar.gz: 1b86992b69f6e097f199251148783a08028b472c
5
5
  SHA512:
6
- metadata.gz: 4cf4939cffb194197a294d3c4fb4a053105ba481ac25dce1cf89814f506c77009a23219c9444a2c6f8b6b439814c75cf899bbcf28766b3f5780f91fb4e9eca1c
7
- data.tar.gz: b8b593f1b24eb238710135e674b553a951cf6ea25a21278762b09eadd217c88f4bff48b0095b2e11cc5ac93abd998ecf6ce49c38ce071ba5620e9ff137deab59
6
+ metadata.gz: d97b48710a8126680bc8b70971eadbd96f233ef8016508651169f188ce2149fd6b2f33690d3b50d856eebaa72ccc7bdec0aaf5bde2fc1cd8e02632e24f4db0db
7
+ data.tar.gz: 9f136f89783f71c6ce8d12667b3dce30a7eba4b7cc69219317192b1beee89c4203bd351e8903bea83e9632a9dbaf0c185203c4657d522698abddd59ce715e00b
data/README.md CHANGED
@@ -18,8 +18,8 @@
18
18
 
19
19
  ## General
20
20
 
21
- [![Version](https://img.shields.io/badge/version-0.4.9-green.svg?style=flat-square)]()
22
- [![Jekyll](https://img.shields.io/badge/Jekyll-3.4+-green.svg?style=flat-square)](https://jekyllrb.com/)
21
+ [![Version](https://img.shields.io/badge/version-0.5.0-green.svg?style=flat-square)]()
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
 
25
25
  [![Code Climate](https://img.shields.io/codeclimate/github/KeJunMao/jekyll-theme-mdui.svg?style=flat-square)](https://codeclimate.com/github/KeJunMao/jekyll-theme-mdui/)
@@ -0,0 +1,3 @@
1
+ {% if site.data.site.comment.used != "" %}
2
+ {% include comment/{{site.data.site.comment.used}}.html %}
3
+ {% endif %}
@@ -9,11 +9,11 @@
9
9
  display: none;
10
10
  }
11
11
  </style>
12
- {% if site.data.site.disqus.disqus_shortname != "" %}
12
+ {% if site.data.site.comment.disqus_shortname != "" %}
13
13
  <div class="mdui-divider"></div>
14
- {% if site.data.site.disqus.disqus_proxy == false %}
15
- {% if site.data.site.disqus.disqus_button == true %}
16
- <button id="load-disqus" class="mdui-btn mdui-btn-block mdui-center" onclick="disqus.load();" data="{{ site.data.site.disqus.disqus_shortname }}">{{lang.post.comments_load_button}}</button>
14
+ {% if site.data.site.comment.disqus_proxy == false %}
15
+ {% if site.data.site.comment.disqus_button == true %}
16
+ <button id="load-disqus" class="mdui-btn mdui-btn-block mdui-center" onclick="disqus.load();" data="{{ site.data.site.comment.disqus_shortname }}">{{lang.post.comments_load_button}}</button>
17
17
  <div id="disqus_thread"></div>
18
18
  <script>
19
19
  var disqus = {
@@ -45,7 +45,7 @@ var disqus = {
45
45
  <div id="disqus_thread"></div>
46
46
  <script>
47
47
  function disqus(){
48
- var disqus_shortname = '{{ site.data.site.disqus.disqus_shortname }}';
48
+ var disqus_shortname = '{{ site.data.site.comment.disqus_shortname }}';
49
49
  if(typeof DISQUS !== 'object') {
50
50
  (function () {
51
51
  var s = document.createElement('script'); s.async = true;
@@ -66,7 +66,7 @@ var disqus = {
66
66
  </script>
67
67
  {% endif %}
68
68
  {% endif %}
69
- {% if site.data.site.disqus.disqus_proxy %}
69
+ {% if site.data.site.comment.disqus_proxy %}
70
70
  <div class="mdui-divider"></div>
71
71
  <div id="disqusreadonly" style="padding-top: 16px;">
72
72
  </div>
@@ -0,0 +1,38 @@
1
+ <!-- 来必力City版安装代码 -->
2
+ <script>
3
+ var livereurl = 'http://' + (document.location.hostname || document.location.host);
4
+ $(document).delegate('a[href^="/"],a[href^="' + livereurl + '"]', "click", function (e) {
5
+ $('script[src="https://cdn-city.livere.com/js/embed.dist.js"]').remove();
6
+ });
7
+ </script>
8
+ <div style="padding:0px 16px;" id="lv-container" data-id="{{site.data.site.comment.livere_type}}" data-uid="{{site.data.site.comment.livere_data_uid}}">
9
+ <script type="text/javascript">
10
+ $(function () {
11
+ (function (d, s) {
12
+ var j, e = d.getElementsByTagName(s)[0];
13
+
14
+ if (typeof LivereTower === 'function') {
15
+ return;
16
+ }
17
+
18
+ j = d.createElement(s);
19
+ j.src = 'https://cdn-city.livere.com/js/embed.dist.js';
20
+ j.async = true;
21
+
22
+ e.parentNode.insertBefore(j, e);
23
+ })(document, 'script');
24
+ $('script[src="https://cdn-city.livere.com/js/embed.dist.js"]').eq(1).remove();
25
+ setTimeout(function () {
26
+ if ($('iframe').length == 2) {
27
+ var livereFlag = true;
28
+ } else {
29
+ $('body').find('iframe').eq(2).remove();
30
+ $('body').find('iframe').eq(3).remove();
31
+ var livereFlag = false;
32
+ }
33
+ }, 1000);
34
+ })
35
+ </script>
36
+ <noscript> 为正常使用来必力评论功能请激活JavaScript</noscript>
37
+ </div>
38
+ <!-- City版安装代码已完成 -->
@@ -1,9 +1,16 @@
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 %}
1
6
  <style>
2
7
  .k-lastupdate{
3
8
  color: #000000;
4
9
  background: #ffffc0;
5
10
  border-left: 5px solid #fff000;
6
11
  cursor: default;
12
+ text-transform: none;
13
+ text-overflow: ellipsis;
7
14
  }
8
15
  .k-lastupdate:hover{
9
16
  background: #ffffc0;
@@ -13,7 +20,7 @@
13
20
  }
14
21
  </style>
15
22
 
16
- <a class="mdui-btn mdui-btn-block k-lastupdate" id="k-difference" href="javascript:;">本文最后更新于0天前,文中所描述的信息可能已发生改变,请谨慎使用。</a>
23
+ <a class="mdui-btn mdui-btn-block k-lastupdate" id="k-difference" href="javascript:;"></a>
17
24
  <script>
18
25
  var date1=Date.parse($('.k-page-date').attr('date'));
19
26
  var date2=new Date();
@@ -22,7 +29,7 @@ var date3=date2.getTime()-date1;
22
29
  var days=Math.floor(date3/(24*3600*1000));
23
30
 
24
31
  if (days>= 100){
25
- $('#k-difference').html("本文最后更新于"+days+"天前,文中所描述的信息可能已发生改变,请谨慎使用。");
32
+ $('#k-difference').html("{{lang.lastupdate.one}} "+ days +" {{lang.lastupdate.two}}");
26
33
  }else{
27
34
  $('#k-difference').hide();
28
35
  }
@@ -1,9 +1,16 @@
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 %}
1
6
  <style>
2
7
  .k-readtime{
3
8
  color: #000000;
4
9
  background: #c0ffee;
5
10
  border-left: 5px solid #00ffd8;
6
11
  cursor: default;
12
+ text-transform: none;
13
+ text-overflow: ellipsis;
7
14
  }
8
15
  .k-readtime:hover{
9
16
  background: #c0ffee;
@@ -14,7 +21,7 @@
14
21
  </style>
15
22
  {% assign words = content | strip_html | strip_newlines | size %}
16
23
  {% if words < 360 %}
17
- <a class="mdui-btn mdui-btn-block k-readtime" href="javascript:;">阅读本文需要1分钟</a>
24
+ <a class="mdui-btn mdui-btn-block k-readtime" href="javascript:;">{{lang.readtime.one}}1{{lang.readtime.two}}</a>
18
25
  {% else %}
19
- <a class="mdui-btn mdui-btn-block k-readtime" href="javascript:;">阅读本文需要{{ content | strip_html | strip_newlines | size | divided_by:360 | round}}分钟</a>
26
+ <a class="mdui-btn mdui-btn-block k-readtime" href="javascript:;">{{lang.readtime.one}} {{ content | strip_html | strip_newlines | size | divided_by:360 | round}} {{lang.readtime.two}}</a>
20
27
  {% endif %}
@@ -1,3 +1,8 @@
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 %}
1
6
  {% capture categories %}
2
7
  {% for c in site.categories %}
3
8
  {{c[0]}}
@@ -28,16 +33,16 @@
28
33
  <div class="k-container">
29
34
  <div class="mdui-dialog" id="frontMatter">
30
35
  <div class="mdui-dialog-content">
31
- <div class="mdui-dialog-title">Front Matter</div>
32
- <h3>Title</h3>
36
+ <div class="mdui-dialog-title">{{lang.editor.frontmatter.name}}</div>
37
+ <h3>{{lang.editor.frontmatter.title}}</h3>
33
38
  <div class="mdui-textfield">
34
39
  <input id="editorTitle" class="mdui-textfield-input" type="text"/>
35
40
  </div>
36
- <h3>Date</h3>
41
+ <h3>{{lang.editor.frontmatter.date}}</h3>
37
42
  <div class="mdui-textfield">
38
43
  <input id="editorDate" class="mdui-textfield-input datepicker" type="date"/>
39
44
  </div>
40
- <h3>Categories</h3>
45
+ <h3>{{lang.editor.frontmatter.categories}}</h3>
41
46
  <div class="mdui-row-md-4 mdui-row-sm-3">
42
47
  {% for c in sortedcategories %}
43
48
  <div class="mdui-col">
@@ -58,9 +63,9 @@
58
63
  </div>
59
64
  </div>
60
65
  </div>
61
- <h3>Tags</h3>
66
+ <h3>{{lang.editor.frontmatter.tags}}</h3>
62
67
  <div class="chips chips-initial"></div>
63
- <h3>Image</h3>
68
+ <h3>{{lang.editor.frontmatter.image}}</h3>
64
69
  <div class="mdui-textfield">
65
70
  <input id="imgurl" class="mdui-textfield-input" type="text" placeholder="imgUrl">
66
71
  </div>
@@ -69,7 +74,7 @@
69
74
 
70
75
  <div class="mdui-dialog" id="preview">
71
76
  <div class="mdui-dialog-content">
72
- <div class="mdui-dialog-title">Preview</div>
77
+ <div class="mdui-dialog-title">{{lang.editor.preview}}</div>
73
78
  <div class="mdui-card k-postcontent">
74
79
  <div class="mdui-card-media k-post-media">
75
80
  <div class="mdui-card-media-covered mdui-card-media-covered-gradient">
@@ -92,15 +97,15 @@
92
97
 
93
98
  <div class="mdui-card">
94
99
  <div class="mdui-card-content">
95
- <h3>Content</h3>
100
+ <h3>{{lang.editor.content}}</h3>
96
101
  <div class="mdui-textfield">
97
102
  <textarea id="editorContent" class="mdui-textfield-input" placeholder="Description"></textarea>
98
103
  </div>
99
104
  </div>
100
105
  <div class="mdui-card-actions">
101
- <a class="mdui-btn mdui-ripple" mdui-dialog="{target: '#frontMatter'}">Front Matter</a>
102
- <a id="previewBtn" class="mdui-btn mdui-ripple" mdui-dialog="{target: '#preview'}">Preview</a>
103
- <a id="download" class="mdui-btn mdui-ripple mdui-float-right">Download</a>
106
+ <a class="mdui-btn mdui-ripple" mdui-dialog="{target: '#frontMatter'}">{{lang.editor.frontmatter.name}}</a>
107
+ <a id="previewBtn" class="mdui-btn mdui-ripple" mdui-dialog="{target: '#preview'}">{{lang.editor.preview}}</a>
108
+ <a id="download" class="mdui-btn mdui-ripple mdui-float-right">{{lang.editor.download}}</a>
104
109
  </div>
105
110
  </div>
106
111
  </div>
@@ -51,7 +51,7 @@
51
51
  <div class="mdui-card-content mdui-typo">
52
52
  {{ content }}
53
53
  </div>
54
- {% include comment/disqus.html %}
54
+ {% include comment/comment.html %}
55
55
  </div>
56
56
  </div>
57
57
  <div class="mdui-col-md-3 mdui-hidden-sm-down">
@@ -49,7 +49,7 @@
49
49
  <div class="mdui-card-content mdui-typo">
50
50
  {{ content }}
51
51
  </div>
52
- {% include comment/disqus.html %}
52
+ {% include comment/comment.html %}
53
53
  </div>
54
54
  </div>
55
55
  </div>
data/_includes/head.html CHANGED
@@ -66,4 +66,14 @@ jQuery(document).ready(function($) {
66
66
  !function(a){"use strict";var b=function(b,c,d){function e(a){return h.body?a():void setTimeout(function(){e(a)})}function f(){i.addEventListener&&i.removeEventListener("load",f),i.media=d||"all"}var g,h=a.document,i=h.createElement("link");if(c)g=c;else{var j=(h.body||h.getElementsByTagName("head")[0]).childNodes;g=j[j.length-1]}var k=h.styleSheets;i.rel="stylesheet",i.href=b,i.media="only x",e(function(){g.parentNode.insertBefore(i,c?g:g.nextSibling)});var l=function(a){for(var b=i.href,c=k.length;c--;)if(k[c].href===b)return a();setTimeout(function(){l(a)})};return i.addEventListener&&i.addEventListener("load",f),i.onloadcssdefined=l,l(f),i};"undefined"!=typeof exports?exports.loadCSS=b:a.loadCSS=b}("undefined"!=typeof global?global:this); !function(a){"use strict";var b=function(b,c,d){function e(a){return h.body?a():void setTimeout(function(){e(a)})}function f(){i.addEventListener&&i.removeEventListener("load",f),i.media=d||"all"}var g,h=a.document,i=h.createElement("link");if(c)g=c;else{var j=(h.body||h.getElementsByTagName("head")[0]).childNodes;g=j[j.length-1]}var k=h.styleSheets;i.rel="stylesheet",i.href=b,i.media="only x",e(function(){g.parentNode.insertBefore(i,c?g:g.nextSibling)});var l=function(a){for(var b=i.href,c=k.length;c--;)if(k[c].href===b)return a();setTimeout(function(){l(a)})};return i.addEventListener&&i.addEventListener("load",f),i.onloadcssdefined=l,l(f),i};"undefined"!=typeof exports?exports.loadCSS=b:a.loadCSS=b}("undefined"!=typeof global?global:this);
67
67
  !function(a){if(a.loadCSS){var b=loadCSS.relpreload={};if(b.support=function(){try{return a.document.createElement("link").relList.supports("preload")}catch(b){return!1}},b.poly=function(){for(var b=a.document.getElementsByTagName("link"),c=0;c<b.length;c++){var d=b[c];"preload"===d.rel&&"style"===d.getAttribute("as")&&(a.loadCSS(d.href,d,d.getAttribute("media")),d.rel=null)}},!b.support()){b.poly();var c=a.setInterval(b.poly,300);a.addEventListener&&a.addEventListener("load",function(){b.poly(),a.clearInterval(c)}),a.attachEvent&&a.attachEvent("onload",function(){a.clearInterval(c)})}}}(this); !function(a){if(a.loadCSS){var b=loadCSS.relpreload={};if(b.support=function(){try{return a.document.createElement("link").relList.supports("preload")}catch(b){return!1}},b.poly=function(){for(var b=a.document.getElementsByTagName("link"),c=0;c<b.length;c++){var d=b[c];"preload"===d.rel&&"style"===d.getAttribute("as")&&(a.loadCSS(d.href,d,d.getAttribute("media")),d.rel=null)}},!b.support()){b.poly();var c=a.setInterval(b.poly,300);a.addEventListener&&a.addEventListener("load",function(){b.poly(),a.clearInterval(c)}),a.attachEvent&&a.attachEvent("onload",function(){a.clearInterval(c)})}}}(this);
68
68
  </script>
69
+ {% if site.data.site.mathjax ==true %}
70
+ <script type="text/x-mathjax-config;executed=true">
71
+ MathJax.Hub.Config({tex2jax:{processEscapes: true, inlineMath: [ ['$','$'], ["\\(","\\)"] ], skipTags: ['script', 'noscript', 'style', 'textarea', 'pre', 'code']}});
72
+ MathJax.Hub.Config({TeX:{extensions: ["cancel.js", "enclose.js"],
73
+ Macros:{a:"\\alpha",b:"\\beta",c:"\\chi",d:"\\delta",e:"\\epsilon",f:"\\phi",g:"\\gamma",h:"\\eta",i:"\\iota",j:"\\varphi",k:"\\kappa",l:"\\lambda",m:"\\mu",n:"\\nu",o:"\\omicron",p:"\\pi",q:"\\theta",r:"\\rho",s:"\\sigma",t:"\\tau",u:"\\upsilon",v:"\\varpi",w:"\\omega",x:"\\xi",y:"\\psi",z:"\\zeta",D:"\\Delta",F:"\\Phi",G:"\\Gamma",J:"\\vartheta",L:"\\Lambda",P:"\\Pi",Q:"\\Theta",S:"\\Sigma",U:"\\Upsilon",V:"\\varsigma",W:"\\Omega",X:"\\Xi",Y:"\\Psi",ve:"\\varepsilon",vk:"\\varkappa",vq:"\\vartheta",vp:"\\varpi",vr:"\\varrho",vs:"\\varsigma",vf:"\\varphi",alg:"\\begin{align}", ealg:"\\end{align}",bmat:"\\begin{bmatrix}", Bmat:"\\begin{Bmatrix}", pmat:"\\begin{pmatrix}", Pmat:"\\begin{Pmatrix}", vmat:"\\begin{vmatrix}", Vmat:"\\begin{Vmatrix}",ebmat:"\\end{bmatrix}", eBmat:"\\end{Bmatrix}", epmat:"\\end{pmatrix}", ePmat:"\\end{Pmatrix}", evmat:"\\end{vmatrix}", eVmat:"\\end{Vmatrix}",AA:"\\unicode{x212B}", Sum:"\\sum\\limits", abs:['\\lvert #1\\rvert',1], rmd:['\\mathop{\\mathrm{d}#1}',1],bi:['\\boldsymbol{#1}', 1], obar:['0\\!\\!\\!\\raise{.05em}{-}'],opar:['\\frac{\\partial #1}{\\partial #2}', 2], oppar:['\\frac{\\partial^2 #1}{\\partial #2^2}', 2]}}});
74
+ MathJax.Hub.Queue(function(){
75
+ var all=MathJax.Hub.getAllJax(),i;for(i=0;i<all.length;i+=1){all[i].SourceElement().parentNode.className+=' has-jax';}});
76
+ </script>
77
+ <script src="//cdn.bootcss.com/mathjax/2.7.1/MathJax.js?config=TeX-AMS_CHTML"></script>
78
+ {% endif %}
69
79
  </head>
@@ -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.4.9 | 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.0 | 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>
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.4.9.9
4
+ version: 0.5.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - KeJun
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-06-30 00:00:00.000000000 Z
11
+ date: 2017-07-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
@@ -76,7 +76,9 @@ files:
76
76
  - LICENSE.txt
77
77
  - README.md
78
78
  - _includes/analytics/google.html
79
+ - _includes/comment/comment.html
79
80
  - _includes/comment/disqus.html
81
+ - _includes/comment/livere.html
80
82
  - _includes/component/nprogress.html
81
83
  - _includes/component/sw.html
82
84
  - _includes/content/component/highlight.html