@kdcloudjs/kdesign 1.7.54 → 1.7.55

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.
@@ -250,7 +250,6 @@
250
250
  }
251
251
  .kd-city-picker-dropdown {
252
252
  display: block;
253
- left: 0;
254
253
  z-index: var(--kd-c-city-picker-z-index, var(--kd-g-z-index-popper, 1050));
255
254
  -webkit-box-sizing: border-box;
256
255
  box-sizing: border-box;
@@ -142,7 +142,6 @@
142
142
 
143
143
  &-dropdown {
144
144
  display: block;
145
- left: 0;
146
145
  z-index: @city-picker-z-index;
147
146
  box-sizing: border-box;
148
147
  margin: 0;
package/es/grid/col.js CHANGED
@@ -41,12 +41,23 @@ var Col = function Col(props) {
41
41
  var rowGroup = useContext(GapContext);
42
42
  var mergedWinWidth = rowGroup.winWidth;
43
43
  var gap = rowGroup.gap;
44
- // 浏览器名称
45
- var isSogouOrIE = testBrowserType(/^sogou/i, 0) || /Trident|MSIE/.test(navigator.userAgent);
44
+ // 判断当前浏览器是否支持row-gap,如果不支持则使用margin负值模拟
45
+ var notSupportRowGap = function notSupportRowGap() {
46
+ // 判断是否是搜狗浏览器
47
+ if (testBrowserType(/^sogou/i, 0)) return true;
48
+ // 判断是否是IE浏览器
49
+ if (/Trident|MSIE/.test(navigator.userAgent)) return true;
50
+ // 判断是否是chrome浏览器,chrome浏览器版本号小于69
51
+ if (/Chrome/.test(navigator.userAgent) && !/Chromium/.test(navigator.userAgent)) {
52
+ var version = navigator.userAgent.split('Chrome/')[1].split('.');
53
+ if (version[0] && parseInt(version[0]) <= 69) return true;
54
+ }
55
+ return false;
56
+ };
46
57
  var colGapStyle = {
47
58
  padding: "0 ".concat(gap.h / 2, "px")
48
59
  };
49
- if (isSogouOrIE && gap.v) colGapStyle.marginBottom = gap.v;
60
+ if (notSupportRowGap() && gap.v) colGapStyle.marginBottom = gap.v;
50
61
  // className前缀
51
62
  var prefixCls = getPrefixCls(pkgPrefixCls, 'col', customPrefixcls);
52
63
  var columns = 24;
package/es/grid/row.js CHANGED
@@ -42,8 +42,19 @@ var Row = function Row(props) {
42
42
  align = _getCompProps.align,
43
43
  justify = _getCompProps.justify,
44
44
  customPrefixcls = _getCompProps.prefixCls;
45
- // 浏览器名称
46
- var isSogouOrIe = testBrowserType(/^sogou/i, 0) || /Trident|MSIE/.test(navigator.userAgent);
45
+ // 判断当前浏览器是否支持row-gap,如果不支持则使用margin负值模拟
46
+ var notSupportRowGap = function notSupportRowGap() {
47
+ // 判断是否是搜狗浏览器
48
+ if (testBrowserType(/^sogou/i, 0)) return true;
49
+ // 判断是否是IE浏览器
50
+ if (/Trident|MSIE/.test(navigator.userAgent)) return true;
51
+ // 判断是否是chrome浏览器,chrome浏览器版本号小于69
52
+ if (/Chrome/.test(navigator.userAgent) && !/Chromium/.test(navigator.userAgent)) {
53
+ var version = navigator.userAgent.split('Chrome/')[1].split('.');
54
+ if (version[0] && parseInt(version[0]) <= 69) return true;
55
+ }
56
+ return false;
57
+ };
47
58
  // className前缀
48
59
  var prefixCls = getPrefixCls(pkgPrefixCls, 'row', customPrefixcls);
49
60
  var _React$useState = React.useState(window.innerWidth),
@@ -78,7 +89,7 @@ var Row = function Row(props) {
78
89
  rowGap: "".concat(gap.v, "px"),
79
90
  margin: "0 ".concat(-1 * gap.h / 2, "px")
80
91
  };
81
- if (gap.v && isSogouOrIe) rowStyle.marginBottom = "".concat(-1 * gap.v, "px");
92
+ if (gap.v && notSupportRowGap()) rowStyle.marginBottom = "".concat(-1 * gap.v, "px");
82
93
  var toalign = {
83
94
  top: 'flex-start',
84
95
  middle: 'center',
@@ -56,11 +56,11 @@ var ClearableInput = function ClearableInput(props) {
56
56
  return null;
57
57
  }
58
58
  var needClear = !disabled && value && isMouseEnter;
59
- var clearIconclasses = classNames((_classNames = {}, _defineProperty(_classNames, "".concat(prefixCls, "-textarea-clear-icon"), inputType === ClearableInputType[1]), _defineProperty(_classNames, "".concat(prefixCls, "-clear-icon"), inputType === ClearableInputType[0]), _defineProperty(_classNames, "".concat(prefixCls, "-clear-icon-hidden"), !needClear), _defineProperty(_classNames, "".concat(prefixCls, "-clear-icon-rightSpace"), suffix), _classNames));
59
+ var clearIconCls = classNames((_classNames = {}, _defineProperty(_classNames, "".concat(prefixCls, "-textarea-clear-icon"), inputType === ClearableInputType[1]), _defineProperty(_classNames, "".concat(prefixCls, "-clear-icon"), inputType === ClearableInputType[0]), _defineProperty(_classNames, "".concat(prefixCls, "-clear-icon-hidden"), !needClear), _defineProperty(_classNames, "".concat(prefixCls, "-clear-icon-rightSpace"), suffix), _classNames));
60
60
  return /*#__PURE__*/React.createElement("span", {
61
61
  onMouseDown: mouseDownHandle,
62
62
  onClick: handleReset,
63
- className: clearIconclasses
63
+ className: clearIconCls
64
64
  }, typeof allowClear === 'boolean' ? /*#__PURE__*/React.createElement(Icon, {
65
65
  type: "close-solid"
66
66
  }) : allowClear);
@@ -250,7 +250,6 @@
250
250
  }
251
251
  .kd-city-picker-dropdown {
252
252
  display: block;
253
- left: 0;
254
253
  z-index: var(--kd-c-city-picker-z-index, var(--kd-g-z-index-popper, 1050));
255
254
  -webkit-box-sizing: border-box;
256
255
  box-sizing: border-box;
@@ -142,7 +142,6 @@
142
142
 
143
143
  &-dropdown {
144
144
  display: block;
145
- left: 0;
146
145
  z-index: @city-picker-z-index;
147
146
  box-sizing: border-box;
148
147
  margin: 0;
package/lib/grid/col.js CHANGED
@@ -53,12 +53,23 @@ var Col = function Col(props) {
53
53
  var rowGroup = (0, _react.useContext)(_row.GapContext);
54
54
  var mergedWinWidth = rowGroup.winWidth;
55
55
  var gap = rowGroup.gap;
56
- // 浏览器名称
57
- var isSogouOrIE = (0, _testBrowserType.testBrowserType)(/^sogou/i, 0) || /Trident|MSIE/.test(navigator.userAgent);
56
+ // 判断当前浏览器是否支持row-gap,如果不支持则使用margin负值模拟
57
+ var notSupportRowGap = function notSupportRowGap() {
58
+ // 判断是否是搜狗浏览器
59
+ if ((0, _testBrowserType.testBrowserType)(/^sogou/i, 0)) return true;
60
+ // 判断是否是IE浏览器
61
+ if (/Trident|MSIE/.test(navigator.userAgent)) return true;
62
+ // 判断是否是chrome浏览器,chrome浏览器版本号小于69
63
+ if (/Chrome/.test(navigator.userAgent) && !/Chromium/.test(navigator.userAgent)) {
64
+ var version = navigator.userAgent.split('Chrome/')[1].split('.');
65
+ if (version[0] && parseInt(version[0]) <= 69) return true;
66
+ }
67
+ return false;
68
+ };
58
69
  var colGapStyle = {
59
70
  padding: "0 ".concat(gap.h / 2, "px")
60
71
  };
61
- if (isSogouOrIE && gap.v) colGapStyle.marginBottom = gap.v;
72
+ if (notSupportRowGap() && gap.v) colGapStyle.marginBottom = gap.v;
62
73
  // className前缀
63
74
  var prefixCls = getPrefixCls(pkgPrefixCls, 'col', customPrefixcls);
64
75
  var columns = 24;
package/lib/grid/row.js CHANGED
@@ -55,8 +55,19 @@ var Row = function Row(props) {
55
55
  align = _getCompProps.align,
56
56
  justify = _getCompProps.justify,
57
57
  customPrefixcls = _getCompProps.prefixCls;
58
- // 浏览器名称
59
- var isSogouOrIe = (0, _testBrowserType.testBrowserType)(/^sogou/i, 0) || /Trident|MSIE/.test(navigator.userAgent);
58
+ // 判断当前浏览器是否支持row-gap,如果不支持则使用margin负值模拟
59
+ var notSupportRowGap = function notSupportRowGap() {
60
+ // 判断是否是搜狗浏览器
61
+ if ((0, _testBrowserType.testBrowserType)(/^sogou/i, 0)) return true;
62
+ // 判断是否是IE浏览器
63
+ if (/Trident|MSIE/.test(navigator.userAgent)) return true;
64
+ // 判断是否是chrome浏览器,chrome浏览器版本号小于69
65
+ if (/Chrome/.test(navigator.userAgent) && !/Chromium/.test(navigator.userAgent)) {
66
+ var version = navigator.userAgent.split('Chrome/')[1].split('.');
67
+ if (version[0] && parseInt(version[0]) <= 69) return true;
68
+ }
69
+ return false;
70
+ };
60
71
  // className前缀
61
72
  var prefixCls = getPrefixCls(pkgPrefixCls, 'row', customPrefixcls);
62
73
  var _React$useState = _react.default.useState(window.innerWidth),
@@ -91,7 +102,7 @@ var Row = function Row(props) {
91
102
  rowGap: "".concat(gap.v, "px"),
92
103
  margin: "0 ".concat(-1 * gap.h / 2, "px")
93
104
  };
94
- if (gap.v && isSogouOrIe) rowStyle.marginBottom = "".concat(-1 * gap.v, "px");
105
+ if (gap.v && notSupportRowGap()) rowStyle.marginBottom = "".concat(-1 * gap.v, "px");
95
106
  var toalign = {
96
107
  top: 'flex-start',
97
108
  middle: 'center',
@@ -69,11 +69,11 @@ var ClearableInput = function ClearableInput(props) {
69
69
  return null;
70
70
  }
71
71
  var needClear = !disabled && value && isMouseEnter;
72
- var clearIconclasses = (0, _classnames.default)((_classNames = {}, (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-textarea-clear-icon"), inputType === ClearableInputType[1]), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-clear-icon"), inputType === ClearableInputType[0]), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-clear-icon-hidden"), !needClear), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-clear-icon-rightSpace"), suffix), _classNames));
72
+ var clearIconCls = (0, _classnames.default)((_classNames = {}, (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-textarea-clear-icon"), inputType === ClearableInputType[1]), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-clear-icon"), inputType === ClearableInputType[0]), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-clear-icon-hidden"), !needClear), (0, _defineProperty2.default)(_classNames, "".concat(prefixCls, "-clear-icon-rightSpace"), suffix), _classNames));
73
73
  return /*#__PURE__*/_react.default.createElement("span", {
74
74
  onMouseDown: mouseDownHandle,
75
75
  onClick: handleReset,
76
- className: clearIconclasses
76
+ className: clearIconCls
77
77
  }, typeof allowClear === 'boolean' ? /*#__PURE__*/_react.default.createElement(_index.Icon, {
78
78
  type: "close-solid"
79
79
  }) : allowClear);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kdcloudjs/kdesign",
3
- "version": "1.7.54",
3
+ "version": "1.7.55",
4
4
  "description": "KDesign 金蝶前端react 组件库",
5
5
  "title": "kdesign",
6
6
  "keywords": [