Skip to content

Commit bd3b32e

Browse files
committed
style: extra Arabic and Latin font support
1 parent 4f8aa29 commit bd3b32e

File tree

5 files changed

+63
-5
lines changed

5 files changed

+63
-5
lines changed

src/content-script/styles.scss

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;700&display=swap');
1+
@import '../fonts/styles.css';
22

33
[data-theme='auto'] {
44
@import 'github-markdown-css/github-markdown.css';
@@ -42,15 +42,16 @@
4242
margin-left: 60px;
4343
}
4444

45+
.chatgptbox-container * {
46+
font-family: 'Cairo', sans-serif;
47+
}
48+
4549
.chatgptbox-container {
4650
width: 100%;
4751
flex-basis: 0;
4852
flex-grow: 1;
4953
margin-bottom: 20px;
5054

51-
.chatgptbox-container * {
52-
font-family: 'Cairo', sans-serif;
53-
}
5455
.gpt-inner {
5556
border-radius: 8px;
5657
border: 1px solid;
@@ -122,7 +123,6 @@
122123
line-height: 1.6;
123124
border-radius: 8px;
124125
word-break: break-word;
125-
font-family: 'Cairo', sans-serif;
126126
pre {
127127
margin-top: 10px;
128128
}
Binary file not shown.
Binary file not shown.
Binary file not shown.

src/fonts/styles.css

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
/* arabic */
2+
@font-face {
3+
font-family: 'Cairo';
4+
font-style: normal;
5+
font-weight: 400;
6+
font-display: swap;
7+
src: url(SLXVc1nY6HkvangtZmpQdkhzfH5lkSscQyyS4J0.woff2) format('woff2');
8+
unicode-range: U+0600-06FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE80-FEFC;
9+
}
10+
/* latin-ext */
11+
@font-face {
12+
font-family: 'Cairo';
13+
font-style: normal;
14+
font-weight: 400;
15+
font-display: swap;
16+
src: url(SLXVc1nY6HkvangtZmpQdkhzfH5lkSscSCyS4J0.woff2) format('woff2');
17+
unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113,
18+
U+2C60-2C7F, U+A720-A7FF;
19+
}
20+
/* latin */
21+
@font-face {
22+
font-family: 'Cairo';
23+
font-style: normal;
24+
font-weight: 400;
25+
font-display: swap;
26+
src: url(SLXVc1nY6HkvangtZmpQdkhzfH5lkSscRiyS.woff2) format('woff2');
27+
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F,
28+
U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
29+
}
30+
/* arabic */
31+
@font-face {
32+
font-family: 'Cairo';
33+
font-style: normal;
34+
font-weight: 700;
35+
font-display: swap;
36+
src: url(SLXVc1nY6HkvangtZmpQdkhzfH5lkSscQyyS4J0.woff2) format('woff2');
37+
unicode-range: U+0600-06FF, U+200C-200E, U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE80-FEFC;
38+
}
39+
/* latin-ext */
40+
@font-face {
41+
font-family: 'Cairo';
42+
font-style: normal;
43+
font-weight: 700;
44+
font-display: swap;
45+
src: url(SLXVc1nY6HkvangtZmpQdkhzfH5lkSscSCyS4J0.woff2) format('woff2');
46+
unicode-range: U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113,
47+
U+2C60-2C7F, U+A720-A7FF;
48+
}
49+
/* latin */
50+
@font-face {
51+
font-family: 'Cairo';
52+
font-style: normal;
53+
font-weight: 700;
54+
font-display: swap;
55+
src: url(SLXVc1nY6HkvangtZmpQdkhzfH5lkSscRiyS.woff2) format('woff2');
56+
unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F,
57+
U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
58+
}

0 commit comments

Comments
 (0)