@element-plus/nightly 0.0.20260308 → 0.0.20260310

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 (649) hide show
  1. package/attributes.json +1 -1
  2. package/dist/index.full.js +366 -264
  3. package/dist/index.full.min.js +9 -9
  4. package/dist/index.full.min.js.map +1 -1
  5. package/dist/index.full.min.mjs +8 -8
  6. package/dist/index.full.min.mjs.map +1 -1
  7. package/dist/index.full.mjs +366 -264
  8. package/dist/locale/af.js +1 -1
  9. package/dist/locale/af.min.js +1 -1
  10. package/dist/locale/af.min.mjs +1 -1
  11. package/dist/locale/af.mjs +1 -1
  12. package/dist/locale/ar-eg.js +1 -1
  13. package/dist/locale/ar-eg.min.js +1 -1
  14. package/dist/locale/ar-eg.min.mjs +1 -1
  15. package/dist/locale/ar-eg.mjs +1 -1
  16. package/dist/locale/ar.js +1 -1
  17. package/dist/locale/ar.min.js +1 -1
  18. package/dist/locale/ar.min.mjs +1 -1
  19. package/dist/locale/ar.mjs +1 -1
  20. package/dist/locale/az.js +1 -1
  21. package/dist/locale/az.min.js +1 -1
  22. package/dist/locale/az.min.mjs +1 -1
  23. package/dist/locale/az.mjs +1 -1
  24. package/dist/locale/bg.js +1 -1
  25. package/dist/locale/bg.min.js +1 -1
  26. package/dist/locale/bg.min.mjs +1 -1
  27. package/dist/locale/bg.mjs +1 -1
  28. package/dist/locale/bn.js +1 -1
  29. package/dist/locale/bn.min.js +1 -1
  30. package/dist/locale/bn.min.mjs +1 -1
  31. package/dist/locale/bn.mjs +1 -1
  32. package/dist/locale/ca.js +1 -1
  33. package/dist/locale/ca.min.js +1 -1
  34. package/dist/locale/ca.min.mjs +1 -1
  35. package/dist/locale/ca.mjs +1 -1
  36. package/dist/locale/ckb.js +1 -1
  37. package/dist/locale/ckb.min.js +1 -1
  38. package/dist/locale/ckb.min.mjs +1 -1
  39. package/dist/locale/ckb.mjs +1 -1
  40. package/dist/locale/cs.js +1 -1
  41. package/dist/locale/cs.min.js +1 -1
  42. package/dist/locale/cs.min.mjs +1 -1
  43. package/dist/locale/cs.mjs +1 -1
  44. package/dist/locale/da.js +1 -1
  45. package/dist/locale/da.min.js +1 -1
  46. package/dist/locale/da.min.mjs +1 -1
  47. package/dist/locale/da.mjs +1 -1
  48. package/dist/locale/de.js +1 -1
  49. package/dist/locale/de.min.js +1 -1
  50. package/dist/locale/de.min.mjs +1 -1
  51. package/dist/locale/de.mjs +1 -1
  52. package/dist/locale/el.js +1 -1
  53. package/dist/locale/el.min.js +1 -1
  54. package/dist/locale/el.min.mjs +1 -1
  55. package/dist/locale/el.mjs +1 -1
  56. package/dist/locale/en.js +1 -1
  57. package/dist/locale/en.min.js +1 -1
  58. package/dist/locale/en.min.mjs +1 -1
  59. package/dist/locale/en.mjs +1 -1
  60. package/dist/locale/eo.js +1 -1
  61. package/dist/locale/eo.min.js +1 -1
  62. package/dist/locale/eo.min.mjs +1 -1
  63. package/dist/locale/eo.mjs +1 -1
  64. package/dist/locale/es.js +1 -1
  65. package/dist/locale/es.min.js +1 -1
  66. package/dist/locale/es.min.mjs +1 -1
  67. package/dist/locale/es.mjs +1 -1
  68. package/dist/locale/et.js +1 -1
  69. package/dist/locale/et.min.js +1 -1
  70. package/dist/locale/et.min.mjs +1 -1
  71. package/dist/locale/et.mjs +1 -1
  72. package/dist/locale/eu.js +1 -1
  73. package/dist/locale/eu.min.js +1 -1
  74. package/dist/locale/eu.min.mjs +1 -1
  75. package/dist/locale/eu.mjs +1 -1
  76. package/dist/locale/fa.js +1 -1
  77. package/dist/locale/fa.min.js +1 -1
  78. package/dist/locale/fa.min.mjs +1 -1
  79. package/dist/locale/fa.mjs +1 -1
  80. package/dist/locale/fi.js +1 -1
  81. package/dist/locale/fi.min.js +1 -1
  82. package/dist/locale/fi.min.mjs +1 -1
  83. package/dist/locale/fi.mjs +1 -1
  84. package/dist/locale/fr.js +1 -1
  85. package/dist/locale/fr.min.js +1 -1
  86. package/dist/locale/fr.min.mjs +1 -1
  87. package/dist/locale/fr.mjs +1 -1
  88. package/dist/locale/he.js +1 -1
  89. package/dist/locale/he.min.js +1 -1
  90. package/dist/locale/he.min.mjs +1 -1
  91. package/dist/locale/he.mjs +1 -1
  92. package/dist/locale/hi.js +1 -1
  93. package/dist/locale/hi.min.js +1 -1
  94. package/dist/locale/hi.min.mjs +1 -1
  95. package/dist/locale/hi.mjs +1 -1
  96. package/dist/locale/hr.js +1 -1
  97. package/dist/locale/hr.min.js +1 -1
  98. package/dist/locale/hr.min.mjs +1 -1
  99. package/dist/locale/hr.mjs +1 -1
  100. package/dist/locale/hu.js +1 -1
  101. package/dist/locale/hu.min.js +1 -1
  102. package/dist/locale/hu.min.mjs +1 -1
  103. package/dist/locale/hu.mjs +1 -1
  104. package/dist/locale/hy-am.js +1 -1
  105. package/dist/locale/hy-am.min.js +1 -1
  106. package/dist/locale/hy-am.min.mjs +1 -1
  107. package/dist/locale/hy-am.mjs +1 -1
  108. package/dist/locale/id.js +1 -1
  109. package/dist/locale/id.min.js +1 -1
  110. package/dist/locale/id.min.mjs +1 -1
  111. package/dist/locale/id.mjs +1 -1
  112. package/dist/locale/it.js +1 -1
  113. package/dist/locale/it.min.js +1 -1
  114. package/dist/locale/it.min.mjs +1 -1
  115. package/dist/locale/it.mjs +1 -1
  116. package/dist/locale/ja.js +1 -1
  117. package/dist/locale/ja.min.js +1 -1
  118. package/dist/locale/ja.min.mjs +1 -1
  119. package/dist/locale/ja.mjs +1 -1
  120. package/dist/locale/kk.js +1 -1
  121. package/dist/locale/kk.min.js +1 -1
  122. package/dist/locale/kk.min.mjs +1 -1
  123. package/dist/locale/kk.mjs +1 -1
  124. package/dist/locale/km.js +1 -1
  125. package/dist/locale/km.min.js +1 -1
  126. package/dist/locale/km.min.mjs +1 -1
  127. package/dist/locale/km.mjs +1 -1
  128. package/dist/locale/ko.js +1 -1
  129. package/dist/locale/ko.min.js +1 -1
  130. package/dist/locale/ko.min.mjs +1 -1
  131. package/dist/locale/ko.mjs +1 -1
  132. package/dist/locale/ku.js +1 -1
  133. package/dist/locale/ku.min.js +1 -1
  134. package/dist/locale/ku.min.mjs +1 -1
  135. package/dist/locale/ku.mjs +1 -1
  136. package/dist/locale/ky.js +1 -1
  137. package/dist/locale/ky.min.js +1 -1
  138. package/dist/locale/ky.min.mjs +1 -1
  139. package/dist/locale/ky.mjs +1 -1
  140. package/dist/locale/lo.js +1 -1
  141. package/dist/locale/lo.min.js +1 -1
  142. package/dist/locale/lo.min.mjs +1 -1
  143. package/dist/locale/lo.mjs +1 -1
  144. package/dist/locale/lt.js +1 -1
  145. package/dist/locale/lt.min.js +1 -1
  146. package/dist/locale/lt.min.mjs +1 -1
  147. package/dist/locale/lt.mjs +1 -1
  148. package/dist/locale/lv.js +1 -1
  149. package/dist/locale/lv.min.js +1 -1
  150. package/dist/locale/lv.min.mjs +1 -1
  151. package/dist/locale/lv.mjs +1 -1
  152. package/dist/locale/mg.js +1 -1
  153. package/dist/locale/mg.min.js +1 -1
  154. package/dist/locale/mg.min.mjs +1 -1
  155. package/dist/locale/mg.mjs +1 -1
  156. package/dist/locale/mn.js +1 -1
  157. package/dist/locale/mn.min.js +1 -1
  158. package/dist/locale/mn.min.mjs +1 -1
  159. package/dist/locale/mn.mjs +1 -1
  160. package/dist/locale/ms.js +1 -1
  161. package/dist/locale/ms.min.js +1 -1
  162. package/dist/locale/ms.min.mjs +1 -1
  163. package/dist/locale/ms.mjs +1 -1
  164. package/dist/locale/my.js +1 -1
  165. package/dist/locale/my.min.js +1 -1
  166. package/dist/locale/my.min.mjs +1 -1
  167. package/dist/locale/my.mjs +1 -1
  168. package/dist/locale/nb-no.js +1 -1
  169. package/dist/locale/nb-no.min.js +1 -1
  170. package/dist/locale/nb-no.min.mjs +1 -1
  171. package/dist/locale/nb-no.mjs +1 -1
  172. package/dist/locale/nl.js +1 -1
  173. package/dist/locale/nl.min.js +1 -1
  174. package/dist/locale/nl.min.mjs +1 -1
  175. package/dist/locale/nl.mjs +1 -1
  176. package/dist/locale/no.js +1 -1
  177. package/dist/locale/no.min.js +1 -1
  178. package/dist/locale/no.min.mjs +1 -1
  179. package/dist/locale/no.mjs +1 -1
  180. package/dist/locale/pa.js +1 -1
  181. package/dist/locale/pa.min.js +1 -1
  182. package/dist/locale/pa.min.mjs +1 -1
  183. package/dist/locale/pa.mjs +1 -1
  184. package/dist/locale/pl.js +1 -1
  185. package/dist/locale/pl.min.js +1 -1
  186. package/dist/locale/pl.min.mjs +1 -1
  187. package/dist/locale/pl.mjs +1 -1
  188. package/dist/locale/pt-br.js +1 -1
  189. package/dist/locale/pt-br.min.js +1 -1
  190. package/dist/locale/pt-br.min.mjs +1 -1
  191. package/dist/locale/pt-br.mjs +1 -1
  192. package/dist/locale/pt.js +1 -1
  193. package/dist/locale/pt.min.js +1 -1
  194. package/dist/locale/pt.min.mjs +1 -1
  195. package/dist/locale/pt.mjs +1 -1
  196. package/dist/locale/ro.js +1 -1
  197. package/dist/locale/ro.min.js +1 -1
  198. package/dist/locale/ro.min.mjs +1 -1
  199. package/dist/locale/ro.mjs +1 -1
  200. package/dist/locale/ru.js +1 -1
  201. package/dist/locale/ru.min.js +1 -1
  202. package/dist/locale/ru.min.mjs +1 -1
  203. package/dist/locale/ru.mjs +1 -1
  204. package/dist/locale/sk.js +1 -1
  205. package/dist/locale/sk.min.js +1 -1
  206. package/dist/locale/sk.min.mjs +1 -1
  207. package/dist/locale/sk.mjs +1 -1
  208. package/dist/locale/sl.js +1 -1
  209. package/dist/locale/sl.min.js +1 -1
  210. package/dist/locale/sl.min.mjs +1 -1
  211. package/dist/locale/sl.mjs +1 -1
  212. package/dist/locale/sr.js +1 -1
  213. package/dist/locale/sr.min.js +1 -1
  214. package/dist/locale/sr.min.mjs +1 -1
  215. package/dist/locale/sr.mjs +1 -1
  216. package/dist/locale/sv.js +1 -1
  217. package/dist/locale/sv.min.js +1 -1
  218. package/dist/locale/sv.min.mjs +1 -1
  219. package/dist/locale/sv.mjs +1 -1
  220. package/dist/locale/sw.js +1 -1
  221. package/dist/locale/sw.min.js +1 -1
  222. package/dist/locale/sw.min.mjs +1 -1
  223. package/dist/locale/sw.mjs +1 -1
  224. package/dist/locale/ta.js +1 -1
  225. package/dist/locale/ta.min.js +1 -1
  226. package/dist/locale/ta.min.mjs +1 -1
  227. package/dist/locale/ta.mjs +1 -1
  228. package/dist/locale/te.js +1 -1
  229. package/dist/locale/te.min.js +1 -1
  230. package/dist/locale/te.min.mjs +1 -1
  231. package/dist/locale/te.mjs +1 -1
  232. package/dist/locale/th.js +1 -1
  233. package/dist/locale/th.min.js +1 -1
  234. package/dist/locale/th.min.mjs +1 -1
  235. package/dist/locale/th.mjs +1 -1
  236. package/dist/locale/tk.js +1 -1
  237. package/dist/locale/tk.min.js +1 -1
  238. package/dist/locale/tk.min.mjs +1 -1
  239. package/dist/locale/tk.mjs +1 -1
  240. package/dist/locale/tr.js +1 -1
  241. package/dist/locale/tr.min.js +1 -1
  242. package/dist/locale/tr.min.mjs +1 -1
  243. package/dist/locale/tr.mjs +1 -1
  244. package/dist/locale/ug-cn.js +1 -1
  245. package/dist/locale/ug-cn.min.js +1 -1
  246. package/dist/locale/ug-cn.min.mjs +1 -1
  247. package/dist/locale/ug-cn.mjs +1 -1
  248. package/dist/locale/uk.js +1 -1
  249. package/dist/locale/uk.min.js +1 -1
  250. package/dist/locale/uk.min.mjs +1 -1
  251. package/dist/locale/uk.mjs +1 -1
  252. package/dist/locale/uz-uz.js +1 -1
  253. package/dist/locale/uz-uz.min.js +1 -1
  254. package/dist/locale/uz-uz.min.mjs +1 -1
  255. package/dist/locale/uz-uz.mjs +1 -1
  256. package/dist/locale/vi.js +1 -1
  257. package/dist/locale/vi.min.js +1 -1
  258. package/dist/locale/vi.min.mjs +1 -1
  259. package/dist/locale/vi.mjs +1 -1
  260. package/dist/locale/zh-cn.js +1 -1
  261. package/dist/locale/zh-cn.min.js +1 -1
  262. package/dist/locale/zh-cn.min.mjs +1 -1
  263. package/dist/locale/zh-cn.mjs +1 -1
  264. package/dist/locale/zh-hk.js +1 -1
  265. package/dist/locale/zh-hk.min.js +1 -1
  266. package/dist/locale/zh-hk.min.mjs +1 -1
  267. package/dist/locale/zh-hk.mjs +1 -1
  268. package/dist/locale/zh-mo.js +1 -1
  269. package/dist/locale/zh-mo.min.js +1 -1
  270. package/dist/locale/zh-mo.min.mjs +1 -1
  271. package/dist/locale/zh-mo.mjs +1 -1
  272. package/dist/locale/zh-tw.js +1 -1
  273. package/dist/locale/zh-tw.min.js +1 -1
  274. package/dist/locale/zh-tw.min.mjs +1 -1
  275. package/dist/locale/zh-tw.mjs +1 -1
  276. package/es/components/affix/src/affix.d.ts +1 -1
  277. package/es/components/affix/src/affix.vue.d.ts +4 -4
  278. package/es/components/alert/src/alert.d.ts +2 -2
  279. package/es/components/alert/src/alert.vue.d.ts +2 -2
  280. package/es/components/anchor/src/anchor.vue.d.ts +2 -2
  281. package/es/components/autocomplete/src/autocomplete.d.ts +5 -5
  282. package/es/components/autocomplete/src/autocomplete.vue.d.ts +10 -10
  283. package/es/components/avatar/src/avatar-group-props.d.ts +1 -1
  284. package/es/components/avatar/src/avatar-group.d.ts +3 -3
  285. package/es/components/avatar/src/avatar.d.ts +1 -1
  286. package/es/components/avatar/src/avatar.vue.d.ts +1 -1
  287. package/es/components/backtop/src/backtop.vue.d.ts +2 -2
  288. package/es/components/badge/src/badge.d.ts +1 -1
  289. package/es/components/badge/src/badge.vue.d.ts +1 -1
  290. package/es/components/button/src/button-group.vue.d.ts +1 -1
  291. package/es/components/button/src/button.d.ts +2 -2
  292. package/es/components/button/src/button.vue.d.ts +5 -5
  293. package/es/components/calendar/src/calendar.d.ts +1 -1
  294. package/es/components/calendar/src/calendar.vue.d.ts +1 -1
  295. package/es/components/calendar/style/css.mjs +1 -1
  296. package/es/components/calendar/style/index.mjs +1 -1
  297. package/es/components/card/src/card.vue.d.ts +1 -1
  298. package/es/components/carousel/src/carousel.vue.d.ts +3 -3
  299. package/es/components/cascader/src/cascader.d.ts +4 -4
  300. package/es/components/cascader/src/cascader.vue.d.ts +14 -14
  301. package/es/components/cascader-panel/src/index.vue.d.ts +3 -3
  302. package/es/components/check-tag/src/check-tag.d.ts +1 -1
  303. package/es/components/checkbox/src/checkbox-button.vue.d.ts +5 -5
  304. package/es/components/checkbox/src/checkbox-group.d.ts +1 -1
  305. package/es/components/checkbox/src/checkbox-group.vue.d.ts +4 -4
  306. package/es/components/checkbox/src/checkbox.d.ts +1 -1
  307. package/es/components/checkbox/src/checkbox.vue.d.ts +5 -5
  308. package/es/components/checkbox/src/composables/use-checkbox-status.d.ts +2 -2
  309. package/es/components/checkbox/src/composables/use-checkbox.d.ts +2 -2
  310. package/es/components/collapse/src/collapse-item.vue.d.ts +1 -1
  311. package/es/components/collapse/src/collapse.vue.d.ts +2 -2
  312. package/es/components/color-picker/src/color-picker.d.ts +2 -2
  313. package/es/components/color-picker/src/color-picker.vue.d.ts +8 -8
  314. package/es/components/color-picker-panel/src/color-picker-panel.d.ts +1 -1
  315. package/es/components/color-picker-panel/src/color-picker-panel.vue.d.ts +1 -1
  316. package/es/components/config-provider/src/config-provider-props.d.ts +1 -1
  317. package/es/components/config-provider/src/config-provider.d.ts +2 -2
  318. package/es/components/config-provider/src/hooks/use-global-config.d.ts +1 -1
  319. package/es/components/countdown/src/countdown.vue.d.ts +1 -1
  320. package/es/components/date-picker/src/date-picker.d.ts +12 -12
  321. package/es/components/date-picker/src/props.d.ts +2 -2
  322. package/es/components/date-picker-panel/src/date-picker-panel.d.ts +4 -4
  323. package/es/components/descriptions/src/description-item.d.ts +3 -3
  324. package/es/components/descriptions/src/description.d.ts +1 -1
  325. package/es/components/descriptions/src/description.vue.d.ts +2 -2
  326. package/es/components/dialog/src/dialog.vue.d.ts +6 -6
  327. package/es/components/divider/src/divider.vue.d.ts +1 -1
  328. package/es/components/drawer/src/drawer.vue.d.ts +8 -8
  329. package/es/components/dropdown/src/dropdown.d.ts +2 -2
  330. package/es/components/dropdown/src/dropdown.vue.d.ts +10 -10
  331. package/es/components/dropdown/style/css.mjs +1 -1
  332. package/es/components/dropdown/style/index.mjs +1 -1
  333. package/es/components/form/src/form-item.d.ts +3 -3
  334. package/es/components/form/src/form-item.vue.d.ts +2 -2
  335. package/es/components/form/src/form.d.ts +3 -3
  336. package/es/components/form/src/hooks/use-form-common-props.d.ts +2 -2
  337. package/es/components/image/src/image.vue.d.ts +9 -9
  338. package/es/components/image-viewer/src/image-viewer.vue.d.ts +4 -4
  339. package/es/components/input/src/input.d.ts +4 -4
  340. package/es/components/input/src/input.vue.d.ts +16 -16
  341. package/es/components/input-number/src/input-number.d.ts +3 -3
  342. package/es/components/input-number/src/input-number.vue.d.ts +9 -9
  343. package/es/components/input-tag/src/composables/use-input-tag.d.ts +1 -1
  344. package/es/components/input-tag/src/input-tag.d.ts +4 -4
  345. package/es/components/input-tag/src/input-tag.vue.d.ts +12 -12
  346. package/es/components/link/src/link.d.ts +1 -1
  347. package/es/components/link/src/link.vue.d.ts +1 -1
  348. package/es/components/mention/src/mention.d.ts +5 -5
  349. package/es/components/mention/src/mention.vue.d.ts +10 -10
  350. package/es/components/menu/src/menu.d.ts +1 -1
  351. package/es/components/menu/src/sub-menu.d.ts +1 -1
  352. package/es/components/message/src/message.d.ts +2 -2
  353. package/es/components/message/src/message.vue.d.ts +7 -7
  354. package/es/components/notification/src/notification.d.ts +2 -2
  355. package/es/components/notification/src/notification.vue.d.ts +2 -2
  356. package/es/components/page-header/src/page-header.vue.d.ts +1 -1
  357. package/es/components/pagination/src/pagination.d.ts +7 -7
  358. package/es/components/popconfirm/src/popconfirm.d.ts +2 -2
  359. package/es/components/popconfirm/src/popconfirm.vue.d.ts +2 -2
  360. package/es/components/popover/src/popover.d.ts +2 -2
  361. package/es/components/popover/src/popover.vue.d.ts +8 -8
  362. package/es/components/popper/src/composables/use-content.d.ts +3 -3
  363. package/es/components/popper/src/content.d.ts +4 -4
  364. package/es/components/popper/src/content.vue.d.ts +11 -11
  365. package/es/components/progress/src/progress.vue.d.ts +2 -2
  366. package/es/components/radio/src/radio-button.d.ts +1 -1
  367. package/es/components/radio/src/radio-button.vue.d.ts +3 -3
  368. package/es/components/radio/src/radio-group.d.ts +1 -1
  369. package/es/components/radio/src/radio-group.vue.d.ts +5 -5
  370. package/es/components/radio/src/radio.d.ts +2 -2
  371. package/es/components/radio/src/radio.vue.d.ts +5 -5
  372. package/es/components/rate/src/rate.d.ts +1 -1
  373. package/es/components/rate/src/rate.vue.d.ts +3 -3
  374. package/es/components/result/src/result.d.ts +1 -1
  375. package/es/components/result/src/result.vue.d.ts +1 -1
  376. package/es/components/roving-focus-group/src/roving-focus-item.vue.d.ts +1 -1
  377. package/es/components/row/src/row.d.ts +2 -2
  378. package/es/components/scrollbar/src/scrollbar.vue.d.ts +1 -1
  379. package/es/components/segmented/index.d.ts +97 -97
  380. package/es/components/segmented/src/segmented.d.ts +1 -1
  381. package/es/components/segmented/src/segmented.vue.d.ts +4 -4
  382. package/es/components/select/src/select.d.ts +4 -4
  383. package/es/components/select/src/select.vue.d.ts +29 -29
  384. package/es/components/select-v2/src/defaults.d.ts +4 -4
  385. package/es/components/select-v2/src/select.vue.d.ts +29 -29
  386. package/es/components/skeleton/src/skeleton-item.d.ts +1 -1
  387. package/es/components/skeleton/src/skeleton.vue.d.ts +1 -1
  388. package/es/components/slider/src/button.vue.d.ts +1 -1
  389. package/es/components/slider/src/composables/index.d.ts +1 -1
  390. package/es/components/slider/src/composables/use-marks.mjs +16 -2
  391. package/es/components/slider/src/composables/use-marks.mjs.map +1 -1
  392. package/es/components/slider/src/composables/use-slider-button.mjs +57 -15
  393. package/es/components/slider/src/composables/use-slider-button.mjs.map +1 -1
  394. package/es/components/slider/src/composables/use-stops.mjs +2 -2
  395. package/es/components/slider/src/composables/use-stops.mjs.map +1 -1
  396. package/es/components/slider/src/constants.d.ts +2 -0
  397. package/es/components/slider/src/constants.mjs.map +1 -1
  398. package/es/components/slider/src/slider.d.ts +3 -3
  399. package/es/components/slider/src/slider.mjs +1 -1
  400. package/es/components/slider/src/slider.mjs.map +1 -1
  401. package/es/components/slider/src/slider.vue.d.ts +17 -17
  402. package/es/components/slider/src/slider.vue_vue_type_script_setup_true_lang.mjs +14 -5
  403. package/es/components/slider/src/slider.vue_vue_type_script_setup_true_lang.mjs.map +1 -1
  404. package/es/components/slider/src/slider2.mjs.map +1 -1
  405. package/es/components/space/src/space.d.ts +5 -5
  406. package/es/components/splitter/src/splitter.vue.d.ts +2 -2
  407. package/es/components/steps/src/item.d.ts +1 -1
  408. package/es/components/steps/src/item.vue.d.ts +1 -1
  409. package/es/components/steps/src/steps.d.ts +2 -2
  410. package/es/components/steps/src/steps.vue.d.ts +1 -1
  411. package/es/components/switch/src/switch.d.ts +1 -1
  412. package/es/components/switch/src/switch.vue.d.ts +6 -6
  413. package/es/components/table/src/table-body/index.d.ts +1 -1
  414. package/es/components/table/src/table-column/index.d.ts +2 -2
  415. package/es/components/table/src/table.vue.d.ts +17 -17
  416. package/es/components/table-v2/src/components/row.d.ts +1 -1
  417. package/es/components/table-v2/src/table-grid.d.ts +2 -2
  418. package/es/components/table-v2/src/table-v2.d.ts +3 -3
  419. package/es/components/tabs/src/tab-nav.d.ts +1 -1
  420. package/es/components/tabs/src/tab-pane.vue.d.ts +1 -1
  421. package/es/components/tabs/src/tabs.d.ts +7 -7
  422. package/es/components/tag/src/tag.d.ts +3 -3
  423. package/es/components/tag/src/tag.vue.d.ts +1 -1
  424. package/es/components/text/src/text.d.ts +2 -2
  425. package/es/components/time-picker/src/common/picker.vue.d.ts +16 -16
  426. package/es/components/time-picker/src/common/props.d.ts +2 -2
  427. package/es/components/time-picker/src/time-picker.d.ts +12 -12
  428. package/es/components/time-select/src/time-select.d.ts +1 -1
  429. package/es/components/time-select/src/time-select.vue.d.ts +9 -9
  430. package/es/components/timeline/src/timeline-item.d.ts +3 -3
  431. package/es/components/timeline/src/timeline-item.vue.d.ts +1 -1
  432. package/es/components/tooltip/src/content.d.ts +1 -1
  433. package/es/components/tooltip/src/content.vue.d.ts +7 -7
  434. package/es/components/tooltip/src/tooltip.d.ts +2 -2
  435. package/es/components/tooltip/src/tooltip.vue.d.ts +9 -9
  436. package/es/components/tooltip/src/tooltip.vue_vue_type_script_setup_true_lang.mjs +1 -0
  437. package/es/components/tooltip/src/tooltip.vue_vue_type_script_setup_true_lang.mjs.map +1 -1
  438. package/es/components/tooltip/src/tooltip2.mjs.map +1 -1
  439. package/es/components/tooltip/src/trigger.d.ts +1 -1
  440. package/es/components/tour/src/content.d.ts +2 -2
  441. package/es/components/tour/src/step.d.ts +1 -1
  442. package/es/components/tour/src/tour.d.ts +1 -1
  443. package/es/components/tour/src/tour.vue.d.ts +5 -5
  444. package/es/components/transfer/src/transfer-panel.vue.d.ts +1 -1
  445. package/es/components/transfer/src/transfer.vue.d.ts +3 -3
  446. package/es/components/tree/src/tree.vue.d.ts +12 -12
  447. package/es/components/tree-select/src/tree-select.vue.d.ts +36 -36
  448. package/es/components/tree-v2/src/tree.vue.d.ts +13 -13
  449. package/es/components/upload/src/upload-content.vue.d.ts +3 -3
  450. package/es/components/upload/src/upload.vue.d.ts +4 -4
  451. package/es/components/virtual-list/src/builders/build-grid.d.ts +6 -6
  452. package/es/components/virtual-list/src/components/dynamic-size-grid.d.ts +6 -6
  453. package/es/components/virtual-list/src/components/dynamic-size-list.d.ts +6 -6
  454. package/es/components/virtual-list/src/components/fixed-size-grid.d.ts +6 -6
  455. package/es/components/virtual-list/src/components/fixed-size-list.d.ts +6 -6
  456. package/es/components/watermark/src/watermark.vue.d.ts +2 -2
  457. package/es/hooks/use-floating/index.d.ts +4 -4
  458. package/es/hooks/use-popper/index.d.ts +3 -3
  459. package/es/hooks/use-size/index.d.ts +3 -3
  460. package/es/version.mjs +1 -1
  461. package/es/version.mjs.map +1 -1
  462. package/lib/components/affix/src/affix.d.ts +1 -1
  463. package/lib/components/affix/src/affix.vue.d.ts +4 -4
  464. package/lib/components/alert/src/alert.d.ts +2 -2
  465. package/lib/components/alert/src/alert.vue.d.ts +2 -2
  466. package/lib/components/anchor/src/anchor.vue.d.ts +2 -2
  467. package/lib/components/autocomplete/src/autocomplete.d.ts +5 -5
  468. package/lib/components/autocomplete/src/autocomplete.vue.d.ts +10 -10
  469. package/lib/components/avatar/src/avatar-group-props.d.ts +1 -1
  470. package/lib/components/avatar/src/avatar-group.d.ts +3 -3
  471. package/lib/components/avatar/src/avatar.d.ts +1 -1
  472. package/lib/components/avatar/src/avatar.vue.d.ts +1 -1
  473. package/lib/components/backtop/src/backtop.vue.d.ts +2 -2
  474. package/lib/components/badge/src/badge.d.ts +1 -1
  475. package/lib/components/badge/src/badge.vue.d.ts +1 -1
  476. package/lib/components/button/src/button-group.vue.d.ts +1 -1
  477. package/lib/components/button/src/button.d.ts +2 -2
  478. package/lib/components/button/src/button.vue.d.ts +5 -5
  479. package/lib/components/calendar/src/calendar.d.ts +1 -1
  480. package/lib/components/calendar/src/calendar.vue.d.ts +1 -1
  481. package/lib/components/calendar/style/css.js +1 -1
  482. package/lib/components/calendar/style/index.js +1 -1
  483. package/lib/components/card/src/card.vue.d.ts +1 -1
  484. package/lib/components/carousel/src/carousel.vue.d.ts +3 -3
  485. package/lib/components/cascader/src/cascader.d.ts +4 -4
  486. package/lib/components/cascader/src/cascader.vue.d.ts +14 -14
  487. package/lib/components/cascader-panel/src/index.vue.d.ts +3 -3
  488. package/lib/components/check-tag/src/check-tag.d.ts +1 -1
  489. package/lib/components/checkbox/src/checkbox-button.vue.d.ts +5 -5
  490. package/lib/components/checkbox/src/checkbox-group.d.ts +1 -1
  491. package/lib/components/checkbox/src/checkbox-group.vue.d.ts +4 -4
  492. package/lib/components/checkbox/src/checkbox.d.ts +1 -1
  493. package/lib/components/checkbox/src/checkbox.vue.d.ts +5 -5
  494. package/lib/components/checkbox/src/composables/use-checkbox-status.d.ts +2 -2
  495. package/lib/components/checkbox/src/composables/use-checkbox.d.ts +2 -2
  496. package/lib/components/collapse/src/collapse-item.vue.d.ts +1 -1
  497. package/lib/components/collapse/src/collapse.vue.d.ts +2 -2
  498. package/lib/components/color-picker/src/color-picker.d.ts +2 -2
  499. package/lib/components/color-picker/src/color-picker.vue.d.ts +8 -8
  500. package/lib/components/color-picker-panel/src/color-picker-panel.d.ts +1 -1
  501. package/lib/components/color-picker-panel/src/color-picker-panel.vue.d.ts +1 -1
  502. package/lib/components/config-provider/src/config-provider-props.d.ts +1 -1
  503. package/lib/components/config-provider/src/config-provider.d.ts +2 -2
  504. package/lib/components/config-provider/src/hooks/use-global-config.d.ts +1 -1
  505. package/lib/components/countdown/src/countdown.vue.d.ts +1 -1
  506. package/lib/components/date-picker/src/date-picker.d.ts +12 -12
  507. package/lib/components/date-picker/src/props.d.ts +2 -2
  508. package/lib/components/date-picker-panel/src/date-picker-panel.d.ts +4 -4
  509. package/lib/components/descriptions/src/description-item.d.ts +3 -3
  510. package/lib/components/descriptions/src/description.d.ts +1 -1
  511. package/lib/components/descriptions/src/description.vue.d.ts +2 -2
  512. package/lib/components/dialog/src/dialog.vue.d.ts +6 -6
  513. package/lib/components/divider/src/divider.vue.d.ts +1 -1
  514. package/lib/components/drawer/src/drawer.vue.d.ts +8 -8
  515. package/lib/components/dropdown/src/dropdown.d.ts +2 -2
  516. package/lib/components/dropdown/src/dropdown.vue.d.ts +10 -10
  517. package/lib/components/dropdown/style/css.js +1 -1
  518. package/lib/components/dropdown/style/index.js +1 -1
  519. package/lib/components/form/src/form-item.d.ts +3 -3
  520. package/lib/components/form/src/form-item.vue.d.ts +2 -2
  521. package/lib/components/form/src/form.d.ts +3 -3
  522. package/lib/components/form/src/hooks/use-form-common-props.d.ts +2 -2
  523. package/lib/components/image/src/image.vue.d.ts +9 -9
  524. package/lib/components/image-viewer/src/image-viewer.vue.d.ts +4 -4
  525. package/lib/components/input/src/input.d.ts +4 -4
  526. package/lib/components/input/src/input.vue.d.ts +16 -16
  527. package/lib/components/input-number/src/input-number.d.ts +3 -3
  528. package/lib/components/input-number/src/input-number.vue.d.ts +9 -9
  529. package/lib/components/input-tag/src/composables/use-input-tag.d.ts +1 -1
  530. package/lib/components/input-tag/src/input-tag.d.ts +4 -4
  531. package/lib/components/input-tag/src/input-tag.vue.d.ts +12 -12
  532. package/lib/components/link/src/link.d.ts +1 -1
  533. package/lib/components/link/src/link.vue.d.ts +1 -1
  534. package/lib/components/mention/src/mention.d.ts +5 -5
  535. package/lib/components/mention/src/mention.vue.d.ts +10 -10
  536. package/lib/components/menu/src/menu.d.ts +1 -1
  537. package/lib/components/menu/src/sub-menu.d.ts +1 -1
  538. package/lib/components/message/src/message.d.ts +2 -2
  539. package/lib/components/message/src/message.vue.d.ts +7 -7
  540. package/lib/components/notification/src/notification.d.ts +2 -2
  541. package/lib/components/notification/src/notification.vue.d.ts +2 -2
  542. package/lib/components/page-header/src/page-header.vue.d.ts +1 -1
  543. package/lib/components/pagination/src/pagination.d.ts +7 -7
  544. package/lib/components/popconfirm/src/popconfirm.d.ts +2 -2
  545. package/lib/components/popconfirm/src/popconfirm.vue.d.ts +2 -2
  546. package/lib/components/popover/src/popover.d.ts +2 -2
  547. package/lib/components/popover/src/popover.vue.d.ts +8 -8
  548. package/lib/components/popper/src/composables/use-content.d.ts +3 -3
  549. package/lib/components/popper/src/content.d.ts +4 -4
  550. package/lib/components/popper/src/content.vue.d.ts +11 -11
  551. package/lib/components/progress/src/progress.vue.d.ts +2 -2
  552. package/lib/components/radio/src/radio-button.d.ts +1 -1
  553. package/lib/components/radio/src/radio-button.vue.d.ts +3 -3
  554. package/lib/components/radio/src/radio-group.d.ts +1 -1
  555. package/lib/components/radio/src/radio-group.vue.d.ts +5 -5
  556. package/lib/components/radio/src/radio.d.ts +2 -2
  557. package/lib/components/radio/src/radio.vue.d.ts +5 -5
  558. package/lib/components/rate/src/rate.d.ts +1 -1
  559. package/lib/components/rate/src/rate.vue.d.ts +3 -3
  560. package/lib/components/result/src/result.d.ts +1 -1
  561. package/lib/components/result/src/result.vue.d.ts +1 -1
  562. package/lib/components/roving-focus-group/src/roving-focus-item.vue.d.ts +1 -1
  563. package/lib/components/row/src/row.d.ts +2 -2
  564. package/lib/components/scrollbar/src/scrollbar.vue.d.ts +1 -1
  565. package/lib/components/segmented/index.d.ts +97 -97
  566. package/lib/components/segmented/src/segmented.d.ts +1 -1
  567. package/lib/components/segmented/src/segmented.vue.d.ts +4 -4
  568. package/lib/components/select/src/select.d.ts +4 -4
  569. package/lib/components/select/src/select.vue.d.ts +29 -29
  570. package/lib/components/select-v2/src/defaults.d.ts +4 -4
  571. package/lib/components/select-v2/src/select.vue.d.ts +29 -29
  572. package/lib/components/skeleton/src/skeleton-item.d.ts +1 -1
  573. package/lib/components/skeleton/src/skeleton.vue.d.ts +1 -1
  574. package/lib/components/slider/src/button.vue.d.ts +1 -1
  575. package/lib/components/slider/src/composables/index.d.ts +1 -1
  576. package/lib/components/slider/src/composables/use-marks.js +15 -1
  577. package/lib/components/slider/src/composables/use-marks.js.map +1 -1
  578. package/lib/components/slider/src/composables/use-slider-button.js +57 -15
  579. package/lib/components/slider/src/composables/use-slider-button.js.map +1 -1
  580. package/lib/components/slider/src/composables/use-stops.js +2 -2
  581. package/lib/components/slider/src/composables/use-stops.js.map +1 -1
  582. package/lib/components/slider/src/constants.d.ts +2 -0
  583. package/lib/components/slider/src/constants.js.map +1 -1
  584. package/lib/components/slider/src/slider.d.ts +3 -3
  585. package/lib/components/slider/src/slider.js +1 -1
  586. package/lib/components/slider/src/slider.js.map +1 -1
  587. package/lib/components/slider/src/slider.vue.d.ts +17 -17
  588. package/lib/components/slider/src/slider.vue_vue_type_script_setup_true_lang.js +14 -5
  589. package/lib/components/slider/src/slider.vue_vue_type_script_setup_true_lang.js.map +1 -1
  590. package/lib/components/slider/src/slider2.js.map +1 -1
  591. package/lib/components/space/src/space.d.ts +5 -5
  592. package/lib/components/splitter/src/splitter.vue.d.ts +2 -2
  593. package/lib/components/steps/src/item.d.ts +1 -1
  594. package/lib/components/steps/src/item.vue.d.ts +1 -1
  595. package/lib/components/steps/src/steps.d.ts +2 -2
  596. package/lib/components/steps/src/steps.vue.d.ts +1 -1
  597. package/lib/components/switch/src/switch.d.ts +1 -1
  598. package/lib/components/switch/src/switch.vue.d.ts +6 -6
  599. package/lib/components/table/src/table-body/index.d.ts +1 -1
  600. package/lib/components/table/src/table-column/index.d.ts +2 -2
  601. package/lib/components/table/src/table.vue.d.ts +17 -17
  602. package/lib/components/table-v2/src/components/row.d.ts +1 -1
  603. package/lib/components/table-v2/src/table-grid.d.ts +2 -2
  604. package/lib/components/table-v2/src/table-v2.d.ts +3 -3
  605. package/lib/components/tabs/src/tab-nav.d.ts +1 -1
  606. package/lib/components/tabs/src/tab-pane.vue.d.ts +1 -1
  607. package/lib/components/tabs/src/tabs.d.ts +7 -7
  608. package/lib/components/tag/src/tag.d.ts +3 -3
  609. package/lib/components/tag/src/tag.vue.d.ts +1 -1
  610. package/lib/components/text/src/text.d.ts +2 -2
  611. package/lib/components/time-picker/src/common/picker.vue.d.ts +16 -16
  612. package/lib/components/time-picker/src/common/props.d.ts +2 -2
  613. package/lib/components/time-picker/src/time-picker.d.ts +12 -12
  614. package/lib/components/time-select/src/time-select.d.ts +1 -1
  615. package/lib/components/time-select/src/time-select.vue.d.ts +9 -9
  616. package/lib/components/timeline/src/timeline-item.d.ts +3 -3
  617. package/lib/components/timeline/src/timeline-item.vue.d.ts +1 -1
  618. package/lib/components/tooltip/src/content.d.ts +1 -1
  619. package/lib/components/tooltip/src/content.vue.d.ts +7 -7
  620. package/lib/components/tooltip/src/tooltip.d.ts +2 -2
  621. package/lib/components/tooltip/src/tooltip.vue.d.ts +9 -9
  622. package/lib/components/tooltip/src/tooltip.vue_vue_type_script_setup_true_lang.js +1 -0
  623. package/lib/components/tooltip/src/tooltip.vue_vue_type_script_setup_true_lang.js.map +1 -1
  624. package/lib/components/tooltip/src/tooltip2.js.map +1 -1
  625. package/lib/components/tooltip/src/trigger.d.ts +1 -1
  626. package/lib/components/tour/src/content.d.ts +2 -2
  627. package/lib/components/tour/src/step.d.ts +1 -1
  628. package/lib/components/tour/src/tour.d.ts +1 -1
  629. package/lib/components/tour/src/tour.vue.d.ts +5 -5
  630. package/lib/components/transfer/src/transfer-panel.vue.d.ts +1 -1
  631. package/lib/components/transfer/src/transfer.vue.d.ts +3 -3
  632. package/lib/components/tree/src/tree.vue.d.ts +12 -12
  633. package/lib/components/tree-select/src/tree-select.vue.d.ts +36 -36
  634. package/lib/components/tree-v2/src/tree.vue.d.ts +13 -13
  635. package/lib/components/upload/src/upload-content.vue.d.ts +3 -3
  636. package/lib/components/upload/src/upload.vue.d.ts +4 -4
  637. package/lib/components/virtual-list/src/builders/build-grid.d.ts +6 -6
  638. package/lib/components/virtual-list/src/components/dynamic-size-grid.d.ts +6 -6
  639. package/lib/components/virtual-list/src/components/dynamic-size-list.d.ts +6 -6
  640. package/lib/components/virtual-list/src/components/fixed-size-grid.d.ts +6 -6
  641. package/lib/components/virtual-list/src/components/fixed-size-list.d.ts +6 -6
  642. package/lib/components/watermark/src/watermark.vue.d.ts +2 -2
  643. package/lib/hooks/use-floating/index.d.ts +4 -4
  644. package/lib/hooks/use-popper/index.d.ts +3 -3
  645. package/lib/hooks/use-size/index.d.ts +3 -3
  646. package/lib/version.js +1 -1
  647. package/lib/version.js.map +1 -1
  648. package/package.json +2 -2
  649. package/web-types.json +1 -1
