gatsby-matrix-theme 42.0.5 → 43.0.0

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.
Files changed (47) hide show
  1. package/CHANGELOG.md +29 -0
  2. package/package.json +2 -2
  3. package/src/components/atoms/cards/comparison-table/table/index.js +8 -1
  4. package/src/components/atoms/cards/game-cards/template-five/index.js +3 -0
  5. package/src/components/atoms/cards/game-cards/template-five/template-five.stories.js +0 -1
  6. package/src/components/atoms/cards/game-cards/template-four/index.js +3 -0
  7. package/src/components/atoms/cards/game-cards/template-four/template-four.stories.js +0 -1
  8. package/src/components/atoms/cards/game-cards/template-one/index.js +3 -0
  9. package/src/components/atoms/cards/game-cards/template-one/template-one.stories.js +0 -1
  10. package/src/components/atoms/cards/game-cards/template-three/index.js +3 -0
  11. package/src/components/atoms/cards/game-cards/template-three/template-three.stories.js +0 -1
  12. package/src/components/atoms/cards/game-cards/template-two/index.js +3 -0
  13. package/src/components/atoms/cards/game-cards/template-two/template-two.stories.js +0 -1
  14. package/src/components/atoms/cards/payment-method/template-one/index.js +3 -0
  15. package/src/components/atoms/cards/payment-method/template-one/template-one.test.js +1 -1
  16. package/src/components/atoms/cards/payment-method/template-three/index.js +9 -1
  17. package/src/components/atoms/cards/payment-method/template-three/template-three.test.js +1 -1
  18. package/src/components/atoms/cards/popup-card/index.js +5 -1
  19. package/src/components/atoms/table/column/index.js +8 -1
  20. package/src/components/molecules/header/variants/operator/template-five/index.js +4 -1
  21. package/src/components/molecules/header/variants/operator/template-four/index.js +3 -0
  22. package/src/components/molecules/header/variants/operator/template-one-two/index.js +3 -0
  23. package/src/components/molecules/header/variants/payment/template-five/index.js +8 -1
  24. package/src/components/molecules/header/variants/payment/template-four/index.js +8 -1
  25. package/src/components/molecules/header/variants/payment/template-one-three/index.js +3 -0
  26. package/src/components/molecules/header/variants/payment/template-two/index.js +3 -0
  27. package/src/components/molecules/header/variants/slot/template-one/index.js +2 -1
  28. package/src/components/molecules/header/variants/slot/template-one/template-one.stories.js +3 -3
  29. package/src/components/molecules/header/variants/slot/template-two/template-two.stories.js +3 -3
  30. package/src/components/molecules/multiple-contributors/contributor/contributor.stories.js +1 -1
  31. package/src/components/molecules/multiple-contributors/multiple-contributors.module.scss +2 -7
  32. package/src/components/molecules/multiple-contributors/multiple-contributors.stories.js +1 -1
  33. package/src/components/molecules/operator-details/index.js +3 -0
  34. package/src/gatsby-core-theme/components/molecules/main/index.js +0 -14
  35. package/src/gatsby-core-theme/components/molecules/module/index.js +21 -0
  36. package/storybook/public/{341.39505fb8.iframe.bundle.js → 341.1a7a7797.iframe.bundle.js} +3 -3
  37. package/storybook/public/{341.39505fb8.iframe.bundle.js.map → 341.1a7a7797.iframe.bundle.js.map} +1 -1
  38. package/storybook/public/iframe.html +1 -1
  39. package/storybook/public/main.5158b9ed.iframe.bundle.js +1 -0
  40. package/storybook/public/project.json +1 -1
  41. package/tests/factories/cards/payment.factory.js +1 -1
  42. package/tests/factories/modules/matrix/card.factory.js +6 -6
  43. package/tests/factories/modules/toplist.factory.js +42 -42
  44. package/tests/factories/pages/operator.factory.js +12 -12
  45. package/tests/factories/pages/payment.factory.js +1 -1
  46. package/storybook/public/main.df129302.iframe.bundle.js +0 -1
  47. /package/storybook/public/{341.39505fb8.iframe.bundle.js.LICENSE.txt → 341.1a7a7797.iframe.bundle.js.LICENSE.txt} +0 -0
