element-plus 2.5.0 → 2.5.1

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 (356) hide show
  1. package/dist/index.full.js +46 -37
  2. package/dist/index.full.min.js +11 -11
  3. package/dist/index.full.min.js.map +1 -1
  4. package/dist/index.full.min.mjs +11 -11
  5. package/dist/index.full.min.mjs.map +1 -1
  6. package/dist/index.full.mjs +46 -37
  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/collection/index.mjs +1 -1
  244. package/es/components/collection/src/collection.mjs +62 -10
  245. package/es/components/collection/src/collection.mjs.map +1 -1
  246. package/es/components/collection/src/collection2.mjs +10 -62
  247. package/es/components/collection/src/collection2.mjs.map +1 -1
  248. package/es/components/color-picker/index.mjs +2 -2
  249. package/es/components/color-picker/src/color-picker.mjs +402 -40
  250. package/es/components/color-picker/src/color-picker.mjs.map +1 -1
  251. package/es/components/color-picker/src/color-picker2.mjs +40 -402
  252. package/es/components/color-picker/src/color-picker2.mjs.map +1 -1
  253. package/es/components/color-picker/src/components/predefine.mjs +1 -1
  254. package/es/components/countdown/index.mjs +2 -2
  255. package/es/components/countdown/src/countdown.mjs +23 -74
  256. package/es/components/countdown/src/countdown.mjs.map +1 -1
  257. package/es/components/countdown/src/countdown2.mjs +74 -23
  258. package/es/components/countdown/src/countdown2.mjs.map +1 -1
  259. package/es/components/descriptions/index.mjs +2 -2
  260. package/es/components/descriptions/src/description.mjs +25 -112
  261. package/es/components/descriptions/src/description.mjs.map +1 -1
  262. package/es/components/descriptions/src/description2.mjs +112 -25
  263. package/es/components/descriptions/src/description2.mjs.map +1 -1
  264. package/es/components/dialog/src/dialog-content.mjs +29 -89
  265. package/es/components/dialog/src/dialog-content.mjs.map +1 -1
  266. package/es/components/dialog/src/dialog-content2.mjs +89 -29
  267. package/es/components/dialog/src/dialog-content2.mjs.map +1 -1
  268. package/es/components/dialog/src/dialog.mjs +1 -1
  269. package/es/components/dialog/src/dialog2.mjs +1 -1
  270. package/es/components/dropdown/src/dropdown-item-impl.mjs +1 -1
  271. package/es/components/dropdown/src/dropdown.mjs +1 -1
  272. package/es/components/form/index.mjs +2 -2
  273. package/es/components/form/src/form.mjs +152 -54
  274. package/es/components/form/src/form.mjs.map +1 -1
  275. package/es/components/form/src/form2.mjs +54 -152
  276. package/es/components/form/src/form2.mjs.map +1 -1
  277. package/es/components/index.mjs +5 -5
  278. package/es/components/pagination/src/components/sizes.mjs +69 -23
  279. package/es/components/pagination/src/components/sizes.mjs.map +1 -1
  280. package/es/components/pagination/src/components/sizes2.mjs +23 -69
  281. package/es/components/pagination/src/components/sizes2.mjs.map +1 -1
  282. package/es/components/pagination/src/pagination.mjs +1 -1
  283. package/es/components/roving-focus-group/src/roving-focus-group.mjs +1 -1
  284. package/es/components/select/src/select2.mjs +25 -24
  285. package/es/components/select/src/select2.mjs.map +1 -1
  286. package/es/components/select/src/useSelect.mjs +15 -9
  287. package/es/components/select/src/useSelect.mjs.map +1 -1
  288. package/es/components/select-v2/src/select.mjs +7 -5
  289. package/es/components/select-v2/src/select.mjs.map +1 -1
  290. package/es/components/steps/index.mjs +2 -2
  291. package/es/components/steps/src/item.mjs +191 -19
  292. package/es/components/steps/src/item.mjs.map +1 -1
  293. package/es/components/steps/src/item2.mjs +19 -191
  294. package/es/components/steps/src/item2.mjs.map +1 -1
  295. package/es/index.mjs +5 -5
  296. package/es/version.d.ts +1 -1
  297. package/es/version.mjs +1 -1
  298. package/es/version.mjs.map +1 -1
  299. package/lib/components/collection/index.js +1 -1
  300. package/lib/components/collection/src/collection.js +62 -9
  301. package/lib/components/collection/src/collection.js.map +1 -1
  302. package/lib/components/collection/src/collection2.js +9 -62
  303. package/lib/components/collection/src/collection2.js.map +1 -1
  304. package/lib/components/color-picker/index.js +2 -2
  305. package/lib/components/color-picker/src/color-picker.js +400 -40
  306. package/lib/components/color-picker/src/color-picker.js.map +1 -1
  307. package/lib/components/color-picker/src/color-picker2.js +40 -400
  308. package/lib/components/color-picker/src/color-picker2.js.map +1 -1
  309. package/lib/components/color-picker/src/components/predefine.js +1 -1
  310. package/lib/components/countdown/index.js +2 -2
  311. package/lib/components/countdown/src/countdown.js +24 -74
  312. package/lib/components/countdown/src/countdown.js.map +1 -1
  313. package/lib/components/countdown/src/countdown2.js +74 -24
  314. package/lib/components/countdown/src/countdown2.js.map +1 -1
  315. package/lib/components/descriptions/index.js +2 -2
  316. package/lib/components/descriptions/src/description.js +25 -112
  317. package/lib/components/descriptions/src/description.js.map +1 -1
  318. package/lib/components/descriptions/src/description2.js +112 -25
  319. package/lib/components/descriptions/src/description2.js.map +1 -1
  320. package/lib/components/dialog/src/dialog-content.js +29 -88
  321. package/lib/components/dialog/src/dialog-content.js.map +1 -1
  322. package/lib/components/dialog/src/dialog-content2.js +88 -29
  323. package/lib/components/dialog/src/dialog-content2.js.map +1 -1
  324. package/lib/components/dialog/src/dialog.js +1 -1
  325. package/lib/components/dialog/src/dialog2.js +1 -1
  326. package/lib/components/dropdown/src/dropdown-item-impl.js +1 -1
  327. package/lib/components/dropdown/src/dropdown.js +1 -1
  328. package/lib/components/form/index.js +2 -2
  329. package/lib/components/form/src/form.js +151 -54
  330. package/lib/components/form/src/form.js.map +1 -1
  331. package/lib/components/form/src/form2.js +54 -151
  332. package/lib/components/form/src/form2.js.map +1 -1
  333. package/lib/components/index.js +5 -5
  334. package/lib/components/pagination/src/components/sizes.js +69 -23
  335. package/lib/components/pagination/src/components/sizes.js.map +1 -1
  336. package/lib/components/pagination/src/components/sizes2.js +23 -69
  337. package/lib/components/pagination/src/components/sizes2.js.map +1 -1
  338. package/lib/components/pagination/src/pagination.js +1 -1
  339. package/lib/components/roving-focus-group/src/roving-focus-group.js +1 -1
  340. package/lib/components/select/src/select2.js +24 -23
  341. package/lib/components/select/src/select2.js.map +1 -1
  342. package/lib/components/select/src/useSelect.js +13 -7
  343. package/lib/components/select/src/useSelect.js.map +1 -1
  344. package/lib/components/select-v2/src/select.js +7 -5
  345. package/lib/components/select-v2/src/select.js.map +1 -1
  346. package/lib/components/steps/index.js +2 -2
  347. package/lib/components/steps/src/item.js +191 -19
  348. package/lib/components/steps/src/item.js.map +1 -1
  349. package/lib/components/steps/src/item2.js +19 -191
  350. package/lib/components/steps/src/item2.js.map +1 -1
  351. package/lib/index.js +5 -5
  352. package/lib/version.d.ts +1 -1
  353. package/lib/version.js +1 -1
  354. package/lib/version.js.map +1 -1
  355. package/package.json +2 -2
  356. package/web-types.json +1 -1
