@fewangsit/wangsvue 1.5.219-alpha.0 → 1.5.219-alpha.2

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 (598) hide show
  1. package/animation/index.es.js +54 -37
  2. package/assets/lottiejs/loading-page.es.js +14 -9
  3. package/assets/lottiejs/loading-plane.es.js +2 -2
  4. package/assets/lottiejs/loading-table.es.js +14 -9
  5. package/assets/lottiejs/no-data.es.js +14 -9
  6. package/backgroundimagecropper/index.es.js +61 -37
  7. package/badge/index.es.js +77 -67
  8. package/badgegroup/index.es.js +62 -50
  9. package/basecalendar/index.es.js +1258 -735
  10. package/basetree/index.es.js +213 -113
  11. package/breadcrumb/index.es.js +46 -38
  12. package/button/index.es.js +60 -54
  13. package/buttonbulkaction/index.es.js +168 -117
  14. package/buttoncopy/index.es.js +25 -22
  15. package/buttondownload/index.es.js +125 -76
  16. package/buttonfilter/index.es.js +21 -15
  17. package/buttonradio/index.es.js +91 -67
  18. package/buttonsearch/index.es.js +62 -46
  19. package/buttonselecttree/index.es.js +233 -172
  20. package/buttontoggle/index.es.js +8 -6
  21. package/calendar/index.es.js +113 -58
  22. package/card/index.es.js +44 -42
  23. package/checkbox/index.es.js +105 -74
  24. package/codesnippet/index.es.js +91 -71
  25. package/codesnippetadapter/index.es.js +25 -21
  26. package/columnlist/index.es.js +249 -171
  27. package/components.d.ts +0 -21
  28. package/config/defaultProps.es.js +9 -9
  29. package/config/index.es.js +11 -10
  30. package/config/locale.es.js +2 -2
  31. package/customcolumn/index.es.js +95 -78
  32. package/datatable/index.es.js +1071 -732
  33. package/dialog/index.es.js +54 -54
  34. package/dialogconfirm/index.es.js +90 -75
  35. package/dialogform/index.es.js +170 -133
  36. package/dialogselecttree/index.es.js +242 -194
  37. package/directives/focus.es.js +13 -8
  38. package/dropdown/index.es.js +250 -196
  39. package/editor/index.es.js +694 -498
  40. package/editorbutton/index.es.js +21 -19
  41. package/event-bus/index.es.js +3 -3
  42. package/event-bus/mitt.es.js +37 -20
  43. package/fieldwrapper/index.es.js +30 -25
  44. package/fileupload/index.es.js +230 -140
  45. package/filtercontainer/index.es.js +299 -222
  46. package/form/index.es.js +176 -126
  47. package/gallerypreview/index.es.js +138 -101
  48. package/icon/index.es.js +38 -36
  49. package/image/index.es.js +161 -108
  50. package/imagecompressor/index.es.js +616 -449
  51. package/imageinputinfo/index.es.js +26 -22
  52. package/inlinemessage/index.es.js +77 -65
  53. package/inputbadge/index.es.js +230 -156
  54. package/inputcurrency/index.es.js +146 -109
  55. package/inputemail/index.es.js +18 -16
  56. package/inputgroup/index.es.js +19 -16
  57. package/inputnumber/index.es.js +252 -182
  58. package/inputpassword/index.es.js +120 -94
  59. package/inputphonenumber/index.es.js +1017 -550
  60. package/inputrangenumber/index.es.js +129 -98
  61. package/inputtext/index.es.js +264 -189
  62. package/inputurl/index.es.js +31 -29
  63. package/invisiblefield/index.es.js +24 -16
  64. package/litedropdown/index.es.js +87 -81
  65. package/loading/index.es.js +21 -19
  66. package/loading-page-BXZ4fLOS.js +8 -0
  67. package/loading-page-BuLpsb_1.js +8 -0
  68. package/loading-page-CNqVBg__.js +4 -0
  69. package/loading-page-DbhhZih2.js +4 -0
  70. package/loading-page-DjfWXoOy.js +8 -0
  71. package/loading-page-S-KRY5zm.js +4 -0
  72. package/loading-plane-C1mi7Whv.js +4 -0
  73. package/loading-plane-CWq1hz_l.js +8 -0
  74. package/loading-table-B7LAXzAp.js +4 -0
  75. package/loading-table-BLmgKUsR.js +4 -0
  76. package/loading-table-CG7-cuhv.js +8 -0
  77. package/loading-table-CUPS49ta.js +4 -0
  78. package/loading-table-CuWWrTbv.js +8 -0
  79. package/loading-table-DbBzVwaZ.js +8 -0
  80. package/mentionlist/index.es.js +77 -44
  81. package/mentionsection/index.es.js +53 -43
  82. package/menu/index.es.js +65 -51
  83. package/menuitem/index.es.js +39 -37
  84. package/multirow/index.es.js +29 -28
  85. package/multiselect/index.es.js +184 -152
  86. package/no-data-B781skt3.js +4 -0
  87. package/no-data-CAksOnDl.js +4 -0
  88. package/no-data-DCsjBXQR.js +4 -0
  89. package/no-data-Dz0QOe7Q.js +8 -0
  90. package/no-data-_Huxiv9q.js +8 -0
  91. package/no-data-ybRQontJ.js +8 -0
  92. package/overlaypanel/index.es.js +49 -36
  93. package/package.json +1 -1
  94. package/paginator/index.es.js +36 -33
  95. package/plugins/WangsVue.es.js +63 -45
  96. package/plugins/formValidation.es.js +15 -11
  97. package/progressbar/index.es.js +39 -32
  98. package/quickfilter/index.es.js +94 -81
  99. package/stats.html +1 -1
  100. package/style.css +2 -2
  101. package/tabmenu/index.es.js +18 -16
  102. package/textarea/index.es.js +94 -72
  103. package/timeline/index.es.js +124 -102
  104. package/timelinecontentbytype/index.es.js +114 -92
  105. package/toast/index.es.js +67 -54
  106. package/toggleswitch/index.es.js +83 -66
  107. package/tree/index.es.js +306 -198
  108. package/treenode/index.es.js +464 -339
  109. package/treesearchinput/index.es.js +32 -26
  110. package/usergroup/index.es.js +83 -67
  111. package/username/index.es.js +99 -85
  112. package/utils/addAttachment.util.es.js +47 -21
  113. package/utils/baseToast.util.es.js +41 -33
  114. package/utils/convertJsonImage.util.es.js +24 -24
  115. package/utils/date.util.es.js +131 -106
  116. package/utils/exportToExcel.util.es.js +81 -47
  117. package/utils/filterOptions.util.es.js +8 -2
  118. package/utils/genPlaceholder.util.es.js +30 -16
  119. package/utils/getProjectPermission.util.es.js +15 -12
  120. package/utils/getSalesRole.util.es.js +4 -4
  121. package/utils/getUser.util.es.js +2 -2
  122. package/utils/getUserType.util.es.js +13 -8
  123. package/utils/isIntersect.es.js +4 -2
  124. package/utils/mergePropsWithDefaults.util.es.js +7 -6
  125. package/utils/object.util.es.js +88 -54
  126. package/utils/queryParamsStringfy.util.es.js +19 -11
  127. package/utils/role.util.es.js +5 -4
  128. package/utils/statusSeverity.util.es.js +20 -5
  129. package/utils/textFormatter.util.es.js +28 -50
  130. package/utils/toast.util.es.js +8 -5
  131. package/utils/xlsx.util.es.js +12 -6
  132. package/validatormessage/index.es.js +9 -9
  133. package/vendor/@popperjs/core/lib/createPopper.es.js +110 -83
  134. package/vendor/@popperjs/core/lib/dom-utils/contains.es.js +14 -13
  135. package/vendor/@popperjs/core/lib/dom-utils/getBoundingClientRect.es.js +33 -18
  136. package/vendor/@popperjs/core/lib/dom-utils/getClippingRect.es.js +55 -31
  137. package/vendor/@popperjs/core/lib/dom-utils/getCompositeRect.es.js +43 -22
  138. package/vendor/@popperjs/core/lib/dom-utils/getComputedStyle.es.js +4 -4
  139. package/vendor/@popperjs/core/lib/dom-utils/getDocumentElement.es.js +5 -5
  140. package/vendor/@popperjs/core/lib/dom-utils/getDocumentRect.es.js +23 -13
  141. package/vendor/@popperjs/core/lib/dom-utils/getHTMLElementScroll.es.js +4 -4
  142. package/vendor/@popperjs/core/lib/dom-utils/getLayoutRect.es.js +17 -9
  143. package/vendor/@popperjs/core/lib/dom-utils/getNodeName.es.js +3 -3
  144. package/vendor/@popperjs/core/lib/dom-utils/getNodeScroll.es.js +11 -7
  145. package/vendor/@popperjs/core/lib/dom-utils/getOffsetParent.es.js +42 -26
  146. package/vendor/@popperjs/core/lib/dom-utils/getParentNode.es.js +13 -10
  147. package/vendor/@popperjs/core/lib/dom-utils/getScrollParent.es.js +13 -7
  148. package/vendor/@popperjs/core/lib/dom-utils/getViewportRect.es.js +25 -15
  149. package/vendor/@popperjs/core/lib/dom-utils/getWindow.es.js +8 -7
  150. package/vendor/@popperjs/core/lib/dom-utils/getWindowScroll.es.js +8 -6
  151. package/vendor/@popperjs/core/lib/dom-utils/getWindowScrollBarX.es.js +6 -6
  152. package/vendor/@popperjs/core/lib/dom-utils/instanceOf.es.js +16 -15
  153. package/vendor/@popperjs/core/lib/dom-utils/isLayoutViewport.es.js +4 -4
  154. package/vendor/@popperjs/core/lib/dom-utils/isScrollParent.es.js +5 -5
  155. package/vendor/@popperjs/core/lib/dom-utils/isTableElement.es.js +4 -4
  156. package/vendor/@popperjs/core/lib/dom-utils/listScrollParents.es.js +17 -11
  157. package/vendor/@popperjs/core/lib/enums.es.js +43 -20
  158. package/vendor/@popperjs/core/lib/modifiers/applyStyles.es.js +49 -25
  159. package/vendor/@popperjs/core/lib/modifiers/arrow.es.js +61 -26
  160. package/vendor/@popperjs/core/lib/modifiers/computeStyles.es.js +101 -69
  161. package/vendor/@popperjs/core/lib/modifiers/eventListeners.es.js +30 -16
  162. package/vendor/@popperjs/core/lib/modifiers/flip.es.js +99 -60
  163. package/vendor/@popperjs/core/lib/modifiers/hide.es.js +44 -31
  164. package/vendor/@popperjs/core/lib/modifiers/offset.es.js +32 -20
  165. package/vendor/@popperjs/core/lib/modifiers/popperOffsets.es.js +11 -11
  166. package/vendor/@popperjs/core/lib/modifiers/preventOverflow.es.js +91 -40
  167. package/vendor/@popperjs/core/lib/popper.es.js +14 -13
  168. package/vendor/@popperjs/core/lib/utils/computeAutoPlacement.es.js +29 -21
  169. package/vendor/@popperjs/core/lib/utils/computeOffsets.es.js +41 -36
  170. package/vendor/@popperjs/core/lib/utils/debounce.es.js +11 -7
  171. package/vendor/@popperjs/core/lib/utils/detectOverflow.es.js +42 -28
  172. package/vendor/@popperjs/core/lib/utils/expandToHashMap.es.js +5 -4
  173. package/vendor/@popperjs/core/lib/utils/getAltAxis.es.js +3 -3
  174. package/vendor/@popperjs/core/lib/utils/getBasePlacement.es.js +3 -3
  175. package/vendor/@popperjs/core/lib/utils/getFreshSideObject.es.js +2 -2
  176. package/vendor/@popperjs/core/lib/utils/getMainAxisFromPlacement.es.js +3 -3
  177. package/vendor/@popperjs/core/lib/utils/getOppositePlacement.es.js +5 -5
  178. package/vendor/@popperjs/core/lib/utils/getOppositeVariationPlacement.es.js +5 -5
  179. package/vendor/@popperjs/core/lib/utils/getVariation.es.js +3 -3
  180. package/vendor/@popperjs/core/lib/utils/math.es.js +6 -4
  181. package/vendor/@popperjs/core/lib/utils/mergeByName.es.js +11 -10
  182. package/vendor/@popperjs/core/lib/utils/mergePaddingObject.es.js +4 -4
  183. package/vendor/@popperjs/core/lib/utils/orderModifiers.es.js +30 -22
  184. package/vendor/@popperjs/core/lib/utils/rectToClientRect.es.js +7 -7
  185. package/vendor/@popperjs/core/lib/utils/userAgent.es.js +9 -6
  186. package/vendor/@popperjs/core/lib/utils/within.es.js +8 -8
  187. package/vendor/@tiptap/core/dist/index.es.js +3494 -2000
  188. package/vendor/@tiptap/extension-bold/dist/index.es.js +29 -19
  189. package/vendor/@tiptap/extension-bubble-menu/dist/index.es.js +145 -71
  190. package/vendor/@tiptap/extension-bullet-list/dist/index.es.js +32 -19
  191. package/vendor/@tiptap/extension-code/dist/index.es.js +22 -14
  192. package/vendor/@tiptap/extension-document/dist/index.es.js +4 -4
  193. package/vendor/@tiptap/extension-floating-menu/dist/index.es.js +106 -51
  194. package/vendor/@tiptap/extension-heading/dist/index.es.js +38 -22
  195. package/vendor/@tiptap/extension-history/dist/index.es.js +11 -7
  196. package/vendor/@tiptap/extension-image/dist/index.es.js +20 -17
  197. package/vendor/@tiptap/extension-italic/dist/index.es.js +28 -18
  198. package/vendor/@tiptap/extension-link/dist/index.es.js +236 -147
  199. package/vendor/@tiptap/extension-list-item/dist/index.es.js +6 -6
  200. package/vendor/@tiptap/extension-mention/dist/index.es.js +98 -63
  201. package/vendor/@tiptap/extension-ordered-list/dist/index.es.js +38 -25
  202. package/vendor/@tiptap/extension-paragraph/dist/index.es.js +8 -6
  203. package/vendor/@tiptap/extension-placeholder/dist/index.es.js +34 -27
  204. package/vendor/@tiptap/extension-text/dist/index.es.js +3 -3
  205. package/vendor/@tiptap/extension-underline/dist/index.es.js +16 -10
  206. package/vendor/@tiptap/suggestion/dist/index.es.js +174 -90
  207. package/vendor/@tiptap/vue-3/dist/index.es.js +287 -188
  208. package/vendor/@wangs-ui/core/components/p-BU8h34na.es.js +17 -14
  209. package/vendor/@wangs-ui/core/components/p-C5lMEBcj.es.js +69 -55
  210. package/vendor/@wangs-ui/core/components/p-CKYwZoTo.es.js +26 -22
  211. package/vendor/@wangs-ui/core/components/p-CsoK-EWG.es.js +147 -102
  212. package/vendor/@wangs-ui/core/components/p-DPHEi31J.es.js +102 -77
  213. package/vendor/@wangs-ui/core/components/p-DTTCzifR.es.js +1298 -551
  214. package/vendor/@wangs-ui/core/components/p-Duri5p90.es.js +60 -49
  215. package/vendor/@wangs-ui/core/components/wangs-button.es.js +19 -15
  216. package/vendor/@wangs-ui/core/components/wangs-icon.es.js +3 -3
  217. package/vendor/@wangs-ui/core/components/wangs-input-otp.es.js +3 -3
  218. package/vendor/@wangs-ui/core/components/wangs-tab-menu.es.js +3 -3
  219. package/vendor/@wangs-ui/core/dist/esm/index-DCkh3cGv.es.js +116 -102
  220. package/vendor/@wangs-ui/vue/dist/index.es.js +77 -77
  221. package/vendor/base64toblob/base64toblob.es.js +31 -15
  222. package/vendor/highlight.js/es/core.es.js +5 -5
  223. package/vendor/highlight.js/es/languages/javascript.es.js +237 -193
  224. package/vendor/highlight.js/es/languages/json.es.js +18 -15
  225. package/vendor/highlight.js/es/languages/typescript.es.js +288 -228
  226. package/vendor/highlight.js/es/languages/vbscript-html.es.js +2 -2
  227. package/vendor/highlight.js/lib/core.es.js +1144 -666
  228. package/vendor/linkifyjs/dist/linkify.es.es.js +858 -405
  229. package/vendor/lodash/_Symbol.es.js +11 -8
  230. package/vendor/lodash/_baseGetTag.es.js +19 -12
  231. package/vendor/lodash/_baseTrim.es.js +13 -10
  232. package/vendor/lodash/_freeGlobal.es.js +10 -8
  233. package/vendor/lodash/_getRawTag.es.js +28 -15
  234. package/vendor/lodash/_objectToString.es.js +12 -9
  235. package/vendor/lodash/_root.es.js +12 -8
  236. package/vendor/lodash/_trimmedEndIndex.es.js +14 -11
  237. package/vendor/lodash/debounce.es.js +92 -54
  238. package/vendor/lodash/isObject.es.js +11 -9
  239. package/vendor/lodash/isObjectLike.es.js +10 -8
  240. package/vendor/lodash/isSymbol.es.js +14 -11
  241. package/vendor/lodash/now.es.js +12 -9
  242. package/vendor/lodash/throttle.es.js +25 -17
  243. package/vendor/lodash/toNumber.es.js +33 -23
  244. package/vendor/lodash-es/_DataView.es.js +4 -4
  245. package/vendor/lodash-es/_Hash.es.js +17 -16
  246. package/vendor/lodash-es/_ListCache.es.js +17 -16
  247. package/vendor/lodash-es/_Map.es.js +4 -4
  248. package/vendor/lodash-es/_MapCache.es.js +17 -16
  249. package/vendor/lodash-es/_Promise.es.js +4 -4
  250. package/vendor/lodash-es/_Set.es.js +4 -4
  251. package/vendor/lodash-es/_SetCache.es.js +12 -10
  252. package/vendor/lodash-es/_Stack.es.js +15 -15
  253. package/vendor/lodash-es/_Symbol.es.js +3 -3
  254. package/vendor/lodash-es/_Uint8Array.es.js +3 -3
  255. package/vendor/lodash-es/_WeakMap.es.js +4 -4
  256. package/vendor/lodash-es/_arrayEach.es.js +9 -5
  257. package/vendor/lodash-es/_arrayFilter.es.js +9 -6
  258. package/vendor/lodash-es/_arrayLikeKeys.es.js +21 -17
  259. package/vendor/lodash-es/_arrayPush.es.js +7 -5
  260. package/vendor/lodash-es/_arraySome.es.js +9 -6
  261. package/vendor/lodash-es/_assignValue.es.js +10 -7
  262. package/vendor/lodash-es/_assocIndexOf.es.js +9 -6
  263. package/vendor/lodash-es/_baseAssignValue.es.js +13 -9
  264. package/vendor/lodash-es/_baseClone.es.js +67 -49
  265. package/vendor/lodash-es/_baseCreate.es.js +15 -11
  266. package/vendor/lodash-es/_baseGetAllKeys.es.js +6 -6
  267. package/vendor/lodash-es/_baseGetTag.es.js +11 -7
  268. package/vendor/lodash-es/_baseIsArguments.es.js +6 -6
  269. package/vendor/lodash-es/_baseIsEqual.es.js +11 -5
  270. package/vendor/lodash-es/_baseIsEqualDeep.es.js +39 -26
  271. package/vendor/lodash-es/_baseIsMap.es.js +6 -6
  272. package/vendor/lodash-es/_baseIsNative.es.js +18 -12
  273. package/vendor/lodash-es/_baseIsSet.es.js +6 -6
  274. package/vendor/lodash-es/_baseIsTypedArray.es.js +11 -9
  275. package/vendor/lodash-es/_baseKeys.es.js +16 -11
  276. package/vendor/lodash-es/_baseTimes.es.js +7 -5
  277. package/vendor/lodash-es/_baseTrim.es.js +5 -5
  278. package/vendor/lodash-es/_baseUnary.es.js +4 -4
  279. package/vendor/lodash-es/_cacheHas.es.js +3 -3
  280. package/vendor/lodash-es/_cloneArrayBuffer.es.js +6 -5
  281. package/vendor/lodash-es/_cloneBuffer.es.js +11 -6
  282. package/vendor/lodash-es/_cloneDataView.es.js +5 -5
  283. package/vendor/lodash-es/_cloneRegExp.es.js +6 -5
  284. package/vendor/lodash-es/_cloneSymbol.es.js +5 -5
  285. package/vendor/lodash-es/_cloneTypedArray.es.js +5 -5
  286. package/vendor/lodash-es/_coreJsData.es.js +3 -3
  287. package/vendor/lodash-es/_defineProperty.es.js +7 -6
  288. package/vendor/lodash-es/_equalArrays.es.js +38 -28
  289. package/vendor/lodash-es/_equalByTag.es.js +55 -41
  290. package/vendor/lodash-es/_equalObjects.es.js +42 -28
  291. package/vendor/lodash-es/_freeGlobal.es.js +2 -2
  292. package/vendor/lodash-es/_getAllKeys.es.js +6 -6
  293. package/vendor/lodash-es/_getMapData.es.js +5 -5
  294. package/vendor/lodash-es/_getNative.es.js +6 -6
  295. package/vendor/lodash-es/_getPrototype.es.js +3 -3
  296. package/vendor/lodash-es/_getRawTag.es.js +20 -10
  297. package/vendor/lodash-es/_getSymbols.es.js +15 -8
  298. package/vendor/lodash-es/_getTag.es.js +31 -25
  299. package/vendor/lodash-es/_getValue.es.js +3 -3
  300. package/vendor/lodash-es/_hashClear.es.js +5 -4
  301. package/vendor/lodash-es/_hashDelete.es.js +5 -4
  302. package/vendor/lodash-es/_hashGet.es.js +11 -9
  303. package/vendor/lodash-es/_hashHas.es.js +7 -6
  304. package/vendor/lodash-es/_hashSet.es.js +8 -6
  305. package/vendor/lodash-es/_initCloneArray.es.js +10 -5
  306. package/vendor/lodash-es/_initCloneByTag.es.js +39 -38
  307. package/vendor/lodash-es/_initCloneObject.es.js +6 -6
  308. package/vendor/lodash-es/_isIndex.es.js +7 -5
  309. package/vendor/lodash-es/_isKeyable.es.js +4 -4
  310. package/vendor/lodash-es/_isMasked.es.js +7 -7
  311. package/vendor/lodash-es/_isPrototype.es.js +5 -5
  312. package/vendor/lodash-es/_listCacheClear.es.js +4 -3
  313. package/vendor/lodash-es/_listCacheDelete.es.js +17 -9
  314. package/vendor/lodash-es/_listCacheGet.es.js +5 -5
  315. package/vendor/lodash-es/_listCacheHas.es.js +4 -4
  316. package/vendor/lodash-es/_listCacheSet.es.js +11 -5
  317. package/vendor/lodash-es/_mapCacheClear.es.js +10 -9
  318. package/vendor/lodash-es/_mapCacheDelete.es.js +6 -5
  319. package/vendor/lodash-es/_mapCacheGet.es.js +4 -4
  320. package/vendor/lodash-es/_mapCacheHas.es.js +4 -4
  321. package/vendor/lodash-es/_mapCacheSet.es.js +7 -5
  322. package/vendor/lodash-es/_mapToArray.es.js +7 -6
  323. package/vendor/lodash-es/_nativeCreate.es.js +3 -3
  324. package/vendor/lodash-es/_nativeKeys.es.js +3 -3
  325. package/vendor/lodash-es/_nodeUtil.es.js +13 -6
  326. package/vendor/lodash-es/_objectToString.es.js +5 -4
  327. package/vendor/lodash-es/_overArg.es.js +4 -4
  328. package/vendor/lodash-es/_root.es.js +4 -3
  329. package/vendor/lodash-es/_setCacheAdd.es.js +5 -4
  330. package/vendor/lodash-es/_setCacheHas.es.js +3 -3
  331. package/vendor/lodash-es/_setToArray.es.js +7 -6
  332. package/vendor/lodash-es/_stackClear.es.js +5 -4
  333. package/vendor/lodash-es/_stackDelete.es.js +5 -4
  334. package/vendor/lodash-es/_stackGet.es.js +3 -3
  335. package/vendor/lodash-es/_stackHas.es.js +3 -3
  336. package/vendor/lodash-es/_stackSet.es.js +18 -13
  337. package/vendor/lodash-es/_toSource.es.js +9 -8
  338. package/vendor/lodash-es/_trimmedEndIndex.es.js +7 -6
  339. package/vendor/lodash-es/cloneDeep.es.js +5 -5
  340. package/vendor/lodash-es/debounce.es.js +84 -49
  341. package/vendor/lodash-es/eq.es.js +3 -3
  342. package/vendor/lodash-es/isArguments.es.js +9 -6
  343. package/vendor/lodash-es/isArray.es.js +2 -2
  344. package/vendor/lodash-es/isArrayLike.es.js +5 -5
  345. package/vendor/lodash-es/isBuffer.es.js +9 -4
  346. package/vendor/lodash-es/isEqual.es.js +4 -4
  347. package/vendor/lodash-es/isFunction.es.js +10 -9
  348. package/vendor/lodash-es/isLength.es.js +4 -4
  349. package/vendor/lodash-es/isMap.es.js +6 -5
  350. package/vendor/lodash-es/isObject.es.js +4 -4
  351. package/vendor/lodash-es/isObjectLike.es.js +3 -3
  352. package/vendor/lodash-es/isSet.es.js +6 -5
  353. package/vendor/lodash-es/isSymbol.es.js +6 -6
  354. package/vendor/lodash-es/isTypedArray.es.js +6 -5
  355. package/vendor/lodash-es/keys.es.js +6 -6
  356. package/vendor/lodash-es/now.es.js +4 -4
  357. package/vendor/lodash-es/stubArray.es.js +2 -2
  358. package/vendor/lodash-es/stubFalse.es.js +3 -3
  359. package/vendor/lodash-es/toNumber.es.js +25 -18
  360. package/vendor/lodash-es/toString.es.js +2 -2
  361. package/vendor/lodash-es/uniqueId.es.js +6 -6
  362. package/vendor/orderedmap/dist/index.es.js +65 -49
  363. package/vendor/primevue/api/api.esm.es.js +214 -121
  364. package/vendor/primevue/avatar/avatar.esm.es.js +44 -41
  365. package/vendor/primevue/avatar/style/avatarstyle.esm.es.js +12 -11
  366. package/vendor/primevue/avatargroup/avatargroup.esm.es.js +17 -16
  367. package/vendor/primevue/avatargroup/style/avatargroupstyle.esm.es.js +6 -5
  368. package/vendor/primevue/badge/badge.esm.es.js +21 -20
  369. package/vendor/primevue/badge/style/badgestyle.esm.es.js +19 -18
  370. package/vendor/primevue/base/style/basestyle.esm.es.js +88 -99
  371. package/vendor/primevue/basecomponent/basecomponent.esm.es.js +327 -261
  372. package/vendor/primevue/basedirective/basedirective.esm.es.js +257 -186
  373. package/vendor/primevue/baseicon/baseicon.esm.es.js +55 -49
  374. package/vendor/primevue/baseicon/style/baseiconstyle.esm.es.js +5 -35
  375. package/vendor/primevue/button/button.esm.es.js +76 -72
  376. package/vendor/primevue/button/style/buttonstyle.esm.es.js +46 -39
  377. package/vendor/primevue/card/card.esm.es.js +30 -29
  378. package/vendor/primevue/card/style/cardstyle.esm.es.js +6 -5
  379. package/vendor/primevue/checkbox/checkbox.esm.es.js +109 -101
  380. package/vendor/primevue/checkbox/style/checkboxstyle.esm.es.js +12 -11
  381. package/vendor/primevue/config/config.esm.es.js +76 -58
  382. package/vendor/primevue/dialog/dialog.esm.es.js +421 -281
  383. package/vendor/primevue/dialog/style/dialogstyle.esm.es.js +26 -22
  384. package/vendor/primevue/dropdown/dropdown.esm.es.js +956 -742
  385. package/vendor/primevue/dropdown/style/dropdownstyle.esm.es.js +33 -31
  386. package/vendor/primevue/fileupload/fileupload.esm.es.js +559 -450
  387. package/vendor/primevue/fileupload/style/fileuploadstyle.esm.es.js +14 -13
  388. package/vendor/primevue/focustrap/focustrap.esm.es.js +128 -90
  389. package/vendor/primevue/focustrap/style/focustrapstyle.esm.es.js +2 -2
  390. package/vendor/primevue/icons/angledoubleleft/index.esm.es.js +13 -11
  391. package/vendor/primevue/icons/angledoubleright/index.esm.es.js +13 -11
  392. package/vendor/primevue/icons/angledown/index.esm.es.js +13 -11
  393. package/vendor/primevue/icons/angleleft/index.esm.es.js +13 -11
  394. package/vendor/primevue/icons/angleright/index.esm.es.js +13 -11
  395. package/vendor/primevue/icons/angleup/index.esm.es.js +13 -11
  396. package/vendor/primevue/icons/blank/index.esm.es.js +13 -11
  397. package/vendor/primevue/icons/check/index.esm.es.js +13 -11
  398. package/vendor/primevue/icons/chevrondown/index.esm.es.js +13 -11
  399. package/vendor/primevue/icons/exclamationtriangle/index.esm.es.js +17 -13
  400. package/vendor/primevue/icons/eye/index.esm.es.js +13 -11
  401. package/vendor/primevue/icons/eyeslash/index.esm.es.js +13 -11
  402. package/vendor/primevue/icons/infocircle/index.esm.es.js +13 -11
  403. package/vendor/primevue/icons/plus/index.esm.es.js +13 -11
  404. package/vendor/primevue/icons/refresh/index.esm.es.js +13 -11
  405. package/vendor/primevue/icons/search/index.esm.es.js +13 -11
  406. package/vendor/primevue/icons/searchminus/index.esm.es.js +13 -11
  407. package/vendor/primevue/icons/searchplus/index.esm.es.js +13 -11
  408. package/vendor/primevue/icons/spinner/index.esm.es.js +13 -11
  409. package/vendor/primevue/icons/times/index.esm.es.js +13 -11
  410. package/vendor/primevue/icons/timescircle/index.esm.es.js +13 -11
  411. package/vendor/primevue/icons/undo/index.esm.es.js +13 -11
  412. package/vendor/primevue/icons/upload/index.esm.es.js +13 -11
  413. package/vendor/primevue/icons/windowmaximize/index.esm.es.js +13 -11
  414. package/vendor/primevue/icons/windowminimize/index.esm.es.js +13 -11
  415. package/vendor/primevue/image/image.esm.es.js +280 -235
  416. package/vendor/primevue/image/style/imagestyle.esm.es.js +18 -17
  417. package/vendor/primevue/inputgroup/inputgroup.esm.es.js +17 -16
  418. package/vendor/primevue/inputgroup/style/inputgroupstyle.esm.es.js +6 -5
  419. package/vendor/primevue/inputgroupaddon/inputgroupaddon.esm.es.js +17 -16
  420. package/vendor/primevue/inputgroupaddon/style/inputgroupaddonstyle.esm.es.js +6 -5
  421. package/vendor/primevue/inputnumber/inputnumber.esm.es.js +834 -566
  422. package/vendor/primevue/inputnumber/style/inputnumberstyle.esm.es.js +23 -22
  423. package/vendor/primevue/inputtext/inputtext.esm.es.js +32 -30
  424. package/vendor/primevue/inputtext/style/inputtextstyle.esm.es.js +13 -12
  425. package/vendor/primevue/menu/menu.esm.es.js +402 -304
  426. package/vendor/primevue/menu/style/menustyle.esm.es.js +14 -13
  427. package/vendor/primevue/message/message.esm.es.js +126 -112
  428. package/vendor/primevue/message/style/messagestyle.esm.es.js +9 -8
  429. package/vendor/primevue/multiselect/multiselect.esm.es.js +1083 -835
  430. package/vendor/primevue/multiselect/style/multiselectstyle.esm.es.js +38 -36
  431. package/vendor/primevue/overlayeventbus/overlayeventbus.esm.es.js +3 -3
  432. package/vendor/primevue/overlaypanel/overlaypanel.esm.es.js +275 -169
  433. package/vendor/primevue/overlaypanel/style/overlaypanelstyle.esm.es.js +9 -8
  434. package/vendor/primevue/paginator/paginator.esm.es.js +513 -469
  435. package/vendor/primevue/paginator/style/paginatorstyle.esm.es.js +50 -43
  436. package/vendor/primevue/password/password.esm.es.js +306 -233
  437. package/vendor/primevue/password/style/passwordstyle.esm.es.js +26 -24
  438. package/vendor/primevue/portal/portal.esm.es.js +17 -17
  439. package/vendor/primevue/progressbar/progressbar.esm.es.js +37 -35
  440. package/vendor/primevue/progressbar/style/progressbarstyle.esm.es.js +10 -9
  441. package/vendor/primevue/ripple/ripple.esm.es.js +90 -62
  442. package/vendor/primevue/ripple/style/ripplestyle.esm.es.js +6 -5
  443. package/vendor/primevue/selectbutton/selectbutton.esm.es.js +213 -167
  444. package/vendor/primevue/selectbutton/style/selectbuttonstyle.esm.es.js +14 -13
  445. package/vendor/primevue/skeleton/skeleton.esm.es.js +28 -26
  446. package/vendor/primevue/skeleton/style/skeletonstyle.esm.es.js +13 -11
  447. package/vendor/primevue/textarea/style/textareastyle.esm.es.js +12 -11
  448. package/vendor/primevue/textarea/textarea.esm.es.js +49 -33
  449. package/vendor/primevue/timeline/style/timelinestyle.esm.es.js +9 -8
  450. package/vendor/primevue/timeline/timeline.esm.es.js +53 -52
  451. package/vendor/primevue/toast/style/toaststyle.esm.es.js +54 -46
  452. package/vendor/primevue/toast/toast.esm.es.js +309 -260
  453. package/vendor/primevue/toasteventbus/toasteventbus.esm.es.js +3 -3
  454. package/vendor/primevue/toastservice/toastservice.esm.es.js +16 -15
  455. package/vendor/primevue/tooltip/style/tooltipstyle.esm.es.js +6 -5
  456. package/vendor/primevue/tooltip/tooltip.esm.es.js +383 -186
  457. package/vendor/primevue/usestyle/usestyle.esm.es.js +94 -64
  458. package/vendor/primevue/usetoast/usetoast.esm.es.js +9 -8
  459. package/vendor/primevue/utils/utils.esm.es.js +1078 -772
  460. package/vendor/primevue/virtualscroller/style/virtualscrollerstyle.esm.es.js +5 -67
  461. package/vendor/primevue/virtualscroller/virtualscroller.esm.es.js +655 -428
  462. package/vendor/prosemirror-commands/dist/index.es.js +454 -316
  463. package/vendor/prosemirror-history/dist/index.es.js +286 -178
  464. package/vendor/prosemirror-keymap/dist/index.es.js +68 -48
  465. package/vendor/prosemirror-model/dist/index.es.js +1905 -1436
  466. package/vendor/prosemirror-schema-list/dist/index.es.js +115 -73
  467. package/vendor/prosemirror-state/dist/index.es.js +467 -353
  468. package/vendor/prosemirror-transform/dist/index.es.js +1146 -829
  469. package/vendor/prosemirror-view/dist/index.es.js +4127 -2719
  470. package/vendor/rope-sequence/dist/index.es.js +165 -82
  471. package/vendor/simplebar-core/dist/index.es.js +670 -242
  472. package/vendor/simplebar-vue/dist/simplebar-vue.esm.es.js +73 -60
  473. package/vendor/single-spa/lib/es2015/esm/single-spa.min.es.js +511 -510
  474. package/vendor/tippy.js/dist/tippy.esm.es.js +971 -525
  475. package/vendor/vee-validate/dist/vee-validate.esm.es.js +1830 -1097
  476. package/vendor/vue-advanced-cropper/dist/index.esm-bundler.es.js +740 -738
  477. package/vendor/w3c-keyname/index.es.js +25 -13
  478. package/wangsvue.es.js +167 -208
  479. package/wangsvue.esm.browser.js +49417 -48026
  480. package/wangsvue.system.js +67600 -234
  481. package/api/index.es.js +0 -149
  482. package/apiitem/index.es.js +0 -611
  483. package/assignmember/index.es.js +0 -434
  484. package/attachment/index.es.js +0 -118
  485. package/attachmentchangelog/index.es.js +0 -79
  486. package/attachmentitem/index.es.js +0 -231
  487. package/attachmentthumbnail/index.es.js +0 -83
  488. package/changelog/index.d.ts +0 -164
  489. package/changelog/index.es.js +0 -85
  490. package/changelogfilter/index.es.js +0 -113
  491. package/changelogpage/index.d.ts +0 -184
  492. package/changelogpage/index.es.js +0 -176
  493. package/checklist/index.es.js +0 -571
  494. package/checklistchangelog/index.es.js +0 -85
  495. package/comment/index.d.ts +0 -187
  496. package/comment/index.es.js +0 -267
  497. package/commentblock/index.es.js +0 -337
  498. package/confirmdeploy/index.es.js +0 -64
  499. package/dependencycol/index.es.js +0 -32
  500. package/description/index.es.js +0 -135
  501. package/descriptiontab/index.es.js +0 -30
  502. package/detailmember/index.d.ts +0 -77
  503. package/detailmember/index.es.js +0 -32
  504. package/detailmemberadmin/index.es.js +0 -210
  505. package/detailmemberleader/index.es.js +0 -164
  506. package/detailmemberlog/index.es.js +0 -117
  507. package/detailsprint/index.d.ts +0 -86
  508. package/detailsprint/index.es.js +0 -414
  509. package/dialogaddattachment/index.es.js +0 -273
  510. package/dialogaddchecklist/index.es.js +0 -120
  511. package/dialogaddeditapi/index.es.js +0 -87
  512. package/dialogaddpbi/index.es.js +0 -197
  513. package/dialogadjustmenttask/index.es.js +0 -484
  514. package/dialogadjustmenttaskheader/index.es.js +0 -193
  515. package/dialogapichangelog/index.es.js +0 -83
  516. package/dialogassignmember/index.es.js +0 -171
  517. package/dialogconfirmapproval/index.es.js +0 -54
  518. package/dialogconfirmchecklist/index.es.js +0 -189
  519. package/dialogconfirmdeletetask/index.es.js +0 -70
  520. package/dialogconfirmdeletetaskpermanently/index.es.js +0 -50
  521. package/dialogconfirmedit/index.es.js +0 -50
  522. package/dialogconfirmfinishtask/index.es.js +0 -50
  523. package/dialogconfirmrestoretask/index.es.js +0 -46
  524. package/dialogconfirmsprint/index.es.js +0 -42
  525. package/dialogcopyapi/index.es.js +0 -130
  526. package/dialogcustomdependency/index.es.js +0 -55
  527. package/dialogdetailchecklisttemplate/index.es.js +0 -214
  528. package/dialogdetailcomponent/index.es.js +0 -121
  529. package/dialogdetailpbi/index.es.js +0 -192
  530. package/dialogfinishreview/index.es.js +0 -126
  531. package/dialogimprovementtask/index.es.js +0 -191
  532. package/dialogmemberadmin/index.es.js +0 -93
  533. package/dialogpreparepbi/index.es.js +0 -93
  534. package/dialogpriorityvalue/index.es.js +0 -85
  535. package/dialogreportbug/index.es.js +0 -207
  536. package/dialogreviewleader/index.es.js +0 -280
  537. package/dialogsavechecklisttemplate/index.es.js +0 -127
  538. package/dialogselectproject/index.es.js +0 -69
  539. package/dialogsetduration/index.es.js +0 -109
  540. package/dialogsettasklink/index.es.js +0 -153
  541. package/dialogtestapi/index.es.js +0 -389
  542. package/eventlogtab/index.es.js +0 -50
  543. package/infotasktab/index.es.js +0 -186
  544. package/inputadditional/index.es.js +0 -62
  545. package/inputinitialname/index.d.ts +0 -118
  546. package/inputinitialname/index.es.js +0 -95
  547. package/inputrepositoryname/index.d.ts +0 -86
  548. package/inputrepositoryname/index.es.js +0 -41
  549. package/isrequiredtext/index.es.js +0 -16
  550. package/legend/index.es.js +0 -727
  551. package/legendlist/index.es.js +0 -33
  552. package/loading-page-BrQattYE.js +0 -1
  553. package/loading-page-CgfbWppy.js +0 -1
  554. package/loading-page-CoC9UhfC.js +0 -4
  555. package/loading-page-CoXtqoc9.js +0 -4
  556. package/loading-page-DbLuqCHa.js +0 -1
  557. package/loading-page-f8D03l3G.js +0 -4
  558. package/loading-plane-CgfbWppy.js +0 -1
  559. package/loading-plane-CoXtqoc9.js +0 -4
  560. package/loading-table-Bdr9ZhtP.js +0 -1
  561. package/loading-table-ByUoWqUo.js +0 -4
  562. package/loading-table-BygEMzFM.js +0 -4
  563. package/loading-table-BzrSQlA0.js +0 -1
  564. package/loading-table-D9bw9OcI.js +0 -4
  565. package/loading-table-chOgXi94.js +0 -1
  566. package/no-data-CTKux8RI.js +0 -4
  567. package/no-data-Cgze_Rvp.js +0 -1
  568. package/no-data-DLHO1L_u.js +0 -4
  569. package/no-data-Dep79CBh.js +0 -1
  570. package/no-data-g0dJCy2p.js +0 -4
  571. package/no-data-y1X5WtcQ.js +0 -1
  572. package/notificationitem/index.d.ts +0 -107
  573. package/notificationitem/index.es.js +0 -333
  574. package/reviewitem/index.es.js +0 -65
  575. package/reviewtab/index.es.js +0 -44
  576. package/services/calendar.service.es.js +0 -32
  577. package/sonarqubesummary/index.es.js +0 -234
  578. package/sprintsummary/index.es.js +0 -73
  579. package/summaryaccordion/index.d.ts +0 -121
  580. package/summaryaccordion/index.es.js +0 -365
  581. package/taskdependency/index.es.js +0 -686
  582. package/taskdetail/index.d.ts +0 -82
  583. package/taskdetail/index.es.js +0 -491
  584. package/taskdetailpbi/index.d.ts +0 -35
  585. package/taskdetailpbi/index.es.js +0 -172
  586. package/taskdetailunassignedpbi/index.es.js +0 -261
  587. package/tasklink/index.es.js +0 -257
  588. package/tasklinkchangelog/index.es.js +0 -93
  589. package/tasklist/index.es.js +0 -92
  590. package/taskmore/index.es.js +0 -52
  591. package/taskstatusbadge/index.es.js +0 -18
  592. package/tasktable/index.d.ts +0 -87
  593. package/tasktable/index.es.js +0 -832
  594. package/ticket/index.es.js +0 -151
  595. package/tooltipspan/index.es.js +0 -30
  596. package/utils/updateSprintStatus.util.es.js +0 -17
  597. package/valueformdatainput/index.es.js +0 -70
  598. package/workcalendar/index.es.js +0 -351
