gatsby-core-theme 11.0.7 → 11.0.9

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 CHANGED
@@ -1,3 +1,32 @@
1
+ ## [11.0.9](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/compare/v11.0.8...v11.0.9) (2022-09-23)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * add standardised logo ([d971d8f](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/d971d8fa53becf1af1bce0e2b020fafe2a3d2a4b))
7
+ * add width and height ([59e1f94](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/59e1f94612c6cf2dd153c3fdf9f261ccf472b8ef))
8
+ * sitemap style isuses ([0fb3850](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/0fb3850a3c69ae6efe498f5574f55c20c51a2dbd))
9
+
10
+
11
+ * Merge branch 'tm-3022-search-atuocomplet' into 'master' ([1eb21c5](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/1eb21c5787eb673e828665d1b177085d6acdcdf4))
12
+ * Merge branch 'tm-3017-sitemap' into 'master' ([759cb3b](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/759cb3b158586515a4b4d0b29c067518c4406eef))
13
+
14
+ ## [11.0.8](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/compare/v11.0.7...v11.0.8) (2022-09-21)
15
+
16
+
17
+ ### Bug Fixes
18
+
19
+ * add featured image in meta data ([b3f9a99](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/b3f9a99e14329f7673d3aaf1bc194e926577c762))
20
+ * fix error ([2a0d8a6](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/2a0d8a641c37af2fd996473fa6871ad50dda2cd9))
21
+ * fix test ([cd98669](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/cd9866989a359d7bac8d7fc528b3f80fb118fb7d))
22
+ * get Standardised Logo ([9d84566](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/9d84566948bf9be605968c785f303f4e0ec9618a))
23
+ * validate data of author ([e11130f](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/e11130f668cfd789437d528f90b89ed6a646b4c5))
24
+
25
+
26
+ * Merge branch 'tm-3040-featured-images' into 'master' ([8d315a9](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/8d315a94f779d32b9ad88463ccbe13a6fe21d1f1))
27
+ * Merge branch 'validate-author-data' into 'master' ([7cac787](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/7cac7872cd4fe76ebf0951575e08fa28742a0ee2))
28
+ * Merge branch 'tm-3040-featured-images' into 'master' ([ee074ee](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/ee074eebdad84057b4ba61b4f9cbdd755a35a4e0))
29
+
1
30
  ## [11.0.7](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/compare/v11.0.6...v11.0.7) (2022-09-12)
2
31
 
3
32
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gatsby-core-theme",
3
- "version": "11.0.7",
3
+ "version": "11.0.9",
4
4
  "description": "Gatsby Theme NPM Package",
5
5
  "main": "index.js",
6
6
  "GATSBY_RECAPTCHA_SITEKEY": "6LfoyvMUAAAAAO4nl_MQnqHb4XdHxEiu5cXgIqeB",
@@ -6,13 +6,18 @@ import { imagePrettyUrl } from '~helpers/getters';
6
6
  import Button from '~atoms/button';
7
7
  import styles from './operator.module.scss';
8
8
 
9
- const Operator = ({ item = {} }) => (
10
- <div className={styles.row}>
11
- <LazyImage src={imagePrettyUrl(item.relation.logo_url, null, 20)} alt={item.title} />
12
- <h3>{item.title}</h3>
13
- <Button to="/#" primaryColor isInternalLink={false} gtmClass="operator-gtm btn-cta" />
14
- </div>
15
- );
9
+ const Operator = ({ item = {} }) => {
10
+ const { relation } = item;
11
+ const img = relation?.standardised_logo_url_object?.filename || relation.logo_url;
12
+
13
+ return (
14
+ <div className={styles.row}>
15
+ <LazyImage width={56} height={56} src={imagePrettyUrl(img, 56, 56)} alt={item.title} />
16
+ <h3>{item.title}</h3>
17
+ <Button to="/#" primaryColor isInternalLink={false} gtmClass="operator-gtm btn-cta" />
18
+ </div>
19
+ );
20
+ };
16
21
 
