shineout 3.7.2-beta.6 → 3.7.2-fix.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/cjs/index.js +1 -1
- package/dist/shineout.js +14 -25
- package/dist/shineout.js.map +1 -1
- package/dist/shineout.min.js +1 -1
- package/dist/shineout.min.js.map +1 -1
- package/esm/index.js +1 -1
- package/package.json +5 -5
package/cjs/index.js
CHANGED
|
@@ -522,5 +522,5 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
|
522
522
|
// 此文件由脚本自动生成,请勿直接修改。
|
|
523
523
|
// This file was generated automatically by a script. Please do not modify it directly.
|
|
524
524
|
var _default = exports.default = {
|
|
525
|
-
version: '3.7.2-
|
|
525
|
+
version: '3.7.2-fix.1'
|
|
526
526
|
};
|
package/dist/shineout.js
CHANGED
|
@@ -12234,7 +12234,7 @@ var handleStyle = function handleStyle(style) {
|
|
|
12234
12234
|
};
|
|
12235
12235
|
/* harmony default export */ var jss_style_handleStyle = (handleStyle);
|
|
12236
12236
|
;// CONCATENATED MODULE: ../shineout-style/src/version.ts
|
|
12237
|
-
/* harmony default export */ var version = ('3.7.2-
|
|
12237
|
+
/* harmony default export */ var version = ('3.7.2-fix.1');
|
|
12238
12238
|
;// CONCATENATED MODULE: ../shineout-style/src/jss-style/index.tsx
|
|
12239
12239
|
|
|
12240
12240
|
|
|
@@ -35422,19 +35422,18 @@ function useInputAble(props) {
|
|
|
35422
35422
|
var render = useRender(syncValue);
|
|
35423
35423
|
var shouldUseState = delay || !control;
|
|
35424
35424
|
var value = shouldUseState ? stateValue : valuePo;
|
|
35425
|
-
(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.
|
|
35426
|
-
if (context.timer) {
|
|
35427
|
-
clearTimeout(context.timer);
|
|
35428
|
-
context.timer = null;
|
|
35429
|
-
}
|
|
35425
|
+
(0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useLayoutEffect)(function () {
|
|
35430
35426
|
if (delay && control && props.value !== stateValue) {
|
|
35431
35427
|
changeStateValue(props.value);
|
|
35428
|
+
} else if (context.timer) {
|
|
35429
|
+
clearTimeout(context.timer);
|
|
35430
|
+
context.timer = null;
|
|
35432
35431
|
}
|
|
35433
35432
|
}, [props.value, delay, control]);
|
|
35434
35433
|
var forceDelayChange = use_persist_fn(function () {
|
|
35435
|
-
if (context.
|
|
35434
|
+
if (context.delayChange) context.delayChange();
|
|
35435
|
+
if (context.timer) {
|
|
35436
35436
|
clearTimeout(context.timer);
|
|
35437
|
-
context.delayChange();
|
|
35438
35437
|
context.timer = null;
|
|
35439
35438
|
context.delayChange = null;
|
|
35440
35439
|
}
|
|
@@ -39918,9 +39917,7 @@ var CascaderNode = function CascaderNode(props) {
|
|
|
39918
39917
|
shouldFinal = props.shouldFinal,
|
|
39919
39918
|
onChange = props.onChange,
|
|
39920
39919
|
onPathChange = props.onPathChange,
|
|
39921
|
-
mode = props.mode
|
|
39922
|
-
activeLeaf = props.activeLeaf,
|
|
39923
|
-
setActiveLeaf = props.setActiveLeaf;
|
|
39920
|
+
mode = props.mode;
|
|
39924
39921
|
var _useState = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useState)(false),
|
|
39925
39922
|
_useState2 = slicedToArray_default()(_useState, 2),
|
|
39926
39923
|
loading = _useState2[0],
|
|
@@ -39933,7 +39930,7 @@ var CascaderNode = function CascaderNode(props) {
|
|
|
39933
39930
|
var uncertainChildren = loader && !loading && children === undefined;
|
|
39934
39931
|
var styles = jssStyle === null || jssStyle === void 0 || (_jssStyle$cascader = jssStyle.cascader) === null || _jssStyle$cascader === void 0 ? void 0 : _jssStyle$cascader.call(jssStyle);
|
|
39935
39932
|
var commonStyles = jssStyle === null || jssStyle === void 0 || (_jssStyle$common = jssStyle.common) === null || _jssStyle$common === void 0 ? void 0 : _jssStyle$common.call(jssStyle);
|
|
39936
|
-
var rootClass = classnames_default()(styles.option,
|
|
39933
|
+
var rootClass = classnames_default()(styles.option, active && styles.activeOption, isDisabled && mode !== 4 && styles.optionDisabled);
|
|
39937
39934
|
var handlePathChange = function handlePathChange() {
|
|
39938
39935
|
onPathChange === null || onPathChange === void 0 || onPathChange(id, data, path);
|
|
39939
39936
|
};
|
|
@@ -39957,9 +39954,6 @@ var CascaderNode = function CascaderNode(props) {
|
|
|
39957
39954
|
if (getParent(e.target, checkboxRef.current)) return;
|
|
39958
39955
|
var checked = datum.getChecked(id);
|
|
39959
39956
|
handleChange(null, !checked);
|
|
39960
|
-
if (setActiveLeaf) {
|
|
39961
|
-
setActiveLeaf(id);
|
|
39962
|
-
}
|
|
39963
39957
|
};
|
|
39964
39958
|
var isHoverAble = expandTrigger === 'hover' || expandTrigger === 'hover-only';
|
|
39965
39959
|
var isRealLeafNode = !hasChildren && !uncertainChildren;
|
|
@@ -39973,7 +39967,10 @@ var CascaderNode = function CascaderNode(props) {
|
|
|
39973
39967
|
if (multiple) events.onClick = handleSelect;
|
|
39974
39968
|
} else if (isRealLeafNode && multiple) {
|
|
39975
39969
|
// 非hover模式下: 末级节点支持整个节点区域点击选中checkbox
|
|
39976
|
-
events.onClick =
|
|
39970
|
+
events.onClick = function (e) {
|
|
39971
|
+
handleClick(e);
|
|
39972
|
+
handleSelect(e);
|
|
39973
|
+
};
|
|
39977
39974
|
}
|
|
39978
39975
|
return events;
|
|
39979
39976
|
};
|
|
@@ -40042,7 +40039,6 @@ var CascaderNode = function CascaderNode(props) {
|
|
|
40042
40039
|
|
|
40043
40040
|
|
|
40044
40041
|
|
|
40045
|
-
|
|
40046
40042
|
var list_devUseWarning = devUseWarning;
|
|
40047
40043
|
var CascaderList = function CascaderList(props) {
|
|
40048
40044
|
var _jssStyle$cascader;
|
|
@@ -40099,18 +40095,11 @@ var CascaderList = function CascaderList(props) {
|
|
|
40099
40095
|
children: "noData"
|
|
40100
40096
|
});
|
|
40101
40097
|
};
|
|
40102
|
-
var _useState = (0,external_root_React_commonjs2_react_commonjs_react_amd_react_.useState)(),
|
|
40103
|
-
_useState2 = slicedToArray_default()(_useState, 2),
|
|
40104
|
-
activeLeaf = _useState2[0],
|
|
40105
|
-
setActiveLeaf = _useState2[1];
|
|
40106
|
-
var needSetActiveLeaf = (multiple || mode !== undefined) && props.id === undefined;
|
|
40107
40098
|
var renderItem = function renderItem(item, index) {
|
|
40108
40099
|
var id = getKey(item, index);
|
|
40109
40100
|
return /*#__PURE__*/(0,jsx_runtime.jsx)(node, {
|
|
40110
40101
|
jssStyle: jssStyle,
|
|
40111
40102
|
active: props.id === id,
|
|
40112
|
-
activeLeaf: activeLeaf,
|
|
40113
|
-
setActiveLeaf: needSetActiveLeaf ? setActiveLeaf : undefined,
|
|
40114
40103
|
id: id,
|
|
40115
40104
|
data: item,
|
|
40116
40105
|
datum: datum,
|
|
@@ -71439,7 +71428,7 @@ var upload_interface = __webpack_require__(8821);
|
|
|
71439
71428
|
|
|
71440
71429
|
|
|
71441
71430
|
/* harmony default export */ var src_0 = ({
|
|
71442
|
-
version: '3.7.2-
|
|
71431
|
+
version: '3.7.2-fix.1'
|
|
71443
71432
|
});
|
|
71444
71433
|
}();
|
|
71445
71434
|
/******/ return __webpack_exports__;
|