@griddo/cx 1.58.0 → 1.58.4

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@griddo/cx",
3
3
  "description": "Griddo SSG based on Gatsby",
4
- "version": "1.58.0",
4
+ "version": "1.58.4",
5
5
  "authors": [
6
6
  "Álvaro Sánchez' <alvaro.sanches@secuoyas.com>",
7
7
  "Carlos Torres <carlos.torres@secuoyas.com>",
@@ -66,7 +66,7 @@
66
66
  "react-helmet": "^6.0.0"
67
67
  },
68
68
  "devDependencies": {
69
- "@griddo/eslint-config-back": "^1.58.0",
69
+ "@griddo/eslint-config-back": "^1.58.4",
70
70
  "eslint": "^7.5.0",
71
71
  "eslint-plugin-node": "^11.1.0",
72
72
  "eslint-plugin-react": "7.14.3",
@@ -98,5 +98,5 @@
98
98
  "publishConfig": {
99
99
  "access": "public"
100
100
  },
101
- "gitHead": "b1f7f7e2c2654ecbfdca9176cbb2e81fdb808ed7"
101
+ "gitHead": "3bba1665cc91e7a6b8c1112117883cc0b7cdfee4"
102
102
  }
@@ -13,7 +13,7 @@ const ENDPOINTS = {
13
13
  GET_DISTRIBUTOR_DATA: [`${withURI}`, '/distributor'],
14
14
  GET_SITEMAP: [`${withURI}`, '/sitemap'],
15
15
  SOCIALS: [`${withURI}`, '/socials'],
16
- GET_PAGES: [`${withURI}`, '/pages'],
16
+ GET_PAGES: [`${withURI}`, '/pages?pagination=false'],
17
17
  };
18
18
 
19
19
  class SitesService {
@@ -140,10 +140,11 @@ async function renderMultiplePages(page, additionalInfo, createPage) {
140
140
  const paginatedPage = JSON.parse(JSON.stringify(cleanPage));
141
141
  const {
142
142
  sectionSlug = '/',
143
- title = '',
143
+ title: bulkTitle = '',
144
144
  metaTitle = '',
145
145
  metaDescription = '',
146
146
  } = pageElement;
147
+ const title = bulkTitle.content || bulkTitle;
147
148
  const compose = paginatedPage?.fullPath?.compose || '';
148
149
  const fullUrl = paginatedPage.fullUrl.endsWith('/')
149
150
  ? paginatedPage.fullUrl.slice(0, -1)
@@ -157,7 +158,7 @@ async function renderMultiplePages(page, additionalInfo, createPage) {
157
158
  paginatedPage.template.activeSectionSlug = sectionSlug;
158
159
  paginatedPage.template.activeSectionBase = fullUrl;
159
160
  if (title.trim()) paginatedPage.title = title;
160
- if (metaTitle.trim()) paginatedPage.metaTitle = metaTitle;
161
+ paginatedPage.metaTitle = metaTitle.trim() || title.trim() || paginatedPage.metaTitle;
161
162
  if (metaDescription.trim()) paginatedPage.metaDescription = metaDescription;
162
163
  await renderSinglePage(paginatedPage, additionalInfo, createPage);
163
164
  }