@saasquatch/mint-components 1.15.0-136 → 1.15.0-138
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/cjs/{ShadowViewAddon-e56c90ab.js → ShadowViewAddon-4bdc20e8.js} +7 -8
- package/dist/cjs/sqm-big-stat_44.cjs.entry.js +40 -35
- package/dist/cjs/{sqm-navigation-sidebar-item-view-da5117fd.js → sqm-navigation-sidebar-item-view-4e88f774.js} +1 -1
- package/dist/cjs/sqm-navigation-sidebar-item.cjs.entry.js +1 -1
- package/dist/cjs/sqm-stencilbook.cjs.entry.js +2 -2
- package/dist/collection/components/sqm-navigation-sidebar-item/sqm-navigation-sidebar-item-view.js +1 -1
- package/dist/collection/components/sqm-reward-exchange-list/RewardExchangeListData.js +1 -1
- package/dist/collection/components/sqm-reward-exchange-list/sqm-reward-exchange-list-view.js +6 -7
- package/dist/collection/components/sqm-reward-exchange-list/sqm-reward-exchange-list.js +43 -38
- package/dist/esm/{ShadowViewAddon-439a4d47.js → ShadowViewAddon-41dd2aeb.js} +7 -8
- package/dist/esm/sqm-big-stat_44.entry.js +40 -35
- package/dist/esm/{sqm-navigation-sidebar-item-view-b03b4588.js → sqm-navigation-sidebar-item-view-5a452423.js} +1 -1
- package/dist/esm/sqm-navigation-sidebar-item.entry.js +1 -1
- package/dist/esm/sqm-stencilbook.entry.js +2 -2
- package/dist/esm-es5/{ShadowViewAddon-439a4d47.js → ShadowViewAddon-41dd2aeb.js} +1 -1
- package/dist/esm-es5/sqm-big-stat_44.entry.js +1 -1
- package/dist/esm-es5/{sqm-navigation-sidebar-item-view-b03b4588.js → sqm-navigation-sidebar-item-view-5a452423.js} +1 -1
- package/dist/esm-es5/sqm-navigation-sidebar-item.entry.js +1 -1
- package/dist/esm-es5/sqm-stencilbook.entry.js +1 -1
- package/dist/mint-components/mint-components.esm.js +1 -1
- package/dist/mint-components/p-0087ad39.system.js +1 -0
- package/dist/mint-components/{p-019a2c63.system.js → p-05a307c7.system.js} +1 -1
- package/dist/mint-components/{p-bb295a46.system.entry.js → p-15f7b849.system.entry.js} +1 -1
- package/dist/mint-components/{p-65782fec.entry.js → p-26b1971c.entry.js} +1 -1
- package/dist/mint-components/{p-84adfce1.entry.js → p-588b7c45.entry.js} +1 -1
- package/dist/mint-components/{p-4a3fd23f.js → p-5aaa8cfc.js} +1 -1
- package/dist/mint-components/p-9eba8408.js +1 -0
- package/dist/mint-components/{p-d359b5f2.system.entry.js → p-a1b89894.system.entry.js} +1 -1
- package/dist/mint-components/{p-9d8815bb.entry.js → p-bc7b703a.entry.js} +6 -6
- package/dist/mint-components/p-cb39dc04.system.js +1 -1
- package/dist/mint-components/{p-6c0ab3e9.system.entry.js → p-f0476abd.system.entry.js} +1 -1
- package/dist/types/components/sqm-reward-exchange-list/sqm-reward-exchange-list.d.ts +4 -4
- package/dist/types/components.d.ts +8 -8
- package/docs/docs.docx +0 -0
- package/docs/raisins.json +1 -1
- package/package.json +1 -1
- package/dist/mint-components/p-41aa5919.system.js +0 -1
- package/dist/mint-components/p-ae95ed57.js +0 -1
|
@@ -3605,7 +3605,7 @@ function RewardExchangeView(props) {
|
|
|
3605
3605
|
index.h("sl-button", { exportparts: "base: primarybutton-base", class: "continue", size: "large", type: "primary", onClick: () => callbacks.setStage("confirmation"), disabled: isDisabled }, states.content.text.continueToConfirmationText)))));
|
|
3606
3606
|
}
|
|
3607
3607
|
function confirmation() {
|
|
3608
|
-
const cost = (selectedStep === null || selectedStep === void 0 ? void 0 : selectedStep.prettySourceValue) || selectedItem.prettySourceValue;
|
|
3608
|
+
const cost = (selectedStep === null || selectedStep === void 0 ? void 0 : selectedStep.prettySourceValue) || (selectedItem === null || selectedItem === void 0 ? void 0 : selectedItem.prettySourceValue);
|
|
3609
3609
|
const amount = selectedStep === null || selectedStep === void 0 ? void 0 : selectedStep.prettyDestinationValue;
|
|
3610
3610
|
return (index.h("div", null,
|
|
3611
3611
|
index.h("div", { class: sheet$8.classes.Confirmation, part: "confirmation-container" },
|
|
@@ -3613,7 +3613,7 @@ function RewardExchangeView(props) {
|
|
|
3613
3613
|
index.h("div", { class: "wrapper" },
|
|
3614
3614
|
index.h("div", { class: "field" }, states.content.text.rewardNameTitle),
|
|
3615
3615
|
index.h("div", { class: "reward-item-container" },
|
|
3616
|
-
index.h("div", { class: "reward-title" }, selectedItem.name),
|
|
3616
|
+
index.h("div", { class: "reward-title" }, selectedItem === null || selectedItem === void 0 ? void 0 : selectedItem.name),
|
|
3617
3617
|
index.h("img", { class: "image", src: (selectedItem === null || selectedItem === void 0 ? void 0 : selectedItem.imageUrl) ||
|
|
3618
3618
|
index.getAssetPath("./assets/Reward-image.png") }))),
|
|
3619
3619
|
index.h("div", { class: "wrapper padding" },
|
|
@@ -3629,7 +3629,7 @@ function RewardExchangeView(props) {
|
|
|
3629
3629
|
index.h("sl-button", { class: "continue", size: "large", type: "primary", loading: states.loading, onClick: callbacks.exchangeReward }, states.content.text.redeemText)))));
|
|
3630
3630
|
}
|
|
3631
3631
|
function success() {
|
|
3632
|
-
var _a, _b, _c, _d, _e, _f;
|
|
3632
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
3633
3633
|
return (index.h("div", { class: sheet$8.classes.Success, part: "success-container" },
|
|
3634
3634
|
index.h(Gift$1, null),
|
|
3635
3635
|
index.h(Confetti, null),
|
|
@@ -3638,13 +3638,12 @@ function RewardExchangeView(props) {
|
|
|
3638
3638
|
id: "successMessage",
|
|
3639
3639
|
defaultMessage: states.content.text.redemptionSuccessText,
|
|
3640
3640
|
}, {
|
|
3641
|
-
sourceValue: (_b = states.selectedItem.prettySourceValue) !== null &&
|
|
3642
|
-
destinationValue: ((
|
|
3643
|
-
states.selectedItem.globalRewardKey,
|
|
3641
|
+
sourceValue: (_c = (_b = states.selectedItem) === null || _b === void 0 ? void 0 : _b.prettySourceValue) !== null && _c !== void 0 ? _c : (_d = states.selectedStep) === null || _d === void 0 ? void 0 : _d.prettySourceValue,
|
|
3642
|
+
destinationValue: ((_e = states.selectedStep) === null || _e === void 0 ? void 0 : _e.prettyDestinationValue) || ((_f = states.selectedItem) === null || _f === void 0 ? void 0 : _f.name) || ((_g = states.selectedItem) === null || _g === void 0 ? void 0 : _g.globalRewardKey),
|
|
3644
3643
|
})),
|
|
3645
3644
|
(data === null || data === void 0 ? void 0 : data.fuelTankCode) && (index.h("div", { class: "promo" },
|
|
3646
3645
|
states.content.text.promoCode,
|
|
3647
|
-
index.h(copyTextView.CopyTextView, { copyString: data.fuelTankCode, tooltiptext: (
|
|
3646
|
+
index.h(copyTextView.CopyTextView, { copyString: data.fuelTankCode, tooltiptext: (_h = states === null || states === void 0 ? void 0 : states.content) === null || _h === void 0 ? void 0 : _h.text.tooltipText, open: states.open, onClick: callbacks.copyFuelTankCode }))),
|
|
3648
3647
|
index.h("div", { class: sheet$8.classes.Button },
|
|
3649
3648
|
index.h("sl-button", { class: "continue center", type: "primary", size: "large", onClick: () => callbacks.resetState(true) }, states.content.text.doneText))));
|
|
3650
3649
|
}
|
|
@@ -3942,7 +3941,7 @@ const rewardExchange = {
|
|
|
3942
3941
|
...baseResponse(data),
|
|
3943
3942
|
};
|
|
3944
3943
|
const demoRewardExchange = {
|
|
3945
|
-
...baseResponse(demoData),
|
|
3944
|
+
...baseResponse(demoData, "chooseReward", baseReward),
|
|
3946
3945
|
};
|
|
3947
3946
|
const rewardExchangeLongText = {
|
|
3948
3947
|
...baseResponse([
|
|
@@ -25,7 +25,7 @@ const sqmPortalLoginView = require('./sqm-portal-login-view-bb50304c.js');
|
|
|
25
25
|
const usePortalLogin = require('./usePortalLogin-6aa864ef.js');
|
|
26
26
|
const AsYouType = require('./AsYouType-6788393a.js');
|
|
27
27
|
const utilities = require('./utilities-9a0c5e91.js');
|
|
28
|
-
const ShadowViewAddon = require('./ShadowViewAddon-
|
|
28
|
+
const ShadowViewAddon = require('./ShadowViewAddon-4bdc20e8.js');
|
|
29
29
|
require('./sqm-portal-container-view-07e4343f.js');
|
|
30
30
|
const parseStates = require('./parseStates-d1effc19.js');
|
|
31
31
|
const usePayoutStatus = require('./usePayoutStatus-3b34dab1.js');
|
|
@@ -5279,10 +5279,10 @@ const SqmRewardExchangeList = class {
|
|
|
5279
5279
|
*/
|
|
5280
5280
|
this.costTitle = "Cost to Redeem";
|
|
5281
5281
|
/**
|
|
5282
|
-
* @componentState { "title": "Choose reward", "props": { "redeemStage": "chooseReward" }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5283
|
-
* @componentState { "title": "Reward details", "props": { "redeemStage": "chooseAmount" }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5284
|
-
* @componentState { "title": "Confirm exchange", "props": { "redeemStage": "confirmation" }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5285
|
-
* @componentState { "title": "Exchange successful", "props": { "redeemStage": "success" }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5282
|
+
* @componentState { "title": "Choose reward", "props": { "states": { "redeemStage": "chooseReward" } }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5283
|
+
* @componentState { "title": "Reward details", "props": { "states": { "redeemStage": "chooseAmount" } }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5284
|
+
* @componentState { "title": "Confirm exchange", "props": { "states": { "redeemStage": "confirmation" } }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5285
|
+
* @componentState { "title": "Exchange successful", "props": { "states": { "redeemStage": "success" } }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5286
5286
|
*/
|
|
5287
5287
|
this.stateController = "{}";
|
|
5288
5288
|
domContextHooks_module.h$1(this);
|
|
@@ -5308,36 +5308,41 @@ function useRewardExchangeListDemo(props) {
|
|
|
5308
5308
|
const formatted = Object.keys(states).reduce((prev, key) => key === "sqm-reward-exchange-list"
|
|
5309
5309
|
? { ...prev, ...states[key] }
|
|
5310
5310
|
: { ...prev, [`${key}_stateController`]: states[key] }, {});
|
|
5311
|
-
|
|
5312
|
-
|
|
5313
|
-
|
|
5314
|
-
|
|
5315
|
-
|
|
5316
|
-
|
|
5317
|
-
|
|
5318
|
-
|
|
5319
|
-
|
|
5320
|
-
|
|
5321
|
-
|
|
5322
|
-
|
|
5323
|
-
|
|
5324
|
-
|
|
5325
|
-
|
|
5326
|
-
|
|
5327
|
-
|
|
5328
|
-
|
|
5329
|
-
|
|
5330
|
-
|
|
5331
|
-
|
|
5332
|
-
|
|
5333
|
-
|
|
5334
|
-
|
|
5335
|
-
|
|
5336
|
-
|
|
5337
|
-
|
|
5338
|
-
|
|
5339
|
-
|
|
5340
|
-
|
|
5311
|
+
const finalProps = cjs.cjs({ ...ShadowViewAddon.demoRewardExchange, content: { text: props } },
|
|
5312
|
+
// {
|
|
5313
|
+
// states: {
|
|
5314
|
+
// content: {
|
|
5315
|
+
// text: props,
|
|
5316
|
+
// },
|
|
5317
|
+
// redeemStage: "chooseReward",
|
|
5318
|
+
// amount: 0,
|
|
5319
|
+
// selectedStep: undefined,
|
|
5320
|
+
// selectedItem: undefined,
|
|
5321
|
+
// open: false,
|
|
5322
|
+
// exchangeError: false,
|
|
5323
|
+
// queryError: false,
|
|
5324
|
+
// loading: false,
|
|
5325
|
+
// noExchangeOptions: false,
|
|
5326
|
+
// // empty: EmptySlot(),
|
|
5327
|
+
// },
|
|
5328
|
+
// data: {
|
|
5329
|
+
// // shareCode: "SHARECODE123",
|
|
5330
|
+
// exchangeList: demoRewardExchange.data.exchangeList,
|
|
5331
|
+
// },
|
|
5332
|
+
// callbacks: {
|
|
5333
|
+
// exchangeReward: () => {},
|
|
5334
|
+
// setExchangeState: (_: ExchangeState) => {},
|
|
5335
|
+
// setStage: (_: Stages) => {},
|
|
5336
|
+
// resetState: () => {},
|
|
5337
|
+
// copyFuelTankCode: () => {},
|
|
5338
|
+
// },
|
|
5339
|
+
// refs: {
|
|
5340
|
+
// canvasRef: {},
|
|
5341
|
+
// },
|
|
5342
|
+
// },
|
|
5343
|
+
props.demoData || formatted || {}, { arrayMerge: (_, a) => a });
|
|
5344
|
+
console.log({ finalProps });
|
|
5345
|
+
return finalProps;
|
|
5341
5346
|
}
|
|
5342
5347
|
|
|
5343
5348
|
const debug$1 = domContextHooks_module.browser("sq:useRouter");
|
|
@@ -22,7 +22,7 @@ function NavigationSidebarItemView(props) {
|
|
|
22
22
|
"text-decoration": "none",
|
|
23
23
|
color: states.active
|
|
24
24
|
? textFocusedColor
|
|
25
|
-
: props.textColor || "var(--sqm-
|
|
25
|
+
: props.textColor || "var(--sqm-text)",
|
|
26
26
|
"align-items": "center",
|
|
27
27
|
...mixins.gap({ direction: "row", size: "var(--sl-font-size-small)" }),
|
|
28
28
|
"&:hover": {
|
|
@@ -9,7 +9,7 @@ const cjs = require('./cjs-1066ec21.js');
|
|
|
9
9
|
const utils = require('./utils-7cbd60cc.js');
|
|
10
10
|
require('./JSS-8503a151.js');
|
|
11
11
|
require('./mixins-4761d472.js');
|
|
12
|
-
const sqmNavigationSidebarItemView = require('./sqm-navigation-sidebar-item-view-
|
|
12
|
+
const sqmNavigationSidebarItemView = require('./sqm-navigation-sidebar-item-view-4e88f774.js');
|
|
13
13
|
|
|
14
14
|
function useNavigationSidebarItem(props) {
|
|
15
15
|
const currentPage = index_module.kn();
|
|
@@ -22,7 +22,7 @@ const emailRegistrationView = require('./email-registration-view-ace50780.js');
|
|
|
22
22
|
const sqmLeaderboardRankView = require('./sqm-leaderboard-rank-view-6a1e63de.js');
|
|
23
23
|
const sqmLogoutCurrentUserView = require('./sqm-logout-current-user-view-b61c8bdf.js');
|
|
24
24
|
const sqmNavigationSidebarView = require('./sqm-navigation-sidebar-view-de90ef03.js');
|
|
25
|
-
const sqmNavigationSidebarItemView = require('./sqm-navigation-sidebar-item-view-
|
|
25
|
+
const sqmNavigationSidebarItemView = require('./sqm-navigation-sidebar-item-view-4e88f774.js');
|
|
26
26
|
const sqmPortalEmailVerificationView = require('./sqm-portal-email-verification-view-bd4ec210.js');
|
|
27
27
|
const sqmPortalLoginView = require('./sqm-portal-login-view-bb50304c.js');
|
|
28
28
|
const sqmBaseRegistrationFormView = require('./sqm-base-registration-form-view-8847804c.js');
|
|
@@ -32,7 +32,7 @@ require('./utilities-9a0c5e91.js');
|
|
|
32
32
|
const sqmPortalResetPasswordView = require('./sqm-portal-reset-password-view-25eb2099.js');
|
|
33
33
|
const sqmPortalVerifyEmailView = require('./sqm-portal-verify-email-view-1c4e781f.js');
|
|
34
34
|
const sqmQrCodeView = require('./sqm-qr-code-view-0c3b2f48.js');
|
|
35
|
-
const ShadowViewAddon = require('./ShadowViewAddon-
|
|
35
|
+
const ShadowViewAddon = require('./ShadowViewAddon-4bdc20e8.js');
|
|
36
36
|
const sqmPortalContainerView = require('./sqm-portal-container-view-07e4343f.js');
|
|
37
37
|
const IndirectTaxDetailsView = require('./IndirectTaxDetailsView-92481647.js');
|
|
38
38
|
const utils = require('./utils-ba8fc342.js');
|
package/dist/collection/components/sqm-navigation-sidebar-item/sqm-navigation-sidebar-item-view.js
CHANGED
|
@@ -19,7 +19,7 @@ export function NavigationSidebarItemView(props) {
|
|
|
19
19
|
"text-decoration": "none",
|
|
20
20
|
color: states.active
|
|
21
21
|
? textFocusedColor
|
|
22
|
-
: props.textColor || "var(--sqm-
|
|
22
|
+
: props.textColor || "var(--sqm-text)",
|
|
23
23
|
"align-items": "center",
|
|
24
24
|
...gap({ direction: "row", size: "var(--sl-font-size-small)" }),
|
|
25
25
|
"&:hover": {
|
|
@@ -223,7 +223,7 @@ export const rewardExchange = {
|
|
|
223
223
|
...baseResponse(data),
|
|
224
224
|
};
|
|
225
225
|
export const demoRewardExchange = {
|
|
226
|
-
...baseResponse(demoData),
|
|
226
|
+
...baseResponse(demoData, "chooseReward", baseReward),
|
|
227
227
|
};
|
|
228
228
|
export const rewardExchangeLongText = {
|
|
229
229
|
...baseResponse([
|
package/dist/collection/components/sqm-reward-exchange-list/sqm-reward-exchange-list-view.js
CHANGED
|
@@ -496,7 +496,7 @@ export function RewardExchangeView(props) {
|
|
|
496
496
|
h("sl-button", { exportparts: "base: primarybutton-base", class: "continue", size: "large", type: "primary", onClick: () => callbacks.setStage("confirmation"), disabled: isDisabled }, states.content.text.continueToConfirmationText)))));
|
|
497
497
|
}
|
|
498
498
|
function confirmation() {
|
|
499
|
-
const cost = (selectedStep === null || selectedStep === void 0 ? void 0 : selectedStep.prettySourceValue) || selectedItem.prettySourceValue;
|
|
499
|
+
const cost = (selectedStep === null || selectedStep === void 0 ? void 0 : selectedStep.prettySourceValue) || (selectedItem === null || selectedItem === void 0 ? void 0 : selectedItem.prettySourceValue);
|
|
500
500
|
const amount = selectedStep === null || selectedStep === void 0 ? void 0 : selectedStep.prettyDestinationValue;
|
|
501
501
|
return (h("div", null,
|
|
502
502
|
h("div", { class: sheet.classes.Confirmation, part: "confirmation-container" },
|
|
@@ -504,7 +504,7 @@ export function RewardExchangeView(props) {
|
|
|
504
504
|
h("div", { class: "wrapper" },
|
|
505
505
|
h("div", { class: "field" }, states.content.text.rewardNameTitle),
|
|
506
506
|
h("div", { class: "reward-item-container" },
|
|
507
|
-
h("div", { class: "reward-title" }, selectedItem.name),
|
|
507
|
+
h("div", { class: "reward-title" }, selectedItem === null || selectedItem === void 0 ? void 0 : selectedItem.name),
|
|
508
508
|
h("img", { class: "image", src: (selectedItem === null || selectedItem === void 0 ? void 0 : selectedItem.imageUrl) ||
|
|
509
509
|
getAssetPath("./assets/Reward-image.png") }))),
|
|
510
510
|
h("div", { class: "wrapper padding" },
|
|
@@ -520,7 +520,7 @@ export function RewardExchangeView(props) {
|
|
|
520
520
|
h("sl-button", { class: "continue", size: "large", type: "primary", loading: states.loading, onClick: callbacks.exchangeReward }, states.content.text.redeemText)))));
|
|
521
521
|
}
|
|
522
522
|
function success() {
|
|
523
|
-
var _a, _b, _c, _d, _e, _f;
|
|
523
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
524
524
|
return (h("div", { class: sheet.classes.Success, part: "success-container" },
|
|
525
525
|
h(Gift, null),
|
|
526
526
|
h(Confetti, null),
|
|
@@ -529,13 +529,12 @@ export function RewardExchangeView(props) {
|
|
|
529
529
|
id: "successMessage",
|
|
530
530
|
defaultMessage: states.content.text.redemptionSuccessText,
|
|
531
531
|
}, {
|
|
532
|
-
sourceValue: (_b = states.selectedItem.prettySourceValue) !== null &&
|
|
533
|
-
destinationValue: ((
|
|
534
|
-
states.selectedItem.globalRewardKey,
|
|
532
|
+
sourceValue: (_c = (_b = states.selectedItem) === null || _b === void 0 ? void 0 : _b.prettySourceValue) !== null && _c !== void 0 ? _c : (_d = states.selectedStep) === null || _d === void 0 ? void 0 : _d.prettySourceValue,
|
|
533
|
+
destinationValue: ((_e = states.selectedStep) === null || _e === void 0 ? void 0 : _e.prettyDestinationValue) || ((_f = states.selectedItem) === null || _f === void 0 ? void 0 : _f.name) || ((_g = states.selectedItem) === null || _g === void 0 ? void 0 : _g.globalRewardKey),
|
|
535
534
|
})),
|
|
536
535
|
(data === null || data === void 0 ? void 0 : data.fuelTankCode) && (h("div", { class: "promo" },
|
|
537
536
|
states.content.text.promoCode,
|
|
538
|
-
h(CopyTextView, { copyString: data.fuelTankCode, tooltiptext: (
|
|
537
|
+
h(CopyTextView, { copyString: data.fuelTankCode, tooltiptext: (_h = states === null || states === void 0 ? void 0 : states.content) === null || _h === void 0 ? void 0 : _h.text.tooltipText, open: states.open, onClick: callbacks.copyFuelTankCode }))),
|
|
539
538
|
h("div", { class: sheet.classes.Button },
|
|
540
539
|
h("sl-button", { class: "continue center", type: "primary", size: "large", onClick: () => callbacks.resetState(true) }, states.content.text.doneText))));
|
|
541
540
|
}
|
|
@@ -149,10 +149,10 @@ export class SqmRewardExchangeList {
|
|
|
149
149
|
*/
|
|
150
150
|
this.costTitle = "Cost to Redeem";
|
|
151
151
|
/**
|
|
152
|
-
* @componentState { "title": "Choose reward", "props": { "redeemStage": "chooseReward" }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
153
|
-
* @componentState { "title": "Reward details", "props": { "redeemStage": "chooseAmount" }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
154
|
-
* @componentState { "title": "Confirm exchange", "props": { "redeemStage": "confirmation" }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
155
|
-
* @componentState { "title": "Exchange successful", "props": { "redeemStage": "success" }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
152
|
+
* @componentState { "title": "Choose reward", "props": { "states": { "redeemStage": "chooseReward" } }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
153
|
+
* @componentState { "title": "Reward details", "props": { "states": { "redeemStage": "chooseAmount" } }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
154
|
+
* @componentState { "title": "Confirm exchange", "props": { "states": { "redeemStage": "confirmation" } }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
155
|
+
* @componentState { "title": "Exchange successful", "props": { "states": { "redeemStage": "success" } }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
156
156
|
*/
|
|
157
157
|
this.stateController = "{}";
|
|
158
158
|
withHooks(this);
|
|
@@ -731,16 +731,16 @@ export class SqmRewardExchangeList {
|
|
|
731
731
|
"optional": false,
|
|
732
732
|
"docs": {
|
|
733
733
|
"tags": [{
|
|
734
|
-
"text": "{ \"title\": \"Choose reward\", \"props\": { \"redeemStage\": \"chooseReward\" }, \"dependencies\": [\"sqm-reward-exchange-list\"] }",
|
|
734
|
+
"text": "{ \"title\": \"Choose reward\", \"props\": { \"states\": { \"redeemStage\": \"chooseReward\" } }, \"dependencies\": [\"sqm-reward-exchange-list\"] }",
|
|
735
735
|
"name": "componentState"
|
|
736
736
|
}, {
|
|
737
|
-
"text": "{ \"title\": \"Reward details\", \"props\": { \"redeemStage\": \"chooseAmount\" }, \"dependencies\": [\"sqm-reward-exchange-list\"] }",
|
|
737
|
+
"text": "{ \"title\": \"Reward details\", \"props\": { \"states\": { \"redeemStage\": \"chooseAmount\" } }, \"dependencies\": [\"sqm-reward-exchange-list\"] }",
|
|
738
738
|
"name": "componentState"
|
|
739
739
|
}, {
|
|
740
|
-
"text": "{ \"title\": \"Confirm exchange\", \"props\": { \"redeemStage\": \"confirmation\" }, \"dependencies\": [\"sqm-reward-exchange-list\"] }",
|
|
740
|
+
"text": "{ \"title\": \"Confirm exchange\", \"props\": { \"states\": { \"redeemStage\": \"confirmation\" } }, \"dependencies\": [\"sqm-reward-exchange-list\"] }",
|
|
741
741
|
"name": "componentState"
|
|
742
742
|
}, {
|
|
743
|
-
"text": "{ \"title\": \"Exchange successful\", \"props\": { \"redeemStage\": \"success\" }, \"dependencies\": [\"sqm-reward-exchange-list\"] }",
|
|
743
|
+
"text": "{ \"title\": \"Exchange successful\", \"props\": { \"states\": { \"redeemStage\": \"success\" } }, \"dependencies\": [\"sqm-reward-exchange-list\"] }",
|
|
744
744
|
"name": "componentState"
|
|
745
745
|
}],
|
|
746
746
|
"text": ""
|
|
@@ -793,34 +793,39 @@ function useRewardExchangeListDemo(props) {
|
|
|
793
793
|
const formatted = Object.keys(states).reduce((prev, key) => key === "sqm-reward-exchange-list"
|
|
794
794
|
? { ...prev, ...states[key] }
|
|
795
795
|
: { ...prev, [`${key}_stateController`]: states[key] }, {});
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
796
|
+
const finalProps = deepmerge({ ...demoRewardExchange, content: { text: props } },
|
|
797
|
+
// {
|
|
798
|
+
// states: {
|
|
799
|
+
// content: {
|
|
800
|
+
// text: props,
|
|
801
|
+
// },
|
|
802
|
+
// redeemStage: "chooseReward",
|
|
803
|
+
// amount: 0,
|
|
804
|
+
// selectedStep: undefined,
|
|
805
|
+
// selectedItem: undefined,
|
|
806
|
+
// open: false,
|
|
807
|
+
// exchangeError: false,
|
|
808
|
+
// queryError: false,
|
|
809
|
+
// loading: false,
|
|
810
|
+
// noExchangeOptions: false,
|
|
811
|
+
// // empty: EmptySlot(),
|
|
812
|
+
// },
|
|
813
|
+
// data: {
|
|
814
|
+
// // shareCode: "SHARECODE123",
|
|
815
|
+
// exchangeList: demoRewardExchange.data.exchangeList,
|
|
816
|
+
// },
|
|
817
|
+
// callbacks: {
|
|
818
|
+
// exchangeReward: () => {},
|
|
819
|
+
// setExchangeState: (_: ExchangeState) => {},
|
|
820
|
+
// setStage: (_: Stages) => {},
|
|
821
|
+
// resetState: () => {},
|
|
822
|
+
// copyFuelTankCode: () => {},
|
|
823
|
+
// },
|
|
824
|
+
// refs: {
|
|
825
|
+
// canvasRef: {},
|
|
826
|
+
// },
|
|
827
|
+
// },
|
|
828
|
+
props.demoData || formatted || {}, { arrayMerge: (_, a) => a });
|
|
829
|
+
console.log({ finalProps });
|
|
830
|
+
return finalProps;
|
|
826
831
|
}
|
|
@@ -3603,7 +3603,7 @@ function RewardExchangeView(props) {
|
|
|
3603
3603
|
h("sl-button", { exportparts: "base: primarybutton-base", class: "continue", size: "large", type: "primary", onClick: () => callbacks.setStage("confirmation"), disabled: isDisabled }, states.content.text.continueToConfirmationText)))));
|
|
3604
3604
|
}
|
|
3605
3605
|
function confirmation() {
|
|
3606
|
-
const cost = (selectedStep === null || selectedStep === void 0 ? void 0 : selectedStep.prettySourceValue) || selectedItem.prettySourceValue;
|
|
3606
|
+
const cost = (selectedStep === null || selectedStep === void 0 ? void 0 : selectedStep.prettySourceValue) || (selectedItem === null || selectedItem === void 0 ? void 0 : selectedItem.prettySourceValue);
|
|
3607
3607
|
const amount = selectedStep === null || selectedStep === void 0 ? void 0 : selectedStep.prettyDestinationValue;
|
|
3608
3608
|
return (h("div", null,
|
|
3609
3609
|
h("div", { class: sheet$8.classes.Confirmation, part: "confirmation-container" },
|
|
@@ -3611,7 +3611,7 @@ function RewardExchangeView(props) {
|
|
|
3611
3611
|
h("div", { class: "wrapper" },
|
|
3612
3612
|
h("div", { class: "field" }, states.content.text.rewardNameTitle),
|
|
3613
3613
|
h("div", { class: "reward-item-container" },
|
|
3614
|
-
h("div", { class: "reward-title" }, selectedItem.name),
|
|
3614
|
+
h("div", { class: "reward-title" }, selectedItem === null || selectedItem === void 0 ? void 0 : selectedItem.name),
|
|
3615
3615
|
h("img", { class: "image", src: (selectedItem === null || selectedItem === void 0 ? void 0 : selectedItem.imageUrl) ||
|
|
3616
3616
|
getAssetPath("./assets/Reward-image.png") }))),
|
|
3617
3617
|
h("div", { class: "wrapper padding" },
|
|
@@ -3627,7 +3627,7 @@ function RewardExchangeView(props) {
|
|
|
3627
3627
|
h("sl-button", { class: "continue", size: "large", type: "primary", loading: states.loading, onClick: callbacks.exchangeReward }, states.content.text.redeemText)))));
|
|
3628
3628
|
}
|
|
3629
3629
|
function success() {
|
|
3630
|
-
var _a, _b, _c, _d, _e, _f;
|
|
3630
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
3631
3631
|
return (h("div", { class: sheet$8.classes.Success, part: "success-container" },
|
|
3632
3632
|
h(Gift$1, null),
|
|
3633
3633
|
h(Confetti, null),
|
|
@@ -3636,13 +3636,12 @@ function RewardExchangeView(props) {
|
|
|
3636
3636
|
id: "successMessage",
|
|
3637
3637
|
defaultMessage: states.content.text.redemptionSuccessText,
|
|
3638
3638
|
}, {
|
|
3639
|
-
sourceValue: (_b = states.selectedItem.prettySourceValue) !== null &&
|
|
3640
|
-
destinationValue: ((
|
|
3641
|
-
states.selectedItem.globalRewardKey,
|
|
3639
|
+
sourceValue: (_c = (_b = states.selectedItem) === null || _b === void 0 ? void 0 : _b.prettySourceValue) !== null && _c !== void 0 ? _c : (_d = states.selectedStep) === null || _d === void 0 ? void 0 : _d.prettySourceValue,
|
|
3640
|
+
destinationValue: ((_e = states.selectedStep) === null || _e === void 0 ? void 0 : _e.prettyDestinationValue) || ((_f = states.selectedItem) === null || _f === void 0 ? void 0 : _f.name) || ((_g = states.selectedItem) === null || _g === void 0 ? void 0 : _g.globalRewardKey),
|
|
3642
3641
|
})),
|
|
3643
3642
|
(data === null || data === void 0 ? void 0 : data.fuelTankCode) && (h("div", { class: "promo" },
|
|
3644
3643
|
states.content.text.promoCode,
|
|
3645
|
-
h(CopyTextView, { copyString: data.fuelTankCode, tooltiptext: (
|
|
3644
|
+
h(CopyTextView, { copyString: data.fuelTankCode, tooltiptext: (_h = states === null || states === void 0 ? void 0 : states.content) === null || _h === void 0 ? void 0 : _h.text.tooltipText, open: states.open, onClick: callbacks.copyFuelTankCode }))),
|
|
3646
3645
|
h("div", { class: sheet$8.classes.Button },
|
|
3647
3646
|
h("sl-button", { class: "continue center", type: "primary", size: "large", onClick: () => callbacks.resetState(true) }, states.content.text.doneText))));
|
|
3648
3647
|
}
|
|
@@ -3940,7 +3939,7 @@ const rewardExchange = {
|
|
|
3940
3939
|
...baseResponse(data),
|
|
3941
3940
|
};
|
|
3942
3941
|
const demoRewardExchange = {
|
|
3943
|
-
...baseResponse(demoData),
|
|
3942
|
+
...baseResponse(demoData, "chooseReward", baseReward),
|
|
3944
3943
|
};
|
|
3945
3944
|
const rewardExchangeLongText = {
|
|
3946
3945
|
...baseResponse([
|
|
@@ -21,7 +21,7 @@ import { P as PortalLoginView } from './sqm-portal-login-view-7670cd86.js';
|
|
|
21
21
|
import { u as usePortalLogin } from './usePortalLogin-e95df3c3.js';
|
|
22
22
|
import { A as AsYouType } from './AsYouType-46f67d0d.js';
|
|
23
23
|
import { i as isEmpty } from './utilities-72c07b09.js';
|
|
24
|
-
import { u as useDemoBigStat, U as useBigStat, B as BigStatView, C as CardFeedView, c as CheckboxFieldView, e as CouponCodeView, D as DropdownFieldView, E as EditProfileView, H as HeroView, I as InputFieldView, V as withShadowView, L as LeaderboardView, N as NameFieldsView, f as ChangeMarktingView, P as PortalChangePasswordView, g as PortalFooterView, h as PortalForgotPasswordView, i as PortalFrameView, d as PortalRegisterView, R as ReferralIframeView, j as RewardExchangeView, W as demoRewardExchange, J as useShareButton, a as ShareButtonView, K as useShareLink, S as StatContainerView, T as TaskCardView } from './ShadowViewAddon-
|
|
24
|
+
import { u as useDemoBigStat, U as useBigStat, B as BigStatView, C as CardFeedView, c as CheckboxFieldView, e as CouponCodeView, D as DropdownFieldView, E as EditProfileView, H as HeroView, I as InputFieldView, V as withShadowView, L as LeaderboardView, N as NameFieldsView, f as ChangeMarktingView, P as PortalChangePasswordView, g as PortalFooterView, h as PortalForgotPasswordView, i as PortalFrameView, d as PortalRegisterView, R as ReferralIframeView, j as RewardExchangeView, W as demoRewardExchange, J as useShareButton, a as ShareButtonView, K as useShareLink, S as StatContainerView, T as TaskCardView } from './ShadowViewAddon-41dd2aeb.js';
|
|
25
25
|
import './sqm-portal-container-view-176e92e3.js';
|
|
26
26
|
import { p as parseStates } from './parseStates-ed75e224.js';
|
|
27
27
|
import { u as usePayoutStatus } from './usePayoutStatus-93462be3.js';
|
|
@@ -5275,10 +5275,10 @@ const SqmRewardExchangeList = class {
|
|
|
5275
5275
|
*/
|
|
5276
5276
|
this.costTitle = "Cost to Redeem";
|
|
5277
5277
|
/**
|
|
5278
|
-
* @componentState { "title": "Choose reward", "props": { "redeemStage": "chooseReward" }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5279
|
-
* @componentState { "title": "Reward details", "props": { "redeemStage": "chooseAmount" }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5280
|
-
* @componentState { "title": "Confirm exchange", "props": { "redeemStage": "confirmation" }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5281
|
-
* @componentState { "title": "Exchange successful", "props": { "redeemStage": "success" }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5278
|
+
* @componentState { "title": "Choose reward", "props": { "states": { "redeemStage": "chooseReward" } }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5279
|
+
* @componentState { "title": "Reward details", "props": { "states": { "redeemStage": "chooseAmount" } }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5280
|
+
* @componentState { "title": "Confirm exchange", "props": { "states": { "redeemStage": "confirmation" } }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5281
|
+
* @componentState { "title": "Exchange successful", "props": { "states": { "redeemStage": "success" } }, "dependencies": ["sqm-reward-exchange-list"] }
|
|
5282
5282
|
*/
|
|
5283
5283
|
this.stateController = "{}";
|
|
5284
5284
|
h(this);
|
|
@@ -5304,36 +5304,41 @@ function useRewardExchangeListDemo(props) {
|
|
|
5304
5304
|
const formatted = Object.keys(states).reduce((prev, key) => key === "sqm-reward-exchange-list"
|
|
5305
5305
|
? { ...prev, ...states[key] }
|
|
5306
5306
|
: { ...prev, [`${key}_stateController`]: states[key] }, {});
|
|
5307
|
-
|
|
5308
|
-
|
|
5309
|
-
|
|
5310
|
-
|
|
5311
|
-
|
|
5312
|
-
|
|
5313
|
-
|
|
5314
|
-
|
|
5315
|
-
|
|
5316
|
-
|
|
5317
|
-
|
|
5318
|
-
|
|
5319
|
-
|
|
5320
|
-
|
|
5321
|
-
|
|
5322
|
-
|
|
5323
|
-
|
|
5324
|
-
|
|
5325
|
-
|
|
5326
|
-
|
|
5327
|
-
|
|
5328
|
-
|
|
5329
|
-
|
|
5330
|
-
|
|
5331
|
-
|
|
5332
|
-
|
|
5333
|
-
|
|
5334
|
-
|
|
5335
|
-
|
|
5336
|
-
|
|
5307
|
+
const finalProps = cjs({ ...demoRewardExchange, content: { text: props } },
|
|
5308
|
+
// {
|
|
5309
|
+
// states: {
|
|
5310
|
+
// content: {
|
|
5311
|
+
// text: props,
|
|
5312
|
+
// },
|
|
5313
|
+
// redeemStage: "chooseReward",
|
|
5314
|
+
// amount: 0,
|
|
5315
|
+
// selectedStep: undefined,
|
|
5316
|
+
// selectedItem: undefined,
|
|
5317
|
+
// open: false,
|
|
5318
|
+
// exchangeError: false,
|
|
5319
|
+
// queryError: false,
|
|
5320
|
+
// loading: false,
|
|
5321
|
+
// noExchangeOptions: false,
|
|
5322
|
+
// // empty: EmptySlot(),
|
|
5323
|
+
// },
|
|
5324
|
+
// data: {
|
|
5325
|
+
// // shareCode: "SHARECODE123",
|
|
5326
|
+
// exchangeList: demoRewardExchange.data.exchangeList,
|
|
5327
|
+
// },
|
|
5328
|
+
// callbacks: {
|
|
5329
|
+
// exchangeReward: () => {},
|
|
5330
|
+
// setExchangeState: (_: ExchangeState) => {},
|
|
5331
|
+
// setStage: (_: Stages) => {},
|
|
5332
|
+
// resetState: () => {},
|
|
5333
|
+
// copyFuelTankCode: () => {},
|
|
5334
|
+
// },
|
|
5335
|
+
// refs: {
|
|
5336
|
+
// canvasRef: {},
|
|
5337
|
+
// },
|
|
5338
|
+
// },
|
|
5339
|
+
props.demoData || formatted || {}, { arrayMerge: (_, a) => a });
|
|
5340
|
+
console.log({ finalProps });
|
|
5341
|
+
return finalProps;
|
|
5337
5342
|
}
|
|
5338
5343
|
|
|
5339
5344
|
const debug$1 = browser("sq:useRouter");
|
|
@@ -20,7 +20,7 @@ function NavigationSidebarItemView(props) {
|
|
|
20
20
|
"text-decoration": "none",
|
|
21
21
|
color: states.active
|
|
22
22
|
? textFocusedColor
|
|
23
|
-
: props.textColor || "var(--sqm-
|
|
23
|
+
: props.textColor || "var(--sqm-text)",
|
|
24
24
|
"align-items": "center",
|
|
25
25
|
...gap({ direction: "row", size: "var(--sl-font-size-small)" }),
|
|
26
26
|
"&:hover": {
|
|
@@ -5,7 +5,7 @@ import { c as cjs } from './cjs-bdfb4486.js';
|
|
|
5
5
|
import { g as getProps } from './utils-03188de2.js';
|
|
6
6
|
import './JSS-67b5cff8.js';
|
|
7
7
|
import './mixins-f750863a.js';
|
|
8
|
-
import { N as NavigationSidebarItemView } from './sqm-navigation-sidebar-item-view-
|
|
8
|
+
import { N as NavigationSidebarItemView } from './sqm-navigation-sidebar-item-view-5a452423.js';
|
|
9
9
|
|
|
10
10
|
function useNavigationSidebarItem(props) {
|
|
11
11
|
const currentPage = kn();
|
|
@@ -18,7 +18,7 @@ import { E as EmailRegistrationView } from './email-registration-view-1f587f8b.j
|
|
|
18
18
|
import { L as LeaderboardRankView } from './sqm-leaderboard-rank-view-18baae5b.js';
|
|
19
19
|
import { L as LogoutCurrentUserView } from './sqm-logout-current-user-view-f21e54e3.js';
|
|
20
20
|
import { N as NavigationSidebarView } from './sqm-navigation-sidebar-view-0a2ec560.js';
|
|
21
|
-
import { N as NavigationSidebarItemView } from './sqm-navigation-sidebar-item-view-
|
|
21
|
+
import { N as NavigationSidebarItemView } from './sqm-navigation-sidebar-item-view-5a452423.js';
|
|
22
22
|
import { P as PortalEmailVerificationView } from './sqm-portal-email-verification-view-6b046416.js';
|
|
23
23
|
import { P as PortalLoginView } from './sqm-portal-login-view-7670cd86.js';
|
|
24
24
|
import { B as BaseRegistrationFormView } from './sqm-base-registration-form-view-193f1721.js';
|
|
@@ -28,7 +28,7 @@ import './utilities-72c07b09.js';
|
|
|
28
28
|
import { P as PortalResetPasswordView } from './sqm-portal-reset-password-view-abef7286.js';
|
|
29
29
|
import { P as PortalVerifyEmailView } from './sqm-portal-verify-email-view-33805220.js';
|
|
30
30
|
import { Q as QrCodeView } from './sqm-qr-code-view-97124a66.js';
|
|
31
|
-
import { S as StatContainerView, B as BigStatView, a as ShareButtonView, P as PortalChangePasswordView, b as PoweredByImg$1, u as useDemoBigStat, T as TaskCardView, C as CardFeedView, c as CheckboxFieldView, d as PortalRegisterView, e as CouponCodeView, D as DropdownFieldView, E as EditProfileView, L as LeaderboardView, H as HeroView, I as InputFieldView, N as NameFieldsView, f as ChangeMarktingView, g as PortalFooterView, h as PortalForgotPasswordView, i as PortalFrameView, R as ReferralIframeView, j as RewardExchangeView, r as rewardExchangeCustomErrorMsg, k as rewardExchangeLongText, l as rewardExchangeSelected, m as chooseAmountFixed, n as chooseAmountFixedNoDescription, o as chooseAmountVariable, p as chooseAmountVariableNoDescription, q as chooseAmountVariableDisabled, s as chooseAmountVariableUnavailable, t as confirmFixed, v as confirmVariable, w as redemptionError, x as queryError, y as success, z as successVariable, A as loading, F as empty$1, G as rewardExchange, J as useShareButton, K as useShareLink, M as ProgressBarView, O as ProgressBar$2, Q as ShadowViewAddon } from './ShadowViewAddon-
|
|
31
|
+
import { S as StatContainerView, B as BigStatView, a as ShareButtonView, P as PortalChangePasswordView, b as PoweredByImg$1, u as useDemoBigStat, T as TaskCardView, C as CardFeedView, c as CheckboxFieldView, d as PortalRegisterView, e as CouponCodeView, D as DropdownFieldView, E as EditProfileView, L as LeaderboardView, H as HeroView, I as InputFieldView, N as NameFieldsView, f as ChangeMarktingView, g as PortalFooterView, h as PortalForgotPasswordView, i as PortalFrameView, R as ReferralIframeView, j as RewardExchangeView, r as rewardExchangeCustomErrorMsg, k as rewardExchangeLongText, l as rewardExchangeSelected, m as chooseAmountFixed, n as chooseAmountFixedNoDescription, o as chooseAmountVariable, p as chooseAmountVariableNoDescription, q as chooseAmountVariableDisabled, s as chooseAmountVariableUnavailable, t as confirmFixed, v as confirmVariable, w as redemptionError, x as queryError, y as success, z as successVariable, A as loading, F as empty$1, G as rewardExchange, J as useShareButton, K as useShareLink, M as ProgressBarView, O as ProgressBar$2, Q as ShadowViewAddon } from './ShadowViewAddon-41dd2aeb.js';
|
|
32
32
|
import { P as PortalContainerView, a as PortalSectionView } from './sqm-portal-container-view-176e92e3.js';
|
|
33
33
|
import { I as InvoiceTableView, a as INDIRECT_TAX_SPAIN_REGIONS, b as INDIRECT_TAX_PROVINCES, O as OtherRegionSlotView } from './IndirectTaxDetailsView-67deb1d0.js';
|
|
34
34
|
import { t as taxTypeToName, L as LoadingView } from './utils-325c4849.js';
|