@lanaco/lnc-react-ui 4.0.38 → 4.0.39

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 (30) hide show
  1. package/dist/BlogsSectionDetailed.cjs +11 -11
  2. package/dist/BlogsSectionDetailed.js +124 -87
  3. package/dist/BlogsSectionLarge.cjs +10 -10
  4. package/dist/BlogsSectionLarge.js +87 -60
  5. package/dist/BlogsSectionSimple.cjs +8 -8
  6. package/dist/BlogsSectionSimple.js +98 -72
  7. package/dist/BlogsSectionSimpleCentered.cjs +9 -9
  8. package/dist/BlogsSectionSimpleCentered.js +75 -45
  9. package/dist/BlogsSectionWithFilters.cjs +10 -10
  10. package/dist/BlogsSectionWithFilters.js +105 -77
  11. package/dist/DetailedProductsSection.cjs +4 -4
  12. package/dist/DetailedProductsSection.js +66 -57
  13. package/dist/FieldOfInterestsWithAvatarsCardsSection.cjs +1 -1
  14. package/dist/FieldOfInterestsWithAvatarsCardsSection.js +1 -1
  15. package/dist/OverlayGeneralCardsSection.cjs +20 -20
  16. package/dist/OverlayGeneralCardsSection.js +99 -59
  17. package/dist/ProductsWithBannerSection.cjs +10 -10
  18. package/dist/ProductsWithBannerSection.js +87 -56
  19. package/dist/SimpleCategoriesSection.cjs +9 -9
  20. package/dist/SimpleCategoriesSection.js +89 -58
  21. package/dist/SimpleProductsSection.cjs +3 -3
  22. package/dist/SimpleProductsSection.js +86 -55
  23. package/dist/UrgentSaleProductsSection.cjs +5 -5
  24. package/dist/UrgentSaleProductsSection.js +41 -30
  25. package/dist/{index-CHkb_Sj6.js → index-BN8qgFbe.js} +15 -15
  26. package/dist/{index-Dj5wZCVs.cjs → index-_Db92CJE.cjs} +3 -3
  27. package/dist/suspense-product-card-detailed-BETmfKMT.js +189 -0
  28. package/dist/{index-vXmvgZ2Y.cjs → suspense-product-card-detailed-DtzOxHaH.cjs} +4 -4
  29. package/package.json +1 -1
  30. package/dist/index-D6g5ZqyJ.js +0 -159
@@ -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"),l=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-BR3tIhP1.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=l.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=l.forwardRef((r,a)=>{const{title:i,image:s,text:o,onCardClick:c,readMoreText:d="Read more"}=r;return t.jsxs(j,{className:"blog-card",onClick:c,children:[t.jsx("img",{src:s}),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:a=!1,keyPrefix:i})=>t.jsx(t.Fragment,{children:Array.from({length:r},(s,o)=>t.jsx(R,{isLoading:a},`${i}-skeleton-product-card-${o}`))}),$=({children:r,fallbackComponent:a=t.jsx(t.Fragment,{}),isLoading:i=!1,limit:s,keyPrefix:o})=>t.jsx(l.Suspense,{fallbackComponent:a,children:i===!0?t.jsx(M,{isLoading:i,limit:s,keyPrefix:o}):r}),h=l.memo(B),_=l.forwardRef((r,a)=>{const{icon:i,title:s,onButtonAction:o=()=>{},onSelectCard:c=()=>{},buttonLink:d,items:n,buttonText:S,limit:u=3,isLoading:x=!1}=r,y=v.useDetectMobile(),b=l.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,{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:s})]}),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=_;
@@ -1,21 +1,21 @@
1
- import { jsxs as a, jsx as t } from "react/jsx-runtime";
2
- import { forwardRef as s } from "react";
3
- import { n as p } from "./emotion-styled.browser.esm-CjCaF13H.js";
4
- import { M as f } from "./consts-C1uHV4xc.js";
5
- import { u as S } from "./useDetectMobile-BC6EGaBc.js";
6
- import { m as C, t as N, k as u } from "./utils-DtRLzzTZ.js";
7
- import { R } from "./style-6tSw9aqK.js";
8
- import T from "./Button.js";
9
- import $ from "./Link.js";
10
- const B = p.div`
1
+ import { jsxs as n, jsx as r, Fragment as g } from "react/jsx-runtime";
2
+ import { forwardRef as u, Suspense as $, memo as B, useMemo as M } from "react";
3
+ import { n as h } from "./emotion-styled.browser.esm-CjCaF13H.js";
4
+ import { M as b } from "./consts-C1uHV4xc.js";
5
+ import { u as R } from "./useDetectMobile-BC6EGaBc.js";
6
+ import { m as T, t as P, k as f } from "./utils-DtRLzzTZ.js";
7
+ import { R as z } from "./style-6tSw9aqK.js";
8
+ import W from "./Button.js";
9
+ import j from "./Link.js";
10
+ const A = h.div`
11
11
  display: grid;
