Skip to content

Commit 818d788

Browse files
committed
postcssの color() を生のCSSの記法に変更
1 parent 8057d99 commit 818d788

File tree

6 files changed

+14
-14
lines changed

6 files changed

+14
-14
lines changed

css/browser.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@ body.kunai {
1616

1717
font-weight: bold;
1818
$c: rgb(240, 36, 54);
19-
background: color($c alpha(0.2));
20-
border: 3px dashed color($c alpha(0.6));
19+
background: rgb(from $c r g b / 0.2);
20+
border: 3px dashed rgb(from $c r g b / 0.6);
2121
box-sizing: border-box;
2222
color: rgba(20, 20, 20, 0.6);
2323
padding: .2em .4em;

css/kunai/site/article.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -285,7 +285,7 @@ div[itemtype="http://schema.org/Article"] {
285285

286286
border-radius: 0;
287287
border: none;
288-
border-top: 1px solid color($cl-shuri alpha(0.2));
288+
border-top: 1px solid rgb(from $cl-shuri r g b / 0.2);
289289

290290
margin: 0;
291291
box-sizing: border-box;

css/kunai/site/layout.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ body {
2121
background: $nav-bg;
2222

2323
border: none;
24-
border-bottom: 1px solid color($cl-shuri alpha(0.2));
24+
border-bottom: 1px solid rgb(from $cl-shuri r g b / 0.2);
2525

2626
position: relative;
2727
z-index: $navbar-z;
@@ -203,7 +203,7 @@ main {
203203
overflow: hidden;
204204

205205
box-sizing: border-box;
206-
border-right: 1px solid color($cl-shuri alpha(0.2));
206+
border-right: 1px solid rgb(from $cl-shuri r g b / 0.2);
207207
box-shadow: -12px 0 12px 6px rgba(0, 0, 0, 0.8);
208208

209209
z-index: $side-z;

css/kunai/site/sidebar.css

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -152,8 +152,8 @@ main[role="main"] .kunai-sidebar.force-legacy {
152152
.kunai-sidebar > .tree.v2 {
153153
$cl-text: #222;
154154
$cl-back: #fbfbfb;
155-
$cl-link: color(#2a6496 tint(15%) saturation(+ 10%));
156-
$cl-list-hover: color(#f0f0fd alpha(.9));
155+
$cl-link: hsl(from color-mix(in srgb, #2a6496, white 15%) h calc(s + 10%) l);
156+
$cl-list-hover: rgb(from #f0f0fd r g b / .9);
157157

158158
display: flex;
159159
height: 100%;
@@ -247,7 +247,7 @@ main[role="main"] .kunai-sidebar.force-legacy {
247247
content: "";
248248
display: block;
249249
height: 2px;
250-
border-bottom: 1px solid color($c alpha(0.7));
250+
border-bottom: 1px solid rgb(from $c r g b / 0.7);
251251
flex-basis: 100%;
252252
}
253253
}
@@ -265,7 +265,7 @@ main[role="main"] .kunai-sidebar.force-legacy {
265265
> .expandbar > a {
266266
flex-basis: auto;
267267
margin-bottom: 0;
268-
color: color($cl-link saturation(-20%));
268+
color: hsl(from $cl-link h calc(s - 20%) l);
269269
}
270270

271271
&:first-child, &:last-child {
@@ -408,7 +408,7 @@ main[role="main"] .kunai-sidebar.force-legacy {
408408

409409

410410
&:not([href]) {
411-
color: color($cl-text tint(50%));
411+
color: color-mix(in srgb, $cl-text, white 50%);
412412
text-decoration: none;
413413
// cursor: help;
414414
border-bottom: 1px solid transparent;
@@ -530,7 +530,7 @@ main[role="main"] .kunai-sidebar.force-legacy {
530530
// background-color: rgba(100, 100, 100, .03);
531531
font-size: .9em;
532532

533-
$c-b: 1px solid color($cl-link saturation(-5%) tint(65%) alpha(0.4));
533+
$c-b: 1px solid rgb(from color-mix(in srgb, hsl(from $cl-link h calc(s - 5%) l), white 65%) r g b / 0.4);
534534
border-left: $c-b;
535535
border-bottom: $c-b;
536536
border-radius: 4px;
@@ -598,7 +598,7 @@ main[role="main"] .kunai-sidebar.force-legacy {
598598
> .self {
599599
$c: #87ceeb;
600600
border-left: 4px solid $c;
601-
border-bottom: 1px dashed color($c alpha(0.7));
601+
border-bottom: 1px dashed rgb(from $c r g b / 0.7);
602602
margin-bottom: .5em;
603603
// box-shadow: 0 3px 13px -6px rgba(20, 20, 20, 0.2);
604604

css/kunai/site/tree.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -168,7 +168,7 @@
168168
border-bottom-width: 2px;
169169
}
170170
.treespan {
171-
background: color(#fddfb3 tint(10%));
171+
background: color-mix(in srgb, #fddfb3, white 10%);
172172
border: 1px solid #faa937;
173173
color: #000;
174174
}

css/kunai/yata.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ body.kunai {
1515

1616
.yata-toolbar {
1717
display: flex;
18-
// background: color($cl-shuri tint(25%));
18+
// background: color-mix(in srgb, $cl-shuri, white 25%);
1919
background: #a9d4e2;
2020
border-radius: 2px 2px 0 0;
2121

0 commit comments

Comments
 (0)