@lanaco/lnc-react-ui 4.0.38 → 4.0.40

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 (67) hide show
  1. package/dist/BannerSectionBasic.cjs +9 -9
  2. package/dist/BannerSectionBasic.js +20 -20
  3. package/dist/BannerSectionCarousel.cjs +13 -5
  4. package/dist/BannerSectionCarousel.js +29 -21
  5. package/dist/BannerSectionGrid.cjs +1 -1
  6. package/dist/BannerSectionGrid.js +6 -6
  7. package/dist/BannerSectionSimple.cjs +4 -4
  8. package/dist/BannerSectionSimple.js +41 -38
  9. package/dist/BannerSectionWithList.cjs +4 -4
  10. package/dist/BannerSectionWithList.js +17 -17
  11. package/dist/BannerSectionWithListImage.cjs +5 -5
  12. package/dist/BannerSectionWithListImage.js +41 -38
  13. package/dist/BlogsSectionDetailed.cjs +15 -15
  14. package/dist/BlogsSectionDetailed.js +128 -92
  15. package/dist/BlogsSectionLarge.cjs +10 -10
  16. package/dist/BlogsSectionLarge.js +87 -60
  17. package/dist/BlogsSectionSimple.cjs +8 -8
  18. package/dist/BlogsSectionSimple.js +98 -72
  19. package/dist/BlogsSectionSimpleCentered.cjs +10 -10
  20. package/dist/BlogsSectionSimpleCentered.js +76 -46
  21. package/dist/BlogsSectionWithFilters.cjs +11 -11
  22. package/dist/BlogsSectionWithFilters.js +102 -73
  23. package/dist/BrandHitsSection.cjs +12 -7
  24. package/dist/BrandHitsSection.js +10 -5
  25. package/dist/CalorieCalculatorSection.cjs +7 -8
  26. package/dist/CalorieCalculatorSection.js +31 -32
  27. package/dist/CustomLoanMapSection.cjs +2 -2
  28. package/dist/CustomLoanMapSection.js +13 -13
  29. package/dist/DetailedProductsSection.cjs +4 -4
  30. package/dist/DetailedProductsSection.js +66 -57
  31. package/dist/FieldOfInterestsWithAvatarsCardsSection.cjs +8 -8
  32. package/dist/FieldOfInterestsWithAvatarsCardsSection.js +9 -8
  33. package/dist/FieldOfInterestsWithTagsCardsSection.cjs +14 -6
  34. package/dist/FieldOfInterestsWithTagsCardsSection.js +12 -4
  35. package/dist/GeneralWithTagsCardsSection.cjs +18 -6
  36. package/dist/GeneralWithTagsCardsSection.js +44 -31
  37. package/dist/GiftCardsSection.cjs +9 -5
  38. package/dist/GiftCardsSection.js +21 -17
  39. package/dist/LocationSearchSection.cjs +1 -1
  40. package/dist/LocationSearchSection.js +1 -1
  41. package/dist/MasonryGeneralCardsSection.cjs +21 -1
  42. package/dist/MasonryGeneralCardsSection.js +20 -0
  43. package/dist/OverlayGeneralCardsSection.cjs +60 -104
  44. package/dist/OverlayGeneralCardsSection.js +138 -147
  45. package/dist/ProductsWithBannerSection.cjs +10 -10
  46. package/dist/ProductsWithBannerSection.js +85 -54
  47. package/dist/SalesCampaignsSection.cjs +17 -17
  48. package/dist/SalesCampaignsSection.js +81 -81
  49. package/dist/ShopCardsSection.cjs +19 -9
  50. package/dist/ShopCardsSection.js +54 -40
  51. package/dist/SimpleCategoriesSection.cjs +9 -9
  52. package/dist/SimpleCategoriesSection.js +89 -58
  53. package/dist/SimpleProductsSection.cjs +3 -3
  54. package/dist/SimpleProductsSection.js +86 -55
  55. package/dist/UrgentSaleProductsSection.cjs +5 -5
  56. package/dist/UrgentSaleProductsSection.js +41 -30
  57. package/dist/{index-CT6_7UFb.js → index-5cttM4t7.js} +119 -124
  58. package/dist/{index-CHkb_Sj6.js → index-BT55M3t6.js} +16 -15
  59. package/dist/{index-Dj5wZCVs.cjs → index-DHJmdMN8.cjs} +6 -5
  60. package/dist/index-Dn5tPLgP.cjs +95 -0
  61. package/dist/{style-6tSw9aqK.js → style-CiePxaJ_.js} +6 -6
  62. package/dist/{style-BR3tIhP1.cjs → style-DN1qT8BE.cjs} +6 -6
  63. package/dist/suspense-product-card-detailed-BETmfKMT.js +189 -0
  64. package/dist/{index-vXmvgZ2Y.cjs → suspense-product-card-detailed-DtzOxHaH.cjs} +4 -4
  65. package/package.json +1 -1
  66. package/dist/index-D6g5ZqyJ.js +0 -159
  67. package/dist/index-Q_i-aqsF.cjs +0 -95
