@sheinx/base 3.8.0-beta.8 → 3.8.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.
Files changed (361) hide show
  1. package/cjs/absolute-list/absolute-list.js +2 -2
  2. package/cjs/absolute-list/use-container.d.ts +1 -0
  3. package/cjs/absolute-list/use-container.d.ts.map +1 -1
  4. package/cjs/absolute-list/use-container.js +3 -0
  5. package/cjs/alert/alert.d.ts.map +1 -1
  6. package/cjs/alert/alert.js +1 -1
  7. package/cjs/avatar/avatar.type.d.ts +5 -0
  8. package/cjs/avatar/avatar.type.d.ts.map +1 -1
  9. package/cjs/avatar/group.js +1 -1
  10. package/cjs/breadcrumb/breadcrumb-item.d.ts +11 -0
  11. package/cjs/breadcrumb/breadcrumb-item.d.ts.map +1 -0
  12. package/cjs/breadcrumb/breadcrumb-item.js +83 -0
  13. package/cjs/breadcrumb/breadcrumb.d.ts.map +1 -1
  14. package/cjs/breadcrumb/breadcrumb.js +34 -32
  15. package/cjs/breadcrumb/breadcrumb.type.d.ts +4 -0
  16. package/cjs/breadcrumb/breadcrumb.type.d.ts.map +1 -1
  17. package/cjs/button/button.type.d.ts +1 -1
  18. package/cjs/button/button.type.d.ts.map +1 -1
  19. package/cjs/cascader/cascader.d.ts.map +1 -1
  20. package/cjs/cascader/cascader.js +3 -5
  21. package/cjs/cascader/cascader.type.d.ts +8 -0
  22. package/cjs/cascader/cascader.type.d.ts.map +1 -1
  23. package/cjs/cascader/node.d.ts.map +1 -1
  24. package/cjs/cascader/node.js +7 -3
  25. package/cjs/config/index.d.ts +23 -0
  26. package/cjs/config/index.d.ts.map +1 -1
  27. package/cjs/config/index.js +7 -0
  28. package/cjs/config/locale/en_US.d.ts +3 -0
  29. package/cjs/config/locale/en_US.d.ts.map +1 -1
  30. package/cjs/config/locale/en_US.js +3 -0
  31. package/cjs/config/locale/zh-CN.d.ts +3 -0
  32. package/cjs/config/locale/zh-CN.d.ts.map +1 -1
  33. package/cjs/config/locale/zh-CN.js +3 -0
  34. package/cjs/date-picker/date-picker.js +1 -1
  35. package/cjs/date-picker/date-picker.type.d.ts +1 -1
  36. package/cjs/date-picker/date-picker.type.d.ts.map +1 -1
  37. package/cjs/date-picker/day.d.ts.map +1 -1
  38. package/cjs/date-picker/time.d.ts.map +1 -1
  39. package/cjs/date-picker/time.js +6 -2
  40. package/cjs/dropdown/Item.d.ts.map +1 -1
  41. package/cjs/dropdown/Item.js +3 -1
  42. package/cjs/empty/empty.d.ts.map +1 -1
  43. package/cjs/empty/empty.js +10 -5
  44. package/cjs/empty/empty.type.d.ts +4 -4
  45. package/cjs/form/form-field.d.ts.map +1 -1
  46. package/cjs/form/form-field.js +25 -2
  47. package/cjs/form/form-field.type.d.ts +12 -21
  48. package/cjs/form/form-field.type.d.ts.map +1 -1
  49. package/cjs/form/form-fieldset.d.ts.map +1 -1
  50. package/cjs/form/form-fieldset.js +55 -3
  51. package/cjs/form/form-fieldset.type.d.ts +35 -23
  52. package/cjs/form/form-fieldset.type.d.ts.map +1 -1
  53. package/cjs/form/form-flow.type.d.ts +11 -7
  54. package/cjs/form/form-flow.type.d.ts.map +1 -1
  55. package/cjs/form/form-item.d.ts.map +1 -1
  56. package/cjs/form/form-item.js +41 -16
  57. package/cjs/form/form-item.type.d.ts +1 -0
  58. package/cjs/form/form-item.type.d.ts.map +1 -1
  59. package/cjs/form/form.d.ts.map +1 -1
  60. package/cjs/form/form.js +2 -1
  61. package/cjs/form/form.type.d.ts +34 -24
  62. package/cjs/form/form.type.d.ts.map +1 -1
  63. package/cjs/form/form.type.js +4 -0
  64. package/cjs/form/index.d.ts +1 -1
  65. package/cjs/form/index.d.ts.map +1 -1
  66. package/cjs/icons/config.d.ts +3 -0
  67. package/cjs/icons/config.d.ts.map +1 -1
  68. package/cjs/icons/config.js +3 -0
  69. package/cjs/icons/icons.d.ts +1 -0
  70. package/cjs/icons/icons.d.ts.map +1 -1
  71. package/cjs/icons/icons.js +150 -1
  72. package/cjs/input/input-number.d.ts.map +1 -1
  73. package/cjs/input/input-number.js +4 -2
  74. package/cjs/input/use-input-common.d.ts +1 -1
  75. package/cjs/list/list.d.ts.map +1 -1
  76. package/cjs/list/list.js +54 -22
  77. package/cjs/list/list.type.d.ts +8 -1
  78. package/cjs/list/list.type.d.ts.map +1 -1
  79. package/cjs/modal/modal-content.d.ts.map +1 -1
  80. package/cjs/modal/modal-content.js +51 -14
  81. package/cjs/modal/modal.d.ts.map +1 -1
  82. package/cjs/modal/modal.js +2 -1
  83. package/cjs/modal/modal.type.d.ts +8 -2
  84. package/cjs/modal/modal.type.d.ts.map +1 -1
  85. package/cjs/pagination/pagination-size-list.d.ts.map +1 -1
  86. package/cjs/pagination/pagination-size-list.js +10 -9
  87. package/cjs/pagination/pagination-size-list.type.d.ts +1 -1
  88. package/cjs/pagination/pagination-size-list.type.d.ts.map +1 -1
  89. package/cjs/pagination/pagination.d.ts.map +1 -1
  90. package/cjs/pagination/pagination.js +10 -2
  91. package/cjs/pagination/pagination.type.d.ts +11 -11
  92. package/cjs/pagination/pagination.type.d.ts.map +1 -1
  93. package/cjs/popover/popover.d.ts.map +1 -1
  94. package/cjs/popover/popover.js +11 -2
  95. package/cjs/radio/group-context.d.ts.map +1 -1
  96. package/cjs/radio/group-context.js +1 -0
  97. package/cjs/radio/radio-group.d.ts.map +1 -1
  98. package/cjs/radio/radio-group.js +5 -1
  99. package/cjs/radio/radio.d.ts.map +1 -1
  100. package/cjs/radio/radio.js +9 -0
  101. package/cjs/radio/radio.type.d.ts +7 -1
  102. package/cjs/radio/radio.type.d.ts.map +1 -1
  103. package/cjs/radio/simple-radio.d.ts.map +1 -1
  104. package/cjs/radio/simple-radio.js +2 -1
  105. package/cjs/select/list-columns.d.ts.map +1 -1
  106. package/cjs/select/list-columns.js +6 -2
  107. package/cjs/select/list.d.ts.map +1 -1
  108. package/cjs/select/list.js +2 -0
  109. package/cjs/select/result-more.d.ts.map +1 -1
  110. package/cjs/select/result-more.js +5 -15
  111. package/cjs/select/result-more.type.d.ts +0 -1
  112. package/cjs/select/result-more.type.d.ts.map +1 -1
  113. package/cjs/select/result.d.ts.map +1 -1
  114. package/cjs/select/result.js +24 -8
  115. package/cjs/select/result.type.d.ts +1 -0
  116. package/cjs/select/result.type.d.ts.map +1 -1
  117. package/cjs/select/select.d.ts.map +1 -1
  118. package/cjs/select/select.js +25 -10
  119. package/cjs/select/select.type.d.ts +206 -127
  120. package/cjs/select/select.type.d.ts.map +1 -1
  121. package/cjs/sticky/sticky.d.ts.map +1 -1
  122. package/cjs/sticky/sticky.js +105 -22
  123. package/cjs/sticky/sticky.type.d.ts +6 -0
  124. package/cjs/sticky/sticky.type.d.ts.map +1 -1
  125. package/cjs/table/table.d.ts.map +1 -1
  126. package/cjs/table/table.js +45 -22
  127. package/cjs/table/table.type.d.ts +81 -82
  128. package/cjs/table/table.type.d.ts.map +1 -1
  129. package/cjs/table/tbody.d.ts.map +1 -1
  130. package/cjs/table/tbody.js +13 -1
  131. package/cjs/table/tbody.type.d.ts +5 -0
  132. package/cjs/table/tbody.type.d.ts.map +1 -1
  133. package/cjs/table/td.d.ts.map +1 -1
  134. package/cjs/table/td.js +5 -23
  135. package/cjs/table/tfoot.d.ts.map +1 -1
  136. package/cjs/table/tfoot.js +6 -2
  137. package/cjs/table/tfoot.type.d.ts +1 -0
  138. package/cjs/table/tfoot.type.d.ts.map +1 -1
  139. package/cjs/table/thead-filter.d.ts.map +1 -1
  140. package/cjs/table/thead-filter.js +17 -7
  141. package/cjs/table/tr.d.ts +1 -0
  142. package/cjs/table/tr.d.ts.map +1 -1
  143. package/cjs/table/tr.js +5 -4
  144. package/cjs/tabs/tabs-header.d.ts.map +1 -1
  145. package/cjs/tabs/tabs-header.js +41 -11
  146. package/cjs/textarea/simple-textarea.d.ts.map +1 -1
  147. package/cjs/textarea/simple-textarea.js +4 -1
  148. package/cjs/tooltip/tooltip.js +2 -1
  149. package/cjs/tree/tree-content.d.ts.map +1 -1
  150. package/cjs/tree/tree-content.js +2 -0
  151. package/cjs/tree/tree-content.type.d.ts +1 -0
  152. package/cjs/tree/tree-content.type.d.ts.map +1 -1
  153. package/cjs/tree/tree-node.type.d.ts +1 -0
  154. package/cjs/tree/tree-node.type.d.ts.map +1 -1
  155. package/cjs/tree/tree-simple-node.d.ts.map +1 -1
  156. package/cjs/tree/tree-simple-node.js +3 -1
  157. package/cjs/tree/tree-virtual-node.d.ts.map +1 -1
  158. package/cjs/tree/tree-virtual-node.js +15 -2
  159. package/cjs/tree/tree-virtual.d.ts.map +1 -1
  160. package/cjs/tree/tree-virtual.js +2 -1
  161. package/cjs/tree/tree.type.d.ts +2 -1
  162. package/cjs/tree/tree.type.d.ts.map +1 -1
  163. package/cjs/tree-select/tree-select.d.ts.map +1 -1
  164. package/cjs/tree-select/tree-select.js +1 -0
  165. package/cjs/tree-select/tree-select.type.d.ts +8 -0
  166. package/cjs/tree-select/tree-select.type.d.ts.map +1 -1
  167. package/cjs/upload/result.d.ts.map +1 -1
  168. package/cjs/upload/result.js +19 -5
  169. package/cjs/upload/useInputClick.d.ts +1 -0
  170. package/cjs/upload/useInputClick.d.ts.map +1 -1
  171. package/cjs/upload/useInputClick.js +4 -0
  172. package/cjs/virtual-scroll/scroll-table.d.ts.map +1 -1
  173. package/cjs/virtual-scroll/scroll-table.js +6 -2
  174. package/cjs/virtual-scroll/virtual-scroll-list.d.ts.map +1 -1
  175. package/cjs/virtual-scroll/virtual-scroll-list.js +8 -2
  176. package/cjs/virtual-scroll/virtual-scroll-list.type.d.ts +1 -0
  177. package/cjs/virtual-scroll/virtual-scroll-list.type.d.ts.map +1 -1
  178. package/esm/absolute-list/absolute-list.js +2 -2
  179. package/esm/absolute-list/use-container.d.ts +1 -0
  180. package/esm/absolute-list/use-container.d.ts.map +1 -1
  181. package/esm/absolute-list/use-container.js +3 -0
  182. package/esm/alert/alert.d.ts.map +1 -1
  183. package/esm/alert/alert.js +1 -1
  184. package/esm/avatar/avatar.type.d.ts +5 -0
  185. package/esm/avatar/avatar.type.d.ts.map +1 -1
  186. package/esm/avatar/group.js +1 -1
  187. package/esm/breadcrumb/breadcrumb-item.d.ts +11 -0
  188. package/esm/breadcrumb/breadcrumb-item.d.ts.map +1 -0
  189. package/esm/breadcrumb/breadcrumb-item.js +76 -0
  190. package/esm/breadcrumb/breadcrumb.d.ts.map +1 -1
  191. package/esm/breadcrumb/breadcrumb.js +34 -33
  192. package/esm/breadcrumb/breadcrumb.type.d.ts +4 -0
  193. package/esm/breadcrumb/breadcrumb.type.d.ts.map +1 -1
  194. package/esm/button/button.type.d.ts +1 -1
  195. package/esm/button/button.type.d.ts.map +1 -1
  196. package/esm/cascader/cascader.d.ts.map +1 -1
  197. package/esm/cascader/cascader.js +3 -5
  198. package/esm/cascader/cascader.type.d.ts +8 -0
  199. package/esm/cascader/cascader.type.d.ts.map +1 -1
  200. package/esm/cascader/node.d.ts.map +1 -1
  201. package/esm/cascader/node.js +7 -3
  202. package/esm/config/index.d.ts +23 -0
  203. package/esm/config/index.d.ts.map +1 -1
  204. package/esm/config/index.js +8 -0
  205. package/esm/config/locale/en_US.d.ts +3 -0
  206. package/esm/config/locale/en_US.d.ts.map +1 -1
  207. package/esm/config/locale/en_US.js +3 -0
  208. package/esm/config/locale/zh-CN.d.ts +3 -0
  209. package/esm/config/locale/zh-CN.d.ts.map +1 -1
  210. package/esm/config/locale/zh-CN.js +3 -0
  211. package/esm/date-picker/date-picker.js +1 -1
  212. package/esm/date-picker/date-picker.type.d.ts +1 -1
  213. package/esm/date-picker/date-picker.type.d.ts.map +1 -1
  214. package/esm/date-picker/day.d.ts.map +1 -1
  215. package/esm/date-picker/time.d.ts.map +1 -1
  216. package/esm/date-picker/time.js +6 -2
  217. package/esm/dropdown/Item.d.ts.map +1 -1
  218. package/esm/dropdown/Item.js +3 -1
  219. package/esm/empty/empty.d.ts.map +1 -1
  220. package/esm/empty/empty.js +10 -5
  221. package/esm/empty/empty.type.d.ts +4 -4
  222. package/esm/form/form-field.d.ts.map +1 -1
  223. package/esm/form/form-field.js +26 -3
  224. package/esm/form/form-field.type.d.ts +12 -21
  225. package/esm/form/form-field.type.d.ts.map +1 -1
  226. package/esm/form/form-fieldset.d.ts.map +1 -1
  227. package/esm/form/form-fieldset.js +55 -3
  228. package/esm/form/form-fieldset.type.d.ts +35 -23
  229. package/esm/form/form-fieldset.type.d.ts.map +1 -1
  230. package/esm/form/form-flow.type.d.ts +11 -7
  231. package/esm/form/form-flow.type.d.ts.map +1 -1
  232. package/esm/form/form-item.d.ts.map +1 -1
  233. package/esm/form/form-item.js +39 -16
  234. package/esm/form/form-item.type.d.ts +1 -0
  235. package/esm/form/form-item.type.d.ts.map +1 -1
  236. package/esm/form/form.d.ts.map +1 -1
  237. package/esm/form/form.js +2 -1
  238. package/esm/form/form.type.d.ts +34 -24
  239. package/esm/form/form.type.d.ts.map +1 -1
  240. package/esm/form/form.type.js +5 -0
  241. package/esm/form/index.d.ts +1 -1
  242. package/esm/form/index.d.ts.map +1 -1
  243. package/esm/icons/config.d.ts +3 -0
  244. package/esm/icons/config.d.ts.map +1 -1
  245. package/esm/icons/config.js +3 -0
  246. package/esm/icons/icons.d.ts +1 -0
  247. package/esm/icons/icons.d.ts.map +1 -1
  248. package/esm/icons/icons.js +150 -1
  249. package/esm/input/input-number.d.ts.map +1 -1
  250. package/esm/input/input-number.js +4 -2
  251. package/esm/input/use-input-common.d.ts +1 -1
  252. package/esm/list/list.d.ts.map +1 -1
  253. package/esm/list/list.js +55 -23
  254. package/esm/list/list.type.d.ts +8 -1
  255. package/esm/list/list.type.d.ts.map +1 -1
  256. package/esm/modal/modal-content.d.ts.map +1 -1
  257. package/esm/modal/modal-content.js +52 -15
  258. package/esm/modal/modal.d.ts.map +1 -1
  259. package/esm/modal/modal.js +2 -1
  260. package/esm/modal/modal.type.d.ts +8 -2
  261. package/esm/modal/modal.type.d.ts.map +1 -1
  262. package/esm/pagination/pagination-size-list.d.ts.map +1 -1
  263. package/esm/pagination/pagination-size-list.js +10 -9
  264. package/esm/pagination/pagination-size-list.type.d.ts +1 -1
  265. package/esm/pagination/pagination-size-list.type.d.ts.map +1 -1
  266. package/esm/pagination/pagination.d.ts.map +1 -1
  267. package/esm/pagination/pagination.js +11 -3
  268. package/esm/pagination/pagination.type.d.ts +11 -11
  269. package/esm/pagination/pagination.type.d.ts.map +1 -1
  270. package/esm/popover/popover.d.ts.map +1 -1
  271. package/esm/popover/popover.js +11 -2
  272. package/esm/radio/group-context.d.ts.map +1 -1
  273. package/esm/radio/group-context.js +1 -0
  274. package/esm/radio/radio-group.d.ts.map +1 -1
  275. package/esm/radio/radio-group.js +5 -2
  276. package/esm/radio/radio.d.ts.map +1 -1
  277. package/esm/radio/radio.js +9 -0
  278. package/esm/radio/radio.type.d.ts +7 -1
  279. package/esm/radio/radio.type.d.ts.map +1 -1
  280. package/esm/radio/simple-radio.d.ts.map +1 -1
  281. package/esm/radio/simple-radio.js +2 -1
  282. package/esm/select/list-columns.d.ts.map +1 -1
  283. package/esm/select/list-columns.js +6 -2
  284. package/esm/select/list.d.ts.map +1 -1
  285. package/esm/select/list.js +2 -0
  286. package/esm/select/result-more.d.ts.map +1 -1
  287. package/esm/select/result-more.js +5 -15
  288. package/esm/select/result-more.type.d.ts +0 -1
  289. package/esm/select/result-more.type.d.ts.map +1 -1
  290. package/esm/select/result.d.ts.map +1 -1
  291. package/esm/select/result.js +24 -8
  292. package/esm/select/result.type.d.ts +1 -0
  293. package/esm/select/result.type.d.ts.map +1 -1
  294. package/esm/select/select.d.ts.map +1 -1
  295. package/esm/select/select.js +25 -10
  296. package/esm/select/select.type.d.ts +206 -127
  297. package/esm/select/select.type.d.ts.map +1 -1
  298. package/esm/sticky/sticky.d.ts.map +1 -1
  299. package/esm/sticky/sticky.js +105 -22
  300. package/esm/sticky/sticky.type.d.ts +6 -0
  301. package/esm/sticky/sticky.type.d.ts.map +1 -1
  302. package/esm/table/table.d.ts.map +1 -1
  303. package/esm/table/table.js +46 -23
  304. package/esm/table/table.type.d.ts +81 -82
  305. package/esm/table/table.type.d.ts.map +1 -1
  306. package/esm/table/tbody.d.ts.map +1 -1
  307. package/esm/table/tbody.js +13 -1
  308. package/esm/table/tbody.type.d.ts +5 -0
  309. package/esm/table/tbody.type.d.ts.map +1 -1
  310. package/esm/table/td.d.ts.map +1 -1
  311. package/esm/table/td.js +4 -20
  312. package/esm/table/tfoot.d.ts.map +1 -1
  313. package/esm/table/tfoot.js +6 -2
  314. package/esm/table/tfoot.type.d.ts +1 -0
  315. package/esm/table/tfoot.type.d.ts.map +1 -1
  316. package/esm/table/thead-filter.d.ts.map +1 -1
  317. package/esm/table/thead-filter.js +17 -7
  318. package/esm/table/tr.d.ts +1 -0
  319. package/esm/table/tr.d.ts.map +1 -1
  320. package/esm/table/tr.js +5 -4
  321. package/esm/tabs/tabs-header.d.ts.map +1 -1
  322. package/esm/tabs/tabs-header.js +41 -11
  323. package/esm/textarea/simple-textarea.d.ts.map +1 -1
  324. package/esm/textarea/simple-textarea.js +4 -1
  325. package/esm/tooltip/tooltip.js +2 -1
  326. package/esm/tree/tree-content.d.ts.map +1 -1
  327. package/esm/tree/tree-content.js +2 -0
  328. package/esm/tree/tree-content.type.d.ts +1 -0
  329. package/esm/tree/tree-content.type.d.ts.map +1 -1
  330. package/esm/tree/tree-node.type.d.ts +1 -0
  331. package/esm/tree/tree-node.type.d.ts.map +1 -1
  332. package/esm/tree/tree-simple-node.d.ts.map +1 -1
  333. package/esm/tree/tree-simple-node.js +3 -1
  334. package/esm/tree/tree-virtual-node.d.ts.map +1 -1
  335. package/esm/tree/tree-virtual-node.js +15 -2
  336. package/esm/tree/tree-virtual.d.ts.map +1 -1
  337. package/esm/tree/tree-virtual.js +2 -1
  338. package/esm/tree/tree.type.d.ts +2 -1
  339. package/esm/tree/tree.type.d.ts.map +1 -1
  340. package/esm/tree-select/tree-select.d.ts.map +1 -1
  341. package/esm/tree-select/tree-select.js +1 -0
  342. package/esm/tree-select/tree-select.type.d.ts +8 -0
  343. package/esm/tree-select/tree-select.type.d.ts.map +1 -1
  344. package/esm/upload/result.d.ts.map +1 -1
  345. package/esm/upload/result.js +20 -6
  346. package/esm/upload/useInputClick.d.ts +1 -0
  347. package/esm/upload/useInputClick.d.ts.map +1 -1
  348. package/esm/upload/useInputClick.js +4 -0
  349. package/esm/virtual-scroll/scroll-table.d.ts.map +1 -1
  350. package/esm/virtual-scroll/scroll-table.js +6 -2
  351. package/esm/virtual-scroll/virtual-scroll-list.d.ts.map +1 -1
  352. package/esm/virtual-scroll/virtual-scroll-list.js +8 -2
  353. package/esm/virtual-scroll/virtual-scroll-list.type.d.ts +1 -0
  354. package/esm/virtual-scroll/virtual-scroll-list.type.d.ts.map +1 -1
  355. package/package.json +3 -3
  356. package/cjs/empty/empty-image.d.ts +0 -2
  357. package/cjs/empty/empty-image.d.ts.map +0 -1
  358. package/cjs/empty/empty-image.js +0 -157
  359. package/esm/empty/empty-image.d.ts +0 -2
  360. package/esm/empty/empty-image.d.ts.map +0 -1
  361. package/esm/empty/empty-image.js +0 -152
