element-ps 2.0.18 → 2.0.19

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 (406) hide show
  1. package/dist/index.full.js +2 -21
  2. package/dist/index.full.min.js +5 -5
  3. package/dist/index.full.min.js.map +1 -1
  4. package/dist/index.full.min.mjs +5 -5
  5. package/dist/index.full.min.mjs.map +1 -1
  6. package/dist/index.full.mjs +2 -21
  7. package/es/components/alert/index.mjs +2 -2
  8. package/es/components/alert/src/alert.mjs +33 -83
  9. package/es/components/alert/src/alert.mjs.map +1 -1
  10. package/es/components/alert/src/alert2.mjs +83 -33
  11. package/es/components/alert/src/alert2.mjs.map +1 -1
  12. package/es/components/autocomplete/index.mjs +2 -2
  13. package/es/components/autocomplete/src/autocomplete.mjs +58 -94
  14. package/es/components/autocomplete/src/autocomplete.mjs.map +1 -1
  15. package/es/components/autocomplete/src/autocomplete2.mjs +94 -58
  16. package/es/components/autocomplete/src/autocomplete2.mjs.map +1 -1
  17. package/es/components/backtop/index.mjs +2 -2
  18. package/es/components/backtop/src/backtop.mjs +18 -59
  19. package/es/components/backtop/src/backtop.mjs.map +1 -1
  20. package/es/components/backtop/src/backtop2.mjs +59 -18
  21. package/es/components/backtop/src/backtop2.mjs.map +1 -1
  22. package/es/components/breadcrumb/index.mjs +4 -4
  23. package/es/components/breadcrumb/src/breadcrumb-item.mjs +46 -11
  24. package/es/components/breadcrumb/src/breadcrumb-item.mjs.map +1 -1
  25. package/es/components/breadcrumb/src/breadcrumb-item2.mjs +11 -46
  26. package/es/components/breadcrumb/src/breadcrumb-item2.mjs.map +1 -1
  27. package/es/components/breadcrumb/src/breadcrumb.mjs +37 -12
  28. package/es/components/breadcrumb/src/breadcrumb.mjs.map +1 -1
  29. package/es/components/breadcrumb/src/breadcrumb2.mjs +12 -37
  30. package/es/components/breadcrumb/src/breadcrumb2.mjs.map +1 -1
  31. package/es/components/button/index.mjs +2 -2
  32. package/es/components/button/src/button-group.mjs +1 -1
  33. package/es/components/button/src/button.mjs +48 -96
  34. package/es/components/button/src/button.mjs.map +1 -1
  35. package/es/components/button/src/button2.mjs +96 -48
  36. package/es/components/button/src/button2.mjs.map +1 -1
  37. package/es/components/calendar/index.mjs +2 -2
  38. package/es/components/calendar/src/calendar.mjs +9 -188
  39. package/es/components/calendar/src/calendar.mjs.map +1 -1
  40. package/es/components/calendar/src/calendar2.mjs +188 -9
  41. package/es/components/calendar/src/calendar2.mjs.map +1 -1
  42. package/es/components/card/index.mjs +2 -2
  43. package/es/components/card/src/card.mjs +15 -35
  44. package/es/components/card/src/card.mjs.map +1 -1
  45. package/es/components/card/src/card2.mjs +35 -15
  46. package/es/components/card/src/card2.mjs.map +1 -1
  47. package/es/components/carousel/index.mjs +2 -2
  48. package/es/components/carousel/src/carousel-item.mjs +148 -7
  49. package/es/components/carousel/src/carousel-item.mjs.map +1 -1
  50. package/es/components/carousel/src/carousel-item2.mjs +7 -148
  51. package/es/components/carousel/src/carousel-item2.mjs.map +1 -1
  52. package/es/components/cascader-panel/src/config.mjs +1 -1
  53. package/es/components/cascader-panel/src/index.mjs +1 -1
  54. package/es/components/cascader-panel/src/menu.mjs +1 -1
  55. package/es/components/cascader-panel/src/node.mjs +200 -120
  56. package/es/components/cascader-panel/src/node.mjs.map +1 -1
  57. package/es/components/cascader-panel/src/node2.mjs +120 -200
  58. package/es/components/cascader-panel/src/node2.mjs.map +1 -1
  59. package/es/components/cascader-panel/src/store.mjs +1 -1
  60. package/es/components/collapse/index.mjs +2 -2
  61. package/es/components/collapse/src/collapse-item.mjs +12 -91
  62. package/es/components/collapse/src/collapse-item.mjs.map +1 -1
  63. package/es/components/collapse/src/collapse-item2.mjs +91 -12
  64. package/es/components/collapse/src/collapse-item2.mjs.map +1 -1
  65. package/es/components/dialog/index.mjs +2 -2
  66. package/es/components/dialog/src/dialog.mjs +61 -87
  67. package/es/components/dialog/src/dialog.mjs.map +1 -1
  68. package/es/components/dialog/src/dialog2.mjs +87 -61
  69. package/es/components/dialog/src/dialog2.mjs.map +1 -1
  70. package/es/components/divider/index.mjs +2 -2
  71. package/es/components/divider/src/divider.mjs +17 -34
  72. package/es/components/divider/src/divider.mjs.map +1 -1
  73. package/es/components/divider/src/divider2.mjs +34 -17
  74. package/es/components/divider/src/divider2.mjs.map +1 -1
  75. package/es/components/drawer/index.mjs +2 -2
  76. package/es/components/drawer/src/drawer.mjs +117 -23
  77. package/es/components/drawer/src/drawer.mjs.map +1 -1
  78. package/es/components/drawer/src/drawer2.mjs +23 -117
  79. package/es/components/drawer/src/drawer2.mjs.map +1 -1
  80. package/es/components/dropdown/index.d.ts +0 -6
  81. package/es/components/dropdown/src/dropdown-menu.mjs +4 -27
  82. package/es/components/dropdown/src/dropdown-menu.mjs.map +1 -1
  83. package/es/components/dropdown/src/dropdown-menu.vue.d.ts +0 -3
  84. package/es/components/empty/index.mjs +2 -2
  85. package/es/components/empty/src/empty.mjs +11 -56
  86. package/es/components/empty/src/empty.mjs.map +1 -1
  87. package/es/components/empty/src/empty2.mjs +56 -11
  88. package/es/components/empty/src/empty2.mjs.map +1 -1
  89. package/es/components/form/index.mjs +2 -2
  90. package/es/components/form/src/form.mjs +40 -45
  91. package/es/components/form/src/form.mjs.map +1 -1
  92. package/es/components/form/src/form2.mjs +45 -40
  93. package/es/components/form/src/form2.mjs.map +1 -1
  94. package/es/components/icon/index.mjs +2 -2
  95. package/es/components/icon/src/icon.mjs +8 -35
  96. package/es/components/icon/src/icon.mjs.map +1 -1
  97. package/es/components/icon/src/icon2.mjs +35 -8
  98. package/es/components/icon/src/icon2.mjs.map +1 -1
  99. package/es/components/image/index.mjs +2 -2
  100. package/es/components/image/src/image.mjs +46 -170
  101. package/es/components/image/src/image.mjs.map +1 -1
  102. package/es/components/image/src/image2.mjs +170 -46
  103. package/es/components/image/src/image2.mjs.map +1 -1
  104. package/es/components/image-viewer/index.mjs +2 -2
  105. package/es/components/image-viewer/src/image-viewer.mjs +31 -210
  106. package/es/components/image-viewer/src/image-viewer.mjs.map +1 -1
  107. package/es/components/image-viewer/src/image-viewer2.mjs +210 -31
  108. package/es/components/image-viewer/src/image-viewer2.mjs.map +1 -1
  109. package/es/components/index.mjs +35 -35
  110. package/es/components/link/index.mjs +2 -2
  111. package/es/components/link/src/link.mjs +43 -19
  112. package/es/components/link/src/link.mjs.map +1 -1
  113. package/es/components/link/src/link2.mjs +19 -43
  114. package/es/components/link/src/link2.mjs.map +1 -1
  115. package/es/components/menu/index.mjs +2 -2
  116. package/es/components/menu/src/menu-item-group.mjs +56 -4
  117. package/es/components/menu/src/menu-item-group.mjs.map +1 -1
  118. package/es/components/menu/src/menu-item-group2.mjs +4 -56
  119. package/es/components/menu/src/menu-item-group2.mjs.map +1 -1
  120. package/es/components/menu/src/menu-item.mjs +1 -1
  121. package/es/components/popconfirm/src/popconfirm2.mjs +1 -1
  122. package/es/components/popper/index.mjs +4 -4
  123. package/es/components/popper/src/arrow.mjs +31 -7
  124. package/es/components/popper/src/arrow.mjs.map +1 -1
  125. package/es/components/popper/src/arrow2.mjs +7 -31
  126. package/es/components/popper/src/arrow2.mjs.map +1 -1
  127. package/es/components/popper/src/popper.mjs +27 -20
  128. package/es/components/popper/src/popper.mjs.map +1 -1
  129. package/es/components/popper/src/popper2.mjs +20 -27
  130. package/es/components/popper/src/popper2.mjs.map +1 -1
  131. package/es/components/progress/index.mjs +2 -2
  132. package/es/components/progress/src/progress.mjs +230 -57
  133. package/es/components/progress/src/progress.mjs.map +1 -1
  134. package/es/components/progress/src/progress2.mjs +57 -230
  135. package/es/components/progress/src/progress2.mjs.map +1 -1
  136. package/es/components/radio/index.mjs +4 -4
  137. package/es/components/radio/src/radio-button.mjs +80 -9
  138. package/es/components/radio/src/radio-button.mjs.map +1 -1
  139. package/es/components/radio/src/radio-button2.mjs +9 -80
  140. package/es/components/radio/src/radio-button2.mjs.map +1 -1
  141. package/es/components/radio/src/radio-group.mjs +18 -37
  142. package/es/components/radio/src/radio-group.mjs.map +1 -1
  143. package/es/components/radio/src/radio-group2.mjs +37 -18
  144. package/es/components/radio/src/radio-group2.mjs.map +1 -1
  145. package/es/components/rate/index.mjs +2 -2
  146. package/es/components/rate/src/rate.mjs +169 -84
  147. package/es/components/rate/src/rate.mjs.map +1 -1
  148. package/es/components/rate/src/rate2.mjs +84 -169
  149. package/es/components/rate/src/rate2.mjs.map +1 -1
  150. package/es/components/scrollbar/index.mjs +2 -2
  151. package/es/components/scrollbar/src/bar.mjs +35 -22
  152. package/es/components/scrollbar/src/bar.mjs.map +1 -1
  153. package/es/components/scrollbar/src/bar2.mjs +22 -35
  154. package/es/components/scrollbar/src/bar2.mjs.map +1 -1
  155. package/es/components/scrollbar/src/scrollbar.mjs +112 -42
  156. package/es/components/scrollbar/src/scrollbar.mjs.map +1 -1
  157. package/es/components/scrollbar/src/scrollbar2.mjs +42 -112
  158. package/es/components/scrollbar/src/scrollbar2.mjs.map +1 -1
  159. package/es/components/select/index.d.ts +4 -4
  160. package/es/components/select/src/select.vue.d.ts +4 -4
  161. package/es/components/select-v2/index.d.ts +10 -10
  162. package/es/components/select-v2/src/select.vue.d.ts +5 -5
  163. package/es/components/skeleton/index.mjs +4 -4
  164. package/es/components/skeleton/src/skeleton-item.mjs +18 -23
  165. package/es/components/skeleton/src/skeleton-item.mjs.map +1 -1
  166. package/es/components/skeleton/src/skeleton-item2.mjs +23 -18
  167. package/es/components/skeleton/src/skeleton-item2.mjs.map +1 -1
  168. package/es/components/skeleton/src/skeleton.mjs +22 -49
  169. package/es/components/skeleton/src/skeleton.mjs.map +1 -1
  170. package/es/components/skeleton/src/skeleton2.mjs +49 -22
  171. package/es/components/skeleton/src/skeleton2.mjs.map +1 -1
  172. package/es/components/tabs/index.mjs +3 -3
  173. package/es/components/tabs/src/tab-bar.mjs +7 -76
  174. package/es/components/tabs/src/tab-bar.mjs.map +1 -1
  175. package/es/components/tabs/src/tab-bar2.mjs +76 -7
  176. package/es/components/tabs/src/tab-bar2.mjs.map +1 -1
  177. package/es/components/tabs/src/tab-nav.mjs +1 -1
  178. package/es/components/tabs/src/tab-pane.mjs +14 -60
  179. package/es/components/tabs/src/tab-pane.mjs.map +1 -1
  180. package/es/components/tabs/src/tab-pane2.mjs +60 -14
  181. package/es/components/tabs/src/tab-pane2.mjs.map +1 -1
  182. package/es/components/timeline/index.mjs +2 -2
  183. package/es/components/timeline/src/timeline-item.mjs +39 -73
  184. package/es/components/timeline/src/timeline-item.mjs.map +1 -1
  185. package/es/components/timeline/src/timeline-item2.mjs +73 -39
  186. package/es/components/timeline/src/timeline-item2.mjs.map +1 -1
  187. package/es/components/tooltip/src/tooltip2.mjs +1 -1
  188. package/es/components/tooltip-v2/index.mjs +1 -1
  189. package/es/components/tooltip-v2/src/content.mjs +113 -50
  190. package/es/components/tooltip-v2/src/content.mjs.map +1 -1
  191. package/es/components/tooltip-v2/src/content2.mjs +50 -113
  192. package/es/components/tooltip-v2/src/content2.mjs.map +1 -1
  193. package/es/components/tooltip-v2/src/tooltip.mjs +1 -1
  194. package/es/components/tooltip-v2/src/tooltip2.mjs +2 -2
  195. package/es/components/upload/index.mjs +3 -3
  196. package/es/components/upload/src/upload-content.mjs +15 -46
  197. package/es/components/upload/src/upload-content.mjs.map +1 -1
  198. package/es/components/upload/src/upload-content2.mjs +46 -15
  199. package/es/components/upload/src/upload-content2.mjs.map +1 -1
  200. package/es/components/upload/src/upload-list2.mjs +1 -1
  201. package/es/components/upload/src/upload.mjs +106 -99
  202. package/es/components/upload/src/upload.mjs.map +1 -1
  203. package/es/components/upload/src/upload2.mjs +99 -106
  204. package/es/components/upload/src/upload2.mjs.map +1 -1
  205. package/es/index.mjs +35 -35
  206. package/lib/components/alert/index.js +2 -2
  207. package/lib/components/alert/src/alert.js +33 -82
  208. package/lib/components/alert/src/alert.js.map +1 -1
  209. package/lib/components/alert/src/alert2.js +82 -33
  210. package/lib/components/alert/src/alert2.js.map +1 -1
  211. package/lib/components/autocomplete/index.js +2 -2
  212. package/lib/components/autocomplete/src/autocomplete.js +58 -94
  213. package/lib/components/autocomplete/src/autocomplete.js.map +1 -1
  214. package/lib/components/autocomplete/src/autocomplete2.js +94 -58
  215. package/lib/components/autocomplete/src/autocomplete2.js.map +1 -1
  216. package/lib/components/backtop/index.js +2 -2
  217. package/lib/components/backtop/src/backtop.js +18 -59
  218. package/lib/components/backtop/src/backtop.js.map +1 -1
  219. package/lib/components/backtop/src/backtop2.js +59 -18
  220. package/lib/components/backtop/src/backtop2.js.map +1 -1
  221. package/lib/components/breadcrumb/index.js +4 -4
  222. package/lib/components/breadcrumb/src/breadcrumb-item.js +46 -11
  223. package/lib/components/breadcrumb/src/breadcrumb-item.js.map +1 -1
  224. package/lib/components/breadcrumb/src/breadcrumb-item2.js +11 -46
  225. package/lib/components/breadcrumb/src/breadcrumb-item2.js.map +1 -1
  226. package/lib/components/breadcrumb/src/breadcrumb.js +37 -12
  227. package/lib/components/breadcrumb/src/breadcrumb.js.map +1 -1
  228. package/lib/components/breadcrumb/src/breadcrumb2.js +12 -37
  229. package/lib/components/breadcrumb/src/breadcrumb2.js.map +1 -1
  230. package/lib/components/button/index.js +2 -2
  231. package/lib/components/button/src/button-group.js +1 -1
  232. package/lib/components/button/src/button.js +50 -96
  233. package/lib/components/button/src/button.js.map +1 -1
  234. package/lib/components/button/src/button2.js +96 -50
  235. package/lib/components/button/src/button2.js.map +1 -1
  236. package/lib/components/calendar/index.js +2 -2
  237. package/lib/components/calendar/src/calendar.js +9 -192
  238. package/lib/components/calendar/src/calendar.js.map +1 -1
  239. package/lib/components/calendar/src/calendar2.js +192 -9
  240. package/lib/components/calendar/src/calendar2.js.map +1 -1
  241. package/lib/components/card/index.js +2 -2
  242. package/lib/components/card/src/card.js +15 -35
  243. package/lib/components/card/src/card.js.map +1 -1
  244. package/lib/components/card/src/card2.js +35 -15
  245. package/lib/components/card/src/card2.js.map +1 -1
  246. package/lib/components/carousel/index.js +2 -2
  247. package/lib/components/carousel/src/carousel-item.js +148 -7
  248. package/lib/components/carousel/src/carousel-item.js.map +1 -1
  249. package/lib/components/carousel/src/carousel-item2.js +7 -148
  250. package/lib/components/carousel/src/carousel-item2.js.map +1 -1
  251. package/lib/components/cascader-panel/src/config.js +1 -1
  252. package/lib/components/cascader-panel/src/index.js +1 -1
  253. package/lib/components/cascader-panel/src/menu.js +1 -1
  254. package/lib/components/cascader-panel/src/node.js +200 -121
  255. package/lib/components/cascader-panel/src/node.js.map +1 -1
  256. package/lib/components/cascader-panel/src/node2.js +121 -200
  257. package/lib/components/cascader-panel/src/node2.js.map +1 -1
  258. package/lib/components/cascader-panel/src/store.js +1 -1
  259. package/lib/components/collapse/index.js +2 -2
  260. package/lib/components/collapse/src/collapse-item.js +12 -91
  261. package/lib/components/collapse/src/collapse-item.js.map +1 -1
  262. package/lib/components/collapse/src/collapse-item2.js +91 -12
  263. package/lib/components/collapse/src/collapse-item2.js.map +1 -1
  264. package/lib/components/dialog/index.js +2 -2
  265. package/lib/components/dialog/src/dialog.js +61 -87
  266. package/lib/components/dialog/src/dialog.js.map +1 -1
  267. package/lib/components/dialog/src/dialog2.js +87 -61
  268. package/lib/components/dialog/src/dialog2.js.map +1 -1
  269. package/lib/components/divider/index.js +2 -2
  270. package/lib/components/divider/src/divider.js +17 -34
  271. package/lib/components/divider/src/divider.js.map +1 -1
  272. package/lib/components/divider/src/divider2.js +34 -17
  273. package/lib/components/divider/src/divider2.js.map +1 -1
  274. package/lib/components/drawer/index.js +2 -2
  275. package/lib/components/drawer/src/drawer.js +117 -23
  276. package/lib/components/drawer/src/drawer.js.map +1 -1
  277. package/lib/components/drawer/src/drawer2.js +23 -117
  278. package/lib/components/drawer/src/drawer2.js.map +1 -1
  279. package/lib/components/dropdown/index.d.ts +0 -6
  280. package/lib/components/dropdown/src/dropdown-menu.js +2 -25
  281. package/lib/components/dropdown/src/dropdown-menu.js.map +1 -1
  282. package/lib/components/dropdown/src/dropdown-menu.vue.d.ts +0 -3
  283. package/lib/components/empty/index.js +2 -2
  284. package/lib/components/empty/src/empty.js +11 -56
  285. package/lib/components/empty/src/empty.js.map +1 -1
  286. package/lib/components/empty/src/empty2.js +56 -11
  287. package/lib/components/empty/src/empty2.js.map +1 -1
  288. package/lib/components/form/index.js +2 -2
  289. package/lib/components/form/src/form.js +40 -45
  290. package/lib/components/form/src/form.js.map +1 -1
  291. package/lib/components/form/src/form2.js +45 -40
  292. package/lib/components/form/src/form2.js.map +1 -1
  293. package/lib/components/icon/index.js +2 -2
  294. package/lib/components/icon/src/icon.js +8 -35
  295. package/lib/components/icon/src/icon.js.map +1 -1
  296. package/lib/components/icon/src/icon2.js +35 -8
  297. package/lib/components/icon/src/icon2.js.map +1 -1
  298. package/lib/components/image/index.js +2 -2
  299. package/lib/components/image/src/image.js +46 -170
  300. package/lib/components/image/src/image.js.map +1 -1
  301. package/lib/components/image/src/image2.js +170 -46
  302. package/lib/components/image/src/image2.js.map +1 -1
  303. package/lib/components/image-viewer/index.js +2 -2
  304. package/lib/components/image-viewer/src/image-viewer.js +31 -210
  305. package/lib/components/image-viewer/src/image-viewer.js.map +1 -1
  306. package/lib/components/image-viewer/src/image-viewer2.js +210 -31
  307. package/lib/components/image-viewer/src/image-viewer2.js.map +1 -1
  308. package/lib/components/index.js +35 -35
  309. package/lib/components/link/index.js +2 -2
  310. package/lib/components/link/src/link.js +43 -19
  311. package/lib/components/link/src/link.js.map +1 -1
  312. package/lib/components/link/src/link2.js +19 -43
  313. package/lib/components/link/src/link2.js.map +1 -1
  314. package/lib/components/menu/index.js +2 -2
  315. package/lib/components/menu/src/menu-item-group.js +56 -4
  316. package/lib/components/menu/src/menu-item-group.js.map +1 -1
  317. package/lib/components/menu/src/menu-item-group2.js +4 -56
  318. package/lib/components/menu/src/menu-item-group2.js.map +1 -1
  319. package/lib/components/menu/src/menu-item.js +1 -1
  320. package/lib/components/popconfirm/src/popconfirm2.js +1 -1
  321. package/lib/components/popper/index.js +4 -4
  322. package/lib/components/popper/src/arrow.js +31 -7
  323. package/lib/components/popper/src/arrow.js.map +1 -1
  324. package/lib/components/popper/src/arrow2.js +7 -31
  325. package/lib/components/popper/src/arrow2.js.map +1 -1
  326. package/lib/components/popper/src/popper.js +27 -21
  327. package/lib/components/popper/src/popper.js.map +1 -1
  328. package/lib/components/popper/src/popper2.js +21 -27
  329. package/lib/components/popper/src/popper2.js.map +1 -1
  330. package/lib/components/progress/index.js +2 -2
  331. package/lib/components/progress/src/progress.js +230 -57
  332. package/lib/components/progress/src/progress.js.map +1 -1
  333. package/lib/components/progress/src/progress2.js +57 -230
  334. package/lib/components/progress/src/progress2.js.map +1 -1
  335. package/lib/components/radio/index.js +4 -4
  336. package/lib/components/radio/src/radio-button.js +79 -8
  337. package/lib/components/radio/src/radio-button.js.map +1 -1
  338. package/lib/components/radio/src/radio-button2.js +8 -79
  339. package/lib/components/radio/src/radio-button2.js.map +1 -1
  340. package/lib/components/radio/src/radio-group.js +18 -37
  341. package/lib/components/radio/src/radio-group.js.map +1 -1
  342. package/lib/components/radio/src/radio-group2.js +37 -18
  343. package/lib/components/radio/src/radio-group2.js.map +1 -1
  344. package/lib/components/rate/index.js +2 -2
  345. package/lib/components/rate/src/rate.js +169 -84
  346. package/lib/components/rate/src/rate.js.map +1 -1
  347. package/lib/components/rate/src/rate2.js +84 -169
  348. package/lib/components/rate/src/rate2.js.map +1 -1
  349. package/lib/components/scrollbar/index.js +2 -2
  350. package/lib/components/scrollbar/src/bar.js +35 -22
  351. package/lib/components/scrollbar/src/bar.js.map +1 -1
  352. package/lib/components/scrollbar/src/bar2.js +22 -35
  353. package/lib/components/scrollbar/src/bar2.js.map +1 -1
  354. package/lib/components/scrollbar/src/scrollbar.js +112 -42
  355. package/lib/components/scrollbar/src/scrollbar.js.map +1 -1
  356. package/lib/components/scrollbar/src/scrollbar2.js +42 -112
  357. package/lib/components/scrollbar/src/scrollbar2.js.map +1 -1
  358. package/lib/components/select/index.d.ts +4 -4
  359. package/lib/components/select/src/select.vue.d.ts +4 -4
  360. package/lib/components/select-v2/index.d.ts +10 -10
  361. package/lib/components/select-v2/src/select.vue.d.ts +5 -5
  362. package/lib/components/skeleton/index.js +4 -4
  363. package/lib/components/skeleton/src/skeleton-item.js +18 -23
  364. package/lib/components/skeleton/src/skeleton-item.js.map +1 -1
  365. package/lib/components/skeleton/src/skeleton-item2.js +23 -18
  366. package/lib/components/skeleton/src/skeleton-item2.js.map +1 -1
  367. package/lib/components/skeleton/src/skeleton.js +22 -49
  368. package/lib/components/skeleton/src/skeleton.js.map +1 -1
  369. package/lib/components/skeleton/src/skeleton2.js +49 -22
  370. package/lib/components/skeleton/src/skeleton2.js.map +1 -1
  371. package/lib/components/tabs/index.js +3 -3
  372. package/lib/components/tabs/src/tab-bar.js +7 -76
  373. package/lib/components/tabs/src/tab-bar.js.map +1 -1
  374. package/lib/components/tabs/src/tab-bar2.js +76 -7
  375. package/lib/components/tabs/src/tab-bar2.js.map +1 -1
  376. package/lib/components/tabs/src/tab-nav.js +1 -1
  377. package/lib/components/tabs/src/tab-pane.js +14 -60
  378. package/lib/components/tabs/src/tab-pane.js.map +1 -1
  379. package/lib/components/tabs/src/tab-pane2.js +60 -14
  380. package/lib/components/tabs/src/tab-pane2.js.map +1 -1
  381. package/lib/components/timeline/index.js +2 -2
  382. package/lib/components/timeline/src/timeline-item.js +39 -73
  383. package/lib/components/timeline/src/timeline-item.js.map +1 -1
  384. package/lib/components/timeline/src/timeline-item2.js +73 -39
  385. package/lib/components/timeline/src/timeline-item2.js.map +1 -1
  386. package/lib/components/tooltip/src/tooltip2.js +1 -1
  387. package/lib/components/tooltip-v2/index.js +1 -1
  388. package/lib/components/tooltip-v2/src/content.js +113 -50
  389. package/lib/components/tooltip-v2/src/content.js.map +1 -1
  390. package/lib/components/tooltip-v2/src/content2.js +50 -113
  391. package/lib/components/tooltip-v2/src/content2.js.map +1 -1
  392. package/lib/components/tooltip-v2/src/tooltip.js +1 -1
  393. package/lib/components/tooltip-v2/src/tooltip2.js +2 -2
  394. package/lib/components/upload/index.js +3 -3
  395. package/lib/components/upload/src/upload-content.js +15 -46
  396. package/lib/components/upload/src/upload-content.js.map +1 -1
  397. package/lib/components/upload/src/upload-content2.js +46 -15
  398. package/lib/components/upload/src/upload-content2.js.map +1 -1
  399. package/lib/components/upload/src/upload-list2.js +1 -1
  400. package/lib/components/upload/src/upload.js +109 -99
  401. package/lib/components/upload/src/upload.js.map +1 -1
  402. package/lib/components/upload/src/upload2.js +99 -109
  403. package/lib/components/upload/src/upload2.js.map +1 -1
  404. package/lib/index.js +35 -35
  405. package/package.json +5 -3
  406. package/web-types.json +1 -1