@@ -1,28 +1,28 @@
1
- import { jsxs as t, jsx as r } from "react/jsx-runtime";
2
- import { forwardRef as w } from "react";
3
- import { n as u } from "./emotion-styled.browser.esm-CjCaF13H.js";
4
- import { M as v } from "./consts-C1uHV4xc.js";
5
- import { u as N } from "./useDetectMobile-BC6EGaBc.js";
6
- import { m as f, t as C, k as h } from "./utils-DtRLzzTZ.js";
7
- import { B as O, R as S } from "./style-6tSw9aqK.js";
8
- import $ from "./Button.js";
9
- const D = u.div`
1
+ import { jsxs as t, jsx as r, Fragment as w } from "react/jsx-runtime";
2
+ import { forwardRef as v, Suspense as D, memo as O, useMemo as B } from "react";
3
+ import { n as k } from "./emotion-styled.browser.esm-CjCaF13H.js";
4
+ import { M as C } from "./consts-C1uHV4xc.js";
5
+ import { u as P } from "./useDetectMobile-BC6EGaBc.js";
6
+ import { m as b, t as T, k as y } from "./utils-DtRLzzTZ.js";
7
+ import { B as L, R as z } from "./style-CiePxaJ_.js";
8
+ import M from "./Button.js";
9
+ const R = k.div`
10
10
  display: grid;
11
- grid-template-columns: ${(o) => `repeat(${o.limit}, minmax(0, 1fr))`};
11
+ grid-template-columns: ${(i) => `repeat(${i.limit}, minmax(0, 1fr))`};
12
12
  gap: 1.25rem;
13
13
 
