wsemi 1.8.61 → 1.8.63

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 (477) hide show
  1. package/README.md +1 -1
  2. package/dist/wsemi.umd.js +3 -3
  3. package/dist/wsemi.umd.js.map +1 -1
  4. package/docs/-_class.mjs.html +1 -1
  5. package/docs/ab2blob.mjs.html +1 -1
  6. package/docs/ab2u8arr.mjs.html +1 -1
  7. package/docs/addExcelWorksheetFromData.mjs.html +1 -1
  8. package/docs/addMonth.mjs.html +1 -1
  9. package/docs/aes2str.mjs.html +1 -1
  10. package/docs/alive.mjs.html +1 -1
  11. package/docs/arr2dt.mjs.html +1 -1
  12. package/docs/arrAccum.mjs.html +1 -1
  13. package/docs/arrAdd.mjs.html +1 -1
  14. package/docs/arrAt.mjs.html +1 -1
  15. package/docs/arrDiff.mjs.html +1 -1
  16. package/docs/arrFilterByKeywords.mjs.html +1 -1
  17. package/docs/arrFilterByNum.mjs.html +1 -1
  18. package/docs/arrFilterByPnum.mjs.html +1 -1
  19. package/docs/arrFilterByPnumAndToLog.mjs.html +1 -1
  20. package/docs/arrFind.mjs.html +1 -1
  21. package/docs/arrGroupByMaxmin.mjs.html +1 -1
  22. package/docs/arrHas.mjs.html +1 -1
  23. package/docs/arrInsert.mjs.html +1 -1
  24. package/docs/arrLookupByMaxmin.mjs.html +1 -1
  25. package/docs/arrMax.mjs.html +1 -1
  26. package/docs/arrMin.mjs.html +1 -1
  27. package/docs/arrMulti.mjs.html +1 -1
  28. package/docs/arrNorm.mjs.html +1 -1
  29. package/docs/arrProduct.mjs.html +1 -1
  30. package/docs/arrPull.mjs.html +1 -1
  31. package/docs/arrPullAt.mjs.html +1 -1
  32. package/docs/arrReduce.mjs.html +1 -1
  33. package/docs/arrReverse.mjs.html +1 -1
  34. package/docs/arrSep.mjs.html +1 -1
  35. package/docs/arrSort.mjs.html +1 -1
  36. package/docs/asind.mjs.html +1 -1
  37. package/docs/atan2d.mjs.html +1 -1
  38. package/docs/atand.mjs.html +1 -1
  39. package/docs/attstr.mjs.html +1 -1
  40. package/docs/b642obj.mjs.html +1 -1
  41. package/docs/b642str.mjs.html +1 -1
  42. package/docs/b642u16arr.mjs.html +1 -1
  43. package/docs/b642u8arr.mjs.html +1 -1
  44. package/docs/binstr.mjs.html +1 -1
  45. package/docs/blob2ab.mjs.html +1 -1
  46. package/docs/blob2b64.mjs.html +1 -1
  47. package/docs/blob2str.mjs.html +1 -1
  48. package/docs/blob2u8arr.mjs.html +1 -1
  49. package/docs/blobs2b64s.mjs.html +1 -1
  50. package/docs/blobs2u8arrs.mjs.html +1 -1
  51. package/docs/bodyLog.mjs.html +1 -1
  52. package/docs/browserView.mjs.html +1 -1
  53. package/docs/browserViewFromBlob.mjs.html +1 -1
  54. package/docs/browserViewFromText.mjs.html +1 -1
  55. package/docs/browserViewFromU8arr.mjs.html +1 -1
  56. package/docs/bs2u8arr.mjs.html +1 -1
  57. package/docs/bufRead.mjs.html +1 -1
  58. package/docs/bufReadDbl.mjs.html +1 -1
  59. package/docs/bufWrite.mjs.html +1 -1
  60. package/docs/bufWriteDbl.mjs.html +1 -1
  61. package/docs/cache.mjs.html +1 -1
  62. package/docs/cacheBd.mjs.html +1 -1
  63. package/docs/cacheSt.mjs.html +1 -1
  64. package/docs/cbol.mjs.html +1 -1
  65. package/docs/cdbl.mjs.html +1 -1
  66. package/docs/ceil.mjs.html +1 -1
  67. package/docs/cfilesize.mjs.html +1 -1
  68. package/docs/cfinancial.mjs.html +1 -1
  69. package/docs/cint.mjs.html +1 -1
  70. package/docs/clearXSS.mjs.html +1 -1
  71. package/docs/clearXSSDyn.mjs.html +1 -1
  72. package/docs/color.mjs.html +1 -1
  73. package/docs/composeToTree.mjs.html +1 -1
  74. package/docs/convertToTree.mjs.html +1 -1
  75. package/docs/copyStrToClipboard.mjs.html +1 -1
  76. package/docs/cosd.mjs.html +1 -1
  77. package/docs/cotd.mjs.html +1 -1
  78. package/docs/createExcelWorkbook.mjs.html +1 -1
  79. package/docs/cscd.mjs.html +1 -1
  80. package/docs/cstr.mjs.html +1 -1
  81. package/docs/day2cht.mjs.html +1 -1
  82. package/docs/debounce.mjs.html +1 -1
  83. package/docs/delay.mjs.html +1 -1
  84. package/docs/dig.mjs.html +1 -1
  85. package/docs/digExp.mjs.html +1 -1
  86. package/docs/domAlert.mjs.html +1 -1
  87. package/docs/domAppend.mjs.html +1 -1
  88. package/docs/domCancelEvent.mjs.html +1 -1
  89. package/docs/domCompareText.mjs.html +1 -1
  90. package/docs/domConvertToPic.mjs.html +1 -1
  91. package/docs/domConvertToPicDyn.mjs.html +1 -1
  92. package/docs/domDetect.mjs.html +1 -1
  93. package/docs/domDrag.mjs.html +1 -1
  94. package/docs/domDragBarAndScroll.mjs.html +1 -1
  95. package/docs/domDragPreview.mjs.html +1 -1
  96. package/docs/domDropFiles.mjs.html +1 -1
  97. package/docs/domElementsFromPoint.mjs.html +1 -1
  98. package/docs/domFadeIn.mjs.html +1 -1
  99. package/docs/domFadeOut.mjs.html +1 -1
  100. package/docs/domFind.mjs.html +1 -1
  101. package/docs/domFinds.mjs.html +1 -1
  102. package/docs/domGetAttr.mjs.html +1 -1
  103. package/docs/domGetBoudRect.mjs.html +1 -1
  104. package/docs/domGetBoudRectRefSelf.mjs.html +1 -1
  105. package/docs/domGetFileAccept.mjs.html +1 -1
  106. package/docs/domGetFiles.mjs.html +1 -1
  107. package/docs/domGetParents.mjs.html +1 -1
  108. package/docs/domGetPointFromEvent.mjs.html +1 -1
  109. package/docs/domGetScrollableParent.mjs.html +1 -1
  110. package/docs/domGetWindowSize.mjs.html +1 -1
  111. package/docs/domIsClientXYIn.mjs.html +1 -1
  112. package/docs/domIsFocused.mjs.html +1 -1
  113. package/docs/domIsStable.mjs.html +1 -1
  114. package/docs/domIsVisible.mjs.html +1 -1
  115. package/docs/domPrepend.mjs.html +1 -1
  116. package/docs/domRemove.mjs.html +1 -1
  117. package/docs/domRenderMarkdownMind.mjs.html +1 -1
  118. package/docs/domRenderMarkdownMindDyn.mjs.html +1 -1
  119. package/docs/domRipple.mjs.html +1 -1
  120. package/docs/domScrollIntoView.mjs.html +1 -1
  121. package/docs/domScrollTo.mjs.html +1 -1
  122. package/docs/domSetAttr.mjs.html +1 -1
  123. package/docs/domShowImages.mjs.html +1 -1
  124. package/docs/domShowImagesDyn.mjs.html +1 -1
  125. package/docs/domShowInputAndGetFiles.mjs.html +1 -1
  126. package/docs/domShowInputAndGetFilesU8Arrs.mjs.html +1 -1
  127. package/docs/domShowInputDatatime.mjs.html +1 -1
  128. package/docs/domTooltip.mjs.html +1 -1
  129. package/docs/domTriggerEvent.mjs.html +1 -1
  130. package/docs/domVirtualCreate.mjs.html +1 -1
  131. package/docs/domVirtualCreateQueue.mjs.html +1 -1
  132. package/docs/downloadExcelFileFromData.mjs.html +1 -1
  133. package/docs/downloadExcelFileFromDataDyn.mjs.html +1 -1
  134. package/docs/downloadFileFromB64.mjs.html +1 -1
  135. package/docs/downloadFileFromBlob.mjs.html +1 -1
  136. package/docs/downloadFileFromText.mjs.html +1 -1
  137. package/docs/downloadFileFromU8Arr.mjs.html +1 -1
  138. package/docs/dtmapping.mjs.html +1 -1
  139. package/docs/dtpick.mjs.html +1 -1
  140. package/docs/estimateTicks.mjs.html +1 -1
  141. package/docs/evem.mjs.html +1 -1
  142. package/docs/examples/ex-blob2b64.html +1 -1
  143. package/docs/examples/ex-clearXSS.html +1 -1
  144. package/docs/examples/ex-clearXSSDyn.html +1 -1
  145. package/docs/examples/ex-colorConverter.html +1 -1
  146. package/docs/examples/ex-domCompareText.html +1 -1
  147. package/docs/examples/ex-domConvertToPic.html +1 -1
  148. package/docs/examples/ex-domDrag.html +1 -1
  149. package/docs/examples/ex-domDropFiles.html +1 -1
  150. package/docs/examples/ex-domIsVisible.html +1 -1
  151. package/docs/examples/ex-domRenderMarkdownMind.html +1 -1
  152. package/docs/examples/ex-domRenderMarkdownMindDyn.html +1 -1
  153. package/docs/examples/ex-domRipple.html +1 -1
  154. package/docs/examples/ex-domScrollIntoView.html +1 -1
  155. package/docs/examples/ex-domScrollTo.html +1 -1
  156. package/docs/examples/ex-domShowImages.html +1 -1
  157. package/docs/examples/ex-domShowImagesDyn.html +1 -1
  158. package/docs/examples/ex-domShowInputAndGetFiles.html +1 -1
  159. package/docs/examples/ex-domTooltip.html +1 -1
  160. package/docs/examples/ex-getFileHash.html +1 -1
  161. package/docs/examples/ex-getUserAgent.html +1 -1
  162. package/docs/examples/ex-getUserAgentDyn.html +1 -1
  163. package/docs/examples/ex-html2str.html +1 -1
  164. package/docs/examples/ex-obj2u8arr-u8arr2obj.html +1 -1
  165. package/docs/examples/ex-openLink.html +1 -1
  166. package/docs/examples/ex-str2aes-aes2str.html +1 -1
  167. package/docs/examples/ex-str2b64-b642str.html +1 -1
  168. package/docs/examples/ex-strFindFuzz.html +1 -1
  169. package/docs/examples/ex-timeTZ2expire-timeTZ2past.html +1 -1
  170. package/docs/examples/ex-xlsx.html +1 -1
  171. package/docs/examples/ex-xlsxDyn.html +1 -1
  172. package/docs/execJsCode.mjs.html +1 -1
  173. package/docs/execProcess.mjs.html +1 -1
  174. package/docs/execProcessKillPid.mjs.html +1 -1
  175. package/docs/filepathToTree.mjs.html +1 -1
  176. package/docs/files2data.mjs.html +1 -1
  177. package/docs/flattenToConn.mjs.html +1 -1
  178. package/docs/flattenTree.mjs.html +1 -1
  179. package/docs/floor.mjs.html +1 -1
  180. package/docs/fsBuildReadStreamText.mjs.html +1 -1
  181. package/docs/fsBuildWriteStreamText.mjs.html +1 -1
  182. package/docs/fsCleanFolder.mjs.html +1 -1
  183. package/docs/fsCleanFolderCore.mjs.html +1 -1
  184. package/docs/fsCopyFile.mjs.html +1 -1
  185. package/docs/fsCopyFileCore.mjs.html +1 -1
  186. package/docs/fsCopyFolder.mjs.html +1 -1
  187. package/docs/fsCopyFolderCore.mjs.html +1 -1
  188. package/docs/fsCreateFile.mjs.html +1 -1
  189. package/docs/fsCreateFileCore.mjs.html +1 -1
  190. package/docs/fsCreateFolder.mjs.html +1 -1
  191. package/docs/fsCreateFolderCore.mjs.html +1 -1
  192. package/docs/fsDeleteFile.mjs.html +1 -1
  193. package/docs/fsDeleteFileCore.mjs.html +1 -1
  194. package/docs/fsDeleteFileSafe.mjs.html +1 -1
  195. package/docs/fsDeleteFileSafeCore.mjs.html +1 -1
  196. package/docs/fsDeleteFolder.mjs.html +1 -1
  197. package/docs/fsDeleteFolderCore.mjs.html +1 -1
  198. package/docs/fsDeleteFolderSafe.mjs.html +1 -1
  199. package/docs/fsDeleteFolderSafeCore.mjs.html +1 -1
  200. package/docs/fsDownloadFile.mjs.html +1 -1
  201. package/docs/fsDownloadFileCore.mjs.html +1 -1
  202. package/docs/fsEvem.mjs.html +1 -1
  203. package/docs/fsExists.mjs.html +1 -1
  204. package/docs/fsExistsCore.mjs.html +1 -1
  205. package/docs/fsGetFileBasicHash.mjs.html +1 -1
  206. package/docs/fsGetFileBasicHashCore.mjs.html +1 -1
  207. package/docs/fsGetFileHash.mjs.html +1 -1
  208. package/docs/fsGetFileHashCore.mjs.html +1 -1
  209. package/docs/fsGetFileXxHash.mjs.html +1 -1
  210. package/docs/fsGetFileXxHashCore.mjs.html +1 -1
  211. package/docs/fsGetFilesInFolder.mjs.html +1 -1
  212. package/docs/fsGetFilesInFolderCore.mjs.html +1 -1
  213. package/docs/fsGetFilesWithHashInFolder.mjs.html +1 -1
  214. package/docs/fsGetFilesWithHashInFolderCore.mjs.html +1 -1
  215. package/docs/fsGetFolderBasicHash.mjs.html +1 -1
  216. package/docs/fsGetFolderBasicHashCore.mjs.html +1 -1
  217. package/docs/fsGetFoldersInFolder.mjs.html +1 -1
  218. package/docs/fsGetFoldersInFolderCore.mjs.html +1 -1
  219. package/docs/fsIsFile.mjs.html +1 -1
  220. package/docs/fsIsFileCore.mjs.html +1 -1
  221. package/docs/fsIsFolder.mjs.html +1 -1
  222. package/docs/fsIsFolderCore.mjs.html +1 -1
  223. package/docs/fsMergeFiles.mjs.html +1 -1
  224. package/docs/fsMergeFilesCore.mjs.html +1 -1
  225. package/docs/fsReadJson.mjs.html +1 -1
  226. package/docs/fsReadText.mjs.html +1 -1
  227. package/docs/fsReadTextCore.mjs.html +1 -1
  228. package/docs/fsRenameFile.mjs.html +1 -1
  229. package/docs/fsRenameFileCore.mjs.html +1 -1
  230. package/docs/fsRenameFolder.mjs.html +1 -1
  231. package/docs/fsRenameFolderCore.mjs.html +1 -1
  232. package/docs/fsSrlog.mjs.html +1 -1
  233. package/docs/fsSyncFolder.mjs.html +1 -1
  234. package/docs/fsSyncFolderCore.mjs.html +1 -1
  235. package/docs/fsTask.mjs.html +1 -1
  236. package/docs/fsTaskCp.mjs.html +1 -1
  237. package/docs/fsTreeFolder.mjs.html +1 -1
  238. package/docs/fsTreeFolderCore.mjs.html +1 -1
  239. package/docs/fsTreeFolderWithHash.mjs.html +1 -1
  240. package/docs/fsTreeFolderWithHashCore.mjs.html +1 -1
  241. package/docs/fsWatchFile.mjs.html +1 -1
  242. package/docs/fsWatchFolder.mjs.html +1 -1
  243. package/docs/fsWriteJson.mjs.html +1 -1
  244. package/docs/fsWriteText.mjs.html +1 -1
  245. package/docs/fsWriteTextCore.mjs.html +1 -1
  246. package/docs/genGradientColor.mjs.html +1 -1
  247. package/docs/genID.mjs.html +1 -1
  248. package/docs/genIDSeq.mjs.html +1 -1
  249. package/docs/genPm.mjs.html +1 -1
  250. package/docs/getBufferSize.mjs.html +1 -1
  251. package/docs/getClearPathName.mjs.html +1 -1
  252. package/docs/getCsvStrFromData.mjs.html +1 -1
  253. package/docs/getDataFromExcelFileU8Arr.mjs.html +1 -1
  254. package/docs/getDataFromExcelFileU8ArrDyn.mjs.html +1 -1
  255. package/docs/getEnv.mjs.html +1 -1
  256. package/docs/getErrorMessage.mjs.html +1 -1
  257. package/docs/getExcelU8ArrFromData.mjs.html +1 -1
  258. package/docs/getExcelU8ArrFromWorkbook.mjs.html +1 -1
  259. package/docs/getExcelWorkbookFromData.mjs.html +1 -1
  260. package/docs/getExcelWorkbookFromWorksheet.mjs.html +1 -1
  261. package/docs/getExcelWorksheetFromData.mjs.html +1 -1
  262. package/docs/getFileAccept.mjs.html +1 -1
  263. package/docs/getFileBasicHash.mjs.html +1 -1
  264. package/docs/getFileHash.mjs.html +1 -1
  265. package/docs/getFileName.mjs.html +1 -1
  266. package/docs/getFileNameExt.mjs.html +1 -1
  267. package/docs/getFileTrueName.mjs.html +1 -1
  268. package/docs/getFileType.mjs.html +38 -2
  269. package/docs/getFileXxHash.mjs.html +1 -1
  270. package/docs/getGlobal.mjs.html +1 -1
  271. package/docs/getObjSize.mjs.html +1 -1
  272. package/docs/getPathParent.mjs.html +1 -1
  273. package/docs/getTimeBetween.mjs.html +1 -1
  274. package/docs/getTimeFromUnit.mjs.html +1 -1
  275. package/docs/getTimeHp.mjs.html +1 -1
  276. package/docs/getTimeObject.mjs.html +1 -1
  277. package/docs/getTimeRange.mjs.html +1 -1
  278. package/docs/getUserAgent.mjs.html +1 -1
  279. package/docs/getUserAgentDyn.mjs.html +1 -1
  280. package/docs/getltdtkeys.mjs.html +1 -1
  281. package/docs/haskey.mjs.html +1 -1
  282. package/docs/html2str.mjs.html +1 -1
  283. package/docs/htmlDecode.mjs.html +1 -1
  284. package/docs/htmlEncode.mjs.html +1 -1
  285. package/docs/importResources.mjs.html +1 -1
  286. package/docs/index.html +1 -1
  287. package/docs/interp1.mjs.html +1 -1
  288. package/docs/isDate.mjs.html +1 -1
  289. package/docs/isDev.mjs.html +1 -1
  290. package/docs/isEle.mjs.html +1 -1
  291. package/docs/isEleExistByID.mjs.html +1 -1
  292. package/docs/isEmail.mjs.html +1 -1
  293. package/docs/isErr.mjs.html +1 -1
  294. package/docs/isIE.mjs.html +1 -1
  295. package/docs/isNarrow.mjs.html +1 -1
  296. package/docs/isStrHasCapital.mjs.html +1 -1
  297. package/docs/isStrHasLetter.mjs.html +1 -1
  298. package/docs/isStrHasLowerCase.mjs.html +1 -1
  299. package/docs/isStrHasNumber.mjs.html +1 -1
  300. package/docs/isStrHasSpace.mjs.html +1 -1
  301. package/docs/isStrHasSymbol.mjs.html +1 -1
  302. package/docs/isUserIdentify.mjs.html +1 -1
  303. package/docs/isUserName.mjs.html +1 -1
  304. package/docs/isUserPw.mjs.html +1 -1
  305. package/docs/isWindow.mjs.html +1 -1
  306. package/docs/isab.mjs.html +1 -1
  307. package/docs/isarr.mjs.html +1 -1
  308. package/docs/isarr0.mjs.html +1 -1
  309. package/docs/isbigint.mjs.html +1 -1
  310. package/docs/isblob.mjs.html +1 -1
  311. package/docs/isbol.mjs.html +1 -1
  312. package/docs/isday.mjs.html +1 -1
  313. package/docs/isearr.mjs.html +1 -1
  314. package/docs/iseobj.mjs.html +1 -1
  315. package/docs/iser.mjs.html +1 -1
  316. package/docs/isernot.mjs.html +1 -1
  317. package/docs/isestr.mjs.html +1 -1
  318. package/docs/isfile.mjs.html +1 -1
  319. package/docs/isfun.mjs.html +1 -1
  320. package/docs/isint.mjs.html +1 -1
  321. package/docs/ismonth.mjs.html +1 -1
  322. package/docs/isn0int.mjs.html +1 -1
  323. package/docs/isn0num.mjs.html +1 -1
  324. package/docs/isnan.mjs.html +1 -1
  325. package/docs/isnbr.mjs.html +1 -1
  326. package/docs/isnint.mjs.html +1 -1
  327. package/docs/isnnum.mjs.html +1 -1
  328. package/docs/isnull.mjs.html +1 -1
  329. package/docs/isnum.mjs.html +1 -1
  330. package/docs/isobj.mjs.html +1 -1
  331. package/docs/isobj0.mjs.html +1 -1
  332. package/docs/isp0int.mjs.html +1 -1
  333. package/docs/isp0num.mjs.html +1 -1
  334. package/docs/ispint.mjs.html +1 -1
  335. package/docs/ispm.mjs.html +1 -1
  336. package/docs/ispnum.mjs.html +1 -1
  337. package/docs/isstr.mjs.html +1 -1
  338. package/docs/isstr0.mjs.html +1 -1
  339. package/docs/istime.mjs.html +1 -1
  340. package/docs/istimeTZ.mjs.html +1 -1
  341. package/docs/istimems.mjs.html +1 -1
  342. package/docs/istimemsTZ.mjs.html +1 -1
  343. package/docs/isu16arr.mjs.html +1 -1
  344. package/docs/isu8arr.mjs.html +1 -1
  345. package/docs/isundefined.mjs.html +1 -1
  346. package/docs/j2o.mjs.html +1 -1
  347. package/docs/judge.mjs.html +1 -1
  348. package/docs/keysmat2ltdt.mjs.html +1 -1
  349. package/docs/ltdt2vrtsable.mjs.html +1 -1
  350. package/docs/ltdtDiff.mjs.html +1 -1
  351. package/docs/ltdtDiffByKey.mjs.html +1 -1
  352. package/docs/ltdtkeys2mat.mjs.html +1 -1
  353. package/docs/ltdtkeysheads2mat.mjs.html +1 -1
  354. package/docs/ltdtmapping.mjs.html +1 -1
  355. package/docs/ltdtmerge.mjs.html +1 -1
  356. package/docs/ltdtpick.mjs.html +1 -1
  357. package/docs/ltdtpull.mjs.html +1 -1
  358. package/docs/mat2ltdt.mjs.html +1 -1
  359. package/docs/matConcat.mjs.html +1 -1
  360. package/docs/matDiff.mjs.html +1 -1
  361. package/docs/matat.mjs.html +1 -1
  362. package/docs/now2str.mjs.html +1 -1
  363. package/docs/now2strp.mjs.html +1 -1
  364. package/docs/nowDay2str.mjs.html +1 -1
  365. package/docs/nowms2str.mjs.html +1 -1
  366. package/docs/nowms2strp.mjs.html +1 -1
  367. package/docs/o2j.mjs.html +1 -1
  368. package/docs/obj2b64.mjs.html +1 -1
  369. package/docs/obj2pb64.mjs.html +1 -1
  370. package/docs/obj2str.mjs.html +1 -1
  371. package/docs/obj2stru8arr.mjs.html +1 -1
  372. package/docs/obj2u8arr.mjs.html +1 -1
  373. package/docs/objSortBy.mjs.html +1 -1
  374. package/docs/objSortByKeys.mjs.html +1 -1
  375. package/docs/oo.mjs.html +1 -1
  376. package/docs/openLink.mjs.html +1 -1
  377. package/docs/pb642obj.mjs.html +1 -1
  378. package/docs/pmChain.mjs.html +1 -1
  379. package/docs/pmConvertResolve.mjs.html +1 -1
  380. package/docs/pmDebounce.mjs.html +1 -1
  381. package/docs/pmHook.mjs.html +1 -1
  382. package/docs/pmHookReject.mjs.html +1 -1
  383. package/docs/pmIni.mjs.html +1 -1
  384. package/docs/pmInvResolve.mjs.html +1 -1
  385. package/docs/pmKeyMutex.mjs.html +1 -1
  386. package/docs/pmMap.mjs.html +7 -1
  387. package/docs/pmQueue.mjs.html +1 -1
  388. package/docs/pmSeries.mjs.html +1 -1
  389. package/docs/pmThrottle.mjs.html +1 -1
  390. package/docs/preciseNum.mjs.html +1 -1
  391. package/docs/pseudoRandom.mjs.html +1 -1
  392. package/docs/pseudoRandomIntRange.mjs.html +1 -1
  393. package/docs/pseudoRandomIntsNdpRange.mjs.html +1 -1
  394. package/docs/pseudoRandomIntsRange.mjs.html +1 -1
  395. package/docs/pseudoRandomRange.mjs.html +1 -1
  396. package/docs/pseudoRandomsRange.mjs.html +1 -1
  397. package/docs/queue.mjs.html +1 -1
  398. package/docs/random.mjs.html +1 -1
  399. package/docs/randomIntRange.mjs.html +1 -1
  400. package/docs/randomIntsNdpRange.mjs.html +1 -1
  401. package/docs/randomIntsRange.mjs.html +1 -1
  402. package/docs/randomRange.mjs.html +1 -1
  403. package/docs/randomsRange.mjs.html +1 -1
  404. package/docs/rang.mjs.html +1 -1
  405. package/docs/rep.mjs.html +1 -1
  406. package/docs/repObj.mjs.html +1 -1
  407. package/docs/replace.mjs.html +1 -1
  408. package/docs/replaceObj.mjs.html +1 -1
  409. package/docs/replacePlus.mjs.html +1 -1
  410. package/docs/round.mjs.html +1 -1
  411. package/docs/secd.mjs.html +1 -1
  412. package/docs/sep.mjs.html +1 -1
  413. package/docs/sepInt.mjs.html +1 -1
  414. package/docs/setIntervalHp.mjs.html +1 -1
  415. package/docs/setTimeoutHp.mjs.html +1 -1
  416. package/docs/sind.mjs.html +1 -1
  417. package/docs/split.mjs.html +1 -1
  418. package/docs/str2aes.mjs.html +1 -1
  419. package/docs/str2b64.mjs.html +1 -1
  420. package/docs/str2hint.mjs.html +1 -1
  421. package/docs/str2md5.mjs.html +1 -1
  422. package/docs/str2obj.mjs.html +1 -1
  423. package/docs/str2sha512.mjs.html +1 -1
  424. package/docs/str2u8arr.mjs.html +1 -1
  425. package/docs/strCompare.mjs.html +1 -1
  426. package/docs/strDiff.mjs.html +1 -1
  427. package/docs/strDiffToHtml.mjs.html +1 -1
  428. package/docs/strFindFuzz.mjs.html +1 -1
  429. package/docs/strFindSimilar.mjs.html +1 -1
  430. package/docs/strdelleft.mjs.html +1 -1
  431. package/docs/strdelright.mjs.html +1 -1
  432. package/docs/strleft.mjs.html +1 -1
  433. package/docs/strmid.mjs.html +1 -1
  434. package/docs/strright.mjs.html +1 -1
  435. package/docs/stru8arr2obj.mjs.html +1 -1
  436. package/docs/tand.mjs.html +1 -1
  437. package/docs/time2day.mjs.html +1 -1
  438. package/docs/time2hour.mjs.html +1 -1
  439. package/docs/time2min.mjs.html +1 -1
  440. package/docs/timeTZ2day.mjs.html +1 -1
  441. package/docs/timeTZ2expire.mjs.html +1 -1
  442. package/docs/timeTZ2hour.mjs.html +1 -1
  443. package/docs/timeTZ2min.mjs.html +1 -1
  444. package/docs/timeTZ2past.mjs.html +1 -1
  445. package/docs/timems2day.mjs.html +1 -1
  446. package/docs/timems2hour.mjs.html +1 -1
  447. package/docs/timems2min.mjs.html +1 -1
  448. package/docs/timems2time.mjs.html +1 -1
  449. package/docs/timemsTZ2day.mjs.html +1 -1
  450. package/docs/timemsTZ2expire.mjs.html +1 -1
  451. package/docs/timemsTZ2hour.mjs.html +1 -1
  452. package/docs/timemsTZ2min.mjs.html +1 -1
  453. package/docs/timemsTZ2past.mjs.html +1 -1
  454. package/docs/timemsTZ2time.mjs.html +1 -1
  455. package/docs/treeObj.mjs.html +1 -1
  456. package/docs/treeToFilepath.mjs.html +1 -1
  457. package/docs/trim.mjs.html +1 -1
  458. package/docs/u16arr2b64.mjs.html +1 -1
  459. package/docs/u16arr2u8arr.mjs.html +1 -1
  460. package/docs/u8arr2ab.mjs.html +1 -1
  461. package/docs/u8arr2b64.mjs.html +1 -1
  462. package/docs/u8arr2blob.mjs.html +1 -1
  463. package/docs/u8arr2bs.mjs.html +1 -1
  464. package/docs/u8arr2obj.mjs.html +1 -1
  465. package/docs/u8arr2str.mjs.html +1 -1
  466. package/docs/u8arr2u16arr.mjs.html +1 -1
  467. package/docs/urlParse.mjs.html +1 -1
  468. package/docs/verifyValue.mjs.html +1 -1
  469. package/docs/waitFun.mjs.html +1 -1
  470. package/docs/wsemi.html +3 -3
  471. package/package.json +3 -3
  472. package/src/getFileType.mjs +37 -1
  473. package/src/pmMap.mjs +6 -0
  474. package/test/pmMap.test.mjs +48 -0
  475. package/toolfp/dist/wsemip.umd.js +2 -2
  476. package/toolparfor/dist/wpf.umd.js +2 -2
  477. package/toolparfor/dist/wpf_pmSeries.umd.js +1 -1
package/dist/wsemi.umd.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * wsemi v1.8.61
2
+ * wsemi v1.8.63
3
3
  * (c) 2018-2021 yuda-lyu(semisphere)
4
4
  * Released under the MIT License.
5
5
  */
@@ -12,7 +12,7 @@
12
12
  * Copyright (c) 2025 Michael Mclaughlin <M8ch88l@gmail.com>
13
13
  * MIT Licence
14
14
  */
15
- var Bs,Es,Cs=9e15,xs=1e9,Ds="0123456789abcdef",Fs="2.3025850929940456840179914546843642076011014886287729760333279009675726096773524802359972050895982983419677840422862486334095254650828067566662873690987816894829072083255546808437998948262331985283935053089653777326288461633662222876982198867465436674744042432743651550489343149393914796194044002221051017141748003688084012647080685567743216228355220114804663715659121373450747856947683463616792101806445070648000277502684916746550586856935673420670581136429224554405758925724208241314695689016758940256776311356919292033376587141660230105703089634572075440370847469940168269282808481184289314848524948644871927809676271275775397027668605952496716674183485704422507197965004714951050492214776567636938662976979522110718264549734772662425709429322582798502585509785265383207606726317164309505995087807523710333101197857547331541421808427543863591778117054309827482385045648019095610299291824318237525357709750539565187697510374970888692180205189339507238539205144634197265287286965110862571492198849978748873771345686209167058",Qs="3.1415926535897932384626433832795028841971693993751058209749445923078164062862089986280348253421170679821480865132823066470938446095505822317253594081284811174502841027019385211055596446229489549303819644288109756659334461284756482337867831652712019091456485669234603486104543266482133936072602491412737245870066063155881748815209209628292540917153643678925903600113305305488204665213841469519415116094330572703657595919530921861173819326117931051185480744623799627495673518857527248912279381830119491298336733624406566430860213949463952247371907021798609437027705392171762931767523846748184676694051320005681271452635608277857713427577896091736371787214684409012249534301465495853710507922796892589235420199561121290219608640344181598136297747713099605187072113499999983729780499510597317328160963185950244594553469083026425223082533446850352619311881710100031378387528865875332083814206171776691473035982534904287554687311595628638823537875937519577818577805321712268066130019278766111959092164201989380952572010654858632789",Ss={precision:20,rounding:4,modulo:1,toExpNeg:-7,toExpPos:21,minE:-Cs,maxE:Cs,crypto:!1},ks=!0,Ns="[DecimalError] ",qs=Ns+"Invalid argument: ",Ms=Ns+"Precision limit exceeded",Hs=Ns+"crypto unavailable",Ls="[object Decimal]",Us=Math.floor,Rs=Math.pow,Os=/^0b([01]+(\.[01]*)?|\.[01]+)(p[+-]?\d+)?$/i,Ts=/^0x([0-9a-f]+(\.[0-9a-f]*)?|\.[0-9a-f]+)(p[+-]?\d+)?$/i,Ys=/^0o([0-7]+(\.[0-7]*)?|\.[0-7]+)(p[+-]?\d+)?$/i,js=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,Gs=1e7,Js=Fs.length-1,zs=Qs.length-1,Vs={toStringTag:Ls};function Ps(e){var t,r,n,i=e.length-1,o="",a=e[0];if(i>0){for(o+=a,t=1;t<i;t++)(r=7-(n=e[t]+"").length)&&(o+=ic(r)),o+=n;(r=7-(n=(a=e[t])+"").length)&&(o+=ic(r))}else if(0===a)return"0";for(;a%10==0;)a/=10;return o+a}function Xs(e,t,r){if(e!==~~e||e<t||e>r)throw Error(qs+e)}function _s(e,t,r,n){var i,o,a,s;for(o=e[0];o>=10;o/=10)--t;return--t<0?(t+=7,i=0):(i=Math.ceil((t+1)/7),t%=7),o=Rs(10,7-t),s=e[i]%o|0,null==n?t<3?(0==t?s=s/100|0:1==t&&(s=s/10|0),a=r<4&&99999==s||r>3&&49999==s||5e4==s||0==s):a=(r<4&&s+1==o||r>3&&s+1==o/2)&&(e[i+1]/o/100|0)==Rs(10,t-2)-1||(s==o/2||0==s)&&!(e[i+1]/o/100|0):t<4?(0==t?s=s/1e3|0:1==t?s=s/100|0:2==t&&(s=s/10|0),a=(n||r<4)&&9999==s||!n&&r>3&&4999==s):a=((n||r<4)&&s+1==o||!n&&r>3&&s+1==o/2)&&(e[i+1]/o/1e3|0)==Rs(10,t-3)-1,a}function Ws(e,t,r){for(var n,i,o=[0],a=0,s=e.length;a<s;){for(i=o.length;i--;)o[i]*=t;for(o[0]+=Ds.indexOf(e.charAt(a++)),n=0;n<o.length;n++)o[n]>r-1&&(void 0===o[n+1]&&(o[n+1]=0),o[n+1]+=o[n]/r|0,o[n]%=r)}return o.reverse()}Vs.absoluteValue=Vs.abs=function(){var e=new this.constructor(this);return e.s<0&&(e.s=1),$s(e)},Vs.ceil=function(){return $s(new this.constructor(this),this.e+1,2)},Vs.clampedTo=Vs.clamp=function(e,t){var r=this,n=r.constructor;if(e=new n(e),t=new n(t),!e.s||!t.s)return new n(NaN);if(e.gt(t))throw Error(qs+t);return r.cmp(e)<0?e:r.cmp(t)>0?t:new n(r)},Vs.comparedTo=Vs.cmp=function(e){var t,r,n,i,o=this,a=o.d,s=(e=new o.constructor(e)).d,c=o.s,l=e.s;if(!a||!s)return c&&l?c!==l?c:a===s?0:!a^c<0?1:-1:NaN;if(!a[0]||!s[0])return a[0]?c:s[0]?-l:0;if(c!==l)return c;if(o.e!==e.e)return o.e>e.e^c<0?1:-1;for(t=0,r=(n=a.length)<(i=s.length)?n:i;t<r;++t)if(a[t]!==s[t])return a[t]>s[t]^c<0?1:-1;return n===i?0:n>i^c<0?1:-1},Vs.cosine=Vs.cos=function(){var e,t,r=this,n=r.constructor;return r.d?r.d[0]?(e=n.precision,t=n.rounding,n.precision=e+Math.max(r.e,r.sd())+7,n.rounding=1,r=function(e,t){var r,n,i;if(t.isZero())return t;n=t.d.length,n<32?i=(1/pc(4,r=Math.ceil(n/3))).toString():(r=16,i="2.3283064365386962890625e-10");e.precision+=r,t=gc(e,1,t.times(i),new e(1));for(var o=r;o--;){var a=t.times(t);t=a.times(a).minus(a).times(8).plus(1)}return e.precision-=r,t}(n,hc(n,r)),n.precision=e,n.rounding=t,$s(2==Es||3==Es?r.neg():r,e,t,!0)):new n(1):new n(NaN)},Vs.cubeRoot=Vs.cbrt=function(){var e,t,r,n,i,o,a,s,c,l,u=this,f=u.constructor;if(!u.isFinite()||u.isZero())return new f(u);for(ks=!1,(o=u.s*Rs(u.s*u,1/3))&&Math.abs(o)!=1/0?n=new f(o.toString()):(r=Ps(u.d),(o=((e=u.e)-r.length+1)%3)&&(r+=1==o||-2==o?"0":"00"),o=Rs(r,1/3),e=Us((e+1)/3)-(e%3==(e<0?-1:2)),(n=new f(r=o==1/0?"5e"+e:(r=o.toExponential()).slice(0,r.indexOf("e")+1)+e)).s=u.s),a=(e=f.precision)+3;;)if(l=(c=(s=n).times(s).times(s)).plus(u),n=Ks(l.plus(u).times(s),l.plus(c),a+2,1),Ps(s.d).slice(0,a)===(r=Ps(n.d)).slice(0,a)){if("9999"!=(r=r.slice(a-3,a+1))&&(i||"4999"!=r)){+r&&(+r.slice(1)||"5"!=r.charAt(0))||($s(n,e+1,1),t=!n.times(n).times(n).eq(u));break}if(!i&&($s(s,e+1,0),s.times(s).times(s).eq(u))){n=s;break}a+=4,i=1}return ks=!0,$s(n,e,f.rounding,t)},Vs.decimalPlaces=Vs.dp=function(){var e,t=this.d,r=NaN;if(t){if(r=7*((e=t.length-1)-Us(this.e/7)),e=t[e])for(;e%10==0;e/=10)r--;r<0&&(r=0)}return r},Vs.dividedBy=Vs.div=function(e){return Ks(this,new this.constructor(e))},Vs.dividedToIntegerBy=Vs.divToInt=function(e){var t=this.constructor;return $s(Ks(this,new t(e),0,1,1),t.precision,t.rounding)},Vs.equals=Vs.eq=function(e){return 0===this.cmp(e)},Vs.floor=function(){return $s(new this.constructor(this),this.e+1,3)},Vs.greaterThan=Vs.gt=function(e){return this.cmp(e)>0},Vs.greaterThanOrEqualTo=Vs.gte=function(e){var t=this.cmp(e);return 1==t||0===t},Vs.hyperbolicCosine=Vs.cosh=function(){var e,t,r,n,i,o=this,a=o.constructor,s=new a(1);if(!o.isFinite())return new a(o.s?1/0:NaN);if(o.isZero())return s;r=a.precision,n=a.rounding,a.precision=r+Math.max(o.e,o.sd())+4,a.rounding=1,(i=o.d.length)<32?t=(1/pc(4,e=Math.ceil(i/3))).toString():(e=16,t="2.3283064365386962890625e-10"),o=gc(a,1,o.times(t),new a(1),!0);for(var c,l=e,u=new a(8);l--;)c=o.times(o),o=s.minus(c.times(u.minus(c.times(u))));return $s(o,a.precision=r,a.rounding=n,!0)},Vs.hyperbolicSine=Vs.sinh=function(){var e,t,r,n,i=this,o=i.constructor;if(!i.isFinite()||i.isZero())return new o(i);if(t=o.precision,r=o.rounding,o.precision=t+Math.max(i.e,i.sd())+4,o.rounding=1,(n=i.d.length)<3)i=gc(o,2,i,i,!0);else{e=(e=1.4*Math.sqrt(n))>16?16:0|e,i=gc(o,2,i=i.times(1/pc(5,e)),i,!0);for(var a,s=new o(5),c=new o(16),l=new o(20);e--;)a=i.times(i),i=i.times(s.plus(a.times(c.times(a).plus(l))))}return o.precision=t,o.rounding=r,$s(i,t,r,!0)},Vs.hyperbolicTangent=Vs.tanh=function(){var e,t,r=this,n=r.constructor;return r.isFinite()?r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+7,n.rounding=1,Ks(r.sinh(),r.cosh(),n.precision=e,n.rounding=t)):new n(r.s)},Vs.inverseCosine=Vs.acos=function(){var e=this,t=e.constructor,r=e.abs().cmp(1),n=t.precision,i=t.rounding;return-1!==r?0===r?e.isNeg()?rc(t,n,i):new t(0):new t(NaN):e.isZero()?rc(t,n+4,i).times(.5):(t.precision=n+6,t.rounding=1,e=new t(1).minus(e).div(e.plus(1)).sqrt().atan(),t.precision=n,t.rounding=i,e.times(2))},Vs.inverseHyperbolicCosine=Vs.acosh=function(){var e,t,r=this,n=r.constructor;return r.lte(1)?new n(r.eq(1)?0:NaN):r.isFinite()?(e=n.precision,t=n.rounding,n.precision=e+Math.max(Math.abs(r.e),r.sd())+4,n.rounding=1,ks=!1,r=r.times(r).minus(1).sqrt().plus(r),ks=!0,n.precision=e,n.rounding=t,r.ln()):new n(r)},Vs.inverseHyperbolicSine=Vs.asinh=function(){var e,t,r=this,n=r.constructor;return!r.isFinite()||r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+2*Math.max(Math.abs(r.e),r.sd())+6,n.rounding=1,ks=!1,r=r.times(r).plus(1).sqrt().plus(r),ks=!0,n.precision=e,n.rounding=t,r.ln())},Vs.inverseHyperbolicTangent=Vs.atanh=function(){var e,t,r,n,i=this,o=i.constructor;return i.isFinite()?i.e>=0?new o(i.abs().eq(1)?i.s/0:i.isZero()?i:NaN):(e=o.precision,t=o.rounding,n=i.sd(),Math.max(n,e)<2*-i.e-1?$s(new o(i),e,t,!0):(o.precision=r=n-i.e,i=Ks(i.plus(1),new o(1).minus(i),r+e,1),o.precision=e+4,o.rounding=1,i=i.ln(),o.precision=e,o.rounding=t,i.times(.5))):new o(NaN)},Vs.inverseSine=Vs.asin=function(){var e,t,r,n,i=this,o=i.constructor;return i.isZero()?new o(i):(t=i.abs().cmp(1),r=o.precision,n=o.rounding,-1!==t?0===t?((e=rc(o,r+4,n).times(.5)).s=i.s,e):new o(NaN):(o.precision=r+6,o.rounding=1,i=i.div(new o(1).minus(i.times(i)).sqrt().plus(1)).atan(),o.precision=r,o.rounding=n,i.times(2)))},Vs.inverseTangent=Vs.atan=function(){var e,t,r,n,i,o,a,s,c,l=this,u=l.constructor,f=u.precision,d=u.rounding;if(l.isFinite()){if(l.isZero())return new u(l);if(l.abs().eq(1)&&f+4<=zs)return(a=rc(u,f+4,d).times(.25)).s=l.s,a}else{if(!l.s)return new u(NaN);if(f+4<=zs)return(a=rc(u,f+4,d).times(.5)).s=l.s,a}for(u.precision=s=f+10,u.rounding=1,e=r=Math.min(28,s/7+2|0);e;--e)l=l.div(l.times(l).plus(1).sqrt().plus(1));for(ks=!1,t=Math.ceil(s/7),n=1,c=l.times(l),a=new u(l),i=l;-1!==e;)if(i=i.times(c),o=a.minus(i.div(n+=2)),i=i.times(c),void 0!==(a=o.plus(i.div(n+=2))).d[t])for(e=t;a.d[e]===o.d[e]&&e--;);return r&&(a=a.times(2<<r-1)),ks=!0,$s(a,u.precision=f,u.rounding=d,!0)},Vs.isFinite=function(){return!!this.d},Vs.isInteger=Vs.isInt=function(){return!!this.d&&Us(this.e/7)>this.d.length-2},Vs.isNaN=function(){return!this.s},Vs.isNegative=Vs.isNeg=function(){return this.s<0},Vs.isPositive=Vs.isPos=function(){return this.s>0},Vs.isZero=function(){return!!this.d&&0===this.d[0]},Vs.lessThan=Vs.lt=function(e){return this.cmp(e)<0},Vs.lessThanOrEqualTo=Vs.lte=function(e){return this.cmp(e)<1},Vs.logarithm=Vs.log=function(e){var t,r,n,i,o,a,s,c,l=this,u=l.constructor,f=u.precision,d=u.rounding;if(null==e)e=new u(10),t=!0;else{if(r=(e=new u(e)).d,e.s<0||!r||!r[0]||e.eq(1))return new u(NaN);t=e.eq(10)}if(r=l.d,l.s<0||!r||!r[0]||l.eq(1))return new u(r&&!r[0]?-1/0:1!=l.s?NaN:r?0:1/0);if(t)if(r.length>1)o=!0;else{for(i=r[0];i%10==0;)i/=10;o=1!==i}if(ks=!1,a=lc(l,s=f+5),n=t?tc(u,s+10):lc(e,s),_s((c=Ks(a,n,s,1)).d,i=f,d))do{if(a=lc(l,s+=10),n=t?tc(u,s+10):lc(e,s),c=Ks(a,n,s,1),!o){+Ps(c.d).slice(i+1,i+15)+1==1e14&&(c=$s(c,f+1,0));break}}while(_s(c.d,i+=10,d));return ks=!0,$s(c,f,d)},Vs.minus=Vs.sub=function(e){var t,r,n,i,o,a,s,c,l,u,f,d,g=this,p=g.constructor;if(e=new p(e),!g.d||!e.d)return g.s&&e.s?g.d?e.s=-e.s:e=new p(e.d||g.s!==e.s?g:NaN):e=new p(NaN),e;if(g.s!=e.s)return e.s=-e.s,g.plus(e);if(l=g.d,d=e.d,s=p.precision,c=p.rounding,!l[0]||!d[0]){if(d[0])e.s=-e.s;else{if(!l[0])return new p(3===c?-0:0);e=new p(g)}return ks?$s(e,s,c):e}if(r=Us(e.e/7),u=Us(g.e/7),l=l.slice(),o=u-r){for((f=o<0)?(t=l,o=-o,a=d.length):(t=d,r=u,a=l.length),o>(n=Math.max(Math.ceil(s/7),a)+2)&&(o=n,t.length=1),t.reverse(),n=o;n--;)t.push(0);t.reverse()}else{for((f=(n=l.length)<(a=d.length))&&(a=n),n=0;n<a;n++)if(l[n]!=d[n]){f=l[n]<d[n];break}o=0}for(f&&(t=l,l=d,d=t,e.s=-e.s),a=l.length,n=d.length-a;n>0;--n)l[a++]=0;for(n=d.length;n>o;){if(l[--n]<d[n]){for(i=n;i&&0===l[--i];)l[i]=Gs-1;--l[i],l[n]+=Gs}l[n]-=d[n]}for(;0===l[--a];)l.pop();for(;0===l[0];l.shift())--r;return l[0]?(e.d=l,e.e=ec(l,r),ks?$s(e,s,c):e):new p(3===c?-0:0)},Vs.modulo=Vs.mod=function(e){var t,r=this,n=r.constructor;return e=new n(e),!r.d||!e.s||e.d&&!e.d[0]?new n(NaN):!e.d||r.d&&!r.d[0]?$s(new n(r),n.precision,n.rounding):(ks=!1,9==n.modulo?(t=Ks(r,e.abs(),0,3,1)).s*=e.s:t=Ks(r,e,0,n.modulo,1),t=t.times(e),ks=!0,r.minus(t))},Vs.naturalExponential=Vs.exp=function(){return cc(this)},Vs.naturalLogarithm=Vs.ln=function(){return lc(this)},Vs.negated=Vs.neg=function(){var e=new this.constructor(this);return e.s=-e.s,$s(e)},Vs.plus=Vs.add=function(e){var t,r,n,i,o,a,s,c,l,u,f=this,d=f.constructor;if(e=new d(e),!f.d||!e.d)return f.s&&e.s?f.d||(e=new d(e.d||f.s===e.s?f:NaN)):e=new d(NaN),e;if(f.s!=e.s)return e.s=-e.s,f.minus(e);if(l=f.d,u=e.d,s=d.precision,c=d.rounding,!l[0]||!u[0])return u[0]||(e=new d(f)),ks?$s(e,s,c):e;if(o=Us(f.e/7),n=Us(e.e/7),l=l.slice(),i=o-n){for(i<0?(r=l,i=-i,a=u.length):(r=u,n=o,a=l.length),i>(a=(o=Math.ceil(s/7))>a?o+1:a+1)&&(i=a,r.length=1),r.reverse();i--;)r.push(0);r.reverse()}for((a=l.length)-(i=u.length)<0&&(i=a,r=u,u=l,l=r),t=0;i;)t=(l[--i]=l[i]+u[i]+t)/Gs|0,l[i]%=Gs;for(t&&(l.unshift(t),++n),a=l.length;0==l[--a];)l.pop();return e.d=l,e.e=ec(l,n),ks?$s(e,s,c):e},Vs.precision=Vs.sd=function(e){var t,r=this;if(void 0!==e&&e!==!!e&&1!==e&&0!==e)throw Error(qs+e);return r.d?(t=nc(r.d),e&&r.e+1>t&&(t=r.e+1)):t=NaN,t},Vs.round=function(){var e=this,t=e.constructor;return $s(new t(e),e.e+1,t.rounding)},Vs.sine=Vs.sin=function(){var e,t,r=this,n=r.constructor;return r.isFinite()?r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+Math.max(r.e,r.sd())+7,n.rounding=1,r=function(e,t){var r,n=t.d.length;if(n<3)return t.isZero()?t:gc(e,2,t,t);r=(r=1.4*Math.sqrt(n))>16?16:0|r,t=t.times(1/pc(5,r)),t=gc(e,2,t,t);for(var i,o=new e(5),a=new e(16),s=new e(20);r--;)i=t.times(t),t=t.times(o.plus(i.times(a.times(i).minus(s))));return t}(n,hc(n,r)),n.precision=e,n.rounding=t,$s(Es>2?r.neg():r,e,t,!0)):new n(NaN)},Vs.squareRoot=Vs.sqrt=function(){var e,t,r,n,i,o,a=this,s=a.d,c=a.e,l=a.s,u=a.constructor;if(1!==l||!s||!s[0])return new u(!l||l<0&&(!s||s[0])?NaN:s?a:1/0);for(ks=!1,0==(l=Math.sqrt(+a))||l==1/0?(((t=Ps(s)).length+c)%2==0&&(t+="0"),l=Math.sqrt(t),c=Us((c+1)/2)-(c<0||c%2),n=new u(t=l==1/0?"5e"+c:(t=l.toExponential()).slice(0,t.indexOf("e")+1)+c)):n=new u(l.toString()),r=(c=u.precision)+3;;)if(n=(o=n).plus(Ks(a,o,r+2,1)).times(.5),Ps(o.d).slice(0,r)===(t=Ps(n.d)).slice(0,r)){if("9999"!=(t=t.slice(r-3,r+1))&&(i||"4999"!=t)){+t&&(+t.slice(1)||"5"!=t.charAt(0))||($s(n,c+1,1),e=!n.times(n).eq(a));break}if(!i&&($s(o,c+1,0),o.times(o).eq(a))){n=o;break}r+=4,i=1}return ks=!0,$s(n,c,u.rounding,e)},Vs.tangent=Vs.tan=function(){var e,t,r=this,n=r.constructor;return r.isFinite()?r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+10,n.rounding=1,(r=r.sin()).s=1,r=Ks(r,new n(1).minus(r.times(r)).sqrt(),e+10,0),n.precision=e,n.rounding=t,$s(2==Es||4==Es?r.neg():r,e,t,!0)):new n(NaN)},Vs.times=Vs.mul=function(e){var t,r,n,i,o,a,s,c,l,u=this,f=u.constructor,d=u.d,g=(e=new f(e)).d;if(e.s*=u.s,!(d&&d[0]&&g&&g[0]))return new f(!e.s||d&&!d[0]&&!g||g&&!g[0]&&!d?NaN:d&&g?0*e.s:e.s/0);for(r=Us(u.e/7)+Us(e.e/7),(c=d.length)<(l=g.length)&&(o=d,d=g,g=o,a=c,c=l,l=a),o=[],n=a=c+l;n--;)o.push(0);for(n=l;--n>=0;){for(t=0,i=c+n;i>n;)s=o[i]+g[n]*d[i-n-1]+t,o[i--]=s%Gs|0,t=s/Gs|0;o[i]=(o[i]+t)%Gs|0}for(;!o[--a];)o.pop();return t?++r:o.shift(),e.d=o,e.e=ec(o,r),ks?$s(e,f.precision,f.rounding):e},Vs.toBinary=function(e,t){return Ac(this,2,e,t)},Vs.toDecimalPlaces=Vs.toDP=function(e,t){var r=this,n=r.constructor;return r=new n(r),void 0===e?r:(Xs(e,0,xs),void 0===t?t=n.rounding:Xs(t,0,8),$s(r,e+r.e+1,t))},Vs.toExponential=function(e,t){var r,n=this,i=n.constructor;return void 0===e?r=Zs(n,!0):(Xs(e,0,xs),void 0===t?t=i.rounding:Xs(t,0,8),r=Zs(n=$s(new i(n),e+1,t),!0,e+1)),n.isNeg()&&!n.isZero()?"-"+r:r},Vs.toFixed=function(e,t){var r,n,i=this,o=i.constructor;return void 0===e?r=Zs(i):(Xs(e,0,xs),void 0===t?t=o.rounding:Xs(t,0,8),r=Zs(n=$s(new o(i),e+i.e+1,t),!1,e+n.e+1)),i.isNeg()&&!i.isZero()?"-"+r:r},Vs.toFraction=function(e){var t,r,n,i,o,a,s,c,l,u,f,d,g=this,p=g.d,h=g.constructor;if(!p)return new h(g);if(l=r=new h(1),n=c=new h(0),a=(o=(t=new h(n)).e=nc(p)-g.e-1)%7,t.d[0]=Rs(10,a<0?7+a:a),null==e)e=o>0?t:l;else{if(!(s=new h(e)).isInt()||s.lt(l))throw Error(qs+s);e=s.gt(t)?o>0?t:l:s}for(ks=!1,s=new h(Ps(p)),u=h.precision,h.precision=o=7*p.length*2;f=Ks(s,t,0,1,1),1!=(i=r.plus(f.times(n))).cmp(e);)r=n,n=i,i=l,l=c.plus(f.times(i)),c=i,i=t,t=s.minus(f.times(i)),s=i;return i=Ks(e.minus(r),n,0,1,1),c=c.plus(i.times(l)),r=r.plus(i.times(n)),c.s=l.s=g.s,d=Ks(l,n,o,1).minus(g).abs().cmp(Ks(c,r,o,1).minus(g).abs())<1?[l,n]:[c,r],h.precision=u,ks=!0,d},Vs.toHexadecimal=Vs.toHex=function(e,t){return Ac(this,16,e,t)},Vs.toNearest=function(e,t){var r=this,n=r.constructor;if(r=new n(r),null==e){if(!r.d)return r;e=new n(1),t=n.rounding}else{if(e=new n(e),void 0===t?t=n.rounding:Xs(t,0,8),!r.d)return e.s?r:e;if(!e.d)return e.s&&(e.s=r.s),e}return e.d[0]?(ks=!1,r=Ks(r,e,0,t,1).times(e),ks=!0,$s(r)):(e.s=r.s,r=e),r},Vs.toNumber=function(){return+this},Vs.toOctal=function(e,t){return Ac(this,8,e,t)},Vs.toPower=Vs.pow=function(e){var t,r,n,i,o,a,s=this,c=s.constructor,l=+(e=new c(e));if(!(s.d&&e.d&&s.d[0]&&e.d[0]))return new c(Rs(+s,l));if((s=new c(s)).eq(1))return s;if(n=c.precision,o=c.rounding,e.eq(1))return $s(s,n,o);if((t=Us(e.e/7))>=e.d.length-1&&(r=l<0?-l:l)<=9007199254740991)return i=oc(c,s,r,n),e.s<0?new c(1).div(i):$s(i,n,o);if((a=s.s)<0){if(t<e.d.length-1)return new c(NaN);if(1&e.d[t]||(a=1),0==s.e&&1==s.d[0]&&1==s.d.length)return s.s=a,s}return(t=0!=(r=Rs(+s,l))&&isFinite(r)?new c(r+"").e:Us(l*(Math.log("0."+Ps(s.d))/Math.LN10+s.e+1)))>c.maxE+1||t<c.minE-1?new c(t>0?a/0:0):(ks=!1,c.rounding=s.s=1,r=Math.min(12,(t+"").length),(i=cc(e.times(lc(s,n+r)),n)).d&&_s((i=$s(i,n+5,1)).d,n,o)&&(t=n+10,+Ps((i=$s(cc(e.times(lc(s,t+r)),t),t+5,1)).d).slice(n+1,n+15)+1==1e14&&(i=$s(i,n+1,0))),i.s=a,ks=!0,c.rounding=o,$s(i,n,o))},Vs.toPrecision=function(e,t){var r,n=this,i=n.constructor;return void 0===e?r=Zs(n,n.e<=i.toExpNeg||n.e>=i.toExpPos):(Xs(e,1,xs),void 0===t?t=i.rounding:Xs(t,0,8),r=Zs(n=$s(new i(n),e,t),e<=n.e||n.e<=i.toExpNeg,e)),n.isNeg()&&!n.isZero()?"-"+r:r},Vs.toSignificantDigits=Vs.toSD=function(e,t){var r=this.constructor;return void 0===e?(e=r.precision,t=r.rounding):(Xs(e,1,xs),void 0===t?t=r.rounding:Xs(t,0,8)),$s(new r(this),e,t)},Vs.toString=function(){var e=this,t=e.constructor,r=Zs(e,e.e<=t.toExpNeg||e.e>=t.toExpPos);return e.isNeg()&&!e.isZero()?"-"+r:r},Vs.truncated=Vs.trunc=function(){return $s(new this.constructor(this),this.e+1,1)},Vs.valueOf=Vs.toJSON=function(){var e=this,t=e.constructor,r=Zs(e,e.e<=t.toExpNeg||e.e>=t.toExpPos);return e.isNeg()?"-"+r:r};var Ks=function(){function e(e,t,r){var n,i=0,o=e.length;for(e=e.slice();o--;)n=e[o]*t+i,e[o]=n%r|0,i=n/r|0;return i&&e.unshift(i),e}function t(e,t,r,n){var i,o;if(r!=n)o=r>n?1:-1;else for(i=o=0;i<r;i++)if(e[i]!=t[i]){o=e[i]>t[i]?1:-1;break}return o}function r(e,t,r,n){for(var i=0;r--;)e[r]-=i,i=e[r]<t[r]?1:0,e[r]=i*n+e[r]-t[r];for(;!e[0]&&e.length>1;)e.shift()}return function(n,i,o,a,s,c){var l,u,f,d,g,p,h,A,m,I,y,v,b,w,B,E,C,x,D,F,Q=n.constructor,S=n.s==i.s?1:-1,k=n.d,N=i.d;if(!(k&&k[0]&&N&&N[0]))return new Q(n.s&&i.s&&(k?!N||k[0]!=N[0]:N)?k&&0==k[0]||!N?0*S:S/0:NaN);for(c?(g=1,u=n.e-i.e):(c=Gs,g=7,u=Us(n.e/g)-Us(i.e/g)),D=N.length,C=k.length,I=(m=new Q(S)).d=[],f=0;N[f]==(k[f]||0);f++);if(N[f]>(k[f]||0)&&u--,null==o?(w=o=Q.precision,a=Q.rounding):w=s?o+(n.e-i.e)+1:o,w<0)I.push(1),p=!0;else{if(w=w/g+2|0,f=0,1==D){for(d=0,N=N[0],w++;(f<C||d)&&w--;f++)B=d*c+(k[f]||0),I[f]=B/N|0,d=B%N|0;p=d||f<C}else{for((d=c/(N[0]+1)|0)>1&&(N=e(N,d,c),k=e(k,d,c),D=N.length,C=k.length),E=D,v=(y=k.slice(0,D)).length;v<D;)y[v++]=0;(F=N.slice()).unshift(0),x=N[0],N[1]>=c/2&&++x;do{d=0,(l=t(N,y,D,v))<0?(b=y[0],D!=v&&(b=b*c+(y[1]||0)),(d=b/x|0)>1?(d>=c&&(d=c-1),1==(l=t(h=e(N,d,c),y,A=h.length,v=y.length))&&(d--,r(h,D<A?F:N,A,c))):(0==d&&(l=d=1),h=N.slice()),(A=h.length)<v&&h.unshift(0),r(y,h,v,c),-1==l&&(l=t(N,y,D,v=y.length))<1&&(d++,r(y,D<v?F:N,v,c)),v=y.length):0===l&&(d++,y=[0]),I[f++]=d,l&&y[0]?y[v++]=k[E]||0:(y=[k[E]],v=1)}while((E++<C||void 0!==y[0])&&w--);p=void 0!==y[0]}I[0]||I.shift()}if(1==g)m.e=u,Bs=p;else{for(f=1,d=I[0];d>=10;d/=10)f++;m.e=f+u*g-1,$s(m,s?o+m.e+1:o,a,p)}return m}}();function $s(e,t,r,n){var i,o,a,s,c,l,u,f,d,g=e.constructor;e:if(null!=t){if(!(f=e.d))return e;for(i=1,s=f[0];s>=10;s/=10)i++;if((o=t-i)<0)o+=7,a=t,c=(u=f[d=0])/Rs(10,i-a-1)%10|0;else if((d=Math.ceil((o+1)/7))>=(s=f.length)){if(!n)break e;for(;s++<=d;)f.push(0);u=c=0,i=1,a=(o%=7)-7+1}else{for(u=s=f[d],i=1;s>=10;s/=10)i++;c=(a=(o%=7)-7+i)<0?0:u/Rs(10,i-a-1)%10|0}if(n=n||t<0||void 0!==f[d+1]||(a<0?u:u%Rs(10,i-a-1)),l=r<4?(c||n)&&(0==r||r==(e.s<0?3:2)):c>5||5==c&&(4==r||n||6==r&&(o>0?a>0?u/Rs(10,i-a):0:f[d-1])%10&1||r==(e.s<0?8:7)),t<1||!f[0])return f.length=0,l?(t-=e.e+1,f[0]=Rs(10,(7-t%7)%7),e.e=-t||0):f[0]=e.e=0,e;if(0==o?(f.length=d,s=1,d--):(f.length=d+1,s=Rs(10,7-o),f[d]=a>0?(u/Rs(10,i-a)%Rs(10,a)|0)*s:0),l)for(;;){if(0==d){for(o=1,a=f[0];a>=10;a/=10)o++;for(a=f[0]+=s,s=1;a>=10;a/=10)s++;o!=s&&(e.e++,f[0]==Gs&&(f[0]=1));break}if(f[d]+=s,f[d]!=Gs)break;f[d--]=0,s=1}for(o=f.length;0===f[--o];)f.pop()}return ks&&(e.e>g.maxE?(e.d=null,e.e=NaN):e.e<g.minE&&(e.e=0,e.d=[0])),e}function Zs(e,t,r){if(!e.isFinite())return uc(e);var n,i=e.e,o=Ps(e.d),a=o.length;return t?(r&&(n=r-a)>0?o=o.charAt(0)+"."+o.slice(1)+ic(n):a>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(e.e<0?"e":"e+")+e.e):i<0?(o="0."+ic(-i-1)+o,r&&(n=r-a)>0&&(o+=ic(n))):i>=a?(o+=ic(i+1-a),r&&(n=r-i-1)>0&&(o=o+"."+ic(n))):((n=i+1)<a&&(o=o.slice(0,n)+"."+o.slice(n)),r&&(n=r-a)>0&&(i+1===a&&(o+="."),o+=ic(n))),o}function ec(e,t){var r=e[0];for(t*=7;r>=10;r/=10)t++;return t}function tc(e,t,r){if(t>Js)throw ks=!0,r&&(e.precision=r),Error(Ms);return $s(new e(Fs),t,1,!0)}function rc(e,t,r){if(t>zs)throw Error(Ms);return $s(new e(Qs),t,r,!0)}function nc(e){var t=e.length-1,r=7*t+1;if(t=e[t]){for(;t%10==0;t/=10)r--;for(t=e[0];t>=10;t/=10)r++}return r}function ic(e){for(var t="";e--;)t+="0";return t}function oc(e,t,r,n){var i,o=new e(1),a=Math.ceil(n/7+4);for(ks=!1;;){if(r%2&&mc((o=o.times(t)).d,a)&&(i=!0),0===(r=Us(r/2))){r=o.d.length-1,i&&0===o.d[r]&&++o.d[r];break}mc((t=t.times(t)).d,a)}return ks=!0,o}function ac(e){return 1&e.d[e.d.length-1]}function sc(e,t,r){for(var n,i,o=new e(t[0]),a=0;++a<t.length;){if(!(i=new e(t[a])).s){o=i;break}((n=o.cmp(i))===r||0===n&&o.s===r)&&(o=i)}return o}function cc(e,t){var r,n,i,o,a,s,c,l=0,u=0,f=0,d=e.constructor,g=d.rounding,p=d.precision;if(!e.d||!e.d[0]||e.e>17)return new d(e.d?e.d[0]?e.s<0?0:1/0:1:e.s?e.s<0?0:e:NaN);for(null==t?(ks=!1,c=p):c=t,s=new d(.03125);e.e>-2;)e=e.times(s),f+=5;for(c+=n=Math.log(Rs(2,f))/Math.LN10*2+5|0,r=o=a=new d(1),d.precision=c;;){if(o=$s(o.times(e),c,1),r=r.times(++u),Ps((s=a.plus(Ks(o,r,c,1))).d).slice(0,c)===Ps(a.d).slice(0,c)){for(i=f;i--;)a=$s(a.times(a),c,1);if(null!=t)return d.precision=p,a;if(!(l<3&&_s(a.d,c-n,g,l)))return $s(a,d.precision=p,g,ks=!0);d.precision=c+=10,r=o=s=new d(1),u=0,l++}a=s}}function lc(e,t){var r,n,i,o,a,s,c,l,u,f,d,g=1,p=e,h=p.d,A=p.constructor,m=A.rounding,I=A.precision;if(p.s<0||!h||!h[0]||!p.e&&1==h[0]&&1==h.length)return new A(h&&!h[0]?-1/0:1!=p.s?NaN:h?0:p);if(null==t?(ks=!1,u=I):u=t,A.precision=u+=10,n=(r=Ps(h)).charAt(0),!(Math.abs(o=p.e)<15e14))return l=tc(A,u+2,I).times(o+""),p=lc(new A(n+"."+r.slice(1)),u-10).plus(l),A.precision=I,null==t?$s(p,I,m,ks=!0):p;for(;n<7&&1!=n||1==n&&r.charAt(1)>3;)n=(r=Ps((p=p.times(e)).d)).charAt(0),g++;for(o=p.e,n>1?(p=new A("0."+r),o++):p=new A(n+"."+r.slice(1)),f=p,c=a=p=Ks(p.minus(1),p.plus(1),u,1),d=$s(p.times(p),u,1),i=3;;){if(a=$s(a.times(d),u,1),Ps((l=c.plus(Ks(a,new A(i),u,1))).d).slice(0,u)===Ps(c.d).slice(0,u)){if(c=c.times(2),0!==o&&(c=c.plus(tc(A,u+2,I).times(o+""))),c=Ks(c,new A(g),u,1),null!=t)return A.precision=I,c;if(!_s(c.d,u-10,m,s))return $s(c,A.precision=I,m,ks=!0);A.precision=u+=10,l=a=p=Ks(f.minus(1),f.plus(1),u,1),d=$s(p.times(p),u,1),i=s=1}c=l,i+=2}}function uc(e){return String(e.s*e.s/0)}function fc(e,t){var r,n,i;for((r=t.indexOf("."))>-1&&(t=t.replace(".","")),(n=t.search(/e/i))>0?(r<0&&(r=n),r+=+t.slice(n+1),t=t.substring(0,n)):r<0&&(r=t.length),n=0;48===t.charCodeAt(n);n++);for(i=t.length;48===t.charCodeAt(i-1);--i);if(t=t.slice(n,i)){if(i-=n,e.e=r=r-n-1,e.d=[],n=(r+1)%7,r<0&&(n+=7),n<i){for(n&&e.d.push(+t.slice(0,n)),i-=7;n<i;)e.d.push(+t.slice(n,n+=7));n=7-(t=t.slice(n)).length}else n-=i;for(;n--;)t+="0";e.d.push(+t),ks&&(e.e>e.constructor.maxE?(e.d=null,e.e=NaN):e.e<e.constructor.minE&&(e.e=0,e.d=[0]))}else e.e=0,e.d=[0];return e}function dc(e,t){var r,n,i,o,a,s,c,l,u;if(t.indexOf("_")>-1){if(t=t.replace(/(\d)_(?=\d)/g,"$1"),js.test(t))return fc(e,t)}else if("Infinity"===t||"NaN"===t)return+t||(e.s=NaN),e.e=NaN,e.d=null,e;if(Ts.test(t))r=16,t=t.toLowerCase();else if(Os.test(t))r=2;else{if(!Ys.test(t))throw Error(qs+t);r=8}for((o=t.search(/p/i))>0?(c=+t.slice(o+1),t=t.substring(2,o)):t=t.slice(2),a=(o=t.indexOf("."))>=0,n=e.constructor,a&&(o=(s=(t=t.replace(".","")).length)-o,i=oc(n,new n(r),o,2*o)),o=u=(l=Ws(t,r,Gs)).length-1;0===l[o];--o)l.pop();return o<0?new n(0*e.s):(e.e=ec(l,u),e.d=l,ks=!1,a&&(e=Ks(e,i,4*s)),c&&(e=e.times(Math.abs(c)<54?Rs(2,c):il.pow(2,c))),ks=!0,e)}function gc(e,t,r,n,i){var o,a,s,c,l=e.precision,u=Math.ceil(l/7);for(ks=!1,c=r.times(r),s=new e(n);;){if(a=Ks(s.times(c),new e(t++*t++),l,1),s=i?n.plus(a):n.minus(a),n=Ks(a.times(c),new e(t++*t++),l,1),void 0!==(a=s.plus(n)).d[u]){for(o=u;a.d[o]===s.d[o]&&o--;);if(-1==o)break}o=s,s=n,n=a,a=o}return ks=!0,a.d.length=u+1,a}function pc(e,t){for(var r=e;--t;)r*=e;return r}function hc(e,t){var r,n=t.s<0,i=rc(e,e.precision,1),o=i.times(.5);if((t=t.abs()).lte(o))return Es=n?4:1,t;if((r=t.divToInt(i)).isZero())Es=n?3:2;else{if((t=t.minus(r.times(i))).lte(o))return Es=ac(r)?n?2:3:n?4:1,t;Es=ac(r)?n?1:4:n?3:2}return t.minus(i).abs()}function Ac(e,t,r,n){var i,o,a,s,c,l,u,f,d,g=e.constructor,p=void 0!==r;if(p?(Xs(r,1,xs),void 0===n?n=g.rounding:Xs(n,0,8)):(r=g.precision,n=g.rounding),e.isFinite()){for(p?(i=2,16==t?r=4*r-3:8==t&&(r=3*r-2)):i=t,(a=(u=Zs(e)).indexOf("."))>=0&&(u=u.replace(".",""),(d=new g(1)).e=u.length-a,d.d=Ws(Zs(d),10,i),d.e=d.d.length),o=c=(f=Ws(u,10,i)).length;0==f[--c];)f.pop();if(f[0]){if(a<0?o--:((e=new g(e)).d=f,e.e=o,f=(e=Ks(e,d,r,n,0,i)).d,o=e.e,l=Bs),a=f[r],s=i/2,l=l||void 0!==f[r+1],l=n<4?(void 0!==a||l)&&(0===n||n===(e.s<0?3:2)):a>s||a===s&&(4===n||l||6===n&&1&f[r-1]||n===(e.s<0?8:7)),f.length=r,l)for(;++f[--r]>i-1;)f[r]=0,r||(++o,f.unshift(1));for(c=f.length;!f[c-1];--c);for(a=0,u="";a<c;a++)u+=Ds.charAt(f[a]);if(p){if(c>1)if(16==t||8==t){for(a=16==t?4:3,--c;c%a;c++)u+="0";for(c=(f=Ws(u,i,t)).length;!f[c-1];--c);for(a=1,u="1.";a<c;a++)u+=Ds.charAt(f[a])}else u=u.charAt(0)+"."+u.slice(1);u=u+(o<0?"p":"p+")+o}else if(o<0){for(;++o;)u="0"+u;u="0."+u}else if(++o>c)for(o-=c;o--;)u+="0";else o<c&&(u=u.slice(0,o)+"."+u.slice(o))}else u=p?"0p+0":"0";u=(16==t?"0x":2==t?"0b":8==t?"0o":"")+u}else u=uc(e);return e.s<0?"-"+u:u}function mc(e,t){if(e.length>t)return e.length=t,!0}function Ic(e){return new this(e).abs()}function yc(e){return new this(e).acos()}function vc(e){return new this(e).acosh()}function bc(e,t){return new this(e).plus(t)}function wc(e){return new this(e).asin()}function Bc(e){return new this(e).asinh()}function Ec(e){return new this(e).atan()}function Cc(e){return new this(e).atanh()}function xc(e,t){e=new this(e),t=new this(t);var r,n=this.precision,i=this.rounding,o=n+4;return e.s&&t.s?e.d||t.d?!t.d||e.isZero()?(r=t.s<0?rc(this,n,i):new this(0)).s=e.s:!e.d||t.isZero()?(r=rc(this,o,1).times(.5)).s=e.s:t.s<0?(this.precision=o,this.rounding=1,r=this.atan(Ks(e,t,o,1)),t=rc(this,o,1),this.precision=n,this.rounding=i,r=e.s<0?r.minus(t):r.plus(t)):r=this.atan(Ks(e,t,o,1)):(r=rc(this,o,1).times(t.s>0?.25:.75)).s=e.s:r=new this(NaN),r}function Dc(e){return new this(e).cbrt()}function Fc(e){return $s(e=new this(e),e.e+1,2)}function Qc(e,t,r){return new this(e).clamp(t,r)}function Sc(e){if(!e||"object"!=typeof e)throw Error(Ns+"Object expected");var t,r,n,i=!0===e.defaults,o=["precision",1,xs,"rounding",0,8,"toExpNeg",-Cs,0,"toExpPos",0,Cs,"maxE",0,Cs,"minE",-Cs,0,"modulo",0,9];for(t=0;t<o.length;t+=3)if(r=o[t],i&&(this[r]=Ss[r]),void 0!==(n=e[r])){if(!(Us(n)===n&&n>=o[t+1]&&n<=o[t+2]))throw Error(qs+r+": "+n);this[r]=n}if(r="crypto",i&&(this[r]=Ss[r]),void 0!==(n=e[r])){if(!0!==n&&!1!==n&&0!==n&&1!==n)throw Error(qs+r+": "+n);if(n){if("undefined"==typeof crypto||!crypto||!crypto.getRandomValues&&!crypto.randomBytes)throw Error(Hs);this[r]=!0}else this[r]=!1}return this}function kc(e){return new this(e).cos()}function Nc(e){return new this(e).cosh()}function qc(e,t){return new this(e).div(t)}function Mc(e){return new this(e).exp()}function Hc(e){return $s(e=new this(e),e.e+1,3)}function Lc(){var e,t,r=new this(0);for(ks=!1,e=0;e<arguments.length;)if((t=new this(arguments[e++])).d)r.d&&(r=r.plus(t.times(t)));else{if(t.s)return ks=!0,new this(1/0);r=t}return ks=!0,r.sqrt()}function Uc(e){return e instanceof il||e&&e.toStringTag===Ls||!1}function Rc(e){return new this(e).ln()}function Oc(e,t){return new this(e).log(t)}function Tc(e){return new this(e).log(2)}function Yc(e){return new this(e).log(10)}function jc(){return sc(this,arguments,-1)}function Gc(){return sc(this,arguments,1)}function Jc(e,t){return new this(e).mod(t)}function zc(e,t){return new this(e).mul(t)}function Vc(e,t){return new this(e).pow(t)}function Pc(e){var t,r,n,i,o=0,a=new this(1),s=[];if(void 0===e?e=this.precision:Xs(e,1,xs),n=Math.ceil(e/7),this.crypto)if(crypto.getRandomValues)for(t=crypto.getRandomValues(new Uint32Array(n));o<n;)(i=t[o])>=429e7?t[o]=crypto.getRandomValues(new Uint32Array(1))[0]:s[o++]=i%1e7;else{if(!crypto.randomBytes)throw Error(Hs);for(t=crypto.randomBytes(n*=4);o<n;)(i=t[o]+(t[o+1]<<8)+(t[o+2]<<16)+((127&t[o+3])<<24))>=214e7?crypto.randomBytes(4).copy(t,o):(s.push(i%1e7),o+=4);o=n/4}else for(;o<n;)s[o++]=1e7*Math.random()|0;for(e%=7,(n=s[--o])&&e&&(i=Rs(10,7-e),s[o]=(n/i|0)*i);0===s[o];o--)s.pop();if(o<0)r=0,s=[0];else{for(r=-1;0===s[0];r-=7)s.shift();for(n=1,i=s[0];i>=10;i/=10)n++;n<7&&(r-=7-n)}return a.e=r,a.d=s,a}function Xc(e){return $s(e=new this(e),e.e+1,this.rounding)}function _c(e){return(e=new this(e)).d?e.d[0]?e.s:0*e.s:e.s||NaN}function Wc(e){return new this(e).sin()}function Kc(e){return new this(e).sinh()}function $c(e){return new this(e).sqrt()}function Zc(e,t){return new this(e).sub(t)}function el(){var e=0,t=arguments,r=new this(t[e]);for(ks=!1;r.s&&++e<t.length;)r=r.plus(t[e]);return ks=!0,$s(r,this.precision,this.rounding)}function tl(e){return new this(e).tan()}function rl(e){return new this(e).tanh()}function nl(e){return $s(e=new this(e),e.e+1,1)}Vs[Symbol.for("nodejs.util.inspect.custom")]=Vs.toString,Vs[Symbol.toStringTag]="Decimal";var il=Vs.constructor=function e(t){var r,n,i;function o(e){var t,r,n,i=this;if(!(i instanceof o))return new o(e);if(i.constructor=o,Uc(e))return i.s=e.s,void(ks?!e.d||e.e>o.maxE?(i.e=NaN,i.d=null):e.e<o.minE?(i.e=0,i.d=[0]):(i.e=e.e,i.d=e.d.slice()):(i.e=e.e,i.d=e.d?e.d.slice():e.d));if("number"===(n=typeof e)){if(0===e)return i.s=1/e<0?-1:1,i.e=0,void(i.d=[0]);if(e<0?(e=-e,i.s=-1):i.s=1,e===~~e&&e<1e7){for(t=0,r=e;r>=10;r/=10)t++;return void(ks?t>o.maxE?(i.e=NaN,i.d=null):t<o.minE?(i.e=0,i.d=[0]):(i.e=t,i.d=[e]):(i.e=t,i.d=[e]))}return 0*e!=0?(e||(i.s=NaN),i.e=NaN,void(i.d=null)):fc(i,e.toString())}if("string"===n)return 45===(r=e.charCodeAt(0))?(e=e.slice(1),i.s=-1):(43===r&&(e=e.slice(1)),i.s=1),js.test(e)?fc(i,e):dc(i,e);if("bigint"===n)return e<0?(e=-e,i.s=-1):i.s=1,fc(i,e.toString());throw Error(qs+e)}if(o.prototype=Vs,o.ROUND_UP=0,o.ROUND_DOWN=1,o.ROUND_CEIL=2,o.ROUND_FLOOR=3,o.ROUND_HALF_UP=4,o.ROUND_HALF_DOWN=5,o.ROUND_HALF_EVEN=6,o.ROUND_HALF_CEIL=7,o.ROUND_HALF_FLOOR=8,o.EUCLID=9,o.config=o.set=Sc,o.clone=e,o.isDecimal=Uc,o.abs=Ic,o.acos=yc,o.acosh=vc,o.add=bc,o.asin=wc,o.asinh=Bc,o.atan=Ec,o.atanh=Cc,o.atan2=xc,o.cbrt=Dc,o.ceil=Fc,o.clamp=Qc,o.cos=kc,o.cosh=Nc,o.div=qc,o.exp=Mc,o.floor=Hc,o.hypot=Lc,o.ln=Rc,o.log=Oc,o.log10=Yc,o.log2=Tc,o.max=jc,o.min=Gc,o.mod=Jc,o.mul=zc,o.pow=Vc,o.random=Pc,o.round=Xc,o.sign=_c,o.sin=Wc,o.sinh=Kc,o.sqrt=$c,o.sub=Zc,o.sum=el,o.tan=tl,o.tanh=rl,o.trunc=nl,void 0===t&&(t={}),t&&!0!==t.defaults)for(i=["precision","rounding","toExpNeg","toExpPos","maxE","minE","modulo","crypto"],r=0;r<i.length;)t.hasOwnProperty(n=i[r++])||(t[n]=this[n]);return o.config(t),o}(Ss);function ol(e,t=0){if(Bo(t)||(t=0),t=Zi(t),!Se(e))return"";return new il(e).toDecimalPlaces(t,il.ROUND_CEIL).toNumber()}function al(e,t=0){if(!Se(e))return"";if(!Bo(t))return"";return e=Mn(e),$i(e,t).toFixed(t)}function sl(e){let t=function(){let e=yn();return n||e.xss}();let r=function e(r){return Ce(r)||Be(r)?(Er(r,function(t,n){r[n]=e(t)}),r):De(r)?t(r,{onIgnoreTagAttr:function(e,r,n,i){if("style"===r)return r+'="'+t.escapeAttrValue(n)+'"'}}):r}(zi(e));return r}function cl(e,t){let r=ns();if(!Ce(e)&&!Be(e))return r.reject("rs is not an array or object"),r;let n=!1;if(Be(e)){n=!0;let t=[];Er(e,(e,r)=>{t.push({k:r,v:e})}),e=t}va(t)||(t=function(e){return e});let i=-1,o=[];return e.reduce(function(e,r){return e.then(function(e){o.push(e),i+=1;let a=i,s=r;return n&&(a=r.k,s=r.v),va(t)?t(s,a):s})},Promise.resolve()).then(function(e){o.push(e),o=ja(o),r.resolve(o)}).catch(function(e){r.reject(e)}),r}Fs=new il(Fs),Qs=new il(Qs);let ll={},ul={};function fl({tagName:e,path:t,attributes:r={},func:n}){let i=ns();if("done"===ll[t])return i.resolve("loaded"),i;if("loading"===ll[t])return vs(()=>"done"===ll[t]).then(function(){i.resolve("loaded")}),i;ll[t]="loading";let o=document.createElement(e);return Er(r,(e,t)=>{o.setAttribute(t,e)}),r.rel&&"stylesheet"===r.rel?(o.setAttribute("href",t),setTimeout(()=>{i.resolve(o),ll[t]="done"},1)):(o.src=t,o.addEventListener("load",()=>{let e;va(n)?e=vs(n):(e=ns(),e.resolve()),e.then(()=>bs(500)).then(function(){i.resolve(o),ll[t]="done"})}),o.addEventListener("error",()=>{i.reject(o),ll[t]="done"})),document.getElementsByTagName("head")[0].appendChild(o),i}function dl(e){let t=ns();Ce(e)||(e=[e]),Er(e,(t,r)=>{xe(t)&&(e[r]={path:t})});let r=xo(xr(e,"path"),"|");return"done"===ul[r]?(t.resolve("loaded"),t):"loading"===ul[r]?(vs(()=>"done"===ul[r]).then(function(){t.resolve("loaded")}),t):(ul[r]="loading",Er(e,(e,t)=>{e.type||(".js"===fa(e.path,3)?e.type="js":".css"===fa(e.path,4)?e.type="css":e.type="unknow")}),cl(e,e=>{let t=ns();if("js"===e.type)t=fl({tagName:"script",path:e.path,attributes:{type:"text/javascript"},func:e.func});else if("css"===e.type)t=fl({tagName:"link",path:e.path,attributes:{rel:"stylesheet"}});else{let r="invalid pathItem.type: "+e.type;console.log(r),t.reject(r)}return t}).finally(()=>{ul[r]="done"}))}function gl(e){return Ie(e).toUpperCase()}function pl(e,t,r){if(!De(e))return"";if(!De(t))return"";if(!xe(r))return"";return String(e).replaceAll(t,r)}function hl(e,t,r=1){return De(e)&&Bo(t)?(r=eo(r)?Zi(r):1,e.substring(t,t+r)):""}let Al={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};function ml(e){return yl(e,1)}function Il(e){return yl(e,360)}function yl(e,t=1){if(e.indexOf("%")>=0){if(!Se(e=pl(e,"%","")))throw new Error("invalid color: value is not a number");e=Mn(e)/100}else{if(!Se(e))throw new Error("invalid color: value is not a number");e=Mn(e)/t}if(e>1)throw new Error("invalid color: value > 1");if(e<0)throw new Error("invalid color: value < 0");return e}function vl(e){if(!Se(e))throw new Error("invalid color: value is not a number");if((e=Mn(e))>1)throw new Error("invalid color: value > 1");if(e<0)throw new Error("invalid color: value < 0");return e}function bl(e,t="rgba"){if(!Ce(e))throw new Error("invalid colors array");let r=we(e,0,0),n=we(e,1,0),i=we(e,2,0),o=we(e,3,1);if(4!==dn(t=t.split("")))throw new Error("tar.length !== 4");let a=we(t,0),s=we(t,1),c=we(t,2),l=we(t,3);return{[a]:r,[s]:n,[c]:i,[l]:o}}function wl(e){let t=(e=da(e,1)).length;if(2===t)e=`${e}${e}${e}ff`;else if(3===t){let t=hl(e,0,1),r=hl(e,1,1),n=hl(e,2,1);e=`${t}${t}${r}${r}${n}${n}ff`}else if(6===t)e=`${e}ff`;else if(8!==t)throw new Error("invalid hex color");function r(e){if(2!==e.length)throw new Error("hex.length of color is not equal to 2");if(!Se(e=parseInt(e,16)))throw new Error("invalid hex of color");return(e=Mn(e))/255}return{r:r(hl(e,0,2)),g:r(hl(e,2,2)),b:r(hl(e,4,2)),a:r(hl(e,6,2))}}function Bl(e){return e=bl(e=xr(e,(e,t)=>t<=2?yl(e,255):3===t?vl(e):null),"rgba")}function El(e){return e=Nl(e=bl(e=xr(e,(e,t)=>0===t?Il(e):1===t||2===t?ml(e):3===t?vl(e):null),"hsla"))}function Cl(e){return e=ql(e=bl(e=xr(e,(e,t)=>0===t?Il(e):1===t||2===t?ml(e):3===t?vl(e):null),"hsva"))}function xl(e){if("transparent"===e)return{r:0,g:0,b:0,a:0};if(function(e){return ke(Al,e)}(e))return wl(e=function(e){return`#${Al[e]}`}(e));if(function(e){return"#"===ua(e,1)&&(!!/[0-9A-Fa-f]{2}/g.test(e)||(!!/[0-9A-Fa-f]{3}/g.test(e)||(!!/[0-9A-Fa-f]{6}/g.test(e)||!!/[0-9A-Fa-f]{8}/g.test(e))))}(e))return wl(e);if(function(e){return"rgb"===ua(e,3)||"rgba"===ua(e,4)}(e))return function(e){return e=pl(e,"rgba",""),e=pl(e,"rgb",""),Bl(la(e=pl(e=e.replace(/[()]/g,""),","," ")," "))}(e);if(function(e){return"hsl"===ua(e,3)||"hsla"===ua(e,4)}(e))return function(e){return e=pl(e,"hsla",""),e=pl(e,"hsl",""),El(la(e=pl(e=e.replace(/[()]/g,""),","," ")," "))}(e);if(function(e){return"hsv"===ua(e,3)||"hsva"===ua(e,4)}(e))return function(e){return e=pl(e,"hsva",""),e=pl(e,"hsv",""),Cl(la(e=pl(e=e.replace(/[()]/g,""),","," ")," "))}(e);throw new Error("format of color string is not hex-color, name-color, rgba, hsla, hsva")}function Dl(e,t){return!!ke(e,t=ws(t))||!!ke(e,t=gl(t))}function Fl(e,t,r){let n;return n=we(e,t,null),null!==n?n:(n=we(e,t=gl(t),null),null!==n?n:r)}function Ql(e){if(function(e){let t=Dl(e,"r"),r=Dl(e,"g"),n=Dl(e,"b");return t&&r&&n}(e))return function(e){let t=[Fl(e,"r",null),Fl(e,"g",null),Fl(e,"b",null),Fl(e,"a",1)];return t=xr(t,Ya),Bl(t)}(e);if(function(e){let t=Dl(e,"h"),r=Dl(e,"s"),n=Dl(e,"l");return t&&r&&n}(e))return function(e){let t=[Fl(e,"h",null),Fl(e,"s",null),Fl(e,"l",null),Fl(e,"a",1)];return t=xr(t,Ya),El(t)}(e);if(function(e){let t=Dl(e,"h"),r=Dl(e,"s"),n=Dl(e,"v");return t&&r&&n}(e))return function(e){let t=[Fl(e,"h",null),Fl(e,"s",null),Fl(e,"v",null),Fl(e,"a",1)];return t=xr(t,Ya),Cl(t)}(e);throw new Error("color object is not one of rgba, hsla, hsva")}function Sl(e){let t,r,n=e.r,i=e.g,o=e.b,a=Math.max(n,i,o),s=Math.min(n,i,o),c=(a+s)/2;if(a===s)t=r=0;else{let e=a-s;switch(r=c>.5?e/(2-a-s):e/(a+s),a){case n:t=(i-o)/e+(i<o?6:0);break;case i:t=(o-n)/e+2;break;case o:t=(n-i)/e+4}t/=6}return{h:t,s:r,l:c,a:e.a}}function kl(e){let t,r,n=e.r,i=e.g,o=e.b,a=Math.max(n,i,o),s=Math.min(n,i,o),c=a,l=a-s;if(r=0===a?0:l/a,a===s)t=0;else{switch(a){case n:t=(i-o)/l+(i<o?6:0);break;case i:t=(o-n)/l+2;break;case o:t=(n-i)/l+4}t/=6}return{h:t,s:r,v:c,a:e.a}}function Nl(e){let t,r,n,i=e.h,o=e.s,a=e.l;function s(e,t,r){return r<0&&(r+=1),r>1&&(r-=1),r<1/6?e+6*(t-e)*r:r<.5?t:r<2/3?e+(t-e)*(2/3-r)*6:e}if(0===o)t=r=n=a;else{let e=a<.5?a*(1+o):a+o-a*o,c=2*a-e;t=s(c,e,i+1/3),r=s(c,e,i),n=s(c,e,i-1/3)}return{r:t,g:r,b:n,a:e.a}}function ql(e){let t,r,n,i=e.h,o=e.s,a=e.v,s=Math.floor(6*i),c=6*i-s,l=a*(1-o),u=a*(1-c*o),f=a*(1-(1-c)*o);switch(s%6){case 0:t=a,r=f,n=l;break;case 1:t=u,r=a,n=l;break;case 2:t=l,r=a,n=f;break;case 3:t=l,r=u,n=a;break;case 4:t=f,r=l,n=a;break;case 5:t=a,r=l,n=u}return{r:t,g:r,b:n,a:e.a}}function Ml(e){let t=Math.round(255*e).toString(16);if(1===t.length)return`0${t}`;if(2===t.length)return t;throw new Error("invalid value")}function Hl(e,t=!0){let r=e.r,n=e.g,i=e.b,o=e.a,a=`${Ml(r)}${Ml(n)}${Ml(i)}`;return t&&(a=`${a}${Ml(o)}`),a}function Ll(e){return Math.min(1,Math.max(0,e))}function Ul(e,t){if(!De(t))throw new Error("fmtOutput is not a string");if(!mu[t])throw console.log(`fmtOutput must be [${dt(mu)}]`),new Error("invalid fmtOutput");return e=mu[t](e)}function Rl(e,t,r="toRgbString"){if(t<0||t>1)throw new Error("amount < 0 or > 1");let n=Sl(e);return n.h+=t,n.h=n.h%1,Ul(Nl(n),r)}function Ol(e,t,r,n,i="toRgbString"){if(t<0||t>1)throw new Error("w1 < 0 or > 1");if(n<0||n>1)throw new Error("w1 < 0 or > 1");return Ul({r:e.r*t+r.r*n,g:e.g*t+r.g*n,b:e.b*t+r.b*n,a:e.a*t+r.a*n},i)}function Tl(e){return`${$i(100*e,1)}%`}function Yl(e){return $i(e,0)}function jl(e){return $i(e,3)}function Gl(e){return{r:Yl(255*e.r),g:Yl(255*e.g),b:Yl(255*e.b)}}function Jl(e){return`rgb(${Yl(255*e.r)}, ${Yl(255*e.g)}, ${Yl(255*e.b)})`}function zl(e){return{r:Yl(255*e.r),g:Yl(255*e.g),b:Yl(255*e.b),a:jl(e.a)}}function Vl(e){return`rgba(${Yl(255*e.r)}, ${Yl(255*e.g)}, ${Yl(255*e.b)}, ${jl(e.a)})`}function Pl(e){let t=Sl(e);return{h:Yl(360*t.h),s:jl(t.s),l:jl(t.l)}}function Xl(e){let t=Sl(e);return`hsl(${Yl(360*t.h)}, ${jl(t.s)}, ${jl(t.l)})`}function _l(e){let t=Sl(e);return{h:Yl(360*t.h),s:jl(t.s),l:jl(t.l),a:jl(t.a)}}function Wl(e){let t=Sl(e);return`hsla(${Yl(360*t.h)}, ${jl(t.s)}, ${jl(t.l)}, ${jl(t.a)})`}function Kl(e){let t=kl(e);return{h:Yl(360*t.h),s:jl(t.s),v:jl(t.v)}}function $l(e){let t=kl(e);return`hsv(${Yl(360*t.h)}, ${jl(t.s)}, ${jl(t.v)})`}function Zl(e){let t=kl(e);return{h:Yl(360*t.h),s:jl(t.s),v:jl(t.v),a:jl(t.a)}}function eu(e){let t=kl(e);return`hsva(${Yl(360*t.h)}, ${jl(t.s)}, ${jl(t.v)}, ${jl(t.a)})`}function tu(e){return{r:Tl(e.r),g:Tl(e.g),b:Tl(e.b)}}function ru(e){return`rgb(${Tl(e.r)}, ${Tl(e.g)}, ${Tl(e.b)})`}function nu(e){return{r:Tl(e.r),g:Tl(e.g),b:Tl(e.b),a:jl(e.a)}}function iu(e){return`rgba(${Tl(e.r)}, ${Tl(e.g)}, ${Tl(e.b)}, ${jl(e.a)})`}function ou(e){let t=Sl(e);return{h:Yl(360*t.h),s:Tl(t.s),l:Tl(t.l)}}function au(e){let t=Sl(e);return`hsl(${Yl(360*t.h)}, ${Tl(t.s)}, ${Tl(t.l)})`}function su(e){let t=Sl(e);return{h:Yl(360*t.h),s:Tl(t.s),l:Tl(t.l),a:jl(t.a)}}function cu(e){let t=Sl(e);return`hsla(${Yl(360*t.h)}, ${Tl(t.s)}, ${Tl(t.l)}, ${jl(t.a)})`}function lu(e){let t=kl(e);return{h:Yl(360*t.h),s:Tl(t.s),v:Tl(t.v)}}function uu(e){let t=kl(e);return`hsv(${Yl(360*t.h)}, ${Tl(t.s)}, ${Tl(t.v)})`}function fu(e){let t=kl(e);return{h:Yl(360*t.h),s:Tl(t.s),v:Tl(t.v),a:jl(t.a)}}function du(e){let t=kl(e);return`hsva(${Yl(360*t.h)}, ${Tl(t.s)}, ${Tl(t.v)}, ${jl(t.a)})`}function gu(e){let t=function(e){return Hl(e,!1)}(e);return`#${t}`}function pu(e){return`#${Hl(e)}`}function hu(e){let t=null,r=null,n=null;if(De(e))t=ws(sa(e));else{if(!Ee(e))throw console.log("color=",e),new Error("color is not a string or an object");r=e}if(null!==t)try{n=xl(t)}catch(e){throw console.log(e),new Error(`can not parse color: ${t}`)}else if(null!==r)try{n=Ql(r)}catch(e){throw console.log(e),new Error(`can not parse color: ${JSON.stringify(r)}`)}return n}function Au(e){if(!Ee(e))return console.log("gradient is not an effective object"),e=>`rgb(${255*(e=Math.min(Math.max(e,0),1))},${255*e},${255*e})`;let t=[];return Er(e,(e,r)=>{t.push([Mn(r),zl(hu(e)),e])}),t=Oa(t,0),function(e){let r=null;for(let n=1;n<t.length;n++){let i=t[n-1][0],o=t[n-1][1],a=t[n][0],s=t[n][1];if(i<=e&&a>=e){let t=(a-e)/(a-i),n=(e-i)/(a-i);r=Ol(hu(o),t,hu(s),n,"toRgbaString");break}}return r}}let mu={toRgb:Gl,toRgbString:Jl,toRgba:zl,toRgbaString:Vl,toHsl:Pl,toHslString:Xl,toHsla:_l,toHslaString:Wl,toHsv:Kl,toHsvString:$l,toHsva:Zl,toHsvaString:eu,toRgbP:tu,toRgbPString:ru,toRgbaP:nu,toRgbaPString:iu,toHslP:ou,toHslPString:au,toHslaP:su,toHslaPString:cu,toHsvP:lu,toHsvPString:uu,toHsvaP:fu,toHsvaPString:du,toHexString:gu,toHex8String:pu};var Iu={toRgb:e=>Gl(hu(e)),toRgbString:e=>Jl(hu(e)),toRgba:e=>zl(hu(e)),toRgbaString:e=>Vl(hu(e)),toHsl:e=>Pl(hu(e)),toHslString:e=>Xl(hu(e)),toHsla:e=>_l(hu(e)),toHslaString:e=>Wl(hu(e)),toHsv:e=>Kl(hu(e)),toHsvString:e=>$l(hu(e)),toHsva:e=>Zl(hu(e)),toHsvaString:e=>eu(hu(e)),toRgbP:e=>tu(hu(e)),toRgbPString:e=>ru(hu(e)),toRgbaP:e=>nu(hu(e)),toRgbaPString:e=>iu(hu(e)),toHslP:e=>ou(hu(e)),toHslPString:e=>au(hu(e)),toHslaP:e=>su(hu(e)),toHslaPString:e=>cu(hu(e)),toHsvP:e=>lu(hu(e)),toHsvPString:e=>uu(hu(e)),toHsvaP:e=>fu(hu(e)),toHsvaPString:e=>du(hu(e)),toHexString:e=>gu(hu(e)),toHex8String:e=>pu(hu(e)),modSaturate:(e,t,r)=>function(e,t,r="toRgbString"){if(t<0||t>1)throw new Error("amount < 0 or > 1");let n=Sl(e);return n.s+=t,n.s=Ll(n.s),Ul(Nl(n),r)}(hu(e),t,r),modGrey:(e,t)=>function(e,t="toRgbString"){let r=Sl(e);return r.s=0,Ul(Nl(r),t)}(hu(e),t),modLighten:(e,t,r)=>function(e,t,r="toRgbString"){if(t<0||t>1)throw new Error("amount < 0 or > 1");let n=Sl(e);return n.l+=t,n.l=Ll(n.l),Ul(Nl(n),r)}(hu(e),t,r),modBrighten:(e,t,r)=>function(e,t,r="toRgbString"){if(t<0||t>1)throw new Error("amount < 0 or > 1");return e.r+=t,e.r=Ll(e.r),e.g+=t,e.g=Ll(e.g),e.b+=t,e.b=Ll(e.b),Ul(e,r)}(hu(e),t,r),modHue:(e,t,r)=>Rl(hu(e),t,r),modComplement:(e,t)=>function(e,t="toRgbString"){return Rl(e,.5,t)}(hu(e),t),spreadHue:(e,t,r)=>function(e,t,r="toRgbString"){if(!Hn(t))throw new Error("num is not an integer");if((t=Zi(t))<=1)return[e];let n=Sl(e),i=1/t,o=[];for(let e=0;e<t;e++)o.push(Ul(Nl(n),r)),n.h+=i,n.h=n.h%1;return o}(hu(e),t,r),spreadMonochromatic:(e,t,r)=>function(e,t,r="toRgbString"){if(!Hn(t))throw new Error("num is not an integer");if((t=Zi(t))<=1)return[e];let n=kl(e);n.s=1,n.l=1;let i=1/t,o=[];for(let e=0;e<t;e++)o.push(Ul(ql(n),r)),n.h-=i,n.l-=i;return o}(hu(e),t,r),mix:(e,t,r,n,i)=>Ol(hu(e),t,hu(r),n,i),getBrightness:e=>function(e){if(1!==e.a)throw new Error("alpha of color can not be equal to 1");return(299*e.r+587*e.g+114*e.b)/1e3}(hu(e)),getLuminance:e=>function(e){if(1!==e.a)throw new Error("alpha of color can not be equal to 1");let t,r,n,i=e.r,o=e.g,a=e.b;return t=i<=.03928?i/12.92:Math.pow((i+.055)/1.055,2.4),r=o<=.03928?o/12.92:Math.pow((o+.055)/1.055,2.4),n=a<=.03928?a/12.92:Math.pow((a+.055)/1.055,2.4),.2126*t+.7152*r+.0722*n}(hu(e)),interp:Au};function yu(e,t,r){return null==e?e:function(e,t,r,n){if(!U(e))return e;for(var i=-1,o=(t=ye(t,e)).length,a=o-1,s=e;null!=s&&++i<o;){var c=ve(t[i]),l=r;if("__proto__"===c||"constructor"===c||"prototype"===c)return e;if(i!=a){var u=s[c];void 0===(l=n?n(u,c,s):void 0)&&(l=U(u)?u:Pe(t[i+1])?[]:{})}pi(s,c,l),s=s[c]}return e}(e,t,r)}function vu(e){return vr(e)?void 0:e}var bu=bo(function(e,t){var r={};if(null==e)return r;var n=!1;t=pe(t,function(t){return t=ye(t,e),n||(n=t.length>1),t}),hi(e,Ci(e),r),n&&(r=Ji(r,7,vu));for(var i=t.length;i--;)ka(r,t[i]);return r}),wu=bu;function Bu(e,t={}){let r="$level",n="$parents";if(!Rr(e))return[];let i=we(t,"bindKey",null);De(i)||(i="id");let o=we(t,"bindParent",null);De(o)||(o="parentId");let a=we(t,"bindChildren",null);De(a)||(a="children");let s=we(t,"saveExtProps",null);pn(s)||(s=!1),e=function(e){let t=[];function a(a){let s=[];Er(e,(e,c)=>{let l=we(e,o),u=we(a,i);if(l&&u&&l===u){let o=we(a,n,[]);o=zi(o),o.push(a[i]),t.push({[r]:a[r]+1,[n]:o,...e})}else s.push(e)}),e=s}if(e=zi(e),function(){let i=[];Er(e,(e,a)=>{Ur(e[o])?t.push({[r]:0,[n]:[],...e}):i.push(e)}),e=i}(),0===t.length)return t;let s=-1;for(;s+=1,!(s>t.length-1);){if(a(t[s]),0===e.length)break}return t}(e);let c=function(e){let t=[];function c(e){return s?e:wu(e,[r,n])}let l={};return Er(e,(n,s)=>{if(0===n[r]){let e=c(n);t.push(e),l[n[i]]=[s]}else{let r=function(t){for(let r=0;r<e.length;r++){let n=e[r];if(t[o]===n[i])return n}return null}(n);if(null!==r){let e=l[r[i]];e=[...e,a];let o=we(t,e,[]),s=c(n);o.push(s),l[n[i]]=[...e,o.length-1],yu(t,e,o)}else console.log(`can not find parent for ${we(n,o)}`)}}),t}(e);return c}function Eu(e,t=null,r={}){R(t)||(t=e=>e);let n=we(r,"force",!1);return pn(n)||(n=!1),function(e,t,r=!1){let n=[];if(!Ce(e)&&!Be(e))return t(e,null,[]);function i(e){if(Ce(e))return ao(dn(e));if(Be(e)){let t=Object.getOwnPropertyNames(e),n=null;return r&&(n=Object.getOwnPropertySymbols(e)),Ce(t)||(t=[]),Ce(n)||(n=[]),[...t,...n]}return e}return function e(r,o){if(Ce(r))return i(r).map(i=>{let o=r[i],a=zi(n);return n.push(i),o=t(o,i,a),o=e(o),n.pop(),o});if(Be(r)){let o=i(r),a={};return o.map(i=>{let o=r[i],s=zi(n);n.push(i),o=t(o,i,s),o=e(o),n.pop(),a[i]=o}),a}return r}(e)}(e,t,n)}function Cu(e,t={}){if(!Ee(e)&&!Rr(e))return[];let r=we(t,"bindKey",null);De(r)||(r="id");let n=we(t,"bindParent",null);De(n)||(n="parentId");let i=we(t,"bindBelong",null);De(i)||(i="key");let o=we(t,"bindText",null);De(o)||(o="text");let a=we(t,"bindType",null);De(a)||(a="type");let s=we(t,"bindNumOfChilren",null);function c(e,t){return e=xr(e=zi(e),e=>q(e)?Ya(e):e),q(t)&&(t=Ya(t)),(De(t)||Se(t))&&e.push(t),xo(e,"-")}De(s)||(s="numOfChilren");let l=[];return Eu(e,(e,t,u)=>{let f=c(u,t),d=c(u,null),g="node";Be(e)?g="object":Ce(e)&&(g="array");let p={[r]:f,[n]:d,[a]:g};if((De(t)||Ia(t))&&(p[i]=t),Be(e)||Ce(e)||(p[o]=e),Be(e)||Ce(e)){let t=null;Be(e)?t=dn(dt(e)):Ce(e)&&(t=dn(e)),p[s]=t}return l.push(p),e},{force:!0}),l}function xu(e){if(!br(e))return"invalid element";let t=!1;try{t=document.activeElement===e}catch(e){console.log(e)}return t}function Du(e){return Se(e)?(e=Mn(e),Math.cos(e*Math.PI/180)):null}function Fu(e){return Se(e)?(e=Mn(e),Math.tan(e*Math.PI/180)):null}function Qu(){let e=new function e(){if(!(this instanceof e))return new e;this.SheetNames=[],this.Sheets={}};return e}function Su(e){return Se(e)?(e=Mn(e),Math.sin(e*Math.PI/180)):null}function ku(e){if(!De(e))return!1;let t="YYYY-MM-DD";return e===r(e,t).format(t)}function Nu(e=300){return new function(e){let t=[],r=null,n=Date.now();return eo(e)||(e=300),e=Zi(e),function(i,...o){va(i)?(n=Date.now(),t.push({func:i,input:o}),null===r&&(r=setInterval(()=>{if(0===dn(t))return clearInterval(r),void(r=null);if(Date.now()-n>e){let e=t.pop();t=[];try{e.func(...e.input)}catch(e){console.log("m.func catch",e)}}},10))):console.log("func is not a function")}}(e)}let qu="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz".split(""),Mu=qu.length;function Hu(e=32){let t=[];e=eo(e)?Zi(e):32;for(let r=0;r<e;r++)t[r]=qu[0|Math.random()*Mu];return t.join("")}function Lu(e,t={}){if(!br(e))return;let r=we(t,"duration",500);r=Mn(r),r<0&&(r=1e3);let n=we(t,"delay",0);n=Mn(n),n<0&&(n=0);let i=we(t,"opacityIni",0);i=Mn(i),i=Math.min(Math.max(i,0),1),Se(e.style.opacity)&&(i=Mn(e.style.opacity));let o=10/r,a=`tag-${Hu()}`;e.setAttribute("dom-fade-tag",a),setTimeout(()=>{let t=setInterval(()=>{try{e.getAttribute("dom-fade-tag")!==a&&clearInterval(t),e.style.opacity=i,i>=1&&(clearInterval(t),e.removeAttribute("dom-fade-tag")),i+=o,i>1&&(i=1)}catch(e){console.log(e),clearInterval(t)}},10)},n)}function Uu(e,t={}){if(!br(e))return;let r=we(t,"duration",500);r=Mn(r),r<0&&(r=1e3);let n=we(t,"delay",0);n=Mn(n),n<0&&(n=0);let i=we(t,"opacityIni",1);i=Mn(i),i=Math.min(Math.max(i,0),1),Se(e.style.opacity)&&(i=Mn(e.style.opacity));let o=10/r,a=`tag-${Hu()}`;e.setAttribute("dom-fade-tag",a),setTimeout(()=>{let t=setInterval(()=>{try{e.getAttribute("dom-fade-tag")!==a&&clearInterval(t),e.style.opacity=i,i<=0&&(clearInterval(t),e.removeAttribute("dom-fade-tag")),i-=o,i<0&&(i=0)}catch(e){console.log(e),clearInterval(t)}},10)},n)}let Ru='<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" x="0px" y="0px" viewBox="0 0 512.001 512.001" style="width:12px; height:12px; enable-background:new 0 0 512.001 512.001;" xml:space="preserve"><g><g><path d="M284.286,256.002L506.143,34.144c7.811-7.811,7.811-20.475,0-28.285c-7.811-7.81-20.475-7.811-28.285,0L256,227.717L34.143,5.859c-7.811-7.811-20.475-7.811-28.285,0c-7.81,7.811-7.811,20.475,0,28.285l221.857,221.857L5.858,477.859c-7.811,7.811-7.811,20.475,0,28.285c3.905,3.905,9.024,5.857,14.143,5.857c5.119,0,10.237-1.952,14.143-5.857L256,284.287l221.857,221.857c3.905,3.905,9.024,5.857,14.143,5.857s10.237-1.952,14.143-5.857c7.811-7.811,7.811-20.475,0-28.285L284.286,256.002z"/></g></g></svg>',Ou={success:'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" x="0px" y="0px" viewBox="0 0 426.667 426.667" style="width:24px; height:24px; enable-background:new 0 0 426.667 426.667" xml:space="preserve"><path style="fill:#6ac259" d="M213.333,0C95.518,0,0,95.514,0,213.333s95.518,213.333,213.333,213.333 c117.828,0,213.333-95.514,213.333-213.333S331.157,0,213.333,0z M174.199,322.918l-93.935-93.931l31.309-31.309l62.626,62.622 l140.894-140.898l31.309,31.309L174.199,322.918z"/></svg>',error:'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" x="0px" y="0px" viewBox="0 0 496.158 496.158" style="width:24px; height:24px; enable-background:new 0 0 496.158 496.158" xml:space="preserve"><path style="fill:#e04f5f" d="M496.158,248.085c0-137.021-111.07-248.082-248.076-248.082C111.07,0.003,0,111.063,0,248.085 c0,137.002,111.07,248.07,248.082,248.07C385.088,496.155,496.158,385.087,496.158,248.085z"/><path style="fill:#fff" d="M277.042,248.082l72.528-84.196c7.91-9.182,6.876-23.041-2.31-30.951 c-9.172-7.904-23.032-6.876-30.947,2.306l-68.236,79.212l-68.229-79.212c-7.91-9.188-21.771-10.216-30.954-2.306 c-9.186,7.91-10.214,21.77-2.304,30.951l72.522,84.196l-72.522,84.192c-7.91,9.182-6.882,23.041,2.304,30.951 c4.143,3.569,9.241,5.318,14.316,5.318c6.161,0,12.294-2.586,16.638-7.624l68.229-79.212l68.236,79.212 c4.338,5.041,10.47,7.624,16.637,7.624c5.069,0,10.168-1.749,14.311-5.318c9.186-7.91,10.22-21.77,2.31-30.951L277.042,248.082z"/></svg>',warning:'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" x="0px" y="0px" viewBox="0 0 497.472 497.472" style="width:24px; height:24px; enable-background:new 0 0 497.472 497.472" xml:space="preserve"><g transform="matrix(1.25 0 0 -1.25 0 45)"><path style="fill:#ffcc4d" d="M24.374-357.857c-20.958,0-30.197,15.223-20.548,33.826L181.421,17.928 c9.648,18.603,25.463,18.603,35.123,0L394.14-324.031c9.671-18.603,0.421-33.826-20.548-33.826H24.374z"/><path style="fill:#231f20" d="M173.605-80.922c0,14.814,10.934,23.984,25.395,23.984c14.12,0,25.407-9.512,25.407-23.984 V-216.75c0-14.461-11.287-23.984-25.407-23.984c-14.461,0-25.395,9.182-25.395,23.984V-80.922z M171.489-289.056 c0,15.167,12.345,27.511,27.511,27.511c15.167,0,27.523-12.345,27.523-27.511c0-15.178-12.356-27.523-27.523-27.523 C183.834-316.579,171.489-304.234,171.489-289.056"/></g></svg>',infor:'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" x="0px" y="0px" viewBox="0 0 496.16 496.16" style="width:24px; height:24px; enable-background:new 0 0 496.158 496.158;" xml:space="preserve"><path d="m496.16 248.08c0-137.02-111.07-248.08-248.08-248.08-137.01 0-248.08 111.06-248.08 248.08 0 137 111.07 248.07 248.08 248.07 137.01 0 248.08-111.07 248.08-248.07z" fill="#25B7D3"/><g fill="#fff"><path d="m315.25 359.56c-1.387-2.032-4.048-2.755-6.27-1.702-24.582 11.637-52.482 23.94-57.958 25.015-0.138-0.123-0.357-0.348-0.644-0.737-0.742-1.005-1.103-2.318-1.103-4.015 0-13.905 10.495-56.205 31.192-125.72 17.451-58.406 19.469-70.499 19.469-74.514 0-6.198-2.373-11.435-6.865-15.146-4.267-3.519-10.229-5.302-17.719-5.302-12.459 0-26.899 4.73-44.146 14.461-16.713 9.433-35.352 25.41-55.396 47.487-1.569 1.729-1.733 4.314-0.395 6.228 1.34 1.915 3.825 2.644 5.986 1.764 7.037-2.872 42.402-17.359 47.557-20.597 4.221-2.646 7.875-3.989 10.861-3.989 0.107 0 0.199 4e-3 0.276 0.01 0.036 0.198 0.07 0.5 0.07 0.933 0 3.047-0.627 6.654-1.856 10.703-30.136 97.641-44.785 157.5-44.785 182.99 0 8.998 2.501 16.242 7.432 21.528 5.025 5.393 11.803 8.127 20.146 8.127 8.891 0 19.712-3.714 33.08-11.354 12.936-7.392 32.68-23.653 60.363-49.717 1.793-1.687 2.092-4.426 0.705-6.458z"/><path d="m314.28 76.672c-4.925-5.041-11.227-7.597-18.729-7.597-9.34 0-17.475 3.691-24.176 10.971-6.594 7.16-9.938 15.946-9.938 26.113 0 8.033 2.463 14.69 7.32 19.785 4.922 5.172 11.139 7.794 18.476 7.794 8.958 0 17.049-3.898 24.047-11.586 6.876-7.553 10.363-16.433 10.363-26.393 1e-3 -7.654-2.476-14.075-7.363-19.087z"/></g></svg>',cancel:Ru},Tu={},Yu=null,ju=yn();function Gu(){Er(["top-right","top-left","bottom-right","bottom-left"],e=>{!function(e){let t=pa(Tu,{position:e});t=Oa(t,"timeStart");let r=16;Er(t,e=>{Tu[e.id].ele||(Tu[e.id].ele=document.querySelector(`#${e.id}`)),Tu[e.id].loc.top=r,Tu[e.id].loc.height=Tu[e.id].ele.offsetHeight,r+=Tu[e.id].loc.height+16}),Er(t,t=>{e.indexOf("bottom-")>=0?(Tu[t.id].ele.style.bottom=`${Tu[t.id].loc.top}px`,Tu[t.id].loc.bottom=Tu[t.id].loc.top):Tu[t.id].ele.style.top=`${Tu[t.id].loc.top}px`,e.indexOf("-left")>=0?(Tu[t.id].ele.style.left="16px",Tu[t.id].loc.left=16):(Tu[t.id].ele.style.right="16px",Tu[t.id].loc.right=16),Tu[t.id].ele.style.zIndex=2e5,Tu[t.id].ele.style.opacity=1,Tu[t.id].ele.style.transform="",Tu[t.id].ele.style.transform=null})}(e)})}function Ju(e){Tu[e].ele&&Tu[e].ele.parentNode.removeChild(Tu[e].ele),Tu[e]&&delete Tu[e],Gu()}function zu(e,t){if(!br(e))return"invalid eleParent";if(xe(t))e.insertAdjacentHTML("beforeend",t);else{if(!br(t))return"invalid itemChild";e.appendChild(t)}}function Vu(){return null!==navigator.userAgent.toLowerCase().match(/rv:([\d.]+)\) like gecko/)}function Pu(e){if(!e)return"invalid event";if(!e.cancelable)return"event is not cancelable";try{Vu()?e.cancelBubble=!0:e.stopPropagation(),e.preventDefault()}catch(e){}}var Xu;ju.ttWAlertCancel=function(e){Ju(e)},ju.ttWAlertFadeIn=function(e){Lu(document.querySelector(`#${e}`))},ju.ttWAlertFadeOut=function(e){Uu(document.querySelector(`#${e}`))},function(e){e.INSERT="insert",e.DELETE="delete",e.CONTEXT="context"}(Xu||(Xu={}));var _u;!function(e){e.AUTO="auto",e.DARK="dark",e.LIGHT="light"}(_u||(_u={}));const Wu=RegExp("["+["-","[","]","/","{","}","(",")","*","+","?",".","\\","^","$","|"].join("\\")+"]","g");function Ku(e){return e?e.replace(/\\/g,"/"):e}function $u(e){const t=e.length;let r=-1/0;for(let n=0;n<t;n++)r=Math.max(r,e[n]);return r}function Zu(e,t){const r=e.split(".");return r.length>1?r[r.length-1]:t}function ef(e,t){return t.reduce((t,r)=>t||e.startsWith(r),!1)}const tf=["a/","b/","i/","w/","c/","o/"];function rf(e,t,r){const n=void 0!==r?[...tf,r]:tf,i=t?new RegExp(`^${o=t,o.replace(Wu,"\\$&")} "?(.+?)"?$`):new RegExp('^"?(.+?)"?$');var o;const[,a=""]=i.exec(e)||[],s=n.find(e=>0===a.indexOf(e));return(s?a.slice(s.length):a).replace(/\s+\d{4}-\d{2}-\d{2} \d{2}:\d{2}:\d{2}(?:\.\d+)? [+-]\d{4}.*$/,"")}function nf(e,t={}){const r=[];let n=null,i=null,o=null,a=null,s=null,c=null,l=null;const u="--- ",f="+++ ",d="@@",g=/^old mode (\d{6})/,p=/^new mode (\d{6})/,h=/^deleted file mode (\d{6})/,A=/^new file mode (\d{6})/,m=/^copy from "?(.+)"?/,I=/^copy to "?(.+)"?/,y=/^rename from "?(.+)"?/,v=/^rename to "?(.+)"?/,b=/^similarity index (\d+)%/,w=/^dissimilarity index (\d+)%/,B=/^index ([\da-z]+)\.\.([\da-z]+)\s*(\d{6})?/,E=/^Binary files (.*) and (.*) differ/,C=/^GIT binary patch/,x=/^index ([\da-z]+),([\da-z]+)\.\.([\da-z]+)/,D=/^mode (\d{6}),(\d{6})\.\.(\d{6})/,F=/^new file mode (\d{6})/,Q=/^deleted file mode (\d{6}),(\d{6})/,S=e.replace(/\/g,"").replace(/\r\n?/g,"\n").split("\n");function k(){null!==i&&null!==n&&(n.blocks.push(i),i=null)}function N(){null!==n&&(n.oldName||null===c||(n.oldName=c),n.newName||null===l||(n.newName=l),n.newName&&(r.push(n),n=null)),c=null,l=null}function q(){k(),N(),n={blocks:[],deletedLines:0,addedLines:0}}function M(e){let t;k(),null!==n&&((t=/^@@ -(\d+)(?:,\d+)? \+(\d+)(?:,\d+)? @@.*/.exec(e))?(n.isCombined=!1,o=parseInt(t[1],10),s=parseInt(t[2],10)):(t=/^@@@ -(\d+)(?:,\d+)? -(\d+)(?:,\d+)? \+(\d+)(?:,\d+)? @@@.*/.exec(e))?(n.isCombined=!0,o=parseInt(t[1],10),a=parseInt(t[2],10),s=parseInt(t[3],10)):(e.startsWith(d)&&console.error("Failed to parse lines, starting in 0!"),o=0,s=0,n.isCombined=!1)),i={lines:[],oldStartLine:o,oldStartLine2:a,newStartLine:s,header:e}}return S.forEach((e,a)=>{if(!e||e.startsWith("*"))return;let k;const N=S[a-1],H=S[a+1],L=S[a+2];if(e.startsWith("diff --git")||e.startsWith("diff --combined")){q();if((k=/^diff --git "?([a-ciow]\/.+)"? "?([a-ciow]\/.+)"?/.exec(e))&&(c=rf(k[1],void 0,t.dstPrefix),l=rf(k[2],void 0,t.srcPrefix)),null===n)throw new Error("Where is my file !!!");return void(n.isGitDiff=!0)}if(e.startsWith("Binary files")&&!(null==n?void 0:n.isGitDiff)){q();if((k=/^Binary files "?([a-ciow]\/.+)"? and "?([a-ciow]\/.+)"? differ/.exec(e))&&(c=rf(k[1],void 0,t.dstPrefix),l=rf(k[2],void 0,t.srcPrefix)),null===n)throw new Error("Where is my file !!!");return void(n.isBinary=!0)}if((!n||!n.isGitDiff&&n&&e.startsWith(u)&&H.startsWith(f)&&L.startsWith(d))&&q(),null==n?void 0:n.isTooBig)return;if(n&&("number"==typeof t.diffMaxChanges&&n.addedLines+n.deletedLines>t.diffMaxChanges||"number"==typeof t.diffMaxLineLength&&e.length>t.diffMaxLineLength)){n.isTooBig=!0,n.addedLines=0,n.deletedLines=0,n.blocks=[],i=null;return void M("function"==typeof t.diffTooBigMessage?t.diffTooBigMessage(r.length):"Diff too big to be displayed")}if(e.startsWith(u)&&H.startsWith(f)||e.startsWith(f)&&N.startsWith(u)){if(n&&!n.oldName&&e.startsWith("--- ")&&(k=function(e,t){return rf(e,"---",t)}(e,t.srcPrefix)))return n.oldName=k,void(n.language=Zu(n.oldName,n.language));if(n&&!n.newName&&e.startsWith("+++ ")&&(k=function(e,t){return rf(e,"+++",t)}(e,t.dstPrefix)))return n.newName=k,void(n.language=Zu(n.newName,n.language))}if(n&&(e.startsWith(d)||n.isGitDiff&&n.oldName&&n.newName&&!i))return void M(e);if(i&&(e.startsWith("+")||e.startsWith("-")||e.startsWith(" ")))return void function(e){if(null===n||null===i||null===o||null===s)return;const t={content:e},r=n.isCombined?["+ "," +","++"]:["+"],a=n.isCombined?["- "," -","--"]:["-"];ef(e,r)?(n.addedLines++,t.type=Xu.INSERT,t.oldNumber=void 0,t.newNumber=s++):ef(e,a)?(n.deletedLines++,t.type=Xu.DELETE,t.oldNumber=o++,t.newNumber=void 0):(t.type=Xu.CONTEXT,t.oldNumber=o++,t.newNumber=s++),i.lines.push(t)}(e);const U=!function(e,t){let r=t;for(;r<S.length-3;){if(e.startsWith("diff"))return!1;if(S[r].startsWith(u)&&S[r+1].startsWith(f)&&S[r+2].startsWith(d))return!0;r++}return!1}(e,a);if(null===n)throw new Error("Where is my file !!!");(k=g.exec(e))?n.oldMode=k[1]:(k=p.exec(e))?n.newMode=k[1]:(k=h.exec(e))?(n.deletedFileMode=k[1],n.isDeleted=!0):(k=A.exec(e))?(n.newFileMode=k[1],n.isNew=!0):(k=m.exec(e))?(U&&(n.oldName=k[1]),n.isCopy=!0):(k=I.exec(e))?(U&&(n.newName=k[1]),n.isCopy=!0):(k=y.exec(e))?(U&&(n.oldName=k[1]),n.isRename=!0):(k=v.exec(e))?(U&&(n.newName=k[1]),n.isRename=!0):(k=E.exec(e))?(n.isBinary=!0,n.oldName=rf(k[1],void 0,t.srcPrefix),n.newName=rf(k[2],void 0,t.dstPrefix),M("Binary file")):C.test(e)?(n.isBinary=!0,M(e)):(k=b.exec(e))?n.unchangedPercentage=parseInt(k[1],10):(k=w.exec(e))?n.changedPercentage=parseInt(k[1],10):(k=B.exec(e))?(n.checksumBefore=k[1],n.checksumAfter=k[2],k[3]&&(n.mode=k[3])):(k=x.exec(e))?(n.checksumBefore=[k[2],k[3]],n.checksumAfter=k[1]):(k=D.exec(e))?(n.oldMode=[k[2],k[3]],n.newMode=k[1]):(k=F.exec(e))?(n.newFileMode=k[1],n.isNew=!0):(k=Q.exec(e))&&(n.deletedFileMode=k[1],n.isDeleted=!0)}),k(),N(),r}class of{diff(e,t,r={}){let n;"function"==typeof r?(n=r,r={}):"callback"in r&&(n=r.callback);const i=this.castInput(e,r),o=this.castInput(t,r),a=this.removeEmpty(this.tokenize(i,r)),s=this.removeEmpty(this.tokenize(o,r));return this.diffWithOptionsObj(a,s,r,n)}diffWithOptionsObj(e,t,r,n){var i;const o=e=>(e=this.postProcess(e,r),n?void setTimeout(function(){n(e)},0):e),a=t.length,s=e.length;let c=1,l=a+s;null!=r.maxEditLength&&(l=Math.min(l,r.maxEditLength));const u=null!==(i=r.timeout)&&void 0!==i?i:1/0,f=Date.now()+u,d=[{oldPos:-1,lastComponent:void 0}];let g=this.extractCommon(d[0],t,e,0,r);if(d[0].oldPos+1>=s&&g+1>=a)return o(this.buildValues(d[0].lastComponent,t,e));let p=-1/0,h=1/0;const A=()=>{for(let n=Math.max(p,-c);n<=Math.min(h,c);n+=2){let i;const c=d[n-1],l=d[n+1];c&&(d[n-1]=void 0);let u=!1;if(l){const e=l.oldPos-n;u=l&&0<=e&&e<a}const f=c&&c.oldPos+1<s;if(u||f){if(i=!f||u&&c.oldPos<l.oldPos?this.addToPath(l,!0,!1,0,r):this.addToPath(c,!1,!0,1,r),g=this.extractCommon(i,t,e,n,r),i.oldPos+1>=s&&g+1>=a)return o(this.buildValues(i.lastComponent,t,e))||!0;d[n]=i,i.oldPos+1>=s&&(h=Math.min(h,n-1)),g+1>=a&&(p=Math.max(p,n+1))}else d[n]=void 0}c++};if(n)!function e(){setTimeout(function(){if(c>l||Date.now()>f)return n(void 0);A()||e()},0)}();else for(;c<=l&&Date.now()<=f;){const e=A();if(e)return e}}addToPath(e,t,r,n,i){const o=e.lastComponent;return o&&!i.oneChangePerToken&&o.added===t&&o.removed===r?{oldPos:e.oldPos+n,lastComponent:{count:o.count+1,added:t,removed:r,previousComponent:o.previousComponent}}:{oldPos:e.oldPos+n,lastComponent:{count:1,added:t,removed:r,previousComponent:o}}}extractCommon(e,t,r,n,i){const o=t.length,a=r.length;let s=e.oldPos,c=s-n,l=0;for(;c+1<o&&s+1<a&&this.equals(r[s+1],t[c+1],i);)c++,s++,l++,i.oneChangePerToken&&(e.lastComponent={count:1,previousComponent:e.lastComponent,added:!1,removed:!1});return l&&!i.oneChangePerToken&&(e.lastComponent={count:l,previousComponent:e.lastComponent,added:!1,removed:!1}),e.oldPos=s,c}equals(e,t,r){return r.comparator?r.comparator(e,t):e===t||!!r.ignoreCase&&e.toLowerCase()===t.toLowerCase()}removeEmpty(e){const t=[];for(let r=0;r<e.length;r++)e[r]&&t.push(e[r]);return t}castInput(e,t){return e}tokenize(e,t){return Array.from(e)}join(e){return e.join("")}postProcess(e,t){return e}get useLongestToken(){return!1}buildValues(e,t,r){const n=[];let i;for(;e;)n.push(e),i=e.previousComponent,delete e.previousComponent,e=i;n.reverse();const o=n.length;let a=0,s=0,c=0;for(;a<o;a++){const e=n[a];if(e.removed)e.value=this.join(r.slice(c,c+e.count)),c+=e.count;else{if(!e.added&&this.useLongestToken){let n=t.slice(s,s+e.count);n=n.map(function(e,t){const n=r[c+t];return n.length>e.length?n:e}),e.value=this.join(n)}else e.value=this.join(t.slice(s,s+e.count));s+=e.count,e.added||(c+=e.count)}}return n}}const af=new class extends of{};const sf="a-zA-Z0-9_\\u{AD}\\u{C0}-\\u{D6}\\u{D8}-\\u{F6}\\u{F8}-\\u{2C6}\\u{2C8}-\\u{2D7}\\u{2DE}-\\u{2FF}\\u{1E00}-\\u{1EFF}";const cf=new class extends of{tokenize(e){const t=new RegExp(`(\\r?\\n)|[${sf}]+|[^\\S\\n\\r]+|[^${sf}]`,"ug");return e.match(t)||[]}};function lf(e){return(t,r)=>{const n=e(t).trim(),i=e(r).trim();return function(e,t){if(0===e.length)return t.length;if(0===t.length)return e.length;const r=[];let n,i;for(n=0;n<=t.length;n++)r[n]=[n];for(i=0;i<=e.length;i++)r[0][i]=i;for(n=1;n<=t.length;n++)for(i=1;i<=e.length;i++)t.charAt(n-1)===e.charAt(i-1)?r[n][i]=r[n-1][i-1]:r[n][i]=Math.min(r[n-1][i-1]+1,Math.min(r[n][i-1]+1,r[n-1][i]+1));return r[t.length][e.length]}(n,i)/(n.length+i.length)}}function uf(e){return function t(r,n,i=0,o=new Map){const a=function(t,r,n=new Map){let i,o=1/0;for(let a=0;a<t.length;++a)for(let s=0;s<r.length;++s){const c=JSON.stringify([t[a],r[s]]);let l;n.has(c)&&(l=n.get(c))||(l=e(t[a],r[s]),n.set(c,l)),l<o&&(o=l,i={indexA:a,indexB:s,score:o})}return i}(r,n,o);if(!a||r.length+n.length<3)return[[r,n]];const s=r.slice(0,a.indexA),c=n.slice(0,a.indexB),l=[r[a.indexA]],u=[n[a.indexB]],f=a.indexA+1,d=a.indexB+1,g=r.slice(f),p=n.slice(d),h=t(s,c,i+1,o),A=t(l,u,i+1,o),m=t(g,p,i+1,o);let I=A;return(a.indexA>0||a.indexB>0)&&(I=h.concat(I)),(r.length>f||n.length>d)&&(I=I.concat(m)),I}}const ff={INSERTS:"d2h-ins",DELETES:"d2h-del",CONTEXT:"d2h-cntx",INFO:"d2h-info",INSERT_CHANGES:"d2h-ins d2h-change",DELETE_CHANGES:"d2h-del d2h-change"},df={matching:"none",matchWordsThreshold:.25,maxLineLengthHighlight:1e4,diffStyle:"word",colorScheme:_u.LIGHT},gf="/",pf=lf(e=>e.value),hf=uf(pf);function Af(e){return-1!==e.indexOf("dev/null")}function mf(e){return e.replace(/(<del[^>]*>((.|\n)*?)<\/del>)/g,"")}function If(e){switch(e){case Xu.CONTEXT:return ff.CONTEXT;case Xu.INSERT:return ff.INSERTS;case Xu.DELETE:return ff.DELETES}}function yf(e){switch(e){case _u.DARK:return"d2h-dark-color-scheme";case _u.AUTO:return"d2h-auto-color-scheme";case _u.LIGHT:default:return"d2h-light-color-scheme"}}function vf(e){return e.slice(0).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;").replace(/\//g,"&#x2F;")}function bf(e,t,r=!0){const n=function(e){return e?2:1}(t);return{prefix:e.substring(0,n),content:r?vf(e.substring(n)):e.substring(n)}}function wf(e){const t=Ku(e.oldName),r=Ku(e.newName);if(t===r||Af(t)||Af(r))return Af(r)?t:r;{const e=[],n=[],i=t.split(gf),o=r.split(gf);let a=0,s=i.length-1,c=o.length-1;for(;a<s&&a<c&&i[a]===o[a];)e.push(o[a]),a+=1;for(;s>a&&c>a&&i[s]===o[c];)n.unshift(o[c]),s-=1,c-=1;const l=e.join(gf),u=n.join(gf),f=i.slice(a,s+1).join(gf),d=o.slice(a,c+1).join(gf);return l.length&&u.length?l+gf+"{"+f+" → "+d+"}"+gf+u:l.length?l+gf+"{"+f+" → "+d+"}":u.length?"{"+f+" → "+d+"}"+gf+u:t+" → "+r}}function Bf(e){return`d2h-${function(e){let t,r,n,i=0;for(t=0,n=e.length;t<n;t++)r=e.charCodeAt(t),i=(i<<5)-i+r,i|=0;return i}(wf(e)).toString().slice(-6)}`}function Ef(e){let t="file-changed";return e.isRename||e.isCopy?t="file-renamed":e.isNew?t="file-added":e.isDeleted?t="file-deleted":e.newName!==e.oldName&&(t="file-renamed"),t}function Cf(e,t,r,n={}){const{matching:i,maxLineLengthHighlight:o,matchWordsThreshold:a,diffStyle:s}=Object.assign(Object.assign({},df),n),c=bf(e,r,!1),l=bf(t,r,!1);if(c.content.length>o||l.content.length>o)return{oldLine:{prefix:c.prefix,content:vf(c.content)},newLine:{prefix:l.prefix,content:vf(l.content)}};const u="char"===s?(f=c.content,d=l.content,af.diff(f,d,g)):function(e,t,r){return cf.diff(e,t,r)}(c.content,l.content);var f,d,g;const p=[];if("word"===s&&"words"===i){const e=u.filter(e=>e.removed),t=u.filter(e=>e.added);hf(t,e).forEach(e=>{if(1===e[0].length&&1===e[1].length){pf(e[0][0],e[1][0])<a&&(p.push(e[0][0]),p.push(e[1][0]))}})}const h=u.reduce((e,t)=>{const r=t.added?"ins":t.removed?"del":null,n=p.indexOf(t)>-1?' class="d2h-change"':"",i=vf(t.value);return null!==r?`${e}<${r}${n}>${i}</${r}>`:`${e}${i}`},"");return{oldLine:{prefix:c.prefix,content:(A=h,A.replace(/(<ins[^>]*>((.|\n)*?)<\/ins>)/g,""))},newLine:{prefix:l.prefix,content:mf(h)}};var A}const xf="file-summary",Df={colorScheme:df.colorScheme};class Ff{constructor(e,t={}){this.hoganUtils=e,this.config=Object.assign(Object.assign({},Df),t)}render(e){const t=e.map(e=>this.hoganUtils.render(xf,"line",{fileHtmlId:Bf(e),oldName:e.oldName,newName:e.newName,fileName:wf(e),deletedLines:"-"+e.deletedLines,addedLines:"+"+e.addedLines},{fileIcon:this.hoganUtils.template("icon",Ef(e))})).join("\n");return this.hoganUtils.render(xf,"wrapper",{colorScheme:yf(this.config.colorScheme),filesNumber:e.length,files:t})}}const Qf=Object.assign(Object.assign({},df),{renderNothingWhenEmpty:!1,matchingMaxComparisons:2500,maxLineSizeInBlockForComparison:200}),Sf="generic",kf="line-by-line";class Nf{constructor(e,t={}){this.hoganUtils=e,this.config=Object.assign(Object.assign({},Qf),t)}render(e){const t=e.map(e=>{let t;return t=e.blocks.length?this.generateFileHtml(e):this.generateEmptyDiff(),this.makeFileDiffHtml(e,t)}).join("\n");return this.hoganUtils.render(Sf,"wrapper",{colorScheme:yf(this.config.colorScheme),content:t})}makeFileDiffHtml(e,t){if(this.config.renderNothingWhenEmpty&&Array.isArray(e.blocks)&&0===e.blocks.length)return"";const r=this.hoganUtils.template(kf,"file-diff"),n=this.hoganUtils.template(Sf,"file-path"),i=this.hoganUtils.template("icon","file"),o=this.hoganUtils.template("tag",Ef(e));return r.render({file:e,fileHtmlId:Bf(e),diffs:t,filePath:n.render({fileDiffName:wf(e)},{fileIcon:i,fileTag:o})})}generateEmptyDiff(){return this.hoganUtils.render(Sf,"empty-diff",{contentClass:"d2h-code-line",CSSLineClass:ff})}generateFileHtml(e){const t=uf(lf(t=>bf(t.content,e.isCombined).content));return e.blocks.map(r=>{let n=this.hoganUtils.render(Sf,"block-header",{CSSLineClass:ff,blockHeader:e.isTooBig?r.header:vf(r.header),lineClass:"d2h-code-linenumber",contentClass:"d2h-code-line"});return this.applyLineGroupping(r).forEach(([r,i,o])=>{if(i.length&&o.length&&!r.length)this.applyRematchMatching(i,o,t).map(([t,r])=>{const{left:i,right:o}=this.processChangedLines(e,e.isCombined,t,r);n+=i,n+=o});else if(r.length)r.forEach(t=>{const{prefix:r,content:i}=bf(t.content,e.isCombined);n+=this.generateSingleLineHtml(e,{type:ff.CONTEXT,prefix:r,content:i,oldNumber:t.oldNumber,newNumber:t.newNumber})});else if(i.length||o.length){const{left:t,right:r}=this.processChangedLines(e,e.isCombined,i,o);n+=t,n+=r}else console.error("Unknown state reached while processing groups of lines",r,i,o)}),n}).join("\n")}applyLineGroupping(e){const t=[];let r=[],n=[];for(let i=0;i<e.lines.length;i++){const o=e.lines[i];(o.type!==Xu.INSERT&&n.length||o.type===Xu.CONTEXT&&r.length>0)&&(t.push([[],r,n]),r=[],n=[]),o.type===Xu.CONTEXT?t.push([[o],[],[]]):o.type===Xu.INSERT&&0===r.length?t.push([[],[],[o]]):o.type===Xu.INSERT&&r.length>0?n.push(o):o.type===Xu.DELETE&&r.push(o)}return(r.length||n.length)&&(t.push([[],r,n]),r=[],n=[]),t}applyRematchMatching(e,t,r){const n=e.length*t.length,i=$u(e.concat(t).map(e=>e.content.length));return n<this.config.matchingMaxComparisons&&i<this.config.maxLineSizeInBlockForComparison&&("lines"===this.config.matching||"words"===this.config.matching)?r(e,t):[[e,t]]}processChangedLines(e,t,r,n){const i={right:"",left:""},o=Math.max(r.length,n.length);for(let a=0;a<o;a++){const o=r[a],s=n[a],c=void 0!==o&&void 0!==s?Cf(o.content,s.content,t,this.config):void 0,l=void 0!==o&&void 0!==o.oldNumber?Object.assign(Object.assign({},void 0!==c?{prefix:c.oldLine.prefix,content:c.oldLine.content,type:ff.DELETE_CHANGES}:Object.assign(Object.assign({},bf(o.content,t)),{type:If(o.type)})),{oldNumber:o.oldNumber,newNumber:o.newNumber}):void 0,u=void 0!==s&&void 0!==s.newNumber?Object.assign(Object.assign({},void 0!==c?{prefix:c.newLine.prefix,content:c.newLine.content,type:ff.INSERT_CHANGES}:Object.assign(Object.assign({},bf(s.content,t)),{type:If(s.type)})),{oldNumber:s.oldNumber,newNumber:s.newNumber}):void 0,{left:f,right:d}=this.generateLineHtml(e,l,u);i.left+=f,i.right+=d}return i}generateLineHtml(e,t,r){return{left:this.generateSingleLineHtml(e,t),right:this.generateSingleLineHtml(e,r)}}generateSingleLineHtml(e,t){if(void 0===t)return"";const r=this.hoganUtils.render(kf,"numbers",{oldNumber:t.oldNumber||"",newNumber:t.newNumber||""});return this.hoganUtils.render(Sf,"line",{type:t.type,lineClass:"d2h-code-linenumber",contentClass:"d2h-code-line",prefix:" "===t.prefix?"&nbsp;":t.prefix,content:t.content,lineNumber:r,line:t,file:e})}}const qf=Object.assign(Object.assign({},df),{renderNothingWhenEmpty:!1,matchingMaxComparisons:2500,maxLineSizeInBlockForComparison:200}),Mf="generic";class Hf{constructor(e,t={}){this.hoganUtils=e,this.config=Object.assign(Object.assign({},qf),t)}render(e){const t=e.map(e=>{let t;return t=e.blocks.length?this.generateFileHtml(e):this.generateEmptyDiff(),this.makeFileDiffHtml(e,t)}).join("\n");return this.hoganUtils.render(Mf,"wrapper",{colorScheme:yf(this.config.colorScheme),content:t})}makeFileDiffHtml(e,t){if(this.config.renderNothingWhenEmpty&&Array.isArray(e.blocks)&&0===e.blocks.length)return"";const r=this.hoganUtils.template("side-by-side","file-diff"),n=this.hoganUtils.template(Mf,"file-path"),i=this.hoganUtils.template("icon","file"),o=this.hoganUtils.template("tag",Ef(e));return r.render({file:e,fileHtmlId:Bf(e),diffs:t,filePath:n.render({fileDiffName:wf(e)},{fileIcon:i,fileTag:o})})}generateEmptyDiff(){return{right:"",left:this.hoganUtils.render(Mf,"empty-diff",{contentClass:"d2h-code-side-line",CSSLineClass:ff})}}generateFileHtml(e){const t=uf(lf(t=>bf(t.content,e.isCombined).content));return e.blocks.map(r=>{const n={left:this.makeHeaderHtml(r.header,e),right:this.makeHeaderHtml("")};return this.applyLineGroupping(r).forEach(([r,i,o])=>{if(i.length&&o.length&&!r.length)this.applyRematchMatching(i,o,t).map(([t,r])=>{const{left:i,right:o}=this.processChangedLines(e.isCombined,t,r);n.left+=i,n.right+=o});else if(r.length)r.forEach(t=>{const{prefix:r,content:i}=bf(t.content,e.isCombined),{left:o,right:a}=this.generateLineHtml({type:ff.CONTEXT,prefix:r,content:i,number:t.oldNumber},{type:ff.CONTEXT,prefix:r,content:i,number:t.newNumber});n.left+=o,n.right+=a});else if(i.length||o.length){const{left:t,right:r}=this.processChangedLines(e.isCombined,i,o);n.left+=t,n.right+=r}else console.error("Unknown state reached while processing groups of lines",r,i,o)}),n}).reduce((e,t)=>({left:e.left+t.left,right:e.right+t.right}),{left:"",right:""})}applyLineGroupping(e){const t=[];let r=[],n=[];for(let i=0;i<e.lines.length;i++){const o=e.lines[i];(o.type!==Xu.INSERT&&n.length||o.type===Xu.CONTEXT&&r.length>0)&&(t.push([[],r,n]),r=[],n=[]),o.type===Xu.CONTEXT?t.push([[o],[],[]]):o.type===Xu.INSERT&&0===r.length?t.push([[],[],[o]]):o.type===Xu.INSERT&&r.length>0?n.push(o):o.type===Xu.DELETE&&r.push(o)}return(r.length||n.length)&&(t.push([[],r,n]),r=[],n=[]),t}applyRematchMatching(e,t,r){const n=e.length*t.length,i=$u(e.concat(t).map(e=>e.content.length));return n<this.config.matchingMaxComparisons&&i<this.config.maxLineSizeInBlockForComparison&&("lines"===this.config.matching||"words"===this.config.matching)?r(e,t):[[e,t]]}makeHeaderHtml(e,t){return this.hoganUtils.render(Mf,"block-header",{CSSLineClass:ff,blockHeader:(null==t?void 0:t.isTooBig)?e:vf(e),lineClass:"d2h-code-side-linenumber",contentClass:"d2h-code-side-line"})}processChangedLines(e,t,r){const n={right:"",left:""},i=Math.max(t.length,r.length);for(let o=0;o<i;o++){const i=t[o],a=r[o],s=void 0!==i&&void 0!==a?Cf(i.content,a.content,e,this.config):void 0,c=void 0!==i&&void 0!==i.oldNumber?Object.assign(Object.assign({},void 0!==s?{prefix:s.oldLine.prefix,content:s.oldLine.content,type:ff.DELETE_CHANGES}:Object.assign(Object.assign({},bf(i.content,e)),{type:If(i.type)})),{number:i.oldNumber}):void 0,l=void 0!==a&&void 0!==a.newNumber?Object.assign(Object.assign({},void 0!==s?{prefix:s.newLine.prefix,content:s.newLine.content,type:ff.INSERT_CHANGES}:Object.assign(Object.assign({},bf(a.content,e)),{type:If(a.type)})),{number:a.newNumber}):void 0,{left:u,right:f}=this.generateLineHtml(c,l);n.left+=u,n.right+=f}return n}generateLineHtml(e,t){return{left:this.generateSingleHtml(e),right:this.generateSingleHtml(t)}}generateSingleHtml(e){const t="d2h-code-side-linenumber",r="d2h-code-side-line";return this.hoganUtils.render(Mf,"line",{type:(null==e?void 0:e.type)||`${ff.CONTEXT} d2h-emptyplaceholder`,lineClass:void 0!==e?t:`${t} d2h-code-side-emptyplaceholder`,contentClass:void 0!==e?r:`${r} d2h-code-side-emptyplaceholder`,prefix:" "===(null==e?void 0:e.prefix)?"&nbsp;":null==e?void 0:e.prefix,content:null==e?void 0:e.content,lineNumber:null==e?void 0:e.number})}}var Lf={};!function(e){!function(e){var t=/\S/,r=/\"/g,n=/\n/g,i=/\r/g,o=/\\/g,a=/\u2028/,s=/\u2029/;function c(e){"}"===e.n.substr(e.n.length-1)&&(e.n=e.n.substring(0,e.n.length-1))}function l(e){return e.trim?e.trim():e.replace(/^\s*|\s*$/g,"")}function u(e,t,r){if(t.charAt(r)!=e.charAt(0))return!1;for(var n=1,i=e.length;n<i;n++)if(t.charAt(r+n)!=e.charAt(n))return!1;return!0}e.tags={"#":1,"^":2,"<":3,$:4,"/":5,"!":6,">":7,"=":8,_v:9,"{":10,"&":11,_t:12},e.scan=function(r,n){var i=r.length,o=0,a=null,s=null,f="",d=[],g=!1,p=0,h=0,A="{{",m="}}";function I(){f.length>0&&(d.push({tag:"_t",text:new String(f)}),f="")}function y(r,n){if(I(),r&&function(){for(var r=!0,n=h;n<d.length;n++)if(!(r=e.tags[d[n].tag]<e.tags._v||"_t"==d[n].tag&&null===d[n].text.match(t)))return!1;return r}())for(var i,o=h;o<d.length;o++)d[o].text&&((i=d[o+1])&&">"==i.tag&&(i.indent=d[o].text.toString()),d.splice(o,1));else n||d.push({tag:"\n"});g=!1,h=d.length}function v(e,t){var r="="+m,n=e.indexOf(r,t),i=l(e.substring(e.indexOf("=",t)+1,n)).split(" ");return A=i[0],m=i[i.length-1],n+r.length-1}for(n&&(n=n.split(" "),A=n[0],m=n[1]),p=0;p<i;p++)0==o?u(A,r,p)?(--p,I(),o=1):"\n"==r.charAt(p)?y(g):f+=r.charAt(p):1==o?(p+=A.length-1,"="==(a=(s=e.tags[r.charAt(p+1)])?r.charAt(p+1):"_v")?(p=v(r,p),o=0):(s&&p++,o=2),g=p):u(m,r,p)?(d.push({tag:a,n:l(f),otag:A,ctag:m,i:"/"==a?g-A.length:p+m.length}),f="",p+=m.length-1,o=0,"{"==a&&("}}"==m?p++:c(d[d.length-1]))):f+=r.charAt(p);return y(g,!0),d};var f={_t:!0,"\n":!0,$:!0,"/":!0};function d(t,r,n,i){var o,a=[],s=null,c=null;for(o=n[n.length-1];t.length>0;){if(c=t.shift(),o&&"<"==o.tag&&!(c.tag in f))throw new Error("Illegal content in < super tag.");if(e.tags[c.tag]<=e.tags.$||g(c,i))n.push(c),c.nodes=d(t,c.tag,n,i);else{if("/"==c.tag){if(0===n.length)throw new Error("Closing tag without opener: /"+c.n);if(s=n.pop(),c.n!=s.n&&!p(c.n,s.n,i))throw new Error("Nesting error: "+s.n+" vs. "+c.n);return s.end=c.i,a}"\n"==c.tag&&(c.last=0==t.length||"\n"==t[0].tag)}a.push(c)}if(n.length>0)throw new Error("missing closing tag: "+n.pop().n);return a}function g(e,t){for(var r=0,n=t.length;r<n;r++)if(t[r].o==e.n)return e.tag="#",!0}function p(e,t,r){for(var n=0,i=r.length;n<i;n++)if(r[n].c==e&&r[n].o==t)return!0}function h(e){var t=[];for(var r in e.partials)t.push('"'+m(r)+'":{name:"'+m(e.partials[r].name)+'", '+h(e.partials[r])+"}");return"partials: {"+t.join(",")+"}, subs: "+function(e){var t=[];for(var r in e)t.push('"'+m(r)+'": function(c,p,t,i) {'+e[r]+"}");return"{ "+t.join(",")+" }"}(e.subs)}e.stringify=function(t,r,n){return"{code: function (c,p,i) { "+e.wrapMain(t.code)+" },"+h(t)+"}"};var A=0;function m(e){return e.replace(o,"\\\\").replace(r,'\\"').replace(n,"\\n").replace(i,"\\r").replace(a,"\\u2028").replace(s,"\\u2029")}function I(e){return~e.indexOf(".")?"d":"f"}function y(e,t){var r="<"+(t.prefix||"")+e.n+A++;return t.partials[r]={name:e.n,partials:{}},t.code+='t.b(t.rp("'+m(r)+'",c,p,"'+(e.indent||"")+'"));',r}function v(e,t){t.code+="t.b(t.t(t."+I(e.n)+'("'+m(e.n)+'",c,p,0)));'}function b(e){return"t.b("+e+");"}e.generate=function(t,r,n){A=0;var i={code:"",subs:{},partials:{}};return e.walk(t,i),n.asString?this.stringify(i,r,n):this.makeTemplate(i,r,n)},e.wrapMain=function(e){return'var t=this;t.b(i=i||"");'+e+"return t.fl();"},e.template=e.Template,e.makeTemplate=function(e,t,r){var n=this.makePartials(e);return n.code=new Function("c","p","i",this.wrapMain(e.code)),new this.template(n,t,this,r)},e.makePartials=function(e){var t,r={subs:{},partials:e.partials,name:e.name};for(t in r.partials)r.partials[t]=this.makePartials(r.partials[t]);for(t in e.subs)r.subs[t]=new Function("c","p","t","i",e.subs[t]);return r},e.codegen={"#":function(t,r){r.code+="if(t.s(t."+I(t.n)+'("'+m(t.n)+'",c,p,1),c,p,0,'+t.i+","+t.end+',"'+t.otag+" "+t.ctag+'")){t.rs(c,p,function(c,p,t){',e.walk(t.nodes,r),r.code+="});c.pop();}"},"^":function(t,r){r.code+="if(!t.s(t."+I(t.n)+'("'+m(t.n)+'",c,p,1),c,p,1,0,0,"")){',e.walk(t.nodes,r),r.code+="};"},">":y,"<":function(t,r){var n={partials:{},code:"",subs:{},inPartial:!0};e.walk(t.nodes,n);var i=r.partials[y(t,r)];i.subs=n.subs,i.partials=n.partials},$:function(t,r){var n={subs:{},code:"",partials:r.partials,prefix:t.n};e.walk(t.nodes,n),r.subs[t.n]=n.code,r.inPartial||(r.code+='t.sub("'+m(t.n)+'",c,p,i);')},"\n":function(e,t){t.code+=b('"\\n"'+(e.last?"":" + i"))},_v:function(e,t){t.code+="t.b(t.v(t."+I(e.n)+'("'+m(e.n)+'",c,p,0)));'},_t:function(e,t){t.code+=b('"'+m(e.text)+'"')},"{":v,"&":v},e.walk=function(t,r){for(var n,i=0,o=t.length;i<o;i++)(n=e.codegen[t[i].tag])&&n(t[i],r);return r},e.parse=function(e,t,r){return d(e,0,[],(r=r||{}).sectionTags||[])},e.cache={},e.cacheKey=function(e,t){return[e,!!t.asString,!!t.disableLambda,t.delimiters,!!t.modelGet].join("||")},e.compile=function(t,r){r=r||{};var n=e.cacheKey(t,r),i=this.cache[n];if(i){var o=i.partials;for(var a in o)delete o[a].instance;return i}return i=this.generate(this.parse(this.scan(t,r.delimiters),t,r),t,r),this.cache[n]=i}}(e)}(Lf);var Uf={};!function(e){!function(e){function t(e,t,r){var n;return t&&"object"==typeof t&&(void 0!==t[e]?n=t[e]:r&&t.get&&"function"==typeof t.get&&(n=t.get(e))),n}e.Template=function(e,t,r,n){e=e||{},this.r=e.code||this.r,this.c=r,this.options=n||{},this.text=t||"",this.partials=e.partials||{},this.subs=e.subs||{},this.buf=""},e.Template.prototype={r:function(e,t,r){return""},v:function(e){return e=c(e),s.test(e)?e.replace(r,"&amp;").replace(n,"&lt;").replace(i,"&gt;").replace(o,"&#39;").replace(a,"&quot;"):e},t:c,render:function(e,t,r){return this.ri([e],t||{},r)},ri:function(e,t,r){return this.r(e,t,r)},ep:function(e,t){var r=this.partials[e],n=t[r.name];if(r.instance&&r.base==n)return r.instance;if("string"==typeof n){if(!this.c)throw new Error("No compiler available.");n=this.c.compile(n,this.options)}if(!n)return null;if(this.partials[e].base=n,r.subs){for(key in t.stackText||(t.stackText={}),r.subs)t.stackText[key]||(t.stackText[key]=void 0!==this.activeSub&&t.stackText[this.activeSub]?t.stackText[this.activeSub]:this.text);n=function(e,t,r,n,i,o){function a(){}function s(){}var c;a.prototype=e,s.prototype=e.subs;var l=new a;for(c in l.subs=new s,l.subsText={},l.buf="",n=n||{},l.stackSubs=n,l.subsText=o,t)n[c]||(n[c]=t[c]);for(c in n)l.subs[c]=n[c];for(c in i=i||{},l.stackPartials=i,r)i[c]||(i[c]=r[c]);for(c in i)l.partials[c]=i[c];return l}(n,r.subs,r.partials,this.stackSubs,this.stackPartials,t.stackText)}return this.partials[e].instance=n,n},rp:function(e,t,r,n){var i=this.ep(e,r);return i?i.ri(t,r,n):""},rs:function(e,t,r){var n=e[e.length-1];if(l(n))for(var i=0;i<n.length;i++)e.push(n[i]),r(e,t,this),e.pop();else r(e,t,this)},s:function(e,t,r,n,i,o,a){var s;return(!l(e)||0!==e.length)&&("function"==typeof e&&(e=this.ms(e,t,r,n,i,o,a)),s=!!e,!n&&s&&t&&t.push("object"==typeof e?e:t[t.length-1]),s)},d:function(e,r,n,i){var o,a=e.split("."),s=this.f(a[0],r,n,i),c=this.options.modelGet,u=null;if("."===e&&l(r[r.length-2]))s=r[r.length-1];else for(var f=1;f<a.length;f++)void 0!==(o=t(a[f],s,c))?(u=s,s=o):s="";return!(i&&!s)&&(i||"function"!=typeof s||(r.push(u),s=this.mv(s,r,n),r.pop()),s)},f:function(e,r,n,i){for(var o=!1,a=!1,s=this.options.modelGet,c=r.length-1;c>=0;c--)if(void 0!==(o=t(e,r[c],s))){a=!0;break}return a?(i||"function"!=typeof o||(o=this.mv(o,r,n)),o):!i&&""},ls:function(e,t,r,n,i,o){var a=this.options.delimiters;return this.options.delimiters=o,this.b(this.ct(c(e.call(t,i,r)),t,n)),this.options.delimiters=a,!1},ct:function(e,t,r){if(this.options.disableLambda)throw new Error("Lambda features disabled.");return this.c.compile(e,this.options).render(t,r)},b:function(e){this.buf+=e},fl:function(){var e=this.buf;return this.buf="",e},ms:function(e,t,r,n,i,o,a){var s,c=t[t.length-1],l=e.call(c);return"function"==typeof l?!!n||(s=this.activeSub&&this.subsText&&this.subsText[this.activeSub]?this.subsText[this.activeSub]:this.text,this.ls(l,c,t,r,s.substring(i,o),a)):l},mv:function(e,t,r){var n=t[t.length-1],i=e.call(n);return"function"==typeof i?this.ct(c(i.call(n)),n,r):i},sub:function(e,t,r,n){var i=this.subs[e];i&&(this.activeSub=e,i(t,r,this,n),this.activeSub=!1)}};var r=/&/g,n=/</g,i=/>/g,o=/\'/g,a=/\"/g,s=/[&<>\"\']/;function c(e){return String(null==e?"":e)}var l=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}}(e)}(Uf);var Rf=Lf;Rf.Template=Uf.Template,Rf.template=Rf.Template;var Of=Rf;const Tf={};Tf["file-summary-line"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<li class="d2h-file-list-line">'),n.b("\n"+r),n.b(' <span class="d2h-file-name-wrapper">'),n.b("\n"+r),n.b(n.rp("<fileIcon0",e,t," ")),n.b(' <a href="#'),n.b(n.v(n.f("fileHtmlId",e,t,0))),n.b('" class="d2h-file-name">'),n.b(n.v(n.f("fileName",e,t,0))),n.b("</a>"),n.b("\n"+r),n.b(' <span class="d2h-file-stats">'),n.b("\n"+r),n.b(' <span class="d2h-lines-added">'),n.b(n.v(n.f("addedLines",e,t,0))),n.b("</span>"),n.b("\n"+r),n.b(' <span class="d2h-lines-deleted">'),n.b(n.v(n.f("deletedLines",e,t,0))),n.b("</span>"),n.b("\n"+r),n.b(" </span>"),n.b("\n"+r),n.b(" </span>"),n.b("\n"+r),n.b("</li>"),n.fl()},partials:{"<fileIcon0":{name:"fileIcon",partials:{},subs:{}}},subs:{}}),Tf["file-summary-wrapper"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<div class="d2h-file-list-wrapper '),n.b(n.v(n.f("colorScheme",e,t,0))),n.b('">'),n.b("\n"+r),n.b(' <div class="d2h-file-list-header">'),n.b("\n"+r),n.b(' <span class="d2h-file-list-title">Files changed ('),n.b(n.v(n.f("filesNumber",e,t,0))),n.b(")</span>"),n.b("\n"+r),n.b(' <a class="d2h-file-switch d2h-hide">hide</a>'),n.b("\n"+r),n.b(' <a class="d2h-file-switch d2h-show">show</a>'),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(' <ol class="d2h-file-list">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.f("files",e,t,0))),n.b("\n"+r),n.b(" </ol>"),n.b("\n"+r),n.b("</div>"),n.fl()},partials:{},subs:{}}),Tf["generic-block-header"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b("<tr>"),n.b("\n"+r),n.b(' <td class="'),n.b(n.v(n.f("lineClass",e,t,0))),n.b(" "),n.b(n.v(n.d("CSSLineClass.INFO",e,t,0))),n.b('"></td>'),n.b("\n"+r),n.b(' <td class="'),n.b(n.v(n.d("CSSLineClass.INFO",e,t,0))),n.b('">'),n.b("\n"+r),n.b(' <div class="'),n.b(n.v(n.f("contentClass",e,t,0))),n.b('">'),n.s(n.f("blockHeader",e,t,1),e,t,0,156,173,"{{ }}")&&(n.rs(e,t,function(e,t,r){r.b(r.t(r.f("blockHeader",e,t,0)))}),e.pop()),n.s(n.f("blockHeader",e,t,1),e,t,1,0,0,"")||n.b("&nbsp;"),n.b("</div>"),n.b("\n"+r),n.b(" </td>"),n.b("\n"+r),n.b("</tr>"),n.fl()},partials:{},subs:{}}),Tf["generic-empty-diff"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b("<tr>"),n.b("\n"+r),n.b(' <td class="'),n.b(n.v(n.d("CSSLineClass.INFO",e,t,0))),n.b('">'),n.b("\n"+r),n.b(' <div class="'),n.b(n.v(n.f("contentClass",e,t,0))),n.b('">'),n.b("\n"+r),n.b(" File without changes"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(" </td>"),n.b("\n"+r),n.b("</tr>"),n.fl()},partials:{},subs:{}}),Tf["generic-file-path"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<span class="d2h-file-name-wrapper">'),n.b("\n"+r),n.b(n.rp("<fileIcon0",e,t," ")),n.b(' <span class="d2h-file-name">'),n.b(n.v(n.f("fileDiffName",e,t,0))),n.b("</span>"),n.b("\n"+r),n.b(n.rp("<fileTag1",e,t," ")),n.b("</span>"),n.b("\n"+r),n.b('<label class="d2h-file-collapse">'),n.b("\n"+r),n.b(' <input class="d2h-file-collapse-input" type="checkbox" name="viewed" value="viewed">'),n.b("\n"+r),n.b(" Viewed"),n.b("\n"+r),n.b("</label>"),n.fl()},partials:{"<fileIcon0":{name:"fileIcon",partials:{},subs:{}},"<fileTag1":{name:"fileTag",partials:{},subs:{}}},subs:{}}),Tf["generic-line"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b("<tr>"),n.b("\n"+r),n.b(' <td class="'),n.b(n.v(n.f("lineClass",e,t,0))),n.b(" "),n.b(n.v(n.f("type",e,t,0))),n.b('">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.f("lineNumber",e,t,0))),n.b("\n"+r),n.b(" </td>"),n.b("\n"+r),n.b(' <td class="'),n.b(n.v(n.f("type",e,t,0))),n.b('">'),n.b("\n"+r),n.b(' <div class="'),n.b(n.v(n.f("contentClass",e,t,0))),n.b('">'),n.b("\n"+r),n.s(n.f("prefix",e,t,1),e,t,0,162,238,"{{ }}")&&(n.rs(e,t,function(e,t,n){n.b(' <span class="d2h-code-line-prefix">'),n.b(n.t(n.f("prefix",e,t,0))),n.b("</span>"),n.b("\n"+r)}),e.pop()),n.s(n.f("prefix",e,t,1),e,t,1,0,0,"")||(n.b(' <span class="d2h-code-line-prefix">&nbsp;</span>'),n.b("\n"+r)),n.s(n.f("content",e,t,1),e,t,0,371,445,"{{ }}")&&(n.rs(e,t,function(e,t,n){n.b(' <span class="d2h-code-line-ctn">'),n.b(n.t(n.f("content",e,t,0))),n.b("</span>"),n.b("\n"+r)}),e.pop()),n.s(n.f("content",e,t,1),e,t,1,0,0,"")||(n.b(' <span class="d2h-code-line-ctn"><br></span>'),n.b("\n"+r)),n.b(" </div>"),n.b("\n"+r),n.b(" </td>"),n.b("\n"+r),n.b("</tr>"),n.fl()},partials:{},subs:{}}),Tf["generic-wrapper"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<div class="d2h-wrapper '),n.b(n.v(n.f("colorScheme",e,t,0))),n.b('">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.f("content",e,t,0))),n.b("\n"+r),n.b("</div>"),n.fl()},partials:{},subs:{}}),Tf["icon-file-added"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<svg aria-hidden="true" class="d2h-icon d2h-added" height="16" title="added" version="1.1" viewBox="0 0 14 16"'),n.b("\n"+r),n.b(' width="14">'),n.b("\n"+r),n.b(' <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM6 9H3V7h3V4h2v3h3v2H8v3H6V9z"></path>'),n.b("\n"+r),n.b("</svg>"),n.fl()},partials:{},subs:{}}),Tf["icon-file-changed"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<svg aria-hidden="true" class="d2h-icon d2h-changed" height="16" title="modified" version="1.1"'),n.b("\n"+r),n.b(' viewBox="0 0 14 16" width="14">'),n.b("\n"+r),n.b(' <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM4 8c0-1.66 1.34-3 3-3s3 1.34 3 3-1.34 3-3 3-3-1.34-3-3z"></path>'),n.b("\n"+r),n.b("</svg>"),n.fl()},partials:{},subs:{}}),Tf["icon-file-deleted"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<svg aria-hidden="true" class="d2h-icon d2h-deleted" height="16" title="removed" version="1.1"'),n.b("\n"+r),n.b(' viewBox="0 0 14 16" width="14">'),n.b("\n"+r),n.b(' <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM11 9H3V7h8v2z"></path>'),n.b("\n"+r),n.b("</svg>"),n.fl()},partials:{},subs:{}}),Tf["icon-file-renamed"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<svg aria-hidden="true" class="d2h-icon d2h-moved" height="16" title="renamed" version="1.1"'),n.b("\n"+r),n.b(' viewBox="0 0 14 16" width="14">'),n.b("\n"+r),n.b(' <path d="M6 9H3V7h3V4l5 4-5 4V9z m8-7v12c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h12c0.55 0 1 0.45 1 1z m-1 0H1v12h12V2z"></path>'),n.b("\n"+r),n.b("</svg>"),n.fl()},partials:{},subs:{}}),Tf["icon-file"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<svg aria-hidden="true" class="d2h-icon" height="16" version="1.1" viewBox="0 0 12 16" width="12">'),n.b("\n"+r),n.b(' <path d="M6 5H2v-1h4v1zM2 8h7v-1H2v1z m0 2h7v-1H2v1z m0 2h7v-1H2v1z m10-7.5v9.5c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h7.5l3.5 3.5z m-1 0.5L8 2H1v12h10V5z"></path>'),n.b("\n"+r),n.b("</svg>"),n.fl()},partials:{},subs:{}}),Tf["line-by-line-file-diff"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<div id="'),n.b(n.v(n.f("fileHtmlId",e,t,0))),n.b('" class="d2h-file-wrapper" data-lang="'),n.b(n.v(n.d("file.language",e,t,0))),n.b('">'),n.b("\n"+r),n.b(' <div class="d2h-file-header">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.f("filePath",e,t,0))),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(' <div class="d2h-file-diff">'),n.b("\n"+r),n.b(' <div class="d2h-code-wrapper">'),n.b("\n"+r),n.b(' <table class="d2h-diff-table">'),n.b("\n"+r),n.b(' <tbody class="d2h-diff-tbody">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.f("diffs",e,t,0))),n.b("\n"+r),n.b(" </tbody>"),n.b("\n"+r),n.b(" </table>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b("</div>"),n.fl()},partials:{},subs:{}}),Tf["line-by-line-numbers"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<div class="line-num1">'),n.b(n.v(n.f("oldNumber",e,t,0))),n.b("</div>"),n.b("\n"+r),n.b('<div class="line-num2">'),n.b(n.v(n.f("newNumber",e,t,0))),n.b("</div>"),n.fl()},partials:{},subs:{}}),Tf["side-by-side-file-diff"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<div id="'),n.b(n.v(n.f("fileHtmlId",e,t,0))),n.b('" class="d2h-file-wrapper" data-lang="'),n.b(n.v(n.d("file.language",e,t,0))),n.b('">'),n.b("\n"+r),n.b(' <div class="d2h-file-header">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.f("filePath",e,t,0))),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(' <div class="d2h-files-diff">'),n.b("\n"+r),n.b(' <div class="d2h-file-side-diff">'),n.b("\n"+r),n.b(' <div class="d2h-code-wrapper">'),n.b("\n"+r),n.b(' <table class="d2h-diff-table">'),n.b("\n"+r),n.b(' <tbody class="d2h-diff-tbody">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.d("diffs.left",e,t,0))),n.b("\n"+r),n.b(" </tbody>"),n.b("\n"+r),n.b(" </table>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(' <div class="d2h-file-side-diff">'),n.b("\n"+r),n.b(' <div class="d2h-code-wrapper">'),n.b("\n"+r),n.b(' <table class="d2h-diff-table">'),n.b("\n"+r),n.b(' <tbody class="d2h-diff-tbody">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.d("diffs.right",e,t,0))),n.b("\n"+r),n.b(" </tbody>"),n.b("\n"+r),n.b(" </table>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b("</div>"),n.fl()},partials:{},subs:{}}),Tf["tag-file-added"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<span class="d2h-tag d2h-added d2h-added-tag">ADDED</span>'),n.fl()},partials:{},subs:{}}),Tf["tag-file-changed"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<span class="d2h-tag d2h-changed d2h-changed-tag">CHANGED</span>'),n.fl()},partials:{},subs:{}}),Tf["tag-file-deleted"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<span class="d2h-tag d2h-deleted d2h-deleted-tag">DELETED</span>'),n.fl()},partials:{},subs:{}}),Tf["tag-file-renamed"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<span class="d2h-tag d2h-moved d2h-moved-tag">RENAMED</span>'),n.fl()},partials:{},subs:{}});class Yf{constructor({compiledTemplates:e={},rawTemplates:t={}}){const r=Object.entries(t).reduce((e,[t,r])=>{const n=Of.compile(r,{asString:!1});return Object.assign(Object.assign({},e),{[t]:n})},{});this.preCompiledTemplates=Object.assign(Object.assign(Object.assign({},Tf),e),r)}static compile(e){return Of.compile(e,{asString:!1})}render(e,t,r,n,i){const o=this.templateKey(e,t);try{return this.preCompiledTemplates[o].render(r,n,i)}catch(e){throw new Error(`Could not find template to render '${o}'`)}}template(e,t){return this.preCompiledTemplates[this.templateKey(e,t)]}templateKey(e,t){return`${e}-${t}`}}const jf=Object.assign(Object.assign(Object.assign({},Qf),qf),{outputFormat:"line-by-line",drawFileList:!0});var Gf=Object.freeze({__proto__:null,defaultDiff2HtmlConfig:jf,html:function(e,t={}){const r=Object.assign(Object.assign({},jf),t),n="string"==typeof e?nf(e,r):e,i=new Yf(r),{colorScheme:o}=r,a={colorScheme:o};return(r.drawFileList?new Ff(i,a).render(n):"")+("side-by-side"===r.outputFormat?new Hf(i,r).render(n):new Nf(i,r).render(n))},parse:function(e,t={}){return nf(e,Object.assign(Object.assign({},jf),t))}});function Jf(){if("[object Module]"===Object.prototype.toString.call(Gf))return Gf;let e=yn(),t=we(e,"Diff2Html.default",null),r=we(e,"Diff2Html",null),n="html";if(Ee(t)&&va(t[n]))return t;if(Ee(r)&&va(r[n]))return r;throw console.log("Diff2Html",Gf,"g.Diff2Html",e.Diff2Html),new Error("invalid Diff2Html, g.Diff2Html, g.Diff2Html.default, use script for import")}function zf(e){return document.querySelectorAll(e)}function Vf(e){function t(e){e.parentNode.removeChild(e)}if(br(e)){return void t(e)}if(!De(e))return;Er(zf(e),function(e){t(e)})}function Pf(e,t){if(!br(e))return"invalid eleParent";if(xe(t))e.insertAdjacentHTML("afterbegin",t);else{if(!br(t))return"invalid itemChild";e.insertBefore(t,e.firstChild)}}async function Xf(e,t={}){if(!br(e))return Promise.reject("invalid ele");let r=we(t,"scale",null);if(Se(r)||(r=1),r=Mn(r),r<1)return Promise.reject("opt.scale can not less then 1");let n=we(t,"picType",null);"image/jpg"!==n&&"image/jpeg"!==n&&"image/png"!==n&&"svg"!==n&&(n="image/png");let i=we(t,"toBase64",null);pn(i)||(i=!0);let o=e.cloneNode(!0),a=document.createElement("div");a.style.position="absolute",a.style.top=0,a.style.left=0,a.style.zIndex=-1,a.appendChild(o);let s=document.createElement("div");s.style.opacity=0,s.style.position="relative",s.appendChild(a),Pf(document.querySelector("body"),s);let c,l=yn().snapdom,u={scale:r,quality:1,cache:"disabled"};return"image/jpg"===n||"image/jpeg"===n?c=await l.toJpg(a,u):"image/png"===n?c=await l.toPng(a,u):"svg"===n&&(c=await l.toSvg(a,u)),i&&(c=we(c,"src","")),Vf(s),c}var _f=Ra(Fa);function Wf(e){let t=function(e,r){return null===e.parentNode?r:t(e.parentNode,r.concat([e]))};return e instanceof HTMLElement||e instanceof SVGElement?t(e.parentNode,[]):[]}function Kf(e){let t=we(e,"clientX",null),r=we(e,"clientY",null),n=we(e,"pageX",null),i=we(e,"pageY",null);if(null!==t&&null!==r&&null!==n&&null!==i)return{clientX:t,clientY:r,pageX:n,pageY:i};let o=we(e,"changedTouches",[]);if(1!==dn(o))return null;let a=o[0];return{clientX:we(a,"clientX",null),clientY:we(a,"clientY",null),pageX:we(a,"pageX",null),pageY:we(a,"pageY",null)}}function $f(e,t){let r=[];try{r=document.elementsFromPoint(e,t)}catch(e){console.log(e)}return r}function Zf(e,t){if(!br(e))return null;if(!De(t))return null;try{return e.getAttribute(t)}catch(e){}return null}function ed(e){if(!br(e))return null;try{return e.getBoundingClientRect()}catch(e){}return null}function td(e,t){if(!Ee(e))return null;if(!Ia(e.clientX)||!Ia(e.clientY))return null;if(!br(t))return null;let r=ed(t);return r?{x:e.clientX-r.left,y:e.clientY-r.top,w:t.offsetWidth,h:t.offsetHeight}:null}function rd(e={}){let t="dragpreviewid",r=null,n=null,i=null,o=null,a=null,s=!1,c=we(e,"attIdentify",null);De(c)||(c="dragprevid");let l=we(e,"containerOpacity",null);Ia(l)||(l=.4);let u=we(e,"containerBackground",null);De(u)||(u="white");let f=we(e,"containerBorderWidth",null);Ia(f)||(f=1);let d=we(e,"containerBorderColor",null);De(d)||(d="#f26");let g=`c${Hu(8)}`;function p(e,t,r){n&&i&&o&&a&&!s&&(a.style.top=t-n.tShiftY+"px",a.style.left=e-n.tShiftX+"px")}function h(){Vf(`[${t}='${g}']`),n=null,i=null,o=null,a=null}let A=function(e){p(e.clientX,e.clientY)};window.addEventListener("mousemove",A);let m=function(e){let t=Kf(e);t&&p(t.clientX,t.clientY)};return window.addEventListener("touchmove",m),{createPreview:function(e,s,A){try{!function(){let h=function(e,t,n){let i=ed(e);if(!i)return null;r=e;let o=e.cloneNode(!0);return o.tShiftX=t-i.left,o.tShiftY=n-i.top,o.tWidth=e.offsetWidth,o.tHeight=e.offsetHeight,o.tParent=e.parentNode,o.setAttribute(c,""),o}(e,s,A);if(null===h)return;let m=document.createElement("div");m.style.position="absolute",m.style.zIndex=1,m.style.top=0,m.style.left=0,m.style.width="100%",m.style.height="100%",m.appendChild(h);let I=document.createElement("div");I.style.position="relative",I.appendChild(m);let y=document.createElement("div");y.setAttribute(t,g),y.style.position="fixed",y.style.zIndex=1e5,y.style.width=`${h.tWidth+2*f}px`,y.style.height=`${h.tHeight+2*f}px`,y.style.opacity=l,y.style.background=u,y.style.border=`${f}px solid ${d}`,y.style.pointerEvents="none",y.appendChild(I),document.querySelector("body").appendChild(y),n=h,i=m,o=I,a=y,p(s,A)}()}catch(e){}let m=setInterval(()=>{let e=Zf(r,c);document.querySelector(`[${c}='${e}']`)||(clearInterval(m),h())},500)},updateDragPreview:p,pauseDragPreview:function(e){s=e},removeDragPreview:h,setNodeStyle:function(e){try{Er(e,(e,t)=>{n.style[t]=e})}catch(e){}},setCoverStyle:function(e){try{Er(e,(e,t)=>{i.style[t]=e})}catch(e){}},setSellStyle:function(e){try{Er(e,(e,t)=>{o.style[t]=e})}catch(e){}},setContainerStyle:function(e){try{Er(e,(e,t)=>{a.style[t]=e})}catch(e){}},clear:function(){window.removeEventListener("mousemove",A),window.removeEventListener("touchmove",m)}}}let nd={};function id(e,t,{attIdentify:r,previewOpacity:n,previewBackground:i,previewBorderWidth:o,previewBorderColor:a}){if(!ke(nd,e)){let t=Xi(),s=function(e){let t=[];function r(){let r;r="mousemove";let n=function(t){e.dragMove({e:t,name:"mousemove"})};window.addEventListener(r,n),t.push({ele:window,name:r,f:n}),r="mouseup";let i=function(t){e.dragDrop({e:t,name:"mouseup"})};window.addEventListener(r,i),t.push({ele:window,name:r,f:i}),r="touchmove";let o=function(t){e.dragMove({e:t,name:"touchmove"})};window.addEventListener(r,o),t.push({ele:window,name:r,f:o}),r="touchend";let a=function(t){e.dragDrop({e:t,name:"touchend"})};window.addEventListener(r,a),t.push({ele:window,name:r,f:a})}function n(){Er(t,({ele:e,name:t,f:r})=>{e.removeEventListener(t,r)})}return{bind:r,unbind:n}}({dragMove:r=>{t.emit(e+"-dragMove",r)},dragDrop:r=>{t.emit(e+"-dragDrop",r)}});s.bind();let c=rd({attIdentify:r,containerOpacity:n,containerBackground:i,containerBorderWidth:o,containerBorderColor:a});nd[e]={eleIds:[],evg:t,oevg:s,pv:c,isInit:!1,isActive:!0}}return nd[e].eleIds.push(t),nd[e].evg}function od(e,t){let r=Zf(e,t);return r=Zi(r),r}function ad({gid:e,attGroup:t,attIndex:r,attIdentify:n,timeDragStartDelay:i,previewOpacity:o,previewDisabledOpacity:a}){let s=null,c=null,l=null,u=null;if(nd[e].isInit)return nd[e].evg;nd[e].isInit=!0;let f=nd[e].evg;f.on(e+"-dragStart",function({e:t,ele:o,from:l}){if(!nd[e].isActive)return;let u=od(o,r);if(null===u)return;s=u,c=o;let g={event:t,startInd:s,startEle:c,tarInd:s,tarEid:Zf(c,n)};f.emit(e+"-change",{mode:"start",...g}),f.emit(e+"-start",g);let p=Kf(t);if(!p)return;setTimeout(()=>{null!==s&&(d.createPreview(c,p.clientX,p.clientY),d.setContainerStyle({opacity:a}))},i)}),f.on(e+"-dragMove",function({e:i,name:g,from:p}){if(!nd[e].isActive)return;let h=function(e,t,r){let n=null;return Er(Wf(e.target),e=>{if(Zf(e,t)===r)return n=e,!1}),n}(i,t,e);if(null===s)return;let A=Kf(i);if(!A)return;function m(){let t={event:i,startInd:s,startEle:c,endInd:l,endEle:u,tarInd:l,tarEid:Zf(u,n)};f.emit(e+"-change",{mode:"leave",...t}),f.emit(e+"-leave",t),l=null,u=null,d.setContainerStyle({opacity:a})}if(!h)return void(null!==l&&m());let I=od(h,r);if(null===I)return;if(I===s)return void(null!==l&&m());if(I!==l)null!==l&&m(),function(t,r){l=t,u=r;let a={event:i,startInd:s,startEle:c,endInd:l,endEle:u,tarInd:l,tarEid:Zf(u,n)};f.emit(e+"-change",{mode:"enter",...a}),f.emit(e+"-enter",a),d.setContainerStyle({opacity:o})}(I,h);else{let t=td(A,h),r=0;t.w>0&&(r=t.x/t.w);let a=0;t.h>0&&(a=t.y/t.h),r>=0&&r<=1&&a>=0&&a<=1&&function(t,r,a){let g={event:i,startInd:s,startEle:c,endInd:l,endEle:u,tarInd:l,tarEid:Zf(u,n),...t,rx:r,ry:a};f.emit(e+"-change",{mode:"move",...g}),f.emit(e+"-move",g),d.setContainerStyle({opacity:o})}(t,r,a)}}),f.on(e+"-dragDrop",function({e:i,name:o,from:a}){if(d.removeDragPreview(),!nd[e].isActive)return;if(null===s)return;let g=function(e,t,r){let n=null,i=Kf(e);return i?(Er($f(i.clientX,i.clientY),e=>{if(Zf(e,t)===r)return n=e,!1}),n):n}(i,t,e);if(!g)return s=null,c=null,l=null,void(u=null);let p=od(g,r);if(null===p)return;(function(t,r){l=t,u=r;let o={event:i,startInd:s,startEle:c,endInd:l,endEle:u,tarInd:l,tarEid:Zf(u,n)};f.emit(e+"-change",{mode:"drop",...o}),f.emit(e+"-drop",o)})(p,g),s=null,c=null,l=null,u=null});let d=nd[e].pv}async function sd(e){let t=[],r=ns();return await async function e(r){let n=null;if(r.isFile&&(n=await function(e){let t=ns();try{e.file(t.resolve,t.reject)}catch(e){t.reject(e)}return t}(r)),t.push({type:r.isDirectory?"folder":r.isFile?"file":"unknow",path:r.fullPath,name:r.name,entry:r,file:n}),r.isDirectory){let t=r.createReader(),n=await function(e){let t=ns();try{e.readEntries(t.resolve,t.reject)}catch(e){t.reject(e)}return t}(t);await cl(n,async t=>{await e(t)})}}(e),r.resolve(t),r}async function cd(e){let t=[];Er(e,e=>{let r=e.webkitGetAsEntry();r&&t.push(r)});let r=await async function(e){let t=[];return await cl(e,async e=>{Er(await sd(e),e=>{t.push(e)})}),t}(t);return r}async function ld(e){let t=[],r=[];try{t=await async function(e){let t=[];return Er(e,e=>{e.type&&t.push({type:"file",name:e.name,file:e})}),t}(we(e,"files",[])),Vu()||(r=await cd(we(e,"items",[])).catch(e=>{console.log(e)}))}catch(e){return Promise.reject(e)}return{files:t,entries:r}}function ud(e){return document.querySelector(e)}function fd(e){return!Ur(e)}var dd=Math.max;var gd,pd=(gd=function(e,t,r){var n=null==e?0:e.length;if(!n)return-1;var i=null==r?0:qn(r);return i<0&&(i=dd(n+i,0)),Or(e,fr(t),i)},function(e,t,r){var n=Object(e);if(!ft(e)){var i=fr(t);e=dt(e),t=function(e){return i(n[e],e,n)}}var o=gd(e,t,r);return o>-1?n[i?e[o]:o]:void 0});let hd=[{name:"pic",group:"image",acp:"image/*",exec:"imageviwer"},{name:"xml",group:"data",acp:"text/xml",exec:"textviwer"},{name:"htm",group:"docums",acp:"text/html",exec:"browser"},{name:"html",group:"docums",acp:"text/html",exec:"browser"},{name:"json",group:"data",acp:"application/json",exec:"textviwer"},{name:"geojson",group:"data",acp:"application/geo+json",exec:"textviwer"},{name:"txt",group:"data",acp:"text/plain",exec:"textviwer"},{name:"csv",group:"data",acp:"text/csv",exec:"excel"},{name:"dat",group:"data",acp:"application/octet-stream",exec:"binaryviwer"},{name:"7z",group:"compress",acp:"application/x-7z-compressed",exec:"compressor"},{name:"bzip",group:"compress",acp:"application/x-bzip",exec:"7z"},{name:"bzip2",group:"compress",acp:"application/x-bzip2",exec:"compressor"},{name:"bz2",group:"compress",acp:"application/x-bzip2",exec:"compressor"},{name:"ace",group:"compress",acp:"application/x-ace-compressed",exec:"compressor"},{name:"Z",group:"compress",acp:"application/x-compress",exec:"compressor"},{name:"lzh",group:"compress",acp:"application/x-lzh-compressed",exec:"compressor"},{name:"lz",group:"compress",acp:"application/x-lzip",exec:"compressor"},{name:"rar",group:"compress",acp:"application/x-rar-compressed",exec:"compressor"},{name:"tar",group:"compress",acp:"application/x-tar",exec:"compressor"},{name:"ar",group:"compress",acp:"application/x-unix-archive",exec:"compressor"},{name:"zip",group:"compress",acp:"application/zip",exec:"compressor"},{name:"gz",group:"compress",acp:"application/gzip",exec:"compressor"},{name:"avro",group:"",acp:"application/avro",exec:""},{name:"dcm",group:"",acp:"application/dicom",exec:""},{name:"eps",group:"",acp:"application/eps",exec:""},{name:"epub",group:"",acp:"application/epub+zip",exec:""},{name:"class",group:"",acp:"application/java-vm",exec:""},{name:"mxf",group:"",acp:"application/mxf",exec:""},{name:"ogx",group:"",acp:"application/ogg",exec:""},{name:"pdf",group:"docums",acp:"application/pdf",exec:"acrobat"},{name:"pgp",group:"",acp:"application/pgp-encrypted",exec:""},{name:"ps",group:"",acp:"application/postscript",exec:""},{name:"ai",group:"",acp:"application/postscript",exec:""},{name:"rtf",group:"docums",acp:"application/rtf",exec:"word"},{name:"icc",group:"",acp:"application/vnd.iccprofile",exec:""},{name:"asf",group:"",acp:"application/vnd.ms-asf",exec:"",msg:"asf的acp可能為application/vnd.ms-asf或audio/x-ms-asf或video/x-ms-asf"},{name:"cab",group:"",acp:"application/vnd.ms-cab-compressed",exec:""},{name:"eot",group:"",acp:"application/vnd.ms-fontobject",exec:""},{name:"chm",group:"",acp:"application/vnd.ms-htmlhelp",exec:""},{name:"pst",group:"",acp:"application/vnd.ms-outlook",exec:""},{name:"odp",group:"docums",acp:"application/vnd.oasis.opendocument.presentation",exec:"powerpoint"},{name:"ods",group:"docums",acp:"application/vnd.oasis.opendocument.spreadsheet",exec:"excel"},{name:"odt",group:"docums",acp:"application/vnd.oasis.opendocument.text",exec:"word"},{name:"ppt",group:"docums",acp:"application/vnd.ms-powerpoint",exec:"powerpoint"},{name:"pptx",group:"docums",acp:"application/vnd.openxmlformats-officedocument.presentationml.presentation",exec:"powerpoint"},{name:"xls",group:"docums",acp:"application/vnd.ms-excel",exec:"excel"},{name:"xlsx",group:"docums",acp:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",exec:"excel"},{name:"doc",group:"docums",acp:"application/msword",exec:"word"},{name:"docx",group:"docums",acp:"application/vnd.openxmlformats-officedocument.wordprocessingml.document",exec:"word"},{name:"skp",group:"",acp:"application/vnd.sketchup.skp",exec:""},{name:"pcap",group:"",acp:"application/vnd.tcpdump.pcap",exec:""},{name:"wasm",group:"",acp:"application/wasm",exec:""},{name:"arrow",group:"",acp:"application/x-apache-arrow",exec:""},{name:"dmg",group:"",acp:"application/x-apple-diskimage",exec:""},{name:"arj",group:"",acp:"application/x-arj",exec:""},{name:"asar",group:"",acp:"application/x-asar",exec:""},{name:"blend",group:"",acp:"application/x-blender",exec:"blender"},{name:"cfb",group:"",acp:"application/x-cfb",exec:""},{name:"cpio",group:"",acp:"application/x-cpio",exec:""},{name:"deb",group:"",acp:"application/x-deb",exec:""},{name:"elf",group:"",acp:"application/x-elf",exec:""},{name:"shp",group:"",acp:"application/x-esri-shape",exec:""},{name:"crx",group:"",acp:"application/x-google-chrome-extension",exec:""},{name:"indd",group:"",acp:"application/x-indesign",exec:""},{name:"macho",group:"",acp:"application/x-mach-binary",exec:""},{name:"mie",group:"",acp:"application/x-mie",exec:""},{name:"mobi",group:"",acp:"application/x-mobipocket-ebook",exec:""},{name:"exe",group:"",acp:"application/x-msdownload",exec:""},{name:"nes",group:"",acp:"application/x-nintendo-nes-rom",exec:""},{name:"parquet",group:"",acp:"application/x-parquet",exec:""},{name:"rpm",group:"",acp:"application/x-rpm",exec:""},{name:"swf",group:"",acp:"application/x-shockwave-flash",exec:""},{name:"sqlite",group:"",acp:"application/x-sqlite3",exec:""},{name:"xpi",group:"",acp:"application/x-xpinstall",exec:""},{name:"xz",group:"",acp:"application/x-xz",exec:""},{name:"alias",group:"",acp:"application/x.apple.alias",exec:""},{name:"fbx",group:"",acp:"application/x.autodesk.fbx",exec:""},{name:"lnk",group:"",acp:"application/x.ms.shortcut",exec:""},{name:"zst",group:"",acp:"application/zstd",exec:""},{name:"aac",group:"audio",acp:"audio/aac",exec:"audioplayer"},{name:"aif",group:"audio",acp:"audio/aiff",exec:"audioplayer"},{name:"amr",group:"audio",acp:"audio/amr",exec:"audioplayer"},{name:"ape",group:"audio",acp:"audio/ape",exec:"audioplayer"},{name:"mid",group:"audio",acp:"audio/midi",exec:"audioplayer"},{name:"m4b",group:"audio",acp:"audio/mp4",exec:"audioplayer"},{name:"f4a",group:"audio",acp:"audio/mp4",exec:"audioplayer"},{name:"f4b",group:"audio",acp:"audio/mp4",exec:"audioplayer"},{name:"mp3",group:"audio",acp:"audio/mpeg",exec:"audioplayer"},{name:"mp2",group:"audio",acp:"audio/mpeg",exec:"audioplayer"},{name:"mp1",group:"audio",acp:"audio/mpeg",exec:"audioplayer"},{name:"oga",group:"audio",acp:"audio/ogg",exec:"audioplayer"},{name:"spx",group:"audio",acp:"audio/ogg",exec:"audioplayer"},{name:"ogg",group:"audio",acp:"audio/ogg",exec:"audioplayer"},{name:"opus",group:"audio",acp:"audio/opus",exec:"audioplayer"},{name:"qcp",group:"audio",acp:"audio/qcelp",exec:"audioplayer"},{name:"ac3",group:"audio",acp:"audio/vnd.dolby.dd-raw",exec:"audioplayer"},{name:"wav",group:"audio",acp:"audio/wav",exec:"audioplayer"},{name:"wv",group:"audio",acp:"audio/wavpack",exec:"audioplayer"},{name:"dsf",group:"audio",acp:"audio/x-dsf",exec:"audioplayer"},{name:"flac",group:"audio",acp:"audio/x-flac",exec:"audioplayer"},{name:"it",group:"audio",acp:"audio/x-it",exec:"audioplayer"},{name:"m4a",group:"audio",acp:"audio/x-m4a",exec:"audioplayer"},{name:"mpc",group:"audio",acp:"audio/x-musepack",exec:"audioplayer"},{name:"s3m",group:"audio",acp:"audio/x-s3m",exec:"audioplayer"},{name:"voc",group:"audio",acp:"audio/x-voc",exec:"audioplayer"},{name:"xm",group:"audio",acp:"audio/x-xm",exec:"audioplayer"},{name:"otf",group:"",acp:"font/otf",exec:""},{name:"ttf",group:"",acp:"font/ttf",exec:""},{name:"woff",group:"",acp:"font/woff",exec:""},{name:"woff2",group:"",acp:"font/woff2",exec:""},{name:"apng",group:"image",acp:"image/apng",exec:"imageviwer"},{name:"avif",group:"image",acp:"image/avif",exec:"imageviwer"},{name:"bmp",group:"image",acp:"image/bmp",exec:"imageviwer"},{name:"bpg",group:"image",acp:"image/bpg",exec:"imageviwer"},{name:"flif",group:"image",acp:"image/flif",exec:"imageviwer"},{name:"gif",group:"image",acp:"image/gif",exec:"imageviwer"},{name:"heic",group:"image",acp:"image/heif",exec:"imageviwer"},{name:"icns",group:"image",acp:"image/icns",exec:"imageviwer"},{name:"j2c",group:"image",acp:"image/j2c",exec:"imageviwer"},{name:"jls",group:"image",acp:"image/jls",exec:"imageviwer"},{name:"jp2",group:"image",acp:"image/jp2",exec:"imageviwer"},{name:"jpg",group:"image",acp:"image/jpeg",exec:"imageviwer"},{name:"jpm",group:"image",acp:"image/jpm",exec:"imageviwer"},{name:"jpx",group:"image",acp:"image/jpx",exec:"imageviwer"},{name:"jxl",group:"image",acp:"image/jxl",exec:"imageviwer"},{name:"ktx",group:"image",acp:"image/ktx",exec:"imageviwer"},{name:"mj2",group:"image",acp:"image/mj2",exec:"imageviwer"},{name:"png",group:"image",acp:"image/png",exec:"imageviwer"},{name:"tif",group:"image",acp:"image/tiff",exec:"imageviwer"},{name:"psd",group:"image",acp:"image/vnd.adobe.photoshop",exec:"imageviwer"},{name:"dwg",group:"image",acp:"image/vnd.dwg",exec:"imageviwer"},{name:"jxr",group:"image",acp:"image/vnd.ms-photo",exec:"imageviwer"},{name:"webp",group:"image",acp:"image/webp",exec:"imageviwer"},{name:"dng",group:"image",acp:"image/x-adobe-dng",exec:"imageviwer"},{name:"cr2",group:"image",acp:"image/x-canon-cr2",exec:"imageviwer"},{name:"cr3",group:"image",acp:"image/x-canon-cr3",exec:"imageviwer"},{name:"raf",group:"image",acp:"image/x-fujifilm-raf",exec:"imageviwer"},{name:"ico",group:"image",acp:"image/x-icon",exec:"imageviwer"},{name:"cur",group:"image",acp:"image/x-icon",exec:"imageviwer"},{name:"nef",group:"image",acp:"image/x-nikon-nef",exec:"imageviwer"},{name:"orf",group:"image",acp:"image/x-olympus-orf",exec:"imageviwer"},{name:"rw2",group:"image",acp:"image/x-panasonic-rw2",exec:"imageviwer"},{name:"arw",group:"image",acp:"image/x-sony-arw",exec:"imageviwer"},{name:"xcf",group:"image",acp:"image/x-xcf",exec:"imageviwer"},{name:"3mf",group:"",acp:"model/3mf",exec:""},{name:"glb",group:"",acp:"model/gltf-binary",exec:""},{name:"stl",group:"",acp:"model/stl",exec:""},{name:"ics",group:"",acp:"text/calendar",exec:""},{name:"vcf",group:"",acp:"text/vcard",exec:""},{name:"3gp",group:"video",acp:"video/3gpp",exec:"videoplayer"},{name:"3g2",group:"video",acp:"video/3gpp2",exec:"videoplayer"},{name:"m2p",group:"video",acp:"video/MP2P",exec:"videoplayer"},{name:"vob",group:"video",acp:"video/MP2P",exec:"videoplayer"},{name:"sub",group:"video",acp:"video/MP2P",exec:"videoplayer",msg:"與字幕檔衝突"},{name:"mts",group:"video",acp:"video/mp2t",exec:"videoplayer"},{name:"m4p",group:"video",acp:"video/mp4",exec:"videoplayer"},{name:"f4v",group:"video",acp:"video/mp4",exec:"videoplayer"},{name:"f4p",group:"video",acp:"video/mp4",exec:"videoplayer"},{name:"mp4",group:"video",acp:"video/mp4",exec:"videoplayer"},{name:"mpg",group:"video",acp:"video/mpeg",exec:"videoplayer",msg:"mpg可能為mpeg或video/MP1S或video/MP2S"},{name:"ogv",group:"video",acp:"video/ogg",exec:"videoplayer"},{name:"ogm",group:"video",acp:"video/ogg",exec:"videoplayer"},{name:"mov",group:"video",acp:"video/quicktime",exec:"videoplayer"},{name:"avi",group:"video",acp:"video/vnd.avi",exec:"videoplayer"},{name:"webm",group:"video",acp:"video/webm",exec:"videoplayer"},{name:"flv",group:"video",acp:"video/x-flv",exec:"videoplayer"},{name:"m4v",group:"video",acp:"video/x-m4v",exec:"videoplayer"},{name:"mkv",group:"video",acp:"video/x-matroska",exec:"videoplayer"}];function Ad(e=""){let t=null;return De(e)?(t=pd(hd,{name:e}),Ee(t)||(t=null)):t=hd,t}function md(e=""){if(""!==e&&"name"!==e&&"group"!==e&&"acp"!==e&&"exec"!==e)return[];let t=Ad();if(""===e)return t;let r={};return Er(t,function(t){let n=t[e];ke(r,n)||(r[n]=[]),r[n].push(t)}),r}function Id(e="*"){if("*"===e)return e;if(!xe(e)&&!Rr(e))return"*";"common"===e&&(e=["docums","compress","image","data"]);let t=md();function r(e){return Pr(xr(e,"acp"))}xe(e)&&(e=[e]);let n="";if(Rr(e)){let i=xr(e,function(e){return function(e){return r(pa(t,{group:e}))}(e)}),o=kr(i,xr(e,function(e){return r(pa(t,{name:e}))}));o=pa(o,fd),n=xo(o,",")}return n}function yd(e,t=1e3){(t=Mn(t))<=0&&(t=1e3);let r={},n=[];return Er(we(e,"files",[]),function(e,i){let o=e.size/1024/1024;o>t&&(r[i]=`file size[${o}]mb > ${t}mb`),n.push(e)}),{files:n,errs:r}}function vd(e,t,r){for(var n=-1,i=e.length;++n<i;){var o=e[n],a=t(o);if(null!=a&&(void 0===s?a==a&&!q(a):r(a,s)))var s=a,c=o}return c}function bd(e,t){return e<t}function wd(e){return e&&e.length?vd(e,cr,bd):void 0}function Bd(){return!function(){try{return"IntersectionObserver"in window}catch(e){return!1}}()||!function(){try{return"IntersectionObserverEntry"in window}catch(e){return!1}}()||!(function(){try{return"intersectionRatio"in window.IntersectionObserverEntry.prototype}catch(e){return!1}}()||va(window.IntersectionObserverEntry))}function Ed(e,t,r={}){if(!br(e))return Promise.reject("invalid ele");let n=yn().markmap,{Transformer:i,Markmap:o,loadCSS:a,loadJS:s}=n,c=e=>{let t=new i,{root:r,features:n}=t.transform(e),{styles:o,scripts:a}=t.getUsedAssets(n);return{root:r,features:n,styles:o,scripts:a}},{root:l,styles:u,scripts:f}=c(t);u&&a(u),f&&s(f,{getMarkmap:()=>n}),e.innerHTML="";let d=o.create(e,null,l);return d.transMarkdown=c,d}const Cd=e=>void 0===e||"auto"===e||"instant"===e||"smooth"===e;function xd(e,t){this.scrollLeft=e,this.scrollTop=t}const Dd=(e,t,r="cannot convert to dictionary.")=>`Failed to execute '${e}' on '${t}': ${r}`,Fd=(e,t,r)=>Dd(e,t,`The provided value '${r}' is not a valid enum value of type ScrollBehavior.`),Qd=(e,t,r)=>{var n;const i=`__SEAMLESS.BACKUP$${t}`;return e[i]||!e[t]||(null===(n=e[t])||void 0===n?void 0:n.__isPolyfill)||(e[i]=e[t]),e[i]||r},Sd=e=>{const t=typeof e;return null!==e&&("object"===t||"function"===t)},kd=e=>"scrollBehavior"in window.document.documentElement.style&&!0!==(null==e?void 0:e.forcePolyfill),Nd=e=>{Object.defineProperty(e,"__isPolyfill",{value:!0})},qd=(e,t)=>{Nd(t),[HTMLElement.prototype,SVGElement.prototype,Element.prototype].forEach(r=>{Qd(r,e),r[e]=t})},Md=e=>e.ownerDocument.scrollingElement||e.ownerDocument.documentElement;const Hd=e=>.5*(1-Math.cos(Math.PI*e));function Ld(){var e;let t;return t=(null===(e=window.performance)||void 0===e?void 0:e.now)?()=>window.performance.now():()=>window.Date.now(),Ld=t,t()}const Ud=e=>{const t=(Ld()-e.timeStamp)/(e.duration||500);if(t>1)return e.method(e.targetX,e.targetY),void e.callback();const r=(e.timingFunc||Hd)(t),n=e.startX+(e.targetX-e.startX)*r,i=e.startY+(e.targetY-e.startY)*r;e.method(n,i),e.rafId=window.requestAnimationFrame(()=>{Ud(e)})},Rd=e=>isFinite(e)?Number(e):0,Od=(e,t,r)=>{var n,i;if(!(e=>{var t;return null!==(t=e.isConnected)&&void 0!==t?t:!(e.ownerDocument&&1&e.ownerDocument.compareDocumentPosition(e))})(e))return;const o=e.scrollLeft,a=e.scrollTop,s=Rd(null!==(n=t.left)&&void 0!==n?n:o),c=Rd(null!==(i=t.top)&&void 0!==i?i:a);if(s===o&&c===a)return;const l=Qd(HTMLElement.prototype,"scroll",xd),u=Qd(Object.getPrototypeOf(e),"scroll",l).bind(e);if("smooth"!==t.behavior)return void u(s,c);const f=()=>{window.removeEventListener("wheel",g),window.removeEventListener("touchmove",g)},d=Object.assign(Object.assign({},r),{timeStamp:Ld(),startX:o,startY:a,targetX:s,targetY:c,rafId:0,method:u,callback:()=>{f();const t=9===e.nodeType;e.dispatchEvent(function(e){if("function"==typeof Event)return new Event("scrollend",{bubbles:e,cancelable:!1});const t=document.createEvent("Event");return t.initEvent("scrollend",e,!1),t}(t))}}),g=()=>{window.cancelAnimationFrame(d.rafId),f()};window.addEventListener("wheel",g,{passive:!0,once:!0}),window.addEventListener("touchmove",g,{passive:!0,once:!0}),Ud(d)},Td=e=>(t,r,n)=>{const[i,o]=(a=t).window===a?[Md(t.document.documentElement),"Window"]:[t,"Element"];var a;const s=null!=r?r:{};if(!Sd(s))throw new TypeError(Dd(e,o));if(!Cd(s.behavior))throw new TypeError(Fd(e,o,s.behavior));"scrollBy"===e&&(s.left=Rd(s.left)+i.scrollLeft,s.top=Rd(s.top)+i.scrollTop),Od(i,s,n)},Yd=Td("scroll"),jd=Td("scrollTo"),Gd=Td("scrollBy"),Jd=Yd,zd=e=>{switch(e){case"horizontal-tb":case"lr":case"lr-tb":case"rl":case"rl-tb":return 0;case"vertical-rl":case"tb":case"tb-rl":return 1;case"vertical-lr":case"tb-lr":return 2;case"sideways-rl":return 3;case"sideways-lr":return 4}return 0},Vd=(e,t,r,n)=>{let i=0;switch(t||(i^=2),e){case 0:i=i>>1|(1&i)<<1,[r,n]=[n,r];break;case 1:case 3:i^=1;break;case 4:i^=2}return[i,r,n]},Pd=e=>!(1&~Vd(zd(e.writingMode),"rtl"!==e.direction,void 0,void 0)[0]),Xd=(e,t,r,n,i,o,a)=>0!==e?e:i<t&&o>r||i>t&&o<r?null:i<=t&&a<=n||o>=r&&a>=n?2:o>r&&a<n||i<t&&a>n?3:null,_d=e=>"visible"!==e&&"clip"!==e,Wd=(e,t)=>(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth)&&(_d(t.overflowY)||_d(t.overflowX)||e===Md(e)),Kd=e=>{const t=e.parentNode,r=e.parentElement;if(null===r&&null!==t){if(11===t.nodeType)return t.host;if(9===t.nodeType)return(e=>{var t;try{return(null===(t=e.ownerDocument.defaultView)||void 0===t?void 0:t.frameElement)||null}catch(e){return null}})(e)}return r},$d=(e,t,r)=>e<t?t:e>r?r:e,Zd=(e,t,r)=>{switch(e){case 1:return(t+r)/2;case 3:return r;case 2:case 0:return t}},eg=(e,t)=>{var r,n,i;const o=null===(r=e.ownerDocument.defaultView)||void 0===r?void 0:r.visualViewport,[a,s,c,l]=e===Md(e)?[0,0,null!==(n=null==o?void 0:o.width)&&void 0!==n?n:e.clientWidth,null!==(i=null==o?void 0:o.height)&&void 0!==i?i:e.clientHeight]:[t.left,t.top,e.clientWidth,e.clientHeight],u=a+e.clientLeft,f=s+e.clientTop;return[f,u+c,f+l,u]},tg=(e,t)=>{const r=[];let n=e.ownerDocument,i=n.defaultView;if(!i)return r;const o=window.getComputedStyle(e),a="rtl"!==o.direction,s=zd(o.writingMode||o.getPropertyValue("-webkit-writing-mode")||o.getPropertyValue("-ms-writing-mode")),[c,l]=((e,t,r)=>{const[n,i,o]=Vd(t,r,e.block||"start",e.inline||"nearest");return[i,o].map((e,t)=>{switch(e){case"center":return 1;case"nearest":return 0;default:return"start"===e==!(n>>t&1)?2:3}})})(t,s,a);let[u,f,d,g]=((e,t,r)=>{const{top:n,right:i,bottom:o,left:a}=t,s=(c=e.ownerDocument,["scroll-margin","scroll-snap-margin"].filter(e=>e in c.documentElement.style)[0]);var c;if(!s)return[n,i,o,a];const l=e=>{const t=r.getPropertyValue(`${s}-${e}`);return parseInt(t,10)||0};return[n-l("top"),i+l("right"),o+l("bottom"),a-l("left")]})(e,e.getBoundingClientRect(),o);for(let o=Kd(e);null!==o;o=Kd(o)){if(n!==o.ownerDocument){if(n=o.ownerDocument,i=n.defaultView,!i)break;const{left:e,top:t}=o.getBoundingClientRect();u+=t,f+=e,d+=t,g+=e}const e=i.getComputedStyle(o);if("fixed"===e.position)break;if(!Wd(o,e))continue;const a=o.getBoundingClientRect(),[s,p,h,A]=eg(o,a),m=Xd(c,A,p,o.clientWidth,g,f,f-g),I=Xd(l,s,h,o.clientHeight,u,d,d-u),y=null===m?0:Zd(m,g,f)-Zd(m,A,p),v=null===I?0:Zd(I,u,d)-Zd(I,s,h),b=Pd(e)?$d(y,-o.scrollWidth+o.clientWidth-o.scrollLeft,-o.scrollLeft):$d(y,-o.scrollLeft,o.scrollWidth-o.clientWidth-o.scrollLeft),w=$d(v,-o.scrollTop,o.scrollHeight-o.clientHeight-o.scrollTop);r.push([o,{left:o.scrollLeft+b,top:o.scrollTop+w,behavior:t.behavior}]),u=Math.max(u-w,s),f=Math.min(f-b,p),d=Math.min(d-w,h),g=Math.max(g-b,A)}return r},rg=(e,t,r)=>{const n=t||{};if(!Cd(n.behavior))throw new TypeError(Fd("scrollIntoView","Element",n.behavior));tg(e,n).forEach(([e,t])=>{Jd(e,t,r)})},ng=(e,t)=>r=>{if(kd(r))return;const n={scroll:Yd,scrollTo:jd,scrollBy:Gd}[e];t(e,function(){const e=arguments;if(1===arguments.length)return void n(this,e[0],r);n(this,{left:e[0],top:e[1]})})},ig=ng("scroll",qd),og=ng("scrollTo",qd),ag=ng("scrollBy",qd),sg=(e,t)=>{Nd(t),Qd(window,e),window[e]=t},cg=ng("scroll",sg),lg=ng("scrollTo",sg),ug=ng("scrollBy",sg);function fg(e){rg(this,{block:null==e||e?"start":"end",inline:"nearest"})}const dg=e=>{if(kd(e))return;const t=Qd(window.HTMLElement.prototype,"scrollIntoView",fg);qd("scrollIntoView",function(){const r=arguments,n=r[0];1===r.length&&Sd(n)?rg(this,n,e):t.apply(this,r)})},gg=e=>{kd(e)||(ig(e),og(e),ag(e),dg(e),cg(e),lg(e),ug(e))};function pg(e,t,r){(void 0!==r&&!re(e[t],r)||void 0===r&&!(t in e))&&di(e,t,r)}function hg(e){return N(e)&&ft(e)}function Ag(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}function mg(e,t,r,n,i,o,a){var s=Ag(e,r),c=Ag(t,r),l=a.get(c);if(l)pg(e,r,l);else{var u,f=o?o(s,c,r+"",e,t,a):void 0,d=void 0===f;if(d){var g=v(c),p=!g&&ze(c),h=!g&&!p&&rt(c);f=c,g||p||h?v(s)?f=s:hg(s)?f=Sr(s):p?(d=!1,f=Bi(c,!0)):h?(d=!1,f=ki(c,!0)):f=[]:vr(c)||Ye(c)?(f=s,Ye(s)?f=hi(u=s,Ii(u)):U(s)&&!R(s)||(f=Hi(c))):d=!1}d&&(a.set(c,f),i(f,c,n,o,a),a.delete(c)),pg(e,r,f)}}function Ig(e,t,r,n,i){e!==t&&Me(t,function(o,a){if(i||(i=new At),U(o))mg(e,t,a,r,Ig,n,i);else{var s=n?n(Ag(e,a),o,a+"",e,t,i):void 0;void 0===s&&(s=o),pg(e,a,s)}},Ii)}var yg,vg=(yg=function(e,t,r){Ig(e,t,r)},Ra(function(e,t){var r=-1,n=t.length,i=n>1?t[n-1]:void 0,o=n>2?t[2]:void 0;for(i=yg.length>3&&"function"==typeof i?(n--,i):void 0,o&&dr(t[0],t[1],o)&&(i=n<3?void 0:i,n=1),e=Object(e);++r<n;){var a=t[r];a&&yg(e,a,r,i)}return e}));async function bg(e,t=null,r={}){let n=!0,i=null,o=ns();Ee(r)||(r={});let a=we(r,"disTouchMoveToHide",null);if(Bo(a)||(a=4),a=Zi(a),!br(e))return o.reject("eleImg is not a HTMLElement"),o;if(i=e,null!==t){if(!br(t))return o.reject("eleGroup is not a HTMLElement"),o;n=!1,i=t}if(!n){let e=dn(t.querySelectorAll("img"));if(0===e)return o.reject("eleGroup does not contain any img"),o;1===e&&(n=!0)}let s={button:!1,navbar:!1,title:!1,toolbar:{zoomIn:4,zoomOut:4,oneToOne:4,reset:4,prev:0,play:0,next:0,rotateLeft:4,rotateRight:4,flipHorizontal:4,flipVertical:4},tooltip:!1,movable:!0,zoomable:!0,rotatable:!0,scalable:!0,transition:!0,fullscreen:!1,keyboard:!0};n||(s=function(){let e={button:!1,navbar:!1,title:!1,toolbar:{zoomIn:4,zoomOut:4,oneToOne:4,reset:4,prev:0,play:0,next:0,rotateLeft:4,rotateRight:4,flipHorizontal:4,flipVertical:4},tooltip:!1,movable:!0,zoomable:!0,rotatable:!0,scalable:!0,transition:!0,fullscreen:!1,keyboard:!0};return e.navbar=!0,e.toolbar.prev=4,e.toolbar.next=4,e}()),s=vg(s,zi(r)),s.shown=function(){(async()=>{let e=null;await vs(()=>(e=l.viewer,br(e)));let t=!1,r=0,n=0,i=0;e.addEventListener("touchstart",e=>{let i=e.touches[0];r=i.clientX,n=i.clientY,((e,t)=>{let r=document.elementsFromPoint(e,t).find(e=>"IMG"===e.tagName);if(!br(r))return!0;let n=r?.classList?.contains("viewer-move");return!n})(r,n)&&(t=!0)},{passive:!1}),e.addEventListener("touchmove",e=>{if(!t)return;let o=e.touches[0],a=o.clientX,s=o.clientY,c=a-r,l=s-n,u=Math.sqrt(c*c+l*l);i+=u,r=o.clientX,n=o.clientY},{passive:!1}),e.addEventListener("touchend",e=>{t&&(i<a&&(e.preventDefault(),e.stopPropagation(),l.hide(!0)),t=!1,i=0)},{passive:!1}),e.addEventListener("touchcancel",e=>{t=!1,i=0})})().catch(e=>{console.log(e)})};let c=!1;s.hide=function(){c||(c=!0,l.hide(!0))},s.hidden=function(){l.destroy(),o.resolve("close")};let l=new(0,yn().Viewer)(i,s);return l.show(),o}function wg(e,t){let r=new MouseEvent(t,{view:window,bubbles:!0,cancelable:!0});e.dispatchEvent(r)}function Bg(e={}){let t=we(e,"kind","*"),r=we(e,"multiple");pn(r)||(r=!1);let n=we(e,"entireHierarchy");pn(n)||(n=!1),n&&!r&&(r=!0);let i=we(e,"sizeMbLimit");Se(i)||(i=1e3),i=Mn(i);let o=ns(),a="drf"+Hu(),s="GrpDomReadFile";Vf(`[name=${s}]`);let c=Id(t),l=`<div name="${s}" style="position:relative; width:0px; height:0px; overflow:hidden;"><input id="${a}" type="file" accept="${c}" ${r?"multiple":""} ${n?"webkitdirectory":""} style="opacity:0; position:absolute; top:-10000px; left:-10000px;"></div>`;zu(document.querySelector("body"),l);let u=ud("#"+a),f=!1;function d(e){f=!0;let t=yd(this,i);o.resolve(t),u.removeEventListener("change",d,!0),n||window.removeEventListener("focus",g),Vf(`[name=${s}]`)}function g(e){setTimeout(()=>{f||d()},300)}return u.addEventListener("change",d,!0),n||window.addEventListener("focus",g),wg(u,"click"),o}function Eg(e){if(!De(e))return!1;let t="YYYY-MM-DDTHH:mm:ss";return e===r(e,t).format(t)}In()&&function(){try{return new MouseEvent("MouseEventPolyfillTest"),!1}catch(e){}let e=function(e,t){t=t||{bubbles:!1,cancelable:!1};let r=document.createEvent("MouseEvent");return r.initMouseEvent(e,t.bubbles,t.cancelable,window,0,t.screenX||0,t.screenY||0,t.clientX||0,t.clientY||0,t.ctrlKey||!1,t.altKey||!1,t.shiftKey||!1,t.metaKey||!1,t.button||0,t.relatedTarget||null),r};e.prototype=Event.prototype,window.MouseEvent=e}();var Cg="top",xg="bottom",Dg="right",Fg="left",Qg="auto",Sg=[Cg,xg,Dg,Fg],kg="start",Ng="end",qg="viewport",Mg="popper",Hg=Sg.reduce(function(e,t){return e.concat([t+"-"+kg,t+"-"+Ng])},[]),Lg=[].concat(Sg,[Qg]).reduce(function(e,t){return e.concat([t,t+"-"+kg,t+"-"+Ng])},[]),Ug=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function Rg(e){return e?(e.nodeName||"").toLowerCase():null}function Og(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Tg(e){return e instanceof Og(e).Element||e instanceof Element}function Yg(e){return e instanceof Og(e).HTMLElement||e instanceof HTMLElement}function jg(e){return"undefined"!=typeof ShadowRoot&&(e instanceof Og(e).ShadowRoot||e instanceof ShadowRoot)}var Gg={name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach(function(e){var r=t.styles[e]||{},n=t.attributes[e]||{},i=t.elements[e];Yg(i)&&Rg(i)&&(Object.assign(i.style,r),Object.keys(n).forEach(function(e){var t=n[e];!1===t?i.removeAttribute(e):i.setAttribute(e,!0===t?"":t)}))})},effect:function(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow),function(){Object.keys(t.elements).forEach(function(e){var n=t.elements[e],i=t.attributes[e]||{},o=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:r[e]).reduce(function(e,t){return e[t]="",e},{});Yg(n)&&Rg(n)&&(Object.assign(n.style,o),Object.keys(i).forEach(function(e){n.removeAttribute(e)}))})}},requires:["computeStyles"]};function Jg(e){return e.split("-")[0]}var zg=Math.max,Vg=Math.min,Pg=Math.round;function Xg(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(e){return e.brand+"/"+e.version}).join(" "):navigator.userAgent}function _g(){return!/^((?!chrome|android).)*safari/i.test(Xg())}function Wg(e,t,r){void 0===t&&(t=!1),void 0===r&&(r=!1);var n=e.getBoundingClientRect(),i=1,o=1;t&&Yg(e)&&(i=e.offsetWidth>0&&Pg(n.width)/e.offsetWidth||1,o=e.offsetHeight>0&&Pg(n.height)/e.offsetHeight||1);var a=(Tg(e)?Og(e):window).visualViewport,s=!_g()&&r,c=(n.left+(s&&a?a.offsetLeft:0))/i,l=(n.top+(s&&a?a.offsetTop:0))/o,u=n.width/i,f=n.height/o;return{width:u,height:f,top:l,right:c+u,bottom:l+f,left:c,x:c,y:l}}function Kg(e){var t=Wg(e),r=e.offsetWidth,n=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-n)<=1&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:n}}function $g(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&jg(r)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function Zg(e){return Og(e).getComputedStyle(e)}function ep(e){return["table","td","th"].indexOf(Rg(e))>=0}function tp(e){return((Tg(e)?e.ownerDocument:e.document)||window.document).documentElement}function rp(e){return"html"===Rg(e)?e:e.assignedSlot||e.parentNode||(jg(e)?e.host:null)||tp(e)}function np(e){return Yg(e)&&"fixed"!==Zg(e).position?e.offsetParent:null}function ip(e){for(var t=Og(e),r=np(e);r&&ep(r)&&"static"===Zg(r).position;)r=np(r);return r&&("html"===Rg(r)||"body"===Rg(r)&&"static"===Zg(r).position)?t:r||function(e){var t=/firefox/i.test(Xg());if(/Trident/i.test(Xg())&&Yg(e)&&"fixed"===Zg(e).position)return null;var r=rp(e);for(jg(r)&&(r=r.host);Yg(r)&&["html","body"].indexOf(Rg(r))<0;){var n=Zg(r);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||t&&"filter"===n.willChange||t&&n.filter&&"none"!==n.filter)return r;r=r.parentNode}return null}(e)||t}function op(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function ap(e,t,r){return zg(e,Vg(t,r))}function sp(e){return Object.assign({},{top:0,right:0,bottom:0,left:0},e)}function cp(e,t){return t.reduce(function(t,r){return t[r]=e,t},{})}var lp={name:"arrow",enabled:!0,phase:"main",fn:function(e){var t,r=e.state,n=e.name,i=e.options,o=r.elements.arrow,a=r.modifiersData.popperOffsets,s=Jg(r.placement),c=op(s),l=[Fg,Dg].indexOf(s)>=0?"height":"width";if(o&&a){var u=function(e,t){return sp("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:cp(e,Sg))}(i.padding,r),f=Kg(o),d="y"===c?Cg:Fg,g="y"===c?xg:Dg,p=r.rects.reference[l]+r.rects.reference[c]-a[c]-r.rects.popper[l],h=a[c]-r.rects.reference[c],A=ip(o),m=A?"y"===c?A.clientHeight||0:A.clientWidth||0:0,I=p/2-h/2,y=u[d],v=m-f[l]-u[g],b=m/2-f[l]/2+I,w=ap(y,b,v),B=c;r.modifiersData[n]=((t={})[B]=w,t.centerOffset=w-b,t)}},effect:function(e){var t=e.state,r=e.options.element,n=void 0===r?"[data-popper-arrow]":r;null!=n&&("string"!=typeof n||(n=t.elements.popper.querySelector(n)))&&$g(t.elements.popper,n)&&(t.elements.arrow=n)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function up(e){return e.split("-")[1]}var fp={top:"auto",right:"auto",bottom:"auto",left:"auto"};function dp(e){var t,r=e.popper,n=e.popperRect,i=e.placement,o=e.variation,a=e.offsets,s=e.position,c=e.gpuAcceleration,l=e.adaptive,u=e.roundOffsets,f=e.isFixed,d=a.x,g=void 0===d?0:d,p=a.y,h=void 0===p?0:p,A="function"==typeof u?u({x:g,y:h}):{x:g,y:h};g=A.x,h=A.y;var m=a.hasOwnProperty("x"),I=a.hasOwnProperty("y"),y=Fg,v=Cg,b=window;if(l){var w=ip(r),B="clientHeight",E="clientWidth";if(w===Og(r)&&"static"!==Zg(w=tp(r)).position&&"absolute"===s&&(B="scrollHeight",E="scrollWidth"),i===Cg||(i===Fg||i===Dg)&&o===Ng)v=xg,h-=(f&&w===b&&b.visualViewport?b.visualViewport.height:w[B])-n.height,h*=c?1:-1;if(i===Fg||(i===Cg||i===xg)&&o===Ng)y=Dg,g-=(f&&w===b&&b.visualViewport?b.visualViewport.width:w[E])-n.width,g*=c?1:-1}var C,x=Object.assign({position:s},l&&fp),D=!0===u?function(e,t){var r=e.x,n=e.y,i=t.devicePixelRatio||1;return{x:Pg(r*i)/i||0,y:Pg(n*i)/i||0}}({x:g,y:h},Og(r)):{x:g,y:h};return g=D.x,h=D.y,c?Object.assign({},x,((C={})[v]=I?"0":"",C[y]=m?"0":"",C.transform=(b.devicePixelRatio||1)<=1?"translate("+g+"px, "+h+"px)":"translate3d("+g+"px, "+h+"px, 0)",C)):Object.assign({},x,((t={})[v]=I?h+"px":"",t[y]=m?g+"px":"",t.transform="",t))}var gp={passive:!0};var pp={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,r=e.instance,n=e.options,i=n.scroll,o=void 0===i||i,a=n.resize,s=void 0===a||a,c=Og(t.elements.popper),l=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&l.forEach(function(e){e.addEventListener("scroll",r.update,gp)}),s&&c.addEventListener("resize",r.update,gp),function(){o&&l.forEach(function(e){e.removeEventListener("scroll",r.update,gp)}),s&&c.removeEventListener("resize",r.update,gp)}},data:{}},hp={left:"right",right:"left",bottom:"top",top:"bottom"};function Ap(e){return e.replace(/left|right|bottom|top/g,function(e){return hp[e]})}var mp={start:"end",end:"start"};function Ip(e){return e.replace(/start|end/g,function(e){return mp[e]})}function yp(e){var t=Og(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function vp(e){return Wg(tp(e)).left+yp(e).scrollLeft}function bp(e){var t=Zg(e),r=t.overflow,n=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+i+n)}function wp(e){return["html","body","#document"].indexOf(Rg(e))>=0?e.ownerDocument.body:Yg(e)&&bp(e)?e:wp(rp(e))}function Bp(e,t){var r;void 0===t&&(t=[]);var n=wp(e),i=n===(null==(r=e.ownerDocument)?void 0:r.body),o=Og(n),a=i?[o].concat(o.visualViewport||[],bp(n)?n:[]):n,s=t.concat(a);return i?s:s.concat(Bp(rp(a)))}function Ep(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Cp(e,t,r){return t===qg?Ep(function(e,t){var r=Og(e),n=tp(e),i=r.visualViewport,o=n.clientWidth,a=n.clientHeight,s=0,c=0;if(i){o=i.width,a=i.height;var l=_g();(l||!l&&"fixed"===t)&&(s=i.offsetLeft,c=i.offsetTop)}return{width:o,height:a,x:s+vp(e),y:c}}(e,r)):Tg(t)?function(e,t){var r=Wg(e,!1,"fixed"===t);return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}(t,r):Ep(function(e){var t,r=tp(e),n=yp(e),i=null==(t=e.ownerDocument)?void 0:t.body,o=zg(r.scrollWidth,r.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),a=zg(r.scrollHeight,r.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),s=-n.scrollLeft+vp(e),c=-n.scrollTop;return"rtl"===Zg(i||r).direction&&(s+=zg(r.clientWidth,i?i.clientWidth:0)-o),{width:o,height:a,x:s,y:c}}(tp(e)))}function xp(e,t,r,n){var i="clippingParents"===t?function(e){var t=Bp(rp(e)),r=["absolute","fixed"].indexOf(Zg(e).position)>=0&&Yg(e)?ip(e):e;return Tg(r)?t.filter(function(e){return Tg(e)&&$g(e,r)&&"body"!==Rg(e)}):[]}(e):[].concat(t),o=[].concat(i,[r]),a=o[0],s=o.reduce(function(t,r){var i=Cp(e,r,n);return t.top=zg(i.top,t.top),t.right=Vg(i.right,t.right),t.bottom=Vg(i.bottom,t.bottom),t.left=zg(i.left,t.left),t},Cp(e,a,n));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function Dp(e){var t,r=e.reference,n=e.element,i=e.placement,o=i?Jg(i):null,a=i?up(i):null,s=r.x+r.width/2-n.width/2,c=r.y+r.height/2-n.height/2;switch(o){case Cg:t={x:s,y:r.y-n.height};break;case xg:t={x:s,y:r.y+r.height};break;case Dg:t={x:r.x+r.width,y:c};break;case Fg:t={x:r.x-n.width,y:c};break;default:t={x:r.x,y:r.y}}var l=o?op(o):null;if(null!=l){var u="y"===l?"height":"width";switch(a){case kg:t[l]=t[l]-(r[u]/2-n[u]/2);break;case Ng:t[l]=t[l]+(r[u]/2-n[u]/2)}}return t}function Fp(e,t){void 0===t&&(t={});var r=t,n=r.placement,i=void 0===n?e.placement:n,o=r.strategy,a=void 0===o?e.strategy:o,s=r.boundary,c=void 0===s?"clippingParents":s,l=r.rootBoundary,u=void 0===l?qg:l,f=r.elementContext,d=void 0===f?Mg:f,g=r.altBoundary,p=void 0!==g&&g,h=r.padding,A=void 0===h?0:h,m=sp("number"!=typeof A?A:cp(A,Sg)),I=d===Mg?"reference":Mg,y=e.rects.popper,v=e.elements[p?I:d],b=xp(Tg(v)?v:v.contextElement||tp(e.elements.popper),c,u,a),w=Wg(e.elements.reference),B=Dp({reference:w,element:y,strategy:"absolute",placement:i}),E=Ep(Object.assign({},y,B)),C=d===Mg?E:w,x={top:b.top-C.top+m.top,bottom:C.bottom-b.bottom+m.bottom,left:b.left-C.left+m.left,right:C.right-b.right+m.right},D=e.modifiersData.offset;if(d===Mg&&D){var F=D[i];Object.keys(x).forEach(function(e){var t=[Dg,xg].indexOf(e)>=0?1:-1,r=[Cg,xg].indexOf(e)>=0?"y":"x";x[e]+=F[r]*t})}return x}function Qp(e,t){void 0===t&&(t={});var r=t,n=r.placement,i=r.boundary,o=r.rootBoundary,a=r.padding,s=r.flipVariations,c=r.allowedAutoPlacements,l=void 0===c?Lg:c,u=up(n),f=u?s?Hg:Hg.filter(function(e){return up(e)===u}):Sg,d=f.filter(function(e){return l.indexOf(e)>=0});0===d.length&&(d=f);var g=d.reduce(function(t,r){return t[r]=Fp(e,{placement:r,boundary:i,rootBoundary:o,padding:a})[Jg(r)],t},{});return Object.keys(g).sort(function(e,t){return g[e]-g[t]})}var Sp={name:"flip",enabled:!0,phase:"main",fn:function(e){var t=e.state,r=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var i=r.mainAxis,o=void 0===i||i,a=r.altAxis,s=void 0===a||a,c=r.fallbackPlacements,l=r.padding,u=r.boundary,f=r.rootBoundary,d=r.altBoundary,g=r.flipVariations,p=void 0===g||g,h=r.allowedAutoPlacements,A=t.options.placement,m=Jg(A),I=c||(m===A||!p?[Ap(A)]:function(e){if(Jg(e)===Qg)return[];var t=Ap(e);return[Ip(e),t,Ip(t)]}(A)),y=[A].concat(I).reduce(function(e,r){return e.concat(Jg(r)===Qg?Qp(t,{placement:r,boundary:u,rootBoundary:f,padding:l,flipVariations:p,allowedAutoPlacements:h}):r)},[]),v=t.rects.reference,b=t.rects.popper,w=new Map,B=!0,E=y[0],C=0;C<y.length;C++){var x=y[C],D=Jg(x),F=up(x)===kg,Q=[Cg,xg].indexOf(D)>=0,S=Q?"width":"height",k=Fp(t,{placement:x,boundary:u,rootBoundary:f,altBoundary:d,padding:l}),N=Q?F?Dg:Fg:F?xg:Cg;v[S]>b[S]&&(N=Ap(N));var q=Ap(N),M=[];if(o&&M.push(k[D]<=0),s&&M.push(k[N]<=0,k[q]<=0),M.every(function(e){return e})){E=x,B=!1;break}w.set(x,M)}if(B)for(var H=function(e){var t=y.find(function(t){var r=w.get(t);if(r)return r.slice(0,e).every(function(e){return e})});if(t)return E=t,"break"},L=p?3:1;L>0;L--){if("break"===H(L))break}t.placement!==E&&(t.modifiersData[n]._skip=!0,t.placement=E,t.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function kp(e,t,r){return void 0===r&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function Np(e){return[Cg,Dg,xg,Fg].some(function(t){return e[t]>=0})}var qp={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(e){var t=e.state,r=e.options,n=e.name,i=r.offset,o=void 0===i?[0,0]:i,a=Lg.reduce(function(e,r){return e[r]=function(e,t,r){var n=Jg(e),i=[Fg,Cg].indexOf(n)>=0?-1:1,o="function"==typeof r?r(Object.assign({},t,{placement:e})):r,a=o[0],s=o[1];return a=a||0,s=(s||0)*i,[Fg,Dg].indexOf(n)>=0?{x:s,y:a}:{x:a,y:s}}(r,t.rects,o),e},{}),s=a[t.placement],c=s.x,l=s.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=l),t.modifiersData[n]=a}};var Mp={name:"preventOverflow",enabled:!0,phase:"main",fn:function(e){var t=e.state,r=e.options,n=e.name,i=r.mainAxis,o=void 0===i||i,a=r.altAxis,s=void 0!==a&&a,c=r.boundary,l=r.rootBoundary,u=r.altBoundary,f=r.padding,d=r.tether,g=void 0===d||d,p=r.tetherOffset,h=void 0===p?0:p,A=Fp(t,{boundary:c,rootBoundary:l,padding:f,altBoundary:u}),m=Jg(t.placement),I=up(t.placement),y=!I,v=op(m),b="x"===v?"y":"x",w=t.modifiersData.popperOffsets,B=t.rects.reference,E=t.rects.popper,C="function"==typeof h?h(Object.assign({},t.rects,{placement:t.placement})):h,x="number"==typeof C?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),D=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,F={x:0,y:0};if(w){if(o){var Q,S="y"===v?Cg:Fg,k="y"===v?xg:Dg,N="y"===v?"height":"width",q=w[v],M=q+A[S],H=q-A[k],L=g?-E[N]/2:0,U=I===kg?B[N]:E[N],R=I===kg?-E[N]:-B[N],O=t.elements.arrow,T=g&&O?Kg(O):{width:0,height:0},Y=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},j=Y[S],G=Y[k],J=ap(0,B[N],T[N]),z=y?B[N]/2-L-J-j-x.mainAxis:U-J-j-x.mainAxis,V=y?-B[N]/2+L+J+G+x.mainAxis:R+J+G+x.mainAxis,P=t.elements.arrow&&ip(t.elements.arrow),X=P?"y"===v?P.clientTop||0:P.clientLeft||0:0,_=null!=(Q=null==D?void 0:D[v])?Q:0,W=q+V-_,K=ap(g?Vg(M,q+z-_-X):M,q,g?zg(H,W):H);w[v]=K,F[v]=K-q}if(s){var $,Z="x"===v?Cg:Fg,ee="x"===v?xg:Dg,te=w[b],re="y"===b?"height":"width",ne=te+A[Z],ie=te-A[ee],oe=-1!==[Cg,Fg].indexOf(m),ae=null!=($=null==D?void 0:D[b])?$:0,se=oe?ne:te-B[re]-E[re]-ae+x.altAxis,ce=oe?te+B[re]+E[re]-ae-x.altAxis:ie,le=g&&oe?function(e,t,r){var n=ap(e,t,r);return n>r?r:n}(se,te,ce):ap(g?se:ne,te,g?ce:ie);w[b]=le,F[b]=le-te}t.modifiersData[n]=F}},requiresIfExists:["offset"]};function Hp(e,t,r){void 0===r&&(r=!1);var n,i,o=Yg(t),a=Yg(t)&&function(e){var t=e.getBoundingClientRect(),r=Pg(t.width)/e.offsetWidth||1,n=Pg(t.height)/e.offsetHeight||1;return 1!==r||1!==n}(t),s=tp(t),c=Wg(e,a,r),l={scrollLeft:0,scrollTop:0},u={x:0,y:0};return(o||!o&&!r)&&(("body"!==Rg(t)||bp(s))&&(l=(n=t)!==Og(n)&&Yg(n)?{scrollLeft:(i=n).scrollLeft,scrollTop:i.scrollTop}:yp(n)),Yg(t)?((u=Wg(t,!0)).x+=t.clientLeft,u.y+=t.clientTop):s&&(u.x=vp(s))),{x:c.left+l.scrollLeft-u.x,y:c.top+l.scrollTop-u.y,width:c.width,height:c.height}}function Lp(e){var t=new Map,r=new Set,n=[];function i(e){r.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach(function(e){if(!r.has(e)){var n=t.get(e);n&&i(n)}}),n.push(e)}return e.forEach(function(e){t.set(e.name,e)}),e.forEach(function(e){r.has(e.name)||i(e)}),n}var Up={placement:"bottom",modifiers:[],strategy:"absolute"};function Rp(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return!t.some(function(e){return!(e&&"function"==typeof e.getBoundingClientRect)})}function Op(e){void 0===e&&(e={});var t=e,r=t.defaultModifiers,n=void 0===r?[]:r,i=t.defaultOptions,o=void 0===i?Up:i;return function(e,t,r){void 0===r&&(r=o);var i,a,s={placement:"bottom",orderedModifiers:[],options:Object.assign({},Up,o),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},c=[],l=!1,u={state:s,setOptions:function(r){var i="function"==typeof r?r(s.options):r;f(),s.options=Object.assign({},o,s.options,i),s.scrollParents={reference:Tg(e)?Bp(e):e.contextElement?Bp(e.contextElement):[],popper:Bp(t)};var a,l,d=function(e){var t=Lp(e);return Ug.reduce(function(e,r){return e.concat(t.filter(function(e){return e.phase===r}))},[])}((a=[].concat(n,s.options.modifiers),l=a.reduce(function(e,t){var r=e[t.name];return e[t.name]=r?Object.assign({},r,t,{options:Object.assign({},r.options,t.options),data:Object.assign({},r.data,t.data)}):t,e},{}),Object.keys(l).map(function(e){return l[e]})));return s.orderedModifiers=d.filter(function(e){return e.enabled}),s.orderedModifiers.forEach(function(e){var t=e.name,r=e.options,n=void 0===r?{}:r,i=e.effect;if("function"==typeof i){var o=i({state:s,name:t,instance:u,options:n}),a=function(){};c.push(o||a)}}),u.update()},forceUpdate:function(){if(!l){var e=s.elements,t=e.reference,r=e.popper;if(Rp(t,r)){s.rects={reference:Hp(t,ip(r),"fixed"===s.options.strategy),popper:Kg(r)},s.reset=!1,s.placement=s.options.placement,s.orderedModifiers.forEach(function(e){return s.modifiersData[e.name]=Object.assign({},e.data)});for(var n=0;n<s.orderedModifiers.length;n++)if(!0!==s.reset){var i=s.orderedModifiers[n],o=i.fn,a=i.options,c=void 0===a?{}:a,f=i.name;"function"==typeof o&&(s=o({state:s,options:c,name:f,instance:u})||s)}else s.reset=!1,n=-1}}},update:(i=function(){return new Promise(function(e){u.forceUpdate(),e(s)})},function(){return a||(a=new Promise(function(e){Promise.resolve().then(function(){a=void 0,e(i())})})),a}),destroy:function(){f(),l=!0}};if(!Rp(e,t))return u;function f(){c.forEach(function(e){return e()}),c=[]}return u.setOptions(r).then(function(e){!l&&r.onFirstUpdate&&r.onFirstUpdate(e)}),u}}var Tp=Op({defaultModifiers:[pp,{name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state,r=e.name;t.modifiersData[r]=Dp({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})},data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,r=e.options,n=r.gpuAcceleration,i=void 0===n||n,o=r.adaptive,a=void 0===o||o,s=r.roundOffsets,c=void 0===s||s,l={placement:Jg(t.placement),variation:up(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,dp(Object.assign({},l,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:a,roundOffsets:c})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,dp(Object.assign({},l,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})},data:{}},Gg,qp,Sp,Mp,lp,{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,r=e.name,n=t.rects.reference,i=t.rects.popper,o=t.modifiersData.preventOverflow,a=Fp(t,{elementContext:"reference"}),s=Fp(t,{altBoundary:!0}),c=kp(a,n),l=kp(s,i,o),u=Np(c),f=Np(l);t.modifiersData[r]={referenceClippingOffsets:c,popperEscapeOffsets:l,isReferenceHidden:u,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":f})}}]}),Yp="tippy-content",jp="tippy-arrow",Gp="tippy-svg-arrow",Jp={passive:!0,capture:!0},zp=function(){return document.body};function Vp(e,t,r){if(Array.isArray(e)){var n=e[t];return null==n?Array.isArray(r)?r[t]:r:n}return e}function Pp(e,t){var r={}.toString.call(e);return 0===r.indexOf("[object")&&r.indexOf(t+"]")>-1}function Xp(e,t){return"function"==typeof e?e.apply(void 0,t):e}function _p(e,t){return 0===t?e:function(n){clearTimeout(r),r=setTimeout(function(){e(n)},t)};var r}function Wp(e){return[].concat(e)}function Kp(e,t){-1===e.indexOf(t)&&e.push(t)}function $p(e){return[].slice.call(e)}function Zp(e){return Object.keys(e).reduce(function(t,r){return void 0!==e[r]&&(t[r]=e[r]),t},{})}function eh(){return document.createElement("div")}function th(e){return["Element","Fragment"].some(function(t){return Pp(e,t)})}function rh(e){return th(e)?[e]:function(e){return Pp(e,"NodeList")}(e)?$p(e):Array.isArray(e)?e:$p(document.querySelectorAll(e))}function nh(e,t){e.forEach(function(e){e&&(e.style.transitionDuration=t+"ms")})}function ih(e,t){e.forEach(function(e){e&&e.setAttribute("data-state",t)})}function oh(e,t,r){var n=t+"EventListener";["transitionend","webkitTransitionEnd"].forEach(function(t){e[n](t,r)})}function ah(e,t){for(var r=t;r;){var n;if(e.contains(r))return!0;r=null==r.getRootNode||null==(n=r.getRootNode())?void 0:n.host}return!1}var sh={isTouch:!1},ch=0;function lh(){sh.isTouch||(sh.isTouch=!0,window.performance&&document.addEventListener("mousemove",uh))}function uh(){var e=performance.now();e-ch<20&&(sh.isTouch=!1,document.removeEventListener("mousemove",uh)),ch=e}function fh(){var e,t=document.activeElement;if((e=t)&&e._tippy&&e._tippy.reference===e){var r=t._tippy;t.blur&&!r.state.isVisible&&t.blur()}}var dh,gh=!!("undefined"!=typeof window&&"undefined"!=typeof document)&&!!window.msCrypto;function ph(e){return[e+"() was called on a"+("destroy"===e?"n already-":" ")+"destroyed instance. This is a no-op but","indicates a potential memory leak."].join(" ")}function hh(e){return e.replace(/[ \t]{2,}/g," ").replace(/^[ \t]*/gm,"").trim()}function Ah(e){return hh("\n %ctippy.js\n\n %c"+hh(e)+"\n\n %c👷‍ This is a development-only message. It will be removed in production.\n ")}function mh(e){return[Ah(e),"color: #00C584; font-size: 1.3em; font-weight: bold;","line-height: 1.5","color: #a6a095;"]}function Ih(e,t){var r;e&&!dh.has(t)&&(dh.add(t),(r=console).warn.apply(r,mh(t)))}function yh(e,t){var r;e&&!dh.has(t)&&(dh.add(t),(r=console).error.apply(r,mh(t)))}dh=new Set;var vh={animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},bh=Object.assign({appendTo:zp,aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},vh,{allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999}),wh=Object.keys(bh);function Bh(e){var t=(e.plugins||[]).reduce(function(t,r){var n,i=r.name,o=r.defaultValue;i&&(t[i]=void 0!==e[i]?e[i]:null!=(n=bh[i])?n:o);return t},{});return Object.assign({},e,t)}function Eh(e,t){var r=Object.assign({},t,{content:Xp(t.content,[e])},t.ignoreAttributes?{}:function(e,t){return(t?Object.keys(Bh(Object.assign({},bh,{plugins:t}))):wh).reduce(function(t,r){var n=(e.getAttribute("data-tippy-"+r)||"").trim();if(!n)return t;if("content"===r)t[r]=n;else try{t[r]=JSON.parse(n)}catch(e){t[r]=n}return t},{})}(e,t.plugins));return r.aria=Object.assign({},bh.aria,r.aria),r.aria={expanded:"auto"===r.aria.expanded?t.interactive:r.aria.expanded,content:"auto"===r.aria.content?t.interactive?null:"describedby":r.aria.content},r}function Ch(e,t){void 0===e&&(e={}),void 0===t&&(t=[]),Object.keys(e).forEach(function(e){var r=function(e,t){var r=Object.assign({},e);return t.forEach(function(e){delete r[e]}),r}(bh,Object.keys(vh)),n=!function(e,t){return{}.hasOwnProperty.call(e,t)}(r,e);n&&(n=0===t.filter(function(t){return t.name===e}).length),Ih(n,["`"+e+"`","is not a valid prop. You may have spelled it incorrectly, or if it's","a plugin, forgot to pass it in an array as props.plugins.","\n\n","All props: https://atomiks.github.io/tippyjs/v6/all-props/\n","Plugins: https://atomiks.github.io/tippyjs/v6/plugins/"].join(" "))})}function xh(e,t){e.innerHTML=t}function Dh(e){var t=eh();return!0===e?t.className=jp:(t.className=Gp,th(e)?t.appendChild(e):xh(t,e)),t}function Fh(e,t){th(t.content)?(xh(e,""),e.appendChild(t.content)):"function"!=typeof t.content&&(t.allowHTML?xh(e,t.content):e.textContent=t.content)}function Qh(e){var t=e.firstElementChild,r=$p(t.children);return{box:t,content:r.find(function(e){return e.classList.contains(Yp)}),arrow:r.find(function(e){return e.classList.contains(jp)||e.classList.contains(Gp)}),backdrop:r.find(function(e){return e.classList.contains("tippy-backdrop")})}}function Sh(e){var t=eh(),r=eh();r.className="tippy-box",r.setAttribute("data-state","hidden"),r.setAttribute("tabindex","-1");var n=eh();function i(r,n){var i=Qh(t),o=i.box,a=i.content,s=i.arrow;n.theme?o.setAttribute("data-theme",n.theme):o.removeAttribute("data-theme"),"string"==typeof n.animation?o.setAttribute("data-animation",n.animation):o.removeAttribute("data-animation"),n.inertia?o.setAttribute("data-inertia",""):o.removeAttribute("data-inertia"),o.style.maxWidth="number"==typeof n.maxWidth?n.maxWidth+"px":n.maxWidth,n.role?o.setAttribute("role",n.role):o.removeAttribute("role"),r.content===n.content&&r.allowHTML===n.allowHTML||Fh(a,e.props),n.arrow?s?r.arrow!==n.arrow&&(o.removeChild(s),o.appendChild(Dh(n.arrow))):o.appendChild(Dh(n.arrow)):s&&o.removeChild(s)}return n.className=Yp,n.setAttribute("data-state","hidden"),Fh(n,e.props),t.appendChild(r),r.appendChild(n),i(e.props,e.props),{popper:t,onUpdate:i}}Sh.$$tippy=!0;var kh=1,Nh=[],qh=[];function Mh(e,t){var r,n,i,o,a,s,c,l,u=Eh(e,Object.assign({},bh,Bh(Zp(t)))),f=!1,d=!1,g=!1,p=!1,h=[],A=_p(P,u.interactiveDebounce),m=kh++,I=(l=u.plugins).filter(function(e,t){return l.indexOf(e)===t}),y={id:m,reference:e,popper:eh(),popperInstance:null,props:u,state:{isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},plugins:I,clearDelayTimeouts:function(){clearTimeout(r),clearTimeout(n),cancelAnimationFrame(i)},setProps:function(t){if(Ih(y.state.isDestroyed,ph("setProps")),y.state.isDestroyed)return;q("onBeforeUpdate",[y,t]),z();var r=y.props,n=Eh(e,Object.assign({},r,Zp(t),{ignoreAttributes:!0}));y.props=n,J(),r.interactiveDebounce!==n.interactiveDebounce&&(L(),A=_p(P,n.interactiveDebounce));r.triggerTarget&&!n.triggerTarget?Wp(r.triggerTarget).forEach(function(e){e.removeAttribute("aria-expanded")}):n.triggerTarget&&e.removeAttribute("aria-expanded");H(),N(),w&&w(r,n);y.popperInstance&&(K(),Z().forEach(function(e){requestAnimationFrame(e._tippy.popperInstance.forceUpdate)}));q("onAfterUpdate",[y,t])},setContent:function(e){y.setProps({content:e})},show:function(){Ih(y.state.isDestroyed,ph("show"));var e=y.state.isVisible,t=y.state.isDestroyed,r=!y.state.isEnabled,n=sh.isTouch&&!y.props.touch,i=Vp(y.props.duration,0,bh.duration);if(e||t||r||n)return;if(F().hasAttribute("disabled"))return;if(q("onShow",[y],!1),!1===y.props.onShow(y))return;y.state.isVisible=!0,D()&&(b.style.visibility="visible");N(),T(),y.state.isMounted||(b.style.transition="none");if(D()){var o=S();nh([o.box,o.content],0)}s=function(){var e;if(y.state.isVisible&&!p){if(p=!0,b.offsetHeight,b.style.transition=y.props.moveTransition,D()&&y.props.animation){var t=S(),r=t.box,n=t.content;nh([r,n],i),ih([r,n],"visible")}M(),H(),Kp(qh,y),null==(e=y.popperInstance)||e.forceUpdate(),q("onMount",[y]),y.props.animation&&D()&&function(e,t){j(e,t)}(i,function(){y.state.isShown=!0,q("onShown",[y])})}},function(){var e,t=y.props.appendTo,r=F();e=y.props.interactive&&t===zp||"parent"===t?r.parentNode:Xp(t,[r]);e.contains(b)||e.appendChild(b);y.state.isMounted=!0,K(),Ih(y.props.interactive&&t===bh.appendTo&&r.nextElementSibling!==b,["Interactive tippy element may not be accessible via keyboard","navigation because it is not directly after the reference element","in the DOM source order.","\n\n","Using a wrapper <div> or <span> tag around the reference element","solves this by creating a new parentNode context.","\n\n","Specifying `appendTo: document.body` silences this warning, but it","assumes you are using a focus management solution to handle","keyboard navigation.","\n\n","See: https://atomiks.github.io/tippyjs/v6/accessibility/#interactivity"].join(" "))}()},hide:function(){Ih(y.state.isDestroyed,ph("hide"));var e=!y.state.isVisible,t=y.state.isDestroyed,r=!y.state.isEnabled,n=Vp(y.props.duration,1,bh.duration);if(e||t||r)return;if(q("onHide",[y],!1),!1===y.props.onHide(y))return;y.state.isVisible=!1,y.state.isShown=!1,p=!1,f=!1,D()&&(b.style.visibility="hidden");if(L(),Y(),N(!0),D()){var i=S(),o=i.box,a=i.content;y.props.animation&&(nh([o,a],n),ih([o,a],"hidden"))}M(),H(),y.props.animation?D()&&function(e,t){j(e,function(){!y.state.isVisible&&b.parentNode&&b.parentNode.contains(b)&&t()})}(n,y.unmount):y.unmount()},hideWithInteractivity:function(e){Ih(y.state.isDestroyed,ph("hideWithInteractivity")),Q().addEventListener("mousemove",A),Kp(Nh,A),A(e)},enable:function(){y.state.isEnabled=!0},disable:function(){y.hide(),y.state.isEnabled=!1},unmount:function(){Ih(y.state.isDestroyed,ph("unmount")),y.state.isVisible&&y.hide();if(!y.state.isMounted)return;$(),Z().forEach(function(e){e._tippy.unmount()}),b.parentNode&&b.parentNode.removeChild(b);qh=qh.filter(function(e){return e!==y}),y.state.isMounted=!1,q("onHidden",[y])},destroy:function(){if(Ih(y.state.isDestroyed,ph("destroy")),y.state.isDestroyed)return;y.clearDelayTimeouts(),y.unmount(),z(),delete e._tippy,y.state.isDestroyed=!0,q("onDestroy",[y])}};if(!u.render)return yh(!0,"render() function has not been supplied."),y;var v=u.render(y),b=v.popper,w=v.onUpdate;b.setAttribute("data-tippy-root",""),b.id="tippy-"+y.id,y.popper=b,e._tippy=y,b._tippy=y;var B=I.map(function(e){return e.fn(y)}),E=e.hasAttribute("aria-expanded");return J(),H(),N(),q("onCreate",[y]),u.showOnCreate&&ee(),b.addEventListener("mouseenter",function(){y.props.interactive&&y.state.isVisible&&y.clearDelayTimeouts()}),b.addEventListener("mouseleave",function(){y.props.interactive&&y.props.trigger.indexOf("mouseenter")>=0&&Q().addEventListener("mousemove",A)}),y;function C(){var e=y.props.touch;return Array.isArray(e)?e:[e,0]}function x(){return"hold"===C()[0]}function D(){var e;return!(null==(e=y.props.render)||!e.$$tippy)}function F(){return c||e}function Q(){var e,t,r=F().parentNode;return r?null!=(t=Wp(r)[0])&&null!=(e=t.ownerDocument)&&e.body?t.ownerDocument:document:document}function S(){return Qh(b)}function k(e){return y.state.isMounted&&!y.state.isVisible||sh.isTouch||o&&"focus"===o.type?0:Vp(y.props.delay,e?0:1,bh.delay)}function N(e){void 0===e&&(e=!1),b.style.pointerEvents=y.props.interactive&&!e?"":"none",b.style.zIndex=""+y.props.zIndex}function q(e,t,r){var n;(void 0===r&&(r=!0),B.forEach(function(r){r[e]&&r[e].apply(r,t)}),r)&&(n=y.props)[e].apply(n,t)}function M(){var t=y.props.aria;if(t.content){var r="aria-"+t.content,n=b.id;Wp(y.props.triggerTarget||e).forEach(function(e){var t=e.getAttribute(r);if(y.state.isVisible)e.setAttribute(r,t?t+" "+n:n);else{var i=t&&t.replace(n,"").trim();i?e.setAttribute(r,i):e.removeAttribute(r)}})}}function H(){!E&&y.props.aria.expanded&&Wp(y.props.triggerTarget||e).forEach(function(e){y.props.interactive?e.setAttribute("aria-expanded",y.state.isVisible&&e===F()?"true":"false"):e.removeAttribute("aria-expanded")})}function L(){Q().removeEventListener("mousemove",A),Nh=Nh.filter(function(e){return e!==A})}function U(t){if(!sh.isTouch||!g&&"mousedown"!==t.type){var r=t.composedPath&&t.composedPath()[0]||t.target;if(!y.props.interactive||!ah(b,r)){if(Wp(y.props.triggerTarget||e).some(function(e){return ah(e,r)})){if(sh.isTouch)return;if(y.state.isVisible&&y.props.trigger.indexOf("click")>=0)return}else q("onClickOutside",[y,t]);!0===y.props.hideOnClick&&(y.clearDelayTimeouts(),y.hide(),d=!0,setTimeout(function(){d=!1}),y.state.isMounted||Y())}}}function R(){g=!0}function O(){g=!1}function T(){var e=Q();e.addEventListener("mousedown",U,!0),e.addEventListener("touchend",U,Jp),e.addEventListener("touchstart",O,Jp),e.addEventListener("touchmove",R,Jp)}function Y(){var e=Q();e.removeEventListener("mousedown",U,!0),e.removeEventListener("touchend",U,Jp),e.removeEventListener("touchstart",O,Jp),e.removeEventListener("touchmove",R,Jp)}function j(e,t){var r=S().box;function n(e){e.target===r&&(oh(r,"remove",n),t())}if(0===e)return t();oh(r,"remove",a),oh(r,"add",n),a=n}function G(t,r,n){void 0===n&&(n=!1),Wp(y.props.triggerTarget||e).forEach(function(e){e.addEventListener(t,r,n),h.push({node:e,eventType:t,handler:r,options:n})})}function J(){var e;x()&&(G("touchstart",V,{passive:!0}),G("touchend",X,{passive:!0})),(e=y.props.trigger,e.split(/\s+/).filter(Boolean)).forEach(function(e){if("manual"!==e)switch(G(e,V),e){case"mouseenter":G("mouseleave",X);break;case"focus":G(gh?"focusout":"blur",_);break;case"focusin":G("focusout",_)}})}function z(){h.forEach(function(e){var t=e.node,r=e.eventType,n=e.handler,i=e.options;t.removeEventListener(r,n,i)}),h=[]}function V(e){var t,r=!1;if(y.state.isEnabled&&!W(e)&&!d){var n="focus"===(null==(t=o)?void 0:t.type);o=e,c=e.currentTarget,H(),!y.state.isVisible&&Pp(e,"MouseEvent")&&Nh.forEach(function(t){return t(e)}),"click"===e.type&&(y.props.trigger.indexOf("mouseenter")<0||f)&&!1!==y.props.hideOnClick&&y.state.isVisible?r=!0:ee(e),"click"===e.type&&(f=!r),r&&!n&&te(e)}}function P(e){var t=e.target,r=F().contains(t)||b.contains(t);if("mousemove"!==e.type||!r){var n=Z().concat(b).map(function(e){var t,r=null==(t=e._tippy.popperInstance)?void 0:t.state;return r?{popperRect:e.getBoundingClientRect(),popperState:r,props:u}:null}).filter(Boolean);(function(e,t){var r=t.clientX,n=t.clientY;return e.every(function(e){var t=e.popperRect,i=e.popperState,o=e.props.interactiveBorder,a=i.placement.split("-")[0],s=i.modifiersData.offset;if(!s)return!0;var c="bottom"===a?s.top.y:0,l="top"===a?s.bottom.y:0,u="right"===a?s.left.x:0,f="left"===a?s.right.x:0,d=t.top-n+c>o,g=n-t.bottom-l>o,p=t.left-r+u>o,h=r-t.right-f>o;return d||g||p||h})})(n,e)&&(L(),te(e))}}function X(e){W(e)||y.props.trigger.indexOf("click")>=0&&f||(y.props.interactive?y.hideWithInteractivity(e):te(e))}function _(e){y.props.trigger.indexOf("focusin")<0&&e.target!==F()||y.props.interactive&&e.relatedTarget&&b.contains(e.relatedTarget)||te(e)}function W(e){return!!sh.isTouch&&x()!==e.type.indexOf("touch")>=0}function K(){$();var t=y.props,r=t.popperOptions,n=t.placement,i=t.offset,o=t.getReferenceClientRect,a=t.moveTransition,c=D()?Qh(b).arrow:null,l=o?{getBoundingClientRect:o,contextElement:o.contextElement||F()}:e,u={name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(e){var t=e.state;if(D()){var r=S().box;["placement","reference-hidden","escaped"].forEach(function(e){"placement"===e?r.setAttribute("data-placement",t.placement):t.attributes.popper["data-popper-"+e]?r.setAttribute("data-"+e,""):r.removeAttribute("data-"+e)}),t.attributes.popper={}}}},f=[{name:"offset",options:{offset:i}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!a}},u];D()&&c&&f.push({name:"arrow",options:{element:c,padding:3}}),f.push.apply(f,(null==r?void 0:r.modifiers)||[]),y.popperInstance=Tp(l,b,Object.assign({},r,{placement:n,onFirstUpdate:s,modifiers:f}))}function $(){y.popperInstance&&(y.popperInstance.destroy(),y.popperInstance=null)}function Z(){return $p(b.querySelectorAll("[data-tippy-root]"))}function ee(e){y.clearDelayTimeouts(),e&&q("onTrigger",[y,e]),T();var t=k(!0),n=C(),i=n[0],o=n[1];sh.isTouch&&"hold"===i&&o&&(t=o),t?r=setTimeout(function(){y.show()},t):y.show()}function te(e){if(y.clearDelayTimeouts(),q("onUntrigger",[y,e]),y.state.isVisible){if(!(y.props.trigger.indexOf("mouseenter")>=0&&y.props.trigger.indexOf("click")>=0&&["mouseleave","mousemove"].indexOf(e.type)>=0&&f)){var t=k(!1);t?n=setTimeout(function(){y.state.isVisible&&y.hide()},t):i=requestAnimationFrame(function(){y.hide()})}}else Y()}}function Hh(e,t){void 0===t&&(t={});var r=bh.plugins.concat(t.plugins||[]);!function(e){var t=!e,r="[object Object]"===Object.prototype.toString.call(e)&&!e.addEventListener;yh(t,["tippy() was passed","`"+String(e)+"`","as its targets (first) argument. Valid types are: String, Element,","Element[], or NodeList."].join(" ")),yh(r,["tippy() was passed a plain object which is not supported as an argument","for virtual positioning. Use props.getReferenceClientRect instead."].join(" "))}(e),Ch(t,r),document.addEventListener("touchstart",lh,Jp),window.addEventListener("blur",fh);var n=Object.assign({},t,{plugins:r}),i=rh(e),o=th(n.content),a=i.length>1;Ih(o&&a,["tippy() was passed an Element as the `content` prop, but more than","one tippy instance was created by this invocation. This means the","content element will only be appended to the last tippy instance.","\n\n","Instead, pass the .innerHTML of the element, or use a function that","returns a cloned version of the element instead.","\n\n","1) content: element.innerHTML\n","2) content: () => element.cloneNode(true)"].join(" "));var s=i.reduce(function(e,t){var r=t&&Mh(t,n);return r&&e.push(r),e},[]);return th(e)?s[0]:s}function Lh(e,t){void 0===t&&(t={});var r=t.insertAt;if(e&&"undefined"!=typeof document){var n=document.head||document.getElementsByTagName("head")[0],i=document.createElement("style");i.type="text/css","top"===r&&n.firstChild?n.insertBefore(i,n.firstChild):n.appendChild(i),i.styleSheet?i.styleSheet.cssText=e:i.appendChild(document.createTextNode(e))}}Hh.defaultProps=bh,Hh.setDefaultProps=function(e){Ch(e,[]),Object.keys(e).forEach(function(t){bh[t]=e[t]})},Hh.currentInput=sh,Object.assign({},Gg,{effect:function(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow)}}),Hh.setDefaultProps({render:Sh});Lh('.tippy-box[data-animation=fade][data-state=hidden]{opacity:0}[data-tippy-root]{max-width:calc(100vw - 10px)}.tippy-box{position:relative;background-color:#333;color:#fff;border-radius:4px;font-size:14px;line-height:1.4;white-space:normal;outline:0;transition-property:transform,visibility,opacity}.tippy-box[data-placement^=top]>.tippy-arrow{bottom:0}.tippy-box[data-placement^=top]>.tippy-arrow:before{bottom:-7px;left:0;border-width:8px 8px 0;border-top-color:initial;transform-origin:center top}.tippy-box[data-placement^=bottom]>.tippy-arrow{top:0}.tippy-box[data-placement^=bottom]>.tippy-arrow:before{top:-7px;left:0;border-width:0 8px 8px;border-bottom-color:initial;transform-origin:center bottom}.tippy-box[data-placement^=left]>.tippy-arrow{right:0}.tippy-box[data-placement^=left]>.tippy-arrow:before{border-width:8px 0 8px 8px;border-left-color:initial;right:-7px;transform-origin:center left}.tippy-box[data-placement^=right]>.tippy-arrow{left:0}.tippy-box[data-placement^=right]>.tippy-arrow:before{left:-7px;border-width:8px 8px 8px 0;border-right-color:initial;transform-origin:center right}.tippy-box[data-inertia][data-state=visible]{transition-timing-function:cubic-bezier(.54,1.5,.38,1.11)}.tippy-arrow{width:16px;height:16px;color:#333}.tippy-arrow:before{content:"";position:absolute;border-color:transparent;border-style:solid}.tippy-content{position:relative;padding:5px 9px;z-index:1}');async function Uh(e,t={}){if(!va(e))throw new Error("invalid fun");let r=we(t,"width");r=De(r)?sa(r):Se(r)?Mn(r):null;let n=we(t,"height");n=De(n)?sa(n):Se(n)?Mn(n):null;let i=document.createElement("div");Se(r)&&(i.style.width=`${r}px`),Se(n)&&(i.style.height=`${n}px`);let o=document.createElement("div");o.style.position="absolute",o.style.top=0,o.style.left=0,o.style.zIndex=-1,o.appendChild(i);let a=document.createElement("div");a.style.position="relative",a.appendChild(o);let s,c=document.createElement("div");c.style.position="fixed",c.style.zIndex=-1,c.appendChild(a),Pf(document.querySelector("body"),c);let l=e(i);return s=ys(l)?await l:l,Vf(c),s}function Rh(e){if(!va(e))throw new Error("fn is not a function");return function(){let t=ns(),r=null,n=null;try{r=e.apply(this,arguments)}catch(e){n=e}return null!==n?t.resolve({state:"error",msg:n}):ys(r)?r.then(e=>{t.resolve({state:"success",msg:e})}).catch(e=>{"cancelled"===we(e,"reason")?t.resolve({state:"cancelled",msg:""}):t.resolve({state:"error",msg:e})}):t.resolve({state:"success",msg:r}),t}}Lh(".tippy-box[data-theme~=light]{color:#26323d;box-shadow:0 0 20px 4px rgba(154,161,177,.15),0 4px 80px -8px rgba(36,40,47,.25),0 4px 4px -2px rgba(91,94,105,.15);background-color:#fff}.tippy-box[data-theme~=light][data-placement^=top]>.tippy-arrow:before{border-top-color:#fff}.tippy-box[data-theme~=light][data-placement^=bottom]>.tippy-arrow:before{border-bottom-color:#fff}.tippy-box[data-theme~=light][data-placement^=left]>.tippy-arrow:before{border-left-color:#fff}.tippy-box[data-theme~=light][data-placement^=right]>.tippy-arrow:before{border-right-color:#fff}.tippy-box[data-theme~=light]>.tippy-backdrop{background-color:#fff}.tippy-box[data-theme~=light]>.tippy-svg-arrow{fill:#fff}");let Oh=Rh;function Th(e){if(!Hn(e))return!1;return Zi(e)<0}function Yh(e=0){let t=0,r=[];Th(e)&&(e=0),e=Zi(e);let n=Xi();return n.get=function(){if(r.length>0){return t+=1,r.splice(0,1)[0]}return null},n.cb=function(){t-=1,t<0&&(t=0),r.length>0&&n.emit("message",r)},n.push=function(i){r.push(i),(e<=0||t<e)&&n.emit("message",r)},n.clear=function(){t=0,r=[]},n}function jh(e=0,t=!1){return new function(e,t){let r=null;Bo(e)||(e=0),e=Zi(e),gn(t)||(t=!1);let n=Yh(e);return n.on("message",async function(e){let t=n.get();if(!t)return;await bs(1);let r,i=we(t,"id"),o=we(t,"fun"),a=we(t,"input");r=va(o)?await Oh(o)(...a):{state:"error",msg:"fun is not a function"},n.emit(i,r),n.cb()}),function(e,...i){let o=ns(),a=Hu();r=a;let s={id:a,fun:e,input:i};return n.push(s),n.once(a,e=>{t?a===r?"success"===e.state?o.resolve(e.msg):o.reject(e.msg):o.reject({reason:"cancelled"}):"success"===e.state?o.resolve(e.msg):o.reject(e.msg)}),o}}(e,t)}function Gh(e,t){In()?De(e)?Vu()?function(e,t){window.navigator.msSaveOrOpenBlob(t,e)}(e,t):function(e,t){let r=window.URL.createObjectURL(t),n=document.createElement("a");n.href=r,n.download=e,document.body.appendChild(n),n.click(),document.body.removeChild(n),window.URL.revokeObjectURL(r)}(e,t):console.log("no filename"):console.log("no window")}function Jh(e,t="data"){if(!Be(e))return{error:"sheet is not an object"};De(t)||(t="data");let r=Qu();return r.SheetNames.push(t),r.Sheets[t]=e,r}function zh(e,t="data"){if(!Ce(e)&&!br(e))return{error:"data is not an array or element"};De(t)||(t="data");let r=null,n=bn(e);return ke(n,"error")?n:(r=Jh(n,t),ke(r,"error"),r)}function Vh(e,t="data",r){if(!De(e)){let t="no filename";return console.log(t,e),{error:t}}if(De(t)||(t="data"),!Ce(r)&&!br(r)){let e="data is not an array or element";return console.log(e,r),{error:e}}Ce(r)&&Ee(we(r,0,null))&&(r=mn(r));let n=zh(r,t);if(we(n,"error"))return console.log(n.error),n.error;let i=vn();if(In()){let t=i.write(n,{bookType:"xlsx",bookSST:!1,type:"array"});Gh(e,new Blob([t]))}else try{i.writeFile(n,e)}catch(e){let t=`xl.writeFile failed: ${we(e,"message",e)}. 提示: 若於Node ESM環境單獨深度import此檔, xlsx ESM build的_fs未注入會擲此錯; 請改用 import { downloadExcelFileFromData } from 'wsemi' (走package main的UMD bundle, xlsx CJS自動載fs), 或於app entry手動呼叫 XLSX.set_fs(fs) 注入fs`;return console.log(t),t}return"ok"}function Ph(e){if(!Za(e))return new Blob;return new Blob([e])}function Xh(e,t,r=""){if(!Rr(t))return{};let n={};return Er(t,function(t){n[t]=we(e,t,r)}),n}function _h(e,t){if(!Be(e))return{};if(!Rr(t))return{};let r={};return Er(t,function(t){ke(e,t)&&(r[t]=we(e,t))}),r}function Wh(e,t=0,r={}){Bo(t)||(t=0),t=Zi(t);let n=we(r,"rounding","");return"ROUND_HALF_UP"!==n&&"ROUND_HALF_EVEN"!==n&&(n="ROUND_HALF_UP"),Se(e)?new il(e).toDecimalPlaces(t,il[n]).toNumber():""}function Kh(e,t={}){if(!Se(e))throw new Error("v is not a number");let r=we(t,"returnDigit");if(pn(r)||(r=!1),Hn(e))return r?0:Ya(e);let n=null,i=null;for(let t=1;t<=16;t++){let r=e*Math.pow(10,t);if(Math.abs(r-Math.round(r))<1e-9){n=t,i=al(e,t);break}}return null===i&&(n=16,i=Ya(e)),r?n:i}let $h=e=>{let t=1;e<0&&(t=-1);let r=null;if((e=Math.abs(e))<.1)for(let n=1;n<16;n++){let i=Math.pow(10,n);if((e*=i)<1){r={r:1/i,v:t*e};break}}else{if(e<1)return{r:1,v:t*e};if(e>=1)for(let n=1;n<16;n++){let i=Math.pow(10,n);if((e/=i)<1){r={r:i,v:t*e};break}}}if(null===r)throw new Error(`can not normalize v[${e}]`);return r};var Zh=a,eA=Zh.spawn,tA=Zh.exec;function rA(e,t,r){var n={};try{Object.keys(e).forEach(function(r){e[r].forEach(function(e){n[e]||(nA(e,t),n[e]=1)}),n[r]||(nA(r,t),n[r]=1)})}catch(e){if(r)return r(e);throw e}if(r)return r()}function nA(e,t){try{process.kill(parseInt(e,10),t)}catch(e){if("ESRCH"!==e.code)throw e}}function iA(e,t,r,n,i){var o=n(e),a="";o.stdout.on("data",function(e){e=e.toString("ascii");a+=e});o.on("close",function(o){delete r[e],0==o?a.match(/\d+/g).forEach(function(o){o=parseInt(o,10),t[e].push(o),t[o]=[],r[o]=1,iA(o,t,r,n,i)}):0==Object.keys(r).length&&i()})}var oA=Un(function(e,t,r){if("function"==typeof t&&void 0===r&&(r=t,t=void 0),e=parseInt(e),Number.isNaN(e)){if(r)return r(new Error("pid must be a number"));throw new Error("pid must be a number")}var n={},i={};switch(n[e]=[],i[e]=1,process.platform){case"win32":tA("taskkill /pid "+e+" /T /F",r);break;case"darwin":iA(e,n,i,function(e){return eA("pgrep",["-P",e])},function(){rA(n,t,r)});break;default:iA(e,n,i,function(e){return eA("ps",["-o","pid","--no-headers","--ppid",e])},function(){rA(n,t,r)})}});function aA(e){let t=ns();return oA(Number(e),"SIGKILL",r=>{r?t.reject(r):t.resolve(`pid[${e}] killed`)}),t}function sA(e,t){return e>t}function cA(e){return e&&e.length?vd(e,cr,sA):void 0}function lA(e){return null==e?[]:function(e,t){return pe(t,function(t){return e[t]})}(e,dt(e))}function uA(e,t,r,n){for(var i=-1,o=null==e?0:e.length;++i<o;){var a=e[i];t(n,a,r(a),e)}return n}function fA(e,t,r,n){return pt(e,function(e,i,o){t(n,e,r(e),o)}),n}var dA,gA,pA=Object.prototype.hasOwnProperty,hA=(dA=function(e,t,r){pA.call(e,r)?e[r].push(t):di(e,r,[t])},function(e,t){var r=v(e)?uA:fA,n=gA?gA():{};return r(e,dA,fr(t),n)}),AA=hA;function mA(e,t){if(!Ce(e)||!Ce(t))return[];if(e.length!==t.length)return[];return xr(e,function(r,n){return vg(e[n],t[n])})}function IA(e,t={}){let r=we(t,"fs"),n=!1;try{r.statSync(e),n=!0}catch{n=!1}return n}function yA(e,t={}){let r=we(t,"fs");return!!IA(e,{fs:r})&&(!r.lstatSync(e).isDirectory()&&!r.lstatSync(e).isSymbolicLink())}function vA(e){return yA(e,{fs:s})}function bA(e,t={}){let r=we(t,"fs");if(!IA(e,{fs:r}))return!1;let n=r.lstatSync(e);return!n.isFile()&&!n.isSymbolicLink()}function wA(e,t={}){let r=we(t,"fs");if(bA(e,{fs:r}))return{success:"input folder is already exists: "+e};if(IA(e,{fs:r}))return{error:"input path already exists: "+e};try{r.mkdirSync(e,{recursive:!0})}catch(e){return{error:e}}return{success:"done: "+e}}function BA(e,t={}){let r=we(t,"path"),n=we(t,"fs");if(!IA(e,{fs:n})){let t=wA(e,{fs:n});return t.error?t.error:{success:"done: "+e}}if(!bA(e,{fs:n}))return{error:"input path is not a folder"};try{let t=n.readdirSync(e);for(let i of t){let t=r.join(e,i);n.statSync(t).isDirectory()?n.rmSync(t,{recursive:!0,force:!0}):n.unlinkSync(t)}}catch(e){return{error:e}}return{success:"done: "+e}}function EA(e,t,r={}){let n=we(r,"path"),i=we(r,"fs"),o=we(r,"useSync","");pn(o)||(o=!0);let a="";return a=o?function(e,t,r={}){let n=we(r,"path"),i=we(r,"fs");if(!yA(e,{fs:i}))return{error:`fpSrc[${e}] is not a file`};try{wA(n.dirname(t),{fs:i}),i.copyFileSync(e,t)}catch(e){return{error:e}}return{success:"done: "+t}}(e,t,{path:n,fs:i}):async function(e,t,r={}){let n=we(r,"path"),i=we(r,"fs");if(!yA(e,{fs:i}))return{error:`fpSrc[${e}] is not a file`};let o=null;return await(async(e,t)=>{wA(n.dirname(t),{fs:i}),await new Promise((r,n)=>{let o=i.createReadStream(e),a=i.createWriteStream(t);o.on("error",n),a.on("error",n),a.on("finish",r),o.pipe(a)})})(e,t).then(()=>{o={success:"done: "+t}}).catch(e=>{o={error:e}}),o}(e,t,{path:n,fs:i}),a}function CA(e,t,r={}){let n=we(r,"path"),i=we(r,"fs");if(!bA(e,{fs:i}))return{error:`fpSrc[${e}] is not a folder`};try{i.readdirSync(e).forEach(function(r){let o=n.resolve(e,r),a=n.resolve(t,r),s=i.lstatSync(o);if(s.isDirectory())wA(a,{fs:i}),CA(o,a,{path:n,fs:i});else if(s.isSymbolicLink()){let e=i.readlinkSync(o);i.symlinkSync(e,a)}else wA(n.dirname(a),{fs:i}),i.copyFileSync(o,a)})}catch(e){return{error:e}}return{success:"done: "+t}}function xA(e,t,r={}){let n=we(r,"path"),i=we(r,"fs"),o=we(r,"useSync","");pn(o)||(o=!0);let a="";return a=o?CA(e,t,{path:n,fs:i}):async function(e,t,r={}){let n=we(r,"path"),i=we(r,"fs");if(!bA(e,{fs:i}))return{error:`fpSrc[${e}] is not a folder`};let o=async(e,t)=>{let r=i.readdirSync(e);for(let a of r){let r=n.join(e,a),s=n.join(t,a),c=i.lstatSync(r);if(c.isDirectory())wA(s,{fs:i}),await o(r,s);else if(c.isSymbolicLink()){let e=i.readlinkSync(r);i.symlinkSync(e,s)}else wA(n.dirname(s),{fs:i}),await new Promise((e,t)=>{let n=i.createReadStream(r),o=i.createWriteStream(s);n.on("error",t),o.on("error",t),o.on("finish",e),n.pipe(o)})}},a=null;return await o(e,t).then(()=>{a={success:"done: "+t}}).catch(e=>{a={error:e}}),a}(e,t,{path:n,fs:i}),a}function DA(e){if(!De(e))return{path:"",isRoot:!1};for(;e.indexOf("\\\\")>=0;)e=e.replace("\\\\","\\");for(;e.indexOf("//")>=0;)e=e.replace("//","/");if(":"===fa(e,1))return{path:`${e}\\`,isRoot:!0};if("\\"===fa(e,1)){let t=Ga(e,1);return":"===fa(t,1)?{path:e,isRoot:!0}:{path:t,isRoot:!1}}if("/"===fa(e,1)){let t=Ga(e,1);return 0===t.length?{path:e,isRoot:!0}:{path:t,isRoot:!1}}return{path:e,isRoot:!1}}function FA(e){if(!De(e))return"";let t=DA(e);if(t.isRoot)return t.path;let r=t.path;try{r=r.split("\\").pop().split("/").pop()}catch(e){}return r}function QA(e){if(!De(e))return"";let t=DA(e);if(t.isRoot)return t.path;let r=FA(e=t.path);if(!De(r))return e;let n=DA(e=Ga(e,r.length));return n.isRoot,n.path}function SA(e,t="",r={}){let n=we(r,"fs"),i=we(r,"encoding","");if(De(i)||(i="utf8"),IA(e,{fs:n}))return{error:"input path already exists: "+e};if(yA(e,{fs:n}))return{error:"input file is already exists: "+e};let o=QA(e);bA(o,{fs:n})||wA(o,{fs:n});try{n.writeFileSync(e,t,{encoding:i})}catch(e){return{error:e}}return{success:"done: "+e}}function kA(e){return wA(e,{fs:s})}function NA(e,t={}){let r=we(t,"fs");if(!IA(e,{fs:r}))return{success:"file does not exist: "+e};if(!yA(e,{fs:r}))return{error:"input path is not a file: "+e};try{r.unlinkSync(e)}catch(e){return{error:e}}return{success:"done: "+e}}async function qA(e,t={}){let r=we(t,"numRetry");eo(r)||(r=5),r=Zi(r);let n=we(t,"fs",null);if(!IA(e,{fs:n}))return"file does not exist: "+e;if(!yA(e,{fs:n}))return Promise.reject("input path is not a file: "+e);for(let t=0;t<r;t++)try{n.unlinkSync(e);break}catch(e){if("EBUSY"!==e.code)return Promise.reject(e);await bs(300)}return"done: "+e}function MA(e,t={}){let r=we(t,"fs");if(!IA(e,{fs:r}))return{success:"folder does not exist: "+e};if(!bA(e,{fs:r}))return{error:"input path is not a folder: "+e};try{r.rmSync(e,{recursive:!0,force:!0})}catch(e){return{error:e}}return{success:"done: "+e}}function HA(e){return MA(e,{fs:s})}async function LA(e,t={}){let r=we(t,"numRetry");eo(r)||(r=5),r=Zi(r);let n=we(t,"fs",null);if(!IA(e,{fs:n}))return"folder does not exist: "+e;if(!bA(e,{fs:n}))return Promise.reject("input path is not a folder: "+e);for(let t=0;t<r;t++)try{n.rmSync(e,{recursive:!0,force:!0});break}catch(e){if("EBUSY"!==e.code)return Promise.reject(e);await bs(300)}return"done: "+e}async function UA(e,t,r={}){let n="",i=we(r,"fs"),o=we(r,"Readable");if(!De(e))throw new Error("urlIn in not an effective string");let a=QA(t),s=we(r,"fnOut","");De(s)||(s=FA(t)),bA(a,{fs:i})||wA(a,{fs:i});let c=ns();try{let r=await fetch(e);if(!r.ok)return c.reject(r.statusText),c;let a=i.createWriteStream(t);o.fromWeb(r.body).pipe(a),a.on("finish",()=>{c.resolve(t)}),a.on("error",e=>{n=e.message,c.reject(n)})}catch(e){n=e.message,c.reject(n)}return c}function RA(){if(!va(r))throw new Error("invalid dayjs");return r().format("YYYY-MM-DDTHH:mm:ssZ")}function OA(e){if(!De(e))return"";let t=FA(e),r=Jo(t,".");if(dn(r)<=1)return t;let n="";try{r=zo(r),n=xo(r,".")}catch(e){}return n}function TA(e){return bA(e,{fs:s})}function YA(e,t={}){let r=we(t,"polling");pn(r)||(r=!1);let n=we(t,"timeInterval");eo(n)||(n=100),n=Zi(n);let o=we(t,"timeBinaryInterval");eo(o)||(o=300),o=Zi(o);let a=new u.EventEmitter,c=e,l=null,d=setInterval(()=>{if(null===l)TA(c)&&(l=f.watch(c,{usePolling:r,interval:n,binaryInterval:o,awaitWriteFinish:!0}),l.on("all",(e,t,r)=>{t=i.resolve(t),a.emit("change",{type:e,fp:t,stats:r}),"unlinkDir"===e&&i.resolve(c)===t&&setTimeout(()=>{g()},1)}));else if(!TA(c)){let e=s.fstatSync;a.emit("change",{type:"unlinkDir",fp:i.resolve(c),stats:e}),setTimeout(()=>{g()},1)}},n),g=()=>{if(null!==l){try{l.unwatch(c)}catch(e){console.log(e)}l.close().catch(e=>{console.log(e)}).finally(()=>{l=null})}};return a.clear=()=>{g(),clearInterval(d)},a}function jA(e,t={}){let r=we(t,"fs"),n=we(t,"crypto"),i=we(t,"type","");De(i)||(i="sha512");let o=ns();if(!yA(e,{fs:r}))return o.reject(`fp[${e}] is not a file`),o;try{let t=n.createHash(i),a=r.createReadStream(e);a.on("readable",()=>{let e=a.read();e?t.update(e):o.resolve(t.digest("hex"))}),a.on("error",e=>{o.reject(e.toString())})}catch(e){o.reject(e.toString())}return o}const GA=new Uint8Array([0,97,115,109,1,0,0,0,1,48,8,96,3,127,127,127,1,127,96,3,127,127,127,0,96,2,127,127,0,96,1,127,1,127,96,3,127,127,126,1,126,96,3,126,127,127,1,126,96,2,127,126,0,96,1,127,1,126,3,11,10,0,0,2,1,3,4,5,6,1,7,5,3,1,0,1,7,85,9,3,109,101,109,2,0,5,120,120,104,51,50,0,0,6,105,110,105,116,51,50,0,2,8,117,112,100,97,116,101,51,50,0,3,8,100,105,103,101,115,116,51,50,0,4,5,120,120,104,54,52,0,5,6,105,110,105,116,54,52,0,7,8,117,112,100,97,116,101,54,52,0,8,8,100,105,103,101,115,116,54,52,0,9,10,251,22,10,242,1,1,4,127,32,0,32,1,106,33,3,32,1,65,16,79,4,127,32,3,65,16,107,33,6,32,2,65,168,136,141,161,2,106,33,3,32,2,65,137,235,208,208,7,107,33,4,32,2,65,207,140,162,142,6,106,33,5,3,64,32,3,32,0,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,3,32,4,32,0,65,4,106,34,0,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,4,32,2,32,0,65,4,106,34,0,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,2,32,5,32,0,65,4,106,34,0,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,5,32,6,32,0,65,4,106,34,0,79,13,0,11,32,2,65,12,119,32,5,65,18,119,106,32,4,65,7,119,106,32,3,65,1,119,106,5,32,2,65,177,207,217,178,1,106,11,32,1,106,32,0,32,1,65,15,113,16,1,11,146,1,0,32,1,32,2,106,33,2,3,64,32,1,65,4,106,32,2,75,69,4,64,32,0,32,1,40,2,0,65,189,220,202,149,124,108,106,65,17,119,65,175,214,211,190,2,108,33,0,32,1,65,4,106,33,1,12,1,11,11,3,64,32,1,32,2,79,69,4,64,32,0,32,1,45,0,0,65,177,207,217,178,1,108,106,65,11,119,65,177,243,221,241,121,108,33,0,32,1,65,1,106,33,1,12,1,11,11,32,0,32,0,65,15,118,115,65,247,148,175,175,120,108,34,0,65,13,118,32,0,115,65,189,220,202,149,124,108,34,0,65,16,118,32,0,115,11,63,0,32,0,65,8,106,32,1,65,168,136,141,161,2,106,54,2,0,32,0,65,12,106,32,1,65,137,235,208,208,7,107,54,2,0,32,0,65,16,106,32,1,54,2,0,32,0,65,20,106,32,1,65,207,140,162,142,6,106,54,2,0,11,195,4,1,6,127,32,1,32,2,106,33,6,32,0,65,24,106,33,4,32,0,65,40,106,40,2,0,33,3,32,0,32,0,40,2,0,32,2,106,54,2,0,32,0,65,4,106,34,5,32,5,40,2,0,32,2,65,16,79,32,0,40,2,0,65,16,79,114,114,54,2,0,32,2,32,3,106,65,16,73,4,64,32,3,32,4,106,32,1,32,2,252,10,0,0,32,0,65,40,106,32,2,32,3,106,54,2,0,15,11,32,3,4,64,32,3,32,4,106,32,1,65,16,32,3,107,34,2,252,10,0,0,32,0,65,8,106,34,3,32,3,40,2,0,32,4,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,54,2,0,32,0,65,12,106,34,3,32,3,40,2,0,32,4,65,4,106,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,54,2,0,32,0,65,16,106,34,3,32,3,40,2,0,32,4,65,8,106,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,54,2,0,32,0,65,20,106,34,3,32,3,40,2,0,32,4,65,12,106,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,54,2,0,32,0,65,40,106,65,0,54,2,0,32,1,32,2,106,33,1,11,32,1,32,6,65,16,107,77,4,64,32,6,65,16,107,33,8,32,0,65,8,106,40,2,0,33,2,32,0,65,12,106,40,2,0,33,3,32,0,65,16,106,40,2,0,33,5,32,0,65,20,106,40,2,0,33,7,3,64,32,2,32,1,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,2,32,3,32,1,65,4,106,34,1,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,3,32,5,32,1,65,4,106,34,1,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,5,32,7,32,1,65,4,106,34,1,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,7,32,8,32,1,65,4,106,34,1,79,13,0,11,32,0,65,8,106,32,2,54,2,0,32,0,65,12,106,32,3,54,2,0,32,0,65,16,106,32,5,54,2,0,32,0,65,20,106,32,7,54,2,0,11,32,1,32,6,73,4,64,32,4,32,1,32,6,32,1,107,34,1,252,10,0,0,32,0,65,40,106,32,1,54,2,0,11,11,97,1,1,127,32,0,65,16,106,40,2,0,33,1,32,0,65,4,106,40,2,0,4,127,32,1,65,12,119,32,0,65,20,106,40,2,0,65,18,119,106,32,0,65,12,106,40,2,0,65,7,119,106,32,0,65,8,106,40,2,0,65,1,119,106,5,32,1,65,177,207,217,178,1,106,11,32,0,40,2,0,106,32,0,65,24,106,32,0,65,40,106,40,2,0,16,1,11,255,3,2,3,126,1,127,32,0,32,1,106,33,6,32,1,65,32,79,4,126,32,6,65,32,107,33,6,32,2,66,214,235,130,238,234,253,137,245,224,0,124,33,3,32,2,66,177,169,172,193,173,184,212,166,61,125,33,4,32,2,66,249,234,208,208,231,201,161,228,225,0,124,33,5,3,64,32,3,32,0,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,3,32,4,32,0,65,8,106,34,0,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,4,32,2,32,0,65,8,106,34,0,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,2,32,5,32,0,65,8,106,34,0,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,5,32,6,32,0,65,8,106,34,0,79,13,0,11,32,2,66,12,137,32,5,66,18,137,124,32,4,66,7,137,124,32,3,66,1,137,124,32,3,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,32,4,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,32,2,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,32,5,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,5,32,2,66,197,207,217,178,241,229,186,234,39,124,11,32,1,173,124,32,0,32,1,65,31,113,16,6,11,134,2,0,32,1,32,2,106,33,2,3,64,32,2,32,1,65,8,106,79,4,64,32,1,41,3,0,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,32,0,133,66,27,137,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,33,0,32,1,65,8,106,33,1,12,1,11,11,32,1,65,4,106,32,2,77,4,64,32,0,32,1,53,2,0,66,135,149,175,175,152,182,222,155,158,127,126,133,66,23,137,66,207,214,211,190,210,199,171,217,66,126,66,249,243,221,241,153,246,153,171,22,124,33,0,32,1,65,4,106,33,1,11,3,64,32,1,32,2,73,4,64,32,0,32,1,49,0,0,66,197,207,217,178,241,229,186,234,39,126,133,66,11,137,66,135,149,175,175,152,182,222,155,158,127,126,33,0,32,1,65,1,106,33,1,12,1,11,11,32,0,32,0,66,33,136,133,66,207,214,211,190,210,199,171,217,66,126,34,0,32,0,66,29,136,133,66,249,243,221,241,153,246,153,171,22,126,34,0,32,0,66,32,136,133,11,77,0,32,0,65,8,106,32,1,66,214,235,130,238,234,253,137,245,224,0,124,55,3,0,32,0,65,16,106,32,1,66,177,169,172,193,173,184,212,166,61,125,55,3,0,32,0,65,24,106,32,1,55,3,0,32,0,65,32,106,32,1,66,249,234,208,208,231,201,161,228,225,0,124,55,3,0,11,244,4,2,3,127,4,126,32,1,32,2,106,33,5,32,0,65,40,106,33,4,32,0,65,200,0,106,40,2,0,33,3,32,0,32,0,41,3,0,32,2,173,124,55,3,0,32,2,32,3,106,65,32,73,4,64,32,3,32,4,106,32,1,32,2,252,10,0,0,32,0,65,200,0,106,32,2,32,3,106,54,2,0,15,11,32,3,4,64,32,3,32,4,106,32,1,65,32,32,3,107,34,2,252,10,0,0,32,0,65,8,106,34,3,32,3,41,3,0,32,4,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,55,3,0,32,0,65,16,106,34,3,32,3,41,3,0,32,4,65,8,106,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,55,3,0,32,0,65,24,106,34,3,32,3,41,3,0,32,4,65,16,106,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,55,3,0,32,0,65,32,106,34,3,32,3,41,3,0,32,4,65,24,106,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,55,3,0,32,0,65,200,0,106,65,0,54,2,0,32,1,32,2,106,33,1,11,32,1,65,32,106,32,5,77,4,64,32,5,65,32,107,33,2,32,0,65,8,106,41,3,0,33,6,32,0,65,16,106,41,3,0,33,7,32,0,65,24,106,41,3,0,33,8,32,0,65,32,106,41,3,0,33,9,3,64,32,6,32,1,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,6,32,7,32,1,65,8,106,34,1,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,7,32,8,32,1,65,8,106,34,1,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,8,32,9,32,1,65,8,106,34,1,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,9,32,2,32,1,65,8,106,34,1,79,13,0,11,32,0,65,8,106,32,6,55,3,0,32,0,65,16,106,32,7,55,3,0,32,0,65,24,106,32,8,55,3,0,32,0,65,32,106,32,9,55,3,0,11,32,1,32,5,73,4,64,32,4,32,1,32,5,32,1,107,34,1,252,10,0,0,32,0,65,200,0,106,32,1,54,2,0,11,11,188,2,1,5,126,32,0,65,24,106,41,3,0,33,1,32,0,41,3,0,34,2,66,32,90,4,126,32,0,65,8,106,41,3,0,34,3,66,1,137,32,0,65,16,106,41,3,0,34,4,66,7,137,124,32,1,66,12,137,32,0,65,32,106,41,3,0,34,5,66,18,137,124,124,32,3,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,32,4,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,32,1,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,32,5,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,5,32,1,66,197,207,217,178,241,229,186,234,39,124,11,32,2,124,32,0,65,40,106,32,2,66,31,131,167,16,6,11]);async function JA(){return function(e){const{exports:{mem:t,xxh32:r,xxh64:n,init32:i,update32:o,digest32:a,init64:s,update64:c,digest64:l}}=e;let u=new Uint8Array(t.buffer);function f(e,r){if(t.buffer.byteLength<e+r){const n=Math.ceil((e+r-t.buffer.byteLength)/65536);t.grow(n),u=new Uint8Array(t.buffer)}}function d(e,t,r,n,i,o){f(e);const a=new Uint8Array(e);return u.set(a),r(0,t),a.set(u.subarray(0,e)),{update(t){let r;return u.set(a),"string"==typeof t?(f(3*t.length,e),r=A.encodeInto(t,u.subarray(e)).written):(f(t.byteLength,e),u.set(t,e),r=t.byteLength),n(0,e,r),a.set(u.subarray(0,e)),this},digest:()=>(u.set(a),o(i(0)))}}function g(e){return e>>>0}const p=2n**64n-1n;function h(e){return e&p}const A=new TextEncoder;function m(e,t=0){return f(3*e.length,0),g(r(0,A.encodeInto(e,u).written,t))}function I(e,t=0n){return f(3*e.length,0),h(n(0,A.encodeInto(e,u).written,t))}return{h32:m,h32ToString:(e,t=0)=>m(e,t).toString(16).padStart(8,"0"),h32Raw:(e,t=0)=>(f(e.byteLength,0),u.set(e),g(r(0,e.byteLength,t))),create32:(e=0)=>d(48,e,i,o,a,g),h64:I,h64ToString:(e,t=0n)=>I(e,t).toString(16).padStart(16,"0"),h64Raw:(e,t=0n)=>(f(e.byteLength,0),u.set(e),h(n(0,e.byteLength,t))),create64:(e=0n)=>d(88,e,s,c,l,h)}}((await WebAssembly.instantiate(GA)).instance)}async function zA(e,t={}){let r=we(t,"fs"),n=we(t,"chunkSize");if(Se(n)||(n=67108864),n=Mn(n),!yA(e,{fs:r}))return Promise.reject("fp is not a file");let i=ns();try{let{create64:t}=await JA(),o=t(),a=r.createReadStream(e,{highWaterMark:n});a.on("data",e=>{o.update(e)}),a.on("end",()=>{let e=o.digest().toString(16).padStart(16,"0");i.resolve(e)}),a.on("error",i.reject)}catch(e){i.reject(e.toString())}return i}function VA(e,t={}){let r=we(t,"fs"),n=we(t,"crypto"),i=we(t,"type","");De(i)||(i="sha512");let o=we(t,"chunkSize");Se(o)||(o=67108864),o=Mn(o);let a=ns();return yA(e,{fs:r})?"xxhash64"===i?zA(e,{fs:r,chunkSize:o}):jA(e,{fs:r,crypto:n,type:i}):(a.reject(`fp[${e}] is not a file`),a)}function PA(e,t=1,r={}){let n=1,i=we(r,"path"),o=we(r,"fs");if(!bA(e,{fs:o}))throw new Error(`fd[${e}] is not a folder`);return null!==t&&eo(t)&&(t=Zi(t))<1&&(t=1),function e(r){let a=[];return bA(r,{fs:o})?(Er(o.readdirSync(r),function(s){let c=i.resolve(r,s),l=null;try{l=o.statSync(c)}catch(e){}l&&l.isDirectory()?(a.push({isFolder:!0,level:n,path:c,name:i.basename(c)}),n+=1,(n<=t||null===t)&&(a=a.concat(e(c))),n-=1):a.push({isFolder:!1,level:n,path:c,name:i.basename(c)})}),a):a}(e)}function XA(e,t=1,r={}){let n=we(r,"path"),i=we(r,"fs");if(!bA(e,{fs:i}))throw new Error(`fd[${e}] is not a folder`);let o=[];return o=PA(e,t,{path:n,fs:i}),o=pa(o,{isFolder:!1}),o=xr(o,e=>(delete e.isFolder,e)),o}async function _A(e,t=1,r={}){let n=we(r,"path"),i=we(r,"fs"),o=we(r,"crypto"),a=we(r,"type","");if(De(a)||(a="md5"),!bA(e,{fs:i}))throw new Error(`fd[${e}] is not a folder`);let s=XA(e,t,{path:n,fs:i});return s=await cl(s,async e=>{let t=we(e,"path","");return e.hashType=a,e.hash="",De(t)&&(e.hash=await VA(t,{fs:i,crypto:o,type:a,useSync:!1})),e}),s}async function WA(e,t=1,r={}){return _A(e,t,{path:i,fs:s,crypto:d,...r})}async function KA(e,t={}){let r=we(t,"path"),n=we(t,"fs"),i=we(t,"crypto"),o=we(t,"type","");De(o)||(o="md5");let a=[],s=PA(e,null,{path:r,fs:n});return await cl(s,async e=>{if(e.isFolder)return;let t=await jA(e.path,{fs:n,crypto:i,type:o});a.push(t)}),xo(a,"|")}function $A(e,t=1,r={}){let n=we(r,"path"),i=we(r,"fs");if(!bA(e,{fs:i}))throw new Error(`fd[${e}] is not a folder`);let o=[];return o=PA(e,t,{path:n,fs:i}),o=pa(o,{isFolder:!0}),o=xr(o,e=>(delete e.isFolder,e)),o}async function ZA(e,t,r={}){let n="",i=we(r,"fs");if(!Rr(e))throw new Error("fpsIn in not an effective array");let o=QA(t),a=we(r,"fnOut","");De(a)||(a=FA(t)),bA(o,{fs:i})||wA(o,{fs:i});let s=ns();try{let r=i.createWriteStream(t);for(let t=0;t<e.length;t++){let o=e[t];if(!yA(o,{fs:i}))throw new Error(`fpIn[${o}] is not a file`);let a=()=>{let e=ns(),t=i.createReadStream(o);return t.on("error",t=>{n=t.message,e.reject(t)}),t.on("end",()=>{NA(o,{fs:i}),e.resolve()}),t.pipe(r,{end:!1}),e};await a()}r.end(),r.on("error",e=>{n=e.message,s.reject(n)}),r.on("finish",()=>{let e={filename:a,path:t};s.resolve(e)})}catch(e){n=e.message,s.reject(n)}return s}function em(e,t={}){let r=null,n=we(t,"fs"),i="";try{i=n.readFileSync(e,"utf8")}catch(e){r=e}return null!==r?{error:r}:{success:i}}function tm(e,t,r={}){let n=we(r,"fs");if(!yA(e,{fs:n}))return{error:`pahOld[${e}] is not a file`};if(IA(t,{fs:n}))return{error:`pahNew[${t}] already exists`};let i=QA(t);bA(i,{fs:n})||wA(i,{fs:n});try{n.renameSync(e,t)}catch(e){return{error:e}}return{success:"done: "+t}}function rm(e,t,r={}){let n=we(r,"fs");if(!bA(e,{fs:n}))return{error:`pahOld[${e}] is not a folder`};if(IA(t,{fs:n}))return{error:`pahNew[${t}] already exists`};let i=QA(t);bA(i,{fs:n})||wA(i,{fs:n});try{n.renameSync(e,t)}catch(e){return{error:e}}return{success:"done: "+t}}function nm(e,t,r,n={}){let i=we(n,"withInfor");pn(i)||(i=!0);let o={del:[],add:[],same:[],diff:[]};if(!De(r))return console.log("invalid key"),i&&(o.infor={}),o;Ce(e)||(e=[e]),Ce(t)||(t=[t]),e=pa(e,e=>ke(e,r)),t=pa(t,e=>ke(e,r));let a=new Map(t.map(e=>[e[r],e]));for(let t of e){let e=a.get(t[r]);if(e){JSON.stringify(t)===JSON.stringify(e)?o.same.push(e):o.diff.push(e),a.delete(t[r])}else o.del.push(t)}if(o.add=Array.from(a.values()),i){let e={};for(let t of o.del)e[t[r]]="del";for(let t of o.add)e[t[r]]="add";for(let t of o.diff)e[t[r]]="diff";for(let t of o.same)e[t[r]]="same";o.infor=e}return o}async function im(e,t=1,r={}){let n=we(r,"path"),i=we(r,"fs"),o=we(r,"crypto"),a=we(r,"type","");De(a)||(a="md5");let s=we(r,"forFile",null);pn(s)||(s=!0);let c=we(r,"forFolder",null);if(pn(c)||(c=!1),!bA(e,{fs:i}))throw new Error(`fd[${e}] is not a folder`);let l=PA(e,t,{path:n,fs:i});return l=await cl(l,async e=>{let t="";return s&&!e.isFolder&&(t=await jA(e.path,{fs:i,crypto:o,type:a})),c&&e.isFolder&&(t=await KA(e.path,{path:n,fs:i,crypto:o,type:a})),e.hash=t,e}),l}async function om(e,t,r={}){let n=we(r,"path"),i=we(r,"fs"),o=we(r,"crypto"),a=we(r,"type","");if(De(a)||(a="md5"),!bA(e,{fs:i}))throw new Error(`fdSrc[${e}] is not a folder`);if(!bA(t,{fs:i}))return void await xA(e,t,{path:n,fs:i,useSync:!1});let s=n.sep,c=n.sep.length,l=(e,t)=>(e=xr(e,e=>((e,t)=>{let r=e.isFolder?"folder":"file",n=e.path.replace(t,"");return ua(n,c)===s&&(n=da(n,c)),n=n.replaceAll("\\","/"),{id:`${r}|${n}`,isFolder:e.isFolder,name:e.name,rpath:n,hash:e.hash}})(e,t)),e),u=await im(e,null,{path:n,fs:i,crypto:o,type:a,forFile:!0,forFolder:!1});u=l(u,n.resolve(e));let f=await im(t,null,{path:n,fs:i,crypto:o,type:a,forFile:!0,forFolder:!1});f=l(f,n.resolve(t));let d=nm(f,u,"id",{withInfor:!1});await cl(d.del,async e=>{if(e.isFolder){MA(n.resolve(t,e.rpath),{fs:i})}}),await cl(d.del,async e=>{if(!e.isFolder){NA(n.resolve(t,e.rpath),{fs:i})}}),await cl([...d.add,...d.diff],async r=>{if(!r.isFolder){let o=n.resolve(e,r.rpath),a=n.resolve(t,r.rpath);await EA(o,a,{path:n,fs:i,useSync:!1})}})}function am(e,t={}){let r=we(t,"polling");pn(r)||(r=!1);let n=we(t,"timeInterval");eo(n)||(n=100),n=Zi(n);let o=we(t,"timeBinaryInterval");eo(o)||(o=300),o=Zi(o);let a=new u.EventEmitter,s=e,c=null,l=setInterval(()=>{null===c&&vA(s)&&(c=f.watch(s,{usePolling:r,interval:n,binaryInterval:o,awaitWriteFinish:!0}),c.on("all",(e,t,r)=>{t=i.resolve(t),a.emit("change",{type:e,fp:t,stats:r})}))},n);return a.clear=()=>{(()=>{if(null!==c){try{c.unwatch(s)}catch(e){console.log(e)}c.close().catch(e=>{console.log(e)}).finally(()=>{c=null})}})(),clearInterval(l)},a}function sm(e,t,r={}){let n=null,i=we(r,"fs"),o=QA(e);bA(o,{fs:i})||wA(o,{fs:i});try{i.writeFileSync(e,t,"utf8")}catch(e){n=e}return null!==n?{error:n}:{success:e}}const cm=[];for(let e=0;e<256;++e)cm.push((e+256).toString(16).slice(1));const lm=new Uint8Array(16);function um(){return crypto.getRandomValues(lm)}const fm={};function dm(e,t,r){let n;if(e)n=gm(e.random??e.rng?.()??um(),e.msecs,e.seq,t,r);else{const e=Date.now(),i=um();!function(e,t,r){e.msecs??=-1/0,e.seq??=0,t>e.msecs?(e.seq=r[6]<<23|r[7]<<16|r[8]<<8|r[9],e.msecs=t):(e.seq=e.seq+1|0,0===e.seq&&e.msecs++)}(fm,e,i),n=gm(i,fm.msecs,fm.seq,t,r)}return t??function(e,t=0){return(cm[e[t+0]]+cm[e[t+1]]+cm[e[t+2]]+cm[e[t+3]]+"-"+cm[e[t+4]]+cm[e[t+5]]+"-"+cm[e[t+6]]+cm[e[t+7]]+"-"+cm[e[t+8]]+cm[e[t+9]]+"-"+cm[e[t+10]]+cm[e[t+11]]+cm[e[t+12]]+cm[e[t+13]]+cm[e[t+14]]+cm[e[t+15]]).toLowerCase()}(n)}function gm(e,t,r,n,i=0){if(e.length<16)throw new Error("Random bytes length must be >= 16");if(n){if(i<0||i+16>n.length)throw new RangeError(`UUID byte range ${i}:${i+15} is out of buffer bounds`)}else n=new Uint8Array(16),i=0;return t??=Date.now(),r??=127*e[6]<<24|e[7]<<16|e[8]<<8|e[9],n[i++]=t/1099511627776&255,n[i++]=t/4294967296&255,n[i++]=t/16777216&255,n[i++]=t/65536&255,n[i++]=t/256&255,n[i++]=255&t,n[i++]=112|r>>>28&15,n[i++]=r>>>20&255,n[i++]=128|r>>>14&63,n[i++]=r>>>6&255,n[i++]=r<<2&255|3&e[10],n[i++]=e[11],n[i++]=e[12],n[i++]=e[13],n[i++]=e[14],n[i++]=e[15],n}function pm(e){return"[object Uint16Array]"===Object.prototype.toString.call(e)}function hm(e){if(!(I(e)||gs(e)||Za(e)||pm(e)))return null;try{if(e.byteLength)return e.byteLength}catch(e){}try{if(e.length)return e.length}catch(e){}try{if(e.size)return e.size}catch(e){}return null}function Am(e,t=!0){if(!Rr(e)){return{error:"no data"}}let r=null;try{r=function(e,t=!0){let r=t?"\ufeff":"";return Er(e,e=>{let t=[];Er(e,e=>{xe(e)?(e=pl(e,"\r\n",""),e=pl(e,"\r",""),e=`"${e=pl(e,"\n","")}"`):e=pn(e)?e?"true":"false":Ya(e),t.push(e)}),r+=xo(t,",")+"\r\n"}),r}(e,t)}catch(e){return{error:e}}return r}function mm(e){return pn(e)?e?"true":"false":Ya(e)}function Im(e,t){let r=[];return e.SheetNames.forEach(function(n){let i=vn().utils.sheet_to_json(e.Sheets[n],{header:"A",defval:"",blankrows:!0});i=xr(i,e=>lA(e)),t&&(i=xr(i,e=>xr(e,e=>mm(e)))),r.push({sheetname:n,data:i})}),r}function ym(e,t){let r=we(t,"fmt","ltdt");if(!ya(["ltdt","csv","array"],r))return{error:"opt.fmt is not one of 'ltdt', 'csv', 'array'"};let n,i=we(t,"valueToString",!0);if(!pn(i))return{error:"opt.valueToString is not a boolean"};try{n=vn().read(e,{type:"buffer"})}catch(e){return console.log("error: ",e),{error:"can not read data from u8a"}}let o=null;try{"ltdt"===r?o=function(e,t){let r=[];return e.SheetNames.forEach(function(n){let i=vn().utils.sheet_to_json(e.Sheets[n]);t&&(i=xr(i,e=>(Er(e,(t,r)=>{e[r]=mm(t)}),e))),r.push({sheetname:n,data:i})}),r}(n,i):"array"===r?o=Im(n,i):"csv"===r&&(o=function(e,t){let r=Im(e,t);return Er(r,(e,t)=>{r[t].data=Am(e.data,!1)}),r}(n,i))}catch(e){return console.log("error: ",e),{error:"can not convert data"}}return o}var vm;function bm(e){if(!N(e))return!1;var t=k(e);return"[object Error]"==t||"[object DOMException]"==t||"string"==typeof e.message&&"string"==typeof e.name&&!vr(e)}function wm(e){return bm(e)}function Bm(e){if(!Ee(e))return{error:"wb is not an effective object"};if(!Ce(we(e,"SheetNames")))return{error:"wb.SheetNames is not an array"};if(!Be(we(e,"Sheets")))return{error:"wb.Sheets is not an object"};let t=null;try{t=ps(vn().write(e,{bookType:"xlsx",type:"binary"}))}catch(e){return{error:e}}return t}
15
+ var Bs,Es,Cs=9e15,xs=1e9,Ds="0123456789abcdef",Fs="2.3025850929940456840179914546843642076011014886287729760333279009675726096773524802359972050895982983419677840422862486334095254650828067566662873690987816894829072083255546808437998948262331985283935053089653777326288461633662222876982198867465436674744042432743651550489343149393914796194044002221051017141748003688084012647080685567743216228355220114804663715659121373450747856947683463616792101806445070648000277502684916746550586856935673420670581136429224554405758925724208241314695689016758940256776311356919292033376587141660230105703089634572075440370847469940168269282808481184289314848524948644871927809676271275775397027668605952496716674183485704422507197965004714951050492214776567636938662976979522110718264549734772662425709429322582798502585509785265383207606726317164309505995087807523710333101197857547331541421808427543863591778117054309827482385045648019095610299291824318237525357709750539565187697510374970888692180205189339507238539205144634197265287286965110862571492198849978748873771345686209167058",Qs="3.1415926535897932384626433832795028841971693993751058209749445923078164062862089986280348253421170679821480865132823066470938446095505822317253594081284811174502841027019385211055596446229489549303819644288109756659334461284756482337867831652712019091456485669234603486104543266482133936072602491412737245870066063155881748815209209628292540917153643678925903600113305305488204665213841469519415116094330572703657595919530921861173819326117931051185480744623799627495673518857527248912279381830119491298336733624406566430860213949463952247371907021798609437027705392171762931767523846748184676694051320005681271452635608277857713427577896091736371787214684409012249534301465495853710507922796892589235420199561121290219608640344181598136297747713099605187072113499999983729780499510597317328160963185950244594553469083026425223082533446850352619311881710100031378387528865875332083814206171776691473035982534904287554687311595628638823537875937519577818577805321712268066130019278766111959092164201989380952572010654858632789",Ss={precision:20,rounding:4,modulo:1,toExpNeg:-7,toExpPos:21,minE:-Cs,maxE:Cs,crypto:!1},ks=!0,Ns="[DecimalError] ",qs=Ns+"Invalid argument: ",Ms=Ns+"Precision limit exceeded",Hs=Ns+"crypto unavailable",Ls="[object Decimal]",Us=Math.floor,Rs=Math.pow,Os=/^0b([01]+(\.[01]*)?|\.[01]+)(p[+-]?\d+)?$/i,Ts=/^0x([0-9a-f]+(\.[0-9a-f]*)?|\.[0-9a-f]+)(p[+-]?\d+)?$/i,Ys=/^0o([0-7]+(\.[0-7]*)?|\.[0-7]+)(p[+-]?\d+)?$/i,js=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,Gs=1e7,Js=Fs.length-1,zs=Qs.length-1,Vs={toStringTag:Ls};function Ps(e){var t,r,n,i=e.length-1,o="",a=e[0];if(i>0){for(o+=a,t=1;t<i;t++)(r=7-(n=e[t]+"").length)&&(o+=ic(r)),o+=n;(r=7-(n=(a=e[t])+"").length)&&(o+=ic(r))}else if(0===a)return"0";for(;a%10==0;)a/=10;return o+a}function Xs(e,t,r){if(e!==~~e||e<t||e>r)throw Error(qs+e)}function _s(e,t,r,n){var i,o,a,s;for(o=e[0];o>=10;o/=10)--t;return--t<0?(t+=7,i=0):(i=Math.ceil((t+1)/7),t%=7),o=Rs(10,7-t),s=e[i]%o|0,null==n?t<3?(0==t?s=s/100|0:1==t&&(s=s/10|0),a=r<4&&99999==s||r>3&&49999==s||5e4==s||0==s):a=(r<4&&s+1==o||r>3&&s+1==o/2)&&(e[i+1]/o/100|0)==Rs(10,t-2)-1||(s==o/2||0==s)&&!(e[i+1]/o/100|0):t<4?(0==t?s=s/1e3|0:1==t?s=s/100|0:2==t&&(s=s/10|0),a=(n||r<4)&&9999==s||!n&&r>3&&4999==s):a=((n||r<4)&&s+1==o||!n&&r>3&&s+1==o/2)&&(e[i+1]/o/1e3|0)==Rs(10,t-3)-1,a}function Ws(e,t,r){for(var n,i,o=[0],a=0,s=e.length;a<s;){for(i=o.length;i--;)o[i]*=t;for(o[0]+=Ds.indexOf(e.charAt(a++)),n=0;n<o.length;n++)o[n]>r-1&&(void 0===o[n+1]&&(o[n+1]=0),o[n+1]+=o[n]/r|0,o[n]%=r)}return o.reverse()}Vs.absoluteValue=Vs.abs=function(){var e=new this.constructor(this);return e.s<0&&(e.s=1),$s(e)},Vs.ceil=function(){return $s(new this.constructor(this),this.e+1,2)},Vs.clampedTo=Vs.clamp=function(e,t){var r=this,n=r.constructor;if(e=new n(e),t=new n(t),!e.s||!t.s)return new n(NaN);if(e.gt(t))throw Error(qs+t);return r.cmp(e)<0?e:r.cmp(t)>0?t:new n(r)},Vs.comparedTo=Vs.cmp=function(e){var t,r,n,i,o=this,a=o.d,s=(e=new o.constructor(e)).d,c=o.s,l=e.s;if(!a||!s)return c&&l?c!==l?c:a===s?0:!a^c<0?1:-1:NaN;if(!a[0]||!s[0])return a[0]?c:s[0]?-l:0;if(c!==l)return c;if(o.e!==e.e)return o.e>e.e^c<0?1:-1;for(t=0,r=(n=a.length)<(i=s.length)?n:i;t<r;++t)if(a[t]!==s[t])return a[t]>s[t]^c<0?1:-1;return n===i?0:n>i^c<0?1:-1},Vs.cosine=Vs.cos=function(){var e,t,r=this,n=r.constructor;return r.d?r.d[0]?(e=n.precision,t=n.rounding,n.precision=e+Math.max(r.e,r.sd())+7,n.rounding=1,r=function(e,t){var r,n,i;if(t.isZero())return t;n=t.d.length,n<32?i=(1/pc(4,r=Math.ceil(n/3))).toString():(r=16,i="2.3283064365386962890625e-10");e.precision+=r,t=gc(e,1,t.times(i),new e(1));for(var o=r;o--;){var a=t.times(t);t=a.times(a).minus(a).times(8).plus(1)}return e.precision-=r,t}(n,hc(n,r)),n.precision=e,n.rounding=t,$s(2==Es||3==Es?r.neg():r,e,t,!0)):new n(1):new n(NaN)},Vs.cubeRoot=Vs.cbrt=function(){var e,t,r,n,i,o,a,s,c,l,u=this,f=u.constructor;if(!u.isFinite()||u.isZero())return new f(u);for(ks=!1,(o=u.s*Rs(u.s*u,1/3))&&Math.abs(o)!=1/0?n=new f(o.toString()):(r=Ps(u.d),(o=((e=u.e)-r.length+1)%3)&&(r+=1==o||-2==o?"0":"00"),o=Rs(r,1/3),e=Us((e+1)/3)-(e%3==(e<0?-1:2)),(n=new f(r=o==1/0?"5e"+e:(r=o.toExponential()).slice(0,r.indexOf("e")+1)+e)).s=u.s),a=(e=f.precision)+3;;)if(l=(c=(s=n).times(s).times(s)).plus(u),n=Ks(l.plus(u).times(s),l.plus(c),a+2,1),Ps(s.d).slice(0,a)===(r=Ps(n.d)).slice(0,a)){if("9999"!=(r=r.slice(a-3,a+1))&&(i||"4999"!=r)){+r&&(+r.slice(1)||"5"!=r.charAt(0))||($s(n,e+1,1),t=!n.times(n).times(n).eq(u));break}if(!i&&($s(s,e+1,0),s.times(s).times(s).eq(u))){n=s;break}a+=4,i=1}return ks=!0,$s(n,e,f.rounding,t)},Vs.decimalPlaces=Vs.dp=function(){var e,t=this.d,r=NaN;if(t){if(r=7*((e=t.length-1)-Us(this.e/7)),e=t[e])for(;e%10==0;e/=10)r--;r<0&&(r=0)}return r},Vs.dividedBy=Vs.div=function(e){return Ks(this,new this.constructor(e))},Vs.dividedToIntegerBy=Vs.divToInt=function(e){var t=this.constructor;return $s(Ks(this,new t(e),0,1,1),t.precision,t.rounding)},Vs.equals=Vs.eq=function(e){return 0===this.cmp(e)},Vs.floor=function(){return $s(new this.constructor(this),this.e+1,3)},Vs.greaterThan=Vs.gt=function(e){return this.cmp(e)>0},Vs.greaterThanOrEqualTo=Vs.gte=function(e){var t=this.cmp(e);return 1==t||0===t},Vs.hyperbolicCosine=Vs.cosh=function(){var e,t,r,n,i,o=this,a=o.constructor,s=new a(1);if(!o.isFinite())return new a(o.s?1/0:NaN);if(o.isZero())return s;r=a.precision,n=a.rounding,a.precision=r+Math.max(o.e,o.sd())+4,a.rounding=1,(i=o.d.length)<32?t=(1/pc(4,e=Math.ceil(i/3))).toString():(e=16,t="2.3283064365386962890625e-10"),o=gc(a,1,o.times(t),new a(1),!0);for(var c,l=e,u=new a(8);l--;)c=o.times(o),o=s.minus(c.times(u.minus(c.times(u))));return $s(o,a.precision=r,a.rounding=n,!0)},Vs.hyperbolicSine=Vs.sinh=function(){var e,t,r,n,i=this,o=i.constructor;if(!i.isFinite()||i.isZero())return new o(i);if(t=o.precision,r=o.rounding,o.precision=t+Math.max(i.e,i.sd())+4,o.rounding=1,(n=i.d.length)<3)i=gc(o,2,i,i,!0);else{e=(e=1.4*Math.sqrt(n))>16?16:0|e,i=gc(o,2,i=i.times(1/pc(5,e)),i,!0);for(var a,s=new o(5),c=new o(16),l=new o(20);e--;)a=i.times(i),i=i.times(s.plus(a.times(c.times(a).plus(l))))}return o.precision=t,o.rounding=r,$s(i,t,r,!0)},Vs.hyperbolicTangent=Vs.tanh=function(){var e,t,r=this,n=r.constructor;return r.isFinite()?r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+7,n.rounding=1,Ks(r.sinh(),r.cosh(),n.precision=e,n.rounding=t)):new n(r.s)},Vs.inverseCosine=Vs.acos=function(){var e=this,t=e.constructor,r=e.abs().cmp(1),n=t.precision,i=t.rounding;return-1!==r?0===r?e.isNeg()?rc(t,n,i):new t(0):new t(NaN):e.isZero()?rc(t,n+4,i).times(.5):(t.precision=n+6,t.rounding=1,e=new t(1).minus(e).div(e.plus(1)).sqrt().atan(),t.precision=n,t.rounding=i,e.times(2))},Vs.inverseHyperbolicCosine=Vs.acosh=function(){var e,t,r=this,n=r.constructor;return r.lte(1)?new n(r.eq(1)?0:NaN):r.isFinite()?(e=n.precision,t=n.rounding,n.precision=e+Math.max(Math.abs(r.e),r.sd())+4,n.rounding=1,ks=!1,r=r.times(r).minus(1).sqrt().plus(r),ks=!0,n.precision=e,n.rounding=t,r.ln()):new n(r)},Vs.inverseHyperbolicSine=Vs.asinh=function(){var e,t,r=this,n=r.constructor;return!r.isFinite()||r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+2*Math.max(Math.abs(r.e),r.sd())+6,n.rounding=1,ks=!1,r=r.times(r).plus(1).sqrt().plus(r),ks=!0,n.precision=e,n.rounding=t,r.ln())},Vs.inverseHyperbolicTangent=Vs.atanh=function(){var e,t,r,n,i=this,o=i.constructor;return i.isFinite()?i.e>=0?new o(i.abs().eq(1)?i.s/0:i.isZero()?i:NaN):(e=o.precision,t=o.rounding,n=i.sd(),Math.max(n,e)<2*-i.e-1?$s(new o(i),e,t,!0):(o.precision=r=n-i.e,i=Ks(i.plus(1),new o(1).minus(i),r+e,1),o.precision=e+4,o.rounding=1,i=i.ln(),o.precision=e,o.rounding=t,i.times(.5))):new o(NaN)},Vs.inverseSine=Vs.asin=function(){var e,t,r,n,i=this,o=i.constructor;return i.isZero()?new o(i):(t=i.abs().cmp(1),r=o.precision,n=o.rounding,-1!==t?0===t?((e=rc(o,r+4,n).times(.5)).s=i.s,e):new o(NaN):(o.precision=r+6,o.rounding=1,i=i.div(new o(1).minus(i.times(i)).sqrt().plus(1)).atan(),o.precision=r,o.rounding=n,i.times(2)))},Vs.inverseTangent=Vs.atan=function(){var e,t,r,n,i,o,a,s,c,l=this,u=l.constructor,f=u.precision,d=u.rounding;if(l.isFinite()){if(l.isZero())return new u(l);if(l.abs().eq(1)&&f+4<=zs)return(a=rc(u,f+4,d).times(.25)).s=l.s,a}else{if(!l.s)return new u(NaN);if(f+4<=zs)return(a=rc(u,f+4,d).times(.5)).s=l.s,a}for(u.precision=s=f+10,u.rounding=1,e=r=Math.min(28,s/7+2|0);e;--e)l=l.div(l.times(l).plus(1).sqrt().plus(1));for(ks=!1,t=Math.ceil(s/7),n=1,c=l.times(l),a=new u(l),i=l;-1!==e;)if(i=i.times(c),o=a.minus(i.div(n+=2)),i=i.times(c),void 0!==(a=o.plus(i.div(n+=2))).d[t])for(e=t;a.d[e]===o.d[e]&&e--;);return r&&(a=a.times(2<<r-1)),ks=!0,$s(a,u.precision=f,u.rounding=d,!0)},Vs.isFinite=function(){return!!this.d},Vs.isInteger=Vs.isInt=function(){return!!this.d&&Us(this.e/7)>this.d.length-2},Vs.isNaN=function(){return!this.s},Vs.isNegative=Vs.isNeg=function(){return this.s<0},Vs.isPositive=Vs.isPos=function(){return this.s>0},Vs.isZero=function(){return!!this.d&&0===this.d[0]},Vs.lessThan=Vs.lt=function(e){return this.cmp(e)<0},Vs.lessThanOrEqualTo=Vs.lte=function(e){return this.cmp(e)<1},Vs.logarithm=Vs.log=function(e){var t,r,n,i,o,a,s,c,l=this,u=l.constructor,f=u.precision,d=u.rounding;if(null==e)e=new u(10),t=!0;else{if(r=(e=new u(e)).d,e.s<0||!r||!r[0]||e.eq(1))return new u(NaN);t=e.eq(10)}if(r=l.d,l.s<0||!r||!r[0]||l.eq(1))return new u(r&&!r[0]?-1/0:1!=l.s?NaN:r?0:1/0);if(t)if(r.length>1)o=!0;else{for(i=r[0];i%10==0;)i/=10;o=1!==i}if(ks=!1,a=lc(l,s=f+5),n=t?tc(u,s+10):lc(e,s),_s((c=Ks(a,n,s,1)).d,i=f,d))do{if(a=lc(l,s+=10),n=t?tc(u,s+10):lc(e,s),c=Ks(a,n,s,1),!o){+Ps(c.d).slice(i+1,i+15)+1==1e14&&(c=$s(c,f+1,0));break}}while(_s(c.d,i+=10,d));return ks=!0,$s(c,f,d)},Vs.minus=Vs.sub=function(e){var t,r,n,i,o,a,s,c,l,u,f,d,g=this,p=g.constructor;if(e=new p(e),!g.d||!e.d)return g.s&&e.s?g.d?e.s=-e.s:e=new p(e.d||g.s!==e.s?g:NaN):e=new p(NaN),e;if(g.s!=e.s)return e.s=-e.s,g.plus(e);if(l=g.d,d=e.d,s=p.precision,c=p.rounding,!l[0]||!d[0]){if(d[0])e.s=-e.s;else{if(!l[0])return new p(3===c?-0:0);e=new p(g)}return ks?$s(e,s,c):e}if(r=Us(e.e/7),u=Us(g.e/7),l=l.slice(),o=u-r){for((f=o<0)?(t=l,o=-o,a=d.length):(t=d,r=u,a=l.length),o>(n=Math.max(Math.ceil(s/7),a)+2)&&(o=n,t.length=1),t.reverse(),n=o;n--;)t.push(0);t.reverse()}else{for((f=(n=l.length)<(a=d.length))&&(a=n),n=0;n<a;n++)if(l[n]!=d[n]){f=l[n]<d[n];break}o=0}for(f&&(t=l,l=d,d=t,e.s=-e.s),a=l.length,n=d.length-a;n>0;--n)l[a++]=0;for(n=d.length;n>o;){if(l[--n]<d[n]){for(i=n;i&&0===l[--i];)l[i]=Gs-1;--l[i],l[n]+=Gs}l[n]-=d[n]}for(;0===l[--a];)l.pop();for(;0===l[0];l.shift())--r;return l[0]?(e.d=l,e.e=ec(l,r),ks?$s(e,s,c):e):new p(3===c?-0:0)},Vs.modulo=Vs.mod=function(e){var t,r=this,n=r.constructor;return e=new n(e),!r.d||!e.s||e.d&&!e.d[0]?new n(NaN):!e.d||r.d&&!r.d[0]?$s(new n(r),n.precision,n.rounding):(ks=!1,9==n.modulo?(t=Ks(r,e.abs(),0,3,1)).s*=e.s:t=Ks(r,e,0,n.modulo,1),t=t.times(e),ks=!0,r.minus(t))},Vs.naturalExponential=Vs.exp=function(){return cc(this)},Vs.naturalLogarithm=Vs.ln=function(){return lc(this)},Vs.negated=Vs.neg=function(){var e=new this.constructor(this);return e.s=-e.s,$s(e)},Vs.plus=Vs.add=function(e){var t,r,n,i,o,a,s,c,l,u,f=this,d=f.constructor;if(e=new d(e),!f.d||!e.d)return f.s&&e.s?f.d||(e=new d(e.d||f.s===e.s?f:NaN)):e=new d(NaN),e;if(f.s!=e.s)return e.s=-e.s,f.minus(e);if(l=f.d,u=e.d,s=d.precision,c=d.rounding,!l[0]||!u[0])return u[0]||(e=new d(f)),ks?$s(e,s,c):e;if(o=Us(f.e/7),n=Us(e.e/7),l=l.slice(),i=o-n){for(i<0?(r=l,i=-i,a=u.length):(r=u,n=o,a=l.length),i>(a=(o=Math.ceil(s/7))>a?o+1:a+1)&&(i=a,r.length=1),r.reverse();i--;)r.push(0);r.reverse()}for((a=l.length)-(i=u.length)<0&&(i=a,r=u,u=l,l=r),t=0;i;)t=(l[--i]=l[i]+u[i]+t)/Gs|0,l[i]%=Gs;for(t&&(l.unshift(t),++n),a=l.length;0==l[--a];)l.pop();return e.d=l,e.e=ec(l,n),ks?$s(e,s,c):e},Vs.precision=Vs.sd=function(e){var t,r=this;if(void 0!==e&&e!==!!e&&1!==e&&0!==e)throw Error(qs+e);return r.d?(t=nc(r.d),e&&r.e+1>t&&(t=r.e+1)):t=NaN,t},Vs.round=function(){var e=this,t=e.constructor;return $s(new t(e),e.e+1,t.rounding)},Vs.sine=Vs.sin=function(){var e,t,r=this,n=r.constructor;return r.isFinite()?r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+Math.max(r.e,r.sd())+7,n.rounding=1,r=function(e,t){var r,n=t.d.length;if(n<3)return t.isZero()?t:gc(e,2,t,t);r=(r=1.4*Math.sqrt(n))>16?16:0|r,t=t.times(1/pc(5,r)),t=gc(e,2,t,t);for(var i,o=new e(5),a=new e(16),s=new e(20);r--;)i=t.times(t),t=t.times(o.plus(i.times(a.times(i).minus(s))));return t}(n,hc(n,r)),n.precision=e,n.rounding=t,$s(Es>2?r.neg():r,e,t,!0)):new n(NaN)},Vs.squareRoot=Vs.sqrt=function(){var e,t,r,n,i,o,a=this,s=a.d,c=a.e,l=a.s,u=a.constructor;if(1!==l||!s||!s[0])return new u(!l||l<0&&(!s||s[0])?NaN:s?a:1/0);for(ks=!1,0==(l=Math.sqrt(+a))||l==1/0?(((t=Ps(s)).length+c)%2==0&&(t+="0"),l=Math.sqrt(t),c=Us((c+1)/2)-(c<0||c%2),n=new u(t=l==1/0?"5e"+c:(t=l.toExponential()).slice(0,t.indexOf("e")+1)+c)):n=new u(l.toString()),r=(c=u.precision)+3;;)if(n=(o=n).plus(Ks(a,o,r+2,1)).times(.5),Ps(o.d).slice(0,r)===(t=Ps(n.d)).slice(0,r)){if("9999"!=(t=t.slice(r-3,r+1))&&(i||"4999"!=t)){+t&&(+t.slice(1)||"5"!=t.charAt(0))||($s(n,c+1,1),e=!n.times(n).eq(a));break}if(!i&&($s(o,c+1,0),o.times(o).eq(a))){n=o;break}r+=4,i=1}return ks=!0,$s(n,c,u.rounding,e)},Vs.tangent=Vs.tan=function(){var e,t,r=this,n=r.constructor;return r.isFinite()?r.isZero()?new n(r):(e=n.precision,t=n.rounding,n.precision=e+10,n.rounding=1,(r=r.sin()).s=1,r=Ks(r,new n(1).minus(r.times(r)).sqrt(),e+10,0),n.precision=e,n.rounding=t,$s(2==Es||4==Es?r.neg():r,e,t,!0)):new n(NaN)},Vs.times=Vs.mul=function(e){var t,r,n,i,o,a,s,c,l,u=this,f=u.constructor,d=u.d,g=(e=new f(e)).d;if(e.s*=u.s,!(d&&d[0]&&g&&g[0]))return new f(!e.s||d&&!d[0]&&!g||g&&!g[0]&&!d?NaN:d&&g?0*e.s:e.s/0);for(r=Us(u.e/7)+Us(e.e/7),(c=d.length)<(l=g.length)&&(o=d,d=g,g=o,a=c,c=l,l=a),o=[],n=a=c+l;n--;)o.push(0);for(n=l;--n>=0;){for(t=0,i=c+n;i>n;)s=o[i]+g[n]*d[i-n-1]+t,o[i--]=s%Gs|0,t=s/Gs|0;o[i]=(o[i]+t)%Gs|0}for(;!o[--a];)o.pop();return t?++r:o.shift(),e.d=o,e.e=ec(o,r),ks?$s(e,f.precision,f.rounding):e},Vs.toBinary=function(e,t){return Ac(this,2,e,t)},Vs.toDecimalPlaces=Vs.toDP=function(e,t){var r=this,n=r.constructor;return r=new n(r),void 0===e?r:(Xs(e,0,xs),void 0===t?t=n.rounding:Xs(t,0,8),$s(r,e+r.e+1,t))},Vs.toExponential=function(e,t){var r,n=this,i=n.constructor;return void 0===e?r=Zs(n,!0):(Xs(e,0,xs),void 0===t?t=i.rounding:Xs(t,0,8),r=Zs(n=$s(new i(n),e+1,t),!0,e+1)),n.isNeg()&&!n.isZero()?"-"+r:r},Vs.toFixed=function(e,t){var r,n,i=this,o=i.constructor;return void 0===e?r=Zs(i):(Xs(e,0,xs),void 0===t?t=o.rounding:Xs(t,0,8),r=Zs(n=$s(new o(i),e+i.e+1,t),!1,e+n.e+1)),i.isNeg()&&!i.isZero()?"-"+r:r},Vs.toFraction=function(e){var t,r,n,i,o,a,s,c,l,u,f,d,g=this,p=g.d,h=g.constructor;if(!p)return new h(g);if(l=r=new h(1),n=c=new h(0),a=(o=(t=new h(n)).e=nc(p)-g.e-1)%7,t.d[0]=Rs(10,a<0?7+a:a),null==e)e=o>0?t:l;else{if(!(s=new h(e)).isInt()||s.lt(l))throw Error(qs+s);e=s.gt(t)?o>0?t:l:s}for(ks=!1,s=new h(Ps(p)),u=h.precision,h.precision=o=7*p.length*2;f=Ks(s,t,0,1,1),1!=(i=r.plus(f.times(n))).cmp(e);)r=n,n=i,i=l,l=c.plus(f.times(i)),c=i,i=t,t=s.minus(f.times(i)),s=i;return i=Ks(e.minus(r),n,0,1,1),c=c.plus(i.times(l)),r=r.plus(i.times(n)),c.s=l.s=g.s,d=Ks(l,n,o,1).minus(g).abs().cmp(Ks(c,r,o,1).minus(g).abs())<1?[l,n]:[c,r],h.precision=u,ks=!0,d},Vs.toHexadecimal=Vs.toHex=function(e,t){return Ac(this,16,e,t)},Vs.toNearest=function(e,t){var r=this,n=r.constructor;if(r=new n(r),null==e){if(!r.d)return r;e=new n(1),t=n.rounding}else{if(e=new n(e),void 0===t?t=n.rounding:Xs(t,0,8),!r.d)return e.s?r:e;if(!e.d)return e.s&&(e.s=r.s),e}return e.d[0]?(ks=!1,r=Ks(r,e,0,t,1).times(e),ks=!0,$s(r)):(e.s=r.s,r=e),r},Vs.toNumber=function(){return+this},Vs.toOctal=function(e,t){return Ac(this,8,e,t)},Vs.toPower=Vs.pow=function(e){var t,r,n,i,o,a,s=this,c=s.constructor,l=+(e=new c(e));if(!(s.d&&e.d&&s.d[0]&&e.d[0]))return new c(Rs(+s,l));if((s=new c(s)).eq(1))return s;if(n=c.precision,o=c.rounding,e.eq(1))return $s(s,n,o);if((t=Us(e.e/7))>=e.d.length-1&&(r=l<0?-l:l)<=9007199254740991)return i=oc(c,s,r,n),e.s<0?new c(1).div(i):$s(i,n,o);if((a=s.s)<0){if(t<e.d.length-1)return new c(NaN);if(1&e.d[t]||(a=1),0==s.e&&1==s.d[0]&&1==s.d.length)return s.s=a,s}return(t=0!=(r=Rs(+s,l))&&isFinite(r)?new c(r+"").e:Us(l*(Math.log("0."+Ps(s.d))/Math.LN10+s.e+1)))>c.maxE+1||t<c.minE-1?new c(t>0?a/0:0):(ks=!1,c.rounding=s.s=1,r=Math.min(12,(t+"").length),(i=cc(e.times(lc(s,n+r)),n)).d&&_s((i=$s(i,n+5,1)).d,n,o)&&(t=n+10,+Ps((i=$s(cc(e.times(lc(s,t+r)),t),t+5,1)).d).slice(n+1,n+15)+1==1e14&&(i=$s(i,n+1,0))),i.s=a,ks=!0,c.rounding=o,$s(i,n,o))},Vs.toPrecision=function(e,t){var r,n=this,i=n.constructor;return void 0===e?r=Zs(n,n.e<=i.toExpNeg||n.e>=i.toExpPos):(Xs(e,1,xs),void 0===t?t=i.rounding:Xs(t,0,8),r=Zs(n=$s(new i(n),e,t),e<=n.e||n.e<=i.toExpNeg,e)),n.isNeg()&&!n.isZero()?"-"+r:r},Vs.toSignificantDigits=Vs.toSD=function(e,t){var r=this.constructor;return void 0===e?(e=r.precision,t=r.rounding):(Xs(e,1,xs),void 0===t?t=r.rounding:Xs(t,0,8)),$s(new r(this),e,t)},Vs.toString=function(){var e=this,t=e.constructor,r=Zs(e,e.e<=t.toExpNeg||e.e>=t.toExpPos);return e.isNeg()&&!e.isZero()?"-"+r:r},Vs.truncated=Vs.trunc=function(){return $s(new this.constructor(this),this.e+1,1)},Vs.valueOf=Vs.toJSON=function(){var e=this,t=e.constructor,r=Zs(e,e.e<=t.toExpNeg||e.e>=t.toExpPos);return e.isNeg()?"-"+r:r};var Ks=function(){function e(e,t,r){var n,i=0,o=e.length;for(e=e.slice();o--;)n=e[o]*t+i,e[o]=n%r|0,i=n/r|0;return i&&e.unshift(i),e}function t(e,t,r,n){var i,o;if(r!=n)o=r>n?1:-1;else for(i=o=0;i<r;i++)if(e[i]!=t[i]){o=e[i]>t[i]?1:-1;break}return o}function r(e,t,r,n){for(var i=0;r--;)e[r]-=i,i=e[r]<t[r]?1:0,e[r]=i*n+e[r]-t[r];for(;!e[0]&&e.length>1;)e.shift()}return function(n,i,o,a,s,c){var l,u,f,d,g,p,h,A,m,I,y,v,b,w,B,E,C,x,D,F,Q=n.constructor,S=n.s==i.s?1:-1,k=n.d,N=i.d;if(!(k&&k[0]&&N&&N[0]))return new Q(n.s&&i.s&&(k?!N||k[0]!=N[0]:N)?k&&0==k[0]||!N?0*S:S/0:NaN);for(c?(g=1,u=n.e-i.e):(c=Gs,g=7,u=Us(n.e/g)-Us(i.e/g)),D=N.length,C=k.length,I=(m=new Q(S)).d=[],f=0;N[f]==(k[f]||0);f++);if(N[f]>(k[f]||0)&&u--,null==o?(w=o=Q.precision,a=Q.rounding):w=s?o+(n.e-i.e)+1:o,w<0)I.push(1),p=!0;else{if(w=w/g+2|0,f=0,1==D){for(d=0,N=N[0],w++;(f<C||d)&&w--;f++)B=d*c+(k[f]||0),I[f]=B/N|0,d=B%N|0;p=d||f<C}else{for((d=c/(N[0]+1)|0)>1&&(N=e(N,d,c),k=e(k,d,c),D=N.length,C=k.length),E=D,v=(y=k.slice(0,D)).length;v<D;)y[v++]=0;(F=N.slice()).unshift(0),x=N[0],N[1]>=c/2&&++x;do{d=0,(l=t(N,y,D,v))<0?(b=y[0],D!=v&&(b=b*c+(y[1]||0)),(d=b/x|0)>1?(d>=c&&(d=c-1),1==(l=t(h=e(N,d,c),y,A=h.length,v=y.length))&&(d--,r(h,D<A?F:N,A,c))):(0==d&&(l=d=1),h=N.slice()),(A=h.length)<v&&h.unshift(0),r(y,h,v,c),-1==l&&(l=t(N,y,D,v=y.length))<1&&(d++,r(y,D<v?F:N,v,c)),v=y.length):0===l&&(d++,y=[0]),I[f++]=d,l&&y[0]?y[v++]=k[E]||0:(y=[k[E]],v=1)}while((E++<C||void 0!==y[0])&&w--);p=void 0!==y[0]}I[0]||I.shift()}if(1==g)m.e=u,Bs=p;else{for(f=1,d=I[0];d>=10;d/=10)f++;m.e=f+u*g-1,$s(m,s?o+m.e+1:o,a,p)}return m}}();function $s(e,t,r,n){var i,o,a,s,c,l,u,f,d,g=e.constructor;e:if(null!=t){if(!(f=e.d))return e;for(i=1,s=f[0];s>=10;s/=10)i++;if((o=t-i)<0)o+=7,a=t,c=(u=f[d=0])/Rs(10,i-a-1)%10|0;else if((d=Math.ceil((o+1)/7))>=(s=f.length)){if(!n)break e;for(;s++<=d;)f.push(0);u=c=0,i=1,a=(o%=7)-7+1}else{for(u=s=f[d],i=1;s>=10;s/=10)i++;c=(a=(o%=7)-7+i)<0?0:u/Rs(10,i-a-1)%10|0}if(n=n||t<0||void 0!==f[d+1]||(a<0?u:u%Rs(10,i-a-1)),l=r<4?(c||n)&&(0==r||r==(e.s<0?3:2)):c>5||5==c&&(4==r||n||6==r&&(o>0?a>0?u/Rs(10,i-a):0:f[d-1])%10&1||r==(e.s<0?8:7)),t<1||!f[0])return f.length=0,l?(t-=e.e+1,f[0]=Rs(10,(7-t%7)%7),e.e=-t||0):f[0]=e.e=0,e;if(0==o?(f.length=d,s=1,d--):(f.length=d+1,s=Rs(10,7-o),f[d]=a>0?(u/Rs(10,i-a)%Rs(10,a)|0)*s:0),l)for(;;){if(0==d){for(o=1,a=f[0];a>=10;a/=10)o++;for(a=f[0]+=s,s=1;a>=10;a/=10)s++;o!=s&&(e.e++,f[0]==Gs&&(f[0]=1));break}if(f[d]+=s,f[d]!=Gs)break;f[d--]=0,s=1}for(o=f.length;0===f[--o];)f.pop()}return ks&&(e.e>g.maxE?(e.d=null,e.e=NaN):e.e<g.minE&&(e.e=0,e.d=[0])),e}function Zs(e,t,r){if(!e.isFinite())return uc(e);var n,i=e.e,o=Ps(e.d),a=o.length;return t?(r&&(n=r-a)>0?o=o.charAt(0)+"."+o.slice(1)+ic(n):a>1&&(o=o.charAt(0)+"."+o.slice(1)),o=o+(e.e<0?"e":"e+")+e.e):i<0?(o="0."+ic(-i-1)+o,r&&(n=r-a)>0&&(o+=ic(n))):i>=a?(o+=ic(i+1-a),r&&(n=r-i-1)>0&&(o=o+"."+ic(n))):((n=i+1)<a&&(o=o.slice(0,n)+"."+o.slice(n)),r&&(n=r-a)>0&&(i+1===a&&(o+="."),o+=ic(n))),o}function ec(e,t){var r=e[0];for(t*=7;r>=10;r/=10)t++;return t}function tc(e,t,r){if(t>Js)throw ks=!0,r&&(e.precision=r),Error(Ms);return $s(new e(Fs),t,1,!0)}function rc(e,t,r){if(t>zs)throw Error(Ms);return $s(new e(Qs),t,r,!0)}function nc(e){var t=e.length-1,r=7*t+1;if(t=e[t]){for(;t%10==0;t/=10)r--;for(t=e[0];t>=10;t/=10)r++}return r}function ic(e){for(var t="";e--;)t+="0";return t}function oc(e,t,r,n){var i,o=new e(1),a=Math.ceil(n/7+4);for(ks=!1;;){if(r%2&&mc((o=o.times(t)).d,a)&&(i=!0),0===(r=Us(r/2))){r=o.d.length-1,i&&0===o.d[r]&&++o.d[r];break}mc((t=t.times(t)).d,a)}return ks=!0,o}function ac(e){return 1&e.d[e.d.length-1]}function sc(e,t,r){for(var n,i,o=new e(t[0]),a=0;++a<t.length;){if(!(i=new e(t[a])).s){o=i;break}((n=o.cmp(i))===r||0===n&&o.s===r)&&(o=i)}return o}function cc(e,t){var r,n,i,o,a,s,c,l=0,u=0,f=0,d=e.constructor,g=d.rounding,p=d.precision;if(!e.d||!e.d[0]||e.e>17)return new d(e.d?e.d[0]?e.s<0?0:1/0:1:e.s?e.s<0?0:e:NaN);for(null==t?(ks=!1,c=p):c=t,s=new d(.03125);e.e>-2;)e=e.times(s),f+=5;for(c+=n=Math.log(Rs(2,f))/Math.LN10*2+5|0,r=o=a=new d(1),d.precision=c;;){if(o=$s(o.times(e),c,1),r=r.times(++u),Ps((s=a.plus(Ks(o,r,c,1))).d).slice(0,c)===Ps(a.d).slice(0,c)){for(i=f;i--;)a=$s(a.times(a),c,1);if(null!=t)return d.precision=p,a;if(!(l<3&&_s(a.d,c-n,g,l)))return $s(a,d.precision=p,g,ks=!0);d.precision=c+=10,r=o=s=new d(1),u=0,l++}a=s}}function lc(e,t){var r,n,i,o,a,s,c,l,u,f,d,g=1,p=e,h=p.d,A=p.constructor,m=A.rounding,I=A.precision;if(p.s<0||!h||!h[0]||!p.e&&1==h[0]&&1==h.length)return new A(h&&!h[0]?-1/0:1!=p.s?NaN:h?0:p);if(null==t?(ks=!1,u=I):u=t,A.precision=u+=10,n=(r=Ps(h)).charAt(0),!(Math.abs(o=p.e)<15e14))return l=tc(A,u+2,I).times(o+""),p=lc(new A(n+"."+r.slice(1)),u-10).plus(l),A.precision=I,null==t?$s(p,I,m,ks=!0):p;for(;n<7&&1!=n||1==n&&r.charAt(1)>3;)n=(r=Ps((p=p.times(e)).d)).charAt(0),g++;for(o=p.e,n>1?(p=new A("0."+r),o++):p=new A(n+"."+r.slice(1)),f=p,c=a=p=Ks(p.minus(1),p.plus(1),u,1),d=$s(p.times(p),u,1),i=3;;){if(a=$s(a.times(d),u,1),Ps((l=c.plus(Ks(a,new A(i),u,1))).d).slice(0,u)===Ps(c.d).slice(0,u)){if(c=c.times(2),0!==o&&(c=c.plus(tc(A,u+2,I).times(o+""))),c=Ks(c,new A(g),u,1),null!=t)return A.precision=I,c;if(!_s(c.d,u-10,m,s))return $s(c,A.precision=I,m,ks=!0);A.precision=u+=10,l=a=p=Ks(f.minus(1),f.plus(1),u,1),d=$s(p.times(p),u,1),i=s=1}c=l,i+=2}}function uc(e){return String(e.s*e.s/0)}function fc(e,t){var r,n,i;for((r=t.indexOf("."))>-1&&(t=t.replace(".","")),(n=t.search(/e/i))>0?(r<0&&(r=n),r+=+t.slice(n+1),t=t.substring(0,n)):r<0&&(r=t.length),n=0;48===t.charCodeAt(n);n++);for(i=t.length;48===t.charCodeAt(i-1);--i);if(t=t.slice(n,i)){if(i-=n,e.e=r=r-n-1,e.d=[],n=(r+1)%7,r<0&&(n+=7),n<i){for(n&&e.d.push(+t.slice(0,n)),i-=7;n<i;)e.d.push(+t.slice(n,n+=7));n=7-(t=t.slice(n)).length}else n-=i;for(;n--;)t+="0";e.d.push(+t),ks&&(e.e>e.constructor.maxE?(e.d=null,e.e=NaN):e.e<e.constructor.minE&&(e.e=0,e.d=[0]))}else e.e=0,e.d=[0];return e}function dc(e,t){var r,n,i,o,a,s,c,l,u;if(t.indexOf("_")>-1){if(t=t.replace(/(\d)_(?=\d)/g,"$1"),js.test(t))return fc(e,t)}else if("Infinity"===t||"NaN"===t)return+t||(e.s=NaN),e.e=NaN,e.d=null,e;if(Ts.test(t))r=16,t=t.toLowerCase();else if(Os.test(t))r=2;else{if(!Ys.test(t))throw Error(qs+t);r=8}for((o=t.search(/p/i))>0?(c=+t.slice(o+1),t=t.substring(2,o)):t=t.slice(2),a=(o=t.indexOf("."))>=0,n=e.constructor,a&&(o=(s=(t=t.replace(".","")).length)-o,i=oc(n,new n(r),o,2*o)),o=u=(l=Ws(t,r,Gs)).length-1;0===l[o];--o)l.pop();return o<0?new n(0*e.s):(e.e=ec(l,u),e.d=l,ks=!1,a&&(e=Ks(e,i,4*s)),c&&(e=e.times(Math.abs(c)<54?Rs(2,c):il.pow(2,c))),ks=!0,e)}function gc(e,t,r,n,i){var o,a,s,c,l=e.precision,u=Math.ceil(l/7);for(ks=!1,c=r.times(r),s=new e(n);;){if(a=Ks(s.times(c),new e(t++*t++),l,1),s=i?n.plus(a):n.minus(a),n=Ks(a.times(c),new e(t++*t++),l,1),void 0!==(a=s.plus(n)).d[u]){for(o=u;a.d[o]===s.d[o]&&o--;);if(-1==o)break}o=s,s=n,n=a,a=o}return ks=!0,a.d.length=u+1,a}function pc(e,t){for(var r=e;--t;)r*=e;return r}function hc(e,t){var r,n=t.s<0,i=rc(e,e.precision,1),o=i.times(.5);if((t=t.abs()).lte(o))return Es=n?4:1,t;if((r=t.divToInt(i)).isZero())Es=n?3:2;else{if((t=t.minus(r.times(i))).lte(o))return Es=ac(r)?n?2:3:n?4:1,t;Es=ac(r)?n?1:4:n?3:2}return t.minus(i).abs()}function Ac(e,t,r,n){var i,o,a,s,c,l,u,f,d,g=e.constructor,p=void 0!==r;if(p?(Xs(r,1,xs),void 0===n?n=g.rounding:Xs(n,0,8)):(r=g.precision,n=g.rounding),e.isFinite()){for(p?(i=2,16==t?r=4*r-3:8==t&&(r=3*r-2)):i=t,(a=(u=Zs(e)).indexOf("."))>=0&&(u=u.replace(".",""),(d=new g(1)).e=u.length-a,d.d=Ws(Zs(d),10,i),d.e=d.d.length),o=c=(f=Ws(u,10,i)).length;0==f[--c];)f.pop();if(f[0]){if(a<0?o--:((e=new g(e)).d=f,e.e=o,f=(e=Ks(e,d,r,n,0,i)).d,o=e.e,l=Bs),a=f[r],s=i/2,l=l||void 0!==f[r+1],l=n<4?(void 0!==a||l)&&(0===n||n===(e.s<0?3:2)):a>s||a===s&&(4===n||l||6===n&&1&f[r-1]||n===(e.s<0?8:7)),f.length=r,l)for(;++f[--r]>i-1;)f[r]=0,r||(++o,f.unshift(1));for(c=f.length;!f[c-1];--c);for(a=0,u="";a<c;a++)u+=Ds.charAt(f[a]);if(p){if(c>1)if(16==t||8==t){for(a=16==t?4:3,--c;c%a;c++)u+="0";for(c=(f=Ws(u,i,t)).length;!f[c-1];--c);for(a=1,u="1.";a<c;a++)u+=Ds.charAt(f[a])}else u=u.charAt(0)+"."+u.slice(1);u=u+(o<0?"p":"p+")+o}else if(o<0){for(;++o;)u="0"+u;u="0."+u}else if(++o>c)for(o-=c;o--;)u+="0";else o<c&&(u=u.slice(0,o)+"."+u.slice(o))}else u=p?"0p+0":"0";u=(16==t?"0x":2==t?"0b":8==t?"0o":"")+u}else u=uc(e);return e.s<0?"-"+u:u}function mc(e,t){if(e.length>t)return e.length=t,!0}function Ic(e){return new this(e).abs()}function yc(e){return new this(e).acos()}function vc(e){return new this(e).acosh()}function bc(e,t){return new this(e).plus(t)}function wc(e){return new this(e).asin()}function Bc(e){return new this(e).asinh()}function Ec(e){return new this(e).atan()}function Cc(e){return new this(e).atanh()}function xc(e,t){e=new this(e),t=new this(t);var r,n=this.precision,i=this.rounding,o=n+4;return e.s&&t.s?e.d||t.d?!t.d||e.isZero()?(r=t.s<0?rc(this,n,i):new this(0)).s=e.s:!e.d||t.isZero()?(r=rc(this,o,1).times(.5)).s=e.s:t.s<0?(this.precision=o,this.rounding=1,r=this.atan(Ks(e,t,o,1)),t=rc(this,o,1),this.precision=n,this.rounding=i,r=e.s<0?r.minus(t):r.plus(t)):r=this.atan(Ks(e,t,o,1)):(r=rc(this,o,1).times(t.s>0?.25:.75)).s=e.s:r=new this(NaN),r}function Dc(e){return new this(e).cbrt()}function Fc(e){return $s(e=new this(e),e.e+1,2)}function Qc(e,t,r){return new this(e).clamp(t,r)}function Sc(e){if(!e||"object"!=typeof e)throw Error(Ns+"Object expected");var t,r,n,i=!0===e.defaults,o=["precision",1,xs,"rounding",0,8,"toExpNeg",-Cs,0,"toExpPos",0,Cs,"maxE",0,Cs,"minE",-Cs,0,"modulo",0,9];for(t=0;t<o.length;t+=3)if(r=o[t],i&&(this[r]=Ss[r]),void 0!==(n=e[r])){if(!(Us(n)===n&&n>=o[t+1]&&n<=o[t+2]))throw Error(qs+r+": "+n);this[r]=n}if(r="crypto",i&&(this[r]=Ss[r]),void 0!==(n=e[r])){if(!0!==n&&!1!==n&&0!==n&&1!==n)throw Error(qs+r+": "+n);if(n){if("undefined"==typeof crypto||!crypto||!crypto.getRandomValues&&!crypto.randomBytes)throw Error(Hs);this[r]=!0}else this[r]=!1}return this}function kc(e){return new this(e).cos()}function Nc(e){return new this(e).cosh()}function qc(e,t){return new this(e).div(t)}function Mc(e){return new this(e).exp()}function Hc(e){return $s(e=new this(e),e.e+1,3)}function Lc(){var e,t,r=new this(0);for(ks=!1,e=0;e<arguments.length;)if((t=new this(arguments[e++])).d)r.d&&(r=r.plus(t.times(t)));else{if(t.s)return ks=!0,new this(1/0);r=t}return ks=!0,r.sqrt()}function Uc(e){return e instanceof il||e&&e.toStringTag===Ls||!1}function Rc(e){return new this(e).ln()}function Oc(e,t){return new this(e).log(t)}function Tc(e){return new this(e).log(2)}function Yc(e){return new this(e).log(10)}function jc(){return sc(this,arguments,-1)}function Gc(){return sc(this,arguments,1)}function Jc(e,t){return new this(e).mod(t)}function zc(e,t){return new this(e).mul(t)}function Vc(e,t){return new this(e).pow(t)}function Pc(e){var t,r,n,i,o=0,a=new this(1),s=[];if(void 0===e?e=this.precision:Xs(e,1,xs),n=Math.ceil(e/7),this.crypto)if(crypto.getRandomValues)for(t=crypto.getRandomValues(new Uint32Array(n));o<n;)(i=t[o])>=429e7?t[o]=crypto.getRandomValues(new Uint32Array(1))[0]:s[o++]=i%1e7;else{if(!crypto.randomBytes)throw Error(Hs);for(t=crypto.randomBytes(n*=4);o<n;)(i=t[o]+(t[o+1]<<8)+(t[o+2]<<16)+((127&t[o+3])<<24))>=214e7?crypto.randomBytes(4).copy(t,o):(s.push(i%1e7),o+=4);o=n/4}else for(;o<n;)s[o++]=1e7*Math.random()|0;for(e%=7,(n=s[--o])&&e&&(i=Rs(10,7-e),s[o]=(n/i|0)*i);0===s[o];o--)s.pop();if(o<0)r=0,s=[0];else{for(r=-1;0===s[0];r-=7)s.shift();for(n=1,i=s[0];i>=10;i/=10)n++;n<7&&(r-=7-n)}return a.e=r,a.d=s,a}function Xc(e){return $s(e=new this(e),e.e+1,this.rounding)}function _c(e){return(e=new this(e)).d?e.d[0]?e.s:0*e.s:e.s||NaN}function Wc(e){return new this(e).sin()}function Kc(e){return new this(e).sinh()}function $c(e){return new this(e).sqrt()}function Zc(e,t){return new this(e).sub(t)}function el(){var e=0,t=arguments,r=new this(t[e]);for(ks=!1;r.s&&++e<t.length;)r=r.plus(t[e]);return ks=!0,$s(r,this.precision,this.rounding)}function tl(e){return new this(e).tan()}function rl(e){return new this(e).tanh()}function nl(e){return $s(e=new this(e),e.e+1,1)}Vs[Symbol.for("nodejs.util.inspect.custom")]=Vs.toString,Vs[Symbol.toStringTag]="Decimal";var il=Vs.constructor=function e(t){var r,n,i;function o(e){var t,r,n,i=this;if(!(i instanceof o))return new o(e);if(i.constructor=o,Uc(e))return i.s=e.s,void(ks?!e.d||e.e>o.maxE?(i.e=NaN,i.d=null):e.e<o.minE?(i.e=0,i.d=[0]):(i.e=e.e,i.d=e.d.slice()):(i.e=e.e,i.d=e.d?e.d.slice():e.d));if("number"===(n=typeof e)){if(0===e)return i.s=1/e<0?-1:1,i.e=0,void(i.d=[0]);if(e<0?(e=-e,i.s=-1):i.s=1,e===~~e&&e<1e7){for(t=0,r=e;r>=10;r/=10)t++;return void(ks?t>o.maxE?(i.e=NaN,i.d=null):t<o.minE?(i.e=0,i.d=[0]):(i.e=t,i.d=[e]):(i.e=t,i.d=[e]))}return 0*e!=0?(e||(i.s=NaN),i.e=NaN,void(i.d=null)):fc(i,e.toString())}if("string"===n)return 45===(r=e.charCodeAt(0))?(e=e.slice(1),i.s=-1):(43===r&&(e=e.slice(1)),i.s=1),js.test(e)?fc(i,e):dc(i,e);if("bigint"===n)return e<0?(e=-e,i.s=-1):i.s=1,fc(i,e.toString());throw Error(qs+e)}if(o.prototype=Vs,o.ROUND_UP=0,o.ROUND_DOWN=1,o.ROUND_CEIL=2,o.ROUND_FLOOR=3,o.ROUND_HALF_UP=4,o.ROUND_HALF_DOWN=5,o.ROUND_HALF_EVEN=6,o.ROUND_HALF_CEIL=7,o.ROUND_HALF_FLOOR=8,o.EUCLID=9,o.config=o.set=Sc,o.clone=e,o.isDecimal=Uc,o.abs=Ic,o.acos=yc,o.acosh=vc,o.add=bc,o.asin=wc,o.asinh=Bc,o.atan=Ec,o.atanh=Cc,o.atan2=xc,o.cbrt=Dc,o.ceil=Fc,o.clamp=Qc,o.cos=kc,o.cosh=Nc,o.div=qc,o.exp=Mc,o.floor=Hc,o.hypot=Lc,o.ln=Rc,o.log=Oc,o.log10=Yc,o.log2=Tc,o.max=jc,o.min=Gc,o.mod=Jc,o.mul=zc,o.pow=Vc,o.random=Pc,o.round=Xc,o.sign=_c,o.sin=Wc,o.sinh=Kc,o.sqrt=$c,o.sub=Zc,o.sum=el,o.tan=tl,o.tanh=rl,o.trunc=nl,void 0===t&&(t={}),t&&!0!==t.defaults)for(i=["precision","rounding","toExpNeg","toExpPos","maxE","minE","modulo","crypto"],r=0;r<i.length;)t.hasOwnProperty(n=i[r++])||(t[n]=this[n]);return o.config(t),o}(Ss);function ol(e,t=0){if(Bo(t)||(t=0),t=Zi(t),!Se(e))return"";return new il(e).toDecimalPlaces(t,il.ROUND_CEIL).toNumber()}function al(e,t=0){if(!Se(e))return"";if(!Bo(t))return"";return e=Mn(e),$i(e,t).toFixed(t)}function sl(e){let t=function(){let e=yn();return n||e.xss}();let r=function e(r){return Ce(r)||Be(r)?(Er(r,function(t,n){r[n]=e(t)}),r):De(r)?t(r,{onIgnoreTagAttr:function(e,r,n,i){if("style"===r)return r+'="'+t.escapeAttrValue(n)+'"'}}):r}(zi(e));return r}function cl(e,t){let r=ns();if(!Ce(e)&&!Be(e))return r.reject("rs is not an array or object"),r;let n=!1;if(Be(e)){n=!0;let t=[];Er(e,(e,r)=>{t.push({k:r,v:e})}),e=t}va(t)||(t=function(e){return e});let i=-1,o=[];return e.reduce(function(e,r){return e.then(function(e){o.push(e),i+=1;let a=i,s=r;return n&&(a=r.k,s=r.v),va(t)?t(s,a):s})},Promise.resolve()).then(function(e){o.push(e),o=ja(o),r.resolve(o)}).catch(function(e){r.reject(e)}),r}Fs=new il(Fs),Qs=new il(Qs);let ll={},ul={};function fl({tagName:e,path:t,attributes:r={},func:n}){let i=ns();if("done"===ll[t])return i.resolve("loaded"),i;if("loading"===ll[t])return vs(()=>"done"===ll[t]).then(function(){i.resolve("loaded")}),i;ll[t]="loading";let o=document.createElement(e);return Er(r,(e,t)=>{o.setAttribute(t,e)}),r.rel&&"stylesheet"===r.rel?(o.setAttribute("href",t),setTimeout(()=>{i.resolve(o),ll[t]="done"},1)):(o.src=t,o.addEventListener("load",()=>{let e;va(n)?e=vs(n):(e=ns(),e.resolve()),e.then(()=>bs(500)).then(function(){i.resolve(o),ll[t]="done"})}),o.addEventListener("error",()=>{i.reject(o),ll[t]="done"})),document.getElementsByTagName("head")[0].appendChild(o),i}function dl(e){let t=ns();Ce(e)||(e=[e]),Er(e,(t,r)=>{xe(t)&&(e[r]={path:t})});let r=xo(xr(e,"path"),"|");return"done"===ul[r]?(t.resolve("loaded"),t):"loading"===ul[r]?(vs(()=>"done"===ul[r]).then(function(){t.resolve("loaded")}),t):(ul[r]="loading",Er(e,(e,t)=>{e.type||(".js"===fa(e.path,3)?e.type="js":".css"===fa(e.path,4)?e.type="css":e.type="unknow")}),cl(e,e=>{let t=ns();if("js"===e.type)t=fl({tagName:"script",path:e.path,attributes:{type:"text/javascript"},func:e.func});else if("css"===e.type)t=fl({tagName:"link",path:e.path,attributes:{rel:"stylesheet"}});else{let r="invalid pathItem.type: "+e.type;console.log(r),t.reject(r)}return t}).finally(()=>{ul[r]="done"}))}function gl(e){return Ie(e).toUpperCase()}function pl(e,t,r){if(!De(e))return"";if(!De(t))return"";if(!xe(r))return"";return String(e).replaceAll(t,r)}function hl(e,t,r=1){return De(e)&&Bo(t)?(r=eo(r)?Zi(r):1,e.substring(t,t+r)):""}let Al={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"};function ml(e){return yl(e,1)}function Il(e){return yl(e,360)}function yl(e,t=1){if(e.indexOf("%")>=0){if(!Se(e=pl(e,"%","")))throw new Error("invalid color: value is not a number");e=Mn(e)/100}else{if(!Se(e))throw new Error("invalid color: value is not a number");e=Mn(e)/t}if(e>1)throw new Error("invalid color: value > 1");if(e<0)throw new Error("invalid color: value < 0");return e}function vl(e){if(!Se(e))throw new Error("invalid color: value is not a number");if((e=Mn(e))>1)throw new Error("invalid color: value > 1");if(e<0)throw new Error("invalid color: value < 0");return e}function bl(e,t="rgba"){if(!Ce(e))throw new Error("invalid colors array");let r=we(e,0,0),n=we(e,1,0),i=we(e,2,0),o=we(e,3,1);if(4!==dn(t=t.split("")))throw new Error("tar.length !== 4");let a=we(t,0),s=we(t,1),c=we(t,2),l=we(t,3);return{[a]:r,[s]:n,[c]:i,[l]:o}}function wl(e){let t=(e=da(e,1)).length;if(2===t)e=`${e}${e}${e}ff`;else if(3===t){let t=hl(e,0,1),r=hl(e,1,1),n=hl(e,2,1);e=`${t}${t}${r}${r}${n}${n}ff`}else if(6===t)e=`${e}ff`;else if(8!==t)throw new Error("invalid hex color");function r(e){if(2!==e.length)throw new Error("hex.length of color is not equal to 2");if(!Se(e=parseInt(e,16)))throw new Error("invalid hex of color");return(e=Mn(e))/255}return{r:r(hl(e,0,2)),g:r(hl(e,2,2)),b:r(hl(e,4,2)),a:r(hl(e,6,2))}}function Bl(e){return e=bl(e=xr(e,(e,t)=>t<=2?yl(e,255):3===t?vl(e):null),"rgba")}function El(e){return e=Nl(e=bl(e=xr(e,(e,t)=>0===t?Il(e):1===t||2===t?ml(e):3===t?vl(e):null),"hsla"))}function Cl(e){return e=ql(e=bl(e=xr(e,(e,t)=>0===t?Il(e):1===t||2===t?ml(e):3===t?vl(e):null),"hsva"))}function xl(e){if("transparent"===e)return{r:0,g:0,b:0,a:0};if(function(e){return ke(Al,e)}(e))return wl(e=function(e){return`#${Al[e]}`}(e));if(function(e){return"#"===ua(e,1)&&(!!/[0-9A-Fa-f]{2}/g.test(e)||(!!/[0-9A-Fa-f]{3}/g.test(e)||(!!/[0-9A-Fa-f]{6}/g.test(e)||!!/[0-9A-Fa-f]{8}/g.test(e))))}(e))return wl(e);if(function(e){return"rgb"===ua(e,3)||"rgba"===ua(e,4)}(e))return function(e){return e=pl(e,"rgba",""),e=pl(e,"rgb",""),Bl(la(e=pl(e=e.replace(/[()]/g,""),","," ")," "))}(e);if(function(e){return"hsl"===ua(e,3)||"hsla"===ua(e,4)}(e))return function(e){return e=pl(e,"hsla",""),e=pl(e,"hsl",""),El(la(e=pl(e=e.replace(/[()]/g,""),","," ")," "))}(e);if(function(e){return"hsv"===ua(e,3)||"hsva"===ua(e,4)}(e))return function(e){return e=pl(e,"hsva",""),e=pl(e,"hsv",""),Cl(la(e=pl(e=e.replace(/[()]/g,""),","," ")," "))}(e);throw new Error("format of color string is not hex-color, name-color, rgba, hsla, hsva")}function Dl(e,t){return!!ke(e,t=ws(t))||!!ke(e,t=gl(t))}function Fl(e,t,r){let n;return n=we(e,t,null),null!==n?n:(n=we(e,t=gl(t),null),null!==n?n:r)}function Ql(e){if(function(e){let t=Dl(e,"r"),r=Dl(e,"g"),n=Dl(e,"b");return t&&r&&n}(e))return function(e){let t=[Fl(e,"r",null),Fl(e,"g",null),Fl(e,"b",null),Fl(e,"a",1)];return t=xr(t,Ya),Bl(t)}(e);if(function(e){let t=Dl(e,"h"),r=Dl(e,"s"),n=Dl(e,"l");return t&&r&&n}(e))return function(e){let t=[Fl(e,"h",null),Fl(e,"s",null),Fl(e,"l",null),Fl(e,"a",1)];return t=xr(t,Ya),El(t)}(e);if(function(e){let t=Dl(e,"h"),r=Dl(e,"s"),n=Dl(e,"v");return t&&r&&n}(e))return function(e){let t=[Fl(e,"h",null),Fl(e,"s",null),Fl(e,"v",null),Fl(e,"a",1)];return t=xr(t,Ya),Cl(t)}(e);throw new Error("color object is not one of rgba, hsla, hsva")}function Sl(e){let t,r,n=e.r,i=e.g,o=e.b,a=Math.max(n,i,o),s=Math.min(n,i,o),c=(a+s)/2;if(a===s)t=r=0;else{let e=a-s;switch(r=c>.5?e/(2-a-s):e/(a+s),a){case n:t=(i-o)/e+(i<o?6:0);break;case i:t=(o-n)/e+2;break;case o:t=(n-i)/e+4}t/=6}return{h:t,s:r,l:c,a:e.a}}function kl(e){let t,r,n=e.r,i=e.g,o=e.b,a=Math.max(n,i,o),s=Math.min(n,i,o),c=a,l=a-s;if(r=0===a?0:l/a,a===s)t=0;else{switch(a){case n:t=(i-o)/l+(i<o?6:0);break;case i:t=(o-n)/l+2;break;case o:t=(n-i)/l+4}t/=6}return{h:t,s:r,v:c,a:e.a}}function Nl(e){let t,r,n,i=e.h,o=e.s,a=e.l;function s(e,t,r){return r<0&&(r+=1),r>1&&(r-=1),r<1/6?e+6*(t-e)*r:r<.5?t:r<2/3?e+(t-e)*(2/3-r)*6:e}if(0===o)t=r=n=a;else{let e=a<.5?a*(1+o):a+o-a*o,c=2*a-e;t=s(c,e,i+1/3),r=s(c,e,i),n=s(c,e,i-1/3)}return{r:t,g:r,b:n,a:e.a}}function ql(e){let t,r,n,i=e.h,o=e.s,a=e.v,s=Math.floor(6*i),c=6*i-s,l=a*(1-o),u=a*(1-c*o),f=a*(1-(1-c)*o);switch(s%6){case 0:t=a,r=f,n=l;break;case 1:t=u,r=a,n=l;break;case 2:t=l,r=a,n=f;break;case 3:t=l,r=u,n=a;break;case 4:t=f,r=l,n=a;break;case 5:t=a,r=l,n=u}return{r:t,g:r,b:n,a:e.a}}function Ml(e){let t=Math.round(255*e).toString(16);if(1===t.length)return`0${t}`;if(2===t.length)return t;throw new Error("invalid value")}function Hl(e,t=!0){let r=e.r,n=e.g,i=e.b,o=e.a,a=`${Ml(r)}${Ml(n)}${Ml(i)}`;return t&&(a=`${a}${Ml(o)}`),a}function Ll(e){return Math.min(1,Math.max(0,e))}function Ul(e,t){if(!De(t))throw new Error("fmtOutput is not a string");if(!mu[t])throw console.log(`fmtOutput must be [${dt(mu)}]`),new Error("invalid fmtOutput");return e=mu[t](e)}function Rl(e,t,r="toRgbString"){if(t<0||t>1)throw new Error("amount < 0 or > 1");let n=Sl(e);return n.h+=t,n.h=n.h%1,Ul(Nl(n),r)}function Ol(e,t,r,n,i="toRgbString"){if(t<0||t>1)throw new Error("w1 < 0 or > 1");if(n<0||n>1)throw new Error("w1 < 0 or > 1");return Ul({r:e.r*t+r.r*n,g:e.g*t+r.g*n,b:e.b*t+r.b*n,a:e.a*t+r.a*n},i)}function Tl(e){return`${$i(100*e,1)}%`}function Yl(e){return $i(e,0)}function jl(e){return $i(e,3)}function Gl(e){return{r:Yl(255*e.r),g:Yl(255*e.g),b:Yl(255*e.b)}}function Jl(e){return`rgb(${Yl(255*e.r)}, ${Yl(255*e.g)}, ${Yl(255*e.b)})`}function zl(e){return{r:Yl(255*e.r),g:Yl(255*e.g),b:Yl(255*e.b),a:jl(e.a)}}function Vl(e){return`rgba(${Yl(255*e.r)}, ${Yl(255*e.g)}, ${Yl(255*e.b)}, ${jl(e.a)})`}function Pl(e){let t=Sl(e);return{h:Yl(360*t.h),s:jl(t.s),l:jl(t.l)}}function Xl(e){let t=Sl(e);return`hsl(${Yl(360*t.h)}, ${jl(t.s)}, ${jl(t.l)})`}function _l(e){let t=Sl(e);return{h:Yl(360*t.h),s:jl(t.s),l:jl(t.l),a:jl(t.a)}}function Wl(e){let t=Sl(e);return`hsla(${Yl(360*t.h)}, ${jl(t.s)}, ${jl(t.l)}, ${jl(t.a)})`}function Kl(e){let t=kl(e);return{h:Yl(360*t.h),s:jl(t.s),v:jl(t.v)}}function $l(e){let t=kl(e);return`hsv(${Yl(360*t.h)}, ${jl(t.s)}, ${jl(t.v)})`}function Zl(e){let t=kl(e);return{h:Yl(360*t.h),s:jl(t.s),v:jl(t.v),a:jl(t.a)}}function eu(e){let t=kl(e);return`hsva(${Yl(360*t.h)}, ${jl(t.s)}, ${jl(t.v)}, ${jl(t.a)})`}function tu(e){return{r:Tl(e.r),g:Tl(e.g),b:Tl(e.b)}}function ru(e){return`rgb(${Tl(e.r)}, ${Tl(e.g)}, ${Tl(e.b)})`}function nu(e){return{r:Tl(e.r),g:Tl(e.g),b:Tl(e.b),a:jl(e.a)}}function iu(e){return`rgba(${Tl(e.r)}, ${Tl(e.g)}, ${Tl(e.b)}, ${jl(e.a)})`}function ou(e){let t=Sl(e);return{h:Yl(360*t.h),s:Tl(t.s),l:Tl(t.l)}}function au(e){let t=Sl(e);return`hsl(${Yl(360*t.h)}, ${Tl(t.s)}, ${Tl(t.l)})`}function su(e){let t=Sl(e);return{h:Yl(360*t.h),s:Tl(t.s),l:Tl(t.l),a:jl(t.a)}}function cu(e){let t=Sl(e);return`hsla(${Yl(360*t.h)}, ${Tl(t.s)}, ${Tl(t.l)}, ${jl(t.a)})`}function lu(e){let t=kl(e);return{h:Yl(360*t.h),s:Tl(t.s),v:Tl(t.v)}}function uu(e){let t=kl(e);return`hsv(${Yl(360*t.h)}, ${Tl(t.s)}, ${Tl(t.v)})`}function fu(e){let t=kl(e);return{h:Yl(360*t.h),s:Tl(t.s),v:Tl(t.v),a:jl(t.a)}}function du(e){let t=kl(e);return`hsva(${Yl(360*t.h)}, ${Tl(t.s)}, ${Tl(t.v)}, ${jl(t.a)})`}function gu(e){let t=function(e){return Hl(e,!1)}(e);return`#${t}`}function pu(e){return`#${Hl(e)}`}function hu(e){let t=null,r=null,n=null;if(De(e))t=ws(sa(e));else{if(!Ee(e))throw console.log("color=",e),new Error("color is not a string or an object");r=e}if(null!==t)try{n=xl(t)}catch(e){throw console.log(e),new Error(`can not parse color: ${t}`)}else if(null!==r)try{n=Ql(r)}catch(e){throw console.log(e),new Error(`can not parse color: ${JSON.stringify(r)}`)}return n}function Au(e){if(!Ee(e))return console.log("gradient is not an effective object"),e=>`rgb(${255*(e=Math.min(Math.max(e,0),1))},${255*e},${255*e})`;let t=[];return Er(e,(e,r)=>{t.push([Mn(r),zl(hu(e)),e])}),t=Oa(t,0),function(e){let r=null;for(let n=1;n<t.length;n++){let i=t[n-1][0],o=t[n-1][1],a=t[n][0],s=t[n][1];if(i<=e&&a>=e){let t=(a-e)/(a-i),n=(e-i)/(a-i);r=Ol(hu(o),t,hu(s),n,"toRgbaString");break}}return r}}let mu={toRgb:Gl,toRgbString:Jl,toRgba:zl,toRgbaString:Vl,toHsl:Pl,toHslString:Xl,toHsla:_l,toHslaString:Wl,toHsv:Kl,toHsvString:$l,toHsva:Zl,toHsvaString:eu,toRgbP:tu,toRgbPString:ru,toRgbaP:nu,toRgbaPString:iu,toHslP:ou,toHslPString:au,toHslaP:su,toHslaPString:cu,toHsvP:lu,toHsvPString:uu,toHsvaP:fu,toHsvaPString:du,toHexString:gu,toHex8String:pu};var Iu={toRgb:e=>Gl(hu(e)),toRgbString:e=>Jl(hu(e)),toRgba:e=>zl(hu(e)),toRgbaString:e=>Vl(hu(e)),toHsl:e=>Pl(hu(e)),toHslString:e=>Xl(hu(e)),toHsla:e=>_l(hu(e)),toHslaString:e=>Wl(hu(e)),toHsv:e=>Kl(hu(e)),toHsvString:e=>$l(hu(e)),toHsva:e=>Zl(hu(e)),toHsvaString:e=>eu(hu(e)),toRgbP:e=>tu(hu(e)),toRgbPString:e=>ru(hu(e)),toRgbaP:e=>nu(hu(e)),toRgbaPString:e=>iu(hu(e)),toHslP:e=>ou(hu(e)),toHslPString:e=>au(hu(e)),toHslaP:e=>su(hu(e)),toHslaPString:e=>cu(hu(e)),toHsvP:e=>lu(hu(e)),toHsvPString:e=>uu(hu(e)),toHsvaP:e=>fu(hu(e)),toHsvaPString:e=>du(hu(e)),toHexString:e=>gu(hu(e)),toHex8String:e=>pu(hu(e)),modSaturate:(e,t,r)=>function(e,t,r="toRgbString"){if(t<0||t>1)throw new Error("amount < 0 or > 1");let n=Sl(e);return n.s+=t,n.s=Ll(n.s),Ul(Nl(n),r)}(hu(e),t,r),modGrey:(e,t)=>function(e,t="toRgbString"){let r=Sl(e);return r.s=0,Ul(Nl(r),t)}(hu(e),t),modLighten:(e,t,r)=>function(e,t,r="toRgbString"){if(t<0||t>1)throw new Error("amount < 0 or > 1");let n=Sl(e);return n.l+=t,n.l=Ll(n.l),Ul(Nl(n),r)}(hu(e),t,r),modBrighten:(e,t,r)=>function(e,t,r="toRgbString"){if(t<0||t>1)throw new Error("amount < 0 or > 1");return e.r+=t,e.r=Ll(e.r),e.g+=t,e.g=Ll(e.g),e.b+=t,e.b=Ll(e.b),Ul(e,r)}(hu(e),t,r),modHue:(e,t,r)=>Rl(hu(e),t,r),modComplement:(e,t)=>function(e,t="toRgbString"){return Rl(e,.5,t)}(hu(e),t),spreadHue:(e,t,r)=>function(e,t,r="toRgbString"){if(!Hn(t))throw new Error("num is not an integer");if((t=Zi(t))<=1)return[e];let n=Sl(e),i=1/t,o=[];for(let e=0;e<t;e++)o.push(Ul(Nl(n),r)),n.h+=i,n.h=n.h%1;return o}(hu(e),t,r),spreadMonochromatic:(e,t,r)=>function(e,t,r="toRgbString"){if(!Hn(t))throw new Error("num is not an integer");if((t=Zi(t))<=1)return[e];let n=kl(e);n.s=1,n.l=1;let i=1/t,o=[];for(let e=0;e<t;e++)o.push(Ul(ql(n),r)),n.h-=i,n.l-=i;return o}(hu(e),t,r),mix:(e,t,r,n,i)=>Ol(hu(e),t,hu(r),n,i),getBrightness:e=>function(e){if(1!==e.a)throw new Error("alpha of color can not be equal to 1");return(299*e.r+587*e.g+114*e.b)/1e3}(hu(e)),getLuminance:e=>function(e){if(1!==e.a)throw new Error("alpha of color can not be equal to 1");let t,r,n,i=e.r,o=e.g,a=e.b;return t=i<=.03928?i/12.92:Math.pow((i+.055)/1.055,2.4),r=o<=.03928?o/12.92:Math.pow((o+.055)/1.055,2.4),n=a<=.03928?a/12.92:Math.pow((a+.055)/1.055,2.4),.2126*t+.7152*r+.0722*n}(hu(e)),interp:Au};function yu(e,t,r){return null==e?e:function(e,t,r,n){if(!U(e))return e;for(var i=-1,o=(t=ye(t,e)).length,a=o-1,s=e;null!=s&&++i<o;){var c=ve(t[i]),l=r;if("__proto__"===c||"constructor"===c||"prototype"===c)return e;if(i!=a){var u=s[c];void 0===(l=n?n(u,c,s):void 0)&&(l=U(u)?u:Pe(t[i+1])?[]:{})}pi(s,c,l),s=s[c]}return e}(e,t,r)}function vu(e){return vr(e)?void 0:e}var bu=bo(function(e,t){var r={};if(null==e)return r;var n=!1;t=pe(t,function(t){return t=ye(t,e),n||(n=t.length>1),t}),hi(e,Ci(e),r),n&&(r=Ji(r,7,vu));for(var i=t.length;i--;)ka(r,t[i]);return r}),wu=bu;function Bu(e,t={}){let r="$level",n="$parents";if(!Rr(e))return[];let i=we(t,"bindKey",null);De(i)||(i="id");let o=we(t,"bindParent",null);De(o)||(o="parentId");let a=we(t,"bindChildren",null);De(a)||(a="children");let s=we(t,"saveExtProps",null);pn(s)||(s=!1),e=function(e){let t=[];function a(a){let s=[];Er(e,(e,c)=>{let l=we(e,o),u=we(a,i);if(l&&u&&l===u){let o=we(a,n,[]);o=zi(o),o.push(a[i]),t.push({[r]:a[r]+1,[n]:o,...e})}else s.push(e)}),e=s}if(e=zi(e),function(){let i=[];Er(e,(e,a)=>{Ur(e[o])?t.push({[r]:0,[n]:[],...e}):i.push(e)}),e=i}(),0===t.length)return t;let s=-1;for(;s+=1,!(s>t.length-1);){if(a(t[s]),0===e.length)break}return t}(e);let c=function(e){let t=[];function c(e){return s?e:wu(e,[r,n])}let l={};return Er(e,(n,s)=>{if(0===n[r]){let e=c(n);t.push(e),l[n[i]]=[s]}else{let r=function(t){for(let r=0;r<e.length;r++){let n=e[r];if(t[o]===n[i])return n}return null}(n);if(null!==r){let e=l[r[i]];e=[...e,a];let o=we(t,e,[]),s=c(n);o.push(s),l[n[i]]=[...e,o.length-1],yu(t,e,o)}else console.log(`can not find parent for ${we(n,o)}`)}}),t}(e);return c}function Eu(e,t=null,r={}){R(t)||(t=e=>e);let n=we(r,"force",!1);return pn(n)||(n=!1),function(e,t,r=!1){let n=[];if(!Ce(e)&&!Be(e))return t(e,null,[]);function i(e){if(Ce(e))return ao(dn(e));if(Be(e)){let t=Object.getOwnPropertyNames(e),n=null;return r&&(n=Object.getOwnPropertySymbols(e)),Ce(t)||(t=[]),Ce(n)||(n=[]),[...t,...n]}return e}return function e(r,o){if(Ce(r))return i(r).map(i=>{let o=r[i],a=zi(n);return n.push(i),o=t(o,i,a),o=e(o),n.pop(),o});if(Be(r)){let o=i(r),a={};return o.map(i=>{let o=r[i],s=zi(n);n.push(i),o=t(o,i,s),o=e(o),n.pop(),a[i]=o}),a}return r}(e)}(e,t,n)}function Cu(e,t={}){if(!Ee(e)&&!Rr(e))return[];let r=we(t,"bindKey",null);De(r)||(r="id");let n=we(t,"bindParent",null);De(n)||(n="parentId");let i=we(t,"bindBelong",null);De(i)||(i="key");let o=we(t,"bindText",null);De(o)||(o="text");let a=we(t,"bindType",null);De(a)||(a="type");let s=we(t,"bindNumOfChilren",null);function c(e,t){return e=xr(e=zi(e),e=>q(e)?Ya(e):e),q(t)&&(t=Ya(t)),(De(t)||Se(t))&&e.push(t),xo(e,"-")}De(s)||(s="numOfChilren");let l=[];return Eu(e,(e,t,u)=>{let f=c(u,t),d=c(u,null),g="node";Be(e)?g="object":Ce(e)&&(g="array");let p={[r]:f,[n]:d,[a]:g};if((De(t)||Ia(t))&&(p[i]=t),Be(e)||Ce(e)||(p[o]=e),Be(e)||Ce(e)){let t=null;Be(e)?t=dn(dt(e)):Ce(e)&&(t=dn(e)),p[s]=t}return l.push(p),e},{force:!0}),l}function xu(e){if(!br(e))return"invalid element";let t=!1;try{t=document.activeElement===e}catch(e){console.log(e)}return t}function Du(e){return Se(e)?(e=Mn(e),Math.cos(e*Math.PI/180)):null}function Fu(e){return Se(e)?(e=Mn(e),Math.tan(e*Math.PI/180)):null}function Qu(){let e=new function e(){if(!(this instanceof e))return new e;this.SheetNames=[],this.Sheets={}};return e}function Su(e){return Se(e)?(e=Mn(e),Math.sin(e*Math.PI/180)):null}function ku(e){if(!De(e))return!1;let t="YYYY-MM-DD";return e===r(e,t).format(t)}function Nu(e=300){return new function(e){let t=[],r=null,n=Date.now();return eo(e)||(e=300),e=Zi(e),function(i,...o){va(i)?(n=Date.now(),t.push({func:i,input:o}),null===r&&(r=setInterval(()=>{if(0===dn(t))return clearInterval(r),void(r=null);if(Date.now()-n>e){let e=t.pop();t=[];try{e.func(...e.input)}catch(e){console.log("m.func catch",e)}}},10))):console.log("func is not a function")}}(e)}let qu="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz".split(""),Mu=qu.length;function Hu(e=32){let t=[];e=eo(e)?Zi(e):32;for(let r=0;r<e;r++)t[r]=qu[0|Math.random()*Mu];return t.join("")}function Lu(e,t={}){if(!br(e))return;let r=we(t,"duration",500);r=Mn(r),r<0&&(r=1e3);let n=we(t,"delay",0);n=Mn(n),n<0&&(n=0);let i=we(t,"opacityIni",0);i=Mn(i),i=Math.min(Math.max(i,0),1),Se(e.style.opacity)&&(i=Mn(e.style.opacity));let o=10/r,a=`tag-${Hu()}`;e.setAttribute("dom-fade-tag",a),setTimeout(()=>{let t=setInterval(()=>{try{e.getAttribute("dom-fade-tag")!==a&&clearInterval(t),e.style.opacity=i,i>=1&&(clearInterval(t),e.removeAttribute("dom-fade-tag")),i+=o,i>1&&(i=1)}catch(e){console.log(e),clearInterval(t)}},10)},n)}function Uu(e,t={}){if(!br(e))return;let r=we(t,"duration",500);r=Mn(r),r<0&&(r=1e3);let n=we(t,"delay",0);n=Mn(n),n<0&&(n=0);let i=we(t,"opacityIni",1);i=Mn(i),i=Math.min(Math.max(i,0),1),Se(e.style.opacity)&&(i=Mn(e.style.opacity));let o=10/r,a=`tag-${Hu()}`;e.setAttribute("dom-fade-tag",a),setTimeout(()=>{let t=setInterval(()=>{try{e.getAttribute("dom-fade-tag")!==a&&clearInterval(t),e.style.opacity=i,i<=0&&(clearInterval(t),e.removeAttribute("dom-fade-tag")),i-=o,i<0&&(i=0)}catch(e){console.log(e),clearInterval(t)}},10)},n)}let Ru='<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" x="0px" y="0px" viewBox="0 0 512.001 512.001" style="width:12px; height:12px; enable-background:new 0 0 512.001 512.001;" xml:space="preserve"><g><g><path d="M284.286,256.002L506.143,34.144c7.811-7.811,7.811-20.475,0-28.285c-7.811-7.81-20.475-7.811-28.285,0L256,227.717L34.143,5.859c-7.811-7.811-20.475-7.811-28.285,0c-7.81,7.811-7.811,20.475,0,28.285l221.857,221.857L5.858,477.859c-7.811,7.811-7.811,20.475,0,28.285c3.905,3.905,9.024,5.857,14.143,5.857c5.119,0,10.237-1.952,14.143-5.857L256,284.287l221.857,221.857c3.905,3.905,9.024,5.857,14.143,5.857s10.237-1.952,14.143-5.857c7.811-7.811,7.811-20.475,0-28.285L284.286,256.002z"/></g></g></svg>',Ou={success:'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" x="0px" y="0px" viewBox="0 0 426.667 426.667" style="width:24px; height:24px; enable-background:new 0 0 426.667 426.667" xml:space="preserve"><path style="fill:#6ac259" d="M213.333,0C95.518,0,0,95.514,0,213.333s95.518,213.333,213.333,213.333 c117.828,0,213.333-95.514,213.333-213.333S331.157,0,213.333,0z M174.199,322.918l-93.935-93.931l31.309-31.309l62.626,62.622 l140.894-140.898l31.309,31.309L174.199,322.918z"/></svg>',error:'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" x="0px" y="0px" viewBox="0 0 496.158 496.158" style="width:24px; height:24px; enable-background:new 0 0 496.158 496.158" xml:space="preserve"><path style="fill:#e04f5f" d="M496.158,248.085c0-137.021-111.07-248.082-248.076-248.082C111.07,0.003,0,111.063,0,248.085 c0,137.002,111.07,248.07,248.082,248.07C385.088,496.155,496.158,385.087,496.158,248.085z"/><path style="fill:#fff" d="M277.042,248.082l72.528-84.196c7.91-9.182,6.876-23.041-2.31-30.951 c-9.172-7.904-23.032-6.876-30.947,2.306l-68.236,79.212l-68.229-79.212c-7.91-9.188-21.771-10.216-30.954-2.306 c-9.186,7.91-10.214,21.77-2.304,30.951l72.522,84.196l-72.522,84.192c-7.91,9.182-6.882,23.041,2.304,30.951 c4.143,3.569,9.241,5.318,14.316,5.318c6.161,0,12.294-2.586,16.638-7.624l68.229-79.212l68.236,79.212 c4.338,5.041,10.47,7.624,16.637,7.624c5.069,0,10.168-1.749,14.311-5.318c9.186-7.91,10.22-21.77,2.31-30.951L277.042,248.082z"/></svg>',warning:'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" x="0px" y="0px" viewBox="0 0 497.472 497.472" style="width:24px; height:24px; enable-background:new 0 0 497.472 497.472" xml:space="preserve"><g transform="matrix(1.25 0 0 -1.25 0 45)"><path style="fill:#ffcc4d" d="M24.374-357.857c-20.958,0-30.197,15.223-20.548,33.826L181.421,17.928 c9.648,18.603,25.463,18.603,35.123,0L394.14-324.031c9.671-18.603,0.421-33.826-20.548-33.826H24.374z"/><path style="fill:#231f20" d="M173.605-80.922c0,14.814,10.934,23.984,25.395,23.984c14.12,0,25.407-9.512,25.407-23.984 V-216.75c0-14.461-11.287-23.984-25.407-23.984c-14.461,0-25.395,9.182-25.395,23.984V-80.922z M171.489-289.056 c0,15.167,12.345,27.511,27.511,27.511c15.167,0,27.523-12.345,27.523-27.511c0-15.178-12.356-27.523-27.523-27.523 C183.834-316.579,171.489-304.234,171.489-289.056"/></g></svg>',infor:'<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" version="1.1" x="0px" y="0px" viewBox="0 0 496.16 496.16" style="width:24px; height:24px; enable-background:new 0 0 496.158 496.158;" xml:space="preserve"><path d="m496.16 248.08c0-137.02-111.07-248.08-248.08-248.08-137.01 0-248.08 111.06-248.08 248.08 0 137 111.07 248.07 248.08 248.07 137.01 0 248.08-111.07 248.08-248.07z" fill="#25B7D3"/><g fill="#fff"><path d="m315.25 359.56c-1.387-2.032-4.048-2.755-6.27-1.702-24.582 11.637-52.482 23.94-57.958 25.015-0.138-0.123-0.357-0.348-0.644-0.737-0.742-1.005-1.103-2.318-1.103-4.015 0-13.905 10.495-56.205 31.192-125.72 17.451-58.406 19.469-70.499 19.469-74.514 0-6.198-2.373-11.435-6.865-15.146-4.267-3.519-10.229-5.302-17.719-5.302-12.459 0-26.899 4.73-44.146 14.461-16.713 9.433-35.352 25.41-55.396 47.487-1.569 1.729-1.733 4.314-0.395 6.228 1.34 1.915 3.825 2.644 5.986 1.764 7.037-2.872 42.402-17.359 47.557-20.597 4.221-2.646 7.875-3.989 10.861-3.989 0.107 0 0.199 4e-3 0.276 0.01 0.036 0.198 0.07 0.5 0.07 0.933 0 3.047-0.627 6.654-1.856 10.703-30.136 97.641-44.785 157.5-44.785 182.99 0 8.998 2.501 16.242 7.432 21.528 5.025 5.393 11.803 8.127 20.146 8.127 8.891 0 19.712-3.714 33.08-11.354 12.936-7.392 32.68-23.653 60.363-49.717 1.793-1.687 2.092-4.426 0.705-6.458z"/><path d="m314.28 76.672c-4.925-5.041-11.227-7.597-18.729-7.597-9.34 0-17.475 3.691-24.176 10.971-6.594 7.16-9.938 15.946-9.938 26.113 0 8.033 2.463 14.69 7.32 19.785 4.922 5.172 11.139 7.794 18.476 7.794 8.958 0 17.049-3.898 24.047-11.586 6.876-7.553 10.363-16.433 10.363-26.393 1e-3 -7.654-2.476-14.075-7.363-19.087z"/></g></svg>',cancel:Ru},Tu={},Yu=null,ju=yn();function Gu(){Er(["top-right","top-left","bottom-right","bottom-left"],e=>{!function(e){let t=pa(Tu,{position:e});t=Oa(t,"timeStart");let r=16;Er(t,e=>{Tu[e.id].ele||(Tu[e.id].ele=document.querySelector(`#${e.id}`)),Tu[e.id].loc.top=r,Tu[e.id].loc.height=Tu[e.id].ele.offsetHeight,r+=Tu[e.id].loc.height+16}),Er(t,t=>{e.indexOf("bottom-")>=0?(Tu[t.id].ele.style.bottom=`${Tu[t.id].loc.top}px`,Tu[t.id].loc.bottom=Tu[t.id].loc.top):Tu[t.id].ele.style.top=`${Tu[t.id].loc.top}px`,e.indexOf("-left")>=0?(Tu[t.id].ele.style.left="16px",Tu[t.id].loc.left=16):(Tu[t.id].ele.style.right="16px",Tu[t.id].loc.right=16),Tu[t.id].ele.style.zIndex=2e5,Tu[t.id].ele.style.opacity=1,Tu[t.id].ele.style.transform="",Tu[t.id].ele.style.transform=null})}(e)})}function Ju(e){Tu[e].ele&&Tu[e].ele.parentNode.removeChild(Tu[e].ele),Tu[e]&&delete Tu[e],Gu()}function zu(e,t){if(!br(e))return"invalid eleParent";if(xe(t))e.insertAdjacentHTML("beforeend",t);else{if(!br(t))return"invalid itemChild";e.appendChild(t)}}function Vu(){return null!==navigator.userAgent.toLowerCase().match(/rv:([\d.]+)\) like gecko/)}function Pu(e){if(!e)return"invalid event";if(!e.cancelable)return"event is not cancelable";try{Vu()?e.cancelBubble=!0:e.stopPropagation(),e.preventDefault()}catch(e){}}var Xu;ju.ttWAlertCancel=function(e){Ju(e)},ju.ttWAlertFadeIn=function(e){Lu(document.querySelector(`#${e}`))},ju.ttWAlertFadeOut=function(e){Uu(document.querySelector(`#${e}`))},function(e){e.INSERT="insert",e.DELETE="delete",e.CONTEXT="context"}(Xu||(Xu={}));var _u;!function(e){e.AUTO="auto",e.DARK="dark",e.LIGHT="light"}(_u||(_u={}));const Wu=RegExp("["+["-","[","]","/","{","}","(",")","*","+","?",".","\\","^","$","|"].join("\\")+"]","g");function Ku(e){return e?e.replace(/\\/g,"/"):e}function $u(e){const t=e.length;let r=-1/0;for(let n=0;n<t;n++)r=Math.max(r,e[n]);return r}function Zu(e,t){const r=e.split(".");return r.length>1?r[r.length-1]:t}function ef(e,t){return t.reduce((t,r)=>t||e.startsWith(r),!1)}const tf=["a/","b/","i/","w/","c/","o/"];function rf(e,t,r){const n=void 0!==r?[...tf,r]:tf,i=t?new RegExp(`^${o=t,o.replace(Wu,"\\$&")} "?(.+?)"?$`):new RegExp('^"?(.+?)"?$');var o;const[,a=""]=i.exec(e)||[],s=n.find(e=>0===a.indexOf(e));return(s?a.slice(s.length):a).replace(/\s+\d{4}-\d{2}-\d{2} \d{2}:\d{2}:\d{2}(?:\.\d+)? [+-]\d{4}.*$/,"")}function nf(e,t={}){const r=[];let n=null,i=null,o=null,a=null,s=null,c=null,l=null;const u="--- ",f="+++ ",d="@@",g=/^old mode (\d{6})/,p=/^new mode (\d{6})/,h=/^deleted file mode (\d{6})/,A=/^new file mode (\d{6})/,m=/^copy from "?(.+)"?/,I=/^copy to "?(.+)"?/,y=/^rename from "?(.+)"?/,v=/^rename to "?(.+)"?/,b=/^similarity index (\d+)%/,w=/^dissimilarity index (\d+)%/,B=/^index ([\da-z]+)\.\.([\da-z]+)\s*(\d{6})?/,E=/^Binary files (.*) and (.*) differ/,C=/^GIT binary patch/,x=/^index ([\da-z]+),([\da-z]+)\.\.([\da-z]+)/,D=/^mode (\d{6}),(\d{6})\.\.(\d{6})/,F=/^new file mode (\d{6})/,Q=/^deleted file mode (\d{6}),(\d{6})/,S=e.replace(/\/g,"").replace(/\r\n?/g,"\n").split("\n");function k(){null!==i&&null!==n&&(n.blocks.push(i),i=null)}function N(){null!==n&&(n.oldName||null===c||(n.oldName=c),n.newName||null===l||(n.newName=l),n.newName&&(r.push(n),n=null)),c=null,l=null}function q(){k(),N(),n={blocks:[],deletedLines:0,addedLines:0}}function M(e){let t;k(),null!==n&&((t=/^@@ -(\d+)(?:,\d+)? \+(\d+)(?:,\d+)? @@.*/.exec(e))?(n.isCombined=!1,o=parseInt(t[1],10),s=parseInt(t[2],10)):(t=/^@@@ -(\d+)(?:,\d+)? -(\d+)(?:,\d+)? \+(\d+)(?:,\d+)? @@@.*/.exec(e))?(n.isCombined=!0,o=parseInt(t[1],10),a=parseInt(t[2],10),s=parseInt(t[3],10)):(e.startsWith(d)&&console.error("Failed to parse lines, starting in 0!"),o=0,s=0,n.isCombined=!1)),i={lines:[],oldStartLine:o,oldStartLine2:a,newStartLine:s,header:e}}return S.forEach((e,a)=>{if(!e||e.startsWith("*"))return;let k;const N=S[a-1],H=S[a+1],L=S[a+2];if(e.startsWith("diff --git")||e.startsWith("diff --combined")){q();if((k=/^diff --git "?([a-ciow]\/.+)"? "?([a-ciow]\/.+)"?/.exec(e))&&(c=rf(k[1],void 0,t.dstPrefix),l=rf(k[2],void 0,t.srcPrefix)),null===n)throw new Error("Where is my file !!!");return void(n.isGitDiff=!0)}if(e.startsWith("Binary files")&&!(null==n?void 0:n.isGitDiff)){q();if((k=/^Binary files "?([a-ciow]\/.+)"? and "?([a-ciow]\/.+)"? differ/.exec(e))&&(c=rf(k[1],void 0,t.dstPrefix),l=rf(k[2],void 0,t.srcPrefix)),null===n)throw new Error("Where is my file !!!");return void(n.isBinary=!0)}if((!n||!n.isGitDiff&&n&&e.startsWith(u)&&H.startsWith(f)&&L.startsWith(d))&&q(),null==n?void 0:n.isTooBig)return;if(n&&("number"==typeof t.diffMaxChanges&&n.addedLines+n.deletedLines>t.diffMaxChanges||"number"==typeof t.diffMaxLineLength&&e.length>t.diffMaxLineLength)){n.isTooBig=!0,n.addedLines=0,n.deletedLines=0,n.blocks=[],i=null;return void M("function"==typeof t.diffTooBigMessage?t.diffTooBigMessage(r.length):"Diff too big to be displayed")}if(e.startsWith(u)&&H.startsWith(f)||e.startsWith(f)&&N.startsWith(u)){if(n&&!n.oldName&&e.startsWith("--- ")&&(k=function(e,t){return rf(e,"---",t)}(e,t.srcPrefix)))return n.oldName=k,void(n.language=Zu(n.oldName,n.language));if(n&&!n.newName&&e.startsWith("+++ ")&&(k=function(e,t){return rf(e,"+++",t)}(e,t.dstPrefix)))return n.newName=k,void(n.language=Zu(n.newName,n.language))}if(n&&(e.startsWith(d)||n.isGitDiff&&n.oldName&&n.newName&&!i))return void M(e);if(i&&(e.startsWith("+")||e.startsWith("-")||e.startsWith(" ")))return void function(e){if(null===n||null===i||null===o||null===s)return;const t={content:e},r=n.isCombined?["+ "," +","++"]:["+"],a=n.isCombined?["- "," -","--"]:["-"];ef(e,r)?(n.addedLines++,t.type=Xu.INSERT,t.oldNumber=void 0,t.newNumber=s++):ef(e,a)?(n.deletedLines++,t.type=Xu.DELETE,t.oldNumber=o++,t.newNumber=void 0):(t.type=Xu.CONTEXT,t.oldNumber=o++,t.newNumber=s++),i.lines.push(t)}(e);const U=!function(e,t){let r=t;for(;r<S.length-3;){if(e.startsWith("diff"))return!1;if(S[r].startsWith(u)&&S[r+1].startsWith(f)&&S[r+2].startsWith(d))return!0;r++}return!1}(e,a);if(null===n)throw new Error("Where is my file !!!");(k=g.exec(e))?n.oldMode=k[1]:(k=p.exec(e))?n.newMode=k[1]:(k=h.exec(e))?(n.deletedFileMode=k[1],n.isDeleted=!0):(k=A.exec(e))?(n.newFileMode=k[1],n.isNew=!0):(k=m.exec(e))?(U&&(n.oldName=k[1]),n.isCopy=!0):(k=I.exec(e))?(U&&(n.newName=k[1]),n.isCopy=!0):(k=y.exec(e))?(U&&(n.oldName=k[1]),n.isRename=!0):(k=v.exec(e))?(U&&(n.newName=k[1]),n.isRename=!0):(k=E.exec(e))?(n.isBinary=!0,n.oldName=rf(k[1],void 0,t.srcPrefix),n.newName=rf(k[2],void 0,t.dstPrefix),M("Binary file")):C.test(e)?(n.isBinary=!0,M(e)):(k=b.exec(e))?n.unchangedPercentage=parseInt(k[1],10):(k=w.exec(e))?n.changedPercentage=parseInt(k[1],10):(k=B.exec(e))?(n.checksumBefore=k[1],n.checksumAfter=k[2],k[3]&&(n.mode=k[3])):(k=x.exec(e))?(n.checksumBefore=[k[2],k[3]],n.checksumAfter=k[1]):(k=D.exec(e))?(n.oldMode=[k[2],k[3]],n.newMode=k[1]):(k=F.exec(e))?(n.newFileMode=k[1],n.isNew=!0):(k=Q.exec(e))&&(n.deletedFileMode=k[1],n.isDeleted=!0)}),k(),N(),r}class of{diff(e,t,r={}){let n;"function"==typeof r?(n=r,r={}):"callback"in r&&(n=r.callback);const i=this.castInput(e,r),o=this.castInput(t,r),a=this.removeEmpty(this.tokenize(i,r)),s=this.removeEmpty(this.tokenize(o,r));return this.diffWithOptionsObj(a,s,r,n)}diffWithOptionsObj(e,t,r,n){var i;const o=e=>(e=this.postProcess(e,r),n?void setTimeout(function(){n(e)},0):e),a=t.length,s=e.length;let c=1,l=a+s;null!=r.maxEditLength&&(l=Math.min(l,r.maxEditLength));const u=null!==(i=r.timeout)&&void 0!==i?i:1/0,f=Date.now()+u,d=[{oldPos:-1,lastComponent:void 0}];let g=this.extractCommon(d[0],t,e,0,r);if(d[0].oldPos+1>=s&&g+1>=a)return o(this.buildValues(d[0].lastComponent,t,e));let p=-1/0,h=1/0;const A=()=>{for(let n=Math.max(p,-c);n<=Math.min(h,c);n+=2){let i;const c=d[n-1],l=d[n+1];c&&(d[n-1]=void 0);let u=!1;if(l){const e=l.oldPos-n;u=l&&0<=e&&e<a}const f=c&&c.oldPos+1<s;if(u||f){if(i=!f||u&&c.oldPos<l.oldPos?this.addToPath(l,!0,!1,0,r):this.addToPath(c,!1,!0,1,r),g=this.extractCommon(i,t,e,n,r),i.oldPos+1>=s&&g+1>=a)return o(this.buildValues(i.lastComponent,t,e))||!0;d[n]=i,i.oldPos+1>=s&&(h=Math.min(h,n-1)),g+1>=a&&(p=Math.max(p,n+1))}else d[n]=void 0}c++};if(n)!function e(){setTimeout(function(){if(c>l||Date.now()>f)return n(void 0);A()||e()},0)}();else for(;c<=l&&Date.now()<=f;){const e=A();if(e)return e}}addToPath(e,t,r,n,i){const o=e.lastComponent;return o&&!i.oneChangePerToken&&o.added===t&&o.removed===r?{oldPos:e.oldPos+n,lastComponent:{count:o.count+1,added:t,removed:r,previousComponent:o.previousComponent}}:{oldPos:e.oldPos+n,lastComponent:{count:1,added:t,removed:r,previousComponent:o}}}extractCommon(e,t,r,n,i){const o=t.length,a=r.length;let s=e.oldPos,c=s-n,l=0;for(;c+1<o&&s+1<a&&this.equals(r[s+1],t[c+1],i);)c++,s++,l++,i.oneChangePerToken&&(e.lastComponent={count:1,previousComponent:e.lastComponent,added:!1,removed:!1});return l&&!i.oneChangePerToken&&(e.lastComponent={count:l,previousComponent:e.lastComponent,added:!1,removed:!1}),e.oldPos=s,c}equals(e,t,r){return r.comparator?r.comparator(e,t):e===t||!!r.ignoreCase&&e.toLowerCase()===t.toLowerCase()}removeEmpty(e){const t=[];for(let r=0;r<e.length;r++)e[r]&&t.push(e[r]);return t}castInput(e,t){return e}tokenize(e,t){return Array.from(e)}join(e){return e.join("")}postProcess(e,t){return e}get useLongestToken(){return!1}buildValues(e,t,r){const n=[];let i;for(;e;)n.push(e),i=e.previousComponent,delete e.previousComponent,e=i;n.reverse();const o=n.length;let a=0,s=0,c=0;for(;a<o;a++){const e=n[a];if(e.removed)e.value=this.join(r.slice(c,c+e.count)),c+=e.count;else{if(!e.added&&this.useLongestToken){let n=t.slice(s,s+e.count);n=n.map(function(e,t){const n=r[c+t];return n.length>e.length?n:e}),e.value=this.join(n)}else e.value=this.join(t.slice(s,s+e.count));s+=e.count,e.added||(c+=e.count)}}return n}}const af=new class extends of{};const sf="a-zA-Z0-9_\\u{AD}\\u{C0}-\\u{D6}\\u{D8}-\\u{F6}\\u{F8}-\\u{2C6}\\u{2C8}-\\u{2D7}\\u{2DE}-\\u{2FF}\\u{1E00}-\\u{1EFF}";const cf=new class extends of{tokenize(e){const t=new RegExp(`(\\r?\\n)|[${sf}]+|[^\\S\\n\\r]+|[^${sf}]`,"ug");return e.match(t)||[]}};function lf(e){return(t,r)=>{const n=e(t).trim(),i=e(r).trim();return function(e,t){if(0===e.length)return t.length;if(0===t.length)return e.length;const r=[];let n,i;for(n=0;n<=t.length;n++)r[n]=[n];for(i=0;i<=e.length;i++)r[0][i]=i;for(n=1;n<=t.length;n++)for(i=1;i<=e.length;i++)t.charAt(n-1)===e.charAt(i-1)?r[n][i]=r[n-1][i-1]:r[n][i]=Math.min(r[n-1][i-1]+1,Math.min(r[n][i-1]+1,r[n-1][i]+1));return r[t.length][e.length]}(n,i)/(n.length+i.length)}}function uf(e){return function t(r,n,i=0,o=new Map){const a=function(t,r,n=new Map){let i,o=1/0;for(let a=0;a<t.length;++a)for(let s=0;s<r.length;++s){const c=JSON.stringify([t[a],r[s]]);let l;n.has(c)&&(l=n.get(c))||(l=e(t[a],r[s]),n.set(c,l)),l<o&&(o=l,i={indexA:a,indexB:s,score:o})}return i}(r,n,o);if(!a||r.length+n.length<3)return[[r,n]];const s=r.slice(0,a.indexA),c=n.slice(0,a.indexB),l=[r[a.indexA]],u=[n[a.indexB]],f=a.indexA+1,d=a.indexB+1,g=r.slice(f),p=n.slice(d),h=t(s,c,i+1,o),A=t(l,u,i+1,o),m=t(g,p,i+1,o);let I=A;return(a.indexA>0||a.indexB>0)&&(I=h.concat(I)),(r.length>f||n.length>d)&&(I=I.concat(m)),I}}const ff={INSERTS:"d2h-ins",DELETES:"d2h-del",CONTEXT:"d2h-cntx",INFO:"d2h-info",INSERT_CHANGES:"d2h-ins d2h-change",DELETE_CHANGES:"d2h-del d2h-change"},df={matching:"none",matchWordsThreshold:.25,maxLineLengthHighlight:1e4,diffStyle:"word",colorScheme:_u.LIGHT},gf="/",pf=lf(e=>e.value),hf=uf(pf);function Af(e){return-1!==e.indexOf("dev/null")}function mf(e){return e.replace(/(<del[^>]*>((.|\n)*?)<\/del>)/g,"")}function If(e){switch(e){case Xu.CONTEXT:return ff.CONTEXT;case Xu.INSERT:return ff.INSERTS;case Xu.DELETE:return ff.DELETES}}function yf(e){switch(e){case _u.DARK:return"d2h-dark-color-scheme";case _u.AUTO:return"d2h-auto-color-scheme";case _u.LIGHT:default:return"d2h-light-color-scheme"}}function vf(e){return e.slice(0).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;").replace(/\//g,"&#x2F;")}function bf(e,t,r=!0){const n=function(e){return e?2:1}(t);return{prefix:e.substring(0,n),content:r?vf(e.substring(n)):e.substring(n)}}function wf(e){const t=Ku(e.oldName),r=Ku(e.newName);if(t===r||Af(t)||Af(r))return Af(r)?t:r;{const e=[],n=[],i=t.split(gf),o=r.split(gf);let a=0,s=i.length-1,c=o.length-1;for(;a<s&&a<c&&i[a]===o[a];)e.push(o[a]),a+=1;for(;s>a&&c>a&&i[s]===o[c];)n.unshift(o[c]),s-=1,c-=1;const l=e.join(gf),u=n.join(gf),f=i.slice(a,s+1).join(gf),d=o.slice(a,c+1).join(gf);return l.length&&u.length?l+gf+"{"+f+" → "+d+"}"+gf+u:l.length?l+gf+"{"+f+" → "+d+"}":u.length?"{"+f+" → "+d+"}"+gf+u:t+" → "+r}}function Bf(e){return`d2h-${function(e){let t,r,n,i=0;for(t=0,n=e.length;t<n;t++)r=e.charCodeAt(t),i=(i<<5)-i+r,i|=0;return i}(wf(e)).toString().slice(-6)}`}function Ef(e){let t="file-changed";return e.isRename||e.isCopy?t="file-renamed":e.isNew?t="file-added":e.isDeleted?t="file-deleted":e.newName!==e.oldName&&(t="file-renamed"),t}function Cf(e,t,r,n={}){const{matching:i,maxLineLengthHighlight:o,matchWordsThreshold:a,diffStyle:s}=Object.assign(Object.assign({},df),n),c=bf(e,r,!1),l=bf(t,r,!1);if(c.content.length>o||l.content.length>o)return{oldLine:{prefix:c.prefix,content:vf(c.content)},newLine:{prefix:l.prefix,content:vf(l.content)}};const u="char"===s?(f=c.content,d=l.content,af.diff(f,d,g)):function(e,t,r){return cf.diff(e,t,r)}(c.content,l.content);var f,d,g;const p=[];if("word"===s&&"words"===i){const e=u.filter(e=>e.removed),t=u.filter(e=>e.added);hf(t,e).forEach(e=>{if(1===e[0].length&&1===e[1].length){pf(e[0][0],e[1][0])<a&&(p.push(e[0][0]),p.push(e[1][0]))}})}const h=u.reduce((e,t)=>{const r=t.added?"ins":t.removed?"del":null,n=p.indexOf(t)>-1?' class="d2h-change"':"",i=vf(t.value);return null!==r?`${e}<${r}${n}>${i}</${r}>`:`${e}${i}`},"");return{oldLine:{prefix:c.prefix,content:(A=h,A.replace(/(<ins[^>]*>((.|\n)*?)<\/ins>)/g,""))},newLine:{prefix:l.prefix,content:mf(h)}};var A}const xf="file-summary",Df={colorScheme:df.colorScheme};class Ff{constructor(e,t={}){this.hoganUtils=e,this.config=Object.assign(Object.assign({},Df),t)}render(e){const t=e.map(e=>this.hoganUtils.render(xf,"line",{fileHtmlId:Bf(e),oldName:e.oldName,newName:e.newName,fileName:wf(e),deletedLines:"-"+e.deletedLines,addedLines:"+"+e.addedLines},{fileIcon:this.hoganUtils.template("icon",Ef(e))})).join("\n");return this.hoganUtils.render(xf,"wrapper",{colorScheme:yf(this.config.colorScheme),filesNumber:e.length,files:t})}}const Qf=Object.assign(Object.assign({},df),{renderNothingWhenEmpty:!1,matchingMaxComparisons:2500,maxLineSizeInBlockForComparison:200}),Sf="generic",kf="line-by-line";class Nf{constructor(e,t={}){this.hoganUtils=e,this.config=Object.assign(Object.assign({},Qf),t)}render(e){const t=e.map(e=>{let t;return t=e.blocks.length?this.generateFileHtml(e):this.generateEmptyDiff(),this.makeFileDiffHtml(e,t)}).join("\n");return this.hoganUtils.render(Sf,"wrapper",{colorScheme:yf(this.config.colorScheme),content:t})}makeFileDiffHtml(e,t){if(this.config.renderNothingWhenEmpty&&Array.isArray(e.blocks)&&0===e.blocks.length)return"";const r=this.hoganUtils.template(kf,"file-diff"),n=this.hoganUtils.template(Sf,"file-path"),i=this.hoganUtils.template("icon","file"),o=this.hoganUtils.template("tag",Ef(e));return r.render({file:e,fileHtmlId:Bf(e),diffs:t,filePath:n.render({fileDiffName:wf(e)},{fileIcon:i,fileTag:o})})}generateEmptyDiff(){return this.hoganUtils.render(Sf,"empty-diff",{contentClass:"d2h-code-line",CSSLineClass:ff})}generateFileHtml(e){const t=uf(lf(t=>bf(t.content,e.isCombined).content));return e.blocks.map(r=>{let n=this.hoganUtils.render(Sf,"block-header",{CSSLineClass:ff,blockHeader:e.isTooBig?r.header:vf(r.header),lineClass:"d2h-code-linenumber",contentClass:"d2h-code-line"});return this.applyLineGroupping(r).forEach(([r,i,o])=>{if(i.length&&o.length&&!r.length)this.applyRematchMatching(i,o,t).map(([t,r])=>{const{left:i,right:o}=this.processChangedLines(e,e.isCombined,t,r);n+=i,n+=o});else if(r.length)r.forEach(t=>{const{prefix:r,content:i}=bf(t.content,e.isCombined);n+=this.generateSingleLineHtml(e,{type:ff.CONTEXT,prefix:r,content:i,oldNumber:t.oldNumber,newNumber:t.newNumber})});else if(i.length||o.length){const{left:t,right:r}=this.processChangedLines(e,e.isCombined,i,o);n+=t,n+=r}else console.error("Unknown state reached while processing groups of lines",r,i,o)}),n}).join("\n")}applyLineGroupping(e){const t=[];let r=[],n=[];for(let i=0;i<e.lines.length;i++){const o=e.lines[i];(o.type!==Xu.INSERT&&n.length||o.type===Xu.CONTEXT&&r.length>0)&&(t.push([[],r,n]),r=[],n=[]),o.type===Xu.CONTEXT?t.push([[o],[],[]]):o.type===Xu.INSERT&&0===r.length?t.push([[],[],[o]]):o.type===Xu.INSERT&&r.length>0?n.push(o):o.type===Xu.DELETE&&r.push(o)}return(r.length||n.length)&&(t.push([[],r,n]),r=[],n=[]),t}applyRematchMatching(e,t,r){const n=e.length*t.length,i=$u(e.concat(t).map(e=>e.content.length));return n<this.config.matchingMaxComparisons&&i<this.config.maxLineSizeInBlockForComparison&&("lines"===this.config.matching||"words"===this.config.matching)?r(e,t):[[e,t]]}processChangedLines(e,t,r,n){const i={right:"",left:""},o=Math.max(r.length,n.length);for(let a=0;a<o;a++){const o=r[a],s=n[a],c=void 0!==o&&void 0!==s?Cf(o.content,s.content,t,this.config):void 0,l=void 0!==o&&void 0!==o.oldNumber?Object.assign(Object.assign({},void 0!==c?{prefix:c.oldLine.prefix,content:c.oldLine.content,type:ff.DELETE_CHANGES}:Object.assign(Object.assign({},bf(o.content,t)),{type:If(o.type)})),{oldNumber:o.oldNumber,newNumber:o.newNumber}):void 0,u=void 0!==s&&void 0!==s.newNumber?Object.assign(Object.assign({},void 0!==c?{prefix:c.newLine.prefix,content:c.newLine.content,type:ff.INSERT_CHANGES}:Object.assign(Object.assign({},bf(s.content,t)),{type:If(s.type)})),{oldNumber:s.oldNumber,newNumber:s.newNumber}):void 0,{left:f,right:d}=this.generateLineHtml(e,l,u);i.left+=f,i.right+=d}return i}generateLineHtml(e,t,r){return{left:this.generateSingleLineHtml(e,t),right:this.generateSingleLineHtml(e,r)}}generateSingleLineHtml(e,t){if(void 0===t)return"";const r=this.hoganUtils.render(kf,"numbers",{oldNumber:t.oldNumber||"",newNumber:t.newNumber||""});return this.hoganUtils.render(Sf,"line",{type:t.type,lineClass:"d2h-code-linenumber",contentClass:"d2h-code-line",prefix:" "===t.prefix?"&nbsp;":t.prefix,content:t.content,lineNumber:r,line:t,file:e})}}const qf=Object.assign(Object.assign({},df),{renderNothingWhenEmpty:!1,matchingMaxComparisons:2500,maxLineSizeInBlockForComparison:200}),Mf="generic";class Hf{constructor(e,t={}){this.hoganUtils=e,this.config=Object.assign(Object.assign({},qf),t)}render(e){const t=e.map(e=>{let t;return t=e.blocks.length?this.generateFileHtml(e):this.generateEmptyDiff(),this.makeFileDiffHtml(e,t)}).join("\n");return this.hoganUtils.render(Mf,"wrapper",{colorScheme:yf(this.config.colorScheme),content:t})}makeFileDiffHtml(e,t){if(this.config.renderNothingWhenEmpty&&Array.isArray(e.blocks)&&0===e.blocks.length)return"";const r=this.hoganUtils.template("side-by-side","file-diff"),n=this.hoganUtils.template(Mf,"file-path"),i=this.hoganUtils.template("icon","file"),o=this.hoganUtils.template("tag",Ef(e));return r.render({file:e,fileHtmlId:Bf(e),diffs:t,filePath:n.render({fileDiffName:wf(e)},{fileIcon:i,fileTag:o})})}generateEmptyDiff(){return{right:"",left:this.hoganUtils.render(Mf,"empty-diff",{contentClass:"d2h-code-side-line",CSSLineClass:ff})}}generateFileHtml(e){const t=uf(lf(t=>bf(t.content,e.isCombined).content));return e.blocks.map(r=>{const n={left:this.makeHeaderHtml(r.header,e),right:this.makeHeaderHtml("")};return this.applyLineGroupping(r).forEach(([r,i,o])=>{if(i.length&&o.length&&!r.length)this.applyRematchMatching(i,o,t).map(([t,r])=>{const{left:i,right:o}=this.processChangedLines(e.isCombined,t,r);n.left+=i,n.right+=o});else if(r.length)r.forEach(t=>{const{prefix:r,content:i}=bf(t.content,e.isCombined),{left:o,right:a}=this.generateLineHtml({type:ff.CONTEXT,prefix:r,content:i,number:t.oldNumber},{type:ff.CONTEXT,prefix:r,content:i,number:t.newNumber});n.left+=o,n.right+=a});else if(i.length||o.length){const{left:t,right:r}=this.processChangedLines(e.isCombined,i,o);n.left+=t,n.right+=r}else console.error("Unknown state reached while processing groups of lines",r,i,o)}),n}).reduce((e,t)=>({left:e.left+t.left,right:e.right+t.right}),{left:"",right:""})}applyLineGroupping(e){const t=[];let r=[],n=[];for(let i=0;i<e.lines.length;i++){const o=e.lines[i];(o.type!==Xu.INSERT&&n.length||o.type===Xu.CONTEXT&&r.length>0)&&(t.push([[],r,n]),r=[],n=[]),o.type===Xu.CONTEXT?t.push([[o],[],[]]):o.type===Xu.INSERT&&0===r.length?t.push([[],[],[o]]):o.type===Xu.INSERT&&r.length>0?n.push(o):o.type===Xu.DELETE&&r.push(o)}return(r.length||n.length)&&(t.push([[],r,n]),r=[],n=[]),t}applyRematchMatching(e,t,r){const n=e.length*t.length,i=$u(e.concat(t).map(e=>e.content.length));return n<this.config.matchingMaxComparisons&&i<this.config.maxLineSizeInBlockForComparison&&("lines"===this.config.matching||"words"===this.config.matching)?r(e,t):[[e,t]]}makeHeaderHtml(e,t){return this.hoganUtils.render(Mf,"block-header",{CSSLineClass:ff,blockHeader:(null==t?void 0:t.isTooBig)?e:vf(e),lineClass:"d2h-code-side-linenumber",contentClass:"d2h-code-side-line"})}processChangedLines(e,t,r){const n={right:"",left:""},i=Math.max(t.length,r.length);for(let o=0;o<i;o++){const i=t[o],a=r[o],s=void 0!==i&&void 0!==a?Cf(i.content,a.content,e,this.config):void 0,c=void 0!==i&&void 0!==i.oldNumber?Object.assign(Object.assign({},void 0!==s?{prefix:s.oldLine.prefix,content:s.oldLine.content,type:ff.DELETE_CHANGES}:Object.assign(Object.assign({},bf(i.content,e)),{type:If(i.type)})),{number:i.oldNumber}):void 0,l=void 0!==a&&void 0!==a.newNumber?Object.assign(Object.assign({},void 0!==s?{prefix:s.newLine.prefix,content:s.newLine.content,type:ff.INSERT_CHANGES}:Object.assign(Object.assign({},bf(a.content,e)),{type:If(a.type)})),{number:a.newNumber}):void 0,{left:u,right:f}=this.generateLineHtml(c,l);n.left+=u,n.right+=f}return n}generateLineHtml(e,t){return{left:this.generateSingleHtml(e),right:this.generateSingleHtml(t)}}generateSingleHtml(e){const t="d2h-code-side-linenumber",r="d2h-code-side-line";return this.hoganUtils.render(Mf,"line",{type:(null==e?void 0:e.type)||`${ff.CONTEXT} d2h-emptyplaceholder`,lineClass:void 0!==e?t:`${t} d2h-code-side-emptyplaceholder`,contentClass:void 0!==e?r:`${r} d2h-code-side-emptyplaceholder`,prefix:" "===(null==e?void 0:e.prefix)?"&nbsp;":null==e?void 0:e.prefix,content:null==e?void 0:e.content,lineNumber:null==e?void 0:e.number})}}var Lf={};!function(e){!function(e){var t=/\S/,r=/\"/g,n=/\n/g,i=/\r/g,o=/\\/g,a=/\u2028/,s=/\u2029/;function c(e){"}"===e.n.substr(e.n.length-1)&&(e.n=e.n.substring(0,e.n.length-1))}function l(e){return e.trim?e.trim():e.replace(/^\s*|\s*$/g,"")}function u(e,t,r){if(t.charAt(r)!=e.charAt(0))return!1;for(var n=1,i=e.length;n<i;n++)if(t.charAt(r+n)!=e.charAt(n))return!1;return!0}e.tags={"#":1,"^":2,"<":3,$:4,"/":5,"!":6,">":7,"=":8,_v:9,"{":10,"&":11,_t:12},e.scan=function(r,n){var i=r.length,o=0,a=null,s=null,f="",d=[],g=!1,p=0,h=0,A="{{",m="}}";function I(){f.length>0&&(d.push({tag:"_t",text:new String(f)}),f="")}function y(r,n){if(I(),r&&function(){for(var r=!0,n=h;n<d.length;n++)if(!(r=e.tags[d[n].tag]<e.tags._v||"_t"==d[n].tag&&null===d[n].text.match(t)))return!1;return r}())for(var i,o=h;o<d.length;o++)d[o].text&&((i=d[o+1])&&">"==i.tag&&(i.indent=d[o].text.toString()),d.splice(o,1));else n||d.push({tag:"\n"});g=!1,h=d.length}function v(e,t){var r="="+m,n=e.indexOf(r,t),i=l(e.substring(e.indexOf("=",t)+1,n)).split(" ");return A=i[0],m=i[i.length-1],n+r.length-1}for(n&&(n=n.split(" "),A=n[0],m=n[1]),p=0;p<i;p++)0==o?u(A,r,p)?(--p,I(),o=1):"\n"==r.charAt(p)?y(g):f+=r.charAt(p):1==o?(p+=A.length-1,"="==(a=(s=e.tags[r.charAt(p+1)])?r.charAt(p+1):"_v")?(p=v(r,p),o=0):(s&&p++,o=2),g=p):u(m,r,p)?(d.push({tag:a,n:l(f),otag:A,ctag:m,i:"/"==a?g-A.length:p+m.length}),f="",p+=m.length-1,o=0,"{"==a&&("}}"==m?p++:c(d[d.length-1]))):f+=r.charAt(p);return y(g,!0),d};var f={_t:!0,"\n":!0,$:!0,"/":!0};function d(t,r,n,i){var o,a=[],s=null,c=null;for(o=n[n.length-1];t.length>0;){if(c=t.shift(),o&&"<"==o.tag&&!(c.tag in f))throw new Error("Illegal content in < super tag.");if(e.tags[c.tag]<=e.tags.$||g(c,i))n.push(c),c.nodes=d(t,c.tag,n,i);else{if("/"==c.tag){if(0===n.length)throw new Error("Closing tag without opener: /"+c.n);if(s=n.pop(),c.n!=s.n&&!p(c.n,s.n,i))throw new Error("Nesting error: "+s.n+" vs. "+c.n);return s.end=c.i,a}"\n"==c.tag&&(c.last=0==t.length||"\n"==t[0].tag)}a.push(c)}if(n.length>0)throw new Error("missing closing tag: "+n.pop().n);return a}function g(e,t){for(var r=0,n=t.length;r<n;r++)if(t[r].o==e.n)return e.tag="#",!0}function p(e,t,r){for(var n=0,i=r.length;n<i;n++)if(r[n].c==e&&r[n].o==t)return!0}function h(e){var t=[];for(var r in e.partials)t.push('"'+m(r)+'":{name:"'+m(e.partials[r].name)+'", '+h(e.partials[r])+"}");return"partials: {"+t.join(",")+"}, subs: "+function(e){var t=[];for(var r in e)t.push('"'+m(r)+'": function(c,p,t,i) {'+e[r]+"}");return"{ "+t.join(",")+" }"}(e.subs)}e.stringify=function(t,r,n){return"{code: function (c,p,i) { "+e.wrapMain(t.code)+" },"+h(t)+"}"};var A=0;function m(e){return e.replace(o,"\\\\").replace(r,'\\"').replace(n,"\\n").replace(i,"\\r").replace(a,"\\u2028").replace(s,"\\u2029")}function I(e){return~e.indexOf(".")?"d":"f"}function y(e,t){var r="<"+(t.prefix||"")+e.n+A++;return t.partials[r]={name:e.n,partials:{}},t.code+='t.b(t.rp("'+m(r)+'",c,p,"'+(e.indent||"")+'"));',r}function v(e,t){t.code+="t.b(t.t(t."+I(e.n)+'("'+m(e.n)+'",c,p,0)));'}function b(e){return"t.b("+e+");"}e.generate=function(t,r,n){A=0;var i={code:"",subs:{},partials:{}};return e.walk(t,i),n.asString?this.stringify(i,r,n):this.makeTemplate(i,r,n)},e.wrapMain=function(e){return'var t=this;t.b(i=i||"");'+e+"return t.fl();"},e.template=e.Template,e.makeTemplate=function(e,t,r){var n=this.makePartials(e);return n.code=new Function("c","p","i",this.wrapMain(e.code)),new this.template(n,t,this,r)},e.makePartials=function(e){var t,r={subs:{},partials:e.partials,name:e.name};for(t in r.partials)r.partials[t]=this.makePartials(r.partials[t]);for(t in e.subs)r.subs[t]=new Function("c","p","t","i",e.subs[t]);return r},e.codegen={"#":function(t,r){r.code+="if(t.s(t."+I(t.n)+'("'+m(t.n)+'",c,p,1),c,p,0,'+t.i+","+t.end+',"'+t.otag+" "+t.ctag+'")){t.rs(c,p,function(c,p,t){',e.walk(t.nodes,r),r.code+="});c.pop();}"},"^":function(t,r){r.code+="if(!t.s(t."+I(t.n)+'("'+m(t.n)+'",c,p,1),c,p,1,0,0,"")){',e.walk(t.nodes,r),r.code+="};"},">":y,"<":function(t,r){var n={partials:{},code:"",subs:{},inPartial:!0};e.walk(t.nodes,n);var i=r.partials[y(t,r)];i.subs=n.subs,i.partials=n.partials},$:function(t,r){var n={subs:{},code:"",partials:r.partials,prefix:t.n};e.walk(t.nodes,n),r.subs[t.n]=n.code,r.inPartial||(r.code+='t.sub("'+m(t.n)+'",c,p,i);')},"\n":function(e,t){t.code+=b('"\\n"'+(e.last?"":" + i"))},_v:function(e,t){t.code+="t.b(t.v(t."+I(e.n)+'("'+m(e.n)+'",c,p,0)));'},_t:function(e,t){t.code+=b('"'+m(e.text)+'"')},"{":v,"&":v},e.walk=function(t,r){for(var n,i=0,o=t.length;i<o;i++)(n=e.codegen[t[i].tag])&&n(t[i],r);return r},e.parse=function(e,t,r){return d(e,0,[],(r=r||{}).sectionTags||[])},e.cache={},e.cacheKey=function(e,t){return[e,!!t.asString,!!t.disableLambda,t.delimiters,!!t.modelGet].join("||")},e.compile=function(t,r){r=r||{};var n=e.cacheKey(t,r),i=this.cache[n];if(i){var o=i.partials;for(var a in o)delete o[a].instance;return i}return i=this.generate(this.parse(this.scan(t,r.delimiters),t,r),t,r),this.cache[n]=i}}(e)}(Lf);var Uf={};!function(e){!function(e){function t(e,t,r){var n;return t&&"object"==typeof t&&(void 0!==t[e]?n=t[e]:r&&t.get&&"function"==typeof t.get&&(n=t.get(e))),n}e.Template=function(e,t,r,n){e=e||{},this.r=e.code||this.r,this.c=r,this.options=n||{},this.text=t||"",this.partials=e.partials||{},this.subs=e.subs||{},this.buf=""},e.Template.prototype={r:function(e,t,r){return""},v:function(e){return e=c(e),s.test(e)?e.replace(r,"&amp;").replace(n,"&lt;").replace(i,"&gt;").replace(o,"&#39;").replace(a,"&quot;"):e},t:c,render:function(e,t,r){return this.ri([e],t||{},r)},ri:function(e,t,r){return this.r(e,t,r)},ep:function(e,t){var r=this.partials[e],n=t[r.name];if(r.instance&&r.base==n)return r.instance;if("string"==typeof n){if(!this.c)throw new Error("No compiler available.");n=this.c.compile(n,this.options)}if(!n)return null;if(this.partials[e].base=n,r.subs){for(key in t.stackText||(t.stackText={}),r.subs)t.stackText[key]||(t.stackText[key]=void 0!==this.activeSub&&t.stackText[this.activeSub]?t.stackText[this.activeSub]:this.text);n=function(e,t,r,n,i,o){function a(){}function s(){}var c;a.prototype=e,s.prototype=e.subs;var l=new a;for(c in l.subs=new s,l.subsText={},l.buf="",n=n||{},l.stackSubs=n,l.subsText=o,t)n[c]||(n[c]=t[c]);for(c in n)l.subs[c]=n[c];for(c in i=i||{},l.stackPartials=i,r)i[c]||(i[c]=r[c]);for(c in i)l.partials[c]=i[c];return l}(n,r.subs,r.partials,this.stackSubs,this.stackPartials,t.stackText)}return this.partials[e].instance=n,n},rp:function(e,t,r,n){var i=this.ep(e,r);return i?i.ri(t,r,n):""},rs:function(e,t,r){var n=e[e.length-1];if(l(n))for(var i=0;i<n.length;i++)e.push(n[i]),r(e,t,this),e.pop();else r(e,t,this)},s:function(e,t,r,n,i,o,a){var s;return(!l(e)||0!==e.length)&&("function"==typeof e&&(e=this.ms(e,t,r,n,i,o,a)),s=!!e,!n&&s&&t&&t.push("object"==typeof e?e:t[t.length-1]),s)},d:function(e,r,n,i){var o,a=e.split("."),s=this.f(a[0],r,n,i),c=this.options.modelGet,u=null;if("."===e&&l(r[r.length-2]))s=r[r.length-1];else for(var f=1;f<a.length;f++)void 0!==(o=t(a[f],s,c))?(u=s,s=o):s="";return!(i&&!s)&&(i||"function"!=typeof s||(r.push(u),s=this.mv(s,r,n),r.pop()),s)},f:function(e,r,n,i){for(var o=!1,a=!1,s=this.options.modelGet,c=r.length-1;c>=0;c--)if(void 0!==(o=t(e,r[c],s))){a=!0;break}return a?(i||"function"!=typeof o||(o=this.mv(o,r,n)),o):!i&&""},ls:function(e,t,r,n,i,o){var a=this.options.delimiters;return this.options.delimiters=o,this.b(this.ct(c(e.call(t,i,r)),t,n)),this.options.delimiters=a,!1},ct:function(e,t,r){if(this.options.disableLambda)throw new Error("Lambda features disabled.");return this.c.compile(e,this.options).render(t,r)},b:function(e){this.buf+=e},fl:function(){var e=this.buf;return this.buf="",e},ms:function(e,t,r,n,i,o,a){var s,c=t[t.length-1],l=e.call(c);return"function"==typeof l?!!n||(s=this.activeSub&&this.subsText&&this.subsText[this.activeSub]?this.subsText[this.activeSub]:this.text,this.ls(l,c,t,r,s.substring(i,o),a)):l},mv:function(e,t,r){var n=t[t.length-1],i=e.call(n);return"function"==typeof i?this.ct(c(i.call(n)),n,r):i},sub:function(e,t,r,n){var i=this.subs[e];i&&(this.activeSub=e,i(t,r,this,n),this.activeSub=!1)}};var r=/&/g,n=/</g,i=/>/g,o=/\'/g,a=/\"/g,s=/[&<>\"\']/;function c(e){return String(null==e?"":e)}var l=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}}(e)}(Uf);var Rf=Lf;Rf.Template=Uf.Template,Rf.template=Rf.Template;var Of=Rf;const Tf={};Tf["file-summary-line"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<li class="d2h-file-list-line">'),n.b("\n"+r),n.b(' <span class="d2h-file-name-wrapper">'),n.b("\n"+r),n.b(n.rp("<fileIcon0",e,t," ")),n.b(' <a href="#'),n.b(n.v(n.f("fileHtmlId",e,t,0))),n.b('" class="d2h-file-name">'),n.b(n.v(n.f("fileName",e,t,0))),n.b("</a>"),n.b("\n"+r),n.b(' <span class="d2h-file-stats">'),n.b("\n"+r),n.b(' <span class="d2h-lines-added">'),n.b(n.v(n.f("addedLines",e,t,0))),n.b("</span>"),n.b("\n"+r),n.b(' <span class="d2h-lines-deleted">'),n.b(n.v(n.f("deletedLines",e,t,0))),n.b("</span>"),n.b("\n"+r),n.b(" </span>"),n.b("\n"+r),n.b(" </span>"),n.b("\n"+r),n.b("</li>"),n.fl()},partials:{"<fileIcon0":{name:"fileIcon",partials:{},subs:{}}},subs:{}}),Tf["file-summary-wrapper"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<div class="d2h-file-list-wrapper '),n.b(n.v(n.f("colorScheme",e,t,0))),n.b('">'),n.b("\n"+r),n.b(' <div class="d2h-file-list-header">'),n.b("\n"+r),n.b(' <span class="d2h-file-list-title">Files changed ('),n.b(n.v(n.f("filesNumber",e,t,0))),n.b(")</span>"),n.b("\n"+r),n.b(' <a class="d2h-file-switch d2h-hide">hide</a>'),n.b("\n"+r),n.b(' <a class="d2h-file-switch d2h-show">show</a>'),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(' <ol class="d2h-file-list">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.f("files",e,t,0))),n.b("\n"+r),n.b(" </ol>"),n.b("\n"+r),n.b("</div>"),n.fl()},partials:{},subs:{}}),Tf["generic-block-header"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b("<tr>"),n.b("\n"+r),n.b(' <td class="'),n.b(n.v(n.f("lineClass",e,t,0))),n.b(" "),n.b(n.v(n.d("CSSLineClass.INFO",e,t,0))),n.b('"></td>'),n.b("\n"+r),n.b(' <td class="'),n.b(n.v(n.d("CSSLineClass.INFO",e,t,0))),n.b('">'),n.b("\n"+r),n.b(' <div class="'),n.b(n.v(n.f("contentClass",e,t,0))),n.b('">'),n.s(n.f("blockHeader",e,t,1),e,t,0,156,173,"{{ }}")&&(n.rs(e,t,function(e,t,r){r.b(r.t(r.f("blockHeader",e,t,0)))}),e.pop()),n.s(n.f("blockHeader",e,t,1),e,t,1,0,0,"")||n.b("&nbsp;"),n.b("</div>"),n.b("\n"+r),n.b(" </td>"),n.b("\n"+r),n.b("</tr>"),n.fl()},partials:{},subs:{}}),Tf["generic-empty-diff"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b("<tr>"),n.b("\n"+r),n.b(' <td class="'),n.b(n.v(n.d("CSSLineClass.INFO",e,t,0))),n.b('">'),n.b("\n"+r),n.b(' <div class="'),n.b(n.v(n.f("contentClass",e,t,0))),n.b('">'),n.b("\n"+r),n.b(" File without changes"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(" </td>"),n.b("\n"+r),n.b("</tr>"),n.fl()},partials:{},subs:{}}),Tf["generic-file-path"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<span class="d2h-file-name-wrapper">'),n.b("\n"+r),n.b(n.rp("<fileIcon0",e,t," ")),n.b(' <span class="d2h-file-name">'),n.b(n.v(n.f("fileDiffName",e,t,0))),n.b("</span>"),n.b("\n"+r),n.b(n.rp("<fileTag1",e,t," ")),n.b("</span>"),n.b("\n"+r),n.b('<label class="d2h-file-collapse">'),n.b("\n"+r),n.b(' <input class="d2h-file-collapse-input" type="checkbox" name="viewed" value="viewed">'),n.b("\n"+r),n.b(" Viewed"),n.b("\n"+r),n.b("</label>"),n.fl()},partials:{"<fileIcon0":{name:"fileIcon",partials:{},subs:{}},"<fileTag1":{name:"fileTag",partials:{},subs:{}}},subs:{}}),Tf["generic-line"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b("<tr>"),n.b("\n"+r),n.b(' <td class="'),n.b(n.v(n.f("lineClass",e,t,0))),n.b(" "),n.b(n.v(n.f("type",e,t,0))),n.b('">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.f("lineNumber",e,t,0))),n.b("\n"+r),n.b(" </td>"),n.b("\n"+r),n.b(' <td class="'),n.b(n.v(n.f("type",e,t,0))),n.b('">'),n.b("\n"+r),n.b(' <div class="'),n.b(n.v(n.f("contentClass",e,t,0))),n.b('">'),n.b("\n"+r),n.s(n.f("prefix",e,t,1),e,t,0,162,238,"{{ }}")&&(n.rs(e,t,function(e,t,n){n.b(' <span class="d2h-code-line-prefix">'),n.b(n.t(n.f("prefix",e,t,0))),n.b("</span>"),n.b("\n"+r)}),e.pop()),n.s(n.f("prefix",e,t,1),e,t,1,0,0,"")||(n.b(' <span class="d2h-code-line-prefix">&nbsp;</span>'),n.b("\n"+r)),n.s(n.f("content",e,t,1),e,t,0,371,445,"{{ }}")&&(n.rs(e,t,function(e,t,n){n.b(' <span class="d2h-code-line-ctn">'),n.b(n.t(n.f("content",e,t,0))),n.b("</span>"),n.b("\n"+r)}),e.pop()),n.s(n.f("content",e,t,1),e,t,1,0,0,"")||(n.b(' <span class="d2h-code-line-ctn"><br></span>'),n.b("\n"+r)),n.b(" </div>"),n.b("\n"+r),n.b(" </td>"),n.b("\n"+r),n.b("</tr>"),n.fl()},partials:{},subs:{}}),Tf["generic-wrapper"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<div class="d2h-wrapper '),n.b(n.v(n.f("colorScheme",e,t,0))),n.b('">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.f("content",e,t,0))),n.b("\n"+r),n.b("</div>"),n.fl()},partials:{},subs:{}}),Tf["icon-file-added"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<svg aria-hidden="true" class="d2h-icon d2h-added" height="16" title="added" version="1.1" viewBox="0 0 14 16"'),n.b("\n"+r),n.b(' width="14">'),n.b("\n"+r),n.b(' <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM6 9H3V7h3V4h2v3h3v2H8v3H6V9z"></path>'),n.b("\n"+r),n.b("</svg>"),n.fl()},partials:{},subs:{}}),Tf["icon-file-changed"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<svg aria-hidden="true" class="d2h-icon d2h-changed" height="16" title="modified" version="1.1"'),n.b("\n"+r),n.b(' viewBox="0 0 14 16" width="14">'),n.b("\n"+r),n.b(' <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM4 8c0-1.66 1.34-3 3-3s3 1.34 3 3-1.34 3-3 3-3-1.34-3-3z"></path>'),n.b("\n"+r),n.b("</svg>"),n.fl()},partials:{},subs:{}}),Tf["icon-file-deleted"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<svg aria-hidden="true" class="d2h-icon d2h-deleted" height="16" title="removed" version="1.1"'),n.b("\n"+r),n.b(' viewBox="0 0 14 16" width="14">'),n.b("\n"+r),n.b(' <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM11 9H3V7h8v2z"></path>'),n.b("\n"+r),n.b("</svg>"),n.fl()},partials:{},subs:{}}),Tf["icon-file-renamed"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<svg aria-hidden="true" class="d2h-icon d2h-moved" height="16" title="renamed" version="1.1"'),n.b("\n"+r),n.b(' viewBox="0 0 14 16" width="14">'),n.b("\n"+r),n.b(' <path d="M6 9H3V7h3V4l5 4-5 4V9z m8-7v12c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h12c0.55 0 1 0.45 1 1z m-1 0H1v12h12V2z"></path>'),n.b("\n"+r),n.b("</svg>"),n.fl()},partials:{},subs:{}}),Tf["icon-file"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<svg aria-hidden="true" class="d2h-icon" height="16" version="1.1" viewBox="0 0 12 16" width="12">'),n.b("\n"+r),n.b(' <path d="M6 5H2v-1h4v1zM2 8h7v-1H2v1z m0 2h7v-1H2v1z m0 2h7v-1H2v1z m10-7.5v9.5c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h7.5l3.5 3.5z m-1 0.5L8 2H1v12h10V5z"></path>'),n.b("\n"+r),n.b("</svg>"),n.fl()},partials:{},subs:{}}),Tf["line-by-line-file-diff"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<div id="'),n.b(n.v(n.f("fileHtmlId",e,t,0))),n.b('" class="d2h-file-wrapper" data-lang="'),n.b(n.v(n.d("file.language",e,t,0))),n.b('">'),n.b("\n"+r),n.b(' <div class="d2h-file-header">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.f("filePath",e,t,0))),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(' <div class="d2h-file-diff">'),n.b("\n"+r),n.b(' <div class="d2h-code-wrapper">'),n.b("\n"+r),n.b(' <table class="d2h-diff-table">'),n.b("\n"+r),n.b(' <tbody class="d2h-diff-tbody">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.f("diffs",e,t,0))),n.b("\n"+r),n.b(" </tbody>"),n.b("\n"+r),n.b(" </table>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b("</div>"),n.fl()},partials:{},subs:{}}),Tf["line-by-line-numbers"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<div class="line-num1">'),n.b(n.v(n.f("oldNumber",e,t,0))),n.b("</div>"),n.b("\n"+r),n.b('<div class="line-num2">'),n.b(n.v(n.f("newNumber",e,t,0))),n.b("</div>"),n.fl()},partials:{},subs:{}}),Tf["side-by-side-file-diff"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<div id="'),n.b(n.v(n.f("fileHtmlId",e,t,0))),n.b('" class="d2h-file-wrapper" data-lang="'),n.b(n.v(n.d("file.language",e,t,0))),n.b('">'),n.b("\n"+r),n.b(' <div class="d2h-file-header">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.f("filePath",e,t,0))),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(' <div class="d2h-files-diff">'),n.b("\n"+r),n.b(' <div class="d2h-file-side-diff">'),n.b("\n"+r),n.b(' <div class="d2h-code-wrapper">'),n.b("\n"+r),n.b(' <table class="d2h-diff-table">'),n.b("\n"+r),n.b(' <tbody class="d2h-diff-tbody">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.d("diffs.left",e,t,0))),n.b("\n"+r),n.b(" </tbody>"),n.b("\n"+r),n.b(" </table>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(' <div class="d2h-file-side-diff">'),n.b("\n"+r),n.b(' <div class="d2h-code-wrapper">'),n.b("\n"+r),n.b(' <table class="d2h-diff-table">'),n.b("\n"+r),n.b(' <tbody class="d2h-diff-tbody">'),n.b("\n"+r),n.b(" "),n.b(n.t(n.d("diffs.right",e,t,0))),n.b("\n"+r),n.b(" </tbody>"),n.b("\n"+r),n.b(" </table>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b(" </div>"),n.b("\n"+r),n.b("</div>"),n.fl()},partials:{},subs:{}}),Tf["tag-file-added"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<span class="d2h-tag d2h-added d2h-added-tag">ADDED</span>'),n.fl()},partials:{},subs:{}}),Tf["tag-file-changed"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<span class="d2h-tag d2h-changed d2h-changed-tag">CHANGED</span>'),n.fl()},partials:{},subs:{}}),Tf["tag-file-deleted"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<span class="d2h-tag d2h-deleted d2h-deleted-tag">DELETED</span>'),n.fl()},partials:{},subs:{}}),Tf["tag-file-renamed"]=new Of.Template({code:function(e,t,r){var n=this;return n.b(r=r||""),n.b('<span class="d2h-tag d2h-moved d2h-moved-tag">RENAMED</span>'),n.fl()},partials:{},subs:{}});class Yf{constructor({compiledTemplates:e={},rawTemplates:t={}}){const r=Object.entries(t).reduce((e,[t,r])=>{const n=Of.compile(r,{asString:!1});return Object.assign(Object.assign({},e),{[t]:n})},{});this.preCompiledTemplates=Object.assign(Object.assign(Object.assign({},Tf),e),r)}static compile(e){return Of.compile(e,{asString:!1})}render(e,t,r,n,i){const o=this.templateKey(e,t);try{return this.preCompiledTemplates[o].render(r,n,i)}catch(e){throw new Error(`Could not find template to render '${o}'`)}}template(e,t){return this.preCompiledTemplates[this.templateKey(e,t)]}templateKey(e,t){return`${e}-${t}`}}const jf=Object.assign(Object.assign(Object.assign({},Qf),qf),{outputFormat:"line-by-line",drawFileList:!0});var Gf=Object.freeze({__proto__:null,defaultDiff2HtmlConfig:jf,html:function(e,t={}){const r=Object.assign(Object.assign({},jf),t),n="string"==typeof e?nf(e,r):e,i=new Yf(r),{colorScheme:o}=r,a={colorScheme:o};return(r.drawFileList?new Ff(i,a).render(n):"")+("side-by-side"===r.outputFormat?new Hf(i,r).render(n):new Nf(i,r).render(n))},parse:function(e,t={}){return nf(e,Object.assign(Object.assign({},jf),t))}});function Jf(){if("[object Module]"===Object.prototype.toString.call(Gf))return Gf;let e=yn(),t=we(e,"Diff2Html.default",null),r=we(e,"Diff2Html",null),n="html";if(Ee(t)&&va(t[n]))return t;if(Ee(r)&&va(r[n]))return r;throw console.log("Diff2Html",Gf,"g.Diff2Html",e.Diff2Html),new Error("invalid Diff2Html, g.Diff2Html, g.Diff2Html.default, use script for import")}function zf(e){return document.querySelectorAll(e)}function Vf(e){function t(e){e.parentNode.removeChild(e)}if(br(e)){return void t(e)}if(!De(e))return;Er(zf(e),function(e){t(e)})}function Pf(e,t){if(!br(e))return"invalid eleParent";if(xe(t))e.insertAdjacentHTML("afterbegin",t);else{if(!br(t))return"invalid itemChild";e.insertBefore(t,e.firstChild)}}async function Xf(e,t={}){if(!br(e))return Promise.reject("invalid ele");let r=we(t,"scale",null);if(Se(r)||(r=1),r=Mn(r),r<1)return Promise.reject("opt.scale can not less then 1");let n=we(t,"picType",null);"image/jpg"!==n&&"image/jpeg"!==n&&"image/png"!==n&&"svg"!==n&&(n="image/png");let i=we(t,"toBase64",null);pn(i)||(i=!0);let o=e.cloneNode(!0),a=document.createElement("div");a.style.position="absolute",a.style.top=0,a.style.left=0,a.style.zIndex=-1,a.appendChild(o);let s=document.createElement("div");s.style.opacity=0,s.style.position="relative",s.appendChild(a),Pf(document.querySelector("body"),s);let c,l=yn().snapdom,u={scale:r,quality:1,cache:"disabled"};return"image/jpg"===n||"image/jpeg"===n?c=await l.toJpg(a,u):"image/png"===n?c=await l.toPng(a,u):"svg"===n&&(c=await l.toSvg(a,u)),i&&(c=we(c,"src","")),Vf(s),c}var _f=Ra(Fa);function Wf(e){let t=function(e,r){return null===e.parentNode?r:t(e.parentNode,r.concat([e]))};return e instanceof HTMLElement||e instanceof SVGElement?t(e.parentNode,[]):[]}function Kf(e){let t=we(e,"clientX",null),r=we(e,"clientY",null),n=we(e,"pageX",null),i=we(e,"pageY",null);if(null!==t&&null!==r&&null!==n&&null!==i)return{clientX:t,clientY:r,pageX:n,pageY:i};let o=we(e,"changedTouches",[]);if(1!==dn(o))return null;let a=o[0];return{clientX:we(a,"clientX",null),clientY:we(a,"clientY",null),pageX:we(a,"pageX",null),pageY:we(a,"pageY",null)}}function $f(e,t){let r=[];try{r=document.elementsFromPoint(e,t)}catch(e){console.log(e)}return r}function Zf(e,t){if(!br(e))return null;if(!De(t))return null;try{return e.getAttribute(t)}catch(e){}return null}function ed(e){if(!br(e))return null;try{return e.getBoundingClientRect()}catch(e){}return null}function td(e,t){if(!Ee(e))return null;if(!Ia(e.clientX)||!Ia(e.clientY))return null;if(!br(t))return null;let r=ed(t);return r?{x:e.clientX-r.left,y:e.clientY-r.top,w:t.offsetWidth,h:t.offsetHeight}:null}function rd(e={}){let t="dragpreviewid",r=null,n=null,i=null,o=null,a=null,s=!1,c=we(e,"attIdentify",null);De(c)||(c="dragprevid");let l=we(e,"containerOpacity",null);Ia(l)||(l=.4);let u=we(e,"containerBackground",null);De(u)||(u="white");let f=we(e,"containerBorderWidth",null);Ia(f)||(f=1);let d=we(e,"containerBorderColor",null);De(d)||(d="#f26");let g=`c${Hu(8)}`;function p(e,t,r){n&&i&&o&&a&&!s&&(a.style.top=t-n.tShiftY+"px",a.style.left=e-n.tShiftX+"px")}function h(){Vf(`[${t}='${g}']`),n=null,i=null,o=null,a=null}let A=function(e){p(e.clientX,e.clientY)};window.addEventListener("mousemove",A);let m=function(e){let t=Kf(e);t&&p(t.clientX,t.clientY)};return window.addEventListener("touchmove",m),{createPreview:function(e,s,A){try{!function(){let h=function(e,t,n){let i=ed(e);if(!i)return null;r=e;let o=e.cloneNode(!0);return o.tShiftX=t-i.left,o.tShiftY=n-i.top,o.tWidth=e.offsetWidth,o.tHeight=e.offsetHeight,o.tParent=e.parentNode,o.setAttribute(c,""),o}(e,s,A);if(null===h)return;let m=document.createElement("div");m.style.position="absolute",m.style.zIndex=1,m.style.top=0,m.style.left=0,m.style.width="100%",m.style.height="100%",m.appendChild(h);let I=document.createElement("div");I.style.position="relative",I.appendChild(m);let y=document.createElement("div");y.setAttribute(t,g),y.style.position="fixed",y.style.zIndex=1e5,y.style.width=`${h.tWidth+2*f}px`,y.style.height=`${h.tHeight+2*f}px`,y.style.opacity=l,y.style.background=u,y.style.border=`${f}px solid ${d}`,y.style.pointerEvents="none",y.appendChild(I),document.querySelector("body").appendChild(y),n=h,i=m,o=I,a=y,p(s,A)}()}catch(e){}let m=setInterval(()=>{let e=Zf(r,c);document.querySelector(`[${c}='${e}']`)||(clearInterval(m),h())},500)},updateDragPreview:p,pauseDragPreview:function(e){s=e},removeDragPreview:h,setNodeStyle:function(e){try{Er(e,(e,t)=>{n.style[t]=e})}catch(e){}},setCoverStyle:function(e){try{Er(e,(e,t)=>{i.style[t]=e})}catch(e){}},setSellStyle:function(e){try{Er(e,(e,t)=>{o.style[t]=e})}catch(e){}},setContainerStyle:function(e){try{Er(e,(e,t)=>{a.style[t]=e})}catch(e){}},clear:function(){window.removeEventListener("mousemove",A),window.removeEventListener("touchmove",m)}}}let nd={};function id(e,t,{attIdentify:r,previewOpacity:n,previewBackground:i,previewBorderWidth:o,previewBorderColor:a}){if(!ke(nd,e)){let t=Xi(),s=function(e){let t=[];function r(){let r;r="mousemove";let n=function(t){e.dragMove({e:t,name:"mousemove"})};window.addEventListener(r,n),t.push({ele:window,name:r,f:n}),r="mouseup";let i=function(t){e.dragDrop({e:t,name:"mouseup"})};window.addEventListener(r,i),t.push({ele:window,name:r,f:i}),r="touchmove";let o=function(t){e.dragMove({e:t,name:"touchmove"})};window.addEventListener(r,o),t.push({ele:window,name:r,f:o}),r="touchend";let a=function(t){e.dragDrop({e:t,name:"touchend"})};window.addEventListener(r,a),t.push({ele:window,name:r,f:a})}function n(){Er(t,({ele:e,name:t,f:r})=>{e.removeEventListener(t,r)})}return{bind:r,unbind:n}}({dragMove:r=>{t.emit(e+"-dragMove",r)},dragDrop:r=>{t.emit(e+"-dragDrop",r)}});s.bind();let c=rd({attIdentify:r,containerOpacity:n,containerBackground:i,containerBorderWidth:o,containerBorderColor:a});nd[e]={eleIds:[],evg:t,oevg:s,pv:c,isInit:!1,isActive:!0}}return nd[e].eleIds.push(t),nd[e].evg}function od(e,t){let r=Zf(e,t);return r=Zi(r),r}function ad({gid:e,attGroup:t,attIndex:r,attIdentify:n,timeDragStartDelay:i,previewOpacity:o,previewDisabledOpacity:a}){let s=null,c=null,l=null,u=null;if(nd[e].isInit)return nd[e].evg;nd[e].isInit=!0;let f=nd[e].evg;f.on(e+"-dragStart",function({e:t,ele:o,from:l}){if(!nd[e].isActive)return;let u=od(o,r);if(null===u)return;s=u,c=o;let g={event:t,startInd:s,startEle:c,tarInd:s,tarEid:Zf(c,n)};f.emit(e+"-change",{mode:"start",...g}),f.emit(e+"-start",g);let p=Kf(t);if(!p)return;setTimeout(()=>{null!==s&&(d.createPreview(c,p.clientX,p.clientY),d.setContainerStyle({opacity:a}))},i)}),f.on(e+"-dragMove",function({e:i,name:g,from:p}){if(!nd[e].isActive)return;let h=function(e,t,r){let n=null;return Er(Wf(e.target),e=>{if(Zf(e,t)===r)return n=e,!1}),n}(i,t,e);if(null===s)return;let A=Kf(i);if(!A)return;function m(){let t={event:i,startInd:s,startEle:c,endInd:l,endEle:u,tarInd:l,tarEid:Zf(u,n)};f.emit(e+"-change",{mode:"leave",...t}),f.emit(e+"-leave",t),l=null,u=null,d.setContainerStyle({opacity:a})}if(!h)return void(null!==l&&m());let I=od(h,r);if(null===I)return;if(I===s)return void(null!==l&&m());if(I!==l)null!==l&&m(),function(t,r){l=t,u=r;let a={event:i,startInd:s,startEle:c,endInd:l,endEle:u,tarInd:l,tarEid:Zf(u,n)};f.emit(e+"-change",{mode:"enter",...a}),f.emit(e+"-enter",a),d.setContainerStyle({opacity:o})}(I,h);else{let t=td(A,h),r=0;t.w>0&&(r=t.x/t.w);let a=0;t.h>0&&(a=t.y/t.h),r>=0&&r<=1&&a>=0&&a<=1&&function(t,r,a){let g={event:i,startInd:s,startEle:c,endInd:l,endEle:u,tarInd:l,tarEid:Zf(u,n),...t,rx:r,ry:a};f.emit(e+"-change",{mode:"move",...g}),f.emit(e+"-move",g),d.setContainerStyle({opacity:o})}(t,r,a)}}),f.on(e+"-dragDrop",function({e:i,name:o,from:a}){if(d.removeDragPreview(),!nd[e].isActive)return;if(null===s)return;let g=function(e,t,r){let n=null,i=Kf(e);return i?(Er($f(i.clientX,i.clientY),e=>{if(Zf(e,t)===r)return n=e,!1}),n):n}(i,t,e);if(!g)return s=null,c=null,l=null,void(u=null);let p=od(g,r);if(null===p)return;(function(t,r){l=t,u=r;let o={event:i,startInd:s,startEle:c,endInd:l,endEle:u,tarInd:l,tarEid:Zf(u,n)};f.emit(e+"-change",{mode:"drop",...o}),f.emit(e+"-drop",o)})(p,g),s=null,c=null,l=null,u=null});let d=nd[e].pv}async function sd(e){let t=[],r=ns();return await async function e(r){let n=null;if(r.isFile&&(n=await function(e){let t=ns();try{e.file(t.resolve,t.reject)}catch(e){t.reject(e)}return t}(r)),t.push({type:r.isDirectory?"folder":r.isFile?"file":"unknow",path:r.fullPath,name:r.name,entry:r,file:n}),r.isDirectory){let t=r.createReader(),n=await function(e){let t=ns();try{e.readEntries(t.resolve,t.reject)}catch(e){t.reject(e)}return t}(t);await cl(n,async t=>{await e(t)})}}(e),r.resolve(t),r}async function cd(e){let t=[];Er(e,e=>{let r=e.webkitGetAsEntry();r&&t.push(r)});let r=await async function(e){let t=[];return await cl(e,async e=>{Er(await sd(e),e=>{t.push(e)})}),t}(t);return r}async function ld(e){let t=[],r=[];try{t=await async function(e){let t=[];return Er(e,e=>{e.type&&t.push({type:"file",name:e.name,file:e})}),t}(we(e,"files",[])),Vu()||(r=await cd(we(e,"items",[])).catch(e=>{console.log(e)}))}catch(e){return Promise.reject(e)}return{files:t,entries:r}}function ud(e){return document.querySelector(e)}function fd(e){return!Ur(e)}var dd=Math.max;var gd,pd=(gd=function(e,t,r){var n=null==e?0:e.length;if(!n)return-1;var i=null==r?0:qn(r);return i<0&&(i=dd(n+i,0)),Or(e,fr(t),i)},function(e,t,r){var n=Object(e);if(!ft(e)){var i=fr(t);e=dt(e),t=function(e){return i(n[e],e,n)}}var o=gd(e,t,r);return o>-1?n[i?e[o]:o]:void 0});let hd=[{name:"pic",group:"image",acp:"image/*",exec:"imageviwer"},{name:"xml",group:"data",acp:"text/xml",exec:"textviwer"},{name:"htm",group:"docums",acp:"text/html",exec:"browser"},{name:"html",group:"docums",acp:"text/html",exec:"browser"},{name:"json",group:"data",acp:"application/json",exec:"textviwer"},{name:"geojson",group:"data",acp:"application/geo+json",exec:"textviwer"},{name:"txt",group:"data",acp:"text/plain",exec:"textviwer"},{name:"csv",group:"data",acp:"text/csv",exec:"excel"},{name:"dat",group:"data",acp:"application/octet-stream",exec:"binaryviwer"},{name:"7z",group:"compress",acp:"application/x-7z-compressed",exec:"compressor"},{name:"bzip",group:"compress",acp:"application/x-bzip",exec:"7z"},{name:"bzip2",group:"compress",acp:"application/x-bzip2",exec:"compressor"},{name:"bz2",group:"compress",acp:"application/x-bzip2",exec:"compressor"},{name:"ace",group:"compress",acp:"application/x-ace-compressed",exec:"compressor"},{name:"Z",group:"compress",acp:"application/x-compress",exec:"compressor"},{name:"lzh",group:"compress",acp:"application/x-lzh-compressed",exec:"compressor"},{name:"lz",group:"compress",acp:"application/x-lzip",exec:"compressor"},{name:"rar",group:"compress",acp:"application/x-rar-compressed",exec:"compressor"},{name:"tar",group:"compress",acp:"application/x-tar",exec:"compressor"},{name:"ar",group:"compress",acp:"application/x-unix-archive",exec:"compressor"},{name:"zip",group:"compress",acp:"application/zip",exec:"compressor"},{name:"gz",group:"compress",acp:"application/gzip",exec:"compressor"},{name:"avro",group:"",acp:"application/avro",exec:""},{name:"dcm",group:"",acp:"application/dicom",exec:""},{name:"eps",group:"",acp:"application/eps",exec:""},{name:"epub",group:"",acp:"application/epub+zip",exec:""},{name:"class",group:"",acp:"application/java-vm",exec:""},{name:"mxf",group:"",acp:"application/mxf",exec:""},{name:"ogx",group:"",acp:"application/ogg",exec:""},{name:"pdf",group:"docums",acp:"application/pdf",exec:"acrobat"},{name:"pgp",group:"",acp:"application/pgp-encrypted",exec:""},{name:"ps",group:"",acp:"application/postscript",exec:""},{name:"ai",group:"",acp:"application/postscript",exec:""},{name:"rtf",group:"docums",acp:"application/rtf",exec:"word"},{name:"icc",group:"",acp:"application/vnd.iccprofile",exec:""},{name:"asf",group:"",acp:"application/vnd.ms-asf",exec:"",msg:"asf的acp可能為application/vnd.ms-asf或audio/x-ms-asf或video/x-ms-asf"},{name:"cab",group:"",acp:"application/vnd.ms-cab-compressed",exec:""},{name:"eot",group:"",acp:"application/vnd.ms-fontobject",exec:""},{name:"chm",group:"",acp:"application/vnd.ms-htmlhelp",exec:""},{name:"pst",group:"",acp:"application/vnd.ms-outlook",exec:""},{name:"odp",group:"docums",acp:"application/vnd.oasis.opendocument.presentation",exec:"powerpoint"},{name:"ods",group:"docums",acp:"application/vnd.oasis.opendocument.spreadsheet",exec:"excel"},{name:"odt",group:"docums",acp:"application/vnd.oasis.opendocument.text",exec:"word"},{name:"ppt",group:"docums",acp:"application/vnd.ms-powerpoint",exec:"powerpoint"},{name:"pptx",group:"docums",acp:"application/vnd.openxmlformats-officedocument.presentationml.presentation",exec:"powerpoint"},{name:"xls",group:"docums",acp:"application/vnd.ms-excel",exec:"excel"},{name:"xlsx",group:"docums",acp:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",exec:"excel"},{name:"doc",group:"docums",acp:"application/msword",exec:"word"},{name:"docx",group:"docums",acp:"application/vnd.openxmlformats-officedocument.wordprocessingml.document",exec:"word"},{name:"skp",group:"",acp:"application/vnd.sketchup.skp",exec:""},{name:"pcap",group:"",acp:"application/vnd.tcpdump.pcap",exec:""},{name:"wasm",group:"",acp:"application/wasm",exec:""},{name:"arrow",group:"",acp:"application/x-apache-arrow",exec:""},{name:"dmg",group:"",acp:"application/x-apple-diskimage",exec:""},{name:"arj",group:"",acp:"application/x-arj",exec:""},{name:"asar",group:"",acp:"application/x-asar",exec:""},{name:"blend",group:"",acp:"application/x-blender",exec:"blender"},{name:"cfb",group:"",acp:"application/x-cfb",exec:""},{name:"cpio",group:"",acp:"application/x-cpio",exec:""},{name:"deb",group:"",acp:"application/x-deb",exec:""},{name:"elf",group:"",acp:"application/x-elf",exec:""},{name:"shp",group:"",acp:"application/x-esri-shape",exec:""},{name:"crx",group:"",acp:"application/x-google-chrome-extension",exec:""},{name:"indd",group:"",acp:"application/x-indesign",exec:""},{name:"macho",group:"",acp:"application/x-mach-binary",exec:""},{name:"mie",group:"",acp:"application/x-mie",exec:""},{name:"mobi",group:"",acp:"application/x-mobipocket-ebook",exec:""},{name:"exe",group:"",acp:"application/x-msdownload",exec:""},{name:"nes",group:"",acp:"application/x-nintendo-nes-rom",exec:""},{name:"parquet",group:"",acp:"application/x-parquet",exec:""},{name:"rpm",group:"",acp:"application/x-rpm",exec:""},{name:"swf",group:"",acp:"application/x-shockwave-flash",exec:""},{name:"sqlite",group:"",acp:"application/x-sqlite3",exec:""},{name:"xpi",group:"",acp:"application/x-xpinstall",exec:""},{name:"xz",group:"",acp:"application/x-xz",exec:""},{name:"alias",group:"",acp:"application/x.apple.alias",exec:""},{name:"fbx",group:"",acp:"application/x.autodesk.fbx",exec:""},{name:"lnk",group:"",acp:"application/x.ms.shortcut",exec:""},{name:"zst",group:"",acp:"application/zstd",exec:""},{name:"aac",group:"audio",acp:"audio/aac",exec:"audioplayer"},{name:"aif",group:"audio",acp:"audio/aiff",exec:"audioplayer"},{name:"amr",group:"audio",acp:"audio/amr",exec:"audioplayer"},{name:"ape",group:"audio",acp:"audio/ape",exec:"audioplayer"},{name:"mid",group:"audio",acp:"audio/midi",exec:"audioplayer"},{name:"m4b",group:"audio",acp:"audio/mp4",exec:"audioplayer"},{name:"f4a",group:"audio",acp:"audio/mp4",exec:"audioplayer"},{name:"f4b",group:"audio",acp:"audio/mp4",exec:"audioplayer"},{name:"mp3",group:"audio",acp:"audio/mpeg",exec:"audioplayer"},{name:"mp2",group:"audio",acp:"audio/mpeg",exec:"audioplayer"},{name:"mp1",group:"audio",acp:"audio/mpeg",exec:"audioplayer"},{name:"oga",group:"audio",acp:"audio/ogg",exec:"audioplayer"},{name:"spx",group:"audio",acp:"audio/ogg",exec:"audioplayer"},{name:"ogg",group:"audio",acp:"audio/ogg",exec:"audioplayer"},{name:"opus",group:"audio",acp:"audio/opus",exec:"audioplayer"},{name:"qcp",group:"audio",acp:"audio/qcelp",exec:"audioplayer"},{name:"ac3",group:"audio",acp:"audio/vnd.dolby.dd-raw",exec:"audioplayer"},{name:"wav",group:"audio",acp:"audio/wav",exec:"audioplayer"},{name:"wv",group:"audio",acp:"audio/wavpack",exec:"audioplayer"},{name:"dsf",group:"audio",acp:"audio/x-dsf",exec:"audioplayer"},{name:"flac",group:"audio",acp:"audio/x-flac",exec:"audioplayer"},{name:"it",group:"audio",acp:"audio/x-it",exec:"audioplayer"},{name:"m4a",group:"audio",acp:"audio/x-m4a",exec:"audioplayer"},{name:"mpc",group:"audio",acp:"audio/x-musepack",exec:"audioplayer"},{name:"s3m",group:"audio",acp:"audio/x-s3m",exec:"audioplayer"},{name:"voc",group:"audio",acp:"audio/x-voc",exec:"audioplayer"},{name:"xm",group:"audio",acp:"audio/x-xm",exec:"audioplayer"},{name:"otf",group:"",acp:"font/otf",exec:""},{name:"ttf",group:"",acp:"font/ttf",exec:""},{name:"woff",group:"",acp:"font/woff",exec:""},{name:"woff2",group:"",acp:"font/woff2",exec:""},{name:"apng",group:"image",acp:"image/apng",exec:"imageviwer"},{name:"avif",group:"image",acp:"image/avif",exec:"imageviwer"},{name:"bmp",group:"image",acp:"image/bmp",exec:"imageviwer"},{name:"bpg",group:"image",acp:"image/bpg",exec:"imageviwer"},{name:"flif",group:"image",acp:"image/flif",exec:"imageviwer"},{name:"gif",group:"image",acp:"image/gif",exec:"imageviwer"},{name:"heic",group:"image",acp:"image/heif",exec:"imageviwer"},{name:"icns",group:"image",acp:"image/icns",exec:"imageviwer"},{name:"j2c",group:"image",acp:"image/j2c",exec:"imageviwer"},{name:"jls",group:"image",acp:"image/jls",exec:"imageviwer"},{name:"jp2",group:"image",acp:"image/jp2",exec:"imageviwer"},{name:"jpg",group:"image",acp:"image/jpeg",exec:"imageviwer"},{name:"jpm",group:"image",acp:"image/jpm",exec:"imageviwer"},{name:"jpx",group:"image",acp:"image/jpx",exec:"imageviwer"},{name:"jxl",group:"image",acp:"image/jxl",exec:"imageviwer"},{name:"ktx",group:"image",acp:"image/ktx",exec:"imageviwer"},{name:"mj2",group:"image",acp:"image/mj2",exec:"imageviwer"},{name:"png",group:"image",acp:"image/png",exec:"imageviwer"},{name:"tif",group:"image",acp:"image/tiff",exec:"imageviwer"},{name:"psd",group:"image",acp:"image/vnd.adobe.photoshop",exec:"imageviwer"},{name:"dwg",group:"image",acp:"image/vnd.dwg",exec:"imageviwer"},{name:"jxr",group:"image",acp:"image/vnd.ms-photo",exec:"imageviwer"},{name:"webp",group:"image",acp:"image/webp",exec:"imageviwer"},{name:"dng",group:"image",acp:"image/x-adobe-dng",exec:"imageviwer"},{name:"cr2",group:"image",acp:"image/x-canon-cr2",exec:"imageviwer"},{name:"cr3",group:"image",acp:"image/x-canon-cr3",exec:"imageviwer"},{name:"raf",group:"image",acp:"image/x-fujifilm-raf",exec:"imageviwer"},{name:"ico",group:"image",acp:"image/x-icon",exec:"imageviwer"},{name:"cur",group:"image",acp:"image/x-icon",exec:"imageviwer"},{name:"nef",group:"image",acp:"image/x-nikon-nef",exec:"imageviwer"},{name:"orf",group:"image",acp:"image/x-olympus-orf",exec:"imageviwer"},{name:"rw2",group:"image",acp:"image/x-panasonic-rw2",exec:"imageviwer"},{name:"arw",group:"image",acp:"image/x-sony-arw",exec:"imageviwer"},{name:"xcf",group:"image",acp:"image/x-xcf",exec:"imageviwer"},{name:"3mf",group:"",acp:"model/3mf",exec:""},{name:"glb",group:"",acp:"model/gltf-binary",exec:""},{name:"stl",group:"",acp:"model/stl",exec:""},{name:"vtp",group:"",acp:"model/vtp",exec:""},{name:"vtk",group:"",acp:"model/vtk",exec:""},{name:"vtu",group:"",acp:"model/vtu",exec:""},{name:"vti",group:"",acp:"model/vti",exec:""},{name:"vts",group:"",acp:"model/vts",exec:""},{name:"vtr",group:"",acp:"model/vtr",exec:""},{name:"ics",group:"",acp:"text/calendar",exec:""},{name:"vcf",group:"",acp:"text/vcard",exec:""},{name:"3gp",group:"video",acp:"video/3gpp",exec:"videoplayer"},{name:"3g2",group:"video",acp:"video/3gpp2",exec:"videoplayer"},{name:"m2p",group:"video",acp:"video/MP2P",exec:"videoplayer"},{name:"vob",group:"video",acp:"video/MP2P",exec:"videoplayer"},{name:"sub",group:"video",acp:"video/MP2P",exec:"videoplayer",msg:"與字幕檔衝突"},{name:"mts",group:"video",acp:"video/mp2t",exec:"videoplayer"},{name:"m4p",group:"video",acp:"video/mp4",exec:"videoplayer"},{name:"f4v",group:"video",acp:"video/mp4",exec:"videoplayer"},{name:"f4p",group:"video",acp:"video/mp4",exec:"videoplayer"},{name:"mp4",group:"video",acp:"video/mp4",exec:"videoplayer"},{name:"mpg",group:"video",acp:"video/mpeg",exec:"videoplayer",msg:"mpg可能為mpeg或video/MP1S或video/MP2S"},{name:"ogv",group:"video",acp:"video/ogg",exec:"videoplayer"},{name:"ogm",group:"video",acp:"video/ogg",exec:"videoplayer"},{name:"mov",group:"video",acp:"video/quicktime",exec:"videoplayer"},{name:"avi",group:"video",acp:"video/vnd.avi",exec:"videoplayer"},{name:"webm",group:"video",acp:"video/webm",exec:"videoplayer"},{name:"flv",group:"video",acp:"video/x-flv",exec:"videoplayer"},{name:"m4v",group:"video",acp:"video/x-m4v",exec:"videoplayer"},{name:"mkv",group:"video",acp:"video/x-matroska",exec:"videoplayer"}];function Ad(e=""){let t=null;return De(e)?(t=pd(hd,{name:e}),Ee(t)||(t=null)):t=hd,t}function md(e=""){if(""!==e&&"name"!==e&&"group"!==e&&"acp"!==e&&"exec"!==e)return[];let t=Ad();if(""===e)return t;let r={};return Er(t,function(t){let n=t[e];ke(r,n)||(r[n]=[]),r[n].push(t)}),r}function Id(e="*"){if("*"===e)return e;if(!xe(e)&&!Rr(e))return"*";"common"===e&&(e=["docums","compress","image","data"]);let t=md();function r(e){return Pr(xr(e,"acp"))}xe(e)&&(e=[e]);let n="";if(Rr(e)){let i=xr(e,function(e){return function(e){return r(pa(t,{group:e}))}(e)}),o=kr(i,xr(e,function(e){return r(pa(t,{name:e}))}));o=pa(o,fd),n=xo(o,",")}return n}function yd(e,t=1e3){(t=Mn(t))<=0&&(t=1e3);let r={},n=[];return Er(we(e,"files",[]),function(e,i){let o=e.size/1024/1024;o>t&&(r[i]=`file size[${o}]mb > ${t}mb`),n.push(e)}),{files:n,errs:r}}function vd(e,t,r){for(var n=-1,i=e.length;++n<i;){var o=e[n],a=t(o);if(null!=a&&(void 0===s?a==a&&!q(a):r(a,s)))var s=a,c=o}return c}function bd(e,t){return e<t}function wd(e){return e&&e.length?vd(e,cr,bd):void 0}function Bd(){return!function(){try{return"IntersectionObserver"in window}catch(e){return!1}}()||!function(){try{return"IntersectionObserverEntry"in window}catch(e){return!1}}()||!(function(){try{return"intersectionRatio"in window.IntersectionObserverEntry.prototype}catch(e){return!1}}()||va(window.IntersectionObserverEntry))}function Ed(e,t,r={}){if(!br(e))return Promise.reject("invalid ele");let n=yn().markmap,{Transformer:i,Markmap:o,loadCSS:a,loadJS:s}=n,c=e=>{let t=new i,{root:r,features:n}=t.transform(e),{styles:o,scripts:a}=t.getUsedAssets(n);return{root:r,features:n,styles:o,scripts:a}},{root:l,styles:u,scripts:f}=c(t);u&&a(u),f&&s(f,{getMarkmap:()=>n}),e.innerHTML="";let d=o.create(e,null,l);return d.transMarkdown=c,d}const Cd=e=>void 0===e||"auto"===e||"instant"===e||"smooth"===e;function xd(e,t){this.scrollLeft=e,this.scrollTop=t}const Dd=(e,t,r="cannot convert to dictionary.")=>`Failed to execute '${e}' on '${t}': ${r}`,Fd=(e,t,r)=>Dd(e,t,`The provided value '${r}' is not a valid enum value of type ScrollBehavior.`),Qd=(e,t,r)=>{var n;const i=`__SEAMLESS.BACKUP$${t}`;return e[i]||!e[t]||(null===(n=e[t])||void 0===n?void 0:n.__isPolyfill)||(e[i]=e[t]),e[i]||r},Sd=e=>{const t=typeof e;return null!==e&&("object"===t||"function"===t)},kd=e=>"scrollBehavior"in window.document.documentElement.style&&!0!==(null==e?void 0:e.forcePolyfill),Nd=e=>{Object.defineProperty(e,"__isPolyfill",{value:!0})},qd=(e,t)=>{Nd(t),[HTMLElement.prototype,SVGElement.prototype,Element.prototype].forEach(r=>{Qd(r,e),r[e]=t})},Md=e=>e.ownerDocument.scrollingElement||e.ownerDocument.documentElement;const Hd=e=>.5*(1-Math.cos(Math.PI*e));function Ld(){var e;let t;return t=(null===(e=window.performance)||void 0===e?void 0:e.now)?()=>window.performance.now():()=>window.Date.now(),Ld=t,t()}const Ud=e=>{const t=(Ld()-e.timeStamp)/(e.duration||500);if(t>1)return e.method(e.targetX,e.targetY),void e.callback();const r=(e.timingFunc||Hd)(t),n=e.startX+(e.targetX-e.startX)*r,i=e.startY+(e.targetY-e.startY)*r;e.method(n,i),e.rafId=window.requestAnimationFrame(()=>{Ud(e)})},Rd=e=>isFinite(e)?Number(e):0,Od=(e,t,r)=>{var n,i;if(!(e=>{var t;return null!==(t=e.isConnected)&&void 0!==t?t:!(e.ownerDocument&&1&e.ownerDocument.compareDocumentPosition(e))})(e))return;const o=e.scrollLeft,a=e.scrollTop,s=Rd(null!==(n=t.left)&&void 0!==n?n:o),c=Rd(null!==(i=t.top)&&void 0!==i?i:a);if(s===o&&c===a)return;const l=Qd(HTMLElement.prototype,"scroll",xd),u=Qd(Object.getPrototypeOf(e),"scroll",l).bind(e);if("smooth"!==t.behavior)return void u(s,c);const f=()=>{window.removeEventListener("wheel",g),window.removeEventListener("touchmove",g)},d=Object.assign(Object.assign({},r),{timeStamp:Ld(),startX:o,startY:a,targetX:s,targetY:c,rafId:0,method:u,callback:()=>{f();const t=9===e.nodeType;e.dispatchEvent(function(e){if("function"==typeof Event)return new Event("scrollend",{bubbles:e,cancelable:!1});const t=document.createEvent("Event");return t.initEvent("scrollend",e,!1),t}(t))}}),g=()=>{window.cancelAnimationFrame(d.rafId),f()};window.addEventListener("wheel",g,{passive:!0,once:!0}),window.addEventListener("touchmove",g,{passive:!0,once:!0}),Ud(d)},Td=e=>(t,r,n)=>{const[i,o]=(a=t).window===a?[Md(t.document.documentElement),"Window"]:[t,"Element"];var a;const s=null!=r?r:{};if(!Sd(s))throw new TypeError(Dd(e,o));if(!Cd(s.behavior))throw new TypeError(Fd(e,o,s.behavior));"scrollBy"===e&&(s.left=Rd(s.left)+i.scrollLeft,s.top=Rd(s.top)+i.scrollTop),Od(i,s,n)},Yd=Td("scroll"),jd=Td("scrollTo"),Gd=Td("scrollBy"),Jd=Yd,zd=e=>{switch(e){case"horizontal-tb":case"lr":case"lr-tb":case"rl":case"rl-tb":return 0;case"vertical-rl":case"tb":case"tb-rl":return 1;case"vertical-lr":case"tb-lr":return 2;case"sideways-rl":return 3;case"sideways-lr":return 4}return 0},Vd=(e,t,r,n)=>{let i=0;switch(t||(i^=2),e){case 0:i=i>>1|(1&i)<<1,[r,n]=[n,r];break;case 1:case 3:i^=1;break;case 4:i^=2}return[i,r,n]},Pd=e=>!(1&~Vd(zd(e.writingMode),"rtl"!==e.direction,void 0,void 0)[0]),Xd=(e,t,r,n,i,o,a)=>0!==e?e:i<t&&o>r||i>t&&o<r?null:i<=t&&a<=n||o>=r&&a>=n?2:o>r&&a<n||i<t&&a>n?3:null,_d=e=>"visible"!==e&&"clip"!==e,Wd=(e,t)=>(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth)&&(_d(t.overflowY)||_d(t.overflowX)||e===Md(e)),Kd=e=>{const t=e.parentNode,r=e.parentElement;if(null===r&&null!==t){if(11===t.nodeType)return t.host;if(9===t.nodeType)return(e=>{var t;try{return(null===(t=e.ownerDocument.defaultView)||void 0===t?void 0:t.frameElement)||null}catch(e){return null}})(e)}return r},$d=(e,t,r)=>e<t?t:e>r?r:e,Zd=(e,t,r)=>{switch(e){case 1:return(t+r)/2;case 3:return r;case 2:case 0:return t}},eg=(e,t)=>{var r,n,i;const o=null===(r=e.ownerDocument.defaultView)||void 0===r?void 0:r.visualViewport,[a,s,c,l]=e===Md(e)?[0,0,null!==(n=null==o?void 0:o.width)&&void 0!==n?n:e.clientWidth,null!==(i=null==o?void 0:o.height)&&void 0!==i?i:e.clientHeight]:[t.left,t.top,e.clientWidth,e.clientHeight],u=a+e.clientLeft,f=s+e.clientTop;return[f,u+c,f+l,u]},tg=(e,t)=>{const r=[];let n=e.ownerDocument,i=n.defaultView;if(!i)return r;const o=window.getComputedStyle(e),a="rtl"!==o.direction,s=zd(o.writingMode||o.getPropertyValue("-webkit-writing-mode")||o.getPropertyValue("-ms-writing-mode")),[c,l]=((e,t,r)=>{const[n,i,o]=Vd(t,r,e.block||"start",e.inline||"nearest");return[i,o].map((e,t)=>{switch(e){case"center":return 1;case"nearest":return 0;default:return"start"===e==!(n>>t&1)?2:3}})})(t,s,a);let[u,f,d,g]=((e,t,r)=>{const{top:n,right:i,bottom:o,left:a}=t,s=(c=e.ownerDocument,["scroll-margin","scroll-snap-margin"].filter(e=>e in c.documentElement.style)[0]);var c;if(!s)return[n,i,o,a];const l=e=>{const t=r.getPropertyValue(`${s}-${e}`);return parseInt(t,10)||0};return[n-l("top"),i+l("right"),o+l("bottom"),a-l("left")]})(e,e.getBoundingClientRect(),o);for(let o=Kd(e);null!==o;o=Kd(o)){if(n!==o.ownerDocument){if(n=o.ownerDocument,i=n.defaultView,!i)break;const{left:e,top:t}=o.getBoundingClientRect();u+=t,f+=e,d+=t,g+=e}const e=i.getComputedStyle(o);if("fixed"===e.position)break;if(!Wd(o,e))continue;const a=o.getBoundingClientRect(),[s,p,h,A]=eg(o,a),m=Xd(c,A,p,o.clientWidth,g,f,f-g),I=Xd(l,s,h,o.clientHeight,u,d,d-u),y=null===m?0:Zd(m,g,f)-Zd(m,A,p),v=null===I?0:Zd(I,u,d)-Zd(I,s,h),b=Pd(e)?$d(y,-o.scrollWidth+o.clientWidth-o.scrollLeft,-o.scrollLeft):$d(y,-o.scrollLeft,o.scrollWidth-o.clientWidth-o.scrollLeft),w=$d(v,-o.scrollTop,o.scrollHeight-o.clientHeight-o.scrollTop);r.push([o,{left:o.scrollLeft+b,top:o.scrollTop+w,behavior:t.behavior}]),u=Math.max(u-w,s),f=Math.min(f-b,p),d=Math.min(d-w,h),g=Math.max(g-b,A)}return r},rg=(e,t,r)=>{const n=t||{};if(!Cd(n.behavior))throw new TypeError(Fd("scrollIntoView","Element",n.behavior));tg(e,n).forEach(([e,t])=>{Jd(e,t,r)})},ng=(e,t)=>r=>{if(kd(r))return;const n={scroll:Yd,scrollTo:jd,scrollBy:Gd}[e];t(e,function(){const e=arguments;if(1===arguments.length)return void n(this,e[0],r);n(this,{left:e[0],top:e[1]})})},ig=ng("scroll",qd),og=ng("scrollTo",qd),ag=ng("scrollBy",qd),sg=(e,t)=>{Nd(t),Qd(window,e),window[e]=t},cg=ng("scroll",sg),lg=ng("scrollTo",sg),ug=ng("scrollBy",sg);function fg(e){rg(this,{block:null==e||e?"start":"end",inline:"nearest"})}const dg=e=>{if(kd(e))return;const t=Qd(window.HTMLElement.prototype,"scrollIntoView",fg);qd("scrollIntoView",function(){const r=arguments,n=r[0];1===r.length&&Sd(n)?rg(this,n,e):t.apply(this,r)})},gg=e=>{kd(e)||(ig(e),og(e),ag(e),dg(e),cg(e),lg(e),ug(e))};function pg(e,t,r){(void 0!==r&&!re(e[t],r)||void 0===r&&!(t in e))&&di(e,t,r)}function hg(e){return N(e)&&ft(e)}function Ag(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}function mg(e,t,r,n,i,o,a){var s=Ag(e,r),c=Ag(t,r),l=a.get(c);if(l)pg(e,r,l);else{var u,f=o?o(s,c,r+"",e,t,a):void 0,d=void 0===f;if(d){var g=v(c),p=!g&&ze(c),h=!g&&!p&&rt(c);f=c,g||p||h?v(s)?f=s:hg(s)?f=Sr(s):p?(d=!1,f=Bi(c,!0)):h?(d=!1,f=ki(c,!0)):f=[]:vr(c)||Ye(c)?(f=s,Ye(s)?f=hi(u=s,Ii(u)):U(s)&&!R(s)||(f=Hi(c))):d=!1}d&&(a.set(c,f),i(f,c,n,o,a),a.delete(c)),pg(e,r,f)}}function Ig(e,t,r,n,i){e!==t&&Me(t,function(o,a){if(i||(i=new At),U(o))mg(e,t,a,r,Ig,n,i);else{var s=n?n(Ag(e,a),o,a+"",e,t,i):void 0;void 0===s&&(s=o),pg(e,a,s)}},Ii)}var yg,vg=(yg=function(e,t,r){Ig(e,t,r)},Ra(function(e,t){var r=-1,n=t.length,i=n>1?t[n-1]:void 0,o=n>2?t[2]:void 0;for(i=yg.length>3&&"function"==typeof i?(n--,i):void 0,o&&dr(t[0],t[1],o)&&(i=n<3?void 0:i,n=1),e=Object(e);++r<n;){var a=t[r];a&&yg(e,a,r,i)}return e}));async function bg(e,t=null,r={}){let n=!0,i=null,o=ns();Ee(r)||(r={});let a=we(r,"disTouchMoveToHide",null);if(Bo(a)||(a=4),a=Zi(a),!br(e))return o.reject("eleImg is not a HTMLElement"),o;if(i=e,null!==t){if(!br(t))return o.reject("eleGroup is not a HTMLElement"),o;n=!1,i=t}if(!n){let e=dn(t.querySelectorAll("img"));if(0===e)return o.reject("eleGroup does not contain any img"),o;1===e&&(n=!0)}let s={button:!1,navbar:!1,title:!1,toolbar:{zoomIn:4,zoomOut:4,oneToOne:4,reset:4,prev:0,play:0,next:0,rotateLeft:4,rotateRight:4,flipHorizontal:4,flipVertical:4},tooltip:!1,movable:!0,zoomable:!0,rotatable:!0,scalable:!0,transition:!0,fullscreen:!1,keyboard:!0};n||(s=function(){let e={button:!1,navbar:!1,title:!1,toolbar:{zoomIn:4,zoomOut:4,oneToOne:4,reset:4,prev:0,play:0,next:0,rotateLeft:4,rotateRight:4,flipHorizontal:4,flipVertical:4},tooltip:!1,movable:!0,zoomable:!0,rotatable:!0,scalable:!0,transition:!0,fullscreen:!1,keyboard:!0};return e.navbar=!0,e.toolbar.prev=4,e.toolbar.next=4,e}()),s=vg(s,zi(r)),s.shown=function(){(async()=>{let e=null;await vs(()=>(e=l.viewer,br(e)));let t=!1,r=0,n=0,i=0;e.addEventListener("touchstart",e=>{let i=e.touches[0];r=i.clientX,n=i.clientY,((e,t)=>{let r=document.elementsFromPoint(e,t).find(e=>"IMG"===e.tagName);if(!br(r))return!0;let n=r?.classList?.contains("viewer-move");return!n})(r,n)&&(t=!0)},{passive:!1}),e.addEventListener("touchmove",e=>{if(!t)return;let o=e.touches[0],a=o.clientX,s=o.clientY,c=a-r,l=s-n,u=Math.sqrt(c*c+l*l);i+=u,r=o.clientX,n=o.clientY},{passive:!1}),e.addEventListener("touchend",e=>{t&&(i<a&&(e.preventDefault(),e.stopPropagation(),l.hide(!0)),t=!1,i=0)},{passive:!1}),e.addEventListener("touchcancel",e=>{t=!1,i=0})})().catch(e=>{console.log(e)})};let c=!1;s.hide=function(){c||(c=!0,l.hide(!0))},s.hidden=function(){l.destroy(),o.resolve("close")};let l=new(0,yn().Viewer)(i,s);return l.show(),o}function wg(e,t){let r=new MouseEvent(t,{view:window,bubbles:!0,cancelable:!0});e.dispatchEvent(r)}function Bg(e={}){let t=we(e,"kind","*"),r=we(e,"multiple");pn(r)||(r=!1);let n=we(e,"entireHierarchy");pn(n)||(n=!1),n&&!r&&(r=!0);let i=we(e,"sizeMbLimit");Se(i)||(i=1e3),i=Mn(i);let o=ns(),a="drf"+Hu(),s="GrpDomReadFile";Vf(`[name=${s}]`);let c=Id(t),l=`<div name="${s}" style="position:relative; width:0px; height:0px; overflow:hidden;"><input id="${a}" type="file" accept="${c}" ${r?"multiple":""} ${n?"webkitdirectory":""} style="opacity:0; position:absolute; top:-10000px; left:-10000px;"></div>`;zu(document.querySelector("body"),l);let u=ud("#"+a),f=!1;function d(e){f=!0;let t=yd(this,i);o.resolve(t),u.removeEventListener("change",d,!0),n||window.removeEventListener("focus",g),Vf(`[name=${s}]`)}function g(e){setTimeout(()=>{f||d()},300)}return u.addEventListener("change",d,!0),n||window.addEventListener("focus",g),wg(u,"click"),o}function Eg(e){if(!De(e))return!1;let t="YYYY-MM-DDTHH:mm:ss";return e===r(e,t).format(t)}In()&&function(){try{return new MouseEvent("MouseEventPolyfillTest"),!1}catch(e){}let e=function(e,t){t=t||{bubbles:!1,cancelable:!1};let r=document.createEvent("MouseEvent");return r.initMouseEvent(e,t.bubbles,t.cancelable,window,0,t.screenX||0,t.screenY||0,t.clientX||0,t.clientY||0,t.ctrlKey||!1,t.altKey||!1,t.shiftKey||!1,t.metaKey||!1,t.button||0,t.relatedTarget||null),r};e.prototype=Event.prototype,window.MouseEvent=e}();var Cg="top",xg="bottom",Dg="right",Fg="left",Qg="auto",Sg=[Cg,xg,Dg,Fg],kg="start",Ng="end",qg="viewport",Mg="popper",Hg=Sg.reduce(function(e,t){return e.concat([t+"-"+kg,t+"-"+Ng])},[]),Lg=[].concat(Sg,[Qg]).reduce(function(e,t){return e.concat([t,t+"-"+kg,t+"-"+Ng])},[]),Ug=["beforeRead","read","afterRead","beforeMain","main","afterMain","beforeWrite","write","afterWrite"];function Rg(e){return e?(e.nodeName||"").toLowerCase():null}function Og(e){if(null==e)return window;if("[object Window]"!==e.toString()){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Tg(e){return e instanceof Og(e).Element||e instanceof Element}function Yg(e){return e instanceof Og(e).HTMLElement||e instanceof HTMLElement}function jg(e){return"undefined"!=typeof ShadowRoot&&(e instanceof Og(e).ShadowRoot||e instanceof ShadowRoot)}var Gg={name:"applyStyles",enabled:!0,phase:"write",fn:function(e){var t=e.state;Object.keys(t.elements).forEach(function(e){var r=t.styles[e]||{},n=t.attributes[e]||{},i=t.elements[e];Yg(i)&&Rg(i)&&(Object.assign(i.style,r),Object.keys(n).forEach(function(e){var t=n[e];!1===t?i.removeAttribute(e):i.setAttribute(e,!0===t?"":t)}))})},effect:function(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow),function(){Object.keys(t.elements).forEach(function(e){var n=t.elements[e],i=t.attributes[e]||{},o=Object.keys(t.styles.hasOwnProperty(e)?t.styles[e]:r[e]).reduce(function(e,t){return e[t]="",e},{});Yg(n)&&Rg(n)&&(Object.assign(n.style,o),Object.keys(i).forEach(function(e){n.removeAttribute(e)}))})}},requires:["computeStyles"]};function Jg(e){return e.split("-")[0]}var zg=Math.max,Vg=Math.min,Pg=Math.round;function Xg(){var e=navigator.userAgentData;return null!=e&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(e){return e.brand+"/"+e.version}).join(" "):navigator.userAgent}function _g(){return!/^((?!chrome|android).)*safari/i.test(Xg())}function Wg(e,t,r){void 0===t&&(t=!1),void 0===r&&(r=!1);var n=e.getBoundingClientRect(),i=1,o=1;t&&Yg(e)&&(i=e.offsetWidth>0&&Pg(n.width)/e.offsetWidth||1,o=e.offsetHeight>0&&Pg(n.height)/e.offsetHeight||1);var a=(Tg(e)?Og(e):window).visualViewport,s=!_g()&&r,c=(n.left+(s&&a?a.offsetLeft:0))/i,l=(n.top+(s&&a?a.offsetTop:0))/o,u=n.width/i,f=n.height/o;return{width:u,height:f,top:l,right:c+u,bottom:l+f,left:c,x:c,y:l}}function Kg(e){var t=Wg(e),r=e.offsetWidth,n=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-n)<=1&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:n}}function $g(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&jg(r)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function Zg(e){return Og(e).getComputedStyle(e)}function ep(e){return["table","td","th"].indexOf(Rg(e))>=0}function tp(e){return((Tg(e)?e.ownerDocument:e.document)||window.document).documentElement}function rp(e){return"html"===Rg(e)?e:e.assignedSlot||e.parentNode||(jg(e)?e.host:null)||tp(e)}function np(e){return Yg(e)&&"fixed"!==Zg(e).position?e.offsetParent:null}function ip(e){for(var t=Og(e),r=np(e);r&&ep(r)&&"static"===Zg(r).position;)r=np(r);return r&&("html"===Rg(r)||"body"===Rg(r)&&"static"===Zg(r).position)?t:r||function(e){var t=/firefox/i.test(Xg());if(/Trident/i.test(Xg())&&Yg(e)&&"fixed"===Zg(e).position)return null;var r=rp(e);for(jg(r)&&(r=r.host);Yg(r)&&["html","body"].indexOf(Rg(r))<0;){var n=Zg(r);if("none"!==n.transform||"none"!==n.perspective||"paint"===n.contain||-1!==["transform","perspective"].indexOf(n.willChange)||t&&"filter"===n.willChange||t&&n.filter&&"none"!==n.filter)return r;r=r.parentNode}return null}(e)||t}function op(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function ap(e,t,r){return zg(e,Vg(t,r))}function sp(e){return Object.assign({},{top:0,right:0,bottom:0,left:0},e)}function cp(e,t){return t.reduce(function(t,r){return t[r]=e,t},{})}var lp={name:"arrow",enabled:!0,phase:"main",fn:function(e){var t,r=e.state,n=e.name,i=e.options,o=r.elements.arrow,a=r.modifiersData.popperOffsets,s=Jg(r.placement),c=op(s),l=[Fg,Dg].indexOf(s)>=0?"height":"width";if(o&&a){var u=function(e,t){return sp("number"!=typeof(e="function"==typeof e?e(Object.assign({},t.rects,{placement:t.placement})):e)?e:cp(e,Sg))}(i.padding,r),f=Kg(o),d="y"===c?Cg:Fg,g="y"===c?xg:Dg,p=r.rects.reference[l]+r.rects.reference[c]-a[c]-r.rects.popper[l],h=a[c]-r.rects.reference[c],A=ip(o),m=A?"y"===c?A.clientHeight||0:A.clientWidth||0:0,I=p/2-h/2,y=u[d],v=m-f[l]-u[g],b=m/2-f[l]/2+I,w=ap(y,b,v),B=c;r.modifiersData[n]=((t={})[B]=w,t.centerOffset=w-b,t)}},effect:function(e){var t=e.state,r=e.options.element,n=void 0===r?"[data-popper-arrow]":r;null!=n&&("string"!=typeof n||(n=t.elements.popper.querySelector(n)))&&$g(t.elements.popper,n)&&(t.elements.arrow=n)},requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function up(e){return e.split("-")[1]}var fp={top:"auto",right:"auto",bottom:"auto",left:"auto"};function dp(e){var t,r=e.popper,n=e.popperRect,i=e.placement,o=e.variation,a=e.offsets,s=e.position,c=e.gpuAcceleration,l=e.adaptive,u=e.roundOffsets,f=e.isFixed,d=a.x,g=void 0===d?0:d,p=a.y,h=void 0===p?0:p,A="function"==typeof u?u({x:g,y:h}):{x:g,y:h};g=A.x,h=A.y;var m=a.hasOwnProperty("x"),I=a.hasOwnProperty("y"),y=Fg,v=Cg,b=window;if(l){var w=ip(r),B="clientHeight",E="clientWidth";if(w===Og(r)&&"static"!==Zg(w=tp(r)).position&&"absolute"===s&&(B="scrollHeight",E="scrollWidth"),i===Cg||(i===Fg||i===Dg)&&o===Ng)v=xg,h-=(f&&w===b&&b.visualViewport?b.visualViewport.height:w[B])-n.height,h*=c?1:-1;if(i===Fg||(i===Cg||i===xg)&&o===Ng)y=Dg,g-=(f&&w===b&&b.visualViewport?b.visualViewport.width:w[E])-n.width,g*=c?1:-1}var C,x=Object.assign({position:s},l&&fp),D=!0===u?function(e,t){var r=e.x,n=e.y,i=t.devicePixelRatio||1;return{x:Pg(r*i)/i||0,y:Pg(n*i)/i||0}}({x:g,y:h},Og(r)):{x:g,y:h};return g=D.x,h=D.y,c?Object.assign({},x,((C={})[v]=I?"0":"",C[y]=m?"0":"",C.transform=(b.devicePixelRatio||1)<=1?"translate("+g+"px, "+h+"px)":"translate3d("+g+"px, "+h+"px, 0)",C)):Object.assign({},x,((t={})[v]=I?h+"px":"",t[y]=m?g+"px":"",t.transform="",t))}var gp={passive:!0};var pp={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:function(e){var t=e.state,r=e.instance,n=e.options,i=n.scroll,o=void 0===i||i,a=n.resize,s=void 0===a||a,c=Og(t.elements.popper),l=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&l.forEach(function(e){e.addEventListener("scroll",r.update,gp)}),s&&c.addEventListener("resize",r.update,gp),function(){o&&l.forEach(function(e){e.removeEventListener("scroll",r.update,gp)}),s&&c.removeEventListener("resize",r.update,gp)}},data:{}},hp={left:"right",right:"left",bottom:"top",top:"bottom"};function Ap(e){return e.replace(/left|right|bottom|top/g,function(e){return hp[e]})}var mp={start:"end",end:"start"};function Ip(e){return e.replace(/start|end/g,function(e){return mp[e]})}function yp(e){var t=Og(e);return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function vp(e){return Wg(tp(e)).left+yp(e).scrollLeft}function bp(e){var t=Zg(e),r=t.overflow,n=t.overflowX,i=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+i+n)}function wp(e){return["html","body","#document"].indexOf(Rg(e))>=0?e.ownerDocument.body:Yg(e)&&bp(e)?e:wp(rp(e))}function Bp(e,t){var r;void 0===t&&(t=[]);var n=wp(e),i=n===(null==(r=e.ownerDocument)?void 0:r.body),o=Og(n),a=i?[o].concat(o.visualViewport||[],bp(n)?n:[]):n,s=t.concat(a);return i?s:s.concat(Bp(rp(a)))}function Ep(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function Cp(e,t,r){return t===qg?Ep(function(e,t){var r=Og(e),n=tp(e),i=r.visualViewport,o=n.clientWidth,a=n.clientHeight,s=0,c=0;if(i){o=i.width,a=i.height;var l=_g();(l||!l&&"fixed"===t)&&(s=i.offsetLeft,c=i.offsetTop)}return{width:o,height:a,x:s+vp(e),y:c}}(e,r)):Tg(t)?function(e,t){var r=Wg(e,!1,"fixed"===t);return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}(t,r):Ep(function(e){var t,r=tp(e),n=yp(e),i=null==(t=e.ownerDocument)?void 0:t.body,o=zg(r.scrollWidth,r.clientWidth,i?i.scrollWidth:0,i?i.clientWidth:0),a=zg(r.scrollHeight,r.clientHeight,i?i.scrollHeight:0,i?i.clientHeight:0),s=-n.scrollLeft+vp(e),c=-n.scrollTop;return"rtl"===Zg(i||r).direction&&(s+=zg(r.clientWidth,i?i.clientWidth:0)-o),{width:o,height:a,x:s,y:c}}(tp(e)))}function xp(e,t,r,n){var i="clippingParents"===t?function(e){var t=Bp(rp(e)),r=["absolute","fixed"].indexOf(Zg(e).position)>=0&&Yg(e)?ip(e):e;return Tg(r)?t.filter(function(e){return Tg(e)&&$g(e,r)&&"body"!==Rg(e)}):[]}(e):[].concat(t),o=[].concat(i,[r]),a=o[0],s=o.reduce(function(t,r){var i=Cp(e,r,n);return t.top=zg(i.top,t.top),t.right=Vg(i.right,t.right),t.bottom=Vg(i.bottom,t.bottom),t.left=zg(i.left,t.left),t},Cp(e,a,n));return s.width=s.right-s.left,s.height=s.bottom-s.top,s.x=s.left,s.y=s.top,s}function Dp(e){var t,r=e.reference,n=e.element,i=e.placement,o=i?Jg(i):null,a=i?up(i):null,s=r.x+r.width/2-n.width/2,c=r.y+r.height/2-n.height/2;switch(o){case Cg:t={x:s,y:r.y-n.height};break;case xg:t={x:s,y:r.y+r.height};break;case Dg:t={x:r.x+r.width,y:c};break;case Fg:t={x:r.x-n.width,y:c};break;default:t={x:r.x,y:r.y}}var l=o?op(o):null;if(null!=l){var u="y"===l?"height":"width";switch(a){case kg:t[l]=t[l]-(r[u]/2-n[u]/2);break;case Ng:t[l]=t[l]+(r[u]/2-n[u]/2)}}return t}function Fp(e,t){void 0===t&&(t={});var r=t,n=r.placement,i=void 0===n?e.placement:n,o=r.strategy,a=void 0===o?e.strategy:o,s=r.boundary,c=void 0===s?"clippingParents":s,l=r.rootBoundary,u=void 0===l?qg:l,f=r.elementContext,d=void 0===f?Mg:f,g=r.altBoundary,p=void 0!==g&&g,h=r.padding,A=void 0===h?0:h,m=sp("number"!=typeof A?A:cp(A,Sg)),I=d===Mg?"reference":Mg,y=e.rects.popper,v=e.elements[p?I:d],b=xp(Tg(v)?v:v.contextElement||tp(e.elements.popper),c,u,a),w=Wg(e.elements.reference),B=Dp({reference:w,element:y,strategy:"absolute",placement:i}),E=Ep(Object.assign({},y,B)),C=d===Mg?E:w,x={top:b.top-C.top+m.top,bottom:C.bottom-b.bottom+m.bottom,left:b.left-C.left+m.left,right:C.right-b.right+m.right},D=e.modifiersData.offset;if(d===Mg&&D){var F=D[i];Object.keys(x).forEach(function(e){var t=[Dg,xg].indexOf(e)>=0?1:-1,r=[Cg,xg].indexOf(e)>=0?"y":"x";x[e]+=F[r]*t})}return x}function Qp(e,t){void 0===t&&(t={});var r=t,n=r.placement,i=r.boundary,o=r.rootBoundary,a=r.padding,s=r.flipVariations,c=r.allowedAutoPlacements,l=void 0===c?Lg:c,u=up(n),f=u?s?Hg:Hg.filter(function(e){return up(e)===u}):Sg,d=f.filter(function(e){return l.indexOf(e)>=0});0===d.length&&(d=f);var g=d.reduce(function(t,r){return t[r]=Fp(e,{placement:r,boundary:i,rootBoundary:o,padding:a})[Jg(r)],t},{});return Object.keys(g).sort(function(e,t){return g[e]-g[t]})}var Sp={name:"flip",enabled:!0,phase:"main",fn:function(e){var t=e.state,r=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var i=r.mainAxis,o=void 0===i||i,a=r.altAxis,s=void 0===a||a,c=r.fallbackPlacements,l=r.padding,u=r.boundary,f=r.rootBoundary,d=r.altBoundary,g=r.flipVariations,p=void 0===g||g,h=r.allowedAutoPlacements,A=t.options.placement,m=Jg(A),I=c||(m===A||!p?[Ap(A)]:function(e){if(Jg(e)===Qg)return[];var t=Ap(e);return[Ip(e),t,Ip(t)]}(A)),y=[A].concat(I).reduce(function(e,r){return e.concat(Jg(r)===Qg?Qp(t,{placement:r,boundary:u,rootBoundary:f,padding:l,flipVariations:p,allowedAutoPlacements:h}):r)},[]),v=t.rects.reference,b=t.rects.popper,w=new Map,B=!0,E=y[0],C=0;C<y.length;C++){var x=y[C],D=Jg(x),F=up(x)===kg,Q=[Cg,xg].indexOf(D)>=0,S=Q?"width":"height",k=Fp(t,{placement:x,boundary:u,rootBoundary:f,altBoundary:d,padding:l}),N=Q?F?Dg:Fg:F?xg:Cg;v[S]>b[S]&&(N=Ap(N));var q=Ap(N),M=[];if(o&&M.push(k[D]<=0),s&&M.push(k[N]<=0,k[q]<=0),M.every(function(e){return e})){E=x,B=!1;break}w.set(x,M)}if(B)for(var H=function(e){var t=y.find(function(t){var r=w.get(t);if(r)return r.slice(0,e).every(function(e){return e})});if(t)return E=t,"break"},L=p?3:1;L>0;L--){if("break"===H(L))break}t.placement!==E&&(t.modifiersData[n]._skip=!0,t.placement=E,t.reset=!0)}},requiresIfExists:["offset"],data:{_skip:!1}};function kp(e,t,r){return void 0===r&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function Np(e){return[Cg,Dg,xg,Fg].some(function(t){return e[t]>=0})}var qp={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:function(e){var t=e.state,r=e.options,n=e.name,i=r.offset,o=void 0===i?[0,0]:i,a=Lg.reduce(function(e,r){return e[r]=function(e,t,r){var n=Jg(e),i=[Fg,Cg].indexOf(n)>=0?-1:1,o="function"==typeof r?r(Object.assign({},t,{placement:e})):r,a=o[0],s=o[1];return a=a||0,s=(s||0)*i,[Fg,Dg].indexOf(n)>=0?{x:s,y:a}:{x:a,y:s}}(r,t.rects,o),e},{}),s=a[t.placement],c=s.x,l=s.y;null!=t.modifiersData.popperOffsets&&(t.modifiersData.popperOffsets.x+=c,t.modifiersData.popperOffsets.y+=l),t.modifiersData[n]=a}};var Mp={name:"preventOverflow",enabled:!0,phase:"main",fn:function(e){var t=e.state,r=e.options,n=e.name,i=r.mainAxis,o=void 0===i||i,a=r.altAxis,s=void 0!==a&&a,c=r.boundary,l=r.rootBoundary,u=r.altBoundary,f=r.padding,d=r.tether,g=void 0===d||d,p=r.tetherOffset,h=void 0===p?0:p,A=Fp(t,{boundary:c,rootBoundary:l,padding:f,altBoundary:u}),m=Jg(t.placement),I=up(t.placement),y=!I,v=op(m),b="x"===v?"y":"x",w=t.modifiersData.popperOffsets,B=t.rects.reference,E=t.rects.popper,C="function"==typeof h?h(Object.assign({},t.rects,{placement:t.placement})):h,x="number"==typeof C?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),D=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,F={x:0,y:0};if(w){if(o){var Q,S="y"===v?Cg:Fg,k="y"===v?xg:Dg,N="y"===v?"height":"width",q=w[v],M=q+A[S],H=q-A[k],L=g?-E[N]/2:0,U=I===kg?B[N]:E[N],R=I===kg?-E[N]:-B[N],O=t.elements.arrow,T=g&&O?Kg(O):{width:0,height:0},Y=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:{top:0,right:0,bottom:0,left:0},j=Y[S],G=Y[k],J=ap(0,B[N],T[N]),z=y?B[N]/2-L-J-j-x.mainAxis:U-J-j-x.mainAxis,V=y?-B[N]/2+L+J+G+x.mainAxis:R+J+G+x.mainAxis,P=t.elements.arrow&&ip(t.elements.arrow),X=P?"y"===v?P.clientTop||0:P.clientLeft||0:0,_=null!=(Q=null==D?void 0:D[v])?Q:0,W=q+V-_,K=ap(g?Vg(M,q+z-_-X):M,q,g?zg(H,W):H);w[v]=K,F[v]=K-q}if(s){var $,Z="x"===v?Cg:Fg,ee="x"===v?xg:Dg,te=w[b],re="y"===b?"height":"width",ne=te+A[Z],ie=te-A[ee],oe=-1!==[Cg,Fg].indexOf(m),ae=null!=($=null==D?void 0:D[b])?$:0,se=oe?ne:te-B[re]-E[re]-ae+x.altAxis,ce=oe?te+B[re]+E[re]-ae-x.altAxis:ie,le=g&&oe?function(e,t,r){var n=ap(e,t,r);return n>r?r:n}(se,te,ce):ap(g?se:ne,te,g?ce:ie);w[b]=le,F[b]=le-te}t.modifiersData[n]=F}},requiresIfExists:["offset"]};function Hp(e,t,r){void 0===r&&(r=!1);var n,i,o=Yg(t),a=Yg(t)&&function(e){var t=e.getBoundingClientRect(),r=Pg(t.width)/e.offsetWidth||1,n=Pg(t.height)/e.offsetHeight||1;return 1!==r||1!==n}(t),s=tp(t),c=Wg(e,a,r),l={scrollLeft:0,scrollTop:0},u={x:0,y:0};return(o||!o&&!r)&&(("body"!==Rg(t)||bp(s))&&(l=(n=t)!==Og(n)&&Yg(n)?{scrollLeft:(i=n).scrollLeft,scrollTop:i.scrollTop}:yp(n)),Yg(t)?((u=Wg(t,!0)).x+=t.clientLeft,u.y+=t.clientTop):s&&(u.x=vp(s))),{x:c.left+l.scrollLeft-u.x,y:c.top+l.scrollTop-u.y,width:c.width,height:c.height}}function Lp(e){var t=new Map,r=new Set,n=[];function i(e){r.add(e.name),[].concat(e.requires||[],e.requiresIfExists||[]).forEach(function(e){if(!r.has(e)){var n=t.get(e);n&&i(n)}}),n.push(e)}return e.forEach(function(e){t.set(e.name,e)}),e.forEach(function(e){r.has(e.name)||i(e)}),n}var Up={placement:"bottom",modifiers:[],strategy:"absolute"};function Rp(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return!t.some(function(e){return!(e&&"function"==typeof e.getBoundingClientRect)})}function Op(e){void 0===e&&(e={});var t=e,r=t.defaultModifiers,n=void 0===r?[]:r,i=t.defaultOptions,o=void 0===i?Up:i;return function(e,t,r){void 0===r&&(r=o);var i,a,s={placement:"bottom",orderedModifiers:[],options:Object.assign({},Up,o),modifiersData:{},elements:{reference:e,popper:t},attributes:{},styles:{}},c=[],l=!1,u={state:s,setOptions:function(r){var i="function"==typeof r?r(s.options):r;f(),s.options=Object.assign({},o,s.options,i),s.scrollParents={reference:Tg(e)?Bp(e):e.contextElement?Bp(e.contextElement):[],popper:Bp(t)};var a,l,d=function(e){var t=Lp(e);return Ug.reduce(function(e,r){return e.concat(t.filter(function(e){return e.phase===r}))},[])}((a=[].concat(n,s.options.modifiers),l=a.reduce(function(e,t){var r=e[t.name];return e[t.name]=r?Object.assign({},r,t,{options:Object.assign({},r.options,t.options),data:Object.assign({},r.data,t.data)}):t,e},{}),Object.keys(l).map(function(e){return l[e]})));return s.orderedModifiers=d.filter(function(e){return e.enabled}),s.orderedModifiers.forEach(function(e){var t=e.name,r=e.options,n=void 0===r?{}:r,i=e.effect;if("function"==typeof i){var o=i({state:s,name:t,instance:u,options:n}),a=function(){};c.push(o||a)}}),u.update()},forceUpdate:function(){if(!l){var e=s.elements,t=e.reference,r=e.popper;if(Rp(t,r)){s.rects={reference:Hp(t,ip(r),"fixed"===s.options.strategy),popper:Kg(r)},s.reset=!1,s.placement=s.options.placement,s.orderedModifiers.forEach(function(e){return s.modifiersData[e.name]=Object.assign({},e.data)});for(var n=0;n<s.orderedModifiers.length;n++)if(!0!==s.reset){var i=s.orderedModifiers[n],o=i.fn,a=i.options,c=void 0===a?{}:a,f=i.name;"function"==typeof o&&(s=o({state:s,options:c,name:f,instance:u})||s)}else s.reset=!1,n=-1}}},update:(i=function(){return new Promise(function(e){u.forceUpdate(),e(s)})},function(){return a||(a=new Promise(function(e){Promise.resolve().then(function(){a=void 0,e(i())})})),a}),destroy:function(){f(),l=!0}};if(!Rp(e,t))return u;function f(){c.forEach(function(e){return e()}),c=[]}return u.setOptions(r).then(function(e){!l&&r.onFirstUpdate&&r.onFirstUpdate(e)}),u}}var Tp=Op({defaultModifiers:[pp,{name:"popperOffsets",enabled:!0,phase:"read",fn:function(e){var t=e.state,r=e.name;t.modifiersData[r]=Dp({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})},data:{}},{name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:function(e){var t=e.state,r=e.options,n=r.gpuAcceleration,i=void 0===n||n,o=r.adaptive,a=void 0===o||o,s=r.roundOffsets,c=void 0===s||s,l={placement:Jg(t.placement),variation:up(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:i,isFixed:"fixed"===t.options.strategy};null!=t.modifiersData.popperOffsets&&(t.styles.popper=Object.assign({},t.styles.popper,dp(Object.assign({},l,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:a,roundOffsets:c})))),null!=t.modifiersData.arrow&&(t.styles.arrow=Object.assign({},t.styles.arrow,dp(Object.assign({},l,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:c})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})},data:{}},Gg,qp,Sp,Mp,lp,{name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:function(e){var t=e.state,r=e.name,n=t.rects.reference,i=t.rects.popper,o=t.modifiersData.preventOverflow,a=Fp(t,{elementContext:"reference"}),s=Fp(t,{altBoundary:!0}),c=kp(a,n),l=kp(s,i,o),u=Np(c),f=Np(l);t.modifiersData[r]={referenceClippingOffsets:c,popperEscapeOffsets:l,isReferenceHidden:u,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":u,"data-popper-escaped":f})}}]}),Yp="tippy-content",jp="tippy-arrow",Gp="tippy-svg-arrow",Jp={passive:!0,capture:!0},zp=function(){return document.body};function Vp(e,t,r){if(Array.isArray(e)){var n=e[t];return null==n?Array.isArray(r)?r[t]:r:n}return e}function Pp(e,t){var r={}.toString.call(e);return 0===r.indexOf("[object")&&r.indexOf(t+"]")>-1}function Xp(e,t){return"function"==typeof e?e.apply(void 0,t):e}function _p(e,t){return 0===t?e:function(n){clearTimeout(r),r=setTimeout(function(){e(n)},t)};var r}function Wp(e){return[].concat(e)}function Kp(e,t){-1===e.indexOf(t)&&e.push(t)}function $p(e){return[].slice.call(e)}function Zp(e){return Object.keys(e).reduce(function(t,r){return void 0!==e[r]&&(t[r]=e[r]),t},{})}function eh(){return document.createElement("div")}function th(e){return["Element","Fragment"].some(function(t){return Pp(e,t)})}function rh(e){return th(e)?[e]:function(e){return Pp(e,"NodeList")}(e)?$p(e):Array.isArray(e)?e:$p(document.querySelectorAll(e))}function nh(e,t){e.forEach(function(e){e&&(e.style.transitionDuration=t+"ms")})}function ih(e,t){e.forEach(function(e){e&&e.setAttribute("data-state",t)})}function oh(e,t,r){var n=t+"EventListener";["transitionend","webkitTransitionEnd"].forEach(function(t){e[n](t,r)})}function ah(e,t){for(var r=t;r;){var n;if(e.contains(r))return!0;r=null==r.getRootNode||null==(n=r.getRootNode())?void 0:n.host}return!1}var sh={isTouch:!1},ch=0;function lh(){sh.isTouch||(sh.isTouch=!0,window.performance&&document.addEventListener("mousemove",uh))}function uh(){var e=performance.now();e-ch<20&&(sh.isTouch=!1,document.removeEventListener("mousemove",uh)),ch=e}function fh(){var e,t=document.activeElement;if((e=t)&&e._tippy&&e._tippy.reference===e){var r=t._tippy;t.blur&&!r.state.isVisible&&t.blur()}}var dh,gh=!!("undefined"!=typeof window&&"undefined"!=typeof document)&&!!window.msCrypto;function ph(e){return[e+"() was called on a"+("destroy"===e?"n already-":" ")+"destroyed instance. This is a no-op but","indicates a potential memory leak."].join(" ")}function hh(e){return e.replace(/[ \t]{2,}/g," ").replace(/^[ \t]*/gm,"").trim()}function Ah(e){return hh("\n %ctippy.js\n\n %c"+hh(e)+"\n\n %c👷‍ This is a development-only message. It will be removed in production.\n ")}function mh(e){return[Ah(e),"color: #00C584; font-size: 1.3em; font-weight: bold;","line-height: 1.5","color: #a6a095;"]}function Ih(e,t){var r;e&&!dh.has(t)&&(dh.add(t),(r=console).warn.apply(r,mh(t)))}function yh(e,t){var r;e&&!dh.has(t)&&(dh.add(t),(r=console).error.apply(r,mh(t)))}dh=new Set;var vh={animateFill:!1,followCursor:!1,inlinePositioning:!1,sticky:!1},bh=Object.assign({appendTo:zp,aria:{content:"auto",expanded:"auto"},delay:0,duration:[300,250],getReferenceClientRect:null,hideOnClick:!0,ignoreAttributes:!1,interactive:!1,interactiveBorder:2,interactiveDebounce:0,moveTransition:"",offset:[0,10],onAfterUpdate:function(){},onBeforeUpdate:function(){},onCreate:function(){},onDestroy:function(){},onHidden:function(){},onHide:function(){},onMount:function(){},onShow:function(){},onShown:function(){},onTrigger:function(){},onUntrigger:function(){},onClickOutside:function(){},placement:"top",plugins:[],popperOptions:{},render:null,showOnCreate:!1,touch:!0,trigger:"mouseenter focus",triggerTarget:null},vh,{allowHTML:!1,animation:"fade",arrow:!0,content:"",inertia:!1,maxWidth:350,role:"tooltip",theme:"",zIndex:9999}),wh=Object.keys(bh);function Bh(e){var t=(e.plugins||[]).reduce(function(t,r){var n,i=r.name,o=r.defaultValue;i&&(t[i]=void 0!==e[i]?e[i]:null!=(n=bh[i])?n:o);return t},{});return Object.assign({},e,t)}function Eh(e,t){var r=Object.assign({},t,{content:Xp(t.content,[e])},t.ignoreAttributes?{}:function(e,t){return(t?Object.keys(Bh(Object.assign({},bh,{plugins:t}))):wh).reduce(function(t,r){var n=(e.getAttribute("data-tippy-"+r)||"").trim();if(!n)return t;if("content"===r)t[r]=n;else try{t[r]=JSON.parse(n)}catch(e){t[r]=n}return t},{})}(e,t.plugins));return r.aria=Object.assign({},bh.aria,r.aria),r.aria={expanded:"auto"===r.aria.expanded?t.interactive:r.aria.expanded,content:"auto"===r.aria.content?t.interactive?null:"describedby":r.aria.content},r}function Ch(e,t){void 0===e&&(e={}),void 0===t&&(t=[]),Object.keys(e).forEach(function(e){var r=function(e,t){var r=Object.assign({},e);return t.forEach(function(e){delete r[e]}),r}(bh,Object.keys(vh)),n=!function(e,t){return{}.hasOwnProperty.call(e,t)}(r,e);n&&(n=0===t.filter(function(t){return t.name===e}).length),Ih(n,["`"+e+"`","is not a valid prop. You may have spelled it incorrectly, or if it's","a plugin, forgot to pass it in an array as props.plugins.","\n\n","All props: https://atomiks.github.io/tippyjs/v6/all-props/\n","Plugins: https://atomiks.github.io/tippyjs/v6/plugins/"].join(" "))})}function xh(e,t){e.innerHTML=t}function Dh(e){var t=eh();return!0===e?t.className=jp:(t.className=Gp,th(e)?t.appendChild(e):xh(t,e)),t}function Fh(e,t){th(t.content)?(xh(e,""),e.appendChild(t.content)):"function"!=typeof t.content&&(t.allowHTML?xh(e,t.content):e.textContent=t.content)}function Qh(e){var t=e.firstElementChild,r=$p(t.children);return{box:t,content:r.find(function(e){return e.classList.contains(Yp)}),arrow:r.find(function(e){return e.classList.contains(jp)||e.classList.contains(Gp)}),backdrop:r.find(function(e){return e.classList.contains("tippy-backdrop")})}}function Sh(e){var t=eh(),r=eh();r.className="tippy-box",r.setAttribute("data-state","hidden"),r.setAttribute("tabindex","-1");var n=eh();function i(r,n){var i=Qh(t),o=i.box,a=i.content,s=i.arrow;n.theme?o.setAttribute("data-theme",n.theme):o.removeAttribute("data-theme"),"string"==typeof n.animation?o.setAttribute("data-animation",n.animation):o.removeAttribute("data-animation"),n.inertia?o.setAttribute("data-inertia",""):o.removeAttribute("data-inertia"),o.style.maxWidth="number"==typeof n.maxWidth?n.maxWidth+"px":n.maxWidth,n.role?o.setAttribute("role",n.role):o.removeAttribute("role"),r.content===n.content&&r.allowHTML===n.allowHTML||Fh(a,e.props),n.arrow?s?r.arrow!==n.arrow&&(o.removeChild(s),o.appendChild(Dh(n.arrow))):o.appendChild(Dh(n.arrow)):s&&o.removeChild(s)}return n.className=Yp,n.setAttribute("data-state","hidden"),Fh(n,e.props),t.appendChild(r),r.appendChild(n),i(e.props,e.props),{popper:t,onUpdate:i}}Sh.$$tippy=!0;var kh=1,Nh=[],qh=[];function Mh(e,t){var r,n,i,o,a,s,c,l,u=Eh(e,Object.assign({},bh,Bh(Zp(t)))),f=!1,d=!1,g=!1,p=!1,h=[],A=_p(P,u.interactiveDebounce),m=kh++,I=(l=u.plugins).filter(function(e,t){return l.indexOf(e)===t}),y={id:m,reference:e,popper:eh(),popperInstance:null,props:u,state:{isEnabled:!0,isVisible:!1,isDestroyed:!1,isMounted:!1,isShown:!1},plugins:I,clearDelayTimeouts:function(){clearTimeout(r),clearTimeout(n),cancelAnimationFrame(i)},setProps:function(t){if(Ih(y.state.isDestroyed,ph("setProps")),y.state.isDestroyed)return;q("onBeforeUpdate",[y,t]),z();var r=y.props,n=Eh(e,Object.assign({},r,Zp(t),{ignoreAttributes:!0}));y.props=n,J(),r.interactiveDebounce!==n.interactiveDebounce&&(L(),A=_p(P,n.interactiveDebounce));r.triggerTarget&&!n.triggerTarget?Wp(r.triggerTarget).forEach(function(e){e.removeAttribute("aria-expanded")}):n.triggerTarget&&e.removeAttribute("aria-expanded");H(),N(),w&&w(r,n);y.popperInstance&&(K(),Z().forEach(function(e){requestAnimationFrame(e._tippy.popperInstance.forceUpdate)}));q("onAfterUpdate",[y,t])},setContent:function(e){y.setProps({content:e})},show:function(){Ih(y.state.isDestroyed,ph("show"));var e=y.state.isVisible,t=y.state.isDestroyed,r=!y.state.isEnabled,n=sh.isTouch&&!y.props.touch,i=Vp(y.props.duration,0,bh.duration);if(e||t||r||n)return;if(F().hasAttribute("disabled"))return;if(q("onShow",[y],!1),!1===y.props.onShow(y))return;y.state.isVisible=!0,D()&&(b.style.visibility="visible");N(),T(),y.state.isMounted||(b.style.transition="none");if(D()){var o=S();nh([o.box,o.content],0)}s=function(){var e;if(y.state.isVisible&&!p){if(p=!0,b.offsetHeight,b.style.transition=y.props.moveTransition,D()&&y.props.animation){var t=S(),r=t.box,n=t.content;nh([r,n],i),ih([r,n],"visible")}M(),H(),Kp(qh,y),null==(e=y.popperInstance)||e.forceUpdate(),q("onMount",[y]),y.props.animation&&D()&&function(e,t){j(e,t)}(i,function(){y.state.isShown=!0,q("onShown",[y])})}},function(){var e,t=y.props.appendTo,r=F();e=y.props.interactive&&t===zp||"parent"===t?r.parentNode:Xp(t,[r]);e.contains(b)||e.appendChild(b);y.state.isMounted=!0,K(),Ih(y.props.interactive&&t===bh.appendTo&&r.nextElementSibling!==b,["Interactive tippy element may not be accessible via keyboard","navigation because it is not directly after the reference element","in the DOM source order.","\n\n","Using a wrapper <div> or <span> tag around the reference element","solves this by creating a new parentNode context.","\n\n","Specifying `appendTo: document.body` silences this warning, but it","assumes you are using a focus management solution to handle","keyboard navigation.","\n\n","See: https://atomiks.github.io/tippyjs/v6/accessibility/#interactivity"].join(" "))}()},hide:function(){Ih(y.state.isDestroyed,ph("hide"));var e=!y.state.isVisible,t=y.state.isDestroyed,r=!y.state.isEnabled,n=Vp(y.props.duration,1,bh.duration);if(e||t||r)return;if(q("onHide",[y],!1),!1===y.props.onHide(y))return;y.state.isVisible=!1,y.state.isShown=!1,p=!1,f=!1,D()&&(b.style.visibility="hidden");if(L(),Y(),N(!0),D()){var i=S(),o=i.box,a=i.content;y.props.animation&&(nh([o,a],n),ih([o,a],"hidden"))}M(),H(),y.props.animation?D()&&function(e,t){j(e,function(){!y.state.isVisible&&b.parentNode&&b.parentNode.contains(b)&&t()})}(n,y.unmount):y.unmount()},hideWithInteractivity:function(e){Ih(y.state.isDestroyed,ph("hideWithInteractivity")),Q().addEventListener("mousemove",A),Kp(Nh,A),A(e)},enable:function(){y.state.isEnabled=!0},disable:function(){y.hide(),y.state.isEnabled=!1},unmount:function(){Ih(y.state.isDestroyed,ph("unmount")),y.state.isVisible&&y.hide();if(!y.state.isMounted)return;$(),Z().forEach(function(e){e._tippy.unmount()}),b.parentNode&&b.parentNode.removeChild(b);qh=qh.filter(function(e){return e!==y}),y.state.isMounted=!1,q("onHidden",[y])},destroy:function(){if(Ih(y.state.isDestroyed,ph("destroy")),y.state.isDestroyed)return;y.clearDelayTimeouts(),y.unmount(),z(),delete e._tippy,y.state.isDestroyed=!0,q("onDestroy",[y])}};if(!u.render)return yh(!0,"render() function has not been supplied."),y;var v=u.render(y),b=v.popper,w=v.onUpdate;b.setAttribute("data-tippy-root",""),b.id="tippy-"+y.id,y.popper=b,e._tippy=y,b._tippy=y;var B=I.map(function(e){return e.fn(y)}),E=e.hasAttribute("aria-expanded");return J(),H(),N(),q("onCreate",[y]),u.showOnCreate&&ee(),b.addEventListener("mouseenter",function(){y.props.interactive&&y.state.isVisible&&y.clearDelayTimeouts()}),b.addEventListener("mouseleave",function(){y.props.interactive&&y.props.trigger.indexOf("mouseenter")>=0&&Q().addEventListener("mousemove",A)}),y;function C(){var e=y.props.touch;return Array.isArray(e)?e:[e,0]}function x(){return"hold"===C()[0]}function D(){var e;return!(null==(e=y.props.render)||!e.$$tippy)}function F(){return c||e}function Q(){var e,t,r=F().parentNode;return r?null!=(t=Wp(r)[0])&&null!=(e=t.ownerDocument)&&e.body?t.ownerDocument:document:document}function S(){return Qh(b)}function k(e){return y.state.isMounted&&!y.state.isVisible||sh.isTouch||o&&"focus"===o.type?0:Vp(y.props.delay,e?0:1,bh.delay)}function N(e){void 0===e&&(e=!1),b.style.pointerEvents=y.props.interactive&&!e?"":"none",b.style.zIndex=""+y.props.zIndex}function q(e,t,r){var n;(void 0===r&&(r=!0),B.forEach(function(r){r[e]&&r[e].apply(r,t)}),r)&&(n=y.props)[e].apply(n,t)}function M(){var t=y.props.aria;if(t.content){var r="aria-"+t.content,n=b.id;Wp(y.props.triggerTarget||e).forEach(function(e){var t=e.getAttribute(r);if(y.state.isVisible)e.setAttribute(r,t?t+" "+n:n);else{var i=t&&t.replace(n,"").trim();i?e.setAttribute(r,i):e.removeAttribute(r)}})}}function H(){!E&&y.props.aria.expanded&&Wp(y.props.triggerTarget||e).forEach(function(e){y.props.interactive?e.setAttribute("aria-expanded",y.state.isVisible&&e===F()?"true":"false"):e.removeAttribute("aria-expanded")})}function L(){Q().removeEventListener("mousemove",A),Nh=Nh.filter(function(e){return e!==A})}function U(t){if(!sh.isTouch||!g&&"mousedown"!==t.type){var r=t.composedPath&&t.composedPath()[0]||t.target;if(!y.props.interactive||!ah(b,r)){if(Wp(y.props.triggerTarget||e).some(function(e){return ah(e,r)})){if(sh.isTouch)return;if(y.state.isVisible&&y.props.trigger.indexOf("click")>=0)return}else q("onClickOutside",[y,t]);!0===y.props.hideOnClick&&(y.clearDelayTimeouts(),y.hide(),d=!0,setTimeout(function(){d=!1}),y.state.isMounted||Y())}}}function R(){g=!0}function O(){g=!1}function T(){var e=Q();e.addEventListener("mousedown",U,!0),e.addEventListener("touchend",U,Jp),e.addEventListener("touchstart",O,Jp),e.addEventListener("touchmove",R,Jp)}function Y(){var e=Q();e.removeEventListener("mousedown",U,!0),e.removeEventListener("touchend",U,Jp),e.removeEventListener("touchstart",O,Jp),e.removeEventListener("touchmove",R,Jp)}function j(e,t){var r=S().box;function n(e){e.target===r&&(oh(r,"remove",n),t())}if(0===e)return t();oh(r,"remove",a),oh(r,"add",n),a=n}function G(t,r,n){void 0===n&&(n=!1),Wp(y.props.triggerTarget||e).forEach(function(e){e.addEventListener(t,r,n),h.push({node:e,eventType:t,handler:r,options:n})})}function J(){var e;x()&&(G("touchstart",V,{passive:!0}),G("touchend",X,{passive:!0})),(e=y.props.trigger,e.split(/\s+/).filter(Boolean)).forEach(function(e){if("manual"!==e)switch(G(e,V),e){case"mouseenter":G("mouseleave",X);break;case"focus":G(gh?"focusout":"blur",_);break;case"focusin":G("focusout",_)}})}function z(){h.forEach(function(e){var t=e.node,r=e.eventType,n=e.handler,i=e.options;t.removeEventListener(r,n,i)}),h=[]}function V(e){var t,r=!1;if(y.state.isEnabled&&!W(e)&&!d){var n="focus"===(null==(t=o)?void 0:t.type);o=e,c=e.currentTarget,H(),!y.state.isVisible&&Pp(e,"MouseEvent")&&Nh.forEach(function(t){return t(e)}),"click"===e.type&&(y.props.trigger.indexOf("mouseenter")<0||f)&&!1!==y.props.hideOnClick&&y.state.isVisible?r=!0:ee(e),"click"===e.type&&(f=!r),r&&!n&&te(e)}}function P(e){var t=e.target,r=F().contains(t)||b.contains(t);if("mousemove"!==e.type||!r){var n=Z().concat(b).map(function(e){var t,r=null==(t=e._tippy.popperInstance)?void 0:t.state;return r?{popperRect:e.getBoundingClientRect(),popperState:r,props:u}:null}).filter(Boolean);(function(e,t){var r=t.clientX,n=t.clientY;return e.every(function(e){var t=e.popperRect,i=e.popperState,o=e.props.interactiveBorder,a=i.placement.split("-")[0],s=i.modifiersData.offset;if(!s)return!0;var c="bottom"===a?s.top.y:0,l="top"===a?s.bottom.y:0,u="right"===a?s.left.x:0,f="left"===a?s.right.x:0,d=t.top-n+c>o,g=n-t.bottom-l>o,p=t.left-r+u>o,h=r-t.right-f>o;return d||g||p||h})})(n,e)&&(L(),te(e))}}function X(e){W(e)||y.props.trigger.indexOf("click")>=0&&f||(y.props.interactive?y.hideWithInteractivity(e):te(e))}function _(e){y.props.trigger.indexOf("focusin")<0&&e.target!==F()||y.props.interactive&&e.relatedTarget&&b.contains(e.relatedTarget)||te(e)}function W(e){return!!sh.isTouch&&x()!==e.type.indexOf("touch")>=0}function K(){$();var t=y.props,r=t.popperOptions,n=t.placement,i=t.offset,o=t.getReferenceClientRect,a=t.moveTransition,c=D()?Qh(b).arrow:null,l=o?{getBoundingClientRect:o,contextElement:o.contextElement||F()}:e,u={name:"$$tippy",enabled:!0,phase:"beforeWrite",requires:["computeStyles"],fn:function(e){var t=e.state;if(D()){var r=S().box;["placement","reference-hidden","escaped"].forEach(function(e){"placement"===e?r.setAttribute("data-placement",t.placement):t.attributes.popper["data-popper-"+e]?r.setAttribute("data-"+e,""):r.removeAttribute("data-"+e)}),t.attributes.popper={}}}},f=[{name:"offset",options:{offset:i}},{name:"preventOverflow",options:{padding:{top:2,bottom:2,left:5,right:5}}},{name:"flip",options:{padding:5}},{name:"computeStyles",options:{adaptive:!a}},u];D()&&c&&f.push({name:"arrow",options:{element:c,padding:3}}),f.push.apply(f,(null==r?void 0:r.modifiers)||[]),y.popperInstance=Tp(l,b,Object.assign({},r,{placement:n,onFirstUpdate:s,modifiers:f}))}function $(){y.popperInstance&&(y.popperInstance.destroy(),y.popperInstance=null)}function Z(){return $p(b.querySelectorAll("[data-tippy-root]"))}function ee(e){y.clearDelayTimeouts(),e&&q("onTrigger",[y,e]),T();var t=k(!0),n=C(),i=n[0],o=n[1];sh.isTouch&&"hold"===i&&o&&(t=o),t?r=setTimeout(function(){y.show()},t):y.show()}function te(e){if(y.clearDelayTimeouts(),q("onUntrigger",[y,e]),y.state.isVisible){if(!(y.props.trigger.indexOf("mouseenter")>=0&&y.props.trigger.indexOf("click")>=0&&["mouseleave","mousemove"].indexOf(e.type)>=0&&f)){var t=k(!1);t?n=setTimeout(function(){y.state.isVisible&&y.hide()},t):i=requestAnimationFrame(function(){y.hide()})}}else Y()}}function Hh(e,t){void 0===t&&(t={});var r=bh.plugins.concat(t.plugins||[]);!function(e){var t=!e,r="[object Object]"===Object.prototype.toString.call(e)&&!e.addEventListener;yh(t,["tippy() was passed","`"+String(e)+"`","as its targets (first) argument. Valid types are: String, Element,","Element[], or NodeList."].join(" ")),yh(r,["tippy() was passed a plain object which is not supported as an argument","for virtual positioning. Use props.getReferenceClientRect instead."].join(" "))}(e),Ch(t,r),document.addEventListener("touchstart",lh,Jp),window.addEventListener("blur",fh);var n=Object.assign({},t,{plugins:r}),i=rh(e),o=th(n.content),a=i.length>1;Ih(o&&a,["tippy() was passed an Element as the `content` prop, but more than","one tippy instance was created by this invocation. This means the","content element will only be appended to the last tippy instance.","\n\n","Instead, pass the .innerHTML of the element, or use a function that","returns a cloned version of the element instead.","\n\n","1) content: element.innerHTML\n","2) content: () => element.cloneNode(true)"].join(" "));var s=i.reduce(function(e,t){var r=t&&Mh(t,n);return r&&e.push(r),e},[]);return th(e)?s[0]:s}function Lh(e,t){void 0===t&&(t={});var r=t.insertAt;if(e&&"undefined"!=typeof document){var n=document.head||document.getElementsByTagName("head")[0],i=document.createElement("style");i.type="text/css","top"===r&&n.firstChild?n.insertBefore(i,n.firstChild):n.appendChild(i),i.styleSheet?i.styleSheet.cssText=e:i.appendChild(document.createTextNode(e))}}Hh.defaultProps=bh,Hh.setDefaultProps=function(e){Ch(e,[]),Object.keys(e).forEach(function(t){bh[t]=e[t]})},Hh.currentInput=sh,Object.assign({},Gg,{effect:function(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow)}}),Hh.setDefaultProps({render:Sh});Lh('.tippy-box[data-animation=fade][data-state=hidden]{opacity:0}[data-tippy-root]{max-width:calc(100vw - 10px)}.tippy-box{position:relative;background-color:#333;color:#fff;border-radius:4px;font-size:14px;line-height:1.4;white-space:normal;outline:0;transition-property:transform,visibility,opacity}.tippy-box[data-placement^=top]>.tippy-arrow{bottom:0}.tippy-box[data-placement^=top]>.tippy-arrow:before{bottom:-7px;left:0;border-width:8px 8px 0;border-top-color:initial;transform-origin:center top}.tippy-box[data-placement^=bottom]>.tippy-arrow{top:0}.tippy-box[data-placement^=bottom]>.tippy-arrow:before{top:-7px;left:0;border-width:0 8px 8px;border-bottom-color:initial;transform-origin:center bottom}.tippy-box[data-placement^=left]>.tippy-arrow{right:0}.tippy-box[data-placement^=left]>.tippy-arrow:before{border-width:8px 0 8px 8px;border-left-color:initial;right:-7px;transform-origin:center left}.tippy-box[data-placement^=right]>.tippy-arrow{left:0}.tippy-box[data-placement^=right]>.tippy-arrow:before{left:-7px;border-width:8px 8px 8px 0;border-right-color:initial;transform-origin:center right}.tippy-box[data-inertia][data-state=visible]{transition-timing-function:cubic-bezier(.54,1.5,.38,1.11)}.tippy-arrow{width:16px;height:16px;color:#333}.tippy-arrow:before{content:"";position:absolute;border-color:transparent;border-style:solid}.tippy-content{position:relative;padding:5px 9px;z-index:1}');async function Uh(e,t={}){if(!va(e))throw new Error("invalid fun");let r=we(t,"width");r=De(r)?sa(r):Se(r)?Mn(r):null;let n=we(t,"height");n=De(n)?sa(n):Se(n)?Mn(n):null;let i=document.createElement("div");Se(r)&&(i.style.width=`${r}px`),Se(n)&&(i.style.height=`${n}px`);let o=document.createElement("div");o.style.position="absolute",o.style.top=0,o.style.left=0,o.style.zIndex=-1,o.appendChild(i);let a=document.createElement("div");a.style.position="relative",a.appendChild(o);let s,c=document.createElement("div");c.style.position="fixed",c.style.zIndex=-1,c.appendChild(a),Pf(document.querySelector("body"),c);let l=e(i);return s=ys(l)?await l:l,Vf(c),s}function Rh(e){if(!va(e))throw new Error("fn is not a function");return function(){let t=ns(),r=null,n=null;try{r=e.apply(this,arguments)}catch(e){n=e}return null!==n?t.resolve({state:"error",msg:n}):ys(r)?r.then(e=>{t.resolve({state:"success",msg:e})}).catch(e=>{"cancelled"===we(e,"reason")?t.resolve({state:"cancelled",msg:""}):t.resolve({state:"error",msg:e})}):t.resolve({state:"success",msg:r}),t}}Lh(".tippy-box[data-theme~=light]{color:#26323d;box-shadow:0 0 20px 4px rgba(154,161,177,.15),0 4px 80px -8px rgba(36,40,47,.25),0 4px 4px -2px rgba(91,94,105,.15);background-color:#fff}.tippy-box[data-theme~=light][data-placement^=top]>.tippy-arrow:before{border-top-color:#fff}.tippy-box[data-theme~=light][data-placement^=bottom]>.tippy-arrow:before{border-bottom-color:#fff}.tippy-box[data-theme~=light][data-placement^=left]>.tippy-arrow:before{border-left-color:#fff}.tippy-box[data-theme~=light][data-placement^=right]>.tippy-arrow:before{border-right-color:#fff}.tippy-box[data-theme~=light]>.tippy-backdrop{background-color:#fff}.tippy-box[data-theme~=light]>.tippy-svg-arrow{fill:#fff}");let Oh=Rh;function Th(e){if(!Hn(e))return!1;return Zi(e)<0}function Yh(e=0){let t=0,r=[];Th(e)&&(e=0),e=Zi(e);let n=Xi();return n.get=function(){if(r.length>0){return t+=1,r.splice(0,1)[0]}return null},n.cb=function(){t-=1,t<0&&(t=0),r.length>0&&n.emit("message",r)},n.push=function(i){r.push(i),(e<=0||t<e)&&n.emit("message",r)},n.clear=function(){t=0,r=[]},n}function jh(e=0,t=!1){return new function(e,t){let r=null;Bo(e)||(e=0),e=Zi(e),gn(t)||(t=!1);let n=Yh(e);return n.on("message",async function(e){let t=n.get();if(!t)return;await bs(1);let r,i=we(t,"id"),o=we(t,"fun"),a=we(t,"input");r=va(o)?await Oh(o)(...a):{state:"error",msg:"fun is not a function"},n.emit(i,r),n.cb()}),function(e,...i){let o=ns(),a=Hu();r=a;let s={id:a,fun:e,input:i};return n.push(s),n.once(a,e=>{t?a===r?"success"===e.state?o.resolve(e.msg):o.reject(e.msg):o.reject({reason:"cancelled"}):"success"===e.state?o.resolve(e.msg):o.reject(e.msg)}),o}}(e,t)}function Gh(e,t){In()?De(e)?Vu()?function(e,t){window.navigator.msSaveOrOpenBlob(t,e)}(e,t):function(e,t){let r=window.URL.createObjectURL(t),n=document.createElement("a");n.href=r,n.download=e,document.body.appendChild(n),n.click(),document.body.removeChild(n),window.URL.revokeObjectURL(r)}(e,t):console.log("no filename"):console.log("no window")}function Jh(e,t="data"){if(!Be(e))return{error:"sheet is not an object"};De(t)||(t="data");let r=Qu();return r.SheetNames.push(t),r.Sheets[t]=e,r}function zh(e,t="data"){if(!Ce(e)&&!br(e))return{error:"data is not an array or element"};De(t)||(t="data");let r=null,n=bn(e);return ke(n,"error")?n:(r=Jh(n,t),ke(r,"error"),r)}function Vh(e,t="data",r){if(!De(e)){let t="no filename";return console.log(t,e),{error:t}}if(De(t)||(t="data"),!Ce(r)&&!br(r)){let e="data is not an array or element";return console.log(e,r),{error:e}}Ce(r)&&Ee(we(r,0,null))&&(r=mn(r));let n=zh(r,t);if(we(n,"error"))return console.log(n.error),n.error;let i=vn();if(In()){let t=i.write(n,{bookType:"xlsx",bookSST:!1,type:"array"});Gh(e,new Blob([t]))}else try{i.writeFile(n,e)}catch(e){let t=`xl.writeFile failed: ${we(e,"message",e)}. 提示: 若於Node ESM環境單獨深度import此檔, xlsx ESM build的_fs未注入會擲此錯; 請改用 import { downloadExcelFileFromData } from 'wsemi' (走package main的UMD bundle, xlsx CJS自動載fs), 或於app entry手動呼叫 XLSX.set_fs(fs) 注入fs`;return console.log(t),t}return"ok"}function Ph(e){if(!Za(e))return new Blob;return new Blob([e])}function Xh(e,t,r=""){if(!Rr(t))return{};let n={};return Er(t,function(t){n[t]=we(e,t,r)}),n}function _h(e,t){if(!Be(e))return{};if(!Rr(t))return{};let r={};return Er(t,function(t){ke(e,t)&&(r[t]=we(e,t))}),r}function Wh(e,t=0,r={}){Bo(t)||(t=0),t=Zi(t);let n=we(r,"rounding","");return"ROUND_HALF_UP"!==n&&"ROUND_HALF_EVEN"!==n&&(n="ROUND_HALF_UP"),Se(e)?new il(e).toDecimalPlaces(t,il[n]).toNumber():""}function Kh(e,t={}){if(!Se(e))throw new Error("v is not a number");let r=we(t,"returnDigit");if(pn(r)||(r=!1),Hn(e))return r?0:Ya(e);let n=null,i=null;for(let t=1;t<=16;t++){let r=e*Math.pow(10,t);if(Math.abs(r-Math.round(r))<1e-9){n=t,i=al(e,t);break}}return null===i&&(n=16,i=Ya(e)),r?n:i}let $h=e=>{let t=1;e<0&&(t=-1);let r=null;if((e=Math.abs(e))<.1)for(let n=1;n<16;n++){let i=Math.pow(10,n);if((e*=i)<1){r={r:1/i,v:t*e};break}}else{if(e<1)return{r:1,v:t*e};if(e>=1)for(let n=1;n<16;n++){let i=Math.pow(10,n);if((e/=i)<1){r={r:i,v:t*e};break}}}if(null===r)throw new Error(`can not normalize v[${e}]`);return r};var Zh=a,eA=Zh.spawn,tA=Zh.exec;function rA(e,t,r){var n={};try{Object.keys(e).forEach(function(r){e[r].forEach(function(e){n[e]||(nA(e,t),n[e]=1)}),n[r]||(nA(r,t),n[r]=1)})}catch(e){if(r)return r(e);throw e}if(r)return r()}function nA(e,t){try{process.kill(parseInt(e,10),t)}catch(e){if("ESRCH"!==e.code)throw e}}function iA(e,t,r,n,i){var o=n(e),a="";o.stdout.on("data",function(e){e=e.toString("ascii");a+=e});o.on("close",function(o){delete r[e],0==o?a.match(/\d+/g).forEach(function(o){o=parseInt(o,10),t[e].push(o),t[o]=[],r[o]=1,iA(o,t,r,n,i)}):0==Object.keys(r).length&&i()})}var oA=Un(function(e,t,r){if("function"==typeof t&&void 0===r&&(r=t,t=void 0),e=parseInt(e),Number.isNaN(e)){if(r)return r(new Error("pid must be a number"));throw new Error("pid must be a number")}var n={},i={};switch(n[e]=[],i[e]=1,process.platform){case"win32":tA("taskkill /pid "+e+" /T /F",r);break;case"darwin":iA(e,n,i,function(e){return eA("pgrep",["-P",e])},function(){rA(n,t,r)});break;default:iA(e,n,i,function(e){return eA("ps",["-o","pid","--no-headers","--ppid",e])},function(){rA(n,t,r)})}});function aA(e){let t=ns();return oA(Number(e),"SIGKILL",r=>{r?t.reject(r):t.resolve(`pid[${e}] killed`)}),t}function sA(e,t){return e>t}function cA(e){return e&&e.length?vd(e,cr,sA):void 0}function lA(e){return null==e?[]:function(e,t){return pe(t,function(t){return e[t]})}(e,dt(e))}function uA(e,t,r,n){for(var i=-1,o=null==e?0:e.length;++i<o;){var a=e[i];t(n,a,r(a),e)}return n}function fA(e,t,r,n){return pt(e,function(e,i,o){t(n,e,r(e),o)}),n}var dA,gA,pA=Object.prototype.hasOwnProperty,hA=(dA=function(e,t,r){pA.call(e,r)?e[r].push(t):di(e,r,[t])},function(e,t){var r=v(e)?uA:fA,n=gA?gA():{};return r(e,dA,fr(t),n)}),AA=hA;function mA(e,t){if(!Ce(e)||!Ce(t))return[];if(e.length!==t.length)return[];return xr(e,function(r,n){return vg(e[n],t[n])})}function IA(e,t={}){let r=we(t,"fs"),n=!1;try{r.statSync(e),n=!0}catch{n=!1}return n}function yA(e,t={}){let r=we(t,"fs");return!!IA(e,{fs:r})&&(!r.lstatSync(e).isDirectory()&&!r.lstatSync(e).isSymbolicLink())}function vA(e){return yA(e,{fs:s})}function bA(e,t={}){let r=we(t,"fs");if(!IA(e,{fs:r}))return!1;let n=r.lstatSync(e);return!n.isFile()&&!n.isSymbolicLink()}function wA(e,t={}){let r=we(t,"fs");if(bA(e,{fs:r}))return{success:"input folder is already exists: "+e};if(IA(e,{fs:r}))return{error:"input path already exists: "+e};try{r.mkdirSync(e,{recursive:!0})}catch(e){return{error:e}}return{success:"done: "+e}}function BA(e,t={}){let r=we(t,"path"),n=we(t,"fs");if(!IA(e,{fs:n})){let t=wA(e,{fs:n});return t.error?t.error:{success:"done: "+e}}if(!bA(e,{fs:n}))return{error:"input path is not a folder"};try{let t=n.readdirSync(e);for(let i of t){let t=r.join(e,i);n.statSync(t).isDirectory()?n.rmSync(t,{recursive:!0,force:!0}):n.unlinkSync(t)}}catch(e){return{error:e}}return{success:"done: "+e}}function EA(e,t,r={}){let n=we(r,"path"),i=we(r,"fs"),o=we(r,"useSync","");pn(o)||(o=!0);let a="";return a=o?function(e,t,r={}){let n=we(r,"path"),i=we(r,"fs");if(!yA(e,{fs:i}))return{error:`fpSrc[${e}] is not a file`};try{wA(n.dirname(t),{fs:i}),i.copyFileSync(e,t)}catch(e){return{error:e}}return{success:"done: "+t}}(e,t,{path:n,fs:i}):async function(e,t,r={}){let n=we(r,"path"),i=we(r,"fs");if(!yA(e,{fs:i}))return{error:`fpSrc[${e}] is not a file`};let o=null;return await(async(e,t)=>{wA(n.dirname(t),{fs:i}),await new Promise((r,n)=>{let o=i.createReadStream(e),a=i.createWriteStream(t);o.on("error",n),a.on("error",n),a.on("finish",r),o.pipe(a)})})(e,t).then(()=>{o={success:"done: "+t}}).catch(e=>{o={error:e}}),o}(e,t,{path:n,fs:i}),a}function CA(e,t,r={}){let n=we(r,"path"),i=we(r,"fs");if(!bA(e,{fs:i}))return{error:`fpSrc[${e}] is not a folder`};try{i.readdirSync(e).forEach(function(r){let o=n.resolve(e,r),a=n.resolve(t,r),s=i.lstatSync(o);if(s.isDirectory())wA(a,{fs:i}),CA(o,a,{path:n,fs:i});else if(s.isSymbolicLink()){let e=i.readlinkSync(o);i.symlinkSync(e,a)}else wA(n.dirname(a),{fs:i}),i.copyFileSync(o,a)})}catch(e){return{error:e}}return{success:"done: "+t}}function xA(e,t,r={}){let n=we(r,"path"),i=we(r,"fs"),o=we(r,"useSync","");pn(o)||(o=!0);let a="";return a=o?CA(e,t,{path:n,fs:i}):async function(e,t,r={}){let n=we(r,"path"),i=we(r,"fs");if(!bA(e,{fs:i}))return{error:`fpSrc[${e}] is not a folder`};let o=async(e,t)=>{let r=i.readdirSync(e);for(let a of r){let r=n.join(e,a),s=n.join(t,a),c=i.lstatSync(r);if(c.isDirectory())wA(s,{fs:i}),await o(r,s);else if(c.isSymbolicLink()){let e=i.readlinkSync(r);i.symlinkSync(e,s)}else wA(n.dirname(s),{fs:i}),await new Promise((e,t)=>{let n=i.createReadStream(r),o=i.createWriteStream(s);n.on("error",t),o.on("error",t),o.on("finish",e),n.pipe(o)})}},a=null;return await o(e,t).then(()=>{a={success:"done: "+t}}).catch(e=>{a={error:e}}),a}(e,t,{path:n,fs:i}),a}function DA(e){if(!De(e))return{path:"",isRoot:!1};for(;e.indexOf("\\\\")>=0;)e=e.replace("\\\\","\\");for(;e.indexOf("//")>=0;)e=e.replace("//","/");if(":"===fa(e,1))return{path:`${e}\\`,isRoot:!0};if("\\"===fa(e,1)){let t=Ga(e,1);return":"===fa(t,1)?{path:e,isRoot:!0}:{path:t,isRoot:!1}}if("/"===fa(e,1)){let t=Ga(e,1);return 0===t.length?{path:e,isRoot:!0}:{path:t,isRoot:!1}}return{path:e,isRoot:!1}}function FA(e){if(!De(e))return"";let t=DA(e);if(t.isRoot)return t.path;let r=t.path;try{r=r.split("\\").pop().split("/").pop()}catch(e){}return r}function QA(e){if(!De(e))return"";let t=DA(e);if(t.isRoot)return t.path;let r=FA(e=t.path);if(!De(r))return e;let n=DA(e=Ga(e,r.length));return n.isRoot,n.path}function SA(e,t="",r={}){let n=we(r,"fs"),i=we(r,"encoding","");if(De(i)||(i="utf8"),IA(e,{fs:n}))return{error:"input path already exists: "+e};if(yA(e,{fs:n}))return{error:"input file is already exists: "+e};let o=QA(e);bA(o,{fs:n})||wA(o,{fs:n});try{n.writeFileSync(e,t,{encoding:i})}catch(e){return{error:e}}return{success:"done: "+e}}function kA(e){return wA(e,{fs:s})}function NA(e,t={}){let r=we(t,"fs");if(!IA(e,{fs:r}))return{success:"file does not exist: "+e};if(!yA(e,{fs:r}))return{error:"input path is not a file: "+e};try{r.unlinkSync(e)}catch(e){return{error:e}}return{success:"done: "+e}}async function qA(e,t={}){let r=we(t,"numRetry");eo(r)||(r=5),r=Zi(r);let n=we(t,"fs",null);if(!IA(e,{fs:n}))return"file does not exist: "+e;if(!yA(e,{fs:n}))return Promise.reject("input path is not a file: "+e);for(let t=0;t<r;t++)try{n.unlinkSync(e);break}catch(e){if("EBUSY"!==e.code)return Promise.reject(e);await bs(300)}return"done: "+e}function MA(e,t={}){let r=we(t,"fs");if(!IA(e,{fs:r}))return{success:"folder does not exist: "+e};if(!bA(e,{fs:r}))return{error:"input path is not a folder: "+e};try{r.rmSync(e,{recursive:!0,force:!0})}catch(e){return{error:e}}return{success:"done: "+e}}function HA(e){return MA(e,{fs:s})}async function LA(e,t={}){let r=we(t,"numRetry");eo(r)||(r=5),r=Zi(r);let n=we(t,"fs",null);if(!IA(e,{fs:n}))return"folder does not exist: "+e;if(!bA(e,{fs:n}))return Promise.reject("input path is not a folder: "+e);for(let t=0;t<r;t++)try{n.rmSync(e,{recursive:!0,force:!0});break}catch(e){if("EBUSY"!==e.code)return Promise.reject(e);await bs(300)}return"done: "+e}async function UA(e,t,r={}){let n="",i=we(r,"fs"),o=we(r,"Readable");if(!De(e))throw new Error("urlIn in not an effective string");let a=QA(t),s=we(r,"fnOut","");De(s)||(s=FA(t)),bA(a,{fs:i})||wA(a,{fs:i});let c=ns();try{let r=await fetch(e);if(!r.ok)return c.reject(r.statusText),c;let a=i.createWriteStream(t);o.fromWeb(r.body).pipe(a),a.on("finish",()=>{c.resolve(t)}),a.on("error",e=>{n=e.message,c.reject(n)})}catch(e){n=e.message,c.reject(n)}return c}function RA(){if(!va(r))throw new Error("invalid dayjs");return r().format("YYYY-MM-DDTHH:mm:ssZ")}function OA(e){if(!De(e))return"";let t=FA(e),r=Jo(t,".");if(dn(r)<=1)return t;let n="";try{r=zo(r),n=xo(r,".")}catch(e){}return n}function TA(e){return bA(e,{fs:s})}function YA(e,t={}){let r=we(t,"polling");pn(r)||(r=!1);let n=we(t,"timeInterval");eo(n)||(n=100),n=Zi(n);let o=we(t,"timeBinaryInterval");eo(o)||(o=300),o=Zi(o);let a=new u.EventEmitter,c=e,l=null,d=setInterval(()=>{if(null===l)TA(c)&&(l=f.watch(c,{usePolling:r,interval:n,binaryInterval:o,awaitWriteFinish:!0}),l.on("all",(e,t,r)=>{t=i.resolve(t),a.emit("change",{type:e,fp:t,stats:r}),"unlinkDir"===e&&i.resolve(c)===t&&setTimeout(()=>{g()},1)}));else if(!TA(c)){let e=s.fstatSync;a.emit("change",{type:"unlinkDir",fp:i.resolve(c),stats:e}),setTimeout(()=>{g()},1)}},n),g=()=>{if(null!==l){try{l.unwatch(c)}catch(e){console.log(e)}l.close().catch(e=>{console.log(e)}).finally(()=>{l=null})}};return a.clear=()=>{g(),clearInterval(d)},a}function jA(e,t={}){let r=we(t,"fs"),n=we(t,"crypto"),i=we(t,"type","");De(i)||(i="sha512");let o=ns();if(!yA(e,{fs:r}))return o.reject(`fp[${e}] is not a file`),o;try{let t=n.createHash(i),a=r.createReadStream(e);a.on("readable",()=>{let e=a.read();e?t.update(e):o.resolve(t.digest("hex"))}),a.on("error",e=>{o.reject(e.toString())})}catch(e){o.reject(e.toString())}return o}const GA=new Uint8Array([0,97,115,109,1,0,0,0,1,48,8,96,3,127,127,127,1,127,96,3,127,127,127,0,96,2,127,127,0,96,1,127,1,127,96,3,127,127,126,1,126,96,3,126,127,127,1,126,96,2,127,126,0,96,1,127,1,126,3,11,10,0,0,2,1,3,4,5,6,1,7,5,3,1,0,1,7,85,9,3,109,101,109,2,0,5,120,120,104,51,50,0,0,6,105,110,105,116,51,50,0,2,8,117,112,100,97,116,101,51,50,0,3,8,100,105,103,101,115,116,51,50,0,4,5,120,120,104,54,52,0,5,6,105,110,105,116,54,52,0,7,8,117,112,100,97,116,101,54,52,0,8,8,100,105,103,101,115,116,54,52,0,9,10,251,22,10,242,1,1,4,127,32,0,32,1,106,33,3,32,1,65,16,79,4,127,32,3,65,16,107,33,6,32,2,65,168,136,141,161,2,106,33,3,32,2,65,137,235,208,208,7,107,33,4,32,2,65,207,140,162,142,6,106,33,5,3,64,32,3,32,0,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,3,32,4,32,0,65,4,106,34,0,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,4,32,2,32,0,65,4,106,34,0,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,2,32,5,32,0,65,4,106,34,0,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,5,32,6,32,0,65,4,106,34,0,79,13,0,11,32,2,65,12,119,32,5,65,18,119,106,32,4,65,7,119,106,32,3,65,1,119,106,5,32,2,65,177,207,217,178,1,106,11,32,1,106,32,0,32,1,65,15,113,16,1,11,146,1,0,32,1,32,2,106,33,2,3,64,32,1,65,4,106,32,2,75,69,4,64,32,0,32,1,40,2,0,65,189,220,202,149,124,108,106,65,17,119,65,175,214,211,190,2,108,33,0,32,1,65,4,106,33,1,12,1,11,11,3,64,32,1,32,2,79,69,4,64,32,0,32,1,45,0,0,65,177,207,217,178,1,108,106,65,11,119,65,177,243,221,241,121,108,33,0,32,1,65,1,106,33,1,12,1,11,11,32,0,32,0,65,15,118,115,65,247,148,175,175,120,108,34,0,65,13,118,32,0,115,65,189,220,202,149,124,108,34,0,65,16,118,32,0,115,11,63,0,32,0,65,8,106,32,1,65,168,136,141,161,2,106,54,2,0,32,0,65,12,106,32,1,65,137,235,208,208,7,107,54,2,0,32,0,65,16,106,32,1,54,2,0,32,0,65,20,106,32,1,65,207,140,162,142,6,106,54,2,0,11,195,4,1,6,127,32,1,32,2,106,33,6,32,0,65,24,106,33,4,32,0,65,40,106,40,2,0,33,3,32,0,32,0,40,2,0,32,2,106,54,2,0,32,0,65,4,106,34,5,32,5,40,2,0,32,2,65,16,79,32,0,40,2,0,65,16,79,114,114,54,2,0,32,2,32,3,106,65,16,73,4,64,32,3,32,4,106,32,1,32,2,252,10,0,0,32,0,65,40,106,32,2,32,3,106,54,2,0,15,11,32,3,4,64,32,3,32,4,106,32,1,65,16,32,3,107,34,2,252,10,0,0,32,0,65,8,106,34,3,32,3,40,2,0,32,4,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,54,2,0,32,0,65,12,106,34,3,32,3,40,2,0,32,4,65,4,106,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,54,2,0,32,0,65,16,106,34,3,32,3,40,2,0,32,4,65,8,106,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,54,2,0,32,0,65,20,106,34,3,32,3,40,2,0,32,4,65,12,106,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,54,2,0,32,0,65,40,106,65,0,54,2,0,32,1,32,2,106,33,1,11,32,1,32,6,65,16,107,77,4,64,32,6,65,16,107,33,8,32,0,65,8,106,40,2,0,33,2,32,0,65,12,106,40,2,0,33,3,32,0,65,16,106,40,2,0,33,5,32,0,65,20,106,40,2,0,33,7,3,64,32,2,32,1,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,2,32,3,32,1,65,4,106,34,1,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,3,32,5,32,1,65,4,106,34,1,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,5,32,7,32,1,65,4,106,34,1,40,2,0,65,247,148,175,175,120,108,106,65,13,119,65,177,243,221,241,121,108,33,7,32,8,32,1,65,4,106,34,1,79,13,0,11,32,0,65,8,106,32,2,54,2,0,32,0,65,12,106,32,3,54,2,0,32,0,65,16,106,32,5,54,2,0,32,0,65,20,106,32,7,54,2,0,11,32,1,32,6,73,4,64,32,4,32,1,32,6,32,1,107,34,1,252,10,0,0,32,0,65,40,106,32,1,54,2,0,11,11,97,1,1,127,32,0,65,16,106,40,2,0,33,1,32,0,65,4,106,40,2,0,4,127,32,1,65,12,119,32,0,65,20,106,40,2,0,65,18,119,106,32,0,65,12,106,40,2,0,65,7,119,106,32,0,65,8,106,40,2,0,65,1,119,106,5,32,1,65,177,207,217,178,1,106,11,32,0,40,2,0,106,32,0,65,24,106,32,0,65,40,106,40,2,0,16,1,11,255,3,2,3,126,1,127,32,0,32,1,106,33,6,32,1,65,32,79,4,126,32,6,65,32,107,33,6,32,2,66,214,235,130,238,234,253,137,245,224,0,124,33,3,32,2,66,177,169,172,193,173,184,212,166,61,125,33,4,32,2,66,249,234,208,208,231,201,161,228,225,0,124,33,5,3,64,32,3,32,0,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,3,32,4,32,0,65,8,106,34,0,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,4,32,2,32,0,65,8,106,34,0,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,2,32,5,32,0,65,8,106,34,0,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,5,32,6,32,0,65,8,106,34,0,79,13,0,11,32,2,66,12,137,32,5,66,18,137,124,32,4,66,7,137,124,32,3,66,1,137,124,32,3,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,32,4,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,32,2,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,32,5,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,5,32,2,66,197,207,217,178,241,229,186,234,39,124,11,32,1,173,124,32,0,32,1,65,31,113,16,6,11,134,2,0,32,1,32,2,106,33,2,3,64,32,2,32,1,65,8,106,79,4,64,32,1,41,3,0,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,32,0,133,66,27,137,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,33,0,32,1,65,8,106,33,1,12,1,11,11,32,1,65,4,106,32,2,77,4,64,32,0,32,1,53,2,0,66,135,149,175,175,152,182,222,155,158,127,126,133,66,23,137,66,207,214,211,190,210,199,171,217,66,126,66,249,243,221,241,153,246,153,171,22,124,33,0,32,1,65,4,106,33,1,11,3,64,32,1,32,2,73,4,64,32,0,32,1,49,0,0,66,197,207,217,178,241,229,186,234,39,126,133,66,11,137,66,135,149,175,175,152,182,222,155,158,127,126,33,0,32,1,65,1,106,33,1,12,1,11,11,32,0,32,0,66,33,136,133,66,207,214,211,190,210,199,171,217,66,126,34,0,32,0,66,29,136,133,66,249,243,221,241,153,246,153,171,22,126,34,0,32,0,66,32,136,133,11,77,0,32,0,65,8,106,32,1,66,214,235,130,238,234,253,137,245,224,0,124,55,3,0,32,0,65,16,106,32,1,66,177,169,172,193,173,184,212,166,61,125,55,3,0,32,0,65,24,106,32,1,55,3,0,32,0,65,32,106,32,1,66,249,234,208,208,231,201,161,228,225,0,124,55,3,0,11,244,4,2,3,127,4,126,32,1,32,2,106,33,5,32,0,65,40,106,33,4,32,0,65,200,0,106,40,2,0,33,3,32,0,32,0,41,3,0,32,2,173,124,55,3,0,32,2,32,3,106,65,32,73,4,64,32,3,32,4,106,32,1,32,2,252,10,0,0,32,0,65,200,0,106,32,2,32,3,106,54,2,0,15,11,32,3,4,64,32,3,32,4,106,32,1,65,32,32,3,107,34,2,252,10,0,0,32,0,65,8,106,34,3,32,3,41,3,0,32,4,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,55,3,0,32,0,65,16,106,34,3,32,3,41,3,0,32,4,65,8,106,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,55,3,0,32,0,65,24,106,34,3,32,3,41,3,0,32,4,65,16,106,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,55,3,0,32,0,65,32,106,34,3,32,3,41,3,0,32,4,65,24,106,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,55,3,0,32,0,65,200,0,106,65,0,54,2,0,32,1,32,2,106,33,1,11,32,1,65,32,106,32,5,77,4,64,32,5,65,32,107,33,2,32,0,65,8,106,41,3,0,33,6,32,0,65,16,106,41,3,0,33,7,32,0,65,24,106,41,3,0,33,8,32,0,65,32,106,41,3,0,33,9,3,64,32,6,32,1,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,6,32,7,32,1,65,8,106,34,1,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,7,32,8,32,1,65,8,106,34,1,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,8,32,9,32,1,65,8,106,34,1,41,3,0,66,207,214,211,190,210,199,171,217,66,126,124,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,33,9,32,2,32,1,65,8,106,34,1,79,13,0,11,32,0,65,8,106,32,6,55,3,0,32,0,65,16,106,32,7,55,3,0,32,0,65,24,106,32,8,55,3,0,32,0,65,32,106,32,9,55,3,0,11,32,1,32,5,73,4,64,32,4,32,1,32,5,32,1,107,34,1,252,10,0,0,32,0,65,200,0,106,32,1,54,2,0,11,11,188,2,1,5,126,32,0,65,24,106,41,3,0,33,1,32,0,41,3,0,34,2,66,32,90,4,126,32,0,65,8,106,41,3,0,34,3,66,1,137,32,0,65,16,106,41,3,0,34,4,66,7,137,124,32,1,66,12,137,32,0,65,32,106,41,3,0,34,5,66,18,137,124,124,32,3,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,32,4,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,32,1,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,32,5,66,207,214,211,190,210,199,171,217,66,126,66,31,137,66,135,149,175,175,152,182,222,155,158,127,126,133,66,135,149,175,175,152,182,222,155,158,127,126,66,157,163,181,234,131,177,141,138,250,0,125,5,32,1,66,197,207,217,178,241,229,186,234,39,124,11,32,2,124,32,0,65,40,106,32,2,66,31,131,167,16,6,11]);async function JA(){return function(e){const{exports:{mem:t,xxh32:r,xxh64:n,init32:i,update32:o,digest32:a,init64:s,update64:c,digest64:l}}=e;let u=new Uint8Array(t.buffer);function f(e,r){if(t.buffer.byteLength<e+r){const n=Math.ceil((e+r-t.buffer.byteLength)/65536);t.grow(n),u=new Uint8Array(t.buffer)}}function d(e,t,r,n,i,o){f(e);const a=new Uint8Array(e);return u.set(a),r(0,t),a.set(u.subarray(0,e)),{update(t){let r;return u.set(a),"string"==typeof t?(f(3*t.length,e),r=A.encodeInto(t,u.subarray(e)).written):(f(t.byteLength,e),u.set(t,e),r=t.byteLength),n(0,e,r),a.set(u.subarray(0,e)),this},digest:()=>(u.set(a),o(i(0)))}}function g(e){return e>>>0}const p=2n**64n-1n;function h(e){return e&p}const A=new TextEncoder;function m(e,t=0){return f(3*e.length,0),g(r(0,A.encodeInto(e,u).written,t))}function I(e,t=0n){return f(3*e.length,0),h(n(0,A.encodeInto(e,u).written,t))}return{h32:m,h32ToString:(e,t=0)=>m(e,t).toString(16).padStart(8,"0"),h32Raw:(e,t=0)=>(f(e.byteLength,0),u.set(e),g(r(0,e.byteLength,t))),create32:(e=0)=>d(48,e,i,o,a,g),h64:I,h64ToString:(e,t=0n)=>I(e,t).toString(16).padStart(16,"0"),h64Raw:(e,t=0n)=>(f(e.byteLength,0),u.set(e),h(n(0,e.byteLength,t))),create64:(e=0n)=>d(88,e,s,c,l,h)}}((await WebAssembly.instantiate(GA)).instance)}async function zA(e,t={}){let r=we(t,"fs"),n=we(t,"chunkSize");if(Se(n)||(n=67108864),n=Mn(n),!yA(e,{fs:r}))return Promise.reject("fp is not a file");let i=ns();try{let{create64:t}=await JA(),o=t(),a=r.createReadStream(e,{highWaterMark:n});a.on("data",e=>{o.update(e)}),a.on("end",()=>{let e=o.digest().toString(16).padStart(16,"0");i.resolve(e)}),a.on("error",i.reject)}catch(e){i.reject(e.toString())}return i}function VA(e,t={}){let r=we(t,"fs"),n=we(t,"crypto"),i=we(t,"type","");De(i)||(i="sha512");let o=we(t,"chunkSize");Se(o)||(o=67108864),o=Mn(o);let a=ns();return yA(e,{fs:r})?"xxhash64"===i?zA(e,{fs:r,chunkSize:o}):jA(e,{fs:r,crypto:n,type:i}):(a.reject(`fp[${e}] is not a file`),a)}function PA(e,t=1,r={}){let n=1,i=we(r,"path"),o=we(r,"fs");if(!bA(e,{fs:o}))throw new Error(`fd[${e}] is not a folder`);return null!==t&&eo(t)&&(t=Zi(t))<1&&(t=1),function e(r){let a=[];return bA(r,{fs:o})?(Er(o.readdirSync(r),function(s){let c=i.resolve(r,s),l=null;try{l=o.statSync(c)}catch(e){}l&&l.isDirectory()?(a.push({isFolder:!0,level:n,path:c,name:i.basename(c)}),n+=1,(n<=t||null===t)&&(a=a.concat(e(c))),n-=1):a.push({isFolder:!1,level:n,path:c,name:i.basename(c)})}),a):a}(e)}function XA(e,t=1,r={}){let n=we(r,"path"),i=we(r,"fs");if(!bA(e,{fs:i}))throw new Error(`fd[${e}] is not a folder`);let o=[];return o=PA(e,t,{path:n,fs:i}),o=pa(o,{isFolder:!1}),o=xr(o,e=>(delete e.isFolder,e)),o}async function _A(e,t=1,r={}){let n=we(r,"path"),i=we(r,"fs"),o=we(r,"crypto"),a=we(r,"type","");if(De(a)||(a="md5"),!bA(e,{fs:i}))throw new Error(`fd[${e}] is not a folder`);let s=XA(e,t,{path:n,fs:i});return s=await cl(s,async e=>{let t=we(e,"path","");return e.hashType=a,e.hash="",De(t)&&(e.hash=await VA(t,{fs:i,crypto:o,type:a,useSync:!1})),e}),s}async function WA(e,t=1,r={}){return _A(e,t,{path:i,fs:s,crypto:d,...r})}async function KA(e,t={}){let r=we(t,"path"),n=we(t,"fs"),i=we(t,"crypto"),o=we(t,"type","");De(o)||(o="md5");let a=[],s=PA(e,null,{path:r,fs:n});return await cl(s,async e=>{if(e.isFolder)return;let t=await jA(e.path,{fs:n,crypto:i,type:o});a.push(t)}),xo(a,"|")}function $A(e,t=1,r={}){let n=we(r,"path"),i=we(r,"fs");if(!bA(e,{fs:i}))throw new Error(`fd[${e}] is not a folder`);let o=[];return o=PA(e,t,{path:n,fs:i}),o=pa(o,{isFolder:!0}),o=xr(o,e=>(delete e.isFolder,e)),o}async function ZA(e,t,r={}){let n="",i=we(r,"fs");if(!Rr(e))throw new Error("fpsIn in not an effective array");let o=QA(t),a=we(r,"fnOut","");De(a)||(a=FA(t)),bA(o,{fs:i})||wA(o,{fs:i});let s=ns();try{let r=i.createWriteStream(t);for(let t=0;t<e.length;t++){let o=e[t];if(!yA(o,{fs:i}))throw new Error(`fpIn[${o}] is not a file`);let a=()=>{let e=ns(),t=i.createReadStream(o);return t.on("error",t=>{n=t.message,e.reject(t)}),t.on("end",()=>{NA(o,{fs:i}),e.resolve()}),t.pipe(r,{end:!1}),e};await a()}r.end(),r.on("error",e=>{n=e.message,s.reject(n)}),r.on("finish",()=>{let e={filename:a,path:t};s.resolve(e)})}catch(e){n=e.message,s.reject(n)}return s}function em(e,t={}){let r=null,n=we(t,"fs"),i="";try{i=n.readFileSync(e,"utf8")}catch(e){r=e}return null!==r?{error:r}:{success:i}}function tm(e,t,r={}){let n=we(r,"fs");if(!yA(e,{fs:n}))return{error:`pahOld[${e}] is not a file`};if(IA(t,{fs:n}))return{error:`pahNew[${t}] already exists`};let i=QA(t);bA(i,{fs:n})||wA(i,{fs:n});try{n.renameSync(e,t)}catch(e){return{error:e}}return{success:"done: "+t}}function rm(e,t,r={}){let n=we(r,"fs");if(!bA(e,{fs:n}))return{error:`pahOld[${e}] is not a folder`};if(IA(t,{fs:n}))return{error:`pahNew[${t}] already exists`};let i=QA(t);bA(i,{fs:n})||wA(i,{fs:n});try{n.renameSync(e,t)}catch(e){return{error:e}}return{success:"done: "+t}}function nm(e,t,r,n={}){let i=we(n,"withInfor");pn(i)||(i=!0);let o={del:[],add:[],same:[],diff:[]};if(!De(r))return console.log("invalid key"),i&&(o.infor={}),o;Ce(e)||(e=[e]),Ce(t)||(t=[t]),e=pa(e,e=>ke(e,r)),t=pa(t,e=>ke(e,r));let a=new Map(t.map(e=>[e[r],e]));for(let t of e){let e=a.get(t[r]);if(e){JSON.stringify(t)===JSON.stringify(e)?o.same.push(e):o.diff.push(e),a.delete(t[r])}else o.del.push(t)}if(o.add=Array.from(a.values()),i){let e={};for(let t of o.del)e[t[r]]="del";for(let t of o.add)e[t[r]]="add";for(let t of o.diff)e[t[r]]="diff";for(let t of o.same)e[t[r]]="same";o.infor=e}return o}async function im(e,t=1,r={}){let n=we(r,"path"),i=we(r,"fs"),o=we(r,"crypto"),a=we(r,"type","");De(a)||(a="md5");let s=we(r,"forFile",null);pn(s)||(s=!0);let c=we(r,"forFolder",null);if(pn(c)||(c=!1),!bA(e,{fs:i}))throw new Error(`fd[${e}] is not a folder`);let l=PA(e,t,{path:n,fs:i});return l=await cl(l,async e=>{let t="";return s&&!e.isFolder&&(t=await jA(e.path,{fs:i,crypto:o,type:a})),c&&e.isFolder&&(t=await KA(e.path,{path:n,fs:i,crypto:o,type:a})),e.hash=t,e}),l}async function om(e,t,r={}){let n=we(r,"path"),i=we(r,"fs"),o=we(r,"crypto"),a=we(r,"type","");if(De(a)||(a="md5"),!bA(e,{fs:i}))throw new Error(`fdSrc[${e}] is not a folder`);if(!bA(t,{fs:i}))return void await xA(e,t,{path:n,fs:i,useSync:!1});let s=n.sep,c=n.sep.length,l=(e,t)=>(e=xr(e,e=>((e,t)=>{let r=e.isFolder?"folder":"file",n=e.path.replace(t,"");return ua(n,c)===s&&(n=da(n,c)),n=n.replaceAll("\\","/"),{id:`${r}|${n}`,isFolder:e.isFolder,name:e.name,rpath:n,hash:e.hash}})(e,t)),e),u=await im(e,null,{path:n,fs:i,crypto:o,type:a,forFile:!0,forFolder:!1});u=l(u,n.resolve(e));let f=await im(t,null,{path:n,fs:i,crypto:o,type:a,forFile:!0,forFolder:!1});f=l(f,n.resolve(t));let d=nm(f,u,"id",{withInfor:!1});await cl(d.del,async e=>{if(e.isFolder){MA(n.resolve(t,e.rpath),{fs:i})}}),await cl(d.del,async e=>{if(!e.isFolder){NA(n.resolve(t,e.rpath),{fs:i})}}),await cl([...d.add,...d.diff],async r=>{if(!r.isFolder){let o=n.resolve(e,r.rpath),a=n.resolve(t,r.rpath);await EA(o,a,{path:n,fs:i,useSync:!1})}})}function am(e,t={}){let r=we(t,"polling");pn(r)||(r=!1);let n=we(t,"timeInterval");eo(n)||(n=100),n=Zi(n);let o=we(t,"timeBinaryInterval");eo(o)||(o=300),o=Zi(o);let a=new u.EventEmitter,s=e,c=null,l=setInterval(()=>{null===c&&vA(s)&&(c=f.watch(s,{usePolling:r,interval:n,binaryInterval:o,awaitWriteFinish:!0}),c.on("all",(e,t,r)=>{t=i.resolve(t),a.emit("change",{type:e,fp:t,stats:r})}))},n);return a.clear=()=>{(()=>{if(null!==c){try{c.unwatch(s)}catch(e){console.log(e)}c.close().catch(e=>{console.log(e)}).finally(()=>{c=null})}})(),clearInterval(l)},a}function sm(e,t,r={}){let n=null,i=we(r,"fs"),o=QA(e);bA(o,{fs:i})||wA(o,{fs:i});try{i.writeFileSync(e,t,"utf8")}catch(e){n=e}return null!==n?{error:n}:{success:e}}const cm=[];for(let e=0;e<256;++e)cm.push((e+256).toString(16).slice(1));const lm=new Uint8Array(16);function um(){return crypto.getRandomValues(lm)}const fm={};function dm(e,t,r){let n;if(e)n=gm(e.random??e.rng?.()??um(),e.msecs,e.seq,t,r);else{const e=Date.now(),i=um();!function(e,t,r){e.msecs??=-1/0,e.seq??=0,t>e.msecs?(e.seq=r[6]<<23|r[7]<<16|r[8]<<8|r[9],e.msecs=t):(e.seq=e.seq+1|0,0===e.seq&&e.msecs++)}(fm,e,i),n=gm(i,fm.msecs,fm.seq,t,r)}return t??function(e,t=0){return(cm[e[t+0]]+cm[e[t+1]]+cm[e[t+2]]+cm[e[t+3]]+"-"+cm[e[t+4]]+cm[e[t+5]]+"-"+cm[e[t+6]]+cm[e[t+7]]+"-"+cm[e[t+8]]+cm[e[t+9]]+"-"+cm[e[t+10]]+cm[e[t+11]]+cm[e[t+12]]+cm[e[t+13]]+cm[e[t+14]]+cm[e[t+15]]).toLowerCase()}(n)}function gm(e,t,r,n,i=0){if(e.length<16)throw new Error("Random bytes length must be >= 16");if(n){if(i<0||i+16>n.length)throw new RangeError(`UUID byte range ${i}:${i+15} is out of buffer bounds`)}else n=new Uint8Array(16),i=0;return t??=Date.now(),r??=127*e[6]<<24|e[7]<<16|e[8]<<8|e[9],n[i++]=t/1099511627776&255,n[i++]=t/4294967296&255,n[i++]=t/16777216&255,n[i++]=t/65536&255,n[i++]=t/256&255,n[i++]=255&t,n[i++]=112|r>>>28&15,n[i++]=r>>>20&255,n[i++]=128|r>>>14&63,n[i++]=r>>>6&255,n[i++]=r<<2&255|3&e[10],n[i++]=e[11],n[i++]=e[12],n[i++]=e[13],n[i++]=e[14],n[i++]=e[15],n}function pm(e){return"[object Uint16Array]"===Object.prototype.toString.call(e)}function hm(e){if(!(I(e)||gs(e)||Za(e)||pm(e)))return null;try{if(e.byteLength)return e.byteLength}catch(e){}try{if(e.length)return e.length}catch(e){}try{if(e.size)return e.size}catch(e){}return null}function Am(e,t=!0){if(!Rr(e)){return{error:"no data"}}let r=null;try{r=function(e,t=!0){let r=t?"\ufeff":"";return Er(e,e=>{let t=[];Er(e,e=>{xe(e)?(e=pl(e,"\r\n",""),e=pl(e,"\r",""),e=`"${e=pl(e,"\n","")}"`):e=pn(e)?e?"true":"false":Ya(e),t.push(e)}),r+=xo(t,",")+"\r\n"}),r}(e,t)}catch(e){return{error:e}}return r}function mm(e){return pn(e)?e?"true":"false":Ya(e)}function Im(e,t){let r=[];return e.SheetNames.forEach(function(n){let i=vn().utils.sheet_to_json(e.Sheets[n],{header:"A",defval:"",blankrows:!0});i=xr(i,e=>lA(e)),t&&(i=xr(i,e=>xr(e,e=>mm(e)))),r.push({sheetname:n,data:i})}),r}function ym(e,t){let r=we(t,"fmt","ltdt");if(!ya(["ltdt","csv","array"],r))return{error:"opt.fmt is not one of 'ltdt', 'csv', 'array'"};let n,i=we(t,"valueToString",!0);if(!pn(i))return{error:"opt.valueToString is not a boolean"};try{n=vn().read(e,{type:"buffer"})}catch(e){return console.log("error: ",e),{error:"can not read data from u8a"}}let o=null;try{"ltdt"===r?o=function(e,t){let r=[];return e.SheetNames.forEach(function(n){let i=vn().utils.sheet_to_json(e.Sheets[n]);t&&(i=xr(i,e=>(Er(e,(t,r)=>{e[r]=mm(t)}),e))),r.push({sheetname:n,data:i})}),r}(n,i):"array"===r?o=Im(n,i):"csv"===r&&(o=function(e,t){let r=Im(e,t);return Er(r,(e,t)=>{r[t].data=Am(e.data,!1)}),r}(n,i))}catch(e){return console.log("error: ",e),{error:"can not convert data"}}return o}var vm;function bm(e){if(!N(e))return!1;var t=k(e);return"[object Error]"==t||"[object DOMException]"==t||"string"==typeof e.message&&"string"==typeof e.name&&!vr(e)}function wm(e){return bm(e)}function Bm(e){if(!Ee(e))return{error:"wb is not an effective object"};if(!Ce(we(e,"SheetNames")))return{error:"wb.SheetNames is not an array"};if(!Be(we(e,"Sheets")))return{error:"wb.Sheets is not an object"};let t=null;try{t=ps(vn().write(e,{bookType:"xlsx",type:"binary"}))}catch(e){return{error:e}}return t}
16
16
  /*!
17
17
  * hash-wasm (https://www.npmjs.com/package/hash-wasm)
18
18
  * (c) Dani Biro
@@ -20,5 +20,5 @@ var Bs,Es,Cs=9e15,xs=1e9,Ds="0123456789abcdef",Fs="2.302585092994045684017991454
20
20
  */
21
21
  function Em(e,t,r,n){return new(r||(r=Promise))(function(i,o){function a(e){try{c(n.next(e))}catch(e){o(e)}}function s(e){try{c(n.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?i(e.value):(t=e.value,t instanceof r?t:new r(function(e){e(t)})).then(a,s)}c((n=n.apply(e,t||[])).next())})}"function"==typeof SuppressedError&&SuppressedError;class Cm{constructor(){this.mutex=Promise.resolve()}lock(){let e=()=>{};return this.mutex=this.mutex.then(()=>new Promise(e)),new Promise(t=>{e=t})}dispatch(e){return Em(this,void 0,void 0,function*(){const t=yield this.lock();try{return yield Promise.resolve(e())}finally{t()}})}}const xm="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:global,Dm=null!==(vm=xm.Buffer)&&void 0!==vm?vm:null,Fm=xm.TextEncoder?new xm.TextEncoder:null;function Qm(e,t){return(15&e)+(e>>6|e>>3&8)<<4|(15&t)+(t>>6|t>>3&8)}const Sm="a".charCodeAt(0)-10,km="0".charCodeAt(0);function Nm(e,t,r){let n=0;for(let i=0;i<r;i++){let r=t[i]>>>4;e[n++]=r>9?r+Sm:r+km,r=15&t[i],e[n++]=r>9?r+Sm:r+km}return String.fromCharCode.apply(null,e)}const qm=null!==Dm?e=>{if("string"==typeof e){const t=Dm.from(e,"utf8");return new Uint8Array(t.buffer,t.byteOffset,t.length)}if(Dm.isBuffer(e))return new Uint8Array(e.buffer,e.byteOffset,e.length);if(ArrayBuffer.isView(e))return new Uint8Array(e.buffer,e.byteOffset,e.byteLength);throw new Error("Invalid data type!")}:e=>{if("string"==typeof e)return Fm.encode(e);if(ArrayBuffer.isView(e))return new Uint8Array(e.buffer,e.byteOffset,e.byteLength);throw new Error("Invalid data type!")},Mm="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",Hm=new Uint8Array(256);for(let e=0;e<64;e++)Hm[Mm.charCodeAt(e)]=e;function Lm(e){const t=function(e){let t=Math.floor(.75*e.length);const r=e.length;return"="===e[r-1]&&(t-=1,"="===e[r-2]&&(t-=1)),t}(e),r=e.length,n=new Uint8Array(t);let i=0;for(let t=0;t<r;t+=4){const r=Hm[e.charCodeAt(t)],o=Hm[e.charCodeAt(t+1)],a=Hm[e.charCodeAt(t+2)],s=Hm[e.charCodeAt(t+3)];n[i]=r<<2|o>>4,i+=1,n[i]=(15&o)<<4|a>>2,i+=1,n[i]=(3&a)<<6|63&s,i+=1}return n}const Um=16384,Rm=new Cm,Om=new Map;function Tm(e,t){return Em(this,void 0,void 0,function*(){let r=null,n=null,i=!1;if("undefined"==typeof WebAssembly)throw new Error("WebAssembly is not supported in this environment!");const o=()=>new DataView(r.exports.memory.buffer).getUint32(r.exports.STATE_SIZE,!0),a=Rm.dispatch(()=>Em(this,void 0,void 0,function*(){if(!Om.has(e.name)){const t=Lm(e.data),r=WebAssembly.compile(t);Om.set(e.name,r)}const t=yield Om.get(e.name);r=yield WebAssembly.instantiate(t,{})})),s=(e=null)=>{i=!0,r.exports.Hash_Init(e)},c=e=>{if(!i)throw new Error("update() called before init()");(e=>{let t=0;for(;t<e.length;){const i=e.subarray(t,t+Um);t+=i.length,n.set(i),r.exports.Hash_Update(i.length)}})(qm(e))},l=new Uint8Array(2*t),u=(e,o=null)=>{if(!i)throw new Error("digest() called before init()");return i=!1,r.exports.Hash_Final(o),"binary"===e?n.slice(0,t):Nm(l,n,t)},f=e=>"string"==typeof e?e.length<4096:e.byteLength<Um;let d=f;switch(e.name){case"argon2":case"scrypt":d=()=>!0;break;case"blake2b":case"blake2s":d=(e,t)=>t<=512&&f(e);break;case"blake3":d=(e,t)=>0===t&&f(e);break;case"xxhash64":case"xxhash3":case"xxhash128":case"crc64":d=()=>!1}return yield(()=>Em(this,void 0,void 0,function*(){r||(yield a);const e=r.exports.Hash_GetBuffer(),t=r.exports.memory.buffer;n=new Uint8Array(t,e,Um)}))(),{getMemory:()=>n,writeMemory:(e,t=0)=>{n.set(e,t)},getExports:()=>r.exports,setMemorySize:e=>{r.exports.Hash_SetMemorySize(e);const t=r.exports.Hash_GetBuffer(),i=r.exports.memory.buffer;n=new Uint8Array(i,t,e)},init:s,update:c,digest:u,save:()=>{if(!i)throw new Error("save() can only be called after init() and before digest()");const t=r.exports.Hash_GetState(),n=o(),a=r.exports.memory.buffer,s=new Uint8Array(a,t,n),c=new Uint8Array(4+n);return function(e,t){const r=t.length>>1;for(let n=0;n<r;n++){const r=n<<1;e[n]=Qm(t.charCodeAt(r),t.charCodeAt(r+1))}}(c,e.hash),c.set(s,4),c},load:t=>{if(!(t instanceof Uint8Array))throw new Error("load() expects an Uint8Array generated by save()");const n=r.exports.Hash_GetState(),a=o(),s=4+a,c=r.exports.memory.buffer;if(t.length!==s)throw new Error(`Bad state length (expected ${s} bytes, got ${t.length})`);if(!function(e,t){if(e.length!==2*t.length)return!1;for(let r=0;r<t.length;r++){const n=r<<1;if(t[r]!==Qm(e.charCodeAt(n),e.charCodeAt(n+1)))return!1}return!0}(e.hash,t.subarray(0,4)))throw new Error("This state was written by an incompatible hash implementation");const l=t.subarray(4);new Uint8Array(c,n,a).set(l),i=!0},calculate:(e,i=null,o=null)=>{if(!d(e,i))return s(i),c(e),u("hex",o);const a=qm(e);return n.set(a),r.exports.Hash_Calculate(a.length,i,o),Nm(l,n,t)},hashLength:t}})}new Cm,new Cm,new Cm,new Cm,new Cm,new Cm,new Cm;var Ym={name:"md5",data:"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",hash:"e6508e4b"};function jm(){return Tm(Ym,16).then(e=>{e.init();const t={init:()=>(e.init(),t),update:r=>(e.update(r),t),digest:t=>e.digest(t),save:()=>e.save(),load:r=>(e.load(r),t),blockSize:64,digestSize:16};return t})}new Cm;var Gm={name:"sha1",data:"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",hash:"6b530c24"};function Jm(){return Tm(Gm,20).then(e=>{e.init();const t={init:()=>(e.init(),t),update:r=>(e.update(r),t),digest:t=>e.digest(t),save:()=>e.save(),load:r=>(e.load(r),t),blockSize:64,digestSize:20};return t})}new Cm,new Cm,new Cm;var zm={name:"sha256",data:"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c2pBx6KerX1qIhkgASADcyACcSABIANxcyABQR53IAFBE3dzIAFBCndzaiAaaiICaiIJIBMgEnNxIBJzaiAJQRp3IAlBFXdzIAlBB3dzakHRxqk2aiIaIAIgAXMgA3EgAiABcXMgAkEedyACQRN3cyACQQp3c2ogGGoiA2oiESAJIBNzcSATc2ogEUEadyARQRV3cyARQQd3c2pB59KkoQFqIhggAyACcyABcSADIAJxcyADQR53IANBE3dzIANBCndzaiAUaiIBaiISIBEgCXNxIAlzaiASQRp3IBJBFXdzIBJBB3dzakGFldy9AmoiFCABIANzIAJxIAEgA3FzIAFBHncgAUETd3MgAUEKd3NqIBdqIgJqIhMgI2ogJiASaiAiIBFqICUgCWogEyASIBFzcSARc2ogE0EadyATQRV3cyATQQd3c2pBuMLs8AJqIhcgAiABcyADcSACIAFxcyACQR53IAJBE3dzIAJBCndzaiAZaiIDaiIJIBMgEnNxIBJzaiAJQRp3IAlBFXdzIAlBB3dzakH827HpBGoiGSADIAJzIAFxIAMgAnFzIANBHncgA0ETd3MgA0EKd3NqIBpqIgFqIhEgCSATc3EgE3NqIBFBGncgEUEVd3MgEUEHd3NqQZOa4JkFaiIaIAEgA3MgAnEgASADcXMgAUEedyABQRN3cyABQQp3c2ogGGoiAmoiEiARIAlzcSAJc2ogEkEadyASQRV3cyASQQd3c2pB1OapqAZqIhggAiABcyADcSACIAFxcyACQR53IAJBE3dzIAJBCndzaiAUaiIDaiITaiAoIBJqICQgEWogJyAJaiATIBIgEXNxIBFzaiATQRp3IBNBFXdzIBNBB3dzakG7laizB2oiFCADIAJzIAFxIAMgAnFzIANBHncgA0ETd3MgA0EKd3NqIBdqIgFqIgkgEyASc3EgEnNqIAlBGncgCUEVd3MgCUEHd3NqQa6Si454aiIXIAEgA3MgAnEgASADcXMgAUEedyABQRN3cyABQQp3c2ogGWoiAmoiESAJIBNzcSATc2ogEUEadyARQRV3cyARQQd3c2pBhdnIk3lqIhkgAiABcyADcSACIAFxcyACQR53IAJBE3dzIAJBCndzaiAaaiIDaiISIBEgCXNxIAlzaiASQRp3IBJBFXdzIBJBB3dzakGh0f+VemoiGiADIAJz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",hash:"8c18dd94"};function Vm(){return Tm(zm,32).then(e=>{e.init(256);const t={init:()=>(e.init(256),t),update:r=>(e.update(r),t),digest:t=>e.digest(t),save:()=>e.save(),load:r=>(e.load(r),t),blockSize:64,digestSize:32};return t})}new Cm,new Cm;var Pm={name:"sha512",data:"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",hash:"f2e40eb1"};function Xm(){return Tm(Pm,48).then(e=>{e.init(384);const t={init:()=>(e.init(384),t),update:r=>(e.update(r),t),digest:t=>e.digest(t),save:()=>e.save(),load:r=>(e.load(r),t),blockSize:128,digestSize:48};return t})}function _m(){return Tm(Pm,64).then(e=>{e.init(512);const t={init:()=>(e.init(512),t),update:r=>(e.update(r),t),digest:t=>e.digest(t),save:()=>e.save(),load:r=>(e.load(r),t),blockSize:128,digestSize:64};return t})}function Wm(e){return"[object File]"===Object.prototype.toString.call(e)}async function Km(e,t={}){if(!gs(e)&&!Wm(e))return console.log("inp",e),Promise.reject("inp is not a Blob or File");let r=we(t,"type","");De(r)||(r="sha512");let n=we(t,"chunkSize");Se(n)||(n=67108864),n=Mn(n);let i={MD5:jm,"SHA-1":Jm,"SHA-256":Vm,"SHA-384":Xm,"SHA-512":_m,md5:jm,sha1:Jm,sha256:Vm,sha384:Xm,sha512:_m};if(!ke(i,r))return Promise.reject(`type[${r}] must be one of [ 'md5', 'sha1', 'sha256', 'sha384', 'sha512' ]`);let o=we(i,r),a=await o(),s=0;for(;s<e.size;){let t=e.slice(s,s+n),r=await t.arrayBuffer();a.update(new Uint8Array(r)),s+=n}return a.digest()}async function $m(e,t={}){if(!gs(e)&&!Wm(e))return console.log("inp",e),Promise.reject("inp is not a Blob or File");let r=we(t,"chunkSize");Se(r)||(r=67108864),r=Mn(r);let{create64:n}=await JA(),i=n(),o=0;for(;o<e.size;){let t=e.slice(o,o+r),n=await t.arrayBuffer();i.update(new Uint8Array(n)),o+=r}return i.digest().toString(16).padStart(16,"0")}new Cm,new Cm,new Cm,new Cm,new Cm,new Cm,new Cm,new Cm,new Cm;var Zm=4294967295,eI=Math.min;function tI(e,t){if((e=qn(e))<1||e>9007199254740991)return[];var r=Zm,n=eI(e,Zm);t=Br(t),e-=Zm;for(var i=He(n,t);++r<e;)t(r);return i}function rI(e){let t="";return"years"===e?t="YYYY":"months"===e?t="YYYY-MM":"days"===e?t="YYYY-MM-DD":"hours"===e?t="YYYY-MM-DDTHH":"minutes"===e?t="YYYY-MM-DDTHH:mm":"seconds"===e&&(t="YYYY-MM-DDTHH:mm:ss"),t}function nI(e,t="days"){if(!De(e))return null;if(!De(t))return null;let n=function(e,t){let n="";return"years"===t?n="-01-01T00:00:00":"months"===t?n="-01T00:00:00":"days"===t?n="T00:00:00":"hours"===t?n=":00:00":"minutes"===t&&(n=":00"),r(e+n,"YYYY-MM-DDTHH:mm:ss")}(e,t),i=rI(t);return e===n.format(i)?n:null}function iI(){let e=yn(),t=()=>Number(e.process.hrtime.bigint())/1e6,r=()=>e.performance.now(),n=null;return n=In()?r:t,n}function oI(e){if(!Eg(e))return"";return r(e,"YYYY-MM-DDTHH:mm:ss").format("YYYY-MM-DDTHH:mm")}function aI(e=null){let t,r=function(){let e=yn();return g.UAParser||e.UAParser}();t=xe(e)?new r(e):new r;let n=t.getResult();return{browsername:n.browser.name,browserversion:n.browser.version,engineinfor:n.engine.name+n.engine.version,platform:n.os.name+n.os.version,devicetype:we(n.device,"type",""),cpuarchitecture:we(n.cpu,"architecture","")}}let sI="in x-range",cI="out of x-range",lI="order list",uI="reverse order list";function fI(e,t){let r=null,n=null;return r=e[0].x,n=e[dn(e)-1].x,t<r?{err:cI,msg:`x[${t}] less than lower limit[${r}]`,data:{ps:e,x:t,xmin:r,xmax:n}}:t>n?{err:cI,msg:`x[${t}] greater than upper limit[${n}]`,data:{ps:e,x:t,xmin:r,xmax:n}}:sI}function dI(e){if(!Hn(e))return!1;return Zi(e)<=0}function gI(e){if(!Se(e))return!1;return Mn(e)<=0}function pI(e){if(!Se(e))return!1;return Mn(e)>=0}function hI(e){if(!De(e))return!1;return!(null===e.match(/^.*[A-Z]+.*$/))}function AI(e){if(!De(e))return!1;return!(null===e.match(/^.*[a-zA-Z]+.*$/))}function mI(e){if(!De(e))return!1;return!(null===e.match(/^.*[a-z]+.*$/))}function II(e){if(!De(e))return!1;return!(null===e.match(/^.*[0-9]+.*$/))}function yI(e){if(!De(e))return!1;return!(null===e.match(/^.*\s+.*$/))}function vI(e){if(!De(e))return!1;
22
22
  //!"#$%&'()*+,-./ :;<=>?@ [\]^_` {|}~
23
- return/[!-/:-@[-`{-~]/.test(e)}function bI(e){if(!De(e))return!1;let t="YYYY-MM-DDTHH:mm:ss.SSS";return e===r(e,t).format(t)}function wI(e){let t;return t=fa(e,1),"Z"===t?`${e=Ga(e,1)}+00:00`:e}let BI={checkTZ:function(e){let t;return t=fa(e,1),"Z"===t||(t=fa(e,6),!!/[+|-]\d\d:\d\d/.test(t))},delTZ:function(e){let t;return t=fa(e,1),Ga(e,"Z"===t?1:6)},normTZ:wI,sepTZ:function(e){let t=wI(e);return{t:Ga(t,6),tz:fa(t,6)}}};function EI(e){if(!De(e))return!1;if(!BI.checkTZ(e))return!1;let t=BI.delTZ(e),n="YYYY-MM-DDTHH:mm:ss.SSS";return t===r(t,n).format(n)}function CI(e){if(!De(e))return!1;if(!BI.checkTZ(e))return!1;let t=BI.delTZ(e),n="YYYY-MM-DDTHH:mm:ss";return t===r(t,n).format(n)}let xI=["1234","12345","123456","1234567","12345678","123456789","1234567890","12345678910","111111","000000","666666","888888","7777777","11111111","123123","123321","654321","987654321","qwerty","qwerty123","qwerty1","qwertyuiop","qazwsx","1q2w3e4r","1q2w3e4r5t","1q2w3e","1qaz2wsx","zxcvbnm","password","password1","passw0rd","admin","admin123","welcome","letmein","login","master","monkey","dragon","shadow","sunshine","superman","batman","football","baseball","soccer","hockey","michael","jordan","jennifer","hunter","ranger","harley","thomas","charlie","andrew","daniel","ashley","bailey","mustang","access","secret","ninja","jesus","hello","freedom","trustno1","1qaz@WSX","P@ssw0rd","Pass@123","Aa123456","Aa@123456","Admin@123","abc@123","abc123","abcdef","abcd1234","abc","iloveyou","fuckyou","f*ckyou","whatever","nothing","google","computer","internet","samsung","apple","killer","princess","lovely","tigger","starwars","pokemon","minecraft","123qwe","zaq1zaq1","photoshop","adobe123","18atcskd2w","mynoob"];function DI(e,t){return new il(e).eq(t)}function FI(e,t){if(!Rr(e))return[];if(!Rr(t))return[];if(!Rr(t[0]))return[];return xr(t,function(t){let r=to(e,t);return Er(r,function(e,t){void 0===e&&(r[t]="")}),r})}var QI=Ra(function(e){return Vr(Qr(e,1,hg,!0))});var SI=Ra(function(e,t){var r=Qa(t);return hg(r)&&(r=void 0),hg(e)?function(e,t,r,n){var i=-1,o=jr,a=!0,s=e.length,c=[],l=t.length;if(!s)return c;r&&(t=pe(t,We(r))),n?(o=Gr,a=!1):t.length>=200&&(o=yt,a=!1,t=new mt(t));e:for(;++i<s;){var u=e[i],f=null==r?u:r(u);if(u=n||0!==u?u:0,a&&f==f){for(var d=l;d--;)if(t[d]===f)continue e;c.push(u)}else o(t,f,n)||c.push(u)}return c}(e,Qr(t,1,hg,!0),fr(r)):[]}),kI=SI;function NI(e){if(!De(e))return"";let t=ai.parse(e);return zn.stringify(t)}function qI(e,t,r=!1){if(!De(e))return"";if(!De(t))return"";if(!pn(r))return"";let n=ii.encrypt(e,t),i="";if(r)i=n.toString();else{let e=n.toString();i=zn.parse(e).toString(ci)}return i}var MI={exports:{}};!function(e){var t;e.exports=(t=Yn(),function(){if("function"==typeof ArrayBuffer){var e=t.lib.WordArray,r=e.init,n=e.init=function(e){if(e instanceof ArrayBuffer&&(e=new Uint8Array(e)),(e instanceof Int8Array||"undefined"!=typeof Uint8ClampedArray&&e instanceof Uint8ClampedArray||e instanceof Int16Array||e instanceof Uint16Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Float32Array||e instanceof Float64Array)&&(e=new Uint8Array(e.buffer,e.byteOffset,e.byteLength)),e instanceof Uint8Array){for(var t=e.byteLength,n=[],i=0;i<t;i++)n[i>>>2]|=e[i]<<24-i%4*8;r.call(this,n,t)}else r.apply(this,arguments)};n.prototype=e}}(),t.lib.WordArray)}(MI);var HI=Un(MI.exports);function LI(e){if(!Za(e))return"";return HI.create(e).toString(zn)}function UI(e){return pm(e)?new Uint8Array(e):new Uint8Array}function RI(e){return pm(e)?LI(UI(e)):""}let OI="[Uint8Array]::";let TI="[Uint16Array]::";let YI={tagU8A:OI,u8arr2b64:function(e){return Za(e)?OI+LI(e):e},b642u8arr:function(e){return xe(e)&&ua(e,14)===OI?$a(e=da(e,14)):e},tagU16A:TI,u16arr2b64:function(e){return pm(e)?TI+RI(e):e},b642u16arr:function(e){return xe(e)&&ua(e,15)===TI?ts(e=da(e,15)):e}};function jI(e){if(!Be(e))return{results:"",binarys:[]};if(Mr(e))return{results:"",binarys:[]};let t="",r=[];try{let n=-1;t=JSON.stringify(e,function(e,t){if(Za(t)){n+=1;let e=`[Uint8Array]::${n}`;return r.push(t),e}if(pm(t)){n+=1;let e=`[Uint16Array]::${n}`;return r.push(t),e}if(I(t)){n+=1;let e=`[ArrayBuffer]::${n}`;return r.push(t),e}return bm(t)&&(t=t.toString()),t})}catch(e){}return{results:t,binarys:r}}function GI(e){if(!De(e))return new Uint8Array;let t;try{t=$a(NI(e))}catch(e){return new Uint8Array}return t}function JI(e,t){if(!Ee(e))return{};if(!va(t))throw new Error("fun is not a function");let r=xr(e,(e,r)=>({k:r,v:e,t:t(e,r)}));r=Oa(r,"t");let n={};return Er(r,e=>{n[e.k]=e.v}),n}function zI(e,t=()=>{}){if(!va(e))return null;function r(e,t){let r;return qr(e)||Nr(e)?t:(r=we(e,"data",null),r||e)}return va(t)||(t=()=>{}),function(){let n,i=ns(),o=t({mode:"before",data:arguments});return(qr(o)||Nr(o))&&(o=arguments),e(...o).then(e=>{n=t({mode:"afterThen",data:e}),e=r(n,e),i.resolve(e)}).catch(e=>{n=t({mode:"afterCatch",data:e}),e=r(n,e),i.reject(e)}),i}}function VI(e){if(!xe(e))return null;if(""===e)return 0;let t=e.split("").reduce((e,t)=>t.charCodeAt(0)+(e<<6)+(e<<16)-e,0);return t}let PI=0;function XI(e="start1",t=!1){void 0===e?e=(new Date).getTime():"start1"===e&&(PI++,e=PI);let r=624,n=397,i=2147483648,o=2147483647,a=new Array(r),s=625,c=e=>{for(Ia(e)?a[0]=e>>>0:(e=Ya(e),a[0]=VI(e)),s=1;s<r;s++){let e=a[s-1]^a[s-1]>>>30;a[s]=(1812433253*((4294901760&e)>>>16)<<16)+1812433253*(65535&e)+s,a[s]>>>=0}},l=()=>(()=>{let e,t=new Array(2567483615);if(s>=r){let l;for(625===s&&c(5489),l=0;l<227;l++)e=a[l]&i|a[l+1]&o,a[l]=a[l+n]^e>>>1^t[1&e];for(;l<623;l++)e=a[l]&i|a[l+1]&o,a[l]=a[l+(n-r)]^e>>>1^t[1&e];e=a[623]&i|a[0]&o,a[623]=a[396]^e>>>1^t[1&e],s=0}return e=a[s++],e^=e>>>11,e^=e<<7&2636928640,e^=e<<15&4022730752,e^=e>>>18,e>>>0})()*(1/4294967296);c(e);let u=null;return u=t?l:l(),u}let _I=XI((new Date).getTime(),!0);function WI(){return _I()}function KI(e,t,r){return e==e&&(void 0!==r&&(e=e<=r?e:r),void 0!==t&&(e=e>=t?e:t)),e}var $I=Math.floor,ZI=Math.random;function ey(e,t){return e+$I(ZI()*(t-e+1))}function ty(e,t){var r=-1,n=e.length,i=n-1;for(t=void 0===t?n:t;++r<t;){var o=ey(r,i),a=e[o];e[o]=e[r],e[r]=a}return e.length=t,e}function ry(e,t){return ty(Sr(e),KI(t,0,e.length))}function ny(e,t){var r=lA(e);return ty(r,KI(t,0,r.length))}var iy=Math.floor;function oy(e,t,r){return t=(r?dr(e,t,r):void 0===t)?1:qn(t),function(e,t){var r="";if(!e||t<1||t>9007199254740991)return r;do{t%2&&(r+=e),(t=iy(t/2))&&(e+=e)}while(t);return r}(Ie(e),t)}var ay=Ki("floor");var sy=Un(Pn());var cy,ly={exports:{}},uy={exports:{}};!function(e){var t;e.exports=(t=Yn(),cy||(cy=1,function(e){var t,r,n,i,o,a,s;e.exports=(n=(r=s=Yn()).lib,i=n.Base,o=n.WordArray,(a=r.x64={}).Word=i.extend({init:function(e,t){this.high=e,this.low=t}}),a.WordArray=i.extend({init:function(e,r){e=this.words=e||[],this.sigBytes=r!=t?r:8*e.length},toX32:function(){for(var e=this.words,t=e.length,r=[],n=0;n<t;n++){var i=e[n];r.push(i.high),r.push(i.low)}return o.create(r,this.sigBytes)},clone:function(){for(var e=i.clone.call(this),t=e.words=this.words.slice(0),r=t.length,n=0;n<r;n++)t[n]=t[n].clone();return e}}),s)}(uy)),function(){var e=t,r=e.lib.Hasher,n=e.x64,i=n.Word,o=n.WordArray,a=e.algo;function s(){return i.create.apply(i,arguments)}var c=[s(1116352408,3609767458),s(1899447441,602891725),s(3049323471,3964484399),s(3921009573,2173295548),s(961987163,4081628472),s(1508970993,3053834265),s(2453635748,2937671579),s(2870763221,3664609560),s(3624381080,2734883394),s(310598401,1164996542),s(607225278,1323610764),s(1426881987,3590304994),s(1925078388,4068182383),s(2162078206,991336113),s(2614888103,633803317),s(3248222580,3479774868),s(3835390401,2666613458),s(4022224774,944711139),s(264347078,2341262773),s(604807628,2007800933),s(770255983,1495990901),s(1249150122,1856431235),s(1555081692,3175218132),s(1996064986,2198950837),s(2554220882,3999719339),s(2821834349,766784016),s(2952996808,2566594879),s(3210313671,3203337956),s(3336571891,1034457026),s(3584528711,2466948901),s(113926993,3758326383),s(338241895,168717936),s(666307205,1188179964),s(773529912,1546045734),s(1294757372,1522805485),s(1396182291,2643833823),s(1695183700,2343527390),s(1986661051,1014477480),s(2177026350,1206759142),s(2456956037,344077627),s(2730485921,1290863460),s(2820302411,3158454273),s(3259730800,3505952657),s(3345764771,106217008),s(3516065817,3606008344),s(3600352804,1432725776),s(4094571909,1467031594),s(275423344,851169720),s(430227734,3100823752),s(506948616,1363258195),s(659060556,3750685593),s(883997877,3785050280),s(958139571,3318307427),s(1322822218,3812723403),s(1537002063,2003034995),s(1747873779,3602036899),s(1955562222,1575990012),s(2024104815,1125592928),s(2227730452,2716904306),s(2361852424,442776044),s(2428436474,593698344),s(2756734187,3733110249),s(3204031479,2999351573),s(3329325298,3815920427),s(3391569614,3928383900),s(3515267271,566280711),s(3940187606,3454069534),s(4118630271,4000239992),s(116418474,1914138554),s(174292421,2731055270),s(289380356,3203993006),s(460393269,320620315),s(685471733,587496836),s(852142971,1086792851),s(1017036298,365543100),s(1126000580,2618297676),s(1288033470,3409855158),s(1501505948,4234509866),s(1607167915,987167468),s(1816402316,1246189591)],l=[];!function(){for(var e=0;e<80;e++)l[e]=s()}();var u=a.SHA512=r.extend({_doReset:function(){this._hash=new o.init([new i.init(1779033703,4089235720),new i.init(3144134277,2227873595),new i.init(1013904242,4271175723),new i.init(2773480762,1595750129),new i.init(1359893119,2917565137),new i.init(2600822924,725511199),new i.init(528734635,4215389547),new i.init(1541459225,327033209)])},_doProcessBlock:function(e,t){for(var r=this._hash.words,n=r[0],i=r[1],o=r[2],a=r[3],s=r[4],u=r[5],f=r[6],d=r[7],g=n.high,p=n.low,h=i.high,A=i.low,m=o.high,I=o.low,y=a.high,v=a.low,b=s.high,w=s.low,B=u.high,E=u.low,C=f.high,x=f.low,D=d.high,F=d.low,Q=g,S=p,k=h,N=A,q=m,M=I,H=y,L=v,U=b,R=w,O=B,T=E,Y=C,j=x,G=D,J=F,z=0;z<80;z++){var V,P,X=l[z];if(z<16)P=X.high=0|e[t+2*z],V=X.low=0|e[t+2*z+1];else{var _=l[z-15],W=_.high,K=_.low,$=(W>>>1|K<<31)^(W>>>8|K<<24)^W>>>7,Z=(K>>>1|W<<31)^(K>>>8|W<<24)^(K>>>7|W<<25),ee=l[z-2],te=ee.high,re=ee.low,ne=(te>>>19|re<<13)^(te<<3|re>>>29)^te>>>6,ie=(re>>>19|te<<13)^(re<<3|te>>>29)^(re>>>6|te<<26),oe=l[z-7],ae=oe.high,se=oe.low,ce=l[z-16],le=ce.high,ue=ce.low;P=(P=(P=$+ae+((V=Z+se)>>>0<Z>>>0?1:0))+ne+((V+=ie)>>>0<ie>>>0?1:0))+le+((V+=ue)>>>0<ue>>>0?1:0),X.high=P,X.low=V}var fe,de=U&O^~U&Y,ge=R&T^~R&j,pe=Q&k^Q&q^k&q,he=S&N^S&M^N&M,Ae=(Q>>>28|S<<4)^(Q<<30|S>>>2)^(Q<<25|S>>>7),me=(S>>>28|Q<<4)^(S<<30|Q>>>2)^(S<<25|Q>>>7),Ie=(U>>>14|R<<18)^(U>>>18|R<<14)^(U<<23|R>>>9),ye=(R>>>14|U<<18)^(R>>>18|U<<14)^(R<<23|U>>>9),ve=c[z],be=ve.high,we=ve.low,Be=G+Ie+((fe=J+ye)>>>0<J>>>0?1:0),Ee=me+he;G=Y,J=j,Y=O,j=T,O=U,T=R,U=H+(Be=(Be=(Be=Be+de+((fe+=ge)>>>0<ge>>>0?1:0))+be+((fe+=we)>>>0<we>>>0?1:0))+P+((fe+=V)>>>0<V>>>0?1:0))+((R=L+fe|0)>>>0<L>>>0?1:0)|0,H=q,L=M,q=k,M=N,k=Q,N=S,Q=Be+(Ae+pe+(Ee>>>0<me>>>0?1:0))+((S=fe+Ee|0)>>>0<fe>>>0?1:0)|0}p=n.low=p+S,n.high=g+Q+(p>>>0<S>>>0?1:0),A=i.low=A+N,i.high=h+k+(A>>>0<N>>>0?1:0),I=o.low=I+M,o.high=m+q+(I>>>0<M>>>0?1:0),v=a.low=v+L,a.high=y+H+(v>>>0<L>>>0?1:0),w=s.low=w+R,s.high=b+U+(w>>>0<R>>>0?1:0),E=u.low=E+T,u.high=B+O+(E>>>0<T>>>0?1:0),x=f.low=x+j,f.high=C+Y+(x>>>0<j>>>0?1:0),F=d.low=F+J,d.high=D+G+(F>>>0<J>>>0?1:0)},_doFinalize:function(){var e=this._data,t=e.words,r=8*this._nDataBytes,n=8*e.sigBytes;return t[n>>>5]|=128<<24-n%32,t[30+(n+128>>>10<<5)]=Math.floor(r/4294967296),t[31+(n+128>>>10<<5)]=r,e.sigBytes=4*t.length,this._process(),this._hash.toX32()},clone:function(){var e=r.clone.call(this);return e._hash=this._hash.clone(),e},blockSize:32});e.SHA512=r._createHelper(u),e.HmacSHA512=r._createHmacHelper(u)}(),t.SHA512)}(ly);var fy=Un(ly.exports);function dy(e,t){return De(e)&&De(t)?function(e,t){if(e=e.replace(/\s+/g,""),t=t.replace(/\s+/g,""),!e.length&&!t.length)return 1;if(!e.length||!t.length)return 0;if(e===t)return 1;if(1===e.length&&1===t.length)return 0;if(e.length<2||t.length<2)return 0;let r=new Map;for(let t=0;t<e.length-1;t++){const n=e.substring(t,t+2),i=r.has(n)?r.get(n)+1:1;r.set(n,i)}let n=0;for(let e=0;e<t.length-1;e++){const i=t.substring(e,e+2),o=r.has(i)?r.get(i):0;o>0&&(r.set(i,o-1),n++)}return 2*n/(e.length+t.length-2)}(e,t):0}function gy(e){return Array.isArray?Array.isArray(e):"[object Array]"===by(e)}function py(e){return null==e?"":function(e){if("string"==typeof e)return e;if("bigint"==typeof e)return e.toString();const t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(e)}function hy(e){return"string"==typeof e}function Ay(e){return"number"==typeof e}function my(e){return!0===e||!1===e||function(e){return Iy(e)&&null!==e}(e)&&"[object Boolean]"==by(e)}function Iy(e){return"object"==typeof e}function yy(e){return null!=e}function vy(e){return!e.trim().length}function by(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}const wy="Invalid doc index: must be a non-negative integer within the bounds of the docs array",By=Object.prototype.hasOwnProperty;var Ey=class{constructor(e){this._keys=[],this._keyMap={};let t=0;e.forEach(e=>{const r=Cy(e);this._keys.push(r),this._keyMap[r.id]=r,t+=r.weight}),this._keys.forEach(e=>{e.weight/=t})}get(e){return this._keyMap[e]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}};function Cy(e){let t=null,r=null,n=null,i=1,o=null;if(hy(e)||gy(e))n=e,t=xy(e),r=Dy(e);else{if(!By.call(e,"name"))throw new Error((e=>`Missing ${e} property in key`)("name"));const a=e.name;if(n=a,By.call(e,"weight")&&void 0!==e.weight&&(i=e.weight,i<=0))throw new Error((e=>`Property 'weight' in key '${e}' must be a positive integer`)(Dy(a)));t=xy(a),r=Dy(a),o=e.getFn??null}return{path:t,id:r,weight:i,src:n,getFn:o}}function xy(e){return gy(e)?e:e.split(".")}function Dy(e){return gy(e)?e.join("."):e}const Fy={useExtendedSearch:!1,useTokenSearch:!1,tokenize:void 0,tokenMatch:"any",getFn:function(e,t){const r=[];let n=!1;const i=(e,t,o,a)=>{if(yy(e))if(t[o]){const s=e[t[o]];if(!yy(s))return;if(o===t.length-1&&(hy(s)||Ay(s)||my(s)||"bigint"==typeof s))r.push(void 0!==a?{v:py(s),i:a}:py(s));else if(gy(s)){n=!0;for(let e=0,r=s.length;e<r;e+=1)i(s[e],t,o+1,e)}else t.length&&i(s,t,o+1,a)}else r.push(void 0!==a?{v:e,i:a}:e)};return i(e,hy(t)?t.split("."):t,0),n?r:r[0]},ignoreLocation:!1,ignoreFieldNorm:!1,fieldNormWeight:1},Qy=Object.freeze({isCaseSensitive:!1,ignoreDiacritics:!1,includeScore:!1,keys:[],shouldSort:!0,sortFn:(e,t)=>e.score===t.score?e.idx<t.idx?-1:1:e.score<t.score?-1:1,includeMatches:!1,findAllMatches:!1,minMatchCharLength:1,location:0,threshold:.6,distance:100,...Fy});var Sy=class{constructor({getFn:e=Qy.getFn,fieldNormWeight:t=Qy.fieldNormWeight}={}){this.norm=function(e=1,t=3){const r=new Map,n=Math.pow(10,t);return{get(t){let i=1,o=!1;for(let e=0;e<t.length;e++)32===t.charCodeAt(e)?o||(i++,o=!0):o=!1;if(r.has(i))return r.get(i);const a=Math.round(n/Math.pow(i,.5*e))/n;return r.set(i,a),a},clear(){r.clear()}}}(t,3),this.getFn=e,this.isCreated=!1,this.docs=[],this.keys=[],this._keysMap={},this.setIndexRecords()}setSources(e=[]){this.docs=e}setIndexRecords(e=[]){this.records=e}setKeys(e=[]){this.keys=e,this._keysMap={},e.forEach((e,t)=>{this._keysMap[e.id]=t})}create(){if(this.isCreated||!this.docs.length)return;this.isCreated=!0;const e=this.docs.length;this.records=new Array(e);let t=0;if(hy(this.docs[0]))for(let r=0;r<e;r++){const e=this._createStringRecord(this.docs[r],r);e&&(this.records[t++]=e)}else for(let r=0;r<e;r++)this.records[t++]=this._createObjectRecord(this.docs[r],r);this.records.length=t,this.norm.clear()}add(e,t){if(!Number.isInteger(t)||t<0)throw new Error(wy);if(hy(e)){const r=this._createStringRecord(e,t);return r&&this.records.push(r),r}const r=this._createObjectRecord(e,t);return this.records.push(r),r}removeAt(e){if(!Number.isInteger(e)||e<0)throw new Error(wy);for(let t=0,r=this.records.length;t<r;t+=1)if(this.records[t].i===e){this.records.splice(t,1);break}for(let t=0,r=this.records.length;t<r;t+=1)this.records[t].i>e&&(this.records[t].i-=1)}removeAll(e){const t=new Set;for(const r of e)Number.isInteger(r)&&r>=0&&t.add(r);if(0===t.size)return;this.records=this.records.filter(e=>!t.has(e.i));const r=Array.from(t).sort((e,t)=>e-t);for(const e of this.records){let t=0,n=r.length;for(;t<n;){const i=t+n>>>1;r[i]<e.i?t=i+1:n=i}e.i-=t}}getValueForItemAtKeyId(e,t){return e[this._keysMap[t]]}size(){return this.records.length}_createStringRecord(e,t){return!yy(e)||vy(e)?null:{v:e,i:t,n:this.norm.get(e)}}_createObjectRecord(e,t){const r={i:t,$:{}};for(let t=0,n=this.keys.length;t<n;t++){const n=this.keys[t],i=n.getFn?n.getFn(e):this.getFn(e,n.path);if(yy(i))if(gy(i)){const e=[];for(let t=0,r=i.length;t<r;t+=1){const r=i[t];if(yy(r))if(hy(r)){if(!vy(r)){const n={v:r,i:t,n:this.norm.get(r)};e.push(n)}}else if(yy(r.v)){const t=hy(r.v)?r.v:py(r.v);if(!vy(t)){const n={v:t,i:r.i,n:this.norm.get(t)};e.push(n)}}}r.$[t]=e}else if(hy(i)&&!vy(i)){const e={v:i,n:this.norm.get(i)};r.$[t]=e}}return r}toJSON(){return{keys:this.keys.map(({getFn:e,...t})=>t),records:this.records}}};function ky(e,t,{getFn:r=Qy.getFn,fieldNormWeight:n=Qy.fieldNormWeight}={}){const i=new Sy({getFn:r,fieldNormWeight:n});return i.setKeys(e.map(Cy)),i.setSources(t),i.create(),i}function Ny(e,t,r,{location:n=Qy.location,distance:i=Qy.distance,threshold:o=Qy.threshold,findAllMatches:a=Qy.findAllMatches,minMatchCharLength:s=Qy.minMatchCharLength,includeMatches:c=Qy.includeMatches,ignoreLocation:l=Qy.ignoreLocation}={}){if(t.length>32)throw new Error((e=>`Pattern length exceeds max of ${e}.`)(32));const u=t.length,f=e.length,d=Math.max(0,Math.min(n,f));let g=o,p=d;const h=(e,t)=>{const r=e/u;if(l)return r;const n=Math.abs(d-t);return i?r+n/i:n?1:r},A=s>1||c,m=A?Array(f):[];let I;for(;(I=e.indexOf(t,p))>-1;){const e=h(0,I);if(g=Math.min(e,g),p=I+u,A){let e=0;for(;e<u;)m[I+e]=1,e+=1}}p=-1;let y=[],v=1,b=0,w=u+f;const B=1<<u-1;for(let t=0;t<u;t+=1){let n=0,i=w;for(;n<i;)h(t,d+i)<=g?n=i:w=i,i=Math.floor((w-n)/2+n);w=i;let o=Math.max(1,d-i+1);const s=a?f:Math.min(d+i,f)+u,c=Array(s+2);c[s+1]=(1<<t)-1;for(let n=s;n>=o;n-=1){const i=n-1,a=r[e[i]];if(c[n]=(c[n+1]<<1|1)&a,t&&(c[n]|=(y[n+1]|y[n])<<1|1|y[n+1]),c[n]&B&&(v=h(t,i),v<=g)){if(g=v,p=i,b=t,p<=d)break;o=Math.max(1,2*d-p)}}if(h(t+1,d)>g)break;y=c}if(A&&p>=0){const t=Math.min(f-1,p+u-1+b);for(let n=p;n<=t;n+=1)r[e[n]]&&(m[n]=1)}const E={isMatch:p>=0,score:Math.max(.001,v)};if(A){const e=function(e=[],t=Qy.minMatchCharLength){const r=[];let n=-1,i=-1,o=0;for(let a=e.length;o<a;o+=1){const a=e[o];a&&-1===n?n=o:a||-1===n||(i=o-1,i-n+1>=t&&r.push([n,i]),n=-1)}return e[o-1]&&o-n>=t&&r.push([n,o-1]),r}(m,s);e.length?c&&(E.indices=e):E.isMatch=!1}return E}function qy(e){const t={};for(let r=0,n=e.length;r<n;r+=1){const i=e.charAt(r);t[i]=(t[i]||0)|1<<n-r-1}return t}function My(e){if(e.length<=1)return e;e.sort((e,t)=>e[0]-t[0]||e[1]-t[1]);const t=[e[0]];for(let r=1,n=e.length;r<n;r+=1){const n=t[t.length-1],i=e[r];i[0]<=n[1]+1?n[1]=Math.max(n[1],i[1]):t.push(i)}return t}const Hy={"ł":"l","Ł":"L","đ":"d","Đ":"D","ø":"o","Ø":"O","ħ":"h","Ħ":"H","ŧ":"t","Ŧ":"T","ı":"i","ß":"ss"},Ly=new RegExp("["+Object.keys(Hy).join("")+"]","g"),Uy="function"==typeof String.prototype.normalize?e=>e.normalize("NFD").replace(/[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C04\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F]/g,"").replace(Ly,e=>Hy[e]):e=>e;var Ry=class{constructor(e,{location:t=Qy.location,threshold:r=Qy.threshold,distance:n=Qy.distance,includeMatches:i=Qy.includeMatches,findAllMatches:o=Qy.findAllMatches,minMatchCharLength:a=Qy.minMatchCharLength,isCaseSensitive:s=Qy.isCaseSensitive,ignoreDiacritics:c=Qy.ignoreDiacritics,ignoreLocation:l=Qy.ignoreLocation}={}){if(this.options={location:t,threshold:r,distance:n,includeMatches:i,findAllMatches:o,minMatchCharLength:a,isCaseSensitive:s,ignoreDiacritics:c,ignoreLocation:l},e=s?e:e.toLowerCase(),e=c?Uy(e):e,this.pattern=e,this.chunks=[],!this.pattern.length)return;const u=(e,t)=>{this.chunks.push({pattern:e,alphabet:qy(e),startIndex:t})},f=this.pattern.length;if(f>32){let e=0;const t=f%32,r=f-t;for(;e<r;)u(this.pattern.substr(e,32),e),e+=32;if(t){const e=f-32;u(this.pattern.substr(e),e)}}else u(this.pattern,0)}searchIn(e){const{isCaseSensitive:t,ignoreDiacritics:r,includeMatches:n}=this.options;if(e=t?e:e.toLowerCase(),e=r?Uy(e):e,this.pattern===e){const t={isMatch:!0,score:0};return n&&(t.indices=[[0,e.length-1]]),t}const{location:i,distance:o,threshold:a,findAllMatches:s,minMatchCharLength:c,ignoreLocation:l}=this.options,u=[];let f=0,d=!1;this.chunks.forEach(({pattern:t,alphabet:r,startIndex:g})=>{const{isMatch:p,score:h,indices:A}=Ny(e,t,r,{location:i+g,distance:o,threshold:a,findAllMatches:s,minMatchCharLength:c,includeMatches:n,ignoreLocation:l});p&&(d=!0),f+=h,p&&A&&u.push(...A)});const g={isMatch:d,score:d?f/this.chunks.length:1};return d&&n&&(g.indices=My(u)),g}};const Oy=new Set(["fuzzy","include"]);function Ty(e){return e.startsWith("inverse")}const Yy=[{type:"exact",multiRegex:/^="(.*)"$/,singleRegex:/^=(.*)$/,create:e=>({type:"exact",search(t){const r=t===e;return{isMatch:r,score:r?0:1,indices:[0,e.length-1]}}})},{type:"include",multiRegex:/^'"(.*)"$/,singleRegex:/^'(.*)$/,create:e=>({type:"include",search(t){let r,n=0;const i=[],o=e.length;for(;(r=t.indexOf(e,n))>-1;)n=r+o,i.push([r,n-1]);const a=!!i.length;return{isMatch:a,score:a?0:1,indices:i}}})},{type:"prefix-exact",multiRegex:/^\^"(.*)"$/,singleRegex:/^\^(.*)$/,create:e=>({type:"prefix-exact",search(t){const r=t.startsWith(e);return{isMatch:r,score:r?0:1,indices:[0,e.length-1]}}})},{type:"inverse-prefix-exact",multiRegex:/^!\^"(.*)"$/,singleRegex:/^!\^(.*)$/,create:e=>({type:"inverse-prefix-exact",search(t){const r=!t.startsWith(e);return{isMatch:r,score:r?0:1,indices:[0,t.length-1]}}})},{type:"inverse-suffix-exact",multiRegex:/^!"(.*)"\$$/,singleRegex:/^!(.*)\$$/,create:e=>({type:"inverse-suffix-exact",search(t){const r=!t.endsWith(e);return{isMatch:r,score:r?0:1,indices:[0,t.length-1]}}})},{type:"suffix-exact",multiRegex:/^"(.*)"\$$/,singleRegex:/^(.*)\$$/,create:e=>({type:"suffix-exact",search(t){const r=t.endsWith(e);return{isMatch:r,score:r?0:1,indices:[t.length-e.length,t.length-1]}}})},{type:"inverse-exact",multiRegex:/^!"(.*)"$/,singleRegex:/^!(.*)$/,create:e=>({type:"inverse-exact",search(t){const r=-1===t.indexOf(e);return{isMatch:r,score:r?0:1,indices:[0,t.length-1]}}})},{type:"fuzzy",multiRegex:/^"(.*)"$/,singleRegex:/^(.*)$/,create:(e,t={})=>{const r=new Ry(e,{location:t.location??Qy.location,threshold:t.threshold??Qy.threshold,distance:t.distance??Qy.distance,includeMatches:t.includeMatches??Qy.includeMatches,findAllMatches:t.findAllMatches??Qy.findAllMatches,minMatchCharLength:t.minMatchCharLength??Qy.minMatchCharLength,isCaseSensitive:t.isCaseSensitive??Qy.isCaseSensitive,ignoreDiacritics:t.ignoreDiacritics??Qy.ignoreDiacritics,ignoreLocation:t.ignoreLocation??Qy.ignoreLocation});return{type:"fuzzy",search:e=>r.searchIn(e)}}}],jy=Yy.length;function Gy(e,t){const r=e.match(t);return r?r[1]:null}const Jy=[];function zy(...e){Jy.push(...e)}function Vy(e,t){for(let r=0,n=Jy.length;r<n;r+=1){const n=Jy[r];if(n.condition(e,t))return new n(e,t)}return new Ry(e,t)}const Py="$and",Xy="$or",_y="$path",Wy="$val",Ky=e=>!(!e[Py]&&!e[Xy]),$y=e=>({[Py]:Object.keys(e).map(t=>({[t]:e[t]}))});function Zy(e,t,{auto:r=!0}={}){const n=e=>{if(hy(e)){const n={keyId:null,pattern:e};return r&&(n.searcher=Vy(e,t)),n}const i=Object.keys(e),o=(e=>!!e[_y])(e);if(!o&&i.length>1&&!Ky(e))return n($y(e));if((e=>!gy(e)&&Iy(e)&&!Ky(e))(e)){const n=o?e[_y]:i[0],a=o?e[Wy]:e[n];if(!hy(a))throw new Error((e=>`Invalid value for key ${e}`)(n));const s={keyId:Dy(n),pattern:a};return r&&(s.searcher=Vy(a,t)),s}const a={children:[],operator:i[0]};return i.forEach(t=>{const r=e[t];gy(r)&&r.forEach(e=>{a.children.push(n(e))})}),a};return Ky(e)||(e=$y(e)),n(e)}function ev(e,{ignoreFieldNorm:t=Qy.ignoreFieldNorm}){let r=1;return e.forEach(({key:e,norm:n,score:i})=>{const o=e?e.weight:null;r*=Math.pow(0===i&&o?Number.EPSILON:i,(o||1)*(t?1:n))}),r}var tv=class{constructor(e){this.limit=e,this.heap=[]}get size(){return this.heap.length}shouldInsert(e){return this.size<this.limit||e<this.heap[0].score}insert(e){this.size<this.limit?(this.heap.push(e),this._bubbleUp(this.size-1)):e.score<this.heap[0].score&&(this.heap[0]=e,this._sinkDown(0))}extractSorted(e){return this.heap.sort(e)}_bubbleUp(e){const t=this.heap;for(;e>0;){const r=e-1>>1;if(t[e].score<=t[r].score)break;const n=t[e];t[e]=t[r],t[r]=n,e=r}}_sinkDown(e){const t=this.heap,r=t.length;let n=e;do{const i=2*(e=n)+1,o=2*e+2;if(i<r&&t[i].score>t[n].score&&(n=i),o<r&&t[o].score>t[n].score&&(n=o),n!==e){const r=t[e];t[e]=t[n],t[n]=r}}while(n!==e)}};function rv(e,t,{includeMatches:r=Qy.includeMatches,includeScore:n=Qy.includeScore}={}){return e.map(e=>{const{idx:i}=e,o={item:t[i],refIndex:i};return r&&(o.matches=function(e){const t=[];return e.matches.forEach(e=>{if(!yy(e.indices)||!e.indices.length)return;const r={indices:e.indices,value:e.value};e.key&&(r.key=e.key.id),e.idx>-1&&(r.refIndex=e.idx),t.push(r)}),t}(e)),n&&(o.score=e.score),o})}const nv=/[\p{L}\p{M}\p{N}_]+/gu,iv=new WeakSet;function ov(e){if("function"==typeof e){let t=!1;return r=>{const n=e(r);if(!t&&(t=!0,!Array.isArray(n)||n.some(e=>"string"!=typeof e)))throw new Error(`[Fuse] tokenize function must return string[]; received ${Array.isArray(n)?"array containing non-strings":typeof n}.`);return n}}return e instanceof RegExp?(e.global||function(e){iv.has(e)||(iv.add(e),console.warn(`[Fuse] tokenize regex ${e} lacks the global flag; only the first match per text will be returned. Add the 'g' flag.`))}(e),t=>t.match(e)||[]):e=>e.match(nv)||[]}function av({isCaseSensitive:e=!1,ignoreDiacritics:t=!1,tokenize:r}={}){const n=ov(r);return{tokenize:r=>(e||(r=r.toLowerCase()),t&&(r=Uy(r)),n(r))}}function sv(e,t,r,n){const i=n.tokenize(t);if(!i.length)return;e.fieldCount++,e.docFieldCount.set(r,(e.docFieldCount.get(r)||0)+1);const o=new Set(i);let a=e.docTermFieldHits.get(r);a||(a=new Map,e.docTermFieldHits.set(r,a));for(const t of o)a.set(t,(a.get(t)||0)+1),e.df.set(t,(e.df.get(t)||0)+1)}function cv(e,t,r,n){const{i:i,v:o,$:a}=t;if(void 0===o){if(a)for(let t=0;t<r;t++){const r=a[t];if(r)if(Array.isArray(r))for(const t of r)sv(e,t.v,i,n);else sv(e,r.v,i,n)}}else sv(e,o,i,n)}function lv(e,t){const r=e.docFieldCount.get(t);if(void 0===r)return;e.fieldCount-=r,e.docFieldCount.delete(t);const n=e.docTermFieldHits.get(t);if(n){for(const[t,r]of n){const n=(e.df.get(t)||0)-r;n<=0?e.df.delete(t):e.df.set(t,n)}e.docTermFieldHits.delete(t)}}function uv(e,t){if(0===t.length)return;const r=Array.from(new Set(t)).sort((e,t)=>e-t);for(const t of r)lv(e,t);const n=e=>{let t=0,n=r.length;for(;t<n;){const i=t+n>>>1;r[i]<e?t=i+1:n=i}return e-t},i=r[0],o=new Map;for(const[t,r]of e.docFieldCount)o.set(t>i?n(t):t,r);e.docFieldCount=o;const a=new Map;for(const[t,r]of e.docTermFieldHits)a.set(t>i?n(t):t,r);e.docTermFieldHits=a}var fv=class{constructor(e,t,r){this.options={...Qy,...t},this.options.useExtendedSearch,this.options.useTokenSearch,this._keyStore=new Ey(this.options.keys),this._docs=e,this._myIndex=null,this._invertedIndex=null,this.setCollection(e,r),this._lastQuery=null,this._lastSearcher=null}_getSearcher(e){if(this._lastQuery===e)return this._lastSearcher;const t=Vy(e,this._invertedIndex?{...this.options,_invertedIndex:this._invertedIndex}:this.options);return this._lastQuery=e,this._lastSearcher=t,t}setCollection(e,t){if(this._docs=e,t&&!(t instanceof Sy))throw new Error("Incorrect 'index' type");if(this._myIndex=t||ky(this.options.keys,this._docs,{getFn:this.options.getFn,fieldNormWeight:this.options.fieldNormWeight}),this.options.useTokenSearch){const e=av({isCaseSensitive:this.options.isCaseSensitive,ignoreDiacritics:this.options.ignoreDiacritics,tokenize:this.options.tokenize});this._invertedIndex=function(e,t,r){const n={fieldCount:0,df:new Map,docFieldCount:new Map,docTermFieldHits:new Map};for(const i of e)cv(n,i,t,r);return n}(this._myIndex.records,this._myIndex.keys.length,e)}this._invalidateSearcherCache()}add(e){if(!yy(e))return;this._docs.push(e);const t=this._myIndex.add(e,this._docs.length-1);if(this._invertedIndex&&t){const e=av({isCaseSensitive:this.options.isCaseSensitive,ignoreDiacritics:this.options.ignoreDiacritics,tokenize:this.options.tokenize});!function(e,t,r,n){cv(e,t,r,n)}(this._invertedIndex,t,this._myIndex.keys.length,e)}this._invalidateSearcherCache()}remove(e=()=>!1){const t=[],r=[];for(let n=0,i=this._docs.length;n<i;n+=1)e(this._docs[n],n)&&(t.push(this._docs[n]),r.push(n));if(r.length){this._invertedIndex&&uv(this._invertedIndex,r);const e=new Set(r);this._docs=this._docs.filter((t,r)=>!e.has(r)),this._myIndex.removeAll(r),this._invalidateSearcherCache()}return t}removeAt(e){if(!Number.isInteger(e)||e<0||e>=this._docs.length)throw new Error(wy);this._invertedIndex&&uv(this._invertedIndex,[e]);const t=this._docs.splice(e,1)[0];return this._myIndex.removeAt(e),this._invalidateSearcherCache(),t}_invalidateSearcherCache(){this._lastQuery=null,this._lastSearcher=null}getIndex(){return this._myIndex}search(e,t){const{limit:r=-1}=t||{},{includeMatches:n,includeScore:i,shouldSort:o,sortFn:a,ignoreFieldNorm:s}=this.options;if(hy(e)&&!e.trim()){let e=this._docs.map((e,t)=>({item:e,refIndex:t}));return Ay(r)&&r>-1&&(e=e.slice(0,r)),e}let c;if(Ay(r)&&r>0&&hy(e)){const t=new tv(r);hy(this._docs[0])?this._searchStringList(e,{heap:t,ignoreFieldNorm:s}):this._searchObjectList(e,{heap:t,ignoreFieldNorm:s}),c=t.extractSorted(a)}else c=hy(e)?hy(this._docs[0])?this._searchStringList(e):this._searchObjectList(e):this._searchLogical(e),function(e,{ignoreFieldNorm:t=Qy.ignoreFieldNorm}){e.forEach(e=>{e.score=ev(e.matches,{ignoreFieldNorm:t})})}(c,{ignoreFieldNorm:s}),o&&c.sort(a),Ay(r)&&r>-1&&(c=c.slice(0,r));return rv(c,this._docs,{includeMatches:n,includeScore:i})}_searchStringList(e,{heap:t,ignoreFieldNorm:r}={}){const n=this._getSearcher(e),i=this.options.useTokenSearch&&"all"===this.options.tokenMatch,{records:o}=this._myIndex,a=t?null:[];return o.forEach(({v:e,i:o,n:s})=>{if(!yy(e))return;const c=n.searchIn(e);if(c.isMatch){const n={score:c.score,value:e,norm:s,indices:c.indices};i&&(n.matchedMask=c.matchedMask,n.matchedTerms=c.matchedTerms,n.termCount=c.termCount);const l=[n];if(!i||this._coversAllTokens(l)){const n={item:e,idx:o,matches:l};t?(n.score=ev(n.matches,{ignoreFieldNorm:r}),t.shouldInsert(n.score)&&t.insert(n)):a.push(n)}}}),a}_searchLogical(e){const t=Zy(e,this.options),r=(e,t,n)=>{if(!("children"in e)){const{keyId:r,searcher:i}=e;let o;return null===r?(o=[],this._myIndex.keys.forEach((e,r)=>{o.push(...this._findMatches({key:e,value:t[r],searcher:i}))})):o=this._findMatches({key:this._keyStore.get(r),value:this._myIndex.getValueForItemAtKeyId(t,r),searcher:i}),o&&o.length?[{idx:n,item:t,matches:o}]:[]}const{children:i,operator:o}=e,a=[];for(let e=0,s=i.length;e<s;e+=1){const s=i[e],c=r(s,t,n);if(c.length)a.push(...c);else if(o===Py)return[]}return a},n=this._myIndex.records,i=new Map,o=[];return n.forEach(({$:e,i:n})=>{if(yy(e)){const a=r(t,e,n);a.length&&(i.has(n)||(i.set(n,{idx:n,item:e,matches:[]}),o.push(i.get(n))),a.forEach(({matches:e})=>{i.get(n).matches.push(...e)}))}}),o}_searchObjectList(e,{heap:t,ignoreFieldNorm:r}={}){const n=this._getSearcher(e),i=this.options.useTokenSearch&&"all"===this.options.tokenMatch,{keys:o,records:a}=this._myIndex,s=t?null:[];return a.forEach(({$:e,i:a})=>{if(!yy(e))return;const c=[];let l=!1,u=!1;if(o.forEach((t,r)=>{const i=this._findMatches({key:t,value:e[r],searcher:n});i.length?(c.push(...i),i[0].hasInverse&&(u=!0)):l=!0}),(!u||!l)&&c.length&&(!i||this._coversAllTokens(c))){const n={idx:a,item:e,matches:c};t?(n.score=ev(n.matches,{ignoreFieldNorm:r}),t.shouldInsert(n.score)&&t.insert(n)):s.push(n)}}),s}_findMatches({key:e,value:t,searcher:r}){if(!yy(t))return[];const n=[];if(gy(t))t.forEach(({v:t,i:i,n:o})=>{if(!yy(t))return;const a=r.searchIn(t);if(a.isMatch){const r={score:a.score,key:e,value:t,idx:i,norm:o,indices:a.indices,hasInverse:a.hasInverse};void 0!==a.termCount&&(r.matchedMask=a.matchedMask,r.matchedTerms=a.matchedTerms,r.termCount=a.termCount),n.push(r)}});else{const{v:i,n:o}=t,a=r.searchIn(i);if(a.isMatch){const t={score:a.score,key:e,value:i,norm:o,indices:a.indices,hasInverse:a.hasInverse};void 0!==a.termCount&&(t.matchedMask=a.matchedMask,t.matchedTerms=a.matchedTerms,t.termCount=a.termCount),n.push(t)}}return n}_coversAllTokens(e){const t=e.length?e[0].termCount:void 0;if(void 0===t)return!0;if(t<=31){let r=0;for(let t=0;t<e.length;t++)r|=e[t].matchedMask||0;return r===2**t-1}const r=new Set;for(let t=0;t<e.length;t++){const n=e[t].matchedTerms;if(n)for(const e of n)r.add(e)}return r.size===t}};fv.version="7.4.2",fv.createIndex=ky,fv.parseIndex=function(e,{getFn:t=Qy.getFn,fieldNormWeight:r=Qy.fieldNormWeight}={}){const{keys:n,records:i}=e,o=new Sy({getFn:t,fieldNormWeight:r});return o.setKeys(n),o.setIndexRecords(i),o},fv.config=Qy,fv.match=function(e,t,r){if(r&&r.useTokenSearch)throw new Error("Fuse.match does not support useTokenSearch: token search requires corpus-level statistics (df, fieldCount) that a one-off string comparison does not have. Use new Fuse(...).search(...) instead.");return Vy(e,{...Qy,...r}).searchIn(t)},fv.parseQuery=Zy,zy(class{constructor(e,{isCaseSensitive:t=Qy.isCaseSensitive,ignoreDiacritics:r=Qy.ignoreDiacritics,includeMatches:n=Qy.includeMatches,minMatchCharLength:i=Qy.minMatchCharLength,ignoreLocation:o=Qy.ignoreLocation,findAllMatches:a=Qy.findAllMatches,location:s=Qy.location,threshold:c=Qy.threshold,distance:l=Qy.distance}={}){this.query=null,this.options={isCaseSensitive:t,ignoreDiacritics:r,includeMatches:n,minMatchCharLength:i,findAllMatches:a,ignoreLocation:o,location:s,threshold:c,distance:l},e=t?e:e.toLowerCase(),e=r?Uy(e):e,this.pattern=e,this.query=function(e,t={}){return e.replace(/\\\|/g,"\0").split("|").map(e=>{const r=function(e){const t=[],r=e.length;let n=0;for(;n<r;){for(;n<r&&" "===e[n];)n++;if(n>=r)break;let i=n;for(;i<r&&" "!==e[i]&&'"'!==e[i];)i++;if(i<r&&'"'===e[i]){for(i++;i<r;){if('"'===e[i]){const t=i+1;if(t>=r||" "===e[t]){i++;break}if("$"===e[t]&&(t+1>=r||" "===e[t+1])){i+=2;break}}i++}t.push(e.substring(n,i)),n=i}else{for(;i<r&&" "!==e[i];)i++;t.push(e.substring(n,i)),n=i}}return t}(e.replace(/\u0000/g,"|").trim()).filter(e=>e&&!!e.trim()),n=[];for(let e=0,i=r.length;e<i;e+=1){const i=r[e];let o=!1,a=-1;for(;!o&&++a<jy;){const e=Yy[a],r=Gy(i,e.multiRegex);r&&(n.push(e.create(r,t)),o=!0)}if(!o)for(a=-1;++a<jy;){const e=Yy[a],r=Gy(i,e.singleRegex);if(r){n.push(e.create(r,t));break}}}return n})}(this.pattern,this.options)}static condition(e,t){return t.useExtendedSearch}searchIn(e){const t=this.query;if(!t)return{isMatch:!1,score:1};const{includeMatches:r,isCaseSensitive:n,ignoreDiacritics:i}=this.options;e=n?e:e.toLowerCase(),e=i?Uy(e):e;let o=0;const a=[];let s=0,c=!1;for(let n=0,i=t.length;n<i;n+=1){const i=t[n];a.length=0,o=0,c=!1;for(let t=0,n=i.length;t<n;t+=1){const n=i[t],{isMatch:l,indices:u,score:f}=n.search(e);if(!l){s=0,o=0,a.length=0,c=!1;break}o+=1,s+=f,Ty(n.type)&&(c=!0),r&&(Oy.has(n.type)?a.push(...u):a.push(u))}if(o){const e={isMatch:!0,score:s/o};return c&&(e.hasInverse=!0),r&&(e.indices=My(a)),e}}return{isMatch:!1,score:1}}}),zy(class{static condition(e,t){return t.useTokenSearch}constructor(e,t){this.options=t,this.analyzer=av({isCaseSensitive:t.isCaseSensitive,ignoreDiacritics:t.ignoreDiacritics,tokenize:t.tokenize});const r=this.analyzer.tokenize(e),{df:n,fieldCount:i}=t._invertedIndex;this.termSearchers=[],this.idfWeights=[];for(const e of r){this.termSearchers.push(new Ry(e,{location:t.location,threshold:t.threshold,distance:t.distance,includeMatches:t.includeMatches,findAllMatches:t.findAllMatches,minMatchCharLength:t.minMatchCharLength,isCaseSensitive:t.isCaseSensitive,ignoreDiacritics:t.ignoreDiacritics,ignoreLocation:!0}));const r=n.get(e)||0,o=Math.log(1+(i-r+.5)/(r+.5));this.idfWeights.push(o)}this.combineAll="all"===t.tokenMatch,this.numTerms=this.termSearchers.length,this.useMask=this.numTerms<=31}searchIn(e){if(!this.termSearchers.length)return{isMatch:!1,score:1};const t=[];let r=0,n=0,i=0,o=0;const a=this.combineAll&&!this.useMask?new Set:null;for(let s=0;s<this.termSearchers.length;s++){const c=this.termSearchers[s].searchIn(e),l=this.idfWeights[s];n+=l,c.isMatch&&(i++,r+=l*(1-c.score),c.indices&&t.push(...c.indices),this.combineAll&&(this.useMask?o|=1<<s:a.add(s)))}if(0===i)return{isMatch:!1,score:1};const s=n>0?1-r/n:0,c={isMatch:!0,score:Math.max(.001,s)};return this.options.includeMatches&&t.length&&(c.indices=My(t)),this.combineAll&&(this.useMask?c.matchedMask=o:c.matchedTerms=a,c.termCount=this.numTerms),c}}),fv.use=function(...e){e.forEach(e=>zy(e))};var dv=fv;function gv(e){return function(e,t){var r=null==e?0:e.length;return r?Ea(e,t)/r:NaN}(e,cr)}function pv(e){if(!Ee(e))return{};let{results:t,binarys:r}=e;if(!De(t))return{};if(!Ce(r))return{};let n={};try{n=JSON.parse(t,function(e,t){if(De(t)){if(t.indexOf("[Uint8Array]::")>=0){let e=Zi(t.replace("[Uint8Array]::",""));return r[e]}if(t.indexOf("[Uint16Array]::")>=0){let e=Zi(t.replace("[Uint16Array]::",""));return r[e]}if(t.indexOf("[ArrayBuffer]::")>=0){let e=Zi(t.replace("[ArrayBuffer]::",""));return r[e]}}return t})}catch(e){}return n}function hv(e,t=null){if(!va(r))throw new Error("invalid dayjs");if(!EI(e))return{today:null,msg:"",err:"時間格式錯誤"};let n=r();EI(t)&&(n=r(t,"YYYY-MM-DDTHH:mm:ss.SSSZ"));let i=r(e,"YYYY-MM-DDTHH:mm:ss.SSSZ");if(n>i)return{today:null,msg:"",err:"時間已過"};let o,a=n.format("YYYY-MM-DD"),s=i.format("YYYY-MM-DD"),c=r(a,"YYYY-MM-DD"),l=r(s,"YYYY-MM-DD"),u=i.diff(n,"seconds"),f=i.diff(n,"minutes"),d=i.diff(n,"hours"),g=l.diff(c,"days"),p=l.diff(c,"weeks"),h=l.diff(c,"months"),A=l.diff(c,"years"),m="即將到來";if(u>=0&&(o=!0,m=u+"秒後"),f>0&&(o=!0,m=f+"分鐘後"),d>0){let e=i.format("HH:mm");a===s?(o=!0,m=d+"小時後,今天"+e):(o=!1,m=d+"小時後,明天"+e)}return g>1&&(o=!1,m=2===g?"後天":g+"天後"),p>0&&(o=!1,m=p+"周後"),h>0&&(o=!1,m=h+"個月後"),A>0&&(o=!1,m=A+"年後"),{today:o,msg:m,err:""}}function Av(e,t=null){if(!va(r))throw new Error("invalid dayjs");if(!EI(e))return{today:null,msg:"",err:"時間格式錯誤"};let n=r();EI(t)&&(n=r(t,"YYYY-MM-DDTHH:mm:ss.SSSZ"));let i=r(e,"YYYY-MM-DDTHH:mm:ss.SSSZ");if(n<i)return{today:null,msg:"",err:"時間未到"};let o=n.format("YYYY-MM-DD"),a=i.format("YYYY-MM-DD"),s=r(o,"YYYY-MM-DD"),c=r(a,"YYYY-MM-DD"),l=n.diff(i,"seconds"),u=n.diff(i,"minutes"),f=n.diff(i,"hours"),d=s.diff(c,"days"),g=s.diff(c,"weeks"),p=s.diff(c,"months"),h=s.diff(c,"years"),A=!1,m="剛剛";if(l>=0&&(A=!0,m=l+"秒前"),u>0&&(A=!0,m=u+"分鐘前"),f>0){let e=i.format("HH:mm");o===a?(A=!0,m=f+"小時前"):(A=!1,m="昨天"+e)}return d>1&&(A=!1,m=d+"天前"),g>0&&(A=!1,m=g+"周前"),p>0&&(A=!1,m=p+"個月前"),h>0&&(A=!1,m=h+"年前"),{today:A,msg:m,err:""}}function mv(e){let t=BI.sepTZ(e);return e=`${t.t}.000${t.tz}`}function Iv(e){let t=BI.sepTZ(e);return e=`${t.t}.000${t.tz}`}function yv(e){if(!Za(e))return"";let t;try{t=Wa(LI(e))}catch(e){return""}return t}e.ab2blob=function(e){let t=y(e);return new Blob([t])},e.ab2u8arr=y,e.addExcelWorksheetFromData=function(e,t,r="data"){if(!Ee(e))return{error:"wb is not an effective object"};if(!Ce(we(e,"SheetNames")))return{error:"wb.SheetNames is not an array"};if(!Be(we(e,"Sheets")))return{error:"wb.Sheets is not an object"};let n=bn(t);return ke(n,"error")?n:(e.SheetNames.push(r),e.Sheets[r]=n,e)},e.addMonth=function(e,t){return wn(e)&&Hn(t)?r(e,"YYYY-MM").add(t,"months").format("YYYY-MM"):""},e.aes2str=li,e.alive=function(e={}){let t=Xi(),r={},n=null,i=we(e,"timeAlive");eo(i)||(i=1e4),i=Zi(i);let o=we(e,"timeDetect");return eo(o)||(o=50),o=Zi(o),t.trigger=function(e,a){De(e)?(ke(r,e)||setTimeout(()=>{t.emit("message",{eventName:"enter",key:e,data:a,now:dn(r)})},1),r[e]={data:a,time:Date.now()},null===n&&(n=setInterval(()=>{Er(r,(e,n)=>{if(Date.now()-e.time>i){let e=zi(r[n]);delete r[n],t.emit("message",{eventName:"leave",key:n,data:e.data,now:dn(r)})}}),Ee(r)||(clearInterval(n),n=null)},o))):console.log("trigger need key")},t.get=function(){let e=[];return Er(r,(t,r)=>{e.push({key:r,data:t.data})}),e=zi(e),e},t},e.arr2dt=function(e,t=""){if(!Rr(e))return{};if(Rr(t))return dn(e)===dn(t)?to(e,t):{};let r=[];for(let n=0;n<dn(e);n++)r.push(zi(t));return to(e,r)},e.arrAccum=function(e){if(!Rr(e))return[];let t=[],r=0;return Er(e,function(e){r+=Mn(e),Se(e)?t.push(r):t.push("")}),t},e.arrAdd=function(){if(dn(arguments)<2)return[];let e=arguments[0];for(let t=1;t<dn(arguments);t++){e=ro(e,arguments[t])}return e},e.arrAt=Eo,e.arrDiff=aa,e.arrFilterByKeywords=function(e,t){if(!Rr(e))return[];if(!De(t)&&!Rr(t))return[];let r=null;r=De(t)?la(t," "):t;let n=dn(r);return xr(e,e=>function(e){let t=!1,i=0;for(let o=0;o<n;o++){let a=r[o],s=a,c="+"===ua(a,1),l="-"===ua(a,1);if((c||l)&&(s=da(a,1)),""===sa(s))continue;let u=e.indexOf(s)>=0;if(c){if(u){t=!0,i=1;break}t=!1,i=0;break}if(l){if(u){t=!1,i=0;break}t=!0,i=1;break}if(u){t=!0;let e=1-o/n;e=e**2,i+=e}}return{hasKeyword:t,weight:i}}(e))},e.arrFilterByNum=function(e){return Rr(e)?e=xr(e=pa(e=zi(e),Se),Mn):[]},e.arrFilterByPnum=Aa,e.arrFilterByPnumAndToLog=function(e){return Rr(e)?e=xr(e=Aa(e),Math.log):[]},e.arrFind=function(e,t){function r(e){return Ce(e)?e:[e]}return Ur(e)||0===(e=r(e)).length||Ur(t)?[]:xr(t=r(t),function(t){let r=-1;for(let n=0;n<e.length;n++)if(ma(e[n],t)){r=n;break}return r})},e.arrGroupByMaxmin=function(e,t,r={}){let n=we(r,"keyMax");De(n)||(n="max");let i=we(r,"keyMin");De(i)||(i="min");let o=we(r,"keyValue");De(o)||(o="value");let a=we(r,"keyItems");if(De(a)||(a="items"),!Rr(e))return[];if(!Rr(t))return[];let s=zi(t);return Er(e,(e,r)=>{let c=we(e,o);Se(c)?c=Mn(c):Se(e)&&(c=Mn(e)),Ia(c)&&Er(t,(t,r)=>{let o=we(t,n,null),l=we(t,i,null);if(null!==o&&null!==l&&Se(o)&&Se(l)){let n=we(t,"maxType");"<="!==n&&"<"!==n&&(n="<=");let i,u,f=we(t,"minType");">="!==f&&">"!==f&&(f=">="),o=Mn(o),l=Mn(l),i=">="===f?c>=l:c>l,u="<="===n?c<=o:c<o,i&&u&&(ke(s[r],a)||(s[r][a]=[]),s[r][a].push(e))}})}),s},e.arrHas=ya,e.arrInsert=function(e,t,r){if(!Ce(e))return[];if(Ce(r)||(r=[r]),!Bo(t))return e;if((t=Zi(t))>dn(e))return e;let n=e;try{n=[...e.slice(0,t),...r,...e.slice(t)]}catch(e){}return n},e.arrLookupByMaxmin=function(e,t,r={}){let n=we(r,"keyMax");De(n)||(n="max");let i=we(r,"keyMin");De(i)||(i="min");let o=we(r,"keyValue");De(o)||(o="value");let a=we(r,"keyItems");De(a)||(a="items");let s=we(r,"beforeAddResult",null);if(!Rr(e))return[];if(!Rr(t))return[];if(!Ee(we(e,0)))return[];let c=zi(e);return Er(c,(e,r)=>{let l=we(e,o);Se(l)&&(l=Mn(l)),Ia(l)&&Er(t,(e,t)=>{let o=we(e,n,null),u=we(e,i,null);if(null!==o&&null!==u&&Se(o)&&Se(u)){let t=we(e,"maxType");"<="!==t&&"<"!==t&&(t="<=");let n,i,f=we(e,"minType");">="!==f&&">"!==f&&(f=">="),o=Mn(o),u=Mn(u),n=">="===f?l>=u:l>u,i="<="===t?l<=o:l<o,n&&i&&(va(s)&&(e=s(e,c[r],r)),ke(c[r],a)||(c[r][a]=[]),c[r][a].push(e))}})}),c},e.arrMax=function(e,t={}){if(!Rr(e))return null;let r=we(t,"returnIndex");pn(r)||(r=!1);let n=we(t,"compareKey",null),i=e;De(n)&&(i=xr(e,(e,t)=>we(e,n,"")));let o=null,a=ba(i,(e,t)=>Se(t)?(t=Mn(t),null===e?(o=t,t):(e=Math.max(e,t),o=e,e)):e,{returnIndex:!0});if(r)return a;let s=null;return a>=0&&(s=De(n)?e[a]:o),s},e.arrMin=function(e,t={}){if(!Rr(e))return null;let r=we(t,"returnIndex");pn(r)||(r=!1);let n=we(t,"compareKey",null),i=e;De(n)&&(i=xr(e,(e,t)=>we(e,n,"")));let o=null,a=ba(i,(e,t)=>Se(t)?(t=Mn(t),null===e?(o=t,t):(e=Math.min(e,t),o=e,e)):e,{returnIndex:!0});if(r)return a;let s=null;return a>=0&&(s=De(n)?e[a]:o),s},e.arrMulti=Ba,e.arrNorm=function(e){if(!Rr(e))return null;let t=Ca(e,e);return Se(t)?t<=0?null:Math.sqrt(t):null},e.arrProduct=Ca,e.arrPull=function(e,t){if(!Rr(e))return[];if((Be(t)||Se(t)||xe(t)||pn(t))&&(t=[t]),!Rr(t))return e;let r=zi(e);return Fa(r,t),r},e.arrPullAt=function(e,t){if(!Rr(e))return[];if(Bo(t)&&(t=[t]),!Rr(t))return e;t=xr(t,e=>Zi(e));let r=zi(e);return Ma(r,t),r},e.arrReduce=ba,e.arrReverse=function(e){if(!Rr(e))return[];let t=zi(e);return La(t),t},e.arrSep=function(e,t){if(!Rr(e))return[];if(!eo(t)&&!Ee(t))return[];let r="",n=null;if(eo(t))n=t,r="numCount";else if(Ee(t))if(eo(we(t,"numCount")))n=t.numCount,r="numCount";else{if(!eo(we(t,"numGroup")))throw new Error("invalid opt.numCount or opt.numGroup");n=t.numGroup,r="numGroup"}let i=dn(e),o=[];if("numCount"===r)for(let t=0;t<i;t+=n){let r=[];for(let o=0;o<n;o++){let n=t+o;n<i&&r.push(e[n])}o.push(r)}else if("numGroup"===r){for(let e=0;e<n;e++)o[e]=[];let t=-1;for(let r=0;r<i;r++)t++,t>n-1&&(t=0),o[t].push(e[r])}return o},e.arrSort=_a,e.asind=function(e){return Se(e)?(e=Mn(e),180*Math.asin(e)/Math.PI):null},e.atan2d=function(e,t){return Se(e)?(e=Mn(e),Se(t)?(t=Mn(t),180*Math.atan2(t,e)/Math.PI):null):null},e.atand=function(e){return Se(e)?(e=Mn(e),180*Math.atan(e)/Math.PI):null},e.attstr=function(e={}){let t=";",r="@",n="table",i="id",o=we(e,"uniqItems");pn(o)||(o=!1);let a=we(e,"dlmItem","");De(a)&&(t=a);let s=we(e,"dlmSep","");De(s)&&(r=s);let c=we(e,"keyTable","");De(c)&&(n=c);let l=we(e,"keyId","");De(l)&&(i=l);let u=we(e,"mode");function f(e){if(!De(e))return[];let r=Jo(e,t);return o&&(r=Pr(r)),r}function d(e){if(!Rr(e))return"";return o&&(e=Pr(e)),xo(e,t)}function g(e){return e=pa(e,De),o&&(e=Pr(e)),d(e)}function p(e){let t=[];return Er(e,e=>{let o=we(e,n,""),a=we(e,i,"");if(De(o),xe(a)||(Ce(a)?dn(a):a=""),xe(a))t.push(`${o}${r}${a}`);else if(Ce(a)){let e=xo(a,r);t.push(`${o}${r}${e}`)}}),e=d(t)}function h(e){if(!De(e))return[];return pa(f(e),De)}function A(e){if(!De(e))return[];let t=f(e),o=[];return Er(t,e=>{let t=Jo(e,r),a=we(t,0,""),s=we(t,1,"");dn(t)>=3&&(t=ja(t),s=t),o.push({item:e,[n]:a,[i]:s})}),o}function m(e,t){let r=[...h(e),...h(t)];return 0===dn(r)?"":g(r)}function I(e,t){let r=[...A(e),...A(t)];return 0===dn(r)?"":p(r)}function y(e,t){let r=h(e),n=h(t),i=[];return Er(r,e=>{ya(e,n)||i.push(e)}),0===dn(i)?"":g(i)}function v(e,t){let r=A(e),n=A(t),i=[];return Er(r,e=>{ya(e,n)||i.push(e)}),0===dn(i)?"":p(i)}"1p"!==u&&"2p"!==u&&(u="auto");let b={parse:function(e,t={}){if(!De(e))return[];let n=we(t,"mode");return"1p"!==n&&"2p"!==n&&(n=u),"1p"===n?h(e):"2p"===n||e.indexOf(r)>=0?A(e):h(e)},join:function(e,t={}){if(!Rr(e))return"";let r=we(t,"mode");if("1p"!==r&&"2p"!==r&&(r=u),"1p"===r)return g(e);if("2p"===r)return p(e);let o=we(e,0);return ke(o,n)&&ke(o,i)?p(e):g(e)},remove:function(e,t,n={}){if(!De(e))return"";if(!De(t))return e;let i=we(n,"mode");return"1p"!==i&&"2p"!==i&&(i=u),"1p"===i?y(e,t):"2p"===i||t.indexOf(r)>=0?v(e,t):y(e,t)},add:function(e,t,n={}){let i=we(n,"mode");if("1p"!==i&&"2p"!==i&&(i=u),"1p"===i)return m(e,t);if("2p"===i)return I(e,t);let o=e.indexOf(r)>=0,a=t.indexOf(r)>=0;return o||a?I(e,t):m(e,t)}};return b},e.b642obj=function(e){if(!xe(e))return{};let t={};try{t=Ka(Wa(e))}catch(e){t={}}return t},e.b642str=Wa,e.b642u16arr=ts,e.b642u8arr=$a,e.binstr=rs,e.blob2ab=is,e.blob2b64=os,e.blob2str=function(e){let t=ns(),r=new FileReader;return r.onload=function(){t.resolve(r.result)},r.onerror=function(e){t.reject(e)},r.readAsText(e),t},e.blob2u8arr=as,e.blobs2b64s=ss,e.blobs2u8arrs=cs,e.bodyLog=function(){let e=`\n <div style="padding:5px; font-size:10pt; font-family:Microsoft JhengHei, Helvetica;">\n <span style="color:#f26;">log: </span>\n <code>${fs(xr(arguments,function(e){return hn(e)}).join(", "))}</code>\n </div>\n `;document.querySelector("body").insertAdjacentHTML("beforeend",e)},e.browserView=ds,e.browserViewFromBlob=function(e,t){gs(e)&&ds(e,t)},e.browserViewFromText=function(e){xe(e)&&ds(e,"text/plain")},e.browserViewFromU8arr=function(e,t){Za(e)&&ds(e,t)},e.bs2u8arr=ps,e.bufRead=hs,e.bufReadDbl=As,e.bufWrite=ms,e.bufWriteDbl=Is,e.cache=function(){let e=Xi(),t={};function r(t,r){setTimeout(()=>{e.emit(t,r)},1)}function n(e,n={}){if(ke(t,e))return;let i=we(n,"fun");va(i)||(i=async()=>{});let o=we(n,"inputs");Ce(o)||(o=[]);let a=we(n,"timeExpired");eo(a)||(a=5e3),a=Zi(a),t[e]={needExec:!0,fun:i,running:!1,inputs:o,value:null,time:null,timeExpired:a},r("message",{fun:"set",key:e,timeExpired:a})}async function i(e){if(ke(t,e)){let n;r("message",{fun:"get",key:e,msg:"waiting"}),await vs(()=>!t[e].running,{timeInterval:1e3});let i=Date.now();n=t[e].needExec;let o=i-t[e].time;return n?r("message",{fun:"get",key:e,msg:"execute first"}):t[e].timeExpired>0&&o>t[e].timeExpired&&(r("message",{fun:"get",key:e,msg:"execute by timeExpired",timeDiff:o}),n=!0),n?(r("message",{fun:"get",key:e,msg:"fun start"}),t[e].running=!0,t[e].value=await t[e].fun(...t[e].inputs).catch(t=>{r("error",{fun:"get",key:e,msg:t})}),t[e].needExec=!1,t[e].time=i,t[e].running=!1,r("message",{fun:"get",key:e,msg:"fun end"})):r("message",{fun:"get",key:e,msg:"use cache"}),zi(t[e].value)}return r("error",{fun:"get",key:e,msg:"invalid key"}),null}return e.set=n,e.getProxy=async function(e,t={}){return n(e,t),i(e)},e.get=i,e.update=function(e,n){ke(t,e)&&(r("message",{fun:"updateValue",key:e}),t[e].value=n,t[e].time=Date.now())},e.clear=function(e){ke(t,e)&&(r("message",{fun:"clear",key:e}),t[e].needExec=!0)},e.remove=function(e){ke(t,e)&&(r("message",{fun:"remove",key:e}),delete t[e])},e},e.cacheBd=function(e,t={}){let r=we(t,"nMax");eo(r)||(r=200),r=Zi(r);let n=we(t,"nTrigger");eo(n)||(n=3),n=Zi(n);let i=null,o=!1,a=async(...t)=>(o=!0,i=await e(...t),o=!1,i);return{get:a,getFromCache:async(...e)=>{for(let t=1;t<=r&&(t>n&&!o&&await a(...e).catch(()=>{}),null===i);t++)await bs(1e3);if(null===i)throw new Error(`exceeded nMax[${r}]`);return i}}},e.cacheSt=function(e={}){let t=we(e,"timeExpire",null);eo(t)||(t=18e5),t=Zi(t);let r=we(e,"timeDetect",null);eo(r)||(r=2e3),r=Zi(r);let n=Xi(),i={},o=e=>{if(ke(i,e)){let t=`checkWithSet: key in use: ${e}`;return n.emit("checkWithSet",{state:"error",msg:t}),!1}i[e]={time:Date.now(),value:!0};let t=`checkWithSet: ${e}`;return n.emit("checkWithSet",{state:"success",msg:t}),!0},a=setInterval(()=>{n.emit("detect",{state:"start"});let e=Date.now();for(let r of Object.keys(i)){let n=i[r];n&&e-n.time>t&&delete i[r]}n.emit("detect",{state:"finish"})},r);return n.checkWithSet=o,n.setWithFree=async(e,t)=>{n.emit("setWithFree",{state:"start"});let r=[];for(let t of e){if(!o(t)){for(let e of r)delete i[e];let e=`setWithFree: key in use: ${t}`;return n.emit("setWithFree",{state:"error",msg:e}),Promise.reject(e)}r.push(t)}try{let r=await t(),i=`setWithFree: ${e.join(", ")}`;return n.emit("setWithFree",{state:"success",msg:i}),r}catch(e){let t=`setWithFree: fn threw: ${e&&e.message||e}`;throw n.emit("setWithFree",{state:"error",msg:t}),e}finally{for(let e of r)delete i[e]}},n.set=async(e,t=!0)=>{i[e]={time:Date.now(),value:t};let r=`set: ${e}`;n.emit("set",{state:"success",msg:r})},n.get=async e=>{let t=i[e],r=void 0===t?null:t.value,o=`get: ${e}`;return n.emit("get",{state:"success",msg:o}),r},n.check=async e=>{let t=ke(i,e),r=`check: ${e} = ${t}`;return n.emit("check",{state:"success",msg:r}),t},n.del=async e=>{delete i[e];let t=`del: ${e}`;n.emit("del",{state:"success",msg:t})},n.waitExist=async(e,t={})=>{let r=we(t,"attemptNum",null);eo(r)||(r=30),r=Zi(r);let o=we(t,"timeInterval",null);eo(o)||(o=100),o=Zi(o),n.emit("waitExist",{state:"start"});try{await vs(()=>ke(i,e),{attemptNum:r,timeInterval:o})}catch(t){let i=`waitExist timeout (${r*o}ms): ${e}`;return n.emit("waitExist",{state:"error",msg:i}),Promise.reject(i)}let a=`waitExist resolved: ${e}`;n.emit("waitExist",{state:"success",msg:a})},n.waitNotExist=async(e,t={})=>{let r=we(t,"attemptNum",null);eo(r)||(r=30),r=Zi(r);let o=we(t,"timeInterval",null);eo(o)||(o=100),o=Zi(o),n.emit("waitNotExist",{state:"start"});try{await vs(()=>!ke(i,e),{attemptNum:r,timeInterval:o})}catch(t){let i=`waitNotExist timeout (${r*o}ms): ${e}`;return n.emit("waitNotExist",{state:"error",msg:i}),Promise.reject(i)}let a=`waitNotExist resolved: ${e}`;n.emit("waitNotExist",{state:"success",msg:a})},n.clear=()=>{clearInterval(a)},n},e.cbol=function(e){if(pn(e))return e;if(0===e)return!1;if(1===e)return!0;let t=!1;return De(e)&&"true"===(e=ws(sa(e)))&&(t=!0),t},e.cdbl=Mn,e.ceil=ol,e.cfilesize=function(e){return Se(e)?(e=Mn(e))<1024?al(e,1)+" b":e<1048576?al(e/1024,1)+" kb":e<1073741824?al(e/1024/1024,1)+" mb":e<1099511627776?al(e/1024/1024/1024,1)+" gb":"":""},e.cfinancial=function(e,t=0){if(!Se(e))return"";if(!Bo(t))return"";let r=(e=al(e,t)).split("."),n=r[0],i=r.length>1?"."+r[1]:"",o=/(\d+)(\d{3})/;for(;o.test(n);)n=n.replace(o,"$1,$2");return n+i},e.cint=Zi,e.clearXSS=sl,e.clearXSSDyn=async function(e,t={},r){return Rr(r)||(r=["https://cdn.jsdelivr.net/npm/xss@1.0.15/dist/xss.min.js"]),await dl(r),sl(e)},e.color=Iu,e.composeToTree=Bu,e.convertToTree=function(e,t={}){if(!Ee(e)&&!Rr(e))return[];let r=we(t,"bindKey",null);De(r)||(r="id");let n=we(t,"bindParent",null);De(n)||(n="parentId");let i=we(t,"bindText",null);De(i)||(i="text");let o=we(t,"bindChildren",null);De(o)||(o="children");let a=we(t,"bindType",null);De(a)||(a="type");let s=we(t,"bindNumOfChilren",null);De(s)||(s="numOfChilren");let c=we(t,"bindRoot",null);De(c)||(c="root");let l=we(t,"saveExtProps",null);return pn(l)||(l=!1),De(c)&&(e={[c]:e}),Bu(Cu(e,{bindKey:r,bindParent:n,bindText:i,bindType:a,bindNumOfChilren:s}),{bindKey:r,bindParent:n,bindChildren:o,saveExtProps:l})},e.copyStrToClipboard=function(e,t={}){if(!xe(e))return"invalid input";let r=we(t,"eleParent");br(r)||(r=document.body);let n=document.createElement("textarea");if(n.style.position="fixed",n.style.left=0,n.style.top=0,n.style.zIndex=-1,n.style.background="transparent",n.style.color="transparent",n.value=e,r.appendChild(n),n.select(),!xu(n))return"ele can not be focusd";try{document.execCommand("copy")}catch(e){return"can not copy str to clipboard"}return r.removeChild(n),""},e.cosd=Du,e.cotd=function(e){return Se(e)?1/Fu(e=Mn(e)):null},e.createExcelWorkbook=Qu,e.cscd=function(e){return Se(e)?1/Su(e=Mn(e)):null},e.cstr=Ya,e.day2cht=function(e,t=!1){if(!ku(e))return"";let n=r(e,"YYYY-MM-DD"),i="";return i=t?n.month()+1+"月"+n.date()+"日":"民國 "+(n.year()-1911)+" 年 "+(n.month()+1)+" 月 "+n.date()+" 日",i},e.debounce=Nu,e.delay=bs,e.dig=al,e.digExp=function(e,t=0){if(!Se(e))return"";if(!Bo(t))return"";let r="";return r=0===(e=Mn(e))?"0":Math.abs(e)<=1e-6?e.toExponential(t):al(e,t),r},e.domAlert=function(e,t={}){if(!De(e))return;let r=we(t,"type","success");ke(Ou,r)||(r="success");let n=we(t,"icon",null);De(n)||(n=Ou[r]);let i="top-right";"top-left"!==t.position&&"bottom-right"!==t.position&&"bottom-left"!==t.position||(i=t.position);let o=we(t,"time");Ia(o)||(o=4e3),o<0&&(o=4e3);let a=we(t,"paddingStyle",null);null===a&&(a={top:14,right:26,bottom:14,left:14});let s="";{let e=we(a,"top",0),t=we(a,"bottom",0),r=we(a,"left",0);s=`padding:${e}px ${we(a,"right",0)}px ${t}px ${r}px;`}let c=we(t,"textColor","#000");c=pl(c,";","");let l=we(t,"backgroundColor","#fff");l=pl(l,";","");let u=we(t,"borderWidth",1),f=we(t,"borderColor","#ebeef5");f=pl(f,";","");let d=we(t,"borderRadius",8),g=we(t,"shadowStyle","0 2px 12px 0 rgba(0,0,0,.1)");g=pl(g,";","");let p=we(t,"closeIconShift",null);null===p&&(p={top:10,right:10});let h="";{let e=we(p,"top",""),t=we(p,"bottom",""),r=we(p,"left",""),n=we(p,"right","");Ia(e)&&(e=`top:${e}px;`),Ia(t)&&(t=`bottom:${t}px;`),Ia(r)&&(r=`left:${r}px;`),Ia(n)&&(n=`right:${n}px;`),h=`position:absolute; ${e} ${n} ${t} ${r}`}let A=`alt-${Hu()}`,m=`alt-${Hu()}`,I=`\n <div \n style="display:inline-block; color:${c}; background:${l}; border:${u}px solid ${f}; border-radius:${d}px; box-shadow:${g};"\n onmouseenter="ttWAlertFadeIn('${m}')"\n onmouseleave="ttWAlertFadeOut('${m}')"\n >\n <div style="position:relative; ${s}">\n\n <div style="display:flex; align-items:center;">\n <div style="margin-right:10px;">\n <div style="display:flex;">${n}</div>\n </div>\n <div>${e}</div>\n </div>\n\n <div style="${h}">\n <div \n id="${m}" \n style="display:flex; cursor:pointer; opacity:0;" \n onclick="ttWAlertCancel('${A}')"\n >\n ${Ru}\n </div>\n </div>\n\n </div>\n </div>\n `,y=document.createElement("div");y.id=A,y.style.position="fixed",y.style.transition="transform 0.3s, top 0.5s, bottom 0.5s",y.style.zIndex=-1,y.style.opacity=.001,i.indexOf("-left")>=0?y.style.transform="translateX(-100%)":y.style.transform="translateX(100%)",y.innerHTML=I,document.querySelector("body").appendChild(y);let v=ns();return function({id:e,position:t,time:r,pm:n}){Tu[e]={id:e,position:t,ele:null,loc:{height:null,top:null,bottom:null,left:null,right:null},timeShow:r,timeStart:Date.now(),pm:n},Gu(),null===Yu&&(Yu=setInterval(()=>{Er(Tu,e=>{Date.now()-e.timeStart>e.timeShow&&(e.pm.resolve(),Ju(e.id))}),Ee(Tu)||(clearInterval(Yu),Yu=null)},50))}({id:A,position:i,time:o,pm:v}),v},e.domAppend=zu,e.domCancelEvent=Pu,e.domCompareText=function(e,t,r,n,i={}){if(!br(e))return Promise.reject("invalid ele");let o=we(i,"format");"side"!==o&&"line"!==o&&(o="side");let a="side"===o?"side-by-side":"line-by-line",s=Jf();De(t)||(t="Text");let c=ea(t,t,r,n),l=s.html(c,{drawFileList:!0,matching:"lines",outputFormat:a,...i});l=l.replace('<span class="d2h-file-list-title">Files changed (1)</span>',"");try{e.innerHTML=l}catch(e){console.log(e)}return{diff:c,html:l}},e.domConvertToPic=Xf,e.domConvertToPicDyn=async function(e,t={},r){return Rr(r)||(r=["https://cdn.jsdelivr.net/npm/@zumer/snapdom@1.9.14/dist/snapdom.min.js"]),await dl(r),Xf(e,t)},e.domDetect=function(e,t={}){let r=we(t,"timeInterval",null);eo(r)||(r=20);let n=we(t,"tolerancePixel",null);eo(n)||(n=1);let i,o=Xi(),a={offsetWidth:0,offsetHeight:0,clientWidth:0,clientHeight:0,windowWidth:0,windowHeight:0},s=zi(a),c={width:"",height:""};if(!va(e))return console.log("invalid f",e),null;i=setInterval(()=>{let t=e();if(t){let e={offsetWidth:t.offsetWidth,offsetHeight:t.offsetHeight,clientWidth:t.clientWidth,clientHeight:t.clientHeight,windowWidth:window.innerWidth,windowHeight:window.innerHeight},r=s.offsetWidth-e.offsetWidth,i=s.offsetHeight-e.offsetHeight,l=Math.abs(r)>n,u=Math.abs(i)>n,f="";r>0?f="smaller":r<0&&(f="larger");let d="";if(i>0?d="smaller":i<0&&(d="larger"),c={width:f,height:d},l||u){let r={...s};setTimeout(()=>{e.offsetWidth>0&&e.offsetHeight>0&&(o.emit("resize",{sold:r,snew:e,smode:c,ele:t}),o.emit("resizeWithWindow",{sold:r,snew:e,smode:c,ele:t,from:"dom"}))},1)}a=s,s=e}},r);let l=e=>{o.emit("resizeWithWindow",{sold:a,snew:s,smode:c,from:"window"})};return window.addEventListener("resize",l),o.clear=()=>{clearInterval(i),window.removeEventListener("resize",l)},o},e.domDrag=function(e,t={}){if(!br(e))return void console.log("ele is not a HTMLElement",e);let r=we(t,"attIdentify",null);De(r)||(r="dragid");let n=we(t,"attIndex",null);De(n)||(n="dragindex");let i=we(t,"attGroup",null);De(i)||(i="draggroup");let o=we(t,"group",null);De(o)||(o="group");let a=we(t,"previewOpacity",null);Ia(a)||(a=.4);let s=we(t,"previewDisabledOpacity",null);Ia(s)||(s=.2);let c=we(t,"previewBackground",null);De(c)||(c="white");let l=we(t,"previewBorderWidth",null);Ia(l)||(l=1);let u=we(t,"previewBorderColor",null);De(u)||(u="#f26");let f=we(t,"timeDragStartDelay",null);Ia(f)||(f=120);let d=`c${Hu(8)}`,g=o;e.setAttribute(i,g),e.setAttribute(r,d);let p=id(g,d,{attIdentify:r,previewOpacity:a,previewBackground:c,previewBorderWidth:l,previewBorderColor:u}),h=function(e,t){let r=[];return{bind:function(){let n;n="mousedown";let i=function(r){t.dragStart({e:r,ele:e,name:"mousedown"})};e.addEventListener(n,i,!1),r.push({ele:e,name:n,f:i}),n="touchstart";let o=function(r){t.dragStart({e:r,ele:e,name:"touchstart"})};e.addEventListener(n,o,!1),r.push({ele:e,name:n,f:o}),n="touchmove";let a=function(e){t.dragMove({e:e,name:"touchmove"}),e.cancelable&&e.preventDefault()};e.addEventListener(n,a,!1),r.push({ele:e,name:n,f:a})},unbind:function(){Er(r,({ele:e,name:t,f:r})=>{e.removeEventListener(t,r)})}}}(e,{dragStart:e=>{p.emit(g+"-dragStart",e)},dragMove:e=>{p.emit(g+"-dragMove",e)}});h.bind(),ad({gid:g,attGroup:i,attIndex:n,attIdentify:r,timeDragStartDelay:f,previewOpacity:a,previewDisabledOpacity:s});let A=Xi();return p.on(o+"-change",e=>{e.tarEid===d&&A.emit("change",e)}),p.on(o+"-start",e=>{e.tarEid===d&&A.emit("start",e)}),p.on(o+"-move",e=>{e.tarEid===d&&A.emit("move",e)}),p.on(o+"-enter",e=>{e.tarEid===d&&A.emit("enter",e)}),p.on(o+"-leave",e=>{e.tarEid===d&&A.emit("leave",e)}),p.on(o+"-drop",e=>{e.tarEid===d&&A.emit("drop",e)}),A.setIsActive=function(e){nd[g].isActive=e},A.unbind=function(){h.unbind(),function(e,t){let r=nd[e],n=zi(r.eleIds);_f(n,t),r.eleIds=n,0===n.length&&(r.oevg.unbind(),r.pv.clear(),delete nd[e])}(g,d)},A},e.domDragBarAndScroll=function(e,t,r={}){let n=null,i=null,o=null,a=null,s=null,c=null,l=null,u=null,f=null,d=null,g=null,p=null,h=null,A=null,m=null,I=!1,y=we(r,"getHeighRatio",null);R(y)||(y=()=>1);let v=we(r,"getWidthRatio",null);R(v)||(v=()=>1);let b=we(r,"stopScrollPropagationForPanel",null);gn(b)||(b=!1);let w=we(r,"stopTouchDragPropagationForPanel",null);gn(w)||(w=!1);let B=we(r,"useTouchDragForPanel",null);gn(B)||(B=!0);let E=e,C=t,x=Xi();return n=e=>{let t=e.deltaY/Math.abs(e.deltaY),r=e.deltaX/Math.abs(e.deltaX);x.emit("scrollPanel",{ratioY:t,ratioX:r}),b&&Pu(e)},E.addEventListener("wheel",n),i=e=>{if(B){let t=we(e,"touches.0.clientY",0),r=we(e,"touches.0.clientX",0),n=-t*y(),i=-r*v();I=!0,x.emit("pressBar",{clientY:n,clientX:i}),w&&Pu(e)}},E.addEventListener("touchstart",i),o=e=>{if(B&&I){let t=we(e,"touches.0.clientY",0),r=we(e,"touches.0.clientX",0),n=-t*y(),i=-r*v();x.emit("dragBar",{clientY:n,clientX:i}),w&&Pu(e)}},E.addEventListener("touchmove",o,{passive:!1}),a=e=>{B&&I&&(I=!1,x.emit("freeBar"),w&&Pu(e))},E.addEventListener("touchend",a),s=e=>{I=!0,x.emit("pressBar",{clientY:e.clientY,clientX:e.clientX})},C.addEventListener("mousedown",s),c=e=>{I&&(I=!1,x.emit("freeBar"))},C.addEventListener("mouseup",c),l=e=>{I=!0,x.emit("pressBar",{clientY:e.touches[0].clientY,clientX:e.touches[0].clientX})},C.addEventListener("touchstart",l),u=e=>{I&&(x.emit("dragBar",{clientY:e.touches[0].clientY,clientX:e.touches[0].clientX}),Pu(e))},C.addEventListener("touchmove",u,{passive:!1}),f=e=>{I&&(I=!1,x.emit("freeBar"))},C.addEventListener("touchend",f),d=e=>{I&&x.emit("dragBar",{clientY:e.clientY,clientX:e.clientX})},window.addEventListener("mousemove",d),g=e=>{I&&(I=!1,x.emit("freeBar"),b&&Pu(e))},window.addEventListener("mouseup",g),p=e=>{},window.addEventListener("scroll",p,{passive:!1}),h=e=>{},window.addEventListener("wheel",h,{passive:!1}),A=e=>{},document.addEventListener("scroll",A,{passive:!1}),m=e=>{},document.addEventListener("wheel",m,{passive:!1}),x.clear=function(){E.removeEventListener("wheel",n),E.removeEventListener("touchstart",i),E.removeEventListener("touchmove",o),E.removeEventListener("touchend",a),C.removeEventListener("mousedown",s),C.removeEventListener("mouseup",c),C.removeEventListener("touchstart",l),C.removeEventListener("touchmove",u),C.removeEventListener("touchend",f),window.removeEventListener("mousemove",d),window.removeEventListener("mouseup",g),window.removeEventListener("scroll",p),window.removeEventListener("wheel",h),document.removeEventListener("scroll",A),document.removeEventListener("wheel",m)},x},e.domDragPreview=rd,e.domDropFiles=function(e){let t=!1,r=!1,n=Xi();function i(e){Pu(e),r=!0,!1===t&&(t=!0,n.emit("dropIn",{ev:e}))}function o(e){Pu(e),r=!1,setTimeout(function(){r||(t=!1,n.emit("dropOut",{ev:e}))},100)}function a(e){i(e)}function s(e){o(e)}function c(e){function t(){o(e)}i(e),ld(e.dataTransfer).then(r=>{let i=pa(r.entries,{type:"file"});n.emit("getFiles",{ev:e,files:r.files,filesTree:i,entries:r.entries,cb:t})}).catch(e=>{n.emit("error",e)})}return e.addEventListener("dragenter",a,!1),e.addEventListener("dragover",a,!1),e.addEventListener("dragleave",s,!1),e.addEventListener("drop",c,!1),n.off=function(){e.removeEventListener("dragenter",a,!1),e.removeEventListener("dragover",a,!1),e.removeEventListener("dragleave",s,!1),e.removeEventListener("drop",c,!1)},n},e.domElementsFromPoint=$f,e.domFadeIn=Lu,e.domFadeOut=Uu,e.domFind=ud,e.domFinds=zf,e.domGetAttr=Zf,e.domGetBoudRect=ed,e.domGetBoudRectRefSelf=td,e.domGetFileAccept=Id,e.domGetFiles=yd,e.domGetParents=Wf,e.domGetPointFromEvent=Kf,e.domGetScrollableParent=function(e){let t=/(auto|scroll)/,r=function(e,t){return getComputedStyle(e,null).getPropertyValue(t)},n=function(e){return t.test(function(e){return r(e,"overflow")+r(e,"overflow-y")+r(e,"overflow-x")}(e))};if(!(e instanceof HTMLElement||e instanceof SVGElement))return;let i=Wf(e);for(let e=0;e<i.length;e+=1)if(n(i[e]))return i[e];return document.scrollingElement||document.documentElement},e.domGetWindowSize=function(){let e=yn();return{width:(()=>{let t=[we(e,"innerWidth"),we(e,"document.documentElement.clientWidth"),we(e,"document.body.clientWidth")];return t=pa(t,Ia),wd(t)})(),height:(()=>{let t=[we(e,"innerHeight"),we(e,"document.documentElement.clientHeight"),we(e,"document.body.clientHeight")];return t=pa(t,Ia),wd(t)})()}},e.domIsClientXYIn=function(e,t,r){if(!Ia(e))return void console.log("clientX is not a number",e);if(!Ia(t))return void console.log("clientY is not a number",t);if(!br(r))return void console.log("ele is not a HTMLElement",r);let n;try{n=r.getBoundingClientRect()}catch(e){return void console.log("invalid ele for getBoundingClientRect",e)}let i=!1;try{i=e>=n.left&&e<=n.right&&t>=n.top&&t<=n.bottom}catch(e){console.log("catch when calculating page information of element",e)}return i},e.domIsFocused=xu,e.domIsStable=function(e,t={}){if(!br(e))return Promise.reject("invalid element");if(!va(e.getBoundingClientRect))return Promise.reject("invalid element.getBoundingClientRect");let r=we(t,"mode","");"promise"!==r&&"event"!==r&&(r="promise");let n=we(t,"tolerance",0),i=we(t,"timeDiff",100),o=we(t,"timeDetect",50),a=()=>{let t=e.getBoundingClientRect();return{x:t.left,y:t.top,w:t.width,h:t.height}},s=()=>{try{return e.getAnimations({subtree:!0})}catch(e){return[]}},c=async()=>{let e=ns();try{let t=a();await bs(i);let r=((e,t)=>!!e&&!!t&&Math.abs(e.x-t.x)<=n&&Math.abs(e.y-t.y)<=n&&Math.abs(e.w-t.w)<=n&&Math.abs(e.h-t.h)<=n)(t,a());await Promise.allSettled(s().map(e=>e.finished));let o=0===s().length,c=r&&o;e.resolve(c)}catch(t){e.reject(t)}return e},l=()=>{let t=Xi(),r=!1,n=null,i=null,a=!1;return t.create=()=>{n=setInterval(()=>{r=(e=>{let r=!1;if(!br(e))return r;try{let e=!1,n=!1;i=setInterval(()=>{a?clearInterval(i):e||(e=!0,c().then(e=>{a||n!==e&&(n=e,t.emit("stable",e))}).catch(()=>{}).finally(()=>{e=!1}))},o),r=!0}catch(e){}return r})(e),r&&clearInterval(n)},50)},t.dispose=()=>{let e=!1;try{clearInterval(n),clearInterval(i),a=!0,e=!0}catch(e){}return e},t},u=null;return"promise"===r?u=c():"event"===r&&(u=l()),u},e.domIsVisible=function(e,t={}){if(!br(e))return Promise.reject("invalid element");if(Bd())return Promise.reject("invalid IntersectionObserver");let r=we(t,"mode","");"promise"!==r&&"event"!==r&&(r="promise");let n=()=>{let t=Xi(),r=!1,n=null,i=!1,o=new IntersectionObserver(e=>{if(i)return;let r=e[0].isIntersecting;t.emit("visible",r)});return t.create=()=>{n=setInterval(()=>{i?clearInterval(n):(r=(e=>{let t=!1;if(!br(e))return t;try{o.observe(e),t=!0}catch(e){}return t})(e),r&&clearInterval(n))},50)},t.dispose=()=>{let e=!1;try{clearInterval(n),o.disconnect(),i=!0,e=!0}catch(e){}return e},t},i=null;return"promise"===r?i=(()=>{let t=ns();try{let r=new IntersectionObserver(e=>{t.resolve(e[0].isIntersecting),r.disconnect()});r.observe(e)}catch(e){t.reject(e)}return t})():"event"===r&&(i=n()),i},e.domPrepend=Pf,e.domRemove=Vf,e.domRenderMarkdownMind=Ed,e.domRenderMarkdownMindDyn=async function(e,t,r={},n){return Rr(n)||(n=["https://cdn.jsdelivr.net/npm/d3@7.8.3/dist/d3.min.js","https://cdn.jsdelivr.net/npm/markmap-view@0.14.4/dist/index.min.js","https://cdn.jsdelivr.net/npm/markmap-lib@0.14.4/dist/browser/index.min.js"]),await dl(n),Ed(e,t,r)},e.domRipple=function(e,t,r={}){let n=we(r,"timeDuration",null);eo(n)||(n=1e3);let i=we(r,"color",null);if(De(i)||(i="rgba(255, 255, 255, 0.5)"),!br(e))return;e.style.position="relative",e.style.overflow="hidden";let o=e.getBoundingClientRect(),a=t.clientX-o.left,s=t.clientY-o.top,c=2*Math.max(e.clientWidth,e.clientHeight),l=document.createElement("div");l.style.width=`${c}px`,l.style.height=`${c}px`,l.style.transition=`all ${n/1e3}s linear`,l.style.position="absolute",l.style.zIndex=1,l.style.left=`${a}px`,l.style.top=`${s}px`,l.style.borderRadius="50%",l.style.transformOrigin="center",l.style.transform="translate(-50%,-50%) scale(0)",l.style.background=i,l.style.userSelect="none",l.style.pointerEvents="none",e.appendChild(l),setTimeout(()=>{l.style.transform="translate(-50%,-50%) scale(2)",l.style.opacity=0},1),setTimeout(()=>{Vf(l)},n)},e.domScrollIntoView=function(e,t={}){if(!br(e))return;Be(t)||(t={});let r={behavior:"smooth"};r={...r,...t},Vu()&&gg(),e.scrollIntoView(r)},e.domScrollTo=function(e,t={}){if(!br(e))return;Be(t)||(t={});let r={behavior:"smooth"};r={...r,...t},Vu()&&gg(),e.scrollTo(r)},e.domSetAttr=function(e,t,r){if(!br(e))return null;if(!De(t))return null;if(!De(r)&&!Se(r))return null;try{return e.setAttribute(t,r),e.getAttribute(t)}catch(e){}return null},e.domShowImages=bg,e.domShowImagesDyn=async function(e,t=null,r={},n){return Rr(n)||(n=["https://cdn.jsdelivr.net/npm/viewerjs@1.11.7/dist/viewer.min.css","https://cdn.jsdelivr.net/npm/viewerjs@1.11.7/dist/viewer.min.js"]),await dl(n),bg(e,t,r)},e.domShowInputAndGetFiles=Bg,e.domShowInputAndGetFilesU8Arrs=function(e={}){let t=we(e,"kind","*"),r=we(e,"multiple");pn(r)||(r=!1);let n=we(e,"entireHierarchy");pn(n)||(n=!1);let i=we(e,"sizeMbLimit");Se(i)||(i=1e3),i=Mn(i);let o=ns(),a=[];return Bg({kind:t,multiple:r,entireHierarchy:n,sizeMbLimit:i}).then(function(e){let t=ns(),r=we(e,"errs",{}),n=we(e,"files",[]);return Ee(r)?t.reject(r):t.resolve(n),t}).then(function(e){return Er(e,function(e){a.push({name:e.name,size:e.size,type:e.type})}),cs(e)}).then(function(e){Er(e,function(e,t){a[t].u8a=e}),o.resolve(a)}).catch(function(e){o.reject(e)}),o},e.domShowInputDatatime=function(e,t={}){let n=we(t,"type","");"date"!==n&&"datetime-local"!==n&&(n="datetime-local");let i=we(t,"eleRef",null);br(i)||(i=document.activeElement);let o=ns(),a="drf"+Hu(),s="GrpDomShowDatatime";Vf(`[name=${s}]`);let c=!1,l="";if("date"===n)ku(e)&&(c=!0,l=e);else if(Eg(e)){c=!0,l=r(e).format("YYYY-MM-DDTHH:mm")}De(l)&&(l=`value="${l}"`);let u=document.createElement("div");u.setAttribute("name",s),u.style.width=0,u.style.height=0,u.style.overflow="hidden",u.innerHTML=`\n <div style="transform:translateY(-100%);">\n <input id="${a}" type="${n}" style="opacity:0;" ${c?l:""} />\n </div>\n `;let f=null;br(i)?i.parentNode.insertBefore(u,i.nextSibling):document.querySelector("body").appendChild(u);let d=!1;function g(){if(!d){d=!0;try{f.removeEventListener("change",h,!0),i.removeEventListener("focusout",A,!0)}catch(e){}if(Vf(`[name=${s}]`),De(p)){let e="";e="date"===n?p:`${p}:00`,o.resolve(e)}}}let p="";function h(e){try{p=e.target.value}catch(e){console.log(e)}g()}function A(e){setTimeout(()=>{g()},50)}return setTimeout(()=>{f=ud("#"+a),f.addEventListener("change",h,!0),f.showPicker()},1),i.addEventListener("focusout",A,!0),o},e.domTooltip=function(e,t,r={}){let n=null,i=null;function o(){null!==n&&n.destroy(!0),e.setAttribute("tippystate",""),clearInterval(i)}let a={arrow:!0,theme:"dark",placement:"bottom",delay:150};r=Ee(r)?vg(a,r):a;let s=t;t||(s=e.innerHTML);let c=Se(e.getAttribute("tippystate"));if(e.setAttribute("tippystate","5"),c)return;s=`<div style="text-align:left;">${s}</div>`;let l=Hh;Hh.default&&(l=Hh.default),n=l(e,{...r,content:s,allowHTML:!0,onHidden(){o()},onDestroy(){n=null,o()}}),n.show(),i=setInterval(()=>{let t=e.getAttribute("tippystate");Se(t)?(t=Zi(t),t-=1,e.setAttribute("tippystate",t),t<=0&&o()):o()},1e3)},e.domTriggerEvent=wg,e.domVirtualCreate=Uh,e.domVirtualCreateQueue=function(){return new function(){let e=jh(1);return async function(t,r={}){return e(Uh,t,r)}}},e.downloadExcelFileFromData=Vh,e.downloadExcelFileFromDataDyn=async function(e,t="data",r,n){Rr(n)||(n=["https://cdn.sheetjs.com/xlsx-0.20.3/package/dist/xlsx.full.min.js"]),await dl(n);let i=Vh(e,t,r);return""!==we(i,"error","")?Promise.reject(i.error):i},e.downloadFileFromB64=function(e,t){if(!In())return void console.log("no window");if(!De(e))return void console.log("no filename");let r=document.createElement("a");r.href=t,r.download=e,document.body.appendChild(r),r.click(),document.body.removeChild(r)},e.downloadFileFromBlob=Gh,e.downloadFileFromText=function(e,t,r=!0){if(!In())return void console.log("no window");if(!De(e))return void console.log("invalid filename");if(!xe(t))return void console.log("invalid content");if(!pn(r))return void console.log("withBOM is not a boolean");let n;n=r?new Blob(["\ufeff",t]):new Blob([t]),Gh(e,n)},e.downloadFileFromU8Arr=function(e,t){if(!In())return void console.log("no window");if(!De(e))return void console.log("no filename");if(!Za(t))return void console.log("no data");Gh(e,Ph(t))},e.dtmapping=Xh,e.dtpick=_h,e.estimateTicks=function(e,t,r={}){if(!Se(e))throw new Error("rmin is not a number");if(e=Mn(e),!Se(t))throw new Error("rmax is not a number");if(e===(t=Mn(t))){let t=null;t=0===e?1:Math.abs(e/10);let r=Kh(t,{returnDigit:!0});return t=Wh(t,r),{tickNum:3,tickInterval:t,tickPositions:[e-t,e,e+t],tickDig:r}}if(e>t)throw new Error(`rmin[${e}] > rmax[${t}]`);let n=we(r,"testTickNums");Rr(n)||(n=[3,4,5]);let i=e,o=t,a=$h(i),s=$h(o),c=Math.max(a.r,s.r),l=Math.log10(c),u=i/c,f=o/c,d=(u+f)/2,g=f-u,p=[];Er(n,e=>{let t=g/(e-1),r=Kh(t,{returnDigit:!0});r=Math.min(r,2),Er(ao(r,-1,-1),r=>{let n=r-l;n=Math.max(n,0);let i=ol(t,r),o=i-1/Math.pow(10,r);o=Wh(o,r);let a=i+1/Math.pow(10,r);a=Wh(a,r);let s=[o,i,a];s=pa(s,e=>e>0);let h=Wh(d,r),A=h-1/Math.pow(10,r);A=Wh(A,r);let m=h+1/Math.pow(10,r);m=Wh(m,r);let I=[A,h,m];Er(s,t=>{let i=c*t;i=Wh(i,n),Er(I,o=>{let a=[],s=[];{let i=o-(e-1)/2*t;for(let o=0;o<e;o++){let e=i+o*t;e=Wh(e,r),a.push(e);let l=c*e;l=Wh(l,n),s.push(l)}}let l=(d=a)&&d.length?d[0]:void 0;var d;let h=Qa(a);if(l>u||h<f)return!0;let A=(u-l)/g,m=(h-f)/g,I=(A+m)/2,y=0;Er(s,e=>{Hn(e)&&y++});let v=y/e,b=0;Er(a,e=>{0===e&&b++});let w=b/e,B=0;Er(a,e=>{.5===e&&B++});let E=B/e,C=0;Er(a,e=>{1===e&&C++});let x=C/e,D={diff:I,rngCenter:o,numInt:y,ratInt:v,num0:b,rat0:w,num5:B,rat5:E,num10:C,rat10:x,overMin:A,overMax:m,fitness:I+.2*r+.1*e+1.5*A+1.5*m+(1-.25*v)+(1-.4*w)+(1-.3*E)+(1-.3*x),idg:r,tickNum:e,_tickDig:r,_tickInterval:t,_tickPositions:a,tickDig:n,tickInterval:i,tickPositions:s};p.push(D)})})})}),p=Oa(p,"fitness");let h=we(p,0);return{tickNum:h.tickNum,tickInterval:h.tickInterval,tickPositions:h.tickPositions,tickDig:h.tickDig}},e.evem=Xi,e.execJsCode=async function(e,t={}){e=i.resolve(e);let r=(await import(o.pathToFileURL(e).href)).default;if(!va(r))throw new Error(`the default export of [${e}] is not a function`);return await r(t)},e.execProcess=function(e,t,r={}){if(!Rr(t)&&!De(t))throw new Error("args is not an effective array or string");De(t)&&(t=[t]);let n=we(r,"mode");"spawn"!==n&&"exec"!==n&&"execFile"!==n&&(n="spawn");let i=we(r,"cbStdout"),o=we(r,"cbStderr"),s=we(r,"codeCmd");De(s)||(s="utf8");let c=we(r,"useChcp");pn(c)||(c=!1);let l=we(r,"timeout");(!Se(l)||l<=0)&&(l=null);let u=ns();if(!ya(n,["spawn","exec","execFile"]))return u.reject(`invalid mode[${n}]`),u;let f=null,d="";try{if("spawn"===n){let r=ua(e,1),n=fa(e,1);if('"'===r||'"'===n||"'"===r||"'"===n)throw new Error("prog of spawn doens not need to add quotes");f=a.spawn(e,t,{windowsHide:!0,shell:!1})}else if("exec"===n){let r="";c&&(r="cmd /c chcp 65001>nul &&"),f=a.exec(`${r} ${e} ${t.join(" ")} & exit`,{windowsHide:!0,encoding:s})}else"execFile"===n&&(f=a.execFile(e,t,{windowsHide:!0,encoding:s}))}catch(e){return u.reject(e),u}f.stdout.on("data",e=>{let t="";t="spawn"===n?e.toString(s):e.toString(),d+=t+"\n",va(i)&&i(t)}),f.stderr.on("data",e=>{let t="";t="spawn"===n?e.toString(s):e.toString(),d+=t+"\n",va(o)&&o(t)});let g=null,p=!1;return null!==l&&(g=setTimeout(()=>{p=!0,f&&f.pid&&aA(f.pid).catch(()=>{})},l)),f.on("close",e=>{null!==g&&clearTimeout(g),p?u.reject(`timeout[${l}ms]:\n${d}`):0!==e?u.reject(`code[${e}]:\n${d}`):u.resolve(d)}),f.on("error",e=>{null!==g&&clearTimeout(g),u.reject(e)}),u},e.execProcessKillPid=aA,e.filepathToTree=function(e,t={}){if(!Rr(e))return{};let r=we(t,"delimiter");De(r)||(r="❯");let n=we(t,"bindRoot");De(n)||(n="");let i=De(n),o="";o=i?n:"root";let a=we(t,"soryItems"),s=xr(e,(e,t)=>{"folder"!==e.type&&"file"!==e.type&&(e.type="file");let n=(e=>{let t=la(e=(e=e.replace(/\\\\/g,"\\")).replace(/\\/g,"/"),"/");return{ss:t,cfp:xo(t,r)}})(e.path);return{ind:t,type:e.type,ss:n.ss,data:zi(e)}}),c=e=>{let t=dn(e),n=[];for(let i=0;i<t;i++){let t=[];for(let r=0;r<=i;r++)t.push(e[r]);let o=xo(t,r);n.push({id:o,name:e[i]})}return n},l=-1,u=[],f={};Er(s,e=>{let t=null;t=[o];let n=null;n=o;let i=dn(e.ss)-1;Er(e.ss,(o,a)=>{let s=a<i||"folder"===e.type;t.push(o);let d=null,g=null;a===i&&(d=e.ind,g=e.data);let p=xo(t,r),h=c(t);if(ke(f,p)){let t=f[p],r="folder"===we(t,"_type","");if(!r&&s)throw console.log("kpLv[id]",t),console.log("v",e),new Error(`id[${p}] is unrecognized from a file to folder`);if(!r&&!s)throw console.log("kpLv[id]",t),console.log("v",e),new Error(`id[${p}] get repeat data from two files`);if(r&&!s)throw console.log("kpLv[id]",t),console.log("v",e),new Error(`id[${p}] is unrecognized from a folder to file`);if(Ee(f[p].data)&&Ee(g))throw console.log("kpLv[id]",t),console.log("v",e),new Error(`id[${p}] get repeat data from two folders`);if(null===f[p].data&&Ee(g)){f[p]._indOri=d,f[p].data=g;let e=f[p]._indNormalize,t=u[e];u[e]={...g,type:t.type,path:t.path}}}else{l++;let e=l,r=null;r=s?{_indOri:d,_indNormalize:e,ns:dn(t),ts:zi(t),pathInfors:h,_type:"folder",type:"array",numOfChilren:-1,id:p,parentId:n,text:o,children:[],data:g}:{_indOri:d,_indNormalize:e,ns:dn(t),ts:zi(t),pathInfors:h,_type:"file",type:"node",numOfChilren:-1,id:p,parentId:n,text:o,data:g},f[p]=r,u.push({...we(f[p],"data",{}),type:f[p]._type,path:"/"+xo(t,"/")})}n=p})});let d=lA(f);if(d=Oa(d,"id"),d=Oa(d,"ns"),va(a)){let e=[];Er(AA(d,"ns"),(t,r)=>{Er(AA(t,"parentId"),(t,n)=>{let i=a(t,n,r);e=[...e,...i]})}),d=e}let g=[],p=[];Er(d,e=>{"folder"===e._type?g.push(e):p.push(e)});let h=AA(g,"ns"),A=AA(p,"ns"),m=cA(xr(g,"ns")),I=cA(xr(p,"ns")),y=null;{let e=[o];y=[{_indOri:null,_indNormalize:null,ns:dn(e),ts:zi(e),pathInfors:c(e),_type:"folder",type:"array",numOfChilren:-1,id:o,parentId:"",text:o,children:[],data:null}]}let v={};v[o]="0.children";let b={};b[o]="0";for(let e=2;e<=m;e++){Er(h[e],e=>{let t=we(v,e.parentId,"");if(!De(t))throw console.log("kpPathFd",v),console.log("v",e,e.parentId),new Error(`invalid parentId[${e.parentId}] in folder`);let r=we(y,t);if(Ce(r)||yu(y,t,[]),r=we(y,t),!Ee(pd(r,{id:e.id}))){r.push({...e,children:[]});let n=`${t}.${dn(r)-1}`;v[e.id]=`${n}.children`,b[e.id]=n}})}let w=zi(y),B={};for(let e=2;e<=I;e++){Er(A[e],e=>{let t=we(v,e.parentId,"");if(!De(t))throw console.log("kpPathFd",v),console.log("v",e,e.parentId),new Error(`invalid parentId[${e.parentId}] in file`);let r=we(y,t);if(!Ce(r))throw console.log("treeItems",y),console.log("k",t),console.log("v",e),new Error("無預先建置資料夾");if(!Ee(pd(r,{id:e.id}))){r.push(e);let n=`${t}.${dn(r)-1}`;B[e.id]=n,b[e.id]=n}})}return{treeItems:y,treeItemsFolder:w,kpPath:b,fpsNormalize:u}},e.files2data=function(e){let t=ns(),r=xr(e,function(e){return{name:e.name,size:e.size,type:e.type}});return ss(e).then(function(e){let n=xr(e,function(e){return{b64:e}}),i=mA(r,n);t.resolve(i)}),t},e.flattenToConn=Cu,e.flattenTree=function(e,t={}){if(Ce(e)){if(0===e.length)return[]}else{if(!Be(e))return[];if(Mr(e))return[]}let r=we(t,"bindKey",null);De(r)||(r="id");let n=we(t,"bindChildren",null);De(n)||(n="children");let i=!1;Be(e)&&(i=!0,e=[e]);let o=[];return Eu(e,(e,t,i)=>{let a=we(e,r,null),s=we(e,n,null);if(a){let r=function(e){let t=[e[0]];for(let r=1;r<e.length;r++){let i=e[r];t.push(n),t.push(i)}return t}([...i,t]);if(o.push({...e,level:(dn(r)-1)/2,nk:r}),s)return s}}),i&&(o=o[0]),o},e.floor=function(e,t=0){return Bo(t)||(t=0),t=Zi(t),Se(e)?new il(e).toDecimalPlaces(t,il.ROUND_FLOOR).toNumber():""},e.fsBuildReadStreamText=function(e){if(!vA(e))throw new Error("fp is not a file");let t=Xi(),r=s.createReadStream(e,{encoding:"utf8"});return t.emit("create"),c.createInterface({input:r,crlfDelay:1/0}).on("line",e=>{t.emit("line",e)}),r.on("close",()=>{t.emit("close")}),t},e.fsBuildWriteStreamText=function(){let e=null;return{create:t=>{let r=ns();return e=s.createWriteStream(t,{flags:"w",encoding:"utf8"}),e.on("finish",()=>{r.resolve()}),e.on("error",e=>{r.reject(e)}),r},write:t=>{e.write(t+"\n")},end:()=>{let t=ns();return e.on("close",()=>{t.resolve()}),e.end(),t}}},e.fsCleanFolder=function(e){return BA(e,{path:i,fs:s})},e.fsCleanFolderCore=BA,e.fsCopyFile=function(e,t,r={}){return EA(e,t,{path:i,fs:s,...r})},e.fsCopyFileCore=EA,e.fsCopyFolder=function(e,t,r={}){return xA(e,t,{path:i,fs:s,...r})},e.fsCopyFolderCore=xA,e.fsCreateFile=function(e,t,r={}){return SA(e,t,{fs:s,...r})},e.fsCreateFileCore=SA,e.fsCreateFolder=kA,e.fsCreateFolderCore=wA,e.fsDeleteFile=function(e){return NA(e,{fs:s})},e.fsDeleteFileCore=NA,e.fsDeleteFileSafe=async function(e,t={}){return await qA(e,{fs:s,...t})},e.fsDeleteFileSafeCore=qA,e.fsDeleteFolder=HA,e.fsDeleteFolderCore=MA,e.fsDeleteFolderSafe=async function(e,t={}){return await LA(e,{fs:s,...t})},e.fsDeleteFolderSafeCore=LA,e.fsDownloadFile=async function(e,t){return UA(e,t,{fs:s,Readable:l.Readable})},e.fsDownloadFileCore=UA,e.fsEvem=function(e={}){let t=we(e,"fd");De(t)||(t="./_evps");let r=we(e,"polling");pn(r)||(r=!1);let n=we(e,"timeInterval");eo(n)||(n=100),n=Zi(n);let o=we(e,"timeBinaryInterval");eo(o)||(o=300),o=Zi(o);let a=we(e,"keySys");De(a)||(a="[::pkg_content::]"),TA(t)||kA(t);let c=YA(t,{polling:r,timeInterval:n,timeBinaryInterval:o});c.on("change",e=>{if("add"!==e.type&&"change"!==e.type)return;let t=OA(e.fp),r="";try{r=s.readFileSync(e.fp,"utf8"),r=Ka(r)}catch(e){}Ee(r)&&l.emit(t,{[a]:r})});let l=new u.EventEmitter,f=l.emit;return l.emit=function(e,r){let n=!1;if(Ee(r)&&(n=ke(r,a)),n){let t=we(r,a,null),n=we(t,"pkg",""),i=we(t,"time","");return f.call(this,e,n,i)}((e,r)=>{let n=i.resolve(t,e);xe(r)||(r=hn(r)),s.writeFileSync(n,r,"utf8")})(e,{pkg:r,time:RA()})},l.clear=()=>{c.clear(),HA(t)},l},e.fsExists=function(e){return IA(e,{fs:s})},e.fsExistsCore=IA,e.fsGetFileBasicHash=function(e,t={}){return jA(e,{fs:s,crypto:d,...t})},e.fsGetFileBasicHashCore=jA,e.fsGetFileHash=function(e,t={}){return VA(e,{fs:s,crypto:d,...t})},e.fsGetFileHashCore=VA,e.fsGetFileXxHash=function(e,t={}){return zA(e,{fs:s,...t})},e.fsGetFileXxHashCore=zA,e.fsGetFilesInFolder=function(e,t=1){return XA(e,t,{path:i,fs:s})},e.fsGetFilesInFolderCore=XA,e.fsGetFilesWithHashInFolder=WA,e.fsGetFilesWithHashInFolderCore=_A,e.fsGetFolderBasicHash=function(e,t={}){return KA(e,{path:i,fs:s,crypto:d,...t})},e.fsGetFolderBasicHashCore=KA,e.fsGetFoldersInFolder=function(e,t=1){return $A(e,t,{path:i,fs:s})},e.fsGetFoldersInFolderCore=$A,e.fsIsFile=vA,e.fsIsFileCore=yA,e.fsIsFolder=TA,e.fsIsFolderCore=bA,e.fsMergeFiles=async function(e,t,r={}){return ZA(e,t,{fs:s,...r})},e.fsMergeFilesCore=ZA,e.fsReadJson=function(e){let t=null,r=em(e,{fs:s});if(r.error)return r;let n=r.success,i=null;try{i=JSON.parse(n)}catch(e){t=e}return null!==t?{error:t}:{success:i}},e.fsReadText=function(e){return em(e,{fs:s})},e.fsReadTextCore=em,e.fsRenameFile=function(e,t){return tm(e,t,{fs:s})},e.fsRenameFileCore=tm,e.fsRenameFolder=function(e,t){return rm(e,t,{fs:s})},e.fsRenameFolderCore=rm,e.fsSrlog=function(e={}){let t=we(e,"fdSys","");De(t)||(t=i.resolve(),t=t.replaceAll("\\","/"));let n=we(e,"fdLog","");De(n)||(n="./syslog"),TA(n)||kA(n);let o=we(e,"dlm","");De(o)||(o="ꓹ");let a=we(e,"useTime",null);pn(a)||(a=!0);let c=we(e,"useLoc",null);pn(c)||(c=!0);let l=we(e,"useLocRela",null);async function u(e,t,...i){let l=(()=>{let e=r().format("YYYY-MM-DD");return`${n}/${e}.log`})(),u=xr(i,e=>{let t="";return t=Be(e)||Ce(e)?JSON.stringify(e):pn(e)?e?"true":"false":Ya(e),t}),f="";a&&(f=`[${e}]\n`,s.appendFileSync(l,f,"utf8")),c&&(f=`[${t}]\n`,s.appendFileSync(l,f,"utf8")),f=`${xo(u,`${o} `)}\n\n`,s.appendFileSync(l,f,"utf8")}return pn(l)||(l=!0),function(...e){let r="";a&&(r=RA());let n="",i="",o=[];if(c){if(o=la((new Error).stack,"\n"),Er(o,e=>{if((e=sa(e)).indexOf("file:")<0)return!0;if(e.indexOf("fsSrlog.mjs")>=0)return!0;return Er(la(e," "),e=>{if(e.indexOf("file:")>=0)return n=e,!1}),!De(n)&&void 0}),!De(n))throw console.log("stackLines",o),new Error("can not parse stackLines");"("===ua(n,1)&&(n=da(n,1)),")"===fa(n,1)&&(n=Ga(n,1));try{n=decodeURIComponent(n)}catch(e){console.log(e)}i=n,i=da(i,8),i=i.replace(t,"")}let s=[];a&&(s=[...s,`[${r}]`]);let f="";c&&(f=n,l&&(f=i),s=[...s,`[${f}]`]),s=[...s,...e],console.log(...s),u(r,f,...e)}},e.fsSyncFolder=function(e,t,r={}){return om(e,t,{path:i,fs:s,crypto:d,...r})},e.fsSyncFolderCore=om,e.fsTask=function(e,t={}){let r=we(t,"fdStorage","");De(r)||(r="./_tkfs");let n=we(t,"levelLimit","");eo(n)||(n=1),n=Zi(n);let i=we(t,"typeHash","");De(i)||(i="md5");let o=we(t,"timeInterval");ha(o)||(o=6e4),o=Zi(o),kA(r);let a=Xi(),c=!1,l=`${r}/fpHash.json`,u=`${r}/fpResult.json`,f=async()=>{if(!0===c)return;let t=(()=>{let e={};try{e=Ka(s.readFileSync(l,"utf8"))}catch(e){}return e})(),r=await(async()=>{let t={};return TA(e)?(Er(await WA(e,n,{type:i}),e=>{t[e.path]=e.hash}),t):t})(),o=xr(t,(e,t)=>({path:t,hash:e})),u=xr(r,(e,t)=>({path:t,hash:e}));Er(nm(o,u,"path").infor,(e,n)=>{if("same"===e)return!0;let i=we(t,n,""),o=we(r,n,""),u="";u="del"===e?i:o;let f=e,d=n,g=FA(n);c=!0;let p=ns();return a.emit("change",{type:f,fp:d,fn:g,hash:u,pm:p}),p.then(()=>{let e=zi(t);e[d]=r[d],(e=>{try{let t=hn(e);s.writeFileSync(l,t,"utf8")}catch(e){}})(e)}).finally(()=>{c=!1}),!1})},d=()=>{let e={};try{e=Ka(s.readFileSync(u,"utf8"))}catch(e){}return e},g=(e={})=>{try{let t=hn(e);s.writeFileSync(u,t,"utf8")}catch(e){}},p=setInterval(()=>{f().catch(()=>{})},o);return a.getResult=(e,t)=>{let r=`${e}|${t}`,n=we(d(),r,[]);return Ce(n)||console.log(`result for key[${r}] is not an array`),n},a.getAndEliminateResult=(e,t)=>{let r=`${e}|${t}`,n=d(),i=we(n,r,[]);return Ce(i)||console.log(`result for key[${r}] is not an array`),n=((e,t)=>{let r={};return Er(e,(e,n)=>{we(la(n,"|"),0,"")!==t&&(r[n]=e)}),r})(n,e),g(n),i},a.setResult=(e,t,r)=>{Ce(r)||(console.log("result is not an array, default to []"),r=[]);let n=`${e}|${t}`,i=d();i[n]=r,g(i)},a.clear=()=>{clearInterval(p)},a},e.fsTaskCp=function(e,t,r={}){TA(e)||kA(e),TA(t)||kA(t);let n=`${e}/fpHash.json`,i=`${t}/fpHash.json`,o=e=>{let t={};try{t=Ka(s.readFileSync(e,"utf8"))}catch(e){}return t},a=(e,t)=>{try{let r=hn(t);s.writeFileSync(e,r,"utf8")}catch(e){}},c=(e,t)=>we(o(e),t,""),l=(e,t,r)=>{let n=o(e);n[t]=r,a(e,n)},u=(e,t)=>{let r=o(e);ke(r,t)&&delete r[t],a(e,r)},f=()=>o(n),d=e=>a(n,e),g=e=>c(n,e),p=()=>o(i),h=e=>a(i,e),A=e=>c(i,e),m=(e,t)=>l(i,e,t),I=e=>u(i,e),y=e=>{let t=[];return Er(e,(e,r)=>{t.push({fp:r,hash:e})}),t},v={buildSrc:()=>{let e=Xi();return e.set=(t,r)=>{((e,t)=>{l(n,e,t)})(t,r),e.emit("set",{type:"set",fp:t,hash:r})},e.get=g,e.remove=t=>{(e=>{u(n,e)})(t),e.emit("remove",{type:"remove",fp:t})},e.readKp=f,e.writeKp=d,e},buildTar:()=>{let e=Xi(),t=Nu(300),r=am(n);return r.on("change",r=>{t(()=>{(async()=>{let t=ns(),r=f();if(!Ee(r))return t.resolve("no src"),t;let n=p(),i=y(r),o=nm(y(n),i,"fp",{withInfor:!1}),a=ns();return a.then(e=>{h(r)}).catch(()=>{}),e.emit("change",{kpSrc:r,kpTar:n,kpCmp:o,pm:a}),t})().catch(()=>{})})}),e.set=m,e.get=A,e.remove=I,e.readKp=p,e.writeKp=h,e.clear=r.clear,e}};return v},e.fsTreeFolder=function(e,t=1){return PA(e,t,{path:i,fs:s})},e.fsTreeFolderCore=PA,e.fsTreeFolderWithHash=function(e,t=1,r={}){return im(e,t,{path:i,fs:s,crypto:d,...r})},e.fsTreeFolderWithHashCore=im,e.fsWatchFile=am,e.fsWatchFolder=YA,e.fsWriteJson=function(e,t,r={}){let n=null;if(!Be(t)&&!Ce(t))return{error:"inp is not an object or array"};let i=we(r,"useFormat",null);pn(i)||(i=!1);let o="";try{o=i?JSON.stringify(t,null,2):JSON.stringify(t)}catch(e){n=e}return null!==n?{error:n}:sm(e,o,{fs:s})},e.fsWriteText=function(e,t){return sm(e,t,{fs:s})},e.fsWriteTextCore=sm,e.genGradientColor=function(e){if(Ur(e))return{};let t;try{t=Iu.toRgba(e)}catch(e){return{}}function r(e,t){return e.a=t,Iu.toRgbaString(e)}return{linearGradient:{x1:0,x2:0,y1:0,y2:1},stops:[[0,r(t,.4)],[1,r(t,.9)]]}},e.genID=Hu,e.genIDSeq=function(){return dm()},e.genPm=ns,e.getBufferSize=hm,e.getClearPathName=DA,e.getCsvStrFromData=Am,e.getDataFromExcelFileU8Arr=ym,e.getDataFromExcelFileU8ArrDyn=async function(e,t,r){Rr(r)||(r=["https://cdn.sheetjs.com/xlsx-0.20.3/package/dist/xlsx.full.min.js"]),await dl(r);let n=ym(e,t);return""!==we(n,"error","")?Promise.reject(n.error):n},e.getEnv=function(){let e=In(),t="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope;return e=e||t,{isBrowser:e,isWebWorker:t,isNode:"undefined"!=typeof process&&null!=process.versions&&null!=process.versions.node}},e.getErrorMessage=function(e){let t="";if(wm(e))t=e.message;else{if(xe(e))return e;if(Be(e))return ke(e,"message")?e.message:JSON.stringify(e);if(Ce(e))return JSON.stringify(e);t=Ya(e)}return t},e.getExcelU8ArrFromData=function(e,t="data"){if(!Rr(e)){return{error:"no data"}}De(t)||(t="data");let r=null,n=zh(e,t);return ke(n,"error")?n:(r=Bm(n),ke(r,"error"),r)},e.getExcelU8ArrFromWorkbook=Bm,e.getExcelWorkbookFromData=zh,e.getExcelWorkbookFromWorksheet=Jh,e.getExcelWorksheetFromData=bn,e.getFileAccept=md,e.getFileBasicHash=Km,e.getFileHash=async function(e,t={}){if(!gs(e)&&!Wm(e))return console.log("inp",e),Promise.reject("inp is not a Blob or File");let r=we(t,"type","");De(r)||(r="sha512");let n=we(t,"chunkSize");return Se(n)||(n=67108864),n=Mn(n),ke({MD5:"md5","SHA-1":"sha1","SHA-256":"sha256","SHA-384":"sha384","SHA-512":"sha512",md5:"md5",sha1:"sha1",sha256:"sha256",sha384:"sha384",sha512:"sha512",xxhash64:"xxhash64"},r)?"xxhash64"===r?$m(e,t):Km(e,t):Promise.reject(`type[${r}] must be one of [ 'md5', 'sha1', 'sha256', 'sha384', 'sha512', 'xxhash64' ]`)},e.getFileName=FA,e.getFileNameExt=function(e){if(!De(e))return"";let t=Jo(FA(e),".");if(dn(t)<=1)return"";let r="";try{r=Qa(t)}catch(e){}return r},e.getFileTrueName=OA,e.getFileType=Ad,e.getFileXxHash=$m,e.getGlobal=yn,e.getObjSize=function(e){let t=0,r=function e(r){if(null!=r)switch(typeof r){case"number":t+=8;break;case"string":t+=2*r.length;break;case"boolean":t+=4;break;case"object":let n=Object.prototype.toString.call(r).slice(8,-1);if("Object"===n||"Array"===n)for(let t in r)r.hasOwnProperty(t)&&e(r[t]);else t+=2*r.toString().length}return t}(e),n=function(e){return e<1024?e+" bytes":e<1048576?(e/1024).toFixed(3)+" KiB":e<1073741824?(e/1048576).toFixed(3)+" MiB":(e/1073741824).toFixed(3)+" GiB"}(r);return{int:r,str:n}},e.getPathParent=QA,e.getTimeBetween=function(e,t,r="days"){let n=rI(r);if(""===n)return[];let i=nI(e,r),o=nI(t,r);return null===i||null===o||e>=t?[]:xr(tI(o.diff(i,r)+1),function(e){return i.clone().add(e,r).format(n)})},e.getTimeFromUnit=rI,e.getTimeHp=iI,e.getTimeObject=nI,e.getTimeRange=function(e,t){if(!Eg(e))return"無起始時間";if(void 0===t&&(t=e),!Eg(t))return"結束時間格式錯誤";let n=r(e,"YYYY-MM-DDTHH:mm:ss"),i=r(t,"YYYY-MM-DDTHH:mm:ss"),o=n.format("YYYY-MM-DD"),a=i.format("YYYY-MM-DD");if(o===a){let r=i.format("HH:mm");if(e===t)return oI(e)+" 至 無";if(e<t)return oI(e)+" 至 "+r;if(e>t)return oI(e)+" 至 "+r+" (起始時間大於結束時間)"}else{if(o<a)return oI(e)+" 至 "+oI(t);if(o>a)return oI(e)+" 至 "+oI(t)+" (起始時間大於結束時間)"}return""},e.getUserAgent=aI,e.getUserAgentDyn=async function(e=null,t){return Rr(t)||(t=["https://cdn.jsdelivr.net/npm/ua-parser-js@2.0.3/dist/ua-parser.min.js"]),await dl(t),aI(e)},e.getltdtkeys=Xr,e.haskey=ke,e.html2str=async function(e){if(!De(e))return"";let t=await async function(){let e="htmlToText";if(va(we(m,e)))return m;if(va(we(m,["default",e])))return m.default;let t=globalThis,r=null;if(await vs(()=>(r=we(t,"ht",null),Ee(r)),{attemptNum:4e3,timeInterval:50}),va(we(r,e)))return r;if(va(we(r,["default",e])))return r.default;throw console.log("ht",m,"g.ht",t.ht),new Error("invalid ht, g.ht, g.ht.default, use script for import")}();return t.htmlToText(e,{wordwrap:!1,selectors:[{selector:"script",format:"skip"},{selector:"style",format:"skip"}]})},e.htmlDecode=function(e,t={}){return De(e)?us.decode(e,t):""},e.htmlEncode=fs,e.importResources=dl,e.interp1=function(e,t,r={}){if(!Ce(e))return{err:"ps is not an array"};{let e=!Se(t),r=!Ce(t);if(e&&r)return{err:"px is not a number or an array"}}let n=function(e,t={}){if(dn(e)<=0)return[];let r=we(t,"keyX");De(r)||(r="x");let n=we(t,"keyY");De(n)||(n="y");let i=[];return Er(e,e=>{let t=null,o=null;Ce(e)&&dn(e)>=2?(t=we(e,0),o=we(e,1)):(t=we(e,r,null),o=we(e,n,null)),Se(t)&&Se(o)&&(t=Sn(t),o=Sn(o),i.push({x:t,y:o}))}),i}(e,r);if(we(n,"err"))return we(n,"err");if(0===dn(n))return{err:"ps(length=0) is not an effective array",ps:e,psEff:n};if(1===dn(n))return{err:"ps(length=1) is one point only",ps:e,psEff:n};let i=function(e){let t=!0,r=!0;for(let n=1;n<dn(e);n++){let i=e[n-1],o=e[n];if(t&&i.x>o.x&&(t=!1),r&&i.x<o.x&&(r=!1),i.x===o.x)return{err:`x can not be equal: i=${n}, x=${i.x}`}}return t?lI:r?uI:"no"}(n);if("no"===i)return{err:"psEff is not increasing or decreasing"};i===uI&&(i=lI,n=La(n));let o=!Ce(t);o&&(t=[t]);let a=function(e,t={}){if(dn(e)<=0)return[];let r=we(t,"keyX");De(r)||(r="x");let n=[];return Er(e,e=>{let t=null;t=Se(e)?Sn(e):Ce(e)&&dn(e)>=1?we(e,0):we(e,r,null),Se(t)&&(t=Sn(t),n.push({x:t}))}),n}(t,r),s=we(r,"mode");"linear"!==s&&"stairs"!==s&&"blocks"!==s&&(s="linear");let c,l=xr(a,(e,t)=>{let i=we(e,"x"),o=null;try{"linear"===s?o=function(e,t){let r=fI(e,t);if(r!==sI)return r;let n=null;for(let r=1;r<dn(e);r++){let i=e[r-1],o=e[r];if(i.x<=t&&t<=o.x){n=((t-i.x)*o.y+(o.x-t)*i.y)/(o.x-i.x);break}}return null===n?{err:cI}:n}(n,i):"blocks"===s?o=function(e,t){let r=fI(e,t);if(r!==sI)return r;let n=null;for(let r=1;r<dn(e);r++){let i=e[r-1],o=e[r],a=i.x,s=o.x;if(a<=t&&t<=s){n=o.y;break}}return null===n?{err:cI}:n}(n,i):"stairs"===s&&(o=function(e,t,r={}){let n=we(r,"xMin");if(Ia(n)){if(n>e[0].x)return{err:`xMin=${n} > ps[0].x=${e[0].x}`};n===e[0].x||(e=[{x:n,y:e[0].y},...e])}let i=we(r,"xMax");if(Ia(i)){if(i<e[dn(e)-1].x)return{err:`xMax=${i} < ps[size(ps)-1].x=${e[dn(e)-1].x}`};if(i===e[dn(e)-1].x);else{let t={x:i,y:e[dn(e)-1].y};e=[...e,t]}}let o=fI(e,t);if(o!==sI)return o;let a=null;for(let r=0;r<dn(e);r++){let n=we(e,r-1,null),i=we(e,r,null),o=we(e,r+1,null),s=i.x;n&&(s=(n.x+i.x)/2);let c=i.x;if(o&&(c=(o.x+i.x)/2),s<=t&&t<=c){a=i.y;break}}return null===a?{err:cI}:a}(n,i,r))}catch(e){o={err:e.toString()}}return o});return c=o?l[0]:l,c},e.isDate=function(e){let t=e;return De(e)&&(t=new Date(e)),Se(e)&&(t=Mn(e),t=new Date(e)),t instanceof Date&&!isNaN(t)},e.isDev=function(){return!!location&&rs(location.href,"localhost")},e.isEle=br,e.isEleExistByID=function(e){return!!De(e)&&!(null===document.getElementById(e))},e.isEmail=function(e){return!!De(e)&&/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(e)},e.isErr=wm,e.isIE=Vu,e.isNarrow=function(e){if(!In())return!1;let t=window.innerWidth>0&&window.innerWidth<=1024,r=!1;if(e){let t=we(e,"clientWidth",0);r=t>0&&t<=700}return t||r},e.isStrHasCapital=hI,e.isStrHasLetter=AI,e.isStrHasLowerCase=mI,e.isStrHasNumber=II,e.isStrHasSpace=yI,e.isStrHasSymbol=vI,e.isUserIdentify=function(e){let t=ns();if(!De(e))return t.reject("身份證字號非有效字串"),t;if(10!==e.length)return t.reject("身份證字號長度非10位"),t;if(isNaN(e.substring(1,10))||!/^[A-Z]$/.test(e.substring(0,1)))return t.reject("身份證格式錯誤,字首需大寫英文"),t;e="ABCDEFGHJKLMNPQRSTUVXYWZIO".indexOf(e.substring(0,1))+10+""+e.substring(1,10);let r=parseInt(e.substring(0,1))+9*parseInt(e.substring(1,2))+8*parseInt(e.substring(2,3))+7*parseInt(e.substring(3,4))+6*parseInt(e.substring(4,5))+5*parseInt(e.substring(5,6))+4*parseInt(e.substring(6,7))+3*parseInt(e.substring(7,8))+2*parseInt(e.substring(8,9))+parseInt(e.substring(9,10)),n=parseInt(e.substring(10,11));return r%10!=0&&10-r%10!==n?(t.reject("非有效身份證"),t):(t.resolve(),t)},e.isUserName=function(e){let t=ns();return De(e)?(t.resolve(),t):(t.reject("請填入姓名"),t)},e.isUserPw=function(e,t={}){let r=[],n=we(t,"useKeyForError",null);pn(n)||(n=!1);let i=we(t,"useOnlyOneError",null);if(pn(i)||(i=!1),xe(e)||(n?r.push("keyInvalidPassword"):r.push("密碼非有效字串")),dn(r)>0)throw new Error(r[0]);let o=we(t,"numLenMin","");(!Hn(o)||Zi(o)<0)&&(o=8),o=Zi(o);let a=we(t,"numLenMax","");if((!Hn(a)||Zi(a)<0)&&(a=30),a=Zi(a),o>a&&(n?r.push("keyLimNumLenMinOrMax"):r.push("設定密碼最小長度大於最大長度")),dn(r)>0)throw new Error(r[0]);let s=we(t,"noSpace",null);if(pn(s)||(s=!0),s&&(yI(e)&&(n?r.push("keyLimHasSpace"):r.push("密碼不可包含空白字元")),i&&dn(r)>0))throw new Error(r[0]);let c=we(t,"onlyAscii",null);if(pn(c)||(c=!0),c&&(/[^\x20-\x7e]/.test(e)&&(n?r.push("keyLimNonAsciiChar"):r.push("密碼僅允許使用英文大小寫、數字及特殊符號")),i&&dn(r)>0))throw new Error(r[0]);if(dn(e)<o&&(n?r.push("keyLimNumLenMin"):r.push(`密碼長度須大於等於${o}個字元`)),i&&dn(r)>0)throw new Error(r[0]);if(dn(e)>a&&(n?r.push("keyLimNumLenMax"):r.push(`密碼長度須小於等於${a}個字元`)),i&&dn(r)>0)throw new Error(r[0]);let l=we(t,"requireLetter",null);pn(l)||(l=!1);let u=we(t,"requireUppercase",null);pn(u)||(u=!0);let f=we(t,"requireLowercase",null);pn(f)||(f=!0);let d=we(t,"requireDigit",null);pn(d)||(d=!0);let g=we(t,"requireSpecial",null);if(pn(g)||(g=!0),l&&!AI(e)&&(n?r.push("keyLimRequireLetter"):r.push("密碼須包含至少一個英文字母")),i&&dn(r)>0)throw new Error(r[0]);if(u&&!hI(e)&&(n?r.push("keyLimRequireUppercase"):r.push("密碼須包含至少一個大寫英文字母")),i&&dn(r)>0)throw new Error(r[0]);if(f&&!mI(e)&&(n?r.push("keyLimRequireLowercase"):r.push("密碼須包含至少一個小寫英文字母")),i&&dn(r)>0)throw new Error(r[0]);if(d&&!II(e)&&(n?r.push("keyLimRequireDigit"):r.push("密碼須包含至少一個數字")),i&&dn(r)>0)throw new Error(r[0]);if(g&&!vI(e)&&(n?r.push("keyLimRequireSpecial"):r.push("密碼須包含至少一個特殊符號")),i&&dn(r)>0)throw new Error(r[0]);let p=we(t,"forbiddenChars",null);if(Ce(p)||(p=[]),dn(p)>0){for(let t of p)if(e.includes(t)){if(n){r.push("keyLimForbiddenChar");break}r.push(`密碼不可包含字元:${t}`)}if(i&&dn(r)>0)throw new Error(r[0])}let h=we(t,"commonPasswordBlacklist",null);if(Ce(h)||(h=xI),dn(h)>0){let t=e.toLowerCase();if(h.some(e=>xe(e)&&t===e.toLowerCase())&&(n?r.push("keyLimCommonPassword"):r.push("此密碼為常見弱密碼,不允許使用")),i&&dn(r)>0)throw new Error(r[0])}let A=we(t,"account",""),m=we(t,"noConsecutiveCharsFromAccount",null);pn(m)||(m=!1);let I=we(t,"consecutiveCharsMinMatch","");if(eo(I)||(I=3),I=Zi(I),m&&xe(A)&&dn(A)>=I){let t=[...A.toLowerCase()],o=e.toLowerCase(),a=!1;for(let e=0;e<=t.length-I;e++){let r=t.slice(e,e+I).join("");if(o.includes(r)){a=!0;break}}if(a&&(n?r.push("keyLimConsecutiveCharsFromAccount"):r.push(`密碼不可包含與帳號相同之${I}個以上連續字元`)),i&&dn(r)>0)throw new Error(r[0])}if(dn(r)>0)throw new Error(r.join(" | "));return!0},e.isWindow=In,e.isab=I,e.isarr=Ce,e.isarr0=Lr,e.isbigint=Ta,e.isblob=gs,e.isbol=pn,e.isday=ku,e.isearr=Rr,e.iseobj=Ee,e.iser=Ur,e.isernot=fd,e.isestr=De,e.isfile=Wm,e.isfun=va,e.isint=Hn,e.ismonth=wn,e.isn0int=dI,e.isn0num=gI,e.isnan=Qe,e.isnbr=Fe,e.isnint=Th,e.isnnum=function(e){return!!Se(e)&&Mn(e)<0},e.isnull=qr,e.isnum=Se,e.isobj=Be,e.isobj0=Mr,e.isp0int=Bo,e.isp0num=pI,e.ispint=eo,e.ispm=ys,e.ispnum=ha,e.isstr=xe,e.isstr0=Hr,e.istime=Eg,e.istimeTZ=CI,e.istimems=bI,e.istimemsTZ=EI,e.isu16arr=pm,e.isu8arr=Za,e.isundefined=Nr,e.j2o=Ka,e.judge=function(e,t,r,n={}){if(!Se(e))throw new Error("x1 is not a number");if(!Se(r))throw new Error("x2 is not a number");let i=we(n,"withPreciseNum");if(pn(i)||(i=!0),i&&(e=Kh(e),r=Kh(r)),"==="===t)return e===r||DI(e,r);if("!=="===t)return function(e,t){return!DI(e,t)}(e,r);if(">="===t)return e===r||function(e,t){return new il(e).gte(t)}(e,r);if(">"===t)return function(e,t){return new il(e).gt(t)}(e,r);if("<="===t)return e===r||function(e,t){return new il(e).lte(t)}(e,r);if("<"===t)return function(e,t){return new il(e).lt(t)}(e,r);throw console.log(t),new Error(`invalid op[${t}]`)},e.keysmat2ltdt=FI,e.ltdt2vrtsable=function(e,t=[]){if(!Rr(e))return[];if(!Ce(t))return[];let r=!1;if(Er(e,function(e){Ee(e)||(r=!0)}),r)return[];let n=Xr(e),i=[];Er(e,function(e){let t={};Er(n,function(r){t[r]={value:e[r].value,style:e[r].style,rowspan:1}}),i.push(t)});let o=La(i),a=dn(o);return Er(n,function(e){if(ya(e,t)){let t=ao(0,a,0),r=ao(0,a,0),n=ao(1,a+1,0);Er(o,function(i,a){if(a>0){ma(o[a-1][e].value,o[a][e].value)&&(t[a-1]=1,t[a]=1,n[a]=n[a-1]+1),1===t[a-1]&&1===t[a]&&(r[a-1]=0,r[a]=1)}}),Er(o,function(i,a){1===t[a]&&(1===r[a]?o[a][e].rowspan=n[a]:o[a][e].rowspan=null)})}}),La(o)},e.ltdtDiff=function(e,t,r={}){if(!Ce(e))return{};if(!Ce(t))return{};if(0===dn(e)&&0===dn(t))return{};let n=we(r,"empty");De(n)||(n="∗empty∗");let i=Xr(e),o=Xr(t),a=QI(i,o),s={};Er(a,(e,t)=>{s[t]=e});let c=aa(An(e,a,{empty:n}),An(t,a,{empty:n}),{...r,mode:"matrix"});return c.dfs=xr(c.dfs,e=>{let t={};Er(e,e=>{e.k=s[e.k],t[e.k]=e});let r={};return Er(a,e=>{r[e]=t[e]}),r}),c},e.ltdtDiffByKey=nm,e.ltdtkeys2mat=An,e.ltdtkeysheads2mat=mn,e.ltdtmapping=function(e,t,r=""){return Rr(e)&&Rr(t)?xr(e,e=>Xh(e,t,r)):[]},e.ltdtmerge=mA,e.ltdtpick=function(e,t){return Rr(e)&&Rr(t)?xr(e,e=>_h(e,t)):[]},e.ltdtpull=function(e,t,r){return Ce(e)&&Ce(t)&&De(r)&&gr(e,e=>Be(e))?0===t.length?e:gr(t,e=>Be(e))?kI(e,t,r):[]:[]},e.mat2ltdt=function(e){if(!Rr(e))return[];if(e.length<=1)return[];let t=!1;return Er(e,function(e){Rr(e)||(t=!0)}),t?[]:FI(ra(e)[0],(n=null==(r=e)?0:r.length)?Do(r,1,n):[]);var r,n},e.matConcat=function(e,t){if(!Ce(e))return[];if(!Ce(t))return[];if(0===dn(e)&&0===dn(t))return[];let r=dn(e),n=dn(we(e,0,[])),i=dn(t),o=dn(we(t,0,[])),a=[],s=Math.max(r,i);for(let r=0;r<s;r++){let i=[],s=-1;for(let t=0;t<n;t++){s++;let n=we(e,`${r}.${t}`,null);i[s]=n}for(let e=0;e<o;e++){s++;let n=we(t,`${r}.${e}`,null);i[s]=n}a[r]=i}return a},e.matDiff=function(e,t,r={}){return Ce(e)&&Ce(t)?0===dn(e)&&0===dn(t)?{}:aa(e,t,{...r,mode:"matrix"}):{}},e.matat=function(e,t,r){return Rr(e)?xr(e,function(e){return Eo(e,t,r)}):[]},e.now2str=RA,e.now2strp=function(){if(!va(r))throw new Error("invalid dayjs");return r().format("YYYYMMDDHHmmss")},e.nowDay2str=function(){if(!va(r))throw new Error("invalid dayjs");return r().format("YYYY-MM-DD")},e.nowms2str=function(){if(!va(r))throw new Error("invalid dayjs");return r().format("YYYY-MM-DDTHH:mm:ss.SSSZ")},e.nowms2strp=function(){if(!va(r))throw new Error("invalid dayjs");return r().format("YYYYMMDDHHmmssSSS")},e.o2j=hn,e.obj2b64=function(e){let t="";try{t=NI(hn(e))}catch(e){t=""}return t},e.obj2pb64=function(e,t){return void 0===e?"":De(t)?qI(hn({data:e}),t,!0):""},e.obj2str=function(e,t="Uint8Array"){if(Nr(e))return"";if(xe(t))t=[t];else if(!Ce(t))return"";let r="";try{r=JSON.stringify(e,function(e,r){return t.indexOf("Uint8Array")>=0&&(r=YI.u8arr2b64(r)),t.indexOf("Uint16Array")>=0&&(r=YI.u16arr2b64(r)),r})}catch(e){r=""}return r},e.obj2stru8arr=jI,e.obj2u8arr=function(e){let t=[],r=[];if(!Rr(e)&&!Ee(e))return null;let n=[],i=[];function o(e){n.push(hm(e)),i.push(e)}try{let a=jI(e);o(GI(a.results)),Er(a.binarys,e=>{o(e)});let s=n,c=GI(JSON.stringify(s)),l=new Uint8Array(8);Is(hm(c),l),t.push(l),t.push(c),Er(i,e=>{t.push(e)}),Er(t,e=>{r=function(e,t){let r=hm(e),n=hm(t),i=new Uint8Array(r+n);return i.set(new Uint8Array(e),0),i.set(new Uint8Array(t),r),i}(r,e)})}catch(e){return null}return r},e.objSortBy=JI,e.objSortByKeys=function(e,t){if(!Ee(e))return{};if(!Rr(t))return{};let r={};return Er(t,(e,t)=>{r[e]=t}),JI(e,(e,t)=>we(r,t,0))},e.oo=function(e){if(void 0!==e)return Ka(hn(e))},e.openLink=function(e){if(!De(e))return;let t=document.createElement("a");t.href=e,t.target="_blank",document.body.appendChild(t),t.click(),document.body.removeChild(t)},e.pb642obj=function(e,t){return De(e)&&De(t)?Ka(li(e,t,!0)).data:""},e.pm2resolve=Oh,e.pmChain=function(e,t=null){if(!Ce(e)){let e=ns();return e.reject("pms is not an array"),e}return e.reduce((e,t)=>e.then(t),Promise.resolve(t))},e.pmConvertResolve=Rh,e.pmDebounce=function(e=300){return new function(e){let t=[],r=null,n=null,i="wait";return eo(e)||(e=300),e=Zi(e),function(o,...a){va(o)?((null===n||"wait"===i)&&(n=Date.now()),t.push({func:o,input:a,output:null}),null===r&&"wait"===i&&(r=setInterval(()=>{if(null===n)throw new Error("invalid tLast");if("wait"!==i)return;if("wait"===i&&0===t.length)return clearInterval(r),r=null,void(n=null);let o=Date.now();if(o-n>e){i="doing",n=o;let e=t.pop();t=[];let r=e.func(...e.input);ys(r)?r.then(t=>{e.output=t}).catch(t=>{e.output={err:t}}).finally(()=>{i="wait",n=Date.now()}):(e.output=r,i="wait")}"wait"===i&&0===t.length&&(clearInterval(r),r=null,n=null)},20))):console.log("func is not a function")}}(e)},e.pmHook=zI,e.pmHookReject=function(e,t=()=>{}){return va(e)?(va(t)||(t=()=>{}),zI(e,e=>{if("afterCatch"===e.mode)return t(e.data)})):null},e.pmIni=function(){return Promise.resolve()},e.pmInvResolve=function(e,t={}){if(!ys(e))throw new Error("pm is not a promise");let r=we(t,"thenExtractData");pn(r)||(r=!1);let n=ns();return e.then(e=>{r&&(e=we(e,"data"));let t=we(e,"state",""),i=we(e,"msg",{});"success"===t?n.resolve(i):"cancelled"===t?n.reject({reason:"cancelled"}):n.reject(i)}).catch(e=>{n.reject(e)}),n},e.pmKeyMutex=function(){return new function(){let e=new Map,t=new Map;return async(r,n)=>{let i=(e.get(r)||Promise.resolve()).then(async()=>await n(),async()=>await n());e.set(r,i.catch(()=>{})),t.set(r,(t.get(r)||0)+1);try{return await i}finally{let n=t.get(r)-1;n<=0?(t.delete(r),e.delete(r)):t.set(r,n)}}}},e.pmMap=function(e,t,r=0){let n={},i=!1,o=ns();if(!Ce(e)&&!Be(e))return o.reject("rs is not an array or object"),o;let a=!1;if(Be(e)){a=!0;let t=[];Er(e,(e,r)=>{t.push({k:r,v:e})}),e=t}let s=Yh(r);return s.on("message",function(r){if(i)return;let c,l=s.get();if(va(t)){let e=l.key,r=l.value;if(a&&(e=l.value.k,r=l.value.v),c=t(r,e),!ys(c))throw new Error("return of fun is not a promise")}else c=l.value;c.then(e=>{n[l.key]=e}).catch(e=>{i=!0,s.clear(),o.reject(e)}).finally(()=>{s.cb(),dn(n)===dn(e)&&o.resolve(lA(n))})}),Er(e,(e,t)=>{s.push({key:t,value:e})}),o},e.pmQueue=jh,e.pmSeries=cl,e.pmThrottle=function(){let e=Xi(),t=[],r=null,n=!1;return function(i,...o){let a=ns();if(!va(i))return void console.log("func is not a function");let s=Hu();return t.push({id:s,func:i,input:o}),null===r&&(r=setInterval(async()=>{if(n)return;n=!0;let i=t.pop();for(let r=0;r<t.length;r++){let n=t[r].id,i={state:"cancelled"};e.emit(n,i)}if(t=[],i){let t,r=i.id;t=va(i.func)?await Oh(i.func)(...i.input):{state:"error",msg:"fun is not a function"},e.emit(r,t)}n=!1,n||0!==t.length||(clearInterval(r),r=null)},20)),e.once(s,e=>{"success"===e.state?a.resolve(e.msg):"cancelled"===e.state?a.reject({reason:"cancelled"}):a.reject(e.msg)}),a}},e.preciseNum=Kh,e.pseudoRandom=XI,e.pseudoRandomIntRange=function(e=0,t=100,r="start1"){if(Hn(e)||(e=0),e=Zi(e),Hn(t)||(t=100),e>(t=Zi(t)))throw new Error(`vstart[${e}] > vend[${t}]`);let n=XI(r)*(t-e+1)+e;return n=Math.floor(n),n},e.pseudoRandomIntsNdpRange=function(e=0,t=100,r,n="start1"){if(Hn(e)||(e=0),e=Zi(e),Hn(t)||(t=100),t=Zi(t),eo(r)||(r=1),r=Zi(r),e>t)throw new Error(`vstart[${e}] > vend[${t}]`);let i=XI(n,!0),o=[],a=t-e;for(let r=0;r<=a;r++){let r=i()*(t-e+1)+e;r=Math.floor(r),o.push(r)}let s=_a(o,{returnIndex:!0});return s=ra(s,r),s},e.pseudoRandomIntsRange=function(e=0,t=100,r,n="start1"){if(Hn(e)||(e=0),e=Zi(e),Hn(t)||(t=100),t=Zi(t),eo(r)||(r=1),r=Zi(r),e>t)throw new Error(`vstart[${e}] > vend[${t}]`);let i=XI(n,!0),o=[];for(let n=1;n<=r;n++){let r=i()*(t-e+1)+e;r=Math.floor(r),o.push(r)}return o},e.pseudoRandomRange=function(e=0,t=1,r="start1"){if(Se(e)||(e=0),e=Mn(e),Se(t)||(t=1),e>(t=Mn(t)))throw new Error(`vstart[${e}] > vend[${t}]`);return XI(r)*(t-e)+e},e.pseudoRandomsRange=function(e=0,t=1,r=1,n="start1"){if(Se(e)||(e=0),e=Mn(e),Se(t)||(t=1),t=Mn(t),eo(r)||(r=1),r=Zi(r),e>t)throw new Error(`vstart[${e}] > vend[${t}]`);let i=XI(n,!0),o=[];for(let n=1;n<=r;n++){let r=i()*(t-e)+e;o.push(r)}return o},e.queue=Yh,e.random=WI,e.randomIntRange=function(e=0,t=100){if(Hn(e)||(e=0),e=Zi(e),Hn(t)||(t=100),e>(t=Zi(t)))throw new Error(`vstart[${e}] > vend[${t}]`);let r=WI()*(t-e+1)+e;return r=Math.floor(r),r},e.randomIntsNdpRange=function(e=0,t=100,r){if(Hn(e)||(e=0),e=Zi(e),Hn(t)||(t=100),t=Zi(t),eo(r)||(r=1),r=Zi(r),e>t)throw new Error(`vstart[${e}] > vend[${t}]`);return function(e,t,r){return t=(r?dr(e,t,r):void 0===t)?1:qn(t),(v(e)?ry:ny)(e,t)}(ao(e,t+1),r)},e.randomIntsRange=function(e=0,t=100,r){if(Hn(e)||(e=0),e=Zi(e),Hn(t)||(t=100),t=Zi(t),eo(r)||(r=1),r=Zi(r),e>t)throw new Error(`vstart[${e}] > vend[${t}]`);let n=[];for(let i=1;i<=r;i++){let r=WI()*(t-e+1)+e;r=Math.floor(r),n.push(r)}return n},e.randomRange=function(e=0,t=1){if(Se(e)||(e=0),e=Mn(e),Se(t)||(t=1),e>(t=Mn(t)))throw new Error(`vstart[${e}] > vend[${t}]`);return WI()*(t-e)+e},e.randomsRange=function(e=0,t=1,r=1){if(Se(e)||(e=0),e=Mn(e),Se(t)||(t=1),t=Mn(t),eo(r)||(r=1),r=Zi(r),e>t)throw new Error(`vstart[${e}] > vend[${t}]`);let n=[];for(let i=1;i<=r;i++){let r=WI()*(t-e)+e;n.push(r)}return n},e.rang=function(e,t,r=2){if(!Se(e))return[];if(e=Mn(e),!Se(t))return[];if(t=Mn(t),eo(r)||(r=2),(r=Zi(r))<=0)throw new Error(`num[${r}] <= 0`);let n=(t-e)/r,i=e,o=[];for(let e=0;e<=r;e++)o.push(i),i+=n;return o},e.rep=function(e,t){return De(e)&&Bo(t)?oy(e,t):""},e.repObj=function(e,t){return Ur(e)?[]:eo(t)?tI(t,fo(e)):[]},e.replace=pl,e.replaceObj=function(e,t){return De(e)&&Ee(t)?(Er(t,function(e,t){e=Be(e)||Ce(e)?JSON.stringify(e):Ya(e)}),Er(t,function(t,r){e=pl(e,r,t)}),e):""},e.replacePlus=function(e,t,r,n=null,i){if(!De(e)||!De(t)||!De(r))return"";if(!xe(i))return"";let o="[\\s\\S]*";De(n)&&(o="[^"+n+"]*");let a=new RegExp(t+o+r,"g");return e.replace(a,i)},e.round=Wh,e.secd=function(e){return Se(e)?1/Du(e=Mn(e)):null},e.sep=la,e.sepInt=function(e,t,r=!0){if(!Hn(e))return[];if(!Bo(t))return[];if(!pn(r))return[];let n=ay(e/t),i=e-n*t,o=[];for(let e=1;e<=t;e++){let t=n;e<=i&&(t=n+1),o.push(t)}return r&&(o=La(o)),o},e.setIntervalHp=function(e,t=1){let r=yn(),n=In(),i=e=>{r.setTimeout(e,1)},o=e=>{r.requestAnimationFrame(e)},a=null;a=n?o:i;let s=iI(),c=!0,l=s(),u=()=>{if(!c)return;if(s()-l>=t){try{e()}catch(e){console.log(e)}l=s()}a(u)};return a(u),()=>{c=!1}},e.setTimeoutHp=function(e,t=1){let r=yn(),n=In(),i=e=>{r.setTimeout(e,1)},o=e=>{r.requestAnimationFrame(e)},a=null;a=n?o:i;let s=iI(),c=!0,l=s(),u=()=>{if(!c)return;if(s()-l>=t){c=!1;try{e()}catch(e){console.log(e)}}a(u)};return a(u),null},e.sind=Su,e.split=ca,e.str2aes=qI,e.str2b64=NI,e.str2hint=VI,e.str2md5=function(e,t=!1){if(!De(e))return"";if(!pn(t))return"";let r=sy(e),n="";return n=t?r.toString(zn):r.toString(ci),n},e.str2obj=function(e,t="Uint8Array"){if(xe(t))t=[t];else if(!Ce(t))return{};let r={};try{r=JSON.parse(e,function(e,r){return t.indexOf("Uint8Array")>=0&&(r=YI.b642u8arr(r)),t.indexOf("Uint16Array")>=0&&(r=YI.b642u16arr(r)),r})}catch(e){r={}}return r},e.str2sha512=function(e,t=!1){if(!De(e))return"";if(!pn(t))return"";let r=fy(e),n="";return n=t?r.toString(zn):r.toString(ci),n},e.str2u8arr=GI,e.strCompare=dy,e.strDiff=na,e.strDiffToHtml=function(e,t,r={}){if(!xe(e))return"";if(!xe(t))return"";if(""===e&&""===t)return"";let n=we(r,"useNormNewline");pn(n)||(n=!0),n&&(e=(e=e.replaceAll("\r\n","\n")).replaceAll("\r","\n"),t=(t=t.replaceAll("\r\n","\n")).replaceAll("\r","\n"));let i=Jf(),o=ea("file","file",e,t),a=i.html(o,{drawFileList:!1,matching:"none",diffStyle:"char",outputFormat:"line-by-line"}),s=Jo(a,"\n"),c="",l=!1;return Er(s,e=>{'<div class="d2h-code-line">'===sa(e)&&(l=!0),e.indexOf('class="d2h-code-line-prefix"')>=0&&(e=e.replaceAll('class="d2h-code-line-prefix"','class="d2h-code-line-prefix" style="display:inline-block; width: 0.7rem;"')),e.indexOf("<del>")>=0&&(e=e.replaceAll("<del>",'<del style="color:#f26; background:#ffefd5;">')),e.indexOf("<ins>")>=0&&(e=e.replaceAll("<ins>",'<ins style="color:#090; background:#e4fed1;">')),l&&(c+=e+"\n"),l&&"</div>"===sa(e)&&(l=!1)}),a=c,a},e.strFindFuzz=function(e,t,r=!1){let n="";if(De(e)||Se(e))n=Ya(e);else{if(!Rr(e))return!!r&&0;n=xo(e,"")}if(""===t)return!r||100;if(Ur(t))return!!r&&0;if(rs(n,t))return!r||100;let i=la(t," "),o=xr(i,function(e){return((e,t)=>{let r=new dv([e],{includeScore:!0}).search(t);r=we(r,0);let n=we(r,"score",1);return n=1-n,n*=100,n})(n,e)});if(r)return gv(o);{let e=80;return gr(o,function(t){return t>=e})}},e.strFindSimilar=function(e,t){let r="";if(De(e)||Se(e))r=Ya(e);else{if(!Rr(e))return{};r=xo(e,"")}return Se(t)&&(t=Ya(t)),De(t)&&(t=[t]),Rr(t)?function(e,t){let r=[],n=0;for(let i=0;i<t.length;i++){let o=t[i],a=dy(e,o);r.push({target:o,rating:a}),a>r[n].rating&&(n=i)}return{ratings:r,bestMatch:r[n],bestMatchIndex:n}}(r,t=xr(t,function(e){return Ya(e)})):{}},e.strdelleft=da,e.strdelright=Ga,e.strleft=ua,e.strmid=hl,e.strright=fa,e.stru8arr2obj=pv,e.tand=Fu,e.time2day=function(e){return Eg(e)?r(e,"YYYY-MM-DDTHH:mm:ss").format("YYYY-MM-DD"):""},e.time2hour=function(e){return Eg(e)?r(e,"YYYY-MM-DDTHH:mm:ss").format("YYYY-MM-DDTHH"):""},e.time2min=oI,e.timeTZ2day=function(e){return CI(e)?(e=BI.delTZ(e),r(e,"YYYY-MM-DDTHH:mm:ss").format("YYYY-MM-DD")):""},e.timeTZ2expire=function(e,t=null){return CI(e)?hv(e=mv(e),t=mv(t)):{today:null,msg:"",err:"時間格式錯誤"}},e.timeTZ2hour=function(e){return CI(e)?(e=BI.delTZ(e),r(e,"YYYY-MM-DDTHH:mm:ss").format("YYYY-MM-DDTHH")):""},e.timeTZ2min=function(e){return CI(e)?(e=BI.delTZ(e),r(e,"YYYY-MM-DDTHH:mm:ss").format("YYYY-MM-DDTHH:mm")):""},e.timeTZ2past=function(e,t=null){return CI(e)?Av(e=Iv(e),t=Iv(t)):{today:null,msg:"",err:"時間格式錯誤"}},e.timems2day=function(e){return bI(e)?r(e,"YYYY-MM-DDTHH:mm:ss.SSS").format("YYYY-MM-DD"):""},e.timems2hour=function(e){return bI(e)?r(e,"YYYY-MM-DDTHH:mm:ss.SSS").format("YYYY-MM-DDTHH"):""},e.timems2min=function(e){return bI(e)?r(e,"YYYY-MM-DDTHH:mm:ss.SSS").format("YYYY-MM-DDTHH:mm"):""},e.timems2time=function(e){return bI(e)?r(e,"YYYY-MM-DDTHH:mm:ss.SSS").format("YYYY-MM-DDTHH:mm:ss"):""},e.timemsTZ2day=function(e){return EI(e)?(e=BI.delTZ(e),r(e).format("YYYY-MM-DD")):""},e.timemsTZ2expire=hv,e.timemsTZ2hour=function(e){return EI(e)?(e=BI.delTZ(e),r(e).format("YYYY-MM-DDTHH")):""},e.timemsTZ2min=function(e){return EI(e)?(e=BI.delTZ(e),r(e).format("YYYY-MM-DDTHH:mm")):""},e.timemsTZ2past=Av,e.timemsTZ2time=function(e){return EI(e)?(e=BI.delTZ(e),r(e).format("YYYY-MM-DDTHH:mm:ss")):""},e.treeObj=Eu,e.treeToFilepath=function(e,t={}){if(!Rr(e))return[];let r=we(t,"delimiter");De(r)||(r="/");let n=we(t,"bindRoot");De(n)||(n="root");let i=[];return Eu(e,(e,t,o)=>{let a=we(e,"_type","");if("folder"!==a&&"file"!==a)return e;let s=xr(we(e,"pathInfors",[]),"name"),c=we(s,0,"")===n;if(1===dn(s)&&c)return e;c&&(s=ja(s));let l={type:a,path:r+xo(s,r)};return i.push(l),e},{force:!0}),i},e.trim=Ja,e.u16arr2b64=RI,e.u16arr2u8arr=UI,e.u8arr2ab=function(e){return Za(e)?e.buffer:new ArrayBuffer},e.u8arr2b64=LI,e.u8arr2blob=Ph,e.u8arr2bs=function(e){if(!Za(e))return"";let t=e.length,r="";for(let n=0;n<t;n++)r+=String.fromCharCode(e[n]);return r},e.u8arr2obj=function(e){let t=null;if(!Za(e))return null;try{let r=8,n=e.slice(0,r),i=e.slice(r,hm(e)),o=As(n),a=i.slice(0,o),s=i.slice(o,hm(i)),c=yv(a),l=function(e,t){let r=0,n=0,i=[];return Er(t,t=>{n=r+t;let o=e.slice(r,n);r=n,i.push(o)}),i}(s,JSON.parse(c));t=pv({results:yv(l.shift()),binarys:l})}catch(e){}return t},e.u8arr2str=yv,e.u8arr2u16arr=es,e.urlParse=function(e){if(!De(e))return{};if(!De(e=we(e=Jo(e,"?"),"[1]")))return{};let t=Jo(e,"&");return t=xr(t,function(e){return Jo(e,"=")}),t=function(e){for(var t=-1,r=null==e?0:e.length,n={};++t<r;){var i=e[t];di(n,i[0],i[1])}return n}(t),t},e.verifyValue=function(e,t,r={}){let n=!1,i="";if("isstr"===t)xe(e)||(n=!0,i="需要為字串",e="");else if("isnum"===t)Se(e)||(n=!0,i="需要為數字",e=0);else if("isp0num"===t)pI(e)||(n=!0,i="需要為含0的正浮點數",e=0);else if("isn0num"===t)gI(e)||(n=!0,i="需要為含0的負浮點數",e=0);else if("isint"===t)Hn(e)||(n=!0,i="需要為整數",e=0);else if("ispint"===t)eo(e)||(n=!0,i="需要為不含0正整數",e=0);else if("isp0int"===t)Bo(e)||(n=!0,i="需要為含0正整數",e=0);else if("isnint"===t)Th(e)||(n=!0,i="需要為不含0負整數",e=0);else if("isn0int"===t)dI(e)||(n=!0,i="需要為含0負整數",e=0);else if("custom"===t){let t=we(r,"funCustom");if(!va(t))throw new Error("invalid opt.funCustom when type='custom'");let o=t(e);if(!pn(o.err))throw new Error("invalid return.err for type='custom'");if(o.err&&!De(o.errmsg))throw new Error("invalid return.errmsg when return.err=true for type='custom'");if(!Se(o.value)&!xe(o.value))throw new Error("invalid return.value for type='custom'");n=o.err,i=o.errmsg,e=o.value}else if(va(t)){e=t(e)}else"any"===t?Se(e)||xe(e)||(n=!0,i="需要為字串或數字",e=""):(n=!0,i="需要指定驗證類型",e=null);return{value:e,err:n,errmsg:i}},e.waitFun=vs});
23
+ return/[!-/:-@[-`{-~]/.test(e)}function bI(e){if(!De(e))return!1;let t="YYYY-MM-DDTHH:mm:ss.SSS";return e===r(e,t).format(t)}function wI(e){let t;return t=fa(e,1),"Z"===t?`${e=Ga(e,1)}+00:00`:e}let BI={checkTZ:function(e){let t;return t=fa(e,1),"Z"===t||(t=fa(e,6),!!/[+|-]\d\d:\d\d/.test(t))},delTZ:function(e){let t;return t=fa(e,1),Ga(e,"Z"===t?1:6)},normTZ:wI,sepTZ:function(e){let t=wI(e);return{t:Ga(t,6),tz:fa(t,6)}}};function EI(e){if(!De(e))return!1;if(!BI.checkTZ(e))return!1;let t=BI.delTZ(e),n="YYYY-MM-DDTHH:mm:ss.SSS";return t===r(t,n).format(n)}function CI(e){if(!De(e))return!1;if(!BI.checkTZ(e))return!1;let t=BI.delTZ(e),n="YYYY-MM-DDTHH:mm:ss";return t===r(t,n).format(n)}let xI=["1234","12345","123456","1234567","12345678","123456789","1234567890","12345678910","111111","000000","666666","888888","7777777","11111111","123123","123321","654321","987654321","qwerty","qwerty123","qwerty1","qwertyuiop","qazwsx","1q2w3e4r","1q2w3e4r5t","1q2w3e","1qaz2wsx","zxcvbnm","password","password1","passw0rd","admin","admin123","welcome","letmein","login","master","monkey","dragon","shadow","sunshine","superman","batman","football","baseball","soccer","hockey","michael","jordan","jennifer","hunter","ranger","harley","thomas","charlie","andrew","daniel","ashley","bailey","mustang","access","secret","ninja","jesus","hello","freedom","trustno1","1qaz@WSX","P@ssw0rd","Pass@123","Aa123456","Aa@123456","Admin@123","abc@123","abc123","abcdef","abcd1234","abc","iloveyou","fuckyou","f*ckyou","whatever","nothing","google","computer","internet","samsung","apple","killer","princess","lovely","tigger","starwars","pokemon","minecraft","123qwe","zaq1zaq1","photoshop","adobe123","18atcskd2w","mynoob"];function DI(e,t){return new il(e).eq(t)}function FI(e,t){if(!Rr(e))return[];if(!Rr(t))return[];if(!Rr(t[0]))return[];return xr(t,function(t){let r=to(e,t);return Er(r,function(e,t){void 0===e&&(r[t]="")}),r})}var QI=Ra(function(e){return Vr(Qr(e,1,hg,!0))});var SI=Ra(function(e,t){var r=Qa(t);return hg(r)&&(r=void 0),hg(e)?function(e,t,r,n){var i=-1,o=jr,a=!0,s=e.length,c=[],l=t.length;if(!s)return c;r&&(t=pe(t,We(r))),n?(o=Gr,a=!1):t.length>=200&&(o=yt,a=!1,t=new mt(t));e:for(;++i<s;){var u=e[i],f=null==r?u:r(u);if(u=n||0!==u?u:0,a&&f==f){for(var d=l;d--;)if(t[d]===f)continue e;c.push(u)}else o(t,f,n)||c.push(u)}return c}(e,Qr(t,1,hg,!0),fr(r)):[]}),kI=SI;function NI(e){if(!De(e))return"";let t=ai.parse(e);return zn.stringify(t)}function qI(e,t,r=!1){if(!De(e))return"";if(!De(t))return"";if(!pn(r))return"";let n=ii.encrypt(e,t),i="";if(r)i=n.toString();else{let e=n.toString();i=zn.parse(e).toString(ci)}return i}var MI={exports:{}};!function(e){var t;e.exports=(t=Yn(),function(){if("function"==typeof ArrayBuffer){var e=t.lib.WordArray,r=e.init,n=e.init=function(e){if(e instanceof ArrayBuffer&&(e=new Uint8Array(e)),(e instanceof Int8Array||"undefined"!=typeof Uint8ClampedArray&&e instanceof Uint8ClampedArray||e instanceof Int16Array||e instanceof Uint16Array||e instanceof Int32Array||e instanceof Uint32Array||e instanceof Float32Array||e instanceof Float64Array)&&(e=new Uint8Array(e.buffer,e.byteOffset,e.byteLength)),e instanceof Uint8Array){for(var t=e.byteLength,n=[],i=0;i<t;i++)n[i>>>2]|=e[i]<<24-i%4*8;r.call(this,n,t)}else r.apply(this,arguments)};n.prototype=e}}(),t.lib.WordArray)}(MI);var HI=Un(MI.exports);function LI(e){if(!Za(e))return"";return HI.create(e).toString(zn)}function UI(e){return pm(e)?new Uint8Array(e):new Uint8Array}function RI(e){return pm(e)?LI(UI(e)):""}let OI="[Uint8Array]::";let TI="[Uint16Array]::";let YI={tagU8A:OI,u8arr2b64:function(e){return Za(e)?OI+LI(e):e},b642u8arr:function(e){return xe(e)&&ua(e,14)===OI?$a(e=da(e,14)):e},tagU16A:TI,u16arr2b64:function(e){return pm(e)?TI+RI(e):e},b642u16arr:function(e){return xe(e)&&ua(e,15)===TI?ts(e=da(e,15)):e}};function jI(e){if(!Be(e))return{results:"",binarys:[]};if(Mr(e))return{results:"",binarys:[]};let t="",r=[];try{let n=-1;t=JSON.stringify(e,function(e,t){if(Za(t)){n+=1;let e=`[Uint8Array]::${n}`;return r.push(t),e}if(pm(t)){n+=1;let e=`[Uint16Array]::${n}`;return r.push(t),e}if(I(t)){n+=1;let e=`[ArrayBuffer]::${n}`;return r.push(t),e}return bm(t)&&(t=t.toString()),t})}catch(e){}return{results:t,binarys:r}}function GI(e){if(!De(e))return new Uint8Array;let t;try{t=$a(NI(e))}catch(e){return new Uint8Array}return t}function JI(e,t){if(!Ee(e))return{};if(!va(t))throw new Error("fun is not a function");let r=xr(e,(e,r)=>({k:r,v:e,t:t(e,r)}));r=Oa(r,"t");let n={};return Er(r,e=>{n[e.k]=e.v}),n}function zI(e,t=()=>{}){if(!va(e))return null;function r(e,t){let r;return qr(e)||Nr(e)?t:(r=we(e,"data",null),r||e)}return va(t)||(t=()=>{}),function(){let n,i=ns(),o=t({mode:"before",data:arguments});return(qr(o)||Nr(o))&&(o=arguments),e(...o).then(e=>{n=t({mode:"afterThen",data:e}),e=r(n,e),i.resolve(e)}).catch(e=>{n=t({mode:"afterCatch",data:e}),e=r(n,e),i.reject(e)}),i}}function VI(e){if(!xe(e))return null;if(""===e)return 0;let t=e.split("").reduce((e,t)=>t.charCodeAt(0)+(e<<6)+(e<<16)-e,0);return t}let PI=0;function XI(e="start1",t=!1){void 0===e?e=(new Date).getTime():"start1"===e&&(PI++,e=PI);let r=624,n=397,i=2147483648,o=2147483647,a=new Array(r),s=625,c=e=>{for(Ia(e)?a[0]=e>>>0:(e=Ya(e),a[0]=VI(e)),s=1;s<r;s++){let e=a[s-1]^a[s-1]>>>30;a[s]=(1812433253*((4294901760&e)>>>16)<<16)+1812433253*(65535&e)+s,a[s]>>>=0}},l=()=>(()=>{let e,t=new Array(2567483615);if(s>=r){let l;for(625===s&&c(5489),l=0;l<227;l++)e=a[l]&i|a[l+1]&o,a[l]=a[l+n]^e>>>1^t[1&e];for(;l<623;l++)e=a[l]&i|a[l+1]&o,a[l]=a[l+(n-r)]^e>>>1^t[1&e];e=a[623]&i|a[0]&o,a[623]=a[396]^e>>>1^t[1&e],s=0}return e=a[s++],e^=e>>>11,e^=e<<7&2636928640,e^=e<<15&4022730752,e^=e>>>18,e>>>0})()*(1/4294967296);c(e);let u=null;return u=t?l:l(),u}let _I=XI((new Date).getTime(),!0);function WI(){return _I()}function KI(e,t,r){return e==e&&(void 0!==r&&(e=e<=r?e:r),void 0!==t&&(e=e>=t?e:t)),e}var $I=Math.floor,ZI=Math.random;function ey(e,t){return e+$I(ZI()*(t-e+1))}function ty(e,t){var r=-1,n=e.length,i=n-1;for(t=void 0===t?n:t;++r<t;){var o=ey(r,i),a=e[o];e[o]=e[r],e[r]=a}return e.length=t,e}function ry(e,t){return ty(Sr(e),KI(t,0,e.length))}function ny(e,t){var r=lA(e);return ty(r,KI(t,0,r.length))}var iy=Math.floor;function oy(e,t,r){return t=(r?dr(e,t,r):void 0===t)?1:qn(t),function(e,t){var r="";if(!e||t<1||t>9007199254740991)return r;do{t%2&&(r+=e),(t=iy(t/2))&&(e+=e)}while(t);return r}(Ie(e),t)}var ay=Ki("floor");var sy=Un(Pn());var cy,ly={exports:{}},uy={exports:{}};!function(e){var t;e.exports=(t=Yn(),cy||(cy=1,function(e){var t,r,n,i,o,a,s;e.exports=(n=(r=s=Yn()).lib,i=n.Base,o=n.WordArray,(a=r.x64={}).Word=i.extend({init:function(e,t){this.high=e,this.low=t}}),a.WordArray=i.extend({init:function(e,r){e=this.words=e||[],this.sigBytes=r!=t?r:8*e.length},toX32:function(){for(var e=this.words,t=e.length,r=[],n=0;n<t;n++){var i=e[n];r.push(i.high),r.push(i.low)}return o.create(r,this.sigBytes)},clone:function(){for(var e=i.clone.call(this),t=e.words=this.words.slice(0),r=t.length,n=0;n<r;n++)t[n]=t[n].clone();return e}}),s)}(uy)),function(){var e=t,r=e.lib.Hasher,n=e.x64,i=n.Word,o=n.WordArray,a=e.algo;function s(){return i.create.apply(i,arguments)}var c=[s(1116352408,3609767458),s(1899447441,602891725),s(3049323471,3964484399),s(3921009573,2173295548),s(961987163,4081628472),s(1508970993,3053834265),s(2453635748,2937671579),s(2870763221,3664609560),s(3624381080,2734883394),s(310598401,1164996542),s(607225278,1323610764),s(1426881987,3590304994),s(1925078388,4068182383),s(2162078206,991336113),s(2614888103,633803317),s(3248222580,3479774868),s(3835390401,2666613458),s(4022224774,944711139),s(264347078,2341262773),s(604807628,2007800933),s(770255983,1495990901),s(1249150122,1856431235),s(1555081692,3175218132),s(1996064986,2198950837),s(2554220882,3999719339),s(2821834349,766784016),s(2952996808,2566594879),s(3210313671,3203337956),s(3336571891,1034457026),s(3584528711,2466948901),s(113926993,3758326383),s(338241895,168717936),s(666307205,1188179964),s(773529912,1546045734),s(1294757372,1522805485),s(1396182291,2643833823),s(1695183700,2343527390),s(1986661051,1014477480),s(2177026350,1206759142),s(2456956037,344077627),s(2730485921,1290863460),s(2820302411,3158454273),s(3259730800,3505952657),s(3345764771,106217008),s(3516065817,3606008344),s(3600352804,1432725776),s(4094571909,1467031594),s(275423344,851169720),s(430227734,3100823752),s(506948616,1363258195),s(659060556,3750685593),s(883997877,3785050280),s(958139571,3318307427),s(1322822218,3812723403),s(1537002063,2003034995),s(1747873779,3602036899),s(1955562222,1575990012),s(2024104815,1125592928),s(2227730452,2716904306),s(2361852424,442776044),s(2428436474,593698344),s(2756734187,3733110249),s(3204031479,2999351573),s(3329325298,3815920427),s(3391569614,3928383900),s(3515267271,566280711),s(3940187606,3454069534),s(4118630271,4000239992),s(116418474,1914138554),s(174292421,2731055270),s(289380356,3203993006),s(460393269,320620315),s(685471733,587496836),s(852142971,1086792851),s(1017036298,365543100),s(1126000580,2618297676),s(1288033470,3409855158),s(1501505948,4234509866),s(1607167915,987167468),s(1816402316,1246189591)],l=[];!function(){for(var e=0;e<80;e++)l[e]=s()}();var u=a.SHA512=r.extend({_doReset:function(){this._hash=new o.init([new i.init(1779033703,4089235720),new i.init(3144134277,2227873595),new i.init(1013904242,4271175723),new i.init(2773480762,1595750129),new i.init(1359893119,2917565137),new i.init(2600822924,725511199),new i.init(528734635,4215389547),new i.init(1541459225,327033209)])},_doProcessBlock:function(e,t){for(var r=this._hash.words,n=r[0],i=r[1],o=r[2],a=r[3],s=r[4],u=r[5],f=r[6],d=r[7],g=n.high,p=n.low,h=i.high,A=i.low,m=o.high,I=o.low,y=a.high,v=a.low,b=s.high,w=s.low,B=u.high,E=u.low,C=f.high,x=f.low,D=d.high,F=d.low,Q=g,S=p,k=h,N=A,q=m,M=I,H=y,L=v,U=b,R=w,O=B,T=E,Y=C,j=x,G=D,J=F,z=0;z<80;z++){var V,P,X=l[z];if(z<16)P=X.high=0|e[t+2*z],V=X.low=0|e[t+2*z+1];else{var _=l[z-15],W=_.high,K=_.low,$=(W>>>1|K<<31)^(W>>>8|K<<24)^W>>>7,Z=(K>>>1|W<<31)^(K>>>8|W<<24)^(K>>>7|W<<25),ee=l[z-2],te=ee.high,re=ee.low,ne=(te>>>19|re<<13)^(te<<3|re>>>29)^te>>>6,ie=(re>>>19|te<<13)^(re<<3|te>>>29)^(re>>>6|te<<26),oe=l[z-7],ae=oe.high,se=oe.low,ce=l[z-16],le=ce.high,ue=ce.low;P=(P=(P=$+ae+((V=Z+se)>>>0<Z>>>0?1:0))+ne+((V+=ie)>>>0<ie>>>0?1:0))+le+((V+=ue)>>>0<ue>>>0?1:0),X.high=P,X.low=V}var fe,de=U&O^~U&Y,ge=R&T^~R&j,pe=Q&k^Q&q^k&q,he=S&N^S&M^N&M,Ae=(Q>>>28|S<<4)^(Q<<30|S>>>2)^(Q<<25|S>>>7),me=(S>>>28|Q<<4)^(S<<30|Q>>>2)^(S<<25|Q>>>7),Ie=(U>>>14|R<<18)^(U>>>18|R<<14)^(U<<23|R>>>9),ye=(R>>>14|U<<18)^(R>>>18|U<<14)^(R<<23|U>>>9),ve=c[z],be=ve.high,we=ve.low,Be=G+Ie+((fe=J+ye)>>>0<J>>>0?1:0),Ee=me+he;G=Y,J=j,Y=O,j=T,O=U,T=R,U=H+(Be=(Be=(Be=Be+de+((fe+=ge)>>>0<ge>>>0?1:0))+be+((fe+=we)>>>0<we>>>0?1:0))+P+((fe+=V)>>>0<V>>>0?1:0))+((R=L+fe|0)>>>0<L>>>0?1:0)|0,H=q,L=M,q=k,M=N,k=Q,N=S,Q=Be+(Ae+pe+(Ee>>>0<me>>>0?1:0))+((S=fe+Ee|0)>>>0<fe>>>0?1:0)|0}p=n.low=p+S,n.high=g+Q+(p>>>0<S>>>0?1:0),A=i.low=A+N,i.high=h+k+(A>>>0<N>>>0?1:0),I=o.low=I+M,o.high=m+q+(I>>>0<M>>>0?1:0),v=a.low=v+L,a.high=y+H+(v>>>0<L>>>0?1:0),w=s.low=w+R,s.high=b+U+(w>>>0<R>>>0?1:0),E=u.low=E+T,u.high=B+O+(E>>>0<T>>>0?1:0),x=f.low=x+j,f.high=C+Y+(x>>>0<j>>>0?1:0),F=d.low=F+J,d.high=D+G+(F>>>0<J>>>0?1:0)},_doFinalize:function(){var e=this._data,t=e.words,r=8*this._nDataBytes,n=8*e.sigBytes;return t[n>>>5]|=128<<24-n%32,t[30+(n+128>>>10<<5)]=Math.floor(r/4294967296),t[31+(n+128>>>10<<5)]=r,e.sigBytes=4*t.length,this._process(),this._hash.toX32()},clone:function(){var e=r.clone.call(this);return e._hash=this._hash.clone(),e},blockSize:32});e.SHA512=r._createHelper(u),e.HmacSHA512=r._createHmacHelper(u)}(),t.SHA512)}(ly);var fy=Un(ly.exports);function dy(e,t){return De(e)&&De(t)?function(e,t){if(e=e.replace(/\s+/g,""),t=t.replace(/\s+/g,""),!e.length&&!t.length)return 1;if(!e.length||!t.length)return 0;if(e===t)return 1;if(1===e.length&&1===t.length)return 0;if(e.length<2||t.length<2)return 0;let r=new Map;for(let t=0;t<e.length-1;t++){const n=e.substring(t,t+2),i=r.has(n)?r.get(n)+1:1;r.set(n,i)}let n=0;for(let e=0;e<t.length-1;e++){const i=t.substring(e,e+2),o=r.has(i)?r.get(i):0;o>0&&(r.set(i,o-1),n++)}return 2*n/(e.length+t.length-2)}(e,t):0}function gy(e){return Array.isArray?Array.isArray(e):"[object Array]"===by(e)}function py(e){return null==e?"":function(e){if("string"==typeof e)return e;if("bigint"==typeof e)return e.toString();const t=e+"";return"0"==t&&1/e==-1/0?"-0":t}(e)}function hy(e){return"string"==typeof e}function Ay(e){return"number"==typeof e}function my(e){return!0===e||!1===e||function(e){return Iy(e)&&null!==e}(e)&&"[object Boolean]"==by(e)}function Iy(e){return"object"==typeof e}function yy(e){return null!=e}function vy(e){return!e.trim().length}function by(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":Object.prototype.toString.call(e)}const wy="Invalid doc index: must be a non-negative integer within the bounds of the docs array",By=Object.prototype.hasOwnProperty;var Ey=class{constructor(e){this._keys=[],this._keyMap={};let t=0;e.forEach(e=>{const r=Cy(e);this._keys.push(r),this._keyMap[r.id]=r,t+=r.weight}),this._keys.forEach(e=>{e.weight/=t})}get(e){return this._keyMap[e]}keys(){return this._keys}toJSON(){return JSON.stringify(this._keys)}};function Cy(e){let t=null,r=null,n=null,i=1,o=null;if(hy(e)||gy(e))n=e,t=xy(e),r=Dy(e);else{if(!By.call(e,"name"))throw new Error((e=>`Missing ${e} property in key`)("name"));const a=e.name;if(n=a,By.call(e,"weight")&&void 0!==e.weight&&(i=e.weight,i<=0))throw new Error((e=>`Property 'weight' in key '${e}' must be a positive integer`)(Dy(a)));t=xy(a),r=Dy(a),o=e.getFn??null}return{path:t,id:r,weight:i,src:n,getFn:o}}function xy(e){return gy(e)?e:e.split(".")}function Dy(e){return gy(e)?e.join("."):e}const Fy={useExtendedSearch:!1,useTokenSearch:!1,tokenize:void 0,tokenMatch:"any",getFn:function(e,t){const r=[];let n=!1;const i=(e,t,o,a)=>{if(yy(e))if(t[o]){const s=e[t[o]];if(!yy(s))return;if(o===t.length-1&&(hy(s)||Ay(s)||my(s)||"bigint"==typeof s))r.push(void 0!==a?{v:py(s),i:a}:py(s));else if(gy(s)){n=!0;for(let e=0,r=s.length;e<r;e+=1)i(s[e],t,o+1,e)}else t.length&&i(s,t,o+1,a)}else r.push(void 0!==a?{v:e,i:a}:e)};return i(e,hy(t)?t.split("."):t,0),n?r:r[0]},ignoreLocation:!1,ignoreFieldNorm:!1,fieldNormWeight:1},Qy=Object.freeze({isCaseSensitive:!1,ignoreDiacritics:!1,includeScore:!1,keys:[],shouldSort:!0,sortFn:(e,t)=>e.score===t.score?e.idx<t.idx?-1:1:e.score<t.score?-1:1,includeMatches:!1,findAllMatches:!1,minMatchCharLength:1,location:0,threshold:.6,distance:100,...Fy});var Sy=class{constructor({getFn:e=Qy.getFn,fieldNormWeight:t=Qy.fieldNormWeight}={}){this.norm=function(e=1,t=3){const r=new Map,n=Math.pow(10,t);return{get(t){let i=1,o=!1;for(let e=0;e<t.length;e++)32===t.charCodeAt(e)?o||(i++,o=!0):o=!1;if(r.has(i))return r.get(i);const a=Math.round(n/Math.pow(i,.5*e))/n;return r.set(i,a),a},clear(){r.clear()}}}(t,3),this.getFn=e,this.isCreated=!1,this.docs=[],this.keys=[],this._keysMap={},this.setIndexRecords()}setSources(e=[]){this.docs=e}setIndexRecords(e=[]){this.records=e}setKeys(e=[]){this.keys=e,this._keysMap={},e.forEach((e,t)=>{this._keysMap[e.id]=t})}create(){if(this.isCreated||!this.docs.length)return;this.isCreated=!0;const e=this.docs.length;this.records=new Array(e);let t=0;if(hy(this.docs[0]))for(let r=0;r<e;r++){const e=this._createStringRecord(this.docs[r],r);e&&(this.records[t++]=e)}else for(let r=0;r<e;r++)this.records[t++]=this._createObjectRecord(this.docs[r],r);this.records.length=t,this.norm.clear()}add(e,t){if(!Number.isInteger(t)||t<0)throw new Error(wy);if(hy(e)){const r=this._createStringRecord(e,t);return r&&this.records.push(r),r}const r=this._createObjectRecord(e,t);return this.records.push(r),r}removeAt(e){if(!Number.isInteger(e)||e<0)throw new Error(wy);for(let t=0,r=this.records.length;t<r;t+=1)if(this.records[t].i===e){this.records.splice(t,1);break}for(let t=0,r=this.records.length;t<r;t+=1)this.records[t].i>e&&(this.records[t].i-=1)}removeAll(e){const t=new Set;for(const r of e)Number.isInteger(r)&&r>=0&&t.add(r);if(0===t.size)return;this.records=this.records.filter(e=>!t.has(e.i));const r=Array.from(t).sort((e,t)=>e-t);for(const e of this.records){let t=0,n=r.length;for(;t<n;){const i=t+n>>>1;r[i]<e.i?t=i+1:n=i}e.i-=t}}getValueForItemAtKeyId(e,t){return e[this._keysMap[t]]}size(){return this.records.length}_createStringRecord(e,t){return!yy(e)||vy(e)?null:{v:e,i:t,n:this.norm.get(e)}}_createObjectRecord(e,t){const r={i:t,$:{}};for(let t=0,n=this.keys.length;t<n;t++){const n=this.keys[t],i=n.getFn?n.getFn(e):this.getFn(e,n.path);if(yy(i))if(gy(i)){const e=[];for(let t=0,r=i.length;t<r;t+=1){const r=i[t];if(yy(r))if(hy(r)){if(!vy(r)){const n={v:r,i:t,n:this.norm.get(r)};e.push(n)}}else if(yy(r.v)){const t=hy(r.v)?r.v:py(r.v);if(!vy(t)){const n={v:t,i:r.i,n:this.norm.get(t)};e.push(n)}}}r.$[t]=e}else if(hy(i)&&!vy(i)){const e={v:i,n:this.norm.get(i)};r.$[t]=e}}return r}toJSON(){return{keys:this.keys.map(({getFn:e,...t})=>t),records:this.records}}};function ky(e,t,{getFn:r=Qy.getFn,fieldNormWeight:n=Qy.fieldNormWeight}={}){const i=new Sy({getFn:r,fieldNormWeight:n});return i.setKeys(e.map(Cy)),i.setSources(t),i.create(),i}function Ny(e,t,r,{location:n=Qy.location,distance:i=Qy.distance,threshold:o=Qy.threshold,findAllMatches:a=Qy.findAllMatches,minMatchCharLength:s=Qy.minMatchCharLength,includeMatches:c=Qy.includeMatches,ignoreLocation:l=Qy.ignoreLocation}={}){if(t.length>32)throw new Error((e=>`Pattern length exceeds max of ${e}.`)(32));const u=t.length,f=e.length,d=Math.max(0,Math.min(n,f));let g=o,p=d;const h=(e,t)=>{const r=e/u;if(l)return r;const n=Math.abs(d-t);return i?r+n/i:n?1:r},A=s>1||c,m=A?Array(f):[];let I;for(;(I=e.indexOf(t,p))>-1;){const e=h(0,I);if(g=Math.min(e,g),p=I+u,A){let e=0;for(;e<u;)m[I+e]=1,e+=1}}p=-1;let y=[],v=1,b=0,w=u+f;const B=1<<u-1;for(let t=0;t<u;t+=1){let n=0,i=w;for(;n<i;)h(t,d+i)<=g?n=i:w=i,i=Math.floor((w-n)/2+n);w=i;let o=Math.max(1,d-i+1);const s=a?f:Math.min(d+i,f)+u,c=Array(s+2);c[s+1]=(1<<t)-1;for(let n=s;n>=o;n-=1){const i=n-1,a=r[e[i]];if(c[n]=(c[n+1]<<1|1)&a,t&&(c[n]|=(y[n+1]|y[n])<<1|1|y[n+1]),c[n]&B&&(v=h(t,i),v<=g)){if(g=v,p=i,b=t,p<=d)break;o=Math.max(1,2*d-p)}}if(h(t+1,d)>g)break;y=c}if(A&&p>=0){const t=Math.min(f-1,p+u-1+b);for(let n=p;n<=t;n+=1)r[e[n]]&&(m[n]=1)}const E={isMatch:p>=0,score:Math.max(.001,v)};if(A){const e=function(e=[],t=Qy.minMatchCharLength){const r=[];let n=-1,i=-1,o=0;for(let a=e.length;o<a;o+=1){const a=e[o];a&&-1===n?n=o:a||-1===n||(i=o-1,i-n+1>=t&&r.push([n,i]),n=-1)}return e[o-1]&&o-n>=t&&r.push([n,o-1]),r}(m,s);e.length?c&&(E.indices=e):E.isMatch=!1}return E}function qy(e){const t={};for(let r=0,n=e.length;r<n;r+=1){const i=e.charAt(r);t[i]=(t[i]||0)|1<<n-r-1}return t}function My(e){if(e.length<=1)return e;e.sort((e,t)=>e[0]-t[0]||e[1]-t[1]);const t=[e[0]];for(let r=1,n=e.length;r<n;r+=1){const n=t[t.length-1],i=e[r];i[0]<=n[1]+1?n[1]=Math.max(n[1],i[1]):t.push(i)}return t}const Hy={"ł":"l","Ł":"L","đ":"d","Đ":"D","ø":"o","Ø":"O","ħ":"h","Ħ":"H","ŧ":"t","Ŧ":"T","ı":"i","ß":"ss"},Ly=new RegExp("["+Object.keys(Hy).join("")+"]","g"),Uy="function"==typeof String.prototype.normalize?e=>e.normalize("NFD").replace(/[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0903\u093A-\u093C\u093E-\u094F\u0951-\u0957\u0962\u0963\u0981-\u0983\u09BC\u09BE-\u09C4\u09C7\u09C8\u09CB-\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01-\u0A03\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81-\u0A83\u0ABC\u0ABE-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01-\u0B03\u0B3C\u0B3E-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B62\u0B63\u0B82\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD7\u0C00-\u0C04\u0C3E-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81-\u0C83\u0CBC\u0CBE-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00-\u0D03\u0D3B\u0D3C\u0D3E-\u0D44\u0D46-\u0D48\u0D4A-\u0D4D\u0D57\u0D62\u0D63\u0D82\u0D83\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DF2\u0DF3\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EB9\u0EBB\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F3E\u0F3F\u0F71-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102B-\u103E\u1056-\u1059\u105E-\u1060\u1062-\u1064\u1067-\u106D\u1071-\u1074\u1082-\u108D\u108F\u109A-\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u192B\u1930-\u193B\u1A17-\u1A1B\u1A55-\u1A5E\u1A60-\u1A7C\u1A7F\u1AB0-\u1ABE\u1B00-\u1B04\u1B34-\u1B44\u1B6B-\u1B73\u1B80-\u1B82\u1BA1-\u1BAD\u1BE6-\u1BF3\u1C24-\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE8\u1CED\u1CF2-\u1CF4\u1CF7-\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA823-\uA827\uA880\uA881\uA8B4-\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA953\uA980-\uA983\uA9B3-\uA9C0\uA9E5\uAA29-\uAA36\uAA43\uAA4C\uAA4D\uAA7B-\uAA7D\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEB-\uAAEF\uAAF5\uAAF6\uABE3-\uABEA\uABEC\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F]/g,"").replace(Ly,e=>Hy[e]):e=>e;var Ry=class{constructor(e,{location:t=Qy.location,threshold:r=Qy.threshold,distance:n=Qy.distance,includeMatches:i=Qy.includeMatches,findAllMatches:o=Qy.findAllMatches,minMatchCharLength:a=Qy.minMatchCharLength,isCaseSensitive:s=Qy.isCaseSensitive,ignoreDiacritics:c=Qy.ignoreDiacritics,ignoreLocation:l=Qy.ignoreLocation}={}){if(this.options={location:t,threshold:r,distance:n,includeMatches:i,findAllMatches:o,minMatchCharLength:a,isCaseSensitive:s,ignoreDiacritics:c,ignoreLocation:l},e=s?e:e.toLowerCase(),e=c?Uy(e):e,this.pattern=e,this.chunks=[],!this.pattern.length)return;const u=(e,t)=>{this.chunks.push({pattern:e,alphabet:qy(e),startIndex:t})},f=this.pattern.length;if(f>32){let e=0;const t=f%32,r=f-t;for(;e<r;)u(this.pattern.substr(e,32),e),e+=32;if(t){const e=f-32;u(this.pattern.substr(e),e)}}else u(this.pattern,0)}searchIn(e){const{isCaseSensitive:t,ignoreDiacritics:r,includeMatches:n}=this.options;if(e=t?e:e.toLowerCase(),e=r?Uy(e):e,this.pattern===e){const t={isMatch:!0,score:0};return n&&(t.indices=[[0,e.length-1]]),t}const{location:i,distance:o,threshold:a,findAllMatches:s,minMatchCharLength:c,ignoreLocation:l}=this.options,u=[];let f=0,d=!1;this.chunks.forEach(({pattern:t,alphabet:r,startIndex:g})=>{const{isMatch:p,score:h,indices:A}=Ny(e,t,r,{location:i+g,distance:o,threshold:a,findAllMatches:s,minMatchCharLength:c,includeMatches:n,ignoreLocation:l});p&&(d=!0),f+=h,p&&A&&u.push(...A)});const g={isMatch:d,score:d?f/this.chunks.length:1};return d&&n&&(g.indices=My(u)),g}};const Oy=new Set(["fuzzy","include"]);function Ty(e){return e.startsWith("inverse")}const Yy=[{type:"exact",multiRegex:/^="(.*)"$/,singleRegex:/^=(.*)$/,create:e=>({type:"exact",search(t){const r=t===e;return{isMatch:r,score:r?0:1,indices:[0,e.length-1]}}})},{type:"include",multiRegex:/^'"(.*)"$/,singleRegex:/^'(.*)$/,create:e=>({type:"include",search(t){let r,n=0;const i=[],o=e.length;for(;(r=t.indexOf(e,n))>-1;)n=r+o,i.push([r,n-1]);const a=!!i.length;return{isMatch:a,score:a?0:1,indices:i}}})},{type:"prefix-exact",multiRegex:/^\^"(.*)"$/,singleRegex:/^\^(.*)$/,create:e=>({type:"prefix-exact",search(t){const r=t.startsWith(e);return{isMatch:r,score:r?0:1,indices:[0,e.length-1]}}})},{type:"inverse-prefix-exact",multiRegex:/^!\^"(.*)"$/,singleRegex:/^!\^(.*)$/,create:e=>({type:"inverse-prefix-exact",search(t){const r=!t.startsWith(e);return{isMatch:r,score:r?0:1,indices:[0,t.length-1]}}})},{type:"inverse-suffix-exact",multiRegex:/^!"(.*)"\$$/,singleRegex:/^!(.*)\$$/,create:e=>({type:"inverse-suffix-exact",search(t){const r=!t.endsWith(e);return{isMatch:r,score:r?0:1,indices:[0,t.length-1]}}})},{type:"suffix-exact",multiRegex:/^"(.*)"\$$/,singleRegex:/^(.*)\$$/,create:e=>({type:"suffix-exact",search(t){const r=t.endsWith(e);return{isMatch:r,score:r?0:1,indices:[t.length-e.length,t.length-1]}}})},{type:"inverse-exact",multiRegex:/^!"(.*)"$/,singleRegex:/^!(.*)$/,create:e=>({type:"inverse-exact",search(t){const r=-1===t.indexOf(e);return{isMatch:r,score:r?0:1,indices:[0,t.length-1]}}})},{type:"fuzzy",multiRegex:/^"(.*)"$/,singleRegex:/^(.*)$/,create:(e,t={})=>{const r=new Ry(e,{location:t.location??Qy.location,threshold:t.threshold??Qy.threshold,distance:t.distance??Qy.distance,includeMatches:t.includeMatches??Qy.includeMatches,findAllMatches:t.findAllMatches??Qy.findAllMatches,minMatchCharLength:t.minMatchCharLength??Qy.minMatchCharLength,isCaseSensitive:t.isCaseSensitive??Qy.isCaseSensitive,ignoreDiacritics:t.ignoreDiacritics??Qy.ignoreDiacritics,ignoreLocation:t.ignoreLocation??Qy.ignoreLocation});return{type:"fuzzy",search:e=>r.searchIn(e)}}}],jy=Yy.length;function Gy(e,t){const r=e.match(t);return r?r[1]:null}const Jy=[];function zy(...e){Jy.push(...e)}function Vy(e,t){for(let r=0,n=Jy.length;r<n;r+=1){const n=Jy[r];if(n.condition(e,t))return new n(e,t)}return new Ry(e,t)}const Py="$and",Xy="$or",_y="$path",Wy="$val",Ky=e=>!(!e[Py]&&!e[Xy]),$y=e=>({[Py]:Object.keys(e).map(t=>({[t]:e[t]}))});function Zy(e,t,{auto:r=!0}={}){const n=e=>{if(hy(e)){const n={keyId:null,pattern:e};return r&&(n.searcher=Vy(e,t)),n}const i=Object.keys(e),o=(e=>!!e[_y])(e);if(!o&&i.length>1&&!Ky(e))return n($y(e));if((e=>!gy(e)&&Iy(e)&&!Ky(e))(e)){const n=o?e[_y]:i[0],a=o?e[Wy]:e[n];if(!hy(a))throw new Error((e=>`Invalid value for key ${e}`)(n));const s={keyId:Dy(n),pattern:a};return r&&(s.searcher=Vy(a,t)),s}const a={children:[],operator:i[0]};return i.forEach(t=>{const r=e[t];gy(r)&&r.forEach(e=>{a.children.push(n(e))})}),a};return Ky(e)||(e=$y(e)),n(e)}function ev(e,{ignoreFieldNorm:t=Qy.ignoreFieldNorm}){let r=1;return e.forEach(({key:e,norm:n,score:i})=>{const o=e?e.weight:null;r*=Math.pow(0===i&&o?Number.EPSILON:i,(o||1)*(t?1:n))}),r}var tv=class{constructor(e){this.limit=e,this.heap=[]}get size(){return this.heap.length}shouldInsert(e){return this.size<this.limit||e<this.heap[0].score}insert(e){this.size<this.limit?(this.heap.push(e),this._bubbleUp(this.size-1)):e.score<this.heap[0].score&&(this.heap[0]=e,this._sinkDown(0))}extractSorted(e){return this.heap.sort(e)}_bubbleUp(e){const t=this.heap;for(;e>0;){const r=e-1>>1;if(t[e].score<=t[r].score)break;const n=t[e];t[e]=t[r],t[r]=n,e=r}}_sinkDown(e){const t=this.heap,r=t.length;let n=e;do{const i=2*(e=n)+1,o=2*e+2;if(i<r&&t[i].score>t[n].score&&(n=i),o<r&&t[o].score>t[n].score&&(n=o),n!==e){const r=t[e];t[e]=t[n],t[n]=r}}while(n!==e)}};function rv(e,t,{includeMatches:r=Qy.includeMatches,includeScore:n=Qy.includeScore}={}){return e.map(e=>{const{idx:i}=e,o={item:t[i],refIndex:i};return r&&(o.matches=function(e){const t=[];return e.matches.forEach(e=>{if(!yy(e.indices)||!e.indices.length)return;const r={indices:e.indices,value:e.value};e.key&&(r.key=e.key.id),e.idx>-1&&(r.refIndex=e.idx),t.push(r)}),t}(e)),n&&(o.score=e.score),o})}const nv=/[\p{L}\p{M}\p{N}_]+/gu,iv=new WeakSet;function ov(e){if("function"==typeof e){let t=!1;return r=>{const n=e(r);if(!t&&(t=!0,!Array.isArray(n)||n.some(e=>"string"!=typeof e)))throw new Error(`[Fuse] tokenize function must return string[]; received ${Array.isArray(n)?"array containing non-strings":typeof n}.`);return n}}return e instanceof RegExp?(e.global||function(e){iv.has(e)||(iv.add(e),console.warn(`[Fuse] tokenize regex ${e} lacks the global flag; only the first match per text will be returned. Add the 'g' flag.`))}(e),t=>t.match(e)||[]):e=>e.match(nv)||[]}function av({isCaseSensitive:e=!1,ignoreDiacritics:t=!1,tokenize:r}={}){const n=ov(r);return{tokenize:r=>(e||(r=r.toLowerCase()),t&&(r=Uy(r)),n(r))}}function sv(e,t,r,n){const i=n.tokenize(t);if(!i.length)return;e.fieldCount++,e.docFieldCount.set(r,(e.docFieldCount.get(r)||0)+1);const o=new Set(i);let a=e.docTermFieldHits.get(r);a||(a=new Map,e.docTermFieldHits.set(r,a));for(const t of o)a.set(t,(a.get(t)||0)+1),e.df.set(t,(e.df.get(t)||0)+1)}function cv(e,t,r,n){const{i:i,v:o,$:a}=t;if(void 0===o){if(a)for(let t=0;t<r;t++){const r=a[t];if(r)if(Array.isArray(r))for(const t of r)sv(e,t.v,i,n);else sv(e,r.v,i,n)}}else sv(e,o,i,n)}function lv(e,t){const r=e.docFieldCount.get(t);if(void 0===r)return;e.fieldCount-=r,e.docFieldCount.delete(t);const n=e.docTermFieldHits.get(t);if(n){for(const[t,r]of n){const n=(e.df.get(t)||0)-r;n<=0?e.df.delete(t):e.df.set(t,n)}e.docTermFieldHits.delete(t)}}function uv(e,t){if(0===t.length)return;const r=Array.from(new Set(t)).sort((e,t)=>e-t);for(const t of r)lv(e,t);const n=e=>{let t=0,n=r.length;for(;t<n;){const i=t+n>>>1;r[i]<e?t=i+1:n=i}return e-t},i=r[0],o=new Map;for(const[t,r]of e.docFieldCount)o.set(t>i?n(t):t,r);e.docFieldCount=o;const a=new Map;for(const[t,r]of e.docTermFieldHits)a.set(t>i?n(t):t,r);e.docTermFieldHits=a}var fv=class{constructor(e,t,r){this.options={...Qy,...t},this.options.useExtendedSearch,this.options.useTokenSearch,this._keyStore=new Ey(this.options.keys),this._docs=e,this._myIndex=null,this._invertedIndex=null,this.setCollection(e,r),this._lastQuery=null,this._lastSearcher=null}_getSearcher(e){if(this._lastQuery===e)return this._lastSearcher;const t=Vy(e,this._invertedIndex?{...this.options,_invertedIndex:this._invertedIndex}:this.options);return this._lastQuery=e,this._lastSearcher=t,t}setCollection(e,t){if(this._docs=e,t&&!(t instanceof Sy))throw new Error("Incorrect 'index' type");if(this._myIndex=t||ky(this.options.keys,this._docs,{getFn:this.options.getFn,fieldNormWeight:this.options.fieldNormWeight}),this.options.useTokenSearch){const e=av({isCaseSensitive:this.options.isCaseSensitive,ignoreDiacritics:this.options.ignoreDiacritics,tokenize:this.options.tokenize});this._invertedIndex=function(e,t,r){const n={fieldCount:0,df:new Map,docFieldCount:new Map,docTermFieldHits:new Map};for(const i of e)cv(n,i,t,r);return n}(this._myIndex.records,this._myIndex.keys.length,e)}this._invalidateSearcherCache()}add(e){if(!yy(e))return;this._docs.push(e);const t=this._myIndex.add(e,this._docs.length-1);if(this._invertedIndex&&t){const e=av({isCaseSensitive:this.options.isCaseSensitive,ignoreDiacritics:this.options.ignoreDiacritics,tokenize:this.options.tokenize});!function(e,t,r,n){cv(e,t,r,n)}(this._invertedIndex,t,this._myIndex.keys.length,e)}this._invalidateSearcherCache()}remove(e=()=>!1){const t=[],r=[];for(let n=0,i=this._docs.length;n<i;n+=1)e(this._docs[n],n)&&(t.push(this._docs[n]),r.push(n));if(r.length){this._invertedIndex&&uv(this._invertedIndex,r);const e=new Set(r);this._docs=this._docs.filter((t,r)=>!e.has(r)),this._myIndex.removeAll(r),this._invalidateSearcherCache()}return t}removeAt(e){if(!Number.isInteger(e)||e<0||e>=this._docs.length)throw new Error(wy);this._invertedIndex&&uv(this._invertedIndex,[e]);const t=this._docs.splice(e,1)[0];return this._myIndex.removeAt(e),this._invalidateSearcherCache(),t}_invalidateSearcherCache(){this._lastQuery=null,this._lastSearcher=null}getIndex(){return this._myIndex}search(e,t){const{limit:r=-1}=t||{},{includeMatches:n,includeScore:i,shouldSort:o,sortFn:a,ignoreFieldNorm:s}=this.options;if(hy(e)&&!e.trim()){let e=this._docs.map((e,t)=>({item:e,refIndex:t}));return Ay(r)&&r>-1&&(e=e.slice(0,r)),e}let c;if(Ay(r)&&r>0&&hy(e)){const t=new tv(r);hy(this._docs[0])?this._searchStringList(e,{heap:t,ignoreFieldNorm:s}):this._searchObjectList(e,{heap:t,ignoreFieldNorm:s}),c=t.extractSorted(a)}else c=hy(e)?hy(this._docs[0])?this._searchStringList(e):this._searchObjectList(e):this._searchLogical(e),function(e,{ignoreFieldNorm:t=Qy.ignoreFieldNorm}){e.forEach(e=>{e.score=ev(e.matches,{ignoreFieldNorm:t})})}(c,{ignoreFieldNorm:s}),o&&c.sort(a),Ay(r)&&r>-1&&(c=c.slice(0,r));return rv(c,this._docs,{includeMatches:n,includeScore:i})}_searchStringList(e,{heap:t,ignoreFieldNorm:r}={}){const n=this._getSearcher(e),i=this.options.useTokenSearch&&"all"===this.options.tokenMatch,{records:o}=this._myIndex,a=t?null:[];return o.forEach(({v:e,i:o,n:s})=>{if(!yy(e))return;const c=n.searchIn(e);if(c.isMatch){const n={score:c.score,value:e,norm:s,indices:c.indices};i&&(n.matchedMask=c.matchedMask,n.matchedTerms=c.matchedTerms,n.termCount=c.termCount);const l=[n];if(!i||this._coversAllTokens(l)){const n={item:e,idx:o,matches:l};t?(n.score=ev(n.matches,{ignoreFieldNorm:r}),t.shouldInsert(n.score)&&t.insert(n)):a.push(n)}}}),a}_searchLogical(e){const t=Zy(e,this.options),r=(e,t,n)=>{if(!("children"in e)){const{keyId:r,searcher:i}=e;let o;return null===r?(o=[],this._myIndex.keys.forEach((e,r)=>{o.push(...this._findMatches({key:e,value:t[r],searcher:i}))})):o=this._findMatches({key:this._keyStore.get(r),value:this._myIndex.getValueForItemAtKeyId(t,r),searcher:i}),o&&o.length?[{idx:n,item:t,matches:o}]:[]}const{children:i,operator:o}=e,a=[];for(let e=0,s=i.length;e<s;e+=1){const s=i[e],c=r(s,t,n);if(c.length)a.push(...c);else if(o===Py)return[]}return a},n=this._myIndex.records,i=new Map,o=[];return n.forEach(({$:e,i:n})=>{if(yy(e)){const a=r(t,e,n);a.length&&(i.has(n)||(i.set(n,{idx:n,item:e,matches:[]}),o.push(i.get(n))),a.forEach(({matches:e})=>{i.get(n).matches.push(...e)}))}}),o}_searchObjectList(e,{heap:t,ignoreFieldNorm:r}={}){const n=this._getSearcher(e),i=this.options.useTokenSearch&&"all"===this.options.tokenMatch,{keys:o,records:a}=this._myIndex,s=t?null:[];return a.forEach(({$:e,i:a})=>{if(!yy(e))return;const c=[];let l=!1,u=!1;if(o.forEach((t,r)=>{const i=this._findMatches({key:t,value:e[r],searcher:n});i.length?(c.push(...i),i[0].hasInverse&&(u=!0)):l=!0}),(!u||!l)&&c.length&&(!i||this._coversAllTokens(c))){const n={idx:a,item:e,matches:c};t?(n.score=ev(n.matches,{ignoreFieldNorm:r}),t.shouldInsert(n.score)&&t.insert(n)):s.push(n)}}),s}_findMatches({key:e,value:t,searcher:r}){if(!yy(t))return[];const n=[];if(gy(t))t.forEach(({v:t,i:i,n:o})=>{if(!yy(t))return;const a=r.searchIn(t);if(a.isMatch){const r={score:a.score,key:e,value:t,idx:i,norm:o,indices:a.indices,hasInverse:a.hasInverse};void 0!==a.termCount&&(r.matchedMask=a.matchedMask,r.matchedTerms=a.matchedTerms,r.termCount=a.termCount),n.push(r)}});else{const{v:i,n:o}=t,a=r.searchIn(i);if(a.isMatch){const t={score:a.score,key:e,value:i,norm:o,indices:a.indices,hasInverse:a.hasInverse};void 0!==a.termCount&&(t.matchedMask=a.matchedMask,t.matchedTerms=a.matchedTerms,t.termCount=a.termCount),n.push(t)}}return n}_coversAllTokens(e){const t=e.length?e[0].termCount:void 0;if(void 0===t)return!0;if(t<=31){let r=0;for(let t=0;t<e.length;t++)r|=e[t].matchedMask||0;return r===2**t-1}const r=new Set;for(let t=0;t<e.length;t++){const n=e[t].matchedTerms;if(n)for(const e of n)r.add(e)}return r.size===t}};fv.version="7.4.2",fv.createIndex=ky,fv.parseIndex=function(e,{getFn:t=Qy.getFn,fieldNormWeight:r=Qy.fieldNormWeight}={}){const{keys:n,records:i}=e,o=new Sy({getFn:t,fieldNormWeight:r});return o.setKeys(n),o.setIndexRecords(i),o},fv.config=Qy,fv.match=function(e,t,r){if(r&&r.useTokenSearch)throw new Error("Fuse.match does not support useTokenSearch: token search requires corpus-level statistics (df, fieldCount) that a one-off string comparison does not have. Use new Fuse(...).search(...) instead.");return Vy(e,{...Qy,...r}).searchIn(t)},fv.parseQuery=Zy,zy(class{constructor(e,{isCaseSensitive:t=Qy.isCaseSensitive,ignoreDiacritics:r=Qy.ignoreDiacritics,includeMatches:n=Qy.includeMatches,minMatchCharLength:i=Qy.minMatchCharLength,ignoreLocation:o=Qy.ignoreLocation,findAllMatches:a=Qy.findAllMatches,location:s=Qy.location,threshold:c=Qy.threshold,distance:l=Qy.distance}={}){this.query=null,this.options={isCaseSensitive:t,ignoreDiacritics:r,includeMatches:n,minMatchCharLength:i,findAllMatches:a,ignoreLocation:o,location:s,threshold:c,distance:l},e=t?e:e.toLowerCase(),e=r?Uy(e):e,this.pattern=e,this.query=function(e,t={}){return e.replace(/\\\|/g,"\0").split("|").map(e=>{const r=function(e){const t=[],r=e.length;let n=0;for(;n<r;){for(;n<r&&" "===e[n];)n++;if(n>=r)break;let i=n;for(;i<r&&" "!==e[i]&&'"'!==e[i];)i++;if(i<r&&'"'===e[i]){for(i++;i<r;){if('"'===e[i]){const t=i+1;if(t>=r||" "===e[t]){i++;break}if("$"===e[t]&&(t+1>=r||" "===e[t+1])){i+=2;break}}i++}t.push(e.substring(n,i)),n=i}else{for(;i<r&&" "!==e[i];)i++;t.push(e.substring(n,i)),n=i}}return t}(e.replace(/\u0000/g,"|").trim()).filter(e=>e&&!!e.trim()),n=[];for(let e=0,i=r.length;e<i;e+=1){const i=r[e];let o=!1,a=-1;for(;!o&&++a<jy;){const e=Yy[a],r=Gy(i,e.multiRegex);r&&(n.push(e.create(r,t)),o=!0)}if(!o)for(a=-1;++a<jy;){const e=Yy[a],r=Gy(i,e.singleRegex);if(r){n.push(e.create(r,t));break}}}return n})}(this.pattern,this.options)}static condition(e,t){return t.useExtendedSearch}searchIn(e){const t=this.query;if(!t)return{isMatch:!1,score:1};const{includeMatches:r,isCaseSensitive:n,ignoreDiacritics:i}=this.options;e=n?e:e.toLowerCase(),e=i?Uy(e):e;let o=0;const a=[];let s=0,c=!1;for(let n=0,i=t.length;n<i;n+=1){const i=t[n];a.length=0,o=0,c=!1;for(let t=0,n=i.length;t<n;t+=1){const n=i[t],{isMatch:l,indices:u,score:f}=n.search(e);if(!l){s=0,o=0,a.length=0,c=!1;break}o+=1,s+=f,Ty(n.type)&&(c=!0),r&&(Oy.has(n.type)?a.push(...u):a.push(u))}if(o){const e={isMatch:!0,score:s/o};return c&&(e.hasInverse=!0),r&&(e.indices=My(a)),e}}return{isMatch:!1,score:1}}}),zy(class{static condition(e,t){return t.useTokenSearch}constructor(e,t){this.options=t,this.analyzer=av({isCaseSensitive:t.isCaseSensitive,ignoreDiacritics:t.ignoreDiacritics,tokenize:t.tokenize});const r=this.analyzer.tokenize(e),{df:n,fieldCount:i}=t._invertedIndex;this.termSearchers=[],this.idfWeights=[];for(const e of r){this.termSearchers.push(new Ry(e,{location:t.location,threshold:t.threshold,distance:t.distance,includeMatches:t.includeMatches,findAllMatches:t.findAllMatches,minMatchCharLength:t.minMatchCharLength,isCaseSensitive:t.isCaseSensitive,ignoreDiacritics:t.ignoreDiacritics,ignoreLocation:!0}));const r=n.get(e)||0,o=Math.log(1+(i-r+.5)/(r+.5));this.idfWeights.push(o)}this.combineAll="all"===t.tokenMatch,this.numTerms=this.termSearchers.length,this.useMask=this.numTerms<=31}searchIn(e){if(!this.termSearchers.length)return{isMatch:!1,score:1};const t=[];let r=0,n=0,i=0,o=0;const a=this.combineAll&&!this.useMask?new Set:null;for(let s=0;s<this.termSearchers.length;s++){const c=this.termSearchers[s].searchIn(e),l=this.idfWeights[s];n+=l,c.isMatch&&(i++,r+=l*(1-c.score),c.indices&&t.push(...c.indices),this.combineAll&&(this.useMask?o|=1<<s:a.add(s)))}if(0===i)return{isMatch:!1,score:1};const s=n>0?1-r/n:0,c={isMatch:!0,score:Math.max(.001,s)};return this.options.includeMatches&&t.length&&(c.indices=My(t)),this.combineAll&&(this.useMask?c.matchedMask=o:c.matchedTerms=a,c.termCount=this.numTerms),c}}),fv.use=function(...e){e.forEach(e=>zy(e))};var dv=fv;function gv(e){return function(e,t){var r=null==e?0:e.length;return r?Ea(e,t)/r:NaN}(e,cr)}function pv(e){if(!Ee(e))return{};let{results:t,binarys:r}=e;if(!De(t))return{};if(!Ce(r))return{};let n={};try{n=JSON.parse(t,function(e,t){if(De(t)){if(t.indexOf("[Uint8Array]::")>=0){let e=Zi(t.replace("[Uint8Array]::",""));return r[e]}if(t.indexOf("[Uint16Array]::")>=0){let e=Zi(t.replace("[Uint16Array]::",""));return r[e]}if(t.indexOf("[ArrayBuffer]::")>=0){let e=Zi(t.replace("[ArrayBuffer]::",""));return r[e]}}return t})}catch(e){}return n}function hv(e,t=null){if(!va(r))throw new Error("invalid dayjs");if(!EI(e))return{today:null,msg:"",err:"時間格式錯誤"};let n=r();EI(t)&&(n=r(t,"YYYY-MM-DDTHH:mm:ss.SSSZ"));let i=r(e,"YYYY-MM-DDTHH:mm:ss.SSSZ");if(n>i)return{today:null,msg:"",err:"時間已過"};let o,a=n.format("YYYY-MM-DD"),s=i.format("YYYY-MM-DD"),c=r(a,"YYYY-MM-DD"),l=r(s,"YYYY-MM-DD"),u=i.diff(n,"seconds"),f=i.diff(n,"minutes"),d=i.diff(n,"hours"),g=l.diff(c,"days"),p=l.diff(c,"weeks"),h=l.diff(c,"months"),A=l.diff(c,"years"),m="即將到來";if(u>=0&&(o=!0,m=u+"秒後"),f>0&&(o=!0,m=f+"分鐘後"),d>0){let e=i.format("HH:mm");a===s?(o=!0,m=d+"小時後,今天"+e):(o=!1,m=d+"小時後,明天"+e)}return g>1&&(o=!1,m=2===g?"後天":g+"天後"),p>0&&(o=!1,m=p+"周後"),h>0&&(o=!1,m=h+"個月後"),A>0&&(o=!1,m=A+"年後"),{today:o,msg:m,err:""}}function Av(e,t=null){if(!va(r))throw new Error("invalid dayjs");if(!EI(e))return{today:null,msg:"",err:"時間格式錯誤"};let n=r();EI(t)&&(n=r(t,"YYYY-MM-DDTHH:mm:ss.SSSZ"));let i=r(e,"YYYY-MM-DDTHH:mm:ss.SSSZ");if(n<i)return{today:null,msg:"",err:"時間未到"};let o=n.format("YYYY-MM-DD"),a=i.format("YYYY-MM-DD"),s=r(o,"YYYY-MM-DD"),c=r(a,"YYYY-MM-DD"),l=n.diff(i,"seconds"),u=n.diff(i,"minutes"),f=n.diff(i,"hours"),d=s.diff(c,"days"),g=s.diff(c,"weeks"),p=s.diff(c,"months"),h=s.diff(c,"years"),A=!1,m="剛剛";if(l>=0&&(A=!0,m=l+"秒前"),u>0&&(A=!0,m=u+"分鐘前"),f>0){let e=i.format("HH:mm");o===a?(A=!0,m=f+"小時前"):(A=!1,m="昨天"+e)}return d>1&&(A=!1,m=d+"天前"),g>0&&(A=!1,m=g+"周前"),p>0&&(A=!1,m=p+"個月前"),h>0&&(A=!1,m=h+"年前"),{today:A,msg:m,err:""}}function mv(e){let t=BI.sepTZ(e);return e=`${t.t}.000${t.tz}`}function Iv(e){let t=BI.sepTZ(e);return e=`${t.t}.000${t.tz}`}function yv(e){if(!Za(e))return"";let t;try{t=Wa(LI(e))}catch(e){return""}return t}e.ab2blob=function(e){let t=y(e);return new Blob([t])},e.ab2u8arr=y,e.addExcelWorksheetFromData=function(e,t,r="data"){if(!Ee(e))return{error:"wb is not an effective object"};if(!Ce(we(e,"SheetNames")))return{error:"wb.SheetNames is not an array"};if(!Be(we(e,"Sheets")))return{error:"wb.Sheets is not an object"};let n=bn(t);return ke(n,"error")?n:(e.SheetNames.push(r),e.Sheets[r]=n,e)},e.addMonth=function(e,t){return wn(e)&&Hn(t)?r(e,"YYYY-MM").add(t,"months").format("YYYY-MM"):""},e.aes2str=li,e.alive=function(e={}){let t=Xi(),r={},n=null,i=we(e,"timeAlive");eo(i)||(i=1e4),i=Zi(i);let o=we(e,"timeDetect");return eo(o)||(o=50),o=Zi(o),t.trigger=function(e,a){De(e)?(ke(r,e)||setTimeout(()=>{t.emit("message",{eventName:"enter",key:e,data:a,now:dn(r)})},1),r[e]={data:a,time:Date.now()},null===n&&(n=setInterval(()=>{Er(r,(e,n)=>{if(Date.now()-e.time>i){let e=zi(r[n]);delete r[n],t.emit("message",{eventName:"leave",key:n,data:e.data,now:dn(r)})}}),Ee(r)||(clearInterval(n),n=null)},o))):console.log("trigger need key")},t.get=function(){let e=[];return Er(r,(t,r)=>{e.push({key:r,data:t.data})}),e=zi(e),e},t},e.arr2dt=function(e,t=""){if(!Rr(e))return{};if(Rr(t))return dn(e)===dn(t)?to(e,t):{};let r=[];for(let n=0;n<dn(e);n++)r.push(zi(t));return to(e,r)},e.arrAccum=function(e){if(!Rr(e))return[];let t=[],r=0;return Er(e,function(e){r+=Mn(e),Se(e)?t.push(r):t.push("")}),t},e.arrAdd=function(){if(dn(arguments)<2)return[];let e=arguments[0];for(let t=1;t<dn(arguments);t++){e=ro(e,arguments[t])}return e},e.arrAt=Eo,e.arrDiff=aa,e.arrFilterByKeywords=function(e,t){if(!Rr(e))return[];if(!De(t)&&!Rr(t))return[];let r=null;r=De(t)?la(t," "):t;let n=dn(r);return xr(e,e=>function(e){let t=!1,i=0;for(let o=0;o<n;o++){let a=r[o],s=a,c="+"===ua(a,1),l="-"===ua(a,1);if((c||l)&&(s=da(a,1)),""===sa(s))continue;let u=e.indexOf(s)>=0;if(c){if(u){t=!0,i=1;break}t=!1,i=0;break}if(l){if(u){t=!1,i=0;break}t=!0,i=1;break}if(u){t=!0;let e=1-o/n;e=e**2,i+=e}}return{hasKeyword:t,weight:i}}(e))},e.arrFilterByNum=function(e){return Rr(e)?e=xr(e=pa(e=zi(e),Se),Mn):[]},e.arrFilterByPnum=Aa,e.arrFilterByPnumAndToLog=function(e){return Rr(e)?e=xr(e=Aa(e),Math.log):[]},e.arrFind=function(e,t){function r(e){return Ce(e)?e:[e]}return Ur(e)||0===(e=r(e)).length||Ur(t)?[]:xr(t=r(t),function(t){let r=-1;for(let n=0;n<e.length;n++)if(ma(e[n],t)){r=n;break}return r})},e.arrGroupByMaxmin=function(e,t,r={}){let n=we(r,"keyMax");De(n)||(n="max");let i=we(r,"keyMin");De(i)||(i="min");let o=we(r,"keyValue");De(o)||(o="value");let a=we(r,"keyItems");if(De(a)||(a="items"),!Rr(e))return[];if(!Rr(t))return[];let s=zi(t);return Er(e,(e,r)=>{let c=we(e,o);Se(c)?c=Mn(c):Se(e)&&(c=Mn(e)),Ia(c)&&Er(t,(t,r)=>{let o=we(t,n,null),l=we(t,i,null);if(null!==o&&null!==l&&Se(o)&&Se(l)){let n=we(t,"maxType");"<="!==n&&"<"!==n&&(n="<=");let i,u,f=we(t,"minType");">="!==f&&">"!==f&&(f=">="),o=Mn(o),l=Mn(l),i=">="===f?c>=l:c>l,u="<="===n?c<=o:c<o,i&&u&&(ke(s[r],a)||(s[r][a]=[]),s[r][a].push(e))}})}),s},e.arrHas=ya,e.arrInsert=function(e,t,r){if(!Ce(e))return[];if(Ce(r)||(r=[r]),!Bo(t))return e;if((t=Zi(t))>dn(e))return e;let n=e;try{n=[...e.slice(0,t),...r,...e.slice(t)]}catch(e){}return n},e.arrLookupByMaxmin=function(e,t,r={}){let n=we(r,"keyMax");De(n)||(n="max");let i=we(r,"keyMin");De(i)||(i="min");let o=we(r,"keyValue");De(o)||(o="value");let a=we(r,"keyItems");De(a)||(a="items");let s=we(r,"beforeAddResult",null);if(!Rr(e))return[];if(!Rr(t))return[];if(!Ee(we(e,0)))return[];let c=zi(e);return Er(c,(e,r)=>{let l=we(e,o);Se(l)&&(l=Mn(l)),Ia(l)&&Er(t,(e,t)=>{let o=we(e,n,null),u=we(e,i,null);if(null!==o&&null!==u&&Se(o)&&Se(u)){let t=we(e,"maxType");"<="!==t&&"<"!==t&&(t="<=");let n,i,f=we(e,"minType");">="!==f&&">"!==f&&(f=">="),o=Mn(o),u=Mn(u),n=">="===f?l>=u:l>u,i="<="===t?l<=o:l<o,n&&i&&(va(s)&&(e=s(e,c[r],r)),ke(c[r],a)||(c[r][a]=[]),c[r][a].push(e))}})}),c},e.arrMax=function(e,t={}){if(!Rr(e))return null;let r=we(t,"returnIndex");pn(r)||(r=!1);let n=we(t,"compareKey",null),i=e;De(n)&&(i=xr(e,(e,t)=>we(e,n,"")));let o=null,a=ba(i,(e,t)=>Se(t)?(t=Mn(t),null===e?(o=t,t):(e=Math.max(e,t),o=e,e)):e,{returnIndex:!0});if(r)return a;let s=null;return a>=0&&(s=De(n)?e[a]:o),s},e.arrMin=function(e,t={}){if(!Rr(e))return null;let r=we(t,"returnIndex");pn(r)||(r=!1);let n=we(t,"compareKey",null),i=e;De(n)&&(i=xr(e,(e,t)=>we(e,n,"")));let o=null,a=ba(i,(e,t)=>Se(t)?(t=Mn(t),null===e?(o=t,t):(e=Math.min(e,t),o=e,e)):e,{returnIndex:!0});if(r)return a;let s=null;return a>=0&&(s=De(n)?e[a]:o),s},e.arrMulti=Ba,e.arrNorm=function(e){if(!Rr(e))return null;let t=Ca(e,e);return Se(t)?t<=0?null:Math.sqrt(t):null},e.arrProduct=Ca,e.arrPull=function(e,t){if(!Rr(e))return[];if((Be(t)||Se(t)||xe(t)||pn(t))&&(t=[t]),!Rr(t))return e;let r=zi(e);return Fa(r,t),r},e.arrPullAt=function(e,t){if(!Rr(e))return[];if(Bo(t)&&(t=[t]),!Rr(t))return e;t=xr(t,e=>Zi(e));let r=zi(e);return Ma(r,t),r},e.arrReduce=ba,e.arrReverse=function(e){if(!Rr(e))return[];let t=zi(e);return La(t),t},e.arrSep=function(e,t){if(!Rr(e))return[];if(!eo(t)&&!Ee(t))return[];let r="",n=null;if(eo(t))n=t,r="numCount";else if(Ee(t))if(eo(we(t,"numCount")))n=t.numCount,r="numCount";else{if(!eo(we(t,"numGroup")))throw new Error("invalid opt.numCount or opt.numGroup");n=t.numGroup,r="numGroup"}let i=dn(e),o=[];if("numCount"===r)for(let t=0;t<i;t+=n){let r=[];for(let o=0;o<n;o++){let n=t+o;n<i&&r.push(e[n])}o.push(r)}else if("numGroup"===r){for(let e=0;e<n;e++)o[e]=[];let t=-1;for(let r=0;r<i;r++)t++,t>n-1&&(t=0),o[t].push(e[r])}return o},e.arrSort=_a,e.asind=function(e){return Se(e)?(e=Mn(e),180*Math.asin(e)/Math.PI):null},e.atan2d=function(e,t){return Se(e)?(e=Mn(e),Se(t)?(t=Mn(t),180*Math.atan2(t,e)/Math.PI):null):null},e.atand=function(e){return Se(e)?(e=Mn(e),180*Math.atan(e)/Math.PI):null},e.attstr=function(e={}){let t=";",r="@",n="table",i="id",o=we(e,"uniqItems");pn(o)||(o=!1);let a=we(e,"dlmItem","");De(a)&&(t=a);let s=we(e,"dlmSep","");De(s)&&(r=s);let c=we(e,"keyTable","");De(c)&&(n=c);let l=we(e,"keyId","");De(l)&&(i=l);let u=we(e,"mode");function f(e){if(!De(e))return[];let r=Jo(e,t);return o&&(r=Pr(r)),r}function d(e){if(!Rr(e))return"";return o&&(e=Pr(e)),xo(e,t)}function g(e){return e=pa(e,De),o&&(e=Pr(e)),d(e)}function p(e){let t=[];return Er(e,e=>{let o=we(e,n,""),a=we(e,i,"");if(De(o),xe(a)||(Ce(a)?dn(a):a=""),xe(a))t.push(`${o}${r}${a}`);else if(Ce(a)){let e=xo(a,r);t.push(`${o}${r}${e}`)}}),e=d(t)}function h(e){if(!De(e))return[];return pa(f(e),De)}function A(e){if(!De(e))return[];let t=f(e),o=[];return Er(t,e=>{let t=Jo(e,r),a=we(t,0,""),s=we(t,1,"");dn(t)>=3&&(t=ja(t),s=t),o.push({item:e,[n]:a,[i]:s})}),o}function m(e,t){let r=[...h(e),...h(t)];return 0===dn(r)?"":g(r)}function I(e,t){let r=[...A(e),...A(t)];return 0===dn(r)?"":p(r)}function y(e,t){let r=h(e),n=h(t),i=[];return Er(r,e=>{ya(e,n)||i.push(e)}),0===dn(i)?"":g(i)}function v(e,t){let r=A(e),n=A(t),i=[];return Er(r,e=>{ya(e,n)||i.push(e)}),0===dn(i)?"":p(i)}"1p"!==u&&"2p"!==u&&(u="auto");let b={parse:function(e,t={}){if(!De(e))return[];let n=we(t,"mode");return"1p"!==n&&"2p"!==n&&(n=u),"1p"===n?h(e):"2p"===n||e.indexOf(r)>=0?A(e):h(e)},join:function(e,t={}){if(!Rr(e))return"";let r=we(t,"mode");if("1p"!==r&&"2p"!==r&&(r=u),"1p"===r)return g(e);if("2p"===r)return p(e);let o=we(e,0);return ke(o,n)&&ke(o,i)?p(e):g(e)},remove:function(e,t,n={}){if(!De(e))return"";if(!De(t))return e;let i=we(n,"mode");return"1p"!==i&&"2p"!==i&&(i=u),"1p"===i?y(e,t):"2p"===i||t.indexOf(r)>=0?v(e,t):y(e,t)},add:function(e,t,n={}){let i=we(n,"mode");if("1p"!==i&&"2p"!==i&&(i=u),"1p"===i)return m(e,t);if("2p"===i)return I(e,t);let o=e.indexOf(r)>=0,a=t.indexOf(r)>=0;return o||a?I(e,t):m(e,t)}};return b},e.b642obj=function(e){if(!xe(e))return{};let t={};try{t=Ka(Wa(e))}catch(e){t={}}return t},e.b642str=Wa,e.b642u16arr=ts,e.b642u8arr=$a,e.binstr=rs,e.blob2ab=is,e.blob2b64=os,e.blob2str=function(e){let t=ns(),r=new FileReader;return r.onload=function(){t.resolve(r.result)},r.onerror=function(e){t.reject(e)},r.readAsText(e),t},e.blob2u8arr=as,e.blobs2b64s=ss,e.blobs2u8arrs=cs,e.bodyLog=function(){let e=`\n <div style="padding:5px; font-size:10pt; font-family:Microsoft JhengHei, Helvetica;">\n <span style="color:#f26;">log: </span>\n <code>${fs(xr(arguments,function(e){return hn(e)}).join(", "))}</code>\n </div>\n `;document.querySelector("body").insertAdjacentHTML("beforeend",e)},e.browserView=ds,e.browserViewFromBlob=function(e,t){gs(e)&&ds(e,t)},e.browserViewFromText=function(e){xe(e)&&ds(e,"text/plain")},e.browserViewFromU8arr=function(e,t){Za(e)&&ds(e,t)},e.bs2u8arr=ps,e.bufRead=hs,e.bufReadDbl=As,e.bufWrite=ms,e.bufWriteDbl=Is,e.cache=function(){let e=Xi(),t={};function r(t,r){setTimeout(()=>{e.emit(t,r)},1)}function n(e,n={}){if(ke(t,e))return;let i=we(n,"fun");va(i)||(i=async()=>{});let o=we(n,"inputs");Ce(o)||(o=[]);let a=we(n,"timeExpired");eo(a)||(a=5e3),a=Zi(a),t[e]={needExec:!0,fun:i,running:!1,inputs:o,value:null,time:null,timeExpired:a},r("message",{fun:"set",key:e,timeExpired:a})}async function i(e){if(ke(t,e)){let n;r("message",{fun:"get",key:e,msg:"waiting"}),await vs(()=>!t[e].running,{timeInterval:1e3});let i=Date.now();n=t[e].needExec;let o=i-t[e].time;return n?r("message",{fun:"get",key:e,msg:"execute first"}):t[e].timeExpired>0&&o>t[e].timeExpired&&(r("message",{fun:"get",key:e,msg:"execute by timeExpired",timeDiff:o}),n=!0),n?(r("message",{fun:"get",key:e,msg:"fun start"}),t[e].running=!0,t[e].value=await t[e].fun(...t[e].inputs).catch(t=>{r("error",{fun:"get",key:e,msg:t})}),t[e].needExec=!1,t[e].time=i,t[e].running=!1,r("message",{fun:"get",key:e,msg:"fun end"})):r("message",{fun:"get",key:e,msg:"use cache"}),zi(t[e].value)}return r("error",{fun:"get",key:e,msg:"invalid key"}),null}return e.set=n,e.getProxy=async function(e,t={}){return n(e,t),i(e)},e.get=i,e.update=function(e,n){ke(t,e)&&(r("message",{fun:"updateValue",key:e}),t[e].value=n,t[e].time=Date.now())},e.clear=function(e){ke(t,e)&&(r("message",{fun:"clear",key:e}),t[e].needExec=!0)},e.remove=function(e){ke(t,e)&&(r("message",{fun:"remove",key:e}),delete t[e])},e},e.cacheBd=function(e,t={}){let r=we(t,"nMax");eo(r)||(r=200),r=Zi(r);let n=we(t,"nTrigger");eo(n)||(n=3),n=Zi(n);let i=null,o=!1,a=async(...t)=>(o=!0,i=await e(...t),o=!1,i);return{get:a,getFromCache:async(...e)=>{for(let t=1;t<=r&&(t>n&&!o&&await a(...e).catch(()=>{}),null===i);t++)await bs(1e3);if(null===i)throw new Error(`exceeded nMax[${r}]`);return i}}},e.cacheSt=function(e={}){let t=we(e,"timeExpire",null);eo(t)||(t=18e5),t=Zi(t);let r=we(e,"timeDetect",null);eo(r)||(r=2e3),r=Zi(r);let n=Xi(),i={},o=e=>{if(ke(i,e)){let t=`checkWithSet: key in use: ${e}`;return n.emit("checkWithSet",{state:"error",msg:t}),!1}i[e]={time:Date.now(),value:!0};let t=`checkWithSet: ${e}`;return n.emit("checkWithSet",{state:"success",msg:t}),!0},a=setInterval(()=>{n.emit("detect",{state:"start"});let e=Date.now();for(let r of Object.keys(i)){let n=i[r];n&&e-n.time>t&&delete i[r]}n.emit("detect",{state:"finish"})},r);return n.checkWithSet=o,n.setWithFree=async(e,t)=>{n.emit("setWithFree",{state:"start"});let r=[];for(let t of e){if(!o(t)){for(let e of r)delete i[e];let e=`setWithFree: key in use: ${t}`;return n.emit("setWithFree",{state:"error",msg:e}),Promise.reject(e)}r.push(t)}try{let r=await t(),i=`setWithFree: ${e.join(", ")}`;return n.emit("setWithFree",{state:"success",msg:i}),r}catch(e){let t=`setWithFree: fn threw: ${e&&e.message||e}`;throw n.emit("setWithFree",{state:"error",msg:t}),e}finally{for(let e of r)delete i[e]}},n.set=async(e,t=!0)=>{i[e]={time:Date.now(),value:t};let r=`set: ${e}`;n.emit("set",{state:"success",msg:r})},n.get=async e=>{let t=i[e],r=void 0===t?null:t.value,o=`get: ${e}`;return n.emit("get",{state:"success",msg:o}),r},n.check=async e=>{let t=ke(i,e),r=`check: ${e} = ${t}`;return n.emit("check",{state:"success",msg:r}),t},n.del=async e=>{delete i[e];let t=`del: ${e}`;n.emit("del",{state:"success",msg:t})},n.waitExist=async(e,t={})=>{let r=we(t,"attemptNum",null);eo(r)||(r=30),r=Zi(r);let o=we(t,"timeInterval",null);eo(o)||(o=100),o=Zi(o),n.emit("waitExist",{state:"start"});try{await vs(()=>ke(i,e),{attemptNum:r,timeInterval:o})}catch(t){let i=`waitExist timeout (${r*o}ms): ${e}`;return n.emit("waitExist",{state:"error",msg:i}),Promise.reject(i)}let a=`waitExist resolved: ${e}`;n.emit("waitExist",{state:"success",msg:a})},n.waitNotExist=async(e,t={})=>{let r=we(t,"attemptNum",null);eo(r)||(r=30),r=Zi(r);let o=we(t,"timeInterval",null);eo(o)||(o=100),o=Zi(o),n.emit("waitNotExist",{state:"start"});try{await vs(()=>!ke(i,e),{attemptNum:r,timeInterval:o})}catch(t){let i=`waitNotExist timeout (${r*o}ms): ${e}`;return n.emit("waitNotExist",{state:"error",msg:i}),Promise.reject(i)}let a=`waitNotExist resolved: ${e}`;n.emit("waitNotExist",{state:"success",msg:a})},n.clear=()=>{clearInterval(a)},n},e.cbol=function(e){if(pn(e))return e;if(0===e)return!1;if(1===e)return!0;let t=!1;return De(e)&&"true"===(e=ws(sa(e)))&&(t=!0),t},e.cdbl=Mn,e.ceil=ol,e.cfilesize=function(e){return Se(e)?(e=Mn(e))<1024?al(e,1)+" b":e<1048576?al(e/1024,1)+" kb":e<1073741824?al(e/1024/1024,1)+" mb":e<1099511627776?al(e/1024/1024/1024,1)+" gb":"":""},e.cfinancial=function(e,t=0){if(!Se(e))return"";if(!Bo(t))return"";let r=(e=al(e,t)).split("."),n=r[0],i=r.length>1?"."+r[1]:"",o=/(\d+)(\d{3})/;for(;o.test(n);)n=n.replace(o,"$1,$2");return n+i},e.cint=Zi,e.clearXSS=sl,e.clearXSSDyn=async function(e,t={},r){return Rr(r)||(r=["https://cdn.jsdelivr.net/npm/xss@1.0.15/dist/xss.min.js"]),await dl(r),sl(e)},e.color=Iu,e.composeToTree=Bu,e.convertToTree=function(e,t={}){if(!Ee(e)&&!Rr(e))return[];let r=we(t,"bindKey",null);De(r)||(r="id");let n=we(t,"bindParent",null);De(n)||(n="parentId");let i=we(t,"bindText",null);De(i)||(i="text");let o=we(t,"bindChildren",null);De(o)||(o="children");let a=we(t,"bindType",null);De(a)||(a="type");let s=we(t,"bindNumOfChilren",null);De(s)||(s="numOfChilren");let c=we(t,"bindRoot",null);De(c)||(c="root");let l=we(t,"saveExtProps",null);return pn(l)||(l=!1),De(c)&&(e={[c]:e}),Bu(Cu(e,{bindKey:r,bindParent:n,bindText:i,bindType:a,bindNumOfChilren:s}),{bindKey:r,bindParent:n,bindChildren:o,saveExtProps:l})},e.copyStrToClipboard=function(e,t={}){if(!xe(e))return"invalid input";let r=we(t,"eleParent");br(r)||(r=document.body);let n=document.createElement("textarea");if(n.style.position="fixed",n.style.left=0,n.style.top=0,n.style.zIndex=-1,n.style.background="transparent",n.style.color="transparent",n.value=e,r.appendChild(n),n.select(),!xu(n))return"ele can not be focusd";try{document.execCommand("copy")}catch(e){return"can not copy str to clipboard"}return r.removeChild(n),""},e.cosd=Du,e.cotd=function(e){return Se(e)?1/Fu(e=Mn(e)):null},e.createExcelWorkbook=Qu,e.cscd=function(e){return Se(e)?1/Su(e=Mn(e)):null},e.cstr=Ya,e.day2cht=function(e,t=!1){if(!ku(e))return"";let n=r(e,"YYYY-MM-DD"),i="";return i=t?n.month()+1+"月"+n.date()+"日":"民國 "+(n.year()-1911)+" 年 "+(n.month()+1)+" 月 "+n.date()+" 日",i},e.debounce=Nu,e.delay=bs,e.dig=al,e.digExp=function(e,t=0){if(!Se(e))return"";if(!Bo(t))return"";let r="";return r=0===(e=Mn(e))?"0":Math.abs(e)<=1e-6?e.toExponential(t):al(e,t),r},e.domAlert=function(e,t={}){if(!De(e))return;let r=we(t,"type","success");ke(Ou,r)||(r="success");let n=we(t,"icon",null);De(n)||(n=Ou[r]);let i="top-right";"top-left"!==t.position&&"bottom-right"!==t.position&&"bottom-left"!==t.position||(i=t.position);let o=we(t,"time");Ia(o)||(o=4e3),o<0&&(o=4e3);let a=we(t,"paddingStyle",null);null===a&&(a={top:14,right:26,bottom:14,left:14});let s="";{let e=we(a,"top",0),t=we(a,"bottom",0),r=we(a,"left",0);s=`padding:${e}px ${we(a,"right",0)}px ${t}px ${r}px;`}let c=we(t,"textColor","#000");c=pl(c,";","");let l=we(t,"backgroundColor","#fff");l=pl(l,";","");let u=we(t,"borderWidth",1),f=we(t,"borderColor","#ebeef5");f=pl(f,";","");let d=we(t,"borderRadius",8),g=we(t,"shadowStyle","0 2px 12px 0 rgba(0,0,0,.1)");g=pl(g,";","");let p=we(t,"closeIconShift",null);null===p&&(p={top:10,right:10});let h="";{let e=we(p,"top",""),t=we(p,"bottom",""),r=we(p,"left",""),n=we(p,"right","");Ia(e)&&(e=`top:${e}px;`),Ia(t)&&(t=`bottom:${t}px;`),Ia(r)&&(r=`left:${r}px;`),Ia(n)&&(n=`right:${n}px;`),h=`position:absolute; ${e} ${n} ${t} ${r}`}let A=`alt-${Hu()}`,m=`alt-${Hu()}`,I=`\n <div \n style="display:inline-block; color:${c}; background:${l}; border:${u}px solid ${f}; border-radius:${d}px; box-shadow:${g};"\n onmouseenter="ttWAlertFadeIn('${m}')"\n onmouseleave="ttWAlertFadeOut('${m}')"\n >\n <div style="position:relative; ${s}">\n\n <div style="display:flex; align-items:center;">\n <div style="margin-right:10px;">\n <div style="display:flex;">${n}</div>\n </div>\n <div>${e}</div>\n </div>\n\n <div style="${h}">\n <div \n id="${m}" \n style="display:flex; cursor:pointer; opacity:0;" \n onclick="ttWAlertCancel('${A}')"\n >\n ${Ru}\n </div>\n </div>\n\n </div>\n </div>\n `,y=document.createElement("div");y.id=A,y.style.position="fixed",y.style.transition="transform 0.3s, top 0.5s, bottom 0.5s",y.style.zIndex=-1,y.style.opacity=.001,i.indexOf("-left")>=0?y.style.transform="translateX(-100%)":y.style.transform="translateX(100%)",y.innerHTML=I,document.querySelector("body").appendChild(y);let v=ns();return function({id:e,position:t,time:r,pm:n}){Tu[e]={id:e,position:t,ele:null,loc:{height:null,top:null,bottom:null,left:null,right:null},timeShow:r,timeStart:Date.now(),pm:n},Gu(),null===Yu&&(Yu=setInterval(()=>{Er(Tu,e=>{Date.now()-e.timeStart>e.timeShow&&(e.pm.resolve(),Ju(e.id))}),Ee(Tu)||(clearInterval(Yu),Yu=null)},50))}({id:A,position:i,time:o,pm:v}),v},e.domAppend=zu,e.domCancelEvent=Pu,e.domCompareText=function(e,t,r,n,i={}){if(!br(e))return Promise.reject("invalid ele");let o=we(i,"format");"side"!==o&&"line"!==o&&(o="side");let a="side"===o?"side-by-side":"line-by-line",s=Jf();De(t)||(t="Text");let c=ea(t,t,r,n),l=s.html(c,{drawFileList:!0,matching:"lines",outputFormat:a,...i});l=l.replace('<span class="d2h-file-list-title">Files changed (1)</span>',"");try{e.innerHTML=l}catch(e){console.log(e)}return{diff:c,html:l}},e.domConvertToPic=Xf,e.domConvertToPicDyn=async function(e,t={},r){return Rr(r)||(r=["https://cdn.jsdelivr.net/npm/@zumer/snapdom@1.9.14/dist/snapdom.min.js"]),await dl(r),Xf(e,t)},e.domDetect=function(e,t={}){let r=we(t,"timeInterval",null);eo(r)||(r=20);let n=we(t,"tolerancePixel",null);eo(n)||(n=1);let i,o=Xi(),a={offsetWidth:0,offsetHeight:0,clientWidth:0,clientHeight:0,windowWidth:0,windowHeight:0},s=zi(a),c={width:"",height:""};if(!va(e))return console.log("invalid f",e),null;i=setInterval(()=>{let t=e();if(t){let e={offsetWidth:t.offsetWidth,offsetHeight:t.offsetHeight,clientWidth:t.clientWidth,clientHeight:t.clientHeight,windowWidth:window.innerWidth,windowHeight:window.innerHeight},r=s.offsetWidth-e.offsetWidth,i=s.offsetHeight-e.offsetHeight,l=Math.abs(r)>n,u=Math.abs(i)>n,f="";r>0?f="smaller":r<0&&(f="larger");let d="";if(i>0?d="smaller":i<0&&(d="larger"),c={width:f,height:d},l||u){let r={...s};setTimeout(()=>{e.offsetWidth>0&&e.offsetHeight>0&&(o.emit("resize",{sold:r,snew:e,smode:c,ele:t}),o.emit("resizeWithWindow",{sold:r,snew:e,smode:c,ele:t,from:"dom"}))},1)}a=s,s=e}},r);let l=e=>{o.emit("resizeWithWindow",{sold:a,snew:s,smode:c,from:"window"})};return window.addEventListener("resize",l),o.clear=()=>{clearInterval(i),window.removeEventListener("resize",l)},o},e.domDrag=function(e,t={}){if(!br(e))return void console.log("ele is not a HTMLElement",e);let r=we(t,"attIdentify",null);De(r)||(r="dragid");let n=we(t,"attIndex",null);De(n)||(n="dragindex");let i=we(t,"attGroup",null);De(i)||(i="draggroup");let o=we(t,"group",null);De(o)||(o="group");let a=we(t,"previewOpacity",null);Ia(a)||(a=.4);let s=we(t,"previewDisabledOpacity",null);Ia(s)||(s=.2);let c=we(t,"previewBackground",null);De(c)||(c="white");let l=we(t,"previewBorderWidth",null);Ia(l)||(l=1);let u=we(t,"previewBorderColor",null);De(u)||(u="#f26");let f=we(t,"timeDragStartDelay",null);Ia(f)||(f=120);let d=`c${Hu(8)}`,g=o;e.setAttribute(i,g),e.setAttribute(r,d);let p=id(g,d,{attIdentify:r,previewOpacity:a,previewBackground:c,previewBorderWidth:l,previewBorderColor:u}),h=function(e,t){let r=[];return{bind:function(){let n;n="mousedown";let i=function(r){t.dragStart({e:r,ele:e,name:"mousedown"})};e.addEventListener(n,i,!1),r.push({ele:e,name:n,f:i}),n="touchstart";let o=function(r){t.dragStart({e:r,ele:e,name:"touchstart"})};e.addEventListener(n,o,!1),r.push({ele:e,name:n,f:o}),n="touchmove";let a=function(e){t.dragMove({e:e,name:"touchmove"}),e.cancelable&&e.preventDefault()};e.addEventListener(n,a,!1),r.push({ele:e,name:n,f:a})},unbind:function(){Er(r,({ele:e,name:t,f:r})=>{e.removeEventListener(t,r)})}}}(e,{dragStart:e=>{p.emit(g+"-dragStart",e)},dragMove:e=>{p.emit(g+"-dragMove",e)}});h.bind(),ad({gid:g,attGroup:i,attIndex:n,attIdentify:r,timeDragStartDelay:f,previewOpacity:a,previewDisabledOpacity:s});let A=Xi();return p.on(o+"-change",e=>{e.tarEid===d&&A.emit("change",e)}),p.on(o+"-start",e=>{e.tarEid===d&&A.emit("start",e)}),p.on(o+"-move",e=>{e.tarEid===d&&A.emit("move",e)}),p.on(o+"-enter",e=>{e.tarEid===d&&A.emit("enter",e)}),p.on(o+"-leave",e=>{e.tarEid===d&&A.emit("leave",e)}),p.on(o+"-drop",e=>{e.tarEid===d&&A.emit("drop",e)}),A.setIsActive=function(e){nd[g].isActive=e},A.unbind=function(){h.unbind(),function(e,t){let r=nd[e],n=zi(r.eleIds);_f(n,t),r.eleIds=n,0===n.length&&(r.oevg.unbind(),r.pv.clear(),delete nd[e])}(g,d)},A},e.domDragBarAndScroll=function(e,t,r={}){let n=null,i=null,o=null,a=null,s=null,c=null,l=null,u=null,f=null,d=null,g=null,p=null,h=null,A=null,m=null,I=!1,y=we(r,"getHeighRatio",null);R(y)||(y=()=>1);let v=we(r,"getWidthRatio",null);R(v)||(v=()=>1);let b=we(r,"stopScrollPropagationForPanel",null);gn(b)||(b=!1);let w=we(r,"stopTouchDragPropagationForPanel",null);gn(w)||(w=!1);let B=we(r,"useTouchDragForPanel",null);gn(B)||(B=!0);let E=e,C=t,x=Xi();return n=e=>{let t=e.deltaY/Math.abs(e.deltaY),r=e.deltaX/Math.abs(e.deltaX);x.emit("scrollPanel",{ratioY:t,ratioX:r}),b&&Pu(e)},E.addEventListener("wheel",n),i=e=>{if(B){let t=we(e,"touches.0.clientY",0),r=we(e,"touches.0.clientX",0),n=-t*y(),i=-r*v();I=!0,x.emit("pressBar",{clientY:n,clientX:i}),w&&Pu(e)}},E.addEventListener("touchstart",i),o=e=>{if(B&&I){let t=we(e,"touches.0.clientY",0),r=we(e,"touches.0.clientX",0),n=-t*y(),i=-r*v();x.emit("dragBar",{clientY:n,clientX:i}),w&&Pu(e)}},E.addEventListener("touchmove",o,{passive:!1}),a=e=>{B&&I&&(I=!1,x.emit("freeBar"),w&&Pu(e))},E.addEventListener("touchend",a),s=e=>{I=!0,x.emit("pressBar",{clientY:e.clientY,clientX:e.clientX})},C.addEventListener("mousedown",s),c=e=>{I&&(I=!1,x.emit("freeBar"))},C.addEventListener("mouseup",c),l=e=>{I=!0,x.emit("pressBar",{clientY:e.touches[0].clientY,clientX:e.touches[0].clientX})},C.addEventListener("touchstart",l),u=e=>{I&&(x.emit("dragBar",{clientY:e.touches[0].clientY,clientX:e.touches[0].clientX}),Pu(e))},C.addEventListener("touchmove",u,{passive:!1}),f=e=>{I&&(I=!1,x.emit("freeBar"))},C.addEventListener("touchend",f),d=e=>{I&&x.emit("dragBar",{clientY:e.clientY,clientX:e.clientX})},window.addEventListener("mousemove",d),g=e=>{I&&(I=!1,x.emit("freeBar"),b&&Pu(e))},window.addEventListener("mouseup",g),p=e=>{},window.addEventListener("scroll",p,{passive:!1}),h=e=>{},window.addEventListener("wheel",h,{passive:!1}),A=e=>{},document.addEventListener("scroll",A,{passive:!1}),m=e=>{},document.addEventListener("wheel",m,{passive:!1}),x.clear=function(){E.removeEventListener("wheel",n),E.removeEventListener("touchstart",i),E.removeEventListener("touchmove",o),E.removeEventListener("touchend",a),C.removeEventListener("mousedown",s),C.removeEventListener("mouseup",c),C.removeEventListener("touchstart",l),C.removeEventListener("touchmove",u),C.removeEventListener("touchend",f),window.removeEventListener("mousemove",d),window.removeEventListener("mouseup",g),window.removeEventListener("scroll",p),window.removeEventListener("wheel",h),document.removeEventListener("scroll",A),document.removeEventListener("wheel",m)},x},e.domDragPreview=rd,e.domDropFiles=function(e){let t=!1,r=!1,n=Xi();function i(e){Pu(e),r=!0,!1===t&&(t=!0,n.emit("dropIn",{ev:e}))}function o(e){Pu(e),r=!1,setTimeout(function(){r||(t=!1,n.emit("dropOut",{ev:e}))},100)}function a(e){i(e)}function s(e){o(e)}function c(e){function t(){o(e)}i(e),ld(e.dataTransfer).then(r=>{let i=pa(r.entries,{type:"file"});n.emit("getFiles",{ev:e,files:r.files,filesTree:i,entries:r.entries,cb:t})}).catch(e=>{n.emit("error",e)})}return e.addEventListener("dragenter",a,!1),e.addEventListener("dragover",a,!1),e.addEventListener("dragleave",s,!1),e.addEventListener("drop",c,!1),n.off=function(){e.removeEventListener("dragenter",a,!1),e.removeEventListener("dragover",a,!1),e.removeEventListener("dragleave",s,!1),e.removeEventListener("drop",c,!1)},n},e.domElementsFromPoint=$f,e.domFadeIn=Lu,e.domFadeOut=Uu,e.domFind=ud,e.domFinds=zf,e.domGetAttr=Zf,e.domGetBoudRect=ed,e.domGetBoudRectRefSelf=td,e.domGetFileAccept=Id,e.domGetFiles=yd,e.domGetParents=Wf,e.domGetPointFromEvent=Kf,e.domGetScrollableParent=function(e){let t=/(auto|scroll)/,r=function(e,t){return getComputedStyle(e,null).getPropertyValue(t)},n=function(e){return t.test(function(e){return r(e,"overflow")+r(e,"overflow-y")+r(e,"overflow-x")}(e))};if(!(e instanceof HTMLElement||e instanceof SVGElement))return;let i=Wf(e);for(let e=0;e<i.length;e+=1)if(n(i[e]))return i[e];return document.scrollingElement||document.documentElement},e.domGetWindowSize=function(){let e=yn();return{width:(()=>{let t=[we(e,"innerWidth"),we(e,"document.documentElement.clientWidth"),we(e,"document.body.clientWidth")];return t=pa(t,Ia),wd(t)})(),height:(()=>{let t=[we(e,"innerHeight"),we(e,"document.documentElement.clientHeight"),we(e,"document.body.clientHeight")];return t=pa(t,Ia),wd(t)})()}},e.domIsClientXYIn=function(e,t,r){if(!Ia(e))return void console.log("clientX is not a number",e);if(!Ia(t))return void console.log("clientY is not a number",t);if(!br(r))return void console.log("ele is not a HTMLElement",r);let n;try{n=r.getBoundingClientRect()}catch(e){return void console.log("invalid ele for getBoundingClientRect",e)}let i=!1;try{i=e>=n.left&&e<=n.right&&t>=n.top&&t<=n.bottom}catch(e){console.log("catch when calculating page information of element",e)}return i},e.domIsFocused=xu,e.domIsStable=function(e,t={}){if(!br(e))return Promise.reject("invalid element");if(!va(e.getBoundingClientRect))return Promise.reject("invalid element.getBoundingClientRect");let r=we(t,"mode","");"promise"!==r&&"event"!==r&&(r="promise");let n=we(t,"tolerance",0),i=we(t,"timeDiff",100),o=we(t,"timeDetect",50),a=()=>{let t=e.getBoundingClientRect();return{x:t.left,y:t.top,w:t.width,h:t.height}},s=()=>{try{return e.getAnimations({subtree:!0})}catch(e){return[]}},c=async()=>{let e=ns();try{let t=a();await bs(i);let r=((e,t)=>!!e&&!!t&&Math.abs(e.x-t.x)<=n&&Math.abs(e.y-t.y)<=n&&Math.abs(e.w-t.w)<=n&&Math.abs(e.h-t.h)<=n)(t,a());await Promise.allSettled(s().map(e=>e.finished));let o=0===s().length,c=r&&o;e.resolve(c)}catch(t){e.reject(t)}return e},l=()=>{let t=Xi(),r=!1,n=null,i=null,a=!1;return t.create=()=>{n=setInterval(()=>{r=(e=>{let r=!1;if(!br(e))return r;try{let e=!1,n=!1;i=setInterval(()=>{a?clearInterval(i):e||(e=!0,c().then(e=>{a||n!==e&&(n=e,t.emit("stable",e))}).catch(()=>{}).finally(()=>{e=!1}))},o),r=!0}catch(e){}return r})(e),r&&clearInterval(n)},50)},t.dispose=()=>{let e=!1;try{clearInterval(n),clearInterval(i),a=!0,e=!0}catch(e){}return e},t},u=null;return"promise"===r?u=c():"event"===r&&(u=l()),u},e.domIsVisible=function(e,t={}){if(!br(e))return Promise.reject("invalid element");if(Bd())return Promise.reject("invalid IntersectionObserver");let r=we(t,"mode","");"promise"!==r&&"event"!==r&&(r="promise");let n=()=>{let t=Xi(),r=!1,n=null,i=!1,o=new IntersectionObserver(e=>{if(i)return;let r=e[0].isIntersecting;t.emit("visible",r)});return t.create=()=>{n=setInterval(()=>{i?clearInterval(n):(r=(e=>{let t=!1;if(!br(e))return t;try{o.observe(e),t=!0}catch(e){}return t})(e),r&&clearInterval(n))},50)},t.dispose=()=>{let e=!1;try{clearInterval(n),o.disconnect(),i=!0,e=!0}catch(e){}return e},t},i=null;return"promise"===r?i=(()=>{let t=ns();try{let r=new IntersectionObserver(e=>{t.resolve(e[0].isIntersecting),r.disconnect()});r.observe(e)}catch(e){t.reject(e)}return t})():"event"===r&&(i=n()),i},e.domPrepend=Pf,e.domRemove=Vf,e.domRenderMarkdownMind=Ed,e.domRenderMarkdownMindDyn=async function(e,t,r={},n){return Rr(n)||(n=["https://cdn.jsdelivr.net/npm/d3@7.8.3/dist/d3.min.js","https://cdn.jsdelivr.net/npm/markmap-view@0.14.4/dist/index.min.js","https://cdn.jsdelivr.net/npm/markmap-lib@0.14.4/dist/browser/index.min.js"]),await dl(n),Ed(e,t,r)},e.domRipple=function(e,t,r={}){let n=we(r,"timeDuration",null);eo(n)||(n=1e3);let i=we(r,"color",null);if(De(i)||(i="rgba(255, 255, 255, 0.5)"),!br(e))return;e.style.position="relative",e.style.overflow="hidden";let o=e.getBoundingClientRect(),a=t.clientX-o.left,s=t.clientY-o.top,c=2*Math.max(e.clientWidth,e.clientHeight),l=document.createElement("div");l.style.width=`${c}px`,l.style.height=`${c}px`,l.style.transition=`all ${n/1e3}s linear`,l.style.position="absolute",l.style.zIndex=1,l.style.left=`${a}px`,l.style.top=`${s}px`,l.style.borderRadius="50%",l.style.transformOrigin="center",l.style.transform="translate(-50%,-50%) scale(0)",l.style.background=i,l.style.userSelect="none",l.style.pointerEvents="none",e.appendChild(l),setTimeout(()=>{l.style.transform="translate(-50%,-50%) scale(2)",l.style.opacity=0},1),setTimeout(()=>{Vf(l)},n)},e.domScrollIntoView=function(e,t={}){if(!br(e))return;Be(t)||(t={});let r={behavior:"smooth"};r={...r,...t},Vu()&&gg(),e.scrollIntoView(r)},e.domScrollTo=function(e,t={}){if(!br(e))return;Be(t)||(t={});let r={behavior:"smooth"};r={...r,...t},Vu()&&gg(),e.scrollTo(r)},e.domSetAttr=function(e,t,r){if(!br(e))return null;if(!De(t))return null;if(!De(r)&&!Se(r))return null;try{return e.setAttribute(t,r),e.getAttribute(t)}catch(e){}return null},e.domShowImages=bg,e.domShowImagesDyn=async function(e,t=null,r={},n){return Rr(n)||(n=["https://cdn.jsdelivr.net/npm/viewerjs@1.11.7/dist/viewer.min.css","https://cdn.jsdelivr.net/npm/viewerjs@1.11.7/dist/viewer.min.js"]),await dl(n),bg(e,t,r)},e.domShowInputAndGetFiles=Bg,e.domShowInputAndGetFilesU8Arrs=function(e={}){let t=we(e,"kind","*"),r=we(e,"multiple");pn(r)||(r=!1);let n=we(e,"entireHierarchy");pn(n)||(n=!1);let i=we(e,"sizeMbLimit");Se(i)||(i=1e3),i=Mn(i);let o=ns(),a=[];return Bg({kind:t,multiple:r,entireHierarchy:n,sizeMbLimit:i}).then(function(e){let t=ns(),r=we(e,"errs",{}),n=we(e,"files",[]);return Ee(r)?t.reject(r):t.resolve(n),t}).then(function(e){return Er(e,function(e){a.push({name:e.name,size:e.size,type:e.type})}),cs(e)}).then(function(e){Er(e,function(e,t){a[t].u8a=e}),o.resolve(a)}).catch(function(e){o.reject(e)}),o},e.domShowInputDatatime=function(e,t={}){let n=we(t,"type","");"date"!==n&&"datetime-local"!==n&&(n="datetime-local");let i=we(t,"eleRef",null);br(i)||(i=document.activeElement);let o=ns(),a="drf"+Hu(),s="GrpDomShowDatatime";Vf(`[name=${s}]`);let c=!1,l="";if("date"===n)ku(e)&&(c=!0,l=e);else if(Eg(e)){c=!0,l=r(e).format("YYYY-MM-DDTHH:mm")}De(l)&&(l=`value="${l}"`);let u=document.createElement("div");u.setAttribute("name",s),u.style.width=0,u.style.height=0,u.style.overflow="hidden",u.innerHTML=`\n <div style="transform:translateY(-100%);">\n <input id="${a}" type="${n}" style="opacity:0;" ${c?l:""} />\n </div>\n `;let f=null;br(i)?i.parentNode.insertBefore(u,i.nextSibling):document.querySelector("body").appendChild(u);let d=!1;function g(){if(!d){d=!0;try{f.removeEventListener("change",h,!0),i.removeEventListener("focusout",A,!0)}catch(e){}if(Vf(`[name=${s}]`),De(p)){let e="";e="date"===n?p:`${p}:00`,o.resolve(e)}}}let p="";function h(e){try{p=e.target.value}catch(e){console.log(e)}g()}function A(e){setTimeout(()=>{g()},50)}return setTimeout(()=>{f=ud("#"+a),f.addEventListener("change",h,!0),f.showPicker()},1),i.addEventListener("focusout",A,!0),o},e.domTooltip=function(e,t,r={}){let n=null,i=null;function o(){null!==n&&n.destroy(!0),e.setAttribute("tippystate",""),clearInterval(i)}let a={arrow:!0,theme:"dark",placement:"bottom",delay:150};r=Ee(r)?vg(a,r):a;let s=t;t||(s=e.innerHTML);let c=Se(e.getAttribute("tippystate"));if(e.setAttribute("tippystate","5"),c)return;s=`<div style="text-align:left;">${s}</div>`;let l=Hh;Hh.default&&(l=Hh.default),n=l(e,{...r,content:s,allowHTML:!0,onHidden(){o()},onDestroy(){n=null,o()}}),n.show(),i=setInterval(()=>{let t=e.getAttribute("tippystate");Se(t)?(t=Zi(t),t-=1,e.setAttribute("tippystate",t),t<=0&&o()):o()},1e3)},e.domTriggerEvent=wg,e.domVirtualCreate=Uh,e.domVirtualCreateQueue=function(){return new function(){let e=jh(1);return async function(t,r={}){return e(Uh,t,r)}}},e.downloadExcelFileFromData=Vh,e.downloadExcelFileFromDataDyn=async function(e,t="data",r,n){Rr(n)||(n=["https://cdn.sheetjs.com/xlsx-0.20.3/package/dist/xlsx.full.min.js"]),await dl(n);let i=Vh(e,t,r);return""!==we(i,"error","")?Promise.reject(i.error):i},e.downloadFileFromB64=function(e,t){if(!In())return void console.log("no window");if(!De(e))return void console.log("no filename");let r=document.createElement("a");r.href=t,r.download=e,document.body.appendChild(r),r.click(),document.body.removeChild(r)},e.downloadFileFromBlob=Gh,e.downloadFileFromText=function(e,t,r=!0){if(!In())return void console.log("no window");if(!De(e))return void console.log("invalid filename");if(!xe(t))return void console.log("invalid content");if(!pn(r))return void console.log("withBOM is not a boolean");let n;n=r?new Blob(["\ufeff",t]):new Blob([t]),Gh(e,n)},e.downloadFileFromU8Arr=function(e,t){if(!In())return void console.log("no window");if(!De(e))return void console.log("no filename");if(!Za(t))return void console.log("no data");Gh(e,Ph(t))},e.dtmapping=Xh,e.dtpick=_h,e.estimateTicks=function(e,t,r={}){if(!Se(e))throw new Error("rmin is not a number");if(e=Mn(e),!Se(t))throw new Error("rmax is not a number");if(e===(t=Mn(t))){let t=null;t=0===e?1:Math.abs(e/10);let r=Kh(t,{returnDigit:!0});return t=Wh(t,r),{tickNum:3,tickInterval:t,tickPositions:[e-t,e,e+t],tickDig:r}}if(e>t)throw new Error(`rmin[${e}] > rmax[${t}]`);let n=we(r,"testTickNums");Rr(n)||(n=[3,4,5]);let i=e,o=t,a=$h(i),s=$h(o),c=Math.max(a.r,s.r),l=Math.log10(c),u=i/c,f=o/c,d=(u+f)/2,g=f-u,p=[];Er(n,e=>{let t=g/(e-1),r=Kh(t,{returnDigit:!0});r=Math.min(r,2),Er(ao(r,-1,-1),r=>{let n=r-l;n=Math.max(n,0);let i=ol(t,r),o=i-1/Math.pow(10,r);o=Wh(o,r);let a=i+1/Math.pow(10,r);a=Wh(a,r);let s=[o,i,a];s=pa(s,e=>e>0);let h=Wh(d,r),A=h-1/Math.pow(10,r);A=Wh(A,r);let m=h+1/Math.pow(10,r);m=Wh(m,r);let I=[A,h,m];Er(s,t=>{let i=c*t;i=Wh(i,n),Er(I,o=>{let a=[],s=[];{let i=o-(e-1)/2*t;for(let o=0;o<e;o++){let e=i+o*t;e=Wh(e,r),a.push(e);let l=c*e;l=Wh(l,n),s.push(l)}}let l=(d=a)&&d.length?d[0]:void 0;var d;let h=Qa(a);if(l>u||h<f)return!0;let A=(u-l)/g,m=(h-f)/g,I=(A+m)/2,y=0;Er(s,e=>{Hn(e)&&y++});let v=y/e,b=0;Er(a,e=>{0===e&&b++});let w=b/e,B=0;Er(a,e=>{.5===e&&B++});let E=B/e,C=0;Er(a,e=>{1===e&&C++});let x=C/e,D={diff:I,rngCenter:o,numInt:y,ratInt:v,num0:b,rat0:w,num5:B,rat5:E,num10:C,rat10:x,overMin:A,overMax:m,fitness:I+.2*r+.1*e+1.5*A+1.5*m+(1-.25*v)+(1-.4*w)+(1-.3*E)+(1-.3*x),idg:r,tickNum:e,_tickDig:r,_tickInterval:t,_tickPositions:a,tickDig:n,tickInterval:i,tickPositions:s};p.push(D)})})})}),p=Oa(p,"fitness");let h=we(p,0);return{tickNum:h.tickNum,tickInterval:h.tickInterval,tickPositions:h.tickPositions,tickDig:h.tickDig}},e.evem=Xi,e.execJsCode=async function(e,t={}){e=i.resolve(e);let r=(await import(o.pathToFileURL(e).href)).default;if(!va(r))throw new Error(`the default export of [${e}] is not a function`);return await r(t)},e.execProcess=function(e,t,r={}){if(!Rr(t)&&!De(t))throw new Error("args is not an effective array or string");De(t)&&(t=[t]);let n=we(r,"mode");"spawn"!==n&&"exec"!==n&&"execFile"!==n&&(n="spawn");let i=we(r,"cbStdout"),o=we(r,"cbStderr"),s=we(r,"codeCmd");De(s)||(s="utf8");let c=we(r,"useChcp");pn(c)||(c=!1);let l=we(r,"timeout");(!Se(l)||l<=0)&&(l=null);let u=ns();if(!ya(n,["spawn","exec","execFile"]))return u.reject(`invalid mode[${n}]`),u;let f=null,d="";try{if("spawn"===n){let r=ua(e,1),n=fa(e,1);if('"'===r||'"'===n||"'"===r||"'"===n)throw new Error("prog of spawn doens not need to add quotes");f=a.spawn(e,t,{windowsHide:!0,shell:!1})}else if("exec"===n){let r="";c&&(r="cmd /c chcp 65001>nul &&"),f=a.exec(`${r} ${e} ${t.join(" ")} & exit`,{windowsHide:!0,encoding:s})}else"execFile"===n&&(f=a.execFile(e,t,{windowsHide:!0,encoding:s}))}catch(e){return u.reject(e),u}f.stdout.on("data",e=>{let t="";t="spawn"===n?e.toString(s):e.toString(),d+=t+"\n",va(i)&&i(t)}),f.stderr.on("data",e=>{let t="";t="spawn"===n?e.toString(s):e.toString(),d+=t+"\n",va(o)&&o(t)});let g=null,p=!1;return null!==l&&(g=setTimeout(()=>{p=!0,f&&f.pid&&aA(f.pid).catch(()=>{})},l)),f.on("close",e=>{null!==g&&clearTimeout(g),p?u.reject(`timeout[${l}ms]:\n${d}`):0!==e?u.reject(`code[${e}]:\n${d}`):u.resolve(d)}),f.on("error",e=>{null!==g&&clearTimeout(g),u.reject(e)}),u},e.execProcessKillPid=aA,e.filepathToTree=function(e,t={}){if(!Rr(e))return{};let r=we(t,"delimiter");De(r)||(r="❯");let n=we(t,"bindRoot");De(n)||(n="");let i=De(n),o="";o=i?n:"root";let a=we(t,"soryItems"),s=xr(e,(e,t)=>{"folder"!==e.type&&"file"!==e.type&&(e.type="file");let n=(e=>{let t=la(e=(e=e.replace(/\\\\/g,"\\")).replace(/\\/g,"/"),"/");return{ss:t,cfp:xo(t,r)}})(e.path);return{ind:t,type:e.type,ss:n.ss,data:zi(e)}}),c=e=>{let t=dn(e),n=[];for(let i=0;i<t;i++){let t=[];for(let r=0;r<=i;r++)t.push(e[r]);let o=xo(t,r);n.push({id:o,name:e[i]})}return n},l=-1,u=[],f={};Er(s,e=>{let t=null;t=[o];let n=null;n=o;let i=dn(e.ss)-1;Er(e.ss,(o,a)=>{let s=a<i||"folder"===e.type;t.push(o);let d=null,g=null;a===i&&(d=e.ind,g=e.data);let p=xo(t,r),h=c(t);if(ke(f,p)){let t=f[p],r="folder"===we(t,"_type","");if(!r&&s)throw console.log("kpLv[id]",t),console.log("v",e),new Error(`id[${p}] is unrecognized from a file to folder`);if(!r&&!s)throw console.log("kpLv[id]",t),console.log("v",e),new Error(`id[${p}] get repeat data from two files`);if(r&&!s)throw console.log("kpLv[id]",t),console.log("v",e),new Error(`id[${p}] is unrecognized from a folder to file`);if(Ee(f[p].data)&&Ee(g))throw console.log("kpLv[id]",t),console.log("v",e),new Error(`id[${p}] get repeat data from two folders`);if(null===f[p].data&&Ee(g)){f[p]._indOri=d,f[p].data=g;let e=f[p]._indNormalize,t=u[e];u[e]={...g,type:t.type,path:t.path}}}else{l++;let e=l,r=null;r=s?{_indOri:d,_indNormalize:e,ns:dn(t),ts:zi(t),pathInfors:h,_type:"folder",type:"array",numOfChilren:-1,id:p,parentId:n,text:o,children:[],data:g}:{_indOri:d,_indNormalize:e,ns:dn(t),ts:zi(t),pathInfors:h,_type:"file",type:"node",numOfChilren:-1,id:p,parentId:n,text:o,data:g},f[p]=r,u.push({...we(f[p],"data",{}),type:f[p]._type,path:"/"+xo(t,"/")})}n=p})});let d=lA(f);if(d=Oa(d,"id"),d=Oa(d,"ns"),va(a)){let e=[];Er(AA(d,"ns"),(t,r)=>{Er(AA(t,"parentId"),(t,n)=>{let i=a(t,n,r);e=[...e,...i]})}),d=e}let g=[],p=[];Er(d,e=>{"folder"===e._type?g.push(e):p.push(e)});let h=AA(g,"ns"),A=AA(p,"ns"),m=cA(xr(g,"ns")),I=cA(xr(p,"ns")),y=null;{let e=[o];y=[{_indOri:null,_indNormalize:null,ns:dn(e),ts:zi(e),pathInfors:c(e),_type:"folder",type:"array",numOfChilren:-1,id:o,parentId:"",text:o,children:[],data:null}]}let v={};v[o]="0.children";let b={};b[o]="0";for(let e=2;e<=m;e++){Er(h[e],e=>{let t=we(v,e.parentId,"");if(!De(t))throw console.log("kpPathFd",v),console.log("v",e,e.parentId),new Error(`invalid parentId[${e.parentId}] in folder`);let r=we(y,t);if(Ce(r)||yu(y,t,[]),r=we(y,t),!Ee(pd(r,{id:e.id}))){r.push({...e,children:[]});let n=`${t}.${dn(r)-1}`;v[e.id]=`${n}.children`,b[e.id]=n}})}let w=zi(y),B={};for(let e=2;e<=I;e++){Er(A[e],e=>{let t=we(v,e.parentId,"");if(!De(t))throw console.log("kpPathFd",v),console.log("v",e,e.parentId),new Error(`invalid parentId[${e.parentId}] in file`);let r=we(y,t);if(!Ce(r))throw console.log("treeItems",y),console.log("k",t),console.log("v",e),new Error("無預先建置資料夾");if(!Ee(pd(r,{id:e.id}))){r.push(e);let n=`${t}.${dn(r)-1}`;B[e.id]=n,b[e.id]=n}})}return{treeItems:y,treeItemsFolder:w,kpPath:b,fpsNormalize:u}},e.files2data=function(e){let t=ns(),r=xr(e,function(e){return{name:e.name,size:e.size,type:e.type}});return ss(e).then(function(e){let n=xr(e,function(e){return{b64:e}}),i=mA(r,n);t.resolve(i)}),t},e.flattenToConn=Cu,e.flattenTree=function(e,t={}){if(Ce(e)){if(0===e.length)return[]}else{if(!Be(e))return[];if(Mr(e))return[]}let r=we(t,"bindKey",null);De(r)||(r="id");let n=we(t,"bindChildren",null);De(n)||(n="children");let i=!1;Be(e)&&(i=!0,e=[e]);let o=[];return Eu(e,(e,t,i)=>{let a=we(e,r,null),s=we(e,n,null);if(a){let r=function(e){let t=[e[0]];for(let r=1;r<e.length;r++){let i=e[r];t.push(n),t.push(i)}return t}([...i,t]);if(o.push({...e,level:(dn(r)-1)/2,nk:r}),s)return s}}),i&&(o=o[0]),o},e.floor=function(e,t=0){return Bo(t)||(t=0),t=Zi(t),Se(e)?new il(e).toDecimalPlaces(t,il.ROUND_FLOOR).toNumber():""},e.fsBuildReadStreamText=function(e){if(!vA(e))throw new Error("fp is not a file");let t=Xi(),r=s.createReadStream(e,{encoding:"utf8"});return t.emit("create"),c.createInterface({input:r,crlfDelay:1/0}).on("line",e=>{t.emit("line",e)}),r.on("close",()=>{t.emit("close")}),t},e.fsBuildWriteStreamText=function(){let e=null;return{create:t=>{let r=ns();return e=s.createWriteStream(t,{flags:"w",encoding:"utf8"}),e.on("finish",()=>{r.resolve()}),e.on("error",e=>{r.reject(e)}),r},write:t=>{e.write(t+"\n")},end:()=>{let t=ns();return e.on("close",()=>{t.resolve()}),e.end(),t}}},e.fsCleanFolder=function(e){return BA(e,{path:i,fs:s})},e.fsCleanFolderCore=BA,e.fsCopyFile=function(e,t,r={}){return EA(e,t,{path:i,fs:s,...r})},e.fsCopyFileCore=EA,e.fsCopyFolder=function(e,t,r={}){return xA(e,t,{path:i,fs:s,...r})},e.fsCopyFolderCore=xA,e.fsCreateFile=function(e,t,r={}){return SA(e,t,{fs:s,...r})},e.fsCreateFileCore=SA,e.fsCreateFolder=kA,e.fsCreateFolderCore=wA,e.fsDeleteFile=function(e){return NA(e,{fs:s})},e.fsDeleteFileCore=NA,e.fsDeleteFileSafe=async function(e,t={}){return await qA(e,{fs:s,...t})},e.fsDeleteFileSafeCore=qA,e.fsDeleteFolder=HA,e.fsDeleteFolderCore=MA,e.fsDeleteFolderSafe=async function(e,t={}){return await LA(e,{fs:s,...t})},e.fsDeleteFolderSafeCore=LA,e.fsDownloadFile=async function(e,t){return UA(e,t,{fs:s,Readable:l.Readable})},e.fsDownloadFileCore=UA,e.fsEvem=function(e={}){let t=we(e,"fd");De(t)||(t="./_evps");let r=we(e,"polling");pn(r)||(r=!1);let n=we(e,"timeInterval");eo(n)||(n=100),n=Zi(n);let o=we(e,"timeBinaryInterval");eo(o)||(o=300),o=Zi(o);let a=we(e,"keySys");De(a)||(a="[::pkg_content::]"),TA(t)||kA(t);let c=YA(t,{polling:r,timeInterval:n,timeBinaryInterval:o});c.on("change",e=>{if("add"!==e.type&&"change"!==e.type)return;let t=OA(e.fp),r="";try{r=s.readFileSync(e.fp,"utf8"),r=Ka(r)}catch(e){}Ee(r)&&l.emit(t,{[a]:r})});let l=new u.EventEmitter,f=l.emit;return l.emit=function(e,r){let n=!1;if(Ee(r)&&(n=ke(r,a)),n){let t=we(r,a,null),n=we(t,"pkg",""),i=we(t,"time","");return f.call(this,e,n,i)}((e,r)=>{let n=i.resolve(t,e);xe(r)||(r=hn(r)),s.writeFileSync(n,r,"utf8")})(e,{pkg:r,time:RA()})},l.clear=()=>{c.clear(),HA(t)},l},e.fsExists=function(e){return IA(e,{fs:s})},e.fsExistsCore=IA,e.fsGetFileBasicHash=function(e,t={}){return jA(e,{fs:s,crypto:d,...t})},e.fsGetFileBasicHashCore=jA,e.fsGetFileHash=function(e,t={}){return VA(e,{fs:s,crypto:d,...t})},e.fsGetFileHashCore=VA,e.fsGetFileXxHash=function(e,t={}){return zA(e,{fs:s,...t})},e.fsGetFileXxHashCore=zA,e.fsGetFilesInFolder=function(e,t=1){return XA(e,t,{path:i,fs:s})},e.fsGetFilesInFolderCore=XA,e.fsGetFilesWithHashInFolder=WA,e.fsGetFilesWithHashInFolderCore=_A,e.fsGetFolderBasicHash=function(e,t={}){return KA(e,{path:i,fs:s,crypto:d,...t})},e.fsGetFolderBasicHashCore=KA,e.fsGetFoldersInFolder=function(e,t=1){return $A(e,t,{path:i,fs:s})},e.fsGetFoldersInFolderCore=$A,e.fsIsFile=vA,e.fsIsFileCore=yA,e.fsIsFolder=TA,e.fsIsFolderCore=bA,e.fsMergeFiles=async function(e,t,r={}){return ZA(e,t,{fs:s,...r})},e.fsMergeFilesCore=ZA,e.fsReadJson=function(e){let t=null,r=em(e,{fs:s});if(r.error)return r;let n=r.success,i=null;try{i=JSON.parse(n)}catch(e){t=e}return null!==t?{error:t}:{success:i}},e.fsReadText=function(e){return em(e,{fs:s})},e.fsReadTextCore=em,e.fsRenameFile=function(e,t){return tm(e,t,{fs:s})},e.fsRenameFileCore=tm,e.fsRenameFolder=function(e,t){return rm(e,t,{fs:s})},e.fsRenameFolderCore=rm,e.fsSrlog=function(e={}){let t=we(e,"fdSys","");De(t)||(t=i.resolve(),t=t.replaceAll("\\","/"));let n=we(e,"fdLog","");De(n)||(n="./syslog"),TA(n)||kA(n);let o=we(e,"dlm","");De(o)||(o="ꓹ");let a=we(e,"useTime",null);pn(a)||(a=!0);let c=we(e,"useLoc",null);pn(c)||(c=!0);let l=we(e,"useLocRela",null);async function u(e,t,...i){let l=(()=>{let e=r().format("YYYY-MM-DD");return`${n}/${e}.log`})(),u=xr(i,e=>{let t="";return t=Be(e)||Ce(e)?JSON.stringify(e):pn(e)?e?"true":"false":Ya(e),t}),f="";a&&(f=`[${e}]\n`,s.appendFileSync(l,f,"utf8")),c&&(f=`[${t}]\n`,s.appendFileSync(l,f,"utf8")),f=`${xo(u,`${o} `)}\n\n`,s.appendFileSync(l,f,"utf8")}return pn(l)||(l=!0),function(...e){let r="";a&&(r=RA());let n="",i="",o=[];if(c){if(o=la((new Error).stack,"\n"),Er(o,e=>{if((e=sa(e)).indexOf("file:")<0)return!0;if(e.indexOf("fsSrlog.mjs")>=0)return!0;return Er(la(e," "),e=>{if(e.indexOf("file:")>=0)return n=e,!1}),!De(n)&&void 0}),!De(n))throw console.log("stackLines",o),new Error("can not parse stackLines");"("===ua(n,1)&&(n=da(n,1)),")"===fa(n,1)&&(n=Ga(n,1));try{n=decodeURIComponent(n)}catch(e){console.log(e)}i=n,i=da(i,8),i=i.replace(t,"")}let s=[];a&&(s=[...s,`[${r}]`]);let f="";c&&(f=n,l&&(f=i),s=[...s,`[${f}]`]),s=[...s,...e],console.log(...s),u(r,f,...e)}},e.fsSyncFolder=function(e,t,r={}){return om(e,t,{path:i,fs:s,crypto:d,...r})},e.fsSyncFolderCore=om,e.fsTask=function(e,t={}){let r=we(t,"fdStorage","");De(r)||(r="./_tkfs");let n=we(t,"levelLimit","");eo(n)||(n=1),n=Zi(n);let i=we(t,"typeHash","");De(i)||(i="md5");let o=we(t,"timeInterval");ha(o)||(o=6e4),o=Zi(o),kA(r);let a=Xi(),c=!1,l=`${r}/fpHash.json`,u=`${r}/fpResult.json`,f=async()=>{if(!0===c)return;let t=(()=>{let e={};try{e=Ka(s.readFileSync(l,"utf8"))}catch(e){}return e})(),r=await(async()=>{let t={};return TA(e)?(Er(await WA(e,n,{type:i}),e=>{t[e.path]=e.hash}),t):t})(),o=xr(t,(e,t)=>({path:t,hash:e})),u=xr(r,(e,t)=>({path:t,hash:e}));Er(nm(o,u,"path").infor,(e,n)=>{if("same"===e)return!0;let i=we(t,n,""),o=we(r,n,""),u="";u="del"===e?i:o;let f=e,d=n,g=FA(n);c=!0;let p=ns();return a.emit("change",{type:f,fp:d,fn:g,hash:u,pm:p}),p.then(()=>{let e=zi(t);e[d]=r[d],(e=>{try{let t=hn(e);s.writeFileSync(l,t,"utf8")}catch(e){}})(e)}).finally(()=>{c=!1}),!1})},d=()=>{let e={};try{e=Ka(s.readFileSync(u,"utf8"))}catch(e){}return e},g=(e={})=>{try{let t=hn(e);s.writeFileSync(u,t,"utf8")}catch(e){}},p=setInterval(()=>{f().catch(()=>{})},o);return a.getResult=(e,t)=>{let r=`${e}|${t}`,n=we(d(),r,[]);return Ce(n)||console.log(`result for key[${r}] is not an array`),n},a.getAndEliminateResult=(e,t)=>{let r=`${e}|${t}`,n=d(),i=we(n,r,[]);return Ce(i)||console.log(`result for key[${r}] is not an array`),n=((e,t)=>{let r={};return Er(e,(e,n)=>{we(la(n,"|"),0,"")!==t&&(r[n]=e)}),r})(n,e),g(n),i},a.setResult=(e,t,r)=>{Ce(r)||(console.log("result is not an array, default to []"),r=[]);let n=`${e}|${t}`,i=d();i[n]=r,g(i)},a.clear=()=>{clearInterval(p)},a},e.fsTaskCp=function(e,t,r={}){TA(e)||kA(e),TA(t)||kA(t);let n=`${e}/fpHash.json`,i=`${t}/fpHash.json`,o=e=>{let t={};try{t=Ka(s.readFileSync(e,"utf8"))}catch(e){}return t},a=(e,t)=>{try{let r=hn(t);s.writeFileSync(e,r,"utf8")}catch(e){}},c=(e,t)=>we(o(e),t,""),l=(e,t,r)=>{let n=o(e);n[t]=r,a(e,n)},u=(e,t)=>{let r=o(e);ke(r,t)&&delete r[t],a(e,r)},f=()=>o(n),d=e=>a(n,e),g=e=>c(n,e),p=()=>o(i),h=e=>a(i,e),A=e=>c(i,e),m=(e,t)=>l(i,e,t),I=e=>u(i,e),y=e=>{let t=[];return Er(e,(e,r)=>{t.push({fp:r,hash:e})}),t},v={buildSrc:()=>{let e=Xi();return e.set=(t,r)=>{((e,t)=>{l(n,e,t)})(t,r),e.emit("set",{type:"set",fp:t,hash:r})},e.get=g,e.remove=t=>{(e=>{u(n,e)})(t),e.emit("remove",{type:"remove",fp:t})},e.readKp=f,e.writeKp=d,e},buildTar:()=>{let e=Xi(),t=Nu(300),r=am(n);return r.on("change",r=>{t(()=>{(async()=>{let t=ns(),r=f();if(!Ee(r))return t.resolve("no src"),t;let n=p(),i=y(r),o=nm(y(n),i,"fp",{withInfor:!1}),a=ns();return a.then(e=>{h(r)}).catch(()=>{}),e.emit("change",{kpSrc:r,kpTar:n,kpCmp:o,pm:a}),t})().catch(()=>{})})}),e.set=m,e.get=A,e.remove=I,e.readKp=p,e.writeKp=h,e.clear=r.clear,e}};return v},e.fsTreeFolder=function(e,t=1){return PA(e,t,{path:i,fs:s})},e.fsTreeFolderCore=PA,e.fsTreeFolderWithHash=function(e,t=1,r={}){return im(e,t,{path:i,fs:s,crypto:d,...r})},e.fsTreeFolderWithHashCore=im,e.fsWatchFile=am,e.fsWatchFolder=YA,e.fsWriteJson=function(e,t,r={}){let n=null;if(!Be(t)&&!Ce(t))return{error:"inp is not an object or array"};let i=we(r,"useFormat",null);pn(i)||(i=!1);let o="";try{o=i?JSON.stringify(t,null,2):JSON.stringify(t)}catch(e){n=e}return null!==n?{error:n}:sm(e,o,{fs:s})},e.fsWriteText=function(e,t){return sm(e,t,{fs:s})},e.fsWriteTextCore=sm,e.genGradientColor=function(e){if(Ur(e))return{};let t;try{t=Iu.toRgba(e)}catch(e){return{}}function r(e,t){return e.a=t,Iu.toRgbaString(e)}return{linearGradient:{x1:0,x2:0,y1:0,y2:1},stops:[[0,r(t,.4)],[1,r(t,.9)]]}},e.genID=Hu,e.genIDSeq=function(){return dm()},e.genPm=ns,e.getBufferSize=hm,e.getClearPathName=DA,e.getCsvStrFromData=Am,e.getDataFromExcelFileU8Arr=ym,e.getDataFromExcelFileU8ArrDyn=async function(e,t,r){Rr(r)||(r=["https://cdn.sheetjs.com/xlsx-0.20.3/package/dist/xlsx.full.min.js"]),await dl(r);let n=ym(e,t);return""!==we(n,"error","")?Promise.reject(n.error):n},e.getEnv=function(){let e=In(),t="undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope;return e=e||t,{isBrowser:e,isWebWorker:t,isNode:"undefined"!=typeof process&&null!=process.versions&&null!=process.versions.node}},e.getErrorMessage=function(e){let t="";if(wm(e))t=e.message;else{if(xe(e))return e;if(Be(e))return ke(e,"message")?e.message:JSON.stringify(e);if(Ce(e))return JSON.stringify(e);t=Ya(e)}return t},e.getExcelU8ArrFromData=function(e,t="data"){if(!Rr(e)){return{error:"no data"}}De(t)||(t="data");let r=null,n=zh(e,t);return ke(n,"error")?n:(r=Bm(n),ke(r,"error"),r)},e.getExcelU8ArrFromWorkbook=Bm,e.getExcelWorkbookFromData=zh,e.getExcelWorkbookFromWorksheet=Jh,e.getExcelWorksheetFromData=bn,e.getFileAccept=md,e.getFileBasicHash=Km,e.getFileHash=async function(e,t={}){if(!gs(e)&&!Wm(e))return console.log("inp",e),Promise.reject("inp is not a Blob or File");let r=we(t,"type","");De(r)||(r="sha512");let n=we(t,"chunkSize");return Se(n)||(n=67108864),n=Mn(n),ke({MD5:"md5","SHA-1":"sha1","SHA-256":"sha256","SHA-384":"sha384","SHA-512":"sha512",md5:"md5",sha1:"sha1",sha256:"sha256",sha384:"sha384",sha512:"sha512",xxhash64:"xxhash64"},r)?"xxhash64"===r?$m(e,t):Km(e,t):Promise.reject(`type[${r}] must be one of [ 'md5', 'sha1', 'sha256', 'sha384', 'sha512', 'xxhash64' ]`)},e.getFileName=FA,e.getFileNameExt=function(e){if(!De(e))return"";let t=Jo(FA(e),".");if(dn(t)<=1)return"";let r="";try{r=Qa(t)}catch(e){}return r},e.getFileTrueName=OA,e.getFileType=Ad,e.getFileXxHash=$m,e.getGlobal=yn,e.getObjSize=function(e){let t=0,r=function e(r){if(null!=r)switch(typeof r){case"number":t+=8;break;case"string":t+=2*r.length;break;case"boolean":t+=4;break;case"object":let n=Object.prototype.toString.call(r).slice(8,-1);if("Object"===n||"Array"===n)for(let t in r)r.hasOwnProperty(t)&&e(r[t]);else t+=2*r.toString().length}return t}(e),n=function(e){return e<1024?e+" bytes":e<1048576?(e/1024).toFixed(3)+" KiB":e<1073741824?(e/1048576).toFixed(3)+" MiB":(e/1073741824).toFixed(3)+" GiB"}(r);return{int:r,str:n}},e.getPathParent=QA,e.getTimeBetween=function(e,t,r="days"){let n=rI(r);if(""===n)return[];let i=nI(e,r),o=nI(t,r);return null===i||null===o||e>=t?[]:xr(tI(o.diff(i,r)+1),function(e){return i.clone().add(e,r).format(n)})},e.getTimeFromUnit=rI,e.getTimeHp=iI,e.getTimeObject=nI,e.getTimeRange=function(e,t){if(!Eg(e))return"無起始時間";if(void 0===t&&(t=e),!Eg(t))return"結束時間格式錯誤";let n=r(e,"YYYY-MM-DDTHH:mm:ss"),i=r(t,"YYYY-MM-DDTHH:mm:ss"),o=n.format("YYYY-MM-DD"),a=i.format("YYYY-MM-DD");if(o===a){let r=i.format("HH:mm");if(e===t)return oI(e)+" 至 無";if(e<t)return oI(e)+" 至 "+r;if(e>t)return oI(e)+" 至 "+r+" (起始時間大於結束時間)"}else{if(o<a)return oI(e)+" 至 "+oI(t);if(o>a)return oI(e)+" 至 "+oI(t)+" (起始時間大於結束時間)"}return""},e.getUserAgent=aI,e.getUserAgentDyn=async function(e=null,t){return Rr(t)||(t=["https://cdn.jsdelivr.net/npm/ua-parser-js@2.0.3/dist/ua-parser.min.js"]),await dl(t),aI(e)},e.getltdtkeys=Xr,e.haskey=ke,e.html2str=async function(e){if(!De(e))return"";let t=await async function(){let e="htmlToText";if(va(we(m,e)))return m;if(va(we(m,["default",e])))return m.default;let t=globalThis,r=null;if(await vs(()=>(r=we(t,"ht",null),Ee(r)),{attemptNum:4e3,timeInterval:50}),va(we(r,e)))return r;if(va(we(r,["default",e])))return r.default;throw console.log("ht",m,"g.ht",t.ht),new Error("invalid ht, g.ht, g.ht.default, use script for import")}();return t.htmlToText(e,{wordwrap:!1,selectors:[{selector:"script",format:"skip"},{selector:"style",format:"skip"}]})},e.htmlDecode=function(e,t={}){return De(e)?us.decode(e,t):""},e.htmlEncode=fs,e.importResources=dl,e.interp1=function(e,t,r={}){if(!Ce(e))return{err:"ps is not an array"};{let e=!Se(t),r=!Ce(t);if(e&&r)return{err:"px is not a number or an array"}}let n=function(e,t={}){if(dn(e)<=0)return[];let r=we(t,"keyX");De(r)||(r="x");let n=we(t,"keyY");De(n)||(n="y");let i=[];return Er(e,e=>{let t=null,o=null;Ce(e)&&dn(e)>=2?(t=we(e,0),o=we(e,1)):(t=we(e,r,null),o=we(e,n,null)),Se(t)&&Se(o)&&(t=Sn(t),o=Sn(o),i.push({x:t,y:o}))}),i}(e,r);if(we(n,"err"))return we(n,"err");if(0===dn(n))return{err:"ps(length=0) is not an effective array",ps:e,psEff:n};if(1===dn(n))return{err:"ps(length=1) is one point only",ps:e,psEff:n};let i=function(e){let t=!0,r=!0;for(let n=1;n<dn(e);n++){let i=e[n-1],o=e[n];if(t&&i.x>o.x&&(t=!1),r&&i.x<o.x&&(r=!1),i.x===o.x)return{err:`x can not be equal: i=${n}, x=${i.x}`}}return t?lI:r?uI:"no"}(n);if("no"===i)return{err:"psEff is not increasing or decreasing"};i===uI&&(i=lI,n=La(n));let o=!Ce(t);o&&(t=[t]);let a=function(e,t={}){if(dn(e)<=0)return[];let r=we(t,"keyX");De(r)||(r="x");let n=[];return Er(e,e=>{let t=null;t=Se(e)?Sn(e):Ce(e)&&dn(e)>=1?we(e,0):we(e,r,null),Se(t)&&(t=Sn(t),n.push({x:t}))}),n}(t,r),s=we(r,"mode");"linear"!==s&&"stairs"!==s&&"blocks"!==s&&(s="linear");let c,l=xr(a,(e,t)=>{let i=we(e,"x"),o=null;try{"linear"===s?o=function(e,t){let r=fI(e,t);if(r!==sI)return r;let n=null;for(let r=1;r<dn(e);r++){let i=e[r-1],o=e[r];if(i.x<=t&&t<=o.x){n=((t-i.x)*o.y+(o.x-t)*i.y)/(o.x-i.x);break}}return null===n?{err:cI}:n}(n,i):"blocks"===s?o=function(e,t){let r=fI(e,t);if(r!==sI)return r;let n=null;for(let r=1;r<dn(e);r++){let i=e[r-1],o=e[r],a=i.x,s=o.x;if(a<=t&&t<=s){n=o.y;break}}return null===n?{err:cI}:n}(n,i):"stairs"===s&&(o=function(e,t,r={}){let n=we(r,"xMin");if(Ia(n)){if(n>e[0].x)return{err:`xMin=${n} > ps[0].x=${e[0].x}`};n===e[0].x||(e=[{x:n,y:e[0].y},...e])}let i=we(r,"xMax");if(Ia(i)){if(i<e[dn(e)-1].x)return{err:`xMax=${i} < ps[size(ps)-1].x=${e[dn(e)-1].x}`};if(i===e[dn(e)-1].x);else{let t={x:i,y:e[dn(e)-1].y};e=[...e,t]}}let o=fI(e,t);if(o!==sI)return o;let a=null;for(let r=0;r<dn(e);r++){let n=we(e,r-1,null),i=we(e,r,null),o=we(e,r+1,null),s=i.x;n&&(s=(n.x+i.x)/2);let c=i.x;if(o&&(c=(o.x+i.x)/2),s<=t&&t<=c){a=i.y;break}}return null===a?{err:cI}:a}(n,i,r))}catch(e){o={err:e.toString()}}return o});return c=o?l[0]:l,c},e.isDate=function(e){let t=e;return De(e)&&(t=new Date(e)),Se(e)&&(t=Mn(e),t=new Date(e)),t instanceof Date&&!isNaN(t)},e.isDev=function(){return!!location&&rs(location.href,"localhost")},e.isEle=br,e.isEleExistByID=function(e){return!!De(e)&&!(null===document.getElementById(e))},e.isEmail=function(e){return!!De(e)&&/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,3})+$/.test(e)},e.isErr=wm,e.isIE=Vu,e.isNarrow=function(e){if(!In())return!1;let t=window.innerWidth>0&&window.innerWidth<=1024,r=!1;if(e){let t=we(e,"clientWidth",0);r=t>0&&t<=700}return t||r},e.isStrHasCapital=hI,e.isStrHasLetter=AI,e.isStrHasLowerCase=mI,e.isStrHasNumber=II,e.isStrHasSpace=yI,e.isStrHasSymbol=vI,e.isUserIdentify=function(e){let t=ns();if(!De(e))return t.reject("身份證字號非有效字串"),t;if(10!==e.length)return t.reject("身份證字號長度非10位"),t;if(isNaN(e.substring(1,10))||!/^[A-Z]$/.test(e.substring(0,1)))return t.reject("身份證格式錯誤,字首需大寫英文"),t;e="ABCDEFGHJKLMNPQRSTUVXYWZIO".indexOf(e.substring(0,1))+10+""+e.substring(1,10);let r=parseInt(e.substring(0,1))+9*parseInt(e.substring(1,2))+8*parseInt(e.substring(2,3))+7*parseInt(e.substring(3,4))+6*parseInt(e.substring(4,5))+5*parseInt(e.substring(5,6))+4*parseInt(e.substring(6,7))+3*parseInt(e.substring(7,8))+2*parseInt(e.substring(8,9))+parseInt(e.substring(9,10)),n=parseInt(e.substring(10,11));return r%10!=0&&10-r%10!==n?(t.reject("非有效身份證"),t):(t.resolve(),t)},e.isUserName=function(e){let t=ns();return De(e)?(t.resolve(),t):(t.reject("請填入姓名"),t)},e.isUserPw=function(e,t={}){let r=[],n=we(t,"useKeyForError",null);pn(n)||(n=!1);let i=we(t,"useOnlyOneError",null);if(pn(i)||(i=!1),xe(e)||(n?r.push("keyInvalidPassword"):r.push("密碼非有效字串")),dn(r)>0)throw new Error(r[0]);let o=we(t,"numLenMin","");(!Hn(o)||Zi(o)<0)&&(o=8),o=Zi(o);let a=we(t,"numLenMax","");if((!Hn(a)||Zi(a)<0)&&(a=30),a=Zi(a),o>a&&(n?r.push("keyLimNumLenMinOrMax"):r.push("設定密碼最小長度大於最大長度")),dn(r)>0)throw new Error(r[0]);let s=we(t,"noSpace",null);if(pn(s)||(s=!0),s&&(yI(e)&&(n?r.push("keyLimHasSpace"):r.push("密碼不可包含空白字元")),i&&dn(r)>0))throw new Error(r[0]);let c=we(t,"onlyAscii",null);if(pn(c)||(c=!0),c&&(/[^\x20-\x7e]/.test(e)&&(n?r.push("keyLimNonAsciiChar"):r.push("密碼僅允許使用英文大小寫、數字及特殊符號")),i&&dn(r)>0))throw new Error(r[0]);if(dn(e)<o&&(n?r.push("keyLimNumLenMin"):r.push(`密碼長度須大於等於${o}個字元`)),i&&dn(r)>0)throw new Error(r[0]);if(dn(e)>a&&(n?r.push("keyLimNumLenMax"):r.push(`密碼長度須小於等於${a}個字元`)),i&&dn(r)>0)throw new Error(r[0]);let l=we(t,"requireLetter",null);pn(l)||(l=!1);let u=we(t,"requireUppercase",null);pn(u)||(u=!0);let f=we(t,"requireLowercase",null);pn(f)||(f=!0);let d=we(t,"requireDigit",null);pn(d)||(d=!0);let g=we(t,"requireSpecial",null);if(pn(g)||(g=!0),l&&!AI(e)&&(n?r.push("keyLimRequireLetter"):r.push("密碼須包含至少一個英文字母")),i&&dn(r)>0)throw new Error(r[0]);if(u&&!hI(e)&&(n?r.push("keyLimRequireUppercase"):r.push("密碼須包含至少一個大寫英文字母")),i&&dn(r)>0)throw new Error(r[0]);if(f&&!mI(e)&&(n?r.push("keyLimRequireLowercase"):r.push("密碼須包含至少一個小寫英文字母")),i&&dn(r)>0)throw new Error(r[0]);if(d&&!II(e)&&(n?r.push("keyLimRequireDigit"):r.push("密碼須包含至少一個數字")),i&&dn(r)>0)throw new Error(r[0]);if(g&&!vI(e)&&(n?r.push("keyLimRequireSpecial"):r.push("密碼須包含至少一個特殊符號")),i&&dn(r)>0)throw new Error(r[0]);let p=we(t,"forbiddenChars",null);if(Ce(p)||(p=[]),dn(p)>0){for(let t of p)if(e.includes(t)){if(n){r.push("keyLimForbiddenChar");break}r.push(`密碼不可包含字元:${t}`)}if(i&&dn(r)>0)throw new Error(r[0])}let h=we(t,"commonPasswordBlacklist",null);if(Ce(h)||(h=xI),dn(h)>0){let t=e.toLowerCase();if(h.some(e=>xe(e)&&t===e.toLowerCase())&&(n?r.push("keyLimCommonPassword"):r.push("此密碼為常見弱密碼,不允許使用")),i&&dn(r)>0)throw new Error(r[0])}let A=we(t,"account",""),m=we(t,"noConsecutiveCharsFromAccount",null);pn(m)||(m=!1);let I=we(t,"consecutiveCharsMinMatch","");if(eo(I)||(I=3),I=Zi(I),m&&xe(A)&&dn(A)>=I){let t=[...A.toLowerCase()],o=e.toLowerCase(),a=!1;for(let e=0;e<=t.length-I;e++){let r=t.slice(e,e+I).join("");if(o.includes(r)){a=!0;break}}if(a&&(n?r.push("keyLimConsecutiveCharsFromAccount"):r.push(`密碼不可包含與帳號相同之${I}個以上連續字元`)),i&&dn(r)>0)throw new Error(r[0])}if(dn(r)>0)throw new Error(r.join(" | "));return!0},e.isWindow=In,e.isab=I,e.isarr=Ce,e.isarr0=Lr,e.isbigint=Ta,e.isblob=gs,e.isbol=pn,e.isday=ku,e.isearr=Rr,e.iseobj=Ee,e.iser=Ur,e.isernot=fd,e.isestr=De,e.isfile=Wm,e.isfun=va,e.isint=Hn,e.ismonth=wn,e.isn0int=dI,e.isn0num=gI,e.isnan=Qe,e.isnbr=Fe,e.isnint=Th,e.isnnum=function(e){return!!Se(e)&&Mn(e)<0},e.isnull=qr,e.isnum=Se,e.isobj=Be,e.isobj0=Mr,e.isp0int=Bo,e.isp0num=pI,e.ispint=eo,e.ispm=ys,e.ispnum=ha,e.isstr=xe,e.isstr0=Hr,e.istime=Eg,e.istimeTZ=CI,e.istimems=bI,e.istimemsTZ=EI,e.isu16arr=pm,e.isu8arr=Za,e.isundefined=Nr,e.j2o=Ka,e.judge=function(e,t,r,n={}){if(!Se(e))throw new Error("x1 is not a number");if(!Se(r))throw new Error("x2 is not a number");let i=we(n,"withPreciseNum");if(pn(i)||(i=!0),i&&(e=Kh(e),r=Kh(r)),"==="===t)return e===r||DI(e,r);if("!=="===t)return function(e,t){return!DI(e,t)}(e,r);if(">="===t)return e===r||function(e,t){return new il(e).gte(t)}(e,r);if(">"===t)return function(e,t){return new il(e).gt(t)}(e,r);if("<="===t)return e===r||function(e,t){return new il(e).lte(t)}(e,r);if("<"===t)return function(e,t){return new il(e).lt(t)}(e,r);throw console.log(t),new Error(`invalid op[${t}]`)},e.keysmat2ltdt=FI,e.ltdt2vrtsable=function(e,t=[]){if(!Rr(e))return[];if(!Ce(t))return[];let r=!1;if(Er(e,function(e){Ee(e)||(r=!0)}),r)return[];let n=Xr(e),i=[];Er(e,function(e){let t={};Er(n,function(r){t[r]={value:e[r].value,style:e[r].style,rowspan:1}}),i.push(t)});let o=La(i),a=dn(o);return Er(n,function(e){if(ya(e,t)){let t=ao(0,a,0),r=ao(0,a,0),n=ao(1,a+1,0);Er(o,function(i,a){if(a>0){ma(o[a-1][e].value,o[a][e].value)&&(t[a-1]=1,t[a]=1,n[a]=n[a-1]+1),1===t[a-1]&&1===t[a]&&(r[a-1]=0,r[a]=1)}}),Er(o,function(i,a){1===t[a]&&(1===r[a]?o[a][e].rowspan=n[a]:o[a][e].rowspan=null)})}}),La(o)},e.ltdtDiff=function(e,t,r={}){if(!Ce(e))return{};if(!Ce(t))return{};if(0===dn(e)&&0===dn(t))return{};let n=we(r,"empty");De(n)||(n="∗empty∗");let i=Xr(e),o=Xr(t),a=QI(i,o),s={};Er(a,(e,t)=>{s[t]=e});let c=aa(An(e,a,{empty:n}),An(t,a,{empty:n}),{...r,mode:"matrix"});return c.dfs=xr(c.dfs,e=>{let t={};Er(e,e=>{e.k=s[e.k],t[e.k]=e});let r={};return Er(a,e=>{r[e]=t[e]}),r}),c},e.ltdtDiffByKey=nm,e.ltdtkeys2mat=An,e.ltdtkeysheads2mat=mn,e.ltdtmapping=function(e,t,r=""){return Rr(e)&&Rr(t)?xr(e,e=>Xh(e,t,r)):[]},e.ltdtmerge=mA,e.ltdtpick=function(e,t){return Rr(e)&&Rr(t)?xr(e,e=>_h(e,t)):[]},e.ltdtpull=function(e,t,r){return Ce(e)&&Ce(t)&&De(r)&&gr(e,e=>Be(e))?0===t.length?e:gr(t,e=>Be(e))?kI(e,t,r):[]:[]},e.mat2ltdt=function(e){if(!Rr(e))return[];if(e.length<=1)return[];let t=!1;return Er(e,function(e){Rr(e)||(t=!0)}),t?[]:FI(ra(e)[0],(n=null==(r=e)?0:r.length)?Do(r,1,n):[]);var r,n},e.matConcat=function(e,t){if(!Ce(e))return[];if(!Ce(t))return[];if(0===dn(e)&&0===dn(t))return[];let r=dn(e),n=dn(we(e,0,[])),i=dn(t),o=dn(we(t,0,[])),a=[],s=Math.max(r,i);for(let r=0;r<s;r++){let i=[],s=-1;for(let t=0;t<n;t++){s++;let n=we(e,`${r}.${t}`,null);i[s]=n}for(let e=0;e<o;e++){s++;let n=we(t,`${r}.${e}`,null);i[s]=n}a[r]=i}return a},e.matDiff=function(e,t,r={}){return Ce(e)&&Ce(t)?0===dn(e)&&0===dn(t)?{}:aa(e,t,{...r,mode:"matrix"}):{}},e.matat=function(e,t,r){return Rr(e)?xr(e,function(e){return Eo(e,t,r)}):[]},e.now2str=RA,e.now2strp=function(){if(!va(r))throw new Error("invalid dayjs");return r().format("YYYYMMDDHHmmss")},e.nowDay2str=function(){if(!va(r))throw new Error("invalid dayjs");return r().format("YYYY-MM-DD")},e.nowms2str=function(){if(!va(r))throw new Error("invalid dayjs");return r().format("YYYY-MM-DDTHH:mm:ss.SSSZ")},e.nowms2strp=function(){if(!va(r))throw new Error("invalid dayjs");return r().format("YYYYMMDDHHmmssSSS")},e.o2j=hn,e.obj2b64=function(e){let t="";try{t=NI(hn(e))}catch(e){t=""}return t},e.obj2pb64=function(e,t){return void 0===e?"":De(t)?qI(hn({data:e}),t,!0):""},e.obj2str=function(e,t="Uint8Array"){if(Nr(e))return"";if(xe(t))t=[t];else if(!Ce(t))return"";let r="";try{r=JSON.stringify(e,function(e,r){return t.indexOf("Uint8Array")>=0&&(r=YI.u8arr2b64(r)),t.indexOf("Uint16Array")>=0&&(r=YI.u16arr2b64(r)),r})}catch(e){r=""}return r},e.obj2stru8arr=jI,e.obj2u8arr=function(e){let t=[],r=[];if(!Rr(e)&&!Ee(e))return null;let n=[],i=[];function o(e){n.push(hm(e)),i.push(e)}try{let a=jI(e);o(GI(a.results)),Er(a.binarys,e=>{o(e)});let s=n,c=GI(JSON.stringify(s)),l=new Uint8Array(8);Is(hm(c),l),t.push(l),t.push(c),Er(i,e=>{t.push(e)}),Er(t,e=>{r=function(e,t){let r=hm(e),n=hm(t),i=new Uint8Array(r+n);return i.set(new Uint8Array(e),0),i.set(new Uint8Array(t),r),i}(r,e)})}catch(e){return null}return r},e.objSortBy=JI,e.objSortByKeys=function(e,t){if(!Ee(e))return{};if(!Rr(t))return{};let r={};return Er(t,(e,t)=>{r[e]=t}),JI(e,(e,t)=>we(r,t,0))},e.oo=function(e){if(void 0!==e)return Ka(hn(e))},e.openLink=function(e){if(!De(e))return;let t=document.createElement("a");t.href=e,t.target="_blank",document.body.appendChild(t),t.click(),document.body.removeChild(t)},e.pb642obj=function(e,t){return De(e)&&De(t)?Ka(li(e,t,!0)).data:""},e.pm2resolve=Oh,e.pmChain=function(e,t=null){if(!Ce(e)){let e=ns();return e.reject("pms is not an array"),e}return e.reduce((e,t)=>e.then(t),Promise.resolve(t))},e.pmConvertResolve=Rh,e.pmDebounce=function(e=300){return new function(e){let t=[],r=null,n=null,i="wait";return eo(e)||(e=300),e=Zi(e),function(o,...a){va(o)?((null===n||"wait"===i)&&(n=Date.now()),t.push({func:o,input:a,output:null}),null===r&&"wait"===i&&(r=setInterval(()=>{if(null===n)throw new Error("invalid tLast");if("wait"!==i)return;if("wait"===i&&0===t.length)return clearInterval(r),r=null,void(n=null);let o=Date.now();if(o-n>e){i="doing",n=o;let e=t.pop();t=[];let r=e.func(...e.input);ys(r)?r.then(t=>{e.output=t}).catch(t=>{e.output={err:t}}).finally(()=>{i="wait",n=Date.now()}):(e.output=r,i="wait")}"wait"===i&&0===t.length&&(clearInterval(r),r=null,n=null)},20))):console.log("func is not a function")}}(e)},e.pmHook=zI,e.pmHookReject=function(e,t=()=>{}){return va(e)?(va(t)||(t=()=>{}),zI(e,e=>{if("afterCatch"===e.mode)return t(e.data)})):null},e.pmIni=function(){return Promise.resolve()},e.pmInvResolve=function(e,t={}){if(!ys(e))throw new Error("pm is not a promise");let r=we(t,"thenExtractData");pn(r)||(r=!1);let n=ns();return e.then(e=>{r&&(e=we(e,"data"));let t=we(e,"state",""),i=we(e,"msg",{});"success"===t?n.resolve(i):"cancelled"===t?n.reject({reason:"cancelled"}):n.reject(i)}).catch(e=>{n.reject(e)}),n},e.pmKeyMutex=function(){return new function(){let e=new Map,t=new Map;return async(r,n)=>{let i=(e.get(r)||Promise.resolve()).then(async()=>await n(),async()=>await n());e.set(r,i.catch(()=>{})),t.set(r,(t.get(r)||0)+1);try{return await i}finally{let n=t.get(r)-1;n<=0?(t.delete(r),e.delete(r)):t.set(r,n)}}}},e.pmMap=function(e,t,r=0){let n={},i=!1,o=ns();if(!Ce(e)&&!Be(e))return o.reject("rs is not an array or object"),o;if(0===dn(e))return o.resolve([]),o;let a=!1;if(Be(e)){a=!0;let t=[];Er(e,(e,r)=>{t.push({k:r,v:e})}),e=t}let s=Yh(r);return s.on("message",function(r){if(i)return;let c,l=s.get();if(va(t)){let e=l.key,r=l.value;if(a&&(e=l.value.k,r=l.value.v),c=t(r,e),!ys(c))throw new Error("return of fun is not a promise")}else c=l.value;c.then(e=>{n[l.key]=e}).catch(e=>{i=!0,s.clear(),o.reject(e)}).finally(()=>{s.cb(),dn(n)===dn(e)&&o.resolve(lA(n))})}),Er(e,(e,t)=>{s.push({key:t,value:e})}),o},e.pmQueue=jh,e.pmSeries=cl,e.pmThrottle=function(){let e=Xi(),t=[],r=null,n=!1;return function(i,...o){let a=ns();if(!va(i))return void console.log("func is not a function");let s=Hu();return t.push({id:s,func:i,input:o}),null===r&&(r=setInterval(async()=>{if(n)return;n=!0;let i=t.pop();for(let r=0;r<t.length;r++){let n=t[r].id,i={state:"cancelled"};e.emit(n,i)}if(t=[],i){let t,r=i.id;t=va(i.func)?await Oh(i.func)(...i.input):{state:"error",msg:"fun is not a function"},e.emit(r,t)}n=!1,n||0!==t.length||(clearInterval(r),r=null)},20)),e.once(s,e=>{"success"===e.state?a.resolve(e.msg):"cancelled"===e.state?a.reject({reason:"cancelled"}):a.reject(e.msg)}),a}},e.preciseNum=Kh,e.pseudoRandom=XI,e.pseudoRandomIntRange=function(e=0,t=100,r="start1"){if(Hn(e)||(e=0),e=Zi(e),Hn(t)||(t=100),e>(t=Zi(t)))throw new Error(`vstart[${e}] > vend[${t}]`);let n=XI(r)*(t-e+1)+e;return n=Math.floor(n),n},e.pseudoRandomIntsNdpRange=function(e=0,t=100,r,n="start1"){if(Hn(e)||(e=0),e=Zi(e),Hn(t)||(t=100),t=Zi(t),eo(r)||(r=1),r=Zi(r),e>t)throw new Error(`vstart[${e}] > vend[${t}]`);let i=XI(n,!0),o=[],a=t-e;for(let r=0;r<=a;r++){let r=i()*(t-e+1)+e;r=Math.floor(r),o.push(r)}let s=_a(o,{returnIndex:!0});return s=ra(s,r),s},e.pseudoRandomIntsRange=function(e=0,t=100,r,n="start1"){if(Hn(e)||(e=0),e=Zi(e),Hn(t)||(t=100),t=Zi(t),eo(r)||(r=1),r=Zi(r),e>t)throw new Error(`vstart[${e}] > vend[${t}]`);let i=XI(n,!0),o=[];for(let n=1;n<=r;n++){let r=i()*(t-e+1)+e;r=Math.floor(r),o.push(r)}return o},e.pseudoRandomRange=function(e=0,t=1,r="start1"){if(Se(e)||(e=0),e=Mn(e),Se(t)||(t=1),e>(t=Mn(t)))throw new Error(`vstart[${e}] > vend[${t}]`);return XI(r)*(t-e)+e},e.pseudoRandomsRange=function(e=0,t=1,r=1,n="start1"){if(Se(e)||(e=0),e=Mn(e),Se(t)||(t=1),t=Mn(t),eo(r)||(r=1),r=Zi(r),e>t)throw new Error(`vstart[${e}] > vend[${t}]`);let i=XI(n,!0),o=[];for(let n=1;n<=r;n++){let r=i()*(t-e)+e;o.push(r)}return o},e.queue=Yh,e.random=WI,e.randomIntRange=function(e=0,t=100){if(Hn(e)||(e=0),e=Zi(e),Hn(t)||(t=100),e>(t=Zi(t)))throw new Error(`vstart[${e}] > vend[${t}]`);let r=WI()*(t-e+1)+e;return r=Math.floor(r),r},e.randomIntsNdpRange=function(e=0,t=100,r){if(Hn(e)||(e=0),e=Zi(e),Hn(t)||(t=100),t=Zi(t),eo(r)||(r=1),r=Zi(r),e>t)throw new Error(`vstart[${e}] > vend[${t}]`);return function(e,t,r){return t=(r?dr(e,t,r):void 0===t)?1:qn(t),(v(e)?ry:ny)(e,t)}(ao(e,t+1),r)},e.randomIntsRange=function(e=0,t=100,r){if(Hn(e)||(e=0),e=Zi(e),Hn(t)||(t=100),t=Zi(t),eo(r)||(r=1),r=Zi(r),e>t)throw new Error(`vstart[${e}] > vend[${t}]`);let n=[];for(let i=1;i<=r;i++){let r=WI()*(t-e+1)+e;r=Math.floor(r),n.push(r)}return n},e.randomRange=function(e=0,t=1){if(Se(e)||(e=0),e=Mn(e),Se(t)||(t=1),e>(t=Mn(t)))throw new Error(`vstart[${e}] > vend[${t}]`);return WI()*(t-e)+e},e.randomsRange=function(e=0,t=1,r=1){if(Se(e)||(e=0),e=Mn(e),Se(t)||(t=1),t=Mn(t),eo(r)||(r=1),r=Zi(r),e>t)throw new Error(`vstart[${e}] > vend[${t}]`);let n=[];for(let i=1;i<=r;i++){let r=WI()*(t-e)+e;n.push(r)}return n},e.rang=function(e,t,r=2){if(!Se(e))return[];if(e=Mn(e),!Se(t))return[];if(t=Mn(t),eo(r)||(r=2),(r=Zi(r))<=0)throw new Error(`num[${r}] <= 0`);let n=(t-e)/r,i=e,o=[];for(let e=0;e<=r;e++)o.push(i),i+=n;return o},e.rep=function(e,t){return De(e)&&Bo(t)?oy(e,t):""},e.repObj=function(e,t){return Ur(e)?[]:eo(t)?tI(t,fo(e)):[]},e.replace=pl,e.replaceObj=function(e,t){return De(e)&&Ee(t)?(Er(t,function(e,t){e=Be(e)||Ce(e)?JSON.stringify(e):Ya(e)}),Er(t,function(t,r){e=pl(e,r,t)}),e):""},e.replacePlus=function(e,t,r,n=null,i){if(!De(e)||!De(t)||!De(r))return"";if(!xe(i))return"";let o="[\\s\\S]*";De(n)&&(o="[^"+n+"]*");let a=new RegExp(t+o+r,"g");return e.replace(a,i)},e.round=Wh,e.secd=function(e){return Se(e)?1/Du(e=Mn(e)):null},e.sep=la,e.sepInt=function(e,t,r=!0){if(!Hn(e))return[];if(!Bo(t))return[];if(!pn(r))return[];let n=ay(e/t),i=e-n*t,o=[];for(let e=1;e<=t;e++){let t=n;e<=i&&(t=n+1),o.push(t)}return r&&(o=La(o)),o},e.setIntervalHp=function(e,t=1){let r=yn(),n=In(),i=e=>{r.setTimeout(e,1)},o=e=>{r.requestAnimationFrame(e)},a=null;a=n?o:i;let s=iI(),c=!0,l=s(),u=()=>{if(!c)return;if(s()-l>=t){try{e()}catch(e){console.log(e)}l=s()}a(u)};return a(u),()=>{c=!1}},e.setTimeoutHp=function(e,t=1){let r=yn(),n=In(),i=e=>{r.setTimeout(e,1)},o=e=>{r.requestAnimationFrame(e)},a=null;a=n?o:i;let s=iI(),c=!0,l=s(),u=()=>{if(!c)return;if(s()-l>=t){c=!1;try{e()}catch(e){console.log(e)}}a(u)};return a(u),null},e.sind=Su,e.split=ca,e.str2aes=qI,e.str2b64=NI,e.str2hint=VI,e.str2md5=function(e,t=!1){if(!De(e))return"";if(!pn(t))return"";let r=sy(e),n="";return n=t?r.toString(zn):r.toString(ci),n},e.str2obj=function(e,t="Uint8Array"){if(xe(t))t=[t];else if(!Ce(t))return{};let r={};try{r=JSON.parse(e,function(e,r){return t.indexOf("Uint8Array")>=0&&(r=YI.b642u8arr(r)),t.indexOf("Uint16Array")>=0&&(r=YI.b642u16arr(r)),r})}catch(e){r={}}return r},e.str2sha512=function(e,t=!1){if(!De(e))return"";if(!pn(t))return"";let r=fy(e),n="";return n=t?r.toString(zn):r.toString(ci),n},e.str2u8arr=GI,e.strCompare=dy,e.strDiff=na,e.strDiffToHtml=function(e,t,r={}){if(!xe(e))return"";if(!xe(t))return"";if(""===e&&""===t)return"";let n=we(r,"useNormNewline");pn(n)||(n=!0),n&&(e=(e=e.replaceAll("\r\n","\n")).replaceAll("\r","\n"),t=(t=t.replaceAll("\r\n","\n")).replaceAll("\r","\n"));let i=Jf(),o=ea("file","file",e,t),a=i.html(o,{drawFileList:!1,matching:"none",diffStyle:"char",outputFormat:"line-by-line"}),s=Jo(a,"\n"),c="",l=!1;return Er(s,e=>{'<div class="d2h-code-line">'===sa(e)&&(l=!0),e.indexOf('class="d2h-code-line-prefix"')>=0&&(e=e.replaceAll('class="d2h-code-line-prefix"','class="d2h-code-line-prefix" style="display:inline-block; width: 0.7rem;"')),e.indexOf("<del>")>=0&&(e=e.replaceAll("<del>",'<del style="color:#f26; background:#ffefd5;">')),e.indexOf("<ins>")>=0&&(e=e.replaceAll("<ins>",'<ins style="color:#090; background:#e4fed1;">')),l&&(c+=e+"\n"),l&&"</div>"===sa(e)&&(l=!1)}),a=c,a},e.strFindFuzz=function(e,t,r=!1){let n="";if(De(e)||Se(e))n=Ya(e);else{if(!Rr(e))return!!r&&0;n=xo(e,"")}if(""===t)return!r||100;if(Ur(t))return!!r&&0;if(rs(n,t))return!r||100;let i=la(t," "),o=xr(i,function(e){return((e,t)=>{let r=new dv([e],{includeScore:!0}).search(t);r=we(r,0);let n=we(r,"score",1);return n=1-n,n*=100,n})(n,e)});if(r)return gv(o);{let e=80;return gr(o,function(t){return t>=e})}},e.strFindSimilar=function(e,t){let r="";if(De(e)||Se(e))r=Ya(e);else{if(!Rr(e))return{};r=xo(e,"")}return Se(t)&&(t=Ya(t)),De(t)&&(t=[t]),Rr(t)?function(e,t){let r=[],n=0;for(let i=0;i<t.length;i++){let o=t[i],a=dy(e,o);r.push({target:o,rating:a}),a>r[n].rating&&(n=i)}return{ratings:r,bestMatch:r[n],bestMatchIndex:n}}(r,t=xr(t,function(e){return Ya(e)})):{}},e.strdelleft=da,e.strdelright=Ga,e.strleft=ua,e.strmid=hl,e.strright=fa,e.stru8arr2obj=pv,e.tand=Fu,e.time2day=function(e){return Eg(e)?r(e,"YYYY-MM-DDTHH:mm:ss").format("YYYY-MM-DD"):""},e.time2hour=function(e){return Eg(e)?r(e,"YYYY-MM-DDTHH:mm:ss").format("YYYY-MM-DDTHH"):""},e.time2min=oI,e.timeTZ2day=function(e){return CI(e)?(e=BI.delTZ(e),r(e,"YYYY-MM-DDTHH:mm:ss").format("YYYY-MM-DD")):""},e.timeTZ2expire=function(e,t=null){return CI(e)?hv(e=mv(e),t=mv(t)):{today:null,msg:"",err:"時間格式錯誤"}},e.timeTZ2hour=function(e){return CI(e)?(e=BI.delTZ(e),r(e,"YYYY-MM-DDTHH:mm:ss").format("YYYY-MM-DDTHH")):""},e.timeTZ2min=function(e){return CI(e)?(e=BI.delTZ(e),r(e,"YYYY-MM-DDTHH:mm:ss").format("YYYY-MM-DDTHH:mm")):""},e.timeTZ2past=function(e,t=null){return CI(e)?Av(e=Iv(e),t=Iv(t)):{today:null,msg:"",err:"時間格式錯誤"}},e.timems2day=function(e){return bI(e)?r(e,"YYYY-MM-DDTHH:mm:ss.SSS").format("YYYY-MM-DD"):""},e.timems2hour=function(e){return bI(e)?r(e,"YYYY-MM-DDTHH:mm:ss.SSS").format("YYYY-MM-DDTHH"):""},e.timems2min=function(e){return bI(e)?r(e,"YYYY-MM-DDTHH:mm:ss.SSS").format("YYYY-MM-DDTHH:mm"):""},e.timems2time=function(e){return bI(e)?r(e,"YYYY-MM-DDTHH:mm:ss.SSS").format("YYYY-MM-DDTHH:mm:ss"):""},e.timemsTZ2day=function(e){return EI(e)?(e=BI.delTZ(e),r(e).format("YYYY-MM-DD")):""},e.timemsTZ2expire=hv,e.timemsTZ2hour=function(e){return EI(e)?(e=BI.delTZ(e),r(e).format("YYYY-MM-DDTHH")):""},e.timemsTZ2min=function(e){return EI(e)?(e=BI.delTZ(e),r(e).format("YYYY-MM-DDTHH:mm")):""},e.timemsTZ2past=Av,e.timemsTZ2time=function(e){return EI(e)?(e=BI.delTZ(e),r(e).format("YYYY-MM-DDTHH:mm:ss")):""},e.treeObj=Eu,e.treeToFilepath=function(e,t={}){if(!Rr(e))return[];let r=we(t,"delimiter");De(r)||(r="/");let n=we(t,"bindRoot");De(n)||(n="root");let i=[];return Eu(e,(e,t,o)=>{let a=we(e,"_type","");if("folder"!==a&&"file"!==a)return e;let s=xr(we(e,"pathInfors",[]),"name"),c=we(s,0,"")===n;if(1===dn(s)&&c)return e;c&&(s=ja(s));let l={type:a,path:r+xo(s,r)};return i.push(l),e},{force:!0}),i},e.trim=Ja,e.u16arr2b64=RI,e.u16arr2u8arr=UI,e.u8arr2ab=function(e){return Za(e)?e.buffer:new ArrayBuffer},e.u8arr2b64=LI,e.u8arr2blob=Ph,e.u8arr2bs=function(e){if(!Za(e))return"";let t=e.length,r="";for(let n=0;n<t;n++)r+=String.fromCharCode(e[n]);return r},e.u8arr2obj=function(e){let t=null;if(!Za(e))return null;try{let r=8,n=e.slice(0,r),i=e.slice(r,hm(e)),o=As(n),a=i.slice(0,o),s=i.slice(o,hm(i)),c=yv(a),l=function(e,t){let r=0,n=0,i=[];return Er(t,t=>{n=r+t;let o=e.slice(r,n);r=n,i.push(o)}),i}(s,JSON.parse(c));t=pv({results:yv(l.shift()),binarys:l})}catch(e){}return t},e.u8arr2str=yv,e.u8arr2u16arr=es,e.urlParse=function(e){if(!De(e))return{};if(!De(e=we(e=Jo(e,"?"),"[1]")))return{};let t=Jo(e,"&");return t=xr(t,function(e){return Jo(e,"=")}),t=function(e){for(var t=-1,r=null==e?0:e.length,n={};++t<r;){var i=e[t];di(n,i[0],i[1])}return n}(t),t},e.verifyValue=function(e,t,r={}){let n=!1,i="";if("isstr"===t)xe(e)||(n=!0,i="需要為字串",e="");else if("isnum"===t)Se(e)||(n=!0,i="需要為數字",e=0);else if("isp0num"===t)pI(e)||(n=!0,i="需要為含0的正浮點數",e=0);else if("isn0num"===t)gI(e)||(n=!0,i="需要為含0的負浮點數",e=0);else if("isint"===t)Hn(e)||(n=!0,i="需要為整數",e=0);else if("ispint"===t)eo(e)||(n=!0,i="需要為不含0正整數",e=0);else if("isp0int"===t)Bo(e)||(n=!0,i="需要為含0正整數",e=0);else if("isnint"===t)Th(e)||(n=!0,i="需要為不含0負整數",e=0);else if("isn0int"===t)dI(e)||(n=!0,i="需要為含0負整數",e=0);else if("custom"===t){let t=we(r,"funCustom");if(!va(t))throw new Error("invalid opt.funCustom when type='custom'");let o=t(e);if(!pn(o.err))throw new Error("invalid return.err for type='custom'");if(o.err&&!De(o.errmsg))throw new Error("invalid return.errmsg when return.err=true for type='custom'");if(!Se(o.value)&!xe(o.value))throw new Error("invalid return.value for type='custom'");n=o.err,i=o.errmsg,e=o.value}else if(va(t)){e=t(e)}else"any"===t?Se(e)||xe(e)||(n=!0,i="需要為字串或數字",e=""):(n=!0,i="需要指定驗證類型",e=null);return{value:e,err:n,errmsg:i}},e.waitFun=vs});
24
24
  //# sourceMappingURL=wsemi.umd.js.map