Skip to content

Commit 42227ea

Browse files
committed
style: keep old color values ​​as fallback
When the user's browser does not support `light-dark`, fall back to the light theme color scheme.
1 parent 9bb2fc9 commit 42227ea

File tree

3 files changed

+11
-0
lines changed

3 files changed

+11
-0
lines changed

src/browser/pages/error.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
}
1111

1212
.error-display > .body {
13+
color: #444;
1314
color: light-dark(#444, #ccc);
1415
font-size: 1.2rem;
1516
}

src/browser/pages/global.css

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@ body,
1010
}
1111

1212
body {
13+
background: rgb(244, 247, 252);
1314
background: light-dark(rgb(244, 247, 252), #111);
15+
color: #111;
1416
color: light-dark(#111, #ddd);
1517
margin: 0;
1618
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji",
@@ -26,10 +28,12 @@ button {
2628
}
2729

2830
.-button {
31+
background-color: rgb(87, 114, 245);
2932
background-color: light-dark(rgb(87, 114, 245), rgb(50, 85, 250));
3033
border-radius: 5px;
3134
border: none;
3235
box-sizing: border-box;
36+
color: white;
3337
color: light-dark(white, #ddd);
3438
cursor: pointer;
3539
padding: 18px 20px;
@@ -48,6 +52,7 @@ button {
4852
}
4953

5054
.card-box {
55+
background-color: rgb(250, 253, 258);
5156
background-color: light-dark(rgb(250, 253, 258), #000);
5257
border-radius: 5px;
5358
box-shadow:
@@ -58,7 +63,9 @@ button {
5863
}
5964

6065
.card-box > .header {
66+
border-bottom: 1px solid #ddd;
6167
border-bottom: 1px solid light-dark(#ddd, #222);
68+
color: #444;
6269
color: light-dark(#444, #ccc);
6370
padding: 30px;
6471
}
@@ -69,6 +76,7 @@ button {
6976
}
7077

7178
.card-box > .header > .sub {
79+
color: #555;
7280
color: light-dark(#555, #aaa);
7381
margin-top: 10px;
7482
}

src/browser/pages/login.css

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,10 @@ body {
2929
}
3030

3131
.login-form > .field > .password {
32+
background-color: rgb(244, 247, 252);
3233
background-color: light-dark(rgb(244, 247, 252), #222);
3334
border-radius: 5px;
35+
border: 1px solid #ddd;
3436
border: 1px solid light-dark(#ddd, #333);
3537
box-sizing: border-box;
3638
flex: 1;

0 commit comments

Comments
 (0)