Skip to content

Commit 8f17dff

Browse files
committedOct 21, 2019
updated to v1.3.2
1 parent d953e64 commit 8f17dff

File tree

6 files changed

+34
-8
lines changed

6 files changed

+34
-8
lines changed
 

‎CHANGELOG.md

+8
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
# Changelog
22

3+
## 🚀 1.3.2 (Oct 21, 2019)
4+
5+
### Changes 🙌
6+
- Changed the font color of `*word*` (italic) font in post content.
7+
8+
### Bug fixes 🐛
9+
- Home page added first post reacting height, if the first post's height is higher than the window height, it will react to it's content's full height.
10+
311
## 🚀 1.3.1 (Oct 18, 2019)
412

513
### Features ✨

‎README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
# Hexo-theme-obsidian
22
> A dark Hexo theme, it's responsive, simple but elegant.
33
4-
- `Latest version: v1.3.1`
5-
- Last updated at: 2019-10-18
4+
- `Latest version: v1.3.2`
5+
- `Last updated at: 2019-10-21`
66

77
**[PREVIEW](http://tridiamond.me)** |
88
**[中文文档](https://github.com/TriDiamond/hexo-theme-obsidian/blob/master/README_CN.md)** |

‎README_CN.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
# Hexo-theme-obsidian
22
> 一款暗色的Hexo主题, 拥有响应式布局, 简约而优雅.
33
4-
- `最新版本: v1.3.1`
5-
- 最后更新时间: 2019-10-18
4+
- `最新版本: v1.3.2`
5+
- `最后更新时间: 2019-10-21`
66

77
**[预览](http://tridiamond.me)** |
88
**[English Doc](https://github.com/TriDiamond/hexo-theme-obsidian/blob/master/README.md)** |

‎_config.yml

-2
Original file line numberDiff line numberDiff line change
@@ -130,5 +130,3 @@ html_truncate:
130130
# see http://ibruce.info/2015/04/04/busuanzi/
131131
busuanzi:
132132
enable: true
133-
page: true
134-
site: true

‎source/css/obsidian.styl

+9-1
Original file line numberDiff line numberDiff line change
@@ -478,7 +478,7 @@ body.mu {
478478
#post0 {
479479
width: 80%;
480480
position: absolute;
481-
top: 20%;
481+
top: 165px;
482482
left: 10%;
483483

484484
> p:first-of-type {
@@ -2003,6 +2003,10 @@ h1.title {
20032003
opacity: 0.9;
20042004
margin: 0 5px;
20052005
}
2006+
2007+
em {
2008+
color:#5d5d5d;
2009+
}
20062010
}
20072011

20082012
.post-count {
@@ -2277,6 +2281,10 @@ h1.title {
22772281
margin: 0 0 2em;
22782282
}
22792283

2284+
em {
2285+
color:#9e9e9e;
2286+
}
2287+
22802288
ul {
22812289
margin: 10px 0;
22822290
padding-left: 20px;

‎source/js/obsidian.js

+13-1
Original file line numberDiff line numberDiff line change
@@ -434,10 +434,22 @@ var Obsidian = {
434434
else if (tocHeight <= thisTop)
435435
toc.scrollTop(tocTop + thisTop + link.outerHeight() - tocHeight);
436436
});
437+
},
438+
reactToWindowHeight: function () {
439+
const postSpacing = 315;
440+
var winHeight = $(window).height();
441+
var firstPostHeight = $('#post0').height();
442+
if (firstPostHeight + postSpacing > winHeight) {
443+
$('#mark').css('height', firstPostHeight + postSpacing + 'px');
444+
$('#screen').css('height', firstPostHeight + postSpacing + 'px');
445+
}
437446
}
438447
};
439448

440449
$(function () {
450+
if ($('#post0').length) {
451+
Obsidian.reactToWindowHeight();
452+
}
441453
if (Obsidian.P()) {
442454
$('body').addClass('touch')
443455
}
@@ -683,7 +695,7 @@ $(function () {
683695
} else {
684696
hash = $(e.target).attr('href')
685697
}
686-
to = $(".content :header").find('[href=' + hash + ']')
698+
to = $(".content :header").find('[href="' + hash + '"]')
687699
$("html,body").animate({
688700
scrollTop: to.offset().top - 80
689701
}, 300);

0 commit comments

Comments
 (0)