@hi-ui/check-select 4.3.6 → 4.4.0
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/CHANGELOG.md +13 -0
- package/lib/cjs/CheckSelect.js +5 -2
- package/lib/esm/CheckSelect.js +5 -2
- package/lib/types/CheckSelect.d.ts +6 -2
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
@@ -1,5 +1,18 @@
|
|
1
1
|
# @hi-ui/check-select
|
2
2
|
|
3
|
+
## 4.4.0
|
4
|
+
|
5
|
+
### Minor Changes
|
6
|
+
|
7
|
+
- [#2746](https://github.com/XiaoMi/hiui/pull/2746) [`b3a13135c`](https://github.com/XiaoMi/hiui/commit/b3a13135c77e75291d5864ff7fcf63ddb2ff46b8) Thanks [@zyprepare](https://github.com/zyprepare)! - feat: add prefix api
|
8
|
+
|
9
|
+
### Patch Changes
|
10
|
+
|
11
|
+
- Updated dependencies [[`a9b9c93fc`](https://github.com/XiaoMi/hiui/commit/a9b9c93fc3a3fea60d14052a5afeef9daf7efa1b), [`b3a13135c`](https://github.com/XiaoMi/hiui/commit/b3a13135c77e75291d5864ff7fcf63ddb2ff46b8), [`ca008e4ae`](https://github.com/XiaoMi/hiui/commit/ca008e4ae9753bc1f11efcdcbf09121d1ef07b56)]:
|
12
|
+
- @hi-ui/input@4.1.0
|
13
|
+
- @hi-ui/tag-input@4.1.0
|
14
|
+
- @hi-ui/tree-utils@4.1.6
|
15
|
+
|
3
16
|
## 4.3.6
|
4
17
|
|
5
18
|
### Patch Changes
|
package/lib/cjs/CheckSelect.js
CHANGED
@@ -89,8 +89,10 @@ var CheckSelect = /*#__PURE__*/React.forwardRef(function (_a, ref) {
|
|
89
89
|
tagInputProps = _a.tagInputProps,
|
90
90
|
_a$size = _a.size,
|
91
91
|
size = _a$size === void 0 ? 'md' : _a$size,
|
92
|
+
prefix = _a.prefix,
|
93
|
+
suffix = _a.suffix,
|
92
94
|
onKeyDownProp = _a.onKeyDown,
|
93
|
-
rest = tslib.__rest(_a, ["prefixCls", "role", "className", "children", "disabled", "clearable", "showCheckAll", "showOnlyShowChecked", "placeholder", "displayRender", "onSelect", "height", "itemHeight", "virtual", "visible", "onOpen", "onClose", "appearance", "invalid", "dataSource", "filterOption", "searchable", "render", "renderExtraFooter", "onSearch", "fieldNames", "customRender", "tagInputProps", "size", "onKeyDown"]);
|
95
|
+
rest = tslib.__rest(_a, ["prefixCls", "role", "className", "children", "disabled", "clearable", "showCheckAll", "showOnlyShowChecked", "placeholder", "displayRender", "onSelect", "height", "itemHeight", "virtual", "visible", "onOpen", "onClose", "appearance", "invalid", "dataSource", "filterOption", "searchable", "render", "renderExtraFooter", "onSearch", "fieldNames", "customRender", "tagInputProps", "size", "prefix", "suffix", "onKeyDown"]);
|
94
96
|
var i18n = core.useLocaleContext();
|
95
97
|
var placeholder = typeAssertion.isUndef(placeholderProp) ? i18n.get('checkSelect.placeholder') : placeholderProp;
|
96
98
|
// ************************** Picker ************************* //
|
@@ -295,7 +297,8 @@ var CheckSelect = /*#__PURE__*/React.forwardRef(function (_a, ref) {
|
|
295
297
|
placeholder: placeholder,
|
296
298
|
// @ts-ignore
|
297
299
|
displayRender: displayRender,
|
298
|
-
|
300
|
+
prefix: prefix,
|
301
|
+
suffix: [menuVisible ? /*#__PURE__*/React__default["default"].createElement(icons.UpOutlined, null) : /*#__PURE__*/React__default["default"].createElement(icons.DownOutlined, null), suffix],
|
299
302
|
focused: menuVisible,
|
300
303
|
appearance: appearance,
|
301
304
|
value: value,
|
package/lib/esm/CheckSelect.js
CHANGED
@@ -75,8 +75,10 @@ var CheckSelect = /*#__PURE__*/forwardRef(function (_a, ref) {
|
|
75
75
|
tagInputProps = _a.tagInputProps,
|
76
76
|
_a$size = _a.size,
|
77
77
|
size = _a$size === void 0 ? 'md' : _a$size,
|
78
|
+
prefix = _a.prefix,
|
79
|
+
suffix = _a.suffix,
|
78
80
|
onKeyDownProp = _a.onKeyDown,
|
79
|
-
rest = __rest(_a, ["prefixCls", "role", "className", "children", "disabled", "clearable", "showCheckAll", "showOnlyShowChecked", "placeholder", "displayRender", "onSelect", "height", "itemHeight", "virtual", "visible", "onOpen", "onClose", "appearance", "invalid", "dataSource", "filterOption", "searchable", "render", "renderExtraFooter", "onSearch", "fieldNames", "customRender", "tagInputProps", "size", "onKeyDown"]);
|
81
|
+
rest = __rest(_a, ["prefixCls", "role", "className", "children", "disabled", "clearable", "showCheckAll", "showOnlyShowChecked", "placeholder", "displayRender", "onSelect", "height", "itemHeight", "virtual", "visible", "onOpen", "onClose", "appearance", "invalid", "dataSource", "filterOption", "searchable", "render", "renderExtraFooter", "onSearch", "fieldNames", "customRender", "tagInputProps", "size", "prefix", "suffix", "onKeyDown"]);
|
80
82
|
var i18n = useLocaleContext();
|
81
83
|
var placeholder = isUndef(placeholderProp) ? i18n.get('checkSelect.placeholder') : placeholderProp;
|
82
84
|
// ************************** Picker ************************* //
|
@@ -281,7 +283,8 @@ var CheckSelect = /*#__PURE__*/forwardRef(function (_a, ref) {
|
|
281
283
|
placeholder: placeholder,
|
282
284
|
// @ts-ignore
|
283
285
|
displayRender: displayRender,
|
284
|
-
|
286
|
+
prefix: prefix,
|
287
|
+
suffix: [menuVisible ? /*#__PURE__*/React.createElement(UpOutlined, null) : /*#__PURE__*/React.createElement(DownOutlined, null), suffix],
|
285
288
|
focused: menuVisible,
|
286
289
|
appearance: appearance,
|
287
290
|
value: value,
|
@@ -75,9 +75,13 @@ export interface CheckSelectProps extends Omit<PickerProps, 'trigger' | 'scrolla
|
|
75
75
|
*/
|
76
76
|
renderExtraFooter?: () => React.ReactNode;
|
77
77
|
/**
|
78
|
-
*
|
78
|
+
* 选择框前置内容
|
79
79
|
*/
|
80
|
-
|
80
|
+
prefix?: React.ReactNode;
|
81
|
+
/**
|
82
|
+
* 选择框后置内容
|
83
|
+
*/
|
84
|
+
suffix?: React.ReactNode;
|
81
85
|
/**
|
82
86
|
* 自定义清除 tags 的 icon
|
83
87
|
*/
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@hi-ui/check-select",
|
3
|
-
"version": "4.
|
3
|
+
"version": "4.4.0",
|
4
4
|
"description": "A sub-package for @hi-ui/hiui.",
|
5
5
|
"keywords": [],
|
6
6
|
"author": "HiUI <mi-hiui@xiaomi.com>",
|
@@ -51,12 +51,12 @@
|
|
51
51
|
"@hi-ui/func-utils": "^4.0.4",
|
52
52
|
"@hi-ui/highlighter": "^4.0.8",
|
53
53
|
"@hi-ui/icons": "^4.0.18",
|
54
|
-
"@hi-ui/input": "^4.0
|
54
|
+
"@hi-ui/input": "^4.1.0",
|
55
55
|
"@hi-ui/picker": "^4.1.5",
|
56
56
|
"@hi-ui/popper": "^4.1.4",
|
57
|
-
"@hi-ui/tag-input": "^4.0
|
57
|
+
"@hi-ui/tag-input": "^4.1.0",
|
58
58
|
"@hi-ui/times": "^4.0.4",
|
59
|
-
"@hi-ui/tree-utils": "^4.1.
|
59
|
+
"@hi-ui/tree-utils": "^4.1.6",
|
60
60
|
"@hi-ui/type-assertion": "^4.0.4",
|
61
61
|
"@hi-ui/use-check": "^4.0.5",
|
62
62
|
"@hi-ui/use-children": "^4.0.4",
|