@opentiny/vue-renderless 3.11.8 → 3.12.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (339) hide show
  1. package/anchor/index.js +13 -6
  2. package/anchor/vue.js +1 -1
  3. package/breadcrumb/index.js +6 -1
  4. package/breadcrumb-item/index.js +8 -1
  5. package/calendar-bar/index.js +295 -68
  6. package/calendar-bar/vue.js +82 -8
  7. package/calendar-view/index.js +2 -2
  8. package/card/index.js +4 -4
  9. package/card/vue.js +2 -3
  10. package/card-group/vue.js +3 -7
  11. package/carousel/index.js +26 -27
  12. package/carousel/vue.js +41 -46
  13. package/carousel-item/index.js +9 -6
  14. package/carousel-item/vue.js +4 -4
  15. package/cascader-mobile/index.js +5 -1
  16. package/cascader-mobile/vue.js +2 -1
  17. package/cascader-panel/index.js +6 -2
  18. package/cascader-view/index.js +363 -0
  19. package/cascader-view/vue.js +130 -0
  20. package/chart-core/deps/constants.js +27 -0
  21. package/chart-core/deps/numerify.js +27 -28
  22. package/chart-core/index.js +122 -31
  23. package/chart-core/vue.js +12 -8
  24. package/chart-radar/index.js +2 -2
  25. package/checkbox-button/vue.js +8 -1
  26. package/checkbox-group/vue.js +4 -5
  27. package/col/index.js +3 -2
  28. package/col/vue.js +1 -1
  29. package/collapse-item/index.js +14 -2
  30. package/color-picker/index.js +24 -34
  31. package/color-picker/utils/color.js +7 -1
  32. package/color-picker/vue.js +39 -26
  33. package/color-select-panel/alpha-select/vue.js +5 -8
  34. package/color-select-panel/hue-select/index.js +4 -2
  35. package/color-select-panel/hue-select/vue.js +11 -10
  36. package/color-select-panel/index.js +29 -17
  37. package/color-select-panel/utils/color.js +5 -0
  38. package/color-select-panel/vue.js +16 -7
  39. package/column-list-item/index.js +19 -5
  40. package/column-list-item/vue.js +16 -14
  41. package/common/bigInt.js +1 -1
  42. package/common/deps/dom.js +37 -5
  43. package/common/deps/repeat-click.js +3 -2
  44. package/common/deps/touch-emulator.js +95 -0
  45. package/common/deps/touch.js +12 -11
  46. package/common/deps/useEventListener.js +47 -0
  47. package/common/deps/useTouch.js +68 -0
  48. package/common/deps/vue-popper.js +2 -3
  49. package/common/index.js +1 -1
  50. package/common/runtime.js +1 -1
  51. package/common/string.js +20 -9
  52. package/date-picker/index.js +24 -4
  53. package/date-picker-mobile/index.js +5 -1
  54. package/file-upload/index.js +148 -50
  55. package/file-upload/vue.js +24 -6
  56. package/filter/index.js +2 -1
  57. package/filter/vue.js +1 -1
  58. package/form-item/index.js +24 -21
  59. package/form-item/vue.js +14 -12
  60. package/grid/plugins/export.js +0 -8
  61. package/grid/utils/common.js +13 -16
  62. package/image-viewer/index.js +1 -1
  63. package/ip-address/index.js +6 -3
  64. package/menu/index.js +127 -0
  65. package/menu/vue.js +90 -0
  66. package/menu-node/index.js +12 -0
  67. package/menu-node/vue.js +42 -0
  68. package/modal/index.js +6 -0
  69. package/modal/vue.js +3 -1
  70. package/numeric/index.js +18 -2
  71. package/numeric/vue.js +11 -7
  72. package/package.json +1 -1
  73. package/popconfirm/index.js +15 -6
  74. package/popconfirm/vue.js +5 -4
  75. package/pull-refresh-mobile-first/index.js +243 -0
  76. package/pull-refresh-mobile-first/vue.js +116 -0
  77. package/qr-code/index.js +54 -0
  78. package/qr-code/vue.js +31 -0
  79. package/radio/index.js +9 -7
  80. package/radio/vue.js +4 -4
  81. package/radio-button/index.js +2 -2
  82. package/radio-button/vue.js +2 -2
  83. package/radio-group/vue.js +1 -0
  84. package/rich-text-edtior/index.js +18 -38
  85. package/rich-text-edtior/vue.js +52 -63
  86. package/select/index.js +11 -7
  87. package/slide-bar/index.js +6 -6
  88. package/slide-bar/vue.js +5 -5
  89. package/slider/index.js +47 -14
  90. package/slider/vue.js +25 -6
  91. package/slider-button/index.js +5 -1
  92. package/slider-button/vue.js +1 -0
  93. package/slider-button-group/index.js +15 -0
  94. package/slider-button-group/vue.js +8 -11
  95. package/standard-list-item/index.js +9 -3
  96. package/standard-list-item/vue.js +3 -2
  97. package/switch/index.js +11 -9
  98. package/switch/vue.js +1 -1
  99. package/tab-bar/index.js +1 -1
  100. package/tab-bar/vue.js +2 -1
  101. package/tab-nav/index.js +31 -31
  102. package/tab-nav/vue.js +13 -12
  103. package/tabs/vue.js +3 -1
  104. package/tabs-mf/index.js +14 -9
  105. package/tabs-mf/vue-bar.js +3 -2
  106. package/tabs-mf/vue-nav-item.js +2 -1
  107. package/tabs-mf/vue-nav.js +18 -2
  108. package/tabs-mf/vue.js +3 -1
  109. package/tag/index.js +1 -1
  110. package/toast/index.js +7 -0
  111. package/toast/vue.js +19 -0
  112. package/transfer/index.js +2 -2
  113. package/transfer/vue.js +1 -1
  114. package/tree-node/index.js +1 -1
  115. package/types/{action-menu.type.d.mts → action-menu.type.d.ts} +3 -3
  116. package/types/{alert.type.d.mts → alert.type.d.ts} +2 -1
  117. package/types/{anchor.type.d.mts → anchor.type.d.ts} +3 -3
  118. package/types/{badge.type.d.mts → badge.type.d.ts} +1 -1
  119. package/types/{breadcrumb-item.type.d.mts → breadcrumb-item.type.d.ts} +1 -1
  120. package/types/{breadcrumb.type.d.mts → breadcrumb.type.d.ts} +1 -1
  121. package/types/{button-group.type.d.mts → button-group.type.d.ts} +1 -1
  122. package/types/{button.type.d.mts → button.type.d.ts} +1 -1
  123. package/types/{cascader-menu.type.d.mts → cascader-menu.type.d.ts} +4 -4
  124. package/types/{cascader-node.type.d.mts → cascader-node.type.d.ts} +4 -4
  125. package/types/{cascader-panel.type.d.mts → cascader-panel.type.d.ts} +6 -6
  126. package/types/{checkbox.type.d.mts → checkbox.type.d.ts} +2 -1
  127. package/types/{collapse-item.type.d.mts → collapse-item.type.d.ts} +1 -1
  128. package/types/{collapse.type.d.mts → collapse.type.d.ts} +1 -1
  129. package/types/{color-picker.type.d.mts → color-picker.type.d.ts} +2 -2
  130. package/types/{color-select-panel.type.d.mts → color-select-panel.type.d.ts} +2 -2
  131. package/types/{date-picker.type.d.mts → date-picker.type.d.ts} +6 -2
  132. package/types/{dialog-box.type.d.mts → dialog-box.type.d.ts} +9 -9
  133. package/types/{dropdown-item.type-77f0c8c5.d.ts → dropdown-item.type-bf83e929.d.ts} +4 -4
  134. package/types/{dropdown-item.type.d.mts → dropdown-item.type.d.ts} +3 -3
  135. package/types/{dropdown-menu.type.d.mts → dropdown-menu.type.d.ts} +3 -3
  136. package/types/{dropdown.type.d.mts → dropdown.type.d.ts} +1 -1
  137. package/types/{file-upload.type.d.mts → file-upload.type.d.ts} +2 -2
  138. package/types/{floatbar.type.d.mts → floatbar.type.d.ts} +7 -7
  139. package/types/{form-item.type.d.mts → form-item.type.d.ts} +2 -2
  140. package/types/{form.type-1e2e9272.d.ts → form.type-d0fd42f3.d.ts} +20 -7
  141. package/types/{form.type.d.mts → form.type.d.ts} +2 -2
  142. package/types/{image.type.d.mts → image.type.d.ts} +1 -1
  143. package/types/{input.type.d.mts → input.type.d.ts} +10 -2
  144. package/types/{link.type.d.mts → link.type.d.ts} +1 -1
  145. package/types/{loading.type.d.mts → loading.type.d.ts} +1 -1
  146. package/types/{milestone.type.d.mts → milestone.type.d.ts} +1 -1
  147. package/types/{modal.type.d.mts → modal.type.d.ts} +18 -19
  148. package/types/{nav-menu.type.d.mts → nav-menu.type.d.ts} +1 -1
  149. package/types/{numeric.type.d.mts → numeric.type.d.ts} +9 -3
  150. package/types/{picker.type.d.mts → picker.type.d.ts} +5 -1
  151. package/types/{popeditor.type.d.mts → popeditor.type.d.ts} +1 -1
  152. package/types/{popover.type.d.mts → popover.type.d.ts} +1 -1
  153. package/types/{progress.type.d.mts → progress.type.d.ts} +1 -1
  154. package/types/{radio-button.type.d.mts → radio-button.type.d.ts} +3 -3
  155. package/types/{radio-group.type.d.mts → radio-group.type.d.ts} +5 -1
  156. package/types/{radio.type.d.mts → radio.type.d.ts} +2 -2
  157. package/types/{search.type.d.mts → search.type.d.ts} +1 -1
  158. package/types/{shared.type.d.mts → shared.type.d.ts} +7 -7
  159. package/types/{slider.type.d.mts → slider.type.d.ts} +1 -1
  160. package/types/{steps.type.d.mts → steps.type.d.ts} +6 -1
  161. package/types/{switch.type.d.mts → switch.type.d.ts} +5 -1
  162. package/types/{tab-bar.type.d.mts → tab-bar.type.d.ts} +3 -2
  163. package/types/{tab-item.type.d.mts → tab-item.type.d.ts} +2 -2
  164. package/types/{tab-nav.type.d.mts → tab-nav.type.d.ts} +13 -12
  165. package/types/{tabs.type.d.mts → tabs.type.d.ts} +6 -4
  166. package/types/{tag.type.d.mts → tag.type.d.ts} +1 -1
  167. package/types/{time-line.type-5f76ecc2.d.ts → time-line.type-d7daa669.d.ts} +1 -1
  168. package/types/{time-line.type.d.mts → time-line.type.d.ts} +2 -2
  169. package/types/{timeline-item.type.d.mts → timeline-item.type.d.ts} +2 -2
  170. package/types/toast.type.d.ts +63 -0
  171. package/types/{tooltip.type.d.mts → tooltip.type.d.ts} +2 -9
  172. package/types/{upload-dragger.type.d.mts → upload-dragger.type.d.ts} +2 -2
  173. package/types/{upload-list.type-b934f279.d.ts → upload-list.type-343e8c11.d.ts} +45 -7
  174. package/types/{upload-list.type.d.mts → upload-list.type.d.ts} +2 -2
  175. package/types/{upload.type.d.mts → upload.type.d.ts} +2 -2
  176. package/types/watermark.type.d.ts +33 -0
  177. package/types/{wizard.type.d.mts → wizard.type.d.ts} +1 -1
  178. package/upload/index.js +1 -1
  179. package/upload-list/index.js +3 -2
  180. package/upload-list/vue.js +12 -2
  181. package/watermark/index.js +202 -0
  182. package/watermark/vue.js +27 -0
  183. package/wizard/index.js +5 -5
  184. package/card-group/index.js +0 -16
  185. package/color-picker/alpha-select/index.js +0 -20
  186. package/color-picker/alpha-select/vue.js +0 -60
  187. package/color-picker/color-select/index.js +0 -69
  188. package/color-picker/color-select/vue.js +0 -57
  189. package/color-picker/utils/use-drag.js +0 -38
  190. /package/types/{action-sheet.type.d.mts → action-sheet.type.d.ts} +0 -0
  191. /package/types/{amount.type.d.mts → amount.type.d.ts} +0 -0
  192. /package/types/{area.type.d.mts → area.type.d.ts} +0 -0
  193. /package/types/{autocomplete.type.d.mts → autocomplete.type.d.ts} +0 -0
  194. /package/types/{autonavi-map.type.d.mts → autonavi-map.type.d.ts} +0 -0
  195. /package/types/{avatar.type.d.mts → avatar.type.d.ts} +0 -0
  196. /package/types/{baidu-map.type.d.mts → baidu-map.type.d.ts} +0 -0
  197. /package/types/{bulletin-board.type.d.mts → bulletin-board.type.d.ts} +0 -0
  198. /package/types/{calendar-bar.type.d.mts → calendar-bar.type.d.ts} +0 -0
  199. /package/types/{calendar.type.d.mts → calendar.type.d.ts} +0 -0
  200. /package/types/{card-group.type.d.mts → card-group.type.d.ts} +0 -0
  201. /package/types/{card-template.type.d.mts → card-template.type.d.ts} +0 -0
  202. /package/types/{card.type.d.mts → card.type.d.ts} +0 -0
  203. /package/types/{carousel-item.type.d.mts → carousel-item.type.d.ts} +0 -0
  204. /package/types/{carousel.type.d.mts → carousel.type.d.ts} +0 -0
  205. /package/types/{cascader-mobile.type.d.mts → cascader-mobile.type.d.ts} +0 -0
  206. /package/types/{cascader-select.type.d.mts → cascader-select.type.d.ts} +0 -0
  207. /package/types/{cascader.type.d.mts → cascader.type.d.ts} +0 -0
  208. /package/types/{cell.type.d.mts → cell.type.d.ts} +0 -0
  209. /package/types/{chart-bar.type.d.mts → chart-bar.type.d.ts} +0 -0
  210. /package/types/{chart-boxplot.type.d.mts → chart-boxplot.type.d.ts} +0 -0
  211. /package/types/{chart-candle.type.d.mts → chart-candle.type.d.ts} +0 -0
  212. /package/types/{chart-core.type.d.mts → chart-core.type.d.ts} +0 -0
  213. /package/types/{chart-funnel.type.d.mts → chart-funnel.type.d.ts} +0 -0
  214. /package/types/{chart-gauge.type.d.mts → chart-gauge.type.d.ts} +0 -0
  215. /package/types/{chart-graph.type.d.mts → chart-graph.type.d.ts} +0 -0
  216. /package/types/{chart-heatmap.type.d.mts → chart-heatmap.type.d.ts} +0 -0
  217. /package/types/{chart-line.type.d.mts → chart-line.type.d.ts} +0 -0
  218. /package/types/{chart-liquidfill.type.d.mts → chart-liquidfill.type.d.ts} +0 -0
  219. /package/types/{chart-map.type.d.mts → chart-map.type.d.ts} +0 -0
  220. /package/types/{chart-pie.type.d.mts → chart-pie.type.d.ts} +0 -0
  221. /package/types/{chart-radar.type.d.mts → chart-radar.type.d.ts} +0 -0
  222. /package/types/{chart-sankey.type.d.mts → chart-sankey.type.d.ts} +0 -0
  223. /package/types/{chart-scatter.type.d.mts → chart-scatter.type.d.ts} +0 -0
  224. /package/types/{chart-sunburst.type.d.mts → chart-sunburst.type.d.ts} +0 -0
  225. /package/types/{chart-tree.type.d.mts → chart-tree.type.d.ts} +0 -0
  226. /package/types/{chart-waterfall.type.d.mts → chart-waterfall.type.d.ts} +0 -0
  227. /package/types/{chart-wordcloud.type.d.mts → chart-wordcloud.type.d.ts} +0 -0
  228. /package/types/{checkbox-button.type.d.mts → checkbox-button.type.d.ts} +0 -0
  229. /package/types/{checkbox-group.type.d.mts → checkbox-group.type.d.ts} +0 -0
  230. /package/types/{col.type.d.mts → col.type.d.ts} +0 -0
  231. /package/types/{column-list-group.type.d.mts → column-list-group.type.d.ts} +0 -0
  232. /package/types/{column-list-item.type.d.mts → column-list-item.type.d.ts} +0 -0
  233. /package/types/{common.type.d.mts → common.type.d.ts} +0 -0
  234. /package/types/{company.type.d.mts → company.type.d.ts} +0 -0
  235. /package/types/{container.type.d.mts → container.type.d.ts} +0 -0
  236. /package/types/{country.type.d.mts → country.type.d.ts} +0 -0
  237. /package/types/{credit-card-form.type.d.mts → credit-card-form.type.d.ts} +0 -0
  238. /package/types/{credit-card.type.d.mts → credit-card.type.d.ts} +0 -0
  239. /package/types/{crop.type.d.mts → crop.type.d.ts} +0 -0
  240. /package/types/{currency.type.d.mts → currency.type.d.ts} +0 -0
  241. /package/types/{date-panel.type.d.mts → date-panel.type.d.ts} +0 -0
  242. /package/types/{date-picker-mobile.type.d.mts → date-picker-mobile.type.d.ts} +0 -0
  243. /package/types/{date-range.type.d.mts → date-range.type.d.ts} +0 -0
  244. /package/types/{date-table.type.d.mts → date-table.type.d.ts} +0 -0
  245. /package/types/{dept.type.d.mts → dept.type.d.ts} +0 -0
  246. /package/types/{detail-page.type.d.mts → detail-page.type.d.ts} +0 -0
  247. /package/types/{dialog-select.type.d.mts → dialog-select.type.d.ts} +0 -0
  248. /package/types/{drawer.type.d.mts → drawer.type.d.ts} +0 -0
  249. /package/types/{drop-roles.type.d.mts → drop-roles.type.d.ts} +0 -0
  250. /package/types/{drop-times.type.d.mts → drop-times.type.d.ts} +0 -0
  251. /package/types/{dynamic-scroller-item.type.d.mts → dynamic-scroller-item.type.d.ts} +0 -0
  252. /package/types/{dynamic-scroller.type.d.mts → dynamic-scroller.type.d.ts} +0 -0
  253. /package/types/{espace.type.d.mts → espace.type.d.ts} +0 -0
  254. /package/types/{exception.type.d.mts → exception.type.d.ts} +0 -0
  255. /package/types/{fall-menu.type.d.mts → fall-menu.type.d.ts} +0 -0
  256. /package/types/{filter-bar.type.d.mts → filter-bar.type.d.ts} +0 -0
  257. /package/types/{filter-box.type.d.mts → filter-box.type.d.ts} +0 -0
  258. /package/types/{filter-panel.type.d.mts → filter-panel.type.d.ts} +0 -0
  259. /package/types/{filter.type.d.mts → filter.type.d.ts} +0 -0
  260. /package/types/{floating-button.type.d.mts → floating-button.type.d.ts} +0 -0
  261. /package/types/{flowchart.type.d.mts → flowchart.type.d.ts} +0 -0
  262. /package/types/{fullscreen.type.d.mts → fullscreen.type.d.ts} +0 -0
  263. /package/types/{grid.type.d.mts → grid.type.d.ts} +0 -0
  264. /package/types/{guide.type.d.mts → guide.type.d.ts} +0 -0
  265. /package/types/{hrapprover.type.d.mts → hrapprover.type.d.ts} +0 -0
  266. /package/types/{image-viewer.type.d.mts → image-viewer.type.d.ts} +0 -0
  267. /package/types/{index-bar-anchor.type.d.mts → index-bar-anchor.type.d.ts} +0 -0
  268. /package/types/{index-bar.type.d.mts → index-bar.type.d.ts} +0 -0
  269. /package/types/{ip-address.type.d.mts → ip-address.type.d.ts} +0 -0
  270. /package/types/{layout.type.d.mts → layout.type.d.ts} +0 -0
  271. /package/types/{link-menu.type.d.mts → link-menu.type.d.ts} +0 -0
  272. /package/types/{list.type.d.mts → list.type.d.ts} +0 -0
  273. /package/types/{locales.type.d.mts → locales.type.d.ts} +0 -0
  274. /package/types/{logon-user.type.d.mts → logon-user.type.d.ts} +0 -0
  275. /package/types/{logout.type.d.mts → logout.type.d.ts} +0 -0
  276. /package/types/{mini-picker.type.d.mts → mini-picker.type.d.ts} +0 -0
  277. /package/types/{month-range.type.d.mts → month-range.type.d.ts} +0 -0
  278. /package/types/{month-table.type.d.mts → month-table.type.d.ts} +0 -0
  279. /package/types/{multi-select.type.d.mts → multi-select.type.d.ts} +0 -0
  280. /package/types/{notify.type.d.mts → notify.type.d.ts} +0 -0
  281. /package/types/{option-group.type.d.mts → option-group.type.d.ts} +0 -0
  282. /package/types/{option.type.d.mts → option.type.d.ts} +0 -0
  283. /package/types/{pager-item.type.d.mts → pager-item.type.d.ts} +0 -0
  284. /package/types/{pager.type.d.mts → pager.type.d.ts} +0 -0
  285. /package/types/{panel.type.d.mts → panel.type.d.ts} +0 -0
  286. /package/types/{picker-column.type.d.mts → picker-column.type.d.ts} +0 -0
  287. /package/types/{pop-upload.type.d.mts → pop-upload.type.d.ts} +0 -0
  288. /package/types/{popconfirm.type.d.mts → popconfirm.type.d.ts} +0 -0
  289. /package/types/{popup.type.d.mts → popup.type.d.ts} +0 -0
  290. /package/types/{pull-refresh.type.d.mts → pull-refresh.type.d.ts} +0 -0
  291. /package/types/{query-builder.type.d.mts → query-builder.type.d.ts} +0 -0
  292. /package/types/{rate.type.d.mts → rate.type.d.ts} +0 -0
  293. /package/types/{record.type.d.mts → record.type.d.ts} +0 -0
  294. /package/types/{recycle-scroller.type.d.mts → recycle-scroller.type.d.ts} +0 -0
  295. /package/types/{river.type.d.mts → river.type.d.ts} +0 -0
  296. /package/types/{roles.type.d.mts → roles.type.d.ts} +0 -0
  297. /package/types/{row.type.d.mts → row.type.d.ts} +0 -0
  298. /package/types/{scroll-text.type.d.mts → scroll-text.type.d.ts} +0 -0
  299. /package/types/{scrollbar.type.d.mts → scrollbar.type.d.ts} +0 -0
  300. /package/types/{select-dropdown.type.d.mts → select-dropdown.type.d.ts} +0 -0
  301. /package/types/{select-mobile.type.d.mts → select-mobile.type.d.ts} +0 -0
  302. /package/types/{select-view.type.d.mts → select-view.type.d.ts} +0 -0
  303. /package/types/{select.type.d.mts → select.type.d.ts} +0 -0
  304. /package/types/{selected-box.type.d.mts → selected-box.type.d.ts} +0 -0
  305. /package/types/{slide-bar.type.d.mts → slide-bar.type.d.ts} +0 -0
  306. /package/types/{slider-button-group.type.d.mts → slider-button-group.type.d.ts} +0 -0
  307. /package/types/{slider-button.type.d.mts → slider-button.type.d.ts} +0 -0
  308. /package/types/{split.type.d.mts → split.type.d.ts} +0 -0
  309. /package/types/{standard-list-item.type.d.mts → standard-list-item.type.d.ts} +0 -0
  310. /package/types/{tab-dropdown.type.d.mts → tab-dropdown.type.d.ts} +0 -0
  311. /package/types/{tab-item-mf.type.d.mts → tab-item-mf.type.d.ts} +0 -0
  312. /package/types/{tabbar-item.type.d.mts → tabbar-item.type.d.ts} +0 -0
  313. /package/types/{tabbar.type.d.mts → tabbar.type.d.ts} +0 -0
  314. /package/types/{table.type.d.mts → table.type.d.ts} +0 -0
  315. /package/types/{tabs-mf.type.d.mts → tabs-mf.type.d.ts} +0 -0
  316. /package/types/{tag-group.type.d.mts → tag-group.type.d.ts} +0 -0
  317. /package/types/{tall-storage.type.d.mts → tall-storage.type.d.ts} +0 -0
  318. /package/types/{text-popup.type.d.mts → text-popup.type.d.ts} +0 -0
  319. /package/types/{time-panel.type.d.mts → time-panel.type.d.ts} +0 -0
  320. /package/types/{time-picker-mobile.type.d.mts → time-picker-mobile.type.d.ts} +0 -0
  321. /package/types/{time-range.type.d.mts → time-range.type.d.ts} +0 -0
  322. /package/types/{time-spinner.type.d.mts → time-spinner.type.d.ts} +0 -0
  323. /package/types/{time.type.d.mts → time.type.d.ts} +0 -0
  324. /package/types/{toggle-menu.type.d.mts → toggle-menu.type.d.ts} +0 -0
  325. /package/types/{top-box.type.d.mts → top-box.type.d.ts} +0 -0
  326. /package/types/{transfer-panel.type.d.mts → transfer-panel.type.d.ts} +0 -0
  327. /package/types/{transfer.type.d.mts → transfer.type.d.ts} +0 -0
  328. /package/types/{tree-menu.type.d.mts → tree-menu.type.d.ts} +0 -0
  329. /package/types/{tree-node.type.d.mts → tree-node.type.d.ts} +0 -0
  330. /package/types/{tree.type.d.mts → tree.type.d.ts} +0 -0
  331. /package/types/{user-account.type.d.mts → user-account.type.d.ts} +0 -0
  332. /package/types/{user-contact.type.d.mts → user-contact.type.d.ts} +0 -0
  333. /package/types/{user-head-group.type.d.mts → user-head-group.type.d.ts} +0 -0
  334. /package/types/{user-head.type.d.mts → user-head.type.d.ts} +0 -0
  335. /package/types/{user-link.type.d.mts → user-link.type.d.ts} +0 -0
  336. /package/types/{user.type.d.mts → user.type.d.ts} +0 -0
  337. /package/types/{wheel.type.d.mts → wheel.type.d.ts} +0 -0
  338. /package/types/{year-range.type.d.mts → year-range.type.d.ts} +0 -0
  339. /package/types/{year-table.type.d.mts → year-table.type.d.ts} +0 -0
