@telus-uds/components-community.content-card 1.2.2 → 1.2.4
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 -2
- package/lib/ContentCard.js +3 -10
- package/lib-module/ContentCard.js +3 -7
- package/package.json +3 -3
- package/src/ContentCard.jsx +3 -8
package/CHANGELOG.md
CHANGED
|
@@ -1,12 +1,29 @@
|
|
|
1
1
|
# Change Log - @telus-uds/components-community.content-card
|
|
2
2
|
|
|
3
|
-
This log was last generated on
|
|
3
|
+
This log was last generated on Thu, 23 May 2024 16:27:45 GMT and should not be manually modified.
|
|
4
4
|
|
|
5
5
|
<!-- Start content -->
|
|
6
6
|
|
|
7
|
+
## 1.2.4
|
|
8
|
+
|
|
9
|
+
Thu, 23 May 2024 16:27:45 GMT
|
|
10
|
+
|
|
11
|
+
### Patches
|
|
12
|
+
|
|
13
|
+
- Bump @telus-uds/components-base to v1.85.1
|
|
14
|
+
|
|
15
|
+
## 1.2.3
|
|
16
|
+
|
|
17
|
+
Fri, 17 May 2024 16:34:46 GMT
|
|
18
|
+
|
|
19
|
+
### Patches
|
|
20
|
+
|
|
21
|
+
- Bump @telus-uds/components-base to v1.85.0
|
|
22
|
+
- Bump @telus-uds/system-theme-tokens to v2.56.0
|
|
23
|
+
|
|
7
24
|
## 1.2.2
|
|
8
25
|
|
|
9
|
-
Mon, 06 May 2024 16:
|
|
26
|
+
Mon, 06 May 2024 16:39:58 GMT
|
|
10
27
|
|
|
11
28
|
### Patches
|
|
12
29
|
|
package/lib/ContentCard.js
CHANGED
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.styles = exports.default = void 0;
|
|
7
|
-
var _react =
|
|
7
|
+
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
var _propTypes = _interopRequireDefault(require("prop-types"));
|
|
9
9
|
var _componentsBase = require("@telus-uds/components-base");
|
|
10
10
|
var _StyleSheet = _interopRequireDefault(require("react-native-web/dist/cjs/exports/StyleSheet"));
|
|
@@ -12,10 +12,6 @@ var _View = _interopRequireDefault(require("react-native-web/dist/cjs/exports/Vi
|
|
|
12
12
|
var _ImageBackground = _interopRequireDefault(require("react-native-web/dist/cjs/exports/ImageBackground"));
|
|
13
13
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
14
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
15
|
-
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function (nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
16
|
-
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; }
|
|
17
|
-
/* eslint-disable react/require-default-props */
|
|
18
|
-
|
|
19
15
|
const styles = _StyleSheet.default.create({
|
|
20
16
|
rowReverse: {
|
|
21
17
|
flexDirection: 'row-reverse'
|
|
@@ -35,7 +31,7 @@ const styles = _StyleSheet.default.create({
|
|
|
35
31
|
// Passes React Native-oriented system props through UDS PressableCardBase
|
|
36
32
|
exports.styles = styles;
|
|
37
33
|
const [selectProps, selectedSystemPropTypes] = (0, _componentsBase.selectSystemProps)([_componentsBase.a11yProps, _componentsBase.focusHandlerProps, _componentsBase.viewProps]);
|
|
38
|
-
const ContentCard = /*#__PURE__*/
|
|
34
|
+
const ContentCard = /*#__PURE__*/_react.default.forwardRef((_ref, ref) => {
|
|
39
35
|
let {
|
|
40
36
|
title,
|
|
41
37
|
content,
|
|
@@ -46,7 +42,7 @@ const ContentCard = /*#__PURE__*/(0, _react.forwardRef)((_ref, ref) => {
|
|
|
46
42
|
imageSrc,
|
|
47
43
|
imageHeight,
|
|
48
44
|
imageWidth,
|
|
49
|
-
isContentOnRight,
|
|
45
|
+
isContentOnRight = false,
|
|
50
46
|
tokens,
|
|
51
47
|
...rest
|
|
52
48
|
} = _ref;
|
|
@@ -181,8 +177,5 @@ ContentCard.propTypes = {
|
|
|
181
177
|
*/
|
|
182
178
|
isContentOnRight: _propTypes.default.bool
|
|
183
179
|
};
|
|
184
|
-
ContentCard.defaultProps = {
|
|
185
|
-
isContentOnRight: false
|
|
186
|
-
};
|
|
187
180
|
var _default = (0, _componentsBase.withLinkRouter)(ContentCard);
|
|
188
181
|
exports.default = _default;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import React, { forwardRef } from 'react';
|
|
1
|
+
import React from 'react';
|
|
3
2
|
import PropTypes from 'prop-types';
|
|
4
3
|
import { Typography, Spacer, ChevronLink, PressableCardBase, selectSystemProps, hrefAttrsProp, withLinkRouter, a11yProps, focusHandlerProps, useThemeTokensCallback, useViewport, useThemeTokens, Box, viewProps } from '@telus-uds/components-base';
|
|
5
4
|
import StyleSheet from "react-native-web/dist/exports/StyleSheet";
|
|
@@ -25,7 +24,7 @@ export const styles = StyleSheet.create({
|
|
|
25
24
|
|
|
26
25
|
// Passes React Native-oriented system props through UDS PressableCardBase
|
|
27
26
|
const [selectProps, selectedSystemPropTypes] = selectSystemProps([a11yProps, focusHandlerProps, viewProps]);
|
|
28
|
-
const ContentCard = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
27
|
+
const ContentCard = /*#__PURE__*/React.forwardRef((_ref, ref) => {
|
|
29
28
|
let {
|
|
30
29
|
title,
|
|
31
30
|
content,
|
|
@@ -36,7 +35,7 @@ const ContentCard = /*#__PURE__*/forwardRef((_ref, ref) => {
|
|
|
36
35
|
imageSrc,
|
|
37
36
|
imageHeight,
|
|
38
37
|
imageWidth,
|
|
39
|
-
isContentOnRight,
|
|
38
|
+
isContentOnRight = false,
|
|
40
39
|
tokens,
|
|
41
40
|
...rest
|
|
42
41
|
} = _ref;
|
|
@@ -171,7 +170,4 @@ ContentCard.propTypes = {
|
|
|
171
170
|
*/
|
|
172
171
|
isContentOnRight: PropTypes.bool
|
|
173
172
|
};
|
|
174
|
-
ContentCard.defaultProps = {
|
|
175
|
-
isContentOnRight: false
|
|
176
|
-
};
|
|
177
173
|
export default withLinkRouter(ContentCard);
|
package/package.json
CHANGED
|
@@ -4,12 +4,12 @@
|
|
|
4
4
|
"extends @telus-uds/browserslist-config"
|
|
5
5
|
],
|
|
6
6
|
"dependencies": {
|
|
7
|
-
"@telus-uds/components-base": "^1.
|
|
7
|
+
"@telus-uds/components-base": "^1.85.1",
|
|
8
8
|
"prop-types": "^15.7.2"
|
|
9
9
|
},
|
|
10
10
|
"devDependencies": {
|
|
11
11
|
"@telus-uds/browserslist-config": "^1.0.5",
|
|
12
|
-
"@telus-uds/system-theme-tokens": "^2.
|
|
12
|
+
"@telus-uds/system-theme-tokens": "^2.56.0",
|
|
13
13
|
"@testing-library/react-native": "11.0.0",
|
|
14
14
|
"babel-plugin-react-native-web": "^0.17.0",
|
|
15
15
|
"babel-plugin-styled-components": "^2.0.6",
|
|
@@ -44,5 +44,5 @@
|
|
|
44
44
|
"standard-engine": {
|
|
45
45
|
"skip": true
|
|
46
46
|
},
|
|
47
|
-
"version": "1.2.
|
|
47
|
+
"version": "1.2.4"
|
|
48
48
|
}
|
package/src/ContentCard.jsx
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
import React, { forwardRef } from 'react'
|
|
1
|
+
import React from 'react'
|
|
3
2
|
import PropTypes from 'prop-types'
|
|
4
3
|
import {
|
|
5
4
|
Typography,
|
|
@@ -42,7 +41,7 @@ const [selectProps, selectedSystemPropTypes] = selectSystemProps([
|
|
|
42
41
|
viewProps
|
|
43
42
|
])
|
|
44
43
|
|
|
45
|
-
const ContentCard = forwardRef(
|
|
44
|
+
const ContentCard = React.forwardRef(
|
|
46
45
|
(
|
|
47
46
|
{
|
|
48
47
|
title,
|
|
@@ -54,7 +53,7 @@ const ContentCard = forwardRef(
|
|
|
54
53
|
imageSrc,
|
|
55
54
|
imageHeight,
|
|
56
55
|
imageWidth,
|
|
57
|
-
isContentOnRight,
|
|
56
|
+
isContentOnRight = false,
|
|
58
57
|
tokens,
|
|
59
58
|
...rest
|
|
60
59
|
},
|
|
@@ -170,8 +169,4 @@ ContentCard.propTypes = {
|
|
|
170
169
|
isContentOnRight: PropTypes.bool
|
|
171
170
|
}
|
|
172
171
|
|
|
173
|
-
ContentCard.defaultProps = {
|
|
174
|
-
isContentOnRight: false
|
|
175
|
-
}
|
|
176
|
-
|
|
177
172
|
export default withLinkRouter(ContentCard)
|