@lanaco/lnc-react-ui 4.0.70 → 4.0.72
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/BlogsSectionSimpleCentered.cjs +6 -7
- package/dist/BlogsSectionSimpleCentered.js +62 -63
- package/dist/GeneralWithTagsCardsSection.cjs +2 -2
- package/dist/GeneralWithTagsCardsSection.js +15 -14
- package/dist/MasonryGeneralCardsSection.cjs +6 -6
- package/dist/MasonryGeneralCardsSection.js +40 -38
- package/dist/OverlayGeneralCardsSection.cjs +5 -5
- package/dist/OverlayGeneralCardsSection.js +76 -72
- package/dist/Table.cjs +24 -22
- package/dist/Table.js +666 -659
- package/package.json +1 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
"use strict";const t=require("react/jsx-runtime"),
|
|
1
|
+
"use strict";const t=require("react/jsx-runtime"),a=require("react"),u=require("./emotion-styled.browser.esm-BtEseadx.cjs"),p=require("./consts-CtNoHdBj.cjs"),b=require("./useDetectMobile-D6d5LpdL.cjs"),m=require("./utils-BXPz9bck.cjs"),j=require("./Button.cjs"),k=require("./index-CAqPGuiA.cjs"),C=u.styled.div`
|
|
2
2
|
display: grid;
|
|
3
3
|
grid-template-columns: ${i=>`repeat(${i.limit}, minmax(0, 1fr))`};
|
|
4
4
|
gap: 1.25rem;
|
|
5
5
|
margin: auto;
|
|
6
6
|
width: fit-content;
|
|
7
|
-
@media (max-width: ${
|
|
7
|
+
@media (max-width: ${p.MOBILE_SIZE_PX+"px"}) {
|
|
8
8
|
grid-template-columns: repeat(1, 1fr);
|
|
9
9
|
}
|
|
10
|
-
`,
|
|
10
|
+
`,h=u.styled.div`
|
|
11
11
|
display: flex;
|
|
12
12
|
flex-direction: column;
|
|
13
13
|
width: 100%;
|
|
@@ -21,7 +21,6 @@
|
|
|
21
21
|
gap: 1.5rem;
|
|
22
22
|
padding: 2rem 1.25rem;
|
|
23
23
|
min-height: 22.5rem;
|
|
24
|
-
max-height: 22.5rem;
|
|
25
24
|
align-items: center;
|
|
26
25
|
|
|
27
26
|
& button {
|
|
@@ -47,10 +46,10 @@
|
|
|
47
46
|
background-color: ${m.linearGradientAnimation("-90deg")};
|
|
48
47
|
}
|
|
49
48
|
|
|
50
|
-
@media (max-width: ${
|
|
49
|
+
@media (max-width: ${p.MOBILE_SIZE_PX+"px"}) {
|
|
51
50
|
max-width: unset;
|
|
52
51
|
}
|
|
53
|
-
`,
|
|
52
|
+
`,f=u.styled.div`
|
|
54
53
|
text-align: center;
|
|
55
54
|
display: flex;
|
|
56
55
|
flex-direction: column;
|
|
@@ -75,4 +74,4 @@
|
|
|
75
74
|
color: var(--gray-700, #4e555f);
|
|
76
75
|
${m.truncateTextInRows(3)}
|
|
77
76
|
}
|
|
78
|
-
`,
|
|
77
|
+
`,g=a.forwardRef((i,n)=>{const{title:r,imageUrl:o,text:l,buttonText:d,onCardClick:s}=i;return t.jsxs(h,{ref:n,className:"blog-card",onClick:s,children:[t.jsx(k.ProductImageWrapper,{src:o}),t.jsxs(f,{children:[t.jsx("div",{className:"text-wr-title",children:r}),t.jsx("div",{className:"text-wr",children:l})]}),t.jsx(j,{borderRadius:"curved",color:"gray",type:"button",btnType:"outline",onClick:s,size:"medium",children:d})]})}),S=a.forwardRef((i,n)=>{const{onCardClick:r}=i;return t.jsxs(h,{className:"product-card",onClick:r,children:[t.jsx("div",{className:"skeleton-img"}),t.jsx(f,{children:t.jsx("div",{className:"skeleton-title"})})]})}),y=({limit:i=3,isLoading:n=!1,keyPrefix:r})=>t.jsx(t.Fragment,{children:Array.from({length:i},(o,l)=>t.jsx(S,{isLoading:n},`${r}-skeleton-product-card-${l}`))}),v=({children:i,fallbackComponent:n=t.jsx(t.Fragment,{}),isLoading:r=!1,limit:o,keyPrefix:l})=>t.jsx(a.Suspense,{fallbackComponent:n,children:r===!0?t.jsx(y,{isLoading:r,limit:o,keyPrefix:l}):i}),$=a.forwardRef((i,n)=>{const{items:r,limit:o=3,onSelectCard:l=()=>{},isLoading:d=!1,getImage:s=()=>{}}=i,w=b.useDetectMobile();return t.jsx(C,{ref:n,limit:o,children:t.jsx(v,{isLoading:d,limit:o,keyPrefix:"explore-landing",children:t.jsx(t.Fragment,{children:w===!0?r==null?void 0:r.map((e,c)=>t.jsx(g,{title:e==null?void 0:e.title,imageUrl:s(e==null?void 0:e.imageUrl,e==null?void 0:e.uuid)||null,text:e==null?void 0:e.description,titleSlug:e==null?void 0:e.titleSlug,buttonText:e==null?void 0:e.buttonText,onCardClick:()=>l(e==null?void 0:e.uuid)},c)):r==null?void 0:r.slice(0,o).map((e,c)=>t.jsx(g,{title:e==null?void 0:e.title,imageUrl:s(e==null?void 0:e.imageUrl,e==null?void 0:e.uuid)||null,text:e==null?void 0:e.description,titleSlug:e==null?void 0:e.titleSlug,buttonText:e==null?void 0:e.buttonText,onCardClick:()=>l(e==null?void 0:e.uuid)},c))})})})});module.exports=$;
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
import { jsxs as c, jsx as t, Fragment as s } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as u, Suspense as
|
|
2
|
+
import { forwardRef as u, Suspense as C } from "react";
|
|
3
3
|
import { s as p } from "./emotion-styled.browser.esm-BNN1dTl3.js";
|
|
4
|
-
import { M as
|
|
5
|
-
import { u as
|
|
6
|
-
import { m as
|
|
7
|
-
import
|
|
8
|
-
import { P as
|
|
9
|
-
const
|
|
4
|
+
import { M as h } from "./consts-C1uHV4xc.js";
|
|
5
|
+
import { u as S } from "./useDetectMobile-BC6EGaBc.js";
|
|
6
|
+
import { m as f, t as v } from "./utils-DCs-SbIv.js";
|
|
7
|
+
import y from "./Button.js";
|
|
8
|
+
import { P as $ } from "./index-BLxkXrqU.js";
|
|
9
|
+
const T = p.div`
|
|
10
10
|
display: grid;
|
|
11
11
|
grid-template-columns: ${(i) => `repeat(${i.limit}, minmax(0, 1fr))`};
|
|
12
12
|
gap: 1.25rem;
|
|
13
13
|
margin: auto;
|
|
14
14
|
width: fit-content;
|
|
15
|
-
@media (max-width: ${
|
|
15
|
+
@media (max-width: ${h + "px"}) {
|
|
16
16
|
grid-template-columns: repeat(1, 1fr);
|
|
17
17
|
}
|
|
18
|
-
`,
|
|
18
|
+
`, b = p.div`
|
|
19
19
|
display: flex;
|
|
20
20
|
flex-direction: column;
|
|
21
21
|
width: 100%;
|
|
@@ -29,7 +29,6 @@ const M = p.div`
|
|
|
29
29
|
gap: 1.5rem;
|
|
30
30
|
padding: 2rem 1.25rem;
|
|
31
31
|
min-height: 22.5rem;
|
|
32
|
-
max-height: 22.5rem;
|
|
33
32
|
align-items: center;
|
|
34
33
|
|
|
35
34
|
& button {
|
|
@@ -52,13 +51,13 @@ const M = p.div`
|
|
|
52
51
|
min-height: 6rem;
|
|
53
52
|
max-height: 6rem;
|
|
54
53
|
border-radius: 0.75rem;
|
|
55
|
-
background-color: ${
|
|
54
|
+
background-color: ${f("-90deg")};
|
|
56
55
|
}
|
|
57
56
|
|
|
58
|
-
@media (max-width: ${
|
|
57
|
+
@media (max-width: ${h + "px"}) {
|
|
59
58
|
max-width: unset;
|
|
60
59
|
}
|
|
61
|
-
`,
|
|
60
|
+
`, w = p.div`
|
|
62
61
|
text-align: center;
|
|
63
62
|
display: flex;
|
|
64
63
|
flex-direction: column;
|
|
@@ -73,7 +72,7 @@ const M = p.div`
|
|
|
73
72
|
& .skeleton-title {
|
|
74
73
|
height: 1.75rem;
|
|
75
74
|
width: 80%;
|
|
76
|
-
background-color: ${
|
|
75
|
+
background-color: ${f("-90deg")};
|
|
77
76
|
}
|
|
78
77
|
|
|
79
78
|
& .text-wr {
|
|
@@ -81,18 +80,18 @@ const M = p.div`
|
|
|
81
80
|
font-size: 0.875rem;
|
|
82
81
|
flex: 1;
|
|
83
82
|
color: var(--gray-700, #4e555f);
|
|
84
|
-
${
|
|
83
|
+
${v(3)}
|
|
85
84
|
}
|
|
86
|
-
`,
|
|
87
|
-
const { title: r, imageUrl:
|
|
88
|
-
return /* @__PURE__ */ c(
|
|
89
|
-
/* @__PURE__ */ t(
|
|
90
|
-
/* @__PURE__ */ c(
|
|
85
|
+
`, g = u((i, o) => {
|
|
86
|
+
const { title: r, imageUrl: l, text: n, buttonText: d, onCardClick: a } = i;
|
|
87
|
+
return /* @__PURE__ */ c(b, { ref: o, className: "blog-card", onClick: a, children: [
|
|
88
|
+
/* @__PURE__ */ t($, { src: l }),
|
|
89
|
+
/* @__PURE__ */ c(w, { children: [
|
|
91
90
|
/* @__PURE__ */ t("div", { className: "text-wr-title", children: r }),
|
|
92
91
|
/* @__PURE__ */ t("div", { className: "text-wr", children: n })
|
|
93
92
|
] }),
|
|
94
93
|
/* @__PURE__ */ t(
|
|
95
|
-
|
|
94
|
+
y,
|
|
96
95
|
{
|
|
97
96
|
borderRadius: "curved",
|
|
98
97
|
color: "gray",
|
|
@@ -104,76 +103,76 @@ const M = p.div`
|
|
|
104
103
|
}
|
|
105
104
|
)
|
|
106
105
|
] });
|
|
107
|
-
}),
|
|
106
|
+
}), B = u((i, o) => {
|
|
108
107
|
const { onCardClick: r } = i;
|
|
109
108
|
return (
|
|
110
109
|
// <SimpleBlogCardSkeleton />
|
|
111
|
-
/* @__PURE__ */ c(
|
|
110
|
+
/* @__PURE__ */ c(b, { className: "product-card", onClick: r, children: [
|
|
112
111
|
/* @__PURE__ */ t("div", { className: "skeleton-img" }),
|
|
113
|
-
/* @__PURE__ */ t(
|
|
112
|
+
/* @__PURE__ */ t(w, { children: /* @__PURE__ */ t("div", { className: "skeleton-title" }) })
|
|
114
113
|
] })
|
|
115
114
|
);
|
|
116
|
-
}),
|
|
117
|
-
|
|
115
|
+
}), N = ({ limit: i = 3, isLoading: o = !1, keyPrefix: r }) => /* @__PURE__ */ t(s, { children: Array.from({ length: i }, (l, n) => /* @__PURE__ */ t(
|
|
116
|
+
B,
|
|
118
117
|
{
|
|
119
|
-
isLoading:
|
|
118
|
+
isLoading: o
|
|
120
119
|
},
|
|
121
120
|
`${r}-skeleton-product-card-${n}`
|
|
122
|
-
)) }),
|
|
121
|
+
)) }), I = ({
|
|
123
122
|
children: i,
|
|
124
|
-
fallbackComponent:
|
|
123
|
+
fallbackComponent: o = /* @__PURE__ */ t(s, {}),
|
|
125
124
|
isLoading: r = !1,
|
|
126
|
-
limit:
|
|
125
|
+
limit: l,
|
|
127
126
|
keyPrefix: n
|
|
128
|
-
}) => /* @__PURE__ */ t(
|
|
129
|
-
|
|
127
|
+
}) => /* @__PURE__ */ t(C, { fallbackComponent: o, children: r === !0 ? /* @__PURE__ */ t(
|
|
128
|
+
N,
|
|
130
129
|
{
|
|
131
130
|
isLoading: r,
|
|
132
|
-
limit:
|
|
131
|
+
limit: l,
|
|
133
132
|
keyPrefix: n
|
|
134
133
|
}
|
|
135
|
-
) : i }),
|
|
134
|
+
) : i }), A = u((i, o) => {
|
|
136
135
|
const {
|
|
137
136
|
items: r,
|
|
138
|
-
limit:
|
|
137
|
+
limit: l = 3,
|
|
139
138
|
onSelectCard: n = () => {
|
|
140
139
|
},
|
|
141
140
|
isLoading: d = !1,
|
|
142
141
|
getImage: a = () => {
|
|
143
142
|
}
|
|
144
|
-
} = i,
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
title: e == null ? void 0 : e.title,
|
|
148
|
-
imageUrl: a(e == null ? void 0 : e.imageUrl, e == null ? void 0 : e.uuid) || null,
|
|
149
|
-
text: e == null ? void 0 : e.description,
|
|
150
|
-
titleSlug: e == null ? void 0 : e.titleSlug,
|
|
151
|
-
buttonText: e == null ? void 0 : e.buttonText,
|
|
152
|
-
onCardClick: () => n(e == null ? void 0 : e.uuid)
|
|
153
|
-
},
|
|
154
|
-
m
|
|
155
|
-
)) : r == null ? void 0 : r.slice(0, o).map((e, m) => /* @__PURE__ */ t(
|
|
156
|
-
h,
|
|
157
|
-
{
|
|
158
|
-
title: e == null ? void 0 : e.title,
|
|
159
|
-
imageUrl: a(e == null ? void 0 : e.imageUrl, e == null ? void 0 : e.uuid) || null,
|
|
160
|
-
text: e == null ? void 0 : e.description,
|
|
161
|
-
titleSlug: e == null ? void 0 : e.titleSlug,
|
|
162
|
-
buttonText: e == null ? void 0 : e.buttonText,
|
|
163
|
-
onCardClick: () => n(e == null ? void 0 : e.uuid)
|
|
164
|
-
},
|
|
165
|
-
m
|
|
166
|
-
)) }), [r, g, o, n]);
|
|
167
|
-
return /* @__PURE__ */ t(M, { ref: l, limit: o, children: /* @__PURE__ */ t(
|
|
168
|
-
U,
|
|
143
|
+
} = i, k = S();
|
|
144
|
+
return /* @__PURE__ */ t(T, { ref: o, limit: l, children: /* @__PURE__ */ t(
|
|
145
|
+
I,
|
|
169
146
|
{
|
|
170
147
|
isLoading: d,
|
|
171
|
-
limit:
|
|
148
|
+
limit: l,
|
|
172
149
|
keyPrefix: "explore-landing",
|
|
173
|
-
children: k
|
|
150
|
+
children: /* @__PURE__ */ t(s, { children: k === !0 ? r == null ? void 0 : r.map((e, m) => /* @__PURE__ */ t(
|
|
151
|
+
g,
|
|
152
|
+
{
|
|
153
|
+
title: e == null ? void 0 : e.title,
|
|
154
|
+
imageUrl: a(e == null ? void 0 : e.imageUrl, e == null ? void 0 : e.uuid) || null,
|
|
155
|
+
text: e == null ? void 0 : e.description,
|
|
156
|
+
titleSlug: e == null ? void 0 : e.titleSlug,
|
|
157
|
+
buttonText: e == null ? void 0 : e.buttonText,
|
|
158
|
+
onCardClick: () => n(e == null ? void 0 : e.uuid)
|
|
159
|
+
},
|
|
160
|
+
m
|
|
161
|
+
)) : r == null ? void 0 : r.slice(0, l).map((e, m) => /* @__PURE__ */ t(
|
|
162
|
+
g,
|
|
163
|
+
{
|
|
164
|
+
title: e == null ? void 0 : e.title,
|
|
165
|
+
imageUrl: a(e == null ? void 0 : e.imageUrl, e == null ? void 0 : e.uuid) || null,
|
|
166
|
+
text: e == null ? void 0 : e.description,
|
|
167
|
+
titleSlug: e == null ? void 0 : e.titleSlug,
|
|
168
|
+
buttonText: e == null ? void 0 : e.buttonText,
|
|
169
|
+
onCardClick: () => n(e == null ? void 0 : e.uuid)
|
|
170
|
+
},
|
|
171
|
+
m
|
|
172
|
+
)) })
|
|
174
173
|
}
|
|
175
174
|
) });
|
|
176
175
|
});
|
|
177
176
|
export {
|
|
178
|
-
|
|
177
|
+
A as default
|
|
179
178
|
};
|
|
@@ -130,7 +130,7 @@
|
|
|
130
130
|
height: 3rem;
|
|
131
131
|
border-radius: 999px;
|
|
132
132
|
background: ${m.linearGradientAnimation("-90deg")};
|
|
133
|
-
`,E=l.forwardRef(({},t)=>r.jsx(C,{})),W=l.forwardRef(({text:t,icon:i,onSelectCard:a=()=>{}},p)=>r.jsxs(N,{onClick:a,children:[r.jsx(j,{icon:` ${i}`,className:"wrapper__icon"}),r.jsx("div",{className:"wrapper__text",children:t})]})),G=l.forwardRef(({image:t,imageComponent:i,title:a,onSelectCard:p=()=>{}},
|
|
133
|
+
`,E=l.forwardRef(({},t)=>r.jsx(C,{})),W=l.forwardRef(({text:t,icon:i,onSelectCard:a=()=>{}},p)=>r.jsxs(N,{onClick:a,children:[r.jsx(j,{icon:` ${i}`,className:"wrapper__icon"}),r.jsx("div",{className:"wrapper__text",children:t})]})),G=l.forwardRef(({image:t,imageComponent:i,title:a,onSelectCard:p=()=>{}},c)=>{const{theme:h}=k.useTheme();return r.jsxs($,{ref:c,theme:h,onClick:p,children:[m.isDefined(i)?i:r.jsx("img",{src:t,className:"wrapper__image"}),r.jsx("div",{className:"wrapper__content",children:r.jsx("div",{className:"wrapper__title",children:a})})]})}),R=l.forwardRef(({},t)=>r.jsx(I,{})),q=o.styled.div`
|
|
134
134
|
display: flex;
|
|
135
135
|
flex-direction: column;
|
|
136
136
|
align-items: center;
|
|
@@ -207,4 +207,4 @@
|
|
|
207
207
|
gap: 1rem;
|
|
208
208
|
}
|
|
209
209
|
}
|
|
210
|
-
`,z=l.forwardRef(({title:t,subtitle:i,options:a=[],limitTags:p=7,limitTagsForMobile:
|
|
210
|
+
`,z=l.forwardRef(({title:t,subtitle:i,options:a=[],limitTags:p=7,limitTagsForMobile:c=2,limit:h=3,limitForMobile:b=3,items:n=[],onSelectTag:_=()=>{},onSelectCard:x=()=>{},isLoading:y},v)=>{var f,u;const g=e=>{_==null||_(e==null?void 0:e.uuid)},w=e=>{x==null||x(e==null?void 0:e.uuid)};return r.jsxs(q,{ref:v,limitTags:p,limitTagsForMobile:c,limitCards:h,limitCardsForMobile:b,children:[r.jsxs("div",{className:"wrapper__heading",children:[t&&r.jsx("div",{className:"wrapper__title",children:t}),i&&r.jsx("div",{className:"wrapper__subtitle",children:i})]}),r.jsx("div",{className:"wrapper__cards",children:n&&(n==null?void 0:n.length)>0?n==null?void 0:n.map((e,s)=>r.jsx(G,{image:e==null?void 0:e.imageUrl,imageComponent:e==null?void 0:e.imageComponent,title:e==null?void 0:e.title,onSelectCard:()=>w==null?void 0:w(e==null?void 0:e.uuid)},`general-with-tags-card__${s+1}`)):(f=Array.from("123"))==null?void 0:f.map((e,s)=>r.jsx(R,{},`general-with-tags-card-skeleton__${s+1}`))}),(a==null?void 0:a.length)>0&&r.jsx("div",{className:"wrapper__tags",children:a==null?void 0:a.map((e,s)=>r.jsx(W,{icon:e==null?void 0:e.icon,text:e==null?void 0:e.text,onSelectCard:()=>g==null?void 0:g(e)},`general-with-tags-card-tag__${s+1}`))}),y===!0&&!((a==null?void 0:a.length)>0)&&r.jsx("div",{className:"wrapper__tags",children:(u=Array.from("123"))==null?void 0:u.map((e,s)=>r.jsx(E,{},`general-with-tags-card-tag-skeleton__${s+1}`))})]})});module.exports=z;
|
|
@@ -144,10 +144,11 @@ const j = s.div`
|
|
|
144
144
|
/* @__PURE__ */ a("div", { className: "wrapper__text", children: r })
|
|
145
145
|
] })
|
|
146
146
|
), A = o(
|
|
147
|
+
// eslint-disable-next-line react/prop-types
|
|
147
148
|
({ image: r, imageComponent: i, title: t, onSelectCard: p = () => {
|
|
148
|
-
} },
|
|
149
|
-
const { theme:
|
|
150
|
-
return /* @__PURE__ */ m(j, {
|
|
149
|
+
} }, c) => {
|
|
150
|
+
const { theme: h } = W();
|
|
151
|
+
return /* @__PURE__ */ m(j, { ref: c, theme: h, onClick: p, children: [
|
|
151
152
|
N(i) ? i : /* @__PURE__ */ a("img", { src: r, className: "wrapper__image" }),
|
|
152
153
|
/* @__PURE__ */ a("div", { className: "wrapper__content", children: /* @__PURE__ */ a("div", { className: "wrapper__title", children: t }) })
|
|
153
154
|
] });
|
|
@@ -235,29 +236,29 @@ const j = s.div`
|
|
|
235
236
|
subtitle: i,
|
|
236
237
|
options: t = [],
|
|
237
238
|
limitTags: p = 7,
|
|
238
|
-
limitTagsForMobile:
|
|
239
|
-
limit:
|
|
239
|
+
limitTagsForMobile: c = 2,
|
|
240
|
+
limit: h = 3,
|
|
240
241
|
limitForMobile: v = 3,
|
|
241
242
|
items: n = [],
|
|
242
|
-
onSelectTag:
|
|
243
|
+
onSelectTag: g = () => {
|
|
243
244
|
},
|
|
244
|
-
onSelectCard:
|
|
245
|
+
onSelectCard: w = () => {
|
|
245
246
|
},
|
|
246
247
|
isLoading: y
|
|
247
248
|
}, k) => {
|
|
248
249
|
var x, u;
|
|
249
|
-
const
|
|
250
|
-
h == null || h(e == null ? void 0 : e.uuid);
|
|
251
|
-
}, _ = (e) => {
|
|
250
|
+
const _ = (e) => {
|
|
252
251
|
g == null || g(e == null ? void 0 : e.uuid);
|
|
252
|
+
}, f = (e) => {
|
|
253
|
+
w == null || w(e == null ? void 0 : e.uuid);
|
|
253
254
|
};
|
|
254
255
|
return /* @__PURE__ */ m(
|
|
255
256
|
F,
|
|
256
257
|
{
|
|
257
258
|
ref: k,
|
|
258
259
|
limitTags: p,
|
|
259
|
-
limitTagsForMobile:
|
|
260
|
-
limitCards:
|
|
260
|
+
limitTagsForMobile: c,
|
|
261
|
+
limitCards: h,
|
|
261
262
|
limitCardsForMobile: v,
|
|
262
263
|
children: [
|
|
263
264
|
/* @__PURE__ */ m("div", { className: "wrapper__heading", children: [
|
|
@@ -270,7 +271,7 @@ const j = s.div`
|
|
|
270
271
|
image: e == null ? void 0 : e.imageUrl,
|
|
271
272
|
imageComponent: e == null ? void 0 : e.imageComponent,
|
|
272
273
|
title: e == null ? void 0 : e.title,
|
|
273
|
-
onSelectCard: () =>
|
|
274
|
+
onSelectCard: () => f == null ? void 0 : f(e == null ? void 0 : e.uuid)
|
|
274
275
|
},
|
|
275
276
|
`general-with-tags-card__${l + 1}`
|
|
276
277
|
)) : (x = Array.from("123")) == null ? void 0 : x.map((e, l) => /* @__PURE__ */ a(
|
|
@@ -283,7 +284,7 @@ const j = s.div`
|
|
|
283
284
|
{
|
|
284
285
|
icon: e == null ? void 0 : e.icon,
|
|
285
286
|
text: e == null ? void 0 : e.text,
|
|
286
|
-
onSelectCard: () =>
|
|
287
|
+
onSelectCard: () => _ == null ? void 0 : _(e)
|
|
287
288
|
},
|
|
288
289
|
`general-with-tags-card-tag__${l + 1}`
|
|
289
290
|
)) }),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const r=require("react/jsx-runtime"),g=require("react"),
|
|
1
|
+
"use strict";const r=require("react/jsx-runtime"),g=require("react"),u=require("./Button.cjs"),c=require("./emotion-styled.browser.esm-BtEseadx.cjs"),i=require("./utils-BXPz9bck.cjs"),_=require("./emotion-element-f0de968e.browser.esm-B7k6i6lC.cjs"),p=require("./consts-CtNoHdBj.cjs"),w=c.styled.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
flex-direction: column;
|
|
4
4
|
align-items: flex-start;
|
|
@@ -12,12 +12,12 @@
|
|
|
12
12
|
grid-row: ${t=>{var e;return((e=t.position)==null?void 0:e.rowStart)||"1"}} /
|
|
13
13
|
${t=>{var e;return((e=t.position)==null?void 0:e.rowEnd)||"1"}};
|
|
14
14
|
|
|
15
|
-
background: linear-gradient(
|
|
15
|
+
background: ${t=>t.backgroundColor||`linear-gradient(
|
|
16
16
|
178deg,
|
|
17
17
|
rgba(0, 0, 0, 0) 1.5%,
|
|
18
18
|
rgba(0, 0, 0, 0.16) 8.95%,
|
|
19
19
|
#000 98.39%
|
|
20
|
-
);
|
|
20
|
+
)`};
|
|
21
21
|
|
|
22
22
|
& .wrapper__image {
|
|
23
23
|
height: 100%;
|
|
@@ -114,7 +114,7 @@
|
|
|
114
114
|
}
|
|
115
115
|
}
|
|
116
116
|
}
|
|
117
|
-
`,
|
|
117
|
+
`,b=g.forwardRef(({title:t,imageUrl:e,description:n,buttonText:a,onSelectCard:o=()=>{},className:l,position:s,selectAction:d,tag:m,backgroundColor:x},h)=>{const f=_.useTheme();return r.jsx(r.Fragment,{children:r.jsxs(w,{ref:h,theme:f,className:l,onClick:o,position:s,backgroundColor:x,children:[r.jsx("img",{src:e,className:"wrapper__image"}),r.jsxs("div",{className:"wrapper__text",children:[m&&r.jsx("div",{className:"text__tag",children:m}),r.jsx("div",{className:"text__title",children:t}),i.isDefinedNotEmptyString(n)&&r.jsx("div",{className:"text__description",children:n}),i.isDefinedNotEmptyString(a)&&r.jsx(u,{text:a,onClick:()=>o(d),className:"text__action"})]})]})})}),v=c.styled.div`
|
|
118
118
|
display: flex;
|
|
119
119
|
flex-direction: column;
|
|
120
120
|
gap: 1.5rem;
|
|
@@ -149,7 +149,7 @@
|
|
|
149
149
|
}
|
|
150
150
|
}
|
|
151
151
|
}
|
|
152
|
-
`,
|
|
152
|
+
`,y=c.styled.div`
|
|
153
153
|
display: grid;
|
|
154
154
|
grid-template-columns: ${t=>"repeat(12, minmax(0, 1fr))"};
|
|
155
155
|
|
|
@@ -168,4 +168,4 @@
|
|
|
168
168
|
max-height: 100%;
|
|
169
169
|
padding: 0 1rem;
|
|
170
170
|
}
|
|
171
|
-
`,
|
|
171
|
+
`,j=g.forwardRef(({title:t,items:e,limit:n=3,onSelectCard:a=()=>{}},o)=>r.jsxs(v,{ref:o,children:[r.jsx("div",{className:"regular-title",children:r.jsx("div",{className:"regular-title-text",children:r.jsx("span",{children:t})})}),r.jsx(y,{limit:n,children:e&&(e==null?void 0:e.map((l,s)=>r.jsx(b,{...l,onSelectCard:d=>a(d,l)},`landing-page-masonry-general-card__${s+1}`)))})]}));module.exports=j;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { jsx as t, Fragment as
|
|
1
|
+
import { jsx as t, Fragment as b, jsxs as s } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef as f } from "react";
|
|
3
|
-
import
|
|
3
|
+
import v from "./Button.js";
|
|
4
4
|
import { s as c } from "./emotion-styled.browser.esm-BNN1dTl3.js";
|
|
5
|
-
import { m as
|
|
6
|
-
import { u as
|
|
5
|
+
import { m as l, t as p, k as h } from "./utils-DCs-SbIv.js";
|
|
6
|
+
import { u as y } from "./emotion-element-f0de968e.browser.esm-CkCiQliQ.js";
|
|
7
7
|
import { M as x } from "./consts-C1uHV4xc.js";
|
|
8
|
-
const
|
|
8
|
+
const k = c.div`
|
|
9
9
|
display: flex;
|
|
10
10
|
flex-direction: column;
|
|
11
11
|
align-items: flex-start;
|
|
@@ -31,12 +31,12 @@ const y = c.div`
|
|
|
31
31
|
return ((e = r.position) == null ? void 0 : e.rowEnd) || "1";
|
|
32
32
|
}};
|
|
33
33
|
|
|
34
|
-
background: linear-gradient(
|
|
34
|
+
background: ${(r) => r.backgroundColor || `linear-gradient(
|
|
35
35
|
178deg,
|
|
36
36
|
rgba(0, 0, 0, 0) 1.5%,
|
|
37
37
|
rgba(0, 0, 0, 0.16) 8.95%,
|
|
38
38
|
#000 98.39%
|
|
39
|
-
);
|
|
39
|
+
)`};
|
|
40
40
|
|
|
41
41
|
& .wrapper__image {
|
|
42
42
|
height: 100%;
|
|
@@ -50,7 +50,7 @@ const y = c.div`
|
|
|
50
50
|
width: 24.5rem;
|
|
51
51
|
height: 30rem;
|
|
52
52
|
border-radius: 0.75rem;
|
|
53
|
-
background-color: ${
|
|
53
|
+
background-color: ${l("-90deg")};
|
|
54
54
|
}
|
|
55
55
|
|
|
56
56
|
& .wrapper__text {
|
|
@@ -106,19 +106,19 @@ const y = c.div`
|
|
|
106
106
|
}
|
|
107
107
|
|
|
108
108
|
& .text__title--skeleton {
|
|
109
|
-
background-color: ${
|
|
109
|
+
background-color: ${l("-90deg")};
|
|
110
110
|
height: 1rem;
|
|
111
111
|
width: 9rem;
|
|
112
112
|
}
|
|
113
113
|
|
|
114
114
|
& .text__description--skeleton {
|
|
115
|
-
background-color: ${
|
|
115
|
+
background-color: ${l("-90deg")};
|
|
116
116
|
height: 1rem;
|
|
117
117
|
width: 12rem;
|
|
118
118
|
}
|
|
119
119
|
|
|
120
120
|
& .text__action--skeleton {
|
|
121
|
-
background-color: ${
|
|
121
|
+
background-color: ${l("-90deg")};
|
|
122
122
|
height: 2rem;
|
|
123
123
|
width: 9rem;
|
|
124
124
|
}
|
|
@@ -133,28 +133,30 @@ const y = c.div`
|
|
|
133
133
|
}
|
|
134
134
|
}
|
|
135
135
|
}
|
|
136
|
-
`,
|
|
136
|
+
`, $ = f(
|
|
137
137
|
({
|
|
138
138
|
title: r,
|
|
139
139
|
imageUrl: e,
|
|
140
140
|
description: i,
|
|
141
141
|
buttonText: a,
|
|
142
|
-
onSelectCard:
|
|
142
|
+
onSelectCard: o = () => {
|
|
143
143
|
},
|
|
144
|
-
className:
|
|
145
|
-
position:
|
|
146
|
-
selectAction:
|
|
147
|
-
tag: g
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
144
|
+
className: n,
|
|
145
|
+
position: d,
|
|
146
|
+
selectAction: m,
|
|
147
|
+
tag: g,
|
|
148
|
+
backgroundColor: u
|
|
149
|
+
}, _) => {
|
|
150
|
+
const w = y();
|
|
151
|
+
return /* @__PURE__ */ t(b, { children: /* @__PURE__ */ s(
|
|
152
|
+
k,
|
|
152
153
|
{
|
|
153
|
-
ref:
|
|
154
|
-
theme:
|
|
155
|
-
className:
|
|
156
|
-
onClick:
|
|
157
|
-
position:
|
|
154
|
+
ref: _,
|
|
155
|
+
theme: w,
|
|
156
|
+
className: n,
|
|
157
|
+
onClick: o,
|
|
158
|
+
position: d,
|
|
159
|
+
backgroundColor: u,
|
|
158
160
|
children: [
|
|
159
161
|
/* @__PURE__ */ t("img", { src: e, className: "wrapper__image" }),
|
|
160
162
|
/* @__PURE__ */ s("div", { className: "wrapper__text", children: [
|
|
@@ -162,10 +164,10 @@ const y = c.div`
|
|
|
162
164
|
/* @__PURE__ */ t("div", { className: "text__title", children: r }),
|
|
163
165
|
h(i) && /* @__PURE__ */ t("div", { className: "text__description", children: i }),
|
|
164
166
|
h(a) && /* @__PURE__ */ t(
|
|
165
|
-
|
|
167
|
+
v,
|
|
166
168
|
{
|
|
167
169
|
text: a,
|
|
168
|
-
onClick: () =>
|
|
170
|
+
onClick: () => o(m),
|
|
169
171
|
className: "text__action"
|
|
170
172
|
}
|
|
171
173
|
)
|
|
@@ -174,7 +176,7 @@ const y = c.div`
|
|
|
174
176
|
}
|
|
175
177
|
) });
|
|
176
178
|
}
|
|
177
|
-
),
|
|
179
|
+
), N = c.div`
|
|
178
180
|
display: flex;
|
|
179
181
|
flex-direction: column;
|
|
180
182
|
gap: 1.5rem;
|
|
@@ -209,7 +211,7 @@ const y = c.div`
|
|
|
209
211
|
}
|
|
210
212
|
}
|
|
211
213
|
}
|
|
212
|
-
`,
|
|
214
|
+
`, z = c.div`
|
|
213
215
|
display: grid;
|
|
214
216
|
grid-template-columns: ${(r) => "repeat(12, minmax(0, 1fr))"};
|
|
215
217
|
|
|
@@ -228,20 +230,20 @@ const y = c.div`
|
|
|
228
230
|
max-height: 100%;
|
|
229
231
|
padding: 0 1rem;
|
|
230
232
|
}
|
|
231
|
-
`,
|
|
233
|
+
`, R = f(
|
|
232
234
|
({ title: r, items: e, limit: i = 3, onSelectCard: a = () => {
|
|
233
|
-
} },
|
|
235
|
+
} }, o) => /* @__PURE__ */ s(N, { ref: o, children: [
|
|
234
236
|
/* @__PURE__ */ t("div", { className: "regular-title", children: /* @__PURE__ */ t("div", { className: "regular-title-text", children: /* @__PURE__ */ t("span", { children: r }) }) }),
|
|
235
|
-
/* @__PURE__ */ t(
|
|
236
|
-
|
|
237
|
+
/* @__PURE__ */ t(z, { limit: i, children: e && (e == null ? void 0 : e.map((n, d) => /* @__PURE__ */ t(
|
|
238
|
+
$,
|
|
237
239
|
{
|
|
238
|
-
...
|
|
239
|
-
onSelectCard: (
|
|
240
|
+
...n,
|
|
241
|
+
onSelectCard: (m) => a(m, n)
|
|
240
242
|
},
|
|
241
|
-
`landing-page-masonry-general-card__${
|
|
243
|
+
`landing-page-masonry-general-card__${d + 1}`
|
|
242
244
|
))) })
|
|
243
245
|
] })
|
|
244
246
|
);
|
|
245
247
|
export {
|
|
246
|
-
|
|
248
|
+
R as default
|
|
247
249
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const
|
|
1
|
+
"use strict";const r=require("react/jsx-runtime"),l=require("react"),u=require("./emotion-styled.browser.esm-BtEseadx.cjs"),g=require("./consts-CtNoHdBj.cjs"),p=require("./style-C571ywKV.cjs"),x=require("./utils-BXPz9bck.cjs"),f=require("./Button.cjs"),j=require("./ThemeProvider.cjs"),v=u.styled.div`
|
|
2
2
|
display: grid;
|
|
3
3
|
grid-template-columns: ${n=>`repeat(${n.limit}, 1fr)`};
|
|
4
4
|
gap: 1.25rem;
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
flex-direction: column;
|
|
10
10
|
gap: 1rem;
|
|
11
11
|
}
|
|
12
|
-
`,h=
|
|
12
|
+
`,h=u.styled.div`
|
|
13
13
|
width: 100%;
|
|
14
14
|
overflow: hidden;
|
|
15
15
|
position: relative;
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
|
|
51
51
|
& .content-text-title {
|
|
52
52
|
font-weight: 600;
|
|
53
|
-
${
|
|
53
|
+
${x.truncateTextInRows(2)}
|
|
54
54
|
}
|
|
55
55
|
}
|
|
56
56
|
|
|
@@ -62,7 +62,7 @@
|
|
|
62
62
|
}
|
|
63
63
|
|
|
64
64
|
& .img-skeleton {
|
|
65
|
-
background-color: ${
|
|
65
|
+
background-color: ${x.linearGradientAnimation("-90deg")};
|
|
66
66
|
min-height: 28.75rem;
|
|
67
67
|
}
|
|
68
68
|
|
|
@@ -80,4 +80,4 @@
|
|
|
80
80
|
max-height: 28.75rem;
|
|
81
81
|
}
|
|
82
82
|
}
|
|
83
|
-
`,
|
|
83
|
+
`,y=l.forwardRef(({},n)=>r.jsx(h,{ref:n,children:r.jsx("div",{className:"img-skeleton"})})),w=({limit:n=2,isLoading:t=!1,keyPrefix:o})=>r.jsx(r.Fragment,{children:Array.from({length:n},(s,a)=>r.jsx(y,{isLoading:t},`${o}-skeleton-product-card-${a}`))}),m=({children:n,fallbackComponent:t=r.jsx(r.Fragment,{}),isLoading:o=!1,limit:s,keyPrefix:a})=>r.jsx(l.Suspense,{fallbackComponent:t,children:o===!0?r.jsx(w,{isLoading:o,limit:s,keyPrefix:a}):n}),k=l.forwardRef(({title:n,image:t,backgroundColor:o,description:s,buttonText:a,handleClick:c=()=>{},onButtonAction:i=()=>{}},e)=>{const{theme:d}=j.useTheme();return r.jsx(r.Fragment,{children:r.jsxs(h,{ref:e,theme:d,overlay:o,onClick:c,children:[r.jsx("img",{src:t}),r.jsxs("div",{className:"content-wrapper",children:[r.jsxs("div",{className:"content-text",children:[r.jsx("div",{children:n}),r.jsx("div",{className:"content-text-title",children:s})]}),x.isDefinedNotEmptyString(a)&&r.jsx(f,{text:a,onClick:i,className:"text__action",size:"medium",color:"gray"})]})]})})}),b=l.forwardRef(({title:n,items:t,limit:o=2,onSelectCard:s=()=>{},isLoading:a=!1,onButtonAction:c=()=>{}},i)=>r.jsxs(p.RegulatTitleSectionWrapper,{ref:i,children:[r.jsx("div",{className:"regular-title center",children:r.jsx("div",{className:"regular-title-text",children:r.jsx("span",{children:n})})}),r.jsx(v,{limit:o,children:r.jsx(m,{isLoading:a,limit:o,keyPrefix:"explore-landing",children:t==null?void 0:t.map((e,d)=>r.jsx(k,{title:e==null?void 0:e.title,image:e==null?void 0:e.imageUrl,description:e==null?void 0:e.description,buttonText:e==null?void 0:e.buttonText,backgroundColor:e==null?void 0:e.backgroundColor,handleClick:()=>s(e==null?void 0:e.selectAction,e),onButtonAction:()=>c(e==null?void 0:e.buttonLink,e)},`landing-page-overlay-general-card__${d+1}`))})})]}));module.exports=b;
|