@@ -1,177 +1,183 @@
1
- import { s as Q } from "../icons/spinner/index.esm.es.js";
2
- import { D as p } from "../utils/utils.esm.es.js";
3
- import { s as U } from "../basecomponent/basecomponent.esm.es.js";
4
- import { V as K } from "./style/virtualscrollerstyle.esm.es.js";
5
- import { resolveComponent as X, createElementBlock as R, openBlock as W, mergeProps as M, renderSlot as A, createCommentVNode as k, createElementVNode as Y, Fragment as D, renderList as q, createVNode as Z } from "vue";
6
- var $ = {
1
+ import { s as script$2 } from "../icons/spinner/index.esm.es.js";
2
+ import { D as DomHandler } from "../utils/utils.esm.es.js";
3
+ import { s as script$3 } from "../basecomponent/basecomponent.esm.es.js";
4
+ import { V as VirtualScrollerStyle } from "./style/virtualscrollerstyle.esm.es.js";
5
+ import { resolveComponent, createElementBlock, openBlock, mergeProps, renderSlot, createCommentVNode, createElementVNode, Fragment, renderList, createVNode } from "vue";
6
+ var script$1 = {
7
7
  name: "BaseVirtualScroller",
8
- extends: U,
8
+ "extends": script$3,
9
9
  props: {
10
10
  id: {
11
11
  type: String,
12
- default: null
12
+ "default": null
13
13
  },
14
14
  style: null,
15
- class: null,
15
+ "class": null,
16
16
  items: {
17
17
  type: Array,
18
- default: null
18
+ "default": null
19
19
  },
20
20
  itemSize: {
21
21
  type: [Number, Array],
22
- default: 0
22
+ "default": 0
23
23
  },
24
24
  scrollHeight: null,
25
25
  scrollWidth: null,
26
26
  orientation: {
27
27
  type: String,
28
- default: "vertical"
28
+ "default": "vertical"
29
29
  },
30
30
  numToleratedItems: {
31
31
  type: Number,
32
- default: null
32
+ "default": null
33
33
  },
34
34
  delay: {
35
35
  type: Number,
36
- default: 0
36
+ "default": 0
37
37
  },
38
38
  resizeDelay: {
39
39
  type: Number,
40
- default: 10
40
+ "default": 10
41
41
  },
42
42
  lazy: {
43
43
  type: Boolean,
44
- default: !1
44
+ "default": false
45
45
  },
46
46
  disabled: {
47
47
  type: Boolean,
48
- default: !1
48
+ "default": false
49
49
  },
50
50
  loaderDisabled: {
51
51
  type: Boolean,
52
- default: !1
52
+ "default": false
53
53
  },
54
54
  columns: {
55
55
  type: Array,
56
- default: null
56
+ "default": null
57
57
  },
58
58
  loading: {
59
59
  type: Boolean,
60
- default: !1
60
+ "default": false
61
61
  },
62
62
  showSpacer: {
63
63
  type: Boolean,
64
- default: !0
64
+ "default": true
65
65
  },
66
66
  showLoader: {
67
67
  type: Boolean,
68
- default: !1
68
+ "default": false
69
69
  },
70
70
  tabindex: {
71
71
  type: Number,
72
- default: 0
72
+ "default": 0
73
73
  },
74
74
  inline: {
75
75
  type: Boolean,
76
- default: !1
76
+ "default": false
77
77
  },
78
78
  step: {
79
79
  type: Number,
80
- default: 0
80
+ "default": 0
81
81
  },
82
82
  appendOnly: {
83
83
  type: Boolean,
84
- default: !1
84
+ "default": false
85
85
  },
86
86
  autoSize: {
87
87
  type: Boolean,
88
- default: !1
88
+ "default": false
89
89
  }
90
90
  },
91
- style: K,
92
- provide: function() {
91
+ style: VirtualScrollerStyle,
92
+ provide: function provide() {
93
93
  return {
94
94
  $parentInstance: this
95
95
  };
96
96
  },
97
- beforeMount: function() {
98
- var t;
99
- K.loadStyle({
100
- nonce: (t = this.$primevueConfig) === null || t === void 0 || (t = t.csp) === null || t === void 0 ? void 0 : t.nonce
97
+ beforeMount: function beforeMount() {
98
+ var _this$$primevueConfig;
99
+ VirtualScrollerStyle.loadStyle({
100
+ nonce: (_this$$primevueConfig = this.$primevueConfig) === null || _this$$primevueConfig === void 0 || (_this$$primevueConfig = _this$$primevueConfig.csp) === null || _this$$primevueConfig === void 0 ? void 0 : _this$$primevueConfig.nonce
101
101
  });
102
102
  }
103
103
  };
104
- function E(e) {
104
+ function _typeof(o) {
105
105
  "@babel/helpers - typeof";
106
- return E = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
107
- return typeof t;
108
- } : function(t) {
109
- return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
110
- }, E(e);
106
+ return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o2) {
107
+ return typeof o2;
108
+ } : function(o2) {
109
+ return o2 && "function" == typeof Symbol && o2.constructor === Symbol && o2 !== Symbol.prototype ? "symbol" : typeof o2;
110
+ }, _typeof(o);
111
111
  }
112
- function G(e, t) {
113
- var i = Object.keys(e);
112
+ function ownKeys(e, r) {
113
+ var t = Object.keys(e);
114
114
  if (Object.getOwnPropertySymbols) {
115
- var n = Object.getOwnPropertySymbols(e);
116
- t && (n = n.filter(function(r) {
117
- return Object.getOwnPropertyDescriptor(e, r).enumerable;
118
- })), i.push.apply(i, n);
115
+ var o = Object.getOwnPropertySymbols(e);
116
+ r && (o = o.filter(function(r2) {
117
+ return Object.getOwnPropertyDescriptor(e, r2).enumerable;
118
+ })), t.push.apply(t, o);
119
119
  }
120
- return i;
120
+ return t;
121
121
  }
122
- function j(e) {
123
- for (var t = 1; t < arguments.length; t++) {
124
- var i = arguments[t] != null ? arguments[t] : {};
125
- t % 2 ? G(Object(i), !0).forEach(function(n) {
126
- J(e, n, i[n]);
127
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(i)) : G(Object(i)).forEach(function(n) {
128
- Object.defineProperty(e, n, Object.getOwnPropertyDescriptor(i, n));
122
+ function _objectSpread(e) {
123
+ for (var r = 1; r < arguments.length; r++) {
124
+ var t = null != arguments[r] ? arguments[r] : {};
125
+ r % 2 ? ownKeys(Object(t), true).forEach(function(r2) {
126
+ _defineProperty(e, r2, t[r2]);
127
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function(r2) {
128
+ Object.defineProperty(e, r2, Object.getOwnPropertyDescriptor(t, r2));
129
129
  });
130
130
  }
131
131
  return e;
132
132
  }
133
- function J(e, t, i) {
134
- return t = x(t), t in e ? Object.defineProperty(e, t, { value: i, enumerable: !0, configurable: !0, writable: !0 }) : e[t] = i, e;
133
+ function _defineProperty(obj, key, value) {
134
+ key = _toPropertyKey(key);
135
+ if (key in obj) {
136
+ Object.defineProperty(obj, key, { value, enumerable: true, configurable: true, writable: true });
137
+ } else {
138
+ obj[key] = value;
139
+ }
140
+ return obj;
135
141
  }
136
- function x(e) {
137
- var t = tt(e, "string");
138
- return E(t) == "symbol" ? t : String(t);
142
+ function _toPropertyKey(t) {
143
+ var i = _toPrimitive(t, "string");
144
+ return "symbol" == _typeof(i) ? i : String(i);
139
145
  }
140
- function tt(e, t) {
141
- if (E(e) != "object" || !e) return e;
142
- var i = e[Symbol.toPrimitive];
143
- if (i !== void 0) {
144
- var n = i.call(e, t);
145
- if (E(n) != "object") return n;
146
+ function _toPrimitive(t, r) {
147
+ if ("object" != _typeof(t) || !t) return t;
148
+ var e = t[Symbol.toPrimitive];
149
+ if (void 0 !== e) {
150
+ var i = e.call(t, r);
151
+ if ("object" != _typeof(i)) return i;
146
152
  throw new TypeError("@@toPrimitive must return a primitive value.");
147
153
  }
148
- return (t === "string" ? String : Number)(e);
154
+ return ("string" === r ? String : Number)(t);
149
155
  }
150
- var et = {
156
+ var script = {
151
157
  name: "VirtualScroller",
152
- extends: $,
153
- inheritAttrs: !1,
158
+ "extends": script$1,
159
+ inheritAttrs: false,
154
160
  emits: ["update:numToleratedItems", "scroll", "scroll-index-change", "lazy-load"],
155
- data: function() {
156
- var t = this.isBoth();
161
+ data: function data() {
162
+ var both = this.isBoth();
157
163
  return {
158
- first: t ? {
164
+ first: both ? {
159
165
  rows: 0,
160
166
  cols: 0
161
167
  } : 0,
162
- last: t ? {
168
+ last: both ? {
163
169
  rows: 0,
164
170
  cols: 0
165
171
  } : 0,
166
- page: t ? {
172
+ page: both ? {
167
173
  rows: 0,
168
174
  cols: 0
169
175
  } : 0,
170
- numItemsInViewport: t ? {
176
+ numItemsInViewport: both ? {
171
177
  rows: 0,
172
178
  cols: 0
173
179
  } : 0,
174
- lastScrollPos: t ? {
180
+ lastScrollPos: both ? {
175
181
  top: 0,
176
182
  left: 0
177
183
  } : 0,
@@ -191,222 +197,340 @@ var et = {
191
197
  defaultHeight: 0,
192
198
  defaultContentWidth: 0,
193
199
  defaultContentHeight: 0,
194
- isRangeChanged: !1,
200
+ isRangeChanged: false,
195
201
  lazyLoadState: {},
196
202
  resizeListener: null,
197
- initialized: !1,
203
+ initialized: false,
198
204
  watch: {
199
- numToleratedItems: function(t) {
200
- this.d_numToleratedItems = t;
205
+ numToleratedItems: function numToleratedItems(newValue) {
206
+ this.d_numToleratedItems = newValue;
201
207
  },
202
- loading: function(t, i) {
203
- this.lazy && t !== i && t !== this.d_loading && (this.d_loading = t);
208
+ loading: function loading(newValue, oldValue) {
209
+ if (this.lazy && newValue !== oldValue && newValue !== this.d_loading) {
210
+ this.d_loading = newValue;
211
+ }
204
212
  },
205
- items: function(t, i) {
206
- (!i || i.length !== (t || []).length) && (this.init(), this.calculateAutoSize());
213
+ items: function items(newValue, oldValue) {
214
+ if (!oldValue || oldValue.length !== (newValue || []).length) {
215
+ this.init();
216
+ this.calculateAutoSize();
217
+ }
207
218
  },
208
- itemSize: function() {
209
- this.init(), this.calculateAutoSize();
219
+ itemSize: function itemSize() {
220
+ this.init();
221
+ this.calculateAutoSize();
210
222
  },
211
- orientation: function() {
223
+ orientation: function orientation() {
212
224
  this.lastScrollPos = this.isBoth() ? {
213
225
  top: 0,
214
226
  left: 0
215
227
  } : 0;
216
228
  },
217
- scrollHeight: function() {
218
- this.init(), this.calculateAutoSize();
229
+ scrollHeight: function scrollHeight() {
230
+ this.init();
231
+ this.calculateAutoSize();
219
232
  },
220
- scrollWidth: function() {
221
- this.init(), this.calculateAutoSize();
233
+ scrollWidth: function scrollWidth() {
234
+ this.init();
235
+ this.calculateAutoSize();
222
236
  }
223
237
  },
224
- mounted: function() {
225
- this.viewInit(), this.lastScrollPos = this.isBoth() ? {
238
+ mounted: function mounted() {
239
+ this.viewInit();
240
+ this.lastScrollPos = this.isBoth() ? {
226
241
  top: 0,
227
242
  left: 0
228
- } : 0, this.lazyLoadState = this.lazyLoadState || {};
243
+ } : 0;
244
+ this.lazyLoadState = this.lazyLoadState || {};
229
245
  },
230
- updated: function() {
246
+ updated: function updated() {
231
247
  !this.initialized && this.viewInit();
232
248
  },
233
- unmounted: function() {
234
- this.unbindResizeListener(), this.initialized = !1;
249
+ unmounted: function unmounted() {
250
+ this.unbindResizeListener();
251
+ this.initialized = false;
235
252
  },
236
253
  methods: {
237
- viewInit: function() {
238
- p.isVisible(this.element) && (this.setContentEl(this.content), this.init(), this.calculateAutoSize(), this.bindResizeListener(), this.defaultWidth = p.getWidth(this.element), this.defaultHeight = p.getHeight(this.element), this.defaultContentWidth = p.getWidth(this.content), this.defaultContentHeight = p.getHeight(this.content), this.initialized = !0);
254
+ viewInit: function viewInit() {
255
+ if (DomHandler.isVisible(this.element)) {
256
+ this.setContentEl(this.content);
257
+ this.init();
258
+ this.calculateAutoSize();
259
+ this.bindResizeListener();
260
+ this.defaultWidth = DomHandler.getWidth(this.element);
261
+ this.defaultHeight = DomHandler.getHeight(this.element);
262
+ this.defaultContentWidth = DomHandler.getWidth(this.content);
263
+ this.defaultContentHeight = DomHandler.getHeight(this.content);
264
+ this.initialized = true;
265
+ }
239
266
  },
240
- init: function() {
241
- this.disabled || (this.setSize(), this.calculateOptions(), this.setSpacerSize());
267
+ init: function init() {
268
+ if (!this.disabled) {
269
+ this.setSize();
270
+ this.calculateOptions();
271
+ this.setSpacerSize();
272
+ }
242
273
  },
243
- isVertical: function() {
274
+ isVertical: function isVertical() {
244
275
  return this.orientation === "vertical";
245
276
  },
246
- isHorizontal: function() {
277
+ isHorizontal: function isHorizontal() {
247
278
  return this.orientation === "horizontal";
248
279
  },
249
- isBoth: function() {
280
+ isBoth: function isBoth() {
250
281
  return this.orientation === "both";
251
282
  },
252
- scrollTo: function(t) {
253
- this.element && this.element.scrollTo(t);
254
- },
255
- scrollToIndex: function(t) {
256
- var i = this, n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "auto", r = this.isBoth(), s = this.isHorizontal(), l = r ? t.every(function(P) {
257
- return P > -1;
258
- }) : t > -1;
259
- if (l) {
260
- var a = this.first, h = this.element, u = h.scrollTop, o = u === void 0 ? 0 : u, c = h.scrollLeft, m = c === void 0 ? 0 : c, y = this.calculateNumItems(), g = y.numToleratedItems, v = this.getContentPosition(), S = this.itemSize, b = function() {
261
- var I = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0, H = arguments.length > 1 ? arguments[1] : void 0;
262
- return I <= H ? 0 : I;
263
- }, w = function(I, H, T) {
264
- return I * H + T;
265
- }, L = function() {
266
- var I = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0, H = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0;
267
- return i.scrollTo({
268
- left: I,
269
- top: H,
270
- behavior: n
283
+ scrollTo: function scrollTo(options) {
284
+ this.element && this.element.scrollTo(options);
285
+ },
286
+ scrollToIndex: function scrollToIndex(index) {
287
+ var _this = this;
288
+ var behavior = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : "auto";
289
+ var both = this.isBoth();
290
+ var horizontal = this.isHorizontal();
291
+ var valid = both ? index.every(function(i) {
292
+ return i > -1;
293
+ }) : index > -1;
294
+ if (valid) {
295
+ var first = this.first;
296
+ var _this$element = this.element, _this$element$scrollT = _this$element.scrollTop, scrollTop = _this$element$scrollT === void 0 ? 0 : _this$element$scrollT, _this$element$scrollL = _this$element.scrollLeft, scrollLeft = _this$element$scrollL === void 0 ? 0 : _this$element$scrollL;
297
+ var _this$calculateNumIte = this.calculateNumItems(), numToleratedItems2 = _this$calculateNumIte.numToleratedItems;
298
+ var contentPos = this.getContentPosition();
299
+ var itemSize2 = this.itemSize;
300
+ var calculateFirst = function calculateFirst2() {
301
+ var _index = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0;
302
+ var _numT = arguments.length > 1 ? arguments[1] : void 0;
303
+ return _index <= _numT ? 0 : _index;
304
+ };
305
+ var calculateCoord = function calculateCoord2(_first, _size, _cpos) {
306
+ return _first * _size + _cpos;
307
+ };
308
+ var scrollTo2 = function scrollTo3() {
309
+ var left = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0;
310
+ var top = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0;
311
+ return _this.scrollTo({
312
+ left,
313
+ top,
314
+ behavior
271
315
  });
272
- }, d = r ? {
316
+ };
317
+ var newFirst = both ? {
273
318
  rows: 0,
274
319
  cols: 0
275
- } : 0, V = !1, B = !1;
276
- r ? (d = {
277
- rows: b(t[0], g[0]),
278
- cols: b(t[1], g[1])
279
- }, L(w(d.cols, S[1], v.left), w(d.rows, S[0], v.top)), B = this.lastScrollPos.top !== o || this.lastScrollPos.left !== m, V = d.rows !== a.rows || d.cols !== a.cols) : (d = b(t, g), s ? L(w(d, S, v.left), o) : L(m, w(d, S, v.top)), B = this.lastScrollPos !== (s ? m : o), V = d !== a), this.isRangeChanged = V, B && (this.first = d);
320
+ } : 0;
321
+ var isRangeChanged = false, isScrollChanged = false;
322
+ if (both) {
323
+ newFirst = {
324
+ rows: calculateFirst(index[0], numToleratedItems2[0]),
325
+ cols: calculateFirst(index[1], numToleratedItems2[1])
326
+ };
327
+ scrollTo2(calculateCoord(newFirst.cols, itemSize2[1], contentPos.left), calculateCoord(newFirst.rows, itemSize2[0], contentPos.top));
328
+ isScrollChanged = this.lastScrollPos.top !== scrollTop || this.lastScrollPos.left !== scrollLeft;
329
+ isRangeChanged = newFirst.rows !== first.rows || newFirst.cols !== first.cols;
330
+ } else {
331
+ newFirst = calculateFirst(index, numToleratedItems2);
332
+ horizontal ? scrollTo2(calculateCoord(newFirst, itemSize2, contentPos.left), scrollTop) : scrollTo2(scrollLeft, calculateCoord(newFirst, itemSize2, contentPos.top));
333
+ isScrollChanged = this.lastScrollPos !== (horizontal ? scrollLeft : scrollTop);
334
+ isRangeChanged = newFirst !== first;
335
+ }
336
+ this.isRangeChanged = isRangeChanged;
337
+ isScrollChanged && (this.first = newFirst);
280
338
  }
281
339
  },
282
- scrollInView: function(t, i) {
283
- var n = this, r = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : "auto";
284
- if (i) {
285
- var s = this.isBoth(), l = this.isHorizontal(), a = s ? t.every(function(S) {
286
- return S > -1;
287
- }) : t > -1;
288
- if (a) {
289
- var h = this.getRenderedRange(), u = h.first, o = h.viewport, c = function() {
290
- var b = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0, w = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0;
291
- return n.scrollTo({
292
- left: b,
293
- top: w,
294
- behavior: r
340
+ scrollInView: function scrollInView(index, to) {
341
+ var _this2 = this;
342
+ var behavior = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : "auto";
343
+ if (to) {
344
+ var both = this.isBoth();
345
+ var horizontal = this.isHorizontal();
346
+ var valid = both ? index.every(function(i) {
347
+ return i > -1;
348
+ }) : index > -1;
349
+ if (valid) {
350
+ var _this$getRenderedRang = this.getRenderedRange(), first = _this$getRenderedRang.first, viewport = _this$getRenderedRang.viewport;
351
+ var scrollTo2 = function scrollTo3() {
352
+ var left = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0;
353
+ var top = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0;
354
+ return _this2.scrollTo({
355
+ left,
356
+ top,
357
+ behavior
295
358
  });
296
- }, m = i === "to-start", y = i === "to-end";
297
- if (m) {
298
- if (s)
299
- o.first.rows - u.rows > t[0] ? c(o.first.cols * this.itemSize[1], (o.first.rows - 1) * this.itemSize[0]) : o.first.cols - u.cols > t[1] && c((o.first.cols - 1) * this.itemSize[1], o.first.rows * this.itemSize[0]);
300
- else if (o.first - u > t) {
301
- var g = (o.first - 1) * this.itemSize;
302
- l ? c(g, 0) : c(0, g);
359
+ };
360
+ var isToStart = to === "to-start";
361
+ var isToEnd = to === "to-end";
362
+ if (isToStart) {
363
+ if (both) {
364
+ if (viewport.first.rows - first.rows > index[0]) {
365
+ scrollTo2(viewport.first.cols * this.itemSize[1], (viewport.first.rows - 1) * this.itemSize[0]);
366
+ } else if (viewport.first.cols - first.cols > index[1]) {
367
+ scrollTo2((viewport.first.cols - 1) * this.itemSize[1], viewport.first.rows * this.itemSize[0]);
368
+ }
369
+ } else {
370
+ if (viewport.first - first > index) {
371
+ var pos = (viewport.first - 1) * this.itemSize;
372
+ horizontal ? scrollTo2(pos, 0) : scrollTo2(0, pos);
373
+ }
303
374
  }
304
- } else if (y) {
305
- if (s)
306
- o.last.rows - u.rows <= t[0] + 1 ? c(o.first.cols * this.itemSize[1], (o.first.rows + 1) * this.itemSize[0]) : o.last.cols - u.cols <= t[1] + 1 && c((o.first.cols + 1) * this.itemSize[1], o.first.rows * this.itemSize[0]);
307
- else if (o.last - u <= t + 1) {
308
- var v = (o.first + 1) * this.itemSize;
309
- l ? c(v, 0) : c(0, v);
375
+ } else if (isToEnd) {
376
+ if (both) {
377
+ if (viewport.last.rows - first.rows <= index[0] + 1) {
378
+ scrollTo2(viewport.first.cols * this.itemSize[1], (viewport.first.rows + 1) * this.itemSize[0]);
379
+ } else if (viewport.last.cols - first.cols <= index[1] + 1) {
380
+ scrollTo2((viewport.first.cols + 1) * this.itemSize[1], viewport.first.rows * this.itemSize[0]);
381
+ }
382
+ } else {
383
+ if (viewport.last - first <= index + 1) {
384
+ var _pos2 = (viewport.first + 1) * this.itemSize;
385
+ horizontal ? scrollTo2(_pos2, 0) : scrollTo2(0, _pos2);
386
+ }
310
387
  }
311
388
  }
312
389
  }
313
- } else
314
- this.scrollToIndex(t, r);
390
+ } else {
391
+ this.scrollToIndex(index, behavior);
392
+ }
315
393
  },
316
- getRenderedRange: function() {
317
- var t = function(c, m) {
318
- return Math.floor(c / (m || c));
319
- }, i = this.first, n = 0;
394
+ getRenderedRange: function getRenderedRange() {
395
+ var calculateFirstInViewport = function calculateFirstInViewport2(_pos, _size) {
396
+ return Math.floor(_pos / (_size || _pos));
397
+ };
398
+ var firstInViewport = this.first;
399
+ var lastInViewport = 0;
320
400
  if (this.element) {
321
- var r = this.isBoth(), s = this.isHorizontal(), l = this.element, a = l.scrollTop, h = l.scrollLeft;
322
- if (r)
323
- i = {
324
- rows: t(a, this.itemSize[0]),
325
- cols: t(h, this.itemSize[1])
326
- }, n = {
327
- rows: i.rows + this.numItemsInViewport.rows,
328
- cols: i.cols + this.numItemsInViewport.cols
401
+ var both = this.isBoth();
402
+ var horizontal = this.isHorizontal();
403
+ var _this$element2 = this.element, scrollTop = _this$element2.scrollTop, scrollLeft = _this$element2.scrollLeft;
404
+ if (both) {
405
+ firstInViewport = {
406
+ rows: calculateFirstInViewport(scrollTop, this.itemSize[0]),
407
+ cols: calculateFirstInViewport(scrollLeft, this.itemSize[1])
408
+ };
409
+ lastInViewport = {
410
+ rows: firstInViewport.rows + this.numItemsInViewport.rows,
411
+ cols: firstInViewport.cols + this.numItemsInViewport.cols
329
412
  };
330
- else {
331
- var u = s ? h : a;
332
- i = t(u, this.itemSize), n = i + this.numItemsInViewport;
413
+ } else {
414
+ var scrollPos = horizontal ? scrollLeft : scrollTop;
415
+ firstInViewport = calculateFirstInViewport(scrollPos, this.itemSize);
416
+ lastInViewport = firstInViewport + this.numItemsInViewport;
333
417
  }
334
418
  }
335
419
  return {
336
420
  first: this.first,
337
421
  last: this.last,
338
422
  viewport: {
339
- first: i,
340
- last: n
423
+ first: firstInViewport,
424
+ last: lastInViewport
341
425
  }
342
426
  };
343
427
  },
344
- calculateNumItems: function() {
345
- var t = this.isBoth(), i = this.isHorizontal(), n = this.itemSize, r = this.getContentPosition(), s = this.element ? this.element.offsetWidth - r.left : 0, l = this.element ? this.element.offsetHeight - r.top : 0, a = function(m, y) {
346
- return Math.ceil(m / (y || m));
347
- }, h = function(m) {
348
- return Math.ceil(m / 2);
349
- }, u = t ? {
350
- rows: a(l, n[0]),
351
- cols: a(s, n[1])
352
- } : a(i ? s : l, n), o = this.d_numToleratedItems || (t ? [h(u.rows), h(u.cols)] : h(u));
428
+ calculateNumItems: function calculateNumItems() {
429
+ var both = this.isBoth();
430
+ var horizontal = this.isHorizontal();
431
+ var itemSize2 = this.itemSize;
432
+ var contentPos = this.getContentPosition();
433
+ var contentWidth = this.element ? this.element.offsetWidth - contentPos.left : 0;
434
+ var contentHeight = this.element ? this.element.offsetHeight - contentPos.top : 0;
435
+ var calculateNumItemsInViewport = function calculateNumItemsInViewport2(_contentSize, _itemSize) {
436
+ return Math.ceil(_contentSize / (_itemSize || _contentSize));
437
+ };
438
+ var calculateNumToleratedItems = function calculateNumToleratedItems2(_numItems) {
439
+ return Math.ceil(_numItems / 2);
440
+ };
441
+ var numItemsInViewport = both ? {
442
+ rows: calculateNumItemsInViewport(contentHeight, itemSize2[0]),
443
+ cols: calculateNumItemsInViewport(contentWidth, itemSize2[1])
444
+ } : calculateNumItemsInViewport(horizontal ? contentWidth : contentHeight, itemSize2);
445
+ var numToleratedItems2 = this.d_numToleratedItems || (both ? [calculateNumToleratedItems(numItemsInViewport.rows), calculateNumToleratedItems(numItemsInViewport.cols)] : calculateNumToleratedItems(numItemsInViewport));
353
446
  return {
354
- numItemsInViewport: u,
355
- numToleratedItems: o
447
+ numItemsInViewport,
448
+ numToleratedItems: numToleratedItems2
356
449
  };
357
450
  },
358
- calculateOptions: function() {
359
- var t = this, i = this.isBoth(), n = this.first, r = this.calculateNumItems(), s = r.numItemsInViewport, l = r.numToleratedItems, a = function(o, c, m) {
360
- var y = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : !1;
361
- return t.getLast(o + c + (o < m ? 2 : 3) * m, y);
362
- }, h = i ? {
363
- rows: a(n.rows, s.rows, l[0]),
364
- cols: a(n.cols, s.cols, l[1], !0)
365
- } : a(n, s, l);
366
- this.last = h, this.numItemsInViewport = s, this.d_numToleratedItems = l, this.$emit("update:numToleratedItems", this.d_numToleratedItems), this.showLoader && (this.loaderArr = i ? Array.from({
367
- length: s.rows
368
- }).map(function() {
369
- return Array.from({
370
- length: s.cols
451
+ calculateOptions: function calculateOptions() {
452
+ var _this3 = this;
453
+ var both = this.isBoth();
454
+ var first = this.first;
455
+ var _this$calculateNumIte2 = this.calculateNumItems(), numItemsInViewport = _this$calculateNumIte2.numItemsInViewport, numToleratedItems2 = _this$calculateNumIte2.numToleratedItems;
456
+ var calculateLast = function calculateLast2(_first, _num, _numT) {
457
+ var _isCols = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : false;
458
+ return _this3.getLast(_first + _num + (_first < _numT ? 2 : 3) * _numT, _isCols);
459
+ };
460
+ var last = both ? {
461
+ rows: calculateLast(first.rows, numItemsInViewport.rows, numToleratedItems2[0]),
462
+ cols: calculateLast(first.cols, numItemsInViewport.cols, numToleratedItems2[1], true)
463
+ } : calculateLast(first, numItemsInViewport, numToleratedItems2);
464
+ this.last = last;
465
+ this.numItemsInViewport = numItemsInViewport;
466
+ this.d_numToleratedItems = numToleratedItems2;
467
+ this.$emit("update:numToleratedItems", this.d_numToleratedItems);
468
+ if (this.showLoader) {
469
+ this.loaderArr = both ? Array.from({
470
+ length: numItemsInViewport.rows
471
+ }).map(function() {
472
+ return Array.from({
473
+ length: numItemsInViewport.cols
474
+ });
475
+ }) : Array.from({
476
+ length: numItemsInViewport
371
477
  });
372
- }) : Array.from({
373
- length: s
374
- })), this.lazy && Promise.resolve().then(function() {
375
- var u;
376
- t.lazyLoadState = {
377
- first: t.step ? i ? {
378
- rows: 0,
379
- cols: n.cols
380
- } : 0 : n,
381
- last: Math.min(t.step ? t.step : h, ((u = t.items) === null || u === void 0 ? void 0 : u.length) || 0)
382
- }, t.$emit("lazy-load", t.lazyLoadState);
383
- });
478
+ }
479
+ if (this.lazy) {
480
+ Promise.resolve().then(function() {
481
+ var _this3$items;
482
+ _this3.lazyLoadState = {
483
+ first: _this3.step ? both ? {
484
+ rows: 0,
485
+ cols: first.cols
486
+ } : 0 : first,
487
+ last: Math.min(_this3.step ? _this3.step : last, ((_this3$items = _this3.items) === null || _this3$items === void 0 ? void 0 : _this3$items.length) || 0)
488
+ };
489
+ _this3.$emit("lazy-load", _this3.lazyLoadState);
490
+ });
491
+ }
384
492
  },
385
- calculateAutoSize: function() {
386
- var t = this;
387
- this.autoSize && !this.d_loading && Promise.resolve().then(function() {
388
- if (t.content) {
389
- var i = t.isBoth(), n = t.isHorizontal(), r = t.isVertical();
390
- t.content.style.minHeight = t.content.style.minWidth = "auto", t.content.style.position = "relative", t.element.style.contain = "none";
391
- var s = [p.getWidth(t.element), p.getHeight(t.element)], l = s[0], a = s[1];
392
- (i || n) && (t.element.style.width = l < t.defaultWidth ? l + "px" : t.scrollWidth || t.defaultWidth + "px"), (i || r) && (t.element.style.height = a < t.defaultHeight ? a + "px" : t.scrollHeight || t.defaultHeight + "px"), t.content.style.minHeight = t.content.style.minWidth = "", t.content.style.position = "", t.element.style.contain = "";
393
- }
394
- });
493
+ calculateAutoSize: function calculateAutoSize() {
494
+ var _this4 = this;
495
+ if (this.autoSize && !this.d_loading) {
496
+ Promise.resolve().then(function() {
497
+ if (_this4.content) {
498
+ var both = _this4.isBoth();
499
+ var horizontal = _this4.isHorizontal();
500
+ var vertical = _this4.isVertical();
501
+ _this4.content.style.minHeight = _this4.content.style.minWidth = "auto";
502
+ _this4.content.style.position = "relative";
503
+ _this4.element.style.contain = "none";
504
+ var _ref = [DomHandler.getWidth(_this4.element), DomHandler.getHeight(_this4.element)], width = _ref[0], height = _ref[1];
505
+ (both || horizontal) && (_this4.element.style.width = width < _this4.defaultWidth ? width + "px" : _this4.scrollWidth || _this4.defaultWidth + "px");
506
+ (both || vertical) && (_this4.element.style.height = height < _this4.defaultHeight ? height + "px" : _this4.scrollHeight || _this4.defaultHeight + "px");
507
+ _this4.content.style.minHeight = _this4.content.style.minWidth = "";
508
+ _this4.content.style.position = "";
509
+ _this4.element.style.contain = "";
510
+ }
511
+ });
512
+ }
395
513
  },
396
- getLast: function() {
397
- var t, i, n = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0, r = arguments.length > 1 ? arguments[1] : void 0;
398
- return this.items ? Math.min(r ? ((t = this.columns || this.items[0]) === null || t === void 0 ? void 0 : t.length) || 0 : ((i = this.items) === null || i === void 0 ? void 0 : i.length) || 0, n) : 0;
514
+ getLast: function getLast() {
515
+ var _ref2, _this$items;
516
+ var last = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0;
517
+ var isCols = arguments.length > 1 ? arguments[1] : void 0;
518
+ return this.items ? Math.min(isCols ? ((_ref2 = this.columns || this.items[0]) === null || _ref2 === void 0 ? void 0 : _ref2.length) || 0 : ((_this$items = this.items) === null || _this$items === void 0 ? void 0 : _this$items.length) || 0, last) : 0;
399
519
  },
400
- getContentPosition: function() {
520
+ getContentPosition: function getContentPosition() {
401
521
  if (this.content) {
402
- var t = getComputedStyle(this.content), i = parseFloat(t.paddingLeft) + Math.max(parseFloat(t.left) || 0, 0), n = parseFloat(t.paddingRight) + Math.max(parseFloat(t.right) || 0, 0), r = parseFloat(t.paddingTop) + Math.max(parseFloat(t.top) || 0, 0), s = parseFloat(t.paddingBottom) + Math.max(parseFloat(t.bottom) || 0, 0);
522
+ var style = getComputedStyle(this.content);
523
+ var left = parseFloat(style.paddingLeft) + Math.max(parseFloat(style.left) || 0, 0);
524
+ var right = parseFloat(style.paddingRight) + Math.max(parseFloat(style.right) || 0, 0);
525
+ var top = parseFloat(style.paddingTop) + Math.max(parseFloat(style.top) || 0, 0);
526
+ var bottom = parseFloat(style.paddingBottom) + Math.max(parseFloat(style.bottom) || 0, 0);
403
527
  return {
404
- left: i,
405
- right: n,
406
- top: r,
407
- bottom: s,
408
- x: i + n,
409
- y: r + s
528
+ left,
529
+ right,
530
+ top,
531
+ bottom,
532
+ x: left + right,
533
+ y: top + bottom
410
534
  };
411
535
  }
412
536
  return {
@@ -418,287 +542,390 @@ var et = {
418
542
  y: 0
419
543
  };
420
544
  },
421
- setSize: function() {
422
- var t = this;
545
+ setSize: function setSize() {
546
+ var _this5 = this;
423
547
  if (this.element) {
424
- var i = this.isBoth(), n = this.isHorizontal(), r = this.element.parentElement, s = this.scrollWidth || "".concat(this.element.offsetWidth || r.offsetWidth, "px"), l = this.scrollHeight || "".concat(this.element.offsetHeight || r.offsetHeight, "px"), a = function(u, o) {
425
- return t.element.style[u] = o;
548
+ var both = this.isBoth();
549
+ var horizontal = this.isHorizontal();
550
+ var parentElement = this.element.parentElement;
551
+ var width = this.scrollWidth || "".concat(this.element.offsetWidth || parentElement.offsetWidth, "px");
552
+ var height = this.scrollHeight || "".concat(this.element.offsetHeight || parentElement.offsetHeight, "px");
553
+ var setProp = function setProp2(_name, _value) {
554
+ return _this5.element.style[_name] = _value;
426
555
  };
427
- i || n ? (a("height", l), a("width", s)) : a("height", l);
556
+ if (both || horizontal) {
557
+ setProp("height", height);
558
+ setProp("width", width);
559
+ } else {
560
+ setProp("height", height);
561
+ }
428
562
  }
429
563
  },
430
- setSpacerSize: function() {
431
- var t = this, i = this.items;
432
- if (i) {
433
- var n = this.isBoth(), r = this.isHorizontal(), s = this.getContentPosition(), l = function(h, u, o) {
434
- var c = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : 0;
435
- return t.spacerStyle = j(j({}, t.spacerStyle), J({}, "".concat(h), (u || []).length * o + c + "px"));
564
+ setSpacerSize: function setSpacerSize() {
565
+ var _this6 = this;
566
+ var items2 = this.items;
567
+ if (items2) {
568
+ var both = this.isBoth();
569
+ var horizontal = this.isHorizontal();
570
+ var contentPos = this.getContentPosition();
571
+ var setProp = function setProp2(_name, _value, _size) {
572
+ var _cpos = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : 0;
573
+ return _this6.spacerStyle = _objectSpread(_objectSpread({}, _this6.spacerStyle), _defineProperty({}, "".concat(_name), (_value || []).length * _size + _cpos + "px"));
436
574
  };
437
- n ? (l("height", i, this.itemSize[0], s.y), l("width", this.columns || i[1], this.itemSize[1], s.x)) : r ? l("width", this.columns || i, this.itemSize, s.x) : l("height", i, this.itemSize, s.y);
575
+ if (both) {
576
+ setProp("height", items2, this.itemSize[0], contentPos.y);
577
+ setProp("width", this.columns || items2[1], this.itemSize[1], contentPos.x);
578
+ } else {
579
+ horizontal ? setProp("width", this.columns || items2, this.itemSize, contentPos.x) : setProp("height", items2, this.itemSize, contentPos.y);
580
+ }
438
581
  }
439
582
  },
440
- setContentPosition: function(t) {
441
- var i = this;
583
+ setContentPosition: function setContentPosition(pos) {
584
+ var _this7 = this;
442
585
  if (this.content && !this.appendOnly) {
443
- var n = this.isBoth(), r = this.isHorizontal(), s = t ? t.first : this.first, l = function(o, c) {
444
- return o * c;
445
- }, a = function() {
446
- var o = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0, c = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0;
447
- return i.contentStyle = j(j({}, i.contentStyle), {
448
- transform: "translate3d(".concat(o, "px, ").concat(c, "px, 0)")
586
+ var both = this.isBoth();
587
+ var horizontal = this.isHorizontal();
588
+ var first = pos ? pos.first : this.first;
589
+ var calculateTranslateVal = function calculateTranslateVal2(_first, _size) {
590
+ return _first * _size;
591
+ };
592
+ var setTransform = function setTransform2() {
593
+ var _x = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : 0;
594
+ var _y = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : 0;
595
+ return _this7.contentStyle = _objectSpread(_objectSpread({}, _this7.contentStyle), {
596
+ transform: "translate3d(".concat(_x, "px, ").concat(_y, "px, 0)")
449
597
  });
450
598
  };
451
- if (n)
452
- a(l(s.cols, this.itemSize[1]), l(s.rows, this.itemSize[0]));
453
- else {
454
- var h = l(s, this.itemSize);
455
- r ? a(h, 0) : a(0, h);
599
+ if (both) {
600
+ setTransform(calculateTranslateVal(first.cols, this.itemSize[1]), calculateTranslateVal(first.rows, this.itemSize[0]));
601
+ } else {
602
+ var translateVal = calculateTranslateVal(first, this.itemSize);
603
+ horizontal ? setTransform(translateVal, 0) : setTransform(0, translateVal);
456
604
  }
457
605
  }
458
606
  },
459
- onScrollPositionChange: function(t) {
460
- var i = this, n = t.target, r = this.isBoth(), s = this.isHorizontal(), l = this.getContentPosition(), a = function(f, z) {
461
- return f ? f > z ? f - z : f : 0;
462
- }, h = function(f, z) {
463
- return Math.floor(f / (z || f));
464
- }, u = function(f, z, N, F, C, O) {
465
- return f <= C ? C : O ? N - F - C : z + C - 1;
466
- }, o = function(f, z, N, F, C, O, _) {
467
- return f <= O ? 0 : Math.max(0, _ ? f < z ? N : f - O : f > z ? N : f - 2 * O);
468
- }, c = function(f, z, N, F, C, O) {
469
- var _ = z + F + 2 * C;
470
- return f >= C && (_ += C + 1), i.getLast(_, O);
471
- }, m = a(n.scrollTop, l.top), y = a(n.scrollLeft, l.left), g = r ? {
607
+ onScrollPositionChange: function onScrollPositionChange(event) {
608
+ var _this8 = this;
609
+ var target = event.target;
610
+ var both = this.isBoth();
611
+ var horizontal = this.isHorizontal();
612
+ var contentPos = this.getContentPosition();
613
+ var calculateScrollPos = function calculateScrollPos2(_pos, _cpos) {
614
+ return _pos ? _pos > _cpos ? _pos - _cpos : _pos : 0;
615
+ };
616
+ var calculateCurrentIndex = function calculateCurrentIndex2(_pos, _size) {
617
+ return Math.floor(_pos / (_size || _pos));
618
+ };
619
+ var calculateTriggerIndex = function calculateTriggerIndex2(_currentIndex, _first, _last, _num, _numT, _isScrollDownOrRight) {
620
+ return _currentIndex <= _numT ? _numT : _isScrollDownOrRight ? _last - _num - _numT : _first + _numT - 1;
621
+ };
622
+ var calculateFirst = function calculateFirst2(_currentIndex, _triggerIndex, _first, _last, _num, _numT, _isScrollDownOrRight) {
623
+ if (_currentIndex <= _numT) return 0;
624
+ else return Math.max(0, _isScrollDownOrRight ? _currentIndex < _triggerIndex ? _first : _currentIndex - _numT : _currentIndex > _triggerIndex ? _first : _currentIndex - 2 * _numT);
625
+ };
626
+ var calculateLast = function calculateLast2(_currentIndex, _first, _last, _num, _numT, _isCols) {
627
+ var lastValue = _first + _num + 2 * _numT;
628
+ if (_currentIndex >= _numT) {
629
+ lastValue += _numT + 1;
630
+ }
631
+ return _this8.getLast(lastValue, _isCols);
632
+ };
633
+ var scrollTop = calculateScrollPos(target.scrollTop, contentPos.top);
634
+ var scrollLeft = calculateScrollPos(target.scrollLeft, contentPos.left);
635
+ var newFirst = both ? {
472
636
  rows: 0,
473
637
  cols: 0
474
- } : 0, v = this.last, S = !1, b = this.lastScrollPos;
475
- if (r) {
476
- var w = this.lastScrollPos.top <= m, L = this.lastScrollPos.left <= y;
477
- if (!this.appendOnly || this.appendOnly && (w || L)) {
478
- var d = {
479
- rows: h(m, this.itemSize[0]),
480
- cols: h(y, this.itemSize[1])
481
- }, V = {
482
- rows: u(d.rows, this.first.rows, this.last.rows, this.numItemsInViewport.rows, this.d_numToleratedItems[0], w),
483
- cols: u(d.cols, this.first.cols, this.last.cols, this.numItemsInViewport.cols, this.d_numToleratedItems[1], L)
638
+ } : 0;
639
+ var newLast = this.last;
640
+ var isRangeChanged = false;
641
+ var newScrollPos = this.lastScrollPos;
642
+ if (both) {
643
+ var isScrollDown = this.lastScrollPos.top <= scrollTop;
644
+ var isScrollRight = this.lastScrollPos.left <= scrollLeft;
645
+ if (!this.appendOnly || this.appendOnly && (isScrollDown || isScrollRight)) {
646
+ var currentIndex = {
647
+ rows: calculateCurrentIndex(scrollTop, this.itemSize[0]),
648
+ cols: calculateCurrentIndex(scrollLeft, this.itemSize[1])
649
+ };
650
+ var triggerIndex = {
651
+ rows: calculateTriggerIndex(currentIndex.rows, this.first.rows, this.last.rows, this.numItemsInViewport.rows, this.d_numToleratedItems[0], isScrollDown),
652
+ cols: calculateTriggerIndex(currentIndex.cols, this.first.cols, this.last.cols, this.numItemsInViewport.cols, this.d_numToleratedItems[1], isScrollRight)
653
+ };
654
+ newFirst = {
655
+ rows: calculateFirst(currentIndex.rows, triggerIndex.rows, this.first.rows, this.last.rows, this.numItemsInViewport.rows, this.d_numToleratedItems[0], isScrollDown),
656
+ cols: calculateFirst(currentIndex.cols, triggerIndex.cols, this.first.cols, this.last.cols, this.numItemsInViewport.cols, this.d_numToleratedItems[1], isScrollRight)
484
657
  };
485
- g = {
486
- rows: o(d.rows, V.rows, this.first.rows, this.last.rows, this.numItemsInViewport.rows, this.d_numToleratedItems[0], w),
487
- cols: o(d.cols, V.cols, this.first.cols, this.last.cols, this.numItemsInViewport.cols, this.d_numToleratedItems[1], L)
488
- }, v = {
489
- rows: c(d.rows, g.rows, this.last.rows, this.numItemsInViewport.rows, this.d_numToleratedItems[0]),
490
- cols: c(d.cols, g.cols, this.last.cols, this.numItemsInViewport.cols, this.d_numToleratedItems[1], !0)
491
- }, S = g.rows !== this.first.rows || v.rows !== this.last.rows || g.cols !== this.first.cols || v.cols !== this.last.cols || this.isRangeChanged, b = {
492
- top: m,
493
- left: y
658
+ newLast = {
659
+ rows: calculateLast(currentIndex.rows, newFirst.rows, this.last.rows, this.numItemsInViewport.rows, this.d_numToleratedItems[0]),
660
+ cols: calculateLast(currentIndex.cols, newFirst.cols, this.last.cols, this.numItemsInViewport.cols, this.d_numToleratedItems[1], true)
661
+ };
662
+ isRangeChanged = newFirst.rows !== this.first.rows || newLast.rows !== this.last.rows || newFirst.cols !== this.first.cols || newLast.cols !== this.last.cols || this.isRangeChanged;
663
+ newScrollPos = {
664
+ top: scrollTop,
665
+ left: scrollLeft
494
666
  };
495
667
  }
496
668
  } else {
497
- var B = s ? y : m, P = this.lastScrollPos <= B;
498
- if (!this.appendOnly || this.appendOnly && P) {
499
- var I = h(B, this.itemSize), H = u(I, this.first, this.last, this.numItemsInViewport, this.d_numToleratedItems, P);
500
- g = o(I, H, this.first, this.last, this.numItemsInViewport, this.d_numToleratedItems, P), v = c(I, g, this.last, this.numItemsInViewport, this.d_numToleratedItems), S = g !== this.first || v !== this.last || this.isRangeChanged, b = B;
669
+ var scrollPos = horizontal ? scrollLeft : scrollTop;
670
+ var isScrollDownOrRight = this.lastScrollPos <= scrollPos;
671
+ if (!this.appendOnly || this.appendOnly && isScrollDownOrRight) {
672
+ var _currentIndex2 = calculateCurrentIndex(scrollPos, this.itemSize);
673
+ var _triggerIndex2 = calculateTriggerIndex(_currentIndex2, this.first, this.last, this.numItemsInViewport, this.d_numToleratedItems, isScrollDownOrRight);
674
+ newFirst = calculateFirst(_currentIndex2, _triggerIndex2, this.first, this.last, this.numItemsInViewport, this.d_numToleratedItems, isScrollDownOrRight);
675
+ newLast = calculateLast(_currentIndex2, newFirst, this.last, this.numItemsInViewport, this.d_numToleratedItems);
676
+ isRangeChanged = newFirst !== this.first || newLast !== this.last || this.isRangeChanged;
677
+ newScrollPos = scrollPos;
501
678
  }
502
679
  }
503
680
  return {
504
- first: g,
505
- last: v,
506
- isRangeChanged: S,
507
- scrollPos: b
681
+ first: newFirst,
682
+ last: newLast,
683
+ isRangeChanged,
684
+ scrollPos: newScrollPos
508
685
  };
509
686
  },
510
- onScrollChange: function(t) {
511
- var i = this.onScrollPositionChange(t), n = i.first, r = i.last, s = i.isRangeChanged, l = i.scrollPos;
512
- if (s) {
513
- var a = {
514
- first: n,
515
- last: r
687
+ onScrollChange: function onScrollChange(event) {
688
+ var _this$onScrollPositio = this.onScrollPositionChange(event), first = _this$onScrollPositio.first, last = _this$onScrollPositio.last, isRangeChanged = _this$onScrollPositio.isRangeChanged, scrollPos = _this$onScrollPositio.scrollPos;
689
+ if (isRangeChanged) {
690
+ var newState = {
691
+ first,
692
+ last
516
693
  };
517
- if (this.setContentPosition(a), this.first = n, this.last = r, this.lastScrollPos = l, this.$emit("scroll-index-change", a), this.lazy && this.isPageChanged(n)) {
518
- var h, u, o = {
519
- first: this.step ? Math.min(this.getPageByFirst(n) * this.step, (((h = this.items) === null || h === void 0 ? void 0 : h.length) || 0) - this.step) : n,
520
- last: Math.min(this.step ? (this.getPageByFirst(n) + 1) * this.step : r, ((u = this.items) === null || u === void 0 ? void 0 : u.length) || 0)
521
- }, c = this.lazyLoadState.first !== o.first || this.lazyLoadState.last !== o.last;
522
- c && this.$emit("lazy-load", o), this.lazyLoadState = o;
694
+ this.setContentPosition(newState);
695
+ this.first = first;
696
+ this.last = last;
697
+ this.lastScrollPos = scrollPos;
698
+ this.$emit("scroll-index-change", newState);
699
+ if (this.lazy && this.isPageChanged(first)) {
700
+ var _this$items2, _this$items3;
701
+ var lazyLoadState = {
702
+ first: this.step ? Math.min(this.getPageByFirst(first) * this.step, (((_this$items2 = this.items) === null || _this$items2 === void 0 ? void 0 : _this$items2.length) || 0) - this.step) : first,
703
+ last: Math.min(this.step ? (this.getPageByFirst(first) + 1) * this.step : last, ((_this$items3 = this.items) === null || _this$items3 === void 0 ? void 0 : _this$items3.length) || 0)
704
+ };
705
+ var isLazyStateChanged = this.lazyLoadState.first !== lazyLoadState.first || this.lazyLoadState.last !== lazyLoadState.last;
706
+ isLazyStateChanged && this.$emit("lazy-load", lazyLoadState);
707
+ this.lazyLoadState = lazyLoadState;
523
708
  }
524
709
  }
525
710
  },
526
- onScroll: function(t) {
527
- var i = this;
528
- if (this.$emit("scroll", t), this.delay) {
529
- if (this.scrollTimeout && clearTimeout(this.scrollTimeout), this.isPageChanged()) {
711
+ onScroll: function onScroll(event) {
712
+ var _this9 = this;
713
+ this.$emit("scroll", event);
714
+ if (this.delay) {
715
+ if (this.scrollTimeout) {
716
+ clearTimeout(this.scrollTimeout);
717
+ }
718
+ if (this.isPageChanged()) {
530
719
  if (!this.d_loading && this.showLoader) {
531
- var n = this.onScrollPositionChange(t), r = n.isRangeChanged, s = r || (this.step ? this.isPageChanged() : !1);
532
- s && (this.d_loading = !0);
720
+ var _this$onScrollPositio2 = this.onScrollPositionChange(event), isRangeChanged = _this$onScrollPositio2.isRangeChanged;
721
+ var changed = isRangeChanged || (this.step ? this.isPageChanged() : false);
722
+ changed && (this.d_loading = true);
533
723
  }
534
724
  this.scrollTimeout = setTimeout(function() {
535
- i.onScrollChange(t), i.d_loading && i.showLoader && (!i.lazy || i.loading === void 0) && (i.d_loading = !1, i.page = i.getPageByFirst());
725
+ _this9.onScrollChange(event);
726
+ if (_this9.d_loading && _this9.showLoader && (!_this9.lazy || _this9.loading === void 0)) {
727
+ _this9.d_loading = false;
728
+ _this9.page = _this9.getPageByFirst();
729
+ }
536
730
  }, this.delay);
537
731
  }
538
- } else
539
- this.onScrollChange(t);
540
- },
541
- onResize: function() {
542
- var t = this;
543
- this.resizeTimeout && clearTimeout(this.resizeTimeout), this.resizeTimeout = setTimeout(function() {
544
- if (p.isVisible(t.element)) {
545
- var i = t.isBoth(), n = t.isVertical(), r = t.isHorizontal(), s = [p.getWidth(t.element), p.getHeight(t.element)], l = s[0], a = s[1], h = l !== t.defaultWidth, u = a !== t.defaultHeight, o = i ? h || u : r ? h : n ? u : !1;
546
- o && (t.d_numToleratedItems = t.numToleratedItems, t.defaultWidth = l, t.defaultHeight = a, t.defaultContentWidth = p.getWidth(t.content), t.defaultContentHeight = p.getHeight(t.content), t.init());
732
+ } else {
733
+ this.onScrollChange(event);
734
+ }
735
+ },
736
+ onResize: function onResize() {
737
+ var _this10 = this;
738
+ if (this.resizeTimeout) {
739
+ clearTimeout(this.resizeTimeout);
740
+ }
741
+ this.resizeTimeout = setTimeout(function() {
742
+ if (DomHandler.isVisible(_this10.element)) {
743
+ var both = _this10.isBoth();
744
+ var vertical = _this10.isVertical();
745
+ var horizontal = _this10.isHorizontal();
746
+ var _ref3 = [DomHandler.getWidth(_this10.element), DomHandler.getHeight(_this10.element)], width = _ref3[0], height = _ref3[1];
747
+ var isDiffWidth = width !== _this10.defaultWidth, isDiffHeight = height !== _this10.defaultHeight;
748
+ var reinit = both ? isDiffWidth || isDiffHeight : horizontal ? isDiffWidth : vertical ? isDiffHeight : false;
749
+ if (reinit) {
750
+ _this10.d_numToleratedItems = _this10.numToleratedItems;
751
+ _this10.defaultWidth = width;
752
+ _this10.defaultHeight = height;
753
+ _this10.defaultContentWidth = DomHandler.getWidth(_this10.content);
754
+ _this10.defaultContentHeight = DomHandler.getHeight(_this10.content);
755
+ _this10.init();
756
+ }
547
757
  }
548
758
  }, this.resizeDelay);
549
759
  },
550
- bindResizeListener: function() {
551
- this.resizeListener || (this.resizeListener = this.onResize.bind(this), window.addEventListener("resize", this.resizeListener), window.addEventListener("orientationchange", this.resizeListener));
760
+ bindResizeListener: function bindResizeListener() {
761
+ if (!this.resizeListener) {
762
+ this.resizeListener = this.onResize.bind(this);
763
+ window.addEventListener("resize", this.resizeListener);
764
+ window.addEventListener("orientationchange", this.resizeListener);
765
+ }
552
766
  },
553
- unbindResizeListener: function() {
554
- this.resizeListener && (window.removeEventListener("resize", this.resizeListener), window.removeEventListener("orientationchange", this.resizeListener), this.resizeListener = null);
767
+ unbindResizeListener: function unbindResizeListener() {
768
+ if (this.resizeListener) {
769
+ window.removeEventListener("resize", this.resizeListener);
770
+ window.removeEventListener("orientationchange", this.resizeListener);
771
+ this.resizeListener = null;
772
+ }
555
773
  },
556
- getOptions: function(t) {
557
- var i = (this.items || []).length, n = this.isBoth() ? this.first.rows + t : this.first + t;
774
+ getOptions: function getOptions(renderedIndex) {
775
+ var count = (this.items || []).length;
776
+ var index = this.isBoth() ? this.first.rows + renderedIndex : this.first + renderedIndex;
558
777
  return {
559
- index: n,
560
- count: i,
561
- first: n === 0,
562
- last: n === i - 1,
563
- even: n % 2 === 0,
564
- odd: n % 2 !== 0
778
+ index,
779
+ count,
780
+ first: index === 0,
781
+ last: index === count - 1,
782
+ even: index % 2 === 0,
783
+ odd: index % 2 !== 0
565
784
  };
566
785
  },
567
- getLoaderOptions: function(t, i) {
568
- var n = this.loaderArr.length;
569
- return j({
570
- index: t,
571
- count: n,
572
- first: t === 0,
573
- last: t === n - 1,
574
- even: t % 2 === 0,
575
- odd: t % 2 !== 0
576
- }, i);
786
+ getLoaderOptions: function getLoaderOptions(index, extOptions) {
787
+ var count = this.loaderArr.length;
788
+ return _objectSpread({
789
+ index,
790
+ count,
791
+ first: index === 0,
792
+ last: index === count - 1,
793
+ even: index % 2 === 0,
794
+ odd: index % 2 !== 0
795
+ }, extOptions);
577
796
  },
578
- getPageByFirst: function(t) {
579
- return Math.floor(((t ?? this.first) + this.d_numToleratedItems * 4) / (this.step || 1));
797
+ getPageByFirst: function getPageByFirst(first) {
798
+ return Math.floor(((first !== null && first !== void 0 ? first : this.first) + this.d_numToleratedItems * 4) / (this.step || 1));
580
799
  },
581
- isPageChanged: function(t) {
582
- return this.step ? this.page !== this.getPageByFirst(t ?? this.first) : !0;
800
+ isPageChanged: function isPageChanged(first) {
801
+ return this.step ? this.page !== this.getPageByFirst(first !== null && first !== void 0 ? first : this.first) : true;
583
802
  },
584
- setContentEl: function(t) {
585
- this.content = t || this.content || p.findSingle(this.element, '[data-pc-section="content"]');
803
+ setContentEl: function setContentEl(el) {
804
+ this.content = el || this.content || DomHandler.findSingle(this.element, '[data-pc-section="content"]');
586
805
  },
587
- elementRef: function(t) {
588
- this.element = t;
806
+ elementRef: function elementRef(el) {
807
+ this.element = el;
589
808
  },
590
- contentRef: function(t) {
591
- this.content = t;
809
+ contentRef: function contentRef(el) {
810
+ this.content = el;
592
811
  }
593
812
  },
594
813
  computed: {
595
- containerClass: function() {
596
- return ["p-virtualscroller", this.class, {
814
+ containerClass: function containerClass() {
815
+ return ["p-virtualscroller", this["class"], {
597
816
  "p-virtualscroller-inline": this.inline,
598
817
  "p-virtualscroller-both p-both-scroll": this.isBoth(),
599
818
  "p-virtualscroller-horizontal p-horizontal-scroll": this.isHorizontal()
600
819
  }];
601
820
  },
602
- contentClass: function() {
821
+ contentClass: function contentClass() {
603
822
  return ["p-virtualscroller-content", {
604
823
  "p-virtualscroller-loading": this.d_loading
605
824
  }];
606
825
  },
607
- loaderClass: function() {
826
+ loaderClass: function loaderClass() {
608
827
  return ["p-virtualscroller-loader", {
609
828
  "p-component-overlay": !this.$slots.loader
610
829
  }];
611
830
  },
612
- loadedItems: function() {
613
- var t = this;
614
- return this.items && !this.d_loading ? this.isBoth() ? this.items.slice(this.appendOnly ? 0 : this.first.rows, this.last.rows).map(function(i) {
615
- return t.columns ? i : i.slice(t.appendOnly ? 0 : t.first.cols, t.last.cols);
616
- }) : this.isHorizontal() && this.columns ? this.items : this.items.slice(this.appendOnly ? 0 : this.first, this.last) : [];
831
+ loadedItems: function loadedItems() {
832
+ var _this11 = this;
833
+ if (this.items && !this.d_loading) {
834
+ if (this.isBoth()) return this.items.slice(this.appendOnly ? 0 : this.first.rows, this.last.rows).map(function(item) {
835
+ return _this11.columns ? item : item.slice(_this11.appendOnly ? 0 : _this11.first.cols, _this11.last.cols);
836
+ });
837
+ else if (this.isHorizontal() && this.columns) return this.items;
838
+ else return this.items.slice(this.appendOnly ? 0 : this.first, this.last);
839
+ }
840
+ return [];
617
841
  },
618
- loadedRows: function() {
842
+ loadedRows: function loadedRows() {
619
843
  return this.d_loading ? this.loaderDisabled ? this.loaderArr : [] : this.loadedItems;
620
844
  },
621
- loadedColumns: function() {
845
+ loadedColumns: function loadedColumns() {
622
846
  if (this.columns) {
623
- var t = this.isBoth(), i = this.isHorizontal();
624
- if (t || i)
625
- return this.d_loading && this.loaderDisabled ? t ? this.loaderArr[0] : this.loaderArr : this.columns.slice(t ? this.first.cols : this.first, t ? this.last.cols : this.last);
847
+ var both = this.isBoth();
848
+ var horizontal = this.isHorizontal();
849
+ if (both || horizontal) {
850
+ return this.d_loading && this.loaderDisabled ? both ? this.loaderArr[0] : this.loaderArr : this.columns.slice(both ? this.first.cols : this.first, both ? this.last.cols : this.last);
851
+ }
626
852
  }
627
853
  return this.columns;
628
854
  }
629
855
  },
630
856
  components: {
631
- SpinnerIcon: Q
857
+ SpinnerIcon: script$2
632
858
  }
633
- }, it = ["tabindex"];
634
- function st(e, t, i, n, r, s) {
635
- var l = X("SpinnerIcon");
636
- return e.disabled ? (W(), R(D, {
637
- key: 1
638
- }, [A(e.$slots, "default"), A(e.$slots, "content", {
639
- items: e.items,
640
- rows: e.items,
641
- columns: s.loadedColumns
642
- })], 64)) : (W(), R("div", M({
859
+ };
860
+ var _hoisted_1 = ["tabindex"];
861
+ function render(_ctx, _cache, $props, $setup, $data, $options) {
862
+ var _component_SpinnerIcon = resolveComponent("SpinnerIcon");
863
+ return !_ctx.disabled ? (openBlock(), createElementBlock("div", mergeProps({
643
864
  key: 0,
644
- ref: s.elementRef,
645
- class: s.containerClass,
646
- tabindex: e.tabindex,
647
- style: e.style,
648
- onScroll: t[0] || (t[0] = function() {
649
- return s.onScroll && s.onScroll.apply(s, arguments);
865
+ ref: $options.elementRef,
866
+ "class": $options.containerClass,
867
+ tabindex: _ctx.tabindex,
868
+ style: _ctx.style,
869
+ onScroll: _cache[0] || (_cache[0] = function() {
870
+ return $options.onScroll && $options.onScroll.apply($options, arguments);
650
871
  })
651
- }, e.ptmi("root")), [A(e.$slots, "content", {
652
- styleClass: s.contentClass,
653
- items: s.loadedItems,
654
- getItemOptions: s.getOptions,
655
- loading: r.d_loading,
656
- getLoaderOptions: s.getLoaderOptions,
657
- itemSize: e.itemSize,
658
- rows: s.loadedRows,
659
- columns: s.loadedColumns,
660
- contentRef: s.contentRef,
661
- spacerStyle: r.spacerStyle,
662
- contentStyle: r.contentStyle,
663
- vertical: s.isVertical(),
664
- horizontal: s.isHorizontal(),
665
- both: s.isBoth()
872
+ }, _ctx.ptmi("root")), [renderSlot(_ctx.$slots, "content", {
873
+ styleClass: $options.contentClass,
874
+ items: $options.loadedItems,
875
+ getItemOptions: $options.getOptions,
876
+ loading: $data.d_loading,
877
+ getLoaderOptions: $options.getLoaderOptions,
878
+ itemSize: _ctx.itemSize,
879
+ rows: $options.loadedRows,
880
+ columns: $options.loadedColumns,
881
+ contentRef: $options.contentRef,
882
+ spacerStyle: $data.spacerStyle,
883
+ contentStyle: $data.contentStyle,
884
+ vertical: $options.isVertical(),
885
+ horizontal: $options.isHorizontal(),
886
+ both: $options.isBoth()
666
887
  }, function() {
667
- return [Y("div", M({
668
- ref: s.contentRef,
669
- class: s.contentClass,
670
- style: r.contentStyle
671
- }, e.ptm("content")), [(W(!0), R(D, null, q(s.loadedItems, function(a, h) {
672
- return A(e.$slots, "item", {
673
- key: h,
674
- item: a,
675
- options: s.getOptions(h)
888
+ return [createElementVNode("div", mergeProps({
889
+ ref: $options.contentRef,
890
+ "class": $options.contentClass,
891
+ style: $data.contentStyle
892
+ }, _ctx.ptm("content")), [(openBlock(true), createElementBlock(Fragment, null, renderList($options.loadedItems, function(item, index) {
893
+ return renderSlot(_ctx.$slots, "item", {
894
+ key: index,
895
+ item,
896
+ options: $options.getOptions(index)
676
897
  });
677
898
  }), 128))], 16)];
678
- }), e.showSpacer ? (W(), R("div", M({
899
+ }), _ctx.showSpacer ? (openBlock(), createElementBlock("div", mergeProps({
679
900
  key: 0,
680
- class: "p-virtualscroller-spacer",
681
- style: r.spacerStyle
682
- }, e.ptm("spacer")), null, 16)) : k("", !0), !e.loaderDisabled && e.showLoader && r.d_loading ? (W(), R("div", M({
901
+ "class": "p-virtualscroller-spacer",
902
+ style: $data.spacerStyle
903
+ }, _ctx.ptm("spacer")), null, 16)) : createCommentVNode("", true), !_ctx.loaderDisabled && _ctx.showLoader && $data.d_loading ? (openBlock(), createElementBlock("div", mergeProps({
683
904
  key: 1,
684
- class: s.loaderClass
685
- }, e.ptm("loader")), [e.$slots && e.$slots.loader ? (W(!0), R(D, {
905
+ "class": $options.loaderClass
906
+ }, _ctx.ptm("loader")), [_ctx.$slots && _ctx.$slots.loader ? (openBlock(true), createElementBlock(Fragment, {
686
907
  key: 0
687
- }, q(r.loaderArr, function(a, h) {
688
- return A(e.$slots, "loader", {
689
- key: h,
690
- options: s.getLoaderOptions(h, s.isBoth() && {
691
- numCols: e.d_numItemsInViewport.cols
908
+ }, renderList($data.loaderArr, function(_, index) {
909
+ return renderSlot(_ctx.$slots, "loader", {
910
+ key: index,
911
+ options: $options.getLoaderOptions(index, $options.isBoth() && {
912
+ numCols: _ctx.d_numItemsInViewport.cols
692
913
  })
693
914
  });
694
- }), 128)) : k("", !0), A(e.$slots, "loadingicon", {}, function() {
695
- return [Z(l, M({
915
+ }), 128)) : createCommentVNode("", true), renderSlot(_ctx.$slots, "loadingicon", {}, function() {
916
+ return [createVNode(_component_SpinnerIcon, mergeProps({
696
917
  spin: "",
697
- class: "p-virtualscroller-loading-icon"
698
- }, e.ptm("loadingIcon")), null, 16)];
699
- })], 16)) : k("", !0)], 16, it));
918
+ "class": "p-virtualscroller-loading-icon"
919
+ }, _ctx.ptm("loadingIcon")), null, 16)];
920
+ })], 16)) : createCommentVNode("", true)], 16, _hoisted_1)) : (openBlock(), createElementBlock(Fragment, {
921
+ key: 1
922
+ }, [renderSlot(_ctx.$slots, "default"), renderSlot(_ctx.$slots, "content", {
923
+ items: _ctx.items,
924
+ rows: _ctx.items,
925
+ columns: $options.loadedColumns
926
+ })], 64));
700
927
  }
701
- et.render = st;
928
+ script.render = render;
702
929
  export {
703
- et as s
930
+ script as s
704
931
  };