zartui 3.0.6 → 3.0.8

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 (446) hide show
  1. package/es/button/Button.d.ts +3 -0
  2. package/es/button/Button.mjs +2 -0
  3. package/es/button/index.d.ts +2 -0
  4. package/es/calendar/Calendar.d.ts +23 -33
  5. package/es/calendar/Calendar.mjs +124 -31
  6. package/es/calendar/CalendarDay.mjs +1 -1
  7. package/es/calendar/CalendarHeader.d.ts +15 -1
  8. package/es/calendar/CalendarHeader.mjs +106 -4
  9. package/es/calendar/CalendarMonth.d.ts +23 -24
  10. package/es/calendar/CalendarMonth.mjs +49 -8
  11. package/es/calendar/index.css +1 -1
  12. package/es/calendar/index.d.ts +15 -22
  13. package/es/calendar/types.d.ts +3 -1
  14. package/es/calendar/utils.d.ts +4 -1
  15. package/es/calendar/utils.mjs +23 -3
  16. package/es/cascader/Cascader.mjs +1 -3
  17. package/es/cascader/index.css +1 -1
  18. package/es/checkbox/Checkbox.d.ts +1 -1
  19. package/es/checkbox/Checker.d.ts +2 -2
  20. package/es/checkbox/index.d.ts +1 -1
  21. package/es/collapse-item/CollapseItem.mjs +3 -1
  22. package/es/date-time-picker/DateTimePicker.d.ts +1 -1
  23. package/es/date-time-picker/DateTimePicker.mjs +9 -3
  24. package/es/date-time-picker/DateTimePickerWrapper.d.ts +1 -1
  25. package/es/date-time-picker/index.d.ts +1 -1
  26. package/es/dialog/Dialog.d.ts +4 -0
  27. package/es/dialog/Dialog.mjs +24 -9
  28. package/es/dialog/index.css +1 -1
  29. package/es/dialog/index.d.ts +3 -0
  30. package/es/dialog/types.d.ts +1 -0
  31. package/es/divider/index.css +1 -1
  32. package/es/dropdown-item/DropdownItem.mjs +7 -4
  33. package/es/dropdown-menu/DropdownMenu.mjs +2 -2
  34. package/es/dropdown-menu/types.d.ts +1 -0
  35. package/es/empty/Images.mjs +9 -9
  36. package/es/empty/index.css +1 -1
  37. package/es/field/Field.d.ts +3 -0
  38. package/es/field/Field.mjs +2 -1
  39. package/es/field/index.d.ts +2 -0
  40. package/es/hierarchy-select/Breadcrumb.d.ts +43 -0
  41. package/es/hierarchy-select/Breadcrumb.mjs +56 -0
  42. package/es/hierarchy-select/HierarchySelect.d.ts +104 -0
  43. package/es/hierarchy-select/HierarchySelect.mjs +221 -0
  44. package/es/hierarchy-select/index.css +1 -0
  45. package/es/hierarchy-select/index.d.ts +79 -0
  46. package/es/hierarchy-select/index.mjs +8 -0
  47. package/es/hierarchy-select/style/index.d.ts +1 -0
  48. package/es/hierarchy-select/style/index.mjs +8 -0
  49. package/es/hierarchy-select/svg/SubIcon.d.ts +1 -0
  50. package/es/hierarchy-select/svg/SubIcon.mjs +33 -0
  51. package/es/hierarchy-select/types.d.ts +7 -0
  52. package/es/hierarchy-select/types.mjs +0 -0
  53. package/es/icon/config.mjs +4 -1
  54. package/es/icon/index.css +1 -1
  55. package/es/image-preview/ImagePreview.mjs +1 -1
  56. package/es/index-anchor/IndexAnchor.d.ts +11 -0
  57. package/es/index-anchor/IndexAnchor.mjs +88 -0
  58. package/es/index-anchor/index.css +1 -0
  59. package/es/index-anchor/index.d.ts +14 -0
  60. package/es/index-anchor/index.mjs +10 -0
  61. package/es/index-anchor/style/index.d.ts +1 -0
  62. package/es/index-anchor/style/index.mjs +3 -0
  63. package/es/index-anchor/types.d.ts +11 -0
  64. package/es/index-anchor/types.mjs +0 -0
  65. package/es/index-bar/IndexBar.d.ts +64 -0
  66. package/es/index-bar/IndexBar.mjs +275 -0
  67. package/es/index-bar/index.css +1 -0
  68. package/es/index-bar/index.d.ts +50 -0
  69. package/es/index-bar/index.mjs +10 -0
  70. package/es/index-bar/style/index.d.ts +1 -0
  71. package/es/index-bar/style/index.mjs +2 -0
  72. package/es/index-bar/types.d.ts +16 -0
  73. package/es/index-bar/types.mjs +0 -0
  74. package/es/index.d.ts +8 -1
  75. package/es/index.mjs +22 -1
  76. package/es/lazyload/vue-lazyload/index.mjs +5 -0
  77. package/es/lazyload/vue-lazyload/lazy.mjs +81 -0
  78. package/es/lazyload/vue-lazyload/listener.mjs +45 -0
  79. package/es/list/List.mjs +2 -4
  80. package/es/list/index.css +1 -1
  81. package/es/locale/lang/en-US.d.ts +7 -23
  82. package/es/locale/lang/en-US.mjs +7 -23
  83. package/es/locale/lang/zh-CN.d.ts +7 -23
  84. package/es/locale/lang/zh-CN.mjs +7 -23
  85. package/es/media-picker/MediaPicker.mjs +20 -0
  86. package/es/media-picker/image/PickFileIcon.mjs +1 -1
  87. package/es/media-picker/image/PickPhotoIcon.mjs +1 -1
  88. package/es/media-picker/image/TakeAudioIcon.mjs +1 -1
  89. package/es/media-picker/image/TakePhotoIcon.mjs +1 -1
  90. package/es/media-picker/image/TakeVideoIcon.mjs +1 -1
  91. package/es/media-picker/index.css +1 -1
  92. package/es/media-picker/util/media-util.mjs +3 -0
  93. package/es/media-picker/watermark/image-processor.mjs +10 -6
  94. package/es/media-picker/watermark/resize-options.mjs +1 -0
  95. package/es/media-picker/watermark/watermark.mjs +4 -0
  96. package/es/multiple-picker/MultiplePicker.d.ts +4 -4
  97. package/es/multiple-picker/MultiplePicker.mjs +3 -3
  98. package/es/multiple-picker/MultiplePickerOptions.d.ts +4 -4
  99. package/es/multiple-picker/MultiplePickerOptions.mjs +3 -3
  100. package/es/multiple-picker/index.d.ts +3 -3
  101. package/es/notice-bar/index.css +1 -1
  102. package/es/overlay/index.d.ts +1 -1
  103. package/es/picker/Picker.mjs +7 -4
  104. package/es/picker/PickerToolbar.mjs +1 -0
  105. package/es/popover/Popover.d.ts +13 -0
  106. package/es/popover/Popover.mjs +99 -4
  107. package/es/popover/index.css +1 -1
  108. package/es/popover/index.d.ts +9 -0
  109. package/es/popup/Popup.mjs +1 -0
  110. package/es/popup/index.css +1 -1
  111. package/es/popup/shared.mjs +12 -0
  112. package/es/radio/Radio.d.ts +1 -1
  113. package/es/radio/index.d.ts +1 -1
  114. package/es/rate/index.css +1 -1
  115. package/es/search/Search.d.ts +1 -1
  116. package/es/search/Search.mjs +1 -0
  117. package/es/search/index.d.ts +1 -1
  118. package/es/signature/Signature.mjs +13 -10
  119. package/es/signature/index.css +1 -1
  120. package/es/step/Step.mjs +10 -6
  121. package/es/step/index.css +1 -1
  122. package/es/stepper/Stepper.mjs +2 -0
  123. package/es/stepper/index.css +1 -1
  124. package/es/steps/index.css +1 -1
  125. package/es/sticky/Sticky.mjs +2 -0
  126. package/es/style/base.css +1 -1
  127. package/es/style/css-variables.css +1 -1
  128. package/es/swipe/Swipe.d.ts +3 -1
  129. package/es/swipe/Swipe.mjs +19 -2
  130. package/es/swipe/index.d.ts +3 -1
  131. package/es/swipe-cell/SwipeCell.d.ts +44 -0
  132. package/es/swipe-cell/SwipeCell.mjs +163 -0
  133. package/es/swipe-cell/index.css +1 -0
  134. package/es/swipe-cell/index.d.ts +39 -0
  135. package/es/swipe-cell/index.mjs +10 -0
  136. package/es/swipe-cell/style/index.d.ts +1 -0
  137. package/es/swipe-cell/style/index.mjs +2 -0
  138. package/es/swipe-cell/types.d.ts +9 -0
  139. package/es/swipe-cell/types.mjs +0 -0
  140. package/es/switch/index.css +1 -1
  141. package/es/tabbar-item/index.css +1 -1
  142. package/es/table/Table.d.ts +118 -0
  143. package/es/table/Table.mjs +209 -0
  144. package/es/table/index.css +1 -0
  145. package/es/table/index.d.ts +77 -0
  146. package/es/table/index.mjs +10 -0
  147. package/es/table/style/index.d.ts +1 -0
  148. package/es/table/style/index.mjs +4 -0
  149. package/es/table/types.d.ts +5 -0
  150. package/es/table/types.mjs +8 -0
  151. package/es/tabs/Tabs.mjs +2 -0
  152. package/es/tabs/index.css +1 -1
  153. package/es/tag/Tag.d.ts +21 -1
  154. package/es/tag/Tag.mjs +63 -10
  155. package/es/tag/index.css +1 -1
  156. package/es/tag/index.d.ts +15 -1
  157. package/es/tag/style/index.mjs +1 -0
  158. package/es/text-ellipsis/TextEllipsis.d.ts +76 -0
  159. package/es/text-ellipsis/TextEllipsis.mjs +118 -0
  160. package/es/text-ellipsis/index.css +1 -0
  161. package/es/text-ellipsis/index.d.ts +60 -0
  162. package/es/text-ellipsis/index.mjs +10 -0
  163. package/es/text-ellipsis/style/index.d.ts +1 -0
  164. package/es/text-ellipsis/style/index.mjs +2 -0
  165. package/es/text-ellipsis/types.d.ts +3 -0
  166. package/es/text-ellipsis/types.mjs +0 -0
  167. package/es/timeline/Timeline.d.ts +113 -0
  168. package/es/timeline/Timeline.mjs +162 -0
  169. package/es/timeline/index.css +1 -0
  170. package/es/timeline/index.d.ts +75 -0
  171. package/es/timeline/index.mjs +10 -0
  172. package/es/timeline/style/index.d.ts +1 -0
  173. package/es/timeline/style/index.mjs +4 -0
  174. package/es/uploader/Uploader.d.ts +1 -1
  175. package/es/uploader/UploaderPreviewItem.d.ts +1 -1
  176. package/es/uploader/index.d.ts +1 -1
  177. package/es/uploader/utils.mjs +1 -1
  178. package/es/utils/dom.d.ts +1 -0
  179. package/es/utils/dom.mjs +11 -0
  180. package/lib/action-sheet/index.js +4 -0
  181. package/lib/avatar/Avatar.js +4 -0
  182. package/lib/avatar/index.js +4 -0
  183. package/lib/badge/index.js +4 -0
  184. package/lib/button/Button.d.ts +3 -0
  185. package/lib/button/Button.js +2 -0
  186. package/lib/button/index.d.ts +2 -0
  187. package/lib/button/index.js +4 -0
  188. package/lib/calendar/Calendar.d.ts +23 -33
  189. package/lib/calendar/Calendar.js +127 -30
  190. package/lib/calendar/CalendarDay.js +1 -1
  191. package/lib/calendar/CalendarHeader.d.ts +15 -1
  192. package/lib/calendar/CalendarHeader.js +106 -4
  193. package/lib/calendar/CalendarMonth.d.ts +23 -24
  194. package/lib/calendar/CalendarMonth.js +52 -7
  195. package/lib/calendar/index.css +1 -1
  196. package/lib/calendar/index.d.ts +15 -22
  197. package/lib/calendar/index.js +4 -0
  198. package/lib/calendar/types.d.ts +3 -1
  199. package/lib/calendar/utils.d.ts +4 -1
  200. package/lib/calendar/utils.js +23 -3
  201. package/lib/cascader/Cascader.js +5 -3
  202. package/lib/cascader/index.css +1 -1
  203. package/lib/cascader/index.js +4 -0
  204. package/lib/cell/index.js +4 -0
  205. package/lib/cell-group/index.js +4 -0
  206. package/lib/checkbox/Checkbox.d.ts +1 -1
  207. package/lib/checkbox/Checkbox.js +4 -0
  208. package/lib/checkbox/Checker.d.ts +2 -2
  209. package/lib/checkbox/index.d.ts +1 -1
  210. package/lib/checkbox/index.js +4 -0
  211. package/lib/checkbox-group/index.js +4 -0
  212. package/lib/col/index.js +4 -0
  213. package/lib/collapse/index.js +4 -0
  214. package/lib/collapse-item/CollapseItem.js +7 -1
  215. package/lib/collapse-item/index.js +4 -0
  216. package/lib/config-provider/index.js +4 -0
  217. package/lib/date-time-picker/DateTimePicker.d.ts +1 -1
  218. package/lib/date-time-picker/DateTimePicker.js +13 -3
  219. package/lib/date-time-picker/DateTimePickerWrapper.d.ts +1 -1
  220. package/lib/date-time-picker/DateTimePickerWrapper.js +4 -0
  221. package/lib/date-time-picker/index.d.ts +1 -1
  222. package/lib/date-time-picker/index.js +4 -0
  223. package/lib/dialog/Dialog.d.ts +4 -0
  224. package/lib/dialog/Dialog.js +24 -9
  225. package/lib/dialog/function-call.js +4 -0
  226. package/lib/dialog/index.css +1 -1
  227. package/lib/dialog/index.d.ts +3 -0
  228. package/lib/dialog/index.js +4 -0
  229. package/lib/dialog/types.d.ts +1 -0
  230. package/lib/divider/index.css +1 -1
  231. package/lib/divider/index.js +4 -0
  232. package/lib/dropdown-item/DropdownItem.js +6 -3
  233. package/lib/dropdown-item/index.js +4 -0
  234. package/lib/dropdown-menu/DropdownMenu.js +6 -2
  235. package/lib/dropdown-menu/index.js +4 -0
  236. package/lib/dropdown-menu/types.d.ts +1 -0
  237. package/lib/empty/Images.js +9 -9
  238. package/lib/empty/index.css +1 -1
  239. package/lib/empty/index.js +4 -0
  240. package/lib/field/Field.d.ts +3 -0
  241. package/lib/field/Field.js +2 -1
  242. package/lib/field/index.d.ts +2 -0
  243. package/lib/field/index.js +4 -0
  244. package/lib/form/index.js +4 -0
  245. package/lib/grid/index.js +4 -0
  246. package/lib/grid-item/index.js +4 -0
  247. package/lib/hierarchy-select/Breadcrumb.d.ts +43 -0
  248. package/lib/hierarchy-select/Breadcrumb.js +85 -0
  249. package/lib/hierarchy-select/HierarchySelect.d.ts +104 -0
  250. package/lib/hierarchy-select/HierarchySelect.js +250 -0
  251. package/lib/hierarchy-select/index.css +1 -0
  252. package/lib/hierarchy-select/index.d.ts +79 -0
  253. package/lib/hierarchy-select/index.js +37 -0
  254. package/lib/hierarchy-select/style/index.d.ts +1 -0
  255. package/lib/hierarchy-select/style/index.js +8 -0
  256. package/lib/hierarchy-select/svg/SubIcon.d.ts +1 -0
  257. package/lib/hierarchy-select/svg/SubIcon.js +52 -0
  258. package/lib/hierarchy-select/types.d.ts +7 -0
  259. package/lib/hierarchy-select/types.js +15 -0
  260. package/lib/icon/config.js +4 -1
  261. package/lib/icon/index.css +1 -1
  262. package/lib/icon/index.js +4 -0
  263. package/lib/image/index.js +4 -0
  264. package/lib/image-preview/ImagePreview.js +5 -1
  265. package/lib/image-preview/function-call.js +4 -0
  266. package/lib/image-preview/index.js +4 -0
  267. package/lib/index-anchor/IndexAnchor.d.ts +11 -0
  268. package/lib/index-anchor/IndexAnchor.js +107 -0
  269. package/lib/index-anchor/index.css +1 -0
  270. package/lib/index-anchor/index.d.ts +14 -0
  271. package/lib/index-anchor/index.js +39 -0
  272. package/lib/index-anchor/style/index.d.ts +1 -0
  273. package/lib/index-anchor/style/index.js +3 -0
  274. package/lib/index-anchor/types.d.ts +11 -0
  275. package/lib/index-anchor/types.js +15 -0
  276. package/lib/index-bar/IndexBar.d.ts +64 -0
  277. package/lib/index-bar/IndexBar.js +294 -0
  278. package/lib/index-bar/index.css +1 -0
  279. package/lib/index-bar/index.d.ts +50 -0
  280. package/lib/index-bar/index.js +39 -0
  281. package/lib/index-bar/style/index.d.ts +1 -0
  282. package/lib/index-bar/style/index.js +2 -0
  283. package/lib/index-bar/types.d.ts +16 -0
  284. package/lib/index-bar/types.js +15 -0
  285. package/lib/index.css +1 -1
  286. package/lib/index.d.ts +8 -1
  287. package/lib/index.js +22 -1
  288. package/lib/lazyload/vue-lazyload/index.js +9 -0
  289. package/lib/lazyload/vue-lazyload/lazy.js +85 -0
  290. package/lib/lazyload/vue-lazyload/listener.js +45 -0
  291. package/lib/list/List.js +2 -4
  292. package/lib/list/index.css +1 -1
  293. package/lib/list/index.js +4 -0
  294. package/lib/loading/index.js +4 -0
  295. package/lib/locale/index.js +4 -0
  296. package/lib/locale/lang/en-US.d.ts +7 -23
  297. package/lib/locale/lang/en-US.js +7 -23
  298. package/lib/locale/lang/zh-CN.d.ts +7 -23
  299. package/lib/locale/lang/zh-CN.js +7 -23
  300. package/lib/media-picker/MediaPicker.js +24 -0
  301. package/lib/media-picker/image/PickFileIcon.js +1 -1
  302. package/lib/media-picker/image/PickPhotoIcon.js +1 -1
  303. package/lib/media-picker/image/TakeAudioIcon.js +1 -1
  304. package/lib/media-picker/image/TakePhotoIcon.js +1 -1
  305. package/lib/media-picker/image/TakeVideoIcon.js +1 -1
  306. package/lib/media-picker/index.css +1 -1
  307. package/lib/media-picker/index.js +4 -0
  308. package/lib/media-picker/util/media-util.js +3 -0
  309. package/lib/media-picker/watermark/image-processor.js +10 -6
  310. package/lib/media-picker/watermark/resize-options.js +1 -0
  311. package/lib/media-picker/watermark/watermark.js +4 -0
  312. package/lib/media-player/MediaPlayer.js +4 -0
  313. package/lib/media-player/index.js +4 -0
  314. package/lib/multiple-picker/MultiplePicker.d.ts +4 -4
  315. package/lib/multiple-picker/MultiplePicker.js +7 -3
  316. package/lib/multiple-picker/MultiplePickerOptions.d.ts +4 -4
  317. package/lib/multiple-picker/MultiplePickerOptions.js +3 -3
  318. package/lib/multiple-picker/index.d.ts +3 -3
  319. package/lib/multiple-picker/index.js +4 -0
  320. package/lib/nav-bar/index.js +4 -0
  321. package/lib/notice-bar/NoticeBar.js +4 -0
  322. package/lib/notice-bar/index.css +1 -1
  323. package/lib/notice-bar/index.js +4 -0
  324. package/lib/notify/function-call.js +4 -0
  325. package/lib/notify/index.js +4 -0
  326. package/lib/number-keyboard/NumberKeyboard.js +4 -0
  327. package/lib/number-keyboard/NumberKeyboardKey.js +4 -0
  328. package/lib/number-keyboard/index.js +4 -0
  329. package/lib/overlay/index.d.ts +1 -1
  330. package/lib/overlay/index.js +4 -0
  331. package/lib/password-input/index.js +4 -0
  332. package/lib/picker/Picker.js +10 -3
  333. package/lib/picker/PickerToolbar.js +1 -0
  334. package/lib/picker/index.js +4 -0
  335. package/lib/popover/Popover.d.ts +13 -0
  336. package/lib/popover/Popover.js +98 -3
  337. package/lib/popover/index.css +1 -1
  338. package/lib/popover/index.d.ts +9 -0
  339. package/lib/popover/index.js +4 -0
  340. package/lib/popup/Popup.js +1 -0
  341. package/lib/popup/index.css +1 -1
  342. package/lib/popup/index.js +4 -0
  343. package/lib/popup/shared.js +12 -0
  344. package/lib/pull-refresh/index.js +4 -0
  345. package/lib/radio/Radio.d.ts +1 -1
  346. package/lib/radio/Radio.js +4 -0
  347. package/lib/radio/index.d.ts +1 -1
  348. package/lib/radio/index.js +4 -0
  349. package/lib/radio-group/index.js +4 -0
  350. package/lib/rate/index.css +1 -1
  351. package/lib/rate/index.js +4 -0
  352. package/lib/row/index.js +4 -0
  353. package/lib/search/Search.d.ts +1 -1
  354. package/lib/search/Search.js +1 -0
  355. package/lib/search/index.d.ts +1 -1
  356. package/lib/search/index.js +4 -0
  357. package/lib/signature/Signature.js +16 -9
  358. package/lib/signature/index.css +1 -1
  359. package/lib/signature/index.js +4 -0
  360. package/lib/skeleton/index.js +4 -0
  361. package/lib/step/Step.js +10 -6
  362. package/lib/step/index.css +1 -1
  363. package/lib/step/index.js +4 -0
  364. package/lib/stepper/Stepper.js +6 -0
  365. package/lib/stepper/index.css +1 -1
  366. package/lib/stepper/index.js +4 -0
  367. package/lib/steps/index.css +1 -1
  368. package/lib/steps/index.js +4 -0
  369. package/lib/sticky/Sticky.js +2 -0
  370. package/lib/sticky/index.js +4 -0
  371. package/lib/style/base.css +1 -1
  372. package/lib/style/css-variables.css +1 -1
  373. package/lib/swipe/Swipe.d.ts +3 -1
  374. package/lib/swipe/Swipe.js +19 -2
  375. package/lib/swipe/index.d.ts +3 -1
  376. package/lib/swipe/index.js +4 -0
  377. package/lib/swipe-cell/SwipeCell.d.ts +44 -0
  378. package/lib/swipe-cell/SwipeCell.js +182 -0
  379. package/lib/swipe-cell/index.css +1 -0
  380. package/lib/swipe-cell/index.d.ts +39 -0
  381. package/lib/swipe-cell/index.js +39 -0
  382. package/lib/swipe-cell/style/index.d.ts +1 -0
  383. package/lib/swipe-cell/style/index.js +2 -0
  384. package/lib/swipe-cell/types.d.ts +9 -0
  385. package/lib/swipe-cell/types.js +15 -0
  386. package/lib/swipe-item/index.js +4 -0
  387. package/lib/switch/index.css +1 -1
  388. package/lib/switch/index.js +4 -0
  389. package/lib/tab/index.js +4 -0
  390. package/lib/tabbar/index.js +4 -0
  391. package/lib/tabbar-item/index.css +1 -1
  392. package/lib/tabbar-item/index.js +4 -0
  393. package/lib/table/Table.d.ts +118 -0
  394. package/lib/table/Table.js +228 -0
  395. package/lib/table/index.css +1 -0
  396. package/lib/table/index.d.ts +77 -0
  397. package/lib/table/index.js +39 -0
  398. package/lib/table/style/index.d.ts +1 -0
  399. package/lib/table/style/index.js +4 -0
  400. package/lib/table/types.d.ts +5 -0
  401. package/lib/table/types.js +27 -0
  402. package/lib/tabs/Tabs.js +6 -0
  403. package/lib/tabs/index.css +1 -1
  404. package/lib/tabs/index.js +4 -0
  405. package/lib/tag/Tag.d.ts +21 -1
  406. package/lib/tag/Tag.js +73 -10
  407. package/lib/tag/index.css +1 -1
  408. package/lib/tag/index.d.ts +15 -1
  409. package/lib/tag/index.js +4 -0
  410. package/lib/tag/style/index.js +1 -0
  411. package/lib/text-ellipsis/TextEllipsis.d.ts +76 -0
  412. package/lib/text-ellipsis/TextEllipsis.js +137 -0
  413. package/lib/text-ellipsis/index.css +1 -0
  414. package/lib/text-ellipsis/index.d.ts +60 -0
  415. package/lib/text-ellipsis/index.js +39 -0
  416. package/lib/text-ellipsis/style/index.d.ts +1 -0
  417. package/lib/text-ellipsis/style/index.js +2 -0
  418. package/lib/text-ellipsis/types.d.ts +3 -0
  419. package/lib/text-ellipsis/types.js +15 -0
  420. package/lib/time-picker/TimePicker.js +4 -0
  421. package/lib/time-picker/TimePickerColumn.js +4 -0
  422. package/lib/time-picker/index.js +4 -0
  423. package/lib/timeline/Timeline.d.ts +113 -0
  424. package/lib/timeline/Timeline.js +191 -0
  425. package/lib/timeline/index.css +1 -0
  426. package/lib/timeline/index.d.ts +75 -0
  427. package/lib/timeline/index.js +39 -0
  428. package/lib/timeline/style/index.d.ts +1 -0
  429. package/lib/timeline/style/index.js +4 -0
  430. package/lib/toast/function-call.js +4 -0
  431. package/lib/toast/index.js +4 -0
  432. package/lib/uploader/Uploader.d.ts +1 -1
  433. package/lib/uploader/Uploader.js +4 -0
  434. package/lib/uploader/UploaderPreviewItem.d.ts +1 -1
  435. package/lib/uploader/index.d.ts +1 -1
  436. package/lib/uploader/index.js +4 -0
  437. package/lib/uploader/utils.js +1 -1
  438. package/lib/utils/create.js +4 -0
  439. package/lib/utils/dom.d.ts +1 -0
  440. package/lib/utils/dom.js +11 -0
  441. package/lib/web-types.json +1 -1
  442. package/lib/zartui.cjs.js +3054 -1076
  443. package/lib/zartui.es.js +3102 -1124
  444. package/lib/zartui.js +3817 -1303
  445. package/lib/zartui.min.js +1 -1
  446. package/package.json +18 -17
