element-ps 2.0.12 → 2.0.13

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 (516) hide show
  1. package/dist/index.full.js +352 -324
  2. package/dist/index.full.min.js +5 -5
  3. package/dist/index.full.min.js.map +1 -1
  4. package/dist/index.full.min.mjs +5 -5
  5. package/dist/index.full.min.mjs.map +1 -1
  6. package/dist/index.full.mjs +352 -324
  7. package/es/components/autocomplete/index.d.ts +11 -4
  8. package/es/components/autocomplete/index.mjs +2 -2
  9. package/es/components/autocomplete/src/autocomplete.mjs +96 -58
  10. package/es/components/autocomplete/src/autocomplete.mjs.map +1 -1
  11. package/es/components/autocomplete/src/autocomplete.vue.d.ts +11 -4
  12. package/es/components/autocomplete/src/autocomplete2.mjs +58 -96
  13. package/es/components/autocomplete/src/autocomplete2.mjs.map +1 -1
  14. package/es/components/avatar/index.mjs +2 -2
  15. package/es/components/avatar/src/avatar.mjs +29 -61
  16. package/es/components/avatar/src/avatar.mjs.map +1 -1
  17. package/es/components/avatar/src/avatar2.mjs +61 -29
  18. package/es/components/avatar/src/avatar2.mjs.map +1 -1
  19. package/es/components/breadcrumb/index.mjs +2 -2
  20. package/es/components/breadcrumb/src/breadcrumb.mjs +37 -12
  21. package/es/components/breadcrumb/src/breadcrumb.mjs.map +1 -1
  22. package/es/components/breadcrumb/src/breadcrumb2.mjs +12 -37
  23. package/es/components/breadcrumb/src/breadcrumb2.mjs.map +1 -1
  24. package/es/components/button/index.mjs +1 -1
  25. package/es/components/button/src/button-group.mjs +5 -30
  26. package/es/components/button/src/button-group.mjs.map +1 -1
  27. package/es/components/button/src/button-group2.mjs +30 -5
  28. package/es/components/button/src/button-group2.mjs.map +1 -1
  29. package/es/components/calendar/index.mjs +2 -2
  30. package/es/components/calendar/src/calendar.mjs +188 -9
  31. package/es/components/calendar/src/calendar.mjs.map +1 -1
  32. package/es/components/calendar/src/calendar2.mjs +9 -188
  33. package/es/components/calendar/src/calendar2.mjs.map +1 -1
  34. package/es/components/card/index.mjs +2 -2
  35. package/es/components/card/src/card.mjs +15 -35
  36. package/es/components/card/src/card.mjs.map +1 -1
  37. package/es/components/card/src/card2.mjs +35 -15
  38. package/es/components/card/src/card2.mjs.map +1 -1
  39. package/es/components/carousel/index.mjs +2 -2
  40. package/es/components/carousel/src/carousel.mjs +43 -227
  41. package/es/components/carousel/src/carousel.mjs.map +1 -1
  42. package/es/components/carousel/src/carousel2.mjs +227 -43
  43. package/es/components/carousel/src/carousel2.mjs.map +1 -1
  44. package/es/components/cascader/index.d.ts +28 -2
  45. package/es/components/cascader/src/index.mjs +15 -10
  46. package/es/components/cascader/src/index.mjs.map +1 -1
  47. package/es/components/cascader/src/index.vue.d.ts +14 -1
  48. package/es/components/check-tag/index.mjs +2 -2
  49. package/es/components/check-tag/src/check-tag.mjs +20 -7
  50. package/es/components/check-tag/src/check-tag.mjs.map +1 -1
  51. package/es/components/check-tag/src/check-tag2.mjs +7 -20
  52. package/es/components/check-tag/src/check-tag2.mjs.map +1 -1
  53. package/es/components/collection/index.mjs +1 -1
  54. package/es/components/collection/src/collection.mjs +10 -63
  55. package/es/components/collection/src/collection.mjs.map +1 -1
  56. package/es/components/collection/src/collection2.mjs +63 -10
  57. package/es/components/collection/src/collection2.mjs.map +1 -1
  58. package/es/components/descriptions/index.d.ts +12 -0
  59. package/es/components/descriptions/src/description-item.d.ts +6 -0
  60. package/es/components/descriptions/src/description-item.mjs +3 -0
  61. package/es/components/descriptions/src/description-item.mjs.map +1 -1
  62. package/es/components/descriptions/src/descriptions.type.d.ts +1 -0
  63. package/es/components/dialog/index.d.ts +4 -0
  64. package/es/components/dialog/index.mjs +2 -2
  65. package/es/components/dialog/src/dialog-content.d.ts +1 -0
  66. package/es/components/dialog/src/dialog-content.mjs +3 -0
  67. package/es/components/dialog/src/dialog-content.mjs.map +1 -1
  68. package/es/components/dialog/src/dialog-content.vue.d.ts +3 -0
  69. package/es/components/dialog/src/dialog-content2.mjs +11 -6
  70. package/es/components/dialog/src/dialog-content2.mjs.map +1 -1
  71. package/es/components/dialog/src/dialog.d.ts +1 -0
  72. package/es/components/dialog/src/dialog.mjs +97 -58
  73. package/es/components/dialog/src/dialog.mjs.map +1 -1
  74. package/es/components/dialog/src/dialog.vue.d.ts +4 -0
  75. package/es/components/dialog/src/dialog2.mjs +61 -96
  76. package/es/components/dialog/src/dialog2.mjs.map +1 -1
  77. package/es/components/drawer/index.d.ts +3 -0
  78. package/es/components/drawer/src/drawer.d.ts +1 -0
  79. package/es/components/drawer/src/drawer.mjs +4 -1
  80. package/es/components/drawer/src/drawer.mjs.map +1 -1
  81. package/es/components/drawer/src/drawer.vue.d.ts +3 -0
  82. package/es/components/drawer/src/drawer2.mjs +64 -65
  83. package/es/components/drawer/src/drawer2.mjs.map +1 -1
  84. package/es/components/dropdown/index.mjs +2 -2
  85. package/es/components/dropdown/src/dropdown-item-impl.mjs +3 -3
  86. package/es/components/dropdown/src/dropdown-item.mjs +1 -1
  87. package/es/components/dropdown/src/dropdown-menu.mjs +2 -2
  88. package/es/components/dropdown/src/dropdown.mjs +100 -109
  89. package/es/components/dropdown/src/dropdown.mjs.map +1 -1
  90. package/es/components/dropdown/src/dropdown2.mjs +109 -100
  91. package/es/components/dropdown/src/dropdown2.mjs.map +1 -1
  92. package/es/components/empty/index.mjs +2 -2
  93. package/es/components/empty/src/empty.mjs +11 -56
  94. package/es/components/empty/src/empty.mjs.map +1 -1
  95. package/es/components/empty/src/empty2.mjs +56 -11
  96. package/es/components/empty/src/empty2.mjs.map +1 -1
  97. package/es/components/form/index.d.ts +8 -0
  98. package/es/components/form/index.mjs +2 -2
  99. package/es/components/form/src/form-item.d.ts +1 -0
  100. package/es/components/form/src/form-item.mjs +3 -0
  101. package/es/components/form/src/form-item.mjs.map +1 -1
  102. package/es/components/form/src/form-item.vue.d.ts +4 -0
  103. package/es/components/form/src/form-item2.mjs +12 -7
  104. package/es/components/form/src/form-item2.mjs.map +1 -1
  105. package/es/components/form/src/form.mjs +45 -40
  106. package/es/components/form/src/form.mjs.map +1 -1
  107. package/es/components/form/src/form2.mjs +40 -45
  108. package/es/components/form/src/form2.mjs.map +1 -1
  109. package/es/components/icon/index.mjs +2 -2
  110. package/es/components/icon/src/icon.mjs +8 -35
  111. package/es/components/icon/src/icon.mjs.map +1 -1
  112. package/es/components/icon/src/icon2.mjs +35 -8
  113. package/es/components/icon/src/icon2.mjs.map +1 -1
  114. package/es/components/image/index.d.ts +1 -1
  115. package/es/components/image/index.mjs +2 -2
  116. package/es/components/image/src/image.mjs +50 -158
  117. package/es/components/image/src/image.mjs.map +1 -1
  118. package/es/components/image/src/image.vue.d.ts +1 -1
  119. package/es/components/image/src/image2.mjs +158 -50
  120. package/es/components/image/src/image2.mjs.map +1 -1
  121. package/es/components/index.mjs +27 -27
  122. package/es/components/input/index.d.ts +4 -0
  123. package/es/components/input/index.mjs +2 -2
  124. package/es/components/input/src/input.d.ts +1 -0
  125. package/es/components/input/src/input.mjs +85 -294
  126. package/es/components/input/src/input.mjs.map +1 -1
  127. package/es/components/input/src/input.vue.d.ts +4 -0
  128. package/es/components/input/src/input2.mjs +296 -82
  129. package/es/components/input/src/input2.mjs.map +1 -1
  130. package/es/components/input-number/index.d.ts +8 -0
  131. package/es/components/input-number/src/input-number.vue.d.ts +8 -0
  132. package/es/components/menu/index.mjs +2 -2
  133. package/es/components/menu/src/menu-item.mjs +15 -73
  134. package/es/components/menu/src/menu-item.mjs.map +1 -1
  135. package/es/components/menu/src/menu-item2.mjs +73 -15
  136. package/es/components/menu/src/menu-item2.mjs.map +1 -1
  137. package/es/components/popconfirm/src/popconfirm.mjs +1 -1
  138. package/es/components/popover/index.d.ts +2 -2
  139. package/es/components/popover/src/index.vue.d.ts +1 -1
  140. package/es/components/popover/src/popover.mjs +2 -2
  141. package/es/components/popper/index.mjs +2 -2
  142. package/es/components/popper/src/content.vue.d.ts +1 -1
  143. package/es/components/popper/src/trigger.mjs +36 -17
  144. package/es/components/popper/src/trigger.mjs.map +1 -1
  145. package/es/components/popper/src/trigger2.mjs +17 -36
  146. package/es/components/popper/src/trigger2.mjs.map +1 -1
  147. package/es/components/progress/index.d.ts +3 -3
  148. package/es/components/progress/index.mjs +2 -2
  149. package/es/components/progress/src/progress.d.ts +1 -1
  150. package/es/components/progress/src/progress.mjs +57 -230
  151. package/es/components/progress/src/progress.mjs.map +1 -1
  152. package/es/components/progress/src/progress.vue.d.ts +3 -3
  153. package/es/components/progress/src/progress2.mjs +230 -57
  154. package/es/components/progress/src/progress2.mjs.map +1 -1
  155. package/es/components/radio/index.mjs +2 -2
  156. package/es/components/radio/src/radio-button.mjs +1 -1
  157. package/es/components/radio/src/radio-button2.mjs +1 -1
  158. package/es/components/radio/src/radio.mjs +74 -67
  159. package/es/components/radio/src/radio.mjs.map +1 -1
  160. package/es/components/radio/src/radio2.mjs +67 -74
  161. package/es/components/radio/src/radio2.mjs.map +1 -1
  162. package/es/components/rate/index.mjs +2 -2
  163. package/es/components/rate/src/rate.mjs +84 -169
  164. package/es/components/rate/src/rate.mjs.map +1 -1
  165. package/es/components/rate/src/rate2.mjs +169 -84
  166. package/es/components/rate/src/rate2.mjs.map +1 -1
  167. package/es/components/result/index.mjs +2 -2
  168. package/es/components/result/src/result.mjs +28 -73
  169. package/es/components/result/src/result.mjs.map +1 -1
  170. package/es/components/result/src/result2.mjs +73 -28
  171. package/es/components/result/src/result2.mjs.map +1 -1
  172. package/es/components/roving-focus-group/index.mjs +3 -3
  173. package/es/components/roving-focus-group/src/roving-focus-group-impl.mjs +1 -1
  174. package/es/components/roving-focus-group/src/roving-focus-group.mjs +29 -27
  175. package/es/components/roving-focus-group/src/roving-focus-group.mjs.map +1 -1
  176. package/es/components/roving-focus-group/src/roving-focus-group2.mjs +27 -29
  177. package/es/components/roving-focus-group/src/roving-focus-group2.mjs.map +1 -1
  178. package/es/components/roving-focus-group/src/roving-focus-item.mjs +1 -1
  179. package/es/components/scrollbar/index.mjs +1 -1
  180. package/es/components/scrollbar/src/bar.mjs +1 -1
  181. package/es/components/scrollbar/src/thumb.mjs +11 -59
  182. package/es/components/scrollbar/src/thumb.mjs.map +1 -1
  183. package/es/components/scrollbar/src/thumb.vue.d.ts +1 -1
  184. package/es/components/scrollbar/src/thumb2.mjs +59 -11
  185. package/es/components/scrollbar/src/thumb2.mjs.map +1 -1
  186. package/es/components/select/index.d.ts +4 -4
  187. package/es/components/select/src/select.mjs +1 -1
  188. package/es/components/select/src/select.vue.d.ts +4 -4
  189. package/es/components/select/src/useSelect.d.ts +3 -3
  190. package/es/components/select-v2/index.d.ts +8 -8
  191. package/es/components/select-v2/src/defaults.mjs +1 -1
  192. package/es/components/select-v2/src/select.vue.d.ts +4 -4
  193. package/es/components/select-v2/src/useSelect.d.ts +3 -3
  194. package/es/components/skeleton/index.mjs +2 -2
  195. package/es/components/skeleton/src/skeleton.mjs +49 -22
  196. package/es/components/skeleton/src/skeleton.mjs.map +1 -1
  197. package/es/components/skeleton/src/skeleton2.mjs +22 -49
  198. package/es/components/skeleton/src/skeleton2.mjs.map +1 -1
  199. package/es/components/switch/index.d.ts +1 -1
  200. package/es/components/switch/src/switch.vue.d.ts +1 -1
  201. package/es/components/table/index.d.ts +13 -1
  202. package/es/components/table/src/filter-panel.vue.d.ts +3 -3
  203. package/es/components/table/src/table-body/render-helper.mjs +2 -1
  204. package/es/components/table/src/table-body/render-helper.mjs.map +1 -1
  205. package/es/components/table/src/table-column/defaults.d.ts +4 -0
  206. package/es/components/table/src/table-column/defaults.mjs +3 -0
  207. package/es/components/table/src/table-column/defaults.mjs.map +1 -1
  208. package/es/components/table/src/table-column/index.d.ts +6 -0
  209. package/es/components/table/src/table-column/index.mjs +2 -1
  210. package/es/components/table/src/table-column/index.mjs.map +1 -1
  211. package/es/components/table/src/table-header/index.mjs +1 -8
  212. package/es/components/table/src/table-header/index.mjs.map +1 -1
  213. package/es/components/table/src/table.vue.d.ts +1 -1
  214. package/es/components/teleport/index.mjs +2 -2
  215. package/es/components/teleport/src/teleport.mjs +18 -43
  216. package/es/components/teleport/src/teleport.mjs.map +1 -1
  217. package/es/components/teleport/src/teleport2.mjs +43 -18
  218. package/es/components/teleport/src/teleport2.mjs.map +1 -1
  219. package/es/components/time-picker/src/common/picker.vue.d.ts +3 -3
  220. package/es/components/time-select/index.d.ts +4 -4
  221. package/es/components/time-select/src/time-select.vue.d.ts +2 -2
  222. package/es/components/timeline/index.mjs +2 -2
  223. package/es/components/timeline/src/timeline-item.mjs +73 -39
  224. package/es/components/timeline/src/timeline-item.mjs.map +1 -1
  225. package/es/components/timeline/src/timeline-item2.mjs +39 -73
  226. package/es/components/timeline/src/timeline-item2.mjs.map +1 -1
  227. package/es/components/tooltip/index.d.ts +1 -1
  228. package/es/components/tooltip/index.mjs +2 -2
  229. package/es/components/tooltip/src/tooltip.mjs +64 -51
  230. package/es/components/tooltip/src/tooltip.mjs.map +1 -1
  231. package/es/components/tooltip/src/tooltip.vue.d.ts +1 -1
  232. package/es/components/tooltip/src/tooltip2.mjs +51 -64
  233. package/es/components/tooltip/src/tooltip2.mjs.map +1 -1
  234. package/es/components/tooltip/src/trigger.mjs +2 -2
  235. package/es/components/tooltip-v2/index.mjs +2 -2
  236. package/es/components/tooltip-v2/src/content.mjs +113 -50
  237. package/es/components/tooltip-v2/src/content.mjs.map +1 -1
  238. package/es/components/tooltip-v2/src/content2.mjs +50 -113
  239. package/es/components/tooltip-v2/src/content2.mjs.map +1 -1
  240. package/es/components/tooltip-v2/src/tooltip.mjs +2 -2
  241. package/es/components/tooltip-v2/src/tooltip2.mjs +4 -4
  242. package/es/components/tooltip-v2/src/trigger.mjs +11 -89
  243. package/es/components/tooltip-v2/src/trigger.mjs.map +1 -1
  244. package/es/components/tooltip-v2/src/trigger2.mjs +89 -11
  245. package/es/components/tooltip-v2/src/trigger2.mjs.map +1 -1
  246. package/es/components/upload/index.mjs +3 -3
  247. package/es/components/upload/src/upload-content.mjs +1 -1
  248. package/es/components/upload/src/upload-list.mjs +155 -26
  249. package/es/components/upload/src/upload-list.mjs.map +1 -1
  250. package/es/components/upload/src/upload-list.vue.d.ts +3 -3
  251. package/es/components/upload/src/upload-list2.mjs +26 -155
  252. package/es/components/upload/src/upload-list2.mjs.map +1 -1
  253. package/es/components/upload/src/upload.mjs +99 -106
  254. package/es/components/upload/src/upload.mjs.map +1 -1
  255. package/es/components/upload/src/upload2.mjs +106 -99
  256. package/es/components/upload/src/upload2.mjs.map +1 -1
  257. package/es/components/virtual-list/src/builders/build-list.d.ts +1 -1
  258. package/es/components/virtual-list/src/components/dynamic-size-list.d.ts +1 -1
  259. package/es/components/virtual-list/src/components/fixed-size-list.d.ts +1 -1
  260. package/es/index.mjs +27 -27
  261. package/lib/components/autocomplete/index.d.ts +11 -4
  262. package/lib/components/autocomplete/index.js +2 -2
  263. package/lib/components/autocomplete/src/autocomplete.js +96 -58
  264. package/lib/components/autocomplete/src/autocomplete.js.map +1 -1
  265. package/lib/components/autocomplete/src/autocomplete.vue.d.ts +11 -4
  266. package/lib/components/autocomplete/src/autocomplete2.js +58 -96
  267. package/lib/components/autocomplete/src/autocomplete2.js.map +1 -1
  268. package/lib/components/avatar/index.js +2 -2
  269. package/lib/components/avatar/src/avatar.js +29 -61
  270. package/lib/components/avatar/src/avatar.js.map +1 -1
  271. package/lib/components/avatar/src/avatar2.js +61 -29
  272. package/lib/components/avatar/src/avatar2.js.map +1 -1
  273. package/lib/components/breadcrumb/index.js +2 -2
  274. package/lib/components/breadcrumb/src/breadcrumb.js +37 -12
  275. package/lib/components/breadcrumb/src/breadcrumb.js.map +1 -1
  276. package/lib/components/breadcrumb/src/breadcrumb2.js +12 -37
  277. package/lib/components/breadcrumb/src/breadcrumb2.js.map +1 -1
  278. package/lib/components/button/index.js +1 -1
  279. package/lib/components/button/src/button-group.js +5 -30
  280. package/lib/components/button/src/button-group.js.map +1 -1
  281. package/lib/components/button/src/button-group2.js +30 -5
  282. package/lib/components/button/src/button-group2.js.map +1 -1
  283. package/lib/components/calendar/index.js +2 -2
  284. package/lib/components/calendar/src/calendar.js +192 -9
  285. package/lib/components/calendar/src/calendar.js.map +1 -1
  286. package/lib/components/calendar/src/calendar2.js +9 -192
  287. package/lib/components/calendar/src/calendar2.js.map +1 -1
  288. package/lib/components/card/index.js +2 -2
  289. package/lib/components/card/src/card.js +15 -35
  290. package/lib/components/card/src/card.js.map +1 -1
  291. package/lib/components/card/src/card2.js +35 -15
  292. package/lib/components/card/src/card2.js.map +1 -1
  293. package/lib/components/carousel/index.js +2 -2
  294. package/lib/components/carousel/src/carousel.js +43 -227
  295. package/lib/components/carousel/src/carousel.js.map +1 -1
  296. package/lib/components/carousel/src/carousel2.js +227 -43
  297. package/lib/components/carousel/src/carousel2.js.map +1 -1
  298. package/lib/components/cascader/index.d.ts +28 -2
  299. package/lib/components/cascader/src/index.js +15 -10
  300. package/lib/components/cascader/src/index.js.map +1 -1
  301. package/lib/components/cascader/src/index.vue.d.ts +14 -1
  302. package/lib/components/check-tag/index.js +2 -2
  303. package/lib/components/check-tag/src/check-tag.js +20 -7
  304. package/lib/components/check-tag/src/check-tag.js.map +1 -1
  305. package/lib/components/check-tag/src/check-tag2.js +7 -20
  306. package/lib/components/check-tag/src/check-tag2.js.map +1 -1
  307. package/lib/components/collection/index.js +1 -1
  308. package/lib/components/collection/src/collection.js +9 -63
  309. package/lib/components/collection/src/collection.js.map +1 -1
  310. package/lib/components/collection/src/collection2.js +63 -9
  311. package/lib/components/collection/src/collection2.js.map +1 -1
  312. package/lib/components/descriptions/index.d.ts +12 -0
  313. package/lib/components/descriptions/src/description-item.d.ts +6 -0
  314. package/lib/components/descriptions/src/description-item.js +3 -0
  315. package/lib/components/descriptions/src/description-item.js.map +1 -1
  316. package/lib/components/descriptions/src/descriptions.type.d.ts +1 -0
  317. package/lib/components/dialog/index.d.ts +4 -0
  318. package/lib/components/dialog/index.js +2 -2
  319. package/lib/components/dialog/src/dialog-content.d.ts +1 -0
  320. package/lib/components/dialog/src/dialog-content.js +3 -0
  321. package/lib/components/dialog/src/dialog-content.js.map +1 -1
  322. package/lib/components/dialog/src/dialog-content.vue.d.ts +3 -0
  323. package/lib/components/dialog/src/dialog-content2.js +11 -6
  324. package/lib/components/dialog/src/dialog-content2.js.map +1 -1
  325. package/lib/components/dialog/src/dialog.d.ts +1 -0
  326. package/lib/components/dialog/src/dialog.js +97 -58
  327. package/lib/components/dialog/src/dialog.js.map +1 -1
  328. package/lib/components/dialog/src/dialog.vue.d.ts +4 -0
  329. package/lib/components/dialog/src/dialog2.js +61 -96
  330. package/lib/components/dialog/src/dialog2.js.map +1 -1
  331. package/lib/components/drawer/index.d.ts +3 -0
  332. package/lib/components/drawer/src/drawer.d.ts +1 -0
  333. package/lib/components/drawer/src/drawer.js +4 -1
  334. package/lib/components/drawer/src/drawer.js.map +1 -1
  335. package/lib/components/drawer/src/drawer.vue.d.ts +3 -0
  336. package/lib/components/drawer/src/drawer2.js +63 -64
  337. package/lib/components/drawer/src/drawer2.js.map +1 -1
  338. package/lib/components/dropdown/index.js +2 -2
  339. package/lib/components/dropdown/src/dropdown-item-impl.js +3 -3
  340. package/lib/components/dropdown/src/dropdown-item.js +1 -1
  341. package/lib/components/dropdown/src/dropdown-menu.js +2 -2
  342. package/lib/components/dropdown/src/dropdown.js +109 -109
  343. package/lib/components/dropdown/src/dropdown.js.map +1 -1
  344. package/lib/components/dropdown/src/dropdown2.js +109 -109
  345. package/lib/components/dropdown/src/dropdown2.js.map +1 -1
  346. package/lib/components/empty/index.js +2 -2
  347. package/lib/components/empty/src/empty.js +11 -56
  348. package/lib/components/empty/src/empty.js.map +1 -1
  349. package/lib/components/empty/src/empty2.js +56 -11
  350. package/lib/components/empty/src/empty2.js.map +1 -1
  351. package/lib/components/form/index.d.ts +8 -0
  352. package/lib/components/form/index.js +2 -2
  353. package/lib/components/form/src/form-item.d.ts +1 -0
  354. package/lib/components/form/src/form-item.js +3 -0
  355. package/lib/components/form/src/form-item.js.map +1 -1
  356. package/lib/components/form/src/form-item.vue.d.ts +4 -0
  357. package/lib/components/form/src/form-item2.js +12 -7
  358. package/lib/components/form/src/form-item2.js.map +1 -1
  359. package/lib/components/form/src/form.js +45 -40
  360. package/lib/components/form/src/form.js.map +1 -1
  361. package/lib/components/form/src/form2.js +40 -45
  362. package/lib/components/form/src/form2.js.map +1 -1
  363. package/lib/components/icon/index.js +2 -2
  364. package/lib/components/icon/src/icon.js +8 -35
  365. package/lib/components/icon/src/icon.js.map +1 -1
  366. package/lib/components/icon/src/icon2.js +35 -8
  367. package/lib/components/icon/src/icon2.js.map +1 -1
  368. package/lib/components/image/index.d.ts +1 -1
  369. package/lib/components/image/index.js +2 -2
  370. package/lib/components/image/src/image.js +50 -158
  371. package/lib/components/image/src/image.js.map +1 -1
  372. package/lib/components/image/src/image.vue.d.ts +1 -1
  373. package/lib/components/image/src/image2.js +158 -50
  374. package/lib/components/image/src/image2.js.map +1 -1
  375. package/lib/components/index.js +27 -27
  376. package/lib/components/input/index.d.ts +4 -0
  377. package/lib/components/input/index.js +2 -2
  378. package/lib/components/input/src/input.d.ts +1 -0
  379. package/lib/components/input/src/input.js +84 -293
  380. package/lib/components/input/src/input.js.map +1 -1
  381. package/lib/components/input/src/input.vue.d.ts +4 -0
  382. package/lib/components/input/src/input2.js +295 -81
  383. package/lib/components/input/src/input2.js.map +1 -1
  384. package/lib/components/input-number/index.d.ts +8 -0
  385. package/lib/components/input-number/src/input-number.vue.d.ts +8 -0
  386. package/lib/components/menu/index.js +2 -2
  387. package/lib/components/menu/src/menu-item.js +16 -73
  388. package/lib/components/menu/src/menu-item.js.map +1 -1
  389. package/lib/components/menu/src/menu-item2.js +73 -16
  390. package/lib/components/menu/src/menu-item2.js.map +1 -1
  391. package/lib/components/popconfirm/src/popconfirm.js +1 -1
  392. package/lib/components/popover/index.d.ts +2 -2
  393. package/lib/components/popover/src/index.vue.d.ts +1 -1
  394. package/lib/components/popover/src/popover.js +2 -2
  395. package/lib/components/popper/index.js +2 -2
  396. package/lib/components/popper/src/content.vue.d.ts +1 -1
  397. package/lib/components/popper/src/trigger.js +36 -17
  398. package/lib/components/popper/src/trigger.js.map +1 -1
  399. package/lib/components/popper/src/trigger2.js +17 -36
  400. package/lib/components/popper/src/trigger2.js.map +1 -1
  401. package/lib/components/progress/index.d.ts +3 -3
  402. package/lib/components/progress/index.js +2 -2
  403. package/lib/components/progress/src/progress.d.ts +1 -1
  404. package/lib/components/progress/src/progress.js +57 -230
  405. package/lib/components/progress/src/progress.js.map +1 -1
  406. package/lib/components/progress/src/progress.vue.d.ts +3 -3
  407. package/lib/components/progress/src/progress2.js +230 -57
  408. package/lib/components/progress/src/progress2.js.map +1 -1
  409. package/lib/components/radio/index.js +2 -2
  410. package/lib/components/radio/src/radio-button.js +1 -1
  411. package/lib/components/radio/src/radio-button2.js +1 -1
  412. package/lib/components/radio/src/radio.js +73 -69
  413. package/lib/components/radio/src/radio.js.map +1 -1
  414. package/lib/components/radio/src/radio2.js +69 -73
  415. package/lib/components/radio/src/radio2.js.map +1 -1
  416. package/lib/components/rate/index.js +2 -2
  417. package/lib/components/rate/src/rate.js +84 -169
  418. package/lib/components/rate/src/rate.js.map +1 -1
  419. package/lib/components/rate/src/rate2.js +169 -84
  420. package/lib/components/rate/src/rate2.js.map +1 -1
  421. package/lib/components/result/index.js +2 -2
  422. package/lib/components/result/src/result.js +30 -73
  423. package/lib/components/result/src/result.js.map +1 -1
  424. package/lib/components/result/src/result2.js +73 -30
  425. package/lib/components/result/src/result2.js.map +1 -1
  426. package/lib/components/roving-focus-group/index.js +2 -2
  427. package/lib/components/roving-focus-group/src/roving-focus-group-impl.js +1 -1
  428. package/lib/components/roving-focus-group/src/roving-focus-group.js +33 -27
  429. package/lib/components/roving-focus-group/src/roving-focus-group.js.map +1 -1
  430. package/lib/components/roving-focus-group/src/roving-focus-group2.js +27 -33
  431. package/lib/components/roving-focus-group/src/roving-focus-group2.js.map +1 -1
  432. package/lib/components/roving-focus-group/src/roving-focus-item.js +1 -1
  433. package/lib/components/scrollbar/index.js +1 -1
  434. package/lib/components/scrollbar/src/bar.js +1 -1
  435. package/lib/components/scrollbar/src/thumb.js +11 -59
  436. package/lib/components/scrollbar/src/thumb.js.map +1 -1
  437. package/lib/components/scrollbar/src/thumb.vue.d.ts +1 -1
  438. package/lib/components/scrollbar/src/thumb2.js +59 -11
  439. package/lib/components/scrollbar/src/thumb2.js.map +1 -1
  440. package/lib/components/select/index.d.ts +4 -4
  441. package/lib/components/select/src/select.js +1 -1
  442. package/lib/components/select/src/select.vue.d.ts +4 -4
  443. package/lib/components/select/src/useSelect.d.ts +3 -3
  444. package/lib/components/select-v2/index.d.ts +8 -8
  445. package/lib/components/select-v2/src/defaults.js +1 -1
  446. package/lib/components/select-v2/src/select.vue.d.ts +4 -4
  447. package/lib/components/select-v2/src/useSelect.d.ts +3 -3
  448. package/lib/components/skeleton/index.js +2 -2
  449. package/lib/components/skeleton/src/skeleton.js +49 -22
  450. package/lib/components/skeleton/src/skeleton.js.map +1 -1
  451. package/lib/components/skeleton/src/skeleton2.js +22 -49
  452. package/lib/components/skeleton/src/skeleton2.js.map +1 -1
  453. package/lib/components/switch/index.d.ts +1 -1
  454. package/lib/components/switch/src/switch.vue.d.ts +1 -1
  455. package/lib/components/table/index.d.ts +13 -1
  456. package/lib/components/table/src/filter-panel.vue.d.ts +3 -3
  457. package/lib/components/table/src/table-body/render-helper.js +2 -1
  458. package/lib/components/table/src/table-body/render-helper.js.map +1 -1
  459. package/lib/components/table/src/table-column/defaults.d.ts +4 -0
  460. package/lib/components/table/src/table-column/defaults.js +3 -0
  461. package/lib/components/table/src/table-column/defaults.js.map +1 -1
  462. package/lib/components/table/src/table-column/index.d.ts +6 -0
  463. package/lib/components/table/src/table-column/index.js +2 -1
  464. package/lib/components/table/src/table-column/index.js.map +1 -1
  465. package/lib/components/table/src/table-header/index.js +1 -8
  466. package/lib/components/table/src/table-header/index.js.map +1 -1
  467. package/lib/components/table/src/table.vue.d.ts +1 -1
  468. package/lib/components/teleport/index.js +2 -2
  469. package/lib/components/teleport/src/teleport.js +18 -43
  470. package/lib/components/teleport/src/teleport.js.map +1 -1
  471. package/lib/components/teleport/src/teleport2.js +43 -18
  472. package/lib/components/teleport/src/teleport2.js.map +1 -1
  473. package/lib/components/time-picker/src/common/picker.vue.d.ts +3 -3
  474. package/lib/components/time-select/index.d.ts +4 -4
  475. package/lib/components/time-select/src/time-select.vue.d.ts +2 -2
  476. package/lib/components/timeline/index.js +2 -2
  477. package/lib/components/timeline/src/timeline-item.js +73 -39
  478. package/lib/components/timeline/src/timeline-item.js.map +1 -1
  479. package/lib/components/timeline/src/timeline-item2.js +39 -73
  480. package/lib/components/timeline/src/timeline-item2.js.map +1 -1
  481. package/lib/components/tooltip/index.d.ts +1 -1
  482. package/lib/components/tooltip/index.js +2 -2
  483. package/lib/components/tooltip/src/tooltip.js +65 -50
  484. package/lib/components/tooltip/src/tooltip.js.map +1 -1
  485. package/lib/components/tooltip/src/tooltip.vue.d.ts +1 -1
  486. package/lib/components/tooltip/src/tooltip2.js +50 -65
  487. package/lib/components/tooltip/src/tooltip2.js.map +1 -1
  488. package/lib/components/tooltip/src/trigger.js +2 -2
  489. package/lib/components/tooltip-v2/index.js +2 -2
  490. package/lib/components/tooltip-v2/src/content.js +113 -50
  491. package/lib/components/tooltip-v2/src/content.js.map +1 -1
  492. package/lib/components/tooltip-v2/src/content2.js +50 -113
  493. package/lib/components/tooltip-v2/src/content2.js.map +1 -1
  494. package/lib/components/tooltip-v2/src/tooltip.js +2 -2
  495. package/lib/components/tooltip-v2/src/tooltip2.js +4 -4
  496. package/lib/components/tooltip-v2/src/trigger.js +11 -89
  497. package/lib/components/tooltip-v2/src/trigger.js.map +1 -1
  498. package/lib/components/tooltip-v2/src/trigger2.js +89 -11
  499. package/lib/components/tooltip-v2/src/trigger2.js.map +1 -1
  500. package/lib/components/upload/index.js +3 -3
  501. package/lib/components/upload/src/upload-content.js +1 -1
  502. package/lib/components/upload/src/upload-list.js +155 -27
  503. package/lib/components/upload/src/upload-list.js.map +1 -1
  504. package/lib/components/upload/src/upload-list.vue.d.ts +3 -3
  505. package/lib/components/upload/src/upload-list2.js +27 -155
  506. package/lib/components/upload/src/upload-list2.js.map +1 -1
  507. package/lib/components/upload/src/upload.js +99 -109
  508. package/lib/components/upload/src/upload.js.map +1 -1
  509. package/lib/components/upload/src/upload2.js +109 -99
  510. package/lib/components/upload/src/upload2.js.map +1 -1
  511. package/lib/components/virtual-list/src/builders/build-list.d.ts +1 -1
  512. package/lib/components/virtual-list/src/components/dynamic-size-list.d.ts +1 -1
  513. package/lib/components/virtual-list/src/components/fixed-size-list.d.ts +1 -1
  514. package/lib/index.js +27 -27
  515. package/package.json +1 -1
  516. package/web-types.json +1 -1
