@douyinfe/semi-ui 2.43.1 → 2.43.2
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/css/semi.css +8 -1
- package/dist/css/semi.min.css +1 -1
- package/dist/umd/semi-ui.js +23 -9
- package/dist/umd/semi-ui.js.map +1 -1
- package/dist/umd/semi-ui.min.js +1 -1
- package/dist/umd/semi-ui.min.js.map +1 -1
- package/lib/cjs/calendar/monthCalendar.js +5 -1
- package/lib/cjs/popconfirm/index.js +8 -3
- package/lib/cjs/table/ColumnFilter.js +2 -1
- package/lib/es/calendar/monthCalendar.js +5 -1
- package/lib/es/popconfirm/index.js +8 -3
- package/lib/es/table/ColumnFilter.js +2 -1
- package/package.json +8 -8
|
@@ -78,6 +78,9 @@ class monthCalendar extends _baseComponent.default {
|
|
|
78
78
|
}))));
|
|
79
79
|
};
|
|
80
80
|
this.renderEvents = events => {
|
|
81
|
+
const {
|
|
82
|
+
itemLimit
|
|
83
|
+
} = this.state;
|
|
81
84
|
if (!events) {
|
|
82
85
|
return undefined;
|
|
83
86
|
}
|
|
@@ -94,11 +97,12 @@ class monthCalendar extends _baseComponent.default {
|
|
|
94
97
|
width: toPercent(width),
|
|
95
98
|
top: `${topInd}em`
|
|
96
99
|
};
|
|
97
|
-
return /*#__PURE__*/_react.default.createElement("li", {
|
|
100
|
+
if (topInd < itemLimit) return /*#__PURE__*/_react.default.createElement("li", {
|
|
98
101
|
className: `${_constants.cssClasses.PREFIX}-event-item ${_constants.cssClasses.PREFIX}-event-month`,
|
|
99
102
|
key: key || `${ind}-monthevent`,
|
|
100
103
|
style: style
|
|
101
104
|
}, children);
|
|
105
|
+
return null;
|
|
102
106
|
});
|
|
103
107
|
return list;
|
|
104
108
|
};
|
|
@@ -58,6 +58,11 @@ class Popconfirm extends _baseComponent.default {
|
|
|
58
58
|
});
|
|
59
59
|
const showTitle = title !== null && typeof title !== 'undefined';
|
|
60
60
|
const showContent = !(content === null || typeof content === 'undefined');
|
|
61
|
+
const hasIcon = /*#__PURE__*/_react.default.isValidElement(icon);
|
|
62
|
+
const bodyCls = (0, _classnames.default)({
|
|
63
|
+
[`${prefixCls}-body`]: true,
|
|
64
|
+
[`${prefixCls}-body-withIcon`]: hasIcon
|
|
65
|
+
});
|
|
61
66
|
return (
|
|
62
67
|
/*#__PURE__*/
|
|
63
68
|
/* eslint-disable-next-line jsx-a11y/no-static-element-interactions */
|
|
@@ -69,10 +74,10 @@ class Popconfirm extends _baseComponent.default {
|
|
|
69
74
|
className: `${prefixCls}-inner`
|
|
70
75
|
}, /*#__PURE__*/_react.default.createElement("div", {
|
|
71
76
|
className: `${prefixCls}-header`
|
|
72
|
-
}, /*#__PURE__*/_react.default.createElement("i", {
|
|
77
|
+
}, hasIcon ? /*#__PURE__*/_react.default.createElement("i", {
|
|
73
78
|
className: `${prefixCls}-header-icon`,
|
|
74
79
|
"x-semi-prop": "icon"
|
|
75
|
-
},
|
|
80
|
+
}, icon) : null, /*#__PURE__*/_react.default.createElement("div", {
|
|
76
81
|
className: `${prefixCls}-header-body`
|
|
77
82
|
}, showTitle ? /*#__PURE__*/_react.default.createElement("div", {
|
|
78
83
|
className: `${prefixCls}-header-title`,
|
|
@@ -85,7 +90,7 @@ class Popconfirm extends _baseComponent.default {
|
|
|
85
90
|
type: cancelType,
|
|
86
91
|
onClick: this.handleCancel
|
|
87
92
|
})), showContent ? /*#__PURE__*/_react.default.createElement("div", {
|
|
88
|
-
className:
|
|
93
|
+
className: bodyCls,
|
|
89
94
|
"x-semi-prop": "content"
|
|
90
95
|
}, (0, _isFunction2.default)(content) ? content({
|
|
91
96
|
initialFocusRef
|
|
@@ -104,7 +104,8 @@ function renderDropdown() {
|
|
|
104
104
|
dropdownProps.visible = filterDropdownVisible;
|
|
105
105
|
}
|
|
106
106
|
return /*#__PURE__*/_react.default.createElement(_dropdown.default, Object.assign({}, dropdownProps, {
|
|
107
|
-
key: `Dropdown_level_${level}
|
|
107
|
+
key: `Dropdown_level_${level}`,
|
|
108
|
+
className: `${_constants.cssClasses.PREFIX}-column-filter-dropdown`
|
|
108
109
|
}), nestedElem);
|
|
109
110
|
}
|
|
110
111
|
function ColumnFilter() {
|
|
@@ -70,6 +70,9 @@ export default class monthCalendar extends BaseComponent {
|
|
|
70
70
|
}))));
|
|
71
71
|
};
|
|
72
72
|
this.renderEvents = events => {
|
|
73
|
+
const {
|
|
74
|
+
itemLimit
|
|
75
|
+
} = this.state;
|
|
73
76
|
if (!events) {
|
|
74
77
|
return undefined;
|
|
75
78
|
}
|
|
@@ -86,11 +89,12 @@ export default class monthCalendar extends BaseComponent {
|
|
|
86
89
|
width: toPercent(width),
|
|
87
90
|
top: `${topInd}em`
|
|
88
91
|
};
|
|
89
|
-
return /*#__PURE__*/React.createElement("li", {
|
|
92
|
+
if (topInd < itemLimit) return /*#__PURE__*/React.createElement("li", {
|
|
90
93
|
className: `${cssClasses.PREFIX}-event-item ${cssClasses.PREFIX}-event-month`,
|
|
91
94
|
key: key || `${ind}-monthevent`,
|
|
92
95
|
style: style
|
|
93
96
|
}, children);
|
|
97
|
+
return null;
|
|
94
98
|
});
|
|
95
99
|
return list;
|
|
96
100
|
};
|
|
@@ -51,6 +51,11 @@ export default class Popconfirm extends BaseComponent {
|
|
|
51
51
|
});
|
|
52
52
|
const showTitle = title !== null && typeof title !== 'undefined';
|
|
53
53
|
const showContent = !(content === null || typeof content === 'undefined');
|
|
54
|
+
const hasIcon = /*#__PURE__*/React.isValidElement(icon);
|
|
55
|
+
const bodyCls = cls({
|
|
56
|
+
[`${prefixCls}-body`]: true,
|
|
57
|
+
[`${prefixCls}-body-withIcon`]: hasIcon
|
|
58
|
+
});
|
|
54
59
|
return (
|
|
55
60
|
/*#__PURE__*/
|
|
56
61
|
/* eslint-disable-next-line jsx-a11y/no-static-element-interactions */
|
|
@@ -62,10 +67,10 @@ export default class Popconfirm extends BaseComponent {
|
|
|
62
67
|
className: `${prefixCls}-inner`
|
|
63
68
|
}, /*#__PURE__*/React.createElement("div", {
|
|
64
69
|
className: `${prefixCls}-header`
|
|
65
|
-
}, /*#__PURE__*/React.createElement("i", {
|
|
70
|
+
}, hasIcon ? /*#__PURE__*/React.createElement("i", {
|
|
66
71
|
className: `${prefixCls}-header-icon`,
|
|
67
72
|
"x-semi-prop": "icon"
|
|
68
|
-
},
|
|
73
|
+
}, icon) : null, /*#__PURE__*/React.createElement("div", {
|
|
69
74
|
className: `${prefixCls}-header-body`
|
|
70
75
|
}, showTitle ? /*#__PURE__*/React.createElement("div", {
|
|
71
76
|
className: `${prefixCls}-header-title`,
|
|
@@ -78,7 +83,7 @@ export default class Popconfirm extends BaseComponent {
|
|
|
78
83
|
type: cancelType,
|
|
79
84
|
onClick: this.handleCancel
|
|
80
85
|
})), showContent ? /*#__PURE__*/React.createElement("div", {
|
|
81
|
-
className:
|
|
86
|
+
className: bodyCls,
|
|
82
87
|
"x-semi-prop": "content"
|
|
83
88
|
}, _isFunction(content) ? content({
|
|
84
89
|
initialFocusRef
|
|
@@ -95,7 +95,8 @@ function renderDropdown() {
|
|
|
95
95
|
dropdownProps.visible = filterDropdownVisible;
|
|
96
96
|
}
|
|
97
97
|
return /*#__PURE__*/React.createElement(Dropdown, Object.assign({}, dropdownProps, {
|
|
98
|
-
key: `Dropdown_level_${level}
|
|
98
|
+
key: `Dropdown_level_${level}`,
|
|
99
|
+
className: `${cssClasses.PREFIX}-column-filter-dropdown`
|
|
99
100
|
}), nestedElem);
|
|
100
101
|
}
|
|
101
102
|
export default function ColumnFilter() {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@douyinfe/semi-ui",
|
|
3
|
-
"version": "2.43.
|
|
3
|
+
"version": "2.43.2",
|
|
4
4
|
"description": "A modern, comprehensive, flexible design system and UI library. Connect DesignOps & DevOps. Quickly build beautiful React apps. Maintained by Douyin-fe team.",
|
|
5
5
|
"main": "lib/cjs/index.js",
|
|
6
6
|
"module": "lib/es/index.js",
|
|
@@ -20,12 +20,12 @@
|
|
|
20
20
|
"@dnd-kit/core": "^6.0.8",
|
|
21
21
|
"@dnd-kit/sortable": "^7.0.2",
|
|
22
22
|
"@dnd-kit/utilities": "^3.2.1",
|
|
23
|
-
"@douyinfe/semi-animation": "2.43.
|
|
24
|
-
"@douyinfe/semi-animation-react": "2.43.
|
|
25
|
-
"@douyinfe/semi-foundation": "2.43.
|
|
26
|
-
"@douyinfe/semi-icons": "2.43.
|
|
27
|
-
"@douyinfe/semi-illustrations": "2.43.
|
|
28
|
-
"@douyinfe/semi-theme-default": "2.43.
|
|
23
|
+
"@douyinfe/semi-animation": "2.43.2",
|
|
24
|
+
"@douyinfe/semi-animation-react": "2.43.2",
|
|
25
|
+
"@douyinfe/semi-foundation": "2.43.2",
|
|
26
|
+
"@douyinfe/semi-icons": "2.43.2",
|
|
27
|
+
"@douyinfe/semi-illustrations": "2.43.2",
|
|
28
|
+
"@douyinfe/semi-theme-default": "2.43.2",
|
|
29
29
|
"async-validator": "^3.5.0",
|
|
30
30
|
"classnames": "^2.2.6",
|
|
31
31
|
"copy-text-to-clipboard": "^2.1.1",
|
|
@@ -75,7 +75,7 @@
|
|
|
75
75
|
],
|
|
76
76
|
"author": "",
|
|
77
77
|
"license": "MIT",
|
|
78
|
-
"gitHead": "
|
|
78
|
+
"gitHead": "6c7218869ff6a0c83525f49845b7dc7a858f3705",
|
|
79
79
|
"devDependencies": {
|
|
80
80
|
"@babel/plugin-proposal-decorators": "^7.15.8",
|
|
81
81
|
"@babel/plugin-transform-runtime": "^7.15.8",
|