@para-ui/core 5.0.0-beta.8 → 5.0.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 (735) hide show
  1. package/AGENTS.md +315 -0
  2. package/AlignBox/component.json +89 -0
  3. package/Anchor/component.json +130 -0
  4. package/Argv/component.json +216 -0
  5. package/AutoBox/component.json +133 -0
  6. package/AutoButton/component.json +109 -0
  7. package/AutoTips/component.json +121 -0
  8. package/Badge/component.json +92 -0
  9. package/Breadcrumbs/component.json +142 -0
  10. package/Button/component.json +168 -0
  11. package/ButtonGroup/component.json +132 -0
  12. package/Card/component.json +162 -0
  13. package/Carousel/component.json +142 -0
  14. package/Cascader/component.json +196 -0
  15. package/Checkbox/component.json +138 -0
  16. package/CheckboxGroup/component.json +152 -0
  17. package/CodeEditor/component.json +189 -0
  18. package/Collapse/component.json +166 -0
  19. package/CollapseBox/component.json +84 -0
  20. package/CollapseLayout/component.json +155 -0
  21. package/ColorPicker/component.json +142 -0
  22. package/ComboSelect/component.json +181 -0
  23. package/Container/component.json +111 -0
  24. package/ContentBox/component.json +81 -0
  25. package/CopyText/component.json +118 -0
  26. package/CycleSelector/component.json +98 -0
  27. package/DatePicker/component.json +192 -0
  28. package/Descriptions/component.json +142 -0
  29. package/Desktop/component.json +171 -0
  30. package/DragVerify/component.json +114 -0
  31. package/Drawer/component.json +200 -0
  32. package/Dropdown/component.json +147 -0
  33. package/DynamicMultiBox/component.json +278 -0
  34. package/Empty/component.json +123 -0
  35. package/ExpressionInput/component.json +79 -0
  36. package/FieldForm/component.json +196 -0
  37. package/Form/component.json +161 -0
  38. package/FormItem/component.json +171 -0
  39. package/FunctionModal/component.json +197 -0
  40. package/Help/component.json +118 -0
  41. package/HelperText/component.json +126 -0
  42. package/Image/component.json +165 -0
  43. package/InputCode/component.json +191 -0
  44. package/InputLang/component.json +205 -0
  45. package/InputNumber/component.json +162 -0
  46. package/Label/component.json +126 -0
  47. package/Loading/component.json +91 -0
  48. package/Menu/component.json +180 -0
  49. package/Message/component.json +246 -0
  50. package/Modal/component.json +277 -0
  51. package/MultiBox/component.json +216 -0
  52. package/Notification/component.json +184 -0
  53. package/OperateBtn/component.json +134 -0
  54. package/PageHeader/component.json +112 -0
  55. package/Pagination/component.json +181 -0
  56. package/PasswordRules/component.json +105 -0
  57. package/PopConfirm/component.json +227 -0
  58. package/PopMenu/component.json +131 -0
  59. package/Popover/component.json +165 -0
  60. package/Progress/component.json +161 -0
  61. package/Prompt/component.json +144 -0
  62. package/Querying/component.json +96 -0
  63. package/QuickReply/component.json +129 -0
  64. package/README.md +0 -5
  65. package/Radio/component.json +136 -0
  66. package/RadioGroup/component.json +149 -0
  67. package/RangeInput/component.json +198 -0
  68. package/Result/component.json +104 -0
  69. package/ScrollBar/component.json +115 -0
  70. package/Search/component.json +177 -0
  71. package/Select/component.json +244 -0
  72. package/SelectInput/component.json +184 -0
  73. package/Selector/component.json +203 -0
  74. package/SelectorPicker/component.json +179 -0
  75. package/SingleBox/component.json +151 -0
  76. package/Slider/component.json +181 -0
  77. package/SortBox/component.json +108 -0
  78. package/Status/component.json +104 -0
  79. package/Stepper/component.json +129 -0
  80. package/Switch/component.json +207 -0
  81. package/Table/component.json +547 -0
  82. package/Tabs/component.json +227 -0
  83. package/Tag/component.json +221 -0
  84. package/TextEditor/component.json +186 -0
  85. package/TextField/component.json +290 -0
  86. package/TimePicker/component.json +176 -0
  87. package/Timeline/component.json +110 -0
  88. package/Title/component.json +156 -0
  89. package/ToggleButton/component.json +153 -0
  90. package/Tooltip/component.json +176 -0
  91. package/Transfer/component.json +157 -0
  92. package/Tree/component.json +512 -0
  93. package/Upload/component.json +450 -0
  94. package/ai-workflows/01-crud-list-multi-drawer.md +278 -0
  95. package/ai-workflows/02-rbac-operation-buttons.md +290 -0
  96. package/ai-workflows/03-complex-form-async-cascade.md +350 -0
  97. package/ai-workflows/04-array-field-form.md +281 -0
  98. package/ai-workflows/05-popconfirm-async-message-queue.md +333 -0
  99. package/ai-workflows/06-modal-drawer-form-workflow.md +385 -0
  100. package/ai-workflows/07-search-filter-table-trio.md +387 -0
  101. package/ai-workflows/08-table-advanced-features.md +365 -0
  102. package/ai-workflows/09-batch-operation-export-progress.md +367 -0
  103. package/ai-workflows/10-cross-component-state-coordination.md +412 -0
  104. package/es/AlignBox/component.json +89 -0
  105. package/es/AlignBox/index.css +1 -1
  106. package/es/AlignBox/index.d.ts +6 -2
  107. package/es/AlignBox/index.js +1 -1
  108. package/es/AlignBox/style/index.css +1 -1
  109. package/es/Anchor/anchorMenu/index.d.ts +2 -1
  110. package/es/Anchor/anchorMenu/index.js +36 -33
  111. package/es/Anchor/component.json +130 -0
  112. package/es/Anchor/index.js +52 -49
  113. package/es/Anchor/type.d.ts +8 -4
  114. package/es/Argv/batchEdit/index.js +1 -1
  115. package/es/Argv/component.json +216 -0
  116. package/es/Argv/dataGenerator/index.js +1 -1
  117. package/es/Argv/index.d.ts +5 -6
  118. package/es/Argv/index.js +1 -1
  119. package/es/AutoBox/component.json +133 -0
  120. package/es/AutoBox/index.d.ts +3 -3
  121. package/es/AutoBox/index.js +1 -1
  122. package/es/AutoBox/protal.d.ts +2 -2
  123. package/es/AutoBox/protal.js +33 -30
  124. package/es/AutoButton/component.json +109 -0
  125. package/es/AutoButton/index.js +1 -1
  126. package/es/AutoTips/autoTipsMultiline/index.d.ts +1 -1
  127. package/es/AutoTips/autoTipsMultiline/index.js +1 -1
  128. package/es/AutoTips/component.json +121 -0
  129. package/es/AutoTips/index.js +1 -1
  130. package/es/Badge/component.json +92 -0
  131. package/es/Breadcrumbs/component.json +142 -0
  132. package/es/Breadcrumbs/index.js +1 -1
  133. package/es/Button/SplitButton.d.ts +2 -2
  134. package/es/Button/component.json +168 -0
  135. package/es/Button/index.js +44 -44
  136. package/es/ButtonGroup/component.json +132 -0
  137. package/es/ButtonGroup/index.d.ts +1 -1
  138. package/es/Card/component.json +162 -0
  139. package/es/Card/index.d.ts +2 -2
  140. package/es/Card/index.js +2 -2
  141. package/es/Carousel/component.json +142 -0
  142. package/es/Carousel/index.d.ts +1 -1
  143. package/es/Cascader/Cascader.js +1 -1
  144. package/es/Cascader/OptionList/Column.js +1 -1
  145. package/es/Cascader/OptionList/index.js +1 -1
  146. package/es/Cascader/component.json +196 -0
  147. package/es/Cascader/hooks/useEntities.js +7 -7
  148. package/es/Cascader/interface.d.ts +1 -0
  149. package/es/Cascader/utils/commonUtil.d.ts +1 -1
  150. package/es/Cascader/utils/commonUtil.js +16 -16
  151. package/es/Cascader/utils/treeUtil.d.ts +14 -5
  152. package/es/Cascader/utils/treeUtil.js +1 -1
  153. package/es/Checkbox/component.json +138 -0
  154. package/es/CheckboxGroup/component.json +152 -0
  155. package/es/CheckboxGroup/index.js +1 -1
  156. package/es/CodeEditor/component.json +189 -0
  157. package/es/CodeEditor/index.d.ts +11 -10
  158. package/es/CodeEditor/index.js +25 -25
  159. package/es/Collapse/component.json +166 -0
  160. package/es/Collapse/index.d.ts +1 -1
  161. package/es/Collapse/index.js +23 -22
  162. package/es/CollapseBox/component.json +84 -0
  163. package/es/CollapseLayout/component.json +155 -0
  164. package/es/ColorPicker/component.json +142 -0
  165. package/es/ComboSelect/component.json +181 -0
  166. package/es/ComboSelect/index.js +115 -109
  167. package/es/ComboSelect/interface.d.ts +2 -2
  168. package/es/ComboSelect/utils.d.ts +3 -3
  169. package/es/ComboSelect/utils.js +1 -1
  170. package/es/Container/component.json +111 -0
  171. package/es/ContentBox/component.json +81 -0
  172. package/es/CopyText/component.json +118 -0
  173. package/es/CycleSelector/component.json +98 -0
  174. package/es/CycleSelector/index.js +14 -13
  175. package/es/DatePicker/component.json +192 -0
  176. package/es/DatePicker/generatePicker/generateRangePicker.js +11 -11
  177. package/es/DatePicker/generatePicker/generateSinglePicker.js +2 -2
  178. package/es/Descriptions/component.json +142 -0
  179. package/es/Descriptions/index.d.ts +1 -1
  180. package/es/Desktop/component.json +171 -0
  181. package/es/Desktop/index.js +1 -1
  182. package/es/DragVerify/component.json +114 -0
  183. package/es/DragVerify/index.js +19 -19
  184. package/es/Drawer/component.json +200 -0
  185. package/es/Drawer/index.js +86 -86
  186. package/es/Drawer/interface.d.ts +1 -1
  187. package/es/Drawer/util.d.ts +1 -6
  188. package/es/Drawer/util.js +9 -6
  189. package/es/Dropdown/component.json +147 -0
  190. package/es/Dropdown/index.js +1 -1
  191. package/es/DynamicMultiBox/component.json +278 -0
  192. package/es/DynamicMultiBox/formItem.d.ts +1 -1
  193. package/es/DynamicMultiBox/index.d.ts +2 -2
  194. package/es/DynamicMultiBox/index.js +1 -1
  195. package/es/DynamicMultiBox/interface.d.ts +76 -76
  196. package/es/DynamicMultiBox/rowForm.d.ts +2 -2
  197. package/es/Empty/component.json +123 -0
  198. package/es/Empty/index.css +1 -1
  199. package/es/Empty/index.d.ts +2 -2
  200. package/es/Empty/index.js +27 -26
  201. package/es/Empty/style/index.css +1 -1
  202. package/es/ExpressionInput/HighlightOverlay.d.ts +8 -0
  203. package/es/ExpressionInput/HighlightOverlay.js +27 -0
  204. package/es/ExpressionInput/Popup.d.ts +19 -0
  205. package/es/ExpressionInput/Popup.js +93 -0
  206. package/es/ExpressionInput/component.json +79 -0
  207. package/es/ExpressionInput/detectChainAtCursor.d.ts +17 -0
  208. package/es/ExpressionInput/detectChainAtCursor.js +31 -0
  209. package/es/ExpressionInput/filterCandidatesByPartial.d.ts +2 -0
  210. package/es/ExpressionInput/filterCandidatesByPartial.js +15 -0
  211. package/es/ExpressionInput/highlightSegments.d.ts +9 -0
  212. package/es/ExpressionInput/highlightSegments.js +14 -0
  213. package/es/ExpressionInput/index.css +1 -0
  214. package/es/ExpressionInput/index.d.ts +5 -0
  215. package/es/ExpressionInput/index.js +178 -0
  216. package/es/ExpressionInput/interface.d.ts +52 -0
  217. package/es/ExpressionInput/isExpressionValue.d.ts +5 -0
  218. package/es/ExpressionInput/isExpressionValue.js +18 -0
  219. package/es/ExpressionInput/lang/en_US.d.ts +4 -0
  220. package/es/ExpressionInput/lang/en_US.js +7 -0
  221. package/es/ExpressionInput/lang/index.d.ts +9 -0
  222. package/es/ExpressionInput/lang/index.js +10 -0
  223. package/es/ExpressionInput/lang/zh_CN.d.ts +4 -0
  224. package/es/ExpressionInput/lang/zh_CN.js +7 -0
  225. package/es/ExpressionInput/style/css.js +1 -0
  226. package/es/ExpressionInput/style/index.css +1 -0
  227. package/es/ExpressionInput/style/index.js +1 -0
  228. package/es/ExpressionInput/useExpressionInput.d.ts +26 -0
  229. package/es/ExpressionInput/useExpressionInput.js +59 -0
  230. package/es/FieldForm/FieldFormItem/ItemHolder.js +1 -1
  231. package/es/FieldForm/FieldFormItem/MemoInput.d.ts +2 -2
  232. package/es/FieldForm/FieldFormItem/StatusProvider.js +1 -1
  233. package/es/FieldForm/FieldFormItem/index.d.ts +6 -6
  234. package/es/FieldForm/Form.d.ts +2 -2
  235. package/es/FieldForm/Form.js +1 -1
  236. package/es/FieldForm/FormItemInput.js +1 -1
  237. package/es/FieldForm/FormItemLabel.js +1 -1
  238. package/es/FieldForm/FormList.d.ts +2 -2
  239. package/es/FieldForm/component.json +196 -0
  240. package/es/FieldForm/context.d.ts +5 -1
  241. package/es/FieldForm/context.js +2 -2
  242. package/es/FieldForm/hooks/useForm.d.ts +4 -3
  243. package/es/FieldForm/hooks/useFormInstance.d.ts +1 -1
  244. package/es/FieldForm/hooks/useFormItemStatus.d.ts +9 -5
  245. package/es/FieldForm/hooks/useFormItemStatus.js +2 -2
  246. package/es/FieldForm/hooks/useItemRef.d.ts +1 -1
  247. package/es/FieldForm/hooks/useItemRef.js +6 -6
  248. package/es/Form/component.json +161 -0
  249. package/es/Form/index.d.ts +52 -49
  250. package/es/Form/index.js +1 -1
  251. package/es/FormItem/compoments/defaultCompoments/index.d.ts +5 -5
  252. package/es/FormItem/compoments/defaultCompoments/index.js +12 -11
  253. package/es/FormItem/compoments/formCheckboxGroup/index.d.ts +2 -2
  254. package/es/FormItem/compoments/formFile/index.js +8 -8
  255. package/es/FormItem/compoments/formRadioGroup/index.d.ts +1 -1
  256. package/es/FormItem/compoments/formSelect/index.d.ts +1 -1
  257. package/es/FormItem/component.json +171 -0
  258. package/es/FormItem/index.d.ts +5 -5
  259. package/es/FormItem/index.js +23 -23
  260. package/es/FormItem/itemType.js +1 -1
  261. package/es/FunctionModal/component.json +197 -0
  262. package/es/FunctionModal/dialog.d.ts +1 -1
  263. package/es/FunctionModal/modalContext.d.ts +4 -1
  264. package/es/GlobalContext/confirmLocale.js +1 -1
  265. package/es/GlobalContext/index.js +1 -1
  266. package/es/Help/component.json +118 -0
  267. package/es/HelperText/component.json +126 -0
  268. package/es/Image/PreviewGroup.js +1 -1
  269. package/es/Image/component.json +165 -0
  270. package/es/Image/index.js +1 -1
  271. package/es/InputCode/component.json +191 -0
  272. package/es/InputCode/index.d.ts +2 -2
  273. package/es/InputCode/index.js +1 -1
  274. package/es/InputLang/component.json +205 -0
  275. package/es/InputLang/index.js +2 -2
  276. package/es/InputNumber/component.json +162 -0
  277. package/es/InputNumber/index.d.ts +13 -7
  278. package/es/InputNumber/index.js +152 -144
  279. package/es/Label/component.json +126 -0
  280. package/es/Label/index.d.ts +2 -2
  281. package/es/Loading/component.json +91 -0
  282. package/es/Menu/component.json +180 -0
  283. package/es/Menu/verticalMenuList.js +1 -1
  284. package/es/Message/component.json +246 -0
  285. package/es/Message/index.d.ts +2 -2
  286. package/es/Message/index.js +19 -19
  287. package/es/Modal/Confirm/index.d.ts +1 -1
  288. package/es/Modal/Confirm/index.js +1 -1
  289. package/es/Modal/component.json +277 -0
  290. package/es/Modal/index.d.ts +85 -5
  291. package/es/Modal/index.js +159 -122
  292. package/es/Modal/interface.d.ts +1 -0
  293. package/es/MultiBox/component.json +216 -0
  294. package/es/MultiBox/index.js +19 -14
  295. package/es/Notification/component.json +184 -0
  296. package/es/OperateBtn/component.json +134 -0
  297. package/es/OperateBtn/index.d.ts +3 -3
  298. package/es/PageHeader/component.json +112 -0
  299. package/es/PageHeader/horizontalMeun.js +1 -1
  300. package/es/PageHeader/horizontalMeunRight.js +1 -1
  301. package/es/Pagination/component.json +181 -0
  302. package/es/Pagination/index.js +15 -15
  303. package/es/ParauiProvider/index.js +1 -1
  304. package/es/PasswordRules/component.json +105 -0
  305. package/es/PasswordRules/index.d.ts +4 -4
  306. package/es/PopConfirm/component.json +227 -0
  307. package/es/PopConfirm/index.d.ts +1 -1
  308. package/es/PopConfirm/index.js +1 -1
  309. package/es/PopMenu/component.json +131 -0
  310. package/es/PopMenu/hooks.d.ts +1 -1
  311. package/es/PopMenu/index.js +8 -8
  312. package/es/Popover/component.json +165 -0
  313. package/es/Popover/index.js +1 -1
  314. package/es/Progress/component.json +161 -0
  315. package/es/Prompt/component.json +144 -0
  316. package/es/Querying/component.json +96 -0
  317. package/es/Querying/index.css +1 -1
  318. package/es/Querying/index.d.ts +2 -2
  319. package/es/Querying/index.js +20 -19
  320. package/es/Querying/style/index.css +1 -1
  321. package/es/QuickReply/QuickReplyCode/index.js +1 -1
  322. package/es/QuickReply/component.json +129 -0
  323. package/es/QuickReply/index.d.ts +1 -1
  324. package/es/Radio/component.json +136 -0
  325. package/es/RadioGroup/component.json +149 -0
  326. package/es/RangeInput/component.json +198 -0
  327. package/es/RangeInput/index.d.ts +15 -7
  328. package/es/RangeInput/index.js +120 -103
  329. package/es/Result/component.json +104 -0
  330. package/es/ScrollBar/component.json +115 -0
  331. package/es/Search/component.json +177 -0
  332. package/es/Search/index.d.ts +1 -1
  333. package/es/Select/component.json +244 -0
  334. package/es/Select/index.d.ts +11 -8
  335. package/es/Select/index.js +441 -438
  336. package/es/SelectInput/component.json +184 -0
  337. package/es/SelectInput/index.d.ts +4 -4
  338. package/es/SelectInput/index.js +8 -8
  339. package/es/Selector/component.json +203 -0
  340. package/es/Selector/index.js +56 -50
  341. package/es/Selector/interface.d.ts +2 -2
  342. package/es/Selector/selectorData/index.js +1 -1
  343. package/es/Selector/selectorMain/index.js +3 -3
  344. package/es/Selector/selectorNode/index.js +1 -1
  345. package/es/Selector/util.d.ts +3 -3
  346. package/es/Selector/util.js +6 -12
  347. package/es/SelectorPicker/component.json +179 -0
  348. package/es/SelectorPicker/index.d.ts +5 -5
  349. package/es/SelectorPicker/index.js +15 -15
  350. package/es/SingleBox/component.json +151 -0
  351. package/es/SingleBox/index.d.ts +2 -2
  352. package/es/Slider/component.json +181 -0
  353. package/es/SortBox/component.json +108 -0
  354. package/es/Status/component.json +104 -0
  355. package/es/Stepper/component.json +129 -0
  356. package/es/Stepper/index.d.ts +2 -2
  357. package/es/Switch/component.json +207 -0
  358. package/es/Switch/index.css +1 -1
  359. package/es/Switch/index.d.ts +3 -2
  360. package/es/Switch/index.js +60 -59
  361. package/es/Switch/style/index.css +1 -1
  362. package/es/Table/component.json +547 -0
  363. package/es/Table/index.d.ts +2 -2
  364. package/es/Table/index.js +385 -382
  365. package/es/Table/interface.d.ts +30 -0
  366. package/es/Table/tableHead.js +1 -1
  367. package/es/Table/util.d.ts +1 -1
  368. package/es/Table/util.js +3 -12
  369. package/es/Tabs/component.json +227 -0
  370. package/es/Tag/component.json +221 -0
  371. package/es/Tag/index.css +1 -1
  372. package/es/Tag/index.d.ts +1 -1
  373. package/es/Tag/index.js +20 -20
  374. package/es/Tag/style/index.css +1 -1
  375. package/es/TextEditor/component.json +186 -0
  376. package/es/TextEditor/index.d.ts +5 -5
  377. package/es/TextEditor/index.js +1 -1
  378. package/es/TextField/component.json +290 -0
  379. package/es/TextField/index.d.ts +2 -2
  380. package/es/TextField/index.js +1 -1
  381. package/es/TimePicker/component.json +176 -0
  382. package/es/Timeline/component.json +110 -0
  383. package/es/Title/component.json +156 -0
  384. package/es/ToggleButton/component.json +153 -0
  385. package/es/ToggleButton/index.js +1 -1
  386. package/es/Tooltip/component.json +176 -0
  387. package/es/Tooltip/index.js +58 -53
  388. package/es/Tooltip/interface.d.ts +14 -1
  389. package/es/Tooltip/utils.js +6 -6
  390. package/es/Transfer/component.json +157 -0
  391. package/es/Tree/OperateBar/index.js +1 -1
  392. package/es/Tree/Tree.js +3 -3
  393. package/es/Tree/component.json +512 -0
  394. package/es/Tree/interface.d.ts +1 -1
  395. package/es/Upload/component.json +450 -0
  396. package/es/Upload/util.js +1 -1
  397. package/es/Utils/snack-kit-shims.d.ts +18 -0
  398. package/es/Utils/snack-kit-shims.js +19 -0
  399. package/es/Utils/type.d.ts +0 -6
  400. package/es/_virtual/index.js +5 -3
  401. package/es/_virtual/index2.js +2 -5
  402. package/es/index.d.ts +4 -0
  403. package/es/index.js +152 -150
  404. package/es/locale/en-US.d.ts +3 -0
  405. package/es/locale/en-US.js +3 -0
  406. package/es/locale/en_US.d.ts +361 -0
  407. package/es/locale/en_US.js +364 -0
  408. package/es/locale/index.d.ts +1 -723
  409. package/es/locale/index2.js +10 -0
  410. package/es/locale/zh-CN.d.ts +3 -0
  411. package/es/locale/zh-CN.js +3 -0
  412. package/es/locale/zh_CN.d.ts +361 -0
  413. package/es/locale/zh_CN.js +364 -0
  414. package/es/node_modules/classnames/index.js +1 -1
  415. package/lib/AlignBox/component.json +89 -0
  416. package/lib/AlignBox/index.css +1 -1
  417. package/lib/AlignBox/index.d.ts +6 -2
  418. package/lib/AlignBox/index.js +1 -1
  419. package/lib/AlignBox/style/index.css +1 -1
  420. package/lib/Anchor/anchorMenu/index.d.ts +2 -1
  421. package/lib/Anchor/anchorMenu/index.js +1 -1
  422. package/lib/Anchor/component.json +130 -0
  423. package/lib/Anchor/index.js +1 -1
  424. package/lib/Anchor/type.d.ts +8 -4
  425. package/lib/Argv/component.json +216 -0
  426. package/lib/Argv/dataGenerator/index.js +1 -1
  427. package/lib/Argv/index.d.ts +5 -6
  428. package/lib/Argv/index.js +1 -1
  429. package/lib/AutoBox/component.json +133 -0
  430. package/lib/AutoBox/index.d.ts +3 -3
  431. package/lib/AutoBox/index.js +1 -1
  432. package/lib/AutoBox/protal.d.ts +2 -2
  433. package/lib/AutoBox/protal.js +1 -1
  434. package/lib/AutoButton/component.json +109 -0
  435. package/lib/AutoButton/index.js +1 -1
  436. package/lib/AutoTips/autoTipsMultiline/index.d.ts +1 -1
  437. package/lib/AutoTips/autoTipsMultiline/index.js +1 -1
  438. package/lib/AutoTips/component.json +121 -0
  439. package/lib/AutoTips/index.js +1 -1
  440. package/lib/Badge/component.json +92 -0
  441. package/lib/Breadcrumbs/component.json +142 -0
  442. package/lib/Breadcrumbs/index.js +1 -1
  443. package/lib/Button/SplitButton.d.ts +2 -2
  444. package/lib/Button/component.json +168 -0
  445. package/lib/Button/index.js +1 -1
  446. package/lib/ButtonGroup/component.json +132 -0
  447. package/lib/ButtonGroup/index.d.ts +1 -1
  448. package/lib/Card/component.json +162 -0
  449. package/lib/Card/index.d.ts +2 -2
  450. package/lib/Card/index.js +1 -1
  451. package/lib/Carousel/component.json +142 -0
  452. package/lib/Carousel/index.d.ts +1 -1
  453. package/lib/Cascader/Cascader.js +1 -1
  454. package/lib/Cascader/OptionList/Column.js +1 -1
  455. package/lib/Cascader/OptionList/index.js +1 -1
  456. package/lib/Cascader/component.json +196 -0
  457. package/lib/Cascader/hooks/useEntities.js +1 -1
  458. package/lib/Cascader/interface.d.ts +1 -0
  459. package/lib/Cascader/utils/commonUtil.d.ts +1 -1
  460. package/lib/Cascader/utils/commonUtil.js +1 -1
  461. package/lib/Cascader/utils/treeUtil.d.ts +14 -5
  462. package/lib/Cascader/utils/treeUtil.js +1 -1
  463. package/lib/Checkbox/component.json +138 -0
  464. package/lib/CheckboxGroup/component.json +152 -0
  465. package/lib/CheckboxGroup/index.js +1 -1
  466. package/lib/CodeEditor/component.json +189 -0
  467. package/lib/CodeEditor/index.d.ts +11 -10
  468. package/lib/CodeEditor/index.js +1 -1
  469. package/lib/Collapse/component.json +166 -0
  470. package/lib/Collapse/index.d.ts +1 -1
  471. package/lib/Collapse/index.js +1 -1
  472. package/lib/CollapseBox/component.json +84 -0
  473. package/lib/CollapseLayout/component.json +155 -0
  474. package/lib/ColorPicker/component.json +142 -0
  475. package/lib/ComboSelect/component.json +181 -0
  476. package/lib/ComboSelect/index.js +1 -1
  477. package/lib/ComboSelect/interface.d.ts +2 -2
  478. package/lib/ComboSelect/utils.d.ts +3 -3
  479. package/lib/ComboSelect/utils.js +1 -1
  480. package/lib/Container/component.json +111 -0
  481. package/lib/ContentBox/component.json +81 -0
  482. package/lib/CopyText/component.json +118 -0
  483. package/lib/CycleSelector/component.json +98 -0
  484. package/lib/CycleSelector/index.js +1 -1
  485. package/lib/DatePicker/component.json +192 -0
  486. package/lib/DatePicker/generatePicker/generateRangePicker.js +1 -1
  487. package/lib/DatePicker/generatePicker/generateSinglePicker.js +1 -1
  488. package/lib/Descriptions/component.json +142 -0
  489. package/lib/Descriptions/index.d.ts +1 -1
  490. package/lib/Desktop/component.json +171 -0
  491. package/lib/Desktop/index.js +1 -1
  492. package/lib/DragVerify/component.json +114 -0
  493. package/lib/DragVerify/index.js +1 -1
  494. package/lib/Drawer/component.json +200 -0
  495. package/lib/Drawer/index.js +1 -1
  496. package/lib/Drawer/interface.d.ts +1 -1
  497. package/lib/Drawer/util.d.ts +1 -6
  498. package/lib/Drawer/util.js +1 -1
  499. package/lib/Dropdown/component.json +147 -0
  500. package/lib/Dropdown/index.js +1 -1
  501. package/lib/DynamicMultiBox/component.json +278 -0
  502. package/lib/DynamicMultiBox/formItem.d.ts +1 -1
  503. package/lib/DynamicMultiBox/index.d.ts +2 -2
  504. package/lib/DynamicMultiBox/index.js +1 -1
  505. package/lib/DynamicMultiBox/interface.d.ts +76 -76
  506. package/lib/DynamicMultiBox/rowForm.d.ts +2 -2
  507. package/lib/Empty/component.json +123 -0
  508. package/lib/Empty/index.css +1 -1
  509. package/lib/Empty/index.d.ts +2 -2
  510. package/lib/Empty/index.js +1 -1
  511. package/lib/Empty/style/index.css +1 -1
  512. package/lib/ExpressionInput/HighlightOverlay.d.ts +8 -0
  513. package/lib/ExpressionInput/HighlightOverlay.js +2 -0
  514. package/lib/ExpressionInput/Popup.d.ts +19 -0
  515. package/lib/ExpressionInput/Popup.js +2 -0
  516. package/lib/ExpressionInput/component.json +79 -0
  517. package/lib/ExpressionInput/detectChainAtCursor.d.ts +17 -0
  518. package/lib/ExpressionInput/detectChainAtCursor.js +2 -0
  519. package/lib/ExpressionInput/filterCandidatesByPartial.d.ts +2 -0
  520. package/lib/ExpressionInput/filterCandidatesByPartial.js +2 -0
  521. package/lib/ExpressionInput/highlightSegments.d.ts +9 -0
  522. package/lib/ExpressionInput/highlightSegments.js +2 -0
  523. package/lib/ExpressionInput/index.css +1 -0
  524. package/lib/ExpressionInput/index.d.ts +5 -0
  525. package/lib/ExpressionInput/index.js +2 -0
  526. package/lib/ExpressionInput/interface.d.ts +52 -0
  527. package/lib/ExpressionInput/isExpressionValue.d.ts +5 -0
  528. package/lib/ExpressionInput/isExpressionValue.js +2 -0
  529. package/lib/ExpressionInput/lang/en_US.d.ts +4 -0
  530. package/lib/ExpressionInput/lang/en_US.js +2 -0
  531. package/lib/ExpressionInput/lang/index.d.ts +9 -0
  532. package/lib/ExpressionInput/lang/index.js +2 -0
  533. package/lib/ExpressionInput/lang/zh_CN.d.ts +4 -0
  534. package/lib/ExpressionInput/lang/zh_CN.js +2 -0
  535. package/lib/ExpressionInput/style/css.js +1 -0
  536. package/lib/ExpressionInput/style/index.css +1 -0
  537. package/lib/ExpressionInput/style/index.js +1 -0
  538. package/lib/ExpressionInput/useExpressionInput.d.ts +26 -0
  539. package/lib/ExpressionInput/useExpressionInput.js +2 -0
  540. package/lib/FieldForm/FieldFormItem/ItemHolder.js +1 -1
  541. package/lib/FieldForm/FieldFormItem/MemoInput.d.ts +2 -2
  542. package/lib/FieldForm/FieldFormItem/StatusProvider.js +1 -1
  543. package/lib/FieldForm/FieldFormItem/index.d.ts +6 -6
  544. package/lib/FieldForm/Form.d.ts +2 -2
  545. package/lib/FieldForm/Form.js +1 -1
  546. package/lib/FieldForm/FormItemInput.js +1 -1
  547. package/lib/FieldForm/FormItemLabel.js +1 -1
  548. package/lib/FieldForm/FormList.d.ts +2 -2
  549. package/lib/FieldForm/component.json +196 -0
  550. package/lib/FieldForm/context.d.ts +5 -1
  551. package/lib/FieldForm/context.js +1 -1
  552. package/lib/FieldForm/hooks/useForm.d.ts +4 -3
  553. package/lib/FieldForm/hooks/useFormInstance.d.ts +1 -1
  554. package/lib/FieldForm/hooks/useFormItemStatus.d.ts +9 -5
  555. package/lib/FieldForm/hooks/useFormItemStatus.js +1 -1
  556. package/lib/FieldForm/hooks/useItemRef.d.ts +1 -1
  557. package/lib/FieldForm/hooks/useItemRef.js +1 -1
  558. package/lib/Form/component.json +161 -0
  559. package/lib/Form/index.d.ts +52 -49
  560. package/lib/Form/index.js +1 -1
  561. package/lib/FormItem/compoments/defaultCompoments/index.d.ts +5 -5
  562. package/lib/FormItem/compoments/defaultCompoments/index.js +1 -1
  563. package/lib/FormItem/compoments/formCheckboxGroup/index.d.ts +2 -2
  564. package/lib/FormItem/compoments/formFile/index.js +1 -1
  565. package/lib/FormItem/compoments/formRadioGroup/index.d.ts +1 -1
  566. package/lib/FormItem/compoments/formSelect/index.d.ts +1 -1
  567. package/lib/FormItem/component.json +171 -0
  568. package/lib/FormItem/index.d.ts +5 -5
  569. package/lib/FormItem/index.js +1 -1
  570. package/lib/FormItem/itemType.js +1 -1
  571. package/lib/FunctionModal/component.json +197 -0
  572. package/lib/FunctionModal/dialog.d.ts +1 -1
  573. package/lib/FunctionModal/modalContext.d.ts +4 -1
  574. package/lib/GlobalContext/confirmLocale.js +1 -1
  575. package/lib/GlobalContext/index.js +1 -1
  576. package/lib/Help/component.json +118 -0
  577. package/lib/HelperText/component.json +126 -0
  578. package/lib/Image/PreviewGroup.js +1 -1
  579. package/lib/Image/component.json +165 -0
  580. package/lib/Image/index.js +1 -1
  581. package/lib/InputCode/component.json +191 -0
  582. package/lib/InputCode/index.d.ts +2 -2
  583. package/lib/InputLang/component.json +205 -0
  584. package/lib/InputLang/index.js +1 -1
  585. package/lib/InputNumber/component.json +162 -0
  586. package/lib/InputNumber/index.d.ts +13 -7
  587. package/lib/InputNumber/index.js +1 -1
  588. package/lib/Label/component.json +126 -0
  589. package/lib/Label/index.d.ts +2 -2
  590. package/lib/Loading/component.json +91 -0
  591. package/lib/Menu/component.json +180 -0
  592. package/lib/Menu/verticalMenuList.js +1 -1
  593. package/lib/Message/component.json +246 -0
  594. package/lib/Message/index.d.ts +2 -2
  595. package/lib/Message/index.js +1 -1
  596. package/lib/Modal/Confirm/index.d.ts +1 -1
  597. package/lib/Modal/Confirm/index.js +1 -1
  598. package/lib/Modal/component.json +277 -0
  599. package/lib/Modal/index.d.ts +85 -5
  600. package/lib/Modal/index.js +1 -1
  601. package/lib/Modal/interface.d.ts +1 -0
  602. package/lib/MultiBox/component.json +216 -0
  603. package/lib/MultiBox/index.js +1 -1
  604. package/lib/Notification/component.json +184 -0
  605. package/lib/OperateBtn/component.json +134 -0
  606. package/lib/OperateBtn/index.d.ts +3 -3
  607. package/lib/PageHeader/component.json +112 -0
  608. package/lib/PageHeader/horizontalMeun.js +1 -1
  609. package/lib/PageHeader/horizontalMeunRight.js +1 -1
  610. package/lib/Pagination/component.json +181 -0
  611. package/lib/Pagination/index.js +1 -1
  612. package/lib/ParauiProvider/index.js +1 -1
  613. package/lib/PasswordRules/component.json +105 -0
  614. package/lib/PasswordRules/index.d.ts +4 -4
  615. package/lib/PopConfirm/component.json +227 -0
  616. package/lib/PopConfirm/index.d.ts +1 -1
  617. package/lib/PopConfirm/index.js +1 -1
  618. package/lib/PopMenu/component.json +131 -0
  619. package/lib/PopMenu/hooks.d.ts +1 -1
  620. package/lib/PopMenu/index.js +1 -1
  621. package/lib/Popover/component.json +165 -0
  622. package/lib/Popover/index.js +1 -1
  623. package/lib/Progress/component.json +161 -0
  624. package/lib/Prompt/component.json +144 -0
  625. package/lib/Querying/component.json +96 -0
  626. package/lib/Querying/index.css +1 -1
  627. package/lib/Querying/index.d.ts +2 -2
  628. package/lib/Querying/index.js +1 -1
  629. package/lib/Querying/style/index.css +1 -1
  630. package/lib/QuickReply/QuickReplyCode/index.js +1 -1
  631. package/lib/QuickReply/component.json +129 -0
  632. package/lib/QuickReply/index.d.ts +1 -1
  633. package/lib/Radio/component.json +136 -0
  634. package/lib/RadioGroup/component.json +149 -0
  635. package/lib/RangeInput/component.json +198 -0
  636. package/lib/RangeInput/index.d.ts +15 -7
  637. package/lib/RangeInput/index.js +1 -1
  638. package/lib/Result/component.json +104 -0
  639. package/lib/ScrollBar/component.json +115 -0
  640. package/lib/Search/component.json +177 -0
  641. package/lib/Search/index.d.ts +1 -1
  642. package/lib/Select/component.json +244 -0
  643. package/lib/Select/index.d.ts +11 -8
  644. package/lib/Select/index.js +1 -1
  645. package/lib/SelectInput/component.json +184 -0
  646. package/lib/SelectInput/index.d.ts +4 -4
  647. package/lib/SelectInput/index.js +1 -1
  648. package/lib/Selector/component.json +203 -0
  649. package/lib/Selector/index.js +1 -1
  650. package/lib/Selector/interface.d.ts +2 -2
  651. package/lib/Selector/selectorData/index.js +1 -1
  652. package/lib/Selector/selectorMain/index.js +1 -1
  653. package/lib/Selector/selectorNode/index.js +1 -1
  654. package/lib/Selector/util.d.ts +3 -3
  655. package/lib/Selector/util.js +1 -1
  656. package/lib/SelectorPicker/component.json +179 -0
  657. package/lib/SelectorPicker/index.d.ts +5 -5
  658. package/lib/SelectorPicker/index.js +1 -1
  659. package/lib/SingleBox/component.json +151 -0
  660. package/lib/SingleBox/index.d.ts +2 -2
  661. package/lib/Slider/component.json +181 -0
  662. package/lib/SortBox/component.json +108 -0
  663. package/lib/Status/component.json +104 -0
  664. package/lib/Stepper/component.json +129 -0
  665. package/lib/Stepper/index.d.ts +2 -2
  666. package/lib/Switch/component.json +207 -0
  667. package/lib/Switch/index.css +1 -1
  668. package/lib/Switch/index.d.ts +3 -2
  669. package/lib/Switch/index.js +1 -1
  670. package/lib/Switch/style/index.css +1 -1
  671. package/lib/Table/component.json +547 -0
  672. package/lib/Table/index.d.ts +2 -2
  673. package/lib/Table/index.js +1 -1
  674. package/lib/Table/interface.d.ts +30 -0
  675. package/lib/Table/tableHead.js +1 -1
  676. package/lib/Table/util.d.ts +1 -1
  677. package/lib/Table/util.js +1 -1
  678. package/lib/Tabs/component.json +227 -0
  679. package/lib/Tag/component.json +221 -0
  680. package/lib/Tag/index.css +1 -1
  681. package/lib/Tag/index.d.ts +1 -1
  682. package/lib/Tag/index.js +1 -1
  683. package/lib/Tag/style/index.css +1 -1
  684. package/lib/TextEditor/component.json +186 -0
  685. package/lib/TextEditor/index.d.ts +5 -5
  686. package/lib/TextEditor/index.js +1 -1
  687. package/lib/TextField/component.json +290 -0
  688. package/lib/TextField/index.d.ts +2 -2
  689. package/lib/TextField/index.js +1 -1
  690. package/lib/TimePicker/component.json +176 -0
  691. package/lib/Timeline/component.json +110 -0
  692. package/lib/Title/component.json +156 -0
  693. package/lib/ToggleButton/component.json +153 -0
  694. package/lib/ToggleButton/index.js +1 -1
  695. package/lib/Tooltip/component.json +176 -0
  696. package/lib/Tooltip/index.js +1 -1
  697. package/lib/Tooltip/interface.d.ts +14 -1
  698. package/lib/Tooltip/utils.js +1 -1
  699. package/lib/Transfer/component.json +157 -0
  700. package/lib/Tree/OperateBar/index.js +2 -2
  701. package/lib/Tree/Tree.js +1 -1
  702. package/lib/Tree/component.json +512 -0
  703. package/lib/Tree/interface.d.ts +1 -1
  704. package/lib/Upload/component.json +450 -0
  705. package/lib/Upload/util.js +1 -1
  706. package/lib/Utils/snack-kit-shims.d.ts +18 -0
  707. package/lib/Utils/snack-kit-shims.js +2 -0
  708. package/lib/Utils/type.d.ts +0 -6
  709. package/lib/_virtual/index.js +1 -1
  710. package/lib/_virtual/index2.js +1 -1
  711. package/lib/index.d.ts +4 -0
  712. package/lib/index.js +1 -1
  713. package/lib/locale/en-US.d.ts +3 -0
  714. package/lib/locale/en-US.js +1 -1
  715. package/lib/locale/en_US.d.ts +361 -0
  716. package/lib/locale/en_US.js +2 -0
  717. package/lib/locale/index.d.ts +1 -723
  718. package/lib/locale/index2.js +2 -0
  719. package/lib/locale/zh-CN.d.ts +3 -0
  720. package/lib/locale/zh-CN.js +1 -1
  721. package/lib/locale/zh_CN.d.ts +361 -0
  722. package/lib/locale/zh_CN.js +2 -0
  723. package/lib/node_modules/classnames/index.js +1 -1
  724. package/package.json +24 -4
  725. package/es/_virtual/index3.js +0 -5
  726. package/es/_virtual/index4.js +0 -5
  727. package/es/node_modules/@para-snack/core/dist/index.js +0 -5231
  728. package/lib/_virtual/index3.js +0 -2
  729. package/lib/_virtual/index4.js +0 -2
  730. package/lib/node_modules/@para-snack/core/dist/index.js +0 -20
  731. /package/es/{InputCode → CodeEditor}/index.css +0 -0
  732. /package/es/{Utils/Hooks → Hooks}/useResizeObserver.d.ts +0 -0
  733. /package/es/{Utils/Hooks → Hooks}/useResizeObserver.js +0 -0
  734. /package/lib/{Utils/Hooks → Hooks}/useResizeObserver.d.ts +0 -0
  735. /package/lib/{Utils/Hooks → Hooks}/useResizeObserver.js +0 -0