@@ -1,64 +1,100 @@
1
- import { NOOP } from '@vue/shared';
1
+ import { defineComponent, useAttrs as useAttrs$1, ref, computed, onMounted, resolveComponent, openBlock, createElementBlock, normalizeClass, unref, normalizeStyle, createVNode, mergeProps, createSlots, withCtx, renderSlot } from 'vue';
2
+ import '../../../hooks/index.mjs';
2
3
  import '../../../utils/index.mjs';
3
- import '../../tooltip/index.mjs';
4
- import { buildProps, definePropType } from '../../../utils/vue/props.mjs';
5
- import { useTooltipContentProps } from '../../tooltip/src/tooltip.mjs';
4
+ import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
5
+ import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
6
+ import { useAttrs } from '../../../hooks/use-attrs/index.mjs';
7
+ import { generateId } from '../../../utils/rand.mjs';
8
+ import { isArray } from '@vue/shared';
6
9
 
7
- const autocompleteProps = buildProps({
8
- valueKey: {
9
- type: String,
10
- default: "value"
11
- },
12
- modelValue: {
13
- type: [String, Number],
14
- default: ""
15
- },
16
- debounce: {
17
- type: Number,
18
- default: 300
19
- },
20
- placement: {
21
- type: definePropType(String),
22
- values: [
23
- "top",
24
- "top-start",
25
- "top-end",
26
- "bottom",
27
- "bottom-start",
28
- "bottom-end"
29
- ],
30
- default: "bottom-start"
31
- },
32
- fetchSuggestions: {
33
- type: definePropType([Function, Array]),
34
- default: NOOP
35
- },
36
- popperClass: {
37
- type: String,
38
- default: ""
39
- },
40
- triggerOnFocus: {
41
- type: Boolean,
42
- default: true
43
- },
44
- selectWhenUnmatched: {
45
- type: Boolean,
46
- default: false
47
- },
48
- hideLoading: {
49
- type: Boolean,
50
- default: false
51
- },
52
- popperAppendToBody: {
53
- type: Boolean,
54
- default: void 0
55
- },
56
- teleported: useTooltipContentProps.teleported,
57
- highlightFirstItem: {
58
- type: Boolean,
59
- default: false
10
+ const _hoisted_1 = ["aria-expanded", "aria-owns"];
11
+ const __default__ = {
12
+ name: "PsAutocomplete",
13
+ inheritAttrs: false
14
+ };
15
+ const _sfc_main = /* @__PURE__ */ defineComponent({
16
+ ...__default__,
17
+ setup(__props, { expose }) {
18
+ const COMPONENT_NAME = "PsAutocomplete";
19
+ const ns = useNamespace("autocomplete");
20
+ const attrs = useAttrs();
21
+ const compAttrs = useAttrs$1();
22
+ const suggestions = ref([]);
23
+ const highlightedIndex = ref(-1);
24
+ const activated = ref(false);
25
+ const loading = ref(false);
26
+ const inputRef = ref();
27
+ const popperRef = ref();
28
+ const listboxRef = ref();
29
+ const id = computed(() => {
30
+ return ns.b(String(generateId()));
31
+ });
32
+ const styles = computed(() => compAttrs.style);
33
+ const suggestionVisible = computed(() => {
34
+ const isValidData = isArray(suggestions.value) && suggestions.value.length > 0;
35
+ return (isValidData || loading.value) && activated.value;
36
+ });
37
+ onMounted(() => {
38
+ ;
39
+ inputRef.value.ref.setAttribute("role", "textbox");
40
+ inputRef.value.ref.setAttribute("aria-autocomplete", "list");
41
+ inputRef.value.ref.setAttribute("aria-controls", "id");
42
+ inputRef.value.ref.setAttribute("aria-activedescendant", `${id.value}-item-${highlightedIndex.value}`);
43
+ });
44
+ expose({
45
+ highlightedIndex,
46
+ activated,
47
+ loading,
48
+ inputRef,
49
+ popperRef,
50
+ suggestions
51
+ });
52
+ return (_ctx, _cache) => {
53
+ const _component_ps_input = resolveComponent("ps-input");
54
+ return openBlock(), createElementBlock("div", {
55
+ ref_key: "listboxRef",
56
+ ref: listboxRef,
57
+ class: normalizeClass([unref(ns).b(), _ctx.$attrs.class]),
58
+ style: normalizeStyle(unref(styles)),
59
+ role: "combobox",
60
+ "aria-haspopup": "listbox",
61
+ "aria-expanded": unref(suggestionVisible),
62
+ "aria-owns": unref(id)
63
+ }, [
64
+ createVNode(_component_ps_input, mergeProps({
65
+ ref_key: "inputRef",
66
+ ref: inputRef
67
+ }, unref(attrs), { "model-value": _ctx.modelValue }), createSlots({ _: 2 }, [
68
+ _ctx.$slots.prepend ? {
69
+ name: "prepend",
70
+ fn: withCtx(() => [
71
+ renderSlot(_ctx.$slots, "prepend")
72
+ ])
73
+ } : void 0,
74
+ _ctx.$slots.append ? {
75
+ name: "append",
76
+ fn: withCtx(() => [
77
+ renderSlot(_ctx.$slots, "append")
78
+ ])
79
+ } : void 0,
80
+ _ctx.$slots.prefix ? {
81
+ name: "prefix",
82
+ fn: withCtx(() => [
83
+ renderSlot(_ctx.$slots, "prefix")
84
+ ])
85
+ } : void 0,
86
+ _ctx.$slots.suffix ? {
87
+ name: "suffix",
88
+ fn: withCtx(() => [
89
+ renderSlot(_ctx.$slots, "suffix")
90
+ ])
91
+ } : void 0
92
+ ]), 1040, ["model-value"])
93
+ ], 14, _hoisted_1);
94
+ };
60
95
  }
61
96
  });
97
+ var Autocomplete = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "/Users/meng/workspace/element-ps/packages/components/autocomplete/src/autocomplete.vue"]]);
62
98
 