@@ -1,4 +1,4 @@
1
- /*! Element Plus v0.0.20260308 */
1
+ /*! Element Plus v0.0.20260310 */
2
2
 
3
3
  (function(global, factory) {
4
4
  typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('vue')) :
@@ -10462,7 +10462,7 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
10462
10462
 
10463
10463
  //#endregion
10464
10464
  //#region ../../packages/element-plus/version.ts
10465
- const version$1 = "0.0.20260308";
10465
+ const version$1 = "0.0.20260310";
10466
10466
 
10467
10467
  //#endregion
10468
10468
  //#region ../../packages/element-plus/make-installer.ts
@@ -13852,6 +13852,7 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
13852
13852
  });
13853
13853
  (0, vue.watch)(() => props.disabled, (disabled) => {
13854
13854
  if (disabled && open.value) open.value = false;
13855
+ if (!disabled && isBoolean(props.visible)) open.value = props.visible;
13855
13856
  });
13856
13857
  const isFocusInsideContent = (event) => {
13857
13858
  return contentRef.value?.isFocusInsideContent(event);
@@ -16207,14 +16208,14 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16207
16208
  };
16208
16209
 
16209
16210
  //#endregion
16210
- //#region ../../node_modules/.pnpm/@ctrl+tinycolor@3.6.1/node_modules/@ctrl/tinycolor/dist/module/util.js
16211
+ //#region ../../node_modules/.pnpm/@ctrl+tinycolor@4.2.0/node_modules/@ctrl/tinycolor/dist/module/util.js
16211
16212
  /**
16212
16213
  * Take input from [0, n] and return it as [0, 1]
16213
16214
  * @hidden
16214
16215
  */
