@element-plus/nightly 0.0.20240402 → 0.0.20240404

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 (402) hide show
  1. package/dist/index.full.js +65 -30
  2. package/dist/index.full.min.js +10 -10
  3. package/dist/index.full.min.js.map +1 -1
  4. package/dist/index.full.min.mjs +10 -10
  5. package/dist/index.full.min.mjs.map +1 -1
  6. package/dist/index.full.mjs +65 -30
  7. package/dist/locale/af.js +1 -1
  8. package/dist/locale/af.min.js +1 -1
  9. package/dist/locale/af.min.mjs +1 -1
  10. package/dist/locale/af.mjs +1 -1
  11. package/dist/locale/ar-eg.js +1 -1
  12. package/dist/locale/ar-eg.min.js +1 -1
  13. package/dist/locale/ar-eg.min.mjs +1 -1
  14. package/dist/locale/ar-eg.mjs +1 -1
  15. package/dist/locale/ar.js +1 -1
  16. package/dist/locale/ar.min.js +1 -1
  17. package/dist/locale/ar.min.mjs +1 -1
  18. package/dist/locale/ar.mjs +1 -1
  19. package/dist/locale/az.js +1 -1
  20. package/dist/locale/az.min.js +1 -1
  21. package/dist/locale/az.min.mjs +1 -1
  22. package/dist/locale/az.mjs +1 -1
  23. package/dist/locale/bg.js +1 -1
  24. package/dist/locale/bg.min.js +1 -1
  25. package/dist/locale/bg.min.mjs +1 -1
  26. package/dist/locale/bg.mjs +1 -1
  27. package/dist/locale/bn.js +1 -1
  28. package/dist/locale/bn.min.js +1 -1
  29. package/dist/locale/bn.min.mjs +1 -1
  30. package/dist/locale/bn.mjs +1 -1
  31. package/dist/locale/ca.js +1 -1
  32. package/dist/locale/ca.min.js +1 -1
  33. package/dist/locale/ca.min.mjs +1 -1
  34. package/dist/locale/ca.mjs +1 -1
  35. package/dist/locale/ckb.js +1 -1
  36. package/dist/locale/ckb.min.js +1 -1
  37. package/dist/locale/ckb.min.mjs +1 -1
  38. package/dist/locale/ckb.mjs +1 -1
  39. package/dist/locale/cs.js +1 -1
  40. package/dist/locale/cs.min.js +1 -1
  41. package/dist/locale/cs.min.mjs +1 -1
  42. package/dist/locale/cs.mjs +1 -1
  43. package/dist/locale/da.js +1 -1
  44. package/dist/locale/da.min.js +1 -1
  45. package/dist/locale/da.min.mjs +1 -1
  46. package/dist/locale/da.mjs +1 -1
  47. package/dist/locale/de.js +1 -1
  48. package/dist/locale/de.min.js +1 -1
  49. package/dist/locale/de.min.mjs +1 -1
  50. package/dist/locale/de.mjs +1 -1
  51. package/dist/locale/el.js +1 -1
  52. package/dist/locale/el.min.js +1 -1
  53. package/dist/locale/el.min.mjs +1 -1
  54. package/dist/locale/el.mjs +1 -1
  55. package/dist/locale/en.js +1 -1
  56. package/dist/locale/en.min.js +1 -1
  57. package/dist/locale/en.min.mjs +1 -1
  58. package/dist/locale/en.mjs +1 -1
  59. package/dist/locale/eo.js +1 -1
  60. package/dist/locale/eo.min.js +1 -1
  61. package/dist/locale/eo.min.mjs +1 -1
  62. package/dist/locale/eo.mjs +1 -1
  63. package/dist/locale/es.js +1 -1
  64. package/dist/locale/es.min.js +1 -1
  65. package/dist/locale/es.min.mjs +1 -1
  66. package/dist/locale/es.mjs +1 -1
  67. package/dist/locale/et.js +1 -1
  68. package/dist/locale/et.min.js +1 -1
  69. package/dist/locale/et.min.mjs +1 -1
  70. package/dist/locale/et.mjs +1 -1
  71. package/dist/locale/eu.js +1 -1
  72. package/dist/locale/eu.min.js +1 -1
  73. package/dist/locale/eu.min.mjs +1 -1
  74. package/dist/locale/eu.mjs +1 -1
  75. package/dist/locale/fa.js +1 -1
  76. package/dist/locale/fa.min.js +1 -1
  77. package/dist/locale/fa.min.mjs +1 -1
  78. package/dist/locale/fa.mjs +1 -1
  79. package/dist/locale/fi.js +1 -1
  80. package/dist/locale/fi.min.js +1 -1
  81. package/dist/locale/fi.min.mjs +1 -1
  82. package/dist/locale/fi.mjs +1 -1
  83. package/dist/locale/fr.js +1 -1
  84. package/dist/locale/fr.min.js +1 -1
  85. package/dist/locale/fr.min.mjs +1 -1
  86. package/dist/locale/fr.mjs +1 -1
  87. package/dist/locale/he.js +1 -1
  88. package/dist/locale/he.min.js +1 -1
  89. package/dist/locale/he.min.mjs +1 -1
  90. package/dist/locale/he.mjs +1 -1
  91. package/dist/locale/hr.js +1 -1
  92. package/dist/locale/hr.min.js +1 -1
  93. package/dist/locale/hr.min.mjs +1 -1
  94. package/dist/locale/hr.mjs +1 -1
  95. package/dist/locale/hu.js +1 -1
  96. package/dist/locale/hu.min.js +1 -1
  97. package/dist/locale/hu.min.mjs +1 -1
  98. package/dist/locale/hu.mjs +1 -1
  99. package/dist/locale/hy-am.js +1 -1
  100. package/dist/locale/hy-am.min.js +1 -1
  101. package/dist/locale/hy-am.min.mjs +1 -1
  102. package/dist/locale/hy-am.mjs +1 -1
  103. package/dist/locale/id.js +1 -1
  104. package/dist/locale/id.min.js +1 -1
  105. package/dist/locale/id.min.mjs +1 -1
  106. package/dist/locale/id.mjs +1 -1
  107. package/dist/locale/it.js +1 -1
  108. package/dist/locale/it.min.js +1 -1
  109. package/dist/locale/it.min.mjs +1 -1
  110. package/dist/locale/it.mjs +1 -1
  111. package/dist/locale/ja.js +1 -1
  112. package/dist/locale/ja.min.js +1 -1
  113. package/dist/locale/ja.min.mjs +1 -1
  114. package/dist/locale/ja.mjs +1 -1
  115. package/dist/locale/kk.js +1 -1
  116. package/dist/locale/kk.min.js +1 -1
  117. package/dist/locale/kk.min.mjs +1 -1
  118. package/dist/locale/kk.mjs +1 -1
  119. package/dist/locale/km.js +1 -1
  120. package/dist/locale/km.min.js +1 -1
  121. package/dist/locale/km.min.mjs +1 -1
  122. package/dist/locale/km.mjs +1 -1
  123. package/dist/locale/ko.js +1 -1
  124. package/dist/locale/ko.min.js +1 -1
  125. package/dist/locale/ko.min.mjs +1 -1
  126. package/dist/locale/ko.mjs +1 -1
  127. package/dist/locale/ku.js +1 -1
  128. package/dist/locale/ku.min.js +1 -1
  129. package/dist/locale/ku.min.mjs +1 -1
  130. package/dist/locale/ku.mjs +1 -1
  131. package/dist/locale/ky.js +1 -1
  132. package/dist/locale/ky.min.js +1 -1
  133. package/dist/locale/ky.min.mjs +1 -1
  134. package/dist/locale/ky.mjs +1 -1
  135. package/dist/locale/lt.js +1 -1
  136. package/dist/locale/lt.min.js +1 -1
  137. package/dist/locale/lt.min.mjs +1 -1
  138. package/dist/locale/lt.mjs +1 -1
  139. package/dist/locale/lv.js +1 -1
  140. package/dist/locale/lv.min.js +1 -1
  141. package/dist/locale/lv.min.mjs +1 -1
  142. package/dist/locale/lv.mjs +1 -1
  143. package/dist/locale/mg.js +1 -1
  144. package/dist/locale/mg.min.js +1 -1
  145. package/dist/locale/mg.min.mjs +1 -1
  146. package/dist/locale/mg.mjs +1 -1
  147. package/dist/locale/mn.js +1 -1
  148. package/dist/locale/mn.min.js +1 -1
  149. package/dist/locale/mn.min.mjs +1 -1
  150. package/dist/locale/mn.mjs +1 -1
  151. package/dist/locale/nb-no.js +1 -1
  152. package/dist/locale/nb-no.min.js +1 -1
  153. package/dist/locale/nb-no.min.mjs +1 -1
  154. package/dist/locale/nb-no.mjs +1 -1
  155. package/dist/locale/nl.js +1 -1
  156. package/dist/locale/nl.min.js +1 -1
  157. package/dist/locale/nl.min.mjs +1 -1
  158. package/dist/locale/nl.mjs +1 -1
  159. package/dist/locale/pa.js +1 -1
  160. package/dist/locale/pa.min.js +1 -1
  161. package/dist/locale/pa.min.mjs +1 -1
  162. package/dist/locale/pa.mjs +1 -1
  163. package/dist/locale/pl.js +1 -1
  164. package/dist/locale/pl.min.js +1 -1
  165. package/dist/locale/pl.min.mjs +1 -1
  166. package/dist/locale/pl.mjs +1 -1
  167. package/dist/locale/pt-br.js +1 -1
  168. package/dist/locale/pt-br.min.js +1 -1
  169. package/dist/locale/pt-br.min.mjs +1 -1
  170. package/dist/locale/pt-br.mjs +1 -1
  171. package/dist/locale/pt.js +1 -1
  172. package/dist/locale/pt.min.js +1 -1
  173. package/dist/locale/pt.min.mjs +1 -1
  174. package/dist/locale/pt.mjs +1 -1
  175. package/dist/locale/ro.js +1 -1
  176. package/dist/locale/ro.min.js +1 -1
  177. package/dist/locale/ro.min.mjs +1 -1
  178. package/dist/locale/ro.mjs +1 -1
  179. package/dist/locale/ru.js +1 -1
  180. package/dist/locale/ru.min.js +1 -1
  181. package/dist/locale/ru.min.mjs +1 -1
  182. package/dist/locale/ru.mjs +1 -1
  183. package/dist/locale/sk.js +1 -1
  184. package/dist/locale/sk.min.js +1 -1
  185. package/dist/locale/sk.min.mjs +1 -1
  186. package/dist/locale/sk.mjs +1 -1
  187. package/dist/locale/sl.js +1 -1
  188. package/dist/locale/sl.min.js +1 -1
  189. package/dist/locale/sl.min.mjs +1 -1
  190. package/dist/locale/sl.mjs +1 -1
  191. package/dist/locale/sr.js +1 -1
  192. package/dist/locale/sr.min.js +1 -1
  193. package/dist/locale/sr.min.mjs +1 -1
  194. package/dist/locale/sr.mjs +1 -1
  195. package/dist/locale/sv.js +1 -1
  196. package/dist/locale/sv.min.js +1 -1
  197. package/dist/locale/sv.min.mjs +1 -1
  198. package/dist/locale/sv.mjs +1 -1
  199. package/dist/locale/sw.js +1 -1
  200. package/dist/locale/sw.min.js +1 -1
  201. package/dist/locale/sw.min.mjs +1 -1
  202. package/dist/locale/sw.mjs +1 -1
  203. package/dist/locale/ta.js +1 -1
  204. package/dist/locale/ta.min.js +1 -1
  205. package/dist/locale/ta.min.mjs +1 -1
  206. package/dist/locale/ta.mjs +1 -1
  207. package/dist/locale/th.js +1 -1
  208. package/dist/locale/th.min.js +1 -1
  209. package/dist/locale/th.min.mjs +1 -1
  210. package/dist/locale/th.mjs +1 -1
  211. package/dist/locale/tk.js +1 -1
  212. package/dist/locale/tk.min.js +1 -1
  213. package/dist/locale/tk.min.mjs +1 -1
  214. package/dist/locale/tk.mjs +1 -1
  215. package/dist/locale/tr.js +1 -1
  216. package/dist/locale/tr.min.js +1 -1
  217. package/dist/locale/tr.min.mjs +1 -1
  218. package/dist/locale/tr.mjs +1 -1
  219. package/dist/locale/ug-cn.js +1 -1
  220. package/dist/locale/ug-cn.min.js +1 -1
  221. package/dist/locale/ug-cn.min.mjs +1 -1
  222. package/dist/locale/ug-cn.mjs +1 -1
  223. package/dist/locale/uk.js +1 -1
  224. package/dist/locale/uk.min.js +1 -1
  225. package/dist/locale/uk.min.mjs +1 -1
  226. package/dist/locale/uk.mjs +1 -1
  227. package/dist/locale/uz-uz.js +1 -1
  228. package/dist/locale/uz-uz.min.js +1 -1
  229. package/dist/locale/uz-uz.min.mjs +1 -1
  230. package/dist/locale/uz-uz.mjs +1 -1
  231. package/dist/locale/vi.js +1 -1
  232. package/dist/locale/vi.min.js +1 -1
  233. package/dist/locale/vi.min.mjs +1 -1
  234. package/dist/locale/vi.mjs +1 -1
  235. package/dist/locale/zh-cn.js +1 -1
  236. package/dist/locale/zh-cn.min.js +1 -1
  237. package/dist/locale/zh-cn.min.mjs +1 -1
  238. package/dist/locale/zh-cn.mjs +1 -1
  239. package/dist/locale/zh-tw.js +1 -1
  240. package/dist/locale/zh-tw.min.js +1 -1
  241. package/dist/locale/zh-tw.min.mjs +1 -1
  242. package/dist/locale/zh-tw.mjs +1 -1
  243. package/es/components/alert/index.mjs +2 -2
  244. package/es/components/alert/src/alert.mjs +36 -96
  245. package/es/components/alert/src/alert.mjs.map +1 -1
  246. package/es/components/alert/src/alert2.mjs +96 -36
  247. package/es/components/alert/src/alert2.mjs.map +1 -1
  248. package/es/components/backtop/index.mjs +2 -2
  249. package/es/components/backtop/src/backtop.mjs +54 -21
  250. package/es/components/backtop/src/backtop.mjs.map +1 -1
  251. package/es/components/backtop/src/backtop2.mjs +21 -54
  252. package/es/components/backtop/src/backtop2.mjs.map +1 -1
  253. package/es/components/badge/index.mjs +2 -2
  254. package/es/components/badge/src/badge.mjs +60 -23
  255. package/es/components/badge/src/badge.mjs.map +1 -1
  256. package/es/components/badge/src/badge2.mjs +23 -60
  257. package/es/components/badge/src/badge2.mjs.map +1 -1
  258. package/es/components/button/index.d.ts +1 -0
  259. package/es/components/button/src/button.vue.d.ts +1 -0
  260. package/es/components/button/src/button2.mjs +15 -14
  261. package/es/components/button/src/button2.mjs.map +1 -1
  262. package/es/components/calendar/index.d.ts +1 -0
  263. package/es/components/calendar/src/calendar.vue.d.ts +2 -1
  264. package/es/components/cascader/src/cascader.mjs +1 -1
  265. package/es/components/color-picker/index.d.ts +1 -0
  266. package/es/components/color-picker/src/color-picker.vue.d.ts +1 -0
  267. package/es/components/date-picker/src/date-picker-com/panel-date-pick.vue.d.ts +1 -0
  268. package/es/components/date-picker/src/date-picker-com/panel-date-range.vue.d.ts +1 -0
  269. package/es/components/date-picker/src/panel-utils.d.ts +2 -0
  270. package/es/components/index.mjs +6 -6
  271. package/es/components/popconfirm/index.d.ts +1 -0
  272. package/es/components/popconfirm/src/popconfirm.vue.d.ts +1 -0
  273. package/es/components/radio/index.mjs +2 -2
  274. package/es/components/radio/src/radio-button.mjs +6 -67
  275. package/es/components/radio/src/radio-button.mjs.map +1 -1
  276. package/es/components/radio/src/radio-button2.mjs +67 -6
  277. package/es/components/radio/src/radio-button2.mjs.map +1 -1
  278. package/es/components/select/src/select.mjs +1 -1
  279. package/es/components/select-v2/src/defaults.mjs +1 -1
  280. package/es/components/table-v2/src/composables/use-row.d.ts +7 -4
  281. package/es/components/table-v2/src/composables/use-row.mjs +20 -4
  282. package/es/components/table-v2/src/composables/use-row.mjs.map +1 -1
  283. package/es/components/table-v2/src/renderers/row.d.ts +3 -2
  284. package/es/components/table-v2/src/renderers/row.mjs +22 -4
  285. package/es/components/table-v2/src/renderers/row.mjs.map +1 -1
  286. package/es/components/table-v2/src/table-v2.mjs +0 -3
  287. package/es/components/table-v2/src/table-v2.mjs.map +1 -1
  288. package/es/components/table-v2/src/tokens.d.ts +0 -2
  289. package/es/components/table-v2/src/tokens.mjs.map +1 -1
  290. package/es/components/table-v2/src/use-table.d.ts +0 -1
  291. package/es/components/table-v2/src/use-table.mjs +10 -5
  292. package/es/components/table-v2/src/use-table.mjs.map +1 -1
  293. package/es/components/tag/index.mjs +2 -2
  294. package/es/components/tag/src/tag.mjs +94 -29
  295. package/es/components/tag/src/tag.mjs.map +1 -1
  296. package/es/components/tag/src/tag2.mjs +29 -94
  297. package/es/components/tag/src/tag2.mjs.map +1 -1
  298. package/es/components/text/index.mjs +2 -2
  299. package/es/components/text/src/text.mjs +38 -24
  300. package/es/components/text/src/text.mjs.map +1 -1
  301. package/es/components/text/src/text2.mjs +24 -38
  302. package/es/components/text/src/text2.mjs.map +1 -1
  303. package/es/components/tour/index.d.ts +2 -0
  304. package/es/components/tour/src/mask.mjs +78 -19
  305. package/es/components/tour/src/mask.mjs.map +1 -1
  306. package/es/components/tour/src/mask2.mjs +19 -78
  307. package/es/components/tour/src/mask2.mjs.map +1 -1
  308. package/es/components/tour/src/step.vue.d.ts +1 -0
  309. package/es/components/tour/src/tour2.mjs +1 -1
  310. package/es/components/transfer/index.d.ts +1 -0
  311. package/es/components/transfer/src/composables/use-check.mjs +1 -1
  312. package/es/components/transfer/src/transfer-panel.mjs +128 -19
  313. package/es/components/transfer/src/transfer-panel.mjs.map +1 -1
  314. package/es/components/transfer/src/transfer-panel2.mjs +19 -128
  315. package/es/components/transfer/src/transfer-panel2.mjs.map +1 -1
  316. package/es/components/transfer/src/transfer.vue.d.ts +1 -0
  317. package/es/components/transfer/src/transfer2.mjs +1 -1
  318. package/es/index.mjs +6 -6
  319. package/es/version.d.ts +1 -1
  320. package/es/version.mjs +1 -1
  321. package/es/version.mjs.map +1 -1
  322. package/lib/components/alert/index.js +2 -2
  323. package/lib/components/alert/src/alert.js +37 -95
  324. package/lib/components/alert/src/alert.js.map +1 -1
  325. package/lib/components/alert/src/alert2.js +95 -37
  326. package/lib/components/alert/src/alert2.js.map +1 -1
  327. package/lib/components/backtop/index.js +2 -2
  328. package/lib/components/backtop/src/backtop.js +54 -22
  329. package/lib/components/backtop/src/backtop.js.map +1 -1
  330. package/lib/components/backtop/src/backtop2.js +22 -54
  331. package/lib/components/backtop/src/backtop2.js.map +1 -1
  332. package/lib/components/badge/index.js +2 -2
  333. package/lib/components/badge/src/badge.js +60 -23
  334. package/lib/components/badge/src/badge.js.map +1 -1
  335. package/lib/components/badge/src/badge2.js +23 -60
  336. package/lib/components/badge/src/badge2.js.map +1 -1
  337. package/lib/components/button/index.d.ts +1 -0
  338. package/lib/components/button/src/button.vue.d.ts +1 -0
  339. package/lib/components/button/src/button2.js +14 -13
  340. package/lib/components/button/src/button2.js.map +1 -1
  341. package/lib/components/calendar/index.d.ts +1 -0
  342. package/lib/components/calendar/src/calendar.vue.d.ts +2 -1
  343. package/lib/components/cascader/src/cascader.js +1 -1
  344. package/lib/components/color-picker/index.d.ts +1 -0
  345. package/lib/components/color-picker/src/color-picker.vue.d.ts +1 -0
  346. package/lib/components/date-picker/src/date-picker-com/panel-date-pick.vue.d.ts +1 -0
  347. package/lib/components/date-picker/src/date-picker-com/panel-date-range.vue.d.ts +1 -0
  348. package/lib/components/date-picker/src/panel-utils.d.ts +2 -0
  349. package/lib/components/index.js +6 -6
  350. package/lib/components/popconfirm/index.d.ts +1 -0
  351. package/lib/components/popconfirm/src/popconfirm.vue.d.ts +1 -0
  352. package/lib/components/radio/index.js +2 -2
  353. package/lib/components/radio/src/radio-button.js +6 -67
  354. package/lib/components/radio/src/radio-button.js.map +1 -1
  355. package/lib/components/radio/src/radio-button2.js +67 -6
  356. package/lib/components/radio/src/radio-button2.js.map +1 -1
  357. package/lib/components/select/src/select.js +1 -1
  358. package/lib/components/select-v2/src/defaults.js +1 -1
  359. package/lib/components/table-v2/src/composables/use-row.d.ts +7 -4
  360. package/lib/components/table-v2/src/composables/use-row.js +20 -4
  361. package/lib/components/table-v2/src/composables/use-row.js.map +1 -1
  362. package/lib/components/table-v2/src/renderers/row.d.ts +3 -2
  363. package/lib/components/table-v2/src/renderers/row.js +22 -4
  364. package/lib/components/table-v2/src/renderers/row.js.map +1 -1
  365. package/lib/components/table-v2/src/table-v2.js +0 -3
  366. package/lib/components/table-v2/src/table-v2.js.map +1 -1
  367. package/lib/components/table-v2/src/tokens.d.ts +0 -2
  368. package/lib/components/table-v2/src/tokens.js.map +1 -1
  369. package/lib/components/table-v2/src/use-table.d.ts +0 -1
  370. package/lib/components/table-v2/src/use-table.js +9 -4
  371. package/lib/components/table-v2/src/use-table.js.map +1 -1
  372. package/lib/components/tag/index.js +2 -2
  373. package/lib/components/tag/src/tag.js +94 -30
  374. package/lib/components/tag/src/tag.js.map +1 -1
  375. package/lib/components/tag/src/tag2.js +30 -94
  376. package/lib/components/tag/src/tag2.js.map +1 -1
  377. package/lib/components/text/index.js +2 -2
  378. package/lib/components/text/src/text.js +38 -24
  379. package/lib/components/text/src/text.js.map +1 -1
  380. package/lib/components/text/src/text2.js +24 -38
  381. package/lib/components/text/src/text2.js.map +1 -1
  382. package/lib/components/tour/index.d.ts +2 -0
  383. package/lib/components/tour/src/mask.js +78 -19
  384. package/lib/components/tour/src/mask.js.map +1 -1
  385. package/lib/components/tour/src/mask2.js +19 -78
  386. package/lib/components/tour/src/mask2.js.map +1 -1
  387. package/lib/components/tour/src/step.vue.d.ts +1 -0
  388. package/lib/components/tour/src/tour2.js +1 -1
  389. package/lib/components/transfer/index.d.ts +1 -0
  390. package/lib/components/transfer/src/composables/use-check.js +1 -1
  391. package/lib/components/transfer/src/transfer-panel.js +128 -21
  392. package/lib/components/transfer/src/transfer-panel.js.map +1 -1
  393. package/lib/components/transfer/src/transfer-panel2.js +21 -128
  394. package/lib/components/transfer/src/transfer-panel2.js.map +1 -1
  395. package/lib/components/transfer/src/transfer.vue.d.ts +1 -0
  396. package/lib/components/transfer/src/transfer2.js +1 -1
  397. package/lib/index.js +6 -6
  398. package/lib/version.d.ts +1 -1
  399. package/lib/version.js +1 -1
  400. package/lib/version.js.map +1 -1
  401. package/package.json +2 -2
  402. package/web-types.json +1 -1
