@lanaco/lnc-react-ui 4.0.183 → 4.0.185
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/BlogCardsSponsoredSection.cjs +5 -3
- package/dist/BlogCardsSponsoredSection.js +68 -64
- package/dist/BlogCategoryCardsSection.cjs +1 -1
- package/dist/BlogCategoryCardsSection.js +1 -1
- package/dist/BlogListSection.cjs +8 -6
- package/dist/BlogListSection.js +122 -114
- package/dist/BlogProductCardsSection.cjs +1 -1
- package/dist/BlogProductCardsSection.js +1 -1
- package/dist/BlogShopCardsSection.cjs +1 -1
- package/dist/BlogShopCardsSection.js +1 -1
- package/dist/BlogSingleSection.cjs +1 -1
- package/dist/BlogSingleSection.js +1 -1
- package/dist/BlogsSectionDetailed.cjs +5 -3
- package/dist/BlogsSectionDetailed.js +53 -49
- package/dist/BlogsSectionLarge.cjs +2 -2
- package/dist/BlogsSectionLarge.js +2 -2
- package/dist/BlogsSectionSimple.cjs +9 -7
- package/dist/BlogsSectionSimple.js +53 -47
- package/dist/BlogsSectionSimpleCentered.cjs +7 -5
- package/dist/BlogsSectionSimpleCentered.js +31 -26
- package/dist/BlogsSectionWithFilters.cjs +9 -7
- package/dist/BlogsSectionWithFilters.js +47 -42
- package/dist/BrandHitsSection.cjs +9 -7
- package/dist/BrandHitsSection.js +40 -35
- package/dist/{CategorySimpleCard-BNYjZQTH.cjs → CategorySimpleCard-D5N8cx0Z.cjs} +4 -3
- package/dist/{CategorySimpleCard-BA0S7TaN.js → CategorySimpleCard-DRQuoxXu.js} +17 -15
- package/dist/CheckBoxInput.cjs +27 -27
- package/dist/CheckBoxInput.js +61 -98
- package/dist/ColorInput.cjs +26 -26
- package/dist/ColorInput.js +127 -162
- package/dist/DetailedProductsInfinitiveSection.cjs +2 -2
- package/dist/DetailedProductsInfinitiveSection.js +6 -5
- package/dist/DetailedProductsSection.cjs +2 -2
- package/dist/DetailedProductsSection.js +12 -10
- package/dist/FieldOfInterestsMasonrySection.cjs +5 -3
- package/dist/FieldOfInterestsMasonrySection.js +90 -85
- package/dist/FieldOfInterestsWithAvatarsCardsSection.cjs +4 -4
- package/dist/FieldOfInterestsWithAvatarsCardsSection.js +49 -46
- package/dist/FieldOfInterestsWithTagsCardsSection.cjs +8 -6
- package/dist/FieldOfInterestsWithTagsCardsSection.js +44 -40
- package/dist/GeneralWithTagsCardsSection.cjs +12 -8
- package/dist/GeneralWithTagsCardsSection.js +50 -44
- package/dist/GiftCardsSection.cjs +7 -5
- package/dist/GiftCardsSection.js +46 -40
- package/dist/MasonryGeneralCardsSection.cjs +6 -5
- package/dist/MasonryGeneralCardsSection.js +26 -23
- package/dist/Modal.cjs +14 -13
- package/dist/Modal.js +88 -86
- package/dist/OverlayGeneralCardsSection.cjs +7 -5
- package/dist/OverlayGeneralCardsSection.js +30 -35
- package/dist/ProductsWithBannerSection.cjs +8 -6
- package/dist/ProductsWithBannerSection.js +71 -77
- package/dist/QuattroCardsSection.cjs +8 -6
- package/dist/QuattroCardsSection.js +31 -28
- package/dist/ReviewsSection.cjs +11 -9
- package/dist/ReviewsSection.js +38 -36
- package/dist/SalesCampaignsSection.cjs +22 -19
- package/dist/SalesCampaignsSection.js +299 -300
- package/dist/ShopCardsSection.cjs +1 -1
- package/dist/ShopCardsSection.js +1 -1
- package/dist/SimpleCategoriesSection.cjs +2 -2
- package/dist/SimpleCategoriesSection.js +7 -3
- package/dist/SimpleProductsSection.cjs +5 -5
- package/dist/SimpleProductsSection.js +62 -72
- package/dist/UrgentSaleProductsSection.cjs +6 -6
- package/dist/UrgentSaleProductsSection.js +9 -7
- package/dist/{index-DoKMLSVY.cjs → index-0p_3g3pT.cjs} +4 -2
- package/dist/{index-Bhfq_YpE.js → index-BipuzfLW.js} +28 -25
- package/dist/{index-CaAhRJ2-.cjs → index-Bmr3IeZ_.cjs} +12 -11
- package/dist/{index-DWLKvVyZ.js → index-C8QkdNHi.js} +27 -23
- package/dist/{index-B8I1mHMA.js → index-CA59z2ge.js} +29 -26
- package/dist/{index-BnYqZk-h.cjs → index-DHV9awrE.cjs} +4 -2
- package/dist/{index-DxZ71UZ1.js → index-DZ8515cZ.js} +144 -137
- package/dist/{index-D55MR8tU.cjs → index-MiN854X_.cjs} +6 -4
- package/package.json +1 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { jsxs as t, jsx as r, Fragment as P } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as W, useRef as
|
|
3
|
-
import { s as
|
|
4
|
-
import { M as
|
|
5
|
-
import { u as
|
|
6
|
-
import { R as
|
|
7
|
-
import { o as
|
|
8
|
-
import { P as
|
|
9
|
-
import { S as o, b as i, a as
|
|
10
|
-
const
|
|
2
|
+
import { forwardRef as W, useRef as C, Suspense as N, memo as U, useMemo as G } from "react";
|
|
3
|
+
import { s as b } from "./emotion-styled.browser.esm-BNN1dTl3.js";
|
|
4
|
+
import { M as f } from "./consts-BuFChS64.js";
|
|
5
|
+
import { u as M } from "./useDetectMobile-Bkvj0VMa.js";
|
|
6
|
+
import { R as _ } from "./style-C7FUSHmS.js";
|
|
7
|
+
import { o as j, l as B, k } from "./utils-Dc5zIpaz.js";
|
|
8
|
+
import { P as I } from "./index-C_NnINik.js";
|
|
9
|
+
import { S as o, b as i, a as c, c as p } from "./style-CXMUA6cI.js";
|
|
10
|
+
const y = b.div`
|
|
11
11
|
width: 100%;
|
|
12
12
|
height: 22.5rem;
|
|
13
13
|
min-height: 22.5rem;
|
|
@@ -25,7 +25,7 @@ const E = f.div`
|
|
|
25
25
|
object-fit: cover;
|
|
26
26
|
}
|
|
27
27
|
|
|
28
|
-
@media (max-width: ${
|
|
28
|
+
@media (max-width: ${f + "px"}) {
|
|
29
29
|
height: 100%;
|
|
30
30
|
min-height: 100%;
|
|
31
31
|
max-height: 100%;
|
|
@@ -40,19 +40,21 @@ const E = f.div`
|
|
|
40
40
|
}
|
|
41
41
|
}
|
|
42
42
|
}
|
|
43
|
-
`,
|
|
43
|
+
`, z = b.div`
|
|
44
44
|
display: grid;
|
|
45
45
|
grid-template-columns: ${(a) => `repeat(${a.limit}, minmax(0, 1fr))`};
|
|
46
46
|
gap: 1.25rem;
|
|
47
47
|
|
|
48
|
-
@media (max-width: ${
|
|
48
|
+
@media (max-width: ${f + "px"}) {
|
|
49
49
|
grid-template-columns: repeat(2, minmax(0, 1fr));
|
|
50
50
|
}
|
|
51
|
-
`,
|
|
51
|
+
`, D = b.a`
|
|
52
52
|
display: flex;
|
|
53
53
|
flex-direction: column;
|
|
54
54
|
gap: 0.5rem;
|
|
55
55
|
cursor: pointer;
|
|
56
|
+
text-decoration: none;
|
|
57
|
+
color: var(--gray-950);
|
|
56
58
|
|
|
57
59
|
& img {
|
|
58
60
|
width: 100%;
|
|
@@ -64,10 +66,10 @@ const E = f.div`
|
|
|
64
66
|
& .card-title {
|
|
65
67
|
font-size: 0.875rem;
|
|
66
68
|
font-weight: 600;
|
|
67
|
-
${
|
|
69
|
+
${j(2)}
|
|
68
70
|
}
|
|
69
71
|
|
|
70
|
-
@media (max-width: ${
|
|
72
|
+
@media (max-width: ${f + "px"}) {
|
|
71
73
|
& img {
|
|
72
74
|
width: 8.875rem;
|
|
73
75
|
height: 8.875rem;
|
|
@@ -78,44 +80,46 @@ const E = f.div`
|
|
|
78
80
|
object-fit: cover;
|
|
79
81
|
}
|
|
80
82
|
}
|
|
81
|
-
`,
|
|
83
|
+
`, E = W((a, s) => {
|
|
82
84
|
const {
|
|
83
|
-
uuid:
|
|
85
|
+
uuid: n,
|
|
84
86
|
title: d,
|
|
85
87
|
image: h,
|
|
86
|
-
sellerUuid:
|
|
87
|
-
onSelectCard:
|
|
88
|
+
sellerUuid: $,
|
|
89
|
+
onSelectCard: R = () => {
|
|
88
90
|
},
|
|
89
91
|
imageComponent: u,
|
|
90
|
-
metadata: m
|
|
91
|
-
|
|
92
|
+
metadata: m,
|
|
93
|
+
nameSlug: l
|
|
94
|
+
} = a, g = C(null);
|
|
92
95
|
return /* @__PURE__ */ t(
|
|
93
|
-
|
|
96
|
+
D,
|
|
94
97
|
{
|
|
95
98
|
ref: g,
|
|
96
99
|
className: "product-card",
|
|
97
100
|
name: m == null ? void 0 : m.name,
|
|
98
101
|
"data-accessor": m == null ? void 0 : m.accessor,
|
|
99
|
-
onClick: (
|
|
102
|
+
onClick: (w) => R(w, s),
|
|
103
|
+
href: `/product/${k(l) ? `${l}-` : ""}${n}`,
|
|
100
104
|
children: [
|
|
101
|
-
|
|
105
|
+
B(u) ? u : /* @__PURE__ */ r(I, { src: h }),
|
|
102
106
|
/* @__PURE__ */ r("div", { className: "card-title", children: d })
|
|
103
107
|
]
|
|
104
108
|
}
|
|
105
109
|
);
|
|
106
|
-
}),
|
|
107
|
-
@media (max-width: ${
|
|
110
|
+
}), L = b(o)`
|
|
111
|
+
@media (max-width: ${f + "px"}) {
|
|
108
112
|
& .skeleton__banner {
|
|
109
113
|
height: 100%;
|
|
110
114
|
aspect-ratio: 1 / 1;
|
|
111
115
|
}
|
|
112
116
|
}
|
|
113
|
-
`,
|
|
117
|
+
`, T = ({ keyPrefix: a }) => /* @__PURE__ */ t(L, { children: [
|
|
114
118
|
/* @__PURE__ */ r(i, { height: "22.5rem", className: "skeleton__banner" }),
|
|
115
|
-
/* @__PURE__ */ t(
|
|
119
|
+
/* @__PURE__ */ t(c, { children: [
|
|
116
120
|
/* @__PURE__ */ t(o, { gap: "0.5rem", children: [
|
|
117
121
|
/* @__PURE__ */ r(
|
|
118
|
-
|
|
122
|
+
p,
|
|
119
123
|
{
|
|
120
124
|
height: "100%",
|
|
121
125
|
width: "100%",
|
|
@@ -123,7 +127,7 @@ const E = f.div`
|
|
|
123
127
|
}
|
|
124
128
|
),
|
|
125
129
|
/* @__PURE__ */ r(o, { height: "1rem", children: /* @__PURE__ */ r(i, { height: "1rem", borderRadius: "0.75rem" }) }),
|
|
126
|
-
/* @__PURE__ */ t(
|
|
130
|
+
/* @__PURE__ */ t(c, { gap: "0.5rem", children: [
|
|
127
131
|
/* @__PURE__ */ r(i, { height: "1.5rem", borderRadius: "0.75rem" }),
|
|
128
132
|
/* @__PURE__ */ r(i, { height: "1.5rem", borderRadius: "0.75rem" })
|
|
129
133
|
] }),
|
|
@@ -136,7 +140,7 @@ const E = f.div`
|
|
|
136
140
|
noGradient: !0,
|
|
137
141
|
children: [
|
|
138
142
|
/* @__PURE__ */ r(
|
|
139
|
-
|
|
143
|
+
p,
|
|
140
144
|
{
|
|
141
145
|
height: "100%",
|
|
142
146
|
width: "100%",
|
|
@@ -144,7 +148,7 @@ const E = f.div`
|
|
|
144
148
|
}
|
|
145
149
|
),
|
|
146
150
|
/* @__PURE__ */ r(i, { height: "1rem", borderRadius: "0.75rem" }),
|
|
147
|
-
/* @__PURE__ */ t(
|
|
151
|
+
/* @__PURE__ */ t(c, { gap: "0.5rem", noGradient: !0, children: [
|
|
148
152
|
/* @__PURE__ */ r(i, { height: "1.5rem", borderRadius: "0.75rem" }),
|
|
149
153
|
/* @__PURE__ */ r(i, { height: "1.5rem", borderRadius: "0.75rem" })
|
|
150
154
|
] }),
|
|
@@ -160,7 +164,7 @@ const E = f.div`
|
|
|
160
164
|
noGradient: !0,
|
|
161
165
|
children: [
|
|
162
166
|
/* @__PURE__ */ r(
|
|
163
|
-
|
|
167
|
+
p,
|
|
164
168
|
{
|
|
165
169
|
height: "100%",
|
|
166
170
|
width: "100%",
|
|
@@ -168,7 +172,7 @@ const E = f.div`
|
|
|
168
172
|
}
|
|
169
173
|
),
|
|
170
174
|
/* @__PURE__ */ r(i, { height: "1rem", borderRadius: "0.75rem" }),
|
|
171
|
-
/* @__PURE__ */ t(
|
|
175
|
+
/* @__PURE__ */ t(c, { gap: "0.5rem", noGradient: !0, children: [
|
|
172
176
|
/* @__PURE__ */ r(i, { height: "1.5rem", borderRadius: "0.75rem" }),
|
|
173
177
|
/* @__PURE__ */ r(i, { height: "1.5rem", borderRadius: "0.75rem" })
|
|
174
178
|
] }),
|
|
@@ -184,7 +188,7 @@ const E = f.div`
|
|
|
184
188
|
noGradient: !0,
|
|
185
189
|
children: [
|
|
186
190
|
/* @__PURE__ */ r(
|
|
187
|
-
|
|
191
|
+
p,
|
|
188
192
|
{
|
|
189
193
|
height: "100%",
|
|
190
194
|
width: "100%",
|
|
@@ -192,7 +196,7 @@ const E = f.div`
|
|
|
192
196
|
}
|
|
193
197
|
),
|
|
194
198
|
/* @__PURE__ */ r(i, { height: "1rem", borderRadius: "0.75rem" }),
|
|
195
|
-
/* @__PURE__ */ t(
|
|
199
|
+
/* @__PURE__ */ t(c, { gap: "0.5rem", noGradient: !0, children: [
|
|
196
200
|
/* @__PURE__ */ r(i, { height: "1.5rem", borderRadius: "0.75rem" }),
|
|
197
201
|
/* @__PURE__ */ r(i, { height: "1.5rem", borderRadius: "0.75rem" })
|
|
198
202
|
] }),
|
|
@@ -202,73 +206,63 @@ const E = f.div`
|
|
|
202
206
|
`${a}-4`
|
|
203
207
|
)
|
|
204
208
|
] })
|
|
205
|
-
] }),
|
|
209
|
+
] }), q = ({
|
|
206
210
|
keyPrefix: a,
|
|
207
|
-
isLoading:
|
|
208
|
-
fallbackComponent:
|
|
211
|
+
isLoading: s = !1,
|
|
212
|
+
fallbackComponent: n = /* @__PURE__ */ r(P, {}),
|
|
209
213
|
children: d
|
|
210
|
-
}) => /* @__PURE__ */ r(
|
|
214
|
+
}) => /* @__PURE__ */ r(N, { fallbackComponent: n, children: s === !0 ? /* @__PURE__ */ r(T, { keyPrefix: a }) : d }), v = U(E), V = W((a, s) => {
|
|
211
215
|
const {
|
|
212
|
-
icon:
|
|
216
|
+
icon: n,
|
|
213
217
|
items: d,
|
|
214
218
|
limit: h = 4,
|
|
215
|
-
imageUrl:
|
|
216
|
-
|
|
219
|
+
imageUrl: $,
|
|
220
|
+
title: R = "Season inspiration",
|
|
221
|
+
isLoading: u = !1,
|
|
222
|
+
getImage: m = () => {
|
|
217
223
|
},
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
},
|
|
222
|
-
componentName: p
|
|
223
|
-
} = a, v = j(), k = _(() => /* @__PURE__ */ r(P, { children: v === !0 ? d == null ? void 0 : d.map((e, w) => /* @__PURE__ */ r(
|
|
224
|
-
$,
|
|
224
|
+
componentName: l
|
|
225
|
+
} = a, g = M(), w = G(() => /* @__PURE__ */ r(P, { children: g === !0 ? d == null ? void 0 : d.map((e, S) => /* @__PURE__ */ r(
|
|
226
|
+
v,
|
|
225
227
|
{
|
|
226
228
|
title: e == null ? void 0 : e.name,
|
|
227
229
|
sellerUuid: e == null ? void 0 : e.sellerUuid,
|
|
228
230
|
uuid: e == null ? void 0 : e.uuid,
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
cardRef: S
|
|
233
|
-
}),
|
|
234
|
-
image: g(e == null ? void 0 : e.image, e == null ? void 0 : e.uuid, e == null ? void 0 : e.sellerUuid) || null,
|
|
235
|
-
metadata: { name: p, accessor: e == null ? void 0 : e.accessor }
|
|
231
|
+
nameSlug: e == null ? void 0 : e.nameSlug,
|
|
232
|
+
image: m(e == null ? void 0 : e.image, e == null ? void 0 : e.uuid, e == null ? void 0 : e.sellerUuid) || null,
|
|
233
|
+
metadata: { name: l, accessor: e == null ? void 0 : e.accessor }
|
|
236
234
|
},
|
|
237
|
-
|
|
238
|
-
)) : d == null ? void 0 : d.slice(0, h).map((e,
|
|
239
|
-
|
|
235
|
+
S
|
|
236
|
+
)) : d == null ? void 0 : d.slice(0, h).map((e, S) => /* @__PURE__ */ r(
|
|
237
|
+
v,
|
|
240
238
|
{
|
|
241
239
|
title: e == null ? void 0 : e.name,
|
|
242
240
|
sellerUuid: e == null ? void 0 : e.sellerUuid,
|
|
243
241
|
uuid: e == null ? void 0 : e.uuid,
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
cardRef: S
|
|
248
|
-
}),
|
|
249
|
-
image: g(e == null ? void 0 : e.image, e == null ? void 0 : e.uuid, e == null ? void 0 : e.sellerUuid) || null,
|
|
250
|
-
metadata: { name: p, accessor: e == null ? void 0 : e.accessor }
|
|
242
|
+
nameSlug: e == null ? void 0 : e.nameSlug,
|
|
243
|
+
image: m(e == null ? void 0 : e.image, e == null ? void 0 : e.uuid, e == null ? void 0 : e.sellerUuid) || null,
|
|
244
|
+
metadata: { name: l, accessor: e == null ? void 0 : e.accessor }
|
|
251
245
|
},
|
|
252
|
-
|
|
253
|
-
)) }), [d,
|
|
254
|
-
return /* @__PURE__ */ t(
|
|
246
|
+
S
|
|
247
|
+
)) }), [d, g, h]);
|
|
248
|
+
return /* @__PURE__ */ t(_, { ref: s, children: [
|
|
255
249
|
/* @__PURE__ */ r("div", { className: "regular-title", children: /* @__PURE__ */ t("div", { className: "regular-title-text", children: [
|
|
256
|
-
|
|
257
|
-
/* @__PURE__ */ r("span", { children:
|
|
250
|
+
k(n) && /* @__PURE__ */ r("i", { className: n }),
|
|
251
|
+
/* @__PURE__ */ r("span", { children: R })
|
|
258
252
|
] }) }),
|
|
259
253
|
/* @__PURE__ */ t(
|
|
260
|
-
|
|
254
|
+
q,
|
|
261
255
|
{
|
|
262
|
-
isLoading:
|
|
256
|
+
isLoading: u,
|
|
263
257
|
keyPrefix: "products-with-banner-skeleton",
|
|
264
258
|
children: [
|
|
265
|
-
/* @__PURE__ */ r(
|
|
266
|
-
/* @__PURE__ */ r(
|
|
259
|
+
/* @__PURE__ */ r(y, { className: "products-banner", children: /* @__PURE__ */ r("img", { src: $ }) }),
|
|
260
|
+
/* @__PURE__ */ r(z, { limit: h, children: w })
|
|
267
261
|
]
|
|
268
262
|
}
|
|
269
263
|
)
|
|
270
264
|
] });
|
|
271
265
|
});
|
|
272
266
|
export {
|
|
273
|
-
|
|
267
|
+
V as default
|
|
274
268
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const e=require("react/jsx-runtime"),n=require("react"),
|
|
1
|
+
"use strict";const e=require("react/jsx-runtime"),n=require("react"),c=require("./utils-RnrgDDZP.cjs"),m=require("./emotion-styled.browser.esm-BtEseadx.cjs"),p=require("./consts-goSZX3xP.cjs"),u=require("./emotion-element-f0de968e.browser.esm-B7k6i6lC.cjs"),_=require("./styled-components.browser.esm-CvykQBGY.cjs"),f=require("./index-D0IYt1s3.cjs"),h=m.styled.div`
|
|
2
2
|
position: absolute;
|
|
3
3
|
top: 0;
|
|
4
4
|
left: 0;
|
|
@@ -41,7 +41,9 @@
|
|
|
41
41
|
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#a6000000', endColorstr='#00000000',GradientType=0 );
|
|
42
42
|
border-radius: 0.75rem;
|
|
43
43
|
z-index: 2;
|
|
44
|
-
`,b=m.styled.
|
|
44
|
+
`,b=m.styled.a`
|
|
45
|
+
text-decoration: none;
|
|
46
|
+
color: var(--gray-950);
|
|
45
47
|
cursor: pointer;
|
|
46
48
|
position: relative;
|
|
47
49
|
border-radius: 0.75rem;
|
|
@@ -79,7 +81,7 @@
|
|
|
79
81
|
font-style: normal;
|
|
80
82
|
font-weight: 600;
|
|
81
83
|
line-height: 1.75rem;
|
|
82
|
-
${
|
|
84
|
+
${c.truncateText()}
|
|
83
85
|
}
|
|
84
86
|
|
|
85
87
|
& .quattro-card__description {
|
|
@@ -87,7 +89,7 @@
|
|
|
87
89
|
font-style: normal;
|
|
88
90
|
font-weight: 500;
|
|
89
91
|
line-height: 1.25rem;
|
|
90
|
-
${
|
|
92
|
+
${c.truncateTextInRows(2)}
|
|
91
93
|
}
|
|
92
94
|
}
|
|
93
95
|
|
|
@@ -108,7 +110,7 @@
|
|
|
108
110
|
display: block;
|
|
109
111
|
}
|
|
110
112
|
}
|
|
111
|
-
`,w=n.forwardRef(({title:
|
|
113
|
+
`,w=n.forwardRef(({title:o,description:t,imageUrl:s,onSelectCard:i=()=>{},link:d},l)=>{const{theme:a}=u.useTheme();return e.jsxs(b,{ref:l,theme:a,onClick:i,href:`/${d}`,children:[e.jsx("img",{loading:"lazy",src:s}),e.jsx(h,{theme:a,className:"quattro-card__gradient",children:e.jsxs("div",{className:"quattro-card__text",children:[e.jsx("div",{className:"quattro-card__title",children:o}),e.jsx("div",{className:"quattro-card__description",children:t})]})})]})}),y=_.qe.div`
|
|
112
114
|
display: flex;
|
|
113
115
|
flex-direction: column;
|
|
114
116
|
align-items: flex-start;
|
|
@@ -162,4 +164,4 @@
|
|
|
162
164
|
gap: 1rem;
|
|
163
165
|
}
|
|
164
166
|
}
|
|
165
|
-
`,
|
|
167
|
+
`,x=n.memo(w),q=n.forwardRef(({title:o,items:t,isLoading:s=!1,onSelectCard:i=()=>{}},d)=>{const l=n.useMemo(()=>{var a;return(a=t==null?void 0:t.slice(0,4))==null?void 0:a.map((r,g)=>e.jsx(x,{title:r==null?void 0:r.title,description:r==null?void 0:r.description,imageUrl:r==null?void 0:r.imageUrl,onSelectCard:()=>i==null?void 0:i(r),link:r==null?void 0:r.link},`quattro-card__${g+1}`))},[t]);return e.jsxs(y,{ref:d,children:[e.jsx("div",{className:"wrapper__heading",children:e.jsx("div",{className:"wrapper__title",children:c.isDefinedNotEmptyString(o)&&e.jsx("div",{className:"title__text",children:e.jsx("span",{children:o})})})}),e.jsx(f.SuspenseBlogCardsSponsored,{isLoading:s,keyPrefix:"quattro-cards-skeleton",children:e.jsx("div",{className:"wrapper__cards",children:l})})]})});module.exports=q;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { forwardRef as c, memo as f, useMemo as
|
|
3
|
-
import { t as
|
|
1
|
+
import { jsxs as l, jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as c, memo as f, useMemo as h } from "react";
|
|
3
|
+
import { t as u, o as _, k as b } from "./utils-Dc5zIpaz.js";
|
|
4
4
|
import { s as m } from "./emotion-styled.browser.esm-BNN1dTl3.js";
|
|
5
5
|
import { M as p } from "./consts-BuFChS64.js";
|
|
6
6
|
import { u as w } from "./emotion-element-f0de968e.browser.esm-CkCiQliQ.js";
|
|
7
7
|
import { q as y } from "./styled-components.browser.esm-D-n22PJk.js";
|
|
8
8
|
import { S as v } from "./index-BSpdEGFd.js";
|
|
9
|
-
const
|
|
9
|
+
const k = m.div`
|
|
10
10
|
position: absolute;
|
|
11
11
|
top: 0;
|
|
12
12
|
left: 0;
|
|
@@ -49,7 +49,9 @@ const x = m.div`
|
|
|
49
49
|
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#a6000000', endColorstr='#00000000',GradientType=0 );
|
|
50
50
|
border-radius: 0.75rem;
|
|
51
51
|
z-index: 2;
|
|
52
|
-
`, q = m.
|
|
52
|
+
`, q = m.a`
|
|
53
|
+
text-decoration: none;
|
|
54
|
+
color: var(--gray-950);
|
|
53
55
|
cursor: pointer;
|
|
54
56
|
position: relative;
|
|
55
57
|
border-radius: 0.75rem;
|
|
@@ -87,7 +89,7 @@ const x = m.div`
|
|
|
87
89
|
font-style: normal;
|
|
88
90
|
font-weight: 600;
|
|
89
91
|
line-height: 1.75rem;
|
|
90
|
-
${
|
|
92
|
+
${u()}
|
|
91
93
|
}
|
|
92
94
|
|
|
93
95
|
& .quattro-card__description {
|
|
@@ -116,15 +118,15 @@ const x = m.div`
|
|
|
116
118
|
display: block;
|
|
117
119
|
}
|
|
118
120
|
}
|
|
119
|
-
`,
|
|
120
|
-
({ title:
|
|
121
|
-
} },
|
|
122
|
-
const { theme:
|
|
123
|
-
return /* @__PURE__ */
|
|
124
|
-
/* @__PURE__ */
|
|
125
|
-
/* @__PURE__ */
|
|
126
|
-
/* @__PURE__ */
|
|
127
|
-
/* @__PURE__ */
|
|
121
|
+
`, x = c(
|
|
122
|
+
({ title: o, description: e, imageUrl: n, onSelectCard: a = () => {
|
|
123
|
+
}, link: s }, d) => {
|
|
124
|
+
const { theme: i } = w();
|
|
125
|
+
return /* @__PURE__ */ l(q, { ref: d, theme: i, onClick: a, href: `/${s}`, children: [
|
|
126
|
+
/* @__PURE__ */ t("img", { loading: "lazy", src: n }),
|
|
127
|
+
/* @__PURE__ */ t(k, { theme: i, className: "quattro-card__gradient", children: /* @__PURE__ */ l("div", { className: "quattro-card__text", children: [
|
|
128
|
+
/* @__PURE__ */ t("div", { className: "quattro-card__title", children: o }),
|
|
129
|
+
/* @__PURE__ */ t("div", { className: "quattro-card__description", children: e })
|
|
128
130
|
] }) })
|
|
129
131
|
] });
|
|
130
132
|
}
|
|
@@ -182,30 +184,31 @@ const x = m.div`
|
|
|
182
184
|
gap: 1rem;
|
|
183
185
|
}
|
|
184
186
|
}
|
|
185
|
-
`, N = f(
|
|
186
|
-
({ title:
|
|
187
|
+
`, N = f(x), S = c(
|
|
188
|
+
({ title: o, items: e, isLoading: n = !1, onSelectCard: a = () => {
|
|
187
189
|
} }, s) => {
|
|
188
|
-
const
|
|
189
|
-
var
|
|
190
|
-
return (
|
|
190
|
+
const d = h(() => {
|
|
191
|
+
var i;
|
|
192
|
+
return (i = e == null ? void 0 : e.slice(0, 4)) == null ? void 0 : i.map((r, g) => /* @__PURE__ */ t(
|
|
191
193
|
N,
|
|
192
194
|
{
|
|
193
|
-
title:
|
|
194
|
-
description:
|
|
195
|
-
imageUrl:
|
|
196
|
-
onSelectCard: () => a == null ? void 0 : a(
|
|
195
|
+
title: r == null ? void 0 : r.title,
|
|
196
|
+
description: r == null ? void 0 : r.description,
|
|
197
|
+
imageUrl: r == null ? void 0 : r.imageUrl,
|
|
198
|
+
onSelectCard: () => a == null ? void 0 : a(r),
|
|
199
|
+
link: r == null ? void 0 : r.link
|
|
197
200
|
},
|
|
198
201
|
`quattro-card__${g + 1}`
|
|
199
202
|
));
|
|
200
203
|
}, [e]);
|
|
201
|
-
return /* @__PURE__ */
|
|
202
|
-
/* @__PURE__ */
|
|
203
|
-
/* @__PURE__ */
|
|
204
|
+
return /* @__PURE__ */ l(z, { ref: s, children: [
|
|
205
|
+
/* @__PURE__ */ t("div", { className: "wrapper__heading", children: /* @__PURE__ */ t("div", { className: "wrapper__title", children: b(o) && /* @__PURE__ */ t("div", { className: "title__text", children: /* @__PURE__ */ t("span", { children: o }) }) }) }),
|
|
206
|
+
/* @__PURE__ */ t(
|
|
204
207
|
v,
|
|
205
208
|
{
|
|
206
209
|
isLoading: n,
|
|
207
210
|
keyPrefix: "quattro-cards-skeleton",
|
|
208
|
-
children: /* @__PURE__ */
|
|
211
|
+
children: /* @__PURE__ */ t("div", { className: "wrapper__cards", children: d })
|
|
209
212
|
}
|
|
210
213
|
)
|
|
211
214
|
] });
|
package/dist/ReviewsSection.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const e=require("react/jsx-runtime"),
|
|
1
|
+
"use strict";const e=require("react/jsx-runtime"),h=require("react"),a=require("./emotion-styled.browser.esm-BtEseadx.cjs"),f=require("./consts-goSZX3xP.cjs"),v=require("./useDetectMobile-zkbzoOGV.cjs"),u=require("./utils-RnrgDDZP.cjs"),k=require("./ThemeProvider.cjs"),s=require("./index-BpbMKBf_.cjs"),R=require("./index-uwl7BjRF.cjs"),i=require("./style-BAcV7F53.cjs"),P=a.styled.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
flex-direction: column;
|
|
4
4
|
color: var(--darkest-950);
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
font-weight: 600;
|
|
9
9
|
font-size: 1.5rem;
|
|
10
10
|
}
|
|
11
|
-
`,$=
|
|
11
|
+
`,$=a.styled.div`
|
|
12
12
|
display: grid;
|
|
13
13
|
grid-template-columns: ${t=>`repeat(${t.limit}, minmax(0, 1fr))`};
|
|
14
14
|
gap: 1.25rem;
|
|
@@ -16,10 +16,12 @@
|
|
|
16
16
|
@media (max-width: ${f.MOBILE_SIZE_PX+"px"}) {
|
|
17
17
|
grid-template-columns: repeat(1, 1fr);
|
|
18
18
|
}
|
|
19
|
-
`,C=
|
|
19
|
+
`,C=a.styled.div`
|
|
20
20
|
padding-top: 5rem;
|
|
21
21
|
overflow: hidden;
|
|
22
|
-
|
|
22
|
+
text-decoration: none;
|
|
23
|
+
color: var(--gray-950);
|
|
24
|
+
`,L=a.styled.div`
|
|
23
25
|
position: relative;
|
|
24
26
|
cursor: pointer;
|
|
25
27
|
display: flex;
|
|
@@ -75,7 +77,7 @@
|
|
|
75
77
|
box-shadow: 0px 10px 15px -3px rgba(0, 0, 0, 0.1),
|
|
76
78
|
0px 4px 6px -2px rgba(0, 0, 0, 0.05);
|
|
77
79
|
}
|
|
78
|
-
`,x=(t,n)=>u.getComponentPropValue(t.theme,"StarRating",t.color,t.disabled===!0?"disabled":"enabled",n),N=
|
|
80
|
+
`,x=(t,n)=>u.getComponentPropValue(t.theme,"StarRating",t.color,t.disabled===!0?"disabled":"enabled",n),N=a.styled.div`
|
|
79
81
|
font-size: ${t=>x(t,"fontSize")};
|
|
80
82
|
line-height: ${t=>x(t,"lineHeight")};
|
|
81
83
|
line-height: 1.5rem;
|
|
@@ -96,7 +98,7 @@
|
|
|
96
98
|
line-height: 1.5rem;
|
|
97
99
|
color: ${t=>t.color};
|
|
98
100
|
}
|
|
99
|
-
`,q=
|
|
101
|
+
`,q=a.styled.span`
|
|
100
102
|
position: absolute;
|
|
101
103
|
z-index: 1;
|
|
102
104
|
display: block;
|
|
@@ -106,12 +108,12 @@
|
|
|
106
108
|
width: ${t=>t.width}%;
|
|
107
109
|
|
|
108
110
|
color: ${t=>u.getColorRgbaValue(t.theme,"StarRating",t.color,t.disabled===!0?"disabled":"enabled","filledColor")};
|
|
109
|
-
`,T=
|
|
111
|
+
`,T=a.styled.span`
|
|
110
112
|
padding: 0;
|
|
111
113
|
display: block;
|
|
112
114
|
z-index: 0;
|
|
113
115
|
color: ${t=>t.color};
|
|
114
|
-
`,S=
|
|
116
|
+
`,S=h.forwardRef((t,n)=>{const{rating:l=0,reviewCount:o=null,disabled:d=!1,tabIndex:c=0,className:p="",style:m={},color:b="primary",size:r="large"}=t,{theme:g}=k.useTheme(),w={theme:g,color:b,size:r,style:m,disabled:d},y=l/5*100;return e.jsxs(N,{ref:n,tabIndex:c,...w,className:`star-rating ${p}`,children:[e.jsxs("div",{className:"rating",children:[e.jsx(q,{className:"filled-stars",...w,width:y,children:"★★★★★"}),e.jsx(T,{...w,children:"★★★★★"})]}),!isNaN(o)&&Number.isFinite(o)&&e.jsx("div",{className:"review-count",children:`(${o.toLocaleString()})`})]})});S.propTypes={rating:s.PropTypes.number,reviewCount:s.PropTypes.any,disabled:s.PropTypes.bool,tabIndex:s.PropTypes.number,style:s.PropTypes.object,className:s.PropTypes.string,color:s.PropTypes.oneOf(["primary","secondary","success","warning","danger","information","neutral"]),size:s.PropTypes.oneOf(["small","medium","large"])};const z=h.forwardRef((t,n)=>{const{image:l,text:o,title:d,link:c,rating:p,onSelectCard:m=()=>{}}=t;return e.jsx(C,{ref:n,className:"review-card",onClick:m,href:`/${c}`,children:e.jsxs(L,{children:[e.jsx(R.ProductImageWrapper,{src:l}),e.jsxs("div",{className:"cont",children:[e.jsx("span",{className:"cont-title",children:d}),e.jsx("div",{className:"cont-text",children:o})]}),e.jsx(S,{color:"warning",rating:p})]})})}),M=a.styled(i.SkeletonRowWrapper)`
|
|
115
117
|
@media (max-width: ${f.MOBILE_SIZE_PX+"px"}) {
|
|
116
118
|
flex-direction: column;
|
|
117
119
|
|
|
@@ -123,4 +125,4 @@
|
|
|
123
125
|
}
|
|
124
126
|
}
|
|
125
127
|
}
|
|
126
|
-
`,I=({keyPrefix:t})=>e.jsxs(M,{children:[e.jsxs(i.SkeletonColumnWrapper,{children:[e.jsx(i.SkeletonSquarePlaceholder,{height:"6.25rem",width:"6.25rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"2rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem",width:"6rem"})]},`${t}-1`),e.jsxs(i.SkeletonColumnWrapper,{noGradient:!0,children:[e.jsx(i.SkeletonSquarePlaceholder,{height:"6.25rem",width:"6.25rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"2rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem",width:"6rem"})]},`${t}-2`),e.jsxs(i.SkeletonColumnWrapper,{noGradient:!0,children:[e.jsx(i.SkeletonSquarePlaceholder,{height:"6.25rem",width:"6.25rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"2rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem",width:"6rem"})]},`${t}-3`)]}),W=({keyPrefix:t,isLoading:n=!1,fallbackComponent:
|
|
128
|
+
`,I=({keyPrefix:t})=>e.jsxs(M,{children:[e.jsxs(i.SkeletonColumnWrapper,{children:[e.jsx(i.SkeletonSquarePlaceholder,{height:"6.25rem",width:"6.25rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"2rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem",width:"6rem"})]},`${t}-1`),e.jsxs(i.SkeletonColumnWrapper,{noGradient:!0,children:[e.jsx(i.SkeletonSquarePlaceholder,{height:"6.25rem",width:"6.25rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"2rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem",width:"6rem"})]},`${t}-2`),e.jsxs(i.SkeletonColumnWrapper,{noGradient:!0,children:[e.jsx(i.SkeletonSquarePlaceholder,{height:"6.25rem",width:"6.25rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"2rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsx(i.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem",width:"6rem"})]},`${t}-3`)]}),W=({keyPrefix:t,isLoading:n=!1,fallbackComponent:l=e.jsx(e.Fragment,{}),children:o})=>e.jsx(h.Suspense,{fallbackComponent:l,children:n===!0?e.jsx(I,{keyPrefix:t}):o}),j=h.memo(z),E=h.forwardRef((t,n)=>{const{title:l="Electronics reviews",items:o,limit:d=3,onSelectCard:c=()=>{},isLoading:p=!1}=t,m=v.useDetectMobile(),b=h.useMemo(()=>e.jsx(e.Fragment,{children:m===!0?o==null?void 0:o.map((r,g)=>e.jsx(j,{text:r==null?void 0:r.text,title:r==null?void 0:r.title,image:r==null?void 0:r.image,link:r==null?void 0:r.link,rating:r==null?void 0:r.ratingArithmeticMean,onSelectCard:()=>c(r)},g)):o==null?void 0:o.slice(0,d).map((r,g)=>e.jsx(j,{text:r==null?void 0:r.text,title:r==null?void 0:r.title,image:r==null?void 0:r.image,link:r==null?void 0:r.link,rating:r==null?void 0:r.ratingArithmeticMean,onSelectCard:()=>c(r)},g))}),[o,m,d]);return e.jsxs(P,{ref:n,children:[e.jsx("div",{className:"container-title",children:l}),e.jsx(W,{isLoading:p,keyPrefix:"reviews-skeleton",children:e.jsx($,{limit:d,children:b})})]})});module.exports=E;
|