17
22
  Operator.propTypes = {
18
23
  item: PropTypes.shape({
@@ -28,7 +28,18 @@
28
28
 
29
29
  > div {
30
30
  position: relative;
31
- @include flex-align(center, flex-start);
31
+ @include flex-align(flex-start, flex-start);
32
+
33
+ &::after {
34
+ content: ' ';
35
+ border-right: var(--sitemap-connector-border, dashed 1px #e3e6ef);
36
+ left: -1px;
37
+ position: absolute;
38
+ top: 0%;
39
+ width: 2.5rem;
40
+ height: 103%;
41
+ display: var(--sitemap-header-line-border, block);
42
+ }
32
43
 
33
44
  svg {
34
45
  fill: var(--template-name-icon-color, white);
@@ -45,12 +56,14 @@
45
56
  font-size: var(--template-name-font-size, 2rem);
46
57
  margin-left: 1.6rem;
47
58
  text-transform: capitalize;
59
+ word-break: break-word;
48
60
  }
49
61
 
50
62
  > div {
51
63
  position: relative;
52
64
  display: flex;
53
65
  align-items: center;
66
+ z-index: 3;
54
67
 
55
68
  span {
56
69
  @include flex-align(center, center);
@@ -150,19 +150,24 @@ export function imagePrettyUrl(filename = 'image.png', width = null, height = nu
150
150
 
151
151
  export function getPageImage(page) {
152
152
  if (page.type === 'operator') {
153
- if (page.relation.default_logo_url) {
154
- return imagePrettyUrl(page.relation.default_logo_url);
153
+ if (page.featured_image) {
154
+ return imagePrettyUrl(page.featured_image);
155
+ }
156
+ if (page.relation.default_logo_url || page.relation.standardised_logo_url) {
157
+ return imagePrettyUrl(page.relation.standardised_logo_url || page.relation.default_logo_url);
155
158
  }
156
159
  return imagePrettyUrl(page.relation.logo_url);
157
160
  }
161
+
158
162
  if (page.type === 'game') {
159
- if (page.banner) {
160
- return imagePrettyUrl(page.banner);
163
+ if (page.featured_image) {
164
+ return imagePrettyUrl(page.featured_image);
161
165
  }
162
166
  if (page.relation.thumbnail_filename) {
163
167
  return page.relation.thumbnail_filename;
164
168
  }
165
169
  }
170
+
166
171
  if (page.type === 'software_provider' && page.relation.logo) {
167
172
  return imagePrettyUrl(page.relation.logo);
168
173
  }
@@ -92,7 +92,7 @@ describe('Getters Helper', () => {
92
92
  expect(
93
93
  Getters.getPageImage({ type: 'game', relation: { thumbnail_filename: 'foo.jpg' } })
94
94
  ).toEqual('foo.jpg');
95
- expect(Getters.getPageImage({ type: 'game', banner: 'bar.gif' })).toEqual(
95
+ expect(Getters.getPageImage({ type: 'game', featured_image: 'bar.gif' })).toEqual(
96
96
  Getters.imagePrettyUrl('bar.gif')
97
97
  );
98
98
  expect(Getters.getPageImage({ type: 'article', banner: 'bar.svg' })).toEqual(
@@ -255,8 +255,9 @@ export function processTopListModule(module, relations, pages) {
255
255
  : [];
256
256
 
257
257
  if (operatorPage.length >= 1 && operatorPage[0].author) {
258
- clone.authorName = operatorPage[0].author.name;
259
- clone.authorPath = operatorPage[0].author.profile_page_path;
258
+ clone.authorName = operatorPage[0].author.name && operatorPage[0].author.name;
259
+ clone.authorPath =
260
+ operatorPage[0].author.profile_page_path && operatorPage[0].author.profile_page_path;
260
261
  }
261
262
  delete clone.software;
262
263
  delete clone.bonus.deposit_methods;