hexo
This commit is contained in:
70
themes/next/layout/_partials/comments.swig
Normal file
70
themes/next/layout/_partials/comments.swig
Normal file
@ -0,0 +1,70 @@
|
||||
{% if page.comments %}
|
||||
|
||||
{% if (theme.duoshuo and theme.duoshuo.shortname) or theme.duoshuo_shortname %}
|
||||
<div class="comments" id="comments">
|
||||
<div class="ds-thread" data-thread-key="{{ page.path }}"
|
||||
data-title="{{ page.title }}" data-url="{{ page.permalink }}">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% elseif theme.facebook_sdk.enable and theme.facebook_comments_plugin.enable %}
|
||||
<div class="comments" id="comments">
|
||||
<div class="fb-comments"
|
||||
data-href="{{ page.permalink }}"
|
||||
data-numposts="{{ theme.facebook_comments_plugin.num_of_posts }}"
|
||||
data-width="{{ theme.facebook_comments_plugin.width }}"
|
||||
data-colorscheme="{{ theme.facebook_comments_plugin.scheme }}">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% elseif theme.vkontakte_api.enable and theme.vkontakte_api.comments %}
|
||||
<div class="comments" id="comments">
|
||||
<div id="vk_comments"></div>
|
||||
</div>
|
||||
|
||||
{% elseif theme.disqus.enable %}
|
||||
<div class="comments" id="comments">
|
||||
<div id="disqus_thread">
|
||||
<noscript>
|
||||
Please enable JavaScript to view the
|
||||
<a href="https://disqus.com/?ref_noscript">comments powered by Disqus.</a>
|
||||
</noscript>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% elseif theme.hypercomments_id %}
|
||||
<div class="comments" id="comments">
|
||||
<div id="hypercomments_widget"></div>
|
||||
</div>
|
||||
|
||||
{% elseif theme.youyan_uid %}
|
||||
<div class="comments" id="comments">
|
||||
<div id="uyan_frame"></div>
|
||||
</div>
|
||||
|
||||
{% elseif theme.livere_uid %}
|
||||
<div class="comments" id="comments">
|
||||
<div id="lv-container" data-id="city" data-uid="{{ theme.livere_uid }}"></div>
|
||||
</div>
|
||||
|
||||
{% elseif theme.changyan.appid and theme.changyan.appkey %}
|
||||
<div class="comments" id="comments">
|
||||
<div id="SOHUCS"></div>
|
||||
</div>
|
||||
|
||||
{% elseif theme.gitment.enable %}
|
||||
<div class="comments" id="comments">
|
||||
{% if theme.gitment.lazy %}
|
||||
<div onclick="showGitment()" id="gitment-display-button">{{ __('gitmentbutton') }}</div>
|
||||
<div id="gitment-container" style="display:none"></div>
|
||||
{% else %}
|
||||
<div id="gitment-container"></div>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
{% elseif theme.valine.appid and theme.valine.appkey %}
|
||||
<div class="comments" id="comments">
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
{% endif %}
|
47
themes/next/layout/_partials/footer.swig
Normal file
47
themes/next/layout/_partials/footer.swig
Normal file
@ -0,0 +1,47 @@
|
||||
<div class="copyright">{#
|
||||
#}{% set current = date(Date.now(), "YYYY") %}{#
|
||||
#}© {% if theme.footer.since and theme.footer.since != current %}{{ theme.footer.since }} — {% endif %}{#
|
||||
#}<span itemprop="copyrightYear">{{ current }}</span>
|
||||
<span class="with-love">
|
||||
<i class="fa fa-{{ theme.footer.icon }}"></i>
|
||||
</span>
|
||||
<span class="author" itemprop="copyrightHolder">{{ theme.footer.copyright || config.author }}</span>
|
||||
|
||||
{% if theme.post_wordcount.totalcount %}
|
||||
<span class="post-meta-divider">|</span>
|
||||
<span class="post-meta-item-icon">
|
||||
<i class="fa fa-area-chart"></i>
|
||||
</span>
|
||||
{% if theme.post_wordcount.item_text %}
|
||||
<span class="post-meta-item-text">{{ __('post.totalcount') }}:</span>
|
||||
{% endif %}
|
||||
<span title="{{ __('post.totalcount') }}">{#
|
||||
#}{{ totalcount(site, '0,0.0a') }}{#
|
||||
#}</span>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
{% if theme.footer.powered %}
|
||||
<div class="powered-by">{#
|
||||
#}{{ __('footer.powered', '<a class="theme-link" target="_blank" href="https://hexo.io">Hexo</a>') }}{#
|
||||
#}</div>
|
||||
{% endif %}
|
||||
|
||||
{% if theme.footer.powered and theme.footer.theme.enable %}
|
||||
<span class="post-meta-divider">|</span>
|
||||
{% endif %}
|
||||
|
||||
{% if theme.footer.theme.enable %}
|
||||
<div class="theme-info">{#
|
||||
#}{{ __('footer.theme') }} — {#
|
||||
#}<a class="theme-link" target="_blank" href="https://github.com/iissnan/hexo-theme-next">{#
|
||||
#}NexT.{{ theme.scheme }}{#
|
||||
#}</a>{% if theme.footer.theme.version %} v{{ theme.version }}{% endif %}{#
|
||||
#}</div>
|
||||
{% endif %}
|
||||
|
||||
{% if theme.footer.custom_text %}
|
||||
<div class="footer-custom">{#
|
||||
#}{{ theme.footer.custom_text }}{#
|
||||
#}</div>
|
||||
{% endif %}
|
158
themes/next/layout/_partials/head.swig
Normal file
158
themes/next/layout/_partials/head.swig
Normal file
@ -0,0 +1,158 @@
|
||||
<meta charset="UTF-8"/>
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1"/>
|
||||
<meta name="theme-color" content="{{ theme.android_chrome_color }}">
|
||||
|
||||
|
||||
{% if theme.pace %}
|
||||
{% set pace_css_uri = url_for(theme.vendors._internal + '/pace/'+ theme.pace_theme +'.min.css?v=1.0.2') %}
|
||||
{% set pace_js_uri = url_for(theme.vendors._internal + '/pace/pace.min.js?v=1.0.2') %}
|
||||
{% if theme.vendors.pace %}
|
||||
{% set pace_js_uri = theme.vendors.pace %}
|
||||
{% endif %}
|
||||
{% if theme.vendors.pace_css %}
|
||||
{% set pace_css_uri = theme.vendors.pace_css %}
|
||||
{% endif %}
|
||||
<script src="{{ pace_js_uri }}"></script>
|
||||
<link href="{{ pace_css_uri }}" rel="stylesheet">
|
||||
{% endif %}
|
||||
|
||||
|
||||
{% if theme.han %}
|
||||
{% set Han_uri = url_for(theme.vendors._internal + '/Han/dist/han.min.css?v=3.3') %}
|
||||
{% if theme.vendors.Han %}
|
||||
{% set Han_uri = theme.vendors.Han %}
|
||||
{% endif %}
|
||||
<link rel="stylesheet" media="all" href="{{ Han_uri }}">
|
||||
{% endif %}
|
||||
|
||||
|
||||
{# #238, Disable Baidu tranformation #}
|
||||
<meta http-equiv="Cache-Control" content="no-transform" />
|
||||
<meta http-equiv="Cache-Control" content="no-siteapp" />
|
||||
|
||||
|
||||
{% if theme.google_site_verification %}
|
||||
<meta name="google-site-verification" content="{{ theme.google_site_verification }}" />
|
||||
{% endif %}
|
||||
|
||||
{% if theme.bing_site_verification %}
|
||||
<meta name="msvalidate.01" content="{{ theme.bing_site_verification }}" />
|
||||
{% endif %}
|
||||
|
||||
{% if theme.yandex_site_verification %}
|
||||
<meta name="yandex-verification" content="{{ theme.yandex_site_verification }}" />
|
||||
{% endif %}
|
||||
|
||||
|
||||
{% if theme.baidu_site_verification %}
|
||||
<meta name="baidu-site-verification" content="{{ theme.baidu_site_verification }}" />
|
||||
{% endif %}
|
||||
|
||||
|
||||
{% if theme.qihu_site_verification %}
|
||||
<meta name="360-site-verification" content="{{ theme.qihu_site_verification }}" />
|
||||
{% endif %}
|
||||
|
||||
|
||||
{% if theme.fancybox %}
|
||||
{% set fancybox_css_uri = url_for(theme.vendors._internal + '/fancybox/source/jquery.fancybox.css?v=2.1.5') %}
|
||||
{% if theme.vendors.fancybox_css %}
|
||||
{% set fancybox_css_uri = theme.vendors.fancybox_css %}
|
||||
{% endif %}
|
||||
<link href="{{ fancybox_css_uri }}" rel="stylesheet" type="text/css" />
|
||||
{% endif %}
|
||||
|
||||
{% include "./head/external-fonts.swig" %}
|
||||
|
||||
{% set font_awesome_uri = url_for(theme.vendors._internal + '/font-awesome/css/font-awesome.min.css?v=4.6.2') %}
|
||||
{% if theme.vendors.fontawesome %}
|
||||
{% set font_awesome_uri = theme.vendors.fontawesome %}
|
||||
{% endif %}
|
||||
<link href="{{ font_awesome_uri }}" rel="stylesheet" type="text/css" />
|
||||
|
||||
<link href="{{ url_for(theme.css) }}/main.css?v={{ theme.version }}" rel="stylesheet" type="text/css" />
|
||||
|
||||
{% if theme.favicon.apple_touch_icon %}
|
||||
<link rel="apple-touch-icon" sizes="180x180" href="{{ url_for(theme.favicon.apple_touch_icon) }}?v={{ theme.version }}">
|
||||
{% endif %}
|
||||
{% if theme.favicon.medium %}
|
||||
<link rel="icon" type="image/png" sizes="32x32" href="{{ url_for(theme.favicon.medium) }}?v={{ theme.version }}">
|
||||
{% endif %}
|
||||
{% if theme.favicon.small %}
|
||||
<link rel="icon" type="image/png" sizes="16x16" href="{{ url_for(theme.favicon.small) }}?v={{ theme.version }}">
|
||||
{% endif %}
|
||||
{% if theme.favicon.safari_pinned_tab %}
|
||||
<link rel="mask-icon" href="{{ url_for(theme.favicon.safari_pinned_tab) }}?v={{ theme.version }}" color="{{ theme.android_chrome_color }}">
|
||||
{% endif %}
|
||||
{% if theme.favicon.android_manifest %}
|
||||
<link rel="manifest" href="{{ url_for(theme.favicon.android_manifest) }}">
|
||||
{% endif %}
|
||||
{% if theme.favicon.ms_browserconfig %}
|
||||
<meta name="msapplication-config" content="{{ url_for(theme.favicon.ms_browserconfig) }}" />
|
||||
{% endif %}
|
||||
|
||||
{% if page.keywords %}
|
||||
<meta name="keywords" content="{{ page.keywords }}" />
|
||||
{% elif page.tags and page.tags.length %}
|
||||
<meta name="keywords" content="{% for tag in page.tags %}{{ tag.name }},{% endfor %}" />
|
||||
{% elif theme.keywords %}
|
||||
<meta name="keywords" content="{{ theme.keywords }}" />
|
||||
{% endif %}
|
||||
|
||||
|
||||
{% if theme.rss === '' and config.feed and config.feed.path %}
|
||||
{% set theme.rss = config.feed.path %}
|
||||
{% endif %}
|
||||
{% if theme.rss %}
|
||||
<link rel="alternate" href="{{ url_for(theme.rss) }}" title="{{ config.title }}" type="application/atom+xml" />
|
||||
{% endif %}
|
||||
|
||||
|
||||
{% if theme.facebook_sdk.enable and theme.facebook_sdk.webmaster %}
|
||||
<meta property="fb:admins" content="{{ theme.facebook_sdk.fb_admin }}" />
|
||||
<meta property="fb:app_id" content="{{ theme.facebook_sdk.app_id }}" />
|
||||
{% endif %}
|
||||
|
||||
|
||||
{{
|
||||
open_graph({
|
||||
twitter_id: theme.twitter,
|
||||
google_plus: theme.google_plus,
|
||||
fb_admins: theme.fb_admins,
|
||||
fb_app_id: theme.fb_app_id
|
||||
})
|
||||
}}
|
||||
|
||||
|
||||
{# Export some HEXO Configurations to Front-End #}
|
||||
<script type="text/javascript" id="hexo.configurations">
|
||||
var NexT = window.NexT || {};
|
||||
var CONFIG = {
|
||||
root: '{{ theme.root }}',
|
||||
scheme: '{{ theme.scheme }}',
|
||||
version: '{{ theme.version }}',
|
||||
sidebar: {{ theme.sidebar | json_encode }},
|
||||
fancybox: {{ theme.fancybox }},
|
||||
tabs: {{ theme.tabs.enable }},
|
||||
motion: {{ theme.motion | json_encode }},
|
||||
duoshuo: {
|
||||
userId: '{{ theme.duoshuo_info.user_id | default() }}',
|
||||
author: '{{ theme.duoshuo_info.admin_nickname | default(__('author'))}}'
|
||||
},
|
||||
algolia: {
|
||||
applicationID: '{{ theme.algolia.applicationID }}',
|
||||
apiKey: '{{ theme.algolia.apiKey }}',
|
||||
indexName: '{{ theme.algolia.indexName }}',
|
||||
hits: {{ theme.algolia_search.hits | json_encode }},
|
||||
labels: {{ theme.algolia_search.labels | json_encode }}
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
{# Canonical, good for google search engine (SEO) : https://support.google.com/webmasters/answer/139066 #}
|
||||
{% if theme.canonical %}
|
||||
<link rel="canonical" href="{{ config.url }}/{{ page.canonical_path.replace('index.html', '') }}"/>
|
||||
{% endif %}
|
||||
|
||||
{% include 'head/custom-head.swig' %}
|
3
themes/next/layout/_partials/head/custom-head.swig
Normal file
3
themes/next/layout/_partials/head/custom-head.swig
Normal file
@ -0,0 +1,3 @@
|
||||
{#
|
||||
Custom head.
|
||||
#}
|
51
themes/next/layout/_partials/head/external-fonts.swig
Normal file
51
themes/next/layout/_partials/head/external-fonts.swig
Normal file
@ -0,0 +1,51 @@
|
||||
{% if theme.font.enable %}
|
||||
|
||||
{% set font_config = theme.font %}
|
||||
{% set font_families = '' %}
|
||||
{% set font_styles = ':300,300italic,400,400italic,700,700italic' %}
|
||||
{% set font_found = false %}
|
||||
|
||||
{% if font_config.global.family and font_config.global.external %}
|
||||
{% set font_families += font_config.global.family + font_styles %}
|
||||
{% set font_found = true %}
|
||||
{% endif %}
|
||||
|
||||
{% if font_config.headings.family and font_config.headings.external %}
|
||||
{% if font_found %}
|
||||
{% set font_families += '|' %}
|
||||
{% endif %}
|
||||
|
||||
{% set font_families += font_config.headings.family + font_styles %}
|
||||
{% endif %}
|
||||
|
||||
{% if font_config.posts.family and font_config.posts.external %}
|
||||
{% if font_found %}
|
||||
{% set font_families += '|' %}
|
||||
{% endif %}
|
||||
|
||||
{% set font_families += font_config.posts.family + font_styles %}
|
||||
{% endif %}
|
||||
|
||||
{% if font_config.logo.family and font_config.logo.external %}
|
||||
{% if font_found %}
|
||||
{% set font_families += '|' %}
|
||||
{% endif %}
|
||||
|
||||
{% set font_families += font_config.logo.family + font_styles %}
|
||||
{% endif %}
|
||||
|
||||
{% if font_config.codes.family and font_config.codes.external %}
|
||||
{% if font_found %}
|
||||
{% set font_families += '|' %}
|
||||
{% endif %}
|
||||
|
||||
{% set font_families += font_config.codes.family + font_styles %}
|
||||
{% endif %}
|
||||
|
||||
{% if font_families !== '' %}
|
||||
{% set font_families += '&subset=latin,latin-ext' %}
|
||||
{% set font_host = font_config.host | default('//fonts.googleapis.com') %}
|
||||
<link href="{{ font_host }}/css?family={{ font_families }}" rel="stylesheet" type="text/css">
|
||||
{% endif %}
|
||||
|
||||
{% endif %}
|
76
themes/next/layout/_partials/header.swig
Normal file
76
themes/next/layout/_partials/header.swig
Normal file
@ -0,0 +1,76 @@
|
||||
<div class="site-brand-wrapper">
|
||||
<div class="site-meta {% if theme.custom_logo.enabled %}custom-logo{% endif %}">
|
||||
{% if theme.custom_logo.image and theme.scheme === 'Muse' %}
|
||||
<div class="site-meta-headline">
|
||||
<a>
|
||||
<img class="custom-logo-image" src="{{ theme.custom_logo.image }}"
|
||||
alt="{{ config.title }}"/>
|
||||
</a>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<div class="custom-logo-site-title">
|
||||
<a href="{{ config.root }}" class="brand" rel="start">
|
||||
<span class="logo-line-before"><i></i></span>
|
||||
<span class="site-title">{{ config.title }}</span>
|
||||
<span class="logo-line-after"><i></i></span>
|
||||
</a>
|
||||
</div>
|
||||
{% if theme.seo %}
|
||||
<h1 class="site-subtitle" itemprop="description">{{ config.subtitle }}</h1>
|
||||
{% else %}
|
||||
<p class="site-subtitle">{{ config.subtitle }}</p>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
<div class="site-nav-toggle">
|
||||
<button>
|
||||
<span class="btn-bar"></span>
|
||||
<span class="btn-bar"></span>
|
||||
<span class="btn-bar"></span>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<nav class="site-nav">
|
||||
{% set hasSearch = theme.swiftype_key || theme.algolia_search.enable || theme.tinysou_Key || theme.local_search.enable %}
|
||||
|
||||
{% if theme.menu %}
|
||||
<ul id="menu" class="menu">
|
||||
{% for name, path in theme.menu %}
|
||||
{% set itemName = name.toLowerCase() %}
|
||||
<li class="menu-item menu-item-{{ itemName | replace(' ', '-') }}">
|
||||
<a href="{{ url_for(path.split('||')[0]) | trim }}" rel="section">
|
||||
{% if theme.menu_icons.enable %}
|
||||
<i class="menu-item-icon fa fa-fw fa-{{ path.split('||')[1] | trim | default('question-circle') }}"></i> <br />
|
||||
{% endif %}
|
||||
{{ __('menu.' + name) | replace('menu.', '') }}
|
||||
</a>
|
||||
</li>
|
||||
{% endfor %}
|
||||
|
||||
{% if hasSearch %}
|
||||
<li class="menu-item menu-item-search">
|
||||
{% if theme.swiftype_key %}
|
||||
<a href="javascript:;" class="st-search-show-outputs">
|
||||
{% elseif theme.local_search.enable || theme.algolia_search.enable %}
|
||||
<a href="javascript:;" class="popup-trigger">
|
||||
{% endif %}
|
||||
{% if theme.menu_icons.enable %}
|
||||
<i class="menu-item-icon fa fa-search fa-fw"></i> <br />
|
||||
{% endif %}
|
||||
{{ __('menu.search') }}
|
||||
</a>
|
||||
</li>
|
||||
{% endif %}
|
||||
</ul>
|
||||
{% endif %}
|
||||
|
||||
{% if hasSearch %}
|
||||
<div class="site-search">
|
||||
{% include 'search.swig' %}
|
||||
</div>
|
||||
{% endif %}
|
||||
</nav>
|
||||
|
||||
{% include '../_custom/header.swig' %}
|
11
themes/next/layout/_partials/page-header.swig
Normal file
11
themes/next/layout/_partials/page-header.swig
Normal file
@ -0,0 +1,11 @@
|
||||
<header class="post-header">
|
||||
|
||||
<{% if theme.seo %}h2{% else %}h1{% endif %} class="post-title" itemprop="name headline">{{ page.title }}</{% if theme.seo %}h2{% else %}h1{% endif %}>
|
||||
|
||||
{% if page.description %}
|
||||
<div class="post-meta">
|
||||
<div class="post-description">{{ page.description }}</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
</header>
|
11
themes/next/layout/_partials/pagination.swig
Normal file
11
themes/next/layout/_partials/pagination.swig
Normal file
@ -0,0 +1,11 @@
|
||||
{% if page.prev or page.next %}
|
||||
<nav class="pagination">
|
||||
{{
|
||||
paginator({
|
||||
prev_text: '<i class="fa fa-angle-left"></i>',
|
||||
next_text: '<i class="fa fa-angle-right"></i>',
|
||||
mid_size: 1
|
||||
})
|
||||
}}
|
||||
</nav>
|
||||
{% endif %}
|
9
themes/next/layout/_partials/search.swig
Normal file
9
themes/next/layout/_partials/search.swig
Normal file
@ -0,0 +1,9 @@
|
||||
{% if theme.algolia_search.enable %}
|
||||
{% include '../_third-party/search/algolia-search/dom.swig' %}
|
||||
{% elseif theme.swiftype_key %}
|
||||
{% include 'search/swiftype.swig' %}
|
||||
{% elseif theme.tinysou_Key %}
|
||||
{% include 'search/tinysou.swig' %}
|
||||
{% elseif theme.local_search.enable %}
|
||||
{% include 'search/localsearch.swig' %}
|
||||
{% endif %}
|
16
themes/next/layout/_partials/search/localsearch.swig
Normal file
16
themes/next/layout/_partials/search/localsearch.swig
Normal file
@ -0,0 +1,16 @@
|
||||
<div class="popup search-popup local-search-popup">
|
||||
<div class="local-search-header clearfix">
|
||||
<span class="search-icon">
|
||||
<i class="fa fa-search"></i>
|
||||
</span>
|
||||
<span class="popup-btn-close">
|
||||
<i class="fa fa-times-circle"></i>
|
||||
</span>
|
||||
<div class="local-search-input-wrapper">
|
||||
<input autocomplete="off"
|
||||
placeholder="{{ __('search.placeholder') }}" spellcheck="false"
|
||||
type="text" id="local-search-input">
|
||||
</div>
|
||||
</div>
|
||||
<div id="local-search-result"></div>
|
||||
</div>
|
12
themes/next/layout/_partials/search/swiftype.swig
Normal file
12
themes/next/layout/_partials/search/swiftype.swig
Normal file
@ -0,0 +1,12 @@
|
||||
<form class="site-search-form">
|
||||
<input type="text" id="st-search-input" class="st-search-input st-default-search-input" />
|
||||
</form>
|
||||
|
||||
<script type="text/javascript">
|
||||
(function(w,d,t,u,n,s,e){w['SwiftypeObject']=n;w[n]=w[n]||function(){
|
||||
(w[n].q=w[n].q||[]).push(arguments);};s=d.createElement(t);
|
||||
e=d.getElementsByTagName(t)[0];s.async=1;s.src=u;e.parentNode.insertBefore(s,e);
|
||||
})(window,document,'script','//s.swiftypecdn.com/install/v2/st.js','_st');
|
||||
|
||||
_st('install', '{{ theme.swiftype_key }}','2.0.0');
|
||||
</script>
|
3
themes/next/layout/_partials/search/tinysou.swig
Normal file
3
themes/next/layout/_partials/search/tinysou.swig
Normal file
@ -0,0 +1,3 @@
|
||||
<form class="site-search-form" >
|
||||
<input type="text" id="ts-search-input" class="menu-search-input">
|
||||
</form>
|
4
themes/next/layout/_partials/share/add-this.swig
Normal file
4
themes/next/layout/_partials/share/add-this.swig
Normal file
@ -0,0 +1,4 @@
|
||||
<!-- Go to www.addthis.com/dashboard to customize your tools -->
|
||||
<div class="addthis_inline_share_toolbox">
|
||||
<script type = "text/javascript" src = "//s7.addthis.com/js/300/addthis_widget.js#pubid={{ theme.add_this_id }}" async = "async" ></script>
|
||||
</div>
|
57
themes/next/layout/_partials/share/baidushare.swig
Normal file
57
themes/next/layout/_partials/share/baidushare.swig
Normal file
@ -0,0 +1,57 @@
|
||||
{% if theme.baidushare.type === "button" %}
|
||||
<div class="bdsharebuttonbox">
|
||||
<a href="#" class="bds_tsina" data-cmd="tsina" title="分享到新浪微博"></a>
|
||||
<a href="#" class="bds_douban" data-cmd="douban" title="分享到豆瓣网"></a>
|
||||
<a href="#" class="bds_sqq" data-cmd="sqq" title="分享到QQ好友"></a>
|
||||
<a href="#" class="bds_qzone" data-cmd="qzone" title="分享到QQ空间"></a>
|
||||
<a href="#" class="bds_weixin" data-cmd="weixin" title="分享到微信"></a>
|
||||
<a href="#" class="bds_tieba" data-cmd="tieba" title="分享到百度贴吧"></a>
|
||||
<a href="#" class="bds_twi" data-cmd="twi" title="分享到Twitter"></a>
|
||||
<a href="#" class="bds_fbook" data-cmd="fbook" title="分享到Facebook"></a>
|
||||
<a href="#" class="bds_more" data-cmd="more"></a>
|
||||
<a class="bds_count" data-cmd="count"></a>
|
||||
</div>
|
||||
<script>
|
||||
window._bd_share_config = {
|
||||
"common": {
|
||||
"bdText": "",
|
||||
"bdMini": "2",
|
||||
"bdMiniList": false,
|
||||
"bdPic": ""
|
||||
},
|
||||
"share": {
|
||||
"bdSize": "16",
|
||||
"bdStyle": "0"
|
||||
},
|
||||
"image": {
|
||||
"viewList": ["tsina", "douban", "sqq", "qzone", "weixin", "twi", "fbook"],
|
||||
"viewText": "分享到:",
|
||||
"viewSize": "16"
|
||||
}
|
||||
}
|
||||
</script>
|
||||
{% elseif theme.baidushare.type === "slide" %}
|
||||
<script>
|
||||
window._bd_share_config = {
|
||||
"common": {
|
||||
"bdText": "",
|
||||
"bdMini": "1",
|
||||
"bdMiniList": false,
|
||||
"bdPic": ""
|
||||
},
|
||||
"image": {
|
||||
"viewList": ["tsina", "douban", "sqq", "qzone", "weixin", "twi", "fbook"],
|
||||
"viewText": "分享到:",
|
||||
"viewSize": "16"
|
||||
},
|
||||
"slide": {
|
||||
"bdImg": "5",
|
||||
"bdPos": "left",
|
||||
"bdTop": "100"
|
||||
}
|
||||
}
|
||||
</script>
|
||||
{% endif %}
|
||||
<script>
|
||||
with(document)0[(getElementsByTagName('head')[0]||body).appendChild(createElement('script')).src='//bdimg.share.baidu.com/static/api/js/share.js?cdnversion='+~(-new Date()/36e5)];
|
||||
</script>
|
18
themes/next/layout/_partials/share/duoshuo_share.swig
Normal file
18
themes/next/layout/_partials/share/duoshuo_share.swig
Normal file
@ -0,0 +1,18 @@
|
||||
<div class="ds-share flat" data-thread-key="{{ page.path }}"
|
||||
data-title="{{ page.title }}"
|
||||
data-content=""
|
||||
data-url="{{ page.permalink }}">
|
||||
<div class="ds-share-inline">
|
||||
<ul class="ds-share-icons-16">
|
||||
|
||||
<li data-toggle="ds-share-icons-more"><a class="ds-more" href="javascript:void(0);">分享到:</a></li>
|
||||
<li><a class="ds-weibo" href="javascript:void(0);" data-service="weibo">微博</a></li>
|
||||
<li><a class="ds-qzone" href="javascript:void(0);" data-service="qzone">QQ空间</a></li>
|
||||
<li><a class="ds-qqt" href="javascript:void(0);" data-service="qqt">腾讯微博</a></li>
|
||||
<li><a class="ds-wechat" href="javascript:void(0);" data-service="wechat">微信</a></li>
|
||||
|
||||
</ul>
|
||||
<div class="ds-share-icons-more">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
25
themes/next/layout/_partials/share/jiathis.swig
Normal file
25
themes/next/layout/_partials/share/jiathis.swig
Normal file
@ -0,0 +1,25 @@
|
||||
<!-- JiaThis Button BEGIN -->
|
||||
<div class="jiathis_style">
|
||||
<span class="jiathis_txt">分享到:</span>
|
||||
<a class="jiathis_button_fav">收藏夹</a>
|
||||
<a class="jiathis_button_copy">复制网址</a>
|
||||
<a class="jiathis_button_email">邮件</a>
|
||||
<a class="jiathis_button_weixin">微信</a>
|
||||
<a class="jiathis_button_qzone">QQ空间</a>
|
||||
<a class="jiathis_button_tqq">腾讯微博</a>
|
||||
<a class="jiathis_button_douban">豆瓣</a>
|
||||
<a class="jiathis_button_share">一键分享</a>
|
||||
|
||||
<a href="http://www.jiathis.com/share?uid=2140465" class="jiathis jiathis_txt jiathis_separator jtico jtico_jiathis" target="_blank">更多</a>
|
||||
<a class="jiathis_counter_style"></a>
|
||||
</div>
|
||||
<script type="text/javascript" >
|
||||
var jiathis_config={
|
||||
data_track_clickback:true,
|
||||
summary:"",
|
||||
shortUrl:false,
|
||||
hideMore:false
|
||||
}
|
||||
</script>
|
||||
<script type="text/javascript" src="http://v3.jiathis.com/code/jia.js?uid={{ theme.jiathis.uid }}" charset="utf-8"></script>
|
||||
<!-- JiaThis Button END -->
|
Reference in New Issue
Block a user