@faststore/core 3.7.0 → 3.9.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 -1
- package/.next/build-manifest.json +35 -35
- package/.next/cache/.tsbuildinfo +1 -1
- package/.next/cache/config.json +3 -3
- package/.next/cache/eslint/.cache_1gneedd +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-minimal-server.js.nft.json +1 -1
- package/.next/next-server.js.nft.json +1 -1
- package/.next/prerender-manifest.js +1 -1
- package/.next/prerender-manifest.json +1 -1
- package/.next/react-loadable-manifest.json +12 -12
- package/.next/routes-manifest.json +1 -1
- package/.next/server/chunks/2082.js +4 -4
- package/.next/server/chunks/319.js +1 -1
- package/.next/server/chunks/5110.js +1 -1
- package/.next/server/chunks/5671.js +1 -1
- package/.next/server/chunks/5754.js +2 -2
- package/.next/server/chunks/9410.js +1 -1
- package/.next/server/chunks/9572.js +2 -2
- package/.next/server/chunks/9844.js +1 -1
- package/.next/server/middleware-build-manifest.js +1 -1
- package/.next/server/middleware-react-loadable-manifest.js +1 -1
- package/.next/server/pages/404.js +1 -1
- package/.next/server/pages/500.js +1 -1
- package/.next/server/pages/[...slug].js +1 -1
- package/.next/server/pages/[slug]/p.js +1 -1
- package/.next/server/pages/api/graphql.js +1 -1
- package/.next/server/pages/en-US/404.html +1 -1
- package/.next/server/pages/en-US/404.json +1 -1
- package/.next/server/pages/en-US/500.html +1 -1
- package/.next/server/pages/en-US/500.json +1 -1
- package/.next/server/pages/en-US/account.html +1 -1
- package/.next/server/pages/en-US/account.json +1 -1
- package/.next/server/pages/en-US/checkout.html +1 -1
- package/.next/server/pages/en-US/checkout.json +1 -1
- package/.next/server/pages/en-US/login.html +1 -1
- package/.next/server/pages/en-US/login.json +1 -1
- package/.next/server/pages/en-US/s.html +1 -1
- package/.next/server/pages/en-US/s.json +1 -1
- package/.next/server/pages/en-US.html +1 -1
- package/.next/server/pages/en-US.json +1 -1
- package/.next/server/pages/index.js +1 -1
- package/.next/server/pages/login.js +1 -1
- package/.next/server/pages/s.js +1 -1
- package/.next/server/pages-manifest.json +1 -1
- package/.next/static/chunks/{1978.6d1246731da0f1b0.js → 1978.b33d8b2c02b89474.js} +1 -1
- package/.next/static/chunks/4501-effb6aa25a455116.js +1 -0
- package/.next/static/chunks/6379-5bc15c2be0861eec.js +1 -0
- package/.next/static/chunks/7563-92cb0cc92e3f616d.js +1 -0
- package/.next/static/chunks/BannerNewsletter.ee0b11fa76f97f1e.js +1 -0
- package/.next/static/chunks/BannerText.2914f18ab31cab35.js +1 -0
- package/.next/static/chunks/Newsletter.99c659682ed8b4eb.js +1 -0
- package/.next/static/chunks/ProductShelf.4aeec65ee9e7d9bc.js +1 -0
- package/.next/static/chunks/pages/404-5e3ccc26e8693eea.js +1 -0
- package/.next/static/chunks/pages/500-823cb0432a498a6a.js +1 -0
- package/.next/static/chunks/pages/[...slug]-535243edd040fc0c.js +1 -0
- package/.next/static/chunks/pages/[slug]/p-1334ebce46042e06.js +1 -0
- package/.next/static/chunks/pages/{_app-9d791333b87e7c18.js → _app-9d35d5919aef5334.js} +1 -1
- package/.next/static/chunks/pages/{account-9db0ef5c4174c7dd.js → account-1d2b1635afa59ace.js} +1 -1
- package/.next/static/chunks/pages/{checkout-abaa6374ae946641.js → checkout-4b85659485b4500c.js} +1 -1
- package/.next/static/chunks/pages/index-01e855e8041d8ecd.js +1 -0
- package/.next/static/chunks/pages/login-ec8f707d0c577b05.js +1 -0
- package/.next/static/chunks/pages/s-a932301211f32425.js +1 -0
- package/.next/static/chunks/{webpack-0d0b6c5bc10dfaad.js → webpack-bf502499da135235.js} +1 -1
- package/.next/static/sMXa4bqsC2EIl72tw9r2B/_buildManifest.js +1 -0
- package/.next/trace +101 -98
- package/.turbo/turbo-build.log +13 -13
- package/.turbo/turbo-lint.log +1 -1
- package/.turbo/turbo-test.log +5 -5
- package/CHANGELOG.md +12 -0
- package/package.json +9 -9
- package/src/components/cms/RenderSections.tsx +55 -8
- package/src/components/cms/ViewportObserver.tsx +3 -1
- package/src/components/cms/global/Components.ts +2 -0
- package/src/components/cms/home/Components.ts +2 -0
- package/src/components/cms/plp/Components.ts +2 -0
- package/src/components/cms/search/Components.ts +2 -0
- package/src/components/sections/Alert/OverriddenDefaultAlert.ts +2 -0
- package/src/components/sections/BannerText/OverriddenDefaultBannerText.ts +2 -0
- package/src/components/sections/Breadcrumb/OverriddenDefaultBreadcrumb.ts +2 -0
- package/src/components/sections/CrossSellingShelf/OverriddenDefaultCrossSellingShelf.ts +2 -0
- package/src/components/sections/EmptyState/OverriddenDefaultEmptyState.ts +2 -0
- package/src/components/sections/Hero/OverriddenDefaultHero.ts +2 -0
- package/src/components/sections/Navbar/OverriddenDefaultNavbar.ts +2 -0
- package/src/components/sections/Newsletter/OverriddenDefaultNewsletter.ts +2 -0
- package/src/components/sections/ProductDetails/OverriddenDefaultProductDetails.ts +2 -0
- package/src/components/sections/ProductGallery/OverriddenDefaultProductGallery.ts +2 -0
- package/src/components/sections/ProductShelf/OverriddenDefaultProductShelf.ts +2 -0
- package/src/components/sections/RegionBar/OverriddenDefaultRegionBar.ts +2 -0
- package/src/components/templates/LandingPage/LandingPage.tsx +2 -0
- package/src/customizations/src/GlobalOverrides.tsx +6 -0
- package/src/pages/404.tsx +2 -0
- package/src/pages/500.tsx +2 -0
- package/src/pages/[slug]/p.tsx +2 -0
- package/src/pages/_app.tsx +1 -0
- package/src/pages/login.tsx +2 -0
- package/src/plugins/.gitkeep +0 -0
- package/src/plugins/index.scss +3 -0
- package/src/plugins/index.ts +2 -0
- package/src/plugins/overrides/Alert.tsx +3 -0
- package/src/plugins/overrides/BannerText.tsx +3 -0
- package/src/plugins/overrides/Breadcrumb.tsx +3 -0
- package/src/plugins/overrides/CrossSellingShelf.tsx +3 -0
- package/src/plugins/overrides/EmptyState.tsx +3 -0
- package/src/plugins/overrides/Hero.tsx +3 -0
- package/src/plugins/overrides/Navbar.tsx +3 -0
- package/src/plugins/overrides/Newsletter.tsx +3 -0
- package/src/plugins/overrides/ProductDetails.tsx +3 -0
- package/src/plugins/overrides/ProductGallery.tsx +3 -0
- package/src/plugins/overrides/ProductShelf.tsx +3 -0
- package/src/plugins/overrides/RegionBar.tsx +3 -0
- package/src/plugins/overrides/ThirdPartyScripts.tsx +3 -0
- package/src/plugins/overrides/WebFonts.tsx +3 -0
- package/src/sdk/performance/useTTI.ts +35 -0
- package/.next/static/chunks/1550-a6207993ae890714.js +0 -1
- package/.next/static/chunks/4501-7857a5a8218d9f58.js +0 -1
- package/.next/static/chunks/6379-e49fe5643b85d5b5.js +0 -1
- package/.next/static/chunks/BannerNewsletter.29403e046f34b6c1.js +0 -1
- package/.next/static/chunks/BannerText.24939a8013e30e18.js +0 -1
- package/.next/static/chunks/Newsletter.7a07fe93f98e2922.js +0 -1
- package/.next/static/chunks/ProductShelf.d40d1e693c5a302b.js +0 -1
- package/.next/static/chunks/pages/404-358f6795222bf991.js +0 -1
- package/.next/static/chunks/pages/500-7adc48c3231ccee1.js +0 -1
- package/.next/static/chunks/pages/[...slug]-0203b74377537f7d.js +0 -1
- package/.next/static/chunks/pages/[slug]/p-c005eeb4788692e7.js +0 -1
- package/.next/static/chunks/pages/index-ad532cf8840c5d3f.js +0 -1
- package/.next/static/chunks/pages/login-8d2eb8db226d6363.js +0 -1
- package/.next/static/chunks/pages/s-ba5734fbe496d9af.js +0 -1
- package/.next/static/wTXZLYjYfhhubsnCUqtpc/_buildManifest.js +0 -1
- /package/.next/static/{wTXZLYjYfhhubsnCUqtpc → sMXa4bqsC2EIl72tw9r2B}/_ssgManifest.js +0 -0
package/.turbo/turbo-build.log
CHANGED
|
@@ -38,41 +38,41 @@ https://nextjs.org/telemetry
|
|
|
38
38
|
Collecting page data ...
|
|
39
39
|
Generating static pages (0/7) ...
|
|
40
40
|
|
|
41
41
|
Generating static pages (1/7)
|
|
42
|
-
|
|
43
42
|
Generating static pages (3/7)
|
|
44
43
|
Warning: Dynamic Content not found for the page: home. Refer to the Dynamic Content documentation at https://developers.vtex.com/docs/guides/faststore/dynamic-content-overview for mapping the page and the corresponding data-fetching function.
|
|
44
|
+
|
|
45
45
|
Generating static pages (3/7)
|
|
46
46
|
|
|
47
47
|
Generating static pages (5/7)
|
|
48
48
|
|
|
49
49
|
✓ Generating static pages (7/7)
|
|
50
50
|
Finalizing page optimization ...
|
|
51
51
|
Collecting build traces ...
|
|
52
52
|
|
|
53
53
|
Route (pages) Size First Load JS
|
|
54
|
-
┌ ● / 3.
|
|
54
|
+
┌ ● / 3.23 kB 122 kB
|
|
55
55
|
├ └ css/b1806cbafd0c1f81.css 3.06 kB
|
|
56
56
|
├ /_app 0 B 91.9 kB
|
|
57
|
-
├ ● /[...slug] 2 kB
|
|
58
|
-
├ ● /[slug]/p 34 kB
|
|
57
|
+
├ ● /[...slug] 2.01 kB 131 kB
|
|
58
|
+
├ ● /[slug]/p 34.1 kB 153 kB
|
|
59
59
|
├ ├ css/bf1560439df2c1a1.css 5.66 kB
|
|
60
60
|
├ ├ css/e3ff5d95518a5c79.css 6.01 kB
|
|
61
61
|
├ └ css/d92839440872e246.css 15.6 kB
|
|
62
|
-
├ ○ /404 1.
|
|
63
|
-
├ ● /500 1.
|
|
64
|
-
├ ● /account
|
|
62
|
+
├ ○ /404 1.48 kB 120 kB
|
|
63
|
+
├ ● /500 1.48 kB 120 kB
|
|
64
|
+
├ ● /account 714 B 120 kB
|
|
65
65
|
├ λ /api/graphql 0 B 91.9 kB
|
|
66
66
|
├ λ /api/health/live 0 B 91.9 kB
|
|
67
67
|
├ λ /api/health/ready 0 B 91.9 kB
|
|
68
68
|
├ λ /api/preview 0 B 91.9 kB
|
|
69
|
-
├ ● /checkout
|
|
70
|
-
├ ● /login 1.
|
|
71
|
-
└ ● /s 2.
|
|
69
|
+
├ ● /checkout 695 B 120 kB
|
|
70
|
+
├ ● /login 1.59 kB 121 kB
|
|
71
|
+
└ ● /s 2.75 kB 131 kB
|
|
72
72
|
+ First Load JS shared by all 95 kB
|
|
73
73
|
├ chunks/framework-12a146e94cfcf7c4.js 45.4 kB
|
|
74
74
|
├ chunks/main-209ac4974b020af1.js 33.1 kB
|
|
75
|
-
├ chunks/pages/_app-
|
|
76
|
-
├ chunks/webpack-
|
|
75
|
+
├ chunks/pages/_app-9d35d5919aef5334.js 9.91 kB
|
|
76
|
+
├ chunks/webpack-bf502499da135235.js 3.57 kB
|
|
77
77
|
└ css/ee0556daedda6306.css 3.07 kB
|
|
78
78
|
|
|
79
79
|
λ (Server) server-side renders at runtime (uses getInitialProps or getServerSideProps)
|
|
80
80
|
○ (Static) automatically rendered as static HTML (uses no initial props)
|
|
81
81
|
● (SSG) automatically generated as static HTML + JSON (uses getStaticProps)
|
|
82
82
|
|
|
83
|
-
Done in
|
|
83
|
+
Done in 70.70s.
|
package/.turbo/turbo-lint.log
CHANGED
package/.turbo/turbo-test.log
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
yarn run v1.22.22
|
|
2
2
|
$ jest
|
|
3
|
-
PASS test/
|
|
4
|
-
PASS test/
|
|
5
|
-
PASS test/server/index.test.ts (41.
|
|
3
|
+
PASS test/utils/multipleTemplates.test.ts (36.538 s)
|
|
4
|
+
PASS test/server/cms/index.test.ts (37.31 s)
|
|
5
|
+
PASS test/server/index.test.ts (41.077 s)
|
|
6
6
|
|
|
7
7
|
Test Suites: 3 passed, 3 total
|
|
8
8
|
Tests: 19 passed, 19 total
|
|
9
9
|
Snapshots: 0 total
|
|
10
|
-
Time: 42.
|
|
10
|
+
Time: 42.06 s
|
|
11
11
|
Ran all test suites.
|
|
12
|
-
Done in
|
|
12
|
+
Done in 43.45s.
|
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,18 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# 3.9.0 (2025-01-22)
|
|
7
|
+
|
|
8
|
+
### Features
|
|
9
|
+
|
|
10
|
+
- Adds Plugins feature ([#2563](https://github.com/vtex/faststore/issues/2563)) ([83c1bf9](https://github.com/vtex/faststore/commit/83c1bf904f744842060e0dfdb7449406800df157))
|
|
11
|
+
|
|
12
|
+
# [3.8.0](https://github.com/vtex/faststore/compare/v3.7.0...v3.8.0) (2025-01-15)
|
|
13
|
+
|
|
14
|
+
### Features
|
|
15
|
+
|
|
16
|
+
- load out of viewport sections after TTI ([#2604](https://github.com/vtex/faststore/issues/2604)) ([98f8109](https://github.com/vtex/faststore/commit/98f8109d406150edf8172a4b8f8e3d4f39f28362))
|
|
17
|
+
|
|
6
18
|
# [3.7.0](https://github.com/vtex/faststore/compare/v3.6.0...v3.7.0) (2025-01-15)
|
|
7
19
|
|
|
8
20
|
### Features
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@faststore/core",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.9.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"repository": "vtex/faststore",
|
|
6
6
|
"browserslist": "supports es6-module and not dead",
|
|
@@ -43,12 +43,12 @@
|
|
|
43
43
|
"@envelop/graphql-jit": "^8.0.3",
|
|
44
44
|
"@envelop/parser-cache": "^6.0.2",
|
|
45
45
|
"@envelop/validation-cache": "^6.0.2",
|
|
46
|
-
"@faststore/api": "^3.
|
|
47
|
-
"@faststore/components": "^3.
|
|
48
|
-
"@faststore/graphql-utils": "^3.
|
|
49
|
-
"@faststore/lighthouse": "^3.
|
|
50
|
-
"@faststore/sdk": "^3.
|
|
51
|
-
"@faststore/ui": "^3.
|
|
46
|
+
"@faststore/api": "^3.9.0",
|
|
47
|
+
"@faststore/components": "^3.9.0",
|
|
48
|
+
"@faststore/graphql-utils": "^3.9.0",
|
|
49
|
+
"@faststore/lighthouse": "^3.9.0",
|
|
50
|
+
"@faststore/sdk": "^3.9.0",
|
|
51
|
+
"@faststore/ui": "^3.9.0",
|
|
52
52
|
"@graphql-codegen/cli": "5.0.2",
|
|
53
53
|
"@graphql-codegen/client-preset": "4.2.6",
|
|
54
54
|
"@graphql-codegen/typescript": "4.0.7",
|
|
@@ -87,7 +87,7 @@
|
|
|
87
87
|
"devDependencies": {
|
|
88
88
|
"@cypress/code-coverage": "^3.12.1",
|
|
89
89
|
"@envelop/testing": "^6.0.0",
|
|
90
|
-
"@faststore/eslint-config": "^3.
|
|
90
|
+
"@faststore/eslint-config": "^3.9.0",
|
|
91
91
|
"@lhci/cli": "^0.9.0",
|
|
92
92
|
"@testing-library/cypress": "^10.0.1",
|
|
93
93
|
"@types/cypress": "^1.1.3",
|
|
@@ -128,5 +128,5 @@
|
|
|
128
128
|
"node": "18.19.0",
|
|
129
129
|
"yarn": "1.19.1"
|
|
130
130
|
},
|
|
131
|
-
"gitHead": "
|
|
131
|
+
"gitHead": "50345eff012999c1e2100a5fcfeccd0732da131e"
|
|
132
132
|
}
|
|
@@ -6,8 +6,10 @@ import {
|
|
|
6
6
|
useMemo,
|
|
7
7
|
} from 'react'
|
|
8
8
|
|
|
9
|
+
import { useUI } from '@faststore/ui'
|
|
9
10
|
import { Section } from '@vtex/client-cms'
|
|
10
11
|
import dynamic from 'next/dynamic'
|
|
12
|
+
import useTTI from 'src/sdk/performance/useTTI'
|
|
11
13
|
import SectionBoundary from './SectionBoundary'
|
|
12
14
|
import ViewportObserver from './ViewportObserver'
|
|
13
15
|
import COMPONENTS from './global/Components'
|
|
@@ -16,6 +18,7 @@ interface Props {
|
|
|
16
18
|
components?: Record<string, ComponentType<any>>
|
|
17
19
|
globalSections?: Array<{ name: string; data: any }>
|
|
18
20
|
sections?: Array<{ name: string; data: any }>
|
|
21
|
+
isInteractive?: boolean
|
|
19
22
|
}
|
|
20
23
|
|
|
21
24
|
const SECTIONS_OUT_OF_VIEWPORT = ['CartSidebar', 'RegionModal']
|
|
@@ -49,20 +52,47 @@ const useDividedSections = (sections: Section[]) => {
|
|
|
49
52
|
export const LazyLoadingSection = ({
|
|
50
53
|
sectionName,
|
|
51
54
|
children,
|
|
55
|
+
debug = false,
|
|
56
|
+
isInteractive = false,
|
|
52
57
|
}: {
|
|
53
58
|
sectionName: string
|
|
54
59
|
children: ReactNode
|
|
60
|
+
debug?: boolean
|
|
61
|
+
isInteractive?: boolean
|
|
55
62
|
}) => {
|
|
63
|
+
const { cart: displayCart, modal: displayModal } = useUI()
|
|
56
64
|
if (SECTIONS_OUT_OF_VIEWPORT.includes(sectionName)) {
|
|
57
|
-
|
|
65
|
+
const shouldLoad =
|
|
66
|
+
isInteractive ||
|
|
67
|
+
(sectionName === 'CartSidebar' && displayCart) ||
|
|
68
|
+
(sectionName === 'RegionModal' && displayModal)
|
|
69
|
+
|
|
70
|
+
if (debug) {
|
|
71
|
+
console.log(
|
|
72
|
+
`section SECTIONS_OUT_OF_VIEWPORT '${sectionName}' shouldLoad:`,
|
|
73
|
+
shouldLoad
|
|
74
|
+
)
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
return shouldLoad ? <>{children}</> : null
|
|
58
78
|
}
|
|
59
79
|
|
|
60
80
|
return (
|
|
61
|
-
<ViewportObserver
|
|
81
|
+
<ViewportObserver
|
|
82
|
+
sectionName={sectionName}
|
|
83
|
+
debug={debug}
|
|
84
|
+
isInteractive={isInteractive}
|
|
85
|
+
>
|
|
86
|
+
{children}
|
|
87
|
+
</ViewportObserver>
|
|
62
88
|
)
|
|
63
89
|
}
|
|
64
90
|
|
|
65
|
-
const RenderSectionsBase = ({
|
|
91
|
+
const RenderSectionsBase = ({
|
|
92
|
+
sections = [],
|
|
93
|
+
components,
|
|
94
|
+
isInteractive,
|
|
95
|
+
}: Props) => {
|
|
66
96
|
return (
|
|
67
97
|
<>
|
|
68
98
|
{sections.map(({ name, data = {} }, index) => {
|
|
@@ -79,7 +109,10 @@ const RenderSectionsBase = ({ sections = [], components }: Props) => {
|
|
|
79
109
|
|
|
80
110
|
return (
|
|
81
111
|
<SectionBoundary key={`cms-section-${name}-${index}`} name={name}>
|
|
82
|
-
<LazyLoadingSection
|
|
112
|
+
<LazyLoadingSection
|
|
113
|
+
sectionName={name}
|
|
114
|
+
isInteractive={isInteractive}
|
|
115
|
+
>
|
|
83
116
|
<Component {...data} />
|
|
84
117
|
</LazyLoadingSection>
|
|
85
118
|
</SectionBoundary>
|
|
@@ -99,21 +132,35 @@ function RenderSections({
|
|
|
99
132
|
globalSections ?? sections
|
|
100
133
|
)
|
|
101
134
|
|
|
135
|
+
const { isInteractive } = useTTI()
|
|
136
|
+
|
|
102
137
|
return (
|
|
103
138
|
<>
|
|
104
139
|
{firstSections && (
|
|
105
|
-
<RenderSectionsBase
|
|
140
|
+
<RenderSectionsBase
|
|
141
|
+
sections={firstSections}
|
|
142
|
+
components={components}
|
|
143
|
+
isInteractive={isInteractive}
|
|
144
|
+
/>
|
|
106
145
|
)}
|
|
107
146
|
{sections && sections.length > 0 && (
|
|
108
|
-
<RenderSectionsBase
|
|
147
|
+
<RenderSectionsBase
|
|
148
|
+
sections={sections}
|
|
149
|
+
components={components}
|
|
150
|
+
isInteractive={isInteractive}
|
|
151
|
+
/>
|
|
109
152
|
)}
|
|
110
153
|
{children}
|
|
111
|
-
<LazyLoadingSection sectionName="Toast">
|
|
154
|
+
<LazyLoadingSection sectionName="Toast" isInteractive={isInteractive}>
|
|
112
155
|
<Toast />
|
|
113
156
|
</LazyLoadingSection>
|
|
114
157
|
|
|
115
158
|
{lastSections && (
|
|
116
|
-
<RenderSectionsBase
|
|
159
|
+
<RenderSectionsBase
|
|
160
|
+
sections={lastSections}
|
|
161
|
+
components={components}
|
|
162
|
+
isInteractive={isInteractive}
|
|
163
|
+
/>
|
|
117
164
|
)}
|
|
118
165
|
</>
|
|
119
166
|
)
|
|
@@ -14,6 +14,7 @@ type ViewportObserverProps = {
|
|
|
14
14
|
* Debug/test purposes: enables visual debugging to identify the visibility of the section.
|
|
15
15
|
*/
|
|
16
16
|
debug?: boolean
|
|
17
|
+
isInteractive?: boolean
|
|
17
18
|
} & IntersectionObserverInit
|
|
18
19
|
|
|
19
20
|
function ViewportObserver({
|
|
@@ -23,6 +24,7 @@ function ViewportObserver({
|
|
|
23
24
|
rootMargin,
|
|
24
25
|
children,
|
|
25
26
|
debug = false,
|
|
27
|
+
isInteractive = false,
|
|
26
28
|
}: PropsWithChildren<ViewportObserverProps>) {
|
|
27
29
|
const [isVisible, setVisible] = useState(false)
|
|
28
30
|
const ref = useRef<HTMLDivElement | null>(null)
|
|
@@ -80,7 +82,7 @@ function ViewportObserver({
|
|
|
80
82
|
></div>
|
|
81
83
|
)}
|
|
82
84
|
|
|
83
|
-
{isVisible && children}
|
|
85
|
+
{(isVisible || isInteractive) && children}
|
|
84
86
|
</>
|
|
85
87
|
)
|
|
86
88
|
}
|
|
@@ -6,6 +6,7 @@ import { OverriddenDefaultNavbar as Navbar } from 'src/components/sections/Navba
|
|
|
6
6
|
import { OverriddenDefaultRegionBar as RegionBar } from 'src/components/sections/RegionBar/OverriddenDefaultRegionBar'
|
|
7
7
|
|
|
8
8
|
import CUSTOM_COMPONENTS from 'src/customizations/src/components'
|
|
9
|
+
import PLUGINS_COMPONENTS from 'src/plugins'
|
|
9
10
|
|
|
10
11
|
const CartSidebar = dynamic(
|
|
11
12
|
() =>
|
|
@@ -34,6 +35,7 @@ const COMPONENTS: Record<string, ComponentType<any>> = {
|
|
|
34
35
|
CartSidebar, // out of viewport
|
|
35
36
|
RegionModal, // out of viewport
|
|
36
37
|
Footer, // out of viewport
|
|
38
|
+
...PLUGINS_COMPONENTS,
|
|
37
39
|
...CUSTOM_COMPONENTS,
|
|
38
40
|
}
|
|
39
41
|
|
|
@@ -6,6 +6,7 @@ import Incentives from 'src/components/sections/Incentives'
|
|
|
6
6
|
import { default as GLOBAL_COMPONENTS } from '../global/Components'
|
|
7
7
|
|
|
8
8
|
import CUSTOM_COMPONENTS from 'src/customizations/src/components'
|
|
9
|
+
import PLUGINS_COMPONENTS from 'src/plugins'
|
|
9
10
|
|
|
10
11
|
const BannerText = dynamic(
|
|
11
12
|
() =>
|
|
@@ -48,6 +49,7 @@ const COMPONENTS: Record<string, ComponentType<any>> = {
|
|
|
48
49
|
Newsletter,
|
|
49
50
|
ProductShelf,
|
|
50
51
|
ProductTiles,
|
|
52
|
+
...PLUGINS_COMPONENTS,
|
|
51
53
|
...CUSTOM_COMPONENTS,
|
|
52
54
|
}
|
|
53
55
|
|
|
@@ -5,6 +5,7 @@ import { OverriddenDefaultBreadcrumb as Breadcrumb } from 'src/components/sectio
|
|
|
5
5
|
import { OverriddenDefaultHero as Hero } from 'src/components/sections/Hero/OverriddenDefaultHero'
|
|
6
6
|
import { OverriddenDefaultProductGallery as ProductGallery } from 'src/components/sections/ProductGallery/OverriddenDefaultProductGallery'
|
|
7
7
|
import CUSTOM_COMPONENTS from 'src/customizations/src/components'
|
|
8
|
+
import PLUGINS_COMPONENTS from 'src/plugins'
|
|
8
9
|
import { default as GLOBAL_COMPONENTS } from '../global/Components'
|
|
9
10
|
|
|
10
11
|
const BannerText = dynamic(
|
|
@@ -53,6 +54,7 @@ const COMPONENTS: Record<string, ComponentType<any>> = {
|
|
|
53
54
|
Newsletter,
|
|
54
55
|
ProductShelf,
|
|
55
56
|
ProductTiles,
|
|
57
|
+
...PLUGINS_COMPONENTS,
|
|
56
58
|
...CUSTOM_COMPONENTS,
|
|
57
59
|
}
|
|
58
60
|
|
|
@@ -5,6 +5,7 @@ import { OverriddenDefaultBreadcrumb as Breadcrumb } from 'src/components/sectio
|
|
|
5
5
|
import { OverriddenDefaultHero as Hero } from 'src/components/sections/Hero/OverriddenDefaultHero'
|
|
6
6
|
import { OverriddenDefaultProductGallery as ProductGallery } from 'src/components/sections/ProductGallery/OverriddenDefaultProductGallery'
|
|
7
7
|
import CUSTOM_COMPONENTS from 'src/customizations/src/components'
|
|
8
|
+
import PLUGINS_COMPONENTS from 'src/plugins'
|
|
8
9
|
import { default as GLOBAL_COMPONENTS } from '../global/Components'
|
|
9
10
|
|
|
10
11
|
const BannerText = dynamic(
|
|
@@ -62,6 +63,7 @@ const COMPONENTS: Record<string, ComponentType<any>> = {
|
|
|
62
63
|
Newsletter,
|
|
63
64
|
ProductShelf,
|
|
64
65
|
ProductTiles,
|
|
66
|
+
...PLUGINS_COMPONENTS,
|
|
65
67
|
...CUSTOM_COMPONENTS,
|
|
66
68
|
}
|
|
67
69
|
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { override } from 'src/customizations/src/components/overrides/Alert'
|
|
2
|
+
import { override as overridePlugin } from 'src/plugins/overrides/Alert'
|
|
2
3
|
import { getOverriddenSection } from 'src/sdk/overrides/getOverriddenSection'
|
|
3
4
|
import Alert from '.'
|
|
4
5
|
|
|
@@ -10,6 +11,7 @@ import type { SectionOverrideDefinitionV1 } from 'src/typings/overridesDefinitio
|
|
|
10
11
|
* This allows users to override the default Alert section present in the Headless CMS
|
|
11
12
|
*/
|
|
12
13
|
export const OverriddenDefaultAlert = getOverriddenSection({
|
|
14
|
+
...(overridePlugin as SectionOverrideDefinitionV1<'Alert'>),
|
|
13
15
|
...(override as SectionOverrideDefinitionV1<'Alert'>),
|
|
14
16
|
Section: Alert,
|
|
15
17
|
})
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { override } from 'src/customizations/src/components/overrides/BannerText'
|
|
2
|
+
import { override as overridePlugin } from 'src/plugins/overrides/BannerText'
|
|
2
3
|
import { getOverriddenSection } from 'src/sdk/overrides/getOverriddenSection'
|
|
3
4
|
import BannerText from '.'
|
|
4
5
|
|
|
@@ -10,6 +11,7 @@ import type { SectionOverrideDefinitionV1 } from 'src/typings/overridesDefinitio
|
|
|
10
11
|
* This allows users to override the default BannerText section present in the Headless CMS
|
|
11
12
|
*/
|
|
12
13
|
export const OverriddenDefaultBannerText = getOverriddenSection({
|
|
14
|
+
...(overridePlugin as SectionOverrideDefinitionV1<'BannerText'>),
|
|
13
15
|
...(override as SectionOverrideDefinitionV1<'BannerText'>),
|
|
14
16
|
Section: BannerText,
|
|
15
17
|
})
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { override } from 'src/customizations/src/components/overrides/Breadcrumb'
|
|
2
|
+
import { override as overridePlugin } from 'src/plugins/overrides/Breadcrumb'
|
|
2
3
|
import { getOverriddenSection } from 'src/sdk/overrides/getOverriddenSection'
|
|
3
4
|
import Breadcrumb from '.'
|
|
4
5
|
|
|
@@ -10,6 +11,7 @@ import type { SectionOverrideDefinitionV1 } from 'src/typings/overridesDefinitio
|
|
|
10
11
|
* This allows users to override the default Breadcrumb section present in the Headless CMS
|
|
11
12
|
*/
|
|
12
13
|
export const OverriddenDefaultBreadcrumb = getOverriddenSection({
|
|
14
|
+
...(overridePlugin as SectionOverrideDefinitionV1<'Breadcrumb'>),
|
|
13
15
|
...(override as SectionOverrideDefinitionV1<'Breadcrumb'>),
|
|
14
16
|
Section: Breadcrumb,
|
|
15
17
|
})
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { override } from 'src/customizations/src/components/overrides/CrossSellingShelf'
|
|
2
|
+
import { override as overridePlugin } from 'src/plugins/overrides/CrossSellingShelf'
|
|
2
3
|
import { getOverriddenSection } from 'src/sdk/overrides/getOverriddenSection'
|
|
3
4
|
import type { SectionOverrideDefinitionV1 } from 'src/typings/overridesDefinition'
|
|
4
5
|
import CrossSellingShelf from '.'
|
|
@@ -9,6 +10,7 @@ import CrossSellingShelf from '.'
|
|
|
9
10
|
* This allows users to override the default CrossSellingShelf section present in the Headless CMS
|
|
10
11
|
*/
|
|
11
12
|
export const OverriddenDefaultCrossSellingShelf = getOverriddenSection({
|
|
13
|
+
...(overridePlugin as SectionOverrideDefinitionV1<'CrossSellingShelf'>),
|
|
12
14
|
...(override as SectionOverrideDefinitionV1<'CrossSellingShelf'>),
|
|
13
15
|
Section: CrossSellingShelf,
|
|
14
16
|
})
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { override } from 'src/customizations/src/components/overrides/EmptyState'
|
|
2
|
+
import { override as overridePlugin } from 'src/plugins/overrides/EmptyState'
|
|
2
3
|
import { getOverriddenSection } from 'src/sdk/overrides/getOverriddenSection'
|
|
3
4
|
|
|
4
5
|
import type { SectionOverrideDefinitionV1 } from 'src/typings/overridesDefinition'
|
|
@@ -10,6 +11,7 @@ import EmptyState from './EmptyState'
|
|
|
10
11
|
* This allows users to override the default EmptyState section present in the Headless CMS
|
|
11
12
|
*/
|
|
12
13
|
export const OverriddenDefaultEmptyState = getOverriddenSection({
|
|
14
|
+
...(overridePlugin as SectionOverrideDefinitionV1<'EmptyState'>),
|
|
13
15
|
...(override as SectionOverrideDefinitionV1<'EmptyState'>),
|
|
14
16
|
Section: EmptyState,
|
|
15
17
|
})
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { override } from 'src/customizations/src/components/overrides/Hero'
|
|
2
|
+
import { override as overridePlugin } from 'src/plugins/overrides/Hero'
|
|
2
3
|
import { getOverriddenSection } from 'src/sdk/overrides/getOverriddenSection'
|
|
3
4
|
import Hero from '.'
|
|
4
5
|
|
|
@@ -10,6 +11,7 @@ import type { SectionOverrideDefinitionV1 } from 'src/typings/overridesDefinitio
|
|
|
10
11
|
* This allows users to override the default Hero section present in the Headless CMS
|
|
11
12
|
*/
|
|
12
13
|
export const OverriddenDefaultHero = getOverriddenSection({
|
|
14
|
+
...(overridePlugin as SectionOverrideDefinitionV1<'Hero'>),
|
|
13
15
|
...(override as SectionOverrideDefinitionV1<'Hero'>),
|
|
14
16
|
Section: Hero,
|
|
15
17
|
})
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { override } from 'src/customizations/src/components/overrides/Navbar'
|
|
2
|
+
import { override as overridePlugin } from 'src/plugins/overrides/Navbar'
|
|
2
3
|
import { getOverriddenSection } from 'src/sdk/overrides/getOverriddenSection'
|
|
3
4
|
import type { SectionOverrideDefinitionV1 } from 'src/typings/overridesDefinition'
|
|
4
5
|
import Navbar from './Navbar'
|
|
@@ -9,6 +10,7 @@ import Navbar from './Navbar'
|
|
|
9
10
|
* This allows users to override the default Navbar section present in the Headless CMS
|
|
10
11
|
*/
|
|
11
12
|
export const OverriddenDefaultNavbar = getOverriddenSection({
|
|
13
|
+
...(overridePlugin as SectionOverrideDefinitionV1<'Navbar'>),
|
|
12
14
|
...(override as SectionOverrideDefinitionV1<'Navbar'>),
|
|
13
15
|
Section: Navbar,
|
|
14
16
|
})
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { override } from 'src/customizations/src/components/overrides/Newsletter'
|
|
2
|
+
import { override as overridePlugin } from 'src/plugins/overrides/Newsletter'
|
|
2
3
|
import { getOverriddenSection } from 'src/sdk/overrides/getOverriddenSection'
|
|
3
4
|
import type { SectionOverrideDefinitionV1 } from 'src/typings/overridesDefinition'
|
|
4
5
|
import Newsletter from './Newsletter'
|
|
@@ -9,6 +10,7 @@ import Newsletter from './Newsletter'
|
|
|
9
10
|
* This allows users to override the default Newsletter section present in the Headless CMS
|
|
10
11
|
*/
|
|
11
12
|
export const OverriddenDefaultNewsletter = getOverriddenSection({
|
|
13
|
+
...(overridePlugin as SectionOverrideDefinitionV1<'Newsletter'>),
|
|
12
14
|
...(override as SectionOverrideDefinitionV1<'Newsletter'>),
|
|
13
15
|
Section: Newsletter,
|
|
14
16
|
})
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { override } from 'src/customizations/src/components/overrides/ProductDetails'
|
|
2
|
+
import { override as overridePlugin } from 'src/plugins/overrides/ProductDetails'
|
|
2
3
|
import { getOverriddenSection } from 'src/sdk/overrides/getOverriddenSection'
|
|
3
4
|
import ProductDetails from './ProductDetails'
|
|
4
5
|
|
|
@@ -10,6 +11,7 @@ import type { SectionOverrideDefinitionV1 } from 'src/typings/overridesDefinitio
|
|
|
10
11
|
* This allows users to override the default ProductDetails section present in the Headless CMS
|
|
11
12
|
*/
|
|
12
13
|
export const OverriddenDefaultProductDetails = getOverriddenSection({
|
|
14
|
+
...(overridePlugin as SectionOverrideDefinitionV1<'ProductDetails'>),
|
|
13
15
|
...(override as SectionOverrideDefinitionV1<'ProductDetails'>),
|
|
14
16
|
Section: ProductDetails,
|
|
15
17
|
})
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { override } from 'src/customizations/src/components/overrides/ProductGallery'
|
|
2
|
+
import { override as overridePlugin } from 'src/plugins/overrides/ProductGallery'
|
|
2
3
|
import { getOverriddenSection } from 'src/sdk/overrides/getOverriddenSection'
|
|
3
4
|
import type { SectionOverrideDefinitionV1 } from 'src/typings/overridesDefinition'
|
|
4
5
|
import ProductGallery from '.'
|
|
@@ -9,6 +10,7 @@ import ProductGallery from '.'
|
|
|
9
10
|
* This allows users to override the default ProductGallery section present in the Headless CMS
|
|
10
11
|
*/
|
|
11
12
|
export const OverriddenDefaultProductGallery = getOverriddenSection({
|
|
13
|
+
...(overridePlugin as SectionOverrideDefinitionV1<'ProductGallery'>),
|
|
12
14
|
...(override as SectionOverrideDefinitionV1<'ProductGallery'>),
|
|
13
15
|
Section: ProductGallery,
|
|
14
16
|
})
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { override } from 'src/customizations/src/components/overrides/ProductShelf'
|
|
2
|
+
import { override as overridePlugin } from 'src/plugins/overrides/ProductShelf'
|
|
2
3
|
import { getOverriddenSection } from 'src/sdk/overrides/getOverriddenSection'
|
|
3
4
|
import ProductShelf from '.'
|
|
4
5
|
|
|
@@ -10,6 +11,7 @@ import type { SectionOverrideDefinitionV1 } from 'src/typings/overridesDefinitio
|
|
|
10
11
|
* This allows users to override the default ProductShelf section present in the Headless CMS
|
|
11
12
|
*/
|
|
12
13
|
export const OverriddenDefaultProductShelf = getOverriddenSection({
|
|
14
|
+
...(overridePlugin as SectionOverrideDefinitionV1<'ProductShelf'>),
|
|
13
15
|
...(override as SectionOverrideDefinitionV1<'ProductShelf'>),
|
|
14
16
|
Section: ProductShelf,
|
|
15
17
|
})
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { override } from 'src/customizations/src/components/overrides/RegionBar'
|
|
2
|
+
import { override as overridePlugin } from 'src/plugins/overrides/RegionBar'
|
|
2
3
|
import { getOverriddenSection } from 'src/sdk/overrides/getOverriddenSection'
|
|
3
4
|
import type { SectionOverrideDefinitionV1 } from 'src/typings/overridesDefinition'
|
|
4
5
|
import RegionBar from '.'
|
|
@@ -9,6 +10,7 @@ import RegionBar from '.'
|
|
|
9
10
|
* This allows users to override the default RegionBar section present in the Headless CMS
|
|
10
11
|
*/
|
|
11
12
|
export const OverriddenDefaultRegionBar = getOverriddenSection({
|
|
13
|
+
...(overridePlugin as SectionOverrideDefinitionV1<'RegionBar'>),
|
|
12
14
|
...(override as SectionOverrideDefinitionV1<'RegionBar'>),
|
|
13
15
|
Section: RegionBar,
|
|
14
16
|
})
|
|
@@ -11,6 +11,7 @@ import Incentives from 'src/components/sections/Incentives'
|
|
|
11
11
|
import { OverriddenDefaultNewsletter as Newsletter } from 'src/components/sections/Newsletter/OverriddenDefaultNewsletter'
|
|
12
12
|
import { OverriddenDefaultProductShelf as ProductShelf } from 'src/components/sections/ProductShelf/OverriddenDefaultProductShelf'
|
|
13
13
|
import ProductTiles from 'src/components/sections/ProductTiles'
|
|
14
|
+
import PLUGINS_COMPONENTS from 'src/plugins'
|
|
14
15
|
import CUSTOM_COMPONENTS from 'src/customizations/src/components'
|
|
15
16
|
import { default as GLOBAL_COMPONENTS } from 'src/components/cms/global/Components'
|
|
16
17
|
import MissingContentError from 'src/sdk/error/MissingContentError/MissingContentError'
|
|
@@ -31,6 +32,7 @@ const COMPONENTS: Record<string, ComponentType<any>> = {
|
|
|
31
32
|
Newsletter,
|
|
32
33
|
ProductShelf,
|
|
33
34
|
ProductTiles,
|
|
35
|
+
...PLUGINS_COMPONENTS,
|
|
34
36
|
...CUSTOM_COMPONENTS,
|
|
35
37
|
}
|
|
36
38
|
|
|
@@ -1,9 +1,15 @@
|
|
|
1
1
|
import WebFontsOverrides from 'src/customizations/src/components/overrides/WebFonts'
|
|
2
2
|
import { default as CoreWebFonts } from 'src/fonts/WebFonts'
|
|
3
3
|
import ThirdPartyScriptsOverrides from 'src/customizations/src/components/overrides/ThirdPartyScripts'
|
|
4
|
+
import ThirdPartyScriptsPluginsOverrides from 'src/plugins/overrides/ThirdPartyScripts'
|
|
5
|
+
import WebFontsOverridesPlugins from 'src/plugins/overrides/WebFonts'
|
|
4
6
|
|
|
5
7
|
const Components = {
|
|
6
8
|
WebFonts: CoreWebFonts,
|
|
9
|
+
|
|
10
|
+
...ThirdPartyScriptsPluginsOverrides.components,
|
|
11
|
+
...WebFontsOverridesPlugins.components,
|
|
12
|
+
|
|
7
13
|
...WebFontsOverrides.components,
|
|
8
14
|
...ThirdPartyScriptsOverrides.components,
|
|
9
15
|
}
|
package/src/pages/404.tsx
CHANGED
|
@@ -10,6 +10,7 @@ import {
|
|
|
10
10
|
import { default as GLOBAL_COMPONENTS } from 'src/components/cms/global/Components'
|
|
11
11
|
import RenderSections from 'src/components/cms/RenderSections'
|
|
12
12
|
import { OverriddenDefaultEmptyState as EmptyState } from 'src/components/sections/EmptyState/OverriddenDefaultEmptyState'
|
|
13
|
+
import PLUGINS_COMPONENTS from 'src/plugins'
|
|
13
14
|
import CUSTOM_COMPONENTS from 'src/customizations/src/components'
|
|
14
15
|
import { PageContentType, getPage } from 'src/server/cms'
|
|
15
16
|
|
|
@@ -17,6 +18,7 @@ import { PageContentType, getPage } from 'src/server/cms'
|
|
|
17
18
|
const COMPONENTS: Record<string, ComponentType<any>> = {
|
|
18
19
|
...GLOBAL_COMPONENTS,
|
|
19
20
|
EmptyState,
|
|
21
|
+
...PLUGINS_COMPONENTS,
|
|
20
22
|
...CUSTOM_COMPONENTS,
|
|
21
23
|
}
|
|
22
24
|
|
package/src/pages/500.tsx
CHANGED
|
@@ -10,6 +10,7 @@ import {
|
|
|
10
10
|
import { default as GLOBAL_COMPONENTS } from 'src/components/cms/global/Components'
|
|
11
11
|
import RenderSections from 'src/components/cms/RenderSections'
|
|
12
12
|
import { OverriddenDefaultEmptyState as EmptyState } from 'src/components/sections/EmptyState/OverriddenDefaultEmptyState'
|
|
13
|
+
import PLUGINS_COMPONENTS from 'src/plugins'
|
|
13
14
|
import CUSTOM_COMPONENTS from 'src/customizations/src/components'
|
|
14
15
|
import { PageContentType, getPage } from 'src/server/cms'
|
|
15
16
|
|
|
@@ -17,6 +18,7 @@ import { PageContentType, getPage } from 'src/server/cms'
|
|
|
17
18
|
const COMPONENTS: Record<string, ComponentType<any>> = {
|
|
18
19
|
...GLOBAL_COMPONENTS,
|
|
19
20
|
EmptyState,
|
|
21
|
+
...PLUGINS_COMPONENTS,
|
|
20
22
|
...CUSTOM_COMPONENTS,
|
|
21
23
|
}
|
|
22
24
|
|
package/src/pages/[slug]/p.tsx
CHANGED
|
@@ -21,6 +21,7 @@ import { OverriddenDefaultNewsletter as Newsletter } from 'src/components/sectio
|
|
|
21
21
|
import { OverriddenDefaultProductDetails as ProductDetails } from 'src/components/sections/ProductDetails/OverriddenDefaultProductDetails'
|
|
22
22
|
import { OverriddenDefaultProductShelf as ProductShelf } from 'src/components/sections/ProductShelf/OverriddenDefaultProductShelf'
|
|
23
23
|
import ProductTiles from 'src/components/sections/ProductTiles'
|
|
24
|
+
import PLUGINS_COMPONENTS from 'src/plugins'
|
|
24
25
|
import CUSTOM_COMPONENTS from 'src/customizations/src/components'
|
|
25
26
|
import { useSession } from 'src/sdk/session'
|
|
26
27
|
import { execute } from 'src/server'
|
|
@@ -49,6 +50,7 @@ const COMPONENTS: Record<string, ComponentType<any>> = {
|
|
|
49
50
|
ProductShelf,
|
|
50
51
|
ProductTiles,
|
|
51
52
|
CrossSellingShelf,
|
|
53
|
+
...PLUGINS_COMPONENTS,
|
|
52
54
|
...CUSTOM_COMPONENTS,
|
|
53
55
|
}
|
|
54
56
|
|
package/src/pages/_app.tsx
CHANGED
package/src/pages/login.tsx
CHANGED
|
@@ -11,6 +11,7 @@ import {
|
|
|
11
11
|
} from 'src/components/cms/GlobalSections'
|
|
12
12
|
import RenderSections from 'src/components/cms/RenderSections'
|
|
13
13
|
import { OverriddenDefaultEmptyState as EmptyState } from 'src/components/sections/EmptyState/OverriddenDefaultEmptyState'
|
|
14
|
+
import PLUGINS_COMPONENTS from 'src/plugins'
|
|
14
15
|
import CUSTOM_COMPONENTS from 'src/customizations/src/components'
|
|
15
16
|
import { PageContentType, getPage } from 'src/server/cms'
|
|
16
17
|
import storeConfig from '../../discovery.config'
|
|
@@ -19,6 +20,7 @@ import storeConfig from '../../discovery.config'
|
|
|
19
20
|
const COMPONENTS: Record<string, ComponentType<any>> = {
|
|
20
21
|
...GLOBAL_COMPONENTS,
|
|
21
22
|
EmptyState,
|
|
23
|
+
...PLUGINS_COMPONENTS,
|
|
22
24
|
...CUSTOM_COMPONENTS,
|
|
23
25
|
}
|
|
24
26
|
|