@saasquatch/mint-components 1.16.0-2 → 1.16.0-21
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/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 +107 -29
- package/dist/cjs/sqm-big-stat_43.cjs.entry.js +50 -4
- package/dist/cjs/sqm-qr-code.cjs.entry.js +1 -13
- package/dist/cjs/sqm-referral-table_11.cjs.entry.js +2 -2
- package/dist/cjs/sqm-rewards-table_9.cjs.entry.js +1 -1
- package/dist/cjs/sqm-stencilbook.cjs.entry.js +2 -2
- package/dist/cjs/{usePayoutStatus-c84a7d98.js → usePayoutStatus-d459ddde.js} +32 -11
- package/dist/collection/components/sqm-name-fields/sqm-name-fields.js +1 -1
- package/dist/collection/components/sqm-qr-code/useQRCode.js +1 -13
- package/dist/collection/components/sqm-referral-table/cells/sqm-referral-table-rewards-cell.js +2 -2
- package/dist/collection/components/sqm-referral-table/columns/sqm-referral-table-rewards-column.js +3 -3
- package/dist/collection/components/sqm-referral-table/sqm-referral-table.js +1 -1
- package/dist/collection/components/sqm-rewards-table/columns/sqm-rewards-table-source-column.js +1 -1
- package/dist/collection/components/sqm-rewards-table/columns/sqm-rewards-table-status-column.js +3 -3
- package/dist/collection/components/sqm-rewards-table/sqm-rewards-table.js +1 -1
- package/dist/collection/components/tax-and-cash/sqm-banking-info-form/useBankingInfoForm.js +4 -0
- package/dist/collection/components/tax-and-cash/sqm-docusign-form/sqm-docusign-form.js +2 -2
- package/dist/collection/components/tax-and-cash/sqm-indirect-tax-form/useIndirectTaxForm.js +4 -0
- package/dist/collection/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert-view.js +41 -3
- package/dist/collection/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert.js +51 -1
- package/dist/collection/components/tax-and-cash/sqm-payout-status-alert/usePayoutStatus.js +32 -11
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash/sqm-tax-and-cash.js +81 -2
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard-view.js +48 -12
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard.js +76 -27
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash-dashboard/useTaxAndCashDashboard.js +22 -11
- package/dist/collection/components/tax-and-cash/sqm-user-info-form/useUserInfoForm.js +4 -0
- 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 +108 -30
- package/dist/esm/sqm-big-stat_43.entry.js +50 -4
- package/dist/esm/sqm-qr-code.entry.js +1 -13
- package/dist/esm/sqm-referral-table_11.entry.js +2 -2
- package/dist/esm/sqm-rewards-table_9.entry.js +1 -1
- package/dist/esm/sqm-stencilbook.entry.js +2 -2
- package/dist/esm/{usePayoutStatus-f07bcf90.js → usePayoutStatus-4a7625b9.js} +32 -11
- 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-big-stat_43.entry.js +1 -1
- package/dist/esm-es5/sqm-qr-code.entry.js +1 -1
- package/dist/esm-es5/sqm-referral-table_11.entry.js +1 -1
- package/dist/esm-es5/sqm-rewards-table_9.entry.js +1 -1
- package/dist/esm-es5/sqm-stencilbook.entry.js +1 -1
- package/dist/esm-es5/{usePayoutStatus-f07bcf90.js → usePayoutStatus-4a7625b9.js} +2 -2
- package/dist/mint-components/mint-components.esm.js +1 -1
- package/dist/mint-components/p-0309fdfa.entry.js +1 -0
- package/dist/mint-components/{p-9a176cdf.entry.js → p-05389a8e.entry.js} +7 -7
- package/dist/mint-components/{p-c46a0007.entry.js → p-1a838f4d.entry.js} +1 -1
- package/dist/mint-components/{p-eff2e68b.entry.js → p-267c8f8c.entry.js} +2 -2
- package/dist/mint-components/p-2bf6eef0.entry.js +211 -0
- package/dist/mint-components/p-37996351.system.js +1 -1
- package/dist/mint-components/{p-776733b5.system.entry.js → p-37a4452c.system.entry.js} +1 -1
- package/dist/mint-components/{p-6bb25c02.js → p-3b2f1211.js} +9 -3
- package/dist/mint-components/p-4b29afb2.system.entry.js +1 -0
- package/dist/mint-components/p-8b584c46.system.entry.js +1 -0
- package/dist/mint-components/p-986d4c17.system.entry.js +1 -0
- package/dist/mint-components/{p-0c9debc1.system.js → p-9f22f58a.system.js} +2 -2
- package/dist/mint-components/p-a12f854d.system.entry.js +1 -0
- package/dist/mint-components/{p-0e864c3c.system.entry.js → p-beba8f57.system.entry.js} +1 -1
- package/dist/mint-components/p-c9b08184.entry.js +17 -0
- package/dist/types/components/sqm-name-fields/sqm-name-fields.d.ts +1 -1
- package/dist/types/components/sqm-referral-table/columns/sqm-referral-table-rewards-column.d.ts +1 -1
- package/dist/types/components/sqm-referral-table/sqm-referral-table.d.ts +1 -1
- package/dist/types/components/sqm-rewards-table/columns/sqm-rewards-table-source-column.d.ts +1 -1
- package/dist/types/components/sqm-rewards-table/columns/sqm-rewards-table-status-column.d.ts +1 -1
- package/dist/types/components/sqm-rewards-table/sqm-rewards-table.d.ts +1 -1
- package/dist/types/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert-view.d.ts +4 -1
- package/dist/types/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert.d.ts +8 -0
- package/dist/types/components/tax-and-cash/sqm-payout-status-alert/usePayoutStatus.d.ts +8 -1
- package/dist/types/components/tax-and-cash/sqm-tax-and-cash/sqm-tax-and-cash.d.ts +13 -0
- package/dist/types/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard-view.d.ts +4 -1
- package/dist/types/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard.d.ts +12 -5
- package/dist/types/components.d.ts +66 -10
- 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/mint-components/p-0c78815e.system.entry.js +0 -1
- package/dist/mint-components/p-1c67bf1c.system.entry.js +0 -1
- package/dist/mint-components/p-43b4bb99.entry.js +0 -1
- package/dist/mint-components/p-47bd2d7a.entry.js +0 -205
- package/dist/mint-components/p-53730ffe.entry.js +0 -17
- package/dist/mint-components/p-6f65f9e1.system.entry.js +0 -1
- package/dist/mint-components/p-ef75f3a9.system.entry.js +0 -1
- package/dist/types/global/android.d.ts +0 -7
- package/dist/types/global/demo.d.ts +0 -2
- package/dist/types/stories/features.d.ts +0 -4
- package/dist/types/stories/templates.d.ts +0 -4
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { h, r as registerInstance, c as Host, g as getElement } from './index-91e7729f.js';
|
|
2
2
|
import { m as useRef, k as useState, f as useEffect, n as h$1, l, u as useMemo, b as browser, j as useReducer } from './stencil-hooks.module-4bc38af4.js';
|
|
3
3
|
import { i as intl } from './global-be1f9992.js';
|
|
4
|
-
import { d as dist, _, L, J, t as Pn, F as Fn, x as $n, $ as $e, i as isDemo, q as En, u as useCallback, R as Rn, M as Mn, I as In, S as Sn } from './index.module-89a79f66.js';
|
|
4
|
+
import { d as dist, _, L, J, t as Pn, F as Fn, x as $n, $ as $e, i as isDemo, q as En, u as useCallback, R as Rn, M as Mn, I as In, S as Sn, w as wn } from './index.module-89a79f66.js';
|
|
5
5
|
import { j as jsonpointer } from './jsonpointer-388a7082.js';
|
|
6
6
|
import { c as cjs } from './cjs-bdfb4486.js';
|
|
7
7
|
import { g as getProps, l as luxonLocale } from './utils-334c1e34.js';
|
|
@@ -17,7 +17,7 @@ import { E as ErrorView } from './ErrorView-48e2b969.js';
|
|
|
17
17
|
import { t as taxTypeToName, v as validTaxDocument, a as INDIRECT_TAX_SPAIN_REGIONS, b as INDIRECT_TAX_PROVINCES, g as getCountryObj, O as OtherRegionSlotView, I as InvoiceTableView, L as LoadingView, c as vatLabels, G as GeneralLoadingView, f as formatErrorMessage, d as validateBillingField, o as objectIsFull, A as ADDRESS_REGIONS } from './sqm-invoice-table-view-3491dd80.js';
|
|
18
18
|
import { e as extractProps } from './extractProps-ae1afbb3.js';
|
|
19
19
|
import { b as VERIFICATION_EVENT_KEY, V as VERIFICATION_EMAIL_NAMESPACE, S as SHOW_CODE_NAMESPACE, a as VERIFICATION_PARENT_NAMESPACE } from './keys-406491dc.js';
|
|
20
|
-
import { T as TAX_FORM_UPDATED_EVENT_KEY, a as useVeriffApp, g as getStatus, V as VERIFF_COMPLETE_EVENT_KEY } from './usePayoutStatus-
|
|
20
|
+
import { T as TAX_FORM_UPDATED_EVENT_KEY, a as useVeriffApp, g as getStatus, V as VERIFF_COMPLETE_EVENT_KEY } from './usePayoutStatus-4a7625b9.js';
|
|
21
21
|
import { u as useVerificationEmail } from './useVerificationEmail-edc318cb.js';
|
|
22
22
|
|
|
23
23
|
const TAX_CONTEXT_NAMESPACE = "sq:tax-and-cash";
|
|
@@ -1070,6 +1070,10 @@ function useBankingInfoForm(props) {
|
|
|
1070
1070
|
const paymentMethodChecked = !hasPayPal
|
|
1071
1071
|
? "toBankAccount"
|
|
1072
1072
|
: _paymentMethodChecked;
|
|
1073
|
+
useEffect(() => {
|
|
1074
|
+
// reset redirect hash
|
|
1075
|
+
window.location.hash = "";
|
|
1076
|
+
}, []);
|
|
1073
1077
|
useEffect(() => {
|
|
1074
1078
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
1075
1079
|
if (!userData)
|
|
@@ -2681,7 +2685,7 @@ const DocusignForm = class {
|
|
|
2681
2685
|
* @uiName W-8 BEN-E tax form description
|
|
2682
2686
|
* @uiWidget textArea
|
|
2683
2687
|
*/
|
|
2684
|
-
this.taxFormDescriptionBusinessEntity = "Participants residing outside of the US
|
|
2688
|
+
this.taxFormDescriptionBusinessEntity = "Participants residing outside of the US working with a US Brand need to submit a {documentType} form.";
|
|
2685
2689
|
/**
|
|
2686
2690
|
* This appears inside the Docusign frame.
|
|
2687
2691
|
* @uiName Docusign session expired messag
|
|
@@ -3110,6 +3114,10 @@ function useIndirectTaxForm(props) {
|
|
|
3110
3114
|
const [filteredCountries, setFilteredCountries] = useState(_countries || []);
|
|
3111
3115
|
const [option, setOption] = useState("notRegistered");
|
|
3112
3116
|
const publisher = (_c = (_b = userData === null || userData === void 0 ? void 0 : userData.user) === null || _b === void 0 ? void 0 : _b.impactConnection) === null || _c === void 0 ? void 0 : _c.publisher;
|
|
3117
|
+
useEffect(() => {
|
|
3118
|
+
// reset redirect hash
|
|
3119
|
+
window.location.hash = "";
|
|
3120
|
+
}, []);
|
|
3113
3121
|
useEffect(() => {
|
|
3114
3122
|
var _a;
|
|
3115
3123
|
if (!((_a = publisher === null || publisher === void 0 ? void 0 : publisher.taxInformation) === null || _a === void 0 ? void 0 : _a.indirectTaxCountryCode))
|
|
@@ -4744,7 +4752,7 @@ const TaxAndCashMonolith = class {
|
|
|
4744
4752
|
* @uiGroup Step 3 Properties
|
|
4745
4753
|
* @uiWidget textArea
|
|
4746
4754
|
*/
|
|
4747
|
-
this.step3_taxFormDescriptionBusinessEntity = "Participants residing outside of the US
|
|
4755
|
+
this.step3_taxFormDescriptionBusinessEntity = "Participants residing outside of the US working with a US Brand need to submit a {documentType} form.";
|
|
4748
4756
|
/**
|
|
4749
4757
|
* This appears inside the Docusign frame.
|
|
4750
4758
|
* @uiName Docusign session expired message
|
|
@@ -5403,6 +5411,19 @@ const TaxAndCashMonolith = class {
|
|
|
5403
5411
|
* @uiWidget textArea
|
|
5404
5412
|
*/
|
|
5405
5413
|
this.dashboard_w9RequiredDescription = "You have surpassed the $600 threshold for a W9 tax form. To remove the hold, you need to submit a W9 tax form as outlined in our {termsAndConditions}. Please click 'Submit W9' to start the process.";
|
|
5414
|
+
/**
|
|
5415
|
+
* @uiName Account review alert header
|
|
5416
|
+
*/
|
|
5417
|
+
this.dashboard_accountReviewHeader = "Your account is under review";
|
|
5418
|
+
/**
|
|
5419
|
+
* @uiName Account review alert description
|
|
5420
|
+
*/
|
|
5421
|
+
this.dashboard_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}.";
|
|
5422
|
+
/**
|
|
5423
|
+
* @uiName Terms and Conditions text
|
|
5424
|
+
* @uiGroup Dashboard Properties
|
|
5425
|
+
*/
|
|
5426
|
+
this.dashboard_termsAndConditions = "Terms and Conditions";
|
|
5406
5427
|
/**
|
|
5407
5428
|
* @uiName W9 payment threshold alert button text
|
|
5408
5429
|
* @uiGroup Dashboard Properties
|
|
@@ -5781,14 +5802,36 @@ const TaxAndCashDashboardView = (props) => {
|
|
|
5781
5802
|
function getAlert(status) {
|
|
5782
5803
|
switch (status) {
|
|
5783
5804
|
case "OVER_W9_THRESHOLD":
|
|
5784
|
-
|
|
5785
|
-
|
|
5786
|
-
|
|
5787
|
-
|
|
5788
|
-
|
|
5789
|
-
|
|
5790
|
-
|
|
5791
|
-
|
|
5805
|
+
if (states.enforceUsTaxComplianceOption === "CASH_ONLY_DEFER_W9") {
|
|
5806
|
+
return {
|
|
5807
|
+
header: text.w9RequiredHeader,
|
|
5808
|
+
description: intl.formatMessage({
|
|
5809
|
+
id: "w9RequiredDescription",
|
|
5810
|
+
defaultMessage: text.w9RequiredDescription,
|
|
5811
|
+
}, {
|
|
5812
|
+
termsAndConditions: (h("a", { target: "_blank", href: `https://terms.advocate.impact.com/PayoutTermsAndConditions.html` }, text.termsAndConditions)),
|
|
5813
|
+
}),
|
|
5814
|
+
button: (h("sl-button", { style: { marginTop: "var(--sl-spacing-x-small)" }, type: "default", onClick: callbacks.onNewFormClick }, text.w9RequiredButtonText)),
|
|
5815
|
+
alertType: "info",
|
|
5816
|
+
icon: "info-circle",
|
|
5817
|
+
class: sheet$5.classes.WarningHoldAlertContainer,
|
|
5818
|
+
};
|
|
5819
|
+
}
|
|
5820
|
+
else {
|
|
5821
|
+
return {
|
|
5822
|
+
header: text.payoutHoldAlertHeader,
|
|
5823
|
+
description: intl.formatMessage({
|
|
5824
|
+
id: "payoutHoldAlertDescription",
|
|
5825
|
+
defaultMessage: text.payoutHoldAlertDescription,
|
|
5826
|
+
}, {
|
|
5827
|
+
supportLink: (h("a", { target: "_blank", href: `mailto:advocate-support@impact.com` }, text.supportLink)),
|
|
5828
|
+
}),
|
|
5829
|
+
buttonText: null,
|
|
5830
|
+
alertType: "warning",
|
|
5831
|
+
icon: "exclamation-triangle",
|
|
5832
|
+
class: sheet$5.classes.WarningHoldAlertContainer,
|
|
5833
|
+
};
|
|
5834
|
+
}
|
|
5792
5835
|
case "VERIFICATION:REQUIRED":
|
|
5793
5836
|
return {
|
|
5794
5837
|
header: text.verificationRequiredHeader,
|
|
@@ -5842,6 +5885,20 @@ const TaxAndCashDashboardView = (props) => {
|
|
|
5842
5885
|
icon: "exclamation-octagon",
|
|
5843
5886
|
class: sheet$5.classes.ErrorHoldAlertContainer,
|
|
5844
5887
|
};
|
|
5888
|
+
case "ACCOUNT_REVIEW":
|
|
5889
|
+
return {
|
|
5890
|
+
header: text.accountReviewHeader,
|
|
5891
|
+
description: intl.formatMessage({
|
|
5892
|
+
id: "accountReviewDescription",
|
|
5893
|
+
defaultMessage: text.accountReviewDescription,
|
|
5894
|
+
}, {
|
|
5895
|
+
supportLink: (h("a", { target: "_blank", href: `mailto:advocate-support@impact.com` }, text.supportLink)),
|
|
5896
|
+
}),
|
|
5897
|
+
buttonText: null,
|
|
5898
|
+
alertType: "warning",
|
|
5899
|
+
icon: "exclamation-triangle",
|
|
5900
|
+
class: sheet$5.classes.WarningHoldAlertContainer,
|
|
5901
|
+
};
|
|
5845
5902
|
case "HOLD":
|
|
5846
5903
|
return {
|
|
5847
5904
|
header: text.payoutHoldAlertHeader,
|
|
@@ -5978,12 +6035,11 @@ const TaxAndCashDashboardView = (props) => {
|
|
|
5978
6035
|
states.status === "INACTIVE" && alertMap[states.status],
|
|
5979
6036
|
h("div", null,
|
|
5980
6037
|
h("h3", { style: { marginBottom: "0" } }, text.bankingInformationSectionHeader),
|
|
5981
|
-
h("p", { class: sheet$5.classes.PageDescriptionText }, text.taxAndPayoutsDescription),
|
|
5982
6038
|
h("div", { class: sheet$5.classes.BankingInformationContainer },
|
|
5983
6039
|
slots.payoutDetailsCardSlot,
|
|
5984
6040
|
!states.loading && (h("p", { class: sheet$5.classes.DescriptionText }, text.payoutFromImpact)),
|
|
5985
6041
|
states.canEditPayoutInfo && (h("sl-button", { disabled: states.disabled || states.loading, type: "default", class: sheet$5.classes.EditBankDetailsButton, onClick: callbacks.onEditPayoutInfo }, text.editPaymentInformationButton)))),
|
|
5986
|
-
!states.noFormNeeded && (h("div", { class: sheet$5.classes.TaxDocumentsContainer },
|
|
6042
|
+
(!states.noFormNeeded || states.status === "NOT_VERIFIED") && (h("div", { class: sheet$5.classes.TaxDocumentsContainer },
|
|
5987
6043
|
h("div", null, states.loading ? (h("div", { class: sheet$5.classes.TaxSectionSkeletonContainer },
|
|
5988
6044
|
h("sl-skeleton", { class: sheet$5.classes.SkeletonOne }),
|
|
5989
6045
|
h("sl-skeleton", { class: sheet$5.classes.SkeletonTwo }))) : (h("div", null,
|
|
@@ -5994,10 +6050,11 @@ const TaxAndCashDashboardView = (props) => {
|
|
|
5994
6050
|
id: "section-subheader",
|
|
5995
6051
|
defaultMessage: text.taxDocumentSectionSubHeader,
|
|
5996
6052
|
}, {
|
|
5997
|
-
documentType: states.documentTypeString,
|
|
6053
|
+
documentType: states.documentTypeString || "W9",
|
|
5998
6054
|
})),
|
|
5999
6055
|
h("span", { class: sheet$5.classes.StatusAlert }, statusMap[states.status]))),
|
|
6000
|
-
states.
|
|
6056
|
+
states.noFormNeeded &&
|
|
6057
|
+
states.status !== "NOT_VERIFIED" && (h("sl-button", { disabled: states.disabled || states.loading, onClick: callbacks.onClick, type: "default", class: sheet$5.classes.NewFormButton, exportparts: "base: primarybutton-base" }, text.newFormButton)))))))),
|
|
6001
6058
|
h("div", { class: sheet$5.classes.IndirectTaxPreviewContainer }, states.loading ? (h("div", { class: sheet$5.classes.TaxSectionSkeletonContainer },
|
|
6002
6059
|
h("sl-skeleton", { class: sheet$5.classes.SkeletonOne }),
|
|
6003
6060
|
h("sl-skeleton", { class: sheet$5.classes.SkeletonTwo }))) : (h("div", null,
|
|
@@ -6045,6 +6102,13 @@ const TaxAndCashDashboardView = (props) => {
|
|
|
6045
6102
|
h("sqm-invoice-table-data-column", { "column-title": text.earningsAfterTaxColumnTitle, property: "netEarnings" })))))))))));
|
|
6046
6103
|
};
|
|
6047
6104
|
|
|
6105
|
+
const GET_TAX_SETTING = dist.gql `
|
|
6106
|
+
query getTenantSettings {
|
|
6107
|
+
tenantSettings {
|
|
6108
|
+
enforceUsTaxCompliance
|
|
6109
|
+
}
|
|
6110
|
+
}
|
|
6111
|
+
`;
|
|
6048
6112
|
function getCountryName(countryCode, locale) {
|
|
6049
6113
|
if (!countryCode)
|
|
6050
6114
|
return undefined;
|
|
@@ -6080,11 +6144,12 @@ function getIndirectTaxType(taxInformation) {
|
|
|
6080
6144
|
return "Indirect Tax";
|
|
6081
6145
|
}
|
|
6082
6146
|
const useTaxAndCashDashboard = (props) => {
|
|
6083
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
|
|
6147
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
|
|
6084
6148
|
const setStep = En(TAX_CONTEXT_NAMESPACE);
|
|
6085
6149
|
const setContext = En(TAX_FORM_CONTEXT_NAMESPACE);
|
|
6086
6150
|
const [showDialog, setShowDialog] = useState(false);
|
|
6087
6151
|
const { render, loading: veriffLoading, errors: veriffErrors, } = useVeriffApp();
|
|
6152
|
+
const { data: taxSettingRes } = wn(GET_TAX_SETTING, {});
|
|
6088
6153
|
const locale = L();
|
|
6089
6154
|
useEffect(() => {
|
|
6090
6155
|
// Clear override context once on submitted
|
|
@@ -6125,30 +6190,32 @@ const useTaxAndCashDashboard = (props) => {
|
|
|
6125
6190
|
window.removeEventListener(VERIFF_COMPLETE_EVENT_KEY, cb);
|
|
6126
6191
|
};
|
|
6127
6192
|
}, []);
|
|
6193
|
+
const enforceUsTaxComplianceOption = (_e = taxSettingRes === null || taxSettingRes === void 0 ? void 0 : taxSettingRes.tenantSettings) === null || _e === void 0 ? void 0 : _e.enforceUsTaxCompliance;
|
|
6128
6194
|
return {
|
|
6129
6195
|
states: {
|
|
6130
6196
|
dateSubmitted,
|
|
6131
6197
|
documentType,
|
|
6132
6198
|
canEditPayoutInfo: publisher === null || publisher === void 0 ? void 0 : publisher.brandedSignup,
|
|
6133
6199
|
documentTypeString: taxTypeToName(documentType),
|
|
6134
|
-
status: (
|
|
6135
|
-
subRegion: getSubRegionName((
|
|
6136
|
-
subRegionTaxNumber: (
|
|
6137
|
-
qstNumber: (
|
|
6200
|
+
status: (_f = publisher === null || publisher === void 0 ? void 0 : publisher.currentTaxDocument) === null || _f === void 0 ? void 0 : _f.status,
|
|
6201
|
+
subRegion: getSubRegionName((_g = publisher === null || publisher === void 0 ? void 0 : publisher.taxInformation) === null || _g === void 0 ? void 0 : _g.indirectTaxRegion),
|
|
6202
|
+
subRegionTaxNumber: (_h = publisher === null || publisher === void 0 ? void 0 : publisher.taxInformation) === null || _h === void 0 ? void 0 : _h.withholdingTaxId,
|
|
6203
|
+
qstNumber: (_j = publisher === null || publisher === void 0 ? void 0 : publisher.taxInformation) === null || _j === void 0 ? void 0 : _j.additionalTaxId,
|
|
6138
6204
|
indirectTaxType: getIndirectTaxType(publisher === null || publisher === void 0 ? void 0 : publisher.taxInformation),
|
|
6139
|
-
indirectTaxNumber: (
|
|
6205
|
+
indirectTaxNumber: (_k = publisher === null || publisher === void 0 ? void 0 : publisher.taxInformation) === null || _k === void 0 ? void 0 : _k.indirectTaxId,
|
|
6140
6206
|
isBusinessEntity: (publisher === null || publisher === void 0 ? void 0 : publisher.requiredTaxDocumentType) === "W8BENE",
|
|
6141
6207
|
province: provinceName,
|
|
6142
|
-
country: getCountryName((
|
|
6143
|
-
notRegistered: !((
|
|
6208
|
+
country: getCountryName((_l = publisher === null || publisher === void 0 ? void 0 : publisher.taxInformation) === null || _l === void 0 ? void 0 : _l.indirectTaxCountryCode, locale),
|
|
6209
|
+
notRegistered: !((_m = publisher === null || publisher === void 0 ? void 0 : publisher.taxInformation) === null || _m === void 0 ? void 0 : _m.indirectTaxId),
|
|
6144
6210
|
noFormNeeded: !documentType,
|
|
6145
6211
|
disabled: loading,
|
|
6146
6212
|
loading,
|
|
6147
6213
|
loadingError: !!(userError === null || userError === void 0 ? void 0 : userError.message),
|
|
6148
6214
|
showNewFormDialog: showDialog,
|
|
6149
|
-
hasHold: !!((
|
|
6215
|
+
hasHold: !!((_o = publisher === null || publisher === void 0 ? void 0 : publisher.payoutsAccount) === null || _o === void 0 ? void 0 : _o.hold),
|
|
6150
6216
|
payoutStatus,
|
|
6151
6217
|
veriffLoading,
|
|
6218
|
+
enforceUsTaxComplianceOption,
|
|
6152
6219
|
},
|
|
6153
6220
|
callbacks: {
|
|
6154
6221
|
onClick: () => setShowDialog(true),
|
|
@@ -6393,6 +6460,18 @@ const TaxAndCashDashboard = class {
|
|
|
6393
6460
|
* @uiName W9 payment threshold alert description
|
|
6394
6461
|
*/
|
|
6395
6462
|
this.w9RequiredDescription = "You have surpassed the $600 threshold for a W9 tax form. To remove the hold, you need to submit a W9 tax form as outlined in our {termsAndConditions}. Please click 'Submit W9' to start the process.";
|
|
6463
|
+
/**
|
|
6464
|
+
* @uiName Account review alert header
|
|
6465
|
+
*/
|
|
6466
|
+
this.accountReviewHeader = "Your account is under review";
|
|
6467
|
+
/**
|
|
6468
|
+
* @uiName Account review alert description
|
|
6469
|
+
*/
|
|
6470
|
+
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}.";
|
|
6471
|
+
/**
|
|
6472
|
+
* @uiName Terms and Conditions text
|
|
6473
|
+
*/
|
|
6474
|
+
this.termsAndConditions = "Terms and Conditions";
|
|
6396
6475
|
/**
|
|
6397
6476
|
* @uiName W9 payment threshold alert button text
|
|
6398
6477
|
*/
|
|
@@ -6464,11 +6543,6 @@ const TaxAndCashDashboard = class {
|
|
|
6464
6543
|
this.invoiceEmptyStateHeader = "View your invoice details";
|
|
6465
6544
|
/** @uiName Empty invoice table description */
|
|
6466
6545
|
this.invoiceEmptyStateText = "Refer a friend to view the status of your invoices and rewards earned";
|
|
6467
|
-
/**
|
|
6468
|
-
* Displayed at the top of the page on all set up steps and on the dashboard.
|
|
6469
|
-
* @uiName Page description
|
|
6470
|
-
*/
|
|
6471
|
-
this.taxAndPayoutsDescription = "Submit your tax documents and add your banking information to receive your rewards.";
|
|
6472
6546
|
/**
|
|
6473
6547
|
* @uiName Replace tax form modal header
|
|
6474
6548
|
*/
|
|
@@ -7836,6 +7910,10 @@ function useUserInfoForm(props) {
|
|
|
7836
7910
|
const [currencySearch, setCurrencySearch] = useState("");
|
|
7837
7911
|
const [filteredCurrencies, setFilteredCurrencies] = useState(currencies || []);
|
|
7838
7912
|
const [formErrors, setErrors] = useState({});
|
|
7913
|
+
useEffect(() => {
|
|
7914
|
+
// reset redirect hash
|
|
7915
|
+
window.location.hash = "";
|
|
7916
|
+
}, []);
|
|
7839
7917
|
useEffect(() => {
|
|
7840
7918
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
7841
7919
|
const user = data === null || data === void 0 ? void 0 : data.user;
|
|
@@ -22,7 +22,7 @@ import { A as AsYouType } from './AsYouType-46f67d0d.js';
|
|
|
22
22
|
import { i as isEmpty } from './utilities-5b0ca040.js';
|
|
23
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-f2176779.js';
|
|
24
24
|
import './sqm-portal-container-view-1683ae32.js';
|
|
25
|
-
import { u as usePayoutStatus } from './usePayoutStatus-
|
|
25
|
+
import { u as usePayoutStatus } from './usePayoutStatus-4a7625b9.js';
|
|
26
26
|
|
|
27
27
|
const BigStat = class {
|
|
28
28
|
constructor(hostRef) {
|
|
@@ -2360,10 +2360,46 @@ function PayoutStatusAlertView(props) {
|
|
|
2360
2360
|
class: sheet$2.classes.ErrorAlertContainer,
|
|
2361
2361
|
};
|
|
2362
2362
|
case "OVER_W9_THRESHOLD":
|
|
2363
|
+
if (states.enforceUsTaxComplianceOption === "CASH_ONLY_DEFER_W9") {
|
|
2364
|
+
return {
|
|
2365
|
+
header: text.w9RequiredHeader,
|
|
2366
|
+
description: intl.formatMessage({
|
|
2367
|
+
id: "w9RequiredDescription",
|
|
2368
|
+
defaultMessage: text.w9RequiredDescription,
|
|
2369
|
+
}, {
|
|
2370
|
+
termsAndConditions: (h$1("a", { target: "_blank", href: `https://terms.advocate.impact.com/PayoutTermsAndConditions.html` }, text.termsAndConditions)),
|
|
2371
|
+
}),
|
|
2372
|
+
buttonText: text.w9RequiredButtonText,
|
|
2373
|
+
alertType: "warning",
|
|
2374
|
+
icon: "exclamation-triangle",
|
|
2375
|
+
class: sheet$2.classes.WarningAlertContainer,
|
|
2376
|
+
};
|
|
2377
|
+
}
|
|
2378
|
+
else {
|
|
2379
|
+
return {
|
|
2380
|
+
header: text.holdHeader,
|
|
2381
|
+
description: intl.formatMessage({
|
|
2382
|
+
id: "holdDescription",
|
|
2383
|
+
defaultMessage: text.holdDescription,
|
|
2384
|
+
}, {
|
|
2385
|
+
supportLink: (h$1("a", { target: "_blank", href: `mailto:advocate-support@impact.com` }, text.supportLink)),
|
|
2386
|
+
}),
|
|
2387
|
+
buttonText: null,
|
|
2388
|
+
alertType: "warning",
|
|
2389
|
+
icon: "exclamation-triangle",
|
|
2390
|
+
class: sheet$2.classes.WarningAlertContainer,
|
|
2391
|
+
};
|
|
2392
|
+
}
|
|
2393
|
+
case "ACCOUNT_REVIEW":
|
|
2363
2394
|
return {
|
|
2364
|
-
header: text.
|
|
2365
|
-
description: intl.formatMessage({
|
|
2366
|
-
|
|
2395
|
+
header: text.accountReviewHeader,
|
|
2396
|
+
description: intl.formatMessage({
|
|
2397
|
+
id: "accountReviewDescription",
|
|
2398
|
+
defaultMessage: text.accountReviewDescription,
|
|
2399
|
+
}, {
|
|
2400
|
+
supportLink: (h$1("a", { target: "_blank", href: `mailto:advocate-support@impact.com` }, text.supportLink)),
|
|
2401
|
+
}),
|
|
2402
|
+
buttonText: null,
|
|
2367
2403
|
alertType: "warning",
|
|
2368
2404
|
icon: "exclamation-triangle",
|
|
2369
2405
|
class: sheet$2.classes.WarningAlertContainer,
|
|
@@ -2389,6 +2425,8 @@ function PayoutStatusAlertView(props) {
|
|
|
2389
2425
|
function getButton(status) {
|
|
2390
2426
|
switch (status) {
|
|
2391
2427
|
case "OVER_W9_THRESHOLD":
|
|
2428
|
+
if (states.enforceUsTaxComplianceOption === "CASH_ONLY")
|
|
2429
|
+
return;
|
|
2392
2430
|
return data.type === "SquatchJS2" ? (h$1("sqm-scroll", { "scroll-tag-name": "sqm-tabs", "button-text": text.w9RequiredButtonText, "scroll-animation": "smooth" })) : data.type === "SquatchPortal" ? (h$1("sl-button", { type: "default", onClick: callbacks.onTermsClick }, text.w9RequiredButtonText)) : (
|
|
2393
2431
|
// Demo case
|
|
2394
2432
|
h$1("sl-button", { type: "default" }, text.w9RequiredButtonText));
|
|
@@ -2469,6 +2507,14 @@ const PayoutStatusAlert = class {
|
|
|
2469
2507
|
* @uiName Verification failed internal alert description
|
|
2470
2508
|
*/
|
|
2471
2509
|
this.verificationFailedInternalDescription = "Identity verification has failed. Our team is reviewing the report and will contact you with further information. If you don't hear from us contact our {supportLink}.";
|
|
2510
|
+
/**
|
|
2511
|
+
* @uiName Account review alert header
|
|
2512
|
+
*/
|
|
2513
|
+
this.accountReviewHeader = "Your account is under review";
|
|
2514
|
+
/**
|
|
2515
|
+
* @uiName Account review alert description
|
|
2516
|
+
*/
|
|
2517
|
+
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}.";
|
|
2472
2518
|
/**
|
|
2473
2519
|
* @uiName W9 payment threshold alert header
|
|
2474
2520
|
*/
|
|
@@ -44,19 +44,7 @@ function useQRCode(props) {
|
|
|
44
44
|
if (!shareLink)
|
|
45
45
|
return;
|
|
46
46
|
const getQrCode = async () => {
|
|
47
|
-
|
|
48
|
-
try {
|
|
49
|
-
const res = await fetch(`${shareLink}?qrCode&qrCodeImageFormat=svg&qrCodeQuietZoneSize=0`);
|
|
50
|
-
const blob = await res.blob();
|
|
51
|
-
const url = URL.createObjectURL(blob);
|
|
52
|
-
setQrUrl(url);
|
|
53
|
-
}
|
|
54
|
-
catch (e) {
|
|
55
|
-
setError(true);
|
|
56
|
-
}
|
|
57
|
-
finally {
|
|
58
|
-
setLoading(false);
|
|
59
|
-
}
|
|
47
|
+
setQrUrl(`${shareLink}?qrCode&qrCodeImageFormat=svg&qrCodeQuietZoneSize=0`);
|
|
60
48
|
};
|
|
61
49
|
getQrCode();
|
|
62
50
|
}, [shareLink]);
|
|
@@ -424,7 +424,7 @@ const ReferralTableRewardsCell = class {
|
|
|
424
424
|
constructor(hostRef) {
|
|
425
425
|
registerInstance(this, hostRef);
|
|
426
426
|
this.statusText = "{status, select, AVAILABLE {Available} CANCELLED {Cancelled} PENDING {Pending} PENDING_REVIEW {Pending} PAYOUT_APPROVED {Payout Approved} PAYOUT_FAILED {Payout Failed} PAYOUT_CANCELLED {Payout Cancelled} PENDING_TAX_REVIEW {Pending} PENDING_NEW_TAX_FORM {Pending} PENDING_TAX_SUBMISSION {Pending} PENDING_PARTNER_CREATION {Pending} DENIED {Denied} EXPIRED {Expired} REDEEMED {Redeemed} other {Not available} }";
|
|
427
|
-
this.statusLongText = "{status, select, AVAILABLE {Reward expiring on} CANCELLED {Reward cancelled on} PENDING {Available on} PENDING_REVIEW {Pending since} PAYOUT_APPROVED {Reward
|
|
427
|
+
this.statusLongText = "{status, select, AVAILABLE {Reward expiring on} CANCELLED {Reward cancelled on} PENDING {Available on} PENDING_REVIEW {Pending since} PAYOUT_APPROVED {Reward was scheduled for payment based on your settings, barring any account holds.} PAYOUT_FAILED {Payout failed due to a fulfillment issue and is currently being retried.} PAYOUT_CANCELLED {If you think this is a mistake, contact our Support team.} PENDING_TAX_REVIEW {Awaiting tax form review} PENDING_NEW_TAX_FORM {Invalid tax form. Submit a new form to receive your rewards.} PENDING_TAX_SUBMISSION {Submit your tax documents to receive your rewards} PENDING_PARTNER_CREATION {Complete your tax and cash payout setup to receive your rewards} DENIED {Denied on} EXPIRED {Reward expired on} other {Not available} }";
|
|
428
428
|
this.locale = "en";
|
|
429
429
|
}
|
|
430
430
|
render() {
|
|
@@ -643,7 +643,7 @@ const ReferralTableRewardsColumn = class {
|
|
|
643
643
|
* @uiName Reward status long text
|
|
644
644
|
* @uiWidget textArea
|
|
645
645
|
*/
|
|
646
|
-
this.statusLongText = "{status, select, AVAILABLE {Reward expiring on} CANCELLED {Reward cancelled on} PENDING {Available on} PENDING_REVIEW {Pending since} PAYOUT_APPROVED {Reward
|
|
646
|
+
this.statusLongText = "{status, select, AVAILABLE {Reward expiring on} CANCELLED {Reward cancelled on} PENDING {Available on} PENDING_REVIEW {Pending since} PAYOUT_APPROVED {Reward was scheduled for payment based on your settings, barring any account holds.} PAYOUT_FAILED {Payout failed due to a fulfillment issue and is currently being retried.} PAYOUT_CANCELLED {If you think this is a mistake, contact our Support team.} PENDING_TAX_REVIEW {Awaiting tax form review} PENDING_NEW_TAX_FORM {Invalid tax form. Submit a new form to receive your rewards.} PENDING_TAX_SUBMISSION {Submit your tax documents to receive your rewards} PENDING_PARTNER_CREATION {Complete your tax and cash payout setup to receive your rewards} DENIED {Denied on} EXPIRED {Reward expired on} other {Not available} }";
|
|
647
647
|
/**
|
|
648
648
|
* Shown in the dropdown details when a reward has an associated fuel tank code.
|
|
649
649
|
*
|
|
@@ -1062,7 +1062,7 @@ const RewardTableStatusColumn = class {
|
|
|
1062
1062
|
*
|
|
1063
1063
|
* @uiName Payout approved text
|
|
1064
1064
|
*/
|
|
1065
|
-
this.payoutApproved = "Reward
|
|
1065
|
+
this.payoutApproved = "Reward was scheduled for payment based on your settings, barring any account holds.";
|
|
1066
1066
|
h$1(this);
|
|
1067
1067
|
}
|
|
1068
1068
|
disconnectedCallback() { }
|