@kdcloudjs/kdesign 1.7.33-stable.3 → 1.7.33-stable.4

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.
@@ -20,7 +20,7 @@ import isBoolean from 'lodash/isBoolean';
20
20
  import Icon from '../icon';
21
21
  import devWarning from '../_utils/devwarning';
22
22
  var InternalCheckbox = function InternalCheckbox(props, ref) {
23
- var _context, _context2, _context3, _classNames, _context4, _context5, _context6, _context7, _classNames2, _context8, _context9, _context10, _context11, _context12, _context13, _context14, _context15, _classNames4, _context16, _context17, _context18, _classNames5, _context19;
23
+ var _context, _context2, _context3, _classNames, _context4, _context5, _context6, _context7, _classNames2, _context8, _context9, _context10, _context11, _context12, _context13, _context14, _classNames4, _context15, _context16, _context17, _classNames5, _context18;
24
24
  var _useContext = useContext(ConfigContext),
25
25
  getPrefixCls = _useContext.getPrefixCls,
26
26
  prefixCls = _useContext.prefixCls,
@@ -67,9 +67,9 @@ var InternalCheckbox = function InternalCheckbox(props, ref) {
67
67
  var getSquareClassName = classNames(className, (_classNames2 = {}, _defineProperty(_classNames2, "".concat(checkboxPrefixCls), true), _defineProperty(_classNames2, _concatInstanceProperty(_context4 = "".concat(checkboxPrefixCls, "-")).call(_context4, mergedCheckboxType), true), _defineProperty(_classNames2, _concatInstanceProperty(_context5 = "".concat(checkboxPrefixCls, "-")).call(_context5, mergedSize), !!children), _defineProperty(_classNames2, _concatInstanceProperty(_context6 = "".concat(checkboxPrefixCls, "-")).call(_context6, mergedCheckboxType, "-disabled"), mergedDisabled), _defineProperty(_classNames2, _concatInstanceProperty(_context7 = "".concat(checkboxPrefixCls, "-")).call(_context7, mergedCheckboxType, "-checked"), selected && !mergedDisabled), _defineProperty(_classNames2, "checked", selected), _classNames2));
68
68
  var getRootClassName = isDefaultType() ? getDefaultClassName : getSquareClassName;
69
69
  var inputClassName = classNames(_defineProperty({}, "".concat(checkboxPrefixCls, "-input"), true));
70
- var checkedWrapperClassName = classNames((_classNames4 = {}, _defineProperty(_classNames4, _concatInstanceProperty(_context8 = "".concat(checkboxPrefixCls, "-")).call(_context8, mergedCheckboxType, "-no-child"), !children), _defineProperty(_classNames4, _concatInstanceProperty(_context9 = "".concat(checkboxPrefixCls, "-")).call(_context9, mergedCheckboxType, "-wrapper"), true), _defineProperty(_classNames4, _concatInstanceProperty(_context10 = "".concat(checkboxPrefixCls, "-")).call(_context10, mergedCheckboxType, "-wrapper-size"), !!children), _defineProperty(_classNames4, _concatInstanceProperty(_context11 = "".concat(checkboxPrefixCls, "-")).call(_context11, mergedCheckboxType, "-margin"), !!children), _defineProperty(_classNames4, _concatInstanceProperty(_context12 = "".concat(checkboxPrefixCls, "-")).call(_context12, mergedCheckboxType, "-checked"), selected), _defineProperty(_classNames4, _concatInstanceProperty(_context13 = "".concat(checkboxPrefixCls, "-")).call(_context13, mergedCheckboxType, "-indeterminate"), getIndeterminate()), _defineProperty(_classNames4, _concatInstanceProperty(_context14 = "".concat(checkboxPrefixCls, "-")).call(_context14, mergedCheckboxType, "-disabled"), mergedDisabled && !selected), _defineProperty(_classNames4, _concatInstanceProperty(_context15 = "".concat(checkboxPrefixCls, "-")).call(_context15, mergedCheckboxType, "-checked-disabled"), mergedDisabled && selected), _classNames4));
71
- var triangleClassName = classNames((_classNames5 = {}, _defineProperty(_classNames5, _concatInstanceProperty(_context16 = "".concat(checkboxPrefixCls, "-")).call(_context16, mergedCheckboxType, "-triangle"), !selected), _defineProperty(_classNames5, _concatInstanceProperty(_context17 = "".concat(checkboxPrefixCls, "-")).call(_context17, mergedCheckboxType, "-triangle-checked"), selected), _defineProperty(_classNames5, _concatInstanceProperty(_context18 = "".concat(checkboxPrefixCls, "-")).call(_context18, mergedCheckboxType, "-triangle-disabled"), mergedDisabled), _classNames5));
72
- var innerIconClassName = classNames(_defineProperty({}, _concatInstanceProperty(_context19 = "".concat(checkboxPrefixCls, "-")).call(_context19, mergedCheckboxType, "-inner"), true));
70
+ var checkedWrapperClassName = classNames((_classNames4 = {}, _defineProperty(_classNames4, _concatInstanceProperty(_context8 = "".concat(checkboxPrefixCls, "-")).call(_context8, mergedCheckboxType, "-wrapper"), true), _defineProperty(_classNames4, _concatInstanceProperty(_context9 = "".concat(checkboxPrefixCls, "-")).call(_context9, mergedCheckboxType, "-wrapper-size"), true), _defineProperty(_classNames4, _concatInstanceProperty(_context10 = "".concat(checkboxPrefixCls, "-")).call(_context10, mergedCheckboxType, "-margin"), !!children), _defineProperty(_classNames4, _concatInstanceProperty(_context11 = "".concat(checkboxPrefixCls, "-")).call(_context11, mergedCheckboxType, "-checked"), selected), _defineProperty(_classNames4, _concatInstanceProperty(_context12 = "".concat(checkboxPrefixCls, "-")).call(_context12, mergedCheckboxType, "-indeterminate"), getIndeterminate()), _defineProperty(_classNames4, _concatInstanceProperty(_context13 = "".concat(checkboxPrefixCls, "-")).call(_context13, mergedCheckboxType, "-disabled"), mergedDisabled && !selected), _defineProperty(_classNames4, _concatInstanceProperty(_context14 = "".concat(checkboxPrefixCls, "-")).call(_context14, mergedCheckboxType, "-checked-disabled"), mergedDisabled && selected), _classNames4));
71
+ var triangleClassName = classNames((_classNames5 = {}, _defineProperty(_classNames5, _concatInstanceProperty(_context15 = "".concat(checkboxPrefixCls, "-")).call(_context15, mergedCheckboxType, "-triangle"), !selected), _defineProperty(_classNames5, _concatInstanceProperty(_context16 = "".concat(checkboxPrefixCls, "-")).call(_context16, mergedCheckboxType, "-triangle-checked"), selected), _defineProperty(_classNames5, _concatInstanceProperty(_context17 = "".concat(checkboxPrefixCls, "-")).call(_context17, mergedCheckboxType, "-triangle-disabled"), mergedDisabled), _classNames5));
72
+ var innerIconClassName = classNames(_defineProperty({}, _concatInstanceProperty(_context18 = "".concat(checkboxPrefixCls, "-")).call(_context18, mergedCheckboxType, "-inner"), true));
73
73
  var handleChange = function handleChange(e) {
74
74
  onChange && onChange(e);
75
75
  (checkboxGroup === null || checkboxGroup === void 0 ? void 0 : checkboxGroup.onCheckboxGroupChange) && (checkboxGroup === null || checkboxGroup === void 0 ? void 0 : checkboxGroup.onCheckboxGroupChange(value, e.target.checked, e));
@@ -96,7 +96,7 @@ var InternalCheckbox = function InternalCheckbox(props, ref) {
96
96
  };
97
97
  }, []);
98
98
  var getDefaultCheckbox = function getDefaultCheckbox() {
99
- var _context20, _context21;
99
+ var _context19, _context20;
100
100
  var inputProps = {
101
101
  type: 'checkbox',
102
102
  className: inputClassName,
@@ -121,7 +121,7 @@ var InternalCheckbox = function InternalCheckbox(props, ref) {
121
121
  className: innerIconClassName
122
122
  }, /*#__PURE__*/React.createElement(Icon, {
123
123
  type: "right-bold",
124
- className: _concatInstanceProperty(_context20 = "".concat(checkboxPrefixCls, "-")).call(_context20, mergedCheckboxType, "-inner-icon")
124
+ className: _concatInstanceProperty(_context19 = "".concat(checkboxPrefixCls, "-")).call(_context19, mergedCheckboxType, "-inner-icon")
125
125
  })) : null, /*#__PURE__*/React.createElement("input", _extends({
126
126
  type: "checkbox",
127
127
  ref: ref
@@ -133,7 +133,7 @@ var InternalCheckbox = function InternalCheckbox(props, ref) {
133
133
  className: innerIconClassName
134
134
  }, /*#__PURE__*/React.createElement(Icon, {
135
135
  type: "right-bold",
136
- className: _concatInstanceProperty(_context21 = "".concat(checkboxPrefixCls, "-")).call(_context21, mergedCheckboxType, "-inner-icon")
136
+ className: _concatInstanceProperty(_context20 = "".concat(checkboxPrefixCls, "-")).call(_context20, mergedCheckboxType, "-inner-icon")
137
137
  }))) : null)
138
138
  );
139
139
  };
