@lanaco/lnc-react-ui 4.0.156 → 4.0.160

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 (70) hide show
  1. package/dist/BlogCardsSponsoredSection.cjs +8 -8
  2. package/dist/BlogCardsSponsoredSection.js +105 -89
  3. package/dist/BlogExploreSection.cjs +5 -5
  4. package/dist/BlogExploreSection.js +88 -84
  5. package/dist/BlogListSection.cjs +5 -5
  6. package/dist/BlogListSection.js +139 -126
  7. package/dist/BlogProductCardsSection.cjs +1 -1
  8. package/dist/BlogProductCardsSection.js +37 -35
  9. package/dist/BlogShopCardsSection.cjs +1 -1
  10. package/dist/BlogShopCardsSection.js +43 -41
  11. package/dist/BlogSingleSection.cjs +1 -1
  12. package/dist/BlogSingleSection.js +9 -4
  13. package/dist/BlogsSectionDetailed.cjs +11 -11
  14. package/dist/BlogsSectionDetailed.js +122 -108
  15. package/dist/BlogsSectionLarge.cjs +4 -4
  16. package/dist/BlogsSectionLarge.js +43 -40
  17. package/dist/BlogsSectionSimple.cjs +8 -8
  18. package/dist/BlogsSectionSimple.js +100 -86
  19. package/dist/BlogsSectionSimpleCentered.cjs +9 -9
  20. package/dist/BlogsSectionSimpleCentered.js +81 -66
  21. package/dist/BlogsSectionWithFilters.cjs +11 -11
  22. package/dist/BlogsSectionWithFilters.js +108 -93
  23. package/dist/{CustomStyles-Ajyqx0cb.cjs → CustomStyles-BwHfr4iM.cjs} +1 -1
  24. package/dist/{CustomStyles-DVcu00ul.js → CustomStyles-iconSXFL.js} +0 -1
  25. package/dist/DetailedProductsInfinitiveSection.cjs +8 -3
  26. package/dist/DetailedProductsInfinitiveSection.js +63 -51
  27. package/dist/DetailedProductsSection.cjs +3 -3
  28. package/dist/DetailedProductsSection.js +76 -65
  29. package/dist/Dropdown.cjs +1 -1
  30. package/dist/Dropdown.js +2 -2
  31. package/dist/DropdownLookup.cjs +1 -1
  32. package/dist/DropdownLookup.js +1 -1
  33. package/dist/FieldOfInterestsWithAvatarsCardsSection.cjs +1 -1
  34. package/dist/FieldOfInterestsWithAvatarsCardsSection.js +1 -1
  35. package/dist/GiftCardsSection.cjs +1 -1
  36. package/dist/GiftCardsSection.js +1 -1
  37. package/dist/MultiSelectDropdown.cjs +1 -1
  38. package/dist/MultiSelectDropdown.js +1 -1
  39. package/dist/MultiSelectDropdownLookup.cjs +1 -1
  40. package/dist/MultiSelectDropdownLookup.js +1 -1
  41. package/dist/ProductsWithBannerSection.cjs +10 -10
  42. package/dist/ProductsWithBannerSection.js +81 -59
  43. package/dist/SalesCampaignsSection.cjs +27 -27
  44. package/dist/SalesCampaignsSection.js +281 -272
  45. package/dist/ShopCardsSection.cjs +3 -3
  46. package/dist/ShopCardsSection.js +27 -25
  47. package/dist/SimpleCategoriesSection.cjs +1 -1
  48. package/dist/SimpleCategoriesSection.js +1 -1
  49. package/dist/SimpleProductsSection.cjs +3 -3
  50. package/dist/SimpleProductsSection.js +62 -51
  51. package/dist/UrgentSaleProductsSection.cjs +6 -6
  52. package/dist/UrgentSaleProductsSection.js +67 -56
  53. package/dist/index-1Dm1i6WK.js +52 -0
  54. package/dist/index-BGTtoLxz.cjs +1 -0
  55. package/dist/{index-CLoINIGC.cjs → index-DicTpiG0.cjs} +5 -5
  56. package/dist/{index-BGY3PSA-.js → index-y6sKgrZC.js} +45 -34
  57. package/dist/index.cjs +1 -1
  58. package/dist/index.js +1 -1
  59. package/dist/{skeleton-BWFqIToC.js → skeleton-5mO22c5S.js} +94 -84
  60. package/dist/{skeleton-CanJ6Gr6.cjs → skeleton-Ccd6EDeB.cjs} +8 -8
  61. package/dist/{style-DFPWLJBr.js → style-BLuyU97E.js} +4 -0
  62. package/dist/{style-CyHewQxg.cjs → style-lSjkOR95.cjs} +6 -2
  63. package/dist/{suspense-product-card-detailed-YJVsf2-a.js → suspense-product-card-detailed-BZtObEfA.js} +191 -162
  64. package/dist/suspense-product-card-detailed-D-pjVe22.cjs +300 -0
  65. package/dist/{suspense-product-card-simple-CrqjSxHI.cjs → suspense-product-card-simple-DJ8UYolb.cjs} +1 -1
  66. package/dist/{suspense-product-card-simple-CLJjab5B.js → suspense-product-card-simple-ziy0XcLp.js} +1 -1
  67. package/package.json +1 -1
  68. package/dist/index-Cm0f72Po.cjs +0 -1
  69. package/dist/index-DGp7FHms.js +0 -42
  70. package/dist/suspense-product-card-detailed-mCJwteOy.cjs +0 -265
@@ -1,11 +1,11 @@
1
- "use strict";const r=require("react/jsx-runtime"),m=require("react"),s=require("./utils-Dl9xPH4c.cjs"),w=require("./Icon.cjs"),j=require("./style-CyHewQxg.cjs"),N=require("./index-BueKsXT8.cjs"),b=require("./emotion-styled.browser.esm-BtEseadx.cjs"),v=require("./consts-goSZX3xP.cjs"),x=require("./suspense-large-CFmcSzX-.cjs"),S=require("./Button.cjs"),z=b.styled.div`
1
+ "use strict";const r=require("react/jsx-runtime"),d=require("react"),l=require("./utils-Dl9xPH4c.cjs"),w=require("./Icon.cjs"),R=require("./style-lSjkOR95.cjs"),x=require("./index-BueKsXT8.cjs"),v=require("./emotion-styled.browser.esm-BtEseadx.cjs"),y=require("./consts-goSZX3xP.cjs"),S=require("./suspense-large-CFmcSzX-.cjs"),z=require("./Button.cjs"),I=v.styled.div`
2
2
  display: flex;