@@ -1,95 +1,35 @@
1
- import { defineComponent, inject, computed, openBlock, createElementBlock, unref, normalizeClass, normalizeStyle, createElementVNode, renderSlot, toDisplayString, createVNode, withCtx, createBlock, resolveDynamicComponent, createCommentVNode } from 'vue';
2
- import { ElIcon } from '../../icon/index.mjs';
3
- import '../../focus-trap/index.mjs';
4
- import '../../../hooks/index.mjs';
5
1
  import '../../../utils/index.mjs';
6
- import { dialogInjectionKey } from './constants.mjs';
7
- import { dialogContentProps, dialogContentEmits } from './dialog-content2.mjs';
8
- import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
9
- import { useLocale } from '../../../hooks/use-locale/index.mjs';
10
- import { CloseComponents } from '../../../utils/vue/icon.mjs';
11
- import { FOCUS_TRAP_INJECTION_KEY } from '../../focus-trap/src/tokens.mjs';
12
- import { composeRefs } from '../../../utils/vue/refs.mjs';
13
- import { useDraggable } from '../../../hooks/use-draggable/index.mjs';
2
+ import { buildProps } from '../../../utils/vue/props/runtime.mjs';
3
+ import { iconPropType } from '../../../utils/vue/icon.mjs';
14
4
 
15
- const _hoisted_1 = ["aria-level"];
16
- const _hoisted_2 = ["aria-label"];
17
- const _hoisted_3 = ["id"];
18
- const __default__ = defineComponent({ name: "ElDialogContent" });
19
- const _sfc_main = /* @__PURE__ */ defineComponent({
20
- ...__default__,
21
- props: dialogContentProps,
22
- emits: dialogContentEmits,
23
- setup(__props) {
24
- const props = __props;
25
- const { t } = useLocale();
26
- const { Close } = CloseComponents;
27
- const { dialogRef, headerRef, bodyId, ns, style } = inject(dialogInjectionKey);
28
- const { focusTrapRef } = inject(FOCUS_TRAP_INJECTION_KEY);
29
- const dialogKls = computed(() => [
30
- ns.b(),
31
- ns.is("fullscreen", props.fullscreen),
32
- ns.is("draggable", props.draggable),
33
- ns.is("align-center", props.alignCenter),
34
- { [ns.m("center")]: props.center },
35
- props.customClass
36
- ]);
37
- const composedDialogRef = composeRefs(focusTrapRef, dialogRef);
38
- const draggable = computed(() => props.draggable);
39
- useDraggable(dialogRef, headerRef, draggable);
40
- return (_ctx, _cache) => {
41
- return openBlock(), createElementBlock("div", {
42
- ref: unref(composedDialogRef),
43
- class: normalizeClass(unref(dialogKls)),
44
- style: normalizeStyle(unref(style)),
45
- tabindex: "-1"
46
- }, [
47
- createElementVNode("header", {
48
- ref_key: "headerRef",
49
- ref: headerRef,
50
- class: normalizeClass(unref(ns).e("header"))
51
- }, [
52
- renderSlot(_ctx.$slots, "header", {}, () => [
53
- createElementVNode("span", {
54
- role: "heading",
55
- "aria-level": _ctx.ariaLevel,
56
- class: normalizeClass(unref(ns).e("title"))
57
- }, toDisplayString(_ctx.title), 11, _hoisted_1)
58
- ]),
59
- _ctx.showClose ? (openBlock(), createElementBlock("button", {
60
- key: 0,
61
- "aria-label": unref(t)("el.dialog.close"),
62
- class: normalizeClass(unref(ns).e("headerbtn")),
63
- type: "button",
64
- onClick: _cache[0] || (_cache[0] = ($event) => _ctx.$emit("close"))
65
- }, [
66
- createVNode(unref(ElIcon), {
67
- class: normalizeClass(unref(ns).e("close"))
68
- }, {
69
- default: withCtx(() => [
70
- (openBlock(), createBlock(resolveDynamicComponent(_ctx.closeIcon || unref(Close))))
71
- ]),
72
- _: 1
73
- }, 8, ["class"])
74
- ], 10, _hoisted_2)) : createCommentVNode("v-if", true)
75
- ], 2),
76
- createElementVNode("div", {
77
- id: unref(bodyId),
78
- class: normalizeClass(unref(ns).e("body"))
79
- }, [
80
- renderSlot(_ctx.$slots, "default")
81
- ], 10, _hoisted_3),
82
- _ctx.$slots.footer ? (openBlock(), createElementBlock("footer", {
83
- key: 0,
84
- class: normalizeClass(unref(ns).e("footer"))
85
- }, [
86
- renderSlot(_ctx.$slots, "footer")
87
- ], 2)) : createCommentVNode("v-if", true)
88
- ], 6);
89
- };
5
+ const dialogContentProps = buildProps({
6
+ center: Boolean,
7
+ alignCenter: Boolean,
8
+ closeIcon: {
9
+ type: iconPropType
10
+ },
11
+ customClass: {
12
+ type: String,
13
+ default: ""
14
+ },
15
+ draggable: Boolean,
16
+ fullscreen: Boolean,
17
+ showClose: {
18
+ type: Boolean,
19
+ default: true
20
+ },
21
+ title: {
22
+ type: String,
23
+ default: ""
24
+ },
25
+ ariaLevel: {
26
+ type: String,
27
+ default: "2"
90
28
  }
91
29
  });
92
- var ElDialogContent = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "dialog-content.vue"]]);
30
+ const dialogContentEmits = {
31
+ close: () => true
32
+ };
93
33
 