@@ -334,10 +334,6 @@
334
334
  .kd-checkbox-default-margin {
335
335
  margin-right: var(--kd-c-checkbox-default-input-spacing-margin-right, 4px);
336
336
  }
337
- .kd-checkbox-default-no-child {
338
- height: 100%;
339
- width: 100%;
340
- }
341
337
  .kd-checkbox-default-checked-disabled {
342
338
  background-color: var(--kd-c-checkbox-default-color-background-disabled, #e5e5e5) !important;
343
339
  border-color: var(--kd-c-checkbox-default-color-background-disabled, #d9d9d9) !important;
@@ -200,10 +200,6 @@
200
200
  &-margin {
201
201
  margin-right: @checkbox-default-input-margin-right;
202
202
  }
203
- &-no-child {
204
- height: 100%;
205
- width: 100%;
206
- }
207
203
  &-checked-disabled {
208
204
  background-color: @checkbox-default-disabled-color-bg !important;
209
205
  border-color: @checkbox-default-disabled-color-border !important;
@@ -563,7 +563,7 @@ var InternalSelect = function InternalSelect(props, ref) {
563
563
  background: 'none'
564
564
  };
565
565
  var indeterminate = mulOptions.length > 0 && mulOptions.length < filledOptions.length;
566
- var checked = mulOptions.length === filledOptions.length;
566
+ var checked = mulOptions.length > 0 && mulOptions.length === filledOptions.length;
567
567
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
568
568
  className: dropDownCls,
569
569
  style: dropdownStyle,
@@ -32,7 +32,7 @@ var __rest = void 0 && (void 0).__rest || function (s, e) {
32
32
  return t;
33
33
  };
34
34
  var InternalCheckbox = function InternalCheckbox(props, ref) {
35
- var _context, _context2, _context3, _classNames, _context4, _context5, _context6, _context7, _classNames2, _context8, _context9, _context10, _context11, _context12, _context13, _context14, _context15, _classNames4, _context16, _context17, _context18, _classNames5, _context19;
35
+ var _context, _context2, _context3, _classNames, _context4, _context5, _context6, _context7, _classNames2, _context8, _context9, _context10, _context11, _context12, _context13, _context14, _classNames4, _context15, _context16, _context17, _classNames5, _context18;
36
36
  var _useContext = (0, _react.useContext)(_ConfigContext.default),
37
37
  getPrefixCls = _useContext.getPrefixCls,
38
38
  prefixCls = _useContext.prefixCls,
@@ -79,9 +79,9 @@ var InternalCheckbox = function InternalCheckbox(props, ref) {
79
79
  var getSquareClassName = (0, _classnames.default)(className, (_classNames2 = {}, (0, _defineProperty2.default)(_classNames2, "".concat(checkboxPrefixCls), true), (0, _defineProperty2.default)(_classNames2, (0, _concat.default)(_context4 = "".concat(checkboxPrefixCls, "-")).call(_context4, mergedCheckboxType), true), (0, _defineProperty2.default)(_classNames2, (0, _concat.default)(_context5 = "".concat(checkboxPrefixCls, "-")).call(_context5, mergedSize), !!children), (0, _defineProperty2.default)(_classNames2, (0, _concat.default)(_context6 = "".concat(checkboxPrefixCls, "-")).call(_context6, mergedCheckboxType, "-disabled"), mergedDisabled), (0, _defineProperty2.default)(_classNames2, (0, _concat.default)(_context7 = "".concat(checkboxPrefixCls, "-")).call(_context7, mergedCheckboxType, "-checked"), selected && !mergedDisabled), (0, _defineProperty2.default)(_classNames2, "checked", selected), _classNames2));
80
80
  var getRootClassName = isDefaultType() ? getDefaultClassName : getSquareClassName;
81
81
  var inputClassName = (0, _classnames.default)((0, _defineProperty2.default)({}, "".concat(checkboxPrefixCls, "-input"), true));
82
- var checkedWrapperClassName = (0, _classnames.default)((_classNames4 = {}, (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context8 = "".concat(checkboxPrefixCls, "-")).call(_context8, mergedCheckboxType, "-no-child"), !children), (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context9 = "".concat(checkboxPrefixCls, "-")).call(_context9, mergedCheckboxType, "-wrapper"), true), (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context10 = "".concat(checkboxPrefixCls, "-")).call(_context10, mergedCheckboxType, "-wrapper-size"), !!children), (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context11 = "".concat(checkboxPrefixCls, "-")).call(_context11, mergedCheckboxType, "-margin"), !!children), (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context12 = "".concat(checkboxPrefixCls, "-")).call(_context12, mergedCheckboxType, "-checked"), selected), (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context13 = "".concat(checkboxPrefixCls, "-")).call(_context13, mergedCheckboxType, "-indeterminate"), getIndeterminate()), (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context14 = "".concat(checkboxPrefixCls, "-")).call(_context14, mergedCheckboxType, "-disabled"), mergedDisabled && !selected), (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context15 = "".concat(checkboxPrefixCls, "-")).call(_context15, mergedCheckboxType, "-checked-disabled"), mergedDisabled && selected), _classNames4));
83
- var triangleClassName = (0, _classnames.default)((_classNames5 = {}, (0, _defineProperty2.default)(_classNames5, (0, _concat.default)(_context16 = "".concat(checkboxPrefixCls, "-")).call(_context16, mergedCheckboxType, "-triangle"), !selected), (0, _defineProperty2.default)(_classNames5, (0, _concat.default)(_context17 = "".concat(checkboxPrefixCls, "-")).call(_context17, mergedCheckboxType, "-triangle-checked"), selected), (0, _defineProperty2.default)(_classNames5, (0, _concat.default)(_context18 = "".concat(checkboxPrefixCls, "-")).call(_context18, mergedCheckboxType, "-triangle-disabled"), mergedDisabled), _classNames5));
84
- var innerIconClassName = (0, _classnames.default)((0, _defineProperty2.default)({}, (0, _concat.default)(_context19 = "".concat(checkboxPrefixCls, "-")).call(_context19, mergedCheckboxType, "-inner"), true));
82
+ var checkedWrapperClassName = (0, _classnames.default)((_classNames4 = {}, (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context8 = "".concat(checkboxPrefixCls, "-")).call(_context8, mergedCheckboxType, "-wrapper"), true), (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context9 = "".concat(checkboxPrefixCls, "-")).call(_context9, mergedCheckboxType, "-wrapper-size"), true), (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context10 = "".concat(checkboxPrefixCls, "-")).call(_context10, mergedCheckboxType, "-margin"), !!children), (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context11 = "".concat(checkboxPrefixCls, "-")).call(_context11, mergedCheckboxType, "-checked"), selected), (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context12 = "".concat(checkboxPrefixCls, "-")).call(_context12, mergedCheckboxType, "-indeterminate"), getIndeterminate()), (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context13 = "".concat(checkboxPrefixCls, "-")).call(_context13, mergedCheckboxType, "-disabled"), mergedDisabled && !selected), (0, _defineProperty2.default)(_classNames4, (0, _concat.default)(_context14 = "".concat(checkboxPrefixCls, "-")).call(_context14, mergedCheckboxType, "-checked-disabled"), mergedDisabled && selected), _classNames4));
83
+ var triangleClassName = (0, _classnames.default)((_classNames5 = {}, (0, _defineProperty2.default)(_classNames5, (0, _concat.default)(_context15 = "".concat(checkboxPrefixCls, "-")).call(_context15, mergedCheckboxType, "-triangle"), !selected), (0, _defineProperty2.default)(_classNames5, (0, _concat.default)(_context16 = "".concat(checkboxPrefixCls, "-")).call(_context16, mergedCheckboxType, "-triangle-checked"), selected), (0, _defineProperty2.default)(_classNames5, (0, _concat.default)(_context17 = "".concat(checkboxPrefixCls, "-")).call(_context17, mergedCheckboxType, "-triangle-disabled"), mergedDisabled), _classNames5));
84
+ var innerIconClassName = (0, _classnames.default)((0, _defineProperty2.default)({}, (0, _concat.default)(_context18 = "".concat(checkboxPrefixCls, "-")).call(_context18, mergedCheckboxType, "-inner"), true));
85
85
  var handleChange = function handleChange(e) {
86
86
  onChange && onChange(e);
87
87
  (checkboxGroup === null || checkboxGroup === void 0 ? void 0 : checkboxGroup.onCheckboxGroupChange) && (checkboxGroup === null || checkboxGroup === void 0 ? void 0 : checkboxGroup.onCheckboxGroupChange(value, e.target.checked, e));
@@ -108,7 +108,7 @@ var InternalCheckbox = function InternalCheckbox(props, ref) {
108
108
  };
109
109
  }, []);