@@ -0,0 +1,68 @@
1
+ import "../../chunk-G2ADBYYC.js";
2
+ const TAP_OFFSET = 5;
3
+ const getDirection = (x, y) => {
4
+ if (x > y)
5
+ return "horizontal";
6
+ if (y > x)
7
+ return "vertical";
8
+ return "";
9
+ };
10
+ const touchEvent = (event) => event.touches[0];
11
+ const useTouch = (ref) => () => {
12
+ const startX = ref(0);
13
+ const startY = ref(0);
14
+ const deltaX = ref(0);
15
+ const deltaY = ref(0);
16
+ const offsetX = ref(0);
17
+ const offsetY = ref(0);
18
+ const direction = ref("");
19
+ const isTap = ref(true);
20
+ const isVertical = () => direction.value === "vertical";
21
+ const isHorizontal = () => direction.value === "horizontal";
22
+ const reset = () => {
23
+ deltaX.value = 0;
24
+ deltaY.value = 0;
25
+ offsetX.value = 0;
26
+ offsetY.value = 0;
27
+ direction.value = "";
28
+ isTap.value = true;
29
+ };
30
+ const start = (event) => {
31
+ reset();
32
+ const touch = touchEvent(event);
33
+ startX.value = touch.clientX;
34
+ startY.value = touch.clientY;
35
+ };
36
+ const move = (event) => {
37
+ const touch = touchEvent(event);
38
+ deltaX.value = (touch.clientX < 0 ? 0 : touch.clientX) - startX.value;
39
+ deltaY.value = touch.clientY - startY.value;
40
+ offsetX.value = Math.abs(deltaX.value);
41
+ offsetY.value = Math.abs(deltaY.value);
42
+ const LOCK_DIRECTION_DISTANCE = 10;
43
+ if (!direction.value || offsetX.value < LOCK_DIRECTION_DISTANCE && offsetY.value < LOCK_DIRECTION_DISTANCE) {
44
+ direction.value = getDirection(offsetX.value, offsetY.value);
45
+ }
46
+ if (isTap.value && (offsetX.value > TAP_OFFSET || offsetY.value > TAP_OFFSET)) {
47
+ isTap.value = false;
48
+ }
49
+ };
50
+ return {
51
+ move,
52
+ start,
53
+ reset,
54
+ isVertical,
55
+ isHorizontal,
56
+ startX,
57
+ startY,
58
+ deltaX,
59
+ deltaY,
60
+ offsetX,
61
+ offsetY,
62
+ direction,
63
+ isTap
64
+ };
65
+ };
66
+ export {
67
+ useTouch
68
+ };
@@ -41,8 +41,7 @@ var vue_popper_default = (options) => {
41
41
  el.appendChild(div);
42
42
  };