94
- export { ElDialogContent as default };
34
+ export { dialogContentEmits, dialogContentProps };
95
35
  //# sourceMappingURL=dialog-content.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"dialog-content.mjs","sources":["../../../../../../packages/components/dialog/src/dialog-content.vue"],"sourcesContent":["<template>\n <div :ref=\"composedDialogRef\" :class=\"dialogKls\" :style=\"style\" tabindex=\"-1\">\n <header ref=\"headerRef\" :class=\"ns.e('header')\">\n <slot name=\"header\">\n <span role=\"heading\" :aria-level=\"ariaLevel\" :class=\"ns.e('title')\">\n {{ title }}\n </span>\n </slot>\n <button\n v-if=\"showClose\"\n :aria-label=\"t('el.dialog.close')\"\n :class=\"ns.e('headerbtn')\"\n type=\"button\"\n @click=\"$emit('close')\"\n >\n <el-icon :class=\"ns.e('close')\">\n <component :is=\"closeIcon || Close\" />\n </el-icon>\n </button>\n </header>\n <div :id=\"bodyId\" :class=\"ns.e('body')\">\n <slot />\n </div>\n <footer v-if=\"$slots.footer\" :class=\"ns.e('footer')\">\n <slot name=\"footer\" />\n </footer>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed, inject } from 'vue'\nimport { ElIcon } from '@element-plus/components/icon'\nimport { FOCUS_TRAP_INJECTION_KEY } from '@element-plus/components/focus-trap'\nimport { useDraggable, useLocale } from '@element-plus/hooks'\nimport { CloseComponents, composeRefs } from '@element-plus/utils'\nimport { dialogInjectionKey } from './constants'\nimport { dialogContentEmits, dialogContentProps } from './dialog-content'\n\nconst { t } = useLocale()\nconst { Close } = CloseComponents\n\ndefineOptions({ name: 'ElDialogContent' })\nconst props = defineProps(dialogContentProps)\ndefineEmits(dialogContentEmits)\n\nconst { dialogRef, headerRef, bodyId, ns, style } = inject(dialogInjectionKey)!\nconst { focusTrapRef } = inject(FOCUS_TRAP_INJECTION_KEY)!\n\nconst dialogKls = computed(() => [\n ns.b(),\n ns.is('fullscreen', props.fullscreen),\n ns.is('draggable', props.draggable),\n ns.is('align-center', props.alignCenter),\n { [ns.m('center')]: props.center },\n props.customClass,\n])\n\nconst composedDialogRef = composeRefs(focusTrapRef, dialogRef)\n\nconst draggable = computed(() => props.draggable)\nuseDraggable(dialogRef, headerRef, draggable)\n</script>\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;mCAyCc,CAAA,EAAE,IAAM,EAAA,iBAAA,EAAkB,CAAA,CAAA;;;;;;;AAHxC,IAAM,MAAA,EAAE,MAAM,SAAU,EAAA,CAAA;AACxB,IAAA,MAAM,EAAE,KAAU,EAAA,GAAA,eAAA,CAAA;AAMlB,IAAA,MAAM,EAAE,SAAW,EAAA,SAAA,EAAW,QAAQ,EAAI,EAAA,KAAA,EAAA,GAAU,OAAO,kBAAkB,CAAA,CAAA;AAC7E,IAAM,MAAA,EAAE,YAAiB,EAAA,GAAA,MAAA,CAAO,wBAAwB,CAAA,CAAA;AAExD,IAAM,MAAA,SAAA,GAAY,SAAS,MAAM;AAAA,MAC/B,GAAG,CAAE,EAAA;AAAA,MACL,EAAG,CAAA,EAAA,CAAG,YAAc,EAAA,KAAA,CAAM,UAAU,CAAA;AAAA,MACpC,EAAG,CAAA,EAAA,CAAG,WAAa,EAAA,KAAA,CAAM,SAAS,CAAA;AAAA,MAClC,EAAG,CAAA,EAAA,CAAG,cAAgB,EAAA,KAAA,CAAM,WAAW,CAAA;AAAA,MACvC,EAAE,CAAC,EAAA,CAAG,EAAE,QAAQ,CAAA,GAAI,MAAM,MAAO,EAAA;AAAA,MACjC,KAAM,CAAA,WAAA;AAAA,KACP,CAAA,CAAA;AAED,IAAM,MAAA,iBAAA,GAAoB,WAAY,CAAA,YAAA,EAAc,SAAS,CAAA,CAAA;AAE7D,IAAA,MAAM,SAAY,GAAA,QAAA,CAAS,MAAM,KAAA,CAAM,SAAS,CAAA,CAAA;AAChD,IAAa,YAAA,CAAA,SAAA,EAAW,WAAW,SAAS,CAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"dialog-content.mjs","sources":["../../../../../../packages/components/dialog/src/dialog-content.ts"],"sourcesContent":["import { buildProps, iconPropType } from '@element-plus/utils'\n\nexport const dialogContentProps = buildProps({\n /**\n * @description whether to align the header and footer in center\n */\n center: Boolean,\n /**\n * @description whether to align the dialog both horizontally and vertically\n */\n alignCenter: Boolean,\n /**\n * @description custom close icon, default is Close\n */\n closeIcon: {\n type: iconPropType,\n },\n /**\n * @deprecated will be removed in version 2.4.0, please use class\n */\n customClass: {\n type: String,\n default: '',\n },\n /**\n * @description enable dragging feature for Dialog\n */\n draggable: Boolean,\n /**\n * @description whether the Dialog takes up full screen\n */\n fullscreen: Boolean,\n /**\n * @description whether to show a close button\n */\n showClose: {\n type: Boolean,\n default: true,\n },\n /**\n * @description title of Dialog. Can also be passed with a named slot (see the following table)\n */\n title: {\n type: String,\n default: '',\n },\n /**\n * @description header's aria-level attribute\n */\n ariaLevel: {\n type: String,\n default: '2',\n },\n} as const)\n\nexport const dialogContentEmits = {\n close: () => true,\n}\n"],"names":[],"mappings":";;;;AACY,MAAC,kBAAkB,GAAG,UAAU,CAAC;AAC7C,EAAE,MAAM,EAAE,OAAO;AACjB,EAAE,WAAW,EAAE,OAAO;AACtB,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,YAAY;AACtB,GAAG;AACH,EAAE,WAAW,EAAE;AACf,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,SAAS,EAAE,OAAO;AACpB,EAAE,UAAU,EAAE,OAAO;AACrB,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,IAAI;AACjB,GAAG;AACH,EAAE,KAAK,EAAE;AACT,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,GAAG;AAChB,GAAG;AACH,CAAC,EAAE;AACS,MAAC,kBAAkB,GAAG;AAClC,EAAE,KAAK,EAAE,MAAM,IAAI;AACnB;;;;"}
