gatsby-core-theme 30.0.58 → 30.0.60

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,18 @@
1
+ ## [30.0.60](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/compare/v30.0.59...v30.0.60) (2024-01-24)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * grouping zindex ([209c807](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/209c80731f187f1ebc761cca5faf2b4c28d39dd6))
7
+
8
+ ## [30.0.59](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/compare/v30.0.58...v30.0.59) (2024-01-24)
9
+
10
+
11
+ ### Bug Fixes
12
+
13
+ * casinomobile cards ([99b5662](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/99b5662635ff607f841eb2baa83521b46f56b5f6))
14
+ * prefilled modules ([e7405b1](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/e7405b1aab3e5a1cde92d1ec77283c8dc13a6780))
15
+
1
16
  ## [30.0.58](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/compare/v30.0.57...v30.0.58) (2024-01-23)
2
17
 
3
18
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gatsby-core-theme",
3
- "version": "30.0.58",
3
+ "version": "30.0.60",
4
4
  "description": "Gatsby Theme NPM Package",
5
5
  "author": "",
6
6
  "license": "ISC",
@@ -4,6 +4,7 @@
4
4
  position: fixed;
5
5
  transition: all 1s;
6
6
  bottom: -30rem;
7
+ z-index: map-get($z-index, scroll-to-top);
7
8
  }
8
9
 