43
43
  const followHide = (popperInstance) => {
44
- var _a;
45
- const followReferenceHide = ((_a = props == null ? void 0 : props.popperOptions) == null ? void 0 : _a.followReferenceHide) || true;
44
+ const { followReferenceHide = true } = (props == null ? void 0 : props.popperOptions) || {};
46
45
  const { _popper: popper, _reference: reference } = popperInstance;
47
46
  if (followReferenceHide && getComputedStyle(reference).position !== "fixed" && reference.offsetParent === null) {
48
47
  popper.style.display = "none";
@@ -56,7 +55,7 @@ var vue_popper_default = (options) => {
56
55
  if (!/^(top|bottom|left|right)(-start|-end)?$/g.test(state.currentPlacement)) {
57
56
  return;
58
57
  }
59
- const options2 = props.popperOptions || { gpuAcceleration: false };
58
+ const options2 = props.popperOptions || {};
60
59
  state.popperElm = state.popperElm || props.popper || refs.popper;
61
60
  const popper = state.popperElm;
62
61
  let reference = getReference({ state, props, refs, slots });
package/common/index.js CHANGED
@@ -224,7 +224,7 @@ const CASCADER = {
224
224
  PropsHover: "hoverThreshold",
225
225
  MenuConnector: "cascader-menu-"
226
226
  };
227
- const version = "3.11.0";
227
+ const version = "3.12.0";
228
228
  const log = (data, type = "log") => {
229
229
  uLog.logger[type](data);
230
230
  };
package/common/runtime.js CHANGED
@@ -22,7 +22,7 @@ import vuePopup from "./deps/vue-popup";
22
22
  import validate from "./validate";
23
23
  import memorize from "./deps/memorize";
24
24
  import * as common from ".";
25
- const version = "3.11.0";
25
+ const version = "3.12.0";
26
26
  const Renderless = {
27
27
  browser,
28
28
  array,
package/common/string.js CHANGED
@@ -119,15 +119,7 @@ const random = () => {
119
119
  let MAX_UINT32_PLUS_ONE = 4294967296;
120
120
  return window.crypto.getRandomValues(new window.Uint32Array(1))[0] / MAX_UINT32_PLUS_ONE;
121
121
  };
122
- const guid = (prefix = "", length = 8) => {
123
- return "xxxxxxxx".replace(/[x]/g, (c) => {
124
- const random2 = parseFloat("0." + crypto.getRandomValues(new Uint32Array(1))[0]);
125
- const r = random2 * 16 | 0;
126
- const v = c === "x" ? r : r & 3 | 8;
127
- const randomStr = v.toString(16);
128
- return prefix + randomStr.substring(0, length);
129
- });
130
- };
122
+ const guid = (prefix = "", length = 8) => prefix + random().toString().substr(2, length);
131
123
  const escapeHtml = (string, isReplaceSpace) => {
132
124
  if (!string || typeof string !== "string") {
133
125
  return string;
@@ -350,6 +342,24 @@ const toFileSize = (value, unit, currUnit) => {
350
342
  }
351
343
  return value;
352
344
  };
345
+ const formatFileSize = (size, baseUnit = "") => {
346
+ if ([void 0, null].includes(size)) {
347
+ return "";
348
+ } else if (!isNumber(size) || size <= 0) {
349
+ return size + baseUnit;
350
+ }
351
+ const unitArr = ["B", "K", "M", "G", "T", "P", "E", "Z", "Y"];
352
+ let unitIndex = Math.max(unitArr.indexOf((baseUnit + "").toLocaleUpperCase()), 0);
353
+ while (size >= 1024 && unitIndex < unitArr.length - 1) {
354
+ size = size / 1024;
355
+ unitIndex++;
356
+ }
357
+ while (size < 1 && unitIndex > 0) {
358
+ size = size * 1024;
359
+ unitIndex--;
360
+ }
361
+ return parseFloat(toDecimal(size, 2, true)) + unitArr[unitIndex];
362
+ };
353
363
  const isKorean = (text) => /([(\uAC00-\uD7AF)|(\u3130-\u318F)])+/gi.test(text);
354
364
  const omitText = (text, font, w) => {
355
365
  const canvas = document.createElement("canvas");
@@ -378,6 +388,7 @@ export {
378
388
  fieldFormat,
379
389
  fillChar,
380
390
  format,
391
+ formatFileSize,
381
392
  formatTypes,
382
393
  getLength,
383
394
  guid,
@@ -13,7 +13,10 @@ const getTrueValue = (value) => {
13
13
  }
14
14
  return parseInt(value, 10);
15
15
  };
16
- const getBoundary = ({ api, constants, props }) => ({ type, value: val }) => {
16
+ const getBoundary = ({ api, constants, props }) => ({
17
+ type,
18
+ value: val
19
+ }) => {
17
20
  const boundary = props[`${type}${constants.CapDate}`];
18
21
  const year = boundary.getFullYear();
19
22
  let month = 1;
@@ -46,7 +49,13 @@ const getBoundary = ({ api, constants, props }) => ({ type, value: val }) => {
46
49
  [`${type}${constants.CapMinute}`]: minute
47
50
  };
48
51
  };
49
- const updateInnerValue = ({ api, constants, props, refs, state }) => () => {
52
+ const updateInnerValue = ({
53
+ api,
54
+ constants,
55
+ props,
56
+ refs,
57
+ state
58
+ }) => () => {
50
59
  const indexes = refs.picker && refs.picker.getIndexes();
51
60
  const getValue = (index) => {
52
61
  const { values } = state.originColumns[index];
@@ -95,7 +104,13 @@ const padZero = (num, targetLength = 2) => {
95
104
  }
96
105
  return str;
97
106
  };
98
- const updateColumnValue = ({ constants, nextTick, props, refs, state }) => () => {
107
+ const updateColumnValue = ({
108
+ constants,
109
+ nextTick,
110
+ props,
111
+ refs,
112
+ state
113
+ }) => () => {
99
114
  const value = state.innerValue;
100
115
  const { formatter } = props;
101
116
  let values = [
@@ -211,7 +226,12 @@ const getDisplayValue = ({ constants, DATE, props, state }) => () => {
211
226
  };
212
227
  return format(state.innerValue, props.type === constants.DateTime ? DATE.Datetime : DATE.Date);
213
228
  };
214
- const hookMounted = ({ constants, parent, refs, nextTick }) => () => {
229
+ const hookMounted = ({
230
+ constants,
231
+ parent,
232
+ refs,
233
+ nextTick
234
+ }) => () => {
215
235
  nextTick(() => {
216
236
  parent.$emit(constants.HookMounted, refs.refrence.$el);
217
237
  });
@@ -124,7 +124,11 @@ const watchVisible = ({ emit, api, state }) => (bool) => {
124
124
  };
125
125
  const scrollToCurrentDate = ({ state, vm, nextTick }) => ({ date, value }) => {
126
126
  const { isYearMonthPanel, computedYears, months } = state;
127
- let field, list, year, month, index = -1;
127
+ let field;
128
+ let list;
129
+ let year;
130
+ let month;
131
+ let index = -1;
128
132
  if (date) {
129
133
  year = date.getFullYear();
130
134
  month = date.getMonth() + 1;
@@ -50,6 +50,7 @@ const initService = ({
50
50
  getFileDownloadUrl: noopFnCreator(common.getFileDownloadUrl),
51
51
  getSingleDownloadUrl: noopFnCreator(common.getSingleDownloadUrl),
52
52
  getPackageDownloadUrl: noopFnCreator(common.getPackageDownloadUrl),
53
+ getAsyncPackageDownload: noopFnCreator(common.getAsyncPackageDownload),
53
54
  getLargeFileInitUrl: noopFnCreator(common.getLargeFileInitUrl),
54
55
  getChunkUploadUrl: noopFnCreator(common.getChunkUploadUrl),
55
56
  getPreviewUrl: noopFnCreator(common.getPreviewUrl),
@@ -193,7 +194,7 @@ const beforeUpload = ({
193
194
  if (!isValid) {
194
195
  remove({ api, file, autoRemove });
195
196
  return Modal.message({
196
- message: t(constants.EDM.notSupport, { format: fileType }),
197
+ message: fileType ? t(constants.EDM.notSupport, { format: fileType }) : t(constants.EDM.NOT_SUPPORT_NO_SUFFIX),
197
198
  status: "warning"
198
199
  });
199
200
  }
@@ -251,15 +252,16 @@ const calcFileForMobile = (rawFile, file) => {
251
252
  file.fileType = rawFile.name.substring(fileName + 1, fileNameLen);
252
253
  const size = rawFile.size / 1024;
253
254
  if (size < 1024) {
254
- file.size = Math.round(size * Math.pow(10, 1)) / Math.pow(10, 1) + "KB";
255
+ file.size = Math.round(size * 10 ** 1) / 10 ** 1 + "KB";
255
256
  } else {
256
257
  const fileSize = size / 1024;
257
- file.size = Math.round(fileSize * Math.pow(10, 1)) / Math.pow(10, 1) + "MB";
258
+ file.size = Math.round(fileSize * 10 ** 1) / 10 ** 1 + "MB";
258
259
  }
259
260
  };
260
261
  const properFileSize = ({
261
262
  props,
262
263
  state,
264
+ api,
263
265
  constants,
264
266
  Modal,
265
267
  t
@@ -275,7 +277,7 @@ const properFileSize = ({
275
277
  if (state.isEdm || !state.isEdm && Array.isArray(props.fileSize) && props.fileSize[1]) {
276
278
  if (file.size > maxSize * 1024 * 1024) {
277
279
  Modal.message({
278
- message: t(constants.EDM.EXCEED, { maxSize }),
280
+ message: t(constants.EDM.EXCEED, { maxSize: api.formatFileSize(Number(maxSize), "M") }),
279
281
  status: "warning"
280
282
  });
281
283
  return false;
@@ -291,7 +293,7 @@ const properFileSize = ({
291
293
  const userMin = props.fileSize && (props.fileSize[0] || props.fileSize) || 0;
292
294
  if (file.size <= userMin * 1024) {
293
295
  Modal.message({
294
- message: `${t(constants.EDM.SIZE).replace(/{name}/, file.name)} ${userMin} KB`,
296
+ message: `${t(constants.EDM.SIZE, { minSize: api.formatFileSize(Number(userMin), "K"), sizeUnit: "" })}`,
295
297
  status: "warning"
296
298
  });
297
299
  return false;
@@ -441,7 +443,7 @@ const handleStart = ({
441
443
  state.currentUploadingFileUids = [];
442
444
  rawFiles.forEach((rawFile) => api.addFileToList(rawFile, updateId, reUpload));
443
445
  const { UPLOADING, READY } = constants.FILE_STATUS;
444
- state.uploadingFiles = state.uploadFiles.filter((file) => [UPLOADING, READY].indexOf(file.status) > -1);
446
+ state.uploadingFiles = state.uploadFiles.filter((file) => [UPLOADING, READY].includes(file.status));
445
447
  if (state.isEdm && state.isSuccess) {
446
448
  rawFiles.forEach((rawFile) => {
447
449
  const file = api.getFile(rawFile);
@@ -554,7 +556,9 @@ const handleSuccess = ({
554
556
  constants,
555
557
  emit,
556
558
  state,
557
- props
559
+ props,
560
+ Modal,
561
+ t
558
562
  }) => (res, rawFile) => {
559
563
  const currentUploadFiles = state.uploadFiles.filter((file) => state.currentUploadingFileUids.includes(file.uid));
560
564
  if (Array.isArray(rawFile)) {
@@ -570,8 +574,16 @@ const handleSuccess = ({
570
574
  });
571
575
  } else {
572
576
  const file = api.getFile(rawFile);
577
+ const status = res.data && res.data.status;
578
+ const { STATUS_SPECIAL_CHARACTERS, NOT_SUPPORT_SPECIAL_CHARACTERS } = constants.EDM;
573
579
  delete file.cancelToken;
574
- if (props.edm.upload && file && res.data && res.data.status !== 200) {
580
+ if (props.edm.upload && file && res.data && status !== 200) {
581
+ if (status === STATUS_SPECIAL_CHARACTERS) {
582
+ Modal.message({
583
+ message: `${t(NOT_SUPPORT_SPECIAL_CHARACTERS)}`,
584
+ status: "warning"
585
+ });
586
+ }
575
587
  file.status = constants.FILE_STATUS.FAIL;
576
588
  emit("error", res, file, state.uploadFiles);
577
589
  return;
@@ -602,13 +614,19 @@ const handleSuccess = ({
602
614
  }
603
615
  api.clearUploadingFiles();
604
616
  };
605
- const handleError = ({ api, constants, emit, state }) => (err, rawFile) => {
617
+ const handleError = ({
618
+ api,
619
+ constants,
620
+ emit,
621
+ state,
622
+ props
623
+ }) => (err, rawFile) => {
606
624
  const file = api.getFile(rawFile);
607
625
  if (!file)
608
626
  return;
609
627
  file.status = constants.FILE_STATUS.FAIL;
610
628
  file.percentage = 100;
611
- if (!state.isEdm) {
629
+ if (!state.isEdm && !props.reUploadable) {
612
630
  state.uploadFiles.splice(state.uploadFiles.indexOf(file), 1);
613
631
  }
614
632
  api.clearUploadingFiles();
@@ -626,7 +644,6 @@ const handleRemove = ({
626
644
  file = api.getFile(raw);
627
645
  }
628
646
  let doRemove = () => {
629
- file.status = constants.FILE_STATUS.FAIL;
630
647
  api.abort(file);
631
648
  let fileList = state.uploadFiles;
632
649
  fileList.splice(fileList.indexOf(file), 1);
@@ -648,9 +665,22 @@ const handleRemove = ({
648
665
  }
649
666
  }
650
667
  };
668
+ const handleReUpload = ({ vm, constants }) => (file) => {
669
+ const { READY } = constants.FILE_STATUS;
670
+ file.status = READY;
671
+ file.percentage = 0;
672
+ vm.$refs[constants.UPLOAD_INNER].$refs[constants.UPLOAD_INNER_TEMPLATE].upload(file.raw);
673
+ };
674
+ const handleReUploadTotal = (api) => (files) => {
675
+ files.forEach((file) => {
676
+ if (file.status === "fail") {
677
+ api.handleReUpload(file);
678
+ }
679
+ });
680
+ };
651
681
  const clearUploadingFiles = ({ constants, state }) => () => {
652
682
  const { SUCESS, FAIL } = constants.FILE_STATUS;
653
- const isUploadComplete = state.uploadingFiles.every((file) => [SUCESS, FAIL].indexOf(file.status) > -1);
683
+ const isUploadComplete = state.uploadingFiles.every((file) => [SUCESS, FAIL].includes(file.status));
654
684
  if (isUploadComplete) {
655
685
  state.uploadingFiles = [];
656
686
  }
@@ -770,8 +800,9 @@ const getTranslateFile = ({
770
800
  }
771
801
  } else {
772
802
  const content = data.headers["content-disposition"];
773
- const name = content.match(/fileName.?=(.*)/)[1] || content.match(/fileName=(.*)/)[1];
774
- const blob = new Blob([data.data], { type: type !== "zip" ? "application / x - xls" : "application/zip" });
803
+ const name = content ? content.match(/fileName.?=(.*)/)[1] || content.match(/fileName=(.*)/)[1] : "";
804
+ const type2 = !name.includes(".") ? data.headers["content-type"] : type2 !== "zip" ? "application / x - xls" : "application/zip";
805
+ const blob = new Blob([data.data], { type: type2 });
775
806
  aLinkDownload({ blob, name });
776
807
  }
777
808
  };
@@ -874,7 +905,7 @@ const validateDownloadStatus = ({ state, Modal }) => ({
874
905
  downloadOps2.fail(errRes, file2);
875
906
  }
876
907
  };
877
- if (data.data && data.data.type && data.data.type.indexOf("application/json") > -1) {
908
+ if (data.data && data.data.type && data.data.type.includes("application/json")) {
878
909
  const reader = new FileReader();
879
910
  reader.onload = (e) => {
880
911
  const errRes = JSON.parse(e.target.result);
@@ -883,7 +914,7 @@ const validateDownloadStatus = ({ state, Modal }) => ({
883
914
  reader.readAsText(data.data);
884
915
  return true;
885
916
  }
886
- if (!isLessThan17G && data.headers["content-type"].indexOf("application/json") > -1) {
917
+ if (!isLessThan17G && data.headers["content-type"].includes("application/json")) {
887
918
  const errRes = JSON.parse(String.fromCharCode.apply(null, new Uint8Array(data.data)));
888
919
  errorHandle({ state, file, errRes, Modal, downloadOps });
889
920
  return true;
@@ -911,12 +942,24 @@ const downloadFileSingle = ({
911
942
  api,
912
943
  emit
913
944
  }) => (args) => {
914
- let { file, batchIndex, isChunk, calcProgress, handleSuccess: handleSuccess2, range = {}, isBatch, isLessThan17G } = args;
915
- let getServiceUrl = ({ url, file: file2 }) => url.replace(/{docId}/, file2.docId || file2) + `${~url.indexOf("?") ? "&" : "?"}x-download-sign=true&docVersion=${file2.docVersion || ""}`;
916
- let sdResolver = (url) => {
917
- let serviceUrl = getServiceUrl({ url, file });
945
+ let {
946
+ file,
947
+ batchIndex,
948
+ isChunk,
949
+ calcProgress,
950
+ handleSuccess: handleSuccess2,
951
+ range = {},
952
+ isBatch,
953
+ isLessThan17G,
954
+ url: fileUrl
955
+ } = args;
956
+ const promise = fileUrl ? Promise.resolve(fileUrl) : service.getSingleDownloadUrl().then((url) => {
957
+ let serviceUrl = url.replace(/{docId}/, file.docId || file) + `${~url.indexOf("?") ? "&" : "?"}x-download-sign=true&docVersion=${file.docVersion || ""}${file.decryptKey ? "&decryptKey=" + file.decryptKey : ""}`;
918
958
  serviceUrl = api.modifyServiceUrlSingle({ file, serviceUrl, range });
919
- serviceUrl = xss.filterUrl(serviceUrl);
959
+ return serviceUrl;
960
+ });
961
+ promise.then((url) => {
962
+ url = xss.filterUrl(url);
920
963
  let params = {
921
964
  withCredentials: props.withCredentials,
922
965
  headers: Object.assign(props.headers, state.headers),
@@ -924,7 +967,7 @@ const downloadFileSingle = ({
924
967
  hideErr: true,
925
968
  cancelToken: api.createDownloadCancelToken(file),
926
969
  onDownloadProgress(evt) {
927
- let progress = calcProgress(evt);
970
+ let progress = calcProgress(evt, isChunk);
928
971
  if (progress !== 100) {
929
972
  !isChunk && emit("download", progress, evt);
930
973
  }
@@ -933,7 +976,7 @@ const downloadFileSingle = ({
933
976
  }
934
977
  }
935
978
  };
936
- service.get(serviceUrl, params).then((data) => {
979
+ service.get(url, params).then((data) => {
937
980
  if (api.getKiaScanTip({ data }))
938
981
  return;
939
982
  if (api.validateDownloadStatus({ downloadOps: props.edm.download || {}, file, isLessThan17G, data }))
@@ -955,8 +998,7 @@ const downloadFileSingle = ({
955
998
  });
956
999
  }
957
1000
  });
958
- };
959
- service.getSingleDownloadUrl().then(sdResolver);
1001
+ });
960
1002
  };
961
1003
  const downloadFileBatch = ({
962
1004
  api,
@@ -967,6 +1009,7 @@ const downloadFileBatch = ({
967
1009
  }) => (args) => {
968
1010
  let { downloadOps, file, calcProgress, handleSuccess: handleSuccess2, range = {} } = args;
969
1011
  let tokenParams = { token: downloadOps.packageToken, file, type: "download" };
1012
+ const { asyncPackages } = downloadOps || {};
970
1013
  api.getToken(tokenParams).then((data) => {
971
1014
  if (!data) {
972
1015
  return;
@@ -979,9 +1022,12 @@ const downloadFileBatch = ({
979
1022
  params.downloadTOs.push(item);
980
1023
  }
981
1024
  });
1025
+ if (asyncPackages) {
1026
+ api.downloadAsyncPackage(params);
1027
+ return;
1028
+ }
982
1029
  service.getPackageDownloadUrl().then((url) => {
983
- url += `${~url.indexOf("?") ? "&" : "?"}x-download-sign=true`;
984
- url = xss.filterUrl(url);
1030
+ url = xss.filterUrl(url + `${~url.indexOf("?") ? "&" : "?"}x-download-sign=true`);
985
1031
  service.post(
986
1032
  url,
987
1033
  __spreadValues(__spreadValues({}, params), range),
@@ -1007,6 +1053,54 @@ const downloadFileBatch = ({
1007
1053
  });
1008
1054
  });
1009
1055
  };
1056
+ const downloadAsyncPackage = ({ state, props, service, api, constants }) => (params) => {
1057
+ return service.getAsyncPackageDownload().then((url) => {
1058
+ service.request({
1059
+ method: "post",
1060
+ url: xss.filterUrl(url),
1061
+ withCredentials: props.withCredentials,
1062
+ headers: Object.assign(props.headers, state.headers),
1063
+ data: params
1064
+ }).then((res) => {
1065
+ if (res && res.data && res.data.status === 200) {
1066
+ const files = (res.data.result || []).map(({ downloadLink, fileSize }) => {
1067
+ return { url: downloadLink, fileSize };
1068
+ });
1069
+ const { SIZE_17G } = constants.EDM;
1070
+ const isBatch = false;
1071
+ const isChunk = false;
1072
+ const downloadOps = props.edm.download || {};
1073
+ files.forEach((file) => {
1074
+ const isLessThan17G = !file.fileSize || file.fileSize < SIZE_17G * 1024;
1075
+ const translateFile = getTranslateFile({ api, isChunk, isLessThan17G, file, state });
1076
+ const handleSuccess2 = getHandleSuccess({
1077
+ downloadOps,
1078
+ file,
1079
+ translateFile,
1080
+ isChunk,
1081
+ state,
1082
+ isLessThan17G
1083
+ });
1084
+ const calcProgress = getCalcProgress();
1085
+ const args = {
1086
+ url: file.url,
1087
+ calcProgress,
1088
+ handleSuccess: handleSuccess2,
1089
+ downloadOps,
1090
+ file,
1091
+ isLessThan17G,
1092
+ isFinished: false,
1093
+ range: {},
1094
+ batchIndex: 0,
1095
+ isBatch,
1096
+ isChunk
1097
+ };
1098
+ api.downloadFileSingle(args);
1099
+ });
1100
+ }
1101
+ });
1102
+ });
1103
+ };
1010
1104
  const downloadFileSingleHwh5 = ({ state, props, emit, constants }) => ({ file }) => {
1011
1105
  const { HWH5, appId } = props.hwh5;
1012
1106
  const { downloadToEDM } = HWH5();
@@ -1062,24 +1156,16 @@ const downloadFileSingleInner = ({ props, state, api, constants }) => ({ file, i
1062
1156
  api.downloadFileSingleHwh5({ file });
1063
1157
  return;
1064
1158
  }
1065
- if (state.hasFileInfoInterface) {
1066
- api.getDownloadFileInfo({ docId: file.docId }).then((res) => {
1067
- let fileInfo;
1068
- if (res && res.outDocQueryList[0].verInfo[0]) {
1069
- fileInfo = res.outDocQueryList[0].verInfo[0].docInfo[0];
1070
- }
1071
- const { fileSize } = fileInfo;
1072
- const isLargeFile = fileSize > state.docSize && fileSize > state.chunkSize;
1073
- const isLessThan17G = fileSize < SIZE_17G * 1024;
1074
- if (isLargeFile) {
1075
- api.largeDocumentDownload({ file: fileInfo, isBatch, isLessThan17G });
1076
- } else {
1077
- api.downloadFileInner({ file, isBatch });
1078
- }
1079
- });
1080
- } else {
1081
- api.downloadFileInner({ file, isBatch });
1082
- }
1159
+ const promise = state.hasFileInfoInterface ? api.getDownloadFileInfo({ docId: file.docId }) : Promise.resolve();
1160
+ promise.then((fileInfo) => {
1161
+ const { fileSize } = fileInfo || {};
1162
+ const isLargeFile = fileSize > state.docSize && fileSize > state.chunkSize;
1163
+ if (fileSize && isLargeFile) {
1164
+ api.largeDocumentDownload({ file: fileInfo, isBatch, isLessThan17G: fileSize < SIZE_17G * 1024 });
1165
+ } else {
1166
+ api.downloadFileInner({ file, isBatch });
1167
+ }
1168
+ });
1083
1169
  });
1084
1170
  };
1085
1171
  const getDownloadFileInfo = ({ api, state, props, service }) => ({ docId }) => {
@@ -1093,8 +1179,10 @@ const getDownloadFileInfo = ({ api, state, props, service }) => ({ docId }) => {
1093
1179
  cancelToken: api.createDownloadCancelToken({ docId }),
1094
1180
  data: { docInfoVO: { ids: [docId], docType: "", docVersion: "" } }
1095
1181
  }).then((res) => {
1096
- if (res.data.status === 200) {
1097
- resolve(res.data.result);
1182
+ const { data, outDocQueryList } = res || {};
1183
+ if (data && data.status === 200) {
1184
+ const fileInfo = outDocQueryList && outDocQueryList[0].verInfo[0].docInfo[0];
1185
+ resolve(fileInfo);
1098
1186
  } else {
1099
1187
  reject(res);
1100
1188
  }
@@ -1231,9 +1319,10 @@ const setWriterFile = ({
1231
1319
  let { fileStream, writer, fileData = [], downloaded = 0 } = {};
1232
1320
  const { checkcode } = data.headers;
1233
1321
  const content = data.headers["content-disposition"];
1234
- const name = content.match(/fileName.?=(.*)/)[1] || content.match(/fileName=(.*)/)[1];
1235
1322
  let { chunkNum, fileSize, docName } = state.downloadChunkFile[file.docId];
1236
- docName = name || docName;
1323
+ if (content) {
1324
+ docName = content.match(/fileName.?=(.*)/)[1] || content.match(/fileName=(.*)/)[1] || docName;
1325
+ }
1237
1326
  if (!isLessThan17G) {
1238
1327
  fileStream = Streamsaver.createWriteStream(docName, { size: data.byteLength });
1239
1328
  writer = fileStream.getWriter();
@@ -1565,7 +1654,7 @@ const sliceChunk = ({ state }) => (file) => {
1565
1654
  state.batchQueue[file.docId + "-0"] = 0;
1566
1655
  state.batchQueueListen[file.docId + "-0"] = 0;
1567
1656
  for (let i = 0; i < chunkSize; i++) {
1568
- if (file.records.indexOf(i.toString()) > -1) {
1657
+ if (file.records.includes(i.toString())) {
1569
1658
  continue;
1570
1659
  }
1571
1660
  const start = i * state.chunkSize;
@@ -1973,6 +2062,11 @@ const handleClickFileList = ({ state, emit }) => (file) => {
1973
2062
  const mounted = ({ vm, state }) => () => {
1974
2063
  vm.$on("drag-over", (isDragover) => state.isDragover = isDragover);
1975
2064
  };
2065
+ const encryptDialogConfirm = ({ state }) => () => {
2066
+ const selectFileMethod = state.encryptDialogConfig.selectFileMethod;
2067
+ state.encryptDialogConfig.show = false;
2068
+ typeof selectFileMethod === "function" && selectFileMethod();
2069
+ };
1976
2070
  export {
1977
2071
  abort,
1978
2072
  abortDownload,
@@ -1989,12 +2083,14 @@ export {
1989
2083
  computedUploadDisabled,
1990
2084
  computedUploadingSize,
1991
2085
  createDownloadCancelToken,
2086
+ downloadAsyncPackage,
1992
2087
  downloadFile,
1993
2088
  downloadFileBatch,
1994
2089
  downloadFileInner,
1995
2090
  downloadFileSingle,
1996
2091
  downloadFileSingleHwh5,
1997
2092
  downloadFileSingleInner,
2093
+ encryptDialogConfirm,
1998
2094
  getCalcProgress,
1999
2095
  getDialogConfigObj,
2000
2096
  getDownloadFileInfo,
@@ -2013,6 +2109,8 @@ export {
2013
2109
  handleClickFileList,
2014
2110
  handleError,
2015
2111
  handleProgress,
2112
+ handleReUpload,
2113
+ handleReUploadTotal,
2016
2114
  handleRemove,
2017
2115
  handleStart,
2018
2116
  handleSuccess,