110
110
  var getDefaultCheckbox = function getDefaultCheckbox() {
111
- var _context20, _context21;
111
+ var _context19, _context20;
112
112
  var inputProps = {
113
113
  type: 'checkbox',
114
114
  className: inputClassName,
@@ -133,7 +133,7 @@ var InternalCheckbox = function InternalCheckbox(props, ref) {
133
133
  className: innerIconClassName
134
134
  }, /*#__PURE__*/_react.default.createElement(_icon.default, {
135
135
  type: "right-bold",
136
- className: (0, _concat.default)(_context20 = "".concat(checkboxPrefixCls, "-")).call(_context20, mergedCheckboxType, "-inner-icon")
136
+ className: (0, _concat.default)(_context19 = "".concat(checkboxPrefixCls, "-")).call(_context19, mergedCheckboxType, "-inner-icon")
137
137
  })) : null, /*#__PURE__*/_react.default.createElement("input", (0, _extends2.default)({
138
138
  type: "checkbox",
139
139
  ref: ref
@@ -145,7 +145,7 @@ var InternalCheckbox = function InternalCheckbox(props, ref) {
145
145
  className: innerIconClassName
146
146
  }, /*#__PURE__*/_react.default.createElement(_icon.default, {
147
147
  type: "right-bold",
148
- className: (0, _concat.default)(_context21 = "".concat(checkboxPrefixCls, "-")).call(_context21, mergedCheckboxType, "-inner-icon")
148
+ className: (0, _concat.default)(_context20 = "".concat(checkboxPrefixCls, "-")).call(_context20, mergedCheckboxType, "-inner-icon")
149
149
  }))) : null)
150
150
  );
