@kdcloudjs/kdesign 1.8.33 → 1.8.34

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.
@@ -33,7 +33,8 @@ var InternalButtonGroup = function InternalButtonGroup(props, ref) {
33
33
  buttonType = buttonGoupProps.buttonType,
34
34
  disabled = buttonGoupProps.disabled,
35
35
  onVisibleChange = buttonGoupProps.onVisibleChange,
36
- loading = buttonGoupProps.loading;
36
+ loading = buttonGoupProps.loading,
37
+ placement = buttonGoupProps.placement;
37
38
  var _useState = useState(false),
38
39
  _useState2 = _slicedToArray(_useState, 2),
39
40
  optionShow = _useState2[0],
@@ -110,7 +111,7 @@ var InternalButtonGroup = function InternalButtonGroup(props, ref) {
110
111
  onVisibleChange === null || onVisibleChange === void 0 ? void 0 : onVisibleChange(visible);
111
112
  };
112
113
  var popperProps = _extends(_extends({
113
- placement: direction === 'rtl' ? 'bottomRight' : 'bottomLeft',
114
+ placement: placement || (direction === 'rtl' ? 'bottomRight' : 'bottomLeft'),
114
115
  trigger: 'click',
115
116
  gap: 0
116
117
  }, buttonGoupProps), {
@@ -21,8 +21,7 @@ var InternalOption = function InternalOption(props, ref) {
21
21
  name = city.name;
22
22
  var _useContext = useContext(ConfigContext),
23
23
  getPrefixCls = _useContext.getPrefixCls,
24
- prefixCls = _useContext.prefixCls,
25
- direction = _useContext.direction;
24
+ prefixCls = _useContext.prefixCls;
26
25
  var selectOptionPrefixCls = getPrefixCls(prefixCls, 'city-picker-list-item');
27
26
  var isSelected = id !== undefined ? id === value : false;
28
27
  var optionCls = classNames(selectOptionPrefixCls, className, (_classNames = {}, _defineProperty(_classNames, "".concat(selectOptionPrefixCls, "-selected"), isSelected), _defineProperty(_classNames, "".concat(selectOptionPrefixCls, "-disabled"), disabled), _defineProperty(_classNames, "".concat(selectOptionPrefixCls, "-active"), activeIndex === index), _classNames));
@@ -40,11 +39,7 @@ var InternalOption = function InternalOption(props, ref) {
40
39
  title: name,
41
40
  onClick: handleClick,
42
41
  onMouseEnter: handleOnMouseEnter
43
- }, typeof itemRender === 'function' ? itemRender(city) : direction === 'rtl' ? React.createElement(React.Fragment, null, React.createElement("span", {
44
- className: "".concat(selectOptionPrefixCls, "-info")
45
- }, renderCityInfo === null || renderCityInfo === void 0 ? void 0 : renderCityInfo(city, true)), React.createElement("span", {
46
- className: "".concat(selectOptionPrefixCls, "-content")
47
- }, children)) : React.createElement(React.Fragment, null, React.createElement("span", {
42
+ }, typeof itemRender === 'function' ? itemRender(city) : React.createElement(React.Fragment, null, React.createElement("span", {
48
43
  className: "".concat(selectOptionPrefixCls, "-content")
49
44
  }, children), React.createElement("span", {
50
45
  className: "".concat(selectOptionPrefixCls, "-info")
@@ -989,3 +989,6 @@
989
989
  .kd-date-picker-rtl .kd-date-picker-container .kd-date-picker-ranges {
990
990
  text-align: right;
991
991
  }
992
+ .kd-date-picker-rtl .kd-date-picker-warpper .kd-date-picker-time .kd-date-picker-content {
993
+ direction: ltr;
994
+ }
@@ -895,4 +895,11 @@
895
895
  text-align: right;
896
896
  }
897
897
  }
898
+ .@{datePicker-prefix-cls}-warpper {
899
+ .@{datePicker-prefix-cls}-time {
900
+ .@{datePicker-prefix-cls}-content {
901
+ direction: ltr;
902
+ }
903
+ }
904
+ }
898
905
  }
package/es/modal/modal.js CHANGED
@@ -121,7 +121,7 @@ var InternalModal = function InternalModal(props, ref) {
121
121
  modalContainer = document.body;
122
122
  }
123
123
  var _useState3 = useState(modalContainer && !overroll ? {
124
- x: -(width / 2),
124
+ x: direction === 'rtl' ? width / 2 : -(width / 2),
125
125
  y: -(height / 2)
126
126
  } : {
127
127
  x: 0,
@@ -358,3 +358,7 @@
358
358
  margin-left: var(--kd-c-modal-footer-button-spacing, 12px);
359
359
  margin-right: 0;
360
360
  }
361
+ .kd-modal-rtl .kd-modal-has-container-box {
362
+ right: 50%;
363
+ left: auto;
364
+ }
@@ -247,4 +247,8 @@
247
247
  }
248
248
  }
249
249
  }
250
+ .@{modal-prefix-cls}-has-container-box {
251
+ right: 50%;
252
+ left: auto;
253
+ }
250
254
  }
@@ -278,10 +278,6 @@
278
278
  padding-right: 0;
279
279
  padding-left: calc(var(--kd-c-progress-line-text-font-size, 16px) * 2 + 8px);
280
280
  }
281
- .kd-progress-rtl .kd-progress-inner {
282
- -webkit-transform: rotateY(180deg);
283
- transform: rotateY(180deg);
284
- }
285
281
  .kd-progress-rtl .kd-progress-text {
286
282
  margin-right: var(--kd-c-progress-line-text-spacing-margin-left, 8px);
287
283
  margin-left: 0;
@@ -215,9 +215,9 @@
215
215
  padding-left: calc(@progress-line-text-font-size * 2 + 8px);
216
216
  }
217
217
  }
218
- .@{progress-prefix-cls}-inner {
219
- transform: rotateY(180deg);
220
- }
218
+ // .@{progress-prefix-cls}-inner {
219
+ // // transform: rotateY(180deg);
220
+ // }
221
221
  .@{progress-prefix-cls}-text {
222
222
  margin-right: @progress-line-text-margin-left;
223
223
  margin-left: 0;
@@ -37,8 +37,7 @@ var ITransferList = function ITransferList(props, ref) {
37
37
  pagination = props.pagination,
38
38
  footer = props.footer,
39
39
  showRemove = props.showRemove,
40
- placeholder = props.placeholder,
41
- rtl = props.rtl;
40
+ placeholder = props.placeholder;
42
41
  var _useState = useState(''),
43
42
  _useState2 = _slicedToArray(_useState, 2),
44
43
  filterValue = _useState2[0],
@@ -135,11 +134,11 @@ var ITransferList = function ITransferList(props, ref) {
135
134
  }, search, bodyNode);
136
135
  };
137
136
  var getSelectAllLabel = function getSelectAllLabel(selectedCount, totalCount) {
138
- var _context2, _context3;
137
+ var _context2;
139
138
  if (showRemove) {
140
139
  return React.createElement(React.Fragment, null, "".concat(totalCount));
141
140
  }
142
- return rtl ? React.createElement(React.Fragment, null, _concatInstanceProperty(_context2 = "(".concat(totalCount, "/")).call(_context2, selectedCount, ")")) : React.createElement(React.Fragment, null, _concatInstanceProperty(_context3 = "(".concat(selectedCount, "/")).call(_context3, totalCount, ")"));
141
+ return React.createElement(React.Fragment, null, _concatInstanceProperty(_context2 = "(".concat(totalCount, "/")).call(_context2, selectedCount, ")"));
143
142
  };
144
143
  var getCheckStatus = function getCheckStatus(filteredItems) {
145
144
  if (checkedKeys.length === 0) {
@@ -162,10 +161,10 @@ var ITransferList = function ITransferList(props, ref) {
162
161
  checked: checkedAll,
163
162
  indeterminate: checkStatus === 'part',
164
163
  onChange: function onChange() {
165
- var _context4;
166
- onItemSelectAll(_mapInstanceProperty(_context4 = _filterInstanceProperty(filteredItems).call(filteredItems, function (item) {
164
+ var _context3;
165
+ onItemSelectAll(_mapInstanceProperty(_context3 = _filterInstanceProperty(filteredItems).call(filteredItems, function (item) {
167
166
  return !item.disabled;
168
- })).call(_context4, function (_ref) {
167
+ })).call(_context3, function (_ref) {
169
168
  var key = _ref.key;
170
169
  return key;
171
170
  }), !checkedAll);
@@ -270,8 +270,7 @@ var InternalTransfer = function InternalTransfer(props, ref) {
270
270
  pagination: mergedPagination,
271
271
  noDataContent: handleNoDataContent(noDataContent, 'left'),
272
272
  footer: footer,
273
- ref: leftListRef,
274
- rtl: direction === 'rtl'
273
+ ref: leftListRef
275
274
  }), React.createElement(Operation, {
276
275
  className: "".concat(transferPrefixCls, "-operation"),
277
276
  rightActive: rightActive,
@@ -46,7 +46,8 @@ var InternalButtonGroup = function InternalButtonGroup(props, ref) {
46
46
  buttonType = buttonGoupProps.buttonType,
47
47
  disabled = buttonGoupProps.disabled,
48
48
  onVisibleChange = buttonGoupProps.onVisibleChange,
49
- loading = buttonGoupProps.loading;
49
+ loading = buttonGoupProps.loading,
50
+ placement = buttonGoupProps.placement;
50
51
  var _useState = (0, _react.useState)(false),
51
52
  _useState2 = (0, _slicedToArray2.default)(_useState, 2),
52
53
  optionShow = _useState2[0],
@@ -123,7 +124,7 @@ var InternalButtonGroup = function InternalButtonGroup(props, ref) {
123
124
  onVisibleChange === null || onVisibleChange === void 0 ? void 0 : onVisibleChange(visible);
124
125
  };
125
126
  var popperProps = (0, _extends2.default)((0, _extends2.default)({
126
- placement: direction === 'rtl' ? 'bottomRight' : 'bottomLeft',
127
+ placement: placement || (direction === 'rtl' ? 'bottomRight' : 'bottomLeft'),
127
128
  trigger: 'click',
128
129
  gap: 0
129
130
  }, buttonGoupProps), {
@@ -33,8 +33,7 @@ var InternalOption = function InternalOption(props, ref) {
33
33
  name = city.name;
34
34
  var _useContext = (0, _react.useContext)(_ConfigContext.default),
35
35
  getPrefixCls = _useContext.getPrefixCls,
36
- prefixCls = _useContext.prefixCls,
37
- direction = _useContext.direction;
36
+ prefixCls = _useContext.prefixCls;
38
37
  var selectOptionPrefixCls = getPrefixCls(prefixCls, 'city-picker-list-item');
39
38
  var isSelected = id !== undefined ? id === value : false;
40
39
  var optionCls = (0, _classnames.default)(selectOptionPrefixCls, className, (_classNames = {}, (0, _defineProperty2.default)(_classNames, "".concat(selectOptionPrefixCls, "-selected"), isSelected), (0, _defineProperty2.default)(_classNames, "".concat(selectOptionPrefixCls, "-disabled"), disabled), (0, _defineProperty2.default)(_classNames, "".concat(selectOptionPrefixCls, "-active"), activeIndex === index), _classNames));
@@ -52,11 +51,7 @@ var InternalOption = function InternalOption(props, ref) {
52
51
  title: name,
53
52
  onClick: handleClick,
54
53
  onMouseEnter: handleOnMouseEnter
55
- }, typeof itemRender === 'function' ? itemRender(city) : direction === 'rtl' ? _react.default.createElement(_react.default.Fragment, null, _react.default.createElement("span", {
56
- className: "".concat(selectOptionPrefixCls, "-info")
57
- }, renderCityInfo === null || renderCityInfo === void 0 ? void 0 : renderCityInfo(city, true)), _react.default.createElement("span", {
58
- className: "".concat(selectOptionPrefixCls, "-content")
59
- }, children)) : _react.default.createElement(_react.default.Fragment, null, _react.default.createElement("span", {
54
+ }, typeof itemRender === 'function' ? itemRender(city) : _react.default.createElement(_react.default.Fragment, null, _react.default.createElement("span", {
60
55
  className: "".concat(selectOptionPrefixCls, "-content")
61
56
  }, children), _react.default.createElement("span", {
62
57
  className: "".concat(selectOptionPrefixCls, "-info")
@@ -989,3 +989,6 @@
989
989
  .kd-date-picker-rtl .kd-date-picker-container .kd-date-picker-ranges {
990
990
  text-align: right;
991
991
  }
992
+ .kd-date-picker-rtl .kd-date-picker-warpper .kd-date-picker-time .kd-date-picker-content {
993
+ direction: ltr;
994
+ }
@@ -895,4 +895,11 @@
895
895
  text-align: right;
896
896
  }
897
897
  }
898
+ .@{datePicker-prefix-cls}-warpper {
899
+ .@{datePicker-prefix-cls}-time {
900
+ .@{datePicker-prefix-cls}-content {
901
+ direction: ltr;
902
+ }
903
+ }
904
+ }
898
905
  }
@@ -135,7 +135,7 @@ var InternalModal = function InternalModal(props, ref) {
135
135
  modalContainer = document.body;
136
136
  }
137
137
  var _useState3 = (0, _react.useState)(modalContainer && !overroll ? {
138
- x: -(width / 2),
138
+ x: direction === 'rtl' ? width / 2 : -(width / 2),
139
139
  y: -(height / 2)
140
140
  } : {
141
141
  x: 0,
@@ -358,3 +358,7 @@
358
358
  margin-left: var(--kd-c-modal-footer-button-spacing, 12px);
359
359
  margin-right: 0;
360
360
  }
361
+ .kd-modal-rtl .kd-modal-has-container-box {
362
+ right: 50%;
363
+ left: auto;
364
+ }
@@ -247,4 +247,8 @@
247
247
  }
248
248
  }
249
249
  }
250
+ .@{modal-prefix-cls}-has-container-box {
251
+ right: 50%;
252
+ left: auto;
253
+ }
250
254
  }
@@ -278,10 +278,6 @@
278
278
  padding-right: 0;
279
279
  padding-left: calc(var(--kd-c-progress-line-text-font-size, 16px) * 2 + 8px);
280
280
  }
281
- .kd-progress-rtl .kd-progress-inner {
282
- -webkit-transform: rotateY(180deg);
283
- transform: rotateY(180deg);
284
- }
285
281
  .kd-progress-rtl .kd-progress-text {
286
282
  margin-right: var(--kd-c-progress-line-text-spacing-margin-left, 8px);
287
283
  margin-left: 0;
@@ -215,9 +215,9 @@
215
215
  padding-left: calc(@progress-line-text-font-size * 2 + 8px);
216
216
  }
217
217
  }
218
- .@{progress-prefix-cls}-inner {
219
- transform: rotateY(180deg);
220
- }
218
+ // .@{progress-prefix-cls}-inner {
219
+ // // transform: rotateY(180deg);
220
+ // }
221
221
  .@{progress-prefix-cls}-text {
222
222
  margin-right: @progress-line-text-margin-left;
223
223
  margin-left: 0;
@@ -49,8 +49,7 @@ var ITransferList = function ITransferList(props, ref) {
49
49
  pagination = props.pagination,
50
50
  footer = props.footer,
51
51
  showRemove = props.showRemove,
52
- placeholder = props.placeholder,
53
- rtl = props.rtl;
52
+ placeholder = props.placeholder;
54
53
  var _useState = (0, _react.useState)(''),
55
54
  _useState2 = (0, _slicedToArray2.default)(_useState, 2),
56
55
  filterValue = _useState2[0],
@@ -147,11 +146,11 @@ var ITransferList = function ITransferList(props, ref) {
147
146
  }, search, bodyNode);
148
147
  };
149
148
  var getSelectAllLabel = function getSelectAllLabel(selectedCount, totalCount) {
150
- var _context2, _context3;
149
+ var _context2;
151
150
  if (showRemove) {
152
151
  return _react.default.createElement(_react.default.Fragment, null, "".concat(totalCount));
153
152
  }
154
- return rtl ? _react.default.createElement(_react.default.Fragment, null, (0, _concat.default)(_context2 = "(".concat(totalCount, "/")).call(_context2, selectedCount, ")")) : _react.default.createElement(_react.default.Fragment, null, (0, _concat.default)(_context3 = "(".concat(selectedCount, "/")).call(_context3, totalCount, ")"));
153
+ return _react.default.createElement(_react.default.Fragment, null, (0, _concat.default)(_context2 = "(".concat(totalCount, "/")).call(_context2, selectedCount, ")"));
155
154
  };
156
155
  var getCheckStatus = function getCheckStatus(filteredItems) {
157
156
  if (checkedKeys.length === 0) {
@@ -174,10 +173,10 @@ var ITransferList = function ITransferList(props, ref) {
174
173
  checked: checkedAll,
175
174
  indeterminate: checkStatus === 'part',
176
175
  onChange: function onChange() {
177
- var _context4;
178
- onItemSelectAll((0, _map.default)(_context4 = (0, _filter.default)(filteredItems).call(filteredItems, function (item) {
176
+ var _context3;
177
+ onItemSelectAll((0, _map.default)(_context3 = (0, _filter.default)(filteredItems).call(filteredItems, function (item) {
179
178
  return !item.disabled;
180
- })).call(_context4, function (_ref) {
179
+ })).call(_context3, function (_ref) {
181
180
  var key = _ref.key;
182
181
  return key;
183
182
  }), !checkedAll);
@@ -282,8 +282,7 @@ var InternalTransfer = function InternalTransfer(props, ref) {
282
282
  pagination: mergedPagination,
283
283
  noDataContent: handleNoDataContent(noDataContent, 'left'),
284
284
  footer: footer,
285
- ref: leftListRef,
286
- rtl: direction === 'rtl'
285
+ ref: leftListRef
287
286
  }), _react.default.createElement(_operation.default, {
288
287
  className: "".concat(transferPrefixCls, "-operation"),
289
288
  rightActive: rightActive,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kdcloudjs/kdesign",
3
- "version": "1.8.33",
3
+ "version": "1.8.34",
4
4
  "description": "KDesign 金蝶前端react 组件库",
5
5
  "title": "kdesign",
6
6
  "keywords": [