@twreporter/react-components 9.0.2 → 9.1.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.
- package/CHANGELOG.md +22 -0
- package/lib/badge/badge.stories.js +3 -9
- package/lib/badge/index.js +8 -24
- package/lib/bookmark-list/bookmark.js +20 -69
- package/lib/bookmark-list/bookmarks.js +10 -40
- package/lib/bookmark-list/customized-link.js +4 -14
- package/lib/bookmark-list/image-wrapper.js +9 -36
- package/lib/bookmark-list/index.js +36 -91
- package/lib/bookmark-list/redirect-to-sign-in.js +1 -10
- package/lib/bookmark-list/stories/bookmark.stories.js +3 -9
- package/lib/bookmark-widget/index.js +91 -220
- package/lib/button/components/iconButton.js +15 -34
- package/lib/button/components/iconWithTextButton.js +16 -31
- package/lib/button/components/link.js +27 -45
- package/lib/button/components/menuButton.js +18 -38
- package/lib/button/components/pillButton.js +31 -60
- package/lib/button/components/textButton.js +29 -61
- package/lib/button/components/toggleButton.js +11 -31
- package/lib/button/enums/index.js +4 -7
- package/lib/button/index.js +5 -18
- package/lib/button/stories/iconButton.stories.js +4 -15
- package/lib/button/stories/iconWithTextButton.stories.js +4 -13
- package/lib/button/stories/link.stories.js +9 -27
- package/lib/button/stories/menuButton.stories.js +3 -10
- package/lib/button/stories/pillButton.stories.js +4 -15
- package/lib/button/stories/textButton.stories.js +4 -15
- package/lib/button/stories/toggleButton.stories.js +3 -8
- package/lib/button/utils/size.js +3 -8
- package/lib/button/utils/theme.js +11 -102
- package/lib/card/components/article-card.js +31 -59
- package/lib/card/components/dialog.js +7 -22
- package/lib/card/components/short-story.js +24 -44
- package/lib/card/index.js +2 -8
- package/lib/card/stories/articleCard.stories.js +3 -14
- package/lib/card/stories/dialog.stories.js +3 -11
- package/lib/card/stories/shortStory.stories.js +3 -16
- package/lib/checkbox/checkbox.stories.js +3 -8
- package/lib/checkbox/index.js +10 -31
- package/lib/color.stories.js +9 -34
- package/lib/confirmation/index.js +7 -29
- package/lib/customized-link.js +5 -18
- package/lib/divider.js +3 -19
- package/lib/divider.stories.js +5 -18
- package/lib/donation-link.js +2 -14
- package/lib/empty-state/enums/index.js +2 -3
- package/lib/empty-state/index.js +20 -41
- package/lib/empty-state/stories/empty-guide.stories.js +3 -11
- package/lib/error/index.js +3 -8
- package/lib/error/message.js +3 -44
- package/lib/footer/constants/links.js +10 -16
- package/lib/footer/footer.stories.js +3 -10
- package/lib/footer/index.js +5 -40
- package/lib/footer/link.js +15 -46
- package/lib/footer/logo.js +12 -32
- package/lib/hook/index.js +3 -18
- package/lib/hook/use-bookmark.js +21 -47
- package/lib/hook/use-font-face-observer.js +9 -24
- package/lib/hook/use-outside-click.js +4 -9
- package/lib/icon/enum/index.js +5 -9
- package/lib/icon/index.js +49 -105
- package/lib/icon/stories/arrow.stories.js +7 -16
- package/lib/icon/stories/article.stories.js +2 -7
- package/lib/icon/stories/bookmark.stories.js +6 -14
- package/lib/icon/stories/changeIconColor.stories.js +2 -12
- package/lib/icon/stories/clock.stories.js +2 -7
- package/lib/icon/stories/copy.stories.js +2 -7
- package/lib/icon/stories/cross.stories.js +2 -7
- package/lib/icon/stories/hamburger.stories.js +2 -7
- package/lib/icon/stories/home.stories.js +2 -7
- package/lib/icon/stories/letter.stories.js +2 -7
- package/lib/icon/stories/loading.stories.js +2 -7
- package/lib/icon/stories/member.stories.js +2 -7
- package/lib/icon/stories/printer.stories.js +2 -7
- package/lib/icon/stories/search.stories.js +2 -7
- package/lib/icon/stories/share.stories.js +2 -7
- package/lib/icon/stories/socialMedia.stories.js +2 -8
- package/lib/icon/stories/text.stories.js +2 -7
- package/lib/icon/stories/topic.stories.js +2 -7
- package/lib/image-with-fallback.js +22 -52
- package/lib/input/components/search-bar.js +40 -85
- package/lib/input/components/text-field.js +20 -40
- package/lib/input/enums/index.js +6 -8
- package/lib/input/index.js +2 -7
- package/lib/input/stories/search-bar.stories.js +3 -16
- package/lib/input/stories/text-field.stories.js +3 -14
- package/lib/input/utils/theme.js +2 -9
- package/lib/is-fetching-wrapper.js +16 -48
- package/lib/junior-link.js +6 -29
- package/lib/link-with-tracker.js +14 -47
- package/lib/listing-page/components/card-list.js +20 -51
- package/lib/listing-page/components/image.js +15 -46
- package/lib/listing-page/components/list-item.js +18 -65
- package/lib/listing-page/components/list.js +17 -61
- package/lib/listing-page/components/page-content.js +2 -12
- package/lib/listing-page/components/topics/index.js +26 -74
- package/lib/listing-page/components/topics/post-item.js +14 -47
- package/lib/listing-page/components/topics/posts.js +1 -10
- package/lib/listing-page/components/topics/section.js +3 -25
- package/lib/listing-page/components/topics/topic-item.js +17 -56
- package/lib/listing-page/constants/mockup-spec.js +2 -3
- package/lib/listing-page/constants/predefined-css.js +2 -10
- package/lib/listing-page/constants/prop-types.js +2 -7
- package/lib/listing-page/constants/topics.js +2 -3
- package/lib/listing-page/index.js +2 -8
- package/lib/listing-page/stories/cardList.stories.js +3 -10
- package/lib/logo/components/logo-footer.js +6 -21
- package/lib/logo/components/logo-header.js +7 -23
- package/lib/logo/components/logo-loading-fallback.js +4 -13
- package/lib/logo/components/logo-symbol.js +7 -23
- package/lib/logo/index.js +2 -9
- package/lib/logo/stories/logoFooter.stories.js +2 -8
- package/lib/logo/stories/logoHeader.stories.js +3 -9
- package/lib/logo/stories/logoLoadingFallback.stories.js +2 -8
- package/lib/logo/stories/logoSymbol.stories.js +3 -9
- package/lib/logo/utils/path.js +2 -9
- package/lib/material-icon.js +9 -17
- package/lib/mobile-member-role-card/index.js +22 -49
- package/lib/mobile-member-role-card/stories/member-role-card.stories.js +3 -12
- package/lib/mobile-pop-up-modal.js +10 -44
- package/lib/more.js +10 -37
- package/lib/pagination/index.js +17 -83
- package/lib/podcast-link.js +6 -29
- package/lib/rwd.js +6 -26
- package/lib/shared-enum.js +2 -3
- package/lib/side-bar/index.js +16 -59
- package/lib/simple-header/index.js +2 -12
- package/lib/simple-header/simpleHeader.stories.js +3 -8
- package/lib/snack-bar/components/snack-bar.js +9 -20
- package/lib/snack-bar/hooks/use-snack-bar.js +12 -25
- package/lib/snack-bar/index.js +2 -7
- package/lib/snack-bar/stories/snackBar.stories.js +12 -29
- package/lib/snack-bar/utils/theme.js +3 -9
- package/lib/storybook/constants/index.js +3 -11
- package/lib/storybook/utils/get-enum-arg.js +2 -5
- package/lib/table-of-contents/index.js +62 -128
- package/lib/text/constants/headline-type.js +5 -8
- package/lib/text/enums/index.js +3 -5
- package/lib/text/headline.js +14 -41
- package/lib/text/paragraph.js +13 -34
- package/lib/text/stories/headline.stories.js +8 -21
- package/lib/text/stories/paragraph.stories.js +6 -17
- package/lib/text/utils/webfonts.js +9 -22
- package/lib/title-bar/components/tab.js +27 -69
- package/lib/title-bar/components/title1.js +6 -17
- package/lib/title-bar/components/title2.js +7 -23
- package/lib/title-bar/index.js +2 -8
- package/lib/title-bar/stories/tab.stories.js +5 -12
- package/lib/title-bar/stories/title1.stories.js +5 -12
- package/lib/title-bar/stories/title2.stories.js +3 -11
- package/lib/utils/link-with-params.js +0 -5
- package/package.json +4 -4
- package/lib/hook/use-store.js +0 -46
package/lib/input/index.js
CHANGED
|
@@ -16,15 +16,10 @@ Object.defineProperty(exports, "TextField", {
|
|
|
16
16
|
}
|
|
17
17
|
});
|
|
18
18
|
exports["default"] = void 0;
|
|
19
|
-
|
|
20
19
|
var _searchBar = _interopRequireDefault(require("./components/search-bar"));
|
|
21
|
-
|
|
22
20
|
var _textField = _interopRequireDefault(require("./components/text-field"));
|
|
23
|
-
|
|
24
21
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
25
|
-
|
|
26
|
-
var _default = {
|
|
22
|
+
var _default = exports["default"] = {
|
|
27
23
|
SearchBar: _searchBar["default"],
|
|
28
24
|
TextField: _textField["default"]
|
|
29
|
-
};
|
|
30
|
-
exports["default"] = _default;
|
|
25
|
+
};
|
|
@@ -4,18 +4,12 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.searchBar = exports["default"] = void 0;
|
|
7
|
-
|
|
8
7
|
var _getEnumArg = require("../../storybook/utils/get-enum-arg");
|
|
9
|
-
|
|
10
8
|
var _searchBar = _interopRequireDefault(require("../components/search-bar"));
|
|
11
|
-
|
|
12
9
|
var _constants = require("../../storybook/constants");
|
|
13
|
-
|
|
14
10
|
var _releaseBranch = require("@twreporter/core/lib/constants/release-branch");
|
|
15
|
-
|
|
16
11
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
17
|
-
|
|
18
|
-
var _default = {
|
|
12
|
+
var _default = exports["default"] = {
|
|
19
13
|
title: 'Input/Search Bar',
|
|
20
14
|
component: _searchBar["default"],
|
|
21
15
|
argTypes: {
|
|
@@ -24,21 +18,15 @@ var _default = {
|
|
|
24
18
|
theme: _constants.THEME_STORYBOOK_ARG_TYPE
|
|
25
19
|
}
|
|
26
20
|
};
|
|
27
|
-
exports["default"] = _default;
|
|
28
|
-
|
|
29
21
|
var onSearch = function onSearch(keyword) {
|
|
30
22
|
var _window;
|
|
31
|
-
|
|
32
23
|
return (_window = window) === null || _window === void 0 ? void 0 : _window.alert("search keyword: ".concat(keyword));
|
|
33
24
|
};
|
|
34
|
-
|
|
35
25
|
var onClose = function onClose() {
|
|
36
26
|
var _window2;
|
|
37
|
-
|
|
38
27
|
return (_window2 = window) === null || _window2 === void 0 ? void 0 : _window2.alert('click close !');
|
|
39
28
|
};
|
|
40
|
-
|
|
41
|
-
var searchBar = {
|
|
29
|
+
var searchBar = exports.searchBar = {
|
|
42
30
|
args: {
|
|
43
31
|
placeholder: '關鍵字搜尋',
|
|
44
32
|
theme: _searchBar["default"].THEME.normal,
|
|
@@ -48,5 +36,4 @@ var searchBar = {
|
|
|
48
36
|
autofocus: false,
|
|
49
37
|
widthType: _searchBar["default"].WidthType.FIT
|
|
50
38
|
}
|
|
51
|
-
};
|
|
52
|
-
exports.searchBar = searchBar;
|
|
39
|
+
};
|
|
@@ -4,19 +4,13 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.textField = exports["default"] = void 0;
|
|
7
|
-
|
|
8
7
|
var _react = _interopRequireDefault(require("react"));
|
|
9
|
-
|
|
10
8
|
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
11
|
-
|
|
12
9
|
var _getEnumArg = require("../../storybook/utils/get-enum-arg");
|
|
13
|
-
|
|
14
10
|
var _textField = _interopRequireDefault(require("../components/text-field"));
|
|
15
|
-
|
|
16
11
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
17
|
-
|
|
18
12
|
/* eslint react/display-name:0 */
|
|
19
|
-
var _default = {
|
|
13
|
+
var _default = exports["default"] = {
|
|
20
14
|
title: 'Input/Text Field',
|
|
21
15
|
component: _textField["default"],
|
|
22
16
|
argTypes: {
|
|
@@ -24,21 +18,17 @@ var _default = {
|
|
|
24
18
|
state: (0, _getEnumArg.getRadioArg)(_textField["default"].State, _textField["default"].State.DEFAULT)
|
|
25
19
|
}
|
|
26
20
|
};
|
|
27
|
-
exports["default"] = _default;
|
|
28
21
|
var Form = /*#__PURE__*/(0, _styledComponents["default"])(_textField["default"]).withConfig({
|
|
29
22
|
displayName: "text-fieldstories__Form",
|
|
30
23
|
componentId: "sc-1rwuni4-0"
|
|
31
24
|
})(["width:200px;"]);
|
|
32
|
-
|
|
33
25
|
var onSubmit = function onSubmit(value) {
|
|
34
26
|
console.log('submit', value);
|
|
35
27
|
};
|
|
36
|
-
|
|
37
28
|
var onChange = function onChange(value) {
|
|
38
29
|
console.log('change', value);
|
|
39
30
|
};
|
|
40
|
-
|
|
41
|
-
var textField = {
|
|
31
|
+
var textField = exports.textField = {
|
|
42
32
|
render: function render(args) {
|
|
43
33
|
return /*#__PURE__*/_react["default"].createElement(Form, args);
|
|
44
34
|
},
|
|
@@ -50,5 +40,4 @@ var textField = {
|
|
|
50
40
|
state: _textField["default"].State.DEFAULT,
|
|
51
41
|
message: '系統文字'
|
|
52
42
|
}
|
|
53
|
-
};
|
|
54
|
-
exports.textField = textField;
|
|
43
|
+
};
|
package/lib/input/utils/theme.js
CHANGED
|
@@ -4,12 +4,9 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.selectThemeStyle = void 0;
|
|
7
|
-
|
|
8
7
|
var _color = require("@twreporter/core/lib/constants/color");
|
|
9
|
-
|
|
10
8
|
var _theme = require("@twreporter/core/lib/constants/theme");
|
|
11
|
-
|
|
12
|
-
var selectThemeStyle = function selectThemeStyle(theme) {
|
|
9
|
+
var selectThemeStyle = exports.selectThemeStyle = function selectThemeStyle(theme) {
|
|
13
10
|
switch (theme) {
|
|
14
11
|
case _theme.THEME.photography:
|
|
15
12
|
return {
|
|
@@ -21,7 +18,6 @@ var selectThemeStyle = function selectThemeStyle(theme) {
|
|
|
21
18
|
focusColor: _color.colorGrayscale.gray500,
|
|
22
19
|
placeholderColor: _color.colorGrayscale.gray800
|
|
23
20
|
};
|
|
24
|
-
|
|
25
21
|
case _theme.THEME.transpareant:
|
|
26
22
|
return {
|
|
27
23
|
bgColor: _color.colorOpacity['gray100_0.8'],
|
|
@@ -32,7 +28,6 @@ var selectThemeStyle = function selectThemeStyle(theme) {
|
|
|
32
28
|
focusColor: _color.colorGrayscale.gray500,
|
|
33
29
|
placeholderColor: _color.colorGrayscale.gray500
|
|
34
30
|
};
|
|
35
|
-
|
|
36
31
|
case _theme.THEME.normal:
|
|
37
32
|
default:
|
|
38
33
|
return {
|
|
@@ -45,6 +40,4 @@ var selectThemeStyle = function selectThemeStyle(theme) {
|
|
|
45
40
|
placeholderColor: _color.colorGrayscale.gray500
|
|
46
41
|
};
|
|
47
42
|
}
|
|
48
|
-
};
|
|
49
|
-
|
|
50
|
-
exports.selectThemeStyle = selectThemeStyle;
|
|
43
|
+
};
|
|
@@ -1,56 +1,34 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
function _typeof(
|
|
4
|
-
|
|
3
|
+
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); }
|
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
|
6
5
|
value: true
|
|
7
6
|
});
|
|
8
7
|
exports["default"] = void 0;
|
|
9
|
-
|
|
10
8
|
var _storageUrlProcessor = require("@twreporter/core/lib/utils/storage-url-processor");
|
|
11
|
-
|
|
12
9
|
var storage = _interopRequireWildcard(require("@twreporter/core/lib/constants/storage"));
|
|
13
|
-
|
|
14
10
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
15
|
-
|
|
16
11
|
var _react = _interopRequireDefault(require("react"));
|
|
17
|
-
|
|
18
12
|
var _styledComponents = _interopRequireDefault(require("styled-components"));
|
|
19
|
-
|
|
20
13
|
var _excluded = ["isFetching", "showSpinner"];
|
|
21
|
-
|
|
22
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
23
|
-
|
|
24
|
-
function
|
|
25
|
-
|
|
26
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
27
|
-
|
|
15
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
16
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
|
|
28
17
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
29
|
-
|
|
30
18
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
31
|
-
|
|
32
19
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
33
|
-
|
|
34
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
35
|
-
|
|
20
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
36
21
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
37
|
-
|
|
22
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
23
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
38
24
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
39
|
-
|
|
40
25
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
41
|
-
|
|
42
26
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
43
|
-
|
|
44
27
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
45
|
-
|
|
46
28
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
47
|
-
|
|
48
29
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
49
|
-
|
|
50
30
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
51
|
-
|
|
52
31
|
var spinnerLogoUrl = "".concat(storage.google.schema, "://").concat(storage.google.hostname, "/").concat(storage.google.bucket, "/images/spinner-logo.gif");
|
|
53
|
-
|
|
54
32
|
var FetchingBlock = /*#__PURE__*/_styledComponents["default"].div.withConfig({
|
|
55
33
|
displayName: "is-fetching-wrapper__FetchingBlock",
|
|
56
34
|
componentId: "sc-1oo61h6-0"
|
|
@@ -59,35 +37,28 @@ var FetchingBlock = /*#__PURE__*/_styledComponents["default"].div.withConfig({
|
|
|
59
37
|
}, function (props) {
|
|
60
38
|
return props.$showSpinner ? "\n background-image: url(".concat((0, _storageUrlProcessor.replaceGCSUrlOrigin)(spinnerLogoUrl), ");\n background-position: center;\n background-repeat: no-repeat;\n ") : '';
|
|
61
39
|
});
|
|
62
|
-
|
|
63
40
|
var TransitionBlock = /*#__PURE__*/_styledComponents["default"].div.withConfig({
|
|
64
41
|
displayName: "is-fetching-wrapper__TransitionBlock",
|
|
65
42
|
componentId: "sc-1oo61h6-1"
|
|
66
43
|
})(["transition:opacity 1s ease-in-out;opacity:", ";"], function (props) {
|
|
67
44
|
return props.$isFetching ? 0 : 1;
|
|
68
45
|
});
|
|
69
|
-
|
|
70
46
|
var FetchingWrapper = function FetchingWrapper(WrappedComponent) {
|
|
71
47
|
var Wrapper = /*#__PURE__*/function (_React$PureComponent) {
|
|
72
48
|
_inherits(Wrapper, _React$PureComponent);
|
|
73
|
-
|
|
74
49
|
var _super = _createSuper(Wrapper);
|
|
75
|
-
|
|
76
50
|
function Wrapper() {
|
|
77
51
|
_classCallCheck(this, Wrapper);
|
|
78
|
-
|
|
79
52
|
return _super.apply(this, arguments);
|
|
80
53
|
}
|
|
81
|
-
|
|
82
54
|
_createClass(Wrapper, [{
|
|
83
55
|
key: "render",
|
|
84
56
|
value: function render() {
|
|
85
57
|
// TODO make client customize FetchingBlock
|
|
86
58
|
var _this$props = this.props,
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
59
|
+
isFetching = _this$props.isFetching,
|
|
60
|
+
showSpinner = _this$props.showSpinner,
|
|
61
|
+
rest = _objectWithoutProperties(_this$props, _excluded);
|
|
91
62
|
if ( /*#__PURE__*/_react["default"].isValidElement(WrappedComponent)) {
|
|
92
63
|
return /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(FetchingBlock, {
|
|
93
64
|
$isFetching: isFetching,
|
|
@@ -96,7 +67,6 @@ var FetchingWrapper = function FetchingWrapper(WrappedComponent) {
|
|
|
96
67
|
$isFetching: isFetching
|
|
97
68
|
}, WrappedComponent));
|
|
98
69
|
}
|
|
99
|
-
|
|
100
70
|
return /*#__PURE__*/_react["default"].createElement("div", null, /*#__PURE__*/_react["default"].createElement(FetchingBlock, {
|
|
101
71
|
$isFetching: isFetching,
|
|
102
72
|
$showSpinner: showSpinner
|
|
@@ -105,22 +75,20 @@ var FetchingWrapper = function FetchingWrapper(WrappedComponent) {
|
|
|
105
75
|
}, /*#__PURE__*/_react["default"].createElement(WrappedComponent, rest)));
|
|
106
76
|
}
|
|
107
77
|
}]);
|
|
108
|
-
|
|
109
78
|
return Wrapper;
|
|
110
79
|
}(_react["default"].PureComponent);
|
|
111
|
-
|
|
112
80
|
Wrapper.defaultProps = {
|
|
113
81
|
isFetching: false,
|
|
114
|
-
showSpinner: false
|
|
115
|
-
|
|
82
|
+
showSpinner: false
|
|
83
|
+
// fetchingBlockStyles: '',
|
|
116
84
|
};
|
|
85
|
+
|
|
117
86
|
Wrapper.propTypes = {
|
|
118
87
|
isFetching: _propTypes["default"].bool,
|
|
119
|
-
showSpinner: _propTypes["default"].bool
|
|
120
|
-
|
|
88
|
+
showSpinner: _propTypes["default"].bool
|
|
89
|
+
// fetchingBlockStyles: PropTypes.string,
|
|
121
90
|
};
|
|
91
|
+
|
|
122
92
|
return Wrapper;
|
|
123
93
|
};
|
|
124
|
-
|
|
125
|
-
var _default = FetchingWrapper;
|
|
126
|
-
exports["default"] = _default;
|
|
94
|
+
var _default = exports["default"] = FetchingWrapper;
|
package/lib/junior-link.js
CHANGED
|
@@ -1,53 +1,34 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
|
|
4
|
-
|
|
5
3
|
Object.defineProperty(exports, "__esModule", {
|
|
6
4
|
value: true
|
|
7
5
|
});
|
|
8
6
|
exports["default"] = void 0;
|
|
9
|
-
|
|
10
7
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
11
|
-
|
|
12
8
|
var _react = _interopRequireDefault(require("react"));
|
|
13
|
-
|
|
14
9
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
15
|
-
|
|
10
|
+
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); }
|
|
16
11
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
17
|
-
|
|
18
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
19
|
-
|
|
12
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
20
13
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
21
|
-
|
|
22
14
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
23
|
-
|
|
24
15
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
25
|
-
|
|
26
16
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
27
|
-
|
|
28
17
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
29
|
-
|
|
30
18
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
31
|
-
|
|
32
19
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
33
|
-
|
|
34
20
|
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
35
|
-
|
|
36
|
-
function
|
|
37
|
-
|
|
21
|
+
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; }
|
|
22
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
23
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
38
24
|
var juniorURL = 'https://kids.twreporter.org/';
|
|
39
|
-
|
|
40
25
|
var JuniorLink = /*#__PURE__*/function (_React$PureComponent) {
|
|
41
26
|
_inherits(JuniorLink, _React$PureComponent);
|
|
42
|
-
|
|
43
27
|
var _super = _createSuper(JuniorLink);
|
|
44
|
-
|
|
45
28
|
function JuniorLink() {
|
|
46
29
|
_classCallCheck(this, JuniorLink);
|
|
47
|
-
|
|
48
30
|
return _super.apply(this, arguments);
|
|
49
31
|
}
|
|
50
|
-
|
|
51
32
|
_createClass(JuniorLink, [{
|
|
52
33
|
key: "render",
|
|
53
34
|
value: function render() {
|
|
@@ -59,13 +40,9 @@ var JuniorLink = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
59
40
|
}, children);
|
|
60
41
|
}
|
|
61
42
|
}]);
|
|
62
|
-
|
|
63
43
|
return JuniorLink;
|
|
64
44
|
}(_react["default"].PureComponent);
|
|
65
|
-
|
|
66
45
|
_defineProperty(JuniorLink, "propTypes", {
|
|
67
46
|
children: _propTypes["default"].node
|
|
68
47
|
});
|
|
69
|
-
|
|
70
|
-
var _default = JuniorLink;
|
|
71
|
-
exports["default"] = _default;
|
|
48
|
+
var _default = exports["default"] = JuniorLink;
|
package/lib/link-with-tracker.js
CHANGED
|
@@ -1,74 +1,48 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
function _typeof(
|
|
4
|
-
|
|
3
|
+
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); }
|
|
5
4
|
Object.defineProperty(exports, "__esModule", {
|
|
6
5
|
value: true
|
|
7
6
|
});
|
|
8
7
|
exports["default"] = void 0;
|
|
9
|
-
|
|
10
8
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
11
|
-
|
|
12
9
|
var _react = _interopRequireWildcard(require("react"));
|
|
13
|
-
|
|
14
10
|
var _get = _interopRequireDefault(require("lodash/get"));
|
|
15
|
-
|
|
16
11
|
var _excluded = ["clickActionName", "href", "to", "rel", "target"];
|
|
17
|
-
|
|
18
|
-
function
|
|
19
|
-
|
|
20
|
-
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
21
|
-
|
|
12
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
13
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
|
|
22
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
23
|
-
|
|
24
15
|
function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
25
|
-
|
|
26
16
|
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
27
|
-
|
|
28
17
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
29
|
-
|
|
30
18
|
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
31
|
-
|
|
32
|
-
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } }
|
|
33
|
-
|
|
19
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
34
20
|
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
35
|
-
|
|
21
|
+
function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
|
|
22
|
+
function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
|
|
36
23
|
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
37
|
-
|
|
38
24
|
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
39
|
-
|
|
40
25
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
41
|
-
|
|
42
26
|
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
43
|
-
|
|
44
27
|
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
45
|
-
|
|
46
28
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
47
|
-
|
|
48
|
-
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
49
|
-
|
|
29
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); } /* global gtag ga */ // get
|
|
50
30
|
var _ = {
|
|
51
31
|
get: _get["default"]
|
|
52
32
|
};
|
|
53
33
|
var eventAction = 'Click';
|
|
54
34
|
var hitType = 'event';
|
|
55
35
|
var keysToBeTracked = ['Enter', 'NumpadEnter', 'Space'];
|
|
56
|
-
|
|
57
|
-
var TrackedLink = /*#__PURE__*/function (_PureComponent) {
|
|
36
|
+
var TrackedLink = exports["default"] = /*#__PURE__*/function (_PureComponent) {
|
|
58
37
|
_inherits(TrackedLink, _PureComponent);
|
|
59
|
-
|
|
60
38
|
var _super = _createSuper(TrackedLink);
|
|
61
|
-
|
|
62
39
|
function TrackedLink(props) {
|
|
63
40
|
var _this;
|
|
64
|
-
|
|
65
41
|
_classCallCheck(this, TrackedLink);
|
|
66
|
-
|
|
67
42
|
_this = _super.call(this, props);
|
|
68
43
|
_this.sendClickTrackingEvent = _this.sendClickTrackingEvent.bind(_assertThisInitialized(_this));
|
|
69
44
|
return _this;
|
|
70
45
|
}
|
|
71
|
-
|
|
72
46
|
_createClass(TrackedLink, [{
|
|
73
47
|
key: "isKeyToBeTracked",
|
|
74
48
|
value: function isKeyToBeTracked(keyCode) {
|
|
@@ -81,11 +55,8 @@ var TrackedLink = /*#__PURE__*/function (_PureComponent) {
|
|
|
81
55
|
value: function sendClickTrackingEvent(e) {
|
|
82
56
|
if (e.code && !this.isKeyToBeTracked(e.code)) return;
|
|
83
57
|
var clickActionName = this.props.clickActionName || 'undefined-click-action';
|
|
84
|
-
|
|
85
58
|
var url = _.get(window, 'location.href', 'null');
|
|
86
|
-
|
|
87
59
|
var eventLabel = "[".concat(clickActionName, "]: ").concat(url);
|
|
88
|
-
|
|
89
60
|
if (typeof gtag === 'function') {
|
|
90
61
|
try {
|
|
91
62
|
gtag(hitType, eventAction, {
|
|
@@ -112,13 +83,12 @@ var TrackedLink = /*#__PURE__*/function (_PureComponent) {
|
|
|
112
83
|
key: "render",
|
|
113
84
|
value: function render() {
|
|
114
85
|
var _this$props = this.props,
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
86
|
+
clickActionName = _this$props.clickActionName,
|
|
87
|
+
href = _this$props.href,
|
|
88
|
+
to = _this$props.to,
|
|
89
|
+
rel = _this$props.rel,
|
|
90
|
+
target = _this$props.target,
|
|
91
|
+
elseProps = _objectWithoutProperties(_this$props, _excluded);
|
|
122
92
|
return (
|
|
123
93
|
/*#__PURE__*/
|
|
124
94
|
// eslint-disable-next-line jsx-a11y/anchor-has-content
|
|
@@ -132,11 +102,8 @@ var TrackedLink = /*#__PURE__*/function (_PureComponent) {
|
|
|
132
102
|
);
|
|
133
103
|
}
|
|
134
104
|
}]);
|
|
135
|
-
|
|
136
105
|
return TrackedLink;
|
|
137
106
|
}(_react.PureComponent);
|
|
138
|
-
|
|
139
|
-
exports["default"] = TrackedLink;
|
|
140
107
|
TrackedLink.propTypes = {
|
|
141
108
|
clickActionName: _propTypes["default"].string,
|
|
142
109
|
href: _propTypes["default"].string,
|