From c5d794b993ac990a01f03b0f74e9c80dff8a7626 Mon Sep 17 00:00:00 2001 From: Mimi Date: Thu, 8 Nov 2018 01:09:48 +0800 Subject: [PATCH 1/2] Update _config.yml --- _config.yml | 68 ++++++++++++++++++++++++++++++----------------------- 1 file changed, 38 insertions(+), 30 deletions(-) diff --git a/_config.yml b/_config.yml index 21f1a3ad1f..294f1164b3 100644 --- a/_config.yml +++ b/_config.yml @@ -88,7 +88,7 @@ footer: version: true # ------------------------------------------------------------- # Beian icp information for Chinese users. In China, every legal website should have a beian icp in website footer. - # http://www.miitbeian.gov.cn/ + # http://www.miitbeian.gov.cn beian: enable: false icp: @@ -98,7 +98,7 @@ footer: #custom_text: Hosted by Coding Pages # Creative Commons 4.0 International License. -# https://creativecommons.org/share-your-work/licensing-types-examples/ +# https://creativecommons.org/share-your-work/licensing-types-examples # Available: by | by-nc | by-nc-nd | by-nc-sa | by-nd | by-sa | zero creative_commons: license: by-nc-sa @@ -203,7 +203,7 @@ links_title: Links links_layout: block #links_layout: inline #links: - #Title: http://example.com/ + #Title: http://example.com # Sidebar Avatar avatar: @@ -480,10 +480,13 @@ pdf: # If you set it to false, it will load PDFObject/PDF.js srcipt EVERY PAGE. per_page: true + height: 500px + pdfobject: - # Use 2.1.1 as default, cloudflare as default CDN - cdn: //cdnjs.cloudflare.com/ajax/libs/pdfobject/2.1.1/pdfobject.min.js - height: 500px + # Use 2.1.1 as default, jsdelivr as default CDN, works everywhere even in China + cdn: //cdn.jsdelivr.net/npm/pdfobject@2.1.1/pdfobject.min.js + # CDNJS, provided by cloudflare, maybe the best CDN, but not works in China + #cdn: //cdnjs.cloudflare.com/ajax/libs/pdfobject/2.1.1/pdfobject.min.js # Han Support # Dependencies: https://github.com/theme-next/theme-next-han @@ -538,7 +541,7 @@ valine: #livere_uid: your uid # Gitment -# Introduction: https://imsun.net/posts/gitment-introduction/ +# Introduction: https://imsun.net/posts/gitment-introduction gitment: enable: false mint: true # RECOMMEND, A mint on Gitment, to support count, language and proxy_gateway @@ -560,7 +563,7 @@ gitment: #baidushare: ## type: button -# addthis Share, see: https://www.addthis.com/ +# addthis Share, see: https://www.addthis.com #add_this_id: # NeedMoreShare2 @@ -592,29 +595,29 @@ needmoreshare2: networks: Weibo,Wechat,Douban,QQZone,Twitter,Facebook # Google Webmaster tools verification setting -# See: https://www.google.com/webmasters/ +# See: https://www.google.com/webmasters #google_site_verification: # Google Analytics #google_analytics: # Bing Webmaster tools verification setting -# See: https://www.bing.com/webmaster/ +# See: https://www.bing.com/webmaster #bing_site_verification: # Yandex Webmaster tools verification setting -# See: https://webmaster.yandex.ru/ +# See: https://webmaster.yandex.ru #yandex_site_verification: # Baidu Webmaster tools verification setting -# See: https://ziyuan.baidu.com/site/ +# See: https://ziyuan.baidu.com/site #baidu_site_verification: # CNZZ count #cnzz_siteid: # Application Insights -# See https://azure.microsoft.com/en-us/services/application-insights/ +# See https://azure.microsoft.com/en-us/services/application-insights # application_insights: # Post widgets & FB/VK comments settings. @@ -677,7 +680,7 @@ firestore: bluebird: false #enable this if you want to include bluebird 3.5.1(core version) Promise polyfill # Show Views/Visitors of the website/page with busuanzi. -# Get more information on http://ibruce.info/2015/04/04/busuanzi/ +# Get more information on http://ibruce.info/2015/04/04/busuanzi busuanzi_count: enable: false total_visitors: true @@ -704,7 +707,7 @@ baidu_push: false # API Documentation: # https://developers.google.com/google-apps/calendar/v3/reference/events/list # Enabled APIs and services -# api_key: https://console.developers.google.com/ +# api_key: https://console.developers.google.com # Create & manage a public Google calendar: https://support.google.com/calendar/answer/37083?hl=en calendar: enable: false @@ -897,7 +900,7 @@ vendors: jquery: # Internal version: 2.1.5 - # See: http://fancyapps.com/fancybox/ + # See: http://fancyapps.com/fancybox # Example: # fancybox: //cdn.jsdelivr.net/npm/fancybox@3.0.0/dist/js/jquery.fancybox.pack.js # fancybox_css: //cdn.jsdelivr.net/npm/fancybox@3.0.0/dist/css/jquery.fancybox.min.css @@ -910,11 +913,14 @@ vendors: # See: https://github.com/ftlabs/fastclick # Example: # fastclick: //cdn.jsdelivr.net/npm/fastclick@1.0.6/lib/fastclick.min.js + # fastclick: //cdnjs.cloudflare.com/ajax/libs/fastclick/1.0.6/fastclick.min.js fastclick: # Internal version: 1.9.7 # See: https://github.com/tuupola/jquery_lazyload - # lazyload: //cdn.jsdelivr.net/npm/jquery_lazyload@1.9.3/jquery.lazyload.min.js + # Example: + # lazyload: //cdn.jsdelivr.net/npm/jquery_lazyload@1.9.7/jquery.lazyload.min.js + # lazyload: //cdnjs.cloudflare.com/ajax/libs/jquery_lazyload/1.9.7/jquery.lazyload.min.js lazyload: # Internal version: 1.2.1 @@ -926,26 +932,27 @@ vendors: # Internal version: 1.2.1 # See: http://VelocityJS.org + # Example: # velocity_ui: //cdn.jsdelivr.net/npm/velocity-animate@1.2.1/velocity.ui.min.js # velocity_ui: //cdnjs.cloudflare.com/ajax/libs/velocity/1.2.1/velocity.ui.min.js velocity_ui: # Internal version: 0.7.9 - # See: https://faisalman.github.io/ua-parser-js/ + # See: https://faisalman.github.io/ua-parser-js # Example: # ua_parser: //cdn.jsdelivr.net/npm/ua-parser-js@0.7.17/src/ua-parser.min.js # ua_parser: //cdnjs.cloudflare.com/ajax/libs/UAParser.js/0.7.9/ua-parser.min.js ua_parser: # Internal version: 4.6.2 - # See: http://fontawesome.io/ + # See: http://fontawesome.io # Example: # fontawesome: //cdn.jsdelivr.net/npm/font-awesome@4.7.0/css/font-awesome.min.css # fontawesome: //cdnjs.cloudflare.com/ajax/libs/font-awesome/4.6.2/css/font-awesome.min.css fontawesome: - # Internal version: 1 - # https://www.algolia.com + # Internal version: 2.4.1 + # See: https://www.algolia.com # Example: # algolia_instant_js: //cdn.jsdelivr.net/npm/instantsearch.js@2.4.1/dist/instantsearch.js # algolia_instant_css: //cdn.jsdelivr.net/npm/instantsearch.js@2.4.1/dist/instantsearch.min.css @@ -983,22 +990,22 @@ vendors: canvas_sphere: # Internal version: 1.0.0 - # https://github.com/zproo/canvas-ribbon + # See: https://github.com/zproo/canvas-ribbon canvas_ribbon: # Internal version: 3.3.0 - # https://github.com/ethantw/Han + # See: https://github.com/ethantw/Han Han: # Internal version: 3.3.0 - # https://github.com/vinta/pangu.js + # See: https://github.com/vinta/pangu.js # Example: # pangu: //cdn.jsdelivr.net/npm/pangu@3.3.0/dist/browser/pangu.min.js # pangu: //cdnjs.cloudflare.com/ajax/libs/pangu/3.3.0/pangu.min.js pangu: # needMoreShare2 - # https://github.com/revir/need-more-share2 + # See: https://github.com/revir/need-more-share2 # Example: # needmoreshare2_js: //cdn.jsdelivr.net/gh/theme-next/theme-next-needmoreshare2@1.0.0/needsharebutton.min.js # needmoreshare2_css: //cdn.jsdelivr.net/gh/theme-next/theme-next-needmoreshare2@1.0.0/needsharebutton.min.css @@ -1006,21 +1013,22 @@ vendors: needmoreshare2_css: # bookmark - # Internal version: 1.0.0 - # https://github.com/theme-next/theme-next-bookmark + # See: https://github.com/theme-next/theme-next-bookmark # Example: # bookmark: //cdn.jsdelivr.net/gh/theme-next/theme-next-bookmark@1.0.0/bookmark.min.js bookmark: # reading_progress - # Internal version: 1.0 - # https://github.com/theme-next/theme-next-reading-progress + # See: https://github.com/theme-next/theme-next-reading-progress # Example: # reading_progress: //cdn.jsdelivr.net/gh/theme-next/theme-next-reading-progress@1.1/reading_progress.min.js reading_progress: # valine comment - # Example: https://cdn.jsdelivr.net/npm/valine@1.1.8/dist/Valine.min.js + # See: https://github.com/xCss/Valine + # Example: + # valine: //cdn.jsdelivr.net/npm/valine@1.3.3/dist/Valine.min.js + # valine: //cdnjs.cloudflare.com/ajax/libs/valine/1.3.3/Valine.min.js valine: From ec446b00a3e0eb1487c91b6c9f3ba9a92c171106 Mon Sep 17 00:00:00 2001 From: Mimi Date: Thu, 8 Nov 2018 01:10:11 +0800 Subject: [PATCH 2/2] Update pdf.swig --- layout/_third-party/pdf.swig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/layout/_third-party/pdf.swig b/layout/_third-party/pdf.swig index 7bf8c838e6..8a0376e6f5 100644 --- a/layout/_third-party/pdf.swig +++ b/layout/_third-party/pdf.swig @@ -22,7 +22,7 @@ view: "FitV" }, PDFJS_URL: "/lib/pdf/web/viewer.html", - height: "{{ theme.pdf.pdfobject.height }}" + height: "{{ theme.pdf.height }}" }; $("#main a").each(function() { var href = $(this).attr("href"); @@ -39,7 +39,7 @@ position: relative; overflow: auto; width: 100%; - height: {{ theme.pdf.pdfobject.height }}; + height: {{ theme.pdf.height }}; } {% endif %}