@times-components/markup 3.6.3 → 3.7.1
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 +19 -0
- package/README.md +2 -8
- package/babel.config.js +6 -5
- package/dist/markup.js +68 -1
- package/package.json +13 -23
- package/rnw.js +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,25 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [3.7.1](https://github.com/newsuk/times-components/compare/@times-components/markup@3.7.0...@times-components/markup@3.7.1) (2022-10-13)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @times-components/markup
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
# [3.7.0](https://github.com/newsuk/times-components/compare/@times-components/markup@3.6.3...@times-components/markup@3.7.0) (2022-08-18)
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
### Features
|
|
18
|
+
|
|
19
|
+
* **TDP-1712:** remove react-native foreverrrrr ([#3064](https://github.com/newsuk/times-components/issues/3064)) ([2a20cb5](https://github.com/newsuk/times-components/commit/2a20cb5abc10a4e7ca2d62487967f8fcf4eccb62)), closes [#3037](https://github.com/newsuk/times-components/issues/3037) [#3045](https://github.com/newsuk/times-components/issues/3045) [#3050](https://github.com/newsuk/times-components/issues/3050) [#3056](https://github.com/newsuk/times-components/issues/3056) [#3057](https://github.com/newsuk/times-components/issues/3057) [#3066](https://github.com/newsuk/times-components/issues/3066) [#3065](https://github.com/newsuk/times-components/issues/3065) [#3037](https://github.com/newsuk/times-components/issues/3037) [#3045](https://github.com/newsuk/times-components/issues/3045) [#3045](https://github.com/newsuk/times-components/issues/3045) [#3056](https://github.com/newsuk/times-components/issues/3056) [#3066](https://github.com/newsuk/times-components/issues/3066) [#3069](https://github.com/newsuk/times-components/issues/3069) [#3068](https://github.com/newsuk/times-components/issues/3068) [#3070](https://github.com/newsuk/times-components/issues/3070) [#3072](https://github.com/newsuk/times-components/issues/3072) [#3073](https://github.com/newsuk/times-components/issues/3073) [#3071](https://github.com/newsuk/times-components/issues/3071) [#3074](https://github.com/newsuk/times-components/issues/3074) [#3076](https://github.com/newsuk/times-components/issues/3076) [#3079](https://github.com/newsuk/times-components/issues/3079) [#3078](https://github.com/newsuk/times-components/issues/3078) [#3083](https://github.com/newsuk/times-components/issues/3083) [#3087](https://github.com/newsuk/times-components/issues/3087) [#3091](https://github.com/newsuk/times-components/issues/3091) [#3096](https://github.com/newsuk/times-components/issues/3096) [#3102](https://github.com/newsuk/times-components/issues/3102) [#3105](https://github.com/newsuk/times-components/issues/3105) [#3108](https://github.com/newsuk/times-components/issues/3108) [#3111](https://github.com/newsuk/times-components/issues/3111) [#3112](https://github.com/newsuk/times-components/issues/3112) [#3113](https://github.com/newsuk/times-components/issues/3113) [#3114](https://github.com/newsuk/times-components/issues/3114) [#3120](https://github.com/newsuk/times-components/issues/3120) [#3119](https://github.com/newsuk/times-components/issues/3119) [#3112](https://github.com/newsuk/times-components/issues/3112) [#3126](https://github.com/newsuk/times-components/issues/3126) [#3112](https://github.com/newsuk/times-components/issues/3112) [#3126](https://github.com/newsuk/times-components/issues/3126) [#3127](https://github.com/newsuk/times-components/issues/3127) [#3116](https://github.com/newsuk/times-components/issues/3116) [#3128](https://github.com/newsuk/times-components/issues/3128) [#3132](https://github.com/newsuk/times-components/issues/3132) [#3133](https://github.com/newsuk/times-components/issues/3133)
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
|
|
6
25
|
## [3.6.3](https://github.com/newsuk/times-components/compare/@times-components/markup@3.6.2...@times-components/markup@3.6.3) (2022-08-05)
|
|
7
26
|
|
|
8
27
|
**Note:** Version bump only for package @times-components/markup
|
package/README.md
CHANGED
|
@@ -18,7 +18,7 @@ functions from `markup-forest`, which iterates over and renders with the given
|
|
|
18
18
|
- text
|
|
19
19
|
|
|
20
20
|
This package should only have core renderers with no dependencies beyond
|
|
21
|
-
React
|
|
21
|
+
React. If a consumer would like to support more complex elements
|
|
22
22
|
they'll need to provide renderers for them.
|
|
23
23
|
|
|
24
24
|
## Contributing
|
|
@@ -41,7 +41,7 @@ yarn lint
|
|
|
41
41
|
|
|
42
42
|
## Testing
|
|
43
43
|
|
|
44
|
-
Testing can be done
|
|
44
|
+
Testing can be done by running:
|
|
45
45
|
|
|
46
46
|
```
|
|
47
47
|
yarn test:web
|
|
@@ -76,12 +76,6 @@ const data = [
|
|
|
76
76
|
renderTrees(data, coreRenderers);
|
|
77
77
|
|
|
78
78
|
/*
|
|
79
|
-
native
|
|
80
|
-
|
|
81
|
-
<Text>
|
|
82
|
-
Some text value here
|
|
83
|
-
</Text>
|
|
84
|
-
|
|
85
79
|
web
|
|
86
80
|
|
|
87
81
|
<span>
|
package/babel.config.js
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
module.exports = api => {
|
|
2
2
|
api.cache(true);
|
|
3
3
|
return {
|
|
4
|
-
plugins: [
|
|
5
|
-
|
|
6
|
-
"@babel/
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
plugins: ["babel-plugin-styled-components"],
|
|
5
|
+
presets: [
|
|
6
|
+
"@babel/preset-env",
|
|
7
|
+
"@babel/preset-react",
|
|
8
|
+
"@babel/preset-typescript"
|
|
9
|
+
]
|
|
9
10
|
};
|
|
10
11
|
};
|
package/dist/markup.js
CHANGED
|
@@ -1 +1,68 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports["default"] = void 0;
|
|
7
|
+
|
|
8
|
+
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
|
|
10
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
11
|
+
|
|
12
|
+
var _default = {
|
|
13
|
+
block: function block(key, attributes, renderedChildren) {
|
|
14
|
+
return /*#__PURE__*/_react["default"].createElement("div", {
|
|
15
|
+
key: key
|
|
16
|
+
}, renderedChildren);
|
|
17
|
+
},
|
|
18
|
+
bold: function bold(key, attributes, renderedChildren) {
|
|
19
|
+
return /*#__PURE__*/_react["default"].createElement("b", {
|
|
20
|
+
key: key
|
|
21
|
+
}, renderedChildren);
|
|
22
|
+
},
|
|
23
|
+
"break": function _break(key) {
|
|
24
|
+
return /*#__PURE__*/_react["default"].createElement("br", {
|
|
25
|
+
key: key
|
|
26
|
+
});
|
|
27
|
+
},
|
|
28
|
+
emphasis: function emphasis(key, attributes, renderedChildren) {
|
|
29
|
+
return /*#__PURE__*/_react["default"].createElement("em", {
|
|
30
|
+
key: key
|
|
31
|
+
}, renderedChildren);
|
|
32
|
+
},
|
|
33
|
+
inline: function inline(key, attributes, renderedChildren) {
|
|
34
|
+
return /*#__PURE__*/_react["default"].createElement("span", {
|
|
35
|
+
key: key
|
|
36
|
+
}, renderedChildren);
|
|
37
|
+
},
|
|
38
|
+
italic: function italic(key, attributes, renderedChildren) {
|
|
39
|
+
return /*#__PURE__*/_react["default"].createElement("i", {
|
|
40
|
+
key: key
|
|
41
|
+
}, renderedChildren);
|
|
42
|
+
},
|
|
43
|
+
paragraph: function paragraph(key, attributes, renderedChildren) {
|
|
44
|
+
return /*#__PURE__*/_react["default"].createElement("p", {
|
|
45
|
+
key: key
|
|
46
|
+
}, renderedChildren);
|
|
47
|
+
},
|
|
48
|
+
strong: function strong(key, attributes, renderedChildren) {
|
|
49
|
+
return /*#__PURE__*/_react["default"].createElement("strong", {
|
|
50
|
+
key: key
|
|
51
|
+
}, renderedChildren);
|
|
52
|
+
},
|
|
53
|
+
subscript: function subscript(key, attributes, renderedChildren) {
|
|
54
|
+
return /*#__PURE__*/_react["default"].createElement("sub", {
|
|
55
|
+
key: key
|
|
56
|
+
}, renderedChildren);
|
|
57
|
+
},
|
|
58
|
+
superscript: function superscript(key, attributes, renderedChildren) {
|
|
59
|
+
return /*#__PURE__*/_react["default"].createElement("sup", {
|
|
60
|
+
key: key
|
|
61
|
+
}, renderedChildren);
|
|
62
|
+
},
|
|
63
|
+
text: function text(key, _ref) {
|
|
64
|
+
var value = _ref.value;
|
|
65
|
+
return value;
|
|
66
|
+
}
|
|
67
|
+
};
|
|
68
|
+
exports["default"] = _default;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@times-components/markup",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.7.1",
|
|
4
4
|
"description": "a component which takes an HTML ast and renders the platform specific markup",
|
|
5
5
|
"main": "dist/markup",
|
|
6
6
|
"dev": "src/markup",
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"prettier:diff": "prettier --list-different '**/*.*'",
|
|
10
10
|
"depcheck": "depcheck --ignores='@babel/*,babel-*,depcheck,eslint,jest,prettier,react-art,webpack*' --ignore-bin-package=false --skip-missing",
|
|
11
11
|
"lint": "eslint . && yarn prettier:diff && yarn depcheck",
|
|
12
|
-
"test:web": "jest --config='./__tests__/
|
|
12
|
+
"test:web": "jest --config='./__tests__/jest.config.js'",
|
|
13
13
|
"prepublishOnly": "yarn transpile && yarn bundle",
|
|
14
14
|
"watch": "watch 'yarn bundle' ./src --ignoreDotFiles --ignoreUnreadable",
|
|
15
15
|
"cleanup-dist": "rm -rf dist",
|
|
@@ -21,9 +21,7 @@
|
|
|
21
21
|
"url": "git+https://github.com/newsuk/times-components.git"
|
|
22
22
|
},
|
|
23
23
|
"keywords": [
|
|
24
|
-
"react-native-web",
|
|
25
24
|
"react",
|
|
26
|
-
"native",
|
|
27
25
|
"web",
|
|
28
26
|
"markup",
|
|
29
27
|
"component"
|
|
@@ -36,32 +34,26 @@
|
|
|
36
34
|
"devDependencies": {
|
|
37
35
|
"@babel/core": "7.4.4",
|
|
38
36
|
"@times-components/eslint-config-thetimes": "0.8.18",
|
|
39
|
-
"@times-components/jest-configurator": "
|
|
40
|
-
"@times-components/jest-serializer": "3.
|
|
41
|
-
"@times-components/markup-forest": "1.
|
|
42
|
-
"@times-components/storybook": "4.
|
|
43
|
-
"@times-components/test-utils": "2.
|
|
44
|
-
"@times-components/webpack-configurator": "2.0
|
|
37
|
+
"@times-components/jest-configurator-web": "0.8.0",
|
|
38
|
+
"@times-components/jest-serializer": "3.4.1",
|
|
39
|
+
"@times-components/markup-forest": "1.9.0",
|
|
40
|
+
"@times-components/storybook": "4.5.1",
|
|
41
|
+
"@times-components/test-utils": "2.4.0",
|
|
42
|
+
"@times-components/webpack-configurator": "2.1.0",
|
|
45
43
|
"babel-jest": "24.8.0",
|
|
46
44
|
"babel-loader": "8.0.5",
|
|
47
|
-
"babel-plugin-add-react-displayname": "0.0.5",
|
|
48
|
-
"babel-plugin-styled-components": "1.10.6",
|
|
49
45
|
"depcheck": "0.6.9",
|
|
50
46
|
"enzyme": "3.9.0",
|
|
51
47
|
"eslint": "5.9.0",
|
|
52
48
|
"jest": "24.8.0",
|
|
53
49
|
"prettier": "1.14.3",
|
|
54
50
|
"react": "16.9.0",
|
|
55
|
-
"react-art": "16.6.3",
|
|
56
51
|
"react-dom": "16.9.0",
|
|
57
|
-
"
|
|
58
|
-
"react-native-web": "0.11.4",
|
|
59
|
-
"webpack": "4.30.0",
|
|
60
|
-
"webpack-cli": "3.3.1"
|
|
52
|
+
"webpack": "4.30.0"
|
|
61
53
|
},
|
|
62
54
|
"dependencies": {
|
|
63
|
-
"@times-components/ts-styleguide": "1.
|
|
64
|
-
"@times-components/utils": "6.
|
|
55
|
+
"@times-components/ts-styleguide": "1.37.1",
|
|
56
|
+
"@times-components/utils": "6.15.1"
|
|
65
57
|
},
|
|
66
58
|
"resolutions": {
|
|
67
59
|
"react": "16.9.0",
|
|
@@ -69,12 +61,10 @@
|
|
|
69
61
|
},
|
|
70
62
|
"peerDependencies": {
|
|
71
63
|
"react": ">=16.9",
|
|
72
|
-
"react-dom": ">=16.9"
|
|
73
|
-
"react-native": ">=0.59",
|
|
74
|
-
"react-native-web": "0.11.4"
|
|
64
|
+
"react-dom": ">=16.9"
|
|
75
65
|
},
|
|
76
66
|
"publishConfig": {
|
|
77
67
|
"access": "public"
|
|
78
68
|
},
|
|
79
|
-
"gitHead": "
|
|
69
|
+
"gitHead": "d33c3115e165e09794ffdfd7931e217620f7ce07"
|
|
80
70
|
}
|
package/rnw.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
module.exports=function(e){var t={};function r
|
|
1
|
+
module.exports=function(e){var t={};function n(r){if(t[r])return t[r].exports;var u=t[r]={i:r,l:!1,exports:{}};return e[r].call(u.exports,u,u.exports,n),u.l=!0,u.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},n.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.t=function(e,t){if(1&t&&(e=n(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var u in e)n.d(r,u,function(t){return e[t]}.bind(null,u));return r},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=1)}([function(e,t){e.exports=require("react")},function(e,t,n){"use strict";n.r(t);var r=n(0),u=n.n(r);t.default={block:function(e,t,n){return u.a.createElement("div",{key:e},n)},bold:function(e,t,n){return u.a.createElement("b",{key:e},n)},break:function(e){return u.a.createElement("br",{key:e})},emphasis:function(e,t,n){return u.a.createElement("em",{key:e},n)},inline:function(e,t,n){return u.a.createElement("span",{key:e},n)},italic:function(e,t,n){return u.a.createElement("i",{key:e},n)},paragraph:function(e,t,n){return u.a.createElement("p",{key:e},n)},strong:function(e,t,n){return u.a.createElement("strong",{key:e},n)},subscript:function(e,t,n){return u.a.createElement("sub",{key:e},n)},superscript:function(e,t,n){return u.a.createElement("sup",{key:e},n)},text:function(e,t){return t.value}}}]);
|