package/CHANGELOG.md CHANGED
@@ -1,3 +1,32 @@
1
+ # [43.0.0](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/compare/v42.0.6...v43.0.0) (2024-05-29)
2
+
3
+
4
+ ### Code Refactoring
5
+
6
+ * changes to ratings, storybook and testing ([7c19c8c](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/7c19c8c907bd8132deebaeba52ddf27e0f7cfd73))
7
+ * fix storybook path ([0fed1be](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/0fed1bee81f418408f16bb583f665a500baba8ad))
8
+ * make multiple contributors a template block ([d4e04b5](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/d4e04b5a3d43a4998f8ec8d219d1018f0aeb5bed))
9
+
10
+
11
+ ### Config
12
+
13
+ * update theme ([7f19526](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/7f195262be5ec3f7e3e9139bf97b24f862fd6d00))
14
+
15
+
16
+ * Merge branch 'tm-4382-ratings' into 'master' ([b5670a4](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/b5670a49abadf4b3ff2892e5c0836afabc9c898c))
17
+ * Merge branch 'tm-4417-multiple-contributors' into 'master' ([49d2141](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/49d2141fd494697f3ab52ee44794ff39a26941dd))
18
+ * Merge branch 'master' into tm-4417-multiple-contributors ([6c2befd](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/6c2befd07ff8576587c918b3e3d78ffecc00679f))
19
+ * Merge branch 'master' into tm-4382-ratings ([57a2d40](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/57a2d4065295d8e52b7bc0063817c3fda7274abf))
20
+ * Merge branch 'master' into tm-4382-ratings ([d3ecc94](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/d3ecc9402d4e4ac11266c2d431ae2a8fa9423a93))
21
+
22
+ ## [42.0.6](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/compare/v42.0.5...v42.0.6) (2024-05-28)
23
+
24
+
25
+ ### Bug Fixes
26
+
27
+ * update average rating ([eba80fc](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/eba80fc15f1fde0a66891a421dd8548609af4385))
28
+ * update average rating ([f92b846](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/commit/f92b846faf9a6a2b923677bd0c7b3b69cc4f1f6e))
29
+
1
30
  ## [42.0.5](https://git.ilcd.rocks/team-floyd/themes/matrix-theme/compare/v42.0.4...v42.0.5) (2024-05-24)
2
31
 
3
32
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gatsby-matrix-theme",
3
- "version": "42.0.5",
3
+ "version": "43.0.0",
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": "31.0.2",
28
+ "gatsby-core-theme": "32.0.0",
29
29
  "gatsby-plugin-sharp": "^5.11.0",
30
30
  "gatsby-transformer-sharp": "^5.11.0",
31
31
  "prop-types": "15.7.2",
@@ -1,3 +1,4 @@
1
+ /* eslint-disable jsx-a11y/control-has-associated-label */
1
2
  /* eslint-disable react/forbid-prop-types */
2
3
  /* eslint-disable import/no-extraneous-dependencies */
3
4
  /* eslint-disable jsx-a11y/click-events-have-key-events */