12
- grid-template-columns: ${(r) => `repeat(${r.limit}, minmax(0, 1fr))`};
12
+ grid-template-columns: ${(t) => `repeat(${t.limit}, minmax(0, 1fr))`};
13
13
  gap: 1.25rem;
14
14
 
15
- @media (max-width: ${f + "px"}) {
15
+ @media (max-width: ${b + "px"}) {
16
16
  grid-template-columns: repeat(1, 1fr);
17
17
  }
18
- `, v = p.div`
18
+ `, w = h.div`
19
19
  display: flex;
20
20
  flex-direction: column;
21
21
  width: 100%;
@@ -47,7 +47,7 @@ const B = p.div`
47
47
  width: 100%;
48
48
  max-height: 12.5625rem;
49
49
  min-height: 12.5625rem;
50
- background-color: ${C("-90deg")};
50
+ background-color: ${T("-90deg")};
51
51
  }
52
52
 
53
53
  & .action {
@@ -55,9 +55,9 @@ const B = p.div`
55
55
  margin-top: auto;
56
56
  }
57
57
 
58
- @media (max-width: ${f + "px"}) {
58
+ @media (max-width: ${b + "px"}) {
59
59
  }
60
- `, b = p.div`
60
+ `, S = h.div`
61
61
  padding: 1rem 1rem 0 1rem;
62
62
  display: flex;
63
63
  flex-direction: column;
@@ -75,84 +75,110 @@ const B = p.div`
75
75
  font-size: 0.875rem;
76
76
  flex: 1;
77
77
  color: var(--gray-700, #4e555f);
78
- ${N(3)}
78
+ ${P(3)}
79
79
  }
80
- `;
81
- s(({}, r) => (
80
+ `, E = u(({}, t) => (
82
81
  // <LandingPageClearProductCardSkeleton />
83
- /* @__PURE__ */ a(v, { className: "product-card", children: [
84
- /* @__PURE__ */ t("div", { className: "skeleton-img" }),
85
- /* @__PURE__ */ t("div", { className: "card-title" }),
86
- /* @__PURE__ */ t(b, {})
82
+ /* @__PURE__ */ n(w, { className: "product-card", children: [
83
+ /* @__PURE__ */ r("div", { className: "skeleton-img" }),
84
+ /* @__PURE__ */ r("div", { className: "card-title" }),
85
+ /* @__PURE__ */ r(S, {})
87
86
  ] })
88
- ));
89
- const h = s((r, w) => {
90
- const { title: l, image: m, text: d, onCardClick: o, readMoreText: n = "Read more" } = r;
87
+ )), I = u((t, m) => {
88
+ const { title: i, image: l, text: o, onCardClick: d, readMoreText: c = "Read more" } = t;
91
89
  return (
92
90
  // <SimpleBlogCardSkeleton />
93
- /* @__PURE__ */ a(v, { className: "blog-card", onClick: o, children: [
94
- /* @__PURE__ */ t("img", { src: m }),
95
- /* @__PURE__ */ a(b, { children: [
96
- /* @__PURE__ */ t("div", { className: "text-wr-title", children: l }),
97
- /* @__PURE__ */ t("div", { className: "text-wr", children: d })
91
+ /* @__PURE__ */ n(w, { className: "blog-card", onClick: d, children: [
92
+ /* @__PURE__ */ r("img", { src: l }),
93
+ /* @__PURE__ */ n(S, { children: [
94
+ /* @__PURE__ */ r("div", { className: "text-wr-title", children: i }),
95
+ /* @__PURE__ */ r("div", { className: "text-wr", children: o })
98
96
  ] }),
99
- /* @__PURE__ */ t($, { className: "action", color: "gray", onClick: o, children: n })
97
+ /* @__PURE__ */ r(j, { className: "action", color: "gray", onClick: d, children: c })
100
98
  ] })
101
99
  );
102
- }), G = s((r, w) => {
100
+ }), L = ({ limit: t = 3, isLoading: m = !1, keyPrefix: i }) => /* @__PURE__ */ r(g, { children: Array.from({ length: t }, (l, o) => /* @__PURE__ */ r(
101
+ E,
102
+ {
103
+ isLoading: m
104
+ },
105
+ `${i}-skeleton-product-card-${o}`
106
+ )) }), _ = ({
107
+ children: t,
108
+ fallbackComponent: m = /* @__PURE__ */ r(g, {}),
109
+ isLoading: i = !1,
110
+ limit: l,
111
+ keyPrefix: o
112
+ }) => /* @__PURE__ */ r($, { fallbackComponent: m, children: i === !0 ? /* @__PURE__ */ r(
113
+ L,
114
+ {
115
+ isLoading: i,
116
+ limit: l,
117
+ keyPrefix: o
118
+ }
119
+ ) : t }), v = B(I), K = u((t, m) => {
103
120
  const {
104
- icon: l,
105
- title: m,
106
- onButtonAction: d = () => {
121
+ icon: i,
122
+ title: l,
123
+ onButtonAction: o = () => {
124
+ },
125
+ onSelectCard: d = () => {
107
126
  },
108
- onSelectCard: o = () => {
127
+ buttonLink: c,
128
+ items: a,
129
+ buttonText: k,
130
+ limit: s = 3,
131
+ isLoading: y = !1
132
+ } = t, C = R(), N = M(() => /* @__PURE__ */ r(g, { children: C === !0 ? a == null ? void 0 : a.map((e, p) => /* @__PURE__ */ r(
133
+ v,
134
+ {
135
+ title: e == null ? void 0 : e.title,
136
+ image: e == null ? void 0 : e.image,
137
+ text: e == null ? void 0 : e.text,
138
+ titleSlug: e == null ? void 0 : e.titleSlug,
139
+ onCardClick: () => d(e == null ? void 0 : e.uuid)
109
140
  },
110
- buttonLink: n,
111
- items: i,
112
- buttonText: y,
113
- limit: g = 3
114
- } = r, k = S();
115
- return /* @__PURE__ */ a(R, { children: [
116
- /* @__PURE__ */ a("div", { className: "regular-title", children: [
117
- /* @__PURE__ */ a("div", { className: "regular-title-text", children: [
118
- u(l) && /* @__PURE__ */ t("i", { className: l }),
119
- /* @__PURE__ */ t("span", { children: m })
141
+ p
142
+ )) : a == null ? void 0 : a.slice(0, s).map((e, p) => /* @__PURE__ */ r(
143
+ v,
144
+ {
145
+ title: e == null ? void 0 : e.title,
146
+ image: e == null ? void 0 : e.image,
147
+ text: e == null ? void 0 : e.text,
148
+ titleSlug: e == null ? void 0 : e.titleSlug,
149
+ onCardClick: () => d(e == null ? void 0 : e.uuid)
150
+ },
151
+ p
152
+ )) }), [a]);
153
+ return /* @__PURE__ */ n(z, { children: [
154
+ /* @__PURE__ */ n("div", { className: "regular-title", children: [
155
+ /* @__PURE__ */ n("div", { className: "regular-title-text", children: [
156
+ f(i) && /* @__PURE__ */ r("i", { className: i }),
157
+ /* @__PURE__ */ r("span", { children: l })
120
158
  ] }),
121
- u(n) && /* @__PURE__ */ t(
122
- T,
159
+ f(c) && /* @__PURE__ */ r(
160
+ W,
123
161
  {
124
162
  type: "button",
125
163
  btnType: "tinted",
126
164
  color: "gray",
127
- onClick: () => d(n),
165
+ onClick: () => o(c),
128
166
  borderRadius: "curved",
129
- children: y
167
+ children: k
130
168
  }
131
169
  )
132
170
  ] }),
133
- /* @__PURE__ */ t(B, { limit: g, children: k === !0 ? i == null ? void 0 : i.map((e, c) => /* @__PURE__ */ t(
134
- h,
135
- {
136
- title: e == null ? void 0 : e.title,
137
- image: e == null ? void 0 : e.image,
138
- text: e == null ? void 0 : e.text,
139
- titleSlug: e == null ? void 0 : e.titleSlug,
140
- onCardClick: () => o(e == null ? void 0 : e.uuid)
141
- },
142
- c
143
- )) : i == null ? void 0 : i.slice(0, g).map((e, c) => /* @__PURE__ */ t(
144
- h,
171
+ /* @__PURE__ */ r(A, { limit: s, children: /* @__PURE__ */ r(
172
+ _,
145
173
  {
146
- title: e == null ? void 0 : e.title,
147
- image: e == null ? void 0 : e.image,
148
- text: e == null ? void 0 : e.text,
149
- titleSlug: e == null ? void 0 : e.titleSlug,
150
- onCardClick: () => o(e == null ? void 0 : e.uuid)
151
- },
152
- c
153
- )) })
174
+ isLoading: y,
175
+ limit: s,
176
+ keyPrefix: "explore-landing",
177
+ children: N
178
+ }
179
+ ) })
154
180
  ] });
155
181
  });
156
182
  export {
157
- G as default
183
+ K as default
158
184
  };
@@ -1,13 +1,13 @@
1
- "use strict";const t=require("react/jsx-runtime"),s=require("react"),m=require("./emotion-styled.browser.esm-Cle7tAM9.cjs"),g=require("./consts-CtNoHdBj.cjs"),w=require("./useDetectMobile-D6d5LpdL.cjs"),d=require("./utils-NZLCh-J5.cjs"),b=require("./Button.cjs"),f=m.newStyled.div`
1
+ "use strict";const t=require("react/jsx-runtime"),a=require("react"),u=require("./emotion-styled.browser.esm-Cle7tAM9.cjs"),h=require("./consts-CtNoHdBj.cjs"),b=require("./useDetectMobile-D6d5LpdL.cjs"),c=require("./utils-NZLCh-J5.cjs"),j=require("./Button.cjs"),S=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
  margin: auto;
6
6
 
7
- @media (max-width: ${g.MOBILE_SIZE_PX+"px"}) {
7
+ @media (max-width: ${h.MOBILE_SIZE_PX+"px"}) {
8
8
  grid-template-columns: repeat(1, 1fr);
9
9
  }
10
- `,h=m.newStyled.div`
10
+ `,p=u.newStyled.div`
11
11
  display: flex;
12
12
  flex-direction: column;
13
13
  width: 100%;
@@ -44,13 +44,13 @@
44
44
  min-height: 6rem;
45
45
  max-height: 6rem;
46
46
  border-radius: 0.75rem;
47
- background-color: ${d.linearGradientAnimation("-90deg")};
47
+ background-color: ${c.linearGradientAnimation("-90deg")};
48
48
  }
49
49
 
50
- @media (max-width: ${g.MOBILE_SIZE_PX+"px"}) {
50
+ @media (max-width: ${h.MOBILE_SIZE_PX+"px"}) {
51
51
  max-width: unset;
52
52
  }
53
- `,p=m.newStyled.div`
53
+ `,f=u.newStyled.div`
54
54
  text-align: center;
55
55
  display: flex;
56
56
  flex-direction: column;
@@ -65,7 +65,7 @@
65
65
  & .skeleton-title {
66
66
  height: 1.75rem;
67
67
  width: 80%;
68
- background-color: ${d.linearGradientAnimation("-90deg")};
68
+ background-color: ${c.linearGradientAnimation("-90deg")};
69
69
  }
70
70
 
71
71
  & .text-wr {
@@ -73,6 +73,6 @@
73
73
  font-size: 0.875rem;
74
74
  flex: 1;
75
75
  color: var(--gray-700, #4e555f);
76
- ${d.truncateTextInRows(3)}
76
+ ${c.truncateTextInRows(3)}
77
77
  }
78
- `;s.forwardRef((i,c)=>{const{onCardClick:r}=i;return t.jsxs(h,{className:"product-card",onClick:r,children:[t.jsx("div",{"skeleton-img":!0}),t.jsx(p,{children:t.jsx("div",{className:"skeleton-title"})})]})});const u=s.forwardRef((i,c)=>{const{title:r,image:n,text:o,buttonText:a,onCardClick:e}=i;return t.jsxs(h,{className:"blog-card",onClick:e,children:[t.jsx("img",{src:n}),t.jsxs(p,{children:[t.jsx("div",{className:"text-wr-title",children:r}),t.jsx("div",{className:"text-wr",children:o})]}),t.jsx(b,{borderRadius:"curved",color:"gray",type:"button",btnType:"outline",onClick:e,size:"medium",children:a})]})}),j=s.forwardRef((i,c)=>{const{items:r,limit:n=3,onSelectCard:o=()=>{}}=i,a=w.useDetectMobile();return t.jsx(f,{limit:n,children:a===!0?r==null?void 0:r.map((e,l)=>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:()=>o(e==null?void 0:e.uuid)},l)):r==null?void 0:r.slice(0,n).map((e,l)=>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:()=>o(e==null?void 0:e.uuid)},l))})});module.exports=j;
78
+ `,C=a.forwardRef((i,l)=>{const{onCardClick:r}=i;return t.jsxs(p,{className:"product-card",onClick:r,children:[t.jsx("div",{"skeleton-img":!0}),t.jsx(f,{children:t.jsx("div",{className:"skeleton-title"})})]})}),k=a.forwardRef((i,l)=>{const{title:r,image:n,text:o,buttonText:d,onCardClick:s}=i;return t.jsxs(p,{className:"blog-card",onClick:s,children:[t.jsx("img",{src:n}),t.jsxs(f,{children:[t.jsx("div",{className:"text-wr-title",children:r}),t.jsx("div",{className:"text-wr",children:o})]}),t.jsx(j,{borderRadius:"curved",color:"gray",type:"button",btnType:"outline",onClick:s,size:"medium",children:d})]})}),y=({limit:i=3,isLoading:l=!1,keyPrefix:r})=>t.jsx(t.Fragment,{children:Array.from({length:i},(n,o)=>t.jsx(C,{isLoading:l},`${r}-skeleton-product-card-${o}`))}),v=({children:i,fallbackComponent:l=t.jsx(t.Fragment,{}),isLoading:r=!1,limit:n,keyPrefix:o})=>t.jsx(a.Suspense,{fallbackComponent:l,children:r===!0?t.jsx(y,{isLoading:r,limit:n,keyPrefix:o}):i}),g=a.memo(k),x=a.forwardRef((i,l)=>{const{items:r,limit:n=3,onSelectCard:o=()=>{},isLoading:d=!1}=i,s=b.useDetectMobile(),w=a.useMemo(()=>t.jsx(t.Fragment,{children:s===!0?r==null?void 0:r.map((e,m)=>t.jsx(g,{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:()=>o(e==null?void 0:e.uuid)},m)):r==null?void 0:r.slice(0,n).map((e,m)=>t.jsx(g,{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:()=>o(e==null?void 0:e.uuid)},m))}),[r]);return t.jsx(S,{limit:n,children:t.jsx(v,{isLoading:d,limit:n,keyPrefix:"explore-landing",children:w})})});module.exports=x;
@@ -1,20 +1,20 @@
1
- import { jsxs as l, jsx as r } from "react/jsx-runtime";
2
- import { forwardRef as d } from "react";
3
- import { n as c } from "./emotion-styled.browser.esm-CjCaF13H.js";
4
- import { M as p } from "./consts-C1uHV4xc.js";
5
- import { u as b } from "./useDetectMobile-BC6EGaBc.js";
6
- import { m as u, t as w } from "./utils-DtRLzzTZ.js";
7
- import C from "./Button.js";
8
- const k = c.div`
1
+ import { jsxs as c, jsx as t, Fragment as s } from "react/jsx-runtime";
2
+ import { forwardRef as u, Suspense as k, memo as S, useMemo as v } from "react";
3
+ import { n as g } from "./emotion-styled.browser.esm-CjCaF13H.js";
4
+ import { M as h } from "./consts-C1uHV4xc.js";
5
+ import { u as y } from "./useDetectMobile-BC6EGaBc.js";
6
+ import { m as f, t as $ } from "./utils-DtRLzzTZ.js";
7
+ import T from "./Button.js";
8
+ const B = g.div`
9
9
  display: grid;
10
10
  grid-template-columns: ${(i) => `repeat(${i.limit}, minmax(0, 1fr))`};
11
11
  gap: 1.25rem;
12
12
  margin: auto;
13
13
 
14
- @media (max-width: ${p + "px"}) {
14
+ @media (max-width: ${h + "px"}) {
15
15
  grid-template-columns: repeat(1, 1fr);
16
16
  }
17
- `, h = c.div`
17
+ `, b = g.div`
18
18
  display: flex;
19
19
  flex-direction: column;
20
20
  width: 100%;
@@ -51,13 +51,13 @@ const k = c.div`
51
51
  min-height: 6rem;
52
52
  max-height: 6rem;
53
53
  border-radius: 0.75rem;
54
- background-color: ${u("-90deg")};
54
+ background-color: ${f("-90deg")};
55
55
  }
56
56
 
57
- @media (max-width: ${p + "px"}) {
57
+ @media (max-width: ${h + "px"}) {
58
58
  max-width: unset;
59
59
  }
60
- `, f = c.div`
60
+ `, w = g.div`
61
61
  text-align: center;
62
62
  display: flex;
63
63
  flex-direction: column;
@@ -72,7 +72,7 @@ const k = c.div`
72
72
  & .skeleton-title {
73
73
  height: 1.75rem;
74
74
  width: 80%;
75
- background-color: ${u("-90deg")};
75
+ background-color: ${f("-90deg")};
76
76
  }
77
77
 
78
78
  & .text-wr {
@@ -80,70 +80,100 @@ const k = c.div`
80
80
  font-size: 0.875rem;
81
81
  flex: 1;
82
82
  color: var(--gray-700, #4e555f);
83
- ${w(3)}
83
+ ${$(3)}
84
84
  }
85
- `;
86
- d((i, s) => {
87
- const { onCardClick: t } = i;
85
+ `, M = u((i, a) => {
86
+ const { onCardClick: r } = i;
88
87
  return (
89
88
  // <SimpleBlogCardSkeleton />
90
- /* @__PURE__ */ l(h, { className: "product-card", onClick: t, children: [
91
- /* @__PURE__ */ r("div", { "skeleton-img": !0 }),
92
- /* @__PURE__ */ r(f, { children: /* @__PURE__ */ r("div", { className: "skeleton-title" }) })
89
+ /* @__PURE__ */ c(b, { className: "product-card", onClick: r, children: [
90
+ /* @__PURE__ */ t("div", { "skeleton-img": !0 }),
91
+ /* @__PURE__ */ t(w, { children: /* @__PURE__ */ t("div", { className: "skeleton-title" }) })
93
92
  ] })
94
93
  );
95
- });
96
- const g = d((i, s) => {
97
- const { title: t, image: o, text: a, buttonText: m, onCardClick: e } = i;
94
+ }), z = u((i, a) => {
95
+ const { title: r, image: o, text: n, buttonText: m, onCardClick: l } = i;
98
96
  return (
99
97
  // <SimpleBlogCardCenteredSkeleton />
100
- /* @__PURE__ */ l(h, { className: "blog-card", onClick: e, children: [
101
- /* @__PURE__ */ r("img", { src: o }),
102
- /* @__PURE__ */ l(f, { children: [
103
- /* @__PURE__ */ r("div", { className: "text-wr-title", children: t }),
104
- /* @__PURE__ */ r("div", { className: "text-wr", children: a })
98
+ /* @__PURE__ */ c(b, { className: "blog-card", onClick: l, children: [
99
+ /* @__PURE__ */ t("img", { src: o }),
100
+ /* @__PURE__ */ c(w, { children: [
101
+ /* @__PURE__ */ t("div", { className: "text-wr-title", children: r }),
102
+ /* @__PURE__ */ t("div", { className: "text-wr", children: n })
105
103
  ] }),
106
- /* @__PURE__ */ r(
107
- C,
104
+ /* @__PURE__ */ t(
105
+ T,
108
106
  {
109
107
  borderRadius: "curved",
110
108
  color: "gray",
111
109
  type: "button",
112
110
  btnType: "outline",
113
- onClick: e,
111
+ onClick: l,
114
112
  size: "medium",
115
113
  children: m
116
114
  }
117
115
  )
118
116
  ] })
119
117
  );
120
- }), M = d((i, s) => {
121
- const { items: t, limit: o = 3, onSelectCard: a = () => {
122
- } } = i, m = b();
123
- return /* @__PURE__ */ r(k, { limit: o, children: m === !0 ? t == null ? void 0 : t.map((e, n) => /* @__PURE__ */ r(
124
- g,
118
+ }), N = ({ limit: i = 3, isLoading: a = !1, keyPrefix: r }) => /* @__PURE__ */ t(s, { children: Array.from({ length: i }, (o, n) => /* @__PURE__ */ t(
119
+ M,
120
+ {
121
+ isLoading: a
122
+ },
123
+ `${r}-skeleton-product-card-${n}`
124
+ )) }), P = ({
125
+ children: i,
126
+ fallbackComponent: a = /* @__PURE__ */ t(s, {}),
127
+ isLoading: r = !1,
128
+ limit: o,
129
+ keyPrefix: n
130
+ }) => /* @__PURE__ */ t(k, { fallbackComponent: a, children: r === !0 ? /* @__PURE__ */ t(
131
+ N,
132
+ {
133
+ isLoading: r,
134
+ limit: o,
135
+ keyPrefix: n
136
+ }
137
+ ) : i }), p = S(z), G = u((i, a) => {
138
+ const {
139
+ items: r,
140
+ limit: o = 3,
141
+ onSelectCard: n = () => {
142
+ },
143
+ isLoading: m = !1
144
+ } = i, l = y(), C = v(() => /* @__PURE__ */ t(s, { children: l === !0 ? r == null ? void 0 : r.map((e, d) => /* @__PURE__ */ t(
145
+ p,
125
146
  {
126
147
  title: e == null ? void 0 : e.title,
127
148
  image: e == null ? void 0 : e.image,
128
149
  text: e == null ? void 0 : e.text,
129
150
  titleSlug: e == null ? void 0 : e.titleSlug,
130
151
  buttonText: e == null ? void 0 : e.buttonText,
131
- onCardClick: () => a(e == null ? void 0 : e.uuid)
152
+ onCardClick: () => n(e == null ? void 0 : e.uuid)
132
153
  },
133
- n
134
- )) : t == null ? void 0 : t.slice(0, o).map((e, n) => /* @__PURE__ */ r(
135
- g,
154
+ d
155
+ )) : r == null ? void 0 : r.slice(0, o).map((e, d) => /* @__PURE__ */ t(
156
+ p,
136
157
  {
137
158
  title: e == null ? void 0 : e.title,
138
159
  image: e == null ? void 0 : e.image,
139
160
  text: e == null ? void 0 : e.text,
140
161
  titleSlug: e == null ? void 0 : e.titleSlug,
141
162
  buttonText: e == null ? void 0 : e.buttonText,
142
- onCardClick: () => a(e == null ? void 0 : e.uuid)
163
+ onCardClick: () => n(e == null ? void 0 : e.uuid)
143
164
  },
144
- n
145
- )) });
165
+ d
166
+ )) }), [r]);
167
+ return /* @__PURE__ */ t(B, { limit: o, children: /* @__PURE__ */ t(
168
+ P,
169
+ {
170
+ isLoading: m,
171
+ limit: o,
172
+ keyPrefix: "explore-landing",
173
+ children: C
174
+ }
175
+ ) });
146
176
  });
147
177
  export {
148
- M as default
178
+ G as default
149
179
  };
@@ -1,9 +1,9 @@
1
- "use strict";const t=require("react/jsx-runtime"),m=require("react"),g=require("./emotion-styled.browser.esm-Cle7tAM9.cjs"),p=require("./consts-CtNoHdBj.cjs"),v=require("./useDetectMobile-D6d5LpdL.cjs"),n=require("./utils-NZLCh-J5.cjs"),k=require("./style-BR3tIhP1.cjs"),y=require("./Button.cjs"),C=require("./Link.cjs"),N=require("./index-Q_i-aqsF.cjs"),q=g.newStyled.div`
1
+ "use strict";const t=require("react/jsx-runtime"),a=require("react"),g=require("./emotion-styled.browser.esm-Cle7tAM9.cjs"),j=require("./consts-CtNoHdBj.cjs"),x=require("./useDetectMobile-D6d5LpdL.cjs"),s=require("./utils-NZLCh-J5.cjs"),C=require("./style-BR3tIhP1.cjs"),N=require("./Button.cjs"),q=require("./Link.cjs"),T=require("./index-Q_i-aqsF.cjs"),$=g.newStyled.div`
2
2
  display: grid;
3
- grid-template-columns: ${r=>`repeat(${r.limit}, minmax(0, 1fr))`};
3
+ grid-template-columns: ${i=>`repeat(${i.limit}, minmax(0, 1fr))`};
4
4
  gap: 1.25rem;
5
5
 
6
- @media (max-width: ${p.MOBILE_SIZE_PX+"px"}) {
6
+ @media (max-width: ${j.MOBILE_SIZE_PX+"px"}) {
7
7
  grid-template-columns: repeat(1, 1fr);
8
8
  }
9
9
  `,b=g.newStyled.div`
@@ -35,16 +35,16 @@
35
35
  min-height: 3.3125rem;
36
36
  max-height: 3.3125rem;
37
37
  border-radius: 0.75rem;
38
- background-color: ${n.linearGradientAnimation("-90deg")};
38
+ background-color: ${s.linearGradientAnimation("-90deg")};
39
39
  }
40
40
 
41
41
  & a {
42
42
  margin-top: auto;
43
43
  }
44
44
 
45
- @media (max-width: ${p.MOBILE_SIZE_PX+"px"}) {
45
+ @media (max-width: ${j.MOBILE_SIZE_PX+"px"}) {
46
46
  }
47
- `,w=g.newStyled.div`
47
+ `,f=g.newStyled.div`
48
48
  display: flex;
49
49
  flex-direction: column;
50
50
  gap: 0.5rem;
@@ -58,19 +58,19 @@
58
58
  & .skeleton-title {
59
59
  height: 1.5rem;
60
60
  width: 80%;
61
- background-color: ${n.linearGradientAnimation("-90deg")};
61
+ background-color: ${s.linearGradientAnimation("-90deg")};
62
62
  }
63
63
 
64
64
  & .skeleton-action {
65
65
  height: 1.25rem;
66
66
  width: 20%;
67
- background-color: ${n.linearGradientAnimation("-90deg")};
67
+ background-color: ${s.linearGradientAnimation("-90deg")};
68
68
  }
69
69
 
70
70
  & .text-wr {
71
71
  font-weight: 400;
72
72
  font-size: 0.875rem;
73
73
  color: var(--gray-700, #4e555f);
74
- ${n.truncateTextInRows(3)}
74
+ ${s.truncateTextInRows(3)}
75
75
  }
76
- `;m.forwardRef(({},r)=>t.jsxs(b,{className:"blog-card",children:[t.jsxs(w,{children:[t.jsx("div",{className:"skeleton-title"}),t.jsx("div",{className:"text-wr"}),t.jsx("div",{className:"skeleton-action"})]}),t.jsx("div",{className:"skeleton-img"})]}));const h=m.forwardRef((r,j)=>{const{title:l,image:s,text:i,buttonText:c,onCardClick:o}=r;return t.jsxs(b,{className:"blog-card",onClick:o,children:[t.jsxs(w,{children:[t.jsx("div",{className:"text-wr-title",children:l}),t.jsx("div",{className:"text-wr",children:i}),t.jsx(C,{color:"gray",onClick:o,children:c})]}),t.jsx("img",{src:s})]})}),T=m.forwardRef((r,j)=>{const{icon:l,title:s,items:i,buttonText:c,limit:o=3,options:a,onActionClick:f=()=>{},onSelectOption:u=()=>{}}=r,S=v.useDetectMobile();return t.jsxs(k.TitleWithOptionsSectionWrapper,{children:[t.jsxs("div",{className:"regular-title",children:[t.jsxs("div",{className:"regular-title-text",children:[n.isDefinedNotEmptyString(l)&&t.jsx("i",{className:l}),t.jsx("span",{children:s})]}),n.isDefinedNotEmptyString(onSectionClick)&&t.jsx(y,{type:"button",btnType:"tinted",color:"gray",onClick:f,borderRadius:"curved",children:c})]}),(a==null?void 0:a.length)>0&&t.jsx(N.SelectBar,{items:a,onRemove:e=>{u(e)},onSelect:e=>{u(e)},labelKey:"name",valueKey:"code",noMargin:!0}),t.jsx(q,{limit:o,children:S===!0?i==null?void 0:i.map((e,d)=>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,buttonText:e==null?void 0:e.buttonText,onCardClick:()=>onSelectCard(e==null?void 0:e.uuid)},d)):i==null?void 0:i.slice(0,o).map((e,d)=>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,buttonText:e==null?void 0:e.buttonText,onCardClick:()=>onSelectCard(e==null?void 0:e.uuid)},d))})]})});module.exports=T;
76
+ `,B=a.forwardRef(({},i)=>t.jsxs(b,{className:"blog-card",children:[t.jsxs(f,{children:[t.jsx("div",{className:"skeleton-title"}),t.jsx("div",{className:"text-wr"}),t.jsx("div",{className:"skeleton-action"})]}),t.jsx("div",{className:"skeleton-img"})]})),M=a.forwardRef((i,c)=>{const{title:n,image:o,text:r,buttonText:m,onCardClick:l}=i;return t.jsxs(b,{className:"blog-card",onClick:l,children:[t.jsxs(f,{children:[t.jsx("div",{className:"text-wr-title",children:n}),t.jsx("div",{className:"text-wr",children:r}),t.jsx(q,{color:"gray",onClick:l,children:m})]}),t.jsx("img",{src:o})]})}),R=({limit:i=3,isLoading:c=!1,keyPrefix:n})=>t.jsx(t.Fragment,{children:Array.from({length:i},(o,r)=>t.jsx(B,{isLoading:c},`${n}-skeleton-product-card-${r}`))}),W=({children:i,fallbackComponent:c=t.jsx(t.Fragment,{}),isLoading:n=!1,limit:o,keyPrefix:r})=>t.jsx(a.Suspense,{fallbackComponent:c,children:n===!0?t.jsx(R,{isLoading:n,limit:o,keyPrefix:r}):i}),p=a.memo(M),_=a.forwardRef((i,c)=>{const{icon:n,title:o,items:r,buttonText:m,limit:l=3,options:d,onActionClick:w=()=>{},onSelectOption:h=()=>{},isLoading:S=!1,onSectionClick:k=()=>{}}=i,y=x.useDetectMobile(),v=a.useMemo(()=>t.jsx(t.Fragment,{children:y===!0?r==null?void 0:r.map((e,u)=>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,buttonText:e==null?void 0:e.buttonText,onCardClick:()=>onSelectCard(e==null?void 0:e.uuid)},u)):r==null?void 0:r.slice(0,l).map((e,u)=>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,buttonText:e==null?void 0:e.buttonText,onCardClick:()=>onSelectCard(e==null?void 0:e.uuid)},u))}),[r]);return t.jsxs(C.TitleWithOptionsSectionWrapper,{children:[t.jsxs("div",{className:"regular-title",children:[t.jsxs("div",{className:"regular-title-text",children:[s.isDefinedNotEmptyString(n)&&t.jsx("i",{className:n}),t.jsx("span",{children:o})]}),s.isDefinedNotEmptyString(k)&&t.jsx(N,{type:"button",btnType:"tinted",color:"gray",onClick:w,borderRadius:"curved",children:m})]}),(d==null?void 0:d.length)>0&&t.jsx(T.SelectBar,{items:d,onRemove:e=>{h(e)},onSelect:e=>{h(e)},labelKey:"name",valueKey:"code",noMargin:!0}),t.jsx($,{limit:l,children:t.jsx(W,{isLoading:S,limit:l,keyPrefix:"explore-landing",children:v})})]})});module.exports=_;