@npm_leadtech/legal-lib-components 5.9.1 → 5.9.2
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.
|
@@ -3,6 +3,6 @@ import ArrowRight from '../../../../images/svg/arrow-right-24px-outlined.svg';
|
|
|
3
3
|
import { ArticleStyled } from './Article.styled';
|
|
4
4
|
import { Button } from '../../atoms';
|
|
5
5
|
const Article = ({ imageUrl, title, articleUrl, summary, isCategoryProductPage }) => {
|
|
6
|
-
return (_jsxs(ArticleStyled, { className: 'article', children: [_jsx("img", { src: imageUrl, className: 'image', loading: 'lazy', alt: title }), _jsxs("div", { className: 'information', children: [_jsx("a", { href: articleUrl, target: '_blank', rel: 'noreferrer', children: _jsxs("p", { className: 'title sans-serif --big', children: [title, " "] }) }), _jsx("div", { className: 'summary', children: summary }), isCategoryProductPage ? (_jsxs("div", { className: 'button-image-container', children: [_jsx(Button, { givenClass: 'thinner-letter', color: 'tertiary', label: 'Read more', dataQa: 'article-read-more', link: articleUrl, isExternal: true }), _jsx("img", { className: 'article__arrow-right', src: ArrowRight, alt: '' })] })) : (_jsx(Button, { color: 'tertiary', label: 'Read more', dataQa: 'article-read-more', link: articleUrl, isExternal: true }))] })] }));
|
|
6
|
+
return (_jsxs(ArticleStyled, { className: 'article', children: [_jsx("img", { src: imageUrl, className: isCategoryProductPage ? 'image image-category' : 'image', loading: 'lazy', alt: title }), _jsxs("div", { className: isCategoryProductPage ? 'information information-category' : 'information', children: [_jsx("a", { href: articleUrl, target: '_blank', rel: 'noreferrer', children: _jsxs("p", { className: 'title sans-serif --big', children: [title, " "] }) }), _jsx("div", { className: 'summary', children: summary }), isCategoryProductPage ? (_jsxs("div", { className: 'button-image-container', children: [_jsx(Button, { givenClass: 'thinner-letter', color: 'tertiary', label: 'Read more', dataQa: 'article-read-more', link: articleUrl, isExternal: true }), _jsx("img", { className: 'article__arrow-right', src: ArrowRight, alt: '' })] })) : (_jsx(Button, { color: 'tertiary', label: 'Read more', dataQa: 'article-read-more', link: articleUrl, isExternal: true }))] })] }));
|
|
7
7
|
};
|
|
8
8
|
export default Article;
|
|
@@ -25,6 +25,13 @@ export const ArticleStyled = styled.div `
|
|
|
25
25
|
}
|
|
26
26
|
}
|
|
27
27
|
|
|
28
|
+
.image-category {
|
|
29
|
+
@media ${device.laptop} {
|
|
30
|
+
width: 100%;
|
|
31
|
+
height: 13em;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
|
|
28
35
|
.information {
|
|
29
36
|
width: 100%;
|
|
30
37
|
padding: 1rem 1.5rem 0;
|
|
@@ -79,4 +86,11 @@ export const ArticleStyled = styled.div `
|
|
|
79
86
|
}
|
|
80
87
|
}
|
|
81
88
|
}
|
|
89
|
+
|
|
90
|
+
.information-category {
|
|
91
|
+
@media ${device['landscape-tablets']} {
|
|
92
|
+
width: 100%;
|
|
93
|
+
height: auto;
|
|
94
|
+
}
|
|
95
|
+
}
|
|
82
96
|
`;
|
|
@@ -26,6 +26,13 @@ export const ArticleStyled = styled.div`
|
|
|
26
26
|
}
|
|
27
27
|
}
|
|
28
28
|
|
|
29
|
+
.image-category {
|
|
30
|
+
@media ${device.laptop} {
|
|
31
|
+
width: 100%;
|
|
32
|
+
height: 13em;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
|
|
29
36
|
.information {
|
|
30
37
|
width: 100%;
|
|
31
38
|
padding: 1rem 1.5rem 0;
|
|
@@ -80,4 +87,11 @@ export const ArticleStyled = styled.div`
|
|
|
80
87
|
}
|
|
81
88
|
}
|
|
82
89
|
}
|
|
90
|
+
|
|
91
|
+
.information-category {
|
|
92
|
+
@media ${device['landscape-tablets']} {
|
|
93
|
+
width: 100%;
|
|
94
|
+
height: auto;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
83
97
|
`
|
|
@@ -8,8 +8,13 @@ import { Button } from '../../atoms'
|
|
|
8
8
|
const Article: FC<ArticleProps> = ({ imageUrl, title, articleUrl, summary, isCategoryProductPage }) => {
|
|
9
9
|
return (
|
|
10
10
|
<ArticleStyled className='article'>
|
|
11
|
-
<img
|
|
12
|
-
|
|
11
|
+
<img
|
|
12
|
+
src={imageUrl}
|
|
13
|
+
className={isCategoryProductPage ? 'image image-category' : 'image'}
|
|
14
|
+
loading='lazy'
|
|
15
|
+
alt={title}
|
|
16
|
+
/>
|
|
17
|
+
<div className={isCategoryProductPage ? 'information information-category' : 'information'}>
|
|
13
18
|
<a href={articleUrl} target='_blank' rel='noreferrer'>
|
|
14
19
|
<p className='title sans-serif --big'>{title} </p>
|
|
15
20
|
</a>
|