Skip to content

Commit f98ce5f

Browse files
Fix several bugs reported in v7.3 (theme-next#1060)
1 parent 8aa162c commit f98ce5f

File tree

6 files changed

+17
-13
lines changed

6 files changed

+17
-13
lines changed

source/css/_common/components/highlight/copy-code.styl

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -50,11 +50,6 @@ if (hexo-config('codeblock.copy_button.style') == 'mac') {
5050
box-shadow: 0 10px 30px 0 rgba(0, 0, 0, .4);
5151
margin-bottom: 1.6em;
5252
padding-top: 30px;
53-
}
54-
55-
.highlight {
56-
// border-radius: 0 0 5px 5px;
57-
margin: 0 !important;
5853

5954
&::before {
6055
background: #fc625d;
@@ -68,4 +63,9 @@ if (hexo-config('codeblock.copy_button.style') == 'mac') {
6863
width: 12px;
6964
}
7065
}
66+
67+
.highlight {
68+
// border-radius: 0 0 5px 5px;
69+
margin: 0 !important;
70+
}
7171
}

source/css/_common/components/highlight/highlight.styl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ pre {
3434
code {
3535
background: none;
3636
color: $highlight-foreground;
37+
font-size: $table-font-size;
3738
padding: 0;
3839
text-shadow: none;
3940
}

source/css/_common/components/post/post-title.styl

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
color: #bbb;
1111
display: inline-block;
1212
float: right;
13+
font-size: $font-size-larger;
1314
the-transition-ease-in();
1415
margin-left: -1.2em;
1516

source/css/_common/components/sidebar/sidebar-button.styl

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,21 +2,21 @@
22
margin-top: 10px;
33

44
a {
5-
border: 1px solid rgb(252, 100, 35) !important;
5+
border: 1px solid $orange !important;
66
border-radius: 4px;
7-
color: rgb(252, 100, 35);
7+
color: $orange;
88
display: inline-block;
99
padding: 0 15px;
1010

11-
i {
12-
color: rgb(252, 100, 35);
11+
.fa {
12+
margin-right: 5px;
1313
}
1414

1515
&:hover {
16-
background: rgb(252, 100, 35);
16+
background: $orange;
1717
color: white;
1818

19-
i {
19+
.fa {
2020
color: white;
2121
}
2222
}

source/css/_schemes/Pisces/_sidebar.styl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@
6666
background: none;
6767
color: darken($orange, 20%);
6868

69-
i {
69+
.fa {
7070
color: darken($orange, 20%);
7171
}
7272
}

source/js/utils.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,9 @@ NexT.utils = {
163163
registerActiveMenuItem: function() {
164164
$('.menu-item').each(function() {
165165
var target = $(this).find('a[href]')[0];
166-
if (target.hostname === location.hostname && (target.pathname === location.pathname || target.pathname === location.pathname.replace('index.html', '', 'g'))) {
166+
var isSamePath = target.pathname === location.pathname || target.pathname === location.pathname.replace('index.html', '');
167+
var isSubPath = target.pathname !== '/' && location.pathname.indexOf(target.pathname) === 0;
168+
if (target.hostname === location.hostname && (isSamePath || isSubPath)) {
167169
$(this).addClass('menu-item-active');
168170
} else {
169171
$(this).removeClass('menu-item-active');

0 commit comments

Comments
 (0)