@tesouro/embedded-components-react 0.5.148 → 0.5.150

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 (64) hide show
  1. package/dist/libs/tesouro-embedded-components-react/bank-account-onboarding-widget/data-access/dist/index11.js +11 -8
  2. package/dist/libs/tesouro-embedded-components-react/bank-accounts-widget/account-details/data-access/dist/index2.js +5 -2
  3. package/dist/libs/tesouro-embedded-components-react/bank-accounts-widget/account-details/data-access/dist/index3.js +5 -2
  4. package/dist/libs/tesouro-embedded-components-react/bank-accounts-widget/account-details/data-access/dist/index4.js +5 -2
  5. package/dist/libs/tesouro-embedded-components-react/bank-accounts-widget/data-access/dist/index5.js +21 -18
  6. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index10.js +14 -11
  7. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index11.js +17 -14
  8. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index15.js +6 -3
  9. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index17.js +43 -28
  10. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index18.js +9 -6
  11. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index8.js +6 -3
  12. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/data-access/dist/index9.js +6 -3
  13. package/dist/libs/tesouro-embedded-components-react/bill-pay-widget/feature/dist/index72.js +52 -49
  14. package/dist/libs/tesouro-embedded-components-react/card-details-widget/data-access/dist/index6.js +7 -4
  15. package/dist/libs/tesouro-embedded-components-react/card-details-widget/data-access/dist/index7.js +10 -7
  16. package/dist/libs/tesouro-embedded-components-react/card-details-widget/data-access/dist/index8.js +7 -4
  17. package/dist/libs/tesouro-embedded-components-react/cards-widget/create-card/data-access/dist/index7.js +5 -2
  18. package/dist/libs/tesouro-embedded-components-react/cards-widget/data-access/dist/index2.js +5 -2
  19. package/dist/libs/tesouro-embedded-components-react/cards-widget/data-access/dist/index3.js +5 -2
  20. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/data-access/dist/index2.js +12 -6
  21. package/dist/libs/tesouro-embedded-components-react/counterparts-widget/data-access/dist/index3.js +12 -6
  22. package/dist/libs/tesouro-embedded-components-react/expense-management-widget/data-access/dist/index2.js +6 -3
  23. package/dist/libs/tesouro-embedded-components-react/expense-management-widget/data-access/dist/index3.js +6 -3
  24. package/dist/libs/tesouro-embedded-components-react/invoicing-widget/data-access/dist/index6.js +30 -15
  25. package/dist/libs/tesouro-embedded-components-react/linked-accounts-widget/data-access/dist/index4.js +5 -2
  26. package/dist/libs/tesouro-embedded-components-react/settings-widget/invoice-settings/data-access/dist/index2.js +6 -3
  27. package/dist/libs/tesouro-embedded-components-react/settings-widget/invoice-settings/data-access/dist/index3.js +6 -3
  28. package/dist/libs/tesouro-embedded-components-react/settings-widget/invoice-settings/data-access/dist/index4.js +6 -3
  29. package/dist/libs/tesouro-embedded-components-react/settings-widget/profile/data-access/dist/index2.js +7 -4
  30. package/dist/libs/tesouro-embedded-components-react/settings-widget/tags/data-access/dist/index10.js +6 -3
  31. package/dist/libs/tesouro-embedded-components-react/settings-widget/tags/data-access/dist/index2.js +6 -3
  32. package/dist/libs/tesouro-embedded-components-react/settings-widget/tags/data-access/dist/index7.js +6 -3
  33. package/dist/libs/tesouro-embedded-components-react/settings-widget/tags/data-access/dist/index8.js +6 -3
  34. package/dist/libs/tesouro-embedded-components-react/settings-widget/team/data-access/dist/index12.js +7 -4
  35. package/dist/libs/tesouro-embedded-components-react/settings-widget/team/data-access/dist/index13.js +5 -2
  36. package/dist/libs/tesouro-embedded-components-react/shared/approval-policy/data-access/dist/lib/approvalPoliciesApi.js +16 -13
  37. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/data-access/dist/index3.js +12 -6
  38. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/data-access/dist/index5.js +6 -3
  39. package/dist/libs/tesouro-embedded-components-react/shared/counterpart-management/data-access/dist/index7.js +12 -6
  40. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/EmbedApiContext.js +9 -6
  41. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/applicationStatusQueryOptions.js +4 -1
  42. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/bank-account/useAllBankAccountsQuery.js +14 -14
  43. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/disclosures/useDisclosuresQuery.js +15 -12
  44. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/merchant-category-group/useAllMerchantCategoryGroupsQuery.js +17 -14
  45. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/reference-data/useLedgerAccountsQuery.js +23 -17
  46. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/reference-data/usePaymentTermsQuery.js +6 -3
  47. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/rest/zod.gen.js +3 -0
  48. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/role/useAllOrganizationRolesQuery.js +17 -14
  49. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/role/useRolePermissionsQueries.js +19 -16
  50. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/useCurrentUserQuery.js +6 -3
  51. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/useGetUserDataQuery.js +12 -9
  52. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/user/useAllOrganizationUsersQuery.js +19 -16
  53. package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/withAuthEpoch.js +11 -11
  54. package/dist/libs/tesouro-embedded-components-react/shared/expense-requirements/data-access/dist/index3.js +6 -3
  55. package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/RootWidgetProvider.js +99 -98
  56. package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/WidgetProvider.js +139 -138
  57. package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/WidgetProvider/useWidgetFetch.js +11 -10
  58. package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
  59. package/dist/libs/tesouro-embedded-components-react/shared/product-catalog/data-access/dist/index2.js +6 -3
  60. package/dist/libs/tesouro-embedded-components-react/shared/product-catalog/data-access/dist/index3.js +6 -3
  61. package/dist/libs/tesouro-embedded-components-react/shared/product-catalog/data-access/dist/index8.js +6 -3
  62. package/dist/libs/tesouro-embedded-components-react/shared/product-catalog/data-access/dist/index9.js +6 -3
  63. package/dist/libs/tesouro-embedded-components-react/transfers-widget/data-access/dist/index6.js +16 -13
  64. package/package.json +7 -1
