@automattic/vip-design-system 0.17.0 → 0.17.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/build/system/NewConfirmationDialog/NewConfirmationDialog.js +1 -1
- package/build/system/NewDialog/DialogDescription.js +3 -2
- package/build/system/NewDialog/DialogTitle.js +4 -2
- package/build/system/NewDialog/NewDialog.js +2 -2
- package/package.json +1 -1
- package/src/system/NewConfirmationDialog/NewConfirmationDialog.js +1 -1
- package/src/system/NewDialog/DialogDescription.js +6 -2
- package/src/system/NewDialog/DialogTitle.js +6 -2
- package/src/system/NewDialog/NewDialog.js +2 -2
|
@@ -114,7 +114,7 @@ NewConfirmationDialog.propTypes = {
|
|
|
114
114
|
needsConfirm: _propTypes["default"].bool,
|
|
115
115
|
trigger: _propTypes["default"].node,
|
|
116
116
|
onConfirm: _propTypes["default"].func,
|
|
117
|
-
title: _propTypes["default"].node,
|
|
117
|
+
title: _propTypes["default"].node.isRequired,
|
|
118
118
|
body: _propTypes["default"].node,
|
|
119
119
|
label: _propTypes["default"].node
|
|
120
120
|
};
|
|
@@ -43,7 +43,8 @@ var DialogDescription = /*#__PURE__*/_react["default"].forwardRef(function (_ref
|
|
|
43
43
|
return (0, _jsxRuntime.jsx)(DialogPrimitive.Description, (0, _extends2["default"])({}, rest, {
|
|
44
44
|
ref: forwardedRef,
|
|
45
45
|
sx: {
|
|
46
|
-
margin: 0
|
|
46
|
+
margin: 0,
|
|
47
|
+
color: 'text'
|
|
47
48
|
},
|
|
48
49
|
children: text
|
|
49
50
|
}));
|
|
@@ -52,6 +53,6 @@ var DialogDescription = /*#__PURE__*/_react["default"].forwardRef(function (_ref
|
|
|
52
53
|
exports.DialogDescription = DialogDescription;
|
|
53
54
|
DialogDescription.displayName = 'DialogDescription';
|
|
54
55
|
DialogDescription.propTypes = {
|
|
55
|
-
description: _propTypes["default"].
|
|
56
|
+
description: _propTypes["default"].node,
|
|
56
57
|
hidden: _propTypes["default"].bool
|
|
57
58
|
};
|
|
@@ -40,7 +40,9 @@ var DialogTitle = function DialogTitle(_ref) {
|
|
|
40
40
|
|
|
41
41
|
return (0, _jsxRuntime.jsx)(DialogPrimitive.Title, {
|
|
42
42
|
sx: {
|
|
43
|
-
margin: 0
|
|
43
|
+
margin: 0,
|
|
44
|
+
fontSize: 3,
|
|
45
|
+
fontWeight: 500
|
|
44
46
|
},
|
|
45
47
|
children: titleNode
|
|
46
48
|
});
|
|
@@ -48,6 +50,6 @@ var DialogTitle = function DialogTitle(_ref) {
|
|
|
48
50
|
|
|
49
51
|
exports.DialogTitle = DialogTitle;
|
|
50
52
|
DialogTitle.propTypes = {
|
|
51
|
-
title: _propTypes["default"].
|
|
53
|
+
title: _propTypes["default"].node,
|
|
52
54
|
hidden: _propTypes["default"].bool
|
|
53
55
|
};
|
|
@@ -94,8 +94,8 @@ var NewDialog = function NewDialog(_ref) {
|
|
|
94
94
|
exports.NewDialog = NewDialog;
|
|
95
95
|
NewDialog.propTypes = {
|
|
96
96
|
trigger: _propTypes["default"].node.isRequired,
|
|
97
|
-
title: _propTypes["default"].
|
|
98
|
-
description: _propTypes["default"].
|
|
97
|
+
title: _propTypes["default"].node.isRequired,
|
|
98
|
+
description: _propTypes["default"].node.isRequired,
|
|
99
99
|
content: _propTypes["default"].node,
|
|
100
100
|
showHeading: _propTypes["default"].bool,
|
|
101
101
|
disabled: _propTypes["default"].bool,
|
package/package.json
CHANGED
|
@@ -21,7 +21,11 @@ export const DialogDescription = React.forwardRef(
|
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
return (
|
|
24
|
-
<DialogPrimitive.Description
|
|
24
|
+
<DialogPrimitive.Description
|
|
25
|
+
{ ...rest }
|
|
26
|
+
ref={ forwardedRef }
|
|
27
|
+
sx={ { margin: 0, color: 'text' } }
|
|
28
|
+
>
|
|
25
29
|
{ text }
|
|
26
30
|
</DialogPrimitive.Description>
|
|
27
31
|
);
|
|
@@ -31,6 +35,6 @@ export const DialogDescription = React.forwardRef(
|
|
|
31
35
|
DialogDescription.displayName = 'DialogDescription';
|
|
32
36
|
|
|
33
37
|
DialogDescription.propTypes = {
|
|
34
|
-
description: PropTypes.
|
|
38
|
+
description: PropTypes.node,
|
|
35
39
|
hidden: PropTypes.bool,
|
|
36
40
|
};
|
|
@@ -18,10 +18,14 @@ export const DialogTitle = ( { title, hidden = false } ) => {
|
|
|
18
18
|
titleNode = <ScreenReaderText>{ titleNode }</ScreenReaderText>;
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
return
|
|
21
|
+
return (
|
|
22
|
+
<DialogPrimitive.Title sx={ { margin: 0, fontSize: 3, fontWeight: 500 } }>
|
|
23
|
+
{ titleNode }
|
|
24
|
+
</DialogPrimitive.Title>
|
|
25
|
+
);
|
|
22
26
|
};
|
|
23
27
|
|
|
24
28
|
DialogTitle.propTypes = {
|
|
25
|
-
title: PropTypes.
|
|
29
|
+
title: PropTypes.node,
|
|
26
30
|
hidden: PropTypes.bool,
|
|
27
31
|
};
|
|
@@ -64,8 +64,8 @@ export const NewDialog = ( {
|
|
|
64
64
|
|
|
65
65
|
NewDialog.propTypes = {
|
|
66
66
|
trigger: PropTypes.node.isRequired,
|
|
67
|
-
title: PropTypes.
|
|
68
|
-
description: PropTypes.
|
|
67
|
+
title: PropTypes.node.isRequired,
|
|
68
|
+
description: PropTypes.node.isRequired,
|
|
69
69
|
content: PropTypes.node,
|
|
70
70
|
showHeading: PropTypes.bool,
|
|
71
71
|
disabled: PropTypes.bool,
|