3
3
  padding: 1rem;
4
4
  align-items: center;
5
5
  gap: 1.25rem;
6
6
  border-radius: 1.25rem;
7
7
  align-items: stretch;
8
- border: ${i=>i!=null&&i.isSponsored?"2px solid var(--yellow-500, #f59e0b)":"1px solid var(--neutral-9508, rgba(20, 22, 26, 0.08))"};
8
+ border: ${s=>s!=null&&s.isSponsored?"2px solid var(--yellow-500, #f59e0b)":"1px solid var(--neutral-9508, rgba(20, 22, 26, 0.08))"};
9
9
  background: var(--white, #fff);
10
10
  min-height: 10.5rem;
11
11
  position: relative;
@@ -63,7 +63,7 @@
63
63
  font-weight: 600;
64
64
  line-height: 1.5rem;
65
65
  letter-spacing: 0.1px;
66
- ${s.truncateTextInRows(2)}
66
+ ${l.truncateTextInRows(2)}
67
67
  }
68
68
 
69
69
  & .wrapper__tags {
@@ -95,7 +95,7 @@
95
95
  }
96
96
  }
97
97
 
98
- @media (max-width: ${v.MOBILE_SIZE_PX+"px"}) {
98
+ @media (max-width: ${y.MOBILE_SIZE_PX+"px"}) {
99
99
  flex-direction: column;
100
100
  padding: 0;
101
101
 
@@ -121,7 +121,7 @@
121
121
  }
122
122
  }
123
123
  }
124
- `,I=m.forwardRef(({title:i,imageUrl:p,options:a,publishedAt:c,timeToReadText:g="{0} min read",timeToRead:_=0,numberOfLikes:n=0,numberOfComments:l=0,isSponsored:o=!1,onSelectCard:f=()=>{}},u)=>r.jsxs(z,{ref:u,isSponsored:o,onClick:f,children:[o&&r.jsx("div",{className:"wrapper__sponsored",children:r.jsx(w,{icon:" mng-lnc-paw",sizeInUnits:"1.5rem"})}),r.jsx(N.ProductImageWrapper,{src:p,className:"wrapper__image"}),r.jsxs("div",{className:"wrapper__content",children:[r.jsxs("div",{className:"wrapper__subcontent",children:[r.jsx("div",{className:"wrapper__title",children:i}),r.jsx("div",{className:"wrapper__tags",children:a&&(a==null?void 0:a.map((t,h)=>r.jsx(j.BlogTag,{color:t==null?void 0:t.color,children:t==null?void 0:t.name},h)))})]}),r.jsxs("div",{className:"wrapper__info",children:[r.jsx("div",{className:"info__text",children:`${s.formatLocaleDateString(c)} • ${s.formatString(g,_)}`}),r.jsxs("div",{className:"info__text",children:[r.jsxs("div",{children:[r.jsx(w,{icon:" mng-lnc-thumbs-up--filled",sizeInUnits:"1rem"}),s.getRoundedNumber(n)]}),r.jsxs("div",{children:[r.jsx(w,{icon:" mng-lnc-messages-filled",sizeInUnits:"1rem"}),s.getRoundedNumber(l)]})]})]})]})]})),R=b.styled.div`
124
+ `,q=d.forwardRef(({title:s,imageUrl:m,options:n,publishedAt:_,timeToReadText:f="{0} min read",timeToRead:u=0,numberOfLikes:o=0,numberOfComments:c=0,isSponsored:p=!1,onSelectCard:h=()=>{},metadata:t},b)=>{const g=d.useRef();return r.jsxs(I,{ref:g,isSponsored:p,"data-accessor":t==null?void 0:t.accessor,name:t==null?void 0:t.name,onClick:i=>h(i,g),children:[p&&r.jsx("div",{className:"wrapper__sponsored",children:r.jsx(w,{icon:" mng-lnc-paw",sizeInUnits:"1.5rem"})}),r.jsx(x.ProductImageWrapper,{src:m,className:"wrapper__image"}),r.jsxs("div",{className:"wrapper__content",children:[r.jsxs("div",{className:"wrapper__subcontent",children:[r.jsx("div",{className:"wrapper__title",children:s}),r.jsx("div",{className:"wrapper__tags",children:n&&(n==null?void 0:n.map((i,a)=>r.jsx(R.BlogTag,{color:i==null?void 0:i.color,children:i==null?void 0:i.name},a)))})]}),r.jsxs("div",{className:"wrapper__info",children:[r.jsx("div",{className:"info__text",children:`${l.formatLocaleDateString(_)} • ${l.formatString(f,u)}`}),r.jsxs("div",{className:"info__text",children:[r.jsxs("div",{children:[r.jsx(w,{icon:" mng-lnc-thumbs-up--filled",sizeInUnits:"1rem"}),l.getRoundedNumber(o)]}),r.jsxs("div",{children:[r.jsx(w,{icon:" mng-lnc-messages-filled",sizeInUnits:"1rem"}),l.getRoundedNumber(c)]})]})]})]})]})}),k=v.styled.div`
125
125
  display: flex;
126
126
  flex-direction: column;
127
127
  align-items: flex-start;
@@ -139,7 +139,7 @@
139
139
 