151
151
  };
@@ -334,10 +334,6 @@
334
334
  .kd-checkbox-default-margin {
335
335
  margin-right: var(--kd-c-checkbox-default-input-spacing-margin-right, 4px);
336
336
  }
337
- .kd-checkbox-default-no-child {
338
- height: 100%;
339
- width: 100%;
340
- }
341
337
  .kd-checkbox-default-checked-disabled {
342
338
  background-color: var(--kd-c-checkbox-default-color-background-disabled, #e5e5e5) !important;
343
339
  border-color: var(--kd-c-checkbox-default-color-background-disabled, #d9d9d9) !important;
@@ -200,10 +200,6 @@
200
200
  &-margin {
201
201
  margin-right: @checkbox-default-input-margin-right;
202
202
  }
203
- &-no-child {
204
- height: 100%;
205
- width: 100%;
206
- }
207
203
  &-checked-disabled {
208
204
  background-color: @checkbox-default-disabled-color-bg !important;
209
205
  border-color: @checkbox-default-disabled-color-border !important;
@@ -575,7 +575,7 @@ var InternalSelect = function InternalSelect(props, ref) {
575
575
  background: 'none'
576
576
  };
577
577
  var indeterminate = mulOptions.length > 0 && mulOptions.length < filledOptions.length;
578
- var checked = mulOptions.length === filledOptions.length;
578
+ var checked = mulOptions.length > 0 && mulOptions.length === filledOptions.length;
579
579
  return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement("div", {
580
580
  className: dropDownCls,
581
581
  style: dropdownStyle,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kdcloudjs/kdesign",
3
- "version": "1.7.33-stable.3",
3
+ "version": "1.7.33-stable.4",
4
4
  "description": "KDesign 金蝶前端react 组件库",
5
5
  "title": "kdesign",
6
6
  "keywords": [