@lanaco/lnc-react-ui 4.0.226 → 4.0.227
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.
- package/dist/BannerSectionCarousel.cjs +3 -3
- package/dist/BannerSectionCarousel.js +18 -11
- package/dist/BlogCardsSponsoredSection.cjs +1 -1
- package/dist/BlogCardsSponsoredSection.js +1 -1
- package/dist/BlogListSection.cjs +7 -7
- package/dist/BlogListSection.js +157 -207
- package/dist/BlogSingleSection.cjs +2 -11
- package/dist/BlogSingleSection.js +19 -35
- package/dist/BlogsSectionDetailed.cjs +1 -1
- package/dist/BlogsSectionDetailed.js +1 -1
- package/dist/BlogsSectionLarge.cjs +8 -16
- package/dist/BlogsSectionLarge.js +40 -58
- package/dist/BlogsSectionSimple.cjs +1 -1
- package/dist/BlogsSectionSimple.js +1 -1
- package/dist/BlogsSectionSimpleCentered.cjs +12 -25
- package/dist/BlogsSectionSimpleCentered.js +64 -98
- package/dist/BlogsSectionWithFilters.cjs +10 -21
- package/dist/BlogsSectionWithFilters.js +106 -154
- package/dist/BrandHitsSection.cjs +7 -7
- package/dist/BrandHitsSection.js +41 -87
- package/dist/DetailedProductsInfinitiveSection.cjs +1 -1
- package/dist/DetailedProductsInfinitiveSection.js +2 -2
- package/dist/DetailedProductsSection.cjs +1 -1
- package/dist/DetailedProductsSection.js +2 -2
- package/dist/FieldOfInterestsMasonrySection.cjs +13 -13
- package/dist/FieldOfInterestsMasonrySection.js +105 -159
- package/dist/FieldOfInterestsWithAvatarsCardsSection.cjs +8 -8
- package/dist/FieldOfInterestsWithAvatarsCardsSection.js +93 -124
- package/dist/FieldOfInterestsWithTagsCardsSection.cjs +1 -1
- package/dist/FieldOfInterestsWithTagsCardsSection.js +1 -1
- package/dist/GeneralWithTagsCardsSection.cjs +1 -1
- package/dist/GeneralWithTagsCardsSection.js +1 -1
- package/dist/GiftCardsSection.cjs +10 -14
- package/dist/GiftCardsSection.js +76 -146
- package/dist/MasonryGeneralCardsSection.cjs +10 -10
- package/dist/MasonryGeneralCardsSection.js +45 -44
- package/dist/OverlayGeneralCardsSection.cjs +1 -1
- package/dist/OverlayGeneralCardsSection.js +1 -1
- package/dist/ProductsWithBannerSection.cjs +13 -13
- package/dist/ProductsWithBannerSection.js +87 -168
- package/dist/QuattroCardsSection.cjs +1 -1
- package/dist/QuattroCardsSection.js +1 -1
- package/dist/ReviewsSection.cjs +18 -22
- package/dist/ReviewsSection.js +101 -163
- package/dist/SalesCampaignsSection.cjs +14 -14
- package/dist/SalesCampaignsSection.js +299 -330
- package/dist/ShopCardsSection.cjs +6 -19
- package/dist/ShopCardsSection.js +54 -100
- package/dist/SimpleCategoriesSection.cjs +3 -3
- package/dist/SimpleCategoriesSection.js +64 -67
- package/dist/SimpleProductsSection.cjs +7 -7
- package/dist/SimpleProductsSection.js +65 -138
- package/dist/UrgentSaleProductsSection.cjs +1 -1
- package/dist/UrgentSaleProductsSection.js +1 -1
- package/dist/index-B7fBsitY.js +45 -0
- package/dist/index-BMAvJQBG.cjs +9 -0
- package/dist/index-BUdvfHpp.cjs +5 -0
- package/dist/index-BXT1eY2D.js +753 -0
- package/dist/index-C6amCwRZ.js +25 -0
- package/dist/index-C8R9lsWG.cjs +1 -0
- package/dist/index-CeQvy566.cjs +11 -0
- package/dist/index-Cyt4EUZ6.js +20 -0
- package/dist/index-D3QZziO_.cjs +368 -0
- package/dist/index-VTkAaA-n.js +18 -0
- package/dist/style-BFPpppS9.js +73 -0
- package/dist/style-CQdEALKR.cjs +59 -0
- package/package.json +1 -1
- package/dist/index-BGNavrtB.cjs +0 -368
- package/dist/index-BHcrzV2G.js +0 -54
- package/dist/index-Bj1KWOV4.cjs +0 -11
- package/dist/index-BsAddfgC.cjs +0 -1
- package/dist/index-Cn4bq6ZX.js +0 -84
- package/dist/index-CuRcxKQH.js +0 -42
- package/dist/index-DB1J-G6Z.js +0 -38
- package/dist/index-DkPva6Gr.cjs +0 -20
- package/dist/index-fzBXDy05.cjs +0 -16
- package/dist/index-gFZSZLba.js +0 -882
- package/dist/style-DvkivBNg.js +0 -74
- package/dist/style-Ito6YFqi.cjs +0 -64
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const t=require("react/jsx-runtime"),
|
|
1
|
+
"use strict";const t=require("react/jsx-runtime"),_=require("react"),m=require("./Button.cjs"),N=require("./index-D4-_TrSn.cjs"),$=require("./utils-CITgSxXe.cjs"),g=require("./emotion-styled.browser.esm-DwHBgTPn.cjs"),u=require("./breakpoints-CcVm-gVm.cjs"),h=require("./style-CQdEALKR.cjs"),q=g.styled.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
flex-direction: column;
|
|
4
4
|
align-items: flex-start;
|
|
@@ -60,14 +60,14 @@
|
|
|
60
60
|
|
|
61
61
|
& .wrapper__cards {
|
|
62
62
|
display: grid;
|
|
63
|
-
grid-template-columns: ${
|
|
63
|
+
grid-template-columns: ${i=>`repeat(${i==null?void 0:i.limitCards}, minmax(0, 1fr))`};
|
|
64
64
|
gap: 1.25rem;
|
|
65
65
|
justify-items: center;
|
|
66
66
|
align-items: center;
|
|
67
67
|
width: 100%;
|
|
68
68
|
}
|
|
69
69
|
|
|
70
|
-
@media ${
|
|
70
|
+
@media ${u.down("M")} {
|
|
71
71
|
& .wrapper__cards {
|
|
72
72
|
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
73
73
|
}
|
|
@@ -89,7 +89,7 @@
|
|
|
89
89
|
display: none;
|
|
90
90
|
}
|
|
91
91
|
|
|
92
|
-
@media ${
|
|
92
|
+
@media ${u.down("S")} {
|
|
93
93
|
gap: 1.25rem;
|
|
94
94
|
|
|
95
95
|
& .wrapper__view-all {
|
|
@@ -109,7 +109,7 @@
|
|
|
109
109
|
& .wrapper__cards {
|
|
110
110
|
gap: 1rem;
|
|
111
111
|
|
|
112
|
-
${
|
|
112
|
+
${i=>i!=null&&i.gridView?`
|
|
113
113
|
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
114
114
|
& > div {
|
|
115
115
|
min-width:100%;
|
|
@@ -134,17 +134,4 @@
|
|
|
134
134
|
}`}
|
|
135
135
|
}
|
|
136
136
|
}
|
|
137
|
-
`,
|
|
138
|
-
@media ${p.down("S")} {
|
|
139
|
-
& > div {
|
|
140
|
-
background: linear-gradient(
|
|
141
|
-
to right,
|
|
142
|
-
transparent 0%,
|
|
143
|
-
#f4f6fb 10%,
|
|
144
|
-
#f4f6fb 100%
|
|
145
|
-
);
|
|
146
|
-
|
|
147
|
-
box-shadow: none;
|
|
148
|
-
}
|
|
149
|
-
}
|
|
150
|
-
`,z=({keyPrefix:r})=>t.jsxs(q,{children:[t.jsx(s.SkeletonLinePlaceholder,{height:"18rem",borderRadius:"0.75rem"},`${r}-1`),t.jsx(s.SkeletonLinePlaceholder,{height:"18rem",borderRadius:"0.75rem"},`${r}-2`),t.jsx(s.SkeletonLinePlaceholder,{height:"18rem",borderRadius:"0.75rem"},`${r}-3`),t.jsx(s.SkeletonLinePlaceholder,{height:"18rem",borderRadius:"0.75rem"},`${r}-4`)]}),M=({keyPrefix:r,isLoading:l=!1,fallbackComponent:i=t.jsx(t.Fragment,{}),children:n})=>t.jsx(g.Suspense,{fallbackComponent:i,children:l===!0?t.jsx(z,{keyPrefix:r}):n}),P=g.forwardRef(({title:r,subtitle:l,items:i,isLoading:n=!1,limit:w=4,limitForMobile:_=2,buttonText:m="Show More",onSelectCard:x=()=>{},onButtonAction:o=()=>{},icon:u,getImage:c=()=>{},getProductImage:d=()=>{},hideProducts:b=!1,showRating:y=!0,gridView:a=!1,componentName:v,LinkComponent:j},S)=>t.jsxs(N,{ref:S,limitCards:w,limitCardsForMobile:_,gridView:a,children:[t.jsxs("div",{className:"wrapper__heading",children:[t.jsxs("div",{className:"wrapper__title",children:[r&&t.jsxs("div",{className:"title__text",children:[R.isDefinedNotEmptyString(u)&&t.jsx("i",{className:u}),t.jsx("span",{children:r})]}),o&&!n&&t.jsx(h,{text:m,color:"neutral",borderRadius:"curved",btnType:"tinted",className:`title__action ${a?"grid":""}`,onClick:o})]}),l&&t.jsx("div",{className:"wrapper__subtitle",children:l})]}),t.jsx(M,{isLoading:n,keyPrefix:"shop-cards-skeleton",children:t.jsx("div",{className:"wrapper__cards",children:i==null?void 0:i.map((e,k)=>t.jsx($.ShopCard,{showRating:y,uuid:e==null?void 0:e.uuid,title:e==null?void 0:e.name,subtitle:e==null?void 0:e.shortDescription,rating:e==null?void 0:e.ratingArithmeticMean,reviewCount:e==null?void 0:e.reviewCount,products:e==null?void 0:e.products,imageComponent:e==null?void 0:e.imageComponent,onSelectCard:(F,C)=>x(e==null?void 0:e.uuid,C),image:c(e==null?void 0:e.profileImage,e==null?void 0:e.uuid)||null,getProductImage:d,canAcceptPayments:e==null?void 0:e.canAcceptPayments,hideProducts:b,metadata:{name:v,accessor:e==null?void 0:e.accessor},LinkComponent:j},`shop-card__${k+1}`))})}),a&&o&&!n&&t.jsx(h,{text:m,borderRadius:"curved",btnType:"basic",color:"neutral",className:"wrapper__view-all",onClick:o})]}));module.exports=P;
|
|
137
|
+
`,R=g.styled(h.SkeletonContainer)``,z=({keyPrefix:i})=>t.jsx(R,{children:[1,2,3,4].map(n=>t.jsx(h.SkeletonRect,{height:"18rem",width:"100%"},`${i}-${n}`))}),M=({keyPrefix:i,isLoading:n=!1,fallbackComponent:r=t.jsx(t.Fragment,{}),children:s})=>t.jsx(_.Suspense,{fallbackComponent:r,children:n===!0?t.jsx(z,{keyPrefix:i}):s}),F=_.forwardRef(({title:i,subtitle:n,items:r,isLoading:s=!1,limit:w=4,limitForMobile:f=2,buttonText:a="Show More",onSelectCard:x=()=>{},onButtonAction:l=()=>{},icon:p,getImage:c=()=>{},getProductImage:y=()=>{},hideProducts:v=!1,showRating:d=!0,gridView:o=!1,componentName:b,LinkComponent:j},C)=>t.jsxs(q,{ref:C,limitCards:w,limitCardsForMobile:f,gridView:o,children:[t.jsxs("div",{className:"wrapper__heading",children:[t.jsxs("div",{className:"wrapper__title",children:[i&&t.jsxs("div",{className:"title__text",children:[$.isDefinedNotEmptyString(p)&&t.jsx("i",{className:p}),t.jsx("span",{children:i})]}),l&&!s&&t.jsx(m,{text:a,color:"neutral",borderRadius:"curved",btnType:"tinted",className:`title__action ${o?"grid":""}`,onClick:l})]}),n&&t.jsx("div",{className:"wrapper__subtitle",children:n})]}),t.jsx(M,{isLoading:s,keyPrefix:"shop-cards-skeleton",children:t.jsx("div",{className:"wrapper__cards",children:r==null?void 0:r.map((e,S)=>t.jsx(N.ShopCard,{showRating:d,uuid:e==null?void 0:e.uuid,title:e==null?void 0:e.name,subtitle:e==null?void 0:e.shortDescription,rating:e==null?void 0:e.ratingArithmeticMean,reviewCount:e==null?void 0:e.reviewCount,products:e==null?void 0:e.products,imageComponent:e==null?void 0:e.imageComponent,onSelectCard:(P,k)=>x(e==null?void 0:e.uuid,k),image:c(e==null?void 0:e.profileImage,e==null?void 0:e.uuid)||null,getProductImage:y,canAcceptPayments:e==null?void 0:e.canAcceptPayments,hideProducts:v,metadata:{name:b,accessor:e==null?void 0:e.accessor},LinkComponent:j},`shop-card__${S+1}`))})}),o&&l&&!s&&t.jsx(m,{text:a,borderRadius:"curved",btnType:"basic",color:"neutral",className:"wrapper__view-all",onClick:l})]}));module.exports=F;
|
package/dist/ShopCardsSection.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Suspense as
|
|
3
|
-
import
|
|
1
|
+
import { jsx as i, Fragment as N, jsxs as a } from "react/jsx-runtime";
|
|
2
|
+
import { Suspense as $, forwardRef as j } from "react";
|
|
3
|
+
import f from "./Button.js";
|
|
4
4
|
import { S as z } from "./index-Dx2hfxCG.js";
|
|
5
5
|
import { l as M } from "./utils-MoGhNMmj.js";
|
|
6
6
|
import { s as g } from "./emotion-styled.browser.esm-DfbrHHed.js";
|
|
7
|
-
import { d as
|
|
8
|
-
import {
|
|
9
|
-
const
|
|
7
|
+
import { d as u } from "./breakpoints-BubDitvo.js";
|
|
8
|
+
import { c as R, a as F } from "./style-BFPpppS9.js";
|
|
9
|
+
const P = g.div`
|
|
10
10
|
display: flex;
|
|
11
11
|
flex-direction: column;
|
|
12
12
|
align-items: flex-start;
|
|
@@ -75,7 +75,7 @@ const D = g.div`
|
|
|
75
75
|
width: 100%;
|
|
76
76
|
}
|
|
77
77
|
|
|
78
|
-
@media ${
|
|
78
|
+
@media ${u("M")} {
|
|
79
79
|
& .wrapper__cards {
|
|
80
80
|
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
81
81
|
}
|
|
@@ -97,7 +97,7 @@ const D = g.div`
|
|
|
97
97
|
display: none;
|
|
98
98
|
}
|
|
99
99
|
|
|
100
|
-
@media ${
|
|
100
|
+
@media ${u("S")} {
|
|
101
101
|
gap: 1.25rem;
|
|
102
102
|
|
|
103
103
|
& .wrapper__view-all {
|
|
@@ -142,117 +142,71 @@ const D = g.div`
|
|
|
142
142
|
}`}
|
|
143
143
|
}
|
|
144
144
|
}
|
|
145
|
-
`,
|
|
146
|
-
@media ${m("S")} {
|
|
147
|
-
& > div {
|
|
148
|
-
background: linear-gradient(
|
|
149
|
-
to right,
|
|
150
|
-
transparent 0%,
|
|
151
|
-
#f4f6fb 10%,
|
|
152
|
-
#f4f6fb 100%
|
|
153
|
-
);
|
|
154
|
-
|
|
155
|
-
box-shadow: none;
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
|
-
`, I = ({ keyPrefix: t }) => /* @__PURE__ */ l(E, { children: [
|
|
159
|
-
/* @__PURE__ */ r(
|
|
160
|
-
s,
|
|
161
|
-
{
|
|
162
|
-
height: "18rem",
|
|
163
|
-
borderRadius: "0.75rem"
|
|
164
|
-
},
|
|
165
|
-
`${t}-1`
|
|
166
|
-
),
|
|
167
|
-
/* @__PURE__ */ r(
|
|
168
|
-
s,
|
|
169
|
-
{
|
|
170
|
-
height: "18rem",
|
|
171
|
-
borderRadius: "0.75rem"
|
|
172
|
-
},
|
|
173
|
-
`${t}-2`
|
|
174
|
-
),
|
|
175
|
-
/* @__PURE__ */ r(
|
|
176
|
-
s,
|
|
177
|
-
{
|
|
178
|
-
height: "18rem",
|
|
179
|
-
borderRadius: "0.75rem"
|
|
180
|
-
},
|
|
181
|
-
`${t}-3`
|
|
182
|
-
),
|
|
183
|
-
/* @__PURE__ */ r(
|
|
184
|
-
s,
|
|
185
|
-
{
|
|
186
|
-
height: "18rem",
|
|
187
|
-
borderRadius: "0.75rem"
|
|
188
|
-
},
|
|
189
|
-
`${t}-4`
|
|
190
|
-
)
|
|
191
|
-
] }), W = ({
|
|
145
|
+
`, D = g(R)``, E = ({ keyPrefix: t }) => /* @__PURE__ */ i(D, { children: [1, 2, 3, 4].map((r) => /* @__PURE__ */ i(F, { height: "18rem", width: "100%" }, `${t}-${r}`)) }), I = ({
|
|
192
146
|
keyPrefix: t,
|
|
193
|
-
isLoading:
|
|
194
|
-
fallbackComponent:
|
|
147
|
+
isLoading: r = !1,
|
|
148
|
+
fallbackComponent: l = /* @__PURE__ */ i(N, {}),
|
|
195
149
|
children: n
|
|
196
|
-
}) => /* @__PURE__ */
|
|
150
|
+
}) => /* @__PURE__ */ i($, { fallbackComponent: l, children: r === !0 ? /* @__PURE__ */ i(E, { keyPrefix: t }) : n }), Q = j(
|
|
197
151
|
({
|
|
198
152
|
title: t,
|
|
199
|
-
subtitle:
|
|
200
|
-
items:
|
|
153
|
+
subtitle: r,
|
|
154
|
+
items: l,
|
|
201
155
|
isLoading: n = !1,
|
|
202
|
-
limit:
|
|
156
|
+
limit: h = 4,
|
|
203
157
|
limitForMobile: _ = 2,
|
|
204
|
-
buttonText:
|
|
205
|
-
onSelectCard:
|
|
158
|
+
buttonText: p = "Show More",
|
|
159
|
+
onSelectCard: w = () => {
|
|
206
160
|
},
|
|
207
|
-
onButtonAction:
|
|
161
|
+
onButtonAction: o = () => {
|
|
208
162
|
},
|
|
209
|
-
icon:
|
|
210
|
-
getImage:
|
|
163
|
+
icon: m,
|
|
164
|
+
getImage: c = () => {
|
|
211
165
|
},
|
|
212
|
-
getProductImage:
|
|
166
|
+
getProductImage: y = () => {
|
|
213
167
|
},
|
|
214
168
|
hideProducts: v = !1,
|
|
215
|
-
showRating:
|
|
216
|
-
gridView:
|
|
217
|
-
componentName:
|
|
218
|
-
LinkComponent:
|
|
219
|
-
}, C) => /* @__PURE__ */
|
|
220
|
-
|
|
169
|
+
showRating: x = !0,
|
|
170
|
+
gridView: s = !1,
|
|
171
|
+
componentName: d,
|
|
172
|
+
LinkComponent: b
|
|
173
|
+
}, C) => /* @__PURE__ */ a(
|
|
174
|
+
P,
|
|
221
175
|
{
|
|
222
176
|
ref: C,
|
|
223
|
-
limitCards:
|
|
177
|
+
limitCards: h,
|
|
224
178
|
limitCardsForMobile: _,
|
|
225
|
-
gridView:
|
|
179
|
+
gridView: s,
|
|
226
180
|
children: [
|
|
227
|
-
/* @__PURE__ */
|
|
228
|
-
/* @__PURE__ */
|
|
229
|
-
t && /* @__PURE__ */
|
|
230
|
-
M(
|
|
231
|
-
/* @__PURE__ */
|
|
181
|
+
/* @__PURE__ */ a("div", { className: "wrapper__heading", children: [
|
|
182
|
+
/* @__PURE__ */ a("div", { className: "wrapper__title", children: [
|
|
183
|
+
t && /* @__PURE__ */ a("div", { className: "title__text", children: [
|
|
184
|
+
M(m) && /* @__PURE__ */ i("i", { className: m }),
|
|
185
|
+
/* @__PURE__ */ i("span", { children: t })
|
|
232
186
|
] }),
|
|
233
|
-
|
|
234
|
-
|
|
187
|
+
o && !n && /* @__PURE__ */ i(
|
|
188
|
+
f,
|
|
235
189
|
{
|
|
236
|
-
text:
|
|
190
|
+
text: p,
|
|
237
191
|
color: "neutral",
|
|
238
192
|
borderRadius: "curved",
|
|
239
193
|
btnType: "tinted",
|
|
240
|
-
className: `title__action ${
|
|
241
|
-
onClick:
|
|
194
|
+
className: `title__action ${s ? "grid" : ""}`,
|
|
195
|
+
onClick: o
|
|
242
196
|
}
|
|
243
197
|
)
|
|
244
198
|
] }),
|
|
245
|
-
|
|
199
|
+
r && /* @__PURE__ */ i("div", { className: "wrapper__subtitle", children: r })
|
|
246
200
|
] }),
|
|
247
|
-
/* @__PURE__ */
|
|
248
|
-
|
|
201
|
+
/* @__PURE__ */ i(
|
|
202
|
+
I,
|
|
249
203
|
{
|
|
250
204
|
isLoading: n,
|
|
251
205
|
keyPrefix: "shop-cards-skeleton",
|
|
252
|
-
children: /* @__PURE__ */
|
|
206
|
+
children: /* @__PURE__ */ i("div", { className: "wrapper__cards", children: l == null ? void 0 : l.map((e, S) => /* @__PURE__ */ i(
|
|
253
207
|
z,
|
|
254
208
|
{
|
|
255
|
-
showRating:
|
|
209
|
+
showRating: x,
|
|
256
210
|
uuid: e == null ? void 0 : e.uuid,
|
|
257
211
|
title: e == null ? void 0 : e.name,
|
|
258
212
|
subtitle: e == null ? void 0 : e.shortDescription,
|
|
@@ -260,27 +214,27 @@ const D = g.div`
|
|
|
260
214
|
reviewCount: e == null ? void 0 : e.reviewCount,
|
|
261
215
|
products: e == null ? void 0 : e.products,
|
|
262
216
|
imageComponent: e == null ? void 0 : e.imageComponent,
|
|
263
|
-
onSelectCard: (
|
|
264
|
-
image:
|
|
265
|
-
getProductImage:
|
|
217
|
+
onSelectCard: (T, k) => w(e == null ? void 0 : e.uuid, k),
|
|
218
|
+
image: c(e == null ? void 0 : e.profileImage, e == null ? void 0 : e.uuid) || null,
|
|
219
|
+
getProductImage: y,
|
|
266
220
|
canAcceptPayments: e == null ? void 0 : e.canAcceptPayments,
|
|
267
221
|
hideProducts: v,
|
|
268
|
-
metadata: { name:
|
|
269
|
-
LinkComponent:
|
|
222
|
+
metadata: { name: d, accessor: e == null ? void 0 : e.accessor },
|
|
223
|
+
LinkComponent: b
|
|
270
224
|
},
|
|
271
|
-
`shop-card__${
|
|
225
|
+
`shop-card__${S + 1}`
|
|
272
226
|
)) })
|
|
273
227
|
}
|
|
274
228
|
),
|
|
275
|
-
|
|
276
|
-
|
|
229
|
+
s && o && !n && /* @__PURE__ */ i(
|
|
230
|
+
f,
|
|
277
231
|
{
|
|
278
|
-
text:
|
|
232
|
+
text: p,
|
|
279
233
|
borderRadius: "curved",
|
|
280
234
|
btnType: "basic",
|
|
281
235
|
color: "neutral",
|
|
282
236
|
className: "wrapper__view-all",
|
|
283
|
-
onClick:
|
|
237
|
+
onClick: o
|
|
284
238
|
}
|
|
285
239
|
)
|
|
286
240
|
]
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const
|
|
1
|
+
"use strict";const t=require("react/jsx-runtime"),c=require("react"),f=require("./emotion-styled.browser.esm-DwHBgTPn.cjs"),m=require("./breakpoints-CcVm-gVm.cjs"),C=require("./useDetectMobile-DYV6V1yw.cjs"),d=require("./utils-CITgSxXe.cjs"),v=require("./style-Boz6dk5s.cjs"),z=require("./Button.cjs"),N=require("./CategorySimpleCard-lIdzBNDa.cjs"),r=require("./style-CQdEALKR.cjs"),$=f.styled.div`
|
|
2
2
|
display: grid;
|
|
3
3
|
grid-template-columns: ${()=>"repeat(6, minmax(0, 1fr))"};
|
|
4
4
|
gap: 2rem;
|
|
@@ -26,10 +26,10 @@
|
|
|
26
26
|
/* Safari and Chrome */
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
|
-
`,f
|
|
29
|
+
`,M=f.styled(r.SkeletonAnimationColumnContainer)`
|
|
30
30
|
@media ${m.down("S")} {
|
|
31
31
|
& .skeleton__cards {
|
|
32
32
|
overflow-x: hidden;
|
|
33
33
|
}
|
|
34
34
|
}
|
|
35
|
-
`,
|
|
35
|
+
`,_=({keyPrefix:s})=>t.jsx(M,{children:[1,2].map(l=>t.jsxs(r.SkeletonContainer,{className:"skeleton__cards",children:[t.jsx(r.SkeletonSquare,{size:"8.25rem"}),t.jsx(r.SkeletonSquare,{size:"8.25rem"}),t.jsx(r.SkeletonSquare,{size:"8.25rem"}),t.jsx(r.SkeletonSquare,{size:"8.25rem"}),t.jsx(r.SkeletonSquare,{size:"8.25rem"}),t.jsx(r.SkeletonSquare,{size:"8.25rem"})]},`${s}-${l}`))}),D=({keyPrefix:s,isLoading:l=!1,fallbackComponent:a=t.jsx(t.Fragment,{}),children:u})=>t.jsx(c.Suspense,{fallbackComponent:a,children:l===!0?t.jsx(_,{keyPrefix:s}):u}),y=c.memo(N.CategorySimpleCard),R=c.forwardRef((s,l)=>{const{icon:a,title:u="Shop by category",items:n,buttonText:p="Shop now",buttonLink:S,limit:g=12,onButtonAction:h=()=>{},onSelectCard:i=()=>{},isLoading:j=!1,getImage:k=()=>{},LinkComponent:b}=s,q=C.useDetectMobile(),w=c.useMemo(()=>t.jsx(t.Fragment,{children:q===!0?n==null?void 0:n.map((e,o)=>t.jsx(y,{uuid:e==null?void 0:e.uuid,image:k(e==null?void 0:e.image)||null,name:e==null?void 0:e.name,code:e==null?void 0:e.code,onSelectCard:()=>i==null?void 0:i(e==null?void 0:e.uuid),LinkComponent:b,...e},o)):n==null?void 0:n.slice(0,g).map((e,o)=>t.jsx(y,{uuid:e==null?void 0:e.uuid,image:k(e==null?void 0:e.image)||null,name:e==null?void 0:e.name,code:e==null?void 0:e.code,onSelectCard:()=>i==null?void 0:i(e==null?void 0:e.uuid),LinkComponent:b,...e},o))}),[n]);return t.jsxs(v.RegulatTitleSectionWrapper,{ref:l,children:[t.jsxs("div",{className:"regular-title",children:[t.jsxs("div",{className:"regular-title-text",children:[d.isDefinedNotEmptyString(a)&&t.jsx("i",{className:a}),t.jsx("span",{children:u})]}),d.isDefinedNotEmptyString(p)&&d.isDefinedNotEmptyString(S)&&!j&&t.jsx(z,{type:"button",btnType:"tinted",color:"neutral",onClick:e=>{var o;(o=e==null?void 0:e.target)==null||o.blur(),h(S)},borderRadius:"curved",className:"button-link",children:p})]}),t.jsx(D,{isLoading:j,keyPrefix:"simple-categories-skeleton",children:t.jsx($,{limit:g,children:w})})]})});module.exports=R;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Suspense as
|
|
3
|
-
import { s as
|
|
1
|
+
import { jsx as r, jsxs as m, Fragment as C } from "react/jsx-runtime";
|
|
2
|
+
import { Suspense as N, memo as $, forwardRef as M, useMemo as R } from "react";
|
|
3
|
+
import { s as y } from "./emotion-styled.browser.esm-DfbrHHed.js";
|
|
4
4
|
import { d as u } from "./breakpoints-BubDitvo.js";
|
|
5
|
-
import { u as
|
|
5
|
+
import { u as _ } from "./useDetectMobile-B0Jog4jQ.js";
|
|
6
6
|
import { l as c } from "./utils-MoGhNMmj.js";
|
|
7
|
-
import { R as
|
|
8
|
-
import
|
|
9
|
-
import { C as
|
|
10
|
-
import { b as
|
|
11
|
-
const D =
|
|
7
|
+
import { R as L } from "./style-D54KOzZj.js";
|
|
8
|
+
import T from "./Button.js";
|
|
9
|
+
import { C as j } from "./CategorySimpleCard-TJRJ_2Sb.js";
|
|
10
|
+
import { b as A, c as B, d as n } from "./style-BFPpppS9.js";
|
|
11
|
+
const D = y.div`
|
|
12
12
|
display: grid;
|
|
13
13
|
grid-template-columns: ${() => "repeat(6, minmax(0, 1fr))"};
|
|
14
14
|
gap: 2rem;
|
|
@@ -36,107 +36,104 @@ const D = v.div`
|
|
|
36
36
|
/* Safari and Chrome */
|
|
37
37
|
}
|
|
38
38
|
}
|
|
39
|
-
`, E =
|
|
39
|
+
`, E = y(A)`
|
|
40
40
|
@media ${u("S")} {
|
|
41
41
|
& .skeleton__cards {
|
|
42
42
|
overflow-x: hidden;
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
|
-
`, F = ({ keyPrefix:
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
keyPrefix: t,
|
|
64
|
-
isLoading: s = !1,
|
|
65
|
-
fallbackComponent: m = /* @__PURE__ */ r(C, {}),
|
|
45
|
+
`, F = ({ keyPrefix: a }) => /* @__PURE__ */ r(E, { children: [1, 2].map((l) => /* @__PURE__ */ m(
|
|
46
|
+
B,
|
|
47
|
+
{
|
|
48
|
+
className: "skeleton__cards",
|
|
49
|
+
children: [
|
|
50
|
+
/* @__PURE__ */ r(n, { size: "8.25rem" }),
|
|
51
|
+
/* @__PURE__ */ r(n, { size: "8.25rem" }),
|
|
52
|
+
/* @__PURE__ */ r(n, { size: "8.25rem" }),
|
|
53
|
+
/* @__PURE__ */ r(n, { size: "8.25rem" }),
|
|
54
|
+
/* @__PURE__ */ r(n, { size: "8.25rem" }),
|
|
55
|
+
/* @__PURE__ */ r(n, { size: "8.25rem" })
|
|
56
|
+
]
|
|
57
|
+
},
|
|
58
|
+
`${a}-${l}`
|
|
59
|
+
)) }), I = ({
|
|
60
|
+
keyPrefix: a,
|
|
61
|
+
isLoading: l = !1,
|
|
62
|
+
fallbackComponent: s = /* @__PURE__ */ r(C, {}),
|
|
66
63
|
children: d
|
|
67
|
-
}) => /* @__PURE__ */ r(
|
|
64
|
+
}) => /* @__PURE__ */ r(N, { fallbackComponent: s, children: l === !0 ? /* @__PURE__ */ r(F, { keyPrefix: a }) : d }), k = $(j), V = M((a, l) => {
|
|
68
65
|
const {
|
|
69
|
-
icon:
|
|
66
|
+
icon: s,
|
|
70
67
|
title: d = "Shop by category",
|
|
71
|
-
items:
|
|
72
|
-
buttonText:
|
|
73
|
-
buttonLink:
|
|
74
|
-
limit:
|
|
75
|
-
onButtonAction:
|
|
68
|
+
items: o,
|
|
69
|
+
buttonText: p = "Shop now",
|
|
70
|
+
buttonLink: f,
|
|
71
|
+
limit: g = 12,
|
|
72
|
+
onButtonAction: w = () => {
|
|
76
73
|
},
|
|
77
|
-
onSelectCard:
|
|
74
|
+
onSelectCard: t = () => {
|
|
78
75
|
},
|
|
79
|
-
isLoading:
|
|
80
|
-
getImage:
|
|
76
|
+
isLoading: S = !1,
|
|
77
|
+
getImage: b = () => {
|
|
81
78
|
},
|
|
82
|
-
LinkComponent:
|
|
83
|
-
} =
|
|
84
|
-
|
|
79
|
+
LinkComponent: h
|
|
80
|
+
} = a, v = _(), z = R(() => /* @__PURE__ */ r(C, { children: v === !0 ? o == null ? void 0 : o.map((e, i) => /* @__PURE__ */ r(
|
|
81
|
+
k,
|
|
85
82
|
{
|
|
86
83
|
uuid: e == null ? void 0 : e.uuid,
|
|
87
|
-
image:
|
|
84
|
+
image: b(e == null ? void 0 : e.image) || null,
|
|
88
85
|
name: e == null ? void 0 : e.name,
|
|
89
86
|
code: e == null ? void 0 : e.code,
|
|
90
|
-
onSelectCard: () =>
|
|
91
|
-
LinkComponent:
|
|
87
|
+
onSelectCard: () => t == null ? void 0 : t(e == null ? void 0 : e.uuid),
|
|
88
|
+
LinkComponent: h,
|
|
92
89
|
...e
|
|
93
90
|
},
|
|
94
|
-
|
|
95
|
-
)) :
|
|
96
|
-
|
|
91
|
+
i
|
|
92
|
+
)) : o == null ? void 0 : o.slice(0, g).map((e, i) => /* @__PURE__ */ r(
|
|
93
|
+
k,
|
|
97
94
|
{
|
|
98
95
|
uuid: e == null ? void 0 : e.uuid,
|
|
99
|
-
image:
|
|
96
|
+
image: b(e == null ? void 0 : e.image) || null,
|
|
100
97
|
name: e == null ? void 0 : e.name,
|
|
101
98
|
code: e == null ? void 0 : e.code,
|
|
102
|
-
onSelectCard: () =>
|
|
103
|
-
LinkComponent:
|
|
99
|
+
onSelectCard: () => t == null ? void 0 : t(e == null ? void 0 : e.uuid),
|
|
100
|
+
LinkComponent: h,
|
|
104
101
|
...e
|
|
105
102
|
},
|
|
106
|
-
|
|
107
|
-
)) }), [
|
|
108
|
-
return /* @__PURE__ */
|
|
109
|
-
/* @__PURE__ */
|
|
110
|
-
/* @__PURE__ */
|
|
111
|
-
c(
|
|
103
|
+
i
|
|
104
|
+
)) }), [o]);
|
|
105
|
+
return /* @__PURE__ */ m(L, { ref: l, children: [
|
|
106
|
+
/* @__PURE__ */ m("div", { className: "regular-title", children: [
|
|
107
|
+
/* @__PURE__ */ m("div", { className: "regular-title-text", children: [
|
|
108
|
+
c(s) && /* @__PURE__ */ r("i", { className: s }),
|
|
112
109
|
/* @__PURE__ */ r("span", { children: d })
|
|
113
110
|
] }),
|
|
114
|
-
c(
|
|
115
|
-
|
|
111
|
+
c(p) && c(f) && !S && /* @__PURE__ */ r(
|
|
112
|
+
T,
|
|
116
113
|
{
|
|
117
114
|
type: "button",
|
|
118
115
|
btnType: "tinted",
|
|
119
116
|
color: "neutral",
|
|
120
117
|
onClick: (e) => {
|
|
121
|
-
var
|
|
122
|
-
(
|
|
118
|
+
var i;
|
|
119
|
+
(i = e == null ? void 0 : e.target) == null || i.blur(), w(f);
|
|
123
120
|
},
|
|
124
121
|
borderRadius: "curved",
|
|
125
122
|
className: "button-link",
|
|
126
|
-
children:
|
|
123
|
+
children: p
|
|
127
124
|
}
|
|
128
125
|
)
|
|
129
126
|
] }),
|
|
130
127
|
/* @__PURE__ */ r(
|
|
131
128
|
I,
|
|
132
129
|
{
|
|
133
|
-
isLoading:
|
|
130
|
+
isLoading: S,
|
|
134
131
|
keyPrefix: "simple-categories-skeleton",
|
|
135
|
-
children: /* @__PURE__ */ r(D, { limit:
|
|
132
|
+
children: /* @__PURE__ */ r(D, { limit: g, children: z })
|
|
136
133
|
}
|
|
137
134
|
)
|
|
138
135
|
] });
|
|
139
136
|
});
|
|
140
137
|
export {
|
|
141
|
-
|
|
138
|
+
V as default
|
|
142
139
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const t=require("react/jsx-runtime"),
|
|
1
|
+
"use strict";const t=require("react/jsx-runtime"),l=require("react"),j=require("./emotion-styled.browser.esm-DwHBgTPn.cjs"),s=require("./breakpoints-CcVm-gVm.cjs"),P=require("./useDetectMobile-DYV6V1yw.cjs"),$=require("./index-BkztbBWe.cjs"),F=require("./index-DgUNsgfF.cjs"),i=require("./style-CQdEALKR.cjs"),U=j.styled.div`
|
|
2
2
|
display: grid;
|
|
3
3
|
grid-template-columns: repeat(6, 1fr);
|
|
4
4
|
gap: 1.25rem;
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
}
|
|
11
11
|
|
|
12
12
|
/* Tablet (768–1024px) – text 3/4 left, 1 card top-right, 4 equal product cols below */
|
|
13
|
-
@media ${
|
|
13
|
+
@media ${s.down("M")} {
|
|
14
14
|
grid-template-columns: repeat(4, 1fr);
|
|
15
15
|
grid-template-rows: auto;
|
|
16
16
|
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
}
|
|
35
35
|
|
|
36
36
|
/* Mobile (≤767px) – title full width above, 2-col product grid below */
|
|
37
|
-
@media ${
|
|
37
|
+
@media ${s.down("S")} {
|
|
38
38
|
grid-template-columns: repeat(2, 1fr);
|
|
39
39
|
gap: 1rem;
|
|
40
40
|
|
|
@@ -57,12 +57,12 @@
|
|
|
57
57
|
}
|
|
58
58
|
|
|
59
59
|
/* Small phones (≤480px) – single column */
|
|
60
|
-
@media ${
|
|
60
|
+
@media ${s.down("XS")} {
|
|
61
61
|
grid-template-columns: 1fr;
|
|
62
62
|
gap: 0.75rem;
|
|
63
63
|
}
|
|
64
|
-
`,
|
|
65
|
-
@media ${
|
|
64
|
+
`,_=j.styled(i.SkeletonAnimationColumnContainer)`
|
|
65
|
+
@media ${s.down("S")} {
|
|
66
66
|
& .skeleton__cards {
|
|
67
67
|
& > div {
|
|
68
68
|
width: 100%;
|
|
@@ -74,4 +74,4 @@
|
|
|
74
74
|
}
|
|
75
75
|
}
|
|
76
76
|
}
|
|
77
|
-
`,
|
|
77
|
+
`,z=({keyPrefix:o})=>t.jsx(_,{children:[1,2].map(n=>t.jsxs(i.SkeletonContainer,{className:"skeleton__cards",children:[t.jsx(i.SkeletonRect,{width:"100%",height:"11.125rem"}),t.jsx(i.SkeletonSquare,{size:"11.125rem"}),t.jsx(i.SkeletonSquare,{size:"11.125rem"}),t.jsx(i.SkeletonSquare,{size:"11.125rem"})]},`${o}-${n}`))}),T=({keyPrefix:o,isLoading:n=!1,fallbackComponent:a=t.jsx(t.Fragment,{}),children:c})=>t.jsx(l.Suspense,{fallbackComponent:a,children:n===!0?t.jsx(z,{keyPrefix:o}):c}),k=l.memo($.SimpleProductCard),R=l.forwardRef((o,n)=>{const{title:a,subtitle:c,description:y,buttonText:q,buttonLink:v,items:r,onButtonAction:C=()=>{},isLoading:M=!1,limit:d=6,getImage:m=()=>{},negotiableText:p,freeText:g,componentName:h,LinkComponent:S}=o,w=P.useDetectMobile(),N=l.useMemo(()=>{var b,f;return t.jsx(t.Fragment,{children:w===!0?(b=r==null?void 0:r.slice(0,4))==null?void 0:b.map((e,u)=>t.jsx(k,{title:e==null?void 0:e.name,price:e==null?void 0:e.price,isFree:e==null?void 0:e.isFree,isNegotiable:e==null?void 0:e.isNegotiable,currency:e==null?void 0:e.currency,sellerUuid:e==null?void 0:e.sellerUuid,uuid:e==null?void 0:e.uuid,nameSlug:e==null?void 0:e.nameSlug,image:m(e==null?void 0:e.image,e==null?void 0:e.uuid,e==null?void 0:e.sellerUuid)||null,negotiableText:p,freeText:g,metadata:{name:h,accessor:e==null?void 0:e.accessor},LinkComponent:S},u)):(f=r==null?void 0:r.slice(0,9))==null?void 0:f.map((e,u)=>t.jsx(k,{title:e==null?void 0:e.name,price:e==null?void 0:e.price,isFree:e==null?void 0:e.isFree,isNegotiable:e==null?void 0:e.isNegotiable,currency:e==null?void 0:e.currency,sellerUuid:e==null?void 0:e.sellerUuid,uuid:e==null?void 0:e.uuid,nameSlug:e==null?void 0:e.nameSlug,image:m(e==null?void 0:e.image,e==null?void 0:e.uuid,e==null?void 0:e.sellerUuid)||null,negotiableText:p,freeText:g,metadata:{name:h,accessor:e==null?void 0:e.accessor},LinkComponent:S},u))})},[r,w,d]);return t.jsx(T,{isLoading:M,keyPrefix:"simple-products-skeleton",children:t.jsxs(U,{ref:n,limit:d,children:[t.jsx(F.TextBlockV1,{subtitle:c,title:a,description:y,buttonText:q,buttonLink:v,onButtonAction:C,className:"text-block-v1"}),N]})})});module.exports=R;
|