63
- export { autocompleteProps };
99
+ export { Autocomplete as default };
64
100
  //# sourceMappingURL=autocomplete2.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"autocomplete2.mjs","sources":["../../../../../../packages/components/autocomplete/src/autocomplete.ts"],"sourcesContent":["import { NOOP } from '@vue/shared'\nimport {\n buildProps,\n definePropType,\n} from '@element-ps/utils'\nimport { useTooltipContentProps } from '@element-ps/components/tooltip'\nimport type { ExtractPropTypes } from 'vue'\nimport type Autocomplete from './autocomplete.vue'\nimport type { Placement } from '@element-ps/components/popper'\n\nexport const autocompleteProps = buildProps({\n valueKey: {\n type: String,\n default: 'value',\n },\n modelValue: {\n type: [String, Number],\n default: '',\n },\n debounce: {\n type: Number,\n default: 300,\n },\n placement: {\n type: definePropType<Placement>(String),\n values: [\n 'top',\n 'top-start',\n 'top-end',\n 'bottom',\n 'bottom-start',\n 'bottom-end',\n ],\n default: 'bottom-start',\n },\n fetchSuggestions: {\n type: definePropType<\n | ((\n queryString: string,\n cb: (data: { value: string }[]) => void\n ) => { value: string }[] | Promise<{ value: string }[]> | void)\n | { value: string }[]\n >([Function, Array]),\n default: NOOP,\n },\n popperClass: {\n type: String,\n default: '',\n },\n triggerOnFocus: {\n type: Boolean,\n default: true,\n },\n selectWhenUnmatched: {\n type: Boolean,\n default: false,\n },\n hideLoading: {\n type: Boolean,\n default: false,\n },\n popperAppendToBody: {\n type: Boolean,\n default: undefined,\n },\n teleported: useTooltipContentProps.teleported,\n highlightFirstItem: {\n type: Boolean,\n default: false,\n },\n} as const)\nexport type AutocompleteProps = ExtractPropTypes<typeof autocompleteProps>\n\nexport type AutocompleteInstance = InstanceType<typeof Autocomplete>\n"],"names":[],"mappings":";;;;;;AAMY,MAAC,iBAAiB,GAAG,UAAU,CAAC;AAC5C,EAAE,QAAQ,EAAE;AACZ,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,OAAO;AACpB,GAAG;AACH,EAAE,UAAU,EAAE;AACd,IAAI,IAAI,EAAE,CAAC,MAAM,EAAE,MAAM,CAAC;AAC1B,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,QAAQ,EAAE;AACZ,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,GAAG;AAChB,GAAG;AACH,EAAE,SAAS,EAAE;AACb,IAAI,IAAI,EAAE,cAAc,CAAC,MAAM,CAAC;AAChC,IAAI,MAAM,EAAE;AACZ,MAAM,KAAK;AACX,MAAM,WAAW;AACjB,MAAM,SAAS;AACf,MAAM,QAAQ;AACd,MAAM,cAAc;AACpB,MAAM,YAAY;AAClB,KAAK;AACL,IAAI,OAAO,EAAE,cAAc;AAC3B,GAAG;AACH,EAAE,gBAAgB,EAAE;AACpB,IAAI,IAAI,EAAE,cAAc,CAAC,CAAC,QAAQ,EAAE,KAAK,CAAC,CAAC;AAC3C,IAAI,OAAO,EAAE,IAAI;AACjB,GAAG;AACH,EAAE,WAAW,EAAE;AACf,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,cAAc,EAAE;AAClB,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,IAAI;AACjB,GAAG;AACH,EAAE,mBAAmB,EAAE;AACvB,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,KAAK;AAClB,GAAG;AACH,EAAE,WAAW,EAAE;AACf,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,KAAK;AAClB,GAAG;AACH,EAAE,kBAAkB,EAAE;AACtB,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,KAAK,CAAC;AACnB,GAAG;AACH,EAAE,UAAU,EAAE,sBAAsB,CAAC,UAAU;AAC/C,EAAE,kBAAkB,EAAE;AACtB,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,KAAK;AAClB,GAAG;AACH,CAAC;;;;"}
