@pixelated-tech/components 3.7.1 → 3.7.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/dist/components/admin/site-health/site-health-on-site-seo.integration.js +15 -0
- package/dist/components/general/callout.js +4 -3
- package/dist/components/general/intersection-observer.js +117 -0
- package/dist/components/general/microinteractions.js +39 -50
- package/dist/components/general/schema-services.js +17 -4
- package/dist/components/general/schema-website.js +100 -7
- package/dist/components/general/splitscroll.css +125 -0
- package/dist/components/general/splitscroll.js +89 -0
- package/dist/components/sitebuilder/config/ConfigBuilder.js +142 -25
- package/dist/components/sitebuilder/config/services-form.json +51 -0
- package/dist/components/sitebuilder/config/siteinfo-form.json +68 -0
- package/dist/index.js +2 -0
- package/dist/scripts/generate-site-images.js +7 -4
- package/dist/scripts/setup-remotes.sh +69 -0
- package/dist/scripts/validate-exports.cjs +280 -0
- package/dist/types/components/admin/site-health/site-health-on-site-seo.integration.d.ts.map +1 -1
- package/dist/types/components/config/config.types.d.ts +8 -1
- package/dist/types/components/config/config.types.d.ts.map +1 -1
- package/dist/types/components/general/callout.d.ts +3 -2
- package/dist/types/components/general/callout.d.ts.map +1 -1
- package/dist/types/components/general/intersection-observer.d.ts +73 -0
- package/dist/types/components/general/intersection-observer.d.ts.map +1 -0
- package/dist/types/components/general/microinteractions.d.ts +1 -1
- package/dist/types/components/general/microinteractions.d.ts.map +1 -1
- package/dist/types/components/general/schema-services.d.ts +25 -6
- package/dist/types/components/general/schema-services.d.ts.map +1 -1
- package/dist/types/components/general/schema-website.d.ts +60 -5
- package/dist/types/components/general/schema-website.d.ts.map +1 -1
- package/dist/types/components/general/splitscroll.d.ts +51 -0
- package/dist/types/components/general/splitscroll.d.ts.map +1 -0
- package/dist/types/components/sitebuilder/config/ConfigBuilder.d.ts +30 -0
- package/dist/types/components/sitebuilder/config/ConfigBuilder.d.ts.map +1 -1
- package/dist/types/index.d.ts +2 -0
- package/dist/types/scripts/validate-exports.d.cts +2 -0
- package/dist/types/scripts/validate-exports.d.cts.map +1 -0
- package/dist/types/stories/callout/callout.stories.d.ts +7 -0
- package/dist/types/stories/callout/callout.stories.d.ts.map +1 -1
- package/dist/types/stories/general/splitscroll.stories.d.ts +19 -0
- package/dist/types/stories/general/splitscroll.stories.d.ts.map +1 -0
- package/dist/types/stories/lookbook/lookbook.stories.d.ts +19 -0
- package/dist/types/stories/lookbook/lookbook.stories.d.ts.map +1 -0
- package/dist/types/tests/splitscroll.test.d.ts +2 -0
- package/dist/types/tests/splitscroll.test.d.ts.map +1 -0
- package/package.json +5 -5
- package/dist/mocks/browser.js +0 -1
- package/dist/mocks/handlers.js +0 -206
- package/dist/mocks/index.js +0 -1
- package/dist/types/mocks/browser.d.ts +0 -1
- package/dist/types/mocks/browser.d.ts.map +0 -1
- package/dist/types/mocks/handlers.d.ts +0 -2
- package/dist/types/mocks/handlers.d.ts.map +0 -1
- package/dist/types/mocks/index.d.ts +0 -1
- package/dist/types/mocks/index.d.ts.map +0 -1
|
@@ -36,6 +36,21 @@ declare const SiteInfoPropTypes: {
|
|
|
36
36
|
priceRange: PropTypes.Requireable<string>;
|
|
37
37
|
sameAs: PropTypes.Requireable<string[]>;
|
|
38
38
|
keywords: PropTypes.Requireable<string>;
|
|
39
|
+
openingHours: PropTypes.Requireable<string>;
|
|
40
|
+
publisherType: PropTypes.Requireable<string>;
|
|
41
|
+
copyrightYear: PropTypes.Requireable<number>;
|
|
42
|
+
potentialAction: PropTypes.Requireable<PropTypes.InferProps<{
|
|
43
|
+
'@type': PropTypes.Requireable<string>;
|
|
44
|
+
target: PropTypes.Validator<string>;
|
|
45
|
+
'query-input': PropTypes.Requireable<string>;
|
|
46
|
+
queryInput: PropTypes.Requireable<string>;
|
|
47
|
+
}>>;
|
|
48
|
+
services: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
49
|
+
name: PropTypes.Validator<string>;
|
|
50
|
+
description: PropTypes.Validator<string>;
|
|
51
|
+
url: PropTypes.Requireable<string>;
|
|
52
|
+
areaServed: PropTypes.Requireable<string[]>;
|
|
53
|
+
}> | null | undefined)[]>;
|
|
39
54
|
};
|
|
40
55
|
export type SiteInfoType = InferProps<typeof SiteInfoPropTypes>;
|
|
41
56
|
export type ConfigBuilderType = InferProps<typeof ConfigBuilder.propTypes>;
|
|
@@ -70,6 +85,21 @@ export declare namespace ConfigBuilder {
|
|
|
70
85
|
priceRange: PropTypes.Requireable<string>;
|
|
71
86
|
sameAs: PropTypes.Requireable<string[]>;
|
|
72
87
|
keywords: PropTypes.Requireable<string>;
|
|
88
|
+
openingHours: PropTypes.Requireable<string>;
|
|
89
|
+
publisherType: PropTypes.Requireable<string>;
|
|
90
|
+
copyrightYear: PropTypes.Requireable<number>;
|
|
91
|
+
potentialAction: PropTypes.Requireable<PropTypes.InferProps<{
|
|
92
|
+
'@type': PropTypes.Requireable<string>;
|
|
93
|
+
target: PropTypes.Validator<string>;
|
|
94
|
+
'query-input': PropTypes.Requireable<string>;
|
|
95
|
+
queryInput: PropTypes.Requireable<string>;
|
|
96
|
+
}>>;
|
|
97
|
+
services: PropTypes.Requireable<(PropTypes.InferProps<{
|
|
98
|
+
name: PropTypes.Validator<string>;
|
|
99
|
+
description: PropTypes.Validator<string>;
|
|
100
|
+
url: PropTypes.Requireable<string>;
|
|
101
|
+
areaServed: PropTypes.Requireable<string[]>;
|
|
102
|
+
}> | null | undefined)[]>;
|
|
73
103
|
}>>>;
|
|
74
104
|
routes: PropTypes.Validator<NonNullable<PropTypes.InferProps<{
|
|
75
105
|
name: PropTypes.Requireable<string>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ConfigBuilder.d.ts","sourceRoot":"","sources":["../../../../../src/components/sitebuilder/config/ConfigBuilder.tsx"],"names":[],"mappings":"AAGA,OAAO,SAAS,EAAE,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"ConfigBuilder.d.ts","sourceRoot":"","sources":["../../../../../src/components/sitebuilder/config/ConfigBuilder.tsx"],"names":[],"mappings":"AAGA,OAAO,SAAS,EAAE,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAanD,OAAO,qBAAqB,CAAC;AAE7B,QAAA,MAAM,cAAc;;;;;;;CAOnB,CAAC;AACF,MAAM,MAAM,SAAS,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAE1D,QAAA,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA0CtB,CAAC;AACF,MAAM,MAAM,YAAY,GAAG,UAAU,CAAC,OAAO,iBAAiB,CAAC,CAAC;AA+ChE,MAAM,MAAM,iBAAiB,GAAG,UAAU,CAAC,OAAO,aAAa,CAAC,SAAS,CAAC,CAAC;AAC3E,wBAAgB,aAAa,CAAC,KAAK,EAAE,iBAAiB,2CAgwBrD;yBAhwBe,aAAa"}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -27,7 +27,9 @@ export * from "./components/general/hubspot.components";
|
|
|
27
27
|
export * from "./components/general/image";
|
|
28
28
|
export * from "./components/general/instagram.components";
|
|
29
29
|
export * from "./components/general/instagram.functions";
|
|
30
|
+
export * from "./components/general/intersection-observer";
|
|
30
31
|
export * from "./components/general/loading";
|
|
32
|
+
export * from "./components/general/splitscroll";
|
|
31
33
|
export * from "./components/general/manifest";
|
|
32
34
|
export * from "./components/general/markdown";
|
|
33
35
|
export * from "./components/general/menu-accordion";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"validate-exports.d.cts","sourceRoot":"","sources":["../../../src/scripts/validate-exports.cjs"],"names":[],"mappings":""}
|
|
@@ -65,5 +65,12 @@ export namespace CalloutStory {
|
|
|
65
65
|
export { imgShape_1 as imgShape };
|
|
66
66
|
}
|
|
67
67
|
}
|
|
68
|
+
export namespace CalloutWithChildren {
|
|
69
|
+
function render(): import("react/jsx-runtime").JSX.Element;
|
|
70
|
+
}
|
|
71
|
+
export namespace CalloutSplitWithChildren {
|
|
72
|
+
export function render_1(): import("react/jsx-runtime").JSX.Element;
|
|
73
|
+
export { render_1 as render };
|
|
74
|
+
}
|
|
68
75
|
import { Callout } from '@/components/general/callout';
|
|
69
76
|
//# sourceMappingURL=callout.stories.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"callout.stories.d.ts","sourceRoot":"","sources":["../../../../src/stories/callout/callout.stories.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"callout.stories.d.ts","sourceRoot":"","sources":["../../../../src/stories/callout/callout.stories.js"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IA+DS,2DAuCP;;;IAIO,oEAiCP;;;wBA1IsB,8BAA8B"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
declare namespace _default {
|
|
2
|
+
export let title: string;
|
|
3
|
+
export { SplitScroll as component };
|
|
4
|
+
export let decorators: ((Story: any) => import("react/jsx-runtime").JSX.Element)[];
|
|
5
|
+
}
|
|
6
|
+
export default _default;
|
|
7
|
+
export namespace BasicSplitScroll {
|
|
8
|
+
function render(): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
}
|
|
10
|
+
export namespace ProductShowcase {
|
|
11
|
+
export function render_1(): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export { render_1 as render };
|
|
13
|
+
}
|
|
14
|
+
export namespace MinimalSplitScroll {
|
|
15
|
+
export function render_2(): import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
export { render_2 as render };
|
|
17
|
+
}
|
|
18
|
+
import { SplitScroll } from '@/components/general/splitscroll';
|
|
19
|
+
//# sourceMappingURL=splitscroll.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"splitscroll.stories.d.ts","sourceRoot":"","sources":["../../../../src/stories/general/splitscroll.stories.js"],"names":[],"mappings":";;;;;;;IA4BS,2DAwGP;;;IAIO,oEAyFP;;;;IAIO,oEAuBP;;;4BA3P0B,kCAAkC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
declare namespace _default {
|
|
2
|
+
export let title: string;
|
|
3
|
+
export { SplitScroll as component };
|
|
4
|
+
export let decorators: ((Story: any) => import("react/jsx-runtime").JSX.Element)[];
|
|
5
|
+
}
|
|
6
|
+
export default _default;
|
|
7
|
+
export namespace BasicSplitScroll {
|
|
8
|
+
function render(): import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
}
|
|
10
|
+
export namespace ProductShowcase {
|
|
11
|
+
export function render_1(): import("react/jsx-runtime").JSX.Element;
|
|
12
|
+
export { render_1 as render };
|
|
13
|
+
}
|
|
14
|
+
export namespace MinimalSplitScroll {
|
|
15
|
+
export function render_2(): import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
export { render_2 as render };
|
|
17
|
+
}
|
|
18
|
+
import { SplitScroll } from '@/components/general/splitscroll';
|
|
19
|
+
//# sourceMappingURL=lookbook.stories.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lookbook.stories.d.ts","sourceRoot":"","sources":["../../../../src/stories/lookbook/lookbook.stories.js"],"names":[],"mappings":";;;;;;;IA4BS,2DAwGP;;;IAIO,oEAyFP;;;;IAIO,oEAuBP;;;4BA3P0B,kCAAkC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"splitscroll.test.d.ts","sourceRoot":"","sources":["../../../src/tests/splitscroll.test.tsx"],"names":[],"mappings":""}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pixelated-tech/components",
|
|
3
|
-
"version": "3.7.
|
|
3
|
+
"version": "3.7.4",
|
|
4
4
|
"private": false,
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Pixelated Technologies",
|
|
@@ -138,7 +138,7 @@
|
|
|
138
138
|
"eslint-plugin-react": "^7.37.4",
|
|
139
139
|
"eslint-plugin-storybook": "^10.1.11",
|
|
140
140
|
"file-loader": "^6.2.0",
|
|
141
|
-
"happy-dom": "^20.0
|
|
141
|
+
"happy-dom": "^20.1.0",
|
|
142
142
|
"jsdom": "^27.4.0",
|
|
143
143
|
"less-loader": "^12.3.0",
|
|
144
144
|
"mini-css-extract-plugin": "^2.9.4",
|
|
@@ -169,9 +169,9 @@
|
|
|
169
169
|
"react-dom": "^19.2.0"
|
|
170
170
|
},
|
|
171
171
|
"optionalDependencies": {
|
|
172
|
-
"@aws-sdk/client-cloudwatch": "^3.
|
|
173
|
-
"@aws-sdk/client-route-53": "^3.
|
|
174
|
-
"googleapis": "^
|
|
172
|
+
"@aws-sdk/client-cloudwatch": "^3.965.0",
|
|
173
|
+
"@aws-sdk/client-route-53": "^3.965.0",
|
|
174
|
+
"googleapis": "^170.0.0",
|
|
175
175
|
"md5": "^2.3.0",
|
|
176
176
|
"puppeteer": "^24.34.0",
|
|
177
177
|
"react-redux": "*",
|
package/dist/mocks/browser.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";
|
package/dist/mocks/handlers.js
DELETED
|
@@ -1,206 +0,0 @@
|
|
|
1
|
-
import { http, HttpResponse } from 'msw';
|
|
2
|
-
console.log('MSW handlers loaded');
|
|
3
|
-
// Mock data for Axe Core accessibility
|
|
4
|
-
const mockAxeData = {
|
|
5
|
-
success: true,
|
|
6
|
-
data: {
|
|
7
|
-
site: 'example.com',
|
|
8
|
-
url: 'https://example.com',
|
|
9
|
-
violations: [
|
|
10
|
-
{
|
|
11
|
-
id: 'color-contrast',
|
|
12
|
-
impact: 'serious',
|
|
13
|
-
description: 'Elements must have sufficient color contrast',
|
|
14
|
-
help: 'Ensure text has enough contrast against background',
|
|
15
|
-
helpUrl: 'https://dequeuniversity.com/rules/axe/4.8/color-contrast',
|
|
16
|
-
nodes: [
|
|
17
|
-
{
|
|
18
|
-
target: ['.header h1'],
|
|
19
|
-
html: '<h1>Welcome</h1>',
|
|
20
|
-
failureSummary: 'Fix any of the following: Element has insufficient color contrast of 2.5:1'
|
|
21
|
-
}
|
|
22
|
-
]
|
|
23
|
-
},
|
|
24
|
-
{
|
|
25
|
-
id: 'image-alt',
|
|
26
|
-
impact: 'critical',
|
|
27
|
-
description: 'Images must have alternate text',
|
|
28
|
-
help: 'Provide alternative text for images',
|
|
29
|
-
helpUrl: 'https://dequeuniversity.com/rules/axe/4.8/image-alt',
|
|
30
|
-
nodes: [
|
|
31
|
-
{
|
|
32
|
-
target: ['img[alt=""]'],
|
|
33
|
-
html: '<img src="logo.png" alt="">',
|
|
34
|
-
failureSummary: 'Fix any of the following: aria-label attribute does not exist or is empty'
|
|
35
|
-
}
|
|
36
|
-
]
|
|
37
|
-
}
|
|
38
|
-
],
|
|
39
|
-
passes: 45,
|
|
40
|
-
incomplete: 2,
|
|
41
|
-
inapplicable: 12
|
|
42
|
-
}
|
|
43
|
-
};
|
|
44
|
-
// Mock data for Core Web Vitals
|
|
45
|
-
const mockCoreWebVitalsData = {
|
|
46
|
-
success: true,
|
|
47
|
-
data: {
|
|
48
|
-
site: 'pixelated.tech',
|
|
49
|
-
url: 'https://pixelated.tech',
|
|
50
|
-
metrics: {
|
|
51
|
-
cls: 0.05,
|
|
52
|
-
fid: 85,
|
|
53
|
-
lcp: 1200,
|
|
54
|
-
fcp: 800,
|
|
55
|
-
ttfb: 150,
|
|
56
|
-
speedIndex: 1100,
|
|
57
|
-
interactive: 1300,
|
|
58
|
-
totalBlockingTime: 50,
|
|
59
|
-
firstMeaningfulPaint: 900
|
|
60
|
-
},
|
|
61
|
-
scores: {
|
|
62
|
-
performance: 85,
|
|
63
|
-
accessibility: 90,
|
|
64
|
-
bestPractices: 95,
|
|
65
|
-
seo: 88,
|
|
66
|
-
pwa: 75
|
|
67
|
-
},
|
|
68
|
-
categories: {
|
|
69
|
-
performance: { score: 85, displayValue: 'Good' },
|
|
70
|
-
accessibility: { score: 90, displayValue: 'Good' },
|
|
71
|
-
bestPractices: { score: 95, displayValue: 'Good' },
|
|
72
|
-
seo: { score: 88, displayValue: 'Good' },
|
|
73
|
-
pwa: { score: 75, displayValue: 'Good' }
|
|
74
|
-
}
|
|
75
|
-
}
|
|
76
|
-
};
|
|
77
|
-
// Mock data for Google Analytics
|
|
78
|
-
const mockGoogleAnalyticsData = {
|
|
79
|
-
success: true,
|
|
80
|
-
data: {
|
|
81
|
-
site: 'pixelated.tech',
|
|
82
|
-
dateRange: {
|
|
83
|
-
start: '2024-01-01',
|
|
84
|
-
end: '2024-01-06'
|
|
85
|
-
},
|
|
86
|
-
metrics: {
|
|
87
|
-
users: 1250,
|
|
88
|
-
sessions: 1800,
|
|
89
|
-
pageviews: 3200,
|
|
90
|
-
bounceRate: 0.45,
|
|
91
|
-
avgSessionDuration: 180,
|
|
92
|
-
newUsers: 890
|
|
93
|
-
},
|
|
94
|
-
chartData: [
|
|
95
|
-
{ date: '2024-01-01', users: 120, sessions: 150, pageviews: 280 },
|
|
96
|
-
{ date: '2024-01-02', users: 135, sessions: 165, pageviews: 310 },
|
|
97
|
-
{ date: '2024-01-03', users: 142, sessions: 178, pageviews: 325 },
|
|
98
|
-
{ date: '2024-01-04', users: 158, sessions: 192, pageviews: 345 },
|
|
99
|
-
{ date: '2024-01-05', users: 165, sessions: 198, pageviews: 365 },
|
|
100
|
-
{ date: '2024-01-06', users: 172, sessions: 205, pageviews: 380 }
|
|
101
|
-
]
|
|
102
|
-
}
|
|
103
|
-
};
|
|
104
|
-
// Mock data for Google Search Console
|
|
105
|
-
const mockGoogleSearchConsoleData = {
|
|
106
|
-
success: true,
|
|
107
|
-
data: {
|
|
108
|
-
site: 'pixelated.tech',
|
|
109
|
-
dateRange: {
|
|
110
|
-
start: '2024-01-01',
|
|
111
|
-
end: '2024-01-06'
|
|
112
|
-
},
|
|
113
|
-
metrics: {
|
|
114
|
-
clicks: 1250,
|
|
115
|
-
impressions: 15000,
|
|
116
|
-
ctr: 0.083,
|
|
117
|
-
position: 12.5
|
|
118
|
-
},
|
|
119
|
-
chartData: [
|
|
120
|
-
{ date: '2024-01-01', clicks: 85, impressions: 1200, ctr: 0.071, position: 14.2 },
|
|
121
|
-
{ date: '2024-01-02', clicks: 92, impressions: 1350, ctr: 0.068, position: 13.8 },
|
|
122
|
-
{ date: '2024-01-03', clicks: 98, impressions: 1420, ctr: 0.069, position: 13.5 },
|
|
123
|
-
{ date: '2024-01-04', clicks: 105, impressions: 1480, ctr: 0.071, position: 13.2 },
|
|
124
|
-
{ date: '2024-01-05', clicks: 112, impressions: 1520, ctr: 0.074, position: 12.8 },
|
|
125
|
-
{ date: '2024-01-06', clicks: 118, impressions: 1580, ctr: 0.075, position: 12.5 }
|
|
126
|
-
]
|
|
127
|
-
}
|
|
128
|
-
};
|
|
129
|
-
// Mock data for CloudWatch uptime
|
|
130
|
-
const mockCloudWatchData = {
|
|
131
|
-
success: true,
|
|
132
|
-
data: {
|
|
133
|
-
site: 'pixelated.tech',
|
|
134
|
-
uptime: 99.8,
|
|
135
|
-
responseTime: 245,
|
|
136
|
-
status: 'operational',
|
|
137
|
-
incidents: [],
|
|
138
|
-
chartData: [
|
|
139
|
-
{ timestamp: '2024-01-01T00:00:00Z', uptime: 100, responseTime: 220 },
|
|
140
|
-
{ timestamp: '2024-01-02T00:00:00Z', uptime: 99.5, responseTime: 280 },
|
|
141
|
-
{ timestamp: '2024-01-03T00:00:00Z', uptime: 100, responseTime: 210 },
|
|
142
|
-
{ timestamp: '2024-01-04T00:00:00Z', uptime: 100, responseTime: 235 },
|
|
143
|
-
{ timestamp: '2024-01-05T00:00:00Z', uptime: 99.9, responseTime: 250 },
|
|
144
|
-
{ timestamp: '2024-01-06T00:00:00Z', uptime: 100, responseTime: 225 }
|
|
145
|
-
]
|
|
146
|
-
}
|
|
147
|
-
};
|
|
148
|
-
export const handlers = [
|
|
149
|
-
// API endpoints using relative paths (MSW v2 matches these regardless of origin)
|
|
150
|
-
http.get('/api/site-health/axe-core', () => {
|
|
151
|
-
console.log('MSW: Intercepting axe-core request');
|
|
152
|
-
return HttpResponse.json(mockAxeData);
|
|
153
|
-
}),
|
|
154
|
-
http.get('/api/site-health/core-web-vitals', () => {
|
|
155
|
-
console.log('MSW: Intercepting core-web-vitals request');
|
|
156
|
-
return HttpResponse.json(mockCoreWebVitalsData);
|
|
157
|
-
}),
|
|
158
|
-
http.get('/api/site-health/google-analytics', () => {
|
|
159
|
-
console.log('MSW: Intercepting google-analytics request');
|
|
160
|
-
return HttpResponse.json(mockGoogleAnalyticsData);
|
|
161
|
-
}),
|
|
162
|
-
http.get('/api/site-health/google-search-console', () => {
|
|
163
|
-
console.log('MSW: Intercepting google-search-console request');
|
|
164
|
-
return HttpResponse.json(mockGoogleSearchConsoleData);
|
|
165
|
-
}),
|
|
166
|
-
http.get('/api/site-health/cloudwatch', () => {
|
|
167
|
-
console.log('MSW: Intercepting cloudwatch request');
|
|
168
|
-
return HttpResponse.json(mockCloudWatchData);
|
|
169
|
-
}),
|
|
170
|
-
// External URLs used by some stories
|
|
171
|
-
http.get('https://api.pixelated.tech/axe-core', () => {
|
|
172
|
-
console.log('MSW: Intercepting external axe-core request');
|
|
173
|
-
return HttpResponse.json(mockAxeData);
|
|
174
|
-
}),
|
|
175
|
-
http.get('https://api.pixelated.tech/core-web-vitals', () => {
|
|
176
|
-
console.log('MSW: Intercepting external core-web-vitals request');
|
|
177
|
-
return HttpResponse.json(mockCoreWebVitalsData);
|
|
178
|
-
}),
|
|
179
|
-
http.get('https://api.pixelated.tech/google-analytics', () => {
|
|
180
|
-
console.log('MSW: Intercepting external google-analytics request');
|
|
181
|
-
return HttpResponse.json(mockGoogleAnalyticsData);
|
|
182
|
-
}),
|
|
183
|
-
http.get('https://api.pixelated.tech/google-search-console', () => {
|
|
184
|
-
console.log('MSW: Intercepting external google-search-console request');
|
|
185
|
-
return HttpResponse.json(mockGoogleSearchConsoleData);
|
|
186
|
-
}),
|
|
187
|
-
http.get('https://api.pixelated.tech/cloudwatch', () => {
|
|
188
|
-
console.log('MSW: Intercepting external cloudwatch request');
|
|
189
|
-
return HttpResponse.json(mockCloudWatchData);
|
|
190
|
-
}),
|
|
191
|
-
http.get('https://api.pixelated.tech/template-data', () => {
|
|
192
|
-
console.log('MSW: Intercepting template-data request');
|
|
193
|
-
return HttpResponse.json({
|
|
194
|
-
success: true,
|
|
195
|
-
data: { message: 'Mock template data' }
|
|
196
|
-
});
|
|
197
|
-
}),
|
|
198
|
-
// Generic fallback for any other site health endpoints
|
|
199
|
-
http.get('/api/site-health/*', () => {
|
|
200
|
-
console.log('MSW: Intercepting generic site-health request');
|
|
201
|
-
return HttpResponse.json({
|
|
202
|
-
success: true,
|
|
203
|
-
data: { message: 'Mock data for site health endpoint' }
|
|
204
|
-
});
|
|
205
|
-
})
|
|
206
|
-
];
|
package/dist/mocks/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=browser.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"browser.d.ts","sourceRoot":"","sources":["../../../src/mocks/browser.js"],"names":[],"mappings":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"handlers.d.ts","sourceRoot":"","sources":["../../../src/mocks/handlers.js"],"names":[],"mappings":"AA0JA,6BAqEE"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/mocks/index.js"],"names":[],"mappings":""}
|