@kdcloudjs/kdesign 1.6.10 → 1.6.11

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.js CHANGED
@@ -1,6 +1,6 @@
1
1
  /*!
2
2
  *
3
- * @kdcloudjs/kdesign v1.6.8
3
+ * @kdcloudjs/kdesign v1.6.10
4
4
  *
5
5
  * Copyright 2020-present, Kingdee, Inc.
6
6
  * All rights reserved.
@@ -28881,22 +28881,24 @@ var InternalSelect = function InternalSelect(props, ref) {
28881
28881
  return childrenList;
28882
28882
  }, [searchValue, realChildren, filterOption, optionFilterProp]);
28883
28883
  var getOptionLabel = Object(react__WEBPACK_IMPORTED_MODULE_18__["useCallback"])(function (obj) {
28884
+ var text = 'options' in selectProps ? 'label' : optionLabelProp;
28885
+
28884
28886
  if (obj.props) {
28885
28887
  var _obj$props3;
28886
28888
 
28887
- if (optionLabelProp) {
28888
- return obj === null || obj === void 0 ? void 0 : obj.props[optionLabelProp];
28889
+ if (text) {
28890
+ return obj === null || obj === void 0 ? void 0 : obj.props[text];
28889
28891
  }
28890
28892
 
28891
28893
  return (_obj$props3 = obj.props) === null || _obj$props3 === void 0 ? void 0 : _obj$props3.children;
28892
28894
  } else {
28893
- if (optionLabelProp) {
28894
- return obj[optionLabelProp];
28895
+ if (text) {
28896
+ return obj[text];
28895
28897
  }
28896
28898
  }
28897
28899
 
28898
28900
  return obj === null || obj === void 0 ? void 0 : obj.label;
28899
- }, [optionLabelProp]); // 点击下拉列表中某项回调
28901
+ }, [optionLabelProp, selectProps]); // 点击下拉列表中某项回调
28900
28902
 
28901
28903
  var handleOption = function handleOption(key, label, isSelected) {
28902
28904
  var onSelect = selectProps.onSelect,