1
+ {"version":3,"file":"autocomplete2.mjs","sources":["../../../../../../packages/components/autocomplete/src/autocomplete.vue"],"sourcesContent":["<template>\n <div\n ref=\"listboxRef\"\n :class=\"[ns.b(), $attrs.class]\"\n :style=\"styles\"\n role=\"combobox\"\n aria-haspopup=\"listbox\"\n :aria-expanded=\"suggestionVisible\"\n :aria-owns=\"id\"\n >\n <ps-input\n ref=\"inputRef\"\n v-bind=\"attrs\"\n :model-value=\"modelValue\"\n >\n <template v-if=\"$slots.prepend\" #prepend>\n <slot name=\"prepend\" />\n </template>\n <template v-if=\"$slots.append\" #append>\n <slot name=\"append\" />\n </template>\n <template v-if=\"$slots.prefix\" #prefix>\n <slot name=\"prefix\" />\n </template>\n <template v-if=\"$slots.suffix\" #suffix>\n <slot name=\"suffix\" />\n </template>\n </ps-input>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport {\n computed,\n onMounted,\n ref,\n useAttrs as useCompAttrs,\n} from 'vue'\nimport { useAttrs, useNamespace } from '@element-ps/hooks'\nimport { generateId, isArray } from '@element-ps/utils'\nimport type { StyleValue } from 'vue'\nimport type { TooltipInstance } from '@element-ps/components/tooltip'\nimport type { InputInstance } from '@element-ps/components/input'\n\ndefineOptions({\n name: 'PsAutocomplete',\n inheritAttrs: false,\n})\n\nconst COMPONENT_NAME = 'PsAutocomplete'\nconst ns = useNamespace('autocomplete')\n\nconst attrs = useAttrs()\nconst compAttrs = useCompAttrs()\nconst suggestions = ref<any[]>([])\nconst highlightedIndex = ref(-1)\nconst activated = ref(false)\nconst loading = ref(false)\nconst inputRef = ref<InputInstance>()\nconst popperRef = ref<TooltipInstance>()\nconst listboxRef = ref<HTMLElement>()\n\nconst id = computed(() => {\n return ns.b(String(generateId()))\n})\nconst styles = computed(() => compAttrs.style as StyleValue)\nconst suggestionVisible = computed(() => {\n const isValidData = isArray(suggestions.value) && suggestions.value.length > 0\n return (isValidData || loading.value) && activated.value\n})\n\nonMounted(() => {\n // TODO: use Volar generate dts to fix it.\n ;(inputRef.value as any).ref!.setAttribute('role', 'textbox')\n ;(inputRef.value as any).ref!.setAttribute('aria-autocomplete', 'list')\n ;(inputRef.value as any).ref!.setAttribute('aria-controls', 'id')\n ;(inputRef.value as any).ref!.setAttribute(\n 'aria-activedescendant',\n `${id.value}-item-${highlightedIndex.value}`\n )\n})\n\ndefineExpose({\n /** @description the index of the currently highlighted item */\n highlightedIndex,\n /** @description autocomplete whether activated */\n activated,\n /** @description remote search loading status */\n loading,\n /** @description el-input component instance */\n inputRef,\n /** @description el-tooltip component instance */\n popperRef,\n /** @description fetch suggestions result */\n suggestions,\n})\n</script>\n"],"names":["useCompAttrs"],"mappings":";;;;;;;;;;;;;;;;;AAiDA,IAAA,MAAA,cAAA,GAAA,gBAAA,CAAA;AACA,IAAA,MAAA,EAAA,GAAA,aAAA,cAAA,CAAA,CAAA;AAEA,IAAA,MAAA,QAAA,QAAA,EAAA,CAAA;AACA,IAAA,MAAA,YAAAA,UAAA,EAAA,CAAA;AACA,IAAA,MAAA,WAAA,GAAA,GAAA,CAAA,EAAA,CAAA,CAAA;AACA,IAAA,MAAA,gBAAA,GAAA,IAAA,CAAA,CAAA,CAAA,CAAA;AACA,IAAA,MAAA,SAAA,GAAA,IAAA,KAAA,CAAA,CAAA;AACA,IAAA,MAAA,OAAA,GAAA,IAAA,KAAA,CAAA,CAAA;AACA,IAAA,MAAA,WAAA,GAAA,EAAA,CAAA;AACA,IAAA,MAAA,YAAA,GAAA,EAAA,CAAA;AACA,IAAA,MAAA,aAAA,GAAA,EAAA,CAAA;AAEA,IAAA,MAAA,EAAA,GAAA,SAAA,MAAA;AACA,MAAA,OAAA,EAAA,CAAA,CAAA,CAAA,MAAA,CAAA,UAAA,EAAA,CAAA,CAAA,CAAA;AAAA,KACA,CAAA,CAAA;AACA,IAAA,MAAA,MAAA,GAAA,QAAA,CAAA,MAAA,SAAA,CAAA,KAAA,CAAA,CAAA;AACA,IAAA,MAAA,iBAAA,GAAA,SAAA,MAAA;AACA,MAAA,MAAA,cAAA,OAAA,CAAA,WAAA,CAAA,KAAA,CAAA,IAAA,WAAA,CAAA,MAAA,MAAA,GAAA,CAAA,CAAA;AACA,MAAA,OAAA,CAAA,WAAA,IAAA,OAAA,CAAA,KAAA,KAAA,SAAA,CAAA,KAAA,CAAA;AAAA,KACA,CAAA,CAAA;AAEA,IAAA,SAAA,CAAA,MAAA;AAEA,MAAA,CAAA;AAAA,MAAA,QAAA,CAAA,KAAA,CAAA,GAAA,CAAA,YAAA,CAAA,QAAA,SAAA,CAAA,CAAA;AACA,MAAA,QAAA,CAAA,KAAA,CAAA,GAAA,CAAA,YAAA,CAAA,qBAAA,MAAA,CAAA,CAAA;AACA,MAAA,QAAA,CAAA,KAAA,CAAA,GAAA,CAAA,YAAA,CAAA,iBAAA,IAAA,CAAA,CAAA;AACA,MAAA,QAAA,CAAA,MAAA,GAAA,CAAA,YAAA,CACA,yBACA,CAAA,EAAA,EAAA,CAAA,KAAA,CAAA,MAAA,EAAA,gBAAA,CAAA,KACA,CAAA,CAAA,CAAA,CAAA;AAAA,KACA,CAAA,CAAA;AAEA,IAAA,MAAA,CAAA;AAAA,MAEA,gBAAA;AAAA,MAEA,SAAA;AAAA,MAEA,OAAA;AAAA,MAEA,QAAA;AAAA,MAEA,SAAA;AAAA,MAEA,WAAA;AAAA,KACA,CAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,6 +1,6 @@
1
1
  import '../../utils/index.mjs';
2
- import Backtop from './src/backtop.mjs';
3
- export { backtopProps } from './src/backtop2.mjs';
2
+ import Backtop from './src/backtop2.mjs';
3
+ export { backtopProps } from './src/backtop.mjs';
4
4
  import { withInstall } from '../../utils/vue/install.mjs';
5
5
 
6
6
  const PsBacktop = withInstall(Backtop);
@@ -1,62 +1,21 @@
1
- import { defineComponent, shallowRef, ref, computed, onMounted, openBlock, createElementBlock, normalizeStyle, unref, normalizeClass, renderSlot, createVNode, withCtx } from 'vue';
2
- import { PsIcon } from '../../icon/index.mjs';
3
- import '../../../utils/index.mjs';
4
- import { CaretTop } from '@element-plus/icons-vue';
5
- import '../../../hooks/index.mjs';
6
- import { backtopProps } from './backtop2.mjs';
7
- import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
8
- import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
9
- import { throwError } from '../../../utils/error.mjs';
10
-
11
- const __default__ = {
12
- name: "PsBacktop"
13
- };
14
- const _sfc_main = /* @__PURE__ */ defineComponent({
15
- ...__default__,
16
- props: backtopProps,
17
- setup(__props) {
18
- const props = __props;
19
- const COMPONENT_NAME = "PsBacktop";
20
- const ns = useNamespace("backtop");
21
- const el = shallowRef();
22
- const container = shallowRef();
23
- const visible = ref(false);
24
- const backTopStyle = computed(() => ({
25
- right: `${props.right}px`,
26
- bottom: `${props.bottom}px`
27
- }));
28
- onMounted(() => {
29
- var _a;
30
- container.value = document;
31
- el.value = document.documentElement;
32
- if (props.target) {
33
- el.value = (_a = document.querySelector(props.target)) != null ? _a : void 0;
34
- if (!el.value) {
35
- throwError(COMPONENT_NAME, `target is not existed: ${props.target}`);
36
- }
37
- container.value = el.value;
38
- }
39
- });
40
- return (_ctx, _cache) => {
41
- return openBlock(), createElementBlock("div", {
42
- style: normalizeStyle(unref(backTopStyle)),
43
- class: normalizeClass(unref(ns).b())
44
- }, [
45
- renderSlot(_ctx.$slots, "default", {}, () => [
46
- createVNode(unref(PsIcon), {
47
- class: normalizeClass(unref(ns).e("icon"))
48
- }, {
49
- default: withCtx(() => [
50
- createVNode(unref(CaretTop))
51
- ]),
52
- _: 1
53
- }, 8, ["class"])
54
- ])
55
- ], 6);
56
- };
1
+ const backtopProps = {
2
+ visibilityHeight: {
3
+ type: Number,
4
+ default: 200
5
+ },
6
+ target: {
7
+ type: String,
8
+ default: ""
9
+ },
10
+ right: {
11
+ type: Number,
12
+ default: 40
13
+ },
14
+ bottom: {
15
+ type: Number,
16
+ default: 40
57
17
  }
58
- });
59
- var Backtop = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "/Users/meng/workspace/element-ps/packages/components/backtop/src/backtop.vue"]]);
18
+ };
60
19
 
