Skip to content
This repository has been archived by the owner on Nov 19, 2021. It is now read-only.

Commit

Permalink
V1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
chenall committed Mar 26, 2014
1 parent 4359bc9 commit c5ff71a
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 5 deletions.
10 changes: 8 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# chenall
# chenall V1.0

基于[Hexo]默认主题light修改而成,采用bootstrap css框架
在尽量保留原有主题功能的同时采用模块化设计支持多个widgets.实现高度自定义,通过widgets你可以添加许多实用功能.
Expand All @@ -14,7 +14,13 @@
- 允许在head或body的前面或尾部附加自定义内容.
- 独立脚本插件扩展(source_dir/_scripts目录里面的js文件会自动加载,效果和scripts目录里面一样)

注: 上面的$SOURCE是hexo配置文件中在`source_dir`,$THEME是hexo配置文件中的`theme`,即 **hexo.source_dir + '_'+ hexo.config.theme+ '.yml'**;
注1: 上面的$SOURCE是hexo配置文件中在`source_dir`,$THEME是hexo配置文件中的`theme`,即 **hexo.source_dir + '_'+ hexo.config.theme+ '.yml'**;

注2: 本版本V1.0主题适用的hexo版本为 2.4.x 建议使用2.4.5版,可以使用如下命令安装hexo2.4.5版本.hexo2.5版本因为还有一些问题没有解决,请等待以后的更新.

```
npm install [email protected]
```

### **具体效果:** [demo] 或我的搏客 [chenall.net]

Expand Down
2 changes: 1 addition & 1 deletion layout/_partial/footer.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
})
}%>
</div>
<div id="copyright">Blog powered by <a href='http://zespia.tw/hexo/'><strong>hexo</strong></a> Theme <strong><a href='https://github.com/chenall/hexo-theme-chenall'>chenall</a></strong><span class="pull-right"> 更新时间: <em><%-time(page.updated,'YYYY-MM-DD HH:mm:ss')%></em></span></div>
<div id="copyright">Blog powered by <a href='http://zespia.tw/hexo/' <%if (hexo.env.version){%> title="本站由hexo V<%- hexo.env.version%> 生成"<%}%>><strong>hexo</strong></a> Theme <strong><a href='https://github.com/chenall/hexo-theme-chenall'>chenall</a></strong><span class="pull-right"> 更新时间: <em><%-time(page.updated,'YYYY-MM-DD HH:mm:ss')%></em></span></div>
</div>
<div class="clearfix"></div>

2 changes: 1 addition & 1 deletion layout/_partial/pagination.ejs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<%if (page.prev || page.next) {%>
<ul id="pagination" class="pagination pagination-lg">
<%- paginator({mid_size:3,end_size:2,show_all: false,prev_text:'&laquo;',next_text:'&raquo;'}).replace(/<a.+?\/a>/g,'<li>$&</li>').replace(/<span[^>]+?current.+\/span>/g,'<li class="active">$&</li>').replace(/<span.+?\/span>/g,'<li>$&</li>')%>
<%- paginator({mid_size:3,end_size:2,show_all: false,prev_text:'&laquo;',next_text:'&raquo;'}).replace(/<a.+?\/a>/g,'<li>$&</li>').replace(/<span[^>]+?current.+?\/span>/g,'<li class="active">$&</li>').replace(/<span.+?\/span>/g,'<li>$&</li>')%>
<div class="clearfix"></div>
</ul>
<%}%>
2 changes: 2 additions & 0 deletions layout/module.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ if (!usercfg.themeconfig) usercfg.themeconfig = theme;
hexo.__ = function(item){
return function(str,opt){
var s = __(item?item + '.' + str:str);
if (item && s == item + '.' + str)
return (opt===false?false:str);
return s?s:(opt===false?false:str);
}
}
Expand Down
2 changes: 1 addition & 1 deletion scripts/extend.helper.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ helper.register('_partial',function(view,opt){

if (type[0] == '_'){
var dst = path.join(hexo.source_dir,type);
if (fs.existsSync(dst)) hexo.log.d(dst),view = dst;
if (fs.existsSync(dst)) hexo.log.d(dst),view = dst.replace(/\\/g, '/');
}

return this.partial(view,opt);
Expand Down

0 comments on commit c5ff71a

Please sign in to comment.