@@ -0,0 +1,75 @@
1
+ export declare const Timeline: import("../utils").WithInstall<import("vue").DefineComponent<{
2
+ title: {
3
+ type: import("vue").PropType<string>;
4
+ default: string;
5
+ };
6
+ defaultFold: {
7
+ type: BooleanConstructor;
8
+ default: boolean;
9
+ };
10
+ collapseCount: {
11
+ type: NumberConstructor;
12
+ default: number;
13
+ };
14
+ processes: {
15
+ type: import("vue").PropType<import("./Timeline").TimelineProcessOption[]>;
16
+ default: () => import("./Timeline").TimelineProcessOption[];
17
+ };
18
+ opinionKey: {
19
+ type: import("vue").PropType<string>;
20
+ default: string;
21
+ };
22
+ enableSingleFold: {
23
+ type: BooleanConstructor;
24
+ default: true;
25
+ };
26
+ dot: {
27
+ type: BooleanConstructor;
28
+ default: boolean;
29
+ };
30
+ }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
31
+ title: {
32
+ type: import("vue").PropType<string>;
33
+ default: string;
34
+ };
35
+ defaultFold: {
36
+ type: BooleanConstructor;
37
+ default: boolean;
38
+ };
39
+ collapseCount: {
40
+ type: NumberConstructor;
41
+ default: number;
42
+ };
43
+ processes: {
44
+ type: import("vue").PropType<import("./Timeline").TimelineProcessOption[]>;
45
+ default: () => import("./Timeline").TimelineProcessOption[];
46
+ };
47
+ opinionKey: {
48
+ type: import("vue").PropType<string>;
49
+ default: string;
50
+ };
51
+ enableSingleFold: {
52
+ type: BooleanConstructor;
53
+ default: true;
54
+ };
55
+ dot: {
56
+ type: BooleanConstructor;
57
+ default: boolean;
58
+ };
59
+ }>>, {
60
+ title: string;
61
+ dot: boolean;
62
+ defaultFold: boolean;
63
+ collapseCount: number;
64
+ processes: import("./Timeline").TimelineProcessOption[];
65
+ opinionKey: string;
66
+ enableSingleFold: boolean;
67
+ }>>;
68
+ export default Timeline;
69
+ export { timelineProps } from './Timeline';
70
+ export type { TimelineProcessOption, TimelineProps } from './Timeline';
71
+ declare module 'vue' {
72
+ interface GlobalComponents {
73
+ ZtTimeline: typeof Timeline;
74
+ }
75
+ }
@@ -0,0 +1,10 @@
1
+ import { withInstall } from "../utils/index.mjs";
2
+ import _Timeline from "./Timeline.mjs";
3
+ const Timeline = withInstall(_Timeline);
4
+ var stdin_default = Timeline;
5
+ import { timelineProps } from "./Timeline.mjs";
6
+ export {
7
+ Timeline,
8
+ stdin_default as default,
9
+ timelineProps
10
+ };
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,4 @@
1
+ import "../../style/base.css";
2
+ import "../../loading/index.css";
3
+ import "../../switch/index.css";
4
+ import "../index.css";
@@ -195,8 +195,8 @@ declare const _default: import("vue").DefineComponent<{
195
195
  onClickPreview?: ((...args: any[]) => any) | undefined;
196
196
  }, {
197
197
  name: string | number;
198
- accept: string;
199
198
  disabled: boolean;
199
+ accept: string;
200
200
  modelValue: UploaderFileListItem[];
201
201
  readonly: boolean;
202
202
  multiple: boolean;
@@ -14,7 +14,7 @@ declare const _default: import("vue").DefineComponent<{
14
14
  deletable: BooleanConstructor;
15
15
  previewSize: PropType<Numeric | [Numeric, Numeric]>;
16
16
  beforeDelete: PropType<Interceptor>;
17
- }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("delete" | "preview")[], "preview" | "delete", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
17
+ }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("preview" | "delete")[], "preview" | "delete", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
18
18
  name: (NumberConstructor | StringConstructor)[];
