gatsby-matrix-theme 7.1.29 → 7.1.32

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,38 @@
1
+ ## [7.1.32](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/compare/v7.1.31...v7.1.32) (2022-07-06)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * add option for affiliate link ([a0cbf0c](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/a0cbf0c4ca2919780828d9cc7b79a8ef218dec49))
7
+ * config: update core theme ([7bad9e7](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/7bad9e7a73bd028ac0bb82b8c1094e11b02976c1))
8
+ * enabled adding multiple ribbons on toplists ([a3c813a](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/a3c813ae4718534882a91ac9b7430a3df3a4694e))
9
+ * hide button when isnt selected any operator ([96ffd2a](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/96ffd2a8ae8567bc789d2c089513ecc17b7b2fd7))
10
+ * removed extra spaces from review link in comparison tab.e ([b9c0e26](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/b9c0e26dd808c26c243fff31b0ba8cb9229ce1e9))
11
+ * updated module intro to use the core component ([43f663d](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/43f663ddd71907d6b93734c423247abbcb65d84d))
12
+
13
+
14
+ * Merge branch 'tm-2934-adding-2-links-card' into 'master' ([41486b2](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/41486b2431b62fb66f44b1db99c94b62bf3b5009))
15
+ * Merge branch 'tm-2947-module-intro' into 'master' ([0c7c2e3](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/0c7c2e30d865225a3302e8d1fe600b13871ade45))
16
+ * Merge branch 'tm-2935-multiple-ribbons-for-toplists' into 'master' ([892102a](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/892102ad5fbcd20be4de98451140f94f2ec2638d))
17
+ * Merge branch 'master' of git.ilcd.rocks:team-floyd/themes/matrix-theme ([e43b8e5](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/e43b8e590e5bcc3ef86894191f40cf50041cf9dc))
18
+
19
+ ## [7.1.31](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/compare/v7.1.30...v7.1.31) (2022-07-01)
20
+
21
+
22
+ ### Bug Fixes
23
+
24
+ * make style and replaced headings to span ([ec24bbd](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/ec24bbd532dc6cc4a4b65a62b26ebcd1c823d1f2))
25
+
26
+
27
+ * Merge branch 'tm-2622-cookie' into 'master' ([8458ad5](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/8458ad5f80d41a9d98280513736fc16c118fd61e))
28
+
29
+ ## [7.1.30](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/compare/v7.1.29...v7.1.30) (2022-06-30)
30
+
31
+
32
+ ### Bug Fixes
33
+
34
+ * added standardized logos in comparison table as well as width and height for licence and withdrawal methods ([681eb1d](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/681eb1dcb8b3959948c84bbbdf2813beb0c6d71f))
35
+
1
36
  ## [7.1.29](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/compare/v7.1.28...v7.1.29) (2022-06-28)
2
37
 
3
38
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gatsby-matrix-theme",
3
- "version": "7.1.29",
3
+ "version": "7.1.32",
4
4
  "main": "index.js",
5
5
  "description": "Matrix Theme NPM Package",
6
6
  "author": "",
@@ -29,7 +29,7 @@
29
29
  "react": "^17.0.2",
30
30
  "gatsby-plugin-sitemap": "^3.3.0",
31
31
  "react-dom": "^17.0.2",
32
- "gatsby-core-theme": "^8.0.4"
32
+ "gatsby-core-theme": "^8.0.6"
33
33
  },
