@faststore/core 2.0.147-alpha.0 → 2.0.151-alpha.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.
- package/.next/BUILD_ID +1 -0
- package/.next/build-manifest.json +132 -0
- package/.next/cache/.tsbuildinfo +1 -0
- package/.next/cache/config.json +7 -0
- package/.next/cache/eslint/.cache_1gneedd +1 -0
- package/.next/cache/next-server.js.nft.json +1 -0
- 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/export-marker.json +1 -0
- package/.next/images-manifest.json +1 -0
- package/.next/next-server.js.nft.json +1 -0
- package/.next/package.json +1 -0
- package/.next/prerender-manifest.json +1 -0
- package/.next/react-loadable-manifest.json +48 -0
- package/.next/required-server-files.json +1 -0
- package/.next/routes-manifest.json +1 -0
- package/.next/server/chunks/104.js +703 -0
- package/.next/server/chunks/123.js +58 -0
- package/.next/server/chunks/143.js +106 -0
- package/.next/server/chunks/183.js +80 -0
- package/.next/server/chunks/247.js +61 -0
- package/.next/server/chunks/280.js +324 -0
- package/.next/server/chunks/287.js +58 -0
- package/.next/server/chunks/312.js +670 -0
- package/.next/server/chunks/336.js +821 -0
- package/.next/server/chunks/350.js +142 -0
- package/.next/server/chunks/368.js +253 -0
- package/.next/server/chunks/401.js +7241 -0
- package/.next/server/chunks/431.js +7241 -0
- package/.next/server/chunks/502.js +600 -0
- package/.next/server/chunks/557.js +132 -0
- package/.next/server/chunks/576.js +80 -0
- package/.next/server/chunks/597.js +169 -0
- package/.next/server/chunks/608.js +644 -0
- package/.next/server/chunks/644.js +235 -0
- package/.next/server/chunks/664.js +3401 -0
- package/.next/server/chunks/676.js +32 -0
- package/.next/server/chunks/701.js +87 -0
- package/.next/server/chunks/74.js +2674 -0
- package/.next/server/chunks/746.js +225 -0
- package/.next/server/chunks/82.js +371 -0
- package/.next/server/chunks/854.js +72 -0
- package/.next/server/chunks/859.js +959 -0
- package/.next/server/chunks/874.js +487 -0
- package/.next/server/chunks/886.js +120 -0
- package/.next/server/chunks/907.js +1723 -0
- package/.next/server/chunks/98.js +124 -0
- package/.next/server/chunks/font-manifest.json +1 -0
- package/.next/server/font-manifest.json +1 -0
- package/.next/server/middleware-build-manifest.js +1 -0
- package/.next/server/middleware-manifest.json +6 -0
- package/.next/server/middleware-react-loadable-manifest.js +1 -0
- package/.next/server/pages/404.js +393 -0
- package/.next/server/pages/404.js.nft.json +1 -0
- package/.next/server/pages/500.js +395 -0
- package/.next/server/pages/500.js.nft.json +1 -0
- package/.next/server/pages/[...slug].js +718 -0
- package/.next/server/pages/[...slug].js.nft.json +1 -0
- package/.next/server/pages/[slug]/p.js +2458 -0
- package/.next/server/pages/[slug]/p.js.nft.json +1 -0
- package/.next/server/pages/_app.js +368 -0
- package/.next/server/pages/_app.js.nft.json +1 -0
- package/.next/server/pages/_document.js +304 -0
- package/.next/server/pages/_document.js.nft.json +1 -0
- package/.next/server/pages/_error.js +164 -0
- package/.next/server/pages/_error.js.nft.json +1 -0
- package/.next/server/pages/account.js +370 -0
- package/.next/server/pages/account.js.nft.json +1 -0
- package/.next/server/pages/api/graphql.js +315 -0
- package/.next/server/pages/api/graphql.js.nft.json +1 -0
- package/.next/server/pages/api/preview.js +118 -0
- package/.next/server/pages/api/preview.js.nft.json +1 -0
- package/.next/server/pages/checkout.js +370 -0
- package/.next/server/pages/checkout.js.nft.json +1 -0
- package/.next/server/pages/en-US/404.html +81 -0
- package/.next/server/pages/en-US/404.json +1 -0
- package/.next/server/pages/en-US/500.html +81 -0
- package/.next/server/pages/en-US/500.json +1 -0
- package/.next/server/pages/en-US/account.html +81 -0
- package/.next/server/pages/en-US/account.json +1 -0
- package/.next/server/pages/en-US/checkout.html +81 -0
- package/.next/server/pages/en-US/checkout.json +1 -0
- package/.next/server/pages/en-US/login.html +81 -0
- package/.next/server/pages/en-US/login.json +1 -0
- package/.next/server/pages/en-US/s.html +81 -0
- package/.next/server/pages/en-US/s.json +1 -0
- package/.next/server/pages/en-US.html +81 -0
- package/.next/server/pages/en-US.json +1 -0
- package/.next/server/pages/index.js +966 -0
- package/.next/server/pages/index.js.nft.json +1 -0
- package/.next/server/pages/login.js +375 -0
- package/.next/server/pages/login.js.nft.json +1 -0
- package/.next/server/pages/s.js +457 -0
- package/.next/server/pages/s.js.nft.json +1 -0
- package/.next/server/pages-manifest.json +16 -0
- package/.next/server/webpack-api-runtime.js +229 -0
- package/.next/server/webpack-runtime.js +229 -0
- package/.next/static/SPkTG9-gxU2UejLG7FvOw/_buildManifest.js +1 -0
- package/.next/static/SPkTG9-gxU2UejLG7FvOw/_ssgManifest.js +1 -0
- package/.next/static/chunks/143.dd8a556e6957baa1.js +1 -0
- package/.next/static/chunks/170.c17ce564bb568265.js +1 -0
- package/.next/static/chunks/226.b57e10ad9932f88c.js +1 -0
- package/.next/static/chunks/327-43715af4f3fffaf6.js +1 -0
- package/.next/static/chunks/336.0846f48eccce57e4.js +1 -0
- package/.next/static/chunks/366-4a0572a47e2225d9.js +1 -0
- package/.next/static/chunks/377-61e89c711b136605.js +1 -0
- package/.next/static/chunks/391-47b923ef44945418.js +1 -0
- package/.next/static/chunks/495.8ffebac98e9475dc.js +1 -0
- package/.next/static/chunks/502.ae82de1669112b15.js +1 -0
- package/.next/static/chunks/545-1d3d08edfd2ee4c6.js +1 -0
- package/.next/static/chunks/597.c5cf3fbeae5ceb63.js +1 -0
- package/.next/static/chunks/651.7142f31ce1e052b3.js +1 -0
- package/.next/static/chunks/741.52f7fb873418346f.js +1 -0
- package/.next/static/chunks/98.97381d2021f86cd9.js +1 -0
- package/.next/static/chunks/framework-dfd14d7ce6600b03.js +1 -0
- package/.next/static/chunks/main-fd466221927468fd.js +1 -0
- package/.next/static/chunks/pages/404-459452495a0df278.js +1 -0
- package/.next/static/chunks/pages/500-008e30c48eceebed.js +1 -0
- package/.next/static/chunks/pages/[...slug]-3c749c7d8561eb90.js +1 -0
- package/.next/static/chunks/pages/[slug]/p-fa35dd93d53f75f6.js +1 -0
- package/.next/static/chunks/pages/_app-3e4e7e579cb0681a.js +1 -0
- package/.next/static/chunks/pages/_error-a7a0c1d9bfbb4f38.js +1 -0
- package/.next/static/chunks/pages/account-46263f0c100c3eae.js +1 -0
- package/.next/static/chunks/pages/checkout-20bb3710b24df3b6.js +1 -0
- package/.next/static/chunks/pages/index-49b7ee570f7cc4b7.js +1 -0
- package/.next/static/chunks/pages/login-f9d316d261fcc062.js +1 -0
- package/.next/static/chunks/pages/s-890c0c4b88484224.js +1 -0
- package/.next/static/chunks/polyfills-c67a75d1b6f99dc8.js +1 -0
- package/.next/static/chunks/webpack-5051dce9659282f3.js +1 -0
- package/.next/static/css/13a4da555ff5e3be.css +1 -0
- package/.next/static/css/1de3e7b6ba8daaac.css +1 -0
- package/.next/static/css/2e00f7ba49c754b3.css +1 -0
- package/.next/static/css/2e9de35e0cb999e0.css +1 -0
- package/.next/static/css/43b1b3821e21630c.css +1 -0
- package/.next/static/css/48af598df5fe042d.css +1 -0
- package/.next/static/css/923c4a942e57bc91.css +1 -0
- package/.next/static/css/e02cdad8fc000339.css +1 -0
- package/.next/static/css/e434797816e17065.css +1 -0
- package/.next/static/css/e7a6f3559cf45c62.css +1 -0
- package/.next/trace +69 -0
- package/.turbo/turbo-build.log +3 -3
- package/CHANGELOG.md +6 -0
- package/cms/faststore/sections.json +26 -19
- package/package.json +4 -4
- package/public/~partytown/debug/partytown-atomics.js +556 -0
- package/public/~partytown/debug/partytown-media.js +374 -0
- package/public/~partytown/debug/partytown-sandbox-sw.js +543 -0
- package/public/~partytown/debug/partytown-sw.js +59 -0
- package/public/~partytown/debug/partytown-ww-atomics.js +1789 -0
- package/public/~partytown/debug/partytown-ww-sw.js +1781 -0
- package/public/~partytown/debug/partytown.js +72 -0
- package/public/~partytown/partytown-atomics.js +2 -0
- package/public/~partytown/partytown-media.js +2 -0
- package/public/~partytown/partytown-sw.js +2 -0
- package/public/~partytown/partytown.js +2 -0
- package/src/components/sections/ProductDetails/ProductDetails.tsx +106 -165
- package/src/components/{sections/ProducDetailsContent/ProductDetailsContent.tsx → ui/ProductDescription/ProductDescription.tsx} +7 -7
- package/src/components/ui/ProductDescription/index.ts +1 -0
- package/src/components/ui/ProductDetails/AddToCartLoadingSkeleton.tsx +57 -0
- package/src/components/ui/ProductDetails/ProductDetailsSettings.tsx +125 -0
- package/src/components/ui/ProductDetails/index.ts +2 -0
- package/src/components/ui/ShippingSimulation/ShippingSimulation.tsx +18 -2
- package/src/components/sections/ProducDetailsContent/index.ts +0 -1
- /package/src/components/{sections/ProducDetailsContent/ProductDetailsContent.stories.mdx → ui/ProductDescription/ProductDescription.stories.mdx} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":1,"files":["../../webpack-runtime.js","../../chunks/608.js","../../chunks/676.js","../../chunks/664.js","../../chunks/401.js","../../chunks/336.js","../../chunks/183.js","../../chunks/644.js","../../chunks/886.js","../../chunks/74.js","../../chunks/247.js","../../chunks/287.js","../../chunks/854.js","../../chunks/280.js","../../chunks/368.js","../../chunks/104.js","../../chunks/874.js","../../chunks/350.js","../../chunks/82.js","../../chunks/123.js","../../chunks/312.js","../../../package.json","../../../../node_modules/chalk/package.json","../../../../node_modules/@faststore/graphql-utils/package.json","../../../../node_modules/next/dist/shared/lib/head.js","../../../../node_modules/next/dist/shared/lib/app-router-context.js","../../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../../node_modules/next/dist/shared/lib/image-blur-svg.js","../../../../node_modules/next/dist/shared/lib/image-config-context.js","../../../../node_modules/next/dist/shared/lib/image-config.js","../../../../node_modules/next/dist/shared/lib/is-plain-object.js","../../../../node_modules/next/dist/shared/lib/mitt.js","../../../../node_modules/next/dist/shared/lib/router-context.js","../../../../node_modules/next/dist/shared/lib/utils.js","../../../../node_modules/next/dist/shared/lib/i18n/detect-domain-locale.js","../../../../node_modules/next/dist/shared/lib/i18n/normalize-locale-path.js","../../../../node_modules/next/dist/shared/lib/page-path/denormalize-page-path.js","../../../../node_modules/next/dist/shared/lib/router/utils/add-locale.js","../../../../node_modules/next/dist/shared/lib/router/utils/add-path-prefix.js","../../../../node_modules/next/dist/shared/lib/router/utils/compare-states.js","../../../../node_modules/next/dist/shared/lib/router/utils/format-next-pathname-info.js","../../../../node_modules/next/dist/shared/lib/router/utils/format-url.js","../../../../node_modules/next/dist/shared/lib/router/utils/get-asset-path-from-route.js","../../../../node_modules/next/dist/shared/lib/router/utils/get-next-pathname-info.js","../../../../node_modules/next/dist/shared/lib/router/utils/is-bot.js","../../../../node_modules/next/dist/shared/lib/router/utils/is-dynamic.js","../../../../node_modules/next/dist/shared/lib/router/utils/parse-path.js","../../../../node_modules/next/dist/shared/lib/router/utils/parse-relative-url.js","../../../../node_modules/next/dist/shared/lib/router/utils/path-has-prefix.js","../../../../node_modules/next/dist/shared/lib/router/utils/querystring.js","../../../../node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.js","../../../../node_modules/next/dist/shared/lib/router/utils/resolve-rewrites.js","../../../../node_modules/next/dist/shared/lib/router/utils/route-matcher.js","../../../../node_modules/next/dist/shared/lib/router/utils/route-regex.js","../../../../node_modules/chalk/source/index.js","../../../../node_modules/@faststore/graphql-utils/dist/index.js","../../../../node_modules/next/router.js","../../../../node_modules/next/package.json","../../../../node_modules/chalk/source/utilities.js","../../../../node_modules/next/dist/client/remove-base-path.js","../../../../node_modules/chalk/source/vendor/ansi-styles/index.js","../../../../node_modules/chalk/source/vendor/supports-color/index.js","../../../../node_modules/next/dist/client/router.js","../../../../node_modules/next/dist/client/has-base-path.js","../../../../node_modules/next/dist/shared/lib/side-effect.js","../../../../node_modules/next/dist/shared/lib/amp-context.js","../../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../../node_modules/next/dist/shared/lib/page-path/normalize-path-sep.js","../../../../node_modules/next/dist/shared/lib/router/utils/add-path-suffix.js","../../../../node_modules/next/dist/shared/lib/router/utils/remove-path-prefix.js","../../../../node_modules/next/dist/shared/lib/router/utils/path-match.js","../../../../node_modules/next/dist/shared/lib/router/utils/prepare-destination.js","../../../../node_modules/next/dist/shared/lib/escape-regexp.js","../../../../node_modules/next/dist/shared/lib/router/router.js","../../../../node_modules/next/dist/lib/is-error.js","../../../../node_modules/next/dist/shared/lib/router/utils/index.js","../../../../node_modules/next/dist/client/normalize-trailing-slash.js","../../../../node_modules/next/dist/client/route-loader.js","../../../../node_modules/next/dist/client/script.js","../../../../node_modules/next/dist/client/detect-domain-locale.js","../../../../node_modules/next/dist/client/add-locale.js","../../../../node_modules/next/dist/client/remove-locale.js","../../../../node_modules/next/dist/client/add-base-path.js","../../../../node_modules/next/dist/client/trusted-types.js","../../../../node_modules/next/dist/client/request-idle-callback.js","../../../../node_modules/next/dist/client/head-manager.js","../../../../node_modules/next/dist/client/with-router.js","../../../../node_modules/@swc/helpers/lib/_extends.js","../../../../node_modules/@swc/helpers/package.json","../../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../../node_modules/next/dist/shared/lib/router/utils/parse-url.js","../../../../node_modules/@swc/helpers/lib/_object_without_properties_loose.js","../../../../node_modules/next/dist/shared/lib/router/utils/sorted-routes.js","../../../../node_modules/next/dist/compiled/path-to-regexp/index.js","../../../../node_modules/next/dist/compiled/react-is/package.json","../../../../node_modules/next/dist/compiled/react-is/index.js","../../../../node_modules/next/dist/compiled/react-is/cjs/react-is.production.min.js","../../../../node_modules/next/dist/compiled/react-is/cjs/react-is.development.js","../../../../@generated/graphql/persisted.json","../../../../src/components/search/SearchDropdown/index.ts","../../../../package.json"]}
|
|
@@ -0,0 +1,368 @@
|
|
|
1
|
+
(() => {
|
|
2
|
+
var exports = {};
|
|
3
|
+
exports.id = 888;
|
|
4
|
+
exports.ids = [888];
|
|
5
|
+
exports.modules = {
|
|
6
|
+
|
|
7
|
+
/***/ 6917:
|
|
8
|
+
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
9
|
+
|
|
10
|
+
"use strict";
|
|
11
|
+
// ESM COMPAT FLAG
|
|
12
|
+
__webpack_require__.r(__webpack_exports__);
|
|
13
|
+
|
|
14
|
+
// EXPORTS
|
|
15
|
+
__webpack_require__.d(__webpack_exports__, {
|
|
16
|
+
"default": () => (/* binding */ _app)
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
;// CONCATENATED MODULE: external "nextjs-progressbar"
|
|
20
|
+
const external_nextjs_progressbar_namespaceObject = require("nextjs-progressbar");
|
|
21
|
+
var external_nextjs_progressbar_default = /*#__PURE__*/__webpack_require__.n(external_nextjs_progressbar_namespaceObject);
|
|
22
|
+
// EXTERNAL MODULE: ../components/dist/hooks/UIProvider.js
|
|
23
|
+
var UIProvider = __webpack_require__(395);
|
|
24
|
+
// EXTERNAL MODULE: external "react"
|
|
25
|
+
var external_react_ = __webpack_require__(6689);
|
|
26
|
+
// EXTERNAL MODULE: external "react/jsx-runtime"
|
|
27
|
+
var jsx_runtime_ = __webpack_require__(997);
|
|
28
|
+
;// CONCATENATED MODULE: ./src/Layout.tsx
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
const CartSidebar = /*#__PURE__*/(0,external_react_.lazy)(() => Promise.all(/* import() */[__webpack_require__.e(608), __webpack_require__.e(336), __webpack_require__.e(644), __webpack_require__.e(247), __webpack_require__.e(123), __webpack_require__.e(502)]).then(__webpack_require__.bind(__webpack_require__, 2502)));
|
|
35
|
+
const RegionModal = /*#__PURE__*/(0,external_react_.lazy)(() => Promise.all(/* import() */[__webpack_require__.e(336), __webpack_require__.e(287), __webpack_require__.e(597)]).then(__webpack_require__.bind(__webpack_require__, 1597)));
|
|
36
|
+
|
|
37
|
+
function Layout({
|
|
38
|
+
children
|
|
39
|
+
}) {
|
|
40
|
+
const {
|
|
41
|
+
cart: displayCart,
|
|
42
|
+
modal: displayModal
|
|
43
|
+
} = (0,UIProvider/* useUI */.l)();
|
|
44
|
+
return /*#__PURE__*/(0,jsx_runtime_.jsxs)(jsx_runtime_.Fragment, {
|
|
45
|
+
children: [children, displayCart && /*#__PURE__*/jsx_runtime_.jsx(external_react_.Suspense, {
|
|
46
|
+
fallback: null,
|
|
47
|
+
children: /*#__PURE__*/jsx_runtime_.jsx(CartSidebar, {})
|
|
48
|
+
}), displayModal && /*#__PURE__*/jsx_runtime_.jsx(external_react_.Suspense, {
|
|
49
|
+
fallback: null,
|
|
50
|
+
children: /*#__PURE__*/jsx_runtime_.jsx(RegionModal, {})
|
|
51
|
+
})]
|
|
52
|
+
});
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
/* harmony default export */ const src_Layout = (Layout);
|
|
56
|
+
// EXTERNAL MODULE: ../sdk/dist/analytics/wrap.js
|
|
57
|
+
var wrap = __webpack_require__(4950);
|
|
58
|
+
;// CONCATENATED MODULE: ../sdk/dist/analytics/useAnalyticsEvent.js
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
const useAnalyticsEvent = (handler) => {
|
|
62
|
+
const callback = (0,external_react_.useCallback)((message) => {
|
|
63
|
+
try {
|
|
64
|
+
if (message.data.name !== wrap/* ANALYTICS_EVENT_TYPE */.vi) {
|
|
65
|
+
return;
|
|
66
|
+
}
|
|
67
|
+
handler((0,wrap/* unwrap */.Wg)(message.data));
|
|
68
|
+
}
|
|
69
|
+
catch (err) {
|
|
70
|
+
console.error('Something went wrong while running Analytics handler');
|
|
71
|
+
}
|
|
72
|
+
}, [handler]);
|
|
73
|
+
(0,external_react_.useEffect)(() => {
|
|
74
|
+
window.addEventListener('message', callback);
|
|
75
|
+
return () => window.removeEventListener('message', callback);
|
|
76
|
+
}, [callback]);
|
|
77
|
+
};
|
|
78
|
+
//# sourceMappingURL=useAnalyticsEvent.js.map
|
|
79
|
+
// EXTERNAL MODULE: ./faststore.config.js
|
|
80
|
+
var faststore_config = __webpack_require__(7183);
|
|
81
|
+
var faststore_config_default = /*#__PURE__*/__webpack_require__.n(faststore_config);
|
|
82
|
+
;// CONCATENATED MODULE: ./src/sdk/analytics/index.tsx
|
|
83
|
+
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
if (false) {}
|
|
87
|
+
|
|
88
|
+
const AnalyticsHandler = () => {
|
|
89
|
+
useAnalyticsEvent(event => {
|
|
90
|
+
// Cleans the ecommerce object before pushing a new one
|
|
91
|
+
// This prevents the new data from getting merged with the previous one
|
|
92
|
+
// which could lead do inaccurate and old data being sent with events
|
|
93
|
+
//
|
|
94
|
+
// source: https://developers.google.com/tag-manager/ecommerce-ga4?hl=pt-br#clearing_the_ecommerce_object
|
|
95
|
+
window.dataLayer.push({
|
|
96
|
+
ecommerce: null
|
|
97
|
+
});
|
|
98
|
+
window.dataLayer.push({
|
|
99
|
+
event: event.name,
|
|
100
|
+
ecommerce: event.params
|
|
101
|
+
});
|
|
102
|
+
__webpack_require__(3982)(`./${(faststore_config_default()).platform}`).then(({
|
|
103
|
+
default: sendEvent
|
|
104
|
+
}) => {
|
|
105
|
+
sendEvent(event);
|
|
106
|
+
});
|
|
107
|
+
});
|
|
108
|
+
return null;
|
|
109
|
+
};
|
|
110
|
+
/* harmony default export */ const analytics = (AnalyticsHandler);
|
|
111
|
+
;// CONCATENATED MODULE: ./src/sdk/error/ErrorBoundary/ErrorBoundary.tsx
|
|
112
|
+
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
|
|
116
|
+
const getReloads = () => Number(window.sessionStorage.getItem('store:reloads') ?? '0');
|
|
117
|
+
|
|
118
|
+
const setReloads = reloads => window.sessionStorage.setItem('store:reloads', `${reloads}`);
|
|
119
|
+
|
|
120
|
+
const canRecover = () => getReloads() < 2;
|
|
121
|
+
|
|
122
|
+
const isFrameworkLevelError = error => error?.name === 'ChunkLoadError';
|
|
123
|
+
|
|
124
|
+
if (false) {}
|
|
125
|
+
|
|
126
|
+
class ErrorBoundary extends external_react_.Component {
|
|
127
|
+
constructor(...args) {
|
|
128
|
+
super(...args);
|
|
129
|
+
|
|
130
|
+
_defineProperty(this, "state", {
|
|
131
|
+
hasError: false,
|
|
132
|
+
error: null
|
|
133
|
+
});
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
static getDerivedStateFromError(error) {
|
|
137
|
+
return {
|
|
138
|
+
hasError: true,
|
|
139
|
+
error
|
|
140
|
+
};
|
|
141
|
+
} // We can't accurately type the error here, since it could vary depending on
|
|
142
|
+
// what caused it. This is not standardized.
|
|
143
|
+
|
|
144
|
+
|
|
145
|
+
componentDidCatch(error, errorInfo) {
|
|
146
|
+
console.error(`React Error: ${error.message} ${errorInfo.componentStack}`);
|
|
147
|
+
const errorId = 'unknown'; // prevent infinite loop
|
|
148
|
+
|
|
149
|
+
if (window.location.pathname.startsWith('/404') || window.location.pathname.startsWith('/500')) {
|
|
150
|
+
return;
|
|
151
|
+
}
|
|
152
|
+
|
|
153
|
+
const from = encodeURIComponent(window.location.pathname);
|
|
154
|
+
const is404 = error?.extensions?.exception?.status === 404;
|
|
155
|
+
|
|
156
|
+
if (isFrameworkLevelError(error) && canRecover()) {
|
|
157
|
+
setReloads(getReloads() + 1);
|
|
158
|
+
window.location.reload();
|
|
159
|
+
} else if (is404) {
|
|
160
|
+
window.location.href = `/404?from=${from}`;
|
|
161
|
+
} else {
|
|
162
|
+
window.location.href = `/500?from=${from}&errorId=${errorId}`;
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
render() {
|
|
167
|
+
if (this.state.hasError && true) {
|
|
168
|
+
return null;
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
return this.props.children;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
/* harmony default export */ const ErrorBoundary_ErrorBoundary = (ErrorBoundary);
|
|
177
|
+
;// CONCATENATED MODULE: ./src/sdk/error/ErrorBoundary/index.ts
|
|
178
|
+
|
|
179
|
+
;// CONCATENATED MODULE: ./src/pages/_app.tsx
|
|
180
|
+
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; }
|
|
181
|
+
|
|
182
|
+
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) { _app_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; }
|
|
183
|
+
|
|
184
|
+
function _app_defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
185
|
+
|
|
186
|
+
// FastStore UI's base styles
|
|
187
|
+
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
|
|
191
|
+
|
|
192
|
+
|
|
193
|
+
|
|
194
|
+
|
|
195
|
+
|
|
196
|
+
|
|
197
|
+
|
|
198
|
+
function App({
|
|
199
|
+
Component,
|
|
200
|
+
pageProps
|
|
201
|
+
}) {
|
|
202
|
+
return /*#__PURE__*/(0,jsx_runtime_.jsxs)(ErrorBoundary_ErrorBoundary, {
|
|
203
|
+
children: [/*#__PURE__*/jsx_runtime_.jsx((external_nextjs_progressbar_default()), {
|
|
204
|
+
color: "var(--fs-color-primary-bkg);",
|
|
205
|
+
showOnShallow: false,
|
|
206
|
+
options: {
|
|
207
|
+
showSpinner: false
|
|
208
|
+
}
|
|
209
|
+
}), /*#__PURE__*/jsx_runtime_.jsx(analytics, {}), /*#__PURE__*/jsx_runtime_.jsx(UIProvider/* default */.Z, {
|
|
210
|
+
children: /*#__PURE__*/jsx_runtime_.jsx(src_Layout, {
|
|
211
|
+
children: /*#__PURE__*/jsx_runtime_.jsx(Component, _objectSpread({}, pageProps))
|
|
212
|
+
})
|
|
213
|
+
})]
|
|
214
|
+
});
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
/* harmony default export */ const _app = (App);
|
|
218
|
+
|
|
219
|
+
/***/ }),
|
|
220
|
+
|
|
221
|
+
/***/ 3982:
|
|
222
|
+
/***/ ((module, __unused_webpack_exports, __webpack_require__) => {
|
|
223
|
+
|
|
224
|
+
var map = {
|
|
225
|
+
"./vtex": [
|
|
226
|
+
3664,
|
|
227
|
+
98
|
|
228
|
+
],
|
|
229
|
+
"./vtex/": [
|
|
230
|
+
3664,
|
|
231
|
+
98
|
|
232
|
+
],
|
|
233
|
+
"./vtex/index": [
|
|
234
|
+
3664,
|
|
235
|
+
98
|
|
236
|
+
],
|
|
237
|
+
"./vtex/index.ts": [
|
|
238
|
+
3664,
|
|
239
|
+
98
|
|
240
|
+
],
|
|
241
|
+
"./vtex/search": [
|
|
242
|
+
9143,
|
|
243
|
+
143
|
|
244
|
+
],
|
|
245
|
+
"./vtex/search.ts": [
|
|
246
|
+
9143,
|
|
247
|
+
143
|
|
248
|
+
]
|
|
249
|
+
};
|
|
250
|
+
function webpackAsyncContext(req) {
|
|
251
|
+
if(!__webpack_require__.o(map, req)) {
|
|
252
|
+
return Promise.resolve().then(() => {
|
|
253
|
+
var e = new Error("Cannot find module '" + req + "'");
|
|
254
|
+
e.code = 'MODULE_NOT_FOUND';
|
|
255
|
+
throw e;
|
|
256
|
+
});
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
var ids = map[req], id = ids[0];
|
|
260
|
+
return __webpack_require__.e(ids[1]).then(() => {
|
|
261
|
+
return __webpack_require__(id);
|
|
262
|
+
});
|
|
263
|
+
}
|
|
264
|
+
webpackAsyncContext.keys = () => (Object.keys(map));
|
|
265
|
+
webpackAsyncContext.id = 3982;
|
|
266
|
+
module.exports = webpackAsyncContext;
|
|
267
|
+
|
|
268
|
+
/***/ }),
|
|
269
|
+
|
|
270
|
+
/***/ 5490:
|
|
271
|
+
/***/ ((module) => {
|
|
272
|
+
|
|
273
|
+
"use strict";
|
|
274
|
+
module.exports = require("@faststore/graphql-utils");
|
|
275
|
+
|
|
276
|
+
/***/ }),
|
|
277
|
+
|
|
278
|
+
/***/ 3430:
|
|
279
|
+
/***/ ((module) => {
|
|
280
|
+
|
|
281
|
+
"use strict";
|
|
282
|
+
module.exports = require("idb-keyval");
|
|
283
|
+
|
|
284
|
+
/***/ }),
|
|
285
|
+
|
|
286
|
+
/***/ 4957:
|
|
287
|
+
/***/ ((module) => {
|
|
288
|
+
|
|
289
|
+
"use strict";
|
|
290
|
+
module.exports = require("next/dist/shared/lib/head.js");
|
|
291
|
+
|
|
292
|
+
/***/ }),
|
|
293
|
+
|
|
294
|
+
/***/ 4486:
|
|
295
|
+
/***/ ((module) => {
|
|
296
|
+
|
|
297
|
+
"use strict";
|
|
298
|
+
module.exports = require("next/dist/shared/lib/image-blur-svg.js");
|
|
299
|
+
|
|
300
|
+
/***/ }),
|
|
301
|
+
|
|
302
|
+
/***/ 744:
|
|
303
|
+
/***/ ((module) => {
|
|
304
|
+
|
|
305
|
+
"use strict";
|
|
306
|
+
module.exports = require("next/dist/shared/lib/image-config-context.js");
|
|
307
|
+
|
|
308
|
+
/***/ }),
|
|
309
|
+
|
|
310
|
+
/***/ 5843:
|
|
311
|
+
/***/ ((module) => {
|
|
312
|
+
|
|
313
|
+
"use strict";
|
|
314
|
+
module.exports = require("next/dist/shared/lib/image-config.js");
|
|
315
|
+
|
|
316
|
+
/***/ }),
|
|
317
|
+
|
|
318
|
+
/***/ 9232:
|
|
319
|
+
/***/ ((module) => {
|
|
320
|
+
|
|
321
|
+
"use strict";
|
|
322
|
+
module.exports = require("next/dist/shared/lib/utils.js");
|
|
323
|
+
|
|
324
|
+
/***/ }),
|
|
325
|
+
|
|
326
|
+
/***/ 6689:
|
|
327
|
+
/***/ ((module) => {
|
|
328
|
+
|
|
329
|
+
"use strict";
|
|
330
|
+
module.exports = require("react");
|
|
331
|
+
|
|
332
|
+
/***/ }),
|
|
333
|
+
|
|
334
|
+
/***/ 6405:
|
|
335
|
+
/***/ ((module) => {
|
|
336
|
+
|
|
337
|
+
"use strict";
|
|
338
|
+
module.exports = require("react-dom");
|
|
339
|
+
|
|
340
|
+
/***/ }),
|
|
341
|
+
|
|
342
|
+
/***/ 997:
|
|
343
|
+
/***/ ((module) => {
|
|
344
|
+
|
|
345
|
+
"use strict";
|
|
346
|
+
module.exports = require("react/jsx-runtime");
|
|
347
|
+
|
|
348
|
+
/***/ }),
|
|
349
|
+
|
|
350
|
+
/***/ 3823:
|
|
351
|
+
/***/ ((module) => {
|
|
352
|
+
|
|
353
|
+
"use strict";
|
|
354
|
+
module.exports = require("tabbable");
|
|
355
|
+
|
|
356
|
+
/***/ })
|
|
357
|
+
|
|
358
|
+
};
|
|
359
|
+
;
|
|
360
|
+
|
|
361
|
+
// load runtime
|
|
362
|
+
var __webpack_require__ = require("../webpack-runtime.js");
|
|
363
|
+
__webpack_require__.C(exports);
|
|
364
|
+
var __webpack_exec__ = (moduleId) => (__webpack_require__(__webpack_require__.s = moduleId))
|
|
365
|
+
var __webpack_exports__ = __webpack_require__.X(0, [183,886], () => (__webpack_exec__(6917)));
|
|
366
|
+
module.exports = __webpack_exports__;
|
|
367
|
+
|
|
368
|
+
})();
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":1,"files":["../webpack-runtime.js","../chunks/183.js","../chunks/886.js","../chunks/608.js","../chunks/336.js","../chunks/644.js","../chunks/247.js","../chunks/123.js","../chunks/502.js","../chunks/287.js","../chunks/597.js","../chunks/98.js","../chunks/143.js","../../package.json","../../../node_modules/nextjs-progressbar/package.json","../../../node_modules/@faststore/graphql-utils/package.json","../../../node_modules/next/dist/shared/lib/head.js","../../../node_modules/next/dist/shared/lib/head-manager-context.js","../../../node_modules/next/dist/shared/lib/image-blur-svg.js","../../../node_modules/next/dist/shared/lib/image-config-context.js","../../../node_modules/next/dist/shared/lib/image-config.js","../../../node_modules/next/dist/shared/lib/is-plain-object.js","../../../node_modules/next/dist/shared/lib/mitt.js","../../../node_modules/next/dist/shared/lib/router-context.js","../../../node_modules/next/dist/shared/lib/utils.js","../../../node_modules/next/dist/shared/lib/i18n/detect-domain-locale.js","../../../node_modules/next/dist/shared/lib/i18n/normalize-locale-path.js","../../../node_modules/next/dist/shared/lib/page-path/denormalize-page-path.js","../../../node_modules/next/dist/shared/lib/router/utils/add-locale.js","../../../node_modules/next/dist/shared/lib/router/utils/add-path-prefix.js","../../../node_modules/next/dist/shared/lib/router/utils/compare-states.js","../../../node_modules/next/dist/shared/lib/router/utils/format-next-pathname-info.js","../../../node_modules/next/dist/shared/lib/router/utils/format-url.js","../../../node_modules/next/dist/shared/lib/router/utils/get-asset-path-from-route.js","../../../node_modules/next/dist/shared/lib/router/utils/get-next-pathname-info.js","../../../node_modules/next/dist/shared/lib/router/utils/is-bot.js","../../../node_modules/next/dist/shared/lib/router/utils/is-dynamic.js","../../../node_modules/next/dist/shared/lib/router/utils/parse-path.js","../../../node_modules/next/dist/shared/lib/router/utils/parse-relative-url.js","../../../node_modules/next/dist/shared/lib/router/utils/path-has-prefix.js","../../../node_modules/next/dist/shared/lib/router/utils/querystring.js","../../../node_modules/next/dist/shared/lib/router/utils/remove-trailing-slash.js","../../../node_modules/next/dist/shared/lib/router/utils/resolve-rewrites.js","../../../node_modules/next/dist/shared/lib/router/utils/route-matcher.js","../../../node_modules/next/dist/shared/lib/router/utils/route-regex.js","../../../node_modules/nextjs-progressbar/dist/index.js","../../../node_modules/@faststore/graphql-utils/dist/index.js","../../../node_modules/next/router.js","../../../node_modules/next/package.json","../../../node_modules/next/dist/client/remove-base-path.js","../../../node_modules/next/dist/client/router.js","../../../node_modules/next/dist/client/has-base-path.js","../../../node_modules/next/dist/shared/lib/side-effect.js","../../../node_modules/next/dist/shared/lib/amp-context.js","../../../node_modules/next/dist/shared/lib/amp-mode.js","../../../node_modules/next/dist/shared/lib/page-path/normalize-path-sep.js","../../../node_modules/next/dist/shared/lib/router/utils/add-path-suffix.js","../../../node_modules/next/dist/shared/lib/router/utils/remove-path-prefix.js","../../../node_modules/next/dist/shared/lib/router/utils/path-match.js","../../../node_modules/next/dist/shared/lib/router/utils/prepare-destination.js","../../../node_modules/next/dist/shared/lib/escape-regexp.js","../../../node_modules/next/dist/shared/lib/router/router.js","../../../node_modules/next/dist/lib/is-error.js","../../../node_modules/next/dist/shared/lib/router/utils/index.js","../../../node_modules/next/dist/client/normalize-trailing-slash.js","../../../node_modules/next/dist/client/route-loader.js","../../../node_modules/next/dist/client/script.js","../../../node_modules/next/dist/client/detect-domain-locale.js","../../../node_modules/next/dist/client/add-locale.js","../../../node_modules/next/dist/client/remove-locale.js","../../../node_modules/next/dist/client/add-base-path.js","../../../node_modules/next/dist/client/trusted-types.js","../../../node_modules/next/dist/client/request-idle-callback.js","../../../node_modules/next/dist/client/head-manager.js","../../../node_modules/next/dist/client/with-router.js","../../../node_modules/@swc/helpers/lib/_extends.js","../../../node_modules/@swc/helpers/package.json","../../../node_modules/@swc/helpers/lib/_interop_require_default.js","../../../node_modules/@swc/helpers/lib/_interop_require_wildcard.js","../../../node_modules/@swc/helpers/lib/_async_to_generator.js","../../../node_modules/next/dist/shared/lib/router/utils/parse-url.js","../../../node_modules/@swc/helpers/lib/_object_without_properties_loose.js","../../../node_modules/next/dist/shared/lib/router/utils/sorted-routes.js","../../../node_modules/next/dist/compiled/path-to-regexp/index.js","../../../node_modules/next/dist/compiled/react-is/package.json","../../../node_modules/next/dist/compiled/react-is/index.js","../../../node_modules/next/dist/compiled/react-is/cjs/react-is.production.min.js","../../../node_modules/next/dist/compiled/react-is/cjs/react-is.development.js","../../../src/components/cart/CartSidebar/index.ts","../../../src/components/region/RegionModal/index.ts","../../../package.json","../../../src/sdk/analytics/platform/vtex/index.ts","../../../src/sdk/analytics/platform/vtex/search.ts"]}
|