140
140
  & .title__text {
141
141
  color: var(--gray-950, #14161a);
142
- ${s.truncateTextInRows(2)}
142
+ ${l.truncateTextInRows(2)}
143
143
 
144
144
  font-size: 1.5rem;
145
145
  font-style: normal;
@@ -191,7 +191,7 @@
191
191
  width: 100%;
192
192
  }
193
193
 
194
- @media (max-width: ${v.MOBILE_SIZE_PX+"px"}) {
194
+ @media (max-width: ${y.MOBILE_SIZE_PX+"px"}) {
195
195
  & .wrapper__title {
196
196
  & .title__text {
197
197
  font-size: 1.375rem;
@@ -203,4 +203,4 @@
203
203
  gap: 1rem;
204
204
  }
205
205
  }
206
- `,q=m.memo(I),k=m.forwardRef(({title:i,subtitle:p,icon:a,buttonText:c,buttonLink:g,timeToReadText:_="{0} min read",items:n,onButtonAction:l=()=>{},onSelectCard:o=()=>{},isLoading:f=!1,getImage:u=()=>{}},t)=>{const h=m.useMemo(()=>{var d;return(d=n==null?void 0:n.slice(0,4))==null?void 0:d.map((e,y)=>r.jsx(q,{title:e==null?void 0:e.title,titleSlug:e==null?void 0:e.titleSlug,options:e==null?void 0:e.options,publishedAt:e==null?void 0:e.publishedAt,timeToReadText:_,timeToRead:e==null?void 0:e.timeToRead,numberOfLikes:e==null?void 0:e.numberOfLikes,numberOfComments:e==null?void 0:e.numberOfComments,isSponsored:e==null?void 0:e.isSponsored,onSelectCard:()=>o==null?void 0:o(e),imageUrl:u(e==null?void 0:e.imageUrl,e==null?void 0:e.uuid)||null},`blog-card-sponsored__${y+1}`))},[n]);return r.jsxs(R,{ref:t,children:[r.jsxs("div",{className:"wrapper__heading",children:[r.jsxs("div",{className:"wrapper__title",children:[i&&r.jsxs("div",{className:"title__text",children:[s.isDefinedNotEmptyString(a)&&r.jsx("i",{className:a}),r.jsx("span",{children:i})]}),l&&r.jsx(S,{text:c,borderRadius:"curved",btnType:"tinted",className:"title__action",color:"neutral",onClick:d=>{var e;(e=d==null?void 0:d.target)==null||e.blur(),l==null||l(g)}})]}),p&&r.jsx("div",{className:"wrapper__subtitle",children:p})]}),r.jsx("div",{className:"wrapper__cards",children:r.jsx(x.SuspenseBlogLarge,{isLoading:f,limit:4,keyPrefix:"blog-section",children:h})})]})});module.exports=k;
206
+ `,$=d.memo(q),L=d.forwardRef(({title:s,subtitle:m,icon:n,buttonText:_,buttonLink:f,timeToReadText:u="{0} min read",items:o,onButtonAction:c=()=>{},onSelectCard:p=()=>{},isLoading:h=!1,getImage:t=()=>{},componentName:b},g)=>{const i=d.useMemo(()=>{var a;return(a=o==null?void 0:o.slice(0,4))==null?void 0:a.map((e,j)=>r.jsx($,{title:e==null?void 0:e.title,titleSlug:e==null?void 0:e.titleSlug,options:e==null?void 0:e.options,publishedAt:e==null?void 0:e.publishedAt,timeToReadText:u,timeToRead:e==null?void 0:e.timeToRead,numberOfLikes:e==null?void 0:e.numberOfLikes,numberOfComments:e==null?void 0:e.numberOfComments,isSponsored:e==null?void 0:e.isSponsored,onSelectCard:(O,N)=>p==null?void 0:p(e,N),imageUrl:t(e==null?void 0:e.imageUrl,e==null?void 0:e.uuid)||null,metadata:{name:b,accessor:e==null?void 0:e.accessor}},`blog-card-sponsored__${j+1}`))},[o]);return r.jsxs(k,{ref:g,children:[r.jsxs("div",{className:"wrapper__heading",children:[r.jsxs("div",{className:"wrapper__title",children:[s&&r.jsxs("div",{className:"title__text",children:[l.isDefinedNotEmptyString(n)&&r.jsx("i",{className:n}),r.jsx("span",{children:s})]}),c&&r.jsx(z,{text:_,borderRadius:"curved",btnType:"tinted",className:"title__action",color:"neutral",onClick:a=>{var e;(e=a==null?void 0:a.target)==null||e.blur(),c==null||c(f)}})]}),m&&r.jsx("div",{className:"wrapper__subtitle",children:m})]}),r.jsx("div",{className:"wrapper__cards",children:r.jsx(S.SuspenseBlogLarge,{isLoading:h,limit:4,keyPrefix:"blog-section",children:i})})]})});module.exports=L;
@@ -1,21 +1,21 @@
1
- import { jsxs as a, jsx as r } from "react/jsx-runtime";
2
- import { forwardRef as b, memo as S, useMemo as k } from "react";
3
- import { p as v, s as $, v as j, w as u, k as I } from "./utils-BdsZgOUE.js";
1
+ import { jsxs as i, jsx as r } from "react/jsx-runtime";
2
+ import { forwardRef as v, useRef as $, memo as j, useMemo as I } from "react";
3
+ import { p as y, s as R, v as L, w as b, k as O } from "./utils-BdsZgOUE.js";
4
4
  import w from "./Icon.js";
5
- import { B as R } from "./style-DFPWLJBr.js";
6
- import { P as L } from "./index-CF3HhgvN.js";
7
- import { s as y } from "./emotion-styled.browser.esm-BNN1dTl3.js";
8
- import { M as N } from "./consts-BuFChS64.js";
9
- import { S as O } from "./suspense-large-BMO7JH52.js";
10
- import T from "./Button.js";
11
- const U = y.div`
5
+ import { B as T } from "./style-BLuyU97E.js";
6
+ import { P as U } from "./index-CF3HhgvN.js";
7
+ import { s as N } from "./emotion-styled.browser.esm-BNN1dTl3.js";
8
+ import { M as z } from "./consts-BuFChS64.js";
9
+ import { S as B } from "./suspense-large-BMO7JH52.js";
10
+ import C from "./Button.js";
11
+ const M = N.div`
12
12
  display: flex;
13
13
  padding: 1rem;
14
14
  align-items: center;
15
15
  gap: 1.25rem;
16
16
  border-radius: 1.25rem;
17
17
  align-items: stretch;
18
- border: ${(i) => i != null && i.isSponsored ? "2px solid var(--yellow-500, #f59e0b)" : "1px solid var(--neutral-9508, rgba(20, 22, 26, 0.08))"};
18
+ border: ${(t) => t != null && t.isSponsored ? "2px solid var(--yellow-500, #f59e0b)" : "1px solid var(--neutral-9508, rgba(20, 22, 26, 0.08))"};
19
19
  background: var(--white, #fff);
20
20
  min-height: 10.5rem;
21
21
  position: relative;
@@ -73,7 +73,7 @@ const U = y.div`
73
73
  font-weight: 600;
74
74
  line-height: 1.5rem;
75
75
  letter-spacing: 0.1px;
76
- ${v(2)}
76
+ ${y(2)}
77
77
  }
78
78
 
79
79
  & .wrapper__tags {
@@ -105,7 +105,7 @@ const U = y.div`
105
105
  }
106
106
  }
107
107
 
108
- @media (max-width: ${N + "px"}) {
108
+ @media (max-width: ${z + "px"}) {
109
109
  flex-direction: column;
110
110
  padding: 0;
111
111
 
@@ -131,45 +131,59 @@ const U = y.div`
131
131
  }
132
132
  }
133
133
  }
134
- `, B = b(
134
+ `, P = v(
135
135
  ({
136
- title: i,
137
- imageUrl: p,
136
+ title: t,
137
+ imageUrl: d,
138
138
  options: l,
139
- publishedAt: d,
140
- timeToReadText: c = "{0} min read",
141
- timeToRead: g = 0,
142
- numberOfLikes: n = 0,
143
- numberOfComments: s = 0,
144
- isSponsored: o = !1,
145
- onSelectCard: f = () => {
146
- }
147
- }, _) => /* @__PURE__ */ a(U, { ref: _, isSponsored: o, onClick: f, children: [
148
- o && /* @__PURE__ */ r("div", { className: "wrapper__sponsored", children: /* @__PURE__ */ r(w, { icon: " mng-lnc-paw", sizeInUnits: "1.5rem" }) }),
149
- /* @__PURE__ */ r(L, { src: p, className: "wrapper__image" }),
150
- /* @__PURE__ */ a("div", { className: "wrapper__content", children: [
151
- /* @__PURE__ */ a("div", { className: "wrapper__subcontent", children: [
152
- /* @__PURE__ */ r("div", { className: "wrapper__title", children: i }),
153
- /* @__PURE__ */ r("div", { className: "wrapper__tags", children: l && (l == null ? void 0 : l.map((t, h) => /* @__PURE__ */ r(R, { color: t == null ? void 0 : t.color, children: t == null ? void 0 : t.name }, h))) })
154
- ] }),
155
- /* @__PURE__ */ a("div", { className: "wrapper__info", children: [
156
- /* @__PURE__ */ r("div", { className: "info__text", children: `${$(
157
- d
158
- )} • ${j(c, g)}` }),
159
- /* @__PURE__ */ a("div", { className: "info__text", children: [
160
- /* @__PURE__ */ a("div", { children: [
161
- /* @__PURE__ */ r(w, { icon: " mng-lnc-thumbs-up--filled", sizeInUnits: "1rem" }),
162
- u(n)
163
- ] }),
164
- /* @__PURE__ */ a("div", { children: [
165
- /* @__PURE__ */ r(w, { icon: " mng-lnc-messages-filled", sizeInUnits: "1rem" }),
166
- u(s)
139
+ publishedAt: f,
140
+ timeToReadText: g = "{0} min read",
141
+ timeToRead: _ = 0,
142
+ numberOfLikes: o = 0,
143
+ numberOfComments: p = 0,
144
+ isSponsored: m = !1,
145
+ onSelectCard: h = () => {
146
+ },
147
+ metadata: s
148
+ }, u) => {
149
+ const c = $();
150
+ return /* @__PURE__ */ i(
151
+ M,
152
+ {
153
+ ref: c,
154
+ isSponsored: m,
155
+ "data-accessor": s == null ? void 0 : s.accessor,
156
+ name: s == null ? void 0 : s.name,
157
+ onClick: (a) => h(a, c),
158
+ children: [
159
+ m && /* @__PURE__ */ r("div", { className: "wrapper__sponsored", children: /* @__PURE__ */ r(w, { icon: " mng-lnc-paw", sizeInUnits: "1.5rem" }) }),
160
+ /* @__PURE__ */ r(U, { src: d, className: "wrapper__image" }),
161
+ /* @__PURE__ */ i("div", { className: "wrapper__content", children: [
162
+ /* @__PURE__ */ i("div", { className: "wrapper__subcontent", children: [
163
+ /* @__PURE__ */ r("div", { className: "wrapper__title", children: t }),
164
+ /* @__PURE__ */ r("div", { className: "wrapper__tags", children: l && (l == null ? void 0 : l.map((a, n) => /* @__PURE__ */ r(T, { color: a == null ? void 0 : a.color, children: a == null ? void 0 : a.name }, n))) })
165
+ ] }),
166
+ /* @__PURE__ */ i("div", { className: "wrapper__info", children: [
167
+ /* @__PURE__ */ r("div", { className: "info__text", children: `${R(
168
+ f
169
+ )} • ${L(g, _)}` }),
170
+ /* @__PURE__ */ i("div", { className: "info__text", children: [
171
+ /* @__PURE__ */ i("div", { children: [
172
+ /* @__PURE__ */ r(w, { icon: " mng-lnc-thumbs-up--filled", sizeInUnits: "1rem" }),
173
+ b(o)
174
+ ] }),
175
+ /* @__PURE__ */ i("div", { children: [
176
+ /* @__PURE__ */ r(w, { icon: " mng-lnc-messages-filled", sizeInUnits: "1rem" }),
177
+ b(p)
178
+ ] })
179
+ ] })
180
+ ] })
167
181
  ] })
168
- ] })
169
- ] })
170
- ] })
171
- ] })
172
- ), C = y.div`
182
+ ]
183
+ }
184
+ );
185
+ }
186
+ ), E = N.div`
173
187
  display: flex;
174
188
  flex-direction: column;
175
189
  align-items: flex-start;
@@ -187,7 +201,7 @@ const U = y.div`
187
201
 
