Skip to content

Commit 3d34a11

Browse files
Update .category-list-count style
1 parent 6bf97f6 commit 3d34a11

File tree

9 files changed

+41
-43
lines changed

9 files changed

+41
-43
lines changed

source/css/_common/components/pages/categories.styl

+2-9
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,8 @@
1818
}
1919

2020
.category-list-count {
21-
color: $grey;
22-
23-
&::before {
24-
content: ' (';
25-
}
26-
27-
&::after {
28-
content: ') ';
29-
}
21+
font-size: $font-size-smallest;
22+
badge();
3023
}
3124

3225
.category-list-child {

source/css/_common/outline/header/menu.styl

+1-2
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,7 @@
3636
}
3737

3838
.badge {
39-
font-weight: bold;
40-
line-height: 1;
39+
badge();
4140
}
4241
}
4342

source/css/_mixins.styl

+11
Original file line numberDiff line numberDiff line change
@@ -281,3 +281,14 @@ menu-item-row() {
281281
margin-left: auto;
282282
}
283283
}
284+
285+
badge() {
286+
background: $badge-background;
287+
border-radius: $badge-border-radius;
288+
color: $badge-color;
289+
font-weight: bold;
290+
line-height: 1;
291+
margin-left: .35em;
292+
padding: $badge-padding;
293+
text-shadow: $badge-text-shadow;
294+
}

source/css/_schemes/Mist/_menu.styl

-9
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,5 @@
3434
menu-item-row();
3535
}
3636
}
37-
38-
.badge {
39-
background: white;
40-
border-radius: 10px;
41-
color: $black-light;
42-
margin-left: .35em;
43-
padding: 1px 4px;
44-
text-shadow: 1px 1px 0 rgba(0, 0, 0, .1);
45-
}
4637
}
4738
}

source/css/_schemes/Muse/_menu.styl

-7
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,4 @@
4848
width: 100%;
4949
}
5050
}
51-
52-
.badge {
53-
background: $gainsboro;
54-
color: $black-light;
55-
margin-left: .35em;
56-
padding: 1px 4px;
57-
}
5851
}

source/css/_schemes/Pisces/_menu.styl

-8
Original file line numberDiff line numberDiff line change
@@ -19,14 +19,6 @@
1919
display: none;
2020
}
2121
}
22-
23-
.badge {
24-
background: $grey-light;
25-
border-radius: 10px;
26-
color: var(--content-bg-color);
27-
padding: 2px 5px;
28-
text-shadow: 1px 1px 0 rgba(0, 0, 0, .1);
29-
}
3022
}
3123

3224
if (not hexo-config('menu_settings.badges')) {

source/css/_variables/Mist.styl

+4
Original file line numberDiff line numberDiff line change
@@ -25,3 +25,7 @@ $btn-default-hover-bg = transparent;
2525
$btn-default-border-color = var(--link-color);
2626
$btn-default-hover-color = var(--link-hover-color);
2727
$btn-default-hover-border-color = var(--link-hover-color);
28+
29+
$badge-background = white;
30+
$badge-border-radius = 10px;
31+
$badge-text-shadow = 1px 1px 0 rgba(0, 0, 0, .1);

source/css/_variables/Pisces.styl

+14-8
Original file line numberDiff line numberDiff line change
@@ -57,13 +57,19 @@ $site-state-item-name-color = $grey-dark;
5757
// --------------------------------------------------
5858

5959
// Button
60-
$btn-default-radius = 2px;
61-
$btn-default-bg = white;
62-
$btn-default-color = $text-color;
63-
$btn-default-border-color = $text-color;
64-
$btn-default-hover-bg = $black-deep;
65-
$btn-default-hover-color = white;
60+
$btn-default-radius = 2px;
61+
$btn-default-bg = white;
62+
$btn-default-color = $text-color;
63+
$btn-default-border-color = $text-color;
64+
$btn-default-hover-bg = $black-deep;
65+
$btn-default-hover-color = white;
6666

6767
// Back to top
68-
$b2t-opacity = .6;
69-
$b2t-opacity-hover = .8;
68+
$b2t-opacity = .6;
69+
$b2t-opacity-hover = .8;
70+
71+
$badge-background = $grey-light;
72+
$badge-border-radius = 10px;
73+
$badge-color = var(--content-bg-color);
74+
$badge-padding = 2px 5px;
75+
$badge-text-shadow = 1px 1px 0 rgba(0, 0, 0, .1);

source/css/_variables/base.styl

+9
Original file line numberDiff line numberDiff line change
@@ -387,3 +387,12 @@ $label = {
387387
warning : lighten(spin($note-border.warning, 10), 83% + $lbg),
388388
danger : lighten(spin($note-border.danger, -10), 87% + $lbg)
389389
};
390+
391+
392+
// Badge colors
393+
// --------------------------------------------------
394+
$badge-padding = 1px 4px;
395+
$badge-border-radius = 0;
396+
$badge-background = $gainsboro;
397+
$badge-color = $black-light;
398+
$badge-text-shadow = none;

0 commit comments

Comments
 (0)