@saasquatch/mint-components 1.16.0-10 → 1.16.0-12
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/sqm-banking-info-form_17.cjs.entry.js +1 -5
- package/dist/cjs/sqm-big-stat_43.cjs.entry.js +26 -9
- package/dist/cjs/{usePayoutStatus-c84a7d98.js → usePayoutStatus-79b5577f.js} +11 -0
- package/dist/collection/components/tax-and-cash/sqm-docusign-form/useDocusignForm.js +0 -4
- package/dist/collection/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert-view.js +25 -8
- package/dist/collection/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert.js +1 -1
- package/dist/collection/components/tax-and-cash/sqm-payout-status-alert/usePayoutStatus.js +11 -0
- package/dist/esm/sqm-banking-info-form_17.entry.js +1 -5
- package/dist/esm/sqm-big-stat_43.entry.js +26 -9
- package/dist/esm/{usePayoutStatus-f07bcf90.js → usePayoutStatus-6ae7fc44.js} +11 -0
- 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/{usePayoutStatus-f07bcf90.js → usePayoutStatus-6ae7fc44.js} +2 -2
- package/dist/mint-components/mint-components.esm.js +1 -1
- package/dist/mint-components/p-37996351.system.js +1 -1
- package/dist/mint-components/p-8ef0c090.system.entry.js +1 -0
- package/dist/mint-components/p-aa7a6a5c.system.entry.js +1 -0
- package/dist/mint-components/{p-6bb25c02.js → p-dbdef054.js} +9 -3
- package/dist/mint-components/{p-0c9debc1.system.js → p-dd883bbb.system.js} +2 -2
- package/dist/mint-components/{p-19d60c22.entry.js → p-e505f4bb.entry.js} +2 -2
- package/dist/mint-components/{p-d8ea88f9.entry.js → p-f772713f.entry.js} +7 -7
- package/dist/types/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert-view.d.ts +2 -1
- package/dist/types/components/tax-and-cash/sqm-payout-status-alert/usePayoutStatus.d.ts +7 -0
- package/docs/docs.docx +0 -0
- package/package.json +1 -1
- package/dist/mint-components/p-1086f9c1.system.entry.js +0 -1
- package/dist/mint-components/p-1870ab08.system.entry.js +0 -1
|
@@ -21,7 +21,7 @@ const ErrorView = require('./ErrorView-b2fcf954.js');
|
|
|
21
21
|
const sqmInvoiceTableView = require('./sqm-invoice-table-view-5c74607f.js');
|
|
22
22
|
const extractProps = require('./extractProps-fd93ba62.js');
|
|
23
23
|
const keys = require('./keys-cff24974.js');
|
|
24
|
-
const usePayoutStatus = require('./usePayoutStatus-
|
|
24
|
+
const usePayoutStatus = require('./usePayoutStatus-79b5577f.js');
|
|
25
25
|
const useVerificationEmail = require('./useVerificationEmail-95a82767.js');
|
|
26
26
|
|
|
27
27
|
const TAX_CONTEXT_NAMESPACE = "sq:tax-and-cash";
|
|
@@ -2203,10 +2203,6 @@ function useDocusignForm(props) {
|
|
|
2203
2203
|
? publisher === null || publisher === void 0 ? void 0 : publisher.requiredTaxDocumentType : undefined;
|
|
2204
2204
|
const actualDocumentType = existingDocumentType ||
|
|
2205
2205
|
getDocumentType(participantType) || (publisher === null || publisher === void 0 ? void 0 : publisher.requiredTaxDocumentType);
|
|
2206
|
-
stencilHooks_module.useEffect(() => {
|
|
2207
|
-
// reset redirect hash
|
|
2208
|
-
window.location.hash = "";
|
|
2209
|
-
}, []);
|
|
2210
2206
|
stencilHooks_module.useEffect(() => {
|
|
2211
2207
|
if (!existingDocumentType)
|
|
2212
2208
|
return;
|
|
@@ -26,7 +26,7 @@ const AsYouType = require('./AsYouType-6788393a.js');
|
|
|
26
26
|
const utilities = require('./utilities-78f5e169.js');
|
|
27
27
|
const ShadowViewAddon = require('./ShadowViewAddon-28865623.js');
|
|
28
28
|
require('./sqm-portal-container-view-4f15143a.js');
|
|
29
|
-
const usePayoutStatus = require('./usePayoutStatus-
|
|
29
|
+
const usePayoutStatus = require('./usePayoutStatus-79b5577f.js');
|
|
30
30
|
|
|
31
31
|
const BigStat = class {
|
|
32
32
|
constructor(hostRef) {
|
|
@@ -2364,14 +2364,31 @@ function PayoutStatusAlertView(props) {
|
|
|
2364
2364
|
class: sheet$2.classes.ErrorAlertContainer,
|
|
2365
2365
|
};
|
|
2366
2366
|
case "OVER_W9_THRESHOLD":
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
|
|
2370
|
-
|
|
2371
|
-
|
|
2372
|
-
|
|
2373
|
-
|
|
2374
|
-
|
|
2367
|
+
if (states.enforceUsTaxComplianceOption === "CASH_ONLY_DEFER_W9") {
|
|
2368
|
+
return {
|
|
2369
|
+
header: text.w9RequiredHeader,
|
|
2370
|
+
description: global.intl.formatMessage({
|
|
2371
|
+
id: "w9RequiredDescription",
|
|
2372
|
+
defaultMessage: text.w9RequiredDescription,
|
|
2373
|
+
}, {
|
|
2374
|
+
termsAndConditions: (index.h("a", { target: "_blank", href: `https://terms.advocate.impact.com/PayoutTermsAndConditions.html` }, text.termsAndConditions)),
|
|
2375
|
+
}),
|
|
2376
|
+
buttonText: text.w9RequiredButtonText,
|
|
2377
|
+
alertType: "warning",
|
|
2378
|
+
icon: "exclamation-triangle",
|
|
2379
|
+
class: sheet$2.classes.WarningAlertContainer,
|
|
2380
|
+
};
|
|
2381
|
+
}
|
|
2382
|
+
else {
|
|
2383
|
+
return {
|
|
2384
|
+
header: text.informationRequiredHeader,
|
|
2385
|
+
description: text.informationRequiredDescription,
|
|
2386
|
+
buttonText: text.informationRequiredButtonText,
|
|
2387
|
+
alertType: "info",
|
|
2388
|
+
icon: "info-circle",
|
|
2389
|
+
class: sheet$2.classes.InfoAlertContainer,
|
|
2390
|
+
};
|
|
2391
|
+
}
|
|
2375
2392
|
case "HOLD":
|
|
2376
2393
|
return {
|
|
2377
2394
|
header: text.holdHeader,
|
|
@@ -985,6 +985,13 @@ const GET_USER_STATUS = index_module.dist.gql `
|
|
|
985
985
|
}
|
|
986
986
|
}
|
|
987
987
|
`;
|
|
988
|
+
const GET_TAX_SETTING = index_module.dist.gql `
|
|
989
|
+
query getTenantSettings {
|
|
990
|
+
tenantSettings {
|
|
991
|
+
enforceUsTaxCompliance
|
|
992
|
+
}
|
|
993
|
+
}
|
|
994
|
+
`;
|
|
988
995
|
function getStatus(data) {
|
|
989
996
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
|
|
990
997
|
const account = (_b = (_a = data.user.impactConnection) === null || _a === void 0 ? void 0 : _a.publisher) === null || _b === void 0 ? void 0 : _b.payoutsAccount;
|
|
@@ -1009,10 +1016,13 @@ function getStatus(data) {
|
|
|
1009
1016
|
return "DONE";
|
|
1010
1017
|
}
|
|
1011
1018
|
function usePayoutStatus(props) {
|
|
1019
|
+
var _a;
|
|
1012
1020
|
const { type } = index_module.getEnvironmentSDK();
|
|
1013
1021
|
const { loading, data, errors, refetch } = index_module.wn(GET_USER_STATUS, {});
|
|
1022
|
+
const { data: taxSettingRes } = index_module.wn(GET_TAX_SETTING, {});
|
|
1014
1023
|
const { render, loading: veriffLoading, errors: veriffErrors, } = useVeriffApp();
|
|
1015
1024
|
const [status, setStatus] = stencilHooks_module.useState(undefined);
|
|
1025
|
+
const enforceUsTaxComplianceOption = (_a = taxSettingRes === null || taxSettingRes === void 0 ? void 0 : taxSettingRes.tenantSettings) === null || _a === void 0 ? void 0 : _a.enforceUsTaxCompliance;
|
|
1016
1026
|
stencilHooks_module.useEffect(() => {
|
|
1017
1027
|
if (!data)
|
|
1018
1028
|
return;
|
|
@@ -1034,6 +1044,7 @@ function usePayoutStatus(props) {
|
|
|
1034
1044
|
veriffLoading,
|
|
1035
1045
|
status,
|
|
1036
1046
|
error: !!errors,
|
|
1047
|
+
enforceUsTaxComplianceOption,
|
|
1037
1048
|
},
|
|
1038
1049
|
data: { type },
|
|
1039
1050
|
text: props.getTextProps(),
|
|
@@ -50,10 +50,6 @@ export function useDocusignForm(props) {
|
|
|
50
50
|
? publisher === null || publisher === void 0 ? void 0 : publisher.requiredTaxDocumentType : undefined;
|
|
51
51
|
const actualDocumentType = existingDocumentType ||
|
|
52
52
|
getDocumentType(participantType) || (publisher === null || publisher === void 0 ? void 0 : publisher.requiredTaxDocumentType);
|
|
53
|
-
useEffect(() => {
|
|
54
|
-
// reset redirect hash
|
|
55
|
-
window.location.hash = "";
|
|
56
|
-
}, []);
|
|
57
53
|
useEffect(() => {
|
|
58
54
|
if (!existingDocumentType)
|
|
59
55
|
return;
|
|
@@ -130,14 +130,31 @@ export function PayoutStatusAlertView(props) {
|
|
|
130
130
|
class: sheet.classes.ErrorAlertContainer,
|
|
131
131
|
};
|
|
132
132
|
case "OVER_W9_THRESHOLD":
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
133
|
+
if (states.enforceUsTaxComplianceOption === "CASH_ONLY_DEFER_W9") {
|
|
134
|
+
return {
|
|
135
|
+
header: text.w9RequiredHeader,
|
|
136
|
+
description: intl.formatMessage({
|
|
137
|
+
id: "w9RequiredDescription",
|
|
138
|
+
defaultMessage: text.w9RequiredDescription,
|
|
139
|
+
}, {
|
|
140
|
+
termsAndConditions: (h("a", { target: "_blank", href: `https://terms.advocate.impact.com/PayoutTermsAndConditions.html` }, text.termsAndConditions)),
|
|
141
|
+
}),
|
|
142
|
+
buttonText: text.w9RequiredButtonText,
|
|
143
|
+
alertType: "warning",
|
|
144
|
+
icon: "exclamation-triangle",
|
|
145
|
+
class: sheet.classes.WarningAlertContainer,
|
|
146
|
+
};
|
|
147
|
+
}
|
|
148
|
+
else {
|
|
149
|
+
return {
|
|
150
|
+
header: text.informationRequiredHeader,
|
|
151
|
+
description: text.informationRequiredDescription,
|
|
152
|
+
buttonText: text.informationRequiredButtonText,
|
|
153
|
+
alertType: "info",
|
|
154
|
+
icon: "info-circle",
|
|
155
|
+
class: sheet.classes.InfoAlertContainer,
|
|
156
|
+
};
|
|
157
|
+
}
|
|
141
158
|
case "HOLD":
|
|
142
159
|
return {
|
|
143
160
|
header: text.holdHeader,
|
package/dist/collection/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert.js
CHANGED
|
@@ -582,7 +582,7 @@ export class PayoutStatusAlert {
|
|
|
582
582
|
"mutable": false,
|
|
583
583
|
"complexType": {
|
|
584
584
|
"original": "DemoData<PayoutStatusAlertViewProps>",
|
|
585
|
-
"resolved": "{ states?: { error: boolean; loading: boolean; status: PayoutStatus; veriffLoading: boolean; }; data?: { type: \"SquatchJS2\" | \"SquatchAndroid\" | \"SquatchIOS\" | \"SquatchPortal\" | \"SquatchAdmin\" | \"None\"; }; }",
|
|
585
|
+
"resolved": "{ states?: { error: boolean; loading: boolean; status: PayoutStatus; veriffLoading: boolean; enforceUsTaxComplianceOption?: EnforceUsTaxComplianceOption; }; data?: { type: \"SquatchJS2\" | \"SquatchAndroid\" | \"SquatchIOS\" | \"SquatchPortal\" | \"SquatchAdmin\" | \"None\"; }; }",
|
|
586
586
|
"references": {
|
|
587
587
|
"DemoData": {
|
|
588
588
|
"location": "import",
|
|
@@ -22,6 +22,13 @@ const GET_USER_STATUS = gql `
|
|
|
22
22
|
}
|
|
23
23
|
}
|
|
24
24
|
`;
|
|
25
|
+
const GET_TAX_SETTING = gql `
|
|
26
|
+
query getTenantSettings {
|
|
27
|
+
tenantSettings {
|
|
28
|
+
enforceUsTaxCompliance
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
`;
|
|
25
32
|
export function getStatus(data) {
|
|
26
33
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
|
|
27
34
|
const account = (_b = (_a = data.user.impactConnection) === null || _a === void 0 ? void 0 : _a.publisher) === null || _b === void 0 ? void 0 : _b.payoutsAccount;
|
|
@@ -46,10 +53,13 @@ export function getStatus(data) {
|
|
|
46
53
|
return "DONE";
|
|
47
54
|
}
|
|
48
55
|
export function usePayoutStatus(props) {
|
|
56
|
+
var _a;
|
|
49
57
|
const { type } = getEnvironmentSDK();
|
|
50
58
|
const { loading, data, errors, refetch } = useQuery(GET_USER_STATUS, {});
|
|
59
|
+
const { data: taxSettingRes } = useQuery(GET_TAX_SETTING, {});
|
|
51
60
|
const { render, loading: veriffLoading, errors: veriffErrors, } = useVeriffApp();
|
|
52
61
|
const [status, setStatus] = useState(undefined);
|
|
62
|
+
const enforceUsTaxComplianceOption = (_a = taxSettingRes === null || taxSettingRes === void 0 ? void 0 : taxSettingRes.tenantSettings) === null || _a === void 0 ? void 0 : _a.enforceUsTaxCompliance;
|
|
53
63
|
useEffect(() => {
|
|
54
64
|
if (!data)
|
|
55
65
|
return;
|
|
@@ -71,6 +81,7 @@ export function usePayoutStatus(props) {
|
|
|
71
81
|
veriffLoading,
|
|
72
82
|
status,
|
|
73
83
|
error: !!errors,
|
|
84
|
+
enforceUsTaxComplianceOption,
|
|
74
85
|
},
|
|
75
86
|
data: { type },
|
|
76
87
|
text: props.getTextProps(),
|
|
@@ -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-6ae7fc44.js';
|
|
21
21
|
import { u as useVerificationEmail } from './useVerificationEmail-edc318cb.js';
|
|
22
22
|
|
|
23
23
|
const TAX_CONTEXT_NAMESPACE = "sq:tax-and-cash";
|
|
@@ -2199,10 +2199,6 @@ function useDocusignForm(props) {
|
|
|
2199
2199
|
? publisher === null || publisher === void 0 ? void 0 : publisher.requiredTaxDocumentType : undefined;
|
|
2200
2200
|
const actualDocumentType = existingDocumentType ||
|
|
2201
2201
|
getDocumentType(participantType) || (publisher === null || publisher === void 0 ? void 0 : publisher.requiredTaxDocumentType);
|
|
2202
|
-
useEffect(() => {
|
|
2203
|
-
// reset redirect hash
|
|
2204
|
-
window.location.hash = "";
|
|
2205
|
-
}, []);
|
|
2206
2202
|
useEffect(() => {
|
|
2207
2203
|
if (!existingDocumentType)
|
|
2208
2204
|
return;
|
|
@@ -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-6ae7fc44.js';
|
|
26
26
|
|
|
27
27
|
const BigStat = class {
|
|
28
28
|
constructor(hostRef) {
|
|
@@ -2360,14 +2360,31 @@ function PayoutStatusAlertView(props) {
|
|
|
2360
2360
|
class: sheet$2.classes.ErrorAlertContainer,
|
|
2361
2361
|
};
|
|
2362
2362
|
case "OVER_W9_THRESHOLD":
|
|
2363
|
-
|
|
2364
|
-
|
|
2365
|
-
|
|
2366
|
-
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
|
|
2370
|
-
|
|
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.informationRequiredHeader,
|
|
2381
|
+
description: text.informationRequiredDescription,
|
|
2382
|
+
buttonText: text.informationRequiredButtonText,
|
|
2383
|
+
alertType: "info",
|
|
2384
|
+
icon: "info-circle",
|
|
2385
|
+
class: sheet$2.classes.InfoAlertContainer,
|
|
2386
|
+
};
|
|
2387
|
+
}
|
|
2371
2388
|
case "HOLD":
|
|
2372
2389
|
return {
|
|
2373
2390
|
header: text.holdHeader,
|
|
@@ -983,6 +983,13 @@ const GET_USER_STATUS = dist.gql `
|
|
|
983
983
|
}
|
|
984
984
|
}
|
|
985
985
|
`;
|
|
986
|
+
const GET_TAX_SETTING = dist.gql `
|
|
987
|
+
query getTenantSettings {
|
|
988
|
+
tenantSettings {
|
|
989
|
+
enforceUsTaxCompliance
|
|
990
|
+
}
|
|
991
|
+
}
|
|
992
|
+
`;
|
|
986
993
|
function getStatus(data) {
|
|
987
994
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
|
|
988
995
|
const account = (_b = (_a = data.user.impactConnection) === null || _a === void 0 ? void 0 : _a.publisher) === null || _b === void 0 ? void 0 : _b.payoutsAccount;
|
|
@@ -1007,10 +1014,13 @@ function getStatus(data) {
|
|
|
1007
1014
|
return "DONE";
|
|
1008
1015
|
}
|
|
1009
1016
|
function usePayoutStatus(props) {
|
|
1017
|
+
var _a;
|
|
1010
1018
|
const { type } = getEnvironmentSDK();
|
|
1011
1019
|
const { loading, data, errors, refetch } = wn(GET_USER_STATUS, {});
|
|
1020
|
+
const { data: taxSettingRes } = wn(GET_TAX_SETTING, {});
|
|
1012
1021
|
const { render, loading: veriffLoading, errors: veriffErrors, } = useVeriffApp();
|
|
1013
1022
|
const [status, setStatus] = useState(undefined);
|
|
1023
|
+
const enforceUsTaxComplianceOption = (_a = taxSettingRes === null || taxSettingRes === void 0 ? void 0 : taxSettingRes.tenantSettings) === null || _a === void 0 ? void 0 : _a.enforceUsTaxCompliance;
|
|
1014
1024
|
useEffect(() => {
|
|
1015
1025
|
if (!data)
|
|
1016
1026
|
return;
|
|
@@ -1032,6 +1042,7 @@ function usePayoutStatus(props) {
|
|
|
1032
1042
|
veriffLoading,
|
|
1033
1043
|
status,
|
|
1034
1044
|
error: !!errors,
|
|
1045
|
+
enforceUsTaxComplianceOption,
|
|
1035
1046
|
},
|
|
1036
1047
|
data: { type },
|
|
1037
1048
|
text: props.getTextProps(),
|