@@ -0,0 +1,93 @@
1
+ import { j as t } from "../_virtual/jsx-runtime.js";
2
+ import * as p from "react";
3
+ import { Lock as S } from "../node_modules/@para-ui/icons/Lock/index.js";
4
+ import { $prefixCls as o } from "../GlobalContext/constant.js";
5
+ const i = 30, d = 240, m = 4, b = p.forwardRef((v, g) => {
6
+ const {
7
+ instanceClass: T,
8
+ visible: $,
9
+ rect: a,
10
+ header: j,
11
+ candidates: s,
12
+ highlight: h,
13
+ virtualizeThreshold: w,
14
+ onSelect: N,
15
+ onHighlightChange: E
16
+ } = v, [H, x] = p.useState(0), c = p.useRef(null);
17
+ if (p.useEffect(() => {
18
+ x(0), c.current && (c.current.scrollTop = 0);
19
+ }, [s]), p.useEffect(() => {
20
+ const e = c.current;
21
+ if (!e)
22
+ return;
23
+ const n = h * i, r = e.scrollTop, f = r + e.clientHeight;
24
+ n < r ? e.scrollTop = n : n + i > f && (e.scrollTop = n + i - e.clientHeight);
25
+ }, [h]), !$ || s.length === 0)
26
+ return null;
27
+ const l = s.length > w, u = l ? Math.max(0, Math.floor(H / i) - m) : 0, M = l ? Math.ceil(d / i) + m * 2 : s.length, R = l ? Math.min(s.length, u + M) : s.length, y = s.slice(u, R), C = u * i;
28
+ return /* @__PURE__ */ t.jsxs(
29
+ "div",
30
+ {
31
+ ref: g,
32
+ className: `${o}-expression-input-popup ${T}`,
33
+ style: { position: "fixed", top: a.top, left: a.left, width: a.width },
34
+ children: [
35
+ /* @__PURE__ */ t.jsx("div", { className: `${o}-expression-input-popup-header`, children: j }),
36
+ /* @__PURE__ */ t.jsx(
37
+ "div",
38
+ {
39
+ ref: c,
40
+ className: `${o}-expression-input-popup-list`,
41
+ style: { maxHeight: d, overflowY: "auto" },
42
+ onScroll: (e) => {
43
+ l && x(e.currentTarget.scrollTop);
44
+ },
45
+ children: /* @__PURE__ */ t.jsx("div", { style: { height: l ? s.length * i : void 0, position: "relative" }, children: /* @__PURE__ */ t.jsx(
46
+ "div",
47
+ {
48
+ style: {
49
+ position: l ? "absolute" : void 0,
50
+ top: l ? C : void 0,
51
+ left: 0,
52
+ right: 0
53
+ },
54
+ children: y.map((e, n) => {
55
+ const r = u + n, f = r === h;
56
+ return /* @__PURE__ */ t.jsxs(
57
+ "div",
58
+ {
59
+ "data-testid": `expr-candidate-row-${e.value}`,
60
+ className: `${o}-expression-input-popup-item${f ? ` ${o}-expression-input-popup-item-active` : ""}`,
61
+ style: { height: i },
62
+ onMouseEnter: () => E(r),
63
+ onMouseDown: (I) => {
64
+ I.preventDefault(), N(e);
65
+ },
66
+ children: [
67
+ /* @__PURE__ */ t.jsx("span", { className: `${o}-expression-input-popup-item-value`, children: e.label ?? e.value }),
68
+ e.desc && /* @__PURE__ */ t.jsx("span", { className: `${o}-expression-input-popup-item-desc`, children: e.desc }),
69
+ e.sensitive && /* @__PURE__ */ t.jsx(
70
+ S,
71
+ {
72
+ "data-testid": `expr-candidate-lock-${e.value}`,
73
+ className: `${o}-expression-input-popup-item-lock`
74
+ }
75
+ )
76
+ ]
77
+ },
78
+ e.value
79
+ );
80
+ })
81
+ }
82
+ ) })
83
+ }
84
+ )
85
+ ]
86
+ }
87
+ );
88
+ });
89
+ b.displayName = "Popup";
90
+ export {
91
+ b as Popup
92
+ };
93
+ //# sourceMappingURL=Popup.js.map
@@ -0,0 +1,79 @@
1
+ {
2
+ "name": "ExpressionInput",
3
+ "category": "数据录入",
4
+ "description": "单行表达式变量自动补全输入框,默认要求 {{ }} 包裹触发,候选数据完全由业务方通过 resolveCandidates 注入。",
5
+ "semantic": {
6
+ "intent": ["在文本中输入引用变量的表达式", "按命名空间层级下钻选择变量"],
7
+ "useCases": ["脚本/配置里引用运行时变量", "低代码画布属性面板里的表达式绑定"],
8
+ "riskLevel": "low"
9
+ },
10
+ "variants": {
11
+ "braces": { "meaning": "默认触发模式,要求光标位于 {{ }} 区间内才弹出候选" },
12
+ "bare": { "meaning": "不要求大括号包裹,任意位置匹配 triggerPrefix 即弹出候选" }
13
+ },
14
+ "states": ["default", "focus", "disabled", "readOnly", "popup-open"],
15
+ "idealProps": {
16
+ "value": { "type": "string", "description": "受控值", "required": false },
17
+ "onChange": { "type": "function", "description": "值变化回调", "signature": "(value: string) => void" },
18
+ "resolveCandidates": {
19
+ "type": "function",
20
+ "description": "按命名空间路径返回该层级的完整候选列表,组件内部按 parts 缓存",
21
+ "signature": "(parts: string[]) => ExprCandidate[]",
22
+ "required": true
23
+ },
24
+ "triggerMode": {
25
+ "type": "string",
26
+ "description": "触发匹配机制",
27
+ "values": ["braces", "bare"],
28
+ "default": "braces"
29
+ },
30
+ "triggerPrefix": { "type": "string", "description": "触发前缀符号", "default": "$" },
31
+ "virtualizeThreshold": { "type": "number", "description": "候选数超过该阈值启用虚拟滚动", "default": "50" },
32
+ "renderPopupHeader": {
33
+ "type": "function",
34
+ "description": "自定义浮层 header 文案",
35
+ "signature": "(ctx: ExprChainCtx, count: number) => React.ReactNode",
36
+ "required": false
37
+ },
38
+ "expressionTooltip": {
39
+ "type": "ReactNode",
40
+ "description": "表达式说明 tooltip 文案,不传则不展示;仅当 value 命中表达式格式(braces/bare)时 hover/focus 才弹出",
41
+ "required": false
42
+ }
43
+ },
44
+ "commonMisconceptions": [
45
+ "以为 resolveCandidates 每次按键都会被调用——实际只有下钻/回退到新的命名空间层级时才调用,同层级内逐字过滤是客户端完成的",
46
+ "以为默认触发不需要 {{ }} 包裹——默认 triggerMode 是 'braces',裸写 $.xxx 不会触发,需要显式传 triggerMode='bare' 才对齐 Ditto 原始行为",
47
+ "以为传入的 candidate.value 可以是任意字符串——实际必须是合法标识符字符([A-Za-z0-9_$]),否则插入后再次解析会被截断",
48
+ "以为 expressionTooltip 会随打字实时弹出/消失——实际是否命中只在 hover/focus 触发那一刻判定,光标停留期间继续输入使 value 从未命中变为命中不会自动弹出,需要重新 hover/focus",
49
+ "以为花括号着色和 expressionTooltip 用同一套判定标准——实际着色只看 {{ }} 是否配对闭合,不校验内容合法性,门槛比 expressionTooltip 低,{{$.}} 这类值会着色但不会弹出 tooltip,两者可能不一致,这是预期行为"
50
+ ],
51
+ "do": [
52
+ "为需要继续下钻子级的候选项设置 chain: true,让选中后自动追加 . 方便连续输入",
53
+ "为敏感字段设置 sensitive: true,组件会自动展示锁图标",
54
+ "在 Modal/Drawer 中使用时无需额外处理,组件内部已对接 usePopupContainer 自动寻找最近可滚动祖先容器"
55
+ ],
56
+ "dont": [
57
+ "不要在 resolveCandidates 内部做未做缓存的重量级计算并假设组件会防抖——组件只在 parts 变化时调用一次,但单次调用本身仍需业务方保证足够快",
58
+ "不要给多个实例传相同的 DOM id 或手动操作 document.body 上的浮层 — 组件已经用 UUID 做了实例隔离"
59
+ ],
60
+ "events": {
61
+ "onChange": {
62
+ "signature": "(value: string) => void",
63
+ "asyncSupported": false,
64
+ "examples": ["受控更新 value 状态"],
65
+ "commonMistakes": ["忘记把新 value 传回 props.value,导致组件表现为不可编辑"]
66
+ }
67
+ },
68
+ "typescriptPitfalls": [
69
+ {
70
+ "issue": "resolveCandidates 类型签名从 ChainCtx 变成了 parts: string[]",
71
+ "wrong": "resolveCandidates={(ctx) => ctx.partial ? [] : rootCandidates}",
72
+ "right": "resolveCandidates={(parts) => parts.length === 0 ? rootCandidates : []}"
73
+ }
74
+ ],
75
+ "mapping": {
76
+ "realComponent": "ExpressionInput",
77
+ "adapter": "无,直接使用"
78
+ }
79
+ }
@@ -0,0 +1,17 @@
1
+ /** partial 片段本身允许出现的字符(不含 .) */
2
+ export declare const ID_TAIL: RegExp;
3
+ export interface DetectChainOptions {
4
+ triggerPrefix: string;
5
+ triggerMode: 'braces' | 'bare';
6
+ }
7
+ export interface ChainResult {
8
+ /** 链路在原文本中的起始下标(含前缀符号) */
9
+ startIdx: number;
10
+ /** 链路在原文本中的结束下标(即光标位置) */
11
+ endIdx: number;
12
+ /** 已确定的上级片段 */
13
+ parts: string[];
14
+ /** 正在输入的片段 */
15
+ partial: string;
16
+ }
17
+ export declare function detectChainAtCursor(text: string, cursor: number, options: DetectChainOptions): ChainResult | null;
@@ -0,0 +1,31 @@
1
+ const x = /[A-Za-z0-9_$]/;
2
+ function g(t) {
3
+ const e = t.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
4
+ return new RegExp(`[A-Za-z0-9_.${e}]`);
5
+ }
6
+ function h(t, e) {
7
+ const i = t.slice(0, e), r = i.lastIndexOf("{{");
8
+ if (r === -1 || i.lastIndexOf("}}") > r)
9
+ return !1;
10
+ const o = t.slice(e), n = o.indexOf("}}"), s = o.indexOf("{{");
11
+ return n === -1 ? !0 : !(s !== -1 && s < n);
12
+ }
13
+ function I(t, e, i) {
14
+ const { triggerPrefix: r, triggerMode: c } = i;
15
+ if (c === "braces" && !h(t, e))
16
+ return null;
17
+ const o = g(r);
18
+ let n = e;
19
+ for (; n > 0 && o.test(t[n - 1]); )
20
+ n -= 1;
21
+ const s = t.slice(n, e), f = `${r}.`;
22
+ if (!s.startsWith(f))
23
+ return null;
24
+ const a = s.slice(f.length), u = a.length > 0 ? a.split(".") : [""], l = u.pop(), d = u;
25
+ return l.length > 0 && !l.split("").every((p) => x.test(p)) ? null : { startIdx: n, endIdx: e, parts: d, partial: l };
26
+ }
27
+ export {
28
+ x as ID_TAIL,
29
+ I as detectChainAtCursor
30
+ };
31
+ //# sourceMappingURL=detectChainAtCursor.js.map
@@ -0,0 +1,2 @@
1
+ import { ExprCandidate } from './interface';
2
+ export declare function filterCandidatesByPartial(candidates: ExprCandidate[], partial: string): ExprCandidate[];
@@ -0,0 +1,15 @@
1
+ function n(e, r) {
2
+ if (!r)
3
+ return e;
4
+ const t = r.toLowerCase();
5
+ return e.filter((o) => {
6
+ if (o.value.toLowerCase().startsWith(t))
7
+ return !0;
8
+ const l = o.label?.toLowerCase();
9
+ return !!l && l.includes(t);
10
+ });
11
+ }
12
+ export {
13
+ n as filterCandidatesByPartial
14
+ };
15
+ //# sourceMappingURL=filterCandidatesByPartial.js.map
@@ -0,0 +1,9 @@
1
+ export interface HighlightSegment {
2
+ text: string;
3
+ highlight: boolean;
4
+ }
5
+ /**
6
+ * 按 {{ }} 配对闭合切分 value,不校验内容合法性,不处理嵌套。
7
+ * 用于表达式片段着色,判定门槛低于 isExpressionValue。
8
+ */
9
+ export declare function highlightSegments(value: string): HighlightSegment[];
@@ -0,0 +1,14 @@
1
+ const n = /\{\{[^{}]*\}\}/g;
2
+ function s(e) {
3
+ if (!e)
4
+ return [];
5
+ const i = [];
6
+ let h = 0, t;
7
+ for (n.lastIndex = 0; (t = n.exec(e)) !== null; )
8
+ t.index > h && i.push({ text: e.slice(h, t.index), highlight: !1 }), i.push({ text: t[0], highlight: !0 }), h = t.index + t[0].length;
9
+ return h < e.length && i.push({ text: e.slice(h), highlight: !1 }), i;
10
+ }
11
+ export {
12
+ s as highlightSegments
13
+ };
14
+ //# sourceMappingURL=highlightSegments.js.map
@@ -0,0 +1 @@
1
+ @charset "UTF-8";.paraui-v4-expression-input{display:inline-block;width:100%}.paraui-v4-expression-input input{position:relative;z-index:1;color:transparent!important;caret-color:#1d2126!important}.paraui-v4-expression-input-overlay{position:absolute;inset:0;z-index:0;overflow:hidden;color:#1d2126;white-space:pre;pointer-events:none}.paraui-v4-expression-input-overlay-highlight{color:#2e65e6}.paraui-v4-expression-input-popup{z-index:1500;min-width:280px;overflow:hidden;background:#fff;border:1px solid rgb(212,218,227);border-radius:4px;box-shadow:0 2px 8px #d4dae366}.paraui-v4-expression-input-popup-header{padding:6px 12px;font-size:12px;color:#a1a8b3;border-bottom:1px solid rgb(234,236,241)}.paraui-v4-expression-input-popup-list{padding:4px 0}.paraui-v4-expression-input-popup-item{display:flex;align-items:center;padding:0 12px;font-size:14px;color:#1d2126;white-space:nowrap;cursor:pointer}.paraui-v4-expression-input-popup-item-active{color:#2e65e6;background:#f0f5ff}.paraui-v4-expression-input-popup-item-value{flex:0 0 auto;margin-right:8px}.paraui-v4-expression-input-popup-item-desc{flex:1 1 auto;overflow:hidden;font-size:12px;color:#a1a8b3;text-overflow:ellipsis}.paraui-v4-expression-input-popup-item-lock{flex:0 0 auto;margin-left:8px;font-size:16px;color:#a1a8b3}
@@ -0,0 +1,5 @@
1
+ import { ExpressionInputProps } from './interface';
2
+ import * as React from 'react';
3
+ declare const ExpressionInput: React.FunctionComponent<ExpressionInputProps>;
4
+ export default ExpressionInput;
5
+ export * from './interface';
@@ -0,0 +1,178 @@
1
+ import { j as a } from "../_virtual/jsx-runtime.js";
2
+ import './index.css';/* empty css */
3
+ import * as r from "react";
4
+ import * as b from "react-dom";
5
+ import { UUID as X } from "@snack-kit/lib";
6
+ import { TextField as Z } from "../TextField/index.js";
7
+ import { Tooltip as Q } from "../Tooltip/index.js";
8
+ import Y from "../GlobalContext/usePopupContainer.js";
9
+ import ee from "../GlobalContext/useFormatMessage.js";
10
+ import { $prefixCls as T } from "../GlobalContext/constant.js";
11
+ import { useExpressionInput as te } from "./useExpressionInput.js";
12
+ import { Popup as re } from "./Popup.js";
13
+ import { isExpressionValue as ne } from "./isExpressionValue.js";
14
+ import { highlightSegments as oe } from "./highlightSegments.js";
15
+ import ie from "./HighlightOverlay.js";
16
+ import se from "./lang/index.js";
17
+ const le = 50, ae = "$", Re = (j) => {
18
+ const {
19
+ value: o,
20
+ onChange: z,
21
+ resolveCandidates: D,
22
+ triggerMode: h = "braces",
23
+ triggerPrefix: d = ae,
24
+ virtualizeThreshold: F = le,
25
+ renderPopupHeader: v,
26
+ expressionTooltip: p,
27
+ disabled: E,
28
+ readOnly: I,
29
+ className: x,
30
+ ...y
31
+ } = j, H = ee("ExpressionInput", se), [f] = r.useState(() => `${T}-expression-input-${X()}`), n = r.useRef(null), S = r.useRef(null), O = r.useRef({ getRootDomNode: () => n.current }), P = Y(O), [$, M] = r.useState({ top: 0, left: 0, width: 0 }), l = r.useRef(null), [w, q] = r.useState(null), [U, W] = r.useState({}), _ = r.useMemo(() => oe(o ?? ""), [o]), {
32
+ open: i,
33
+ ctx: c,
34
+ candidates: g,
35
+ highlight: A,
36
+ setHighlight: B,
37
+ handleValueChange: K,
38
+ handleKeyDown: N,
39
+ handleSelect: V,
40
+ close: R,
41
+ pendingCursorRef: m
42
+ } = te({
43
+ value: o ?? "",
44
+ onChange: z,
45
+ resolveCandidates: D,
46
+ triggerMode: h,
47
+ triggerPrefix: d,
48
+ disabled: E,
49
+ readOnly: I
50
+ }), s = r.useCallback(() => {
51
+ const e = n.current?.querySelector("input, textarea");
52
+ if (!e)
53
+ return;
54
+ const t = e.getBoundingClientRect();
55
+ M({ top: t.bottom + 4, left: t.left, width: Math.max(t.width, 280) });
56
+ }, []), u = r.useCallback(() => {
57
+ const e = n.current?.querySelector("input, textarea");
58
+ if (!e)
59
+ return;
60
+ q(e.parentElement);
61
+ const t = window.getComputedStyle(e);
62
+ W({
63
+ paddingTop: t.paddingTop,
64
+ paddingRight: t.paddingRight,
65
+ paddingBottom: t.paddingBottom,
66
+ paddingLeft: t.paddingLeft,
67
+ fontFamily: t.fontFamily,
68
+ fontSize: t.fontSize,
69
+ fontWeight: t.fontWeight,
70
+ lineHeight: t.lineHeight,
71
+ letterSpacing: t.letterSpacing,
72
+ boxSizing: t.boxSizing,
73
+ borderWidth: t.borderWidth,
74
+ borderStyle: t.borderStyle,
75
+ borderColor: "transparent"
76
+ });
77
+ }, []);
78
+ r.useLayoutEffect(() => (u(), window.addEventListener("resize", u), () => window.removeEventListener("resize", u)), [u]), r.useEffect(() => {
79
+ const e = n.current?.querySelector("input, textarea");
80
+ if (!e)
81
+ return;
82
+ const t = () => {
83
+ l.current && (l.current.scrollLeft = e.scrollLeft);
84
+ };
85
+ return e.addEventListener("scroll", t), () => e.removeEventListener("scroll", t);
86
+ }, []), r.useEffect(() => {
87
+ const e = n.current?.querySelector("input, textarea");
88
+ e && l.current && (l.current.scrollLeft = e.scrollLeft);
89
+ }, [o]), r.useEffect(() => {
90
+ const e = m.current;
91
+ if (e === null)
92
+ return;
93
+ const t = n.current?.querySelector("input, textarea");
94
+ t && (t.focus(), t.setSelectionRange(e, e)), m.current = null;
95
+ }, [o, m]), r.useEffect(() => {
96
+ if (i)
97
+ return s(), window.addEventListener("scroll", s, !0), window.addEventListener("resize", s), () => {
98
+ window.removeEventListener("scroll", s, !0), window.removeEventListener("resize", s);
99
+ };
100
+ }, [i, s]), r.useEffect(() => {
101
+ if (!i)
102
+ return;
103
+ const e = (t) => {
104
+ const C = t.target;
105
+ n.current?.contains(C) || S.current?.contains(C) || R();
106
+ };
107
+ return document.addEventListener("mousedown", e, !0), () => document.removeEventListener("mousedown", e, !0);
108
+ }, [i, R, f]);
109
+ const k = (e) => {
110
+ const t = e.target.selectionStart ?? e.target.value.length;
111
+ K(e.target.value, t);
112
+ }, G = c ? v ? v(c, g.length) : H(
113
+ { id: "header" },
114
+ { path: c.parts.length ? c.parts.join(".") : d, count: g.length }
115
+ ) : null, J = !!p && ne(o ?? "", d, h), L = /* @__PURE__ */ a.jsx(
116
+ Z,
117
+ {
118
+ ...y,
119
+ value: o,
120
+ disabled: E,
121
+ onChange: k,
122
+ onKeydown: (e) => {
123
+ N(e), y.onKeydown?.(e);
124
+ }
125
+ }
126
+ );
127
+ return /* @__PURE__ */ a.jsxs(
128
+ "div",
129
+ {
130
+ ref: n,
131
+ className: `${T}-expression-input ${f}${x ? ` ${x}` : ""}`,
132
+ children: [
133
+ p ? /* @__PURE__ */ a.jsx(
134
+ Q,
135
+ {
136
+ title: p,
137
+ trigger: ["hover", "focus"],
138
+ ...J ? {} : { visible: !1 },
139
+ children: L
140
+ }
141
+ ) : L,
142
+ w && b.createPortal(
143
+ /* @__PURE__ */ a.jsx(
144
+ ie,
145
+ {
146
+ ref: l,
147
+ segments: _,
148
+ style: U
149
+ }
150
+ ),
151
+ w
152
+ ),
153
+ i && n.current && b.createPortal(
154
+ /* @__PURE__ */ a.jsx(
155
+ re,
156
+ {
157
+ ref: S,
158
+ instanceClass: f,
159
+ visible: i,
160
+ rect: $,
161
+ header: G,
162
+ candidates: g,
163
+ highlight: A,
164
+ virtualizeThreshold: F,
165
+ onSelect: V,
166
+ onHighlightChange: B
167
+ }
168
+ ),
169
+ P(n.current)
170
+ )
171
+ ]
172
+ }
173
+ );
174
+ };
175
+ export {
176
+ Re as default
177
+ };
178
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1,52 @@
1
+ import { TextFieldProps } from '../TextField';
2
+ import * as React from 'react';
3
+ export interface ExprCandidate {
4
+ /** 插入表达式时使用的实际值 */
5
+ value: string;
6
+ /** 展示用名称,不传则显示 value */
7
+ label?: string;
8
+ /** 右侧描述文案 */
9
+ desc?: string;
10
+ /** 选中后是否自动追加 `.` 以便继续下钻子级 */
11
+ chain?: boolean;
12
+ /** 是否为敏感字段,展示锁图标 */
13
+ sensitive?: boolean;
14
+ }
15
+ export interface ExprChainCtx {
16
+ /** 当前光标所在链路中,已确定的上级片段(不含正在输入的部分) */
17
+ parts: string[];
18
+ /** 当前正在输入、尚未确定的片段 */
19
+ partial: string;
20
+ }
21
+ export interface ExpressionInputProps extends Omit<TextFieldProps, 'value' | 'onChange'> {
22
+ value?: string;
23
+ onChange?: (value: string) => void;
24
+ /**
25
+ * 只读态,输入触发前缀时不弹出候选浮层。
26
+ * 注:仓库现有 TextField 无 readOnly 能力,该态仅影响候选弹出逻辑,不改变输入框本身的可编辑外观。
27
+ */
28
+ readOnly?: boolean;
29
+ /**
30
+ * 按当前命名空间路径(不含正在输入的 partial)返回该层级的完整候选列表。
31
+ * 仅在 parts 变化(下钻/回退层级)时调用,组件内部按 parts 缓存结果;
32
+ * 同层级内继续输入 partial 只做客户端过滤,不会重复调用。
33
+ */
34
+ resolveCandidates: (parts: string[]) => ExprCandidate[];
35
+ /**
36
+ * 触发匹配机制,默认 'braces':仅当光标位于 `{{ }}` 区间内且内容匹配
37
+ * `{prefix}.xxx` 才弹窗。'bare':不要求大括号包裹,对齐 Ditto 原始行为。
38
+ */
39
+ triggerMode?: 'braces' | 'bare';
40
+ /** 触发表达式补全的前缀符号,默认 '$' */
41
+ triggerPrefix?: string;
42
+ /** 候选数量超过该阈值时启用虚拟滚动,默认 50 */
43
+ virtualizeThreshold?: number;
44
+ /** 自定义浮层 header 文案(面包屑 + 数量 + 快捷键提示),不传则使用默认 i18n 文案 */
45
+ renderPopupHeader?: (ctx: ExprChainCtx, count: number) => React.ReactNode;
46
+ /**
47
+ * 表达式说明 tooltip 文案,不传则不展示;仅当 value 命中表达式格式(braces/bare)时,hover/focus 输入框才会真正弹出。
48
+ * 注:是否命中只在触发 hover/focus 那一刻判定,若光标停留期间继续输入使 value 从未命中变为命中,
49
+ * 不会自动弹出,需要重新 hover/focus 才会展示——这是已知的边界行为,非 bug。
50
+ */
51
+ expressionTooltip?: React.ReactNode;
52
+ }
@@ -0,0 +1,5 @@
1
+ /**
2
+ * 判断 value 是否已经是一段完整的表达式引用,用于决定是否展示 expressionTooltip 说明。
3
+ * braces 模式要求 `{{ prefix.xxx }}` 完整闭合;bare 模式只要求文本中出现 `prefix.xxx` 即可。
4
+ */
5
+ export declare function isExpressionValue(value: string, triggerPrefix: string, triggerMode: 'braces' | 'bare'): boolean;
@@ -0,0 +1,18 @@
1
+ import { ID_TAIL as s } from "./detectChainAtCursor.js";
2
+ function o(e) {
3
+ return e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
4
+ }
5
+ function c(e) {
6
+ const t = o(e), r = `${s.source}+`;
7
+ return `${t}\\.${r}(?:\\.${r})*`;
8
+ }
9
+ function p(e, t, r) {
10
+ if (!e)
11
+ return !1;
12
+ const n = c(t);
13
+ return r === "braces" ? new RegExp(`\\{\\{\\s*${n}\\s*\\}\\}`).test(e) : new RegExp(n).test(e);
14
+ }
15
+ export {
16
+ p as isExpressionValue
17
+ };
18
+ //# sourceMappingURL=isExpressionValue.js.map
@@ -0,0 +1,4 @@
1
+ declare const _default: {
2
+ header: string;
3
+ };
4
+ export default _default;
@@ -0,0 +1,7 @@
1
+ const e = {
2
+ header: "{path} · {count} items · ↑↓ select · Enter/Tab insert · Esc close"
3
+ };
4
+ export {
5
+ e as default
6
+ };
7
+ //# sourceMappingURL=en_US.js.map
@@ -0,0 +1,9 @@
1
+ declare const _default: {
2
+ zh: {
3
+ header: string;
4
+ };
5
+ en: {
6
+ header: string;
7
+ };
8
+ };
9
+ export default _default;
@@ -0,0 +1,10 @@
1
+ import o from "./en_US.js";
2
+ import r from "./zh_CN.js";
3
+ const m = {
4
+ zh: r,
5
+ en: o
6
+ };
7
+ export {
8
+ m as default
9
+ };
10
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1,4 @@
1
+ declare const _default: {
2
+ header: string;
3
+ };
4
+ export default _default;
@@ -0,0 +1,7 @@
1
+ const t = {
2
+ header: "{path} · {count} 项 · ↑↓ 选择 · Enter/Tab 插入 · Esc 关闭"
3
+ };
4
+ export {
5
+ t as default
6
+ };
7
+ //# sourceMappingURL=zh_CN.js.map
@@ -0,0 +1 @@
1
+ import './index.css';
@@ -0,0 +1 @@
1
+ .paraui-v4-expression-input{display:inline-block;width:100%}.paraui-v4-expression-input input{position:relative;z-index:1;color:rgba(0,0,0,0) !important;caret-color:#1d2126 !important}.paraui-v4-expression-input-overlay{position:absolute;top:0;right:0;bottom:0;left:0;z-index:0;overflow:hidden;color:#1d2126;white-space:pre;pointer-events:none}.paraui-v4-expression-input-overlay-highlight{color:#2e65e6}.paraui-v4-expression-input-popup{z-index:1500;min-width:280px;overflow:hidden;background:#fff;border:1px solid #d4dae3;border-radius:4px;box-shadow:0px 2px 8px 0px rgba(212,218,227,.4)}.paraui-v4-expression-input-popup-header{padding:6px 12px;font-size:12px;color:#a1a8b3;border-bottom:1px solid #eaecf1}.paraui-v4-expression-input-popup-list{padding:4px 0}.paraui-v4-expression-input-popup-item{display:flex;align-items:center;padding:0 12px;font-size:14px;color:#1d2126;white-space:nowrap;cursor:pointer}.paraui-v4-expression-input-popup-item-active{color:#2e65e6;background:#f0f5ff}.paraui-v4-expression-input-popup-item-value{flex:0 0 auto;margin-right:8px}.paraui-v4-expression-input-popup-item-desc{flex:1 1 auto;overflow:hidden;font-size:12px;color:#a1a8b3;text-overflow:ellipsis}.paraui-v4-expression-input-popup-item-lock{flex:0 0 auto;margin-left:8px;font-size:16px;color:#a1a8b3}
@@ -0,0 +1 @@
1
+ import './index.css';
@@ -0,0 +1,26 @@
1
+ import { ExprCandidate, ExprChainCtx } from './interface';
2
+ import * as React from 'react';
3
+ export interface UseExpressionInputOptions {
4
+ value: string;
5
+ onChange?: (value: string) => void;
6
+ resolveCandidates: (parts: string[]) => ExprCandidate[];
7
+ triggerMode: 'braces' | 'bare';
8
+ triggerPrefix: string;
9
+ disabled?: boolean;
10
+ readOnly?: boolean;
11
+ }
12
+ export interface UseExpressionInputResult {
13
+ open: boolean;
14
+ ctx: ExprChainCtx | null;
15
+ candidates: ExprCandidate[];
16
+ highlight: number;
17
+ /** 手动指定当前高亮索引,供鼠标移入候选行时与键盘 ArrowUp/Down 共享同一份高亮状态,避免出现两套独立高亮源 */
18
+ setHighlight: (index: number) => void;
19
+ /** 插入候选后期望的光标落点(相对新 value 的下标),供 Task 6 index.tsx 把光标设置到实际 DOM input 上;未处于"刚插入"状态时为 null */
20
+ pendingCursorRef: React.MutableRefObject<number | null>;
21
+ handleValueChange: (nextValue: string, cursor: number) => void;
22
+ handleKeyDown: (event: React.KeyboardEvent<HTMLInputElement>) => void;
23
+ handleSelect: (candidate: ExprCandidate) => void;
24
+ close: () => void;
25
+ }
26
+ export declare function useExpressionInput(options: UseExpressionInputOptions): UseExpressionInputResult;