@@ -1,35 +1,95 @@
1
+ import { defineComponent, inject, computed, openBlock, createElementBlock, unref, normalizeClass, normalizeStyle, createElementVNode, renderSlot, toDisplayString, createVNode, withCtx, createBlock, resolveDynamicComponent, createCommentVNode } from 'vue';
2
+ import { ElIcon } from '../../icon/index.mjs';
3
+ import '../../focus-trap/index.mjs';
4
+ import '../../../hooks/index.mjs';
1
5
  import '../../../utils/index.mjs';
2
- import { buildProps } from '../../../utils/vue/props/runtime.mjs';
3
- import { iconPropType } from '../../../utils/vue/icon.mjs';
6
+ import { dialogInjectionKey } from './constants.mjs';
7
+ import { dialogContentProps, dialogContentEmits } from './dialog-content.mjs';
8
+ import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
9
+ import { useLocale } from '../../../hooks/use-locale/index.mjs';
10
+ import { CloseComponents } from '../../../utils/vue/icon.mjs';
11
+ import { FOCUS_TRAP_INJECTION_KEY } from '../../focus-trap/src/tokens.mjs';
12
+ import { composeRefs } from '../../../utils/vue/refs.mjs';
13
+ import { useDraggable } from '../../../hooks/use-draggable/index.mjs';
4
14
 
5
- const dialogContentProps = buildProps({
6
- center: Boolean,
7
- alignCenter: Boolean,
8
- closeIcon: {
9
- type: iconPropType
10
- },
11
- customClass: {
12
- type: String,
13
- default: ""
14
- },
15
- draggable: Boolean,
16
- fullscreen: Boolean,
17
- showClose: {
18
- type: Boolean,
19
- default: true
20
- },
21
- title: {
22
- type: String,
23
- default: ""
24
- },
25
- ariaLevel: {
26
- type: String,
27
- default: "2"
15
+ const _hoisted_1 = ["aria-level"];
16
+ const _hoisted_2 = ["aria-label"];
17
+ const _hoisted_3 = ["id"];
18
+ const __default__ = defineComponent({ name: "ElDialogContent" });
19
+ const _sfc_main = /* @__PURE__ */ defineComponent({
20
+ ...__default__,
21
+ props: dialogContentProps,
22
+ emits: dialogContentEmits,
23
+ setup(__props) {
24
+ const props = __props;
25
+ const { t } = useLocale();
26
+ const { Close } = CloseComponents;
27
+ const { dialogRef, headerRef, bodyId, ns, style } = inject(dialogInjectionKey);
28
+ const { focusTrapRef } = inject(FOCUS_TRAP_INJECTION_KEY);
29
+ const dialogKls = computed(() => [
30
+ ns.b(),
31
+ ns.is("fullscreen", props.fullscreen),
32
+ ns.is("draggable", props.draggable),
33
+ ns.is("align-center", props.alignCenter),
34
+ { [ns.m("center")]: props.center },
35
+ props.customClass
36
+ ]);
37
+ const composedDialogRef = composeRefs(focusTrapRef, dialogRef);
38
+ const draggable = computed(() => props.draggable);
39
+ useDraggable(dialogRef, headerRef, draggable);
40
+ return (_ctx, _cache) => {
41
+ return openBlock(), createElementBlock("div", {
42
+ ref: unref(composedDialogRef),
43
+ class: normalizeClass(unref(dialogKls)),
44
+ style: normalizeStyle(unref(style)),
45
+ tabindex: "-1"
46
+ }, [
47
+ createElementVNode("header", {
48
+ ref_key: "headerRef",
49
+ ref: headerRef,
50
+ class: normalizeClass(unref(ns).e("header"))
51
+ }, [
52
+ renderSlot(_ctx.$slots, "header", {}, () => [
53
+ createElementVNode("span", {
54
+ role: "heading",
55
+ "aria-level": _ctx.ariaLevel,
56
+ class: normalizeClass(unref(ns).e("title"))
57
+ }, toDisplayString(_ctx.title), 11, _hoisted_1)
58
+ ]),
59
+ _ctx.showClose ? (openBlock(), createElementBlock("button", {
60
+ key: 0,
61
+ "aria-label": unref(t)("el.dialog.close"),
62
+ class: normalizeClass(unref(ns).e("headerbtn")),
63
+ type: "button",
64
+ onClick: _cache[0] || (_cache[0] = ($event) => _ctx.$emit("close"))
65
+ }, [
66
+ createVNode(unref(ElIcon), {
67
+ class: normalizeClass(unref(ns).e("close"))
68
+ }, {
69
+ default: withCtx(() => [
70
+ (openBlock(), createBlock(resolveDynamicComponent(_ctx.closeIcon || unref(Close))))
71
+ ]),
72
+ _: 1
73
+ }, 8, ["class"])
74
+ ], 10, _hoisted_2)) : createCommentVNode("v-if", true)
75
+ ], 2),
76
+ createElementVNode("div", {
77
+ id: unref(bodyId),
78
+ class: normalizeClass(unref(ns).e("body"))
79
+ }, [
80
+ renderSlot(_ctx.$slots, "default")
81
+ ], 10, _hoisted_3),
82
+ _ctx.$slots.footer ? (openBlock(), createElementBlock("footer", {
83
+ key: 0,
84
+ class: normalizeClass(unref(ns).e("footer"))
85
+ }, [
86
+ renderSlot(_ctx.$slots, "footer")
87
+ ], 2)) : createCommentVNode("v-if", true)
88
+ ], 6);
89
+ };
28
90
  }
29
91
  });
30
- const dialogContentEmits = {
31
- close: () => true
32
- };
92
+ var ElDialogContent = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "dialog-content.vue"]]);
33
93
 
34
- export { dialogContentEmits, dialogContentProps };
94
+ export { ElDialogContent as default };
35
95
  //# sourceMappingURL=dialog-content2.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"dialog-content2.mjs","sources":["../../../../../../packages/components/dialog/src/dialog-content.ts"],"sourcesContent":["import { buildProps, iconPropType } from '@element-plus/utils'\n\nexport const dialogContentProps = buildProps({\n /**\n * @description whether to align the header and footer in center\n */\n center: Boolean,\n /**\n * @description whether to align the dialog both horizontally and vertically\n */\n alignCenter: Boolean,\n /**\n * @description custom close icon, default is Close\n */\n closeIcon: {\n type: iconPropType,\n },\n /**\n * @deprecated will be removed in version 2.4.0, please use class\n */\n customClass: {\n type: String,\n default: '',\n },\n /**\n * @description enable dragging feature for Dialog\n */\n draggable: Boolean,\n /**\n * @description whether the Dialog takes up full screen\n */\n fullscreen: Boolean,\n /**\n * @description whether to show a close button\n */\n showClose: {\n type: Boolean,\n default: true,\n },\n /**\n * @description title of Dialog. Can also be passed with a named slot (see the following table)\n */\n title: {\n type: String,\n default: '',\n },\n /**\n * @description header's aria-level attribute\n */\n ariaLevel: {\n type: String,\n default: '2',\n },\n} as const)\n\nexport const dialogContentEmits = {\n close: () => true,\n}\n"],"names":[],"mappings":";;;;AACY,MAAC,kBAAkB,GAAG,UAAU,CAAC;AAC7C,EAAE,MAAM,EAAE,OAAO;AACjB,EAAE,WAAW,EAAE,OAAO;AACtB,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,YAAY;AACtB,GAAG;AACH,EAAE,WAAW,EAAE;AACf,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,SAAS,EAAE,OAAO;AACpB,EAAE,UAAU,EAAE,OAAO;AACrB,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,IAAI;AACjB,GAAG;AACH,EAAE,KAAK,EAAE;AACT,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,GAAG;AAChB,GAAG;AACH,CAAC,EAAE;AACS,MAAC,kBAAkB,GAAG;AAClC,EAAE,KAAK,EAAE,MAAM,IAAI;AACnB;;;;"}