19
19
  item: {
20
20
  type: PropType<UploaderFileListItem>;
@@ -128,8 +128,8 @@ export declare const Uploader: import("../utils").WithInstall<import("vue").Defi
128
128
  onClickPreview?: ((...args: any[]) => any) | undefined;
129
129
  }, {
130
130
  name: string | number;
131
- accept: string;
132
131
  disabled: boolean;
132
+ accept: string;
133
133
  modelValue: import("./types").UploaderFileListItem[];
134
134
  readonly: boolean;
135
135
  multiple: boolean;
@@ -40,7 +40,7 @@ function filterFiles(items, maxSize) {
40
40
  });
41
41
  return { valid, invalid };
42
42
  }
43
- const IMAGE_REGEXP = /\.(jpeg|jpg|gif|png|svg|webp|jfif|bmp|dpg)/i;
43
+ const IMAGE_REGEXP = /\.(jpeg|jpg|gif|png|svg|webp|jfif|bmp|dpg|avif)/i;
44
44
  const isImageUrl = (url) => IMAGE_REGEXP.test(url);
45
45
  function isImageFile(item) {
46
46
  if (item.isImage) {
package/es/utils/dom.d.ts CHANGED
@@ -9,4 +9,5 @@ export declare function resetScroll(): void;
9
9
  export declare const stopPropagation: (event: Event) => void;
10
10
  export declare function preventDefault(event: Event, isStopPropagation?: boolean): void;
11
11
  export declare function isHidden(elementRef: HTMLElement | Ref<HTMLElement | undefined>): boolean;
12
+ export declare function colorFromCSSClass(className: string, defaultColor: string): string;
12
13
  export declare const windowWidth: Ref<number>, windowHeight: Ref<number>;
package/es/utils/dom.mjs CHANGED
@@ -51,8 +51,19 @@ function isHidden(elementRef) {
51
51
  const parentHidden = el.offsetParent === null && style.position !== "fixed";
52
52
  return hidden || parentHidden;
53
53
  }
54
+ function colorFromCSSClass(className, defaultColor) {
55
+ var _a;
56
+ const tmp = document.createElement("div");
57
+ tmp.style.cssText = "position:fixed;left:-100px;top:-100px;width:1px;height:1px";
58
+ tmp.className = className;
59
+ document.body.appendChild(tmp);
60
+ const classColor = (_a = getComputedStyle(tmp)) == null ? void 0 : _a.getPropertyValue("color");
61
+ document.body.removeChild(tmp);
62
+ return !classColor ? defaultColor : classColor;
63
+ }
54
64
  const { width: windowWidth, height: windowHeight } = useWindowSize();
55
65
  export {
66
+ colorFromCSSClass,
56
67
  getElementTop,
57
68
  getRootScrollTop,
58
69
  getScrollTop,
@@ -17,6 +17,10 @@ var __copyProps = (to, from, except, desc) => {
17
17
  return to;
18
18
  };
19
19
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
20
24
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
21
25
  mod
22
26
  ));
@@ -17,6 +17,10 @@ var __copyProps = (to, from, except, desc) => {
17
17
  return to;
18
18
  };
19
19
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
20
24
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
21
25
  mod
22
26
  ));
