@kdcloudjs/kdesign 1.8.1 → 1.8.2
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/kdesign.css +1 -1
- package/dist/kdesign.css.map +1 -1
- package/dist/kdesign.js +3 -3
- package/dist/kdesign.js.map +1 -1
- package/dist/kdesign.min.css +1 -1
- package/dist/kdesign.min.js +2 -2
- package/dist/kdesign.min.js.map +1 -1
- package/es/image/preview-group.js +2 -2
- package/lib/image/preview-group.js +2 -2
- package/package.json +1 -1
|
@@ -108,12 +108,12 @@ var PreviewGroup = function PreviewGroup(_ref) {
|
|
|
108
108
|
onPrevious: onPrevious
|
|
109
109
|
};
|
|
110
110
|
return /*#__PURE__*/React.createElement(React.Fragment, null, images.length > 1 ? _mapInstanceProperty(_context3 = React.Children).call(_context3, children, function (image, index) {
|
|
111
|
-
var _a;
|
|
111
|
+
var _a, _b;
|
|
112
112
|
return /*#__PURE__*/React.cloneElement(image, {
|
|
113
113
|
key: image.key || index,
|
|
114
114
|
preview: false,
|
|
115
115
|
ref: refs[index],
|
|
116
|
-
onClick: onPreview.bind(null, index, (
|
|
116
|
+
onClick: ((_a = image === null || image === void 0 ? void 0 : image.props) === null || _a === void 0 ? void 0 : _a.preview) !== false ? onPreview.bind(null, index, (_b = image === null || image === void 0 ? void 0 : image.props) === null || _b === void 0 ? void 0 : _b.src) : undefined
|
|
117
117
|
});
|
|
118
118
|
}) : children, exit && /*#__PURE__*/React.createElement(Preview, _extends({}, previewProps)));
|
|
119
119
|
};
|
|
@@ -120,12 +120,12 @@ var PreviewGroup = function PreviewGroup(_ref) {
|
|
|
120
120
|
onPrevious: onPrevious
|
|
121
121
|
};
|
|
122
122
|
return /*#__PURE__*/React.createElement(React.Fragment, null, images.length > 1 ? (0, _map.default)(_context3 = React.Children).call(_context3, children, function (image, index) {
|
|
123
|
-
var _a;
|
|
123
|
+
var _a, _b;
|
|
124
124
|
return /*#__PURE__*/React.cloneElement(image, {
|
|
125
125
|
key: image.key || index,
|
|
126
126
|
preview: false,
|
|
127
127
|
ref: refs[index],
|
|
128
|
-
onClick: onPreview.bind(null, index, (
|
|
128
|
+
onClick: ((_a = image === null || image === void 0 ? void 0 : image.props) === null || _a === void 0 ? void 0 : _a.preview) !== false ? onPreview.bind(null, index, (_b = image === null || image === void 0 ? void 0 : image.props) === null || _b === void 0 ? void 0 : _b.src) : undefined
|
|
129
129
|
});
|
|
130
130
|
}) : children, exit && /*#__PURE__*/React.createElement(_preview.default, (0, _extends2.default)({}, previewProps)));
|
|
131
131
|
};
|