34
34
  "devDependencies": {
35
35
  "@babel/core": "^7.13.1",
@@ -78,6 +78,8 @@ export default function ComparisonTable({
78
78
  const CustomComponent = rowData.customComponent;
79
79
  return <CustomComponent key={key} operator={item} />;
80
80
  }
81
+ const imageObject =
82
+ item?.relation.standardised_logo_url_object || item?.relation.logo_url_object;
81
83
 
82
84
  switch (heading) {
83
85
  case 'casino_name':
@@ -85,7 +87,7 @@ export default function ComparisonTable({
85
87
  <td key={key} className={styles.casinoName}>
86
88
  {item?.relation?.logo_url ? (
87
89
  <LazyImg
88
- src={imagePrettyUrl(item?.relation?.logo_url)}
90
+ src={imagePrettyUrl(imageObject?.filename || item?.relation.logo_url, 89, 89)}
89
91
  height={89}
90
92
  width={89}
91
93
  alt={item.relation.name}
@@ -115,7 +117,7 @@ export default function ComparisonTable({
115
117
  <td key={key} className={styles.raiting}>
116
118
  <StarRating numOfStars={5} rating={item?.relation?.rating} />
117
119
  {type === 'operator' && index === 0 ? null : (
118
- <Link to={item.path}> {translate(translations, 'review', 'Review')} </Link>
120
+ <Link to={item.path}>{translate(translations, 'review', 'Review')}</Link>
119
121
  )}
120
122
  </td>
121
123
  );
@@ -150,7 +152,7 @@ export default function ComparisonTable({
150
152
  return (
151
153
  <LazyImg
152
154
  key={`${key}-${deposit.name}`}
153
- src={imagePrettyUrl(deposit?.logo_filename)}
155
+ src={imagePrettyUrl(deposit?.logo_filename, 72, 72)}
154
156
  width={72}
155
157
  height={72}
156
158
  alt={deposit.name}
@@ -209,8 +211,9 @@ export default function ComparisonTable({
209
211
  return (
210
212
  <LazyImg
211
213
  key={license.name}
212
- src={imagePrettyUrl(license?.logo_filename)}
214
+ src={imagePrettyUrl(license?.logo_filename, 72, 72)}
213
215
  height={32}
216
+ width={72}
214
217
  alt={license.name}
215
218
  />
216
219
  );
@@ -3,6 +3,7 @@ import React, { useContext } from 'react';
3
3
  import PropTypes from 'prop-types';
4
4
  import loadable from '@loadable/component';
5
5
  import Button from 'gatsby-core-theme/src/components/atoms/button';
6
+ import OperatorCta from 'gatsby-core-theme/src/components/atoms/operator-cta';
6
7
  import GatsbyImg from 'gatsby-core-theme/src/hooks/gatsby-img';
7
8
  import Link from 'gatsby-core-theme/src/hooks/link';
8
9
  import {
@@ -23,6 +24,7 @@ const GameCard = ({
23
24
  width = 300,
24
25
  height = 250,
25
26
  useOneStarRating = false,
27
+ affilateLink = false,
26
28
  }) => {
27
29
  const { relation, title, path, banner } = item;
28
30
  const cardBackgroundImage = getSectionExtraField(null, item, 'card_background_image');
@@ -34,6 +36,31 @@ const GameCard = ({
34
36
  ? loadable(() => import('gatsby-core-theme/src/components/molecules/star-rating/one-star'))
35
37
  : loadable(() => import('gatsby-core-theme/src/components/molecules/star-rating'));
36
38
 
39
+ const button = () => {
40
+ if (affilateLink) {
41
+ return (
42
+ <>
43
+ {item?.extra_fields?.operator ? (
44
+ <OperatorCta
45
+ tracker="main"
46
+ operator={item?.extra_fields?.operator}
47
+ playText={translate(translations, 'play_now_game', 'Play for Real')}
48
+ gtmClass="operator-card-gtm btn-cta"
49
+ />
50
+ ) : null}
51
+ </>
52
+ );
53
+ }
54
+ return (
55
+ <Button
56
+ to={path}
57
+ primaryColor={!featured}
58
+ btnText={translate(translations, button_text, 'Play now')}
59
+ className={styles.playNow}
60
+ gtmClass="game-card-gtm btn-cta"
61
+ />
62
+ );
63
+ };
37
64
  return (
38
65
  <BaseCard item={item} isLinked cardType="game">
39
66
  {!featured && (
@@ -75,13 +102,7 @@ const GameCard = ({
75
102
  )}
76
103
  </div>
77
104
  </div>
78
- <Button
79
- to={path}
80
- primaryColor={!featured}
81
- btnText={translate(translations, button_text, 'Play now')}
82
- className={styles.playNow}
83
- gtmClass="game-card-gtm btn-cta"
84
- />
105
+ {button()}
85
106
  </div>
86
107
  </BaseCard>
87
108
  );
@@ -102,11 +123,15 @@ GameCard.propTypes = {
102
123
  title: PropTypes.string,
103
124
  path: PropTypes.string,
104
125
  banner: PropTypes.string,
126
+ extra_fields: PropTypes.shape({
127
+ operator: PropTypes.shape({}),
128
+ }),
105
129
  }).isRequired,
106
130
  button_text: PropTypes.string,
107
131
  width: PropTypes.number,
108
132
  height: PropTypes.number,
109
133
  useOneStarRating: PropTypes.bool,
134
+ affilateLink: PropTypes.bool,
110
135
  };
111
136
 
112
137
  export default GameCard;
@@ -3,7 +3,7 @@
3
3
  overflow-y: hidden;
4
4
  background-color: #f3f2f2;
5
5
  border-radius: 8px;
6
- margin-bottom: 8px;
6
+ margin-top: 8px;
7
7
 
8
8
  .categoryHeader {
9
9
  display: flex;
@@ -19,6 +19,7 @@
19
19
  font-weight: 700;
20
20
  font-size: 14px;
21
21
  line-height: 22px;
22
+ text-align: right
22
23
  }
23
24
 
24
25
  .boxTitle {
@@ -27,7 +28,7 @@
27
28
  white-space: nowrap;
28
29
  overflow: hidden;
29
30
  text-overflow: ellipsis;
30
- > h3 {
31
+ > span {
31
32
  margin: 0px;
32
33
  padding-left: 10px;
33
34
  font-weight: 700;
@@ -23,7 +23,7 @@ const CategoryContainer = ({
23
23
  <div className={styles.categoryHeader}>
24
24
  <div className={styles.boxTitle}>
25
25
  {currentSection === index ? <AiOutlineMinus /> : <AiOutlinePlus />}
26
- <h3>{translate(translations, obj?.translateKey, obj?.altTranslation)}</h3>
26
+ <span>{translate(translations, obj?.translateKey, obj?.altTranslation)}</span>
27
27
  </div>
28
28
  {obj?.button ? (
29
29
  <ToggleButton state={currentState} setStateFunc={updateState} />
@@ -26,12 +26,10 @@
26
26
  margin-top: 18px;
27
27
  margin-bottom: 16px;
28
28
 
29
- h4 {
30
- margin: 0px;
29
+ span {
31
30
  font-size: 16px;
32
31
  font-weight: 700;
33
32
  line-height: 24px;
34
- margin-bottom: 8px;
35
33
  color: #150E06;
36
34
  }
37
35
  p {
@@ -39,6 +37,7 @@
39
37
  font-size: 14px;
40
38
  line-height: 19px;
41
39
  color: #150E06;
40
+ margin-top: 8px;
42
41
  }
43
42
  }
44
43
 
@@ -74,7 +73,7 @@
74
73
  }
75
74
  }
76
75
  .lastButton {
77
- padding-top: 6px;
76
+ padding-top: 16px;
78
77
  padding-bottom: 3.2rem;
79
78
  > button {
80
79
  height: 40px;
@@ -86,7 +85,21 @@
86
85
  @include min(tablet) {
87
86
  border-radius: 16px;
88
87
  padding: 34px 32px;
89
- overflow-y: hidden;
88
+ overflow-y: scroll;
89
+ max-height: 98vh;
90
+ &::-webkit-scrollbar {
91
+ width: 3px;
92
+ }
93
+ &::-webkit-scrollbar-track {
94
+ background: transparent;
95
+ }
96
+ &::-webkit-scrollbar-thumb {
97
+ background: #888;
98
+ border-radius: 10px;
99
+ }
100
+ &::-webkit-scrollbar-thumb:hover {
101
+ background: #555;
102
+ }
90
103
  .modalCookieHeader {
91
104
  justify-content: center;
92
105
  padding-bottom: 27px;
@@ -104,7 +117,7 @@
104
117
  margin-top: 0px;
105
118
  margin-bottom: 0px;
106
119
  color: #150e06;
107
- h4 {
120
+ span {
108
121
  font-size: 18px;
109
122
  line-height: 26px;
110
123
  }
@@ -131,6 +144,7 @@
131
144
  }
132
145
  }
133
146
  .lastButton {
147
+
134
148
  padding-bottom: 0rem;
135
149
  > button {
136
150
  width: auto;
@@ -44,7 +44,9 @@ const CookieModal = ({ acceptCookies, closeModal, logo = '../../../../../images/
44
44
  </button>
45
45
  </div>
46
46
  <div className={styles.modalTextHeader}>
47
- <h4>{translate(translations, 'privacy_preference_title', 'Privacy Preference Center')}</h4>
47
+ <span>
48
+ {translate(translations, 'privacy_preference_title', 'Privacy Preference Center')}
49
+ </span>
48
50
  <p>{translate(translations, 'privacy_preference_text')}</p>
49
51
  </div>
50
52
  <div className={styles.modalButtons}>
@@ -68,9 +70,9 @@ const CookieModal = ({ acceptCookies, closeModal, logo = '../../../../../images/
68
70
  />
69
71
  </div>
70
72
  <div className={styles.mainBox}>
71
- <h3 className={styles.mainTitle}>
73
+ <span className={styles.mainTitle}>
72
74
  {translate(translations, 'menage_consent_preference', 'Manage Consent Preferences')}
73
- </h3>
75
+ </span>
74
76
 
75
77
  {CategoryObj.map((elm, index) => {
76
78
  const state = index === 1 ? anlyticsButton : marketing;
@@ -48,7 +48,7 @@ export default function Row({
48
48
  const prettyLink = prettyTracker(item, trackerType);
49
49
  const hasRibbon = getExtraField(item.extra_fields, 'ribbon_text');
50
50
  const imageObject = item?.standardised_logo_url_object || item?.logo_url_object;
51
-
51
+ const ribbons = hasRibbon?.split(',');
52
52
  const launchDate = getLaunchDate(item.founded);
53
53
 
54
54
  return (
@@ -64,16 +64,18 @@ export default function Row({
64
64
  )}
65
65
  {hasRibbon && (
66
66
  <div className={styles.ribbon}>
67
- <Link to={reviewPath} className="toplist-variant-one-gtm">
68
- <Label
69
- title={getExtraField(item.extra_fields, 'ribbon_text')}
70
- bgColor={
71
- getExtraField(item.extra_fields, 'ribbon_color')
72
- ? getExtraField(item.extra_fields, 'ribbon_color')
73
- : '#0000'
74
- }
75
- />
76
- </Link>
67
+ {ribbons.map((r) => (
68
+ <Link to={reviewPath} className="toplist-variant-one-gtm">
69
+ <Label
70
+ title={r}
71
+ bgColor={
72
+ getExtraField(item.extra_fields, 'ribbon_color')
73
+ ? getExtraField(item.extra_fields, 'ribbon_color')
74
+ : '#0000'
75
+ }
76
+ />
77
+ </Link>
78
+ ))}
77
79
  </div>
78
80
  )}
79
81
 
@@ -87,10 +89,7 @@ export default function Row({
87
89
  >
88
90
  <LazyImage
89
91
  alt={getAltText(imageObject, item.name)}
90
- src={imagePrettyUrl(imageObject?.filename || item?.logo_url, 80, 80).replace(
91
- 'filters:format(webp)/',
92
- ''
93
- )}
92
+ src={imagePrettyUrl(imageObject?.filename || item?.logo_url, 80, 80)}
94
93
  width={80}
95
94
  height={800}
96
95
  />
@@ -45,6 +45,10 @@
45
45
  left: 4rem;
46
46
  top: 0.2rem;
47
47
 
48
+ a {
49
+ margin-right: 1rem;
50
+ }
51
+
48
52
  span {
49
53
  padding: 0.8rem 1rem;
50
54
  font-size: 1rem;
@@ -148,7 +152,6 @@
148
152
  }
149
153
  }
150
154
 
151
-
152
155
  &.withRibbon {
153
156
  @include min(tablet) {
154
157
  padding-top: 2rem !important;
@@ -1,7 +1,7 @@
1
+ /* eslint-disable import/no-extraneous-dependencies */
1
2
  /* eslint-disable react/prop-types */
2
3
  import React from 'react';
3
4
  import PropTypes from 'prop-types';
4
- // eslint-disable-next-line import/no-extraneous-dependencies
5
5
  import loadable from '@loadable/component';
6
6
  import { anchorLink } from 'gatsby-core-theme/src/helpers/strings';
7
7
  import { prettyTracker, getSectionExtraField } from 'gatsby-core-theme/src/helpers/getters';
@@ -111,6 +111,11 @@ const Modules = ({ module, page, pageContext }) => {
111
111
  '--module-background-color': module.background_color,
112
112
  };
113
113
 
114
+ const ModuleIntro =
115
+ module.name !== 'top_list' &&
116
+ module.module_introduction &&
117
+ loadable(() => import('~molecules/content-intro'));
118
+
114
119
  return (
115
120
  ModuleComponent && (
116
121
  <div
@@ -121,13 +126,7 @@ const Modules = ({ module, page, pageContext }) => {
121
126
  } ${styles.module} ${module?.style && styles[module.style]} module`}
122
127
  >
123
128
  {module.name !== 'top_list' && <ModuleTitle module={module} />}
124
- {module.name !== 'top_list' && module.module_introduction && (
125
- // eslint-disable-next-line react/no-danger
126
- <div
127
- className={styles.module_introduction}
128
- dangerouslySetInnerHTML={{ __html: module?.module_introduction }}
129
- />
130
- )}
129
+ {ModuleIntro && <ModuleIntro content={module.module_introduction} />}
131
130
  <ModuleComponent module={module} page={page} pageContext={pageContext} {...extraProps} />
132
131
  </div>
133
132
  )
@@ -102,6 +102,10 @@ const Tabs = ({
102
102
  setActiveTab(tabId);
103
103
  setTimeout(forceCheck);
104
104
  }
105
+
106
+ const ModuleIntro =
107
+ module.module_introduction && loadable(() => import('~molecules/content-intro'));
108
+
105
109
  return (
106
110
  <>
107
111
  <div className={tabHeaderClass}>
@@ -124,10 +128,7 @@ const Tabs = ({
124
128
  <></>
125
129
  )}
126
130
  </div>
127
- {module.module_introduction && (
128
- // eslint-disable-next-line react/no-danger
129
- <div dangerouslySetInnerHTML={{ __html: module?.module_introduction }} />
130
- )}
131
+ {ModuleIntro && <ModuleIntro content={module.module_introduction} />}
131
132
  {HeaderComp && <div className={styles.headerComp}>{HeaderComp}</div>}
132
133
  </div>
133
134