carbon-react 142.7.0 → 142.8.1
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/esm/__internal__/validations/validation-icon.component.js +1 -2
- package/esm/__spec_helper__/mock-match-media.d.ts +1 -1
- package/esm/components/dialog/dialog.component.js +12 -4
- package/esm/components/dialog/dialog.config.d.ts +1 -1
- package/esm/components/dialog/dialog.config.js +1 -1
- package/esm/components/dialog/dialog.style.d.ts +5 -1
- package/esm/components/dialog/dialog.style.js +29 -3
- package/esm/components/menu/__internal__/submenu/submenu.component.js +7 -0
- package/lib/__internal__/validations/validation-icon.component.js +1 -2
- package/lib/__spec_helper__/mock-match-media.d.ts +1 -1
- package/lib/components/dialog/dialog.component.js +11 -3
- package/lib/components/dialog/dialog.config.d.ts +1 -1
- package/lib/components/dialog/dialog.config.js +1 -1
- package/lib/components/dialog/dialog.style.d.ts +5 -1
- package/lib/components/dialog/dialog.style.js +29 -3
- package/lib/components/menu/__internal__/submenu/submenu.component.js +7 -0
- package/package.json +10 -8
|
@@ -69,8 +69,7 @@ export const ValidationIcon = ({
|
|
|
69
69
|
setTriggeredByIcon(false);
|
|
70
70
|
if (onBlur) onBlur(e);
|
|
71
71
|
},
|
|
72
|
-
isPartOfInput: isPartOfInput
|
|
73
|
-
"data-role": `validation-icon-${validationType}`
|
|
72
|
+
isPartOfInput: isPartOfInput
|
|
74
73
|
}, filterStyledSystemMarginProps(rest)), /*#__PURE__*/React.createElement(Icon, {
|
|
75
74
|
"aria-describedby": validationTooltipId.current,
|
|
76
75
|
key: `${validationType}-icon`,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
|
|
2
|
-
import React, { useRef, useEffect, useLayoutEffect, useCallback, useImperativeHandle, forwardRef } from "react";
|
|
2
|
+
import React, { useRef, useEffect, useLayoutEffect, useCallback, useImperativeHandle, forwardRef, useState } from "react";
|
|
3
3
|
import PropTypes from "prop-types";
|
|
4
4
|
import createGuid from "../../__internal__/utils/helpers/guid";
|
|
5
5
|
import Modal from "../modal";
|
|
@@ -46,6 +46,8 @@ const Dialog = /*#__PURE__*/forwardRef(({
|
|
|
46
46
|
const containerRef = useRef(null);
|
|
47
47
|
const innerContentRef = useRef(null);
|
|
48
48
|
const titleRef = useRef(null);
|
|
49
|
+
const [breakpointOffset, setBreakpointOffset] = useState(undefined);
|
|
50
|
+
const isDialogMaximised = size === "maximise";
|
|
49
51
|
const listenersAdded = useRef(false);
|
|
50
52
|
const {
|
|
51
53
|
current: titleId
|
|
@@ -78,9 +80,15 @@ const Dialog = /*#__PURE__*/forwardRef(({
|
|
|
78
80
|
if (midPointX < 0) {
|
|
79
81
|
midPointX = 0;
|
|
80
82
|
}
|
|
83
|
+
if (isDialogMaximised) {
|
|
84
|
+
const breakPoint = window.innerWidth > 960 ? 32 : 16;
|
|
85
|
+
midPointX = breakPoint;
|
|
86
|
+
midPointY = breakPoint;
|
|
87
|
+
setBreakpointOffset(breakPoint);
|
|
88
|
+
}
|
|
81
89
|
containerRef.current.style.top = `${midPointY}px`;
|
|
82
90
|
containerRef.current.style.left = `${midPointX}px`;
|
|
83
|
-
}, []);
|
|
91
|
+
}, [size]);
|
|
84
92
|
useResizeObserver(innerContentRef, centerDialog, !open);
|
|
85
93
|
const addListeners = useCallback(() => {
|
|
86
94
|
/* istanbul ignore else */
|
|
@@ -172,7 +180,7 @@ const Dialog = /*#__PURE__*/forwardRef(({
|
|
|
172
180
|
"data-role": dataRole,
|
|
173
181
|
"aria-modal": isTopModal ? true : undefined,
|
|
174
182
|
ref: containerRef,
|
|
175
|
-
topMargin: TOP_MARGIN
|
|
183
|
+
topMargin: isDialogMaximised && breakpointOffset ? breakpointOffset * 2 : TOP_MARGIN
|
|
176
184
|
}, dialogProps, {
|
|
177
185
|
role: role,
|
|
178
186
|
tabIndex: -1
|
|
@@ -243,7 +251,7 @@ if (process.env.NODE_ENV !== "production") {
|
|
|
243
251
|
"open": PropTypes.bool.isRequired,
|
|
244
252
|
"role": PropTypes.string,
|
|
245
253
|
"showCloseIcon": PropTypes.bool,
|
|
246
|
-
"size": PropTypes.oneOf(["auto", "extra-large", "extra-small", "large", "medium-large", "medium-small", "medium", "small"]),
|
|
254
|
+
"size": PropTypes.oneOf(["auto", "extra-large", "extra-small", "large", "maximise", "medium-large", "medium-small", "medium", "small"]),
|
|
247
255
|
"subtitle": PropTypes.node,
|
|
248
256
|
"timeout": PropTypes.number,
|
|
249
257
|
"title": PropTypes.node,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare const DIALOG_SIZES: readonly ["auto", "extra-small", "small", "medium-small", "medium", "medium-large", "large", "extra-large"];
|
|
1
|
+
export declare const DIALOG_SIZES: readonly ["auto", "extra-small", "small", "medium-small", "medium", "medium-large", "large", "extra-large", "maximise"];
|
|
2
2
|
export declare const TOP_MARGIN = 20;
|
|
3
3
|
export declare const CONTENT_TOP_PADDING = 24;
|
|
4
4
|
export declare const HORIZONTAL_PADDING = 32;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export const DIALOG_SIZES = ["auto", "extra-small", "small", "medium-small", "medium", "medium-large", "large", "extra-large"];
|
|
1
|
+
export const DIALOG_SIZES = ["auto", "extra-small", "small", "medium-small", "medium", "medium-large", "large", "extra-large", "maximise"];
|
|
2
2
|
export const TOP_MARGIN = 20;
|
|
3
3
|
export const CONTENT_TOP_PADDING = 24;
|
|
4
4
|
export const HORIZONTAL_PADDING = 32;
|
|
@@ -6,7 +6,11 @@ declare type StyledDialogProps = {
|
|
|
6
6
|
dialogHeight?: string;
|
|
7
7
|
backgroundColor: string;
|
|
8
8
|
};
|
|
9
|
-
declare const StyledDialog: import("styled-components").StyledComponent<"div", any,
|
|
9
|
+
declare const StyledDialog: import("styled-components").StyledComponent<"div", any, {
|
|
10
|
+
isDialogMaximised: boolean;
|
|
11
|
+
isDialogMaximisedSmallViewport: boolean;
|
|
12
|
+
isDialogMaximisedLargeViewport: boolean;
|
|
13
|
+
} & StyledDialogProps & ContentPaddingInterface, "isDialogMaximised" | "isDialogMaximisedSmallViewport" | "isDialogMaximisedLargeViewport">;
|
|
10
14
|
declare type StyledDialogTitleProps = {
|
|
11
15
|
showCloseIcon?: boolean;
|
|
12
16
|
hasSubtitle?: boolean;
|
|
@@ -20,7 +20,19 @@ const calculatePaddingTopInnerContent = ({
|
|
|
20
20
|
py,
|
|
21
21
|
p
|
|
22
22
|
}) => [py, p].some(padding => padding !== undefined) ? 0 : `${CONTENT_TOP_PADDING}px`;
|
|
23
|
-
const StyledDialog = styled.div
|
|
23
|
+
const StyledDialog = styled.div.attrs(({
|
|
24
|
+
topMargin,
|
|
25
|
+
size
|
|
26
|
+
}) => {
|
|
27
|
+
const isDialogMaximised = size === "maximise";
|
|
28
|
+
const isDialogMaximisedSmallViewport = topMargin === 32;
|
|
29
|
+
const isDialogMaximisedLargeViewport = topMargin === 64;
|
|
30
|
+
return {
|
|
31
|
+
isDialogMaximised,
|
|
32
|
+
isDialogMaximisedSmallViewport,
|
|
33
|
+
isDialogMaximisedLargeViewport
|
|
34
|
+
};
|
|
35
|
+
})`
|
|
24
36
|
box-shadow: var(--boxShadow300);
|
|
25
37
|
display: flex;
|
|
26
38
|
flex-direction: column;
|
|
@@ -33,6 +45,9 @@ const StyledDialog = styled.div`
|
|
|
33
45
|
max-height: ${({
|
|
34
46
|
topMargin
|
|
35
47
|
}) => `calc(100vh - ${topMargin}px)`};
|
|
48
|
+
${({
|
|
49
|
+
isDialogMaximised
|
|
50
|
+
}) => isDialogMaximised && "height: 100%"};
|
|
36
51
|
|
|
37
52
|
&:focus {
|
|
38
53
|
outline: none;
|
|
@@ -45,9 +60,10 @@ const StyledDialog = styled.div`
|
|
|
45
60
|
`}
|
|
46
61
|
|
|
47
62
|
${({
|
|
48
|
-
size
|
|
63
|
+
size,
|
|
64
|
+
topMargin
|
|
49
65
|
}) => size && css`
|
|
50
|
-
max-width: ${dialogSizes[size]};
|
|
66
|
+
max-width: ${size === "maximise" ? `calc(100vw - ${topMargin}px)` : dialogSizes[size]};
|
|
51
67
|
width: 100%;
|
|
52
68
|
`}
|
|
53
69
|
|
|
@@ -57,7 +73,17 @@ const StyledDialog = styled.div`
|
|
|
57
73
|
height: ${dialogHeight}px;
|
|
58
74
|
`}
|
|
59
75
|
|
|
76
|
+
/* We're overriding the max-height on the form content to account for a larger height when in a smaller viewport.
|
|
77
|
+
TODO: Remove this upon the completion of FE-6643. */
|
|
60
78
|
${StyledForm} {
|
|
79
|
+
${({
|
|
80
|
+
isDialogMaximised,
|
|
81
|
+
isDialogMaximisedSmallViewport
|
|
82
|
+
}) => isDialogMaximised && css`
|
|
83
|
+
${isDialogMaximisedSmallViewport && "max-height: calc(100vh - 184px);"}
|
|
84
|
+
height: 100%;
|
|
85
|
+
`}
|
|
86
|
+
|
|
61
87
|
padding-bottom: 0px;
|
|
62
88
|
box-sizing: border-box;
|
|
63
89
|
}
|
|
@@ -76,6 +76,13 @@ const Submenu = /*#__PURE__*/React.forwardRef(({
|
|
|
76
76
|
}
|
|
77
77
|
startCharacterTimeout();
|
|
78
78
|
}, [startCharacterTimeout]);
|
|
79
|
+
useEffect(() => {
|
|
80
|
+
return () => {
|
|
81
|
+
if (characterTimer.current) {
|
|
82
|
+
clearTimeout(characterTimer.current);
|
|
83
|
+
}
|
|
84
|
+
};
|
|
85
|
+
}, []);
|
|
79
86
|
const openSubmenu = useCallback(() => {
|
|
80
87
|
setSubmenuOpen(true);
|
|
81
88
|
setOpenSubmenuId(submenuId.current);
|
|
@@ -78,8 +78,7 @@ const ValidationIcon = ({
|
|
|
78
78
|
setTriggeredByIcon(false);
|
|
79
79
|
if (onBlur) onBlur(e);
|
|
80
80
|
},
|
|
81
|
-
isPartOfInput: isPartOfInput
|
|
82
|
-
"data-role": `validation-icon-${validationType}`
|
|
81
|
+
isPartOfInput: isPartOfInput
|
|
83
82
|
}, (0, _utils.filterStyledSystemMarginProps)(rest)), /*#__PURE__*/_react.default.createElement(_icon.default, {
|
|
84
83
|
"aria-describedby": validationTooltipId.current,
|
|
85
84
|
key: `${validationType}-icon`,
|
|
@@ -55,6 +55,8 @@ const Dialog = exports.Dialog = /*#__PURE__*/(0, _react.forwardRef)(({
|
|
|
55
55
|
const containerRef = (0, _react.useRef)(null);
|
|
56
56
|
const innerContentRef = (0, _react.useRef)(null);
|
|
57
57
|
const titleRef = (0, _react.useRef)(null);
|
|
58
|
+
const [breakpointOffset, setBreakpointOffset] = (0, _react.useState)(undefined);
|
|
59
|
+
const isDialogMaximised = size === "maximise";
|
|
58
60
|
const listenersAdded = (0, _react.useRef)(false);
|
|
59
61
|
const {
|
|
60
62
|
current: titleId
|
|
@@ -87,9 +89,15 @@ const Dialog = exports.Dialog = /*#__PURE__*/(0, _react.forwardRef)(({
|
|
|
87
89
|
if (midPointX < 0) {
|
|
88
90
|
midPointX = 0;
|
|
89
91
|
}
|
|
92
|
+
if (isDialogMaximised) {
|
|
93
|
+
const breakPoint = window.innerWidth > 960 ? 32 : 16;
|
|
94
|
+
midPointX = breakPoint;
|
|
95
|
+
midPointY = breakPoint;
|
|
96
|
+
setBreakpointOffset(breakPoint);
|
|
97
|
+
}
|
|
90
98
|
containerRef.current.style.top = `${midPointY}px`;
|
|
91
99
|
containerRef.current.style.left = `${midPointX}px`;
|
|
92
|
-
}, []);
|
|
100
|
+
}, [size]);
|
|
93
101
|
(0, _useResizeObserver.default)(innerContentRef, centerDialog, !open);
|
|
94
102
|
const addListeners = (0, _react.useCallback)(() => {
|
|
95
103
|
/* istanbul ignore else */
|
|
@@ -181,7 +189,7 @@ const Dialog = exports.Dialog = /*#__PURE__*/(0, _react.forwardRef)(({
|
|
|
181
189
|
"data-role": dataRole,
|
|
182
190
|
"aria-modal": isTopModal ? true : undefined,
|
|
183
191
|
ref: containerRef,
|
|
184
|
-
topMargin: _dialog2.TOP_MARGIN
|
|
192
|
+
topMargin: isDialogMaximised && breakpointOffset ? breakpointOffset * 2 : _dialog2.TOP_MARGIN
|
|
185
193
|
}, dialogProps, {
|
|
186
194
|
role: role,
|
|
187
195
|
tabIndex: -1
|
|
@@ -252,7 +260,7 @@ if (process.env.NODE_ENV !== "production") {
|
|
|
252
260
|
"open": _propTypes.default.bool.isRequired,
|
|
253
261
|
"role": _propTypes.default.string,
|
|
254
262
|
"showCloseIcon": _propTypes.default.bool,
|
|
255
|
-
"size": _propTypes.default.oneOf(["auto", "extra-large", "extra-small", "large", "medium-large", "medium-small", "medium", "small"]),
|
|
263
|
+
"size": _propTypes.default.oneOf(["auto", "extra-large", "extra-small", "large", "maximise", "medium-large", "medium-small", "medium", "small"]),
|
|
256
264
|
"subtitle": _propTypes.default.node,
|
|
257
265
|
"timeout": _propTypes.default.number,
|
|
258
266
|
"title": _propTypes.default.node,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare const DIALOG_SIZES: readonly ["auto", "extra-small", "small", "medium-small", "medium", "medium-large", "large", "extra-large"];
|
|
1
|
+
export declare const DIALOG_SIZES: readonly ["auto", "extra-small", "small", "medium-small", "medium", "medium-large", "large", "extra-large", "maximise"];
|
|
2
2
|
export declare const TOP_MARGIN = 20;
|
|
3
3
|
export declare const CONTENT_TOP_PADDING = 24;
|
|
4
4
|
export declare const HORIZONTAL_PADDING = 32;
|
|
@@ -4,7 +4,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.TOP_MARGIN = exports.HORIZONTAL_PADDING = exports.DIALOG_SIZES = exports.CONTENT_TOP_PADDING = exports.CONTENT_BOTTOM_PADDING = void 0;
|
|
7
|
-
const DIALOG_SIZES = exports.DIALOG_SIZES = ["auto", "extra-small", "small", "medium-small", "medium", "medium-large", "large", "extra-large"];
|
|
7
|
+
const DIALOG_SIZES = exports.DIALOG_SIZES = ["auto", "extra-small", "small", "medium-small", "medium", "medium-large", "large", "extra-large", "maximise"];
|
|
8
8
|
const TOP_MARGIN = exports.TOP_MARGIN = 20;
|
|
9
9
|
const CONTENT_TOP_PADDING = exports.CONTENT_TOP_PADDING = 24;
|
|
10
10
|
const HORIZONTAL_PADDING = exports.HORIZONTAL_PADDING = 32;
|
|
@@ -6,7 +6,11 @@ declare type StyledDialogProps = {
|
|
|
6
6
|
dialogHeight?: string;
|
|
7
7
|
backgroundColor: string;
|
|
8
8
|
};
|
|
9
|
-
declare const StyledDialog: import("styled-components").StyledComponent<"div", any,
|
|
9
|
+
declare const StyledDialog: import("styled-components").StyledComponent<"div", any, {
|
|
10
|
+
isDialogMaximised: boolean;
|
|
11
|
+
isDialogMaximisedSmallViewport: boolean;
|
|
12
|
+
isDialogMaximisedLargeViewport: boolean;
|
|
13
|
+
} & StyledDialogProps & ContentPaddingInterface, "isDialogMaximised" | "isDialogMaximisedSmallViewport" | "isDialogMaximisedLargeViewport">;
|
|
10
14
|
declare type StyledDialogTitleProps = {
|
|
11
15
|
showCloseIcon?: boolean;
|
|
12
16
|
hasSubtitle?: boolean;
|
|
@@ -29,7 +29,19 @@ const calculatePaddingTopInnerContent = ({
|
|
|
29
29
|
py,
|
|
30
30
|
p
|
|
31
31
|
}) => [py, p].some(padding => padding !== undefined) ? 0 : `${_dialog.CONTENT_TOP_PADDING}px`;
|
|
32
|
-
const StyledDialog = exports.StyledDialog = _styledComponents.default.div
|
|
32
|
+
const StyledDialog = exports.StyledDialog = _styledComponents.default.div.attrs(({
|
|
33
|
+
topMargin,
|
|
34
|
+
size
|
|
35
|
+
}) => {
|
|
36
|
+
const isDialogMaximised = size === "maximise";
|
|
37
|
+
const isDialogMaximisedSmallViewport = topMargin === 32;
|
|
38
|
+
const isDialogMaximisedLargeViewport = topMargin === 64;
|
|
39
|
+
return {
|
|
40
|
+
isDialogMaximised,
|
|
41
|
+
isDialogMaximisedSmallViewport,
|
|
42
|
+
isDialogMaximisedLargeViewport
|
|
43
|
+
};
|
|
44
|
+
})`
|
|
33
45
|
box-shadow: var(--boxShadow300);
|
|
34
46
|
display: flex;
|
|
35
47
|
flex-direction: column;
|
|
@@ -42,6 +54,9 @@ const StyledDialog = exports.StyledDialog = _styledComponents.default.div`
|
|
|
42
54
|
max-height: ${({
|
|
43
55
|
topMargin
|
|
44
56
|
}) => `calc(100vh - ${topMargin}px)`};
|
|
57
|
+
${({
|
|
58
|
+
isDialogMaximised
|
|
59
|
+
}) => isDialogMaximised && "height: 100%"};
|
|
45
60
|
|
|
46
61
|
&:focus {
|
|
47
62
|
outline: none;
|
|
@@ -54,9 +69,10 @@ const StyledDialog = exports.StyledDialog = _styledComponents.default.div`
|
|
|
54
69
|
`}
|
|
55
70
|
|
|
56
71
|
${({
|
|
57
|
-
size
|
|
72
|
+
size,
|
|
73
|
+
topMargin
|
|
58
74
|
}) => size && (0, _styledComponents.css)`
|
|
59
|
-
max-width: ${dialogSizes[size]};
|
|
75
|
+
max-width: ${size === "maximise" ? `calc(100vw - ${topMargin}px)` : dialogSizes[size]};
|
|
60
76
|
width: 100%;
|
|
61
77
|
`}
|
|
62
78
|
|
|
@@ -66,7 +82,17 @@ const StyledDialog = exports.StyledDialog = _styledComponents.default.div`
|
|
|
66
82
|
height: ${dialogHeight}px;
|
|
67
83
|
`}
|
|
68
84
|
|
|
85
|
+
/* We're overriding the max-height on the form content to account for a larger height when in a smaller viewport.
|
|
86
|
+
TODO: Remove this upon the completion of FE-6643. */
|
|
69
87
|
${_form.StyledForm} {
|
|
88
|
+
${({
|
|
89
|
+
isDialogMaximised,
|
|
90
|
+
isDialogMaximisedSmallViewport
|
|
91
|
+
}) => isDialogMaximised && (0, _styledComponents.css)`
|
|
92
|
+
${isDialogMaximisedSmallViewport && "max-height: calc(100vh - 184px);"}
|
|
93
|
+
height: 100%;
|
|
94
|
+
`}
|
|
95
|
+
|
|
70
96
|
padding-bottom: 0px;
|
|
71
97
|
box-sizing: border-box;
|
|
72
98
|
}
|
|
@@ -85,6 +85,13 @@ const Submenu = /*#__PURE__*/_react.default.forwardRef(({
|
|
|
85
85
|
}
|
|
86
86
|
startCharacterTimeout();
|
|
87
87
|
}, [startCharacterTimeout]);
|
|
88
|
+
(0, _react.useEffect)(() => {
|
|
89
|
+
return () => {
|
|
90
|
+
if (characterTimer.current) {
|
|
91
|
+
clearTimeout(characterTimer.current);
|
|
92
|
+
}
|
|
93
|
+
};
|
|
94
|
+
}, []);
|
|
88
95
|
const openSubmenu = (0, _react.useCallback)(() => {
|
|
89
96
|
setSubmenuOpen(true);
|
|
90
97
|
setOpenSubmenuId(submenuId.current);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "carbon-react",
|
|
3
|
-
"version": "142.
|
|
3
|
+
"version": "142.8.1",
|
|
4
4
|
"description": "A library of reusable React components for easily building user interfaces.",
|
|
5
5
|
"files": [
|
|
6
6
|
"lib",
|
|
@@ -11,8 +11,8 @@
|
|
|
11
11
|
"scripts": {
|
|
12
12
|
"start": "node ./scripts/check_node_version.mjs && cross-env storybook dev -p 9001 -c .storybook",
|
|
13
13
|
"start:debug-theme": "cross-env STORYBOOK_DEBUG_THEME=true npm run start",
|
|
14
|
-
"test": "jest --config=./jest.config.
|
|
15
|
-
"test-update": "jest --config=./jest.config.
|
|
14
|
+
"test": "jest --config=./jest.config.ts",
|
|
15
|
+
"test-update": "jest --config=./jest.config.ts --updateSnapshot",
|
|
16
16
|
"format": "prettier --write './{src,playwright}/**/*.{js,jsx,ts,tsx}'",
|
|
17
17
|
"lint": "eslint ./src ./playwright",
|
|
18
18
|
"build": "node ./scripts/build.js",
|
|
@@ -90,7 +90,7 @@
|
|
|
90
90
|
"@storybook/theming": "^8.2.6",
|
|
91
91
|
"@storybook/types": "^8.2.6",
|
|
92
92
|
"@testing-library/dom": "^9.0.0",
|
|
93
|
-
"@testing-library/jest-dom": "^5.
|
|
93
|
+
"@testing-library/jest-dom": "^6.5.0",
|
|
94
94
|
"@testing-library/react": "^12.1.5",
|
|
95
95
|
"@testing-library/react-hooks": "^8.0.1",
|
|
96
96
|
"@testing-library/user-event": "^14.5.1",
|
|
@@ -99,7 +99,7 @@
|
|
|
99
99
|
"@types/enzyme": "3.10.13",
|
|
100
100
|
"@types/glob": "^8.1.0",
|
|
101
101
|
"@types/invariant": "^2.2.37",
|
|
102
|
-
"@types/jest": "^
|
|
102
|
+
"@types/jest": "^29.5.0",
|
|
103
103
|
"@types/lodash": "^4.14.202",
|
|
104
104
|
"@types/node": "^20.9.0",
|
|
105
105
|
"@types/react": "^17.0.59",
|
|
@@ -149,11 +149,12 @@
|
|
|
149
149
|
"file-loader": "^6.2.0",
|
|
150
150
|
"fs-extra": "^10.1.0",
|
|
151
151
|
"husky": "^8.0.3",
|
|
152
|
-
"jest": "^
|
|
152
|
+
"jest": "^29.5.0",
|
|
153
153
|
"jest-canvas-mock": "^2.5.2",
|
|
154
|
-
"jest-environment-jsdom": "^
|
|
154
|
+
"jest-environment-jsdom": "^29.5.0",
|
|
155
155
|
"jest-fetch-mock": "^3.0.3",
|
|
156
156
|
"jest-styled-components": "^6.3.4",
|
|
157
|
+
"jsdom": "^21.1.0",
|
|
157
158
|
"jsdom-testing-mocks": "^1.11.0",
|
|
158
159
|
"lint-staged": "^11.2.6",
|
|
159
160
|
"mockdate": "^2.0.5",
|
|
@@ -205,7 +206,8 @@
|
|
|
205
206
|
},
|
|
206
207
|
"overrides": {
|
|
207
208
|
"playwright-core": "$@playwright/experimental-ct-react17",
|
|
208
|
-
"@testing-library/dom": "$@testing-library/dom"
|
|
209
|
+
"@testing-library/dom": "$@testing-library/dom",
|
|
210
|
+
"jsdom": "$jsdom"
|
|
209
211
|
},
|
|
210
212
|
"config": {
|
|
211
213
|
"commitizen": {
|