188
202
  & .title__text {
189
203
  color: var(--gray-950, #14161a);
190
- ${v(2)}
204
+ ${y(2)}
191
205
 
192
206
  font-size: 1.5rem;
193
207
  font-style: normal;
@@ -239,7 +253,7 @@ const U = y.div`
239
253
  width: 100%;
240
254
  }
241
255
 
242
- @media (max-width: ${N + "px"}) {
256
+ @media (max-width: ${z + "px"}) {
243
257
  & .wrapper__title {
244
258
  & .title__text {
245
259
  font-size: 1.375rem;
@@ -251,79 +265,81 @@ const U = y.div`
251
265
  gap: 1rem;
252
266
  }
253
267
  }
254
- `, M = S(B), J = b(
268
+ `, W = j(P), Y = v(
255
269
  ({
256
- title: i,
257
- subtitle: p,
270
+ title: t,
271
+ subtitle: d,
258
272
  icon: l,
259
- buttonText: d,
260
- buttonLink: c,
261
- timeToReadText: g = "{0} min read",
262
- items: n,
263
- onButtonAction: s = () => {
273
+ buttonText: f,
274
+ buttonLink: g,
275
+ timeToReadText: _ = "{0} min read",
276
+ items: o,
277
+ onButtonAction: p = () => {
264
278
  },
265
- onSelectCard: o = () => {
279
+ onSelectCard: m = () => {
266
280
  },
267
- isLoading: f = !1,
268
- getImage: _ = () => {
269
- }
270
- }, t) => {
271
- const h = k(() => {
272
- var m;
273
- return (m = n == null ? void 0 : n.slice(0, 4)) == null ? void 0 : m.map((e, z) => /* @__PURE__ */ r(
274
- M,
281
+ isLoading: h = !1,
282
+ getImage: s = () => {
283
+ },
284
+ componentName: u
285
+ }, c) => {
286
+ const a = I(() => {
287
+ var n;
288
+ return (n = o == null ? void 0 : o.slice(0, 4)) == null ? void 0 : n.map((e, S) => /* @__PURE__ */ r(
289
+ W,
275
290
  {
276
291
  title: e == null ? void 0 : e.title,
277
292
  titleSlug: e == null ? void 0 : e.titleSlug,
278
293
  options: e == null ? void 0 : e.options,
279
294
  publishedAt: e == null ? void 0 : e.publishedAt,
280
- timeToReadText: g,
295
+ timeToReadText: _,
281
296
  timeToRead: e == null ? void 0 : e.timeToRead,
282
297
  numberOfLikes: e == null ? void 0 : e.numberOfLikes,
283
298
  numberOfComments: e == null ? void 0 : e.numberOfComments,
284
299
  isSponsored: e == null ? void 0 : e.isSponsored,
285
- onSelectCard: () => o == null ? void 0 : o(e),
286
- imageUrl: _(e == null ? void 0 : e.imageUrl, e == null ? void 0 : e.uuid) || null
300
+ onSelectCard: (D, k) => m == null ? void 0 : m(e, k),
301
+ imageUrl: s(e == null ? void 0 : e.imageUrl, e == null ? void 0 : e.uuid) || null,
302
+ metadata: { name: u, accessor: e == null ? void 0 : e.accessor }
287
303
  },
288
- `blog-card-sponsored__${z + 1}`
304
+ `blog-card-sponsored__${S + 1}`
289
305
  ));
290
- }, [n]);
291
- return /* @__PURE__ */ a(C, { ref: t, children: [
292
- /* @__PURE__ */ a("div", { className: "wrapper__heading", children: [
293
- /* @__PURE__ */ a("div", { className: "wrapper__title", children: [
294
- i && /* @__PURE__ */ a("div", { className: "title__text", children: [
295
- I(l) && /* @__PURE__ */ r("i", { className: l }),
296
- /* @__PURE__ */ r("span", { children: i })
306
+ }, [o]);
307
+ return /* @__PURE__ */ i(E, { ref: c, children: [
308
+ /* @__PURE__ */ i("div", { className: "wrapper__heading", children: [
309
+ /* @__PURE__ */ i("div", { className: "wrapper__title", children: [
310
+ t && /* @__PURE__ */ i("div", { className: "title__text", children: [
311
+ O(l) && /* @__PURE__ */ r("i", { className: l }),
312
+ /* @__PURE__ */ r("span", { children: t })
297
313
  ] }),
298
- s && /* @__PURE__ */ r(
299
- T,
314
+ p && /* @__PURE__ */ r(
315
+ C,
300
316
  {
301
- text: d,
317
+ text: f,
302
318
  borderRadius: "curved",
303
319
  btnType: "tinted",
304
320
  className: "title__action",
305
321
  color: "neutral",
306
- onClick: (m) => {
322
+ onClick: (n) => {
307
323
  var e;
308
- (e = m == null ? void 0 : m.target) == null || e.blur(), s == null || s(c);
324
+ (e = n == null ? void 0 : n.target) == null || e.blur(), p == null || p(g);
309
325
  }
310
326
  }
311
327
  )
312
328
  ] }),
313
- p && /* @__PURE__ */ r("div", { className: "wrapper__subtitle", children: p })
329
+ d && /* @__PURE__ */ r("div", { className: "wrapper__subtitle", children: d })
314
330
  ] }),
315
331
  /* @__PURE__ */ r("div", { className: "wrapper__cards", children: /* @__PURE__ */ r(
316
- O,
332
+ B,
317
333
  {
318
- isLoading: f,
334
+ isLoading: h,
319
335
  limit: 4,
320
336
  keyPrefix: "blog-section",
321
- children: h
337
+ children: a
322
338
  }
323
339
  ) })
324
340
  ] });
325
341
  }
326
342
  );
327
343
  export {
328
- J as default
344
+ Y as default
329
345
  };
@@ -1,4 +1,4 @@
1
- "use strict";const e=require("react/jsx-runtime"),w=require("react"),n=require("./index-BpbMKBf_.cjs"),$=require("./utils-Dl9xPH4c.cjs"),Q=require("./TextInput.cjs"),b=require("./Icon.cjs"),Y=require("./Link.cjs"),z=require("./DropdownMenu.cjs"),L=require("./DropdownItem.cjs"),B=require("./tag-yputMSpE.cjs"),O=require("./BlogProductCardsSection.cjs"),P=require("./emotion-styled.browser.esm-BtEseadx.cjs"),ee=require("./index-BueKsXT8.cjs"),I=require("./BlogListSection.cjs"),ne=require("./consts-goSZX3xP.cjs"),re=P.styled.div`
1
+ "use strict";const e=require("react/jsx-runtime"),b=require("react"),n=require("./index-BpbMKBf_.cjs"),z=require("./utils-Dl9xPH4c.cjs"),Y=require("./TextInput.cjs"),N=require("./Icon.cjs"),B=require("./Link.cjs"),L=require("./DropdownMenu.cjs"),P=require("./DropdownItem.cjs"),O=require("./tag-yputMSpE.cjs"),ee=require("./BlogProductCardsSection.cjs"),A=require("./emotion-styled.browser.esm-BtEseadx.cjs"),ne=require("./index-BueKsXT8.cjs"),$=require("./BlogListSection.cjs"),re=require("./consts-goSZX3xP.cjs"),te=A.styled.div`
2
2
  display: flex;
3
3
  justify-content: space-between;
4
4
  align-items: center;
@@ -79,7 +79,7 @@
79
79
  }
80
80
  }
81
81
  }
82
- `,te=w.forwardRef(({perPageOptions:o=[{code:10,name:"Show 10 items"},{code:25,name:"Show 25 items"},{code:50,name:"Show 50 items"}],perPage:m,handlePerPage:u=()=>{},page:s=1,handlePage:c=()=>{},totalPage:r},d)=>{var _,l;const p=()=>{s>1&&(c==null||c(s-1))},f=()=>{s<r&&(c==null||c(s+1))},g=()=>{const i=[];if(r<=7)for(let a=1;a<=r;a++)i.push(a);else s<=3?i.push(1,2,3,"...",r):s>=r-2?i.push(1,"...",r-2,r-1,r):i.push(1,2,3,"...",r);return i==null?void 0:i.map((a,x)=>a==="..."?e.jsx("div",{className:"pagination__page ellipsis",children:a},`pagination-ellipsis__${x}`):e.jsx("div",{onClick:()=>c(a),className:`pagination__page ${s===a?"active":""}`,children:a},`pagination-page__${x}`))};return e.jsxs(re,{className:"pagination",children:[e.jsx(z,{color:"neutral",control:((_=o==null?void 0:o.find(i=>(i==null?void 0:i.code)===m))==null?void 0:_.name)||((l=o[0])==null?void 0:l.name),placement:"bottom",zIndex:1001,className:"pagination__per-page",children:o==null?void 0:o.map((i,a)=>e.jsx(L,{active:(i==null?void 0:i.code)===(m==null?void 0:m.code),className:"sort-by__item",onClick:()=>u(i),children:i==null?void 0:i.name},`blog-epxlore-section-per-page-option__${a+1}`))}),e.jsxs("div",{className:"pagination__pages",children:[e.jsx("div",{className:`pagination__page ${s===1?"disabled":""}`,onClick:p,children:e.jsx(b,{icon:" mng-lnc-chevron--left"})}),g(),e.jsx("div",{className:`pagination__page ${s===r?"disabled":""}`,onClick:f,children:e.jsx(b,{icon:" mng-lnc-chevron--right"})})]})]})}),ie=P.styled.div`
82
+ `,ie=b.forwardRef(({perPageOptions:c=[{code:10,name:"Show 10 items"},{code:25,name:"Show 25 items"},{code:50,name:"Show 50 items"}],perPage:m,handlePerPage:u=()=>{},page:s=1,handlePage:o=()=>{},totalPage:r},d)=>{var _,l;const p=()=>{s>1&&(o==null||o(s-1))},f=()=>{s<r&&(o==null||o(s+1))},g=()=>{const i=[];if(r<=7)for(let a=1;a<=r;a++)i.push(a);else s<=3?i.push(1,2,3,"...",r):s>=r-2?i.push(1,"...",r-2,r-1,r):i.push(1,2,3,"...",r);return i==null?void 0:i.map((a,x)=>a==="..."?e.jsx("div",{className:"pagination__page ellipsis",children:a},`pagination-ellipsis__${x}`):e.jsx("div",{onClick:()=>o(a),className:`pagination__page ${s===a?"active":""}`,children:a},`pagination-page__${x}`))};return e.jsxs(te,{className:"pagination",children:[e.jsx(L,{color:"neutral",control:((_=c==null?void 0:c.find(i=>(i==null?void 0:i.code)===m))==null?void 0:_.name)||((l=c[0])==null?void 0:l.name),placement:"bottom",zIndex:1001,className:"pagination__per-page",children:c==null?void 0:c.map((i,a)=>e.jsx(P,{active:(i==null?void 0:i.code)===(m==null?void 0:m.code),className:"sort-by__item",onClick:()=>u(i),children:i==null?void 0:i.name},`blog-epxlore-section-per-page-option__${a+1}`))}),e.jsxs("div",{className:"pagination__pages",children:[e.jsx("div",{className:`pagination__page ${s===1?"disabled":""}`,onClick:p,children:e.jsx(N,{icon:" mng-lnc-chevron--left"})}),g(),e.jsx("div",{className:`pagination__page ${s===r?"disabled":""}`,onClick:f,children:e.jsx(N,{icon:" mng-lnc-chevron--right"})})]})]})}),ae=A.styled.div`
83
83
  display: flex;
84
84
  align-items: flex-start;
85
85
  gap: 2rem;
@@ -255,7 +255,7 @@
255
255
  font-style: normal;
256
256
  font-weight: 500;
257
257
  line-height: 1.25rem;
258
- ${$.truncateTextInRows(2)}
258
+ ${z.truncateTextInRows(2)}
259
259
  }
260
260
 
261
261
  & .item__description {
@@ -270,7 +270,7 @@
270
270
  }
271
271
  }
272
272
 
273
- @media (max-width: ${ne.MOBILE_SIZE_PX+"px"}) {
273
+ @media (max-width: ${re.MOBILE_SIZE_PX+"px"}) {
274
274
  flex-direction: column;
275
275
 
276
276
  & .landing__main-content {
@@ -317,4 +317,4 @@
317
317
  display: none;
318
318
  }
319
319
  }
320
- `,A=w.forwardRef(({mainTitle:o,sideTitle:m,tags:u,selectedTag:s,handleSelectTag:c=()=>{},blogs:r,miniBlogs:d,products:p,blogsLoading:f=!1,productsLoading:g=!1,sortingOptions:_,sortBy:l,handleSortBy:i=()=>{},allTagText:a="All",searchPlaceholderText:x="Search blogs",timeToReadText:N="{0} min read",getBlogImageUrl:y=()=>{},handleSelectBlog:v=()=>{},handleSelectBlogTag:S=()=>{},handleShareBlog:k=()=>{},showAllButtonLink:R,showAllButtonText:E="Show all products",viewAllButtonText:F="View all (11)",viewAllButtonLink:ae,handleViewAll:D=()=>{},handleShowAll:M=()=>{},handleSelectProduct:U=()=>{},getProductImageUrl:V=()=>{},page:H,handlePage:T=()=>{},perPage:W,handlePerPage:X=()=>{},totalPage:j,perPageOptions:Z,handleSearch:G=()=>{},onBookmark:q=()=>{},bookmarkComponent:C=e.jsx(e.Fragment,{children:" "})},J)=>{const K=t=>{document.getElementById("landing__container").scrollIntoView({behavior:"smooth",block:"start"}),T==null||T(t)};return e.jsxs(ie,{ref:J,id:"landing__container",children:[e.jsxs("div",{className:"landing__main-content",children:[o&&e.jsx("div",{className:"main-content__title",children:o}),u&&e.jsx(B.FaqSectionTags,{tags:u,allTagText:a,selectedTagCode:s,onSelectTag:c}),e.jsxs("div",{className:"main-content__actions",children:[e.jsx(Q,{className:"main-content__search",placeholder:x,debounceTime:200,prefix:e.jsx(b,{icon:" mng-lnc-search",sizeInUnits:"1.25rem",className:"main-content__search-prefix"}),color:"neutral",onChange:G}),e.jsx(z,{color:"neutral",control:l==null?void 0:l.name,zIndex:1001,className:"main-content__sort-by",children:_==null?void 0:_.map((t,h)=>e.jsx(L,{active:(t==null?void 0:t.code)===(l==null?void 0:l.code),className:"sort-by__item",onClick:()=>i(t),children:t==null?void 0:t.name},`blog-epxlore-section-sorting-option__${h+1}`))})]}),e.jsxs("div",{className:"main-content__items",children:[r&&(r==null?void 0:r.length)>0&&e.jsx(I,{timeToReadText:N,items:r==null?void 0:r.slice(0,5),isLoading:f,getImage:y,onSelectCard:v,onSelectOption:S,onShare:k,onBookmark:q,bookmarkComponent:C}),e.jsx("div",{className:"main-content__divider"}),p&&(p==null?void 0:p.length)>0&&e.jsx(O,{buttonText:E,buttonLink:R,onButtonAction:M,onSelectCard:U,items:p,isLoading:g,getImage:V,isHighlight:!0}),e.jsx("div",{className:"main-content__divider"}),r&&(r==null?void 0:r.length)>0&&e.jsx(I,{timeToReadText:N,items:r==null?void 0:r.slice(5),isLoading:f,getImage:y,onSelectCard:v,onSelectOption:S,onShare:k,onBookmark:q,bookmarkComponent:C})]}),j&&j>1&&e.jsx(te,{perPageOptions:Z,perPage:W,handlePerPage:X,page:H,handlePage:K,totalPage:j})]}),e.jsxs("div",{className:"landing__side-content",children:[m&&e.jsx("div",{className:"side-content__title",children:m}),d&&(d==null?void 0:d.length)>0&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"side-content__items",children:d==null?void 0:d.map((t,h)=>e.jsx(w.Fragment,{children:e.jsxs("div",{className:"side-content__item",onClick:()=>v(t),children:[e.jsx(ee.ProductImageWrapper,{src:y(t==null?void 0:t.imageUrl,t==null?void 0:t.uuid)||null,alt:`Mini blog ${h+1}`,className:"item__image"}),e.jsxs("div",{className:"item__content",children:[e.jsx("div",{className:"item__title",children:t==null?void 0:t.title}),e.jsx("div",{className:"item__description",children:$.formatLocaleDateString(t==null?void 0:t.publishedAt)})]})]})},`mini_blg_${h}`))}),e.jsx(Y,{onClick:D,className:"side-content__link",children:F})]})]})]})});A.propTypes={mainTitle:n.PropTypes.string,sideTitle:n.PropTypes.string,tags:n.PropTypes.array,selectedTag:n.PropTypes.any,handleSelectTag:n.PropTypes.func,blogs:n.PropTypes.array,miniBlogs:n.PropTypes.array,products:n.PropTypes.array,blogsLoading:n.PropTypes.bool,productsLoading:n.PropTypes.bool,sortingOptions:n.PropTypes.array,sortBy:n.PropTypes.any,handleSortBy:n.PropTypes.func,allTagText:n.PropTypes.string,searchPlaceholderText:n.PropTypes.string,timeToReadText:n.PropTypes.string,getBlogImageUrl:n.PropTypes.func,handleSelectBlog:n.PropTypes.func,handleSelectBlogTag:n.PropTypes.func,handleShareBlog:n.PropTypes.func,handleBookmarkBlog:n.PropTypes.func,showAllButtonLink:n.PropTypes.string,showAllButtonText:n.PropTypes.string,viewAllButtonText:n.PropTypes.string,handleShowAll:n.PropTypes.func,handleSelectProduct:n.PropTypes.func,getProductImageUrl:n.PropTypes.func,page:n.PropTypes.number,handlePage:n.PropTypes.func,perPage:n.PropTypes.any,handlePerPage:n.PropTypes.func,totalPage:n.PropTypes.number,perPageOptions:n.PropTypes.array,handleSearch:n.PropTypes.func};module.exports=A;
320
+ `,R=b.forwardRef(({mainTitle:c,sideTitle:m,tags:u,selectedTag:s,handleSelectTag:o=()=>{},blogs:r,miniBlogs:d,products:p,blogsLoading:f=!1,productsLoading:g=!1,sortingOptions:_,sortBy:l,handleSortBy:i=()=>{},allTagText:a="All",searchPlaceholderText:x="Search blogs",timeToReadText:S="{0} min read",getBlogImageUrl:y=()=>{},handleSelectBlog:v=()=>{},handleSelectBlogTag:k=()=>{},handleShareBlog:q=()=>{},showAllButtonLink:E,showAllButtonText:F="Show all products",viewAllButtonText:D="View all (11)",viewAllButtonLink:se,handleViewAll:M=()=>{},handleShowAll:U=()=>{},handleSelectProduct:V=()=>{},getProductImageUrl:H=()=>{},page:W,handlePage:T=()=>{},perPage:X,handlePerPage:Z=()=>{},totalPage:j,perPageOptions:G,handleSearch:J=()=>{},onBookmark:C=()=>{},bookmarkComponent:I=e.jsx(e.Fragment,{children:" "}),componentName:w},K)=>{const Q=t=>{document.getElementById("landing__container").scrollIntoView({behavior:"smooth",block:"start"}),T==null||T(t)};return e.jsxs(ae,{ref:K,id:"landing__container",children:[e.jsxs("div",{className:"landing__main-content",children:[c&&e.jsx("div",{className:"main-content__title",children:c}),u&&e.jsx(O.FaqSectionTags,{tags:u,allTagText:a,selectedTagCode:s,onSelectTag:o}),e.jsxs("div",{className:"main-content__actions",children:[e.jsx(Y,{className:"main-content__search",placeholder:x,debounceTime:200,prefix:e.jsx(N,{icon:" mng-lnc-search",sizeInUnits:"1.25rem",className:"main-content__search-prefix"}),color:"neutral",onChange:J}),e.jsx(L,{color:"neutral",control:l==null?void 0:l.name,zIndex:1001,className:"main-content__sort-by",children:_==null?void 0:_.map((t,h)=>e.jsx(P,{active:(t==null?void 0:t.code)===(l==null?void 0:l.code),className:"sort-by__item",onClick:()=>i(t),children:t==null?void 0:t.name},`blog-epxlore-section-sorting-option__${h+1}`))})]}),e.jsxs("div",{className:"main-content__items",children:[r&&(r==null?void 0:r.length)>0&&e.jsx($,{timeToReadText:S,items:r==null?void 0:r.slice(0,5),isLoading:f,getImage:y,onSelectCard:v,onSelectOption:k,onShare:q,onBookmark:C,bookmarkComponent:I,componentName:w}),e.jsx("div",{className:"main-content__divider"}),p&&(p==null?void 0:p.length)>0&&e.jsx(ee,{buttonText:F,buttonLink:E,onButtonAction:U,onSelectCard:V,items:p,isLoading:g,getImage:H,isHighlight:!0,componentName:w}),e.jsx("div",{className:"main-content__divider"}),r&&(r==null?void 0:r.length)>0&&e.jsx($,{timeToReadText:S,items:r==null?void 0:r.slice(5),isLoading:f,getImage:y,onSelectCard:v,onSelectOption:k,onShare:q,onBookmark:C,bookmarkComponent:I,componentName:w})]}),j&&j>1&&e.jsx(ie,{perPageOptions:G,perPage:X,handlePerPage:Z,page:W,handlePage:Q,totalPage:j})]}),e.jsxs("div",{className:"landing__side-content",children:[m&&e.jsx("div",{className:"side-content__title",children:m}),d&&(d==null?void 0:d.length)>0&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"side-content__items",children:d==null?void 0:d.map((t,h)=>e.jsx(b.Fragment,{children:e.jsxs("div",{className:"side-content__item",onClick:()=>v(t),children:[e.jsx(ne.ProductImageWrapper,{src:y(t==null?void 0:t.imageUrl,t==null?void 0:t.uuid)||null,alt:`Mini blog ${h+1}`,className:"item__image"}),e.jsxs("div",{className:"item__content",children:[e.jsx("div",{className:"item__title",children:t==null?void 0:t.title}),e.jsx("div",{className:"item__description",children:z.formatLocaleDateString(t==null?void 0:t.publishedAt)})]})]})},`mini_blg_${h}`))}),e.jsx(B,{onClick:M,className:"side-content__link",children:D})]})]})]})});R.propTypes={mainTitle:n.PropTypes.string,sideTitle:n.PropTypes.string,tags:n.PropTypes.array,selectedTag:n.PropTypes.any,handleSelectTag:n.PropTypes.func,blogs:n.PropTypes.array,miniBlogs:n.PropTypes.array,products:n.PropTypes.array,blogsLoading:n.PropTypes.bool,productsLoading:n.PropTypes.bool,sortingOptions:n.PropTypes.array,sortBy:n.PropTypes.any,handleSortBy:n.PropTypes.func,allTagText:n.PropTypes.string,searchPlaceholderText:n.PropTypes.string,timeToReadText:n.PropTypes.string,getBlogImageUrl:n.PropTypes.func,handleSelectBlog:n.PropTypes.func,handleSelectBlogTag:n.PropTypes.func,handleShareBlog:n.PropTypes.func,handleBookmarkBlog:n.PropTypes.func,showAllButtonLink:n.PropTypes.string,showAllButtonText:n.PropTypes.string,viewAllButtonText:n.PropTypes.string,handleShowAll:n.PropTypes.func,handleSelectProduct:n.PropTypes.func,getProductImageUrl:n.PropTypes.func,page:n.PropTypes.number,handlePage:n.PropTypes.func,perPage:n.PropTypes.any,handlePerPage:n.PropTypes.func,totalPage:n.PropTypes.number,perPageOptions:n.PropTypes.array,handleSearch:n.PropTypes.func};module.exports=R;