@pega/cosmos-react-test-utils 8.0.0-build.3.2 → 8.0.0-build.30.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/lib/index.d.ts +1 -0
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +1 -0
- package/lib/index.js.map +1 -1
- package/lib/matchers/index.d.ts +3 -0
- package/lib/matchers/index.d.ts.map +1 -0
- package/lib/matchers/index.js +7 -0
- package/lib/matchers/index.js.map +1 -0
- package/lib/matchers/to-contain-assertive-log.d.ts +29 -0
- package/lib/matchers/to-contain-assertive-log.d.ts.map +1 -0
- package/lib/matchers/to-contain-assertive-log.js +18 -0
- package/lib/matchers/to-contain-assertive-log.js.map +1 -0
- package/lib/mocks/animation.d.ts +1 -0
- package/lib/mocks/animation.d.ts.map +1 -0
- package/lib/mocks/animation.js +8 -0
- package/lib/mocks/animation.js.map +1 -0
- package/lib/mocks/broadcastChannelMock.d.ts +1 -0
- package/lib/mocks/broadcastChannelMock.d.ts.map +1 -0
- package/lib/mocks/broadcastChannelMock.js +12 -0
- package/lib/mocks/broadcastChannelMock.js.map +1 -0
- package/lib/mocks/createObjectURL.d.ts +1 -0
- package/lib/mocks/createObjectURL.d.ts.map +1 -0
- package/lib/mocks/createObjectURL.js +4 -0
- package/lib/mocks/createObjectURL.js.map +1 -0
- package/lib/mocks/createRange.js +12 -10
- package/lib/mocks/createRange.js.map +1 -1
- package/lib/mocks/elementFromPointMock.js +3 -1
- package/lib/mocks/elementFromPointMock.js.map +1 -1
- package/lib/mocks/getCurrentPositionMock.d.ts +1 -0
- package/lib/mocks/getCurrentPositionMock.d.ts.map +1 -0
- package/lib/mocks/getCurrentPositionMock.js +26 -0
- package/lib/mocks/getCurrentPositionMock.js.map +1 -0
- package/lib/mocks/index.d.ts +7 -0
- package/lib/mocks/index.d.ts.map +1 -1
- package/lib/mocks/index.js +7 -0
- package/lib/mocks/index.js.map +1 -1
- package/lib/mocks/innerTextMock.d.ts +1 -0
- package/lib/mocks/innerTextMock.d.ts.map +1 -0
- package/lib/mocks/innerTextMock.js +13 -0
- package/lib/mocks/innerTextMock.js.map +1 -0
- package/lib/mocks/intersectionObserverMock.js +11 -9
- package/lib/mocks/intersectionObserverMock.js.map +1 -1
- package/lib/mocks/mapsAPILoaderMock.d.ts +1 -0
- package/lib/mocks/mapsAPILoaderMock.d.ts.map +1 -0
- package/lib/mocks/mapsAPILoaderMock.js +10 -0
- package/lib/mocks/mapsAPILoaderMock.js.map +1 -0
- package/lib/mocks/matchMediaMock.js +12 -10
- package/lib/mocks/matchMediaMock.js.map +1 -1
- package/lib/mocks/mutationObserverMock.js +9 -7
- package/lib/mocks/mutationObserverMock.js.map +1 -1
- package/lib/mocks/randomUUID.d.ts +2 -0
- package/lib/mocks/randomUUID.d.ts.map +1 -0
- package/lib/mocks/randomUUID.js +5 -0
- package/lib/mocks/randomUUID.js.map +1 -0
- package/lib/mocks/resizeObserverMock.js +7 -5
- package/lib/mocks/resizeObserverMock.js.map +1 -1
- package/lib/mocks/scrollIntoView.js +3 -1
- package/lib/mocks/scrollIntoView.js.map +1 -1
- package/lib/mocks/svgGetBBox.js +18 -16
- package/lib/mocks/svgGetBBox.js.map +1 -1
- package/lib/mocks/svgGetScreenCTM.js +14 -12
- package/lib/mocks/svgGetScreenCTM.js.map +1 -1
- package/lib/mocks/svgGetSubStringLength.js +9 -7
- package/lib/mocks/svgGetSubStringLength.js.map +1 -1
- package/lib/mocks/useBreakpointMock.js +2 -3
- package/lib/mocks/useBreakpointMock.js.map +1 -1
- package/lib/utils/utils.d.ts +1 -0
- package/lib/utils/utils.d.ts.map +1 -1
- package/lib/utils/utils.js +4 -0
- package/lib/utils/utils.js.map +1 -1
- package/package.json +13 -9
package/lib/index.d.ts
CHANGED
package/lib/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,cAAc,SAAS,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC"}
|
package/lib/index.js
CHANGED
package/lib/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,+DAA+D;AAC/D,cAAc,SAAS,CAAC","sourcesContent":["// This file is autogenerated. Any changes will be overwritten.\nexport * from './utils';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,+DAA+D;AAC/D,cAAc,YAAY,CAAC;AAC3B,cAAc,SAAS,CAAC","sourcesContent":["// This file is autogenerated. Any changes will be overwritten.\nexport * from './matchers';\nexport * from './utils';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/matchers/index.ts"],"names":[],"mappings":"AAAA,OAAO,qBAAqB,MAAM,4BAA4B,CAAC;AAO/D,OAAO,EAAE,qBAAqB,EAAE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/matchers/index.ts"],"names":[],"mappings":"AAAA,OAAO,qBAAqB,MAAM,4BAA4B,CAAC;AAE/D,MAAM,CAAC,MAAM,CAAC;IACZ,qBAAqB;CACtB,CAAC,CAAC;AAEH,wDAAwD;AACxD,OAAO,EAAE,qBAAqB,EAAE,CAAC","sourcesContent":["import toContainAssertiveLog from './to-contain-assertive-log';\n\nexpect.extend({\n toContainAssertiveLog\n});\n\n// eslint-disable-next-line import/prefer-default-export\nexport { toContainAssertiveLog };\n"]}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
declare global {
|
|
2
|
+
namespace jest {
|
|
3
|
+
interface Matchers<R> {
|
|
4
|
+
/**
|
|
5
|
+
* @description
|
|
6
|
+
* This allows you to check if given element of type 'log' does contain assertive text.
|
|
7
|
+
*
|
|
8
|
+
* @example
|
|
9
|
+
* <div
|
|
10
|
+
* role='log'
|
|
11
|
+
* >
|
|
12
|
+
* Invisible content
|
|
13
|
+
* </div>
|
|
14
|
+
*
|
|
15
|
+
* <div data-testid="visible">Visible Example</div>
|
|
16
|
+
*
|
|
17
|
+
* expect(getByRole('log')).toContainAssertiveLog('Value cannot be empty.')
|
|
18
|
+
* expect(getByRole('log')).not.toContainAssertiveLog('Value cannot be empty.')
|
|
19
|
+
*/
|
|
20
|
+
toContainAssertiveLog: (expected: string) => R;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
declare function toContainAssertiveLog(this: jest.MatcherContext, actual: HTMLElement[], expected: string): {
|
|
25
|
+
message: () => string;
|
|
26
|
+
pass: boolean;
|
|
27
|
+
};
|
|
28
|
+
export default toContainAssertiveLog;
|
|
29
|
+
//# sourceMappingURL=to-contain-assertive-log.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"to-contain-assertive-log.d.ts","sourceRoot":"","sources":["../../src/matchers/to-contain-assertive-log.ts"],"names":[],"mappings":"AAEA,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,IAAI,CAAC;QACb,UAAU,QAAQ,CAAC,CAAC;YAClB;;;;;;;;;;;;;;;eAeG;YACH,qBAAqB,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,CAAC,CAAC;SAChD;KACF;CACF;AAED,iBAAS,qBAAqB,CAAC,IAAI,EAAE,IAAI,CAAC,cAAc,EAAE,MAAM,EAAE,WAAW,EAAE,EAAE,QAAQ,EAAE,MAAM;;;EAmBhG;AAED,eAAe,qBAAqB,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import chalk from 'chalk';
|
|
2
|
+
function toContainAssertiveLog(actual, expected) {
|
|
3
|
+
const logFound = actual.find(el => {
|
|
4
|
+
return el.getAttribute('aria-live') === 'assertive';
|
|
5
|
+
});
|
|
6
|
+
if (logFound && logFound.textContent && logFound.textContent.includes(expected)) {
|
|
7
|
+
return {
|
|
8
|
+
message: () => `Expected LiveLog to contain an assertive log that matches "${expected}"`,
|
|
9
|
+
pass: true
|
|
10
|
+
};
|
|
11
|
+
}
|
|
12
|
+
return {
|
|
13
|
+
message: () => `Expected substring: ${chalk.green(expected)}\nReceived string: ${chalk.red(logFound && logFound.textContent ? logFound.textContent : 'undefined')}`,
|
|
14
|
+
pass: false
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
export default toContainAssertiveLog;
|
|
18
|
+
//# sourceMappingURL=to-contain-assertive-log.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"to-contain-assertive-log.js","sourceRoot":"","sources":["../../src/matchers/to-contain-assertive-log.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AA0B1B,SAAS,qBAAqB,CAA4B,MAAqB,EAAE,QAAgB;IAC/F,MAAM,QAAQ,GAAG,MAAM,CAAC,IAAI,CAAC,EAAE,CAAC,EAAE;QAChC,OAAO,EAAE,CAAC,YAAY,CAAC,WAAW,CAAC,KAAK,WAAW,CAAC;IACtD,CAAC,CAAC,CAAC;IAEH,IAAI,QAAQ,IAAI,QAAQ,CAAC,WAAW,IAAI,QAAQ,CAAC,WAAW,CAAC,QAAQ,CAAC,QAAQ,CAAC,EAAE,CAAC;QAChF,OAAO;YACL,OAAO,EAAE,GAAG,EAAE,CAAC,8DAA8D,QAAQ,GAAG;YACxF,IAAI,EAAE,IAAI;SACX,CAAC;IACJ,CAAC;IAED,OAAO;QACL,OAAO,EAAE,GAAG,EAAE,CACZ,uBAAuB,KAAK,CAAC,KAAK,CAAC,QAAQ,CAAC,sBAAsB,KAAK,CAAC,GAAG,CACzE,QAAQ,IAAI,QAAQ,CAAC,WAAW,CAAC,CAAC,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAC,CAAC,WAAW,CACtE,EAAE;QACL,IAAI,EAAE,KAAK;KACZ,CAAC;AACJ,CAAC;AAED,eAAe,qBAAqB,CAAC","sourcesContent":["import chalk from 'chalk';\n\ndeclare global {\n namespace jest {\n interface Matchers<R> {\n /**\n * @description\n * This allows you to check if given element of type 'log' does contain assertive text.\n *\n * @example\n * <div\n * role='log'\n * >\n * Invisible content\n * </div>\n *\n * <div data-testid=\"visible\">Visible Example</div>\n *\n * expect(getByRole('log')).toContainAssertiveLog('Value cannot be empty.')\n * expect(getByRole('log')).not.toContainAssertiveLog('Value cannot be empty.')\n */\n toContainAssertiveLog: (expected: string) => R;\n }\n }\n}\n\nfunction toContainAssertiveLog(this: jest.MatcherContext, actual: HTMLElement[], expected: string) {\n const logFound = actual.find(el => {\n return el.getAttribute('aria-live') === 'assertive';\n });\n\n if (logFound && logFound.textContent && logFound.textContent.includes(expected)) {\n return {\n message: () => `Expected LiveLog to contain an assertive log that matches \"${expected}\"`,\n pass: true\n };\n }\n\n return {\n message: () =>\n `Expected substring: ${chalk.green(expected)}\\nReceived string: ${chalk.red(\n logFound && logFound.textContent ? logFound.textContent : 'undefined'\n )}`,\n pass: false\n };\n}\n\nexport default toContainAssertiveLog;\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=animation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"animation.d.ts","sourceRoot":"","sources":["../../src/mocks/animation.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"animation.js","sourceRoot":"","sources":["../../src/mocks/animation.ts"],"names":[],"mappings":";AAAA,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;IAClC,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,OAAO,GAAG,GAAG,EAAE,CACtC,CAAC;QACC,6DAA6D;QAC7D,gBAAgB,EAAE,CAAC,IAAY,EAAE,QAA4C,EAAE,EAAE,GAAE,CAAC;KACrF,CAAc,CAAC;AACpB,CAAC","sourcesContent":["if (typeof window !== 'undefined') {\n window.Element.prototype.animate = () =>\n ({\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n addEventListener: (type: string, listener: EventListenerOrEventListenerObject) => {}\n }) as Animation;\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=broadcastChannelMock.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"broadcastChannelMock.d.ts","sourceRoot":"","sources":["../../src/mocks/broadcastChannelMock.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
globalThis.BroadcastChannel = class BroadcastChannel {
|
|
3
|
+
// eslint-disable-next-line class-methods-use-this
|
|
4
|
+
onMessage() { }
|
|
5
|
+
postMessage(data) {
|
|
6
|
+
// @ts-expect-error
|
|
7
|
+
this.onmessage?.({ data });
|
|
8
|
+
}
|
|
9
|
+
// eslint-disable-next-line class-methods-use-this
|
|
10
|
+
close() { }
|
|
11
|
+
};
|
|
12
|
+
//# sourceMappingURL=broadcastChannelMock.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"broadcastChannelMock.js","sourceRoot":"","sources":["../../src/mocks/broadcastChannelMock.ts"],"names":[],"mappings":";AAAA,UAAU,CAAC,gBAAgB,GAAG,MAAM,gBAAgB;IAClD,kDAAkD;IAClD,SAAS,KAAI,CAAC;IAEd,WAAW,CAAC,IAAa;QACvB,mBAAmB;QACnB,IAAI,CAAC,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC;IAC7B,CAAC;IAED,kDAAkD;IAClD,KAAK,KAAI,CAAC;CACJ,CAAC","sourcesContent":["globalThis.BroadcastChannel = class BroadcastChannel {\n // eslint-disable-next-line class-methods-use-this\n onMessage() {}\n\n postMessage(data: unknown) {\n // @ts-expect-error\n this.onmessage?.({ data });\n }\n\n // eslint-disable-next-line class-methods-use-this\n close() {}\n} as any;\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=createObjectURL.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"createObjectURL.d.ts","sourceRoot":"","sources":["../../src/mocks/createObjectURL.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"createObjectURL.js","sourceRoot":"","sources":["../../src/mocks/createObjectURL.ts"],"names":[],"mappings":";AAAA,GAAG,CAAC,eAAe,GAAG,GAAG,EAAE,CAAC,EAAE,CAAC;AAC/B,GAAG,CAAC,eAAe,GAAG,GAAG,EAAE,GAAE,CAAC,CAAC","sourcesContent":["URL.createObjectURL = () => '';\nURL.revokeObjectURL = () => {};\n"]}
|
package/lib/mocks/createRange.js
CHANGED
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
document
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
2
|
+
if (typeof document !== 'undefined') {
|
|
3
|
+
document.createRange = () => {
|
|
4
|
+
const range = new Range();
|
|
5
|
+
range.getBoundingClientRect = jest.fn();
|
|
6
|
+
range.getClientRects = () => {
|
|
7
|
+
return {
|
|
8
|
+
item: () => null,
|
|
9
|
+
length: 0,
|
|
10
|
+
[Symbol.iterator]: jest.fn()
|
|
11
|
+
};
|
|
10
12
|
};
|
|
13
|
+
return range;
|
|
11
14
|
};
|
|
12
|
-
|
|
13
|
-
};
|
|
15
|
+
}
|
|
14
16
|
//# sourceMappingURL=createRange.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createRange.js","sourceRoot":"","sources":["../../src/mocks/createRange.ts"],"names":[],"mappings":";AAAA,QAAQ,CAAC,WAAW,GAAG,GAAG,EAAE;
|
|
1
|
+
{"version":3,"file":"createRange.js","sourceRoot":"","sources":["../../src/mocks/createRange.ts"],"names":[],"mappings":";AAAA,IAAI,OAAO,QAAQ,KAAK,WAAW,EAAE,CAAC;IACpC,QAAQ,CAAC,WAAW,GAAG,GAAG,EAAE;QAC1B,MAAM,KAAK,GAAG,IAAI,KAAK,EAAE,CAAC;QAE1B,KAAK,CAAC,qBAAqB,GAAG,IAAI,CAAC,EAAE,EAAE,CAAC;QAExC,KAAK,CAAC,cAAc,GAAG,GAAG,EAAE;YAC1B,OAAO;gBACL,IAAI,EAAE,GAAG,EAAE,CAAC,IAAI;gBAChB,MAAM,EAAE,CAAC;gBACT,CAAC,MAAM,CAAC,QAAQ,CAAC,EAAE,IAAI,CAAC,EAAE,EAAE;aAC7B,CAAC;QACJ,CAAC,CAAC;QAEF,OAAO,KAAK,CAAC;IACf,CAAC,CAAC;AACJ,CAAC","sourcesContent":["if (typeof document !== 'undefined') {\n document.createRange = () => {\n const range = new Range();\n\n range.getBoundingClientRect = jest.fn();\n\n range.getClientRects = () => {\n return {\n item: () => null,\n length: 0,\n [Symbol.iterator]: jest.fn()\n };\n };\n\n return range;\n };\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"elementFromPointMock.js","sourceRoot":"","sources":["../../src/mocks/elementFromPointMock.ts"],"names":[],"mappings":";AAAA,QAAQ,CAAC,gBAAgB,GAAG,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,CAAC","sourcesContent":["document.elementFromPoint = jest.fn(() => null);\n"]}
|
|
1
|
+
{"version":3,"file":"elementFromPointMock.js","sourceRoot":"","sources":["../../src/mocks/elementFromPointMock.ts"],"names":[],"mappings":";AAAA,IAAI,OAAO,QAAQ,KAAK,WAAW,EAAE,CAAC;IACpC,QAAQ,CAAC,gBAAgB,GAAG,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,CAAC;AAClD,CAAC","sourcesContent":["if (typeof document !== 'undefined') {\n document.elementFromPoint = jest.fn(() => null);\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=getCurrentPositionMock.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getCurrentPositionMock.d.ts","sourceRoot":"","sources":["../../src/mocks/getCurrentPositionMock.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
if (typeof navigator !== 'undefined') {
|
|
3
|
+
const getCurrentPositionMock = successCallback => {
|
|
4
|
+
successCallback({
|
|
5
|
+
coords: {
|
|
6
|
+
latitude: 0,
|
|
7
|
+
longitude: 0,
|
|
8
|
+
accuracy: 1,
|
|
9
|
+
heading: null,
|
|
10
|
+
altitude: null,
|
|
11
|
+
altitudeAccuracy: null,
|
|
12
|
+
speed: null
|
|
13
|
+
},
|
|
14
|
+
timestamp: Date.now()
|
|
15
|
+
});
|
|
16
|
+
};
|
|
17
|
+
Object.defineProperty(navigator, 'geolocation', {
|
|
18
|
+
value: {
|
|
19
|
+
getCurrentPosition: getCurrentPositionMock,
|
|
20
|
+
watchPosition: () => { },
|
|
21
|
+
clearWatch: () => { }
|
|
22
|
+
},
|
|
23
|
+
configurable: true
|
|
24
|
+
});
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=getCurrentPositionMock.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getCurrentPositionMock.js","sourceRoot":"","sources":["../../src/mocks/getCurrentPositionMock.ts"],"names":[],"mappings":";AAAA,IAAI,OAAO,SAAS,KAAK,WAAW,EAAE,CAAC;IACrC,MAAM,sBAAsB,GAAsC,eAAe,CAAC,EAAE;QAClF,eAAe,CAAC;YACd,MAAM,EAAE;gBACN,QAAQ,EAAE,CAAC;gBACX,SAAS,EAAE,CAAC;gBACZ,QAAQ,EAAE,CAAC;gBACX,OAAO,EAAE,IAAI;gBACb,QAAQ,EAAE,IAAI;gBACd,gBAAgB,EAAE,IAAI;gBACtB,KAAK,EAAE,IAAI;aACZ;YACD,SAAS,EAAE,IAAI,CAAC,GAAG,EAAE;SACtB,CAAC,CAAC;IACL,CAAC,CAAC;IAEF,MAAM,CAAC,cAAc,CAAC,SAAS,EAAE,aAAa,EAAE;QAC9C,KAAK,EAAE;YACL,kBAAkB,EAAE,sBAAsB;YAC1C,aAAa,EAAE,GAAG,EAAE,GAAE,CAAC;YACvB,UAAU,EAAE,GAAG,EAAE,GAAE,CAAC;SACrB;QACD,YAAY,EAAE,IAAI;KACnB,CAAC,CAAC;AACL,CAAC","sourcesContent":["if (typeof navigator !== 'undefined') {\n const getCurrentPositionMock: Geolocation['getCurrentPosition'] = successCallback => {\n successCallback({\n coords: {\n latitude: 0,\n longitude: 0,\n accuracy: 1,\n heading: null,\n altitude: null,\n altitudeAccuracy: null,\n speed: null\n },\n timestamp: Date.now()\n });\n };\n\n Object.defineProperty(navigator, 'geolocation', {\n value: {\n getCurrentPosition: getCurrentPositionMock,\n watchPosition: () => {},\n clearWatch: () => {}\n },\n configurable: true\n });\n}\n"]}
|
package/lib/mocks/index.d.ts
CHANGED
|
@@ -1,11 +1,18 @@
|
|
|
1
|
+
import './animation';
|
|
2
|
+
import './broadcastChannelMock';
|
|
3
|
+
import './createObjectURL';
|
|
1
4
|
import './createRange';
|
|
2
5
|
import './createUIDMock';
|
|
3
6
|
import './elementFromPointMock';
|
|
7
|
+
import './getCurrentPositionMock';
|
|
4
8
|
import './iconMock';
|
|
9
|
+
import './innerTextMock';
|
|
5
10
|
import './intersectionObserverMock';
|
|
11
|
+
import './mapsAPILoaderMock';
|
|
6
12
|
import './matchMediaMock';
|
|
7
13
|
import './popoverMock';
|
|
8
14
|
import './qrcodeMock';
|
|
15
|
+
import './randomUUID';
|
|
9
16
|
import './scrollIntoView';
|
|
10
17
|
import './svgGetBBox';
|
|
11
18
|
import './svgGetScreenCTM';
|
package/lib/mocks/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/mocks/index.ts"],"names":[],"mappings":"AAAA,OAAO,eAAe,CAAC;AACvB,OAAO,iBAAiB,CAAC;AACzB,OAAO,wBAAwB,CAAC;AAChC,OAAO,YAAY,CAAC;AACpB,OAAO,4BAA4B,CAAC;AACpC,OAAO,kBAAkB,CAAC;AAC1B,OAAO,eAAe,CAAC;AACvB,OAAO,cAAc,CAAC;AACtB,OAAO,kBAAkB,CAAC;AAC1B,OAAO,cAAc,CAAC;AACtB,OAAO,mBAAmB,CAAC;AAC3B,OAAO,yBAAyB,CAAC;AACjC,OAAO,sBAAsB,CAAC;AAC9B,OAAO,qBAAqB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/mocks/index.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,CAAC;AACrB,OAAO,wBAAwB,CAAC;AAChC,OAAO,mBAAmB,CAAC;AAC3B,OAAO,eAAe,CAAC;AACvB,OAAO,iBAAiB,CAAC;AACzB,OAAO,wBAAwB,CAAC;AAChC,OAAO,0BAA0B,CAAC;AAClC,OAAO,YAAY,CAAC;AACpB,OAAO,iBAAiB,CAAC;AACzB,OAAO,4BAA4B,CAAC;AACpC,OAAO,qBAAqB,CAAC;AAC7B,OAAO,kBAAkB,CAAC;AAC1B,OAAO,eAAe,CAAC;AACvB,OAAO,cAAc,CAAC;AACtB,OAAO,cAAc,CAAC;AACtB,OAAO,kBAAkB,CAAC;AAC1B,OAAO,cAAc,CAAC;AACtB,OAAO,mBAAmB,CAAC;AAC3B,OAAO,yBAAyB,CAAC;AACjC,OAAO,sBAAsB,CAAC;AAC9B,OAAO,qBAAqB,CAAC"}
|
package/lib/mocks/index.js
CHANGED
|
@@ -1,11 +1,18 @@
|
|
|
1
|
+
import './animation';
|
|
2
|
+
import './broadcastChannelMock';
|
|
3
|
+
import './createObjectURL';
|
|
1
4
|
import './createRange';
|
|
2
5
|
import './createUIDMock';
|
|
3
6
|
import './elementFromPointMock';
|
|
7
|
+
import './getCurrentPositionMock';
|
|
4
8
|
import './iconMock';
|
|
9
|
+
import './innerTextMock';
|
|
5
10
|
import './intersectionObserverMock';
|
|
11
|
+
import './mapsAPILoaderMock';
|
|
6
12
|
import './matchMediaMock';
|
|
7
13
|
import './popoverMock';
|
|
8
14
|
import './qrcodeMock';
|
|
15
|
+
import './randomUUID';
|
|
9
16
|
import './scrollIntoView';
|
|
10
17
|
import './svgGetBBox';
|
|
11
18
|
import './svgGetScreenCTM';
|
package/lib/mocks/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/mocks/index.ts"],"names":[],"mappings":"AAAA,OAAO,eAAe,CAAC;AACvB,OAAO,iBAAiB,CAAC;AACzB,OAAO,wBAAwB,CAAC;AAChC,OAAO,YAAY,CAAC;AACpB,OAAO,4BAA4B,CAAC;AACpC,OAAO,kBAAkB,CAAC;AAC1B,OAAO,eAAe,CAAC;AACvB,OAAO,cAAc,CAAC;AACtB,OAAO,kBAAkB,CAAC;AAC1B,OAAO,cAAc,CAAC;AACtB,OAAO,mBAAmB,CAAC;AAC3B,OAAO,yBAAyB,CAAC;AACjC,OAAO,sBAAsB,CAAC;AAC9B,OAAO,qBAAqB,CAAC","sourcesContent":["import './createRange';\nimport './createUIDMock';\nimport './elementFromPointMock';\nimport './iconMock';\nimport './intersectionObserverMock';\nimport './matchMediaMock';\nimport './popoverMock';\nimport './qrcodeMock';\nimport './scrollIntoView';\nimport './svgGetBBox';\nimport './svgGetScreenCTM';\nimport './svgGetSubStringLength';\nimport './resizeObserverMock';\nimport './useBreakpointMock';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/mocks/index.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,CAAC;AACrB,OAAO,wBAAwB,CAAC;AAChC,OAAO,mBAAmB,CAAC;AAC3B,OAAO,eAAe,CAAC;AACvB,OAAO,iBAAiB,CAAC;AACzB,OAAO,wBAAwB,CAAC;AAChC,OAAO,0BAA0B,CAAC;AAClC,OAAO,YAAY,CAAC;AACpB,OAAO,iBAAiB,CAAC;AACzB,OAAO,4BAA4B,CAAC;AACpC,OAAO,qBAAqB,CAAC;AAC7B,OAAO,kBAAkB,CAAC;AAC1B,OAAO,eAAe,CAAC;AACvB,OAAO,cAAc,CAAC;AACtB,OAAO,cAAc,CAAC;AACtB,OAAO,kBAAkB,CAAC;AAC1B,OAAO,cAAc,CAAC;AACtB,OAAO,mBAAmB,CAAC;AAC3B,OAAO,yBAAyB,CAAC;AACjC,OAAO,sBAAsB,CAAC;AAC9B,OAAO,qBAAqB,CAAC","sourcesContent":["import './animation';\nimport './broadcastChannelMock';\nimport './createObjectURL';\nimport './createRange';\nimport './createUIDMock';\nimport './elementFromPointMock';\nimport './getCurrentPositionMock';\nimport './iconMock';\nimport './innerTextMock';\nimport './intersectionObserverMock';\nimport './mapsAPILoaderMock';\nimport './matchMediaMock';\nimport './popoverMock';\nimport './qrcodeMock';\nimport './randomUUID';\nimport './scrollIntoView';\nimport './svgGetBBox';\nimport './svgGetScreenCTM';\nimport './svgGetSubStringLength';\nimport './resizeObserverMock';\nimport './useBreakpointMock';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=innerTextMock.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"innerTextMock.d.ts","sourceRoot":"","sources":["../../src/mocks/innerTextMock.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
if (typeof window !== 'undefined') {
|
|
3
|
+
// innerText is not supported by JSDOM, mock it to use textContent instead.
|
|
4
|
+
Object.defineProperty(window.HTMLElement.prototype, 'innerText', {
|
|
5
|
+
get() {
|
|
6
|
+
return this.textContent;
|
|
7
|
+
},
|
|
8
|
+
set(value) {
|
|
9
|
+
this.textContent = value;
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
}
|
|
13
|
+
//# sourceMappingURL=innerTextMock.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"innerTextMock.js","sourceRoot":"","sources":["../../src/mocks/innerTextMock.ts"],"names":[],"mappings":";AAAA,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;IAClC,2EAA2E;IAC3E,MAAM,CAAC,cAAc,CAAC,MAAM,CAAC,WAAW,CAAC,SAAS,EAAE,WAAW,EAAE;QAC/D,GAAG;YACD,OAAO,IAAI,CAAC,WAAW,CAAC;QAC1B,CAAC;QACD,GAAG,CAAC,KAAK;YACP,IAAI,CAAC,WAAW,GAAG,KAAK,CAAC;QAC3B,CAAC;KACF,CAAC,CAAC;AACL,CAAC","sourcesContent":["if (typeof window !== 'undefined') {\n // innerText is not supported by JSDOM, mock it to use textContent instead.\n Object.defineProperty(window.HTMLElement.prototype, 'innerText', {\n get() {\n return this.textContent;\n },\n set(value) {\n this.textContent = value;\n }\n });\n}\n"]}
|
|
@@ -1,11 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
window
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
}
|
|
2
|
+
if (typeof window !== 'undefined') {
|
|
3
|
+
window.IntersectionObserver = jest.fn(() => ({
|
|
4
|
+
root: null,
|
|
5
|
+
rootMargin: '0',
|
|
6
|
+
thresholds: [],
|
|
7
|
+
takeRecords: () => [],
|
|
8
|
+
observe: () => { },
|
|
9
|
+
unobserve: () => { },
|
|
10
|
+
disconnect: () => { }
|
|
11
|
+
}));
|
|
12
|
+
}
|
|
11
13
|
//# sourceMappingURL=intersectionObserverMock.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"intersectionObserverMock.js","sourceRoot":"","sources":["../../src/mocks/intersectionObserverMock.ts"],"names":[],"mappings":";AAAA,MAAM,CAAC,oBAAoB,GAAG,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"intersectionObserverMock.js","sourceRoot":"","sources":["../../src/mocks/intersectionObserverMock.ts"],"names":[],"mappings":";AAAA,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;IAClC,MAAM,CAAC,oBAAoB,GAAG,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,CAAC;QAC3C,IAAI,EAAE,IAAI;QACV,UAAU,EAAE,GAAG;QACf,UAAU,EAAE,EAAE;QACd,WAAW,EAAE,GAAG,EAAE,CAAC,EAAE;QACrB,OAAO,EAAE,GAAG,EAAE,GAAE,CAAC;QACjB,SAAS,EAAE,GAAG,EAAE,GAAE,CAAC;QACnB,UAAU,EAAE,GAAG,EAAE,GAAE,CAAC;KACrB,CAAC,CAAC,CAAC;AACN,CAAC","sourcesContent":["if (typeof window !== 'undefined') {\n window.IntersectionObserver = jest.fn(() => ({\n root: null,\n rootMargin: '0',\n thresholds: [],\n takeRecords: () => [],\n observe: () => {},\n unobserve: () => {},\n disconnect: () => {}\n }));\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=mapsAPILoaderMock.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mapsAPILoaderMock.d.ts","sourceRoot":"","sources":["../../src/mocks/mapsAPILoaderMock.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mapsAPILoaderMock.js","sourceRoot":"","sources":["../../src/mocks/mapsAPILoaderMock.ts"],"names":[],"mappings":";AAAA,IAAI,CAAC,IAAI,CAAC,2BAA2B,EAAE,GAAG,EAAE,CAAC,CAAC;IAC5C,MAAM,EAAE,MAAM,UAAU;QACtB,kDAAkD;QAClD,KAAK,CAAC,IAAI;YACR,OAAO,OAAO,CAAC,OAAO,EAAE,CAAC;QAC3B,CAAC;KACF;CACF,CAAC,CAAC,CAAC","sourcesContent":["jest.mock('@googlemaps/js-api-loader', () => ({\n Loader: class LoaderMock {\n // eslint-disable-next-line class-methods-use-this\n async load() {\n return Promise.resolve();\n }\n }\n}));\n"]}
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
window
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
2
|
+
if (typeof window !== 'undefined') {
|
|
3
|
+
window.matchMedia = jest.fn((query) => ({
|
|
4
|
+
matches: false,
|
|
5
|
+
media: query,
|
|
6
|
+
onchange: null,
|
|
7
|
+
addListener: () => { },
|
|
8
|
+
removeListener: () => { },
|
|
9
|
+
addEventListener: () => { },
|
|
10
|
+
removeEventListener: () => { },
|
|
11
|
+
dispatchEvent: () => false
|
|
12
|
+
}));
|
|
13
|
+
}
|
|
12
14
|
//# sourceMappingURL=matchMediaMock.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"matchMediaMock.js","sourceRoot":"","sources":["../../src/mocks/matchMediaMock.ts"],"names":[],"mappings":";AAAA,MAAM,CAAC,UAAU,GAAG,IAAI,CAAC,EAAE,CAAC,CAAC,KAAa,EAAE,EAAE,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"matchMediaMock.js","sourceRoot":"","sources":["../../src/mocks/matchMediaMock.ts"],"names":[],"mappings":";AAAA,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;IAClC,MAAM,CAAC,UAAU,GAAG,IAAI,CAAC,EAAE,CAAC,CAAC,KAAa,EAAE,EAAE,CAAC,CAAC;QAC9C,OAAO,EAAE,KAAK;QACd,KAAK,EAAE,KAAK;QACZ,QAAQ,EAAE,IAAI;QACd,WAAW,EAAE,GAAG,EAAE,GAAE,CAAC;QACrB,cAAc,EAAE,GAAG,EAAE,GAAE,CAAC;QACxB,gBAAgB,EAAE,GAAG,EAAE,GAAE,CAAC;QAC1B,mBAAmB,EAAE,GAAG,EAAE,GAAE,CAAC;QAC7B,aAAa,EAAE,GAAG,EAAE,CAAC,KAAK;KAC3B,CAAC,CAAC,CAAC;AACN,CAAC","sourcesContent":["if (typeof window !== 'undefined') {\n window.matchMedia = jest.fn((query: string) => ({\n matches: false,\n media: query,\n onchange: null,\n addListener: () => {},\n removeListener: () => {},\n addEventListener: () => {},\n removeEventListener: () => {},\n dispatchEvent: () => false\n }));\n}\n"]}
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
window
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
}
|
|
2
|
+
if (typeof window !== 'undefined') {
|
|
3
|
+
window.MutationObserver = jest.fn(() => {
|
|
4
|
+
return {
|
|
5
|
+
observe: jest.fn(),
|
|
6
|
+
disconnect: jest.fn(),
|
|
7
|
+
takeRecords: jest.fn()
|
|
8
|
+
};
|
|
9
|
+
});
|
|
10
|
+
}
|
|
9
11
|
//# sourceMappingURL=mutationObserverMock.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mutationObserverMock.js","sourceRoot":"","sources":["../../src/mocks/mutationObserverMock.ts"],"names":[],"mappings":";AAAA,MAAM,CAAC,gBAAgB,GAAG,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE;
|
|
1
|
+
{"version":3,"file":"mutationObserverMock.js","sourceRoot":"","sources":["../../src/mocks/mutationObserverMock.ts"],"names":[],"mappings":";AAAA,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;IAClC,MAAM,CAAC,gBAAgB,GAAG,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE;QACrC,OAAO;YACL,OAAO,EAAE,IAAI,CAAC,EAAE,EAAE;YAClB,UAAU,EAAE,IAAI,CAAC,EAAE,EAAE;YACrB,WAAW,EAAE,IAAI,CAAC,EAAE,EAAE;SACvB,CAAC;IACJ,CAAC,CAAC,CAAC;AACL,CAAC","sourcesContent":["if (typeof window !== 'undefined') {\n window.MutationObserver = jest.fn(() => {\n return {\n observe: jest.fn(),\n disconnect: jest.fn(),\n takeRecords: jest.fn()\n };\n });\n}\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"randomUUID.d.ts","sourceRoot":"","sources":["../../src/mocks/randomUUID.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"randomUUID.js","sourceRoot":"","sources":["../../src/mocks/randomUUID.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAEzC,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;IAClC,MAAM,CAAC,MAAM,CAAC,UAAU,GAAG,GAAG,EAAE,CAAC,UAAU,EAAE,CAAC;AAChD,CAAC","sourcesContent":["import { randomUUID } from 'node:crypto';\n\nif (typeof window !== 'undefined') {\n window.crypto.randomUUID = () => randomUUID();\n}\n"]}
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
window
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
}
|
|
2
|
+
if (typeof window !== 'undefined') {
|
|
3
|
+
window.ResizeObserver = jest.fn(() => ({
|
|
4
|
+
observe: () => { },
|
|
5
|
+
unobserve: () => { },
|
|
6
|
+
disconnect: () => { }
|
|
7
|
+
}));
|
|
8
|
+
}
|
|
7
9
|
//# sourceMappingURL=resizeObserverMock.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resizeObserverMock.js","sourceRoot":"","sources":["../../src/mocks/resizeObserverMock.ts"],"names":[],"mappings":";AAAA,MAAM,CAAC,cAAc,GAAG,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"resizeObserverMock.js","sourceRoot":"","sources":["../../src/mocks/resizeObserverMock.ts"],"names":[],"mappings":";AAAA,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;IAClC,MAAM,CAAC,cAAc,GAAG,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,CAAC;QACrC,OAAO,EAAE,GAAG,EAAE,GAAE,CAAC;QACjB,SAAS,EAAE,GAAG,EAAE,GAAE,CAAC;QACnB,UAAU,EAAE,GAAG,EAAE,GAAE,CAAC;KACrB,CAAC,CAAC,CAAC;AACN,CAAC","sourcesContent":["if (typeof window !== 'undefined') {\n window.ResizeObserver = jest.fn(() => ({\n observe: () => {},\n unobserve: () => {},\n disconnect: () => {}\n }));\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scrollIntoView.js","sourceRoot":"","sources":["../../src/mocks/scrollIntoView.ts"],"names":[],"mappings":";AAAA,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,cAAc,GAAG,GAAG,EAAE,GAAE,CAAC,CAAC","sourcesContent":["window.Element.prototype.scrollIntoView = () => {};\n"]}
|
|
1
|
+
{"version":3,"file":"scrollIntoView.js","sourceRoot":"","sources":["../../src/mocks/scrollIntoView.ts"],"names":[],"mappings":";AAAA,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;IAClC,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,cAAc,GAAG,GAAG,EAAE,GAAE,CAAC,CAAC;AACrD,CAAC","sourcesContent":["if (typeof window !== 'undefined') {\n window.Element.prototype.scrollIntoView = () => {};\n}\n"]}
|
package/lib/mocks/svgGetBBox.js
CHANGED
|
@@ -1,18 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
//
|
|
4
|
-
//
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
}
|
|
2
|
+
if (typeof window !== 'undefined') {
|
|
3
|
+
// JSDom mock for `getBBox` method on SVG graphic nodes
|
|
4
|
+
// https://developer.mozilla.org/en-US/docs/Web/API/SVGGraphicsElement/getBBox
|
|
5
|
+
// Need to attach to SVGElement.protype because JSDOM does not implement SVGGraphicsElement.
|
|
6
|
+
window.SVGElement.prototype.getBBox = () => ({
|
|
7
|
+
x: 0,
|
|
8
|
+
y: 0,
|
|
9
|
+
width: 10,
|
|
10
|
+
height: 10,
|
|
11
|
+
top: 0,
|
|
12
|
+
bottom: 10,
|
|
13
|
+
left: 0,
|
|
14
|
+
right: 10,
|
|
15
|
+
toJSON() {
|
|
16
|
+
return this;
|
|
17
|
+
}
|
|
18
|
+
});
|
|
19
|
+
}
|
|
18
20
|
//# sourceMappingURL=svgGetBBox.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"svgGetBBox.js","sourceRoot":"","sources":["../../src/mocks/svgGetBBox.ts"],"names":[],"mappings":";AAAA,uDAAuD;
|
|
1
|
+
{"version":3,"file":"svgGetBBox.js","sourceRoot":"","sources":["../../src/mocks/svgGetBBox.ts"],"names":[],"mappings":";AAAA,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;IAClC,uDAAuD;IACvD,8EAA8E;IAE9E,4FAA4F;IAC3F,MAAM,CAAC,UAAU,CAAC,SAAgC,CAAC,OAAO,GAAG,GAAG,EAAE,CAAC,CAAC;QACnE,CAAC,EAAE,CAAC;QACJ,CAAC,EAAE,CAAC;QACJ,KAAK,EAAE,EAAE;QACT,MAAM,EAAE,EAAE;QACV,GAAG,EAAE,CAAC;QACN,MAAM,EAAE,EAAE;QACV,IAAI,EAAE,CAAC;QACP,KAAK,EAAE,EAAE;QACT,MAAM;YACJ,OAAO,IAAI,CAAC;QACd,CAAC;KACF,CAAC,CAAC;AACL,CAAC","sourcesContent":["if (typeof window !== 'undefined') {\n // JSDom mock for `getBBox` method on SVG graphic nodes\n // https://developer.mozilla.org/en-US/docs/Web/API/SVGGraphicsElement/getBBox\n\n // Need to attach to SVGElement.protype because JSDOM does not implement SVGGraphicsElement.\n (window.SVGElement.prototype as SVGGraphicsElement).getBBox = () => ({\n x: 0,\n y: 0,\n width: 10,\n height: 10,\n top: 0,\n bottom: 10,\n left: 0,\n right: 10,\n toJSON() {\n return this;\n }\n });\n}\n"]}
|
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
//
|
|
4
|
-
//
|
|
5
|
-
//
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
2
|
+
if (typeof window !== 'undefined') {
|
|
3
|
+
// JSDom Polyfill for `getScreenCTM` method on SVG graphic nodes
|
|
4
|
+
// https://developer.mozilla.org/en-US/docs/Web/API/SVGGraphicsElement
|
|
5
|
+
// Similar issue: https://github.com/apexcharts/react-apexcharts/issues/52#issuecomment-844757362
|
|
6
|
+
// Need to attach to SVGElement.protype because JSDOM does not implement SVGGraphicsElement.
|
|
7
|
+
window.SVGElement.prototype.getScreenCTM = () => ({
|
|
8
|
+
a: 0,
|
|
9
|
+
b: 0,
|
|
10
|
+
c: 0,
|
|
11
|
+
d: 0,
|
|
12
|
+
e: 0,
|
|
13
|
+
f: 0
|
|
14
|
+
});
|
|
15
|
+
}
|
|
14
16
|
//# sourceMappingURL=svgGetScreenCTM.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"svgGetScreenCTM.js","sourceRoot":"","sources":["../../src/mocks/svgGetScreenCTM.ts"],"names":[],"mappings":";AAAA,gEAAgE;
|
|
1
|
+
{"version":3,"file":"svgGetScreenCTM.js","sourceRoot":"","sources":["../../src/mocks/svgGetScreenCTM.ts"],"names":[],"mappings":";AAAA,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;IAClC,gEAAgE;IAChE,sEAAsE;IACtE,iGAAiG;IAEjG,4FAA4F;IAC3F,MAAM,CAAC,UAAU,CAAC,SAAgC,CAAC,YAAY,GAAG,GAAG,EAAE,CACtE,CAAC;QACC,CAAC,EAAE,CAAC;QACJ,CAAC,EAAE,CAAC;QACJ,CAAC,EAAE,CAAC;QACJ,CAAC,EAAE,CAAC;QACJ,CAAC,EAAE,CAAC;QACJ,CAAC,EAAE,CAAC;KACL,CAAc,CAAC;AACpB,CAAC","sourcesContent":["if (typeof window !== 'undefined') {\n // JSDom Polyfill for `getScreenCTM` method on SVG graphic nodes\n // https://developer.mozilla.org/en-US/docs/Web/API/SVGGraphicsElement\n // Similar issue: https://github.com/apexcharts/react-apexcharts/issues/52#issuecomment-844757362\n\n // Need to attach to SVGElement.protype because JSDOM does not implement SVGGraphicsElement.\n (window.SVGElement.prototype as SVGGraphicsElement).getScreenCTM = () =>\n ({\n a: 0,\n b: 0,\n c: 0,\n d: 0,\n e: 0,\n f: 0\n }) as DOMMatrix;\n}\n"]}
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
//
|
|
4
|
-
// https://
|
|
5
|
-
//
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
2
|
+
if (typeof window !== 'undefined') {
|
|
3
|
+
// JSDom Polyfill for `getSubStringLength` method on SVG text nodes
|
|
4
|
+
// https://developer.mozilla.org/en-US/docs/Web/API/SVGTextContentElement
|
|
5
|
+
// https://webplatform.github.io/docs/svg/methods/getSubStringLength/
|
|
6
|
+
// Need to attach to SVGElement.protype because JSDOM does not implement SVGTextContentElement.
|
|
7
|
+
window.SVGElement.prototype.getSubStringLength =
|
|
8
|
+
// Mock: Assumes each character takes 10px width on an average and returns the substring width
|
|
9
|
+
(charnum, nchars) => nchars * 10;
|
|
10
|
+
}
|
|
9
11
|
//# sourceMappingURL=svgGetSubStringLength.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"svgGetSubStringLength.js","sourceRoot":"","sources":["../../src/mocks/svgGetSubStringLength.ts"],"names":[],"mappings":";AAAA,mEAAmE;
|
|
1
|
+
{"version":3,"file":"svgGetSubStringLength.js","sourceRoot":"","sources":["../../src/mocks/svgGetSubStringLength.ts"],"names":[],"mappings":";AAAA,IAAI,OAAO,MAAM,KAAK,WAAW,EAAE,CAAC;IAClC,mEAAmE;IACnE,yEAAyE;IACzE,qEAAqE;IAErE,+FAA+F;IAC9F,MAAM,CAAC,UAAU,CAAC,SAAmC,CAAC,kBAAkB;QACvE,8FAA8F;QAC9F,CAAC,OAAO,EAAE,MAAM,EAAE,EAAE,CAAC,MAAM,GAAG,EAAE,CAAC;AACrC,CAAC","sourcesContent":["if (typeof window !== 'undefined') {\n // JSDom Polyfill for `getSubStringLength` method on SVG text nodes\n // https://developer.mozilla.org/en-US/docs/Web/API/SVGTextContentElement\n // https://webplatform.github.io/docs/svg/methods/getSubStringLength/\n\n // Need to attach to SVGElement.protype because JSDOM does not implement SVGTextContentElement.\n (window.SVGElement.prototype as SVGTextContentElement).getSubStringLength =\n // Mock: Assumes each character takes 10px width on an average and returns the substring width\n (charnum, nchars) => nchars * 10;\n}\n"]}
|
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
jest.mock('@pega/cosmos-react-core/lib/hooks', () => {
|
|
2
|
+
jest.mock('@pega/cosmos-react-core/lib/hooks/useBreakpoint', () => {
|
|
3
3
|
const { themeDefinition } = jest.requireActual('@pega/cosmos-react-core/lib/theme');
|
|
4
4
|
return {
|
|
5
5
|
__esModule: true,
|
|
6
|
-
|
|
7
|
-
useBreakpoint: (bp) => {
|
|
6
|
+
default: (bp) => {
|
|
8
7
|
return (window.innerWidth / 16 >= Number.parseFloat(themeDefinition.base.breakpoints[bp].$value));
|
|
9
8
|
}
|
|
10
9
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useBreakpointMock.js","sourceRoot":"","sources":["../../src/mocks/useBreakpointMock.ts"],"names":[],"mappings":";AAAA,IAAI,CAAC,IAAI,CAAC,
|
|
1
|
+
{"version":3,"file":"useBreakpointMock.js","sourceRoot":"","sources":["../../src/mocks/useBreakpointMock.ts"],"names":[],"mappings":";AAAA,IAAI,CAAC,IAAI,CAAC,iDAAiD,EAAE,GAAG,EAAE;IAChE,MAAM,EAAE,eAAe,EAAE,GAAG,IAAI,CAAC,aAAa,CAE5C,mCAAmC,CAAC,CAAC;IAEvC,OAAO;QACL,UAAU,EAAE,IAAI;QAChB,OAAO,EAAE,CAAC,EAAiD,EAAE,EAAE;YAC7D,OAAO,CACL,MAAM,CAAC,UAAU,GAAG,EAAE,IAAI,MAAM,CAAC,UAAU,CAAC,eAAe,CAAC,IAAI,CAAC,WAAW,CAAC,EAAE,CAAC,CAAC,MAAM,CAAC,CACzF,CAAC;QACJ,CAAC;KACF,CAAC;AACJ,CAAC,CAAC,CAAC","sourcesContent":["jest.mock('@pega/cosmos-react-core/lib/hooks/useBreakpoint', () => {\n const { themeDefinition } = jest.requireActual<\n typeof import('@pega/cosmos-react-core/lib/theme')\n >('@pega/cosmos-react-core/lib/theme');\n\n return {\n __esModule: true,\n default: (bp: keyof typeof themeDefinition.base.breakpoints) => {\n return (\n window.innerWidth / 16 >= Number.parseFloat(themeDefinition.base.breakpoints[bp].$value)\n );\n }\n };\n});\n"]}
|
package/lib/utils/utils.d.ts
CHANGED
|
@@ -7,5 +7,6 @@ export declare function render(content: ReactElement, options?: OmitStrict<Rende
|
|
|
7
7
|
export declare function render<Q extends Queries = typeof queries, Container extends Element | DocumentFragment = HTMLElement, BaseElement extends Element | DocumentFragment = Container>(content: ReactElement, options: OmitStrict<RenderOptions<Q, Container, BaseElement>, 'wrapper'>, configurationProps?: ProvidersProps): RenderResult<Q, Container, BaseElement>;
|
|
8
8
|
export declare const resizeWindow: (x: number, y: number) => void;
|
|
9
9
|
export declare const dragElement: (originEl: HTMLElement, destinationEl: HTMLElement) => void;
|
|
10
|
+
export declare const userEventNoPointer: import("@testing-library/user-event").UserEvent;
|
|
10
11
|
export {};
|
|
11
12
|
//# sourceMappingURL=utils.d.ts.map
|
package/lib/utils/utils.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/utils/utils.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,OAAO,CAAC;AAE1C,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAC1E,OAAO,KAAK,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/utils/utils.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,OAAO,CAAC;AAE1C,OAAO,KAAK,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AAC1E,OAAO,KAAK,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAU7D,OAAO,KAAK,EAAE,kBAAkB,EAAE,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAE9E,KAAK,cAAc,GAAG,UAAU,CAAC,kBAAkB,EAAE,UAAU,CAAC,CAAC;AAiBjE,wBAAgB,MAAM,CACpB,OAAO,EAAE,YAAY,EACrB,OAAO,CAAC,EAAE,UAAU,CAAC,aAAa,EAAE,SAAS,GAAG,SAAS,CAAC,EAC1D,kBAAkB,CAAC,EAAE,cAAc,GAClC,YAAY,CAAC;AAEhB,wBAAgB,MAAM,CACpB,CAAC,SAAS,OAAO,GAAG,OAAO,OAAO,EAClC,SAAS,SAAS,OAAO,GAAG,gBAAgB,GAAG,WAAW,EAC1D,WAAW,SAAS,OAAO,GAAG,gBAAgB,GAAG,SAAS,EAE1D,OAAO,EAAE,YAAY,EACrB,OAAO,EAAE,UAAU,CAAC,aAAa,CAAC,CAAC,EAAE,SAAS,EAAE,WAAW,CAAC,EAAE,SAAS,CAAC,EACxE,kBAAkB,CAAC,EAAE,cAAc,GAClC,YAAY,CAAC,CAAC,EAAE,SAAS,EAAE,WAAW,CAAC,CAAC;AAmB3C,eAAO,MAAM,YAAY,MAAO,MAAM,KAAK,MAAM,SAIhD,CAAC;AAEF,eAAO,MAAM,WAAW,aAAc,WAAW,iBAAiB,WAAW,SAK5E,CAAC;AAEF,eAAO,MAAM,kBAAkB,iDAE7B,CAAC"}
|
package/lib/utils/utils.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { fireEvent, render as rtlRender } from '@testing-library/react';
|
|
3
|
+
import userEvent, { PointerEventsCheckLevel } from '@testing-library/user-event';
|
|
3
4
|
import { Configuration, LiveLog, ModalManager, PopoverManager, Toaster } from '@pega/cosmos-react-core';
|
|
4
5
|
const Providers = (configurationProps) => ({ children }) => (_jsx(Configuration, { ...configurationProps, children: _jsx(LiveLog, { children: _jsx(PopoverManager, { children: _jsx(Toaster, { dismissAfter: 5000, children: _jsx(ModalManager, { children: children }) }) }) }) }));
|
|
5
6
|
export function render(content, options = {}, configurationProps) {
|
|
@@ -19,4 +20,7 @@ export const dragElement = (originEl, destinationEl) => {
|
|
|
19
20
|
fireEvent.dragOver(destinationEl);
|
|
20
21
|
fireEvent.drop(destinationEl);
|
|
21
22
|
};
|
|
23
|
+
export const userEventNoPointer = userEvent.setup({
|
|
24
|
+
pointerEventsCheck: PointerEventsCheckLevel.Never
|
|
25
|
+
});
|
|
22
26
|
//# sourceMappingURL=utils.js.map
|
package/lib/utils/utils.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../src/utils/utils.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,SAAS,EAAE,MAAM,IAAI,SAAS,EAAE,MAAM,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"utils.js","sourceRoot":"","sources":["../../src/utils/utils.tsx"],"names":[],"mappings":";AACA,OAAO,EAAE,SAAS,EAAE,MAAM,IAAI,SAAS,EAAE,MAAM,wBAAwB,CAAC;AAGxE,OAAO,SAAS,EAAE,EAAE,uBAAuB,EAAE,MAAM,6BAA6B,CAAC;AAEjF,OAAO,EACL,aAAa,EACb,OAAO,EACP,YAAY,EACZ,cAAc,EACd,OAAO,EACR,MAAM,yBAAyB,CAAC;AAKjC,MAAM,SAAS,GACb,CAAC,kBAAmC,EAAE,EAAE,CACxC,CAAC,EAAE,QAAQ,EAA8B,EAAE,EAAE,CAAC,CAC5C,KAAC,aAAa,OAAK,kBAAkB,YACnC,KAAC,OAAO,cACN,KAAC,cAAc,cACb,KAAC,OAAO,IAAC,YAAY,EAAE,IAAI,YACzB,KAAC,YAAY,cAAE,QAAQ,GAAgB,GAC/B,GACK,GACT,GACI,CACjB,CAAC;AAmBJ,MAAM,UAAU,MAAM,CAKpB,OAAqB,EACrB,UAEsE,EAAE,EACxE,kBAAmC;IAEnC,OAAO,SAAS,CAAC,OAAO,EAAE;QACxB,GAAG,OAAO;QACV,OAAO,EAAE,SAAS,CAAC,kBAAkB,CAAC;KACtB,CAA2D,CAAC;AAChF,CAAC;AAED,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,CAAS,EAAE,CAAS,EAAE,EAAE;IACnD,MAAM,CAAC,UAAU,GAAG,CAAC,CAAC;IACtB,MAAM,CAAC,WAAW,GAAG,CAAC,CAAC;IACvB,MAAM,CAAC,aAAa,CAAC,IAAI,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAC;AAC5C,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,WAAW,GAAG,CAAC,QAAqB,EAAE,aAA0B,EAAE,EAAE;IAC/E,SAAS,CAAC,SAAS,CAAC,QAAQ,CAAC,CAAC;IAC9B,SAAS,CAAC,SAAS,CAAC,aAAa,CAAC,CAAC;IACnC,SAAS,CAAC,QAAQ,CAAC,aAAa,CAAC,CAAC;IAClC,SAAS,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC;AAChC,CAAC,CAAC;AAEF,MAAM,CAAC,MAAM,kBAAkB,GAAG,SAAS,CAAC,KAAK,CAAC;IAChD,kBAAkB,EAAE,uBAAuB,CAAC,KAAK;CAClD,CAAC,CAAC","sourcesContent":["import type { ReactElement } from 'react';\nimport { fireEvent, render as rtlRender } from '@testing-library/react';\nimport type { RenderOptions, RenderResult } from '@testing-library/react';\nimport type { queries, Queries } from '@testing-library/dom';\nimport userEvent, { PointerEventsCheckLevel } from '@testing-library/user-event';\n\nimport {\n Configuration,\n LiveLog,\n ModalManager,\n PopoverManager,\n Toaster\n} from '@pega/cosmos-react-core';\nimport type { ConfigurationProps, OmitStrict } from '@pega/cosmos-react-core';\n\ntype ProvidersProps = OmitStrict<ConfigurationProps, 'children'>;\n\nconst Providers =\n (configurationProps?: ProvidersProps) =>\n ({ children }: { children: ReactElement }) => (\n <Configuration {...configurationProps}>\n <LiveLog>\n <PopoverManager>\n <Toaster dismissAfter={5000}>\n <ModalManager>{children}</ModalManager>\n </Toaster>\n </PopoverManager>\n </LiveLog>\n </Configuration>\n );\n\n// Overloads adapted from types for RTL render.\nexport function render(\n content: ReactElement,\n options?: OmitStrict<RenderOptions, 'wrapper' | 'queries'>,\n configurationProps?: ProvidersProps\n): RenderResult;\n\nexport function render<\n Q extends Queries = typeof queries,\n Container extends Element | DocumentFragment = HTMLElement,\n BaseElement extends Element | DocumentFragment = Container\n>(\n content: ReactElement,\n options: OmitStrict<RenderOptions<Q, Container, BaseElement>, 'wrapper'>,\n configurationProps?: ProvidersProps\n): RenderResult<Q, Container, BaseElement>;\n\nexport function render<\n Q extends Queries = typeof queries,\n Container extends Element | DocumentFragment = HTMLElement,\n BaseElement extends Element | DocumentFragment = Container\n>(\n content: ReactElement,\n options:\n | OmitStrict<RenderOptions, 'wrapper' | 'queries'>\n | OmitStrict<RenderOptions<Q, Container, BaseElement>, 'wrapper'> = {},\n configurationProps?: ProvidersProps\n) {\n return rtlRender(content, {\n ...options,\n wrapper: Providers(configurationProps)\n } as RenderOptions) as RenderResult | RenderResult<Q, Container, BaseElement>;\n}\n\nexport const resizeWindow = (x: number, y: number) => {\n window.innerWidth = x;\n window.innerHeight = y;\n window.dispatchEvent(new Event('resize'));\n};\n\nexport const dragElement = (originEl: HTMLElement, destinationEl: HTMLElement) => {\n fireEvent.dragStart(originEl);\n fireEvent.dragEnter(destinationEl);\n fireEvent.dragOver(destinationEl);\n fireEvent.drop(destinationEl);\n};\n\nexport const userEventNoPointer = userEvent.setup({\n pointerEventsCheck: PointerEventsCheckLevel.Never\n});\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pega/cosmos-react-test-utils",
|
|
3
|
-
"version": "8.0.0-build.
|
|
3
|
+
"version": "8.0.0-build.30.0",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/pegasystems/cosmos-react.git",
|
|
@@ -22,16 +22,20 @@
|
|
|
22
22
|
"build": "tsc -b tsconfig.build.json"
|
|
23
23
|
},
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@pega/cosmos-react-core": "8.0.0-build.
|
|
26
|
-
"@testing-library/dom": "^
|
|
27
|
-
"@testing-library/react": "^
|
|
25
|
+
"@pega/cosmos-react-core": "8.0.0-build.30.0",
|
|
26
|
+
"@testing-library/dom": "^10.3.0",
|
|
27
|
+
"@testing-library/react": "^16.0.0",
|
|
28
|
+
"@testing-library/user-event": "^14.5.1",
|
|
28
29
|
"@types/jest": "^29.5.1",
|
|
29
|
-
"@types/react": "^17.0.62",
|
|
30
|
-
"@types/react-dom": "^17.0.20",
|
|
31
|
-
"
|
|
32
|
-
"
|
|
30
|
+
"@types/react": "^17.0.62 || ^18.3.3",
|
|
31
|
+
"@types/react-dom": "^17.0.20 || ^18.3.0",
|
|
32
|
+
"chalk": "^2.4.2",
|
|
33
|
+
"jest-styled-components": "^7.1.1",
|
|
34
|
+
"polished": "^4.1.0",
|
|
35
|
+
"react": "^17.0.0 || ^18.0.0",
|
|
36
|
+
"react-dom": "^17.0.0 || ^18.0.0"
|
|
33
37
|
},
|
|
34
38
|
"devDependencies": {
|
|
35
|
-
"typescript": "~5.
|
|
39
|
+
"typescript": "~5.5.4"
|
|
36
40
|
}
|
|
37
41
|
}
|