61
- export { Backtop as default };
20
+ export { backtopProps };
62
21
  //# sourceMappingURL=backtop.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"backtop.mjs","sources":["../../../../../../packages/components/backtop/src/backtop.vue"],"sourcesContent":["<template>\n <div\n :style=\"backTopStyle\"\n :class=\"ns.b()\"\n >\n <slot>\n <ps-icon :class=\"ns.e('icon')\"><caret-top /></ps-icon>\n </slot>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed, onMounted, ref, shallowRef } from 'vue'\nimport { PsIcon } from '@element-ps/components/icon'\nimport { throwError } from '@element-ps/utils'\nimport { CaretTop } from '@element-plus/icons-vue'\nimport { useNamespace } from '@element-ps/hooks'\n\nimport { backtopProps } from './backtop'\n\nconst COMPONENT_NAME = 'PsBacktop'\n\ndefineOptions({\n name: 'PsBacktop',\n})\n\nconst props = defineProps(backtopProps)\n\nconst ns = useNamespace('backtop')\nconst el = shallowRef<HTMLElement>()\nconst container = shallowRef<Document | HTMLElement>()\nconst visible = ref(false)\n\nconst backTopStyle = computed(() => ({\n right: `${props.right}px`,\n bottom: `${props.bottom}px`,\n}))\n\nonMounted(() => {\n container.value = document\n el.value = document.documentElement\n\n if (props.target) {\n el.value = document.querySelector<HTMLElement>(props.target) ?? undefined\n if (!el.value) {\n throwError(COMPONENT_NAME, `target is not existed: ${props.target}`)\n }\n container.value = el.value\n }\n})\n</script>\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAoBA,IAAA,MAAA,cAAA,GAAA,WAAA,CAAA;AAQA,IAAA,MAAA,EAAA,GAAA,aAAA,SAAA,CAAA,CAAA;AACA,IAAA,MAAA,KAAA,UAAA,EAAA,CAAA;AACA,IAAA,MAAA,YAAA,UAAA,EAAA,CAAA;AACA,IAAA,MAAA,OAAA,GAAA,IAAA,KAAA,CAAA,CAAA;AAEA,IAAA,MAAA,YAAA,GAAA,SAAA,OAAA;AAAA,MACA,KAAA,EAAA,GAAA,KAAA,CAAA,KAAA,CAAA,EAAA,CAAA;AAAA,MACA,MAAA,EAAA,GAAA,KAAA,CAAA,MAAA,CAAA,EAAA,CAAA;AAAA,KACA,CAAA,CAAA,CAAA;AAEA,IAAA,SAAA,CAAA,MAAA;AACA,MAAA,IAAA,EAAA,CAAA;AACA,MAAA,eAAA,GAAA,QAAA,CAAA;AAEA,MAAA,EAAA,CAAA,QAAA,QAAA,CAAA,eAAA,CAAA;AACA,MAAA,IAAA,KAAA,CAAA,MAAA,EAAA;AACA,QAAA,EAAA,CAAA,KAAA,GAAA,CAAA,EAAA,GAAA,QAAA,CAAA,aAAA,CAAA,KAAA,CAAA,MAAA,CAAA,KAAA,IAAA,GAAA,EAAA,GAAA,KAAA,CAAA,CAAA;AACA,QAAA,IAAA,CAAA,EAAA,CAAA,KAAA,EAAA;AAAA,UACA,UAAA,CAAA,cAAA,EAAA,CAAA,uBAAA,EAAA,KAAA,CAAA,MAAA,CAAA,CAAA,CAAA,CAAA;AACA,SAAA;AAAA,QACA,SAAA,CAAA,KAAA,GAAA,EAAA,CAAA,KAAA,CAAA;AAAA,OACA;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"backtop.mjs","sources":["../../../../../../packages/components/backtop/src/backtop.ts"],"sourcesContent":["import type { ExtractPropTypes } from 'vue'\n\nexport const backtopProps = {\n visibilityHeight: {\n type: Number,\n default: 200,\n },\n target: {\n type: String,\n default: '',\n },\n right: {\n type: Number,\n default: 40,\n },\n bottom: {\n type: Number,\n default: 40,\n },\n} as const\nexport type BacktopProps = ExtractPropTypes<typeof backtopProps>\n"],"names":[],"mappings":"AAAY,MAAC,YAAY,GAAG;AAC5B,EAAE,gBAAgB,EAAE;AACpB,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,GAAG;AAChB,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,KAAK,EAAE;AACT,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH;;;;"}
