@soma-vertical-web/multi-lib 0.0.23 → 0.0.25

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 (107) hide show
  1. package/cms/ContentTypes/CommonPage/CommonPage.d.ts +3 -0
  2. package/cms/ContentTypes/CommonPage/DataScreening.d.ts +6 -0
  3. package/cms/ContentTypes/CommonPage/index.d.ts +2 -0
  4. package/cms/ContentTypes/FlagsAndTags/index.d.ts +1 -0
  5. package/cms/ContentTypes/index.d.ts +6 -0
  6. package/cms/Factories/common.d.ts +7 -0
  7. package/cms/Factories/contentType.d.ts +9 -0
  8. package/cms/Factories/index.d.ts +2 -0
  9. package/cms/Factories/section.d.ts +7 -0
  10. package/cms/Sections/Banner/Component.d.ts +7 -0
  11. package/cms/Sections/Banner/Composite/Content.d.ts +4 -0
  12. package/cms/Sections/Banner/Composite/Slot.d.ts +0 -0
  13. package/cms/Sections/Banner/adapter.d.ts +32 -0
  14. package/cms/Sections/Banner/index.d.ts +8 -0
  15. package/cms/Sections/BennefitsBar/Component.d.ts +3 -0
  16. package/cms/Sections/BennefitsBar/index.d.ts +8 -0
  17. package/cms/Sections/TextContent/Component.d.ts +4 -0
  18. package/cms/Sections/TextContent/Composite/Content.d.ts +6 -0
  19. package/cms/Sections/TextContent/Composite/ContentWrapper.d.ts +3 -0
  20. package/cms/Sections/TextContent/adapter.d.ts +3 -0
  21. package/cms/Sections/TextContent/index.d.ts +5 -0
  22. package/cms/Sections/_common/Accordion.d.ts +2 -0
  23. package/cms/Sections/_common/BannerItem.d.ts +5 -0
  24. package/cms/Sections/_common/TextStructure.d.ts +17 -0
  25. package/cms/Sections/_common/interfaces.d.ts +8 -0
  26. package/cms/Sections/index.d.ts +10 -0
  27. package/cms/helpers/index.d.ts +4 -1
  28. package/cms/index.d.ts +13 -7
  29. package/cms/ui/ContentTypes/CommonPage/CommonPage.d.ts +3 -0
  30. package/cms/ui/ContentTypes/CommonPage/DataScreening.d.ts +6 -0
  31. package/cms/ui/ContentTypes/CommonPage/index.d.ts +2 -0
  32. package/cms/ui/ContentTypes/index.d.ts +1 -0
  33. package/cms/ui/Factories/section.d.ts +7 -0
  34. package/cms/ui/Sections/Banner/Component.d.ts +7 -0
  35. package/cms/ui/Sections/Banner/Composite/Content.d.ts +4 -0
  36. package/cms/ui/Sections/Banner/Composite/Slot.d.ts +0 -0
  37. package/cms/ui/Sections/Banner/adapter.d.ts +32 -0
  38. package/cms/ui/Sections/Banner/index.d.ts +8 -0
  39. package/cms/ui/Sections/TextContent/Component.d.ts +4 -0
  40. package/cms/ui/Sections/TextContent/Composite/Content.d.ts +3 -0
  41. package/cms/ui/Sections/TextContent/Composite/ContentWrapper.d.ts +3 -0
  42. package/cms/ui/Sections/TextContent/adapter.d.ts +3 -0
  43. package/cms/ui/Sections/TextContent/index.d.ts +8 -0
  44. package/cms/ui/Sections/_common/Accordion.d.ts +2 -0
  45. package/cms/ui/Sections/_common/BannerItem.d.ts +5 -0
  46. package/cms/ui/Sections/_common/TextStructure.d.ts +17 -0
  47. package/cms/ui/Sections/_common/interfaces.d.ts +8 -0
  48. package/cms/ui/Sections/index.d.ts +4 -0
  49. package/data/api/cms/index.d.ts +1 -1
  50. package/data/helpers/product/generalInfo.d.ts +1 -0
  51. package/index-BCZReEF1.js +4 -0
  52. package/index-BI5_UgNN.mjs +3210 -0
  53. package/index-BaPdEOcD.js +4 -0
  54. package/index-C7gBx1Sj.js +4 -0
  55. package/index-CAM8BZOC.mjs +3509 -0
  56. package/index-CG59Ho-O.mjs +3514 -0
  57. package/index-CWsS9JhJ.mjs +69 -0
  58. package/index-CqPFy76Q.mjs +3531 -0
  59. package/index-DVeRXseR.js +4 -0
  60. package/index-DXjpbLiy.js +4 -0
  61. package/index-DmJIk8vB.mjs +3210 -0
  62. package/index-KIgYoXyH.mjs +3526 -0
  63. package/index-NWyULgUV.js +4 -0
  64. package/index-T-_Ys9t7.mjs +3483 -0
  65. package/index-T1F-4OSy.js +4 -0
  66. package/index-dgE7GGD0.js +4 -0
  67. package/index-fnNrOQ41.js +1 -0
  68. package/index-tKMO8iJa.mjs +3215 -0
  69. package/index.d.ts +1 -1
  70. package/index.js +41 -4
  71. package/index.mjs +8776 -4553
  72. package/index2.js +1 -1
  73. package/index2.mjs +97 -34
  74. package/layout/index.d.ts +11 -10
  75. package/layout/team-component/Footer/Composite/Devices/Column.Mobile.d.ts +1 -1
  76. package/layout/team-component/Footer/Composite/Support/index.d.ts +3 -0
  77. package/layout/team-component/Footer/Composite/Support/item.d.ts +3 -0
  78. package/layout/team-component/Footer/Footer.d.ts +1 -1
  79. package/layout/team-component/Footer/index.d.ts +4 -1
  80. package/layout/team-component/TipBar/Composite/Fields/FieldsScreening.d.ts +1 -1
  81. package/layout/team-component/TipBar/Composite/Fields/TextContent.d.ts +1 -1
  82. package/layout/team-component/TipBar/Composite/Root.d.ts +3 -1
  83. package/layout/team-component/TipBar/index.d.ts +1 -1
  84. package/layout/utils/DraftJsLinkWrapper/index.d.ts +5 -0
  85. package/package.json +1 -1
  86. package/server.d.ts +4 -3
  87. package/style.css +1 -1
  88. package/types/cms/ContentTypes/CommonPage/index.d.ts +6 -2
  89. package/types/cms/ContentTypes/FlagsAndTags/index.d.ts +1 -1
  90. package/types/cms/ContentTypes/Footer/index.d.ts +31 -1
  91. package/types/cms/ContentTypes/Header/index.d.ts +1 -1
  92. package/types/cms/ContentTypes/LookbookPage/index.d.ts +1 -1
  93. package/types/cms/ContentTypes/Multimarcas/index.d.ts +1 -1
  94. package/types/cms/ContentTypes/NotFoundPage/index.d.ts +2 -3
  95. package/types/cms/Sections/Banner/index.d.ts +5 -1
  96. package/types/cms/Sections/BennefitsBar/index.d.ts +5 -0
  97. package/types/cms/Sections/TextContent/index.d.ts +9 -2
  98. package/types/cms/api/index.d.ts +0 -11
  99. package/types/constants.d.ts +8 -1
  100. package/types/contexts/contexts/cart/index.d.ts +1 -2
  101. package/types/contexts/store/cart.d.ts +3 -2
  102. package/types/data/api/cms/index.d.ts +11 -0
  103. package/types/data/api/search/product/index.d.ts +1 -1
  104. package/types/layout/team-components/Footer/index.d.ts +3 -0
  105. package/types/layout/team-components/Timer/index.d.ts +1 -1
  106. package/types/layout/team-components/TipBar/index.d.ts +6 -1
  107. package/types/layout/utils/index.d.ts +6 -0
