gatsby-matrix-theme 53.4.1 → 53.4.3
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/CHANGELOG.md +19 -0
- package/package.json +2 -2
- package/src/components/atoms/cards/article-card/template-one/index.js +16 -11
- package/storybook/public/{384.1251be93.iframe.bundle.js → 384.14a3783a.iframe.bundle.js} +4 -4
- package/storybook/public/{384.1251be93.iframe.bundle.js.map → 384.14a3783a.iframe.bundle.js.map} +1 -1
- package/storybook/public/iframe.html +1 -1
- package/storybook/public/main.680a5fbc.iframe.bundle.js +1 -0
- package/storybook/public/project.json +1 -1
- package/storybook/public/main.55852b85.iframe.bundle.js +0 -1
- /package/storybook/public/{384.1251be93.iframe.bundle.js.LICENSE.txt → 384.14a3783a.iframe.bundle.js.LICENSE.txt} +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,22 @@
|
|
|
1
|
+
## [53.4.3](https://gitlab.com/g2m-gentoo/team-floyd/themes/matrix-theme/compare/v53.4.2...v53.4.3) (2025-11-17)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* article card image ([61f5f87](https://gitlab.com/g2m-gentoo/team-floyd/themes/matrix-theme/commit/61f5f87806f7d92e2c8028b76d5a2f6132df3779))
|
|
7
|
+
* update deploy ([519902b](https://gitlab.com/g2m-gentoo/team-floyd/themes/matrix-theme/commit/519902bc778d8d877a7a5abe02079f9d03f6e024))
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
* Merge branch 'fix/article-card-images' into 'master' ([2125329](https://gitlab.com/g2m-gentoo/team-floyd/themes/matrix-theme/commit/212532940abda3922cc20acf4cf07b39253e6372))
|
|
11
|
+
* Merge branch 'update-deploy' into 'master' ([2991459](https://gitlab.com/g2m-gentoo/team-floyd/themes/matrix-theme/commit/299145996314631207b873fd10a0c1e4e9e7940b))
|
|
12
|
+
|
|
13
|
+
## [53.4.2](https://gitlab.com/g2m-gentoo/team-floyd/themes/matrix-theme/compare/v53.4.1...v53.4.2) (2025-11-13)
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
### Config
|
|
17
|
+
|
|
18
|
+
* update theme ([4b1af63](https://gitlab.com/g2m-gentoo/team-floyd/themes/matrix-theme/commit/4b1af63453554bed454863e2451f5efc9c84aefa))
|
|
19
|
+
|
|
1
20
|
## [53.4.1](https://gitlab.com/g2m-gentoo/team-floyd/themes/matrix-theme/compare/v53.4.0...v53.4.1) (2025-11-10)
|
|
2
21
|
|
|
3
22
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "gatsby-matrix-theme",
|
|
3
|
-
"version": "53.4.
|
|
3
|
+
"version": "53.4.3",
|
|
4
4
|
"main": "index.js",
|
|
5
5
|
"description": "Matrix Theme NPM Package",
|
|
6
6
|
"author": "",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"@react-icons/all-files": "^4.1.0",
|
|
27
27
|
"gatsby": "^5.11.0",
|
|
28
|
-
"gatsby-core-theme": "44.
|
|
28
|
+
"gatsby-core-theme": "44.7.1",
|
|
29
29
|
"gatsby-plugin-sharp": "^5.11.0",
|
|
30
30
|
"gatsby-transformer-sharp": "^5.11.0",
|
|
31
31
|
"gatsby-plugin-sitemap": "^6.13.1",
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/* eslint-disable import/no-extraneous-dependencies */
|
|
2
2
|
/* eslint-disable camelcase */
|
|
3
|
-
import React from 'react';
|
|
3
|
+
import React, { useMemo } from 'react';
|
|
4
4
|
import PropTypes from 'prop-types';
|
|
5
5
|
import Link from 'gatsby-core-theme/src/hooks/link';
|
|
6
6
|
import { imagePrettyUrl } from 'gatsby-core-theme/src/helpers/getters';
|
|
@@ -22,19 +22,17 @@ const ArticleCard = ({
|
|
|
22
22
|
verifyIcon = '',
|
|
23
23
|
showImageAsLink = true,
|
|
24
24
|
}) => {
|
|
25
|
-
const { title, path, banner, reading_time } = item;
|
|
25
|
+
const { title, path, banner, reading_time, relation } = item;
|
|
26
26
|
const defaultImg = (
|
|
27
27
|
<LazyImage width={width} height={height} src="/images/default-article.jpg" alt={title} />
|
|
28
28
|
);
|
|
29
|
-
|
|
29
|
+
const logo = useMemo(() => {
|
|
30
|
+
if (banner) return imagePrettyUrl(banner, width, height);
|
|
31
|
+
if (relation?.logo?.filename) return imagePrettyUrl(relation?.logo?.filename, width, height);
|
|
32
|
+
return undefined;
|
|
33
|
+
}, [banner, relation, height, width]);
|
|
30
34
|
const imageElement = (
|
|
31
|
-
<LazyImage
|
|
32
|
-
width={width}
|
|
33
|
-
height={height}
|
|
34
|
-
defaultImg={defaultImg}
|
|
35
|
-
src={banner ? imagePrettyUrl(banner, width, height) : undefined}
|
|
36
|
-
alt={title}
|
|
37
|
-
/>
|
|
35
|
+
<LazyImage width={width} height={height} defaultImg={defaultImg} src={logo} alt={title} />
|
|
38
36
|
);
|
|
39
37
|
return (
|
|
40
38
|
<div className={styles.article || ''}>
|
|
@@ -79,6 +77,13 @@ ArticleCard.propTypes = {
|
|
|
79
77
|
path: PropTypes.string,
|
|
80
78
|
banner: PropTypes.string,
|
|
81
79
|
reading_time: PropTypes.string,
|
|
80
|
+
relation: PropTypes.shape({
|
|
81
|
+
logo: PropTypes.shape({
|
|
82
|
+
alt: PropTypes.string,
|
|
83
|
+
color: PropTypes.string,
|
|
84
|
+
filename: PropTypes.string,
|
|
85
|
+
}),
|
|
86
|
+
}),
|
|
82
87
|
}).isRequired,
|
|
83
88
|
width: PropTypes.number,
|
|
84
89
|
height: PropTypes.number,
|
|
@@ -88,7 +93,7 @@ ArticleCard.propTypes = {
|
|
|
88
93
|
showAuthorAsLink: PropTypes.bool,
|
|
89
94
|
readingTime: PropTypes.bool,
|
|
90
95
|
verifyIcon: PropTypes.string,
|
|
91
|
-
showImageAsLink: PropTypes.bool
|
|
96
|
+
showImageAsLink: PropTypes.bool,
|
|
92
97
|
};
|
|
93
98
|
|
|
94
99
|
export default ArticleCard;
|