@@ -17,6 +17,10 @@ var __copyProps = (to, from, except, desc) => {
17
17
  return to;
18
18
  };
19
19
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
20
24
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
21
25
  mod
22
26
  ));
@@ -17,6 +17,10 @@ var __copyProps = (to, from, except, desc) => {
17
17
  return to;
18
18
  };
19
19
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
20
24
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
21
25
  mod
22
26
  ));
@@ -12,6 +12,7 @@ declare const buttonProps: {
12
12
  };
13
13
  text: StringConstructor;
14
14
  icon: StringConstructor;
15
+ iconColor: StringConstructor;
15
16
  type: {
16
17
  type: PropType<ButtonType>;
17
18
  default: ButtonType;
@@ -57,6 +58,7 @@ declare const _default: import("vue").DefineComponent<{
57
58
  };
58
59
  text: StringConstructor;
59
60
  icon: StringConstructor;
61
+ iconColor: StringConstructor;
60
62
  type: {
61
63
  type: PropType<ButtonType>;
62
64
  default: ButtonType;
@@ -100,6 +102,7 @@ declare const _default: import("vue").DefineComponent<{
100
102
  };
101
103
  text: StringConstructor;
102
104
  icon: StringConstructor;
105
+ iconColor: StringConstructor;
103
106
  type: {
104
107
  type: PropType<ButtonType>;
105
108
  default: ButtonType;
@@ -31,6 +31,7 @@ const buttonProps = (0, import_utils.extend)({}, import_use_route.routeProps, {
31
31
  tag: (0, import_utils.makeStringProp)("button"),
32
32
  text: String,
33
33
  icon: String,
34
+ iconColor: String,
34
35
  type: (0, import_utils.makeStringProp)("default"),
35
36
  size: (0, import_utils.makeStringProp)("normal"),
36
37
  color: String,
@@ -86,6 +87,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
86
87
  if (props.icon) {
87
88
  return (0, import_vue.createVNode)(import_icon.Icon, {
88
89
  "name": props.icon,
90
+ "color": props.iconColor,
89
91
  "class": bem("icon", size),
90
92
  "classPrefix": props.iconPrefix
91
93
  }, null);
@@ -9,6 +9,7 @@ export declare const Button: import("../utils").WithInstall<import("vue").Define
9
9
  };
10
10
  text: StringConstructor;
11
11
  icon: StringConstructor;
12
+ iconColor: StringConstructor;
12
13
  type: {
13
14
  type: import("vue").PropType<import("./types").ButtonType>;
14
15
  default: import("./types").ButtonType;
@@ -52,6 +53,7 @@ export declare const Button: import("../utils").WithInstall<import("vue").Define
52
53
  };
53
54
  text: StringConstructor;
54
55
  icon: StringConstructor;
56
+ iconColor: StringConstructor;
55
57
  type: {
56
58
  type: import("vue").PropType<import("./types").ButtonType>;
57
59
  default: import("./types").ButtonType;
@@ -17,6 +17,10 @@ var __copyProps = (to, from, except, desc) => {
17
17
  return to;
18
18
  };
19
19
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
20
24
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
21
25
  mod
22
26
  ));
@@ -1,8 +1,12 @@
1
1
  import type { PropType, ExtractPropTypes } from 'vue';
2
2
  import { PopupPosition } from '../popup';
3
- import type { CalendarType, CalendarDayItem } from './types';
3
+ import type { CalendarType, CalendarDayItem, CalendarShowType } from './types';
4
4
  export declare const calendarProps: {
5
5
  show: BooleanConstructor;
6
+ showType: {
7
+ type: PropType<CalendarShowType>;
8
+ default: CalendarShowType;
9
+ };
6
10
  type: {
7
11
  type: PropType<CalendarType>;
8
12
  default: CalendarType;
@@ -74,25 +78,22 @@ export declare const calendarProps: {
74
78
  type: BooleanConstructor;
75
79
  default: true;
76
80
  };
77
- minDate: {
78
- type: DateConstructor;
79
- validator: (val: unknown) => val is Date;
80
- default: () => Date;
81
- };
82
- maxDate: {
83
- type: DateConstructor;
84
- validator: (val: unknown) => val is Date;
85
- default: () => Date;
86
- };
81
+ minDate: DateConstructor;
82
+ maxDate: DateConstructor;
87
83
  firstDayOfWeek: {
88
84
  type: (NumberConstructor | StringConstructor)[];
89
85
  default: number;
90
86
  validator: (val: number) => boolean;
91
87
  };
88
+ disabledDate: PropType<(date: Date) => boolean>;
92
89
  };
93
90
  export declare type CalendarProps = ExtractPropTypes<typeof calendarProps>;
94
91
  declare const _default: import("vue").DefineComponent<{
95
92
  show: BooleanConstructor;
93
+ showType: {
94
+ type: PropType<CalendarShowType>;
95
+ default: CalendarShowType;
96
+ };
96
97
  type: {
97
98
  type: PropType<CalendarType>;
98
99
  default: CalendarType;
@@ -164,23 +165,20 @@ declare const _default: import("vue").DefineComponent<{
164
165
  type: BooleanConstructor;
165
166
  default: true;
166
167
  };
167
- minDate: {
168
- type: DateConstructor;
169
- validator: (val: unknown) => val is Date;
170
- default: () => Date;
171
- };
172
- maxDate: {
173
- type: DateConstructor;
174
- validator: (val: unknown) => val is Date;
175
- default: () => Date;
176
- };
168
+ minDate: DateConstructor;
169
+ maxDate: DateConstructor;
177
170
  firstDayOfWeek: {
178
171
  type: (NumberConstructor | StringConstructor)[];
179
172
  default: number;
180
173
  validator: (val: number) => boolean;
181
174
  };
175
+ disabledDate: PropType<(date: Date) => boolean>;
182
176
  }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("select" | "update:show" | "cancel" | "clickSubtitle" | "confirm" | "unselect" | "monthShow" | "overRange")[], "select" | "update:show" | "cancel" | "clickSubtitle" | "confirm" | "unselect" | "monthShow" | "overRange", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<ExtractPropTypes<{
183
177
  show: BooleanConstructor;
178
+ showType: {
179
+ type: PropType<CalendarShowType>;
180
+ default: CalendarShowType;
181
+ };
184
182
  type: {
185
183
  type: PropType<CalendarType>;
186
184
  default: CalendarType;
@@ -252,21 +250,14 @@ declare const _default: import("vue").DefineComponent<{
252
250
  type: BooleanConstructor;
253
251
  default: true;
254
252
  };
255
- minDate: {
256
- type: DateConstructor;
257
- validator: (val: unknown) => val is Date;
258
- default: () => Date;
259
- };
260
- maxDate: {
261
- type: DateConstructor;
262
- validator: (val: unknown) => val is Date;
263
- default: () => Date;
264
- };
253
+ minDate: DateConstructor;
254
+ maxDate: DateConstructor;
265
255
  firstDayOfWeek: {
266
256
  type: (NumberConstructor | StringConstructor)[];
267
257
  default: number;
268
258
  validator: (val: number) => boolean;
269
259
  };
260
+ disabledDate: PropType<(date: Date) => boolean>;
270
261
  }>> & {
271
262
  onSelect?: ((...args: any[]) => any) | undefined;
272
263
  "onUpdate:show"?: ((...args: any[]) => any) | undefined;
@@ -288,6 +279,7 @@ declare const _default: import("vue").DefineComponent<{
288
279
  safeAreaInsetTop: boolean;
289
280
  safeAreaInsetBottom: boolean;
290
281
  popup: boolean;
282
+ showType: CalendarShowType;
291
283
  maxRange: string | number;
292
284
  showMark: boolean;
293
285
  showTitle: boolean;
@@ -295,8 +287,6 @@ declare const _default: import("vue").DefineComponent<{
295
287
  allowSameDay: boolean;
296
288
  showSubtitle: boolean;
297
289
  showRangePrompt: boolean;
298
- minDate: Date;
299
- maxDate: Date;
300
290
  firstDayOfWeek: string | number;
301
291
  }>;
302
292
  export default _default;
@@ -17,6 +17,10 @@ var __copyProps = (to, from, except, desc) => {
17
17
  return to;
18
18
  };
19
19
  var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
20
+ // If the importer is in node compatibility mode or this is not an ESM
21
+ // file that has been converted to a CommonJS file using a Babel-
22
+ // compatible transform (i.e. "__esModule" has not been set), then set
23
+ // "default" to the CommonJS "module.exports" for node compatibility.
20
24
  isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
21
25
  mod
22
26
  ));
@@ -41,6 +45,7 @@ var import_CalendarMonth = __toESM(require("./CalendarMonth"));
41
45
  var import_CalendarHeader = __toESM(require("./CalendarHeader"));
42
46
  const calendarProps = {
43
47
  show: Boolean,
48
+ showType: (0, import_utils.makeStringProp)("inline"),
44
49
  type: (0, import_utils.makeStringProp)("single"),
45
50
  title: String,
46
51
  color: String,
@@ -67,24 +72,14 @@ const calendarProps = {
67
72
  closeOnClickOverlay: import_utils.truthProp,
68
73
  safeAreaInsetTop: Boolean,
69
74
  safeAreaInsetBottom: import_utils.truthProp,
70
- minDate: {
71
- type: Date,
72
- validator: import_utils.isDate,
73
- default: import_utils2.getToday
74
- },
75
- maxDate: {
76
- type: Date,
77
- validator: import_utils.isDate,
78
- default: () => {
79
- const now = (0, import_utils2.getToday)();
80
- return new Date(now.getFullYear(), now.getMonth() + 6, now.getDate());
81
- }
82
- },
75
+ minDate: Date,
76
+ maxDate: Date,
83
77
  firstDayOfWeek: {
84
78
  type: import_utils.numericProp,
85
- default: 0,
79
+ default: 1,
86
80
  validator: (val) => val >= 0 && val <= 6
87
- }
81
+ },
82
+ disabledDate: Function
88
83
  };
89
84
  var stdin_default = (0, import_vue2.defineComponent)({
90
85
  name: import_utils2.name,
@@ -94,11 +89,19 @@ var stdin_default = (0, import_vue2.defineComponent)({
94
89
  emit,
95
90
  slots
96
91
  }) {
97
- const limitDateRange = (date, minDate = props.minDate, maxDate = props.maxDate) => {
98
- if ((0, import_utils2.compareDay)(date, minDate) === -1) {
92
+ const lastMinDate = (0, import_vue2.computed)(() => {
93
+ const now = new Date();
94
+ return props.showType !== "inline" && !props.minDate ? new Date(now.getFullYear(), now.getMonth() - 3, now.getDate()) : props.minDate;
95
+ });
96
+ const lastMaxDate = (0, import_vue2.computed)(() => {
97
+ const now = new Date();
98
+ return props.showType !== "inline" && !props.maxDate ? new Date(now.getFullYear(), now.getMonth() + 6, now.getDate()) : props.maxDate;
99
+ });
100
+ const limitDateRange = (date, minDate = lastMinDate.value, maxDate = lastMaxDate.value) => {
101
+ if (minDate && (0, import_utils2.compareDay)(date, minDate) === -1) {
99
102
  return minDate;
100
103
  }
101
- if ((0, import_utils2.compareDay)(date, maxDate) === 1) {
104
+ if (maxDate && (0, import_utils2.compareDay)(date, maxDate) === 1) {
102
105
  return maxDate;
103
106
  }
104
107
  return date;
@@ -106,10 +109,10 @@ var stdin_default = (0, import_vue2.defineComponent)({
106
109
  const getInitialDate = (defaultDate = props.defaultDate) => {
107
110
  const {
108
111
  type,
109
- minDate,
110
- maxDate,
111
112
  allowSameDay
112
113
  } = props;
114
+ const minDate = lastMinDate.value;
115
+ const maxDate = lastMaxDate.value;
113
116
  if (defaultDate === null) {
114
117
  return defaultDate;
115
118
  }
@@ -118,8 +121,8 @@ var stdin_default = (0, import_vue2.defineComponent)({
118
121
  if (!Array.isArray(defaultDate)) {
119
122
  defaultDate = [];
120
123
  }
121
- const start = limitDateRange(defaultDate[0] || now, minDate, allowSameDay ? maxDate : (0, import_utils2.getPrevDay)(maxDate));
122
- const end = limitDateRange(defaultDate[1] || now, allowSameDay ? minDate : (0, import_utils2.getNextDay)(minDate));
124
+ const start = limitDateRange(defaultDate[0] || now, minDate, allowSameDay ? maxDate : maxDate && (0, import_utils2.getPrevDay)(maxDate));
125
+ const end = limitDateRange(defaultDate[1] || now, allowSameDay ? minDate : minDate && (0, import_utils2.getNextDay)(minDate));
123
126
  return [start, end];
124
127
  }
125
128
  if (type === "multiple") {
@@ -133,20 +136,40 @@ var stdin_default = (0, import_vue2.defineComponent)({
133
136
  }
134
137
  return limitDateRange(defaultDate);
135
138
  };
139
+ const getInitialTitleDate = (defaultDate = props.defaultDate) => {
140
+ const initTitleDate = getInitialDate(defaultDate);
141
+ const now = (0, import_utils2.getToday)();
142
+ if (Array.isArray(initTitleDate)) {
143
+ return initTitleDate[0] || now;
144
+ } else {
145
+ return initTitleDate || now;
146
+ }
147
+ };
136
148
  let bodyHeight;
137
149
  const bodyRef = (0, import_vue2.ref)();
138
150
  const subtitle = (0, import_vue2.ref)("");
139
151
  const currentDate = (0, import_vue2.ref)(getInitialDate());
152
+ const titleDate = (0, import_vue2.ref)(getInitialTitleDate());
140
153
  const [monthRefs, setMonthRefs] = (0, import_use_refs.useRefs)();
141
154
  const dayOffset = (0, import_vue2.computed)(() => props.firstDayOfWeek ? +props.firstDayOfWeek % 7 : 0);
142
155
  const months = (0, import_vue2.computed)(() => {
156
+ var _a;
143
157
  const months2 = [];
144
- const cursor = new Date(props.minDate);
145
- cursor.setDate(1);
146
- do {
147
- months2.push(new Date(cursor));
148
- cursor.setMonth(cursor.getMonth() + 1);
149
- } while ((0, import_utils2.compareMonth)(cursor, props.maxDate) !== 1);
158
+ if (props.showType !== "inline" && lastMinDate.value && lastMaxDate.value) {
159
+ const cursor = new Date(lastMinDate.value);
160
+ cursor.setDate(1);
161
+ do {
162
+ months2.push(new Date(cursor));
163
+ cursor.setMonth(cursor.getMonth() + 1);
164
+ } while ((0, import_utils2.compareMonth)(cursor, lastMaxDate.value) !== 1);
165
+ } else if (props.showType === "inline") {
166
+ const temp = (_a = titleDate.value) != null ? _a : (0, import_utils2.cloneDates)(titleDate.value);
167
+ if (!Array.isArray(temp)) {
168
+ months2.push((0, import_utils2.getFirstDate)(temp));
169
+ } else {
170
+ months2.push((0, import_utils2.getFirstDate)(temp[0]));
171
+ }
172
+ }
150
173
  return months2;
151
174
  });
152
175
  const buttonDisabled = (0, import_vue2.computed)(() => {
@@ -197,6 +220,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
197
220
  });
198
221
  if (currentMonth) {
199
222
  subtitle.value = currentMonth.getTitle();
223
+ titleDate.value = currentMonth.getDate();
200
224
  }
201
225
  };
202
226
  const scrollToDate = (targetDate) => {
@@ -237,6 +261,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
237
261
  };
238
262
  const reset = (date = getInitialDate()) => {
239
263
  currentDate.value = date;
264
+ titleDate.value = getInitialTitleDate(date);
240
265
  scrollToCurrentDate();
241
266
  };
242
267
  const checkRange = (date) => {
@@ -298,6 +323,9 @@ var stdin_default = (0, import_vue2.defineComponent)({
298
323
  const {
299
324
  type
300
325
  } = props;
326
+ if (item.type === "preview") {
327
+ titleDate.value = date;
328
+ }
301
329
  if (type === "range") {
302
330
  if (!currentDate.value) {
303
331
  select([date]);
@@ -345,6 +373,64 @@ var stdin_default = (0, import_vue2.defineComponent)({
345
373
  select(date, true);
346
374
  }
347
375
  };
376
+ const yearPreEnable = (0, import_vue2.computed)(() => {
377
+ if (!lastMinDate.value) {
378
+ return true;
379
+ }
380
+ return titleDate.value.getFullYear() > lastMinDate.value.getFullYear();
381
+ });
382
+ const monthPreEnable = (0, import_vue2.computed)(() => {
383
+ if (!lastMinDate.value) {
384
+ return true;
385
+ }
386
+ const targetDate = titleDate.value;
387
+ const targetYearMonth = (0, import_utils2.getFirstDate)(targetDate);
388
+ const minDateYearMonth = (0, import_utils2.getFirstDate)(lastMinDate.value);
389
+ return (0, import_utils2.compareDay)(targetYearMonth, minDateYearMonth) === 1;
390
+ });
391
+ const yearNextEnable = (0, import_vue2.computed)(() => {
392
+ if (!lastMaxDate.value) {
393
+ return true;
394
+ }
395
+ return titleDate.value.getFullYear() < lastMaxDate.value.getFullYear();
396
+ });
397
+ const monthNextEnable = (0, import_vue2.computed)(() => {
398
+ if (!lastMaxDate.value) {
399
+ return true;
400
+ }
401
+ const targetDate = titleDate.value;
402
+ const targetYearMonth = (0, import_utils2.getFirstDate)(targetDate);
403
+ const maxDateYearMonth = (0, import_utils2.getFirstDate)(lastMaxDate.value);
404
+ return (0, import_utils2.compareDay)(maxDateYearMonth, targetYearMonth) === 1;
405
+ });
406
+ const onClickTitleIcon = (isPreFlag, isMonth, isYear) => {
407
+ const curTitleDate = titleDate.value;
408
+ if (curTitleDate) {
409
+ let targetDate = isPreFlag ? (0, import_utils2.getPrevDate)(curTitleDate, isMonth, isYear) : (0, import_utils2.getNextDate)(curTitleDate, isMonth, isYear);
410
+ if (!(0, import_utils.isDate)(targetDate)) {
411
+ return;
412
+ }
413
+ let hasCompared = false;
414
+ const compareDate = isPreFlag ? lastMinDate.value : lastMaxDate.value;
415
+ const compareValue = isPreFlag ? 1 : -1;
416
+ if (compareDate && (0, import_utils2.compareDay)(compareDate, targetDate) === compareValue && (0, import_utils2.compareMonth)(compareDate, targetDate) === 0) {
417
+ targetDate = compareDate;
418
+ hasCompared = true;
419
+ }
420
+ if (hasCompared || !compareDate || compareDate && (0, import_utils2.compareDay)(compareDate, targetDate) !== compareValue) {
421
+ scrollToDate(targetDate);
422
+ titleDate.value = targetDate;
423
+ }
424
+ } else {
425
+ (0, import_use.raf)(onScroll);
426
+ }
427
+ };
428
+ const onClickPreIcon = (isMonth, isYear) => {
429
+ onClickTitleIcon(true, isMonth, isYear);
430
+ };
431
+ const onClickNextIcon = (isMonth, isYear) => {
432
+ onClickTitleIcon(false, isMonth, isYear);
433
+ };
348
434
  const updateShow = (value) => emit("update:show", value);
349
435
  const renderMonth = (date, index) => {
350
436
  const showMonthTitle = index !== 0 || !props.showSubtitle;
@@ -354,7 +440,7 @@ var stdin_default = (0, import_vue2.defineComponent)({
354
440
  "currentDate": currentDate.value,
355
441
  "showMonthTitle": showMonthTitle,
356
442
  "firstDayOfWeek": dayOffset.value
357
- }, (0, import_utils.pick)(props, ["type", "color", "minDate", "maxDate", "showMark", "formatter", "rowHeight", "lazyRender", "showSubtitle", "allowSameDay"]), {
443
+ }, (0, import_utils.pick)(props, ["showType", "type", "color", "minDate", "maxDate", "showMark", "formatter", "rowHeight", "lazyRender", "showSubtitle", "allowSameDay", "disabledDate"]), {
358
444
  "onClick": onClickDay
359
445
  }), (0, import_utils.pick)(slots, ["top-info", "bottom-info"]));
360
446
  };
@@ -404,7 +490,13 @@ var stdin_default = (0, import_vue2.defineComponent)({
404
490
  "showTitle": props.showTitle,
405
491
  "showSubtitle": props.showSubtitle,
406
492
  "firstDayOfWeek": dayOffset.value,
407
- "onClickSubtitle": (event) => emit("clickSubtitle", event)
493
+ "onClickSubtitle": (event) => emit("clickSubtitle", event),
494
+ "onClickPreIcon": onClickPreIcon,
495
+ "onClickNextIcon": onClickNextIcon,
496
+ "yearPreEnable": yearPreEnable.value,
497
+ "monthPreEnable": monthPreEnable.value,
498
+ "yearNextEnable": yearNextEnable.value,
499
+ "monthNextEnable": monthNextEnable.value
408
500
  }, (0, import_utils.pick)(slots, ["title", "subtitle"])), (0, import_vue.createVNode)("div", {
409
501
  "ref": bodyRef,
410
502
  "class": (0, import_utils2.bem)("body"),
@@ -416,6 +508,11 @@ var stdin_default = (0, import_vue2.defineComponent)({
416
508
  currentDate.value = value;
417
509
  scrollToCurrentDate();
418
510
  });
511
+ (0, import_vue2.watch)(titleDate, (newValue) => {
512
+ if (props.showType === "inline" && newValue) {
513
+ subtitle.value = (0, import_utils2.formatMonthTitle)(newValue);
514
+ }
515
+ });
419
516
  (0, import_use_expose.useExpose)({
420
517
  reset,
421
518
  scrollToDate,