@@ -1,21 +1,62 @@
1
- const backtopProps = {
2
- visibilityHeight: {
3
- type: Number,
4
- default: 200
5
- },
6
- target: {
7
- type: String,
8
- default: ""
9
- },
10
- right: {
11
- type: Number,
12
- default: 40
13
- },
14
- bottom: {
15
- type: Number,
16
- default: 40
17
- }
1
+ import { defineComponent, shallowRef, ref, computed, onMounted, openBlock, createElementBlock, normalizeStyle, unref, normalizeClass, renderSlot, createVNode, withCtx } from 'vue';
2
+ import { PsIcon } from '../../icon/index.mjs';
3
+ import '../../../utils/index.mjs';
4
+ import { CaretTop } from '@element-plus/icons-vue';
5
+ import '../../../hooks/index.mjs';
6
+ import { backtopProps } from './backtop.mjs';
7
+ import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
8
+ import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
9
+ import { throwError } from '../../../utils/error.mjs';
10
+
11
+ const __default__ = {
12
+ name: "PsBacktop"
18
13
  };
14
+ const _sfc_main = /* @__PURE__ */ defineComponent({
15
+ ...__default__,
16
+ props: backtopProps,
17
+ setup(__props) {
18
+ const props = __props;
19
+ const COMPONENT_NAME = "PsBacktop";
20
+ const ns = useNamespace("backtop");
21
+ const el = shallowRef();
22
+ const container = shallowRef();
23
+ const visible = ref(false);
24
+ const backTopStyle = computed(() => ({
25
+ right: `${props.right}px`,
26
+ bottom: `${props.bottom}px`
27
+ }));
28
+ onMounted(() => {
29
+ var _a;
30
+ container.value = document;
31
+ el.value = document.documentElement;
32
+ if (props.target) {
33
+ el.value = (_a = document.querySelector(props.target)) != null ? _a : void 0;
34
+ if (!el.value) {
35
+ throwError(COMPONENT_NAME, `target is not existed: ${props.target}`);
36
+ }
37
+ container.value = el.value;
38
+ }
39
+ });
40
+ return (_ctx, _cache) => {
41
+ return openBlock(), createElementBlock("div", {
42
+ style: normalizeStyle(unref(backTopStyle)),
43
+ class: normalizeClass(unref(ns).b())
44
+ }, [
45
+ renderSlot(_ctx.$slots, "default", {}, () => [
46
+ createVNode(unref(PsIcon), {
47
+ class: normalizeClass(unref(ns).e("icon"))
48
+ }, {
49
+ default: withCtx(() => [
50
+ createVNode(unref(CaretTop))
51
+ ]),
52
+ _: 1
53
+ }, 8, ["class"])
54
+ ])
55
+ ], 6);
56
+ };
57
+ }
58
+ });
59
+ var Backtop = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "/Users/meng/workspace/element-ps/packages/components/backtop/src/backtop.vue"]]);
19
60
 
20
- export { backtopProps };
61
+ export { Backtop as default };
21
62
  //# sourceMappingURL=backtop2.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"backtop2.mjs","sources":["../../../../../../packages/components/backtop/src/backtop.ts"],"sourcesContent":["import type { ExtractPropTypes } from 'vue'\n\nexport const backtopProps = {\n visibilityHeight: {\n type: Number,\n default: 200,\n },\n target: {\n type: String,\n default: '',\n },\n right: {\n type: Number,\n default: 40,\n },\n bottom: {\n type: Number,\n default: 40,\n },\n} as const\nexport type BacktopProps = ExtractPropTypes<typeof backtopProps>\n"],"names":[],"mappings":"AAAY,MAAC,YAAY,GAAG;AAC5B,EAAE,gBAAgB,EAAE;AACpB,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,GAAG;AAChB,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,KAAK,EAAE;AACT,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,MAAM,EAAE;AACV,IAAI,IAAI,EAAE,MAAM;AAChB,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH;;;;"}
