@hi-ui/tree-select 4.0.0-beta.31 → 4.0.0-beta.32

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.
@@ -100,7 +100,10 @@ var TreeSelect = /*#__PURE__*/React.forwardRef(function (_a, ref) {
100
100
  displayRenderProp = _a.displayRender,
101
101
  placeholderProp = _a.placeholder,
102
102
  appearance = _a.appearance,
103
- rest = tslib.__rest(_a, ["prefixCls", "role", "className", "data", "dataSource", "disabled", "onOpen", "onClose", "fieldNames", "defaultExpandAll", "expandedIds", "defaultExpandedIds", "onExpand", "defaultValue", "value", "onChange", "searchable", "searchMode", "onLoadChildren", "render", "filterOption", "onSearch", "clearable", "invalid", "displayRender", "placeholder", "appearance"]);
103
+ virtual = _a.virtual,
104
+ itemHeight = _a.itemHeight,
105
+ height = _a.height,
106
+ rest = tslib.__rest(_a, ["prefixCls", "role", "className", "data", "dataSource", "disabled", "onOpen", "onClose", "fieldNames", "defaultExpandAll", "expandedIds", "defaultExpandedIds", "onExpand", "defaultValue", "value", "onChange", "searchable", "searchMode", "onLoadChildren", "render", "filterOption", "onSearch", "clearable", "invalid", "displayRender", "placeholder", "appearance", "virtual", "itemHeight", "height"]);
104
107
 
105
108
  var i18n = localeContext.useLocaleContext();
106
109
  var placeholder = typeAssertion.isUndef(placeholderProp) ? i18n.get('treeSelect.placeholder') : placeholderProp;
@@ -283,7 +286,10 @@ var TreeSelect = /*#__PURE__*/React.forwardRef(function (_a, ref) {
283
286
  // onLoadChildren 缓存数据
284
287
  // TODO: 支持 fieldNames
285
288
  // @ts-ignore
286
- onLoadChildren: onLoadChildren
289
+ onLoadChildren: onLoadChildren,
290
+ virtual: virtual,
291
+ itemHeight: itemHeight,
292
+ height: height
287
293
  }, treeProps)) : null);
288
294
  });
289
295
 
@@ -67,7 +67,10 @@ var TreeSelect = /*#__PURE__*/forwardRef(function (_a, ref) {
67
67
  displayRenderProp = _a.displayRender,
68
68
  placeholderProp = _a.placeholder,
69
69
  appearance = _a.appearance,
70
- rest = __rest(_a, ["prefixCls", "role", "className", "data", "dataSource", "disabled", "onOpen", "onClose", "fieldNames", "defaultExpandAll", "expandedIds", "defaultExpandedIds", "onExpand", "defaultValue", "value", "onChange", "searchable", "searchMode", "onLoadChildren", "render", "filterOption", "onSearch", "clearable", "invalid", "displayRender", "placeholder", "appearance"]);
70
+ virtual = _a.virtual,
71
+ itemHeight = _a.itemHeight,
72
+ height = _a.height,
73
+ rest = __rest(_a, ["prefixCls", "role", "className", "data", "dataSource", "disabled", "onOpen", "onClose", "fieldNames", "defaultExpandAll", "expandedIds", "defaultExpandedIds", "onExpand", "defaultValue", "value", "onChange", "searchable", "searchMode", "onLoadChildren", "render", "filterOption", "onSearch", "clearable", "invalid", "displayRender", "placeholder", "appearance", "virtual", "itemHeight", "height"]);
71
74
 
72
75
  var i18n = useLocaleContext();
73
76
  var placeholder = isUndef(placeholderProp) ? i18n.get('treeSelect.placeholder') : placeholderProp;
@@ -250,7 +253,10 @@ var TreeSelect = /*#__PURE__*/forwardRef(function (_a, ref) {
250
253
  // onLoadChildren 缓存数据
251
254
  // TODO: 支持 fieldNames
252
255
  // @ts-ignore
253
- onLoadChildren: onLoadChildren
256
+ onLoadChildren: onLoadChildren,
257
+ virtual: virtual,
258
+ itemHeight: itemHeight,
259
+ height: height
254
260
  }, treeProps)) : null);
255
261
  });
256
262
 
@@ -113,4 +113,18 @@ export interface TreeSelectProps extends Omit<PickerProps, 'data' | 'onChange' |
113
113
  * 设置展现形式
114
114
  */
115
115
  appearance?: HiBaseAppearanceEnum;
116
+ /**
117
+ * 设置虚拟滚动容器的可视高度。暂不对外暴露
118
+ * @private
119
+ */
120
+ height?: number;
121
+ /**
122
+ * 设置虚拟列表每项的固定高度。暂不对外暴露
123
+ * @private
124
+ */
125
+ itemHeight?: number;
126
+ /**
127
+ * 设置 `true` 开启虚拟滚动
128
+ */
129
+ virtual?: boolean;
116
130
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hi-ui/tree-select",
3
- "version": "4.0.0-beta.31",
3
+ "version": "4.0.0-beta.32",
4
4
  "description": "A sub-package for @hi-ui/hiui.",
5
5
  "keywords": [],
6
6
  "author": "HIUI <mi-hiui@xiaomi.com>",
@@ -55,7 +55,7 @@
55
55
  "@hi-ui/locale-context": "^4.0.0-beta.18",
56
56
  "@hi-ui/picker": "^4.0.0-beta.23",
57
57
  "@hi-ui/popper": "^4.0.0-beta.13",
58
- "@hi-ui/tree": "^4.0.0-beta.29",
58
+ "@hi-ui/tree": "^4.0.0-beta.30",
59
59
  "@hi-ui/tree-utils": "^4.0.0-beta.4",
60
60
  "@hi-ui/type-assertion": "^4.0.0-beta.4",
61
61
  "@hi-ui/use-data-source": "^4.0.0-beta.5",
@@ -72,5 +72,5 @@
72
72
  "react": "^17.0.1",
73
73
  "react-dom": "^17.0.1"
74
74
  },
75
- "gitHead": "7f47840510e6dfce429eeed1591c154e321cd14f"
75
+ "gitHead": "1639653e72981dcce445765c8b80866adcffcad0"
76
76
  }