16215
16216
  function bound01(n, max) {
16216
16217
  if (isOnePointZero(n)) n = "100%";
16217
- var isPercent = isPercentage(n);
16218
+ const isPercent = isPercentage(n);
16218
16219
  n = max === 360 ? n : Math.min(max, Math.max(0, parseFloat(n)));
16219
16220
  if (isPercent) n = parseInt(String(n * max), 10) / 100;
16220
16221
  if (Math.abs(n - max) < 1e-6) return 1;
@@ -16258,7 +16259,7 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16258
16259
  * @hidden
16259
16260
  */
16260
16261
  function convertToPercentage(n) {
16261
- if (n <= 1) return "".concat(Number(n) * 100, "%");
16262
+ if (Number(n) <= 1) return `${Number(n) * 100}%`;
16262
16263
  return n;
16263
16264
  }
16264
16265
  /**
@@ -16270,7 +16271,7 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16270
16271
  }
16271
16272
 
16272
16273
  //#endregion
16273
- //#region ../../node_modules/.pnpm/@ctrl+tinycolor@3.6.1/node_modules/@ctrl/tinycolor/dist/module/conversion.js
16274
+ //#region ../../node_modules/.pnpm/@ctrl+tinycolor@4.2.0/node_modules/@ctrl/tinycolor/dist/module/conversion.js
16274
16275
  /**
16275
16276
  * Handle bounds / percentage checking to conform to CSS color spec
16276
16277
  * <http://www.w3.org/TR/css3-color/>
@@ -16293,16 +16294,16 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16293
16294
  r = bound01(r, 255);
16294
16295
  g = bound01(g, 255);
16295
16296
  b = bound01(b, 255);
16296
- var max = Math.max(r, g, b);
16297
- var min = Math.min(r, g, b);
16298
- var h = 0;
16299
- var s = 0;
16300
- var l = (max + min) / 2;
16297
+ const max = Math.max(r, g, b);
16298
+ const min = Math.min(r, g, b);
16299
+ let h = 0;
16300
+ let s = 0;
16301
+ const l = (max + min) / 2;
16301
16302
  if (max === min) {
16302
16303
  s = 0;
16303
16304
  h = 0;
16304
16305
  } else {
16305
- var d = max - min;
16306
+ const d = max - min;
16306
16307
  s = l > .5 ? d / (2 - max - min) : d / (max + min);
16307
16308
  switch (max) {
16308
16309
  case r:
@@ -16339,9 +16340,9 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16339
16340
  * *Returns:* { r, g, b } in the set [0, 255]
16340
16341
  */
16341
16342
  function hslToRgb(h, s, l) {
16342
- var r;
16343
- var g;
16344
- var b;
16343
+ let r;
16344
+ let g;
16345
+ let b;
16345
16346
  h = bound01(h, 360);
16346
16347
  s = bound01(s, 100);
16347
16348
  l = bound01(l, 100);
@@ -16350,8 +16351,8 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16350
16351
  b = l;
16351
16352
  r = l;
16352
16353
  } else {
16353
- var q = l < .5 ? l * (1 + s) : l + s - l * s;
16354
- var p = 2 * l - q;
16354
+ const q = l < .5 ? l * (1 + s) : l + s - l * s;
16355
+ const p = 2 * l - q;
16355
16356
  r = hue2rgb(p, q, h + 1 / 3);
16356
16357
  g = hue2rgb(p, q, h);
16357
16358
  b = hue2rgb(p, q, h - 1 / 3);
@@ -16372,12 +16373,12 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16372
16373
  r = bound01(r, 255);
16373
16374
  g = bound01(g, 255);
16374
16375
  b = bound01(b, 255);
16375
- var max = Math.max(r, g, b);
16376
- var min = Math.min(r, g, b);
16377
- var h = 0;
16378
- var v = max;
16379
- var d = max - min;
16380
- var s = max === 0 ? 0 : d / max;
16376
+ const max = Math.max(r, g, b);
16377
+ const min = Math.min(r, g, b);
16378
+ let h = 0;
16379
+ const v = max;
16380
+ const d = max - min;
16381
+ const s = max === 0 ? 0 : d / max;
16381
16382
  if (max === min) h = 0;
16382
16383
  else {
16383
16384
  switch (max) {
@@ -16410,13 +16411,13 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16410
16411
  h = bound01(h, 360) * 6;
16411
16412
  s = bound01(s, 100);
16412
16413
  v = bound01(v, 100);
16413
- var i = Math.floor(h);
16414
- var f = h - i;
16415
- var p = v * (1 - s);
16416
- var q = v * (1 - f * s);
16417
- var t = v * (1 - (1 - f) * s);
16418
- var mod = i % 6;
16419
- var r = [
16414
+ const i = Math.floor(h);
16415
+ const f = h - i;
16416
+ const p = v * (1 - s);
16417
+ const q = v * (1 - f * s);
16418
+ const t = v * (1 - (1 - f) * s);
16419
+ const mod = i % 6;
16420
+ const r = [
16420
16421
  v,
16421
16422
  q,
16422
16423
  p,
@@ -16424,7 +16425,7 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16424
16425
  t,
16425
16426
  v
16426
16427
  ][mod];
16427
- var g = [
16428
+ const g = [
16428
16429
  t,
16429
16430
  v,
16430
16431
  v,
@@ -16432,7 +16433,7 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16432
16433
  p,
16433
16434
  p
16434
16435
  ][mod];
16435
- var b = [
16436
+ const b = [
16436
16437
  p,
16437
16438
  p,
16438
16439
  t,
@@ -16449,11 +16450,11 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16449
16450
  /**
16450
16451
  * Converts an RGB color to hex
16451
16452
  *
16452
- * Assumes r, g, and b are contained in the set [0, 255]
16453
- * Returns a 3 or 6 character hex
16453
+ * *Assumes:* r, g, and b are contained in the set [0, 255]
16454
+ * *Returns:* a 3 or 6 character hex
16454
16455
  */
16455
16456
  function rgbToHex(r, g, b, allow3Char) {
16456
- var hex = [
16457
+ const hex = [
16457
16458
  pad2(Math.round(r).toString(16)),
16458
16459
  pad2(Math.round(g).toString(16)),
16459
16460
  pad2(Math.round(b).toString(16))
@@ -16464,11 +16465,11 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16464
16465
  /**
16465
16466
  * Converts an RGBA color plus alpha transparency to hex
16466
16467
  *
16467
- * Assumes r, g, b are contained in the set [0, 255] and
16468
- * a in [0, 1]. Returns a 4 or 8 character rgba hex
16468
+ * *Assumes:* r, g, b are contained in the set [0, 255] and a in [0, 1]
16469
+ * *Returns:* a 4 or 8 character rgba hex
16469
16470
  */
16470
16471
  function rgbaToHex(r, g, b, a, allow4Char) {
16471
- var hex = [
16472
+ const hex = [
16472
16473
  pad2(Math.round(r).toString(16)),
16473
16474
  pad2(Math.round(g).toString(16)),
16474
16475
  pad2(Math.round(b).toString(16)),
@@ -16477,6 +16478,43 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16477
16478
  if (allow4Char && hex[0].startsWith(hex[0].charAt(1)) && hex[1].startsWith(hex[1].charAt(1)) && hex[2].startsWith(hex[2].charAt(1)) && hex[3].startsWith(hex[3].charAt(1))) return hex[0].charAt(0) + hex[1].charAt(0) + hex[2].charAt(0) + hex[3].charAt(0);
16478
16479
  return hex.join("");
16479
16480
  }
16481
+ /**
16482
+ * Converts CMYK to RBG
16483
+ * Assumes c, m, y, k are in the set [0, 100]
16484
+ */
16485
+ function cmykToRgb(c, m, y, k) {
16486
+ const cConv = c / 100;
16487
+ const mConv = m / 100;
16488
+ const yConv = y / 100;
16489
+ const kConv = k / 100;
16490
+ return {
16491
+ r: 255 * (1 - cConv) * (1 - kConv),
16492
+ g: 255 * (1 - mConv) * (1 - kConv),
16493
+ b: 255 * (1 - yConv) * (1 - kConv)
16494
+ };
16495
+ }
16496
+ function rgbToCmyk(r, g, b) {
16497
+ let c = 1 - r / 255;
16498
+ let m = 1 - g / 255;
16499
+ let y = 1 - b / 255;
16500
+ let k = Math.min(c, m, y);
16501
+ if (k === 1) {
16502
+ c = 0;
16503
+ m = 0;
16504
+ y = 0;
16505
+ } else {
16506
+ c = (c - k) / (1 - k) * 100;
16507
+ m = (m - k) / (1 - k) * 100;
16508
+ y = (y - k) / (1 - k) * 100;
16509
+ }
16510
+ k *= 100;
16511
+ return {
16512
+ c: Math.round(c),
16513
+ m: Math.round(m),
16514
+ y: Math.round(y),
16515
+ k: Math.round(k)
16516
+ };
16517
+ }
16480
16518
  /** Converts a decimal to a hex value */
16481
16519
  function convertDecimalToHex(d) {
16482
16520
  return Math.round(parseFloat(d) * 255).toString(16);
@@ -16498,11 +16536,11 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16498
16536
  }
16499
16537
 
16500
16538
  //#endregion
16501
- //#region ../../node_modules/.pnpm/@ctrl+tinycolor@3.6.1/node_modules/@ctrl/tinycolor/dist/module/css-color-names.js
16539
+ //#region ../../node_modules/.pnpm/@ctrl+tinycolor@4.2.0/node_modules/@ctrl/tinycolor/dist/module/css-color-names.js
16502
16540
  /**
16503
16541
  * @hidden
16504
16542
  */
16505
- var names = {
16543
+ const names = {
16506
16544
  aliceblue: "#f0f8ff",
16507
16545
  antiquewhite: "#faebd7",
16508
16546
  aqua: "#00ffff",
@@ -16654,7 +16692,7 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16654
16692
  };
16655
16693
 
16656
16694
  //#endregion
16657
- //#region ../../node_modules/.pnpm/@ctrl+tinycolor@3.6.1/node_modules/@ctrl/tinycolor/dist/module/format-input.js
16695
+ //#region ../../node_modules/.pnpm/@ctrl+tinycolor@4.2.0/node_modules/@ctrl/tinycolor/dist/module/format-input.js
16658
16696
  /**
16659
16697
  * Given a string or object, convert that input to RGB
16660
16698
  *
@@ -16671,20 +16709,21 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16671
16709
  * "hsl(0, 100%, 50%)" or "hsl 0 100% 50%"
16672
16710
  * "hsla(0, 100%, 50%, 1)" or "hsla 0 100% 50%, 1"
16673
16711
  * "hsv(0, 100%, 100%)" or "hsv 0 100% 100%"
16712
+ * "cmyk(0, 20, 0, 0)" or "cmyk 0 20 0 0"
16674
16713
  * ```
16675
16714
  */
16676
16715
  function inputToRGB(color) {
16677
- var rgb = {
16716
+ let rgb = {
16678
16717
  r: 0,
16679
16718
  g: 0,
16680
16719
  b: 0
16681
16720
  };
16682
- var a = 1;
16683
- var s = null;
16684
- var v = null;
16685
- var l = null;
16686
- var ok = false;
16687
- var format = false;
16721
+ let a = 1;
16722
+ let s = null;
16723
+ let v = null;
16724
+ let l = null;
16725
+ let ok = false;
16726
+ let format = false;
16688
16727
  if (typeof color === "string") color = stringInputToObject(color);
16689
16728
  if (typeof color === "object") {
16690
16729
  if (isValidCSSUnit(color.r) && isValidCSSUnit(color.g) && isValidCSSUnit(color.b)) {
@@ -16703,6 +16742,10 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16703
16742
  rgb = hslToRgb(color.h, s, l);
16704
16743
  ok = true;
16705
16744
  format = "hsl";
16745
+ } else if (isValidCSSUnit(color.c) && isValidCSSUnit(color.m) && isValidCSSUnit(color.y) && isValidCSSUnit(color.k)) {
16746
+ rgb = cmykToRgb(color.c, color.m, color.y, color.k);
16747
+ ok = true;
16748
+ format = "cmyk";
16706
16749
  }
16707
16750
  if (Object.prototype.hasOwnProperty.call(color, "a")) a = color.a;
16708
16751
  }
@@ -16716,10 +16759,10 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16716
16759
  a
16717
16760
  };
16718
16761
  }
16719
- var CSS_UNIT = "(?:".concat("[-\\+]?\\d*\\.\\d+%?", ")|(?:").concat("[-\\+]?\\d+%?", ")");
16720
- var PERMISSIVE_MATCH3 = "[\\s|\\(]+(".concat(CSS_UNIT, ")[,|\\s]+(").concat(CSS_UNIT, ")[,|\\s]+(").concat(CSS_UNIT, ")\\s*\\)?");
16721
- var PERMISSIVE_MATCH4 = "[\\s|\\(]+(".concat(CSS_UNIT, ")[,|\\s]+(").concat(CSS_UNIT, ")[,|\\s]+(").concat(CSS_UNIT, ")[,|\\s]+(").concat(CSS_UNIT, ")\\s*\\)?");
16722
- var matchers = {
16762
+ const CSS_UNIT = "(?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?)";
16763
+ const PERMISSIVE_MATCH3 = "[\\s|\\(]+(" + CSS_UNIT + ")[,|\\s]+((?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?))[,|\\s]+((?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?))\\s*\\)?";
16764
+ const PERMISSIVE_MATCH4 = "[\\s|\\(]+(" + CSS_UNIT + ")[,|\\s]+((?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?))[,|\\s]+((?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?))[,|\\s]+((?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?))\\s*\\)?";
16765
+ const matchers = {
16723
16766
  CSS_UNIT: new RegExp(CSS_UNIT),
16724
16767
  rgb: new RegExp("rgb" + PERMISSIVE_MATCH3),
16725
16768
  rgba: new RegExp("rgba" + PERMISSIVE_MATCH4),
@@ -16727,6 +16770,7 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16727
16770
  hsla: new RegExp("hsla" + PERMISSIVE_MATCH4),
16728
16771
  hsv: new RegExp("hsv" + PERMISSIVE_MATCH3),
16729
16772
  hsva: new RegExp("hsva" + PERMISSIVE_MATCH4),
16773
+ cmyk: new RegExp("cmyk" + PERMISSIVE_MATCH4),
16730
16774
  hex3: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,
16731
16775
  hex6: /^#?([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,
16732
16776
  hex4: /^#?([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,
@@ -16734,12 +16778,12 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16734
16778
  };
16735
16779
  /**
16736
16780
  * Permissive string parsing. Take in a number of formats, and output an object
16737
- * based on detected format. Returns `{ r, g, b }` or `{ h, s, l }` or `{ h, s, v}`
16781
+ * based on detected format. Returns `{ r, g, b }` or `{ h, s, l }` or `{ h, s, v}` or `{c, m, y, k}` or `{c, m, y, k, a}`
16738
16782
  */
16739
16783
  function stringInputToObject(color) {
16740
16784
  color = color.trim().toLowerCase();
16741
16785
  if (color.length === 0) return false;
16742
- var named = false;
16786
+ let named = false;
16743
16787
  if (names[color]) {
16744
16788
  color = names[color];
16745
16789
  named = true;
@@ -16750,7 +16794,7 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16750
16794
  a: 0,
16751
16795
  format: "name"
16752
16796
  };
16753
- var match = matchers.rgb.exec(color);
16797
+ let match = matchers.rgb.exec(color);
16754
16798
  if (match) return {
16755
16799
  r: match[1],
16756
16800
  g: match[2],
@@ -16789,6 +16833,13 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16789
16833
  v: match[3],
16790
16834
  a: match[4]
16791
16835
  };
16836
+ match = matchers.cmyk.exec(color);
16837
+ if (match) return {
16838
+ c: match[1],
16839
+ m: match[2],
16840
+ y: match[3],
16841
+ k: match[4]
16842
+ };
16792
16843
  match = matchers.hex8.exec(color);
16793
16844
  if (match) return {
16794
16845
  r: parseIntFromHex(match[1]),
@@ -16826,57 +16877,55 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16826
16877
  * (see `matchers` above for definition).
16827
16878
  */
16828
16879
  function isValidCSSUnit(color) {
16829
- return Boolean(matchers.CSS_UNIT.exec(String(color)));
16880
+ if (typeof color === "number") return !Number.isNaN(color);
16881
+ return matchers.CSS_UNIT.test(color);
16830
16882
  }
16831
16883
 
16832
16884
  //#endregion
16833
- //#region ../../node_modules/.pnpm/@ctrl+tinycolor@3.6.1/node_modules/@ctrl/tinycolor/dist/module/index.js
16834
- var TinyColor = function() {
16835
- function TinyColor(color, opts) {
16836
- if (color === void 0) color = "";
16837
- if (opts === void 0) opts = {};
16838
- var _a;
16885
+ //#region ../../node_modules/.pnpm/@ctrl+tinycolor@4.2.0/node_modules/@ctrl/tinycolor/dist/module/index.js
16886
+ var TinyColor = class TinyColor {
16887
+ constructor(color = "", opts = {}) {
16839
16888
  if (color instanceof TinyColor) return color;
16840
16889
  if (typeof color === "number") color = numberInputToObject(color);
16841
16890
  this.originalInput = color;
16842
- var rgb = inputToRGB(color);
16891
+ const rgb = inputToRGB(color);
16843
16892
  this.originalInput = color;
16844
16893
  this.r = rgb.r;
16845
16894
  this.g = rgb.g;
16846
16895
  this.b = rgb.b;
16847
16896
  this.a = rgb.a;
16848
16897
  this.roundA = Math.round(100 * this.a) / 100;
16849
- this.format = (_a = opts.format) !== null && _a !== void 0 ? _a : rgb.format;
16898
+ this.format = opts.format ?? rgb.format;
16850
16899
  this.gradientType = opts.gradientType;
16851
16900
  if (this.r < 1) this.r = Math.round(this.r);
16852
16901
  if (this.g < 1) this.g = Math.round(this.g);
16853
16902
  if (this.b < 1) this.b = Math.round(this.b);
16854
16903
  this.isValid = rgb.ok;
16855
16904
  }
16856
- TinyColor.prototype.isDark = function() {
16905
+ isDark() {
16857
16906
  return this.getBrightness() < 128;
16858
- };
16859
- TinyColor.prototype.isLight = function() {
16907
+ }
16908
+ isLight() {
16860
16909
  return !this.isDark();
16861
- };
16910
+ }
16862
16911
  /**
16863
16912
  * Returns the perceived brightness of the color, from 0-255.
16864
16913
  */
16865
- TinyColor.prototype.getBrightness = function() {
16866
- var rgb = this.toRgb();
16914
+ getBrightness() {
16915
+ const rgb = this.toRgb();
16867
16916
  return (rgb.r * 299 + rgb.g * 587 + rgb.b * 114) / 1e3;
16868
- };
16917
+ }
16869
16918
  /**
16870
16919
  * Returns the perceived luminance of a color, from 0-1.
16871
16920
  */
16872
- TinyColor.prototype.getLuminance = function() {
16873
- var rgb = this.toRgb();
16874
- var R;
16875
- var G;
16876
- var B;
16877
- var RsRGB = rgb.r / 255;
16878
- var GsRGB = rgb.g / 255;
16879
- var BsRGB = rgb.b / 255;
16921
+ getLuminance() {
16922
+ const rgb = this.toRgb();
16923
+ let R;
16924
+ let G;
16925
+ let B;
16926
+ const RsRGB = rgb.r / 255;
16927
+ const GsRGB = rgb.g / 255;
16928
+ const BsRGB = rgb.b / 255;
16880
16929
  if (RsRGB <= .03928) R = RsRGB / 12.92;
16881
16930
  else R = Math.pow((RsRGB + .055) / 1.055, 2.4);
16882
16931
  if (GsRGB <= .03928) G = GsRGB / 12.92;
@@ -16884,177 +16933,173 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
16884
16933
  if (BsRGB <= .03928) B = BsRGB / 12.92;
16885
16934
  else B = Math.pow((BsRGB + .055) / 1.055, 2.4);
16886
16935
  return .2126 * R + .7152 * G + .0722 * B;
16887
- };
16936
+ }
16888
16937
  /**
16889
16938
  * Returns the alpha value of a color, from 0-1.
16890
16939
  */
16891
- TinyColor.prototype.getAlpha = function() {
16940
+ getAlpha() {
16892
16941
  return this.a;
16893
- };
16942
+ }
16894
16943
  /**
16895
16944
  * Sets the alpha value on the current color.
16896
16945
  *
16897
16946
  * @param alpha - The new alpha value. The accepted range is 0-1.
16898
16947
  */
16899
- TinyColor.prototype.setAlpha = function(alpha) {
16948
+ setAlpha(alpha) {
16900
16949
  this.a = boundAlpha(alpha);
16901
16950
  this.roundA = Math.round(100 * this.a) / 100;
16902
16951
  return this;
16903
- };
16952
+ }
16904
16953
  /**
16905
16954
  * Returns whether the color is monochrome.
16906
16955
  */
16907
- TinyColor.prototype.isMonochrome = function() {
16908
- return this.toHsl().s === 0;
16909
- };
16956
+ isMonochrome() {
16957
+ const { s } = this.toHsl();
16958
+ return s === 0;
16959
+ }
16910
16960
  /**
16911
16961
  * Returns the object as a HSVA object.
16912
16962
  */
16913
- TinyColor.prototype.toHsv = function() {
16914
- var hsv = rgbToHsv(this.r, this.g, this.b);
16963
+ toHsv() {
16964
+ const hsv = rgbToHsv(this.r, this.g, this.b);
16915
16965
  return {
16916
16966
  h: hsv.h * 360,
16917
16967
  s: hsv.s,
16918
16968
  v: hsv.v,
16919
16969
  a: this.a
16920
16970
  };
16921
- };
16971
+ }
16922
16972
  /**
16923
16973
  * Returns the hsva values interpolated into a string with the following format:
16924
16974
  * "hsva(xxx, xxx, xxx, xx)".
16925
16975
  */
16926
- TinyColor.prototype.toHsvString = function() {
16927
- var hsv = rgbToHsv(this.r, this.g, this.b);
16928
- var h = Math.round(hsv.h * 360);
16929
- var s = Math.round(hsv.s * 100);
16930
- var v = Math.round(hsv.v * 100);
16931
- return this.a === 1 ? "hsv(".concat(h, ", ").concat(s, "%, ").concat(v, "%)") : "hsva(".concat(h, ", ").concat(s, "%, ").concat(v, "%, ").concat(this.roundA, ")");
16932
- };
16976
+ toHsvString() {
16977
+ const hsv = rgbToHsv(this.r, this.g, this.b);
16978
+ const h = Math.round(hsv.h * 360);
16979
+ const s = Math.round(hsv.s * 100);
16980
+ const v = Math.round(hsv.v * 100);
16981
+ return this.a === 1 ? `hsv(${h}, ${s}%, ${v}%)` : `hsva(${h}, ${s}%, ${v}%, ${this.roundA})`;
16982
+ }
16933
16983
  /**
16934
16984
  * Returns the object as a HSLA object.
16935
16985
  */
16936
- TinyColor.prototype.toHsl = function() {
16937
- var hsl = rgbToHsl(this.r, this.g, this.b);
16986
+ toHsl() {
16987
+ const hsl = rgbToHsl(this.r, this.g, this.b);
16938
16988
  return {
16939
16989
  h: hsl.h * 360,
16940
16990
  s: hsl.s,
16941
16991
  l: hsl.l,
16942
16992
  a: this.a
16943
16993
  };
16944
- };
16994
+ }
16945
16995
  /**
16946
16996
  * Returns the hsla values interpolated into a string with the following format:
16947
16997
  * "hsla(xxx, xxx, xxx, xx)".
16948
16998
  */
16949
- TinyColor.prototype.toHslString = function() {
16950
- var hsl = rgbToHsl(this.r, this.g, this.b);
16951
- var h = Math.round(hsl.h * 360);
16952
- var s = Math.round(hsl.s * 100);
16953
- var l = Math.round(hsl.l * 100);
16954
- return this.a === 1 ? "hsl(".concat(h, ", ").concat(s, "%, ").concat(l, "%)") : "hsla(".concat(h, ", ").concat(s, "%, ").concat(l, "%, ").concat(this.roundA, ")");
16955
- };
16999
+ toHslString() {
17000
+ const hsl = rgbToHsl(this.r, this.g, this.b);
17001
+ const h = Math.round(hsl.h * 360);
17002
+ const s = Math.round(hsl.s * 100);
17003
+ const l = Math.round(hsl.l * 100);
17004
+ return this.a === 1 ? `hsl(${h}, ${s}%, ${l}%)` : `hsla(${h}, ${s}%, ${l}%, ${this.roundA})`;
17005
+ }
16956
17006
  /**
16957
17007
  * Returns the hex value of the color.
16958
17008
  * @param allow3Char will shorten hex value to 3 char if possible
16959
17009
  */
16960
- TinyColor.prototype.toHex = function(allow3Char) {
16961
- if (allow3Char === void 0) allow3Char = false;
17010
+ toHex(allow3Char = false) {
16962
17011
  return rgbToHex(this.r, this.g, this.b, allow3Char);
16963
- };
17012
+ }
16964
17013
  /**
16965
17014
  * Returns the hex value of the color -with a # prefixed.
16966
17015
  * @param allow3Char will shorten hex value to 3 char if possible
16967
17016
  */
16968
- TinyColor.prototype.toHexString = function(allow3Char) {
16969
- if (allow3Char === void 0) allow3Char = false;
17017
+ toHexString(allow3Char = false) {
16970
17018
  return "#" + this.toHex(allow3Char);
16971
- };
17019
+ }
16972
17020
  /**
16973
17021
  * Returns the hex 8 value of the color.
16974
17022
  * @param allow4Char will shorten hex value to 4 char if possible
16975
17023
  */
16976
- TinyColor.prototype.toHex8 = function(allow4Char) {
16977
- if (allow4Char === void 0) allow4Char = false;
17024
+ toHex8(allow4Char = false) {
16978
17025
  return rgbaToHex(this.r, this.g, this.b, this.a, allow4Char);
16979
- };
17026
+ }
16980
17027
  /**
16981
17028
  * Returns the hex 8 value of the color -with a # prefixed.
16982
17029
  * @param allow4Char will shorten hex value to 4 char if possible
16983
17030
  */
16984
- TinyColor.prototype.toHex8String = function(allow4Char) {
16985
- if (allow4Char === void 0) allow4Char = false;
17031
+ toHex8String(allow4Char = false) {
16986
17032
  return "#" + this.toHex8(allow4Char);
16987
- };
17033
+ }
16988
17034
  /**
16989
17035
  * Returns the shorter hex value of the color depends on its alpha -with a # prefixed.
16990
17036
  * @param allowShortChar will shorten hex value to 3 or 4 char if possible
16991
17037
  */
16992
- TinyColor.prototype.toHexShortString = function(allowShortChar) {
16993
- if (allowShortChar === void 0) allowShortChar = false;
17038
+ toHexShortString(allowShortChar = false) {
16994
17039
  return this.a === 1 ? this.toHexString(allowShortChar) : this.toHex8String(allowShortChar);
16995
- };
17040
+ }
16996
17041
  /**
16997
17042
  * Returns the object as a RGBA object.
16998
17043
  */
16999
- TinyColor.prototype.toRgb = function() {
17044
+ toRgb() {
17000
17045
  return {
17001
17046
  r: Math.round(this.r),
17002
17047
  g: Math.round(this.g),
17003
17048
  b: Math.round(this.b),
17004
17049
  a: this.a
17005
17050
  };
17006
- };
17051
+ }
17007
17052
  /**
17008
17053
  * Returns the RGBA values interpolated into a string with the following format:
17009
17054
  * "RGBA(xxx, xxx, xxx, xx)".
17010
17055
  */
17011
- TinyColor.prototype.toRgbString = function() {
17012
- var r = Math.round(this.r);
17013
- var g = Math.round(this.g);
17014
- var b = Math.round(this.b);
17015
- return this.a === 1 ? "rgb(".concat(r, ", ").concat(g, ", ").concat(b, ")") : "rgba(".concat(r, ", ").concat(g, ", ").concat(b, ", ").concat(this.roundA, ")");
17016
- };
17056
+ toRgbString() {
17057
+ const r = Math.round(this.r);
17058
+ const g = Math.round(this.g);
17059
+ const b = Math.round(this.b);
17060
+ return this.a === 1 ? `rgb(${r}, ${g}, ${b})` : `rgba(${r}, ${g}, ${b}, ${this.roundA})`;
17061
+ }
17017
17062
  /**
17018
17063
  * Returns the object as a RGBA object.
17019
17064
  */
17020
- TinyColor.prototype.toPercentageRgb = function() {
17021
- var fmt = function(x) {
17022
- return "".concat(Math.round(bound01(x, 255) * 100), "%");
17023
- };
17065
+ toPercentageRgb() {
17066
+ const fmt = (x) => `${Math.round(bound01(x, 255) * 100)}%`;
17024
17067
  return {
17025
17068
  r: fmt(this.r),
17026
17069
  g: fmt(this.g),
17027
17070
  b: fmt(this.b),
17028
17071
  a: this.a
17029
17072
  };
17030
- };
17073
+ }
17031
17074
  /**
17032
17075
  * Returns the RGBA relative values interpolated into a string
17033
17076
  */
17034
- TinyColor.prototype.toPercentageRgbString = function() {
17035
- var rnd = function(x) {
17036
- return Math.round(bound01(x, 255) * 100);
17037
- };
17038
- return this.a === 1 ? "rgb(".concat(rnd(this.r), "%, ").concat(rnd(this.g), "%, ").concat(rnd(this.b), "%)") : "rgba(".concat(rnd(this.r), "%, ").concat(rnd(this.g), "%, ").concat(rnd(this.b), "%, ").concat(this.roundA, ")");
17039
- };
17077
+ toPercentageRgbString() {
17078
+ const rnd = (x) => Math.round(bound01(x, 255) * 100);
17079
+ return this.a === 1 ? `rgb(${rnd(this.r)}%, ${rnd(this.g)}%, ${rnd(this.b)}%)` : `rgba(${rnd(this.r)}%, ${rnd(this.g)}%, ${rnd(this.b)}%, ${this.roundA})`;
17080
+ }
17081
+ toCmyk() {
17082
+ return { ...rgbToCmyk(this.r, this.g, this.b) };
17083
+ }
17084
+ toCmykString() {
17085
+ const { c, m, y, k } = rgbToCmyk(this.r, this.g, this.b);
17086
+ return `cmyk(${c}, ${m}, ${y}, ${k})`;
17087
+ }
17040
17088
  /**
17041
17089
  * The 'real' name of the color -if there is one.
17042
17090
  */
17043
- TinyColor.prototype.toName = function() {
17091
+ toName() {
17044
17092
  if (this.a === 0) return "transparent";
17045
17093
  if (this.a < 1) return false;
17046
- var hex = "#" + rgbToHex(this.r, this.g, this.b, false);
17047
- for (var _i = 0, _a = Object.entries(names); _i < _a.length; _i++) {
17048
- var _b = _a[_i], key = _b[0];
17049
- if (hex === _b[1]) return key;
17050
- }
17094
+ const hex = "#" + rgbToHex(this.r, this.g, this.b, false);
17095
+ for (const [key, value] of Object.entries(names)) if (hex === value) return key;
17051
17096
  return false;
17052
- };
17053
- TinyColor.prototype.toString = function(format) {
17054
- var formatSet = Boolean(format);
17055
- format = format !== null && format !== void 0 ? format : this.format;
17056
- var formattedString = false;
17057
- var hasAlpha = this.a < 1 && this.a >= 0;
17097
+ }
17098
+ toString(format) {
17099
+ const formatSet = Boolean(format);
17100
+ format = format ?? this.format;
17101
+ let formattedString = false;
17102
+ const hasAlpha = this.a < 1 && this.a >= 0;
17058
17103
  if (!formatSet && hasAlpha && (format.startsWith("hex") || format === "name")) {
17059
17104
  if (format === "name" && this.a === 0) return this.toName();
17060
17105
  return this.toRgbString();
@@ -17068,151 +17113,141 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
17068
17113
  if (format === "name") formattedString = this.toName();
17069
17114
  if (format === "hsl") formattedString = this.toHslString();
17070
17115
  if (format === "hsv") formattedString = this.toHsvString();
17116
+ if (format === "cmyk") formattedString = this.toCmykString();
17071
17117
  return formattedString || this.toHexString();
17072
- };
17073
- TinyColor.prototype.toNumber = function() {
17118
+ }
17119
+ toNumber() {
17074
17120
  return (Math.round(this.r) << 16) + (Math.round(this.g) << 8) + Math.round(this.b);
17075
- };
17076
- TinyColor.prototype.clone = function() {
17121
+ }
17122
+ clone() {
17077
17123
  return new TinyColor(this.toString());
17078
- };
17124
+ }
17079
17125
  /**
17080
17126
  * Lighten the color a given amount. Providing 100 will always return white.
17081
17127
  * @param amount - valid between 1-100
17082
17128
  */
17083
- TinyColor.prototype.lighten = function(amount) {
17084
- if (amount === void 0) amount = 10;
17085
- var hsl = this.toHsl();
17129
+ lighten(amount = 10) {
17130
+ const hsl = this.toHsl();
17086
17131
  hsl.l += amount / 100;
17087
17132
  hsl.l = clamp01(hsl.l);
17088
17133
  return new TinyColor(hsl);
17089
- };
17134
+ }
17090
17135
  /**
17091
17136
  * Brighten the color a given amount, from 0 to 100.
17092
17137
  * @param amount - valid between 1-100
17093
17138
  */
17094
- TinyColor.prototype.brighten = function(amount) {
17095
- if (amount === void 0) amount = 10;
17096
- var rgb = this.toRgb();
17139
+ brighten(amount = 10) {
17140
+ const rgb = this.toRgb();
17097
17141
  rgb.r = Math.max(0, Math.min(255, rgb.r - Math.round(255 * -(amount / 100))));
17098
17142
  rgb.g = Math.max(0, Math.min(255, rgb.g - Math.round(255 * -(amount / 100))));
17099
17143
  rgb.b = Math.max(0, Math.min(255, rgb.b - Math.round(255 * -(amount / 100))));
17100
17144
  return new TinyColor(rgb);
17101
- };
17145
+ }
17102
17146
  /**
17103
17147
  * Darken the color a given amount, from 0 to 100.
17104
17148
  * Providing 100 will always return black.
17105
17149
  * @param amount - valid between 1-100
17106
17150
  */
17107
- TinyColor.prototype.darken = function(amount) {
17108
- if (amount === void 0) amount = 10;
17109
- var hsl = this.toHsl();
17151
+ darken(amount = 10) {
17152
+ const hsl = this.toHsl();
17110
17153
  hsl.l -= amount / 100;
17111
17154
  hsl.l = clamp01(hsl.l);
17112
17155
  return new TinyColor(hsl);
17113
- };
17156
+ }
17114
17157
  /**
17115
17158
  * Mix the color with pure white, from 0 to 100.
17116
17159
  * Providing 0 will do nothing, providing 100 will always return white.
17117
17160
  * @param amount - valid between 1-100
17118
17161
  */
17119
- TinyColor.prototype.tint = function(amount) {
17120
- if (amount === void 0) amount = 10;
17162
+ tint(amount = 10) {
17121
17163
  return this.mix("white", amount);
17122
- };
17164
+ }
17123
17165
  /**
17124
17166
  * Mix the color with pure black, from 0 to 100.
17125
17167
  * Providing 0 will do nothing, providing 100 will always return black.
17126
17168
  * @param amount - valid between 1-100
17127
17169
  */
17128
- TinyColor.prototype.shade = function(amount) {
17129
- if (amount === void 0) amount = 10;
17170
+ shade(amount = 10) {
17130
17171
  return this.mix("black", amount);
17131
- };
17172
+ }
17132
17173
  /**
17133
17174
  * Desaturate the color a given amount, from 0 to 100.
17134
17175
  * Providing 100 will is the same as calling greyscale
17135
17176
  * @param amount - valid between 1-100
17136
17177
  */
17137
- TinyColor.prototype.desaturate = function(amount) {
17138
- if (amount === void 0) amount = 10;
17139
- var hsl = this.toHsl();
17178
+ desaturate(amount = 10) {
17179
+ const hsl = this.toHsl();
17140
17180
  hsl.s -= amount / 100;
17141
17181
  hsl.s = clamp01(hsl.s);
17142
17182
  return new TinyColor(hsl);
17143
- };
17183
+ }
17144
17184
  /**
17145
17185
  * Saturate the color a given amount, from 0 to 100.
17146
17186
  * @param amount - valid between 1-100
17147
17187
  */
17148
- TinyColor.prototype.saturate = function(amount) {
17149
- if (amount === void 0) amount = 10;
17150
- var hsl = this.toHsl();
17188
+ saturate(amount = 10) {
17189
+ const hsl = this.toHsl();
17151
17190
  hsl.s += amount / 100;
17152
17191
  hsl.s = clamp01(hsl.s);
17153
17192
  return new TinyColor(hsl);
17154
- };
17193
+ }
17155
17194
  /**
17156
17195
  * Completely desaturates a color into greyscale.
17157
17196
  * Same as calling `desaturate(100)`
17158
17197
  */
17159
- TinyColor.prototype.greyscale = function() {
17198
+ greyscale() {
17160
17199
  return this.desaturate(100);
17161
- };
17200
+ }
17162
17201
  /**
17163
17202
  * Spin takes a positive or negative amount within [-360, 360] indicating the change of hue.
17164
17203
  * Values outside of this range will be wrapped into this range.
17165
17204
  */
17166
- TinyColor.prototype.spin = function(amount) {
17167
- var hsl = this.toHsl();
17168
- var hue = (hsl.h + amount) % 360;
17205
+ spin(amount) {
17206
+ const hsl = this.toHsl();
17207
+ const hue = (hsl.h + amount) % 360;
17169
17208
  hsl.h = hue < 0 ? 360 + hue : hue;
17170
17209
  return new TinyColor(hsl);
17171
- };
17210
+ }
17172
17211
  /**
17173
17212
  * Mix the current color a given amount with another color, from 0 to 100.
17174
17213
  * 0 means no mixing (return current color).
17175
17214
  */
17176
- TinyColor.prototype.mix = function(color, amount) {
17177
- if (amount === void 0) amount = 50;
17178
- var rgb1 = this.toRgb();
17179
- var rgb2 = new TinyColor(color).toRgb();
17180
- var p = amount / 100;
17215
+ mix(color, amount = 50) {
17216
+ const rgb1 = this.toRgb();
17217
+ const rgb2 = new TinyColor(color).toRgb();
17218
+ const p = amount / 100;
17181
17219
  return new TinyColor({
17182
17220
  r: (rgb2.r - rgb1.r) * p + rgb1.r,
17183
17221
  g: (rgb2.g - rgb1.g) * p + rgb1.g,
17184
17222
  b: (rgb2.b - rgb1.b) * p + rgb1.b,
17185
17223
  a: (rgb2.a - rgb1.a) * p + rgb1.a
17186
17224
  });
17187
- };
17188
- TinyColor.prototype.analogous = function(results, slices) {
17189
- if (results === void 0) results = 6;
17190
- if (slices === void 0) slices = 30;
17191
- var hsl = this.toHsl();
17192
- var part = 360 / slices;
17193
- var ret = [this];
17225
+ }
17226
+ analogous(results = 6, slices = 30) {
17227
+ const hsl = this.toHsl();
17228
+ const part = 360 / slices;
17229
+ const ret = [this];
17194
17230
  for (hsl.h = (hsl.h - (part * results >> 1) + 720) % 360; --results;) {
17195
17231
  hsl.h = (hsl.h + part) % 360;
17196
17232
  ret.push(new TinyColor(hsl));
17197
17233
  }
17198
17234
  return ret;
17199
- };
17235
+ }
17200
17236
  /**
17201
17237
  * taken from https://github.com/infusion/jQuery-xcolor/blob/master/jquery.xcolor.js
17202
17238
  */
17203
- TinyColor.prototype.complement = function() {
17204
- var hsl = this.toHsl();
17239
+ complement() {
17240
+ const hsl = this.toHsl();
17205
17241
  hsl.h = (hsl.h + 180) % 360;
17206
17242
  return new TinyColor(hsl);
17207
- };
17208
- TinyColor.prototype.monochromatic = function(results) {
17209
- if (results === void 0) results = 6;
17210
- var hsv = this.toHsv();
17211
- var h = hsv.h;
17212
- var s = hsv.s;
17213
- var v = hsv.v;
17214
- var res = [];
17215
- var modification = 1 / results;
17243
+ }
17244
+ monochromatic(results = 6) {
17245
+ const hsv = this.toHsv();
17246
+ const { h } = hsv;
17247
+ const { s } = hsv;
17248
+ let { v } = hsv;
17249
+ const res = [];
17250
+ const modification = 1 / results;
17216
17251
  while (results--) {
17217
17252
  res.push(new TinyColor({
17218
17253
  h,
@@ -17222,10 +17257,10 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
17222
17257
  v = (v + modification) % 1;
17223
17258
  }
17224
17259
  return res;
17225
- };
17226
- TinyColor.prototype.splitcomplement = function() {
17227
- var hsl = this.toHsl();
17228
- var h = hsl.h;
17260
+ }
17261
+ splitcomplement() {
17262
+ const hsl = this.toHsl();
17263
+ const { h } = hsl;
17229
17264
  return [
17230
17265
  this,
17231
17266
  new TinyColor({
@@ -17239,57 +17274,62 @@ usage: app.provide(ZINDEX_INJECTION_KEY, { current: 0 })`);
17239
17274
  l: hsl.l
17240
17275
  })
17241
17276
  ];
17242
- };
17277
+ }
17243
17278
  /**
17244
17279
  * Compute how the color would appear on a background
17245
17280
  */
17246
- TinyColor.prototype.onBackground = function(background) {
17247
- var fg = this.toRgb();
17248
- var bg = new TinyColor(background).toRgb();
17249
- var alpha = fg.a + bg.a * (1 - fg.a);
17281
+ onBackground(background) {
17282
+ const fg = this.toRgb();
17283
+ const bg = new TinyColor(background).toRgb();
17284
+ const alpha = fg.a + bg.a * (1 - fg.a);
17250
17285
  return new TinyColor({
17251
17286
  r: (fg.r * fg.a + bg.r * bg.a * (1 - fg.a)) / alpha,
17252
17287
  g: (fg.g * fg.a + bg.g * bg.a * (1 - fg.a)) / alpha,
17253
17288
  b: (fg.b * fg.a + bg.b * bg.a * (1 - fg.a)) / alpha,
17254
17289
  a: alpha
17255
17290
  });
17256
- };
17291
+ }
17257
17292
  /**
17258
17293
  * Alias for `polyad(3)`
17259
17294
  */
17260
- TinyColor.prototype.triad = function() {
17295
+ triad() {
17261
17296
  return this.polyad(3);
17262
- };
17297
+ }
17263
17298
  /**
17264
17299
  * Alias for `polyad(4)`
17265
17300
  */
17266
- TinyColor.prototype.tetrad = function() {
17301
+ tetrad() {
17267
17302
  return this.polyad(4);
17268
- };
17303
+ }
17269
17304
  /**
17270
17305
  * Get polyad colors, like (for 1, 2, 3, 4, 5, 6, 7, 8, etc...)
17271
17306
  * monad, dyad, triad, tetrad, pentad, hexad, heptad, octad, etc...
17272
17307
  */
17273
- TinyColor.prototype.polyad = function(n) {
17274
- var hsl = this.toHsl();
17275
- var h = hsl.h;
17276
- var result = [this];
17277
- var increment = 360 / n;
17278
- for (var i = 1; i < n; i++) result.push(new TinyColor({
17308
+ polyad(n) {
17309
+ const hsl = this.toHsl();
17310
+ const { h } = hsl;
17311
+ const result = [this];
17312
+ const increment = 360 / n;
17313
+ for (let i = 1; i < n; i++) result.push(new TinyColor({
17279
17314
  h: (h + i * increment) % 360,
17280
17315
  s: hsl.s,
17281
17316
  l: hsl.l
17282
17317
  }));
17283
17318
  return result;
17284
- };
17319
+ }
17285
17320
  /**
17286
17321
  * compare color vs current color
17287
17322
  */
17288
- TinyColor.prototype.equals = function(color) {
17289
- return this.toRgbString() === new TinyColor(color).toRgbString();
17290
- };
17291
- return TinyColor;
17292
- }();
17323
+ equals(color) {
17324
+ const comparedColor = new TinyColor(color);
17325
+ /**
17326
+ * RGB and CMYK do not have the same color gamut, so a CMYK conversion will never be 100%.
17327
+ * This means we need to compare CMYK to CMYK to ensure accuracy of the equals function.
17328
+ */
17329
+ if (this.format === "cmyk" || comparedColor.format === "cmyk") return this.toCmykString() === comparedColor.toCmykString();
17330
+ return this.toRgbString() === comparedColor.toRgbString();
17331
+ }
17332
+ };
17293
17333
 
17294
17334
  //#endregion
17295
17335
  //#region ../../packages/components/button/src/button-custom.ts
@@ -41282,7 +41322,7 @@ var import_advancedFormat = /* @__PURE__ */ __toESM(require_advancedFormat());
41282
41322
  default: 100
41283
41323
  },
41284
41324
  step: {
41285
- type: Number,
41325
+ type: definePropType([Number, String]),
41286
41326
  default: 1
41287
41327
  },
41288
41328
  showInput: Boolean,
@@ -41376,7 +41416,7 @@ var import_advancedFormat = /* @__PURE__ */ __toESM(require_advancedFormat());
41376
41416
  //#endregion
41377
41417
  //#region ../../packages/components/slider/src/composables/use-marks.ts
41378
41418
  const useMarks = (props) => {
41379
- return (0, vue.computed)(() => {
41419
+ const markList = (0, vue.computed)(() => {
41380
41420
  if (!props.marks) return [];
41381
41421
  return Object.keys(props.marks).map(Number.parseFloat).sort((a, b) => a - b).filter((point) => point <= props.max && point >= props.min).map((point) => ({
41382
41422
  point,
@@ -41384,6 +41424,19 @@ var import_advancedFormat = /* @__PURE__ */ __toESM(require_advancedFormat());
41384
41424
  mark: props.marks[point]
41385
41425
  }));
41386
41426
  });
41427
+ (0, vue.watchEffect)(() => {
41428
+ if (props.step === "mark" && !props.marks) /* @__PURE__ */ debugWarn("ElSlider", "marks prop must be provided when step is mark");
41429
+ if (props.marks) {
41430
+ const keys = Object.keys(props.marks);
41431
+ const validPoints = markList.value.map((m) => m.point);
41432
+ const invalidKeys = keys.filter((key) => {
41433
+ const parsed = Number.parseFloat(key);
41434
+ return Number.isNaN(parsed) || !validPoints.includes(parsed);
41435
+ });
41436
+ if (invalidKeys.length > 0) /* @__PURE__ */ debugWarn("ElSlider", `Some marks keys are invalid (not a number or out of [min, max]): [${invalidKeys.map((k) => `'${k}'`).join(", ")}] and will be ignored.`);
41437
+ }
41438
+ });
41439
+ return markList;
41387
41440
  };
41388
41441
 
41389
41442
  //#endregion
@@ -41527,7 +41580,7 @@ var import_advancedFormat = /* @__PURE__ */ __toESM(require_advancedFormat());
41527
41580
  };
41528
41581
  };
41529
41582
  const useSliderButton = (props, initData, emit) => {
41530
- const { disabled, min, max, step, showTooltip, persistent, precision, sliderSize, formatTooltip, emitChange, resetSize, updateDragging } = (0, vue.inject)(sliderContextKey);
41583
+ const { disabled, min, max, step, showTooltip, persistent, precision, sliderSize, formatTooltip, emitChange, resetSize, updateDragging, markList } = (0, vue.inject)(sliderContextKey);
41531
41584
  const { tooltip, tooltipVisible, formatValue, displayTooltip, hideTooltip } = useTooltip(props, formatTooltip, showTooltip);
41532
41585
  const button = (0, vue.ref)();
41533
41586
  const currentPosition = (0, vue.computed)(() => {
@@ -41536,6 +41589,9 @@ var import_advancedFormat = /* @__PURE__ */ __toESM(require_advancedFormat());
41536
41589
  const wrapperStyle = (0, vue.computed)(() => {
41537
41590
  return props.vertical ? { bottom: currentPosition.value } : { left: currentPosition.value };
41538
41591
  });
41592
+ const shouldMoveToMark = (0, vue.computed)(() => {
41593
+ return step.value === "mark" && markList.value.length > 0;
41594
+ });
41539
41595
  const handleMouseEnter = () => {
41540
41596
  initData.hovering = true;
41541
41597
  displayTooltip();
@@ -41561,17 +41617,49 @@ var import_advancedFormat = /* @__PURE__ */ __toESM(require_advancedFormat());
41561
41617
  setPosition(initData.newPosition);
41562
41618
  emitChange();
41563
41619
  };
41620
+ const moveToMark = (amount) => {
41621
+ if (disabled.value || !markList.value.length) return;
41622
+ const current = props.modelValue;
41623
+ const epsilon = Number.EPSILON;
41624
+ const stride = Math.abs(amount);
41625
+ let target;
41626
+ if (amount > 0) {
41627
+ const startIndex = markList.value.findIndex((m) => m.point > current + epsilon);
41628
+ if (startIndex !== -1) {
41629
+ const targetIndex = Math.min(startIndex + stride - 1, markList.value.length - 1);
41630
+ target = markList.value[targetIndex].point;
41631
+ }
41632
+ } else {
41633
+ let startIndex = -1;
41634
+ for (let i = markList.value.length - 1; i >= 0; i--) if (markList.value[i].point < current - epsilon) {
41635
+ startIndex = i;
41636
+ break;
41637
+ }
41638
+ if (startIndex !== -1) {
41639
+ const targetIndex = Math.max(startIndex - (stride - 1), 0);
41640
+ target = markList.value[targetIndex].point;
41641
+ }
41642
+ }
41643
+ if (target !== void 0 && target !== current) {
41644
+ setPosition((target - min.value) / (max.value - min.value) * 100);
41645
+ emitChange();
41646
+ }
41647
+ };
41564
41648
  const onLeftKeyDown = () => {
41565
- incrementPosition(-step.value);
41649
+ if (shouldMoveToMark.value) moveToMark(-1);
41650
+ else if (isNumber(step.value)) incrementPosition(-step.value);
41566
41651
  };
41567
41652
  const onRightKeyDown = () => {
41568
- incrementPosition(step.value);
41653
+ if (shouldMoveToMark.value) moveToMark(1);
41654
+ else if (isNumber(step.value)) incrementPosition(step.value);
41569
41655
  };
41570
41656
  const onPageDownKeyDown = () => {
41571
- incrementPosition(-step.value * 4);
41657
+ if (shouldMoveToMark.value) moveToMark(-4);
41658
+ else if (isNumber(step.value)) incrementPosition(-step.value * 4);
41572
41659
  };
41573
41660
  const onPageUpKeyDown = () => {
41574
- incrementPosition(step.value * 4);
41661
+ if (shouldMoveToMark.value) moveToMark(4);
41662
+ else if (isNumber(step.value)) incrementPosition(step.value * 4);
41575
41663
  };
41576
41664
  const onHomeKeyDown = () => {
41577
41665
  if (disabled.value) return;
@@ -41673,17 +41761,23 @@ var import_advancedFormat = /* @__PURE__ */ __toESM(require_advancedFormat());
41673
41761
  const setPosition = async (newPosition) => {
41674
41762
  if (newPosition === null || Number.isNaN(+newPosition)) return;
41675
41763
  newPosition = clamp$1(newPosition, 0, 100);
41676
- const fullSteps = Math.floor((max.value - min.value) / step.value);
41677
- const fullRangePercentage = fullSteps * step.value / (max.value - min.value) * 100;
41678
- const threshold = fullRangePercentage + (100 - fullRangePercentage) / 2;
41679
41764
  let value;
41680
- if (newPosition < fullRangePercentage) {
41681
- const valueBetween = fullRangePercentage / fullSteps;
41682
- const steps = Math.round(newPosition / valueBetween);
41683
- value = min.value + steps * step.value;
41684
- } else if (newPosition < threshold) value = min.value + fullSteps * step.value;
41685
- else value = max.value;
41686
- value = Number.parseFloat(value.toFixed(precision.value));
41765
+ if (step.value === "mark") if (markList.value.length === 0) value = newPosition <= 50 ? min.value : max.value;
41766
+ else value = markList.value.reduce((prev, curr) => {
41767
+ return Math.abs(curr.position - newPosition) < Math.abs(prev.position - newPosition) ? curr : prev;
41768
+ }).point;
41769
+ else {
41770
+ const fullSteps = Math.floor((max.value - min.value) / step.value);
41771
+ const fullRangePercentage = fullSteps * step.value / (max.value - min.value) * 100;
41772
+ const threshold = fullRangePercentage + (100 - fullRangePercentage) / 2;
41773
+ if (newPosition < fullRangePercentage) {
41774
+ const valueBetween = fullRangePercentage / fullSteps;
41775
+ const steps = Math.round(newPosition / valueBetween);
41776
+ value = min.value + steps * step.value;
41777
+ } else if (newPosition < threshold) value = min.value + fullSteps * step.value;
41778
+ else value = max.value;
41779
+ value = Number.parseFloat(value.toFixed(precision.value));
41780
+ }
41687
41781
  if (value !== props.modelValue) emit(UPDATE_MODEL_EVENT, value);
41688
41782
  if (!initData.dragging && props.modelValue !== initData.oldValue) initData.oldValue = props.modelValue;
41689
41783
  await (0, vue.nextTick)();
@@ -41716,8 +41810,8 @@ var import_advancedFormat = /* @__PURE__ */ __toESM(require_advancedFormat());
41716
41810
  const useStops = (props, initData, minValue, maxValue) => {
41717
41811
  const stops = (0, vue.computed)(() => {
41718
41812
  if (!props.showStops || props.min > props.max) return [];
41719
- if (props.step === 0) {
41720
- /* @__PURE__ */ debugWarn("ElSlider", "step should not be 0.");
41813
+ if (props.step === "mark" || props.step === 0) {
41814
+ if (props.step === 0) /* @__PURE__ */ debugWarn("ElSlider", "step should not be 0.");
41721
41815
  return [];
41722
41816
  }
41723
41817
  const stopCount = Math.ceil((props.max - props.min) / props.step);
@@ -41943,6 +42037,9 @@ var import_advancedFormat = /* @__PURE__ */ __toESM(require_advancedFormat());
41943
42037
  const { inputId, isLabeledByFormItem } = useFormItemInputId(props, { formItemContext: elFormItem });
41944
42038
  const sliderWrapperSize = useFormSize();
41945
42039
  const sliderInputSize = (0, vue.computed)(() => props.inputSize || sliderWrapperSize.value);
42040
+ const renderInput = (0, vue.computed)(() => {
42041
+ return props.showInput && !props.range && props.step !== "mark";
42042
+ });
41946
42043
  const groupLabel = (0, vue.computed)(() => {
41947
42044
  return props.ariaLabel || t("el.slider.defaultLabel", {
41948
42045
  min: props.min,
@@ -41966,15 +42063,19 @@ var import_advancedFormat = /* @__PURE__ */ __toESM(require_advancedFormat());
41966
42063
  ns.b(),
41967
42064
  ns.m(sliderWrapperSize.value),
41968
42065
  ns.is("vertical", props.vertical),
41969
- { [ns.m("with-input")]: props.showInput }
42066
+ { [ns.m("with-input")]: renderInput.value }
41970
42067
  ]);
41971
42068
  const markList = useMarks(props);
41972
42069
  useWatch(props, initData, minValue, maxValue, emit, elFormItem);
42070
+ const sliderInputStep = (0, vue.computed)(() => {
42071
+ return isNumber(props.step) ? props.step : 1;
42072
+ });
41973
42073
  const precision = (0, vue.computed)(() => {
42074
+ const stepValue = isNumber(props.step) ? props.step : 1;
41974
42075
  const precisions = [
41975
42076
  props.min,
41976
42077
  props.max,
41977
- props.step
42078
+ stepValue
41978
42079
  ].map((item) => {
41979
42080
  const decimal = `${item}`.split(".")[1];
41980
42081
  return decimal ? decimal.length : 0;
@@ -41993,6 +42094,7 @@ var import_advancedFormat = /* @__PURE__ */ __toESM(require_advancedFormat());
41993
42094
  sliderSize,
41994
42095
  disabled: sliderDisabled,
41995
42096
  precision,
42097
+ markList,
41996
42098
  emitChange,
41997
42099
  resetSize,
41998
42100
  updateDragging
@@ -42012,7 +42114,7 @@ var import_advancedFormat = /* @__PURE__ */ __toESM(require_advancedFormat());
42012
42114
  ref: slider,
42013
42115
  class: (0, vue.normalizeClass)([
42014
42116
  (0, vue.unref)(ns).e("runway"),
42015
- { "show-input": _ctx.showInput && !_ctx.range },
42117
+ { "show-input": renderInput.value },
42016
42118
  (0, vue.unref)(ns).is("disabled", (0, vue.unref)(sliderDisabled))
42017
42119
  ]),
42018
42120
  style: (0, vue.normalizeStyle)((0, vue.unref)(runwayStyle)),
@@ -42113,12 +42215,12 @@ var import_advancedFormat = /* @__PURE__ */ __toESM(require_advancedFormat());
42113
42215
  "onMousedown"
42114
42216
  ]);
42115
42217
  }), 128))], 2)], 64)) : (0, vue.createCommentVNode)("v-if", true)
42116
- ], 38), _ctx.showInput && !_ctx.range ? ((0, vue.openBlock)(), (0, vue.createBlock)((0, vue.unref)(ElInputNumber), {
42218
+ ], 38), renderInput.value ? ((0, vue.openBlock)(), (0, vue.createBlock)((0, vue.unref)(ElInputNumber), {
42117
42219
  key: 0,
42118
42220
  ref: "input",
42119
42221
  "model-value": (0, vue.unref)(firstValue),
42120
42222
  class: (0, vue.normalizeClass)((0, vue.unref)(ns).e("input")),
42121
- step: _ctx.step,
42223
+ step: sliderInputStep.value,
42122
42224
  disabled: (0, vue.unref)(sliderDisabled),
42123
42225
  controls: _ctx.showInputControls,
42124
42226
  min: _ctx.min,