@chaoswise/ui 2.3.3 → 2.3.5
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/AbreastLayout/index.js +2 -2
- package/lib/CWCascader/rc-cascader/OptionList/index.js +2 -2
- package/lib/CWCascader/rc-cascader/hooks/useDisplayValues.js +2 -2
- package/lib/CWMessage/index.js +5 -2
- package/lib/CWRangePicker/DropdownMenu/index.js +6 -3
- package/lib/CWRangePicker/Refresh/index.js +9 -16
- package/lib/CWRangePicker/TimeSpan/index.js +16 -35
- package/lib/CWRangePicker/index.js +86 -79
- package/lib/CWRangePicker/locale/en_US.js +3 -2
- package/lib/CWRangePicker/locale/zh_CN.js +3 -2
- package/lib/CWRangePicker/utils/index.js +69 -34
- package/lib/CWSelect/DragTag/index.js +52 -0
- package/lib/CWSelect/Tag.js +3 -11
- package/lib/CWSelect/index.js +8 -45
- package/lib/CWTable/EditLine.js +1 -1
- package/lib/CWTree/index.js +11 -6
- package/lib/Input/InputComponent.js +2 -2
- package/lib/Pagination/index.js +9 -3
- package/lib/QuickTransfer/CheckList.js +1 -1
- package/lib/QuickTransfer/NoDrag.js +1 -1
- package/lib/QuickTransfer/NotDragList.js +4 -5
- package/lib/QuickTransfer/TopicList.js +3 -3
- package/lib/QuickTransfer/index.js +7 -2
- package/lib/QuickTransfer/utils.js +21 -4
- package/lib/SearchBar/index.js +5 -3
- package/lib/SingleSpa/index.js +2 -2
- package/lib/ThemeProvider/utils.js +1 -1
- package/lib/WangEditor/wangEditor.js +2 -2
- package/package.json +2 -2
|
@@ -251,6 +251,11 @@ var QuickTransfer = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
251
251
|
});
|
|
252
252
|
findValue && finalCheckValue.push(findValue);
|
|
253
253
|
});
|
|
254
|
+
finalCheckValue = finalCheckValue.filter(function (i) {
|
|
255
|
+
return i.disabled;
|
|
256
|
+
}).concat(finalCheckValue.filter(function (i) {
|
|
257
|
+
return !i.disabled;
|
|
258
|
+
}));
|
|
254
259
|
setCheckValue(finalCheckValue);
|
|
255
260
|
}
|
|
256
261
|
//回显table
|
|
@@ -684,7 +689,7 @@ var QuickTransfer = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
684
689
|
}, treeRest));
|
|
685
690
|
}
|
|
686
691
|
};
|
|
687
|
-
var
|
|
692
|
+
var renderRightList = searchCheckedValue.length === 0 ? /*#__PURE__*/React.createElement(_Empty, {
|
|
688
693
|
description: localeObj["pleaseSelectFromLeft"]
|
|
689
694
|
}) : useDndProvider ? /*#__PURE__*/React.createElement(CheckList, {
|
|
690
695
|
checkValue: searchCheckedValue,
|
|
@@ -754,7 +759,7 @@ var QuickTransfer = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
754
759
|
className: "cw-transfer-right-header-clear"
|
|
755
760
|
}, localeObj.clear)) : /*#__PURE__*/React.createElement(Fragment, null, rightHeader)), /*#__PURE__*/React.createElement("div", {
|
|
756
761
|
className: "cw-transfer-right-main-wrapper"
|
|
757
|
-
},
|
|
762
|
+
}, renderRightList)), rightFooter && /*#__PURE__*/React.createElement("div", {
|
|
758
763
|
className: "cw-transfer-footer"
|
|
759
764
|
}, rightFooter))));
|
|
760
765
|
});
|
|
@@ -115,7 +115,9 @@ export var filterObj = function filterObj(arr) {
|
|
|
115
115
|
export var getNotSelectKeys = function getNotSelectKeys(arr) {
|
|
116
116
|
var keys = [];
|
|
117
117
|
arr.map(function (item) {
|
|
118
|
-
|
|
118
|
+
var _ref = item.props || {},
|
|
119
|
+
disabled = _ref.disabled;
|
|
120
|
+
!disabled && keys.push(item.key);
|
|
119
121
|
if (item.props.children && item.props.children.length > 0) {
|
|
120
122
|
keys = keys.concat(getNotSelectKeys(item.props.children));
|
|
121
123
|
}
|
|
@@ -125,7 +127,9 @@ export var getNotSelectKeys = function getNotSelectKeys(arr) {
|
|
|
125
127
|
export var getKeysAndTitle = function getKeysAndTitle(arr) {
|
|
126
128
|
var keys = [];
|
|
127
129
|
arr.map(function (item) {
|
|
128
|
-
|
|
130
|
+
var _ref2 = item.props || {},
|
|
131
|
+
disabled = _ref2.disabled;
|
|
132
|
+
!disabled && keys.push({
|
|
129
133
|
key: item.key,
|
|
130
134
|
title: item.props.title
|
|
131
135
|
});
|
|
@@ -141,7 +145,9 @@ export var getBottomKey = function getBottomKey(arr) {
|
|
|
141
145
|
if (item.props.children && item.props.children.length > 0) {
|
|
142
146
|
keys = keys.concat(getBottomKey(item.props.children));
|
|
143
147
|
} else {
|
|
144
|
-
|
|
148
|
+
var _ref3 = item.props || {},
|
|
149
|
+
disabled = _ref3.disabled;
|
|
150
|
+
!disabled && keys.push({
|
|
145
151
|
key: item.key,
|
|
146
152
|
title: item.props.title,
|
|
147
153
|
children: item.props.children
|
|
@@ -159,7 +165,8 @@ export var renderLeafNodetree = function renderLeafNodetree(targetKeys, dataSour
|
|
|
159
165
|
} else {
|
|
160
166
|
newArr.push({
|
|
161
167
|
key: item.key,
|
|
162
|
-
title: item.title
|
|
168
|
+
title: item.title,
|
|
169
|
+
disabled: item.disabled
|
|
163
170
|
});
|
|
164
171
|
}
|
|
165
172
|
});
|
|
@@ -169,6 +176,11 @@ export var renderLeafNodetree = function renderLeafNodetree(targetKeys, dataSour
|
|
|
169
176
|
});
|
|
170
177
|
findValue && finalCheckValue.push(findValue);
|
|
171
178
|
});
|
|
179
|
+
finalCheckValue = finalCheckValue.filter(function (i) {
|
|
180
|
+
return i.disabled;
|
|
181
|
+
}).concat(finalCheckValue.filter(function (i) {
|
|
182
|
+
return !i.disabled;
|
|
183
|
+
}));
|
|
172
184
|
// return newArr.filter(item=>targetKeys.includes(item.key))
|
|
173
185
|
return finalCheckValue;
|
|
174
186
|
};
|
|
@@ -189,6 +201,11 @@ export var renderRelationNode = function renderRelationNode(targetKeys, dataSour
|
|
|
189
201
|
});
|
|
190
202
|
findValue && finalCheckValue.push(findValue);
|
|
191
203
|
});
|
|
204
|
+
finalCheckValue = finalCheckValue.filter(function (i) {
|
|
205
|
+
return i.disabled;
|
|
206
|
+
}).concat(finalCheckValue.filter(function (i) {
|
|
207
|
+
return !i.disabled;
|
|
208
|
+
}));
|
|
192
209
|
// return flatdata.filter(item=>targetKeys.includes(item.key));
|
|
193
210
|
return finalCheckValue;
|
|
194
211
|
};
|
package/lib/SearchBar/index.js
CHANGED
|
@@ -108,13 +108,13 @@ var SearchBar = function SearchBar(props) {
|
|
|
108
108
|
showTooltipIcon = _tipTooltipOption$sho === void 0 ? false : _tipTooltipOption$sho,
|
|
109
109
|
tipTooltipOptionRest = _objectWithoutProperties(tipTooltipOption, _excluded);
|
|
110
110
|
useEffect(function () {
|
|
111
|
-
var _formItemContainer$cu
|
|
111
|
+
var _formItemContainer$cu;
|
|
112
112
|
if (!Number.isInteger(maxLine) || maxLine < 1) return;
|
|
113
113
|
// 只设置一次容器的maxHeight
|
|
114
114
|
if (maxHeight) return;
|
|
115
115
|
|
|
116
116
|
// 获取最大行数的一个节点的高度。来设置外层容器的maxHeight
|
|
117
|
-
var children = (_formItemContainer$cu = formItemContainer.current) === null || _formItemContainer$cu === void 0
|
|
117
|
+
var children = (_formItemContainer$cu = formItemContainer.current) === null || _formItemContainer$cu === void 0 || (_formItemContainer$cu = _formItemContainer$cu.children) === null || _formItemContainer$cu === void 0 || (_formItemContainer$cu = _formItemContainer$cu[0]) === null || _formItemContainer$cu === void 0 ? void 0 : _formItemContainer$cu.children;
|
|
118
118
|
if (!(children !== null && children !== void 0 && children.length)) return;
|
|
119
119
|
var containerTop = formItemContainer.current.children[0].getBoundingClientRect().top;
|
|
120
120
|
if (expandSearchArrange === "inline") {
|
|
@@ -336,7 +336,9 @@ var SearchBar = function SearchBar(props) {
|
|
|
336
336
|
if (index < showExtraCount) {
|
|
337
337
|
return /*#__PURE__*/React.createElement("div", {
|
|
338
338
|
style: {
|
|
339
|
-
marginLeft: index === 0 ? 0 : "8px"
|
|
339
|
+
marginLeft: index === 0 ? 0 : "8px",
|
|
340
|
+
display: 'flex',
|
|
341
|
+
alignItems: "center"
|
|
340
342
|
},
|
|
341
343
|
key: value.key ? value.key : index
|
|
342
344
|
}, value);
|
package/lib/SingleSpa/index.js
CHANGED
|
@@ -80,9 +80,9 @@ var SingleSpa = function SingleSpa(_ref) {
|
|
|
80
80
|
_context.prev = 9;
|
|
81
81
|
_context.next = 12;
|
|
82
82
|
return importScripts(script).then(function (result) {
|
|
83
|
-
var _result$default
|
|
83
|
+
var _result$default;
|
|
84
84
|
// 子应用umount周期卸载相关样式(防止样式冲突)
|
|
85
|
-
(_result$default = result["default"]) === null || _result$default === void 0
|
|
85
|
+
(_result$default = result["default"]) === null || _result$default === void 0 || (_result$default = _result$default.unmount) === null || _result$default === void 0 ? void 0 : _result$default.push(function () {
|
|
86
86
|
unloadApplication(project.id, {
|
|
87
87
|
waitForUnmount: true
|
|
88
88
|
}).then(function () {
|
|
@@ -10,7 +10,7 @@ export function findCommentNode(comment) {
|
|
|
10
10
|
for (var i = 0; i < head.childNodes.length; i++) {
|
|
11
11
|
var _node$nodeValue;
|
|
12
12
|
var node = head.childNodes[i];
|
|
13
|
-
if (node.nodeType === 8 && (node === null || node === void 0
|
|
13
|
+
if (node.nodeType === 8 && (node === null || node === void 0 || (_node$nodeValue = node.nodeValue) === null || _node$nodeValue === void 0 ? void 0 : _node$nodeValue.trim()) === comment) {
|
|
14
14
|
return node;
|
|
15
15
|
}
|
|
16
16
|
}
|
|
@@ -4340,8 +4340,8 @@ function _typeof2(obj) { "@babel/helpers - typeof"; return _typeof2 = "function"
|
|
|
4340
4340
|
}
|
|
4341
4341
|
});
|
|
4342
4342
|
$(document).on('click focusin', function (e) {
|
|
4343
|
-
var _e$target
|
|
4344
|
-
if (tab$focus && e.type == 'focusin' && !(e !== null && e !== void 0 && (_e$target = e.target) !== null && _e$target !== void 0 && (_e$target
|
|
4343
|
+
var _e$target;
|
|
4344
|
+
if (tab$focus && e.type == 'focusin' && !(e !== null && e !== void 0 && (_e$target = e.target) !== null && _e$target !== void 0 && (_e$target = _e$target.className) !== null && _e$target !== void 0 && _e$target.includes('w-e-text'))) {
|
|
4345
4345
|
tab$focus = false;
|
|
4346
4346
|
return;
|
|
4347
4347
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@chaoswise/ui",
|
|
3
|
-
"version": "2.3.
|
|
3
|
+
"version": "2.3.5",
|
|
4
4
|
"description": "公共UI库",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ui",
|
|
@@ -140,5 +140,5 @@
|
|
|
140
140
|
"access": "public"
|
|
141
141
|
},
|
|
142
142
|
"license": "MIT",
|
|
143
|
-
"gitHead": "
|
|
143
|
+
"gitHead": "2674d3bab3ac2e373daafc58ff0048ba5338aaba"
|
|
144
144
|
}
|