@saasquatch/mint-components 1.15.5-3 → 1.15.5
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-28865623.js → ShadowViewAddon-e9dc77e3.js} +2 -2
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/mint-components.cjs.js +1 -1
- package/dist/cjs/sqm-banking-info-form_17.cjs.entry.js +234 -378
- package/dist/cjs/{sqm-base-registration-form-view-8029d30e.js → sqm-base-registration-form-view-66f99821.js} +9 -4
- package/dist/cjs/sqm-big-stat_43.cjs.entry.js +10 -143
- package/dist/cjs/{sqm-invoice-table-view-3f60fba9.js → sqm-invoice-table-view-5c74607f.js} +0 -1
- package/dist/cjs/sqm-portal-google-registration-form.cjs.entry.js +25 -18
- package/dist/cjs/sqm-stencilbook.cjs.entry.js +8 -5
- package/dist/cjs/{usePayoutStatus-fc4e609e.js → usePayoutStatus-733ef29a.js} +2 -167
- package/dist/collection/components/sqm-base-registration/BaseRegistrationForm.stories.js +2 -2
- package/dist/collection/components/sqm-base-registration/sqm-base-registration-form-view.js +9 -4
- package/dist/collection/components/sqm-checkbox-field/sqm-checkbox-field.js +1 -1
- package/dist/collection/components/sqm-dropdown-field/sqm-dropdown-field.js +1 -1
- package/dist/collection/components/sqm-input-field/sqm-input-field.js +1 -1
- package/dist/collection/components/sqm-marketing-emails-checkbox/sqm-marketing-emails-checkbox.js +1 -1
- package/dist/collection/components/sqm-name-fields/NameFields.stories.js +2 -0
- package/dist/collection/components/sqm-name-fields/sqm-name-fields-view.js +3 -3
- package/dist/collection/components/sqm-name-fields/sqm-name-fields.js +31 -1
- package/dist/collection/components/sqm-name-fields/useNameFields.js +1 -0
- package/dist/collection/components/sqm-password-field/sqm-password-field.js +2 -2
- package/dist/collection/components/sqm-portal-google-registration-form/PortalGoogleRegistrationForm.stories.js +1 -0
- package/dist/collection/components/sqm-portal-google-registration-form/sqm-portal-google-registration-form.js +4 -4
- package/dist/collection/components/sqm-portal-google-registration-form/usePortalGoogleRegistrationForm.js +22 -15
- package/dist/collection/components/tax-and-cash/TaxForm.stories.js +0 -1
- package/dist/collection/components/tax-and-cash/sqm-indirect-tax-form/useIndirectTaxForm.js +40 -46
- package/dist/collection/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert-view.js +1 -87
- package/dist/collection/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert.js +0 -327
- package/dist/collection/components/tax-and-cash/sqm-payout-status-alert/usePayoutStatus.js +3 -27
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash/sqm-tax-and-cash.js +0 -300
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard-view.js +1 -85
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard.js +0 -300
- package/dist/collection/components/tax-and-cash/sqm-user-info-form/sqm-user-info-form-view.js +12 -23
- package/dist/collection/components/tax-and-cash/sqm-user-info-form/sqm-user-info-form.js +1 -1
- package/dist/collection/components/tax-and-cash/sqm-user-info-form/useUserInfoForm.js +9 -92
- package/dist/esm/{ShadowViewAddon-f2176779.js → ShadowViewAddon-e0d5f1c9.js} +2 -2
- package/dist/esm/loader.js +1 -1
- package/dist/esm/mint-components.js +1 -1
- package/dist/esm/sqm-banking-info-form_17.entry.js +188 -332
- package/dist/esm/{sqm-base-registration-form-view-dafba287.js → sqm-base-registration-form-view-d81e316a.js} +9 -4
- package/dist/esm/sqm-big-stat_43.entry.js +10 -143
- package/dist/esm/{sqm-invoice-table-view-01453fa3.js → sqm-invoice-table-view-3491dd80.js} +0 -1
- package/dist/esm/sqm-portal-google-registration-form.entry.js +25 -18
- package/dist/esm/sqm-stencilbook.entry.js +8 -5
- package/dist/esm/{usePayoutStatus-b4bdbfa7.js → usePayoutStatus-b89e8c49.js} +4 -154
- package/dist/esm-es5/{ShadowViewAddon-f2176779.js → ShadowViewAddon-e0d5f1c9.js} +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/esm-es5/mint-components.js +1 -1
- package/dist/esm-es5/sqm-banking-info-form_17.entry.js +1 -1
- package/dist/esm-es5/sqm-base-registration-form-view-d81e316a.js +1 -0
- package/dist/esm-es5/sqm-big-stat_43.entry.js +1 -1
- package/dist/esm-es5/sqm-invoice-table-view-3491dd80.js +1 -0
- package/dist/esm-es5/sqm-portal-google-registration-form.entry.js +1 -1
- package/dist/esm-es5/sqm-stencilbook.entry.js +1 -1
- package/dist/esm-es5/usePayoutStatus-b89e8c49.js +6 -0
- package/dist/mint-components/mint-components.esm.js +1 -1
- package/dist/mint-components/p-021b0540.js +46 -0
- package/dist/mint-components/{p-4a731079.entry.js → p-1edebab1.entry.js} +2 -2
- package/dist/mint-components/p-37996351.system.js +1 -1
- package/dist/mint-components/{p-02832118.system.entry.js → p-3ac8613d.system.entry.js} +1 -1
- package/dist/mint-components/{p-c1b074b6.js → p-3b6dccec.js} +1 -1
- package/dist/mint-components/p-3d73cd84.entry.js +220 -0
- package/dist/mint-components/p-43e274e9.entry.js +1 -0
- package/dist/mint-components/p-49932f12.system.js +1 -0
- package/dist/mint-components/p-8db18561.system.entry.js +1 -0
- package/dist/mint-components/p-9308221f.js +1 -0
- package/dist/mint-components/p-959c42b2.system.entry.js +1 -0
- package/dist/mint-components/p-a6494752.system.js +6 -0
- package/dist/mint-components/p-bc021969.system.js +1 -0
- package/dist/mint-components/p-c78e6066.entry.js +273 -0
- package/dist/mint-components/{p-0d939b73.system.js → p-d15b642f.system.js} +1 -1
- package/dist/mint-components/p-e64e8354.system.entry.js +1 -0
- package/dist/mint-components/p-e8e48982.js +1 -0
- package/dist/types/components/sqm-base-registration/sqm-base-registration-form-view.d.ts +2 -1
- package/dist/types/components/sqm-checkbox-field/sqm-checkbox-field.d.ts +1 -1
- package/dist/types/components/sqm-dropdown-field/sqm-dropdown-field.d.ts +1 -1
- package/dist/types/components/sqm-input-field/sqm-input-field.d.ts +1 -1
- package/dist/types/components/sqm-marketing-emails-checkbox/sqm-marketing-emails-checkbox.d.ts +1 -1
- package/dist/types/components/sqm-name-fields/sqm-name-fields-view.d.ts +1 -0
- package/dist/types/components/sqm-name-fields/sqm-name-fields.d.ts +5 -0
- package/dist/types/components/sqm-name-fields/useNameFields.d.ts +1 -0
- package/dist/types/components/sqm-password-field/sqm-password-field.d.ts +1 -1
- package/dist/types/components/sqm-portal-google-registration-form/usePortalGoogleRegistrationForm.d.ts +2 -1
- package/dist/types/components/tax-and-cash/sqm-indirect-tax-form/useIndirectTaxForm.d.ts +0 -23
- package/dist/types/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert-view.d.ts +0 -14
- package/dist/types/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert.d.ts +0 -53
- package/dist/types/components/tax-and-cash/sqm-payout-status-alert/usePayoutStatus.d.ts +1 -2
- package/dist/types/components/tax-and-cash/sqm-tax-and-cash/sqm-tax-and-cash.d.ts +0 -48
- package/dist/types/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard-view.d.ts +0 -12
- package/dist/types/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard.d.ts +0 -48
- package/dist/types/components/tax-and-cash/sqm-user-info-form/sqm-user-info-form-view.d.ts +0 -2
- package/dist/types/components/tax-and-cash/sqm-user-info-form/useUserInfoForm.d.ts +0 -1
- package/dist/types/components.d.ts +10 -296
- package/docs/docs.docx +0 -0
- package/docs/raisins.json +1 -1
- package/grapesjs/grapesjs.js +1 -1
- package/package.json +1 -1
- package/dist/esm-es5/sqm-base-registration-form-view-dafba287.js +0 -1
- package/dist/esm-es5/sqm-invoice-table-view-01453fa3.js +0 -1
- package/dist/esm-es5/usePayoutStatus-b4bdbfa7.js +0 -6
- package/dist/mint-components/p-2651ef99.system.js +0 -1
- package/dist/mint-components/p-35701119.js +0 -1
- package/dist/mint-components/p-50988798.system.entry.js +0 -1
- package/dist/mint-components/p-59fe6066.js +0 -1
- package/dist/mint-components/p-86a5db85.system.js +0 -1
- package/dist/mint-components/p-93db61eb.system.js +0 -6
- package/dist/mint-components/p-9c4f4cd6.entry.js +0 -1
- package/dist/mint-components/p-a3647f70.system.entry.js +0 -1
- package/dist/mint-components/p-a4f494ee.system.entry.js +0 -1
- package/dist/mint-components/p-e3deed72.entry.js +0 -273
- package/dist/mint-components/p-e8981f26.entry.js +0 -109
- package/dist/mint-components/p-fde41ad1.js +0 -157
|
@@ -38,6 +38,7 @@ sqm-portal-register {
|
|
|
38
38
|
const sheet = createStyleSheet(style);
|
|
39
39
|
const styleString = sheet.toString();
|
|
40
40
|
function BaseRegistrationFormView(props) {
|
|
41
|
+
var _a, _b;
|
|
41
42
|
const { states, content, callbacks } = props;
|
|
42
43
|
return (h("div", { class: sheet.classes.Wrapper },
|
|
43
44
|
h("style", { type: "text/css" },
|
|
@@ -45,10 +46,8 @@ function BaseRegistrationFormView(props) {
|
|
|
45
46
|
styleString),
|
|
46
47
|
h(TextSpanView, { type: "h3" }, content.pageLabel),
|
|
47
48
|
h("sl-form", { class: sheet.classes.Column, "onSl-submit": callbacks.handleEmailSubmit, novalidate: true },
|
|
48
|
-
states.error && (h("sqm-form-message", { type: "error", exportparts: "erroralert-icon" },
|
|
49
|
-
h("div", { part: "erroralert-text" }, props.states.error))),
|
|
50
49
|
content.formData,
|
|
51
|
-
h("sl-input", { exportparts: "label: input-label, base: input-base", type: "email", name: "/email", label: content.emailLabel || "Email", required: true, validationError: ({ value }) => {
|
|
50
|
+
h("sl-input", Object.assign({ exportparts: "label: input-label, base: input-base", type: "email", name: "/email", label: content.emailLabel || "Email", required: true, validationError: ({ value }) => {
|
|
52
51
|
if (!value) {
|
|
53
52
|
return content.requiredFieldErrorMessage;
|
|
54
53
|
}
|
|
@@ -56,7 +55,13 @@ function BaseRegistrationFormView(props) {
|
|
|
56
55
|
if (!value.includes("@")) {
|
|
57
56
|
return content.invalidEmailErrorMessage;
|
|
58
57
|
}
|
|
59
|
-
} })
|
|
58
|
+
} }, (((_a = states === null || states === void 0 ? void 0 : states.validationErrors) === null || _a === void 0 ? void 0 : _a.email) ? {
|
|
59
|
+
class: sheet.classes.ErrorStyle,
|
|
60
|
+
helpText: ((_b = states === null || states === void 0 ? void 0 : states.validationErrors) === null || _b === void 0 ? void 0 : _b.email) ||
|
|
61
|
+
content.requiredFieldErrorMessage,
|
|
62
|
+
}
|
|
63
|
+
: []))),
|
|
64
|
+
content.terms,
|
|
60
65
|
h("div", { class: sheet.classes.ButtonsContainer },
|
|
61
66
|
h("sl-button", { submit: true, exportparts: "base: primarybutton-base", type: "primary", style: { margin: "0" } }, content.submitLabel || "Register"),
|
|
62
67
|
h("sl-menu-divider", { style: { margin: "0" } }),
|
|
@@ -20,9 +20,9 @@ import { P as PortalLoginView } from './sqm-portal-login-view-7e49609a.js';
|
|
|
20
20
|
import { u as usePortalLogin } from './usePortalLogin-ef647a50.js';
|
|
21
21
|
import { A as AsYouType } from './AsYouType-46f67d0d.js';
|
|
22
22
|
import { i as isEmpty } from './utilities-5b0ca040.js';
|
|
23
|
-
import { b as useDemoBigStat, W as useBigStat, B as BigStatView, U as autoColorScaleCss, J as CardFeedView, i as CheckboxFieldView, K as CouponCodeView, D as DropdownFieldView, E as EditProfileView, H as HeroView, I as InputFieldView, Q as LeadDropdownFieldView, O as LeadFormView, X as withShadowView, L as LeaderboardView, N as NameFieldsView, C as ChangeMarktingView, d as PortalChangePasswordView, h as PortalFooterView, P as PortalFrameView, e as PortalRegisterView, R as ReferralIframeView, Y as demoRewardExchange, j as RewardExchangeView, a as useShareButton, S as ShareButtonView, u as useShareLink, c as StatContainerView, T as TaskCardView } from './ShadowViewAddon-
|
|
23
|
+
import { b as useDemoBigStat, W as useBigStat, B as BigStatView, U as autoColorScaleCss, J as CardFeedView, i as CheckboxFieldView, K as CouponCodeView, D as DropdownFieldView, E as EditProfileView, H as HeroView, I as InputFieldView, Q as LeadDropdownFieldView, O as LeadFormView, X as withShadowView, L as LeaderboardView, N as NameFieldsView, C as ChangeMarktingView, d as PortalChangePasswordView, h as PortalFooterView, P as PortalFrameView, e as PortalRegisterView, R as ReferralIframeView, Y as demoRewardExchange, j as RewardExchangeView, a as useShareButton, S as ShareButtonView, u as useShareLink, c as StatContainerView, T as TaskCardView } from './ShadowViewAddon-e0d5f1c9.js';
|
|
24
24
|
import './sqm-portal-container-view-1683ae32.js';
|
|
25
|
-
import { u as usePayoutStatus } from './usePayoutStatus-
|
|
25
|
+
import { u as usePayoutStatus } from './usePayoutStatus-b89e8c49.js';
|
|
26
26
|
|
|
27
27
|
const BigStat = class {
|
|
28
28
|
constructor(hostRef) {
|
|
@@ -2025,6 +2025,7 @@ function useNameFields(props) {
|
|
|
2025
2025
|
const registrationFormState = d(REGISTRATION_FORM_STATE_CONTEXT);
|
|
2026
2026
|
return {
|
|
2027
2027
|
states: {
|
|
2028
|
+
optional: props.optional,
|
|
2028
2029
|
registrationFormState,
|
|
2029
2030
|
content: {
|
|
2030
2031
|
lastNameLabel: props.lastNameLabel,
|
|
@@ -2046,6 +2047,11 @@ const NameFields = class {
|
|
|
2046
2047
|
* @uiName Last name label
|
|
2047
2048
|
*/
|
|
2048
2049
|
this.lastNameLabel = "Last Name";
|
|
2050
|
+
/**
|
|
2051
|
+
* @uiName Optional
|
|
2052
|
+
* @uiWidget
|
|
2053
|
+
*/
|
|
2054
|
+
this.optional = false;
|
|
2049
2055
|
h(this);
|
|
2050
2056
|
}
|
|
2051
2057
|
disconnectedCallback() { }
|
|
@@ -2057,6 +2063,7 @@ const NameFields = class {
|
|
|
2057
2063
|
function useNameFieldsDemo(props) {
|
|
2058
2064
|
return cjs({
|
|
2059
2065
|
states: {
|
|
2066
|
+
optional: props.optional,
|
|
2060
2067
|
validationErrors: [],
|
|
2061
2068
|
content: {
|
|
2062
2069
|
firstNameLabel: props.firstNameLabel,
|
|
@@ -2390,7 +2397,7 @@ function PayoutStatusAlertView(props) {
|
|
|
2390
2397
|
class: sheet$2.classes.WarningAlertContainer,
|
|
2391
2398
|
};
|
|
2392
2399
|
}
|
|
2393
|
-
case "
|
|
2400
|
+
case "ACCOUNT_REVIEW":
|
|
2394
2401
|
return {
|
|
2395
2402
|
header: text.accountReviewHeader,
|
|
2396
2403
|
description: intl.formatMessage({
|
|
@@ -2404,90 +2411,6 @@ function PayoutStatusAlertView(props) {
|
|
|
2404
2411
|
icon: "exclamation-triangle",
|
|
2405
2412
|
class: sheet$2.classes.WarningAlertContainer,
|
|
2406
2413
|
};
|
|
2407
|
-
case "PAYMENT_HOLD_ON_CHANGE":
|
|
2408
|
-
return {
|
|
2409
|
-
header: text.paymentHoldOnChangeHeader,
|
|
2410
|
-
description: intl.formatMessage({
|
|
2411
|
-
id: "accountReviewDescription",
|
|
2412
|
-
defaultMessage: text.paymentHoldOnChangeDescription,
|
|
2413
|
-
}, {
|
|
2414
|
-
supportLink: (h$1("a", { target: "_blank", href: `mailto:advocate-support@impact.com` }, text.supportLink)),
|
|
2415
|
-
}),
|
|
2416
|
-
buttonText: null,
|
|
2417
|
-
alertType: "warning",
|
|
2418
|
-
icon: "exclamation-triangle",
|
|
2419
|
-
class: sheet$2.classes.WarningAlertContainer,
|
|
2420
|
-
};
|
|
2421
|
-
case "BENEFICIARY_NAME_INVALID":
|
|
2422
|
-
return {
|
|
2423
|
-
header: text.beneficiaryNameInvalidHeader,
|
|
2424
|
-
description: intl.formatMessage({
|
|
2425
|
-
id: "accountReviewDescription",
|
|
2426
|
-
defaultMessage: text.beneficiaryNameInvalidDescription,
|
|
2427
|
-
}, {
|
|
2428
|
-
supportLink: (h$1("a", { target: "_blank", href: `mailto:advocate-support@impact.com` }, text.supportLink)),
|
|
2429
|
-
}),
|
|
2430
|
-
buttonText: text.editPaymentInformationButton,
|
|
2431
|
-
alertType: "warning",
|
|
2432
|
-
icon: "exclamation-triangle",
|
|
2433
|
-
class: sheet$2.classes.WarningAlertContainer,
|
|
2434
|
-
};
|
|
2435
|
-
case "BENEFICIARY_NAME_MISMATCH":
|
|
2436
|
-
return {
|
|
2437
|
-
header: text.beneficiaryNameMismatchHeader,
|
|
2438
|
-
description: intl.formatMessage({
|
|
2439
|
-
id: "accountReviewDescription",
|
|
2440
|
-
defaultMessage: text.beneficiaryNameMismatchDescription,
|
|
2441
|
-
}, {
|
|
2442
|
-
supportLink: (h$1("a", { target: "_blank", href: `mailto:advocate-support@impact.com` }, text.supportLink)),
|
|
2443
|
-
}),
|
|
2444
|
-
buttonText: text.editPaymentInformationButton,
|
|
2445
|
-
alertType: "warning",
|
|
2446
|
-
icon: "exclamation-triangle",
|
|
2447
|
-
class: sheet$2.classes.WarningAlertContainer,
|
|
2448
|
-
};
|
|
2449
|
-
case "BANK_TAX_NAME_MISMATCH":
|
|
2450
|
-
return {
|
|
2451
|
-
header: text.bankTaxNameMismatchHeader,
|
|
2452
|
-
description: intl.formatMessage({
|
|
2453
|
-
id: "accountReviewDescription",
|
|
2454
|
-
defaultMessage: text.bankTaxNameMismatchDescription,
|
|
2455
|
-
}, {
|
|
2456
|
-
supportLink: (h$1("a", { target: "_blank", href: `mailto:advocate-support@impact.com` }, text.supportLink)),
|
|
2457
|
-
}),
|
|
2458
|
-
buttonText: text.editPaymentInformationButton,
|
|
2459
|
-
alertType: "warning",
|
|
2460
|
-
icon: "exclamation-triangle",
|
|
2461
|
-
class: sheet$2.classes.WarningAlertContainer,
|
|
2462
|
-
};
|
|
2463
|
-
case "WITHDRAWAL_SETTINGS_INVALID":
|
|
2464
|
-
return {
|
|
2465
|
-
header: text.withdrawalSettingsInvalidHeader,
|
|
2466
|
-
description: intl.formatMessage({
|
|
2467
|
-
id: "accountReviewDescription",
|
|
2468
|
-
defaultMessage: text.withdrawalSettingsInvalidDescription,
|
|
2469
|
-
}, {
|
|
2470
|
-
supportLink: (h$1("a", { target: "_blank", href: `mailto:advocate-support@impact.com` }, text.supportLink)),
|
|
2471
|
-
}),
|
|
2472
|
-
buttonText: text.editPaymentInformationButton,
|
|
2473
|
-
alertType: "warning",
|
|
2474
|
-
icon: "exclamation-triangle",
|
|
2475
|
-
class: sheet$2.classes.WarningAlertContainer,
|
|
2476
|
-
};
|
|
2477
|
-
case "PAYMENT_RETURNED":
|
|
2478
|
-
return {
|
|
2479
|
-
header: text.paymentReturnedHeader,
|
|
2480
|
-
description: intl.formatMessage({
|
|
2481
|
-
id: "accountReviewDescription",
|
|
2482
|
-
defaultMessage: text.paymentReturnedDescription,
|
|
2483
|
-
}, {
|
|
2484
|
-
supportLink: (h$1("a", { target: "_blank", href: `mailto:advocate-support@impact.com` }, text.supportLink)),
|
|
2485
|
-
}),
|
|
2486
|
-
buttonText: text.editPaymentInformationButton,
|
|
2487
|
-
alertType: "warning",
|
|
2488
|
-
icon: "exclamation-triangle",
|
|
2489
|
-
class: sheet$2.classes.WarningAlertContainer,
|
|
2490
|
-
};
|
|
2491
2414
|
case "HOLD":
|
|
2492
2415
|
return {
|
|
2493
2416
|
header: text.holdHeader,
|
|
@@ -2521,8 +2444,6 @@ function PayoutStatusAlertView(props) {
|
|
|
2521
2444
|
case "VERIFICATION:REQUIRED":
|
|
2522
2445
|
return (h$1("sl-button", { type: "default", loading: states.veriffLoading, onClick: callbacks.onClick }, text.verificationRequiredButtonText));
|
|
2523
2446
|
default:
|
|
2524
|
-
if (alertDetails.buttonText)
|
|
2525
|
-
return (h$1("sl-button", { type: "default", onClick: callbacks.onPaymentInfoClick }, alertDetails.buttonText));
|
|
2526
2447
|
return;
|
|
2527
2448
|
}
|
|
2528
2449
|
}
|
|
@@ -2549,11 +2470,6 @@ const PayoutStatusAlert = class {
|
|
|
2549
2470
|
* @uiName Info required alert header
|
|
2550
2471
|
*/
|
|
2551
2472
|
this.informationRequiredHeader = "Payout and tax information required";
|
|
2552
|
-
/**
|
|
2553
|
-
*
|
|
2554
|
-
* @uiName Edit payment info button label
|
|
2555
|
-
*/
|
|
2556
|
-
this.editPaymentInformationButton = "Edit Payout Information";
|
|
2557
2473
|
/**
|
|
2558
2474
|
* @uiName Info required alert description
|
|
2559
2475
|
*/
|
|
@@ -2606,54 +2522,6 @@ const PayoutStatusAlert = class {
|
|
|
2606
2522
|
* @uiName Account review alert description
|
|
2607
2523
|
*/
|
|
2608
2524
|
this.accountReviewDescription = "This process takes 48 hours, payouts are on hold until it's completed. You will receive an email from our referral provider, Impact.com, if any issues arise. It contains details on how to resolve this issue. If you need further assistance, please reach out to our {supportLink}.";
|
|
2609
|
-
/**
|
|
2610
|
-
* @uiName Payment on hold alert header
|
|
2611
|
-
*/
|
|
2612
|
-
this.paymentHoldOnChangeHeader = "We are reviewing your new payout settings";
|
|
2613
|
-
/**
|
|
2614
|
-
* @uiName Payment on hold alert description
|
|
2615
|
-
*/
|
|
2616
|
-
this.paymentHoldOnChangeDescription = "Your payout is temporarily on hold while we review your new payment information, this process is usually resolved within 48 hours.";
|
|
2617
|
-
/**
|
|
2618
|
-
* @uiName Beneficiary name invalid alert header
|
|
2619
|
-
*/
|
|
2620
|
-
this.beneficiaryNameInvalidHeader = "Your payment information does not match your tax form";
|
|
2621
|
-
/**
|
|
2622
|
-
* @uiName Beneficiary name invalid description
|
|
2623
|
-
*/
|
|
2624
|
-
this.beneficiaryNameInvalidDescription = "The beneficiary name in your payment information does not match what was submitted in your tax form. Please review and update your payment information or tax form so that they match exactly and do not include any invalid characters. Your payouts are on hold until this is resolved.";
|
|
2625
|
-
/**
|
|
2626
|
-
* @uiName Beneficiary name mismatch alert header
|
|
2627
|
-
*/
|
|
2628
|
-
this.beneficiaryNameMismatchHeader = "Your payment information does not match your tax form";
|
|
2629
|
-
/**
|
|
2630
|
-
* @uiName Beneficiary name mismatch alert description
|
|
2631
|
-
*/
|
|
2632
|
-
this.beneficiaryNameMismatchDescription = "The beneficiary name in your payment information does not match what was submitted in your tax form. Please review and update your payment information or tax form so that they match exactly and do not include any invalid characters. Your payouts are on hold until this is resolved.";
|
|
2633
|
-
/**
|
|
2634
|
-
* @uiName Bank name mismatch alert header
|
|
2635
|
-
*/
|
|
2636
|
-
this.bankTaxNameMismatchHeader = "Your payment information does not match your tax form";
|
|
2637
|
-
/**
|
|
2638
|
-
* @uiName Bank name mismatch alert description
|
|
2639
|
-
*/
|
|
2640
|
-
this.bankTaxNameMismatchDescription = "The bank name in your payment information does not match what was submitted in your tax form. Please review and update your payment information or tax form so that they match exactly and do not include any invalid characters. Your payouts are on hold until this is resolved.";
|
|
2641
|
-
/**
|
|
2642
|
-
* @uiName Withdrawal settings invalid alert header
|
|
2643
|
-
*/
|
|
2644
|
-
this.withdrawalSettingsInvalidHeader = "Your payment information includes invalid characters";
|
|
2645
|
-
/**
|
|
2646
|
-
* @uiName Withdrawal settings invalid alert description
|
|
2647
|
-
*/
|
|
2648
|
-
this.withdrawalSettingsInvalidDescription = "There are invalid characters in your payment information. Please review your information and make sure it is correct with no invalid characters. Your payouts are on hold until this is resolved.";
|
|
2649
|
-
/**
|
|
2650
|
-
* @uiName Payment returned alert header
|
|
2651
|
-
*/
|
|
2652
|
-
this.paymentReturnedHeader = "Payout unsuccessful";
|
|
2653
|
-
/**
|
|
2654
|
-
* @uiName Payment returned alert description
|
|
2655
|
-
*/
|
|
2656
|
-
this.paymentReturnedDescription = "Our recent payment attempt for your earnings was unsuccessful. Please review your payment information and make sure it is correct.";
|
|
2657
2525
|
/**
|
|
2658
2526
|
* @uiName W-9 payment threshold alert header
|
|
2659
2527
|
*/
|
|
@@ -2720,7 +2588,6 @@ function useDemoPayoutStatusAlert(props) {
|
|
|
2720
2588
|
callbacks: {
|
|
2721
2589
|
onTermsClick: () => { },
|
|
2722
2590
|
onClick: () => console.log("show"),
|
|
2723
|
-
onPaymentInfoClick: () => { },
|
|
2724
2591
|
},
|
|
2725
2592
|
}, props.demoData || {}, { arrayMerge: (_, a) => a });
|
|
2726
2593
|
}
|
|
@@ -7,7 +7,7 @@ import { c as createStyleSheet } from './JSS-67b5cff8.js';
|
|
|
7
7
|
import './mixins-83f90fa1.js';
|
|
8
8
|
import './sqm-text-span-view-ca32495e.js';
|
|
9
9
|
import { a as useRegistrationForm } from './useRegistrationFormState-d6f33135.js';
|
|
10
|
-
import { B as BaseRegistrationFormView } from './sqm-base-registration-form-view-
|
|
10
|
+
import { B as BaseRegistrationFormView } from './sqm-base-registration-form-view-d81e316a.js';
|
|
11
11
|
import { P as PortalRegistrationFormView } from './sqm-portal-registration-form-view-3c1f6000.js';
|
|
12
12
|
import './AsYouType-46f67d0d.js';
|
|
13
13
|
import { u as usePortalRegistrationForm } from './usePortalRegistrationForm-4b35a357.js';
|
|
@@ -71,7 +71,6 @@ function jwtDecode(token, options) {
|
|
|
71
71
|
}
|
|
72
72
|
|
|
73
73
|
function usePortalGoogleRegistrationForm(props) {
|
|
74
|
-
const [emailValidationError, setEmailValidationError] = useState(null);
|
|
75
74
|
const [registrationFormState, setRegistrationFormState] = useRegistrationForm();
|
|
76
75
|
const [showRegistrationForm, setShowRegistrationForm] = useState({
|
|
77
76
|
mode: "base",
|
|
@@ -79,33 +78,40 @@ function usePortalGoogleRegistrationForm(props) {
|
|
|
79
78
|
const handleEmailSubmit = async (event) => {
|
|
80
79
|
const formControls = event.target.getFormControls();
|
|
81
80
|
let formData = {};
|
|
82
|
-
let
|
|
81
|
+
let validationErrors = {};
|
|
83
82
|
formControls.forEach((control) => {
|
|
84
83
|
if (!control.name)
|
|
85
84
|
return;
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
85
|
+
const key = control.name;
|
|
86
|
+
const value = control.value;
|
|
87
|
+
jsonpointer.set(formData, key, value);
|
|
88
|
+
if (control.required && !value) {
|
|
89
|
+
jsonpointer.set(validationErrors, key, props.requiredFieldErrorMessage);
|
|
90
|
+
}
|
|
92
91
|
if (typeof control.validationError === "function") {
|
|
93
92
|
const validate = control.validationError;
|
|
94
93
|
const validationError = validate({
|
|
95
94
|
control,
|
|
96
|
-
key
|
|
97
|
-
value
|
|
95
|
+
key,
|
|
96
|
+
value,
|
|
98
97
|
});
|
|
99
98
|
if (validationError)
|
|
100
|
-
|
|
99
|
+
jsonpointer.set(validationErrors, key, validationError);
|
|
101
100
|
}
|
|
102
101
|
});
|
|
103
|
-
if (
|
|
104
|
-
|
|
102
|
+
if (Object.keys(validationErrors).length) {
|
|
103
|
+
// early return for validation errors
|
|
104
|
+
setRegistrationFormState({
|
|
105
|
+
...registrationFormState,
|
|
106
|
+
loading: false,
|
|
107
|
+
error: "",
|
|
108
|
+
validationErrors,
|
|
109
|
+
});
|
|
105
110
|
return;
|
|
106
111
|
}
|
|
107
112
|
setRegistrationFormState({
|
|
108
113
|
...registrationFormState,
|
|
114
|
+
validationErrors: {},
|
|
109
115
|
initialData: {
|
|
110
116
|
...registrationFormState === null || registrationFormState === void 0 ? void 0 : registrationFormState.initialData,
|
|
111
117
|
...formData,
|
|
@@ -135,8 +141,9 @@ function usePortalGoogleRegistrationForm(props) {
|
|
|
135
141
|
}
|
|
136
142
|
};
|
|
137
143
|
return {
|
|
144
|
+
registrationFormState,
|
|
138
145
|
showRegistrationForm,
|
|
139
|
-
|
|
146
|
+
validationErrors: registrationFormState.validationErrors,
|
|
140
147
|
handleGoogleInit,
|
|
141
148
|
handleEmailSubmit,
|
|
142
149
|
};
|
|
@@ -292,7 +299,7 @@ const PortalGoogleRegistrationForm = class {
|
|
|
292
299
|
};
|
|
293
300
|
const sheet = createStyleSheet(styles);
|
|
294
301
|
const styleString = sheet.toString();
|
|
295
|
-
const { handleGoogleInit, handleEmailSubmit, showRegistrationForm,
|
|
302
|
+
const { handleGoogleInit, handleEmailSubmit, showRegistrationForm, validationErrors, } = isDemo() ? useGoogleDemo(this) : usePortalGoogleRegistrationForm(this);
|
|
296
303
|
const content = {
|
|
297
304
|
formData: h$1("slot", { name: "formData" }),
|
|
298
305
|
googleButton: (h$1("sqm-google-sign-in", { text: this.googleButtonText, onInitComplete: handleGoogleInit })),
|
|
@@ -317,7 +324,7 @@ const PortalGoogleRegistrationForm = class {
|
|
|
317
324
|
};
|
|
318
325
|
if (showRegistrationForm.mode === "base") {
|
|
319
326
|
return (h$1(BaseRegistrationFormView, { states: {
|
|
320
|
-
|
|
327
|
+
validationErrors,
|
|
321
328
|
}, callbacks: { handleEmailSubmit }, content: content }));
|
|
322
329
|
}
|
|
323
330
|
return (h$1(PortalRegistrationFormView, { states: {
|
|
@@ -360,7 +367,7 @@ function useGoogleDemo(props) {
|
|
|
360
367
|
mode: "base",
|
|
361
368
|
});
|
|
362
369
|
return cjs({
|
|
363
|
-
|
|
370
|
+
validationErrors: {},
|
|
364
371
|
handleEmailSubmit: () => setShowRegistrationForm({ mode: "manual" }),
|
|
365
372
|
showRegistrationForm,
|
|
366
373
|
handleGoogleInit: () => setShowRegistrationForm({ mode: "google" }),
|
|
@@ -24,7 +24,7 @@ import { N as NavigationSidebarItemView } from './sqm-navigation-sidebar-item-vi
|
|
|
24
24
|
import { P as PortalEmailVerificationView } from './sqm-portal-email-verification-view-35b4353b.js';
|
|
25
25
|
import { P as PortalForgotPasswordView } from './sqm-portal-forgot-password-view-3d3182f1.js';
|
|
26
26
|
import { P as PortalLoginView } from './sqm-portal-login-view-7e49609a.js';
|
|
27
|
-
import { B as BaseRegistrationFormView } from './sqm-base-registration-form-view-
|
|
27
|
+
import { B as BaseRegistrationFormView } from './sqm-base-registration-form-view-d81e316a.js';
|
|
28
28
|
import { P as PortalRegistrationFormView } from './sqm-portal-registration-form-view-3c1f6000.js';
|
|
29
29
|
import { P as PortalProfileView } from './sqm-portal-profile-view-93003974.js';
|
|
30
30
|
import './utilities-5b0ca040.js';
|
|
@@ -32,9 +32,9 @@ import { P as PortalResetPasswordView } from './sqm-portal-reset-password-view-5
|
|
|
32
32
|
import { P as PortalVerifyEmailView } from './sqm-portal-verify-email-view-b12cb894.js';
|
|
33
33
|
import './ErrorView-48e2b969.js';
|
|
34
34
|
import { Q as QrCodeView } from './sqm-qr-code-view-f1d0763b.js';
|
|
35
|
-
import { S as ShareButtonView, L as LeaderboardView, B as BigStatView, P as PortalFrameView, E as EditProfileView, u as useShareLink, a as useShareButton, b as useDemoBigStat, c as StatContainerView, d as PortalChangePasswordView, e as PortalRegisterView, C as ChangeMarktingView, T as TaskCardView, f as ProgressBarView, g as PoweredByImg$1, h as PortalFooterView, H as HeroView, R as ReferralIframeView, N as NameFieldsView, i as CheckboxFieldView, D as DropdownFieldView, I as InputFieldView, 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 CardFeedView, K as CouponCodeView, M as ProgressBar$2, O as LeadFormView, Q as LeadDropdownFieldView, U as autoColorScaleCss, V as ShadowViewAddon } from './ShadowViewAddon-
|
|
35
|
+
import { S as ShareButtonView, L as LeaderboardView, B as BigStatView, P as PortalFrameView, E as EditProfileView, u as useShareLink, a as useShareButton, b as useDemoBigStat, c as StatContainerView, d as PortalChangePasswordView, e as PortalRegisterView, C as ChangeMarktingView, T as TaskCardView, f as ProgressBarView, g as PoweredByImg$1, h as PortalFooterView, H as HeroView, R as ReferralIframeView, N as NameFieldsView, i as CheckboxFieldView, D as DropdownFieldView, I as InputFieldView, 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 CardFeedView, K as CouponCodeView, M as ProgressBar$2, O as LeadFormView, Q as LeadDropdownFieldView, U as autoColorScaleCss, V as ShadowViewAddon } from './ShadowViewAddon-e0d5f1c9.js';
|
|
36
36
|
import { P as PortalContainerView, a as PortalSectionView } from './sqm-portal-container-view-1683ae32.js';
|
|
37
|
-
import { O as OtherRegionSlotView, I as InvoiceTableView, T as TaxForm } from './sqm-invoice-table-view-
|
|
37
|
+
import { O as OtherRegionSlotView, I as InvoiceTableView, T as TaxForm } from './sqm-invoice-table-view-3491dd80.js';
|
|
38
38
|
import { L as LeadInputFieldView } from './sqm-lead-input-field-view-4ede5d7f.js';
|
|
39
39
|
|
|
40
40
|
/**
|
|
@@ -10829,6 +10829,7 @@ const NameFields_stories = {
|
|
|
10829
10829
|
};
|
|
10830
10830
|
const props$1 = {
|
|
10831
10831
|
states: {
|
|
10832
|
+
optional: false,
|
|
10832
10833
|
registrationFormState: {
|
|
10833
10834
|
validationErrors: undefined,
|
|
10834
10835
|
},
|
|
@@ -10840,6 +10841,7 @@ const props$1 = {
|
|
|
10840
10841
|
};
|
|
10841
10842
|
const errorProps$9 = {
|
|
10842
10843
|
states: {
|
|
10844
|
+
optional: false,
|
|
10843
10845
|
registrationFormState: {
|
|
10844
10846
|
validationErrors: {
|
|
10845
10847
|
firstName: "Cannot be empty",
|
|
@@ -15636,7 +15638,7 @@ const BaseRegistrationForm_stories = {
|
|
|
15636
15638
|
};
|
|
15637
15639
|
const defaultProps$q = {
|
|
15638
15640
|
states: {
|
|
15639
|
-
|
|
15641
|
+
validationErrors: {},
|
|
15640
15642
|
},
|
|
15641
15643
|
callbacks: {
|
|
15642
15644
|
handleEmailSubmit: () => console.log("Submit!"),
|
|
@@ -15656,7 +15658,7 @@ const defaultProps$q = {
|
|
|
15656
15658
|
const errorProps$a = {
|
|
15657
15659
|
...defaultProps$q,
|
|
15658
15660
|
states: {
|
|
15659
|
-
error: "Something went wrong. Please try again.",
|
|
15661
|
+
validationErrors: { error: "Something went wrong. Please try again." },
|
|
15660
15662
|
},
|
|
15661
15663
|
};
|
|
15662
15664
|
const Default$o = () => {
|
|
@@ -15703,6 +15705,7 @@ const defaultProps$r = {
|
|
|
15703
15705
|
formData: (h("div", null,
|
|
15704
15706
|
" ",
|
|
15705
15707
|
h(NameFieldsView, { states: {
|
|
15708
|
+
optional: false,
|
|
15706
15709
|
registrationFormState: {
|
|
15707
15710
|
validationErrors: undefined,
|
|
15708
15711
|
disabled: true,
|
|
@@ -1,135 +1,8 @@
|
|
|
1
1
|
import { k as useState, f as useEffect } from './stencil-hooks.module-4bc38af4.js';
|
|
2
|
-
import { d as dist, J, $ as $e, g as getEnvironmentSDK, w as wn
|
|
2
|
+
import { d as dist, J, $ as $e, g as getEnvironmentSDK, w as wn } from './index.module-89a79f66.js';
|
|
3
3
|
|
|
4
4
|
const TAX_FORM_UPDATED_EVENT_KEY = "sqm:tax-form-updated";
|
|
5
5
|
|
|
6
|
-
const TAX_CONTEXT_NAMESPACE = "sq:tax-and-cash";
|
|
7
|
-
const TAX_FORM_CONTEXT_NAMESPACE = "sq:tax-form-context";
|
|
8
|
-
const USER_QUERY_NAMESPACE = "sq:user-info-query";
|
|
9
|
-
const USER_FORM_CONTEXT_NAMESPACE = "sq:user-form-context";
|
|
10
|
-
const FINANCE_NETWORK_SETTINGS_NAMESPACE = "sq:finance-network-settings";
|
|
11
|
-
const COUNTRIES_NAMESPACE = "sq:countries:list";
|
|
12
|
-
const SORTED_COUNTRIES_NAMESPACE = "sq:countries:sorted";
|
|
13
|
-
const COUNTRIES_QUERY_NAMESPACE = "sq:countries:query";
|
|
14
|
-
const CURRENCIES_NAMESPACE = "sq:currencies:list";
|
|
15
|
-
const CURRENCIES_QUERY_NAMESPACE = "sq:currencies:query";
|
|
16
|
-
const GET_USER = dist.gql `
|
|
17
|
-
query getUserTaxInfo {
|
|
18
|
-
user: viewer {
|
|
19
|
-
... on User {
|
|
20
|
-
id
|
|
21
|
-
firstName
|
|
22
|
-
lastName
|
|
23
|
-
email
|
|
24
|
-
countryCode
|
|
25
|
-
customFields
|
|
26
|
-
rewards(limit: 1000) {
|
|
27
|
-
data {
|
|
28
|
-
statuses
|
|
29
|
-
partnerFundsTransfer {
|
|
30
|
-
id
|
|
31
|
-
status
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
managedIdentity {
|
|
36
|
-
uid
|
|
37
|
-
email
|
|
38
|
-
emailVerified
|
|
39
|
-
}
|
|
40
|
-
impactConnection {
|
|
41
|
-
connected
|
|
42
|
-
user {
|
|
43
|
-
firstName
|
|
44
|
-
lastName
|
|
45
|
-
}
|
|
46
|
-
publisher {
|
|
47
|
-
id
|
|
48
|
-
brandedSignup
|
|
49
|
-
countryCode
|
|
50
|
-
currency
|
|
51
|
-
billingAddress
|
|
52
|
-
billingCity
|
|
53
|
-
billingState
|
|
54
|
-
billingCountryCode
|
|
55
|
-
billingPostalCode
|
|
56
|
-
phoneNumberCountryCode
|
|
57
|
-
phoneNumber
|
|
58
|
-
taxInformation {
|
|
59
|
-
indirectTaxId
|
|
60
|
-
indirectTaxCountryCode
|
|
61
|
-
indirectTaxRegion
|
|
62
|
-
additionalTaxId
|
|
63
|
-
withholdingTaxId
|
|
64
|
-
withholdingTaxCountryCode
|
|
65
|
-
}
|
|
66
|
-
requiredTaxDocumentType
|
|
67
|
-
currentTaxDocument {
|
|
68
|
-
status
|
|
69
|
-
type
|
|
70
|
-
dateCreated
|
|
71
|
-
}
|
|
72
|
-
withdrawalSettings {
|
|
73
|
-
paymentMethod
|
|
74
|
-
paypalEmailAddress
|
|
75
|
-
bankCountry
|
|
76
|
-
bankAccountNumber
|
|
77
|
-
paymentSchedulingType
|
|
78
|
-
paymentThreshold
|
|
79
|
-
paymentDay
|
|
80
|
-
}
|
|
81
|
-
payoutsAccount {
|
|
82
|
-
hold
|
|
83
|
-
holdReasons
|
|
84
|
-
balance
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
}
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
}
|
|
91
|
-
`;
|
|
92
|
-
const GET_COUNTRIES = dist.gql `
|
|
93
|
-
query getCountries {
|
|
94
|
-
impactPayoutCountries(limit: 1000) {
|
|
95
|
-
data {
|
|
96
|
-
countryCode
|
|
97
|
-
displayName
|
|
98
|
-
}
|
|
99
|
-
}
|
|
100
|
-
}
|
|
101
|
-
`;
|
|
102
|
-
const GET_CURRENCIES = dist.gql `
|
|
103
|
-
query currencies($locale: RSLocale) {
|
|
104
|
-
currencies(limit: 300) {
|
|
105
|
-
data {
|
|
106
|
-
displayName(locale: $locale)
|
|
107
|
-
currencyCode
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
}
|
|
111
|
-
`;
|
|
112
|
-
const GET_FINANCE_NETWORK_SETTINGS = dist.gql `
|
|
113
|
-
query impactFinanceNetworkSettings(
|
|
114
|
-
$filter: ImpactFinanceNetworkSettingsFilterInput
|
|
115
|
-
) {
|
|
116
|
-
impactFinanceNetworkSettings(filter: $filter, limit: 1000) {
|
|
117
|
-
data {
|
|
118
|
-
countryCode
|
|
119
|
-
currency
|
|
120
|
-
defaultFinancePaymentMethodId
|
|
121
|
-
thresholdOptions
|
|
122
|
-
withdrawalSettingId
|
|
123
|
-
internationalEftFee
|
|
124
|
-
foreignFxFee
|
|
125
|
-
defaultFxFee
|
|
126
|
-
}
|
|
127
|
-
totalCount
|
|
128
|
-
}
|
|
129
|
-
}
|
|
130
|
-
`;
|
|
131
|
-
const FORM_STEPS = 4;
|
|
132
|
-
|
|
133
6
|
var toArray = function toArray(a) {
|
|
134
7
|
var ret = Array(a.length);
|
|
135
8
|
for (var i = 0; i < a.length; ++i) {
|
|
@@ -1127,7 +1000,7 @@ const GET_TAX_SETTING = dist.gql `
|
|
|
1127
1000
|
}
|
|
1128
1001
|
`;
|
|
1129
1002
|
function getStatus(data) {
|
|
1130
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q
|
|
1003
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
|
|
1131
1004
|
const account = (_b = (_a = data.user.impactConnection) === null || _a === void 0 ? void 0 : _a.publisher) === null || _b === void 0 ? void 0 : _b.payoutsAccount;
|
|
1132
1005
|
const hasTransferredReward = (_e = (_d = (_c = data === null || data === void 0 ? void 0 : data.user) === null || _c === void 0 ? void 0 : _c.rewards) === null || _d === void 0 ? void 0 : _d.data) === null || _e === void 0 ? void 0 : _e.find((reward) => reward.statuses.includes("REDEEMED") &&
|
|
1133
1006
|
reward.partnerFundsTransfer.status === "TRANSFERRED");
|
|
@@ -1145,19 +1018,7 @@ function getStatus(data) {
|
|
|
1145
1018
|
if ((_p = account.holdReasons) === null || _p === void 0 ? void 0 : _p.includes("IDV_CHECK_FAILED_INTERNAL"))
|
|
1146
1019
|
return "VERIFICATION:FAILED";
|
|
1147
1020
|
if (((_q = account.holdReasons) === null || _q === void 0 ? void 0 : _q.includes("NEW_PAYEE_REVIEW")) && hasTransferredReward)
|
|
1148
|
-
return "
|
|
1149
|
-
if ((_r = account.holdReasons) === null || _r === void 0 ? void 0 : _r.includes("PAYMENT_HOLD_ON_CHANGE"))
|
|
1150
|
-
return "PAYMENT_HOLD_ON_CHANGE";
|
|
1151
|
-
if ((_s = account.holdReasons) === null || _s === void 0 ? void 0 : _s.includes("BENEFICIARY_NAME_INVALID"))
|
|
1152
|
-
return "BENEFICIARY_NAME_INVALID";
|
|
1153
|
-
if ((_t = account.holdReasons) === null || _t === void 0 ? void 0 : _t.includes("BENEFICIARY_NAME_MISMATCH"))
|
|
1154
|
-
return "BENEFICIARY_NAME_MISMATCH";
|
|
1155
|
-
if ((_u = account.holdReasons) === null || _u === void 0 ? void 0 : _u.includes("BANK_TAX_NAME_MISMATCH"))
|
|
1156
|
-
return "BANK_TAX_NAME_MISMATCH";
|
|
1157
|
-
if ((_v = account.holdReasons) === null || _v === void 0 ? void 0 : _v.includes("WITHDRAWAL_SETTINGS_INVALID"))
|
|
1158
|
-
return "WITHDRAWAL_SETTINGS_INVALID";
|
|
1159
|
-
if ((_w = account.holdReasons) === null || _w === void 0 ? void 0 : _w.includes("PAYMENT_RETURNED"))
|
|
1160
|
-
return "PAYMENT_RETURNED";
|
|
1021
|
+
return "ACCOUNT_REVIEW";
|
|
1161
1022
|
if (account.hold)
|
|
1162
1023
|
return "HOLD";
|
|
1163
1024
|
return "DONE";
|
|
@@ -1169,8 +1030,6 @@ function usePayoutStatus(props) {
|
|
|
1169
1030
|
const { data: taxSettingRes } = wn(GET_TAX_SETTING, {});
|
|
1170
1031
|
const { render, loading: veriffLoading, errors: veriffErrors, } = useVeriffApp();
|
|
1171
1032
|
const [status, setStatus] = useState(undefined);
|
|
1172
|
-
const setContext = En(TAX_FORM_CONTEXT_NAMESPACE);
|
|
1173
|
-
const setStep = En(TAX_CONTEXT_NAMESPACE);
|
|
1174
1033
|
const enforceUsTaxComplianceOption = (_a = taxSettingRes === null || taxSettingRes === void 0 ? void 0 : taxSettingRes.tenantSettings) === null || _a === void 0 ? void 0 : _a.enforceUsTaxCompliance;
|
|
1175
1034
|
useEffect(() => {
|
|
1176
1035
|
if (!data)
|
|
@@ -1198,14 +1057,6 @@ function usePayoutStatus(props) {
|
|
|
1198
1057
|
url += "#3";
|
|
1199
1058
|
window.history.pushState(null, "", url);
|
|
1200
1059
|
};
|
|
1201
|
-
const onPaymentInfoClick = () => {
|
|
1202
|
-
setContext({
|
|
1203
|
-
overrideNextStep: "/dashboard",
|
|
1204
|
-
overrideBackStep: "/dashboard",
|
|
1205
|
-
hideSteps: true,
|
|
1206
|
-
});
|
|
1207
|
-
setStep("/4");
|
|
1208
|
-
};
|
|
1209
1060
|
return {
|
|
1210
1061
|
states: {
|
|
1211
1062
|
loading,
|
|
@@ -1219,9 +1070,8 @@ function usePayoutStatus(props) {
|
|
|
1219
1070
|
callbacks: {
|
|
1220
1071
|
onTermsClick,
|
|
1221
1072
|
onClick: render,
|
|
1222
|
-
onPaymentInfoClick,
|
|
1223
1073
|
},
|
|
1224
1074
|
};
|
|
1225
1075
|
}
|
|
1226
1076
|
|
|
1227
|
-
export {
|
|
1077
|
+
export { TAX_FORM_UPDATED_EVENT_KEY as T, VERIFF_COMPLETE_EVENT_KEY as V, useVeriffApp as a, getStatus as g, usePayoutStatus as u };
|