@saasquatch/mint-components 1.12.0-12 → 1.12.0-13

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.
Files changed (37) hide show
  1. package/dist/cjs/sqm-banking-info-form_16.cjs.entry.js +33 -13
  2. package/dist/cjs/sqm-code-verification.cjs.entry.js +1 -1
  3. package/dist/cjs/{sqm-invoice-table-view-301eed81.js → sqm-invoice-table-view-e92c557a.js} +1 -0
  4. package/dist/cjs/sqm-stencilbook.cjs.entry.js +2 -1
  5. package/dist/collection/components/sqm-widget-verification/sqm-code-verification/sqm-code-verification-view.js +1 -1
  6. package/dist/collection/components/tax-and-cash/BankingForm.stories.js +1 -0
  7. package/dist/collection/components/tax-and-cash/TaxForm.stories.js +1 -0
  8. package/dist/collection/components/tax-and-cash/sqm-banking-info-form/sqm-banking-info-form.js +28 -6
  9. package/dist/collection/components/tax-and-cash/sqm-banking-info-form/useBankingInfoForm.js +3 -1
  10. package/dist/collection/components/tax-and-cash/sqm-tax-and-cash-dashboard/sqm-tax-and-cash-dashboard-view.js +4 -5
  11. package/dist/esm/sqm-banking-info-form_16.entry.js +33 -13
  12. package/dist/esm/sqm-code-verification.entry.js +1 -1
  13. package/dist/esm/{sqm-invoice-table-view-1f26f252.js → sqm-invoice-table-view-c184248a.js} +1 -0
  14. package/dist/esm/sqm-stencilbook.entry.js +2 -1
  15. package/dist/esm-es5/sqm-banking-info-form_16.entry.js +1 -1
  16. package/dist/esm-es5/sqm-code-verification.entry.js +1 -1
  17. package/dist/esm-es5/sqm-invoice-table-view-c184248a.js +1 -0
  18. package/dist/esm-es5/sqm-stencilbook.entry.js +1 -1
  19. package/dist/mint-components/mint-components.esm.js +1 -1
  20. package/dist/mint-components/{p-b24b4d75.entry.js → p-02892b2a.entry.js} +1 -1
  21. package/dist/mint-components/p-13ce67a3.js +1 -0
  22. package/dist/mint-components/{p-f7902f51.entry.js → p-4e21de5f.entry.js} +2 -2
  23. package/dist/mint-components/{p-9ddcfcd7.entry.js → p-8c26c4ce.entry.js} +3 -3
  24. package/dist/mint-components/{p-f7493ca6.system.entry.js → p-8fa2809f.system.entry.js} +1 -1
  25. package/dist/mint-components/{p-c5f84a95.system.entry.js → p-9266a8fc.system.entry.js} +1 -1
  26. package/dist/mint-components/p-b7836281.system.js +1 -0
  27. package/dist/mint-components/p-c520d10d.system.entry.js +1 -0
  28. package/dist/mint-components/p-ca809fdd.system.js +1 -1
  29. package/dist/types/components/tax-and-cash/sqm-banking-info-form/sqm-banking-info-form-view.d.ts +2 -0
  30. package/docs/docs.docx +0 -0
  31. package/docs/picklesdoc--2024-01-15--11-20-00.xlsx +0 -0
  32. package/docs/picklesdoc--2024-01-15--11-24-04.xlsx +0 -0
  33. package/package.json +1 -1
  34. package/dist/esm-es5/sqm-invoice-table-view-1f26f252.js +0 -1
  35. package/dist/mint-components/p-635f1cf5.system.entry.js +0 -1
  36. package/dist/mint-components/p-78ec0d48.js +0 -1
  37. package/dist/mint-components/p-7d79f697.system.js +0 -1
@@ -16,7 +16,7 @@ const useChildElements = require('./useChildElements-410d2435.js');
16
16
  const luxon = require('./luxon-05098e19.js');
17
17
  const useReferralTable = require('./useReferralTable-824ac152.js');
18
18
  const utils = require('./utils-6847bc06.js');
19
- const sqmInvoiceTableView = require('./sqm-invoice-table-view-301eed81.js');
19
+ const sqmInvoiceTableView = require('./sqm-invoice-table-view-e92c557a.js');
20
20
  const keys = require('./keys-cff24974.js');
21
21
  const usePayoutStatus = require('./usePayoutStatus-5ac536a3.js');
22
22
  const extractProps = require('./extractProps-fd93ba62.js');
@@ -1190,7 +1190,8 @@ function useBankingInfoForm(props) {
1190
1190
  });
1191
1191
  setShowVerification(false);
1192
1192
  }
1193
- await runMutation(formData, token);
1193
+ if (token)
1194
+ await runMutation(formData, token);
1194
1195
  };