1
+ {"version":3,"file":"dialog-content2.mjs","sources":["../../../../../../packages/components/dialog/src/dialog-content.vue"],"sourcesContent":["<template>\n <div :ref=\"composedDialogRef\" :class=\"dialogKls\" :style=\"style\" tabindex=\"-1\">\n <header ref=\"headerRef\" :class=\"ns.e('header')\">\n <slot name=\"header\">\n <span role=\"heading\" :aria-level=\"ariaLevel\" :class=\"ns.e('title')\">\n {{ title }}\n </span>\n </slot>\n <button\n v-if=\"showClose\"\n :aria-label=\"t('el.dialog.close')\"\n :class=\"ns.e('headerbtn')\"\n type=\"button\"\n @click=\"$emit('close')\"\n >\n <el-icon :class=\"ns.e('close')\">\n <component :is=\"closeIcon || Close\" />\n </el-icon>\n </button>\n </header>\n <div :id=\"bodyId\" :class=\"ns.e('body')\">\n <slot />\n </div>\n <footer v-if=\"$slots.footer\" :class=\"ns.e('footer')\">\n <slot name=\"footer\" />\n </footer>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed, inject } from 'vue'\nimport { ElIcon } from '@element-plus/components/icon'\nimport { FOCUS_TRAP_INJECTION_KEY } from '@element-plus/components/focus-trap'\nimport { useDraggable, useLocale } from '@element-plus/hooks'\nimport { CloseComponents, composeRefs } from '@element-plus/utils'\nimport { dialogInjectionKey } from './constants'\nimport { dialogContentEmits, dialogContentProps } from './dialog-content'\n\nconst { t } = useLocale()\nconst { Close } = CloseComponents\n\ndefineOptions({ name: 'ElDialogContent' })\nconst props = defineProps(dialogContentProps)\ndefineEmits(dialogContentEmits)\n\nconst { dialogRef, headerRef, bodyId, ns, style } = inject(dialogInjectionKey)!\nconst { focusTrapRef } = inject(FOCUS_TRAP_INJECTION_KEY)!\n\nconst dialogKls = computed(() => [\n ns.b(),\n ns.is('fullscreen', props.fullscreen),\n ns.is('draggable', props.draggable),\n ns.is('align-center', props.alignCenter),\n { [ns.m('center')]: props.center },\n props.customClass,\n])\n\nconst composedDialogRef = composeRefs(focusTrapRef, dialogRef)\n\nconst draggable = computed(() => props.draggable)\nuseDraggable(dialogRef, headerRef, draggable)\n</script>\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;mCAyCc,CAAA,EAAE,IAAM,EAAA,iBAAA,EAAkB,CAAA,CAAA;;;;;;;AAHxC,IAAM,MAAA,EAAE,MAAM,SAAU,EAAA,CAAA;AACxB,IAAA,MAAM,EAAE,KAAU,EAAA,GAAA,eAAA,CAAA;AAMlB,IAAA,MAAM,EAAE,SAAW,EAAA,SAAA,EAAW,QAAQ,EAAI,EAAA,KAAA,EAAA,GAAU,OAAO,kBAAkB,CAAA,CAAA;AAC7E,IAAM,MAAA,EAAE,YAAiB,EAAA,GAAA,MAAA,CAAO,wBAAwB,CAAA,CAAA;AAExD,IAAM,MAAA,SAAA,GAAY,SAAS,MAAM;AAAA,MAC/B,GAAG,CAAE,EAAA;AAAA,MACL,EAAG,CAAA,EAAA,CAAG,YAAc,EAAA,KAAA,CAAM,UAAU,CAAA;AAAA,MACpC,EAAG,CAAA,EAAA,CAAG,WAAa,EAAA,KAAA,CAAM,SAAS,CAAA;AAAA,MAClC,EAAG,CAAA,EAAA,CAAG,cAAgB,EAAA,KAAA,CAAM,WAAW,CAAA;AAAA,MACvC,EAAE,CAAC,EAAA,CAAG,EAAE,QAAQ,CAAA,GAAI,MAAM,MAAO,EAAA;AAAA,MACjC,KAAM,CAAA,WAAA;AAAA,KACP,CAAA,CAAA;AAED,IAAM,MAAA,iBAAA,GAAoB,WAAY,CAAA,YAAA,EAAc,SAAS,CAAA,CAAA;AAE7D,IAAA,MAAM,SAAY,GAAA,QAAA,CAAS,MAAM,KAAA,CAAM,SAAS,CAAA,CAAA;AAChD,IAAa,YAAA,CAAA,SAAA,EAAW,WAAW,SAAS,CAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,6 +1,6 @@
1
1
  import '../../../utils/index.mjs';
2
2
  import '../../../constants/index.mjs';
3
- import { dialogContentProps } from './dialog-content2.mjs';
3
+ import { dialogContentProps } from './dialog-content.mjs';
4
4
  import { buildProps, definePropType } from '../../../utils/vue/props/runtime.mjs';
5
5
  import { UPDATE_MODEL_EVENT } from '../../../constants/event.mjs';
6
6
  import { isBoolean } from '../../../utils/types.mjs';
@@ -2,7 +2,7 @@ import { defineComponent, useSlots, computed, ref, provide, openBlock, createBlo
2
2
  import { ElOverlay } from '../../overlay/index.mjs';
3
3
  import '../../../hooks/index.mjs';
4
4
  import '../../focus-trap/index.mjs';
5
- import ElDialogContent from './dialog-content.mjs';
5
+ import ElDialogContent from './dialog-content2.mjs';
6
6
  import { dialogInjectionKey } from './constants.mjs';
7
7
  import { dialogProps, dialogEmits } from './dialog.mjs';
8
8
  import { useDialog } from './use-dialog.mjs';
@@ -14,7 +14,7 @@ import { ROVING_FOCUS_GROUP_ITEM_INJECTION_KEY } from '../../roving-focus-group/
14
14
  import { composeRefs } from '../../../utils/vue/refs.mjs';
15
15
  import { composeEventHandlers } from '../../../utils/dom/event.mjs';
16
16
  import { EVENT_CODE } from '../../../constants/aria.mjs';
17
- import { COLLECTION_ITEM_SIGN } from '../../collection/src/collection2.mjs';
17
+ import { COLLECTION_ITEM_SIGN } from '../../collection/src/collection.mjs';
18
18
 
19
19
  const _sfc_main = defineComponent({
20
20
  name: "DropdownItemImpl",
@@ -7,7 +7,7 @@ import { useTooltipTriggerProps } from '../../tooltip/src/trigger.mjs';
7
7
  import { useTooltipContentProps } from '../../tooltip/src/content.mjs';
8
8
  import { iconPropType } from '../../../utils/vue/icon.mjs';
9
9
  import { EVENT_CODE } from '../../../constants/aria.mjs';
10
- import { createCollectionWithScope } from '../../collection/src/collection2.mjs';
10
+ import { createCollectionWithScope } from '../../collection/src/collection.mjs';
11
11
 
12
12
  const dropdownProps = buildProps({
13
13
  trigger: useTooltipTriggerProps.trigger,
@@ -1,7 +1,7 @@
1
1
  import '../../utils/index.mjs';
2
- import Form from './src/form2.mjs';
2
+ import Form from './src/form.mjs';
3
3
  import FormItem from './src/form-item2.mjs';
4
- export { formEmits, formProps } from './src/form.mjs';
4
+ export { formEmits, formProps } from './src/form2.mjs';
5
5
  export { formItemProps, formItemValidateStates } from './src/form-item.mjs';
6
6
  import './src/types.mjs';
7
7
  export { formContextKey, formItemContextKey } from './src/constants.mjs';
@@ -1,61 +1,159 @@
1
- import '../../../constants/index.mjs';
1
+ import { defineComponent, computed, watch, provide, reactive, toRefs, openBlock, createElementBlock, normalizeClass, unref, renderSlot } from 'vue';
2
2
  import '../../../utils/index.mjs';
3
- import { buildProps, definePropType } from '../../../utils/vue/props/runtime.mjs';
4
- import { componentSizes } from '../../../constants/size.mjs';
5
- import { isArray, isString } from '@vue/shared';
6
- import { isBoolean } from '../../../utils/types.mjs';
3
+ import '../../../hooks/index.mjs';
4
+ import './hooks/index.mjs';
5
+ import { formContextKey } from './constants.mjs';
6
+ import { formProps, formEmits } from './form2.mjs';
7
+ import { filterFields, useFormLabelWidth } from './utils.mjs';
8
+ import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
9
+ import { useFormSize } from './hooks/use-form-common-props.mjs';
10
+ import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
11
+ import { debugWarn } from '../../../utils/error.mjs';
12
+ import { isFunction } from '@vue/shared';
7
13
 
8
- const formMetaProps = buildProps({
9
- size: {
10
- type: String,
11
- values: componentSizes
12
- },
13
- disabled: Boolean
14
+ const COMPONENT_NAME = "ElForm";
15
+ const __default__ = defineComponent({
16
+ name: COMPONENT_NAME
14
17
  });
15
- const formProps = buildProps({
16
- ...formMetaProps,
17
- model: Object,
18
- rules: {
19
- type: definePropType(Object)
20
- },
21
- labelPosition: {
22
- type: String,
23
- values: ["left", "right", "top"],
24
- default: "right"
25
- },
26
- requireAsteriskPosition: {
27
- type: String,
28
- values: ["left", "right"],
29
- default: "left"
30
- },
31
- labelWidth: {
32
- type: [String, Number],
33
- default: ""
34
- },
35
- labelSuffix: {
36
- type: String,
37
- default: ""
38
- },
39
- inline: Boolean,
40
- inlineMessage: Boolean,
41
- statusIcon: Boolean,
42
- showMessage: {
43
- type: Boolean,
44
- default: true
45
- },
46
- validateOnRuleChange: {
47
- type: Boolean,
48
- default: true
49
- },
50
- hideRequiredAsterisk: Boolean,
51
- scrollToError: Boolean,
52
- scrollIntoViewOptions: {
53
- type: [Object, Boolean]
18
+ const _sfc_main = /* @__PURE__ */ defineComponent({
19
+ ...__default__,
20
+ props: formProps,
21
+ emits: formEmits,
22
+ setup(__props, { expose, emit }) {
23
+ const props = __props;
24
+ const fields = [];
25
+ const formSize = useFormSize();
26
+ const ns = useNamespace("form");
27
+ const formClasses = computed(() => {
28
+ const { labelPosition, inline } = props;
29
+ return [
30
+ ns.b(),
31
+ ns.m(formSize.value || "default"),
32
+ {
33
+ [ns.m(`label-${labelPosition}`)]: labelPosition,
34
+ [ns.m("inline")]: inline
35
+ }
36
+ ];
37
+ });
38
+ const getField = (prop) => {
39
+ return fields.find((field) => field.prop === prop);
40
+ };
41
+ const addField = (field) => {
42
+ fields.push(field);
43
+ };
44
+ const removeField = (field) => {
45
+ if (field.prop) {
46
+ fields.splice(fields.indexOf(field), 1);
47
+ }
48
+ };
49
+ const resetFields = (properties = []) => {
50
+ if (!props.model) {
51
+ debugWarn(COMPONENT_NAME, "model is required for resetFields to work.");
52
+ return;
53
+ }
54
+ filterFields(fields, properties).forEach((field) => field.resetField());
55
+ };
56
+ const clearValidate = (props2 = []) => {
57
+ filterFields(fields, props2).forEach((field) => field.clearValidate());
58
+ };
59
+ const isValidatable = computed(() => {
60
+ const hasModel = !!props.model;
61
+ if (!hasModel) {
62
+ debugWarn(COMPONENT_NAME, "model is required for validate to work.");
63
+ }
64
+ return hasModel;
65
+ });
66
+ const obtainValidateFields = (props2) => {
67
+ if (fields.length === 0)
68
+ return [];
69
+ const filteredFields = filterFields(fields, props2);
70
+ if (!filteredFields.length) {
71
+ debugWarn(COMPONENT_NAME, "please pass correct props!");
72
+ return [];
73
+ }
74
+ return filteredFields;
75
+ };
76
+ const validate = async (callback) => validateField(void 0, callback);
77
+ const doValidateField = async (props2 = []) => {
78
+ if (!isValidatable.value)
79
+ return false;
80
+ const fields2 = obtainValidateFields(props2);
81
+ if (fields2.length === 0)
82
+ return true;
83
+ let validationErrors = {};
84
+ for (const field of fields2) {
85
+ try {
86
+ await field.validate("");
87
+ } catch (fields3) {
88
+ validationErrors = {
89
+ ...validationErrors,
90
+ ...fields3
91
+ };
92
+ }
93
+ }
94
+ if (Object.keys(validationErrors).length === 0)
95
+ return true;
96
+ return Promise.reject(validationErrors);
97
+ };
98
+ const validateField = async (modelProps = [], callback) => {
99
+ const shouldThrow = !isFunction(callback);
100
+ try {
101
+ const result = await doValidateField(modelProps);
102
+ if (result === true) {
103
+ callback == null ? void 0 : callback(result);
104
+ }
105
+ return result;
106
+ } catch (e) {
107
+ if (e instanceof Error)
108
+ throw e;
109
+ const invalidFields = e;
110
+ if (props.scrollToError) {
111
+ scrollToField(Object.keys(invalidFields)[0]);
112
+ }
113
+ callback == null ? void 0 : callback(false, invalidFields);
114
+ return shouldThrow && Promise.reject(invalidFields);
115
+ }
116
+ };
117
+ const scrollToField = (prop) => {
118
+ var _a;
119
+ const field = filterFields(fields, prop)[0];
120
+ if (field) {
121
+ (_a = field.$el) == null ? void 0 : _a.scrollIntoView(props.scrollIntoViewOptions);
122
+ }
123
+ };
124
+ watch(() => props.rules, () => {
125
+ if (props.validateOnRuleChange) {
126
+ validate().catch((err) => debugWarn(err));
127
+ }
128
+ }, { deep: true });
129
+ provide(formContextKey, reactive({
130
+ ...toRefs(props),
131
+ emit,
132
+ resetFields,
133
+ clearValidate,
134
+ validateField,
135
+ getField,
136
+ addField,
137
+ removeField,
138
+ ...useFormLabelWidth()
139
+ }));
140
+ expose({
141
+ validate,
142
+ validateField,
143
+ resetFields,
144
+ clearValidate,
145
+ scrollToField
146
+ });
147
+ return (_ctx, _cache) => {
148
+ return openBlock(), createElementBlock("form", {
149
+ class: normalizeClass(unref(formClasses))
150
+ }, [
151
+ renderSlot(_ctx.$slots, "default")
152
+ ], 2);
153
+ };
54
154
  }
55
155
  });
56
- const formEmits = {
57
- validate: (prop, isValid, message) => (isArray(prop) || isString(prop)) && isBoolean(isValid) && isString(message)
58
- };
156
+ var Form = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "form.vue"]]);
59
157
 
60
- export { formEmits, formProps };
158
+ export { Form as default };
61
159
  //# sourceMappingURL=form.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"form.mjs","sources":["../../../../../../packages/components/form/src/form.ts"],"sourcesContent":["import { componentSizes } from '@element-plus/constants'\nimport {\n buildProps,\n definePropType,\n isArray,\n isBoolean,\n isString,\n} from '@element-plus/utils'\n\nimport type { ExtractPropTypes } from 'vue'\nimport type { FormItemProp } from './form-item'\nimport type { FormRules } from './types'\n\nconst formMetaProps = buildProps({\n /**\n * @description Control the size of components in this form.\n */\n size: {\n type: String,\n values: componentSizes,\n },\n /**\n * @description Whether to disable all components in this form. If set to `true`, it will override the `disabled` prop of the inner component.\n */\n disabled: Boolean,\n} as const)\n\nexport const formProps = buildProps({\n ...formMetaProps,\n /**\n * @description Data of form component.\n */\n model: Object,\n /**\n * @description Validation rules of form.\n */\n rules: {\n type: definePropType<FormRules>(Object),\n },\n /**\n * @description Position of label. If set to `'left'` or `'right'`, `label-width` prop is also required.\n */\n labelPosition: {\n type: String,\n values: ['left', 'right', 'top'],\n default: 'right',\n },\n /**\n * @description Position of asterisk.\n */\n requireAsteriskPosition: {\n type: String,\n values: ['left', 'right'],\n default: 'left',\n },\n /**\n * @description Width of label, e.g. `'50px'`. All its direct child form items will inherit this value. `auto` is supported.\n */\n labelWidth: {\n type: [String, Number],\n default: '',\n },\n /**\n * @description Suffix of the label.\n */\n labelSuffix: {\n type: String,\n default: '',\n },\n /**\n * @description Whether the form is inline.\n */\n inline: Boolean,\n /**\n * @description Whether to display the error message inline with the form item.\n */\n inlineMessage: Boolean,\n /**\n * @description Whether to display an icon indicating the validation result.\n */\n statusIcon: Boolean,\n /**\n * @description Whether to show the error message.\n */\n showMessage: {\n type: Boolean,\n default: true,\n },\n /**\n * @description Whether to trigger validation when the `rules` prop is changed.\n */\n validateOnRuleChange: {\n type: Boolean,\n default: true,\n },\n /**\n * @description Whether to hide required fields should have a red asterisk (star) beside their labels.\n */\n hideRequiredAsterisk: Boolean,\n /**\n * @description When validation fails, scroll to the first error form entry.\n */\n scrollToError: Boolean,\n /**\n * @description When validation fails, it scrolls to the first error item based on the scrollIntoView option.\n */\n scrollIntoViewOptions: {\n type: [Object, Boolean],\n },\n} as const)\nexport type FormProps = ExtractPropTypes<typeof formProps>\nexport type FormMetaProps = ExtractPropTypes<typeof formMetaProps>\n\nexport const formEmits = {\n validate: (prop: FormItemProp, isValid: boolean, message: string) =>\n (isArray(prop) || isString(prop)) &&\n isBoolean(isValid) &&\n isString(message),\n}\nexport type FormEmits = typeof formEmits\n"],"names":[],"mappings":";;;;;;;AAQA,MAAM,aAAa,GAAG,UAAU,CAAC;AACjC,EAAE,IAAI,EAAE;AACR,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,MAAM,EAAE,cAAc;AAC1B,GAAG;AACH,EAAE,QAAQ,EAAE,OAAO;AACnB,CAAC,CAAC,CAAC;AACS,MAAC,SAAS,GAAG,UAAU,CAAC;AACpC,EAAE,GAAG,aAAa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,IAAI,CAAC,KAAK,SAAS,CAAC,OAAO,CAAC,IAAI,QAAQ,CAAC,OAAO,CAAC;AACpH;;;;"}
1
+ {"version":3,"file":"form.mjs","sources":["../../../../../../packages/components/form/src/form.vue"],"sourcesContent":["<template>\n <form :class=\"formClasses\">\n <slot />\n </form>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed, provide, reactive, toRefs, watch } from 'vue'\nimport { debugWarn, isFunction } from '@element-plus/utils'\nimport { useNamespace } from '@element-plus/hooks'\nimport { useFormSize } from './hooks'\nimport { formContextKey } from './constants'\nimport { formEmits, formProps } from './form'\nimport { filterFields, useFormLabelWidth } from './utils'\n\nimport type { ValidateFieldsError } from 'async-validator'\nimport type { Arrayable } from '@element-plus/utils'\nimport type {\n FormContext,\n FormItemContext,\n FormValidateCallback,\n FormValidationResult,\n} from './types'\nimport type { FormItemProp } from './form-item'\n\nconst COMPONENT_NAME = 'ElForm'\ndefineOptions({\n name: COMPONENT_NAME,\n})\nconst props = defineProps(formProps)\nconst emit = defineEmits(formEmits)\n\nconst fields: FormItemContext[] = []\n\nconst formSize = useFormSize()\nconst ns = useNamespace('form')\nconst formClasses = computed(() => {\n const { labelPosition, inline } = props\n return [\n ns.b(),\n // todo: in v2.2.0, we can remove default\n // in fact, remove it doesn't affect the final style\n ns.m(formSize.value || 'default'),\n {\n [ns.m(`label-${labelPosition}`)]: labelPosition,\n [ns.m('inline')]: inline,\n },\n ]\n})\n\nconst getField: FormContext['getField'] = (prop) => {\n return fields.find((field) => field.prop === prop)\n}\n\nconst addField: FormContext['addField'] = (field) => {\n fields.push(field)\n}\n\nconst removeField: FormContext['removeField'] = (field) => {\n if (field.prop) {\n fields.splice(fields.indexOf(field), 1)\n }\n}\n\nconst resetFields: FormContext['resetFields'] = (properties = []) => {\n if (!props.model) {\n debugWarn(COMPONENT_NAME, 'model is required for resetFields to work.')\n return\n }\n filterFields(fields, properties).forEach((field) => field.resetField())\n}\n\nconst clearValidate: FormContext['clearValidate'] = (props = []) => {\n filterFields(fields, props).forEach((field) => field.clearValidate())\n}\n\nconst isValidatable = computed(() => {\n const hasModel = !!props.model\n if (!hasModel) {\n debugWarn(COMPONENT_NAME, 'model is required for validate to work.')\n }\n return hasModel\n})\n\nconst obtainValidateFields = (props: Arrayable<FormItemProp>) => {\n if (fields.length === 0) return []\n\n const filteredFields = filterFields(fields, props)\n if (!filteredFields.length) {\n debugWarn(COMPONENT_NAME, 'please pass correct props!')\n return []\n }\n return filteredFields\n}\n\nconst validate = async (\n callback?: FormValidateCallback\n): FormValidationResult => validateField(undefined, callback)\n\nconst doValidateField = async (\n props: Arrayable<FormItemProp> = []\n): Promise<boolean> => {\n if (!isValidatable.value) return false\n\n const fields = obtainValidateFields(props)\n if (fields.length === 0) return true\n\n let validationErrors: ValidateFieldsError = {}\n for (const field of fields) {\n try {\n await field.validate('')\n } catch (fields) {\n validationErrors = {\n ...validationErrors,\n ...(fields as ValidateFieldsError),\n }\n }\n }\n\n if (Object.keys(validationErrors).length === 0) return true\n return Promise.reject(validationErrors)\n}\n\nconst validateField: FormContext['validateField'] = async (\n modelProps = [],\n callback\n) => {\n const shouldThrow = !isFunction(callback)\n try {\n const result = await doValidateField(modelProps)\n // When result is false meaning that the fields are not validatable\n if (result === true) {\n callback?.(result)\n }\n return result\n } catch (e) {\n if (e instanceof Error) throw e\n\n const invalidFields = e as ValidateFieldsError\n\n if (props.scrollToError) {\n scrollToField(Object.keys(invalidFields)[0])\n }\n callback?.(false, invalidFields)\n return shouldThrow && Promise.reject(invalidFields)\n }\n}\n\nconst scrollToField = (prop: FormItemProp) => {\n const field = filterFields(fields, prop)[0]\n if (field) {\n field.$el?.scrollIntoView(props.scrollIntoViewOptions)\n }\n}\n\nwatch(\n () => props.rules,\n () => {\n if (props.validateOnRuleChange) {\n validate().catch((err) => debugWarn(err))\n }\n },\n { deep: true }\n)\n\nprovide(\n formContextKey,\n reactive({\n ...toRefs(props),\n emit,\n\n resetFields,\n clearValidate,\n validateField,\n getField,\n addField,\n removeField,\n\n ...useFormLabelWidth(),\n })\n)\n\ndefineExpose({\n /**\n * @description Validate the whole form. Receives a callback or returns `Promise`.\n */\n validate,\n /**\n * @description Validate specified fields.\n */\n validateField,\n /**\n * @description Reset specified fields and remove validation result.\n */\n resetFields,\n /**\n * @description Clear validation message for specified fields.\n */\n clearValidate,\n /**\n * @description Scroll to the specified fields.\n */\n scrollToField,\n})\n</script>\n"],"names":[],"mappings":";;;;;;;;;;;;;;mCA0Bc,CAAA;AAAA,EACZ,IAAM,EAAA,cAAA;AACR;;;;;;;AAIA,IAAA,MAAM,SAA4B,EAAC,CAAA;AAEnC,IAAA,MAAM,WAAW,WAAY,EAAA,CAAA;AAC7B,IAAM,MAAA,EAAA,GAAK,aAAa,MAAM,CAAA,CAAA;AAC9B,IAAM,MAAA,WAAA,GAAc,SAAS,MAAM;AACjC,MAAM,MAAA,EAAE,eAAe,MAAW,EAAA,GAAA,KAAA,CAAA;AAClC,MAAO,OAAA;AAAA,QACL,GAAG,CAAE,EAAA;AAAA,QAGL,EAAG,CAAA,CAAA,CAAE,QAAS,CAAA,KAAA,IAAS,SAAS,CAAA;AAAA,QAChC;AAAA,UACE,CAAC,EAAA,CAAG,CAAE,CAAA,CAAA,MAAA,EAAS,eAAe,CAAI,GAAA,aAAA;AAAA,UAClC,CAAC,EAAA,CAAG,CAAE,CAAA,QAAQ,CAAI,GAAA,MAAA;AAAA,SACpB;AAAA,OACF,CAAA;AAAA,KACD,CAAA,CAAA;AAED,IAAM,MAAA,QAAA,GAAoC,CAAC,IAAS,KAAA;AAClD,MAAA,OAAO,OAAO,IAAK,CAAA,CAAC,KAAU,KAAA,KAAA,CAAM,SAAS,IAAI,CAAA,CAAA;AAAA,KACnD,CAAA;AAEA,IAAM,MAAA,QAAA,GAAoC,CAAC,KAAU,KAAA;AACnD,MAAA,MAAA,CAAO,KAAK,KAAK,CAAA,CAAA;AAAA,KACnB,CAAA;AAEA,IAAM,MAAA,WAAA,GAA0C,CAAC,KA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