Prechádzať zdrojové kódy

update font-face

* set default language to en
RoyLiu 4 rokov pred
rodič
commit
28a6088dda

+ 47 - 2
helpers/globalStyles.css

@@ -1,3 +1,48 @@
+/* en */
+@font-face {
+  font-family: 'Open Sans';
+  font-style: normal;
+  font-weight: 300;
+  font-display: swap;
+  src: local('Open Sans Light'), local('OpenSans-Light'), url(/static/fonts/OpenSans-Light.woff) format('woff');
+}
+@font-face {
+  font-family: 'Open Sans';
+  font-style: normal;
+  font-weight: 400;
+  font-display: swap;
+  src: local('Open Sans Regular'), local('OpenSans-Regular'), url(/static/fonts/OpenSans-Regular.woff) format('woff');
+}
+@font-face {
+  font-family: 'Open Sans';
+  font-style: normal;
+  font-weight: 700;
+  font-display: swap;
+  src: local('Open Sans Bold'), local('OpenSans-Bold'), url(/static/fonts/OpenSans-Bold.woff) format('woff');
+}
+/* zh-TW */
+@font-face {
+  font-family: 'Noto Sans TC';
+  font-style: normal;
+  font-weight: 300;
+  font-display: swap;
+  src: local('Noto Sans TC Light'), local('NotoSansTC-Light'), url(/static/fonts/NotoSansTC-Light.woff) format('woff');
+}
+@font-face {
+  font-family: 'Noto Sans TC';
+  font-style: normal;
+  font-weight: 400;
+  font-display: swap;
+  src: local('Noto Sans TC Regular'), local('NotoSansTC-Regular'), url(/static/fonts/NotoSansTC-Regular.woff) format('woff');
+}
+@font-face {
+  font-family: 'Noto Sans TC';
+  font-style: normal;
+  font-weight: 700;
+  font-display: swap;
+  src: local('Noto Sans TC Bold'), local('NotoSansTC-Bold'), url(/static/fonts/NotoSansTC-Bold.woff) format('woff');
+}
+
 html, body {
   margin: 0;
   background-color: #c8c8c8;
@@ -12,9 +57,9 @@ div {
 }
 
 html:lang(en) {
-  font-family: 'Clear Sans', 'Microsoft JhengHei', sans-serif;
+  font-family: 'Open Sans', sans-serif;
 }
 
 html:lang(zh-TW) {
-  font-family: 'Clear Sans', 'Microsoft JhengHei', sans-serif;
+  font-family: 'Noto Sans TC', sans-serif;
 }

+ 1 - 2
i18n.js

@@ -35,8 +35,7 @@ i18n
   .use(initReactI18next) // passes i18n down to react-i18next
   .init({
     resources,
-    lng: 'zh_tw',
+    lng: 'en',
   });
 
-
 export default i18n;

BIN
public/static/fonts/NotoSansTC-Bold.woff


BIN
public/static/fonts/NotoSansTC-Light.woff


BIN
public/static/fonts/NotoSansTC-Regular.woff


BIN
public/static/fonts/OpenSans-Bold.woff


BIN
public/static/fonts/OpenSans-Light.woff


BIN
public/static/fonts/OpenSans-Regular.woff