1
+ {"version":3,"file":"backtop2.mjs","sources":["../../../../../../packages/components/backtop/src/backtop.vue"],"sourcesContent":["<template>\n <div\n :style=\"backTopStyle\"\n :class=\"ns.b()\"\n >\n <slot>\n <ps-icon :class=\"ns.e('icon')\"><caret-top /></ps-icon>\n </slot>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport { computed, onMounted, ref, shallowRef } from 'vue'\nimport { PsIcon } from '@element-ps/components/icon'\nimport { throwError } from '@element-ps/utils'\nimport { CaretTop } from '@element-plus/icons-vue'\nimport { useNamespace } from '@element-ps/hooks'\n\nimport { backtopProps } from './backtop'\n\nconst COMPONENT_NAME = 'PsBacktop'\n\ndefineOptions({\n name: 'PsBacktop',\n})\n\nconst props = defineProps(backtopProps)\n\nconst ns = useNamespace('backtop')\nconst el = shallowRef<HTMLElement>()\nconst container = shallowRef<Document | HTMLElement>()\nconst visible = ref(false)\n\nconst backTopStyle = computed(() => ({\n right: `${props.right}px`,\n bottom: `${props.bottom}px`,\n}))\n\nonMounted(() => {\n container.value = document\n el.value = document.documentElement\n\n if (props.target) {\n el.value = document.querySelector<HTMLElement>(props.target) ?? undefined\n if (!el.value) {\n throwError(COMPONENT_NAME, `target is not existed: ${props.target}`)\n }\n container.value = el.value\n }\n})\n</script>\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;AAoBA,IAAA,MAAA,cAAA,GAAA,WAAA,CAAA;AAQA,IAAA,MAAA,EAAA,GAAA,aAAA,SAAA,CAAA,CAAA;AACA,IAAA,MAAA,KAAA,UAAA,EAAA,CAAA;AACA,IAAA,MAAA,YAAA,UAAA,EAAA,CAAA;AACA,IAAA,MAAA,OAAA,GAAA,IAAA,KAAA,CAAA,CAAA;AAEA,IAAA,MAAA,YAAA,GAAA,SAAA,OAAA;AAAA,MACA,KAAA,EAAA,GAAA,KAAA,CAAA,KAAA,CAAA,EAAA,CAAA;AAAA,MACA,MAAA,EAAA,GAAA,KAAA,CAAA,MAAA,CAAA,EAAA,CAAA;AAAA,KACA,CAAA,CAAA,CAAA;AAEA,IAAA,SAAA,CAAA,MAAA;AACA,MAAA,IAAA,EAAA,CAAA;AACA,MAAA,eAAA,GAAA,QAAA,CAAA;AAEA,MAAA,EAAA,CAAA,QAAA,QAAA,CAAA,eAAA,CAAA;AACA,MAAA,IAAA,KAAA,CAAA,MAAA,EAAA;AACA,QAAA,EAAA,CAAA,KAAA,GAAA,CAAA,EAAA,GAAA,QAAA,CAAA,aAAA,CAAA,KAAA,CAAA,MAAA,CAAA,KAAA,IAAA,GAAA,EAAA,GAAA,KAAA,CAAA,CAAA;AACA,QAAA,IAAA,CAAA,EAAA,CAAA,KAAA,EAAA;AAAA,UACA,UAAA,CAAA,cAAA,EAAA,CAAA,uBAAA,EAAA,KAAA,CAAA,MAAA,CAAA,CAAA,CAAA,CAAA;AACA,SAAA;AAAA,QACA,SAAA,CAAA,KAAA,GAAA,EAAA,CAAA,KAAA,CAAA;AAAA,OACA;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,8 +1,8 @@
1
1
  import '../../utils/index.mjs';
2
- import Breadcrumb from './src/breadcrumb2.mjs';
3
- import BreadcrumbItem from './src/breadcrumb-item2.mjs';
4
- export { breadcrumbProps } from './src/breadcrumb.mjs';
5
- export { breadcrumbItemProps } from './src/breadcrumb-item.mjs';
2
+ import Breadcrumb from './src/breadcrumb.mjs';
3
+ import BreadcrumbItem from './src/breadcrumb-item.mjs';
4
+ export { breadcrumbProps } from './src/breadcrumb2.mjs';
5
+ export { breadcrumbItemProps } from './src/breadcrumb-item2.mjs';
6
6
  import { withInstall, withNoopInstall } from '../../utils/vue/install.mjs';
7
7
 
8
8
  const PsBreadcrumb = withInstall(Breadcrumb, {
@@ -1,16 +1,51 @@
1
- import '../../../utils/index.mjs';
2
- import { buildProps, definePropType } from '../../../utils/vue/props.mjs';
1
+ import { defineComponent, inject, ref, openBlock, createElementBlock, normalizeClass, unref, createElementVNode, renderSlot, createBlock, withCtx, resolveDynamicComponent, toDisplayString } from 'vue';
2
+ import { PsIcon } from '../../icon/index.mjs';
3
+ import '../../../tokens/index.mjs';
4
+ import '../../../hooks/index.mjs';
5
+ import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
6
+ import { breadcrumbKey } from '../../../tokens/breadcrumb.mjs';
7
+ import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
3
8
 
4
- const breadcrumbItemProps = buildProps({
5
- to: {
6
- type: definePropType([String, Object]),
7
- default: ""
8
- },
9
- replace: {
10
- type: Boolean,
11
- default: false
9
+ const __default__ = {
10
+ name: "PsBreadcrumbItem"
11
+ };
12
+ const _sfc_main = /* @__PURE__ */ defineComponent({
13
+ ...__default__,
14
+ setup(__props) {
15
+ const breadcrumbInjection = inject(breadcrumbKey, {});
16
+ const ns = useNamespace("breadcrumb");
17
+ const { separator, separatorIcon } = breadcrumbInjection;
18
+ const link = ref();
19
+ return (_ctx, _cache) => {
20
+ return openBlock(), createElementBlock("span", {
21
+ class: normalizeClass(unref(ns).e("item"))
22
+ }, [
23
+ createElementVNode("span", {
24
+ ref_key: "link",
25
+ ref: link,
26
+ class: normalizeClass([unref(ns).e("inner"), unref(ns).is("link", !!_ctx.to)]),
27
+ role: "link"
28
+ }, [
29
+ renderSlot(_ctx.$slots, "default")
30
+ ], 2),
31
+ unref(separatorIcon) ? (openBlock(), createBlock(unref(PsIcon), {
32
+ key: 0,
33
+ class: normalizeClass(unref(ns).e("separator"))
34
+ }, {
35
+ default: withCtx(() => [
36
+ (openBlock(), createBlock(resolveDynamicComponent(unref(separatorIcon))))
37
+ ]),
38
+ _: 1
39
+ }, 8, ["class"])) : (openBlock(), createElementBlock("span", {
40
+ key: 1,
41
+ class: normalizeClass(unref(ns).e("separator")),
42
+ role: "presentation"
43
+ }, toDisplayString(unref(separator)), 3))
44
+ ], 2);
45
+ };
12
46
  }
13
47
  });
48
+ var BreadcrumbItem = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "/Users/meng/workspace/element-ps/packages/components/breadcrumb/src/breadcrumb-item.vue"]]);
14
49
 
15
- export { breadcrumbItemProps };
50
+ export { BreadcrumbItem as default };
16
51
  //# sourceMappingURL=breadcrumb-item.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"breadcrumb-item.mjs","sources":["../../../../../../packages/components/breadcrumb/src/breadcrumb-item.ts"],"sourcesContent":["import { buildProps, definePropType } from '@element-ps/utils'\nimport type { ExtractPropTypes } from 'vue'\nimport type { RouteLocationRaw } from 'vue-router'\nimport type BreadcrumbItem from './breadcrumb-item.vue'\n\nexport const breadcrumbItemProps = buildProps({\n to: {\n type: definePropType<RouteLocationRaw>([String, Object]),\n default: '',\n },\n replace: {\n type: Boolean,\n default: false,\n },\n} as const)\nexport type BreadcrumbItemProps = ExtractPropTypes<typeof breadcrumbItemProps>\n\nexport type BreadcrumbItemInstance = InstanceType<typeof BreadcrumbItem>\n"],"names":[],"mappings":";;;AACY,MAAC,mBAAmB,GAAG,UAAU,CAAC;AAC9C,EAAE,EAAE,EAAE;AACN,IAAI,IAAI,EAAE,cAAc,CAAC,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;AAC1C,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,OAAO,EAAE;AACX,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,KAAK;AAClB,GAAG;AACH,CAAC;;;;"}
1
+ {"version":3,"file":"breadcrumb-item.mjs","sources":["../../../../../../packages/components/breadcrumb/src/breadcrumb-item.vue"],"sourcesContent":["<template>\n <span :class=\"ns.e('item')\">\n <span\n ref=\"link\"\n :class=\"[ns.e('inner'), ns.is('link', !!to)]\"\n role=\"link\"\n >\n <slot />\n </span>\n <ps-icon v-if=\"separatorIcon\" :class=\"ns.e('separator')\">\n <component :is=\"separatorIcon\" />\n </ps-icon>\n <span v-else :class=\"ns.e('separator')\" role=\"presentation\">\n {{ separator }}\n </span>\n </span>\n</template>\n\n<script lang=\"ts\" setup>\nimport { inject, ref } from 'vue'\nimport PsIcon from '@element-ps/components/icon'\nimport { breadcrumbKey } from '@element-ps/tokens'\nimport { useNamespace } from '@element-ps/hooks'\nimport type { BreadcrumbProps } from './breadcrumb'\n\ndefineOptions({\n name: 'PsBreadcrumbItem',\n})\n\nconst breadcrumbInjection = inject(breadcrumbKey, {} as BreadcrumbProps)!\n\nconst ns = useNamespace('breadcrumb')\n\nconst { separator, separatorIcon } = breadcrumbInjection\n\nconst link = ref<HTMLSpanElement>()\n</script>\n"],"names":[],"mappings":";;;;;;;;;;;;;;AA6BA,IAAA,MAAA,mBAAA,GAAA,MAAA,CAAA,aAAA,EAAA,EAAA,CAAA,CAAA;AAEA,IAAA,MAAA,EAAA,GAAA,aAAA,YAAA,CAAA,CAAA;AAEA,IAAA,MAAA,EAAA,WAAA,aAAA,EAAA,GAAA,mBAAA,CAAA;AAEA,IAAA,MAAA,OAAA,GAAA,EAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,51 +1,16 @@
1
- import { defineComponent, inject, ref, openBlock, createElementBlock, normalizeClass, unref, createElementVNode, renderSlot, createBlock, withCtx, resolveDynamicComponent, toDisplayString } from 'vue';
2
- import { PsIcon } from '../../icon/index.mjs';
3
- import '../../../tokens/index.mjs';
4
- import '../../../hooks/index.mjs';
5
- import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
6
- import { breadcrumbKey } from '../../../tokens/breadcrumb.mjs';
7
- import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
1
+ import '../../../utils/index.mjs';
2
+ import { buildProps, definePropType } from '../../../utils/vue/props.mjs';
8
3
 
9
- const __default__ = {
10
- name: "PsBreadcrumbItem"
11
- };
12
- const _sfc_main = /* @__PURE__ */ defineComponent({
13
- ...__default__,
14
- setup(__props) {
15
- const breadcrumbInjection = inject(breadcrumbKey, {});
16
- const ns = useNamespace("breadcrumb");
17
- const { separator, separatorIcon } = breadcrumbInjection;
18
- const link = ref();
19
- return (_ctx, _cache) => {
20
- return openBlock(), createElementBlock("span", {
21
- class: normalizeClass(unref(ns).e("item"))
22
- }, [
23
- createElementVNode("span", {
24
- ref_key: "link",
25
- ref: link,
26
- class: normalizeClass([unref(ns).e("inner"), unref(ns).is("link", !!_ctx.to)]),
27
- role: "link"
28
- }, [
29
- renderSlot(_ctx.$slots, "default")
30
- ], 2),
31
- unref(separatorIcon) ? (openBlock(), createBlock(unref(PsIcon), {
32
- key: 0,
33
- class: normalizeClass(unref(ns).e("separator"))
34
- }, {
35
- default: withCtx(() => [
36
- (openBlock(), createBlock(resolveDynamicComponent(unref(separatorIcon))))
37
- ]),
38
- _: 1
39
- }, 8, ["class"])) : (openBlock(), createElementBlock("span", {
40
- key: 1,
41
- class: normalizeClass(unref(ns).e("separator")),
42
- role: "presentation"
43
- }, toDisplayString(unref(separator)), 3))
44
- ], 2);
45
- };
4
+ const breadcrumbItemProps = buildProps({
5
+ to: {
6
+ type: definePropType([String, Object]),
7
+ default: ""
8
+ },
9
+ replace: {
10
+ type: Boolean,
11
+ default: false
46
12
  }
47
13
  });
48
- var BreadcrumbItem = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "/Users/meng/workspace/element-ps/packages/components/breadcrumb/src/breadcrumb-item.vue"]]);
49
14
 
50
- export { BreadcrumbItem as default };
15
+ export { breadcrumbItemProps };
51
16
  //# sourceMappingURL=breadcrumb-item2.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"breadcrumb-item2.mjs","sources":["../../../../../../packages/components/breadcrumb/src/breadcrumb-item.vue"],"sourcesContent":["<template>\n <span :class=\"ns.e('item')\">\n <span\n ref=\"link\"\n :class=\"[ns.e('inner'), ns.is('link', !!to)]\"\n role=\"link\"\n >\n <slot />\n </span>\n <ps-icon v-if=\"separatorIcon\" :class=\"ns.e('separator')\">\n <component :is=\"separatorIcon\" />\n </ps-icon>\n <span v-else :class=\"ns.e('separator')\" role=\"presentation\">\n {{ separator }}\n </span>\n </span>\n</template>\n\n<script lang=\"ts\" setup>\nimport { inject, ref } from 'vue'\nimport PsIcon from '@element-ps/components/icon'\nimport { breadcrumbKey } from '@element-ps/tokens'\nimport { useNamespace } from '@element-ps/hooks'\nimport type { BreadcrumbProps } from './breadcrumb'\n\ndefineOptions({\n name: 'PsBreadcrumbItem',\n})\n\nconst breadcrumbInjection = inject(breadcrumbKey, {} as BreadcrumbProps)!\n\nconst ns = useNamespace('breadcrumb')\n\nconst { separator, separatorIcon } = breadcrumbInjection\n\nconst link = ref<HTMLSpanElement>()\n</script>\n"],"names":[],"mappings":";;;;;;;;;;;;;;AA6BA,IAAA,MAAA,mBAAA,GAAA,MAAA,CAAA,aAAA,EAAA,EAAA,CAAA,CAAA;AAEA,IAAA,MAAA,EAAA,GAAA,aAAA,YAAA,CAAA,CAAA;AAEA,IAAA,MAAA,EAAA,WAAA,aAAA,EAAA,GAAA,mBAAA,CAAA;AAEA,IAAA,MAAA,OAAA,GAAA,EAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"breadcrumb-item2.mjs","sources":["../../../../../../packages/components/breadcrumb/src/breadcrumb-item.ts"],"sourcesContent":["import { buildProps, definePropType } from '@element-ps/utils'\nimport type { ExtractPropTypes } from 'vue'\nimport type { RouteLocationRaw } from 'vue-router'\nimport type BreadcrumbItem from './breadcrumb-item.vue'\n\nexport const breadcrumbItemProps = buildProps({\n to: {\n type: definePropType<RouteLocationRaw>([String, Object]),\n default: '',\n },\n replace: {\n type: Boolean,\n default: false,\n },\n} as const)\nexport type BreadcrumbItemProps = ExtractPropTypes<typeof breadcrumbItemProps>\n\nexport type BreadcrumbItemInstance = InstanceType<typeof BreadcrumbItem>\n"],"names":[],"mappings":";;;AACY,MAAC,mBAAmB,GAAG,UAAU,CAAC;AAC9C,EAAE,EAAE,EAAE;AACN,IAAI,IAAI,EAAE,cAAc,CAAC,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;AAC1C,IAAI,OAAO,EAAE,EAAE;AACf,GAAG;AACH,EAAE,OAAO,EAAE;AACX,IAAI,IAAI,EAAE,OAAO;AACjB,IAAI,OAAO,EAAE,KAAK;AAClB,GAAG;AACH,CAAC;;;;"}
@@ -1,17 +1,42 @@
1
- import '../../../utils/index.mjs';
2
- import { buildProps } from '../../../utils/vue/props.mjs';
3
- import { iconPropType } from '../../../utils/vue/icon.mjs';
1
+ import { defineComponent, ref, provide, onMounted, openBlock, createElementBlock, normalizeClass, unref, renderSlot } from 'vue';
2
+ import '../../../tokens/index.mjs';
3
+ import '../../../hooks/index.mjs';
4
+ import { breadcrumbProps } from './breadcrumb2.mjs';
5
+ import _export_sfc from '../../../_virtual/plugin-vue_export-helper.mjs';
6
+ import { useNamespace } from '../../../hooks/use-namespace/index.mjs';
7
+ import { breadcrumbKey } from '../../../tokens/breadcrumb.mjs';
4
8
 
5
- const breadcrumbProps = buildProps({
6
- separator: {
7
- type: String,
8
- default: "/"
9
- },
10
- separatorIcon: {
11
- type: iconPropType,
12
- default: ""
9
+ const __default__ = {
10
+ name: "PsBreadcrumb"
11
+ };
12
+ const _sfc_main = /* @__PURE__ */ defineComponent({
13
+ ...__default__,
14
+ props: breadcrumbProps,
15
+ setup(__props) {
16
+ const props = __props;
17
+ const ns = useNamespace("breadcrumb");
18
+ const breadcrumb = ref();
19
+ provide(breadcrumbKey, props);
20
+ onMounted(() => {
21
+ const items = breadcrumb.value.querySelectorAll(`.${ns.e("item")}`);
22
+ if (items.length) {
23
+ items[items.length - 1].setAttribute("aria-current", "page");
24
+ }
25
+ });
26
+ return (_ctx, _cache) => {
27
+ return openBlock(), createElementBlock("div", {
28
+ ref_key: "breadcrumb",
29
+ ref: breadcrumb,
30
+ class: normalizeClass(unref(ns).b()),
31
+ "aria-label": "Breadcrumb",
32
+ role: "navigation"
33
+ }, [
34
+ renderSlot(_ctx.$slots, "default")
35
+ ], 2);
36
+ };
13
37
  }
14
38
  });
39
+ var Breadcrumb = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "/Users/meng/workspace/element-ps/packages/components/breadcrumb/src/breadcrumb.vue"]]);
15
40
 
16
- export { breadcrumbProps };
41
+ export { Breadcrumb as default };
17
42
  //# sourceMappingURL=breadcrumb.mjs.map