Skip to content

Commit

Permalink
feat: hide-labels button 隐藏标记
Browse files Browse the repository at this point in the history
Add a button to hide labels in archives page.
在文章索引界面增加一个按钮用于隐藏标记标签。

Closes #9
  • Loading branch information
MOxFIVE committed Sep 14, 2015
1 parent 2952bea commit ccd87b5
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 5 deletions.
12 changes: 11 additions & 1 deletion themes/Yilia/layout/archive.ejs
@@ -1 +1,11 @@
<%- partial('_partial/archive', {pagination: config.archive, index: true}) %>
<%- partial('_partial/archive', {pagination: config.archive, index: true}) %>
<button class="hide-labels">TAG 开关</button>
<script src="http://7.url.cn/edu/jslib/comb/require-2.1.6,jquery-1.9.1.min.js">
</script>
<script>
$(document).ready(function(){
$("button").click(function(){
$(".article-info").toggle(200);
});
});
</script>
26 changes: 22 additions & 4 deletions themes/Yilia/source/css/_partial/article.styl
Expand Up @@ -391,9 +391,6 @@ body {
}
}




/*toc*/
#tocButton {
position: fixed;
Expand Down Expand Up @@ -505,4 +502,25 @@ body {

li:hover {
background: #F0F0F0
};
};

.hide-labels {
position: fixed;
left: 378px;
top: 30px;
font-size: .9em;
padding: 1px;
font-weight: bold;
color: #666;
background: none;
cursor: pointer
border: none;
border-radius: 5px;
opacity: .32;
font-family: inherit;
-webkit-appearance: none;
&:hover {
color: #88acdb;
opacity: 1;
}
}

0 comments on commit ccd87b5

Please sign in to comment.