@@ -2,304 +2,95 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var vue = require('vue');
6
- var core = require('@vueuse/core');
7
- var lodashUnified = require('lodash-unified');
8
- var iconsVue = require('@element-plus/icons-vue');
9
5
  require('../../../utils/index.js');
10
6
  require('../../../hooks/index.js');
11
- var utils = require('./utils.js');
12
- var input = require('./input2.js');
13
- var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
14
- var index = require('../../../hooks/use-attrs/index.js');
15
- var index$1 = require('../../../hooks/use-form-item/index.js');
16
- var index$2 = require('../../../hooks/use-common-props/index.js');
17
- var index$3 = require('../../../hooks/use-namespace/index.js');
7
+ var props = require('../../../utils/vue/props.js');
8
+ var index = require('../../../hooks/use-common-props/index.js');
18
9
  var icon = require('../../../utils/vue/icon.js');
19
- var shared = require('@vue/shared');
20
- var error = require('../../../utils/error.js');
10
+ var typescript = require('../../../utils/typescript.js');
21
11
 
22
- const _hoisted_1 = ["type", "disabled", "formatter", "parser", "readonly", "autocomplete", "tabindex", "aria-label", "placeholder"];
23
- const _hoisted_2 = ["tabindex", "disabled", "readonly", "autocomplete", "aria-label", "placeholder"];
24
- const __default__ = {
25
- name: "PsInput",
26
- inheritAttrs: false
27
- };
28
- const _sfc_main = /* @__PURE__ */ vue.defineComponent({
29
- ...__default__,
30
- props: input.inputProps,
31
- setup(__props, { expose }) {
32
- const props = __props;
33
- const PENDANT_MAP = {
34
- suffix: "append",
35
- prefix: "prepend"
36
- };
37
- const instance = vue.getCurrentInstance();
38
- const rawAttrs = vue.useAttrs();
39
- const slots = vue.useSlots();
40
- const attrs = index.useAttrs();
41
- const { form, formItem } = index$1.useFormItem();
42
- const inputSize = index$2.useSize();
43
- const inputDisabled = index$2.useDisabled();
44
- const nsInput = index$3.useNamespace("input");
45
- const nsTextarea = index$3.useNamespace("textarea");
46
- const input = vue.shallowRef();
47
- const textarea = vue.shallowRef();
48
- const focused = vue.ref(false);
49
- const hovering = vue.ref(false);
50
- const isComposing = vue.ref(false);
51
- const passwordVisible = vue.ref(false);
52
- const textareaCalcStyle = vue.shallowRef(props.inputStyle);
53
- const _ref = vue.computed(() => input.value || textarea.value);
54
- const needStatusIcon = vue.computed(() => {
55
- var _a;
56
- return (_a = form == null ? void 0 : form.statusIcon) != null ? _a : false;
57
- });
58
- const validateState = vue.computed(() => (formItem == null ? void 0 : formItem.validateState) || "");
59
- const validateIcon = vue.computed(() => icon.ValidateComponentsMap[validateState.value]);
60
- const passwordIcon = vue.computed(() => passwordVisible.value ? iconsVue.View : iconsVue.Hide);
61
- const containerStyle = vue.computed(() => [
62
- rawAttrs.style,
63
- props.inputStyle
64
- ]);
65
- const textareaStyle = vue.computed(() => [
66
- props.inputStyle,
67
- textareaCalcStyle.value,
68
- { resize: props.resize }
69
- ]);
70
- const nativeInputValue = vue.computed(() => lodashUnified.isNil(props.modelValue) ? "" : String(props.modelValue));
71
- const showClear = vue.computed(() => props.clearable && !inputDisabled.value && !props.readonly && !!nativeInputValue.value && (focused.value || hovering.value));
72
- const showPwdVisible = vue.computed(() => props.showPassword && !inputDisabled.value && !props.readonly && (!!nativeInputValue.value || focused.value));
73
- const isWordLimitVisible = vue.computed(() => props.showWordLimit && !!attrs.value.maxlength && (props.type === "text" || props.type === "textarea") && !inputDisabled.value && !props.readonly && !props.showPassword);
74
- const textLength = vue.computed(() => Array.from(nativeInputValue.value).length);
75
- const inputExceed = vue.computed(() => !!isWordLimitVisible.value && textLength.value > Number(attrs.value.maxlength));
76
- const suffixVisible = vue.computed(() => !!slots.suffix || !!props.suffixIcon || showClear.value || props.showPassword || isWordLimitVisible.value || !!validateState.value && needStatusIcon.value);
77
- const resizeTextarea = () => {
78
- const { type, autosize } = props;
79
- if (!core.isClient || type !== "textarea")
80
- return;
81
- if (autosize) {
82
- const minRows = shared.isObject(autosize) ? autosize.minRows : void 0;
83
- const maxRows = shared.isObject(autosize) ? autosize.maxRows : void 0;
84
- textareaCalcStyle.value = {
85
- ...utils.calcTextareaHeight(textarea.value, minRows, maxRows)
86
- };
87
- } else {
88
- textareaCalcStyle.value = {
89
- minHeight: utils.calcTextareaHeight(textarea.value).minHeight
90
- };
91
- }
92
- };
93
- const setNativeInputValue = () => {
94
- const input2 = _ref.value;
95
- if (!input2 || input2.value === nativeInputValue.value)
96
- return;
97
- input2.value = nativeInputValue.value;
98
- };
99
- const calcIconOffset = (place) => {
100
- const { el } = instance.vnode;
101
- if (!el)
102
- return;
103
- const elList = Array.from(el.querySelectorAll(`.${nsInput.e(place)}`));
104
- const target = elList.find((item) => item.parentNode === el);
105
- if (!target)
106
- return;
107
- const pendant = PENDANT_MAP[place];
108
- if (slots[pendant]) {
109
- target.style.transform = `translateX(${place === "suffix" ? "-" : ""}${el.querySelector(`.${nsInput.be("group", pendant)}`).offsetWidth}px)`;
110
- } else {
111
- target.removeAttribute("style");
112
- }
113
- };
114
- const updateIconOffset = () => {
115
- calcIconOffset("prefix");
116
- calcIconOffset("suffix");
117
- };
118
- vue.onMounted(async () => {
119
- if (!props.formatter && props.parser) {
120
- error.debugWarn("PsInput", "If you set the parser, you also need to set the formatter.");
121
- }
122
- setNativeInputValue();
123
- updateIconOffset();
124
- await vue.nextTick();
125
- resizeTextarea();
126
- });
127
- vue.onUpdated(async () => {
128
- await vue.nextTick();
129
- updateIconOffset();
130
- });
131
- expose({
132
- input,
133
- textarea,
134
- ref: _ref,
135
- textareaStyle,
136
- autosize: vue.toRef(props, "autosize")
137
- });
138
- return (_ctx, _cache) => {
139
- const _component_ps_icon = vue.resolveComponent("ps-icon");
140
- const _component_circle_close = vue.resolveComponent("circle-close");
141
- return vue.withDirectives((vue.openBlock(), vue.createElementBlock("div", {
142
- class: vue.normalizeClass([
143
- _ctx.type === "textarea" ? vue.unref(nsTextarea).b() : vue.unref(nsInput).b(),
144
- vue.unref(nsInput).m(vue.unref(inputSize)),
145
- vue.unref(nsInput).is("disabled", vue.unref(inputDisabled)),
146
- vue.unref(nsInput).is("exceed", vue.unref(inputExceed)),
147
- {
148
- [vue.unref(nsInput).b("group")]: _ctx.$slots.prepend || _ctx.$slots.append,
149
- [vue.unref(nsInput).bm("group", "append")]: _ctx.$slots.append,
150
- [vue.unref(nsInput).bm("group", "prepend")]: _ctx.$slots.prepend,
151
- [vue.unref(nsInput).m("prefix")]: _ctx.$slots.prefix || _ctx.prefixIcon,
152
- [vue.unref(nsInput).m("suffix")]: _ctx.$slots.suffix || _ctx.suffixIcon || _ctx.clearable || _ctx.showPassword,
153
- [vue.unref(nsInput).bm("suffix", "password-clear")]: vue.unref(showClear) && vue.unref(showPwdVisible)
154
- },
155
- _ctx.$attrs.class
156
- ]),
157
- style: vue.normalizeStyle(vue.unref(containerStyle))
158
- }, [
159
- vue.createCommentVNode(" input "),
160
- _ctx.type !== "textarea" ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 0 }, [
161
- vue.createCommentVNode(" prepend slot "),
162
- _ctx.$slots.prepend ? (vue.openBlock(), vue.createElementBlock("div", {
163
- key: 0,
164
- class: vue.normalizeClass(vue.unref(nsInput).be("group", "prepend"))
165
- }, [
166
- vue.renderSlot(_ctx.$slots, "prepend")
167
- ], 2)) : vue.createCommentVNode("v-if", true),
168
- vue.createElementVNode("div", {
169
- class: vue.normalizeClass([vue.unref(nsInput).e("wrapper"), vue.unref(nsInput).is("focus", focused.value)])
170
- }, [
171
- vue.createCommentVNode(" prefix slot "),
172
- _ctx.$slots.prefix || _ctx.prefixIcon ? (vue.openBlock(), vue.createElementBlock("span", {
173
- key: 0,
174
- class: vue.normalizeClass(vue.unref(nsInput).e("prefix"))
175
- }, [
176
- vue.createElementVNode("span", {
177
- class: vue.normalizeClass(vue.unref(nsInput).e("prefix-inner"))
178
- }, [
179
- vue.renderSlot(_ctx.$slots, "prefix"),
180
- _ctx.prefixIcon ? (vue.openBlock(), vue.createBlock(_component_ps_icon, {
181
- key: 0,
182
- class: vue.normalizeClass(vue.unref(nsInput).e("icon"))
183
- }, {
184
- default: vue.withCtx(() => [
185
- (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.prefixIcon)))
186
- ]),
187
- _: 1
188
- }, 8, ["class"])) : vue.createCommentVNode("v-if", true)
189
- ], 2)
190
- ], 2)) : vue.createCommentVNode("v-if", true),
191
- vue.createElementVNode("input", vue.mergeProps({
192
- ref_key: "input",
193
- ref: input,
194
- class: vue.unref(nsInput).e("inner")
195
- }, vue.unref(attrs), {
196
- type: _ctx.showPassword ? passwordVisible.value ? "text" : "password" : _ctx.type,
197
- disabled: vue.unref(inputDisabled),
198
- formatter: _ctx.formatter,
199
- parser: _ctx.parser,
200
- readonly: _ctx.readonly,
201
- autocomplete: _ctx.autocomplete,
202
- tabindex: _ctx.tabindex,
203
- "aria-label": _ctx.label,
204
- placeholder: _ctx.placeholder,
205
- style: _ctx.inputStyle
206
- }), null, 16, _hoisted_1),
207
- vue.createCommentVNode(" suffix slot "),
208
- vue.unref(suffixVisible) ? (vue.openBlock(), vue.createElementBlock("span", {
209
- key: 1,
210
- class: vue.normalizeClass(vue.unref(nsInput).e("suffix"))
211
- }, [
212
- vue.createElementVNode("span", {
213
- class: vue.normalizeClass(vue.unref(nsInput).e("suffix-inner"))
214
- }, [
215
- !vue.unref(showClear) || !vue.unref(showPwdVisible) || !vue.unref(isWordLimitVisible) ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 0 }, [
216
- vue.renderSlot(_ctx.$slots, "suffix"),
217
- _ctx.suffixIcon ? (vue.openBlock(), vue.createBlock(_component_ps_icon, {
218
- key: 0,
219
- class: vue.normalizeClass(vue.unref(nsInput).e("icon"))
220
- }, {
221
- default: vue.withCtx(() => [
222
- (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.suffixIcon)))
223
- ]),
224
- _: 1
225
- }, 8, ["class"])) : vue.createCommentVNode("v-if", true)
226
- ], 64)) : vue.createCommentVNode("v-if", true),
227
- vue.unref(showClear) ? (vue.openBlock(), vue.createBlock(_component_ps_icon, {
228
- key: 1,
229
- class: vue.normalizeClass([vue.unref(nsInput).e("icon"), vue.unref(nsInput).e("clear")])
230
- }, {
231
- default: vue.withCtx(() => [
232
- vue.createVNode(_component_circle_close)
233
- ]),
234
- _: 1
235
- }, 8, ["class"])) : vue.createCommentVNode("v-if", true),
236
- vue.unref(showPwdVisible) ? (vue.openBlock(), vue.createBlock(_component_ps_icon, {
237
- key: 2,
238
- class: vue.normalizeClass([vue.unref(nsInput).e("icon"), vue.unref(nsInput).e("password")])
239
- }, {
240
- default: vue.withCtx(() => [
241
- (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(vue.unref(passwordIcon))))
242
- ]),
243
- _: 1
244
- }, 8, ["class"])) : vue.createCommentVNode("v-if", true),
245
- vue.unref(isWordLimitVisible) ? (vue.openBlock(), vue.createElementBlock("span", {
246
- key: 3,
247
- class: vue.normalizeClass(vue.unref(nsInput).e("count"))
248
- }, [
249
- vue.createElementVNode("span", {
250
- class: vue.normalizeClass(vue.unref(nsInput).e("count-inner"))
251
- }, vue.toDisplayString(vue.unref(textLength)) + " / " + vue.toDisplayString(vue.unref(attrs).maxlength), 3)
252
- ], 2)) : vue.createCommentVNode("v-if", true),
253
- vue.unref(validateState) && vue.unref(validateIcon) && vue.unref(needStatusIcon) ? (vue.openBlock(), vue.createBlock(_component_ps_icon, {
254
- key: 4,
255
- class: vue.normalizeClass([
256
- vue.unref(nsInput).e("icon"),
257
- vue.unref(nsInput).e("validateIcon"),
258
- vue.unref(nsInput).is("loading", vue.unref(validateState) === "validating")
259
- ])
260
- }, {
261
- default: vue.withCtx(() => [
262
- (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(vue.unref(validateIcon))))
263
- ]),
264
- _: 1
265
- }, 8, ["class"])) : vue.createCommentVNode("v-if", true)
266
- ], 2)
267
- ], 2)) : vue.createCommentVNode("v-if", true)
268
- ], 2),
269
- vue.createCommentVNode(" append slot "),
270
- _ctx.$slots.append ? (vue.openBlock(), vue.createElementBlock("div", {
271
- key: 1,
272
- class: vue.normalizeClass(vue.unref(nsInput).be("group", "append"))
273
- }, [
274
- vue.renderSlot(_ctx.$slots, "append")
275
- ], 2)) : vue.createCommentVNode("v-if", true)
276
- ], 64)) : (vue.openBlock(), vue.createElementBlock(vue.Fragment, { key: 1 }, [
277
- vue.createCommentVNode(" textarea "),
278
- vue.createElementVNode("textarea", vue.mergeProps({
279
- ref_key: "textarea",
280
- ref: textarea,
281
- class: vue.unref(nsTextarea).e("inner")
282
- }, vue.unref(attrs), {
283
- tabindex: _ctx.tabindex,
284
- disabled: vue.unref(inputDisabled),
285
- readonly: _ctx.readonly,
286
- autocomplete: _ctx.autocomplete,
287
- style: vue.unref(textareaStyle),
288
- "aria-label": _ctx.label,
289
- placeholder: _ctx.placeholder
290
- }), null, 16, _hoisted_2),
291
- vue.unref(isWordLimitVisible) ? (vue.openBlock(), vue.createElementBlock("span", {
292
- key: 0,
293
- class: vue.normalizeClass(vue.unref(nsInput).e("count"))
294
- }, vue.toDisplayString(vue.unref(textLength)) + " / " + vue.toDisplayString(vue.unref(attrs).maxlength), 3)) : vue.createCommentVNode("v-if", true)
295
- ], 64))
296
- ], 6)), [
297
- [vue.vShow, _ctx.type !== "hidden"]
298
- ]);
299
- };
12
+ const inputProps = props.buildProps({
13
+ size: index.useSizeProp,
14
+ disabled: Boolean,
15
+ modelValue: {
16
+ type: props.definePropType([
17
+ String,
18
+ Number,
19
+ Object
20
+ ]),
21
+ default: ""
22
+ },
23
+ type: {
24
+ type: String,
25
+ default: "text"
26
+ },
27
+ resize: {
28
+ type: String,
29
+ values: ["none", "both", "horizontal", "vertical"]
30
+ },
31
+ autosize: {
32
+ type: props.definePropType([Boolean, Object]),
33
+ default: false
34
+ },
35
+ autocomplete: {
36
+ type: String,
37
+ default: "off"
38
+ },
39
+ formatter: {
40
+ type: Function
41
+ },
42
+ parser: {
43
+ type: Function
44
+ },
45
+ placeholder: {
46
+ type: String
47
+ },
48
+ form: {
49
+ type: String,
50
+ default: ""
51
+ },
52
+ readonly: {
53
+ type: Boolean,
54
+ default: false
55
+ },
56
+ clearable: {
57
+ type: Boolean,
58
+ default: false
59
+ },
60
+ showPassword: {
61
+ type: Boolean,
62
+ default: false
63
+ },
64
+ showWordLimit: {
65
+ type: Boolean,
66
+ default: false
67
+ },
68
+ suffixIcon: {
69
+ type: icon.iconPropType,
70
+ default: ""
71
+ },
72
+ prefixIcon: {
73
+ type: icon.iconPropType,
74
+ default: ""
75
+ },
76
+ label: {
77
+ type: String
78
+ },
79
+ tabindex: {
80
+ type: [Number, String]
81
+ },
82
+ validateEvent: {
83
+ type: Boolean,
84
+ default: true
85
+ },
86
+ inputStyle: {
87
+ type: props.definePropType([Object, Array, String]),
88
+ default: () => typescript.mutable({})
89
+ },
90
+ widget: {
91
+ type: String
300
92
  }
301
93
  });