@@ -4,9 +4,11 @@ Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  var vue = require('vue');
6
6
  require('../../../utils/index.js');
7
+ require('../../../hooks/index.js');
7
8
  require('./composables/index.js');
8
9
  var useColumns = require('./composables/use-columns.js');
9
10
  var useScrollbar = require('./composables/use-scrollbar.js');
11
+ var index = require('../../../hooks/use-namespace/index.js');
10
12
  var useRow = require('./composables/use-row.js');
11
13
  var useData = require('./composables/use-data.js');
12
14
  var useStyles = require('./composables/use-styles.js');
@@ -40,9 +42,11 @@ function useTable(props) {
40
42
  rightTableRef,
41
43
  onMaybeEndReached
42
44
  });
45
+ const ns = index.useNamespace("table-v2");
46
+ const instance = vue.getCurrentInstance();
47
+ const isScrolling = vue.shallowRef(false);
43
48
  const {
44
49
  expandedRowKeys,
45
- hoveringRowKey,
46
50
  lastRenderedRowIndex,
47
51
  isDynamic,
48
52
  isResetting,
@@ -55,7 +59,10 @@ function useTable(props) {
55
59
  } = useRow.useRow(props, {
56
60
  mainTableRef,
57
61
  leftTableRef,
58
- rightTableRef
62
+ rightTableRef,
63
+ tableInstance: instance,
64
+ ns,
65
+ isScrolling
59
66
  });
60
67
  const { data, depthMap } = useData.useData(props, {
61
68
  expandedRowKeys,
@@ -81,7 +88,6 @@ function useTable(props) {
81
88
  fixedColumnsOnLeft,
82
89
  fixedColumnsOnRight
83
90
  });
84
- const isScrolling = vue.shallowRef(false);
85
91
  const containerRef = vue.ref();
86
92
  const showEmpty = vue.computed(() => {
87
93
  const noData = vue.unref(data).length === 0;
@@ -117,7 +123,6 @@ function useTable(props) {
117
123
  isDynamic,
118
124
  isResetting,
119
125
  isScrolling,
120
- hoveringRowKey,
121
126
  hasFixedColumns,
122
127
  columnsStyles,
123
128
  columnsTotalWidth,
@@ -1 +1 @@
1
- {"version":3,"file":"use-table.js","sources":["../../../../../../packages/components/table-v2/src/use-table.ts"],"sourcesContent":["import { computed, ref, shallowRef, toRef, unref, watch } from 'vue'\nimport { isArray } from '@element-plus/utils'\nimport {\n useColumns,\n useData,\n useRow,\n useScrollbar,\n useStyles,\n} from './composables'\n\nimport type { TableV2Props } from './table'\nimport type { TableGridInstance } from './table-grid'\n\nfunction useTable(props: TableV2Props) {\n const mainTableRef = ref<TableGridInstance>()\n const leftTableRef = ref<TableGridInstance>()\n const rightTableRef = ref<TableGridInstance>()\n const {\n columns,\n columnsStyles,\n columnsTotalWidth,\n fixedColumnsOnLeft,\n fixedColumnsOnRight,\n hasFixedColumns,\n mainColumns,\n\n onColumnSorted,\n } = useColumns(props, toRef(props, 'columns'), toRef(props, 'fixed'))\n\n const {\n scrollTo,\n scrollToLeft,\n scrollToTop,\n scrollToRow,\n onScroll,\n onVerticalScroll,\n scrollPos,\n } = useScrollbar(props, {\n mainTableRef,\n leftTableRef,\n rightTableRef,\n\n onMaybeEndReached,\n })\n\n const {\n expandedRowKeys,\n hoveringRowKey,\n lastRenderedRowIndex,\n isDynamic,\n isResetting,\n rowHeights,\n\n resetAfterIndex,\n onRowExpanded,\n onRowHeightChange,\n onRowHovered,\n onRowsRendered,\n } = useRow(props, {\n mainTableRef,\n leftTableRef,\n rightTableRef,\n })\n\n const { data, depthMap } = useData(props, {\n expandedRowKeys,\n lastRenderedRowIndex,\n resetAfterIndex,\n })\n\n const {\n bodyWidth,\n fixedTableHeight,\n mainTableHeight,\n leftTableWidth,\n rightTableWidth,\n headerWidth,\n rowsHeight,\n windowHeight,\n footerHeight,\n emptyStyle,\n rootStyle,\n headerHeight,\n } = useStyles(props, {\n columnsTotalWidth,\n data,\n fixedColumnsOnLeft,\n fixedColumnsOnRight,\n })\n // state\n const isScrolling = shallowRef(false)\n\n // DOM/Component refs\n const containerRef = ref()\n\n const showEmpty = computed(() => {\n const noData = unref(data).length === 0\n\n return isArray(props.fixedData)\n ? props.fixedData.length === 0 && noData\n : noData\n })\n\n function getRowHeight(rowIndex: number) {\n const { estimatedRowHeight, rowHeight, rowKey } = props\n\n if (!estimatedRowHeight) return rowHeight\n\n return (\n unref(rowHeights)[unref(data)[rowIndex][rowKey]] || estimatedRowHeight\n )\n }\n\n function onMaybeEndReached() {\n const { onEndReached } = props\n if (!onEndReached) return\n\n const { scrollTop } = unref(scrollPos)\n\n const _totalHeight = unref(rowsHeight)\n const clientHeight = unref(windowHeight)\n\n const heightUntilEnd =\n _totalHeight - (scrollTop + clientHeight) + props.hScrollbarSize\n\n if (\n unref(lastRenderedRowIndex) >= 0 &&\n _totalHeight === scrollTop + unref(mainTableHeight) - unref(headerHeight)\n ) {\n onEndReached(heightUntilEnd)\n }\n }\n\n // events\n\n watch(\n () => props.expandedRowKeys,\n (val) => (expandedRowKeys.value = val),\n {\n deep: true,\n }\n )\n\n return {\n // models\n columns,\n containerRef,\n mainTableRef,\n leftTableRef,\n rightTableRef,\n // states\n isDynamic,\n isResetting,\n isScrolling,\n hoveringRowKey,\n hasFixedColumns,\n // records\n columnsStyles,\n columnsTotalWidth,\n data,\n expandedRowKeys,\n depthMap,\n fixedColumnsOnLeft,\n fixedColumnsOnRight,\n mainColumns,\n // metadata\n bodyWidth,\n emptyStyle,\n rootStyle,\n headerWidth,\n footerHeight,\n mainTableHeight,\n fixedTableHeight,\n leftTableWidth,\n rightTableWidth,\n // flags\n showEmpty,\n\n // methods\n getRowHeight,\n\n // event handlers\n onColumnSorted,\n onRowHovered,\n onRowExpanded,\n onRowsRendered,\n onRowHeightChange,\n // use scrollbars\n scrollTo,\n scrollToLeft,\n scrollToTop,\n scrollToRow,\n onScroll,\n onVerticalScroll,\n }\n}\n\nexport { useTable }\n\nexport type UseTableReturn = ReturnType<typeof useTable>\n"],"names":["ref","useColumns","toRef","useScrollbar","useRow","useData","useStyles","shallowRef","computed","unref","isArray","watch"],"mappings":";;;;;;;;;;;;;;AASA,SAAS,QAAQ,CAAC,KAAK,EAAE;AACzB,EAAE,MAAM,YAAY,GAAGA,OAAG,EAAE,CAAC;AAC7B,EAAE,MAAM,YAAY,GAAGA,OAAG,EAAE,CAAC;AAC7B,EAAE,MAAM,aAAa,GAAGA,OAAG,EAAE,CAAC;AAC9B,EAAE,MAAM;AACR,IAAI,OAAO;AACX,IAAI,aAAa;AACjB,IAAI,iBAAiB;A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CAAC;AACJ;;;;"}
1
+ {"version":3,"file":"use-table.js","sources":["../../../../../../packages/components/table-v2/src/use-table.ts"],"sourcesContent":["import {\n computed,\n getCurrentInstance,\n ref,\n shallowRef,\n toRef,\n unref,\n watch,\n} from 'vue'\nimport { isArray } from '@element-plus/utils'\nimport { useNamespace } from '@element-plus/hooks'\nimport {\n useColumns,\n useData,\n useRow,\n useScrollbar,\n useStyles,\n} from './composables'\n\nimport type { TableV2Props } from './table'\nimport type { TableGridInstance } from './table-grid'\n\nfunction useTable(props: TableV2Props) {\n const mainTableRef = ref<TableGridInstance>()\n const leftTableRef = ref<TableGridInstance>()\n const rightTableRef = ref<TableGridInstance>()\n const {\n columns,\n columnsStyles,\n columnsTotalWidth,\n fixedColumnsOnLeft,\n fixedColumnsOnRight,\n hasFixedColumns,\n mainColumns,\n\n onColumnSorted,\n } = useColumns(props, toRef(props, 'columns'), toRef(props, 'fixed'))\n\n const {\n scrollTo,\n scrollToLeft,\n scrollToTop,\n scrollToRow,\n onScroll,\n onVerticalScroll,\n scrollPos,\n } = useScrollbar(props, {\n mainTableRef,\n leftTableRef,\n rightTableRef,\n\n onMaybeEndReached,\n })\n\n const ns = useNamespace('table-v2')\n const instance = getCurrentInstance()!\n\n // state\n const isScrolling = shallowRef(false)\n\n const {\n expandedRowKeys,\n lastRenderedRowIndex,\n isDynamic,\n isResetting,\n rowHeights,\n resetAfterIndex,\n onRowExpanded,\n onRowHeightChange,\n onRowHovered,\n onRowsRendered,\n } = useRow(props, {\n mainTableRef,\n leftTableRef,\n rightTableRef,\n tableInstance: instance,\n ns,\n isScrolling,\n })\n\n const { data, depthMap } = useData(props, {\n expandedRowKeys,\n lastRenderedRowIndex,\n resetAfterIndex,\n })\n\n const {\n bodyWidth,\n fixedTableHeight,\n mainTableHeight,\n leftTableWidth,\n rightTableWidth,\n headerWidth,\n rowsHeight,\n windowHeight,\n footerHeight,\n emptyStyle,\n rootStyle,\n headerHeight,\n } = useStyles(props, {\n columnsTotalWidth,\n data,\n fixedColumnsOnLeft,\n fixedColumnsOnRight,\n })\n\n // DOM/Component refs\n const containerRef = ref()\n\n const showEmpty = computed(() => {\n const noData = unref(data).length === 0\n\n return isArray(props.fixedData)\n ? props.fixedData.length === 0 && noData\n : noData\n })\n\n function getRowHeight(rowIndex: number) {\n const { estimatedRowHeight, rowHeight, rowKey } = props\n\n if (!estimatedRowHeight) return rowHeight\n\n return (\n unref(rowHeights)[unref(data)[rowIndex][rowKey]] || estimatedRowHeight\n )\n }\n\n function onMaybeEndReached() {\n const { onEndReached } = props\n if (!onEndReached) return\n\n const { scrollTop } = unref(scrollPos)\n\n const _totalHeight = unref(rowsHeight)\n const clientHeight = unref(windowHeight)\n\n const heightUntilEnd =\n _totalHeight - (scrollTop + clientHeight) + props.hScrollbarSize\n\n if (\n unref(lastRenderedRowIndex) >= 0 &&\n _totalHeight === scrollTop + unref(mainTableHeight) - unref(headerHeight)\n ) {\n onEndReached(heightUntilEnd)\n }\n }\n\n // events\n\n watch(\n () => props.expandedRowKeys,\n (val) => (expandedRowKeys.value = val),\n {\n deep: true,\n }\n )\n\n return {\n // models\n columns,\n containerRef,\n mainTableRef,\n leftTableRef,\n rightTableRef,\n // states\n isDynamic,\n isResetting,\n isScrolling,\n hasFixedColumns,\n // records\n columnsStyles,\n columnsTotalWidth,\n data,\n expandedRowKeys,\n depthMap,\n fixedColumnsOnLeft,\n fixedColumnsOnRight,\n mainColumns,\n // metadata\n bodyWidth,\n emptyStyle,\n rootStyle,\n headerWidth,\n footerHeight,\n mainTableHeight,\n fixedTableHeight,\n leftTableWidth,\n rightTableWidth,\n // flags\n showEmpty,\n\n // methods\n getRowHeight,\n\n // event handlers\n onColumnSorted,\n onRowHovered,\n onRowExpanded,\n onRowsRendered,\n onRowHeightChange,\n // use scrollbars\n scrollTo,\n scrollToLeft,\n scrollToTop,\n scrollToRow,\n onScroll,\n onVerticalScroll,\n }\n}\n\nexport { useTable }\n\nexport type UseTableReturn = ReturnType<typeof useTable>\n"],"names":["ref","useColumns","toRef","useScrollbar","useNamespace","getCurrentInstance","shallowRef","useRow","useData","useStyles","computed","unref","isArray","watch"],"mappings":";;;;;;;;;;;;;;;;AAkBA,SAAS,QAAQ,CAAC,KAAK,EAAE;AACzB,EAAE,MAAM,YAAY,GAAGA,OAAG,EAAE,CAAC;AAC7B,EAAE,MAAM,YAAY,GAAGA,OAAG,EAAE,CAAC;AAC7B,EAAE,MAAM,aAAa,GAAGA,OAAG,EAAE,CAAC;AAC9B,EAAE,MAAM;AACR,IAAI,OAAO;AACX,IAAI,aAAa;AACjB,IAAI,iBAAiB;AACrB,IAAI,kBAAkB;AACtB,IAAI,mBAAmB;AACvB,IAAI,eAAe;AACnB,IAAI,WAAW;AACf,IAAI,cAAc;AAClB,GAAG,GAAGC,qBAAU,CAAC,KAAK,EAAEC,SAAK,CAAC,KAAK,EAAE,SAAS,CAAC,EAAEA,SAAK,CAAC,KAAK,EAAE,OAAO,CAAC,CAAC,CAAC;AACxE,EAAE,MAAM;AACR,IAAI,QAAQ;AACZ,IAAI,YAAY;AAChB,IAAI,WAAW;AACf,IAAI,WAAW;AACf,IAAI,QAAQ;AACZ,IAAI,gBAAgB;AACpB,IAAI,SAAS;AACb,GAAG,GAAGC,yBAAY,CAAC,KAAK,EAAE;AAC1B,IAAI,YAAY;AAChB,IAAI,YAAY;AAChB,IAAI,aAAa;AACjB,IAAI,iBAAiB;AACrB,GAAG,CAAC,CAAC;AACL,EAAE,MAAM,EAAE,GAAGC,kBAAY,CAAC,UAAU,CAAC,CAAC;AACtC,EAAE,MAAM,QAAQ,GAAGC,sBAAkB,EAAE,CAAC;AACxC,EAAE,MAAM,WAAW,GAAGC,cAAU,CAAC,KAAK,CAAC,CAAC;AACxC,EAAE,MAAM;AACR,IAAI,eAAe;AACnB,IAAI,oBAAoB;AACxB,IAAI,SAAS;AACb,IAAI,WAAW;AACf,IAAI,UAAU;AACd,IAAI,eAAe;AACnB,IAAI,aAAa;AACjB,IAAI,iBAAiB;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rB,IAAI,IAAI;AACR,IAAI,eAAe;AACnB,IAAI,QAAQ;AACZ,IAAI,kBAAkB;AACtB,IAAI,mBAAmB;AACvB,IAAI,WAAW;AACf,IAAI,SAAS;AACb,IAAI,UAAU;AACd,IAAI,SAAS;AACb,IAAI,WAAW;AACf,IAAI,YAAY;AAChB,IAAI,eAAe;AACnB,IAAI,gBAAgB;AACpB,IAAI,cAAc;AAClB,IAAI,eAAe;AACnB,IAAI,SAAS;AACb,IAAI,YAAY;AAChB,IAAI,cAAc;AAClB,IAAI,YAAY;AAChB,IAAI,aAAa;AACjB,IAAI,cAAc;AAClB,IAAI,iBAAiB;AACrB,IAAI,QAAQ;AACZ,IAAI,YAAY;AAChB,IAAI,WAAW;AACf,IAAI,WAAW;AACf,IAAI,QAAQ;AACZ,IAAI,gBAAgB;AACpB,GAAG,CAAC;AACJ;;;;"}
@@ -3,8 +3,8 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  require('../../utils/index.js');
6
- var tag$1 = require('./src/tag2.js');
7
- var tag = require('./src/tag.js');
6
+ var tag$1 = require('./src/tag.js');
7
+ var tag = require('./src/tag2.js');
8
8
  var install = require('../../utils/vue/install.js');
9
9
 
10
10
  const ElTag = install.withInstall(tag$1["default"]);
@@ -2,37 +2,101 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- require('../../../utils/index.js');
6
- require('../../../constants/index.js');
7
- var runtime = require('../../../utils/vue/props/runtime.js');
8
- var size = require('../../../constants/size.js');
5
+ var vue = require('vue');
6
+ var index$1 = require('../../icon/index.js');
7
+ var iconsVue = require('@element-plus/icons-vue');
8
+ require('../../../hooks/index.js');
9
+ require('../../form/index.js');
10
+ var tag = require('./tag2.js');
11
+ var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
12
+ var useFormCommonProps = require('../../form/src/hooks/use-form-common-props.js');
13
+ var index = require('../../../hooks/use-namespace/index.js');
9
14
 
10
- const tagProps = runtime.buildProps({
11
- type: {
12
- type: String,
13
- values: ["primary", "success", "info", "warning", "danger"],
14
- default: "primary"
15
- },
16
- closable: Boolean,
17
- disableTransitions: Boolean,
18
- hit: Boolean,
19
- color: String,
20
- size: {
21
- type: String,
22
- values: size.componentSizes
23
- },
24
- effect: {
25
- type: String,
26
- values: ["dark", "light", "plain"],
27
- default: "light"
28
- },
29
- round: Boolean
15
+ const __default__ = vue.defineComponent({
16
+ name: "ElTag"
30
17
  });
31
- const tagEmits = {
32
- close: (evt) => evt instanceof MouseEvent,
33
- click: (evt) => evt instanceof MouseEvent
34
- };
18
+ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
19
+ ...__default__,
20
+ props: tag.tagProps,
21
+ emits: tag.tagEmits,
22
+ setup(__props, { emit }) {
23
+ const props = __props;
24
+ const tagSize = useFormCommonProps.useFormSize();
25
+ const ns = index.useNamespace("tag");
26
+ const containerKls = vue.computed(() => {
27
+ const { type, hit, effect, closable, round } = props;
28
+ return [
29
+ ns.b(),
30
+ ns.is("closable", closable),
31
+ ns.m(type || "primary"),
32
+ ns.m(tagSize.value),
33
+ ns.m(effect),
34
+ ns.is("hit", hit),
35
+ ns.is("round", round)
36
+ ];
37
+ });
38
+ const handleClose = (event) => {
39
+ emit("close", event);
40
+ };
41
+ const handleClick = (event) => {
42
+ emit("click", event);
43
+ };
44
+ return (_ctx, _cache) => {
45
+ return _ctx.disableTransitions ? (vue.openBlock(), vue.createElementBlock("span", {
46
+ key: 0,
47
+ class: vue.normalizeClass(vue.unref(containerKls)),
48
+ style: vue.normalizeStyle({ backgroundColor: _ctx.color }),
49
+ onClick: handleClick
50
+ }, [
51
+ vue.createElementVNode("span", {
52
+ class: vue.normalizeClass(vue.unref(ns).e("content"))
53
+ }, [
54
+ vue.renderSlot(_ctx.$slots, "default")
55
+ ], 2),
56
+ _ctx.closable ? (vue.openBlock(), vue.createBlock(vue.unref(index$1.ElIcon), {
57
+ key: 0,
58
+ class: vue.normalizeClass(vue.unref(ns).e("close")),
59
+ onClick: vue.withModifiers(handleClose, ["stop"])
60
+ }, {
61
+ default: vue.withCtx(() => [
62
+ vue.createVNode(vue.unref(iconsVue.Close))
63
+ ]),
64
+ _: 1
65
+ }, 8, ["class", "onClick"])) : vue.createCommentVNode("v-if", true)
66
+ ], 6)) : (vue.openBlock(), vue.createBlock(vue.Transition, {
67
+ key: 1,
68
+ name: `${vue.unref(ns).namespace.value}-zoom-in-center`,
69
+ appear: ""
70
+ }, {
71
+ default: vue.withCtx(() => [
72
+ vue.createElementVNode("span", {
73
+ class: vue.normalizeClass(vue.unref(containerKls)),
74
+ style: vue.normalizeStyle({ backgroundColor: _ctx.color }),
75
+ onClick: handleClick
76
+ }, [
77
+ vue.createElementVNode("span", {
78
+ class: vue.normalizeClass(vue.unref(ns).e("content"))
79
+ }, [
80
+ vue.renderSlot(_ctx.$slots, "default")
81
+ ], 2),
82
+ _ctx.closable ? (vue.openBlock(), vue.createBlock(vue.unref(index$1.ElIcon), {
83
+ key: 0,
84
+ class: vue.normalizeClass(vue.unref(ns).e("close")),
85
+ onClick: vue.withModifiers(handleClose, ["stop"])
86
+ }, {
87
+ default: vue.withCtx(() => [
88
+ vue.createVNode(vue.unref(iconsVue.Close))
89
+ ]),
90
+ _: 1
91
+ }, 8, ["class", "onClick"])) : vue.createCommentVNode("v-if", true)
92
+ ], 6)
93
+ ]),
94
+ _: 3
95
+ }, 8, ["name"]));
96
+ };
97
+ }
98
+ });
99
+ var Tag = /* @__PURE__ */ pluginVue_exportHelper["default"](_sfc_main, [["__file", "tag.vue"]]);
35
100
 
36
- exports.tagEmits = tagEmits;
37
- exports.tagProps = tagProps;
101
+ exports["default"] = Tag;
38
102
  //# sourceMappingURL=tag.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"tag.js","sources":["../../../../../../packages/components/tag/src/tag.ts"],"sourcesContent":["import { buildProps } from '@element-plus/utils'\nimport { componentSizes } from '@element-plus/constants'\nimport type Tag from './tag.vue'\n\nimport type { ExtractPropTypes } from 'vue'\n\nexport const tagProps = buildProps({\n /**\n * @description type of Tag\n */\n type: {\n type: String,\n values: ['primary', 'success', 'info', 'warning', 'danger'],\n default: 'primary',\n },\n /**\n * @description whether Tag can be removed\n */\n closable: Boolean,\n /**\n * @description whether to disable animations\n */\n disableTransitions: Boolean,\n /**\n * @description whether Tag has a highlighted border\n */\n hit: Boolean,\n /**\n * @description background color of the Tag\n */\n color: String,\n /**\n * @description size of Tag\n */\n size: {\n type: String,\n values: componentSizes,\n },\n /**\n * @description theme of Tag\n */\n effect: {\n type: String,\n values: ['dark', 'light', 'plain'],\n default: 'light',\n },\n /**\n * @description whether Tag is rounded\n */\n round: Boolean,\n} as const)\nexport type TagProps = ExtractPropTypes<typeof tagProps>\n\nexport const tagEmits = {\n close: (evt: MouseEvent) => evt instanceof MouseEvent,\n click: (evt: MouseEvent) => evt instanceof MouseEvent,\n}\nexport type TagEmits = typeof tagEmits\n\nexport type TagInstance = InstanceType<typeof Tag>\n"],"names":["buildProps","componentSizes"],"mappings":";;;;;;;;;AAEY,MAAC,QAAQ,GAAGA,kBAAU,CAAC;AACnC,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAE,CAAC,SAAS,EAAE,SAAS,EAAE,MAAM,EAAE,SAAS,EAAE,QAAQ,CAAC;AAC/D,IAAI,OAAO,EAAE,SAAS;AACtB,GAAG;AACH,EAAE,QAAQ,EAAE,OAAO;AACnB,EAAE,kBAAkB,EAAE,OAAO;AAC7B,EAAE,GAAG,EAAE,OAAO;AACd,EAAE,KAAK,EAAE,MAAM;AACf,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAEC,mBAAc;AAC1B,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAE,CAAC,MAAM,EAAE,OAAO,EAAE,OAAO,CAAC;AACtC,IAAI,OAAO,EAAE,OAAO;AACpB,GAAG;AACH,EAAE,KAAK,EAAE,OAAO;AAChB,CAAC,EAAE;AACS,MAAC,QAAQ,GAAG;AACxB,EAAE,KAAK,EAAE,CAAC,GAAG,KAAK,GAAG,YAAY,UAAU;AAC3C,EAAE,KAAK,EAAE,CAAC,GAAG,KAAK,GAAG,YAAY,UAAU;AAC3C;;;;;"}
1
+ {"version":3,"file":"tag.js","sources":["../../../../../../packages/components/tag/src/tag.vue"],"sourcesContent":["<template>\n <span\n v-if=\"disableTransitions\"\n :class=\"containerKls\"\n :style=\"{ backgroundColor: color }\"\n @click=\"handleClick\"\n >\n <span :class=\"ns.e('content')\">\n <slot />\n </span>\n <el-icon v-if=\"closable\" :class=\"ns.e('close')\" @click.stop=\"handleClose\">\n <Close />\n </el-icon>\n </span>\n <transition v-else :name=\"`${ns.namespace.value}-zoom-in-center`\" appear>\n <span\n :class=\"containerKls\"\n :style=\"{ backgroundColor: color }\"\n @click=\"handleClick\"\n >\n <span :class=\"ns.e('content')\">\n <slot />\n </span>\n <el-icon v-if=\"closable\" :class=\"ns.e('close')\" @click.stop=\"handleClose\">\n <Close />\n </el-icon>\n </span>\n </transition>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed } from 'vue'\nimport ElIcon from '@element-plus/components/icon'\nimport { Close } from '@element-plus/icons-vue'\nimport { useNamespace } from '@element-plus/hooks'\nimport { useFormSize } from '@element-plus/components/form'\n\nimport { tagEmits, tagProps } from './tag'\n\ndefineOptions({\n name: 'ElTag',\n})\nconst props = defineProps(tagProps)\nconst emit = defineEmits(tagEmits)\n\nconst tagSize = useFormSize()\nconst ns = useNamespace('tag')\nconst containerKls = computed(() => {\n const { type, hit, effect, closable, round } = props\n return [\n ns.b(),\n ns.is('closable', closable),\n ns.m(type || 'primary'),\n ns.m(tagSize.value),\n ns.m(effect),\n ns.is('hit', hit),\n ns.is('round', round),\n ]\n})\n\n// methods\nconst handleClose = (event: MouseEvent) => {\n emit('close', event)\n}\n\nconst handleClick = (event: MouseEvent) => {\n emit('click', event)\n}\n</script>\n"],"names":["useFormSize","useNamespace","computed"],"mappings":";;;;;;;;;;;;;;uCAuCc,CAAA;AAAA,EACZ,IAAM,EAAA,OAAA;AACR,CAAA,CAAA,CAAA;;;;;;;AAIA,IAAA,MAAM,UAAUA,8BAAY,EAAA,CAAA;AAC5B,IAAM,MAAA,EAAA,GAAKC,mBAAa,KAAK,CAAA,CAAA;AAC7B,IAAM,MAAA,YAAA,GAAeC,aAAS,MAAM;AAClC,MAAA,MAAM,EAAE,IAAA,EAAM,GAAK,EAAA,MAAA,EAAQ,UAAU,KAAU,EAAA,GAAA,KAAA,CAAA;AAC/C,MAAO,OAAA;AAAA,QACL,GAAG,CAAE,EAAA;AAAA,QACL,EAAA,CAAG,EAAG,CAAA,UAAA,EAAY,QAAQ,CAAA;AAAA,QAC1B,EAAA,CAAG,CAAE,CAAA,IAAA,IAAQ,SAAS,CAAA;AAAA,QACtB,EAAA,CAAG,CAAE,CAAA,OAAA,CAAQ,KAAK,CAAA;AAAA,QAClB,EAAA,CAAG,EAAE,MAAM,CAAA;AAAA,QACX,EAAA,CAAG,EAAG,CAAA,KAAA,EAAO,GAAG,CAAA;AAAA,QAChB,EAAA,CAAG,EAAG,CAAA,OAAA,EAAS,KAAK,CAAA;AAAA,OACtB,CAAA;AAAA,KACD,CAAA,CAAA;AAGD,IAAM,MAAA,WAAA,GAAc,CAAC,KAAsB,KAAA;AACzC,MAAA,IAAA,CAAK,SAAS,KAAK,CAAA,CAAA;AAAA,KACrB,CAAA;AAEA,IAAM,MAAA,WAAA,GAAc,CAAC,KAAsB,KAAA;AACzC,MAAA,IAAA,CAAK,SAAS,KAAK,CAAA,CAAA;AAAA,KACrB,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -2,101 +2,37 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var vue = require('vue');
6
- var index$1 = require('../../icon/index.js');
7
- var iconsVue = require('@element-plus/icons-vue');
8
- require('../../../hooks/index.js');
9
- require('../../form/index.js');
10
- var tag = require('./tag.js');
11
- var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
12
- var useFormCommonProps = require('../../form/src/hooks/use-form-common-props.js');
13
- var index = require('../../../hooks/use-namespace/index.js');
5
+ require('../../../utils/index.js');
6
+ require('../../../constants/index.js');
7
+ var runtime = require('../../../utils/vue/props/runtime.js');
8
+ var size = require('../../../constants/size.js');
14
9
 
15
- const __default__ = vue.defineComponent({
16
- name: "ElTag"
10
+ const tagProps = runtime.buildProps({
11
+ type: {
12
+ type: String,
13
+ values: ["primary", "success", "info", "warning", "danger"],
14
+ default: "primary"
15
+ },
16
+ closable: Boolean,
17
+ disableTransitions: Boolean,
18
+ hit: Boolean,
19
+ color: String,
20
+ size: {
21
+ type: String,
22
+ values: size.componentSizes
23
+ },
24
+ effect: {
25
+ type: String,
26
+ values: ["dark", "light", "plain"],
27
+ default: "light"
28
+ },
29
+ round: Boolean
17
30
  });
18
- const _sfc_main = /* @__PURE__ */ vue.defineComponent({
19
- ...__default__,
20
- props: tag.tagProps,
21
- emits: tag.tagEmits,
22
- setup(__props, { emit }) {
23
- const props = __props;
24
- const tagSize = useFormCommonProps.useFormSize();
25
- const ns = index.useNamespace("tag");
26
- const containerKls = vue.computed(() => {
27
- const { type, hit, effect, closable, round } = props;
28
- return [
29
- ns.b(),
30
- ns.is("closable", closable),
31
- ns.m(type || "primary"),
32
- ns.m(tagSize.value),
33
- ns.m(effect),
34
- ns.is("hit", hit),
35
- ns.is("round", round)
36
- ];
37
- });
38
- const handleClose = (event) => {
39
- emit("close", event);
40
- };
41
- const handleClick = (event) => {
42
- emit("click", event);
43
- };
44
- return (_ctx, _cache) => {
45
- return _ctx.disableTransitions ? (vue.openBlock(), vue.createElementBlock("span", {
46
- key: 0,
47
- class: vue.normalizeClass(vue.unref(containerKls)),
48
- style: vue.normalizeStyle({ backgroundColor: _ctx.color }),
49
- onClick: handleClick
50
- }, [
51
- vue.createElementVNode("span", {
52
- class: vue.normalizeClass(vue.unref(ns).e("content"))
53
- }, [
54
- vue.renderSlot(_ctx.$slots, "default")
55
- ], 2),
56
- _ctx.closable ? (vue.openBlock(), vue.createBlock(vue.unref(index$1.ElIcon), {
57
- key: 0,
58
- class: vue.normalizeClass(vue.unref(ns).e("close")),
59
- onClick: vue.withModifiers(handleClose, ["stop"])
60
- }, {
61
- default: vue.withCtx(() => [
62
- vue.createVNode(vue.unref(iconsVue.Close))
63
- ]),
64
- _: 1
65
- }, 8, ["class", "onClick"])) : vue.createCommentVNode("v-if", true)
66
- ], 6)) : (vue.openBlock(), vue.createBlock(vue.Transition, {
67
- key: 1,
68
- name: `${vue.unref(ns).namespace.value}-zoom-in-center`,
69
- appear: ""
70
- }, {
71
- default: vue.withCtx(() => [
72
- vue.createElementVNode("span", {
73
- class: vue.normalizeClass(vue.unref(containerKls)),
74
- style: vue.normalizeStyle({ backgroundColor: _ctx.color }),
75
- onClick: handleClick
76
- }, [
77
- vue.createElementVNode("span", {
78
- class: vue.normalizeClass(vue.unref(ns).e("content"))
79
- }, [
80
- vue.renderSlot(_ctx.$slots, "default")
81
- ], 2),
82
- _ctx.closable ? (vue.openBlock(), vue.createBlock(vue.unref(index$1.ElIcon), {
83
- key: 0,
84
- class: vue.normalizeClass(vue.unref(ns).e("close")),
85
- onClick: vue.withModifiers(handleClose, ["stop"])
86
- }, {
87
- default: vue.withCtx(() => [
88
- vue.createVNode(vue.unref(iconsVue.Close))
89
- ]),
90
- _: 1
91
- }, 8, ["class", "onClick"])) : vue.createCommentVNode("v-if", true)
92
- ], 6)
93
- ]),
94
- _: 3
95
- }, 8, ["name"]));
96
- };
97
- }
98
- });
99
- var Tag = /* @__PURE__ */ pluginVue_exportHelper["default"](_sfc_main, [["__file", "tag.vue"]]);
31
+ const tagEmits = {
32
+ close: (evt) => evt instanceof MouseEvent,
33
+ click: (evt) => evt instanceof MouseEvent
34
+ };
100
35
 
101
- exports["default"] = Tag;
36
+ exports.tagEmits = tagEmits;
37
+ exports.tagProps = tagProps;
102
38
  //# sourceMappingURL=tag2.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"tag2.js","sources":["../../../../../../packages/components/tag/src/tag.vue"],"sourcesContent":["<template>\n <span\n v-if=\"disableTransitions\"\n :class=\"containerKls\"\n :style=\"{ backgroundColor: color }\"\n @click=\"handleClick\"\n >\n <span :class=\"ns.e('content')\">\n <slot />\n </span>\n <el-icon v-if=\"closable\" :class=\"ns.e('close')\" @click.stop=\"handleClose\">\n <Close />\n </el-icon>\n </span>\n <transition v-else :name=\"`${ns.namespace.value}-zoom-in-center`\" appear>\n <span\n :class=\"containerKls\"\n :style=\"{ backgroundColor: color }\"\n @click=\"handleClick\"\n >\n <span :class=\"ns.e('content')\">\n <slot />\n </span>\n <el-icon v-if=\"closable\" :class=\"ns.e('close')\" @click.stop=\"handleClose\">\n <Close />\n </el-icon>\n </span>\n </transition>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed } from 'vue'\nimport ElIcon from '@element-plus/components/icon'\nimport { Close } from '@element-plus/icons-vue'\nimport { useNamespace } from '@element-plus/hooks'\nimport { useFormSize } from '@element-plus/components/form'\n\nimport { tagEmits, tagProps } from './tag'\n\ndefineOptions({\n name: 'ElTag',\n})\nconst props = defineProps(tagProps)\nconst emit = defineEmits(tagEmits)\n\nconst tagSize = useFormSize()\nconst ns = useNamespace('tag')\nconst containerKls = computed(() => {\n const { type, hit, effect, closable, round } = props\n return [\n ns.b(),\n ns.is('closable', closable),\n ns.m(type || 'primary'),\n ns.m(tagSize.value),\n ns.m(effect),\n ns.is('hit', hit),\n ns.is('round', round),\n ]\n})\n\n// methods\nconst handleClose = (event: MouseEvent) => {\n emit('close', event)\n}\n\nconst handleClick = (event: MouseEvent) => {\n emit('click', event)\n}\n</script>\n"],"names":["useFormSize","useNamespace","computed"],"mappings":";;;;;;;;;;;;;;uCAuCc,CAAA;AAAA,EACZ,IAAM,EAAA,OAAA;AACR,CAAA,CAAA,CAAA;;;;;;;AAIA,IAAA,MAAM,UAAUA,8BAAY,EAAA,CAAA;AAC5B,IAAM,MAAA,EAAA,GAAKC,mBAAa,KAAK,CAAA,CAAA;AAC7B,IAAM,MAAA,YAAA,GAAeC,aAAS,MAAM;AAClC,MAAA,MAAM,EAAE,IAAA,EAAM,GAAK,EAAA,MAAA,EAAQ,UAAU,KAAU,EAAA,GAAA,KAAA,CAAA;AAC/C,MAAO,OAAA;AAAA,QACL,GAAG,CAAE,EAAA;AAAA,QACL,EAAA,CAAG,EAAG,CAAA,UAAA,EAAY,QAAQ,CAAA;AAAA,QAC1B,EAAA,CAAG,CAAE,CAAA,IAAA,IAAQ,SAAS,CAAA;AAAA,QACtB,EAAA,CAAG,CAAE,CAAA,OAAA,CAAQ,KAAK,CAAA;AAAA,QAClB,EAAA,CAAG,EAAE,MAAM,CAAA;AAAA,QACX,EAAA,CAAG,EAAG,CAAA,KAAA,EAAO,GAAG,CAAA;AAAA,QAChB,EAAA,CAAG,EAAG,CAAA,OAAA,EAAS,KAAK,CAAA;AAAA,OACtB,CAAA;AAAA,KACD,CAAA,CAAA;AAGD,IAAM,MAAA,WAAA,GAAc,CAAC,KAAsB,KAAA;AACzC,MAAA,IAAA,CAAK,SAAS,KAAK,CAAA,CAAA;AAAA,KACrB,CAAA;AAEA,IAAM,MAAA,WAAA,GAAc,CAAC,KAAsB,KAAA;AACzC,MAAA,IAAA,CAAK,SAAS,KAAK,CAAA,CAAA;AAAA,KACrB,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"tag2.js","sources":["../../../../../../packages/components/tag/src/tag.ts"],"sourcesContent":["import { buildProps } from '@element-plus/utils'\nimport { componentSizes } from '@element-plus/constants'\nimport type Tag from './tag.vue'\n\nimport type { ExtractPropTypes } from 'vue'\n\nexport const tagProps = buildProps({\n /**\n * @description type of Tag\n */\n type: {\n type: String,\n values: ['primary', 'success', 'info', 'warning', 'danger'],\n default: 'primary',\n },\n /**\n * @description whether Tag can be removed\n */\n closable: Boolean,\n /**\n * @description whether to disable animations\n */\n disableTransitions: Boolean,\n /**\n * @description whether Tag has a highlighted border\n */\n hit: Boolean,\n /**\n * @description background color of the Tag\n */\n color: String,\n /**\n * @description size of Tag\n */\n size: {\n type: String,\n values: componentSizes,\n },\n /**\n * @description theme of Tag\n */\n effect: {\n type: String,\n values: ['dark', 'light', 'plain'],\n default: 'light',\n },\n /**\n * @description whether Tag is rounded\n */\n round: Boolean,\n} as const)\nexport type TagProps = ExtractPropTypes<typeof tagProps>\n\nexport const tagEmits = {\n close: (evt: MouseEvent) => evt instanceof MouseEvent,\n click: (evt: MouseEvent) => evt instanceof MouseEvent,\n}\nexport type TagEmits = typeof tagEmits\n\nexport type TagInstance = InstanceType<typeof Tag>\n"],"names":["buildProps","componentSizes"],"mappings":";;;;;;;;;AAEY,MAAC,QAAQ,GAAGA,kBAAU,CAAC;AACnC,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAE,CAAC,SAAS,EAAE,SAAS,EAAE,MAAM,EAAE,SAAS,EAAE,QAAQ,CAAC;AAC/D,IAAI,OAAO,EAAE,SAAS;AACtB,GAAG;AACH,EAAE,QAAQ,EAAE,OAAO;AACnB,EAAE,kBAAkB,EAAE,OAAO;AAC7B,EAAE,GAAG,EAAE,OAAO;AACd,EAAE,KAAK,EAAE,MAAM;AACf,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAEC,mBAAc;AAC1B,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAE,CAAC,MAAM,EAAE,OAAO,EAAE,OAAO,CAAC;AACtC,IAAI,OAAO,EAAE,OAAO;AACpB,GAAG;AACH,EAAE,KAAK,EAAE,OAAO;AAChB,CAAC,EAAE;AACS,MAAC,QAAQ,GAAG;AACxB,EAAE,KAAK,EAAE,CAAC,GAAG,KAAK,GAAG,YAAY,UAAU;AAC3C,EAAE,KAAK,EAAE,CAAC,GAAG,KAAK,GAAG,YAAY,UAAU;AAC3C;;;;;"}
@@ -3,8 +3,8 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  require('../../utils/index.js');
6
- var text$1 = require('./src/text2.js');
7
- var text = require('./src/text.js');
6
+ var text$1 = require('./src/text.js');
7
+ var text = require('./src/text2.js');
8
8
  var install = require('../../utils/vue/install.js');
9
9
 
10
10
  const ElText = install.withInstall(text$1["default"]);
@@ -2,33 +2,47 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
+ var vue = require('vue');
6
+ require('../../../hooks/index.js');
7
+ require('../../form/index.js');
5
8
  require('../../../utils/index.js');
6
- require('../../../constants/index.js');
7
- var runtime = require('../../../utils/vue/props/runtime.js');
8
- var size = require('../../../constants/size.js');
9
+ var text = require('./text2.js');
10
+ var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
11
+ var useFormCommonProps = require('../../form/src/hooks/use-form-common-props.js');
12
+ var index = require('../../../hooks/use-namespace/index.js');
13
+ var types = require('../../../utils/types.js');
9
14
 
10
- const textProps = runtime.buildProps({
11
- type: {
12
- type: String,
13
- values: ["primary", "success", "info", "warning", "danger", ""],
14
- default: ""
15
- },
16
- size: {
17
- type: String,
18
- values: size.componentSizes,
19
- default: ""
20
- },
21
- truncated: {
22
- type: Boolean
23
- },
24
- lineClamp: {
25
- type: [String, Number]
26
- },
27
- tag: {
28
- type: String,
29
- default: "span"
15
+ const __default__ = vue.defineComponent({
16
+ name: "ElText"
17
+ });
18
+ const _sfc_main = /* @__PURE__ */ vue.defineComponent({
19
+ ...__default__,
20
+ props: text.textProps,
21
+ setup(__props) {
22
+ const props = __props;
23
+ const textSize = useFormCommonProps.useFormSize();
24
+ const ns = index.useNamespace("text");
25
+ const textKls = vue.computed(() => [
26
+ ns.b(),
27
+ ns.m(props.type),
28
+ ns.m(textSize.value),
29
+ ns.is("truncated", props.truncated),
30
+ ns.is("line-clamp", !types.isUndefined(props.lineClamp))
31
+ ]);
32
+ return (_ctx, _cache) => {
33
+ return vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.tag), {
34
+ class: vue.normalizeClass(vue.unref(textKls)),
35
+ style: vue.normalizeStyle({ "-webkit-line-clamp": _ctx.lineClamp })
36
+ }, {
37
+ default: vue.withCtx(() => [
38
+ vue.renderSlot(_ctx.$slots, "default")
39
+ ]),
40
+ _: 3
41
+ }, 8, ["class", "style"]);
42
+ };
30
43
  }
31
44
  });
45
+ var Text = /* @__PURE__ */ pluginVue_exportHelper["default"](_sfc_main, [["__file", "text.vue"]]);
32
46
 
33
- exports.textProps = textProps;
47
+ exports["default"] = Text;
34
48
  //# sourceMappingURL=text.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"text.js","sources":["../../../../../../packages/components/text/src/text.ts"],"sourcesContent":["import { buildProps } from '@element-plus/utils'\nimport { componentSizes } from '@element-plus/constants'\n\nimport type { ExtractPropTypes } from 'vue'\n\nexport const textProps = buildProps({\n /**\n * @description text type\n */\n type: {\n type: String,\n values: ['primary', 'success', 'info', 'warning', 'danger', ''],\n default: '',\n },\n /**\n * @description text size\n */\n size: {\n type: String,\n values: componentSizes,\n default: '',\n },\n /**\n * @description render ellipsis\n */\n truncated: {\n type: Boolean,\n },\n /**\n * @description maximum lines\n */\n lineClamp: {\n type: [String, Number],\n },\n /**\n * @description custom element tag\n */\n tag: {\n type: String,\n default: 'span',\n },\n} as const)\n\nexport type TextProps = ExtractPropTypes<typeof textProps>\n"],"names":["buildProps","componentSizes"],"mappings":";;;;;;;;;AAEY,MAAC,SAAS,GAAGA,kBAAU,CAAC;AACpC,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAE,CAAC,SAAS,EAAE,SAAS,EAAE,MAAM,EAAE,SAAS,EAAE,QAAQ,EAAE,EAAE,CAAC;AACnE,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAEC,mBAAc;AAC1B,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,OAAO;AACjB,GAAG;AACH,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;AAC1B,GAAG;AACH,EAAE,GAAG,EAAE;AACP,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,MAAM;AACnB,GAAG;AACH,CAAC;;;;"}
1
+ {"version":3,"file":"text.js","sources":["../../../../../../packages/components/text/src/text.vue"],"sourcesContent":["<template>\n <component\n :is=\"tag\"\n :class=\"textKls\"\n :style=\"{ '-webkit-line-clamp': lineClamp }\"\n >\n <slot />\n </component>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed } from 'vue'\nimport { useNamespace } from '@element-plus/hooks'\nimport { useFormSize } from '@element-plus/components/form'\nimport { isUndefined } from '@element-plus/utils'\nimport { textProps } from './text'\n\ndefineOptions({\n name: 'ElText',\n})\n\nconst props = defineProps(textProps)\n\nconst textSize = useFormSize()\nconst ns = useNamespace('text')\n\nconst textKls = computed(() => [\n ns.b(),\n ns.m(props.type),\n ns.m(textSize.value),\n ns.is('truncated', props.truncated),\n ns.is('line-clamp', !isUndefined(props.lineClamp)),\n])\n</script>\n"],"names":["useFormSize","useNamespace","computed","isUndefined"],"mappings":";;;;;;;;;;;;;;uCAiBc,CAAA;AAAA,EACZ,IAAM,EAAA,QAAA;AACR,CAAA,CAAA,CAAA;;;;;;AAIA,IAAA,MAAM,WAAWA,8BAAY,EAAA,CAAA;AAC7B,IAAM,MAAA,EAAA,GAAKC,mBAAa,MAAM,CAAA,CAAA;AAE9B,IAAM,MAAA,OAAA,GAAUC,aAAS,MAAM;AAAA,MAC7B,GAAG,CAAE,EAAA;AAAA,MACL,EAAA,CAAG,CAAE,CAAA,KAAA,CAAM,IAAI,CAAA;AAAA,MACf,EAAA,CAAG,CAAE,CAAA,QAAA,CAAS,KAAK,CAAA;AAAA,MACnB,EAAG,CAAA,EAAA,CAAG,WAAa,EAAA,KAAA,CAAM,SAAS,CAAA;AAAA,MAClC,GAAG,EAAG,CAAA,YAAA,EAAc,CAACC,iBAAY,CAAA,KAAA,CAAM,SAAS,CAAC,CAAA;AAAA,KAClD,CAAA,CAAA;;;;;;;;;;;;;;;;;;"}
@@ -2,47 +2,33 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var vue = require('vue');
6
- require('../../../hooks/index.js');
7
- require('../../form/index.js');
8
5
  require('../../../utils/index.js');
9
- var text = require('./text.js');
10
- var pluginVue_exportHelper = require('../../../_virtual/plugin-vue_export-helper.js');
11
- var useFormCommonProps = require('../../form/src/hooks/use-form-common-props.js');
12
- var index = require('../../../hooks/use-namespace/index.js');
13
- var types = require('../../../utils/types.js');
6
+ require('../../../constants/index.js');
7
+ var runtime = require('../../../utils/vue/props/runtime.js');
8
+ var size = require('../../../constants/size.js');
14
9
 
15
- const __default__ = vue.defineComponent({
16
- name: "ElText"
17
- });
18
- const _sfc_main = /* @__PURE__ */ vue.defineComponent({
19
- ...__default__,
20
- props: text.textProps,
21
- setup(__props) {
22
- const props = __props;
23
- const textSize = useFormCommonProps.useFormSize();
24
- const ns = index.useNamespace("text");
25
- const textKls = vue.computed(() => [
26
- ns.b(),
27
- ns.m(props.type),
28
- ns.m(textSize.value),
29
- ns.is("truncated", props.truncated),
30
- ns.is("line-clamp", !types.isUndefined(props.lineClamp))
31
- ]);
32
- return (_ctx, _cache) => {
33
- return vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.tag), {
34
- class: vue.normalizeClass(vue.unref(textKls)),
35
- style: vue.normalizeStyle({ "-webkit-line-clamp": _ctx.lineClamp })
36
- }, {
37
- default: vue.withCtx(() => [
38
- vue.renderSlot(_ctx.$slots, "default")
39
- ]),
40
- _: 3
41
- }, 8, ["class", "style"]);
42
- };
10
+ const textProps = runtime.buildProps({
11
+ type: {
12
+ type: String,
13
+ values: ["primary", "success", "info", "warning", "danger", ""],
14
+ default: ""
15
+ },
16
+ size: {
17
+ type: String,
18
+ values: size.componentSizes,
19
+ default: ""
20
+ },
21
+ truncated: {
22
+ type: Boolean
23
+ },
24
+ lineClamp: {
25
+ type: [String, Number]
26
+ },
27
+ tag: {
28
+ type: String,
29
+ default: "span"
43
30
  }
44
31
  });
45
- var Text = /* @__PURE__ */ pluginVue_exportHelper["default"](_sfc_main, [["__file", "text.vue"]]);
46
32
 
47
- exports["default"] = Text;
33
+ exports.textProps = textProps;
48
34
  //# sourceMappingURL=text2.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"text2.js","sources":["../../../../../../packages/components/text/src/text.vue"],"sourcesContent":["<template>\n <component\n :is=\"tag\"\n :class=\"textKls\"\n :style=\"{ '-webkit-line-clamp': lineClamp }\"\n >\n <slot />\n </component>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed } from 'vue'\nimport { useNamespace } from '@element-plus/hooks'\nimport { useFormSize } from '@element-plus/components/form'\nimport { isUndefined } from '@element-plus/utils'\nimport { textProps } from './text'\n\ndefineOptions({\n name: 'ElText',\n})\n\nconst props = defineProps(textProps)\n\nconst textSize = useFormSize()\nconst ns = useNamespace('text')\n\nconst textKls = computed(() => [\n ns.b(),\n ns.m(props.type),\n ns.m(textSize.value),\n ns.is('truncated', props.truncated),\n ns.is('line-clamp', !isUndefined(props.lineClamp)),\n])\n</script>\n"],"names":["useFormSize","useNamespace","computed","isUndefined"],"mappings":";;;;;;;;;;;;;;uCAiBc,CAAA;AAAA,EACZ,IAAM,EAAA,QAAA;AACR,CAAA,CAAA,CAAA;;;;;;AAIA,IAAA,MAAM,WAAWA,8BAAY,EAAA,CAAA;AAC7B,IAAM,MAAA,EAAA,GAAKC,mBAAa,MAAM,CAAA,CAAA;AAE9B,IAAM,MAAA,OAAA,GAAUC,aAAS,MAAM;AAAA,MAC7B,GAAG,CAAE,EAAA;AAAA,MACL,EAAA,CAAG,CAAE,CAAA,KAAA,CAAM,IAAI,CAAA;AAAA,MACf,EAAA,CAAG,CAAE,CAAA,QAAA,CAAS,KAAK,CAAA;AAAA,MACnB,EAAG,CAAA,EAAA,CAAG,WAAa,EAAA,KAAA,CAAM,SAAS,CAAA;AAAA,MAClC,GAAG,EAAG,CAAA,YAAA,EAAc,CAACC,iBAAY,CAAA,KAAA,CAAM,SAAS,CAAC,CAAA;AAAA,KAClD,CAAA,CAAA;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"text2.js","sources":["../../../../../../packages/components/text/src/text.ts"],"sourcesContent":["import { buildProps } from '@element-plus/utils'\nimport { componentSizes } from '@element-plus/constants'\n\nimport type { ExtractPropTypes } from 'vue'\n\nexport const textProps = buildProps({\n /**\n * @description text type\n */\n type: {\n type: String,\n values: ['primary', 'success', 'info', 'warning', 'danger', ''],\n default: '',\n },\n /**\n * @description text size\n */\n size: {\n type: String,\n values: componentSizes,\n default: '',\n },\n /**\n * @description render ellipsis\n */\n truncated: {\n type: Boolean,\n },\n /**\n * @description maximum lines\n */\n lineClamp: {\n type: [String, Number],\n },\n /**\n * @description custom element tag\n */\n tag: {\n type: String,\n default: 'span',\n },\n} as const)\n\nexport type TextProps = ExtractPropTypes<typeof textProps>\n"],"names":["buildProps","componentSizes"],"mappings":";;;;;;;;;AAEY,MAAC,SAAS,GAAGA,kBAAU,CAAC;AACpC,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAE,CAAC,SAAS,EAAE,SAAS,EAAE,MAAM,EAAE,SAAS,EAAE,QAAQ,EAAE,EAAE,CAAC;AACnE,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAEC,mBAAc;AAC1B,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,OAAO;AACjB,GAAG;AACH,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;AAC1B,GAAG;AACH,EAAE,GAAG,EAAE;AACP,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,MAAM;AACnB,GAAG;AACH,CAAC;;;;"}
@@ -626,6 +626,7 @@ export declare const ElTour: import("@element-plus/nightly/es/utils").SFCWithIns
626
626
  }>;
627
627
  shouldAddSpace: import("vue").ComputedRef<boolean>;
628
628
  handleClick: (evt: MouseEvent) => void;
629
+ buttonKls: import("vue").ComputedRef<string[]>;
629
630
  ElIcon: import("@element-plus/nightly/es/utils").SFCWithInstall<import("vue").DefineComponent<{
630
631
  readonly size: {
631
632
  readonly type: import("vue").PropType<import("@element-plus/nightly/es/utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;
@@ -1145,6 +1146,7 @@ export declare const ElTourStep: import("@element-plus/nightly/es/utils").SFCWit
1145
1146
  }>;
1146
1147
  shouldAddSpace: import("vue").ComputedRef<boolean>;
1147
1148
  handleClick: (evt: MouseEvent) => void;
1149
+ buttonKls: import("vue").ComputedRef<string[]>;
1148
1150
  ElIcon: import("@element-plus/nightly/es/utils").SFCWithInstall<import("vue").DefineComponent<{
1149
1151
  readonly size: {
1150
1152
  readonly type: import("vue").PropType<import("@element-plus/nightly/es/utils").EpPropMergeType<(new (...args: any[]) => (string | number) & {}) | (() => string | number) | ((new (...args: any[]) => (string | number) & {}) | (() => string | number))[], unknown, unknown>>;