@@ -66,6 +67,7 @@ export default function ComparisonTable({
66
67
  ctaKey = 'play_now',
67
68
  type,
68
69
  tempate,
70
+ showRoundedRating = false,
69
71
  }) {
70
72
  const { translations } = useContext(Context) || {};
71
73
 
@@ -129,7 +131,11 @@ export default function ComparisonTable({
129
131
  case 'rating':
130
132
  return (
131
133
  <td key={key} className={styles.raiting}>
132
- <StarRating numOfStars={5} rating={item?.relation?.rating} />
134
+ <StarRating
135
+ numOfStars={5}
136
+ rating={item?.relation?.rating}
137
+ showRoundedRating={showRoundedRating}
138
+ />
133
139
 
134
140
  {type === 'operator' && index === 0 ? null : (
135
141
  <ReviewLink
@@ -268,4 +274,5 @@ export default function ComparisonTable({
268
274
 
269
275
  ComparisonTable.propTypes = {
270
276
  items: PropTypes.arrayOf(PropTypes.object),
277
+ showRoundedRating: PropTypes.bool,
271
278
  };
@@ -28,6 +28,7 @@ const TemplateFive = ({
28
28
  useThumbnail = true,
29
29
  storybookImage,
30
30
  storybookLogo,
31
+ showRoundedRating = false,
31
32
  }) => {
32
33
  const { relation, path, banner } = item;
33
34
  const { name } = relation || {};
@@ -76,6 +77,7 @@ const TemplateFive = ({
76
77
  relation.fourth_rating,
77
78
  ]
78
79
  }
80
+ showRoundedRating={showRoundedRating}
79
81
  />
80
82
  )}
81
83
  </div>
@@ -182,6 +184,7 @@ TemplateFive.propTypes = {
182
184
  affilateLink: PropTypes.bool,
183
185
  storybookImage: PropTypes.string,
184
186
  storybookLogo: PropTypes.string,
187
+ showRoundedRating: PropTypes.bool,
185
188
  };
186
189
 
187
190
  export default TemplateFive;
@@ -46,7 +46,6 @@ Default.args = {
46
46
  },
47
47
  relation: {
48
48
  ...card.relation,
49
- rating: '4.5',
50
49
  game_provider: {
51
50
  name: 'Wildz',
52
51
  path: 'wildz-casino',
@@ -27,6 +27,7 @@ const TemplateFour = ({
27
27
  affilateLink = false,
28
28
  useThumbnail = true,
29
29
  storybookImage,
30
+ showRoundedRating = false,
30
31
  }) => {
31
32
  const { relation, path, banner } = item;
32
33
  const { name } = relation || {};
@@ -67,6 +68,7 @@ const TemplateFour = ({
67
68
  relation.fourth_rating,
68
69
  ]
69
70
  }
71
+ showRoundedRating={showRoundedRating}
70
72
  />
71
73
  )}
72
74
  <div className={`${styles?.cardContent || ''} ${featured ? styles.featured : ''}`}>
@@ -161,6 +163,7 @@ TemplateFour.propTypes = {
161
163
  useThumbnail: PropTypes.bool,
162
164
  affilateLink: PropTypes.bool,
163
165
  storybookImage: PropTypes.string,
166
+ showRoundedRating: PropTypes.bool,
164
167
  };
165
168
 
166
169
  export default TemplateFour;
@@ -34,7 +34,6 @@ Default.args = {
34
34
  title: 'Wolf Gold',
35
35
  relation: {
36
36
  ...card.relation,
37
- rating: '4.5',
38
37
  game_provider: {
39
38
  name: 'NetEnt',
40
39
  path: 'netent-casinos',
@@ -25,6 +25,7 @@ const TemplateOne = ({
25
25
  affilateLink = false,
26
26
  useThumbnail = true,
27
27
  storybookImage,
28
+ showRoundedRating = false,
28
29
  }) => {
29
30
  const { relation, path, banner } = item;
30
31
  const { name } = relation || {};
@@ -82,6 +83,7 @@ const TemplateOne = ({
82
83
  relation.fourth_rating,
83
84
  ]
84
85
  }
86
+ showRoundedRating={showRoundedRating}
85
87
  />
86
88
  )}
87
89
  </div>
@@ -163,6 +165,7 @@ TemplateOne.propTypes = {
163
165
  useThumbnail: PropTypes.bool,
164
166
  affilateLink: PropTypes.bool,
165
167
  storybookImage: PropTypes.string,
168
+ showRoundedRating: PropTypes.bool,
166
169
  };
167
170
 
168
171
  export default TemplateOne;
@@ -34,7 +34,6 @@ Default.args = {
34
34
  title: 'Rick Wilde and the Book of dead',
35
35
  relation: {
36
36
  ...card.relation,
37
- rating: '4.5',
38
37
  game_provider: {
39
38
  name: 'NetEnt',
40
39
  path: 'netent-casinos',
@@ -27,6 +27,7 @@ const TemplateThree = ({
27
27
  affilateLink = false,
28
28
  useThumbnail = true,
29
29
  storybookImage,
30
+ showRoundedRating = false,
30
31
  }) => {
31
32
  const { relation, path, banner } = item;
32
33
  const { name } = relation || {};
@@ -72,6 +73,7 @@ const TemplateThree = ({
72
73
  relation.fourth_rating,
73
74
  ]
74
75
  }
76
+ showRoundedRating={showRoundedRating}
75
77
  />
76
78
  )}
77
79
  </div>
@@ -167,6 +169,7 @@ TemplateThree.propTypes = {
167
169
  useThumbnail: PropTypes.bool,
168
170
  affilateLink: PropTypes.bool,
169
171
  storybookImage: PropTypes.string,
172
+ showRoundedRating: PropTypes.bool,
170
173
  };
171
174
 
172
175
  export default TemplateThree;
@@ -34,7 +34,6 @@ Default.args = {
34
34
  title: 'Rick Wilde and the Book of dead',
35
35
  relation: {
36
36
  ...card.relation,
37
- rating: '4.5',
38
37
  game_provider: {
39
38
  name: 'NetEnt',
40
39
  path: 'netent-casinos',
@@ -27,6 +27,7 @@ const TemplateTwo = ({
27
27
  affilateLink = false,
28
28
  useThumbnail = true,
29
29
  storybookImage,
30
+ showRoundedRating = false,
30
31
  }) => {
31
32
  const { relation, path, banner } = item;
32
33
  const { name } = relation || {};
@@ -76,6 +77,7 @@ const TemplateTwo = ({
76
77
  relation.fourth_rating,
77
78
  ]
78
79
  }
80
+ showRoundedRating={showRoundedRating}
79
81
  />
80
82
  )}
81
83
  </div>
@@ -169,6 +171,7 @@ TemplateTwo.propTypes = {
169
171
  useThumbnail: PropTypes.bool,
170
172
  affilateLink: PropTypes.bool,
171
173
  storybookImage: PropTypes.string,
174
+ showRoundedRating: PropTypes.bool,
172
175
  };
173
176
 
174
177
  export default TemplateTwo;
@@ -34,7 +34,6 @@ Default.args = {
34
34
  title: 'Rick Wilde and the Book of dead',
35
35
  relation: {
36
36
  ...card.relation,
37
- rating: '4.5',
38
37
  game_provider: {
39
38
  name: 'NetEnt',
40
39
  path: 'netent-casinos',
@@ -23,6 +23,7 @@ const TemplateOneTwo = ({
23
23
  width = 150,
24
24
  height = 150,
25
25
  wordLimit = 50,
26
+ showRoundedRating = false,
26
27
  }) => {
27
28
  const { translations } = useContext(Context);
28
29
  const { title, path, relation, sections, description } = item || {};
@@ -55,6 +56,7 @@ const TemplateOneTwo = ({
55
56
  halfStars={false}
56
57
  rating={relation?.rating}
57
58
  showDot={false}
59
+ showRoundedRating={showRoundedRating}
58
60
  />
59
61
  </div>
60
62
  </div>
@@ -117,6 +119,7 @@ TemplateOneTwo.propTypes = {
117
119
  width: PropTypes.number,
118
120
  height: PropTypes.number,
119
121
  wordLimit: PropTypes.number,
122
+ showRoundedRating: PropTypes.bool,
120
123
  };
121
124
 
122
125
  export default TemplateOneTwo;
@@ -18,7 +18,7 @@ describe('TemplateOneTwo component', () => {
18
18
  expect(paymentData.relation.games_count).toBe(10);
19
19
  expect(paymentData.relation.logo_filename_object.alt).toBe('Payment Method Item Logo');
20
20
  expect(paymentData.relation.logo_filename_object.filename).toBe('1652872814/revolut.svg');
21
- expect(paymentData.relation.rating).toBe('4.5');
21
+ expect(paymentData.relation.rating).toBe('4.75');
22
22
  });
23
23
  it('renders the payment method name', () => {
24
24
  const paymentData = getPaymentData();
@@ -12,7 +12,13 @@ import { FaArrowRight } from '@react-icons/all-files/fa/FaArrowRight';
12
12
  import SellingPoints from '../sellingPoints';
13
13
  import styles from './template-three.module.scss';
14
14
 
15
- const TemplateThree = ({ item, width = 150, height = 150, useOneStarRating = false }) => {
15
+ const TemplateThree = ({
16
+ item,
17
+ width = 150,
18
+ height = 150,
19
+ useOneStarRating = false,
20
+ showRoundedRating = false,
21
+ }) => {
16
22
  const { title, path, relation } = item || {};
17
23
  const { name, selling_points } = item?.relation || {};
18
24
 
@@ -44,6 +50,7 @@ const TemplateThree = ({ item, width = 150, height = 150, useOneStarRating = fal
44
50
  halfStars={false}
45
51
  rating={relation?.rating}
46
52
  showDot={false}
53
+ showRoundedRating={showRoundedRating}
47
54
  />
48
55
  </div>
49
56
  </div>
@@ -94,6 +101,7 @@ TemplateThree.propTypes = {
94
101
  }).isRequired,
95
102
  width: PropTypes.number,
96
103
  height: PropTypes.number,
104
+ showRoundedRating: PropTypes.bool,
97
105
  };
98
106
 
99
107
  export default TemplateThree;
@@ -16,7 +16,7 @@ describe('TemplateThree', () => {
16
16
  expect(paymentData.relation.games_count).toBe(10);
17
17
  expect(paymentData.relation.logo_filename_object.alt).toBe('Payment Method Item Logo');
18
18
  expect(paymentData.relation.logo_filename_object.filename).toBe('1652872814/revolut.svg');
19
- expect(paymentData.relation.rating).toBe('4.5');
19
+ expect(paymentData.relation.rating).toBe('4.75');
20
20
  });
21
21
  it('renders payment method name', () => {
22
22
  const paymentData = getPaymentData();
@@ -21,6 +21,7 @@ const PopupCard = ({
21
21
  buttonSize = '',
22
22
  buttonType = 'primary',
23
23
  template,
24
+ showRoundedRating = false,
24
25
  }) => {
25
26
  const operatorName = item.name;
26
27
  const oneLiner = item?.one_liners?.main?.one_liner;
@@ -36,7 +37,9 @@ const PopupCard = ({
36
37
  width={98}
37
38
  height={98}
38
39
  />
39
- {showRating && <StarRating numOfStars={5} rating={item?.rating} />}
40
+ {showRating && (
41
+ <StarRating numOfStars={5} rating={item?.rating} showRoundedRating={showRoundedRating} />
42
+ )}
40
43
  {showName && <p className={styles?.name || ''}>{operatorName}</p>}
41
44
  </div>
42
45
  <Bonus module="popup" item={item} tracker={tracker} />
@@ -114,6 +117,7 @@ PopupCard.propTypes = {
114
117
  hasCollapse: PropTypes.bool,
115
118
  buttonSize: PropTypes.string,
116
119
  buttonType: PropTypes.string,
120
+ showRoundedRating: PropTypes.bool,
117
121
  };
118
122
 
119
123
  export default PopupCard;
@@ -1,3 +1,4 @@
1
+ /* eslint-disable jsx-a11y/control-has-associated-label */
1
2
  /* eslint-disable react/forbid-prop-types */
2
3
  /* eslint-disable camelcase */
3
4
  import React from 'react';
@@ -28,6 +29,7 @@ const Index = ({
28
29
  chnageHeights,
29
30
  licensesMore,
30
31
  layout = 'list',
32
+ showRoundedRating = false,
31
33
  }) => {
32
34
  const { min_deposit } = item.bonus;
33
35
  const { max_withdrawal } = item.bonus;
@@ -75,7 +77,11 @@ const Index = ({
75
77
  <tr style={{ height: rating }} id="rating">
76
78
  <td>
77
79
  <div className={styles?.rating || ''}>
78
- <StarRating numOfStars={5} rating={item.rating} />
80
+ <StarRating
81
+ numOfStars={5}
82
+ rating={item.rating}
83
+ showRoundedRating={showRoundedRating}
84
+ />
79
85
  </div>
80
86
  </td>
81
87
  </tr>
@@ -162,5 +168,6 @@ Index.propTypes = {
162
168
  chnageHeights: PropTypes.func,
163
169
  licensesMore: PropTypes.bool,
164
170
  layout: PropTypes.string,
171
+ showRoundedRating: PropTypes.bool,
165
172
  };
166
173
  export default Index;
@@ -27,6 +27,7 @@ const TemplateFive = ({
27
27
  type,
28
28
  numOfStars = 5,
29
29
  icon,
30
+ showRoundedRating = false,
30
31
  }) => {
31
32
  const { translations } = useContext(Context) || {};
32
33
 
@@ -86,6 +87,7 @@ const TemplateFive = ({
86
87
  {extraFields?.summary && (
87
88
  <div
88
89
  className={styles.decs}
90
+ // eslint-disable-next-line react/no-danger
89
91
  dangerouslySetInnerHTML={{ __html: extraFields?.summary }}
90
92
  />
91
93
  )}
@@ -107,7 +109,7 @@ const TemplateFive = ({
107
109
  '-'
108
110
  )}
109
111
  </span>
110
- <StarRating numOfStars={5} rating={value} />
112
+ <StarRating numOfStars={5} rating={value} showRoundedRating={showRoundedRating} />
111
113
  </div>
112
114
  );
113
115
  })}
@@ -159,6 +161,7 @@ TemplateFive.propTypes = {
159
161
  summary: PropTypes.node,
160
162
  }),
161
163
  icon: PropTypes.node,
164
+ showRoundedRating: PropTypes.bool,
162
165
  };
163
166
 
164
167
  export default TemplateFive;
@@ -22,6 +22,7 @@ const TemplateFour = ({
22
22
  icon,
23
23
  numOfStars = 5,
24
24
  hasVariableComponent = false,
25
+ showRoundedRating = false,
25
26
  }) => {
26
27
  const { translations } = useContext(Context) || {};
27
28
  const ribbon = ribbons?.length > 0 ? ribbons[0] : null;
@@ -58,6 +59,7 @@ const TemplateFour = ({
58
59
  rating={numOfStars < 6 ? relation?.rating : Math.round(relation?.rating * 2)}
59
60
  icon={<FaStar title="Star Icon" />}
60
61
  showDot={false}
62
+ showRoundedRating={showRoundedRating}
61
63
  />
62
64
  ) : (
63
65
  <div className={styles.ratingInactive}>
@@ -113,6 +115,7 @@ TemplateFour.propTypes = {
113
115
  hasVariableComponent: PropTypes.bool,
114
116
  numOfStars: PropTypes.number,
115
117
  icon: PropTypes.node,
118
+ showRoundedRating: PropTypes.bool,
116
119
  };
117
120
 
118
121
  export default TemplateFour;
@@ -23,6 +23,7 @@ const TemplateOneTwo = ({
23
23
  icon,
24
24
  hasVariableComponent = false,
25
25
  template = 'template_one',
26
+ showRoundedRating = false,
26
27
  }) => {
27
28
  const { translations } = useContext(Context) || {};
28
29
 
@@ -89,6 +90,7 @@ const TemplateOneTwo = ({
89
90
  rating={numOfStars < 6 ? relation?.rating : Math.round(relation?.rating * 2)}
90
91
  icon={<FaStar title="Star Icon" />}
91
92
  showDot={false}
93
+ showRoundedRating={showRoundedRating}
92
94
  />
93
95
  ) : (
94
96
  <div className={styles.ratingInactive}>
@@ -132,6 +134,7 @@ TemplateOneTwo.propTypes = {
132
134
  numOfStars: PropTypes.number,
133
135
  template: PropTypes.string,
134
136
  icon: PropTypes.node,
137
+ showRoundedRating: PropTypes.bool,
135
138
  };
136
139
 
137
140
  export default TemplateOneTwo;
@@ -26,6 +26,7 @@ const TemplateOneThree = ({
26
26
  description,
27
27
  numOfStars,
28
28
  CostumeComponent = null,
29
+ showRoundedRating = false,
29
30
  }) => {
30
31
  const [isReadMore, setIsReadMore] = useState(true);
31
32
  const { translations } = useContext(Context) || {};
@@ -61,7 +62,12 @@ const TemplateOneThree = ({
61
62
 
62
63
  {CostumeComponent && <div className={styles.costumeComponent}>{CostumeComponent}</div>}
63
64
 
64
- <Rating item={relation} type={type} numOfStars={numOfStars} />
65
+ <Rating
66
+ item={relation}
67
+ type={type}
68
+ numOfStars={numOfStars}
69
+ showRoundedRating={showRoundedRating}
70
+ />
65
71
  </div>
66
72
  </div>
67
73
  {description && (
@@ -119,6 +125,7 @@ TemplateOneThree.propTypes = {
119
125
  description: PropTypes.string,
120
126
  icon: PropTypes.node,
121
127
  CostumeComponent: PropTypes.node,
128
+ showRoundedRating: PropTypes.bool,
122
129
  };
123
130
 
124
131
  export default TemplateOneThree;
@@ -15,6 +15,7 @@ const TemplateFour = ({
15
15
  pageTemplate,
16
16
  icon,
17
17
  numOfStars = 5,
18
+ showRoundedRating = false,
18
19
  }) => {
19
20
  const headerBonus = sections?.header?.modules?.find((bonus) => bonus?.name === 'bonus');
20
21
 
@@ -41,7 +42,12 @@ const TemplateFour = ({
41
42
  />
42
43
  </div>
43
44
  <div className={styles.ratings}>
44
- <Rating item={relation} type={type} numOfStars={numOfStars} />
45
+ <Rating
46
+ item={relation}
47
+ type={type}
48
+ numOfStars={numOfStars}
49
+ showRoundedRating={showRoundedRating}
50
+ />
45
51
  </div>
46
52
  {headerBonus && (
47
53
  <OperatorBanner
@@ -75,6 +81,7 @@ TemplateFour.propTypes = {
75
81
  pageTemplate: PropTypes.string,
76
82
  numOfStars: PropTypes.number,
77
83
  icon: PropTypes.node,
84
+ showRoundedRating: PropTypes.bool,
78
85
  };
79
86
 
80
87
  export default TemplateFour;
@@ -28,6 +28,7 @@ const TemplateOneThree = ({
28
28
  numOfStars,
29
29
  template = 'template_one',
30
30
  CostumeComponent = null,
31
+ showRoundedRating = false,
31
32
  }) => {
32
33
  const [isReadMore, setIsReadMore] = useState(true);
33
34
  const { translations } = useContext(Context) || {};
@@ -82,6 +83,7 @@ const TemplateOneThree = ({
82
83
  numOfStars={numOfStars}
83
84
  rating={relation?.rating}
84
85
  icon={<FaStar title="Star Icon" />}
86
+ showRoundedRating={showRoundedRating}
85
87
  />
86
88
  ) : (
87
89
  <div className={styles.ratingInactive}>
@@ -154,6 +156,7 @@ TemplateOneThree.propTypes = {
154
156
  description: PropTypes.string,
155
157
  icon: PropTypes.node,
156
158
  CostumeComponent: PropTypes.node,
159
+ showRoundedRating: PropTypes.bool,
157
160
  };
158
161
 
159
162
  export default TemplateOneThree;
@@ -24,6 +24,7 @@ const TemplateTwo = ({
24
24
  icon,
25
25
  description,
26
26
  numOfStars,
27
+ showRoundedRating = false,
27
28
  }) => {
28
29
  const [isReadMore, setIsReadMore] = useState(true);
29
30
  const descriptionRef = useRef(null);
@@ -62,6 +63,7 @@ const TemplateTwo = ({
62
63
  numOfStars={numOfStars}
63
64
  rating={relation?.rating}
64
65
  icon={<FaStar title="Star Icon" />}
66
+ showRoundedRating={showRoundedRating}
65
67
  />
66
68
  ) : (
67
69
  <div className={styles.ratingInactive}>
@@ -124,5 +126,6 @@ TemplateTwo.propTypes = {
124
126
  numOfStars: PropTypes.number,
125
127
  description: PropTypes.string,
126
128
  icon: PropTypes.node,
129
+ showRoundedRating: PropTypes.bool,
127
130
  };
128
131
  export default TemplateTwo;
@@ -40,7 +40,8 @@ export default function SlotHeader({ page, image, showExtraRatings = false }) {
40
40
  </div>
41
41
  <div className={styles.averageRating}>
42
42
  <FaStar title="Star Icon" s />
43
- <p>{averageRating}/5</p>
43
+ <p>{averageRating}/</p>
44
+ <p>5</p>
44
45
  </div>
45
46
  </div>
46
47
  </div>
@@ -37,10 +37,10 @@ Default.args = {
37
37
  page: {
38
38
  title: 'Game slot',
39
39
  relation: {
40
- third_rating: 3,
41
- first_rating: 4,
40
+ third_rating: 3.6,
41
+ first_rating: 4.2,
42
42
  rtp: 30,
43
- average_rating: 4.5,
43
+ average_rating: 4.4,
44
44
  thumbnail_filename_object: {
45
45
  filename: 'holiday-season-game-thumbnail.jpeg',
46
46
  },
@@ -37,10 +37,10 @@ Default.args = {
37
37
  page: {
38
38
  title: 'Game slot',
39
39
  relation: {
40
- third_rating: 3,
41
- first_rating: 4,
40
+ third_rating: 3.7,
41
+ first_rating: 4.3,
42
42
  rtp: 30,
43
- average_rating: 4.5,
43
+ average_rating: 4.9,
44
44
  thumbnail_filename_object: {
45
45
  filename: 'holiday-season-game-thumbnail.jpeg',
46
46
  },
@@ -15,7 +15,7 @@ import Contributor from '.';
15
15
  const authorData = getAuthorList({})[1];
16
16
 
17
17
  export default {
18
- title: 'Theme/Layout/Author/Multiple Contributors/Single Contributor',
18
+ title: 'Theme/Modules/Template Blocks/Multiple Contributors/Single Contributor',
19
19
  component: Contributor,
20
20
  argTypes: {
21
21
  contributor: {
@@ -8,15 +8,10 @@
8
8
  .container {
9
9
  max-width: var(--main-container-max);
10
10
  margin: 0 auto;
11
- padding: 1.6rem 0;
12
- width: calc(100% - 3.2rem);
11
+ padding: var(--multiple-contributors-container-padding, 1.6rem 0);
13
12
  @include flex-direction(column);
14
13
  gap: 2.4rem;
15
-
16
- @include min(tablet) {
17
- padding: 1.6rem 2.4rem;
18
- width: 100%;
19
- }
14
+ width: 100%;
20
15
  }
21
16
 
22
17
  .heading {
@@ -15,7 +15,7 @@ const authorData = getAuthorList({})[1];
15
15
  const reviewerData = getAuthorList({})[1];
16
16
 
17
17
  export default {
18
- title: 'Theme/Layout/Author/Multiple Contributors',
18
+ title: 'Theme/Modules/Template Blocks/Multiple Contributors',
19
19
  component: Author,
20
20
  argTypes: {
21
21
  authors: {