@twreporter/index-page 1.3.2 → 1.3.3-rc.2
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 +27 -0
- package/lib/components/category-section.js +9 -15
- package/lib/components/common-utils/mobile-list.js +7 -3
- package/lib/components/common-utils/section-content-wrapper.js +3 -1
- package/lib/components/common-utils/section-name.js +3 -3
- package/lib/components/common-utils/section.js +2 -2
- package/lib/components/donation-box-section.js +6 -6
- package/lib/components/editor-picks.js +24 -22
- package/lib/components/infographic-section.js +13 -21
- package/lib/components/junior-box-section.js +6 -6
- package/lib/components/latest-section.js +9 -8
- package/lib/components/latest-topic.js +13 -20
- package/lib/components/mobile-flex-swipeable.js +13 -16
- package/lib/components/news-letter-section.js +8 -8
- package/lib/components/photography-section.js +10 -11
- package/lib/components/podcast-box-section.js +6 -6
- package/lib/components/reviews.js +11 -17
- package/lib/components/topics-section.js +6 -7
- package/lib/utils/style-utils.js +2 -32
- package/package.json +4 -4
package/lib/utils/style-utils.js
CHANGED
|
@@ -4,10 +4,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.truncate = truncate;
|
|
7
|
-
exports.
|
|
8
|
-
|
|
9
|
-
var _styledComponents = require("styled-components");
|
|
10
|
-
|
|
7
|
+
exports.breakPoints = exports.centerBlock = void 0;
|
|
11
8
|
var centerBlock = "\n margin-left: auto;\n margin-right: auto;\n";
|
|
12
9
|
exports.centerBlock = centerBlock;
|
|
13
10
|
var breakPoints = {
|
|
@@ -18,33 +15,6 @@ var breakPoints = {
|
|
|
18
15
|
tabletMinWidth: '768px',
|
|
19
16
|
mobileMaxWidth: '767px'
|
|
20
17
|
};
|
|
21
|
-
exports.breakPoints = breakPoints;
|
|
22
|
-
var finalMedia = {
|
|
23
|
-
mobile: function mobile() {
|
|
24
|
-
return (0, _styledComponents.css)(["@media (max-width:", "){", "}"], breakPoints.mobileMaxWidth, _styledComponents.css.apply(void 0, arguments));
|
|
25
|
-
},
|
|
26
|
-
tabletAbove: function tabletAbove() {
|
|
27
|
-
return (0, _styledComponents.css)(["@media (min-width:", "){", "}"], breakPoints.tabletMinWidth, _styledComponents.css.apply(void 0, arguments));
|
|
28
|
-
},
|
|
29
|
-
tablet: function tablet() {
|
|
30
|
-
return (0, _styledComponents.css)(["@media (min-width:", ") and (max-width:", "){", "}"], breakPoints.tabletMinWidth, breakPoints.tabletMaxWidth, _styledComponents.css.apply(void 0, arguments));
|
|
31
|
-
},
|
|
32
|
-
tabletBelow: function tabletBelow() {
|
|
33
|
-
return (0, _styledComponents.css)(["@media (max-width:", "){", "}"], breakPoints.tabletMaxWidth, _styledComponents.css.apply(void 0, arguments));
|
|
34
|
-
},
|
|
35
|
-
desktopAbove: function desktopAbove() {
|
|
36
|
-
return (0, _styledComponents.css)(["@media (min-width:", "){", "}"], breakPoints.desktopMinWidth, _styledComponents.css.apply(void 0, arguments));
|
|
37
|
-
},
|
|
38
|
-
desktop: function desktop() {
|
|
39
|
-
return (0, _styledComponents.css)(["@media (min-width:", ") and (max-width:", "){", "}"], breakPoints.desktopMinWidth, breakPoints.desktopMaxWidth, _styledComponents.css.apply(void 0, arguments));
|
|
40
|
-
},
|
|
41
|
-
desktopBelow: function desktopBelow() {
|
|
42
|
-
return (0, _styledComponents.css)(["@media (max-width:", "){", "}"], breakPoints.desktopMaxWidth, _styledComponents.css.apply(void 0, arguments));
|
|
43
|
-
},
|
|
44
|
-
overDesktop: function overDesktop() {
|
|
45
|
-
return (0, _styledComponents.css)(["@media (min-width:", "){", "}"], breakPoints.overDesktopMinWidth, _styledComponents.css.apply(void 0, arguments));
|
|
46
|
-
}
|
|
47
|
-
};
|
|
48
18
|
/**
|
|
49
19
|
* @prop {string} position - postion of the content div
|
|
50
20
|
* @prop {number} lineHeight - line-height
|
|
@@ -53,7 +23,7 @@ var finalMedia = {
|
|
|
53
23
|
* @prop {string} textAlign - text-align
|
|
54
24
|
*/
|
|
55
25
|
|
|
56
|
-
exports.
|
|
26
|
+
exports.breakPoints = breakPoints;
|
|
57
27
|
|
|
58
28
|
function truncate(position, lineHeight, numberOfLine, backgroundColor, textAlign) {
|
|
59
29
|
var maxHeight = lineHeight * numberOfLine;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@twreporter/index-page",
|
|
3
|
-
"version": "1.3.2",
|
|
3
|
+
"version": "1.3.3-rc.2",
|
|
4
4
|
"main": "lib/index.js",
|
|
5
5
|
"repository": "https://github.com/twreporter/twreporter-npm-packages.git",
|
|
6
6
|
"author": "twreporter <developer@twreporter.org>",
|
|
@@ -12,8 +12,8 @@
|
|
|
12
12
|
"prepublishOnly": "make build"
|
|
13
13
|
},
|
|
14
14
|
"dependencies": {
|
|
15
|
-
"@twreporter/core": "^1.
|
|
16
|
-
"@twreporter/react-components": "^8.12.
|
|
15
|
+
"@twreporter/core": "^1.6.0-rc.0",
|
|
16
|
+
"@twreporter/react-components": "^8.12.1-rc.1",
|
|
17
17
|
"lodash": "^4.0.0",
|
|
18
18
|
"prop-types": "^15.0.0",
|
|
19
19
|
"react": "^16.3.0",
|
|
@@ -27,5 +27,5 @@
|
|
|
27
27
|
"files": [
|
|
28
28
|
"lib"
|
|
29
29
|
],
|
|
30
|
-
"gitHead": "
|
|
30
|
+
"gitHead": "0d20c113cb1bb3bf8adc165794eada91e1fe2fd6"
|
|
31
31
|
}
|