@loczer/storefront-sdk 0.198.0 → 0.199.0

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 (45) hide show
  1. package/dist/StorefrontContext.d.ts +483 -0
  2. package/dist/StorefrontContext.d.ts.map +1 -0
  3. package/dist/StorefrontContext.js +39 -0
  4. package/dist/StorefrontProvider.d.ts +6 -486
  5. package/dist/StorefrontProvider.d.ts.map +1 -1
  6. package/dist/StorefrontProvider.js +34 -67
  7. package/dist/components/AboutSection/index.js +5 -5
  8. package/dist/components/BikeProductCard/index.d.ts.map +1 -1
  9. package/dist/components/BikeProductCard/index.js +27 -27
  10. package/dist/components/BookingBikeVariantDialog/index.js +14 -8
  11. package/dist/components/ContactSection/index.js +107 -107
  12. package/dist/components/ContractSaleDocument/Invoice.d.ts.map +1 -1
  13. package/dist/components/ContractSaleDocument/Invoice.js +117 -111
  14. package/dist/components/Header/index.js +4 -4
  15. package/dist/components/Layout/index.d.ts.map +1 -1
  16. package/dist/components/Layout/index.js +47 -40
  17. package/dist/components/ProductPriceBadge/index.d.ts +2 -1
  18. package/dist/components/ProductPriceBadge/index.d.ts.map +1 -1
  19. package/dist/components/ProductPriceBadge/index.js +72 -70
  20. package/dist/components/TestimonialsSection/index.js +1 -1
  21. package/dist/i18n/en.d.ts +1 -0
  22. package/dist/i18n/en.d.ts.map +1 -1
  23. package/dist/i18n/en.js +1 -0
  24. package/dist/i18n/fr.d.ts +1 -0
  25. package/dist/i18n/fr.d.ts.map +1 -1
  26. package/dist/i18n/fr.js +1 -0
  27. package/dist/index.d.ts +15 -2
  28. package/dist/index.js +59 -58
  29. package/dist/lib/cartSummary.js +7 -7
  30. package/dist/lib/products.d.ts +6 -0
  31. package/dist/lib/products.d.ts.map +1 -1
  32. package/dist/lib/products.js +36 -32
  33. package/dist/lib/toast.d.ts +9 -0
  34. package/dist/lib/toast.d.ts.map +1 -0
  35. package/dist/lib/toast.js +13 -0
  36. package/dist/pages/BookingPage.d.ts.map +1 -1
  37. package/dist/pages/BookingPage.js +143 -138
  38. package/dist/pages/CheckoutPage.js +217 -217
  39. package/dist/pages/CheckoutPaymentPage.js +124 -124
  40. package/dist/pages/ContractSaleDocumentPage.d.ts.map +1 -1
  41. package/dist/pages/ContractSaleDocumentPage.js +83 -83
  42. package/dist/pages/HomePage.js +6 -3
  43. package/dist/pages/ProductPage.d.ts.map +1 -1
  44. package/dist/pages/ProductPage.js +177 -165
  45. package/package.json +2 -1
@@ -1,28 +1,28 @@
1
1
  import { pickBookingSearchParams as e } from "../lib/booking.js";
2
2
  import { useStorefrontCart as t } from "../lib/cart.js";
3
3
  import { Button as n } from "../ui/button.js";
4
- import { Card as r } from "../ui/card.js";
5
- import { apiPost as i } from "../lib/apiCall.js";
6
- import { Spinner as a } from "../chunks/pkg/ui/dist/Spinner/index-Cgi70z_E.js";
7
- import { ROUTE as o, responseSchema as ee } from "../lib/checkoutPaymentSession.js";
8
- import { MollieCardFieldsForm as s } from "../components/payment/MollieCardFieldsForm.js";
9
- import { StripeCardFieldsForm as c } from "../components/payment/StripeCardFieldsForm.js";
4
+ import { toast as r } from "../lib/toast.js";
5
+ import { Card as i } from "../ui/card.js";
6
+ import { apiPost as a } from "../lib/apiCall.js";
7
+ import { Spinner as o } from "../chunks/pkg/ui/dist/Spinner/index-Cgi70z_E.js";
8
+ import { ROUTE as s, responseSchema as c } from "../lib/checkoutPaymentSession.js";
9
+ import { MollieCardFieldsForm as l } from "../components/payment/MollieCardFieldsForm.js";
10
+ import { StripeCardFieldsForm as u } from "../components/payment/StripeCardFieldsForm.js";
10
11
  import "../components/payment/index.js";