@@ -22,107 +22,110 @@ function g({ onOpenBill: g, labels: _ } = {}) {
22
22
  let v = {
23
23
  ...l,
24
24
  ..._
25
- }, y = _?.tooManyFilesError ?? l.tooManyFilesError, b = _?.remainingCapacityError ?? l.remainingCapacityError, { client: x, organizationId: S, authEpoch: C } = r(), w = h(), T = f(() => c(S), [S]), E = o(), [D, O] = p(!1), { data: k = [] } = m({
26
- queryKey: T,
27
- queryFn: () => w.getQueryData(T) ?? [],
25
+ }, y = _?.tooManyFilesError ?? l.tooManyFilesError, b = _?.remainingCapacityError ?? l.remainingCapacityError, { client: x, organizationId: S, authEpoch: C, organizationPending: w } = r(), T = h(), E = f(() => c(S), [S]), D = o(), [O, k] = p(!1), { data: A = [] } = m({
26
+ queryKey: E,
27
+ queryFn: () => T.getQueryData(E) ?? [],
28
28
  staleTime: Infinity,
29
29
  gcTime: Infinity,
30
30
  initialData: []
31
- }), A = u((e, t) => {
32
- w.setQueryData(T, (n) => (n ?? []).map((n) => n.localId === e ? {
31
+ }), j = u((e, t) => {
32
+ T.setQueryData(E, (n) => (n ?? []).map((n) => n.localId === e ? {
33
33
  ...n,
34
34
  ...t
35
35
  } : n));
36
- }, [w, T]), j = u((e) => {
37
- w.setQueryData(T, (t) => (t ?? []).filter((t) => t.localId !== e));
38
- }, [w, T]), M = u((t) => {
39
- let n = (w.getQueryData(T) ?? []).filter((e) => e.status === "uploading").length;
36
+ }, [T, E]), M = u((e) => {
37
+ T.setQueryData(E, (t) => (t ?? []).filter((t) => t.localId !== e));
38
+ }, [T, E]), N = u((t) => {
39
+ let n = (T.getQueryData(E) ?? []).filter((e) => e.status === "uploading").length;
40
40
  if (t.length + n > 10) {
41
41
  e.error(n > 0 ? b(10 - n) : y(10));
42
42
  return;
43
43
  }
44
- O(!1);
44
+ k(!1);
45
45
  for (let e of t) {
46
46
  let t = crypto.randomUUID();
47
- w.setQueryData(T, (n) => [...n ?? [], {
47
+ T.setQueryData(E, (n) => [...n ?? [], {
48
48
  localId: t,
49
49
  fileName: e.name,
50
50
  status: "uploading"
51
- }]), E.mutateAsync({ file: e }).then((e) => A(t, { payableId: e?.id })).catch(() => A(t, { status: "failed" }));
51
+ }]), D.mutateAsync({ file: e }).then((e) => j(t, { payableId: e?.id })).catch(() => j(t, { status: "failed" }));
52
52
  }
53
53
  }, [
54
- A,
55
- w,
54
+ j,
56
55
  T,
56
+ E,
57
57
  b,
58
58
  y,
59
- E
60
- ]), N = s({ payableIds: k.filter((e) => e.status === "uploading" && e.payableId).map((e) => e.payableId) });
59
+ D
60
+ ]), P = s({ payableIds: A.filter((e) => e.status === "uploading" && e.payableId).map((e) => e.payableId) });
61
61
  d(() => {
62
62
  let e = /* @__PURE__ */ new Set();
63
- for (let t of N) if (t.suspectedDuplicateOf.length !== 0) {
63
+ for (let t of P) if (t.suspectedDuplicateOf.length !== 0) {
64
64
  e.add(t.payableId);
65
65
  for (let n of t.suspectedDuplicateOf) e.add(n);
66
66
  }
67
- for (let { payableId: t, ocrStatus: n, isError: r } of N) {
68
- let i = k.find((e) => e.payableId === t && e.status === "uploading");
69
- i && (n === "success" ? A(i.localId, { status: e.has(t) ? "duplicate" : "ready" }) : (r || n === "error" || n === "canceled") && A(i.localId, { status: "failed" }));
67
+ for (let { payableId: t, ocrStatus: n, isError: r } of P) {
68
+ let i = A.find((e) => e.payableId === t && e.status === "uploading");
69
+ i && (n === "success" ? j(i.localId, { status: e.has(t) ? "duplicate" : "ready" }) : (r || n === "error" || n === "canceled") && j(i.localId, { status: "failed" }));
70
70
  }
71
- for (let t of k) t.status === "ready" && t.payableId && e.has(t.payableId) && A(t.localId, { status: "duplicate" });
71
+ for (let t of A) t.status === "ready" && t.payableId && e.has(t.payableId) && j(t.localId, { status: "duplicate" });
72
72
  }, [
73
- k,
74
- N,
75
- A
73
+ A,
74
+ P,
75
+ j
76
76
  ]);
77
- let P = k.filter((e) => e.status === "uploading"), F = k.filter((e) => e.status === "ready"), I = k.filter((e) => e.status === "duplicate"), L = k.filter((e) => e.status === "failed"), R = (r) => ({
77
+ let F = A.filter((e) => e.status === "uploading"), I = A.filter((e) => e.status === "ready"), L = A.filter((e) => e.status === "duplicate"), R = A.filter((e) => e.status === "failed"), z = (r) => ({
78
78
  id: r.localId,
79
79
  fileName: r.fileName,
80
80
  status: r.status,
81
81
  onOpen: (r.status === "ready" || r.status === "duplicate") && r.payableId && g ? () => {
82
82
  let o = r.payableId;
83
- w.fetchQuery({
83
+ T.fetchQuery({
84
84
  ...n(t({
85
85
  client: x,
86
86
  headers: i(S),
87
87
  path: { payable_id: o }
88
- }), C),
88
+ }), {
89
+ authEpoch: C,
90
+ organizationPending: w
91
+ }),
89
92
  retry: !1
90
93
  }).catch((e) => {
91
94
  if (a(e)) return "deleted";
92
95
  }).then((t) => {
93
- t === "deleted" ? e.error(v.billDeletedError) : g(o), j(r.localId);
96
+ t === "deleted" ? e.error(v.billDeletedError) : g(o), M(r.localId);
94
97
  });
95
98
  } : void 0
96
- }), z = P.length ? [{
99
+ }), B = F.length ? [{
97
100
  id: "in-progress",
98
- items: k.map(R)
101
+ items: A.map(z)
99
102
  }] : [
100
- ...F.length ? [{
103
+ ...I.length ? [{
101
104
  id: "ready",
102
- caption: v.readyCaption(F.length),
103
- items: F.map(R)
105
+ caption: v.readyCaption(I.length),
106
+ items: I.map(z)
104
107
  }] : [],
105
- ...I.length ? [{
108
+ ...L.length ? [{
106
109
  id: "duplicate",
107
- caption: v.duplicateCaption(I.length),
108
- items: I.map(R)
110
+ caption: v.duplicateCaption(L.length),
111
+ items: L.map(z)
109
112
  }] : [],
110
- ...L.length ? [{
113
+ ...R.length ? [{
111
114
  id: "failed",
112
- caption: v.failedCaption(L.length),
113
- items: L.map(R)
115
+ caption: v.failedCaption(R.length),
116
+ items: R.map(z)
114
117
  }] : []
115
- ], B = F.length + I.length, V = P.length ? v.uploadingSummary(k.length) : B ? v.completeSummary(B) : v.failedCaption(L.length), H = u(() => {
116
- w.setQueryData(T, []);
117
- }, [w, T]);
118
+ ], V = I.length + L.length, H = F.length ? v.uploadingSummary(A.length) : V ? v.completeSummary(V) : v.failedCaption(R.length), U = u(() => {
119
+ T.setQueryData(E, []);
120
+ }, [T, E]);
118
121
  return {
119
- enqueue: M,
120
- sections: z,
121
- summaryLabel: V,
122
- collapsed: D,
123
- onToggleCollapsed: u(() => O((e) => !e), []),
124
- onClose: H,
125
- isVisible: k.length > 0
122
+ enqueue: N,
123
+ sections: B,
124
+ summaryLabel: H,
125
+ collapsed: O,
126
+ onToggleCollapsed: u(() => k((e) => !e), []),
127
+ onClose: U,
128
+ isVisible: A.length > 0
126
129
  };
127
130
  }
128
131
  //#endregion
@@ -11,15 +11,18 @@ import { withNotFoundOutcome as i } from "./index5.js";
11
11
  import { useQuery as a } from "@tanstack/react-query";
12
12
  //#region ../../libs/tesouro-embedded-components-react/card-details-widget/data-access/dist/index6.js
13
13
  function o({ cardId: o, enabled: s }) {
14
- let { client: c, organizationId: l, widgetToken: u, authEpoch: d } = n(), f = e({
14
+ let { client: c, organizationId: l, widgetToken: u, authEpoch: d, organizationPending: f } = n(), p = e({
15
15
  client: c,
16
16
  headers: r(l),
17
17
  path: { cardId: o ?? "" }
18
- }), p = a({
19
- ...t(f, d),
18
+ }), m = a({
19
+ ...t(p, {
20
+ authEpoch: d,
21
+ organizationPending: f
22
+ }),
20
23
  enabled: !!(o && l && u) && s !== !1
21
24
  });
22
- return i(p);
25
+ return i(m);
23
26
  }
24
27
  //#endregion
25
28
  export { o as useCreditCardDetailsQuery };
@@ -11,21 +11,24 @@ import "../../../shared/data-access/dist/index.js";
11
11
  import { useQuery as a } from "@tanstack/react-query";
12
12
  //#region ../../libs/tesouro-embedded-components-react/card-details-widget/data-access/dist/index7.js
13
13
  function o({ cardId: o, enabled: s }) {
14
- let { client: c, organizationId: l, widgetToken: u, authEpoch: d } = n(), f = !!(o && l && u) && s, p = f ? o ?? "" : "", m = e({
14
+ let { client: c, organizationId: l, widgetToken: u, authEpoch: d, organizationPending: f } = n(), p = !!(o && l && u) && s, m = p ? o ?? "" : "", h = e({
15
15
  client: c,
16
16
  headers: r(l),
17
- path: { id: p }
18
- }), h = a({
19
- ...t(m, d),
20
- enabled: f,
17
+ path: { id: m }
18
+ }), g = a({
19
+ ...t(h, {
20
+ authEpoch: d,
21
+ organizationPending: f
22
+ }),
23
+ enabled: p,
21
24
  staleTime: 0,
22
25
  gcTime: 0,
23
26
  retry: !1,
24
27
  placeholderData: void 0
25
28
  });
26
29
  return {
27
- ...h,
28
- isForbidden: h.isError && i(h.error)
30
+ ...g,
31
+ isForbidden: g.isError && i(g.error)
29
32
  };
30
33
  }
31
34
  //#endregion
@@ -11,15 +11,18 @@ import { withNotFoundOutcome as i } from "./index5.js";
11
11
  import { useQuery as a } from "@tanstack/react-query";
12
12
  //#region ../../libs/tesouro-embedded-components-react/card-details-widget/data-access/dist/index8.js
13
13
  function o({ cardId: o, enabled: s }) {
14
- let { client: c, organizationId: l, widgetToken: u, authEpoch: d } = n(), f = e({
14
+ let { client: c, organizationId: l, widgetToken: u, authEpoch: d, organizationPending: f } = n(), p = e({
15
15
  client: c,
16
16
  headers: r(l),
17
17
  path: { id: o ?? "" }
18
- }), p = a({
19
- ...t(f, d),
18
+ }), m = a({
19
+ ...t(p, {
20
+ authEpoch: d,
21
+ organizationPending: f
22
+ }),
20
23
  enabled: !!(o && l && u) && s !== !1
21
24
  });
22
- return i(p);
25
+ return i(m);
23
26
  }
24
27
  //#endregion
25
28
  export { o as useDebitCardDetailsQuery };
@@ -9,12 +9,15 @@ import "../../../../shared/data-access/dist/index.js";
9
9
  import { useQuery as r } from "@tanstack/react-query";
10
10
  //#region ../../libs/tesouro-embedded-components-react/cards-widget/create-card/data-access/dist/index7.js
11
11
  function i({ enabled: i } = {}) {
12
- let { client: a, organizationId: o, widgetToken: s, authEpoch: c } = n(), l = e({
12
+ let { client: a, organizationId: o, widgetToken: s, authEpoch: c, organizationPending: l } = n(), u = e({
13
13
  client: a,
14
14
  path: { organizationId: o ?? "" }
15
15
  });
16
16
  return r({
17
- ...t(l, c),
17
+ ...t(u, {
18
+ authEpoch: c,
19
+ organizationPending: l
20
+ }),
18
21
  enabled: !!(o && s) && (i === !0 || i === void 0)
19
22
  });
20
23
  }
@@ -10,13 +10,16 @@ import "../../../shared/data-access/dist/index.js";
10
10
  import { useQuery as i } from "@tanstack/react-query";
11
11
  //#region ../../libs/tesouro-embedded-components-react/cards-widget/data-access/dist/index2.js
12
12
  function a({ enabled: a, ...o } = {}) {
13
- let { client: s, organizationId: c, widgetToken: l, authEpoch: u } = n(), d = e({
13
+ let { client: s, organizationId: c, widgetToken: l, authEpoch: u, organizationPending: d } = n(), f = e({
14
14
  query: o,
15
15
  client: s,
16
16
  headers: r(c)
17
17
  });
18
18
  return i({
19
- ...t(d, u, { carryWithinOrg: !0 }),
19
+ ...t(f, {
20
+ authEpoch: u,
21
+ organizationPending: d
22
+ }, { carryWithinOrg: !0 }),
20
23
  enabled: !!(c && l) && (a === !0 || a === void 0)
21
24
  });
22
25
  }
@@ -10,13 +10,16 @@ import "../../../shared/data-access/dist/index.js";
10
10
  import { useQuery as i } from "@tanstack/react-query";
11
11
  //#region ../../libs/tesouro-embedded-components-react/cards-widget/data-access/dist/index3.js
12
12
  function a({ enabled: a, ...o } = {}) {
13
- let { client: s, organizationId: c, widgetToken: l, authEpoch: u } = n(), d = e({
13
+ let { client: s, organizationId: c, widgetToken: l, authEpoch: u, organizationPending: d } = n(), f = e({
14
14
  query: o,
15
15
  client: s,
16
16
  headers: r(c)
17
17
  });
18
18
  return i({
19
- ...t(d, u, { carryWithinOrg: !0 }),
19
+ ...t(f, {
20
+ authEpoch: u,
21
+ organizationPending: d
22
+ }, { carryWithinOrg: !0 }),
20
23
  enabled: !!(c && l) && (a === !0 || a === void 0)
21
24
  });
22
25
  }
@@ -10,7 +10,7 @@ import "../../../shared/data-access/dist/index.js";
10
10
  import { useQuery as a } from "@tanstack/react-query";
11
11
  //#region ../../libs/tesouro-embedded-components-react/counterparts-widget/data-access/dist/index2.js
12
12
  function o({ metric: e = "total_amount", type: o, statusIn: s, counterpartIdIn: c, enabled: l } = {}) {
13
- let { client: u, organizationId: d, widgetToken: f, authEpoch: p } = r(), m = c == null || c.length > 0, h = !!(d && f) && m && (l === !0 || l === void 0), g = t({
13
+ let { client: u, organizationId: d, widgetToken: f, authEpoch: p, organizationPending: m } = r(), h = c == null || c.length > 0, g = !!(d && f) && h && (l === !0 || l === void 0), _ = t({
14
14
  client: u,
15
15
  headers: i(d),
16
16
  query: {
@@ -23,12 +23,15 @@ function o({ metric: e = "total_amount", type: o, statusIn: s, counterpartIdIn:
23
23
  }
24
24
  });
25
25
  return a({
26
- ...n(g, p),
27
- enabled: h
26
+ ...n(_, {
27
+ authEpoch: p,
28
+ organizationPending: m
29
+ }),
30
+ enabled: g
28
31
  });
29
32
  }
30
33
  function s({ metric: t = "total_amount", statusIn: o, counterpartIdIn: s, enabled: c } = {}) {
31
- let { client: l, organizationId: u, widgetToken: d, authEpoch: f } = r(), p = s == null || s.length > 0, m = !!(u && d) && p && (c === !0 || c === void 0), h = e({
34
+ let { client: l, organizationId: u, widgetToken: d, authEpoch: f, organizationPending: p } = r(), m = s == null || s.length > 0, h = !!(u && d) && m && (c === !0 || c === void 0), g = e({
32
35
  client: l,
33
36
  headers: i(u),
34
37
  query: {
@@ -40,8 +43,11 @@ function s({ metric: t = "total_amount", statusIn: o, counterpartIdIn: s, enable
40
43
  }
41
44
  });
42
45
  return a({
43
- ...n(h, f),
44
- enabled: m
46
+ ...n(g, {
47
+ authEpoch: f,
48
+ organizationPending: p
49
+ }),
50
+ enabled: h
45
51
  });
46
52
  }
47
53
  //#endregion
@@ -24,7 +24,7 @@ var o = [
24
24
  "paid"
25
25
  ];
26
26
  function c({ counterpartId: t, enabled: s }) {
27
- let { client: c, organizationId: l, widgetToken: u, authEpoch: d } = r(), f = !!(l && u && t) && (s === !0 || s === void 0), p = e({
27
+ let { client: c, organizationId: l, widgetToken: u, authEpoch: d, organizationPending: f } = r(), p = !!(l && u && t) && (s === !0 || s === void 0), m = e({
28
28
  client: c,
29
29
  headers: i(l),
30
30
  query: {
@@ -36,12 +36,15 @@ function c({ counterpartId: t, enabled: s }) {
36
36
  }
37
37
  });
38
38
  return a({
39
- ...n(p, d),
40
- enabled: f
39
+ ...n(m, {
40
+ authEpoch: d,
41
+ organizationPending: f
42
+ }),
43
+ enabled: p
41
44
  });
42
45
  }
43
46
  function l({ counterpartId: e, enabled: o }) {
44
- let { client: c, organizationId: l, widgetToken: u, authEpoch: d } = r(), f = !!(l && u && e) && (o === !0 || o === void 0), p = t({
47
+ let { client: c, organizationId: l, widgetToken: u, authEpoch: d, organizationPending: f } = r(), p = !!(l && u && e) && (o === !0 || o === void 0), m = t({
45
48
  client: c,
46
49
  headers: i(l),
47
50
  query: {
@@ -54,8 +57,11 @@ function l({ counterpartId: e, enabled: o }) {
54
57
  }
55
58
  });
56
59
  return a({
57
- ...n(p, d),
58
- enabled: f
60
+ ...n(m, {
61
+ authEpoch: d,
62
+ organizationPending: f
63
+ }),
64
+ enabled: p
59
65
  });
60
66
  }
61
67
  //#endregion
@@ -9,14 +9,17 @@ import "../../../shared/data-access/dist/index.js";
9
9
  import { useQuery as r } from "@tanstack/react-query";
10
10
  //#region ../../libs/tesouro-embedded-components-react/expense-management-widget/data-access/dist/index2.js
11
11
  function i({ enabled: i, ...a } = {}) {
12
- let { client: o, organizationId: s, widgetToken: c, authEpoch: l } = n(), u = !!(s && c) && (i === !0 || i === void 0), d = e({
12
+ let { client: o, organizationId: s, widgetToken: c, authEpoch: l, organizationPending: u } = n(), d = !!(s && c) && (i === !0 || i === void 0), f = e({
13
13
  query: a,
14
14
  client: o,
15
15
  headers: { "x-organization-id": s ?? "" }
16
16
  });
17
17
  return r({
18
- ...t(d, l),
19
- enabled: u
18
+ ...t(f, {
19
+ authEpoch: l,
20
+ organizationPending: u
21
+ }),
22
+ enabled: d
20
23
  });
21
24
  }
22
25
  //#endregion
@@ -9,14 +9,17 @@ import "../../../shared/data-access/dist/index.js";
9
9
  import { useQuery as r } from "@tanstack/react-query";
10
10
  //#region ../../libs/tesouro-embedded-components-react/expense-management-widget/data-access/dist/index3.js
11
11
  function i({ enabled: i, ...a } = {}) {
12
- let { client: o, organizationId: s, widgetToken: c, authEpoch: l } = n(), u = !!(s && c) && (i === !0 || i === void 0), d = e({
12
+ let { client: o, organizationId: s, widgetToken: c, authEpoch: l, organizationPending: u } = n(), d = !!(s && c) && (i === !0 || i === void 0), f = e({
13
13
  query: a,
14
14
  client: o,
15
15
  headers: { "x-organization-id": s ?? "" }
16
16
  });
17
17
  return r({
18
- ...t(d, l, { carryWithinOrg: !0 }),
19
- enabled: u
18
+ ...t(f, {
19
+ authEpoch: l,
20
+ organizationPending: u
21
+ }, { carryWithinOrg: !0 }),
22
+ enabled: d
20
23
  });
21
24
  }
22
25
  //#endregion
@@ -10,60 +10,75 @@ import "../../../shared/data-access/dist/index.js";
10
10
  import { useQuery as c } from "@tanstack/react-query";
11
11
  //#region ../../libs/tesouro-embedded-components-react/invoicing-widget/data-access/dist/index6.js
12
12
  function l({ enabled: e, ...t } = {}) {
13
- let { client: n, organizationId: r, widgetToken: l, authEpoch: u } = o(), d = !!(r && l) && (e === !0 || e === void 0), f = i({
13
+ let { client: n, organizationId: r, widgetToken: l, authEpoch: u, organizationPending: d } = o(), f = !!(r && l) && (e === !0 || e === void 0), p = i({
14
14
  client: n,
15
15
  headers: s(r),
16
16
  query: t
17
17
  });
18
18
  return c({
19
- ...a(f, u, { carryWithinOrg: !0 }),
20
- enabled: d
19
+ ...a(p, {
20
+ authEpoch: u,
21
+ organizationPending: d
22
+ }, { carryWithinOrg: !0 }),
23
+ enabled: f
21
24
  });
22
25
  }
23
26
  function u(e, { enabled: t = !0 } = {}) {
24
- let { client: r, organizationId: i, widgetToken: l, authEpoch: u } = o(), d = !!(i && l && e) && t, f = n({
27
+ let { client: r, organizationId: i, widgetToken: l, authEpoch: u, organizationPending: d } = o(), f = !!(i && l && e) && t, p = n({
25
28
  client: r,
26
29
  headers: s(i),
27
30
  path: { receivable_id: e ?? "" }
28
31
  });
29
32
  return c({
30
- ...a(f, u),
31
- enabled: d
33
+ ...a(p, {
34
+ authEpoch: u,
35
+ organizationPending: d
36
+ }),
37
+ enabled: f
32
38
  });
33
39
  }
34
40
  function d(t, { enabled: n, ...r } = {}) {
35
- let { client: i, organizationId: l, widgetToken: u, authEpoch: d } = o(), f = !!(l && u && t) && (n === !0 || n === void 0), p = e({
41
+ let { client: i, organizationId: l, widgetToken: u, authEpoch: d, organizationPending: f } = o(), p = !!(l && u && t) && (n === !0 || n === void 0), m = e({
36
42
  client: i,
37
43
  headers: s(l),
38
44
  path: { receivable_id: t ?? "" },
39
45
  query: r
40
46
  });
41
47
  return c({
42
- ...a(p, d),
43
- enabled: f
48
+ ...a(m, {
49
+ authEpoch: d,
50
+ organizationPending: f
51
+ }),
52
+ enabled: p
44
53
  });
45
54
  }
46
55
  function f(e, { enabled: n, ...r } = {}) {
47
- let { client: i, organizationId: l, widgetToken: u, authEpoch: d } = o(), f = !!(l && u && e) && (n === !0 || n === void 0), p = t({
56
+ let { client: i, organizationId: l, widgetToken: u, authEpoch: d, organizationPending: f } = o(), p = !!(l && u && e) && (n === !0 || n === void 0), m = t({
48
57
  client: i,
49
58
  headers: s(l),
50
59
  path: { receivable_id: e ?? "" },
51
60
  query: r
52
61
  });
53
62
  return c({
54
- ...a(p, d),
55
- enabled: f
63
+ ...a(m, {
64
+ authEpoch: d,
65
+ organizationPending: f
66
+ }),
67
+ enabled: p
56
68
  });
57
69
  }
58
70
  function p(e, { enabled: t = !0 } = {}) {
59
- let { client: n, organizationId: i, widgetToken: l, authEpoch: u } = o(), d = !!(i && l && e) && t, f = r({
71
+ let { client: n, organizationId: i, widgetToken: l, authEpoch: u, organizationPending: d } = o(), f = !!(i && l && e) && t, p = r({
60
72
  client: n,
61
73
  headers: s(i),
62
74
  path: { receivable_id: e ?? "" }
63
75
  });
64
76
  return c({
65
- ...a(f, u),
66
- enabled: d
77
+ ...a(p, {
78
+ authEpoch: u,
79
+ organizationPending: d
80
+ }),
81
+ enabled: f
67
82
  });
68
83
  }
69
84
  //#endregion
@@ -10,13 +10,16 @@ import "../../../shared/data-access/dist/index.js";
10
10
  import { useQuery as i } from "@tanstack/react-query";
11
11
  //#region ../../libs/tesouro-embedded-components-react/linked-accounts-widget/data-access/dist/index4.js
12
12
  function a({ enabled: a, ...o } = {}) {
13
- let { client: s, organizationId: c, widgetToken: l, authEpoch: u } = n(), d = e({
13
+ let { client: s, organizationId: c, widgetToken: l, authEpoch: u, organizationPending: d } = n(), f = e({
14
14
  query: o,
15
15
  client: s,
16
16
  headers: r(c)
17
17
  });
18
18
  return i({
19
- ...t(d, u),
19
+ ...t(f, {
20
+ authEpoch: u,
21
+ organizationPending: d
22
+ }),
20
23
  enabled: !!(c && l) && (a === !0 || a === void 0)
21
24
  });
22
25
  }
@@ -10,13 +10,16 @@ import "../../../../shared/data-access/dist/index.js";
10
10
  import { useQuery as i } from "@tanstack/react-query";
11
11
  //#region ../../libs/tesouro-embedded-components-react/settings-widget/invoice-settings/data-access/dist/index2.js
12
12
  function a() {
13
- let { client: a, organizationId: o, widgetToken: s, authEpoch: c } = n(), l = !!(o && s), u = e({
13
+ let { client: a, organizationId: o, widgetToken: s, authEpoch: c, organizationPending: l } = n(), u = !!(o && s), d = e({
14
14
  client: a,
15
15
  headers: r(o)
16
16
  });
17
17
  return i({
18
- ...t(u, c),
19
- enabled: l
18
+ ...t(d, {
19
+ authEpoch: c,
20
+ organizationPending: l
21
+ }),
22
+ enabled: u
20
23
  });
21
24
  }
22
25
  //#endregion
@@ -10,14 +10,17 @@ import "../../../../shared/data-access/dist/index.js";
10
10
  import { useQuery as i } from "@tanstack/react-query";
11
11
  //#region ../../libs/tesouro-embedded-components-react/settings-widget/invoice-settings/data-access/dist/index3.js
12
12
  function a(a) {
13
- let { client: o, organizationId: s, widgetToken: c, authEpoch: l } = n(), u = !!(s && c && a), d = e({
13
+ let { client: o, organizationId: s, widgetToken: c, authEpoch: l, organizationPending: u } = n(), d = !!(s && c && a), f = e({
14
14
  client: o,
15
15
  headers: r(s),
16
16
  path: { entity_id: a ?? "" }
17
17
  });
18
18
  return i({
19
- ...t(d, l),
20
- enabled: u
19
+ ...t(f, {
20
+ authEpoch: l,
21
+ organizationPending: u
22
+ }),
23
+ enabled: d
21
24
  });
22
25
  }
23
26
  //#endregion
@@ -10,14 +10,17 @@ import "../../../../shared/data-access/dist/index.js";
10
10
  import { useQuery as i } from "@tanstack/react-query";
11
11
  //#region ../../libs/tesouro-embedded-components-react/settings-widget/invoice-settings/data-access/dist/index4.js
12
12
  function a(a) {
13
- let { client: o, organizationId: s, widgetToken: c, authEpoch: l } = n(), u = !!(s && c && a), d = e({
13
+ let { client: o, organizationId: s, widgetToken: c, authEpoch: l, organizationPending: u } = n(), d = !!(s && c && a), f = e({
14
14
  client: o,
15
15
  headers: r(s),
16
16
  path: { entity_id: a ?? "" }
17
17
  });
18
18
  return i({
19
- ...t(d, l),
20
- enabled: u
19
+ ...t(f, {
20
+ authEpoch: l,
21
+ organizationPending: u
22
+ }),
23
+ enabled: d
21
24
  });
22
25
  }
23
26
  //#endregion
@@ -11,15 +11,18 @@ import "../../../../shared/data-access/dist/index.js";
11
11
  import { useQuery as a } from "@tanstack/react-query";
12
12
  //#region ../../libs/tesouro-embedded-components-react/settings-widget/profile/data-access/dist/index2.js
13
13
  function o({ enabled: o } = {}) {
14
- let { client: s, organizationId: c, widgetToken: l, authEpoch: u } = n(), d = !!(c && l) && (o === !0 || o === void 0);
14
+ let { client: s, organizationId: c, widgetToken: l, authEpoch: u, organizationPending: d } = n(), f = !!(c && l) && (o === !0 || o === void 0);
15
15
  return {
16
- userQuery: i({ enabled: d }),
16
+ userQuery: i({ enabled: f }),
17
17
  entityQuery: a({
18
18
  ...t(e({
19
19
  client: s,
20
20
  headers: r(c)
21
- }), u),
22
- enabled: d
21
+ }), {
22
+ authEpoch: u,
23
+ organizationPending: d
24
+ }),
25
+ enabled: f
23
26
  })
24
27
  };
25
28
  }
@@ -11,14 +11,17 @@ import { useQuery as i } from "@tanstack/react-query";
11
11
  //#region ../../libs/tesouro-embedded-components-react/settings-widget/tags/data-access/dist/index10.js
12
12
  var a = 100;
13
13
  function o(o = a) {
14
- let { client: s, organizationId: c, widgetToken: l, authEpoch: u } = n(), d = !!(c && l), f = e({
14
+ let { client: s, organizationId: c, widgetToken: l, authEpoch: u, organizationPending: d } = n(), f = !!(c && l), p = e({
15
15
  query: { limit: o },
16
16
  client: s,
17
17
  headers: r(c)
18
18
  });
19
19
  return i({
20
- ...t(f, u),
21
- enabled: d
20
+ ...t(p, {
21
+ authEpoch: u,
22
+ organizationPending: d
23
+ }),
24
+ enabled: f
22
25
  });
23
26
  }
24
27
  //#endregion