@saasquatch/mint-components 2.4.4 → 2.4.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/{data-89ac73dd.js → data-04ef5511.js} +2 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/mint-components.cjs.js +1 -1
- package/dist/cjs/sqm-banking-info-form_10.cjs.entry.js +35 -21
- package/dist/cjs/sqm-big-stat_47.cjs.entry.js +33 -3
- package/dist/cjs/sqm-email-verification_2.cjs.entry.js +1 -1
- package/dist/cjs/sqm-stencilbook.cjs.entry.js +74 -7
- package/dist/cjs/{sqm-user-info-form-view-ec41191c.js → sqm-user-info-form-view-9745956d.js} +29 -26
- package/dist/cjs/{subregions-3d27e279.js → subregions-d12829d6.js} +28 -0
- package/dist/cjs/{useIndirectTaxForm-5211013b.js → useIndirectTaxForm-0969e194.js} +26 -3
- package/dist/collection/components/tax-and-cash/TaxForm.stories.js +19 -0
- package/dist/collection/components/tax-and-cash/data.js +2 -0
- package/dist/collection/components/tax-and-cash/sqm-payout-details-card/PayoutDetailsCard.stories.js +25 -0
- package/dist/collection/components/tax-and-cash/sqm-payout-details-card/sqm-payout-details-card-view.js +12 -8
- package/dist/collection/components/tax-and-cash/sqm-payout-details-card/sqm-payout-details-card.js +1 -0
- package/dist/collection/components/tax-and-cash/sqm-payout-details-card/usePayoutDetailsCard.js +10 -9
- package/dist/collection/components/tax-and-cash/sqm-payout-status-alert/PayoutStatusAlert.stories.js +7 -0
- package/dist/collection/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert-view.js +11 -0
- 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 +25 -1
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash/sqm-tax-and-cash.js +63 -1
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash-dashboard/TaxAndCashDashboardView.stories.js +11 -3
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard-view.js +27 -24
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard.js +51 -1
- package/dist/collection/components/tax-and-cash/sqm-tax-and-cash-dashboard/useTaxAndCashDashboard.js +2 -1
- package/dist/collection/components/tax-and-cash/sqm-user-info-form/UserInfoFormView.stories.js +3 -1
- package/dist/collection/components/tax-and-cash/utils.js +26 -0
- package/dist/esm/{data-8698cbc6.js → data-0be04430.js} +2 -0
- package/dist/esm/loader.js +1 -1
- package/dist/esm/mint-components.js +1 -1
- package/dist/esm/sqm-banking-info-form_10.entry.js +35 -21
- package/dist/esm/sqm-big-stat_47.entry.js +33 -3
- package/dist/esm/sqm-email-verification_2.entry.js +1 -1
- package/dist/esm/sqm-stencilbook.entry.js +74 -7
- package/dist/esm/{sqm-user-info-form-view-b43a1729.js → sqm-user-info-form-view-81526655.js} +29 -26
- package/dist/esm/{subregions-810a5c2d.js → subregions-98789b46.js} +27 -1
- package/dist/esm/{useIndirectTaxForm-4dc576f0.js → useIndirectTaxForm-bbe8779d.js} +26 -3
- package/dist/esm-es5/data-0be04430.js +1 -0
- 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_10.entry.js +1 -1
- package/dist/esm-es5/sqm-big-stat_47.entry.js +1 -1
- package/dist/esm-es5/sqm-email-verification_2.entry.js +1 -1
- package/dist/esm-es5/sqm-stencilbook.entry.js +1 -1
- package/dist/esm-es5/sqm-user-info-form-view-81526655.js +1 -0
- package/dist/esm-es5/subregions-98789b46.js +1 -0
- package/dist/esm-es5/useIndirectTaxForm-bbe8779d.js +6 -0
- package/dist/mint-components/mint-components.esm.js +1 -1
- package/dist/mint-components/p-07b989a3.system.js +6 -0
- package/dist/mint-components/{p-484817ed.entry.js → p-0d89ef44.entry.js} +3 -3
- package/dist/mint-components/p-14f4cce8.js +1 -0
- package/dist/mint-components/{p-26126144.entry.js → p-1e9c339f.entry.js} +2 -2
- package/dist/mint-components/p-227ca8d4.system.js +1 -0
- package/dist/mint-components/p-231926a3.system.entry.js +1 -0
- package/dist/mint-components/{p-e8aaf90f.system.entry.js → p-288249ae.system.entry.js} +1 -1
- package/dist/mint-components/p-53575d04.js +1 -0
- package/dist/mint-components/p-549d60ee.system.entry.js +1 -0
- package/dist/mint-components/{p-83099738.entry.js → p-654cdee8.entry.js} +1 -1
- package/dist/mint-components/{p-5c52100b.js → p-7aa89fa8.js} +2 -0
- package/dist/mint-components/p-826e3db0.system.js +1 -0
- package/dist/mint-components/p-a1b655ba.system.js +1 -0
- package/dist/mint-components/p-b1feb0f1.js +108 -0
- package/dist/mint-components/p-bfb00685.system.js +1 -1
- package/dist/mint-components/{p-0a0d8788.system.entry.js → p-cf12347b.system.entry.js} +1 -1
- package/dist/mint-components/p-e1b917ff.entry.js +83 -0
- package/dist/types/components/tax-and-cash/TaxForm.stories.d.ts +1 -0
- package/dist/types/components/tax-and-cash/data.d.ts +2 -0
- package/dist/types/components/tax-and-cash/sqm-payout-details-card/PayoutDetailsCard.stories.d.ts +3 -0
- package/dist/types/components/tax-and-cash/sqm-payout-details-card/sqm-payout-details-card-view.d.ts +1 -0
- package/dist/types/components/tax-and-cash/sqm-payout-status-alert/PayoutStatusAlert.stories.d.ts +1 -0
- package/dist/types/components/tax-and-cash/sqm-payout-status-alert/sqm-payout-status-alert-view.d.ts +3 -0
- 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 +2 -1
- package/dist/types/components/tax-and-cash/sqm-tax-and-cash/sqm-tax-and-cash.d.ts +11 -0
- package/dist/types/components/tax-and-cash/sqm-tax-and-cash-dashboard/TaxAndCashDashboardView.stories.d.ts +1 -0
- package/dist/types/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard-view.d.ts +3 -0
- package/dist/types/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard.d.ts +8 -0
- package/dist/types/components/tax-and-cash/utils.d.ts +5 -1
- package/dist/types/components.d.ts +54 -0
- 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/data-8698cbc6.js +0 -1
- package/dist/esm-es5/sqm-user-info-form-view-b43a1729.js +0 -1
- package/dist/esm-es5/subregions-810a5c2d.js +0 -1
- package/dist/esm-es5/useIndirectTaxForm-4dc576f0.js +0 -6
- package/dist/mint-components/p-0ad64881.js +0 -101
- package/dist/mint-components/p-13379201.system.entry.js +0 -1
- package/dist/mint-components/p-3090d391.system.js +0 -1
- package/dist/mint-components/p-4fd803e7.entry.js +0 -83
- package/dist/mint-components/p-6cd93ea3.system.js +0 -6
- package/dist/mint-components/p-92f520c9.js +0 -1
- package/dist/mint-components/p-9c1f5317.system.js +0 -1
- package/dist/mint-components/p-ae19027d.js +0 -1
- package/dist/mint-components/p-ef695105.system.entry.js +0 -1
- package/dist/mint-components/p-fd231c49.system.js +0 -1
|
@@ -8,17 +8,17 @@ import { g as getProps } from './utils-334c1e34.js';
|
|
|
8
8
|
import { c as createStyleSheet } from './JSS-67b5cff8.js';
|
|
9
9
|
import './mixins-f750863a.js';
|
|
10
10
|
import './AsYouType-2d56519e.js';
|
|
11
|
-
import { t as taxTypeToName,
|
|
11
|
+
import { t as taxTypeToName, d as validTaxDocument, I as INDIRECT_TAX_SPAIN_REGIONS, a as INDIRECT_TAX_PROVINCES, b as formatPayoutThreshold, c as isBalanceUnderPayoutThreshold, o as objectIsFull, e as toDomesticNumber, A as ADDRESS_REGIONS } from './subregions-98789b46.js';
|
|
12
12
|
import { G as GenericTableView } from './GenericTableView-471a9386.js';
|
|
13
13
|
import { u as useRerenderListener, a as useRequestRerender } from './re-render-bf46ba54.js';
|
|
14
14
|
import { g as generateUserError, d as dropZoneColumnIndexes } from './useReferralTable-3aa4b527.js';
|
|
15
15
|
import { u as useChildElements } from './useChildElements-06937df7.js';
|
|
16
16
|
import { l as luxon } from './luxon-1be92a8e.js';
|
|
17
|
-
import { O as OtherRegionSlotView, I as InvoiceTableView, v as vatLabels, T as TaxAndCashDashboardView, U as UserInfoFormView } from './sqm-user-info-form-view-
|
|
18
|
-
import { F as FORM_STEPS, a as TAX_FORM_CONTEXT_NAMESPACE, S as SORTED_COUNTRIES_NAMESPACE, f as FINANCE_NETWORK_SETTINGS_NAMESPACE, c as USER_QUERY_NAMESPACE, T as TAX_CONTEXT_NAMESPACE, C as CURRENCIES_NAMESPACE, U as USER_FORM_CONTEXT_NAMESPACE } from './data-
|
|
17
|
+
import { O as OtherRegionSlotView, I as InvoiceTableView, v as vatLabels, T as TaxAndCashDashboardView, U as UserInfoFormView } from './sqm-user-info-form-view-81526655.js';
|
|
18
|
+
import { F as FORM_STEPS, a as TAX_FORM_CONTEXT_NAMESPACE, S as SORTED_COUNTRIES_NAMESPACE, f as FINANCE_NETWORK_SETTINGS_NAMESPACE, c as USER_QUERY_NAMESPACE, T as TAX_CONTEXT_NAMESPACE, C as CURRENCIES_NAMESPACE, U as USER_FORM_CONTEXT_NAMESPACE } from './data-0be04430.js';
|
|
19
19
|
import { c as VERIFICATION_EVENT_KEY } from './keys-1054056a.js';
|
|
20
20
|
import { T as TAX_FORM_UPDATED_EVENT_KEY } from './eventKeys-f76b6a03.js';
|
|
21
|
-
import { a as useIndirectTaxForm, b as useVeriffApp, g as getStatus, V as VERIFF_COMPLETE_EVENT_KEY, c as CONNECT_PARTNER, C as COMPLETE_PARTNER } from './useIndirectTaxForm-
|
|
21
|
+
import { a as useIndirectTaxForm, b as useVeriffApp, g as getStatus, V as VERIFF_COMPLETE_EVENT_KEY, c as CONNECT_PARTNER, C as COMPLETE_PARTNER } from './useIndirectTaxForm-bbe8779d.js';
|
|
22
22
|
|
|
23
23
|
function getFormMap({ props, getValidationErrorMessage, bankCountry, }) {
|
|
24
24
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6, _7, _8, _9, _10, _11, _12, _13, _14, _15, _16, _17, _18, _19, _20, _21, _22, _23, _24, _25, _26, _27, _28, _29, _30, _31, _32, _33, _34, _35, _36, _37, _38, _39, _40, _41, _42, _43, _44, _45, _46, _47, _48, _49, _50, _51, _52, _53, _54, _55, _56, _57, _58, _59, _60, _61, _62, _63, _64, _65, _66, _67, _68, _69, _70, _71, _72, _73, _74, _75, _76;
|
|
@@ -3702,18 +3702,22 @@ function PayoutDetailsCardView(props) {
|
|
|
3702
3702
|
}, {
|
|
3703
3703
|
thresholdBalance: states.thresholdBalance,
|
|
3704
3704
|
});
|
|
3705
|
+
// No payout is scheduled while the balance sits under the minimum
|
|
3706
|
+
const scheduleText = states.badgeStatus === "thresholdPayout"
|
|
3707
|
+
? states.thresholdBalance
|
|
3708
|
+
? thresholdText
|
|
3709
|
+
: ""
|
|
3710
|
+
: states.belowPayoutThreshold
|
|
3711
|
+
? ""
|
|
3712
|
+
: states.nextPayoutDate;
|
|
3713
|
+
const showBadge = states.badgeStatus !== "thresholdPayout" && !states.belowPayoutThreshold;
|
|
3705
3714
|
return (h("div", { class: classes.Container },
|
|
3706
3715
|
h("style", { type: "text/css" }, styleString),
|
|
3707
3716
|
states.loading ? (renderLoadingSkeleton()) : (h("div", { class: classes.CardContainer },
|
|
3708
3717
|
h("div", { class: classes.StatusContainer },
|
|
3709
|
-
h("p", { class: classes.SubduedRegularText },
|
|
3710
|
-
|
|
3711
|
-
|
|
3712
|
-
: ""
|
|
3713
|
-
: states.nextPayoutDate),
|
|
3714
|
-
states.badgeStatus === "thresholdPayout"
|
|
3715
|
-
? null
|
|
3716
|
-
: renderStatusBadge(states.badgeStatus, text.statusBadgeText)),
|
|
3718
|
+
h("p", { class: classes.SubduedRegularText }, scheduleText),
|
|
3719
|
+
showBadge &&
|
|
3720
|
+
renderStatusBadge(states.badgeStatus, text.statusBadgeText)),
|
|
3717
3721
|
h("h1", { class: classes.MainCurrency }, states.balance),
|
|
3718
3722
|
states.payoutType === "PAYPAL" ? (h("div", { class: classes.PaypalDetailsContainer },
|
|
3719
3723
|
h("span", { class: classes.PaypalEmail }, states.paypalEmailAddress),
|
|
@@ -3724,7 +3728,7 @@ function PayoutDetailsCardView(props) {
|
|
|
3724
3728
|
}
|
|
3725
3729
|
|
|
3726
3730
|
function usePayoutDetailsCard(props) {
|
|
3727
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j
|
|
3731
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
3728
3732
|
const { data, loading } = $n(USER_QUERY_NAMESPACE);
|
|
3729
3733
|
const publisher = (_b = (_a = data === null || data === void 0 ? void 0 : data.user) === null || _a === void 0 ? void 0 : _a.impactConnection) === null || _b === void 0 ? void 0 : _b.publisher;
|
|
3730
3734
|
function getPayoutDetailedStatusText(paymentDay) {
|
|
@@ -3763,18 +3767,18 @@ function usePayoutDetailsCard(props) {
|
|
|
3763
3767
|
return {
|
|
3764
3768
|
states: {
|
|
3765
3769
|
loading,
|
|
3766
|
-
thresholdBalance: (
|
|
3767
|
-
|
|
3768
|
-
balance: (
|
|
3769
|
-
badgeStatus: ((
|
|
3770
|
+
thresholdBalance: formatPayoutThreshold(publisher),
|
|
3771
|
+
belowPayoutThreshold: isBalanceUnderPayoutThreshold(publisher),
|
|
3772
|
+
balance: (_d = publisher === null || publisher === void 0 ? void 0 : publisher.payoutsAccount) === null || _d === void 0 ? void 0 : _d.balance,
|
|
3773
|
+
badgeStatus: ((_e = publisher === null || publisher === void 0 ? void 0 : publisher.withdrawalSettings) === null || _e === void 0 ? void 0 : _e.paymentSchedulingType) !== "FIXED_DAY"
|
|
3770
3774
|
? "thresholdPayout"
|
|
3771
3775
|
: isPayoutToday
|
|
3772
3776
|
? "payoutToday"
|
|
3773
3777
|
: "nextPayout",
|
|
3774
|
-
payoutType: (
|
|
3775
|
-
error: (
|
|
3776
|
-
paypalEmailAddress: (
|
|
3777
|
-
cardNumberPreview: (
|
|
3778
|
+
payoutType: (_f = publisher === null || publisher === void 0 ? void 0 : publisher.withdrawalSettings) === null || _f === void 0 ? void 0 : _f.paymentMethod,
|
|
3779
|
+
error: (_g = publisher === null || publisher === void 0 ? void 0 : publisher.payoutsAccount) === null || _g === void 0 ? void 0 : _g.hold,
|
|
3780
|
+
paypalEmailAddress: (_h = publisher === null || publisher === void 0 ? void 0 : publisher.withdrawalSettings) === null || _h === void 0 ? void 0 : _h.paypalEmailAddress,
|
|
3781
|
+
cardNumberPreview: (_j = publisher === null || publisher === void 0 ? void 0 : publisher.withdrawalSettings) === null || _j === void 0 ? void 0 : _j.bankAccountNumber,
|
|
3778
3782
|
nextPayoutDate: paymentDay,
|
|
3779
3783
|
},
|
|
3780
3784
|
text: props.getTextProps(),
|
|
@@ -3830,6 +3834,7 @@ function useDemoPayoutDetailsCard(props) {
|
|
|
3830
3834
|
loading: false,
|
|
3831
3835
|
error: false,
|
|
3832
3836
|
thresholdBalance: "$50",
|
|
3837
|
+
belowPayoutThreshold: false,
|
|
3833
3838
|
mainCurrency: { currencyText: "USD", amountText: "100.00" },
|
|
3834
3839
|
badgeStatus: "nextPayout",
|
|
3835
3840
|
payoutType: "BANK_TRANSFER",
|
|
@@ -3963,6 +3968,7 @@ const useTaxAndCashDashboard = (props) => {
|
|
|
3963
3968
|
showNewFormDialog: showDialog,
|
|
3964
3969
|
hasHold: !!((_o = publisher === null || publisher === void 0 ? void 0 : publisher.payoutsAccount) === null || _o === void 0 ? void 0 : _o.hold),
|
|
3965
3970
|
payoutStatus,
|
|
3971
|
+
minPayoutAmount: formatPayoutThreshold(publisher),
|
|
3966
3972
|
veriffLoading,
|
|
3967
3973
|
enforceUsTaxComplianceOption,
|
|
3968
3974
|
},
|
|
@@ -4223,6 +4229,14 @@ const TaxAndCashDashboard = class {
|
|
|
4223
4229
|
* @uiName Account review alert description
|
|
4224
4230
|
*/
|
|
4225
4231
|
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}.";
|
|
4232
|
+
/**
|
|
4233
|
+
* @uiName Balance under payout minimum alert header
|
|
4234
|
+
*/
|
|
4235
|
+
this.balanceUnderThresholdHeader = "Your balance is under the minimum payout";
|
|
4236
|
+
/**
|
|
4237
|
+
* @uiName Balance under payout minimum alert description
|
|
4238
|
+
*/
|
|
4239
|
+
this.balanceUnderThresholdDescription = "Your total balance is under {minPayoutAmount}, the minimum required for payout.";
|
|
4226
4240
|
/**
|
|
4227
4241
|
* @uiName Payment hold on change alert header
|
|
4228
4242
|
*/
|
|
@@ -11,7 +11,7 @@ import './mixins-f750863a.js';
|
|
|
11
11
|
import { C as CopyTextView } from './copy-text-view-87259b11.js';
|
|
12
12
|
import './sqm-text-span-view-72f43dff.js';
|
|
13
13
|
import { A as AsYouType } from './AsYouType-2d56519e.js';
|
|
14
|
-
import { g as getCountryObj, i as isValidI18nPhoneNumber, L as LoadingView } from './subregions-
|
|
14
|
+
import { g as getCountryObj, i as isValidI18nPhoneNumber, L as LoadingView } from './subregions-98789b46.js';
|
|
15
15
|
import { R as REGISTRATION_FORM_STATE_CONTEXT, a as useRegistrationForm } from './useRegistrationFormState-aa44cfff.js';
|
|
16
16
|
import { P as PortalRegistrationFormView } from './sqm-portal-registration-form-view-79265df5.js';
|
|
17
17
|
import { u as usePortalRegistrationForm } from './usePortalRegistrationForm-78fdfd93.js';
|
|
@@ -27,10 +27,10 @@ import { i as isEmpty } from './utilities-cbd8f2eb.js';
|
|
|
27
27
|
import { E as ErrorView } from './ErrorView-74cb3af8.js';
|
|
28
28
|
import { u as useDemoBigStat, W as useBigStat, B as BigStatView, C as CardFeedView, d as CheckboxFieldView, e as CouponCodeView, D as DropdownFieldView, E as EditProfileView, H as HeroView, I as InputFieldView, U as LeadDropdownFieldView, Q as LeadFormView, X as withShadowView, L as LeaderboardView, N as NameFieldsView, f as ChangeMarktingView, P as PortalChangePasswordView, g as PortalFooterView, h as PortalFrameView, c as BaseRegistrationFormView, R as ReferralIframeView, i as RewardExchangeView, Y as demoRewardExchange, G as useShareButton, a as ShareButtonView, K as useShareLink, J as ShareLinkView, S as StatContainerView, T as TaskCardView } from './ShadowViewAddon-ae0cd8b9.js';
|
|
29
29
|
import './sqm-portal-container-view-200c9df8.js';
|
|
30
|
-
import { T as TAX_CONTEXT_NAMESPACE, a as TAX_FORM_CONTEXT_NAMESPACE, U as USER_FORM_CONTEXT_NAMESPACE, C as CURRENCIES_NAMESPACE, b as COUNTRIES_NAMESPACE, S as SORTED_COUNTRIES_NAMESPACE, c as USER_QUERY_NAMESPACE, G as GET_USER$2, d as COUNTRIES_QUERY_NAMESPACE, e as GET_COUNTRIES, f as FINANCE_NETWORK_SETTINGS_NAMESPACE, g as GET_FINANCE_NETWORK_SETTINGS, h as CURRENCIES_QUERY_NAMESPACE, i as GET_CURRENCIES } from './data-
|
|
30
|
+
import { T as TAX_CONTEXT_NAMESPACE, a as TAX_FORM_CONTEXT_NAMESPACE, U as USER_FORM_CONTEXT_NAMESPACE, C as CURRENCIES_NAMESPACE, b as COUNTRIES_NAMESPACE, S as SORTED_COUNTRIES_NAMESPACE, c as USER_QUERY_NAMESPACE, G as GET_USER$2, d as COUNTRIES_QUERY_NAMESPACE, e as GET_COUNTRIES, f as FINANCE_NETWORK_SETTINGS_NAMESPACE, g as GET_FINANCE_NETWORK_SETTINGS, h as CURRENCIES_QUERY_NAMESPACE, i as GET_CURRENCIES } from './data-0be04430.js';
|
|
31
31
|
import { S as SHOW_CODE_NAMESPACE, a as VERIFICATION_EMAIL_NAMESPACE, b as SHOW_PARTNER_MODAL_NAMESPACE, P as PARTNER_CREATED_NAMESPACE, V as VERIFICATION_PARENT_NAMESPACE } from './keys-1054056a.js';
|
|
32
32
|
import './eventKeys-f76b6a03.js';
|
|
33
|
-
import { u as usePayoutStatus, C as COMPLETE_PARTNER } from './useIndirectTaxForm-
|
|
33
|
+
import { u as usePayoutStatus, C as COMPLETE_PARTNER } from './useIndirectTaxForm-bbe8779d.js';
|
|
34
34
|
import { p as parseStates } from './parseStates-ed75e224.js';
|
|
35
35
|
|
|
36
36
|
/**
|
|
@@ -3078,6 +3078,17 @@ function PayoutStatusAlertView(props) {
|
|
|
3078
3078
|
alertType: "warning",
|
|
3079
3079
|
icon: "exclamation-triangle",
|
|
3080
3080
|
};
|
|
3081
|
+
case "BALANCE_UNDER_THRESHOLD":
|
|
3082
|
+
return {
|
|
3083
|
+
header: text.balanceUnderThresholdHeader,
|
|
3084
|
+
description: intl.formatMessage({
|
|
3085
|
+
id: "balanceUnderThresholdDescription",
|
|
3086
|
+
defaultMessage: text.balanceUnderThresholdDescription,
|
|
3087
|
+
}, { minPayoutAmount: states.minPayoutAmount }),
|
|
3088
|
+
buttonText: null,
|
|
3089
|
+
alertType: "info",
|
|
3090
|
+
icon: "info-circle",
|
|
3091
|
+
};
|
|
3081
3092
|
case "PAYMENT_HOLD_ON_CHANGE":
|
|
3082
3093
|
return {
|
|
3083
3094
|
header: text.paymentHoldOnChangeHeader,
|
|
@@ -3285,6 +3296,14 @@ const PayoutStatusAlert = class {
|
|
|
3285
3296
|
* @uiName Account review alert description
|
|
3286
3297
|
*/
|
|
3287
3298
|
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}.";
|
|
3299
|
+
/**
|
|
3300
|
+
* @uiName Balance under payout minimum alert header
|
|
3301
|
+
*/
|
|
3302
|
+
this.balanceUnderThresholdHeader = "Your balance is under the minimum payout";
|
|
3303
|
+
/**
|
|
3304
|
+
* @uiName Balance under payout minimum alert description
|
|
3305
|
+
*/
|
|
3306
|
+
this.balanceUnderThresholdDescription = "Your total balance is under {minPayoutAmount}, the minimum required for payout.";
|
|
3288
3307
|
/**
|
|
3289
3308
|
* @uiName Payment on hold alert header
|
|
3290
3309
|
*/
|
|
@@ -7812,6 +7831,17 @@ const TaxAndCashMonolith = class {
|
|
|
7812
7831
|
* @uiName Account review alert description
|
|
7813
7832
|
*/
|
|
7814
7833
|
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}.";
|
|
7834
|
+
/**
|
|
7835
|
+
* @uiName Balance under payout minimum alert header
|
|
7836
|
+
* @uiGroup Dashboard Properties
|
|
7837
|
+
*/
|
|
7838
|
+
this.dashboard_balanceUnderThresholdHeader = "Your balance is under the minimum payout";
|
|
7839
|
+
/**
|
|
7840
|
+
* @uiName Balance under payout minimum alert description
|
|
7841
|
+
* @uiGroup Dashboard Properties
|
|
7842
|
+
* @uiWidget textArea
|
|
7843
|
+
*/
|
|
7844
|
+
this.dashboard_balanceUnderThresholdDescription = "Your total balance is under {minPayoutAmount}, the minimum required for payout.";
|
|
7815
7845
|
/**
|
|
7816
7846
|
* @uiName Payment on hold alert header
|
|
7817
7847
|
*/
|
|
@@ -6,7 +6,7 @@ import { c as cjs } from './cjs-bdfb4486.js';
|
|
|
6
6
|
import { g as getProps } from './utils-334c1e34.js';
|
|
7
7
|
import { c as createStyleSheet } from './JSS-67b5cff8.js';
|
|
8
8
|
import { T as TextSpanView } from './sqm-text-span-view-72f43dff.js';
|
|
9
|
-
import { g as GET_FINANCE_NETWORK_SETTINGS } from './data-
|
|
9
|
+
import { g as GET_FINANCE_NETWORK_SETTINGS } from './data-0be04430.js';
|
|
10
10
|
import { a as PartnerInfoModalContentView, P as PartnerInfoModalView } from './sqm-partner-info-modal-view-b921fed1.js';
|
|
11
11
|
import { S as SHOW_CODE_NAMESPACE, a as VERIFICATION_EMAIL_NAMESPACE, P as PARTNER_CREATED_NAMESPACE } from './keys-1054056a.js';
|
|
12
12
|
import { T as TAX_FORM_UPDATED_EVENT_KEY } from './eventKeys-f76b6a03.js';
|
|
@@ -11,7 +11,7 @@ import { C as CopyTextView } from './copy-text-view-87259b11.js';
|
|
|
11
11
|
import './sqm-text-span-view-72f43dff.js';
|
|
12
12
|
import { b as PortalRegisterView, P as PortalForgotPasswordView, a as PortalLoginView, c as PortalVerifyEmailView } from './sqm-portal-verify-email-view-590f964b.js';
|
|
13
13
|
import './AsYouType-2d56519e.js';
|
|
14
|
-
import { t as taxTypeToName, L as LoadingView, I as INDIRECT_TAX_SPAIN_REGIONS, a as INDIRECT_TAX_PROVINCES } from './subregions-
|
|
14
|
+
import { t as taxTypeToName, L as LoadingView, I as INDIRECT_TAX_SPAIN_REGIONS, a as INDIRECT_TAX_PROVINCES } from './subregions-98789b46.js';
|
|
15
15
|
import { P as PortalRegistrationFormView } from './sqm-portal-registration-form-view-79265df5.js';
|
|
16
16
|
import { G as GenericTableView } from './GenericTableView-471a9386.js';
|
|
17
17
|
import './useChildElements-06937df7.js';
|
|
@@ -33,9 +33,9 @@ import './ErrorView-74cb3af8.js';
|
|
|
33
33
|
import { Q as QrCodeView } from './sqm-qr-code-view-ce476721.js';
|
|
34
34
|
import { S as StatContainerView, B as BigStatView, a as ShareButtonView, P as PortalChangePasswordView, b as PoweredByImg$1, c as BaseRegistrationFormView, u as useDemoBigStat, T as TaskCardView, C as CardFeedView, d as CheckboxFieldView, e as CouponCodeView, D as DropdownFieldView, E as EditProfileView, L as LeaderboardView, H as HeroView, I as InputFieldView, N as NameFieldsView, f as ChangeMarktingView, g as PortalFooterView, h as PortalFrameView, R as ReferralIframeView, i as RewardExchangeView, r as rewardExchangeCustomErrorMsg, j as rewardExchangeLongText, k as rewardExchangeSelected, l as chooseAmountFixed, m as chooseAmountFixedNoDescription, n as chooseAmountVariable, o as chooseAmountVariableNoDescription, p as chooseAmountVariableDisabled, q as chooseAmountVariableUnavailable, s as confirmFixed, t as confirmVariable, v as redemptionError, w as queryError, x as success, y as successVariable, z as loading, A as empty$1, F as rewardExchange, G as useShareButton, J as ShareLinkView, K as useShareLink, M as ProgressBarView, O as ProgressBar$2, Q as LeadFormView, U as LeadDropdownFieldView, V as ShadowViewAddon } from './ShadowViewAddon-ae0cd8b9.js';
|
|
35
35
|
import { P as PortalContainerView, a as PortalSectionView } from './sqm-portal-container-view-200c9df8.js';
|
|
36
|
-
import { I as InvoiceTableView, T as TaxAndCashDashboardView$1, O as OtherRegionSlotView, U as UserInfoFormView$1 } from './sqm-user-info-form-view-
|
|
36
|
+
import { I as InvoiceTableView, T as TaxAndCashDashboardView$1, O as OtherRegionSlotView, U as UserInfoFormView$1 } from './sqm-user-info-form-view-81526655.js';
|
|
37
37
|
import { L as LeadInputFieldView } from './sqm-lead-input-field-view-671ff96f.js';
|
|
38
|
-
import './data-
|
|
38
|
+
import './data-0be04430.js';
|
|
39
39
|
import { P as PartnerInfoModalView } from './sqm-partner-info-modal-view-b921fed1.js';
|
|
40
40
|
|
|
41
41
|
/**
|
|
@@ -16582,6 +16582,8 @@ const defaultText = {
|
|
|
16582
16582
|
w9RequiredButtonText: "Submit W-9",
|
|
16583
16583
|
accountReviewHeader: "Your account is under review",
|
|
16584
16584
|
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}.",
|
|
16585
|
+
balanceUnderThresholdHeader: "Your balance is under the minimum payout",
|
|
16586
|
+
balanceUnderThresholdDescription: "Your total balance is under {minPayoutAmount}, the minimum required for payout.",
|
|
16585
16587
|
paymentHoldOnChangeHeader: "We are reviewing your new payout settings",
|
|
16586
16588
|
paymentHoldOnChangeDescription: "Your payout is temporarily on hold while we review your new payment information, this process is usually resolved within 48 hours.",
|
|
16587
16589
|
beneficiaryNameInvalidHeader: "Your payment information does not match your tax form",
|
|
@@ -16609,9 +16611,10 @@ const defaultCallbacks$1 = {
|
|
|
16609
16611
|
onNewFormCancel: () => { },
|
|
16610
16612
|
onNewFormClick: () => { },
|
|
16611
16613
|
};
|
|
16612
|
-
const
|
|
16613
|
-
payoutDetailsCardSlot: (h("sqm-payout-details-card", { demoData: { states: { badgeStatus: "nextPayout" } } })),
|
|
16614
|
-
};
|
|
16614
|
+
const buildSlots = (cardStates = {}) => ({
|
|
16615
|
+
payoutDetailsCardSlot: (h("sqm-payout-details-card", { demoData: { states: { badgeStatus: "nextPayout", ...cardStates } } })),
|
|
16616
|
+
});
|
|
16617
|
+
const defaultSlots = buildSlots();
|
|
16615
16618
|
const baseStates = {
|
|
16616
16619
|
payoutStatus: "DONE",
|
|
16617
16620
|
veriffLoading: false,
|
|
@@ -16643,6 +16646,11 @@ const TaxFormRequired = () => (h(TaxAndCashDashboardView$1, { states: {
|
|
|
16643
16646
|
// ─── Payout hold statuses not in TaxForm.stories.tsx ─────────────────────────
|
|
16644
16647
|
const AccountUnderReview = () => (h(TaxAndCashDashboardView$1, { states: { ...baseStates, payoutStatus: "NEW_PAYEE_REVIEW" }, text: defaultText, callbacks: defaultCallbacks$1, slots: defaultSlots }));
|
|
16645
16648
|
const PaymentHoldOnChange = () => (h(TaxAndCashDashboardView$1, { states: { ...baseStates, payoutStatus: "PAYMENT_HOLD_ON_CHANGE" }, text: defaultText, callbacks: defaultCallbacks$1, slots: defaultSlots }));
|
|
16649
|
+
const BalanceUnderThreshold = () => (h(TaxAndCashDashboardView$1, { states: {
|
|
16650
|
+
...baseStates,
|
|
16651
|
+
payoutStatus: "BALANCE_UNDER_THRESHOLD",
|
|
16652
|
+
minPayoutAmount: "USD50.00",
|
|
16653
|
+
}, text: defaultText, callbacks: defaultCallbacks$1, slots: buildSlots({ belowPayoutThreshold: true }) }));
|
|
16646
16654
|
const BeneficiaryNameInvalid = () => (h(TaxAndCashDashboardView$1, { states: { ...baseStates, payoutStatus: "BENEFICIARY_NAME_INVALID" }, text: defaultText, callbacks: defaultCallbacks$1, slots: defaultSlots }));
|
|
16647
16655
|
const BeneficiaryNameMismatch = () => (h(TaxAndCashDashboardView$1, { states: { ...baseStates, payoutStatus: "BENEFICIARY_NAME_MISMATCH" }, text: defaultText, callbacks: defaultCallbacks$1, slots: defaultSlots }));
|
|
16648
16656
|
const BankTaxNameMismatch = () => (h(TaxAndCashDashboardView$1, { states: { ...baseStates, payoutStatus: "BANK_TAX_NAME_MISMATCH" }, text: defaultText, callbacks: defaultCallbacks$1, slots: defaultSlots }));
|
|
@@ -16674,6 +16682,7 @@ const TaxAndCashDashboardView = /*#__PURE__*/Object.freeze({
|
|
|
16674
16682
|
TaxFormRequired: TaxFormRequired,
|
|
16675
16683
|
AccountUnderReview: AccountUnderReview,
|
|
16676
16684
|
PaymentHoldOnChange: PaymentHoldOnChange,
|
|
16685
|
+
BalanceUnderThreshold: BalanceUnderThreshold,
|
|
16677
16686
|
BeneficiaryNameInvalid: BeneficiaryNameInvalid,
|
|
16678
16687
|
BeneficiaryNameMismatch: BeneficiaryNameMismatch,
|
|
16679
16688
|
BankTaxNameMismatch: BankTaxNameMismatch,
|
|
@@ -17901,6 +17910,25 @@ const TaxAndCashDashboardPayoutsOnHold = () => {
|
|
|
17901
17910
|
},
|
|
17902
17911
|
} }));
|
|
17903
17912
|
};
|
|
17913
|
+
const TaxAndCashDashboardBalanceUnderThreshold = () => {
|
|
17914
|
+
return (h("sqm-tax-and-cash-dashboard", { demoData: {
|
|
17915
|
+
...dashboardProps,
|
|
17916
|
+
states: {
|
|
17917
|
+
payoutStatus: "BALANCE_UNDER_THRESHOLD",
|
|
17918
|
+
minPayoutAmount: "USD50.00",
|
|
17919
|
+
veriffLoading: false,
|
|
17920
|
+
canEditPayoutInfo: true,
|
|
17921
|
+
status: "ACTIVE",
|
|
17922
|
+
documentType: "W8BEN",
|
|
17923
|
+
documentTypeString: taxTypeToName("W8BEN"),
|
|
17924
|
+
dateSubmitted: "Jan 18th, 2025",
|
|
17925
|
+
noFormNeeded: false,
|
|
17926
|
+
indirectTaxNumber: "123456",
|
|
17927
|
+
showNewFormDialog: false,
|
|
17928
|
+
hasHold: false,
|
|
17929
|
+
},
|
|
17930
|
+
} }));
|
|
17931
|
+
};
|
|
17904
17932
|
const TaxAndCashDashboardNoTaxFormRequiredAndBeneficiaryNameInvalid = () => {
|
|
17905
17933
|
return (h("sqm-tax-and-cash-dashboard", { demoData: {
|
|
17906
17934
|
...dashboardProps,
|
|
@@ -18202,6 +18230,7 @@ const TaxForm = /*#__PURE__*/Object.freeze({
|
|
|
18202
18230
|
TaxAndCashDashboardW9ThresholdReached: TaxAndCashDashboardW9ThresholdReached,
|
|
18203
18231
|
TaxAndCashDashboardNewTaxForm: TaxAndCashDashboardNewTaxForm,
|
|
18204
18232
|
TaxAndCashDashboardPayoutsOnHold: TaxAndCashDashboardPayoutsOnHold,
|
|
18233
|
+
TaxAndCashDashboardBalanceUnderThreshold: TaxAndCashDashboardBalanceUnderThreshold,
|
|
18205
18234
|
TaxAndCashDashboardNoTaxFormRequiredAndBeneficiaryNameInvalid: TaxAndCashDashboardNoTaxFormRequiredAndBeneficiaryNameInvalid,
|
|
18206
18235
|
TaxAndCashDashboardNoTaxFormRequiredAndBeneficiaryNameInvalidUS: TaxAndCashDashboardNoTaxFormRequiredAndBeneficiaryNameInvalidUS,
|
|
18207
18236
|
TaxAndCashDashboardNoDocumentType: TaxAndCashDashboardNoDocumentType,
|
|
@@ -18248,6 +18277,31 @@ const ThresholdPayout = () => {
|
|
|
18248
18277
|
},
|
|
18249
18278
|
} }));
|
|
18250
18279
|
};
|
|
18280
|
+
const BelowPayoutThresholdFixedDay = () => {
|
|
18281
|
+
return (h("sqm-payout-details-card", { demoData: {
|
|
18282
|
+
states: {
|
|
18283
|
+
badgeStatus: "nextPayout",
|
|
18284
|
+
belowPayoutThreshold: true,
|
|
18285
|
+
},
|
|
18286
|
+
} }));
|
|
18287
|
+
};
|
|
18288
|
+
const BelowPayoutThresholdPayoutToday = () => {
|
|
18289
|
+
return (h("sqm-payout-details-card", { demoData: {
|
|
18290
|
+
states: {
|
|
18291
|
+
badgeStatus: "payoutToday",
|
|
18292
|
+
belowPayoutThreshold: true,
|
|
18293
|
+
},
|
|
18294
|
+
} }));
|
|
18295
|
+
};
|
|
18296
|
+
const BelowPayoutThresholdBalanceThreshold = () => {
|
|
18297
|
+
return (h("sqm-payout-details-card", { demoData: {
|
|
18298
|
+
states: {
|
|
18299
|
+
thresholdBalance: "50 USD",
|
|
18300
|
+
badgeStatus: "thresholdPayout",
|
|
18301
|
+
belowPayoutThreshold: true,
|
|
18302
|
+
},
|
|
18303
|
+
} }));
|
|
18304
|
+
};
|
|
18251
18305
|
const PaypalPayout = () => {
|
|
18252
18306
|
return (h("sqm-payout-details-card", { demoData: {
|
|
18253
18307
|
states: {
|
|
@@ -18269,6 +18323,9 @@ const PayoutDetailsCard = /*#__PURE__*/Object.freeze({
|
|
|
18269
18323
|
NextPayout: NextPayout,
|
|
18270
18324
|
PayoutToday: PayoutToday,
|
|
18271
18325
|
ThresholdPayout: ThresholdPayout,
|
|
18326
|
+
BelowPayoutThresholdFixedDay: BelowPayoutThresholdFixedDay,
|
|
18327
|
+
BelowPayoutThresholdPayoutToday: BelowPayoutThresholdPayoutToday,
|
|
18328
|
+
BelowPayoutThresholdBalanceThreshold: BelowPayoutThresholdBalanceThreshold,
|
|
18272
18329
|
PaypalPayout: PaypalPayout,
|
|
18273
18330
|
BadgeTextICUParsing: BadgeTextICUParsing
|
|
18274
18331
|
});
|
|
@@ -18304,6 +18361,13 @@ const Loading$e = () => (h("sqm-payout-status-alert", { demoData: { states: { ..
|
|
|
18304
18361
|
const Error$b = () => (h("sqm-payout-status-alert", { demoData: { states: { ...defaultProps$s, error: true } } }));
|
|
18305
18362
|
const NewPayeeReview = () => (h("sqm-payout-status-alert", { demoData: { states: { ...defaultProps$s, status: "NEW_PAYEE_REVIEW" } } }));
|
|
18306
18363
|
const PaymentHoldOnChange$1 = () => (h("sqm-payout-status-alert", { demoData: { states: { ...defaultProps$s, status: "PAYMENT_HOLD_ON_CHANGE" } } }));
|
|
18364
|
+
const BalanceUnderThreshold$1 = () => (h("sqm-payout-status-alert", { demoData: {
|
|
18365
|
+
states: {
|
|
18366
|
+
...defaultProps$s,
|
|
18367
|
+
status: "BALANCE_UNDER_THRESHOLD",
|
|
18368
|
+
minPayoutAmount: "USD50.00",
|
|
18369
|
+
},
|
|
18370
|
+
} }));
|
|
18307
18371
|
const BeneficiaryNameInvalid$1 = () => (h("sqm-payout-status-alert", { demoData: {
|
|
18308
18372
|
states: { ...defaultProps$s, status: "BENEFICIARY_NAME_INVALID" },
|
|
18309
18373
|
} }));
|
|
@@ -18330,6 +18394,7 @@ const PayoutStatusAlert = /*#__PURE__*/Object.freeze({
|
|
|
18330
18394
|
Error: Error$b,
|
|
18331
18395
|
NewPayeeReview: NewPayeeReview,
|
|
18332
18396
|
PaymentHoldOnChange: PaymentHoldOnChange$1,
|
|
18397
|
+
BalanceUnderThreshold: BalanceUnderThreshold$1,
|
|
18333
18398
|
BeneficiaryNameInvalid: BeneficiaryNameInvalid$1,
|
|
18334
18399
|
BeneficiaryNameMismatch: BeneficiaryNameMismatch$1,
|
|
18335
18400
|
BankTaxNameMismatch: BankTaxNameMismatch$1,
|
|
@@ -18930,7 +18995,9 @@ const mockPartnerData = {
|
|
|
18930
18995
|
payoutsAccount: {
|
|
18931
18996
|
hold: false,
|
|
18932
18997
|
holdReasons: [],
|
|
18933
|
-
balance: "0",
|
|
18998
|
+
balance: "$0.00",
|
|
18999
|
+
balanceAmount: 0,
|
|
19000
|
+
currencyCode: "USD",
|
|
18934
19001
|
},
|
|
18935
19002
|
};
|
|
18936
19003
|
const defaultText$1 = {
|
package/dist/esm/{sqm-user-info-form-view-b43a1729.js → sqm-user-info-form-view-81526655.js}
RENAMED
|
@@ -2,8 +2,8 @@ import { h } from './index-38ad4957.js';
|
|
|
2
2
|
import { i as intl } from './global-32d00a6e.js';
|
|
3
3
|
import { c as createStyleSheet } from './JSS-67b5cff8.js';
|
|
4
4
|
import { A as AsYouType } from './AsYouType-2d56519e.js';
|
|
5
|
-
import { f as formatErrorMessage, a as INDIRECT_TAX_PROVINCES, L as LoadingView, i as isValidI18nPhoneNumber, v as validateBillingField } from './subregions-
|
|
6
|
-
import { F as FORM_STEPS } from './data-
|
|
5
|
+
import { f as formatErrorMessage, a as INDIRECT_TAX_PROVINCES, L as LoadingView, i as isValidI18nPhoneNumber, v as validateBillingField } from './subregions-98789b46.js';
|
|
6
|
+
import { F as FORM_STEPS } from './data-0be04430.js';
|
|
7
7
|
|
|
8
8
|
const style = {
|
|
9
9
|
Description: {
|
|
@@ -59,6 +59,18 @@ function InvoiceTableView(props, children) {
|
|
|
59
59
|
children))));
|
|
60
60
|
}
|
|
61
61
|
|
|
62
|
+
const holdAlertContainer = (iconColor) => ({
|
|
63
|
+
marginLeft: "-20px",
|
|
64
|
+
"&::part(base)": {
|
|
65
|
+
maxWidth: "850px",
|
|
66
|
+
border: "none",
|
|
67
|
+
backgroundColor: "transparent",
|
|
68
|
+
color: "var(--sqm-text)",
|
|
69
|
+
},
|
|
70
|
+
"& sl-icon::part(base)": {
|
|
71
|
+
color: iconColor,
|
|
72
|
+
},
|
|
73
|
+
});
|
|
62
74
|
const style$1 = {
|
|
63
75
|
ErrorAlertContainer: {
|
|
64
76
|
"&::part(base)": {
|
|
@@ -73,30 +85,9 @@ const style$1 = {
|
|
|
73
85
|
maxWidth: "600px",
|
|
74
86
|
},
|
|
75
87
|
},
|
|
76
|
-
WarningHoldAlertContainer:
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
maxWidth: "850px",
|
|
80
|
-
border: "none",
|
|
81
|
-
backgroundColor: "transparent",
|
|
82
|
-
color: "var(--sqm-text)",
|
|
83
|
-
},
|
|
84
|
-
"& sl-icon::part(base)": {
|
|
85
|
-
color: "var(--sqm-warning-color-icon)",
|
|
86
|
-
},
|
|
87
|
-
},
|
|
88
|
-
ErrorHoldAlertContainer: {
|
|
89
|
-
marginLeft: "-20px",
|
|
90
|
-
"&::part(base)": {
|
|
91
|
-
maxWidth: "850px",
|
|
92
|
-
border: "none",
|
|
93
|
-
backgroundColor: "transparent",
|
|
94
|
-
color: "var(--sqm-text)",
|
|
95
|
-
},
|
|
96
|
-
"& sl-icon::part(base)": {
|
|
97
|
-
color: "var(--sqm-danger-color-icon)",
|
|
98
|
-
},
|
|
99
|
-
},
|
|
88
|
+
WarningHoldAlertContainer: holdAlertContainer("var(--sqm-warning-color-icon)"),
|
|
89
|
+
ErrorHoldAlertContainer: holdAlertContainer("var(--sqm-danger-color-icon)"),
|
|
90
|
+
InfoHoldAlertContainer: holdAlertContainer("var(--sqm-informative-color-icon)"),
|
|
100
91
|
ExpiringSoonAlertContainer: {
|
|
101
92
|
"&::part(base)": {
|
|
102
93
|
backgroundColor: "var(--sl-color-yellow-100)",
|
|
@@ -431,6 +422,18 @@ const TaxAndCashDashboardView = (props) => {
|
|
|
431
422
|
icon: "exclamation-triangle",
|
|
432
423
|
class: sheet.classes.WarningHoldAlertContainer,
|
|
433
424
|
};
|
|
425
|
+
case "BALANCE_UNDER_THRESHOLD":
|
|
426
|
+
return {
|
|
427
|
+
header: text.balanceUnderThresholdHeader,
|
|
428
|
+
description: intl.formatMessage({
|
|
429
|
+
id: "balanceUnderThresholdDescription",
|
|
430
|
+
defaultMessage: text.balanceUnderThresholdDescription,
|
|
431
|
+
}, { minPayoutAmount: states.minPayoutAmount }),
|
|
432
|
+
buttonText: null,
|
|
433
|
+
alertType: "info",
|
|
434
|
+
icon: "info-circle",
|
|
435
|
+
class: sheet.classes.InfoHoldAlertContainer,
|
|
436
|
+
};
|
|
434
437
|
case "PAYMENT_HOLD_ON_CHANGE":
|
|
435
438
|
return {
|
|
436
439
|
header: text.paymentHoldOnChangeHeader,
|
|
@@ -633,6 +633,32 @@ function getCountryObj({ countryCode, locale, }) {
|
|
|
633
633
|
displayName,
|
|
634
634
|
};
|
|
635
635
|
}
|
|
636
|
+
/** The minimum balance Impact requires before it will issue a payout, e.g. "USD50.00". */
|
|
637
|
+
function formatPayoutThreshold(publisher) {
|
|
638
|
+
var _a, _b;
|
|
639
|
+
const threshold = (_a = publisher === null || publisher === void 0 ? void 0 : publisher.withdrawalSettings) === null || _a === void 0 ? void 0 : _a.paymentThreshold;
|
|
640
|
+
if (!threshold)
|
|
641
|
+
return undefined;
|
|
642
|
+
return `${(_b = publisher === null || publisher === void 0 ? void 0 : publisher.currency) !== null && _b !== void 0 ? _b : ""}${threshold}`;
|
|
643
|
+
}
|
|
644
|
+
/** `payoutsAccount.balance` is a formatted string; only `balanceAmount` (minor units) is comparable. */
|
|
645
|
+
function isBalanceUnderPayoutThreshold(publisher) {
|
|
646
|
+
var _a;
|
|
647
|
+
const rawThreshold = (_a = publisher === null || publisher === void 0 ? void 0 : publisher.withdrawalSettings) === null || _a === void 0 ? void 0 : _a.paymentThreshold;
|
|
648
|
+
const account = publisher === null || publisher === void 0 ? void 0 : publisher.payoutsAccount;
|
|
649
|
+
if (!rawThreshold || !account)
|
|
650
|
+
return false;
|
|
651
|
+
const threshold = Number(rawThreshold);
|
|
652
|
+
if (!Number.isFinite(threshold) || !Number.isFinite(account.balanceAmount))
|
|
653
|
+
return false;
|
|
654
|
+
const currency = account.currencyCode || (publisher === null || publisher === void 0 ? void 0 : publisher.currency);
|
|
655
|
+
if (!currency)
|
|
656
|
+
return false;
|
|
657
|
+
const scale = 10 **
|
|
658
|
+
new Intl.NumberFormat("en-US", { style: "currency", currency })
|
|
659
|
+
.resolvedOptions().maximumFractionDigits;
|
|
660
|
+
return account.balanceAmount < Math.round(threshold * scale);
|
|
661
|
+
}
|
|
636
662
|
|
|
637
663
|
const style = {
|
|
638
664
|
Container: {
|
|
@@ -1052,4 +1078,4 @@ const ADDRESS_REGIONS = {
|
|
|
1052
1078
|
},
|
|
1053
1079
|
};
|
|
1054
1080
|
|
|
1055
|
-
export { ADDRESS_REGIONS as A, INDIRECT_TAX_SPAIN_REGIONS as I, LoadingView as L, INDIRECT_TAX_PROVINCES as a,
|
|
1081
|
+
export { ADDRESS_REGIONS as A, INDIRECT_TAX_SPAIN_REGIONS as I, LoadingView as L, INDIRECT_TAX_PROVINCES as a, formatPayoutThreshold as b, isBalanceUnderPayoutThreshold as c, validTaxDocument as d, toDomesticNumber as e, formatErrorMessage as f, getCountryObj as g, isValidI18nPhoneNumber as i, objectIsFull as o, taxTypeToName as t, validateBillingField as v };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { k as useState, f as useEffect, m as useRef, u as useMemo } from './dom-context-hooks.module-50442785.js';
|
|
2
2
|
import { d as dist, J, $ as $e, g as getEnvironmentSDK, w as wn, L, F as Fn, q as Pn, r as $n } from './index.module-02cb914c.js';
|
|
3
3
|
import { j as jsonpointer } from './jsonpointer-388a7082.js';
|
|
4
|
-
import { I as INDIRECT_TAX_SPAIN_REGIONS, a as INDIRECT_TAX_PROVINCES, g as getCountryObj,
|
|
5
|
-
import { a as TAX_FORM_CONTEXT_NAMESPACE, U as USER_FORM_CONTEXT_NAMESPACE, d as COUNTRIES_QUERY_NAMESPACE, T as TAX_CONTEXT_NAMESPACE, c as USER_QUERY_NAMESPACE } from './data-
|
|
4
|
+
import { b as formatPayoutThreshold, c as isBalanceUnderPayoutThreshold, I as INDIRECT_TAX_SPAIN_REGIONS, a as INDIRECT_TAX_PROVINCES, g as getCountryObj, d as validTaxDocument } from './subregions-98789b46.js';
|
|
5
|
+
import { a as TAX_FORM_CONTEXT_NAMESPACE, U as USER_FORM_CONTEXT_NAMESPACE, d as COUNTRIES_QUERY_NAMESPACE, T as TAX_CONTEXT_NAMESPACE, c as USER_QUERY_NAMESPACE } from './data-0be04430.js';
|
|
6
6
|
import { T as TAX_FORM_UPDATED_EVENT_KEY } from './eventKeys-f76b6a03.js';
|
|
7
7
|
|
|
8
8
|
var toArray = function toArray(a) {
|
|
@@ -975,9 +975,16 @@ const GET_USER_STATUS = dist.gql `
|
|
|
975
975
|
connected
|
|
976
976
|
publisher {
|
|
977
977
|
id
|
|
978
|
+
currency
|
|
979
|
+
withdrawalSettings {
|
|
980
|
+
paymentThreshold
|
|
981
|
+
}
|
|
978
982
|
payoutsAccount {
|
|
979
983
|
hold
|
|
980
984
|
holdReasons
|
|
985
|
+
balance
|
|
986
|
+
balanceAmount
|
|
987
|
+
currencyCode
|
|
981
988
|
}
|
|
982
989
|
}
|
|
983
990
|
}
|
|
@@ -1004,7 +1011,22 @@ const GET_TAX_SETTING = dist.gql `
|
|
|
1004
1011
|
}
|
|
1005
1012
|
}
|
|
1006
1013
|
`;
|
|
1014
|
+
/** Transient holds that clear automatically, so a balance under the minimum explains the wait better. */
|
|
1015
|
+
const DISPLACEABLE_STATUSES = [
|
|
1016
|
+
"DONE",
|
|
1017
|
+
"NEW_PAYEE_REVIEW",
|
|
1018
|
+
"PAYMENT_HOLD_ON_CHANGE",
|
|
1019
|
+
];
|
|
1007
1020
|
function getStatus(data) {
|
|
1021
|
+
var _a;
|
|
1022
|
+
const status = getHoldStatus(data);
|
|
1023
|
+
const publisher = (_a = data.user.impactConnection) === null || _a === void 0 ? void 0 : _a.publisher;
|
|
1024
|
+
return DISPLACEABLE_STATUSES.includes(status) &&
|
|
1025
|
+
isBalanceUnderPayoutThreshold(publisher)
|
|
1026
|
+
? "BALANCE_UNDER_THRESHOLD"
|
|
1027
|
+
: status;
|
|
1028
|
+
}
|
|
1029
|
+
function getHoldStatus(data) {
|
|
1008
1030
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x;
|
|
1009
1031
|
const account = (_b = (_a = data.user.impactConnection) === null || _a === void 0 ? void 0 : _a.publisher) === null || _b === void 0 ? void 0 : _b.payoutsAccount;
|
|
1010
1032
|
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) => {
|
|
@@ -1047,7 +1069,7 @@ function getStatus(data) {
|
|
|
1047
1069
|
return "DONE";
|
|
1048
1070
|
}
|
|
1049
1071
|
function usePayoutStatus(props) {
|
|
1050
|
-
var _a;
|
|
1072
|
+
var _a, _b, _c;
|
|
1051
1073
|
const { type } = getEnvironmentSDK();
|
|
1052
1074
|
const { loading, data, errors, refetch } = wn(GET_USER_STATUS, {});
|
|
1053
1075
|
const { data: taxSettingRes } = wn(GET_TAX_SETTING, {});
|
|
@@ -1097,6 +1119,7 @@ function usePayoutStatus(props) {
|
|
|
1097
1119
|
status,
|
|
1098
1120
|
error: !!errors,
|
|
1099
1121
|
enforceUsTaxComplianceOption,
|
|
1122
|
+
minPayoutAmount: formatPayoutThreshold((_c = (_b = data === null || data === void 0 ? void 0 : data.user) === null || _b === void 0 ? void 0 : _b.impactConnection) === null || _c === void 0 ? void 0 : _c.publisher),
|
|
1100
1123
|
},
|
|
1101
1124
|
data: { type },
|
|
1102
1125
|
text: props.getTextProps(),
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var __makeTemplateObject=this&&this.__makeTemplateObject||function(n,e){if(Object.defineProperty){Object.defineProperty(n,"raw",{value:e})}else{n.raw=e}return n};import{d as dist}from"./index.module-02cb914c.js";var TAX_CONTEXT_NAMESPACE="sq:tax-and-cash";var TAX_FORM_CONTEXT_NAMESPACE="sq:tax-form-context";var USER_QUERY_NAMESPACE="sq:user-info-query";var USER_FORM_CONTEXT_NAMESPACE="sq:user-form-context";var FINANCE_NETWORK_SETTINGS_NAMESPACE="sq:finance-network-settings";var COUNTRIES_NAMESPACE="sq:countries:list";var SORTED_COUNTRIES_NAMESPACE="sq:countries:sorted";var COUNTRIES_QUERY_NAMESPACE="sq:countries:query";var CURRENCIES_NAMESPACE="sq:currencies:list";var CURRENCIES_QUERY_NAMESPACE="sq:currencies:query";var GET_USER=dist.gql(templateObject_1||(templateObject_1=__makeTemplateObject(["\n query getUserTaxInfo {\n user: viewer {\n ... on User {\n id\n accountId\n firstName\n lastName\n email\n countryCode\n customFields\n rewards(limit: 1000) {\n data {\n statuses\n partnerFundsTransfer {\n id\n status\n dateScheduled\n dateCreated\n dateTransferred\n }\n }\n }\n managedIdentity {\n uid\n email\n emailVerified\n }\n impactConnection {\n connected\n connectionStatus\n user {\n firstName\n lastName\n }\n publisher {\n id\n brandedSignup\n countryCode\n currency\n billingAddress\n billingCity\n billingState\n billingCountryCode\n billingPostalCode\n phoneNumberCountryCode\n phoneNumber\n taxInformation {\n indirectTaxId\n indirectTaxCountryCode\n indirectTaxRegion\n additionalTaxId\n withholdingTaxId\n withholdingTaxCountryCode\n }\n requiredTaxDocumentType\n currentTaxDocument {\n status\n type\n dateCreated\n }\n withdrawalSettings {\n paymentMethod\n paypalEmailAddress\n bankCountry\n bankAccountNumber\n paymentSchedulingType\n paymentThreshold\n paymentDay\n }\n payoutsAccount {\n hold\n holdReasons\n balance\n balanceAmount\n currencyCode\n }\n }\n }\n }\n }\n }\n"],["\n query getUserTaxInfo {\n user: viewer {\n ... on User {\n id\n accountId\n firstName\n lastName\n email\n countryCode\n customFields\n rewards(limit: 1000) {\n data {\n statuses\n partnerFundsTransfer {\n id\n status\n dateScheduled\n dateCreated\n dateTransferred\n }\n }\n }\n managedIdentity {\n uid\n email\n emailVerified\n }\n impactConnection {\n connected\n connectionStatus\n user {\n firstName\n lastName\n }\n publisher {\n id\n brandedSignup\n countryCode\n currency\n billingAddress\n billingCity\n billingState\n billingCountryCode\n billingPostalCode\n phoneNumberCountryCode\n phoneNumber\n taxInformation {\n indirectTaxId\n indirectTaxCountryCode\n indirectTaxRegion\n additionalTaxId\n withholdingTaxId\n withholdingTaxCountryCode\n }\n requiredTaxDocumentType\n currentTaxDocument {\n status\n type\n dateCreated\n }\n withdrawalSettings {\n paymentMethod\n paypalEmailAddress\n bankCountry\n bankAccountNumber\n paymentSchedulingType\n paymentThreshold\n paymentDay\n }\n payoutsAccount {\n hold\n holdReasons\n balance\n balanceAmount\n currencyCode\n }\n }\n }\n }\n }\n }\n"])));var GET_COUNTRIES=dist.gql(templateObject_2||(templateObject_2=__makeTemplateObject(["\n query getCountries {\n impactPayoutCountries(limit: 1000) {\n data {\n countryCode\n displayName\n }\n }\n }\n"],["\n query getCountries {\n impactPayoutCountries(limit: 1000) {\n data {\n countryCode\n displayName\n }\n }\n }\n"])));var GET_CURRENCIES=dist.gql(templateObject_3||(templateObject_3=__makeTemplateObject(["\n query currencies($locale: RSLocale) {\n currencies(limit: 300) {\n data {\n displayName(locale: $locale)\n currencyCode\n }\n }\n }\n"],["\n query currencies($locale: RSLocale) {\n currencies(limit: 300) {\n data {\n displayName(locale: $locale)\n currencyCode\n }\n }\n }\n"])));var GET_FINANCE_NETWORK_SETTINGS=dist.gql(templateObject_4||(templateObject_4=__makeTemplateObject(["\n query impactFinanceNetworkSettings(\n $filter: ImpactFinanceNetworkSettingsFilterInput\n ) {\n impactFinanceNetworkSettings(filter: $filter, limit: 1000) {\n data {\n countryCode\n currency\n defaultFinancePaymentMethodId\n thresholdOptions\n withdrawalSettingId\n internationalEftFee\n foreignFxFee\n defaultFxFee\n }\n totalCount\n }\n }\n"],["\n query impactFinanceNetworkSettings(\n $filter: ImpactFinanceNetworkSettingsFilterInput\n ) {\n impactFinanceNetworkSettings(filter: $filter, limit: 1000) {\n data {\n countryCode\n currency\n defaultFinancePaymentMethodId\n thresholdOptions\n withdrawalSettingId\n internationalEftFee\n foreignFxFee\n defaultFxFee\n }\n totalCount\n }\n }\n"])));var FORM_STEPS=4;export{CURRENCIES_NAMESPACE as C,FORM_STEPS as F,GET_USER as G,SORTED_COUNTRIES_NAMESPACE as S,TAX_CONTEXT_NAMESPACE as T,USER_FORM_CONTEXT_NAMESPACE as U,TAX_FORM_CONTEXT_NAMESPACE as a,COUNTRIES_NAMESPACE as b,USER_QUERY_NAMESPACE as c,COUNTRIES_QUERY_NAMESPACE as d,GET_COUNTRIES as e,FINANCE_NETWORK_SETTINGS_NAMESPACE as f,GET_FINANCE_NETWORK_SETTINGS as g,CURRENCIES_QUERY_NAMESPACE as h,GET_CURRENCIES as i};var templateObject_1,templateObject_2,templateObject_3,templateObject_4;
|