9
10
  .show {
@@ -22,7 +22,7 @@ export default {
22
22
  'partnerships.gigmedia.com': ['inactive', 'blacklisted'],
23
23
  'habibibet.org': ['inactive', 'blacklisted'],
24
24
  'xn--nt-casino-v2a.se': ['inactive', 'blacklisted'],
25
- 'casinomobile.co.za': [],
25
+ 'casinomobile.co.za': ['inactive', 'blacklisted'],
26
26
  'betamericalatina.com': ['inactive', 'blacklisted'],
27
27
  },
28
28
  keep_page_extra_fields: {
@@ -115,9 +115,16 @@ export function processSections(sections, skipPost = false, page, translations,
115
115
  }
116
116
  if (sections[sectionKey] && sections[sectionKey].modules) {
117
117
  sections[sectionKey].modules.forEach((module, key) => {
118
- if (shouldSavePrefilled(module, siteName) && savedModules[module.module_value_id]) {
119
- Object.assign(module, savedModules[module.module_value_id]);
118
+ if (shouldSavePrefilled(module, siteName) && savedModules[module.value_id]) {
119
+ Object.assign(module, savedModules[module.value_id]);
120
120
  } else {
121
+ if (module.value_type === ModuleValue.VALUE_TYPE_PREFILLED_MODULE_MARKET) {
122
+ module = {
123
+ ...cloneDeep(prefilledMarketModules[module.value_id]),
124
+ value_type: ModuleValue.VALUE_TYPE_PREFILLED_MODULE_MARKET,
125
+ };
126
+ }
127
+
121
128
  processModule(
122
129
  module,
123
130
  pages,
@@ -132,8 +139,10 @@ export function processSections(sections, skipPost = false, page, translations,
132
139
  markets
133
140
  );
134
141
 
142
+ sections[sectionKey].modules[key] = module;
143
+
135
144
  if (shouldSavePrefilled(module, siteName)) {
136
- savedModules[module.module_value_id] = module;
145
+ savedModules[module.value_id] = module;
137
146
  }
138
147
  }
139
148
  });
@@ -26,11 +26,11 @@ export function processCardsModule(module, pages, pagesCloned, pagesMappedById)
26
26
  module.cards_page_type !== 'operator'
27
27
  ? pagesCloned[modelType]
28
28
  : pagesCloned[modelType].filter(
29
- (page) =>
30
- !settings.filter_cards_modules[process.env.GATSBY_SITE_NAME].includes(
31
- page.relation && page.relation.status
32
- )
33
- );
29
+ (page) =>
30
+ !settings.filter_cards_modules[process.env.GATSBY_SITE_NAME].includes(
31
+ page.relation && page.relation.status
32
+ )
33
+ );
34
34
  module.items = sampleSize(samplePages, numOfItems);
35
35
  } else {
36
36
  module.items = pagesCloned[modelType].slice(0, numOfItems);
@@ -74,13 +74,18 @@ export function filterGames(pages, selectedCategories, selectedProviders) {
74
74
  }
75
75
 
76
76
  pages.forEach((page) => {
77
- page.relation.game_categories.forEach((game) => {
78
- if (selectedCategories && selectedCategories.includes(game.id)) {
77
+ if (selectedCategories) {
78
+ page.relation.game_categories.forEach((game) => {
79
+ if (selectedCategories.includes(game.id)) {
80
+ pagesFiltered.push(page);
81
+ }
82
+ });
83
+ }
84
+
85
+ if (selectedProviders) {
86
+ if (selectedProviders.includes(page.relation.game_provider.id)) {
79
87
  pagesFiltered.push(page);
80
88
  }
81
- });
82
- if (selectedProviders && selectedProviders.includes(page.relation.game_provider.id)) {
83
- pagesFiltered.push(page);
84
89
  }
85
90
  });
86
91
 
@@ -117,16 +122,21 @@ export function filterOperators(pages, selectedProviders, selectedTypes) {
117
122
  }
118
123
 
119
124
  pages.forEach((page) => {
120
- page.relation.software.forEach((software) => {
121
- if (selectedProviders && selectedProviders.includes(software.id)) {
122
- pagesFiltered.push(page);
123
- }
124
- });
125
- page.relation.types.forEach((type) => {
126
- if (selectedTypes && selectedTypes.includes(type)) {
127
- pagesFiltered.push(page);
128
- }
129
- });
125
+ if (selectedProviders) {
126
+ page.relation.software.forEach((software) => {
127
+ if (selectedProviders.includes(software.id)) {
128
+ pagesFiltered.push(page);
129
+ }
130
+ });
131
+ }
132
+
133
+ if (selectedTypes) {
134
+ page.relation.types.forEach((type) => {
135
+ if (selectedTypes.includes(type)) {
136
+ pagesFiltered.push(page);
137
+ }
138
+ });
139
+ }
130
140
  });
131
141
 
132
142
  return filterInactiveOperators(pagesFiltered);
@@ -185,6 +195,7 @@ export function processCardsV2(module, pagesCloned, pagesMappedById, pageId) {
185
195
  const selectedCategories = module.cards_selector_filters.page_categories;
186
196
 
187
197
  const pagesFilteredByAuthor = filterPages(pagesList, selectedAuthors, 'author_id');
198
+
188
199
  // Filter by reviewer
189
200
  const pagesFilteredByReviewer = filterPages(
190
201
  pagesFilteredByAuthor,
@@ -205,7 +216,6 @@ export function processCardsV2(module, pagesCloned, pagesMappedById, pageId) {
205
216
  // Get limit, if not set 50 as default
206
217
  const itemLimit = module.cards_selector_filters_limit || 50;
207
218
  let finalizedFilteredPages = [];
208
-
209
219
  switch (cardType) {
210
220
  case 'game':
211
221
  finalizedFilteredPages = filterGames(
@@ -228,7 +238,7 @@ export function processCardsV2(module, pagesCloned, pagesMappedById, pageId) {
228
238
  finalizedFilteredPages = filteredPages;
229
239
  }
230
240
  const uniquePages = removeCurrentPage(removeDuplicates(finalizedFilteredPages, 'id'), pageId);
231
-
241
+
232
242
  // Applying sorting
233
243
  if (sortType === 'random') {
234
244
  module.items = sampleSize(uniquePages, itemLimit);
@@ -238,6 +248,7 @@ export function processCardsV2(module, pagesCloned, pagesMappedById, pageId) {
238
248
  module.items = uniquePages.slice(0, itemLimit);
239
249
  }
240
250
  }
251
+
241
252
  }
242
253
  }
243
254
 
@@ -249,7 +260,7 @@ export function processCardsV2(module, pagesCloned, pagesMappedById, pageId) {
249
260
  if (pageId !== null) {
250
261
  module.module_title = getModuleTitle(module, pagesMappedById[pageId]);
251
262
  }
252
-
263
+
253
264
  // modify page so it doesn't have too much data
254
265
  module.items = module.items.map((item) => clonePageForCards(cloneDeep(item), module.style));
255
266
  }
@@ -273,19 +284,22 @@ export function processTopListModule(module, relations, pages, markets) {
273
284
  // Remove the ribbons if are empty, will be add ribbons from operator
274
285
  if (item.ribbons && item.ribbons.length === 0) delete item.ribbons;
275
286
  const clone = pick(cloneDeep(relations.operator[item.operator_id]), topListPickKeys);
276
-
277
- // refactor deposit method
278
- clone.bonus.deposit_methods = clone.bonus.deposit_methods?.map(({ id, name, standardised_logo_filename }) => (
279
- { id, name, standardised_logo_filename }
280
- ));
281
287
 
288
+ // refactor deposit method
289
+ clone.bonus.deposit_methods = clone.bonus.deposit_methods?.map(
290
+ ({ id, name, standardised_logo_filename }) => ({ id, name, standardised_logo_filename })
291
+ );
282
292
 
283
293
  const operatorPage =
284
294
  pages && pages.operator
285
295
  ? pages.operator.filter((page) => page.relation_id === item.operator_id)
286
296
  : [];
287
297
  if (operatorPage[0]?.extra_fields) {
288
- clone.reviewSummery = getExtraField(operatorPage[0]?.extra_fields, 'operator_review_summary', null);
298
+ clone.reviewSummery = getExtraField(
299
+ operatorPage[0]?.extra_fields,
300
+ 'operator_review_summary',
301
+ null
302
+ );
289
303
  }
290
304
 
291
305
  if (operatorPage.length >= 1 && operatorPage[0].author) {
@@ -348,7 +362,9 @@ export function processModule(
348
362
  // See more link
349
363
  if (module.see_more_link?.value) {
350
364
  module.see_more_link.path =
351
- module.see_more_link?.type === 'page' ? pagesMappedById[module.see_more_link.value].path : module.see_more_link?.value
365
+ module.see_more_link?.type === 'page'
366
+ ? pagesMappedById[module.see_more_link.value].path
367
+ : module.see_more_link?.value;
352
368
  }
353
369
 
354
370
  if (module.name === 'cards') {