@hi-ui/tree-select 5.0.0-canary.2 → 5.0.0-canary.3

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 CHANGED
@@ -1,5 +1,11 @@
1
1
  # @hi-ui/tree-select
2
2
 
3
+ ## 5.0.0-canary.3
4
+
5
+ ### Patch Changes
6
+
7
+ - a89b3b3ae: fix: 修改组件问题 (5.0)
8
+
3
9
  ## 5.0.0-canary.2
4
10
 
5
11
  ### Patch Changes
@@ -195,9 +195,9 @@ var TreeSelect = /*#__PURE__*/React.forwardRef(function (_a, ref) {
195
195
  }
196
196
  // 本地搜索执行默认高亮规则
197
197
  var highlight = !!searchValue && (searchMode === 'highlight' || searchMode === 'filter');
198
- var ret = highlight ? /*#__PURE__*/React__default["default"].createElement(highlighter.Highlighter, {
199
- keyword: searchValue
200
- }, node.title) : true;
198
+ var ret = highlight ? ( /*#__PURE__*/React__default["default"].createElement(highlighter.Highlighter, {
199
+ keyword: new RegExp(searchValue, 'ig')
200
+ }, node.title)) : true;
201
201
  return ret;
202
202
  }, [titleRender, searchValue, searchMode]);
203
203
  var shouldUseSearch = !!searchValue && !hasError;
@@ -183,9 +183,9 @@ var TreeSelect = /*#__PURE__*/forwardRef(function (_a, ref) {
183
183
  }
184
184
  // 本地搜索执行默认高亮规则
185
185
  var highlight = !!searchValue && (searchMode === 'highlight' || searchMode === 'filter');
186
- var ret = highlight ? /*#__PURE__*/React.createElement(Highlighter, {
187
- keyword: searchValue
188
- }, node.title) : true;
186
+ var ret = highlight ? ( /*#__PURE__*/React.createElement(Highlighter, {
187
+ keyword: new RegExp(searchValue, 'ig')
188
+ }, node.title)) : true;
189
189
  return ret;
190
190
  }, [titleRender, searchValue, searchMode]);
191
191
  var shouldUseSearch = !!searchValue && !hasError;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hi-ui/tree-select",
3
- "version": "5.0.0-canary.2",
3
+ "version": "5.0.0-canary.3",
4
4
  "description": "A sub-package for @hi-ui/hiui.",
5
5
  "keywords": [],
6
6
  "author": "HiUI <mi-hiui@xiaomi.com>",
@@ -68,7 +68,7 @@
68
68
  },
69
69
  "devDependencies": {
70
70
  "@hi-ui/core": "^5.0.0-canary.0",
71
- "@hi-ui/core-css": "^5.0.0-canary.2",
71
+ "@hi-ui/core-css": "^5.0.0-canary.4",
72
72
  "react": "^17.0.1",
73
73
  "react-dom": "^17.0.1"
74
74
  }