Skip to content

Commit 2775be7

Browse files
committed
Default to subpixel for non-retina screens
1 parent 2484f02 commit 2775be7

File tree

1 file changed

+13
-4
lines changed

1 file changed

+13
-4
lines changed

packages/common/src/global.css

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
html,
22
body {
33
font-family: 'Roboto', sans-serif;
4-
-webkit-font-smoothing: antialiased;
5-
-moz-font-smoothing: antialiased;
4+
-webkit-font-smoothing: auto;
5+
-moz-font-smoothing: auto;
66
-moz-osx-font-smoothing: grayscale;
7-
font-smoothing: antialiased;
7+
font-smoothing: auto;
88
text-rendering: optimizeLegibility;
99
font-smooth: always;
1010
-webkit-tap-highlight-color: transparent;
@@ -82,5 +82,14 @@ a {
8282
**/
8383
body * {
8484
box-sizing: initial;
85-
-webkit-font-smoothing: antialiased;
85+
-webkit-font-smoothing: auto;
86+
}
87+
88+
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
89+
/* On Retina the pixel density is so high that we can do anti-aliasing instead of
90+
subpixel anti-aliasing and it will look more beautiful (star)
91+
*/
92+
body * {
93+
-webkit-font-smoothing: antialiased;
94+
}
8695
}

0 commit comments

Comments
 (0)