1195
1196
  const onVerification = async (token) => {
1196
1197
  host.dispatchEvent(new CustomEvent(keys.VERIFICATION_EVENT_KEY, {
@@ -1223,6 +1224,7 @@ function useBankingInfoForm(props) {
1223
1224
  onBack: () => setStep("/dashboard"),
1224
1225
  setCountrySearch,
1225
1226
  onVerification,
1227
+ onVerificationHide: () => onVerification(null),
1226
1228
  },
1227
1229
  states: {
1228
1230
  showVerification,
@@ -1556,15 +1558,33 @@ const BankingInfoForm = class {
1556
1558
  bitset: props.states.bitset,
1557
1559
  formMap,
1558
1560
  });
1559
- const searchStyle = {
1561
+ const style = {
1562
+ Dialog: {
1563
+ "&::part(panel)": {
1564
+ maxWidth: "420px",
1565
+ },
1566
+ "&::part(close-button)": {
1567
+ marginBottom: "var(--sl-spacing-xx-large)",
1568
+ },
1569
+ "&::part(body)": {
1570
+ padding: "0 var(--sl-spacing-x-large) 0 var(--sl-spacing-x-large)",
1571
+ fontSize: "var(--sl-font-size-small)",
1572
+ },
1573
+ "&::part(footer)": {
1574
+ display: "flex",
1575
+ flexDirection: "column",
1576
+ gap: "var(--sl-spacing-small)",
1577
+ marginBottom: "var(--sl-spacing-xx-small)",
1578
+ alignItems: "center",
1579
+ flex: "1",
1580
+ },
1581
+ },
1560
1582
  SearchInput: {
1561
1583
  padding: "var(--sl-spacing-x-small)",
1562
1584
  },
1563
1585
  };
1564
- if (props.states.isPartner && props.states.showVerification) {
1565
- return (index.h("sqm-code-verification", { onVerification: props.callbacks.onVerification }));
1566
- }
1567
- return (index.h(index.Host, null, index.h(BankingInfoFormView, { callbacks: props.callbacks, text: props.text, states: props.states, refs: props.refs, slots: {
1586
+ const sheet = JSS.createStyleSheet(style);
1587
+ return (index.h(index.Host, null, props.states.isPartner && props.states.showVerification ? (index.h("sl-dialog", { class: sheet.classes.Dialog, open: true, "onSl-hide": props.callbacks.onVerificationHide }, index.h("sqm-code-verification", { onVerification: props.callbacks.onVerification }))) : null, index.h(BankingInfoFormView, { callbacks: props.callbacks, text: props.text, states: props.states, refs: props.refs, slots: {
1568
1588
  formInputsSlot: inputFields === null || inputFields === void 0 ? void 0 : inputFields.map(({ input }) => input),
1569
1589
  countryInputSlot: (index.h("sl-select", Object.assign({ label: props.text.bankLocationLabel, disabled: props.states.saveLoading, required: true, name: "/bankCountry", id: "bankCountry", value: props.states.formState.bankCountry || "", "onSl-select": (e) => { var _a, _b; return props.callbacks.setBankCountry((_b = (_a = e.detail) === null || _a === void 0 ? void 0 : _a.item) === null || _b === void 0 ? void 0 : _b.value); } }, (((_a = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _a === void 0 ? void 0 : _a.bankCountry) && {
1570
1590
  class: "error-input",
@@ -1572,7 +1592,7 @@ const BankingInfoForm = class {
1572
1592
  type: (_c = (_b = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _b === void 0 ? void 0 : _b.bankCountry) === null || _c === void 0 ? void 0 : _c.type,
1573
1593
  label: props.text.bankLocationLabel,
1574
1594
  }),
1575
- })), index.h("sl-input", { disabled: props.states.saveLoading, class: searchStyle.SearchInput, placeholder: this.searchForCountryText, onKeyDown: (e) => {
1595
+ })), index.h("sl-input", { disabled: props.states.saveLoading, class: sheet.classes.SearchInput, placeholder: this.searchForCountryText, onKeyDown: (e) => {
1576
1596
  // Stop shoelace intercepting key presses
1577
1597
  e.stopPropagation();
1578
1598
  }, "onSl-input": (e) => {
@@ -1688,6 +1708,7 @@ function useDemoBankingInfoForm(props) {
1688
1708
  hasPayPal: true,
1689
1709
  },
1690
1710
  callbacks: {
1711
+ onVerificationHide: () => { },
1691
1712
  onSubmit: async () => {
1692
1713
  setStep("/dashboard");
1693
1714
  },
@@ -5050,6 +5071,7 @@ const style$5 = {
5050
5071
  PageDescriptionText: {
5051
5072
  color: "var(--sl-color-neutral-500)",
5052
5073
  fontSize: "var(--sl-font-size-medium)",
5074
+ marginTop: "0",
5053
5075
  },
5054
5076
  Dialog: {
5055
5077
  "&::part(panel)": {
@@ -5218,20 +5240,18 @@ const TaxAndCashDashboardView = (props) => {
5218
5240
  index.h("strong", null, text.error.generalTitle),
5219
5241
  index.h("br", null),
5220
5242
  text.error.generalDescription)),
5221
- states.payoutStatus && states.payoutStatus !== "DONE" && (index.h("sl-alert", { exportparts: "base: alert-base, icon:alert-icon", name: (_b = getAlert(states.payoutStatus)) === null || _b === void 0 ? void 0 : _b.alertType, open: true, class: (_c = getAlert(states.payoutStatus)) === null || _c === void 0 ? void 0 : _c.class },
5243
+ getAlert(states.payoutStatus) && (index.h("sl-alert", { exportparts: "base: alert-base, icon:alert-icon", name: (_b = getAlert(states.payoutStatus)) === null || _b === void 0 ? void 0 : _b.alertType, open: true, class: (_c = getAlert(states.payoutStatus)) === null || _c === void 0 ? void 0 : _c.class },
5222
5244
  index.h("sl-icon", { slot: "icon", name: (_d = getAlert(states.payoutStatus)) === null || _d === void 0 ? void 0 : _d.icon }),
5223
5245
  index.h("strong", null, getAlert(states.payoutStatus).header),
5224
5246
  index.h("p", { style: { margin: "0" } }, getAlert(states.payoutStatus).description),
5225
- getAlert(states.payoutStatus).buttonText && (index.h("sl-button", { style: { marginTop: "var(--sl-spacing-x-small)" }, type: "default", loading: states.loading,
5226
- //AL: TODO hooks
5227
- onClick: () => callbacks.onClick }, getAlert(states.payoutStatus).buttonText)))),
5247
+ getAlert(states.payoutStatus).buttonText && (index.h("sl-button", { style: { marginTop: "var(--sl-spacing-x-small)" }, type: "default", loading: states.veriffLoading, onClick: () => callbacks.onVerifyClick() }, getAlert(states.payoutStatus).buttonText)))),
5228
5248
  index.h("sl-dialog", { label: text.replaceTaxFormModalHeader, class: sheet$4.classes.Dialog, open: states.showNewFormDialog, "onSl-hide": callbacks.onNewFormCancel },
5229
5249
  index.h("p", null, text.replaceTaxFormModalBodyText),
5230
5250
  index.h("sl-button", { slot: "footer", type: "primary", class: sheet$4.classes.DialogButton, onClick: callbacks.onNewFormClick }, text.newFormButton),
5231
5251
  index.h("sl-button", { slot: "footer", type: "default", class: sheet$4.classes.DialogButton, onClick: callbacks.onNewFormCancel }, text.cancelButton)),
5232
5252
  states.status === "INACTIVE" && alertMap[states.status],
5233
5253
  index.h("div", null,
5234
- index.h("h3", null, text.bankingInformationSectionHeader),
5254
+ index.h("h3", { style: { marginBottom: "0" } }, text.bankingInformationSectionHeader),
5235
5255
  index.h("p", { class: sheet$4.classes.PageDescriptionText }, text.taxAndPayoutsDescription),
5236
5256
  index.h("div", { class: sheet$4.classes.BankingInformationContainer },
5237
5257
  slots.payoutDetailsCardSlot,
@@ -19,7 +19,7 @@ const style = {
19
19
  display: "flex",
20
20
  flexDirection: "column",
21
21
  gap: "var(--sl-spacing-medium)",
22
- maxWidth: "515px",
22
+ maxWidth: "550px",
23
23
  },
24
24
  HeaderContainer: {
25
25
  display: "flex",
@@ -714,6 +714,7 @@ const stepFourProps = {
714
714
  },
715
715
  },
716
716
  callbacks: {
717
+ onVerificationHide: () => { },
717
718
  onVerification: () => { },
718
719
  onSubmit: async () => console.log("Submit"),
719
720
  setPaymentMethodChecked: () => { },
@@ -30,7 +30,7 @@ const sqmPortalResetPasswordView = require('./sqm-portal-reset-password-view-96f
30
30
  const sqmPortalVerifyEmailView = require('./sqm-portal-verify-email-view-7ffcc0d4.js');
31
31
  const ShadowViewAddon = require('./ShadowViewAddon-040cffad.js');
32
32
  const sqmPortalContainerView = require('./sqm-portal-container-view-990a85a3.js');
33
- const sqmInvoiceTableView = require('./sqm-invoice-table-view-301eed81.js');
33
+ const sqmInvoiceTableView = require('./sqm-invoice-table-view-e92c557a.js');
34
34
 
35
35
  /**
36
36
  * lodash (Custom Build) <https://lodash.com/>
@@ -14404,6 +14404,7 @@ const bankingFormProps = {
14404
14404
  loadingError: false,
14405
14405
  },
14406
14406
  callbacks: {
14407
+ onVerificationHide: () => { },
14407
14408
  onVerification: () => { },
14408
14409
  onSubmit: async () => console.log("Submit"),
14409
14410
  setPaymentMethodChecked: () => { },
@@ -8,7 +8,7 @@ const style = {
8
8
  display: "flex",
9
9
  flexDirection: "column",
10
10
  gap: "var(--sl-spacing-medium)",
11
- maxWidth: "515px",
11
+ maxWidth: "550px",
12
12
  },
13
13
  HeaderContainer: {
14
14
  display: "flex",
@@ -21,6 +21,7 @@ const bankingFormProps = {
21
21
  loadingError: false,
22
22
  },
23
23
  callbacks: {
24
+ onVerificationHide: () => { },
24
25
  onVerification: () => { },
25
26
  onSubmit: async () => console.log("Submit"),
26
27
  setPaymentMethodChecked: () => { },
@@ -210,6 +210,7 @@ const stepFourProps = {
210
210
  },
211
211
  },
212
212
  callbacks: {
213
+ onVerificationHide: () => { },
213
214
  onVerification: () => { },
214
215
  onSubmit: async () => console.log("Submit"),
215
216
  setPaymentMethodChecked: () => { },
@@ -10,6 +10,7 @@ import { getFormMap } from "./formDefinitions";
10
10
  import { mockPaymentOptions } from "./mockData";
11
11
  import { BankingInfoFormView, } from "./sqm-banking-info-form-view";
12
12
  import { getFormInputs, paypalFeeMap, useBankingInfoForm, } from "./useBankingInfoForm";
13
+ import { createStyleSheet } from "../../../styling/JSS";
13
14
  /**
14
15
  * @uiName Banking Information Form
15
16
  * @exampleGroup Common Components
@@ -308,15 +309,35 @@ export class BankingInfoForm {
308
309
  bitset: props.states.bitset,
309
310
  formMap,
310
311
  });
311
- const searchStyle = {
312
+ const style = {
313
+ Dialog: {
314
+ "&::part(panel)": {
315
+ maxWidth: "420px",
316
+ },
317
+ "&::part(close-button)": {
318
+ marginBottom: "var(--sl-spacing-xx-large)",
319
+ },
320
+ "&::part(body)": {
321
+ padding: "0 var(--sl-spacing-x-large) 0 var(--sl-spacing-x-large)",
322
+ fontSize: "var(--sl-font-size-small)",
323
+ },
324
+ "&::part(footer)": {
325
+ display: "flex",
326
+ flexDirection: "column",
327
+ gap: "var(--sl-spacing-small)",
328
+ marginBottom: "var(--sl-spacing-xx-small)",
329
+ alignItems: "center",
330
+ flex: "1",
331
+ },
332
+ },
312
333
  SearchInput: {
313
334
  padding: "var(--sl-spacing-x-small)",
314
335
  },
315
336
  };
316
- if (props.states.isPartner && props.states.showVerification) {
317
- return (h("sqm-code-verification", { onVerification: props.callbacks.onVerification }));
318
- }
337
+ const sheet = createStyleSheet(style);
319
338
  return (h(Host, null,
339
+ props.states.isPartner && props.states.showVerification ? (h("sl-dialog", { class: sheet.classes.Dialog, open: true, "onSl-hide": props.callbacks.onVerificationHide },
340
+ h("sqm-code-verification", { onVerification: props.callbacks.onVerification }))) : null,
320
341
  h(BankingInfoFormView, { callbacks: props.callbacks, text: props.text, states: props.states, refs: props.refs, slots: {
321
342
  formInputsSlot: inputFields === null || inputFields === void 0 ? void 0 : inputFields.map(({ input }) => input),
322
343
  countryInputSlot: (h("sl-select", Object.assign({ label: props.text.bankLocationLabel, disabled: props.states.saveLoading, required: true, name: "/bankCountry", id: "bankCountry", value: props.states.formState.bankCountry || "", "onSl-select": (e) => { var _a, _b; return props.callbacks.setBankCountry((_b = (_a = e.detail) === null || _a === void 0 ? void 0 : _a.item) === null || _b === void 0 ? void 0 : _b.value); } }, (((_a = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _a === void 0 ? void 0 : _a.bankCountry) && {
@@ -326,7 +347,7 @@ export class BankingInfoForm {
326
347
  label: props.text.bankLocationLabel,
327
348
  }),
328
349
  })),
329
- h("sl-input", { disabled: props.states.saveLoading, class: searchStyle.SearchInput, placeholder: this.searchForCountryText, onKeyDown: (e) => {
350
+ h("sl-input", { disabled: props.states.saveLoading, class: sheet.classes.SearchInput, placeholder: this.searchForCountryText, onKeyDown: (e) => {
330
351
  // Stop shoelace intercepting key presses
331
352
  e.stopPropagation();
332
353
  }, "onSl-input": (e) => {
@@ -1500,7 +1521,7 @@ export class BankingInfoForm {
1500
1521
  "mutable": false,
1501
1522
  "complexType": {
1502
1523
  "original": "DemoData<BankingInfoFormViewProps>",
1503
- "resolved": "{ states?: { showVerification: boolean; step?: string; locale?: string; loading: boolean; saveLoading?: boolean; disabled: boolean; saveDisabled: boolean; hideSteps?: boolean; hasPayPal: boolean; hideBanking?: boolean; hidePayPal?: boolean; hideBalanceThreshold?: boolean; hideFixedDay?: boolean; hideBackButton: boolean; feeCap?: string; isPartner: boolean; paymentMethodFeeLabel?: string; loadingError: boolean; formState: BankingInfoFormData & { paymentMethodChecked?: \"toBankAccount\" | \"toPayPalAccount\"; paymentScheduleChecked?: \"BALANCE_THRESHOLD\" | \"FIXED_DAY\"; errors?: { general?: boolean; inputErrors?: { [field: string]: { type: \"required\" | \"invalid\"; }; }; }; }; bitset?: number; currency?: string; thresholds: string[]; countries?: { countryCode: string; displayName: string; }[]; allCountries?: { countryCode: string; displayName: string; }[]; currentPaymentOption?: any; showInputs?: boolean; bankCountry?: string; countrySearch?: string; }; slots?: { formInputsSlot?: VNode[]; countryInputSlot?: VNode; paymentMethodSlot?: VNode; paymentThresholdSelectSlot?: VNode; paymentFixedDaySelectSlot?: VNode; paypalInputSlot?: VNode; }; refs?: { formRef: any; }; }",
1524
+ "resolved": "{ states?: { showVerification: boolean; step?: string; locale?: string; loading: boolean; saveLoading?: boolean; disabled: boolean; saveDisabled: boolean; hideSteps?: boolean; hasPayPal: boolean; hideBanking?: boolean; hidePayPal?: boolean; hideBalanceThreshold?: boolean; hideFixedDay?: boolean; hideBackButton: boolean; feeCap?: string; isPartner: boolean; paymentMethodFeeLabel?: string; loadingError: boolean; formState: BankingInfoFormData & { paymentMethodChecked?: \"toBankAccount\" | \"toPayPalAccount\"; paymentScheduleChecked?: \"BALANCE_THRESHOLD\" | \"FIXED_DAY\"; errors?: { general?: boolean; inputErrors?: { [field: string]: { type: \"required\" | \"invalid\"; }; }; }; }; bitset?: number; currency?: string; thresholds: string[]; countries?: { countryCode: string; displayName: string; }[]; allCountries?: { countryCode: string; displayName: string; }[]; currentPaymentOption?: any; showInputs?: boolean; bankCountry?: string; countrySearch?: string; }; slots?: { verificationDialogSlot?: VNode; formInputsSlot?: VNode[]; countryInputSlot?: VNode; paymentMethodSlot?: VNode; paymentThresholdSelectSlot?: VNode; paymentFixedDaySelectSlot?: VNode; paypalInputSlot?: VNode; }; refs?: { formRef: any; }; }",
1504
1525
  "references": {
1505
1526
  "DemoData": {
1506
1527
  "location": "import",
@@ -1611,6 +1632,7 @@ function useDemoBankingInfoForm(props) {
1611
1632
  hasPayPal: true,
1612
1633
  },
1613
1634
  callbacks: {
1635
+ onVerificationHide: () => { },
1614
1636
  onSubmit: async () => {
1615
1637
  setStep("/dashboard");
1616
1638
  },
@@ -289,7 +289,8 @@ export function useBankingInfoForm(props) {
289
289
  });
290
290
  setShowVerification(false);
291
291
  }
292
- await runMutation(formData, token);
292
+ if (token)
293
+ await runMutation(formData, token);
293
294
  };
294
295
  const onVerification = async (token) => {
295
296
  host.dispatchEvent(new CustomEvent(VERIFICATION_EVENT_KEY, {
@@ -322,6 +323,7 @@ export function useBankingInfoForm(props) {
322
323
  onBack: () => setStep("/dashboard"),
323
324
  setCountrySearch,
324
325
  onVerification,
326
+ onVerificationHide: () => onVerification(null),
325
327
  },
326
328
  states: {
327
329
  showVerification,
@@ -159,6 +159,7 @@ const style = {
159
159
  PageDescriptionText: {
160
160
  color: "var(--sl-color-neutral-500)",
161
161
  fontSize: "var(--sl-font-size-medium)",
162
+ marginTop: "0",
162
163
  },
163
164
  Dialog: {
164
165
  "&::part(panel)": {
@@ -327,20 +328,18 @@ export const TaxAndCashDashboardView = (props) => {
327
328
  h("strong", null, text.error.generalTitle),
328
329
  h("br", null),
329
330
  text.error.generalDescription)),
330
- states.payoutStatus && states.payoutStatus !== "DONE" && (h("sl-alert", { exportparts: "base: alert-base, icon:alert-icon", name: (_b = getAlert(states.payoutStatus)) === null || _b === void 0 ? void 0 : _b.alertType, open: true, class: (_c = getAlert(states.payoutStatus)) === null || _c === void 0 ? void 0 : _c.class },
331
+ getAlert(states.payoutStatus) && (h("sl-alert", { exportparts: "base: alert-base, icon:alert-icon", name: (_b = getAlert(states.payoutStatus)) === null || _b === void 0 ? void 0 : _b.alertType, open: true, class: (_c = getAlert(states.payoutStatus)) === null || _c === void 0 ? void 0 : _c.class },
331
332
  h("sl-icon", { slot: "icon", name: (_d = getAlert(states.payoutStatus)) === null || _d === void 0 ? void 0 : _d.icon }),
332
333
  h("strong", null, getAlert(states.payoutStatus).header),
333
334
  h("p", { style: { margin: "0" } }, getAlert(states.payoutStatus).description),
334
- getAlert(states.payoutStatus).buttonText && (h("sl-button", { style: { marginTop: "var(--sl-spacing-x-small)" }, type: "default", loading: states.loading,
335
- //AL: TODO hooks
336
- onClick: () => callbacks.onClick }, getAlert(states.payoutStatus).buttonText)))),
335
+ getAlert(states.payoutStatus).buttonText && (h("sl-button", { style: { marginTop: "var(--sl-spacing-x-small)" }, type: "default", loading: states.veriffLoading, onClick: () => callbacks.onVerifyClick() }, getAlert(states.payoutStatus).buttonText)))),
337
336
  h("sl-dialog", { label: text.replaceTaxFormModalHeader, class: sheet.classes.Dialog, open: states.showNewFormDialog, "onSl-hide": callbacks.onNewFormCancel },
338
337
  h("p", null, text.replaceTaxFormModalBodyText),
339
338
  h("sl-button", { slot: "footer", type: "primary", class: sheet.classes.DialogButton, onClick: callbacks.onNewFormClick }, text.newFormButton),
340
339
  h("sl-button", { slot: "footer", type: "default", class: sheet.classes.DialogButton, onClick: callbacks.onNewFormCancel }, text.cancelButton)),
341
340
  states.status === "INACTIVE" && alertMap[states.status],
342
341
  h("div", null,
343
- h("h3", null, text.bankingInformationSectionHeader),
342
+ h("h3", { style: { marginBottom: "0" } }, text.bankingInformationSectionHeader),
344
343
  h("p", { class: sheet.classes.PageDescriptionText }, text.taxAndPayoutsDescription),
345
344
  h("div", { class: sheet.classes.BankingInformationContainer },
346
345
  slots.payoutDetailsCardSlot,
@@ -12,7 +12,7 @@ import { u as useChildElements } from './useChildElements-fc84e640.js';
12
12
  import { l as luxon } from './luxon-7600be8d.js';
13
13
  import { g as generateUserError } from './useReferralTable-f6ffa103.js';
14
14
  import { g as getProps, l as luxonLocale } from './utils-334c1e34.js';
15
- 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, E as ErrorView, 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-1f26f252.js';
15
+ 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, E as ErrorView, 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-c184248a.js';
16
16
  import { b as VERIFICATION_EVENT_KEY } from './keys-db1897ae.js';
17
17
  import { T as TAX_FORM_UPDATED_EVENT_KEY, a as useVeriffApp, g as getStatus, V as VERIFF_COMPLETE_EVENT_KEY } from './usePayoutStatus-d613ff10.js';
18
18
  import { e as extractProps } from './extractProps-ae1afbb3.js';
@@ -1186,7 +1186,8 @@ function useBankingInfoForm(props) {
1186
1186
  });
1187
1187
  setShowVerification(false);
1188
1188
  }
1189
- await runMutation(formData, token);
1189
+ if (token)
1190
+ await runMutation(formData, token);
1190
1191
  };
1191
1192
  const onVerification = async (token) => {
1192
1193
  host.dispatchEvent(new CustomEvent(VERIFICATION_EVENT_KEY, {
@@ -1219,6 +1220,7 @@ function useBankingInfoForm(props) {
1219
1220
  onBack: () => setStep("/dashboard"),
1220
1221
  setCountrySearch,
1221
1222
  onVerification,
1223
+ onVerificationHide: () => onVerification(null),
1222
1224
  },
1223
1225
  states: {
1224
1226
  showVerification,
@@ -1552,15 +1554,33 @@ const BankingInfoForm = class {
1552
1554
  bitset: props.states.bitset,
1553
1555
  formMap,
1554
1556
  });
1555
- const searchStyle = {
1557
+ const style = {
1558
+ Dialog: {
1559
+ "&::part(panel)": {
1560
+ maxWidth: "420px",
1561
+ },
1562
+ "&::part(close-button)": {
1563
+ marginBottom: "var(--sl-spacing-xx-large)",
1564
+ },
1565
+ "&::part(body)": {
1566
+ padding: "0 var(--sl-spacing-x-large) 0 var(--sl-spacing-x-large)",
1567
+ fontSize: "var(--sl-font-size-small)",
1568
+ },
1569
+ "&::part(footer)": {
1570
+ display: "flex",
1571
+ flexDirection: "column",
1572
+ gap: "var(--sl-spacing-small)",
1573
+ marginBottom: "var(--sl-spacing-xx-small)",
1574
+ alignItems: "center",
1575
+ flex: "1",
1576
+ },
1577
+ },
1556
1578
  SearchInput: {
1557
1579
  padding: "var(--sl-spacing-x-small)",
1558
1580
  },
1559
1581
  };
1560
- if (props.states.isPartner && props.states.showVerification) {
1561
- return (h("sqm-code-verification", { onVerification: props.callbacks.onVerification }));
1562
- }
1563
- return (h(Host, null, h(BankingInfoFormView, { callbacks: props.callbacks, text: props.text, states: props.states, refs: props.refs, slots: {
1582
+ const sheet = createStyleSheet(style);
1583
+ return (h(Host, null, props.states.isPartner && props.states.showVerification ? (h("sl-dialog", { class: sheet.classes.Dialog, open: true, "onSl-hide": props.callbacks.onVerificationHide }, h("sqm-code-verification", { onVerification: props.callbacks.onVerification }))) : null, h(BankingInfoFormView, { callbacks: props.callbacks, text: props.text, states: props.states, refs: props.refs, slots: {
1564
1584
  formInputsSlot: inputFields === null || inputFields === void 0 ? void 0 : inputFields.map(({ input }) => input),
1565
1585
  countryInputSlot: (h("sl-select", Object.assign({ label: props.text.bankLocationLabel, disabled: props.states.saveLoading, required: true, name: "/bankCountry", id: "bankCountry", value: props.states.formState.bankCountry || "", "onSl-select": (e) => { var _a, _b; return props.callbacks.setBankCountry((_b = (_a = e.detail) === null || _a === void 0 ? void 0 : _a.item) === null || _b === void 0 ? void 0 : _b.value); } }, (((_a = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _a === void 0 ? void 0 : _a.bankCountry) && {
1566
1586
  class: "error-input",
@@ -1568,7 +1588,7 @@ const BankingInfoForm = class {
1568
1588
  type: (_c = (_b = errors === null || errors === void 0 ? void 0 : errors.inputErrors) === null || _b === void 0 ? void 0 : _b.bankCountry) === null || _c === void 0 ? void 0 : _c.type,
1569
1589
  label: props.text.bankLocationLabel,
1570
1590
  }),
1571
- })), h("sl-input", { disabled: props.states.saveLoading, class: searchStyle.SearchInput, placeholder: this.searchForCountryText, onKeyDown: (e) => {
1591
+ })), h("sl-input", { disabled: props.states.saveLoading, class: sheet.classes.SearchInput, placeholder: this.searchForCountryText, onKeyDown: (e) => {
1572
1592
  // Stop shoelace intercepting key presses
1573
1593
  e.stopPropagation();
1574
1594
  }, "onSl-input": (e) => {
@@ -1684,6 +1704,7 @@ function useDemoBankingInfoForm(props) {
1684
1704
  hasPayPal: true,
1685
1705
  },
1686
1706
  callbacks: {
1707
+ onVerificationHide: () => { },
1687
1708
  onSubmit: async () => {
1688
1709
  setStep("/dashboard");
1689
1710
  },
@@ -5046,6 +5067,7 @@ const style$5 = {
5046
5067
  PageDescriptionText: {
5047
5068
  color: "var(--sl-color-neutral-500)",
5048
5069
  fontSize: "var(--sl-font-size-medium)",
5070
+ marginTop: "0",
5049
5071
  },
5050
5072
  Dialog: {
5051
5073
  "&::part(panel)": {
@@ -5214,20 +5236,18 @@ const TaxAndCashDashboardView = (props) => {
5214
5236
  h("strong", null, text.error.generalTitle),
5215
5237
  h("br", null),
5216
5238
  text.error.generalDescription)),
5217
- states.payoutStatus && states.payoutStatus !== "DONE" && (h("sl-alert", { exportparts: "base: alert-base, icon:alert-icon", name: (_b = getAlert(states.payoutStatus)) === null || _b === void 0 ? void 0 : _b.alertType, open: true, class: (_c = getAlert(states.payoutStatus)) === null || _c === void 0 ? void 0 : _c.class },
5239
+ getAlert(states.payoutStatus) && (h("sl-alert", { exportparts: "base: alert-base, icon:alert-icon", name: (_b = getAlert(states.payoutStatus)) === null || _b === void 0 ? void 0 : _b.alertType, open: true, class: (_c = getAlert(states.payoutStatus)) === null || _c === void 0 ? void 0 : _c.class },
5218
5240
  h("sl-icon", { slot: "icon", name: (_d = getAlert(states.payoutStatus)) === null || _d === void 0 ? void 0 : _d.icon }),
5219
5241
  h("strong", null, getAlert(states.payoutStatus).header),
5220
5242
  h("p", { style: { margin: "0" } }, getAlert(states.payoutStatus).description),
5221
- getAlert(states.payoutStatus).buttonText && (h("sl-button", { style: { marginTop: "var(--sl-spacing-x-small)" }, type: "default", loading: states.loading,
5222
- //AL: TODO hooks
5223
- onClick: () => callbacks.onClick }, getAlert(states.payoutStatus).buttonText)))),
5243
+ getAlert(states.payoutStatus).buttonText && (h("sl-button", { style: { marginTop: "var(--sl-spacing-x-small)" }, type: "default", loading: states.veriffLoading, onClick: () => callbacks.onVerifyClick() }, getAlert(states.payoutStatus).buttonText)))),
5224
5244
  h("sl-dialog", { label: text.replaceTaxFormModalHeader, class: sheet$4.classes.Dialog, open: states.showNewFormDialog, "onSl-hide": callbacks.onNewFormCancel },
5225
5245
  h("p", null, text.replaceTaxFormModalBodyText),
5226
5246
  h("sl-button", { slot: "footer", type: "primary", class: sheet$4.classes.DialogButton, onClick: callbacks.onNewFormClick }, text.newFormButton),
5227
5247
  h("sl-button", { slot: "footer", type: "default", class: sheet$4.classes.DialogButton, onClick: callbacks.onNewFormCancel }, text.cancelButton)),
5228
5248
  states.status === "INACTIVE" && alertMap[states.status],
5229
5249
  h("div", null,
5230
- h("h3", null, text.bankingInformationSectionHeader),
5250
+ h("h3", { style: { marginBottom: "0" } }, text.bankingInformationSectionHeader),
5231
5251
  h("p", { class: sheet$4.classes.PageDescriptionText }, text.taxAndPayoutsDescription),
5232
5252
  h("div", { class: sheet$4.classes.BankingInformationContainer },
5233
5253
  slots.payoutDetailsCardSlot,
@@ -15,7 +15,7 @@ const style = {
15
15
  display: "flex",
16
16
  flexDirection: "column",
17
17
  gap: "var(--sl-spacing-medium)",
18
- maxWidth: "515px",
18
+ maxWidth: "550px",
19
19
  },
20
20
  HeaderContainer: {
21
21
  display: "flex",
@@ -712,6 +712,7 @@ const stepFourProps = {
712
712
  },
713
713
  },
714
714
  callbacks: {
715
+ onVerificationHide: () => { },
715
716
  onVerification: () => { },
716
717
  onSubmit: async () => console.log("Submit"),
717
718
  setPaymentMethodChecked: () => { },
@@ -26,7 +26,7 @@ import { P as PortalResetPasswordView } from './sqm-portal-reset-password-view-7
26
26
  import { P as PortalVerifyEmailView } from './sqm-portal-verify-email-view-d7ea2c56.js';
27
27
  import { S as ShareButtonView, L as LeaderboardView, C as CopyTextView, B as BigStatView, P as PortalFrameView, E as EditProfileView, u as useShareLink, a as useShareButton, b as useDemoBigStat, c as StatContainerView, d as PortalChangePasswordView, e as PortalLoginView, f as PortalRegisterView, T as TaskCardView, g as ProgressBarView, h as PoweredByImg$1, i as PortalFooterView, H as HeroView, R as ReferralIframeView, N as NameFieldsView, j as CheckboxFieldView, D as DropdownFieldView, I as InputFieldView, k as RewardExchangeView, r as rewardExchangeCustomErrorMsg, l as rewardExchangeLongText, m as rewardExchangeSelected, n as chooseAmountFixed, o as chooseAmountFixedNoDescription, p as chooseAmountVariable, q as chooseAmountVariableNoDescription, s as chooseAmountVariableDisabled, t as chooseAmountVariableUnavailable, v as confirmFixed, w as confirmVariable, x as redemptionError, y as queryError, z as success, A as successVariable, F as loading, G as empty$1, J as rewardExchange, K as CardFeedView, M as CouponCodeView, O as ProgressBar$2, Q as autoColorScaleCss, U as ShadowViewAddon } from './ShadowViewAddon-69b61037.js';
28
28
  import { P as PortalContainerView, a as PortalSectionView } from './sqm-portal-container-view-6c582684.js';
29
- import { O as OtherRegionSlotView, I as InvoiceTableView, T as TaxForm } from './sqm-invoice-table-view-1f26f252.js';
29
+ import { O as OtherRegionSlotView, I as InvoiceTableView, T as TaxForm } from './sqm-invoice-table-view-c184248a.js';
30
30
 
31
31
  /**
32
32
  * lodash (Custom Build) <https://lodash.com/>
@@ -14400,6 +14400,7 @@ const bankingFormProps = {
14400
14400
  loadingError: false,
14401
14401
  },
14402
14402
  callbacks: {
14403
+ onVerificationHide: () => { },
14403
14404
  onVerification: () => { },
14404
14405
  onSubmit: async () => console.log("Submit"),
14405
14406
  setPaymentMethodChecked: () => { },