@@ -0,0 +1,3210 @@
1
+ import { DefaultDraftBlockRenderMap as zr, convertFromRaw as pr, CompositeDecorator as Ur, EditorState as nt, Editor as bt } from "draft-js";
2
+ import we, { createContext as mr, useRef as X, useContext as gr, useState as Pe, useEffect as ct, useMemo as Fr } from "react";
3
+ import { jsx as w, jsxs as W, Fragment as z } from "react/jsx-runtime";
4
+ import { Utils as Re, helpers as Y, TextStructure as Pt, Icon as Rt, Button as Br, Timer as H, Banner as Ce } from "@soma-vertical-web/core-components";
5
+ import { SizesSmallExtended as oe, Mode as $r } from "@soma-vertical-web/foundations";
6
+ import { TZDate as Et } from "@date-fns/tz";
7
+ const Wr = (e, t) => {
8
+ const [n, r] = e.split(t);
9
+ return { name: n.trim(), size: r ? r.trim() : "" };
10
+ }, hr = (e, t) => {
11
+ if (!e)
12
+ return {};
13
+ const [n, r] = e.split(t);
14
+ return { color: n == null ? void 0 : n.trim(), size: r == null ? void 0 : r.trim() };
15
+ }, No = (e, t = "tamanho") => {
16
+ if (e.additionalProperty) {
17
+ const [n] = e.additionalProperty;
18
+ return n != null && n.name ? n.name.toLocaleLowerCase() === t ? n.value : e.name : "";
19
+ }
20
+ return e.name;
21
+ }, Co = (e) => e.replace(/\//g, ""), K = ({ event: e, data: t }) => {
22
+ const n = (window == null ? void 0 : window.dataLayer) || [];
23
+ t.ecommerce && n.push({
24
+ ecommerce: null
25
+ }), n.push({ ...e && { event: `custom_${e}` }, ...t });
26
+ }, C = {
27
+ configs: {
28
+ PLP_FILTERS: [{ key: "", label: "", eventLabel: "", order: 0 }],
29
+ currency: "BRL",
30
+ categoryOff: "bazar",
31
+ storeUrl: "https://www.example.com",
32
+ MAIN_IMAGE: "1",
33
+ // Default main image identifier
34
+ NAME_SPLIT_SYMBOL: "-"
35
+ },
36
+ productEvents: (e, t) => {
37
+ const { event: n, commonData: r, customData: o, promotionInfo: i, itemList: u, outsideEcommerceData: a } = e, { availableSizes: s, sizes: l, price: d } = r, f = {
38
+ ...n === "view_item" ? {
39
+ currency: C.configs.currency,
40
+ value: d,
41
+ grade_disponivel: s ?? (l ? yr(l) : "")
42
+ } : {},
43
+ ...n === "add_to_wishlist" || n === "remove_from_wishlist" ? {
44
+ value: d,
45
+ currency: C.configs.currency
46
+ } : {}
47
+ }, c = ue({
48
+ data: r,
49
+ customData: {
50
+ ...o,
51
+ ...u,
52
+ ...i
53
+ },
54
+ configs: C.configs
55
+ });
56
+ K({
57
+ event: n,
58
+ data: {
59
+ ...a,
60
+ ecommerce: {
61
+ ...u,
62
+ ...f,
63
+ items: [c]
64
+ }
65
+ }
66
+ }), typeof t == "function" && t(c, f);
67
+ },
68
+ productListEvent: (e) => {
69
+ const {
70
+ commonData: { products: t },
71
+ promotionInfo: n,
72
+ itemList: r,
73
+ outsideEcommerceData: o,
74
+ customData: i
75
+ } = e;
76
+ if (t.length === 0)
77
+ return;
78
+ const u = t.map(({ node: a }, s) => ue({
79
+ data: { ...a },
80
+ customData: {
81
+ ...n,
82
+ index: s,
83
+ ...i != null && i.item_list_name ? { item_list_name: i == null ? void 0 : i.item_list_name } : r
84
+ },
85
+ configs: C.configs
86
+ }));
87
+ K({
88
+ event: "view_item_list",
89
+ data: {
90
+ ...o,
91
+ ecommerce: {
92
+ ...i != null && i.item_list_name ? { item_list_name: i == null ? void 0 : i.item_list_name } : r,
93
+ items: u
94
+ }
95
+ }
96
+ });
97
+ },
98
+ skuEvents: (e) => {
99
+ const {
100
+ event: t,
101
+ commonData: { products: n },
102
+ customData: r,
103
+ supportData: { selectedSkus: o, price: i },
104
+ //in case of kit price and list price are here
105
+ promotionInfo: u,
106
+ itemList: a,
107
+ outsideEcommerceData: s
108
+ } = e;
109
+ let l = 0;
110
+ const d = n.map((f) => {
111
+ var p, h, _, O, R, m, E, v, P;
112
+ const c = o == null ? void 0 : o.find(
113
+ (S) => (f.productId ?? f.id) === S.productId
114
+ );
115
+ let g = { ...u, ...a };
116
+ if (c) {
117
+ const S = vr(), N = br(S, c);
118
+ N && (g = {
119
+ ...g,
120
+ ...N
121
+ }), t === "add_to_cart" && (u || a) && ot({
122
+ persistedData: S,
123
+ type: "add",
124
+ sku: (c == null ? void 0 : c.id) ?? (c == null ? void 0 : c.sku),
125
+ newData: {
126
+ promotionInfo: u,
127
+ itemList: a
128
+ }
129
+ }), t === "remove_from_cart" && ot({
130
+ persistedData: S,
131
+ type: "remove",
132
+ sku: (c == null ? void 0 : c.id) ?? (c == null ? void 0 : c.sku)
133
+ });
134
+ }
135
+ l += f.price ?? ((_ = (h = (p = c == null ? void 0 : c.offers) == null ? void 0 : p.offers) == null ? void 0 : h[0]) == null ? void 0 : _.price) ?? 0;
136
+ const y = (c == null ? void 0 : c.size) ?? hr(
137
+ (c == null ? void 0 : c.skuName) ?? (c == null ? void 0 : c.name) ?? ((O = f.itemOffered) == null ? void 0 : O.skuName),
138
+ C.configs.NAME_SPLIT_SYMBOL
139
+ ).size;
140
+ return ue({
141
+ data: f,
142
+ customData: {
143
+ ...r,
144
+ ...g ?? {
145
+ ...u,
146
+ ...a
147
+ },
148
+ item_sku: (c == null ? void 0 : c.id) ?? (c == null ? void 0 : c.sku) ?? ((R = f.itemOffered) == null ? void 0 : R.sku),
149
+ quantity: (r == null ? void 0 : r.quantity) ?? f.quantity ?? 1,
150
+ item_variant2: y,
151
+ seller_id: (c == null ? void 0 : c.sellerId) ?? (c == null ? void 0 : c.seller) ?? ((P = (v = (E = (m = c == null ? void 0 : c.offers) == null ? void 0 : m.offers) == null ? void 0 : E[0]) == null ? void 0 : v.seller) == null ? void 0 : P.identifier) ?? f.seller
152
+ },
153
+ configs: C.configs
154
+ });
155
+ });
156
+ K({
157
+ event: t,
158
+ data: {
159
+ ...s,
160
+ ecommerce: {
161
+ value: i ?? l,
162
+ currency: C.configs.currency,
163
+ items: d
164
+ }
165
+ }
166
+ });
167
+ },
168
+ filterEvent: (e) => {
169
+ var u;
170
+ const { commonData: t, customData: n, outsideEcommerceData: r } = e, o = {}, i = {};
171
+ Array.isArray(t == null ? void 0 : t.selectedFacets) && ((u = t == null ? void 0 : t.selectedFacets) != null && u.length) && ((t == null ? void 0 : t.selectedFacets).forEach(({ key: a, value: s }) => {
172
+ var f;
173
+ const l = ((f = C.configs.PLP_FILTERS.find((c) => c.key === a)) == null ? void 0 : f.eventLabel) ?? a, d = (o == null ? void 0 : o[l]) || [];
174
+ l === "price_range" && s.replace(":", "-"), o[l] = [...d, s];
175
+ }), Object.keys(o).forEach((a) => i[a] = o[a].join(", "))), K({
176
+ event: "filter",
177
+ data: {
178
+ ...r,
179
+ ...i,
180
+ ...n
181
+ }
182
+ });
183
+ },
184
+ viewCartEvent: (e) => {
185
+ var d, f, c, g, y, p, h, _, O, R;
186
+ const { commonData: t, outsideEcommerceData: n } = e, { cartStore: r } = t;
187
+ if (!r)
188
+ return;
189
+ const o = window.localStorage.getItem("persistedCartEventsData"), i = o ? JSON.parse(o) : {}, u = r.items.map((m) => {
190
+ const { promotionInfo: E, itemList: v } = i[m.id] ?? {};
191
+ return ue({
192
+ data: {
193
+ ...m,
194
+ price: m.price / 100,
195
+ listPrice: m.listPrice / 100
196
+ },
197
+ customData: {
198
+ ...E,
199
+ ...v,
200
+ item_sku: m.id ?? m.itemOffered.sku,
201
+ quantity: m.quantity ?? 1
202
+ },
203
+ configs: C.configs
204
+ });
205
+ }), a = (((d = r.totalizers.find((m) => m.name === "Total dos Itens")) == null ? void 0 : d.value) ?? 0) / 100, s = (((f = r.totalizers.find((m) => m.name === "Total dos Descontos")) == null ? void 0 : f.value) ?? 0) / 100, l = ((c = r.marketingData) == null ? void 0 : c.utmiCampaign) === "codigodavendedora" ? (g = r.marketingData) == null ? void 0 : g.utmCampaign : (p = String((y = r.openTextField) == null ? void 0 : y.value)) == null ? void 0 : p.split(" - ")[0];
206
+ K({
207
+ event: "view_cart",
208
+ data: {
209
+ ...n,
210
+ ecommerce: {
211
+ currency: C.configs.currency,
212
+ value: a + s,
213
+ total_discount: Math.abs(s),
214
+ cep_preenchido: !!((_ = (h = r.shippingData) == null ? void 0 : h.address) != null && _.postalCode),
215
+ ...l ? { seller_coupon_name: l } : {},
216
+ ...((O = r.marketingData) == null ? void 0 : O.coupon) && {
217
+ sale_coupon_name: (R = r.marketingData) == null ? void 0 : R.coupon
218
+ },
219
+ subtotal: a,
220
+ items: u
221
+ }
222
+ }
223
+ });
224
+ },
225
+ readyEvents: (e) => {
226
+ const { event: t, readyData: n } = e;
227
+ K({
228
+ event: t,
229
+ data: {
230
+ ...n
231
+ }
232
+ });
233
+ }
234
+ }, yr = (e) => e.reduce((t, n) => (n.available && t.push(n.value), t), []).toString(), Vr = (e) => {
235
+ const t = e.length;
236
+ return {
237
+ ...e && e.length > 0 ? {
238
+ item_category: e[0].includes(C.configs.categoryOff) ? "Bazar" : "Coleção",
239
+ ...e[1] ? { item_category2: e[1] } : {},
240
+ ...t > 2 ? { item_category3: e[t - 1] } : {}
241
+ } : {}
242
+ };
243
+ }, ue = ({ data: e, customData: t, configs: n }) => ({
244
+ ...Hr(e, n == null ? void 0 : n.MAIN_IMAGE),
245
+ ...Kr(e),
246
+ ...Gr(e),
247
+ ...Xr(e),
248
+ ...t
249
+ }), _r = () => {
250
+ var e, t;
251
+ return document ? ((t = (e = window.document.head.querySelector('meta[name="category"]')) == null ? void 0 : e.getAttribute("content")) == null ? void 0 : t.split("_")) ?? [] : [];
252
+ }, vr = () => {
253
+ const e = window.localStorage.getItem("persistedCartEventsData");
254
+ return e ? JSON.parse(e) : null;
255
+ }, br = (e, t) => e == null ? void 0 : e[t], ot = ({
256
+ persistedData: e,
257
+ type: t,
258
+ sku: n,
259
+ newData: r
260
+ }) => {
261
+ if (!e && t === "add") {
262
+ window.localStorage.setItem("persistedCartEventsData", JSON.stringify({ [n]: r }));
263
+ return;
264
+ }
265
+ if (e && t === "add") {
266
+ window.localStorage.setItem(
267
+ "persistedCartEventsData",
268
+ JSON.stringify({ ...e, [n]: r })
269
+ );
270
+ return;
271
+ }
272
+ e && t === "remove" && (delete e[n], window.localStorage.setItem("persistedCartEventsData", JSON.stringify(e)));
273
+ }, Hr = (e, t = "1") => {
274
+ var i, u, a, s, l, d, f, c, g, y, p;
275
+ const n = e.productReference ?? e.gtin ?? e.productRefId, r = e.image ?? ((u = (i = e.items) == null ? void 0 : i[0]) == null ? void 0 : u.images) ?? ((a = e.itemOffered) == null ? void 0 : a.image), o = r == null ? void 0 : r.find(
276
+ (h) => h.alternateName === t || h.imageLabel === t || h.keywords === t
277
+ );
278
+ return {
279
+ item_id: e.productId ?? ((s = e.isVariantOf) == null ? void 0 : s.productGroupID) ?? ((l = e.isVariationOf) == null ? void 0 : l.productGroupID) ?? ((f = (d = e.itemOffered) == null ? void 0 : d.isVariationOf) == null ? void 0 : f.productGroupID),
280
+ item_ref: /_\d$/.test(n) ? n.slice(0, -2) : n,
281
+ item_name: e.productTitle ?? e.productName ?? e.name ?? Wr((c = e.itemOffered) == null ? void 0 : c.name, C.configs.NAME_SPLIT_SYMBOL).name,
282
+ item_brand: ((g = e.brand) == null ? void 0 : g.brandName) ?? ((y = e.brand) == null ? void 0 : y.name) ?? e.brand ?? ((p = e.itemOffered) == null ? void 0 : p.brand.name),
283
+ item_url: `${C.configs.storeUrl}${e.linkText}/p`,
284
+ item_image: (o == null ? void 0 : o.url) ?? (o == null ? void 0 : o.imageUrl)
285
+ };
286
+ }, wt = (e) => Array.isArray(e) ? e.reduce((t, n) => (n.length > t.length && (t = n), t), "") : e, Kr = (e) => {
287
+ var l, d;
288
+ const { categories: t, categoriesIds: n } = e, r = t ?? ((l = e.itemOffered) == null ? void 0 : l.categories), o = n ?? ((d = e.itemOffered) == null ? void 0 : d.categoriesIds), i = wt(r), u = wt(o), a = i.slice(1, -1).split("/"), s = u.slice(1, -1).split("/");
289
+ return {
290
+ item_category: a[0].toLowerCase().includes(C.configs.categoryOff) ? "Bazar" : "Coleção",
291
+ ...a[1] && { item_category2: a[1] },
292
+ ...a.length > 2 && {
293
+ item_category3: a[a.length - 1]
294
+ },
295
+ item_category_id: s[s.length - 1],
296
+ ...s.length > 1 && {
297
+ item_parent_category_id: s[s.length - 2]
298
+ }
299
+ };
300
+ }, Gr = (e) => {
301
+ var o, i, u, a, s, l;
302
+ const t = ((o = e.itemOffered) == null ? void 0 : o.skuName) ?? ((a = (u = (i = e.isVariantOf) == null ? void 0 : i.hasVariant) == null ? void 0 : u[0]) == null ? void 0 : a.name) ?? ((l = (s = e.items) == null ? void 0 : s[0]) == null ? void 0 : l.name), { color: n, size: r } = hr(t, C.configs.NAME_SPLIT_SYMBOL);
303
+ return {
304
+ item_variant: n,
305
+ ...e.itemOffered && { item_variant2: r }
306
+ };
307
+ }, Xr = (e) => {
308
+ var s, l;
309
+ const { price: t, listPrice: n, installments: r } = e, o = t ?? ((s = e.offers) == null ? void 0 : s.lowPrice) ?? 0, i = n ?? ((l = e.offers) == null ? void 0 : l.highPrice) ?? 0, u = i ? i - o : 0, a = u % 1 === 0 ? u : Number(u.toFixed(2));
310
+ return {
311
+ ...t && { price: o ?? i },
312
+ ...i && {
313
+ list_price: i,
314
+ discount: a
315
+ },
316
+ ...r && {
317
+ installments: r == null ? void 0 : r.count,
318
+ installment_value: r == null ? void 0 : r.value
319
+ },
320
+ item_currency: C.configs.currency
321
+ };
322
+ }, Yr = () => {
323
+ const [e, t] = _r(), [n, r] = e.split("-"), o = n.includes("shop") || n.includes("sale") ? n : "";
324
+ return {
325
+ page_category: o && r ? r : "",
326
+ page_departament: o,
327
+ id: t,
328
+ name: e
329
+ };
330
+ }, xo = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
331
+ __proto__: null,
332
+ eventsFunctions: C,
333
+ findDataInPersistedData: br,
334
+ getAvailablesSizes: yr,
335
+ getCategories: Vr,
336
+ getPageCategoryAndDepartmentFromSlug: Yr,
337
+ getPersistedData: vr,
338
+ getProductListInfoFromHead: _r,
339
+ pushDatalayer: K,
340
+ updatePersistedData: ot
341
+ }, Symbol.toStringTag, { value: "Module" })), Pr = mr({}), jo = ({ children: e, evtFunctionsConfigs: t }) => {
342
+ const n = X({}), r = X(null), o = X(null), i = X({}), u = X({
343
+ trigger: !1,
344
+ index: 0
345
+ }), a = ({
346
+ functionKey: d,
347
+ data: f,
348
+ callBack: c,
349
+ timeout: g = 100
350
+ }) => {
351
+ window.dataLayer || (window.dataLayer = []), C.configs = t;
352
+ try {
353
+ typeof C[d] == "function" && setTimeout(() => {
354
+ var y;
355
+ f.promotionInfo = n.current, (y = o.current) != null && y.item_list_name && (f.itemList = o.current), C[d](f, c);
356
+ }, g);
357
+ } catch (y) {
358
+ K({
359
+ event: "error_event",
360
+ data: {
361
+ error_message: (y == null ? void 0 : y.message) ?? y
362
+ }
363
+ });
364
+ }
365
+ }, s = ({ content: d }) => {
366
+ a({
367
+ functionKey: "readyEvents",
368
+ data: {
369
+ event: "select_content",
370
+ readyData: {
371
+ content_type: d.replace("::", ":")
372
+ }
373
+ }
374
+ });
375
+ }, l = ({
376
+ updatePromotionRef: d,
377
+ promotion: f,
378
+ index: c
379
+ }) => {
380
+ d && (n.current = {
381
+ ...f
382
+ }), a({
383
+ functionKey: "readyEvents",
384
+ data: {
385
+ event: "select_promotion",
386
+ readyData: {
387
+ ecommerce: {
388
+ ...f,
389
+ ...c !== void 0 && { index: c }
390
+ }
391
+ }
392
+ }
393
+ });
394
+ };
395
+ return /* @__PURE__ */ w(
396
+ Pr.Provider,
397
+ {
398
+ value: {
399
+ sendDataLayerEvent: a,
400
+ triggerSelectItemEventRef: u,
401
+ promotionEventRef: n,
402
+ currentLocalRef: r,
403
+ itemListRef: o,
404
+ cartProductsFullDataRef: i,
405
+ handleSelectContent: s,
406
+ handleSelectPromotionEvent: l
407
+ },
408
+ children: e
409
+ }
410
+ );
411
+ }, Rr = () => gr(Pr), Er = mr({}), Lo = ({ children: e, ...t }) => /* @__PURE__ */ w(
412
+ Er.Provider,
413
+ {
414
+ value: {
415
+ ...t
416
+ },
417
+ children: e
418
+ }
419
+ ), wr = () => gr(Er), Qr = (e, t) => t.getTime() > e.getTime() ? Math.abs(t.getTime() - e.getTime()) : 0, ce = (e, t) => Math.floor(t === "days" ? e / (1e3 * 60 * 60 * 24) : t === "hours" ? e % (1e3 * 60 * 60 * 24) / (1e3 * 60 * 60) : t === "minutes" ? e % (1e3 * 60 * 60) / (1e3 * 60) : e % (1e3 * 60) / 1e3), Jr = (e) => e, Zr = (e) => e, en = (e) => e, tn = (e) => e, D = {
420
+ base: tn,
421
+ configurationSchemaSet: en,
422
+ configuration: Zr,
423
+ schema: Jr
424
+ }, rn = (e) => e, nn = (e) => ({
425
+ ...e.uiWidget ? { "ui:widget": e.uiWidget } : {},
426
+ ...e.uiObjectFieldTemplate ? { "ui:ObjectFieldTemplate": e.uiObjectFieldTemplate } : {}
427
+ }), b = {
428
+ property: rn,
429
+ widget: nn
430
+ }, on = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
431
+ __proto__: null,
432
+ Common: b,
433
+ ContentType: D
434
+ }, Symbol.toStringTag, { value: "Module" }));
435
+ function an(e) {
436
+ const t = {
437
+ value: b.property({
438
+ type: "string",
439
+ title: "Label da flag a ser mostrado"
440
+ }),
441
+ textColor: b.property({
442
+ type: "string",
443
+ title: "Cor do texto"
444
+ }),
445
+ tagColor: b.property({
446
+ type: "string",
447
+ title: "Cor de fundo da tag"
448
+ }),
449
+ enableIcon: b.property({
450
+ type: "boolean",
451
+ title: "Ativar ícone"
452
+ }),
453
+ icon: b.property({
454
+ type: "string",
455
+ title: "Ícone",
456
+ enum: Object.values(e),
457
+ enumNames: Object.keys(e)
458
+ }),
459
+ iconColor: b.property({
460
+ type: "string",
461
+ title: "Cor do Ícone"
462
+ })
463
+ };
464
+ return D.base({
465
+ id: "flags_and_tags",
466
+ name: "Flags And Tags",
467
+ scopes: ["flags_and_tags"],
468
+ configurationSchemaSets: [
469
+ D.configurationSchemaSet({
470
+ name: "config",
471
+ configurations: [
472
+ {
473
+ name: "commercial",
474
+ schema: D.schema({
475
+ title: "Items - Commercial",
476
+ description: "Flags e Tags comerciais em Produtos",
477
+ type: "object",
478
+ properties: {
479
+ items: {
480
+ title: "Flags e Tags",
481
+ type: "array",
482
+ items: b.property({
483
+ title: "Flags e Tags",
484
+ type: "object",
485
+ properties: {
486
+ key: b.property({
487
+ type: "string",
488
+ title: "chave (id do cluster)"
489
+ }),
490
+ ...t
491
+ }
492
+ })
493
+ }
494
+ }
495
+ })
496
+ },
497
+ {
498
+ name: "institucional",
499
+ schema: D.schema({
500
+ title: "Items - Institucional",
501
+ description: "Flags e Tags comerciais em Produtos",
502
+ type: "object",
503
+ properties: {
504
+ items: {
505
+ title: "Flags e Tags",
506
+ type: "array",
507
+ items: b.property({
508
+ title: "Flags e Tags",
509
+ type: "object",
510
+ properties: {
511
+ key: b.property({
512
+ type: "string",
513
+ title: "chave (id do cluster)"
514
+ }),
515
+ ...t
516
+ }
517
+ })
518
+ }
519
+ }
520
+ })
521
+ },
522
+ {
523
+ name: "flag_cart",
524
+ schema: D.schema({
525
+ title: "Flags Sacola",
526
+ description: "Flags da Sacola",
527
+ type: "object",
528
+ properties: {
529
+ flagHeader: b.property({
530
+ type: "object",
531
+ title: "Flag exibida abaixo do Header da Sacola",
532
+ properties: t
533
+ }),
534
+ flagTotal: {
535
+ title: "Flag exibida ao lado do Total da Sacola",
536
+ type: "string"
537
+ }
538
+ }
539
+ })
540
+ },
541
+ {
542
+ name: "flag_pdp",
543
+ schema: D.schema({
544
+ title: "Flag PDP",
545
+ description: "Flag Cashback PDP",
546
+ type: "object",
547
+ properties: t
548
+ })
549
+ }
550
+ ]
551
+ })
552
+ ]
553
+ });
554
+ }
555
+ const sn = D.base({
556
+ id: "common_page",
557
+ name: "Common Page",
558
+ scopes: ["common_page"],
559
+ configurationSchemaSets: [
560
+ D.configurationSchemaSet({
561
+ name: "config",
562
+ configurations: [
563
+ {
564
+ name: "seo",
565
+ schema: D.schema({
566
+ title: "SEO",
567
+ description: "Search Engine Optimization options",
568
+ type: "object",
569
+ widget: b.widget({
570
+ uiObjectFieldTemplate: "GoogleSeoPreview"
571
+ }),
572
+ required: ["slug", "title", "description"],
573
+ properties: {
574
+ slug: {
575
+ title: "Path",
576
+ type: "string",
577
+ default: "/"
578
+ },
579
+ title: {
580
+ title: "Default page title",
581
+ description: "Display this title when no other title is available",
582
+ type: "string",
583
+ default: "FastStore Starter"
584
+ },
585
+ description: {
586
+ title: "Meta tag description",
587
+ type: "string",
588
+ default: "A beautifully designed store"
589
+ },
590
+ canonical: {
591
+ title: "Canonical url for the page",
592
+ type: "string"
593
+ }
594
+ }
595
+ })
596
+ },
597
+ {
598
+ name: "responsive",
599
+ schema: D.schema({
600
+ title: "Responsive",
601
+ description: "Configurações de responsivo",
602
+ type: "object",
603
+ widget: b.widget({
604
+ uiObjectFieldTemplate: "GoogleSeoPreview"
605
+ }),
606
+ properties: {
607
+ deviceType: b.property({
608
+ title: "Tipo de dispositivo",
609
+ type: "string",
610
+ enum: ["desktop", "mobile"],
611
+ enumNames: ["desktop", "mobile"]
612
+ }),
613
+ gapCustom: b.property({
614
+ title: "Modificar espaçamento",
615
+ description: "O espaçamento padrão entre as seções é de 64px",
616
+ type: "boolean"
617
+ }),
618
+ gapSections: b.property({
619
+ title: "Espaçamento entre seções",
620
+ description: 'Marque a opção "Modificar espaçamento" para ativar/desativar o espaçamento selecionado',
621
+ type: "string",
622
+ enum: ["8px", "16px", "32px", "128px"],
623
+ enumNames: ["8px", "16px", "32px", "128px"],
624
+ default: "32px"
625
+ })
626
+ }
627
+ })
628
+ }
629
+ ]
630
+ })
631
+ ]
632
+ }), un = {
633
+ generateFlagsAndTags: an,
634
+ commonPage: sn
635
+ };
636
+ function cn(e) {
637
+ return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
638
+ }
639
+ var it = { exports: {} }, ie = {};
640
+ ie._ = ie._interop_require_default = ln;
641
+ function ln(e) {
642
+ return e && e.__esModule ? e : { default: e };
643
+ }
644
+ var le = { exports: {} }, xe = {}, St;
645
+ function Sr() {
646
+ return St || (St = 1, function(e) {
647
+ Object.defineProperty(e, "__esModule", {
648
+ value: !0
649
+ });
650
+ function t(u, a) {
651
+ for (var s in a) Object.defineProperty(u, s, {
652
+ enumerable: !0,
653
+ get: a[s]
654
+ });
655
+ }
656
+ t(e, {
657
+ searchParamsToUrlQuery: function() {
658
+ return n;
659
+ },
660
+ urlQueryToSearchParams: function() {
661
+ return o;
662
+ },
663
+ assign: function() {
664
+ return i;
665
+ }
666
+ });
667
+ function n(u) {
668
+ const a = {};
669
+ return u.forEach((s, l) => {
670
+ typeof a[l] > "u" ? a[l] = s : Array.isArray(a[l]) ? a[l].push(s) : a[l] = [
671
+ a[l],
672
+ s
673
+ ];
674
+ }), a;
675
+ }
676
+ function r(u) {
677
+ return typeof u == "string" || typeof u == "number" && !isNaN(u) || typeof u == "boolean" ? String(u) : "";
678
+ }
679
+ function o(u) {
680
+ const a = new URLSearchParams();
681
+ return Object.entries(u).forEach((s) => {
682
+ let [l, d] = s;
683
+ Array.isArray(d) ? d.forEach((f) => a.append(l, r(f))) : a.set(l, r(d));
684
+ }), a;
685
+ }
686
+ function i(u) {
687
+ for (var a = arguments.length, s = new Array(a > 1 ? a - 1 : 0), l = 1; l < a; l++)
688
+ s[l - 1] = arguments[l];
689
+ return s.forEach((d) => {
690
+ Array.from(d.keys()).forEach((f) => u.delete(f)), d.forEach((f, c) => u.append(c, f));
691
+ }), u;
692
+ }
693
+ }(xe)), xe;
694
+ }
695
+ var je = {}, at = {};
696
+ function Or(e) {
697
+ if (typeof WeakMap != "function") return null;
698
+ var t = /* @__PURE__ */ new WeakMap(), n = /* @__PURE__ */ new WeakMap();
699
+ return (Or = function(r) {
700
+ return r ? n : t;
701
+ })(e);
702
+ }
703
+ at._ = at._interop_require_wildcard = fn;
704
+ function fn(e, t) {
705
+ if (!t && e && e.__esModule) return e;
706
+ if (e === null || typeof e != "object" && typeof e != "function") return { default: e };
707
+ var n = Or(t);
708
+ if (n && n.has(e)) return n.get(e);
709
+ var r = {}, o = Object.defineProperty && Object.getOwnPropertyDescriptor;
710
+ for (var i in e)
711
+ if (i !== "default" && Object.prototype.hasOwnProperty.call(e, i)) {
712
+ var u = o ? Object.getOwnPropertyDescriptor(e, i) : null;
713
+ u && (u.get || u.set) ? Object.defineProperty(r, i, u) : r[i] = e[i];
714
+ }
715
+ return r.default = e, n && n.set(e, r), r;
716
+ }
717
+ var Ot;
718
+ function Tr() {
719
+ return Ot || (Ot = 1, function(e) {
720
+ Object.defineProperty(e, "__esModule", {
721
+ value: !0
722
+ });
723
+ function t(s, l) {
724
+ for (var d in l) Object.defineProperty(s, d, {
725
+ enumerable: !0,
726
+ get: l[d]
727
+ });
728
+ }
729
+ t(e, {
730
+ formatUrl: function() {
731
+ return i;
732
+ },
733
+ urlObjectKeys: function() {
734
+ return u;
735
+ },
736
+ formatWithValidation: function() {
737
+ return a;
738
+ }
739
+ });
740
+ const r = /* @__PURE__ */ at._(Sr()), o = /https?|ftp|gopher|file/;
741
+ function i(s) {
742
+ let { auth: l, hostname: d } = s, f = s.protocol || "", c = s.pathname || "", g = s.hash || "", y = s.query || "", p = !1;
743
+ l = l ? encodeURIComponent(l).replace(/%3A/i, ":") + "@" : "", s.host ? p = l + s.host : d && (p = l + (~d.indexOf(":") ? "[" + d + "]" : d), s.port && (p += ":" + s.port)), y && typeof y == "object" && (y = String(r.urlQueryToSearchParams(y)));
744
+ let h = s.search || y && "?" + y || "";
745
+ return f && !f.endsWith(":") && (f += ":"), s.slashes || (!f || o.test(f)) && p !== !1 ? (p = "//" + (p || ""), c && c[0] !== "/" && (c = "/" + c)) : p || (p = ""), g && g[0] !== "#" && (g = "#" + g), h && h[0] !== "?" && (h = "?" + h), c = c.replace(/[?#]/g, encodeURIComponent), h = h.replace("#", "%23"), "" + f + p + c + h + g;
746
+ }
747
+ const u = [
748
+ "auth",
749
+ "hash",
750
+ "host",
751
+ "hostname",
752
+ "href",
753
+ "path",
754
+ "pathname",
755
+ "port",
756
+ "protocol",
757
+ "query",
758
+ "search",
759
+ "slashes"
760
+ ];
761
+ function a(s) {
762
+ return process.env.NODE_ENV === "development" && s !== null && typeof s == "object" && Object.keys(s).forEach((l) => {
763
+ u.includes(l) || console.warn("Unknown key passed via urlObject into url.format: " + l);
764
+ }), i(s);
765
+ }
766
+ }(je)), je;
767
+ }
768
+ var Le = {}, Tt;
769
+ function dn() {
770
+ return Tt || (Tt = 1, function(e) {
771
+ Object.defineProperty(e, "__esModule", {
772
+ value: !0
773
+ }), Object.defineProperty(e, "omit", {
774
+ enumerable: !0,
775
+ get: function() {
776
+ return t;
777
+ }
778
+ });
779
+ function t(n, r) {
780
+ const o = {};
781
+ return Object.keys(n).forEach((i) => {
782
+ r.includes(i) || (o[i] = n[i]);
783
+ }), o;
784
+ }
785
+ }(Le)), Le;
786
+ }
787
+ var Ae = {}, It;
788
+ function Se() {
789
+ return It || (It = 1, function(e) {
790
+ Object.defineProperty(e, "__esModule", {
791
+ value: !0
792
+ });
793
+ function t(m, E) {
794
+ for (var v in E) Object.defineProperty(m, v, {
795
+ enumerable: !0,
796
+ get: E[v]
797
+ });
798
+ }
799
+ t(e, {
800
+ WEB_VITALS: function() {
801
+ return n;
802
+ },
803
+ execOnce: function() {
804
+ return r;
805
+ },
806
+ isAbsoluteUrl: function() {
807
+ return i;
808
+ },
809
+ getLocationOrigin: function() {
810
+ return u;
811
+ },
812
+ getURL: function() {
813
+ return a;
814
+ },
815
+ getDisplayName: function() {
816
+ return s;
817
+ },
818
+ isResSent: function() {
819
+ return l;
820
+ },
821
+ normalizeRepeatedSlashes: function() {
822
+ return d;
823
+ },
824
+ loadGetInitialProps: function() {
825
+ return f;
826
+ },
827
+ SP: function() {
828
+ return c;
829
+ },
830
+ ST: function() {
831
+ return g;
832
+ },
833
+ DecodeError: function() {
834
+ return y;
835
+ },
836
+ NormalizeError: function() {
837
+ return p;
838
+ },
839
+ PageNotFoundError: function() {
840
+ return h;
841
+ },
842
+ MissingStaticPage: function() {
843
+ return _;
844
+ },
845
+ MiddlewareNotFoundError: function() {
846
+ return O;
847
+ },
848
+ stringifyError: function() {
849
+ return R;
850
+ }
851
+ });
852
+ const n = [
853
+ "CLS",
854
+ "FCP",
855
+ "FID",
856
+ "INP",
857
+ "LCP",
858
+ "TTFB"
859
+ ];
860
+ function r(m) {
861
+ let E = !1, v;
862
+ return function() {
863
+ for (var P = arguments.length, S = new Array(P), N = 0; N < P; N++)
864
+ S[N] = arguments[N];
865
+ return E || (E = !0, v = m(...S)), v;
866
+ };
867
+ }
868
+ const o = /^[a-zA-Z][a-zA-Z\d+\-.]*?:/, i = (m) => o.test(m);
869
+ function u() {
870
+ const { protocol: m, hostname: E, port: v } = window.location;
871
+ return m + "//" + E + (v ? ":" + v : "");
872
+ }
873
+ function a() {
874
+ const { href: m } = window.location, E = u();
875
+ return m.substring(E.length);
876
+ }
877
+ function s(m) {
878
+ return typeof m == "string" ? m : m.displayName || m.name || "Unknown";
879
+ }
880
+ function l(m) {
881
+ return m.finished || m.headersSent;
882
+ }
883
+ function d(m) {
884
+ const E = m.split("?");
885
+ return E[0].replace(/\\/g, "/").replace(/\/\/+/g, "/") + (E[1] ? "?" + E.slice(1).join("?") : "");
886
+ }
887
+ async function f(m, E) {
888
+ if (process.env.NODE_ENV !== "production") {
889
+ var v;
890
+ if ((v = m.prototype) != null && v.getInitialProps) {
891
+ const N = '"' + s(m) + '.getInitialProps()" is defined as an instance method - visit https://nextjs.org/docs/messages/get-initial-props-as-an-instance-method for more information.';
892
+ throw new Error(N);
893
+ }
894
+ }
895
+ const P = E.res || E.ctx && E.ctx.res;
896
+ if (!m.getInitialProps)
897
+ return E.ctx && E.Component ? {
898
+ pageProps: await f(E.Component, E.ctx)
899
+ } : {};
900
+ const S = await m.getInitialProps(E);
901
+ if (P && l(P))
902
+ return S;
903
+ if (!S) {
904
+ const N = '"' + s(m) + '.getInitialProps()" should resolve to an object. But found "' + S + '" instead.';
905
+ throw new Error(N);
906
+ }
907
+ return process.env.NODE_ENV !== "production" && Object.keys(S).length === 0 && !E.ctx && console.warn("" + s(m) + " returned an empty object from `getInitialProps`. This de-optimizes and prevents automatic static optimization. https://nextjs.org/docs/messages/empty-object-getInitialProps"), S;
908
+ }
909
+ const c = typeof performance < "u", g = c && [
910
+ "mark",
911
+ "measure",
912
+ "getEntriesByName"
913
+ ].every((m) => typeof performance[m] == "function");
914
+ class y extends Error {
915
+ }
916
+ class p extends Error {
917
+ }
918
+ class h extends Error {
919
+ constructor(E) {
920
+ super(), this.code = "ENOENT", this.name = "PageNotFoundError", this.message = "Cannot find module for page: " + E;
921
+ }
922
+ }
923
+ class _ extends Error {
924
+ constructor(E, v) {
925
+ super(), this.message = "Failed to load static file for page: " + E + " " + v;
926
+ }
927
+ }
928
+ class O extends Error {
929
+ constructor() {
930
+ super(), this.code = "ENOENT", this.message = "Cannot find the middleware module";
931
+ }
932
+ }
933
+ function R(m) {
934
+ return JSON.stringify({
935
+ message: m.message,
936
+ stack: m.stack
937
+ });
938
+ }
939
+ }(Ae)), Ae;
940
+ }
941
+ var fe = { exports: {} }, Me = {}, Nt;
942
+ function Ir() {
943
+ return Nt || (Nt = 1, function(e) {
944
+ Object.defineProperty(e, "__esModule", {
945
+ value: !0
946
+ }), Object.defineProperty(e, "removeTrailingSlash", {
947
+ enumerable: !0,
948
+ get: function() {
949
+ return t;
950
+ }
951
+ });
952
+ function t(n) {
953
+ return n.replace(/\/$/, "") || "/";
954
+ }
955
+ }(Me)), Me;
956
+ }
957
+ var qe = {}, Ct;
958
+ function lt() {
959
+ return Ct || (Ct = 1, function(e) {
960
+ Object.defineProperty(e, "__esModule", {
961
+ value: !0
962
+ }), Object.defineProperty(e, "parsePath", {
963
+ enumerable: !0,
964
+ get: function() {
965
+ return t;
966
+ }
967
+ });
968
+ function t(n) {
969
+ const r = n.indexOf("#"), o = n.indexOf("?"), i = o > -1 && (r < 0 || o < r);
970
+ return i || r > -1 ? {
971
+ pathname: n.substring(0, i ? o : r),
972
+ query: i ? n.substring(o, r > -1 ? r : void 0) : "",
973
+ hash: r > -1 ? n.slice(r) : ""
974
+ } : {
975
+ pathname: n,
976
+ query: "",
977
+ hash: ""
978
+ };
979
+ }
980
+ }(qe)), qe;
981
+ }
982
+ var xt;
983
+ function Oe() {
984
+ return xt || (xt = 1, function(e, t) {
985
+ Object.defineProperty(t, "__esModule", {
986
+ value: !0
987
+ }), Object.defineProperty(t, "normalizePathTrailingSlash", {
988
+ enumerable: !0,
989
+ get: function() {
990
+ return o;
991
+ }
992
+ });
993
+ const n = Ir(), r = lt(), o = (i) => {
994
+ if (!i.startsWith("/") || process.env.__NEXT_MANUAL_TRAILING_SLASH)
995
+ return i;
996
+ const { pathname: u, query: a, hash: s } = (0, r.parsePath)(i);
997
+ return process.env.__NEXT_TRAILING_SLASH ? /\.[^/]+\/?$/.test(u) ? "" + (0, n.removeTrailingSlash)(u) + a + s : u.endsWith("/") ? "" + u + a + s : u + "/" + a + s : "" + (0, n.removeTrailingSlash)(u) + a + s;
998
+ };
999
+ (typeof t.default == "function" || typeof t.default == "object" && t.default !== null) && typeof t.default.__esModule > "u" && (Object.defineProperty(t.default, "__esModule", { value: !0 }), Object.assign(t.default, t), e.exports = t.default);
1000
+ }(fe, fe.exports)), fe.exports;
1001
+ }
1002
+ var De = {}, de = { exports: {} }, ke = {}, jt;
1003
+ function Nr() {
1004
+ return jt || (jt = 1, function(e) {
1005
+ Object.defineProperty(e, "__esModule", {
1006
+ value: !0
1007
+ }), Object.defineProperty(e, "pathHasPrefix", {
1008
+ enumerable: !0,
1009
+ get: function() {
1010
+ return n;
1011
+ }
1012
+ });
1013
+ const t = lt();
1014
+ function n(r, o) {
1015
+ if (typeof r != "string")
1016
+ return !1;
1017
+ const { pathname: i } = (0, t.parsePath)(r);
1018
+ return i === o || i.startsWith(o + "/");
1019
+ }
1020
+ }(ke)), ke;
1021
+ }
1022
+ var Lt;
1023
+ function pn() {
1024
+ return Lt || (Lt = 1, function(e, t) {
1025
+ Object.defineProperty(t, "__esModule", {
1026
+ value: !0
1027
+ }), Object.defineProperty(t, "hasBasePath", {
1028
+ enumerable: !0,
1029
+ get: function() {
1030
+ return o;
1031
+ }
1032
+ });
1033
+ const n = Nr(), r = process.env.__NEXT_ROUTER_BASEPATH || "";
1034
+ function o(i) {
1035
+ return (0, n.pathHasPrefix)(i, r);
1036
+ }
1037
+ (typeof t.default == "function" || typeof t.default == "object" && t.default !== null) && typeof t.default.__esModule > "u" && (Object.defineProperty(t.default, "__esModule", { value: !0 }), Object.assign(t.default, t), e.exports = t.default);
1038
+ }(de, de.exports)), de.exports;
1039
+ }
1040
+ var At;
1041
+ function Cr() {
1042
+ return At || (At = 1, function(e) {
1043
+ Object.defineProperty(e, "__esModule", {
1044
+ value: !0
1045
+ }), Object.defineProperty(e, "isLocalURL", {
1046
+ enumerable: !0,
1047
+ get: function() {
1048
+ return r;
1049
+ }
1050
+ });
1051
+ const t = Se(), n = pn();
1052
+ function r(o) {
1053
+ if (!(0, t.isAbsoluteUrl)(o)) return !0;
1054
+ try {
1055
+ const i = (0, t.getLocationOrigin)(), u = new URL(o, i);
1056
+ return u.origin === i && (0, n.hasBasePath)(u.pathname);
1057
+ } catch {
1058
+ return !1;
1059
+ }
1060
+ }
1061
+ }(De)), De;
1062
+ }
1063
+ var ze = {}, Ue = {}, Mt;
1064
+ function mn() {
1065
+ return Mt || (Mt = 1, function(e) {
1066
+ Object.defineProperty(e, "__esModule", {
1067
+ value: !0
1068
+ }), Object.defineProperty(e, "getSortedRoutes", {
1069
+ enumerable: !0,
1070
+ get: function() {
1071
+ return n;
1072
+ }
1073
+ });
1074
+ class t {
1075
+ insert(o) {
1076
+ this._insert(o.split("/").filter(Boolean), [], !1);
1077
+ }
1078
+ smoosh() {
1079
+ return this._smoosh();
1080
+ }
1081
+ _smoosh(o) {
1082
+ o === void 0 && (o = "/");
1083
+ const i = [
1084
+ ...this.children.keys()
1085
+ ].sort();
1086
+ this.slugName !== null && i.splice(i.indexOf("[]"), 1), this.restSlugName !== null && i.splice(i.indexOf("[...]"), 1), this.optionalRestSlugName !== null && i.splice(i.indexOf("[[...]]"), 1);
1087
+ const u = i.map((a) => this.children.get(a)._smoosh("" + o + a + "/")).reduce((a, s) => [
1088
+ ...a,
1089
+ ...s
1090
+ ], []);
1091
+ if (this.slugName !== null && u.push(...this.children.get("[]")._smoosh(o + "[" + this.slugName + "]/")), !this.placeholder) {
1092
+ const a = o === "/" ? "/" : o.slice(0, -1);
1093
+ if (this.optionalRestSlugName != null)
1094
+ throw new Error('You cannot define a route with the same specificity as a optional catch-all route ("' + a + '" and "' + a + "[[..." + this.optionalRestSlugName + ']]").');
1095
+ u.unshift(a);
1096
+ }
1097
+ return this.restSlugName !== null && u.push(...this.children.get("[...]")._smoosh(o + "[..." + this.restSlugName + "]/")), this.optionalRestSlugName !== null && u.push(...this.children.get("[[...]]")._smoosh(o + "[[..." + this.optionalRestSlugName + "]]/")), u;
1098
+ }
1099
+ _insert(o, i, u) {
1100
+ if (o.length === 0) {
1101
+ this.placeholder = !1;
1102
+ return;
1103
+ }
1104
+ if (u)
1105
+ throw new Error("Catch-all must be the last part of the URL.");
1106
+ let a = o[0];
1107
+ if (a.startsWith("[") && a.endsWith("]")) {
1108
+ let d = function(f, c) {
1109
+ if (f !== null && f !== c)
1110
+ throw new Error("You cannot use different slug names for the same dynamic path ('" + f + "' !== '" + c + "').");
1111
+ i.forEach((g) => {
1112
+ if (g === c)
1113
+ throw new Error('You cannot have the same slug name "' + c + '" repeat within a single dynamic path');
1114
+ if (g.replace(/\W/g, "") === a.replace(/\W/g, ""))
1115
+ throw new Error('You cannot have the slug names "' + g + '" and "' + c + '" differ only by non-word symbols within a single dynamic path');
1116
+ }), i.push(c);
1117
+ }, s = a.slice(1, -1), l = !1;
1118
+ if (s.startsWith("[") && s.endsWith("]") && (s = s.slice(1, -1), l = !0), s.startsWith("...") && (s = s.substring(3), u = !0), s.startsWith("[") || s.endsWith("]"))
1119
+ throw new Error("Segment names may not start or end with extra brackets ('" + s + "').");
1120
+ if (s.startsWith("."))
1121
+ throw new Error("Segment names may not start with erroneous periods ('" + s + "').");
1122
+ if (u)
1123
+ if (l) {
1124
+ if (this.restSlugName != null)
1125
+ throw new Error('You cannot use both an required and optional catch-all route at the same level ("[...' + this.restSlugName + ']" and "' + o[0] + '" ).');
1126
+ d(this.optionalRestSlugName, s), this.optionalRestSlugName = s, a = "[[...]]";
1127
+ } else {
1128
+ if (this.optionalRestSlugName != null)
1129
+ throw new Error('You cannot use both an optional and required catch-all route at the same level ("[[...' + this.optionalRestSlugName + ']]" and "' + o[0] + '").');
1130
+ d(this.restSlugName, s), this.restSlugName = s, a = "[...]";
1131
+ }
1132
+ else {
1133
+ if (l)
1134
+ throw new Error('Optional route parameters are not yet supported ("' + o[0] + '").');
1135
+ d(this.slugName, s), this.slugName = s, a = "[]";
1136
+ }
1137
+ }
1138
+ this.children.has(a) || this.children.set(a, new t()), this.children.get(a)._insert(o.slice(1), i, u);
1139
+ }
1140
+ constructor() {
1141
+ this.placeholder = !0, this.children = /* @__PURE__ */ new Map(), this.slugName = null, this.restSlugName = null, this.optionalRestSlugName = null;
1142
+ }
1143
+ }
1144
+ function n(r) {
1145
+ const o = new t();
1146
+ return r.forEach((i) => o.insert(i)), o.smoosh();
1147
+ }
1148
+ }(Ue)), Ue;
1149
+ }
1150
+ var Fe = {}, qt;
1151
+ function gn() {
1152
+ return qt || (qt = 1, function(e) {
1153
+ Object.defineProperty(e, "__esModule", {
1154
+ value: !0
1155
+ }), Object.defineProperty(e, "isDynamicRoute", {
1156
+ enumerable: !0,
1157
+ get: function() {
1158
+ return n;
1159
+ }
1160
+ });
1161
+ const t = /\/\[[^/]+?\](?=\/|$)/;
1162
+ function n(r) {
1163
+ return t.test(r);
1164
+ }
1165
+ }(Fe)), Fe;
1166
+ }
1167
+ var Dt;
1168
+ function hn() {
1169
+ return Dt || (Dt = 1, function(e) {
1170
+ Object.defineProperty(e, "__esModule", {
1171
+ value: !0
1172
+ });
1173
+ function t(o, i) {
1174
+ for (var u in i) Object.defineProperty(o, u, {
1175
+ enumerable: !0,
1176
+ get: i[u]
1177
+ });
1178
+ }
1179
+ t(e, {
1180
+ getSortedRoutes: function() {
1181
+ return n.getSortedRoutes;
1182
+ },
1183
+ isDynamicRoute: function() {
1184
+ return r.isDynamicRoute;
1185
+ }
1186
+ });
1187
+ const n = mn(), r = gn();
1188
+ }(ze)), ze;
1189
+ }
1190
+ var Be = {}, $e = {}, kt;
1191
+ function yn() {
1192
+ return kt || (kt = 1, function(e) {
1193
+ Object.defineProperty(e, "__esModule", {
1194
+ value: !0
1195
+ }), Object.defineProperty(e, "getRouteMatcher", {
1196
+ enumerable: !0,
1197
+ get: function() {
1198
+ return n;
1199
+ }
1200
+ });
1201
+ const t = Se();
1202
+ function n(r) {
1203
+ let { re: o, groups: i } = r;
1204
+ return (u) => {
1205
+ const a = o.exec(u);
1206
+ if (!a)
1207
+ return !1;
1208
+ const s = (d) => {
1209
+ try {
1210
+ return decodeURIComponent(d);
1211
+ } catch {
1212
+ throw new t.DecodeError("failed to decode param");
1213
+ }
1214
+ }, l = {};
1215
+ return Object.keys(i).forEach((d) => {
1216
+ const f = i[d], c = a[f.pos];
1217
+ c !== void 0 && (l[d] = ~c.indexOf("/") ? c.split("/").map((g) => s(g)) : f.repeat ? [
1218
+ s(c)
1219
+ ] : s(c));
1220
+ }), l;
1221
+ };
1222
+ }
1223
+ }($e)), $e;
1224
+ }
1225
+ var We = {}, Ve = {}, He = {}, Ke = {}, zt;
1226
+ function _n() {
1227
+ return zt || (zt = 1, function(e) {
1228
+ Object.defineProperty(e, "__esModule", {
1229
+ value: !0
1230
+ }), Object.defineProperty(e, "ensureLeadingSlash", {
1231
+ enumerable: !0,
1232
+ get: function() {
1233
+ return t;
1234
+ }
1235
+ });
1236
+ function t(n) {
1237
+ return n.startsWith("/") ? n : "/" + n;
1238
+ }
1239
+ }(Ke)), Ke;
1240
+ }
1241
+ var Ge = {}, Ut;
1242
+ function vn() {
1243
+ return Ut || (Ut = 1, function(e) {
1244
+ Object.defineProperty(e, "__esModule", {
1245
+ value: !0
1246
+ }), Object.defineProperty(e, "isGroupSegment", {
1247
+ enumerable: !0,
1248
+ get: function() {
1249
+ return t;
1250
+ }
1251
+ });
1252
+ function t(n) {
1253
+ return n[0] === "(" && n.endsWith(")");
1254
+ }
1255
+ }(Ge)), Ge;
1256
+ }
1257
+ var Ft;
1258
+ function bn() {
1259
+ return Ft || (Ft = 1, function(e) {
1260
+ Object.defineProperty(e, "__esModule", {
1261
+ value: !0
1262
+ });
1263
+ function t(u, a) {
1264
+ for (var s in a) Object.defineProperty(u, s, {
1265
+ enumerable: !0,
1266
+ get: a[s]
1267
+ });
1268
+ }
1269
+ t(e, {
1270
+ normalizeAppPath: function() {
1271
+ return o;
1272
+ },
1273
+ normalizeRscPath: function() {
1274
+ return i;
1275
+ }
1276
+ });
1277
+ const n = _n(), r = vn();
1278
+ function o(u) {
1279
+ return (0, n.ensureLeadingSlash)(u.split("/").reduce((a, s, l, d) => !s || (0, r.isGroupSegment)(s) || s[0] === "@" || (s === "page" || s === "route") && l === d.length - 1 ? a : a + "/" + s, ""));
1280
+ }
1281
+ function i(u, a) {
1282
+ return a ? u.replace(
1283
+ /\.rsc($|\?)/,
1284
+ // $1 ensures `?` is preserved
1285
+ "$1"
1286
+ ) : u;
1287
+ }
1288
+ }(He)), He;
1289
+ }
1290
+ var Bt;
1291
+ function Pn() {
1292
+ return Bt || (Bt = 1, function(e) {
1293
+ Object.defineProperty(e, "__esModule", {
1294
+ value: !0
1295
+ });
1296
+ function t(u, a) {
1297
+ for (var s in a) Object.defineProperty(u, s, {
1298
+ enumerable: !0,
1299
+ get: a[s]
1300
+ });
1301
+ }
1302
+ t(e, {
1303
+ INTERCEPTION_ROUTE_MARKERS: function() {
1304
+ return r;
1305
+ },
1306
+ isInterceptionRouteAppPath: function() {
1307
+ return o;
1308
+ },
1309
+ extractInterceptionRouteInformation: function() {
1310
+ return i;
1311
+ }
1312
+ });
1313
+ const n = bn(), r = [
1314
+ "(..)(..)",
1315
+ "(.)",
1316
+ "(..)",
1317
+ "(...)"
1318
+ ];
1319
+ function o(u) {
1320
+ return u.split("/").find((a) => r.find((s) => a.startsWith(s))) !== void 0;
1321
+ }
1322
+ function i(u) {
1323
+ let a, s, l;
1324
+ for (const d of u.split("/"))
1325
+ if (s = r.find((f) => d.startsWith(f)), s) {
1326
+ [a, l] = u.split(s, 2);
1327
+ break;
1328
+ }
1329
+ if (!a || !s || !l)
1330
+ throw new Error(`Invalid interception route: ${u}. Must be in the format /<intercepting route>/(..|...|..)(..)/<intercepted route>`);
1331
+ switch (a = (0, n.normalizeAppPath)(a), s) {
1332
+ case "(.)":
1333
+ a === "/" ? l = `/${l}` : l = a + "/" + l;
1334
+ break;
1335
+ case "(..)":
1336
+ if (a === "/")
1337
+ throw new Error(`Invalid interception route: ${u}. Cannot use (..) marker at the root level, use (.) instead.`);
1338
+ l = a.split("/").slice(0, -1).concat(l).join("/");
1339
+ break;
1340
+ case "(...)":
1341
+ l = "/" + l;
1342
+ break;
1343
+ case "(..)(..)":
1344
+ const d = a.split("/");
1345
+ if (d.length <= 2)
1346
+ throw new Error(`Invalid interception route: ${u}. Cannot use (..)(..) marker at the root level or one level up.`);
1347
+ l = d.slice(0, -2).concat(l).join("/");
1348
+ break;
1349
+ default:
1350
+ throw new Error("Invariant: unexpected marker");
1351
+ }
1352
+ return {
1353
+ interceptingRoute: a,
1354
+ interceptedRoute: l
1355
+ };
1356
+ }
1357
+ }(Ve)), Ve;
1358
+ }
1359
+ var Xe = {}, $t;
1360
+ function Rn() {
1361
+ return $t || ($t = 1, function(e) {
1362
+ Object.defineProperty(e, "__esModule", {
1363
+ value: !0
1364
+ }), Object.defineProperty(e, "escapeStringRegexp", {
1365
+ enumerable: !0,
1366
+ get: function() {
1367
+ return r;
1368
+ }
1369
+ });
1370
+ const t = /[|\\{}()[\]^$+*?.-]/, n = /[|\\{}()[\]^$+*?.-]/g;
1371
+ function r(o) {
1372
+ return t.test(o) ? o.replace(n, "\\$&") : o;
1373
+ }
1374
+ }(Xe)), Xe;
1375
+ }
1376
+ var Wt;
1377
+ function En() {
1378
+ return Wt || (Wt = 1, function(e) {
1379
+ Object.defineProperty(e, "__esModule", {
1380
+ value: !0
1381
+ });
1382
+ function t(p, h) {
1383
+ for (var _ in h) Object.defineProperty(p, _, {
1384
+ enumerable: !0,
1385
+ get: h[_]
1386
+ });
1387
+ }
1388
+ t(e, {
1389
+ getRouteRegex: function() {
1390
+ return l;
1391
+ },
1392
+ getNamedRouteRegex: function() {
1393
+ return g;
1394
+ },
1395
+ getNamedMiddlewareRegex: function() {
1396
+ return y;
1397
+ }
1398
+ });
1399
+ const n = Pn(), r = Rn(), o = Ir(), i = "nxtP", u = "nxtI";
1400
+ function a(p) {
1401
+ const h = p.startsWith("[") && p.endsWith("]");
1402
+ h && (p = p.slice(1, -1));
1403
+ const _ = p.startsWith("...");
1404
+ return _ && (p = p.slice(3)), {
1405
+ key: p,
1406
+ repeat: _,
1407
+ optional: h
1408
+ };
1409
+ }
1410
+ function s(p) {
1411
+ const h = (0, o.removeTrailingSlash)(p).slice(1).split("/"), _ = {};
1412
+ let O = 1;
1413
+ return {
1414
+ parameterizedRoute: h.map((R) => {
1415
+ const m = n.INTERCEPTION_ROUTE_MARKERS.find((v) => R.startsWith(v)), E = R.match(/\[((?:\[.*\])|.+)\]/);
1416
+ if (m && E) {
1417
+ const { key: v, optional: P, repeat: S } = a(E[1]);
1418
+ return _[v] = {
1419
+ pos: O++,
1420
+ repeat: S,
1421
+ optional: P
1422
+ }, "/" + (0, r.escapeStringRegexp)(m) + "([^/]+?)";
1423
+ } else if (E) {
1424
+ const { key: v, repeat: P, optional: S } = a(E[1]);
1425
+ return _[v] = {
1426
+ pos: O++,
1427
+ repeat: P,
1428
+ optional: S
1429
+ }, P ? S ? "(?:/(.+?))?" : "/(.+?)" : "/([^/]+?)";
1430
+ } else
1431
+ return "/" + (0, r.escapeStringRegexp)(R);
1432
+ }).join(""),
1433
+ groups: _
1434
+ };
1435
+ }
1436
+ function l(p) {
1437
+ const { parameterizedRoute: h, groups: _ } = s(p);
1438
+ return {
1439
+ re: new RegExp("^" + h + "(?:/)?$"),
1440
+ groups: _
1441
+ };
1442
+ }
1443
+ function d() {
1444
+ let p = 0;
1445
+ return () => {
1446
+ let h = "", _ = ++p;
1447
+ for (; _ > 0; )
1448
+ h += String.fromCharCode(97 + (_ - 1) % 26), _ = Math.floor((_ - 1) / 26);
1449
+ return h;
1450
+ };
1451
+ }
1452
+ function f(p) {
1453
+ let { getSafeRouteKey: h, segment: _, routeKeys: O, keyPrefix: R } = p;
1454
+ const { key: m, optional: E, repeat: v } = a(_);
1455
+ let P = m.replace(/\W/g, "");
1456
+ R && (P = "" + R + P);
1457
+ let S = !1;
1458
+ return (P.length === 0 || P.length > 30) && (S = !0), isNaN(parseInt(P.slice(0, 1))) || (S = !0), S && (P = h()), R ? O[P] = "" + R + m : O[P] = "" + m, v ? E ? "(?:/(?<" + P + ">.+?))?" : "/(?<" + P + ">.+?)" : "/(?<" + P + ">[^/]+?)";
1459
+ }
1460
+ function c(p, h) {
1461
+ const _ = (0, o.removeTrailingSlash)(p).slice(1).split("/"), O = d(), R = {};
1462
+ return {
1463
+ namedParameterizedRoute: _.map((m) => {
1464
+ const E = n.INTERCEPTION_ROUTE_MARKERS.some((P) => m.startsWith(P)), v = m.match(/\[((?:\[.*\])|.+)\]/);
1465
+ return E && v ? f({
1466
+ getSafeRouteKey: O,
1467
+ segment: v[1],
1468
+ routeKeys: R,
1469
+ keyPrefix: h ? u : void 0
1470
+ }) : v ? f({
1471
+ getSafeRouteKey: O,
1472
+ segment: v[1],
1473
+ routeKeys: R,
1474
+ keyPrefix: h ? i : void 0
1475
+ }) : "/" + (0, r.escapeStringRegexp)(m);
1476
+ }).join(""),
1477
+ routeKeys: R
1478
+ };
1479
+ }
1480
+ function g(p, h) {
1481
+ const _ = c(p, h);
1482
+ return {
1483
+ ...l(p),
1484
+ namedRegex: "^" + _.namedParameterizedRoute + "(?:/)?$",
1485
+ routeKeys: _.routeKeys
1486
+ };
1487
+ }
1488
+ function y(p, h) {
1489
+ const { parameterizedRoute: _ } = s(p), { catchAll: O = !0 } = h;
1490
+ if (_ === "/")
1491
+ return {
1492
+ namedRegex: "^/" + (O ? ".*" : "") + "$"
1493
+ };
1494
+ const { namedParameterizedRoute: R } = c(p, !1);
1495
+ let m = O ? "(?:(/.*)?)" : "";
1496
+ return {
1497
+ namedRegex: "^" + R + m + "$"
1498
+ };
1499
+ }
1500
+ }(We)), We;
1501
+ }
1502
+ var Vt;
1503
+ function wn() {
1504
+ return Vt || (Vt = 1, function(e) {
1505
+ Object.defineProperty(e, "__esModule", {
1506
+ value: !0
1507
+ }), Object.defineProperty(e, "interpolateAs", {
1508
+ enumerable: !0,
1509
+ get: function() {
1510
+ return r;
1511
+ }
1512
+ });
1513
+ const t = yn(), n = En();
1514
+ function r(o, i, u) {
1515
+ let a = "";
1516
+ const s = (0, n.getRouteRegex)(o), l = s.groups, d = (
1517
+ // Try to match the dynamic route against the asPath
1518
+ (i !== o ? (0, t.getRouteMatcher)(s)(i) : "") || // Fall back to reading the values from the href
1519
+ // TODO: should this take priority; also need to change in the router.
1520
+ u
1521
+ );
1522
+ a = o;
1523
+ const f = Object.keys(l);
1524
+ return f.every((c) => {
1525
+ let g = d[c] || "";
1526
+ const { repeat: y, optional: p } = l[c];
1527
+ let h = "[" + (y ? "..." : "") + c + "]";
1528
+ return p && (h = (g ? "" : "/") + "[" + h + "]"), y && !Array.isArray(g) && (g = [
1529
+ g
1530
+ ]), (p || c in d) && // Interpolate group into data URL if present
1531
+ (a = a.replace(h, y ? g.map(
1532
+ // these values should be fully encoded instead of just
1533
+ // path delimiter escaped since they are being inserted
1534
+ // into the URL and we expect URL encoded segments
1535
+ // when parsing dynamic route params
1536
+ (_) => encodeURIComponent(_)
1537
+ ).join("/") : encodeURIComponent(g)) || "/");
1538
+ }) || (a = ""), {
1539
+ params: f,
1540
+ result: a
1541
+ };
1542
+ }
1543
+ }(Be)), Be;
1544
+ }
1545
+ var Ht;
1546
+ function Sn() {
1547
+ return Ht || (Ht = 1, function(e, t) {
1548
+ Object.defineProperty(t, "__esModule", {
1549
+ value: !0
1550
+ }), Object.defineProperty(t, "resolveHref", {
1551
+ enumerable: !0,
1552
+ get: function() {
1553
+ return d;
1554
+ }
1555
+ });
1556
+ const n = Sr(), r = Tr(), o = dn(), i = Se(), u = Oe(), a = Cr(), s = hn(), l = wn();
1557
+ function d(f, c, g) {
1558
+ let y, p = typeof c == "string" ? c : (0, r.formatWithValidation)(c);
1559
+ const h = p.match(/^[a-zA-Z]{1,}:\/\//), _ = h ? p.slice(h[0].length) : p;
1560
+ if ((_.split("?")[0] || "").match(/(\/\/|\\)/)) {
1561
+ console.error("Invalid href '" + p + "' passed to next/router in page: '" + f.pathname + "'. Repeated forward-slashes (//) or backslashes \\ are not valid in the href.");
1562
+ const R = (0, i.normalizeRepeatedSlashes)(_);
1563
+ p = (h ? h[0] : "") + R;
1564
+ }
1565
+ if (!(0, a.isLocalURL)(p))
1566
+ return g ? [
1567
+ p
1568
+ ] : p;
1569
+ try {
1570
+ y = new URL(p.startsWith("#") ? f.asPath : f.pathname, "http://n");
1571
+ } catch {
1572
+ y = new URL("/", "http://n");
1573
+ }
1574
+ try {
1575
+ const R = new URL(p, y);
1576
+ R.pathname = (0, u.normalizePathTrailingSlash)(R.pathname);
1577
+ let m = "";
1578
+ if ((0, s.isDynamicRoute)(R.pathname) && R.searchParams && g) {
1579
+ const v = (0, n.searchParamsToUrlQuery)(R.searchParams), { result: P, params: S } = (0, l.interpolateAs)(R.pathname, R.pathname, v);
1580
+ P && (m = (0, r.formatWithValidation)({
1581
+ pathname: P,
1582
+ hash: R.hash,
1583
+ query: (0, o.omit)(v, S)
1584
+ }));
1585
+ }
1586
+ const E = R.origin === y.origin ? R.href.slice(R.origin.length) : R.href;
1587
+ return g ? [
1588
+ E,
1589
+ m || E
1590
+ ] : E;
1591
+ } catch {
1592
+ return g ? [
1593
+ p
1594
+ ] : p;
1595
+ }
1596
+ }
1597
+ (typeof t.default == "function" || typeof t.default == "object" && t.default !== null) && typeof t.default.__esModule > "u" && (Object.defineProperty(t.default, "__esModule", { value: !0 }), Object.assign(t.default, t), e.exports = t.default);
1598
+ }(le, le.exports)), le.exports;
1599
+ }
1600
+ var pe = { exports: {} }, Ye = {}, Qe = {}, Kt;
1601
+ function xr() {
1602
+ return Kt || (Kt = 1, function(e) {
1603
+ Object.defineProperty(e, "__esModule", {
1604
+ value: !0
1605
+ }), Object.defineProperty(e, "addPathPrefix", {
1606
+ enumerable: !0,
1607
+ get: function() {
1608
+ return n;
1609
+ }
1610
+ });
1611
+ const t = lt();
1612
+ function n(r, o) {
1613
+ if (!r.startsWith("/") || !o)
1614
+ return r;
1615
+ const { pathname: i, query: u, hash: a } = (0, t.parsePath)(r);
1616
+ return "" + o + i + u + a;
1617
+ }
1618
+ }(Qe)), Qe;
1619
+ }
1620
+ var Gt;
1621
+ function On() {
1622
+ return Gt || (Gt = 1, function(e) {
1623
+ Object.defineProperty(e, "__esModule", {
1624
+ value: !0
1625
+ }), Object.defineProperty(e, "addLocale", {
1626
+ enumerable: !0,
1627
+ get: function() {
1628
+ return r;
1629
+ }
1630
+ });
1631
+ const t = xr(), n = Nr();
1632
+ function r(o, i, u, a) {
1633
+ if (!i || i === u) return o;
1634
+ const s = o.toLowerCase();
1635
+ return !a && ((0, n.pathHasPrefix)(s, "/api") || (0, n.pathHasPrefix)(s, "/" + i.toLowerCase())) ? o : (0, t.addPathPrefix)(o, "/" + i);
1636
+ }
1637
+ }(Ye)), Ye;
1638
+ }
1639
+ var Xt;
1640
+ function Tn() {
1641
+ return Xt || (Xt = 1, function(e, t) {
1642
+ Object.defineProperty(t, "__esModule", {
1643
+ value: !0
1644
+ }), Object.defineProperty(t, "addLocale", {
1645
+ enumerable: !0,
1646
+ get: function() {
1647
+ return r;
1648
+ }
1649
+ });
1650
+ const n = Oe(), r = function(o) {
1651
+ for (var i = arguments.length, u = new Array(i > 1 ? i - 1 : 0), a = 1; a < i; a++)
1652
+ u[a - 1] = arguments[a];
1653
+ return process.env.__NEXT_I18N_SUPPORT ? (0, n.normalizePathTrailingSlash)(On().addLocale(o, ...u)) : o;
1654
+ };
1655
+ (typeof t.default == "function" || typeof t.default == "object" && t.default !== null) && typeof t.default.__esModule > "u" && (Object.defineProperty(t.default, "__esModule", { value: !0 }), Object.assign(t.default, t), e.exports = t.default);
1656
+ }(pe, pe.exports)), pe.exports;
1657
+ }
1658
+ var Je = {}, Yt;
1659
+ function In() {
1660
+ return Yt || (Yt = 1, function(e) {
1661
+ Object.defineProperty(e, "__esModule", {
1662
+ value: !0
1663
+ }), Object.defineProperty(e, "RouterContext", {
1664
+ enumerable: !0,
1665
+ get: function() {
1666
+ return r;
1667
+ }
1668
+ });
1669
+ const r = (/* @__PURE__ */ ie._(we)).default.createContext(null);
1670
+ process.env.NODE_ENV !== "production" && (r.displayName = "RouterContext");
1671
+ }(Je)), Je;
1672
+ }
1673
+ var Ze = {}, Qt;
1674
+ function Nn() {
1675
+ return Qt || (Qt = 1, function(e) {
1676
+ "use client";
1677
+ Object.defineProperty(e, "__esModule", {
1678
+ value: !0
1679
+ });
1680
+ function t(l, d) {
1681
+ for (var f in d) Object.defineProperty(l, f, {
1682
+ enumerable: !0,
1683
+ get: d[f]
1684
+ });
1685
+ }
1686
+ t(e, {
1687
+ CacheStates: function() {
1688
+ return o;
1689
+ },
1690
+ AppRouterContext: function() {
1691
+ return i;
1692
+ },
1693
+ LayoutRouterContext: function() {
1694
+ return u;
1695
+ },
1696
+ GlobalLayoutRouterContext: function() {
1697
+ return a;
1698
+ },
1699
+ TemplateContext: function() {
1700
+ return s;
1701
+ }
1702
+ });
1703
+ const r = /* @__PURE__ */ ie._(we);
1704
+ var o;
1705
+ (function(l) {
1706
+ l.LAZY_INITIALIZED = "LAZYINITIALIZED", l.DATA_FETCH = "DATAFETCH", l.READY = "READY";
1707
+ })(o || (o = {}));
1708
+ const i = r.default.createContext(null), u = r.default.createContext(null), a = r.default.createContext(null), s = r.default.createContext(null);
1709
+ process.env.NODE_ENV !== "production" && (i.displayName = "AppRouterContext", u.displayName = "LayoutRouterContext", a.displayName = "GlobalLayoutRouterContext", s.displayName = "TemplateContext");
1710
+ }(Ze)), Ze;
1711
+ }
1712
+ var me = { exports: {} }, ge = { exports: {} }, Jt;
1713
+ function Cn() {
1714
+ return Jt || (Jt = 1, function(e, t) {
1715
+ Object.defineProperty(t, "__esModule", {
1716
+ value: !0
1717
+ });
1718
+ function n(i, u) {
1719
+ for (var a in u) Object.defineProperty(i, a, {
1720
+ enumerable: !0,
1721
+ get: u[a]
1722
+ });
1723
+ }
1724
+ n(t, {
1725
+ requestIdleCallback: function() {
1726
+ return r;
1727
+ },
1728
+ cancelIdleCallback: function() {
1729
+ return o;
1730
+ }
1731
+ });
1732
+ const r = typeof self < "u" && self.requestIdleCallback && self.requestIdleCallback.bind(window) || function(i) {
1733
+ let u = Date.now();
1734
+ return self.setTimeout(function() {
1735
+ i({
1736
+ didTimeout: !1,
1737
+ timeRemaining: function() {
1738
+ return Math.max(0, 50 - (Date.now() - u));
1739
+ }
1740
+ });
1741
+ }, 1);
1742
+ }, o = typeof self < "u" && self.cancelIdleCallback && self.cancelIdleCallback.bind(window) || function(i) {
1743
+ return clearTimeout(i);
1744
+ };
1745
+ (typeof t.default == "function" || typeof t.default == "object" && t.default !== null) && typeof t.default.__esModule > "u" && (Object.defineProperty(t.default, "__esModule", { value: !0 }), Object.assign(t.default, t), e.exports = t.default);
1746
+ }(ge, ge.exports)), ge.exports;
1747
+ }
1748
+ var Zt;
1749
+ function xn() {
1750
+ return Zt || (Zt = 1, function(e, t) {
1751
+ Object.defineProperty(t, "__esModule", {
1752
+ value: !0
1753
+ }), Object.defineProperty(t, "useIntersection", {
1754
+ enumerable: !0,
1755
+ get: function() {
1756
+ return l;
1757
+ }
1758
+ });
1759
+ const n = we, r = Cn(), o = typeof IntersectionObserver == "function", i = /* @__PURE__ */ new Map(), u = [];
1760
+ function a(d) {
1761
+ const f = {
1762
+ root: d.root || null,
1763
+ margin: d.rootMargin || ""
1764
+ }, c = u.find((h) => h.root === f.root && h.margin === f.margin);
1765
+ let g;
1766
+ if (c && (g = i.get(c), g))
1767
+ return g;
1768
+ const y = /* @__PURE__ */ new Map(), p = new IntersectionObserver((h) => {
1769
+ h.forEach((_) => {
1770
+ const O = y.get(_.target), R = _.isIntersecting || _.intersectionRatio > 0;
1771
+ O && R && O(R);
1772
+ });
1773
+ }, d);
1774
+ return g = {
1775
+ id: f,
1776
+ observer: p,
1777
+ elements: y
1778
+ }, u.push(f), i.set(f, g), g;
1779
+ }
1780
+ function s(d, f, c) {
1781
+ const { id: g, observer: y, elements: p } = a(c);
1782
+ return p.set(d, f), y.observe(d), function() {
1783
+ if (p.delete(d), y.unobserve(d), p.size === 0) {
1784
+ y.disconnect(), i.delete(g);
1785
+ const _ = u.findIndex((O) => O.root === g.root && O.margin === g.margin);
1786
+ _ > -1 && u.splice(_, 1);
1787
+ }
1788
+ };
1789
+ }
1790
+ function l(d) {
1791
+ let { rootRef: f, rootMargin: c, disabled: g } = d;
1792
+ const y = g || !o, [p, h] = (0, n.useState)(!1), _ = (0, n.useRef)(null), O = (0, n.useCallback)((m) => {
1793
+ _.current = m;
1794
+ }, []);
1795
+ (0, n.useEffect)(() => {
1796
+ if (o) {
1797
+ if (y || p) return;
1798
+ const m = _.current;
1799
+ if (m && m.tagName)
1800
+ return s(m, (v) => v && h(v), {
1801
+ root: f == null ? void 0 : f.current,
1802
+ rootMargin: c
1803
+ });
1804
+ } else if (!p) {
1805
+ const m = (0, r.requestIdleCallback)(() => h(!0));
1806
+ return () => (0, r.cancelIdleCallback)(m);
1807
+ }
1808
+ }, [
1809
+ y,
1810
+ c,
1811
+ f,
1812
+ p,
1813
+ _.current
1814
+ ]);
1815
+ const R = (0, n.useCallback)(() => {
1816
+ h(!1);
1817
+ }, []);
1818
+ return [
1819
+ O,
1820
+ p,
1821
+ R
1822
+ ];
1823
+ }
1824
+ (typeof t.default == "function" || typeof t.default == "object" && t.default !== null) && typeof t.default.__esModule > "u" && (Object.defineProperty(t.default, "__esModule", { value: !0 }), Object.assign(t.default, t), e.exports = t.default);
1825
+ }(me, me.exports)), me.exports;
1826
+ }
1827
+ var he = { exports: {} }, ye = { exports: {} }, et = {}, er;
1828
+ function jn() {
1829
+ return er || (er = 1, function(e) {
1830
+ Object.defineProperty(e, "__esModule", {
1831
+ value: !0
1832
+ }), Object.defineProperty(e, "normalizeLocalePath", {
1833
+ enumerable: !0,
1834
+ get: function() {
1835
+ return t;
1836
+ }
1837
+ });
1838
+ function t(n, r) {
1839
+ let o;
1840
+ const i = n.split("/");
1841
+ return (r || []).some((u) => i[1] && i[1].toLowerCase() === u.toLowerCase() ? (o = u, i.splice(1, 1), n = i.join("/") || "/", !0) : !1), {
1842
+ pathname: n,
1843
+ detectedLocale: o
1844
+ };
1845
+ }
1846
+ }(et)), et;
1847
+ }
1848
+ var tr;
1849
+ function Ln() {
1850
+ return tr || (tr = 1, function(e, t) {
1851
+ Object.defineProperty(t, "__esModule", {
1852
+ value: !0
1853
+ }), Object.defineProperty(t, "normalizeLocalePath", {
1854
+ enumerable: !0,
1855
+ get: function() {
1856
+ return n;
1857
+ }
1858
+ });
1859
+ const n = (r, o) => process.env.__NEXT_I18N_SUPPORT ? jn().normalizeLocalePath(r, o) : {
1860
+ pathname: r,
1861
+ detectedLocale: void 0
1862
+ };
1863
+ (typeof t.default == "function" || typeof t.default == "object" && t.default !== null) && typeof t.default.__esModule > "u" && (Object.defineProperty(t.default, "__esModule", { value: !0 }), Object.assign(t.default, t), e.exports = t.default);
1864
+ }(ye, ye.exports)), ye.exports;
1865
+ }
1866
+ var _e = { exports: {} }, tt = {}, rr;
1867
+ function An() {
1868
+ return rr || (rr = 1, function(e) {
1869
+ Object.defineProperty(e, "__esModule", {
1870
+ value: !0
1871
+ }), Object.defineProperty(e, "detectDomainLocale", {
1872
+ enumerable: !0,
1873
+ get: function() {
1874
+ return t;
1875
+ }
1876
+ });
1877
+ function t(n, r, o) {
1878
+ if (n) {
1879
+ o && (o = o.toLowerCase());
1880
+ for (const a of n) {
1881
+ var i, u;
1882
+ const s = (i = a.domain) == null ? void 0 : i.split(":")[0].toLowerCase();
1883
+ if (r === s || o === a.defaultLocale.toLowerCase() || (u = a.locales) != null && u.some((l) => l.toLowerCase() === o))
1884
+ return a;
1885
+ }
1886
+ }
1887
+ }
1888
+ }(tt)), tt;
1889
+ }
1890
+ var nr;
1891
+ function Mn() {
1892
+ return nr || (nr = 1, function(e, t) {
1893
+ Object.defineProperty(t, "__esModule", {
1894
+ value: !0
1895
+ }), Object.defineProperty(t, "detectDomainLocale", {
1896
+ enumerable: !0,
1897
+ get: function() {
1898
+ return n;
1899
+ }
1900
+ });
1901
+ const n = function() {
1902
+ for (var r = arguments.length, o = new Array(r), i = 0; i < r; i++)
1903
+ o[i] = arguments[i];
1904
+ if (process.env.__NEXT_I18N_SUPPORT)
1905
+ return An().detectDomainLocale(...o);
1906
+ };
1907
+ (typeof t.default == "function" || typeof t.default == "object" && t.default !== null) && typeof t.default.__esModule > "u" && (Object.defineProperty(t.default, "__esModule", { value: !0 }), Object.assign(t.default, t), e.exports = t.default);
1908
+ }(_e, _e.exports)), _e.exports;
1909
+ }
1910
+ var or;
1911
+ function qn() {
1912
+ return or || (or = 1, function(e, t) {
1913
+ Object.defineProperty(t, "__esModule", {
1914
+ value: !0
1915
+ }), Object.defineProperty(t, "getDomainLocale", {
1916
+ enumerable: !0,
1917
+ get: function() {
1918
+ return o;
1919
+ }
1920
+ });
1921
+ const n = Oe(), r = process.env.__NEXT_ROUTER_BASEPATH || "";
1922
+ function o(i, u, a, s) {
1923
+ if (process.env.__NEXT_I18N_SUPPORT) {
1924
+ const l = Ln().normalizeLocalePath, d = Mn().detectDomainLocale, f = u || l(i, a).detectedLocale, c = d(s, void 0, f);
1925
+ if (c) {
1926
+ const g = "http" + (c.http ? "" : "s") + "://", y = f === c.defaultLocale ? "" : "/" + f;
1927
+ return "" + g + c.domain + (0, n.normalizePathTrailingSlash)("" + r + y + i);
1928
+ }
1929
+ return !1;
1930
+ } else
1931
+ return !1;
1932
+ }
1933
+ (typeof t.default == "function" || typeof t.default == "object" && t.default !== null) && typeof t.default.__esModule > "u" && (Object.defineProperty(t.default, "__esModule", { value: !0 }), Object.assign(t.default, t), e.exports = t.default);
1934
+ }(he, he.exports)), he.exports;
1935
+ }
1936
+ var ve = { exports: {} }, ir;
1937
+ function Dn() {
1938
+ return ir || (ir = 1, function(e, t) {
1939
+ Object.defineProperty(t, "__esModule", {
1940
+ value: !0
1941
+ }), Object.defineProperty(t, "addBasePath", {
1942
+ enumerable: !0,
1943
+ get: function() {
1944
+ return i;
1945
+ }
1946
+ });
1947
+ const n = xr(), r = Oe(), o = process.env.__NEXT_ROUTER_BASEPATH || "";
1948
+ function i(u, a) {
1949
+ return (0, r.normalizePathTrailingSlash)(process.env.__NEXT_MANUAL_CLIENT_BASE_PATH && !a ? u : (0, n.addPathPrefix)(u, o));
1950
+ }
1951
+ (typeof t.default == "function" || typeof t.default == "object" && t.default !== null) && typeof t.default.__esModule > "u" && (Object.defineProperty(t.default, "__esModule", { value: !0 }), Object.assign(t.default, t), e.exports = t.default);
1952
+ }(ve, ve.exports)), ve.exports;
1953
+ }
1954
+ var be = { exports: {} }, ar;
1955
+ function kn() {
1956
+ return ar || (ar = 1, function(e, t) {
1957
+ Object.defineProperty(t, "__esModule", {
1958
+ value: !0
1959
+ });
1960
+ function n(f, c) {
1961
+ for (var g in c) Object.defineProperty(f, g, {
1962
+ enumerable: !0,
1963
+ get: c[g]
1964
+ });
1965
+ }
1966
+ n(t, {
1967
+ PrefetchKind: function() {
1968
+ return d;
1969
+ },
1970
+ ACTION_REFRESH: function() {
1971
+ return r;
1972
+ },
1973
+ ACTION_NAVIGATE: function() {
1974
+ return o;
1975
+ },
1976
+ ACTION_RESTORE: function() {
1977
+ return i;
1978
+ },
1979
+ ACTION_SERVER_PATCH: function() {
1980
+ return u;
1981
+ },
1982
+ ACTION_PREFETCH: function() {
1983
+ return a;
1984
+ },
1985
+ ACTION_FAST_REFRESH: function() {
1986
+ return s;
1987
+ },
1988
+ ACTION_SERVER_ACTION: function() {
1989
+ return l;
1990
+ }
1991
+ });
1992
+ const r = "refresh", o = "navigate", i = "restore", u = "server-patch", a = "prefetch", s = "fast-refresh", l = "server-action";
1993
+ var d;
1994
+ (function(f) {
1995
+ f.AUTO = "auto", f.FULL = "full", f.TEMPORARY = "temporary";
1996
+ })(d || (d = {})), (typeof t.default == "function" || typeof t.default == "object" && t.default !== null) && typeof t.default.__esModule > "u" && (Object.defineProperty(t.default, "__esModule", { value: !0 }), Object.assign(t.default, t), e.exports = t.default);
1997
+ }(be, be.exports)), be.exports;
1998
+ }
1999
+ (function(e, t) {
2000
+ "use client";
2001
+ Object.defineProperty(t, "__esModule", {
2002
+ value: !0
2003
+ }), Object.defineProperty(t, "default", {
2004
+ enumerable: !0,
2005
+ get: function() {
2006
+ return E;
2007
+ }
2008
+ });
2009
+ const r = /* @__PURE__ */ ie._(we), o = Sn(), i = Cr(), u = Tr(), a = Se(), s = Tn(), l = In(), d = Nn(), f = xn(), c = qn(), g = Dn(), y = kn(), p = /* @__PURE__ */ new Set();
2010
+ function h(v, P, S, N, j, M) {
2011
+ if (typeof window > "u" || !M && !(0, i.isLocalURL)(P))
2012
+ return;
2013
+ if (!N.bypassPrefetchedCheck) {
2014
+ const V = (
2015
+ // Let the link's locale prop override the default router locale.
2016
+ typeof N.locale < "u" ? N.locale : "locale" in v ? v.locale : void 0
2017
+ ), G = P + "%" + S + "%" + V;
2018
+ if (p.has(G))
2019
+ return;
2020
+ p.add(G);
2021
+ }
2022
+ const Q = M ? v.prefetch(P, j) : v.prefetch(P, S, N);
2023
+ Promise.resolve(Q).catch((V) => {
2024
+ if (process.env.NODE_ENV !== "production")
2025
+ throw V;
2026
+ });
2027
+ }
2028
+ function _(v) {
2029
+ const S = v.currentTarget.getAttribute("target");
2030
+ return S && S !== "_self" || v.metaKey || v.ctrlKey || v.shiftKey || v.altKey || // triggers resource download
2031
+ v.nativeEvent && v.nativeEvent.which === 2;
2032
+ }
2033
+ function O(v, P, S, N, j, M, Q, V, G, Te) {
2034
+ const { nodeName: Ie } = v.currentTarget;
2035
+ if (Ie.toUpperCase() === "A" && (_(v) || // app-router supports external urls out of the box so it shouldn't short-circuit here as support for e.g. `replace` is added in the app-router.
2036
+ !G && !(0, i.isLocalURL)(S)))
2037
+ return;
2038
+ v.preventDefault();
2039
+ const k = () => {
2040
+ const J = Q ?? !0;
2041
+ "beforePopState" in P ? P[j ? "replace" : "push"](S, N, {
2042
+ shallow: M,
2043
+ locale: V,
2044
+ scroll: J
2045
+ }) : P[j ? "replace" : "push"](N || S, {
2046
+ forceOptimisticNavigation: !Te,
2047
+ scroll: J
2048
+ });
2049
+ };
2050
+ G ? r.default.startTransition(k) : k();
2051
+ }
2052
+ function R(v) {
2053
+ return typeof v == "string" ? v : (0, u.formatUrl)(v);
2054
+ }
2055
+ const E = /* @__PURE__ */ r.default.forwardRef(function(P, S) {
2056
+ let N;
2057
+ const { href: j, as: M, children: Q, prefetch: V = null, passHref: G, replace: Te, shallow: Ie, scroll: dt, locale: k, onClick: J, onMouseEnter: Ne, onTouchStart: pt, legacyBehavior: q = !1, ...qr } = P;
2058
+ N = Q, q && (typeof N == "string" || typeof N == "number") && (N = /* @__PURE__ */ r.default.createElement("a", null, N));
2059
+ const x = r.default.useContext(l.RouterContext), Dr = r.default.useContext(d.AppRouterContext), U = x ?? Dr, F = !x, re = V !== !1, ae = V === null ? y.PrefetchKind.AUTO : y.PrefetchKind.FULL;
2060
+ if (process.env.NODE_ENV !== "production") {
2061
+ let T = function(I) {
2062
+ return new Error("Failed prop type: The prop `" + I.key + "` expects a " + I.expected + " in `<Link>`, but got `" + I.actual + "` instead." + (typeof window < "u" ? `
2063
+ Open your browser's console to view the Component stack trace.` : ""));
2064
+ };
2065
+ Object.keys({
2066
+ href: !0
2067
+ }).forEach((I) => {
2068
+ if (I === "href" && (P[I] == null || typeof P[I] != "string" && typeof P[I] != "object"))
2069
+ throw T({
2070
+ key: I,
2071
+ expected: "`string` or `object`",
2072
+ actual: P[I] === null ? "null" : typeof P[I]
2073
+ });
2074
+ }), Object.keys({
2075
+ as: !0,
2076
+ replace: !0,
2077
+ scroll: !0,
2078
+ shallow: !0,
2079
+ passHref: !0,
2080
+ prefetch: !0,
2081
+ locale: !0,
2082
+ onClick: !0,
2083
+ onMouseEnter: !0,
2084
+ onTouchStart: !0,
2085
+ legacyBehavior: !0
2086
+ }).forEach((I) => {
2087
+ const $ = typeof P[I];
2088
+ if (I === "as") {
2089
+ if (P[I] && $ !== "string" && $ !== "object")
2090
+ throw T({
2091
+ key: I,
2092
+ expected: "`string` or `object`",
2093
+ actual: $
2094
+ });
2095
+ } else if (I === "locale") {
2096
+ if (P[I] && $ !== "string")
2097
+ throw T({
2098
+ key: I,
2099
+ expected: "`string`",
2100
+ actual: $
2101
+ });
2102
+ } else if (I === "onClick" || I === "onMouseEnter" || I === "onTouchStart") {
2103
+ if (P[I] && $ !== "function")
2104
+ throw T({
2105
+ key: I,
2106
+ expected: "`function`",
2107
+ actual: $
2108
+ });
2109
+ } else if ((I === "replace" || I === "scroll" || I === "shallow" || I === "passHref" || I === "prefetch" || I === "legacyBehavior") && P[I] != null && $ !== "boolean")
2110
+ throw T({
2111
+ key: I,
2112
+ expected: "`boolean`",
2113
+ actual: $
2114
+ });
2115
+ });
2116
+ const vt = r.default.useRef(!1);
2117
+ P.prefetch && !vt.current && !F && (vt.current = !0, console.warn("Next.js auto-prefetches automatically based on viewport. The prefetch attribute is no longer needed. More: https://nextjs.org/docs/messages/prefetch-true-deprecated"));
2118
+ }
2119
+ if (process.env.NODE_ENV !== "production" && F && !M) {
2120
+ let T;
2121
+ if (typeof j == "string" ? T = j : typeof j == "object" && typeof j.pathname == "string" && (T = j.pathname), T && T.split("/").some((ee) => ee.startsWith("[") && ee.endsWith("]")))
2122
+ throw new Error("Dynamic href `" + T + "` found in <Link> while using the `/app` router, this is not supported. Read more: https://nextjs.org/docs/messages/app-dir-dynamic-href");
2123
+ }
2124
+ const { href: B, as: A } = r.default.useMemo(() => {
2125
+ if (!x) {
2126
+ const ee = R(j);
2127
+ return {
2128
+ href: ee,
2129
+ as: M ? R(M) : ee
2130
+ };
2131
+ }
2132
+ const [T, ne] = (0, o.resolveHref)(x, j, !0);
2133
+ return {
2134
+ href: T,
2135
+ as: M ? (0, o.resolveHref)(x, M) : ne || T
2136
+ };
2137
+ }, [
2138
+ x,
2139
+ j,
2140
+ M
2141
+ ]), mt = r.default.useRef(B), gt = r.default.useRef(A);
2142
+ let L;
2143
+ if (q)
2144
+ if (process.env.NODE_ENV === "development") {
2145
+ J && console.warn('"onClick" was passed to <Link> with `href` of `' + j + '` but "legacyBehavior" was set. The legacy behavior requires onClick be set on the child of next/link'), Ne && console.warn('"onMouseEnter" was passed to <Link> with `href` of `' + j + '` but "legacyBehavior" was set. The legacy behavior requires onMouseEnter be set on the child of next/link');
2146
+ try {
2147
+ L = r.default.Children.only(N);
2148
+ } catch {
2149
+ throw N ? new Error("Multiple children were passed to <Link> with `href` of `" + j + "` but only one child is supported https://nextjs.org/docs/messages/link-multiple-children" + (typeof window < "u" ? `
2150
+ Open your browser's console to view the Component stack trace.` : "")) : new Error("No children were passed to <Link> with `href` of `" + j + "` but one child is required https://nextjs.org/docs/messages/link-no-children");
2151
+ }
2152
+ } else
2153
+ L = r.default.Children.only(N);
2154
+ else if (process.env.NODE_ENV === "development" && (N == null ? void 0 : N.type) === "a")
2155
+ throw new Error(`Invalid <Link> with <a> child. Please remove <a> or use <Link legacyBehavior>.
2156
+ Learn more: https://nextjs.org/docs/messages/invalid-new-link-with-extra-anchor`);
2157
+ const Z = q ? L && typeof L == "object" && L.ref : S, [ht, yt, _t] = (0, f.useIntersection)({
2158
+ rootMargin: "200px"
2159
+ }), kr = r.default.useCallback((T) => {
2160
+ (gt.current !== A || mt.current !== B) && (_t(), gt.current = A, mt.current = B), ht(T), Z && (typeof Z == "function" ? Z(T) : typeof Z == "object" && (Z.current = T));
2161
+ }, [
2162
+ A,
2163
+ Z,
2164
+ B,
2165
+ _t,
2166
+ ht
2167
+ ]);
2168
+ r.default.useEffect(() => {
2169
+ process.env.NODE_ENV === "production" && U && (!yt || !re || h(U, B, A, {
2170
+ locale: k
2171
+ }, {
2172
+ kind: ae
2173
+ }, F));
2174
+ }, [
2175
+ A,
2176
+ B,
2177
+ yt,
2178
+ k,
2179
+ re,
2180
+ x == null ? void 0 : x.locale,
2181
+ U,
2182
+ F,
2183
+ ae
2184
+ ]);
2185
+ const se = {
2186
+ ref: kr,
2187
+ onClick(T) {
2188
+ if (process.env.NODE_ENV !== "production" && !T)
2189
+ throw new Error('Component rendered inside next/link has to pass click event to "onClick" prop.');
2190
+ !q && typeof J == "function" && J(T), q && L.props && typeof L.props.onClick == "function" && L.props.onClick(T), U && (T.defaultPrevented || O(T, U, B, A, Te, Ie, dt, k, F, re));
2191
+ },
2192
+ onMouseEnter(T) {
2193
+ !q && typeof Ne == "function" && Ne(T), q && L.props && typeof L.props.onMouseEnter == "function" && L.props.onMouseEnter(T), U && ((!re || process.env.NODE_ENV === "development") && F || h(U, B, A, {
2194
+ locale: k,
2195
+ priority: !0,
2196
+ // @see {https://github.com/vercel/next.js/discussions/40268?sort=top#discussioncomment-3572642}
2197
+ bypassPrefetchedCheck: !0
2198
+ }, {
2199
+ kind: ae
2200
+ }, F));
2201
+ },
2202
+ onTouchStart(T) {
2203
+ !q && typeof pt == "function" && pt(T), q && L.props && typeof L.props.onTouchStart == "function" && L.props.onTouchStart(T), U && (!re && F || h(U, B, A, {
2204
+ locale: k,
2205
+ priority: !0,
2206
+ // @see {https://github.com/vercel/next.js/discussions/40268?sort=top#discussioncomment-3572642}
2207
+ bypassPrefetchedCheck: !0
2208
+ }, {
2209
+ kind: ae
2210
+ }, F));
2211
+ }
2212
+ };
2213
+ if ((0, a.isAbsoluteUrl)(A))
2214
+ se.href = A;
2215
+ else if (!q || G || L.type === "a" && !("href" in L.props)) {
2216
+ const T = typeof k < "u" ? k : x == null ? void 0 : x.locale, ne = (x == null ? void 0 : x.isLocaleDomain) && (0, c.getDomainLocale)(A, T, x == null ? void 0 : x.locales, x == null ? void 0 : x.domainLocales);
2217
+ se.href = ne || (0, g.addBasePath)((0, s.addLocale)(A, T, x == null ? void 0 : x.defaultLocale));
2218
+ }
2219
+ return q ? /* @__PURE__ */ r.default.cloneElement(L, se) : /* @__PURE__ */ r.default.createElement("a", {
2220
+ ...qr,
2221
+ ...se
2222
+ }, N);
2223
+ });
2224
+ (typeof t.default == "function" || typeof t.default == "object" && t.default !== null) && typeof t.default.__esModule > "u" && (Object.defineProperty(t.default, "__esModule", { value: !0 }), Object.assign(t.default, t), e.exports = t.default);
2225
+ })(it, it.exports);
2226
+ var zn = it.exports, Un = zn;
2227
+ const ft = /* @__PURE__ */ cn(Un), Fn = (e) => {
2228
+ const t = e.getBlocksAsArray(), n = [];
2229
+ return t.forEach((r) => {
2230
+ const o = r.getType(), i = r.getText();
2231
+ let u;
2232
+ const a = r.getInlineStyleAt(0).toArray();
2233
+ a.length > 0 && (u = a.map((l) => {
2234
+ switch (l) {
2235
+ case "BOLD":
2236
+ return "font-weight: bold;";
2237
+ case "ITALIC":
2238
+ return "font-style: italic;";
2239
+ case "UNDERLINE":
2240
+ return "text-decoration: underline;";
2241
+ default:
2242
+ return "";
2243
+ }
2244
+ }).join(" "));
2245
+ const s = {
2246
+ type: "p",
2247
+ text: i,
2248
+ ...u && { styleText: u }
2249
+ };
2250
+ switch (o) {
2251
+ case "header-one":
2252
+ s.type = "h1";
2253
+ break;
2254
+ case "header-two":
2255
+ s.type = "h2";
2256
+ break;
2257
+ case "header-three":
2258
+ s.type = "h3";
2259
+ break;
2260
+ case "unordered-list-item":
2261
+ s.type = "li";
2262
+ break;
2263
+ case "ordered-list-item":
2264
+ s.type = "li";
2265
+ break;
2266
+ case "blockquote":
2267
+ s.type = "blockquote";
2268
+ break;
2269
+ case "code-block":
2270
+ s.type = "pre";
2271
+ break;
2272
+ default:
2273
+ s.type = "p";
2274
+ }
2275
+ n.push(s);
2276
+ }), n;
2277
+ }, Bn = (e, t, n) => {
2278
+ e.findEntityRanges((r) => {
2279
+ const o = r.getEntity();
2280
+ return o === null ? !1 : n.getEntity(o).getType() === "LINK";
2281
+ }, t);
2282
+ }, st = (e) => {
2283
+ const t = new Ur([
2284
+ {
2285
+ strategy: Bn,
2286
+ component: ft
2287
+ }
2288
+ ]), n = pr(
2289
+ e
2290
+ );
2291
+ return nt.createWithContent(n, t);
2292
+ }, $n = (e) => pr(e), ut = zr.set(
2293
+ "unstyled",
2294
+ {
2295
+ element: "div",
2296
+ aliasedElements: ["div"]
2297
+ }
2298
+ ), Wn = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2299
+ __proto__: null,
2300
+ CREATE_CONTENT: st,
2301
+ EXTENDED_BLOCK_RENDER_MAP: ut,
2302
+ GET_CONTENT_STATE: $n,
2303
+ convertDraftToHTML: Fn
2304
+ }, Symbol.toStringTag, { value: "Module" })), sr = {
2305
+ "responsive-mobile-flex": "_responsive-mobile-flex_t5bry_2",
2306
+ "responsive-desktop-flex": "_responsive-desktop-flex_t5bry_13",
2307
+ "responsive-mobile-block": "_responsive-mobile-block_t5bry_24",
2308
+ "responsive-desktop-block": "_responsive-desktop-block_t5bry_35"
2309
+ }, jr = ({
2310
+ slug: e,
2311
+ data: t,
2312
+ SectionZone: n,
2313
+ COMMON_PAGE_COLUMN_GAP: r
2314
+ }) => {
2315
+ const o = t == null ? void 0 : t.find(
2316
+ (d) => {
2317
+ var f, c, g, y;
2318
+ return ((c = (f = d.config) == null ? void 0 : f.responsive) == null ? void 0 : c.deviceType) === "desktop" && ((y = (g = d.config) == null ? void 0 : g.seo) == null ? void 0 : y.slug) === e;
2319
+ }
2320
+ ), i = o == null ? void 0 : o.config.responsive.gapCustom, u = o == null ? void 0 : o.config.responsive.gapSections, a = t == null ? void 0 : t.find(
2321
+ (d) => {
2322
+ var f, c, g, y;
2323
+ return ((c = (f = d.config) == null ? void 0 : f.responsive) == null ? void 0 : c.deviceType) === "mobile" && ((y = (g = d.config) == null ? void 0 : g.seo) == null ? void 0 : y.slug) === e;
2324
+ }
2325
+ ), s = a == null ? void 0 : a.config.responsive.gapCustom, l = a == null ? void 0 : a.config.responsive.gapSections;
2326
+ return /* @__PURE__ */ W(z, { children: [
2327
+ /* @__PURE__ */ w(
2328
+ Re.Column,
2329
+ {
2330
+ gap: i && u ? u : r,
2331
+ className: Y.classNameConcat(
2332
+ sr["responsive-desktop-flex"],
2333
+ "utils-column-modifier"
2334
+ ),
2335
+ children: /* @__PURE__ */ w(n, { data: (o == null ? void 0 : o.sections) ?? [] })
2336
+ }
2337
+ ),
2338
+ /* @__PURE__ */ w(
2339
+ Re.Column,
2340
+ {
2341
+ gap: s && l ? l : r,
2342
+ className: Y.classNameConcat(
2343
+ sr["responsive-mobile-flex"],
2344
+ "utils-column-modifier"
2345
+ ),
2346
+ children: /* @__PURE__ */ w(n, { data: (a == null ? void 0 : a.sections) ?? [] })
2347
+ }
2348
+ )
2349
+ ] });
2350
+ };
2351
+ async function Vn({
2352
+ contentType: e,
2353
+ documents: t,
2354
+ NextCookies: n,
2355
+ CMS_PROJECT_NAME: r,
2356
+ storeId: o
2357
+ }) {
2358
+ var u;
2359
+ const i = JSON.parse(
2360
+ ((u = n().get("cms_preview_data")) == null ? void 0 : u.value) ?? "{}"
2361
+ );
2362
+ if (i && (i == null ? void 0 : i.contentType) === e) {
2363
+ const a = i.documentId && i.documentId.length ? `/${i.documentId}` : "", s = i != null && i.versionId && (i != null && i.versionId.length) ? `?versionId=${i == null ? void 0 : i.versionId}` : "", d = await (await fetch(
2364
+ `https://${o}.myvtex.com/_v/cms/api/${r}/${e}${a}${s}`,
2365
+ { cache: "no-store" }
2366
+ )).json(), f = t.filter(
2367
+ (c) => d.id !== c.documentId
2368
+ );
2369
+ return f.unshift(d), f;
2370
+ }
2371
+ return t;
2372
+ }
2373
+ async function Lr({
2374
+ contentType: e,
2375
+ NextCookies: t,
2376
+ CMS_PROJECT_NAME: n,
2377
+ storeId: r
2378
+ }) {
2379
+ var l, d;
2380
+ const o = JSON.parse(
2381
+ ((l = t().get("cms_preview_data")) == null ? void 0 : l.value) ?? "{}"
2382
+ ), i = [];
2383
+ let u = 1, a = 0, s = !0;
2384
+ try {
2385
+ do {
2386
+ const c = await (await fetch(
2387
+ `https://${r}.myvtex.com/_v/cms/api/${n}/${e}?page=${u}`
2388
+ )).json();
2389
+ u === 1 && (a = c.totalItems), (d = c == null ? void 0 : c.data) != null && d.length && i.push(...c.data), s = c.hasNextPage, u++;
2390
+ } while (s && i.length < a);
2391
+ if (o.previewMode && i.length) {
2392
+ const f = await Vn({
2393
+ contentType: e,
2394
+ documents: i,
2395
+ NextCookies: t,
2396
+ CMS_PROJECT_NAME: n,
2397
+ storeId: r
2398
+ });
2399
+ return {
2400
+ status: f.length > 0 ? 200 : 404,
2401
+ data: f ?? []
2402
+ };
2403
+ }
2404
+ return {
2405
+ status: i.length ? 200 : 404,
2406
+ data: i
2407
+ };
2408
+ } catch (f) {
2409
+ return { status: "error", data: [], error: f };
2410
+ }
2411
+ }
2412
+ const Ao = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
2413
+ __proto__: null,
2414
+ getContentType: Lr
2415
+ }, Symbol.toStringTag, { value: "Module" })), Hn = async ({ slug: e, SectionZone: t, COMMON_PAGE_COLUMN_GAP: n, ...r }) => {
2416
+ const { data: o } = await Lr({
2417
+ contentType: "common_page",
2418
+ ...r
2419
+ });
2420
+ return /* @__PURE__ */ w(jr, { data: o, slug: e, SectionZone: t, COMMON_PAGE_COLUMN_GAP: n });
2421
+ }, te = (e) => ({
2422
+ centro: "center",
2423
+ esquerda: "start",
2424
+ direita: "end"
2425
+ })[e], Kn = ({ expanded: e, content: t }) => /* @__PURE__ */ W("details", { open: e, children: [
2426
+ t.textStructureReduced ? /* @__PURE__ */ w("summary", { onClick: (n) => n.preventDefault(), children: /* @__PURE__ */ w(
2427
+ bt,
2428
+ {
2429
+ editorKey: "draft-editor-1",
2430
+ blockRenderMap: ut,
2431
+ editorState: t != null && t.textStructureReduced ? st(JSON.parse(t.textStructureReduced)) : nt.createEmpty(),
2432
+ onChange: () => null,
2433
+ readOnly: !0
2434
+ }
2435
+ ) }) : /* @__PURE__ */ w(z, {}),
2436
+ t.showTextStructureExpander && t.textStructure ? /* @__PURE__ */ w(z, { children: /* @__PURE__ */ w(
2437
+ bt,
2438
+ {
2439
+ editorKey: "draft-editor-1",
2440
+ blockRenderMap: ut,
2441
+ editorState: t.textStructure ? st(JSON.parse(t.textStructure)) : nt.createEmpty(),
2442
+ onChange: () => null,
2443
+ readOnly: !0
2444
+ }
2445
+ ) }) : /* @__PURE__ */ w(z, {})
2446
+ ] }), Gn = {
2447
+ "draftjs-text-modifier": "_draftjs-text-modifier_1itwm_2"
2448
+ }, Xn = "_textContentWrapper_1bigo_5", ur = {
2449
+ "link-modifier": "_link-modifier_1bigo_1",
2450
+ textContentWrapper: Xn
2451
+ }, Yn = "_link_w24h0_1", Qn = "_wrapper_w24h0_98", Jn = "_text_w24h0_106", rt = {
2452
+ link: Yn,
2453
+ wrapper: Qn,
2454
+ text: Jn
2455
+ }, Zn = ({
2456
+ children: e,
2457
+ adornments: t,
2458
+ className: n,
2459
+ disableUnderline: r,
2460
+ href: o,
2461
+ mode: i,
2462
+ size: u,
2463
+ title: a,
2464
+ onClick: s,
2465
+ disablePadding: l,
2466
+ ...d
2467
+ }) => {
2468
+ const f = Y.ValidateProp({
2469
+ fieldTypes: oe,
2470
+ property: u,
2471
+ fallback: "medium"
2472
+ }), c = Y.ValidateProp({
2473
+ fieldTypes: $r,
2474
+ property: i,
2475
+ fallback: "default"
2476
+ });
2477
+ return /* @__PURE__ */ w(
2478
+ ft,
2479
+ {
2480
+ ...d,
2481
+ className: Y.classNameConcat(rt.link, n),
2482
+ href: o && o.length > 0 ? o : "#",
2483
+ "data-size": f,
2484
+ "data-variant": c,
2485
+ title: a || "NextLink",
2486
+ "data-disable-underline": r ?? !1,
2487
+ "data-disable-padding": l ?? !0,
2488
+ children: /* @__PURE__ */ W("div", { className: rt.wrapper, onClick: s, children: [
2489
+ t == null ? void 0 : t.start,
2490
+ /* @__PURE__ */ w("p", { className: rt.text, "data-size": f, children: e }),
2491
+ t == null ? void 0 : t.end
2492
+ ] })
2493
+ }
2494
+ );
2495
+ }, eo = ({
2496
+ data: e
2497
+ }) => {
2498
+ var r;
2499
+ const [t, n] = Pe(!1);
2500
+ return /* @__PURE__ */ w(
2501
+ Pt.Root,
2502
+ {
2503
+ layoutProps: {
2504
+ textRow: {
2505
+ alignContent: te(e.textStructureAlignment),
2506
+ alignItems: te(e.textStructureAlignment)
2507
+ },
2508
+ columnWrapper: {
2509
+ alignContent: te(e.textStructureAlignment),
2510
+ alignItems: te(e.textStructureAlignment)
2511
+ }
2512
+ },
2513
+ adornment: {
2514
+ bottom: e.showTextStructureExpander && e.textStructure ? /* @__PURE__ */ w(
2515
+ Br,
2516
+ {
2517
+ variant: "tertiary",
2518
+ adornment: {
2519
+ end: /* @__PURE__ */ w(Rt, { name: t ? "arrow-up" : "arrow-down" })
2520
+ },
2521
+ onClick: () => n((o) => !o),
2522
+ size: "small",
2523
+ children: t ? "Ver Menos" : "Ver Mais"
2524
+ }
2525
+ ) : /* @__PURE__ */ w(z, {})
2526
+ },
2527
+ children: /* @__PURE__ */ W(
2528
+ Re.Column,
2529
+ {
2530
+ className: ur.textContentWrapper,
2531
+ style: {
2532
+ alignItems: te(
2533
+ e.textStructureAlignment
2534
+ )
2535
+ },
2536
+ children: [
2537
+ /* @__PURE__ */ w(
2538
+ Pt.DivWrapper,
2539
+ {
2540
+ style: {
2541
+ textAlign: te(
2542
+ e.textStructureAlignment
2543
+ )
2544
+ },
2545
+ mode: e.textStructureMode ?? "default",
2546
+ className: Gn["draftjs-text-modifier"],
2547
+ children: e.textStructureReduced ? /* @__PURE__ */ w(Kn, { content: e, expanded: t }) : /* @__PURE__ */ w(z, {})
2548
+ }
2549
+ ),
2550
+ e.textStructureButtonLabel ? /* @__PURE__ */ w(
2551
+ Zn,
2552
+ {
2553
+ mode: e.textStructureMode ?? "default",
2554
+ href: e.textStructureButtonHref ?? "#",
2555
+ size: e.textStructureButtonSize,
2556
+ className: ur["link-modifier"],
2557
+ adornments: (r = e.textStructureButtonIcon) != null && r.length && e.enableIcon ? { end: /* @__PURE__ */ w(Rt, { name: e.textStructureButtonIcon }) } : void 0,
2558
+ children: e.textStructureButtonLabel
2559
+ }
2560
+ ) : /* @__PURE__ */ w(z, {})
2561
+ ]
2562
+ }
2563
+ )
2564
+ }
2565
+ );
2566
+ }, to = (e) => ({
2567
+ centro: {
2568
+ verticalAlignment: "center",
2569
+ horizontalAlignment: "center"
2570
+ },
2571
+ "centro-esquerda": {
2572
+ verticalAlignment: "center",
2573
+ horizontalAlignment: "start"
2574
+ },
2575
+ "centro-direita": {
2576
+ verticalAlignment: "center",
2577
+ horizontalAlignment: "end"
2578
+ },
2579
+ "superior-centro": {
2580
+ verticalAlignment: "start",
2581
+ horizontalAlignment: "center"
2582
+ },
2583
+ "superior-esquerda": {
2584
+ verticalAlignment: "start",
2585
+ horizontalAlignment: "start"
2586
+ },
2587
+ "superior-direita": {
2588
+ verticalAlignment: "start",
2589
+ horizontalAlignment: "end"
2590
+ },
2591
+ "inferior-centro": {
2592
+ verticalAlignment: "end",
2593
+ horizontalAlignment: "center"
2594
+ },
2595
+ "inferior-esquerda": {
2596
+ verticalAlignment: "end",
2597
+ horizontalAlignment: "start"
2598
+ },
2599
+ "inferior-direita": {
2600
+ verticalAlignment: "end",
2601
+ horizontalAlignment: "end"
2602
+ }
2603
+ })[e], cr = (e) => ({
2604
+ centro: "center",
2605
+ esquerda: "start",
2606
+ direita: "end"
2607
+ })[e], ro = "_image_lypfr_1", no = {
2608
+ image: ro
2609
+ }, oo = ({
2610
+ alt: e,
2611
+ className: t,
2612
+ objectFit: n,
2613
+ ...r
2614
+ }) => {
2615
+ const { nextimage: o } = wr();
2616
+ return /* @__PURE__ */ w(
2617
+ o,
2618
+ {
2619
+ quality: 90,
2620
+ ...r,
2621
+ alt: e ?? "",
2622
+ className: Y.classNameConcat(no.image, t),
2623
+ "data-object-fit": n ?? "cover"
2624
+ }
2625
+ );
2626
+ }, io = ({ videoRef: e, ...t }) => /* @__PURE__ */ w("video", { ...t, ref: e, children: /* @__PURE__ */ w("track", { kind: "captions" }) }), ao = {
2627
+ Image: oo,
2628
+ Video: io
2629
+ }, lr = ({
2630
+ dateEnd: e,
2631
+ dateInit: t,
2632
+ TIME_ZONE: n = "America/Sao_Paulo",
2633
+ ...r
2634
+ }) => {
2635
+ const [o, i] = Pe(
2636
+ Qr(
2637
+ new Et(Date.now(), n),
2638
+ new Et(e, n)
2639
+ )
2640
+ ), [u, a] = Pe(!1);
2641
+ ct(() => {
2642
+ u || a(!0);
2643
+ const l = setInterval(() => {
2644
+ if (o <= 0) {
2645
+ clearInterval(l);
2646
+ return;
2647
+ }
2648
+ i(o - 1e3);
2649
+ }, 1e3);
2650
+ return () => {
2651
+ clearInterval(l);
2652
+ };
2653
+ }, [o, i, u]);
2654
+ const s = ce(o, "days");
2655
+ return u && o > 0 ? /* @__PURE__ */ W(H.Root, { ...r, children: [
2656
+ s ? /* @__PURE__ */ W(z, { children: [
2657
+ /* @__PURE__ */ w(H.Digit, { label: "dias", value: s }),
2658
+ /* @__PURE__ */ w(H.Separator, {})
2659
+ ] }) : null,
2660
+ /* @__PURE__ */ w(
2661
+ H.Digit,
2662
+ {
2663
+ label: "horas",
2664
+ value: ce(o, "hours")
2665
+ }
2666
+ ),
2667
+ /* @__PURE__ */ w(H.Separator, {}),
2668
+ /* @__PURE__ */ w(
2669
+ H.Digit,
2670
+ {
2671
+ label: "min",
2672
+ value: ce(o, "minutes")
2673
+ }
2674
+ ),
2675
+ /* @__PURE__ */ w(H.Separator, {}),
2676
+ /* @__PURE__ */ w(
2677
+ H.Digit,
2678
+ {
2679
+ label: "segs",
2680
+ value: ce(o),
2681
+ suppressHydrationWarning: !0
2682
+ }
2683
+ )
2684
+ ] }) : /* @__PURE__ */ w(z, {});
2685
+ }, fr = {
2686
+ "content-modifier": "_content-modifier_16y4u_5",
2687
+ "banner-image-wrapper-modifier": "_banner-image-wrapper-modifier_16y4u_13"
2688
+ }, dr = ({
2689
+ data: e,
2690
+ videoUrl: t,
2691
+ priority: n,
2692
+ videoRef: r,
2693
+ ...o
2694
+ }) => {
2695
+ const {
2696
+ video: i,
2697
+ image: u,
2698
+ imageHref: a,
2699
+ imageOpacity: s,
2700
+ altImage: l,
2701
+ backgroundColor: d,
2702
+ position: f,
2703
+ contentAlignment: c,
2704
+ showTimer: g,
2705
+ contentOrder: y,
2706
+ timerMode: p,
2707
+ timerEnd: h,
2708
+ timerInit: _,
2709
+ textStructure: O,
2710
+ textStructureReduced: R
2711
+ } = e.banner, m = (a == null ? void 0 : a.trim()) || (u == null ? void 0 : u.trim()) || null, { nextimage: E } = wr();
2712
+ return /* @__PURE__ */ W(Ce.Container, { ...o, children: [
2713
+ /* @__PURE__ */ W(
2714
+ Ce.ImageWrapper,
2715
+ {
2716
+ className: fr["banner-image-wrapper-modifier"],
2717
+ style: s ? { background: d } : void 0,
2718
+ children: [
2719
+ i && /* @__PURE__ */ w(
2720
+ ao.Video,
2721
+ {
2722
+ videoRef: r,
2723
+ src: t,
2724
+ autoPlay: n,
2725
+ loop: !0,
2726
+ playsInline: !0,
2727
+ muted: !0
2728
+ }
2729
+ ),
2730
+ m && !(i != null && i.length) && /* @__PURE__ */ w(
2731
+ E,
2732
+ {
2733
+ src: m,
2734
+ width: "1920",
2735
+ height: "1080",
2736
+ alt: l ?? u ?? "",
2737
+ ...n ? { priority: n } : {},
2738
+ style: s ? { opacity: "0" } : void 0
2739
+ }
2740
+ ),
2741
+ !u && !(i != null && i.length) && /* @__PURE__ */ w(
2742
+ "div",
2743
+ {
2744
+ style: {
2745
+ background: d
2746
+ }
2747
+ }
2748
+ )
2749
+ ]
2750
+ }
2751
+ ),
2752
+ g || R || O ? /* @__PURE__ */ w(
2753
+ Ce.Slot,
2754
+ {
2755
+ ...to(f ?? "centro"),
2756
+ className: fr["content-modifier"],
2757
+ style: {
2758
+ textAlign: cr(
2759
+ c
2760
+ )
2761
+ },
2762
+ children: /* @__PURE__ */ W(
2763
+ Re.Column,
2764
+ {
2765
+ gap: "16px",
2766
+ alignItems: cr(c),
2767
+ children: [
2768
+ g && y === "timer-first" && /* @__PURE__ */ w(
2769
+ lr,
2770
+ {
2771
+ mode: p ?? "default",
2772
+ size: "small",
2773
+ dateEnd: h ? new Date(h) : /* @__PURE__ */ new Date(),
2774
+ dateInit: _ ? new Date(_) : /* @__PURE__ */ new Date()
2775
+ }
2776
+ ),
2777
+ /* @__PURE__ */ w(eo, { data: e.banner }),
2778
+ g && y !== "timer-first" && /* @__PURE__ */ w(
2779
+ lr,
2780
+ {
2781
+ mode: p ?? "default",
2782
+ size: "small",
2783
+ dateEnd: h ? new Date(h) : /* @__PURE__ */ new Date(),
2784
+ dateInit: _ ? new Date(_) : /* @__PURE__ */ new Date()
2785
+ }
2786
+ )
2787
+ ]
2788
+ }
2789
+ )
2790
+ }
2791
+ ) : /* @__PURE__ */ w(z, {})
2792
+ ] });
2793
+ }, so = {
2794
+ "observer-wrapper": "_observer-wrapper_r43gk_1"
2795
+ };
2796
+ function uo(e, t, n) {
2797
+ const [r, o] = Pe(!1), { threshold: i } = n || {};
2798
+ return ct(() => {
2799
+ if (!e.current)
2800
+ return () => {
2801
+ };
2802
+ let u = null;
2803
+ const a = new IntersectionObserver(
2804
+ ([s]) => {
2805
+ if (n != null && n.delay) {
2806
+ u && clearTimeout(u), u = setTimeout(() => {
2807
+ o(s.isIntersecting), t && s.isIntersecting && a.unobserve(e.current);
2808
+ }, n.delay);
2809
+ return;
2810
+ }
2811
+ o(s.isIntersecting), t && s.isIntersecting && a.unobserve(e.current);
2812
+ },
2813
+ {
2814
+ threshold: i || 1
2815
+ }
2816
+ );
2817
+ return a.observe(e.current), () => {
2818
+ a.disconnect();
2819
+ };
2820
+ }, [e]), r;
2821
+ }
2822
+ const co = ({
2823
+ children: e,
2824
+ eventData: t,
2825
+ observerOptions: n,
2826
+ callBackWhenVisible: r,
2827
+ stopOnIntersection: o = !0,
2828
+ className: i,
2829
+ ...u
2830
+ }) => {
2831
+ const a = X(null), s = uo(a, o, n), { sendDataLayerEvent: l } = Rr();
2832
+ return ct(() => {
2833
+ s && (typeof r == "function" && r(), t && l({ ...t }));
2834
+ }, [s]), /* @__PURE__ */ w(
2835
+ "div",
2836
+ {
2837
+ ...u,
2838
+ ref: a,
2839
+ className: Y.classNameConcat(so["observer-wrapper"], i),
2840
+ children: e
2841
+ }
2842
+ );
2843
+ }, Ar = ({
2844
+ data: e,
2845
+ className: t,
2846
+ priority: n,
2847
+ creative: r,
2848
+ ...o
2849
+ }) => {
2850
+ const { handleSelectPromotionEvent: i, currentLocalRef: u } = Rr(), {
2851
+ banner: { promotion_name: a },
2852
+ index: s,
2853
+ componentIndex: l
2854
+ } = e, d = typeof s == "number" ? `:${s + 1}` : "", f = {
2855
+ creative_name: r,
2856
+ creative_slot: `${r}-${u.current}:${l + 1}${d}`,
2857
+ promotion_id: e.banner.href,
2858
+ promotion_name: a
2859
+ }, c = X(null), g = Fr(() => {
2860
+ var p;
2861
+ if ((p = e.banner.video) != null && p.includes("player.vimeo")) {
2862
+ const h = e.banner.video.split("?")[1], _ = h == null ? void 0 : h.split("&"), O = _ == null ? void 0 : _.filter(
2863
+ (m) => m.includes("loc") || m.includes("signature") || m.includes("user_id")
2864
+ ), R = O == null ? void 0 : O.join("&");
2865
+ return `${e.banner.video.split("?")[0]}?${R}`;
2866
+ }
2867
+ return e.banner.video;
2868
+ }, [e]), y = () => {
2869
+ var p;
2870
+ (p = c.current) != null && p.paused && c.current.play();
2871
+ };
2872
+ return /* @__PURE__ */ w(
2873
+ co,
2874
+ {
2875
+ eventData: {
2876
+ functionKey: "readyEvents",
2877
+ data: {
2878
+ event: "view_promotion",
2879
+ readyData: {
2880
+ ecommerce: {
2881
+ ...f,
2882
+ index: s
2883
+ }
2884
+ }
2885
+ }
2886
+ },
2887
+ observerOptions: {
2888
+ delay: 100,
2889
+ ...g && { threshold: 0.1 }
2890
+ },
2891
+ ...g && { callBackWhenVisible: y },
2892
+ children: e.banner.href ? /* @__PURE__ */ w(
2893
+ ft,
2894
+ {
2895
+ href: e.banner.href,
2896
+ onClick: () => {
2897
+ i({
2898
+ updatePromotionRef: !0,
2899
+ promotion: f,
2900
+ index: s
2901
+ });
2902
+ },
2903
+ children: /* @__PURE__ */ w(
2904
+ dr,
2905
+ {
2906
+ data: e,
2907
+ videoUrl: g,
2908
+ priority: n,
2909
+ videoRef: c,
2910
+ ...o
2911
+ }
2912
+ )
2913
+ }
2914
+ ) : /* @__PURE__ */ w(
2915
+ dr,
2916
+ {
2917
+ data: e,
2918
+ videoUrl: g,
2919
+ priority: n,
2920
+ videoRef: c,
2921
+ ...o
2922
+ }
2923
+ )
2924
+ }
2925
+ );
2926
+ }, lo = (e) => /* @__PURE__ */ w(Ar, { ...e }), fo = (e) => e, po = (e) => e, Ee = { schema: fo, base: po };
2927
+ function Mr({ ICONS: e }) {
2928
+ return {
2929
+ borderTop: b.property({
2930
+ title: "Esconder borda superior",
2931
+ type: "boolean"
2932
+ }),
2933
+ textStructure: b.property({
2934
+ title: 'Texto complementar (caso queira o "ver mais")',
2935
+ type: "string",
2936
+ widget: b.widget({
2937
+ uiWidget: "draftjs-rich-text"
2938
+ })
2939
+ }),
2940
+ textStructureReduced: b.property({
2941
+ title: "Texto inicial",
2942
+ type: "string",
2943
+ widget: b.widget({
2944
+ uiWidget: "draftjs-rich-text"
2945
+ })
2946
+ }),
2947
+ textStructureMode: b.property({
2948
+ title: "cor da estrutura de texto",
2949
+ type: "string",
2950
+ enumNames: ["Padrão(preto)", "Invertido(branco)"],
2951
+ enum: ["default", "inverse"]
2952
+ }),
2953
+ textStructureButtonSize: b.property({
2954
+ title: "Tamanho botão estrutura de texto",
2955
+ type: "string",
2956
+ enumNames: oe,
2957
+ enum: oe
2958
+ }),
2959
+ enableIcon: b.property({
2960
+ type: "boolean",
2961
+ title: "Ativar ícone"
2962
+ }),
2963
+ textStructureButtonIcon: b.property({
2964
+ title: "Icone botão estrutura de texto",
2965
+ type: "string",
2966
+ enum: Object.values(e),
2967
+ enumNames: Object.keys(e)
2968
+ }),
2969
+ textStructureButtonLabel: b.property({
2970
+ title: "Label botão estrutura de texto",
2971
+ type: "string"
2972
+ }),
2973
+ textStructureButtonHref: b.property({
2974
+ title: "Url botão estrutura texto",
2975
+ type: "string"
2976
+ }),
2977
+ showTextStructureExpander: b.property({
2978
+ title: 'Mostrar botão "ver mais" (Caso ja tenha um texto reduzido)',
2979
+ type: "boolean"
2980
+ }),
2981
+ textStructureAlignment: b.property({
2982
+ title: "alinhamento do texto",
2983
+ type: "string",
2984
+ enumNames: ["centro", "esquerda", "direita"],
2985
+ enum: ["centro", "esquerda", "direita"]
2986
+ })
2987
+ };
2988
+ }
2989
+ function mo({ ICONS: e }) {
2990
+ return b.property({
2991
+ type: "object",
2992
+ title: "Item",
2993
+ properties: {
2994
+ title: b.property({ type: "object", title: "Item" }),
2995
+ creative_name: b.property({
2996
+ type: "string",
2997
+ title: "creative name ex: carrossel home, ex2: stories"
2998
+ }),
2999
+ creative_slot: b.property({
3000
+ type: "string",
3001
+ title: "creative slot ex: carrossel-home: 1"
3002
+ }),
3003
+ promotion_id: b.property({
3004
+ type: "string",
3005
+ title: "promotion id ex: /animale: ex2: /new-collection?O=OrderByScoreDESC"
3006
+ }),
3007
+ promotion_name: b.property({
3008
+ type: "string",
3009
+ title: "promotion name ex: special-gift-for-you"
3010
+ }),
3011
+ href: b.property({
3012
+ type: "string",
3013
+ title: "Link"
3014
+ }),
3015
+ image: b.property({
3016
+ type: "string",
3017
+ title: "Imagem upload",
3018
+ description: "Upload de imagens ou seleção de imagens já existentes.",
3019
+ widget: b.widget({
3020
+ uiWidget: "media-gallery"
3021
+ })
3022
+ }),
3023
+ imageHref: b.property({
3024
+ type: "string",
3025
+ title: "Imagem via link",
3026
+ description: "Informe um link de imagem apenas se não for usar o upload da VTEX. Os dois não podem ser usados juntos."
3027
+ }),
3028
+ imageOpacity: b.property({
3029
+ title: "Deixar imagem transparente",
3030
+ type: "boolean"
3031
+ }),
3032
+ headerVariant: b.property({
3033
+ title: "cor do header no banner principal (se Banner Carousel na home)",
3034
+ type: "string",
3035
+ enumNames: ["Padrão(preto)", "Invertido(branco)"],
3036
+ enum: ["transparent-black", "transparent-white"]
3037
+ }),
3038
+ video: b.property({
3039
+ type: "string",
3040
+ title: "Video",
3041
+ widget: b.widget({
3042
+ uiWidget: "media-gallery"
3043
+ })
3044
+ }),
3045
+ altImage: b.property({
3046
+ type: "string",
3047
+ title: "Alt Image"
3048
+ }),
3049
+ isHeroBanner: b.property({
3050
+ title: "é hero banner",
3051
+ type: "boolean"
3052
+ }),
3053
+ backgroundColor: b.property({
3054
+ title: "Cor de fundo ex: #ffffff",
3055
+ type: "string"
3056
+ }),
3057
+ position: b.property({
3058
+ title: "Posição do conteudo na imagem",
3059
+ type: "string",
3060
+ enumNames: [
3061
+ "superior-esquerda",
3062
+ "superior-centro",
3063
+ "superior-direita",
3064
+ "centro",
3065
+ "centro-esquerda",
3066
+ "centro-direita",
3067
+ "inferior-esquerda",
3068
+ "inferior-centro",
3069
+ "inferior-direita"
3070
+ ],
3071
+ enum: [
3072
+ "superior-esquerda",
3073
+ "superior-centro",
3074
+ "superior-direita",
3075
+ "centro",
3076
+ "centro-esquerda",
3077
+ "centro-direita",
3078
+ "inferior-esquerda",
3079
+ "inferior-centro",
3080
+ "inferior-direita"
3081
+ ]
3082
+ }),
3083
+ showTimer: b.property({
3084
+ title: "mostrar relogio",
3085
+ type: "boolean"
3086
+ }),
3087
+ timerInit: b.property({
3088
+ title: "relogio inicio",
3089
+ type: "string",
3090
+ widget: {
3091
+ "ui:widget": "date-time"
3092
+ }
3093
+ }),
3094
+ timerEnd: b.property({
3095
+ title: "relogio Fim",
3096
+ type: "string",
3097
+ widget: {
3098
+ "ui:widget": "date-time"
3099
+ }
3100
+ }),
3101
+ timerMode: b.property({
3102
+ title: "cor do relogio",
3103
+ type: "string",
3104
+ enumNames: ["Padrão(preto)", "Invertido(branco)"],
3105
+ enum: ["default", "inverse"]
3106
+ }),
3107
+ timerSize: b.property({
3108
+ title: "tamanho do relogio",
3109
+ type: "string",
3110
+ enumNames: oe,
3111
+ enum: oe
3112
+ }),
3113
+ contentAlignment: b.property({
3114
+ title: "alinhamento do conteúdo",
3115
+ type: "string",
3116
+ enumNames: ["centro", "esquerda", "direita"],
3117
+ enum: ["centro", "esquerda", "direita"]
3118
+ }),
3119
+ contentOrder: b.property({
3120
+ title: "ordem do conteúdo",
3121
+ type: "string",
3122
+ enumNames: ["relógio primeiro", "estrutura de texto primeiro"],
3123
+ enum: ["timer-first", "text-structure-first"]
3124
+ }),
3125
+ ...Mr({ ICONS: e })
3126
+ }
3127
+ });
3128
+ }
3129
+ function go({ ICONS: e }) {
3130
+ return Ee.base({
3131
+ name: "Banner",
3132
+ id: "banner",
3133
+ href: "",
3134
+ requiredScopes: [
3135
+ "common_page",
3136
+ "categories_page",
3137
+ "wishlist_page",
3138
+ "search_page",
3139
+ "prehome"
3140
+ ],
3141
+ schema: Ee.schema({
3142
+ title: "Banner",
3143
+ description: "Banners Único para pagina",
3144
+ type: "object",
3145
+ properties: {
3146
+ banner: mo({ ICONS: e })
3147
+ }
3148
+ })
3149
+ });
3150
+ }
3151
+ const ho = { Banner: lo };
3152
+ function yo({ ICONS: e }) {
3153
+ return Ee.base({
3154
+ name: "TextContent",
3155
+ id: "text_content",
3156
+ requiredScopes: [
3157
+ "common_page",
3158
+ "product_page",
3159
+ "categories_page",
3160
+ "wishlist_page",
3161
+ "search_page",
3162
+ "policy_tab"
3163
+ ],
3164
+ schema: Ee.schema({
3165
+ title: "TextStructure",
3166
+ description: "Estrutura de texto",
3167
+ type: "object",
3168
+ properties: {
3169
+ ...Mr({ ICONS: e })
3170
+ }
3171
+ })
3172
+ });
3173
+ }
3174
+ const _o = [
3175
+ go,
3176
+ yo
3177
+ ], vo = {
3178
+ Banner: ho,
3179
+ BannerSection: Ar,
3180
+ DataScreening: jr
3181
+ }, bo = {
3182
+ CommonPageContent: Hn
3183
+ }, Mo = { Components: vo, ContentTypes: un, Factories: on, Sections: _o, helpers: Wn }, qo = { Components: bo };
3184
+ export {
3185
+ jo as E,
3186
+ ft as L,
3187
+ ao as M,
3188
+ Lo as N,
3189
+ co as O,
3190
+ lr as T,
3191
+ ie as _,
3192
+ No as a,
3193
+ wr as b,
3194
+ ce as c,
3195
+ Qr as d,
3196
+ xo as e,
3197
+ Yr as f,
3198
+ hr as g,
3199
+ cn as h,
3200
+ Cn as i,
3201
+ at as j,
3202
+ Zn as k,
3203
+ sr as l,
3204
+ Mo as m,
3205
+ Ao as n,
3206
+ qo as o,
3207
+ Co as r,
3208
+ Wr as s,
3209
+ Rr as u
3210
+ };