Skip to content

Commit e22941f

Browse files
committed
feat: updated typography of wave design system
1 parent fedf564 commit e22941f

File tree

4 files changed

+97
-5
lines changed

4 files changed

+97
-5
lines changed

package-lock.json

Lines changed: 10 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,7 @@
161161
},
162162
"dependencies": {
163163
"@datepicker-react/hooks": "^2.3.1",
164+
"@fontsource-variable/roboto-flex": "^5.2.6",
164165
"@popperjs/core": "^2.11.5",
165166
"@styled-system/theme-get": "^5.1.2",
166167
"@types/react-select": "^4.0.18",

src/essentials/Colors/globalStyles.ts

Lines changed: 85 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import { createGlobalStyle, DefaultTheme, GlobalStyleComponent } from 'styled-components';
2+
import '@fontsource-variable/roboto-flex';
23

34
import {
45
generateBareTierCssVariables,
@@ -23,7 +24,7 @@ export const createThemeGlobalStyle = (
2324
color-scheme: dark;
2425
${generateSemanticTierCssVariables(darkScheme)}
2526
}
26-
27+
2728
.light-scheme {
2829
color-scheme: light;
2930
${generateSemanticTierCssVariables(lightScheme)}
@@ -35,12 +36,92 @@ export const createThemeGlobalStyle = (
3536
${generateSemanticTierCssVariables(darkScheme)}
3637
}
3738
}
38-
39+
3940
body, .wave {
4041
color: ${getSemanticValue('foreground-primary')};
41-
background-color: ${getSemanticValue('background-page-default')}
42+
background-color: ${getSemanticValue('background-page-default')};
43+
font-family: "Roboto Flex Variable", system-ui, sans-serif;
44+
font-style: normal;
45+
font-variation-settings:
46+
"GRAD" 0,
47+
"XOPQ" 100,
48+
"XTRA" 506,
49+
"YOPQ" 85,
50+
"YTAS" 730,
51+
"YTDE" -203,
52+
"YTFI" 738,
53+
"YTLC" 550,
54+
"YTUC" 712;
55+
56+
/* roboto-flex-latin-wght-normal */
57+
@font-face {
58+
font-family: "Roboto Flex Variable";
59+
font-style: oblique 0deg 10deg;
60+
font-display: swap;
61+
font-weight: 100 1000;
62+
font-stretch: 25% 151%;
63+
src: url(@fontsource-variable/roboto-flex/files/roboto-flex-latin-full-normal.woff2)
64+
format("woff2-variations");
65+
unicode-range:
66+
U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC,
67+
U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212,
68+
U+2215, U+FEFF, U+FFFD;
69+
}
70+
71+
/* roboto-flex-cyrillic-wght-normal */
72+
@font-face {
73+
font-family: "Roboto Flex Variable";
74+
font-style: oblique 0deg 10deg;
75+
font-display: swap;
76+
font-weight: 100 1000;
77+
font-stretch: 25% 151%;
78+
src: url(@fontsource-variable/roboto-flex/files/roboto-flex-cyrillic-full-normal.woff2)
79+
format("woff2-variations");
80+
unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
81+
}
82+
83+
/* roboto-flex-cyrillic-ext-wght-normal */
84+
@font-face {
85+
font-family: "Roboto Flex Variable";
86+
font-style: oblique 0deg 10deg;
87+
font-display: swap;
88+
font-weight: 100 1000;
89+
font-stretch: 25% 151%;
90+
src: url(@fontsource-variable/roboto-flex/files/roboto-flex-cyrillic-ext-full-normal.woff2)
91+
format("woff2-variations");
92+
unicode-range:
93+
U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
94+
}
95+
96+
/* roboto-flex-greek-wght-normal */
97+
@font-face {
98+
font-family: "Roboto Flex Variable";
99+
font-style: oblique 0deg 10deg;
100+
font-display: swap;
101+
font-weight: 100 1000;
102+
font-stretch: 25% 151%;
103+
src: url(@fontsource-variable/roboto-flex/files/roboto-flex-greek-full-normal.woff2)
104+
format("woff2-variations");
105+
unicode-range:
106+
U+0370-0377, U+037A-037F, U+0384-038A, U+038C, U+038E-03A1, U+03A3-03FF;
107+
}
108+
109+
/* roboto-flex-latin-ext-wght-normal */
110+
@font-face {
111+
font-family: "Roboto Flex Variable";
112+
font-style: oblique 0deg 10deg;
113+
font-display: swap;
114+
font-weight: 100 1000;
115+
font-stretch: 25% 151%;
116+
src: url(@fontsource-variable/roboto-flex/files/roboto-flex-latin-ext-full-normal.woff2)
117+
format("woff2-variations");
118+
unicode-range:
119+
U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304,
120+
U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB,
121+
U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
122+
}
42123
}
43-
124+
44125
svg {
45126
fill: currentColor;
46127
}

src/essentials/theme.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ const theme: DefaultTheme = {
1111
bold: 700
1212
},
1313
fonts: {
14-
normal: fontStack(['Roboto Flex', 'Open Sans', 'sans-serif']),
14+
normal: fontStack(['Roboto Flex Variable', 'Open Sans', 'sans-serif']),
1515
monospace: fontStack(['Hack', 'monospace'])
1616
},
1717
mediaQueries: MediaQueries,

0 commit comments

Comments
 (0)