@spothero/ui 20.4.0 → 20.5.0-beta.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.
|
@@ -18,6 +18,7 @@ function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj &&
|
|
|
18
18
|
* @param {()=>void} [onClose] - Callback invoked to close the Modal. Not required, but strongly suggested.
|
|
19
19
|
* @param {('sm'|'md'|'lg')} [size] - The size of the modal. If unspecified, uses "md" styles.
|
|
20
20
|
* @param {object} [contentStyling] - Style props to be passed into the modal content
|
|
21
|
+
* @param {object} [overlayProps] - Props to be passed into the ModalOverlay component. See: https://github.com/chakra-ui/chakra-ui/blob/main/packages/components/modal/src/modal-overlay.tsx
|
|
21
22
|
* @param {boolean} [hasHeader] - Whether or not ModalHeader is a child. Will change the styling
|
|
22
23
|
* @param {boolean} [hasFooter] - Whether or not ModalFooter is a child. Will change the styling
|
|
23
24
|
* @param {React.ReactNode} [hideCloseButton] - Whether or not to show the close button
|
|
@@ -29,13 +30,14 @@ const Modal = /*#__PURE__*/(0, _react.forwardRef)((props, ref) => {
|
|
|
29
30
|
isMobile,
|
|
30
31
|
hideCloseButton,
|
|
31
32
|
hasHeader,
|
|
32
|
-
contentStyling = {}
|
|
33
|
+
contentStyling = {},
|
|
34
|
+
overlayProps = {}
|
|
33
35
|
} = props;
|
|
34
36
|
return /*#__PURE__*/_react.default.createElement(_react2.Modal, (0, _extends2.default)({
|
|
35
37
|
motionPreset: isMobile ? 'slideInBottom' : 'scale'
|
|
36
38
|
}, props, {
|
|
37
39
|
ref: ref
|
|
38
|
-
}), /*#__PURE__*/_react.default.createElement(_react2.ModalOverlay,
|
|
40
|
+
}), /*#__PURE__*/_react.default.createElement(_react2.ModalOverlay, overlayProps), /*#__PURE__*/_react.default.createElement(_react2.ModalContent, contentStyling, !hasHeader ? /*#__PURE__*/_react.default.createElement(_react2.Box, (0, _header.default)(props)) : null, hideCloseButton ? null : /*#__PURE__*/_react.default.createElement(_react2.ModalCloseButton, null), children));
|
|
39
41
|
});
|
|
40
42
|
var _default = Modal;
|
|
41
43
|
exports.default = _default;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@spothero/ui",
|
|
3
|
-
"version": "20.
|
|
3
|
+
"version": "20.5.0-beta.1",
|
|
4
4
|
"description": "SpotHero's React component UI library.",
|
|
5
5
|
"main": "./dist/components/index.js",
|
|
6
6
|
"exports": "./dist/components/index.js",
|
|
@@ -95,13 +95,13 @@
|
|
|
95
95
|
"webpack-merge": "5.1.4",
|
|
96
96
|
"css-loader": "5.1.3",
|
|
97
97
|
"sass-loader": "10.2.1",
|
|
98
|
-
"@spothero/babel-preset-spothero": "5.0.0",
|
|
99
98
|
"@spothero/browserslist-config": "4.0.0",
|
|
99
|
+
"@spothero/babel-preset-spothero": "5.0.0",
|
|
100
100
|
"@spothero/core": "7.0.0",
|
|
101
101
|
"@spothero/eslint-config": "6.0.0",
|
|
102
102
|
"@spothero/icons": "7.1.0",
|
|
103
|
-
"@spothero/npm-publisher": "7.0.0",
|
|
104
103
|
"@spothero/prettier-config": "4.0.0",
|
|
104
|
+
"@spothero/npm-publisher": "7.0.0",
|
|
105
105
|
"@spothero/stylelint-config": "6.0.0"
|
|
106
106
|
},
|
|
107
107
|
"dependencies": {
|
|
@@ -118,7 +118,7 @@
|
|
|
118
118
|
"regenerator-runtime": "0.13.7",
|
|
119
119
|
"ssr-window": "1.0.1",
|
|
120
120
|
"transitionEnd": "1.0.2",
|
|
121
|
-
"@spothero/utils": "
|
|
121
|
+
"@spothero/utils": "13.0.0"
|
|
122
122
|
},
|
|
123
123
|
"peerDependencies": {
|
|
124
124
|
"classnames": "^2.2.6",
|