302
- var Input = /* @__PURE__ */ pluginVue_exportHelper["default"](_sfc_main, [["__file", "/Users/meng/workspace/element-ps/packages/components/input/src/input.vue"]]);
303
94
 
304
- exports["default"] = Input;
95
+ exports.inputProps = inputProps;
305
96
  //# sourceMappingURL=input.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"input.js","sources":["../../../../../../packages/components/input/src/input.vue"],"sourcesContent":["<template>\n <div\n v-show=\"type !== 'hidden'\"\n :class=\"[\n type === 'textarea' ? nsTextarea.b() : nsInput.b(),\n nsInput.m(inputSize),\n nsInput.is('disabled', inputDisabled),\n nsInput.is('exceed', inputExceed),\n {\n [nsInput.b('group')]: $slots.prepend || $slots.append,\n [nsInput.bm('group', 'append')]: $slots.append,\n [nsInput.bm('group', 'prepend')]: $slots.prepend,\n [nsInput.m('prefix')]: $slots.prefix || prefixIcon,\n [nsInput.m('suffix')]:\n $slots.suffix || suffixIcon || clearable || showPassword,\n [nsInput.bm('suffix', 'password-clear')]: showClear && showPwdVisible,\n },\n $attrs.class,\n ]\"\n :style=\"containerStyle\"\n >\n <!-- input -->\n <template v-if=\"type !== 'textarea'\">\n <!-- prepend slot -->\n <div v-if=\"$slots.prepend\" :class=\"nsInput.be('group', 'prepend')\">\n <slot name=\"prepend\" />\n </div>\n\n <div :class=\"[nsInput.e('wrapper'), nsInput.is('focus', focused)]\">\n <!-- prefix slot -->\n <span v-if=\"$slots.prefix || prefixIcon\" :class=\"nsInput.e('prefix')\">\n <span :class=\"nsInput.e('prefix-inner')\">\n <slot name=\"prefix\" />\n <ps-icon v-if=\"prefixIcon\" :class=\"nsInput.e('icon')\">\n <component :is=\"prefixIcon\" />\n </ps-icon>\n </span>\n </span>\n\n <input\n ref=\"input\"\n :class=\"nsInput.e('inner')\"\n v-bind=\"attrs\"\n :type=\"showPassword ? (passwordVisible ? 'text' : 'password') : type\"\n :disabled=\"inputDisabled\"\n :formatter=\"formatter\"\n :parser=\"parser\"\n :readonly=\"readonly\"\n :autocomplete=\"autocomplete\"\n :tabindex=\"tabindex\"\n :aria-label=\"label\"\n :placeholder=\"placeholder\"\n :style=\"inputStyle\"\n />\n\n <!-- suffix slot -->\n <span v-if=\"suffixVisible\" :class=\"nsInput.e('suffix')\">\n <span :class=\"nsInput.e('suffix-inner')\">\n <template\n v-if=\"!showClear || !showPwdVisible || !isWordLimitVisible\"\n >\n <slot name=\"suffix\" />\n <ps-icon v-if=\"suffixIcon\" :class=\"nsInput.e('icon')\">\n <component :is=\"suffixIcon\" />\n </ps-icon>\n </template>\n <ps-icon\n v-if=\"showClear\"\n :class=\"[nsInput.e('icon'), nsInput.e('clear')]\"\n >\n <circle-close />\n </ps-icon>\n <ps-icon\n v-if=\"showPwdVisible\"\n :class=\"[nsInput.e('icon'), nsInput.e('password')]\"\n >\n <component :is=\"passwordIcon\" />\n </ps-icon>\n <span v-if=\"isWordLimitVisible\" :class=\"nsInput.e('count')\">\n <span :class=\"nsInput.e('count-inner')\">\n {{ textLength }} / {{ attrs.maxlength }}\n </span>\n </span>\n <ps-icon\n v-if=\"validateState && validateIcon && needStatusIcon\"\n :class=\"[\n nsInput.e('icon'),\n nsInput.e('validateIcon'),\n nsInput.is('loading', validateState === 'validating'),\n ]\"\n >\n <component :is=\"validateIcon\" />\n </ps-icon>\n </span>\n </span>\n </div>\n\n <!-- append slot -->\n <div v-if=\"$slots.append\" :class=\"nsInput.be('group', 'append')\">\n <slot name=\"append\" />\n </div>\n </template>\n\n <!-- textarea -->\n <template v-else>\n <textarea\n ref=\"textarea\"\n :class=\"nsTextarea.e('inner')\"\n v-bind=\"attrs\"\n :tabindex=\"tabindex\"\n :disabled=\"inputDisabled\"\n :readonly=\"readonly\"\n :autocomplete=\"autocomplete\"\n :style=\"textareaStyle\"\n :aria-label=\"label\"\n :placeholder=\"placeholder\"\n />\n <span v-if=\"isWordLimitVisible\" :class=\"nsInput.e('count')\">\n {{ textLength }} / {{ attrs.maxlength }}\n </span>\n </template>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {\n computed,\n getCurrentInstance,\n nextTick,\n onMounted,\n onUpdated,\n ref,\n shallowRef,\n toRef,\n useAttrs as useRawAttrs,\n useSlots,\n} from 'vue'\nimport { isClient } from '@vueuse/core'\nimport { isNil } from 'lodash-unified'\nimport {\n Hide as IconHide,\n View as IconView,\n} from '@element-plus/icons-vue'\nimport {\n ValidateComponentsMap,\n debugWarn,\n isObject,\n} from '@element-ps/utils'\nimport {\n useAttrs,\n useDisabled,\n useFormItem,\n useNamespace,\n useSize,\n} from '@element-ps/hooks'\nimport { calcTextareaHeight } from './utils'\nimport { inputProps } from './input'\nimport type { StyleValue } from 'vue'\n\ntype TargetElement = HTMLInputElement | HTMLTextAreaElement\nconst PENDANT_MAP = {\n suffix: 'append',\n prefix: 'prepend',\n} as const\n\ndefineOptions({\n name: 'PsInput',\n inheritAttrs: false,\n})\nconst props = defineProps(inputProps)\n\nconst instance = getCurrentInstance()!\nconst rawAttrs = useRawAttrs()\nconst slots = useSlots()\n\nconst attrs = useAttrs()\nconst { form, formItem } = useFormItem()\nconst inputSize = useSize()\nconst inputDisabled = useDisabled()\nconst nsInput = useNamespace('input')\nconst nsTextarea = useNamespace('textarea')\n\nconst input = shallowRef<HTMLInputElement>()\nconst textarea = shallowRef<HTMLTextAreaElement>()\n\nconst focused = ref(false)\nconst hovering = ref(false)\nconst isComposing = ref(false)\nconst passwordVisible = ref(false)\nconst textareaCalcStyle = shallowRef(props.inputStyle)\n\nconst _ref = computed(() => input.value || textarea.value)\n\nconst needStatusIcon = computed(() => form?.statusIcon ?? false)\nconst validateState = computed(() => formItem?.validateState || '')\nconst validateIcon = computed(() => ValidateComponentsMap[validateState.value])\nconst passwordIcon = computed(() =>\n passwordVisible.value ? IconView : IconHide\n)\nconst containerStyle = computed<StyleValue>(() => [\n rawAttrs.style as StyleValue,\n props.inputStyle,\n])\nconst textareaStyle = computed<StyleValue>(() => [\n props.inputStyle,\n textareaCalcStyle.value,\n { resize: props.resize },\n])\nconst nativeInputValue = computed(() =>\n isNil(props.modelValue) ? '' : String(props.modelValue)\n)\nconst showClear = computed(\n () =>\n props.clearable &&\n !inputDisabled.value &&\n !props.readonly &&\n !!nativeInputValue.value &&\n (focused.value || hovering.value)\n)\nconst showPwdVisible = computed(\n () =>\n props.showPassword &&\n !inputDisabled.value &&\n !props.readonly &&\n (!!nativeInputValue.value || focused.value)\n)\nconst isWordLimitVisible = computed(\n () =>\n props.showWordLimit &&\n !!attrs.value.maxlength &&\n (props.type === 'text' || props.type === 'textarea') &&\n !inputDisabled.value &&\n !props.readonly &&\n !props.showPassword\n)\nconst textLength = computed(() => Array.from(nativeInputValue.value).length)\nconst inputExceed = computed(\n () =>\n // show exceed style if length of initial value greater then maxlength\n !!isWordLimitVisible.value &&\n textLength.value > Number(attrs.value.maxlength)\n)\nconst suffixVisible = computed(\n () =>\n !!slots.suffix ||\n !!props.suffixIcon ||\n showClear.value ||\n props.showPassword ||\n isWordLimitVisible.value ||\n (!!validateState.value && needStatusIcon.value)\n)\n\nconst resizeTextarea = () => {\n const { type, autosize } = props\n\n if (!isClient || type !== 'textarea') return\n\n if (autosize) {\n const minRows = isObject(autosize) ? autosize.minRows : undefined\n const maxRows = isObject(autosize) ? autosize.maxRows : undefined\n textareaCalcStyle.value = {\n ...calcTextareaHeight(textarea.value!, minRows, maxRows),\n }\n } else {\n textareaCalcStyle.value = {\n minHeight: calcTextareaHeight(textarea.value!).minHeight,\n }\n }\n}\n\nconst setNativeInputValue = () => {\n const input = _ref.value\n if (!input || input.value === nativeInputValue.value) return\n input.value = nativeInputValue.value\n}\n\nconst calcIconOffset = (place: 'prefix' | 'suffix') => {\n const { el } = instance.vnode\n if (!el) return\n const elList = Array.from(\n (el as Element).querySelectorAll<HTMLSpanElement>(`.${nsInput.e(place)}`)\n )\n const target = elList.find((item) => item.parentNode === el)\n if (!target) return\n\n const pendant = PENDANT_MAP[place]\n\n if (slots[pendant]) {\n target.style.transform = `translateX(${place === 'suffix' ? '-' : ''}${\n el.querySelector(`.${nsInput.be('group', pendant)}`).offsetWidth\n }px)`\n } else {\n target.removeAttribute('style')\n }\n}\n\nconst updateIconOffset = () => {\n calcIconOffset('prefix')\n calcIconOffset('suffix')\n}\n\nonMounted(async () => {\n if (!props.formatter && props.parser) {\n debugWarn(\n 'PsInput',\n 'If you set the parser, you also need to set the formatter.'\n )\n }\n setNativeInputValue()\n updateIconOffset()\n await nextTick()\n resizeTextarea()\n})\n\nonUpdated(async () => {\n await nextTick()\n updateIconOffset()\n})\n\ndefineExpose({\n /** @description HTML input element */\n input,\n /** @description HTML textarea element */\n textarea,\n /** @description HTML element, input or textarea */\n ref: _ref,\n /** @description style of textarea. */\n textareaStyle,\n\n /** @description from props (used on unit test) */\n autosize: toRef(props, 'autosize'),\n})\n</script>\n"],"names":["getCurrentInstance","useRawAttrs","useSlots","useAttrs","useFormItem","useSize","useDisabled","useNamespace","shallowRef","ref","computed","ValidateComponentsMap","IconView","IconHide","isNil","isClient","isObject","calcTextareaHeight","onMounted","debugWarn","nextTick","onUpdated"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgKA,IAAA,MAAA,WAAA,GAAA;AAAA,MACA,MAAA,EAAA,QAAA;AAAA,MACA,MAAA,EAAA,SAAA;AAAA,KACA,CAAA;AAQA,IAAA,MAAA,WAAAA,sBAAA,EAAA,CAAA;AACA,IAAA,MAAA,WAAAC,YAAA,EAAA,CAAA;AACA,IAAA,MAAA,QAAAC,YAAA,EAAA,CAAA;AAEA,IAAA,MAAA,QAAAC,cAAA,EAAA,CAAA;AACA,IAAA,MAAA,EAAA,IAAA,EAAA,QAAA,EAAA,GAAAC,mBAAA,EAAA,CAAA;AACA,IAAA,MAAA,YAAAC,eAAA,EAAA,CAAA;AACA,IAAA,MAAA,gBAAAC,mBAAA,EAAA,CAAA;AACA,IAAA,MAAA,OAAA,GAAAC,qBAAA,OAAA,CAAA,CAAA;AACA,IAAA,MAAA,UAAA,GAAAA,qBAAA,UAAA,CAAA,CAAA;AAEA,IAAA,MAAA,QAAAC,cAAA,EAAA,CAAA;AACA,IAAA,MAAA,WAAAA,cAAA,EAAA,CAAA;AAEA,IAAA,MAAA,OAAA,GAAAC,QAAA,KAAA,CAAA,CAAA;AACA,IAAA,MAAA,QAAA,GAAAA,QAAA,KAAA,CAAA,CAAA;AACA,IAAA,MAAA,WAAA,GAAAA,QAAA,KAAA,CAAA,CAAA;AACA,IAAA,MAAA,eAAA,GAAAA,QAAA,KAAA,CA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"input.js","sources":["../../../../../../packages/components/input/src/input.ts"],"sourcesContent":["import {\n buildProps,\n definePropType,\n iconPropType,\n mutable,\n} from '@element-ps/utils'\nimport { useSizeProp } from '@element-ps/hooks'\nimport type Input from './input.vue'\nimport type { ExtractPropTypes, StyleValue } from 'vue'\n\nexport type InputAutoSize = { minRows?: number; maxRows?: number } | boolean\n\nexport const inputProps = buildProps({\n size: useSizeProp,\n disabled: Boolean,\n modelValue: {\n type: definePropType<string | number | null | undefined>([\n String,\n Number,\n Object,\n ]),\n default: '',\n },\n type: {\n type: String,\n default: 'text',\n },\n resize: {\n type: String,\n values: ['none', 'both', 'horizontal', 'vertical'],\n },\n autosize: {\n type: definePropType<InputAutoSize>([Boolean, Object]),\n default: false,\n },\n autocomplete: {\n type: String,\n default: 'off',\n },\n formatter: {\n type: Function,\n },\n parser: {\n type: Function,\n },\n placeholder: {\n type: String,\n },\n form: {\n type: String,\n default: '',\n },\n readonly: {\n type: Boolean,\n default: false,\n },\n clearable: {\n type: Boolean,\n default: false,\n },\n showPassword: {\n type: Boolean,\n default: false,\n },\n showWordLimit: {\n type: Boolean,\n default: false,\n },\n suffixIcon: {\n type: iconPropType,\n default: '',\n },\n prefixIcon: {\n type: iconPropType,\n default: '',\n },\n label: {\n type: String,\n },\n tabindex: {\n type: [Number, String],\n },\n validateEvent: {\n type: Boolean,\n default: true,\n },\n inputStyle: {\n type: definePropType<StyleValue>([Object, Array, String]),\n default: () => mutable({} as const),\n },\n widget: {\n type: String,\n },\n} as const)\nexport type InputProps = ExtractPropTypes<typeof inputProps>\n\nexport type InputInstance = InstanceType<typeof Input>\n"],"names":["buildProps","useSizeProp","definePropType","iconPropType","mutable"],"mappings":";;;;;;;;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,EAAE,YAAY,EAAE;AAChB,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,KAAK;AAClB,GAAG;AACH,EAAE,aAAa,EAAE;AACjB,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,KAAK;AAClB,GAAG;AACH,EAAE,UAAU,EAAE;AACd,IAAI,IAAI,EAAEC,iBAAY;AACtB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,UAAU,EAAE;AACd,IAAI,IAAI,EAAEA,iBAAY;AACtB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,KAAK,EAAE;AACT,IAAI,IAAI,EAAE,MAAM;AAChB,GAAG;AACH,EAAE,QAAQ,EAAE;AACZ,IAAI,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;AAC1B,GAAG;AACH,EAAE,aAAa,EAAE;AACjB,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,IAAI;AACjB,GAAG;AACH,EAAE,UAAU,EAAE;AACd,IAAI,IAAI,EAAED,oBAAc,CAAC,CAAC,MAAM,EAAE,KAAK,EAAE,MAAM,CAAC,CAAC;AACjD,IAAI,OAAO,EAAE,MAAME,kBAAO,CAAC,EAAE,CAAC;AAC9B,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,GAAG;AACH,CAAC;;;;"}
