@douyinfe/semi-ui 2.19.0-alpha.0 → 2.19.0-alpha.1
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/checkbox/checkboxGroup.tsx +2 -0
- package/dist/css/semi.css +7 -14
- package/dist/css/semi.min.css +1 -1
- package/dist/umd/semi-ui.js +24 -40
- 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/checkbox/checkboxGroup.js +4 -2
- package/lib/cjs/form/baseForm.d.ts +1 -1
- package/lib/cjs/form/field.d.ts +1 -1
- package/lib/cjs/radio/radioGroup.js +4 -2
- package/lib/cjs/table/ColumnFilter.js +2 -4
- package/lib/cjs/table/ColumnSorter.d.ts +0 -1
- package/lib/cjs/table/ColumnSorter.js +6 -9
- package/lib/cjs/table/Table.js +4 -11
- package/lib/cjs/tree/treeNode.d.ts +1 -4
- package/lib/cjs/tree/treeNode.js +4 -13
- package/lib/cjs/typography/title.d.ts +1 -1
- package/lib/es/checkbox/checkboxGroup.js +4 -2
- package/lib/es/form/baseForm.d.ts +1 -1
- package/lib/es/form/field.d.ts +1 -1
- package/lib/es/radio/radioGroup.js +4 -2
- package/lib/es/table/ColumnFilter.js +2 -4
- package/lib/es/table/ColumnSorter.d.ts +0 -1
- package/lib/es/table/ColumnSorter.js +6 -9
- package/lib/es/table/Table.js +4 -10
- package/lib/es/tree/treeNode.d.ts +1 -4
- package/lib/es/tree/treeNode.js +4 -13
- package/lib/es/typography/title.d.ts +1 -1
- package/package.json +7 -7
- package/radio/radioGroup.tsx +2 -0
- package/table/ColumnFilter.tsx +1 -2
- package/table/ColumnSorter.tsx +10 -16
- package/table/Table.tsx +4 -7
- package/tree/treeNode.tsx +5 -11
- package/webpack.config.js +1 -3
package/dist/umd/semi-ui.js
CHANGED
|
@@ -49331,7 +49331,8 @@ class checkboxGroup_CheckboxGroup extends baseComponent_BaseComponent {
|
|
|
49331
49331
|
key: index,
|
|
49332
49332
|
disabled: this.props.disabled,
|
|
49333
49333
|
value: option,
|
|
49334
|
-
prefixCls: prefixCls
|
|
49334
|
+
prefixCls: prefixCls,
|
|
49335
|
+
type: type
|
|
49335
49336
|
}, option);
|
|
49336
49337
|
} else {
|
|
49337
49338
|
return /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement(checkbox_checkbox_0, {
|
|
@@ -49343,7 +49344,8 @@ class checkboxGroup_CheckboxGroup extends baseComponent_BaseComponent {
|
|
|
49343
49344
|
extra: option.extra,
|
|
49344
49345
|
className: option.className,
|
|
49345
49346
|
style: option.style,
|
|
49346
|
-
onChange: option.onChange
|
|
49347
|
+
onChange: option.onChange,
|
|
49348
|
+
type: type
|
|
49347
49349
|
}, option.label);
|
|
49348
49350
|
}
|
|
49349
49351
|
});
|
|
@@ -84334,7 +84336,8 @@ class radioGroup_RadioGroup extends baseComponent_BaseComponent {
|
|
|
84334
84336
|
return /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement(radio_radio_0, {
|
|
84335
84337
|
key: index,
|
|
84336
84338
|
disabled: this.props.disabled,
|
|
84337
|
-
value: option
|
|
84339
|
+
value: option,
|
|
84340
|
+
type: type
|
|
84338
84341
|
}, option);
|
|
84339
84342
|
} else {
|
|
84340
84343
|
return /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement(radio_radio_0, {
|
|
@@ -84343,7 +84346,8 @@ class radioGroup_RadioGroup extends baseComponent_BaseComponent {
|
|
|
84343
84346
|
value: option.value,
|
|
84344
84347
|
extra: option.extra,
|
|
84345
84348
|
className: option.className,
|
|
84346
|
-
style: option.style
|
|
84349
|
+
style: option.style,
|
|
84350
|
+
type: type
|
|
84347
84351
|
}, option.label);
|
|
84348
84352
|
}
|
|
84349
84353
|
});
|
|
@@ -91278,14 +91282,12 @@ function ColumnFilter() {
|
|
|
91278
91282
|
} else {
|
|
91279
91283
|
iconElem = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement("div", {
|
|
91280
91284
|
className: finalCls
|
|
91281
|
-
},
|
|
91282
|
-
/* ZWSP(zero-width space) */
|
|
91283
|
-
, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement(IconFilter, {
|
|
91285
|
+
}, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement(IconFilter, {
|
|
91284
91286
|
role: "button",
|
|
91285
91287
|
"aria-label": "Filter data with this column",
|
|
91286
91288
|
"aria-haspopup": "listbox",
|
|
91287
91289
|
tabIndex: -1,
|
|
91288
|
-
size: "
|
|
91290
|
+
size: "small"
|
|
91289
91291
|
}));
|
|
91290
91292
|
}
|
|
91291
91293
|
|
|
@@ -91311,10 +91313,9 @@ class ColumnSorter_ColumnSorter extends external_root_React_commonjs2_react_comm
|
|
|
91311
91313
|
prefixCls,
|
|
91312
91314
|
onClick,
|
|
91313
91315
|
sortOrder,
|
|
91314
|
-
style
|
|
91315
|
-
title
|
|
91316
|
+
style
|
|
91316
91317
|
} = this.props;
|
|
91317
|
-
const iconBtnSize = '
|
|
91318
|
+
const iconBtnSize = 'small';
|
|
91318
91319
|
const upCls = classnames_default()("".concat(prefixCls, "-column-sorter-up"), {
|
|
91319
91320
|
on: sortOrder === table_constants_strings.SORT_DIRECTIONS[0]
|
|
91320
91321
|
});
|
|
@@ -91333,13 +91334,11 @@ class ColumnSorter_ColumnSorter extends external_root_React_commonjs2_react_comm
|
|
|
91333
91334
|
role: 'button'
|
|
91334
91335
|
}, ariaProps, {
|
|
91335
91336
|
tabIndex: -1,
|
|
91336
|
-
|
|
91337
|
+
style: style,
|
|
91338
|
+
className: "".concat(prefixCls, "-column-sorter"),
|
|
91337
91339
|
onClick: onClick,
|
|
91338
91340
|
onKeyPress: e => utils_isEnterPress(e) && onClick(e)
|
|
91339
|
-
}),
|
|
91340
|
-
style: style,
|
|
91341
|
-
className: "".concat(prefixCls, "-column-sorter")
|
|
91342
|
-
}, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement("span", {
|
|
91341
|
+
}), /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement("span", {
|
|
91343
91342
|
className: "".concat(upCls)
|
|
91344
91343
|
}, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement(IconCaretup, {
|
|
91345
91344
|
size: iconBtnSize
|
|
@@ -91347,7 +91346,7 @@ class ColumnSorter_ColumnSorter extends external_root_React_commonjs2_react_comm
|
|
|
91347
91346
|
className: "".concat(downCls)
|
|
91348
91347
|
}, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement(IconCaretdown, {
|
|
91349
91348
|
size: iconBtnSize
|
|
91350
|
-
})))
|
|
91349
|
+
})));
|
|
91351
91350
|
}
|
|
91352
91351
|
|
|
91353
91352
|
}
|
|
@@ -94878,23 +94877,15 @@ class Table_Table extends baseComponent_BaseComponent {
|
|
|
94878
94877
|
const defaultSortOrder = get_default()(curQuery, 'defaultSortOrder', false);
|
|
94879
94878
|
|
|
94880
94879
|
const sortOrder = _this.foundation.isSortOrderValid(stateSortOrder) ? stateSortOrder : defaultSortOrder;
|
|
94881
|
-
const TitleNode = typeof rawTitle !== 'function' && /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement(external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.Fragment, {
|
|
94882
|
-
key: table_constants_strings.DEFAULT_KEY_COLUMN_TITLE
|
|
94883
|
-
}, rawTitle);
|
|
94884
94880
|
|
|
94885
94881
|
if (typeof column.sorter === 'function' || column.sorter === true) {
|
|
94886
|
-
// In order to increase the click hot area of sorting, when sorting is required & useFullRender is false,
|
|
94887
|
-
// both the title and sorting areas are used as the click hot area for sorting。
|
|
94888
94882
|
const sorter = /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement(ColumnSorter_ColumnSorter, {
|
|
94889
94883
|
key: table_constants_strings.DEFAULT_KEY_COLUMN_SORTER,
|
|
94890
94884
|
sortOrder: sortOrder,
|
|
94891
|
-
onClick: e => _this.foundation.handleSort(column, e)
|
|
94892
|
-
title: TitleNode
|
|
94885
|
+
onClick: e => _this.foundation.handleSort(column, e)
|
|
94893
94886
|
});
|
|
94894
94887
|
useFullRender && (titleMap.sorter = sorter);
|
|
94895
94888
|
titleArr.push(sorter);
|
|
94896
|
-
} else {
|
|
94897
|
-
titleArr.push(TitleNode);
|
|
94898
94889
|
}
|
|
94899
94890
|
|
|
94900
94891
|
const stateFilteredValue = get_default()(curQuery, 'filteredValue');
|
|
@@ -94915,7 +94906,9 @@ class Table_Table extends baseComponent_BaseComponent {
|
|
|
94915
94906
|
titleArr.push(filter);
|
|
94916
94907
|
}
|
|
94917
94908
|
|
|
94918
|
-
const newTitle = typeof rawTitle === 'function' ? () => rawTitle(titleMap) : titleArr
|
|
94909
|
+
const newTitle = typeof rawTitle === 'function' ? () => rawTitle(titleMap) : titleArr.unshift( /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement(external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.Fragment, {
|
|
94910
|
+
key: table_constants_strings.DEFAULT_KEY_COLUMN_TITLE
|
|
94911
|
+
}, rawTitle)) && titleArr;
|
|
94919
94912
|
column = assign_default()(assign_default()({}, column), {
|
|
94920
94913
|
title: newTitle
|
|
94921
94914
|
});
|
|
@@ -101021,11 +101014,7 @@ class treeNode_TreeNode extends external_root_React_commonjs2_react_commonjs_rea
|
|
|
101021
101014
|
});
|
|
101022
101015
|
}
|
|
101023
101016
|
|
|
101024
|
-
renderCheckbox(
|
|
101025
|
-
const {
|
|
101026
|
-
label,
|
|
101027
|
-
icon
|
|
101028
|
-
} = options;
|
|
101017
|
+
renderCheckbox() {
|
|
101029
101018
|
const {
|
|
101030
101019
|
checked,
|
|
101031
101020
|
halfChecked,
|
|
@@ -101042,7 +101031,7 @@ class treeNode_TreeNode extends external_root_React_commonjs2_react_commonjs_rea
|
|
|
101042
101031
|
indeterminate: halfChecked,
|
|
101043
101032
|
checked: checked,
|
|
101044
101033
|
disabled: Boolean(disabled)
|
|
101045
|
-
}
|
|
101034
|
+
}));
|
|
101046
101035
|
}
|
|
101047
101036
|
|
|
101048
101037
|
renderIcon() {
|
|
@@ -101212,8 +101201,6 @@ class treeNode_TreeNode extends external_root_React_commonjs2_react_commonjs_rea
|
|
|
101212
101201
|
const setsize = get_default()(rest, ['data', 'children', 'length']);
|
|
101213
101202
|
|
|
101214
101203
|
const posinset = isString_default()(rest.pos) ? Number(rest.pos.split('-')[level + 1]) + 1 : 1;
|
|
101215
|
-
const label = this.renderRealLabel();
|
|
101216
|
-
const icon = this.renderIcon();
|
|
101217
101204
|
return /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement("li", assign_default()({
|
|
101218
101205
|
className: nodeCls,
|
|
101219
101206
|
role: "treeitem",
|
|
@@ -101233,12 +101220,9 @@ class treeNode_TreeNode extends external_root_React_commonjs2_react_commonjs_rea
|
|
|
101233
101220
|
style: style
|
|
101234
101221
|
}, dragProps), this.renderArrow(), /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement("span", {
|
|
101235
101222
|
className: labelCls
|
|
101236
|
-
}, multiple ? this.renderCheckbox({
|
|
101237
|
-
label,
|
|
101238
|
-
icon
|
|
101239
|
-
}) : null, !multiple && icon, !multiple && /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement("span", {
|
|
101223
|
+
}, multiple ? this.renderCheckbox() : null, this.renderIcon(), /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default.a.createElement("span", {
|
|
101240
101224
|
className: "".concat(treeNode_prefixcls, "-label-text")
|
|
101241
|
-
},
|
|
101225
|
+
}, this.renderRealLabel())));
|
|
101242
101226
|
}
|
|
101243
101227
|
|
|
101244
101228
|
}
|