@lanaco/lnc-react-ui 4.0.127 → 4.0.129

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.
@@ -26,7 +26,7 @@
26
26
  & img {
27
27
  max-height: 12.5625rem;
28
28
  min-height: 12.5625rem;
29
- object-fit: cover;
29
+ object-fit: fill;
30
30
  width: 100%;
31
31
  }
32
32
 
@@ -74,4 +74,4 @@
74
74
  color: var(--gray-700, #4e555f);
75
75
  ${u.truncateTextInRows(3)}
76
76
  }
77
- `,$=c.forwardRef((t,o)=>{const{title:i,imageUrl:s,text:l,onCardClick:d,readMoreText:m="Read more"}=t;return r.jsxs(S,{ref:o,className:"blog-card",onClick:d,children:[r.jsx(M.ProductImageWrapper,{src:s}),r.jsxs(b,{children:[r.jsx("div",{className:"text-wr-title",children:i}),r.jsx("div",{className:"text-wr",children:l})]}),r.jsx(R,{className:"action",color:"gray",onClick:d,children:m})]})}),I=c.forwardRef(({},t)=>r.jsxs(S,{className:"product-card",children:[r.jsx("div",{className:"skeleton-img"}),r.jsx("div",{className:"card-title"}),r.jsx(b,{})]})),P=({limit:t=3,isLoading:o=!1,keyPrefix:i})=>r.jsx(r.Fragment,{children:Array.from({length:t},(s,l)=>r.jsx(I,{isLoading:o},`${i}-skeleton-product-card-${l}`))}),T=({children:t,fallbackComponent:o=r.jsx(r.Fragment,{}),isLoading:i=!1,limit:s,keyPrefix:l})=>r.jsx(c.Suspense,{fallbackComponent:o,children:i===!0?r.jsx(P,{isLoading:i,limit:s,keyPrefix:l}):t}),j=c.memo($),_=c.forwardRef((t,o)=>{const{icon:i,title:s,onButtonAction:l=()=>{},onSelectCard:d=()=>{},buttonLink:m,items:n,buttonText:v,limit:g=3,isLoading:w=!1,getImage:h=()=>{},readMoreText:f="Read more"}=t,k=N.useDetectMobile(),C=c.useMemo(()=>r.jsx(r.Fragment,{children:k===!0?n==null?void 0:n.map((e,a)=>r.jsx(j,{title:e==null?void 0:e.title,imageUrl:h(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,readMoreText:f,onCardClick:()=>d(e==null?void 0:e.titleSlug)},a)):n==null?void 0:n.slice(0,g).map((e,a)=>r.jsx(j,{title:e==null?void 0:e.title,imageUrl:h(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,readMoreText:f,onCardClick:()=>d(e==null?void 0:e.titleSlug)},a))}),[n]);return r.jsxs(q.RegulatTitleSectionWrapper,{ref:o,children:[r.jsxs("div",{className:"regular-title",children:[r.jsxs("div",{className:"regular-title-text",children:[u.isDefinedNotEmptyString(i)&&r.jsx("i",{className:i}),r.jsx("span",{children:s})]}),u.isDefinedNotEmptyString(m)&&r.jsx(x,{type:"button",btnType:"tinted",color:"neutral",onClick:e=>{var a;(a=e==null?void 0:e.target)==null||a.blur(),l(m)},borderRadius:"curved",className:"button-link",children:v})]}),r.jsx(B,{limit:g,children:r.jsx(T,{isLoading:w,limit:g,keyPrefix:"explore-landing",children:C})})]})});module.exports=_;
77
+ `,$=c.forwardRef((t,l)=>{const{title:i,imageUrl:s,text:o,onCardClick:d,readMoreText:m="Read more"}=t;return r.jsxs(S,{ref:l,className:"blog-card",onClick:d,children:[r.jsx(M.ProductImageWrapper,{src:s}),r.jsxs(b,{children:[r.jsx("div",{className:"text-wr-title",children:i}),r.jsx("div",{className:"text-wr",children:o})]}),r.jsx(R,{className:"action",color:"gray",onClick:d,children:m})]})}),I=c.forwardRef(({},t)=>r.jsxs(S,{className:"product-card",children:[r.jsx("div",{className:"skeleton-img"}),r.jsx("div",{className:"card-title"}),r.jsx(b,{})]})),P=({limit:t=3,isLoading:l=!1,keyPrefix:i})=>r.jsx(r.Fragment,{children:Array.from({length:t},(s,o)=>r.jsx(I,{isLoading:l},`${i}-skeleton-product-card-${o}`))}),T=({children:t,fallbackComponent:l=r.jsx(r.Fragment,{}),isLoading:i=!1,limit:s,keyPrefix:o})=>r.jsx(c.Suspense,{fallbackComponent:l,children:i===!0?r.jsx(P,{isLoading:i,limit:s,keyPrefix:o}):t}),j=c.memo($),_=c.forwardRef((t,l)=>{const{icon:i,title:s,onButtonAction:o=()=>{},onSelectCard:d=()=>{},buttonLink:m,items:n,buttonText:v,limit:g=3,isLoading:w=!1,getImage:h=()=>{},readMoreText:f="Read more"}=t,k=N.useDetectMobile(),C=c.useMemo(()=>r.jsx(r.Fragment,{children:k===!0?n==null?void 0:n.map((e,a)=>r.jsx(j,{title:e==null?void 0:e.title,imageUrl:h(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,readMoreText:f,onCardClick:()=>d(e==null?void 0:e.titleSlug)},a)):n==null?void 0:n.slice(0,g).map((e,a)=>r.jsx(j,{title:e==null?void 0:e.title,imageUrl:h(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,readMoreText:f,onCardClick:()=>d(e==null?void 0:e.titleSlug)},a))}),[n]);return r.jsxs(q.RegulatTitleSectionWrapper,{ref:l,children:[r.jsxs("div",{className:"regular-title",children:[r.jsxs("div",{className:"regular-title-text",children:[u.isDefinedNotEmptyString(i)&&r.jsx("i",{className:i}),r.jsx("span",{children:s})]}),u.isDefinedNotEmptyString(m)&&r.jsx(x,{type:"button",btnType:"tinted",color:"neutral",onClick:e=>{var a;(a=e==null?void 0:e.target)==null||a.blur(),o(m)},borderRadius:"curved",className:"button-link",children:v})]}),r.jsx(B,{limit:g,children:r.jsx(T,{isLoading:w,limit:g,keyPrefix:"explore-landing",children:C})})]})});module.exports=_;
@@ -36,7 +36,7 @@ const E = h.div`
36
36
  & img {
37
37
  max-height: 12.5625rem;
38
38
  min-height: 12.5625rem;
39
- object-fit: cover;
39
+ object-fit: fill;
40
40
  width: 100%;
41
41
  }
42
42
 
@@ -1,4 +1,4 @@
1
- "use strict";const n=require("react/jsx-runtime"),d=require("react"),t=require("./index-BpbMKBf_.cjs"),u=require("./Button.cjs"),g=require("./emotion-styled.browser.esm-BtEseadx.cjs"),f=require("./consts-goSZX3xP.cjs"),_=g.styled.div`
1
+ "use strict";const n=require("react/jsx-runtime"),d=require("react"),t=require("./index-BpbMKBf_.cjs"),u=require("./Button.cjs"),f=require("./emotion-styled.browser.esm-BtEseadx.cjs"),g=require("./consts-goSZX3xP.cjs"),_=f.styled.div`
2
2
  display: flex;
3
3
  height: 28.75rem;
4
4
  padding: 2.25rem;
@@ -8,11 +8,12 @@
8
8
  cursor: pointer;
9
9
  flex: 1;
10
10
  flex-shrink: 0;
11
- background: ${r=>r==null?void 0:r.backgroundColor}, url(${r=>r==null?void 0:r.backgroundImage});
11
+ background: ${r=>r==null?void 0:r.backgroundColor}, url("${r=>r==null?void 0:r.backgroundImage}");
12
12
  background-size: cover;
13
13
  background-repeat: no-repeat;
14
14
  background-position: center;
15
15
  border-radius: 0.75rem;
16
+ transition: flex 0.3s ease;
16
17
 
17
18
  &:hover {
18
19
  flex: 2;
@@ -59,9 +60,10 @@
59
60
  }
60
61
  }
61
62
 
62
- @media (max-width: ${f.MOBILE_SIZE_PX+"px"}) {
63
+ @media (max-width: ${g.MOBILE_SIZE_PX+"px"}) {
63
64
  padding: 2rem;
64
65
  min-height: 17.5rem;
66
+ width: 100%;
65
67
 
66
68
  &:hover {
67
69
  flex: 1;
@@ -81,7 +83,7 @@
81
83
  }
82
84
  }
83
85
  }
84
- `,h=d.forwardRef(({title:r,description:o,buttonText:i,imageUrl:s,backgroundColor:c,handleSelectCard:e=()=>{},handleButtonAction:l=()=>{}},m)=>n.jsxs(_,{backgroundImage:s,backgroundColor:c,onClick:e,children:[n.jsxs("div",{className:"section__text",children:[r&&n.jsx("div",{className:"section__title",children:r}),o&&n.jsx("div",{className:"section__description",children:o})]}),n.jsx(u,{text:i,onClick:a=>{a==null||a.stopPropagation(),l()},borderRadius:"regular",color:"gray",className:"section__action"})]}));h.propTypes={title:t.PropTypes.string,description:t.PropTypes.string,buttonText:t.PropTypes.string,imageUrl:t.PropTypes.string,backgroundColor:t.PropTypes.string,handleSelectCard:t.PropTypes.func,handleButtonAction:t.PropTypes.func};const x=g.styled.div`
86
+ `,h=d.forwardRef(({title:r,description:o,buttonText:i,imageUrl:s,backgroundColor:c="none",handleSelectCard:e=()=>{},handleButtonAction:l=()=>{}},m)=>n.jsxs(_,{backgroundImage:s,backgroundColor:c,onClick:e,children:[n.jsxs("div",{className:"section__text",children:[r&&n.jsx("div",{className:"section__title",children:r}),o&&n.jsx("div",{className:"section__description",children:o})]}),n.jsx(u,{text:i,onClick:a=>{a==null||a.stopPropagation(),l()},borderRadius:"regular",color:"gray",className:"section__action"})]}));h.propTypes={title:t.PropTypes.string,description:t.PropTypes.string,buttonText:t.PropTypes.string,imageUrl:t.PropTypes.string,backgroundColor:t.PropTypes.string,handleSelectCard:t.PropTypes.func,handleButtonAction:t.PropTypes.func};const x=f.styled.div`
85
87
  display: flex;
86
88
  flex-direction: column;
87
89
  align-items: flex-start;
@@ -120,7 +122,7 @@
120
122
  }
121
123
  }
122
124
 
123
- @media (max-width: ${f.MOBILE_SIZE_PX+"px"}) {
125
+ @media (max-width: ${g.MOBILE_SIZE_PX+"px"}) {
124
126
  & .section__title {
125
127
  font-size: 1.375rem;
126
128
  line-height: 1.75rem;
@@ -14,11 +14,12 @@ const u = g.div`
14
14
  cursor: pointer;
15
15
  flex: 1;
16
16
  flex-shrink: 0;
17
- background: ${(r) => r == null ? void 0 : r.backgroundColor}, url(${(r) => r == null ? void 0 : r.backgroundImage});
17
+ background: ${(r) => r == null ? void 0 : r.backgroundColor}, url("${(r) => r == null ? void 0 : r.backgroundImage}");
18
18
  background-size: cover;
19
19
  background-repeat: no-repeat;
20
20
  background-position: center;
21
21
  border-radius: 0.75rem;
22
+ transition: flex 0.3s ease;
22
23
 
23
24
  &:hover {
24
25
  flex: 2;
@@ -68,6 +69,7 @@ const u = g.div`
68
69
  @media (max-width: ${h + "px"}) {
69
70
  padding: 2rem;
70
71
  min-height: 17.5rem;
72
+ width: 100%;
71
73
 
72
74
  &:hover {
73
75
  flex: 1;
@@ -93,7 +95,7 @@ const u = g.div`
93
95
  description: n,
94
96
  buttonText: i,
95
97
  imageUrl: a,
96
- backgroundColor: d,
98
+ backgroundColor: d = "none",
97
99
  handleSelectCard: e = () => {
98
100
  },
99
101
  handleButtonAction: l = () => {
@@ -371,6 +371,7 @@
371
371
  display: grid;
372
372
  grid-template-columns: repeat(${e=>e==null?void 0:e.numOfColumns}, 1fr);
373
373
  gap: 1.5rem;
374
+ width: 100%;
374
375
 
375
376
  @media (max-width: ${M.MOBILE_SIZE_PX+"px"}) {
376
377
  grid-template-columns: repeat(${e=>e==null?void 0:e.numOfColumnsForMobile}, 1fr);
@@ -678,6 +678,7 @@ const G = m.div`
678
678
  display: grid;
679
679
  grid-template-columns: repeat(${(e) => e == null ? void 0 : e.numOfColumns}, 1fr);
680
680
  gap: 1.5rem;
681
+ width: 100%;
681
682
 
682
683
  @media (max-width: ${M + "px"}) {
683
684
  grid-template-columns: repeat(${(e) => e == null ? void 0 : e.numOfColumnsForMobile}, 1fr);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lanaco/lnc-react-ui",
3
- "version": "4.0.127",
3
+ "version": "4.0.129",
4
4
  "description": "React component library",
5
5
  "type": "module",
6
6
  "keywords": [