@wlloyalty/wll-react-sdk 1.0.8 → 1.0.10
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/dist/index.d.ts +1 -1
- package/dist/index.js +11 -11
- package/dist/index.js.map +1 -1
- package/package.json +1 -2
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -18322,11 +18322,11 @@ var BaseTileMedia = function (props) {
|
|
|
18322
18322
|
var _a = tile.configuration,
|
|
18323
18323
|
artworkUrl = _a.artworkUrl,
|
|
18324
18324
|
title = _a.title,
|
|
18325
|
-
|
|
18325
|
+
body = _a.body;
|
|
18326
18326
|
var isHalfSize = useTileSize(tile).isHalfSize;
|
|
18327
18327
|
if (!artworkUrl) return null;
|
|
18328
18328
|
var hasTitle = !!title;
|
|
18329
|
-
var hasDescription = !!
|
|
18329
|
+
var hasDescription = !!body;
|
|
18330
18330
|
return /*#__PURE__*/React.createElement(ProgressiveImage, _extends({}, props, {
|
|
18331
18331
|
source: {
|
|
18332
18332
|
uri: artworkUrl
|
|
@@ -18358,16 +18358,15 @@ var BaseTileTitle = function () {
|
|
|
18358
18358
|
var BaseTileBody = function (props) {
|
|
18359
18359
|
var tile = useTileContext();
|
|
18360
18360
|
var _a = tile.configuration,
|
|
18361
|
-
|
|
18361
|
+
body = _a.body,
|
|
18362
18362
|
artworkUrl = _a.artworkUrl;
|
|
18363
18363
|
var isHalfSize = useTileSize(tile).isHalfSize;
|
|
18364
|
-
|
|
18365
|
-
if (isHalfSize && artworkUrl || !description) return null;
|
|
18364
|
+
if (isHalfSize && artworkUrl || !body) return null;
|
|
18366
18365
|
return /*#__PURE__*/React.createElement(Text, _extends({
|
|
18367
18366
|
variant: "body"
|
|
18368
18367
|
}, props, {
|
|
18369
|
-
accessibilityLabel:
|
|
18370
|
-
}),
|
|
18368
|
+
accessibilityLabel: body
|
|
18369
|
+
}), body);
|
|
18371
18370
|
};
|
|
18372
18371
|
var BaseTile = BaseTileInner;
|
|
18373
18372
|
BaseTile.Root = BaseTileRoot;
|
|
@@ -18911,9 +18910,9 @@ var ContentTileMedia = function () {
|
|
|
18911
18910
|
};
|
|
18912
18911
|
var ContentTileContent = function (_a) {
|
|
18913
18912
|
var children = _a.children;
|
|
18914
|
-
return /*#__PURE__*/React__namespace.createElement(View$2, {
|
|
18913
|
+
return /*#__PURE__*/React__namespace.createElement(BaseTile.Content, null, /*#__PURE__*/React__namespace.createElement(View$2, {
|
|
18915
18914
|
style: styles$9.content
|
|
18916
|
-
}, children);
|
|
18915
|
+
}, children));
|
|
18917
18916
|
};
|
|
18918
18917
|
var ContentTileHeader = function () {
|
|
18919
18918
|
return /*#__PURE__*/React__namespace.createElement(BaseTile.Header, null, /*#__PURE__*/React__namespace.createElement(BaseTile.Title, null));
|
|
@@ -18924,7 +18923,8 @@ var ContentTileBody = function () {
|
|
|
18924
18923
|
var styles$9 = StyleSheet$1.create({
|
|
18925
18924
|
content: createResponsiveStyle({
|
|
18926
18925
|
paddingHorizontal: [8, 8, 12],
|
|
18927
|
-
flex: 1
|
|
18926
|
+
flex: 1,
|
|
18927
|
+
justifyContent: 'center'
|
|
18928
18928
|
}),
|
|
18929
18929
|
media: createResponsiveStyle({
|
|
18930
18930
|
width: '100%'
|
|
@@ -19649,7 +19649,7 @@ var RewardTilePoints = function () {
|
|
|
19649
19649
|
var configuration = useTileContext().configuration;
|
|
19650
19650
|
var theme = useWllSdk().theme;
|
|
19651
19651
|
var reward = configuration;
|
|
19652
|
-
var calculatedPoints = (reward === null || reward === void 0 ? void 0 : reward.price) !== undefined ? reward.price * Number(reward.pointsMultiplier) : null;
|
|
19652
|
+
var calculatedPoints = (reward === null || reward === void 0 ? void 0 : reward.price) !== undefined ? reward.price * (Number(reward.pointsMultiplier) || 1) : null;
|
|
19653
19653
|
if ((reward === null || reward === void 0 ? void 0 : reward.price) === 0 || !reward.showPrice || calculatedPoints === null) {
|
|
19654
19654
|
return null;
|
|
19655
19655
|
}
|