@twreporter/react-components 9.2.2-rc.0 → 9.3.0-rc.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -8,6 +8,7 @@ var _font = require("@twreporter/core/lib/constants/font");
8
8
  var _forEach = _interopRequireDefault(require("lodash/forEach"));
9
9
  var _keys = _interopRequireDefault(require("lodash/keys"));
10
10
  var _reduce = _interopRequireDefault(require("lodash/reduce"));
11
+ var _gcsFontFolder, _fontFaces;
11
12
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
12
13
  function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
13
14
  function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
@@ -20,7 +21,7 @@ var _ = {
20
21
  };
21
22
  var baseGCSDir = 'https://www.twreporter.org/assets/font/';
22
23
  var fileExt = '.woff2';
23
- var gcsFontFolder = _defineProperty({}, _font.fonts.notoSansTC, 'NotoSansTC');
24
+ var gcsFontFolder = (_gcsFontFolder = {}, _defineProperty(_gcsFontFolder, _font.fonts.notoSansTC, 'NotoSansTC'), _defineProperty(_gcsFontFolder, _font.fonts.tauhuOo, 'TauhuOo'), _gcsFontFolder);
24
25
  var fontWeightKeys = _.keys(_font.fontWeight);
25
26
 
26
27
  // add @font-face to global style to use self-hosted font for performance reasons, to be more precise please check the issue below:
@@ -38,10 +39,13 @@ var getFontFaces = function getFontFaces(_ref) {
38
39
  });
39
40
  }, '');
40
41
  };
41
- var fontFaces = _defineProperty({}, _font.fonts.notoSansTC, getFontFaces({
42
+ var fontFaces = (_fontFaces = {}, _defineProperty(_fontFaces, _font.fonts.notoSansTC, getFontFaces({
42
43
  font: _font.fonts.notoSansTC,
43
44
  folder: gcsFontFolder[_font.fonts.notoSansTC]
44
- }));
45
+ })), _defineProperty(_fontFaces, _font.fonts.tauhuOo, getFontFaces({
46
+ font: _font.fonts.tauhuOo,
47
+ folder: gcsFontFolder[_font.fonts.tauhuOo]
48
+ })), _fontFaces);
45
49
  var fontGCSFiles = [];
46
50
  _.forEach(fontFaces, function (fontFace, font) {
47
51
  _.forEach(fontWeightKeys, function (fontWeightKey) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@twreporter/react-components",
3
- "version": "9.2.2-rc.0",
3
+ "version": "9.3.0-rc.0",
4
4
  "main": "lib/index.js",
5
5
  "repository": "https://github.com/twreporter/twreporter-npm-packages.git",
6
6
  "author": "twreporter <developer@twreporter.org>",
@@ -15,8 +15,8 @@
15
15
  "chromatic": "npx chromatic --exit-zero-on-changes"
16
16
  },
17
17
  "dependencies": {
18
- "@twreporter/core": "^1.23.0-rc.0",
19
- "@twreporter/redux": "^8.1.2-rc.0",
18
+ "@twreporter/core": "^1.24.0-rc.0",
19
+ "@twreporter/redux": "^8.1.3-rc.0",
20
20
  "fontfaceobserver-es": "^3.3.3",
21
21
  "hoist-non-react-statics": "^2.3.1",
22
22
  "lodash": "^4.0.0",
@@ -54,5 +54,5 @@
54
54
  "react-dom": "^18.2.0",
55
55
  "storybook": "^8.1.11"
56
56
  },
57
- "gitHead": "e7e704404a5723189a9386ac47cadad098b8d2f2"
57
+ "gitHead": "6fc620fd9451c138ae7a789ac8a947d5d2ae51bc"
58
58
  }