Skip to content

Commit 2a4d67d

Browse files
committed
refactor: uniform block border radius
scope: - categories - posts (prompt, code snippets)
1 parent 414dd13 commit 2a4d67d

File tree

6 files changed

+25
-25
lines changed

6 files changed

+25
-25
lines changed

_sass/addon/module.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@
9292
}
9393

9494
%rounded {
95-
border-radius: 6px;
95+
border-radius: $base-radius;
9696
}
9797

9898
%img-caption {

_sass/addon/variables.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ $footer-height: 5rem !default;
2323
$footer-height-mobile: 6rem !default; /* screen width: <= 576px */
2424
$main-content-max-width: 1250px !default;
2525
$bottom-min-height: 35rem !default;
26-
$card-radius: 0.5rem;
26+
$base-radius: 0.5rem;
2727

2828
/* syntax highlight */
2929

_sass/jekyll-theme-chirpy.scss

Lines changed: 13 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -6,19 +6,16 @@
66
* MIT Licensed
77
*/
88

9-
@import
10-
"colors/light-typography",
11-
"colors/dark-typography",
12-
13-
"addon/variables",
14-
"variables-hook",
15-
"addon/module",
16-
"addon/syntax",
17-
"addon/commons",
18-
19-
"layout/home",
20-
"layout/post",
21-
"layout/tags",
22-
"layout/archives",
23-
"layout/categories",
24-
"layout/category-tag";
9+
@import 'colors/light-typography';
10+
@import 'colors/dark-typography';
11+
@import 'addon/variables';
12+
@import 'variables-hook';
13+
@import 'addon/module';
14+
@import 'addon/syntax';
15+
@import 'addon/commons';
16+
@import 'layout/home';
17+
@import 'layout/post';
18+
@import 'layout/tags';
19+
@import 'layout/archives';
20+
@import 'layout/categories';
21+
@import 'layout/category-tag';

_sass/layout/categories.scss

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,14 @@
99
.categories {
1010
margin-bottom: 2rem;
1111

12+
&.card,
13+
.list-group {
14+
@extend %rounded;
15+
}
16+
1217
.card-header {
1318
padding-right: 12px;
19+
border-radius: $base-radius $base-radius 0 0;
1420
}
1521

1622
i {
@@ -42,9 +48,7 @@
4248
position: relative;
4349
height: 0.7rem;
4450
width: 1rem;
45-
transition: -webkit-transform 300ms ease;
4651
transition: transform 300ms ease;
47-
transition: transform 300ms ease, -webkit-transform 300ms ease;
4852
}
4953

5054
&:hover {
@@ -62,6 +66,5 @@
6266
}
6367

6468
.rotate {
65-
-webkit-transform: rotate(-90deg);
6669
transform: rotate(-90deg);
6770
}

_sass/layout/home.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
.card {
2121
%img-radius {
22-
border-radius: $card-radius $card-radius 0 0;
22+
border-radius: $base-radius $base-radius 0 0;
2323
}
2424

2525
.preview-img {
@@ -146,7 +146,7 @@
146146
@media all and (min-width: 768px) {
147147
#post-list {
148148
%img-radius {
149-
border-radius: 0 $card-radius $card-radius 0;
149+
border-radius: 0 $base-radius $base-radius 0;
150150
}
151151

152152
.card {

_sass/layout/post.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -205,12 +205,12 @@ h1 + .post-meta {
205205
}
206206

207207
&:first-child {
208-
border-radius: $card-radius 0 0 $card-radius;
208+
border-radius: $base-radius 0 0 $base-radius;
209209
left: 0.5px;
210210
}
211211

212212
&:last-child {
213-
border-radius: 0 $card-radius $card-radius 0;
213+
border-radius: 0 $base-radius $base-radius 0;
214214
right: 0.5px;
215215
}
216216
}

0 commit comments

Comments
 (0)