@@ -40,6 +40,7 @@ export type SelectClasses = {
40
40
  triggerHover: string;
41
41
  resultTextPadding: string;
42
42
  compressedWrapper: string;
43
+ compressedBoundWrapper: string;
43
44
  multipleCompressedWrapper: string;
44
45
  controlMouse: string;
45
46
  controlKeyboard: string;
@@ -130,6 +131,7 @@ export interface BaseListProps<DataItem, Value> extends Pick<SelectProps<DataIte
130
131
  originalData: any;
131
132
  groupKey?: string;
132
133
  dynamicVirtual?: boolean;
134
+ keepScrollTop?: boolean;
133
135
  controlType?: 'mouse' | 'keyboard';
134
136
  optionListRef: React.MutableRefObject<OptionListRefType | undefined>;
135
137
  isAnimationFinish: boolean;
@@ -139,303 +141,356 @@ export interface BaseListProps<DataItem, Value> extends Pick<SelectProps<DataIte
139
141
  export interface SelectPropsBase<DataItem, Value> extends Omit<BaseSelectProps<DataItem, Value>, 'control' | 'filterSameChange'>, Pick<CommonType, 'className' | 'style' | 'size' | 'status' | 'innerTitle' | 'filterSameChange'>, Pick<AbsoluteListProps, 'absolute' | 'zIndex'>, BaseTipProps {
140
142
  jssStyle?: JssStyleType;
141
143
  /**
142
- * @en custom empty copy
143
- * @cn 自定义 empty 文案。与 renderOptionList 搭配使用时,emptyText 设置为 false 后将忽略该功能,如需渲染空内容可在 renderOptionList 中处理
144
+ * @en Custom empty state content. When used with renderOptionList, setting emptyText to false will disable this feature. You can render custom empty content in renderOptionList
145
+ * @cn 自定义空状态内容。与 renderOptionList 搭配使用时,将 emptyText 设置为 false 可禁用此功能,需要自定义空内容时可在 renderOptionList 中处理
146
+ * @when When no options match the filter or data array is empty
144
147
  */
145
148
  emptyText?: React.ReactNode;
146
149
  /**
147
- * @en Options data
148
- * @cn 选项数据
150
+ * @en Array of option items to display in the dropdown list
151
+ * @cn 下拉列表的选项数据数组
149
152
  * @override DataItem[]
153
+ * @when Use for flat list data structure
150
154
  */
151
155
  data?: DataItem[];
152
156
  /**
153
- * @en Tree data, [{children: []}]
154
- * @cn 树形结构数据项,[{children: []}]
157
+ * @en Tree-structured data with nested children. Format: [{children: [...]}]
158
+ * @cn 树形结构数据,包含嵌套的子节点。格式:[{children: [...]}]
155
159
  * @override Object[]
160
+ * @when Use for hierarchical/nested data structure instead of flat data
156
161
  */
157
162
  treeData?: DataItem[];
158
163
  /**
159
- * @en specify the name of the subdata
160
- * @cn 指定子数据的属性名
164
+ * @en Specifies the property name for child nodes in tree data
165
+ * @cn 指定树形数据中子节点的属性名称
161
166
  * @default 'children'
167
+ * @when When using treeData with a different property name for children
162
168
  */
163
169
  childrenKey?: ObjectKey<DataItem>;
164
170
  /**
165
- * @en Auxiliary method for generating key. When it is a function, use the return value of this function. When it is a string, use the data value corresponding to this string. For example, "id" is the same thing as (d) => d.id
166
- * @cn 生成 key 的辅助方法, 为函数时,使用此函数返回值, 为 string 时,使用这个 string 对应的数据值。如 "id",相当于 (d) => d.id
171
+ * @en Auxiliary method for generating key. When it is a function, use the return value of this function. When it is a string, use the data value corresponding to this string. For example, "id" is the same thing as (d) => d.id. The default value is the array index. For simple arrays (strings/numbers), this works fine. However, for object arrays, you MUST specify a proper keygen to avoid errors. Without a proper keygen, the component will use the entire object as the key, which can cause React rendering errors when renderItem defaults to (d) => d.
172
+ * @cn 生成 key 的辅助方法, 为函数时,使用此函数返回值, 为 string 时,使用这个 string 对应的数据值。如 "id",相当于 (d) => d.id。默认值为数组索引。对于简单数组(字符串/数字),可以使用默认值。但对于对象数组,必须指定合适的 keygen 以避免错误。如果不指定 keygen,组件会将整个对象作为 key,当 renderItem 默认为 (d) => d 时,会导致将对象直接渲染到 DOM 中,引发 React 渲染错误。
167
173
  * @default index
174
+ * @when Always required for object arrays; optional for primitive arrays
168
175
  */
169
176
  keygen: KeygenType<DataItem>;
170
177
  /**
171
- * @en In the Form, the value will be taken over by the form, and the value is invalid. Note: Do not use undefined and null as meaningful option values. When the value type is undefined and null, the component will not process data and rendering
172
- * @cn Form 中,value 会被表单接管,value 无效。注意,请勿将 undefined null 作为有意义的选项值,当 value 类型为 undefinednull 时,组件将不处理数据和渲染
178
+ * @en The selected value(s). In Form context, this prop is managed by Form. Note: Do not use undefined or null as meaningful option values - the component will skip processing when value is undefined/null
179
+ * @cn 选中的值。在表单中使用时,此属性由表单管理。注意:请勿使用 undefined null 作为有效选项值,当 value undefined/null 时组件将跳过处理
173
180
  * @override any
181
+ * @when For controlled component usage; omit when used inside Form
174
182
  */
175
183
  value?: Value;
176
184
  /**
177
- * @en If clearable is true, show clear value icon
178
- * @cn 是否显示清除数据图标
185
+ * @en Shows a clear icon to remove all selected values when enabled
186
+ * @cn 启用时显示清除图标,可一键清空所有选中值
179
187
  * @default false
188
+ * @when When users need ability to quickly clear selection
180
189
  */
181
190
  clearable?: boolean;
182
191
  /**
183
- * @en Placeholder text
184
- * @cn 占位文字
192
+ * @en Placeholder text displayed when no option is selected
193
+ * @cn 未选择任何选项时显示的占位文本
194
+ * @when To provide hint text when select is empty
185
195
  */
186
196
  placeholder?: string;
187
197
  /**
188
- * @en When it is true, a default [Spin](/components/Spin) component will be displayed, a custom loading icon can be passed in to replace.
189
- * @cn 数据加载中,为true时会展示一个默认的 [Spin](/components/Spin) 组件,可以传入一个自定义的Spin代替
198
+ * @en Loading state indicator. Shows default Spin component when true, or accepts custom loading component
199
+ * @cn 加载状态指示器。为 true 时显示默认的 Spin 组件,也可传入自定义加载组件
190
200
  * @override boolean | ReactNode
191
201
  * @default false
202
+ * @when When fetching data asynchronously or during search operations
192
203
  */
193
204
  loading?: boolean | React.ReactNode;
194
205
  /**
195
- * @en Custom render option list header
196
- * @cn 自定义渲染列表头部内容
206
+ * @en Custom content rendered at the top of the dropdown list
207
+ * @cn 自定义下拉列表顶部内容
208
+ * @when To display instructions, filters, or actions above options
197
209
  */
198
210
  header?: React.ReactNode;
199
211
  /**
200
- * @en Custom render option list header
201
- * @cn 自定义渲染列表底部内容
212
+ * @en Custom content rendered at the bottom of the dropdown list
213
+ * @cn 自定义下拉列表底部内容
214
+ * @when To display summary, actions, or load more button below options
202
215
  */
203
216
  footer?: React.ReactNode;
204
217
  /**
205
- * @cn 自定义渲染下拉列表
206
- * @en Custom render dropdown
218
+ * @en Custom render function for the entire dropdown list content. The first parameter `list` contains the pre-rendered option list (including virtual scrolling, columns layout if configured). The second parameter `info` contains: `loading` - current loading state, which can be boolean (shows default spinner when true) or custom ReactNode. Note: When using this prop with emptyText, set emptyText to false to fully control empty state rendering
219
+ * @cn 自定义渲染整个下拉列表内容。第一个参数 `list` 包含预渲染的选项列表(包括虚拟滚动、多列布局等)。第二个参数 `info` 包含:`loading` - 当前加载状态,可为 boolean(true 时显示默认加载动画)或自定义 ReactNode。注意:与 emptyText 配合使用时,将 emptyText 设为 false 可完全控制空状态渲染
220
+ * @when For complete control over dropdown content (e.g., custom wrapper, animations, additional UI elements around the option list)
207
221
  */
208
222
  renderOptionList?: (list: React.ReactNode, info: {
209
223
  loading?: boolean | React.ReactNode;
210
224
  }) => React.ReactNode;
211
225
  /**
212
- * @cn 是否展示边框
213
- * @en Whether to display border
226
+ * @en Controls whether to display the select box border
227
+ * @cn 控制是否显示选择框边框
214
228
  * @default true
229
+ * @when Set to false for borderless design or custom styling
215
230
  */
216
231
  border?: boolean;
217
232
  /**
218
- * @en Only display border bottom
219
- * @cn 是否只展示下边框
233
+ * @en Shows only the bottom border for a minimal underline style
234
+ * @cn 仅显示底部边框,呈现下划线样式
220
235
  * @default false
236
+ * @when For minimal UI design or form-like appearance
221
237
  */
222
238
  underline?: boolean;
223
239
  /**
224
- * @en Set visible of datepicker popup
225
- * @cn 控制浮层显隐
240
+ * @en Controls the visibility of the dropdown list programmatically
241
+ * @cn 程序化控制下拉列表的显示/隐藏状态
242
+ * @when For controlled dropdown state or custom trigger logic
226
243
  */
227
244
  open?: boolean;
228
245
  /**
229
- * @cn 选择框的宽度
230
- * @en Custom width
246
+ * @en Width of the select input box. Accepts number (px) or string with units
247
+ * @cn 选择框的宽度。可接受数字(像素)或带单位的字符串
248
+ * @when To set fixed width instead of default auto-sizing
231
249
  */
232
250
  width?: number | string;
233
251
  /**
234
- * @cn 下拉列表的高度
235
- * @en Custom width
252
+ * @en Maximum height of the dropdown list. Accepts number (px) or string with units
253
+ * @cn 下拉列表的最大高度。可接受数字(像素)或带单位的字符串
254
+ * @when To limit dropdown height when many options exist
236
255
  */
237
256
  height?: number | string;
238
257
  /**
239
- * @cn 下拉列表的宽度
240
- * @en Custom width
258
+ * @en Width of the dropdown list. Accepts number (px) or string with units
259
+ * @cn 下拉列表的宽度。可接受数字(像素)或带单位的字符串
241
260
  * @default 100%
261
+ * @when When dropdown needs different width than select input
242
262
  */
243
263
  optionWidth?: number | string;
244
264
  /**
245
- * @en The maximum number of rows for a single render. Select uses lazy render to optimize performance under large amounts of data. If your table displays more than 10 rows, you can change the value of itemsInView.
246
- * @cn 单次 render 的最大行数。Select 采用了lazy render 的方式来优化在大量数据下的性能,如果你的表格显示的高度超出了 10 条,可以调整 itemsInView
265
+ * @en Maximum number of options rendered at once. Uses virtual scrolling for performance with large datasets. Increase if you need to display more than 10 visible items
266
+ * @cn 一次渲染的最大选项数。使用虚拟滚动优化大数据集性能。如需显示超过 10 个可见项,请调整此值
247
267
  * @default 10
268
+ * @when Increase when dropdown height shows more than 10 items
248
269
  */
249
270
  itemsInView?: number;
250
271
  /**
251
- * @en The height of each option. For performance reasons, Select uses a virtual list to render the options. If the option is a fixed height content, such as a fixed size ReactNode, you can adjust the lineHeight to redistribute the height of each item. When lineHeight is set to auto, dynamic virtual list will be enabled, and the actual height will be adaptive according to the content, and each item will be given a minimum height, which will follow the option height corresponding to the size property. This mode will have a certain performance overhead, please choose different modes according to the actual situation.
252
- * @cn 每一条选项的高度。出于默认性能考虑,Select 采用了虚拟列表的方式渲染列表项,如果选项为高度固定内容,比如一个固定尺寸的 ReactNode,可以通过调整 lineHeight 来重新分配每一项的高度。当 lineHeight 设置为 auto 时,将开启动态虚拟列表,实际高度将根据内容自适应,并赋予每一项最小高度,最小高度跟随 size 属性对应的选项高度,该模式将有一定的性能开销,请根据实际情况选择不同的模式。
272
+ * @en Height of each option item. For fixed-height content, set a number. Use 'auto' for dynamic heights based on content (may impact performance with large datasets)
273
+ * @cn 每个选项的高度。固定高度内容请设置数字;设为 'auto' 则根据内容自适应高度(大数据集时可能影响性能)
253
274
  * @default 32
254
- * @version 3.4.0 新增 auto 模式
275
+ * @version 3.4.0 added 'auto' mode
276
+ * @when Set number for consistent height items; 'auto' for variable content
255
277
  */
256
278
  lineHeight?: number | 'auto';
257
279
  /**
258
- * @en Set Position can control the different position of DatePicker
259
- * @cn 弹出框位置
280
+ * @en Dropdown list placement position. 'auto' adjusts based on available space
281
+ * @cn 下拉列表弹出位置。'auto' 会根据可用空间自动调整
260
282
  * @default auto
283
+ * @when Override auto positioning for specific layout requirements
261
284
  */
262
285
  position?: 'auto' | 'bottom-left' | 'bottom-right' | 'top-left' | 'top-right';
263
286
  /**
264
- * @en Option columns.
265
- * @cn columns 大于 1 时,选项展示为多列布局模式
287
+ * @en Number of columns to display options. Values > 1 enable multi-column layout
288
+ * @cn 选项显示的列数。大于 1 时启用多列布局模式
266
289
  * @default 1
290
+ * @when When many short options need better space utilization
267
291
  */
268
292
  columns?: number;
269
293
  /**
270
- * @en Title of columns multiple select
271
- * @cn 多列选项多选时的标题文字
294
+ * @en Title displayed above columns in multi-column multi-select mode
295
+ * @cn 多列多选模式下,列顶部显示的标题
296
+ * @when Using multi-column layout with multiple selection
272
297
  */
273
298
  columnsTitle?: React.ReactNode;
274
299
  /**
275
- * @en Data cache, if data change asynchronously, better set true
276
- * @cn 是否开启数据缓存,如果数据存在动态更新的情况建议开启
300
+ * @en Disables value-to-data caching. By default, Select caches the mapping between values and data items for performance. When data changes frequently, set this to true to ensure the component always uses the latest data
301
+ * @cn 禁用值与数据项的缓存。默认情况下,Select 会缓存 value 对应的 data 项以优化性能。当 data 频繁变化时,建议设为 true 以确保组件始终使用最新数据
277
302
  * @default false
303
+ * @when When data updates frequently or dynamically
278
304
  */
279
305
  noCache?: boolean;
280
306
  /**
281
- * @en Show dropdown arrow, only single select
282
- * @cn 是否显示下拉箭头,仅针对单选情况
307
+ * @en Shows dropdown arrow icon (single select only)
308
+ * @cn 显示下拉箭头图标(仅单选模式)
283
309
  * @default true
310
+ * @when Set to false for cleaner appearance or custom icon
284
311
  */
285
312
  showArrow?: boolean;
286
313
  /**
287
- * @en onFilter Whether to select filter text after clicking the option in multi-selection situation
288
- * @cn onFilter 在多选情况下点击选项后是否选中过滤文本
314
+ * @en In multi-select with filter, whether to select the filter text after clicking an option
315
+ * @cn 多选模式下启用过滤时,点击选项后是否选中过滤输入框中的文本
289
316
  * @default true
317
+ * @when Set to false to preserve filter text after selection
290
318
  */
291
319
  focusSelected?: boolean;
292
320
  /**
293
- * @en When trim is true, blank characters are automatically deleted when lose focus
294
- * @cn trim 为 true 时,失去焦点时会自动删除空白字符
321
+ * @en Automatically removes leading/trailing whitespace from input on blur
322
+ * @cn 失去焦点时自动删除输入内容的首尾空白字符
295
323
  * @default false
324
+ * @when For cleaner data when users may accidentally input spaces
296
325
  */
297
326
  trim?: boolean;
298
327
  /**
299
- * @en Option column width, only effective when columns > 1
300
- * @cn columns 大于 1 时,选项展示为多列布局模式
328
+ * @en Width of each column in multi-column layout (only when columns > 1)
329
+ * @cn 多列布局中每列的宽度(仅在 columns > 1 时生效)
301
330
  * @default 160
331
+ * @when Adjust based on option content length in multi-column mode
302
332
  */
303
333
  columnWidth?: number;
304
334
  /**
305
- * @en The maximum length of the input string in the Select input box
306
- * @cn Select 输入框输入字符串最大长度
335
+ * @en Maximum character length allowed in the filter input
336
+ * @cn 过滤输入框允许输入的最大字符数
337
+ * @when To limit filter/create input length
307
338
  */
308
339
  maxLength?: number;
309
340
  /**
310
- * @en Set with multiple, value will separator by this
311
- * @cn 多选情况下设置后,value 会处理为 separator 分隔的字符串
341
+ * @en In multi-select mode, joins selected values into a string using this separator
342
+ * @cn 多选模式下,使用此分隔符将选中值连接成字符串
343
+ * @when When backend expects comma-separated or other delimited string
312
344
  */
313
345
  separator?: string;
314
346
  /**
315
- * @en Option list is auto adapt
316
- * @cn 下拉列表宽度根据内容自由展开
347
+ * @en Auto-adjusts dropdown width based on content
348
+ * @cn 下拉列表宽度根据内容自动调整
317
349
  * @default false
350
+ * @when When option content varies significantly in width
318
351
  */
319
352
  autoAdapt?: boolean;
320
353
  /**
321
- * @en Merges selected values, valid only in multiselect mode;When it is "no-repeat", the value is not repeated in the pop-up box
322
- * @cn 将选中值合并,只在多选模式下有效; "no-repeat" 时弹出框中不重复展示值
354
+ * @en Compresses multiple selected items display. true: dynamically calculates and shows '+N' based on container width; 'no-repeat': same as true but hides already selected items from popover; 'hide-popover': shows '+N' without popover
355
+ * @cn 压缩多选项显示。true: 根据容器宽度动态计算并显示 '+N';'no-repeat': 与 true 相同但弹出框中不重复显示已选项;'hide-popover': 仅显示 '+N' 不显示弹出框
323
356
  * @default false
357
+ * @when When multiple selections may exceed container width
324
358
  */
325
359
  compressed?: boolean | 'no-repeat' | 'hide-popover';
326
360
  /**
327
- * @en When compressed is True,the comptessedBound can limit the numbers of multiple selected item"s label
328
- * @cn 开启多选后,指定允许展示标签数量,超过后将折叠
361
+ * @en Fixed number of tags to display before showing '+N'. When set, always shows this many tags regardless of container width. This provides better performance for large datasets as it avoids expensive DOM calculations
362
+ * @cn 固定显示的标签数量,超出部分显示 '+N'。设置后将始终显示指定数量的标签,不再根据容器宽度动态计算。对于大数据集,推荐设置此属性以避免昂贵的 DOM 计算,提升性能
363
+ * @when With compressed mode and many selections for better performance
329
364
  */
330
365
  compressedBound?: number;
331
366
  /**
332
- * @en Compressed popover classname
333
- * @cn 多选合并展示弹出框的类名
367
+ * @en CSS class name for the compressed items popover
368
+ * @cn 压缩项弹出框的 CSS 类名
369
+ * @when To style the compressed items popover
334
370
  */
335
371
  compressedClassName?: string;
336
372
  /**
337
- * @en Custom render compressed content
338
- * @cn 自定义渲染折叠内容
373
+ * @en Custom render function for compressed items display
374
+ * @cn 自定义渲染压缩/折叠项的显示内容
339
375
  * @version 3.5.0
376
+ * @when To customize the '+N' display or compressed content
340
377
  */
341
378
  renderCompressed?: (options: RenderCompressedOption<DataItem>) => React.ReactNode;
342
379
  /**
343
- * @en Hide the creat option while set onCreate
344
- * @cn 在使用创建选项时,在选项列表中隐藏该选项,回车后直接选中
380
+ * @en Hides the create option from the dropdown list. Press Enter to select the created value directly
381
+ * @cn 从下拉列表中隐藏创建选项。按回车键直接选中创建的值
345
382
  * @default false
383
+ * @when With onCreate for cleaner UI when creating is primary action
346
384
  */
347
385
  hideCreateOption?: boolean;
348
386
  /**
349
- * @en Blur to select the data when filter data has only single. only work in filter
350
- * @cn 当筛选数据仅为一条时,失焦后直接选中该条数据。仅在 Filter 下有效
387
+ * @en Auto-selects the only matching option on blur when filtering returns single result
388
+ * @cn 过滤结果仅剩一个选项时,失焦自动选中该选项(仅在启用过滤时有效)
351
389
  * @default false
390
+ * @when For better UX when users expect single match to be selected
352
391
  */
353
392
  filterSingleSelect?: boolean;
354
393
  /**
355
- * @en default expanded nodes
356
- * @cn 默认展开的节点 key(非受控)
394
+ * @en Initially expanded node keys for tree data (uncontrolled)
395
+ * @cn 树形数据中默认展开的节点 key 值(非受控)
357
396
  * @override (string | number)[]
397
+ * @when With treeData to show specific nodes expanded initially
358
398
  */
359
399
  defaultExpanded?: KeygenResult[];
360
400
  /**
361
- * @en Expand all node, only in can be use in treeData
362
- * @cn 默认展开全部子节点, 仅树形数据下有效
401
+ * @en Initially expands all tree nodes (tree data only)
402
+ * @cn 初始展开所有树节点(仅树形数据有效)
363
403
  * @default false
404
+ * @when For small tree datasets where all nodes should be visible
364
405
  */
365
406
  defaultExpandAll?: boolean;
366
407
  /**
367
- * @en Expanded node
368
- * @cn 展开的节点 key(受控)
408
+ * @en Controlled expanded node keys for tree data
409
+ * @cn 树形数据中展开的节点 key 值(受控)
369
410
  * @override (string | number)[]
411
+ * @when For controlled tree expansion state
370
412
  */
371
413
  expanded?: KeygenResult[];
372
414
  /**
373
- * @en Whether to show the descendant nodes of the hit node after filtering
374
- * @cn 筛选后是否展示命中节点的后代节点
415
+ * @en Shows descendant nodes of matched items when filtering tree data
416
+ * @cn 过滤树形数据时,显示匹配项的所有子节点
375
417
  * @default false
418
+ * @when To keep parent-child context visible during search
376
419
  */
377
420
  showHitDescendants?: boolean;
378
421
  /**
379
- * @cn 用来转化粘贴文本中的换行
380
- * @en Used to convert line breaks in pasted text
422
+ * @en Converts line breaks when pasting text. String replaces breaks; function transforms the text
423
+ * @cn 粘贴文本时转换换行符。字符串用于替换换行;函数用于转换文本
381
424
  * @default " "
425
+ * @when When pasting multi-line content with onCreate
382
426
  */
383
427
  convertBr?: string | ((text: string) => string);
384
428
  /**
385
- * @en The className of the selected result content container
386
- * @cn 选中结果内容容器的className
429
+ * @en CSS class name for selected item display. Can be string or function returning class based on value
430
+ * @cn 选中项显示容器的 CSS 类名。可为字符串或基于值返回类名的函数
431
+ * @when To style selected items differently based on value
387
432
  */
388
433
  resultClassName?: ((value: DataItem) => string) | string;
389
434
  /**
390
- * @en When it is a string, return d[string]. When it is a function, return the result of the function
391
- * @cn 为 string 时,返回 d[string]。 为 function 时,返回函数结果
435
+ * @en Renders each option in dropdown. String uses property value; function customizes display
436
+ * @cn 渲染下拉列表中的每个选项。字符串使用属性值;函数自定义显示
392
437
  * @default d => d
438
+ * @when To display complex option content or specific property
393
439
  */
394
440
  renderItem?: ((data: DataItem, index?: number) => React.ReactNode) | ObjectKey<DataItem>;
395
441
  /**
396
- * @en The content displayed in the result after selecting, if not set, use renderItem
397
- * @cn 选中后在结果中显示的内容,默认和 renderItem 相同
442
+ * @en Renders selected items display. Falls back to renderItem if not specified
443
+ * @cn 渲染选中项的显示内容。未指定时使用 renderItem
398
444
  * @default renderItem
445
+ * @when When selected display differs from dropdown display
399
446
  */
400
447
  renderResult?: (data: DataItem, index?: number) => React.ReactNode;
401
448
  /**
402
- * @en The way to render not matched data value
403
- * @cn 渲染未匹配值的方式
449
+ * @en Custom render for values that don't match any option in data
450
+ * @cn 自定义渲染数据中不存在的值
451
+ * @when When value might not exist in current data (e.g., async loading)
404
452
  */
405
453
  renderUnmatched?: (value: Value extends (infer U)[] ? U : Value) => React.ReactNode;
406
454
  /**
407
- * @en blur event callback
408
- * @cn blur 事件回调
455
+ * @en Triggered when the select loses focus
456
+ * @cn 选择框失去焦点时触发
457
+ * @when For form validation or saving draft selections
409
458
  */
410
459
  onBlur?: (e: any) => void;
411
460
  /**
412
- * @en focus event callback
413
- * @cn focus 事件回调
461
+ * @en Triggered when the select receives focus
462
+ * @cn 选择框获得焦点时触发
463
+ * @when To load data, show hints, or track analytics
414
464
  */
415
465
  onFocus?: (e: any) => void;
416
466
  /**
417
- * @en When the onFilter is not empty, you can filter data by input. If the onFilter returns a function, use this function as a front-end filter. If return undefined, you can do your own backend filtering
418
- * @cn onFilter 不为空时,可以输入过滤数据。onFilter 如果返回一个函数,使用这个函数做前端过滤。如果不返回,可以自行做后端过滤
467
+ * @en Enables filtering. Return a function for client-side filtering, or undefined for server-side filtering
468
+ * @cn 启用过滤功能。返回函数用于前端过滤,返回 undefined 用于后端过滤
469
+ * @when For searchable select or large datasets
419
470
  */
420
471
  onFilter?: (text: string, from?: string) => ((data: DataItem) => boolean) | void | undefined;
421
472
  /**
422
- * @en When the onFilter is not empty, you can filter data by input. If the onFilter returns a function, use this function as a front-end filter. If return undefined, you can do your own backend filtering
423
- * @cn 设置 `onCreate` 属性,即可创建选项中不存在的条目;当 `onCreate` 为 true 时,使用默认函数 text => text;当 `onCreate` 为函数时,将此函数返回值作为新的选项插入最上方。
473
+ * @en Creates new options from input. true uses input as-is; function transforms input into option
474
+ * @cn 从输入创建新选项。true 直接使用输入值;函数将输入转换为选项
475
+ * @when For tags input or allowing custom values
424
476
  */
425
477
  onCreate?: ((input: string | DataItem) => DataItem | string) | boolean;
426
478
  /**
427
- * @en Expand option list while enter press
428
- * @cn 回车触发下拉框展开的时候调用
479
+ * @en Called when Enter key is pressed to expand dropdown. Return false to prevent expansion
480
+ * @cn 按回车键展开下拉框时调用。返回 false 阻止展开
481
+ * @when To customize Enter key behavior
429
482
  */
430
483
  onEnterExpand?: (e: React.KeyboardEvent<HTMLDivElement>) => boolean;
431
484
  /**
432
- * @en Option list collapse callback
433
- * @cn 下拉列表展开/收起回调
485
+ * @en Triggered when dropdown opens or closes. Parameter indicates collapsed state
486
+ * @cn 下拉框打开/关闭时触发。参数表示是否收起状态
487
+ * @when To sync UI state or load data on open
434
488
  */
435
489
  onCollapse?: (collapse: boolean) => void;
436
490
  /**
437
- * @en Expand event
438
- * @cn 节点展开回调,参数为当前展开节点 key 数组
491
+ * @en Triggered when tree nodes expand/collapse. Receives array of expanded node keys
492
+ * @cn 树节点展开/收起时触发。接收展开节点的 key 数组
493
+ * @when For controlled tree expansion or tracking state
439
494
  */
440
495
  onExpand?: (value: KeygenResult[]) => void;
441
496
  /**
@@ -443,65 +498,89 @@ export interface SelectPropsBase<DataItem, Value> extends Omit<BaseSelectProps<D
443
498
  * @cn 新增 api ,开启 onFilter 和 onCreate 时,用于比对是否已经存在相同的数据,默认用输入的值和 keygen 值比对
444
499
  */
445
500
  /**
446
- * @en empty input after select value
447
- * @cn 选中后是否清空输入框内容
501
+ * @en Clears filter input after selecting an option
502
+ * @cn 选中选项后清空过滤输入框
448
503
  * @default false
504
+ * @when For better UX in searchable multi-select
449
505
  */
450
506
  emptyAfterSelect?: boolean;
451
507
  /**
452
- * @en ms. The delay of user input triggering filter events
453
- * @cn 毫秒。用户输入触发 fitler 事件的延时
508
+ * @en Debounce delay (ms) for filter input
509
+ * @cn 过滤输入的防抖延迟(毫秒)
454
510
  * @default 400
511
+ * @when Adjust for server-side filtering or performance
455
512
  */
456
513
  filterDelay?: number;
457
514
  /**
458
- * @en Dynamically load nodes
459
- * @cn 设置 loader 属性后,未定义 children 的节点视为动态加载节点,点击展开触发 loader事件,children 为 null 或者长度为 0 视为叶子节点
515
+ * @en Loads children dynamically for tree nodes. Nodes without children trigger loader on expand
516
+ * @cn 动态加载树节点子级。无 children 的节点展开时触发加载
517
+ * @when For lazy-loading large tree structures
460
518
  */
461
519
  loader?: (key: KeygenResult, data: DataItem) => void;
462
520
  /**
463
- * @en In the advanced filter mode, you can switch between the filter results and the original data for the current level by pressing the button
464
- * @cn 高级筛选模式,可针对当前层级在筛选结果和原始数据间切换
521
+ * @en Advanced filter mode allowing toggle between filtered results and original data at current level
522
+ * @cn 高级过滤模式,允许在当前层级的过滤结果和原始数据间切换
523
+ * @when For complex filtering scenarios with toggle capability
465
524
  */
466
525
  onAdvancedFilter?: (text: string) => (data: DataItem) => boolean;
467
526
  /**
468
- * @en There are onFilter and onCreate, select Option, automatically focus Input
469
- * @cn 存在 onFilter 和 onCreate,选中 Option,自动 focus Input
527
+ * @en Auto-focuses filter input after selecting when filter and create are enabled
528
+ * @cn 启用过滤和创建功能时,选中选项后自动聚焦输入框
470
529
  * @default false
530
+ * @when For continuous input in filter+create mode
471
531
  */
472
532
  reFocus?: boolean;
473
533
  /**
474
- * @en Whether to adjust the position of the panel automatically. When the panel is blocked by the window, the position is adjusted automatically
475
- * @cn 是否开启自动调整面板位置功能。当面板被窗口遮挡时,自动调整位置
534
+ * @en Auto-adjusts dropdown position when blocked by viewport edges
535
+ * @cn 下拉框被视口边缘遮挡时自动调整位置
476
536
  * @default true
537
+ * @when Set to false for fixed positioning requirements
477
538
  */
478
539
  adjust?: boolean;
479
540
  /**
480
- * @en Whether to adjust the position of the panel automatically. When the panel is blocked by the window, the position is adjusted automatically
481
- * @cn 滚动加载回的调函数。当配置该属性后,下拉列表滚动到底部时触发该函数
541
+ * @en Triggered when scrolling to bottom of dropdown list for infinite scrolling
542
+ * @cn 滚动到下拉列表底部时触发,用于无限滚动加载
482
543
  * @version 3.4.0
544
+ * @when For pagination or lazy-loading large datasets
483
545
  */
484
546
  onLoadMore?: () => void | Promise<any>;
485
547
  /**
486
- * @en The threshold for triggering the callback function of the scroll load. When the current scroll progress reaches this value, the callback is triggered, and the maximum value is 1, that is, the scroll progress is 100%
487
- * @cn 触发滚动加载回的调函数的阈值。当前滚动进度达到该值时触发,最大值为 1,即滚动进度 100%
548
+ * @en Scroll threshold (0-1) for triggering onLoadMore. 1 means bottom of list
549
+ * @cn 触发 onLoadMore 的滚动阈值(0-1)。1 表示列表底部
488
550
  * @default 1
489
551
  * @version 3.4.0
552
+ * @when Set lower to preload before reaching bottom
490
553
  */
491
554
  threshold?: number;
492
555
  /**
493
- * @cn 触发打开选择面板的方式,默认为点击打开
494
- * @en Trigger the way to open the selection panel, default is click to open
556
+ * @en Trigger mode for opening dropdown
557
+ * @cn 打开下拉框的触发方式
495
558
  * @default 'click'
496
559
  * @version 3.4.0
560
+ * @when Use 'hover' for quick preview scenarios
497
561
  */
498
562
  trigger?: 'click' | 'hover';
499
563
  /**
500
- * @cn 开启搜索关键字高亮功能
501
- * @en Whether to enable highlight feature
564
+ * @en Highlights matching text when filtering
565
+ * @cn 过滤时高亮匹配的文本
502
566
  * @version 3.7.0
567
+ * @when To visually indicate search matches
503
568
  */
504
569
  highlight?: boolean;
570
+ /**
571
+ * @en Whether to prevent selecting existing options when pressing Enter while onCreate is enabled
572
+ * @cn 开启 onCreate 时,是否阻止回车选中已有选项,仅创建选项
573
+ * @default false
574
+ * @version 3.8.0
575
+ */
576
+ preventEnterSelect?: boolean;
577
+ /**
578
+ * @en Triggered when clearing the selected value
579
+ * @cn 清除选中值时触发
580
+ * @version 3.8.0
581
+ * @when For custom clearing behavior
582
+ */
583
+ onClear?: () => void;
505
584
  }
506
585
  export interface SelectPropsA<DataItem, Value> extends Omit<SelectPropsBase<DataItem, Value>, 'treeData' | 'childrenKey'> {
507
586
  /**