@@ -21,6 +21,7 @@ declare const _default: import("vue").DefineComponent<{
21
21
  readonly tabindex: import("element-ps/es/utils").BuildPropReturn<readonly [NumberConstructor, StringConstructor], unknown, unknown, unknown, unknown>;
22
22
  readonly validateEvent: import("element-ps/es/utils").BuildPropReturn<BooleanConstructor, true, unknown, unknown, unknown>;
23
23
  readonly inputStyle: import("element-ps/es/utils").BuildPropReturn<import("element-ps/es/utils").PropWrapper<StyleValue>, () => import("element-ps/es/utils").Mutable<{}>, unknown, unknown, unknown>;
24
+ readonly widget: import("element-ps/es/utils").BuildPropReturn<StringConstructor, unknown, unknown, unknown, unknown>;
24
25
  }, {
25
26
  PENDANT_MAP: {
26
27
  readonly suffix: "append";
@@ -48,6 +49,7 @@ declare const _default: import("vue").DefineComponent<{
48
49
  readonly tabindex: import("element-ps/es/utils").BuildPropReturn<readonly [NumberConstructor, StringConstructor], unknown, unknown, unknown, unknown>;
49
50
  readonly validateEvent: import("element-ps/es/utils").BuildPropReturn<BooleanConstructor, true, unknown, unknown, unknown>;
50
51
  readonly inputStyle: import("element-ps/es/utils").BuildPropReturn<import("element-ps/es/utils").PropWrapper<StyleValue>, () => import("element-ps/es/utils").Mutable<{}>, unknown, unknown, unknown>;
52
+ readonly widget: import("element-ps/es/utils").BuildPropReturn<StringConstructor, unknown, unknown, unknown, unknown>;
51
53
  }>> & {
52
54
  [x: string & `on${string}`]: ((...args: any[]) => any) | ((...args: unknown[]) => any) | undefined;
53
55
  }>>;
@@ -138,11 +140,13 @@ declare const _default: import("vue").DefineComponent<{
138
140
  readonly tabindex: import("element-ps/es/utils").BuildPropReturn<readonly [NumberConstructor, StringConstructor], unknown, unknown, unknown, unknown>;
139
141
  readonly validateEvent: import("element-ps/es/utils").BuildPropReturn<BooleanConstructor, true, unknown, unknown, unknown>;
140
142
  readonly inputStyle: import("element-ps/es/utils").BuildPropReturn<import("element-ps/es/utils").PropWrapper<StyleValue>, () => import("element-ps/es/utils").Mutable<{}>, unknown, unknown, unknown>;
143
+ readonly widget: import("element-ps/es/utils").BuildPropReturn<StringConstructor, unknown, unknown, unknown, unknown>;
141
144
  }>>, {
142
145
  type: string;
143
146
  size: import("element-ps/es/utils").BuildPropType<StringConstructor, "" | "default" | "small" | "large", never>;
144
147
  disabled: boolean;
145
148
  label: string;
149
+ widget: string;
146
150
  modelValue: import("element-ps/es/utils").BuildPropType<import("element-ps/es/utils").PropWrapper<string | number | null | undefined>, unknown, unknown>;
147
151
  resize: import("element-ps/es/utils").BuildPropType<StringConstructor, "none" | "both" | "horizontal" | "vertical", unknown>;
148
152
  autosize: import("./input").InputAutoSize;