@lanaco/lnc-react-ui 4.0.176 → 4.0.178
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/DetailedProductsInfinitiveSection.cjs +2 -2
- package/dist/DetailedProductsInfinitiveSection.js +20 -18
- package/dist/DetailedProductsSection.cjs +2 -2
- package/dist/DetailedProductsSection.js +49 -45
- package/dist/UrgentSaleProductsSection.cjs +2 -2
- package/dist/UrgentSaleProductsSection.js +35 -31
- package/dist/{index-BD-qUr5R.cjs → index-BeVjdODO.cjs} +9 -9
- package/dist/{index-DMnFESGw.js → index-DrtxDu6u.js} +85 -80
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const t=require("react/jsx-runtime"),a=require("react"),M=require("./emotion-styled.browser.esm-BtEseadx.cjs"),B=require("./consts-goSZX3xP.cjs"),E=require("./IconButton.cjs"),I=require("./Button.cjs"),r=require("./utils-RnrgDDZP.cjs"),L=require("./useDetectMobile-zkbzoOGV.cjs"),g=require("./index-
|
|
1
|
+
"use strict";const t=require("react/jsx-runtime"),a=require("react"),M=require("./emotion-styled.browser.esm-BtEseadx.cjs"),B=require("./consts-goSZX3xP.cjs"),E=require("./IconButton.cjs"),I=require("./Button.cjs"),r=require("./utils-RnrgDDZP.cjs"),L=require("./useDetectMobile-zkbzoOGV.cjs"),g=require("./index-BeVjdODO.cjs"),T=M.styled.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
flex-direction: column;
|
|
4
4
|
gap: 1.5rem;
|
|
@@ -70,4 +70,4 @@
|
|
|
70
70
|
}
|
|
71
71
|
}
|
|
72
72
|
}
|
|
73
|
-
`,z=a.memo(g.DetailedProductCard),R=a.forwardRef((n,p)=>{const{title:l,icon:c,items:
|
|
73
|
+
`,z=a.memo(g.DetailedProductCard),R=a.forwardRef((n,p)=>{const{title:l,icon:c,items:i,limit:f=4,isLoading:s=!1,onSelectCard:b=()=>{},onLoadMore:h=()=>{},onButtonAction:w=()=>{},getImage:y=()=>{},viewAllbuttonLink:d,viewAllButonText:m="View all",negotiableText:_,freeText:k,loadMoreButtonIcon:v="angle-down",sponsoredText:C,onBookmark:N=()=>{},actionComponent:S,componentName:j,hasNextPage:q=!1}=n,u=L.useDetectMobile(),P=a.useMemo(()=>i==null?void 0:i.map((e,o)=>t.jsx(z,{name:e==null?void 0:e.name,price:e==null?void 0:e.price,sellingPrice:e==null?void 0:e.sellingPrice,currency:e==null?void 0:e.currency,image:e==null?void 0:e.image,sellerUuid:e==null?void 0:e.sellerUuid,uuid:e==null?void 0:e.uuid,sponsored:e==null?void 0:e.sponsored,imageComponent:e==null?void 0:e.imageComponent,onSelectCard:(U,D)=>b({uuid:e==null?void 0:e.uuid,nameSlug:e==null?void 0:e.nameSlug,cardRef:D}),imageUrl:y(e==null?void 0:e.image,e==null?void 0:e.uuid,e==null?void 0:e.sellerUuid)||null,isFree:e==null?void 0:e.isFree,isNegotiable:e==null?void 0:e.isNegotiable,negotiableText:_,freeText:k,tags:e==null?void 0:e.tags,categoryCode:e==null?void 0:e.categoryCode,condition:e==null?void 0:e.condition,quantity:e==null?void 0:e.quantity,hasQuantities:e==null?void 0:e.hasQuantities,status:e==null?void 0:e.status,trade:e==null?void 0:e.trade,sponsoredText:C,onBookmark:N,actionComponent:S,bookmarked:e==null?void 0:e.bookmarked,bookmarkLists:e==null?void 0:e.bookmarkLists,metadata:{accessor:e==null?void 0:e.accessor,name:j},sellerName:e==null?void 0:e.sellerName,forCart:e==null?void 0:e.forCart,forOrder:e==null?void 0:e.forOrder,contactSeller:e==null?void 0:e.contactSeller,hasVariants:e==null?void 0:e.hasVariants},o)),[i]);return t.jsxs(T,{ref:p,limit:f,children:[t.jsxs("div",{className:"section__heading",children:[r.isDefinedNotEmptyString(l)&&t.jsxs("div",{className:"section__title",children:[r.isDefinedNotEmptyString(c)&&t.jsx("i",{className:c})," ",l]}),u&&r.isDefinedNotEmptyString(d)&&r.isDefinedNotEmptyString(m)&&!s&&t.jsx(I,{type:"button",btnType:"tinted",color:"neutral",onClick:e=>{var o;(o=e==null?void 0:e.target)==null||o.blur(),w(d)},borderRadius:"curved",className:"section__view-all",children:m})]}),t.jsx(g.SuspenseDetailedProductCard,{isLoading:s,keyPrefix:"detailed-product-card-skeleton",children:t.jsx("div",{className:"section__items",children:P})}),!u&&!s&&q&&t.jsx(E,{icon:v,borderRadius:"curved",btnType:"basic",color:"neutral",className:"section__show-more",onClick:h})]})});module.exports=R;
|
|
@@ -4,9 +4,9 @@ import { s as T } from "./emotion-styled.browser.esm-BNN1dTl3.js";
|
|
|
4
4
|
import { M as z } from "./consts-BuFChS64.js";
|
|
5
5
|
import E from "./IconButton.js";
|
|
6
6
|
import U from "./Button.js";
|
|
7
|
-
import { k as
|
|
7
|
+
import { k as r } from "./utils-Dc5zIpaz.js";
|
|
8
8
|
import { u as $ } from "./useDetectMobile-Bkvj0VMa.js";
|
|
9
|
-
import { D as j, S as A } from "./index-
|
|
9
|
+
import { D as j, S as A } from "./index-DrtxDu6u.js";
|
|
10
10
|
const F = T.div`
|
|
11
11
|
display: flex;
|
|
12
12
|
flex-direction: column;
|
|
@@ -88,24 +88,24 @@ const F = T.div`
|
|
|
88
88
|
isLoading: n = !1,
|
|
89
89
|
onSelectCard: g = () => {
|
|
90
90
|
},
|
|
91
|
-
onLoadMore:
|
|
91
|
+
onLoadMore: h = () => {
|
|
92
92
|
},
|
|
93
|
-
onButtonAction:
|
|
93
|
+
onButtonAction: b = () => {
|
|
94
94
|
},
|
|
95
95
|
getImage: w = () => {
|
|
96
96
|
},
|
|
97
97
|
viewAllbuttonLink: m,
|
|
98
98
|
viewAllButonText: d = "View all",
|
|
99
99
|
negotiableText: _,
|
|
100
|
-
freeText:
|
|
101
|
-
loadMoreButtonIcon:
|
|
100
|
+
freeText: y,
|
|
101
|
+
loadMoreButtonIcon: k = "angle-down",
|
|
102
102
|
sponsoredText: v,
|
|
103
103
|
onBookmark: C = () => {
|
|
104
104
|
},
|
|
105
|
-
|
|
105
|
+
actionComponent: N,
|
|
106
106
|
componentName: S,
|
|
107
107
|
hasNextPage: P = !1
|
|
108
|
-
} = a, u = $(), M = L(() => t == null ? void 0 : t.map((e,
|
|
108
|
+
} = a, u = $(), M = L(() => t == null ? void 0 : t.map((e, i) => /* @__PURE__ */ o(
|
|
109
109
|
O,
|
|
110
110
|
{
|
|
111
111
|
name: e == null ? void 0 : e.name,
|
|
@@ -122,15 +122,17 @@ const F = T.div`
|
|
|
122
122
|
isFree: e == null ? void 0 : e.isFree,
|
|
123
123
|
isNegotiable: e == null ? void 0 : e.isNegotiable,
|
|
124
124
|
negotiableText: _,
|
|
125
|
-
freeText:
|
|
125
|
+
freeText: y,
|
|
126
126
|
tags: e == null ? void 0 : e.tags,
|
|
127
127
|
categoryCode: e == null ? void 0 : e.categoryCode,
|
|
128
128
|
condition: e == null ? void 0 : e.condition,
|
|
129
129
|
quantity: e == null ? void 0 : e.quantity,
|
|
130
|
+
hasQuantities: e == null ? void 0 : e.hasQuantities,
|
|
131
|
+
status: e == null ? void 0 : e.status,
|
|
130
132
|
trade: e == null ? void 0 : e.trade,
|
|
131
133
|
sponsoredText: v,
|
|
132
134
|
onBookmark: C,
|
|
133
|
-
|
|
135
|
+
actionComponent: N,
|
|
134
136
|
bookmarked: e == null ? void 0 : e.bookmarked,
|
|
135
137
|
bookmarkLists: e == null ? void 0 : e.bookmarkLists,
|
|
136
138
|
metadata: { accessor: e == null ? void 0 : e.accessor, name: S },
|
|
@@ -140,24 +142,24 @@ const F = T.div`
|
|
|
140
142
|
contactSeller: e == null ? void 0 : e.contactSeller,
|
|
141
143
|
hasVariants: e == null ? void 0 : e.hasVariants
|
|
142
144
|
},
|
|
143
|
-
|
|
145
|
+
i
|
|
144
146
|
)), [t]);
|
|
145
147
|
return /* @__PURE__ */ s(F, { ref: p, limit: f, children: [
|
|
146
148
|
/* @__PURE__ */ s("div", { className: "section__heading", children: [
|
|
147
|
-
|
|
148
|
-
|
|
149
|
+
r(l) && /* @__PURE__ */ s("div", { className: "section__title", children: [
|
|
150
|
+
r(c) && /* @__PURE__ */ o("i", { className: c }),
|
|
149
151
|
" ",
|
|
150
152
|
l
|
|
151
153
|
] }),
|
|
152
|
-
u &&
|
|
154
|
+
u && r(m) && r(d) && !n && /* @__PURE__ */ o(
|
|
153
155
|
U,
|
|
154
156
|
{
|
|
155
157
|
type: "button",
|
|
156
158
|
btnType: "tinted",
|
|
157
159
|
color: "neutral",
|
|
158
160
|
onClick: (e) => {
|
|
159
|
-
var
|
|
160
|
-
(
|
|
161
|
+
var i;
|
|
162
|
+
(i = e == null ? void 0 : e.target) == null || i.blur(), b(m);
|
|
161
163
|
},
|
|
162
164
|
borderRadius: "curved",
|
|
163
165
|
className: "section__view-all",
|
|
@@ -176,12 +178,12 @@ const F = T.div`
|
|
|
176
178
|
!u && !n && P && /* @__PURE__ */ o(
|
|
177
179
|
E,
|
|
178
180
|
{
|
|
179
|
-
icon:
|
|
181
|
+
icon: k,
|
|
180
182
|
borderRadius: "curved",
|
|
181
183
|
btnType: "basic",
|
|
182
184
|
color: "neutral",
|
|
183
185
|
className: "section__show-more",
|
|
184
|
-
onClick:
|
|
186
|
+
onClick: h
|
|
185
187
|
}
|
|
186
188
|
)
|
|
187
189
|
] });
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const t=require("react/jsx-runtime"),c=require("react"),T=require("./emotion-styled.browser.esm-BtEseadx.cjs"),E=require("./consts-goSZX3xP.cjs"),F=require("./Button.cjs"),l=require("./utils-RnrgDDZP.cjs"),B=require("./useDetectMobile-zkbzoOGV.cjs"),R=require("./style-CkcozOY6.cjs"),w=require("./index-
|
|
1
|
+
"use strict";const t=require("react/jsx-runtime"),c=require("react"),T=require("./emotion-styled.browser.esm-BtEseadx.cjs"),E=require("./consts-goSZX3xP.cjs"),F=require("./Button.cjs"),l=require("./utils-RnrgDDZP.cjs"),B=require("./useDetectMobile-zkbzoOGV.cjs"),R=require("./style-CkcozOY6.cjs"),w=require("./index-BeVjdODO.cjs"),I=require("./index-CSNxZFTX.cjs"),Q=T.styled.div`
|
|
2
2
|
display: grid;
|
|
3
3
|
grid-template-columns: ${n=>`repeat(${n.limit}, minmax(0, 1fr))`};
|
|
4
4
|
gap: 1.25rem;
|
|
@@ -26,4 +26,4 @@
|
|
|
26
26
|
/* Safari and Chrome */
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
|
-
`,j=c.memo(w.DetailedProductCard)
|
|
29
|
+
`,j=c.memo(w.DetailedProductCard),_=c.forwardRef((n,P)=>{const{icon:d,title:v,buttonLink:u,items:i,buttonText:m,limit:s=4,onSelectCard:g=()=>{},onButtonAction:D=()=>{},isLoading:p=!1,getImage:b=()=>{},negotiableText:k,freeText:y,options:r,onSelectOption:h=()=>{},productsToolbarName:U="All",sponsoredText:S,onBookmark:C=()=>{},actionComponent:N,componentName:f}=n,q=B.useDetectMobile(),L=c.useMemo(()=>t.jsx(t.Fragment,{children:q===!0?i==null?void 0:i.map((e,o)=>t.jsx(j,{name:e==null?void 0:e.name,price:e==null?void 0:e.price,sellingPrice:e==null?void 0:e.sellingPrice,currency:e==null?void 0:e.currency,image:e==null?void 0:e.image,sellerUuid:e==null?void 0:e.sellerUuid,uuid:e==null?void 0:e.uuid,sponsored:e==null?void 0:e.sponsored,imageComponent:e==null?void 0:e.imageComponent,onSelectCard:(M,a)=>g({uuid:e==null?void 0:e.uuid,nameSlug:e==null?void 0:e.nameSlug,cardRef:a}),sellerName:e==null?void 0:e.sellerName,imageUrl:b(e==null?void 0:e.image,e==null?void 0:e.uuid,e==null?void 0:e.sellerUuid)||null,isFree:e==null?void 0:e.isFree,isNegotiable:e==null?void 0:e.isNegotiable,negotiableText:k,freeText:y,tags:e==null?void 0:e.tags,categoryCode:e==null?void 0:e.categoryCode,condition:e==null?void 0:e.condition,quantity:e==null?void 0:e.quantity,hasQuantities:e==null?void 0:e.hasQuantities,status:e==null?void 0:e.status,trade:e==null?void 0:e.trade,sponsoredText:S,onBookmark:C,actionComponent:N,bookmarked:e==null?void 0:e.bookmarked,bookmarkLists:e==null?void 0:e.bookmarkLists,metadata:{accessor:e==null?void 0:e.accessor,name:f}},o)):i==null?void 0:i.slice(0,s).map((e,o)=>t.jsx(j,{name:e==null?void 0:e.name,price:e==null?void 0:e.price,sellingPrice:e==null?void 0:e.sellingPrice,currency:e==null?void 0:e.currency,image:e==null?void 0:e.image,sellerUuid:e==null?void 0:e.sellerUuid,uuid:e==null?void 0:e.uuid,location:e==null?void 0:e.location,sponsored:e==null?void 0:e.sponsored,imageComponent:e==null?void 0:e.imageComponent,onSelectCard:(M,a)=>g({uuid:e==null?void 0:e.uuid,nameSlug:e==null?void 0:e.nameSlug,cardRef:a}),imageUrl:b(e==null?void 0:e.image,e==null?void 0:e.uuid,e==null?void 0:e.sellerUuid)||null,isFree:e==null?void 0:e.isFree,isNegotiable:e==null?void 0:e.isNegotiable,negotiableText:k,freeText:y,tags:e==null?void 0:e.tags,categoryCode:e==null?void 0:e.categoryCode,condition:e==null?void 0:e.condition,quantity:e==null?void 0:e.quantity,hasQuantities:e==null?void 0:e.hasQuantities,status:e==null?void 0:e.status,trade:e==null?void 0:e.trade,sponsoredText:S,onBookmark:C,actionComponent:N,bookmarked:e==null?void 0:e.bookmarked,bookmarkLists:e==null?void 0:e.bookmarkLists,metadata:{accessor:e==null?void 0:e.accessor,name:f},sellerName:e==null?void 0:e.sellerName},o))}),[i,q,s]);return t.jsxs(R.TitleWithOptionsSectionWrapper,{ref:P,children:[t.jsxs("div",{className:"regular-title",children:[t.jsxs("div",{className:"regular-title-text",children:[l.isDefinedNotEmptyString(d)&&t.jsx("i",{className:d}),t.jsx("span",{children:v})]}),l.isDefinedNotEmptyString(u)&&l.isDefinedNotEmptyString(m)&&!p&&t.jsx(F,{type:"button",btnType:"tinted",color:"neutral",onClick:e=>{var o;(o=e==null?void 0:e.target)==null||o.blur(),D(u)},borderRadius:"curved",className:"button-link",children:m})]}),(r==null?void 0:r.length)>0&&t.jsx(I.SelectBar,{items:r,onRemove:e=>{h(e)},onSelect:e=>{h(e)},labelKey:"name",valueKey:"code",noMargin:!0,productsToolbarName:U}),t.jsx(w.SuspenseDetailedProductCard,{isLoading:p,keyPrefix:"detailed-products-skeleton",children:t.jsx(Q,{limit:s,children:L})})]})});module.exports=_;
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as t, Fragment as F, jsxs as l } from "react/jsx-runtime";
|
|
2
2
|
import { memo as B, forwardRef as q, useMemo as E } from "react";
|
|
3
3
|
import { s as I } from "./emotion-styled.browser.esm-BNN1dTl3.js";
|
|
4
|
-
import { M as
|
|
5
|
-
import
|
|
4
|
+
import { M as Q } from "./consts-BuFChS64.js";
|
|
5
|
+
import O from "./Button.js";
|
|
6
6
|
import { k as m } from "./utils-Dc5zIpaz.js";
|
|
7
|
-
import { u as
|
|
8
|
-
import { T as
|
|
9
|
-
import { D as
|
|
10
|
-
import { S as
|
|
11
|
-
const
|
|
7
|
+
import { u as R } from "./useDetectMobile-Bkvj0VMa.js";
|
|
8
|
+
import { T as W } from "./style-C7FUSHmS.js";
|
|
9
|
+
import { D as $, S as j } from "./index-DrtxDu6u.js";
|
|
10
|
+
import { S as z } from "./index-BGiZlEQt.js";
|
|
11
|
+
const A = I.div`
|
|
12
12
|
display: grid;
|
|
13
13
|
grid-template-columns: ${(a) => `repeat(${a.limit}, minmax(0, 1fr))`};
|
|
14
14
|
gap: 1.25rem;
|
|
@@ -17,7 +17,7 @@ const K = I.div`
|
|
|
17
17
|
white-space: nowrap;
|
|
18
18
|
}
|
|
19
19
|
|
|
20
|
-
@media (max-width: ${
|
|
20
|
+
@media (max-width: ${Q + "px"}) {
|
|
21
21
|
display: flex;
|
|
22
22
|
gap: 1rem;
|
|
23
23
|
overflow-x: auto;
|
|
@@ -36,12 +36,12 @@ const K = I.div`
|
|
|
36
36
|
/* Safari and Chrome */
|
|
37
37
|
}
|
|
38
38
|
}
|
|
39
|
-
`, P = B(
|
|
39
|
+
`, P = B($), ee = q((a, v) => {
|
|
40
40
|
const {
|
|
41
41
|
icon: d,
|
|
42
42
|
title: T,
|
|
43
43
|
buttonLink: c,
|
|
44
|
-
items:
|
|
44
|
+
items: o,
|
|
45
45
|
buttonText: u,
|
|
46
46
|
limit: n = 4,
|
|
47
47
|
onSelectCard: p = () => {
|
|
@@ -53,16 +53,16 @@ const K = I.div`
|
|
|
53
53
|
},
|
|
54
54
|
negotiableText: k,
|
|
55
55
|
freeText: f,
|
|
56
|
-
options:
|
|
56
|
+
options: r,
|
|
57
57
|
onSelectOption: y = () => {
|
|
58
58
|
},
|
|
59
59
|
productsToolbarName: L = "All",
|
|
60
|
-
sponsoredText:
|
|
61
|
-
onBookmark:
|
|
60
|
+
sponsoredText: h,
|
|
61
|
+
onBookmark: S = () => {
|
|
62
62
|
},
|
|
63
|
-
|
|
63
|
+
actionComponent: C,
|
|
64
64
|
componentName: N
|
|
65
|
-
} = a, w =
|
|
65
|
+
} = a, w = R(), M = E(() => /* @__PURE__ */ t(F, { children: w === !0 ? o == null ? void 0 : o.map((e, i) => /* @__PURE__ */ t(
|
|
66
66
|
P,
|
|
67
67
|
{
|
|
68
68
|
name: e == null ? void 0 : e.name,
|
|
@@ -74,10 +74,10 @@ const K = I.div`
|
|
|
74
74
|
uuid: e == null ? void 0 : e.uuid,
|
|
75
75
|
sponsored: e == null ? void 0 : e.sponsored,
|
|
76
76
|
imageComponent: e == null ? void 0 : e.imageComponent,
|
|
77
|
-
onSelectCard: (D,
|
|
77
|
+
onSelectCard: (D, s) => p({
|
|
78
78
|
uuid: e == null ? void 0 : e.uuid,
|
|
79
79
|
nameSlug: e == null ? void 0 : e.nameSlug,
|
|
80
|
-
cardRef:
|
|
80
|
+
cardRef: s
|
|
81
81
|
}),
|
|
82
82
|
sellerName: e == null ? void 0 : e.sellerName,
|
|
83
83
|
imageUrl: b(e == null ? void 0 : e.image, e == null ? void 0 : e.uuid, e == null ? void 0 : e.sellerUuid) || null,
|
|
@@ -89,16 +89,18 @@ const K = I.div`
|
|
|
89
89
|
categoryCode: e == null ? void 0 : e.categoryCode,
|
|
90
90
|
condition: e == null ? void 0 : e.condition,
|
|
91
91
|
quantity: e == null ? void 0 : e.quantity,
|
|
92
|
+
hasQuantities: e == null ? void 0 : e.hasQuantities,
|
|
93
|
+
status: e == null ? void 0 : e.status,
|
|
92
94
|
trade: e == null ? void 0 : e.trade,
|
|
93
|
-
sponsoredText:
|
|
94
|
-
onBookmark:
|
|
95
|
-
|
|
95
|
+
sponsoredText: h,
|
|
96
|
+
onBookmark: S,
|
|
97
|
+
actionComponent: C,
|
|
96
98
|
bookmarked: e == null ? void 0 : e.bookmarked,
|
|
97
99
|
bookmarkLists: e == null ? void 0 : e.bookmarkLists,
|
|
98
100
|
metadata: { accessor: e == null ? void 0 : e.accessor, name: N }
|
|
99
101
|
},
|
|
100
|
-
|
|
101
|
-
)) :
|
|
102
|
+
i
|
|
103
|
+
)) : o == null ? void 0 : o.slice(0, n).map((e, i) => /* @__PURE__ */ t(
|
|
102
104
|
P,
|
|
103
105
|
{
|
|
104
106
|
name: e == null ? void 0 : e.name,
|
|
@@ -111,10 +113,10 @@ const K = I.div`
|
|
|
111
113
|
location: e == null ? void 0 : e.location,
|
|
112
114
|
sponsored: e == null ? void 0 : e.sponsored,
|
|
113
115
|
imageComponent: e == null ? void 0 : e.imageComponent,
|
|
114
|
-
onSelectCard: (D,
|
|
116
|
+
onSelectCard: (D, s) => p({
|
|
115
117
|
uuid: e == null ? void 0 : e.uuid,
|
|
116
118
|
nameSlug: e == null ? void 0 : e.nameSlug,
|
|
117
|
-
cardRef:
|
|
119
|
+
cardRef: s
|
|
118
120
|
}),
|
|
119
121
|
imageUrl: b(e == null ? void 0 : e.image, e == null ? void 0 : e.uuid, e == null ? void 0 : e.sellerUuid) || null,
|
|
120
122
|
isFree: e == null ? void 0 : e.isFree,
|
|
@@ -125,32 +127,34 @@ const K = I.div`
|
|
|
125
127
|
categoryCode: e == null ? void 0 : e.categoryCode,
|
|
126
128
|
condition: e == null ? void 0 : e.condition,
|
|
127
129
|
quantity: e == null ? void 0 : e.quantity,
|
|
130
|
+
hasQuantities: e == null ? void 0 : e.hasQuantities,
|
|
131
|
+
status: e == null ? void 0 : e.status,
|
|
128
132
|
trade: e == null ? void 0 : e.trade,
|
|
129
|
-
sponsoredText:
|
|
130
|
-
onBookmark:
|
|
131
|
-
|
|
133
|
+
sponsoredText: h,
|
|
134
|
+
onBookmark: S,
|
|
135
|
+
actionComponent: C,
|
|
132
136
|
bookmarked: e == null ? void 0 : e.bookmarked,
|
|
133
137
|
bookmarkLists: e == null ? void 0 : e.bookmarkLists,
|
|
134
138
|
metadata: { accessor: e == null ? void 0 : e.accessor, name: N },
|
|
135
139
|
sellerName: e == null ? void 0 : e.sellerName
|
|
136
140
|
},
|
|
137
|
-
|
|
138
|
-
)) }), [
|
|
139
|
-
return /* @__PURE__ */
|
|
140
|
-
/* @__PURE__ */
|
|
141
|
-
/* @__PURE__ */
|
|
142
|
-
m(d) && /* @__PURE__ */
|
|
143
|
-
/* @__PURE__ */
|
|
141
|
+
i
|
|
142
|
+
)) }), [o, w, n]);
|
|
143
|
+
return /* @__PURE__ */ l(W, { ref: v, children: [
|
|
144
|
+
/* @__PURE__ */ l("div", { className: "regular-title", children: [
|
|
145
|
+
/* @__PURE__ */ l("div", { className: "regular-title-text", children: [
|
|
146
|
+
m(d) && /* @__PURE__ */ t("i", { className: d }),
|
|
147
|
+
/* @__PURE__ */ t("span", { children: T })
|
|
144
148
|
] }),
|
|
145
|
-
m(c) && m(u) && !g && /* @__PURE__ */
|
|
146
|
-
|
|
149
|
+
m(c) && m(u) && !g && /* @__PURE__ */ t(
|
|
150
|
+
O,
|
|
147
151
|
{
|
|
148
152
|
type: "button",
|
|
149
153
|
btnType: "tinted",
|
|
150
154
|
color: "neutral",
|
|
151
155
|
onClick: (e) => {
|
|
152
|
-
var
|
|
153
|
-
(
|
|
156
|
+
var i;
|
|
157
|
+
(i = e == null ? void 0 : e.target) == null || i.blur(), U(c);
|
|
154
158
|
},
|
|
155
159
|
borderRadius: "curved",
|
|
156
160
|
className: "button-link",
|
|
@@ -158,10 +162,10 @@ const K = I.div`
|
|
|
158
162
|
}
|
|
159
163
|
)
|
|
160
164
|
] }),
|
|
161
|
-
(
|
|
162
|
-
|
|
165
|
+
(r == null ? void 0 : r.length) > 0 && /* @__PURE__ */ t(
|
|
166
|
+
z,
|
|
163
167
|
{
|
|
164
|
-
items:
|
|
168
|
+
items: r,
|
|
165
169
|
onRemove: (e) => {
|
|
166
170
|
y(e);
|
|
167
171
|
},
|
|
@@ -174,12 +178,12 @@ const K = I.div`
|
|
|
174
178
|
productsToolbarName: L
|
|
175
179
|
}
|
|
176
180
|
),
|
|
177
|
-
/* @__PURE__ */
|
|
178
|
-
|
|
181
|
+
/* @__PURE__ */ t(
|
|
182
|
+
j,
|
|
179
183
|
{
|
|
180
184
|
isLoading: g,
|
|
181
185
|
keyPrefix: "detailed-products-skeleton",
|
|
182
|
-
children: /* @__PURE__ */
|
|
186
|
+
children: /* @__PURE__ */ t(A, { limit: n, children: M })
|
|
183
187
|
}
|
|
184
188
|
)
|
|
185
189
|
] });
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const
|
|
1
|
+
"use strict";const t=require("react/jsx-runtime"),s=require("react"),_=require("./emotion-styled.browser.esm-BtEseadx.cjs"),C=require("./consts-goSZX3xP.cjs"),$=require("./useDetectMobile-zkbzoOGV.cjs"),T=require("./Button.cjs"),N=require("./index-BeVjdODO.cjs"),F=_.styled.div`
|
|
2
2
|
padding: 1.75rem 3rem;
|
|
3
3
|
display: grid;
|
|
4
4
|
grid-template-columns: ${a=>`repeat(${a.limit||5}, minmax(0, 1fr))`};
|
|
@@ -71,4 +71,4 @@
|
|
|
71
71
|
display: flex;
|
|
72
72
|
flex-direction: column;
|
|
73
73
|
}
|
|
74
|
-
`,S=s.memo(N.DetailedProductCard),I=s.forwardRef((a,P)=>{const{items:r,limit:n=5,limitMobile:l=4,onSelectCard:u=()=>{},title:j="Urgent sale",showLessText:q="Show less",showMoreText:L="Show more",isLoading:g=!1,getImage:p=()=>{},negotiableText:b,freeText:
|
|
74
|
+
`,S=s.memo(N.DetailedProductCard),I=s.forwardRef((a,P)=>{const{items:r,limit:n=5,limitMobile:l=4,onSelectCard:u=()=>{},title:j="Urgent sale",showLessText:q="Show less",showMoreText:L="Show more",isLoading:g=!1,getImage:p=()=>{},negotiableText:b,freeText:h,onBookmark:f=()=>{},actionComponent:k,componentName:y,sponsoredText:w}=a,d=$.useDetectMobile(),[i,M]=s.useState(!1),U=s.useMemo(()=>{var o;return t.jsx(t.Fragment,{children:d===!0?(o=r==null?void 0:r.slice(0,i===!0?r==null?void 0:r.length:l))==null?void 0:o.map((e,m)=>t.jsx(S,{sellerName:e==null?void 0:e.sellerName,name:e==null?void 0:e.name,price:e==null?void 0:e.price,sellingPrice:e==null?void 0:e.sellingPrice,isFree:e==null?void 0:e.isFree,isNegotiable:e==null?void 0:e.isNegotiable,currency:e==null?void 0:e.currency,categoryCode:e==null?void 0:e.categoryCode,sellerUuid:e==null?void 0:e.sellerUuid,uuid:e==null?void 0:e.uuid,sponsored:e==null?void 0:e.sponsored,onSelectCard:(v,c)=>u({uuid:e==null?void 0:e.uuid,nameSlug:e==null?void 0:e.nameSlug,cardRef:c}),image:e==null?void 0:e.image,imageUrl:p(e==null?void 0:e.image,e==null?void 0:e.uuid,e==null?void 0:e.sellerUuid)||null,imageComponent:e==null?void 0:e.imageComponent,negotiableText:b,freeText:h,onBookmark:f,actionComponent:k,bookmarked:e==null?void 0:e.bookmarked,bookmarkLists:e==null?void 0:e.bookmarkLists,metadata:{name:y,accessor:e==null?void 0:e.accessor},tags:e==null?void 0:e.tags,condition:e==null?void 0:e.condition,quantity:e==null?void 0:e.quantity,hasQuantities:e==null?void 0:e.hasQuantities,status:e==null?void 0:e.status,trade:e==null?void 0:e.trade,sponsoredText:w},m)):r==null?void 0:r.slice(0,n).map((e,m)=>t.jsx(S,{name:e==null?void 0:e.name,price:e==null?void 0:e.price,sellingPrice:e==null?void 0:e.sellingPrice,isFree:e==null?void 0:e.isFree,isNegotiable:e==null?void 0:e.isNegotiable,currency:e==null?void 0:e.currency,categoryCode:e==null?void 0:e.categoryCode,sellerUuid:e==null?void 0:e.sellerUuid,uuid:e==null?void 0:e.uuid,location:e==null?void 0:e.location,sponsored:e==null?void 0:e.sponsored,onSelectCard:(v,c)=>u({uuid:e==null?void 0:e.uuid,nameSlug:e==null?void 0:e.nameSlug,cardRef:c}),image:e==null?void 0:e.image,imageUrl:p(e==null?void 0:e.image,e==null?void 0:e.uuid,e==null?void 0:e.sellerUuid)||null,imageComponent:e==null?void 0:e.imageComponent,negotiableText:b,freeText:h,onBookmark:f,actionComponent:k,bookmarked:e==null?void 0:e.bookmarked,bookmarkLists:e==null?void 0:e.bookmarkLists,metadata:{name:y,accessor:e==null?void 0:e.accessor},tags:e==null?void 0:e.tags,condition:e==null?void 0:e.condition,quantity:e==null?void 0:e.quantity,hasQuantities:e==null?void 0:e.hasQuantities,status:e==null?void 0:e.status,trade:e==null?void 0:e.trade,sponsoredText:w,sellerName:e==null?void 0:e.sellerName},m))})},[r,d,n,l,i]);return t.jsx(N.SuspenseDetailedProductCard,{isLoading:g,keyPrefix:"urgent-sale-products-skeleton",children:t.jsxs(F,{ref:P,limit:n,children:[t.jsxs("div",{className:"urgent-tag",children:[t.jsx("i",{className:"mng mng-lnc-bolt-filled"}),t.jsx("span",{children:j})]})," ",U," ",d===!0&&l<(r==null?void 0:r.length)&&!g&&t.jsx(T,{className:"show-more",btnType:"basic",type:"button",color:"neutral",onClick:o=>{var e;(e=o==null?void 0:o.target)==null||e.blur(),M(!i)},children:i===!0?q:L})]})})});module.exports=I;
|
|
@@ -3,12 +3,12 @@ import { memo as T, forwardRef as F, useState as I, useMemo as _ } from "react";
|
|
|
3
3
|
import { s as q } from "./emotion-styled.browser.esm-BNN1dTl3.js";
|
|
4
4
|
import { M as B, S as D } from "./consts-BuFChS64.js";
|
|
5
5
|
import { u as E } from "./useDetectMobile-Bkvj0VMa.js";
|
|
6
|
-
import
|
|
7
|
-
import { D as
|
|
8
|
-
const
|
|
6
|
+
import Q from "./Button.js";
|
|
7
|
+
import { D as j, S as z } from "./index-DrtxDu6u.js";
|
|
8
|
+
const A = q.div`
|
|
9
9
|
padding: 1.75rem 3rem;
|
|
10
10
|
display: grid;
|
|
11
|
-
grid-template-columns: ${(
|
|
11
|
+
grid-template-columns: ${(r) => `repeat(${r.limit || 5}, minmax(0, 1fr))`};
|
|
12
12
|
|
|
13
13
|
gap: 2.97rem;
|
|
14
14
|
|
|
@@ -41,7 +41,7 @@ const G = q.div`
|
|
|
41
41
|
}
|
|
42
42
|
|
|
43
43
|
& .product-card {
|
|
44
|
-
max-width: ${(
|
|
44
|
+
max-width: ${(r) => `calc(${100 / r.desktopCols}% - ${(r.desktopCols - 1) * r.columnGapRem / r.desktopCols}rem)`};
|
|
45
45
|
|
|
46
46
|
animation-duration: 0.2s;
|
|
47
47
|
animation-name: animate-fade;
|
|
@@ -78,11 +78,11 @@ const G = q.div`
|
|
|
78
78
|
display: flex;
|
|
79
79
|
flex-direction: column;
|
|
80
80
|
}
|
|
81
|
-
`, S = T(
|
|
81
|
+
`, S = T(j), J = F((r, w) => {
|
|
82
82
|
const {
|
|
83
|
-
items:
|
|
84
|
-
limit:
|
|
85
|
-
limitMobile:
|
|
83
|
+
items: a,
|
|
84
|
+
limit: s = 5,
|
|
85
|
+
limitMobile: n = 4,
|
|
86
86
|
onSelectCard: c = () => {
|
|
87
87
|
},
|
|
88
88
|
title: N = "Urgent sale",
|
|
@@ -93,14 +93,14 @@ const G = q.div`
|
|
|
93
93
|
},
|
|
94
94
|
negotiableText: p,
|
|
95
95
|
freeText: f,
|
|
96
|
-
onBookmark:
|
|
96
|
+
onBookmark: h = () => {
|
|
97
97
|
},
|
|
98
|
-
|
|
99
|
-
componentName:
|
|
98
|
+
actionComponent: b,
|
|
99
|
+
componentName: k,
|
|
100
100
|
sponsoredText: y
|
|
101
|
-
} =
|
|
102
|
-
var
|
|
103
|
-
return /* @__PURE__ */ o($, { children: l === !0 ? (
|
|
101
|
+
} = r, l = E(), [i, M] = I(!1), U = _(() => {
|
|
102
|
+
var t;
|
|
103
|
+
return /* @__PURE__ */ o($, { children: l === !0 ? (t = a == null ? void 0 : a.slice(0, i === !0 ? a == null ? void 0 : a.length : n)) == null ? void 0 : t.map((e, m) => /* @__PURE__ */ o(
|
|
104
104
|
S,
|
|
105
105
|
{
|
|
106
106
|
sellerName: e == null ? void 0 : e.sellerName,
|
|
@@ -124,19 +124,21 @@ const G = q.div`
|
|
|
124
124
|
imageComponent: e == null ? void 0 : e.imageComponent,
|
|
125
125
|
negotiableText: p,
|
|
126
126
|
freeText: f,
|
|
127
|
-
onBookmark:
|
|
128
|
-
|
|
127
|
+
onBookmark: h,
|
|
128
|
+
actionComponent: b,
|
|
129
129
|
bookmarked: e == null ? void 0 : e.bookmarked,
|
|
130
130
|
bookmarkLists: e == null ? void 0 : e.bookmarkLists,
|
|
131
|
-
metadata: { name:
|
|
131
|
+
metadata: { name: k, accessor: e == null ? void 0 : e.accessor },
|
|
132
132
|
tags: e == null ? void 0 : e.tags,
|
|
133
133
|
condition: e == null ? void 0 : e.condition,
|
|
134
134
|
quantity: e == null ? void 0 : e.quantity,
|
|
135
|
+
hasQuantities: e == null ? void 0 : e.hasQuantities,
|
|
136
|
+
status: e == null ? void 0 : e.status,
|
|
135
137
|
trade: e == null ? void 0 : e.trade,
|
|
136
138
|
sponsoredText: y
|
|
137
139
|
},
|
|
138
140
|
m
|
|
139
|
-
)) :
|
|
141
|
+
)) : a == null ? void 0 : a.slice(0, s).map((e, m) => /* @__PURE__ */ o(
|
|
140
142
|
S,
|
|
141
143
|
{
|
|
142
144
|
name: e == null ? void 0 : e.name,
|
|
@@ -160,27 +162,29 @@ const G = q.div`
|
|
|
160
162
|
imageComponent: e == null ? void 0 : e.imageComponent,
|
|
161
163
|
negotiableText: p,
|
|
162
164
|
freeText: f,
|
|
163
|
-
onBookmark:
|
|
164
|
-
|
|
165
|
+
onBookmark: h,
|
|
166
|
+
actionComponent: b,
|
|
165
167
|
bookmarked: e == null ? void 0 : e.bookmarked,
|
|
166
168
|
bookmarkLists: e == null ? void 0 : e.bookmarkLists,
|
|
167
|
-
metadata: { name:
|
|
169
|
+
metadata: { name: k, accessor: e == null ? void 0 : e.accessor },
|
|
168
170
|
tags: e == null ? void 0 : e.tags,
|
|
169
171
|
condition: e == null ? void 0 : e.condition,
|
|
170
172
|
quantity: e == null ? void 0 : e.quantity,
|
|
173
|
+
hasQuantities: e == null ? void 0 : e.hasQuantities,
|
|
174
|
+
status: e == null ? void 0 : e.status,
|
|
171
175
|
trade: e == null ? void 0 : e.trade,
|
|
172
176
|
sponsoredText: y,
|
|
173
177
|
sellerName: e == null ? void 0 : e.sellerName
|
|
174
178
|
},
|
|
175
179
|
m
|
|
176
180
|
)) });
|
|
177
|
-
}, [
|
|
181
|
+
}, [a, l, s, n, i]);
|
|
178
182
|
return /* @__PURE__ */ o(
|
|
179
|
-
|
|
183
|
+
z,
|
|
180
184
|
{
|
|
181
185
|
isLoading: u,
|
|
182
186
|
keyPrefix: "urgent-sale-products-skeleton",
|
|
183
|
-
children: /* @__PURE__ */ C(
|
|
187
|
+
children: /* @__PURE__ */ C(A, { ref: w, limit: s, children: [
|
|
184
188
|
/* @__PURE__ */ C("div", { className: "urgent-tag", children: [
|
|
185
189
|
/* @__PURE__ */ o("i", { className: "mng mng-lnc-bolt-filled" }),
|
|
186
190
|
/* @__PURE__ */ o("span", { children: N })
|
|
@@ -188,18 +192,18 @@ const G = q.div`
|
|
|
188
192
|
" ",
|
|
189
193
|
U,
|
|
190
194
|
" ",
|
|
191
|
-
l === !0 &&
|
|
192
|
-
|
|
195
|
+
l === !0 && n < (a == null ? void 0 : a.length) && !u && /* @__PURE__ */ o(
|
|
196
|
+
Q,
|
|
193
197
|
{
|
|
194
198
|
className: "show-more",
|
|
195
199
|
btnType: "basic",
|
|
196
200
|
type: "button",
|
|
197
201
|
color: "neutral",
|
|
198
|
-
onClick: (
|
|
202
|
+
onClick: (t) => {
|
|
199
203
|
var e;
|
|
200
|
-
(e =
|
|
204
|
+
(e = t == null ? void 0 : t.target) == null || e.blur(), M(!i);
|
|
201
205
|
},
|
|
202
|
-
children:
|
|
206
|
+
children: i === !0 ? P : L
|
|
203
207
|
}
|
|
204
208
|
)
|
|
205
209
|
] })
|
|
@@ -207,5 +211,5 @@ const G = q.div`
|
|
|
207
211
|
);
|
|
208
212
|
});
|
|
209
213
|
export {
|
|
210
|
-
|
|
214
|
+
J as default
|
|
211
215
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const e=require("react/jsx-runtime"),c=require("react"),
|
|
1
|
+
"use strict";const e=require("react/jsx-runtime"),c=require("react"),x=require("./emotion-styled.browser.esm-BtEseadx.cjs"),T=require("./consts-goSZX3xP.cjs"),l=require("./utils-RnrgDDZP.cjs"),we=require("./index-uwl7BjRF.cjs"),P=require("./Badge.cjs"),ve=require("./Popover.cjs"),je=require("./PopoverTrigger.cjs"),xe=require("./PopoverContent.cjs"),ke=require("./useDetectMobile-zkbzoOGV.cjs"),r=require("./style-BAcV7F53.cjs"),Se=x.styled.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
flex-direction: column;
|
|
4
4
|
gap: 0.5rem;
|
|
@@ -103,7 +103,7 @@
|
|
|
103
103
|
gap: 0.25rem;
|
|
104
104
|
}
|
|
105
105
|
|
|
106
|
-
@media (max-width: ${
|
|
106
|
+
@media (max-width: ${T.MOBILE_SIZE_PX+"px"}) {
|
|
107
107
|
overflow: visible;
|
|
108
108
|
|
|
109
109
|
& .wrapper-card-3 {
|
|
@@ -166,7 +166,7 @@
|
|
|
166
166
|
&:hover .product-image-wrapper img {
|
|
167
167
|
transform: scale(1.1);
|
|
168
168
|
}
|
|
169
|
-
`,
|
|
169
|
+
`,ye=x.styled.div`
|
|
170
170
|
position: relative;
|
|
171
171
|
overflow: hidden;
|
|
172
172
|
border-radius: 0.75rem;
|
|
@@ -219,7 +219,7 @@
|
|
|
219
219
|
transition: var(--transition, all 0.3s ease);
|
|
220
220
|
}
|
|
221
221
|
|
|
222
|
-
@media (max-width: ${
|
|
222
|
+
@media (max-width: ${T.MOBILE_SIZE_PX+"px"}) {
|
|
223
223
|
& img {
|
|
224
224
|
width: 8.875rem;
|
|
225
225
|
height: 8.875rem;
|
|
@@ -234,7 +234,7 @@
|
|
|
234
234
|
top: unset;
|
|
235
235
|
}
|
|
236
236
|
}
|
|
237
|
-
`,
|
|
237
|
+
`,Pe=x.styled.div`
|
|
238
238
|
background: var(--white, #fff);
|
|
239
239
|
z-index: 1;
|
|
240
240
|
|
|
@@ -284,7 +284,7 @@
|
|
|
284
284
|
color: var(--gray-950, #14161a);
|
|
285
285
|
}
|
|
286
286
|
}
|
|
287
|
-
`,
|
|
287
|
+
`,_e=x.styled.div`
|
|
288
288
|
display: flex;
|
|
289
289
|
align-items: center;
|
|
290
290
|
gap: 0.25rem;
|
|
@@ -296,12 +296,12 @@
|
|
|
296
296
|
font-size: 1rem;
|
|
297
297
|
color: var(--warning-500, #F59E0B);
|
|
298
298
|
}
|
|
299
|
-
`,
|
|
300
|
-
@media (max-width: ${
|
|
299
|
+
`,Ce=c.forwardRef(({sponsoredText:i="Sponsored"},k)=>e.jsxs(_e,{ref:k,className:"sponsored-line",children:[e.jsx("i",{className:"mng-lnc-paw2"}),e.jsx("span",{children:i})]})),Re="Vehicles_Cars",Le="Vehicles_Motorcycles",Ne="Vehicles_Trucks",We="Vehicles_AgriculturalMachines_Tractors",$e="Vehicles_ConstructionMachines",Ee="Vehicles_Bus",Te="Vehicles_Campers",qe="RealEstates_",s={Mileage:{icon:"mng-lnc-road",measure:"km"},YearOfProduction:{icon:"mng-lnc-calendar",measure:""},Fuel:{icon:"mng-lnc-gas-station",measure:""},EnginePowerKW:{icon:"mng-lnc-engine",measure:"kW"},Transmission:{icon:"mng-lnc-transmission",measure:""},Model:{icon:"mng-lnc-application",measure:""},Brand:{icon:"mng-lnc-car--front",measure:""},SurfaceArea:{icon:"mng-lnc-right-angle",measure:""},Floor:{icon:"mng-lnc-elevator",measure:""},FurnishedCondition:{icon:"mng-lnc-sofa-01",measure:""},AdType:{icon:"mng-lnc-notes",measure:""},NumberOfRooms:{icon:"mng-lnc-meeting-room",measure:""},HeatingType:{icon:"mng-lnc-heat",measure:""},AirConditioning:{icon:"mng-lnc-air-conditioner",measure:""},Type:{icon:"mng-lnc-house-building",measure:""},Parking:{icon:"mng-lnc-parking-area-circle",measure:""},Internet:{icon:"mng-lnc-wifi-02",measure:""},State:{icon:"mng-lnc-settings-1",measure:""},NumberOfPremises:{icon:"mng-lnc-meeting-room",measure:""},Pool:{icon:"mng-lnc-pool",measure:""},Approach:{icon:"mng-lnc-driveway",measure:""},NumberOfBeds:{icon:"mng-lnc-bed",measure:""},Kitchen:{icon:"mng-lnc-fridge",measure:""},BathroomToilet:{icon:"mng-lnc-bath",measure:""},default:{icon:" mng-lnc-clock--filled",measure:""}},Oe=c.forwardRef((i,k)=>{const{uuid:w,sellerUuid:_,name:Y,price:C=0,sellingPrice:S,currency:y,isNegotiable:R,isFree:L,imageUrl:Z,location:A,sponsored:K,imageComponent:q,onSelectCard:H=()=>{},freeText:Q="Free",negotiableText:J="Negotiable",tags:t=[],categoryCode:N,condition:O,quantity:W,trade:V,sponsoredText:ee,forCart:re,forOrder:oe,contactSeller:ne,hasVariants:te,hasQuantities:ie,status:se,onBookmark:$=()=>{},actionComponent:v,bookmarked:B,bookmarkLists:ae,metadata:f,sellerName:z}=i,E=ke.useDetectMobile(),le=()=>{var m;if(!l.isDefined(v))return e.jsx(e.Fragment,{});const o=v,n=(m=v==null?void 0:v.props)==null?void 0:m.children,d=c.cloneElement(n,{key:`bookmark_pr__${B}`,bookmarked:B,productUuid:w,onAddToBookmark:()=>$(!0,w),onRemoveFromBookmark:()=>$(!1,w),bookmarkedUuidList:ae,sellerUuid:_,handleBookmarking:$,forCart:re,forOrder:oe,contactSeller:ne,hasVariants:te,status:se,quantity:W,hasQuantities:ie});return c.cloneElement(o,void 0,d)},M=[Re,Le,Ne,We,$e,Ee,Te,qe].some(o=>N==null?void 0:N.includes(o)),[ce,F]=c.useState(!1),de=()=>{F(!0)},me=()=>{F(!1)},a=c.useRef(null),p=c.useRef([]),[he,G]=c.useState(t==null?void 0:t.length),ue=()=>{var m,b,j;if(!(a!=null&&a.current)||((m=p==null?void 0:p.current)==null?void 0:m.length)===0)return;if(E){G(t==null?void 0:t.length);return}const o=(b=a==null?void 0:a.current)==null?void 0:b.offsetWidth;let n=0,d=0;for(let h=0;h<(t==null?void 0:t.length);h++){const g=((j=p==null?void 0:p.current[h])==null?void 0:j.offsetWidth)||0,u=n+g+4;if(u<=o)n+=u,d++;else break}G(d)};c.useEffect(()=>{const o=a==null?void 0:a.current;if(!o)return;const n=new ResizeObserver(()=>{ue()});return n.observe(o),()=>{n.disconnect()}},[t,E]);const pe=()=>{var o;return e.jsx("div",{className:"tags-popover__trigger",children:(o=t==null?void 0:t.slice(0,he))==null?void 0:o.map((n,d)=>{var g,u,D,U,X;const m=((g=s==null?void 0:s[n==null?void 0:n.code])==null?void 0:g.icon)??((u=s==null?void 0:s.default)==null?void 0:u.icon)??"",b=((D=n==null?void 0:n.measurementUnit)==null?void 0:D.symbol)??((U=s==null?void 0:s[n==null?void 0:n.code])==null?void 0:U.measure)??"",h=[(n==null?void 0:n.value)??((X=n==null?void 0:n.multiOptions)==null?void 0:X[0])??"",b].filter(Boolean).join(" ");return e.jsxs(P,{ref:be=>p.current[d]=be,className:"tag",children:[e.jsx("i",{className:m}),h]},`detailed-products-section-tag__${d+1}`)})})},ge=()=>e.jsx("div",{className:"tags-popover__content",children:t==null?void 0:t.map((o,n)=>{var h,g,u;const d=((h=o==null?void 0:o.measurementUnit)==null?void 0:h.symbol)??((g=s==null?void 0:s[o==null?void 0:o.code])==null?void 0:g.measure)??"",b=[(o==null?void 0:o.value)??((u=o==null?void 0:o.multiOptions)==null?void 0:u[0])??"",d].filter(Boolean).join(" "),j=o==null?void 0:o.name;return e.jsxs("div",{children:[e.jsx("span",{className:"tags-popover__name",children:`${j}: `}),e.jsx("span",{className:"tags-popover__value",children:b})]},`detailed-products-section-tag-dropdown__${n+1}`)})}),fe=()=>e.jsxs(e.Fragment,{children:[O&&e.jsx(P,{className:"tag",children:O},"detailed-products-section-tag__condition"),W&&e.jsx(P,{className:"tag",children:W},"detailed-products-section-tag__quantity"),V&&e.jsx(P,{className:"tag",children:V},"detailed-products-section-tag__trade")]}),I=C>0&&y&&R!==!0&&L!==!0&&C!==S;return e.jsxs(Se,{ref:a,className:"product-card","data-accessor":f==null?void 0:f.accessor,name:f==null?void 0:f.name,onClick:o=>H(o,a),children:[e.jsxs(ye,{className:"product-image-wrapper",children:[e.jsx(le,{}),l.isDefined(q)?q:e.jsx(we.ProductImageWrapper,{src:Z})]}),e.jsxs("div",{className:"wrapper-card-1",children:[e.jsx("div",{className:"seller",title:z,children:z}),e.jsx("div",{className:"card-title",children:Y})]}),e.jsxs("div",{className:"wrapper-card-3",children:[M&&e.jsx("div",{...E?{}:{onMouseEnter:de,onMouseLeave:me},children:e.jsxs(ve,{placement:"bottom",open:ce,children:[e.jsx(je,{children:pe()}),e.jsx(xe,{style:{all:"unset"},children:e.jsx(Pe,{children:ge()})})]})}),!M&&fe()]}),e.jsxs("div",{className:"wrapper-card-2",children:[e.jsxs("div",{className:`price-text ${I?"new-price":""}`,children:[S>0&&y&&R!==!0&&L!==!0&&e.jsx("div",{children:`${l.formatPrice(S)} ${l.GetCurrencySymbol(y)}`}),I&&e.jsx("div",{className:`${S>0?"full-price":""}`,children:`${l.formatPrice(C)} ${l.GetCurrencySymbol(y)}`}),R&&J,L&&Q]}),e.jsx("div",{className:"location-text",children:A})]}),K===!0&&e.jsx(Ce,{sponsoredText:ee})]})}),Ve=x.styled(r.SkeletonRowWrapper)`
|
|
300
|
+
@media (max-width: ${T.MOBILE_SIZE_PX+"px"}) {
|
|
301
301
|
& > div {
|
|
302
302
|
&:nth-of-type(even) {
|
|
303
303
|
display: none;
|
|
304
304
|
}
|
|
305
305
|
}
|
|
306
306
|
}
|
|
307
|
-
`,
|
|
307
|
+
`,Be=({keyPrefix:i})=>e.jsxs(Ve,{children:[e.jsxs(r.SkeletonColumnWrapper,{gap:"0.5rem",children:[e.jsx(r.SkeletonSquarePlaceholder,{height:"100%",width:"100%",borderRadius:"0.75rem"}),e.jsx(r.SkeletonColumnWrapper,{height:"1rem",children:e.jsx(r.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"})}),e.jsxs(r.SkeletonRowWrapper,{gap:"0.5rem",children:[e.jsx(r.SkeletonLinePlaceholder,{height:"1.5rem",borderRadius:"0.75rem"}),e.jsx(r.SkeletonLinePlaceholder,{height:"1.5rem",borderRadius:"0.75rem"})]}),e.jsx(r.SkeletonColumnWrapper,{height:"2rem",children:e.jsx(r.SkeletonLinePlaceholder,{height:"2rem",borderRadius:"0.75rem"})})]},`${i}-1`),e.jsxs(r.SkeletonColumnWrapper,{gap:"0.5rem",noGradient:!0,children:[e.jsx(r.SkeletonSquarePlaceholder,{height:"100%",width:"100%",borderRadius:"0.75rem"}),e.jsx(r.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsxs(r.SkeletonRowWrapper,{gap:"0.5rem",noGradient:!0,children:[e.jsx(r.SkeletonLinePlaceholder,{height:"1.5rem",borderRadius:"0.75rem"}),e.jsx(r.SkeletonLinePlaceholder,{height:"1.5rem",borderRadius:"0.75rem"})]}),e.jsx(r.SkeletonLinePlaceholder,{height:"2rem",borderRadius:"0.75rem"})]},`${i}-2`),e.jsxs(r.SkeletonColumnWrapper,{gap:"0.5rem",noGradient:!0,children:[e.jsx(r.SkeletonSquarePlaceholder,{height:"100%",width:"100%",borderRadius:"0.75rem"}),e.jsx(r.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsxs(r.SkeletonRowWrapper,{gap:"0.5rem",noGradient:!0,children:[e.jsx(r.SkeletonLinePlaceholder,{height:"1.5rem",borderRadius:"0.75rem"}),e.jsx(r.SkeletonLinePlaceholder,{height:"1.5rem",borderRadius:"0.75rem"})]}),e.jsx(r.SkeletonLinePlaceholder,{height:"2rem",borderRadius:"0.75rem"})]},`${i}-3`),e.jsxs(r.SkeletonColumnWrapper,{gap:"0.5rem",noGradient:!0,children:[e.jsx(r.SkeletonSquarePlaceholder,{height:"100%",width:"100%",borderRadius:"0.75rem"}),e.jsx(r.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsxs(r.SkeletonRowWrapper,{gap:"0.5rem",noGradient:!0,children:[e.jsx(r.SkeletonLinePlaceholder,{height:"1.5rem",borderRadius:"0.75rem"}),e.jsx(r.SkeletonLinePlaceholder,{height:"1.5rem",borderRadius:"0.75rem"})]}),e.jsx(r.SkeletonLinePlaceholder,{height:"2rem",borderRadius:"0.75rem"})]},`${i}-4`),e.jsxs(r.SkeletonColumnWrapper,{gap:"0.5rem",noGradient:!0,children:[e.jsx(r.SkeletonSquarePlaceholder,{height:"100%",width:"100%",borderRadius:"0.75rem"}),e.jsx(r.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsxs(r.SkeletonRowWrapper,{gap:"0.5rem",noGradient:!0,children:[e.jsx(r.SkeletonLinePlaceholder,{height:"1.5rem",borderRadius:"0.75rem"}),e.jsx(r.SkeletonLinePlaceholder,{height:"1.5rem",borderRadius:"0.75rem"})]}),e.jsx(r.SkeletonLinePlaceholder,{height:"2rem",borderRadius:"0.75rem"})]},`${i}-5`),e.jsxs(r.SkeletonColumnWrapper,{gap:"0.5rem",noGradient:!0,children:[e.jsx(r.SkeletonSquarePlaceholder,{height:"100%",width:"100%",borderRadius:"0.75rem"}),e.jsx(r.SkeletonLinePlaceholder,{height:"1rem",borderRadius:"0.75rem"}),e.jsxs(r.SkeletonRowWrapper,{gap:"0.5rem",noGradient:!0,children:[e.jsx(r.SkeletonLinePlaceholder,{height:"1.5rem",borderRadius:"0.75rem"}),e.jsx(r.SkeletonLinePlaceholder,{height:"1.5rem",borderRadius:"0.75rem"})]}),e.jsx(r.SkeletonLinePlaceholder,{height:"2rem",borderRadius:"0.75rem"})]},`${i}-6`)]}),ze=({keyPrefix:i,isLoading:k=!1,fallbackComponent:w=e.jsx(e.Fragment,{}),children:_})=>e.jsx(c.Suspense,{fallbackComponent:w,children:k===!0?e.jsx(Be,{keyPrefix:i}):_});exports.DetailedProductCard=Oe;exports.SuspenseDetailedProductCard=ze;
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { jsxs as t, jsx as e, Fragment as
|
|
2
|
-
import { forwardRef as ne, useState as
|
|
1
|
+
import { jsxs as t, jsx as e, Fragment as M } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as ne, useState as Q, useRef as Z, useEffect as Te, cloneElement as J, Suspense as Ve } from "react";
|
|
3
3
|
import { s as C } from "./emotion-styled.browser.esm-BNN1dTl3.js";
|
|
4
|
-
import { M } from "./consts-BuFChS64.js";
|
|
5
|
-
import { t as
|
|
6
|
-
import { P as
|
|
4
|
+
import { M as F } from "./consts-BuFChS64.js";
|
|
5
|
+
import { t as G, o as Ee, a as Oe, l as ee, p as re, G as oe } from "./utils-Dc5zIpaz.js";
|
|
6
|
+
import { P as ze } from "./index-C_NnINik.js";
|
|
7
7
|
import S from "./Badge.js";
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import { u as
|
|
8
|
+
import Be from "./Popover.js";
|
|
9
|
+
import We from "./PopoverTrigger.js";
|
|
10
|
+
import Ge from "./PopoverContent.js";
|
|
11
|
+
import { u as Me } from "./useDetectMobile-Bkvj0VMa.js";
|
|
12
12
|
import { a as f, S as p, c as w, b as n } from "./style-CXMUA6cI.js";
|
|
13
|
-
const
|
|
13
|
+
const Fe = C.div`
|
|
14
14
|
display: flex;
|
|
15
15
|
flex-direction: column;
|
|
16
16
|
gap: 0.5rem;
|
|
@@ -20,7 +20,7 @@ const Ge = C.div`
|
|
|
20
20
|
|
|
21
21
|
& .seller {
|
|
22
22
|
text-transform: uppercase;
|
|
23
|
-
${
|
|
23
|
+
${G()}
|
|
24
24
|
color: var(--gray-500);
|
|
25
25
|
font-size: 0.625rem;
|
|
26
26
|
font-weight: 400;
|
|
@@ -73,13 +73,13 @@ const Ge = C.div`
|
|
|
73
73
|
& .card-title {
|
|
74
74
|
font-size: 0.875rem;
|
|
75
75
|
font-weight: 600;
|
|
76
|
-
${
|
|
76
|
+
${Ee(2)}
|
|
77
77
|
}
|
|
78
78
|
|
|
79
79
|
& .price-text {
|
|
80
80
|
font-size: 1rem;
|
|
81
81
|
font-weight: 600;
|
|
82
|
-
${
|
|
82
|
+
${G()}
|
|
83
83
|
display: flex;
|
|
84
84
|
align-items: end;
|
|
85
85
|
gap: 0.5rem;
|
|
@@ -102,7 +102,7 @@ const Ge = C.div`
|
|
|
102
102
|
font-size: 0.75rem;
|
|
103
103
|
font-weight: 400;
|
|
104
104
|
color: var(--gray-600, #676e79);
|
|
105
|
-
${
|
|
105
|
+
${G()}
|
|
106
106
|
}
|
|
107
107
|
|
|
108
108
|
& .tags-wrapper {
|
|
@@ -115,7 +115,7 @@ const Ge = C.div`
|
|
|
115
115
|
gap: 0.25rem;
|
|
116
116
|
}
|
|
117
117
|
|
|
118
|
-
@media (max-width: ${
|
|
118
|
+
@media (max-width: ${F + "px"}) {
|
|
119
119
|
overflow: visible;
|
|
120
120
|
|
|
121
121
|
& .wrapper-card-3 {
|
|
@@ -178,7 +178,7 @@ const Ge = C.div`
|
|
|
178
178
|
&:hover .product-image-wrapper img {
|
|
179
179
|
transform: scale(1.1);
|
|
180
180
|
}
|
|
181
|
-
`,
|
|
181
|
+
`, Ie = C.div`
|
|
182
182
|
position: relative;
|
|
183
183
|
overflow: hidden;
|
|
184
184
|
border-radius: 0.75rem;
|
|
@@ -199,7 +199,7 @@ const Ge = C.div`
|
|
|
199
199
|
|
|
200
200
|
width: 2.25rem;
|
|
201
201
|
height: 2.25rem;
|
|
202
|
-
border-radius: ${(a) =>
|
|
202
|
+
border-radius: ${(a) => Oe(a.theme, "curved")};
|
|
203
203
|
border: 1px solid var(--gray-95008);
|
|
204
204
|
background-color: white;
|
|
205
205
|
color: var(--gray-950);
|
|
@@ -231,7 +231,7 @@ const Ge = C.div`
|
|
|
231
231
|
transition: var(--transition, all 0.3s ease);
|
|
232
232
|
}
|
|
233
233
|
|
|
234
|
-
@media (max-width: ${
|
|
234
|
+
@media (max-width: ${F + "px"}) {
|
|
235
235
|
& img {
|
|
236
236
|
width: 8.875rem;
|
|
237
237
|
height: 8.875rem;
|
|
@@ -246,7 +246,7 @@ const Ge = C.div`
|
|
|
246
246
|
top: unset;
|
|
247
247
|
}
|
|
248
248
|
}
|
|
249
|
-
`,
|
|
249
|
+
`, je = C.div`
|
|
250
250
|
background: var(--white, #fff);
|
|
251
251
|
z-index: 1;
|
|
252
252
|
|
|
@@ -296,7 +296,7 @@ const Ge = C.div`
|
|
|
296
296
|
color: var(--gray-950, #14161a);
|
|
297
297
|
}
|
|
298
298
|
}
|
|
299
|
-
`,
|
|
299
|
+
`, De = C.div`
|
|
300
300
|
display: flex;
|
|
301
301
|
align-items: center;
|
|
302
302
|
gap: 0.25rem;
|
|
@@ -308,10 +308,10 @@ const Ge = C.div`
|
|
|
308
308
|
font-size: 1rem;
|
|
309
309
|
color: var(--warning-500, #F59E0B);
|
|
310
310
|
}
|
|
311
|
-
`,
|
|
311
|
+
`, Ue = ne(({ sponsoredText: a = "Sponsored" }, R) => /* @__PURE__ */ t(De, { ref: R, className: "sponsored-line", children: [
|
|
312
312
|
/* @__PURE__ */ e("i", { className: "mng-lnc-paw2" }),
|
|
313
313
|
/* @__PURE__ */ e("span", { children: a })
|
|
314
|
-
] })),
|
|
314
|
+
] })), Le = "Vehicles_Cars", Xe = "Vehicles_Motorcycles", qe = "Vehicles_Trucks", xe = "Vehicles_AgriculturalMachines_Tractors", Ye = "Vehicles_ConstructionMachines", Ae = "Vehicles_Bus", Ke = "Vehicles_Campers", He = "RealEstates_", s = {
|
|
315
315
|
Mileage: {
|
|
316
316
|
icon: "mng-lnc-road",
|
|
317
317
|
measure: "km"
|
|
@@ -412,7 +412,7 @@ const Ge = C.div`
|
|
|
412
412
|
icon: " mng-lnc-clock--filled",
|
|
413
413
|
measure: ""
|
|
414
414
|
}
|
|
415
|
-
},
|
|
415
|
+
}, hr = ne((a, R) => {
|
|
416
416
|
const {
|
|
417
417
|
uuid: y,
|
|
418
418
|
sellerUuid: P,
|
|
@@ -425,72 +425,77 @@ const Ge = C.div`
|
|
|
425
425
|
imageUrl: ie,
|
|
426
426
|
location: ae,
|
|
427
427
|
sponsored: se,
|
|
428
|
-
imageComponent:
|
|
428
|
+
imageComponent: I,
|
|
429
429
|
onSelectCard: le = () => {
|
|
430
430
|
},
|
|
431
431
|
freeText: ce = "Free",
|
|
432
432
|
negotiableText: de = "Negotiable",
|
|
433
433
|
tags: i = [],
|
|
434
434
|
categoryCode: O,
|
|
435
|
-
condition:
|
|
436
|
-
quantity:
|
|
435
|
+
condition: j,
|
|
436
|
+
quantity: z,
|
|
437
437
|
trade: D,
|
|
438
438
|
sponsoredText: me,
|
|
439
439
|
forCart: he,
|
|
440
440
|
forOrder: pe,
|
|
441
|
-
contactSeller:
|
|
442
|
-
hasVariants:
|
|
441
|
+
contactSeller: ue,
|
|
442
|
+
hasVariants: ge,
|
|
443
|
+
hasQuantities: fe,
|
|
444
|
+
status: be,
|
|
443
445
|
onBookmark: B = () => {
|
|
444
446
|
},
|
|
445
|
-
|
|
447
|
+
actionComponent: k,
|
|
446
448
|
bookmarked: U,
|
|
447
|
-
bookmarkLists:
|
|
449
|
+
bookmarkLists: ve,
|
|
448
450
|
metadata: b,
|
|
449
451
|
sellerName: L
|
|
450
|
-
} = a,
|
|
452
|
+
} = a, W = Me(), we = () => {
|
|
451
453
|
var d;
|
|
452
|
-
if (!ee(k)) return /* @__PURE__ */ e(
|
|
453
|
-
const r = k, o = (d = k == null ? void 0 : k.props) == null ? void 0 : d.children, c =
|
|
454
|
+
if (!ee(k)) return /* @__PURE__ */ e(M, {});
|
|
455
|
+
const r = k, o = (d = k == null ? void 0 : k.props) == null ? void 0 : d.children, c = J(o, {
|
|
454
456
|
key: `bookmark_pr__${U}`,
|
|
455
457
|
bookmarked: U,
|
|
456
458
|
productUuid: y,
|
|
457
459
|
onAddToBookmark: () => B(!0, y),
|
|
458
460
|
onRemoveFromBookmark: () => B(!1, y),
|
|
459
|
-
bookmarkedUuidList:
|
|
461
|
+
bookmarkedUuidList: ve,
|
|
460
462
|
sellerUuid: P,
|
|
461
463
|
handleBookmarking: B,
|
|
462
464
|
forCart: he,
|
|
463
465
|
forOrder: pe,
|
|
464
|
-
contactSeller:
|
|
465
|
-
hasVariants:
|
|
466
|
+
contactSeller: ue,
|
|
467
|
+
hasVariants: ge,
|
|
468
|
+
status: be,
|
|
469
|
+
quantity: z,
|
|
470
|
+
hasQuantities: fe
|
|
466
471
|
});
|
|
467
|
-
return
|
|
472
|
+
return J(r, void 0, c);
|
|
468
473
|
}, X = [
|
|
469
|
-
De,
|
|
470
|
-
Ue,
|
|
471
474
|
Le,
|
|
472
475
|
Xe,
|
|
473
476
|
qe,
|
|
474
477
|
xe,
|
|
475
478
|
Ye,
|
|
476
|
-
|
|
479
|
+
Ae,
|
|
480
|
+
Ke,
|
|
481
|
+
He
|
|
477
482
|
].some(
|
|
478
483
|
(r) => O == null ? void 0 : O.includes(r)
|
|
479
|
-
), [
|
|
484
|
+
), [ye, q] = Q(!1), ke = () => {
|
|
480
485
|
q(!0);
|
|
481
|
-
},
|
|
486
|
+
}, _e = () => {
|
|
482
487
|
q(!1);
|
|
483
|
-
}, l =
|
|
488
|
+
}, l = Z(null), u = Z([]), [Ce, x] = Q(i == null ? void 0 : i.length), Re = () => {
|
|
484
489
|
var d, v, _;
|
|
485
|
-
if (!(l != null && l.current) || ((d =
|
|
486
|
-
if (
|
|
490
|
+
if (!(l != null && l.current) || ((d = u == null ? void 0 : u.current) == null ? void 0 : d.length) === 0) return;
|
|
491
|
+
if (W) {
|
|
487
492
|
x(i == null ? void 0 : i.length);
|
|
488
493
|
return;
|
|
489
494
|
}
|
|
490
495
|
const r = (v = l == null ? void 0 : l.current) == null ? void 0 : v.offsetWidth;
|
|
491
496
|
let o = 0, c = 0;
|
|
492
497
|
for (let m = 0; m < (i == null ? void 0 : i.length); m++) {
|
|
493
|
-
const
|
|
498
|
+
const g = ((_ = u == null ? void 0 : u.current[m]) == null ? void 0 : _.offsetWidth) || 0, h = o + g + 4;
|
|
494
499
|
if (h <= r)
|
|
495
500
|
o += h, c++;
|
|
496
501
|
else
|
|
@@ -498,25 +503,25 @@ const Ge = C.div`
|
|
|
498
503
|
}
|
|
499
504
|
x(c);
|
|
500
505
|
};
|
|
501
|
-
|
|
506
|
+
Te(() => {
|
|
502
507
|
const r = l == null ? void 0 : l.current;
|
|
503
508
|
if (!r) return;
|
|
504
509
|
const o = new ResizeObserver(() => {
|
|
505
|
-
|
|
510
|
+
Re();
|
|
506
511
|
});
|
|
507
512
|
return o.observe(r), () => {
|
|
508
513
|
o.disconnect();
|
|
509
514
|
};
|
|
510
|
-
}, [i,
|
|
511
|
-
const
|
|
515
|
+
}, [i, W]);
|
|
516
|
+
const Ne = () => {
|
|
512
517
|
var r;
|
|
513
|
-
return /* @__PURE__ */ e("div", { className: "tags-popover__trigger", children: (r = i == null ? void 0 : i.slice(0,
|
|
514
|
-
var
|
|
515
|
-
const d = ((
|
|
518
|
+
return /* @__PURE__ */ e("div", { className: "tags-popover__trigger", children: (r = i == null ? void 0 : i.slice(0, Ce)) == null ? void 0 : r.map((o, c) => {
|
|
519
|
+
var g, h, A, K, H;
|
|
520
|
+
const d = ((g = s == null ? void 0 : s[o == null ? void 0 : o.code]) == null ? void 0 : g.icon) ?? ((h = s == null ? void 0 : s.default) == null ? void 0 : h.icon) ?? "", v = ((A = o == null ? void 0 : o.measurementUnit) == null ? void 0 : A.symbol) ?? ((K = s == null ? void 0 : s[o == null ? void 0 : o.code]) == null ? void 0 : K.measure) ?? "", m = [(o == null ? void 0 : o.value) ?? ((H = o == null ? void 0 : o.multiOptions) == null ? void 0 : H[0]) ?? "", v].filter(Boolean).join(" ");
|
|
516
521
|
return /* @__PURE__ */ t(
|
|
517
522
|
S,
|
|
518
523
|
{
|
|
519
|
-
ref: (
|
|
524
|
+
ref: (Pe) => u.current[c] = Pe,
|
|
520
525
|
className: "tag",
|
|
521
526
|
children: [
|
|
522
527
|
/* @__PURE__ */ e("i", { className: d }),
|
|
@@ -526,22 +531,22 @@ const Ge = C.div`
|
|
|
526
531
|
`detailed-products-section-tag__${c + 1}`
|
|
527
532
|
);
|
|
528
533
|
}) });
|
|
529
|
-
},
|
|
530
|
-
var m,
|
|
531
|
-
const c = ((m = r == null ? void 0 : r.measurementUnit) == null ? void 0 : m.symbol) ?? ((
|
|
534
|
+
}, $e = () => /* @__PURE__ */ e("div", { className: "tags-popover__content", children: i == null ? void 0 : i.map((r, o) => {
|
|
535
|
+
var m, g, h;
|
|
536
|
+
const c = ((m = r == null ? void 0 : r.measurementUnit) == null ? void 0 : m.symbol) ?? ((g = s == null ? void 0 : s[r == null ? void 0 : r.code]) == null ? void 0 : g.measure) ?? "", v = [(r == null ? void 0 : r.value) ?? ((h = r == null ? void 0 : r.multiOptions) == null ? void 0 : h[0]) ?? "", c].filter(Boolean).join(" "), _ = r == null ? void 0 : r.name;
|
|
532
537
|
return /* @__PURE__ */ t("div", { children: [
|
|
533
538
|
/* @__PURE__ */ e("span", { className: "tags-popover__name", children: `${_}: ` }),
|
|
534
539
|
/* @__PURE__ */ e("span", { className: "tags-popover__value", children: v })
|
|
535
540
|
] }, `detailed-products-section-tag-dropdown__${o + 1}`);
|
|
536
|
-
}) }),
|
|
537
|
-
|
|
538
|
-
|
|
541
|
+
}) }), Se = () => /* @__PURE__ */ t(M, { children: [
|
|
542
|
+
j && /* @__PURE__ */ e(S, { className: "tag", children: j }, "detailed-products-section-tag__condition"),
|
|
543
|
+
z && /* @__PURE__ */ e(S, { className: "tag", children: z }, "detailed-products-section-tag__quantity"),
|
|
539
544
|
D && /* @__PURE__ */ e(S, { className: "tag", children: D }, "detailed-products-section-tag__trade")
|
|
540
545
|
] }), Y = T > 0 && $ && V !== !0 && E !== !0 && T !== N;
|
|
541
546
|
return (
|
|
542
547
|
// <LandingPageProductCardSkeleton />
|
|
543
548
|
/* @__PURE__ */ t(
|
|
544
|
-
|
|
549
|
+
Fe,
|
|
545
550
|
{
|
|
546
551
|
ref: l,
|
|
547
552
|
className: "product-card",
|
|
@@ -549,9 +554,9 @@ const Ge = C.div`
|
|
|
549
554
|
name: b == null ? void 0 : b.name,
|
|
550
555
|
onClick: (r) => le(r, l),
|
|
551
556
|
children: [
|
|
552
|
-
/* @__PURE__ */ t(
|
|
553
|
-
/* @__PURE__ */ e(
|
|
554
|
-
ee(
|
|
557
|
+
/* @__PURE__ */ t(Ie, { className: "product-image-wrapper", children: [
|
|
558
|
+
/* @__PURE__ */ e(we, {}),
|
|
559
|
+
ee(I) ? I : /* @__PURE__ */ e(ze, { src: ie })
|
|
555
560
|
] }),
|
|
556
561
|
/* @__PURE__ */ t("div", { className: "wrapper-card-1", children: [
|
|
557
562
|
/* @__PURE__ */ e("div", { className: "seller", title: L, children: L }),
|
|
@@ -561,17 +566,17 @@ const Ge = C.div`
|
|
|
561
566
|
X && /* @__PURE__ */ e(
|
|
562
567
|
"div",
|
|
563
568
|
{
|
|
564
|
-
...
|
|
565
|
-
onMouseEnter:
|
|
566
|
-
onMouseLeave:
|
|
569
|
+
...W ? {} : {
|
|
570
|
+
onMouseEnter: ke,
|
|
571
|
+
onMouseLeave: _e
|
|
567
572
|
},
|
|
568
|
-
children: /* @__PURE__ */ t(
|
|
569
|
-
/* @__PURE__ */ e(
|
|
570
|
-
/* @__PURE__ */ e(
|
|
573
|
+
children: /* @__PURE__ */ t(Be, { placement: "bottom", open: ye, children: [
|
|
574
|
+
/* @__PURE__ */ e(We, { children: Ne() }),
|
|
575
|
+
/* @__PURE__ */ e(Ge, { style: { all: "unset" }, children: /* @__PURE__ */ e(je, { children: $e() }) })
|
|
571
576
|
] })
|
|
572
577
|
}
|
|
573
578
|
),
|
|
574
|
-
!X &&
|
|
579
|
+
!X && Se()
|
|
575
580
|
] }),
|
|
576
581
|
/* @__PURE__ */ t("div", { className: "wrapper-card-2", children: [
|
|
577
582
|
/* @__PURE__ */ t("div", { className: `price-text ${Y ? "new-price" : ""}`, children: [
|
|
@@ -582,20 +587,20 @@ const Ge = C.div`
|
|
|
582
587
|
] }),
|
|
583
588
|
/* @__PURE__ */ e("div", { className: "location-text", children: ae })
|
|
584
589
|
] }),
|
|
585
|
-
se === !0 && /* @__PURE__ */ e(
|
|
590
|
+
se === !0 && /* @__PURE__ */ e(Ue, { sponsoredText: me })
|
|
586
591
|
]
|
|
587
592
|
}
|
|
588
593
|
)
|
|
589
594
|
);
|
|
590
|
-
}),
|
|
591
|
-
@media (max-width: ${
|
|
595
|
+
}), Qe = C(f)`
|
|
596
|
+
@media (max-width: ${F + "px"}) {
|
|
592
597
|
& > div {
|
|
593
598
|
&:nth-of-type(even) {
|
|
594
599
|
display: none;
|
|
595
600
|
}
|
|
596
601
|
}
|
|
597
602
|
}
|
|
598
|
-
`,
|
|
603
|
+
`, Ze = ({ keyPrefix: a }) => /* @__PURE__ */ t(Qe, { children: [
|
|
599
604
|
/* @__PURE__ */ t(p, { gap: "0.5rem", children: [
|
|
600
605
|
/* @__PURE__ */ e(
|
|
601
606
|
w,
|
|
@@ -732,13 +737,13 @@ const Ge = C.div`
|
|
|
732
737
|
},
|
|
733
738
|
`${a}-6`
|
|
734
739
|
)
|
|
735
|
-
] }),
|
|
740
|
+
] }), pr = ({
|
|
736
741
|
keyPrefix: a,
|
|
737
742
|
isLoading: R = !1,
|
|
738
|
-
fallbackComponent: y = /* @__PURE__ */ e(
|
|
743
|
+
fallbackComponent: y = /* @__PURE__ */ e(M, {}),
|
|
739
744
|
children: P
|
|
740
|
-
}) => /* @__PURE__ */ e(
|
|
745
|
+
}) => /* @__PURE__ */ e(Ve, { fallbackComponent: y, children: R === !0 ? /* @__PURE__ */ e(Ze, { keyPrefix: a }) : P });
|
|
741
746
|
export {
|
|
742
|
-
|
|
743
|
-
|
|
747
|
+
hr as D,
|
|
748
|
+
pr as S
|
|
744
749
|
};
|