14
- @media (max-width: ${v + "px"}) {
14
+ @media (max-width: ${C + "px"}) {
15
15
  grid-template-columns: repeat(1, 1fr);
16
16
  }
17
- `, T = u.div`
17
+ `, S = k.div`
18
18
  display: flex;
19
19
  flex-direction: column;
20
20
  width: 100%;
21
21
  box-shadow: 0px 1px 3px 0px rgba(0, 0, 0, 0.1),
22
22
  0px 1px 2px 0px rgba(0, 0, 0, 0.06);
23
- background-color: var(--white);
23
+ background-color: var(--white, #fff);
24
24
  border-radius: 0.75rem;
25
- border: 1px solid var(--gray-95008);
25
+ border: 1px solid var(--gray-95008, #14161a14);
26
26
  overflow: hidden;
27
27
  max-height: 21.5625rem;
28
28
  min-height: 21.5625rem;
@@ -45,7 +45,7 @@ const D = u.div`
45
45
  width: 100%;
46
46
  max-height: 11.0625rem;
47
47
  min-height: 11.0625rem;
48
- background-color: ${f("-90deg")};
48
+ background-color: ${b("-90deg")};
49
49
  }
50
50
 
51
51
  & .tags-wr {
@@ -55,15 +55,15 @@ const D = u.div`
55
55
  padding: 0 1rem 1rem 1rem;
56
56
  }
57
57
 
58
- @media (max-width: ${v + "px"}) {
58
+ @media (max-width: ${C + "px"}) {
59
59
  }
60
- `, B = u.div`
60
+ `, $ = k.div`
61
61
  padding: 1rem 1rem 0 1rem;
62
62
  display: flex;
63
63
  flex-direction: column;
64
64
  gap: 0;
65
65
  color: var(--gray-950, #14161a);
66
- border-top: 1px solid var(--gray-95008);
66
+ border-top: 1px solid var(--gray-95008, #14161a14);
67
67
 
68
68
  & .text-wr-title {
69
69
  font-weight: 600;
@@ -71,13 +71,13 @@ const D = u.div`
71
71
  }
72
72
 
73
73
  & .info-wr-skeleton {
74
- background-color: ${f("-90deg")};
74
+ background-color: ${b("-90deg")};
75
75
  height: 1rem;
76
76
  width: 100%;
77
77
  }
78
78
 
79
79
  & .skeleton-title {
80
- background-color: ${f("-90deg")};
80
+ background-color: ${b("-90deg")};
81
81
  height: 1.5rem;
82
82
  width: 70%;
83
83
  }
@@ -87,7 +87,7 @@ const D = u.div`
87
87
  font-size: 0.875rem;
88
88
  flex: 1;
89
89
  color: var(--gray-700, #4e555f);
90
- ${C(2)}
90
+ ${T(2)}
91
91
  }
92
92
 
93
93
  & .info-wr {
@@ -101,7 +101,7 @@ const D = u.div`
101
101
 
102
102
  & .mng {
103
103
  font-size: 0.875rem;
104
- color: var(--gray-300);
104
+ color: var(--gray-300, #c4c8cf);
105
105
  }
106
106
  }
107
107
 
@@ -116,109 +116,145 @@ const D = u.div`
116
116
  align-items: center;
117
117
  gap: 1rem;
118
118
  }
119
- `, b = w((o, k) => {
119
+ `, j = v((i, s) => {
120
120
  const {
121
- title: s,
122
- image: c,
123
- text: g,
124
- numberOfLikes: i,
125
- numberOfComments: p,
126
- readDuration: l,
127
- datePublished: d,
128
- tags: m,
129
- onCardClick: e,
130
- timeToReadText: a = "read"
131
- } = o;
121
+ title: a,
122
+ image: d,
123
+ text: l,
124
+ numberOfLikes: n,
125
+ numberOfComments: u,
126
+ readDuration: m,
127
+ datePublished: c,
128
+ tags: g,
129
+ onCardClick: f,
130
+ timeToReadText: p = "read"
131
+ } = i;
132
132
  return (
133
133
  // <BlogCardDetailedSkeleton />
134
- /* @__PURE__ */ t(T, { className: "blog-card", onClick: e, children: [
135
- /* @__PURE__ */ r("img", { src: c }),
136
- /* @__PURE__ */ t(B, { children: [
134
+ /* @__PURE__ */ t(S, { ref: s, className: "blog-card", onClick: f, children: [
135
+ /* @__PURE__ */ r("img", { src: d }),
136
+ /* @__PURE__ */ t($, { children: [
137
137
  /* @__PURE__ */ t("div", { className: "info-wr", children: [
138
138
  /* @__PURE__ */ t("div", { className: "info-wr-1", children: [
139
- /* @__PURE__ */ r("span", { children: d }),
139
+ /* @__PURE__ */ r("span", { children: c }),
140
140
  /* @__PURE__ */ r("span", { className: "small-dot", children: "●" }),
141
- l && a ? `${l} ${a}` : "N/A"
141
+ m && p ? `${m} ${p}` : "N/A"
142
142
  ] }),
143
143
  /* @__PURE__ */ t("div", { className: "info-wr-2", children: [
144
144
  /* @__PURE__ */ t("span", { className: "info-wr-1", children: [
145
145
  /* @__PURE__ */ r("i", { className: "mng mng-lnc-thumbs-up--filled" }),
146
- /* @__PURE__ */ r("span", { children: i })
146
+ /* @__PURE__ */ r("span", { children: n })
147
147
  ] }),
148
148
  /* @__PURE__ */ t("span", { className: "info-wr-1", children: [
149
149
  /* @__PURE__ */ r("i", { className: "mng mng-lnc-messages-filled" }),
150
- /* @__PURE__ */ r("span", { children: p })
150
+ /* @__PURE__ */ r("span", { children: u })
151
151
  ] })
152
152
  ] })
153
153
  ] }),
154
- /* @__PURE__ */ r("div", { className: "text-wr-title", children: s }),
155
- /* @__PURE__ */ r("div", { className: "text-wr", children: g })
154
+ /* @__PURE__ */ r("div", { className: "text-wr-title", children: a }),
155
+ /* @__PURE__ */ r("div", { className: "text-wr", children: l })
156
156
  ] }),
157
- /* @__PURE__ */ r("div", { className: "tags-wr", children: m == null ? void 0 : m.map((n, y) => /* @__PURE__ */ r(O, { color: n == null ? void 0 : n.color, children: n == null ? void 0 : n.name }, y)) })
157
+ /* @__PURE__ */ r("div", { className: "tags-wr", children: g == null ? void 0 : g.map((o, e) => /* @__PURE__ */ r(L, { color: o == null ? void 0 : o.color, children: o == null ? void 0 : o.name }, e)) })
158
158
  ] })
159
159
  );
160
- }), E = w((o, k) => {
160
+ }), A = v(({}, i) => /* @__PURE__ */ t(S, { className: "blog-card", children: [
161
+ /* @__PURE__ */ r("div", { className: "skeleton-img" }),
162
+ /* @__PURE__ */ t($, { children: [
163
+ /* @__PURE__ */ r("div", { className: "info-wr" }),
164
+ /* @__PURE__ */ r("div", { className: "skeleton-title" }),
165
+ /* @__PURE__ */ r("div", { className: "info-wr-skeleton" })
166
+ ] })
167
+ ] })), W = ({ limit: i = 3, isLoading: s = !1, keyPrefix: a }) => /* @__PURE__ */ r(w, { children: Array.from({ length: i }, (d, l) => /* @__PURE__ */ r(
168
+ A,
169
+ {
170
+ isLoading: s
171
+ },
172
+ `${a}-skeleton-product-card-${l}`
173
+ )) }), E = ({
174
+ children: i,
175
+ fallbackComponent: s = /* @__PURE__ */ r(w, {}),
176
+ isLoading: a = !1,
177
+ limit: d,
178
+ keyPrefix: l
179
+ }) => /* @__PURE__ */ r(D, { fallbackComponent: s, children: a === !0 ? /* @__PURE__ */ r(
180
+ W,
181
+ {
182
+ isLoading: a,
183
+ limit: d,
184
+ keyPrefix: l
185
+ }
186
+ ) : i }), N = O(j), J = v((i, s) => {
161
187
  const {
162
- icon: s,
163
- title: c,
164
- onButtonAction: g,
165
- items: i,
166
- buttonText: p,
167
- limit: l = 3,
168
- onSelectCard: d = () => {
169
- }
170
- } = o, m = N();
171
- return /* @__PURE__ */ t(S, { children: [
188
+ icon: a,
189
+ title: d,
190
+ onButtonAction: l,
191
+ items: n,
192
+ buttonText: u,
193
+ limit: m = 3,
194
+ onSelectCard: c = () => {
195
+ },
196
+ isLoading: g = !1,
197
+ buttonLink: f
198
+ } = i, p = P(), o = B(() => /* @__PURE__ */ r(w, { children: p === !0 ? n == null ? void 0 : n.map((e, h) => /* @__PURE__ */ r(
199
+ N,
200
+ {
201
+ title: e == null ? void 0 : e.title,
202
+ image: e == null ? void 0 : e.image,
203
+ text: e == null ? void 0 : e.text,
204
+ titleSlug: e == null ? void 0 : e.titleSlug,
205
+ numberOfLikes: e == null ? void 0 : e.numberOfLikes,
206
+ numberOfComments: e == null ? void 0 : e.numberOfComments,
207
+ datePublished: e == null ? void 0 : e.date,
208
+ readDuration: e == null ? void 0 : e.readDuration,
209
+ tags: e == null ? void 0 : e.tags,
210
+ onCardClick: () => c(e == null ? void 0 : e.uuid)
211
+ },
212
+ h
213
+ )) : n == null ? void 0 : n.slice(0, m).map((e, h) => /* @__PURE__ */ r(
214
+ N,
215
+ {
216
+ title: e == null ? void 0 : e.title,
217
+ image: e == null ? void 0 : e.image,
218
+ text: e == null ? void 0 : e.text,
219
+ titleSlug: e == null ? void 0 : e.titleSlug,
220
+ tags: e == null ? void 0 : e.tags,
221
+ numberOfLikes: e == null ? void 0 : e.numberOfLikes,
222
+ numberOfComments: e == null ? void 0 : e.numberOfComments,
223
+ datePublished: e == null ? void 0 : e.date,
224
+ readDuration: e == null ? void 0 : e.readDuration,
225
+ onCardClick: () => c(e == null ? void 0 : e.uuid)
226
+ },
227
+ h
228
+ )) }), [n, p, m, c]);
229
+ return /* @__PURE__ */ t(z, { ref: s, children: [
172
230
  /* @__PURE__ */ t("div", { className: "regular-title", children: [
173
231
  /* @__PURE__ */ t("div", { className: "regular-title-text", children: [
174
- h(s) && /* @__PURE__ */ r("i", { className: s }),
175
- /* @__PURE__ */ r("span", { children: c })
232
+ y(a) && /* @__PURE__ */ r("i", { className: a }),
233
+ /* @__PURE__ */ r("span", { children: d })
176
234
  ] }),
177
- h(onSectionClick) && /* @__PURE__ */ r(
178
- $,
235
+ y(l) && /* @__PURE__ */ r(
236
+ M,
179
237
  {
180
238
  type: "button",
181
239
  btnType: "tinted",
182
240
  color: "gray",
183
- onClick: () => g(buttonLink),
241
+ onClick: () => l(f),
184
242
  borderRadius: "curved",
185
- children: p
243
+ children: u
186
244
  }
187
245
  )
188
246
  ] }),
189
- /* @__PURE__ */ r(D, { limit: l, children: m === !0 ? i == null ? void 0 : i.map((e, a) => /* @__PURE__ */ r(
190
- b,
191
- {
192
- title: e == null ? void 0 : e.title,
193
- image: e == null ? void 0 : e.image,
194
- text: e == null ? void 0 : e.text,
195
- titleSlug: e == null ? void 0 : e.titleSlug,
196
- numberOfLikes: e == null ? void 0 : e.numberOfLikes,
197
- numberOfComments: e == null ? void 0 : e.numberOfComments,
198
- datePublished: e == null ? void 0 : e.date,
199
- readDuration: e == null ? void 0 : e.readDuration,
200
- tags: e == null ? void 0 : e.tags,
201
- onCardClick: () => d(e == null ? void 0 : e.uuid)
202
- },
203
- a
204
- )) : i == null ? void 0 : i.slice(0, l).map((e, a) => /* @__PURE__ */ r(
205
- b,
247
+ /* @__PURE__ */ r(R, { limit: m, children: /* @__PURE__ */ r(
248
+ E,
206
249
  {
207
- title: e == null ? void 0 : e.title,
208
- image: e == null ? void 0 : e.image,
209
- text: e == null ? void 0 : e.text,
210
- titleSlug: e == null ? void 0 : e.titleSlug,
211
- tags: e == null ? void 0 : e.tags,
212
- numberOfLikes: e == null ? void 0 : e.numberOfLikes,
213
- numberOfComments: e == null ? void 0 : e.numberOfComments,
214
- datePublished: e == null ? void 0 : e.date,
215
- readDuration: e == null ? void 0 : e.readDuration,
216
- onCardClick: () => d(e == null ? void 0 : e.uuid)
217
- },
218
- a
219
- )) })
250
+ isLoading: g,
251
+ limit: m,
252
+ keyPrefix: "explore-landing",
253
+ children: o
254
+ }
255
+ ) })
220
256
  ] });
221
257
  });
222
258
  export {
223
- E as default
259
+ J as default
224
260
  };
@@ -1,12 +1,12 @@
1
- "use strict";const t=require("react/jsx-runtime"),d=require("react"),s=require("./emotion-styled.browser.esm-Cle7tAM9.cjs"),c=require("./consts-CtNoHdBj.cjs"),h=require("./useDetectMobile-D6d5LpdL.cjs"),l=require("./utils-NZLCh-J5.cjs"),g=require("./Button.cjs"),f=s.newStyled.div`
1
+ "use strict";const t=require("react/jsx-runtime"),s=require("react"),u=require("./emotion-styled.browser.esm-Cle7tAM9.cjs"),h=require("./consts-CtNoHdBj.cjs"),b=require("./useDetectMobile-D6d5LpdL.cjs"),g=require("./utils-NZLCh-J5.cjs"),p=require("./Button.cjs"),x=u.newStyled.div`
2
2
  display: grid;
3
3
  grid-template-columns: ${i=>`repeat(${i.limit}, minmax(0, 1fr))`};
4
4
  gap: 1.25rem;
5
5
 
6
- @media (max-width: ${c.MOBILE_SIZE_PX+"px"}) {
6
+ @media (max-width: ${h.MOBILE_SIZE_PX+"px"}) {
7
7
  grid-template-columns: repeat(1, 1fr);
8
8
  }
9
- `,p=s.newStyled.div`
9
+ `,f=u.newStyled.div`
10
10
  display: flex;
11
11
  width: 100%;
12
12
  gap: 1.25rem;
@@ -35,11 +35,11 @@
35
35
  min-height: 12.25rem;
36
36
  min-width: 11.25rem;
37
37
  max-width: 11.25rem;
38
- background-color: ${l.linearGradientAnimation("-90deg")};
38
+ background-color: ${g.linearGradientAnimation("-90deg")};
39
39
  border-radius: 0.75rem 0 0 0.75rem;
40
40
  }
41
41
 
42
- @media (max-width: ${c.MOBILE_SIZE_PX+"px"}) {
42
+ @media (max-width: ${h.MOBILE_SIZE_PX+"px"}) {
43
43
  padding: 1rem;
44
44
  column-gap: 1.5rem;
45
45
  row-gap: 1rem;
@@ -65,7 +65,7 @@
65
65
  margin-top: auto;
66
66
  }
67
67
  }
68
- `,w=s.newStyled.div`
68
+ `,j=u.newStyled.div`
69
69
  padding: 1rem;
70
70
  display: flex;
71
71
  flex-direction: column;
@@ -81,7 +81,7 @@
81
81
  font-weight: 400;
82
82
  font-size: 0.875rem;
83
83
  color: var(--gray-700, #4e555f);
84
- ${l.truncateTextInRows(3)}
84
+ ${g.truncateTextInRows(3)}
85
85
  }
86
86
 
87
87
  & button {
@@ -92,10 +92,10 @@
92
92
  & .skeleton-title {
93
93
  height: 1.75rem;
94
94
  width: 80%;
95
- background-color: ${l.linearGradientAnimation("-90deg")};
95
+ background-color: ${g.linearGradientAnimation("-90deg")};
96
96
  }
97
97
 
98
- @media (max-width: ${c.MOBILE_SIZE_PX+"px"}) {
98
+ @media (max-width: ${h.MOBILE_SIZE_PX+"px"}) {
99
99
  padding: 0;
100
100
  }
101
- `;d.forwardRef(({},i)=>t.jsxs(p,{className:"blog-card",children:[t.jsx("div",{className:"skeleton-img"}),t.jsx(w,{children:t.jsx("div",{className:"skeleton-title"})})]}));const u=d.forwardRef((i,b)=>{const{title:r,image:n,text:m,onCardClick:a,buttonText:e}=i,o=h.useDetectMobile();return t.jsxs(p,{className:"blog-card",onClick:a,children:[t.jsx("img",{src:n}),t.jsxs(w,{children:[t.jsx("div",{className:"text-wr-title",children:r}),t.jsx("div",{className:"text-wr",children:m}),o!==!0&&t.jsx(g,{type:"button",btnType:"outline",size:"medium",color:"gray",onClick:a,children:e})]}),o===!0&&t.jsx(g,{className:"action",type:"button",btnType:"outline",size:"medium",color:"gray",onClick:a,children:e})]})}),y=d.forwardRef((i,b)=>{const{items:r,onSelectCard:n=()=>{},limit:m=2}=i,a=h.useDetectMobile();return t.jsx(f,{limit:m,children:a===!0?r==null?void 0:r.map((e,o)=>t.jsx(u,{title:e==null?void 0:e.title,image:e==null?void 0:e.image,text:e==null?void 0:e.text,titleSlug:e==null?void 0:e.titleSlug,buttonText:e==null?void 0:e.buttonText,onCardClick:()=>n(e)},o)):r==null?void 0:r.slice(0,m).map((e,o)=>t.jsx(u,{title:e==null?void 0:e.title,image:e==null?void 0:e.image,text:e==null?void 0:e.text,titleSlug:e==null?void 0:e.titleSlug,buttonText:e==null?void 0:e.buttonText,onCardClick:()=>n(e)},o))})});module.exports=y;
101
+ `,y=s.forwardRef((i,a)=>{const{title:r,image:n,text:o,onCardClick:l,buttonText:m}=i,d=b.useDetectMobile();return t.jsxs(f,{className:"blog-card",onClick:l,children:[t.jsx("img",{src:n}),t.jsxs(j,{children:[t.jsx("div",{className:"text-wr-title",children:r}),t.jsx("div",{className:"text-wr",children:o}),d!==!0&&t.jsx(p,{type:"button",btnType:"outline",size:"medium",color:"gray",onClick:l,children:m})]}),d===!0&&t.jsx(p,{className:"action",type:"button",btnType:"outline",size:"medium",color:"gray",onClick:l,children:m})]})}),k=s.forwardRef(({},i)=>t.jsxs(f,{className:"blog-card",children:[t.jsx("div",{className:"skeleton-img"}),t.jsx(j,{children:t.jsx("div",{className:"skeleton-title"})})]})),S=({limit:i=2,isLoading:a=!1,keyPrefix:r})=>t.jsx(t.Fragment,{children:Array.from({length:i},(n,o)=>t.jsx(k,{isLoading:a},`${r}-skeleton-product-card-${o}`))}),v=({children:i,fallbackComponent:a=t.jsx(t.Fragment,{}),isLoading:r=!1,limit:n,keyPrefix:o})=>t.jsx(s.Suspense,{fallbackComponent:a,children:r===!0?t.jsx(S,{isLoading:r,limit:n,keyPrefix:o}):i}),w=s.memo(y),C=s.forwardRef((i,a)=>{const{items:r,onSelectCard:n=()=>{},limit:o=2,isLoading:l=!1}=i,m=b.useDetectMobile(),d=s.useMemo(()=>t.jsx(t.Fragment,{children:m===!0?r==null?void 0:r.map((e,c)=>t.jsx(w,{title:e==null?void 0:e.title,image:e==null?void 0:e.image,text:e==null?void 0:e.text,titleSlug:e==null?void 0:e.titleSlug,buttonText:e==null?void 0:e.buttonText,onCardClick:()=>n(e)},c)):r==null?void 0:r.slice(0,o).map((e,c)=>t.jsx(w,{title:e==null?void 0:e.title,image:e==null?void 0:e.image,text:e==null?void 0:e.text,titleSlug:e==null?void 0:e.titleSlug,buttonText:e==null?void 0:e.buttonText,onCardClick:()=>n(e)},c))}),[r,m,o,n]);return t.jsx(x,{ref:a,limit:o,children:t.jsx(v,{isLoading:l,limit:o,keyPrefix:"explore-landing",children:d})})});module.exports=C;
@@ -1,19 +1,19 @@
1
- import { jsxs as l, jsx as t } from "react/jsx-runtime";
2
- import { forwardRef as d } from "react";
3
- import { n as g } from "./emotion-styled.browser.esm-CjCaF13H.js";
4
- import { M as c } from "./consts-C1uHV4xc.js";
5
- import { u as h } from "./useDetectMobile-BC6EGaBc.js";
6
- import { m as u, t as k } from "./utils-DtRLzzTZ.js";
7
- import s from "./Button.js";
8
- const y = g.div`
1
+ import { jsxs as s, jsx as t, Fragment as g } from "react/jsx-runtime";
2
+ import { forwardRef as h, Suspense as C, memo as S, useMemo as $ } from "react";
3
+ import { n as p } from "./emotion-styled.browser.esm-CjCaF13H.js";
4
+ import { M as u } from "./consts-C1uHV4xc.js";
5
+ import { u as w } from "./useDetectMobile-BC6EGaBc.js";
6
+ import { m as k, t as T } from "./utils-DtRLzzTZ.js";
7
+ import f from "./Button.js";
8
+ const M = p.div`
9
9
  display: grid;
10
10
  grid-template-columns: ${(i) => `repeat(${i.limit}, minmax(0, 1fr))`};
11
11
  gap: 1.25rem;
12
12
 
13
- @media (max-width: ${c + "px"}) {
13
+ @media (max-width: ${u + "px"}) {
14
14
  grid-template-columns: repeat(1, 1fr);
15
15
  }
16
- `, b = g.div`
16
+ `, y = p.div`
17
17
  display: flex;
18
18
  width: 100%;
19
19
  gap: 1.25rem;
@@ -42,11 +42,11 @@ const y = g.div`
42
42
  min-height: 12.25rem;
43
43
  min-width: 11.25rem;
44
44
  max-width: 11.25rem;
45
- background-color: ${u("-90deg")};
45
+ background-color: ${k("-90deg")};
46
46
  border-radius: 0.75rem 0 0 0.75rem;
47
47
  }
48
48
 
49
- @media (max-width: ${c + "px"}) {
49
+ @media (max-width: ${u + "px"}) {
50
50
  padding: 1rem;
51
51
  column-gap: 1.5rem;
52
52
  row-gap: 1rem;
@@ -72,7 +72,7 @@ const y = g.div`
72
72
  margin-top: auto;
73
73
  }
74
74
  }
75
- `, w = g.div`
75
+ `, v = p.div`
76
76
  padding: 1rem;
77
77
  display: flex;
78
78
  flex-direction: column;
@@ -88,7 +88,7 @@ const y = g.div`
88
88
  font-weight: 400;
89
89
  font-size: 0.875rem;
90
90
  color: var(--gray-700, #4e555f);
91
- ${k(3)}
91
+ ${T(3)}
92
92
  }
93
93
 
94
94
  & button {
@@ -99,57 +99,75 @@ const y = g.div`
99
99
  & .skeleton-title {
100
100
  height: 1.75rem;
101
101
  width: 80%;
102
- background-color: ${u("-90deg")};
102
+ background-color: ${k("-90deg")};
103
103
  }
104
104
 
105
- @media (max-width: ${c + "px"}) {
105
+ @media (max-width: ${u + "px"}) {
106
106
  padding: 0;
107
107
  }
108
- `;
109
- d(({}, i) => /* @__PURE__ */ l(b, { className: "blog-card", children: [
110
- /* @__PURE__ */ t("div", { className: "skeleton-img" }),
111
- /* @__PURE__ */ t(w, { children: /* @__PURE__ */ t("div", { className: "skeleton-title" }) })
112
- ] }));
113
- const p = d((i, f) => {
114
- const { title: r, image: a, text: n, onCardClick: m, buttonText: e } = i, o = h();
115
- return (
116
- // <BlogCardLargeSkeleton />
117
- /* @__PURE__ */ l(b, { className: "blog-card", onClick: m, children: [
118
- /* @__PURE__ */ t("img", { src: a }),
119
- /* @__PURE__ */ l(w, { children: [
120
- /* @__PURE__ */ t("div", { className: "text-wr-title", children: r }),
121
- /* @__PURE__ */ t("div", { className: "text-wr", children: n }),
122
- o !== !0 && /* @__PURE__ */ t(
123
- s,
124
- {
125
- type: "button",
126
- btnType: "outline",
127
- size: "medium",
128
- color: "gray",
129
- onClick: m,
130
- children: e
131
- }
132
- )
133
- ] }),
134
- o === !0 && /* @__PURE__ */ t(
135
- s,
108
+ `, N = h((i, m) => {
109
+ const { title: r, image: a, text: o, onCardClick: n, buttonText: l } = i, d = w();
110
+ return /* @__PURE__ */ s(y, { className: "blog-card", onClick: n, children: [
111
+ /* @__PURE__ */ t("img", { src: a }),
112
+ /* @__PURE__ */ s(v, { children: [
113
+ /* @__PURE__ */ t("div", { className: "text-wr-title", children: r }),
114
+ /* @__PURE__ */ t("div", { className: "text-wr", children: o }),
115
+ d !== !0 && /* @__PURE__ */ t(
116
+ f,
136
117
  {
137
- className: "action",
138
118
  type: "button",
139
119
  btnType: "outline",
140
120
  size: "medium",
141
121
  color: "gray",
142
- onClick: m,
143
- children: e
122
+ onClick: n,
123
+ children: l
144
124
  }
145
125
  )
146
- ] })
147
- );
148
- }), z = d((i, f) => {
149
- const { items: r, onSelectCard: a = () => {
150
- }, limit: n = 2 } = i, m = h();
151
- return /* @__PURE__ */ t(y, { limit: n, children: m === !0 ? r == null ? void 0 : r.map((e, o) => /* @__PURE__ */ t(
152
- p,
126
+ ] }),
127
+ d === !0 && /* @__PURE__ */ t(
128
+ f,
129
+ {
130
+ className: "action",
131
+ type: "button",
132
+ btnType: "outline",
133
+ size: "medium",
134
+ color: "gray",
135
+ onClick: n,
136
+ children: l
137
+ }
138
+ )
139
+ ] });
140
+ }), z = h(({}, i) => /* @__PURE__ */ s(y, { className: "blog-card", children: [
141
+ /* @__PURE__ */ t("div", { className: "skeleton-img" }),
142
+ /* @__PURE__ */ t(v, { children: /* @__PURE__ */ t("div", { className: "skeleton-title" }) })
143
+ ] })), B = ({ limit: i = 2, isLoading: m = !1, keyPrefix: r }) => /* @__PURE__ */ t(g, { children: Array.from({ length: i }, (a, o) => /* @__PURE__ */ t(
144
+ z,
145
+ {
146
+ isLoading: m
147
+ },
148
+ `${r}-skeleton-product-card-${o}`
149
+ )) }), L = ({
150
+ children: i,
151
+ fallbackComponent: m = /* @__PURE__ */ t(g, {}),
152
+ isLoading: r = !1,
153
+ limit: a,
154
+ keyPrefix: o
155
+ }) => /* @__PURE__ */ t(C, { fallbackComponent: m, children: r === !0 ? /* @__PURE__ */ t(
156
+ B,
157
+ {
158
+ isLoading: r,
159
+ limit: a,
160
+ keyPrefix: o
161
+ }
162
+ ) : i }), b = S(N), G = h((i, m) => {
163
+ const {
164
+ items: r,
165
+ onSelectCard: a = () => {
166
+ },
167
+ limit: o = 2,
168
+ isLoading: n = !1
169
+ } = i, l = w(), d = $(() => /* @__PURE__ */ t(g, { children: l === !0 ? r == null ? void 0 : r.map((e, c) => /* @__PURE__ */ t(
170
+ b,
153
171
  {
154
172
  title: e == null ? void 0 : e.title,
155
173
  image: e == null ? void 0 : e.image,
@@ -158,9 +176,9 @@ const p = d((i, f) => {
158
176
  buttonText: e == null ? void 0 : e.buttonText,
159
177
  onCardClick: () => a(e)
160
178
  },
161
- o
162
- )) : r == null ? void 0 : r.slice(0, n).map((e, o) => /* @__PURE__ */ t(
163
- p,
179
+ c
180
+ )) : r == null ? void 0 : r.slice(0, o).map((e, c) => /* @__PURE__ */ t(
181
+ b,
164
182
  {
165
183
  title: e == null ? void 0 : e.title,
166
184
  image: e == null ? void 0 : e.image,
@@ -169,9 +187,18 @@ const p = d((i, f) => {
169
187
  buttonText: e == null ? void 0 : e.buttonText,
170
188
  onCardClick: () => a(e)
171
189
  },
172
- o
173
- )) });
190
+ c
191
+ )) }), [r, l, o, a]);
192
+ return /* @__PURE__ */ t(M, { ref: m, limit: o, children: /* @__PURE__ */ t(
193
+ L,
194
+ {
195
+ isLoading: n,
196
+ limit: o,
197
+ keyPrefix: "explore-landing",
198
+ children: d
199
+ }
200
+ ) });
174
201
  });
175
202
  export {
176
- z as default
203
+ G as default
177
204
  };
@@ -1,12 +1,12 @@
1
- "use strict";const t=require("react/jsx-runtime"),m=require("react"),g=require("./emotion-styled.browser.esm-Cle7tAM9.cjs"),h=require("./consts-CtNoHdBj.cjs"),y=require("./useDetectMobile-D6d5LpdL.cjs"),l=require("./utils-NZLCh-J5.cjs"),S=require("./style-BR3tIhP1.cjs"),k=require("./Button.cjs"),x=require("./Link.cjs"),N=g.newStyled.div`
1
+ "use strict";const t=require("react/jsx-runtime"),a=require("react"),p=require("./emotion-styled.browser.esm-Cle7tAM9.cjs"),f=require("./consts-CtNoHdBj.cjs"),v=require("./useDetectMobile-D6d5LpdL.cjs"),m=require("./utils-NZLCh-J5.cjs"),k=require("./style-DN1qT8BE.cjs"),C=require("./Button.cjs"),N=require("./Link.cjs"),q=p.newStyled.div`
2
2
  display: grid;
3
3
  grid-template-columns: ${r=>`repeat(${r.limit}, minmax(0, 1fr))`};
4
4
  gap: 1.25rem;
5
5
 
6
- @media (max-width: ${h.MOBILE_SIZE_PX+"px"}) {
6
+ @media (max-width: ${f.MOBILE_SIZE_PX+"px"}) {
7
7
  grid-template-columns: repeat(1, 1fr);
8
8
  }
9
- `,f=g.newStyled.div`
9
+ `,j=p.newStyled.div`
10
10
  display: flex;
11
11
  flex-direction: column;
12
12
  width: 100%;
@@ -38,7 +38,7 @@
38
38
  width: 100%;
39
39
  max-height: 12.5625rem;
40
40
  min-height: 12.5625rem;
41
- background-color: ${l.linearGradientAnimation("-90deg")};
41
+ background-color: ${m.linearGradientAnimation("-90deg")};
42
42
  }
43
43
 
44
44
  & .action {
@@ -46,9 +46,9 @@
46
46
  margin-top: auto;
47
47
  }
48
48
 
49
- @media (max-width: ${h.MOBILE_SIZE_PX+"px"}) {
49
+ @media (max-width: ${f.MOBILE_SIZE_PX+"px"}) {
50
50
  }
51
- `,w=g.newStyled.div`
51
+ `,w=p.newStyled.div`
52
52
  padding: 1rem 1rem 0 1rem;
53
53
  display: flex;
54
54
  flex-direction: column;
@@ -66,6 +66,6 @@
66
66
  font-size: 0.875rem;
67
67
  flex: 1;
68
68
  color: var(--gray-700, #4e555f);
69
- ${l.truncateTextInRows(3)}
69
+ ${m.truncateTextInRows(3)}
70
70
  }
71
- `;m.forwardRef(({},r)=>t.jsxs(f,{className:"product-card",children:[t.jsx("div",{className:"skeleton-img"}),t.jsx("div",{className:"card-title"}),t.jsx(w,{})]}));const p=m.forwardRef((r,j)=>{const{title:a,image:s,text:c,onCardClick:o,readMoreText:n="Read more"}=r;return t.jsxs(f,{className:"blog-card",onClick:o,children:[t.jsx("img",{src:s}),t.jsxs(w,{children:[t.jsx("div",{className:"text-wr-title",children:a}),t.jsx("div",{className:"text-wr",children:c})]}),t.jsx(x,{className:"action",color:"gray",onClick:o,children:n})]})}),C=m.forwardRef((r,j)=>{const{icon:a,title:s,onButtonAction:c=()=>{},onSelectCard:o=()=>{},buttonLink:n,items:i,buttonText:b,limit:u=3}=r,v=y.useDetectMobile();return t.jsxs(S.RegulatTitleSectionWrapper,{children:[t.jsxs("div",{className:"regular-title",children:[t.jsxs("div",{className:"regular-title-text",children:[l.isDefinedNotEmptyString(a)&&t.jsx("i",{className:a}),t.jsx("span",{children:s})]}),l.isDefinedNotEmptyString(n)&&t.jsx(k,{type:"button",btnType:"tinted",color:"gray",onClick:()=>c(n),borderRadius:"curved",children:b})]}),t.jsx(N,{limit:u,children:v===!0?i==null?void 0:i.map((e,d)=>t.jsx(p,{title:e==null?void 0:e.title,image:e==null?void 0:e.image,text:e==null?void 0:e.text,titleSlug:e==null?void 0:e.titleSlug,onCardClick:()=>o(e==null?void 0:e.uuid)},d)):i==null?void 0:i.slice(0,u).map((e,d)=>t.jsx(p,{title:e==null?void 0:e.title,image:e==null?void 0:e.image,text:e==null?void 0:e.text,titleSlug:e==null?void 0:e.titleSlug,onCardClick:()=>o(e==null?void 0:e.uuid)},d))})]})});module.exports=C;
71
+ `,R=a.forwardRef(({},r)=>t.jsxs(j,{className:"product-card",children:[t.jsx("div",{className:"skeleton-img"}),t.jsx("div",{className:"card-title"}),t.jsx(w,{})]})),B=a.forwardRef((r,s)=>{const{title:i,image:l,text:o,onCardClick:c,readMoreText:d="Read more"}=r;return t.jsxs(j,{className:"blog-card",onClick:c,children:[t.jsx("img",{src:l}),t.jsxs(w,{children:[t.jsx("div",{className:"text-wr-title",children:i}),t.jsx("div",{className:"text-wr",children:o})]}),t.jsx(N,{className:"action",color:"gray",onClick:c,children:d})]})}),M=({limit:r=3,isLoading:s=!1,keyPrefix:i})=>t.jsx(t.Fragment,{children:Array.from({length:r},(l,o)=>t.jsx(R,{isLoading:s},`${i}-skeleton-product-card-${o}`))}),$=({children:r,fallbackComponent:s=t.jsx(t.Fragment,{}),isLoading:i=!1,limit:l,keyPrefix:o})=>t.jsx(a.Suspense,{fallbackComponent:s,children:i===!0?t.jsx(M,{isLoading:i,limit:l,keyPrefix:o}):r}),h=a.memo(B),_=a.forwardRef((r,s)=>{const{icon:i,title:l,onButtonAction:o=()=>{},onSelectCard:c=()=>{},buttonLink:d,items:n,buttonText:S,limit:u=3,isLoading:x=!1}=r,y=v.useDetectMobile(),b=a.useMemo(()=>t.jsx(t.Fragment,{children:y===!0?n==null?void 0:n.map((e,g)=>t.jsx(h,{title:e==null?void 0:e.title,image:e==null?void 0:e.image,text:e==null?void 0:e.text,titleSlug:e==null?void 0:e.titleSlug,onCardClick:()=>c(e==null?void 0:e.uuid)},g)):n==null?void 0:n.slice(0,u).map((e,g)=>t.jsx(h,{title:e==null?void 0:e.title,image:e==null?void 0:e.image,text:e==null?void 0:e.text,titleSlug:e==null?void 0:e.titleSlug,onCardClick:()=>c(e==null?void 0:e.uuid)},g))}),[n]);return t.jsxs(k.RegulatTitleSectionWrapper,{ref:s,children:[t.jsxs("div",{className:"regular-title",children:[t.jsxs("div",{className:"regular-title-text",children:[m.isDefinedNotEmptyString(i)&&t.jsx("i",{className:i}),t.jsx("span",{children:l})]}),m.isDefinedNotEmptyString(d)&&t.jsx(C,{type:"button",btnType:"tinted",color:"gray",onClick:()=>o(d),borderRadius:"curved",children:S})]}),t.jsx(q,{limit:u,children:t.jsx($,{isLoading:x,limit:u,keyPrefix:"explore-landing",children:b})})]})});module.exports=_;