11
- import { useEffect as l, useMemo as u, useRef as d, useState as f } from "react";
12
- import { jsx as p, jsxs as m } from "react/jsx-runtime";
13
- import { toast as te } from "@rpcbase/client";
14
- import { Link as h, useNavigate as g, useParams as _, useSearchParams as v } from "@rpcbase/router";
15
- import { useTranslation as y } from "react-i18next";
16
- import { AlertTriangle as b, ArrowRight as ne, CheckCircle2 as re, CircleDashed as ie, ShieldCheck as ae, XCircle as oe } from "lucide-react";
17
- import { loadStripe as se } from "@stripe/stripe-js";
18
- import { Elements as x, useStripe as S } from "@stripe/react-stripe-js";
19
- var C = {
12
+ import { useEffect as d, useMemo as f, useRef as p, useState as m } from "react";
13
+ import { jsx as h, jsxs as g } from "react/jsx-runtime";
14
+ import { Link as _, useNavigate as ee, useParams as te, useSearchParams as ne } from "@rpcbase/router";
15
+ import { useTranslation as v } from "react-i18next";
16
+ import { AlertTriangle as y, ArrowRight as b, CheckCircle2 as x, CircleDashed as re, ShieldCheck as S, XCircle as ie } from "lucide-react";
17
+ import { loadStripe as ae } from "@stripe/stripe-js";
18
+ import { Elements as oe, useStripe as C } from "@stripe/react-stripe-js";
19
+ var w = {
20
20
  BASE_URL: "/",
21
21
  DEV: !1,
22
22
  MODE: "production",
23
23
  PROD: !0,
24
24
  SSR: !1
25
- }.RB_PUBLIC_STRIPE_PUBLISHABLE_KEY?.trim() ?? "", w = 20, T = 2500, ce = (e, t, n) => {
25
+ }.RB_PUBLIC_STRIPE_PUBLISHABLE_KEY?.trim() ?? "", T = 20, E = 2500, se = (e, t, n) => {
26
26
  try {
27
27
  return new Intl.NumberFormat(n, {
28
28
  style: "currency",
@@ -32,9 +32,9 @@ var C = {
32
32
  return `${(e / 100).toFixed(2)} ${t.toUpperCase()}`;
33
33
  }
34
34
  };
35
- function le({ clientSecret: e, onSuccess: t }) {
36
- let { t: n } = y(), r = S();
37
- return /* @__PURE__ */ p(c, {
35
+ function ce({ clientSecret: e, onSuccess: t }) {
36
+ let { t: n } = v(), r = C();
37
+ return /* @__PURE__ */ h(u, {
38
38
  requireEmail: !1,
39
39
  submitLabel: n("checkout_payment_authorize_button"),
40
40
  submittingLabel: n("checkout_payment_authorizing_button"),
@@ -48,36 +48,36 @@ function le({ clientSecret: e, onSuccess: t }) {
48
48
  }
49
49
  });
50
50
  }
51
- function E() {
52
- let { t: e } = y();
53
- return /* @__PURE__ */ m("div", {
51
+ function le() {
52
+ let { t: e } = v();
53
+ return /* @__PURE__ */ g("div", {
54
54
  className: "flex min-h-48 items-center justify-center gap-2 text-sm text-slate-600",
55
- children: [/* @__PURE__ */ p(a, {
55
+ children: [/* @__PURE__ */ h(o, {
56
56
  className: "size-4",
57
57
  "aria-hidden": "true"
58
- }), /* @__PURE__ */ p("span", { children: e("secure_payment_link.form.loading_session") })]
58
+ }), /* @__PURE__ */ h("span", { children: e("secure_payment_link.form.loading_session") })]
59
59
  });
60
60
  }
61
61
  function D() {
62
- let { t: a, i18n: c } = y(), { storeSlug: S } = _(), D = g(), { clear: O } = t(), [k] = v(), [A, j] = f(null), [ue, M] = f(!0), [N, P] = f(null), [F, I] = f(0), [L, R] = f(0), z = d(!1), B = d(null), V = k.get("checkout_session_id")?.trim() ?? "", H = new URLSearchParams(k.toString());
62
+ let { t: o, i18n: u } = v(), { storeSlug: C } = te(), D = ee(), { clear: O } = t(), [k] = ne(), [A, j] = m(null), [ue, M] = m(!0), [N, P] = m(null), [F, I] = m(0), [L, R] = m(0), z = p(!1), B = p(null), V = k.get("checkout_session_id")?.trim() ?? "", H = new URLSearchParams(k.toString());
63
63
  H.delete("checkout_session_id");
64
- let U = e(H).toString(), W = `/${S ?? ""}/checkout${U ? `?${U}` : ""}`, G = `/${S ?? ""}/checkout/success${U ? `?${U}` : ""}`, K = async (e) => {
65
- if (!S || !V) throw Error(a("checkout_payment_return_missing_session"));
66
- let t = await i(o, {
67
- storeSlug: S,
64
+ let U = e(H).toString(), W = `/${C ?? ""}/checkout${U ? `?${U}` : ""}`, G = `/${C ?? ""}/checkout/success${U ? `?${U}` : ""}`, K = async (e) => {
65
+ if (!C || !V) throw Error(o("checkout_payment_return_missing_session"));
66
+ let t = await a(s, {
67
+ storeSlug: C,
68
68
  checkoutSessionId: V,
69
69
  returnSearch: U || void 0,
70
70
  cardToken: e
71
71
  });
72
- return ee.parse(t);
72
+ return c.parse(t);
73
73
  }, q = async () => {
74
- z.current || (z.current = !0, te.success(a("checkout_success_toast")), await D(G, { replace: !0 }), O());
74
+ z.current || (z.current = !0, r.success(o("checkout_success_toast")), await D(G, { replace: !0 }), O());
75
75
  };
76
- l(() => {
76
+ d(() => {
77
77
  z.current = !1, B.current = null, j(null), M(!0), R(0);
78
- }, [V]), l(() => {
79
- if (!S || !V) {
80
- B.current = null, j(null), P(a("checkout_payment_return_missing_session")), M(!1);
78
+ }, [V]), d(() => {
79
+ if (!C || !V) {
80
+ B.current = null, j(null), P(o("checkout_payment_return_missing_session")), M(!1);
81
81
  return;
82
82
  }
83
83
  let e = !1, t = B.current === null;
@@ -86,7 +86,7 @@ function D() {
86
86
  let t = await K();
87
87
  if (e) return;
88
88
  if (!t.success) {
89
- B.current = null, j(null), P(t.message || a("checkout_payment_return_status_error"));
89
+ B.current = null, j(null), P(t.message || o("checkout_payment_return_status_error"));
90
90
  return;
91
91
  }
92
92
  B.current = t, j(t);
@@ -94,7 +94,7 @@ function D() {
94
94
  (n === "authorized" || n === "succeeded") && !z.current && await q();
95
95
  } catch (t) {
96
96
  if (e) return;
97
- console.error("Failed to fetch checkout payment session", t), B.current = null, j(null), P(a("checkout_payment_return_status_error"));
97
+ console.error("Failed to fetch checkout payment session", t), B.current = null, j(null), P(o("checkout_payment_return_status_error"));
98
98
  } finally {
99
99
  !e && t && M(!1);
100
100
  }
@@ -107,16 +107,16 @@ function D() {
107
107
  D,
108
108
  U,
109
109
  F,
110
- S,
110
+ C,
111
111
  G,
112
- a
112
+ o
113
113
  ]);
114
114
  let J = A?.paymentStatus ?? "pending";
115
- l(() => {
116
- if (J !== "pending" || A?.providerType === "stripe_connect_oauth" || L >= w || !A?.payment?.providerPaymentId) return;
115
+ d(() => {
116
+ if (J !== "pending" || A?.providerType === "stripe_connect_oauth" || L >= T || !A?.payment?.providerPaymentId) return;
117
117
  let e = window.setTimeout(() => {
118
118
  R((e) => e + 1), I((e) => e + 1);
119
- }, T);
119
+ }, E);
120
120
  return () => {
121
121
  window.clearTimeout(e);
122
122
  };
@@ -126,200 +126,200 @@ function D() {
126
126
  A?.payment?.providerPaymentId,
127
127
  A?.providerType
128
128
  ]);
129
- let Y = u(() => {
130
- let e = A?.stripePublishableKey?.trim() || C;
131
- return !e || !A?.providerAccountId ? null : se(e, { stripeAccount: A.providerAccountId });
132
- }, [A?.providerAccountId, A?.stripePublishableKey]), X = u(() => {
129
+ let Y = f(() => {
130
+ let e = A?.stripePublishableKey?.trim() || w;
131
+ return !e || !A?.providerAccountId ? null : ae(e, { stripeAccount: A.providerAccountId });
132
+ }, [A?.providerAccountId, A?.stripePublishableKey]), X = f(() => {
133
133
  if (A?.clientSecret) return { clientSecret: A.clientSecret };
134
134
  }, [A?.clientSecret]);
135
- if (!V) return /* @__PURE__ */ p("div", {
135
+ if (!V) return /* @__PURE__ */ h("div", {
136
136
  className: "mx-auto max-w-3xl px-4 py-14 sm:px-6",
137
- children: /* @__PURE__ */ p(r, {
137
+ children: /* @__PURE__ */ h(i, {
138
138
  className: "border-destructive/25 bg-white p-5 sm:p-6 shadow-sm",
139
- children: /* @__PURE__ */ m("div", {
139
+ children: /* @__PURE__ */ g("div", {
140
140
  className: "space-y-4",
141
- children: [/* @__PURE__ */ m("div", {
141
+ children: [/* @__PURE__ */ g("div", {
142
142
  className: "flex items-start gap-3",
143
- children: [/* @__PURE__ */ p(b, {
143
+ children: [/* @__PURE__ */ h(y, {
144
144
  className: "mt-0.5 h-5 w-5 text-destructive",
145
145
  "aria-hidden": "true"
146
- }), /* @__PURE__ */ p("p", {
146
+ }), /* @__PURE__ */ h("p", {
147
147
  className: "text-sm text-slate-700",
148
- children: /* @__PURE__ */ p("span", { children: a("checkout_payment_return_missing_session") })
148
+ children: /* @__PURE__ */ h("span", { children: o("checkout_payment_return_missing_session") })
149
149
  })]
150
- }), /* @__PURE__ */ p(h, {
150
+ }), /* @__PURE__ */ h(_, {
151
151
  to: W,
152
- children: /* @__PURE__ */ p(n, {
152
+ children: /* @__PURE__ */ h(n, {
153
153
  variant: "outline",
154
- children: /* @__PURE__ */ p("span", { children: a("checkout_payment_return_back_to_checkout") })
154
+ children: /* @__PURE__ */ h("span", { children: o("checkout_payment_return_back_to_checkout") })
155
155
  })
156
156
  })]
157
157
  })
158
158
  })
159
159
  });
160
- if (ue && !A) return /* @__PURE__ */ p("div", {
160
+ if (ue && !A) return /* @__PURE__ */ h("div", {
161
161
  className: "mx-auto max-w-3xl px-4 py-14 sm:px-6",
162
- children: /* @__PURE__ */ p(r, {
162
+ children: /* @__PURE__ */ h(i, {
163
163
  className: "border-slate-200 bg-white p-5 sm:p-6 shadow-sm",
164
- children: /* @__PURE__ */ p(E, {})
164
+ children: /* @__PURE__ */ h(le, {})
165
165
  })
166
166
  });
167
- if (N || !A) return /* @__PURE__ */ p("div", {
167
+ if (N || !A) return /* @__PURE__ */ h("div", {
168
168
  className: "mx-auto max-w-3xl px-4 py-14 sm:px-6",
169
- children: /* @__PURE__ */ p(r, {
169
+ children: /* @__PURE__ */ h(i, {
170
170
  className: "border-destructive/25 bg-white p-5 sm:p-6 shadow-sm",
171
- children: /* @__PURE__ */ m("div", {
171
+ children: /* @__PURE__ */ g("div", {
172
172
  className: "space-y-4",
173
- children: [/* @__PURE__ */ m("div", {
173
+ children: [/* @__PURE__ */ g("div", {
174
174
  className: "flex items-start gap-3",
175
- children: [/* @__PURE__ */ p(b, {
175
+ children: [/* @__PURE__ */ h(y, {
176
176
  className: "mt-0.5 h-5 w-5 text-destructive",
177
177
  "aria-hidden": "true"
178
- }), /* @__PURE__ */ p("p", {
178
+ }), /* @__PURE__ */ h("p", {
179
179
  className: "text-sm text-slate-700",
180
- children: /* @__PURE__ */ p("span", { children: N ?? a("checkout_payment_return_status_error") })
180
+ children: /* @__PURE__ */ h("span", { children: N ?? o("checkout_payment_return_status_error") })
181
181
  })]
182
- }), /* @__PURE__ */ p(h, {
182
+ }), /* @__PURE__ */ h(_, {
183
183
  to: W,
184
- children: /* @__PURE__ */ p(n, {
184
+ children: /* @__PURE__ */ h(n, {
185
185
  variant: "outline",
186
- children: /* @__PURE__ */ p("span", { children: a("checkout_payment_return_back_to_checkout") })
186
+ children: /* @__PURE__ */ h("span", { children: o("checkout_payment_return_back_to_checkout") })
187
187
  })
188
188
  })]
189
189
  })
190
190
  })
191
191
  });
192
- let Z = typeof A.amountMinor == "number" && A.currency ? ce(A.amountMinor, A.currency, c.language) : null, Q = J === "authorized" || J === "succeeded", $ = J === "failed" || J === "cancelled", de = Q ? re : $ ? oe : ie, fe = Q ? "text-success" : $ ? "text-destructive" : "text-warning";
193
- return /* @__PURE__ */ p("div", {
192
+ let Z = typeof A.amountMinor == "number" && A.currency ? se(A.amountMinor, A.currency, u.language) : null, Q = J === "authorized" || J === "succeeded", $ = J === "failed" || J === "cancelled", de = Q ? x : $ ? ie : re, fe = Q ? "text-success" : $ ? "text-destructive" : "text-warning";
193
+ return /* @__PURE__ */ h("div", {
194
194
  className: "mx-auto max-w-5xl px-4 py-10 sm:px-6",
195
- children: /* @__PURE__ */ m("div", {
195
+ children: /* @__PURE__ */ g("div", {
196
196
  className: "grid gap-6 lg:grid-cols-[1fr_1fr]",
197
- children: [/* @__PURE__ */ p(r, {
197
+ children: [/* @__PURE__ */ h(i, {
198
198
  className: "border-slate-200 bg-white p-5 shadow-sm",
199
- children: /* @__PURE__ */ m("div", {
199
+ children: /* @__PURE__ */ g("div", {
200
200
  className: "space-y-5",
201
201
  children: [
202
- /* @__PURE__ */ m("div", {
202
+ /* @__PURE__ */ g("div", {
203
203
  className: "inline-flex items-center gap-2 rounded-full border border-success-border bg-success-subtle px-3 py-1 text-xs font-medium text-success",
204
- children: [/* @__PURE__ */ p(ae, {
204
+ children: [/* @__PURE__ */ h(S, {
205
205
  className: "h-3.5 w-3.5",
206
206
  "aria-hidden": "true"
207
- }), /* @__PURE__ */ p("span", { children: a("secure_payment_link.secured_badge") })]
207
+ }), /* @__PURE__ */ h("span", { children: o("secure_payment_link.secured_badge") })]
208
208
  }),
209
- /* @__PURE__ */ m("div", { children: [/* @__PURE__ */ p("h1", {
209
+ /* @__PURE__ */ g("div", { children: [/* @__PURE__ */ h("h1", {
210
210
  className: "text-2xl font-semibold tracking-tight text-slate-950",
211
- children: /* @__PURE__ */ p("span", { children: a("checkout_payment_title") })
212
- }), /* @__PURE__ */ p("p", {
211
+ children: /* @__PURE__ */ h("span", { children: o("checkout_payment_title") })
212
+ }), /* @__PURE__ */ h("p", {
213
213
  className: "mt-2 text-sm text-slate-600",
214
- children: /* @__PURE__ */ p("span", { children: a("checkout_payment_hold_description") })
214
+ children: /* @__PURE__ */ h("span", { children: o("checkout_payment_hold_description") })
215
215
  })] }),
216
- /* @__PURE__ */ m("dl", {
216
+ /* @__PURE__ */ g("dl", {
217
217
  className: "grid gap-3 rounded-xl border border-slate-200 bg-slate-50 p-4 text-sm",
218
- children: [Z ? /* @__PURE__ */ m("div", {
218
+ children: [Z ? /* @__PURE__ */ g("div", {
219
219
  className: "flex items-center justify-between gap-3",
220
- children: [/* @__PURE__ */ p("dt", {
220
+ children: [/* @__PURE__ */ h("dt", {
221
221
  className: "text-slate-600",
222
- children: /* @__PURE__ */ p("span", { children: a("checkout_payment_hold_amount") })
223
- }), /* @__PURE__ */ p("dd", {
222
+ children: /* @__PURE__ */ h("span", { children: o("checkout_payment_hold_amount") })
223
+ }), /* @__PURE__ */ h("dd", {
224
224
  className: "font-semibold text-slate-950",
225
- children: /* @__PURE__ */ p("span", { children: Z })
225
+ children: /* @__PURE__ */ h("span", { children: Z })
226
226
  })]
227
- }) : null, A.providerType ? /* @__PURE__ */ m("div", {
227
+ }) : null, A.providerType ? /* @__PURE__ */ g("div", {
228
228
  className: "flex items-center justify-between gap-3",
229
- children: [/* @__PURE__ */ p("dt", {
229
+ children: [/* @__PURE__ */ h("dt", {
230
230
  className: "text-slate-600",
231
- children: /* @__PURE__ */ p("span", { children: a("checkout_payment_provider") })
232
- }), /* @__PURE__ */ p("dd", {
231
+ children: /* @__PURE__ */ h("span", { children: o("checkout_payment_provider") })
232
+ }), /* @__PURE__ */ h("dd", {
233
233
  className: "font-medium text-slate-950",
234
- children: /* @__PURE__ */ p("span", { children: a(`secure_payment_link.providers.${A.providerType}`) })
234
+ children: /* @__PURE__ */ h("span", { children: o(`secure_payment_link.providers.${A.providerType}`) })
235
235
  })]
236
236
  }) : null]
237
237
  })
238
238
  ]
239
239
  })
240
- }), /* @__PURE__ */ p(r, {
240
+ }), /* @__PURE__ */ h(i, {
241
241
  className: "border-slate-200 bg-white p-5 shadow-sm",
242
- children: Q || $ ? /* @__PURE__ */ m("div", {
242
+ children: Q || $ ? /* @__PURE__ */ g("div", {
243
243
  className: "space-y-6 text-center",
244
244
  children: [
245
- /* @__PURE__ */ p("div", {
245
+ /* @__PURE__ */ h("div", {
246
246
  className: "mx-auto flex h-12 w-12 items-center justify-center rounded-full bg-slate-100",
247
- children: /* @__PURE__ */ p(de, {
247
+ children: /* @__PURE__ */ h(de, {
248
248
  className: `h-6 w-6 ${fe}`,
249
249
  "aria-hidden": "true"
250
250
  })
251
251
  }),
252
- /* @__PURE__ */ m("div", {
252
+ /* @__PURE__ */ g("div", {
253
253
  className: "space-y-2",
254
- children: [/* @__PURE__ */ p("h2", {
254
+ children: [/* @__PURE__ */ h("h2", {
255
255
  className: "text-xl font-semibold text-slate-950",
256
- children: /* @__PURE__ */ p("span", { children: a(`secure_payment_link.success_titles.${J}`) })
257
- }), /* @__PURE__ */ p("p", {
256
+ children: /* @__PURE__ */ h("span", { children: o(`secure_payment_link.success_titles.${J}`) })
257
+ }), /* @__PURE__ */ h("p", {
258
258
  className: "text-sm text-slate-600",
259
- children: /* @__PURE__ */ p("span", { children: a(`secure_payment_link.statuses.${J}`) })
259
+ children: /* @__PURE__ */ h("span", { children: o(`secure_payment_link.statuses.${J}`) })
260
260
  })]
261
261
  }),
262
- Q ? /* @__PURE__ */ p(h, {
262
+ Q ? /* @__PURE__ */ h(_, {
263
263
  to: G,
264
- children: /* @__PURE__ */ m(n, {
264
+ children: /* @__PURE__ */ g(n, {
265
265
  className: "gap-2",
266
- children: [/* @__PURE__ */ p("span", { children: a("checkout_payment_return_go_to_success") }), /* @__PURE__ */ p(ne, {
266
+ children: [/* @__PURE__ */ h("span", { children: o("checkout_payment_return_go_to_success") }), /* @__PURE__ */ h(b, {
267
267
  className: "h-4 w-4",
268
268
  "aria-hidden": "true"
269
269
  })]
270
270
  })
271
- }) : /* @__PURE__ */ p(h, {
271
+ }) : /* @__PURE__ */ h(_, {
272
272
  to: W,
273
- children: /* @__PURE__ */ p(n, { children: /* @__PURE__ */ p("span", { children: a("checkout_payment_return_retry_checkout") }) })
273
+ children: /* @__PURE__ */ h(n, { children: /* @__PURE__ */ h("span", { children: o("checkout_payment_return_retry_checkout") }) })
274
274
  })
275
275
  ]
276
- }) : A.providerType === "mollie_connect_oauth" ? /* @__PURE__ */ m("div", {
276
+ }) : A.providerType === "mollie_connect_oauth" ? /* @__PURE__ */ g("div", {
277
277
  className: "space-y-4",
278
278
  children: [
279
- /* @__PURE__ */ p("h2", {
279
+ /* @__PURE__ */ h("h2", {
280
280
  className: "text-lg font-semibold text-slate-950",
281
- children: /* @__PURE__ */ p("span", { children: a("secure_payment_link.mollie.form_title") })
281
+ children: /* @__PURE__ */ h("span", { children: o("secure_payment_link.mollie.form_title") })
282
282
  }),
283
- /* @__PURE__ */ p("p", {
283
+ /* @__PURE__ */ h("p", {
284
284
  className: "text-sm text-slate-600",
285
- children: /* @__PURE__ */ p("span", { children: a("checkout_payment_hold_form_description") })
285
+ children: /* @__PURE__ */ h("span", { children: o("checkout_payment_hold_form_description") })
286
286
  }),
287
- A.profileId ? /* @__PURE__ */ p(s, {
287
+ A.profileId ? /* @__PURE__ */ h(l, {
288
288
  profileId: A.profileId,
289
289
  testmode: A.testmode === !0,
290
- submitLabel: a("checkout_payment_authorize_button"),
291
- submittingLabel: a("checkout_payment_authorizing_button"),
290
+ submitLabel: o("checkout_payment_authorize_button"),
291
+ submittingLabel: o("checkout_payment_authorizing_button"),
292
292
  onSubmit: async (e) => {
293
293
  let t = await K(e);
294
- if (!t.success) throw Error(t.message || a("secure_payment_link.errors.payment_failed"));
294
+ if (!t.success) throw Error(t.message || o("secure_payment_link.errors.payment_failed"));
295
295
  if (B.current = t, j(t), t.paymentStatus === "authorized" || t.paymentStatus === "succeeded") {
296
296
  await q();
297
297
  return;
298
298
  }
299
- if (!t.checkoutUrl) throw Error(t.message || a("secure_payment_link.errors.mollie_missing_url"));
299
+ if (!t.checkoutUrl) throw Error(t.message || o("secure_payment_link.errors.mollie_missing_url"));
300
300
  let n = new URL(t.checkoutUrl, window.location.origin).toString();
301
301
  window.location.assign(n);
302
302
  }
303
- }) : /* @__PURE__ */ p("p", {
303
+ }) : /* @__PURE__ */ h("p", {
304
304
  className: "text-sm text-destructive",
305
- children: /* @__PURE__ */ p("span", { children: a("secure_payment_link.errors.session_failed") })
305
+ children: /* @__PURE__ */ h("span", { children: o("secure_payment_link.errors.session_failed") })
306
306
  })
307
307
  ]
308
- }) : A.providerType === "stripe_connect_oauth" ? !A.clientSecret || !Y || !X ? /* @__PURE__ */ p("p", {
308
+ }) : A.providerType === "stripe_connect_oauth" ? !A.clientSecret || !Y || !X ? /* @__PURE__ */ h("p", {
309
309
  className: "text-sm text-destructive",
310
- children: /* @__PURE__ */ p("span", { children: a("secure_payment_link.errors.missing_publishable_key") })
311
- }) : /* @__PURE__ */ p(x, {
310
+ children: /* @__PURE__ */ h("span", { children: o("secure_payment_link.errors.missing_publishable_key") })
311
+ }) : /* @__PURE__ */ h(oe, {
312
312
  stripe: Y,
313
313
  options: X,
314
- children: /* @__PURE__ */ p(le, {
314
+ children: /* @__PURE__ */ h(ce, {
315
315
  clientSecret: A.clientSecret,
316
316
  onSuccess: () => {
317
317
  q();
318
318
  }
319
319
  })
320
- }, A.clientSecret) : /* @__PURE__ */ p("p", {
320
+ }, A.clientSecret) : /* @__PURE__ */ h("p", {
321
321
  className: "text-sm text-destructive",
322
- children: /* @__PURE__ */ p("span", { children: a("secure_payment_link.errors.session_failed") })
322
+ children: /* @__PURE__ */ h("span", { children: o("secure_payment_link.errors.session_failed") })
323
323
  })
324
324
  })]
325
325
  })
@@ -1 +1 @@
1
- {"version":3,"file":"ContractSaleDocumentPage.d.ts","sourceRoot":"","sources":["../../src/pages/ContractSaleDocumentPage.tsx"],"names":[],"mappings":"AAoBA,OAAO,EAAmC,KAAK,sBAAsB,EAAE,MAAM,sBAAsB,CAAA;AAsLnG,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAkEA,CAAA;AAYnB,MAAM,CAAC,OAAO,UAAU,wBAAwB,4CAqP/C"}
1
+ {"version":3,"file":"ContractSaleDocumentPage.d.ts","sourceRoot":"","sources":["../../src/pages/ContractSaleDocumentPage.tsx"],"names":[],"mappings":"AAqBA,OAAO,EAAmC,KAAK,sBAAsB,EAAE,MAAM,sBAAsB,CAAA;AAsLnG,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAkEA,CAAA;AAYnB,MAAM,CAAC,OAAO,UAAU,wBAAwB,4CAqP/C"}