@faststore/core 2.1.38 → 2.1.39
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/.next/BUILD_ID +1 -1
- package/.next/build-manifest.json +3 -3
- package/.next/cache/.tsbuildinfo +1 -1
- package/.next/cache/config.json +3 -3
- package/.next/cache/eslint/.cache_1gneedd +1 -1
- package/.next/cache/next-server.js.nft.json +1 -1
- package/.next/cache/webpack/client-production/0.pack +0 -0
- package/.next/cache/webpack/client-production/index.pack +0 -0
- package/.next/cache/webpack/server-production/0.pack +0 -0
- package/.next/cache/webpack/server-production/index.pack +0 -0
- package/.next/next-server.js.nft.json +1 -1
- package/.next/prerender-manifest.json +1 -1
- package/.next/routes-manifest.json +1 -1
- package/.next/server/chunks/350.js +1 -1
- package/.next/server/middleware-build-manifest.js +1 -1
- package/.next/server/pages/[slug]/p.js +46 -17
- package/.next/server/pages/api/graphql.js +1 -1
- package/.next/server/pages/en-US/404.html +2 -2
- package/.next/server/pages/en-US/500.html +2 -2
- package/.next/server/pages/en-US/account.html +2 -2
- package/.next/server/pages/en-US/checkout.html +2 -2
- package/.next/server/pages/en-US/login.html +2 -2
- package/.next/server/pages/en-US/s.html +2 -2
- package/.next/server/pages/en-US.html +2 -2
- package/.next/server/pages-manifest.json +3 -3
- package/.next/static/{OxGIJPGNOTL0f1MehwB7N → AZ5H7_jKsFGK4P5JiXSwz}/_buildManifest.js +1 -1
- package/.next/static/chunks/pages/[slug]/{p-c1f2b05344981f12.js → p-44e66d729b2413fb.js} +1 -1
- package/.next/trace +80 -80
- package/.turbo/turbo-build.log +1 -1
- package/package.json +2 -2
- package/src/pages/[slug]/p.tsx +36 -17
- /package/.next/static/{OxGIJPGNOTL0f1MehwB7N → AZ5H7_jKsFGK4P5JiXSwz}/_ssgManifest.js +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
self.__BUILD_MANIFEST={polyfillFiles:["static/chunks/polyfills-c67a75d1b6f99dc8.js"],devFiles:[],ampDevFiles:[],lowPriorityFiles:["static/
|
|
1
|
+
self.__BUILD_MANIFEST={polyfillFiles:["static/chunks/polyfills-c67a75d1b6f99dc8.js"],devFiles:[],ampDevFiles:[],lowPriorityFiles:["static/AZ5H7_jKsFGK4P5JiXSwz/_buildManifest.js","static/AZ5H7_jKsFGK4P5JiXSwz/_ssgManifest.js"],rootMainFiles:[],pages:{"/":["static/chunks/webpack-73cade94715ad9e1.js","static/chunks/framework-dfd14d7ce6600b03.js","static/chunks/main-fd466221927468fd.js","static/chunks/738-a5ff304828f20cbf.js","static/chunks/548-6b23e7ad82cd22b9.js","static/css/4ad5a6bd11a9f8d8.css","static/chunks/706-1020d118bb59b204.js","static/css/41ef280537acec50.css","static/chunks/209-d1d2eeaeefbc68f7.js","static/css/5330ae3076254840.css","static/chunks/pages/index-bdbfb082027ed2b7.js"],"/404":["static/chunks/webpack-73cade94715ad9e1.js","static/chunks/framework-dfd14d7ce6600b03.js","static/chunks/main-fd466221927468fd.js","static/chunks/738-a5ff304828f20cbf.js","static/css/4ad5a6bd11a9f8d8.css","static/chunks/706-1020d118bb59b204.js","static/css/af5ef0767b748cb3.css","static/chunks/pages/404-14d27e3706f3d2c3.js"],"/500":["static/chunks/webpack-73cade94715ad9e1.js","static/chunks/framework-dfd14d7ce6600b03.js","static/chunks/main-fd466221927468fd.js","static/chunks/738-a5ff304828f20cbf.js","static/css/4ad5a6bd11a9f8d8.css","static/chunks/706-1020d118bb59b204.js","static/css/af5ef0767b748cb3.css","static/chunks/pages/500-250ccf5c9626e451.js"],"/[...slug]":["static/chunks/webpack-73cade94715ad9e1.js","static/chunks/framework-dfd14d7ce6600b03.js","static/chunks/main-fd466221927468fd.js","static/chunks/738-a5ff304828f20cbf.js","static/chunks/548-6b23e7ad82cd22b9.js","static/css/4ad5a6bd11a9f8d8.css","static/chunks/706-1020d118bb59b204.js","static/css/41ef280537acec50.css","static/chunks/209-d1d2eeaeefbc68f7.js","static/css/82a475e147f4b2ee.css","static/chunks/791-681afeb766a9098f.js","static/css/5330ae3076254840.css","static/css/d67fbe2a613293c1.css","static/chunks/pages/[...slug]-bcfaf0c5d60b57a0.js"],"/[slug]/p":["static/chunks/webpack-73cade94715ad9e1.js","static/chunks/framework-dfd14d7ce6600b03.js","static/chunks/main-fd466221927468fd.js","static/chunks/738-a5ff304828f20cbf.js","static/chunks/548-6b23e7ad82cd22b9.js","static/css/4ad5a6bd11a9f8d8.css","static/chunks/706-1020d118bb59b204.js","static/css/41ef280537acec50.css","static/chunks/209-d1d2eeaeefbc68f7.js","static/css/5972921daee792bb.css","static/chunks/pages/[slug]/p-44e66d729b2413fb.js"],"/_app":["static/chunks/webpack-73cade94715ad9e1.js","static/chunks/framework-dfd14d7ce6600b03.js","static/chunks/main-fd466221927468fd.js","static/css/208b7dd52a0981bd.css","static/chunks/pages/_app-babcc4d7b80d8f4a.js"],"/_error":["static/chunks/webpack-73cade94715ad9e1.js","static/chunks/framework-dfd14d7ce6600b03.js","static/chunks/main-fd466221927468fd.js","static/chunks/pages/_error-a7a0c1d9bfbb4f38.js"],"/account":["static/chunks/webpack-73cade94715ad9e1.js","static/chunks/framework-dfd14d7ce6600b03.js","static/chunks/main-fd466221927468fd.js","static/chunks/738-a5ff304828f20cbf.js","static/css/4ad5a6bd11a9f8d8.css","static/chunks/706-1020d118bb59b204.js","static/chunks/pages/account-d248acc931146694.js"],"/checkout":["static/chunks/webpack-73cade94715ad9e1.js","static/chunks/framework-dfd14d7ce6600b03.js","static/chunks/main-fd466221927468fd.js","static/chunks/738-a5ff304828f20cbf.js","static/css/4ad5a6bd11a9f8d8.css","static/chunks/706-1020d118bb59b204.js","static/chunks/pages/checkout-97f6d6f36f041a6f.js"],"/login":["static/chunks/webpack-73cade94715ad9e1.js","static/chunks/framework-dfd14d7ce6600b03.js","static/chunks/main-fd466221927468fd.js","static/chunks/738-a5ff304828f20cbf.js","static/css/4ad5a6bd11a9f8d8.css","static/chunks/706-1020d118bb59b204.js","static/css/af5ef0767b748cb3.css","static/chunks/pages/login-b1bdf30c951bb60d.js"],"/s":["static/chunks/webpack-73cade94715ad9e1.js","static/chunks/framework-dfd14d7ce6600b03.js","static/chunks/main-fd466221927468fd.js","static/chunks/738-a5ff304828f20cbf.js","static/css/4ad5a6bd11a9f8d8.css","static/chunks/706-1020d118bb59b204.js","static/css/82a475e147f4b2ee.css","static/chunks/791-681afeb766a9098f.js","static/chunks/pages/s-aabfa5c08338974a.js"]},ampFirstPages:[]};
|
|
@@ -1612,6 +1612,12 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
1612
1612
|
/* harmony import */ var react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14___default = /*#__PURE__*/__webpack_require__.n(react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14__);
|
|
1613
1613
|
var __webpack_async_dependencies__ = __webpack_handle_async_dependencies__([src_components_cms_RenderSections__WEBPACK_IMPORTED_MODULE_2__, src_components_sections_BannerNewsletter_BannerNewsletter__WEBPACK_IMPORTED_MODULE_3__, src_components_sections_CrossSellingShelf__WEBPACK_IMPORTED_MODULE_5__, src_components_sections_ProductDetails__WEBPACK_IMPORTED_MODULE_6__, src_server__WEBPACK_IMPORTED_MODULE_10__, src_components_cms_GlobalSections__WEBPACK_IMPORTED_MODULE_12__]);
|
|
1614
1614
|
([src_components_cms_RenderSections__WEBPACK_IMPORTED_MODULE_2__, src_components_sections_BannerNewsletter_BannerNewsletter__WEBPACK_IMPORTED_MODULE_3__, src_components_sections_CrossSellingShelf__WEBPACK_IMPORTED_MODULE_5__, src_components_sections_ProductDetails__WEBPACK_IMPORTED_MODULE_6__, src_server__WEBPACK_IMPORTED_MODULE_10__, src_components_cms_GlobalSections__WEBPACK_IMPORTED_MODULE_12__] = __webpack_async_dependencies__.then ? (await __webpack_async_dependencies__)() : __webpack_async_dependencies__);
|
|
1615
|
+
const _excluded = ["listPrice"];
|
|
1616
|
+
|
|
1617
|
+
function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
|
|
1618
|
+
|
|
1619
|
+
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
1620
|
+
|
|
1615
1621
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
1616
1622
|
|
|
1617
1623
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
@@ -1650,27 +1656,23 @@ const COMPONENTS = _objectSpread({
|
|
|
1650
1656
|
function Page({
|
|
1651
1657
|
product,
|
|
1652
1658
|
sections,
|
|
1653
|
-
globalSections
|
|
1659
|
+
globalSections,
|
|
1660
|
+
offers,
|
|
1661
|
+
meta
|
|
1654
1662
|
}) {
|
|
1655
1663
|
const {
|
|
1656
1664
|
currency
|
|
1657
1665
|
} = (0,src_sdk_session__WEBPACK_IMPORTED_MODULE_8__/* .useSession */ .kP)();
|
|
1658
|
-
const {
|
|
1659
|
-
seo
|
|
1660
|
-
} = product;
|
|
1661
|
-
const title = seo.title || (_faststore_config__WEBPACK_IMPORTED_MODULE_13___default().seo.title);
|
|
1662
|
-
const description = seo.description || (_faststore_config__WEBPACK_IMPORTED_MODULE_13___default().seo.description);
|
|
1663
|
-
const canonical = `${(_faststore_config__WEBPACK_IMPORTED_MODULE_13___default().storeUrl)}${seo.canonical}`;
|
|
1664
1666
|
return /*#__PURE__*/(0,react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14__.jsxs)(src_components_cms_GlobalSections__WEBPACK_IMPORTED_MODULE_12__/* ["default"] */ .ZP, _objectSpread(_objectSpread({}, globalSections), {}, {
|
|
1665
1667
|
children: [/*#__PURE__*/react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14__.jsx(next_seo__WEBPACK_IMPORTED_MODULE_1__.NextSeo, {
|
|
1666
|
-
title: title,
|
|
1667
|
-
description: description,
|
|
1668
|
-
canonical: canonical,
|
|
1668
|
+
title: meta.title,
|
|
1669
|
+
description: meta.description,
|
|
1670
|
+
canonical: meta.canonical,
|
|
1669
1671
|
openGraph: {
|
|
1670
1672
|
type: 'og:product',
|
|
1671
|
-
url: canonical,
|
|
1672
|
-
title,
|
|
1673
|
-
description,
|
|
1673
|
+
url: meta.canonical,
|
|
1674
|
+
title: meta.title,
|
|
1675
|
+
description: meta.description,
|
|
1674
1676
|
images: product.image.map(img => ({
|
|
1675
1677
|
url: img.url,
|
|
1676
1678
|
alt: img.alternateName
|
|
@@ -1694,10 +1696,7 @@ function Page({
|
|
|
1694
1696
|
releaseDate: product.releaseDate,
|
|
1695
1697
|
images: product.image.map(img => img.url) // Somehow, Google does not understand this valid Schema.org schema, so we need to do conversions
|
|
1696
1698
|
,
|
|
1697
|
-
|
|
1698
|
-
offers: _objectSpread(_objectSpread(_objectSpread({}, product.offers), product.offers.offers[0]), {}, {
|
|
1699
|
-
url: canonical
|
|
1700
|
-
})
|
|
1699
|
+
offers: offers
|
|
1701
1700
|
}), /*#__PURE__*/react_jsx_runtime__WEBPACK_IMPORTED_MODULE_14__.jsx(src_components_cms_RenderSections__WEBPACK_IMPORTED_MODULE_2__/* ["default"] */ .Z, {
|
|
1702
1701
|
context: product,
|
|
1703
1702
|
sections: sections,
|
|
@@ -1736,8 +1735,38 @@ const getStaticProps = async ({
|
|
|
1736
1735
|
throw errors[0];
|
|
1737
1736
|
}
|
|
1738
1737
|
|
|
1738
|
+
const {
|
|
1739
|
+
seo
|
|
1740
|
+
} = data.product;
|
|
1741
|
+
const title = seo.title || (_faststore_config__WEBPACK_IMPORTED_MODULE_13___default().seo.title);
|
|
1742
|
+
const description = seo.description || (_faststore_config__WEBPACK_IMPORTED_MODULE_13___default().seo.description);
|
|
1743
|
+
const canonical = `${(_faststore_config__WEBPACK_IMPORTED_MODULE_13___default().storeUrl)}${seo.canonical}`;
|
|
1744
|
+
const meta = {
|
|
1745
|
+
title,
|
|
1746
|
+
description,
|
|
1747
|
+
canonical
|
|
1748
|
+
};
|
|
1749
|
+
let offer = {};
|
|
1750
|
+
|
|
1751
|
+
if (data.product.offers.offers.length > 0) {
|
|
1752
|
+
const _data$product$offers$ = data.product.offers.offers[0],
|
|
1753
|
+
{
|
|
1754
|
+
listPrice
|
|
1755
|
+
} = _data$product$offers$,
|
|
1756
|
+
offerData = _objectWithoutProperties(_data$product$offers$, _excluded);
|
|
1757
|
+
|
|
1758
|
+
offer = offerData;
|
|
1759
|
+
}
|
|
1760
|
+
|
|
1761
|
+
const offers = _objectSpread(_objectSpread({}, offer), {}, {
|
|
1762
|
+
priceCurrency: data.product.offers.priceCurrency,
|
|
1763
|
+
url: canonical
|
|
1764
|
+
});
|
|
1765
|
+
|
|
1739
1766
|
return {
|
|
1740
1767
|
props: _objectSpread(_objectSpread(_objectSpread({}, data), cmsPage), {}, {
|
|
1768
|
+
meta,
|
|
1769
|
+
offers,
|
|
1741
1770
|
globalSections
|
|
1742
1771
|
})
|
|
1743
1772
|
};
|